From 4abab55a6b760fb34d45360109f5774ac543bcce Mon Sep 17 00:00:00 2001 From: Mahdi Date: Sun, 18 Oct 2026 19:39:59 +0330 Subject: [PATCH] feat(web): migrate CRM screens to Ant Design Vue with central theme Adopt ant-design-vue and a shared antdTheme for leads, pipeline, invoices, and shared form controls under strict single-page governance. Co-authored-by: Cursor --- .cursor/rules/antd-strict-governance.mdc | 85 + .cursor/skills/antd-system-architect/SKILL.md | 86 + apps/web/package.json | 2 + apps/web/src/App.vue | 12 +- apps/web/src/components.d.ts | 66 + .../src/components/CustomFieldsSection.vue | 171 +- apps/web/src/components/EntityTimeline.vue | 307 +- apps/web/src/components/ExcelImportFlow.vue | 225 +- apps/web/src/components/InvoiceDocPreview.vue | 427 +++ apps/web/src/components/JalaliDateInput.vue | 120 +- apps/web/src/components/MentoMemoryPanel.vue | 245 +- apps/web/src/components/MoneyInput.vue | 24 +- .../src/components/PhoneContactsImport.vue | 346 +- apps/web/src/components/SavedFiltersBar.vue | 288 +- apps/web/src/components/TableColumnsMenu.vue | 202 +- apps/web/src/components/UserMultiSelect.vue | 350 +- apps/web/src/components/VoiceToTextButton.vue | 110 +- .../src/components/pipeline/AddDealButton.vue | 13 +- apps/web/src/components/pipeline/DealCard.vue | 438 +-- .../src/components/pipeline/PipelineBoard.vue | 289 +- .../components/pipeline/PipelineColumn.vue | 544 ++- .../src/components/pipeline/PipelineList.vue | 690 ++-- .../components/pipeline/PipelineToolbar.vue | 265 +- .../components/routines/EntityLinkPicker.vue | 187 +- .../components/routines/QuickTaskModal.vue | 233 +- .../components/routines/RelatedTasksPanel.vue | 289 +- .../components/routines/RoutineTaskModals.vue | 134 +- .../components/routines/RoutineTaskRow.vue | 492 +-- apps/web/src/layouts/AppLayout.vue | 26 +- apps/web/src/theme/antdTheme.ts | 77 + apps/web/src/views/DealFormView.vue | 1835 +++------- apps/web/src/views/InvoiceFormView.vue | 2488 ++++---------- apps/web/src/views/InvoicesView.vue | 1059 +++--- apps/web/src/views/LeadBoardView.vue | 567 +++- apps/web/src/views/LeadDetailView.vue | 1636 ++++----- apps/web/src/views/LeadsView.vue | 2970 +++++------------ apps/web/src/views/PersonFormView.vue | 890 ++--- apps/web/src/views/PipelineBoardView.vue | 653 ++-- docs/وضعیت-دیزاین-سیستم.md | 233 ++ package-lock.json | 250 +- 40 files changed, 7529 insertions(+), 11795 deletions(-) create mode 100644 .cursor/rules/antd-strict-governance.mdc create mode 100644 .cursor/skills/antd-system-architect/SKILL.md create mode 100644 apps/web/src/components.d.ts create mode 100644 apps/web/src/components/InvoiceDocPreview.vue create mode 100644 apps/web/src/theme/antdTheme.ts create mode 100644 docs/وضعیت-دیزاین-سیستم.md diff --git a/.cursor/rules/antd-strict-governance.mdc b/.cursor/rules/antd-strict-governance.mdc new file mode 100644 index 0000000..a8b16f7 --- /dev/null +++ b/.cursor/rules/antd-strict-governance.mdc @@ -0,0 +1,85 @@ +--- +description: Hard governance for Ant Design Vue v4 migration — isolated page-by-page, no manual CSS, 24-col grid, default controlHeight 36 +alwaysApply: true +--- + +# Ant Design Vue v4 — Strict Governance (locked) + +Source of truth for migrated UI: **Ant Design Vue 4** + central theme [`apps/web/src/theme/antdTheme.ts`](apps/web/src/theme/antdTheme.ts). + +Legacy CRM UI (`components/ui/*`, `.crm-*`, `.btn` / `.field` in `styles/`) remains for **unmigrated** screens only. Never mix systems inside one page. + +## Hard rules + +1. **Single-page migration lock** + Migrate **exactly one** route/view (or one clearly named page folder) per change set. Do not “clean up” neighboring pages, shared legacy primitives, or global CSS while migrating a page. + +2. **No edits to legacy kit during Ant work** + Do **not** modify `apps/web/src/components/ui/**` or broaden changes across `views/` beyond the single page under migration, unless the user explicitly names that page. + +2b. **Child components of a migrated View (mandatory)** + هنگام بازنویسی یک صفحه (View)، ایجنت موظف است علاوه بر خود فایل View، تمام کامپوننت‌های فرزندی را که در آن View ایمپورت شده‌اند و حاوی اینپوت/سلکت/دکمه هستند نیز بازبینی کرده و درون آن‌ها را به کامپوننت‌های رسمی `ant-design-vue` تبدیل کند. هیچ تگ ``, `