@declarion/react 0.1.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/LICENSE +21 -0
- package/README.md +21 -0
- package/dist-lib/JsonEditor-C5NOzsey.js +71 -0
- package/dist-lib/JsonEditor-C5NOzsey.js.map +1 -0
- package/dist-lib/api/auth.d.ts +11 -0
- package/dist-lib/api/client.d.ts +3 -0
- package/dist-lib/api/data.d.ts +28 -0
- package/dist-lib/api/entities.d.ts +75 -0
- package/dist-lib/api/events.d.ts +9 -0
- package/dist-lib/api/params.d.ts +3 -0
- package/dist-lib/api/properties.d.ts +3 -0
- package/dist-lib/api/schema.d.ts +2 -0
- package/dist-lib/api/status.d.ts +2 -0
- package/dist-lib/app.d.ts +1 -0
- package/dist-lib/components/columns/ColumnPicker.d.ts +15 -0
- package/dist-lib/components/detail-layout/AssociatedBlock.d.ts +8 -0
- package/dist-lib/components/detail-layout/AssociatedToolbar.d.ts +13 -0
- package/dist-lib/components/detail-layout/ChildrenBlock.d.ts +15 -0
- package/dist-lib/components/detail-layout/ChildrenCards.d.ts +2 -0
- package/dist-lib/components/detail-layout/ChildrenList.d.ts +2 -0
- package/dist-lib/components/detail-layout/ChildrenTable.d.ts +2 -0
- package/dist-lib/components/detail-layout/ChildrenTimeline.d.ts +2 -0
- package/dist-lib/components/detail-layout/DraggableChildrenTable.d.ts +15 -0
- package/dist-lib/components/detail-layout/EditableChildrenTable.d.ts +15 -0
- package/dist-lib/components/detail-layout/FieldsBlock.d.ts +7 -0
- package/dist-lib/components/detail-layout/LayoutColumn.d.ts +9 -0
- package/dist-lib/components/detail-layout/LayoutRenderer.d.ts +42 -0
- package/dist-lib/components/detail-layout/LayoutRow.d.ts +8 -0
- package/dist-lib/components/detail-layout/LayoutTabs.d.ts +8 -0
- package/dist-lib/components/detail-layout/PropertiesBlock.d.ts +8 -0
- package/dist-lib/components/detail-layout/QuickAddForm.d.ts +10 -0
- package/dist-lib/components/detail-layout/SectionBlock.d.ts +8 -0
- package/dist-lib/components/detail-layout/StatusesBlock.d.ts +8 -0
- package/dist-lib/components/detail-layout/TimelineComposer.d.ts +10 -0
- package/dist-lib/components/detail-layout/index.d.ts +18 -0
- package/dist-lib/components/detail-layout/useQuickAdd.d.ts +17 -0
- package/dist-lib/components/fields/BoolField.d.ts +2 -0
- package/dist-lib/components/fields/EmailField.d.ts +2 -0
- package/dist-lib/components/fields/EnumField.d.ts +2 -0
- package/dist-lib/components/fields/IntArrayField.d.ts +2 -0
- package/dist-lib/components/fields/JsonEditor.d.ts +9 -0
- package/dist-lib/components/fields/JsonField.d.ts +2 -0
- package/dist-lib/components/fields/MultilangField.d.ts +2 -0
- package/dist-lib/components/fields/MultilangTextField.d.ts +2 -0
- package/dist-lib/components/fields/NumberField.d.ts +2 -0
- package/dist-lib/components/fields/PasswordField.d.ts +2 -0
- package/dist-lib/components/fields/RefField.d.ts +2 -0
- package/dist-lib/components/fields/SecretField.d.ts +2 -0
- package/dist-lib/components/fields/StringArrayField.d.ts +2 -0
- package/dist-lib/components/fields/StringField.d.ts +2 -0
- package/dist-lib/components/fields/StructureField.d.ts +2 -0
- package/dist-lib/components/fields/TextField.d.ts +2 -0
- package/dist-lib/components/fields/TimestampField.d.ts +2 -0
- package/dist-lib/components/fields/UrlField.d.ts +2 -0
- package/dist-lib/components/fields/index.d.ts +16 -0
- package/dist-lib/components/filters/FilterChips.d.ts +16 -0
- package/dist-lib/components/filters/FilterDrawer.d.ts +27 -0
- package/dist-lib/components/layout/Layout.d.ts +1 -0
- package/dist-lib/components/layout/Sidebar.d.ts +1 -0
- package/dist-lib/components/layout/TabBar.d.ts +1 -0
- package/dist-lib/components/layout/ThemeToggle.d.ts +1 -0
- package/dist-lib/components/layout/TopBar.d.ts +1 -0
- package/dist-lib/components/pages/AdminCatalogPage.d.ts +1 -0
- package/dist-lib/components/pages/LoginPage.d.ts +1 -0
- package/dist-lib/components/pages/NotFoundPage.d.ts +1 -0
- package/dist-lib/components/pages/SSOCallbackPage.d.ts +1 -0
- package/dist-lib/components/pages/SignupPage.d.ts +1 -0
- package/dist-lib/components/pages/SmartDetailPage.d.ts +5 -0
- package/dist-lib/components/pages/SmartListPage.d.ts +5 -0
- package/dist-lib/components/pages/SmartRecordListPage.d.ts +5 -0
- package/dist-lib/components/shared/ActionButton.d.ts +24 -0
- package/dist-lib/components/shared/ActionConfirmDialog.d.ts +10 -0
- package/dist-lib/components/shared/ActionDialog.d.ts +22 -0
- package/dist-lib/components/shared/ActionResultDialog.d.ts +18 -0
- package/dist-lib/components/shared/AssociationTabs.d.ts +9 -0
- package/dist-lib/components/shared/BatchActionProgress.d.ts +18 -0
- package/dist-lib/components/shared/ConfirmDialog.d.ts +11 -0
- package/dist-lib/components/shared/DynamicIcon.d.ts +6 -0
- package/dist-lib/components/shared/EmptyState.d.ts +9 -0
- package/dist-lib/components/shared/ErrorBoundary.d.ts +22 -0
- package/dist-lib/components/shared/LoadingSkeleton.d.ts +5 -0
- package/dist-lib/components/shared/PageHeader.d.ts +8 -0
- package/dist-lib/components/shared/RowActionItem.d.ts +11 -0
- package/dist-lib/components/shared/StatusGroupsDisplay.d.ts +11 -0
- package/dist-lib/components/ui/alert-dialog.d.ts +14 -0
- package/dist-lib/components/ui/badge.d.ts +9 -0
- package/dist-lib/components/ui/button.d.ts +11 -0
- package/dist-lib/components/ui/card.d.ts +8 -0
- package/dist-lib/components/ui/dialog.d.ts +13 -0
- package/dist-lib/components/ui/dropdown-menu.d.ts +24 -0
- package/dist-lib/components/ui/input.d.ts +3 -0
- package/dist-lib/components/ui/label.d.ts +5 -0
- package/dist-lib/components/ui/select.d.ts +13 -0
- package/dist-lib/components/ui/separator.d.ts +4 -0
- package/dist-lib/components/ui/skeleton.d.ts +2 -0
- package/dist-lib/components/ui/table.d.ts +10 -0
- package/dist-lib/components/ui/textarea.d.ts +3 -0
- package/dist-lib/components/views/ViewSwitcher.d.ts +27 -0
- package/dist-lib/hooks/useAssociatedData.d.ts +10 -0
- package/dist-lib/hooks/useAuth.d.ts +21 -0
- package/dist-lib/hooks/useChildrenData.d.ts +3 -0
- package/dist-lib/hooks/useColumns.d.ts +13 -0
- package/dist-lib/hooks/useDebounce.d.ts +1 -0
- package/dist-lib/hooks/useEntity.d.ts +2 -0
- package/dist-lib/hooks/useEntityData.d.ts +2 -0
- package/dist-lib/hooks/useEntityItem.d.ts +2 -0
- package/dist-lib/hooks/useFilters.d.ts +11 -0
- package/dist-lib/hooks/useMutations.d.ts +13 -0
- package/dist-lib/hooks/useObjectStatus.d.ts +5 -0
- package/dist-lib/hooks/useParams.d.ts +2 -0
- package/dist-lib/hooks/useProperties.d.ts +5 -0
- package/dist-lib/hooks/useSSE.d.ts +1 -0
- package/dist-lib/hooks/useSchema.d.ts +1 -0
- package/dist-lib/hooks/useScreen.d.ts +2 -0
- package/dist-lib/hooks/useTabNavigate.d.ts +8 -0
- package/dist-lib/hooks/useViews.d.ts +6 -0
- package/dist-lib/index.d.ts +37 -0
- package/dist-lib/index.js +8424 -0
- package/dist-lib/index.js.map +1 -0
- package/dist-lib/lib/actions.d.ts +43 -0
- package/dist-lib/lib/child-config.d.ts +23 -0
- package/dist-lib/lib/children-validation.d.ts +3 -0
- package/dist-lib/lib/filters.d.ts +42 -0
- package/dist-lib/lib/quick-add.d.ts +2 -0
- package/dist-lib/lib/size-value.d.ts +16 -0
- package/dist-lib/lib/theme-utils.d.ts +3 -0
- package/dist-lib/lib/timestamp.d.ts +8 -0
- package/dist-lib/lib/utils.d.ts +2 -0
- package/dist-lib/main.d.ts +1 -0
- package/dist-lib/stores/auth.d.ts +15 -0
- package/dist-lib/stores/screen-registry.d.ts +3 -0
- package/dist-lib/stores/tabs.d.ts +21 -0
- package/dist-lib/stores/theme.d.ts +10 -0
- package/dist-lib/types/api.d.ts +178 -0
- package/dist-lib/types/schema.d.ts +380 -0
- package/package.json +85 -0
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { EntityField } from "@/types/schema";
|
|
2
|
+
export type RefsMap = Record<string, Record<string, Record<string, unknown>>>;
|
|
3
|
+
export interface FieldRendererProps {
|
|
4
|
+
field: EntityField;
|
|
5
|
+
fieldName: string;
|
|
6
|
+
value: unknown;
|
|
7
|
+
mode: "display" | "edit";
|
|
8
|
+
onChange?: (value: unknown) => void;
|
|
9
|
+
record?: Record<string, unknown>;
|
|
10
|
+
refs?: RefsMap;
|
|
11
|
+
}
|
|
12
|
+
type FieldRenderer = React.ComponentType<FieldRendererProps>;
|
|
13
|
+
export declare function renderField(props: FieldRendererProps): React.ReactNode;
|
|
14
|
+
export declare function getFieldRenderer(type: string): FieldRenderer;
|
|
15
|
+
export declare function hasFieldRenderer(key: string): boolean;
|
|
16
|
+
export {};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type FilterNode } from "@/lib/filters";
|
|
2
|
+
interface FilterChipsProps {
|
|
3
|
+
filters: FilterNode[];
|
|
4
|
+
onRemove: (field: string) => void;
|
|
5
|
+
onClearAll: () => void;
|
|
6
|
+
onChipClick?: () => void;
|
|
7
|
+
/** Resolve field name to display label */
|
|
8
|
+
fieldLabel?: (field: string) => string;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* FilterChips shows active filters as compact chips between toolbar and table.
|
|
12
|
+
* Simple mode: flat chips. OR mode: grouped chips.
|
|
13
|
+
* Zero active filters = hidden (zero height).
|
|
14
|
+
*/
|
|
15
|
+
export declare function FilterChips({ filters, onRemove, onClearAll, onChipClick, fieldLabel, }: FilterChipsProps): import("react/jsx-runtime").JSX.Element | null;
|
|
16
|
+
export {};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { type FilterNode, type FilterOp } from "@/lib/filters";
|
|
2
|
+
export interface FilterFieldMeta {
|
|
3
|
+
code: string;
|
|
4
|
+
label: string;
|
|
5
|
+
type: "string" | "enum" | "int" | "float" | "date" | "timestamp" | "bool" | "ref" | "status" | "property" | string;
|
|
6
|
+
operators: FilterOp[];
|
|
7
|
+
/** Enum values for enum/status fields. */
|
|
8
|
+
options?: {
|
|
9
|
+
value: string;
|
|
10
|
+
label: string;
|
|
11
|
+
color?: string;
|
|
12
|
+
}[];
|
|
13
|
+
}
|
|
14
|
+
interface FilterDrawerProps {
|
|
15
|
+
open: boolean;
|
|
16
|
+
onClose: () => void;
|
|
17
|
+
filters: FilterNode[];
|
|
18
|
+
onApply: (filters: FilterNode[]) => void;
|
|
19
|
+
availableFields: FilterFieldMeta[];
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* FilterDrawer - right-side panel with progressive disclosure.
|
|
23
|
+
* Level 1: flat AND conditions (default).
|
|
24
|
+
* Level 2: OR groups when "Add OR group" is clicked.
|
|
25
|
+
*/
|
|
26
|
+
export declare function FilterDrawer({ open, onClose, filters, onApply, availableFields, }: FilterDrawerProps): import("react/jsx-runtime").JSX.Element | null;
|
|
27
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function Layout(): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function Sidebar(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function TabBar(): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function ThemeToggle(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function TopBar(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function AdminCatalogPage(): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function LoginPage(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function NotFoundPage(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function SSOCallbackPage(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function SignupPage(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import type { Action } from "@/types/schema";
|
|
2
|
+
interface ActionButtonProps {
|
|
3
|
+
actionCode: string;
|
|
4
|
+
action: Action;
|
|
5
|
+
entityCode?: string;
|
|
6
|
+
/** Selected object IDs (for single/batch scope). */
|
|
7
|
+
objectIds?: string[];
|
|
8
|
+
/** Current row data for condition evaluation (single row context). */
|
|
9
|
+
row?: Record<string, unknown>;
|
|
10
|
+
/** Variant for the button. */
|
|
11
|
+
variant?: "default" | "outline" | "ghost" | "secondary";
|
|
12
|
+
/** Size for the button. */
|
|
13
|
+
size?: "default" | "sm" | "icon";
|
|
14
|
+
/** Called after action execution succeeds. */
|
|
15
|
+
onSuccess?: () => void;
|
|
16
|
+
/** Called when a batch action starts executing. */
|
|
17
|
+
onBatchStart?: (count: number) => void;
|
|
18
|
+
/** Called when a batch action fails. */
|
|
19
|
+
onBatchError?: (count: number) => void;
|
|
20
|
+
/** Called when a batch action partially succeeds (some items failed/skipped). */
|
|
21
|
+
onBatchPartial?: (count: number, successIds?: string[]) => void;
|
|
22
|
+
}
|
|
23
|
+
export declare function ActionButton({ actionCode, action, entityCode, objectIds, row, variant, size, onSuccess, onBatchStart, onBatchError, onBatchPartial, }: ActionButtonProps): import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
interface ActionConfirmDialogProps {
|
|
2
|
+
open: boolean;
|
|
3
|
+
onOpenChange: (open: boolean) => void;
|
|
4
|
+
actionName: string;
|
|
5
|
+
message: string;
|
|
6
|
+
onConfirm: () => void;
|
|
7
|
+
isPending: boolean;
|
|
8
|
+
}
|
|
9
|
+
export declare function ActionConfirmDialog({ open, onOpenChange, actionName, message, onConfirm, isPending, }: ActionConfirmDialogProps): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { Action } from "@/types/schema";
|
|
2
|
+
interface ActionDialogProps {
|
|
3
|
+
open: boolean;
|
|
4
|
+
onOpenChange: (open: boolean) => void;
|
|
5
|
+
action: Action;
|
|
6
|
+
actionName: string;
|
|
7
|
+
onSubmit: (params: Record<string, unknown>) => void;
|
|
8
|
+
isPending: boolean;
|
|
9
|
+
/**
|
|
10
|
+
* Target record for default-value prefill via the `$row.<field>` template
|
|
11
|
+
* syntax. When a param default is a string literal `$row.foo`, the dialog
|
|
12
|
+
* substitutes `row.foo` at open time. For batch invocations on a list
|
|
13
|
+
* page, pass the first selected row (or omit - callers that invoke the
|
|
14
|
+
* action without a single-row context simply don't get row prefills).
|
|
15
|
+
*
|
|
16
|
+
* The substitution is client-side only. The server ignores template
|
|
17
|
+
* syntax - it only sees the concrete value the admin submits.
|
|
18
|
+
*/
|
|
19
|
+
row?: Record<string, unknown>;
|
|
20
|
+
}
|
|
21
|
+
export declare function ActionDialog({ open, onOpenChange, action, actionName, onSubmit, isPending, row, }: ActionDialogProps): import("react/jsx-runtime").JSX.Element;
|
|
22
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export interface DisplayField {
|
|
2
|
+
label: string;
|
|
3
|
+
value: string;
|
|
4
|
+
copyable?: boolean;
|
|
5
|
+
monospace?: boolean;
|
|
6
|
+
}
|
|
7
|
+
export interface ActionDisplayResult {
|
|
8
|
+
title?: string;
|
|
9
|
+
message?: string;
|
|
10
|
+
fields?: DisplayField[];
|
|
11
|
+
}
|
|
12
|
+
interface ActionResultDialogProps {
|
|
13
|
+
open: boolean;
|
|
14
|
+
onClose: () => void;
|
|
15
|
+
display: ActionDisplayResult;
|
|
16
|
+
}
|
|
17
|
+
export declare function ActionResultDialog({ open, onClose, display }: ActionResultDialogProps): import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { AssociationDef, Schema } from "@/types/schema";
|
|
2
|
+
interface AssociationTabsProps {
|
|
3
|
+
entityCode: string;
|
|
4
|
+
recordId: string;
|
|
5
|
+
associations: Record<string, AssociationDef>;
|
|
6
|
+
schema: Schema;
|
|
7
|
+
}
|
|
8
|
+
export declare function AssociationTabs({ entityCode, recordId, associations, schema, }: AssociationTabsProps): import("react/jsx-runtime").JSX.Element | null;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
interface BatchActionProgressProps {
|
|
2
|
+
/** Number of items being processed. */
|
|
3
|
+
count: number;
|
|
4
|
+
/** Whether the action is currently executing. */
|
|
5
|
+
isPending: boolean;
|
|
6
|
+
/** Whether the last execution succeeded. */
|
|
7
|
+
isSuccess?: boolean;
|
|
8
|
+
/** Whether the last execution errored. */
|
|
9
|
+
isError?: boolean;
|
|
10
|
+
/** Whether the last execution partially succeeded (some items failed/skipped). */
|
|
11
|
+
isPartial?: boolean;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Inline progress indicator for batch actions.
|
|
15
|
+
* Shows selected count, a spinner during execution, and success/error/partial state.
|
|
16
|
+
*/
|
|
17
|
+
export declare function BatchActionProgress({ count, isPending, isSuccess, isError, isPartial, }: BatchActionProgressProps): import("react/jsx-runtime").JSX.Element | null;
|
|
18
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
interface ConfirmDialogProps {
|
|
2
|
+
open: boolean;
|
|
3
|
+
onOpenChange: (open: boolean) => void;
|
|
4
|
+
title: string;
|
|
5
|
+
description: string;
|
|
6
|
+
confirmLabel?: string;
|
|
7
|
+
onConfirm: () => void;
|
|
8
|
+
destructive?: boolean;
|
|
9
|
+
}
|
|
10
|
+
export declare function ConfirmDialog({ open, onOpenChange, title, description, confirmLabel, onConfirm, destructive, }: ConfirmDialogProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ReactNode } from "react";
|
|
2
|
+
interface EmptyStateProps {
|
|
3
|
+
icon?: string;
|
|
4
|
+
title: string;
|
|
5
|
+
description?: string;
|
|
6
|
+
action?: ReactNode;
|
|
7
|
+
}
|
|
8
|
+
export declare function EmptyState({ icon, title, description, action }: EmptyStateProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { Component, type ErrorInfo, type ReactNode } from "react";
|
|
2
|
+
interface Props {
|
|
3
|
+
children: ReactNode;
|
|
4
|
+
/** Optional fallback UI. Defaults to a centered error card with retry button. */
|
|
5
|
+
fallback?: ReactNode;
|
|
6
|
+
}
|
|
7
|
+
interface State {
|
|
8
|
+
hasError: boolean;
|
|
9
|
+
error: Error | null;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Catches JavaScript errors in child components and renders a fallback UI
|
|
13
|
+
* instead of crashing the entire app.
|
|
14
|
+
*/
|
|
15
|
+
export declare class ErrorBoundary extends Component<Props, State> {
|
|
16
|
+
constructor(props: Props);
|
|
17
|
+
static getDerivedStateFromError(error: Error): State;
|
|
18
|
+
componentDidCatch(error: Error, info: ErrorInfo): void;
|
|
19
|
+
handleRetry: () => void;
|
|
20
|
+
render(): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined;
|
|
21
|
+
}
|
|
22
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { ReactNode } from "react";
|
|
2
|
+
interface PageHeaderProps {
|
|
3
|
+
title: string;
|
|
4
|
+
backTo?: string;
|
|
5
|
+
actions?: ReactNode;
|
|
6
|
+
}
|
|
7
|
+
export declare function PageHeader({ title, backTo, actions }: PageHeaderProps): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { Action } from "@/types/schema";
|
|
2
|
+
interface RowActionItemProps {
|
|
3
|
+
actionCode: string;
|
|
4
|
+
action: Action;
|
|
5
|
+
entityCode?: string;
|
|
6
|
+
objectId: string;
|
|
7
|
+
row: Record<string, unknown>;
|
|
8
|
+
onSuccess?: () => void;
|
|
9
|
+
}
|
|
10
|
+
export declare function RowActionItem({ actionCode, action, entityCode, objectId, row, onSuccess, }: RowActionItemProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { StatusGroupDef } from "@/types/schema";
|
|
2
|
+
import type { StatusInfo } from "@/types/api";
|
|
3
|
+
interface StatusGroupsDisplayProps {
|
|
4
|
+
statusGroups: Record<string, StatusGroupDef>;
|
|
5
|
+
objectStatuses: StatusInfo[] | undefined;
|
|
6
|
+
onSetStatus: (groupCode: string, statusCode: string) => void;
|
|
7
|
+
isPending: boolean;
|
|
8
|
+
mode?: "display" | "edit";
|
|
9
|
+
}
|
|
10
|
+
export declare function StatusGroupsDisplay({ statusGroups, objectStatuses, onSetStatus, isPending, mode, }: StatusGroupsDisplayProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as AlertDialogPrimitive from "@radix-ui/react-alert-dialog";
|
|
3
|
+
declare const AlertDialog: React.FC<AlertDialogPrimitive.AlertDialogProps>;
|
|
4
|
+
declare const AlertDialogTrigger: React.ForwardRefExoticComponent<AlertDialogPrimitive.AlertDialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
5
|
+
declare const AlertDialogPortal: React.FC<AlertDialogPrimitive.AlertDialogPortalProps>;
|
|
6
|
+
declare const AlertDialogOverlay: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogOverlayProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
7
|
+
declare const AlertDialogContent: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
+
declare function AlertDialogHeader({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare function AlertDialogFooter({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare const AlertDialogTitle: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogTitleProps & React.RefAttributes<HTMLHeadingElement>, "ref"> & React.RefAttributes<HTMLHeadingElement>>;
|
|
11
|
+
declare const AlertDialogDescription: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogDescriptionProps & React.RefAttributes<HTMLParagraphElement>, "ref"> & React.RefAttributes<HTMLParagraphElement>>;
|
|
12
|
+
declare const AlertDialogAction: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogActionProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
13
|
+
declare const AlertDialogCancel: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogCancelProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
14
|
+
export { AlertDialog, AlertDialogPortal, AlertDialogOverlay, AlertDialogTrigger, AlertDialogContent, AlertDialogHeader, AlertDialogFooter, AlertDialogTitle, AlertDialogDescription, AlertDialogAction, AlertDialogCancel, };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type VariantProps } from "class-variance-authority";
|
|
2
|
+
declare const badgeVariants: (props?: ({
|
|
3
|
+
variant?: "default" | "destructive" | "outline" | "secondary" | null | undefined;
|
|
4
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
5
|
+
export interface BadgeProps extends React.HTMLAttributes<HTMLDivElement>, VariantProps<typeof badgeVariants> {
|
|
6
|
+
color?: string;
|
|
7
|
+
}
|
|
8
|
+
declare function Badge({ className, variant, color, style, ...props }: BadgeProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export { Badge, badgeVariants };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { type VariantProps } from "class-variance-authority";
|
|
3
|
+
declare const buttonVariants: (props?: ({
|
|
4
|
+
variant?: "link" | "ghost" | "default" | "destructive" | "outline" | "secondary" | null | undefined;
|
|
5
|
+
size?: "icon" | "default" | "sm" | "lg" | null | undefined;
|
|
6
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
7
|
+
export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
|
|
8
|
+
asChild?: boolean;
|
|
9
|
+
}
|
|
10
|
+
declare const Button: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLButtonElement>>;
|
|
11
|
+
export { Button, buttonVariants };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
declare const Card: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
3
|
+
declare const CardHeader: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
4
|
+
declare const CardTitle: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
5
|
+
declare const CardDescription: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
6
|
+
declare const CardContent: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
7
|
+
declare const CardFooter: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
+
export { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as DialogPrimitive from "@radix-ui/react-dialog";
|
|
3
|
+
declare const Dialog: React.FC<DialogPrimitive.DialogProps>;
|
|
4
|
+
declare const DialogTrigger: React.ForwardRefExoticComponent<DialogPrimitive.DialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
5
|
+
declare const DialogPortal: React.FC<DialogPrimitive.DialogPortalProps>;
|
|
6
|
+
declare const DialogClose: React.ForwardRefExoticComponent<DialogPrimitive.DialogCloseProps & React.RefAttributes<HTMLButtonElement>>;
|
|
7
|
+
declare const DialogOverlay: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogOverlayProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
+
declare const DialogContent: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
9
|
+
declare function DialogHeader({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare function DialogFooter({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
declare const DialogTitle: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogTitleProps & React.RefAttributes<HTMLHeadingElement>, "ref"> & React.RefAttributes<HTMLHeadingElement>>;
|
|
12
|
+
declare const DialogDescription: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogDescriptionProps & React.RefAttributes<HTMLParagraphElement>, "ref"> & React.RefAttributes<HTMLParagraphElement>>;
|
|
13
|
+
export { Dialog, DialogPortal, DialogOverlay, DialogTrigger, DialogClose, DialogContent, DialogHeader, DialogFooter, DialogTitle, DialogDescription, };
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu";
|
|
3
|
+
declare const DropdownMenu: React.FC<DropdownMenuPrimitive.DropdownMenuProps>;
|
|
4
|
+
declare const DropdownMenuTrigger: React.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
5
|
+
declare const DropdownMenuGroup: React.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuGroupProps & React.RefAttributes<HTMLDivElement>>;
|
|
6
|
+
declare const DropdownMenuPortal: React.FC<DropdownMenuPrimitive.DropdownMenuPortalProps>;
|
|
7
|
+
declare const DropdownMenuSub: React.FC<DropdownMenuPrimitive.DropdownMenuSubProps>;
|
|
8
|
+
declare const DropdownMenuRadioGroup: React.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuRadioGroupProps & React.RefAttributes<HTMLDivElement>>;
|
|
9
|
+
declare const DropdownMenuSubTrigger: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSubTriggerProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
10
|
+
inset?: boolean;
|
|
11
|
+
} & React.RefAttributes<HTMLDivElement>>;
|
|
12
|
+
declare const DropdownMenuSubContent: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSubContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
13
|
+
declare const DropdownMenuContent: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
14
|
+
declare const DropdownMenuItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
15
|
+
inset?: boolean;
|
|
16
|
+
} & React.RefAttributes<HTMLDivElement>>;
|
|
17
|
+
declare const DropdownMenuCheckboxItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuCheckboxItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
18
|
+
declare const DropdownMenuRadioItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuRadioItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
19
|
+
declare const DropdownMenuLabel: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
20
|
+
inset?: boolean;
|
|
21
|
+
} & React.RefAttributes<HTMLDivElement>>;
|
|
22
|
+
declare const DropdownMenuSeparator: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
23
|
+
declare function DropdownMenuShortcut({ className, ...props }: React.HTMLAttributes<HTMLSpanElement>): import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
export { DropdownMenu, DropdownMenuTrigger, DropdownMenuContent, DropdownMenuItem, DropdownMenuCheckboxItem, DropdownMenuRadioItem, DropdownMenuLabel, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuGroup, DropdownMenuPortal, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuRadioGroup, };
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as LabelPrimitive from "@radix-ui/react-label";
|
|
3
|
+
import { type VariantProps } from "class-variance-authority";
|
|
4
|
+
declare const Label: React.ForwardRefExoticComponent<Omit<LabelPrimitive.LabelProps & React.RefAttributes<HTMLLabelElement>, "ref"> & VariantProps<(props?: import("class-variance-authority/types").ClassProp | undefined) => string> & React.RefAttributes<HTMLLabelElement>>;
|
|
5
|
+
export { Label };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as SelectPrimitive from "@radix-ui/react-select";
|
|
3
|
+
declare const Select: React.FC<SelectPrimitive.SelectProps>;
|
|
4
|
+
declare const SelectGroup: React.ForwardRefExoticComponent<SelectPrimitive.SelectGroupProps & React.RefAttributes<HTMLDivElement>>;
|
|
5
|
+
declare const SelectValue: React.ForwardRefExoticComponent<SelectPrimitive.SelectValueProps & React.RefAttributes<HTMLSpanElement>>;
|
|
6
|
+
declare const SelectTrigger: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
7
|
+
declare const SelectScrollUpButton: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollUpButtonProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
+
declare const SelectScrollDownButton: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollDownButtonProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
9
|
+
declare const SelectContent: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
10
|
+
declare const SelectItem: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
11
|
+
declare const SelectLabel: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
12
|
+
declare const SelectSeparator: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
13
|
+
export { Select, SelectGroup, SelectValue, SelectTrigger, SelectContent, SelectItem, SelectLabel, SelectSeparator, SelectScrollUpButton, SelectScrollDownButton, };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as SeparatorPrimitive from "@radix-ui/react-separator";
|
|
3
|
+
declare const Separator: React.ForwardRefExoticComponent<Omit<SeparatorPrimitive.SeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
4
|
+
export { Separator };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
declare const Table: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLTableElement> & React.RefAttributes<HTMLTableElement>>;
|
|
3
|
+
declare const TableHeader: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLTableSectionElement> & React.RefAttributes<HTMLTableSectionElement>>;
|
|
4
|
+
declare const TableBody: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLTableSectionElement> & React.RefAttributes<HTMLTableSectionElement>>;
|
|
5
|
+
declare const TableFooter: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLTableSectionElement> & React.RefAttributes<HTMLTableSectionElement>>;
|
|
6
|
+
declare const TableRow: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLTableRowElement> & React.RefAttributes<HTMLTableRowElement>>;
|
|
7
|
+
declare const TableHead: React.ForwardRefExoticComponent<React.ThHTMLAttributes<HTMLTableCellElement> & React.RefAttributes<HTMLTableCellElement>>;
|
|
8
|
+
declare const TableCell: React.ForwardRefExoticComponent<React.TdHTMLAttributes<HTMLTableCellElement> & React.RefAttributes<HTMLTableCellElement>>;
|
|
9
|
+
declare const TableCaption: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLTableCaptionElement> & React.RefAttributes<HTMLTableCaptionElement>>;
|
|
10
|
+
export { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption, };
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
export interface ViewItem {
|
|
2
|
+
/** UUID for DB views, code string for system views */
|
|
3
|
+
id: string;
|
|
4
|
+
name: Record<string, string>;
|
|
5
|
+
icon?: string;
|
|
6
|
+
source: "system" | "personal" | "shared";
|
|
7
|
+
is_default?: boolean;
|
|
8
|
+
filters?: unknown[];
|
|
9
|
+
columns?: string[];
|
|
10
|
+
sort?: string;
|
|
11
|
+
}
|
|
12
|
+
interface ViewSwitcherProps {
|
|
13
|
+
views: ViewItem[];
|
|
14
|
+
activeViewId: string | null;
|
|
15
|
+
isDirty: boolean;
|
|
16
|
+
onSelect: (view: ViewItem) => void;
|
|
17
|
+
onSave?: () => void;
|
|
18
|
+
onSaveAs?: () => void;
|
|
19
|
+
onSetDefault?: (viewId: string) => void;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* ViewSwitcher - dropdown at the top of list pages.
|
|
23
|
+
* Shows system views (presets) + personal/shared DB views.
|
|
24
|
+
* "Save View" button appears when dirty.
|
|
25
|
+
*/
|
|
26
|
+
export declare function ViewSwitcher({ views, activeViewId, isDirty, onSelect, onSave, onSaveAs, onSetDefault, }: ViewSwitcherProps): import("react/jsx-runtime").JSX.Element;
|
|
27
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { V2ListResponse } from "@/types/api";
|
|
2
|
+
/**
|
|
3
|
+
* useAssociatedData fetches associated (non-aggregate) child entity records
|
|
4
|
+
* with cursor-based pagination, search, and filter support.
|
|
5
|
+
*
|
|
6
|
+
* Uses useInfiniteQuery so that "Load more" accumulates pages rather than
|
|
7
|
+
* replacing data. The query key is compatible with the SSE invalidation
|
|
8
|
+
* predicate (index 0 = ENTITY_CHILDREN_KEY, index 3 = child entity code).
|
|
9
|
+
*/
|
|
10
|
+
export declare function useAssociatedData(parentEntity: string, parentId: string, entityCode: string, foreignKey: string, sort?: string, limit?: number, search?: string, filters?: Record<string, string>): import("@tanstack/react-query").UseInfiniteQueryResult<import("@tanstack/react-query").InfiniteData<V2ListResponse<Record<string, unknown>>, unknown>, Error>;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export declare function useAuth(): {
|
|
2
|
+
user: import("..").AuthUser | null;
|
|
3
|
+
isAuthenticated: boolean;
|
|
4
|
+
isLoading: boolean;
|
|
5
|
+
activeTenant: import("..").Tenant | null;
|
|
6
|
+
tenants: import("..").Tenant[];
|
|
7
|
+
login: import("@tanstack/react-query").UseMutateFunction<import("..").LoginResponse, Error, {
|
|
8
|
+
email: string;
|
|
9
|
+
password: string;
|
|
10
|
+
}, unknown>;
|
|
11
|
+
signup: import("@tanstack/react-query").UseMutateFunction<import("..").LoginResponse, Error, {
|
|
12
|
+
email: string;
|
|
13
|
+
password: string;
|
|
14
|
+
displayName: string;
|
|
15
|
+
}, unknown>;
|
|
16
|
+
switchTenant: import("@tanstack/react-query").UseMutateFunction<import("..").LoginResponse, Error, string, unknown>;
|
|
17
|
+
logout: () => Promise<void>;
|
|
18
|
+
isLoginPending: boolean;
|
|
19
|
+
isSignupPending: boolean;
|
|
20
|
+
isSwitchingTenant: boolean;
|
|
21
|
+
};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import type { ListResponse } from "@/types/api";
|
|
2
|
+
export declare const ENTITY_CHILDREN_KEY: "entity-children";
|
|
3
|
+
export declare function useChildrenData(parentEntity: string, parentId: string, childCode: string, foreignKey: string | string[], sort?: string, limit?: number): import("@tanstack/react-query").UseQueryResult<ListResponse<Record<string, unknown>>, Error>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* useColumns manages visible columns via URL `columns` param.
|
|
3
|
+
* Falls back to screen defaults when no URL param is set.
|
|
4
|
+
*/
|
|
5
|
+
export declare function useColumns(availableColumns: string[], defaultColumns: string[]): {
|
|
6
|
+
visibleColumns: string[];
|
|
7
|
+
availableColumns: string[];
|
|
8
|
+
setColumns: (cols: string[]) => void;
|
|
9
|
+
resetToDefaults: () => void;
|
|
10
|
+
showAll: () => void;
|
|
11
|
+
isColumnVisible: (col: string) => boolean;
|
|
12
|
+
toggleColumn: (col: string) => void;
|
|
13
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function useDebounce<T>(value: T, delay: number): T;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type FilterNode } from "@/lib/filters";
|
|
2
|
+
/**
|
|
3
|
+
* useFilters reads/writes the JSON `filters` URL param.
|
|
4
|
+
* URL is the source of truth.
|
|
5
|
+
*/
|
|
6
|
+
export declare function useFilters(): {
|
|
7
|
+
filters: FilterNode[];
|
|
8
|
+
activeCount: number;
|
|
9
|
+
setFilters: (newFilters: FilterNode[]) => void;
|
|
10
|
+
clearFilters: () => void;
|
|
11
|
+
};
|