@firecms/core 3.0.0-canary.101 → 3.0.0-canary.103

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 (56) hide show
  1. package/dist/components/EntityCollectionTable/internal/popup_field/PopupFormField.d.ts +1 -1
  2. package/dist/form/PropertyFieldBinding.d.ts +1 -1
  3. package/dist/form/field_bindings/ArrayCustomShapedFieldBinding.d.ts +1 -1
  4. package/dist/form/field_bindings/ArrayOfReferencesFieldBinding.d.ts +1 -1
  5. package/dist/form/field_bindings/BlockFieldBinding.d.ts +1 -1
  6. package/dist/form/field_bindings/KeyValueFieldBinding.d.ts +1 -1
  7. package/dist/form/field_bindings/MapFieldBinding.d.ts +1 -1
  8. package/dist/form/field_bindings/MarkdownEditorFieldBinding.d.ts +9 -0
  9. package/dist/form/field_bindings/ReadOnlyFieldBinding.d.ts +1 -1
  10. package/dist/form/field_bindings/RepeatFieldBinding.d.ts +1 -1
  11. package/dist/form/field_bindings/StorageUploadFieldBinding.d.ts +1 -1
  12. package/dist/form/index.d.ts +2 -2
  13. package/dist/index.es.js +265 -817
  14. package/dist/index.es.js.map +1 -1
  15. package/dist/index.umd.js +264 -815
  16. package/dist/index.umd.js.map +1 -1
  17. package/dist/types/collections.d.ts +5 -0
  18. package/dist/types/datasource.d.ts +12 -12
  19. package/dist/types/entities.d.ts +1 -0
  20. package/dist/types/fields.d.ts +5 -13
  21. package/dist/util/index.d.ts +1 -0
  22. package/dist/util/storage.d.ts +1 -1
  23. package/package.json +5 -5
  24. package/src/app/Scaffold.tsx +1 -13
  25. package/src/components/EntityCollectionTable/PropertyTableCell.tsx +4 -2
  26. package/src/components/EntityCollectionTable/internal/popup_field/PopupFormField.tsx +3 -5
  27. package/src/components/EntityCollectionView/EntityCollectionView.tsx +4 -4
  28. package/src/components/common/useTableSearchHelper.ts +1 -0
  29. package/src/core/DefaultDrawer.tsx +1 -1
  30. package/src/core/EntityEditView.tsx +3 -4
  31. package/src/core/field_configs.tsx +2 -2
  32. package/src/form/PropertyFieldBinding.tsx +4 -8
  33. package/src/form/field_bindings/ArrayCustomShapedFieldBinding.tsx +4 -5
  34. package/src/form/field_bindings/ArrayOfReferencesFieldBinding.tsx +3 -3
  35. package/src/form/field_bindings/BlockFieldBinding.tsx +5 -6
  36. package/src/form/field_bindings/KeyValueFieldBinding.tsx +5 -5
  37. package/src/form/field_bindings/MapFieldBinding.tsx +6 -8
  38. package/src/form/field_bindings/MarkdownEditorFieldBinding.tsx +133 -0
  39. package/src/form/field_bindings/ReadOnlyFieldBinding.tsx +5 -5
  40. package/src/form/field_bindings/RepeatFieldBinding.tsx +6 -7
  41. package/src/form/field_bindings/StorageUploadFieldBinding.tsx +2 -2
  42. package/src/form/index.tsx +2 -2
  43. package/src/hooks/data/save.ts +5 -1
  44. package/src/internal/useBuildDataSource.ts +29 -14
  45. package/src/preview/PropertyPreview.tsx +2 -2
  46. package/src/types/collections.ts +6 -0
  47. package/src/types/datasource.ts +13 -16
  48. package/src/types/entities.ts +2 -0
  49. package/src/types/fields.tsx +5 -15
  50. package/src/util/index.ts +1 -0
  51. package/src/util/storage.ts +1 -1
  52. package/src/util/useStorageUploadController.tsx +2 -2
  53. package/dist/form/PropertiesForm.d.ts +0 -8
  54. package/dist/form/field_bindings/MarkdownFieldBinding.d.ts +0 -9
  55. package/src/form/PropertiesForm.tsx +0 -81
  56. package/src/form/field_bindings/MarkdownFieldBinding.tsx +0 -695
@@ -2,7 +2,7 @@ import { Entity, EntityCollection } from "../../../../types";
2
2
  import { CustomFieldValidator } from "../../../../form/validation";
3
3
  import { OnCellValueChangeParams } from "../../../common";
