@rebasepro/admin 0.6.0 → 0.6.1

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.
Files changed (33) hide show
  1. package/README.md +7 -3
  2. package/dist/{CollectionEditorDialog-jA-PLh6N.js → CollectionEditorDialog-HNXGxXdO.js} +3 -3
  3. package/dist/{CollectionEditorDialog-jA-PLh6N.js.map → CollectionEditorDialog-HNXGxXdO.js.map} +1 -1
  4. package/dist/{CollectionsStudioView-UKouBPOm.js → CollectionsStudioView-B1mN33GB.js} +4 -4
  5. package/dist/{CollectionsStudioView-UKouBPOm.js.map → CollectionsStudioView-B1mN33GB.js.map} +1 -1
  6. package/dist/{PropertyEditView-DEUddmg_.js → PropertyEditView-C2wp8kQ9.js} +2 -2
  7. package/dist/{PropertyEditView-DEUddmg_.js.map → PropertyEditView-C2wp8kQ9.js.map} +1 -1
  8. package/dist/collection_editor_ui.js +3 -3
  9. package/dist/editor/editor.d.ts +10 -4
  10. package/dist/editor.js +6 -4
  11. package/dist/editor.js.map +1 -1
  12. package/dist/form/field_bindings/MarkdownEditorFieldBinding.d.ts +2 -2
  13. package/dist/{history-BL49TIDb.js → history-BO6VT85a.js} +2 -2
  14. package/dist/{history-BL49TIDb.js.map → history-BO6VT85a.js.map} +1 -1
  15. package/dist/index.d.ts +1 -1
  16. package/dist/index.js +1 -1
  17. package/dist/{src-BJ8fkM8y.js → src-BYniefVu.js} +56 -55
  18. package/dist/src-BYniefVu.js.map +1 -0
  19. package/package.json +8 -8
  20. package/src/collection_editor/ui/AddKanbanColumnAction.tsx +2 -0
  21. package/src/components/ArrayContainer.tsx +5 -5
  22. package/src/components/DrawerNavigationItem.tsx +4 -4
  23. package/src/components/EntityCollectionView/EntityCollectionBoardView.tsx +2 -0
  24. package/src/components/HomePage/NavigationCard.tsx +8 -14
  25. package/src/components/HomePage/NavigationGroup.tsx +1 -1
  26. package/src/components/HomePage/SmallNavigationCard.tsx +1 -5
  27. package/src/components/SelectableTable/filters/StringNumberFilterField.tsx +28 -21
  28. package/src/components/common/default_entity_actions.tsx +10 -2
  29. package/src/editor/editor.tsx +14 -8
  30. package/src/form/field_bindings/MarkdownEditorFieldBinding.tsx +4 -4
  31. package/src/form/field_bindings/StorageUploadFieldBinding.tsx +1 -1
  32. package/src/index.ts +2 -2
  33. package/dist/src-BJ8fkM8y.js.map +0 -1
@@ -1,13 +1,13 @@
1
1
  import React from "react";
2
2
  import type { FieldProps } from "../../types/fields";
3
3
  import type { StringProperty } from "@rebasepro/types";
4
- import type { RebaseEditorProps } from "../../editor";
4
+ import type { RichTextEditorProps } from "../../editor";
5
5
  interface MarkdownEditorFieldProps {
6
6
  highlight?: {
7
7
  from: number;
8
8
  to: number;
9
9
  };
10
- editorProps?: Partial<RebaseEditorProps>;
10
+ editorProps?: Partial<RichTextEditorProps>;
11
11
  }
12
12
  export declare function MarkdownEditorFieldBinding({ property, propertyKey, value, setValue, includeDescription, showError, error, minimalistView, disabled: disabledProp, isSubmitting, context, customProps }: FieldProps<StringProperty, MarkdownEditorFieldProps>): React.JSX.Element;
13
13
  export {};
@@ -1,4 +1,4 @@
1
- import { T as PropertyPreview, bn as useEntityHistory, ir as getPropertyInPath } from "./src-BJ8fkM8y.js";
1
+ import { T as PropertyPreview, bn as useEntityHistory, ir as getPropertyInPath } from "./src-BYniefVu.js";
2
2
  import { useEffect, useRef, useState } from "react";
3
3
  import { ArrowLeftIcon, Chip, ErrorBoundary, HistoryIcon, IconButton, Label, Tooltip, Typography, cls, defaultBorderMixin, iconSize } from "@rebasepro/ui";
4
4
  import { ConfirmationDialog, useAuthController, useSnackbarController } from "@rebasepro/core";
