@fctc/sme-widget-ui 1.8.5 → 1.8.7
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/index.js +6 -6
- package/dist/index.mjs +6 -6
- package/dist/widgets.js +6 -6
- package/dist/widgets.mjs +6 -6
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -17186,7 +17186,7 @@ var baseStyle = {
|
|
|
17186
17186
|
height: "fit-content"
|
|
17187
17187
|
};
|
|
17188
17188
|
var ButtonBadgeField = (props) => {
|
|
17189
|
-
const { defaultValue, selection, value, formValues, domainHelper } = props;
|
|
17189
|
+
const { defaultValue, selection, value, formValues, domainHelper, type } = props;
|
|
17190
17190
|
const decorationSuccess = props["decoration-success"] && domainHelper.checkDomain(formValues, props["decoration-success"]);
|
|
17191
17191
|
const decorationInfo = props["decoration-info"] && domainHelper.checkDomain(formValues, props["decoration-info"]);
|
|
17192
17192
|
const decorationDanger = props["decoration-danger"] && domainHelper.checkDomain(formValues, props["decoration-danger"]);
|
|
@@ -17200,13 +17200,13 @@ var ButtonBadgeField = (props) => {
|
|
|
17200
17200
|
};
|
|
17201
17201
|
const getLabel = (value2) => {
|
|
17202
17202
|
if (!value2) return "";
|
|
17203
|
-
const item = selection?.find(
|
|
17203
|
+
const item = type === "selection" ? selection?.find(
|
|
17204
17204
|
(item2) => Array.isArray(item2) && item2[0] === value2
|
|
17205
|
-
);
|
|
17206
|
-
return item ? item[1] :
|
|
17205
|
+
) : value2;
|
|
17206
|
+
return item && type === "selection" && Array.isArray(item) ? item[1] : item;
|
|
17207
17207
|
};
|
|
17208
17208
|
const label = getLabel(defaultValue ?? value);
|
|
17209
|
-
return label ? /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("div", { style: { ...baseStyle, ...getType() }, children:
|
|
17209
|
+
return label ? /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("div", { style: { ...baseStyle, ...getType() }, children: label }) : null;
|
|
17210
17210
|
};
|
|
17211
17211
|
|
|
17212
17212
|
// src/widgets/basic/button-field/button.tsx
|
|
@@ -32538,7 +32538,7 @@ var Many2ManyTagField = (props) => {
|
|
|
32538
32538
|
placeholder: readonly ? "" : t3("choose_place"),
|
|
32539
32539
|
classNames: isEditTable ? {
|
|
32540
32540
|
valueContainer: () => "overflow-unset !px-0",
|
|
32541
|
-
control: () => `w-full flex ring-0 cursor-pointer outline-0 md:!min-w-max max-w-max !shadow-none
|
|
32541
|
+
control: () => `w-full flex ring-0 cursor-pointer outline-0 md:!min-w-max max-w-max !shadow-none pl-3 text-sm text-[#1A1A1B] font-normal gap-2 opacity-100 leading-5 resize-none overflow-hidden border border-transparent border-b border-[#f7f7f7] hover:border-b-primary ${readonly ? `!cursor-not-allowed ${filteredValue?.length === 0 && "no-values"}` : ""}`,
|
|
32542
32542
|
dropdownIndicator: () => "invisible group-hover:visible !m-0 !p-0",
|
|
32543
32543
|
clearIndicator: () => "invisible group-hover:visible !m-0 !p-0"
|
|
32544
32544
|
} : {
|
package/dist/index.mjs
CHANGED
|
@@ -17064,7 +17064,7 @@ var baseStyle = {
|
|
|
17064
17064
|
height: "fit-content"
|
|
17065
17065
|
};
|
|
17066
17066
|
var ButtonBadgeField = (props) => {
|
|
17067
|
-
const { defaultValue, selection, value, formValues, domainHelper } = props;
|
|
17067
|
+
const { defaultValue, selection, value, formValues, domainHelper, type } = props;
|
|
17068
17068
|
const decorationSuccess = props["decoration-success"] && domainHelper.checkDomain(formValues, props["decoration-success"]);
|
|
17069
17069
|
const decorationInfo = props["decoration-info"] && domainHelper.checkDomain(formValues, props["decoration-info"]);
|
|
17070
17070
|
const decorationDanger = props["decoration-danger"] && domainHelper.checkDomain(formValues, props["decoration-danger"]);
|
|
@@ -17078,13 +17078,13 @@ var ButtonBadgeField = (props) => {
|
|
|
17078
17078
|
};
|
|
17079
17079
|
const getLabel = (value2) => {
|
|
17080
17080
|
if (!value2) return "";
|
|
17081
|
-
const item = selection?.find(
|
|
17081
|
+
const item = type === "selection" ? selection?.find(
|
|
17082
17082
|
(item2) => Array.isArray(item2) && item2[0] === value2
|
|
17083
|
-
);
|
|
17084
|
-
return item ? item[1] :
|
|
17083
|
+
) : value2;
|
|
17084
|
+
return item && type === "selection" && Array.isArray(item) ? item[1] : item;
|
|
17085
17085
|
};
|
|
17086
17086
|
const label = getLabel(defaultValue ?? value);
|
|
17087
|
-
return label ? /* @__PURE__ */ jsx72("div", { style: { ...baseStyle, ...getType() }, children:
|
|
17087
|
+
return label ? /* @__PURE__ */ jsx72("div", { style: { ...baseStyle, ...getType() }, children: label }) : null;
|
|
17088
17088
|
};
|
|
17089
17089
|
|
|
17090
17090
|
// src/widgets/basic/button-field/button.tsx
|
|
@@ -32416,7 +32416,7 @@ var Many2ManyTagField = (props) => {
|
|
|
32416
32416
|
placeholder: readonly ? "" : t3("choose_place"),
|
|
32417
32417
|
classNames: isEditTable ? {
|
|
32418
32418
|
valueContainer: () => "overflow-unset !px-0",
|
|
32419
|
-
control: () => `w-full flex ring-0 cursor-pointer outline-0 md:!min-w-max max-w-max !shadow-none
|
|
32419
|
+
control: () => `w-full flex ring-0 cursor-pointer outline-0 md:!min-w-max max-w-max !shadow-none pl-3 text-sm text-[#1A1A1B] font-normal gap-2 opacity-100 leading-5 resize-none overflow-hidden border border-transparent border-b border-[#f7f7f7] hover:border-b-primary ${readonly ? `!cursor-not-allowed ${filteredValue?.length === 0 && "no-values"}` : ""}`,
|
|
32420
32420
|
dropdownIndicator: () => "invisible group-hover:visible !m-0 !p-0",
|
|
32421
32421
|
clearIndicator: () => "invisible group-hover:visible !m-0 !p-0"
|
|
32422
32422
|
} : {
|
package/dist/widgets.js
CHANGED
|
@@ -16592,7 +16592,7 @@ var baseStyle = {
|
|
|
16592
16592
|
height: "fit-content"
|
|
16593
16593
|
};
|
|
16594
16594
|
var ButtonBadgeField = (props) => {
|
|
16595
|
-
const { defaultValue, selection, value, formValues, domainHelper } = props;
|
|
16595
|
+
const { defaultValue, selection, value, formValues, domainHelper, type } = props;
|
|
16596
16596
|
const decorationSuccess = props["decoration-success"] && domainHelper.checkDomain(formValues, props["decoration-success"]);
|
|
16597
16597
|
const decorationInfo = props["decoration-info"] && domainHelper.checkDomain(formValues, props["decoration-info"]);
|
|
16598
16598
|
const decorationDanger = props["decoration-danger"] && domainHelper.checkDomain(formValues, props["decoration-danger"]);
|
|
@@ -16606,13 +16606,13 @@ var ButtonBadgeField = (props) => {
|
|
|
16606
16606
|
};
|
|
16607
16607
|
const getLabel = (value2) => {
|
|
16608
16608
|
if (!value2) return "";
|
|
16609
|
-
const item = selection?.find(
|
|
16609
|
+
const item = type === "selection" ? selection?.find(
|
|
16610
16610
|
(item2) => Array.isArray(item2) && item2[0] === value2
|
|
16611
|
-
);
|
|
16612
|
-
return item ? item[1] :
|
|
16611
|
+
) : value2;
|
|
16612
|
+
return item && type === "selection" && Array.isArray(item) ? item[1] : item;
|
|
16613
16613
|
};
|
|
16614
16614
|
const label = getLabel(defaultValue ?? value);
|
|
16615
|
-
return label ? /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("div", { style: { ...baseStyle, ...getType() }, children:
|
|
16615
|
+
return label ? /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("div", { style: { ...baseStyle, ...getType() }, children: label }) : null;
|
|
16616
16616
|
};
|
|
16617
16617
|
|
|
16618
16618
|
// src/widgets/basic/button-field/button.tsx
|
|
@@ -31944,7 +31944,7 @@ var Many2ManyTagField = (props) => {
|
|
|
31944
31944
|
placeholder: readonly ? "" : t3("choose_place"),
|
|
31945
31945
|
classNames: isEditTable ? {
|
|
31946
31946
|
valueContainer: () => "overflow-unset !px-0",
|
|
31947
|
-
control: () => `w-full flex ring-0 cursor-pointer outline-0 md:!min-w-max max-w-max !shadow-none
|
|
31947
|
+
control: () => `w-full flex ring-0 cursor-pointer outline-0 md:!min-w-max max-w-max !shadow-none pl-3 text-sm text-[#1A1A1B] font-normal gap-2 opacity-100 leading-5 resize-none overflow-hidden border border-transparent border-b border-[#f7f7f7] hover:border-b-primary ${readonly ? `!cursor-not-allowed ${filteredValue?.length === 0 && "no-values"}` : ""}`,
|
|
31948
31948
|
dropdownIndicator: () => "invisible group-hover:visible !m-0 !p-0",
|
|
31949
31949
|
clearIndicator: () => "invisible group-hover:visible !m-0 !p-0"
|
|
31950
31950
|
} : {
|
package/dist/widgets.mjs
CHANGED
|
@@ -16529,7 +16529,7 @@ var baseStyle = {
|
|
|
16529
16529
|
height: "fit-content"
|
|
16530
16530
|
};
|
|
16531
16531
|
var ButtonBadgeField = (props) => {
|
|
16532
|
-
const { defaultValue, selection, value, formValues, domainHelper } = props;
|
|
16532
|
+
const { defaultValue, selection, value, formValues, domainHelper, type } = props;
|
|
16533
16533
|
const decorationSuccess = props["decoration-success"] && domainHelper.checkDomain(formValues, props["decoration-success"]);
|
|
16534
16534
|
const decorationInfo = props["decoration-info"] && domainHelper.checkDomain(formValues, props["decoration-info"]);
|
|
16535
16535
|
const decorationDanger = props["decoration-danger"] && domainHelper.checkDomain(formValues, props["decoration-danger"]);
|
|
@@ -16543,13 +16543,13 @@ var ButtonBadgeField = (props) => {
|
|
|
16543
16543
|
};
|
|
16544
16544
|
const getLabel = (value2) => {
|
|
16545
16545
|
if (!value2) return "";
|
|
16546
|
-
const item = selection?.find(
|
|
16546
|
+
const item = type === "selection" ? selection?.find(
|
|
16547
16547
|
(item2) => Array.isArray(item2) && item2[0] === value2
|
|
16548
|
-
);
|
|
16549
|
-
return item ? item[1] :
|
|
16548
|
+
) : value2;
|
|
16549
|
+
return item && type === "selection" && Array.isArray(item) ? item[1] : item;
|
|
16550
16550
|
};
|
|
16551
16551
|
const label = getLabel(defaultValue ?? value);
|
|
16552
|
-
return label ? /* @__PURE__ */ jsx72("div", { style: { ...baseStyle, ...getType() }, children:
|
|
16552
|
+
return label ? /* @__PURE__ */ jsx72("div", { style: { ...baseStyle, ...getType() }, children: label }) : null;
|
|
16553
16553
|
};
|
|
16554
16554
|
|
|
16555
16555
|
// src/widgets/basic/button-field/button.tsx
|
|
@@ -31881,7 +31881,7 @@ var Many2ManyTagField = (props) => {
|
|
|
31881
31881
|
placeholder: readonly ? "" : t3("choose_place"),
|
|
31882
31882
|
classNames: isEditTable ? {
|
|
31883
31883
|
valueContainer: () => "overflow-unset !px-0",
|
|
31884
|
-
control: () => `w-full flex ring-0 cursor-pointer outline-0 md:!min-w-max max-w-max !shadow-none
|
|
31884
|
+
control: () => `w-full flex ring-0 cursor-pointer outline-0 md:!min-w-max max-w-max !shadow-none pl-3 text-sm text-[#1A1A1B] font-normal gap-2 opacity-100 leading-5 resize-none overflow-hidden border border-transparent border-b border-[#f7f7f7] hover:border-b-primary ${readonly ? `!cursor-not-allowed ${filteredValue?.length === 0 && "no-values"}` : ""}`,
|
|
31885
31885
|
dropdownIndicator: () => "invisible group-hover:visible !m-0 !p-0",
|
|
31886
31886
|
clearIndicator: () => "invisible group-hover:visible !m-0 !p-0"
|
|
31887
31887
|
} : {
|