@firecms/core 3.0.0-canary.43 → 3.0.0-canary.45

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.
@@ -24,4 +24,4 @@ import { EntityCollectionTableProps } from "./EntityCollectionTableProps";
24
24
  * @see VirtualTable
25
25
  * @group Components
26
26
  */
27
- export declare const EntityCollectionTable: <M extends Record<string, any>, UserType extends User>({ forceFilter, actionsStart, actions, title, tableRowActionsBuilder, uniqueFieldValidator, getPropertyFor, onValueChange, selectionController, highlightedEntities, onEntityClick, onColumnResize, onSizeChanged, textSearchEnabled, hoverRow, inlineEditing, additionalFields, displayedColumnIds, defaultSize, properties, tableController, filterable, sortable, endAdornment, AddColumnComponent, AdditionalHeaderWidget, additionalIDHeaderWidget, emptyComponent, getIdColumnWidth, onTextSearchClick, textSearchLoading }: EntityCollectionTableProps<M>) => import("react/jsx-runtime").JSX.Element;
27
+ export declare const EntityCollectionTable: <M extends Record<string, any>, UserType extends User>({ className, forceFilter, actionsStart, actions, title, tableRowActionsBuilder, uniqueFieldValidator, getPropertyFor, onValueChange, selectionController, highlightedEntities, onEntityClick, onColumnResize, onSizeChanged, textSearchEnabled, hoverRow, inlineEditing, additionalFields, displayedColumnIds, defaultSize, properties, tableController, filterable, sortable, endAdornment, AddColumnComponent, AdditionalHeaderWidget, additionalIDHeaderWidget, emptyComponent, getIdColumnWidth, onTextSearchClick, textSearchLoading, enablePopupIcon }: EntityCollectionTableProps<M>) => import("react/jsx-runtime").JSX.Element;
@@ -5,6 +5,7 @@ import { OnCellValueChange, OnColumnResizeParams, UniqueFieldValidator } from ".
5
5
  * @group Collection components
6
6
  */
7
7
  export type EntityCollectionTableProps<M extends Record<string, any>, UserType extends User = User> = {
8
+ className?: string;
8
9
  /**
9
10
  * Display these entities as selected
10
11
  */
@@ -87,6 +88,7 @@ export type EntityCollectionTableProps<M extends Record<string, any>, UserType e
87
88
  getIdColumnWidth?: () => number;
88
89
  onTextSearchClick?: () => void;
89
90
  textSearchLoading?: boolean;
91
+ enablePopupIcon: boolean;
90
92
  };
