@framework-m/desk 0.6.2 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/audit/AuditTimeline.d.ts +7 -0
- package/dist/components/audit/AuditTimeline.d.ts.map +1 -0
- package/dist/components/audit/DiffViewer.d.ts +7 -0
- package/dist/components/audit/DiffViewer.d.ts.map +1 -0
- package/dist/components/audit/index.d.ts +5 -0
- package/dist/components/audit/index.d.ts.map +1 -0
- package/dist/components/correction/CorrectButton.d.ts +9 -0
- package/dist/components/correction/CorrectButton.d.ts.map +1 -0
- package/dist/components/correction/CorrectionWizard.d.ts +11 -0
- package/dist/components/correction/CorrectionWizard.d.ts.map +1 -0
- package/dist/components/correction/index.d.ts +5 -0
- package/dist/components/correction/index.d.ts.map +1 -0
- package/dist/components/feedback/SubmittedBanner.d.ts +6 -0
- package/dist/components/feedback/SubmittedBanner.d.ts.map +1 -0
- package/dist/components/feedback/index.d.ts +2 -0
- package/dist/components/feedback/index.d.ts.map +1 -1
- package/dist/components/form/LinkWidget.d.ts +6 -1
- package/dist/components/form/LinkWidget.d.ts.map +1 -1
- package/dist/components/form/fields/AutoField.d.ts +26 -0
- package/dist/components/form/fields/AutoField.d.ts.map +1 -0
- package/dist/components/form/fields/BooleanField.d.ts +3 -0
- package/dist/components/form/fields/BooleanField.d.ts.map +1 -0
- package/dist/components/form/fields/ErrorsField.d.ts +5 -0
- package/dist/components/form/fields/ErrorsField.d.ts.map +1 -0
- package/dist/components/form/fields/LinkField.d.ts +2 -0
- package/dist/components/form/fields/LinkField.d.ts.map +1 -0
- package/dist/components/form/fields/ListField.d.ts +6 -0
- package/dist/components/form/fields/ListField.d.ts.map +1 -0
- package/dist/components/form/fields/MultiSelectField.d.ts +3 -0
- package/dist/components/form/fields/MultiSelectField.d.ts.map +1 -0
- package/dist/components/form/fields/SelectField.d.ts +19 -0
- package/dist/components/form/fields/SelectField.d.ts.map +1 -0
- package/dist/components/form/fields/SubmitField.d.ts +5 -0
- package/dist/components/form/fields/SubmitField.d.ts.map +1 -0
- package/dist/components/form/fields/TextField.d.ts +19 -0
- package/dist/components/form/fields/TextField.d.ts.map +1 -0
- package/dist/components/form/fields/registry.d.ts +16 -0
- package/dist/components/form/fields/registry.d.ts.map +1 -0
- package/dist/components/form/tamagui-fields.d.ts +6 -15
- package/dist/components/form/tamagui-fields.d.ts.map +1 -1
- package/dist/components/layout/ColumnGrid.d.ts +22 -0
- package/dist/components/layout/ColumnGrid.d.ts.map +1 -0
- package/dist/components/layout/FrameworkMShell.d.ts +0 -4
- package/dist/components/layout/FrameworkMShell.d.ts.map +1 -1
- package/dist/components/layout/Navigation/ContextualDrawer.d.ts +20 -0
- package/dist/components/layout/Navigation/ContextualDrawer.d.ts.map +1 -0
- package/dist/components/layout/Navigation/NavigationShell.d.ts +16 -0
- package/dist/components/layout/Navigation/NavigationShell.d.ts.map +1 -0
- package/dist/components/layout/Navigation/PrimaryRail.d.ts +13 -0
- package/dist/components/layout/Navigation/PrimaryRail.d.ts.map +1 -0
- package/dist/components/layout/PageHeader.d.ts +19 -0
- package/dist/components/layout/PageHeader.d.ts.map +1 -0
- package/dist/components/layout/SectionField.d.ts +15 -0
- package/dist/components/layout/SectionField.d.ts.map +1 -0
- package/dist/components/layout/ShellSkeleton.d.ts +3 -1
- package/dist/components/layout/ShellSkeleton.d.ts.map +1 -1
- package/dist/components/layout/TabContainer.d.ts +17 -0
- package/dist/components/layout/TabContainer.d.ts.map +1 -0
- package/dist/components/layout/index.d.ts +12 -0
- package/dist/components/layout/index.d.ts.map +1 -1
- package/dist/components/list/AsOfDatePicker.d.ts +8 -0
- package/dist/components/list/AsOfDatePicker.d.ts.map +1 -0
- package/dist/components/list/index.d.ts +3 -0
- package/dist/components/list/index.d.ts.map +1 -0
- package/dist/components/sibling/SiblingPanel.d.ts +8 -0
- package/dist/components/sibling/SiblingPanel.d.ts.map +1 -0
- package/dist/components/sibling/index.d.ts +3 -0
- package/dist/components/sibling/index.d.ts.map +1 -0
- package/dist/components/table/AutoTable.d.ts +4 -1
- package/dist/components/table/AutoTable.d.ts.map +1 -1
- package/dist/config/index.d.ts +2 -10
- package/dist/config/index.d.ts.map +1 -1
- package/dist/data.d.ts.map +1 -1
- package/dist/hooks/index.d.ts +15 -4
- package/dist/hooks/index.d.ts.map +1 -1
- package/dist/hooks/types.d.ts +23 -8
- package/dist/hooks/types.d.ts.map +1 -1
- package/dist/hooks/useAuditTimeline.d.ts +22 -0
- package/dist/hooks/useAuditTimeline.d.ts.map +1 -0
- package/dist/hooks/useComponentOverride.d.ts +3 -0
- package/dist/hooks/useComponentOverride.d.ts.map +1 -0
- package/dist/hooks/useCorrectionAction.d.ts +14 -0
- package/dist/hooks/useCorrectionAction.d.ts.map +1 -0
- package/dist/hooks/useDocTypes.d.ts +3 -0
- package/dist/hooks/useDocTypes.d.ts.map +1 -1
- package/dist/hooks/useFormKeyboard.d.ts +6 -0
- package/dist/hooks/useFormKeyboard.d.ts.map +1 -0
- package/dist/hooks/usePageOverride.d.ts +3 -0
- package/dist/hooks/usePageOverride.d.ts.map +1 -0
- package/dist/hooks/useRouteTraversal.d.ts +8 -0
- package/dist/hooks/useRouteTraversal.d.ts.map +1 -0
- package/dist/hooks/useSiblingDocTypes.d.ts +16 -0
- package/dist/hooks/useSiblingDocTypes.d.ts.map +1 -0
- package/dist/hooks/useTabKeyboard.d.ts +15 -0
- package/dist/hooks/useTabKeyboard.d.ts.map +1 -0
- package/dist/hooks/useUIMeta.d.ts +2 -0
- package/dist/hooks/useUIMeta.d.ts.map +1 -1
- package/dist/index.d.ts +23 -9
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +7423 -6635
- package/dist/index.js.map +1 -1
- package/dist/pages/FormView.d.ts +41 -14
- package/dist/pages/FormView.d.ts.map +1 -1
- package/dist/pages/ListView.d.ts.map +1 -1
- package/dist/pages/LoginPage.d.ts +1 -1
- package/dist/pages/LoginPage.d.ts.map +1 -1
- package/dist/plugins/builtins.d.ts +2 -0
- package/dist/plugins/builtins.d.ts.map +1 -0
- package/dist/plugins/index.d.ts +1 -0
- package/dist/plugins/index.d.ts.map +1 -1
- package/dist/shell/ShellProvider.d.ts.map +1 -1
- package/dist/views/CalendarView.d.ts +1 -1
- package/dist/views/CalendarView.d.ts.map +1 -1
- package/dist/views/GanttView.d.ts +1 -1
- package/dist/views/GanttView.d.ts.map +1 -1
- package/dist/views/KanbanView.d.ts +1 -1
- package/dist/views/KanbanView.d.ts.map +1 -1
- package/dist/views/TreeView.d.ts +1 -1
- package/dist/views/TreeView.d.ts.map +1 -1
- package/package.json +20 -15
- package/dist/components/layout/Navbar/Navbar.d.ts +0 -16
- package/dist/components/layout/Navbar/Navbar.d.ts.map +0 -1
- package/dist/components/layout/Sidebar/Sidebar.d.ts +0 -25
- package/dist/components/layout/Sidebar/Sidebar.d.ts.map +0 -1
- package/dist/config/registry.d.ts +0 -75
- package/dist/config/registry.d.ts.map +0 -1
- package/dist/config/types.d.ts +0 -130
- package/dist/config/types.d.ts.map +0 -1
- package/dist/config/useConfig.d.ts +0 -18
- package/dist/config/useConfig.d.ts.map +0 -1
package/dist/pages/FormView.d.ts
CHANGED
|
@@ -1,19 +1,31 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
1
2
|
/**
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
* Generic form view for any DocType (create/edit).
|
|
5
|
-
* Per checklist 3.2:
|
|
6
|
-
* - Route Create: `/app/{doctype}/new`
|
|
7
|
-
* - Route Edit: `/app/{doctype}/detail/{id}`
|
|
8
|
-
*
|
|
9
|
-
* Features:
|
|
10
|
-
* - Fetches metadata
|
|
11
|
-
* - Fetches document (if editing)
|
|
12
|
-
* - Renders AutoForm
|
|
13
|
-
* - Renders Workflow Actions
|
|
14
|
-
* - Save/Submit/Cancel buttons
|
|
15
|
-
* - Shows validation errors
|
|
3
|
+
* Unified form controller interface passed to overrides and standard views.
|
|
16
4
|
*/
|
|
5
|
+
export interface Frm<T = any> {
|
|
6
|
+
/** The current reactive document state */
|
|
7
|
+
doc: T;
|
|
8
|
+
/** Update a specific field or the entire model */
|
|
9
|
+
setDoc: (data: Partial<T> | ((prev: T) => T)) => void;
|
|
10
|
+
/** Save the document (trigger create/update mutation) */
|
|
11
|
+
save: () => Promise<void>;
|
|
12
|
+
/** Discard changes and return to list */
|
|
13
|
+
cancel: () => void;
|
|
14
|
+
/** True if we are currently editing an existing record */
|
|
15
|
+
isEditing: boolean;
|
|
16
|
+
/** True if a mutation is in flight */
|
|
17
|
+
isSaving: boolean;
|
|
18
|
+
/** True if the document is submitted/cancelled and shouldn't be edited */
|
|
19
|
+
isLocked: boolean;
|
|
20
|
+
/** Current validation or system errors */
|
|
21
|
+
errors: string[];
|
|
22
|
+
/** Current system notices/alerts */
|
|
23
|
+
notices: string[];
|
|
24
|
+
/** Workflow state info if applicable */
|
|
25
|
+
workflow?: any;
|
|
26
|
+
/** Refetch the current document from server */
|
|
27
|
+
refetch: () => Promise<void>;
|
|
28
|
+
}
|
|
17
29
|
/**
|
|
18
30
|
* FormView props
|
|
19
31
|
*/
|
|
@@ -22,6 +34,21 @@ export interface FormViewProps {
|
|
|
22
34
|
doctype?: string;
|
|
23
35
|
/** Document ID (overrides route param) */
|
|
24
36
|
id?: string;
|
|
37
|
+
/** Optional standard view passed as children for wrapping */
|
|
38
|
+
children?: ReactNode;
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* Standard props shared between FormView and its components
|
|
42
|
+
*/
|
|
43
|
+
export interface StandardFormViewProps {
|
|
44
|
+
doctype: string;
|
|
45
|
+
id?: string;
|
|
46
|
+
frm: Frm;
|
|
47
|
+
meta: any;
|
|
48
|
+
metaLoading: boolean;
|
|
49
|
+
metaError?: Error | null;
|
|
50
|
+
docError?: Error | null;
|
|
51
|
+
record?: any;
|
|
25
52
|
}
|
|
26
53
|
/**
|
|
27
54
|
* FormView Component
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FormView.d.ts","sourceRoot":"","sources":["../../src/pages/FormView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;
|
|
1
|
+
{"version":3,"file":"FormView.d.ts","sourceRoot":"","sources":["../../src/pages/FormView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAYH,OAAO,EAA0C,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAkB/E;;GAEG;AACH,MAAM,WAAW,GAAG,CAAC,CAAC,GAAG,GAAG;IAC1B,0CAA0C;IAC1C,GAAG,EAAE,CAAC,CAAC;IACP,kDAAkD;IAClD,MAAM,EAAE,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,CAAC,KAAK,CAAC,CAAC,KAAK,IAAI,CAAC;IACtD,yDAAyD;IACzD,IAAI,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAC1B,yCAAyC;IACzC,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,0DAA0D;IAC1D,SAAS,EAAE,OAAO,CAAC;IACnB,sCAAsC;IACtC,QAAQ,EAAE,OAAO,CAAC;IAClB,0EAA0E;IAC1E,QAAQ,EAAE,OAAO,CAAC;IAClB,0CAA0C;IAC1C,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,oCAAoC;IACpC,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,wCAAwC;IACxC,QAAQ,CAAC,EAAE,GAAG,CAAC;IACf,+CAA+C;IAC/C,OAAO,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;CAC9B;AAED;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,2CAA2C;IAC3C,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,0CAA0C;IAC1C,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,6DAA6D;IAC7D,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB;AAED;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC,OAAO,EAAE,MAAM,CAAC;IAChB,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,GAAG,CAAC;IACT,IAAI,EAAE,GAAG,CAAC;IACV,WAAW,EAAE,OAAO,CAAC;IACrB,SAAS,CAAC,EAAE,KAAK,GAAG,IAAI,CAAC;IACzB,QAAQ,CAAC,EAAE,KAAK,GAAG,IAAI,CAAC;IACxB,MAAM,CAAC,EAAE,GAAG,CAAC;CACd;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,QAAQ,CAAC,EACvB,OAAO,EAAE,WAAW,EACpB,EAAE,EAAE,MAAM,GACX,EAAE,QAAQ,CAAC,aAAa,CAAC,2CAsHzB;AA6iBD,eAAe,QAAQ,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ListView.d.ts","sourceRoot":"","sources":["../../src/pages/ListView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;
|
|
1
|
+
{"version":3,"file":"ListView.d.ts","sourceRoot":"","sources":["../../src/pages/ListView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAkCH;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,2CAA2C;IAC3C,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,6DAA6D;IAC7D,IAAI,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,MAAM,CAAC;CACnC;AAkXD;;;;;;;;;;;;;GAaG;AACH,wBAAgB,QAAQ,CAAC,EACvB,OAAO,EAAE,WAAW,EACpB,IAAI,EAAE,QAAQ,GACf,EAAE,QAAQ,CAAC,aAAa,CAAC,2CA6BzB;AA0zBD,eAAe,QAAQ,CAAC"}
|
|
@@ -12,6 +12,6 @@ export interface LoginPageProps {
|
|
|
12
12
|
*
|
|
13
13
|
* Refactored using Tamagui for premium aesthetics and cross-platform readiness.
|
|
14
14
|
*/
|
|
15
|
-
export declare function LoginPage({
|
|
15
|
+
export declare function LoginPage({ ...props }: Readonly<LoginPageProps>): import("react/jsx-runtime").JSX.Element;
|
|
16
16
|
export default LoginPage;
|
|
17
17
|
//# sourceMappingURL=LoginPage.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LoginPage.d.ts","sourceRoot":"","sources":["../../src/pages/LoginPage.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"LoginPage.d.ts","sourceRoot":"","sources":["../../src/pages/LoginPage.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAsE3D,MAAM,WAAW,cAAc;IAC7B,uBAAuB;IACvB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,4BAA4B;IAC5B,IAAI,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC,SAAS,CAAC;IAChC,+BAA+B;IAC/B,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED;;;;GAIG;AACH,wBAAgB,SAAS,CAAC,EACxB,GAAG,KAAK,EACT,EAAE,QAAQ,CAAC,cAAc,CAAC,2CAQ1B;AAmQD,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"builtins.d.ts","sourceRoot":"","sources":["../../src/plugins/builtins.tsx"],"names":[],"mappings":"AAkHA,wBAAgB,8BAA8B,IAAI,IAAI,CAsBrD"}
|
package/dist/plugins/index.d.ts
CHANGED
|
@@ -11,4 +11,5 @@ export { registerPlugin, registerField, registerSlot, registerPage, getField, ge
|
|
|
11
11
|
export { Slot } from './Slot';
|
|
12
12
|
export type { SlotComponentProps } from './Slot';
|
|
13
13
|
export type { Plugin, PluginRegistry, FieldRegistration, FieldWidgetProps, SlotRegistration, SlotProps, PageRegistration, PageProps, ResourceRegistration, ThemeRegistration, } from './types';
|
|
14
|
+
export { ensureBuiltInSlotContributions } from './builtins';
|
|
14
15
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/plugins/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAGH,OAAO,EACL,cAAc,EACd,aAAa,EACb,YAAY,EACZ,YAAY,EACZ,QAAQ,EACR,iBAAiB,EACjB,OAAO,EACP,YAAY,EACZ,QAAQ,EACR,UAAU,EACV,SAAS,EACT,aAAa,GACd,MAAM,YAAY,CAAC;AAGpB,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,YAAY,EAAE,kBAAkB,EAAE,MAAM,QAAQ,CAAC;AAGjD,YAAY,EACV,MAAM,EACN,cAAc,EACd,iBAAiB,EACjB,gBAAgB,EAChB,gBAAgB,EAChB,SAAS,EACT,gBAAgB,EAChB,SAAS,EACT,oBAAoB,EACpB,iBAAiB,GAClB,MAAM,SAAS,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/plugins/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAGH,OAAO,EACL,cAAc,EACd,aAAa,EACb,YAAY,EACZ,YAAY,EACZ,QAAQ,EACR,iBAAiB,EACjB,OAAO,EACP,YAAY,EACZ,QAAQ,EACR,UAAU,EACV,SAAS,EACT,aAAa,GACd,MAAM,YAAY,CAAC;AAGpB,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,YAAY,EAAE,kBAAkB,EAAE,MAAM,QAAQ,CAAC;AAGjD,YAAY,EACV,MAAM,EACN,cAAc,EACd,iBAAiB,EACjB,gBAAgB,EAChB,gBAAgB,EAChB,SAAS,EACT,gBAAgB,EAChB,SAAS,EACT,oBAAoB,EACpB,iBAAiB,GAClB,MAAM,SAAS,CAAC;AAGjB,OAAO,EAAE,8BAA8B,EAAE,MAAM,YAAY,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ShellProvider.d.ts","sourceRoot":"","sources":["../../src/shell/ShellProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,EAML,KAAK,SAAS,EACf,MAAM,OAAO,CAAC;AAEf,OAAO,KAAK,EAMV,eAAe,EAEhB,MAAM,SAAS,CAAC;AACjB,OAAO,KAAK,EAAE,gBAAgB,
|
|
1
|
+
{"version":3,"file":"ShellProvider.d.ts","sourceRoot":"","sources":["../../src/shell/ShellProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,EAML,KAAK,SAAS,EACf,MAAM,OAAO,CAAC;AAEf,OAAO,KAAK,EAMV,eAAe,EAEhB,MAAM,SAAS,CAAC;AACjB,OAAO,KAAK,EAAE,gBAAgB,EAAkB,MAAM,yBAAyB,CAAC;AAyFhF,wBAAgB,aAAa,CAAC,EAC5B,QAAQ,EACR,QAAgB,EAChB,OAAe,EACf,gBAAwB,EACxB,mBAA8B,EAC9B,SAAS,EACT,YAAY,EACZ,eAAe,EACf,cAAmB,GACpB,EAAE,QAAQ,CAAC;IACV,QAAQ,EAAE,SAAS,CAAC;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,mBAAmB,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,IAAI,CAAC;IAC/C,SAAS,EAAE,OAAO,CAAC;IACnB,YAAY,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,IAAI,CAAC;IACvC,eAAe,CAAC,EAAE,eAAe,CAAC;IAClC,cAAc,CAAC,EAAE,gBAAgB,EAAE,CAAC;CACrC,CAAC,2CA2RD"}
|
|
@@ -9,6 +9,6 @@ export interface CalendarViewProps extends ViewProps {
|
|
|
9
9
|
/**
|
|
10
10
|
* CalendarView Component
|
|
11
11
|
*/
|
|
12
|
-
export declare function CalendarView(
|
|
12
|
+
export declare function CalendarView(props: CalendarViewProps): import("react/jsx-runtime").JSX.Element;
|
|
13
13
|
export default CalendarView;
|
|
14
14
|
//# sourceMappingURL=CalendarView.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CalendarView.d.ts","sourceRoot":"","sources":["../../src/views/CalendarView.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"CalendarView.d.ts","sourceRoot":"","sources":["../../src/views/CalendarView.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAUzD;;GAEG;AACH,MAAM,WAAW,iBAAkB,SAAQ,SAAS;IAClD,6BAA6B;IAC7B,MAAM,EAAE,cAAc,CAAC;CACxB;AA0BD;;GAEG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,iBAAiB,2CAOpD;AA2KD,eAAe,YAAY,CAAC"}
|
|
@@ -9,6 +9,6 @@ export interface GanttViewProps extends ViewProps {
|
|
|
9
9
|
/**
|
|
10
10
|
* GanttView Component
|
|
11
11
|
*/
|
|
12
|
-
export declare function GanttView(
|
|
12
|
+
export declare function GanttView(props: GanttViewProps): import("react/jsx-runtime").JSX.Element;
|
|
13
13
|
export default GanttView;
|
|
14
14
|
//# sourceMappingURL=GanttView.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GanttView.d.ts","sourceRoot":"","sources":["../../src/views/GanttView.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH,OAAO,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"GanttView.d.ts","sourceRoot":"","sources":["../../src/views/GanttView.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH,OAAO,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAItD;;GAEG;AACH,MAAM,WAAW,cAAe,SAAQ,SAAS;IAC/C,0BAA0B;IAC1B,MAAM,EAAE,WAAW,CAAC;CACrB;AAuCD;;GAEG;AACH,wBAAgB,SAAS,CAAC,KAAK,EAAE,cAAc,2CAO9C;AAoLD,eAAe,SAAS,CAAC"}
|
|
@@ -11,6 +11,6 @@ export interface KanbanViewProps extends ViewProps {
|
|
|
11
11
|
* - Auto-discover columns from live data if none configured
|
|
12
12
|
* - Group by any Select/Link field via `config.groupField`
|
|
13
13
|
*/
|
|
14
|
-
export declare function KanbanView(
|
|
14
|
+
export declare function KanbanView(props: KanbanViewProps): import("react/jsx-runtime").JSX.Element;
|
|
15
15
|
export default KanbanView;
|
|
16
16
|
//# sourceMappingURL=KanbanView.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"KanbanView.d.ts","sourceRoot":"","sources":["../../src/views/KanbanView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAIH,OAAO,KAAK,EAAE,SAAS,EAAE,YAAY,EAAgB,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"KanbanView.d.ts","sourceRoot":"","sources":["../../src/views/KanbanView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAIH,OAAO,KAAK,EAAE,SAAS,EAAE,YAAY,EAAgB,MAAM,SAAS,CAAC;AAYrE,MAAM,WAAW,eAAgB,SAAQ,SAAS;IAChD,MAAM,EAAE,YAAY,CAAC;CACtB;AA6KD;;;;;;;;GAQG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,eAAe,2CAOhD;AAyRD,eAAe,UAAU,CAAC"}
|
package/dist/views/TreeView.d.ts
CHANGED
|
@@ -10,6 +10,6 @@ export interface TreeViewProps extends ViewProps {
|
|
|
10
10
|
* - Inline Rename (double-click)
|
|
11
11
|
* - Drag-and-drop reparenting (PATCH /api/tree/:doctype/:id)
|
|
12
12
|
*/
|
|
13
|
-
export declare function TreeView(
|
|
13
|
+
export declare function TreeView(props: Readonly<TreeViewProps>): import("react/jsx-runtime").JSX.Element;
|
|
14
14
|
export default TreeView;
|
|
15
15
|
//# sourceMappingURL=TreeView.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TreeView.d.ts","sourceRoot":"","sources":["../../src/views/TreeView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AASH,OAAO,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"TreeView.d.ts","sourceRoot":"","sources":["../../src/views/TreeView.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AASH,OAAO,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAUrD,MAAM,WAAW,aAAc,SAAQ,SAAS;IAC9C,MAAM,EAAE,UAAU,CAAC;CACpB;AAqUD;;;;;;;GAOG;AACH,wBAAgB,QAAQ,CAAC,KAAK,EAAE,QAAQ,CAAC,aAAa,CAAC,2CAOtD;AAgLD,eAAe,QAAQ,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@framework-m/desk",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.8.0",
|
|
4
4
|
"description": "Business components, hooks, views, and providers for Framework M applications",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -33,8 +33,8 @@
|
|
|
33
33
|
"directory": "libs/framework-m-desk"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@framework-m/plugin-sdk": "^0.
|
|
37
|
-
"@framework-m/ui": "^0.
|
|
36
|
+
"@framework-m/plugin-sdk": "^0.5.0",
|
|
37
|
+
"@framework-m/ui": "^0.6.0"
|
|
38
38
|
},
|
|
39
39
|
"peerDependencies": {
|
|
40
40
|
"@refinedev/core": "^5.0.0",
|
|
@@ -51,35 +51,40 @@
|
|
|
51
51
|
"uniforms-bridge-json-schema": "^4.0.0"
|
|
52
52
|
},
|
|
53
53
|
"devDependencies": {
|
|
54
|
-
"@
|
|
55
|
-
"@framework-m/
|
|
56
|
-
"@
|
|
54
|
+
"@eslint/js": "^9.39.4",
|
|
55
|
+
"@framework-m/plugin-sdk": "^0.5.0",
|
|
56
|
+
"@framework-m/ui": "^0.6.0",
|
|
57
|
+
"@refinedev/core": "^5.0.12",
|
|
57
58
|
"@refinedev/react-router": "^2.0.4",
|
|
58
59
|
"@refinedev/react-table": "^6.0.1",
|
|
59
|
-
"@tanstack/react-query": "^5.
|
|
60
|
+
"@tanstack/react-query": "^5.99.2",
|
|
60
61
|
"@tanstack/react-table": "^8.21.3",
|
|
61
62
|
"@testing-library/jest-dom": "^6.9.1",
|
|
62
63
|
"@testing-library/react": "^16.3.2",
|
|
63
|
-
"@types/node": "^20.19.
|
|
64
|
+
"@types/node": "^20.19.39",
|
|
64
65
|
"@types/react": "^19.2.14",
|
|
65
66
|
"@types/react-dom": "^19.2.3",
|
|
66
67
|
"@vitejs/plugin-react": "^4.7.0",
|
|
67
68
|
"@vitest/coverage-v8": "4.1.2",
|
|
68
69
|
"ajv": "^8.18.0",
|
|
69
|
-
"
|
|
70
|
+
"eslint": "^9.39.4",
|
|
71
|
+
"eslint-plugin-react-hooks": "^5.2.0",
|
|
72
|
+
"globals": "^16.5.0",
|
|
73
|
+
"happy-dom": "^20.9.0",
|
|
70
74
|
"i18next": "^25.10.10",
|
|
71
75
|
"i18next-browser-languagedetector": "^8.2.1",
|
|
72
|
-
"i18next-http-backend": "^3.0.
|
|
73
|
-
"react": "^19.2.
|
|
74
|
-
"react-dom": "^19.2.
|
|
76
|
+
"i18next-http-backend": "^3.0.5",
|
|
77
|
+
"react": "^19.2.5",
|
|
78
|
+
"react-dom": "^19.2.5",
|
|
75
79
|
"react-i18next": "^16.6.6",
|
|
76
|
-
"react-router": "^7.
|
|
80
|
+
"react-router": "^7.14.1",
|
|
77
81
|
"typescript": "^5.9.3",
|
|
82
|
+
"typescript-eslint": "^8.58.2",
|
|
78
83
|
"uniforms": "^4.0.0",
|
|
79
84
|
"uniforms-bridge-json-schema": "^4.0.0",
|
|
80
|
-
"vite": "^6.4.
|
|
85
|
+
"vite": "^6.4.2",
|
|
81
86
|
"vite-plugin-dts": "^4.5.4",
|
|
82
|
-
"vitest": "^4.1.
|
|
87
|
+
"vitest": "^4.1.4"
|
|
83
88
|
},
|
|
84
89
|
"publishConfig": {
|
|
85
90
|
"access": "public"
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Navbar props
|
|
3
|
-
*/
|
|
4
|
-
export interface NavbarProps {
|
|
5
|
-
/** App title */
|
|
6
|
-
title?: string;
|
|
7
|
-
/** Logo URL */
|
|
8
|
-
logo?: string;
|
|
9
|
-
/** Whether to show global search */
|
|
10
|
-
showSearch?: boolean;
|
|
11
|
-
/** Optional callback to toggle mobile menu */
|
|
12
|
-
onMenuToggle?: () => void;
|
|
13
|
-
}
|
|
14
|
-
export declare function Navbar({ title, logo, onMenuToggle, }: Readonly<NavbarProps>): import("react/jsx-runtime").JSX.Element;
|
|
15
|
-
export default Navbar;
|
|
16
|
-
//# sourceMappingURL=Navbar.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Navbar.d.ts","sourceRoot":"","sources":["../../../../src/components/layout/Navbar/Navbar.tsx"],"names":[],"mappings":"AAiBA;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,gBAAgB;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,eAAe;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,oCAAoC;IACpC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,8CAA8C;IAC9C,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;CAC3B;AAwKD,wBAAgB,MAAM,CAAC,EACrB,KAAqB,EACrB,IAAI,EACJ,YAAY,GACb,EAAE,QAAQ,CAAC,WAAW,CAAC,2CA2dvB;AAED,eAAe,MAAM,CAAC"}
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
interface MenuSourceItem {
|
|
2
|
-
name: string;
|
|
3
|
-
label?: string;
|
|
4
|
-
icon?: string;
|
|
5
|
-
route?: string;
|
|
6
|
-
module?: string;
|
|
7
|
-
parent?: string;
|
|
8
|
-
}
|
|
9
|
-
interface MenuItem extends MenuSourceItem {
|
|
10
|
-
children?: MenuItem[];
|
|
11
|
-
}
|
|
12
|
-
export interface SidebarProps {
|
|
13
|
-
collapsed?: boolean;
|
|
14
|
-
onCollapse?: (collapsed: boolean) => void;
|
|
15
|
-
menuItems?: MenuItem[];
|
|
16
|
-
/** Whether the current viewport is mobile */
|
|
17
|
-
isMobile?: boolean;
|
|
18
|
-
/** Whether the mobile drawer is open */
|
|
19
|
-
mobileOpen?: boolean;
|
|
20
|
-
/** Callback to close the mobile drawer */
|
|
21
|
-
onCloseMobile?: () => void;
|
|
22
|
-
}
|
|
23
|
-
export declare function Sidebar({ collapsed, onCollapse, isMobile, mobileOpen, onCloseMobile, }: Readonly<SidebarProps>): import("react/jsx-runtime").JSX.Element;
|
|
24
|
-
export {};
|
|
25
|
-
//# sourceMappingURL=Sidebar.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Sidebar.d.ts","sourceRoot":"","sources":["../../../../src/components/layout/Sidebar/Sidebar.tsx"],"names":[],"mappings":"AAeA,UAAU,cAAc;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,UAAU,QAAS,SAAQ,cAAc;IACvC,QAAQ,CAAC,EAAE,QAAQ,EAAE,CAAC;CACvB;AA+BD,MAAM,WAAW,YAAY;IAC3B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,CAAC,SAAS,EAAE,OAAO,KAAK,IAAI,CAAC;IAC1C,SAAS,CAAC,EAAE,QAAQ,EAAE,CAAC;IACvB,6CAA6C;IAC7C,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,wCAAwC;IACxC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,0CAA0C;IAC1C,aAAa,CAAC,EAAE,MAAM,IAAI,CAAC;CAC5B;AAED,wBAAgB,OAAO,CAAC,EACtB,SAAiB,EACjB,UAAU,EACV,QAAgB,EAChB,UAAkB,EAClB,aAAa,GACd,EAAE,QAAQ,CAAC,YAAY,CAAC,2CAyVxB"}
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
import { DocTypeConfig, FormConfig, ListConfig, FieldConfig, ClientScript } from './types';
|
|
2
|
-
/**
|
|
3
|
-
* Register a DocType configuration
|
|
4
|
-
*
|
|
5
|
-
* @param config - DocType configuration
|
|
6
|
-
*
|
|
7
|
-
* @example
|
|
8
|
-
* ```typescript
|
|
9
|
-
* registerConfig({
|
|
10
|
-
* doctype: "Depot",
|
|
11
|
-
* form: {
|
|
12
|
-
* fields: {
|
|
13
|
-
* capacity: { label: "Max Capacity (MT)" },
|
|
14
|
-
* internal_code: { hidden: true }
|
|
15
|
-
* },
|
|
16
|
-
* sections: [
|
|
17
|
-
* { title: "Location", fields: ["location", "region"] }
|
|
18
|
-
* ]
|
|
19
|
-
* },
|
|
20
|
-
* list: {
|
|
21
|
-
* columns: ["name", "location", "capacity"],
|
|
22
|
-
* defaultSort: { field: "capacity", order: "desc" }
|
|
23
|
-
* }
|
|
24
|
-
* });
|
|
25
|
-
* ```
|
|
26
|
-
*/
|
|
27
|
-
export declare function registerConfig(config: DocTypeConfig): void;
|
|
28
|
-
/**
|
|
29
|
-
* Get configuration for a DocType
|
|
30
|
-
*/
|
|
31
|
-
export declare function getConfig(doctype: string): DocTypeConfig | undefined;
|
|
32
|
-
/**
|
|
33
|
-
* Get form configuration for a DocType
|
|
34
|
-
*/
|
|
35
|
-
export declare function getFormConfig(doctype: string): FormConfig | undefined;
|
|
36
|
-
/**
|
|
37
|
-
* Get list configuration for a DocType
|
|
38
|
-
*/
|
|
39
|
-
export declare function getListConfig(doctype: string): ListConfig | undefined;
|
|
40
|
-
/**
|
|
41
|
-
* Get field configuration override
|
|
42
|
-
*/
|
|
43
|
-
export declare function getFieldConfig(doctype: string, fieldName: string): FieldConfig | undefined;
|
|
44
|
-
/**
|
|
45
|
-
* Register a client script
|
|
46
|
-
*
|
|
47
|
-
* @param script - Client script definition
|
|
48
|
-
*
|
|
49
|
-
* @example
|
|
50
|
-
* ```typescript
|
|
51
|
-
* registerClientScript({
|
|
52
|
-
* doctype: "Sales Invoice",
|
|
53
|
-
* event: "onLoad",
|
|
54
|
-
* handler: (ctx) => {
|
|
55
|
-
* if (ctx.doc.status === "Draft") {
|
|
56
|
-
* ctx.setHidden("cancel_reason", true);
|
|
57
|
-
* }
|
|
58
|
-
* }
|
|
59
|
-
* });
|
|
60
|
-
* ```
|
|
61
|
-
*/
|
|
62
|
-
export declare function registerClientScript(script: ClientScript): void;
|
|
63
|
-
/**
|
|
64
|
-
* Get client scripts for a DocType and event
|
|
65
|
-
*/
|
|
66
|
-
export declare function getClientScripts(doctype: string, event: ClientScript["event"]): ClientScript[];
|
|
67
|
-
/**
|
|
68
|
-
* Load configuration from URL (fetches JSON)
|
|
69
|
-
*/
|
|
70
|
-
export declare function loadConfigFromUrl(url: string): Promise<void>;
|
|
71
|
-
/**
|
|
72
|
-
* Clear all configurations (for testing)
|
|
73
|
-
*/
|
|
74
|
-
export declare function clearConfigs(): void;
|
|
75
|
-
//# sourceMappingURL=registry.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"registry.d.ts","sourceRoot":"","sources":["../../src/config/registry.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EACV,aAAa,EACb,UAAU,EACV,UAAU,EACV,WAAW,EACX,YAAY,EACb,MAAM,SAAS,CAAC;AAwCjB;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,wBAAgB,cAAc,CAAC,MAAM,EAAE,aAAa,GAAG,IAAI,CAS1D;AAiDD;;GAEG;AACH,wBAAgB,SAAS,CAAC,OAAO,EAAE,MAAM,GAAG,aAAa,GAAG,SAAS,CAEpE;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,GAAG,UAAU,GAAG,SAAS,CAErE;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,GAAG,UAAU,GAAG,SAAS,CAErE;AAED;;GAEG;AACH,wBAAgB,cAAc,CAC5B,OAAO,EAAE,MAAM,EACf,SAAS,EAAE,MAAM,GAChB,WAAW,GAAG,SAAS,CAEzB;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,oBAAoB,CAAC,MAAM,EAAE,YAAY,GAAG,IAAI,CAK/D;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAC9B,OAAO,EAAE,MAAM,EACf,KAAK,EAAE,YAAY,CAAC,OAAO,CAAC,GAC3B,YAAY,EAAE,CAGhB;AAED;;GAEG;AACH,wBAAsB,iBAAiB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAYlE;AAED;;GAEG;AACH,wBAAgB,YAAY,IAAI,IAAI,CAGnC"}
|
package/dist/config/types.d.ts
DELETED
|
@@ -1,130 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Configuration Types
|
|
3
|
-
*
|
|
4
|
-
* Types for Level 1 customization (Low Code).
|
|
5
|
-
* JSON-based configuration without build step required.
|
|
6
|
-
*/
|
|
7
|
-
/**
|
|
8
|
-
* Field configuration override
|
|
9
|
-
*/
|
|
10
|
-
export interface FieldConfig {
|
|
11
|
-
/** Override label */
|
|
12
|
-
label?: string;
|
|
13
|
-
/** Hide the field */
|
|
14
|
-
hidden?: boolean;
|
|
15
|
-
/** Make read-only */
|
|
16
|
-
readonly?: boolean;
|
|
17
|
-
/** Default value */
|
|
18
|
-
default?: unknown;
|
|
19
|
-
/** Help text */
|
|
20
|
-
description?: string;
|
|
21
|
-
/** Placeholder text */
|
|
22
|
-
placeholder?: string;
|
|
23
|
-
/** Required override */
|
|
24
|
-
required?: boolean;
|
|
25
|
-
}
|
|
26
|
-
/**
|
|
27
|
-
* Form section configuration
|
|
28
|
-
*/
|
|
29
|
-
export interface SectionConfig {
|
|
30
|
-
/** Section title */
|
|
31
|
-
title: string;
|
|
32
|
-
/** Fields in this section */
|
|
33
|
-
fields: string[];
|
|
34
|
-
/** Collapsible section */
|
|
35
|
-
collapsible?: boolean;
|
|
36
|
-
/** Start collapsed */
|
|
37
|
-
collapsed?: boolean;
|
|
38
|
-
}
|
|
39
|
-
/**
|
|
40
|
-
* Form configuration
|
|
41
|
-
*/
|
|
42
|
-
export interface FormConfig {
|
|
43
|
-
/** Field overrides */
|
|
44
|
-
fields?: Record<string, FieldConfig>;
|
|
45
|
-
/** Custom sections layout */
|
|
46
|
-
sections?: SectionConfig[];
|
|
47
|
-
/** Hide default submit button */
|
|
48
|
-
hideSubmitButton?: boolean;
|
|
49
|
-
/** Custom submit text */
|
|
50
|
-
submitText?: string;
|
|
51
|
-
}
|
|
52
|
-
/**
|
|
53
|
-
* Column configuration for list view
|
|
54
|
-
*/
|
|
55
|
-
export interface ColumnConfig {
|
|
56
|
-
/** Field name */
|
|
57
|
-
field: string;
|
|
58
|
-
/** Column header */
|
|
59
|
-
header?: string;
|
|
60
|
-
/** Fixed width */
|
|
61
|
-
width?: number | string;
|
|
62
|
-
/** Hide column */
|
|
63
|
-
hidden?: boolean;
|
|
64
|
-
/** Enable sorting */
|
|
65
|
-
sortable?: boolean;
|
|
66
|
-
}
|
|
67
|
-
/**
|
|
68
|
-
* List configuration
|
|
69
|
-
*/
|
|
70
|
-
export interface ListConfig {
|
|
71
|
-
/** Column order (field names or ColumnConfig) */
|
|
72
|
-
columns?: (string | ColumnConfig)[];
|
|
73
|
-
/** Default sort */
|
|
74
|
-
defaultSort?: {
|
|
75
|
-
field: string;
|
|
76
|
-
order: "asc" | "desc";
|
|
77
|
-
};
|
|
78
|
-
/** Page size */
|
|
79
|
-
pageSize?: number;
|
|
80
|
-
/** Enable row selection */
|
|
81
|
-
enableSelection?: boolean;
|
|
82
|
-
}
|
|
83
|
-
/**
|
|
84
|
-
* Complete DocType configuration
|
|
85
|
-
*/
|
|
86
|
-
export interface DocTypeConfig {
|
|
87
|
-
/** DocType name */
|
|
88
|
-
doctype: string;
|
|
89
|
-
/** Form configuration */
|
|
90
|
-
form?: FormConfig;
|
|
91
|
-
/** List configuration */
|
|
92
|
-
list?: ListConfig;
|
|
93
|
-
}
|
|
94
|
-
/**
|
|
95
|
-
* Client script for runtime behavior
|
|
96
|
-
*/
|
|
97
|
-
export interface ClientScript {
|
|
98
|
-
/** DocType this script applies to */
|
|
99
|
-
doctype: string;
|
|
100
|
-
/** Event name */
|
|
101
|
-
event: "onLoad" | "beforeSave" | "afterSave" | "onRefresh" | "validate";
|
|
102
|
-
/** Script function */
|
|
103
|
-
handler: (context: ClientScriptContext) => void | Promise<void>;
|
|
104
|
-
}
|
|
105
|
-
/**
|
|
106
|
-
* Context passed to client scripts
|
|
107
|
-
*/
|
|
108
|
-
export interface ClientScriptContext {
|
|
109
|
-
/** Document data */
|
|
110
|
-
doc: Record<string, unknown>;
|
|
111
|
-
/** Update field value */
|
|
112
|
-
setValue: (field: string, value: unknown) => void;
|
|
113
|
-
/** Get field value */
|
|
114
|
-
getValue: (field: string) => unknown;
|
|
115
|
-
/** Set field as required */
|
|
116
|
-
setRequired: (field: string, required: boolean) => void;
|
|
117
|
-
/** Set field as hidden */
|
|
118
|
-
setHidden: (field: string, hidden: boolean) => void;
|
|
119
|
-
/** Set field as read-only */
|
|
120
|
-
setReadOnly: (field: string, readonly: boolean) => void;
|
|
121
|
-
/** Show alert message */
|
|
122
|
-
showAlert: (message: string, type?: "info" | "warning" | "error") => void;
|
|
123
|
-
/** User info */
|
|
124
|
-
user: {
|
|
125
|
-
id: string;
|
|
126
|
-
email: string;
|
|
127
|
-
roles: string[];
|
|
128
|
-
};
|
|
129
|
-
}
|
|
130
|
-
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/config/types.ts"],"names":[],"mappings":"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"}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { DocTypeConfig, FormConfig, ListConfig, FieldConfig } from './types';
|
|
2
|
-
/**
|
|
3
|
-
* Hook to get complete DocType configuration
|
|
4
|
-
*/
|
|
5
|
-
export declare function useConfig(doctype: string): DocTypeConfig | undefined;
|
|
6
|
-
/**
|
|
7
|
-
* Hook to get form configuration
|
|
8
|
-
*/
|
|
9
|
-
export declare function useFormConfig(doctype: string): FormConfig | undefined;
|
|
10
|
-
/**
|
|
11
|
-
* Hook to get list configuration
|
|
12
|
-
*/
|
|
13
|
-
export declare function useListConfig(doctype: string): ListConfig | undefined;
|
|
14
|
-
/**
|
|
15
|
-
* Hook to get field configuration override
|
|
16
|
-
*/
|
|
17
|
-
export declare function useFieldConfig(doctype: string, fieldName: string): FieldConfig | undefined;
|
|
18
|
-
//# sourceMappingURL=useConfig.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"useConfig.d.ts","sourceRoot":"","sources":["../../src/config/useConfig.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AASH,OAAO,KAAK,EAAE,aAAa,EAAE,UAAU,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAElF;;GAEG;AACH,wBAAgB,SAAS,CAAC,OAAO,EAAE,MAAM,GAAG,aAAa,GAAG,SAAS,CAEpE;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,GAAG,UAAU,GAAG,SAAS,CAErE;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,GAAG,UAAU,GAAG,SAAS,CAErE;AAED;;GAEG;AACH,wBAAgB,cAAc,CAC5B,OAAO,EAAE,MAAM,EACf,SAAS,EAAE,MAAM,GAChB,WAAW,GAAG,SAAS,CAKzB"}
|