Merge branch 'upgrade/next-16': upgrade Next.js 15->16, React 18->19

- next 15.5.7 -> 16.2.10, react 18.3.1 -> 19.2.7
- middleware.js -> proxy.js (Next 16 convention)
- next lint -> eslint@9 flat config
- enable React Compiler (Turbopack built-in babel)
- cacheComponents evaluated and left disabled (multi-domain headers() incompatibility)

Build, 69 vitest tests, and production smoke test all pass.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
hamed
2026-07-06 10:21:37 +03:30
co-authored by Claude Fable 5
63 changed files with 46290 additions and 77 deletions
+234
View File
@@ -0,0 +1,234 @@
# ارتقای Next.js از 15 به 16 (آخرین نسخه) + فعال‌سازی امکانات جدید
## پروژه
`nobat724_front`
## زمینه
پروژه روی `next@15.5.7` و `react@18.3.1` است (React با `overrides` در `package.json` روی 18 پین شده). آخرین نسخه پایدار Next.js نسخه **16.3.x** است (16.2.10 LTS هم موجود است — هدف این ارتقا `next@latest` یعنی 16.3.x). Next 16 چند breaking change دارد (React 19 اجباری، حذف `next lint`، deprecate شدن `middleware` به نفع `proxy`، Turbopack به‌عنوان پیش‌فرض build/dev) و چند قابلیت جدید (Cache Components، React Compiler، Instant Navigations / Partial Prefetching در 16.3).
**تمام کار باید روی برنچ جدا انجام شود**`main` دست نخورد.
## مشکل / هدف
1. ارتقای `next` به آخرین نسخه (16.3.x) و `react`/`react-dom` به 19
2. رفع همه breaking changeها تا `npm run build` و `npm run test` سبز شود
3. فعال‌سازی امکانات جدید نسخه 16 که با معماری multi-domain پروژه سازگارند
4. رفتار SEO فعلی (متادیتا داخل `<head>`، canonical، sitemap، robots) عیناً حفظ شود
## فایل‌های مرتبط
| فایل | نقش |
|------|-----|
| `package.json` | نسخه‌ها، `overrides` پین React 18، اسکریپت `next lint` |
| `next.config.js` | کانفیگ — شامل `htmlLimitedBots: /.*/` (فیکس SEO، **نباید حذف شود**`output: 'standalone'`، CSP headers |
| `middleware.js` | تزریق هدر `x-pathname` برای canonical — در 16 باید به `proxy.js` تبدیل شود |
| `app/layout.js` | `generateMetadata` مبتنی بر host (multi-domain) |
| `lib/getStateInfo.js`, `lib/getCanonicalUrl.js`, `lib/auth.js` | خواندن `headers()`/`cookies()` — ۱۰ فایل از `next/headers` استفاده می‌کنند |
| `app/doctor/[slug]/page.js`, `app/clinic/[slug]/page.js`, `app/blog/[slug]/page.js`, `app/sitemap.js` | fetch با `next: { revalidate: 3600, tags: [...] }` |
| `Dockerfile`, `nixpacks.toml`, `liara.json` | deploy — خروجی standalone |
| `vitest.config.mjs`, `test/` | تست‌ها با vitest + @testing-library/react |
## وضعیت فعلی
```json
// package.json (بخش‌های مرتبط)
"scripts": {
"dev": "cross-env HOST=yazd-nobat.localhost PORT=3000 NODE_TLS_REJECT_UNAUTHORIZED=0 next dev",
"build": "next build",
"lint": "next lint"
},
"dependencies": {
"next": "^15.5.7",
"@next/third-parties": "^15.5.7",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"@mui/material": "^5.18.0",
"@mui/x-charts": "^7.29.1",
"@mui/x-date-pickers": "^7.29.4"
},
"overrides": {
"react": "^18.3.1",
"react-dom": "^18.3.1"
}
```
```js
// middleware.js — کل فایل
import { NextResponse } from 'next/server';
export function middleware(request) {
const response = NextResponse.next();
response.headers.set('x-pathname', request.nextUrl.pathname);
return response;
}
export const config = {
matcher: [
'/((?!api|_next/static|_next/image|favicon.ico|panel|dashboard|login|login-verify).*)',
],
};
```
نکات پیش‌بررسی‌شده (لازم نیست دوباره جستجو شوند):
- هیچ استفاده‌ای از `legacyBehavior`، `useFormState`، `publicRuntimeConfig`/`serverRuntimeConfig`، `getInitialProps`، `next/legacy/image`، prop سفارشی `quality` روی `<Image>`، custom webpack config، یا `export const dynamic/revalidate` در پروژه **وجود ندارد**.
- `await params` از قبل در همه صفحات dynamic رعایت شده (الگوی Next 15).
- هیچ فایل کانفیگ ESLint وجود ندارد (`next lint` بدون config اجرا می‌شده) و `eslint` در devDependencies نیست.
- Node محلی v22 است (Next 16 حداقل 20.9 می‌خواهد — OK).
## وظایف
### ۱. ساخت برنچ
```bash
cd nobat724_front
git checkout -b upgrade/next-16
```
همه commitها روی این برنچ. به `main` هیچ چیزی push نشود.
### ۲. ارتقای پکیج‌ها
```bash
npx @next/codemod@latest upgrade latest
```
اگر codemod به هر دلیل کامل اجرا نشد، دستی:
```bash
npm install next@latest react@latest react-dom@latest @next/third-parties@latest
```
- بخش `overrides` (پین React 18) از `package.json` **حذف شود** — دلیل پین، سازگاری قدیمی MUI بود؛ `@mui/material@5.18` و `@mui/x-*@7.29` هر دو peer-dep React 19 را پشتیبانی می‌کنند.
- اگر پکیج‌های قدیمی (`react-google-map-picker`، `react-images-uploading`، `aos`) خطای peer-dep برای React 19 دادند: اول `npm install --legacy-peer-deps` را امتحان کن و در گزارش نهایی صریح ذکر کن؛ سپس در مرحله تست، صفحات استفاده‌کننده از این پکیج‌ها را در مرورگر چک کن (map picker در پنل، آپلود عکس، انیمیشن‌های AOS صفحه اصلی).
- `@testing-library/react@16` و `vitest@2` با React 19 سازگارند؛ اگر تست‌ها خطای rendering دادند فقط نسخه `@testing-library/react` را به آخرین minor ارتقا بده.
### ۳. تبدیل `middleware.js` به `proxy.js`
در Next 16 نام `middleware` deprecated و جایگزینش `proxy` است. فایل `middleware.js` را به `proxy.js` تغییر نام بده و تابع را rename کن:
```js
// proxy.js
import { NextResponse } from 'next/server';
export function proxy(request) {
const response = NextResponse.next();
response.headers.set('x-pathname', request.nextUrl.pathname);
return response;
}
export const config = {
matcher: [
'/((?!api|_next/static|_next/image|favicon.ico|panel|dashboard|login|login-verify).*)',
],
};
```
**تست حیاتی بعد از این تغییر:** هدر `x-pathname` باید همچنان برسد — `curl -s http://yazd-nobat.localhost:3000/doctors | grep canonical` باید `https://nobat724.com/doctors` بدهد (اگر header نرسد، `getCanonicalUrl` مقدار `null` برمی‌گرداند و تگ canonical حذف می‌شود — این یعنی regression).
### ۴. جایگزینی `next lint`
`next lint` در Next 16 حذف شده. چون هیچ کانفیگ ESLint موجود نیست:
```bash
npm install -D eslint eslint-config-next
```
فایل `eslint.config.mjs` (flat config) بساز:
```js
import { FlatCompat } from '@eslint/eslintrc';
const compat = new FlatCompat({ baseDirectory: import.meta.dirname });
export default [
...compat.extends('next/core-web-vitals'),
];
```
و در `package.json`:
```json
"lint": "eslint app components lib services hooks context utils helper"
```
خطاهای lint موجود را فیکس نکن (خارج از scope) — فقط مطمئن شو دستور اجرا می‌شود؛ در صورت نیاز سطح خطاهای پرتکرار را در config به `warn` تنزل بده.
### ۵. Turbopack (پیش‌فرض جدید dev و build)
Next 16 هم `next dev` و هم `next build` را با Turbopack اجرا می‌کند. پروژه custom webpack config ندارد، پس انتظار سازگاری می‌رود. فقط verify کن:
- `npm run dev` بالا بیاید و صفحه اول، `/doctors`، `/doctor/[slug]` (یک uuid واقعی از خروجی `/doctors`) و `/panel` بدون خطای کنسول رندر شوند
- `npm run build` موفق شود و خروجی `standalone` تولید کند (برای Docker/liara لازم است — `ls .next/standalone`)
- استایل‌های emotion RTL (`stylis-plugin-rtl` در `mui/index.js` یا `ThemeRegistry`) درست کار کنند — یک صفحه را چک کن که دکمه‌ها/فرم‌ها RTL باشند
اگر Turbopack با emotion/styled-components مشکل داشت، ابتدا `compiler.styledComponents: true` را در `next.config.js` امتحان کن؛ فقط به‌عنوان آخرین راه‌حل build را با فلگ `--webpack` برگردان و دلیل را در گزارش بنویس.
### ۶. فعال‌سازی React Compiler
قابلیت پایدار نسخه 16 (و در 16.3 پشتیبانی Rust در Turbopack):
```bash
npm install -D babel-plugin-react-compiler
```
```js
// next.config.js
const nextConfig = {
reactCompiler: true,
// ...
};
```
بعد از فعال‌سازی، `npm run build` و تست‌های vitest باید سبز بمانند. اگر کامپایلر روی کامپوننت خاصی خطا داد (کامپوننت‌های کلاسی یا الگوهای غیراستاندارد)، همان کامپوننت را با `"use no memo"` مستثنا کن — کل قابلیت را خاموش نکن.
### ۷. Cache Components — ارزیابی محتاطانه (فعال‌سازی مشروط)
`cacheComponents: true` مدل کش جدید نسخه 16 است (`"use cache"`, `cacheLife`, `cacheTag`) و پیش‌نیاز Partial Prefetching در 16.3.
**هشدار معماری:** این پروژه multi-domain است — `generateMetadata` و layout و ده فایل دیگر به `headers()` (هدر `host`) وابسته‌اند؛ خروجی هر صفحه per-host متفاوت است. با `cacheComponents`، هر چیزی که `headers()` می‌خواند dynamic می‌ماند و کش کردنش باعث نشت محتوای یک شهر به دامنه شهر دیگر می‌شود.
ترتیب کار:
1. ابتدا **بدون** فعال‌سازی، fetchهای موجود را دست‌نخورده بگذار — الگوی `next: { revalidate: 3600, tags: [...] }` در Next 16 همچنان پشتیبانی می‌شود
2. `cacheComponents: true` را روی یک commit جدا فعال کن و `npm run build` بگیر
3. اگر build خطای «uncached data access» برای مسیرهای متکی به `headers()` داد و رفعش نیاز به `Suspense`گذاری گسترده یا `"use cache"` روی توابع host-dependent داشت → **فعال‌سازی را revert کن** و در گزارش نهایی بنویس چرا (این قابلیت برای این معماری فعلاً امن نیست)
4. اگر build پاس شد → با دو host تست کن (`HOST=yazd-nobat.localhost` و یک شهر دیگر از `data/city.json` مثلاً با تغییر موقت HOST در اسکریپت dev) و مطمئن شو title/description/canonical هر دامنه مستقل است
### ۸. تمیزکاری‌های کانفیگ نسخه 16
در `next.config.js`:
- `htmlLimitedBots: /.*/` **باید بماند** — فیکس عمدی برای رندر متادیتا داخل `<head>` است (streaming metadata خاموش). بعد از ارتقا با `curl -s -A "Mozilla/5.0" http://yazd-nobat.localhost:3000/ | python3 -c "import sys; h=sys.stdin.read(); e=h.find('</head>'); print('HEAD' if 0<=h.find('rel=\"canonical\"')<e else 'BODY')"` تأیید کن هنوز `HEAD` است
- `images.minimumCacheTTL` در 16 پیش‌فرض ۴ ساعت شده — نیازی به تغییر نیست، فقط بدان
- `env.DEV_MODE` و CSP headers و `output: 'standalone'` دست نخورند
### ۹. تست نهایی و commit
```bash
npm run test # همه تست‌های vitest سبز
npm run build # build موفق با Turbopack
npm run lint # اجرای eslint بدون crash
```
بعد smoke test دستی با dev server:
- `/` — صفحه اصلی، جستجو، تصاویر next/image
- `/doctors` و `/doctor/[uuid]` — لیست و صفحه پزشک + JSON-LD
- `/blogs` و `/blog/[slug]`
- `/login` — فلوی OTP (فقط رندر فرم؛ ارسال واقعی لازم نیست)
- view-source صفحه اول: متادیتا (`keywords`, `canonical`, `og:*`, `twitter:*`) داخل `<head>`
Commitها را مرحله‌ای بزن (ارتقا پکیج‌ها / proxy / eslint / react compiler / cache components هرکدام جدا) تا در صورت مشکل، revert تکی ممکن باشد.
## نکات مهم
- **برنچ:** همه‌چیز روی `upgrade/next-16`؛ merge به `main` با کاربر است، خودت merge نکن.
- **SEO regression خط قرمز است:** canonical به `https://nobat724.com/<path>`، متادیتا در `<head>`، `robots.js` و `sitemap.js` باید عیناً مثل قبل کار کنند.
- ده فایل از `next/headers` استفاده می‌کنند — همه `await headers()` هستند (الگوی 15)؛ در 16 هم همین درست است.
- `services/response.js` قرارداد API با backend (`clinicpro`) است — این ارتقا نباید هیچ تغییری در آن بدهد.
- اسکریپت dev به `NODE_TLS_REJECT_UNAUTHORIZED=0` و `HOST` سفارشی وابسته است — بدون تغییر بماند.
- اگر در حین کار مستندات لازم شد: راهنمای رسمی مهاجرت `https://nextjs.org/docs/app/guides/upgrading/version-16` و بلاگ‌های `nextjs.org/blog/next-16`, `next-16-1`, `next-16-2`, و 16.3.
- بعد از اتمام: `graphify update .` در روت workspace اجرا شود.
+25
View File
@@ -0,0 +1,25 @@
import next from 'eslint-config-next/core-web-vitals';
const eslintConfig = [
...next,
{
ignores: ['.next/**', 'node_modules/**', 'public/**'],
},
{
// قوانین پرتکراری که با ارتقا به eslint-config-next@16 / react-hooks@7 سخت‌گیرتر شدند
// و در کد موجود نقض می‌شوند؛ برای عبور از ارتقا به warn تنزل داده شده‌اند.
// پاک‌سازی این warningها خارج از scope این ارتقاست.
rules: {
'react/jsx-key': 'warn',
'react-hooks/set-state-in-effect': 'warn',
'react-hooks/exhaustive-deps': 'warn',
'react-hooks/refs': 'warn',
'react-hooks/purity': 'warn',
'react-hooks/immutability': 'warn',
'jsx-a11y/alt-text': 'warn',
'@next/next/no-img-element': 'warn',
},
},
];
export default eslintConfig;
+367
View File
@@ -0,0 +1,367 @@
{
"0": "Community 0",
"1": "Community 1",
"2": "Community 2",
"3": "Community 3",
"4": "Community 4",
"5": "Community 5",
"6": "Community 6",
"7": "Community 7",
"8": "Community 8",
"9": "Community 9",
"10": "Community 10",
"11": "Community 11",
"12": "Community 12",
"13": "Community 13",
"14": "Community 14",
"15": "Community 15",
"16": "Community 16",
"17": "Community 17",
"18": "Community 18",
"19": "Community 19",
"20": "Community 20",
"21": "Community 21",
"22": "Community 22",
"23": "Community 23",
"24": "Community 24",
"25": "Community 25",
"26": "Community 26",
"27": "Community 27",
"28": "Community 28",
"29": "Community 29",
"30": "Community 30",
"31": "Community 31",
"32": "Community 32",
"33": "Community 33",
"34": "Community 34",
"35": "Community 35",
"36": "Community 36",
"37": "Community 37",
"38": "Community 38",
"39": "Community 39",
"40": "Community 40",
"41": "Community 41",
"42": "Community 42",
"43": "Community 43",
"44": "Community 44",
"45": "Community 45",
"46": "Community 46",
"47": "Community 47",
"48": "Community 48",
"49": "Community 49",
"50": "Community 50",
"51": "Community 51",
"52": "Community 52",
"53": "Community 53",
"54": "Community 54",
"55": "Community 55",
"56": "Community 56",
"57": "Community 57",
"58": "Community 58",
"59": "Community 59",
"60": "Community 60",
"61": "Community 61",
"62": "Community 62",
"63": "Community 63",
"64": "Community 64",
"65": "Community 65",
"66": "Community 66",
"67": "Community 67",
"68": "Community 68",
"69": "Community 69",
"70": "Community 70",
"71": "Community 71",
"72": "Community 72",
"73": "Community 73",
"74": "Community 74",
"75": "Community 75",
"76": "Community 76",
"77": "Community 77",
"78": "Community 78",
"79": "Community 79",
"80": "Community 80",
"81": "Community 81",
"82": "Community 82",
"83": "Community 83",
"84": "Community 84",
"85": "Community 85",
"86": "Community 86",
"87": "Community 87",
"88": "Community 88",
"89": "Community 89",
"90": "Community 90",
"91": "Community 91",
"92": "Community 92",
"93": "Community 93",
"94": "Community 94",
"95": "Community 95",
"96": "Community 96",
"97": "Community 97",
"98": "Community 98",
"99": "Community 99",
"100": "Community 100",
"101": "Community 101",
"102": "Community 102",
"103": "Community 103",
"104": "Community 104",
"105": "Community 105",
"106": "Community 106",
"107": "Community 107",
"108": "Community 108",
"109": "Community 109",
"110": "Community 110",
"111": "Community 111",
"112": "Community 112",
"113": "Community 113",
"114": "Community 114",
"115": "Community 115",
"116": "Community 116",
"117": "Community 117",
"118": "Community 118",
"119": "Community 119",
"120": "Community 120",
"121": "Community 121",
"122": "Community 122",
"123": "Community 123",
"124": "Community 124",
"125": "Community 125",
"126": "Community 126",
"127": "Community 127",
"128": "Community 128",
"129": "Community 129",
"130": "Community 130",
"131": "Community 131",
"132": "Community 132",
"133": "Community 133",
"134": "Community 134",
"135": "Community 135",
"136": "Community 136",
"137": "Community 137",
"138": "Community 138",
"139": "Community 139",
"140": "Community 140",
"141": "Community 141",
"142": "Community 142",
"143": "Community 143",
"144": "Community 144",
"145": "Community 145",
"146": "Community 146",
"147": "Community 147",
"148": "Community 148",
"149": "Community 149",
"150": "Community 150",
"151": "Community 151",
"152": "Community 152",
"153": "Community 153",
"154": "Community 154",
"155": "Community 155",
"156": "Community 156",
"157": "Community 157",
"158": "Community 158",
"159": "Community 159",
"160": "Community 160",
"161": "Community 161",
"162": "Community 162",
"163": "Community 163",
"164": "Community 164",
"165": "Community 165",
"166": "Community 166",
"167": "Community 167",
"168": "Community 168",
"169": "Community 169",
"170": "Community 170",
"171": "Community 171",
"172": "Community 172",
"173": "Community 173",
"174": "Community 174",
"175": "Community 175",
"176": "Community 176",
"177": "Community 177",
"178": "Community 178",
"179": "Community 179",
"180": "Community 180",
"181": "Community 181",
"182": "Community 182",
"183": "Community 183",
"184": "Community 184",
"185": "Community 185",
"186": "Community 186",
"187": "Community 187",
"188": "Community 188",
"189": "Community 189",
"190": "Community 190",
"191": "Community 191",
"192": "Community 192",
"193": "Community 193",
"194": "Community 194",
"195": "Community 195",
"196": "Community 196",
"197": "Community 197",
"198": "Community 198",
"199": "Community 199",
"200": "Community 200",
"201": "Community 201",
"202": "Community 202",
"203": "Community 203",
"204": "Community 204",
"205": "Community 205",
"206": "Community 206",
"207": "Community 207",
"208": "Community 208",
"209": "Community 209",
"210": "Community 210",
"211": "Community 211",
"212": "Community 212",
"213": "Community 213",
"214": "Community 214",
"215": "Community 215",
"216": "Community 216",
"217": "Community 217",
"218": "Community 218",
"219": "Community 219",
"220": "Community 220",
"221": "Community 221",
"222": "Community 222",
"223": "Community 223",
"224": "Community 224",
"225": "Community 225",
"226": "Community 226",
"227": "Community 227",
"228": "Community 228",
"229": "Community 229",
"230": "Community 230",
"231": "Community 231",
"232": "Community 232",
"233": "Community 233",
"234": "Community 234",
"235": "Community 235",
"236": "Community 236",
"237": "Community 237",
"238": "Community 238",
"239": "Community 239",
"240": "Community 240",
"241": "Community 241",
"242": "Community 242",
"243": "Community 243",
"244": "Community 244",
"245": "Community 245",
"246": "Community 246",
"247": "Community 247",
"248": "Community 248",
"249": "Community 249",
"250": "Community 250",
"251": "Community 251",
"252": "Community 252",
"253": "Community 253",
"254": "Community 254",
"255": "Community 255",
"256": "Community 256",
"257": "Community 257",
"258": "Community 258",
"259": "Community 259",
"260": "Community 260",
"261": "Community 261",
"262": "Community 262",
"263": "Community 263",
"264": "Community 264",
"265": "Community 265",
"266": "Community 266",
"267": "Community 267",
"268": "Community 268",
"269": "Community 269",
"270": "Community 270",
"271": "Community 271",
"272": "Community 272",
"273": "Community 273",
"274": "Community 274",
"275": "Community 275",
"276": "Community 276",
"277": "Community 277",
"278": "Community 278",
"279": "Community 279",
"280": "Community 280",
"281": "Community 281",
"282": "Community 282",
"283": "Community 283",
"284": "Community 284",
"285": "Community 285",
"286": "Community 286",
"287": "Community 287",
"288": "Community 288",
"289": "Community 289",
"290": "Community 290",
"291": "Community 291",
"292": "Community 292",
"293": "Community 293",
"294": "Community 294",
"295": "Community 295",
"296": "Community 296",
"297": "Community 297",
"298": "Community 298",
"299": "Community 299",
"300": "Community 300",
"301": "Community 301",
"302": "Community 302",
"303": "Community 303",
"304": "Community 304",
"305": "Community 305",
"306": "Community 306",
"307": "Community 307",
"308": "Community 308",
"309": "Community 309",
"310": "Community 310",
"311": "Community 311",
"312": "Community 312",
"313": "Community 313",
"314": "Community 314",
"315": "Community 315",
"316": "Community 316",
"317": "Community 317",
"318": "Community 318",
"319": "Community 319",
"320": "Community 320",
"321": "Community 321",
"322": "Community 322",
"323": "Community 323",
"324": "Community 324",
"325": "Community 325",
"326": "Community 326",
"327": "Community 327",
"328": "Community 328",
"329": "Community 329",
"330": "Community 330",
"331": "Community 331",
"332": "Community 332",
"333": "Community 333",
"334": "Community 334",
"335": "Community 335",
"336": "Community 336",
"337": "Community 337",
"338": "Community 338",
"339": "Community 339",
"340": "Community 340",
"341": "Community 341",
"342": "Community 342",
"343": "Community 343",
"344": "Community 344",
"345": "Community 345",
"346": "Community 346",
"347": "Community 347",
"348": "Community 348",
"349": "Community 349",
"350": "Community 350",
"351": "Community 351",
"352": "Community 352",
"353": "Community 353",
"354": "Community 354",
"355": "Community 355",
"356": "Community 356",
"357": "Community 357",
"358": "Community 358",
"359": "Community 359",
"360": "Community 360",
"361": "Community 361",
"362": "Community 362",
"363": "Community 363",
"364": "Community 364"
}
+1
View File
@@ -0,0 +1 @@
nobat724_front
+578
View File
@@ -0,0 +1,578 @@
# Graph Report - nobat724_front (2026-07-06)
## Corpus Check
- 592 files · ~534,127 words
- Verdict: corpus is large enough that graph structure adds value.
## Summary
- 2012 nodes · 1996 edges · 365 communities (336 shown, 29 thin omitted)
- Extraction: 95% EXTRACTED · 5% INFERRED · 0% AMBIGUOUS · INFERRED: 98 edges (avg confidence: 0.8)
- Token cost: 0 input · 0 output
## Graph Freshness
- Built from commit: `fd5935a1`
- Run `git rev-parse HEAD` and compare to check if the graph is stale.
- Run `graphify update .` after code changes (no API cost).
## Community Hubs (Navigation)
- [[_COMMUNITY_Community 0|Community 0]]
- [[_COMMUNITY_Community 1|Community 1]]
- [[_COMMUNITY_Community 2|Community 2]]
- [[_COMMUNITY_Community 3|Community 3]]
- [[_COMMUNITY_Community 4|Community 4]]
- [[_COMMUNITY_Community 5|Community 5]]
- [[_COMMUNITY_Community 6|Community 6]]
- [[_COMMUNITY_Community 7|Community 7]]
- [[_COMMUNITY_Community 8|Community 8]]
- [[_COMMUNITY_Community 9|Community 9]]
- [[_COMMUNITY_Community 10|Community 10]]
- [[_COMMUNITY_Community 11|Community 11]]
- [[_COMMUNITY_Community 12|Community 12]]
- [[_COMMUNITY_Community 13|Community 13]]
- [[_COMMUNITY_Community 14|Community 14]]
- [[_COMMUNITY_Community 15|Community 15]]
- [[_COMMUNITY_Community 16|Community 16]]
- [[_COMMUNITY_Community 17|Community 17]]
- [[_COMMUNITY_Community 18|Community 18]]
- [[_COMMUNITY_Community 19|Community 19]]
- [[_COMMUNITY_Community 20|Community 20]]
- [[_COMMUNITY_Community 21|Community 21]]
- [[_COMMUNITY_Community 22|Community 22]]
- [[_COMMUNITY_Community 23|Community 23]]
- [[_COMMUNITY_Community 24|Community 24]]
- [[_COMMUNITY_Community 25|Community 25]]
- [[_COMMUNITY_Community 26|Community 26]]
- [[_COMMUNITY_Community 27|Community 27]]
- [[_COMMUNITY_Community 28|Community 28]]
- [[_COMMUNITY_Community 29|Community 29]]
- [[_COMMUNITY_Community 30|Community 30]]
- [[_COMMUNITY_Community 31|Community 31]]
- [[_COMMUNITY_Community 32|Community 32]]
- [[_COMMUNITY_Community 33|Community 33]]
- [[_COMMUNITY_Community 34|Community 34]]
- [[_COMMUNITY_Community 35|Community 35]]
- [[_COMMUNITY_Community 36|Community 36]]
- [[_COMMUNITY_Community 37|Community 37]]
- [[_COMMUNITY_Community 38|Community 38]]
- [[_COMMUNITY_Community 39|Community 39]]
- [[_COMMUNITY_Community 40|Community 40]]
- [[_COMMUNITY_Community 41|Community 41]]
- [[_COMMUNITY_Community 42|Community 42]]
- [[_COMMUNITY_Community 43|Community 43]]
- [[_COMMUNITY_Community 44|Community 44]]
- [[_COMMUNITY_Community 45|Community 45]]
- [[_COMMUNITY_Community 46|Community 46]]
- [[_COMMUNITY_Community 47|Community 47]]
- [[_COMMUNITY_Community 48|Community 48]]
- [[_COMMUNITY_Community 49|Community 49]]
- [[_COMMUNITY_Community 50|Community 50]]
- [[_COMMUNITY_Community 51|Community 51]]
- [[_COMMUNITY_Community 52|Community 52]]
- [[_COMMUNITY_Community 53|Community 53]]
- [[_COMMUNITY_Community 54|Community 54]]
- [[_COMMUNITY_Community 55|Community 55]]
- [[_COMMUNITY_Community 56|Community 56]]
- [[_COMMUNITY_Community 57|Community 57]]
- [[_COMMUNITY_Community 58|Community 58]]
- [[_COMMUNITY_Community 59|Community 59]]
- [[_COMMUNITY_Community 60|Community 60]]
- [[_COMMUNITY_Community 61|Community 61]]
- [[_COMMUNITY_Community 62|Community 62]]
- [[_COMMUNITY_Community 63|Community 63]]
- [[_COMMUNITY_Community 64|Community 64]]
- [[_COMMUNITY_Community 65|Community 65]]
- [[_COMMUNITY_Community 66|Community 66]]
- [[_COMMUNITY_Community 67|Community 67]]
- [[_COMMUNITY_Community 68|Community 68]]
- [[_COMMUNITY_Community 69|Community 69]]
- [[_COMMUNITY_Community 70|Community 70]]
- [[_COMMUNITY_Community 71|Community 71]]
- [[_COMMUNITY_Community 72|Community 72]]
- [[_COMMUNITY_Community 73|Community 73]]
- [[_COMMUNITY_Community 74|Community 74]]
- [[_COMMUNITY_Community 75|Community 75]]
- [[_COMMUNITY_Community 76|Community 76]]
- [[_COMMUNITY_Community 77|Community 77]]
- [[_COMMUNITY_Community 78|Community 78]]
- [[_COMMUNITY_Community 79|Community 79]]
- [[_COMMUNITY_Community 80|Community 80]]
- [[_COMMUNITY_Community 81|Community 81]]
- [[_COMMUNITY_Community 82|Community 82]]
- [[_COMMUNITY_Community 83|Community 83]]
- [[_COMMUNITY_Community 84|Community 84]]
- [[_COMMUNITY_Community 85|Community 85]]
- [[_COMMUNITY_Community 86|Community 86]]
- [[_COMMUNITY_Community 87|Community 87]]
- [[_COMMUNITY_Community 88|Community 88]]
- [[_COMMUNITY_Community 89|Community 89]]
- [[_COMMUNITY_Community 90|Community 90]]
- [[_COMMUNITY_Community 91|Community 91]]
- [[_COMMUNITY_Community 92|Community 92]]
- [[_COMMUNITY_Community 93|Community 93]]
- [[_COMMUNITY_Community 94|Community 94]]
- [[_COMMUNITY_Community 95|Community 95]]
- [[_COMMUNITY_Community 96|Community 96]]
- [[_COMMUNITY_Community 97|Community 97]]
- [[_COMMUNITY_Community 98|Community 98]]
- [[_COMMUNITY_Community 99|Community 99]]
- [[_COMMUNITY_Community 100|Community 100]]
- [[_COMMUNITY_Community 101|Community 101]]
- [[_COMMUNITY_Community 102|Community 102]]
- [[_COMMUNITY_Community 103|Community 103]]
- [[_COMMUNITY_Community 104|Community 104]]
- [[_COMMUNITY_Community 105|Community 105]]
- [[_COMMUNITY_Community 106|Community 106]]
- [[_COMMUNITY_Community 107|Community 107]]
- [[_COMMUNITY_Community 108|Community 108]]
- [[_COMMUNITY_Community 109|Community 109]]
- [[_COMMUNITY_Community 110|Community 110]]
- [[_COMMUNITY_Community 111|Community 111]]
- [[_COMMUNITY_Community 112|Community 112]]
- [[_COMMUNITY_Community 113|Community 113]]
- [[_COMMUNITY_Community 116|Community 116]]
- [[_COMMUNITY_Community 118|Community 118]]
- [[_COMMUNITY_Community 119|Community 119]]
- [[_COMMUNITY_Community 120|Community 120]]
- [[_COMMUNITY_Community 121|Community 121]]
- [[_COMMUNITY_Community 122|Community 122]]
- [[_COMMUNITY_Community 124|Community 124]]
- [[_COMMUNITY_Community 195|Community 195]]
- [[_COMMUNITY_Community 339|Community 339]]
- [[_COMMUNITY_Community 347|Community 347]]
- [[_COMMUNITY_Community 348|Community 348]]
## God Nodes (most connected - your core abstractions)
1. `getStateInfo()` - 23 edges
2. `🏥 نوبت724 (Nobat724) - سیستم نوبت‌دهی آنلاین پزشکی` - 19 edges
3. `imageUrl()` - 15 edges
4. `Dashboard()` - 10 edges
5. `بهینه‌سازی SEO تک‌تک شهرها در city.json (سطح حرفه‌ای)` - 10 edges
6. `بازطراحی حرفه‌ای پوستر اشتراک‌گذاری پزشک (دانلود)` - 10 edges
7. `وظایف` - 10 edges
8. `وظایف` - 10 edges
9. `وظایف` - 10 edges
10. `Architecture Overview` - 10 edges
## Surprising Connections (you probably didn't know these)
- `AboutUsPage()` --calls--> `getStateInfo()` [INFERRED]
components/aboutUs/index.js → lib/getStateInfo.js
- `ContactUsPage()` --calls--> `getStateInfo()` [INFERRED]
components/contactUs/index.js → lib/getStateInfo.js
- `SearchBar()` --calls--> `getStateInfo()` [INFERRED]
components/home/search/index.js → lib/getStateInfo.js
- `StLayout()` --calls--> `getStateInfo()` [INFERRED]
components/layout/StLayout.js → lib/getStateInfo.js
- `generateMetadata()` --calls--> `getStateInfo()` [INFERRED]
app/about-us/page.js → lib/getStateInfo.js
## Import Cycles
- None detected.
## Communities (365 total, 29 thin omitted)
### Community 0 - "Community 0"
Cohesion: 0.05
Nodes (27): BgGray(), ButtonMenu(), Col(), ModalLogout(), Footer(), head, LogoNamad(), Namads (+19 more)
### Community 1 - "Community 1"
Cohesion: 0.07
Nodes (23): Head(), Head(), HeadTab(), convertTimestampToJalali(), convertTimestampToTime(), ButtonData(), DetailLg(), DetailSm() (+15 more)
### Community 2 - "Community 2"
Cohesion: 0.04
Nodes (45): dependencies, aos, axios, @casl/ability, @casl/react, date-fns, dayjs, @emotion/cache (+37 more)
### Community 3 - "Community 3"
Cohesion: 0.06
Nodes (21): ClinicsPage(), ProvinceContext, ProvinceProvider(), Probe(), useProvince(), Content(), Form(), SubmitData() (+13 more)
### Community 4 - "Community 4"
Cohesion: 0.07
Nodes (21): ContentDetail(), About(), ListBime(), Services(), Specialties(), TextDetail(), listTab, AddComment() (+13 more)
### Community 5 - "Community 5"
Cohesion: 0.08
Nodes (18): AppointmentList(), ItemAppointment(), AboutDcotor(), DetailDoctor(), Link(), listLink, List(), VAZIR_WEIGHTS (+10 more)
### Community 6 - "Community 6"
Cohesion: 0.07
Nodes (16): Dashboard(), metadata, defineAbilitiesFor(), getUser(), formatToman(), rialToToman(), buildPatientUser(), safeJsonParse() (+8 more)
### Community 8 - "Community 8"
Cohesion: 0.07
Nodes (28): devDependencies, babel-plugin-react-compiler, cross-env, eslint, eslint-config-next, @eslint/eslintrc, jsdom, prettier (+20 more)
### Community 9 - "Community 9"
Cohesion: 0.07
Nodes (27): `app/appointment/[doctorId]/page.js`, `app/component/date/dateTime/hours/List.js`, `app/component/date/dateTime/index.js`, `components/appointment/detail/SubmitData.js`, `components/appointment/index.js` (خواندن پروفایل), `components/appointment/paying/index.js`, `services/response.js`, بازنویسی صفحه‌ی گرفتن نوبت (`/appointment/[doctorId]`) برای هم‌خوانی با API واقعی (+19 more)
### Community 10 - "Community 10"
Cohesion: 0.08
Nodes (25): زمینه, فایل‌های مرتبط, مشکل / هدف, ممیزی و رفع کامل Technical SEO با محوریت معماری چند-دامنه‌ای, نقش, نکات مهم, وضعیت فعلی (یافته‌های ممیزی اولیه — از کد واقعی), وظایف (+17 more)
### Community 11 - "Community 11"
Cohesion: 0.13
Nodes (10): Container(), Content(), defaultData, Date(), Hour(), Address(), Head(), Location() (+2 more)
### Community 12 - "Community 12"
Cohesion: 0.10
Nodes (20): `app/doctors/page.js` (باگ نوع), `app/specialties/page.js`, `components/doctors/index.js` (باگ نوع در defaultFilter), `context/ProvinceProvider.js`, `lib/getStateInfo.js`, `services/response.js` (بدون تغییر — فقط برای مرجع), دامنهٔ ریشهٔ nobat724.com نباید مثل «شهر» رفتار کند, زمینه (+12 more)
### Community 13 - "Community 13"
Cohesion: 0.10
Nodes (20): `app/doctor/[slug]/page.js` — دو فراخوانی تکراری, `app/doctors/page.js` — بدون og:images، بدون cache, `lib/req.js` — مشکل اصلی caching, `middleware.js` — اجرا روی همه مسیرها, بازبینی کامل Rendering Strategy، SEO، Performance و امنیت (Next.js 15), زمینه, فایل‌های مرتبط, نکات مهم (+12 more)
### Community 14 - "Community 14"
Cohesion: 0.15
Nodes (10): Call(), Links(), Connect(), ContentContact(), FieldLabel(), ContactUsPage(), ArrowLeftC(), CallC() (+2 more)
### Community 15 - "Community 15"
Cohesion: 0.14
Nodes (10): Chart(), ProgressAll(), fallbackLabels, ProgressDetail(), Form(), Content(), Rates(), numberToArStyle() (+2 more)
### Community 16 - "Community 16"
Cohesion: 0.14
Nodes (10): Head(), AboutUsPage(), ourServices, Services(), SearchBar(), TickOrangeA(), UnderlineLG(), ButtonFilter() (+2 more)
### Community 17 - "Community 17"
Cohesion: 0.11
Nodes (18): باگ ۱ — شماره موبایل با `09` اضافی, باگ ۲ — redirect به `/login` بعد از refresh صفحه, زمینه, علت, علت احتمالی, فایل‌های مرتبط, فیکس, فیکس دو باگ در فلو login (+10 more)
### Community 18 - "Community 18"
Cohesion: 0.11
Nodes (17): بهینه‌سازی SEO تک‌تک شهرها در city.json (سطح حرفه‌ای), زمینه, فایل‌های مرتبط, فهرست ۳۴ رکورد (همه باید پردازش شوند), مشکل / هدف, نقش, نکات مهم, وضعیت فعلی (+9 more)
### Community 19 - "Community 19"
Cohesion: 0.11
Nodes (17): باگ ۱ — SubmitData: خواندن نتیجه‌ی نوبت, باگ ۲ — paying: frontend_address و config, باگ ۳ — payment/[uuid]/page.js, رفع جریان پرداخت و اطلاعات حساب در نوبت‌گیری آنلاین, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم (+9 more)
### Community 20 - "Community 20"
Cohesion: 0.11
Nodes (17): ارتقای Next.js از 15 به 16 (آخرین نسخه) + فعال‌سازی امکانات جدید, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی, وظایف, پروژه (+9 more)
### Community 21 - "Community 21"
Cohesion: 0.24
Nodes (14): getCurrentDomain(), robots(), cityFilterParams(), fetchAllPages(), getBlogUrls(), getCityScope(), getClinicUrls(), getCurrentDomain() (+6 more)
### Community 22 - "Community 22"
Cohesion: 0.12
Nodes (16): `app/appointment/[doctorId]/page.js` — disabledDates خالی, `app/component/date/datePicker/index.js` — مصرف disabledDates, `services/response.js` — توابع slot موجود, زمینه, فایل‌های مرتبط, قرارداد endpoint جدید backend (مرجع), مشکل / هدف, نمایش روزهای تعطیل/غیرقابل‌انتخاب روی تقویم صفحه‌ی نوبت + احترام به بازه‌ی رزرو (+8 more)
### Community 23 - "Community 23"
Cohesion: 0.12
Nodes (16): `detail/index.js` — دکمه‌ی mock «برای فرد دیگر», `paying/index.js` — تایمر محلی ۶۰۰ ثانیه (قلابی), `SubmitData.js` — بدنه‌ی نوبت بدون بیمار, زمینه, فایل‌های مرتبط, فلوی نوبت‌گیری: قفل واقعی ۱۵دقیقه‌ای، فرم «نوبت برای شخص دیگر»، و UX وضعیت‌محور, قرارداد backend (بعد از اجرای پرامپت همتا), مشکل / هدف (+8 more)
### Community 24 - "Community 24"
Cohesion: 0.12
Nodes (16): اتصال پنل نماینده و داشبورد کاربر به API واقعی (حذف داده‌های mock), داشبورد کاربر: کاملاً mock, زمینه, فایل‌های مرتبط, لایه‌ی API موجود (در `services/response.js`), مشکل / هدف, نکات مهم, وضعیت فعلی (+8 more)
### Community 25 - "Community 25"
Cohesion: 0.12
Nodes (16): `app/dashboard/page.js` (تبدیل دستی ناهماهنگ), `app/payment/[uuid]/page.js`, `components/appointment/paying/index.js`, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, واحد پول = تومان در سایت عمومی (نمایش ÷۱۰ / ورودی ×۱۰) — API ریال می‌ماند (+8 more)
### Community 26 - "Community 26"
Cohesion: 0.12
Nodes (16): بازطراحی حرفه‌ای پوستر اشتراک‌گذاری پزشک (دانلود), داده‌های در دسترس, زمینه, فایل‌های مرتبط, نقش, نکات مهم, هدف, وضعیت فعلی (+8 more)
### Community 27 - "Community 27"
Cohesion: 0.12
Nodes (16): `app/dashboard/page.js`, `Head.js`, `services/response.js` — URLهای ناموجود, رفع باگ‌های داشبورد کاربر: کوکی uuid اشتباه، URL غلط نوبت‌ها/پرداخت‌ها، و crash هدر, ریشه‌ی اصلی کوکی `uuid`, زمینه, فایل‌های مرتبط, نکات مهم (+8 more)
### Community 28 - "Community 28"
Cohesion: 0.12
Nodes (16): دیپلوی nobat724_front روی Liara (پلتفرم Next.js), زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی, وظایف, پروژه (+8 more)
### Community 29 - "Community 29"
Cohesion: 0.13
Nodes (8): generateMetadata(), generateMetadata(), Appointment(), metadata, getStateInfo(), ContentLogin(), generateMetadata(), Specialties()
### Community 30 - "Community 30"
Cohesion: 0.12
Nodes (15): اتصال دقیق همه‌ی تب‌های داشبورد کاربر به داده‌ی واقعی backend, ذخیره در `detailUser/index.js`, زمینه, فایل‌های مرتبط, قرارداد backend (از `user-profile.md` و entity `toArray`), مشکل / هدف, مپینگ غلط بیمه در `information/index.js`, نکات مهم (+7 more)
### Community 31 - "Community 31"
Cohesion: 0.12
Nodes (15): `components/doctor/detailDoctor/List.js` (بخش دانلود), `components/doctor/poster/ImageProfile.js`, `components/doctor/poster/QrImg.js` (خلاصه), رفع مشکل عکس نادرست در پوستر دانلودی صفحه پزشک (اشتراک‌گذاری), زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم (+7 more)
### Community 32 - "Community 32"
Cohesion: 0.12
Nodes (15): باگ ۱ — مودال شهر/استان دیر بسته می‌شود, باگ ۲ — دسته‌بندی کار نمی‌کند, باگ ۳ — کندی کلی, زمینه, فایل‌های مرتبط, فیکس کندی و باگ‌های فیلتر صفحه پزشکان, نکات مهم, وضعیت فعلی (+7 more)
### Community 33 - "Community 33"
Cohesion: 0.12
Nodes (15): راه‌اندازی تست و نوشتن تست‌سوئیت برای سایت عمومی (nobat724_front), زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی, وظایف, پروژه (+7 more)
### Community 34 - "Community 34"
Cohesion: 0.18
Nodes (7): Tabs(), listTab, nameHours, SendAppo(), Hours(), List(), Loading()
### Community 35 - "Community 35"
Cohesion: 0.13
Nodes (14): تطبیق سایت عمومی با تغییرات API برنچ `backend-audit`, تغییر, جدول تغییرات API مرتبط با سایت عمومی, رفتار جدید backend, زمینه, 🔴 مشکل اصلی: rotation توکن refresh (`POST /oauth/token/refresh`), نکات مهم, وضعیت فعلی (`app/doctor/[slug]/page.js`) (+6 more)
### Community 36 - "Community 36"
Cohesion: 0.13
Nodes (14): `app/doctor/[slug]/page.js` — schema فعلی (ناقص), `app/sitemap.js` — فعلاً یک فایل واحد, SEO پیشرفته صفحه پزشک: Schema کامل، Sitelinks، Knowledge Panel، Local SEO, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی (+6 more)
### Community 37 - "Community 37"
Cohesion: 0.13
Nodes (14): `app/component/ItemDoctor.js` (حوالی خط ۸۴), `components/doctor/appointmentList/index.js` (نوار موبایل، خط ۱۶–۳۴), `components/doctor/appointmentList/ItemAppointment.js` (خط ۳۶–۵۸), رفع نمایش نوبت آزاد و دکمه نوبت برای پزشک با نوبت‌دهی غیرفعال, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم (+6 more)
### Community 38 - "Community 38"
Cohesion: 0.13
Nodes (14): `header/Content.js` — تصمیم فقط بر اساس prop سرور, `StLayout.js` — مقدار اولیه از کوکی سرور, رفع نمایش «ورود | ثبت‌نام» در هدر با وجود لاگین‌بودن کاربر, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی (کد واقعی) (+6 more)
### Community 39 - "Community 39"
Cohesion: 0.14
Nodes (12): Architecture Overview, Authentication & Authorization, Commands, Data Fetching, Doctor & Clinic Slugs, Environment Variables, JSON-LD Structured Data, Key Data Files (+4 more)
### Community 40 - "Community 40"
Cohesion: 0.22
Nodes (9): Field(), Form(), Content(), DateBirthday(), blood_group, gender, job, marital_status (+1 more)
### Community 41 - "Community 41"
Cohesion: 0.14
Nodes (13): `SendReq.js``getInfo` (باگ‌دار), رفع ماندن صفحه‌ی لاگین بعد از وارد کردن کد OTP (نشست ساخته نمی‌شود), زمینه, فایل‌های مرتبط, قرارداد واقعی `GET /oauth/userinfo` (از `clinicpro/docs/api/auth.md`), مشکل / هدف, نکات مهم, وضعیت فعلی (کد واقعی) (+5 more)
### Community 42 - "Community 42"
Cohesion: 0.14
Nodes (13): اتصال UI غنیِ نظرات/امتیاز صفحه پزشک به قرارداد جدید بک‌اند, زمینه, فایل‌های مرتبط (UI موجود که باید وصل شود), قرارداد بک‌اند (مرجع — از پرامپت همتا), نکات مهم, وظایف, پروژه, ۱. fetch تجمیع امتیاز در صفحه و عبور prop (+5 more)
### Community 43 - "Community 43"
Cohesion: 0.14
Nodes (13): `components/appointment/index.js` — هندل ویژه‌ی 404, `SubmitData.js` — انتخاب POST یا PATCH بر اساس وجود `uuid`, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, هم‌خوان‌کردن مصرف پروفایل کاربر با endpoint اصلاح‌شده (بدون 404 برای کاربر جدید), وضعیت فعلی (کد واقعی) (+5 more)
### Community 44 - "Community 44"
Cohesion: 0.14
Nodes (13): `hours/List.js`, آبجکت اسلات (از `adaptSlots` / API), تأیید و سخت‌سازی غیرفعال‌بودن اسلات‌های گذشته در صفحه‌ی نوبت, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی (کد واقعی) (+5 more)
### Community 45 - "Community 45"
Cohesion: 0.26
Nodes (11): generateMetadata(), generateMetadata(), RootLayout(), imageUrl(), normalizeBlog(), safeJsonLd(), Blog(), Clinic() (+3 more)
### Community 46 - "Community 46"
Cohesion: 0.22
Nodes (6): Messages(), Message(), Head(), listTab, UserAccountPage(), NotfoundDashboard()
### Community 47 - "Community 47"
Cohesion: 0.15
Nodes (12): Schema.org کامل و Knowledge Panel برای صفحه کلینیک, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی API کلینیک, وظایف, پروژه (+4 more)
### Community 48 - "Community 48"
Cohesion: 0.15
Nodes (12): زمینه, سخت‌سازی امنیتی سایت عمومی: ذخیره‌ی توکن، XSS، هدرها، client_secret, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی (کد واقعی), وظایف, پروژه (+4 more)
### Community 49 - "Community 49"
Cohesion: 0.15
Nodes (12): جریان پرداخت سمت کلاینت — انتقال از طریق بک‌اند + صفحات نتیجه (Frontend), زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی, وظایف, پروژه (+4 more)
### Community 50 - "Community 50"
Cohesion: 0.15
Nodes (12): زمینه, فایل‌های مرتبط, مشکل / هدف, نمایش تعداد پزشکان هر تخصص در صفحه /specialties, نکات مهم, وضعیت فعلی (کد واقعی), وظایف, پروژه (+4 more)
### Community 51 - "Community 51"
Cohesion: 0.19
Nodes (9): Card(), PAYMENT_STATUS, TYPE_LABELS, Head(), listTab, Transactions(), List(), PAYMENT_STATUS (+1 more)
### Community 52 - "Community 52"
Cohesion: 0.24
Nodes (5): OTPForm(), ArrowRightS(), EditLogin(), Recode(), SendReq()
### Community 53 - "Community 53"
Cohesion: 0.17
Nodes (11): اصلاح جریان پرداخت: انتخاب فقط درگاه‌های فعالِ بک‌اند + بازگشت به دامنه مبدأ, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی, وظایف, پروژه (+3 more)
### Community 54 - "Community 54"
Cohesion: 0.17
Nodes (11): entry پرداخت به‌صورت ریدایرکت خالص به Backend (بدون XHR) — سایت عمومی, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی, وظایف, پروژه (+3 more)
### Community 55 - "Community 55"
Cohesion: 0.27
Nodes (5): Field(), ItemUser(), Replies(), SendAnswer(), timeAgo()
### Community 56 - "Community 56"
Cohesion: 0.27
Nodes (5): DoctorAvatar(), getInitials(), CircularLoading(), CustomLoading(), TextLoading()
### Community 57 - "Community 57"
Cohesion: 0.18
Nodes (10): اصلاح فیلدهای «جزئیات نوبت» در داشبورد, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی (کد واقعی — هر دو فایل مشابه), وظایف, پروژه (+2 more)
### Community 58 - "Community 58"
Cohesion: 0.18
Nodes (10): اجباری‌کردن فیلدهای اطلاعات حساب کاربری در صفحه نوبت‌گیری, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی (کد واقعی), وظایف, پروژه (+2 more)
### Community 59 - "Community 59"
Cohesion: 0.18
Nodes (10): انتخاب تاریخ تولد به‌صورت مرحله‌ای: سال ← ماه ← روز, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی (کد واقعی), وظایف, پروژه (+2 more)
### Community 60 - "Community 60"
Cohesion: 0.18
Nodes (10): ارسال city_id دامنه‌ی جاری هنگام رزرو نوبت, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی, وظایف, پروژه (+2 more)
### Community 61 - "Community 61"
Cohesion: 0.18
Nodes (10): رفع فیلتر وضعیت در «نوبت‌های من» (نوبت ثبت‌شده نمایش داده نمی‌شود), زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی (کد واقعی), وظایف, پروژه (+2 more)
### Community 62 - "Community 62"
Cohesion: 0.18
Nodes (10): ارسال دامنه‌ی شهر همراه درخواست کد تأیید (برای اسم سایت در پیامک OTP), زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی, وظایف, پروژه (+2 more)
### Community 63 - "Community 63"
Cohesion: 0.18
Nodes (10): 🔧 Troubleshooting, 👥 تیم توسعه, 📁 ساختار پروژه, 📋 فهرست مطالب, مشکلات رایج, 🎯 معرفی پروژه, 📚 منابع مفید, 🏥 نوبت724 (Nobat724) - سیستم نوبت‌دهی آنلاین پزشکی (+2 more)
### Community 64 - "Community 64"
Cohesion: 0.33
Nodes (6): Crop(), createImage(), cropImage(), dataURLtoFile(), getCroppedImg(), ModalUpload()
### Community 65 - "Community 65"
Cohesion: 0.29
Nodes (5): CustomToastify(), viewport, Providers(), ThemeRegistry(), theme
### Community 66 - "Community 66"
Cohesion: 0.36
Nodes (4): fixedIconData, nextIconData, prevIconData, LoadingDate()
### Community 67 - "Community 67"
Cohesion: 0.29
Nodes (4): FrequentSearches(), TextHeader(), AText(), BText()
### Community 68 - "Community 68"
Cohesion: 0.27
Nodes (6): clearRefreshCookie(), cookieDomain(), setRefreshCookie(), POST(), POST(), POST()
### Community 69 - "Community 69"
Cohesion: 0.20
Nodes (9): رفع جهت تبدیل تاریخ تولد هنگام ایجاد پروفایل, زمینه, فایل‌های مرتبط, مشکل / هدف, نکات مهم, وضعیت فعلی (کد واقعی), وظایف, پروژه (+1 more)
### Community 70 - "Community 70"
Cohesion: 0.25
Nodes (7): Clinics(), FILTER_KEYS, generateMetadata(), listingRobots(), buildClinicParams(), axiosInstance, fetchReq()
### Community 71 - "Community 71"
Cohesion: 0.22
Nodes (7): degree, Form(), gender, degree, Form(), gender, filterList()
### Community 72 - "Community 72"
Cohesion: 0.46
Nodes (7): generateMetadata(), buildCanonicalPath(), buildCanonicalUrl(), buildMainCanonicalUrl(), getCanonicalUrl(), getRequestOrigin(), normalizeHost()
### Community 73 - "Community 73"
Cohesion: 0.32
Nodes (3): getStateInfoClient(), AddressSelector(), Content()
### Community 74 - "Community 74"
Cohesion: 0.38
Nodes (3): listSort, ArrowBottomD(), SortD()
### Community 75 - "Community 75"
Cohesion: 0.29
Nodes (7): Authentication & Authorization, Development Tools, Frontend Framework, State Management & Data Fetching, UI/UX, 🏗️ معماری و تکنولوژی, کتابخانه‌های تخصصی
### Community 76 - "Community 76"
Cohesion: 0.40
Nodes (3): Allergies(), ItemAllergie(), ModalAddAlergie()
### Community 79 - "Community 79"
Cohesion: 0.40
Nodes (3): FamilyHistory(), ItemHistory(), ModalAddHistory()
### Community 81 - "Community 81"
Cohesion: 0.40
Nodes (3): Medications(), ItemMedication(), ModalAddMedications()
### Community 82 - "Community 82"
Cohesion: 0.40
Nodes (3): ModalAddRelatives(), Relatives(), ItemRelatives()
### Community 83 - "Community 83"
Cohesion: 0.40
Nodes (3): ModalAddSurgeries(), Surgeries(), ItemSurgeries()
### Community 85 - "Community 85"
Cohesion: 0.53
Nodes (3): setNewData(), DetailUser(), Disease()
### Community 86 - "Community 86"
Cohesion: 0.40
Nodes (5): Doctors(), FILTER_KEYS, generateMetadata(), listingRobots(), buildDoctorParams()
### Community 87 - "Community 87"
Cohesion: 0.33
Nodes (6): 1. افزودن صفحه جدید, 2. افزودن API Endpoint جدید, 3. افزودن کامپوننت جدید, 4. کار با تاریخ شمسی, 5. استفاده از Context, 📝 نکات توسعه
### Community 89 - "Community 89"
Cohesion: 0.70
Nodes (4): generateMetadata(), Doctor(), getDoctor, getDoctorAddresses
### Community 90 - "Community 90"
Cohesion: 0.50
Nodes (4): buildDays(), InlineJalaliMonth(), MONTHS, WEEKDAYS
### Community 92 - "Community 92"
Cohesion: 0.40
Nodes (4): footerL, footerR, frequentSearches, listNav
### Community 93 - "Community 93"
Cohesion: 0.40
Nodes (5): 1. Multi-Domain Architecture, 2. سیستم احراز هویت, 3. سیستم رزرو نوبت, 4. پنل مدیریتی, ✨ ویژگی‌های کلیدی
### Community 94 - "Community 94"
Cohesion: 0.40
Nodes (5): Build Production, 🐳 Deployment, Docker Compose, Docker Deployment, متغیرهای محیطی مورد نیاز
### Community 95 - "Community 95"
Cohesion: 0.40
Nodes (5): اسکریپت‌های موجود, راه‌اندازی با Docker, 🚀 راه‌اندازی پروژه, نصب و راه‌اندازی, پیش‌نیازها
### Community 96 - "Community 96"
Cohesion: 0.40
Nodes (5): صفحات احراز هویت, صفحات رزرو نوبت, صفحات عمومی (Public), 📍 مسیرها و صفحات, پنل مدیریتی (Protected)
### Community 102 - "Community 102"
Cohesion: 0.50
Nodes (3): compilerOptions, paths, @/*
### Community 104 - "Community 104"
Cohesion: 0.50
Nodes (4): API Endpoints (`services/response.js`), 🔌 API و سرویس‌ها, Helper Functions (`helper/index.js`), تنظیمات Axios (`services/api.js`)
### Community 105 - "Community 105"
Cohesion: 0.50
Nodes (4): Cookies استفاده شده, 🔐 احراز هویت و مجوزها, فرآیند ورود, محافظت از مسیرها
### Community 106 - "Community 106"
Cohesion: 0.50
Nodes (4): Dark Mode, Material-UI Theme, Tailwind CSS, 🎨 استایل‌دهی
### Community 107 - "Community 107"
Cohesion: 0.50
Nodes (4): Metadata داینامیک بر اساس شهر, ساختار دامنه‌ها, 🌐 سیستم Multi-Domain, فرآیند تشخیص شهر
### Community 122 - "Community 122"
Cohesion: 0.67
Nodes (3): Feature Components, Layout Components, 🧩 کامپوننت‌های اصلی
## Knowledge Gaps
- **668 isolated node(s):** `metadata`, `FILTER_KEYS`, `fallbackLabels`, `MaterialUISwitch`, `fixedIconData` (+663 more)
These have ≤1 connection - possible missing edges or undocumented components.
- **29 thin communities (<3 nodes) omitted from report** — run `graphify query` to explore isolated nodes.
## Suggested Questions
_Questions this graph is uniquely positioned to answer:_
- **Why does `getStateInfo()` connect `Community 29` to `Community 0`, `Community 67`, `Community 3`, `Community 70`, `Community 6`, `Community 72`, `Community 45`, `Community 14`, `Community 16`, `Community 86`, `Community 89`?**
_High betweenness centrality (0.040) - this node is a cross-community bridge._
- **Why does `imageUrl()` connect `Community 45` to `Community 0`, `Community 1`, `Community 99`, `Community 4`, `Community 7`, `Community 55`, `Community 56`, `Community 89`?**
_High betweenness centrality (0.039) - this node is a cross-community bridge._
- **Why does `Dashboard()` connect `Community 6` to `Community 29`, `Community 70`?**
_High betweenness centrality (0.015) - this node is a cross-community bridge._
- **Are the 22 inferred relationships involving `getStateInfo()` (e.g. with `generateMetadata()` and `AboutUsPage()`) actually correct?**
_`getStateInfo()` has 22 INFERRED edges - model-reasoned connections that need verification._
- **Are the 14 inferred relationships involving `imageUrl()` (e.g. with `generateMetadata()` and `generateMetadata()`) actually correct?**
_`imageUrl()` has 14 INFERRED edges - model-reasoned connections that need verification._
- **What connects `metadata`, `FILTER_KEYS`, `fallbackLabels` to the rest of the system?**
_668 weakly-connected nodes found - possible documentation gaps or missing edges._
- **Should `Community 0` be split into smaller, more focused modules?**
_Cohesion score 0.05263157894736842 - nodes in this community are weakly interconnected._
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
{"nodes": [], "edges": [], "skipped": "data json (not a config/manifest)"}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
{"nodes": [], "edges": [], "skipped": "data json (non-object root)"}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
{"nodes": [{"id": "users_hamed_pj_my_pj_clinic_pro_nobat724_front_jsconfig_json", "label": "jsconfig.json", "file_type": "code", "source_file": "jsconfig.json", "source_location": "L1"}, {"id": "nobat724_front_jsconfig_compileroptions", "label": "compilerOptions", "file_type": "code", "source_file": "jsconfig.json", "source_location": "L2"}, {"id": "nobat724_front_jsconfig_compileroptions_paths", "label": "paths", "file_type": "code", "source_file": "jsconfig.json", "source_location": "L3"}, {"id": "nobat724_front_jsconfig_paths", "label": "@/*", "file_type": "code", "source_file": "jsconfig.json", "source_location": "L4"}], "edges": [{"source": "users_hamed_pj_my_pj_clinic_pro_nobat724_front_jsconfig_json", "target": "nobat724_front_jsconfig_compileroptions", "relation": "contains", "confidence": "EXTRACTED", "source_file": "jsconfig.json", "source_location": "L2", "weight": 1.0}, {"source": "nobat724_front_jsconfig_compileroptions", "target": "nobat724_front_jsconfig_compileroptions_paths", "relation": "contains", "confidence": "EXTRACTED", "source_file": "jsconfig.json", "source_location": "L3", "weight": 1.0}, {"source": "nobat724_front_jsconfig_compileroptions_paths", "target": "nobat724_front_jsconfig_paths", "relation": "contains", "confidence": "EXTRACTED", "source_file": "jsconfig.json", "source_location": "L4", "weight": 1.0}, {"source": "nobat724_front_jsconfig_paths", "target": "ref", "relation": "extends", "confidence": "EXTRACTED", "source_file": "jsconfig.json", "source_location": "L4", "weight": 1.0, "context": "import"}]}
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
{"nodes": [], "edges": [], "skipped": "data json (non-object root)"}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
{"nodes": [], "edges": [], "skipped": "data json (non-object root)"}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
{"nodes": [], "edges": [], "skipped": "data json (non-object root)"}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
{"nodes": [], "edges": [], "skipped": "data json (non-object root)"}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
{"nodes": [], "edges": [], "skipped": "data json (non-object root)"}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large Load Diff
+6
View File
@@ -5,6 +5,12 @@ const nextConfig = {
// متادیتا (canonical/OG/keywords) باید داخل <head> رندر شود نه استریم در <body>.
// از Next 15.2 استریم متادیتا پیش‌فرض است؛ این regex همه‌ی UAها را blocking می‌کند.
htmlLimitedBots: /.*/,
// React Compiler (پایدار در Next 16) — memoization خودکار کامپوننت‌ها.
reactCompiler: true,
// نکته: cacheComponents فعال نشد. معماری multi-domain به headers() (هدر host) در
// layout و generateMetadata وابسته است؛ با cacheComponents هر دسترسی uncached به
// headers() باید داخل <Suspense> بسته شود (build روی /_not-found شکست خورد). این کار
// نیازمند Suspenseگذاری گسترده و ریسک نشت محتوای شهر بین دامنه‌هاست — فعلاً امن نیست.
images: {
remotePatterns: [
{
+4049 -67
View File
File diff suppressed because it is too large Load Diff
+10 -9
View File
@@ -9,7 +9,7 @@
"dev": "cross-env HOST=yazd-nobat.localhost PORT=3000 NODE_TLS_REJECT_UNAUTHORIZED=0 next dev",
"build": "next build",
"start": "next start",
"lint": "next lint",
"lint": "eslint .",
"test": "vitest run",
"test:watch": "vitest",
"test:cov": "vitest run --coverage"
@@ -26,7 +26,7 @@
"@mui/styled-engine": "^5.18.0",
"@mui/x-charts": "^7.29.1",
"@mui/x-date-pickers": "^7.29.4",
"@next/third-parties": "^15.5.7",
"@next/third-parties": "^16.2.10",
"aos": "^2.3.4",
"axios": "^1.13.2",
"date-fns": "^4.1.0",
@@ -40,14 +40,14 @@
"js-cookie": "^3.0.5",
"jspdf": "^3.0.4",
"moment-jalaali": "^0.10.4",
"next": "^15.5.7",
"next": "^16.2.10",
"next-themes": "^0.4.6",
"npm": "^11.7.0",
"postcss": "^8.5.6",
"qrcode": "^1.5.4",
"qrcode.react": "^4.2.0",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"react": "^19.2.7",
"react-dom": "^19.2.7",
"react-easy-crop": "^5.5.6",
"react-google-map-picker": "^1.2.3",
"react-images-uploading": "^3.1.7",
@@ -61,18 +61,19 @@
"uninstall": "^0.0.0"
},
"devDependencies": {
"@eslint/eslintrc": "^3.3.5",
"@testing-library/dom": "^10.4.1",
"@testing-library/jest-dom": "^6.9.1",
"@testing-library/react": "^16.3.2",
"@testing-library/user-event": "^14.6.1",
"@vitejs/plugin-react": "^4.7.0",
"babel-plugin-react-compiler": "^1.0.0",
"cross-env": "^10.1.0",
"eslint": "^9.39.4",
"eslint-config-next": "^16.2.10",
"jsdom": "^29.1.1",
"prettier": "^3.7.4",
"typescript": "^6.0.3",
"vitest": "^2.1.9"
},
"overrides": {
"react": "^18.3.1",
"react-dom": "^18.3.1"
}
}
+1 -1
View File
@@ -1,6 +1,6 @@
import { NextResponse } from 'next/server';
export function middleware(request) {
export function proxy(request) {
const response = NextResponse.next();
// Add pathname to headers so we can access it in getCanonicalUrl