@firecms/core 3.0.0-canary.105 → 3.0.0-canary.106
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.
- package/dist/form/PropertyFieldBinding.d.ts +1 -1
- package/dist/form/field_bindings/MultiSelectBinding.d.ts +1 -1
- package/dist/form/field_bindings/SelectFieldBinding.d.ts +1 -1
- package/dist/form/field_bindings/TextFieldBinding.d.ts +1 -1
- package/dist/index.es.js +50 -38
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +50 -38
- package/dist/index.umd.js.map +1 -1
- package/dist/preview/PropertyPreviewProps.d.ts +1 -1
- package/dist/preview/components/EnumValuesChip.d.ts +1 -1
- package/dist/types/fields.d.ts +8 -0
- package/package.json +5 -5
- package/src/components/EntityCollectionTable/fields/TableReferenceField.tsx +1 -1
- package/src/components/EntityCollectionView/EntityCollectionView.tsx +1 -1
- package/src/components/EntityPreview.tsx +7 -7
- package/src/form/PropertyFieldBinding.tsx +11 -4
- package/src/form/field_bindings/MultiSelectBinding.tsx +2 -0
- package/src/form/field_bindings/ReferenceFieldBinding.tsx +3 -3
- package/src/form/field_bindings/SelectFieldBinding.tsx +5 -3
- package/src/form/field_bindings/SwitchFieldBinding.tsx +2 -2
- package/src/form/field_bindings/TextFieldBinding.tsx +3 -1
- package/src/preview/PropertyPreviewProps.tsx +1 -1
- package/src/preview/components/BooleanPreview.tsx +1 -1
- package/src/preview/components/EnumValuesChip.tsx +1 -1
- package/src/preview/components/ImagePreview.tsx +1 -1
- package/src/preview/components/UrlComponentPreview.tsx +1 -1
- package/src/preview/property_previews/ArrayOfReferencesPreview.tsx +1 -1
- package/src/preview/property_previews/ArrayOfStorageComponentsPreview.tsx +1 -1
- package/src/preview/property_previews/ArrayOneOfPreview.tsx +1 -1
- package/src/preview/property_previews/ArrayPropertyPreview.tsx +1 -1
- package/src/preview/property_previews/MapPropertyPreview.tsx +1 -1
- package/src/preview/property_previews/SkeletonPropertyComponent.tsx +2 -2
- package/src/preview/property_previews/StringPropertyPreview.tsx +2 -2
- package/src/preview/util.ts +2 -2
- package/src/types/fields.tsx +10 -0
|
@@ -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, partOfArray, minimalistView, 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, size }: PropertyFieldBindingProps<T, M>): ReactElement<PropertyFieldBindingProps<T, M>>;
|
|
30
30
|
export {};
|
|
@@ -6,4 +6,4 @@ import { EnumType, FieldProps } from "../../types";
|
|
|
6
6
|
* and tables to the specified properties.
|
|
7
7
|
* @group Form fields
|
|
8
8
|
*/
|
|
9
|
-
export declare function MultiSelectBinding({ propertyKey, value, setValue, error, showError, disabled, property, includeDescription, autoFocus }: FieldProps<EnumType[], any, any>): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export declare function MultiSelectBinding({ propertyKey, value, setValue, error, showError, disabled, property, includeDescription, size, autoFocus }: FieldProps<EnumType[], any, any>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -8,5 +8,5 @@ type SelectProps<T extends EnumType> = FieldProps<T>;
|
|
|
8
8
|
* and tables to the specified properties.
|
|
9
9
|
* @group Form fields
|
|
10
10
|
*/
|
|
11
|
-
export declare function SelectFieldBinding<T extends EnumType>({ propertyKey, value, setValue, error, showError, disabled, autoFocus, touched, property, includeDescription }: SelectProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export declare function SelectFieldBinding<T extends EnumType>({ propertyKey, value, setValue, error, showError, disabled, autoFocus, touched, property, includeDescription, size }: SelectProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
12
12
|
export {};
|
|
@@ -8,5 +8,5 @@ interface TextFieldBindingProps<T extends string | number> extends FieldProps<T>
|
|
|
8
8
|
* and tables to the specified properties.
|
|
9
9
|
* @group Form fields
|
|
10
10
|
*/
|
|
11
|
-
export declare function TextFieldBinding<T extends string | number>({ context, propertyKey, value, setValue, error, showError, disabled, autoFocus, property, includeDescription, }: TextFieldBindingProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export declare function TextFieldBinding<T extends string | number>({ context, propertyKey, value, setValue, error, showError, disabled, autoFocus, property, includeDescription, size }: TextFieldBindingProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
12
12
|
export {};
|
package/dist/index.es.js
CHANGED
|
@@ -4515,7 +4515,7 @@ const TINY_THUMBNAIL = 40;
|
|
|
4515
4515
|
const SMALL_THUMBNAIL = 100;
|
|
4516
4516
|
const REGULAR_THUMBNAIL = 200;
|
|
4517
4517
|
function getThumbnailMeasure(size) {
|
|
4518
|
-
if (size === "
|
|
4518
|
+
if (size === "smallest")
|
|
4519
4519
|
return TINY_THUMBNAIL;
|
|
4520
4520
|
else if (size === "small")
|
|
4521
4521
|
return SMALL_THUMBNAIL;
|
|
@@ -4527,7 +4527,7 @@ function getPreviewSizeFrom(size) {
|
|
|
4527
4527
|
switch (size) {
|
|
4528
4528
|
case "xs":
|
|
4529
4529
|
case "s":
|
|
4530
|
-
return "
|
|
4530
|
+
return "smallest";
|
|
4531
4531
|
case "m":
|
|
4532
4532
|
return "small";
|
|
4533
4533
|
case "l":
|
|
@@ -4542,7 +4542,7 @@ function ImagePreview({
|
|
|
4542
4542
|
url
|
|
4543
4543
|
}) {
|
|
4544
4544
|
const imageSize = useMemo(() => getThumbnailMeasure(size), [size]);
|
|
4545
|
-
if (size === "
|
|
4545
|
+
if (size === "smallest") {
|
|
4546
4546
|
return /* @__PURE__ */ jsx(
|
|
4547
4547
|
"img",
|
|
4548
4548
|
{
|
|
@@ -4710,7 +4710,7 @@ function VideoPreview({
|
|
|
4710
4710
|
interactive
|
|
4711
4711
|
}) {
|
|
4712
4712
|
const imageSize = useMemo(() => {
|
|
4713
|
-
if (size === "
|
|
4713
|
+
if (size === "smallest")
|
|
4714
4714
|
return "140px";
|
|
4715
4715
|
else if (size === "small")
|
|
4716
4716
|
return "240px";
|
|
@@ -4802,7 +4802,7 @@ function renderMap(property, size) {
|
|
|
4802
4802
|
mapPropertyKeys = property.previewProperties || Object.keys(property.properties);
|
|
4803
4803
|
if (size === "small")
|
|
4804
4804
|
mapPropertyKeys = mapPropertyKeys.slice(0, 3);
|
|
4805
|
-
else if (size === "
|
|
4805
|
+
else if (size === "smallest")
|
|
4806
4806
|
mapPropertyKeys = mapPropertyKeys.slice(0, 1);
|
|
4807
4807
|
}
|
|
4808
4808
|
if (size !== "medium")
|
|
@@ -4907,7 +4907,7 @@ function renderGenericArrayCell(property, index = 0) {
|
|
|
4907
4907
|
);
|
|
4908
4908
|
}
|
|
4909
4909
|
function renderSkeletonImageThumbnail(size) {
|
|
4910
|
-
const imageSize = size === "
|
|
4910
|
+
const imageSize = size === "smallest" ? 40 : size === "small" ? 100 : 200;
|
|
4911
4911
|
return /* @__PURE__ */ jsx(
|
|
4912
4912
|
Skeleton,
|
|
4913
4913
|
{
|
|
@@ -5072,10 +5072,10 @@ function StringPropertyPreview({
|
|
|
5072
5072
|
} else {
|
|
5073
5073
|
if (!value) return /* @__PURE__ */ jsx(Fragment, {});
|
|
5074
5074
|
const lines = value.split("\n");
|
|
5075
|
-
return value && value.includes("\n") ? /* @__PURE__ */ jsx("div", { className: cls("overflow-x-scroll", size === "
|
|
5075
|
+
return value && value.includes("\n") ? /* @__PURE__ */ jsx("div", { className: cls("overflow-x-scroll", size === "smallest" ? "text-sm" : ""), children: lines.map((str, index) => /* @__PURE__ */ jsxs(React__default.Fragment, { children: [
|
|
5076
5076
|
/* @__PURE__ */ jsx("span", { children: str }),
|
|
5077
5077
|
index !== lines.length - 1 && /* @__PURE__ */ jsx("br", {})
|
|
5078
|
-
] }, `string_preview_${index}`)) }) : size === "
|
|
5078
|
+
] }, `string_preview_${index}`)) }) : size === "smallest" ? /* @__PURE__ */ jsx("span", { className: "text-sm", children: value }) : /* @__PURE__ */ jsx(Fragment, { children: value });
|
|
5079
5079
|
}
|
|
5080
5080
|
}
|
|
5081
5081
|
function ArrayPropertyPreview({
|
|
@@ -5098,7 +5098,7 @@ function ArrayPropertyPreview({
|
|
|
5098
5098
|
throw Error("Picked wrong preview component ArrayPreview");
|
|
5099
5099
|
const values = value;
|
|
5100
5100
|
if (!values) return null;
|
|
5101
|
-
const childSize = size === "medium" ? "small" : "
|
|
5101
|
+
const childSize = size === "medium" ? "small" : "smallest";
|
|
5102
5102
|
return /* @__PURE__ */ jsx("div", { className: "flex flex-col gap-2", children: values && values.map(
|
|
5103
5103
|
(value2, index) => {
|
|
5104
5104
|
const of = property.resolvedProperties[index] ?? (property.resolvedProperties[index] ?? (Array.isArray(property.of) ? property.of[index] : property.of));
|
|
@@ -5161,17 +5161,17 @@ function EntityPreview({
|
|
|
5161
5161
|
hover: disabled ? void 0 : hover,
|
|
5162
5162
|
size,
|
|
5163
5163
|
children: [
|
|
5164
|
-
imageProperty && /* @__PURE__ */ jsx("div", { className: cls("w-10 h-10 mr-2 shrink-0 grow-0", size === "
|
|
5164
|
+
imageProperty && /* @__PURE__ */ jsx("div", { className: cls("w-10 h-10 mr-2 shrink-0 grow-0", size === "smallest" ? "my-0.5" : "m-2 self-start"), children: /* @__PURE__ */ jsx(
|
|
5165
5165
|
PropertyPreview,
|
|
5166
5166
|
{
|
|
5167
5167
|
property: imageProperty,
|
|
5168
5168
|
propertyKey: imagePropertyKey,
|
|
5169
|
-
size: "
|
|
5169
|
+
size: "smallest",
|
|
5170
5170
|
value: getValueInPath(entity.values, imagePropertyKey)
|
|
5171
5171
|
}
|
|
5172
5172
|
) }),
|
|
5173
5173
|
/* @__PURE__ */ jsxs("div", { className: "flex flex-col flex-grow w-full m-1", children: [
|
|
5174
|
-
size !== "
|
|
5174
|
+
size !== "smallest" && includeId && (entity ? /* @__PURE__ */ jsx("div", { className: `${size !== "medium" ? "block whitespace-nowrap overflow-hidden truncate" : ""}`, children: /* @__PURE__ */ jsx(
|
|
5175
5175
|
Typography,
|
|
5176
5176
|
{
|
|
5177
5177
|
variant: "caption",
|
|
@@ -5208,13 +5208,13 @@ function EntityPreview({
|
|
|
5208
5208
|
propertyKey: key,
|
|
5209
5209
|
value: getValueInPath(entity.values, key),
|
|
5210
5210
|
property: childProperty,
|
|
5211
|
-
size: "
|
|
5211
|
+
size: "smallest"
|
|
5212
5212
|
}
|
|
5213
5213
|
) : /* @__PURE__ */ jsx(
|
|
5214
5214
|
SkeletonPropertyComponent,
|
|
5215
5215
|
{
|
|
5216
5216
|
property: childProperty,
|
|
5217
|
-
size: "
|
|
5217
|
+
size: "smallest"
|
|
5218
5218
|
}
|
|
5219
5219
|
)
|
|
5220
5220
|
},
|
|
@@ -5226,7 +5226,7 @@ function EntityPreview({
|
|
|
5226
5226
|
Tooltip,
|
|
5227
5227
|
{
|
|
5228
5228
|
title: `See details for ${entity.id}`,
|
|
5229
|
-
className: size !== "
|
|
5229
|
+
className: size !== "smallest" ? "self-start" : "",
|
|
5230
5230
|
children: /* @__PURE__ */ jsx(
|
|
5231
5231
|
IconButton,
|
|
5232
5232
|
{
|
|
@@ -5280,7 +5280,7 @@ const EntityPreviewContainerInner = React.forwardRef(({
|
|
|
5280
5280
|
fullwidth ? "w-full" : "",
|
|
5281
5281
|
"items-center",
|
|
5282
5282
|
hover ? "hover:bg-slate-50 dark:hover:bg-gray-800 group-hover:bg-slate-50 dark:group-hover:bg-gray-800" : "",
|
|
5283
|
-
size === "
|
|
5283
|
+
size === "smallest" ? "p-1" : "p-2",
|
|
5284
5284
|
"flex border rounded-lg",
|
|
5285
5285
|
onClick ? "cursor-pointer" : "",
|
|
5286
5286
|
defaultBorderMixin,
|
|
@@ -5461,7 +5461,7 @@ function ArrayOfReferencesPreview({
|
|
|
5461
5461
|
}
|
|
5462
5462
|
if (property?.dataType !== "array" || !property.of || property.of.dataType !== "reference")
|
|
5463
5463
|
throw Error("Picked wrong preview component ArrayOfReferencesPreview");
|
|
5464
|
-
const childSize = size === "medium" ? "small" : "
|
|
5464
|
+
const childSize = size === "medium" ? "small" : "smallest";
|
|
5465
5465
|
return /* @__PURE__ */ jsx("div", { className: "flex flex-col w-full", children: value && value.map(
|
|
5466
5466
|
(reference, index) => {
|
|
5467
5467
|
const ofProperty = property.of;
|
|
@@ -5504,7 +5504,7 @@ function ArrayOfStorageComponentsPreview({
|
|
|
5504
5504
|
}
|
|
5505
5505
|
if (property.dataType !== "array" || !property.of || property.of.dataType !== "string")
|
|
5506
5506
|
throw Error("Picked wrong preview component ArrayOfStorageComponentsPreview");
|
|
5507
|
-
const childSize = size === "medium" ? "small" : "
|
|
5507
|
+
const childSize = size === "medium" ? "small" : "smallest";
|
|
5508
5508
|
return /* @__PURE__ */ jsx("div", { className: "flex flex-wrap gap-2", children: value && value.map(
|
|
5509
5509
|
(v, index) => /* @__PURE__ */ jsx(ErrorBoundary, { children: /* @__PURE__ */ jsx(
|
|
5510
5510
|
PropertyPreview,
|
|
@@ -5618,7 +5618,7 @@ function ArrayOneOfPreview({
|
|
|
5618
5618
|
}
|
|
5619
5619
|
const values = value;
|
|
5620
5620
|
if (!values) return null;
|
|
5621
|
-
const childSize = size === "medium" ? "small" : "
|
|
5621
|
+
const childSize = size === "medium" ? "small" : "smallest";
|
|
5622
5622
|
const typeField = property.oneOf.typeField ?? DEFAULT_ONE_OF_TYPE;
|
|
5623
5623
|
const valueField = property.oneOf.valueField ?? DEFAULT_ONE_OF_VALUE;
|
|
5624
5624
|
const properties = property.oneOf.properties;
|
|
@@ -5656,7 +5656,7 @@ function MapPropertyPreview({
|
|
|
5656
5656
|
}
|
|
5657
5657
|
if (!value) return null;
|
|
5658
5658
|
const mapPropertyKeys = Object.keys(mapProperty.properties);
|
|
5659
|
-
if (size === "
|
|
5659
|
+
if (size === "smallest")
|
|
5660
5660
|
return /* @__PURE__ */ jsx("div", { className: "w-full flex flex-col space-y-1 md:space-y-2", children: mapPropertyKeys.map((key, index) => /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
|
|
5661
5661
|
ErrorBoundary,
|
|
5662
5662
|
{
|
|
@@ -5816,7 +5816,7 @@ function BooleanPreview({
|
|
|
5816
5816
|
property.name && /* @__PURE__ */ jsx(
|
|
5817
5817
|
"span",
|
|
5818
5818
|
{
|
|
5819
|
-
className: cls("text-text-secondary dark:text-text-secondary-dark", size === "
|
|
5819
|
+
className: cls("text-text-secondary dark:text-text-secondary-dark", size === "smallest" ? "text-sm" : ""),
|
|
5820
5820
|
children: property.name
|
|
5821
5821
|
}
|
|
5822
5822
|
)
|
|
@@ -7213,7 +7213,7 @@ const TableReferenceFieldSuccess = React__default.memo(
|
|
|
7213
7213
|
ReferencePreview,
|
|
7214
7214
|
{
|
|
7215
7215
|
onClick: disabled ? void 0 : handleOpen,
|
|
7216
|
-
size: "
|
|
7216
|
+
size: "smallest",
|
|
7217
7217
|
reference,
|
|
7218
7218
|
hover: !disabled,
|
|
7219
7219
|
disabled: !path,
|
|
@@ -12445,7 +12445,7 @@ const EntityCollectionView = React__default.memo(
|
|
|
12445
12445
|
ReferencePreview,
|
|
12446
12446
|
{
|
|
12447
12447
|
reference,
|
|
12448
|
-
size: "
|
|
12448
|
+
size: "smallest"
|
|
12449
12449
|
},
|
|
12450
12450
|
reference.path + "/" + reference.id
|
|
12451
12451
|
);
|
|
@@ -13766,7 +13766,8 @@ function SelectFieldBinding({
|
|
|
13766
13766
|
autoFocus,
|
|
13767
13767
|
touched,
|
|
13768
13768
|
property,
|
|
13769
|
-
includeDescription
|
|
13769
|
+
includeDescription,
|
|
13770
|
+
size = "medium"
|
|
13770
13771
|
}) {
|
|
13771
13772
|
const enumValues = property.enumValues;
|
|
13772
13773
|
useClearRestoreValue({
|
|
@@ -13783,6 +13784,7 @@ function SelectFieldBinding({
|
|
|
13783
13784
|
/* @__PURE__ */ jsx(
|
|
13784
13785
|
Select,
|
|
13785
13786
|
{
|
|
13787
|
+
size: size === "medium" ? "medium" : "small",
|
|
13786
13788
|
value: value !== void 0 && value != null ? value.toString() : "",
|
|
13787
13789
|
disabled,
|
|
13788
13790
|
position: "item-aligned",
|
|
@@ -13813,7 +13815,7 @@ function SelectFieldBinding({
|
|
|
13813
13815
|
{
|
|
13814
13816
|
enumKey,
|
|
13815
13817
|
enumValues,
|
|
13816
|
-
size
|
|
13818
|
+
size
|
|
13817
13819
|
}
|
|
13818
13820
|
);
|
|
13819
13821
|
},
|
|
@@ -13827,7 +13829,7 @@ function SelectFieldBinding({
|
|
|
13827
13829
|
{
|
|
13828
13830
|
enumKey: String(option.id),
|
|
13829
13831
|
enumValues,
|
|
13830
|
-
size
|
|
13832
|
+
size
|
|
13831
13833
|
}
|
|
13832
13834
|
)
|
|
13833
13835
|
},
|
|
@@ -13857,6 +13859,7 @@ function MultiSelectBinding({
|
|
|
13857
13859
|
disabled,
|
|
13858
13860
|
property,
|
|
13859
13861
|
includeDescription,
|
|
13862
|
+
size = "medium",
|
|
13860
13863
|
autoFocus
|
|
13861
13864
|
}) {
|
|
13862
13865
|
const of = property.of;
|
|
@@ -13915,6 +13918,7 @@ function MultiSelectBinding({
|
|
|
13915
13918
|
/* @__PURE__ */ jsx(
|
|
13916
13919
|
MultiSelect,
|
|
13917
13920
|
{
|
|
13921
|
+
size: size === "medium" ? "medium" : "small",
|
|
13918
13922
|
value: validValue ? value.map((v) => v.toString()) : [],
|
|
13919
13923
|
disabled,
|
|
13920
13924
|
label: /* @__PURE__ */ jsx(
|
|
@@ -14524,7 +14528,8 @@ function TextFieldBinding({
|
|
|
14524
14528
|
disabled,
|
|
14525
14529
|
autoFocus,
|
|
14526
14530
|
property,
|
|
14527
|
-
includeDescription
|
|
14531
|
+
includeDescription,
|
|
14532
|
+
size = "medium"
|
|
14528
14533
|
}) {
|
|
14529
14534
|
let multiline;
|
|
14530
14535
|
let url;
|
|
@@ -14562,6 +14567,7 @@ function TextFieldBinding({
|
|
|
14562
14567
|
/* @__PURE__ */ jsx(
|
|
14563
14568
|
TextField,
|
|
14564
14569
|
{
|
|
14570
|
+
size,
|
|
14565
14571
|
value,
|
|
14566
14572
|
onChange,
|
|
14567
14573
|
autoFocus,
|
|
@@ -14607,7 +14613,7 @@ function TextFieldBinding({
|
|
|
14607
14613
|
{
|
|
14608
14614
|
value,
|
|
14609
14615
|
property,
|
|
14610
|
-
size
|
|
14616
|
+
size
|
|
14611
14617
|
}
|
|
14612
14618
|
)
|
|
14613
14619
|
}
|
|
@@ -14622,7 +14628,7 @@ const SwitchFieldBinding = React__default.forwardRef(function SwitchFieldBinding
|
|
|
14622
14628
|
showError,
|
|
14623
14629
|
autoFocus,
|
|
14624
14630
|
disabled,
|
|
14625
|
-
|
|
14631
|
+
size = "medium",
|
|
14626
14632
|
property,
|
|
14627
14633
|
includeDescription
|
|
14628
14634
|
}, ref) {
|
|
@@ -14648,7 +14654,7 @@ const SwitchFieldBinding = React__default.forwardRef(function SwitchFieldBinding
|
|
|
14648
14654
|
),
|
|
14649
14655
|
disabled,
|
|
14650
14656
|
autoFocus,
|
|
14651
|
-
size
|
|
14657
|
+
size
|
|
14652
14658
|
}
|
|
14653
14659
|
),
|
|
14654
14660
|
/* @__PURE__ */ jsx(
|
|
@@ -14782,7 +14788,7 @@ function ReferenceFieldBindingInternal({
|
|
|
14782
14788
|
autoFocus,
|
|
14783
14789
|
property,
|
|
14784
14790
|
includeDescription,
|
|
14785
|
-
|
|
14791
|
+
size = "medium"
|
|
14786
14792
|
}) {
|
|
14787
14793
|
if (!property.path) {
|
|
14788
14794
|
throw new Error("Property path is required for ReferenceFieldBinding");
|
|
@@ -14840,7 +14846,7 @@ function ReferenceFieldBindingInternal({
|
|
|
14840
14846
|
disabled: !property.path,
|
|
14841
14847
|
previewProperties: property.previewProperties,
|
|
14842
14848
|
hover: !disabled,
|
|
14843
|
-
size
|
|
14849
|
+
size,
|
|
14844
14850
|
onClick: disabled || isSubmitting ? void 0 : onEntryClick,
|
|
14845
14851
|
reference: value,
|
|
14846
14852
|
includeEntityLink: property.includeEntityLink,
|
|
@@ -14851,7 +14857,7 @@ function ReferenceFieldBindingInternal({
|
|
|
14851
14857
|
EntityPreviewContainer,
|
|
14852
14858
|
{
|
|
14853
14859
|
className: cls(
|
|
14854
|
-
"
|
|
14860
|
+
"px-6 h-16 text-sm font-medium flex items-center gap-6",
|
|
14855
14861
|
disabled || isSubmitting ? "text-slate-500" : "cursor-pointer text-slate-700 dark:text-slate-300 hover:bg-slate-50 dark:hover:bg-gray-800 group-hover:bg-slate-50 dark:group-hover:bg-gray-800"
|
|
14856
14862
|
),
|
|
14857
14863
|
onClick: onEntryClick,
|
|
@@ -14882,6 +14888,9 @@ const PropertyFieldBinding = React__default.memo(PropertyFieldBindingInternal, (
|
|
|
14882
14888
|
if (a.index !== b.index) {
|
|
14883
14889
|
return false;
|
|
14884
14890
|
}
|
|
14891
|
+
if (a.size !== b.size) {
|
|
14892
|
+
return false;
|
|
14893
|
+
}
|
|
14885
14894
|
const aIsBuilder = isPropertyBuilder(a.property) || a.property.fromBuilder;
|
|
14886
14895
|
const bIsBuilder = isPropertyBuilder(b.property) || b.property.fromBuilder;
|
|
14887
14896
|
const baseCheck = (aIsBuilder === bIsBuilder || equal(a.property, b.property)) && a.disabled === b.disabled;
|
|
@@ -14903,7 +14912,8 @@ function PropertyFieldBindingInternal({
|
|
|
14903
14912
|
partOfArray,
|
|
14904
14913
|
minimalistView,
|
|
14905
14914
|
autoFocus,
|
|
14906
|
-
index
|
|
14915
|
+
index,
|
|
14916
|
+
size
|
|
14907
14917
|
}) {
|
|
14908
14918
|
const customizationController = useCustomizationController();
|
|
14909
14919
|
return /* @__PURE__ */ jsx(
|
|
@@ -14965,7 +14975,8 @@ function PropertyFieldBindingInternal({
|
|
|
14965
14975
|
disabled,
|
|
14966
14976
|
partOfArray,
|
|
14967
14977
|
minimalistView,
|
|
14968
|
-
autoFocus
|
|
14978
|
+
autoFocus,
|
|
14979
|
+
size
|
|
14969
14980
|
};
|
|
14970
14981
|
return /* @__PURE__ */ jsx(
|
|
14971
14982
|
FieldInternal,
|
|
@@ -14991,7 +15002,8 @@ function FieldInternal({
|
|
|
14991
15002
|
minimalistView,
|
|
14992
15003
|
autoFocus,
|
|
14993
15004
|
context,
|
|
14994
|
-
disabled
|
|
15005
|
+
disabled,
|
|
15006
|
+
size
|
|
14995
15007
|
},
|
|
14996
15008
|
fieldProps
|
|
14997
15009
|
}) {
|
|
@@ -15022,7 +15034,6 @@ function FieldInternal({
|
|
|
15022
15034
|
const cmsFieldProps = {
|
|
15023
15035
|
propertyKey,
|
|
15024
15036
|
value,
|
|
15025
|
-
// initialValue,
|
|
15026
15037
|
setValue,
|
|
15027
15038
|
setFieldValue,
|
|
15028
15039
|
error,
|
|
@@ -15037,7 +15048,8 @@ function FieldInternal({
|
|
|
15037
15048
|
minimalistView: minimalistView ?? false,
|
|
15038
15049
|
autoFocus: autoFocus ?? false,
|
|
15039
15050
|
customProps: customFieldProps,
|
|
15040
|
-
context
|
|
15051
|
+
context,
|
|
15052
|
+
size
|
|
15041
15053
|
};
|
|
15042
15054
|
return /* @__PURE__ */ jsxs(ErrorBoundary, { children: [
|
|
15043
15055
|
/* @__PURE__ */ jsx(UsedComponent, { ...cmsFieldProps }),
|