4
4
  interface PopupFormFieldProps<M extends Record<string, any>> {
5
- entity?: Entity<M>;
5
+ entity: Entity<M>;
6
6
  customFieldValidator?: CustomFieldValidator;
7
7
  path: string;
8
8
  tableKey: string;
@@ -26,5 +26,5 @@ import { CMSType, PropertyFieldBindingProps } from "../types";
26
26
  * @group Form custom fields
27
27
  */
28
28
  export declare const PropertyFieldBinding: typeof PropertyFieldBindingInternal;
29
- declare function PropertyFieldBindingInternal<T extends CMSType = CMSType, M extends Record<string, any> = Record<string, any>>({ propertyKey, property, context, includeDescription, underlyingValueHasChanged, disabled, tableMode, partOfArray, partOfBlock, autoFocus, index, }: PropertyFieldBindingProps<T, M>): ReactElement<PropertyFieldBindingProps<T, M>>;
29
+ declare function PropertyFieldBindingInternal<T extends CMSType = CMSType, M extends Record<string, any> = Record<string, any>>({ propertyKey, property, context, includeDescription, underlyingValueHasChanged, disabled, partOfArray, minimalistView, autoFocus, index, }: PropertyFieldBindingProps<T, M>): ReactElement<PropertyFieldBindingProps<T, M>>;
30
30
  export {};
@@ -6,4 +6,4 @@ import { FieldProps } from "../../types";
6
6
  * and tables to the specified properties.
7
7
  * @group Form fields
8
8
  */
9
- export declare function ArrayCustomShapedFieldBinding<T extends Array<any>>({ propertyKey, value, error, showError, isSubmitting, setValue, tableMode, property, includeDescription, underlyingValueHasChanged, context, disabled }: FieldProps<T, any, any>): import("react/jsx-runtime").JSX.Element;
9
+ export declare function ArrayCustomShapedFieldBinding<T extends Array<any>>({ propertyKey, value, error, showError, isSubmitting, setValue, minimalistView, property, includeDescription, underlyingValueHasChanged, context, disabled }: FieldProps<T, any, any>): import("react/jsx-runtime").JSX.Element;
@@ -7,5 +7,5 @@ type ArrayOfReferencesFieldProps = FieldProps<EntityReference[]>;
7
7
  * and tables to the specified properties.
8
8
  * @group Form fields
9
9
  */
10
- export declare function ArrayOfReferencesFieldBinding({ propertyKey, value, error, showError, disabled, isSubmitting, tableMode, property, includeDescription, setValue, setFieldValue }: ArrayOfReferencesFieldProps): import("react/jsx-runtime").JSX.Element;
10
+ export declare function ArrayOfReferencesFieldBinding({ propertyKey, value, error, showError, disabled, isSubmitting, minimalistView, property, includeDescription, setValue, setFieldValue }: ArrayOfReferencesFieldProps): import("react/jsx-runtime").JSX.Element;
11
11
  export {};
@@ -7,4 +7,4 @@ import { FieldProps } from "../../types";
7
7
  * and tables to the specified properties.
8
8
  * @group Form fields
9
9
  */
10
- export declare function BlockFieldBinding<T extends Array<any>>({ propertyKey, value, error, showError, isSubmitting, setValue, setFieldValue, tableMode, property, includeDescription, underlyingValueHasChanged, context, disabled }: FieldProps<T>): import("react/jsx-runtime").JSX.Element;
10
+ export declare function BlockFieldBinding<T extends Array<any>>({ propertyKey, value, error, showError, isSubmitting, setValue, setFieldValue, minimalistView, property, includeDescription, underlyingValueHasChanged, context, disabled }: FieldProps<T>): import("react/jsx-runtime").JSX.Element;
@@ -4,4 +4,4 @@ import { FieldProps } from "../../types";
4
4
  *
5
5
  * @group Form fields
6
6
  */
7
- export declare function KeyValueFieldBinding({ propertyKey, value, showError, error, disabled, property, setValue, tableMode, includeDescription, underlyingValueHasChanged, autoFocus, context }: FieldProps<Record<string, any>>): import("react/jsx-runtime").JSX.Element;
7
+ export declare function KeyValueFieldBinding({ propertyKey, value, showError, error, disabled, property, setValue, minimalistView, includeDescription, underlyingValueHasChanged, autoFocus, context }: FieldProps<Record<string, any>>): import("react/jsx-runtime").JSX.Element;
@@ -6,4 +6,4 @@ import { FieldProps } from "../../types";
6
6
  * and tables to the specified properties.
7
7
  * @group Form fields
8
8
  */
9
- export declare function MapFieldBinding({ propertyKey, value, showError, error, disabled, property, partOfBlock, tableMode, includeDescription, underlyingValueHasChanged, autoFocus, context }: FieldProps<Record<string, any>>): import("react/jsx-runtime").JSX.Element;
9
+ export declare function MapFieldBinding({ propertyKey, value, showError, error, disabled, property, minimalistView, includeDescription, underlyingValueHasChanged, autoFocus, context }: FieldProps<Record<string, any>>): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,9 @@
1
+ import { FieldProps } from "../../index";
2
+ interface MarkdownEditorFieldProps {
3
+ highlight?: {
4
+ from: number;
5
+ to: number;
6
+ };
7
+ }
8
+ export declare function MarkdownEditorFieldBinding({ property, propertyKey, value, setValue, includeDescription, showError, error, minimalistView, isSubmitting, context, customProps, ...props }: FieldProps<string, MarkdownEditorFieldProps>): import("react/jsx-runtime").JSX.Element;
9
+ export {};
@@ -7,4 +7,4 @@ import { FieldProps } from "../../types";
7
7
  * and tables to the specified properties.
8
8
  * @group Form fields
9
9
  */
10
- export declare function ReadOnlyFieldBinding({ propertyKey, value, error, showError, tableMode, property, includeDescription, context }: FieldProps<any>): import("react/jsx-runtime").JSX.Element;
10
+ export declare function ReadOnlyFieldBinding({ propertyKey, value, error, showError, minimalistView, property, includeDescription, context }: FieldProps<any>): import("react/jsx-runtime").JSX.Element;
@@ -7,4 +7,4 @@ import { FieldProps } from "../../types";
7
7
  * and tables to the specified properties.
8
8
  * @group Form fields
9
9
  */
10
- export declare function RepeatFieldBinding<T extends Array<any>>({ propertyKey, value, error, showError, isSubmitting, setValue, setFieldValue, tableMode, property, includeDescription, underlyingValueHasChanged, context, disabled }: FieldProps<T>): import("react/jsx-runtime").JSX.Element;
10
+ export declare function RepeatFieldBinding<T extends Array<any>>({ propertyKey, value, error, showError, isSubmitting, setValue, setFieldValue, minimalistView, property, includeDescription, underlyingValueHasChanged, context, disabled }: FieldProps<T>): import("react/jsx-runtime").JSX.Element;
@@ -8,7 +8,7 @@ type StorageUploadFieldProps = FieldProps<string | string[]>;
8
8
  * and tables to the specified properties.
9
9
  * @group Form fields
10
10
  */
11
- export declare function StorageUploadFieldBinding({ propertyKey, value, setValue, error, showError, autoFocus, tableMode, property, includeDescription, context, isSubmitting, }: StorageUploadFieldProps): import("react/jsx-runtime").JSX.Element;
11
+ export declare function StorageUploadFieldBinding({ propertyKey, value, setValue, error, showError, autoFocus, minimalistView, property, includeDescription, context, isSubmitting, }: StorageUploadFieldProps): import("react/jsx-runtime").JSX.Element;
12
12
  export interface StorageUploadProps {
13
13
  value: StorageFieldItem[];
14
14
  setInternalValue: (v: StorageFieldItem[]) => void;
@@ -11,9 +11,9 @@ import { KeyValueFieldBinding } from "./field_bindings/KeyValueFieldBinding";
11
11
  import { RepeatFieldBinding } from "./field_bindings/RepeatFieldBinding";
12
12
  import { BlockFieldBinding } from "./field_bindings/BlockFieldBinding";
13
13
  import { ReadOnlyFieldBinding } from "./field_bindings/ReadOnlyFieldBinding";
14
- import { MarkdownFieldBinding } from "./field_bindings/MarkdownFieldBinding";
14
+ import { MarkdownEditorFieldBinding } from "./field_bindings/MarkdownEditorFieldBinding";
15
15
  import { ArrayCustomShapedFieldBinding } from "./field_bindings/ArrayCustomShapedFieldBinding";
16
- export { ArrayCustomShapedFieldBinding, RepeatFieldBinding, MultiSelectBinding, ArrayOfReferencesFieldBinding, BlockFieldBinding, DateTimeFieldBinding, ReadOnlyFieldBinding, MapFieldBinding, KeyValueFieldBinding, ReferenceFieldBinding, SelectFieldBinding, StorageUploadFieldBinding, SwitchFieldBinding, MarkdownFieldBinding, TextFieldBinding };
16
+ export { ArrayCustomShapedFieldBinding, RepeatFieldBinding, MultiSelectBinding, ArrayOfReferencesFieldBinding, BlockFieldBinding, DateTimeFieldBinding, ReadOnlyFieldBinding, MapFieldBinding, KeyValueFieldBinding, ReferenceFieldBinding, SelectFieldBinding, StorageUploadFieldBinding, SwitchFieldBinding, MarkdownEditorFieldBinding, TextFieldBinding };
17
17
  export * from "./components";
18
18
  export { PropertyFieldBinding } from "./PropertyFieldBinding";
19
19
  export * from "./useClearRestoreValue";