- launch.ts policy: LAUNCH_MODE=free_early_access default; effective access = published && (free || early); intended tier (access) never rewritten - Billing off server-side: /api/subscribe 503 honest copy; subscribe CTAs render disabled 'قريباً' from first paint; /subscription early-access panel + /api/notify (LaunchNotifications) with honest 503 when mail transport off - Signup trust: verification email at signup (Users afterChange), no confirm-password, 429 message fidelity, typo suggestion, live password hint - Agent pipeline: pickFields strips access/readingMinutes, sourceId dedup, secret-scan 422 (pattern names only), string-content rejected (was silently replaced), publish stays explicit opt-in - lexical.ts: root unwrap fix — lexicalToText/countLexicalWords returned 0 for real serialized trees (secret scan + readingMinutes were inert) - llms-full.txt: fetchIndexDocs(true) — bodies were never selected - Content honesty: contentType/authorName/sourceId fields + migration, readingMinutes computed at write (160 wpm) + backfill script, byline, 'حُدّث' freshness - SEO/AI-SEO: metadata rewrite (published-only, og:image 1200x630), Article + BreadcrumbList + FAQPage + Organization JSON-LD, isAccessibleForFree honest, table renderer, robots AI-crawler policy (10 named bots), llms.txt + llms-full.txt, /topics/* hubs + sitemap, noindex auth pages, www 301 - Ops: backup-db.sh (restore rehearsed on VPS), docs copies (launch readiness + marketing audit + owner-inputs for L-03), GLOSSARY.md entries Verified: tsc --noEmit 0, npm run build 0, local smoke (ghost VIP read, subscribe/notify/agent APIs, signup token, 429 on 6th, llms/topics/sitemap, og:image/JSON-LD)
48 lines
1.9 KiB
TypeScript
48 lines
1.9 KiB
TypeScript
import type { Metadata, Viewport } from 'next'
|
|
import { Readex_Pro } from 'next/font/google'
|
|
import './globals.css'
|
|
import './polish.css'
|
|
import './design.css'
|
|
import './color-trial.css'
|
|
|
|
/* Readex Pro: a modern Arabic/Latin face drawn for screens and interfaces.
|
|
Self-hosted at build time by next/font. */
|
|
const sans = Readex_Pro({
|
|
subsets: ['arabic', 'latin'],
|
|
weight: ['300', '400', '500', '600', '700'],
|
|
display: 'swap',
|
|
variable: '--font-sans',
|
|
})
|
|
|
|
/* The design is light-only: stop browsers' forced dark modes from repainting it. */
|
|
export const viewport: Viewport = { colorScheme: 'only light', themeColor: '#ffffff' }
|
|
|
|
export const metadata: Metadata = {
|
|
metadataBase: new URL(process.env.NEXT_PUBLIC_SITE_URL ?? 'https://anwarpi.ai'),
|
|
title: { default: 'أنور بآي — أدلة الذكاء الاصطناعي العملي بالعربية', template: '%s — أنور بآي' },
|
|
description: 'دليلك العربي للذكاء الاصطناعي العملي: وكلاء، نماذج، وأدوات.',
|
|
alternates: { canonical: './' },
|
|
openGraph: {
|
|
type: 'website',
|
|
siteName: 'أنور بآي',
|
|
locale: 'ar',
|
|
images: [{ url: '/og-default.png', width: 1200, height: 630 }],
|
|
},
|
|
twitter: { card: 'summary_large_image', images: ['/og-default.png'] },
|
|
}
|
|
|
|
export default function RootLayout({ children }: { children: React.ReactNode }) {
|
|
const siteUrl = process.env.NEXT_PUBLIC_SITE_URL ?? 'https://anwarpi.ai'
|
|
return (
|
|
<html lang="ar" dir="rtl" className={sans.variable}>
|
|
<head>
|
|
<meta name="darkreader-lock" />
|
|
</head>
|
|
<body>
|
|
{children}
|
|
<script type="application/ld+json" dangerouslySetInnerHTML={{ __html: JSON.stringify({ '@context': 'https://schema.org', '@type': 'WebSite', name: 'أنور بآي', url: siteUrl, inLanguage: 'ar' }) }} />
|
|
</body>
|
|
</html>
|
|
)
|
|
}
|