| Metadata | Value |
|---|---|
| Status | Active |
| Version | 1.1.0 |
| Last Updated | 2026-09-10 |
| Author | Sangeetha Grantha Team |
| Document Type | Evidence record |
[!NOTE] Historical evidence: results, counts, commands, and observations below belong to the original work described here. The editorial update date is not a new test or corpus verification. For present behavior, use current quality checks.
Related Review: frontend-pages-code-review.md
Scope: All pages in modules/frontend/sangita-admin-web/src/pages/
See detailed checklist: krithi-editor-refactor-checklist.md
Summary: 47 P1 items including tab extraction, TypeScript interfaces, useReducer implementation, and business logic extraction.
Composer interface (Lines 42-48)Raga interface (Lines 50-57)Tala interface (Lines 59-64)Temple interface (Lines 66-73)DeityItem interface (Lines 75-78)../types insteadReferenceItem union type to use imported typescomponents/reference-data/EntityForm.tsxEntityFormProps interfacecomponents/form/FormInput.tsx with proper typescomponents/form/FormTextarea.tsx with proper typescomponents/form/FormSelect.tsx with proper typesinterface FormInputProps {
label: string;
name: string;
value: string;
onChange: (e: React.ChangeEvent<HTMLInputElement>) => void;
placeholder?: string;
required?: boolean;
type?: 'text' | 'number';
help?: string;
className?: string;
readOnly?: boolean;
}
any types from all form componentsutils/reference-data-mappers.tsmapComposerToItem() functionmapRagaToItem() functionmapTalaToItem() functionmapTempleToItem() functionmapDeityToItem() functionutils/reference-data-validation.tsconst validateRequiredFields = (entityType: EntityType, formData: FormData): string | null
hooks/useEntityCrud.ts custom hookRecord<string, any> with typed form stateany from FormInput propsany from FormTextarea propsany from FormSelect propsany Typesparams: any with typed interface (Line 37)types/api-params.ts for request parameter typestypes/form-state.ts for common form patternsutils/error-handler.tshandleApiError(error: unknown, toast: ToastContext): voidformatErrorMessage(error: unknown): stringalert() calls with toast notificationsconsole.error + silent failure with toastalert() with toasthooks/useBatchActions.tstriggerAction logic to hookhandlePause(batchId: string)handleResume(batchId: string)handleCancel(batchId: string)handleRetry(batchId: string)handleDelete(batchId: string)handleApproveAll(batchId: string)handleRejectAll(batchId: string)handleFinalize(batchId: string)handleExport(batchId: string, format: string)components/bulk-import/TaskLogDrawer.tsx (Lines 261-364)components/bulk-import/DeleteConfirmModal.tsx (Lines 366-387)console.log at Line 182zod or use runtime validationResolutionResultPromise.allSettled instead of Promise.allconst [formState, setFormState] = useState({
title: '', composer: '', raga: '', tala: '', language: '', lyrics: ''
});
updateField(field: string, value: string) helpercomponents/Modal.tsxcomponents/ConfirmationModal.tsxtitle, message, onConfirm, onCancel, confirmText, cancelText, variantwindow.confirm() calls:
hooks/useAbortController.tscomponents/dashboard/StatCard.tsxcomponents/dashboard/RecentItem.tsxReact.memoconfirm() with ConfirmationModalSTATUS_Styles constantrole="tablist", role="tab", role="tabpanel" where applicable
role="grid" or use semantic <table> with proper headersaria-describedby for field errorsaria-busy="true" and aria-live="polite"React.memoreact-virtual or react-windowcomponents/Skeleton.tsxhandle* prefix)console.log statementssrc/
├── pages/
│ ├── AutoApproveQueue.tsx # ~150 lines
│ ├── BulkImport.tsx # ~400 lines
│ ├── Dashboard.tsx # ~150 lines
│ ├── ImportReview.tsx # ~300 lines
│ ├── ImportsPage.tsx # ~200 lines
│ ├── KrithiEditor.tsx # ~200 lines (orchestration)
│ ├── KrithiList.tsx # ~150 lines
│ ├── ReferenceData.tsx # ~300 lines (orchestration)
│ ├── RolesPage.tsx # Placeholder
│ ├── TagsPage.tsx # ~250 lines
│ └── UsersPage.tsx # Placeholder
├── components/
│ ├── form/
│ │ ├── FormInput.tsx
│ │ ├── FormTextarea.tsx
│ │ ├── FormSelect.tsx
│ │ ├── FormCheckbox.tsx
│ │ └── index.ts
│ ├── Modal.tsx
│ ├── ConfirmationModal.tsx
│ ├── Skeleton.tsx
│ ├── krithi-editor/
│ │ ├── MetadataTab.tsx
│ │ ├── StructureTab.tsx
│ │ ├── LyricsTab.tsx
│ │ ├── TagsTab.tsx
│ │ ├── AuditTab.tsx
│ │ └── index.ts
│ ├── reference-data/
│ │ ├── EntityForm.tsx
│ │ ├── EntityList.tsx
│ │ └── index.ts
│ ├── bulk-import/
│ │ ├── TaskLogDrawer.tsx
│ │ ├── DeleteConfirmModal.tsx
│ │ ├── BatchTable.tsx
│ │ └── index.ts
│ └── dashboard/
│ ├── StatCard.tsx
│ ├── RecentItem.tsx
│ └── index.ts
├── hooks/
│ ├── useKrithiEditorReducer.ts
│ ├── useKrithiData.ts
│ ├── useReferenceData.ts
│ ├── useEntityCrud.ts
│ ├── useBatchActions.ts
│ ├── useAbortController.ts
│ └── index.ts
├── utils/
│ ├── error-handler.ts
│ ├── reference-data-mappers.ts
│ ├── reference-data-validation.ts
│ ├── krithi-mapper.ts
│ └── index.ts
└── types/
├── api-params.ts
├── form-state.ts
├── krithi-editor.types.ts
└── index.ts
| Priority | Section | Total Items | Completed | % |
|---|---|---|---|---|
| P1 | KrithiEditor | 47 | 0 | 0% |
| P1 | ReferenceData | 32 | 0 | 0% |
| P1 | Remove any Types |
8 | 0 | 0% |
| P1 | Standardize Errors | 11 | 0 | 0% |
| P2 | BulkImport | 16 | 0 | 0% |
| P2 | ImportReview | 7 | 0 | 0% |
| P2 | Modal Component | 12 | 0 | 0% |
| P2 | Request Cancellation | 8 | 0 | 0% |
| P3 | TagsPage | 4 | 0 | 0% |
| P3 | ImportsPage | 4 | 0 | 0% |
| P3 | Dashboard | 4 | 0 | 0% |
| P3 | AutoApproveQueue | 4 | 0 | 0% |
| P3 | KrithiList | 2 | 0 | 0% |
| P3 | Accessibility | 8 | 0 | 0% |
| P4 | Performance | 8 | 0 | 0% |
| P4 | UX (Skeletons) | 6 | 0 | 0% |
| P4 | Code Style | 4 | 0 | 0% |
| TOTAL | 185 | 0 | 0% |
For each checklist item:
any types (where applicable)