refactor(mobile): refine bottom nav tabs, hardware back dismissal, and live shop search
This commit is contained in:
parent
1c98f1bfa3
commit
881f75a372
@ -1,12 +1,12 @@
|
||||
"use client";
|
||||
|
||||
import React, { useState, useEffect } from "react";
|
||||
import React, { useState, useEffect, useCallback, useRef } from "react";
|
||||
import Link from "next/link";
|
||||
import Image from "next/image";
|
||||
import { usePathname, useRouter } from "next/navigation";
|
||||
import {
|
||||
Home,
|
||||
ShoppingBag,
|
||||
Sparkles,
|
||||
ShoppingCart,
|
||||
Menu,
|
||||
Pill,
|
||||
@ -18,17 +18,19 @@ import {
|
||||
Building2,
|
||||
FileHeart,
|
||||
User,
|
||||
LogOut,
|
||||
Search,
|
||||
ChevronLeft,
|
||||
Dog,
|
||||
PhoneCall
|
||||
PhoneCall,
|
||||
Sparkles,
|
||||
ArrowRight
|
||||
} from "lucide-react";
|
||||
import { useCartStore } from "../lib/store/cartStore";
|
||||
import { useUserStore } from "../lib/store/userStore";
|
||||
import { useUIStore } from "../lib/store/uiStore";
|
||||
import { useSettingsStore } from "../lib/store/settingsStore";
|
||||
import { toast } from "sonner";
|
||||
import { productService } from "../lib/services/productService";
|
||||
import { Product } from "../lib/data/products";
|
||||
import { toPersian } from "../lib/utils";
|
||||
|
||||
const SOLUTION_ITEMS = [
|
||||
@ -66,74 +68,151 @@ export default function MobileBottomNav({
|
||||
const pathname = usePathname();
|
||||
const router = useRouter();
|
||||
|
||||
const [isSolutionsOpen, setIsSolutionsOpen] = useState(false);
|
||||
const [isMenuOpen, setIsMenuOpen] = useState(false);
|
||||
const [activeSheet, setActiveSheet] = useState<"shop" | "menu" | null>(null);
|
||||
const [searchQuery, setSearchQuery] = useState("");
|
||||
const [searchResults, setSearchResults] = useState<Product[]>([]);
|
||||
const [isSearching, setIsSearching] = useState(false);
|
||||
const [isMounted, setIsMounted] = useState(false);
|
||||
|
||||
const isNavigatingBackRef = useRef(false);
|
||||
|
||||
const { getTotalItems } = useCartStore();
|
||||
const setCartOpen = useUIStore((state) => state.setCartOpen);
|
||||
const setB2BPortalOpen = useUIStore((state) => state.setB2BPortalOpen);
|
||||
const isB2BEnabled = useSettingsStore((s) => s.getBoolean('b2bRegistrationOpen', true) && s.getBoolean('b2b_enabled', true));
|
||||
const isPrescriptionEnabled = useSettingsStore((s) => s.getText('PRESCRIPTION_UPLOAD_ENABLED', 'true') !== 'false');
|
||||
|
||||
const { isLoggedIn, profile, logout, setAuthModalOpen } = useUserStore();
|
||||
const { isLoggedIn, setAuthModalOpen } = useUserStore();
|
||||
|
||||
useEffect(() => {
|
||||
setIsMounted(true);
|
||||
}, []);
|
||||
|
||||
// Close sheet with history navigation support (Back button dismiss)
|
||||
const closeSheet = useCallback(() => {
|
||||
if (!activeSheet) return;
|
||||
setActiveSheet(null);
|
||||
if (typeof window !== "undefined" && window.location.hash === "#sheet") {
|
||||
isNavigatingBackRef.current = true;
|
||||
window.history.back();
|
||||
}
|
||||
}, [activeSheet]);
|
||||
|
||||
const openSheet = useCallback((sheet: "shop" | "menu") => {
|
||||
setActiveSheet(sheet);
|
||||
if (typeof window !== "undefined") {
|
||||
window.history.pushState({ mobileSheet: sheet }, "", "#sheet");
|
||||
}
|
||||
}, []);
|
||||
|
||||
// Handle hardware / browser back button popstate
|
||||
useEffect(() => {
|
||||
setIsSolutionsOpen(false);
|
||||
setIsMenuOpen(false);
|
||||
const handlePopState = () => {
|
||||
if (isNavigatingBackRef.current) {
|
||||
isNavigatingBackRef.current = false;
|
||||
return;
|
||||
}
|
||||
if (activeSheet) {
|
||||
setActiveSheet(null);
|
||||
}
|
||||
};
|
||||
|
||||
window.addEventListener("popstate", handlePopState);
|
||||
return () => window.removeEventListener("popstate", handlePopState);
|
||||
}, [activeSheet]);
|
||||
|
||||
// Close sheet on route change
|
||||
useEffect(() => {
|
||||
setActiveSheet(null);
|
||||
setSearchQuery("");
|
||||
setSearchResults([]);
|
||||
}, [pathname]);
|
||||
|
||||
// Live search debounced query
|
||||
useEffect(() => {
|
||||
if (!searchQuery.trim()) {
|
||||
setSearchResults([]);
|
||||
setIsSearching(false);
|
||||
return;
|
||||
}
|
||||
|
||||
const timer = setTimeout(async () => {
|
||||
setIsSearching(true);
|
||||
try {
|
||||
const res = await productService.getProducts({ query: searchQuery.trim(), limit: 6 });
|
||||
setSearchResults(res.data || []);
|
||||
} catch (err) {
|
||||
console.error("Live search failed:", err);
|
||||
} finally {
|
||||
setIsSearching(false);
|
||||
}
|
||||
}, 250);
|
||||
|
||||
return () => clearTimeout(timer);
|
||||
}, [searchQuery]);
|
||||
|
||||
const handleSearchSubmit = (e: React.FormEvent) => {
|
||||
e.preventDefault();
|
||||
if (searchQuery.trim()) {
|
||||
setIsSolutionsOpen(false);
|
||||
router.push(`/shop?q=${encodeURIComponent(searchQuery.trim())}`);
|
||||
const q = searchQuery.trim();
|
||||
closeSheet();
|
||||
router.push(`/shop?search=${encodeURIComponent(q)}`);
|
||||
} else {
|
||||
closeSheet();
|
||||
router.push("/shop");
|
||||
}
|
||||
};
|
||||
|
||||
const handleAccountClick = () => {
|
||||
if (isLoggedIn) {
|
||||
router.push("/dashboard");
|
||||
} else {
|
||||
setAuthModalOpen(true);
|
||||
}
|
||||
};
|
||||
|
||||
const totalCartItems = isMounted ? getTotalItems() : 0;
|
||||
const isHomeActive = pathname === "/";
|
||||
const isShopActive = pathname === "/shop";
|
||||
const isShopActive = pathname.startsWith("/shop") || activeSheet === "shop";
|
||||
const isAccountActive = pathname.startsWith("/dashboard");
|
||||
|
||||
return (
|
||||
<>
|
||||
{/* 1. SOLUTIONS BOTTOM SHEET */}
|
||||
{isSolutionsOpen && (
|
||||
{/* 1. SHOP & SOLUTIONS BOTTOM SHEET (Modal for Shop Tab) */}
|
||||
{activeSheet === "shop" && (
|
||||
<div
|
||||
className="lg:hidden fixed inset-0 z-50 flex items-end justify-center bg-black/50 backdrop-blur-xs font-vazir"
|
||||
onClick={() => setIsSolutionsOpen(false)}
|
||||
onClick={closeSheet}
|
||||
>
|
||||
<div
|
||||
className="w-full max-w-lg bg-white rounded-t-3xl p-5 border-t border-medical-gray-200 shadow-2xl max-h-[85vh] flex flex-col animate-in slide-in-from-bottom duration-200"
|
||||
onClick={(e) => e.stopPropagation()}
|
||||
dir="rtl"
|
||||
>
|
||||
{/* Grab handle */}
|
||||
<div className="w-10 h-1 bg-medical-gray-200 rounded-full mx-auto mb-3 shrink-0" />
|
||||
|
||||
{/* Header with Direct Shop Link */}
|
||||
<div className="flex items-center justify-between pb-3 border-b border-medical-gray-100 mb-3 shrink-0">
|
||||
<div className="flex items-center gap-2">
|
||||
<div className="p-1.5 bg-canina-blue/10 rounded-xl text-canina-blue">
|
||||
<Sparkles className="w-4 h-4" />
|
||||
<ShoppingBag className="w-4 h-4" />
|
||||
</div>
|
||||
<div>
|
||||
<h3 className="font-black text-sm text-medical-gray-900">راهکارهای بالینی و تخصصی</h3>
|
||||
<p className="text-[10px] text-medical-gray-400">جستجو بر اساس بیماری و علائم بالینی پت</p>
|
||||
<h3 className="font-black text-sm text-medical-gray-900">فروشگاه و راهکارهای دارویی</h3>
|
||||
<p className="text-[10px] text-medical-gray-400">جستجو در داروها، مکملها و علائم بالینی</p>
|
||||
</div>
|
||||
</div>
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => setIsSolutionsOpen(false)}
|
||||
onClick={closeSheet}
|
||||
className="text-xs text-medical-gray-400 hover:text-medical-gray-700 font-bold p-1"
|
||||
>
|
||||
بستن ✕
|
||||
</button>
|
||||
</div>
|
||||
|
||||
{/* Search Input */}
|
||||
<form onSubmit={handleSearchSubmit} className="relative mb-3 shrink-0">
|
||||
<Search className="absolute right-3.5 top-1/2 -translate-y-1/2 w-4 h-4 text-medical-gray-400" />
|
||||
<input
|
||||
@ -141,15 +220,91 @@ export default function MobileBottomNav({
|
||||
placeholder="جستجوی دارو، ترکیب یا علامت بالینی..."
|
||||
value={searchQuery}
|
||||
onChange={(e) => setSearchQuery(e.target.value)}
|
||||
className="w-full bg-medical-gray-50 border border-medical-gray-200 rounded-xl py-2.5 pr-10 pl-3 text-xs outline-none focus:border-canina-blue font-vazir"
|
||||
className="w-full bg-medical-gray-50 border border-medical-gray-200 rounded-xl py-2.5 pr-10 pl-14 text-xs outline-none focus:border-canina-blue font-vazir text-medical-gray-900"
|
||||
autoFocus
|
||||
/>
|
||||
<button
|
||||
type="submit"
|
||||
className="absolute left-1.5 top-1/2 -translate-y-1/2 px-2.5 py-1 bg-canina-blue text-white rounded-lg text-[10px] font-bold"
|
||||
>
|
||||
جستجو
|
||||
</button>
|
||||
</form>
|
||||
|
||||
{/* Live Search Results (if typing) */}
|
||||
{searchQuery.trim().length > 0 && (
|
||||
<div className="mb-3 shrink-0 bg-medical-gray-50 rounded-2xl p-2.5 border border-medical-gray-200 max-h-56 overflow-y-auto">
|
||||
<div className="flex items-center justify-between mb-2 px-1">
|
||||
<span className="text-[10px] font-black text-medical-gray-500">
|
||||
{isSearching ? "در حال جستجو..." : `نتایج زنده (${toPersian(searchResults.length)})`}
|
||||
</span>
|
||||
<button
|
||||
type="button"
|
||||
onClick={handleSearchSubmit}
|
||||
className="text-[10px] font-bold text-canina-blue hover:underline flex items-center gap-0.5"
|
||||
>
|
||||
<span>مشاهده همه در فروشگاه</span>
|
||||
<ArrowRight className="w-3 h-3 rotate-180" />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
{searchResults.length === 0 && !isSearching ? (
|
||||
<p className="text-center text-xs text-medical-gray-400 py-3">دارویی با این نام یافت نشد</p>
|
||||
) : (
|
||||
<div className="space-y-1.5">
|
||||
{searchResults.map((prod) => (
|
||||
<Link
|
||||
key={prod.id}
|
||||
href={`/products/${prod.slug || prod.id}`}
|
||||
onClick={closeSheet}
|
||||
className="flex items-center gap-2.5 p-2 bg-white rounded-xl border border-medical-gray-100 hover:border-canina-blue transition-all"
|
||||
>
|
||||
{prod.image ? (
|
||||
<Image
|
||||
src={prod.image}
|
||||
alt={prod.name}
|
||||
width={36}
|
||||
height={36}
|
||||
className="w-9 h-9 object-contain rounded-lg shrink-0"
|
||||
/>
|
||||
) : (
|
||||
<div className="w-9 h-9 bg-medical-gray-100 rounded-lg flex items-center justify-center text-medical-gray-400 shrink-0">
|
||||
<Pill className="w-4 h-4" />
|
||||
</div>
|
||||
)}
|
||||
<div className="flex-1 min-w-0 text-right">
|
||||
<div className="text-xs font-bold text-medical-gray-900 truncate">{prod.name}</div>
|
||||
<div className="text-[10px] text-medical-gray-400 truncate">{prod.scientificTagline || prod.category}</div>
|
||||
</div>
|
||||
<div className="text-[11px] font-black text-canina-blue shrink-0">
|
||||
{prod.price}
|
||||
</div>
|
||||
</Link>
|
||||
))}
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
)}
|
||||
|
||||
{/* Direct Link to All Products */}
|
||||
<Link
|
||||
href="/shop"
|
||||
onClick={closeSheet}
|
||||
className="w-full flex items-center justify-between p-3 bg-canina-blue text-white rounded-2xl font-black text-xs shadow-md shadow-canina-blue/20 mb-3 shrink-0"
|
||||
>
|
||||
<div className="flex items-center gap-2">
|
||||
<ShoppingBag className="w-4 h-4" />
|
||||
<span>مشاهده کاتالوگ و همه محصولات</span>
|
||||
</div>
|
||||
<ChevronLeft className="w-4 h-4" />
|
||||
</Link>
|
||||
|
||||
{/* Prescription Upload Banner CTA if enabled */}
|
||||
{isPrescriptionEnabled && (
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => {
|
||||
setIsSolutionsOpen(false);
|
||||
closeSheet();
|
||||
if (onPrescriptionOpen) {
|
||||
onPrescriptionOpen();
|
||||
}
|
||||
@ -169,13 +324,15 @@ export default function MobileBottomNav({
|
||||
</button>
|
||||
)}
|
||||
|
||||
<div className="overflow-y-auto flex-1 space-y-3.5 py-1 pr-0.5">
|
||||
{/* 4 Major Clinical Categories with Symptoms */}
|
||||
<div className="overflow-y-auto flex-1 space-y-3 py-1 pr-0.5">
|
||||
<div className="text-[11px] font-black text-medical-gray-400">دستهبندیها و راهکارهای درمانی:</div>
|
||||
{SOLUTION_ITEMS.map((item) => (
|
||||
<div key={item.id} className="p-3 bg-medical-gray-50/70 border border-medical-gray-100 rounded-2xl">
|
||||
<Link
|
||||
href={`/shop?category=${item.id}`}
|
||||
onClick={() => setIsSolutionsOpen(false)}
|
||||
className="flex items-center justify-between mb-2.5"
|
||||
onClick={closeSheet}
|
||||
className="flex items-center justify-between mb-2"
|
||||
>
|
||||
<div className="flex items-center gap-2">
|
||||
{item.icon}
|
||||
@ -191,7 +348,7 @@ export default function MobileBottomNav({
|
||||
<Link
|
||||
key={sIdx}
|
||||
href={`/shop?category=${item.id}&symptom=${encodeURIComponent(sol)}`}
|
||||
onClick={() => setIsSolutionsOpen(false)}
|
||||
onClick={closeSheet}
|
||||
className="px-2.5 py-1 bg-white border border-medical-gray-200/80 rounded-lg text-[10px] font-bold text-medical-gray-600 hover:border-canina-blue hover:text-canina-blue transition-all"
|
||||
>
|
||||
{sol}
|
||||
@ -205,24 +362,26 @@ export default function MobileBottomNav({
|
||||
</div>
|
||||
)}
|
||||
|
||||
{/* 2. MENU & USER PROFILE BOTTOM SHEET */}
|
||||
{isMenuOpen && (
|
||||
{/* 2. MENU BOTTOM SHEET (Modal for Menu Tab) */}
|
||||
{activeSheet === "menu" && (
|
||||
<div
|
||||
className="lg:hidden fixed inset-0 z-50 flex items-end justify-center bg-black/50 backdrop-blur-xs font-vazir"
|
||||
onClick={() => setIsMenuOpen(false)}
|
||||
onClick={closeSheet}
|
||||
>
|
||||
<div
|
||||
className="w-full max-w-lg bg-white rounded-t-3xl p-5 border-t border-medical-gray-200 shadow-2xl max-h-[85vh] flex flex-col animate-in slide-in-from-bottom duration-200"
|
||||
onClick={(e) => e.stopPropagation()}
|
||||
dir="rtl"
|
||||
>
|
||||
{/* Grab handle */}
|
||||
<div className="w-10 h-1 bg-medical-gray-200 rounded-full mx-auto mb-3 shrink-0" />
|
||||
|
||||
{/* Header */}
|
||||
<div className="flex items-center justify-between pb-3 border-b border-medical-gray-100 mb-3 shrink-0">
|
||||
<h3 className="font-black text-sm text-medical-gray-900">منو و حساب کاربری</h3>
|
||||
<h3 className="font-black text-sm text-medical-gray-900">منوی بخشهای کنینا</h3>
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => setIsMenuOpen(false)}
|
||||
onClick={closeSheet}
|
||||
className="text-xs text-medical-gray-400 hover:text-medical-gray-700 font-bold p-1"
|
||||
>
|
||||
بستن ✕
|
||||
@ -230,51 +389,12 @@ export default function MobileBottomNav({
|
||||
</div>
|
||||
|
||||
<div className="overflow-y-auto flex-1 space-y-3 py-1">
|
||||
{isLoggedIn ? (
|
||||
<div className="p-3.5 bg-medical-gray-50 rounded-2xl border border-medical-gray-100 flex items-center justify-between">
|
||||
<div className="flex items-center gap-3">
|
||||
<div className="w-10 h-10 rounded-xl bg-canina-blue/10 flex items-center justify-center text-canina-blue font-black">
|
||||
<User className="w-5 h-5" />
|
||||
</div>
|
||||
<div>
|
||||
<div className="text-xs font-black text-medical-gray-900">
|
||||
{profile.firstName ? `${profile.firstName} ${profile.lastName || ''}` : 'کاربر گرامی'}
|
||||
</div>
|
||||
<div className="text-[10px] text-medical-gray-400 font-mono mt-0.5">
|
||||
{profile.mobile || profile.email}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<Link
|
||||
href="/dashboard"
|
||||
onClick={() => setIsMenuOpen(false)}
|
||||
className="px-3 py-1.5 bg-canina-blue text-white rounded-xl text-xs font-bold"
|
||||
>
|
||||
داشبورد
|
||||
</Link>
|
||||
</div>
|
||||
) : (
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => {
|
||||
setIsMenuOpen(false);
|
||||
setAuthModalOpen(true);
|
||||
}}
|
||||
className="w-full flex items-center justify-between p-3.5 bg-medical-gray-900 text-white rounded-2xl font-black text-xs shadow-md"
|
||||
>
|
||||
<div className="flex items-center gap-2.5">
|
||||
<User className="w-5 h-5 text-canina-gold" />
|
||||
<span>ورود یا ثبتنام در کنینا ایران</span>
|
||||
</div>
|
||||
<ChevronLeft className="w-4 h-4" />
|
||||
</button>
|
||||
)}
|
||||
|
||||
<div className="grid grid-cols-2 gap-2 pt-2">
|
||||
{/* Navigation Links Grid */}
|
||||
<div className="grid grid-cols-2 gap-2">
|
||||
<Link
|
||||
href="/dashboard?tab=pets"
|
||||
onClick={() => setIsMenuOpen(false)}
|
||||
className="flex items-center gap-2.5 p-3 bg-white border border-medical-gray-200/80 rounded-2xl text-xs font-bold text-medical-gray-800 hover:border-canina-blue"
|
||||
onClick={closeSheet}
|
||||
className="flex items-center gap-2.5 p-3.5 bg-medical-gray-50 border border-medical-gray-200/80 rounded-2xl text-xs font-bold text-medical-gray-800 hover:border-canina-blue"
|
||||
>
|
||||
<Dog className="w-4 h-4 text-canina-blue" />
|
||||
<span>شناسنامه پتها</span>
|
||||
@ -282,8 +402,8 @@ export default function MobileBottomNav({
|
||||
|
||||
<Link
|
||||
href="/catalog"
|
||||
onClick={() => setIsMenuOpen(false)}
|
||||
className="flex items-center gap-2.5 p-3 bg-white border border-medical-gray-200/80 rounded-2xl text-xs font-bold text-medical-gray-800 hover:border-canina-blue"
|
||||
onClick={closeSheet}
|
||||
className="flex items-center gap-2.5 p-3.5 bg-medical-gray-50 border border-medical-gray-200/80 rounded-2xl text-xs font-bold text-medical-gray-800 hover:border-canina-blue"
|
||||
>
|
||||
<BookOpen className="w-4 h-4 text-emerald-600" />
|
||||
<span>کاتالوگ دارویی</span>
|
||||
@ -291,8 +411,8 @@ export default function MobileBottomNav({
|
||||
|
||||
<Link
|
||||
href="/wiki"
|
||||
onClick={() => setIsMenuOpen(false)}
|
||||
className="flex items-center gap-2.5 p-3 bg-white border border-medical-gray-200/80 rounded-2xl text-xs font-bold text-medical-gray-800 hover:border-canina-blue"
|
||||
onClick={closeSheet}
|
||||
className="flex items-center gap-2.5 p-3.5 bg-medical-gray-50 border border-medical-gray-200/80 rounded-2xl text-xs font-bold text-medical-gray-800 hover:border-canina-blue"
|
||||
>
|
||||
<FileText className="w-4 h-4 text-amber-500" />
|
||||
<span>دانشنامه علمی</span>
|
||||
@ -300,8 +420,8 @@ export default function MobileBottomNav({
|
||||
|
||||
<Link
|
||||
href="/blog"
|
||||
onClick={() => setIsMenuOpen(false)}
|
||||
className="flex items-center gap-2.5 p-3 bg-white border border-medical-gray-200/80 rounded-2xl text-xs font-bold text-medical-gray-800 hover:border-canina-blue"
|
||||
onClick={closeSheet}
|
||||
className="flex items-center gap-2.5 p-3.5 bg-medical-gray-50 border border-medical-gray-200/80 rounded-2xl text-xs font-bold text-medical-gray-800 hover:border-canina-blue"
|
||||
>
|
||||
<HeartPulse className="w-4 h-4 text-rose-500" />
|
||||
<span>مجله سلامت پت</span>
|
||||
@ -309,8 +429,8 @@ export default function MobileBottomNav({
|
||||
|
||||
<Link
|
||||
href="/videos"
|
||||
onClick={() => setIsMenuOpen(false)}
|
||||
className="flex items-center gap-2.5 p-3 bg-white border border-medical-gray-200/80 rounded-2xl text-xs font-bold text-medical-gray-800 hover:border-canina-blue"
|
||||
onClick={closeSheet}
|
||||
className="flex items-center gap-2.5 p-3.5 bg-medical-gray-50 border border-medical-gray-200/80 rounded-2xl text-xs font-bold text-medical-gray-800 hover:border-canina-blue"
|
||||
>
|
||||
<Video className="w-4 h-4 text-indigo-500" />
|
||||
<span>ویدیوهای بالینی</span>
|
||||
@ -320,10 +440,10 @@ export default function MobileBottomNav({
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => {
|
||||
setIsMenuOpen(false);
|
||||
closeSheet();
|
||||
setB2BPortalOpen(true);
|
||||
}}
|
||||
className="flex items-center gap-2.5 p-3 bg-white border border-medical-gray-200/80 rounded-2xl text-xs font-bold text-medical-gray-800 hover:border-canina-blue text-right"
|
||||
className="flex items-center gap-2.5 p-3.5 bg-medical-gray-50 border border-medical-gray-200/80 rounded-2xl text-xs font-bold text-medical-gray-800 hover:border-canina-blue text-right"
|
||||
>
|
||||
<Building2 className="w-4 h-4 text-teal-600" />
|
||||
<span>خرید عمده (B2B)</span>
|
||||
@ -331,10 +451,11 @@ export default function MobileBottomNav({
|
||||
)}
|
||||
</div>
|
||||
|
||||
{/* Contact & Support */}
|
||||
<div className="pt-2 border-t border-medical-gray-100 space-y-1.5">
|
||||
<Link
|
||||
href="/contact"
|
||||
onClick={() => setIsMenuOpen(false)}
|
||||
onClick={closeSheet}
|
||||
className="w-full flex items-center justify-between p-3 rounded-xl hover:bg-medical-gray-50 text-xs font-bold text-medical-gray-700"
|
||||
>
|
||||
<div className="flex items-center gap-2.5">
|
||||
@ -343,35 +464,21 @@ export default function MobileBottomNav({
|
||||
</div>
|
||||
<ChevronLeft className="w-4 h-4 text-medical-gray-300" />
|
||||
</Link>
|
||||
|
||||
{isLoggedIn && (
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => {
|
||||
logout();
|
||||
setIsMenuOpen(false);
|
||||
toast.success('از حساب کاربری خارج شدید');
|
||||
}}
|
||||
className="w-full flex items-center gap-2.5 p-3 text-rose-600 rounded-xl font-bold text-xs hover:bg-rose-50 transition-colors text-right"
|
||||
>
|
||||
<LogOut className="w-4 h-4" />
|
||||
<span>خروج از حساب</span>
|
||||
</button>
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
|
||||
{/* 3. FIXED FLOATING BOTTOM APP NAVIGATION BAR */}
|
||||
{/* 3. FIXED 5-TAB APP BOTTOM NAVIGATION BAR */}
|
||||
<nav
|
||||
aria-label="منوی ناوبری موبایل"
|
||||
className="lg:hidden fixed bottom-0 inset-x-0 z-40 bg-white/95 backdrop-blur-md border-t border-medical-gray-200/80 shadow-[0_-4px_20px_rgba(0,0,0,0.06)] font-vazir"
|
||||
className="lg:hidden fixed bottom-0 inset-x-0 z-40 bg-white/95 backdrop-blur-md border-t border-medical-gray-200 shadow-[0_-4px_20px_rgba(0,0,0,0.06)] font-vazir"
|
||||
dir="rtl"
|
||||
>
|
||||
<div className="max-w-md mx-auto px-3 h-16 flex items-center justify-between select-none">
|
||||
<div className="max-w-md mx-auto px-2 h-16 flex items-center justify-between select-none">
|
||||
|
||||
{/* Tab 1: Home */}
|
||||
<Link
|
||||
href="/"
|
||||
className={`flex flex-col items-center justify-center flex-1 py-1 transition-all ${
|
||||
@ -382,27 +489,39 @@ export default function MobileBottomNav({
|
||||
<span className="text-[10px] leading-none">خانه</span>
|
||||
</Link>
|
||||
|
||||
<Link
|
||||
href="/shop"
|
||||
{/* Tab 2: Menu */}
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => {
|
||||
if (activeSheet === "menu") closeSheet();
|
||||
else openSheet("menu");
|
||||
}}
|
||||
className={`flex flex-col items-center justify-center flex-1 py-1 transition-all ${
|
||||
activeSheet === "menu" ? "text-canina-blue font-black" : "text-medical-gray-400 font-bold hover:text-medical-gray-700"
|
||||
}`}
|
||||
>
|
||||
<Menu className="w-5 h-5 mb-1" />
|
||||
<span className="text-[10px] leading-none">منو</span>
|
||||
</button>
|
||||
|
||||
{/* Tab 3: Shop (Opens Shop Sheet with Direct Shop Link + Solutions + Symptoms + Live Search) */}
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => {
|
||||
if (activeSheet === "shop") closeSheet();
|
||||
else openSheet("shop");
|
||||
}}
|
||||
className={`flex flex-col items-center justify-center flex-1 py-1 transition-all ${
|
||||
isShopActive ? "text-canina-blue font-black" : "text-medical-gray-400 font-bold hover:text-medical-gray-700"
|
||||
}`}
|
||||
>
|
||||
<ShoppingBag className={`w-5 h-5 mb-1 ${isShopActive ? "text-canina-blue" : "text-medical-gray-400"}`} />
|
||||
<div className="relative mb-1">
|
||||
<ShoppingBag className={`w-5 h-5 ${isShopActive ? "text-canina-blue" : "text-medical-gray-400"}`} />
|
||||
</div>
|
||||
<span className="text-[10px] leading-none">فروشگاه</span>
|
||||
</Link>
|
||||
|
||||
<div className="flex-1 flex justify-center -mt-5">
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => setIsSolutionsOpen(!isSolutionsOpen)}
|
||||
className="w-12 h-12 rounded-full bg-gradient-to-tr from-canina-blue to-teal-700 text-white shadow-lg shadow-canina-blue/30 flex items-center justify-center active:scale-95 transition-transform border-4 border-white"
|
||||
title="راهکارها و علائم"
|
||||
>
|
||||
<Sparkles className="w-5 h-5 text-canina-gold animate-pulse" />
|
||||
</button>
|
||||
</div>
|
||||
</button>
|
||||
|
||||
{/* Tab 4: Cart */}
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => setCartOpen(true)}
|
||||
@ -419,15 +538,16 @@ export default function MobileBottomNav({
|
||||
<span className="text-[10px] leading-none">سبد خرید</span>
|
||||
</button>
|
||||
|
||||
{/* Tab 5: Account (Direct to Dashboard if logged in, otherwise opens Auth Modal) */}
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => setIsMenuOpen(!isMenuOpen)}
|
||||
onClick={handleAccountClick}
|
||||
className={`flex flex-col items-center justify-center flex-1 py-1 transition-all ${
|
||||
isMenuOpen ? "text-canina-blue font-black" : "text-medical-gray-400 font-bold hover:text-medical-gray-700"
|
||||
isAccountActive ? "text-canina-blue font-black" : "text-medical-gray-400 font-bold hover:text-medical-gray-700"
|
||||
}`}
|
||||
>
|
||||
<Menu className="w-5 h-5 mb-1" />
|
||||
<span className="text-[10px] leading-none">منو</span>
|
||||
<User className={`w-5 h-5 mb-1 ${isAccountActive ? "text-canina-blue" : "text-medical-gray-400"}`} />
|
||||
<span className="text-[10px] leading-none">حساب من</span>
|
||||
</button>
|
||||
|
||||
</div>
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
"1": "app.module.ts",
|
||||
"2": "WikiController",
|
||||
"3": "productService.ts",
|
||||
"4": "toPersian",
|
||||
"4": "PetsController",
|
||||
"5": "CmsController",
|
||||
"6": "tickets.controller.ts",
|
||||
"7": "SmsSettingsPage.tsx",
|
||||
@ -13,7 +13,7 @@
|
||||
"11": "UsersService",
|
||||
"12": "index.ts",
|
||||
"13": "app-audit-verification.e2e-spec.js",
|
||||
"14": "CheckoutPage.tsx",
|
||||
"14": "toPersian",
|
||||
"15": "src/services/api.ts",
|
||||
"16": "DoctorQueryDto",
|
||||
"17": "schema.ts",
|
||||
@ -61,7 +61,7 @@
|
||||
"59": "compilerOptions",
|
||||
"60": "CreateUserDto",
|
||||
"61": "ProductPage.tsx",
|
||||
"62": "admin.module.ts",
|
||||
"62": "ReportsController",
|
||||
"63": "dependencies",
|
||||
"64": "compilerOptions",
|
||||
"65": "admin.service.ts",
|
||||
@ -112,7 +112,7 @@
|
||||
"110": "Operational Rules & Boundaries",
|
||||
"111": "Operational Rules & Boundaries",
|
||||
"112": "Operational Rules & Boundaries",
|
||||
"113": "orderService.ts",
|
||||
"113": "cartStore.ts",
|
||||
"114": "AppService",
|
||||
"115": "Spinner.tsx",
|
||||
"116": "Vazirmatn Changelog",
|
||||
@ -196,7 +196,7 @@
|
||||
"194": "Raw Finding Verification & Disposition Report",
|
||||
"195": "React + TypeScript + Vite",
|
||||
"196": "Select.tsx",
|
||||
"197": "AuthModal.tsx",
|
||||
"197": "ClientLayout.tsx",
|
||||
"198": "app/page.tsx",
|
||||
"199": "prisma",
|
||||
"200": "application/README.md",
|
||||
@ -305,7 +305,7 @@
|
||||
"303": "@nestjs/schematics",
|
||||
"304": "reflect-metadata",
|
||||
"305": "swagger-ui-express",
|
||||
"306": "eslint",
|
||||
"306": "components/Skeleton.tsx",
|
||||
"307": "eslint-config-prettier",
|
||||
"308": "@eslint/eslintrc",
|
||||
"309": "axios",
|
||||
@ -327,5 +327,9 @@
|
||||
"325": "@types/react-dom",
|
||||
"326": "@types/supertest",
|
||||
"327": "eslint-plugin-react-refresh",
|
||||
"328": "tailwindcss"
|
||||
"328": "orders.service.ts",
|
||||
"329": "videos.controller.ts",
|
||||
"330": "WikiService",
|
||||
"331": "eslint-plugin-prettier",
|
||||
"332": "eslint-config-next"
|
||||
}
|
||||
|
||||
File diff suppressed because one or more lines are too long
@ -3,25 +3,25 @@
|
||||
"1": "app.module.ts",
|
||||
"2": "WikiController",
|
||||
"3": "productService.ts",
|
||||
"4": "useSettingsStore",
|
||||
"4": "toPersian",
|
||||
"5": "CmsController",
|
||||
"6": "tickets.controller.ts",
|
||||
"7": "SmsSettingsPage.tsx",
|
||||
"8": "SmsService",
|
||||
"9": "devDependencies",
|
||||
"10": "reviews.controller.ts",
|
||||
"10": "CreateReviewDto",
|
||||
"11": "UsersService",
|
||||
"12": "index.ts",
|
||||
"13": "app-audit-verification.e2e-spec.js",
|
||||
"14": "UserDashboard.tsx",
|
||||
"14": "CheckoutPage.tsx",
|
||||
"15": "src/services/api.ts",
|
||||
"16": "DoctorQueryDto",
|
||||
"17": "schema.ts",
|
||||
"18": "JwtAuthGuard",
|
||||
"19": "admin.controller.ts",
|
||||
"20": "CreateVideoDto",
|
||||
"21": "HomeClient.tsx",
|
||||
"22": "ProductDto",
|
||||
"21": "useSettingsStore",
|
||||
"22": "AdminService",
|
||||
"23": "MenuService",
|
||||
"24": "BE-001",
|
||||
"25": "FE-001",
|
||||
@ -33,8 +33,8 @@
|
||||
"31": "DOC-001",
|
||||
"32": "adminRoutes.tsx",
|
||||
"33": "WholesaleApplyDto",
|
||||
"34": "B2BController",
|
||||
"35": "ContactController",
|
||||
"34": "B2BService",
|
||||
"35": "ContactService",
|
||||
"36": "FaqService",
|
||||
"37": "راهنمای تست سیستم (Software Testing)",
|
||||
"38": "Button",
|
||||
@ -42,16 +42,16 @@
|
||||
"40": "MediaController",
|
||||
"41": "What You Must Do When Invoked",
|
||||
"42": "SslController",
|
||||
"43": "BannersController",
|
||||
"44": "TestimonialsController",
|
||||
"43": "BannersService",
|
||||
"44": "TestimonialsService",
|
||||
"45": "What You Must Do When Invoked",
|
||||
"46": "20260526145407_init/migration.sql",
|
||||
"47": "IngredientsController",
|
||||
"47": "IngredientsService",
|
||||
"48": "app.e2e-spec.js",
|
||||
"49": "devDependencies",
|
||||
"50": "devDependencies",
|
||||
"51": "BlogsController",
|
||||
"52": "prescriptions.controller.ts",
|
||||
"52": "PrescriptionsService",
|
||||
"53": "SmartAdvisorService",
|
||||
"54": "Button.tsx",
|
||||
"55": "UITexts.tsx",
|
||||
@ -65,8 +65,8 @@
|
||||
"63": "dependencies",
|
||||
"64": "compilerOptions",
|
||||
"65": "admin.service.ts",
|
||||
"66": "AdminController",
|
||||
"67": "ConfirmModal.tsx",
|
||||
"66": "AdminQueryDto",
|
||||
"67": "pets/pets.controller.ts",
|
||||
"68": "lib/services/api.ts",
|
||||
"69": "Required Review Group Closures",
|
||||
"70": "compilerOptions",
|
||||
@ -89,14 +89,14 @@
|
||||
"87": "dependencies",
|
||||
"88": "CreateEBankCheckoutDto",
|
||||
"89": "seed-products.ts",
|
||||
"90": "PetProfile.tsx",
|
||||
"90": "SmartAdvisor.tsx",
|
||||
"91": "Reconciled Audit Roles & Assignments",
|
||||
"92": "OrdersService",
|
||||
"93": "auth.service.ts",
|
||||
"94": "Phase 3.1 — Human Review Preparation and Master Backlog Critique",
|
||||
"95": "wiki/[slug]/page.tsx",
|
||||
"95": "getSeoConfig",
|
||||
"96": "compilerOptions",
|
||||
"97": "PaymentService",
|
||||
"97": "AdminTransactionFilterDto",
|
||||
"98": "scripts",
|
||||
"99": "BlogsController",
|
||||
"100": "Deep Audit Summary Report",
|
||||
@ -112,7 +112,7 @@
|
||||
"110": "Operational Rules & Boundaries",
|
||||
"111": "Operational Rules & Boundaries",
|
||||
"112": "Operational Rules & Boundaries",
|
||||
"113": "sms.service.ts",
|
||||
"113": "orderService.ts",
|
||||
"114": "AppService",
|
||||
"115": "Spinner.tsx",
|
||||
"116": "Vazirmatn Changelog",
|
||||
@ -121,14 +121,14 @@
|
||||
"119": "compilerOptions",
|
||||
"120": "compilerOptions",
|
||||
"121": "backend/README.md",
|
||||
"122": "AdminService",
|
||||
"123": "ApiOperation",
|
||||
"122": "AdminController",
|
||||
"123": "RouteErrorBoundary",
|
||||
"124": "Repository Map",
|
||||
"125": "validate_integrity.js",
|
||||
"126": "admin-panel/package.json",
|
||||
"127": "Sahel-Font",
|
||||
"128": "HomeController",
|
||||
"129": "auth.module.ts",
|
||||
"129": "LoginDto",
|
||||
"130": "Sahel-Font",
|
||||
"131": "Role & Core Objective",
|
||||
"132": "orchestrate.py",
|
||||
@ -144,7 +144,7 @@
|
||||
"142": "start-dev.js",
|
||||
"143": "generate-openapi.js",
|
||||
"144": "SafeImage.tsx",
|
||||
"145": "auth.controller.ts",
|
||||
"145": "AdminLoginDto",
|
||||
"146": "System Discovery",
|
||||
"147": "torob.controller.ts",
|
||||
"148": "Reports.tsx",
|
||||
@ -176,7 +176,7 @@
|
||||
"174": "rebuild_honest_ledger.js",
|
||||
"175": "validate_evidence_grade.js",
|
||||
"176": "uploads/[...path]/route.ts",
|
||||
"177": "WikiService",
|
||||
"177": "Reviews.tsx",
|
||||
"178": "نقشه جامع پوشش تستهای سرتاسری (E2E Test Coverage Map) — پروژه Canina",
|
||||
"179": "track/page.tsx",
|
||||
"180": "API Contract Specification",
|
||||
@ -184,7 +184,7 @@
|
||||
"182": "🎨 Frontend & Admin Panel Technical Review (06_dev_frontend)",
|
||||
"183": "🚀 SEO & Content Strategy Review (12_seo_content)",
|
||||
"184": "trust-seals/page.tsx",
|
||||
"185": "@types/node",
|
||||
"185": "wiki/[slug]/page.tsx",
|
||||
"186": "seed-ui-texts.ts",
|
||||
"187": "seed-wiki.ts",
|
||||
"188": "update-blog.dto.ts",
|
||||
@ -196,14 +196,14 @@
|
||||
"194": "Raw Finding Verification & Disposition Report",
|
||||
"195": "React + TypeScript + Vite",
|
||||
"196": "Select.tsx",
|
||||
"197": "userStore.ts",
|
||||
"198": "typescript",
|
||||
"197": "AuthModal.tsx",
|
||||
"198": "app/page.tsx",
|
||||
"199": "prisma",
|
||||
"200": "application/README.md",
|
||||
"201": "deploy.sh",
|
||||
"202": "🔒 Security & Performance Review (09_devops_security)",
|
||||
"203": "👁️ UX & Persona Interface Review (08_visual_qa)",
|
||||
"204": "eslint-config-next",
|
||||
"204": "class-transformer",
|
||||
"205": "prisma/scientificTerms.ts",
|
||||
"206": "seed-blogs.ts",
|
||||
"207": "seed-custom.ts",
|
||||
@ -219,15 +219,20 @@
|
||||
"217": "sync_honest_manifest.js",
|
||||
"218": "sync_manifest.js",
|
||||
"219": "FormField.tsx",
|
||||
"220": "globals",
|
||||
"221": "Textarea.tsx",
|
||||
"222": "admin-panel/tsconfig.json",
|
||||
"223": "tailwindcss",
|
||||
"224": "typescript-eslint",
|
||||
"225": "next.config.ts",
|
||||
"226": "Shabnam Font README",
|
||||
"227": "AGENTS.md",
|
||||
"228": "rules/graphify.md",
|
||||
"229": ".agents/workflows/graphify.md",
|
||||
"230": "instructions.md",
|
||||
"231": "helmet",
|
||||
"232": "js-yaml",
|
||||
"233": "@nestjs/core",
|
||||
"234": "source-map-support",
|
||||
"235": "ts-loader",
|
||||
"236": "ts-node",
|
||||
@ -259,6 +264,7 @@
|
||||
"262": "User Logout API",
|
||||
"263": "generate-openapi.d.ts",
|
||||
"264": "@types/compression",
|
||||
"265": "@nestjs/jwt",
|
||||
"266": "@types/express",
|
||||
"267": "@types/jest",
|
||||
"268": "@types/multer",
|
||||
@ -288,24 +294,38 @@
|
||||
"292": "Production Docker Compose",
|
||||
"293": "Staging Docker Compose",
|
||||
"294": "ZibalService",
|
||||
"295": "@nestjs/swagger",
|
||||
"296": "@nestjs/throttler",
|
||||
"297": "ZibalEBankService",
|
||||
"298": ".initiateOrderPayment",
|
||||
"299": "@tailwindcss/postcss",
|
||||
"300": "typescript",
|
||||
"301": "passport",
|
||||
"302": "typescript-eslint",
|
||||
"303": "@nestjs/schematics",
|
||||
"305": "eslint-config-prettier",
|
||||
"308": "jest",
|
||||
"304": "reflect-metadata",
|
||||
"305": "swagger-ui-express",
|
||||
"306": "eslint",
|
||||
"307": "eslint-config-prettier",
|
||||
"308": "@eslint/eslintrc",
|
||||
"309": "axios",
|
||||
"310": "tailwindcss",
|
||||
"311": "jest",
|
||||
"312": "@types/passport-jwt",
|
||||
"313": "20260526160916_add_ui_texts_and_scientific_terms/migration.sql",
|
||||
"314": "@nestjs/cli",
|
||||
"315": "typescript",
|
||||
"316": "@nestjs/testing",
|
||||
"317": "revalidate/route.ts",
|
||||
"318": "MaskableField.tsx",
|
||||
"319": "@tailwindcss/postcss",
|
||||
"320": "prettier",
|
||||
"321": "orders/page.tsx",
|
||||
"322": "pets/page.tsx",
|
||||
"323": "ts-jest",
|
||||
"324": "@types/js-yaml",
|
||||
"325": "@types/react-dom",
|
||||
"327": "eslint-plugin-react-refresh"
|
||||
"326": "@types/supertest",
|
||||
"327": "eslint-plugin-react-refresh",
|
||||
"328": "tailwindcss"
|
||||
}
|
||||
|
||||
@ -1,16 +1,16 @@
|
||||
# Graph Report - canina (2026-09-06)
|
||||
|
||||
## Corpus Check
|
||||
- 603 files · ~1,118,096 words
|
||||
- 604 files · ~1,119,699 words
|
||||
- Verdict: corpus is large enough that graph structure adds value.
|
||||
|
||||
## Summary
|
||||
- 4253 nodes · 7800 edges · 309 communities (212 shown, 97 thin omitted)
|
||||
- 4258 nodes · 7823 edges · 329 communities (215 shown, 114 thin omitted)
|
||||
- Extraction: 96% EXTRACTED · 4% INFERRED · 0% AMBIGUOUS · INFERRED: 298 edges (avg confidence: 0.79)
|
||||
- Token cost: 0 input · 0 output
|
||||
|
||||
## Graph Freshness
|
||||
- Built from commit: `a9fbcbb9`
|
||||
- Built from commit: `808b5c58`
|
||||
- Run `git rev-parse HEAD` and compare to check if the graph is stale.
|
||||
- Run `graphify update .` after code changes (no API cost).
|
||||
|
||||
@ -19,25 +19,25 @@
|
||||
- app.module.ts
|
||||
- WikiController
|
||||
- productService.ts
|
||||
- useSettingsStore
|
||||
- toPersian
|
||||
- CmsController
|
||||
- tickets.controller.ts
|
||||
- SmsSettingsPage.tsx
|
||||
- SmsService
|
||||
- devDependencies
|
||||
- reviews.controller.ts
|
||||
- CreateReviewDto
|
||||
- UsersService
|
||||
- index.ts
|
||||
- app-audit-verification.e2e-spec.js
|
||||
- UserDashboard.tsx
|
||||
- CheckoutPage.tsx
|
||||
- src/services/api.ts
|
||||
- DoctorQueryDto
|
||||
- schema.ts
|
||||
- JwtAuthGuard
|
||||
- admin.controller.ts
|
||||
- CreateVideoDto
|
||||
- HomeClient.tsx
|
||||
- ProductDto
|
||||
- useSettingsStore
|
||||
- AdminService
|
||||
- MenuService
|
||||
- BE-001
|
||||
- FE-001
|
||||
@ -49,8 +49,8 @@
|
||||
- DOC-001
|
||||
- adminRoutes.tsx
|
||||
- WholesaleApplyDto
|
||||
- B2BController
|
||||
- ContactController
|
||||
- B2BService
|
||||
- ContactService
|
||||
- FaqService
|
||||
- راهنمای تست سیستم (Software Testing)
|
||||
- Button
|
||||
@ -58,16 +58,16 @@
|
||||
- MediaController
|
||||
- What You Must Do When Invoked
|
||||
- SslController
|
||||
- BannersController
|
||||
- TestimonialsController
|
||||
- BannersService
|
||||
- TestimonialsService
|
||||
- What You Must Do When Invoked
|
||||
- 20260526145407_init/migration.sql
|
||||
- IngredientsController
|
||||
- IngredientsService
|
||||
- app.e2e-spec.js
|
||||
- devDependencies
|
||||
- devDependencies
|
||||
- BlogsController
|
||||
- prescriptions.controller.ts
|
||||
- PrescriptionsService
|
||||
- SmartAdvisorService
|
||||
- Button.tsx
|
||||
- UITexts.tsx
|
||||
@ -82,7 +82,7 @@
|
||||
- compilerOptions
|
||||
- admin.service.ts
|
||||
- AdminQueryDto
|
||||
- ConfirmModal.tsx
|
||||
- pets/pets.controller.ts
|
||||
- lib/services/api.ts
|
||||
- Required Review Group Closures
|
||||
- compilerOptions
|
||||
@ -105,14 +105,14 @@
|
||||
- dependencies
|
||||
- CreateEBankCheckoutDto
|
||||
- seed-products.ts
|
||||
- PetProfile.tsx
|
||||
- SmartAdvisor.tsx
|
||||
- Reconciled Audit Roles & Assignments
|
||||
- OrdersService
|
||||
- auth.service.ts
|
||||
- Phase 3.1 — Human Review Preparation and Master Backlog Critique
|
||||
- wiki/[slug]/page.tsx
|
||||
- getSeoConfig
|
||||
- compilerOptions
|
||||
- PaymentService
|
||||
- AdminTransactionFilterDto
|
||||
- scripts
|
||||
- BlogsController
|
||||
- Deep Audit Summary Report
|
||||
@ -128,7 +128,7 @@
|
||||
- Operational Rules & Boundaries
|
||||
- Operational Rules & Boundaries
|
||||
- Operational Rules & Boundaries
|
||||
- sms.service.ts
|
||||
- orderService.ts
|
||||
- AppService
|
||||
- Spinner.tsx
|
||||
- Vazirmatn Changelog
|
||||
@ -137,14 +137,14 @@
|
||||
- compilerOptions
|
||||
- compilerOptions
|
||||
- backend/README.md
|
||||
- AdminService
|
||||
- Body
|
||||
- AdminController
|
||||
- RouteErrorBoundary
|
||||
- Repository Map
|
||||
- validate_integrity.js
|
||||
- admin-panel/package.json
|
||||
- Sahel-Font
|
||||
- HomeController
|
||||
- auth.module.ts
|
||||
- LoginDto
|
||||
- Sahel-Font
|
||||
- Role & Core Objective
|
||||
- orchestrate.py
|
||||
@ -160,7 +160,7 @@
|
||||
- start-dev.js
|
||||
- generate-openapi.js
|
||||
- SafeImage.tsx
|
||||
- auth.controller.ts
|
||||
- AdminLoginDto
|
||||
- System Discovery
|
||||
- torob.controller.ts
|
||||
- Reports.tsx
|
||||
@ -191,7 +191,7 @@
|
||||
- rebuild_honest_ledger.js
|
||||
- validate_evidence_grade.js
|
||||
- uploads/[...path]/route.ts
|
||||
- WikiService
|
||||
- Reviews.tsx
|
||||
- نقشه جامع پوشش تستهای سرتاسری (E2E Test Coverage Map) — پروژه Canina
|
||||
- track/page.tsx
|
||||
- API Contract Specification
|
||||
@ -199,7 +199,7 @@
|
||||
- 🎨 Frontend & Admin Panel Technical Review (06_dev_frontend)
|
||||
- 🚀 SEO & Content Strategy Review (12_seo_content)
|
||||
- trust-seals/page.tsx
|
||||
- @types/node
|
||||
- wiki/[slug]/page.tsx
|
||||
- seed-ui-texts.ts
|
||||
- seed-wiki.ts
|
||||
- update-blog.dto.ts
|
||||
@ -211,14 +211,14 @@
|
||||
- Raw Finding Verification & Disposition Report
|
||||
- React + TypeScript + Vite
|
||||
- Select.tsx
|
||||
- userStore.ts
|
||||
- eslint-plugin-prettier
|
||||
- AuthModal.tsx
|
||||
- app/page.tsx
|
||||
- prisma
|
||||
- application/README.md
|
||||
- deploy.sh
|
||||
- 🔒 Security & Performance Review (09_devops_security)
|
||||
- 👁️ UX & Persona Interface Review (08_visual_qa)
|
||||
- eslint-config-next
|
||||
- class-transformer
|
||||
- prisma/scientificTerms.ts
|
||||
- seed-blogs.ts
|
||||
- seed-custom.ts
|
||||
@ -245,6 +245,9 @@
|
||||
- rules/graphify.md
|
||||
- .agents/workflows/graphify.md
|
||||
- instructions.md
|
||||
- helmet
|
||||
- js-yaml
|
||||
- @nestjs/core
|
||||
- source-map-support
|
||||
- ts-loader
|
||||
- ts-node
|
||||
@ -272,6 +275,7 @@
|
||||
- User Login API
|
||||
- User Logout API
|
||||
- @types/compression
|
||||
- @nestjs/jwt
|
||||
- @types/express
|
||||
- @types/jest
|
||||
- @types/multer
|
||||
@ -290,25 +294,41 @@
|
||||
- Production Docker Compose
|
||||
- Staging Docker Compose
|
||||
- ZibalService
|
||||
- @nestjs/swagger
|
||||
- @nestjs/throttler
|
||||
- ZibalEBankService
|
||||
- .initiateOrderPayment
|
||||
- @tailwindcss/postcss
|
||||
- typescript
|
||||
- passport
|
||||
- typescript-eslint
|
||||
- @nestjs/schematics
|
||||
- reflect-metadata
|
||||
- swagger-ui-express
|
||||
- eslint
|
||||
- eslint-config-prettier
|
||||
- @eslint/eslintrc
|
||||
- jest
|
||||
- @types/passport-jwt
|
||||
- 20260526160916_add_ui_texts_and_scientific_terms/migration.sql
|
||||
- @nestjs/cli
|
||||
- typescript
|
||||
- @nestjs/testing
|
||||
- revalidate/route.ts
|
||||
- MaskableField.tsx
|
||||
- @tailwindcss/postcss
|
||||
- prettier
|
||||
- ts-jest
|
||||
- @types/js-yaml
|
||||
- @types/react-dom
|
||||
- @types/supertest
|
||||
- eslint-plugin-react-refresh
|
||||
- tailwindcss
|
||||
|
||||
## God Nodes (most connected - your core abstractions)
|
||||
1. `Roles()` - 108 edges
|
||||
2. `PrismaService` - 89 edges
|
||||
3. `useSettingsStore` - 61 edges
|
||||
3. `useSettingsStore` - 63 edges
|
||||
4. `SmsService` - 51 edges
|
||||
5. `api` - 44 edges
|
||||
6. `PaginationDto` - 41 edges
|
||||
@ -334,27 +354,27 @@
|
||||
- 3-file cycle: `frontend/application/lib/services/api.ts -> frontend/application/lib/store/userStore.ts -> frontend/application/lib/store/cartStore.ts -> frontend/application/lib/services/api.ts`
|
||||
- 4-file cycle: `frontend/application/lib/services/api.ts -> frontend/application/lib/store/userStore.ts -> frontend/application/lib/store/cartStore.ts -> frontend/application/lib/services/orderService.ts -> frontend/application/lib/services/api.ts`
|
||||
|
||||
## Communities (309 total, 97 thin omitted)
|
||||
## Communities (329 total, 114 thin omitted)
|
||||
|
||||
### Community 0 - "Roles"
|
||||
Cohesion: 0.24
|
||||
Nodes (13): Roles(), PaymentController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Get (+5 more)
|
||||
|
||||
### Community 1 - "app.module.ts"
|
||||
Cohesion: 0.07
|
||||
Nodes (36): B2BModule, Module, BannersModule, Module, CmsModule, Module, SmsModule, Global (+28 more)
|
||||
Cohesion: 0.06
|
||||
Nodes (40): B2BModule, Module, BannersModule, Module, CmsModule, Module, SmsModule, Global (+32 more)
|
||||
|
||||
### Community 2 - "WikiController"
|
||||
Cohesion: 0.13
|
||||
Nodes (13): ApiNotFoundResponse, ApiOkResponse, ApiOperation, ApiTags, Controller, Get, Param, Query (+5 more)
|
||||
Cohesion: 0.21
|
||||
Nodes (9): ApiNotFoundResponse, ApiOkResponse, ApiOperation, ApiTags, Controller, Get, Param, Query (+1 more)
|
||||
|
||||
### Community 3 - "productService.ts"
|
||||
Cohesion: 0.06
|
||||
Nodes (35): B2BPortal, dynamic, GET(), revalidate, DEFAULT_CATEGORIES, dynamic, revalidate, dynamic (+27 more)
|
||||
Nodes (35): dynamic, GET(), revalidate, DEFAULT_CATEGORIES, dynamic, revalidate, dynamic, revalidate (+27 more)
|
||||
|
||||
### Community 4 - "useSettingsStore"
|
||||
Cohesion: 0.08
|
||||
Nodes (30): ClientLayout(), metadata, B2BLandingClient(), BrandLogo(), BrandLogoProps, Footer(), Header(), MENU_ICONS (+22 more)
|
||||
### Community 4 - "toPersian"
|
||||
Cohesion: 0.10
|
||||
Nodes (32): B2BPortal, CartDrawer, ClientLayout(), MobileBottomNav, PrescriptionUploadModal, VerifyContent(), AuthModal(), B2BPortal() (+24 more)
|
||||
|
||||
### Community 5 - "CmsController"
|
||||
Cohesion: 0.09
|
||||
@ -373,16 +393,16 @@ Cohesion: 0.05
|
||||
Nodes (27): SmsEventDefinition, SmsService, Injectable, SmsLogQueryDto, ApiPropertyOptional, IsIn, IsNumber, IsOptional (+19 more)
|
||||
|
||||
### Community 9 - "devDependencies"
|
||||
Cohesion: 0.08
|
||||
Nodes (25): devDependencies, eslint, eslint-config-prettier, @eslint/eslintrc, jest, @nestjs/cli, @nestjs/testing, prettier (+17 more)
|
||||
Cohesion: 0.22
|
||||
Nodes (9): devDependencies, eslint-plugin-prettier, @types/bcryptjs, @types/node, typescript, @types/node, typescript, eslint-plugin-prettier (+1 more)
|
||||
|
||||
### Community 10 - "reviews.controller.ts"
|
||||
### Community 10 - "CreateReviewDto"
|
||||
Cohesion: 0.07
|
||||
Nodes (32): CreateReviewDto, ApiProperty, IsInt, IsNotEmpty, IsOptional, IsString, Min, ApiProperty (+24 more)
|
||||
Nodes (30): CreateReviewDto, ApiProperty, IsInt, IsNotEmpty, IsOptional, IsString, Min, ApiProperty (+22 more)
|
||||
|
||||
### Community 11 - "UsersService"
|
||||
Cohesion: 0.07
|
||||
Nodes (32): AddressDto, ApiProperty, ApiPropertyOptional, IsBoolean, IsNotEmpty, IsOptional, IsString, ApiPropertyOptional (+24 more)
|
||||
Cohesion: 0.05
|
||||
Nodes (42): DEFAULT_JWT_REFRESH_SECRET, DEFAULT_JWT_SECRET, getJwtSecret(), AuthModule, Module, JwtPayload, JwtStrategy, Injectable (+34 more)
|
||||
|
||||
### Community 12 - "index.ts"
|
||||
Cohesion: 0.06
|
||||
@ -392,13 +412,13 @@ Nodes (24): backend, frontend, playwright.config.ts, @playwright/test, tests/**/
|
||||
Cohesion: 0.06
|
||||
Nodes (28): AppModule, Module, EnvironmentVariables, IsNotEmpty, IsOptional, IsString, validateEnv(), CustomHttpExceptionFilter (+20 more)
|
||||
|
||||
### Community 14 - "UserDashboard.tsx"
|
||||
Cohesion: 0.14
|
||||
Nodes (23): AddressFormData, AddressModal(), AddressModalProps, normalizeDigits(), validateAddressForm(), BackButton(), BackButtonProps, CheckoutPage() (+15 more)
|
||||
### Community 14 - "CheckoutPage.tsx"
|
||||
Cohesion: 0.17
|
||||
Nodes (19): AddressFormData, AddressModal(), AddressModalProps, normalizeDigits(), validateAddressForm(), BackButton(), BackButtonProps, CheckoutPage() (+11 more)
|
||||
|
||||
### Community 15 - "src/services/api.ts"
|
||||
Cohesion: 0.06
|
||||
Nodes (38): Layout(), ProtectedRoute(), MenuGroup, Sidebar(), SidebarProps, SubMenuItem, LiveMonitoringSummary, SEARCHABLE_PAGES (+30 more)
|
||||
Nodes (36): Layout(), ProtectedRoute(), MenuGroup, Sidebar(), SidebarProps, SubMenuItem, LiveMonitoringSummary, SEARCHABLE_PAGES (+28 more)
|
||||
|
||||
### Community 16 - "DoctorQueryDto"
|
||||
Cohesion: 0.09
|
||||
@ -409,24 +429,20 @@ Cohesion: 0.14
|
||||
Nodes (18): B2BPage(), generateMetadata(), ContactPage(), generateMetadata(), generateMetadata(), getInitialVideos(), Videos(), ContactFormClient() (+10 more)
|
||||
|
||||
### Community 18 - "JwtAuthGuard"
|
||||
Cohesion: 0.15
|
||||
Nodes (9): JwtAuthGuard, Injectable, B2BService, B2BWholesaleOrderItem, Injectable, ROLES_KEY, RequestWithUser, RolesGuard (+1 more)
|
||||
Cohesion: 0.17
|
||||
Nodes (7): JwtAuthGuard, Injectable, ROLES_KEY, RequestWithUser, RolesGuard, Injectable, UserReqPayload
|
||||
|
||||
### Community 19 - "admin.controller.ts"
|
||||
Cohesion: 0.29
|
||||
Cohesion: 0.35
|
||||
Nodes (12): ApplyGlobalMarginsDto, BulkPriceAdjustmentDto, ApiProperty, ApiPropertyOptional, IsArray, IsBoolean, IsIn, IsNumber (+4 more)
|
||||
|
||||
### Community 20 - "CreateVideoDto"
|
||||
Cohesion: 0.09
|
||||
Nodes (24): CreateVideoDto, ApiProperty, ApiPropertyOptional, IsBoolean, IsNotEmpty, IsOptional, IsString, UpdateVideoDto (+16 more)
|
||||
|
||||
### Community 21 - "HomeClient.tsx"
|
||||
Cohesion: 0.10
|
||||
Nodes (22): HomeClient(), HomeClientProps, getHomeData(), Home(), BannerPlacement(), BannerPlacementProps, BlogPreviewSection(), FAQSection() (+14 more)
|
||||
|
||||
### Community 22 - "ProductDto"
|
||||
Cohesion: 0.16
|
||||
Nodes (7): ProductDto, ApiPropertyOptional, IsArray, IsBoolean, IsNumber, IsOptional, IsString
|
||||
### Community 21 - "useSettingsStore"
|
||||
Cohesion: 0.07
|
||||
Nodes (35): HomeClient(), HomeClientProps, ArchivePage(), B2BLandingClient(), BannerPlacement(), BannerPlacementProps, BlogPreviewSection(), BrandLogo() (+27 more)
|
||||
|
||||
### Community 23 - "MenuService"
|
||||
Cohesion: 0.12
|
||||
@ -466,19 +482,19 @@ Nodes (31): Acceptance Criteria, Affected Application, Affected Files, Alternati
|
||||
|
||||
### Community 32 - "adminRoutes.tsx"
|
||||
Cohesion: 0.07
|
||||
Nodes (16): App(), Props, RouteErrorBoundary, State, HeroBanner, VetTestimonial, SslStatus, AdminRouteConfig (+8 more)
|
||||
Nodes (21): App(), ContactInfoItem, ContactSubmission, CategoryDist, DashboardData, SslStatus, Ticket, TicketMessage (+13 more)
|
||||
|
||||
### Community 33 - "WholesaleApplyDto"
|
||||
Cohesion: 0.10
|
||||
Nodes (20): ApiProperty, ApiPropertyOptional, IsNotEmpty, IsOptional, IsString, WholesaleApplyDto, ApiBearerAuth, ApiOperation (+12 more)
|
||||
|
||||
### Community 34 - "B2BController"
|
||||
Cohesion: 0.14
|
||||
Nodes (13): B2BController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Get, Param (+5 more)
|
||||
|
||||
### Community 35 - "ContactController"
|
||||
### Community 34 - "B2BService"
|
||||
Cohesion: 0.13
|
||||
Nodes (10): ContactController, Body, Controller, Get, Param, Post, Put, Query (+2 more)
|
||||
Nodes (15): B2BController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Get, Param (+7 more)
|
||||
|
||||
### Community 35 - "ContactService"
|
||||
Cohesion: 0.13
|
||||
Nodes (12): ContactController, Body, Controller, Get, Param, Post, Put, Query (+4 more)
|
||||
|
||||
### Community 36 - "FaqService"
|
||||
Cohesion: 0.14
|
||||
@ -508,13 +524,13 @@ Nodes (26): For /graphify add and --watch, For /graphify query, For the commit h
|
||||
Cohesion: 0.13
|
||||
Nodes (14): SslController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Get, Post (+6 more)
|
||||
|
||||
### Community 43 - "BannersController"
|
||||
### Community 43 - "BannersService"
|
||||
Cohesion: 0.13
|
||||
Nodes (13): BannersController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Delete, Get (+5 more)
|
||||
Nodes (15): BannersController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Delete, Get (+7 more)
|
||||
|
||||
### Community 44 - "TestimonialsController"
|
||||
### Community 44 - "TestimonialsService"
|
||||
Cohesion: 0.13
|
||||
Nodes (12): TestimonialsController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Delete, Get (+4 more)
|
||||
Nodes (14): TestimonialsController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Delete, Get (+6 more)
|
||||
|
||||
### Community 45 - "What You Must Do When Invoked"
|
||||
Cohesion: 0.07
|
||||
@ -524,9 +540,9 @@ Nodes (26): For /graphify add and --watch, For /graphify query, For the commit h
|
||||
Cohesion: 0.27
|
||||
Nodes (14): "coupons", "health_logs", "order_items", "orders", "pet_medical_conditions", "pets", "product_ingredients", "product_symptoms" (+6 more)
|
||||
|
||||
### Community 47 - "IngredientsController"
|
||||
### Community 47 - "IngredientsService"
|
||||
Cohesion: 0.13
|
||||
Nodes (12): IngredientsController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Delete, Get (+4 more)
|
||||
Nodes (14): IngredientsController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Delete, Get (+6 more)
|
||||
|
||||
### Community 48 - "app.e2e-spec.js"
|
||||
Cohesion: 0.50
|
||||
@ -538,23 +554,23 @@ Nodes (19): autoprefixer, devDependencies, autoprefixer, eslint, @eslint/js, glo
|
||||
|
||||
### Community 50 - "devDependencies"
|
||||
Cohesion: 0.12
|
||||
Nodes (17): devDependencies, eslint, jsdom, tailwindcss, @testing-library/jest-dom, @testing-library/react, @types/node, @types/react (+9 more)
|
||||
Nodes (17): eslint-config-next, devDependencies, eslint, eslint-config-next, jsdom, @testing-library/jest-dom, @testing-library/react, @types/node (+9 more)
|
||||
|
||||
### Community 51 - "BlogsController"
|
||||
Cohesion: 0.07
|
||||
Nodes (18): BlogsController, ApiBearerAuth, ApiOperation, ApiQuery, ApiTags, Body, Controller, Delete (+10 more)
|
||||
|
||||
### Community 52 - "prescriptions.controller.ts"
|
||||
Cohesion: 0.11
|
||||
Nodes (17): PrescriptionsController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Get, Param (+9 more)
|
||||
### Community 52 - "PrescriptionsService"
|
||||
Cohesion: 0.14
|
||||
Nodes (14): PrescriptionsController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Get, Param (+6 more)
|
||||
|
||||
### Community 53 - "SmartAdvisorService"
|
||||
Cohesion: 0.13
|
||||
Nodes (14): SmartAdvisorController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Delete, Get (+6 more)
|
||||
|
||||
### Community 54 - "Button.tsx"
|
||||
Cohesion: 0.07
|
||||
Nodes (24): ButtonProps, ButtonSize, ButtonVariant, maxWidthClasses, Modal(), ModalProps, ContactInfoItem, ContactSubmission (+16 more)
|
||||
Cohesion: 0.10
|
||||
Nodes (16): ButtonProps, ButtonSize, ButtonVariant, ConfirmModal(), ConfirmModalProps, HeroBanner, VetTestimonial, FAQ (+8 more)
|
||||
|
||||
### Community 55 - "UITexts.tsx"
|
||||
Cohesion: 0.08
|
||||
@ -569,48 +585,48 @@ Cohesion: 0.09
|
||||
Nodes (22): CREATE MODE — Normal Operation, Expected JSON Output Schema, File Scope Boundary, Forbidden Actions, MODE 1: REVIEW (called during Review Phase), MODE 2: CONTENT CREATION (standalone task from backlog), Operating Modes, Operational Rules & Boundaries (+14 more)
|
||||
|
||||
### Community 58 - "RedisService"
|
||||
Cohesion: 0.14
|
||||
Nodes (6): Optional, RedisModule, Global, Module, RedisService, Injectable
|
||||
Cohesion: 0.08
|
||||
Nodes (11): ApiExcludeController, Optional, MetricsController, Controller, Get, Res, RedisModule, Global (+3 more)
|
||||
|
||||
### Community 59 - "compilerOptions"
|
||||
Cohesion: 0.06
|
||||
Nodes (30): compilerOptions, allowSyntheticDefaultImports, baseUrl, declaration, emitDecoratorMetadata, esModuleInterop, experimentalDecorators, forceConsistentCasingInFileNames (+22 more)
|
||||
|
||||
### Community 60 - "CreateUserDto"
|
||||
Cohesion: 0.24
|
||||
Cohesion: 0.23
|
||||
Nodes (10): CreateUserDto, ApiProperty, ApiPropertyOptional, IsEmail, IsNotEmpty, IsNumber, IsOptional, IsString (+2 more)
|
||||
|
||||
### Community 61 - "ProductPage.tsx"
|
||||
Cohesion: 0.11
|
||||
Nodes (38): VerifyContent(), ArchivePage(), ArchiveProductCard(), ArchiveProductListItem(), CATEGORY_MAP, ICON_MAP, B2BPortal(), CartDrawer() (+30 more)
|
||||
Nodes (27): ArchiveProductCard(), ArchiveProductListItem(), CATEGORY_MAP, ICON_MAP, FeaturedProducts(), ProductCard(), ProductImageZoomModalProps, CalculatorState (+19 more)
|
||||
|
||||
### Community 62 - "admin.module.ts"
|
||||
Cohesion: 0.05
|
||||
Nodes (30): AdminModule, Module, MediaService, Injectable, PetsController, ApiBearerAuth, ApiOperation, ApiQuery (+22 more)
|
||||
Cohesion: 0.04
|
||||
Nodes (33): AdminModule, Module, MediaService, Injectable, PetsController, ApiBearerAuth, ApiOperation, ApiQuery (+25 more)
|
||||
|
||||
### Community 63 - "dependencies"
|
||||
Cohesion: 0.05
|
||||
Nodes (43): dependencies, bcrypt, bcryptjs, class-transformer, class-validator, compression, helmet, ioredis (+35 more)
|
||||
Cohesion: 0.09
|
||||
Nodes (23): dependencies, bcrypt, bcryptjs, class-validator, compression, ioredis, @nestjs/common, @nestjs/passport (+15 more)
|
||||
|
||||
### Community 64 - "compilerOptions"
|
||||
Cohesion: 0.10
|
||||
Nodes (20): compilerOptions, allowImportingTsExtensions, erasableSyntaxOnly, lib, module, moduleDetection, moduleResolution, noEmit (+12 more)
|
||||
|
||||
### Community 65 - "admin.service.ts"
|
||||
Cohesion: 0.22
|
||||
Nodes (8): CouponTargetInput, PaginationQuery, applyRounding(), calculateSellingPrice(), DEFAULT_PRICING_SETTINGS, PricingSettings, RoundingMode, CANONICAL_ALIASES
|
||||
Cohesion: 0.14
|
||||
Nodes (15): CouponTargetInput, PaginationQuery, ProductDto, ApiPropertyOptional, IsArray, IsBoolean, IsNumber, IsOptional (+7 more)
|
||||
|
||||
### Community 66 - "AdminQueryDto"
|
||||
Cohesion: 0.18
|
||||
Cohesion: 0.13
|
||||
Nodes (8): ApiQuery, Get, Query, AdminProductQueryDto, AdminQueryDto, ApiPropertyOptional, IsOptional, IsString
|
||||
|
||||
### Community 67 - "ConfirmModal.tsx"
|
||||
Cohesion: 0.10
|
||||
Nodes (16): ConfirmModal(), ConfirmModalProps, Pagination(), PaginationProps, Category, Pet, DoctorOption, Video (+8 more)
|
||||
### Community 67 - "pets/pets.controller.ts"
|
||||
Cohesion: 0.12
|
||||
Nodes (15): CreatePetDto, ApiProperty, ApiPropertyOptional, IsArray, IsNotEmpty, IsNumber, IsOptional, IsString (+7 more)
|
||||
|
||||
### Community 68 - "lib/services/api.ts"
|
||||
Cohesion: 0.09
|
||||
Nodes (16): BlogPost, ContactInfoItem, FAQItem, Testimonial, api, ApiErrorPayload, BASE_DOMAIN, baseURL (+8 more)
|
||||
Nodes (24): BlogPost, ContactInfoItem, DeleteConfirmModal(), DeleteConfirmModalProps, OrderDetailsModal(), OrderDetailsModalProps, ProductReviews, ProductReviews() (+16 more)
|
||||
|
||||
### Community 69 - "Required Review Group Closures"
|
||||
Cohesion: 0.10
|
||||
@ -637,8 +653,8 @@ Cohesion: 0.13
|
||||
Nodes (14): ApiBearerAuth, ApiOperation, ApiQuery, ApiTags, Body, Controller, Delete, Get (+6 more)
|
||||
|
||||
### Community 75 - "PetsController"
|
||||
Cohesion: 0.05
|
||||
Nodes (47): CreateHealthLogDto, ApiProperty, ApiPropertyOptional, IsNotEmpty, IsOptional, IsString, CreatePetDto, ApiProperty (+39 more)
|
||||
Cohesion: 0.08
|
||||
Nodes (32): CreateHealthLogDto, ApiProperty, ApiPropertyOptional, IsNotEmpty, IsOptional, IsString, CreateReminderDto, ApiProperty (+24 more)
|
||||
|
||||
### Community 76 - "RevalidationService"
|
||||
Cohesion: 0.07
|
||||
@ -677,7 +693,7 @@ Cohesion: 0.12
|
||||
Nodes (16): 1. Active Secret Scanning (All Modified Files), 2. Docker Container Verification (if Dockerfile exists), 3. CI/CD Basic Check (if `.github/workflows/` exists), 4. Failure Routing Protocol, 5. Forbidden Actions, ENFORCE MODE — Normal Operation, Expected JSON Output Schema, Operational Rules & Boundaries (+8 more)
|
||||
|
||||
### Community 85 - "AuthController"
|
||||
Cohesion: 0.25
|
||||
Cohesion: 0.27
|
||||
Nodes (13): AuthController, ApiBadRequestResponse, ApiBearerAuth, ApiOkResponse, ApiOperation, ApiTags, Body, Controller (+5 more)
|
||||
|
||||
### Community 86 - "zibal.service.ts"
|
||||
@ -696,9 +712,9 @@ Nodes (8): CreateEBankCheckoutDto, ApiProperty, ApiPropertyOptional, IsNotEmpty,
|
||||
Cohesion: 0.17
|
||||
Nodes (12): prisma, main(), prisma, determineSuitableFor(), findOrCreateCategory(), getProductImageUrl(), main(), parseSize() (+4 more)
|
||||
|
||||
### Community 90 - "PetProfile.tsx"
|
||||
Cohesion: 0.12
|
||||
Nodes (11): OrderDetailsModal(), OrderRowSkeleton(), PetProfileSkeleton(), ProductListSkeleton(), Skeleton(), SkeletonProps, HealthLog, PetConsumption (+3 more)
|
||||
### Community 90 - "SmartAdvisor.tsx"
|
||||
Cohesion: 0.24
|
||||
Nodes (7): metadata, CURRENT_SYMPTOMS, MEDICAL_HISTORIES, SmartAdvisor(), SmartAdvisorProps, UIState, useUIStore
|
||||
|
||||
### Community 91 - "Reconciled Audit Roles & Assignments"
|
||||
Cohesion: 0.12
|
||||
@ -709,24 +725,24 @@ Cohesion: 0.07
|
||||
Nodes (29): CreateOrderDto, OrderItemDto, ApiProperty, ApiPropertyOptional, IsArray, IsNotEmpty, IsNumber, IsOptional (+21 more)
|
||||
|
||||
### Community 93 - "auth.service.ts"
|
||||
Cohesion: 0.13
|
||||
Nodes (14): AdminLoginInput, LoginInput, RegisterInput, SendOtpDto, ApiProperty, IsNotEmpty, IsString, Matches (+6 more)
|
||||
Cohesion: 0.22
|
||||
Nodes (8): AdminLoginInput, LoginInput, RegisterInput, SendOtpDto, ApiProperty, IsNotEmpty, IsString, Matches
|
||||
|
||||
### Community 94 - "Phase 3.1 — Human Review Preparation and Master Backlog Critique"
|
||||
Cohesion: 0.13
|
||||
Nodes (14): 10. Dependency & Wave Adjustments, 11. Acceptance Criteria Refinements, 12. Business and Product Decision Classification, 13. Final Recommended Backlog Summary, 1. Executive Assessment, 2. Findings That Require No Change, 3. Findings Requiring Task Refinements, 4. Tasks Requiring Splitting (+6 more)
|
||||
|
||||
### Community 95 - "wiki/[slug]/page.tsx"
|
||||
Cohesion: 0.18
|
||||
Nodes (17): BlogPostPage(), generateMetadata(), getBlog(), revalidate, safeIso(), safeLocalDate(), generateMetadata(), revalidate (+9 more)
|
||||
### Community 95 - "getSeoConfig"
|
||||
Cohesion: 0.24
|
||||
Nodes (12): BlogPostPage(), generateMetadata(), getBlog(), revalidate, safeIso(), safeLocalDate(), generateMetadata(), revalidate (+4 more)
|
||||
|
||||
### Community 96 - "compilerOptions"
|
||||
Cohesion: 0.06
|
||||
Nodes (32): compilerOptions, allowJs, esModuleInterop, incremental, isolatedModules, jsx, lib, module (+24 more)
|
||||
|
||||
### Community 97 - "PaymentService"
|
||||
Cohesion: 0.10
|
||||
Nodes (9): AdminTransactionFilterDto, ApiPropertyOptional, IsIn, IsNumber, IsOptional, IsString, Type, PaymentService (+1 more)
|
||||
### Community 97 - "AdminTransactionFilterDto"
|
||||
Cohesion: 0.25
|
||||
Nodes (7): AdminTransactionFilterDto, ApiPropertyOptional, IsIn, IsNumber, IsOptional, IsString, Type
|
||||
|
||||
### Community 98 - "scripts"
|
||||
Cohesion: 0.13
|
||||
@ -753,8 +769,8 @@ Cohesion: 0.15
|
||||
Nodes (12): 10. `TASK-VERIFY-001`, 1. `TASK-SEC-001`, 2. `TASK-SEC-002`, 3. `TASK-SEC-003`, 4. `TASK-FIN-001`, 5. `TASK-BUILD-001`, 6. `TASK-AUTH-001`, 7. `TASK-FE-001` (+4 more)
|
||||
|
||||
### Community 104 - "Products.tsx"
|
||||
Cohesion: 0.09
|
||||
Nodes (25): Input, InputProps, formatPriceWithCommas(), PriceInput(), PriceInputProps, toEnglishDigits(), Coupon, CouponFormData (+17 more)
|
||||
Cohesion: 0.10
|
||||
Nodes (24): Input, InputProps, formatPriceWithCommas(), PriceInput(), PriceInputProps, toEnglishDigits(), Coupon, CouponFormData (+16 more)
|
||||
|
||||
### Community 105 - "Operational Rules & Boundaries"
|
||||
Cohesion: 0.17
|
||||
@ -765,12 +781,12 @@ Cohesion: 0.43
|
||||
Nodes (7): InitiatePaymentDto, InitiateWalletTopupDto, ApiProperty, ApiPropertyOptional, IsNotEmpty, IsOptional, IsString
|
||||
|
||||
### Community 107 - "PaginationDto"
|
||||
Cohesion: 0.06
|
||||
Nodes (25): BlogsModule, Module, BlogFilterDto, BlogsService, Injectable, PaginationDto, SortOrder, ApiPropertyOptional (+17 more)
|
||||
Cohesion: 0.05
|
||||
Nodes (29): BlogsModule, Module, BlogFilterDto, BlogsService, Injectable, PaginationDto, SortOrder, ApiPropertyOptional (+21 more)
|
||||
|
||||
### Community 108 - "PrismaService"
|
||||
Cohesion: 0.05
|
||||
Nodes (26): ApiExcludeController, CategoryQuery, WikiQuery, BannersService, Injectable, MetricsController, Controller, Get (+18 more)
|
||||
Cohesion: 0.06
|
||||
Nodes (26): CategoryQuery, B2BWholesaleOrderItem, DEFAULT_SMS_RULES, SMS_EVENT_DEFINITIONS, SmsEventVariable, SmsRule, MeliPayamakPattern, MeliPayamakResponse (+18 more)
|
||||
|
||||
### Community 109 - "1. Summary of Integrity Repairs Performed"
|
||||
Cohesion: 0.17
|
||||
@ -788,17 +804,17 @@ Nodes (10): 1. Mark Active Task as Complete, 2. Documentation Updates, 3. Dynami
|
||||
Cohesion: 0.18
|
||||
Nodes (10): 1. Pre-Deployment Checklist, 2. Build Verification, 3. Deployment Strategy (Based on Target), 4. Post-Deployment Health Check, 5. Forbidden Actions, Expected JSON Output Schema, Operational Rules & Boundaries, Required Output Artifacts (What files to write/update) (+2 more)
|
||||
|
||||
### Community 113 - "sms.service.ts"
|
||||
Cohesion: 0.12
|
||||
Nodes (13): DEFAULT_SMS_RULES, SMS_EVENT_DEFINITIONS, SmsEventVariable, SmsRule, MeliPayamakPattern, MeliPayamakResponse, SendPatternSmsOptions, SmsConfig (+5 more)
|
||||
### Community 113 - "orderService.ts"
|
||||
Cohesion: 0.20
|
||||
Nodes (4): ApiErr, Order, OrderItem, OrderService
|
||||
|
||||
### Community 114 - "AppService"
|
||||
Cohesion: 0.29
|
||||
Nodes (5): AppController, Controller, Get, AppService, Injectable
|
||||
|
||||
### Community 115 - "Spinner.tsx"
|
||||
Cohesion: 0.10
|
||||
Nodes (22): ImagePreviewModal(), ImagePreviewModalProps, getFileType(), Media, MediaSelector(), MediaSelectorProps, Spinner(), Doctor (+14 more)
|
||||
Cohesion: 0.07
|
||||
Nodes (36): ImagePreviewModal(), ImagePreviewModalProps, getFileType(), Media, MediaSelector(), MediaSelectorProps, maxWidthClasses, Modal() (+28 more)
|
||||
|
||||
### Community 116 - "Vazirmatn Changelog"
|
||||
Cohesion: 0.18
|
||||
@ -824,13 +840,13 @@ Nodes (9): compilerOptions, esModuleInterop, module, moduleResolution, skipLibCh
|
||||
Cohesion: 0.20
|
||||
Nodes (9): Compile and run the project, Deployment, Description, License, Project setup, Resources, Run tests, Stay in touch (+1 more)
|
||||
|
||||
### Community 122 - "AdminService"
|
||||
Cohesion: 0.10
|
||||
Nodes (11): AdminController, ApiBearerAuth, ApiOperation, ApiTags, Controller, Delete, Param, Put (+3 more)
|
||||
### Community 122 - "AdminController"
|
||||
Cohesion: 0.17
|
||||
Nodes (12): AdminController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Delete, Param (+4 more)
|
||||
|
||||
### Community 123 - "Body"
|
||||
Cohesion: 0.20
|
||||
Nodes (3): Body, Post, CouponInput
|
||||
### Community 123 - "RouteErrorBoundary"
|
||||
Cohesion: 0.22
|
||||
Nodes (3): Props, RouteErrorBoundary, State
|
||||
|
||||
### Community 124 - "Repository Map"
|
||||
Cohesion: 0.20
|
||||
@ -852,9 +868,9 @@ Nodes (9): Arch Linux, Contributors, Install, Known problems for variable versio
|
||||
Cohesion: 0.16
|
||||
Nodes (10): HomeController, ApiOkResponse, ApiOperation, ApiTags, Controller, Get, HomeModule, Module (+2 more)
|
||||
|
||||
### Community 129 - "auth.module.ts"
|
||||
Cohesion: 0.18
|
||||
Nodes (10): DEFAULT_JWT_REFRESH_SECRET, DEFAULT_JWT_SECRET, getJwtSecret(), AuthModule, Module, JwtPayload, JwtStrategy, Injectable (+2 more)
|
||||
### Community 129 - "LoginDto"
|
||||
Cohesion: 0.33
|
||||
Nodes (5): LoginDto, ApiProperty, IsNotEmpty, IsString, MinLength
|
||||
|
||||
### Community 130 - "Sahel-Font"
|
||||
Cohesion: 0.20
|
||||
@ -914,11 +930,11 @@ Nodes (6): app_module_1, core_1, fs, path, swagger_1, yaml
|
||||
|
||||
### Community 144 - "SafeImage.tsx"
|
||||
Cohesion: 0.09
|
||||
Nodes (25): buildTorobProductSpec(), buildTorobProductTitle(), dynamic, GET(), revalidate, BlogPostClientProps, OrderDetailsModalProps, PLAYBACK_RATES (+17 more)
|
||||
Nodes (26): buildTorobProductSpec(), buildTorobProductTitle(), dynamic, GET(), revalidate, BlogPostClientProps, PLAYBACK_RATES, PodcastInlinePlayer() (+18 more)
|
||||
|
||||
### Community 145 - "auth.controller.ts"
|
||||
Cohesion: 0.16
|
||||
Nodes (11): AdminLoginDto, ApiProperty, IsEmail, IsNotEmpty, IsString, MinLength, LoginDto, ApiProperty (+3 more)
|
||||
### Community 145 - "AdminLoginDto"
|
||||
Cohesion: 0.29
|
||||
Nodes (6): AdminLoginDto, ApiProperty, IsEmail, IsNotEmpty, IsString, MinLength
|
||||
|
||||
### Community 146 - "System Discovery"
|
||||
Cohesion: 0.25
|
||||
@ -941,8 +957,8 @@ Cohesion: 0.29
|
||||
Nodes (6): 1. Executive Vision, 2. Target Audience, 3. Functional Requirements, 4. Non-Functional Requirements (Performance, Security), 5. Epic / Feature Breakdown, Product Requirement Document (PRD)
|
||||
|
||||
### Community 152 - "AuthService"
|
||||
Cohesion: 0.15
|
||||
Nodes (3): AuthService, Injectable, normalizeMobile()
|
||||
Cohesion: 0.13
|
||||
Nodes (9): AuthService, Injectable, ApiProperty, IsNotEmpty, IsString, Matches, VerifyOtpDto, normalizeMobile() (+1 more)
|
||||
|
||||
### Community 153 - "exclude"
|
||||
Cohesion: 0.22
|
||||
@ -1032,6 +1048,10 @@ Nodes (4): activeFiles, errors, validationOutput, warnings
|
||||
Cohesion: 0.53
|
||||
Nodes (5): dynamic, GET(), getCandidateUrls(), getMimeType(), HEAD()
|
||||
|
||||
### Community 177 - "Reviews.tsx"
|
||||
Cohesion: 0.40
|
||||
Nodes (5): BlogCommentItem, ProductReview, Reviews(), toPersianDigits(), Reviews
|
||||
|
||||
### Community 178 - "نقشه جامع پوشش تستهای سرتاسری (E2E Test Coverage Map) — پروژه Canina"
|
||||
Cohesion: 0.33
|
||||
Nodes (5): نقشه جامع پوشش تستهای سرتاسری (E2E Test Coverage Map) — پروژه Canina, ۱. معماری و نقشهای کاربری (User Roles), ۲. ماتریس جریانها و قابلیتهای کاربرمحور (Feature & Flow Matrix), ۳. وضعیت پوشش نهایی سوئیت ۱۱گانه (Final 11 Test Suites Status), ۴. راهنمای نگهداری و افزودن فیچرهای جدید بدون شکستن تستها (Developer Maintenance Guide)
|
||||
@ -1052,6 +1072,10 @@ Nodes (3): Architectural Overview, Critical Review Findings & Required Enhanceme
|
||||
Cohesion: 0.50
|
||||
Nodes (3): Overview & Content Foundation, SEO & Content Requirements, 🚀 SEO & Content Strategy Review (12_seo_content)
|
||||
|
||||
### Community 185 - "wiki/[slug]/page.tsx"
|
||||
Cohesion: 0.60
|
||||
Nodes (5): generateMetadata(), getRelatedProducts(), getWikiTerm(), WikiTermPage(), generateMedicalWebPageSchema()
|
||||
|
||||
### Community 191 - "graphify reference: add a URL and watch a folder"
|
||||
Cohesion: 0.50
|
||||
Nodes (3): For /graphify add, For --watch, graphify reference: add a URL and watch a folder
|
||||
@ -1076,9 +1100,13 @@ Nodes (3): Expanding the ESLint configuration, React Compiler, React + TypeScrip
|
||||
Cohesion: 0.50
|
||||
Nodes (3): Select, SelectOption, SelectProps
|
||||
|
||||
### Community 197 - "userStore.ts"
|
||||
Cohesion: 0.07
|
||||
Nodes (27): AuthModal, CartDrawer, LoginModal, AuthModal(), AuthModalProps, extractOtpFromText(), otpCooldownExpiries, IMPORTANT: only depend on isOpen here — NOT subView. If we depend on subView, (+19 more)
|
||||
### Community 197 - "AuthModal.tsx"
|
||||
Cohesion: 0.08
|
||||
Nodes (19): AuthModal, LoginModal, AuthModalProps, extractOtpFromText(), otpCooldownExpiries, IMPORTANT: only depend on isOpen here — NOT subView. If we depend on subView,, extractOtpFromText(), LoginModal() (+11 more)
|
||||
|
||||
### Community 198 - "app/page.tsx"
|
||||
Cohesion: 0.67
|
||||
Nodes (3): generateMetadata(), getHomeData(), Home()
|
||||
|
||||
### Community 200 - "application/README.md"
|
||||
Cohesion: 0.50
|
||||
@ -1096,6 +1124,10 @@ Nodes (3): ADR-AUTH-001: Admin Panel Authentication Architecture & Token Managem
|
||||
Cohesion: 0.67
|
||||
Nodes (3): Shabnam Font README, Shabnam Font Sample, Vazir Font
|
||||
|
||||
### Community 294 - "ZibalService"
|
||||
Cohesion: 0.09
|
||||
Nodes (4): PaymentService, Injectable, Injectable, ZibalService
|
||||
|
||||
### Community 298 - ".initiateOrderPayment"
|
||||
Cohesion: 0.20
|
||||
Nodes (10): ApiPropertyOptional, IsOptional, IsString, ZibalCallbackQueryDto, ApiBadRequestResponse, ApiOkResponse, Req, Res (+2 more)
|
||||
@ -1105,24 +1137,24 @@ Cohesion: 0.83
|
||||
Nodes (3): GET(), handleRevalidate(), POST()
|
||||
|
||||
## Knowledge Gaps
|
||||
- **1355 isolated node(s):** `$schema`, `collection`, `sourceRoot`, `deleteOutDir`, `name` (+1350 more)
|
||||
- **1356 isolated node(s):** `$schema`, `collection`, `sourceRoot`, `deleteOutDir`, `name` (+1351 more)
|
||||
These have ≤1 connection - possible missing edges or undocumented components.
|
||||
- **97 thin communities (<3 nodes) omitted from report** — run `graphify query` to explore isolated nodes.
|
||||
- **114 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 `Roles()` connect `Roles` to `WholesaleApplyDto`, `B2BController`, `ContactController`, `FaqService`, `CmsController`, `tickets.controller.ts`, `SmsService`, `SslController`, `BannersController`, `RevalidationService`, `reviews.controller.ts`, `TestimonialsController`, `IngredientsController`, `JwtAuthGuard`, `prescriptions.controller.ts`, `SmartAdvisorService`, `MenuService`?**
|
||||
- **Why does `Roles()` connect `Roles` to `WholesaleApplyDto`, `B2BService`, `ContactService`, `FaqService`, `CmsController`, `tickets.controller.ts`, `SmsService`, `SslController`, `BannersService`, `RevalidationService`, `CreateReviewDto`, `TestimonialsService`, `IngredientsService`, `JwtAuthGuard`, `PrescriptionsService`, `SmartAdvisorService`, `MenuService`?**
|
||||
_High betweenness centrality (0.093) - this node is a cross-community bridge._
|
||||
- **Why does `ApiResponse` connect `src/services/api.ts` to `HomeController`, `WikiController`, `BlogsController`, `PetsController`, `RevalidationService`, `UsersService`, `AuthController`, `OrdersService`?**
|
||||
_High betweenness centrality (0.066) - this node is a cross-community bridge._
|
||||
- **Why does `JwtAuthGuard` connect `JwtAuthGuard` to `CmsController`, `tickets.controller.ts`, `reviews.controller.ts`, `PaginationDto`, `PrismaService`, `PetsController`, `RevalidationService`, `auth.controller.ts`, `admin.controller.ts`, `prescriptions.controller.ts`, `admin.module.ts`?**
|
||||
- **Why does `JwtAuthGuard` connect `JwtAuthGuard` to `pets/pets.controller.ts`, `CmsController`, `tickets.controller.ts`, `PaginationDto`, `RevalidationService`, `PrismaService`, `DoctorQueryDto`, `admin.controller.ts`, `auth.service.ts`, `admin.module.ts`?**
|
||||
_High betweenness centrality (0.030) - this node is a cross-community bridge._
|
||||
- **What connects `$schema`, `collection`, `sourceRoot` to the rest of the system?**
|
||||
_1355 weakly-connected nodes found - possible documentation gaps or missing edges._
|
||||
_1356 weakly-connected nodes found - possible documentation gaps or missing edges._
|
||||
- **Should `app.module.ts` be split into smaller, more focused modules?**
|
||||
_Cohesion score 0.06531986531986532 - nodes in this community are weakly interconnected._
|
||||
- **Should `WikiController` be split into smaller, more focused modules?**
|
||||
_Cohesion score 0.12554112554112554 - nodes in this community are weakly interconnected._
|
||||
_Cohesion score 0.059562841530054644 - nodes in this community are weakly interconnected._
|
||||
- **Should `productService.ts` be split into smaller, more focused modules?**
|
||||
_Cohesion score 0.061955965181771634 - nodes in this community are weakly interconnected._
|
||||
_Cohesion score 0.06187202538339503 - nodes in this community are weakly interconnected._
|
||||
- **Should `toPersian` be split into smaller, more focused modules?**
|
||||
_Cohesion score 0.1011764705882353 - nodes in this community are weakly interconnected._
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -1,16 +1,16 @@
|
||||
# Graph Report - canina (2026-09-06)
|
||||
|
||||
## Corpus Check
|
||||
- 604 files · ~1,119,699 words
|
||||
- 604 files · ~1,120,105 words
|
||||
- Verdict: corpus is large enough that graph structure adds value.
|
||||
|
||||
## Summary
|
||||
- 4258 nodes · 7823 edges · 329 communities (215 shown, 114 thin omitted)
|
||||
- 4258 nodes · 7827 edges · 333 communities (219 shown, 114 thin omitted)
|
||||
- Extraction: 96% EXTRACTED · 4% INFERRED · 0% AMBIGUOUS · INFERRED: 298 edges (avg confidence: 0.79)
|
||||
- Token cost: 0 input · 0 output
|
||||
|
||||
## Graph Freshness
|
||||
- Built from commit: `808b5c58`
|
||||
- Built from commit: `1c98f1bf`
|
||||
- Run `git rev-parse HEAD` and compare to check if the graph is stale.
|
||||
- Run `graphify update .` after code changes (no API cost).
|
||||
|
||||
@ -19,7 +19,7 @@
|
||||
- app.module.ts
|
||||
- WikiController
|
||||
- productService.ts
|
||||
- toPersian
|
||||
- PetsController
|
||||
- CmsController
|
||||
- tickets.controller.ts
|
||||
- SmsSettingsPage.tsx
|
||||
@ -29,7 +29,7 @@
|
||||
- UsersService
|
||||
- index.ts
|
||||
- app-audit-verification.e2e-spec.js
|
||||
- CheckoutPage.tsx
|
||||
- toPersian
|
||||
- src/services/api.ts
|
||||
- DoctorQueryDto
|
||||
- schema.ts
|
||||
@ -77,7 +77,7 @@
|
||||
- compilerOptions
|
||||
- CreateUserDto
|
||||
- ProductPage.tsx
|
||||
- admin.module.ts
|
||||
- ReportsController
|
||||
- dependencies
|
||||
- compilerOptions
|
||||
- admin.service.ts
|
||||
@ -128,7 +128,7 @@
|
||||
- Operational Rules & Boundaries
|
||||
- Operational Rules & Boundaries
|
||||
- Operational Rules & Boundaries
|
||||
- orderService.ts
|
||||
- cartStore.ts
|
||||
- AppService
|
||||
- Spinner.tsx
|
||||
- Vazirmatn Changelog
|
||||
@ -211,7 +211,7 @@
|
||||
- Raw Finding Verification & Disposition Report
|
||||
- React + TypeScript + Vite
|
||||
- Select.tsx
|
||||
- AuthModal.tsx
|
||||
- ClientLayout.tsx
|
||||
- app/page.tsx
|
||||
- prisma
|
||||
- application/README.md
|
||||
@ -305,7 +305,7 @@
|
||||
- @nestjs/schematics
|
||||
- reflect-metadata
|
||||
- swagger-ui-express
|
||||
- eslint
|
||||
- components/Skeleton.tsx
|
||||
- eslint-config-prettier
|
||||
- @eslint/eslintrc
|
||||
- jest
|
||||
@ -323,7 +323,11 @@
|
||||
- @types/react-dom
|
||||
- @types/supertest
|
||||
- eslint-plugin-react-refresh
|
||||
- tailwindcss
|
||||
- orders.service.ts
|
||||
- videos.controller.ts
|
||||
- WikiService
|
||||
- eslint-plugin-prettier
|
||||
- eslint-config-next
|
||||
|
||||
## God Nodes (most connected - your core abstractions)
|
||||
1. `Roles()` - 108 edges
|
||||
@ -350,19 +354,19 @@
|
||||
backend/src/orders/orders.controller.ts → frontend/admin-panel/src/types/admin.ts
|
||||
|
||||
## Import Cycles
|
||||
- 3-file cycle: `frontend/application/lib/services/api.ts -> frontend/application/lib/store/userStore.ts -> frontend/application/lib/services/authService.ts -> frontend/application/lib/services/api.ts`
|
||||
- 3-file cycle: `frontend/application/lib/services/api.ts -> frontend/application/lib/store/userStore.ts -> frontend/application/lib/store/cartStore.ts -> frontend/application/lib/services/api.ts`
|
||||
- 3-file cycle: `frontend/application/lib/services/api.ts -> frontend/application/lib/store/userStore.ts -> frontend/application/lib/services/authService.ts -> frontend/application/lib/services/api.ts`
|
||||
- 4-file cycle: `frontend/application/lib/services/api.ts -> frontend/application/lib/store/userStore.ts -> frontend/application/lib/store/cartStore.ts -> frontend/application/lib/services/orderService.ts -> frontend/application/lib/services/api.ts`
|
||||
|
||||
## Communities (329 total, 114 thin omitted)
|
||||
## Communities (333 total, 114 thin omitted)
|
||||
|
||||
### Community 0 - "Roles"
|
||||
Cohesion: 0.24
|
||||
Nodes (13): Roles(), PaymentController, ApiBearerAuth, ApiOperation, ApiTags, Body, Controller, Get (+5 more)
|
||||
|
||||
### Community 1 - "app.module.ts"
|
||||
Cohesion: 0.06
|
||||
Nodes (40): B2BModule, Module, BannersModule, Module, CmsModule, Module, SmsModule, Global (+32 more)
|
||||
Cohesion: 0.07
|
||||
Nodes (38): B2BModule, Module, BannersModule, Module, CmsModule, Module, SmsModule, Global (+30 more)
|
||||
|
||||
### Community 2 - "WikiController"
|
||||
Cohesion: 0.21
|
||||
@ -370,11 +374,11 @@ Nodes (9): ApiNotFoundResponse, ApiOkResponse, ApiOperation, ApiTags, Controller
|
||||
|
||||
### Community 3 - "productService.ts"
|
||||
Cohesion: 0.06
|
||||
Nodes (35): dynamic, GET(), revalidate, DEFAULT_CATEGORIES, dynamic, revalidate, dynamic, revalidate (+27 more)
|
||||
Nodes (33): dynamic, GET(), revalidate, DEFAULT_CATEGORIES, dynamic, revalidate, dynamic, revalidate (+25 more)
|
||||
|
||||
### Community 4 - "toPersian"
|
||||
Cohesion: 0.10
|
||||
Nodes (32): B2BPortal, CartDrawer, ClientLayout(), MobileBottomNav, PrescriptionUploadModal, VerifyContent(), AuthModal(), B2BPortal() (+24 more)
|
||||
### Community 4 - "PetsController"
|
||||
Cohesion: 0.15
|
||||
Nodes (11): PetsController, ApiBearerAuth, ApiOperation, ApiQuery, ApiTags, Controller, Delete, Get (+3 more)
|
||||
|
||||
### Community 5 - "CmsController"
|
||||
Cohesion: 0.09
|
||||
@ -394,7 +398,7 @@ Nodes (27): SmsEventDefinition, SmsService, Injectable, SmsLogQueryDto, ApiPrope
|
||||
|
||||
### Community 9 - "devDependencies"
|
||||
Cohesion: 0.22
|
||||
Nodes (9): devDependencies, eslint-plugin-prettier, @types/bcryptjs, @types/node, typescript, @types/node, typescript, eslint-plugin-prettier (+1 more)
|
||||
Nodes (9): devDependencies, eslint, @types/bcryptjs, @types/node, typescript, eslint, @types/node, typescript (+1 more)
|
||||
|
||||
### Community 10 - "CreateReviewDto"
|
||||
Cohesion: 0.07
|
||||
@ -412,9 +416,9 @@ Nodes (24): backend, frontend, playwright.config.ts, @playwright/test, tests/**/
|
||||
Cohesion: 0.06
|
||||
Nodes (28): AppModule, Module, EnvironmentVariables, IsNotEmpty, IsOptional, IsString, validateEnv(), CustomHttpExceptionFilter (+20 more)
|
||||
|
||||
### Community 14 - "CheckoutPage.tsx"
|
||||
Cohesion: 0.17
|
||||
Nodes (19): AddressFormData, AddressModal(), AddressModalProps, normalizeDigits(), validateAddressForm(), BackButton(), BackButtonProps, CheckoutPage() (+11 more)
|
||||
### Community 14 - "toPersian"
|
||||
Cohesion: 0.12
|
||||
Nodes (27): VerifyContent(), AddressFormData, AddressModal(), AddressModalProps, normalizeDigits(), validateAddressForm(), ArchivePage(), B2BPortal() (+19 more)
|
||||
|
||||
### Community 15 - "src/services/api.ts"
|
||||
Cohesion: 0.06
|
||||
@ -429,7 +433,7 @@ Cohesion: 0.14
|
||||
Nodes (18): B2BPage(), generateMetadata(), ContactPage(), generateMetadata(), generateMetadata(), getInitialVideos(), Videos(), ContactFormClient() (+10 more)
|
||||
|
||||
### Community 18 - "JwtAuthGuard"
|
||||
Cohesion: 0.17
|
||||
Cohesion: 0.20
|
||||
Nodes (7): JwtAuthGuard, Injectable, ROLES_KEY, RequestWithUser, RolesGuard, Injectable, UserReqPayload
|
||||
|
||||
### Community 19 - "admin.controller.ts"
|
||||
@ -442,7 +446,7 @@ Nodes (24): CreateVideoDto, ApiProperty, ApiPropertyOptional, IsBoolean, IsNotEm
|
||||
|
||||
### Community 21 - "useSettingsStore"
|
||||
Cohesion: 0.07
|
||||
Nodes (35): HomeClient(), HomeClientProps, ArchivePage(), B2BLandingClient(), BannerPlacement(), BannerPlacementProps, BlogPreviewSection(), BrandLogo() (+27 more)
|
||||
Nodes (30): HomeClient(), HomeClientProps, BannerPlacement(), BannerPlacementProps, BlogPreviewSection(), BrandLogo(), BrandLogoProps, FAQSection() (+22 more)
|
||||
|
||||
### Community 23 - "MenuService"
|
||||
Cohesion: 0.12
|
||||
@ -554,7 +558,7 @@ Nodes (19): autoprefixer, devDependencies, autoprefixer, eslint, @eslint/js, glo
|
||||
|
||||
### Community 50 - "devDependencies"
|
||||
Cohesion: 0.12
|
||||
Nodes (17): eslint-config-next, devDependencies, eslint, eslint-config-next, jsdom, @testing-library/jest-dom, @testing-library/react, @types/node (+9 more)
|
||||
Nodes (17): devDependencies, eslint, jsdom, tailwindcss, @testing-library/jest-dom, @testing-library/react, @types/node, @types/react (+9 more)
|
||||
|
||||
### Community 51 - "BlogsController"
|
||||
Cohesion: 0.07
|
||||
@ -585,7 +589,7 @@ Cohesion: 0.09
|
||||
Nodes (22): CREATE MODE — Normal Operation, Expected JSON Output Schema, File Scope Boundary, Forbidden Actions, MODE 1: REVIEW (called during Review Phase), MODE 2: CONTENT CREATION (standalone task from backlog), Operating Modes, Operational Rules & Boundaries (+14 more)
|
||||
|
||||
### Community 58 - "RedisService"
|
||||
Cohesion: 0.08
|
||||
Cohesion: 0.09
|
||||
Nodes (11): ApiExcludeController, Optional, MetricsController, Controller, Get, Res, RedisModule, Global (+3 more)
|
||||
|
||||
### Community 59 - "compilerOptions"
|
||||
@ -597,12 +601,12 @@ Cohesion: 0.23
|
||||
Nodes (10): CreateUserDto, ApiProperty, ApiPropertyOptional, IsEmail, IsNotEmpty, IsNumber, IsOptional, IsString (+2 more)
|
||||
|
||||
### Community 61 - "ProductPage.tsx"
|
||||
Cohesion: 0.11
|
||||
Nodes (27): ArchiveProductCard(), ArchiveProductListItem(), CATEGORY_MAP, ICON_MAP, FeaturedProducts(), ProductCard(), ProductImageZoomModalProps, CalculatorState (+19 more)
|
||||
Cohesion: 0.14
|
||||
Nodes (32): ArchiveProductCard(), ArchiveProductListItem(), CATEGORY_MAP, ICON_MAP, FeaturedProducts(), ProductCard(), OrderSuccess(), PetProfile() (+24 more)
|
||||
|
||||
### Community 62 - "admin.module.ts"
|
||||
Cohesion: 0.04
|
||||
Nodes (33): AdminModule, Module, MediaService, Injectable, PetsController, ApiBearerAuth, ApiOperation, ApiQuery (+25 more)
|
||||
### Community 62 - "ReportsController"
|
||||
Cohesion: 0.14
|
||||
Nodes (11): ReportsController, ApiBearerAuth, ApiOperation, ApiQuery, ApiTags, Controller, Get, Query (+3 more)
|
||||
|
||||
### Community 63 - "dependencies"
|
||||
Cohesion: 0.09
|
||||
@ -621,12 +625,12 @@ Cohesion: 0.13
|
||||
Nodes (8): ApiQuery, Get, Query, AdminProductQueryDto, AdminQueryDto, ApiPropertyOptional, IsOptional, IsString
|
||||
|
||||
### Community 67 - "pets/pets.controller.ts"
|
||||
Cohesion: 0.12
|
||||
Cohesion: 0.13
|
||||
Nodes (15): CreatePetDto, ApiProperty, ApiPropertyOptional, IsArray, IsNotEmpty, IsNumber, IsOptional, IsString (+7 more)
|
||||
|
||||
### Community 68 - "lib/services/api.ts"
|
||||
Cohesion: 0.09
|
||||
Nodes (24): BlogPost, ContactInfoItem, DeleteConfirmModal(), DeleteConfirmModalProps, OrderDetailsModal(), OrderDetailsModalProps, ProductReviews, ProductReviews() (+16 more)
|
||||
Cohesion: 0.12
|
||||
Nodes (17): B2BLandingClient(), BlogPost, ContactInfoItem, FAQItem, OrderDetailsModal(), OrderDetailsModalProps, Testimonial, api (+9 more)
|
||||
|
||||
### Community 69 - "Required Review Group Closures"
|
||||
Cohesion: 0.10
|
||||
@ -713,8 +717,8 @@ Cohesion: 0.17
|
||||
Nodes (12): prisma, main(), prisma, determineSuitableFor(), findOrCreateCategory(), getProductImageUrl(), main(), parseSize() (+4 more)
|
||||
|
||||
### Community 90 - "SmartAdvisor.tsx"
|
||||
Cohesion: 0.24
|
||||
Nodes (7): metadata, CURRENT_SYMPTOMS, MEDICAL_HISTORIES, SmartAdvisor(), SmartAdvisorProps, UIState, useUIStore
|
||||
Cohesion: 0.17
|
||||
Nodes (11): ClientLayout(), MobileBottomNav, metadata, MobileBottomNav(), SOLUTION_ITEMS, CURRENT_SYMPTOMS, MEDICAL_HISTORIES, SmartAdvisor() (+3 more)
|
||||
|
||||
### Community 91 - "Reconciled Audit Roles & Assignments"
|
||||
Cohesion: 0.12
|
||||
@ -782,11 +786,11 @@ Nodes (7): InitiatePaymentDto, InitiateWalletTopupDto, ApiProperty, ApiPropertyO
|
||||
|
||||
### Community 107 - "PaginationDto"
|
||||
Cohesion: 0.05
|
||||
Nodes (29): BlogsModule, Module, BlogFilterDto, BlogsService, Injectable, PaginationDto, SortOrder, ApiPropertyOptional (+21 more)
|
||||
Nodes (26): AdminModule, Module, CategoryQuery, MediaService, Injectable, PetQuery, PetsService, Injectable (+18 more)
|
||||
|
||||
### Community 108 - "PrismaService"
|
||||
Cohesion: 0.06
|
||||
Nodes (26): CategoryQuery, B2BWholesaleOrderItem, DEFAULT_SMS_RULES, SMS_EVENT_DEFINITIONS, SmsEventVariable, SmsRule, MeliPayamakPattern, MeliPayamakResponse (+18 more)
|
||||
Nodes (25): B2BWholesaleOrderItem, DEFAULT_SMS_RULES, SMS_EVENT_DEFINITIONS, SmsEventVariable, SmsRule, MeliPayamakPattern, MeliPayamakResponse, SendPatternSmsOptions (+17 more)
|
||||
|
||||
### Community 109 - "1. Summary of Integrity Repairs Performed"
|
||||
Cohesion: 0.17
|
||||
@ -804,9 +808,9 @@ Nodes (10): 1. Mark Active Task as Complete, 2. Documentation Updates, 3. Dynami
|
||||
Cohesion: 0.18
|
||||
Nodes (10): 1. Pre-Deployment Checklist, 2. Build Verification, 3. Deployment Strategy (Based on Target), 4. Post-Deployment Health Check, 5. Forbidden Actions, Expected JSON Output Schema, Operational Rules & Boundaries, Required Output Artifacts (What files to write/update) (+2 more)
|
||||
|
||||
### Community 113 - "orderService.ts"
|
||||
Cohesion: 0.20
|
||||
Nodes (4): ApiErr, Order, OrderItem, OrderService
|
||||
### Community 113 - "cartStore.ts"
|
||||
Cohesion: 0.11
|
||||
Nodes (13): CartDrawer, CartDrawer(), DeleteConfirmModal(), DeleteConfirmModalProps, mockProduct, ApiErr, Order, OrderItem (+5 more)
|
||||
|
||||
### Community 114 - "AppService"
|
||||
Cohesion: 0.29
|
||||
@ -1100,9 +1104,9 @@ Nodes (3): Expanding the ESLint configuration, React Compiler, React + TypeScrip
|
||||
Cohesion: 0.50
|
||||
Nodes (3): Select, SelectOption, SelectProps
|
||||
|
||||
### Community 197 - "AuthModal.tsx"
|
||||
Cohesion: 0.08
|
||||
Nodes (19): AuthModal, LoginModal, AuthModalProps, extractOtpFromText(), otpCooldownExpiries, IMPORTANT: only depend on isOpen here — NOT subView. If we depend on subView,, extractOtpFromText(), LoginModal() (+11 more)
|
||||
### Community 197 - "ClientLayout.tsx"
|
||||
Cohesion: 0.06
|
||||
Nodes (34): AuthModal, B2BPortal, LoginModal, PrescriptionUploadModal, AuthModal(), AuthModalProps, extractOtpFromText(), otpCooldownExpiries (+26 more)
|
||||
|
||||
### Community 198 - "app/page.tsx"
|
||||
Cohesion: 0.67
|
||||
@ -1132,10 +1136,26 @@ Nodes (4): PaymentService, Injectable, Injectable, ZibalService
|
||||
Cohesion: 0.20
|
||||
Nodes (10): ApiPropertyOptional, IsOptional, IsString, ZibalCallbackQueryDto, ApiBadRequestResponse, ApiOkResponse, Req, Res (+2 more)
|
||||
|
||||
### Community 306 - "components/Skeleton.tsx"
|
||||
Cohesion: 0.21
|
||||
Nodes (5): OrderRowSkeleton(), PetProfileSkeleton(), ProductListSkeleton(), Skeleton(), SkeletonProps
|
||||
|
||||
### Community 317 - "revalidate/route.ts"
|
||||
Cohesion: 0.83
|
||||
Nodes (3): GET(), handleRevalidate(), POST()
|
||||
|
||||
### Community 328 - "orders.service.ts"
|
||||
Cohesion: 0.24
|
||||
Nodes (6): IsNotEmpty, IsNumber, IsString, ValidateCouponDto, OrdersModule, Module
|
||||
|
||||
### Community 329 - "videos.controller.ts"
|
||||
Cohesion: 0.22
|
||||
Nodes (7): GetVideosQueryDto, ApiPropertyOptional, IsBoolean, IsOptional, Transform, Module, VideosModule
|
||||
|
||||
### Community 330 - "WikiService"
|
||||
Cohesion: 0.27
|
||||
Nodes (4): Module, WikiModule, Injectable, WikiService
|
||||
|
||||
## Knowledge Gaps
|
||||
- **1356 isolated node(s):** `$schema`, `collection`, `sourceRoot`, `deleteOutDir`, `name` (+1351 more)
|
||||
These have ≤1 connection - possible missing edges or undocumented components.
|
||||
@ -1148,13 +1168,13 @@ _Questions this graph is uniquely positioned to answer:_
|
||||
_High betweenness centrality (0.093) - this node is a cross-community bridge._
|
||||
- **Why does `ApiResponse` connect `src/services/api.ts` to `HomeController`, `WikiController`, `BlogsController`, `PetsController`, `RevalidationService`, `UsersService`, `AuthController`, `OrdersService`?**
|
||||
_High betweenness centrality (0.066) - this node is a cross-community bridge._
|
||||
- **Why does `JwtAuthGuard` connect `JwtAuthGuard` to `pets/pets.controller.ts`, `CmsController`, `tickets.controller.ts`, `PaginationDto`, `RevalidationService`, `PrismaService`, `DoctorQueryDto`, `admin.controller.ts`, `auth.service.ts`, `admin.module.ts`?**
|
||||
- **Why does `JwtAuthGuard` connect `JwtAuthGuard` to `pets/pets.controller.ts`, `CmsController`, `tickets.controller.ts`, `orders.service.ts`, `videos.controller.ts`, `PaginationDto`, `RevalidationService`, `PrismaService`, `DoctorQueryDto`, `admin.controller.ts`, `auth.service.ts`, `ReportsController`?**
|
||||
_High betweenness centrality (0.030) - this node is a cross-community bridge._
|
||||
- **What connects `$schema`, `collection`, `sourceRoot` to the rest of the system?**
|
||||
_1356 weakly-connected nodes found - possible documentation gaps or missing edges._
|
||||
- **Should `app.module.ts` be split into smaller, more focused modules?**
|
||||
_Cohesion score 0.059562841530054644 - nodes in this community are weakly interconnected._
|
||||
_Cohesion score 0.06516290726817042 - nodes in this community are weakly interconnected._
|
||||
- **Should `productService.ts` be split into smaller, more focused modules?**
|
||||
_Cohesion score 0.06187202538339503 - nodes in this community are weakly interconnected._
|
||||
- **Should `toPersian` be split into smaller, more focused modules?**
|
||||
_Cohesion score 0.1011764705882353 - nodes in this community are weakly interconnected._
|
||||
_Cohesion score 0.06497175141242938 - nodes in this community are weakly interconnected._
|
||||
- **Should `CmsController` be split into smaller, more focused modules?**
|
||||
_Cohesion score 0.0899854862119013 - nodes in this community are weakly interconnected._
|
||||
2
graphify-out/cache/stat-index.json
vendored
2
graphify-out/cache/stat-index.json
vendored
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
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user