@fctc/sme-widget-ui 1.2.0 → 1.2.2
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 +24 -16
- package/dist/index.mjs +24 -16
- package/dist/widgets.js +24 -16
- package/dist/widgets.mjs +24 -16
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -12068,7 +12068,8 @@ var Row = (props) => {
|
|
|
12068
12068
|
setSelectedRowKeys,
|
|
12069
12069
|
onClickRow,
|
|
12070
12070
|
isAutoSelect,
|
|
12071
|
-
selectedRowKeysRef
|
|
12071
|
+
selectedRowKeysRef,
|
|
12072
|
+
isEditTable
|
|
12072
12073
|
} = props;
|
|
12073
12074
|
const checkboxRef = (0, import_react11.useRef)("enabled");
|
|
12074
12075
|
const checked = (0, import_react11.useMemo)(() => {
|
|
@@ -12144,7 +12145,7 @@ var Row = (props) => {
|
|
|
12144
12145
|
"td",
|
|
12145
12146
|
{
|
|
12146
12147
|
colSpan: 1,
|
|
12147
|
-
className:
|
|
12148
|
+
className: `${isEditTable ? "" : "p-3"} column w-max whitespace-nowrap border-b border-gray-200 text-sm font-normal text-gray-900`,
|
|
12148
12149
|
onClick: () => {
|
|
12149
12150
|
handleClickRow(col, row);
|
|
12150
12151
|
},
|
|
@@ -18311,8 +18312,10 @@ var CharField = (props) => {
|
|
|
18311
18312
|
disabled: readonly,
|
|
18312
18313
|
placeholder,
|
|
18313
18314
|
required: !invisible && required,
|
|
18314
|
-
className: `w-full
|
|
18315
|
-
|
|
18315
|
+
className: `w-full h-full ring-0 focus:ring-0 focus:!outline-none outline-0 px-3 py-[12px] text-sm font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden
|
|
18316
|
+
${readonly ? "cursor-not-allowed border border-[rgba(66,66,66,0.12)] text-[#5c5a5a]" : "cursor-pointer border border-[rgba(66,66,66,0.12)] text-[#525866]"}
|
|
18317
|
+
${!isEditTable ? isForm ? "bg-white border-input-primary rounded-[10px]" : "" : "border-transparent border-b-primary bg-transparent"}
|
|
18318
|
+
${error2 && isEditTable && "focus:border-b-[1px] focus:border-[#de4747] hover:border-b-[1px] hover:border-[#de4747]"}
|
|
18316
18319
|
`
|
|
18317
18320
|
}
|
|
18318
18321
|
),
|
|
@@ -32383,7 +32386,7 @@ var DateField = (props) => {
|
|
|
32383
32386
|
/* @__PURE__ */ (0, import_jsx_runtime78.jsx)(
|
|
32384
32387
|
"input",
|
|
32385
32388
|
{
|
|
32386
|
-
className:
|
|
32389
|
+
className: `bg-transparent w-full focus-visible:outline-none outline-none border-none ${readonly && "cursor-not-allowed"}`,
|
|
32387
32390
|
required,
|
|
32388
32391
|
readOnly: readonly,
|
|
32389
32392
|
type: "",
|
|
@@ -32476,7 +32479,7 @@ var DateField = (props) => {
|
|
|
32476
32479
|
{
|
|
32477
32480
|
isForm,
|
|
32478
32481
|
defaultValue: field.value,
|
|
32479
|
-
className: `${invisible ? "hidden" : ""} ${isEditTable ?
|
|
32482
|
+
className: `${invisible ? "hidden" : ""} ${isEditTable ? `pl-2 border-b-primary py-[12px] px-3 ${readonly && "cursor-not-allowed"}` : !isForm ? "!bg-transparent focus-within:!border-none" : `w-full h-full ring-0 focus:ring-0 focus:!outline-none focus:border-[1px] focus:border-[#16a730] outline-0 bg-white border border-[rgba(66,66,66,0.12)] rounded-[10px] px-3 py-[12px] text-sm text-[#525866] font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden ${readonly && "cursor-not-allowed"}`}`
|
|
32480
32483
|
}
|
|
32481
32484
|
),
|
|
32482
32485
|
timeInputLabel: textPlaceHolder,
|
|
@@ -32969,9 +32972,9 @@ var FloatField = (props) => {
|
|
|
32969
32972
|
placeholder,
|
|
32970
32973
|
required: !invisible && required,
|
|
32971
32974
|
style: invisible ? { display: "none" } : {},
|
|
32972
|
-
className: `w-full
|
|
32973
|
-
|
|
32974
|
-
${!isEditTable ? "bg-
|
|
32975
|
+
className: `w-full h-full ring-0 focus:ring-0 focus:!outline-none outline-0 px-3 py-[12px] text-sm font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden
|
|
32976
|
+
${readonly ? "cursor-not-allowed border border-[rgba(66,66,66,0.12)] text-[#5c5a5a]" : "cursor-pointer border border-[rgba(66,66,66,0.12)] text-[#525866]"}
|
|
32977
|
+
${!isEditTable ? isForm ? "bg-white border-input-primary rounded-[10px]" : "" : "border-transparent border-b-primary bg-transparent"}
|
|
32975
32978
|
${error2 && isEditTable && "focus:border-b-[1px] focus:border-[#de4747] hover:border-b-[1px] hover:border-[#de4747]"}
|
|
32976
32979
|
`
|
|
32977
32980
|
}
|
|
@@ -33939,7 +33942,7 @@ var IntegerField = (props) => {
|
|
|
33939
33942
|
string,
|
|
33940
33943
|
isEditTable
|
|
33941
33944
|
} = props;
|
|
33942
|
-
if (!isForm) {
|
|
33945
|
+
if (!isForm && !isEditTable) {
|
|
33943
33946
|
const displayValue = value ?? defaultValue;
|
|
33944
33947
|
return /* @__PURE__ */ (0, import_jsx_runtime99.jsx)("span", { children: typeof displayValue === "object" ? JSON.stringify(displayValue) : formatNumberOnly(displayValue) });
|
|
33945
33948
|
}
|
|
@@ -34050,9 +34053,10 @@ var IntegerField = (props) => {
|
|
|
34050
34053
|
placeholder,
|
|
34051
34054
|
required: !invisible && required,
|
|
34052
34055
|
style: invisible ? { display: "none" } : {},
|
|
34053
|
-
className: `w-full
|
|
34054
|
-
|
|
34055
|
-
${
|
|
34056
|
+
className: `w-full h-full ring-0 focus:ring-0 focus:!outline-none outline-0 px-3 py-[12px] text-sm font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden
|
|
34057
|
+
${readonly ? "cursor-not-allowed border border-[rgba(66,66,66,0.12)] text-[#5c5a5a]" : "cursor-pointer border border-[rgba(66,66,66,0.12)] text-[#525866]"}
|
|
34058
|
+
${!isEditTable ? isForm ? "bg-white border-input-primary rounded-[10px]" : "" : "border-transparent border-b-primary bg-transparent"}
|
|
34059
|
+
${error2 && isEditTable && "focus:border-b-[1px] focus:border-[#de4747] hover:border-b-[1px] hover:border-[#de4747]"}
|
|
34056
34060
|
`
|
|
34057
34061
|
}
|
|
34058
34062
|
),
|
|
@@ -34445,7 +34449,7 @@ var Many2OneField = (props) => {
|
|
|
34445
34449
|
{
|
|
34446
34450
|
id: name2,
|
|
34447
34451
|
"data-tooltip-id": name2,
|
|
34448
|
-
className: `inline-block w-full ${readonly && "cursor-not-allowed"}`,
|
|
34452
|
+
className: `inline-block w-full h-full ${readonly && "cursor-not-allowed"}`,
|
|
34449
34453
|
children: /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(
|
|
34450
34454
|
Controller,
|
|
34451
34455
|
{
|
|
@@ -34467,14 +34471,14 @@ var Many2OneField = (props) => {
|
|
|
34467
34471
|
methods?.clearErrors(name2);
|
|
34468
34472
|
}
|
|
34469
34473
|
}, [selectedOption]);
|
|
34470
|
-
return /* @__PURE__ */ (0, import_jsx_runtime102.jsxs)("div", { className: "
|
|
34474
|
+
return /* @__PURE__ */ (0, import_jsx_runtime102.jsxs)("div", { className: "h-full", children: [
|
|
34471
34475
|
/* @__PURE__ */ (0, import_jsx_runtime102.jsx)(
|
|
34472
34476
|
StateManagedSelect$1,
|
|
34473
34477
|
{
|
|
34474
34478
|
menuShouldScrollIntoView: false,
|
|
34475
34479
|
options: options2,
|
|
34476
34480
|
classNames: {
|
|
34477
|
-
control: ({ isFocused }) => `w-full flex
|
|
34481
|
+
control: ({ isFocused }) => `w-full flex h-full ring-0 cursor-pointer outline-0 bg-white shadow-none rounded-[10px] py-2 px-3 text-sm text-[#1A1A1B] font-normal cursor-pointer gap-2 opacity-100 leading-5 resize-none overflow-hidden field-sizing-content ${isForm && (isFocused ? "!border-[1px] !border-primary !ring-0 outline-none" : "border !border-[rgba(66,66,66,0.12)]")} ${readonly && "!cursor-not-allowed"} ${isEditTable && "md:!min-w-[300px] max-w-[300px] !rounded-none !border !border-transparent !border-b !border-[#f7f7f7] hover:border-b-primary !bg-transparent min-h-auto"}`,
|
|
34478
34482
|
valueContainer: () => "!m-0 !p-0 ",
|
|
34479
34483
|
singleValue: () => `!m-0 ${readonly ? "!text-[#5c5a5a]" : ""}`,
|
|
34480
34484
|
input: () => "!m-0 !p-0",
|
|
@@ -34504,6 +34508,10 @@ var Many2OneField = (props) => {
|
|
|
34504
34508
|
menuPortalTarget: typeof window !== "undefined" ? document.body : null,
|
|
34505
34509
|
styles: {
|
|
34506
34510
|
control: () => ({}),
|
|
34511
|
+
container: (base) => ({
|
|
34512
|
+
...base,
|
|
34513
|
+
height: "100%"
|
|
34514
|
+
}),
|
|
34507
34515
|
clearIndicator: (base) => ({
|
|
34508
34516
|
...base,
|
|
34509
34517
|
padding: "0"
|
package/dist/index.mjs
CHANGED
|
@@ -11949,7 +11949,8 @@ var Row = (props) => {
|
|
|
11949
11949
|
setSelectedRowKeys,
|
|
11950
11950
|
onClickRow,
|
|
11951
11951
|
isAutoSelect,
|
|
11952
|
-
selectedRowKeysRef
|
|
11952
|
+
selectedRowKeysRef,
|
|
11953
|
+
isEditTable
|
|
11953
11954
|
} = props;
|
|
11954
11955
|
const checkboxRef = useRef3("enabled");
|
|
11955
11956
|
const checked = useMemo3(() => {
|
|
@@ -12025,7 +12026,7 @@ var Row = (props) => {
|
|
|
12025
12026
|
"td",
|
|
12026
12027
|
{
|
|
12027
12028
|
colSpan: 1,
|
|
12028
|
-
className:
|
|
12029
|
+
className: `${isEditTable ? "" : "p-3"} column w-max whitespace-nowrap border-b border-gray-200 text-sm font-normal text-gray-900`,
|
|
12029
12030
|
onClick: () => {
|
|
12030
12031
|
handleClickRow(col, row);
|
|
12031
12032
|
},
|
|
@@ -18192,8 +18193,10 @@ var CharField = (props) => {
|
|
|
18192
18193
|
disabled: readonly,
|
|
18193
18194
|
placeholder,
|
|
18194
18195
|
required: !invisible && required,
|
|
18195
|
-
className: `w-full
|
|
18196
|
-
|
|
18196
|
+
className: `w-full h-full ring-0 focus:ring-0 focus:!outline-none outline-0 px-3 py-[12px] text-sm font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden
|
|
18197
|
+
${readonly ? "cursor-not-allowed border border-[rgba(66,66,66,0.12)] text-[#5c5a5a]" : "cursor-pointer border border-[rgba(66,66,66,0.12)] text-[#525866]"}
|
|
18198
|
+
${!isEditTable ? isForm ? "bg-white border-input-primary rounded-[10px]" : "" : "border-transparent border-b-primary bg-transparent"}
|
|
18199
|
+
${error2 && isEditTable && "focus:border-b-[1px] focus:border-[#de4747] hover:border-b-[1px] hover:border-[#de4747]"}
|
|
18197
18200
|
`
|
|
18198
18201
|
}
|
|
18199
18202
|
),
|
|
@@ -32264,7 +32267,7 @@ var DateField = (props) => {
|
|
|
32264
32267
|
/* @__PURE__ */ jsx80(
|
|
32265
32268
|
"input",
|
|
32266
32269
|
{
|
|
32267
|
-
className:
|
|
32270
|
+
className: `bg-transparent w-full focus-visible:outline-none outline-none border-none ${readonly && "cursor-not-allowed"}`,
|
|
32268
32271
|
required,
|
|
32269
32272
|
readOnly: readonly,
|
|
32270
32273
|
type: "",
|
|
@@ -32357,7 +32360,7 @@ var DateField = (props) => {
|
|
|
32357
32360
|
{
|
|
32358
32361
|
isForm,
|
|
32359
32362
|
defaultValue: field.value,
|
|
32360
|
-
className: `${invisible ? "hidden" : ""} ${isEditTable ?
|
|
32363
|
+
className: `${invisible ? "hidden" : ""} ${isEditTable ? `pl-2 border-b-primary py-[12px] px-3 ${readonly && "cursor-not-allowed"}` : !isForm ? "!bg-transparent focus-within:!border-none" : `w-full h-full ring-0 focus:ring-0 focus:!outline-none focus:border-[1px] focus:border-[#16a730] outline-0 bg-white border border-[rgba(66,66,66,0.12)] rounded-[10px] px-3 py-[12px] text-sm text-[#525866] font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden ${readonly && "cursor-not-allowed"}`}`
|
|
32361
32364
|
}
|
|
32362
32365
|
),
|
|
32363
32366
|
timeInputLabel: textPlaceHolder,
|
|
@@ -32850,9 +32853,9 @@ var FloatField = (props) => {
|
|
|
32850
32853
|
placeholder,
|
|
32851
32854
|
required: !invisible && required,
|
|
32852
32855
|
style: invisible ? { display: "none" } : {},
|
|
32853
|
-
className: `w-full
|
|
32854
|
-
|
|
32855
|
-
${!isEditTable ? "bg-
|
|
32856
|
+
className: `w-full h-full ring-0 focus:ring-0 focus:!outline-none outline-0 px-3 py-[12px] text-sm font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden
|
|
32857
|
+
${readonly ? "cursor-not-allowed border border-[rgba(66,66,66,0.12)] text-[#5c5a5a]" : "cursor-pointer border border-[rgba(66,66,66,0.12)] text-[#525866]"}
|
|
32858
|
+
${!isEditTable ? isForm ? "bg-white border-input-primary rounded-[10px]" : "" : "border-transparent border-b-primary bg-transparent"}
|
|
32856
32859
|
${error2 && isEditTable && "focus:border-b-[1px] focus:border-[#de4747] hover:border-b-[1px] hover:border-[#de4747]"}
|
|
32857
32860
|
`
|
|
32858
32861
|
}
|
|
@@ -33820,7 +33823,7 @@ var IntegerField = (props) => {
|
|
|
33820
33823
|
string,
|
|
33821
33824
|
isEditTable
|
|
33822
33825
|
} = props;
|
|
33823
|
-
if (!isForm) {
|
|
33826
|
+
if (!isForm && !isEditTable) {
|
|
33824
33827
|
const displayValue = value ?? defaultValue;
|
|
33825
33828
|
return /* @__PURE__ */ jsx101("span", { children: typeof displayValue === "object" ? JSON.stringify(displayValue) : formatNumberOnly(displayValue) });
|
|
33826
33829
|
}
|
|
@@ -33931,9 +33934,10 @@ var IntegerField = (props) => {
|
|
|
33931
33934
|
placeholder,
|
|
33932
33935
|
required: !invisible && required,
|
|
33933
33936
|
style: invisible ? { display: "none" } : {},
|
|
33934
|
-
className: `w-full
|
|
33935
|
-
|
|
33936
|
-
${
|
|
33937
|
+
className: `w-full h-full ring-0 focus:ring-0 focus:!outline-none outline-0 px-3 py-[12px] text-sm font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden
|
|
33938
|
+
${readonly ? "cursor-not-allowed border border-[rgba(66,66,66,0.12)] text-[#5c5a5a]" : "cursor-pointer border border-[rgba(66,66,66,0.12)] text-[#525866]"}
|
|
33939
|
+
${!isEditTable ? isForm ? "bg-white border-input-primary rounded-[10px]" : "" : "border-transparent border-b-primary bg-transparent"}
|
|
33940
|
+
${error2 && isEditTable && "focus:border-b-[1px] focus:border-[#de4747] hover:border-b-[1px] hover:border-[#de4747]"}
|
|
33937
33941
|
`
|
|
33938
33942
|
}
|
|
33939
33943
|
),
|
|
@@ -34326,7 +34330,7 @@ var Many2OneField = (props) => {
|
|
|
34326
34330
|
{
|
|
34327
34331
|
id: name2,
|
|
34328
34332
|
"data-tooltip-id": name2,
|
|
34329
|
-
className: `inline-block w-full ${readonly && "cursor-not-allowed"}`,
|
|
34333
|
+
className: `inline-block w-full h-full ${readonly && "cursor-not-allowed"}`,
|
|
34330
34334
|
children: /* @__PURE__ */ jsx104(
|
|
34331
34335
|
Controller,
|
|
34332
34336
|
{
|
|
@@ -34348,14 +34352,14 @@ var Many2OneField = (props) => {
|
|
|
34348
34352
|
methods?.clearErrors(name2);
|
|
34349
34353
|
}
|
|
34350
34354
|
}, [selectedOption]);
|
|
34351
|
-
return /* @__PURE__ */ jsxs72("div", { className: "
|
|
34355
|
+
return /* @__PURE__ */ jsxs72("div", { className: "h-full", children: [
|
|
34352
34356
|
/* @__PURE__ */ jsx104(
|
|
34353
34357
|
StateManagedSelect$1,
|
|
34354
34358
|
{
|
|
34355
34359
|
menuShouldScrollIntoView: false,
|
|
34356
34360
|
options: options2,
|
|
34357
34361
|
classNames: {
|
|
34358
|
-
control: ({ isFocused }) => `w-full flex
|
|
34362
|
+
control: ({ isFocused }) => `w-full flex h-full ring-0 cursor-pointer outline-0 bg-white shadow-none rounded-[10px] py-2 px-3 text-sm text-[#1A1A1B] font-normal cursor-pointer gap-2 opacity-100 leading-5 resize-none overflow-hidden field-sizing-content ${isForm && (isFocused ? "!border-[1px] !border-primary !ring-0 outline-none" : "border !border-[rgba(66,66,66,0.12)]")} ${readonly && "!cursor-not-allowed"} ${isEditTable && "md:!min-w-[300px] max-w-[300px] !rounded-none !border !border-transparent !border-b !border-[#f7f7f7] hover:border-b-primary !bg-transparent min-h-auto"}`,
|
|
34359
34363
|
valueContainer: () => "!m-0 !p-0 ",
|
|
34360
34364
|
singleValue: () => `!m-0 ${readonly ? "!text-[#5c5a5a]" : ""}`,
|
|
34361
34365
|
input: () => "!m-0 !p-0",
|
|
@@ -34385,6 +34389,10 @@ var Many2OneField = (props) => {
|
|
|
34385
34389
|
menuPortalTarget: typeof window !== "undefined" ? document.body : null,
|
|
34386
34390
|
styles: {
|
|
34387
34391
|
control: () => ({}),
|
|
34392
|
+
container: (base) => ({
|
|
34393
|
+
...base,
|
|
34394
|
+
height: "100%"
|
|
34395
|
+
}),
|
|
34388
34396
|
clearIndicator: (base) => ({
|
|
34389
34397
|
...base,
|
|
34390
34398
|
padding: "0"
|
package/dist/widgets.js
CHANGED
|
@@ -11669,7 +11669,8 @@ var Row = (props) => {
|
|
|
11669
11669
|
setSelectedRowKeys,
|
|
11670
11670
|
onClickRow,
|
|
11671
11671
|
isAutoSelect,
|
|
11672
|
-
selectedRowKeysRef
|
|
11672
|
+
selectedRowKeysRef,
|
|
11673
|
+
isEditTable
|
|
11673
11674
|
} = props;
|
|
11674
11675
|
const checkboxRef = (0, import_react10.useRef)("enabled");
|
|
11675
11676
|
const checked = (0, import_react10.useMemo)(() => {
|
|
@@ -11745,7 +11746,7 @@ var Row = (props) => {
|
|
|
11745
11746
|
"td",
|
|
11746
11747
|
{
|
|
11747
11748
|
colSpan: 1,
|
|
11748
|
-
className:
|
|
11749
|
+
className: `${isEditTable ? "" : "p-3"} column w-max whitespace-nowrap border-b border-gray-200 text-sm font-normal text-gray-900`,
|
|
11749
11750
|
onClick: () => {
|
|
11750
11751
|
handleClickRow(col, row);
|
|
11751
11752
|
},
|
|
@@ -17957,8 +17958,10 @@ var CharField = (props) => {
|
|
|
17957
17958
|
disabled: readonly,
|
|
17958
17959
|
placeholder,
|
|
17959
17960
|
required: !invisible && required,
|
|
17960
|
-
className: `w-full
|
|
17961
|
-
|
|
17961
|
+
className: `w-full h-full ring-0 focus:ring-0 focus:!outline-none outline-0 px-3 py-[12px] text-sm font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden
|
|
17962
|
+
${readonly ? "cursor-not-allowed border border-[rgba(66,66,66,0.12)] text-[#5c5a5a]" : "cursor-pointer border border-[rgba(66,66,66,0.12)] text-[#525866]"}
|
|
17963
|
+
${!isEditTable ? isForm ? "bg-white border-input-primary rounded-[10px]" : "" : "border-transparent border-b-primary bg-transparent"}
|
|
17964
|
+
${error2 && isEditTable && "focus:border-b-[1px] focus:border-[#de4747] hover:border-b-[1px] hover:border-[#de4747]"}
|
|
17962
17965
|
`
|
|
17963
17966
|
}
|
|
17964
17967
|
),
|
|
@@ -32029,7 +32032,7 @@ var DateField = (props) => {
|
|
|
32029
32032
|
/* @__PURE__ */ (0, import_jsx_runtime78.jsx)(
|
|
32030
32033
|
"input",
|
|
32031
32034
|
{
|
|
32032
|
-
className:
|
|
32035
|
+
className: `bg-transparent w-full focus-visible:outline-none outline-none border-none ${readonly && "cursor-not-allowed"}`,
|
|
32033
32036
|
required,
|
|
32034
32037
|
readOnly: readonly,
|
|
32035
32038
|
type: "",
|
|
@@ -32122,7 +32125,7 @@ var DateField = (props) => {
|
|
|
32122
32125
|
{
|
|
32123
32126
|
isForm,
|
|
32124
32127
|
defaultValue: field.value,
|
|
32125
|
-
className: `${invisible ? "hidden" : ""} ${isEditTable ?
|
|
32128
|
+
className: `${invisible ? "hidden" : ""} ${isEditTable ? `pl-2 border-b-primary py-[12px] px-3 ${readonly && "cursor-not-allowed"}` : !isForm ? "!bg-transparent focus-within:!border-none" : `w-full h-full ring-0 focus:ring-0 focus:!outline-none focus:border-[1px] focus:border-[#16a730] outline-0 bg-white border border-[rgba(66,66,66,0.12)] rounded-[10px] px-3 py-[12px] text-sm text-[#525866] font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden ${readonly && "cursor-not-allowed"}`}`
|
|
32126
32129
|
}
|
|
32127
32130
|
),
|
|
32128
32131
|
timeInputLabel: textPlaceHolder,
|
|
@@ -32615,9 +32618,9 @@ var FloatField = (props) => {
|
|
|
32615
32618
|
placeholder,
|
|
32616
32619
|
required: !invisible && required,
|
|
32617
32620
|
style: invisible ? { display: "none" } : {},
|
|
32618
|
-
className: `w-full
|
|
32619
|
-
|
|
32620
|
-
${!isEditTable ? "bg-
|
|
32621
|
+
className: `w-full h-full ring-0 focus:ring-0 focus:!outline-none outline-0 px-3 py-[12px] text-sm font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden
|
|
32622
|
+
${readonly ? "cursor-not-allowed border border-[rgba(66,66,66,0.12)] text-[#5c5a5a]" : "cursor-pointer border border-[rgba(66,66,66,0.12)] text-[#525866]"}
|
|
32623
|
+
${!isEditTable ? isForm ? "bg-white border-input-primary rounded-[10px]" : "" : "border-transparent border-b-primary bg-transparent"}
|
|
32621
32624
|
${error2 && isEditTable && "focus:border-b-[1px] focus:border-[#de4747] hover:border-b-[1px] hover:border-[#de4747]"}
|
|
32622
32625
|
`
|
|
32623
32626
|
}
|
|
@@ -33585,7 +33588,7 @@ var IntegerField = (props) => {
|
|
|
33585
33588
|
string,
|
|
33586
33589
|
isEditTable
|
|
33587
33590
|
} = props;
|
|
33588
|
-
if (!isForm) {
|
|
33591
|
+
if (!isForm && !isEditTable) {
|
|
33589
33592
|
const displayValue = value ?? defaultValue;
|
|
33590
33593
|
return /* @__PURE__ */ (0, import_jsx_runtime99.jsx)("span", { children: typeof displayValue === "object" ? JSON.stringify(displayValue) : formatNumberOnly(displayValue) });
|
|
33591
33594
|
}
|
|
@@ -33696,9 +33699,10 @@ var IntegerField = (props) => {
|
|
|
33696
33699
|
placeholder,
|
|
33697
33700
|
required: !invisible && required,
|
|
33698
33701
|
style: invisible ? { display: "none" } : {},
|
|
33699
|
-
className: `w-full
|
|
33700
|
-
|
|
33701
|
-
${
|
|
33702
|
+
className: `w-full h-full ring-0 focus:ring-0 focus:!outline-none outline-0 px-3 py-[12px] text-sm font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden
|
|
33703
|
+
${readonly ? "cursor-not-allowed border border-[rgba(66,66,66,0.12)] text-[#5c5a5a]" : "cursor-pointer border border-[rgba(66,66,66,0.12)] text-[#525866]"}
|
|
33704
|
+
${!isEditTable ? isForm ? "bg-white border-input-primary rounded-[10px]" : "" : "border-transparent border-b-primary bg-transparent"}
|
|
33705
|
+
${error2 && isEditTable && "focus:border-b-[1px] focus:border-[#de4747] hover:border-b-[1px] hover:border-[#de4747]"}
|
|
33702
33706
|
`
|
|
33703
33707
|
}
|
|
33704
33708
|
),
|
|
@@ -34091,7 +34095,7 @@ var Many2OneField = (props) => {
|
|
|
34091
34095
|
{
|
|
34092
34096
|
id: name2,
|
|
34093
34097
|
"data-tooltip-id": name2,
|
|
34094
|
-
className: `inline-block w-full ${readonly && "cursor-not-allowed"}`,
|
|
34098
|
+
className: `inline-block w-full h-full ${readonly && "cursor-not-allowed"}`,
|
|
34095
34099
|
children: /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(
|
|
34096
34100
|
Controller,
|
|
34097
34101
|
{
|
|
@@ -34113,14 +34117,14 @@ var Many2OneField = (props) => {
|
|
|
34113
34117
|
methods?.clearErrors(name2);
|
|
34114
34118
|
}
|
|
34115
34119
|
}, [selectedOption]);
|
|
34116
|
-
return /* @__PURE__ */ (0, import_jsx_runtime102.jsxs)("div", { className: "
|
|
34120
|
+
return /* @__PURE__ */ (0, import_jsx_runtime102.jsxs)("div", { className: "h-full", children: [
|
|
34117
34121
|
/* @__PURE__ */ (0, import_jsx_runtime102.jsx)(
|
|
34118
34122
|
StateManagedSelect$1,
|
|
34119
34123
|
{
|
|
34120
34124
|
menuShouldScrollIntoView: false,
|
|
34121
34125
|
options: options2,
|
|
34122
34126
|
classNames: {
|
|
34123
|
-
control: ({ isFocused }) => `w-full flex
|
|
34127
|
+
control: ({ isFocused }) => `w-full flex h-full ring-0 cursor-pointer outline-0 bg-white shadow-none rounded-[10px] py-2 px-3 text-sm text-[#1A1A1B] font-normal cursor-pointer gap-2 opacity-100 leading-5 resize-none overflow-hidden field-sizing-content ${isForm && (isFocused ? "!border-[1px] !border-primary !ring-0 outline-none" : "border !border-[rgba(66,66,66,0.12)]")} ${readonly && "!cursor-not-allowed"} ${isEditTable && "md:!min-w-[300px] max-w-[300px] !rounded-none !border !border-transparent !border-b !border-[#f7f7f7] hover:border-b-primary !bg-transparent min-h-auto"}`,
|
|
34124
34128
|
valueContainer: () => "!m-0 !p-0 ",
|
|
34125
34129
|
singleValue: () => `!m-0 ${readonly ? "!text-[#5c5a5a]" : ""}`,
|
|
34126
34130
|
input: () => "!m-0 !p-0",
|
|
@@ -34150,6 +34154,10 @@ var Many2OneField = (props) => {
|
|
|
34150
34154
|
menuPortalTarget: typeof window !== "undefined" ? document.body : null,
|
|
34151
34155
|
styles: {
|
|
34152
34156
|
control: () => ({}),
|
|
34157
|
+
container: (base) => ({
|
|
34158
|
+
...base,
|
|
34159
|
+
height: "100%"
|
|
34160
|
+
}),
|
|
34153
34161
|
clearIndicator: (base) => ({
|
|
34154
34162
|
...base,
|
|
34155
34163
|
padding: "0"
|
package/dist/widgets.mjs
CHANGED
|
@@ -11606,7 +11606,8 @@ var Row = (props) => {
|
|
|
11606
11606
|
setSelectedRowKeys,
|
|
11607
11607
|
onClickRow,
|
|
11608
11608
|
isAutoSelect,
|
|
11609
|
-
selectedRowKeysRef
|
|
11609
|
+
selectedRowKeysRef,
|
|
11610
|
+
isEditTable
|
|
11610
11611
|
} = props;
|
|
11611
11612
|
const checkboxRef = useRef2("enabled");
|
|
11612
11613
|
const checked = useMemo3(() => {
|
|
@@ -11682,7 +11683,7 @@ var Row = (props) => {
|
|
|
11682
11683
|
"td",
|
|
11683
11684
|
{
|
|
11684
11685
|
colSpan: 1,
|
|
11685
|
-
className:
|
|
11686
|
+
className: `${isEditTable ? "" : "p-3"} column w-max whitespace-nowrap border-b border-gray-200 text-sm font-normal text-gray-900`,
|
|
11686
11687
|
onClick: () => {
|
|
11687
11688
|
handleClickRow(col, row);
|
|
11688
11689
|
},
|
|
@@ -17894,8 +17895,10 @@ var CharField = (props) => {
|
|
|
17894
17895
|
disabled: readonly,
|
|
17895
17896
|
placeholder,
|
|
17896
17897
|
required: !invisible && required,
|
|
17897
|
-
className: `w-full
|
|
17898
|
-
|
|
17898
|
+
className: `w-full h-full ring-0 focus:ring-0 focus:!outline-none outline-0 px-3 py-[12px] text-sm font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden
|
|
17899
|
+
${readonly ? "cursor-not-allowed border border-[rgba(66,66,66,0.12)] text-[#5c5a5a]" : "cursor-pointer border border-[rgba(66,66,66,0.12)] text-[#525866]"}
|
|
17900
|
+
${!isEditTable ? isForm ? "bg-white border-input-primary rounded-[10px]" : "" : "border-transparent border-b-primary bg-transparent"}
|
|
17901
|
+
${error2 && isEditTable && "focus:border-b-[1px] focus:border-[#de4747] hover:border-b-[1px] hover:border-[#de4747]"}
|
|
17899
17902
|
`
|
|
17900
17903
|
}
|
|
17901
17904
|
),
|
|
@@ -31966,7 +31969,7 @@ var DateField = (props) => {
|
|
|
31966
31969
|
/* @__PURE__ */ jsx80(
|
|
31967
31970
|
"input",
|
|
31968
31971
|
{
|
|
31969
|
-
className:
|
|
31972
|
+
className: `bg-transparent w-full focus-visible:outline-none outline-none border-none ${readonly && "cursor-not-allowed"}`,
|
|
31970
31973
|
required,
|
|
31971
31974
|
readOnly: readonly,
|
|
31972
31975
|
type: "",
|
|
@@ -32059,7 +32062,7 @@ var DateField = (props) => {
|
|
|
32059
32062
|
{
|
|
32060
32063
|
isForm,
|
|
32061
32064
|
defaultValue: field.value,
|
|
32062
|
-
className: `${invisible ? "hidden" : ""} ${isEditTable ?
|
|
32065
|
+
className: `${invisible ? "hidden" : ""} ${isEditTable ? `pl-2 border-b-primary py-[12px] px-3 ${readonly && "cursor-not-allowed"}` : !isForm ? "!bg-transparent focus-within:!border-none" : `w-full h-full ring-0 focus:ring-0 focus:!outline-none focus:border-[1px] focus:border-[#16a730] outline-0 bg-white border border-[rgba(66,66,66,0.12)] rounded-[10px] px-3 py-[12px] text-sm text-[#525866] font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden ${readonly && "cursor-not-allowed"}`}`
|
|
32063
32066
|
}
|
|
32064
32067
|
),
|
|
32065
32068
|
timeInputLabel: textPlaceHolder,
|
|
@@ -32552,9 +32555,9 @@ var FloatField = (props) => {
|
|
|
32552
32555
|
placeholder,
|
|
32553
32556
|
required: !invisible && required,
|
|
32554
32557
|
style: invisible ? { display: "none" } : {},
|
|
32555
|
-
className: `w-full
|
|
32556
|
-
|
|
32557
|
-
${!isEditTable ? "bg-
|
|
32558
|
+
className: `w-full h-full ring-0 focus:ring-0 focus:!outline-none outline-0 px-3 py-[12px] text-sm font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden
|
|
32559
|
+
${readonly ? "cursor-not-allowed border border-[rgba(66,66,66,0.12)] text-[#5c5a5a]" : "cursor-pointer border border-[rgba(66,66,66,0.12)] text-[#525866]"}
|
|
32560
|
+
${!isEditTable ? isForm ? "bg-white border-input-primary rounded-[10px]" : "" : "border-transparent border-b-primary bg-transparent"}
|
|
32558
32561
|
${error2 && isEditTable && "focus:border-b-[1px] focus:border-[#de4747] hover:border-b-[1px] hover:border-[#de4747]"}
|
|
32559
32562
|
`
|
|
32560
32563
|
}
|
|
@@ -33522,7 +33525,7 @@ var IntegerField = (props) => {
|
|
|
33522
33525
|
string,
|
|
33523
33526
|
isEditTable
|
|
33524
33527
|
} = props;
|
|
33525
|
-
if (!isForm) {
|
|
33528
|
+
if (!isForm && !isEditTable) {
|
|
33526
33529
|
const displayValue = value ?? defaultValue;
|
|
33527
33530
|
return /* @__PURE__ */ jsx101("span", { children: typeof displayValue === "object" ? JSON.stringify(displayValue) : formatNumberOnly(displayValue) });
|
|
33528
33531
|
}
|
|
@@ -33633,9 +33636,10 @@ var IntegerField = (props) => {
|
|
|
33633
33636
|
placeholder,
|
|
33634
33637
|
required: !invisible && required,
|
|
33635
33638
|
style: invisible ? { display: "none" } : {},
|
|
33636
|
-
className: `w-full
|
|
33637
|
-
|
|
33638
|
-
${
|
|
33639
|
+
className: `w-full h-full ring-0 focus:ring-0 focus:!outline-none outline-0 px-3 py-[12px] text-sm font-normal gap-2 opacity-100 leading-[1.5] resize-none overflow-hidden
|
|
33640
|
+
${readonly ? "cursor-not-allowed border border-[rgba(66,66,66,0.12)] text-[#5c5a5a]" : "cursor-pointer border border-[rgba(66,66,66,0.12)] text-[#525866]"}
|
|
33641
|
+
${!isEditTable ? isForm ? "bg-white border-input-primary rounded-[10px]" : "" : "border-transparent border-b-primary bg-transparent"}
|
|
33642
|
+
${error2 && isEditTable && "focus:border-b-[1px] focus:border-[#de4747] hover:border-b-[1px] hover:border-[#de4747]"}
|
|
33639
33643
|
`
|
|
33640
33644
|
}
|
|
33641
33645
|
),
|
|
@@ -34028,7 +34032,7 @@ var Many2OneField = (props) => {
|
|
|
34028
34032
|
{
|
|
34029
34033
|
id: name2,
|
|
34030
34034
|
"data-tooltip-id": name2,
|
|
34031
|
-
className: `inline-block w-full ${readonly && "cursor-not-allowed"}`,
|
|
34035
|
+
className: `inline-block w-full h-full ${readonly && "cursor-not-allowed"}`,
|
|
34032
34036
|
children: /* @__PURE__ */ jsx104(
|
|
34033
34037
|
Controller,
|
|
34034
34038
|
{
|
|
@@ -34050,14 +34054,14 @@ var Many2OneField = (props) => {
|
|
|
34050
34054
|
methods?.clearErrors(name2);
|
|
34051
34055
|
}
|
|
34052
34056
|
}, [selectedOption]);
|
|
34053
|
-
return /* @__PURE__ */ jsxs72("div", { className: "
|
|
34057
|
+
return /* @__PURE__ */ jsxs72("div", { className: "h-full", children: [
|
|
34054
34058
|
/* @__PURE__ */ jsx104(
|
|
34055
34059
|
StateManagedSelect$1,
|
|
34056
34060
|
{
|
|
34057
34061
|
menuShouldScrollIntoView: false,
|
|
34058
34062
|
options: options2,
|
|
34059
34063
|
classNames: {
|
|
34060
|
-
control: ({ isFocused }) => `w-full flex
|
|
34064
|
+
control: ({ isFocused }) => `w-full flex h-full ring-0 cursor-pointer outline-0 bg-white shadow-none rounded-[10px] py-2 px-3 text-sm text-[#1A1A1B] font-normal cursor-pointer gap-2 opacity-100 leading-5 resize-none overflow-hidden field-sizing-content ${isForm && (isFocused ? "!border-[1px] !border-primary !ring-0 outline-none" : "border !border-[rgba(66,66,66,0.12)]")} ${readonly && "!cursor-not-allowed"} ${isEditTable && "md:!min-w-[300px] max-w-[300px] !rounded-none !border !border-transparent !border-b !border-[#f7f7f7] hover:border-b-primary !bg-transparent min-h-auto"}`,
|
|
34061
34065
|
valueContainer: () => "!m-0 !p-0 ",
|
|
34062
34066
|
singleValue: () => `!m-0 ${readonly ? "!text-[#5c5a5a]" : ""}`,
|
|
34063
34067
|
input: () => "!m-0 !p-0",
|
|
@@ -34087,6 +34091,10 @@ var Many2OneField = (props) => {
|
|
|
34087
34091
|
menuPortalTarget: typeof window !== "undefined" ? document.body : null,
|
|
34088
34092
|
styles: {
|
|
34089
34093
|
control: () => ({}),
|
|
34094
|
+
container: (base) => ({
|
|
34095
|
+
...base,
|
|
34096
|
+
height: "100%"
|
|
34097
|
+
}),
|
|
34090
34098
|
clearIndicator: (base) => ({
|
|
34091
34099
|
...base,
|
|
34092
34100
|
padding: "0"
|