91
93
  export type GetPropertyForProps<M extends Record<string, any>> = {
92
94
  propertyKey: string;
@@ -95,5 +97,5 @@ export type GetPropertyForProps<M extends Record<string, any>> = {
95
97
  };
96
98
  export type PropertyColumnConfig = {
97
99
  key: string;
98
- disabled: boolean;
100
+ disabled?: boolean;
99
101
  };
@@ -14,5 +14,6 @@ export interface PropertyTableCellProps<T extends CMSType> {
14
14
  entity: Entity<any>;
15
15
  path: string;
16
16
  disabled: boolean;
17
+ enablePopupIcon?: boolean;
17
18
  }
18
19
  export declare const PropertyTableCell: React.FunctionComponent<PropertyTableCellProps<any>>;
@@ -16,7 +16,7 @@ interface PopupFormFieldProps<M extends Record<string, any>> {
16
16
  * Callback when the value of a cell has been edited
17
17
  * @param params
18
18
  */
19
- onCellValueChange?: (params: OnCellValueChangeParams<any, M>) => Promise<void> | void;
19
+ onCellValueChange?: (params: OnCellValueChangeParams<any, any>) => Promise<void> | void;
20
20
  }
21
21
  export declare function PopupFormField<M extends Record<string, any>>(props: PopupFormFieldProps<M>): import("react/jsx-runtime").JSX.Element | null;
22
22
  export declare function PopupFormFieldInternal<M extends Record<string, any>>({ tableKey, entity: entityProp, customFieldValidator, propertyKey, collection: inputCollection, path, cellRect, open, onClose, onCellValueChange, container }: PopupFormFieldProps<M>): import("react/jsx-runtime").JSX.Element;
@@ -1,7 +1,7 @@
1
1
  import React from "react";
2
2
  import { User } from "../types";
3
3
  export type FireCMSAppBarProps<ADDITIONAL_PROPS = object> = {
4
- title: string;
4
+ title: React.ReactNode;
5
5
  /**
6
6
  * A component that gets rendered on the upper side of the main toolbar
7
7
  */
@@ -12,6 +12,7 @@ export type FireCMSAppBarProps<ADDITIONAL_PROPS = object> = {
12
12
  drawerOpen: boolean;
13
13
  className?: string;
14
14
  style?: React.CSSProperties;
15
+ logo?: string;
15
16
  user?: User;
16
17
  } & ADDITIONAL_PROPS;
17
18
  /**
@@ -23,4 +24,4 @@ export type FireCMSAppBarProps<ADDITIONAL_PROPS = object> = {
23
24
  * @param drawerOpen
24
25
  * @constructor
25
26
  */
26
- export declare const FireCMSAppBar: ({ title, endAdornment, startAdornment, drawerOpen, dropDownActions, includeDrawer, className, style, user: userProp }: FireCMSAppBarProps) => import("react/jsx-runtime").JSX.Element;
27
+ export declare const FireCMSAppBar: ({ title, endAdornment, startAdornment, drawerOpen, dropDownActions, includeDrawer, className, style, logo, user: userProp }: FireCMSAppBarProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,4 +1,4 @@
1
- import { CollectionSize, Entity, FireCMSContext, ResolvedProperty, SelectedCellProps } from "../../types";
1
+ import { CollectionSize, ResolvedProperty, SelectedCellProps } from "../../types";
2
2
  export type EntityCollectionTableController<M extends Record<string, any>> = {
3
3
  /**
4
4
  * This cell is displayed as selected
@@ -28,14 +28,12 @@ export type EntityCollectionTableController<M extends Record<string, any>> = {
28
28
  * Props passed in a callback when the content of a cell in a table has been edited
29
29
  * @group Collection components
30
30
  */
31
- export interface OnCellValueChangeParams<T = any, M extends Record<string, any> = any> {
31
+ export interface OnCellValueChangeParams<T = any, D = any> {
32
32
  value: T;
33
33
  propertyKey: string;
34
- entity: Entity<M>;
34
+ data?: D;
35
35
  onValueUpdated: () => void;
36
36
  setError: (e: Error | undefined) => void;
37
- fullPath: string;
38
- context: FireCMSContext;
39
37
  }
40
38
  /**
41
39
  * @group Collection components
@@ -6,7 +6,7 @@ export type NavigationRoutesProps = {
6
6
  /**
7
7
  * In case you need to override the home page
8
8
  */
9
- HomePage?: React.ComponentType;
9
+ homePage?: React.ReactNode;
10
10
  customRoutes?: React.ReactNode[];
11
11
  };
12
12
  /**
@@ -9,7 +9,7 @@ export interface ScaffoldProps<ExtraDrawerProps = object, ExtraAppbarProps = obj
9
9
  /**
10
10
  * Name of the app, displayed as the main title and in the tab title
11
11
  */
12
- name: string;
12
+ name: React.ReactNode;
13
13
  /**
14
14
  * Logo to be displayed in the drawer of the CMS
15
15
  */
@@ -1,9 +1,8 @@
1
- import { DataSource, Entity, EntityCallbacks, EntityCollection, FireCMSContext, SaveEntityProps, User } from "../../types";
1
+ import { DataSource, Entity, EntityCollection, FireCMSContext, SaveEntityProps, User } from "../../types";
2
2
  /**
3
3
  * @group Hooks and utilities
4
4
  */
5
5
  export type SaveEntityWithCallbacksProps<M extends Record<string, any>> = SaveEntityProps<M> & {
6
- callbacks?: EntityCallbacks<M>;
7
6
  onSaveSuccess?: (updatedEntity: Entity<M>) => void;
8
7
  onSaveFailure?: (e: Error) => void;
9
8
  onPreSaveHookError?: (e: Error) => void;