@@ -308,4 +308,4 @@ function EntityHistoryView({ entity, collection, formContext }) {
308
308
  //#endregion
309
309
  export { EntityHistoryView };
310
310
 
311
- //# sourceMappingURL=history-BL49TIDb.js.map
311
+ //# sourceMappingURL=history-BO6VT85a.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"history-BL49TIDb.js","names":[],"sources":["../src/components/history/UserChip.tsx","../src/components/history/EntityHistoryEntry.tsx","../src/components/history/EntityHistoryView.tsx"],"sourcesContent":["import { User } from \"@rebasepro/types\";\nimport { Chip, Tooltip } from \"@rebasepro/ui\";\n\nexport function UserChip({ user }: { user: User }) {\n return (\n <Tooltip title={user.email ?? user.uid}>\n <Chip size={\"small\"} className={\"flex items-center\"}>\n {user.photoURL && <img\n className={\"rounded-full w-6 h-6 mr-2\"}\n src={user.photoURL} alt={user.displayName ?? \"User picture\"}/>}\n <span>{user.displayName ?? user.email ?? user.uid}</span>\n </Chip>\n </Tooltip>\n );\n}\n","import type { EntityCollection } from \"@rebasepro/types\";\nimport type { Property } from \"@rebasepro/types\";\nimport * as React from \"react\";\n\nimport { ArrowLeftIcon, Chip, cls, defaultBorderMixin, iconSize, Tooltip, Typography } from \"@rebasepro/ui\";\nimport { PreviewSize } from \"../../types/components/PropertyPreviewProps\";\nimport { getPropertyInPath } from \"../../util/property_utils\";\nimport { PropertyPreview } from \"../../preview/PropertyPreview\";\nimport { SkeletonPropertyComponent } from \"../../preview/property_previews/SkeletonPropertyComponent\";\nimport { useAuthController } from \"@rebasepro/core\";\nimport { UserChip } from \"./UserChip\";\nimport { HistoryEntryData } from \"../../hooks\";\nimport { getValueInPath } from \"@rebasepro/utils\";\n\n/**\n * Recursive deep equality for primitives, arrays and plain objects.\n */\nfunction deepEqual(a: unknown, b: unknown): boolean {\n if (a === b) return true;\n if (a == null || b == null) return a === b;\n if (typeof a !== typeof b) return false;\n if (typeof a !== \"object\") return false;\n\n if (Array.isArray(a)) {\n if (!Array.isArray(b) || a.length !== (b as unknown[]).length) return false;\n return a.every((item, i) => deepEqual(item, (b as unknown[])[i]));\n }\n\n if (Array.isArray(b)) return false;\n\n const aObj = a as Record<string, unknown>;\n const bObj = b as Record<string, unknown>;\n const aKeys = Object.keys(aObj);\n const bKeys = Object.keys(bObj);\n if (aKeys.length !== bKeys.length) return false;\n return aKeys.every(key => key in bObj && deepEqual(aObj[key], bObj[key]));\n}\n\nexport type EntityHistoryEntryProps = {\n size: PreviewSize;\n actions?: React.ReactNode;\n collection?: EntityCollection;\n hover?: boolean;\n entry: HistoryEntryData;\n onClick?: (e: React.SyntheticEvent) => void;\n};\n\nfunction PreviousValueView({\n previousValueInPath,\n childProperty,\n propertyKey\n}: {\n previousValueInPath: unknown;\n childProperty: Property;\n propertyKey: string;\n}) {\n if (typeof previousValueInPath === \"string\" || typeof previousValueInPath === \"number\") {\n return <Typography variant={\"caption\"} color={\"secondary\"} className=\"line-through\">\n {previousValueInPath}\n </Typography>;\n } else if (typeof previousValueInPath === \"boolean\") {\n return <Typography variant={\"caption\"} color={\"secondary\"} className=\"line-through\">\n {previousValueInPath ? \"true\" : \"false\"}\n </Typography>;\n } else {\n return <Tooltip\n side={\"left\"}\n title={<div className={\"flex flex-col gap-2\"}>\n <Typography variant={\"caption\"} color={\"secondary\"}>\n Previous value\n </Typography>\n <PropertyPreview\n propertyKey={propertyKey as string}\n value={previousValueInPath as never}\n property={childProperty as Property}\n size={\"small\"}/>\n </div>}>\n <ArrowLeftIcon size={iconSize.smallest} color={\"disabled\"} className={\"mb-1\"}/>\n </Tooltip>\n }\n}\n\n/**\n * Displays a single entity history revision entry.\n * Adapted from the entity_history plugin — now reads from backend API data.\n */\nexport function EntityHistoryEntry({\n actions,\n hover,\n collection,\n size,\n entry\n}: EntityHistoryEntryProps) {\n\n const authController = useAuthController();\n\n const changedFields = entry.changed_fields;\n const previousValues = entry.previous_values;\n const updatedOn = new Date(entry.updated_at);\n const updatedBy = entry.updated_by;\n\n // Resolve user display\n const currentUser = authController.user;\n const userDisplay = updatedBy === currentUser?.uid\n ? currentUser\n : undefined;\n\n return <div className={\"w-full flex flex-col gap-2 mt-4\"}>\n <div className={\"ml-4 flex items-center gap-4\"}>\n <Typography variant={\"body2\"} color={\"secondary\"}>\n {updatedOn.toLocaleString()}\n </Typography>\n <Chip size={\"small\"}>\n {entry.action}\n </Chip>\n {!userDisplay && updatedBy && <Chip size={\"small\"}>{updatedBy}</Chip>}\n {userDisplay && <UserChip user={userDisplay}/>}\n </div>\n <div\n className={cls(\n \"bg-white dark:bg-surface-900\",\n \"min-h-[44px]\",\n \"w-full\",\n \"items-center\",\n hover ? \"hover:bg-surface-accent-50 dark:hover:bg-surface-800\" : \"\",\n size === \"small\" ? \"p-1\" : \"px-2 py-1\",\n \"flex border rounded-lg\",\n defaultBorderMixin\n )}>\n\n {actions}\n\n <div className={\"flex flex-col grow w-full m-1 shrink min-w-0\"}>\n\n {changedFields && collection && changedFields.map((key: string) => {\n const childProperty = getPropertyInPath(collection.properties, key);\n const valueInPath = entry.values ? getValueInPath(entry.values, key) : undefined;\n const previousValueInPath = previousValues ? getValueInPath(previousValues, key) : undefined;\n\n const element = childProperty\n ? <PropertyPreview\n propertyKey={key}\n value={valueInPath as never}\n property={childProperty as Property}\n size={\"small\"}/>\n : <Typography variant={\"body2\"}>\n {typeof valueInPath === \"string\" ? valueInPath : JSON.stringify(valueInPath)}\n </Typography>;\n\n return (\n <div key={\"ref_prev_\" + key}\n className=\"flex w-full my-1 items-center\">\n <Typography variant={\"caption\"}\n color={\"secondary\"}\n className=\"min-w-[140px] md:min-w-[200px] w-1/5 pr-8 overflow-hidden text-ellipsis text-right\">\n {key}\n </Typography>\n <div className=\"w-4/5\">\n {previousValueInPath !== undefined && !deepEqual(previousValueInPath, valueInPath) &&\n <PreviousValueView previousValueInPath={previousValueInPath}\n childProperty={childProperty as Property}\n propertyKey={key}/>\n }\n {element}\n </div>\n </div>\n );\n })}\n\n {(!changedFields || changedFields.length === 0) && (\n <Typography variant={\"caption\"} color={\"secondary\"} className=\"ml-4\">\n {entry.action === \"create\" ? \"Entity created\" :\n entry.action === \"delete\" ? \"Entity deleted\" : \"No field changes recorded\"}\n </Typography>\n )}\n\n </div>\n\n </div>\n </div>;\n}\n","\nimport type { EntityCustomViewParams } from \"@rebasepro/types\";\nimport { useRef, useEffect } from \"react\";\nimport { cls, IconButton, Label, Tooltip, Typography } from \"@rebasepro/ui\";\nimport { ErrorBoundary, HistoryIcon } from \"@rebasepro/ui\";\nimport { EntityHistoryEntry } from \"./EntityHistoryEntry\";\nimport { useSnackbarController, useAuthController } from \"@rebasepro/core\";\nimport { ConfirmationDialog } from \"@rebasepro/core\";\nimport { useState } from \"react\";\nimport { useEntityHistory } from \"../../index\";\n\n/**\n * Entity history tab view. Shows a paginated list of entity revisions\n * fetched from the backend API. Supports infinite scroll and revert.\n */\nexport function EntityHistoryView<M extends Record<string, unknown>>({\n entity,\n collection,\n formContext\n}: EntityCustomViewParams<M>) {\n\n const snackbarController = useSnackbarController();\n const authController = useAuthController();\n const dirty = formContext?.formex.dirty;\n\n const slug = collection.slug;\n const entityId = entity?.id;\n\n const {\n entries,\n isLoading,\n hasMore,\n loadMore,\n revert\n } = useEntityHistory({\n slug,\n entityId,\n enabled: !!entityId,\n pageSize: 10\n });\n\n const [revertHistoryId, setRevertHistoryId] = useState<string | undefined>();\n const [isReverting, setIsReverting] = useState(false);\n\n const containerRef = useRef<HTMLDivElement>(null);\n const loadMoreRef = useRef<HTMLDivElement>(null);\n\n // Intersection observer for infinite scroll\n useEffect(() => {\n const currentContainer = containerRef.current;\n const currentLoadMore = loadMoreRef.current;\n\n if (!currentContainer || !currentLoadMore || !hasMore || isLoading) return;\n\n const observer = new IntersectionObserver(\n (observerEntries) => {\n if (observerEntries[0].isIntersecting && hasMore && !isLoading) {\n loadMore();\n }\n },\n {\n root: currentContainer,\n rootMargin: \"0px 0px 200px 0px\",\n threshold: 0.01\n }\n );\n\n observer.observe(currentLoadMore);\n\n return () => observer.disconnect();\n }, [hasMore, isLoading, entries.length, loadMore]);\n\n if (!entity) {\n return <div className=\"flex items-center justify-center h-full\">\n <Label>HistoryIcon is only available for existing entities</Label>\n </div>;\n }\n\n async function doRevert(historyId: string) {\n setIsReverting(true);\n try {\n const revertedValues = await revert(historyId);\n setRevertHistoryId(undefined);\n\n // Reset the form with the reverted values so the UI updates\n // immediately without requiring a page refresh.\n if (formContext?.formex?.resetForm && revertedValues) {\n formContext.formex.resetForm({\n values: revertedValues as M,\n submitCount: 0,\n touched: {}\n });\n }\n\n snackbarController.open({\n message: \"Reverted to selected version\",\n type: \"info\"\n });\n } catch (error) {\n console.error(\"Error reverting entity:\", error);\n snackbarController.open({\n message: \"Error reverting entity\",\n type: \"error\"\n });\n } finally {\n setIsReverting(false);\n }\n }\n\n const revertEntry = revertHistoryId\n ? entries.find(e => e.id === revertHistoryId)\n : undefined;\n\n return <div\n ref={containerRef}\n className={cls(\"relative flex-1 h-full overflow-auto w-full flex flex-col gap-4 p-8\")}>\n <div className=\"flex flex-col gap-2 max-w-6xl mx-auto w-full\">\n\n <Typography variant={\"h5\"} className={\"mt-24 ml-4\"}>\n HistoryIcon\n </Typography>\n\n {isLoading && entries.length === 0 && (\n <div className=\"flex flex-col gap-4 mt-8 ml-4\">\n {[1, 2, 3].map(i => (\n <div key={i} className=\"flex flex-col gap-2 animate-pulse\">\n <div className=\"h-4 w-48 bg-surface-200 dark:bg-surface-700 rounded\"/>\n <div className=\"h-12 w-full bg-surface-100 dark:bg-surface-900 rounded-lg border border-surface-200 dark:border-surface-700\"/>\n </div>\n ))}\n </div>\n )}\n\n {!isLoading && entries.length === 0 && <>\n <Label className={\"ml-4 mt-8\"}>\n No history available\n </Label>\n <Typography variant={\"caption\"} className={\"ml-4\"}>\n When you save an entity, a new version is created and stored in the history.\n </Typography>\n </>}\n\n {entries.map((entry) => (\n <div key={entry.id} className=\"flex flex-cols gap-2 w-full\">\n <EntityHistoryEntry\n entry={entry}\n collection={collection}\n size={\"medium\"}\n actions={\n <Tooltip title={\"Revert to this version\"}\n className={\"m-2 grow-0 self-start\"}>\n <IconButton\n onClick={() => {\n if (dirty) {\n snackbarController.open({\n message: \"Please save or discard your changes before reverting\",\n type: \"warning\"\n });\n } else {\n setRevertHistoryId(entry.id);\n }\n }}>\n <HistoryIcon/>\n </IconButton>\n </Tooltip>\n }\n />\n </div>\n ))}\n\n {/* Load more sentinel */}\n {entries.length > 0 && (\n <div ref={loadMoreRef} className=\"py-4 text-center\">\n {isLoading && <Label>Loading more...</Label>}\n {!hasMore && entries.length > 10 && <Label>No more history available</Label>}\n </div>\n )}\n </div>\n\n <ErrorBoundary>\n <ConfirmationDialog\n open={Boolean(revertHistoryId)}\n onAccept={() => {\n if (revertHistoryId) doRevert(revertHistoryId);\n }}\n onCancel={() => setRevertHistoryId(undefined)}\n title={<Typography variant={\"subtitle2\"}>Revert data to this version?</Typography>}\n body={revertEntry\n ? <div className=\"p-4\">\n <Typography variant={\"caption\"} color={\"secondary\"}>\n This will save the entity with the values from{\" \"}\n {new Date(revertEntry.updated_at).toLocaleString()}.\n A new history entry will be created for the revert.\n </Typography>\n </div>\n : null\n }\n />\n </ErrorBoundary>\n </div>;\n}\n"],"mappings":";;;;;;;AAGA,SAAgB,SAAS,EAAE,QAAwB;CAC/C,OACI,oBAAC,SAAD;EAAS,OAAO,KAAK,SAAS,KAAK;YAC/B,qBAAC,MAAD;GAAM,MAAM;GAAS,WAAW;aAAhC,CACK,KAAK,YAAY,oBAAC,OAAD;IACd,WAAW;IACX,KAAK,KAAK;IAAU,KAAK,KAAK,eAAe;GAAgB,CAAA,GACjE,oBAAC,QAAD,EAAA,UAAO,KAAK,eAAe,KAAK,SAAS,KAAK,IAAU,CAAA,CACtD;;CACD,CAAA;AAEjB;;;;;;ACGA,SAAS,UAAU,GAAY,GAAqB;CAChD,IAAI,MAAM,GAAG,OAAO;CACpB,IAAI,KAAK,QAAQ,KAAK,MAAM,OAAO,MAAM;CACzC,IAAI,OAAO,MAAM,OAAO,GAAG,OAAO;CAClC,IAAI,OAAO,MAAM,UAAU,OAAO;CAElC,IAAI,MAAM,QAAQ,CAAC,GAAG;EAClB,IAAI,CAAC,MAAM,QAAQ,CAAC,KAAK,EAAE,WAAY,EAAgB,QAAQ,OAAO;EACtE,OAAO,EAAE,OAAO,MAAM,MAAM,UAAU,MAAO,EAAgB,EAAE,C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AD,CAAa,CAAA;OACL,CAAA;MACP,CAAA;KAEhB,CAAA;IACA,GAxBK,MAAM,EAwBX,CACR;IAGA,QAAQ,SAAS,KACd,qBAAC,OAAD;KAAK,KAAK;KAAa,WAAU;eAAjC,CACK,aAAa,oBAAC,OAAD,EAAA,UAAO,kBAAsB,CAAA,GAC1C,CAAC,WAAW,QAAQ,SAAS,MAAM,oBAAC,OAAD,EAAA,UAAO,4BAAgC,CAAA,CAC1E;;GAER;MAEL,oBAAC,eAAD,EAAA,UACI,oBAAC,oBAAD;GACI,MAAM,QAAQ,eAAe;GAC7B,gBAAgB;IACZ,IAAI,iBAAiB,SAAS,eAAe;GACjD;GACA,gBAAgB,mBAAmB,KAAA,CAAS;GAC5C,OAAO,oBAAC,YAAD;IAAY,SAAS;cAAa;GAAwC,CAAA;GACjF,MAAM,cACA,oBAAC,OAAD;IAAK,WAAU;cACb,qBAAC,YAAD;KAAY,SAAS;KAAW,OAAO;eAAvC;MAAoD;MACD;MAC9C,IAAI,KAAK,YAAY,UAAU,EAAE,eAAe;MAAE;KAE3C;;GACX,CAAA,IACH;EAET,CAAA,EACU,CAAA,CACd;;AACT"}
1
+ {"version":3,"file":"history-BO6VT85a.js","names":[],"sources":["../src/components/history/UserChip.tsx","../src/components/history/EntityHistoryEntry.tsx","../src/components/history/EntityHistoryView.tsx"],"sourcesContent":["import { User } from \"@rebasepro/types\";\nimport { Chip, Tooltip } from \"@rebasepro/ui\";\n\nexport function UserChip({ user }: { user: User }) {\n return (\n <Tooltip title={user.email ?? user.uid}>\n <Chip size={\"small\"} className={\"flex items-center\"}>\n {user.photoURL && <img\n className={\"rounded-full w-6 h-6 mr-2\"}\n src={user.photoURL} alt={user.displayName ?? \"User picture\"}/>}\n <span>{user.displayName ?? user.email ?? user.uid}</span>\n </Chip>\n </Tooltip>\n );\n}\n","import type { EntityCollection } from \"@rebasepro/types\";\nimport type { Property } from \"@rebasepro/types\";\nimport * as React from \"react\";\n\nimport { ArrowLeftIcon, Chip, cls, defaultBorderMixin, iconSize, Tooltip, Typography } from \"@rebasepro/ui\";\nimport { PreviewSize } from \"../../types/components/PropertyPreviewProps\";\nimport { getPropertyInPath } from \"../../util/property_utils\";\nimport { PropertyPreview } from \"../../preview/PropertyPreview\";\nimport { SkeletonPropertyComponent } from \"../../preview/property_previews/SkeletonPropertyComponent\";\nimport { useAuthController } from \"@rebasepro/core\";\nimport { UserChip } from \"./UserChip\";\nimport { HistoryEntryData } from \"../../hooks\";\nimport { getValueInPath } from \"@rebasepro/utils\";\n\n/**\n * Recursive deep equality for primitives, arrays and plain objects.\n */\nfunction deepEqual(a: unknown, b: unknown): boolean {\n if (a === b) return true;\n if (a == null || b == null) return a === b;\n if (typeof a !== typeof b) return false;\n if (typeof a !== \"object\") return false;\n\n if (Array.isArray(a)) {\n if (!Array.isArray(b) || a.length !== (b as unknown[]).length) return false;\n return a.every((item, i) => deepEqual(item, (b as unknown[])[i]));\n }\n\n if (Array.isArray(b)) return false;\n\n const aObj = a as Record<string, unknown>;\n const bObj = b as Record<string, unknown>;\n const aKeys = Object.keys(aObj);\n const bKeys = Object.keys(bObj);\n if (aKeys.length !== bKeys.length) return false;\n return aKeys.every(key => key in bObj && deepEqual(aObj[key], bObj[key]));\n}\n\nexport type EntityHistoryEntryProps = {\n size: PreviewSize;\n actions?: React.ReactNode;\n collection?: EntityCollection;\n hover?: boolean;\n entry: HistoryEntryData;\n onClick?: (e: React.SyntheticEvent) => void;\n};\n\nfunction PreviousValueView({\n previousValueInPath,\n childProperty,\n propertyKey\n}: {\n previousValueInPath: unknown;\n childProperty: Property;\n propertyKey: string;\n}) {\n if (typeof previousValueInPath === \"string\" || typeof previousValueInPath === \"number\") {\n return <Typography variant={\"caption\"} color={\"secondary\"} className=\"line-through\">\n {previousValueInPath}\n </Typography>;\n } else if (typeof previousValueInPath === \"boolean\") {\n return <Typography variant={\"caption\"} color={\"secondary\"} className=\"line-through\">\n {previousValueInPath ? \"true\" : \"false\"}\n </Typography>;\n } else {\n return <Tooltip\n side={\"left\"}\n title={<div className={\"flex flex-col gap-2\"}>\n <Typography variant={\"caption\"} color={\"secondary\"}>\n Previous value\n </Typography>\n <PropertyPreview\n propertyKey={propertyKey as string}\n value={previousValueInPath as never}\n property={childProperty as Property}\n size={\"small\"}/>\n </div>}>\n <ArrowLeftIcon size={iconSize.smallest} color={\"disabled\"} className={\"mb-1\"}/>\n </Tooltip>\n }\n}\n\n/**\n * Displays a single entity history revision entry.\n * Adapted from the entity_history plugin — now reads from backend API data.\n */\nexport function EntityHistoryEntry({\n actions,\n hover,\n collection,\n size,\n entry\n}: EntityHistoryEntryProps) {\n\n const authController = useAuthController();\n\n const changedFields = entry.changed_fields;\n const previousValues = entry.previous_values;\n const updatedOn = new Date(entry.updated_at);\n const updatedBy = entry.updated_by;\n\n // Resolve user display\n const currentUser = authController.user;\n const userDisplay = updatedBy === currentUser?.uid\n ? currentUser\n : undefined;\n\n return <div className={\"w-full flex flex-col gap-2 mt-4\"}>\n <div className={\"ml-4 flex items-center gap-4\"}>\n <Typography variant={\"body2\"} color={\"secondary\"}>\n {updatedOn.toLocaleString()}\n </Typography>\n <Chip size={\"small\"}>\n {entry.action}\n </Chip>\n {!userDisplay && updatedBy && <Chip size={\"small\"}>{updatedBy}</Chip>}\n {userDisplay && <UserChip user={userDisplay}/>}\n </div>\n <div\n className={cls(\n \"bg-white dark:bg-surface-900\",\n \"min-h-[44px]\",\n \"w-full\",\n \"items-center\",\n hover ? \"hover:bg-surface-accent-50 dark:hover:bg-surface-800\" : \"\",\n size === \"small\" ? \"p-1\" : \"px-2 py-1\",\n \"flex border rounded-lg\",\n defaultBorderMixin\n )}>\n\n {actions}\n\n <div className={\"flex flex-col grow w-full m-1 shrink min-w-0\"}>\n\n {changedFields && collection && changedFields.map((key: string) => {\n const childProperty = getPropertyInPath(collection.properties, key);\n const valueInPath = entry.values ? getValueInPath(entry.values, key) : undefined;\n const previousValueInPath = previousValues ? getValueInPath(previousValues, key) : undefined;\n\n const element = childProperty\n ? <PropertyPreview\n propertyKey={key}\n value={valueInPath as never}\n property={childProperty as Property}\n size={\"small\"}/>\n : <Typography variant={\"body2\"}>\n {typeof valueInPath === \"string\" ? valueInPath : JSON.stringify(valueInPath)}\n </Typography>;\n\n return (\n <div key={\"ref_prev_\" + key}\n className=\"flex w-full my-1 items-center\">\n <Typography variant={\"caption\"}\n color={\"secondary\"}\n className=\"min-w-[140px] md:min-w-[200px] w-1/5 pr-8 overflow-hidden text-ellipsis text-right\">\n {key}\n </Typography>\n <div className=\"w-4/5\">\n {previousValueInPath !== undefined && !deepEqual(previousValueInPath, valueInPath) &&\n <PreviousValueView previousValueInPath={previousValueInPath}\n childProperty={childProperty as Property}\n propertyKey={key}/>\n }\n {element}\n </div>\n </div>\n );\n })}\n\n {(!changedFields || changedFields.length === 0) && (\n <Typography variant={\"caption\"} color={\"secondary\"} className=\"ml-4\">\n {entry.action === \"create\" ? \"Entity created\" :\n entry.action === \"delete\" ? \"Entity deleted\" : \"No field changes recorded\"}\n </Typography>\n )}\n\n </div>\n\n </div>\n </div>;\n}\n","\nimport type { EntityCustomViewParams } from \"@rebasepro/types\";\nimport { useRef, useEffect } from \"react\";\nimport { cls, IconButton, Label, Tooltip, Typography } from \"@rebasepro/ui\";\nimport { ErrorBoundary, HistoryIcon } from \"@rebasepro/ui\";\nimport { EntityHistoryEntry } from \"./EntityHistoryEntry\";\nimport { useSnackbarController, useAuthController } from \"@rebasepro/core\";\nimport { ConfirmationDialog } from \"@rebasepro/core\";\nimport { useState } from \"react\";\nimport { useEntityHistory } from \"../../index\";\n\n/**\n * Entity history tab view. Shows a paginated list of entity revisions\n * fetched from the backend API. Supports infinite scroll and revert.\n */\nexport function EntityHistoryView<M extends Record<string, unknown>>({\n entity,\n collection,\n formContext\n}: EntityCustomViewParams<M>) {\n\n const snackbarController = useSnackbarController();\n const authController = useAuthController();\n const dirty = formContext?.formex.dirty;\n\n const slug = collection.slug;\n const entityId = entity?.id;\n\n const {\n entries,\n isLoading,\n hasMore,\n loadMore,\n revert\n } = useEntityHistory({\n slug,\n entityId,\n enabled: !!entityId,\n pageSize: 10\n });\n\n const [revertHistoryId, setRevertHistoryId] = useState<string | undefined>();\n const [isReverting, setIsReverting] = useState(false);\n\n const containerRef = useRef<HTMLDivElement>(null);\n const loadMoreRef = useRef<HTMLDivElement>(null);\n\n // Intersection observer for infinite scroll\n useEffect(() => {\n const currentContainer = containerRef.current;\n const currentLoadMore = loadMoreRef.current;\n\n if (!currentContainer || !currentLoadMore || !hasMore || isLoading) return;\n\n const observer = new IntersectionObserver(\n (observerEntries) => {\n if (observerEntries[0].isIntersecting && hasMore && !isLoading) {\n loadMore();\n }\n },\n {\n root: currentContainer,\n rootMargin: \"0px 0px 200px 0px\",\n threshold: 0.01\n }\n );\n\n observer.observe(currentLoadMore);\n\n return () => observer.disconnect();\n }, [hasMore, isLoading, entries.length, loadMore]);\n\n if (!entity) {\n return <div className=\"flex items-center justify-center h-full\">\n <Label>HistoryIcon is only available for existing entities</Label>\n </div>;\n }\n\n async function doRevert(historyId: string) {\n setIsReverting(true);\n try {\n const revertedValues = await revert(historyId);\n setRevertHistoryId(undefined);\n\n // Reset the form with the reverted values so the UI updates\n // immediately without requiring a page refresh.\n if (formContext?.formex?.resetForm && revertedValues) {\n formContext.formex.resetForm({\n values: revertedValues as M,\n submitCount: 0,\n touched: {}\n });\n }\n\n snackbarController.open({\n message: \"Reverted to selected version\",\n type: \"info\"\n });\n } catch (error) {\n console.error(\"Error reverting entity:\", error);\n snackbarController.open({\n message: \"Error reverting entity\",\n type: \"error\"\n });\n } finally {\n setIsReverting(false);\n }\n }\n\n const revertEntry = revertHistoryId\n ? entries.find(e => e.id === revertHistoryId)\n : undefined;\n\n return <div\n ref={containerRef}\n className={cls(\"relative flex-1 h-full overflow-auto w-full flex flex-col gap-4 p-8\")}>\n <div className=\"flex flex-col gap-2 max-w-6xl mx-auto w-full\">\n\n <Typography variant={\"h5\"} className={\"mt-24 ml-4\"}>\n HistoryIcon\n </Typography>\n\n {isLoading && entries.length === 0 && (\n <div className=\"flex flex-col gap-4 mt-8 ml-4\">\n {[1, 2, 3].map(i => (\n <div key={i} className=\"flex flex-col gap-2 animate-pulse\">\n <div className=\"h-4 w-48 bg-surface-200 dark:bg-surface-700 rounded\"/>\n <div className=\"h-12 w-full bg-surface-100 dark:bg-surface-900 rounded-lg border border-surface-200 dark:border-surface-700\"/>\n </div>\n ))}\n </div>\n )}\n\n {!isLoading && entries.length === 0 && <>\n <Label className={\"ml-4 mt-8\"}>\n No history available\n </Label>\n <Typography variant={\"caption\"} className={\"ml-4\"}>\n When you save an entity, a new version is created and stored in the history.\n </Typography>\n </>}\n\n {entries.map((entry) => (\n <div key={entry.id} className=\"flex flex-cols gap-2 w-full\">\n <EntityHistoryEntry\n entry={entry}\n collection={collection}\n size={\"medium\"}\n actions={\n <Tooltip title={\"Revert to this version\"}\n className={\"m-2 grow-0 self-start\"}>\n <IconButton\n onClick={() => {\n if (dirty) {\n snackbarController.open({\n message: \"Please save or discard your changes before reverting\",\n type: \"warning\"\n });\n } else {\n setRevertHistoryId(entry.id);\n }\n }}>\n <HistoryIcon/>\n </IconButton>\n </Tooltip>\n }\n />\n </div>\n ))}\n\n {/* Load more sentinel */}\n {entries.length > 0 && (\n <div ref={loadMoreRef} className=\"py-4 text-center\">\n {isLoading && <Label>Loading more...</Label>}\n {!hasMore && entries.length > 10 && <Label>No more history available</Label>}\n </div>\n )}\n </div>\n\n <ErrorBoundary>\n <ConfirmationDialog\n open={Boolean(revertHistoryId)}\n onAccept={() => {\n if (revertHistoryId) doRevert(revertHistoryId);\n }}\n onCancel={() => setRevertHistoryId(undefined)}\n title={<Typography variant={\"subtitle2\"}>Revert data to this version?</Typography>}\n body={revertEntry\n ? <div className=\"p-4\">\n <Typography variant={\"caption\"} color={\"secondary\"}>\n This will save the entity with the values from{\" \"}\n {new Date(revertEntry.updated_at).toLocaleString()}.\n A new history entry will be created for the revert.\n </Typography>\n </div>\n : null\n }\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AAS;cAAa;GAAwC,CAAA;GACjF,MAAM,cACA,oBAAC,OAAD;IAAK,WAAU;cACb,qBAAC,YAAD;KAAY,SAAS;KAAW,OAAO;eAAvC;MAAoD;MACD;MAC9C,IAAI,KAAK,YAAY,UAAU,EAAE,eAAe;MAAE;KAE3C;;GACX,CAAA,IACH;EAET,CAAA,EACU,CAAA,CACd;;AACT"}
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  export * from "./types";
2
- export type { RebaseEditorProps, JSONContent, EditorAIController } from "./editor";
2
+ export type { RichTextEditorProps, RichTextEditorTextSize, RebaseEditorProps, RebaseEditorTextSize, JSONContent, EditorAIController } from "./editor";
3
3
  export * from "./form";
4
4
  export * from "./preview";
5
5
  export * from "./routes";
package/dist/index.js CHANGED
@@ -1,2 +1,2 @@
1
- import { $ as useApp, $n as getBracketNotation, $t as SideDialogs, A as KeyValuePreview, An as useSideDialogsController, At as RepeatFieldBinding, B as RebaseRouteDefs, Bn as SelectableTableContext, Bt as ArrayContainer, C as zodToFormErrors, Cn as useCMSContext, Ct as getFieldConfig, D as NumberPropertyPreview, Dn as useNavigationStateController, Dt as SwitchFieldBinding, E as UserPreview, En as NavigationStateContext, Et as TextFieldBinding, F as ArrayEnumPreview, Fn as useSelectionController, Ft as MapFieldBinding, G as useLocalCollectionsConfigController, Gn as resolveEntityAction, Gt as FormEntry, H as RebaseRoute, Hn as useSideEntityController, Ht as PropertyFieldBinding, I as ArrayOfStorageComponentsPreview, In as EntityCollectionTable, It as KeyValueFieldBinding, J as Scaffold, Jn as ArrayOfReferencesPreview, Jt as LabelWithIcon, K as RebaseAuthGate, Kn as resolveEntityView, Kt as LabelWithIconAndTooltip, L as RelationPreview, Ln as SelectableTable, Lt as DateTimeFieldBinding, M as ArrayOneOfPreview, Mn as getEntityViewWidth, Mt as ReferenceAsStringFieldBinding, N as ArrayOfStringsPreview, Nn as useBuildSideEntityController, Nt as MultiSelectFieldBinding, O as BooleanPreview, On as CollectionRegistryContext, Ot as StorageUploadFieldBinding, P as ArrayPropertyEnumPreview, Pn as mergeEntityActions, Pt as MarkdownEditorFieldBinding, Q as AppBar, Qn as getEntityTitlePropertyKey, Qt as EntitySelectionTable, R as CollectionPanel, Rn as EntityCollectionRowActions, Rt as BlockFieldBinding, S as EntityForm, Sn as useResolvedNavigationFrom, St as getDefaultFieldId, T as PropertyPreview, Tn as useUrlController, Tt as VectorFieldBinding, U as RebaseLayout, Un as useEntitySelectionDialog, Ut as ReadOnlyFieldBinding, V as CustomViewRoute, Vn as SideEntityControllerContext, Vt as ArrayCustomShapedFieldBinding, W as RebaseNavigation, Wn as VirtualTableInput, Wt as FormLayout, X as DefaultDrawer, Xn as EntityPreview, Xt as SearchIconsView, Y as Drawer, Yn as ReferencePreview, Yt as FieldHelperText, Z as DrawerFooterActions, Zn as getEntityPreviewKeys, Zt as FieldCaption, _ as getEntityCSVExportableData, _n as removeTrailingSlash, _r as renderSkeletonText, _t as convertFileToJson, a as namespaceToPropertiesPath, an as useResolvedCollections, ar as getResolvedPropertyInPath, at as EntityCard, b as ImportDataPreview, bn as useEntityHistory, br as ImagePreview, bt as DEFAULT_FIELD_CONFIGS, c as DEFAULT_COLLECTION_GENERATION_ENDPOINT, cn as editEntityAction, cr as ArrayPropertyPreview, ct as ImportNewPropertyFieldPreview, d as useCollectionsConfigController, dn as addInitialSlash, dr as StorageThumbnail, dt as flattenEntry, en as useBreadcrumbsController, er as getDefaultPropertiesOrder, et as AdminModeSyncer, f as ExportCollectionAction, fn as getCollectionBySlugWithin, fr as StorageThumbnailInternal, ft as processValueMapping, g as downloadEntitiesExport, gn as removeInitialSlash, gr as renderSkeletonImageThumbnail, gt as ImportFileUpload, h as downloadDataAsCsv, hn as removeInitialAndTrailingSlashes, hr as renderSkeletonIcon, ht as ImportSaveInProgress, i as namespaceToPropertiesOrderPath, in as useResolvedViews, ir as getPropertyInPath, it as EntityCollectionCardView, j as MapPropertyPreview, jn as buildSidePanelsFromUrl, jt as ReferenceFieldBinding, k as DatePreview, kn as useCollectionRegistryController, kt as SelectFieldBinding, l as buildCollectionGenerationCallback, ln as resetPasswordAction, lr as StringPropertyPreview, lt as DataNewPropertiesMapping, m as downloadBlob, mn as getLastSegment, mr as renderSkeletonCaptionText, mt as useImportConfig, n as getFullIdPath, nn as useBuildNavigationStateController, nr as getIconForWidget, nt as ReferenceWidget, o as MissingReferenceWidget, on as copyEntityAction, or as isReferenceProperty, ot as EntityCollectionViewActions, p as BasicExportAction, pn as getCollectionPathsCombinations, pr as SkeletonPropertyComponent, pt as getInferenceType, q as RebaseCMS, qn as EntityView, qt as PropertyIdCopyTooltip, r as idToPropertiesPath, rn as useTopLevelNavigation, rr as getPropertiesWithPropertiesOrder, rt as EntityCollectionView, s as CollectionGenerationApiError, sn as deleteEntityAction, sr as isRelationProperty, st as useCollectionEditorController, t as getFullId, tn as useBuildUrlController, tr as getIconForProperty, tt as SideEntityProvider, u as validateCollectionJson, un as CreationResultDialog, ur as EnumValuesChip, ut as convertDataToEntity, v as getEntityJsonExportableData, vn as resolveCollectionPathIds, vr as UrlComponentPreview, vt as unflattenObject, w as ArrayOfMapsPreview, wn as UrlContext, wt as getFieldId, x as PropertySelectEntry, xn as resolveNavigationFrom, xr as EmptyValue, xt as getDefaultFieldConfig, y as ImportCollectionAction, yn as useBuildCollectionRegistryController, yr as sanitizeUrl, yt as PropertyConfigBadge, z as RebaseShell, zn as useClearRestoreValue, zt as ArrayOfReferencesFieldBinding } from "./src-BJ8fkM8y.js";
1
+ import { $ as useApp, $n as getBracketNotation, $t as SideDialogs, A as KeyValuePreview, An as useSideDialogsController, At as RepeatFieldBinding, B as RebaseRouteDefs, Bn as SelectableTableContext, Bt as ArrayContainer, C as zodToFormErrors, Cn as useCMSContext, Ct as getFieldConfig, D as NumberPropertyPreview, Dn as useNavigationStateController, Dt as SwitchFieldBinding, E as UserPreview, En as NavigationStateContext, Et as TextFieldBinding, F as ArrayEnumPreview, Fn as useSelectionController, Ft as MapFieldBinding, G as useLocalCollectionsConfigController, Gn as resolveEntityAction, Gt as FormEntry, H as RebaseRoute, Hn as useSideEntityController, Ht as PropertyFieldBinding, I as ArrayOfStorageComponentsPreview, In as EntityCollectionTable, It as KeyValueFieldBinding, J as Scaffold, Jn as ArrayOfReferencesPreview, Jt as LabelWithIcon, K as RebaseAuthGate, Kn as resolveEntityView, Kt as LabelWithIconAndTooltip, L as RelationPreview, Ln as SelectableTable, Lt as DateTimeFieldBinding, M as ArrayOneOfPreview, Mn as getEntityViewWidth, Mt as ReferenceAsStringFieldBinding, N as ArrayOfStringsPreview, Nn as useBuildSideEntityController, Nt as MultiSelectFieldBinding, O as BooleanPreview, On as CollectionRegistryContext, Ot as StorageUploadFieldBinding, P as ArrayPropertyEnumPreview, Pn as mergeEntityActions, Pt as MarkdownEditorFieldBinding, Q as AppBar, Qn as getEntityTitlePropertyKey, Qt as EntitySelectionTable, R as CollectionPanel, Rn as EntityCollectionRowActions, Rt as BlockFieldBinding, S as EntityForm, Sn as useResolvedNavigationFrom, St as getDefaultFieldId, T as PropertyPreview, Tn as useUrlController, Tt as VectorFieldBinding, U as RebaseLayout, Un as useEntitySelectionDialog, Ut as ReadOnlyFieldBinding, V as CustomViewRoute, Vn as SideEntityControllerContext, Vt as ArrayCustomShapedFieldBinding, W as RebaseNavigation, Wn as VirtualTableInput, Wt as FormLayout, X as DefaultDrawer, Xn as EntityPreview, Xt as SearchIconsView, Y as Drawer, Yn as ReferencePreview, Yt as FieldHelperText, Z as DrawerFooterActions, Zn as getEntityPreviewKeys, Zt as FieldCaption, _ as getEntityCSVExportableData, _n as removeTrailingSlash, _r as renderSkeletonText, _t as convertFileToJson, a as namespaceToPropertiesPath, an as useResolvedCollections, ar as getResolvedPropertyInPath, at as EntityCard, b as ImportDataPreview, bn as useEntityHistory, br as ImagePreview, bt as DEFAULT_FIELD_CONFIGS, c as DEFAULT_COLLECTION_GENERATION_ENDPOINT, cn as editEntityAction, cr as ArrayPropertyPreview, ct as ImportNewPropertyFieldPreview, d as useCollectionsConfigController, dn as addInitialSlash, dr as StorageThumbnail, dt as flattenEntry, en as useBreadcrumbsController, er as getDefaultPropertiesOrder, et as AdminModeSyncer, f as ExportCollectionAction, fn as getCollectionBySlugWithin, fr as StorageThumbnailInternal, ft as processValueMapping, g as downloadEntitiesExport, gn as removeInitialSlash, gr as renderSkeletonImageThumbnail, gt as ImportFileUpload, h as downloadDataAsCsv, hn as removeInitialAndTrailingSlashes, hr as renderSkeletonIcon, ht as ImportSaveInProgress, i as namespaceToPropertiesOrderPath, in as useResolvedViews, ir as getPropertyInPath, it as EntityCollectionCardView, j as MapPropertyPreview, jn as buildSidePanelsFromUrl, jt as ReferenceFieldBinding, k as DatePreview, kn as useCollectionRegistryController, kt as SelectFieldBinding, l as buildCollectionGenerationCallback, ln as resetPasswordAction, lr as StringPropertyPreview, lt as DataNewPropertiesMapping, m as downloadBlob, mn as getLastSegment, mr as renderSkeletonCaptionText, mt as useImportConfig, n as getFullIdPath, nn as useBuildNavigationStateController, nr as getIconForWidget, nt as ReferenceWidget, o as MissingReferenceWidget, on as copyEntityAction, or as isReferenceProperty, ot as EntityCollectionViewActions, p as BasicExportAction, pn as getCollectionPathsCombinations, pr as SkeletonPropertyComponent, pt as getInferenceType, q as RebaseCMS, qn as EntityView, qt as PropertyIdCopyTooltip, r as idToPropertiesPath, rn as useTopLevelNavigation, rr as getPropertiesWithPropertiesOrder, rt as EntityCollectionView, s as CollectionGenerationApiError, sn as deleteEntityAction, sr as isRelationProperty, st as useCollectionEditorController, t as getFullId, tn as useBuildUrlController, tr as getIconForProperty, tt as SideEntityProvider, u as validateCollectionJson, un as CreationResultDialog, ur as EnumValuesChip, ut as convertDataToEntity, v as getEntityJsonExportableData, vn as resolveCollectionPathIds, vr as UrlComponentPreview, vt as unflattenObject, w as ArrayOfMapsPreview, wn as UrlContext, wt as getFieldId, x as PropertySelectEntry, xn as resolveNavigationFrom, xr as EmptyValue, xt as getDefaultFieldConfig, y as ImportCollectionAction, yn as useBuildCollectionRegistryController, yr as sanitizeUrl, yt as PropertyConfigBadge, z as RebaseShell, zn as useClearRestoreValue, zt as ArrayOfReferencesFieldBinding } from "./src-BYniefVu.js";
2
2
  export { AdminModeSyncer, AppBar, ArrayContainer, ArrayCustomShapedFieldBinding, ArrayEnumPreview, ArrayOfMapsPreview, ArrayOfReferencesFieldBinding, ArrayOfReferencesPreview, ArrayOfStorageComponentsPreview, ArrayOfStringsPreview, ArrayOneOfPreview, ArrayPropertyEnumPreview, ArrayPropertyPreview, BasicExportAction, BlockFieldBinding, BooleanPreview, CollectionGenerationApiError, CollectionPanel, CollectionRegistryContext, CreationResultDialog, CustomViewRoute, DEFAULT_COLLECTION_GENERATION_ENDPOINT, DEFAULT_FIELD_CONFIGS, DataNewPropertiesMapping, DatePreview, DateTimeFieldBinding, DefaultDrawer, Drawer, DrawerFooterActions, EmptyValue, EntityCard, EntityCollectionCardView, EntityCollectionRowActions, EntityCollectionTable, EntityCollectionView, EntityCollectionViewActions, EntityForm, EntityPreview, EntitySelectionTable, EntityView, EnumValuesChip, ExportCollectionAction, FieldCaption, FieldHelperText, FormEntry, FormLayout, ImagePreview, ImportCollectionAction, ImportDataPreview, ImportFileUpload, ImportNewPropertyFieldPreview, ImportSaveInProgress, KeyValueFieldBinding, KeyValuePreview, LabelWithIcon, LabelWithIconAndTooltip, MapFieldBinding, MapPropertyPreview, MarkdownEditorFieldBinding, MissingReferenceWidget, MultiSelectFieldBinding, NavigationStateContext, NumberPropertyPreview, PropertyConfigBadge, PropertyFieldBinding, PropertyIdCopyTooltip, PropertyPreview, PropertySelectEntry, ReadOnlyFieldBinding, RebaseAuthGate, RebaseCMS, RebaseLayout, RebaseNavigation, RebaseRoute, RebaseRouteDefs, RebaseShell, ReferenceAsStringFieldBinding, ReferenceFieldBinding, ReferencePreview, ReferenceWidget, RelationPreview, RepeatFieldBinding, Scaffold, SearchIconsView, SelectFieldBinding, SelectableTable, SelectableTableContext, SideDialogs, SideEntityControllerContext, SideEntityProvider, SkeletonPropertyComponent, StorageThumbnail, StorageThumbnailInternal, StorageUploadFieldBinding, StringPropertyPreview, SwitchFieldBinding, TextFieldBinding, UrlComponentPreview, UrlContext, UserPreview, VectorFieldBinding, VirtualTableInput, addInitialSlash, buildCollectionGenerationCallback, buildSidePanelsFromUrl, convertDataToEntity, convertFileToJson, copyEntityAction, deleteEntityAction, downloadBlob, downloadDataAsCsv, downloadEntitiesExport, editEntityAction, flattenEntry, getBracketNotation, getCollectionBySlugWithin, getCollectionPathsCombinations, getDefaultFieldConfig, getDefaultFieldId, getDefaultPropertiesOrder, getEntityCSVExportableData, getEntityJsonExportableData, getEntityPreviewKeys, getEntityTitlePropertyKey, getEntityViewWidth, getFieldConfig, getFieldId, getFullId, getFullIdPath, getIconForProperty, getIconForWidget, getInferenceType, getLastSegment, getPropertiesWithPropertiesOrder, getPropertyInPath, getResolvedPropertyInPath, idToPropertiesPath, isReferenceProperty, isRelationProperty, mergeEntityActions, namespaceToPropertiesOrderPath, namespaceToPropertiesPath, processValueMapping, removeInitialAndTrailingSlashes, removeInitialSlash, removeTrailingSlash, renderSkeletonCaptionText, renderSkeletonIcon, renderSkeletonImageThumbnail, renderSkeletonText, resetPasswordAction, resolveCollectionPathIds, resolveEntityAction, resolveEntityView, resolveNavigationFrom, sanitizeUrl, unflattenObject, useApp, useBreadcrumbsController, useBuildCollectionRegistryController, useBuildNavigationStateController, useBuildSideEntityController, useBuildUrlController, useCMSContext, useClearRestoreValue, useCollectionEditorController, useCollectionRegistryController, useCollectionsConfigController, useEntityHistory, useEntitySelectionDialog, useImportConfig, useLocalCollectionsConfigController, useNavigationStateController, useResolvedCollections, useResolvedNavigationFrom, useResolvedViews, useSelectionController, useSideDialogsController, useSideEntityController, useTopLevelNavigation, useUrlController, validateCollectionJson, zodToFormErrors };
@@ -2,7 +2,7 @@ import { t as __exportAll } from "./rolldown-runtime-D7D4PA-g.js";
2
2
  import * as React$1 from "react";
3
3
  import React, { Suspense, createContext, createElement, forwardRef, lazy, memo, useCallback, useContext, useEffect, useLayoutEffect, useMemo, useRef, useState, useSyncExternalStore } from "react";
4
4
  import { deepEqual } from "fast-equals";
5
- import { Alert, AlertCircleIcon, AlertTriangleIcon, AlignLeftIcon, ArrowLeftIcon, ArrowRightIcon, ArrowRightToLineIcon, Avatar, Badge, BooleanSwitch, BooleanSwitchWithLabel, Button, CHIP_COLORS, CalendarIcon, Card, CenteredView, CheckCircleIcon, CheckIcon, Checkbox, ChevronDownIcon, ChevronRightIcon, ChevronUpIcon, ChevronsLeftIcon, ChevronsRightIcon, ChevronsUpDownIcon, Chip, CircleIcon, CircularProgress, CircularProgressCenter, CodeIcon, Collapse, ColumnsIcon, Container, CopyIcon, DateTimeField, Dialog, DialogActions, DialogContent, DialogTitle, DownloadIcon, ErrorBoundary, ExpandablePanel, ExternalLinkIcon, EyeIcon, EyeOffIcon, FileTextIcon, FileUpload, FilterChip, FilterIcon, FilterXIcon, FlagIcon, FolderUpIcon, FunctionSquareIcon, GlobeIcon, HandleIcon, HashIcon, HistoryIcon, IconButton, ImageOffIcon, KanbanIcon, KeyRoundIcon, Label, LayoutGridIcon, LinkIcon, ListIcon, ListOrderedIcon, LoadingButton, LogOutIcon, MailIcon, Markdown, Maximize2Icon, Menu, MenuIcon, MenuItem, MinusIcon, MoonIcon, MoreVerticalIcon, MultiSelect, MultiSelectItem, PencilIcon, PlusIcon, Popover, PopoverPrimitive, Portal, QuoteIcon, RadioGroup, RadioGroupItem, RefreshCwIcon, RepeatIcon, ResizablePanels, Rows3Icon, SearchBar, SearchIcon, Select, SelectItem, Separator, SettingsIcon, Sheet, Skeleton, StarIcon, SunIcon, SunMoonIcon, Tab, Table, TableBody, TableCell, TableHeader, TableIcon, TableRow, Tabs, TextField, TextIcon, TextareaAutosize, ToggleButtonGroup, Tooltip, Trash2Icon, Typography, UploadIcon, UserIcon, VirtualTable, VoteIcon, XCircleIcon, XIcon, cls, coolIconKeys, debounce, defaultBorderMixin, fieldBackgroundDisabledMixin, fieldBackgroundHoverMixin, fieldBackgroundInvisibleMixin, fieldBackgroundMixin, focusedDisabled, getColorSchemeForKey, getColorSchemeForSeed, iconSize, lucideIcons, paperMixin, useDebouncedCallback, useInjectStyles, useOutsideAlerter } from "@rebasepro/ui";
5
+ import { Alert, AlertCircleIcon, AlertTriangleIcon, AlignLeftIcon, ArrowLeftIcon, ArrowRightToLineIcon, Avatar, Badge, BooleanSwitch, BooleanSwitchWithLabel, Button, CHIP_COLORS, CalendarIcon, Card, CenteredView, CheckCircleIcon, CheckIcon, Checkbox, ChevronDownIcon, ChevronRightIcon, ChevronUpIcon, ChevronsLeftIcon, ChevronsRightIcon, ChevronsUpDownIcon, Chip, CircleIcon, CircularProgress, CircularProgressCenter, CodeIcon, Collapse, ColumnsIcon, Container, CopyIcon, DateTimeField, Dialog, DialogActions, DialogContent, DialogTitle, DownloadIcon, ErrorBoundary, ExpandablePanel, ExternalLinkIcon, EyeIcon, EyeOffIcon, FileTextIcon, FileUpload, FilterChip, FilterIcon, FilterXIcon, FlagIcon, FolderUpIcon, FunctionSquareIcon, GlobeIcon, HandleIcon, HashIcon, HistoryIcon, IconButton, ImageOffIcon, KanbanIcon, KeyRoundIcon, Label, LayoutGridIcon, LinkIcon, ListIcon, ListOrderedIcon, LoadingButton, LogOutIcon, MailIcon, Markdown, Maximize2Icon, Menu, MenuIcon, MenuItem, MinusIcon, MoonIcon, MoreVerticalIcon, MultiSelect, MultiSelectItem, PencilIcon, PlusIcon, Popover, PopoverPrimitive, Portal, QuoteIcon, RadioGroup, RadioGroupItem, RefreshCwIcon, RepeatIcon, ResizablePanels, Rows3Icon, SearchBar, SearchIcon, Select, SelectItem, Separator, SettingsIcon, Sheet, Skeleton, StarIcon, SunIcon, SunMoonIcon, Tab, Table, TableBody, TableCell, TableHeader, TableIcon, TableRow, Tabs, TextField, TextIcon, TextareaAutosize, ToggleButtonGroup, Tooltip, Trash2Icon, Typography, UploadIcon, UserIcon, VirtualTable, VoteIcon, XCircleIcon, XIcon, cls, coolIconKeys, debounce, defaultBorderMixin, fieldBackgroundDisabledMixin, fieldBackgroundHoverMixin, fieldBackgroundInvisibleMixin, fieldBackgroundMixin, focusedDisabled, getColorSchemeForKey, getColorSchemeForSeed, iconSize, lucideIcons, paperMixin, useDebouncedCallback, useInjectStyles, useOutsideAlerter } from "@rebasepro/ui";
6
6
  import { CollectionRegistry, DEFAULT_ONE_OF_TYPE, DEFAULT_ONE_OF_VALUE, addInitialSlash, canReadCollection, enumToObjectEntries, getArrayResolvedProperties, getCollectionBySlugWithin, getCollectionPathsCombinations, getDefaultValueFor, getDefaultValueFortype, getDefaultValuesFor, getEntityImagePreviewPropertyKey, getLabelOrConfigFrom, getLastSegment, getLastSegment as getLastSegment$1, getLocalChangesBackup, getNavigationEntriesFromPath, getParentReferencesFromPath, getReferenceFrom, getRelationFrom, getSubcollections, getTableName, isHidden, isPropertyBuilder, isReadOnly, normalizeToEntityRelation, removeInitialAndTrailingSlashes, removeInitialAndTrailingSlashes as removeInitialAndTrailingSlashes$1, removeInitialSlash, removeTrailingSlash, resolveArrayProperties, resolveCollectionPathIds, resolveCollectionPathIds as resolveCollectionPathIds$1, resolveDefaultSelectedView, resolveEnumValues, resolveProperty, resolveRelationProperty, resolveStorageFilenameString, resolveStoragePathString } from "@rebasepro/common";
7
7
  import { ADDITIONAL_TAB_WIDTH, CONTAINER_FULL_WIDTH, CollectionComponentOverrideProvider, ConfirmationDialog, CustomizationControllerContext, DEFAULT_PAGE_SIZE, ErrorTooltip, ErrorView, FORM_CONTAINER_WIDTH, IconForView, LanguageToggle, LoginView, NotFoundPage, PluginProviderStack, RebaseLogo, RebaseRoutes, SchemaDriftBanner, StudioBridgeRegistryProvider, UIReferenceView, UnsavedChangesDialog, UserDisplay, UserSettingsView, buildCollapsedDefaults, buildEnumLabel, createFormexStub, deleteEntityWithCallbacks, flattenKeys, getColorScheme, getColumnKeysForProperty, getEntityFromCache, getEntityFromMemoryCache, getFormFieldKeys, getIcon, getRowHeight, iconsSearch, removeEntityFromCache, removeEntityFromMemoryCache, resolveComponentRef, saveEntityToCache, saveEntityToMemoryCache, saveEntityWithCallbacks, useAdminModeController, useAnalyticsController, useApiConfig, useAuthController, useBridgeRegistration, useBuildLocalConfigurationPersistence, useCollapsedGroups, useColumnIds, useComponentOverride, useCustomizationController, useData, useDataTableController, useEntityFetch, useLargeLayout, useModeController, usePermissions, useRebaseClient, useRebaseContext, useRebaseRegistry, useRebaseRegistryDispatch, useRelationSelector, useRestoreScroll, useScrollRestoration, useSlot, useSnackbarController, useStorageSource, useStorageUploadController, useTranslation, useUnsavedChangesDialog, useUserConfigurationPersistence } from "@rebasepro/core";
8
8
  import { Field, Formex, getIn, setIn, useCreateFormex, useFormex } from "@rebasepro/formex";
@@ -1578,7 +1578,7 @@ var MAIN_TAB_VALUE = "__main_##Q$SC^#S6";
1578
1578
  var JSON_TAB_VALUE = "__json";
1579
1579
  //#endregion
1580
1580
  //#region src/components/EntityDetailView.tsx
1581
- var EntityHistoryView$1 = lazy(() => import("./history-BL49TIDb.js").then((m) => ({ default: m.EntityHistoryView })));
1581
+ var EntityHistoryView$1 = lazy(() => import("./history-BO6VT85a.js").then((m) => ({ default: m.EntityHistoryView })));
1582
1582
  function EntityDetailView({ entityId, ...props }) {
1583
1583
  const { entity, dataLoading, dataLoadingError } = useEntityFetch({
1584
1584
  path: props.path,
@@ -4889,7 +4889,7 @@ function StringNumberFilterField({ name, value, setValue, type, isArray, enumVal
4889
4889
  value: Array.isArray(internalValue) ? internalValue.map((e) => String(e)) : [],
4890
4890
  disabled: isNullOperation,
4891
4891
  onValueChange: (value) => {
4892
- updateFilter(operation, type === "number" ? value.map((v) => parseInt(v)) : value);
4892
+ updateFilter(operation, type === "number" ? (value ?? []).map((v) => parseInt(v)) : value);
4893
4893
  },
4894
4894
  multiple,
4895
4895
  endAdornment: internalValue && /* @__PURE__ */ jsx(IconButton, {
@@ -5875,7 +5875,7 @@ function EntityActionButton({ action, enabled, props }) {
5875
5875
  }
5876
5876
  //#endregion
5877
5877
  //#region src/components/EntityEditView.tsx
5878
- var EntityHistoryView = lazy(() => import("./history-BL49TIDb.js").then((m) => ({ default: m.EntityHistoryView })));
5878
+ var EntityHistoryView = lazy(() => import("./history-BO6VT85a.js").then((m) => ({ default: m.EntityHistoryView })));
5879
5879
  /**
5880
5880
  * This is the default view that is used as the content of a side panel when
5881
5881
  * an entity is opened.
@@ -7546,7 +7546,7 @@ var deleteEntityAction = {
7546
7546
  name: "Delete",
7547
7547
  key: "delete",
7548
7548
  isEnabled: ({ entity }) => Boolean(entity),
7549
- onClick({ entity, path, collection, context, selectionController, onCollectionChange, navigateBack }) {
7549
+ onClick({ entity, path, collection, context, selectionController, onCollectionChange, navigateBack, openEntityMode }) {
7550
7550
  if (!entity) throw new Error("INTERNAL: deleteEntityAction: Entity is undefined");
7551
7551
  if (!context.dialogsController) throw new Error("INTERNAL: deleteEntityAction: context.dialogsController is undefined");
7552
7552
  const { closeDialog } = context.dialogsController.open({
@@ -7563,7 +7563,10 @@ var deleteEntityAction = {
7563
7563
  context.analyticsController?.onAnalyticsEvent?.("single_entity_deleted", { path });
7564
7564
  selectionController?.setSelectedEntities(selectionController.selectedEntities.filter((e) => e.id !== entity.id));
7565
7565
  onCollectionChange?.();
7566
- navigateBack?.();
7566
+ if (openEntityMode === "full_screen" && context.urlController) {
7567
+ const collectionUrl = context.urlController.buildUrlCollectionPath(path);
7568
+ context.urlController.navigate(collectionUrl, { replace: true });
7569
+ } else navigateBack?.();
7567
7570
  },
7568
7571
  onClose: closeDialog
7569
7572
  });
@@ -9452,12 +9455,12 @@ function ArrayContainer({ droppableId, addLabel, value, disabled = false, buildE
9452
9455
  const newIds = [...internalIds];
9453
9456
  newIds.splice(index, 1);
9454
9457
  setInternalIds(newIds);
9455
- onValueChange(value.filter((_, i) => i !== index));
9458
+ onValueChange((value ?? []).filter((_, i) => i !== index));
9456
9459
  };
9457
9460
  const copy = (index) => {
9458
9461
  if ((value ?? []).length >= max) return;
9459
9462
  const id = getRandomId$1();
9460
- const copyingItem = value[index];
9463
+ const copyingItem = (value ?? [])[index];
9461
9464
  const newIds = [
9462
9465
  ...internalIds.slice(0, index + 1),
9463
9466
  id,
@@ -9466,9 +9469,9 @@ function ArrayContainer({ droppableId, addLabel, value, disabled = false, buildE
9466
9469
  if (onInternalIdAdded) onInternalIdAdded(id);
9467
9470
  setInternalIds(newIds);
9468
9471
  onValueChange([
9469
- ...value.slice(0, index + 1),
9472
+ ...(value ?? []).slice(0, index + 1),
9470
9473
  copyingItem,
9471
- ...value.slice(index + 1)
9474
+ ...(value ?? []).slice(index + 1)
9472
9475
  ]);
9473
9476
  };
9474
9477
  const addInIndex = (index) => {
@@ -9482,9 +9485,9 @@ function ArrayContainer({ droppableId, addLabel, value, disabled = false, buildE
9482
9485
  if (onInternalIdAdded) onInternalIdAdded(id);
9483
9486
  setInternalIds(newIds);
9484
9487
  onValueChange([
9485
- ...value.slice(0, index),
9488
+ ...(value ?? []).slice(0, index),
9486
9489
  newDefaultEntry,
9487
- ...value.slice(index)
9490
+ ...(value ?? []).slice(index)
9488
9491
  ]);
9489
9492
  };
9490
9493
  const onDragEnd = (event) => {
@@ -9494,7 +9497,7 @@ function ArrayContainer({ droppableId, addLabel, value, disabled = false, buildE
9494
9497
  const newIndex = internalIds.indexOf(over.id);
9495
9498
  if (oldIndex === -1 || newIndex === -1) return;
9496
9499
  setInternalIds(arrayMove$1(internalIds, oldIndex, newIndex));
9497
- onValueChange(arrayMove$1(value, oldIndex, newIndex));
9500
+ onValueChange(arrayMove$1(value ?? [], oldIndex, newIndex));
9498
9501
  };
9499
9502
  return sortable ? /* @__PURE__ */ jsx(DndContext, {
9500
9503
  sensors,
@@ -10391,7 +10394,7 @@ function MapFieldBinding({ propertyKey, value, showError, error, disabled, prope
10391
10394
  }
10392
10395
  //#endregion
10393
10396
  //#region src/form/field_bindings/MarkdownEditorFieldBinding.tsx
10394
- var RebaseEditor = lazy(() => import("./editor.js").then((m) => ({ default: m.RebaseEditor })));
10397
+ var RichTextEditor = lazy(() => import("./editor.js").then((m) => ({ default: m.RichTextEditor })));
10395
10398
  var loadMarkdownUtils = () => import("./markdown-CklalUUk.js").then((n) => n.t);
10396
10399
  var _markdownUtils = null;
10397
10400
  var getMarkdownUtils = async () => {
@@ -10506,7 +10509,7 @@ function MarkdownEditorFieldBinding({ property, propertyKey, value, setValue, in
10506
10509
  height: 200,
10507
10510
  className: "w-full rounded-md"
10508
10511
  }),
10509
- children: /* @__PURE__ */ jsx(RebaseEditor, {
10512
+ children: /* @__PURE__ */ jsx(RichTextEditor, {
10510
10513
  content: value,
10511
10514
  onMarkdownContentChange: onContentChange,
10512
10515
  version: context.formex.version + fieldVersion,
@@ -11249,7 +11252,7 @@ function StorageUpload({ property, name, value, setInternalValue, onChange, mult
11249
11252
  onDragStart: handleDragStart,
11250
11253
  onDragEnd: handleDragEnd,
11251
11254
  children: /* @__PURE__ */ jsx(SortableContext, {
11252
- items: value.map((v) => v.id),
11255
+ items: (value ?? []).map((v) => v.id),
11253
11256
  strategy: horizontalListSortingStrategy,
11254
11257
  children: /* @__PURE__ */ jsx(FileDropComponent, { ...fileDropProps })
11255
11258
  })
@@ -16255,23 +16258,30 @@ function EntityCollectionBoardView({ collection, tableController, fullPath, pare
16255
16258
  /* @__PURE__ */ jsxs(Dialog, {
16256
16259
  open: showBackfillDialog,
16257
16260
  onOpenChange: setShowBackfillDialog,
16258
- children: [/* @__PURE__ */ jsxs(DialogContent, { children: [/* @__PURE__ */ jsx(Typography, {
16259
- variant: "h6",
16260
- className: "mb-4",
16261
- children: t("initialize_kanban_order")
16262
- }), /* @__PURE__ */ jsx(Typography, {
16263
- variant: "body2",
16264
- children: t("initialize_kanban_order_desc")
16265
- })] }), /* @__PURE__ */ jsxs(DialogActions, { children: [/* @__PURE__ */ jsx(Button, {
16266
- variant: "text",
16267
- onClick: () => setShowBackfillDialog(false),
16268
- disabled: backfillLoading,
16269
- children: t("cancel")
16270
- }), /* @__PURE__ */ jsx(Button, {
16271
- onClick: handleBackfill,
16272
- disabled: backfillLoading,
16273
- children: backfillLoading ? /* @__PURE__ */ jsx(CircularProgress, { size: "smallest" }) : t("initialize")
16274
- })] })]
16261
+ children: [
16262
+ /* @__PURE__ */ jsx(DialogTitle, {
16263
+ hidden: true,
16264
+ children: t("initialize_kanban_order")
16265
+ }),
16266
+ /* @__PURE__ */ jsxs(DialogContent, { children: [/* @__PURE__ */ jsx(Typography, {
16267
+ variant: "h6",
16268
+ className: "mb-4",
16269
+ children: t("initialize_kanban_order")
16270
+ }), /* @__PURE__ */ jsx(Typography, {
16271
+ variant: "body2",
16272
+ children: t("initialize_kanban_order_desc")
16273
+ })] }),
16274
+ /* @__PURE__ */ jsxs(DialogActions, { children: [/* @__PURE__ */ jsx(Button, {
16275
+ variant: "text",
16276
+ onClick: () => setShowBackfillDialog(false),
16277
+ disabled: backfillLoading,
16278
+ children: t("cancel")
16279
+ }), /* @__PURE__ */ jsx(Button, {
16280
+ onClick: handleBackfill,
16281
+ disabled: backfillLoading,
16282
+ children: backfillLoading ? /* @__PURE__ */ jsx(CircularProgress, { size: "smallest" }) : t("initialize")
16283
+ })] })
16284
+ ]
16275
16285
  })
16276
16286
  ]
16277
16287
  });
@@ -18675,10 +18685,10 @@ function DrawerNavigationItem({ name, icon, drawerOpen, adminMenuOpen, tooltipsO
18675
18685
  width: "100%",
18676
18686
  transition: drawerOpen ? "width 150ms ease-in" : void 0
18677
18687
  },
18678
- className: ({ isActive }) => cls("rounded-md truncate", "hover:bg-surface-100 dark:hover:bg-surface-800/60 text-surface-700 dark:text-surface-300 hover:text-surface-900 dark:hover:text-white", "flex flex-row items-center", drawerOpen ? "pr-4 h-[30px]" : "h-[30px]", "font-medium text-[13px]", isActive ? "bg-surface-900/[0.06] dark:bg-surface-800/50 text-surface-900 dark:text-white" : ""),
18688
+ className: ({ isActive }) => cls("rounded-lg truncate group/nav", "hover:bg-primary/5 dark:hover:bg-primary/5 text-surface-700 dark:text-surface-300 hover:text-surface-900 dark:hover:text-white", "flex flex-row items-center", drawerOpen ? "pr-4 h-[30px]" : "h-[30px]", "font-medium text-[13px]", isActive ? "bg-primary/8 dark:bg-primary/10 text-primary dark:text-primary [&_div]:text-primary" : ""),
18679
18689
  to: url,
18680
18690
  children: [/* @__PURE__ */ jsx("div", {
18681
- className: "shrink-0 flex items-center justify-center w-[44px] h-[30px] text-surface-500 dark:text-text-secondary-dark [&>svg]:size-4",
18691
+ className: "shrink-0 flex items-center justify-center w-[44px] h-[30px] text-surface-500 dark:text-text-secondary-dark [&>svg]:size-4 group-hover/nav:text-primary transition-colors duration-150",
18682
18692
  children: icon
18683
18693
  }), /* @__PURE__ */ jsx("div", {
18684
18694
  className: cls("text-text-primary dark:text-surface-200", drawerOpen ? "opacity-100" : "opacity-0 hidden", "font-inherit truncate space-x-2"),
@@ -19406,7 +19416,7 @@ function useLocalCollectionsConfigController(clientOrUrl, baseCollections = [],
19406
19416
  //#region src/components/RebaseNavigation.tsx
19407
19417
  var EMPTY_PLUGINS = [];
19408
19418
  var EMPTY_COLLECTIONS = [];
19409
- var CollectionsStudioView = lazy(() => import("./CollectionsStudioView-UKouBPOm.js").then((n) => n.n).then((m) => ({ default: m.CollectionsStudioView })));
19419
+ var CollectionsStudioView = lazy(() => import("./CollectionsStudioView-B1mN33GB.js").then((n) => n.n).then((m) => ({ default: m.CollectionsStudioView })));
19410
19420
  /**
19411
19421
  * Navigation layer — builds and provides all CMS navigation controllers:
19412
19422
  * collection registry, URL controller, navigation state, side entity,
@@ -19635,7 +19645,7 @@ function NavigationGroup({ children, group, minimised, isPreview, isPotentialCar
19635
19645
  variant: isPreview ? "body2" : "caption",
19636
19646
  component: "h2",
19637
19647
  color: "secondary",
19638
- className: cls("px-4 py-1 rounded", "font-semibold text-[11px] uppercase tracking-wider text-surface-400 dark:text-surface-400"),
19648
+ className: cls("px-4 py-1 rounded", "font-medium text-[10px] uppercase tracking-[0.08em] text-primary/50 dark:text-primary/70"),
19639
19649
  children: currentGroupName
19640
19650
  }), !isPreview && onEditGroup && !dndDisabled && /* @__PURE__ */ jsx(IconButton, {
19641
19651
  size: "smallest",
@@ -19698,7 +19708,7 @@ function NavigationGroup({ children, group, minimised, isPreview, isPotentialCar
19698
19708
  //#region src/components/HomePage/NavigationCard.tsx
19699
19709
  var NavigationCard = React.memo(function NavigationCard({ name, description, icon, actions, additionalContent, onClick, shrink }) {
19700
19710
  return /* @__PURE__ */ jsx(Card, {
19701
- className: cls("group h-full p-4 cursor-pointer transition-all duration-150 ease-in-out", "border-surface-200 dark:border-surface-700/40", "hover:shadow-md hover:shadow-black/[0.04]", "hover:border-surface-300 dark:hover:border-primary/20", shrink && "w-full max-w-full min-h-0 scale-75"),
19711
+ className: cls("group h-full p-4 cursor-pointer transition-colors duration-150 ease-in-out", "hover:bg-primary/5 dark:hover:bg-primary/5", shrink && "w-full max-w-full min-h-0 scale-75"),
19702
19712
  onClick: () => {
19703
19713
  onClick?.();
19704
19714
  },
@@ -19708,9 +19718,9 @@ var NavigationCard = React.memo(function NavigationCard({ name, description, ico
19708
19718
  /* @__PURE__ */ jsxs("div", {
19709
19719
  className: "flex items-center w-full justify-between mb-1",
19710
19720
  children: [/* @__PURE__ */ jsxs("div", {
19711
- className: "flex items-center gap-4",
19721
+ className: "flex items-center gap-3",
19712
19722
  children: [/* @__PURE__ */ jsx("div", {
19713
- className: "flex items-center justify-center w-6 h-6 rounded-lg bg-primary/8 dark:bg-primary/10 text-primary/70 dark:text-primary/60 transition-colors duration-200 group-hover:bg-primary/12 dark:group-hover:bg-primary/15 group-hover:text-primary dark:group-hover:text-primary/80",
19723
+ className: "flex items-center justify-center w-5 h-5 text-surface-400 dark:text-surface-500 transition-colors duration-150 group-hover:text-primary dark:group-hover:text-primary",
19714
19724
  children: icon
19715
19725
  }), /* @__PURE__ */ jsx(Typography, {
19716
19726
  variant: "subtitle1",
@@ -19727,7 +19737,7 @@ var NavigationCard = React.memo(function NavigationCard({ name, description, ico
19727
19737
  })]
19728
19738
  }),
19729
19739
  /* @__PURE__ */ jsx("div", {
19730
- className: "grow pl-[40px]",
19740
+ className: "pl-8",
19731
19741
  children: description && /* @__PURE__ */ jsx(Typography, {
19732
19742
  variant: "caption",
19733
19743
  color: "secondary",
@@ -19739,19 +19749,10 @@ var NavigationCard = React.memo(function NavigationCard({ name, description, ico
19739
19749
  })
19740
19750
  }),
19741
19751
  additionalContent && /* @__PURE__ */ jsx("div", {
19742
- className: "pl-[40px] pointer-events-none",
19752
+ className: "pl-8 pointer-events-none",
19743
19753
  children: additionalContent
19744
19754
  }),
19745
- /* @__PURE__ */ jsx("div", {
19746
- className: "self-end mt-1",
19747
- children: /* @__PURE__ */ jsx("div", {
19748
- className: "transition-transform duration-200 group-hover:translate-x-0.5",
19749
- children: /* @__PURE__ */ jsx(ArrowRightIcon, {
19750
- className: "text-primary",
19751
- size: iconSize.small
19752
- })
19753
- })
19754
- })
19755
+ /* @__PURE__ */ jsx("div", { className: "grow" })
19755
19756
  ]
19756
19757
  })
19757
19758
  });
@@ -20859,8 +20860,8 @@ function CustomViewRoute({ view }) {
20859
20860
  }
20860
20861
  //#endregion
20861
20862
  //#region src/components/CollectionEditorDialogs.tsx
20862
- var CollectionEditorDialog = lazy(() => import("./CollectionEditorDialog-jA-PLh6N.js").then((n) => n.r).then((m) => ({ default: m.CollectionEditorDialog })));
20863
- var PropertyFormDialog = lazy(() => import("./PropertyEditView-DEUddmg_.js").then((n) => n.t).then((m) => ({ default: m.PropertyFormDialog })));
20863
+ var CollectionEditorDialog = lazy(() => import("./CollectionEditorDialog-HNXGxXdO.js").then((n) => n.r).then((m) => ({ default: m.CollectionEditorDialog })));
20864
+ var PropertyFormDialog = lazy(() => import("./PropertyEditView-C2wp8kQ9.js").then((n) => n.t).then((m) => ({ default: m.PropertyFormDialog })));
20864
20865
  /**
20865
20866
  * Renders the CollectionEditorDialog and PropertyFormDialog inside
20866
20867
  * the RebaseShell tree where CMS-internal contexts
@@ -24007,4 +24008,4 @@ function getFullIdPath(propertyKey, propertyNamespace) {
24007
24008
  //#endregion
24008
24009
  export { useApp as $, getBracketNotation as $n, SideDialogs as $t, KeyValuePreview as A, useSideDialogsController as An, RepeatFieldBinding as At, RebaseRouteDefs as B, SelectableTableContext as Bn, ArrayContainer as Bt, zodToFormErrors as C, useCMSContext as Cn, getFieldConfig as Ct, NumberPropertyPreview as D, useNavigationStateController as Dn, SwitchFieldBinding as Dt, UserPreview as E, NavigationStateContext as En, TextFieldBinding as Et, ArrayEnumPreview as F, useSelectionController as Fn, MapFieldBinding as Ft, useLocalCollectionsConfigController as G, resolveEntityAction as Gn, FormEntry as Gt, RebaseRoute as H, useSideEntityController as Hn, PropertyFieldBinding as Ht, ArrayOfStorageComponentsPreview as I, EntityCollectionTable as In, KeyValueFieldBinding as It, Scaffold as J, ArrayOfReferencesPreview as Jn, LabelWithIcon as Jt, RebaseAuthGate as K, resolveEntityView as Kn, LabelWithIconAndTooltip as Kt, RelationPreview as L, SelectableTable as Ln, DateTimeFieldBinding as Lt, ArrayOneOfPreview as M, getEntityViewWidth as Mn, ReferenceAsStringFieldBinding as Mt, ArrayOfStringsPreview as N, useBuildSideEntityController as Nn, MultiSelectFieldBinding as Nt, BooleanPreview as O, CollectionRegistryContext as On, StorageUploadFieldBinding as Ot, ArrayPropertyEnumPreview as P, mergeEntityActions as Pn, MarkdownEditorFieldBinding as Pt, AppBar as Q, getEntityTitlePropertyKey as Qn, EntitySelectionTable as Qt, CollectionPanel as R, EntityCollectionRowActions as Rn, BlockFieldBinding as Rt, EntityForm as S, useResolvedNavigationFrom as Sn, getDefaultFieldId as St, PropertyPreview as T, useUrlController as Tn, VectorFieldBinding as Tt, RebaseLayout as U, useEntitySelectionDialog as Un, ReadOnlyFieldBinding as Ut, CustomViewRoute as V, SideEntityControllerContext as Vn, ArrayCustomShapedFieldBinding as Vt, RebaseNavigation as W, VirtualTableInput as Wn, FormLayout as Wt, DefaultDrawer as X, EntityPreview as Xn, SearchIconsView as Xt, Drawer as Y, ReferencePreview as Yn, FieldHelperText as Yt, DrawerFooterActions as Z, getEntityPreviewKeys as Zn, FieldCaption as Zt, getEntityCSVExportableData as _, removeTrailingSlash as _n, renderSkeletonText as _r, convertFileToJson as _t, namespaceToPropertiesPath as a, useResolvedCollections as an, getResolvedPropertyInPath as ar, EntityCard as at, ImportDataPreview as b, useEntityHistory as bn, ImagePreview as br, DEFAULT_FIELD_CONFIGS as bt, DEFAULT_COLLECTION_GENERATION_ENDPOINT as c, editEntityAction as cn, ArrayPropertyPreview as cr, ImportNewPropertyFieldPreview as ct, useCollectionsConfigController as d, addInitialSlash as dn, StorageThumbnail as dr, flattenEntry as dt, useBreadcrumbsController as en, getDefaultPropertiesOrder as er, AdminModeSyncer as et, ExportCollectionAction as f, getCollectionBySlugWithin as fn, StorageThumbnailInternal as fr, processValueMapping as ft, downloadEntitiesExport as g, removeInitialSlash as gn, renderSkeletonImageThumbnail as gr, ImportFileUpload as gt, downloadDataAsCsv as h, removeInitialAndTrailingSlashes$1 as hn, renderSkeletonIcon as hr, ImportSaveInProgress as ht, namespaceToPropertiesOrderPath as i, useResolvedViews as in, getPropertyInPath as ir, EntityCollectionCardView as it, MapPropertyPreview as j, buildSidePanelsFromUrl as jn, ReferenceFieldBinding as jt, DatePreview as k, useCollectionRegistryController as kn, SelectFieldBinding as kt, buildCollectionGenerationCallback as l, resetPasswordAction as ln, StringPropertyPreview as lr, DataNewPropertiesMapping as lt, downloadBlob as m, getLastSegment$1 as mn, renderSkeletonCaptionText as mr, useImportConfig as mt, getFullIdPath as n, useBuildNavigationStateController as nn, getIconForWidget as nr, ReferenceWidget as nt, MissingReferenceWidget as o, copyEntityAction as on, isReferenceProperty as or, EntityCollectionViewActions as ot, BasicExportAction as p, getCollectionPathsCombinations as pn, SkeletonPropertyComponent as pr, getInferenceType as pt, RebaseCMS as q, EntityView as qn, PropertyIdCopyTooltip as qt, idToPropertiesPath as r, useTopLevelNavigation as rn, getPropertiesWithPropertiesOrder as rr, EntityCollectionView as rt, CollectionGenerationApiError as s, deleteEntityAction as sn, isRelationProperty as sr, useCollectionEditorController as st, getFullId as t, useBuildUrlController as tn, getIconForProperty as tr, SideEntityProvider as tt, validateCollectionJson as u, CreationResultDialog as un, EnumValuesChip as ur, convertDataToEntity as ut, getEntityJsonExportableData as v, resolveCollectionPathIds$1 as vn, UrlComponentPreview as vr, unflattenObject as vt, ArrayOfMapsPreview as w, UrlContext as wn, getFieldId as wt, PropertySelectEntry as x, resolveNavigationFrom as xn, EmptyValue as xr, getDefaultFieldConfig as xt, ImportCollectionAction as y, useBuildCollectionRegistryController as yn, sanitizeUrl as yr, PropertyConfigBadge as yt, RebaseShell as z, useClearRestoreValue as zn, ArrayOfReferencesFieldBinding as zt };
24009
24010
 
24010
- //# sourceMappingURL=src-BJ8fkM8y.js.map
24011
+ //# sourceMappingURL=src-BYniefVu.js.map