opacacms 0.3.16 → 0.3.18
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/admin/{stores → features/collections}/admin-queries.d.ts +1 -1
- package/dist/admin/{ui/views → features/collections}/collection-list-view.d.ts +1 -1
- package/dist/admin/{ui/views → features/collections}/document-edit-view.d.ts +2 -1
- package/dist/admin/{ui/views → features/collections}/global-edit-view.d.ts +1 -1
- package/dist/admin/{ui/components → features/collections}/versions-sheet.d.ts +3 -3
- package/dist/admin/{ui/views → features/dashboard}/dashboard-view.d.ts +1 -1
- package/dist/admin/{ui/components/media/AssetManagerModal.d.ts → features/media/components/asset-manager-modal.d.ts} +1 -2
- package/dist/admin/features/media/media-registry-view.d.ts +7 -0
- package/dist/admin/{ui/components/PluginSettingsForm.d.ts → features/settings/plugin-settings-form.d.ts} +3 -3
- package/dist/admin/{ui/views → features/settings}/settings-view.d.ts +2 -2
- package/dist/admin/{stores → features/ui-shell}/config.d.ts +1 -1
- package/dist/admin/{stores → features/ui-shell}/ui.d.ts +1 -1
- package/dist/admin/index.d.ts +8 -8
- package/dist/admin/index.js +4 -4
- package/dist/admin/ui/{components/ui → core}/blocks.d.ts +1 -1
- package/dist/admin/ui/core/breadcrumbs.d.ts +21 -0
- package/dist/admin/ui/{components/ui → core}/button.d.ts +4 -4
- package/dist/admin/ui/{components/ui → core}/collapsible.d.ts +2 -2
- package/dist/admin/ui/core/context-menu.d.ts +29 -0
- package/dist/admin/ui/core/dialog.d.ts +20 -0
- package/dist/admin/ui/{components/ui → core}/group.d.ts +2 -2
- package/dist/admin/ui/core/index.d.ts +17 -0
- package/dist/admin/ui/{components/ui → core}/input.d.ts +2 -2
- package/dist/admin/ui/{components/ui → core}/join.d.ts +1 -1
- package/dist/admin/ui/core/label.d.ts +4 -0
- package/dist/admin/ui/core/popover.d.ts +10 -0
- package/dist/admin/ui/{components/ui → core}/radio-group.d.ts +2 -2
- package/dist/admin/ui/{components/ui → core}/relationship.d.ts +1 -1
- package/dist/admin/ui/{components/ui → core}/scroll-area.d.ts +1 -1
- package/dist/admin/ui/core/select.d.ts +15 -0
- package/dist/admin/ui/{components/ui → core}/sheet.d.ts +6 -6
- package/dist/admin/ui/core/sidebar.d.ts +69 -0
- package/dist/admin/ui/core/skeleton.d.ts +2 -0
- package/dist/admin/ui/core/switch.d.ts +6 -0
- package/dist/admin/ui/core/table.d.ts +10 -0
- package/dist/admin/ui/core/tabs.d.ts +11 -0
- package/dist/admin/ui/hooks/use-mobile.d.ts +1 -0
- package/dist/admin/ui/{admin-client.d.ts → layout/admin-client.d.ts} +1 -1
- package/dist/admin/ui/{admin-layout.d.ts → layout/admin-layout.d.ts} +2 -2
- package/dist/admin/ui/{components → shared}/column-visibility-toggle.d.ts +1 -1
- package/dist/admin/ui/{components → shared}/detail-sheet.d.ts +2 -2
- package/dist/admin/ui/{components/fields/ArrayField.d.ts → shared/fields/array-field.d.ts} +1 -1
- package/dist/admin/ui/shared/fields/blocks-field.d.ts +25 -0
- package/dist/admin/ui/{components/fields/BooleanField.d.ts → shared/fields/boolean-field.d.ts} +1 -1
- package/dist/admin/ui/{components/fields/CollapsibleField.d.ts → shared/fields/collapsible-field.d.ts} +1 -1
- package/dist/admin/ui/{components/fields/FileField.d.ts → shared/fields/file-field.d.ts} +13 -3
- package/dist/admin/ui/{components/fields/GroupField.d.ts → shared/fields/group-field.d.ts} +1 -1
- package/dist/admin/ui/shared/fields/index.d.ts +28 -0
- package/dist/admin/ui/{components/fields/JoinField.d.ts → shared/fields/join-field.d.ts} +1 -1
- package/dist/admin/ui/{components/fields/RelationshipField.d.ts → shared/fields/relationship-field.d.ts} +1 -1
- package/dist/admin/ui/{components → shared}/fields/richtext-editor/index.d.ts +2 -2
- package/dist/admin/ui/{components/fields/richtext-editor/nodes/ImageNode.d.ts → shared/fields/richtext-editor/nodes/image-node.d.ts} +3 -3
- package/dist/admin/ui/{components/fields/TabsField.d.ts → shared/fields/tabs-field.d.ts} +1 -1
- package/dist/admin/ui/{components/fields/VirtualField.d.ts → shared/fields/virtual-field.d.ts} +1 -1
- package/dist/admin/ui/{components → shared}/toast.d.ts +1 -1
- package/dist/admin/webcomponent.js +34 -34
- package/dist/admin.css +1 -1
- package/dist/{chunk-5y0mkt7x.js → chunk-2abqb0h6.js} +2 -2
- package/dist/{chunk-m83ybzf8.js → chunk-hrxq1x98.js} +1 -1
- package/dist/{chunk-nch158fe.js → chunk-y3ehzvp4.js} +1 -1
- package/dist/{chunk-vmz9ncf1.js → chunk-yw9w63kr.js} +3 -3
- package/dist/cli/commands/init.d.ts +1 -0
- package/dist/cli/core/seeding/auto-seed.d.ts +1 -1
- package/dist/cli/index.js +28 -3
- package/dist/config.d.ts +2 -6
- package/dist/db/adapter.d.ts +1 -1
- package/dist/db/better-sqlite.d.ts +1 -1
- package/dist/db/better-sqlite.js +587 -9
- package/dist/db/bun-sqlite.js +590 -9
- package/dist/db/d1.d.ts +1 -1
- package/dist/db/d1.js +605 -9
- package/dist/db/index.d.ts +0 -5
- package/dist/db/index.js +0 -35
- package/dist/db/kysely/plugins/draft-swapper.d.ts +2 -2
- package/dist/db/kysely/plugins/i18n-fallback.d.ts +2 -2
- package/dist/db/kysely/plugins/json-flattener.d.ts +2 -2
- package/dist/db/kysely/plugins/virtual-field-resolver.d.ts +2 -2
- package/dist/db/kysely/schema-builder.d.ts +1 -1
- package/dist/db/kysely/snapshot/snapshot-manager.d.ts +1 -1
- package/dist/db/postgres.js +613 -9
- package/dist/db/sqlite.d.ts +1 -1
- package/dist/db/sqlite.js +602 -9
- package/dist/runtimes/bun.js +1 -1
- package/dist/runtimes/cloudflare-workers.js +1 -1
- package/dist/runtimes/next.js +1 -1
- package/dist/runtimes/node.js +1 -1
- package/dist/server.js +4 -4
- package/dist/types.d.ts +3 -3
- package/package.json +25 -7
- package/dist/admin/ui/components/Table.d.ts +0 -10
- package/dist/admin/ui/components/fields/BlocksField.d.ts +0 -17
- package/dist/admin/ui/components/fields/index.d.ts +0 -28
- package/dist/admin/ui/components/ui/breadcrumbs.d.ts +0 -7
- package/dist/admin/ui/components/ui/dialog.d.ts +0 -27
- package/dist/admin/ui/components/ui/index.d.ts +0 -17
- package/dist/admin/ui/components/ui/label.d.ts +0 -3
- package/dist/admin/ui/components/ui/select.d.ts +0 -37
- package/dist/admin/ui/components/ui/tabs.d.ts +0 -17
- package/dist/admin/ui/views/media-registry-view.d.ts +0 -7
- package/dist/chunk-5b9eqr34.js +0 -608
- package/dist/chunk-dz5bh1bd.js +0 -586
- package/dist/chunk-nz6xhtja.js +0 -601
- package/dist/chunk-qsefknd3.js +0 -593
- package/dist/chunk-tsmhn78f.js +0 -616
- /package/dist/admin/{stores → features/auth}/auth.d.ts +0 -0
- /package/dist/admin/{ui/views → features/auth}/login-view.d.ts +0 -0
- /package/dist/admin/{ui/components → features/collections}/data-detail-view.d.ts +0 -0
- /package/dist/admin/{ui/views → features/init}/init-view.d.ts +0 -0
- /package/dist/admin/{stores → features/media}/media.d.ts +0 -0
- /package/dist/admin/{stores → features/ui-shell}/column-visibility.d.ts +0 -0
- /package/dist/admin/{stores → features/ui-shell}/query.d.ts +0 -0
- /package/dist/admin/ui/{components/ui → core}/accordion.d.ts +0 -0
- /package/dist/admin/ui/{components/ui → core}/alert-dialog.d.ts +0 -0
- /package/dist/admin/ui/{components/ui → core}/separator.d.ts +0 -0
- /package/dist/admin/ui/{components/ui → core}/tooltip.d.ts +0 -0
- /package/dist/admin/ui/{components/ui → core}/utils.d.ts +0 -0
- /package/dist/admin/ui/{components → shared}/custom-alert.d.ts +0 -0
- /package/dist/admin/ui/{components/fields/DateField.d.ts → shared/fields/date-field.d.ts} +0 -0
- /package/dist/admin/ui/{components/fields/FieldLabel.d.ts → shared/fields/field-label.d.ts} +0 -0
- /package/dist/admin/ui/{components/fields/NumberField.d.ts → shared/fields/number-field.d.ts} +0 -0
- /package/dist/admin/ui/{components/fields/RadioField.d.ts → shared/fields/radio-field.d.ts} +0 -0
- /package/dist/admin/ui/{components/fields/richtext-editor/nodes/ImageComponent.d.ts → shared/fields/richtext-editor/nodes/image-component.d.ts} +0 -0
- /package/dist/admin/ui/{components/fields/richtext-editor/plugins/ComponentPickerPlugin.d.ts → shared/fields/richtext-editor/plugins/component-picker-plugin.d.ts} +0 -0
- /package/dist/admin/ui/{components/fields/richtext-editor/plugins/EditableSyncPlugin.d.ts → shared/fields/richtext-editor/plugins/editable-sync-plugin.d.ts} +0 -0
- /package/dist/admin/ui/{components/fields/richtext-editor/plugins/NotionToolbarPlugin.d.ts → shared/fields/richtext-editor/plugins/notion-toolbar-plugin.d.ts} +0 -0
- /package/dist/admin/ui/{components/fields/richtext-editor/plugins/SimpleToolbarPlugin.d.ts → shared/fields/richtext-editor/plugins/simple-toolbar-plugin.d.ts} +0 -0
- /package/dist/admin/ui/{components/fields/richtext-editor/plugins/ValueSyncPlugin.d.ts → shared/fields/richtext-editor/plugins/value-sync-plugin.d.ts} +0 -0
- /package/dist/admin/ui/{components/fields/RowField.d.ts → shared/fields/row-field.d.ts} +0 -0
- /package/dist/admin/ui/{components/fields/SelectField.d.ts → shared/fields/select-field.d.ts} +0 -0
- /package/dist/admin/ui/{components/fields/TextAreaField.d.ts → shared/fields/text-area-field.d.ts} +0 -0
- /package/dist/admin/ui/{components/fields/TextField.d.ts → shared/fields/text-field.d.ts} +0 -0
- /package/dist/admin/ui/{components → shared}/fields/utils.d.ts +0 -0
- /package/dist/admin/ui/{components → shared}/link.d.ts +0 -0
- /package/dist/admin/ui/{components → shared}/plugin-iframe.d.ts +0 -0
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import type { SerializableCollection } from "
|
|
1
|
+
import type { SerializableCollection } from "@opaca/types";
|
|
2
|
+
import "@opaca/admin/ui/styles/document-edit.scss";
|
|
2
3
|
export interface DocumentEditViewProps {
|
|
3
4
|
collection: SerializableCollection;
|
|
4
5
|
id: string;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import type { SerializableCollection } from
|
|
2
|
-
import
|
|
1
|
+
import type { SerializableCollection } from '@opaca/types';
|
|
2
|
+
import '@opaca/admin/ui/styles/versions.scss';
|
|
3
3
|
interface VersionsSheetProps {
|
|
4
4
|
collection: SerializableCollection;
|
|
5
5
|
parentId: string;
|
|
6
6
|
onRestore: (data: Record<string, any>) => void;
|
|
7
7
|
children: React.ReactNode;
|
|
8
8
|
}
|
|
9
|
-
export declare function VersionsSheet({ collection, parentId, onRestore, children }: VersionsSheetProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export declare function VersionsSheet({ collection, parentId, onRestore, children, }: VersionsSheetProps): import("react/jsx-runtime").JSX.Element;
|
|
10
10
|
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { SerializableCollection, SerializableConfig } from '@opaca/types';
|
|
2
|
+
import '@opaca/admin/ui/styles/media-registry.scss';
|
|
3
|
+
export interface MediaRegistryViewProps {
|
|
4
|
+
collection: SerializableCollection;
|
|
5
|
+
config: SerializableConfig;
|
|
6
|
+
}
|
|
7
|
+
export declare function MediaRegistryView({ config }: MediaRegistryViewProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -2,10 +2,10 @@ interface PluginSettingsFormProps {
|
|
|
2
2
|
plugin: {
|
|
3
3
|
name: string;
|
|
4
4
|
label?: string;
|
|
5
|
-
configSchema?:
|
|
5
|
+
configSchema?: unknown[];
|
|
6
6
|
};
|
|
7
7
|
onBack: () => void;
|
|
8
|
-
notify?: (message: string, type?:
|
|
8
|
+
notify?: (message: string, type?: 'success' | 'error') => void;
|
|
9
9
|
}
|
|
10
|
-
export declare function PluginSettingsForm({ plugin, onBack, notify }: PluginSettingsFormProps): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export declare function PluginSettingsForm({ plugin, onBack, notify, }: PluginSettingsFormProps): import("react/jsx-runtime").JSX.Element;
|
|
11
11
|
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { ToastType } from
|
|
2
|
-
import type { SerializableConfig } from
|
|
1
|
+
import type { ToastType } from '@opaca/admin/features/ui-shell/ui';
|
|
2
|
+
import type { SerializableConfig } from '@opaca/types';
|
|
3
3
|
export interface SettingsViewProps {
|
|
4
4
|
notify?: (message: string, type?: ToastType) => void;
|
|
5
5
|
config: SerializableConfig;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { SerializableConfig } from "
|
|
1
|
+
import type { SerializableConfig } from "../../../types";
|
|
2
2
|
export declare const $config: import("nanostores").PreinitializedWritableAtom<SerializableConfig | null> & object;
|
|
3
3
|
export declare const $needsInit: import("nanostores").PreinitializedWritableAtom<boolean> & object;
|
|
4
4
|
export declare const $isFetchingConfig: import("nanostores").PreinitializedWritableAtom<boolean> & object;
|
package/dist/admin/index.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
export { type CustomFieldAdapter, type CustomFieldProps, defineCustomField, } from "./custom-field";
|
|
2
2
|
export { defineReactField } from "./react";
|
|
3
3
|
export * from "./router";
|
|
4
|
-
export * from "./
|
|
5
|
-
export * from "./
|
|
6
|
-
export * from "./
|
|
7
|
-
export { AdminClient } from "./ui/admin-client";
|
|
8
|
-
export { AdminLayout } from "./ui/admin-layout";
|
|
9
|
-
export { Link } from "./ui/
|
|
10
|
-
export { Toast, ToastContainer } from "./ui/
|
|
11
|
-
export { Breadcrumbs } from "./ui/
|
|
4
|
+
export * from "./features/ui-shell/config";
|
|
5
|
+
export * from "./features/ui-shell/query";
|
|
6
|
+
export * from "./features/ui-shell/ui";
|
|
7
|
+
export { AdminClient } from "./ui/layout/admin-client";
|
|
8
|
+
export { AdminLayout } from "./ui/layout/admin-layout";
|
|
9
|
+
export { Link } from "./ui/shared/link";
|
|
10
|
+
export { Toast, ToastContainer } from "./ui/shared/toast";
|
|
11
|
+
export { Breadcrumbs } from "./ui/core/breadcrumbs";
|
|
12
12
|
export { defineVueField } from "./vue";
|
package/dist/admin/index.js
CHANGED
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
openSheet,
|
|
13
13
|
registerSidebarItem,
|
|
14
14
|
toggleSidebar
|
|
15
|
-
} from "../chunk-
|
|
15
|
+
} from "../chunk-hrxq1x98.js";
|
|
16
16
|
import"../chunk-8sqjbsgt.js";
|
|
17
17
|
// src/admin/router.ts
|
|
18
18
|
import { createRouter } from "@nanostores/router";
|
|
@@ -24,7 +24,7 @@ var $router = createRouter({
|
|
|
24
24
|
settings: "/admin/settings",
|
|
25
25
|
plugin: "/admin/:path"
|
|
26
26
|
});
|
|
27
|
-
// src/admin/
|
|
27
|
+
// src/admin/features/ui-shell/config.ts
|
|
28
28
|
import { atom } from "nanostores";
|
|
29
29
|
var $config = atom(null);
|
|
30
30
|
var $needsInit = atom(false);
|
|
@@ -36,7 +36,7 @@ function setConfig(config) {
|
|
|
36
36
|
function setNeedsInit(needs) {
|
|
37
37
|
$needsInit.set(needs);
|
|
38
38
|
}
|
|
39
|
-
// src/admin/
|
|
39
|
+
// src/admin/features/ui-shell/query.ts
|
|
40
40
|
import { nanoquery } from "@nanostores/query";
|
|
41
41
|
|
|
42
42
|
// src/admin/api-client.ts
|
|
@@ -57,7 +57,7 @@ var api = new Proxy({}, {
|
|
|
57
57
|
}
|
|
58
58
|
});
|
|
59
59
|
|
|
60
|
-
// src/admin/
|
|
60
|
+
// src/admin/features/ui-shell/query.ts
|
|
61
61
|
var [
|
|
62
62
|
createFetcherStore,
|
|
63
63
|
createMutatorStore,
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
declare const Breadcrumb: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & React.RefAttributes<HTMLElement>>;
|
|
3
|
+
declare const BreadcrumbList: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.OlHTMLAttributes<HTMLOListElement>, HTMLOListElement>, "ref"> & React.RefAttributes<HTMLOListElement>>;
|
|
4
|
+
declare const BreadcrumbItem: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & React.RefAttributes<HTMLLIElement>>;
|
|
5
|
+
declare const BreadcrumbLink: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "ref"> & {
|
|
6
|
+
asChild?: boolean;
|
|
7
|
+
} & React.RefAttributes<HTMLAnchorElement>>;
|
|
8
|
+
declare const BreadcrumbPage: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
|
|
9
|
+
declare const BreadcrumbSeparator: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & React.RefAttributes<HTMLLIElement>>;
|
|
10
|
+
declare const BreadcrumbEllipsis: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
|
|
11
|
+
/**
|
|
12
|
+
* Compatibility component for items-based usage.
|
|
13
|
+
*/
|
|
14
|
+
export interface BreadcrumbItemData {
|
|
15
|
+
label: string;
|
|
16
|
+
href?: string;
|
|
17
|
+
}
|
|
18
|
+
declare function Breadcrumbs({ items }: {
|
|
19
|
+
items: BreadcrumbItemData[];
|
|
20
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
21
|
+
export { Breadcrumb, BreadcrumbList, BreadcrumbItem, BreadcrumbLink, BreadcrumbPage, BreadcrumbSeparator, BreadcrumbEllipsis, Breadcrumbs, };
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { type VariantProps } from
|
|
2
|
-
import type * as React from
|
|
3
|
-
import
|
|
1
|
+
import { type VariantProps } from 'class-variance-authority';
|
|
2
|
+
import type * as React from 'react';
|
|
3
|
+
import '../styles/button.scss';
|
|
4
4
|
declare const buttonVariants: (props?: ({
|
|
5
5
|
variant?: "link" | "default" | "destructive" | "outline" | "secondary" | "ghost" | null | undefined;
|
|
6
6
|
size?: "default" | "icon" | "sm" | "lg" | "icon-sm" | "icon-xs" | "icon-lg" | "xs" | null | undefined;
|
|
7
7
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
8
|
-
declare function Button({ className, variant, size, asChild, ...props }: React.ComponentProps<
|
|
8
|
+
declare function Button({ className, variant, size, asChild, ...props }: React.ComponentProps<'button'> & VariantProps<typeof buttonVariants> & {
|
|
9
9
|
asChild?: boolean;
|
|
10
10
|
}): import("react/jsx-runtime").JSX.Element;
|
|
11
11
|
export { Button, buttonVariants };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as React from
|
|
2
|
-
import
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import '../styles/collapsible.scss';
|
|
3
3
|
export interface CollapsibleProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
4
4
|
open?: boolean;
|
|
5
5
|
defaultOpen?: boolean;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { ContextMenu as ContextMenuPrimitive } from 'radix-ui';
|
|
3
|
+
declare function ContextMenu({ ...props }: React.ComponentProps<typeof ContextMenuPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
declare function ContextMenuTrigger({ className, ...props }: React.ComponentProps<typeof ContextMenuPrimitive.Trigger>): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
declare function ContextMenuGroup({ ...props }: React.ComponentProps<typeof ContextMenuPrimitive.Group>): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
declare function ContextMenuPortal({ ...props }: React.ComponentProps<typeof ContextMenuPrimitive.Portal>): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
declare function ContextMenuSub({ ...props }: React.ComponentProps<typeof ContextMenuPrimitive.Sub>): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
declare function ContextMenuRadioGroup({ ...props }: React.ComponentProps<typeof ContextMenuPrimitive.RadioGroup>): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare function ContextMenuContent({ className, ...props }: React.ComponentProps<typeof ContextMenuPrimitive.Content>): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare function ContextMenuItem({ className, inset, variant, ...props }: React.ComponentProps<typeof ContextMenuPrimitive.Item> & {
|
|
11
|
+
inset?: boolean;
|
|
12
|
+
variant?: 'default' | 'destructive';
|
|
13
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
declare function ContextMenuSubTrigger({ className, inset, children, ...props }: React.ComponentProps<typeof ContextMenuPrimitive.SubTrigger> & {
|
|
15
|
+
inset?: boolean;
|
|
16
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
declare function ContextMenuSubContent({ className, ...props }: React.ComponentProps<typeof ContextMenuPrimitive.SubContent>): import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
declare function ContextMenuCheckboxItem({ className, children, checked, inset, ...props }: React.ComponentProps<typeof ContextMenuPrimitive.CheckboxItem> & {
|
|
19
|
+
inset?: boolean;
|
|
20
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
21
|
+
declare function ContextMenuRadioItem({ className, children, inset, ...props }: React.ComponentProps<typeof ContextMenuPrimitive.RadioItem> & {
|
|
22
|
+
inset?: boolean;
|
|
23
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
declare function ContextMenuLabel({ className, inset, ...props }: React.ComponentProps<typeof ContextMenuPrimitive.Label> & {
|
|
25
|
+
inset?: boolean;
|
|
26
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
27
|
+
declare function ContextMenuSeparator({ className, ...props }: React.ComponentProps<typeof ContextMenuPrimitive.Separator>): import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
declare function ContextMenuShortcut({ className, ...props }: React.ComponentProps<'span'>): import("react/jsx-runtime").JSX.Element;
|
|
29
|
+
export { ContextMenu, ContextMenuTrigger, ContextMenuContent, ContextMenuItem, ContextMenuCheckboxItem, ContextMenuRadioItem, ContextMenuLabel, ContextMenuSeparator, ContextMenuShortcut, ContextMenuGroup, ContextMenuPortal, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuRadioGroup, };
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { Dialog as DialogPrimitive } from 'radix-ui';
|
|
3
|
+
import '../styles/dialog.scss';
|
|
4
|
+
declare const Dialog: React.FC<DialogPrimitive.DialogProps>;
|
|
5
|
+
declare const DialogTrigger: React.ForwardRefExoticComponent<DialogPrimitive.DialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
6
|
+
declare const DialogPortal: React.FC<DialogPrimitive.DialogPortalProps>;
|
|
7
|
+
declare const DialogClose: React.ForwardRefExoticComponent<DialogPrimitive.DialogCloseProps & React.RefAttributes<HTMLButtonElement>>;
|
|
8
|
+
declare const DialogOverlay: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogOverlayProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
9
|
+
declare const DialogContent: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
10
|
+
declare const DialogHeader: {
|
|
11
|
+
({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
displayName: string;
|
|
13
|
+
};
|
|
14
|
+
declare const DialogFooter: {
|
|
15
|
+
({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
displayName: string;
|
|
17
|
+
};
|
|
18
|
+
declare const DialogTitle: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogTitleProps & React.RefAttributes<HTMLHeadingElement>, "ref"> & React.RefAttributes<HTMLHeadingElement>>;
|
|
19
|
+
declare const DialogDescription: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogDescriptionProps & React.RefAttributes<HTMLParagraphElement>, "ref"> & React.RefAttributes<HTMLParagraphElement>>;
|
|
20
|
+
export { Dialog, DialogPortal, DialogOverlay, DialogClose, DialogTrigger, DialogContent, DialogHeader, DialogFooter, DialogTitle, DialogDescription, };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export * from "./accordion";
|
|
2
|
+
export * from "./blocks";
|
|
3
|
+
export * from "./button";
|
|
4
|
+
export * from "./collapsible";
|
|
5
|
+
export * from "./dialog";
|
|
6
|
+
export * from "./group";
|
|
7
|
+
export * from "./input";
|
|
8
|
+
export * from "./join";
|
|
9
|
+
export * from "./label";
|
|
10
|
+
export * from "./radio-group";
|
|
11
|
+
export * from "./relationship";
|
|
12
|
+
export * from "./scroll-area";
|
|
13
|
+
export * from "./select";
|
|
14
|
+
export * from "./separator";
|
|
15
|
+
export * from "./sheet";
|
|
16
|
+
export * from "./tabs";
|
|
17
|
+
export * from "./utils";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as React from
|
|
2
|
-
import
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import '../styles/input.scss';
|
|
3
3
|
export interface InputProps extends React.InputHTMLAttributes<HTMLInputElement> {
|
|
4
4
|
}
|
|
5
5
|
export declare const Input: React.ForwardRefExoticComponent<InputProps & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { Popover as PopoverPrimitive } from 'radix-ui';
|
|
3
|
+
declare function Popover({ ...props }: React.ComponentProps<typeof PopoverPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
declare function PopoverTrigger({ ...props }: React.ComponentProps<typeof PopoverPrimitive.Trigger>): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
declare function PopoverContent({ className, align, sideOffset, ...props }: React.ComponentProps<typeof PopoverPrimitive.Content>): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
declare function PopoverAnchor({ ...props }: React.ComponentProps<typeof PopoverPrimitive.Anchor>): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
declare function PopoverHeader({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
declare function PopoverTitle({ className, ...props }: React.ComponentProps<'h2'>): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare function PopoverDescription({ className, ...props }: React.ComponentProps<'p'>): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export { Popover, PopoverAnchor, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as React from
|
|
2
|
-
import
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import '../styles/radio-group.scss';
|
|
3
3
|
export interface RadioGroupProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
4
4
|
value?: string;
|
|
5
5
|
onValueChange?: (value: string) => void;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { Select as SelectPrimitive } from 'radix-ui';
|
|
3
|
+
declare function Select({ ...props }: React.ComponentProps<typeof SelectPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
declare function SelectGroup({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.Group>): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
declare function SelectValue({ ...props }: React.ComponentProps<typeof SelectPrimitive.Value>): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
declare function SelectTrigger({ className, size, children, ...props }: React.ComponentProps<typeof SelectPrimitive.Trigger> & {
|
|
7
|
+
size?: 'sm' | 'default';
|
|
8
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare function SelectContent({ className, children, position, align, sideOffset, ...props }: React.ComponentProps<typeof SelectPrimitive.Content>): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare function SelectLabel({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.Label>): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
declare function SelectItem({ className, children, ...props }: React.ComponentProps<typeof SelectPrimitive.Item>): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
declare function SelectSeparator({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.Separator>): import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
declare function SelectScrollUpButton({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.ScrollUpButton>): import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
declare function SelectScrollDownButton({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.ScrollDownButton>): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
export { Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, };
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { Dialog as SheetPrimitive } from
|
|
2
|
-
import type * as React from
|
|
3
|
-
import
|
|
1
|
+
import { Dialog as SheetPrimitive } from 'radix-ui';
|
|
2
|
+
import type * as React from 'react';
|
|
3
|
+
import '../styles/sheet.scss';
|
|
4
4
|
declare function Sheet({ ...props }: React.ComponentProps<typeof SheetPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
|
|
5
5
|
declare function SheetTrigger({ ...props }: React.ComponentProps<typeof SheetPrimitive.Trigger>): import("react/jsx-runtime").JSX.Element;
|
|
6
6
|
declare function SheetClose({ ...props }: React.ComponentProps<typeof SheetPrimitive.Close>): import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
declare function SheetContent({ className, children, side, showCloseButton, ...props }: React.ComponentProps<typeof SheetPrimitive.Content> & {
|
|
8
|
-
side?:
|
|
8
|
+
side?: 'top' | 'right' | 'bottom' | 'left';
|
|
9
9
|
showCloseButton?: boolean;
|
|
10
10
|
}): import("react/jsx-runtime").JSX.Element;
|
|
11
|
-
declare function SheetHeader({ className, ...props }: React.ComponentProps<
|
|
12
|
-
declare function SheetFooter({ className, ...props }: React.ComponentProps<
|
|
11
|
+
declare function SheetHeader({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
declare function SheetFooter({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
13
13
|
declare function SheetTitle({ className, ...props }: React.ComponentProps<typeof SheetPrimitive.Title>): import("react/jsx-runtime").JSX.Element;
|
|
14
14
|
declare function SheetDescription({ className, ...props }: React.ComponentProps<typeof SheetPrimitive.Description>): import("react/jsx-runtime").JSX.Element;
|
|
15
15
|
export { Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, };
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { type VariantProps } from 'class-variance-authority';
|
|
3
|
+
import { Button } from '@opaca/admin/ui/core/button';
|
|
4
|
+
import { Input } from '@opaca/admin/ui/core/input';
|
|
5
|
+
import { Separator } from '@opaca/admin/ui/core/separator';
|
|
6
|
+
import { TooltipContent } from '@opaca/admin/ui/core/tooltip';
|
|
7
|
+
type SidebarContextProps = {
|
|
8
|
+
state: 'expanded' | 'collapsed';
|
|
9
|
+
open: boolean;
|
|
10
|
+
setOpen: (open: boolean) => void;
|
|
11
|
+
openMobile: boolean;
|
|
12
|
+
setOpenMobile: (open: boolean) => void;
|
|
13
|
+
isMobile: boolean;
|
|
14
|
+
toggleSidebar: () => void;
|
|
15
|
+
};
|
|
16
|
+
declare function useSidebar(): SidebarContextProps;
|
|
17
|
+
declare function SidebarProvider({ defaultOpen, open: openProp, onOpenChange: setOpenProp, className, style, children, ...props }: React.ComponentProps<'div'> & {
|
|
18
|
+
defaultOpen?: boolean;
|
|
19
|
+
open?: boolean;
|
|
20
|
+
onOpenChange?: (open: boolean) => void;
|
|
21
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
22
|
+
declare function Sidebar({ side, variant, collapsible, className, children, dir, ...props }: React.ComponentProps<'div'> & {
|
|
23
|
+
side?: 'left' | 'right';
|
|
24
|
+
variant?: 'sidebar' | 'floating' | 'inset';
|
|
25
|
+
collapsible?: 'offcanvas' | 'icon' | 'none';
|
|
26
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
27
|
+
declare function SidebarTrigger({ className, onClick, ...props }: React.ComponentProps<typeof Button>): import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
declare function SidebarRail({ className, ...props }: React.ComponentProps<'button'>): import("react/jsx-runtime").JSX.Element;
|
|
29
|
+
declare function SidebarInset({ className, ...props }: React.ComponentProps<'main'>): import("react/jsx-runtime").JSX.Element;
|
|
30
|
+
declare function SidebarInput({ className, ...props }: React.ComponentProps<typeof Input>): import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
declare function SidebarHeader({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
32
|
+
declare function SidebarFooter({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
33
|
+
declare function SidebarSeparator({ className, ...props }: React.ComponentProps<typeof Separator>): import("react/jsx-runtime").JSX.Element;
|
|
34
|
+
declare function SidebarContent({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
35
|
+
declare function SidebarGroup({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
36
|
+
declare function SidebarGroupLabel({ className, asChild, ...props }: React.ComponentProps<'div'> & {
|
|
37
|
+
asChild?: boolean;
|
|
38
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
39
|
+
declare function SidebarGroupAction({ className, asChild, ...props }: React.ComponentProps<'button'> & {
|
|
40
|
+
asChild?: boolean;
|
|
41
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
42
|
+
declare function SidebarGroupContent({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
43
|
+
declare function SidebarMenu({ className, ...props }: React.ComponentProps<'ul'>): import("react/jsx-runtime").JSX.Element;
|
|
44
|
+
declare function SidebarMenuItem({ className, ...props }: React.ComponentProps<'li'>): import("react/jsx-runtime").JSX.Element;
|
|
45
|
+
declare const sidebarMenuButtonVariants: (props?: ({
|
|
46
|
+
variant?: "default" | "outline" | null | undefined;
|
|
47
|
+
size?: "default" | "sm" | "lg" | null | undefined;
|
|
48
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
49
|
+
declare function SidebarMenuButton({ asChild, isActive, variant, size, tooltip, className, ...props }: React.ComponentProps<'button'> & {
|
|
50
|
+
asChild?: boolean;
|
|
51
|
+
isActive?: boolean;
|
|
52
|
+
tooltip?: string | React.ComponentProps<typeof TooltipContent>;
|
|
53
|
+
} & VariantProps<typeof sidebarMenuButtonVariants>): import("react/jsx-runtime").JSX.Element;
|
|
54
|
+
declare function SidebarMenuAction({ className, asChild, showOnHover, ...props }: React.ComponentProps<'button'> & {
|
|
55
|
+
asChild?: boolean;
|
|
56
|
+
showOnHover?: boolean;
|
|
57
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
58
|
+
declare function SidebarMenuBadge({ className, ...props }: React.ComponentProps<'div'>): import("react/jsx-runtime").JSX.Element;
|
|
59
|
+
declare function SidebarMenuSkeleton({ className, showIcon, ...props }: React.ComponentProps<'div'> & {
|
|
60
|
+
showIcon?: boolean;
|
|
61
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
62
|
+
declare function SidebarMenuSub({ className, ...props }: React.ComponentProps<'ul'>): import("react/jsx-runtime").JSX.Element;
|
|
63
|
+
declare function SidebarMenuSubItem({ className, ...props }: React.ComponentProps<'li'>): import("react/jsx-runtime").JSX.Element;
|
|
64
|
+
declare function SidebarMenuSubButton({ asChild, size, isActive, className, ...props }: React.ComponentProps<'a'> & {
|
|
65
|
+
asChild?: boolean;
|
|
66
|
+
size?: 'sm' | 'md';
|
|
67
|
+
isActive?: boolean;
|
|
68
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
69
|
+
export { Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, useSidebar, };
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { Switch as SwitchPrimitive } from 'radix-ui';
|
|
3
|
+
declare function Switch({ className, size, ...props }: React.ComponentProps<typeof SwitchPrimitive.Root> & {
|
|
4
|
+
size?: 'sm' | 'default';
|
|
5
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
export { Switch };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
declare function Table({ className, ...props }: React.ComponentProps<'table'>): import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
declare function TableHeader({ className, ...props }: React.ComponentProps<'thead'>): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
declare function TableBody({ className, ...props }: React.ComponentProps<'tbody'>): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
declare function TableFooter({ className, ...props }: React.ComponentProps<'tfoot'>): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
declare function TableRow({ className, ...props }: React.ComponentProps<'tr'>): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
declare function TableHead({ className, ...props }: React.ComponentProps<'th'>): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
declare function TableCell({ className, ...props }: React.ComponentProps<'td'>): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare function TableCaption({ className, ...props }: React.ComponentProps<'caption'>): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption, };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { type VariantProps } from 'class-variance-authority';
|
|
3
|
+
import { Tabs as TabsPrimitive } from 'radix-ui';
|
|
4
|
+
declare function Tabs({ className, orientation, ...props }: React.ComponentProps<typeof TabsPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
declare const tabsListVariants: (props?: ({
|
|
6
|
+
variant?: "default" | "line" | null | undefined;
|
|
7
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
8
|
+
declare function TabsList({ className, variant, ...props }: React.ComponentProps<typeof TabsPrimitive.List> & VariantProps<typeof tabsListVariants>): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare function TabsTrigger({ className, ...props }: React.ComponentProps<typeof TabsPrimitive.Trigger>): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare function TabsContent({ className, ...props }: React.ComponentProps<typeof TabsPrimitive.Content>): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export { Tabs, TabsList, TabsTrigger, TabsContent, tabsListVariants };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function useIsMobile(): boolean;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type React from 'react';
|
|
2
|
-
import
|
|
3
|
-
import '
|
|
2
|
+
import '../styles/index.scss';
|
|
3
|
+
import { SerializableConfig } from '@opaca/types';
|
|
4
4
|
export interface AdminLayoutProps {
|
|
5
5
|
children: React.ReactNode;
|
|
6
6
|
config: SerializableConfig;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
interface BlockFieldDef {
|
|
3
|
+
name?: string;
|
|
4
|
+
type?: string;
|
|
5
|
+
label?: string;
|
|
6
|
+
defaultValue?: unknown;
|
|
7
|
+
hasMany?: boolean;
|
|
8
|
+
[key: string]: unknown;
|
|
9
|
+
}
|
|
10
|
+
interface BlocksFieldProps {
|
|
11
|
+
name: string;
|
|
12
|
+
label?: string;
|
|
13
|
+
blocks: Array<{
|
|
14
|
+
slug: string;
|
|
15
|
+
fields: BlockFieldDef[];
|
|
16
|
+
label?: string;
|
|
17
|
+
}>;
|
|
18
|
+
value: Record<string, unknown>[];
|
|
19
|
+
onChange: (val: Record<string, unknown>[]) => void;
|
|
20
|
+
disabled?: boolean;
|
|
21
|
+
readOnly?: boolean;
|
|
22
|
+
renderField: (field: BlockFieldDef, value: unknown, onChange: (val: unknown) => void) => React.ReactNode;
|
|
23
|
+
}
|
|
24
|
+
export declare const BlocksField: React.FC<BlocksFieldProps>;
|
|
25
|
+
export {};
|
package/dist/admin/ui/{components/fields/BooleanField.d.ts → shared/fields/boolean-field.d.ts}
RENAMED
|
@@ -8,7 +8,7 @@ interface BooleanFieldProps {
|
|
|
8
8
|
disabled?: boolean;
|
|
9
9
|
readOnly?: boolean;
|
|
10
10
|
error?: string;
|
|
11
|
-
renderType?:
|
|
11
|
+
renderType?: 'switch' | 'toggle' | 'checkbox';
|
|
12
12
|
}
|
|
13
13
|
export declare const BooleanField: React.FC<BooleanFieldProps>;
|
|
14
14
|
export {};
|