Adds accounting-service PATCH/archive, fiscal helpers, COA templates and setup status, plus SuperApp Accounting UI (DS, scoreboard, masters, vouchers, ledger, ops modules) with session refresh and HTTPS public API URLs. Co-authored-by: Cursor <cursoragent@cursor.com>
1.6 KiB
1.6 KiB
Component Library
Located in frontend/components/ds/.
Core
| Component | File | Notes |
|---|---|---|
| Button | Button.tsx |
variants: default, outline, ghost, danger, success |
| Input / Textarea / Label / FieldError | Input.tsx |
Form primitives |
| Card family | Card.tsx |
Card, Header, Title, Description, Content |
| Badge | Badge.tsx |
tones: default, primary, success, warning, danger, info |
| Dialog / ConfirmDialog | Dialog.tsx |
Modal + confirm |
| PageHeader | Page.tsx |
Title + actions |
| DataTable | Page.tsx |
Simple enterprise table |
| Empty / Loading / Error | Page.tsx |
Standard states |
| StatCard | Page.tsx |
Dashboard KPI |
| DatePicker / JalaliDateText | DatePicker.tsx |
Shamsi calendar only; value is Gregorian ISO for APIs |
| Select / FormField / Checkbox / MoneyInput | FormControls.tsx |
Styled <select>, labeled checkbox, LTR decimal input for voucher lines |
| Drawer | Drawer.tsx |
RTL slide-over for edit forms (currencies, cost centers, projects, COA accounts) |
| Tabs / TableToolbar / Breadcrumbs / Skeleton / Pagination | NavChrome.tsx |
List chrome + navigation |
Import via @/components/ds.
Dates
- Never use native
type="date"(Gregorian browser picker) in Accounting. - Always use
DatePickerfor input andJalaliDateText/formatJalalifor display. - API payloads remain
YYYY-MM-DDGregorian.
Accounting helpers
CompletionScoreboard—frontend/components/accounting/CompletionScoreboard.tsx(readslib/accounting-scoreboard.ts).- Scoreboard doc:
docs/frontend/completion-scoreboard.md.