@pdfme/ui 4.2.4-dev.11 → 4.2.4-dev.13
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.es.js
CHANGED
@@ -9264,7 +9264,9 @@ z.object({
|
|
9264
9264
|
addPageAfter: z.string(),
|
9265
9265
|
removePage: z.string(),
|
9266
9266
|
removePageConfirm: z.string(),
|
9267
|
-
|
9267
|
+
// --------------------validation-------------------
|
9268
|
+
"validation.uniqueName": z.string(),
|
9269
|
+
"validation.hexColor": z.string(),
|
9268
9270
|
// -----------------used in schemas-----------------
|
9269
9271
|
"schemas.color": z.string(),
|
9270
9272
|
"schemas.borderWidth": z.string(),
|
@@ -81828,7 +81830,7 @@ const UseDynamicFontSize = (a) => {
|
|
81828
81830
|
rules: [
|
81829
81831
|
{
|
81830
81832
|
pattern: HEX_COLOR_PATTERN,
|
81831
|
-
message: $("
|
81833
|
+
message: $("validation.hexColor")
|
81832
81834
|
}
|
81833
81835
|
]
|
81834
81836
|
},
|
@@ -81839,7 +81841,7 @@ const UseDynamicFontSize = (a) => {
|
|
81839
81841
|
rules: [
|
81840
81842
|
{
|
81841
81843
|
pattern: HEX_COLOR_PATTERN,
|
81842
|
-
message: $("
|
81844
|
+
message: $("validation.hexColor")
|
81843
81845
|
}
|
81844
81846
|
]
|
81845
81847
|
}
|
@@ -135174,7 +135176,8 @@ const MinusOutlined$1 = /* @__PURE__ */ reactExports.forwardRef(MinusOutlined),
|
|
135174
135176
|
addPageAfter: "Add Page After",
|
135175
135177
|
removePage: "Remove Current Page",
|
135176
135178
|
removePageConfirm: "Are you sure you want to delete this page? This action cannot be undone.",
|
135177
|
-
|
135179
|
+
"validation.hexColor": "Please enter a valid hex color code.",
|
135180
|
+
"validation.uniqueName": "Please enter a unique name.",
|
135178
135181
|
"schemas.color": "Color",
|
135179
135182
|
"schemas.borderWidth": "Border Width",
|
135180
135183
|
"schemas.borderColor": "Border Color",
|
@@ -135236,7 +135239,8 @@ const MinusOutlined$1 = /* @__PURE__ */ reactExports.forwardRef(MinusOutlined),
|
|
135236
135239
|
addPageAfter: "在之后添加页面",
|
135237
135240
|
removePage: "删除当前页面",
|
135238
135241
|
removePageConfirm: "您确定要删除此页面吗?此操作无法撤销。",
|
135239
|
-
|
135242
|
+
"validation.hexColor": "请输入有效的十六进制颜色代码。",
|
135243
|
+
"validation.uniqueName": "请输入一个唯一的名称。",
|
135240
135244
|
"schemas.color": "颜色",
|
135241
135245
|
"schemas.borderWidth": "边框宽度",
|
135242
135246
|
"schemas.borderColor": "边框颜色",
|
@@ -135298,7 +135302,8 @@ const MinusOutlined$1 = /* @__PURE__ */ reactExports.forwardRef(MinusOutlined),
|
|
135298
135302
|
addPageAfter: "次にページを追加",
|
135299
135303
|
removePage: "現在のページを削除",
|
135300
135304
|
removePageConfirm: "ページを削除してもよろしいですか?この操作は元に戻せません。",
|
135301
|
-
|
135305
|
+
"validation.hexColor": "有効な16進数のカラーコードを入力してください。",
|
135306
|
+
"validation.uniqueName": "一意の名前を入力してください。",
|
135302
135307
|
"schemas.color": "色",
|
135303
135308
|
"schemas.borderWidth": "枠線の太さ",
|
135304
135309
|
"schemas.borderColor": "枠線の色",
|
@@ -135360,7 +135365,8 @@ const MinusOutlined$1 = /* @__PURE__ */ reactExports.forwardRef(MinusOutlined),
|
|
135360
135365
|
addPageAfter: "다음에 페이지 추가",
|
135361
135366
|
removePage: "현재 페이지 제거",
|
135362
135367
|
removePageConfirm: "이 페이지를 삭제하시겠습니까? 이 작업은 취소할 수 없습니다.",
|
135363
|
-
|
135368
|
+
"validation.hexColor": "유효한 16진수 색상 코드를 입력하세요.",
|
135369
|
+
"validation.uniqueName": "고유한 이름을 입력하세요.",
|
135364
135370
|
"schemas.color": "색상",
|
135365
135371
|
"schemas.borderWidth": "테두리 너비",
|
135366
135372
|
"schemas.borderColor": "테두리 색상",
|
@@ -135422,7 +135428,8 @@ const MinusOutlined$1 = /* @__PURE__ */ reactExports.forwardRef(MinusOutlined),
|
|
135422
135428
|
addPageAfter: "إضافة صفحة بعد",
|
135423
135429
|
removePage: "احذف الصفحة الحالية",
|
135424
135430
|
removePageConfirm: "هل أنت متأكد من رغبتك في حذف هذه الصفحة؟ لا يمكن التراجع عن هذا الإجراء.",
|
135425
|
-
|
135431
|
+
"validation.hexColor": "الرجاء إدخال رمز لون سداسي عشري صالح.",
|
135432
|
+
"validation.uniqueName": "الرجاء إدخال اسم فريد.",
|
135426
135433
|
"schemas.color": "اللون",
|
135427
135434
|
"schemas.borderWidth": "عرض الحدود",
|
135428
135435
|
"schemas.borderColor": "لون الحدود",
|
@@ -135484,7 +135491,8 @@ const MinusOutlined$1 = /* @__PURE__ */ reactExports.forwardRef(MinusOutlined),
|
|
135484
135491
|
addPageAfter: "เพิ่มหน้าถัดไป",
|
135485
135492
|
removePage: "ลบหน้าปัจจุบัน",
|
135486
135493
|
removePageConfirm: "คุณแน่ใจหรือไม่ว่าต้องการลบหน้านี้? การกระทำนี้ไม่สามารถย้อนกลับได้",
|
135487
|
-
|
135494
|
+
"validation.hexColor": "กรุณาใส่รหัสสีแบบฐานสิบหกที่ถูกต้อง",
|
135495
|
+
"validation.uniqueName": "กรุณาระบุชื่อที่ไม่ซ้ำ",
|
135488
135496
|
"schemas.color": "สี",
|
135489
135497
|
"schemas.borderWidth": "ความกว้างของเส้นขอบ",
|
135490
135498
|
"schemas.borderColor": "สีขอบ",
|
@@ -135546,7 +135554,8 @@ const MinusOutlined$1 = /* @__PURE__ */ reactExports.forwardRef(MinusOutlined),
|
|
135546
135554
|
addPageAfter: "Aggiungi pagina dopo",
|
135547
135555
|
removePage: "Rimuovi la Pagina Corrente",
|
135548
135556
|
removePageConfirm: "Sei sicuro di voler eliminare questa pagina? Questa azione non può essere annullata.",
|
135549
|
-
|
135557
|
+
"validation.hexColor": "Inserisci un codice colore esadecimale valido.",
|
135558
|
+
"validation.uniqueName": "Inserisci un nome univoco.",
|
135550
135559
|
"schemas.color": "Colore",
|
135551
135560
|
"schemas.borderWidth": "Spessore bordo",
|
135552
135561
|
"schemas.borderColor": "Colore bordo",
|
@@ -135608,7 +135617,8 @@ const MinusOutlined$1 = /* @__PURE__ */ reactExports.forwardRef(MinusOutlined),
|
|
135608
135617
|
addPageAfter: "Dodaj stronę po",
|
135609
135618
|
removePage: "Usuń Bieżącą Stronę",
|
135610
135619
|
removePageConfirm: "Czy na pewno chcesz usunąć tę stronę? Tej operacji nie można cofnąć.",
|
135611
|
-
|
135620
|
+
"validation.hexColor": "Wprowadź poprawny kod koloru szesnastkowego.",
|
135621
|
+
"validation.uniqueName": "Proszę wpisać unikalną nazwę.",
|
135612
135622
|
"schemas.color": "Kolor",
|
135613
135623
|
"schemas.borderWidth": "Szerokość obramowania",
|
135614
135624
|
"schemas.borderColor": "Kolor obramowania",
|
@@ -135670,7 +135680,8 @@ const MinusOutlined$1 = /* @__PURE__ */ reactExports.forwardRef(MinusOutlined),
|
|
135670
135680
|
addPageAfter: "Seite danach hinzufügen",
|
135671
135681
|
removePage: "Aktuelle Seite entfernen",
|
135672
135682
|
removePageConfirm: "Sind Sie sicher, dass Sie diese Seite löschen möchten? Diese Aktion kann nicht rückgängig gemacht werden.",
|
135673
|
-
|
135683
|
+
"validation.hexColor": "Bitte geben Sie einen gültigen Hex-Farbcode ein.",
|
135684
|
+
"validation.uniqueName": "Bitte geben Sie einen eindeutigen Namen ein.",
|
135674
135685
|
"schemas.color": "Farbe",
|
135675
135686
|
"schemas.borderWidth": "Rahmenbreite",
|
135676
135687
|
"schemas.borderColor": "Rahmenfarbe",
|
@@ -135732,7 +135743,8 @@ const MinusOutlined$1 = /* @__PURE__ */ reactExports.forwardRef(MinusOutlined),
|
|
135732
135743
|
addPageAfter: "Insertar página",
|
135733
135744
|
removePage: "Eliminar página actual",
|
135734
135745
|
removePageConfirm: "¿Estás seguro de que quieres eliminar esta página? Esta acción no se puede deshacer.",
|
135735
|
-
|
135746
|
+
"validation.hexColor": "Introduce un código de color hexadecimal válido.",
|
135747
|
+
"validation.uniqueName": "Por favor, introduzca un nombre único.",
|
135736
135748
|
"schemas.color": "Color",
|
135737
135749
|
"schemas.borderWidth": "Ancho del borde",
|
135738
135750
|
"schemas.borderColor": "Color del borde",
|
@@ -135794,7 +135806,8 @@ const MinusOutlined$1 = /* @__PURE__ */ reactExports.forwardRef(MinusOutlined),
|
|
135794
135806
|
addPageAfter: "Ajouter une page après",
|
135795
135807
|
removePage: "Supprimer la page actuelle",
|
135796
135808
|
removePageConfirm: "Êtes-vous sûr de vouloir supprimer cette page ? Cette action est irréversible.",
|
135797
|
-
|
135809
|
+
"validation.hexColor": "Veuillez entrer un code couleur hexadécimal valide.",
|
135810
|
+
"validation.uniqueName": "Veuillez saisir un nom unique.",
|
135798
135811
|
"schemas.color": "Couleur",
|
135799
135812
|
"schemas.borderWidth": "Largeur de la bordure",
|
135800
135813
|
"schemas.borderColor": "Couleur de la bordure",
|
@@ -151921,85 +151934,102 @@ const FormRender = withProvider(FormCore, defaultWidgets), svgBaseProp = {
|
|
151921
151934
|
);
|
151922
151935
|
}) }) });
|
151923
151936
|
}, ButtonGroupWidget$1 = ButtonGroupWidget, { Text: Text$2 } = Typography$1, DetailView = (a) => {
|
151924
|
-
const { token: s } = theme.useToken(), { size: $,
|
151937
|
+
const { token: s } = theme.useToken(), { size: $, schemas: _, changeSchemas: _e, deselectSchema: tt, activeSchema: nt } = a, at = useForm(), ot = reactExports.useContext(I18nContext), rt = reactExports.useContext(PluginsRegistry), st = reactExports.useContext(OptionsContext), [lt, et] = reactExports.useState({});
|
151925
151938
|
reactExports.useEffect(() => {
|
151926
|
-
const
|
151927
|
-
AlignWidget: (
|
151939
|
+
const ct = {
|
151940
|
+
AlignWidget: (vt) => /* @__PURE__ */ jsxRuntimeExports.jsx(AlignWidget$1, { ...vt, ...a, options: st }),
|
151928
151941
|
Divider: () => /* @__PURE__ */ jsxRuntimeExports.jsx(Divider$1, { style: { marginTop: s.marginXS, marginBottom: s.marginXS } }),
|
151929
|
-
ButtonGroup: (
|
151942
|
+
ButtonGroup: (vt) => /* @__PURE__ */ jsxRuntimeExports.jsx(ButtonGroupWidget$1, { ...vt, ...a, options: st })
|
151930
151943
|
};
|
151931
|
-
for (const
|
151932
|
-
const
|
151933
|
-
Object.entries(
|
151934
|
-
|
151944
|
+
for (const vt of Object.values(rt)) {
|
151945
|
+
const At = (vt == null ? void 0 : vt.propPanel.widgets) || {};
|
151946
|
+
Object.entries(At).forEach(([xt, bt]) => {
|
151947
|
+
ct[xt] = (Et) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
151935
151948
|
WidgetRenderer$1,
|
151936
151949
|
{
|
151937
|
-
...
|
151950
|
+
...Et,
|
151938
151951
|
...a,
|
151939
|
-
options:
|
151952
|
+
options: st,
|
151940
151953
|
theme: s,
|
151941
|
-
i18n:
|
151942
|
-
widget:
|
151954
|
+
i18n: ot,
|
151955
|
+
widget: bt
|
151943
151956
|
}
|
151944
151957
|
);
|
151945
151958
|
});
|
151946
151959
|
}
|
151947
|
-
|
151948
|
-
}, [
|
151949
|
-
const
|
151950
|
-
|
151951
|
-
}, [
|
151952
|
-
|
151953
|
-
|
151954
|
-
|
151955
|
-
|
151956
|
-
|
151960
|
+
et(ct);
|
151961
|
+
}, [nt, rt, JSON.stringify(st)]), reactExports.useEffect(() => {
|
151962
|
+
const ct = { ...nt };
|
151963
|
+
ct.x = ct.position.x, ct.y = ct.position.y, delete ct.position, at.setValues(ct);
|
151964
|
+
}, [nt, at]), reactExports.useEffect(() => at.resetFields(), [nt.id]), reactExports.useEffect(() => {
|
151965
|
+
it.current = (ct) => {
|
151966
|
+
for (const vt of Object.values(_))
|
151967
|
+
if (vt.key === ct && vt.id !== nt.id)
|
151968
|
+
return !1;
|
151969
|
+
return !0;
|
151970
|
+
};
|
151971
|
+
}, [_, nt]);
|
151972
|
+
const it = reactExports.useRef((ct) => !0), ut = (ct, vt) => it.current(vt), ft = debounce$1((ct) => {
|
151973
|
+
const vt = (xt, bt) => typeof xt == "object" ? JSON.stringify(xt) !== JSON.stringify(bt) : xt !== bt;
|
151974
|
+
let At = [];
|
151975
|
+
for (let xt in ct) {
|
151976
|
+
if (["id", "content"].includes(xt))
|
151957
151977
|
continue;
|
151958
|
-
let
|
151959
|
-
["x", "y"].includes(
|
151978
|
+
let bt = ct[xt], Et = !1;
|
151979
|
+
["x", "y"].includes(xt) ? (Et = bt !== nt.position[xt], xt = "position." + xt) : Et = vt(bt, nt[xt]), Et && (bt === null && ["rotate", "opacity"].includes(xt) && (bt = void 0), At.push({ key: xt, value: bt, schemaId: nt.id }));
|
151960
151980
|
}
|
151961
|
-
|
151962
|
-
|
151963
|
-
(
|
151964
|
-
))),
|
151981
|
+
At.length && at.validateFields().then(() => _e(At)).catch((xt) => {
|
151982
|
+
xt.errorFields.length && (At = At.filter((bt) => !xt.errorFields.find(
|
151983
|
+
(Et) => Et.name.includes(bt.key)
|
151984
|
+
))), At.length && _e(At);
|
151965
151985
|
});
|
151966
|
-
},
|
151967
|
-
(
|
151968
|
-
),
|
151969
|
-
|
151986
|
+
}, 500), ht = Object.values(rt).find(
|
151987
|
+
(ct) => (ct == null ? void 0 : ct.propPanel.defaultSchema.type) === nt.type
|
151988
|
+
), dt = ht == null ? void 0 : ht.propPanel.schema;
|
151989
|
+
dt || console.error(`[@pdfme/ui] No propPanel.schema for ${nt.type}.
|
151970
151990
|
Check this document: https://pdfme.com/docs/custom-schemas`);
|
151971
|
-
const
|
151972
|
-
label:
|
151973
|
-
value:
|
151974
|
-
})),
|
151991
|
+
const gt = Object.entries(rt).map(([ct, vt]) => ({
|
151992
|
+
label: ct,
|
151993
|
+
value: vt == null ? void 0 : vt.propPanel.defaultSchema.type
|
151994
|
+
})), pt = ht.propPanel.defaultSchema, mt = {
|
151975
151995
|
type: "object",
|
151976
151996
|
column: 2,
|
151977
151997
|
properties: {
|
151978
151998
|
type: {
|
151979
|
-
title:
|
151999
|
+
title: ot("type"),
|
151980
152000
|
type: "string",
|
151981
152001
|
widget: "select",
|
151982
|
-
props: { options:
|
152002
|
+
props: { options: gt },
|
151983
152003
|
required: !0,
|
151984
152004
|
span: 12
|
151985
152005
|
},
|
151986
|
-
key: {
|
151987
|
-
|
152006
|
+
key: {
|
152007
|
+
title: ot("fieldName"),
|
152008
|
+
type: "string",
|
152009
|
+
required: !0,
|
152010
|
+
span: 12,
|
152011
|
+
rules: [{
|
152012
|
+
validator: ut,
|
152013
|
+
message: ot("validation.uniqueName")
|
152014
|
+
}],
|
152015
|
+
props: { autocomplete: "off" }
|
152016
|
+
},
|
152017
|
+
required: { title: ot("required"), type: "boolean", span: 8, hidden: pt == null ? void 0 : pt.readOnly },
|
151988
152018
|
"-": { type: "void", widget: "Divider" },
|
151989
|
-
align: { title:
|
152019
|
+
align: { title: ot("align"), type: "void", widget: "AlignWidget" },
|
151990
152020
|
x: { title: "X", type: "number", widget: "inputNumber", required: !0, span: 8, min: 0 },
|
151991
152021
|
y: { title: "Y", type: "number", widget: "inputNumber", required: !0, span: 8, min: 0 },
|
151992
152022
|
rotate: {
|
151993
|
-
title:
|
152023
|
+
title: ot("rotate"),
|
151994
152024
|
type: "number",
|
151995
152025
|
widget: "inputNumber",
|
151996
|
-
disabled: (
|
152026
|
+
disabled: (pt == null ? void 0 : pt.rotate) === void 0,
|
151997
152027
|
max: 360,
|
151998
152028
|
props: { min: 0 },
|
151999
152029
|
span: 8
|
152000
152030
|
},
|
152001
152031
|
width: {
|
152002
|
-
title:
|
152032
|
+
title: ot("width"),
|
152003
152033
|
type: "number",
|
152004
152034
|
widget: "inputNumber",
|
152005
152035
|
required: !0,
|
@@ -152007,7 +152037,7 @@ Check this document: https://pdfme.com/docs/custom-schemas`);
|
|
152007
152037
|
props: { min: 0 }
|
152008
152038
|
},
|
152009
152039
|
height: {
|
152010
|
-
title:
|
152040
|
+
title: ot("height"),
|
152011
152041
|
type: "number",
|
152012
152042
|
widget: "inputNumber",
|
152013
152043
|
required: !0,
|
@@ -152015,33 +152045,33 @@ Check this document: https://pdfme.com/docs/custom-schemas`);
|
|
152015
152045
|
props: { min: 0 }
|
152016
152046
|
},
|
152017
152047
|
opacity: {
|
152018
|
-
title:
|
152048
|
+
title: ot("opacity"),
|
152019
152049
|
type: "number",
|
152020
152050
|
widget: "inputNumber",
|
152021
|
-
disabled: (
|
152051
|
+
disabled: (pt == null ? void 0 : pt.opacity) === void 0,
|
152022
152052
|
props: { step: 0.1, min: 0, max: 1 },
|
152023
152053
|
span: 8
|
152024
152054
|
}
|
152025
152055
|
}
|
152026
152056
|
};
|
152027
|
-
if (typeof
|
152028
|
-
const
|
152057
|
+
if (typeof dt == "function") {
|
152058
|
+
const ct = dt({
|
152029
152059
|
...a,
|
152030
|
-
options:
|
152060
|
+
options: st,
|
152031
152061
|
theme: s,
|
152032
|
-
i18n:
|
152062
|
+
i18n: ot
|
152033
152063
|
}) || {};
|
152034
|
-
|
152035
|
-
...
|
152036
|
-
...Object.keys(
|
152037
|
-
...
|
152064
|
+
mt.properties = {
|
152065
|
+
...mt.properties,
|
152066
|
+
...Object.keys(ct).length === 0 ? {} : { "--": { type: "void", widget: "Divider" } },
|
152067
|
+
...ct
|
152038
152068
|
};
|
152039
152069
|
} else {
|
152040
|
-
const
|
152041
|
-
|
152042
|
-
...
|
152043
|
-
...Object.keys(
|
152044
|
-
...
|
152070
|
+
const ct = dt || {};
|
152071
|
+
mt.properties = {
|
152072
|
+
...mt.properties,
|
152073
|
+
...Object.keys(ct).length === 0 ? {} : { "--": { type: "void", widget: "Divider" } },
|
152074
|
+
...ct
|
152045
152075
|
};
|
152046
152076
|
}
|
152047
152077
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
|
@@ -152056,11 +152086,11 @@ Check this document: https://pdfme.com/docs/custom-schemas`);
|
|
152056
152086
|
alignItems: "center",
|
152057
152087
|
justifyContent: "center"
|
152058
152088
|
},
|
152059
|
-
onClick:
|
152089
|
+
onClick: tt,
|
152060
152090
|
icon: /* @__PURE__ */ jsxRuntimeExports.jsx(MenuOutlined$1, {})
|
152061
152091
|
}
|
152062
152092
|
),
|
152063
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(Text$2, { strong: !0, style: { textAlign: "center", width: "100%" }, children:
|
152093
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Text$2, { strong: !0, style: { textAlign: "center", width: "100%" }, children: ot("editField") })
|
152064
152094
|
] }),
|
152065
152095
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Divider$1, { style: { marginTop: s.marginXS, marginBottom: s.marginXS } }),
|
152066
152096
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
@@ -152074,10 +152104,10 @@ Check this document: https://pdfme.com/docs/custom-schemas`);
|
|
152074
152104
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
152075
152105
|
FormRender,
|
152076
152106
|
{
|
152077
|
-
form:
|
152078
|
-
schema:
|
152079
|
-
widgets:
|
152080
|
-
watch: { "#":
|
152107
|
+
form: at,
|
152108
|
+
schema: mt,
|
152109
|
+
widgets: lt,
|
152110
|
+
watch: { "#": ft },
|
152081
152111
|
locale: "en-US"
|
152082
152112
|
}
|
152083
152113
|
)
|
@@ -162392,21 +162422,26 @@ const Guides$2 = Guides$1, guideStyle = (a, s, $, _) => ({
|
|
162392
162422
|
const Dt = await template2SchemasList(Tt);
|
162393
162423
|
dt(Dt), Ct(), pt(0), (Ut = at.current) != null && Ut.scroll && at.current.scroll({ top: 0, behavior: "smooth" });
|
162394
162424
|
}, []), jt = (Tt) => {
|
162395
|
-
const [Dt, Ut, Vt, Qt] = isBlankPdf(a.basePdf) ? a.basePdf.padding : [0, 0, 0, 0], qt = St[gt], Zt = (
|
162425
|
+
const [Dt, Ut, Vt, Qt] = isBlankPdf(a.basePdf) ? a.basePdf.padding : [0, 0, 0, 0], qt = St[gt], Zt = (rr) => {
|
162426
|
+
let Yt = ht[gt].length + 1, Kt = rr + Yt;
|
162427
|
+
for (; ht[gt].find((nr) => nr.key === Kt); )
|
162428
|
+
Yt++, Kt = rr + Yt;
|
162429
|
+
return Kt;
|
162430
|
+
}, ar = (rr, Yt, Kt) => Math.min(Math.max(rr, Yt), Kt), Jt = {
|
162396
162431
|
id: uuid$6(),
|
162397
|
-
key:
|
162432
|
+
key: Zt(rt("field")),
|
162398
162433
|
...Tt,
|
162399
162434
|
position: {
|
162400
|
-
x:
|
162401
|
-
y:
|
162435
|
+
x: ar(Qt, Tt.position.x, qt.width - Ut - Tt.width),
|
162436
|
+
y: ar(Dt, Tt.position.y, qt.height - Vt - Tt.height)
|
162402
162437
|
},
|
162403
162438
|
required: Tt.readOnly ? !1 : lt.requiredByDefault || Tt.required || !1
|
162404
162439
|
};
|
162405
162440
|
if (Tt.position.y === 0) {
|
162406
|
-
const
|
162407
|
-
|
162441
|
+
const rr = ot.current[gt], Yt = rr ? rr.getBoundingClientRect().top : 0;
|
162442
|
+
Jt.position.y = Yt > 0 ? Dt : St[gt].height / 2;
|
162408
162443
|
}
|
162409
|
-
It(ht[gt].concat(
|
162444
|
+
It(ht[gt].concat(Jt)), setTimeout(() => wt([document.getElementById(Jt.id)]));
|
162410
162445
|
}, Ht = (Tt) => {
|
162411
162446
|
It(Tt);
|
162412
162447
|
}, Ft = (Tt) => {
|