@firecms/core 3.0.0-canary.175 → 3.0.0-canary.177

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.
@@ -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, minimalistView, 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: minimalistViewProp, 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, minimalistView, property, includeDescription, setValue, setFieldValue }: ArrayOfReferencesFieldProps): import("react/jsx-runtime").JSX.Element;
10
+ export declare function ArrayOfReferencesFieldBinding({ propertyKey, value, error, showError, disabled, isSubmitting, minimalistView: minimalistViewProp, 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, minimalistView, 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: minimalistViewProp, property, includeDescription, underlyingValueHasChanged, context, disabled }: FieldProps<T>): 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, minimalistView, includeDescription, underlyingValueHasChanged, autoFocus, context, onPropertyChange }: FieldProps<Record<string, any>>): import("react/jsx-runtime").JSX.Element;
9
+ export declare function MapFieldBinding({ propertyKey, value, showError, error, disabled, property, minimalistView: minimalistViewProp, includeDescription, underlyingValueHasChanged, autoFocus, context, onPropertyChange }: FieldProps<Record<string, 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, minimalistView, 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: minimalistViewProp, property, includeDescription, underlyingValueHasChanged, context, disabled }: FieldProps<T>): import("react/jsx-runtime").JSX.Element;
package/dist/index.es.js CHANGED
@@ -11531,7 +11531,7 @@ function FormLayout(t0) {
11531
11531
  } = t0;
11532
11532
  let t1;
