@firecms/collection_editor 3.0.0-canary.237 → 3.0.0-canary.239
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 +384 -340
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +383 -339
- package/dist/index.umd.js.map +1 -1
- package/package.json +8 -8
- package/src/ui/collection_editor/CollectionDetailsForm.tsx +19 -0
package/dist/index.umd.js
CHANGED
|
@@ -169,7 +169,7 @@
|
|
|
169
169
|
return t18;
|
|
170
170
|
}
|
|
171
171
|
function CollectionDetailsForm(t0) {
|
|
172
|
-
const $ = reactCompilerRuntime.c(
|
|
172
|
+
const $ = reactCompilerRuntime.c(186);
|
|
173
173
|
const {
|
|
174
174
|
isNewCollection,
|
|
175
175
|
reservedGroups,
|
|
@@ -475,101 +475,143 @@
|
|
|
475
475
|
} else {
|
|
476
476
|
t40 = $[58];
|
|
477
477
|
}
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
] });
|
|
484
|
-
$[59] = t41;
|
|
485
|
-
} else {
|
|
486
|
-
t41 = $[59];
|
|
487
|
-
}
|
|
488
|
-
const t42 = !isNewCollection;
|
|
489
|
-
const t43 = showErrors && Boolean(errors.id);
|
|
490
|
-
let t44;
|
|
491
|
-
if ($[60] !== t42 || $[61] !== t43) {
|
|
492
|
-
t44 = /* @__PURE__ */ jsxRuntime.jsx(formex.Field, { name: "id", as: ui.DebouncedTextField, disabled: t42, label: "Collection id", error: t43 });
|
|
478
|
+
const t41 = values.history === null ? "Document history revisions enabled if enabled globally" : values.history ? "Document history revisions ENABLED" : "Document history revisions NOT enabled";
|
|
479
|
+
let t42;
|
|
480
|
+
if ($[59] !== setFieldValue) {
|
|
481
|
+
t42 = (v) => setFieldValue("history", v);
|
|
482
|
+
$[59] = setFieldValue;
|
|
493
483
|
$[60] = t42;
|
|
494
|
-
$[61] = t43;
|
|
495
|
-
$[62] = t44;
|
|
496
484
|
} else {
|
|
497
|
-
|
|
485
|
+
t42 = $[60];
|
|
498
486
|
}
|
|
499
|
-
const
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
$[
|
|
505
|
-
$[
|
|
506
|
-
$[
|
|
487
|
+
const t43 = values.history ?? null;
|
|
488
|
+
let t44;
|
|
489
|
+
if ($[61] !== t41 || $[62] !== t42 || $[63] !== t43) {
|
|
490
|
+
t44 = /* @__PURE__ */ jsxRuntime.jsx(ui.BooleanSwitchWithLabel, { position: "start", size: "large", allowIndeterminate: true, label: t41, onValueChange: t42, value: t43 });
|
|
491
|
+
$[61] = t41;
|
|
492
|
+
$[62] = t42;
|
|
493
|
+
$[63] = t43;
|
|
494
|
+
$[64] = t44;
|
|
495
|
+
} else {
|
|
496
|
+
t44 = $[64];
|
|
497
|
+
}
|
|
498
|
+
let t45;
|
|
499
|
+
if ($[65] === Symbol.for("react.memo_cache_sentinel")) {
|
|
500
|
+
t45 = /* @__PURE__ */ jsxRuntime.jsxs(core.FieldCaption, { children: [
|
|
501
|
+
"When enabled, each document in this collection will have a history of changes. This is useful for auditing purposes. The data is stored in a subcollection of the document in your database, called ",
|
|
502
|
+
/* @__PURE__ */ jsxRuntime.jsx("b", { children: "__history" }),
|
|
503
|
+
"."
|
|
504
|
+
] });
|
|
505
|
+
$[65] = t45;
|
|
507
506
|
} else {
|
|
508
|
-
|
|
507
|
+
t45 = $[65];
|
|
509
508
|
}
|
|
510
|
-
let
|
|
511
|
-
if ($[66] !== t44
|
|
512
|
-
|
|
509
|
+
let t46;
|
|
510
|
+
if ($[66] !== t44) {
|
|
511
|
+
t46 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "col-span-12", children: [
|
|
513
512
|
t44,
|
|
514
|
-
|
|
513
|
+
t45
|
|
515
514
|
] });
|
|
516
515
|
$[66] = t44;
|
|
517
|
-
$[67] =
|
|
518
|
-
|
|
516
|
+
$[67] = t46;
|
|
517
|
+
} else {
|
|
518
|
+
t46 = $[67];
|
|
519
|
+
}
|
|
520
|
+
let t47;
|
|
521
|
+
if ($[68] === Symbol.for("react.memo_cache_sentinel")) {
|
|
522
|
+
t47 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-row text-surface-500", children: [
|
|
523
|
+
/* @__PURE__ */ jsxRuntime.jsx(ui.SettingsIcon, {}),
|
|
524
|
+
/* @__PURE__ */ jsxRuntime.jsx(ui.Typography, { variant: "subtitle2", className: "ml-2", children: "Advanced" })
|
|
525
|
+
] });
|
|
526
|
+
$[68] = t47;
|
|
519
527
|
} else {
|
|
520
|
-
|
|
528
|
+
t47 = $[68];
|
|
521
529
|
}
|
|
522
|
-
const
|
|
530
|
+
const t48 = !isNewCollection;
|
|
531
|
+
const t49 = showErrors && Boolean(errors.id);
|
|
523
532
|
let t50;
|
|
524
|
-
if ($[69] !==
|
|
525
|
-
t50 = (
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
};
|
|
529
|
-
$[69] = handleChange;
|
|
530
|
-
$[70] = setFieldTouched;
|
|
533
|
+
if ($[69] !== t48 || $[70] !== t49) {
|
|
534
|
+
t50 = /* @__PURE__ */ jsxRuntime.jsx(formex.Field, { name: "id", as: ui.DebouncedTextField, disabled: t48, label: "Collection id", error: t49 });
|
|
535
|
+
$[69] = t48;
|
|
536
|
+
$[70] = t49;
|
|
531
537
|
$[71] = t50;
|
|
532
538
|
} else {
|
|
533
539
|
t50 = $[71];
|
|
534
540
|
}
|
|
535
|
-
const t51 =
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
$[
|
|
541
|
-
$[
|
|
542
|
-
$[
|
|
543
|
-
} else {
|
|
544
|
-
|
|
545
|
-
}
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
541
|
+
const t51 = touched.id && Boolean(errors.id);
|
|
542
|
+
const t52 = touched.id && Boolean(errors.id) ? errors.id : "This id identifies this collection. Typically the same as the path.";
|
|
543
|
+
let t53;
|
|
544
|
+
if ($[72] !== t51 || $[73] !== t52) {
|
|
545
|
+
t53 = /* @__PURE__ */ jsxRuntime.jsx(core.FieldCaption, { error: t51, children: t52 });
|
|
546
|
+
$[72] = t51;
|
|
547
|
+
$[73] = t52;
|
|
548
|
+
$[74] = t53;
|
|
549
|
+
} else {
|
|
550
|
+
t53 = $[74];
|
|
551
|
+
}
|
|
552
|
+
let t54;
|
|
553
|
+
if ($[75] !== t50 || $[76] !== t53) {
|
|
554
|
+
t54 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "col-span-12", children: [
|
|
555
|
+
t50,
|
|
556
|
+
t53
|
|
557
|
+
] });
|
|
558
|
+
$[75] = t50;
|
|
551
559
|
$[76] = t53;
|
|
552
560
|
$[77] = t54;
|
|
553
|
-
$[78] = t55;
|
|
554
561
|
} else {
|
|
555
|
-
|
|
562
|
+
t54 = $[77];
|
|
556
563
|
}
|
|
564
|
+
const t55 = showErrors && Boolean(errors.singularName);
|
|
557
565
|
let t56;
|
|
558
|
-
if ($[
|
|
559
|
-
t56 =
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
$[
|
|
564
|
-
$[
|
|
565
|
-
$[
|
|
566
|
+
if ($[78] !== handleChange || $[79] !== setFieldTouched) {
|
|
567
|
+
t56 = (e_0) => {
|
|
568
|
+
setFieldTouched("singularName", true);
|
|
569
|
+
return handleChange(e_0);
|
|
570
|
+
};
|
|
571
|
+
$[78] = handleChange;
|
|
572
|
+
$[79] = setFieldTouched;
|
|
573
|
+
$[80] = t56;
|
|
566
574
|
} else {
|
|
567
|
-
t56 = $[
|
|
575
|
+
t56 = $[80];
|
|
568
576
|
}
|
|
569
|
-
const t57 =
|
|
577
|
+
const t57 = values.singularName ?? "";
|
|
570
578
|
let t58;
|
|
571
|
-
if ($[82] !==
|
|
572
|
-
t58 = (
|
|
579
|
+
if ($[81] !== t55 || $[82] !== t56 || $[83] !== t57) {
|
|
580
|
+
t58 = /* @__PURE__ */ jsxRuntime.jsx(ui.TextField, { error: t55, name: "singularName", "aria-describedby": "singularName-helper", onChange: t56, value: t57, label: "Singular name" });
|
|
581
|
+
$[81] = t55;
|
|
582
|
+
$[82] = t56;
|
|
583
|
+
$[83] = t57;
|
|
584
|
+
$[84] = t58;
|
|
585
|
+
} else {
|
|
586
|
+
t58 = $[84];
|
|
587
|
+
}
|
|
588
|
+
const t59 = showErrors && Boolean(errors.singularName);
|
|
589
|
+
const t60 = showErrors && Boolean(errors.singularName) ? errors.singularName : "Optionally define a singular name for your entities";
|
|
590
|
+
let t61;
|
|
591
|
+
if ($[85] !== t59 || $[86] !== t60) {
|
|
592
|
+
t61 = /* @__PURE__ */ jsxRuntime.jsx(core.FieldCaption, { error: t59, children: t60 });
|
|
593
|
+
$[85] = t59;
|
|
594
|
+
$[86] = t60;
|
|
595
|
+
$[87] = t61;
|
|
596
|
+
} else {
|
|
597
|
+
t61 = $[87];
|
|
598
|
+
}
|
|
599
|
+
let t62;
|
|
600
|
+
if ($[88] !== t58 || $[89] !== t61) {
|
|
601
|
+
t62 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "col-span-12", children: [
|
|
602
|
+
t58,
|
|
603
|
+
t61
|
|
604
|
+
] });
|
|
605
|
+
$[88] = t58;
|
|
606
|
+
$[89] = t61;
|
|
607
|
+
$[90] = t62;
|
|
608
|
+
} else {
|
|
609
|
+
t62 = $[90];
|
|
610
|
+
}
|
|
611
|
+
const t63 = showErrors && Boolean(errors.sideDialogWidth);
|
|
612
|
+
let t64;
|
|
613
|
+
if ($[91] !== setFieldTouched || $[92] !== setFieldValue) {
|
|
614
|
+
t64 = (e_1) => {
|
|
573
615
|
setFieldTouched("sideDialogWidth", true);
|
|
574
616
|
const value_0 = e_1.target.value;
|
|
575
617
|
if (!value_0) {
|
|
@@ -580,360 +622,362 @@
|
|
|
580
622
|
}
|
|
581
623
|
}
|
|
582
624
|
};
|
|
583
|
-
$[
|
|
584
|
-
$[
|
|
585
|
-
$[
|
|
625
|
+
$[91] = setFieldTouched;
|
|
626
|
+
$[92] = setFieldValue;
|
|
627
|
+
$[93] = t64;
|
|
586
628
|
} else {
|
|
587
|
-
|
|
629
|
+
t64 = $[93];
|
|
588
630
|
}
|
|
589
|
-
let
|
|
590
|
-
if ($[
|
|
591
|
-
|
|
631
|
+
let t65;
|
|
632
|
+
if ($[94] !== setFieldValue) {
|
|
633
|
+
t65 = () => {
|
|
592
634
|
setFieldValue("sideDialogWidth", null);
|
|
593
635
|
};
|
|
594
|
-
$[
|
|
595
|
-
$[
|
|
636
|
+
$[94] = setFieldValue;
|
|
637
|
+
$[95] = t65;
|
|
596
638
|
} else {
|
|
597
|
-
|
|
639
|
+
t65 = $[95];
|
|
598
640
|
}
|
|
599
|
-
const
|
|
600
|
-
let t61;
|
|
601
|
-
if ($[87] === Symbol.for("react.memo_cache_sentinel")) {
|
|
602
|
-
t61 = /* @__PURE__ */ jsxRuntime.jsx(ui.CloseIcon, { size: "small" });
|
|
603
|
-
$[87] = t61;
|
|
604
|
-
} else {
|
|
605
|
-
t61 = $[87];
|
|
606
|
-
}
|
|
607
|
-
let t62;
|
|
608
|
-
if ($[88] !== t59 || $[89] !== t60) {
|
|
609
|
-
t62 = /* @__PURE__ */ jsxRuntime.jsx(ui.IconButton, { size: "small", onClick: t59, disabled: t60, children: t61 });
|
|
610
|
-
$[88] = t59;
|
|
611
|
-
$[89] = t60;
|
|
612
|
-
$[90] = t62;
|
|
613
|
-
} else {
|
|
614
|
-
t62 = $[90];
|
|
615
|
-
}
|
|
616
|
-
const t63 = values.sideDialogWidth ?? "";
|
|
617
|
-
let t64;
|
|
618
|
-
if ($[91] !== t57 || $[92] !== t58 || $[93] !== t62 || $[94] !== t63) {
|
|
619
|
-
t64 = /* @__PURE__ */ jsxRuntime.jsx(ui.TextField, { error: t57, name: "sideDialogWidth", type: "number", "aria-describedby": "sideDialogWidth-helper", onChange: t58, endAdornment: t62, value: t63, label: "Side dialog width" });
|
|
620
|
-
$[91] = t57;
|
|
621
|
-
$[92] = t58;
|
|
622
|
-
$[93] = t62;
|
|
623
|
-
$[94] = t63;
|
|
624
|
-
$[95] = t64;
|
|
625
|
-
} else {
|
|
626
|
-
t64 = $[95];
|
|
627
|
-
}
|
|
628
|
-
const t65 = showErrors && Boolean(errors.singularName);
|
|
629
|
-
const t66 = showErrors && Boolean(errors.singularName) ? errors.singularName : "Optionally define the width (in pixels) of entities side dialog. Default is 768px";
|
|
641
|
+
const t66 = !values.sideDialogWidth;
|
|
630
642
|
let t67;
|
|
631
|
-
if ($[96]
|
|
632
|
-
t67 = /* @__PURE__ */ jsxRuntime.jsx(
|
|
633
|
-
$[96] =
|
|
634
|
-
$[97] = t66;
|
|
635
|
-
$[98] = t67;
|
|
643
|
+
if ($[96] === Symbol.for("react.memo_cache_sentinel")) {
|
|
644
|
+
t67 = /* @__PURE__ */ jsxRuntime.jsx(ui.CloseIcon, { size: "small" });
|
|
645
|
+
$[96] = t67;
|
|
636
646
|
} else {
|
|
637
|
-
t67 = $[
|
|
647
|
+
t67 = $[96];
|
|
638
648
|
}
|
|
639
649
|
let t68;
|
|
640
|
-
if ($[
|
|
641
|
-
t68 = /* @__PURE__ */ jsxRuntime.
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
]
|
|
645
|
-
|
|
646
|
-
$[
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
t71 = /* @__PURE__ */ jsxRuntime.jsx(ui.TextField, { error: t69, name: "description", value: t70, onChange: handleChange, multiline: true, minRows: 2, "aria-describedby": "description-helper-text", label: "Description" });
|
|
656
|
-
$[102] = handleChange;
|
|
650
|
+
if ($[97] !== t65 || $[98] !== t66) {
|
|
651
|
+
t68 = /* @__PURE__ */ jsxRuntime.jsx(ui.IconButton, { size: "small", onClick: t65, disabled: t66, children: t67 });
|
|
652
|
+
$[97] = t65;
|
|
653
|
+
$[98] = t66;
|
|
654
|
+
$[99] = t68;
|
|
655
|
+
} else {
|
|
656
|
+
t68 = $[99];
|
|
657
|
+
}
|
|
658
|
+
const t69 = values.sideDialogWidth ?? "";
|
|
659
|
+
let t70;
|
|
660
|
+
if ($[100] !== t63 || $[101] !== t64 || $[102] !== t68 || $[103] !== t69) {
|
|
661
|
+
t70 = /* @__PURE__ */ jsxRuntime.jsx(ui.TextField, { error: t63, name: "sideDialogWidth", type: "number", "aria-describedby": "sideDialogWidth-helper", onChange: t64, endAdornment: t68, value: t69, label: "Side dialog width" });
|
|
662
|
+
$[100] = t63;
|
|
663
|
+
$[101] = t64;
|
|
664
|
+
$[102] = t68;
|
|
657
665
|
$[103] = t69;
|
|
658
666
|
$[104] = t70;
|
|
659
|
-
$[105] = t71;
|
|
660
667
|
} else {
|
|
661
|
-
|
|
668
|
+
t70 = $[104];
|
|
662
669
|
}
|
|
663
|
-
const
|
|
664
|
-
const
|
|
665
|
-
let
|
|
666
|
-
if ($[
|
|
667
|
-
|
|
670
|
+
const t71 = showErrors && Boolean(errors.singularName);
|
|
671
|
+
const t72 = showErrors && Boolean(errors.singularName) ? errors.singularName : "Optionally define the width (in pixels) of entities side dialog. Default is 768px";
|
|
672
|
+
let t73;
|
|
673
|
+
if ($[105] !== t71 || $[106] !== t72) {
|
|
674
|
+
t73 = /* @__PURE__ */ jsxRuntime.jsx(core.FieldCaption, { error: t71, children: t72 });
|
|
675
|
+
$[105] = t71;
|
|
668
676
|
$[106] = t72;
|
|
669
677
|
$[107] = t73;
|
|
670
|
-
$[108] = t74;
|
|
671
678
|
} else {
|
|
672
|
-
|
|
679
|
+
t73 = $[107];
|
|
673
680
|
}
|
|
674
|
-
let
|
|
675
|
-
if ($[
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
681
|
+
let t74;
|
|
682
|
+
if ($[108] !== t70 || $[109] !== t73) {
|
|
683
|
+
t74 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "col-span-12", children: [
|
|
684
|
+
t70,
|
|
685
|
+
t73
|
|
679
686
|
] });
|
|
680
|
-
$[
|
|
687
|
+
$[108] = t70;
|
|
688
|
+
$[109] = t73;
|
|
681
689
|
$[110] = t74;
|
|
682
|
-
$[111] = t75;
|
|
683
690
|
} else {
|
|
684
|
-
|
|
691
|
+
t74 = $[110];
|
|
685
692
|
}
|
|
686
|
-
const
|
|
693
|
+
const t75 = showErrors && Boolean(errors.description);
|
|
694
|
+
const t76 = values.description ?? "";
|
|
687
695
|
let t77;
|
|
688
|
-
if ($[112]
|
|
689
|
-
t77 =
|
|
690
|
-
$[
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
let t78;
|
|
695
|
-
if ($[113] !== handleChange || $[114] !== t76) {
|
|
696
|
-
t78 = /* @__PURE__ */ jsxRuntime.jsx("div", { className: "col-span-12", children: /* @__PURE__ */ jsxRuntime.jsx(ui.Select, { name: "defaultSize", size: "large", fullWidth: true, label: "Default row size", position: "item-aligned", onChange: handleChange, value: t76, renderValue: _temp$b, children: t77 }) });
|
|
697
|
-
$[113] = handleChange;
|
|
698
|
-
$[114] = t76;
|
|
699
|
-
$[115] = t78;
|
|
696
|
+
if ($[111] !== handleChange || $[112] !== t75 || $[113] !== t76) {
|
|
697
|
+
t77 = /* @__PURE__ */ jsxRuntime.jsx(ui.TextField, { error: t75, name: "description", value: t76, onChange: handleChange, multiline: true, minRows: 2, "aria-describedby": "description-helper-text", label: "Description" });
|
|
698
|
+
$[111] = handleChange;
|
|
699
|
+
$[112] = t75;
|
|
700
|
+
$[113] = t76;
|
|
701
|
+
$[114] = t77;
|
|
700
702
|
} else {
|
|
701
|
-
|
|
703
|
+
t77 = $[114];
|
|
702
704
|
}
|
|
703
|
-
const
|
|
705
|
+
const t78 = showErrors && Boolean(errors.description);
|
|
706
|
+
const t79 = showErrors && Boolean(errors.description) ? errors.description : "Description of the collection, you can use markdown";
|
|
704
707
|
let t80;
|
|
705
|
-
if ($[116] !==
|
|
706
|
-
t80 = (
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
}
|
|
710
|
-
setFieldValue("customId", v);
|
|
711
|
-
};
|
|
712
|
-
$[116] = setFieldValue;
|
|
708
|
+
if ($[115] !== t78 || $[116] !== t79) {
|
|
709
|
+
t80 = /* @__PURE__ */ jsxRuntime.jsx(core.FieldCaption, { error: t78, children: t79 });
|
|
710
|
+
$[115] = t78;
|
|
711
|
+
$[116] = t79;
|
|
713
712
|
$[117] = t80;
|
|
714
713
|
} else {
|
|
715
714
|
t80 = $[117];
|
|
716
715
|
}
|
|
717
|
-
|
|
718
|
-
|
|
716
|
+
let t81;
|
|
717
|
+
if ($[118] !== t77 || $[119] !== t80) {
|
|
718
|
+
t81 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "col-span-12", children: [
|
|
719
|
+
t77,
|
|
720
|
+
t80
|
|
721
|
+
] });
|
|
722
|
+
$[118] = t77;
|
|
723
|
+
$[119] = t80;
|
|
724
|
+
$[120] = t81;
|
|
725
|
+
} else {
|
|
726
|
+
t81 = $[120];
|
|
727
|
+
}
|
|
728
|
+
const t82 = values.defaultSize ?? "";
|
|
719
729
|
let t83;
|
|
730
|
+
if ($[121] === Symbol.for("react.memo_cache_sentinel")) {
|
|
731
|
+
t83 = ["xs", "s", "m", "l", "xl"].map(_temp2$7);
|
|
732
|
+
$[121] = t83;
|
|
733
|
+
} else {
|
|
734
|
+
t83 = $[121];
|
|
735
|
+
}
|
|
720
736
|
let t84;
|
|
721
|
-
if ($[
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
$[
|
|
726
|
-
$[119] = t83;
|
|
727
|
-
$[120] = t84;
|
|
728
|
-
} else {
|
|
729
|
-
t82 = $[118];
|
|
730
|
-
t83 = $[119];
|
|
731
|
-
t84 = $[120];
|
|
732
|
-
}
|
|
733
|
-
let t85;
|
|
734
|
-
if ($[121] !== t79 || $[122] !== t80 || $[123] !== t81) {
|
|
735
|
-
t85 = /* @__PURE__ */ jsxRuntime.jsx("div", { className: "col-span-12", children: /* @__PURE__ */ jsxRuntime.jsxs(ui.Select, { name: "customId", label: "Document IDs generation", position: "item-aligned", size: "large", fullWidth: true, disabled: t79, onValueChange: t80, value: t81, renderValue: _temp3$4, children: [
|
|
736
|
-
t82,
|
|
737
|
-
t83,
|
|
738
|
-
t84
|
|
739
|
-
] }) });
|
|
740
|
-
$[121] = t79;
|
|
741
|
-
$[122] = t80;
|
|
742
|
-
$[123] = t81;
|
|
743
|
-
$[124] = t85;
|
|
737
|
+
if ($[122] !== handleChange || $[123] !== t82) {
|
|
738
|
+
t84 = /* @__PURE__ */ jsxRuntime.jsx("div", { className: "col-span-12", children: /* @__PURE__ */ jsxRuntime.jsx(ui.Select, { name: "defaultSize", size: "large", fullWidth: true, label: "Default row size", position: "item-aligned", onChange: handleChange, value: t82, renderValue: _temp$b, children: t83 }) });
|
|
739
|
+
$[122] = handleChange;
|
|
740
|
+
$[123] = t82;
|
|
741
|
+
$[124] = t84;
|
|
744
742
|
} else {
|
|
745
|
-
|
|
743
|
+
t84 = $[124];
|
|
746
744
|
}
|
|
745
|
+
const t85 = customIdValue === "code_defined";
|
|
747
746
|
let t86;
|
|
748
747
|
if ($[125] !== setFieldValue) {
|
|
749
|
-
t86 = (v_0) =>
|
|
748
|
+
t86 = (v_0) => {
|
|
749
|
+
if (v_0 === "code_defined") {
|
|
750
|
+
throw new Error("This should not happen");
|
|
751
|
+
}
|
|
752
|
+
setFieldValue("customId", v_0);
|
|
753
|
+
};
|
|
750
754
|
$[125] = setFieldValue;
|
|
751
755
|
$[126] = t86;
|
|
752
756
|
} else {
|
|
753
757
|
t86 = $[126];
|
|
754
758
|
}
|
|
755
|
-
const t87 =
|
|
759
|
+
const t87 = customIdValue ?? "";
|
|
756
760
|
let t88;
|
|
757
|
-
if ($[127] !== t86 || $[128] !== t87) {
|
|
758
|
-
t88 = /* @__PURE__ */ jsxRuntime.jsx(ui.BooleanSwitchWithLabel, { position: "start", size: "large", label: "Collection group", onValueChange: t86, value: t87 });
|
|
759
|
-
$[127] = t86;
|
|
760
|
-
$[128] = t87;
|
|
761
|
-
$[129] = t88;
|
|
762
|
-
} else {
|
|
763
|
-
t88 = $[129];
|
|
764
|
-
}
|
|
765
761
|
let t89;
|
|
766
|
-
if ($[130] === Symbol.for("react.memo_cache_sentinel")) {
|
|
767
|
-
t89 = /* @__PURE__ */ jsxRuntime.jsx(core.FieldCaption, { children: "A collection group consists of all collections with the same path. This allows you to query over multiple collections at once." });
|
|
768
|
-
$[130] = t89;
|
|
769
|
-
} else {
|
|
770
|
-
t89 = $[130];
|
|
771
|
-
}
|
|
772
762
|
let t90;
|
|
773
|
-
if ($[
|
|
774
|
-
|
|
763
|
+
if ($[127] === Symbol.for("react.memo_cache_sentinel")) {
|
|
764
|
+
t88 = /* @__PURE__ */ jsxRuntime.jsx(ui.SelectItem, { value: "false", children: "Document ID is generated automatically" });
|
|
765
|
+
t89 = /* @__PURE__ */ jsxRuntime.jsx(ui.SelectItem, { value: "true", children: "Users must define an ID" });
|
|
766
|
+
t90 = /* @__PURE__ */ jsxRuntime.jsx(ui.SelectItem, { value: "optional", children: "Users can define an ID, but it is not required" });
|
|
767
|
+
$[127] = t88;
|
|
768
|
+
$[128] = t89;
|
|
769
|
+
$[129] = t90;
|
|
770
|
+
} else {
|
|
771
|
+
t88 = $[127];
|
|
772
|
+
t89 = $[128];
|
|
773
|
+
t90 = $[129];
|
|
774
|
+
}
|
|
775
|
+
let t91;
|
|
776
|
+
if ($[130] !== t85 || $[131] !== t86 || $[132] !== t87) {
|
|
777
|
+
t91 = /* @__PURE__ */ jsxRuntime.jsx("div", { className: "col-span-12", children: /* @__PURE__ */ jsxRuntime.jsxs(ui.Select, { name: "customId", label: "Document IDs generation", position: "item-aligned", size: "large", fullWidth: true, disabled: t85, onValueChange: t86, value: t87, renderValue: _temp3$4, children: [
|
|
775
778
|
t88,
|
|
776
|
-
t89
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
$[
|
|
779
|
+
t89,
|
|
780
|
+
t90
|
|
781
|
+
] }) });
|
|
782
|
+
$[130] = t85;
|
|
783
|
+
$[131] = t86;
|
|
784
|
+
$[132] = t87;
|
|
785
|
+
$[133] = t91;
|
|
780
786
|
} else {
|
|
781
|
-
|
|
787
|
+
t91 = $[133];
|
|
782
788
|
}
|
|
783
|
-
let
|
|
784
|
-
if ($[
|
|
785
|
-
|
|
786
|
-
$[
|
|
787
|
-
$[
|
|
788
|
-
} else {
|
|
789
|
-
t91 = $[134];
|
|
790
|
-
}
|
|
791
|
-
const t92 = values.textSearchEnabled ?? false;
|
|
792
|
-
let t93;
|
|
793
|
-
if ($[135] !== t91 || $[136] !== t92) {
|
|
794
|
-
t93 = /* @__PURE__ */ jsxRuntime.jsx(ui.BooleanSwitchWithLabel, { position: "start", size: "large", label: "Enable text search for this collection", onValueChange: t91, value: t92 });
|
|
795
|
-
$[135] = t91;
|
|
796
|
-
$[136] = t92;
|
|
797
|
-
$[137] = t93;
|
|
789
|
+
let t92;
|
|
790
|
+
if ($[134] !== setFieldValue) {
|
|
791
|
+
t92 = (v_1) => setFieldValue("collectionGroup", v_1);
|
|
792
|
+
$[134] = setFieldValue;
|
|
793
|
+
$[135] = t92;
|
|
798
794
|
} else {
|
|
799
|
-
|
|
795
|
+
t92 = $[135];
|
|
800
796
|
}
|
|
797
|
+
const t93 = values.collectionGroup ?? false;
|
|
801
798
|
let t94;
|
|
802
|
-
if ($[
|
|
803
|
-
t94 = /* @__PURE__ */ jsxRuntime.jsx(
|
|
799
|
+
if ($[136] !== t92 || $[137] !== t93) {
|
|
800
|
+
t94 = /* @__PURE__ */ jsxRuntime.jsx(ui.BooleanSwitchWithLabel, { position: "start", size: "large", label: "Collection group", onValueChange: t92, value: t93 });
|
|
801
|
+
$[136] = t92;
|
|
802
|
+
$[137] = t93;
|
|
804
803
|
$[138] = t94;
|
|
805
804
|
} else {
|
|
806
805
|
t94 = $[138];
|
|
807
806
|
}
|
|
808
807
|
let t95;
|
|
809
|
-
if ($[139]
|
|
810
|
-
t95 = /* @__PURE__ */ jsxRuntime.
|
|
811
|
-
|
|
812
|
-
t94
|
|
813
|
-
] });
|
|
814
|
-
$[139] = t93;
|
|
815
|
-
$[140] = t95;
|
|
808
|
+
if ($[139] === Symbol.for("react.memo_cache_sentinel")) {
|
|
809
|
+
t95 = /* @__PURE__ */ jsxRuntime.jsx(core.FieldCaption, { children: "A collection group consists of all collections with the same path. This allows you to query over multiple collections at once." });
|
|
810
|
+
$[139] = t95;
|
|
816
811
|
} else {
|
|
817
|
-
t95 = $[
|
|
812
|
+
t95 = $[139];
|
|
818
813
|
}
|
|
819
814
|
let t96;
|
|
820
|
-
if ($[
|
|
821
|
-
t96 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
822
|
-
|
|
823
|
-
t56,
|
|
824
|
-
t68,
|
|
825
|
-
t75,
|
|
826
|
-
t78,
|
|
827
|
-
t85,
|
|
828
|
-
t90,
|
|
815
|
+
if ($[140] !== t94) {
|
|
816
|
+
t96 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "col-span-12 mt-4", children: [
|
|
817
|
+
t94,
|
|
829
818
|
t95
|
|
830
819
|
] });
|
|
831
|
-
$[
|
|
832
|
-
$[
|
|
833
|
-
|
|
834
|
-
$[
|
|
835
|
-
$[145] = t78;
|
|
836
|
-
$[146] = t85;
|
|
837
|
-
$[147] = t90;
|
|
838
|
-
$[148] = t95;
|
|
839
|
-
$[149] = t96;
|
|
840
|
-
} else {
|
|
841
|
-
t96 = $[149];
|
|
820
|
+
$[140] = t94;
|
|
821
|
+
$[141] = t96;
|
|
822
|
+
} else {
|
|
823
|
+
t96 = $[141];
|
|
842
824
|
}
|
|
843
825
|
let t97;
|
|
844
|
-
if ($[
|
|
845
|
-
t97 =
|
|
846
|
-
$[
|
|
847
|
-
$[
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
let
|
|
853
|
-
if ($[
|
|
854
|
-
|
|
855
|
-
|
|
826
|
+
if ($[142] !== setFieldValue) {
|
|
827
|
+
t97 = (v_2) => setFieldValue("textSearchEnabled", v_2);
|
|
828
|
+
$[142] = setFieldValue;
|
|
829
|
+
$[143] = t97;
|
|
830
|
+
} else {
|
|
831
|
+
t97 = $[143];
|
|
832
|
+
}
|
|
833
|
+
const t98 = values.textSearchEnabled ?? false;
|
|
834
|
+
let t99;
|
|
835
|
+
if ($[144] !== t97 || $[145] !== t98) {
|
|
836
|
+
t99 = /* @__PURE__ */ jsxRuntime.jsx(ui.BooleanSwitchWithLabel, { position: "start", size: "large", label: "Enable text search for this collection", onValueChange: t97, value: t98 });
|
|
837
|
+
$[144] = t97;
|
|
838
|
+
$[145] = t98;
|
|
839
|
+
$[146] = t99;
|
|
840
|
+
} else {
|
|
841
|
+
t99 = $[146];
|
|
842
|
+
}
|
|
843
|
+
let t100;
|
|
844
|
+
if ($[147] === Symbol.for("react.memo_cache_sentinel")) {
|
|
845
|
+
t100 = /* @__PURE__ */ jsxRuntime.jsx(core.FieldCaption, { children: "Allow text search for this collection. If you have not specified a text search delegate, this will use the built-in local text search. This is not recommended for large collections, as it may incur in performance and cost issues." });
|
|
846
|
+
$[147] = t100;
|
|
847
|
+
} else {
|
|
848
|
+
t100 = $[147];
|
|
849
|
+
}
|
|
850
|
+
let t101;
|
|
851
|
+
if ($[148] !== t99) {
|
|
852
|
+
t101 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "col-span-12", children: [
|
|
853
|
+
t99,
|
|
854
|
+
t100
|
|
855
|
+
] });
|
|
856
|
+
$[148] = t99;
|
|
857
|
+
$[149] = t101;
|
|
858
|
+
} else {
|
|
859
|
+
t101 = $[149];
|
|
860
|
+
}
|
|
861
|
+
let t102;
|
|
862
|
+
if ($[150] !== t101 || $[151] !== t54 || $[152] !== t62 || $[153] !== t74 || $[154] !== t81 || $[155] !== t84 || $[156] !== t91 || $[157] !== t96) {
|
|
863
|
+
t102 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-12 gap-4 p-4", children: [
|
|
864
|
+
t54,
|
|
865
|
+
t62,
|
|
866
|
+
t74,
|
|
867
|
+
t81,
|
|
868
|
+
t84,
|
|
869
|
+
t91,
|
|
870
|
+
t96,
|
|
871
|
+
t101
|
|
872
|
+
] });
|
|
873
|
+
$[150] = t101;
|
|
874
|
+
$[151] = t54;
|
|
875
|
+
$[152] = t62;
|
|
876
|
+
$[153] = t74;
|
|
877
|
+
$[154] = t81;
|
|
878
|
+
$[155] = t84;
|
|
879
|
+
$[156] = t91;
|
|
880
|
+
$[157] = t96;
|
|
881
|
+
$[158] = t102;
|
|
882
|
+
} else {
|
|
883
|
+
t102 = $[158];
|
|
884
|
+
}
|
|
885
|
+
let t103;
|
|
886
|
+
if ($[159] !== advancedPanelExpanded || $[160] !== t102) {
|
|
887
|
+
t103 = /* @__PURE__ */ jsxRuntime.jsx(ui.ExpandablePanel, { expanded: advancedPanelExpanded, onExpandedChange: setAdvancedPanelExpanded, title: t47, initiallyExpanded: false, children: t102 });
|
|
888
|
+
$[159] = advancedPanelExpanded;
|
|
889
|
+
$[160] = t102;
|
|
890
|
+
$[161] = t103;
|
|
891
|
+
} else {
|
|
892
|
+
t103 = $[161];
|
|
893
|
+
}
|
|
894
|
+
let t104;
|
|
895
|
+
if ($[162] !== children || $[163] !== t103) {
|
|
896
|
+
t104 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "col-span-12 mt-8", children: [
|
|
897
|
+
t103,
|
|
856
898
|
children
|
|
857
899
|
] });
|
|
858
|
-
$[
|
|
859
|
-
$[
|
|
860
|
-
$[
|
|
900
|
+
$[162] = children;
|
|
901
|
+
$[163] = t103;
|
|
902
|
+
$[164] = t104;
|
|
861
903
|
} else {
|
|
862
|
-
|
|
904
|
+
t104 = $[164];
|
|
863
905
|
}
|
|
864
|
-
let
|
|
865
|
-
if ($[
|
|
866
|
-
|
|
906
|
+
let t105;
|
|
907
|
+
if ($[165] !== t104 || $[166] !== t27 || $[167] !== t36 || $[168] !== t37 || $[169] !== t40 || $[170] !== t46) {
|
|
908
|
+
t105 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: t19, children: [
|
|
867
909
|
t27,
|
|
868
910
|
t36,
|
|
869
911
|
t37,
|
|
870
912
|
t40,
|
|
871
|
-
|
|
913
|
+
t46,
|
|
914
|
+
t104
|
|
872
915
|
] });
|
|
873
|
-
$[
|
|
874
|
-
$[
|
|
875
|
-
$[
|
|
876
|
-
$[
|
|
877
|
-
$[
|
|
878
|
-
$[
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
916
|
+
$[165] = t104;
|
|
917
|
+
$[166] = t27;
|
|
918
|
+
$[167] = t36;
|
|
919
|
+
$[168] = t37;
|
|
920
|
+
$[169] = t40;
|
|
921
|
+
$[170] = t46;
|
|
922
|
+
$[171] = t105;
|
|
923
|
+
} else {
|
|
924
|
+
t105 = $[171];
|
|
925
|
+
}
|
|
926
|
+
let t106;
|
|
927
|
+
if ($[172] === Symbol.for("react.memo_cache_sentinel")) {
|
|
928
|
+
t106 = /* @__PURE__ */ jsxRuntime.jsx("div", { style: {
|
|
885
929
|
height: "52px"
|
|
886
930
|
} });
|
|
887
|
-
$[
|
|
931
|
+
$[172] = t106;
|
|
888
932
|
} else {
|
|
889
|
-
|
|
933
|
+
t106 = $[172];
|
|
890
934
|
}
|
|
891
|
-
let
|
|
892
|
-
if ($[
|
|
893
|
-
|
|
935
|
+
let t107;
|
|
936
|
+
if ($[173] !== setFieldValue) {
|
|
937
|
+
t107 = (icon) => {
|
|
894
938
|
setIconDialogOpen(false);
|
|
895
939
|
setFieldValue("icon", icon);
|
|
896
940
|
};
|
|
897
|
-
$[
|
|
898
|
-
$[
|
|
941
|
+
$[173] = setFieldValue;
|
|
942
|
+
$[174] = t107;
|
|
899
943
|
} else {
|
|
900
|
-
|
|
944
|
+
t107 = $[174];
|
|
901
945
|
}
|
|
902
|
-
let
|
|
903
|
-
if ($[
|
|
904
|
-
|
|
905
|
-
$[
|
|
906
|
-
$[
|
|
907
|
-
$[
|
|
946
|
+
let t108;
|
|
947
|
+
if ($[175] !== t107 || $[176] !== values.icon) {
|
|
948
|
+
t108 = /* @__PURE__ */ jsxRuntime.jsx("div", { className: "p-4 overflow-auto min-h-[200px]", children: /* @__PURE__ */ jsxRuntime.jsx(core.SearchIconsView, { selectedIcon: values.icon, onIconSelected: t107 }) });
|
|
949
|
+
$[175] = t107;
|
|
950
|
+
$[176] = values.icon;
|
|
951
|
+
$[177] = t108;
|
|
908
952
|
} else {
|
|
909
|
-
|
|
953
|
+
t108 = $[177];
|
|
910
954
|
}
|
|
911
|
-
let
|
|
912
|
-
if ($[
|
|
913
|
-
|
|
914
|
-
$[
|
|
915
|
-
$[
|
|
916
|
-
$[
|
|
955
|
+
let t109;
|
|
956
|
+
if ($[178] !== iconDialogOpen || $[179] !== t108) {
|
|
957
|
+
t109 = /* @__PURE__ */ jsxRuntime.jsx(ui.Dialog, { open: iconDialogOpen, onOpenChange: setIconDialogOpen, maxWidth: "xl", fullWidth: true, children: t108 });
|
|
958
|
+
$[178] = iconDialogOpen;
|
|
959
|
+
$[179] = t108;
|
|
960
|
+
$[180] = t109;
|
|
917
961
|
} else {
|
|
918
|
-
|
|
962
|
+
t109 = $[180];
|
|
919
963
|
}
|
|
920
|
-
let
|
|
921
|
-
if ($[
|
|
922
|
-
|
|
964
|
+
let t110;
|
|
965
|
+
if ($[181] !== T0 || $[182] !== t105 || $[183] !== t109 || $[184] !== t18) {
|
|
966
|
+
t110 = /* @__PURE__ */ jsxRuntime.jsx("div", { className: t7, children: /* @__PURE__ */ jsxRuntime.jsxs(T0, { maxWidth: t8, className: t9, children: [
|
|
923
967
|
t18,
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
968
|
+
t105,
|
|
969
|
+
t106,
|
|
970
|
+
t109
|
|
927
971
|
] }) });
|
|
928
|
-
$[
|
|
929
|
-
$[
|
|
930
|
-
$[
|
|
931
|
-
$[
|
|
932
|
-
$[
|
|
972
|
+
$[181] = T0;
|
|
973
|
+
$[182] = t105;
|
|
974
|
+
$[183] = t109;
|
|
975
|
+
$[184] = t18;
|
|
976
|
+
$[185] = t110;
|
|
933
977
|
} else {
|
|
934
|
-
|
|
978
|
+
t110 = $[185];
|
|
935
979
|
}
|
|
936
|
-
return
|
|
980
|
+
return t110;
|
|
937
981
|
}
|
|
938
982
|
function _temp3$4(value_3) {
|
|
939
983
|
if (value_3 === "code_defined") {
|