@firecms/core 3.0.0-canary.167 → 3.0.0-canary.168

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.
@@ -12,7 +12,7 @@ export interface DialogsController {
12
12
  * Open a dialog
13
13
  * @param props
14
14
  */
15
- open: (props: DialogControllerEntryProps) => {
15
+ open: <T extends object = object>(props: DialogControllerEntryProps<T>) => {
16
16
  closeDialog: () => void;
17
17
  };
18
18
  }
@@ -20,7 +20,7 @@ export interface DialogsController {
20
20
  * Props used to open a side dialog
21
21
  * @group Hooks and utilities
22
22
  */
23
- export interface DialogControllerEntryProps<T extends object = {}> {
23
+ export interface DialogControllerEntryProps<T extends object = object> {
24
24
  key: string;
25
25
  /**
26
26
  * The component type that will be rendered
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@firecms/core",
3
3
  "type": "module",
4
- "version": "3.0.0-canary.167",
4
+ "version": "3.0.0-canary.168",
5
5
  "description": "Awesome Firebase/Firestore-based headless open-source CMS",
6
6
  "funding": {
7
7
  "url": "https://github.com/sponsors/firecmsco"
@@ -50,9 +50,9 @@
50
50
  "./package.json": "./package.json"
51
51
  },
52
52
  "dependencies": {
53
- "@firecms/editor": "^3.0.0-canary.167",
54
- "@firecms/formex": "^3.0.0-canary.167",
55
- "@firecms/ui": "^3.0.0-canary.167",
53
+ "@firecms/editor": "^3.0.0-canary.168",
54
+ "@firecms/formex": "^3.0.0-canary.168",
55
+ "@firecms/ui": "^3.0.0-canary.168",
56
56
  "@hello-pangea/dnd": "^17.0.0",
57
57
  "@radix-ui/react-portal": "^1.1.2",
58
58
  "clsx": "^2.1.1",
@@ -106,7 +106,7 @@
106
106
  "dist",
107
107
  "src"
108
108
  ],
109
- "gitHead": "86c9b7ff34991bf0424764845936b002e1071560",
109
+ "gitHead": "81a6eef43477c31b82713fc044e4836838ed74bb",
110
110
  "publishConfig": {
111
111
  "access": "public"
112
112
  },
@@ -8,7 +8,7 @@ export const DialogsProvider: React.FC<PropsWithChildren<{}>> = ({ children }) =
8
8
  const [dialogEntries, setDialogEntries] = useState<DialogControllerEntryProps[]>([]);
9
9
  const dialogEntriesRef = useRef<DialogControllerEntryProps[]>(dialogEntries);
10
10
 
11
- const updateDialogEntries = (newPanels: DialogControllerEntryProps[]) => {
11
+ const updateDialogEntries = (newPanels: DialogControllerEntryProps<any>[]) => {
12
12
  dialogEntriesRef.current = newPanels;
13
13
  setDialogEntries(newPanels);
14
14
  };
@@ -23,7 +23,7 @@ export const DialogsProvider: React.FC<PropsWithChildren<{}>> = ({ children }) =
23
23
 
24
24
  }, [dialogEntries]);
25
25
 
26
- const open = useCallback((dialogEntry: DialogControllerEntryProps) => {
26
+ const open = useCallback(<T extends object = object>(dialogEntry: DialogControllerEntryProps<T>) => {
27
27
 
28
28
  const updatedPanels = [...dialogEntriesRef.current, dialogEntry];
29
29
  updateDialogEntries(updatedPanels);
@@ -15,14 +15,14 @@ export interface DialogsController {
15
15
  * Open a dialog
16
16
  * @param props
17
17
  */
18
- open: (props: DialogControllerEntryProps) => { closeDialog: () => void };
18
+ open: <T extends object = object>(props: DialogControllerEntryProps<T>) => { closeDialog: () => void };
19
19
  }
20
20
 
21
21
  /**
22
22
  * Props used to open a side dialog
23
23
  * @group Hooks and utilities
24
24
  */
25
- export interface DialogControllerEntryProps<T extends object = {}> {
25
+ export interface DialogControllerEntryProps<T extends object = object> {
26
26
 
27
27
  key: string;
28
28
  /**