11533
11533
  if ($[0] !== className) {
11534
- t1 = cls("relative flex flex-row max-w-4xl lg:max-w-3xl xl:max-w-4xl 2xl:max-w-5xl w-full h-fit", className);
11534
+ t1 = cls("relative flex flex-row max-w-4xl lg:max-w-3xl xl:max-w-5xl 2xl:max-w-7xl w-full h-fit", className);
11535
11535
  $[0] = className;
11536
11536
  $[1] = t1;
11537
11537
  } else {
@@ -11864,7 +11864,7 @@ function EntityEditViewInner({
11864
11864
  };
11865
11865
  const resolvedEntityViews = customViews ? customViews.map((e_4) => resolveEntityView(e_4, customizationController.entityViews)).filter(Boolean) : [];
11866
11866
  const selectedEntityView = resolvedEntityViews.find((e_5) => e_5.key === selectedTab);
11867
- const shouldShowEntityActions = !autoSave && (selectedTab === MAIN_TAB_VALUE || selectedEntityView?.includeActions);
11867
+ const shouldShowEntityActions = selectedTab === MAIN_TAB_VALUE || selectedEntityView?.includeActions;
11868
11868
  const secondaryForms = customViews && resolvedEntityViews.filter((e_6) => e_6.includeActions).map((customView, colIndex) => {
11869
11869
  if (!customView) return null;
11870
11870
  const Builder = customView.Builder;
@@ -12225,7 +12225,7 @@ function buildSideActions({
12225
12225
  setPendingClose,
12226
12226
  pluginActions
12227
12227
  }) {
12228
- return /* @__PURE__ */ jsxs("div", { className: cls("overflow-auto h-full flex flex-col gap-2 w-96 px-4 py-16 sticky top-0 border-l", defaultBorderMixin), children: [
12228
+ return /* @__PURE__ */ jsxs("div", { className: cls("overflow-auto h-full flex flex-col gap-2 w-80 xl:w-96 px-4 py-16 sticky top-0 border-l", defaultBorderMixin), children: [
12229
12229
  /* @__PURE__ */ jsxs(LoadingButton, { fullWidth: true, variant: "filled", color: "primary", type: "submit", size: "large", disabled: disabled || isSubmitting, onClick: () => {
12230
12230
  setPendingClose?.(false);
12231
12231
  }, children: [
@@ -17277,12 +17277,13 @@ function ArrayOfReferencesFieldBinding({
17277
17277
  showError,
17278
17278
  disabled,
17279
17279
  isSubmitting,
17280
- minimalistView,
17280
+ minimalistView: minimalistViewProp,
17281
17281
  property,
17282
17282
  includeDescription,
17283
17283
  setValue,
17284
17284
  setFieldValue
17285
17285
  }) {
17286
+ const minimalistView = minimalistViewProp || property.minimalistView;
17286
17287
  const ofProperty = property.of;
17287
17288
  if (ofProperty.dataType !== "reference") {
17288
17289
  throw Error("ArrayOfReferencesField expected a property containing references");
@@ -18696,7 +18697,7 @@ function MapFieldBinding(t0) {
18696
18697
  error,
18697
18698
  disabled,
18698
18699
  property,
18699
- minimalistView,
18700
+ minimalistView: minimalistViewProp,
18700
18701
  includeDescription,
18701
18702
  underlyingValueHasChanged,
18702
18703
  autoFocus,
@@ -18705,6 +18706,7 @@ function MapFieldBinding(t0) {
18705
18706
  } = t0;
18706
18707
  const pickOnlySomeKeys = property.pickOnlySomeKeys || false;
18707
18708
  const expanded = property.expanded === void 0 ? true : property.expanded;
18709
+ const minimalistView = minimalistViewProp || property.minimalistView;
18708
18710
  if (!property.properties) {
18709
18711
  throw Error(`You need to specify a 'properties' prop (or specify a custom field) in your map property ${propertyKey}`);
18710
18712
  }
@@ -19636,21 +19638,34 @@ function RepeatFieldBinding(t0) {
19636
19638
  let underlyingValueHasChanged;
19637
19639
  let value;
19638
19640
  if ($[0] !== t0) {
19639
- ({
19640
- propertyKey,
19641
- value,
19642
- error,
19643
- showError,
19644
- isSubmitting,
19645
- setValue,
19646
- setFieldValue,
19647
- minimalistView,
19648
- property,
19649
- includeDescription,
19650
- underlyingValueHasChanged,
19651
- context,
19652
- disabled
19653
- } = t0);
19641
+ const {
19642
+ propertyKey: t19,
19643
+ value: t22,
19644
+ error: t32,
19645
+ showError: t42,
19646
+ isSubmitting: t52,
19647
+ setValue: t62,
19648
+ setFieldValue: t72,
19649
+ minimalistView: minimalistViewProp,
19650
+ property: t82,
19651
+ includeDescription: t92,
19652
+ underlyingValueHasChanged: t102,
19653
+ context: t112,
19654
+ disabled: t122
19655
+ } = t0;
19656
+ propertyKey = t19;
19657
+ value = t22;
19658
+ error = t32;
19659
+ showError = t42;
19660
+ isSubmitting = t52;
19661
+ setValue = t62;
19662
+ setFieldValue = t72;
19663
+ property = t82;
19664
+ includeDescription = t92;
19665
+ underlyingValueHasChanged = t102;
19666
+ context = t112;
19667
+ disabled = t122;
19668
+ minimalistView = minimalistViewProp || property.minimalistView;
19654
19669
  if (!property.of) {
19655
19670
  throw Error("RepeatFieldBinding misconfiguration. Property `of` not set");
19656
19671
  }
@@ -19879,13 +19894,14 @@ function BlockFieldBinding({
19879
19894
  isSubmitting,
19880
19895
  setValue,
19881
19896
  setFieldValue,
19882
- minimalistView,
19897
+ minimalistView: minimalistViewProp,
19883
19898
  property,
19884
19899
  includeDescription,
19885
19900
  underlyingValueHasChanged,
19886
19901
  context,
19887
19902
  disabled
19888
19903
  }) {
19904
+ const minimalistView = minimalistViewProp || property.minimalistView;
19889
19905
  if (!property.oneOf) throw Error("ArrayOneOfField misconfiguration. Property `oneOf` not set");
19890
19906
  const expanded = property.expanded === void 0 ? true : property.expanded;
19891
19907
  useClearRestoreValue({
@@ -20323,13 +20339,14 @@ function ArrayCustomShapedFieldBinding(t0) {
20323
20339
  error,
20324
20340
  showError,
20325
20341
  setValue,
20326
- minimalistView,
20342
+ minimalistView: minimalistViewProp,
20327
20343
  property,
20328
20344
  includeDescription,
20329
20345
  underlyingValueHasChanged,
20330
20346
  context,
20331
20347
  disabled
20332
20348
  } = t0;
20349
+ const minimalistView = minimalistViewProp || property.minimalistView;
20333
20350
  let resolvedProperties = "resolvedProperties" in property ? property.resolvedProperties : void 0;
20334
20351
  if (!resolvedProperties) {
20335
20352
  let t12;