@crediblemark/build 0.25.1 → 0.25.3
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/ArrayField-HI4LZRUN.mjs +19 -0
- package/dist/{ArrayField-HGGIE5AL.css → ArrayField-JRN7ZFM7.css} +15 -15
- package/dist/{Editor-E7FALXHL.css → Editor-CVT4RKSU.css} +7 -7
- package/dist/{Editor-CD7CMRO5.mjs → Editor-IPG4RO2L.mjs} +8 -8
- package/dist/ObjectField-CHMT4KPZ.mjs +19 -0
- package/dist/{ObjectField-NKMT3CLS.css → ObjectField-JYRSRCWB.css} +15 -15
- package/dist/{Render-JDXVKZXN.css → Render-DOE2LXKX.css} +1 -1
- package/dist/{Render-WP5OOTBB.mjs → Render-I6PZ5MEA.mjs} +4 -2
- package/dist/{chunk-DVK7K7D6.mjs → chunk-2RLA42JA.mjs} +4 -3
- package/dist/{chunk-JKWSSGAY.mjs → chunk-3Q7JODIK.mjs} +16 -15
- package/dist/{chunk-BPBYJDIJ.mjs → chunk-F2M5GHDX.mjs} +96 -81
- package/dist/{chunk-OUXISRNA.mjs → chunk-FQKSRGRK.mjs} +435 -336
- package/dist/{chunk-AL77I3BV.mjs → chunk-ISXFLTBM.mjs} +1 -1
- package/dist/{chunk-UPNU77XM.mjs → chunk-MZIV4ZKR.mjs} +2 -2
- package/dist/{chunk-WEPD3OBO.mjs → chunk-NYBTD3FJ.mjs} +2 -2
- package/dist/{chunk-PQXVFRLA.mjs → chunk-NYIULQV4.mjs} +31 -15
- package/dist/{chunk-BC5TH63U.mjs → chunk-PWRZZUWM.mjs} +1 -1
- package/dist/{chunk-NJZPPQVT.mjs → chunk-QMMMJ4RO.mjs} +7 -5
- package/dist/{chunk-3S3KWE2J.mjs → chunk-RBWVOMMW.mjs} +6 -4
- package/dist/{chunk-NSDGBGNG.mjs → chunk-UNMCNIJ3.mjs} +1 -1
- package/dist/{chunk-MLM27DOG.mjs → chunk-W57TTDB2.mjs} +1 -1
- package/dist/{full-HTQAR5N2.mjs → full-A2JX3OI2.mjs} +5 -5
- package/dist/{full-MY4DABK6.css → full-C7RVGAUA.css} +6 -6
- package/dist/index.css +155 -76
- package/dist/index.d.mts +4 -3
- package/dist/index.d.ts +4 -3
- package/dist/index.js +906 -759
- package/dist/index.mjs +13 -13
- package/dist/{loaded-Q7N3MNZB.mjs → loaded-2FUW3WCF.mjs} +2 -2
- package/dist/{loaded-E7C36OKZ.css → loaded-4FAPBCAU.css} +1 -1
- package/dist/{loaded-CDAPR2WZ.mjs → loaded-6L45JULO.mjs} +2 -2
- package/dist/{loaded-AHSNCA4P.mjs → loaded-Y7SRBM7R.mjs} +2 -2
- package/dist/no-external.css +155 -76
- package/dist/no-external.js +906 -759
- package/dist/no-external.mjs +13 -13
- package/dist/rsc.css +1 -1
- package/dist/rsc.js +10 -7
- package/dist/rsc.mjs +2 -2
- package/package.json +2 -1
- package/dist/ArrayField-N36WXYIG.mjs +0 -19
- package/dist/ObjectField-RMXFC6TI.mjs +0 -19
package/dist/no-external.js
CHANGED
|
@@ -74,16 +74,16 @@ var init_get_class_name_factory = __esm({
|
|
|
74
74
|
}
|
|
75
75
|
});
|
|
76
76
|
|
|
77
|
-
// css-module:/home/
|
|
77
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/ActionBar/styles.module.css/#css-module-data
|
|
78
78
|
var init_css_module_data = __esm({
|
|
79
|
-
"css-module:/home/
|
|
79
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/ActionBar/styles.module.css/#css-module-data"() {
|
|
80
80
|
}
|
|
81
81
|
});
|
|
82
82
|
|
|
83
|
-
// css-module:/home/
|
|
83
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/ActionBar/styles.module.css#css-module
|
|
84
84
|
var styles_module_default;
|
|
85
85
|
var init_styles_module = __esm({
|
|
86
|
-
"css-module:/home/
|
|
86
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/ActionBar/styles.module.css#css-module"() {
|
|
87
87
|
"use strict";
|
|
88
88
|
init_react_import();
|
|
89
89
|
init_css_module_data();
|
|
@@ -146,16 +146,16 @@ var init_ActionBar = __esm({
|
|
|
146
146
|
}
|
|
147
147
|
});
|
|
148
148
|
|
|
149
|
-
// css-module:/home/
|
|
149
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/AutoField/styles.module.css/#css-module-data
|
|
150
150
|
var init_css_module_data2 = __esm({
|
|
151
|
-
"css-module:/home/
|
|
151
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/AutoField/styles.module.css/#css-module-data"() {
|
|
152
152
|
}
|
|
153
153
|
});
|
|
154
154
|
|
|
155
|
-
// css-module:/home/
|
|
155
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/AutoField/styles.module.css#css-module
|
|
156
156
|
var styles_module_default2;
|
|
157
157
|
var init_styles_module2 = __esm({
|
|
158
|
-
"css-module:/home/
|
|
158
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/AutoField/styles.module.css#css-module"() {
|
|
159
159
|
"use strict";
|
|
160
160
|
init_react_import();
|
|
161
161
|
init_css_module_data2();
|
|
@@ -776,46 +776,67 @@ var init_image = __esm({
|
|
|
776
776
|
}
|
|
777
777
|
});
|
|
778
778
|
|
|
779
|
+
// node_modules/lucide-react/dist/esm/icons/inbox.js
|
|
780
|
+
var __iconNode25, Inbox;
|
|
781
|
+
var init_inbox = __esm({
|
|
782
|
+
"node_modules/lucide-react/dist/esm/icons/inbox.js"() {
|
|
783
|
+
"use strict";
|
|
784
|
+
init_react_import();
|
|
785
|
+
init_createLucideIcon();
|
|
786
|
+
__iconNode25 = [
|
|
787
|
+
["polyline", { points: "22 12 16 12 14 15 10 15 8 12 2 12", key: "o97t9d" }],
|
|
788
|
+
[
|
|
789
|
+
"path",
|
|
790
|
+
{
|
|
791
|
+
d: "M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",
|
|
792
|
+
key: "oot6mr"
|
|
793
|
+
}
|
|
794
|
+
]
|
|
795
|
+
];
|
|
796
|
+
Inbox = createLucideIcon("inbox", __iconNode25);
|
|
797
|
+
}
|
|
798
|
+
});
|
|
799
|
+
|
|
779
800
|
// node_modules/lucide-react/dist/esm/icons/info.js
|
|
780
|
-
var
|
|
801
|
+
var __iconNode26, Info;
|
|
781
802
|
var init_info = __esm({
|
|
782
803
|
"node_modules/lucide-react/dist/esm/icons/info.js"() {
|
|
783
804
|
"use strict";
|
|
784
805
|
init_react_import();
|
|
785
806
|
init_createLucideIcon();
|
|
786
|
-
|
|
807
|
+
__iconNode26 = [
|
|
787
808
|
["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
|
|
788
809
|
["path", { d: "M12 16v-4", key: "1dtifu" }],
|
|
789
810
|
["path", { d: "M12 8h.01", key: "e9boi3" }]
|
|
790
811
|
];
|
|
791
|
-
Info = createLucideIcon("info",
|
|
812
|
+
Info = createLucideIcon("info", __iconNode26);
|
|
792
813
|
}
|
|
793
814
|
});
|
|
794
815
|
|
|
795
816
|
// node_modules/lucide-react/dist/esm/icons/italic.js
|
|
796
|
-
var
|
|
817
|
+
var __iconNode27, Italic;
|
|
797
818
|
var init_italic = __esm({
|
|
798
819
|
"node_modules/lucide-react/dist/esm/icons/italic.js"() {
|
|
799
820
|
"use strict";
|
|
800
821
|
init_react_import();
|
|
801
822
|
init_createLucideIcon();
|
|
802
|
-
|
|
823
|
+
__iconNode27 = [
|
|
803
824
|
["line", { x1: "19", x2: "10", y1: "4", y2: "4", key: "15jd3p" }],
|
|
804
825
|
["line", { x1: "14", x2: "5", y1: "20", y2: "20", key: "bu0au3" }],
|
|
805
826
|
["line", { x1: "15", x2: "9", y1: "4", y2: "20", key: "uljnxc" }]
|
|
806
827
|
];
|
|
807
|
-
Italic = createLucideIcon("italic",
|
|
828
|
+
Italic = createLucideIcon("italic", __iconNode27);
|
|
808
829
|
}
|
|
809
830
|
});
|
|
810
831
|
|
|
811
832
|
// node_modules/lucide-react/dist/esm/icons/layers.js
|
|
812
|
-
var
|
|
833
|
+
var __iconNode28, Layers;
|
|
813
834
|
var init_layers = __esm({
|
|
814
835
|
"node_modules/lucide-react/dist/esm/icons/layers.js"() {
|
|
815
836
|
"use strict";
|
|
816
837
|
init_react_import();
|
|
817
838
|
init_createLucideIcon();
|
|
818
|
-
|
|
839
|
+
__iconNode28 = [
|
|
819
840
|
[
|
|
820
841
|
"path",
|
|
821
842
|
{
|
|
@@ -838,83 +859,83 @@ var init_layers = __esm({
|
|
|
838
859
|
}
|
|
839
860
|
]
|
|
840
861
|
];
|
|
841
|
-
Layers = createLucideIcon("layers",
|
|
862
|
+
Layers = createLucideIcon("layers", __iconNode28);
|
|
842
863
|
}
|
|
843
864
|
});
|
|
844
865
|
|
|
845
866
|
// node_modules/lucide-react/dist/esm/icons/layout-dashboard.js
|
|
846
|
-
var
|
|
867
|
+
var __iconNode29, LayoutDashboard;
|
|
847
868
|
var init_layout_dashboard = __esm({
|
|
848
869
|
"node_modules/lucide-react/dist/esm/icons/layout-dashboard.js"() {
|
|
849
870
|
"use strict";
|
|
850
871
|
init_react_import();
|
|
851
872
|
init_createLucideIcon();
|
|
852
|
-
|
|
873
|
+
__iconNode29 = [
|
|
853
874
|
["rect", { width: "7", height: "9", x: "3", y: "3", rx: "1", key: "10lvy0" }],
|
|
854
875
|
["rect", { width: "7", height: "5", x: "14", y: "3", rx: "1", key: "16une8" }],
|
|
855
876
|
["rect", { width: "7", height: "9", x: "14", y: "12", rx: "1", key: "1hutg5" }],
|
|
856
877
|
["rect", { width: "7", height: "5", x: "3", y: "16", rx: "1", key: "ldoo1y" }]
|
|
857
878
|
];
|
|
858
|
-
LayoutDashboard = createLucideIcon("layout-dashboard",
|
|
879
|
+
LayoutDashboard = createLucideIcon("layout-dashboard", __iconNode29);
|
|
859
880
|
}
|
|
860
881
|
});
|
|
861
882
|
|
|
862
883
|
// node_modules/lucide-react/dist/esm/icons/layout-grid.js
|
|
863
|
-
var
|
|
884
|
+
var __iconNode30, LayoutGrid;
|
|
864
885
|
var init_layout_grid = __esm({
|
|
865
886
|
"node_modules/lucide-react/dist/esm/icons/layout-grid.js"() {
|
|
866
887
|
"use strict";
|
|
867
888
|
init_react_import();
|
|
868
889
|
init_createLucideIcon();
|
|
869
|
-
|
|
890
|
+
__iconNode30 = [
|
|
870
891
|
["rect", { width: "7", height: "7", x: "3", y: "3", rx: "1", key: "1g98yp" }],
|
|
871
892
|
["rect", { width: "7", height: "7", x: "14", y: "3", rx: "1", key: "6d4xhi" }],
|
|
872
893
|
["rect", { width: "7", height: "7", x: "14", y: "14", rx: "1", key: "nxv5o0" }],
|
|
873
894
|
["rect", { width: "7", height: "7", x: "3", y: "14", rx: "1", key: "1bb6yr" }]
|
|
874
895
|
];
|
|
875
|
-
LayoutGrid = createLucideIcon("layout-grid",
|
|
896
|
+
LayoutGrid = createLucideIcon("layout-grid", __iconNode30);
|
|
876
897
|
}
|
|
877
898
|
});
|
|
878
899
|
|
|
879
900
|
// node_modules/lucide-react/dist/esm/icons/layout-template.js
|
|
880
|
-
var
|
|
901
|
+
var __iconNode31, LayoutTemplate;
|
|
881
902
|
var init_layout_template = __esm({
|
|
882
903
|
"node_modules/lucide-react/dist/esm/icons/layout-template.js"() {
|
|
883
904
|
"use strict";
|
|
884
905
|
init_react_import();
|
|
885
906
|
init_createLucideIcon();
|
|
886
|
-
|
|
907
|
+
__iconNode31 = [
|
|
887
908
|
["rect", { width: "18", height: "7", x: "3", y: "3", rx: "1", key: "f1a2em" }],
|
|
888
909
|
["rect", { width: "9", height: "7", x: "3", y: "14", rx: "1", key: "jqznyg" }],
|
|
889
910
|
["rect", { width: "5", height: "7", x: "16", y: "14", rx: "1", key: "q5h2i8" }]
|
|
890
911
|
];
|
|
891
|
-
LayoutTemplate = createLucideIcon("layout-template",
|
|
912
|
+
LayoutTemplate = createLucideIcon("layout-template", __iconNode31);
|
|
892
913
|
}
|
|
893
914
|
});
|
|
894
915
|
|
|
895
916
|
// node_modules/lucide-react/dist/esm/icons/link.js
|
|
896
|
-
var
|
|
917
|
+
var __iconNode32, Link;
|
|
897
918
|
var init_link = __esm({
|
|
898
919
|
"node_modules/lucide-react/dist/esm/icons/link.js"() {
|
|
899
920
|
"use strict";
|
|
900
921
|
init_react_import();
|
|
901
922
|
init_createLucideIcon();
|
|
902
|
-
|
|
923
|
+
__iconNode32 = [
|
|
903
924
|
["path", { d: "M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71", key: "1cjeqo" }],
|
|
904
925
|
["path", { d: "M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71", key: "19qd67" }]
|
|
905
926
|
];
|
|
906
|
-
Link = createLucideIcon("link",
|
|
927
|
+
Link = createLucideIcon("link", __iconNode32);
|
|
907
928
|
}
|
|
908
929
|
});
|
|
909
930
|
|
|
910
931
|
// node_modules/lucide-react/dist/esm/icons/list-ordered.js
|
|
911
|
-
var
|
|
932
|
+
var __iconNode33, ListOrdered;
|
|
912
933
|
var init_list_ordered = __esm({
|
|
913
934
|
"node_modules/lucide-react/dist/esm/icons/list-ordered.js"() {
|
|
914
935
|
"use strict";
|
|
915
936
|
init_react_import();
|
|
916
937
|
init_createLucideIcon();
|
|
917
|
-
|
|
938
|
+
__iconNode33 = [
|
|
918
939
|
["path", { d: "M11 5h10", key: "1cz7ny" }],
|
|
919
940
|
["path", { d: "M11 12h10", key: "1438ji" }],
|
|
920
941
|
["path", { d: "M11 19h10", key: "11t30w" }],
|
|
@@ -922,18 +943,18 @@ var init_list_ordered = __esm({
|
|
|
922
943
|
["path", { d: "M4 9h2", key: "r1h2o0" }],
|
|
923
944
|
["path", { d: "M6.5 20H3.4c0-1 2.6-1.925 2.6-3.5a1.5 1.5 0 0 0-2.6-1.02", key: "xtkcd5" }]
|
|
924
945
|
];
|
|
925
|
-
ListOrdered = createLucideIcon("list-ordered",
|
|
946
|
+
ListOrdered = createLucideIcon("list-ordered", __iconNode33);
|
|
926
947
|
}
|
|
927
948
|
});
|
|
928
949
|
|
|
929
950
|
// node_modules/lucide-react/dist/esm/icons/list.js
|
|
930
|
-
var
|
|
951
|
+
var __iconNode34, List;
|
|
931
952
|
var init_list = __esm({
|
|
932
953
|
"node_modules/lucide-react/dist/esm/icons/list.js"() {
|
|
933
954
|
"use strict";
|
|
934
955
|
init_react_import();
|
|
935
956
|
init_createLucideIcon();
|
|
936
|
-
|
|
957
|
+
__iconNode34 = [
|
|
937
958
|
["path", { d: "M3 5h.01", key: "18ugdj" }],
|
|
938
959
|
["path", { d: "M3 12h.01", key: "nlz23k" }],
|
|
939
960
|
["path", { d: "M3 19h.01", key: "noohij" }],
|
|
@@ -941,65 +962,65 @@ var init_list = __esm({
|
|
|
941
962
|
["path", { d: "M8 12h13", key: "1za7za" }],
|
|
942
963
|
["path", { d: "M8 19h13", key: "m83p4d" }]
|
|
943
964
|
];
|
|
944
|
-
List = createLucideIcon("list",
|
|
965
|
+
List = createLucideIcon("list", __iconNode34);
|
|
945
966
|
}
|
|
946
967
|
});
|
|
947
968
|
|
|
948
969
|
// node_modules/lucide-react/dist/esm/icons/lock-open.js
|
|
949
|
-
var
|
|
970
|
+
var __iconNode35, LockOpen;
|
|
950
971
|
var init_lock_open = __esm({
|
|
951
972
|
"node_modules/lucide-react/dist/esm/icons/lock-open.js"() {
|
|
952
973
|
"use strict";
|
|
953
974
|
init_react_import();
|
|
954
975
|
init_createLucideIcon();
|
|
955
|
-
|
|
976
|
+
__iconNode35 = [
|
|
956
977
|
["rect", { width: "18", height: "11", x: "3", y: "11", rx: "2", ry: "2", key: "1w4ew1" }],
|
|
957
978
|
["path", { d: "M7 11V7a5 5 0 0 1 9.9-1", key: "1mm8w8" }]
|
|
958
979
|
];
|
|
959
|
-
LockOpen = createLucideIcon("lock-open",
|
|
980
|
+
LockOpen = createLucideIcon("lock-open", __iconNode35);
|
|
960
981
|
}
|
|
961
982
|
});
|
|
962
983
|
|
|
963
984
|
// node_modules/lucide-react/dist/esm/icons/lock.js
|
|
964
|
-
var
|
|
985
|
+
var __iconNode36, Lock;
|
|
965
986
|
var init_lock = __esm({
|
|
966
987
|
"node_modules/lucide-react/dist/esm/icons/lock.js"() {
|
|
967
988
|
"use strict";
|
|
968
989
|
init_react_import();
|
|
969
990
|
init_createLucideIcon();
|
|
970
|
-
|
|
991
|
+
__iconNode36 = [
|
|
971
992
|
["rect", { width: "18", height: "11", x: "3", y: "11", rx: "2", ry: "2", key: "1w4ew1" }],
|
|
972
993
|
["path", { d: "M7 11V7a5 5 0 0 1 10 0v4", key: "fwvmzm" }]
|
|
973
994
|
];
|
|
974
|
-
Lock = createLucideIcon("lock",
|
|
995
|
+
Lock = createLucideIcon("lock", __iconNode36);
|
|
975
996
|
}
|
|
976
997
|
});
|
|
977
998
|
|
|
978
999
|
// node_modules/lucide-react/dist/esm/icons/maximize-2.js
|
|
979
|
-
var
|
|
1000
|
+
var __iconNode37, Maximize2;
|
|
980
1001
|
var init_maximize_2 = __esm({
|
|
981
1002
|
"node_modules/lucide-react/dist/esm/icons/maximize-2.js"() {
|
|
982
1003
|
"use strict";
|
|
983
1004
|
init_react_import();
|
|
984
1005
|
init_createLucideIcon();
|
|
985
|
-
|
|
1006
|
+
__iconNode37 = [
|
|
986
1007
|
["path", { d: "M15 3h6v6", key: "1q9fwt" }],
|
|
987
1008
|
["path", { d: "m21 3-7 7", key: "1l2asr" }],
|
|
988
1009
|
["path", { d: "m3 21 7-7", key: "tjx5ai" }],
|
|
989
1010
|
["path", { d: "M9 21H3v-6", key: "wtvkvv" }]
|
|
990
1011
|
];
|
|
991
|
-
Maximize2 = createLucideIcon("maximize-2",
|
|
1012
|
+
Maximize2 = createLucideIcon("maximize-2", __iconNode37);
|
|
992
1013
|
}
|
|
993
1014
|
});
|
|
994
1015
|
|
|
995
1016
|
// node_modules/lucide-react/dist/esm/icons/megaphone.js
|
|
996
|
-
var
|
|
1017
|
+
var __iconNode38, Megaphone;
|
|
997
1018
|
var init_megaphone = __esm({
|
|
998
1019
|
"node_modules/lucide-react/dist/esm/icons/megaphone.js"() {
|
|
999
1020
|
"use strict";
|
|
1000
1021
|
init_react_import();
|
|
1001
1022
|
init_createLucideIcon();
|
|
1002
|
-
|
|
1023
|
+
__iconNode38 = [
|
|
1003
1024
|
[
|
|
1004
1025
|
"path",
|
|
1005
1026
|
{
|
|
@@ -1010,63 +1031,63 @@ var init_megaphone = __esm({
|
|
|
1010
1031
|
["path", { d: "M6 14a12 12 0 0 0 2.4 7.2 2 2 0 0 0 3.2-2.4A8 8 0 0 1 10 14", key: "1853fq" }],
|
|
1011
1032
|
["path", { d: "M8 6v8", key: "15ugcq" }]
|
|
1012
1033
|
];
|
|
1013
|
-
Megaphone = createLucideIcon("megaphone",
|
|
1034
|
+
Megaphone = createLucideIcon("megaphone", __iconNode38);
|
|
1014
1035
|
}
|
|
1015
1036
|
});
|
|
1016
1037
|
|
|
1017
1038
|
// node_modules/lucide-react/dist/esm/icons/minimize-2.js
|
|
1018
|
-
var
|
|
1039
|
+
var __iconNode39, Minimize2;
|
|
1019
1040
|
var init_minimize_2 = __esm({
|
|
1020
1041
|
"node_modules/lucide-react/dist/esm/icons/minimize-2.js"() {
|
|
1021
1042
|
"use strict";
|
|
1022
1043
|
init_react_import();
|
|
1023
1044
|
init_createLucideIcon();
|
|
1024
|
-
|
|
1045
|
+
__iconNode39 = [
|
|
1025
1046
|
["path", { d: "m14 10 7-7", key: "oa77jy" }],
|
|
1026
1047
|
["path", { d: "M20 10h-6V4", key: "mjg0md" }],
|
|
1027
1048
|
["path", { d: "m3 21 7-7", key: "tjx5ai" }],
|
|
1028
1049
|
["path", { d: "M4 14h6v6", key: "rmj7iw" }]
|
|
1029
1050
|
];
|
|
1030
|
-
Minimize2 = createLucideIcon("minimize-2",
|
|
1051
|
+
Minimize2 = createLucideIcon("minimize-2", __iconNode39);
|
|
1031
1052
|
}
|
|
1032
1053
|
});
|
|
1033
1054
|
|
|
1034
1055
|
// node_modules/lucide-react/dist/esm/icons/minus.js
|
|
1035
|
-
var
|
|
1056
|
+
var __iconNode40, Minus;
|
|
1036
1057
|
var init_minus = __esm({
|
|
1037
1058
|
"node_modules/lucide-react/dist/esm/icons/minus.js"() {
|
|
1038
1059
|
"use strict";
|
|
1039
1060
|
init_react_import();
|
|
1040
1061
|
init_createLucideIcon();
|
|
1041
|
-
|
|
1042
|
-
Minus = createLucideIcon("minus",
|
|
1062
|
+
__iconNode40 = [["path", { d: "M5 12h14", key: "1ays0h" }]];
|
|
1063
|
+
Minus = createLucideIcon("minus", __iconNode40);
|
|
1043
1064
|
}
|
|
1044
1065
|
});
|
|
1045
1066
|
|
|
1046
1067
|
// node_modules/lucide-react/dist/esm/icons/monitor.js
|
|
1047
|
-
var
|
|
1068
|
+
var __iconNode41, Monitor;
|
|
1048
1069
|
var init_monitor = __esm({
|
|
1049
1070
|
"node_modules/lucide-react/dist/esm/icons/monitor.js"() {
|
|
1050
1071
|
"use strict";
|
|
1051
1072
|
init_react_import();
|
|
1052
1073
|
init_createLucideIcon();
|
|
1053
|
-
|
|
1074
|
+
__iconNode41 = [
|
|
1054
1075
|
["rect", { width: "20", height: "14", x: "2", y: "3", rx: "2", key: "48i651" }],
|
|
1055
1076
|
["line", { x1: "8", x2: "16", y1: "21", y2: "21", key: "1svkeh" }],
|
|
1056
1077
|
["line", { x1: "12", x2: "12", y1: "17", y2: "21", key: "vw1qmm" }]
|
|
1057
1078
|
];
|
|
1058
|
-
Monitor = createLucideIcon("monitor",
|
|
1079
|
+
Monitor = createLucideIcon("monitor", __iconNode41);
|
|
1059
1080
|
}
|
|
1060
1081
|
});
|
|
1061
1082
|
|
|
1062
1083
|
// node_modules/lucide-react/dist/esm/icons/moon.js
|
|
1063
|
-
var
|
|
1084
|
+
var __iconNode42, Moon;
|
|
1064
1085
|
var init_moon = __esm({
|
|
1065
1086
|
"node_modules/lucide-react/dist/esm/icons/moon.js"() {
|
|
1066
1087
|
"use strict";
|
|
1067
1088
|
init_react_import();
|
|
1068
1089
|
init_createLucideIcon();
|
|
1069
|
-
|
|
1090
|
+
__iconNode42 = [
|
|
1070
1091
|
[
|
|
1071
1092
|
"path",
|
|
1072
1093
|
{
|
|
@@ -1075,63 +1096,63 @@ var init_moon = __esm({
|
|
|
1075
1096
|
}
|
|
1076
1097
|
]
|
|
1077
1098
|
];
|
|
1078
|
-
Moon = createLucideIcon("moon",
|
|
1099
|
+
Moon = createLucideIcon("moon", __iconNode42);
|
|
1079
1100
|
}
|
|
1080
1101
|
});
|
|
1081
1102
|
|
|
1082
1103
|
// node_modules/lucide-react/dist/esm/icons/panel-left.js
|
|
1083
|
-
var
|
|
1104
|
+
var __iconNode43, PanelLeft;
|
|
1084
1105
|
var init_panel_left = __esm({
|
|
1085
1106
|
"node_modules/lucide-react/dist/esm/icons/panel-left.js"() {
|
|
1086
1107
|
"use strict";
|
|
1087
1108
|
init_react_import();
|
|
1088
1109
|
init_createLucideIcon();
|
|
1089
|
-
|
|
1110
|
+
__iconNode43 = [
|
|
1090
1111
|
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
|
|
1091
1112
|
["path", { d: "M9 3v18", key: "fh3hqa" }]
|
|
1092
1113
|
];
|
|
1093
|
-
PanelLeft = createLucideIcon("panel-left",
|
|
1114
|
+
PanelLeft = createLucideIcon("panel-left", __iconNode43);
|
|
1094
1115
|
}
|
|
1095
1116
|
});
|
|
1096
1117
|
|
|
1097
1118
|
// node_modules/lucide-react/dist/esm/icons/panel-right.js
|
|
1098
|
-
var
|
|
1119
|
+
var __iconNode44, PanelRight;
|
|
1099
1120
|
var init_panel_right = __esm({
|
|
1100
1121
|
"node_modules/lucide-react/dist/esm/icons/panel-right.js"() {
|
|
1101
1122
|
"use strict";
|
|
1102
1123
|
init_react_import();
|
|
1103
1124
|
init_createLucideIcon();
|
|
1104
|
-
|
|
1125
|
+
__iconNode44 = [
|
|
1105
1126
|
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
|
|
1106
1127
|
["path", { d: "M15 3v18", key: "14nvp0" }]
|
|
1107
1128
|
];
|
|
1108
|
-
PanelRight = createLucideIcon("panel-right",
|
|
1129
|
+
PanelRight = createLucideIcon("panel-right", __iconNode44);
|
|
1109
1130
|
}
|
|
1110
1131
|
});
|
|
1111
1132
|
|
|
1112
1133
|
// node_modules/lucide-react/dist/esm/icons/plus.js
|
|
1113
|
-
var
|
|
1134
|
+
var __iconNode45, Plus;
|
|
1114
1135
|
var init_plus = __esm({
|
|
1115
1136
|
"node_modules/lucide-react/dist/esm/icons/plus.js"() {
|
|
1116
1137
|
"use strict";
|
|
1117
1138
|
init_react_import();
|
|
1118
1139
|
init_createLucideIcon();
|
|
1119
|
-
|
|
1140
|
+
__iconNode45 = [
|
|
1120
1141
|
["path", { d: "M5 12h14", key: "1ays0h" }],
|
|
1121
1142
|
["path", { d: "M12 5v14", key: "s699le" }]
|
|
1122
1143
|
];
|
|
1123
|
-
Plus = createLucideIcon("plus",
|
|
1144
|
+
Plus = createLucideIcon("plus", __iconNode45);
|
|
1124
1145
|
}
|
|
1125
1146
|
});
|
|
1126
1147
|
|
|
1127
1148
|
// node_modules/lucide-react/dist/esm/icons/quote.js
|
|
1128
|
-
var
|
|
1149
|
+
var __iconNode46, Quote;
|
|
1129
1150
|
var init_quote = __esm({
|
|
1130
1151
|
"node_modules/lucide-react/dist/esm/icons/quote.js"() {
|
|
1131
1152
|
"use strict";
|
|
1132
1153
|
init_react_import();
|
|
1133
1154
|
init_createLucideIcon();
|
|
1134
|
-
|
|
1155
|
+
__iconNode46 = [
|
|
1135
1156
|
[
|
|
1136
1157
|
"path",
|
|
1137
1158
|
{
|
|
@@ -1147,65 +1168,65 @@ var init_quote = __esm({
|
|
|
1147
1168
|
}
|
|
1148
1169
|
]
|
|
1149
1170
|
];
|
|
1150
|
-
Quote = createLucideIcon("quote",
|
|
1171
|
+
Quote = createLucideIcon("quote", __iconNode46);
|
|
1151
1172
|
}
|
|
1152
1173
|
});
|
|
1153
1174
|
|
|
1154
1175
|
// node_modules/lucide-react/dist/esm/icons/rectangle-ellipsis.js
|
|
1155
|
-
var
|
|
1176
|
+
var __iconNode47, RectangleEllipsis;
|
|
1156
1177
|
var init_rectangle_ellipsis = __esm({
|
|
1157
1178
|
"node_modules/lucide-react/dist/esm/icons/rectangle-ellipsis.js"() {
|
|
1158
1179
|
"use strict";
|
|
1159
1180
|
init_react_import();
|
|
1160
1181
|
init_createLucideIcon();
|
|
1161
|
-
|
|
1182
|
+
__iconNode47 = [
|
|
1162
1183
|
["rect", { width: "20", height: "12", x: "2", y: "6", rx: "2", key: "9lu3g6" }],
|
|
1163
1184
|
["path", { d: "M12 12h.01", key: "1mp3jc" }],
|
|
1164
1185
|
["path", { d: "M17 12h.01", key: "1m0b6t" }],
|
|
1165
1186
|
["path", { d: "M7 12h.01", key: "eqddd0" }]
|
|
1166
1187
|
];
|
|
1167
|
-
RectangleEllipsis = createLucideIcon("rectangle-ellipsis",
|
|
1188
|
+
RectangleEllipsis = createLucideIcon("rectangle-ellipsis", __iconNode47);
|
|
1168
1189
|
}
|
|
1169
1190
|
});
|
|
1170
1191
|
|
|
1171
1192
|
// node_modules/lucide-react/dist/esm/icons/redo-2.js
|
|
1172
|
-
var
|
|
1193
|
+
var __iconNode48, Redo2;
|
|
1173
1194
|
var init_redo_2 = __esm({
|
|
1174
1195
|
"node_modules/lucide-react/dist/esm/icons/redo-2.js"() {
|
|
1175
1196
|
"use strict";
|
|
1176
1197
|
init_react_import();
|
|
1177
1198
|
init_createLucideIcon();
|
|
1178
|
-
|
|
1199
|
+
__iconNode48 = [
|
|
1179
1200
|
["path", { d: "m15 14 5-5-5-5", key: "12vg1m" }],
|
|
1180
1201
|
["path", { d: "M20 9H9.5A5.5 5.5 0 0 0 4 14.5A5.5 5.5 0 0 0 9.5 20H13", key: "6uklza" }]
|
|
1181
1202
|
];
|
|
1182
|
-
Redo2 = createLucideIcon("redo-2",
|
|
1203
|
+
Redo2 = createLucideIcon("redo-2", __iconNode48);
|
|
1183
1204
|
}
|
|
1184
1205
|
});
|
|
1185
1206
|
|
|
1186
1207
|
// node_modules/lucide-react/dist/esm/icons/search.js
|
|
1187
|
-
var
|
|
1208
|
+
var __iconNode49, Search;
|
|
1188
1209
|
var init_search = __esm({
|
|
1189
1210
|
"node_modules/lucide-react/dist/esm/icons/search.js"() {
|
|
1190
1211
|
"use strict";
|
|
1191
1212
|
init_react_import();
|
|
1192
1213
|
init_createLucideIcon();
|
|
1193
|
-
|
|
1214
|
+
__iconNode49 = [
|
|
1194
1215
|
["path", { d: "m21 21-4.34-4.34", key: "14j7rj" }],
|
|
1195
1216
|
["circle", { cx: "11", cy: "11", r: "8", key: "4ej97u" }]
|
|
1196
1217
|
];
|
|
1197
|
-
Search = createLucideIcon("search",
|
|
1218
|
+
Search = createLucideIcon("search", __iconNode49);
|
|
1198
1219
|
}
|
|
1199
1220
|
});
|
|
1200
1221
|
|
|
1201
1222
|
// node_modules/lucide-react/dist/esm/icons/settings.js
|
|
1202
|
-
var
|
|
1223
|
+
var __iconNode50, Settings;
|
|
1203
1224
|
var init_settings = __esm({
|
|
1204
1225
|
"node_modules/lucide-react/dist/esm/icons/settings.js"() {
|
|
1205
1226
|
"use strict";
|
|
1206
1227
|
init_react_import();
|
|
1207
1228
|
init_createLucideIcon();
|
|
1208
|
-
|
|
1229
|
+
__iconNode50 = [
|
|
1209
1230
|
[
|
|
1210
1231
|
"path",
|
|
1211
1232
|
{
|
|
@@ -1215,18 +1236,18 @@ var init_settings = __esm({
|
|
|
1215
1236
|
],
|
|
1216
1237
|
["circle", { cx: "12", cy: "12", r: "3", key: "1v7zrd" }]
|
|
1217
1238
|
];
|
|
1218
|
-
Settings = createLucideIcon("settings",
|
|
1239
|
+
Settings = createLucideIcon("settings", __iconNode50);
|
|
1219
1240
|
}
|
|
1220
1241
|
});
|
|
1221
1242
|
|
|
1222
1243
|
// node_modules/lucide-react/dist/esm/icons/shapes.js
|
|
1223
|
-
var
|
|
1244
|
+
var __iconNode51, Shapes;
|
|
1224
1245
|
var init_shapes = __esm({
|
|
1225
1246
|
"node_modules/lucide-react/dist/esm/icons/shapes.js"() {
|
|
1226
1247
|
"use strict";
|
|
1227
1248
|
init_react_import();
|
|
1228
1249
|
init_createLucideIcon();
|
|
1229
|
-
|
|
1250
|
+
__iconNode51 = [
|
|
1230
1251
|
[
|
|
1231
1252
|
"path",
|
|
1232
1253
|
{
|
|
@@ -1237,18 +1258,18 @@ var init_shapes = __esm({
|
|
|
1237
1258
|
["rect", { x: "3", y: "14", width: "7", height: "7", rx: "1", key: "1bkyp8" }],
|
|
1238
1259
|
["circle", { cx: "17.5", cy: "17.5", r: "3.5", key: "w3z12y" }]
|
|
1239
1260
|
];
|
|
1240
|
-
Shapes = createLucideIcon("shapes",
|
|
1261
|
+
Shapes = createLucideIcon("shapes", __iconNode51);
|
|
1241
1262
|
}
|
|
1242
1263
|
});
|
|
1243
1264
|
|
|
1244
1265
|
// node_modules/lucide-react/dist/esm/icons/sliders-horizontal.js
|
|
1245
|
-
var
|
|
1266
|
+
var __iconNode52, SlidersHorizontal;
|
|
1246
1267
|
var init_sliders_horizontal = __esm({
|
|
1247
1268
|
"node_modules/lucide-react/dist/esm/icons/sliders-horizontal.js"() {
|
|
1248
1269
|
"use strict";
|
|
1249
1270
|
init_react_import();
|
|
1250
1271
|
init_createLucideIcon();
|
|
1251
|
-
|
|
1272
|
+
__iconNode52 = [
|
|
1252
1273
|
["path", { d: "M10 5H3", key: "1qgfaw" }],
|
|
1253
1274
|
["path", { d: "M12 19H3", key: "yhmn1j" }],
|
|
1254
1275
|
["path", { d: "M14 3v4", key: "1sua03" }],
|
|
@@ -1259,65 +1280,65 @@ var init_sliders_horizontal = __esm({
|
|
|
1259
1280
|
["path", { d: "M8 10v4", key: "tgpxqk" }],
|
|
1260
1281
|
["path", { d: "M8 12H3", key: "a7s4jb" }]
|
|
1261
1282
|
];
|
|
1262
|
-
SlidersHorizontal = createLucideIcon("sliders-horizontal",
|
|
1283
|
+
SlidersHorizontal = createLucideIcon("sliders-horizontal", __iconNode52);
|
|
1263
1284
|
}
|
|
1264
1285
|
});
|
|
1265
1286
|
|
|
1266
1287
|
// node_modules/lucide-react/dist/esm/icons/smartphone.js
|
|
1267
|
-
var
|
|
1288
|
+
var __iconNode53, Smartphone;
|
|
1268
1289
|
var init_smartphone = __esm({
|
|
1269
1290
|
"node_modules/lucide-react/dist/esm/icons/smartphone.js"() {
|
|
1270
1291
|
"use strict";
|
|
1271
1292
|
init_react_import();
|
|
1272
1293
|
init_createLucideIcon();
|
|
1273
|
-
|
|
1294
|
+
__iconNode53 = [
|
|
1274
1295
|
["rect", { width: "14", height: "20", x: "5", y: "2", rx: "2", ry: "2", key: "1yt0o3" }],
|
|
1275
1296
|
["path", { d: "M12 18h.01", key: "mhygvu" }]
|
|
1276
1297
|
];
|
|
1277
|
-
Smartphone = createLucideIcon("smartphone",
|
|
1298
|
+
Smartphone = createLucideIcon("smartphone", __iconNode53);
|
|
1278
1299
|
}
|
|
1279
1300
|
});
|
|
1280
1301
|
|
|
1281
1302
|
// node_modules/lucide-react/dist/esm/icons/square-code.js
|
|
1282
|
-
var
|
|
1303
|
+
var __iconNode54, SquareCode;
|
|
1283
1304
|
var init_square_code = __esm({
|
|
1284
1305
|
"node_modules/lucide-react/dist/esm/icons/square-code.js"() {
|
|
1285
1306
|
"use strict";
|
|
1286
1307
|
init_react_import();
|
|
1287
1308
|
init_createLucideIcon();
|
|
1288
|
-
|
|
1309
|
+
__iconNode54 = [
|
|
1289
1310
|
["path", { d: "m10 9-3 3 3 3", key: "1oro0q" }],
|
|
1290
1311
|
["path", { d: "m14 15 3-3-3-3", key: "bz13h7" }],
|
|
1291
1312
|
["rect", { x: "3", y: "3", width: "18", height: "18", rx: "2", key: "h1oib" }]
|
|
1292
1313
|
];
|
|
1293
|
-
SquareCode = createLucideIcon("square-code",
|
|
1314
|
+
SquareCode = createLucideIcon("square-code", __iconNode54);
|
|
1294
1315
|
}
|
|
1295
1316
|
});
|
|
1296
1317
|
|
|
1297
1318
|
// node_modules/lucide-react/dist/esm/icons/strikethrough.js
|
|
1298
|
-
var
|
|
1319
|
+
var __iconNode55, Strikethrough;
|
|
1299
1320
|
var init_strikethrough = __esm({
|
|
1300
1321
|
"node_modules/lucide-react/dist/esm/icons/strikethrough.js"() {
|
|
1301
1322
|
"use strict";
|
|
1302
1323
|
init_react_import();
|
|
1303
1324
|
init_createLucideIcon();
|
|
1304
|
-
|
|
1325
|
+
__iconNode55 = [
|
|
1305
1326
|
["path", { d: "M16 4H9a3 3 0 0 0-2.83 4", key: "43sutm" }],
|
|
1306
1327
|
["path", { d: "M14 12a4 4 0 0 1 0 8H6", key: "nlfj13" }],
|
|
1307
1328
|
["line", { x1: "4", x2: "20", y1: "12", y2: "12", key: "1e0a9i" }]
|
|
1308
1329
|
];
|
|
1309
|
-
Strikethrough = createLucideIcon("strikethrough",
|
|
1330
|
+
Strikethrough = createLucideIcon("strikethrough", __iconNode55);
|
|
1310
1331
|
}
|
|
1311
1332
|
});
|
|
1312
1333
|
|
|
1313
1334
|
// node_modules/lucide-react/dist/esm/icons/sun.js
|
|
1314
|
-
var
|
|
1335
|
+
var __iconNode56, Sun;
|
|
1315
1336
|
var init_sun = __esm({
|
|
1316
1337
|
"node_modules/lucide-react/dist/esm/icons/sun.js"() {
|
|
1317
1338
|
"use strict";
|
|
1318
1339
|
init_react_import();
|
|
1319
1340
|
init_createLucideIcon();
|
|
1320
|
-
|
|
1341
|
+
__iconNode56 = [
|
|
1321
1342
|
["circle", { cx: "12", cy: "12", r: "4", key: "4exip2" }],
|
|
1322
1343
|
["path", { d: "M12 2v2", key: "tus03m" }],
|
|
1323
1344
|
["path", { d: "M12 20v2", key: "1lh1kg" }],
|
|
@@ -1328,190 +1349,190 @@ var init_sun = __esm({
|
|
|
1328
1349
|
["path", { d: "m6.34 17.66-1.41 1.41", key: "1m8zz5" }],
|
|
1329
1350
|
["path", { d: "m19.07 4.93-1.41 1.41", key: "1shlcs" }]
|
|
1330
1351
|
];
|
|
1331
|
-
Sun = createLucideIcon("sun",
|
|
1352
|
+
Sun = createLucideIcon("sun", __iconNode56);
|
|
1332
1353
|
}
|
|
1333
1354
|
});
|
|
1334
1355
|
|
|
1335
1356
|
// node_modules/lucide-react/dist/esm/icons/tablet.js
|
|
1336
|
-
var
|
|
1357
|
+
var __iconNode57, Tablet;
|
|
1337
1358
|
var init_tablet = __esm({
|
|
1338
1359
|
"node_modules/lucide-react/dist/esm/icons/tablet.js"() {
|
|
1339
1360
|
"use strict";
|
|
1340
1361
|
init_react_import();
|
|
1341
1362
|
init_createLucideIcon();
|
|
1342
|
-
|
|
1363
|
+
__iconNode57 = [
|
|
1343
1364
|
["rect", { width: "16", height: "20", x: "4", y: "2", rx: "2", ry: "2", key: "76otgf" }],
|
|
1344
1365
|
["line", { x1: "12", x2: "12.01", y1: "18", y2: "18", key: "1dp563" }]
|
|
1345
1366
|
];
|
|
1346
|
-
Tablet = createLucideIcon("tablet",
|
|
1367
|
+
Tablet = createLucideIcon("tablet", __iconNode57);
|
|
1347
1368
|
}
|
|
1348
1369
|
});
|
|
1349
1370
|
|
|
1350
1371
|
// node_modules/lucide-react/dist/esm/icons/text-align-center.js
|
|
1351
|
-
var
|
|
1372
|
+
var __iconNode58, TextAlignCenter;
|
|
1352
1373
|
var init_text_align_center = __esm({
|
|
1353
1374
|
"node_modules/lucide-react/dist/esm/icons/text-align-center.js"() {
|
|
1354
1375
|
"use strict";
|
|
1355
1376
|
init_react_import();
|
|
1356
1377
|
init_createLucideIcon();
|
|
1357
|
-
|
|
1378
|
+
__iconNode58 = [
|
|
1358
1379
|
["path", { d: "M21 5H3", key: "1fi0y6" }],
|
|
1359
1380
|
["path", { d: "M17 12H7", key: "16if0g" }],
|
|
1360
1381
|
["path", { d: "M19 19H5", key: "vjpgq2" }]
|
|
1361
1382
|
];
|
|
1362
|
-
TextAlignCenter = createLucideIcon("text-align-center",
|
|
1383
|
+
TextAlignCenter = createLucideIcon("text-align-center", __iconNode58);
|
|
1363
1384
|
}
|
|
1364
1385
|
});
|
|
1365
1386
|
|
|
1366
1387
|
// node_modules/lucide-react/dist/esm/icons/text-align-end.js
|
|
1367
|
-
var
|
|
1388
|
+
var __iconNode59, TextAlignEnd;
|
|
1368
1389
|
var init_text_align_end = __esm({
|
|
1369
1390
|
"node_modules/lucide-react/dist/esm/icons/text-align-end.js"() {
|
|
1370
1391
|
"use strict";
|
|
1371
1392
|
init_react_import();
|
|
1372
1393
|
init_createLucideIcon();
|
|
1373
|
-
|
|
1394
|
+
__iconNode59 = [
|
|
1374
1395
|
["path", { d: "M21 5H3", key: "1fi0y6" }],
|
|
1375
1396
|
["path", { d: "M21 12H9", key: "dn1m92" }],
|
|
1376
1397
|
["path", { d: "M21 19H7", key: "4cu937" }]
|
|
1377
1398
|
];
|
|
1378
|
-
TextAlignEnd = createLucideIcon("text-align-end",
|
|
1399
|
+
TextAlignEnd = createLucideIcon("text-align-end", __iconNode59);
|
|
1379
1400
|
}
|
|
1380
1401
|
});
|
|
1381
1402
|
|
|
1382
1403
|
// node_modules/lucide-react/dist/esm/icons/text-align-justify.js
|
|
1383
|
-
var
|
|
1404
|
+
var __iconNode60, TextAlignJustify;
|
|
1384
1405
|
var init_text_align_justify = __esm({
|
|
1385
1406
|
"node_modules/lucide-react/dist/esm/icons/text-align-justify.js"() {
|
|
1386
1407
|
"use strict";
|
|
1387
1408
|
init_react_import();
|
|
1388
1409
|
init_createLucideIcon();
|
|
1389
|
-
|
|
1410
|
+
__iconNode60 = [
|
|
1390
1411
|
["path", { d: "M3 5h18", key: "1u36vt" }],
|
|
1391
1412
|
["path", { d: "M3 12h18", key: "1i2n21" }],
|
|
1392
1413
|
["path", { d: "M3 19h18", key: "awlh7x" }]
|
|
1393
1414
|
];
|
|
1394
|
-
TextAlignJustify = createLucideIcon("text-align-justify",
|
|
1415
|
+
TextAlignJustify = createLucideIcon("text-align-justify", __iconNode60);
|
|
1395
1416
|
}
|
|
1396
1417
|
});
|
|
1397
1418
|
|
|
1398
1419
|
// node_modules/lucide-react/dist/esm/icons/text-align-start.js
|
|
1399
|
-
var
|
|
1420
|
+
var __iconNode61, TextAlignStart;
|
|
1400
1421
|
var init_text_align_start = __esm({
|
|
1401
1422
|
"node_modules/lucide-react/dist/esm/icons/text-align-start.js"() {
|
|
1402
1423
|
"use strict";
|
|
1403
1424
|
init_react_import();
|
|
1404
1425
|
init_createLucideIcon();
|
|
1405
|
-
|
|
1426
|
+
__iconNode61 = [
|
|
1406
1427
|
["path", { d: "M21 5H3", key: "1fi0y6" }],
|
|
1407
1428
|
["path", { d: "M15 12H3", key: "6jk70r" }],
|
|
1408
1429
|
["path", { d: "M17 19H3", key: "z6ezky" }]
|
|
1409
1430
|
];
|
|
1410
|
-
TextAlignStart = createLucideIcon("text-align-start",
|
|
1431
|
+
TextAlignStart = createLucideIcon("text-align-start", __iconNode61);
|
|
1411
1432
|
}
|
|
1412
1433
|
});
|
|
1413
1434
|
|
|
1414
1435
|
// node_modules/lucide-react/dist/esm/icons/toy-brick.js
|
|
1415
|
-
var
|
|
1436
|
+
var __iconNode62, ToyBrick;
|
|
1416
1437
|
var init_toy_brick = __esm({
|
|
1417
1438
|
"node_modules/lucide-react/dist/esm/icons/toy-brick.js"() {
|
|
1418
1439
|
"use strict";
|
|
1419
1440
|
init_react_import();
|
|
1420
1441
|
init_createLucideIcon();
|
|
1421
|
-
|
|
1442
|
+
__iconNode62 = [
|
|
1422
1443
|
["rect", { width: "18", height: "12", x: "3", y: "8", rx: "1", key: "158fvp" }],
|
|
1423
1444
|
["path", { d: "M10 8V5c0-.6-.4-1-1-1H6a1 1 0 0 0-1 1v3", key: "s0042v" }],
|
|
1424
1445
|
["path", { d: "M19 8V5c0-.6-.4-1-1-1h-3a1 1 0 0 0-1 1v3", key: "9wmeh2" }]
|
|
1425
1446
|
];
|
|
1426
|
-
ToyBrick = createLucideIcon("toy-brick",
|
|
1447
|
+
ToyBrick = createLucideIcon("toy-brick", __iconNode62);
|
|
1427
1448
|
}
|
|
1428
1449
|
});
|
|
1429
1450
|
|
|
1430
1451
|
// node_modules/lucide-react/dist/esm/icons/trash.js
|
|
1431
|
-
var
|
|
1452
|
+
var __iconNode63, Trash;
|
|
1432
1453
|
var init_trash = __esm({
|
|
1433
1454
|
"node_modules/lucide-react/dist/esm/icons/trash.js"() {
|
|
1434
1455
|
"use strict";
|
|
1435
1456
|
init_react_import();
|
|
1436
1457
|
init_createLucideIcon();
|
|
1437
|
-
|
|
1458
|
+
__iconNode63 = [
|
|
1438
1459
|
["path", { d: "M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6", key: "miytrc" }],
|
|
1439
1460
|
["path", { d: "M3 6h18", key: "d0wm0j" }],
|
|
1440
1461
|
["path", { d: "M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2", key: "e791ji" }]
|
|
1441
1462
|
];
|
|
1442
|
-
Trash = createLucideIcon("trash",
|
|
1463
|
+
Trash = createLucideIcon("trash", __iconNode63);
|
|
1443
1464
|
}
|
|
1444
1465
|
});
|
|
1445
1466
|
|
|
1446
1467
|
// node_modules/lucide-react/dist/esm/icons/type.js
|
|
1447
|
-
var
|
|
1468
|
+
var __iconNode64, Type;
|
|
1448
1469
|
var init_type = __esm({
|
|
1449
1470
|
"node_modules/lucide-react/dist/esm/icons/type.js"() {
|
|
1450
1471
|
"use strict";
|
|
1451
1472
|
init_react_import();
|
|
1452
1473
|
init_createLucideIcon();
|
|
1453
|
-
|
|
1474
|
+
__iconNode64 = [
|
|
1454
1475
|
["path", { d: "M12 4v16", key: "1654pz" }],
|
|
1455
1476
|
["path", { d: "M4 7V5a1 1 0 0 1 1-1h14a1 1 0 0 1 1 1v2", key: "e0r10z" }],
|
|
1456
1477
|
["path", { d: "M9 20h6", key: "s66wpe" }]
|
|
1457
1478
|
];
|
|
1458
|
-
Type = createLucideIcon("type",
|
|
1479
|
+
Type = createLucideIcon("type", __iconNode64);
|
|
1459
1480
|
}
|
|
1460
1481
|
});
|
|
1461
1482
|
|
|
1462
1483
|
// node_modules/lucide-react/dist/esm/icons/underline.js
|
|
1463
|
-
var
|
|
1484
|
+
var __iconNode65, Underline;
|
|
1464
1485
|
var init_underline = __esm({
|
|
1465
1486
|
"node_modules/lucide-react/dist/esm/icons/underline.js"() {
|
|
1466
1487
|
"use strict";
|
|
1467
1488
|
init_react_import();
|
|
1468
1489
|
init_createLucideIcon();
|
|
1469
|
-
|
|
1490
|
+
__iconNode65 = [
|
|
1470
1491
|
["path", { d: "M6 4v6a6 6 0 0 0 12 0V4", key: "9kb039" }],
|
|
1471
1492
|
["line", { x1: "4", x2: "20", y1: "20", y2: "20", key: "nun2al" }]
|
|
1472
1493
|
];
|
|
1473
|
-
Underline = createLucideIcon("underline",
|
|
1494
|
+
Underline = createLucideIcon("underline", __iconNode65);
|
|
1474
1495
|
}
|
|
1475
1496
|
});
|
|
1476
1497
|
|
|
1477
1498
|
// node_modules/lucide-react/dist/esm/icons/undo-2.js
|
|
1478
|
-
var
|
|
1499
|
+
var __iconNode66, Undo2;
|
|
1479
1500
|
var init_undo_2 = __esm({
|
|
1480
1501
|
"node_modules/lucide-react/dist/esm/icons/undo-2.js"() {
|
|
1481
1502
|
"use strict";
|
|
1482
1503
|
init_react_import();
|
|
1483
1504
|
init_createLucideIcon();
|
|
1484
|
-
|
|
1505
|
+
__iconNode66 = [
|
|
1485
1506
|
["path", { d: "M9 14 4 9l5-5", key: "102s5s" }],
|
|
1486
1507
|
["path", { d: "M4 9h10.5a5.5 5.5 0 0 1 5.5 5.5a5.5 5.5 0 0 1-5.5 5.5H11", key: "f3b9sd" }]
|
|
1487
1508
|
];
|
|
1488
|
-
Undo2 = createLucideIcon("undo-2",
|
|
1509
|
+
Undo2 = createLucideIcon("undo-2", __iconNode66);
|
|
1489
1510
|
}
|
|
1490
1511
|
});
|
|
1491
1512
|
|
|
1492
1513
|
// node_modules/lucide-react/dist/esm/icons/x.js
|
|
1493
|
-
var
|
|
1514
|
+
var __iconNode67, X;
|
|
1494
1515
|
var init_x = __esm({
|
|
1495
1516
|
"node_modules/lucide-react/dist/esm/icons/x.js"() {
|
|
1496
1517
|
"use strict";
|
|
1497
1518
|
init_react_import();
|
|
1498
1519
|
init_createLucideIcon();
|
|
1499
|
-
|
|
1520
|
+
__iconNode67 = [
|
|
1500
1521
|
["path", { d: "M18 6 6 18", key: "1bl5f8" }],
|
|
1501
1522
|
["path", { d: "m6 6 12 12", key: "d8bk6v" }]
|
|
1502
1523
|
];
|
|
1503
|
-
X = createLucideIcon("x",
|
|
1524
|
+
X = createLucideIcon("x", __iconNode67);
|
|
1504
1525
|
}
|
|
1505
1526
|
});
|
|
1506
1527
|
|
|
1507
1528
|
// node_modules/lucide-react/dist/esm/icons/zap.js
|
|
1508
|
-
var
|
|
1529
|
+
var __iconNode68, Zap;
|
|
1509
1530
|
var init_zap = __esm({
|
|
1510
1531
|
"node_modules/lucide-react/dist/esm/icons/zap.js"() {
|
|
1511
1532
|
"use strict";
|
|
1512
1533
|
init_react_import();
|
|
1513
1534
|
init_createLucideIcon();
|
|
1514
|
-
|
|
1535
|
+
__iconNode68 = [
|
|
1515
1536
|
[
|
|
1516
1537
|
"path",
|
|
1517
1538
|
{
|
|
@@ -1520,40 +1541,40 @@ var init_zap = __esm({
|
|
|
1520
1541
|
}
|
|
1521
1542
|
]
|
|
1522
1543
|
];
|
|
1523
|
-
Zap = createLucideIcon("zap",
|
|
1544
|
+
Zap = createLucideIcon("zap", __iconNode68);
|
|
1524
1545
|
}
|
|
1525
1546
|
});
|
|
1526
1547
|
|
|
1527
1548
|
// node_modules/lucide-react/dist/esm/icons/zoom-in.js
|
|
1528
|
-
var
|
|
1549
|
+
var __iconNode69, ZoomIn;
|
|
1529
1550
|
var init_zoom_in = __esm({
|
|
1530
1551
|
"node_modules/lucide-react/dist/esm/icons/zoom-in.js"() {
|
|
1531
1552
|
"use strict";
|
|
1532
1553
|
init_react_import();
|
|
1533
1554
|
init_createLucideIcon();
|
|
1534
|
-
|
|
1555
|
+
__iconNode69 = [
|
|
1535
1556
|
["circle", { cx: "11", cy: "11", r: "8", key: "4ej97u" }],
|
|
1536
1557
|
["line", { x1: "21", x2: "16.65", y1: "21", y2: "16.65", key: "13gj7c" }],
|
|
1537
1558
|
["line", { x1: "11", x2: "11", y1: "8", y2: "14", key: "1vmskp" }],
|
|
1538
1559
|
["line", { x1: "8", x2: "14", y1: "11", y2: "11", key: "durymu" }]
|
|
1539
1560
|
];
|
|
1540
|
-
ZoomIn = createLucideIcon("zoom-in",
|
|
1561
|
+
ZoomIn = createLucideIcon("zoom-in", __iconNode69);
|
|
1541
1562
|
}
|
|
1542
1563
|
});
|
|
1543
1564
|
|
|
1544
1565
|
// node_modules/lucide-react/dist/esm/icons/zoom-out.js
|
|
1545
|
-
var
|
|
1566
|
+
var __iconNode70, ZoomOut;
|
|
1546
1567
|
var init_zoom_out = __esm({
|
|
1547
1568
|
"node_modules/lucide-react/dist/esm/icons/zoom-out.js"() {
|
|
1548
1569
|
"use strict";
|
|
1549
1570
|
init_react_import();
|
|
1550
1571
|
init_createLucideIcon();
|
|
1551
|
-
|
|
1572
|
+
__iconNode70 = [
|
|
1552
1573
|
["circle", { cx: "11", cy: "11", r: "8", key: "4ej97u" }],
|
|
1553
1574
|
["line", { x1: "21", x2: "16.65", y1: "21", y2: "16.65", key: "13gj7c" }],
|
|
1554
1575
|
["line", { x1: "8", x2: "14", y1: "11", y2: "11", key: "durymu" }]
|
|
1555
1576
|
];
|
|
1556
|
-
ZoomOut = createLucideIcon("zoom-out",
|
|
1577
|
+
ZoomOut = createLucideIcon("zoom-out", __iconNode70);
|
|
1557
1578
|
}
|
|
1558
1579
|
});
|
|
1559
1580
|
|
|
@@ -1595,6 +1616,7 @@ var init_lucide_react = __esm({
|
|
|
1595
1616
|
init_heading_6();
|
|
1596
1617
|
init_heading();
|
|
1597
1618
|
init_image();
|
|
1619
|
+
init_inbox();
|
|
1598
1620
|
init_info();
|
|
1599
1621
|
init_italic();
|
|
1600
1622
|
init_layout_dashboard();
|
|
@@ -4095,16 +4117,16 @@ var init_SelectField = __esm({
|
|
|
4095
4117
|
}
|
|
4096
4118
|
});
|
|
4097
4119
|
|
|
4098
|
-
// css-module:/home/
|
|
4120
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/ExternalInput/styles.module.css/#css-module-data
|
|
4099
4121
|
var init_css_module_data3 = __esm({
|
|
4100
|
-
"css-module:/home/
|
|
4122
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/ExternalInput/styles.module.css/#css-module-data"() {
|
|
4101
4123
|
}
|
|
4102
4124
|
});
|
|
4103
4125
|
|
|
4104
|
-
// css-module:/home/
|
|
4126
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/ExternalInput/styles.module.css#css-module
|
|
4105
4127
|
var styles_module_default3;
|
|
4106
4128
|
var init_styles_module3 = __esm({
|
|
4107
|
-
"css-module:/home/
|
|
4129
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/ExternalInput/styles.module.css#css-module"() {
|
|
4108
4130
|
"use strict";
|
|
4109
4131
|
init_react_import();
|
|
4110
4132
|
init_css_module_data3();
|
|
@@ -4112,16 +4134,16 @@ var init_styles_module3 = __esm({
|
|
|
4112
4134
|
}
|
|
4113
4135
|
});
|
|
4114
4136
|
|
|
4115
|
-
// css-module:/home/
|
|
4137
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/Modal/styles.module.css/#css-module-data
|
|
4116
4138
|
var init_css_module_data4 = __esm({
|
|
4117
|
-
"css-module:/home/
|
|
4139
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/Modal/styles.module.css/#css-module-data"() {
|
|
4118
4140
|
}
|
|
4119
4141
|
});
|
|
4120
4142
|
|
|
4121
|
-
// css-module:/home/
|
|
4143
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/Modal/styles.module.css#css-module
|
|
4122
4144
|
var styles_module_default4;
|
|
4123
4145
|
var init_styles_module4 = __esm({
|
|
4124
|
-
"css-module:/home/
|
|
4146
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/Modal/styles.module.css#css-module"() {
|
|
4125
4147
|
"use strict";
|
|
4126
4148
|
init_react_import();
|
|
4127
4149
|
init_css_module_data4();
|
|
@@ -4150,6 +4172,16 @@ var init_Modal = __esm({
|
|
|
4150
4172
|
(0, import_react14.useEffect)(() => {
|
|
4151
4173
|
setRootEl(document.getElementById("credbuild-portal-root"));
|
|
4152
4174
|
}, []);
|
|
4175
|
+
(0, import_react14.useEffect)(() => {
|
|
4176
|
+
if (!isOpen) return;
|
|
4177
|
+
const handleKeyDown = (e) => {
|
|
4178
|
+
if (e.key === "Escape") {
|
|
4179
|
+
onClose();
|
|
4180
|
+
}
|
|
4181
|
+
};
|
|
4182
|
+
document.addEventListener("keydown", handleKeyDown);
|
|
4183
|
+
return () => document.removeEventListener("keydown", handleKeyDown);
|
|
4184
|
+
}, [isOpen, onClose]);
|
|
4153
4185
|
if (!rootEl) {
|
|
4154
4186
|
return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("div", {});
|
|
4155
4187
|
}
|
|
@@ -4159,6 +4191,8 @@ var init_Modal = __esm({
|
|
|
4159
4191
|
{
|
|
4160
4192
|
className: getClassName5("inner"),
|
|
4161
4193
|
onClick: (e) => e.stopPropagation(),
|
|
4194
|
+
role: "dialog",
|
|
4195
|
+
"aria-modal": "true",
|
|
4162
4196
|
children
|
|
4163
4197
|
}
|
|
4164
4198
|
) }),
|
|
@@ -4168,16 +4202,16 @@ var init_Modal = __esm({
|
|
|
4168
4202
|
}
|
|
4169
4203
|
});
|
|
4170
4204
|
|
|
4171
|
-
// css-module:/home/
|
|
4205
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/Heading/styles.module.css/#css-module-data
|
|
4172
4206
|
var init_css_module_data5 = __esm({
|
|
4173
|
-
"css-module:/home/
|
|
4207
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/Heading/styles.module.css/#css-module-data"() {
|
|
4174
4208
|
}
|
|
4175
4209
|
});
|
|
4176
4210
|
|
|
4177
|
-
// css-module:/home/
|
|
4211
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/Heading/styles.module.css#css-module
|
|
4178
4212
|
var styles_module_default5;
|
|
4179
4213
|
var init_styles_module5 = __esm({
|
|
4180
|
-
"css-module:/home/
|
|
4214
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/Heading/styles.module.css#css-module"() {
|
|
4181
4215
|
"use strict";
|
|
4182
4216
|
init_react_import();
|
|
4183
4217
|
init_css_module_data5();
|
|
@@ -4457,16 +4491,16 @@ var init_lib = __esm({
|
|
|
4457
4491
|
}
|
|
4458
4492
|
});
|
|
4459
4493
|
|
|
4460
|
-
// css-module:/home/
|
|
4494
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/Loader/styles.module.css/#css-module-data
|
|
4461
4495
|
var init_css_module_data6 = __esm({
|
|
4462
|
-
"css-module:/home/
|
|
4496
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/Loader/styles.module.css/#css-module-data"() {
|
|
4463
4497
|
}
|
|
4464
4498
|
});
|
|
4465
4499
|
|
|
4466
|
-
// css-module:/home/
|
|
4500
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/Loader/styles.module.css#css-module
|
|
4467
4501
|
var styles_module_default6;
|
|
4468
4502
|
var init_styles_module6 = __esm({
|
|
4469
|
-
"css-module:/home/
|
|
4503
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/Loader/styles.module.css#css-module"() {
|
|
4470
4504
|
"use strict";
|
|
4471
4505
|
init_react_import();
|
|
4472
4506
|
init_css_module_data6();
|
|
@@ -4506,16 +4540,16 @@ var init_Loader = __esm({
|
|
|
4506
4540
|
}
|
|
4507
4541
|
});
|
|
4508
4542
|
|
|
4509
|
-
// css-module:/home/
|
|
4543
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/Button/Button.module.css/#css-module-data
|
|
4510
4544
|
var init_css_module_data7 = __esm({
|
|
4511
|
-
"css-module:/home/
|
|
4545
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/Button/Button.module.css/#css-module-data"() {
|
|
4512
4546
|
}
|
|
4513
4547
|
});
|
|
4514
4548
|
|
|
4515
|
-
// css-module:/home/
|
|
4549
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/Button/Button.module.css#css-module
|
|
4516
4550
|
var Button_module_default;
|
|
4517
4551
|
var init_Button_module = __esm({
|
|
4518
|
-
"css-module:/home/
|
|
4552
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/Button/Button.module.css#css-module"() {
|
|
4519
4553
|
"use strict";
|
|
4520
4554
|
init_react_import();
|
|
4521
4555
|
init_css_module_data7();
|
|
@@ -4573,7 +4607,8 @@ var init_Button = __esm({
|
|
|
4573
4607
|
}) => {
|
|
4574
4608
|
const [loading, setLoading] = (0, import_react16.useState)(loadingProp);
|
|
4575
4609
|
(0, import_react16.useEffect)(() => setLoading(loadingProp), [loadingProp]);
|
|
4576
|
-
const
|
|
4610
|
+
const safeHref = href && href.trim().toLowerCase().startsWith("javascript:") ? "#" : href;
|
|
4611
|
+
const ElementType = safeHref ? "a" : type ? "button" : "span";
|
|
4577
4612
|
const dataAttrs = filterDataAttrs(props);
|
|
4578
4613
|
const el = /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
|
|
4579
4614
|
ElementType,
|
|
@@ -4596,8 +4631,8 @@ var init_Button = __esm({
|
|
|
4596
4631
|
disabled: disabled || loading,
|
|
4597
4632
|
tabIndex,
|
|
4598
4633
|
target: newTab ? "_blank" : void 0,
|
|
4599
|
-
rel: newTab ? "noreferrer" : void 0,
|
|
4600
|
-
href,
|
|
4634
|
+
rel: newTab ? "noopener noreferrer" : void 0,
|
|
4635
|
+
href: safeHref,
|
|
4601
4636
|
...dataAttrs,
|
|
4602
4637
|
children: [
|
|
4603
4638
|
icon && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: getClassName8("icon"), children: icon }),
|
|
@@ -4620,16 +4655,16 @@ var init_Button2 = __esm({
|
|
|
4620
4655
|
}
|
|
4621
4656
|
});
|
|
4622
4657
|
|
|
4623
|
-
// css-module:/home/
|
|
4658
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/IconButton/IconButton.module.css/#css-module-data
|
|
4624
4659
|
var init_css_module_data8 = __esm({
|
|
4625
|
-
"css-module:/home/
|
|
4660
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/IconButton/IconButton.module.css/#css-module-data"() {
|
|
4626
4661
|
}
|
|
4627
4662
|
});
|
|
4628
4663
|
|
|
4629
|
-
// css-module:/home/
|
|
4664
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/IconButton/IconButton.module.css#css-module
|
|
4630
4665
|
var IconButton_module_default;
|
|
4631
4666
|
var init_IconButton_module = __esm({
|
|
4632
|
-
"css-module:/home/
|
|
4667
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/IconButton/IconButton.module.css#css-module"() {
|
|
4633
4668
|
"use strict";
|
|
4634
4669
|
init_react_import();
|
|
4635
4670
|
init_css_module_data8();
|
|
@@ -4663,7 +4698,8 @@ var init_IconButton = __esm({
|
|
|
4663
4698
|
suppressHydrationWarning
|
|
4664
4699
|
}) => {
|
|
4665
4700
|
const [loading, setLoading] = (0, import_react17.useState)(false);
|
|
4666
|
-
const
|
|
4701
|
+
const safeHref = href && href.trim().toLowerCase().startsWith("javascript:") ? "#" : href;
|
|
4702
|
+
const ElementType = safeHref ? "a" : "button";
|
|
4667
4703
|
const el = /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
|
|
4668
4704
|
ElementType,
|
|
4669
4705
|
{
|
|
@@ -4683,8 +4719,8 @@ var init_IconButton = __esm({
|
|
|
4683
4719
|
disabled: disabled || loading,
|
|
4684
4720
|
tabIndex,
|
|
4685
4721
|
target: newTab ? "_blank" : void 0,
|
|
4686
|
-
rel: newTab ? "noreferrer" : void 0,
|
|
4687
|
-
href,
|
|
4722
|
+
rel: newTab ? "noopener noreferrer" : void 0,
|
|
4723
|
+
href: safeHref,
|
|
4688
4724
|
title,
|
|
4689
4725
|
suppressHydrationWarning,
|
|
4690
4726
|
children: [
|
|
@@ -4830,6 +4866,8 @@ var init_ExternalInput = __esm({
|
|
|
4830
4866
|
onChange(null);
|
|
4831
4867
|
},
|
|
4832
4868
|
disabled: readOnly,
|
|
4869
|
+
title: "Clear selection",
|
|
4870
|
+
"aria-label": "Clear selection",
|
|
4833
4871
|
children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(LockOpen, { size: 16 })
|
|
4834
4872
|
}
|
|
4835
4873
|
)
|
|
@@ -5184,16 +5222,16 @@ var init_TextareaField = __esm({
|
|
|
5184
5222
|
}
|
|
5185
5223
|
});
|
|
5186
5224
|
|
|
5187
|
-
// css-module:/home/
|
|
5225
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/RichTextMenu/styles.module.css/#css-module-data
|
|
5188
5226
|
var init_css_module_data9 = __esm({
|
|
5189
|
-
"css-module:/home/
|
|
5227
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/RichTextMenu/styles.module.css/#css-module-data"() {
|
|
5190
5228
|
}
|
|
5191
5229
|
});
|
|
5192
5230
|
|
|
5193
|
-
// css-module:/home/
|
|
5231
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/RichTextMenu/styles.module.css#css-module
|
|
5194
5232
|
var styles_module_default7;
|
|
5195
5233
|
var init_styles_module7 = __esm({
|
|
5196
|
-
"css-module:/home/
|
|
5234
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/RichTextMenu/styles.module.css#css-module"() {
|
|
5197
5235
|
"use strict";
|
|
5198
5236
|
init_react_import();
|
|
5199
5237
|
init_css_module_data9();
|
|
@@ -5201,16 +5239,16 @@ var init_styles_module7 = __esm({
|
|
|
5201
5239
|
}
|
|
5202
5240
|
});
|
|
5203
5241
|
|
|
5204
|
-
// css-module:/home/
|
|
5242
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/RichTextMenu/components/Control/styles.module.css/#css-module-data
|
|
5205
5243
|
var init_css_module_data10 = __esm({
|
|
5206
|
-
"css-module:/home/
|
|
5244
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/RichTextMenu/components/Control/styles.module.css/#css-module-data"() {
|
|
5207
5245
|
}
|
|
5208
5246
|
});
|
|
5209
5247
|
|
|
5210
|
-
// css-module:/home/
|
|
5248
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/RichTextMenu/components/Control/styles.module.css#css-module
|
|
5211
5249
|
var styles_module_default8;
|
|
5212
5250
|
var init_styles_module8 = __esm({
|
|
5213
|
-
"css-module:/home/
|
|
5251
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/RichTextMenu/components/Control/styles.module.css#css-module"() {
|
|
5214
5252
|
"use strict";
|
|
5215
5253
|
init_react_import();
|
|
5216
5254
|
init_css_module_data10();
|
|
@@ -5395,16 +5433,16 @@ var init_AlignJustify = __esm({
|
|
|
5395
5433
|
}
|
|
5396
5434
|
});
|
|
5397
5435
|
|
|
5398
|
-
// css-module:/home/
|
|
5436
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/Select/styles.module.css/#css-module-data
|
|
5399
5437
|
var init_css_module_data11 = __esm({
|
|
5400
|
-
"css-module:/home/
|
|
5438
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/Select/styles.module.css/#css-module-data"() {
|
|
5401
5439
|
}
|
|
5402
5440
|
});
|
|
5403
5441
|
|
|
5404
|
-
// css-module:/home/
|
|
5442
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/Select/styles.module.css#css-module
|
|
5405
5443
|
var styles_module_default9;
|
|
5406
5444
|
var init_styles_module9 = __esm({
|
|
5407
|
-
"css-module:/home/
|
|
5445
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/Select/styles.module.css#css-module"() {
|
|
5408
5446
|
"use strict";
|
|
5409
5447
|
init_react_import();
|
|
5410
5448
|
init_css_module_data11();
|
|
@@ -6370,16 +6408,16 @@ var init_inner = __esm({
|
|
|
6370
6408
|
}
|
|
6371
6409
|
});
|
|
6372
6410
|
|
|
6373
|
-
// css-module:/home/
|
|
6411
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/RichTextEditor/styles.module.css/#css-module-data
|
|
6374
6412
|
var init_css_module_data12 = __esm({
|
|
6375
|
-
"css-module:/home/
|
|
6413
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/RichTextEditor/styles.module.css/#css-module-data"() {
|
|
6376
6414
|
}
|
|
6377
6415
|
});
|
|
6378
6416
|
|
|
6379
|
-
// css-module:/home/
|
|
6417
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/RichTextEditor/styles.module.css#css-module
|
|
6380
6418
|
var styles_module_default10;
|
|
6381
6419
|
var init_styles_module10 = __esm({
|
|
6382
|
-
"css-module:/home/
|
|
6420
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/RichTextEditor/styles.module.css#css-module"() {
|
|
6383
6421
|
"use strict";
|
|
6384
6422
|
init_react_import();
|
|
6385
6423
|
init_css_module_data12();
|
|
@@ -6467,12 +6505,13 @@ var init_EditorInner = __esm({
|
|
|
6467
6505
|
});
|
|
6468
6506
|
|
|
6469
6507
|
// components/RichTextEditor/components/EditorFallback.tsx
|
|
6470
|
-
var import_react35, import_jsx_runtime44, EditorFallback;
|
|
6508
|
+
var import_react35, import_isomorphic_dompurify, import_jsx_runtime44, EditorFallback;
|
|
6471
6509
|
var init_EditorFallback = __esm({
|
|
6472
6510
|
"components/RichTextEditor/components/EditorFallback.tsx"() {
|
|
6473
6511
|
"use strict";
|
|
6474
6512
|
init_react_import();
|
|
6475
6513
|
import_react35 = require("react");
|
|
6514
|
+
import_isomorphic_dompurify = __toESM(require("isomorphic-dompurify"));
|
|
6476
6515
|
init_inner();
|
|
6477
6516
|
init_EditorInner();
|
|
6478
6517
|
import_jsx_runtime44 = require("react/jsx-runtime");
|
|
@@ -6495,7 +6534,7 @@ var init_EditorFallback = __esm({
|
|
|
6495
6534
|
"div",
|
|
6496
6535
|
{
|
|
6497
6536
|
className: "rich-text",
|
|
6498
|
-
dangerouslySetInnerHTML: { __html: props.content },
|
|
6537
|
+
dangerouslySetInnerHTML: { __html: import_isomorphic_dompurify.default.sanitize(props.content) },
|
|
6499
6538
|
contentEditable: true
|
|
6500
6539
|
}
|
|
6501
6540
|
)
|
|
@@ -6966,16 +7005,16 @@ var init_RichtextField = __esm({
|
|
|
6966
7005
|
}
|
|
6967
7006
|
});
|
|
6968
7007
|
|
|
6969
|
-
// css-module:/home/
|
|
7008
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/AutoField/fields/ArrayField/styles.module.css/#css-module-data
|
|
6970
7009
|
var init_css_module_data13 = __esm({
|
|
6971
|
-
"css-module:/home/
|
|
7010
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/AutoField/fields/ArrayField/styles.module.css/#css-module-data"() {
|
|
6972
7011
|
}
|
|
6973
7012
|
});
|
|
6974
7013
|
|
|
6975
|
-
// css-module:/home/
|
|
7014
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/AutoField/fields/ArrayField/styles.module.css#css-module
|
|
6976
7015
|
var styles_module_default11;
|
|
6977
7016
|
var init_styles_module11 = __esm({
|
|
6978
|
-
"css-module:/home/
|
|
7017
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/AutoField/fields/ArrayField/styles.module.css#css-module"() {
|
|
6979
7018
|
"use strict";
|
|
6980
7019
|
init_react_import();
|
|
6981
7020
|
init_css_module_data13();
|
|
@@ -6983,16 +7022,16 @@ var init_styles_module11 = __esm({
|
|
|
6983
7022
|
}
|
|
6984
7023
|
});
|
|
6985
7024
|
|
|
6986
|
-
// css-module:/home/
|
|
7025
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/DragIcon/styles.module.css/#css-module-data
|
|
6987
7026
|
var init_css_module_data14 = __esm({
|
|
6988
|
-
"css-module:/home/
|
|
7027
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/DragIcon/styles.module.css/#css-module-data"() {
|
|
6989
7028
|
}
|
|
6990
7029
|
});
|
|
6991
7030
|
|
|
6992
|
-
// css-module:/home/
|
|
7031
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/DragIcon/styles.module.css#css-module
|
|
6993
7032
|
var styles_module_default12;
|
|
6994
7033
|
var init_styles_module12 = __esm({
|
|
6995
|
-
"css-module:/home/
|
|
7034
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/DragIcon/styles.module.css#css-module"() {
|
|
6996
7035
|
"use strict";
|
|
6997
7036
|
init_react_import();
|
|
6998
7037
|
init_css_module_data14();
|
|
@@ -7947,6 +7986,8 @@ var init_ArrayField = __esm({
|
|
|
7947
7986
|
{
|
|
7948
7987
|
type: "button",
|
|
7949
7988
|
className: getClassName18("addButton"),
|
|
7989
|
+
title: "Add item",
|
|
7990
|
+
"aria-label": "Add item",
|
|
7950
7991
|
onClick: () => {
|
|
7951
7992
|
if (isDraggingAny) return;
|
|
7952
7993
|
const value = getValue();
|
|
@@ -7973,16 +8014,16 @@ var init_ArrayField = __esm({
|
|
|
7973
8014
|
}
|
|
7974
8015
|
});
|
|
7975
8016
|
|
|
7976
|
-
// css-module:/home/
|
|
8017
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/AutoField/fields/ObjectField/styles.module.css/#css-module-data
|
|
7977
8018
|
var init_css_module_data15 = __esm({
|
|
7978
|
-
"css-module:/home/
|
|
8019
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/AutoField/fields/ObjectField/styles.module.css/#css-module-data"() {
|
|
7979
8020
|
}
|
|
7980
8021
|
});
|
|
7981
8022
|
|
|
7982
|
-
// css-module:/home/
|
|
8023
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/AutoField/fields/ObjectField/styles.module.css#css-module
|
|
7983
8024
|
var styles_module_default13;
|
|
7984
8025
|
var init_styles_module13 = __esm({
|
|
7985
|
-
"css-module:/home/
|
|
8026
|
+
"css-module:/home/runner/work/credbuild/credbuild/components/AutoField/fields/ObjectField/styles.module.css#css-module"() {
|
|
7986
8027
|
"use strict";
|
|
7987
8028
|
init_react_import();
|
|
7988
8029
|
init_css_module_data15();
|
|
@@ -8038,6 +8079,8 @@ var init_ObjectField = __esm({
|
|
|
8038
8079
|
type: "button",
|
|
8039
8080
|
className: getClassName19("header"),
|
|
8040
8081
|
onClick: () => setIsOpen(!isOpen),
|
|
8082
|
+
"aria-expanded": isOpen,
|
|
8083
|
+
"aria-controls": `${id}-content`,
|
|
8041
8084
|
children: [
|
|
8042
8085
|
/* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { style: { display: "flex", alignItems: "center", gap: "8px" }, children: [
|
|
8043
8086
|
labelIcon || /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(LayoutTemplate, { size: 12, strokeWidth: 2.5 }),
|
|
@@ -8047,7 +8090,7 @@ var init_ObjectField = __esm({
|
|
|
8047
8090
|
]
|
|
8048
8091
|
}
|
|
8049
8092
|
),
|
|
8050
|
-
isOpen && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { className: getClassName19("content"), children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("fieldset", { className: getClassName19("fieldset"), children: Object.keys(field.objectFields).map((subName) => {
|
|
8093
|
+
isOpen && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { id: `${id}-content`, className: getClassName19("content"), children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("fieldset", { className: getClassName19("fieldset"), children: Object.keys(field.objectFields).map((subName) => {
|
|
8051
8094
|
const subField = field.objectFields[subName];
|
|
8052
8095
|
const subPath = `${localName}.${subName}`;
|
|
8053
8096
|
return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
@@ -8309,11 +8352,11 @@ function RichTextRender({
|
|
|
8309
8352
|
}) {
|
|
8310
8353
|
const { tiptap = {}, options } = field;
|
|
8311
8354
|
const { extensions = [] } = tiptap;
|
|
8312
|
-
const loadedExtensions = (0,
|
|
8355
|
+
const loadedExtensions = (0, import_react66.useMemo)(
|
|
8313
8356
|
() => [CredBuildRichText.configure(options), ...extensions],
|
|
8314
8357
|
[extensions, options]
|
|
8315
8358
|
);
|
|
8316
|
-
const normalized = (0,
|
|
8359
|
+
const normalized = (0, import_react66.useMemo)(() => {
|
|
8317
8360
|
if (typeof content === "object" && content?.type === "doc") {
|
|
8318
8361
|
return content;
|
|
8319
8362
|
}
|
|
@@ -8331,18 +8374,20 @@ function RichTextRender({
|
|
|
8331
8374
|
}
|
|
8332
8375
|
return { type: "doc", content: [] };
|
|
8333
8376
|
}, [content, loadedExtensions]);
|
|
8334
|
-
const html = (0,
|
|
8377
|
+
const html = (0, import_react66.useMemo)(() => {
|
|
8335
8378
|
return (0, import_html.generateHTML)(normalized, loadedExtensions);
|
|
8336
8379
|
}, [normalized, loadedExtensions]);
|
|
8337
|
-
|
|
8380
|
+
const sanitizedHtml = (0, import_react66.useMemo)(() => import_isomorphic_dompurify3.default.sanitize(html), [html]);
|
|
8381
|
+
return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: getClassName24(), children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: "rich-text", dangerouslySetInnerHTML: { __html: sanitizedHtml } }) });
|
|
8338
8382
|
}
|
|
8339
|
-
var import_html,
|
|
8383
|
+
var import_html, import_react66, import_isomorphic_dompurify3, import_jsx_runtime63, getClassName24;
|
|
8340
8384
|
var init_Render = __esm({
|
|
8341
8385
|
"components/RichTextEditor/components/Render.tsx"() {
|
|
8342
8386
|
"use strict";
|
|
8343
8387
|
init_react_import();
|
|
8344
8388
|
import_html = require("@tiptap/html");
|
|
8345
|
-
|
|
8389
|
+
import_react66 = require("react");
|
|
8390
|
+
import_isomorphic_dompurify3 = __toESM(require("isomorphic-dompurify"));
|
|
8346
8391
|
init_get_class_name_factory();
|
|
8347
8392
|
init_styles_module10();
|
|
8348
8393
|
init_extension();
|
|
@@ -8465,7 +8510,8 @@ var SliderField = ({
|
|
|
8465
8510
|
step = 1,
|
|
8466
8511
|
unit = "px",
|
|
8467
8512
|
defaultValue = 0,
|
|
8468
|
-
useUnits = true
|
|
8513
|
+
useUnits = true,
|
|
8514
|
+
style = {}
|
|
8469
8515
|
}) => {
|
|
8470
8516
|
const parseValue = (val) => {
|
|
8471
8517
|
if (typeof val === "number") return val;
|
|
@@ -8496,7 +8542,7 @@ var SliderField = ({
|
|
|
8496
8542
|
const newUnit = e.target.value;
|
|
8497
8543
|
onChange(`${numericValue}${newUnit}`);
|
|
8498
8544
|
};
|
|
8499
|
-
return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)("div", { style: { padding: "
|
|
8545
|
+
return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)("div", { style: { padding: "0", ...style }, children: [
|
|
8500
8546
|
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)("style", { dangerouslySetInnerHTML: { __html: `
|
|
8501
8547
|
.cb-slider-input {
|
|
8502
8548
|
-webkit-appearance: none;
|
|
@@ -8601,7 +8647,7 @@ var SliderField = ({
|
|
|
8601
8647
|
|
|
8602
8648
|
// components/AutoField/fields/ResponsiveSliderField/index.tsx
|
|
8603
8649
|
init_react_import();
|
|
8604
|
-
|
|
8650
|
+
init_store2();
|
|
8605
8651
|
var import_jsx_runtime57 = require("react/jsx-runtime");
|
|
8606
8652
|
var DesktopIcon = () => /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
|
|
8607
8653
|
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)("rect", { x: "2", y: "3", width: "20", height: "14", rx: "2", ry: "2" }),
|
|
@@ -8626,7 +8672,39 @@ var ResponsiveSliderField = ({
|
|
|
8626
8672
|
step = 1,
|
|
8627
8673
|
defaultValue = 0
|
|
8628
8674
|
}) => {
|
|
8629
|
-
const
|
|
8675
|
+
const setUi = useAppStore((s) => s.setUi);
|
|
8676
|
+
const viewportsState = useAppStore((s) => s.state.ui.viewports);
|
|
8677
|
+
const zoomConfig = useAppStore((s) => s.zoomConfig);
|
|
8678
|
+
const setZoomConfig = useAppStore((s) => s.setZoomConfig);
|
|
8679
|
+
const viewportConfigOptions = useAppStore((s) => s.viewports);
|
|
8680
|
+
const getModeFromWidth = (width) => {
|
|
8681
|
+
if (width === "100%") return "desktop";
|
|
8682
|
+
const w = typeof width === "string" ? parseInt(width) : width;
|
|
8683
|
+
if (w <= 480) return "mobile";
|
|
8684
|
+
if (w <= 900) return "tablet";
|
|
8685
|
+
return "desktop";
|
|
8686
|
+
};
|
|
8687
|
+
const mode = getModeFromWidth(viewportsState.current.width);
|
|
8688
|
+
const changeGlobalViewport = (targetMode) => {
|
|
8689
|
+
const targetIcon = targetMode === "mobile" ? "Smartphone" : targetMode === "tablet" ? "Tablet" : "Monitor";
|
|
8690
|
+
const matched = viewportConfigOptions.find((v) => v.icon === targetIcon) || viewportConfigOptions.find((v) => {
|
|
8691
|
+
if (targetMode === "mobile") return v.width !== "100%" && parseInt(String(v.width)) <= 480;
|
|
8692
|
+
if (targetMode === "tablet") return v.width !== "100%" && parseInt(String(v.width)) > 480 && parseInt(String(v.width)) <= 900;
|
|
8693
|
+
return v.width === "100%" || parseInt(String(v.width)) > 900;
|
|
8694
|
+
}) || viewportConfigOptions[0];
|
|
8695
|
+
const isFullWidth = matched.width === "100%";
|
|
8696
|
+
const uiViewport = {
|
|
8697
|
+
...matched,
|
|
8698
|
+
height: matched.height || "auto",
|
|
8699
|
+
zoom: isFullWidth ? 1 : zoomConfig.zoom
|
|
8700
|
+
};
|
|
8701
|
+
if (isFullWidth) {
|
|
8702
|
+
setZoomConfig({ ...zoomConfig, zoom: 1 });
|
|
8703
|
+
}
|
|
8704
|
+
setUi({
|
|
8705
|
+
viewports: { ...viewportsState, current: uiViewport }
|
|
8706
|
+
});
|
|
8707
|
+
};
|
|
8630
8708
|
const getCurrentValue = () => {
|
|
8631
8709
|
const val = value?.[mode];
|
|
8632
8710
|
if (val !== void 0 && val !== null) {
|
|
@@ -8654,34 +8732,38 @@ var ResponsiveSliderField = ({
|
|
|
8654
8732
|
[mode]: newVal
|
|
8655
8733
|
});
|
|
8656
8734
|
};
|
|
8657
|
-
return /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { style: { display: "flex", flexDirection: "column", gap: "2px" }, children: [
|
|
8658
|
-
/* @__PURE__ */ (0, import_jsx_runtime57.
|
|
8659
|
-
|
|
8660
|
-
|
|
8661
|
-
|
|
8662
|
-
|
|
8663
|
-
|
|
8664
|
-
|
|
8665
|
-
|
|
8666
|
-
|
|
8667
|
-
|
|
8668
|
-
|
|
8669
|
-
|
|
8670
|
-
|
|
8671
|
-
|
|
8672
|
-
|
|
8673
|
-
] })
|
|
8735
|
+
return /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { style: { display: "flex", flexDirection: "column", gap: "2px", width: "100%" }, children: [
|
|
8736
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("div", { style: { display: "flex", alignItems: "center", justifyContent: "space-between", marginBottom: "2px" }, children: /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("label", { style: {
|
|
8737
|
+
fontSize: "10px",
|
|
8738
|
+
fontWeight: 600,
|
|
8739
|
+
color: "var(--cb-silver-muted, #71717a)",
|
|
8740
|
+
display: "flex",
|
|
8741
|
+
alignItems: "center",
|
|
8742
|
+
gap: "4px",
|
|
8743
|
+
textTransform: "uppercase",
|
|
8744
|
+
letterSpacing: "0.05em"
|
|
8745
|
+
}, children: [
|
|
8746
|
+
label,
|
|
8747
|
+
/* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("span", { style: { fontSize: "9px", opacity: 0.5, fontWeight: "400" }, children: [
|
|
8748
|
+
"(",
|
|
8749
|
+
mode,
|
|
8750
|
+
")"
|
|
8751
|
+
] })
|
|
8752
|
+
] }) }),
|
|
8753
|
+
/* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { style: { display: "flex", alignItems: "center", gap: "8px", width: "100%" }, children: [
|
|
8674
8754
|
/* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { style: {
|
|
8675
8755
|
display: "flex",
|
|
8676
8756
|
backgroundColor: "var(--cb-bg-panel, #f1f5f9)",
|
|
8677
8757
|
borderRadius: "4px",
|
|
8678
8758
|
padding: "1px",
|
|
8679
|
-
border: "1px solid var(--cb-border, #e2e8f0)"
|
|
8759
|
+
border: "1px solid var(--cb-border, #e2e8f0)",
|
|
8760
|
+
flexShrink: 0
|
|
8680
8761
|
}, children: [
|
|
8681
8762
|
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
|
|
8682
8763
|
"button",
|
|
8683
8764
|
{
|
|
8684
|
-
|
|
8765
|
+
type: "button",
|
|
8766
|
+
onClick: () => changeGlobalViewport("desktop"),
|
|
8685
8767
|
style: {
|
|
8686
8768
|
padding: "2px 5px",
|
|
8687
8769
|
border: "none",
|
|
@@ -8695,13 +8777,16 @@ var ResponsiveSliderField = ({
|
|
|
8695
8777
|
transition: "all 0.1s ease"
|
|
8696
8778
|
},
|
|
8697
8779
|
title: "Desktop",
|
|
8780
|
+
"aria-label": "Desktop viewport",
|
|
8781
|
+
"aria-pressed": mode === "desktop",
|
|
8698
8782
|
children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(DesktopIcon, {})
|
|
8699
8783
|
}
|
|
8700
8784
|
),
|
|
8701
8785
|
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
|
|
8702
8786
|
"button",
|
|
8703
8787
|
{
|
|
8704
|
-
|
|
8788
|
+
type: "button",
|
|
8789
|
+
onClick: () => changeGlobalViewport("tablet"),
|
|
8705
8790
|
style: {
|
|
8706
8791
|
padding: "2px 5px",
|
|
8707
8792
|
border: "none",
|
|
@@ -8715,13 +8800,16 @@ var ResponsiveSliderField = ({
|
|
|
8715
8800
|
transition: "all 0.1s ease"
|
|
8716
8801
|
},
|
|
8717
8802
|
title: "Tablet",
|
|
8803
|
+
"aria-label": "Tablet viewport",
|
|
8804
|
+
"aria-pressed": mode === "tablet",
|
|
8718
8805
|
children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(TabletIcon, {})
|
|
8719
8806
|
}
|
|
8720
8807
|
),
|
|
8721
8808
|
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
|
|
8722
8809
|
"button",
|
|
8723
8810
|
{
|
|
8724
|
-
|
|
8811
|
+
type: "button",
|
|
8812
|
+
onClick: () => changeGlobalViewport("mobile"),
|
|
8725
8813
|
style: {
|
|
8726
8814
|
padding: "2px 5px",
|
|
8727
8815
|
border: "none",
|
|
@@ -8735,23 +8823,25 @@ var ResponsiveSliderField = ({
|
|
|
8735
8823
|
transition: "all 0.1s ease"
|
|
8736
8824
|
},
|
|
8737
8825
|
title: "Mobile",
|
|
8826
|
+
"aria-label": "Mobile viewport",
|
|
8827
|
+
"aria-pressed": mode === "mobile",
|
|
8738
8828
|
children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(MobileIcon, {})
|
|
8739
8829
|
}
|
|
8740
8830
|
)
|
|
8741
|
-
] })
|
|
8742
|
-
|
|
8743
|
-
|
|
8744
|
-
|
|
8745
|
-
|
|
8746
|
-
|
|
8747
|
-
|
|
8748
|
-
|
|
8749
|
-
|
|
8750
|
-
|
|
8751
|
-
|
|
8752
|
-
|
|
8753
|
-
}
|
|
8754
|
-
)
|
|
8831
|
+
] }),
|
|
8832
|
+
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)("div", { style: { flex: 1 }, children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
|
|
8833
|
+
SliderField,
|
|
8834
|
+
{
|
|
8835
|
+
value: getCurrentValue(),
|
|
8836
|
+
onChange: handleChange,
|
|
8837
|
+
unit,
|
|
8838
|
+
max,
|
|
8839
|
+
min,
|
|
8840
|
+
step,
|
|
8841
|
+
useUnits: false
|
|
8842
|
+
}
|
|
8843
|
+
) })
|
|
8844
|
+
] })
|
|
8755
8845
|
] });
|
|
8756
8846
|
};
|
|
8757
8847
|
|
|
@@ -8827,30 +8917,30 @@ init_Button2();
|
|
|
8827
8917
|
// components/Drawer/index.tsx
|
|
8828
8918
|
init_react_import();
|
|
8829
8919
|
|
|
8830
|
-
// css-module:/home/
|
|
8920
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/Drawer/styles.module.css#css-module
|
|
8831
8921
|
init_react_import();
|
|
8832
8922
|
var styles_module_default14 = { "Drawer": "_Drawer_1bd7y_1", "Drawer-draggable": "_Drawer-draggable_1bd7y_7", "Drawer-draggableBg": "_Drawer-draggableBg_1bd7y_11", "DrawerItem-draggable": "_DrawerItem-draggable_1bd7y_21", "DrawerItem--disabled": "_DrawerItem--disabled_1bd7y_34", "DrawerItem": "_DrawerItem_1bd7y_21", "Drawer--isDraggingFrom": "_Drawer--isDraggingFrom_1bd7y_43", "DrawerItem-default": "_DrawerItem-default_1bd7y_44", "DrawerItem-name": "_DrawerItem-name_1bd7y_61" };
|
|
8833
8923
|
|
|
8834
8924
|
// components/Drawer/index.tsx
|
|
8835
8925
|
init_get_class_name_factory();
|
|
8836
8926
|
init_DragIcon();
|
|
8837
|
-
var
|
|
8927
|
+
var import_react54 = require("react");
|
|
8838
8928
|
init_generate_id();
|
|
8839
8929
|
|
|
8840
8930
|
// components/DragDropContext/context.tsx
|
|
8841
8931
|
init_react_import();
|
|
8842
|
-
var
|
|
8843
|
-
var dragListenerContext = (0,
|
|
8932
|
+
var import_react53 = require("react");
|
|
8933
|
+
var dragListenerContext = (0, import_react53.createContext)({
|
|
8844
8934
|
dragListeners: {}
|
|
8845
8935
|
});
|
|
8846
8936
|
function useDragListener(type, fn, deps = []) {
|
|
8847
|
-
const { setDragListeners } = (0,
|
|
8848
|
-
const id = (0,
|
|
8849
|
-
const fnRef = (0,
|
|
8850
|
-
(0,
|
|
8937
|
+
const { setDragListeners } = (0, import_react53.useContext)(dragListenerContext);
|
|
8938
|
+
const id = (0, import_react53.useId)();
|
|
8939
|
+
const fnRef = (0, import_react53.useRef)(fn);
|
|
8940
|
+
(0, import_react53.useEffect)(() => {
|
|
8851
8941
|
fnRef.current = fn;
|
|
8852
8942
|
}, [fn]);
|
|
8853
|
-
(0,
|
|
8943
|
+
(0, import_react53.useEffect)(() => {
|
|
8854
8944
|
if (setDragListeners) {
|
|
8855
8945
|
const wrappedFn = ((...args) => {
|
|
8856
8946
|
return fnRef.current(...args);
|
|
@@ -8871,7 +8961,7 @@ function useDragListener(type, fn, deps = []) {
|
|
|
8871
8961
|
|
|
8872
8962
|
// components/Drawer/index.tsx
|
|
8873
8963
|
init_use_safe_id();
|
|
8874
|
-
var
|
|
8964
|
+
var import_react55 = require("@dnd-kit/react");
|
|
8875
8965
|
var import_jsx_runtime59 = require("react/jsx-runtime");
|
|
8876
8966
|
var getClassName21 = get_class_name_factory_default("Drawer", styles_module_default14);
|
|
8877
8967
|
var getClassNameItem2 = get_class_name_factory_default("DrawerItem", styles_module_default14);
|
|
@@ -8882,7 +8972,7 @@ var DrawerItemInner = ({
|
|
|
8882
8972
|
dragRef,
|
|
8883
8973
|
isDragDisabled
|
|
8884
8974
|
}) => {
|
|
8885
|
-
const CustomInner = (0,
|
|
8975
|
+
const CustomInner = (0, import_react54.useMemo)(
|
|
8886
8976
|
() => children || (({ children: children2 }) => /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: getClassNameItem2("default"), children: children2 })),
|
|
8887
8977
|
[children]
|
|
8888
8978
|
);
|
|
@@ -8908,7 +8998,7 @@ var DrawerItemDraggable = ({
|
|
|
8908
8998
|
id,
|
|
8909
8999
|
isDragDisabled
|
|
8910
9000
|
}) => {
|
|
8911
|
-
const { ref } = (0,
|
|
9001
|
+
const { ref } = (0, import_react55.useDraggable)({
|
|
8912
9002
|
id,
|
|
8913
9003
|
data: { componentType: name },
|
|
8914
9004
|
disabled: isDragDisabled,
|
|
@@ -8937,7 +9027,7 @@ var DrawerItem = ({
|
|
|
8937
9027
|
isDragDisabled
|
|
8938
9028
|
}) => {
|
|
8939
9029
|
const resolvedId = id || name;
|
|
8940
|
-
const [dynamicId, setDynamicId] = (0,
|
|
9030
|
+
const [dynamicId, setDynamicId] = (0, import_react54.useState)(generateId(resolvedId));
|
|
8941
9031
|
if (typeof index !== "undefined") {
|
|
8942
9032
|
console.error(
|
|
8943
9033
|
"Warning: The `index` prop on Drawer.Item is deprecated and no longer required."
|
|
@@ -8977,7 +9067,7 @@ var Drawer = ({
|
|
|
8977
9067
|
);
|
|
8978
9068
|
}
|
|
8979
9069
|
const id = useSafeId();
|
|
8980
|
-
const { ref } = (0,
|
|
9070
|
+
const { ref } = (0, import_react55.useDroppable)({
|
|
8981
9071
|
id,
|
|
8982
9072
|
type: "void",
|
|
8983
9073
|
collisionPriority: 0
|
|
@@ -8999,13 +9089,14 @@ Drawer.Item = DrawerItem;
|
|
|
8999
9089
|
|
|
9000
9090
|
// components/DropZone/index.tsx
|
|
9001
9091
|
init_react_import();
|
|
9002
|
-
var
|
|
9092
|
+
var import_react74 = require("react");
|
|
9093
|
+
var import_isomorphic_dompurify4 = __toESM(require("isomorphic-dompurify"));
|
|
9003
9094
|
|
|
9004
9095
|
// components/DraggableComponent/index.tsx
|
|
9005
9096
|
init_react_import();
|
|
9006
|
-
var
|
|
9097
|
+
var import_react58 = require("react");
|
|
9007
9098
|
|
|
9008
|
-
// css-module:/home/
|
|
9099
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/DraggableComponent/styles.module.css#css-module
|
|
9009
9100
|
init_react_import();
|
|
9010
9101
|
var styles_module_default15 = { "DraggableComponent": "_DraggableComponent_yrtpz_1", "DraggableComponent-overlayWrapper": "_DraggableComponent-overlayWrapper_yrtpz_12", "DraggableComponent-overlay": "_DraggableComponent-overlay_yrtpz_12", "DraggableComponent-loadingOverlay": "_DraggableComponent-loadingOverlay_yrtpz_34", "DraggableComponent--hover": "_DraggableComponent--hover_yrtpz_50", "DraggableComponent--isSelected": "_DraggableComponent--isSelected_yrtpz_57", "DraggableComponent-actionsOverlay": "_DraggableComponent-actionsOverlay_yrtpz_71", "DraggableComponent-actions": "_DraggableComponent-actions_yrtpz_71" };
|
|
9011
9102
|
|
|
@@ -9019,12 +9110,12 @@ var import_react_dom2 = require("react-dom");
|
|
|
9019
9110
|
|
|
9020
9111
|
// components/DropZone/context.tsx
|
|
9021
9112
|
init_react_import();
|
|
9022
|
-
var
|
|
9113
|
+
var import_react56 = require("react");
|
|
9023
9114
|
init_store2();
|
|
9024
9115
|
var import_zustand5 = require("zustand");
|
|
9025
9116
|
var import_jsx_runtime60 = require("react/jsx-runtime");
|
|
9026
|
-
var dropZoneContext = (0,
|
|
9027
|
-
var ZoneStoreContext = (0,
|
|
9117
|
+
var dropZoneContext = (0, import_react56.createContext)(null);
|
|
9118
|
+
var ZoneStoreContext = (0, import_react56.createContext)(
|
|
9028
9119
|
(0, import_zustand5.createStore)(() => ({
|
|
9029
9120
|
zoneDepthIndex: {},
|
|
9030
9121
|
nextZoneDepthIndex: {},
|
|
@@ -9052,7 +9143,7 @@ var DropZoneProvider = ({
|
|
|
9052
9143
|
value
|
|
9053
9144
|
}) => {
|
|
9054
9145
|
const dispatch = useAppStore((s) => s.dispatch);
|
|
9055
|
-
const registerZone = (0,
|
|
9146
|
+
const registerZone = (0, import_react56.useCallback)(
|
|
9056
9147
|
(zoneCompound) => {
|
|
9057
9148
|
dispatch({
|
|
9058
9149
|
type: "registerZone",
|
|
@@ -9061,7 +9152,7 @@ var DropZoneProvider = ({
|
|
|
9061
9152
|
},
|
|
9062
9153
|
[dispatch]
|
|
9063
9154
|
);
|
|
9064
|
-
const memoValue = (0,
|
|
9155
|
+
const memoValue = (0, import_react56.useMemo)(
|
|
9065
9156
|
() => ({
|
|
9066
9157
|
registerZone,
|
|
9067
9158
|
...value
|
|
@@ -9101,11 +9192,11 @@ init_use_context_store();
|
|
|
9101
9192
|
|
|
9102
9193
|
// lib/dnd/use-on-drag-finished.ts
|
|
9103
9194
|
init_react_import();
|
|
9104
|
-
var
|
|
9195
|
+
var import_react57 = require("react");
|
|
9105
9196
|
init_store2();
|
|
9106
9197
|
var useOnDragFinished = (cb, _deps = []) => {
|
|
9107
9198
|
const appStore = useAppStoreApi();
|
|
9108
|
-
return (0,
|
|
9199
|
+
return (0, import_react57.useCallback)(() => {
|
|
9109
9200
|
let dispose = () => {
|
|
9110
9201
|
};
|
|
9111
9202
|
const processDragging = (isDragging2) => {
|
|
@@ -9197,11 +9288,11 @@ var DraggableComponent = ({
|
|
|
9197
9288
|
);
|
|
9198
9289
|
const overrides = useAppStore((s) => s.overrides);
|
|
9199
9290
|
const dispatch = useAppStore((s) => s.dispatch);
|
|
9200
|
-
const
|
|
9201
|
-
const lastMeasureRef = (0,
|
|
9202
|
-
const ctx = (0,
|
|
9203
|
-
const [localZones, setLocalZones] = (0,
|
|
9204
|
-
const registerLocalZone = (0,
|
|
9291
|
+
const isIframeEnabled = useAppStore((s) => s.iframe.enabled);
|
|
9292
|
+
const lastMeasureRef = (0, import_react58.useRef)(0);
|
|
9293
|
+
const ctx = (0, import_react58.useContext)(dropZoneContext);
|
|
9294
|
+
const [localZones, setLocalZones] = (0, import_react58.useState)({});
|
|
9295
|
+
const registerLocalZone = (0, import_react58.useCallback)(
|
|
9205
9296
|
(zoneCompound2, active) => {
|
|
9206
9297
|
ctx?.registerLocalZone?.(zoneCompound2, active);
|
|
9207
9298
|
setLocalZones((obj) => ({
|
|
@@ -9211,7 +9302,7 @@ var DraggableComponent = ({
|
|
|
9211
9302
|
},
|
|
9212
9303
|
[setLocalZones, ctx]
|
|
9213
9304
|
);
|
|
9214
|
-
const unregisterLocalZone = (0,
|
|
9305
|
+
const unregisterLocalZone = (0, import_react58.useCallback)(
|
|
9215
9306
|
(zoneCompound2) => {
|
|
9216
9307
|
ctx?.unregisterLocalZone?.(zoneCompound2);
|
|
9217
9308
|
setLocalZones((obj) => {
|
|
@@ -9232,9 +9323,9 @@ var DraggableComponent = ({
|
|
|
9232
9323
|
return s.permissions.getPermissions({ item });
|
|
9233
9324
|
})
|
|
9234
9325
|
);
|
|
9235
|
-
const zoneStore = (0,
|
|
9236
|
-
const [dragAxis, setDragAxis] = (0,
|
|
9237
|
-
const dynamicCollisionDetector = (0,
|
|
9326
|
+
const zoneStore = (0, import_react58.useContext)(ZoneStoreContext);
|
|
9327
|
+
const [dragAxis, setDragAxis] = (0, import_react58.useState)(userDragAxis || autoDragAxis);
|
|
9328
|
+
const dynamicCollisionDetector = (0, import_react58.useMemo)(
|
|
9238
9329
|
() => createDynamicCollisionDetector(dragAxis),
|
|
9239
9330
|
[dragAxis]
|
|
9240
9331
|
);
|
|
@@ -9266,7 +9357,7 @@ var DraggableComponent = ({
|
|
|
9266
9357
|
},
|
|
9267
9358
|
feedback: "clone"
|
|
9268
9359
|
});
|
|
9269
|
-
(0,
|
|
9360
|
+
(0, import_react58.useEffect)(() => {
|
|
9270
9361
|
const isEnabled = zoneStore.getState().enabledIndex[zoneCompound];
|
|
9271
9362
|
sortable.droppable.disabled = !isEnabled;
|
|
9272
9363
|
sortable.draggable.disabled = !permissions.drag;
|
|
@@ -9282,9 +9373,9 @@ var DraggableComponent = ({
|
|
|
9282
9373
|
}
|
|
9283
9374
|
return cleanup;
|
|
9284
9375
|
}, [permissions.drag, zoneCompound, sortable.draggable, sortable.droppable, zoneStore]);
|
|
9285
|
-
const [, setRerender] = (0,
|
|
9286
|
-
const ref = (0,
|
|
9287
|
-
const refSetter = (0,
|
|
9376
|
+
const [, setRerender] = (0, import_react58.useState)(0);
|
|
9377
|
+
const ref = (0, import_react58.useRef)(null);
|
|
9378
|
+
const refSetter = (0, import_react58.useCallback)(
|
|
9288
9379
|
(el) => {
|
|
9289
9380
|
sortableRef(el);
|
|
9290
9381
|
if (ref.current !== el) {
|
|
@@ -9297,17 +9388,17 @@ var DraggableComponent = ({
|
|
|
9297
9388
|
},
|
|
9298
9389
|
[itemRef, sortableRef]
|
|
9299
9390
|
);
|
|
9300
|
-
const [portalEl, setPortalEl] = (0,
|
|
9301
|
-
(0,
|
|
9391
|
+
const [portalEl, setPortalEl] = (0, import_react58.useState)();
|
|
9392
|
+
(0, import_react58.useEffect)(() => {
|
|
9302
9393
|
setPortalEl(
|
|
9303
|
-
|
|
9394
|
+
isIframeEnabled ? ref.current?.ownerDocument.body : ref.current?.closest("[data-credbuild-preview]") ?? document.body
|
|
9304
9395
|
);
|
|
9305
|
-
}, [
|
|
9306
|
-
const getStyle = (0,
|
|
9396
|
+
}, [isIframeEnabled]);
|
|
9397
|
+
const getStyle = (0, import_react58.useCallback)(() => {
|
|
9307
9398
|
if (!ref.current) return;
|
|
9308
9399
|
const el = ref.current;
|
|
9309
9400
|
const rect = el.getBoundingClientRect();
|
|
9310
|
-
const portalContainerEl =
|
|
9401
|
+
const portalContainerEl = isIframeEnabled ? null : el.closest("[data-credbuild-preview]");
|
|
9311
9402
|
const targetIsFixed = (() => {
|
|
9312
9403
|
let node = el;
|
|
9313
9404
|
while (node && node !== document.documentElement) {
|
|
@@ -9333,24 +9424,24 @@ var DraggableComponent = ({
|
|
|
9333
9424
|
position: targetIsFixed ? "fixed" : void 0
|
|
9334
9425
|
};
|
|
9335
9426
|
return style2;
|
|
9336
|
-
}, [
|
|
9337
|
-
const [style, setStyle] = (0,
|
|
9338
|
-
const lastRectRef = (0,
|
|
9339
|
-
const syncRafRef = (0,
|
|
9340
|
-
const sync = (0,
|
|
9427
|
+
}, [isIframeEnabled]);
|
|
9428
|
+
const [style, setStyle] = (0, import_react58.useState)();
|
|
9429
|
+
const lastRectRef = (0, import_react58.useRef)(null);
|
|
9430
|
+
const syncRafRef = (0, import_react58.useRef)(null);
|
|
9431
|
+
const sync = (0, import_react58.useCallback)(() => {
|
|
9341
9432
|
setStyle(getStyle());
|
|
9342
9433
|
if (itemRef) {
|
|
9343
9434
|
assignRefs([itemRef], ref.current);
|
|
9344
9435
|
}
|
|
9345
9436
|
}, [getStyle, itemRef]);
|
|
9346
|
-
const scheduleSync = (0,
|
|
9437
|
+
const scheduleSync = (0, import_react58.useCallback)(() => {
|
|
9347
9438
|
if (syncRafRef.current != null) return;
|
|
9348
9439
|
syncRafRef.current = requestAnimationFrame(() => {
|
|
9349
9440
|
syncRafRef.current = null;
|
|
9350
9441
|
sync();
|
|
9351
9442
|
});
|
|
9352
9443
|
}, [sync]);
|
|
9353
|
-
(0,
|
|
9444
|
+
(0, import_react58.useEffect)(() => {
|
|
9354
9445
|
return () => {
|
|
9355
9446
|
if (syncRafRef.current != null) {
|
|
9356
9447
|
cancelAnimationFrame(syncRafRef.current);
|
|
@@ -9358,7 +9449,7 @@ var DraggableComponent = ({
|
|
|
9358
9449
|
}
|
|
9359
9450
|
};
|
|
9360
9451
|
}, []);
|
|
9361
|
-
(0,
|
|
9452
|
+
(0, import_react58.useEffect)(() => {
|
|
9362
9453
|
if (ref.current) {
|
|
9363
9454
|
const observer = new ResizeObserver(() => {
|
|
9364
9455
|
scheduleSync();
|
|
@@ -9371,37 +9462,37 @@ var DraggableComponent = ({
|
|
|
9371
9462
|
}, [scheduleSync, itemRef]);
|
|
9372
9463
|
const registerNode = useAppStore((s) => s.nodes.registerNode);
|
|
9373
9464
|
const unregisterNode = useAppStore((s) => s.nodes.unregisterNode);
|
|
9374
|
-
const hideOverlay = (0,
|
|
9465
|
+
const hideOverlay = (0, import_react58.useCallback)(() => {
|
|
9375
9466
|
setIsVisible(false);
|
|
9376
9467
|
}, []);
|
|
9377
|
-
const showOverlay = (0,
|
|
9468
|
+
const showOverlay = (0, import_react58.useCallback)(() => {
|
|
9378
9469
|
setIsVisible(true);
|
|
9379
9470
|
}, []);
|
|
9380
|
-
const nodeHandleRef = (0,
|
|
9471
|
+
const nodeHandleRef = (0, import_react58.useRef)({
|
|
9381
9472
|
sync: () => null,
|
|
9382
9473
|
hideOverlay: () => null,
|
|
9383
9474
|
showOverlay: () => null
|
|
9384
9475
|
});
|
|
9385
|
-
(0,
|
|
9476
|
+
(0, import_react58.useLayoutEffect)(() => {
|
|
9386
9477
|
nodeHandleRef.current.sync = sync;
|
|
9387
9478
|
nodeHandleRef.current.hideOverlay = hideOverlay;
|
|
9388
9479
|
nodeHandleRef.current.showOverlay = showOverlay;
|
|
9389
9480
|
}, [hideOverlay, showOverlay, sync]);
|
|
9390
|
-
(0,
|
|
9481
|
+
(0, import_react58.useEffect)(() => {
|
|
9391
9482
|
registerNode(id, nodeHandleRef.current);
|
|
9392
9483
|
return () => {
|
|
9393
9484
|
unregisterNode(id);
|
|
9394
9485
|
};
|
|
9395
9486
|
}, [id, registerNode, unregisterNode]);
|
|
9396
|
-
const CustomActionBar = (0,
|
|
9487
|
+
const CustomActionBar = (0, import_react58.useMemo)(
|
|
9397
9488
|
() => overrides.actionBar || DefaultActionBar,
|
|
9398
9489
|
[overrides.actionBar]
|
|
9399
9490
|
);
|
|
9400
|
-
const CustomOverlay = (0,
|
|
9491
|
+
const CustomOverlay = (0, import_react58.useMemo)(
|
|
9401
9492
|
() => overrides.componentOverlay || DefaultOverlay,
|
|
9402
9493
|
[overrides.componentOverlay]
|
|
9403
9494
|
);
|
|
9404
|
-
const onClick = (0,
|
|
9495
|
+
const onClick = (0, import_react58.useCallback)(
|
|
9405
9496
|
(e) => {
|
|
9406
9497
|
const userIsDragging = !!zoneStore.getState().draggedItem;
|
|
9407
9498
|
if (userIsDragging) {
|
|
@@ -9430,7 +9521,7 @@ var DraggableComponent = ({
|
|
|
9430
9521
|
[index, zoneCompound, isSelected, _experimentalFullScreenCanvas, dispatch, zoneStore]
|
|
9431
9522
|
);
|
|
9432
9523
|
const appStore = useAppStoreApi();
|
|
9433
|
-
const onSelectParent = (0,
|
|
9524
|
+
const onSelectParent = (0, import_react58.useCallback)(() => {
|
|
9434
9525
|
const { nodes, zones } = appStore.getState().state.indexes;
|
|
9435
9526
|
const node = nodes[id];
|
|
9436
9527
|
const parentNode = node?.parentId ? nodes[node?.parentId] : null;
|
|
@@ -9451,26 +9542,26 @@ var DraggableComponent = ({
|
|
|
9451
9542
|
}
|
|
9452
9543
|
});
|
|
9453
9544
|
}, [appStore, dispatch, id]);
|
|
9454
|
-
const onDuplicate = (0,
|
|
9545
|
+
const onDuplicate = (0, import_react58.useCallback)(() => {
|
|
9455
9546
|
dispatch({
|
|
9456
9547
|
type: "duplicate",
|
|
9457
9548
|
sourceIndex: index,
|
|
9458
9549
|
sourceZone: zoneCompound
|
|
9459
9550
|
});
|
|
9460
9551
|
}, [index, zoneCompound, dispatch]);
|
|
9461
|
-
const onDelete = (0,
|
|
9552
|
+
const onDelete = (0, import_react58.useCallback)(() => {
|
|
9462
9553
|
dispatch({
|
|
9463
9554
|
type: "remove",
|
|
9464
9555
|
index,
|
|
9465
9556
|
zone: zoneCompound
|
|
9466
9557
|
});
|
|
9467
9558
|
}, [index, zoneCompound, dispatch]);
|
|
9468
|
-
const [hover, setHover] = (0,
|
|
9559
|
+
const [hover, setHover] = (0, import_react58.useState)(false);
|
|
9469
9560
|
const indicativeHover = useContextStore(
|
|
9470
9561
|
ZoneStoreContext,
|
|
9471
9562
|
(s) => s.hoveringComponent === id
|
|
9472
9563
|
);
|
|
9473
|
-
(0,
|
|
9564
|
+
(0, import_react58.useEffect)(() => {
|
|
9474
9565
|
if (!ref.current) {
|
|
9475
9566
|
return;
|
|
9476
9567
|
}
|
|
@@ -9517,10 +9608,10 @@ var DraggableComponent = ({
|
|
|
9517
9608
|
zoneStore,
|
|
9518
9609
|
id
|
|
9519
9610
|
]);
|
|
9520
|
-
const [isVisible, setIsVisible] = (0,
|
|
9521
|
-
const [dragFinished, setDragFinished] = (0,
|
|
9522
|
-
const [_, startTransition] = (0,
|
|
9523
|
-
(0,
|
|
9611
|
+
const [isVisible, setIsVisible] = (0, import_react58.useState)(false);
|
|
9612
|
+
const [dragFinished, setDragFinished] = (0, import_react58.useState)(true);
|
|
9613
|
+
const [_, startTransition] = (0, import_react58.useTransition)();
|
|
9614
|
+
(0, import_react58.useEffect)(() => {
|
|
9524
9615
|
startTransition(() => {
|
|
9525
9616
|
if (hover || indicativeHover || isSelected) {
|
|
9526
9617
|
scheduleSync();
|
|
@@ -9530,10 +9621,10 @@ var DraggableComponent = ({
|
|
|
9530
9621
|
setIsVisible(false);
|
|
9531
9622
|
}
|
|
9532
9623
|
});
|
|
9533
|
-
}, [hover, indicativeHover, isSelected,
|
|
9534
|
-
const [thisWasDragging, setThisWasDragging] = (0,
|
|
9624
|
+
}, [hover, indicativeHover, isSelected, isIframeEnabled, scheduleSync]);
|
|
9625
|
+
const [thisWasDragging, setThisWasDragging] = (0, import_react58.useState)(false);
|
|
9535
9626
|
const onDragFinished = useOnDragFinished(
|
|
9536
|
-
(0,
|
|
9627
|
+
(0, import_react58.useCallback)(
|
|
9537
9628
|
(finished) => {
|
|
9538
9629
|
if (finished) {
|
|
9539
9630
|
startTransition(() => {
|
|
@@ -9547,15 +9638,15 @@ var DraggableComponent = ({
|
|
|
9547
9638
|
[sync, startTransition]
|
|
9548
9639
|
)
|
|
9549
9640
|
);
|
|
9550
|
-
(0,
|
|
9641
|
+
(0, import_react58.useEffect)(() => {
|
|
9551
9642
|
if (thisIsDragging) {
|
|
9552
9643
|
setThisWasDragging(true);
|
|
9553
9644
|
}
|
|
9554
9645
|
}, [thisIsDragging]);
|
|
9555
|
-
(0,
|
|
9646
|
+
(0, import_react58.useEffect)(() => {
|
|
9556
9647
|
if (thisWasDragging) return onDragFinished();
|
|
9557
9648
|
}, [thisWasDragging, onDragFinished]);
|
|
9558
|
-
(0,
|
|
9649
|
+
(0, import_react58.useEffect)(() => {
|
|
9559
9650
|
if (!dragFinished || !(isSelected || thisIsDragging)) return;
|
|
9560
9651
|
const el = ref.current;
|
|
9561
9652
|
if (!el) return;
|
|
@@ -9592,7 +9683,7 @@ var DraggableComponent = ({
|
|
|
9592
9683
|
cancelAnimationFrame(frame);
|
|
9593
9684
|
};
|
|
9594
9685
|
}, [dragFinished, isSelected, thisIsDragging, scheduleSync]);
|
|
9595
|
-
const syncActionsPosition = (0,
|
|
9686
|
+
const syncActionsPosition = (0, import_react58.useCallback)(
|
|
9596
9687
|
(el) => {
|
|
9597
9688
|
if (el) {
|
|
9598
9689
|
const view = el.ownerDocument.defaultView;
|
|
@@ -9617,7 +9708,7 @@ var DraggableComponent = ({
|
|
|
9617
9708
|
},
|
|
9618
9709
|
[]
|
|
9619
9710
|
);
|
|
9620
|
-
(0,
|
|
9711
|
+
(0, import_react58.useEffect)(() => {
|
|
9621
9712
|
if (userDragAxis) {
|
|
9622
9713
|
setDragAxis(userDragAxis);
|
|
9623
9714
|
return;
|
|
@@ -9631,11 +9722,11 @@ var DraggableComponent = ({
|
|
|
9631
9722
|
}
|
|
9632
9723
|
setDragAxis(autoDragAxis);
|
|
9633
9724
|
}, [ref, userDragAxis, autoDragAxis]);
|
|
9634
|
-
const parentAction = (0,
|
|
9725
|
+
const parentAction = (0, import_react58.useMemo)(
|
|
9635
9726
|
() => ctx?.areaId && ctx?.areaId !== "root" && /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(ActionBar.Action, { onClick: onSelectParent, label: "Select parent", children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(CornerLeftUp, { size: 16 }) }),
|
|
9636
9727
|
[ctx?.areaId, onSelectParent]
|
|
9637
9728
|
);
|
|
9638
|
-
const nextContextValue = (0,
|
|
9729
|
+
const nextContextValue = (0, import_react58.useMemo)(
|
|
9639
9730
|
() => ({
|
|
9640
9731
|
...ctx,
|
|
9641
9732
|
areaId: id,
|
|
@@ -9744,18 +9835,18 @@ init_setup_zone();
|
|
|
9744
9835
|
init_root_droppable_id();
|
|
9745
9836
|
init_lib();
|
|
9746
9837
|
|
|
9747
|
-
// css-module:/home/
|
|
9838
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/DropZone/styles.module.css#css-module
|
|
9748
9839
|
init_react_import();
|
|
9749
9840
|
var styles_module_default16 = { "DropZone": "_DropZone_1vmgt_1", "DropZone--hasChildren": "_DropZone--hasChildren_1vmgt_11", "DropZone--isAreaSelected": "_DropZone--isAreaSelected_1vmgt_24", "DropZone--hoveringOverArea": "_DropZone--hoveringOverArea_1vmgt_25", "DropZone--isRootZone": "_DropZone--isRootZone_1vmgt_25", "DropZone--isDestination": "_DropZone--isDestination_1vmgt_35", "DropZone-item": "_DropZone-item_1vmgt_47", "DropZone-hitbox": "_DropZone-hitbox_1vmgt_51", "DropZone--isEnabled": "_DropZone--isEnabled_1vmgt_59", "DropZone--isAnimating": "_DropZone--isAnimating_1vmgt_68" };
|
|
9750
9841
|
|
|
9751
9842
|
// components/DropZone/index.tsx
|
|
9752
9843
|
init_store2();
|
|
9753
|
-
var
|
|
9844
|
+
var import_react75 = require("@dnd-kit/react");
|
|
9754
9845
|
var import_collision2 = require("@dnd-kit/collision");
|
|
9755
9846
|
|
|
9756
9847
|
// components/DropZone/lib/use-min-empty-height.ts
|
|
9757
9848
|
init_react_import();
|
|
9758
|
-
var
|
|
9849
|
+
var import_react59 = require("react");
|
|
9759
9850
|
init_use_context_store();
|
|
9760
9851
|
init_store2();
|
|
9761
9852
|
var getNumItems = (appStore, zoneCompound) => appStore.getState().state.indexes.zones[zoneCompound].contentIds.length;
|
|
@@ -9765,17 +9856,17 @@ var useMinEmptyHeight = ({
|
|
|
9765
9856
|
ref
|
|
9766
9857
|
}) => {
|
|
9767
9858
|
const appStore = useAppStoreApi();
|
|
9768
|
-
const [prevHeight, setPrevHeight] = (0,
|
|
9769
|
-
const [isAnimating, setIsAnimating] = (0,
|
|
9859
|
+
const [prevHeight, setPrevHeight] = (0, import_react59.useState)(0);
|
|
9860
|
+
const [isAnimating, setIsAnimating] = (0, import_react59.useState)(false);
|
|
9770
9861
|
const { draggedItem, isZone } = useContextStore(ZoneStoreContext, (s) => {
|
|
9771
9862
|
return {
|
|
9772
9863
|
draggedItem: s.draggedItem?.data.zone === zoneCompound ? s.draggedItem : null,
|
|
9773
9864
|
isZone: s.draggedItem?.data.zone === zoneCompound
|
|
9774
9865
|
};
|
|
9775
9866
|
});
|
|
9776
|
-
const numItems = (0,
|
|
9867
|
+
const numItems = (0, import_react59.useRef)(0);
|
|
9777
9868
|
const onDragFinished = useOnDragFinished(
|
|
9778
|
-
(0,
|
|
9869
|
+
(0, import_react59.useCallback)(
|
|
9779
9870
|
(finished) => {
|
|
9780
9871
|
if (finished) {
|
|
9781
9872
|
const newNumItems = getNumItems(appStore, zoneCompound);
|
|
@@ -9804,7 +9895,7 @@ var useMinEmptyHeight = ({
|
|
|
9804
9895
|
[appStore, zoneCompound]
|
|
9805
9896
|
)
|
|
9806
9897
|
);
|
|
9807
|
-
(0,
|
|
9898
|
+
(0, import_react59.useEffect)(() => {
|
|
9808
9899
|
if (draggedItem && ref.current) {
|
|
9809
9900
|
if (isZone) {
|
|
9810
9901
|
const rect = ref.current.getBoundingClientRect();
|
|
@@ -9821,15 +9912,15 @@ var useMinEmptyHeight = ({
|
|
|
9821
9912
|
|
|
9822
9913
|
// components/DropZone/lib/use-content-with-preview.ts
|
|
9823
9914
|
init_react_import();
|
|
9824
|
-
var
|
|
9915
|
+
var import_react62 = require("react");
|
|
9825
9916
|
|
|
9826
9917
|
// lib/dnd/use-rendered-callback.ts
|
|
9827
9918
|
init_react_import();
|
|
9828
|
-
var
|
|
9829
|
-
var
|
|
9919
|
+
var import_react60 = require("@dnd-kit/react");
|
|
9920
|
+
var import_react61 = require("react");
|
|
9830
9921
|
function useRenderedCallback(callback, _deps = []) {
|
|
9831
|
-
const manager = (0,
|
|
9832
|
-
return (0,
|
|
9922
|
+
const manager = (0, import_react60.useDragDropManager)();
|
|
9923
|
+
return (0, import_react61.useCallback)(
|
|
9833
9924
|
async (...args) => {
|
|
9834
9925
|
await manager?.renderer.rendering;
|
|
9835
9926
|
return callback(...args);
|
|
@@ -9843,18 +9934,18 @@ init_insert();
|
|
|
9843
9934
|
init_use_context_store();
|
|
9844
9935
|
init_store2();
|
|
9845
9936
|
var useContentIdsWithPreview = (contentIds, zoneCompound) => {
|
|
9846
|
-
const zoneStore = (0,
|
|
9937
|
+
const zoneStore = (0, import_react62.useContext)(ZoneStoreContext);
|
|
9847
9938
|
const preview = useContextStore(
|
|
9848
9939
|
ZoneStoreContext,
|
|
9849
9940
|
(s) => s.previewIndex[zoneCompound]
|
|
9850
9941
|
);
|
|
9851
9942
|
const isDragging = useAppStore((s) => s.state.ui.isDragging);
|
|
9852
|
-
const [contentIdsWithPreview, setContentIdsWithPreview] = (0,
|
|
9853
|
-
const [localPreview, setLocalPreview] = (0,
|
|
9943
|
+
const [contentIdsWithPreview, setContentIdsWithPreview] = (0, import_react62.useState)(contentIds);
|
|
9944
|
+
const [localPreview, setLocalPreview] = (0, import_react62.useState)(
|
|
9854
9945
|
preview
|
|
9855
9946
|
);
|
|
9856
9947
|
const updateContent = useRenderedCallback(
|
|
9857
|
-
(0,
|
|
9948
|
+
(0, import_react62.useCallback)(
|
|
9858
9949
|
(contentIds2, preview2, isDragging2, draggedItemId, previewExists) => {
|
|
9859
9950
|
if (isDragging2 && !previewExists) {
|
|
9860
9951
|
return;
|
|
@@ -9887,7 +9978,7 @@ var useContentIdsWithPreview = (contentIds, zoneCompound) => {
|
|
|
9887
9978
|
[]
|
|
9888
9979
|
)
|
|
9889
9980
|
);
|
|
9890
|
-
(0,
|
|
9981
|
+
(0, import_react62.useEffect)(() => {
|
|
9891
9982
|
const s = zoneStore.getState();
|
|
9892
9983
|
const draggedItemId = s.draggedItem?.id;
|
|
9893
9984
|
const previewExists = Object.keys(s.previewIndex || {}).length > 0;
|
|
@@ -9904,17 +9995,17 @@ var useContentIdsWithPreview = (contentIds, zoneCompound) => {
|
|
|
9904
9995
|
|
|
9905
9996
|
// components/DropZone/lib/use-drag-axis.ts
|
|
9906
9997
|
init_react_import();
|
|
9907
|
-
var
|
|
9998
|
+
var import_react63 = require("react");
|
|
9908
9999
|
init_store2();
|
|
9909
10000
|
var GRID_DRAG_AXIS = "dynamic";
|
|
9910
10001
|
var FLEX_ROW_DRAG_AXIS = "x";
|
|
9911
10002
|
var DEFAULT_DRAG_AXIS = "y";
|
|
9912
10003
|
var useDragAxis = (ref, collisionAxis) => {
|
|
9913
10004
|
const status = useAppStore((s) => s.status);
|
|
9914
|
-
const [dragAxis, setDragAxis] = (0,
|
|
10005
|
+
const [dragAxis, setDragAxis] = (0, import_react63.useState)(
|
|
9915
10006
|
collisionAxis || DEFAULT_DRAG_AXIS
|
|
9916
10007
|
);
|
|
9917
|
-
const calculateDragAxis = (0,
|
|
10008
|
+
const calculateDragAxis = (0, import_react63.useCallback)(() => {
|
|
9918
10009
|
if (ref.current) {
|
|
9919
10010
|
const computedStyle = window.getComputedStyle(ref.current);
|
|
9920
10011
|
if (computedStyle.display === "grid") {
|
|
@@ -9926,7 +10017,7 @@ var useDragAxis = (ref, collisionAxis) => {
|
|
|
9926
10017
|
}
|
|
9927
10018
|
}
|
|
9928
10019
|
}, [ref]);
|
|
9929
|
-
(0,
|
|
10020
|
+
(0, import_react63.useEffect)(() => {
|
|
9930
10021
|
const onViewportChange = () => {
|
|
9931
10022
|
calculateDragAxis();
|
|
9932
10023
|
};
|
|
@@ -9935,7 +10026,7 @@ var useDragAxis = (ref, collisionAxis) => {
|
|
|
9935
10026
|
window.removeEventListener("viewportchange", onViewportChange);
|
|
9936
10027
|
};
|
|
9937
10028
|
}, [calculateDragAxis]);
|
|
9938
|
-
(0,
|
|
10029
|
+
(0, import_react63.useEffect)(calculateDragAxis, [status, collisionAxis, calculateDragAxis]);
|
|
9939
10030
|
return [dragAxis, calculateDragAxis];
|
|
9940
10031
|
};
|
|
9941
10032
|
|
|
@@ -9945,8 +10036,8 @@ var import_shallow6 = require("zustand/react/shallow");
|
|
|
9945
10036
|
|
|
9946
10037
|
// components/Render/context.tsx
|
|
9947
10038
|
init_react_import();
|
|
9948
|
-
var
|
|
9949
|
-
var renderContext =
|
|
10039
|
+
var import_react64 = __toESM(require("react"));
|
|
10040
|
+
var renderContext = import_react64.default.createContext({
|
|
9950
10041
|
config: { components: {} },
|
|
9951
10042
|
data: { root: {}, content: [] },
|
|
9952
10043
|
metadata: {}
|
|
@@ -9957,7 +10048,7 @@ init_react_import();
|
|
|
9957
10048
|
|
|
9958
10049
|
// lib/field-transforms/use-field-transforms.tsx
|
|
9959
10050
|
init_react_import();
|
|
9960
|
-
var
|
|
10051
|
+
var import_react65 = require("react");
|
|
9961
10052
|
init_map_fields();
|
|
9962
10053
|
|
|
9963
10054
|
// lib/field-transforms/build-mappers.ts
|
|
@@ -9986,14 +10077,14 @@ function buildMappers(transforms, readOnly, forceReadOnly) {
|
|
|
9986
10077
|
|
|
9987
10078
|
// lib/field-transforms/use-field-transforms.tsx
|
|
9988
10079
|
function useFieldTransforms(config, item, transforms, readOnly, forceReadOnly) {
|
|
9989
|
-
const mappers = (0,
|
|
10080
|
+
const mappers = (0, import_react65.useMemo)(
|
|
9990
10081
|
() => buildMappers(transforms, readOnly, forceReadOnly),
|
|
9991
10082
|
[transforms, readOnly, forceReadOnly]
|
|
9992
10083
|
);
|
|
9993
|
-
const transformedProps = (0,
|
|
10084
|
+
const transformedProps = (0, import_react65.useMemo)(() => {
|
|
9994
10085
|
return mapFields(item, mappers, config).props;
|
|
9995
10086
|
}, [config, item, mappers]);
|
|
9996
|
-
const mergedProps = (0,
|
|
10087
|
+
const mergedProps = (0, import_react65.useMemo)(
|
|
9997
10088
|
() => ({ ...item.props, ...transformedProps }),
|
|
9998
10089
|
[item.props, transformedProps]
|
|
9999
10090
|
);
|
|
@@ -10034,14 +10125,15 @@ init_store2();
|
|
|
10034
10125
|
|
|
10035
10126
|
// components/SlotRender/server.tsx
|
|
10036
10127
|
init_react_import();
|
|
10037
|
-
var
|
|
10128
|
+
var import_react68 = require("react");
|
|
10038
10129
|
|
|
10039
10130
|
// components/RichTextEditor/lib/use-richtext-props.tsx
|
|
10040
10131
|
init_react_import();
|
|
10041
|
-
var
|
|
10132
|
+
var import_react67 = require("react");
|
|
10042
10133
|
|
|
10043
10134
|
// components/RichTextEditor/components/RenderFallback.tsx
|
|
10044
10135
|
init_react_import();
|
|
10136
|
+
var import_isomorphic_dompurify2 = __toESM(require("isomorphic-dompurify"));
|
|
10045
10137
|
init_get_class_name_factory();
|
|
10046
10138
|
init_styles_module10();
|
|
10047
10139
|
var import_jsx_runtime62 = require("react/jsx-runtime");
|
|
@@ -10051,7 +10143,7 @@ function RichTextRenderFallback({ content }) {
|
|
|
10051
10143
|
"div",
|
|
10052
10144
|
{
|
|
10053
10145
|
className: "rich-text",
|
|
10054
|
-
dangerouslySetInnerHTML: { __html: content }
|
|
10146
|
+
dangerouslySetInnerHTML: { __html: import_isomorphic_dompurify2.default.sanitize(content) }
|
|
10055
10147
|
}
|
|
10056
10148
|
) });
|
|
10057
10149
|
}
|
|
@@ -10101,10 +10193,10 @@ var findAllRichtextKeys = (fields, path = []) => {
|
|
|
10101
10193
|
return result;
|
|
10102
10194
|
};
|
|
10103
10195
|
function useRichtextProps(fields, props) {
|
|
10104
|
-
const richtextKeys = (0,
|
|
10105
|
-
const richtextProps = (0,
|
|
10196
|
+
const richtextKeys = (0, import_react67.useMemo)(() => findAllRichtextKeys(fields), [fields]);
|
|
10197
|
+
const richtextProps = (0, import_react67.useMemo)(() => {
|
|
10106
10198
|
if (!richtextKeys?.length) return {};
|
|
10107
|
-
const RichTextRender3 = (0,
|
|
10199
|
+
const RichTextRender3 = (0, import_react67.lazy)(
|
|
10108
10200
|
() => Promise.resolve().then(() => (init_Render(), Render_exports)).then((m) => ({
|
|
10109
10201
|
default: m.RichTextRender
|
|
10110
10202
|
}))
|
|
@@ -10112,7 +10204,7 @@ function useRichtextProps(fields, props) {
|
|
|
10112
10204
|
let result = { ...props };
|
|
10113
10205
|
for (const { path, field } of richtextKeys) {
|
|
10114
10206
|
result = mapDeep(result, path, (content) => /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(
|
|
10115
|
-
|
|
10207
|
+
import_react67.Suspense,
|
|
10116
10208
|
{
|
|
10117
10209
|
fallback: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(RichTextRenderFallback, { content }),
|
|
10118
10210
|
children: /* @__PURE__ */ (0, import_jsx_runtime64.jsx)(RichTextRender3, { content, field })
|
|
@@ -10148,7 +10240,7 @@ var Item2 = ({
|
|
|
10148
10240
|
}
|
|
10149
10241
|
);
|
|
10150
10242
|
};
|
|
10151
|
-
var SlotRender = (0,
|
|
10243
|
+
var SlotRender = (0, import_react68.forwardRef)(
|
|
10152
10244
|
function SlotRenderInternal({ className, style, content, config, metadata, as }, ref) {
|
|
10153
10245
|
const El = as ?? "div";
|
|
10154
10246
|
return /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(El, { className, style, ref, children: content.map((item) => {
|
|
@@ -10199,16 +10291,16 @@ init_flatten_node();
|
|
|
10199
10291
|
|
|
10200
10292
|
// lib/field-transforms/use-field-transforms-tracked.tsx
|
|
10201
10293
|
init_react_import();
|
|
10202
|
-
var
|
|
10294
|
+
var import_react69 = require("react");
|
|
10203
10295
|
init_map_fields();
|
|
10204
10296
|
function useFieldTransformsTracked(config, item, transforms, readOnly, forceReadOnly) {
|
|
10205
|
-
const prevProps = (0,
|
|
10206
|
-
const prevResult = (0,
|
|
10207
|
-
const mappers = (0,
|
|
10297
|
+
const prevProps = (0, import_react69.useRef)(null);
|
|
10298
|
+
const prevResult = (0, import_react69.useRef)(item.props);
|
|
10299
|
+
const mappers = (0, import_react69.useMemo)(
|
|
10208
10300
|
() => buildMappers(transforms, readOnly, forceReadOnly),
|
|
10209
10301
|
[transforms, readOnly, forceReadOnly]
|
|
10210
10302
|
);
|
|
10211
|
-
const transformedProps = (0,
|
|
10303
|
+
const transformedProps = (0, import_react69.useMemo)(() => {
|
|
10212
10304
|
const changedProps = {};
|
|
10213
10305
|
const componentConfig = item.type === "root" ? config.root : config.components?.[item.type];
|
|
10214
10306
|
let changeIncludesSlot = false;
|
|
@@ -10233,7 +10325,7 @@ function useFieldTransformsTracked(config, item, transforms, readOnly, forceRead
|
|
|
10233
10325
|
prevResult.current = { ...prevResult.current, ...mapped };
|
|
10234
10326
|
return prevResult.current;
|
|
10235
10327
|
}, [config, item, mappers]);
|
|
10236
|
-
const mergedProps = (0,
|
|
10328
|
+
const mergedProps = (0, import_react69.useMemo)(
|
|
10237
10329
|
() => ({ ...item.props, ...transformedProps }),
|
|
10238
10330
|
[item.props, transformedProps]
|
|
10239
10331
|
);
|
|
@@ -10245,7 +10337,7 @@ init_react_import();
|
|
|
10245
10337
|
|
|
10246
10338
|
// components/InlineTextField/index.tsx
|
|
10247
10339
|
init_react_import();
|
|
10248
|
-
var
|
|
10340
|
+
var import_react70 = require("react");
|
|
10249
10341
|
|
|
10250
10342
|
// lib/overlay-portal/index.tsx
|
|
10251
10343
|
init_react_import();
|
|
@@ -10298,7 +10390,7 @@ var registerOverlayPortal = (el, opts = {}) => {
|
|
|
10298
10390
|
// components/InlineTextField/index.tsx
|
|
10299
10391
|
init_store2();
|
|
10300
10392
|
|
|
10301
|
-
// css-module:/home/
|
|
10393
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/InlineTextField/styles.module.css#css-module
|
|
10302
10394
|
init_react_import();
|
|
10303
10395
|
var styles_module_default17 = { "InlineTextField": "_InlineTextField_104qp_1" };
|
|
10304
10396
|
|
|
@@ -10326,10 +10418,10 @@ var InlineTextFieldInternal = ({
|
|
|
10326
10418
|
isReadOnly,
|
|
10327
10419
|
opts = {}
|
|
10328
10420
|
}) => {
|
|
10329
|
-
const ref = (0,
|
|
10421
|
+
const ref = (0, import_react70.useRef)(null);
|
|
10330
10422
|
const appStoreApi = useAppStoreApi();
|
|
10331
10423
|
const disableLineBreaks = opts.disableLineBreaks ?? false;
|
|
10332
|
-
(0,
|
|
10424
|
+
(0, import_react70.useEffect)(() => {
|
|
10333
10425
|
const appStore = appStoreApi.getState();
|
|
10334
10426
|
const data = appStore.state.indexes.nodes[componentId].data;
|
|
10335
10427
|
const componentConfig = appStore.getComponentConfig(data.type);
|
|
@@ -10374,8 +10466,8 @@ var InlineTextFieldInternal = ({
|
|
|
10374
10466
|
};
|
|
10375
10467
|
}
|
|
10376
10468
|
}, [appStoreApi, ref, value, disableLineBreaks, componentId, propPath]);
|
|
10377
|
-
const [isHovering, setIsHovering] = (0,
|
|
10378
|
-
const [isFocused, setIsFocused] = (0,
|
|
10469
|
+
const [isHovering, setIsHovering] = (0, import_react70.useState)(false);
|
|
10470
|
+
const [isFocused, setIsFocused] = (0, import_react70.useState)(false);
|
|
10379
10471
|
return /* @__PURE__ */ (0, import_jsx_runtime67.jsx)(
|
|
10380
10472
|
"span",
|
|
10381
10473
|
{
|
|
@@ -10412,7 +10504,7 @@ var InlineTextFieldInternal = ({
|
|
|
10412
10504
|
}
|
|
10413
10505
|
);
|
|
10414
10506
|
};
|
|
10415
|
-
var InlineTextField = (0,
|
|
10507
|
+
var InlineTextField = (0, import_react70.memo)(InlineTextFieldInternal);
|
|
10416
10508
|
|
|
10417
10509
|
// lib/field-transforms/default-transforms/inline-text-transform.tsx
|
|
10418
10510
|
var import_jsx_runtime68 = require("react/jsx-runtime");
|
|
@@ -10467,19 +10559,19 @@ init_react_import();
|
|
|
10467
10559
|
init_EditorFallback();
|
|
10468
10560
|
init_store2();
|
|
10469
10561
|
init_set_deep();
|
|
10470
|
-
var
|
|
10562
|
+
var import_react71 = require("react");
|
|
10471
10563
|
var import_jsx_runtime69 = require("react/jsx-runtime");
|
|
10472
|
-
var Editor3 = (0,
|
|
10564
|
+
var Editor3 = (0, import_react71.lazy)(
|
|
10473
10565
|
() => Promise.resolve().then(() => (init_Editor(), Editor_exports)).then((m) => ({
|
|
10474
10566
|
default: m.Editor
|
|
10475
10567
|
}))
|
|
10476
10568
|
);
|
|
10477
|
-
var RichTextRender2 = (0,
|
|
10569
|
+
var RichTextRender2 = (0, import_react71.lazy)(
|
|
10478
10570
|
() => Promise.resolve().then(() => (init_Render(), Render_exports)).then((m) => ({
|
|
10479
10571
|
default: m.RichTextRender
|
|
10480
10572
|
}))
|
|
10481
10573
|
);
|
|
10482
|
-
var InlineEditorWrapper = (0,
|
|
10574
|
+
var InlineEditorWrapper = (0, import_react71.memo)(
|
|
10483
10575
|
({
|
|
10484
10576
|
value,
|
|
10485
10577
|
componentId,
|
|
@@ -10487,7 +10579,7 @@ var InlineEditorWrapper = (0, import_react72.memo)(
|
|
|
10487
10579
|
field,
|
|
10488
10580
|
id
|
|
10489
10581
|
}) => {
|
|
10490
|
-
const portalRef = (0,
|
|
10582
|
+
const portalRef = (0, import_react71.useRef)(null);
|
|
10491
10583
|
const appStoreApi = useAppStoreApi();
|
|
10492
10584
|
const onClickHandler = (e) => {
|
|
10493
10585
|
e.preventDefault();
|
|
@@ -10502,14 +10594,14 @@ var InlineEditorWrapper = (0, import_react72.memo)(
|
|
|
10502
10594
|
);
|
|
10503
10595
|
appStoreApi.getState().setUi({ itemSelector });
|
|
10504
10596
|
};
|
|
10505
|
-
(0,
|
|
10597
|
+
(0, import_react71.useEffect)(() => {
|
|
10506
10598
|
if (!portalRef.current) return;
|
|
10507
10599
|
const cleanup = registerOverlayPortal(portalRef.current, {
|
|
10508
10600
|
disableDragOnFocus: true
|
|
10509
10601
|
});
|
|
10510
10602
|
return () => cleanup?.();
|
|
10511
10603
|
}, []);
|
|
10512
|
-
const handleChange = (0,
|
|
10604
|
+
const handleChange = (0, import_react71.useCallback)(
|
|
10513
10605
|
async (content, ui) => {
|
|
10514
10606
|
const appStore = appStoreApi.getState();
|
|
10515
10607
|
const node = appStore.state.indexes.nodes[componentId];
|
|
@@ -10532,7 +10624,7 @@ var InlineEditorWrapper = (0, import_react72.memo)(
|
|
|
10532
10624
|
},
|
|
10533
10625
|
[appStoreApi, componentId, propPath]
|
|
10534
10626
|
);
|
|
10535
|
-
const handleFocus = (0,
|
|
10627
|
+
const handleFocus = (0, import_react71.useCallback)(
|
|
10536
10628
|
(editor) => {
|
|
10537
10629
|
appStoreApi.setState({
|
|
10538
10630
|
currentRichText: {
|
|
@@ -10547,7 +10639,7 @@ var InlineEditorWrapper = (0, import_react72.memo)(
|
|
|
10547
10639
|
[field, componentId, appStoreApi, id]
|
|
10548
10640
|
);
|
|
10549
10641
|
if (!field.contentEditable)
|
|
10550
|
-
return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
10642
|
+
return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_react71.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(RichTextRenderFallback, { content: value }), children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(RichTextRender2, { content: value, field }) });
|
|
10551
10643
|
const editorProps = {
|
|
10552
10644
|
content: value,
|
|
10553
10645
|
onChange: handleChange,
|
|
@@ -10563,7 +10655,7 @@ var InlineEditorWrapper = (0, import_react72.memo)(
|
|
|
10563
10655
|
ref: portalRef,
|
|
10564
10656
|
onClick: onClickHandler,
|
|
10565
10657
|
onClickCapture: onClickCaptureHandler,
|
|
10566
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
10658
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_react71.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(EditorFallback, { ...editorProps }), children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(Editor3, { ...editorProps }) })
|
|
10567
10659
|
}
|
|
10568
10660
|
);
|
|
10569
10661
|
}
|
|
@@ -10593,7 +10685,7 @@ var getRichTextTransform = () => ({
|
|
|
10593
10685
|
// components/MemoizeComponent/index.tsx
|
|
10594
10686
|
init_react_import();
|
|
10595
10687
|
var import_fast_equals3 = require("fast-equals");
|
|
10596
|
-
var
|
|
10688
|
+
var import_react72 = require("react");
|
|
10597
10689
|
|
|
10598
10690
|
// lib/shallow-equal.ts
|
|
10599
10691
|
init_react_import();
|
|
@@ -10627,7 +10719,7 @@ var RenderComponent = ({
|
|
|
10627
10719
|
}) => {
|
|
10628
10720
|
return /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(Component, { ...renderProps });
|
|
10629
10721
|
};
|
|
10630
|
-
var MemoizeComponent = (0,
|
|
10722
|
+
var MemoizeComponent = (0, import_react72.memo)(RenderComponent, (prev, next) => {
|
|
10631
10723
|
let credbuildEquals = true;
|
|
10632
10724
|
if ("credbuild" in prev.componentProps && "credbuild" in next.componentProps) {
|
|
10633
10725
|
credbuildEquals = (0, import_fast_equals3.deepEqual)(prev.componentProps.credbuild, next.componentProps.credbuild);
|
|
@@ -10637,7 +10729,7 @@ var MemoizeComponent = (0, import_react73.memo)(RenderComponent, (prev, next) =>
|
|
|
10637
10729
|
|
|
10638
10730
|
// components/DropZone/VirtualizedDropZone.tsx
|
|
10639
10731
|
init_react_import();
|
|
10640
|
-
var
|
|
10732
|
+
var import_react73 = require("react");
|
|
10641
10733
|
init_store2();
|
|
10642
10734
|
var import_react_virtual = require("@tanstack/react-virtual");
|
|
10643
10735
|
init_use_context_store();
|
|
@@ -10672,7 +10764,7 @@ var VirtualizedDropZone = ({
|
|
|
10672
10764
|
}) => {
|
|
10673
10765
|
const selectedId = useAppStore((s) => s.selectedItem?.props.id ?? null);
|
|
10674
10766
|
const frame = getFrame();
|
|
10675
|
-
const zoneStore = (0,
|
|
10767
|
+
const zoneStore = (0, import_react73.useContext)(ZoneStoreContext);
|
|
10676
10768
|
const draggedItemId = useContextStore(ZoneStoreContext, (s) => {
|
|
10677
10769
|
const draggedId = s.draggedItem?.id;
|
|
10678
10770
|
return draggedId ? String(draggedId) : null;
|
|
@@ -10685,9 +10777,9 @@ var VirtualizedDropZone = ({
|
|
|
10685
10777
|
return null;
|
|
10686
10778
|
});
|
|
10687
10779
|
const iframeWindow = frame?.defaultView;
|
|
10688
|
-
const measureRefsRef = (0,
|
|
10780
|
+
const measureRefsRef = (0, import_react73.useRef)(/* @__PURE__ */ new Map());
|
|
10689
10781
|
const appStoreApi = useAppStoreApi();
|
|
10690
|
-
const resolveIndex = (0,
|
|
10782
|
+
const resolveIndex = (0, import_react73.useCallback)(
|
|
10691
10783
|
(targetId) => {
|
|
10692
10784
|
if (!targetId || targetId === "root") {
|
|
10693
10785
|
return -1;
|
|
@@ -10711,7 +10803,7 @@ var VirtualizedDropZone = ({
|
|
|
10711
10803
|
},
|
|
10712
10804
|
[appStoreApi, contentIds]
|
|
10713
10805
|
);
|
|
10714
|
-
const pinnedIndexes = (0,
|
|
10806
|
+
const pinnedIndexes = (0, import_react73.useMemo)(() => {
|
|
10715
10807
|
const nextPinnedIndexes = /* @__PURE__ */ new Set();
|
|
10716
10808
|
[selectedId, draggedItemId, dragTargetParentId].forEach((targetId) => {
|
|
10717
10809
|
const currentIndex = resolveIndex(targetId);
|
|
@@ -10721,7 +10813,7 @@ var VirtualizedDropZone = ({
|
|
|
10721
10813
|
});
|
|
10722
10814
|
return Array.from(nextPinnedIndexes).sort((a, b) => a - b);
|
|
10723
10815
|
}, [dragTargetParentId, draggedItemId, resolveIndex, selectedId]);
|
|
10724
|
-
const rangeExtractor = (0,
|
|
10816
|
+
const rangeExtractor = (0, import_react73.useCallback)(
|
|
10725
10817
|
(range) => {
|
|
10726
10818
|
const indexes = (0, import_react_virtual.defaultRangeExtractor)(range);
|
|
10727
10819
|
pinnedIndexes.forEach((index) => {
|
|
@@ -10746,7 +10838,7 @@ var VirtualizedDropZone = ({
|
|
|
10746
10838
|
rangeExtractor,
|
|
10747
10839
|
initialOffset: () => iframeWindow ? iframeWindow.scrollY : 0
|
|
10748
10840
|
});
|
|
10749
|
-
(0,
|
|
10841
|
+
(0, import_react73.useEffect)(() => {
|
|
10750
10842
|
zoneStore.getState().registerRootVirtualizer(zoneCompound, {
|
|
10751
10843
|
resolveIndex: (targetId) => resolveIndex(targetId),
|
|
10752
10844
|
virtualizer
|
|
@@ -10755,7 +10847,7 @@ var VirtualizedDropZone = ({
|
|
|
10755
10847
|
zoneStore.getState().unregisterRootVirtualizer(zoneCompound);
|
|
10756
10848
|
};
|
|
10757
10849
|
}, [resolveIndex, virtualizer, zoneCompound, zoneStore]);
|
|
10758
|
-
const getMeasureRef = (0,
|
|
10850
|
+
const getMeasureRef = (0, import_react73.useCallback)((componentId) => {
|
|
10759
10851
|
const cachedRef = measureRefsRef.current.get(componentId);
|
|
10760
10852
|
if (cachedRef) {
|
|
10761
10853
|
return cachedRef;
|
|
@@ -10772,7 +10864,7 @@ var VirtualizedDropZone = ({
|
|
|
10772
10864
|
measureRefsRef.current.set(componentId, measureRef);
|
|
10773
10865
|
return measureRef;
|
|
10774
10866
|
}, []);
|
|
10775
|
-
(0,
|
|
10867
|
+
(0, import_react73.useEffect)(() => {
|
|
10776
10868
|
const validIds = new Set(contentIds);
|
|
10777
10869
|
Array.from(measureRefsRef.current.keys()).forEach((componentId) => {
|
|
10778
10870
|
if (!validIds.has(componentId)) {
|
|
@@ -10782,7 +10874,7 @@ var VirtualizedDropZone = ({
|
|
|
10782
10874
|
}, [contentIds]);
|
|
10783
10875
|
const virtualItems = virtualizer.getVirtualItems();
|
|
10784
10876
|
const totalSize = virtualizer.getTotalSize();
|
|
10785
|
-
const renderedItems = (0,
|
|
10877
|
+
const renderedItems = (0, import_react73.useMemo)(() => {
|
|
10786
10878
|
const items = [];
|
|
10787
10879
|
let previousEnd = 0;
|
|
10788
10880
|
let previousIndex = -1;
|
|
@@ -10842,7 +10934,7 @@ var InsertPreview = ({
|
|
|
10842
10934
|
override
|
|
10843
10935
|
}) => {
|
|
10844
10936
|
if (element) {
|
|
10845
|
-
return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("div", { dangerouslySetInnerHTML: { __html: element.outerHTML } });
|
|
10937
|
+
return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)("div", { dangerouslySetInnerHTML: { __html: import_isomorphic_dompurify4.default.sanitize(element.outerHTML) } });
|
|
10846
10938
|
}
|
|
10847
10939
|
return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(DrawerItemInner, { name: label, children: override });
|
|
10848
10940
|
};
|
|
@@ -10857,9 +10949,9 @@ var DropZoneChild = ({
|
|
|
10857
10949
|
itemRef
|
|
10858
10950
|
}) => {
|
|
10859
10951
|
const metadata = useAppStore((s) => s.metadata);
|
|
10860
|
-
const ctx = (0,
|
|
10952
|
+
const ctx = (0, import_react74.useContext)(dropZoneContext);
|
|
10861
10953
|
const { depth = 1 } = ctx ?? {};
|
|
10862
|
-
const zoneStore = (0,
|
|
10954
|
+
const zoneStore = (0, import_react74.useContext)(ZoneStoreContext);
|
|
10863
10955
|
const nodeProps = useAppStore(
|
|
10864
10956
|
(0, import_shallow6.useShallow)((s) => {
|
|
10865
10957
|
return s.state.indexes.nodes[componentId]?.flatData.props;
|
|
@@ -10872,7 +10964,7 @@ var DropZoneChild = ({
|
|
|
10872
10964
|
(0, import_shallow6.useShallow)((s) => s.state.indexes.nodes[componentId]?.data.readOnly)
|
|
10873
10965
|
);
|
|
10874
10966
|
const appStore = useAppStoreApi();
|
|
10875
|
-
const item = (0,
|
|
10967
|
+
const item = (0, import_react74.useMemo)(() => {
|
|
10876
10968
|
if (nodeProps) {
|
|
10877
10969
|
const expanded = expandNode({
|
|
10878
10970
|
type: nodeType,
|
|
@@ -10894,7 +10986,7 @@ var DropZoneChild = ({
|
|
|
10894
10986
|
const componentConfig = useAppStore(
|
|
10895
10987
|
(s) => item?.type ? s.config.components[item.type] : null
|
|
10896
10988
|
);
|
|
10897
|
-
const credbuildProps = (0,
|
|
10989
|
+
const credbuildProps = (0, import_react74.useMemo)(
|
|
10898
10990
|
() => ({
|
|
10899
10991
|
renderDropZone: DropZoneEditPure,
|
|
10900
10992
|
isEditing: true,
|
|
@@ -10911,7 +11003,7 @@ var DropZoneChild = ({
|
|
|
10911
11003
|
(s) => s.selectedItem?.props.id === componentId || false
|
|
10912
11004
|
);
|
|
10913
11005
|
let label = componentConfig?.label ?? item?.type.toString() ?? "Component";
|
|
10914
|
-
const defaultsProps = (0,
|
|
11006
|
+
const defaultsProps = (0, import_react74.useMemo)(
|
|
10915
11007
|
() => ({
|
|
10916
11008
|
...componentConfig?.defaultProps,
|
|
10917
11009
|
...item?.props,
|
|
@@ -10921,14 +11013,14 @@ var DropZoneChild = ({
|
|
|
10921
11013
|
}),
|
|
10922
11014
|
[componentConfig?.defaultProps, item?.props, credbuildProps]
|
|
10923
11015
|
);
|
|
10924
|
-
const defaultedNode = (0,
|
|
11016
|
+
const defaultedNode = (0, import_react74.useMemo)(
|
|
10925
11017
|
() => ({ type: item?.type ?? nodeType, props: defaultsProps }),
|
|
10926
11018
|
[item?.type, nodeType, defaultsProps]
|
|
10927
11019
|
);
|
|
10928
11020
|
const config = useAppStore((s) => s.config);
|
|
10929
11021
|
const plugins = useAppStore((s) => s.plugins);
|
|
10930
11022
|
const userFieldTransforms = useAppStore((s) => s.fieldTransforms);
|
|
10931
|
-
const combinedFieldTransforms = (0,
|
|
11023
|
+
const combinedFieldTransforms = (0, import_react74.useMemo)(
|
|
10932
11024
|
() => ({
|
|
10933
11025
|
...getSlotTransform(DropZoneEditPure, (slotProps) => /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(ContextSlotRender, { componentId, zone: slotProps.zone })),
|
|
10934
11026
|
...getInlineTextTransform(),
|
|
@@ -11001,8 +11093,8 @@ var DropZoneChild = ({
|
|
|
11001
11093
|
}
|
|
11002
11094
|
);
|
|
11003
11095
|
};
|
|
11004
|
-
var DropZoneChildMemo = (0,
|
|
11005
|
-
var DropZoneEdit = (0,
|
|
11096
|
+
var DropZoneChildMemo = (0, import_react74.memo)(DropZoneChild);
|
|
11097
|
+
var DropZoneEdit = (0, import_react74.forwardRef)(
|
|
11006
11098
|
function DropZoneEditInternal({
|
|
11007
11099
|
zone,
|
|
11008
11100
|
allow,
|
|
@@ -11013,7 +11105,7 @@ var DropZoneEdit = (0, import_react75.forwardRef)(
|
|
|
11013
11105
|
collisionAxis,
|
|
11014
11106
|
as
|
|
11015
11107
|
}, userRef) {
|
|
11016
|
-
const ctx = (0,
|
|
11108
|
+
const ctx = (0, import_react74.useContext)(dropZoneContext);
|
|
11017
11109
|
const appStoreApi = useAppStoreApi();
|
|
11018
11110
|
const {
|
|
11019
11111
|
// These all need setting via context
|
|
@@ -11046,14 +11138,14 @@ var DropZoneEdit = (0, import_react75.forwardRef)(
|
|
|
11046
11138
|
return s.state.indexes.zones[zoneCompound]?.type;
|
|
11047
11139
|
})
|
|
11048
11140
|
);
|
|
11049
|
-
(0,
|
|
11141
|
+
(0, import_react74.useEffect)(() => {
|
|
11050
11142
|
if (!zoneType || zoneType === "dropzone") {
|
|
11051
11143
|
if (ctx?.registerZone) {
|
|
11052
11144
|
ctx?.registerZone(zoneCompound);
|
|
11053
11145
|
}
|
|
11054
11146
|
}
|
|
11055
11147
|
}, [zoneType, appStoreApi, ctx, zoneCompound]);
|
|
11056
|
-
(0,
|
|
11148
|
+
(0, import_react74.useEffect)(() => {
|
|
11057
11149
|
if (zoneType === "dropzone") {
|
|
11058
11150
|
if (zoneCompound !== rootDroppableId) {
|
|
11059
11151
|
console.warn(
|
|
@@ -11062,11 +11154,11 @@ var DropZoneEdit = (0, import_react75.forwardRef)(
|
|
|
11062
11154
|
}
|
|
11063
11155
|
}
|
|
11064
11156
|
}, [zoneType, zoneCompound]);
|
|
11065
|
-
const contentIds = (0,
|
|
11157
|
+
const contentIds = (0, import_react74.useMemo)(() => {
|
|
11066
11158
|
return zoneContentIds || [];
|
|
11067
11159
|
}, [zoneContentIds]);
|
|
11068
|
-
const ref = (0,
|
|
11069
|
-
const acceptsTarget = (0,
|
|
11160
|
+
const ref = (0, import_react74.useRef)(null);
|
|
11161
|
+
const acceptsTarget = (0, import_react74.useCallback)(
|
|
11070
11162
|
(componentType) => {
|
|
11071
11163
|
if (!componentType) {
|
|
11072
11164
|
return true;
|
|
@@ -11102,7 +11194,7 @@ var DropZoneEdit = (0, import_react75.forwardRef)(
|
|
|
11102
11194
|
}
|
|
11103
11195
|
return _isEnabled;
|
|
11104
11196
|
});
|
|
11105
|
-
(0,
|
|
11197
|
+
(0, import_react74.useEffect)(() => {
|
|
11106
11198
|
if (registerLocalZone) {
|
|
11107
11199
|
registerLocalZone(zoneCompound, targetAccepted || isEnabled);
|
|
11108
11200
|
}
|
|
@@ -11117,8 +11209,8 @@ var DropZoneEdit = (0, import_react75.forwardRef)(
|
|
|
11117
11209
|
zoneCompound
|
|
11118
11210
|
);
|
|
11119
11211
|
const isDropEnabled = isEnabled && (preview ? contentIdsWithPreview.length === 1 : contentIdsWithPreview.length === 0);
|
|
11120
|
-
const zoneStore = (0,
|
|
11121
|
-
(0,
|
|
11212
|
+
const zoneStore = (0, import_react74.useContext)(ZoneStoreContext);
|
|
11213
|
+
(0, import_react74.useEffect)(() => {
|
|
11122
11214
|
const { enabledIndex } = zoneStore.getState();
|
|
11123
11215
|
zoneStore.setState({
|
|
11124
11216
|
enabledIndex: { ...enabledIndex, [zoneCompound]: isEnabled }
|
|
@@ -11137,7 +11229,7 @@ var DropZoneEdit = (0, import_react75.forwardRef)(
|
|
|
11137
11229
|
path: path || []
|
|
11138
11230
|
}
|
|
11139
11231
|
};
|
|
11140
|
-
const { ref: dropRef } = (0,
|
|
11232
|
+
const { ref: dropRef } = (0, import_react75.useDroppable)(droppableConfig);
|
|
11141
11233
|
const isAreaSelected = useAppStore(
|
|
11142
11234
|
(s) => s?.selectedItem && areaId === s?.selectedItem.props.id
|
|
11143
11235
|
);
|
|
@@ -11147,7 +11239,7 @@ var DropZoneEdit = (0, import_react75.forwardRef)(
|
|
|
11147
11239
|
userMinEmptyHeight,
|
|
11148
11240
|
ref
|
|
11149
11241
|
});
|
|
11150
|
-
const setRefs = (0,
|
|
11242
|
+
const setRefs = (0, import_react74.useCallback)(
|
|
11151
11243
|
(node) => {
|
|
11152
11244
|
assignRefs([ref, dropRef, userRef], node);
|
|
11153
11245
|
},
|
|
@@ -11213,14 +11305,14 @@ var DropZoneEdit = (0, import_react75.forwardRef)(
|
|
|
11213
11305
|
);
|
|
11214
11306
|
}
|
|
11215
11307
|
);
|
|
11216
|
-
var DropZoneRenderItem = ({
|
|
11308
|
+
var DropZoneRenderItem = (0, import_react74.memo)(({
|
|
11217
11309
|
config,
|
|
11218
11310
|
item,
|
|
11219
11311
|
metadata
|
|
11220
11312
|
}) => {
|
|
11221
11313
|
const Component = config.components[item.type];
|
|
11222
11314
|
const props = useSlots(config, item, (slotProps) => /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(SlotRenderPure, { ...slotProps, config, metadata }));
|
|
11223
|
-
const nextContextValue = (0,
|
|
11315
|
+
const nextContextValue = (0, import_react74.useMemo)(
|
|
11224
11316
|
() => ({
|
|
11225
11317
|
areaId: props.id,
|
|
11226
11318
|
depth: 1
|
|
@@ -11240,21 +11332,21 @@ var DropZoneRenderItem = ({
|
|
|
11240
11332
|
}
|
|
11241
11333
|
}
|
|
11242
11334
|
) }, props.id);
|
|
11243
|
-
};
|
|
11335
|
+
});
|
|
11244
11336
|
var DropZoneRenderPure = (props) => /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(DropZoneRender, { ...props });
|
|
11245
|
-
var DropZoneRender = (0,
|
|
11337
|
+
var DropZoneRender = (0, import_react74.forwardRef)(
|
|
11246
11338
|
function DropZoneRenderInternal({ className, style, zone, as }, ref) {
|
|
11247
|
-
const ctx = (0,
|
|
11339
|
+
const ctx = (0, import_react74.useContext)(dropZoneContext);
|
|
11248
11340
|
const { areaId = "root" } = ctx || {};
|
|
11249
|
-
const { config, data, metadata } = (0,
|
|
11341
|
+
const { config, data, metadata } = (0, import_react74.useContext)(renderContext);
|
|
11250
11342
|
let zoneCompound = `${areaId}:${zone}`;
|
|
11251
|
-
const content = (0,
|
|
11343
|
+
const content = (0, import_react74.useMemo)(() => {
|
|
11252
11344
|
if (zoneCompound !== rootDroppableId) {
|
|
11253
11345
|
return setupZone(data, zoneCompound).zones[zoneCompound];
|
|
11254
11346
|
}
|
|
11255
11347
|
return data?.content || [];
|
|
11256
11348
|
}, [data, zoneCompound]);
|
|
11257
|
-
(0,
|
|
11349
|
+
(0, import_react74.useEffect)(() => {
|
|
11258
11350
|
if (!content) {
|
|
11259
11351
|
if (ctx?.registerZone) {
|
|
11260
11352
|
ctx?.registerZone(zoneCompound);
|
|
@@ -11283,9 +11375,9 @@ var DropZoneRender = (0, import_react75.forwardRef)(
|
|
|
11283
11375
|
}
|
|
11284
11376
|
);
|
|
11285
11377
|
var DropZonePure = (props) => /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(DropZone, { ...props });
|
|
11286
|
-
var DropZone = (0,
|
|
11378
|
+
var DropZone = (0, import_react74.forwardRef)(
|
|
11287
11379
|
function DropZone2(props, ref) {
|
|
11288
|
-
const ctx = (0,
|
|
11380
|
+
const ctx = (0, import_react74.useContext)(dropZoneContext);
|
|
11289
11381
|
if (ctx?.mode === "edit") {
|
|
11290
11382
|
return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_jsx_runtime72.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(DropZoneEdit, { ...props, ref }) });
|
|
11291
11383
|
}
|
|
@@ -11298,7 +11390,7 @@ init_IconButton2();
|
|
|
11298
11390
|
|
|
11299
11391
|
// components/CredBuild/index.tsx
|
|
11300
11392
|
init_react_import();
|
|
11301
|
-
var
|
|
11393
|
+
var import_react101 = require("react");
|
|
11302
11394
|
init_store2();
|
|
11303
11395
|
|
|
11304
11396
|
// components/CredBuild/components/Fields/index.tsx
|
|
@@ -11309,13 +11401,13 @@ init_AutoField();
|
|
|
11309
11401
|
init_store();
|
|
11310
11402
|
init_store2();
|
|
11311
11403
|
|
|
11312
|
-
// css-module:/home/
|
|
11404
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/CredBuild/components/Fields/styles.module.css#css-module
|
|
11313
11405
|
init_react_import();
|
|
11314
11406
|
var styles_module_default18 = { "CredBuildFields": "_CredBuildFields_53gu7_1", "CredBuildFields--isLoading": "_CredBuildFields--isLoading_53gu7_6", "CredBuildFields-loadingOverlay": "_CredBuildFields-loadingOverlay_53gu7_10", "CredBuildFields-loadingOverlayInner": "_CredBuildFields-loadingOverlayInner_53gu7_25", "CredBuildFields-field": "_CredBuildFields-field_53gu7_32", "CredBuildFields--wrapFields": "_CredBuildFields--wrapFields_53gu7_36" };
|
|
11315
11407
|
|
|
11316
11408
|
// components/CredBuild/components/Fields/index.tsx
|
|
11317
11409
|
init_lib();
|
|
11318
|
-
var
|
|
11410
|
+
var import_react76 = require("react");
|
|
11319
11411
|
init_fields();
|
|
11320
11412
|
var import_shallow7 = require("zustand/react/shallow");
|
|
11321
11413
|
var import_jsx_runtime73 = require("react/jsx-runtime");
|
|
@@ -11384,15 +11476,15 @@ var FieldsChildInner = ({ fieldName }) => {
|
|
|
11384
11476
|
})
|
|
11385
11477
|
);
|
|
11386
11478
|
const appStore = useAppStoreApi();
|
|
11387
|
-
const onChange = (0,
|
|
11479
|
+
const onChange = (0, import_react76.useCallback)(
|
|
11388
11480
|
async (value, updatedUi) => {
|
|
11389
11481
|
createOnChange(fieldName, appStore)(value, updatedUi);
|
|
11390
11482
|
},
|
|
11391
11483
|
[fieldName, appStore]
|
|
11392
11484
|
);
|
|
11393
11485
|
const { visible = true } = field ?? {};
|
|
11394
|
-
const fieldStore = (0,
|
|
11395
|
-
(0,
|
|
11486
|
+
const fieldStore = (0, import_react76.useContext)(fieldContextStore.ctx);
|
|
11487
|
+
(0, import_react76.useEffect)(() => {
|
|
11396
11488
|
return appStore.subscribe(
|
|
11397
11489
|
(s) => {
|
|
11398
11490
|
const data = s.getCurrentData();
|
|
@@ -11418,13 +11510,13 @@ var FieldsChildInner = ({ fieldName }) => {
|
|
|
11418
11510
|
};
|
|
11419
11511
|
var FieldsChild = ({ fieldName }) => {
|
|
11420
11512
|
const appStore = useAppStoreApi();
|
|
11421
|
-
const initialValue = (0,
|
|
11513
|
+
const initialValue = (0, import_react76.useMemo)(() => {
|
|
11422
11514
|
const value = appStore.getState().getCurrentData().props?.[fieldName];
|
|
11423
11515
|
return { [fieldName]: value };
|
|
11424
11516
|
}, [appStore, fieldName]);
|
|
11425
11517
|
return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(fieldContextStore.Provider, { value: initialValue, children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(FieldsChildInner, { fieldName }) });
|
|
11426
11518
|
};
|
|
11427
|
-
var FieldsChildMemo = (0,
|
|
11519
|
+
var FieldsChildMemo = (0, import_react76.memo)(FieldsChild);
|
|
11428
11520
|
var FieldsInternal = ({ wrapFields = true }) => {
|
|
11429
11521
|
const overrides = useAppStore((s) => s.overrides);
|
|
11430
11522
|
const componentResolving = useAppStore((s) => {
|
|
@@ -11445,7 +11537,7 @@ var FieldsInternal = ({ wrapFields = true }) => {
|
|
|
11445
11537
|
})
|
|
11446
11538
|
);
|
|
11447
11539
|
const isLoading = fieldsLoading || componentResolving;
|
|
11448
|
-
const Wrapper = (0,
|
|
11540
|
+
const Wrapper = (0, import_react76.useMemo)(() => overrides.fields || DefaultFields, [overrides]);
|
|
11449
11541
|
return /* @__PURE__ */ (0, import_jsx_runtime73.jsxs)(
|
|
11450
11542
|
"form",
|
|
11451
11543
|
{
|
|
@@ -11460,31 +11552,30 @@ var FieldsInternal = ({ wrapFields = true }) => {
|
|
|
11460
11552
|
}
|
|
11461
11553
|
);
|
|
11462
11554
|
};
|
|
11463
|
-
var Fields = (0,
|
|
11555
|
+
var Fields = (0, import_react76.memo)(FieldsInternal);
|
|
11464
11556
|
|
|
11465
11557
|
// components/CredBuild/components/Components/index.tsx
|
|
11466
11558
|
init_react_import();
|
|
11467
11559
|
|
|
11468
11560
|
// lib/use-component-list.tsx
|
|
11469
11561
|
init_react_import();
|
|
11470
|
-
var
|
|
11562
|
+
var import_react78 = require("react");
|
|
11471
11563
|
|
|
11472
11564
|
// components/ComponentList/index.tsx
|
|
11473
11565
|
init_react_import();
|
|
11474
11566
|
|
|
11475
|
-
// css-module:/home/
|
|
11567
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/ComponentList/styles.module.css#css-module
|
|
11476
11568
|
init_react_import();
|
|
11477
11569
|
var styles_module_default19 = { "ComponentList": "_ComponentList_10tqo_1", "ComponentList--isExpanded": "_ComponentList--isExpanded_10tqo_5", "ComponentList-content": "_ComponentList-content_10tqo_9", "ComponentList-title": "_ComponentList-title_10tqo_17", "ComponentList-titleIcon": "_ComponentList-titleIcon_10tqo_53" };
|
|
11478
11570
|
|
|
11479
11571
|
// components/ComponentList/index.tsx
|
|
11480
11572
|
init_get_class_name_factory();
|
|
11481
|
-
var
|
|
11573
|
+
var import_react77 = require("react");
|
|
11482
11574
|
init_store2();
|
|
11483
11575
|
init_lucide_react();
|
|
11484
|
-
var import_react_virtual2 = require("@tanstack/react-virtual");
|
|
11485
11576
|
var import_jsx_runtime74 = require("react/jsx-runtime");
|
|
11486
11577
|
var getClassName28 = get_class_name_factory_default("ComponentList", styles_module_default19);
|
|
11487
|
-
var ComponentListItem = ({
|
|
11578
|
+
var ComponentListItem = (0, import_react77.memo)(({
|
|
11488
11579
|
name,
|
|
11489
11580
|
label
|
|
11490
11581
|
}) => {
|
|
@@ -11494,7 +11585,7 @@ var ComponentListItem = ({
|
|
|
11494
11585
|
type: name
|
|
11495
11586
|
}).insert
|
|
11496
11587
|
);
|
|
11497
|
-
(0,
|
|
11588
|
+
(0, import_react77.useEffect)(() => {
|
|
11498
11589
|
if (overrides.componentItem) {
|
|
11499
11590
|
console.warn(
|
|
11500
11591
|
"The `componentItem` override has been deprecated and renamed to `drawerItem`"
|
|
@@ -11502,40 +11593,36 @@ var ComponentListItem = ({
|
|
|
11502
11593
|
}
|
|
11503
11594
|
}, [overrides]);
|
|
11504
11595
|
return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(Drawer.Item, { label, name, isDragDisabled: !canInsert, children: overrides.componentItem ?? overrides.drawerItem });
|
|
11505
|
-
};
|
|
11596
|
+
});
|
|
11506
11597
|
var ComponentList = ({
|
|
11507
11598
|
children,
|
|
11508
11599
|
title,
|
|
11509
11600
|
id
|
|
11510
11601
|
}) => {
|
|
11511
11602
|
const config = useAppStore((s) => s.config);
|
|
11512
|
-
const
|
|
11513
|
-
const
|
|
11514
|
-
const parentRef = (0, import_react78.useRef)(null);
|
|
11515
|
-
const { expanded = true } = componentList[id] || {};
|
|
11603
|
+
const expanded = useAppStore((s) => s.state.ui.componentList[id]?.expanded ?? true);
|
|
11604
|
+
const appStoreApi = useAppStoreApi();
|
|
11516
11605
|
const components = Object.keys(config.components);
|
|
11517
|
-
const virtualizer = (0, import_react_virtual2.useVirtualizer)({
|
|
11518
|
-
count: components.length,
|
|
11519
|
-
getScrollElement: () => parentRef.current,
|
|
11520
|
-
estimateSize: () => 32,
|
|
11521
|
-
// Estimated height of each item
|
|
11522
|
-
overscan: 5
|
|
11523
|
-
});
|
|
11524
11606
|
return /* @__PURE__ */ (0, import_jsx_runtime74.jsxs)("div", { className: getClassName28({ isExpanded: expanded }), children: [
|
|
11525
11607
|
title && /* @__PURE__ */ (0, import_jsx_runtime74.jsxs)(
|
|
11526
11608
|
"button",
|
|
11527
11609
|
{
|
|
11528
11610
|
type: "button",
|
|
11529
11611
|
className: getClassName28("title"),
|
|
11530
|
-
|
|
11531
|
-
|
|
11532
|
-
|
|
11533
|
-
|
|
11534
|
-
|
|
11535
|
-
|
|
11612
|
+
"aria-expanded": expanded,
|
|
11613
|
+
"aria-controls": `${id}-content`,
|
|
11614
|
+
onClick: () => {
|
|
11615
|
+
const currentComponentList = appStoreApi.getState().state.ui.componentList;
|
|
11616
|
+
appStoreApi.getState().setUi({
|
|
11617
|
+
componentList: {
|
|
11618
|
+
...currentComponentList,
|
|
11619
|
+
[id]: {
|
|
11620
|
+
...currentComponentList[id],
|
|
11621
|
+
expanded: !expanded
|
|
11622
|
+
}
|
|
11536
11623
|
}
|
|
11537
|
-
}
|
|
11538
|
-
}
|
|
11624
|
+
});
|
|
11625
|
+
},
|
|
11539
11626
|
children: [
|
|
11540
11627
|
/* @__PURE__ */ (0, import_jsx_runtime74.jsxs)("div", { style: { display: "flex", alignItems: "center", gap: "8px" }, children: [
|
|
11541
11628
|
id.toLowerCase().includes("hero") && /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(LayoutTemplate, { size: 12, strokeWidth: 2.5 }),
|
|
@@ -11553,47 +11640,23 @@ var ComponentList = ({
|
|
|
11553
11640
|
/* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
|
|
11554
11641
|
"div",
|
|
11555
11642
|
{
|
|
11556
|
-
|
|
11643
|
+
id: `${id}-content`,
|
|
11557
11644
|
className: getClassName28("content"),
|
|
11558
11645
|
style: {
|
|
11559
|
-
|
|
11560
|
-
|
|
11561
|
-
transition: "max-height 0.3s ease-in-out"
|
|
11646
|
+
overflow: "visible",
|
|
11647
|
+
display: expanded ? "block" : "none"
|
|
11562
11648
|
},
|
|
11563
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
|
|
11564
|
-
|
|
11565
|
-
|
|
11566
|
-
|
|
11567
|
-
|
|
11568
|
-
|
|
11569
|
-
|
|
11649
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(Drawer, { children: children || components.map((componentKey, i) => {
|
|
11650
|
+
return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
|
|
11651
|
+
ComponentListItem,
|
|
11652
|
+
{
|
|
11653
|
+
label: config.components[componentKey]["label"] ?? componentKey,
|
|
11654
|
+
name: componentKey,
|
|
11655
|
+
index: i
|
|
11570
11656
|
},
|
|
11571
|
-
|
|
11572
|
-
|
|
11573
|
-
|
|
11574
|
-
"div",
|
|
11575
|
-
{
|
|
11576
|
-
style: {
|
|
11577
|
-
position: "absolute",
|
|
11578
|
-
top: 0,
|
|
11579
|
-
left: 0,
|
|
11580
|
-
width: "100%",
|
|
11581
|
-
height: `${virtualItem.size}px`,
|
|
11582
|
-
transform: `translateY(${virtualItem.start}px)`
|
|
11583
|
-
},
|
|
11584
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(
|
|
11585
|
-
ComponentListItem,
|
|
11586
|
-
{
|
|
11587
|
-
label: config.components[componentKey]["label"] ?? componentKey,
|
|
11588
|
-
name: componentKey
|
|
11589
|
-
}
|
|
11590
|
-
)
|
|
11591
|
-
},
|
|
11592
|
-
virtualItem.key
|
|
11593
|
-
);
|
|
11594
|
-
}) })
|
|
11595
|
-
}
|
|
11596
|
-
)
|
|
11657
|
+
componentKey
|
|
11658
|
+
);
|
|
11659
|
+
}) })
|
|
11597
11660
|
}
|
|
11598
11661
|
)
|
|
11599
11662
|
] });
|
|
@@ -11604,10 +11667,10 @@ ComponentList.Item = ComponentListItem;
|
|
|
11604
11667
|
init_store2();
|
|
11605
11668
|
var import_jsx_runtime75 = require("react/jsx-runtime");
|
|
11606
11669
|
var useComponentList = () => {
|
|
11607
|
-
const [componentList, setComponentList] = (0,
|
|
11670
|
+
const [componentList, setComponentList] = (0, import_react78.useState)();
|
|
11608
11671
|
const config = useAppStore((s) => s.config);
|
|
11609
11672
|
const uiComponentList = useAppStore((s) => s.state.ui.componentList);
|
|
11610
|
-
(0,
|
|
11673
|
+
(0, import_react78.useEffect)(() => {
|
|
11611
11674
|
if (Object.keys(uiComponentList).length > 0) {
|
|
11612
11675
|
const matchedComponents = [];
|
|
11613
11676
|
let _componentList;
|
|
@@ -11679,12 +11742,23 @@ var useComponentList = () => {
|
|
|
11679
11742
|
|
|
11680
11743
|
// components/CredBuild/components/Components/index.tsx
|
|
11681
11744
|
init_store2();
|
|
11682
|
-
var
|
|
11745
|
+
var import_react79 = require("react");
|
|
11746
|
+
init_lucide_react();
|
|
11747
|
+
|
|
11748
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/CredBuild/components/Components/styles.module.css#css-module
|
|
11749
|
+
init_react_import();
|
|
11750
|
+
var styles_module_default20 = { "CredBuildComponents": "_CredBuildComponents_17idm_1", "CredBuildComponents-searchContainer": "_CredBuildComponents-searchContainer_17idm_7", "CredBuildComponents-searchWrapper": "_CredBuildComponents-searchWrapper_17idm_16", "CredBuildComponents-searchInput": "_CredBuildComponents-searchInput_17idm_23", "CredBuildComponents-searchIcon": "_CredBuildComponents-searchIcon_17idm_42", "CredBuildComponents-clearButton": "_CredBuildComponents-clearButton_17idm_49", "CredBuildComponents-listContainer": "_CredBuildComponents-listContainer_17idm_69", "CredBuildComponents-noResults": "_CredBuildComponents-noResults_17idm_74" };
|
|
11751
|
+
|
|
11752
|
+
// components/CredBuild/components/Components/index.tsx
|
|
11753
|
+
init_lib();
|
|
11683
11754
|
var import_jsx_runtime76 = require("react/jsx-runtime");
|
|
11755
|
+
var getClassName29 = get_class_name_factory_default("CredBuildComponents", styles_module_default20);
|
|
11684
11756
|
var Components = () => {
|
|
11685
11757
|
const overrides = useAppStore((s) => s.overrides);
|
|
11758
|
+
const config = useAppStore((s) => s.config);
|
|
11759
|
+
const [searchTerm, setSearchTerm] = (0, import_react79.useState)("");
|
|
11686
11760
|
const componentList = useComponentList();
|
|
11687
|
-
const Wrapper = (0,
|
|
11761
|
+
const Wrapper = (0, import_react79.useMemo)(() => {
|
|
11688
11762
|
if (overrides.components) {
|
|
11689
11763
|
console.warn(
|
|
11690
11764
|
"The `components` override has been deprecated and renamed to `drawer`"
|
|
@@ -11692,18 +11766,89 @@ var Components = () => {
|
|
|
11692
11766
|
}
|
|
11693
11767
|
return overrides.components || overrides.drawer || "div";
|
|
11694
11768
|
}, [overrides]);
|
|
11695
|
-
|
|
11769
|
+
const matchingComponents = (0, import_react79.useMemo)(() => {
|
|
11770
|
+
if (!searchTerm.trim()) return [];
|
|
11771
|
+
return Object.keys(config.components).filter((componentKey) => {
|
|
11772
|
+
const componentConf = config.components[componentKey] || {};
|
|
11773
|
+
const label = componentConf["label"] ?? componentKey;
|
|
11774
|
+
return label.toLowerCase().includes(searchTerm.toLowerCase()) || componentKey.toLowerCase().includes(searchTerm.toLowerCase());
|
|
11775
|
+
});
|
|
11776
|
+
}, [searchTerm, config.components]);
|
|
11777
|
+
return /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)(Wrapper, { className: getClassName29(), children: [
|
|
11778
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)("div", { className: getClassName29("searchContainer"), children: /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)("div", { className: getClassName29("searchWrapper"), children: [
|
|
11779
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)(Search, { size: 14, className: getClassName29("searchIcon") }),
|
|
11780
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)(
|
|
11781
|
+
"input",
|
|
11782
|
+
{
|
|
11783
|
+
type: "text",
|
|
11784
|
+
className: getClassName29("searchInput"),
|
|
11785
|
+
placeholder: "Search blocks...",
|
|
11786
|
+
value: searchTerm,
|
|
11787
|
+
onChange: (e) => setSearchTerm(e.target.value)
|
|
11788
|
+
}
|
|
11789
|
+
),
|
|
11790
|
+
searchTerm && /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(
|
|
11791
|
+
"button",
|
|
11792
|
+
{
|
|
11793
|
+
type: "button",
|
|
11794
|
+
className: getClassName29("clearButton"),
|
|
11795
|
+
onClick: () => setSearchTerm(""),
|
|
11796
|
+
title: "Clear search",
|
|
11797
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(X, { size: 12 })
|
|
11798
|
+
}
|
|
11799
|
+
)
|
|
11800
|
+
] }) }),
|
|
11801
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)("div", { className: getClassName29("listContainer"), children: searchTerm.trim() ? matchingComponents.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)("div", { style: { padding: "10px 12px" }, children: [
|
|
11802
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsxs)(
|
|
11803
|
+
"div",
|
|
11804
|
+
{
|
|
11805
|
+
style: {
|
|
11806
|
+
fontSize: "10px",
|
|
11807
|
+
fontWeight: 700,
|
|
11808
|
+
color: "var(--cb-silver-muted)",
|
|
11809
|
+
marginBottom: "8px",
|
|
11810
|
+
textTransform: "uppercase",
|
|
11811
|
+
letterSpacing: "0.05em"
|
|
11812
|
+
},
|
|
11813
|
+
children: [
|
|
11814
|
+
"Search Results (",
|
|
11815
|
+
matchingComponents.length,
|
|
11816
|
+
")"
|
|
11817
|
+
]
|
|
11818
|
+
}
|
|
11819
|
+
),
|
|
11820
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)(Drawer, { children: /* @__PURE__ */ (0, import_jsx_runtime76.jsx)("div", { style: { display: "flex", flexDirection: "column", gap: "2px" }, children: matchingComponents.map((componentName, i) => {
|
|
11821
|
+
const componentConf = config.components[componentName] || {};
|
|
11822
|
+
return /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(
|
|
11823
|
+
ComponentList.Item,
|
|
11824
|
+
{
|
|
11825
|
+
label: componentConf["label"] ?? componentName,
|
|
11826
|
+
name: componentName,
|
|
11827
|
+
index: i
|
|
11828
|
+
},
|
|
11829
|
+
componentName
|
|
11830
|
+
);
|
|
11831
|
+
}) }) })
|
|
11832
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)("div", { className: getClassName29("noResults"), children: [
|
|
11833
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsx)(Inbox, { size: 20, strokeWidth: 1.5 }),
|
|
11834
|
+
/* @__PURE__ */ (0, import_jsx_runtime76.jsxs)("div", { children: [
|
|
11835
|
+
'No blocks found matching "',
|
|
11836
|
+
searchTerm,
|
|
11837
|
+
'"'
|
|
11838
|
+
] })
|
|
11839
|
+
] }) : componentList ? componentList : /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(ComponentList, { id: "all" }) })
|
|
11840
|
+
] });
|
|
11696
11841
|
};
|
|
11697
11842
|
|
|
11698
11843
|
// components/CredBuild/components/Preview/index.tsx
|
|
11699
11844
|
init_react_import();
|
|
11700
11845
|
init_root_droppable_id();
|
|
11701
|
-
var
|
|
11846
|
+
var import_react82 = require("react");
|
|
11702
11847
|
init_store2();
|
|
11703
11848
|
|
|
11704
11849
|
// components/AutoFrame/index.tsx
|
|
11705
11850
|
init_react_import();
|
|
11706
|
-
var
|
|
11851
|
+
var import_react80 = require("react");
|
|
11707
11852
|
var import_object_hash = __toESM(require("object-hash"));
|
|
11708
11853
|
var import_react_dom3 = require("react-dom");
|
|
11709
11854
|
var import_jsx_runtime77 = require("react/jsx-runtime");
|
|
@@ -11756,7 +11901,7 @@ var CopyHostStyles = ({
|
|
|
11756
11901
|
onStylesLoaded = () => null
|
|
11757
11902
|
}) => {
|
|
11758
11903
|
const { document: doc, window: win } = useFrame();
|
|
11759
|
-
(0,
|
|
11904
|
+
(0, import_react80.useEffect)(() => {
|
|
11760
11905
|
if (!win || !doc) {
|
|
11761
11906
|
return () => {
|
|
11762
11907
|
};
|
|
@@ -11922,8 +12067,8 @@ var CopyHostStyles = ({
|
|
|
11922
12067
|
}, [debug, doc, onStylesLoaded, win]);
|
|
11923
12068
|
return /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_jsx_runtime77.Fragment, { children });
|
|
11924
12069
|
};
|
|
11925
|
-
var autoFrameContext = (0,
|
|
11926
|
-
var useFrame = () => (0,
|
|
12070
|
+
var autoFrameContext = (0, import_react80.createContext)({});
|
|
12071
|
+
var useFrame = () => (0, import_react80.useContext)(autoFrameContext);
|
|
11927
12072
|
function AutoFrame({
|
|
11928
12073
|
children,
|
|
11929
12074
|
className,
|
|
@@ -11936,20 +12081,20 @@ function AutoFrame({
|
|
|
11936
12081
|
frameRef,
|
|
11937
12082
|
...props
|
|
11938
12083
|
}) {
|
|
11939
|
-
const [loaded, setLoaded] = (0,
|
|
11940
|
-
const [ctx, setCtx] = (0,
|
|
11941
|
-
const [mountTarget, setMountTarget] = (0,
|
|
11942
|
-
const [stylesLoaded, setStylesLoaded] = (0,
|
|
11943
|
-
const handleStylesLoaded = (0,
|
|
12084
|
+
const [loaded, setLoaded] = (0, import_react80.useState)(false);
|
|
12085
|
+
const [ctx, setCtx] = (0, import_react80.useState)({});
|
|
12086
|
+
const [mountTarget, setMountTarget] = (0, import_react80.useState)();
|
|
12087
|
+
const [stylesLoaded, setStylesLoaded] = (0, import_react80.useState)(false);
|
|
12088
|
+
const handleStylesLoaded = (0, import_react80.useCallback)(() => {
|
|
11944
12089
|
setStylesLoaded(true);
|
|
11945
12090
|
}, []);
|
|
11946
|
-
const onReadyRef = (0,
|
|
11947
|
-
const onNotReadyRef = (0,
|
|
11948
|
-
(0,
|
|
12091
|
+
const onReadyRef = (0, import_react80.useRef)(onReady);
|
|
12092
|
+
const onNotReadyRef = (0, import_react80.useRef)(onNotReady);
|
|
12093
|
+
(0, import_react80.useEffect)(() => {
|
|
11949
12094
|
onReadyRef.current = onReady;
|
|
11950
12095
|
onNotReadyRef.current = onNotReady;
|
|
11951
12096
|
}, [onReady, onNotReady]);
|
|
11952
|
-
(0,
|
|
12097
|
+
(0, import_react80.useEffect)(() => {
|
|
11953
12098
|
if (frameRef.current) {
|
|
11954
12099
|
const doc = frameRef.current.contentDocument;
|
|
11955
12100
|
const win = frameRef.current.contentWindow;
|
|
@@ -11995,9 +12140,9 @@ function AutoFrame({
|
|
|
11995
12140
|
AutoFrame.displayName = "AutoFrame";
|
|
11996
12141
|
var AutoFrame_default = AutoFrame;
|
|
11997
12142
|
|
|
11998
|
-
// css-module:/home/
|
|
12143
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/CredBuild/components/Preview/styles.module.css#css-module
|
|
11999
12144
|
init_react_import();
|
|
12000
|
-
var
|
|
12145
|
+
var styles_module_default21 = { "CredBuildPreview": "_CredBuildPreview_1z08a_1", "CredBuildPreview-frame": "_CredBuildPreview-frame_1z08a_6" };
|
|
12001
12146
|
|
|
12002
12147
|
// components/CredBuild/components/Preview/index.tsx
|
|
12003
12148
|
init_lib();
|
|
@@ -12005,7 +12150,7 @@ init_lib();
|
|
|
12005
12150
|
// components/Render/index.tsx
|
|
12006
12151
|
init_react_import();
|
|
12007
12152
|
init_root_droppable_id();
|
|
12008
|
-
var
|
|
12153
|
+
var import_react81 = require("react");
|
|
12009
12154
|
var import_jsx_runtime78 = require("react/jsx-runtime");
|
|
12010
12155
|
function Render({
|
|
12011
12156
|
config,
|
|
@@ -12037,7 +12182,7 @@ function Render({
|
|
|
12037
12182
|
(props) => /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(SlotRender, { ...props, config, metadata })
|
|
12038
12183
|
);
|
|
12039
12184
|
const richtextProps = useRichtextProps(config.root?.fields, pageProps);
|
|
12040
|
-
const nextContextValue = (0,
|
|
12185
|
+
const nextContextValue = (0, import_react81.useMemo)(
|
|
12041
12186
|
() => ({
|
|
12042
12187
|
mode: "render",
|
|
12043
12188
|
depth: 0
|
|
@@ -12071,10 +12216,10 @@ var BubbledPointerEvent = class extends BaseEvent {
|
|
|
12071
12216
|
|
|
12072
12217
|
// components/CredBuild/components/Preview/index.tsx
|
|
12073
12218
|
var import_jsx_runtime79 = require("react/jsx-runtime");
|
|
12074
|
-
var
|
|
12219
|
+
var getClassName30 = get_class_name_factory_default("CredBuildPreview", styles_module_default21);
|
|
12075
12220
|
var useBubbleIframeEvents = (ref) => {
|
|
12076
12221
|
const status = useAppStore((s) => s.status);
|
|
12077
|
-
(0,
|
|
12222
|
+
(0, import_react82.useEffect)(() => {
|
|
12078
12223
|
if (ref.current && status === "READY") {
|
|
12079
12224
|
const iframe = ref.current;
|
|
12080
12225
|
const handlePointerMove = (event) => {
|
|
@@ -12122,7 +12267,7 @@ var Preview = ({ id = "credbuild-preview" }) => {
|
|
|
12122
12267
|
const renderData = useAppStore(
|
|
12123
12268
|
(s) => s.state.ui.previewMode === "edit" ? null : s.state.data
|
|
12124
12269
|
);
|
|
12125
|
-
const Page = (0,
|
|
12270
|
+
const Page = (0, import_react82.useCallback)(
|
|
12126
12271
|
(pageProps) => {
|
|
12127
12272
|
const propsWithSlots = useSlots(
|
|
12128
12273
|
config,
|
|
@@ -12141,9 +12286,9 @@ var Preview = ({ id = "credbuild-preview" }) => {
|
|
|
12141
12286
|
},
|
|
12142
12287
|
[config]
|
|
12143
12288
|
);
|
|
12144
|
-
const Frame = (0,
|
|
12289
|
+
const Frame = (0, import_react82.useMemo)(() => overrides.iframe, [overrides]);
|
|
12145
12290
|
const rootProps = root.props || root;
|
|
12146
|
-
const ref = (0,
|
|
12291
|
+
const ref = (0, import_react82.useRef)(null);
|
|
12147
12292
|
useBubbleIframeEvents(ref);
|
|
12148
12293
|
const inner = !renderData ? /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(
|
|
12149
12294
|
Page,
|
|
@@ -12159,7 +12304,7 @@ var Preview = ({ id = "credbuild-preview" }) => {
|
|
|
12159
12304
|
children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(DropZonePure, { zone: rootDroppableId })
|
|
12160
12305
|
}
|
|
12161
12306
|
) : /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(Render, { data: renderData, config, metadata });
|
|
12162
|
-
(0,
|
|
12307
|
+
(0, import_react82.useEffect)(() => {
|
|
12163
12308
|
if (!iframe.enabled) {
|
|
12164
12309
|
setStatus("READY");
|
|
12165
12310
|
}
|
|
@@ -12167,7 +12312,7 @@ var Preview = ({ id = "credbuild-preview" }) => {
|
|
|
12167
12312
|
return /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(
|
|
12168
12313
|
"div",
|
|
12169
12314
|
{
|
|
12170
|
-
className:
|
|
12315
|
+
className: getClassName30(),
|
|
12171
12316
|
id,
|
|
12172
12317
|
"data-credbuild-preview": true,
|
|
12173
12318
|
onClick: (e) => {
|
|
@@ -12180,7 +12325,7 @@ var Preview = ({ id = "credbuild-preview" }) => {
|
|
|
12180
12325
|
AutoFrame_default,
|
|
12181
12326
|
{
|
|
12182
12327
|
id: "preview-frame",
|
|
12183
|
-
className:
|
|
12328
|
+
className: getClassName30("frame"),
|
|
12184
12329
|
"data-rfd-iframe": true,
|
|
12185
12330
|
onReady: () => {
|
|
12186
12331
|
setStatus("READY");
|
|
@@ -12200,7 +12345,7 @@ var Preview = ({ id = "credbuild-preview" }) => {
|
|
|
12200
12345
|
"div",
|
|
12201
12346
|
{
|
|
12202
12347
|
id: "preview-frame",
|
|
12203
|
-
className:
|
|
12348
|
+
className: getClassName30("frame"),
|
|
12204
12349
|
ref,
|
|
12205
12350
|
"data-credbuild-entry": true,
|
|
12206
12351
|
children: inner
|
|
@@ -12216,21 +12361,21 @@ init_react_import();
|
|
|
12216
12361
|
// components/LayerTree/index.tsx
|
|
12217
12362
|
init_react_import();
|
|
12218
12363
|
|
|
12219
|
-
// css-module:/home/
|
|
12364
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/LayerTree/styles.module.css#css-module
|
|
12220
12365
|
init_react_import();
|
|
12221
|
-
var
|
|
12366
|
+
var styles_module_default22 = { "LayerTree": "_LayerTree_nus40_1", "LayerTree-zoneTitle": "_LayerTree-zoneTitle_nus40_11", "LayerTree-helper": "_LayerTree-helper_nus40_17", "Layer": "_Layer_nus40_1", "Layer-inner": "_Layer-inner_nus40_29", "Layer--containsZone": "_Layer--containsZone_nus40_35", "Layer-clickable": "_Layer-clickable_nus40_39", "Layer--isSelected": "_Layer--isSelected_nus40_58", "Layer-chevron": "_Layer-chevron_nus40_79", "Layer--childIsSelected": "_Layer--childIsSelected_nus40_80", "Layer-zones": "_Layer-zones_nus40_84", "Layer-title": "_Layer-title_nus40_98", "Layer-name": "_Layer-name_nus40_107", "Layer-icon": "_Layer-icon_nus40_113", "Layer-zoneIcon": "_Layer-zoneIcon_nus40_118" };
|
|
12222
12367
|
|
|
12223
12368
|
// components/LayerTree/index.tsx
|
|
12224
12369
|
init_get_class_name_factory();
|
|
12225
12370
|
init_lucide_react();
|
|
12226
12371
|
init_root_droppable_id();
|
|
12227
|
-
var
|
|
12372
|
+
var import_react83 = require("react");
|
|
12228
12373
|
init_store2();
|
|
12229
12374
|
init_use_context_store();
|
|
12230
|
-
var
|
|
12375
|
+
var import_react_virtual2 = require("@tanstack/react-virtual");
|
|
12231
12376
|
var import_jsx_runtime80 = require("react/jsx-runtime");
|
|
12232
|
-
var
|
|
12233
|
-
var getClassNameLayer = get_class_name_factory_default("Layer",
|
|
12377
|
+
var getClassName31 = get_class_name_factory_default("LayerTree", styles_module_default22);
|
|
12378
|
+
var getClassNameLayer = get_class_name_factory_default("Layer", styles_module_default22);
|
|
12234
12379
|
var DEFAULT_LAYER_ROW_HEIGHT = 32;
|
|
12235
12380
|
var LAYER_TREE_VIRTUALIZATION_OVERSCAN = 8;
|
|
12236
12381
|
var MIN_VIRTUALIZED_LAYER_COUNT = 25;
|
|
@@ -12327,7 +12472,7 @@ var getScrollParent = (el) => {
|
|
|
12327
12472
|
}
|
|
12328
12473
|
return null;
|
|
12329
12474
|
};
|
|
12330
|
-
var Layer = (0,
|
|
12475
|
+
var Layer = (0, import_react83.memo)((0, import_react83.forwardRef)(function Layer2({
|
|
12331
12476
|
childIsSelected,
|
|
12332
12477
|
dataIndex,
|
|
12333
12478
|
depth,
|
|
@@ -12337,13 +12482,13 @@ var Layer = (0, import_react84.forwardRef)(function Layer2({
|
|
|
12337
12482
|
selectedPathIds
|
|
12338
12483
|
}, ref) {
|
|
12339
12484
|
const dispatch = useAppStore((s) => s.dispatch);
|
|
12340
|
-
const zoneStore = (0,
|
|
12485
|
+
const zoneStore = (0, import_react83.useContext)(ZoneStoreContext);
|
|
12341
12486
|
const isHovering = useContextStore(
|
|
12342
12487
|
ZoneStoreContext,
|
|
12343
12488
|
(s) => s.hoveringComponent === node.itemId
|
|
12344
12489
|
);
|
|
12345
12490
|
const containsZone = node.childZones.length > 0;
|
|
12346
|
-
const setItemSelector = (0,
|
|
12491
|
+
const setItemSelector = (0, import_react83.useCallback)(
|
|
12347
12492
|
(itemSelector) => {
|
|
12348
12493
|
dispatch({ type: "setUi", ui: { itemSelector } });
|
|
12349
12494
|
},
|
|
@@ -12436,8 +12581,8 @@ var Layer = (0, import_react84.forwardRef)(function Layer2({
|
|
|
12436
12581
|
]
|
|
12437
12582
|
}
|
|
12438
12583
|
);
|
|
12439
|
-
});
|
|
12440
|
-
var LayerTreeZone = ({
|
|
12584
|
+
}));
|
|
12585
|
+
var LayerTreeZone = (0, import_react83.memo)(({
|
|
12441
12586
|
depth,
|
|
12442
12587
|
selectedId,
|
|
12443
12588
|
selectedPathIds,
|
|
@@ -12445,8 +12590,8 @@ var LayerTreeZone = ({
|
|
|
12445
12590
|
}) => {
|
|
12446
12591
|
const shouldVirtualize = depth === 0 && tree.items.length >= MIN_VIRTUALIZED_LAYER_COUNT;
|
|
12447
12592
|
return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)(import_jsx_runtime80.Fragment, { children: [
|
|
12448
|
-
tree.label && /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("div", { className:
|
|
12449
|
-
/* @__PURE__ */ (0, import_jsx_runtime80.jsx)("div", { className:
|
|
12593
|
+
tree.label && /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("div", { className: getClassName31("zoneTitle"), children: [
|
|
12594
|
+
/* @__PURE__ */ (0, import_jsx_runtime80.jsx)("div", { className: getClassName31("zoneIcon"), children: /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(Layers, { size: "16" }) }),
|
|
12450
12595
|
tree.label
|
|
12451
12596
|
] }),
|
|
12452
12597
|
shouldVirtualize ? /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(
|
|
@@ -12467,15 +12612,15 @@ var LayerTreeZone = ({
|
|
|
12467
12612
|
}
|
|
12468
12613
|
)
|
|
12469
12614
|
] });
|
|
12470
|
-
};
|
|
12471
|
-
var StaticLayerTreeItems = ({
|
|
12615
|
+
});
|
|
12616
|
+
var StaticLayerTreeItems = (0, import_react83.memo)(({
|
|
12472
12617
|
depth,
|
|
12473
12618
|
selectedId,
|
|
12474
12619
|
selectedPathIds,
|
|
12475
12620
|
tree
|
|
12476
12621
|
}) => {
|
|
12477
|
-
return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("ul", { className:
|
|
12478
|
-
tree.items.length === 0 && /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("div", { className:
|
|
12622
|
+
return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("ul", { className: getClassName31(), children: [
|
|
12623
|
+
tree.items.length === 0 && /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("div", { className: getClassName31("helper"), children: "No items" }),
|
|
12479
12624
|
tree.items.map((node) => /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(
|
|
12480
12625
|
Layer,
|
|
12481
12626
|
{
|
|
@@ -12489,15 +12634,15 @@ var StaticLayerTreeItems = ({
|
|
|
12489
12634
|
node.itemId
|
|
12490
12635
|
))
|
|
12491
12636
|
] });
|
|
12492
|
-
};
|
|
12493
|
-
var VirtualizedLayerTreeItems = ({
|
|
12637
|
+
});
|
|
12638
|
+
var VirtualizedLayerTreeItems = (0, import_react83.memo)(({
|
|
12494
12639
|
depth,
|
|
12495
12640
|
selectedId,
|
|
12496
12641
|
selectedPathIds,
|
|
12497
12642
|
tree
|
|
12498
12643
|
}) => {
|
|
12499
|
-
const listRef = (0,
|
|
12500
|
-
const virtualizer = (0,
|
|
12644
|
+
const listRef = (0, import_react83.useRef)(null);
|
|
12645
|
+
const virtualizer = (0, import_react_virtual2.useVirtualizer)({
|
|
12501
12646
|
count: tree.items.length,
|
|
12502
12647
|
estimateSize: (index) => getEstimatedRowHeight(tree.items[index].itemId),
|
|
12503
12648
|
getItemKey: (index) => tree.items[index].itemId,
|
|
@@ -12564,12 +12709,12 @@ var VirtualizedLayerTreeItems = ({
|
|
|
12564
12709
|
)
|
|
12565
12710
|
);
|
|
12566
12711
|
}
|
|
12567
|
-
return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("ul", { className:
|
|
12568
|
-
tree.items.length === 0 && /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("div", { className:
|
|
12712
|
+
return /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)("ul", { className: getClassName31(), ref: listRef, children: [
|
|
12713
|
+
tree.items.length === 0 && /* @__PURE__ */ (0, import_jsx_runtime80.jsx)("div", { className: getClassName31("helper"), children: "No items" }),
|
|
12569
12714
|
renderedItems
|
|
12570
12715
|
] });
|
|
12571
|
-
};
|
|
12572
|
-
var LayerTree = ({
|
|
12716
|
+
});
|
|
12717
|
+
var LayerTree = (0, import_react83.memo)(({
|
|
12573
12718
|
selectedId,
|
|
12574
12719
|
selectedPathIds,
|
|
12575
12720
|
trees
|
|
@@ -12584,11 +12729,11 @@ var LayerTree = ({
|
|
|
12584
12729
|
},
|
|
12585
12730
|
tree.zoneCompound
|
|
12586
12731
|
)) });
|
|
12587
|
-
};
|
|
12732
|
+
});
|
|
12588
12733
|
|
|
12589
12734
|
// components/CredBuild/components/Outline/index.tsx
|
|
12590
12735
|
init_store2();
|
|
12591
|
-
var
|
|
12736
|
+
var import_react84 = require("react");
|
|
12592
12737
|
|
|
12593
12738
|
// lib/data/find-zones-for-area.ts
|
|
12594
12739
|
init_react_import();
|
|
@@ -12601,7 +12746,7 @@ var findZonesForArea = (state, area) => {
|
|
|
12601
12746
|
// components/CredBuild/components/Outline/index.tsx
|
|
12602
12747
|
var import_shallow8 = require("zustand/react/shallow");
|
|
12603
12748
|
var import_jsx_runtime81 = require("react/jsx-runtime");
|
|
12604
|
-
var Outline = () => {
|
|
12749
|
+
var Outline = (0, import_react84.memo)(() => {
|
|
12605
12750
|
const outlineOverride = useAppStore((s) => s.overrides.outline);
|
|
12606
12751
|
const config = useAppStore((s) => s.config);
|
|
12607
12752
|
const nodes = useAppStore((s) => s.state.indexes.nodes);
|
|
@@ -12610,13 +12755,13 @@ var Outline = () => {
|
|
|
12610
12755
|
const rootZones = useAppStore(
|
|
12611
12756
|
(0, import_shallow8.useShallow)((s) => findZonesForArea(s.state, "root"))
|
|
12612
12757
|
);
|
|
12613
|
-
const selectedPathIds = (0,
|
|
12758
|
+
const selectedPathIds = (0, import_react84.useMemo)(() => {
|
|
12614
12759
|
const selectedPath = selectedId ? nodes[selectedId]?.path : null;
|
|
12615
12760
|
return new Set(
|
|
12616
12761
|
selectedPath?.map((candidate) => candidate.split(":")[0]).filter(Boolean) || []
|
|
12617
12762
|
);
|
|
12618
12763
|
}, [nodes, selectedId]);
|
|
12619
|
-
const trees = (0,
|
|
12764
|
+
const trees = (0, import_react84.useMemo)(
|
|
12620
12765
|
() => rootZones.map(
|
|
12621
12766
|
(zoneCompound) => buildLayerTree({
|
|
12622
12767
|
config,
|
|
@@ -12628,7 +12773,7 @@ var Outline = () => {
|
|
|
12628
12773
|
),
|
|
12629
12774
|
[config, nodes, rootZones, zones]
|
|
12630
12775
|
);
|
|
12631
|
-
const Wrapper = (0,
|
|
12776
|
+
const Wrapper = (0, import_react84.useMemo)(() => outlineOverride || "div", [outlineOverride]);
|
|
12632
12777
|
return /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(Wrapper, { children: /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(
|
|
12633
12778
|
LayerTree,
|
|
12634
12779
|
{
|
|
@@ -12637,14 +12782,14 @@ var Outline = () => {
|
|
|
12637
12782
|
trees
|
|
12638
12783
|
}
|
|
12639
12784
|
) });
|
|
12640
|
-
};
|
|
12785
|
+
});
|
|
12641
12786
|
|
|
12642
12787
|
// components/CredBuild/index.tsx
|
|
12643
12788
|
init_default_viewports();
|
|
12644
12789
|
|
|
12645
12790
|
// lib/use-loaded-overrides.ts
|
|
12646
12791
|
init_react_import();
|
|
12647
|
-
var
|
|
12792
|
+
var import_react85 = require("react");
|
|
12648
12793
|
|
|
12649
12794
|
// lib/load-overrides.ts
|
|
12650
12795
|
init_react_import();
|
|
@@ -12687,7 +12832,7 @@ var useLoadedOverrides = ({
|
|
|
12687
12832
|
overrides,
|
|
12688
12833
|
plugins
|
|
12689
12834
|
}) => {
|
|
12690
|
-
return (0,
|
|
12835
|
+
return (0, import_react85.useMemo)(() => {
|
|
12691
12836
|
return loadOverrides({ overrides, plugins });
|
|
12692
12837
|
}, [plugins, overrides]);
|
|
12693
12838
|
};
|
|
@@ -12698,7 +12843,7 @@ init_permissions();
|
|
|
12698
12843
|
|
|
12699
12844
|
// lib/use-credbuild.ts
|
|
12700
12845
|
init_react_import();
|
|
12701
|
-
var
|
|
12846
|
+
var import_react86 = require("react");
|
|
12702
12847
|
var import_zustand6 = require("zustand");
|
|
12703
12848
|
init_make_state_public();
|
|
12704
12849
|
init_get_item();
|
|
@@ -12802,7 +12947,7 @@ var generateUseCredBuild = (store, getState) => {
|
|
|
12802
12947
|
};
|
|
12803
12948
|
return storeData;
|
|
12804
12949
|
};
|
|
12805
|
-
var UseCredBuildStoreContext = (0,
|
|
12950
|
+
var UseCredBuildStoreContext = (0, import_react86.createContext)(
|
|
12806
12951
|
null
|
|
12807
12952
|
);
|
|
12808
12953
|
var convertToPickedStore = (store) => {
|
|
@@ -12816,7 +12961,7 @@ var convertToPickedStore = (store) => {
|
|
|
12816
12961
|
};
|
|
12817
12962
|
};
|
|
12818
12963
|
var useRegisterUseCredBuildStore = (appStore) => {
|
|
12819
|
-
const [useCredBuildStore] = (0,
|
|
12964
|
+
const [useCredBuildStore] = (0, import_react86.useState)(
|
|
12820
12965
|
() => (0, import_zustand6.createStore)(
|
|
12821
12966
|
() => generateUseCredBuild(
|
|
12822
12967
|
convertToPickedStore(appStore.getState()),
|
|
@@ -12824,7 +12969,7 @@ var useRegisterUseCredBuildStore = (appStore) => {
|
|
|
12824
12969
|
)
|
|
12825
12970
|
)
|
|
12826
12971
|
);
|
|
12827
|
-
(0,
|
|
12972
|
+
(0, import_react86.useEffect)(() => {
|
|
12828
12973
|
return appStore.subscribe(
|
|
12829
12974
|
(store) => convertToPickedStore(store),
|
|
12830
12975
|
(pickedStore) => {
|
|
@@ -12838,7 +12983,7 @@ var useRegisterUseCredBuildStore = (appStore) => {
|
|
|
12838
12983
|
};
|
|
12839
12984
|
function createUseCredBuild() {
|
|
12840
12985
|
return function useCredBuild2(selector) {
|
|
12841
|
-
const useCredBuildApi = (0,
|
|
12986
|
+
const useCredBuildApi = (0, import_react86.useContext)(UseCredBuildStoreContext);
|
|
12842
12987
|
if (!useCredBuildApi) {
|
|
12843
12988
|
throw new Error("useCredBuild must be used inside <CredBuild>.");
|
|
12844
12989
|
}
|
|
@@ -12850,7 +12995,7 @@ function createUseCredBuild() {
|
|
|
12850
12995
|
};
|
|
12851
12996
|
}
|
|
12852
12997
|
function useCredBuild() {
|
|
12853
|
-
(0,
|
|
12998
|
+
(0, import_react86.useEffect)(() => {
|
|
12854
12999
|
console.warn(
|
|
12855
13000
|
"You're using the `useCredBuild` method without a selector, which may cause unnecessary re-renders. Replace with `createUseCredBuild` and provide a selector for improved performance."
|
|
12856
13001
|
);
|
|
@@ -12858,7 +13003,7 @@ function useCredBuild() {
|
|
|
12858
13003
|
return createUseCredBuild()((s) => s);
|
|
12859
13004
|
}
|
|
12860
13005
|
function useGetCredBuild() {
|
|
12861
|
-
const useCredBuildApi = (0,
|
|
13006
|
+
const useCredBuildApi = (0, import_react86.useContext)(UseCredBuildStoreContext);
|
|
12862
13007
|
if (!useCredBuildApi) {
|
|
12863
13008
|
throw new Error("useCredBuildGet must be used inside <CredBuild>.");
|
|
12864
13009
|
}
|
|
@@ -12873,33 +13018,33 @@ init_to_component();
|
|
|
12873
13018
|
|
|
12874
13019
|
// components/CredBuild/components/Layout/index.tsx
|
|
12875
13020
|
init_react_import();
|
|
12876
|
-
var
|
|
13021
|
+
var import_react100 = require("react");
|
|
12877
13022
|
init_lib();
|
|
12878
13023
|
|
|
12879
13024
|
// components/CredBuild/context.tsx
|
|
12880
13025
|
init_react_import();
|
|
12881
|
-
var
|
|
13026
|
+
var import_react87 = require("react");
|
|
12882
13027
|
var import_jsx_runtime82 = require("react/jsx-runtime");
|
|
12883
|
-
var propsContext = (0,
|
|
13028
|
+
var propsContext = (0, import_react87.createContext)({});
|
|
12884
13029
|
function PropsProvider(props) {
|
|
12885
13030
|
return /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(propsContext.Provider, { value: props, children: props.children });
|
|
12886
13031
|
}
|
|
12887
|
-
var usePropsContext = () => (0,
|
|
13032
|
+
var usePropsContext = () => (0, import_react87.useContext)(propsContext);
|
|
12888
13033
|
|
|
12889
|
-
// css-module:/home/
|
|
13034
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/CredBuild/components/Layout/styles.module.css#css-module
|
|
12890
13035
|
init_react_import();
|
|
12891
|
-
var
|
|
13036
|
+
var styles_module_default23 = { "CredBuildLayout": "_CredBuildLayout_14aaz_1", "CredBuildLayout-inner": "_CredBuildLayout-inner_14aaz_8", "CredBuildLayout--leftSideBarVisible": "_CredBuildLayout--leftSideBarVisible_14aaz_29", "CredBuildLayout--rightSideBarVisible": "_CredBuildLayout--rightSideBarVisible_14aaz_33", "CredBuild--hidePlugins": "_CredBuild--hidePlugins_14aaz_37", "CredBuildLayout-item": "_CredBuildLayout-item_14aaz_43", "CredBuildLayout-header": "_CredBuildLayout-header_14aaz_49", "CredBuildLayout-left": "_CredBuildLayout-left_14aaz_54", "CredBuildLayout-editor": "_CredBuildLayout-editor_14aaz_67", "CredBuildLayout-right": "_CredBuildLayout-right_14aaz_75", "CredBuildLayout-sidebar": "_CredBuildLayout-sidebar_14aaz_92", "CredBuildPluginTab": "_CredBuildPluginTab_14aaz_107", "CredBuildPluginTab--visible": "_CredBuildPluginTab--visible_14aaz_114", "CredBuildPluginTab-body": "_CredBuildPluginTab-body_14aaz_118", "CredBuildLayout--mounted": "_CredBuildLayout--mounted_14aaz_134" };
|
|
12892
13037
|
|
|
12893
13038
|
// lib/use-inject-css.ts
|
|
12894
13039
|
init_react_import();
|
|
12895
|
-
var
|
|
13040
|
+
var import_react88 = require("react");
|
|
12896
13041
|
var styles = ``;
|
|
12897
13042
|
var useInjectStyleSheet = (initialStyles, iframeEnabled) => {
|
|
12898
|
-
const [el, setEl] = (0,
|
|
12899
|
-
(0,
|
|
13043
|
+
const [el, setEl] = (0, import_react88.useState)();
|
|
13044
|
+
(0, import_react88.useEffect)(() => {
|
|
12900
13045
|
setEl(document.createElement("style"));
|
|
12901
13046
|
}, []);
|
|
12902
|
-
(0,
|
|
13047
|
+
(0, import_react88.useEffect)(() => {
|
|
12903
13048
|
if (!el || typeof window === "undefined") {
|
|
12904
13049
|
return;
|
|
12905
13050
|
}
|
|
@@ -12929,12 +13074,12 @@ init_use_hotkey();
|
|
|
12929
13074
|
|
|
12930
13075
|
// lib/use-preview-mode-hotkeys.ts
|
|
12931
13076
|
init_react_import();
|
|
12932
|
-
var
|
|
13077
|
+
var import_react89 = require("react");
|
|
12933
13078
|
init_use_hotkey();
|
|
12934
13079
|
init_store2();
|
|
12935
13080
|
var usePreviewModeHotkeys = () => {
|
|
12936
13081
|
const appStore = useAppStoreApi();
|
|
12937
|
-
const toggleInteractive = (0,
|
|
13082
|
+
const toggleInteractive = (0, import_react89.useCallback)(() => {
|
|
12938
13083
|
const dispatch = appStore.getState().dispatch;
|
|
12939
13084
|
dispatch({
|
|
12940
13085
|
type: "setUi",
|
|
@@ -12949,9 +13094,9 @@ var usePreviewModeHotkeys = () => {
|
|
|
12949
13094
|
|
|
12950
13095
|
// components/DragDropContext/index.tsx
|
|
12951
13096
|
init_react_import();
|
|
12952
|
-
var
|
|
13097
|
+
var import_react90 = require("@dnd-kit/react");
|
|
12953
13098
|
init_store2();
|
|
12954
|
-
var
|
|
13099
|
+
var import_react91 = require("react");
|
|
12955
13100
|
var import_dom = require("@dnd-kit/dom");
|
|
12956
13101
|
init_get_item();
|
|
12957
13102
|
|
|
@@ -13298,8 +13443,8 @@ var import_jsx_runtime84 = require("react/jsx-runtime");
|
|
|
13298
13443
|
var DEBUG3 = false;
|
|
13299
13444
|
var AREA_CHANGE_DEBOUNCE_MS = 100;
|
|
13300
13445
|
var useTempDisableFallback = (timeout3) => {
|
|
13301
|
-
const lastFallbackDisable = (0,
|
|
13302
|
-
return (0,
|
|
13446
|
+
const lastFallbackDisable = (0, import_react91.useRef)(null);
|
|
13447
|
+
return (0, import_react91.useCallback)((manager) => {
|
|
13303
13448
|
collisionStore.setState({ fallbackEnabled: false });
|
|
13304
13449
|
const fallbackId = generateId();
|
|
13305
13450
|
lastFallbackDisable.current = fallbackId;
|
|
@@ -13318,9 +13463,9 @@ var DragDropContextClient = ({
|
|
|
13318
13463
|
const dispatch = useAppStore((s) => s.dispatch);
|
|
13319
13464
|
const instanceId = useAppStore((s) => s.instanceId);
|
|
13320
13465
|
const appStore = useAppStoreApi();
|
|
13321
|
-
const debouncedParamsRef = (0,
|
|
13466
|
+
const debouncedParamsRef = (0, import_react91.useRef)(null);
|
|
13322
13467
|
const tempDisableFallback = useTempDisableFallback(100);
|
|
13323
|
-
const [zoneStore] = (0,
|
|
13468
|
+
const [zoneStore] = (0, import_react91.useState)(() => {
|
|
13324
13469
|
const rootVirtualizers = /* @__PURE__ */ new Map();
|
|
13325
13470
|
return (0, import_zustand7.createStore)(() => ({
|
|
13326
13471
|
zoneDepthIndex: {},
|
|
@@ -13359,7 +13504,7 @@ var DragDropContextClient = ({
|
|
|
13359
13504
|
}
|
|
13360
13505
|
}));
|
|
13361
13506
|
});
|
|
13362
|
-
const getChanged2 = (0,
|
|
13507
|
+
const getChanged2 = (0, import_react91.useCallback)(
|
|
13363
13508
|
(params) => {
|
|
13364
13509
|
const { zoneDepthIndex = {}, areaDepthIndex = {} } = zoneStore.getState() || {};
|
|
13365
13510
|
const stateHasZone = Object.keys(zoneDepthIndex).length > 0;
|
|
@@ -13380,7 +13525,7 @@ var DragDropContextClient = ({
|
|
|
13380
13525
|
},
|
|
13381
13526
|
[zoneStore]
|
|
13382
13527
|
);
|
|
13383
|
-
const setDeepestAndCollide = (0,
|
|
13528
|
+
const setDeepestAndCollide = (0, import_react91.useCallback)(
|
|
13384
13529
|
(params, manager) => {
|
|
13385
13530
|
const { zoneChanged, areaChanged } = getChanged2(params);
|
|
13386
13531
|
if (!zoneChanged && !areaChanged) return;
|
|
@@ -13404,7 +13549,7 @@ var DragDropContextClient = ({
|
|
|
13404
13549
|
setDeepestDb.cancel();
|
|
13405
13550
|
debouncedParamsRef.current = null;
|
|
13406
13551
|
};
|
|
13407
|
-
(0,
|
|
13552
|
+
(0, import_react91.useEffect)(() => {
|
|
13408
13553
|
if (DEBUG3) {
|
|
13409
13554
|
return zoneStore.subscribe(
|
|
13410
13555
|
(s) => console.log(
|
|
@@ -13415,7 +13560,7 @@ var DragDropContextClient = ({
|
|
|
13415
13560
|
);
|
|
13416
13561
|
}
|
|
13417
13562
|
}, [zoneStore]);
|
|
13418
|
-
const [plugins] = (0,
|
|
13563
|
+
const [plugins] = (0, import_react91.useState)(() => [
|
|
13419
13564
|
...disableAutoScroll ? import_dom.defaultPreset.plugins.filter((plugin) => plugin !== import_dom.AutoScroller) : import_dom.defaultPreset.plugins,
|
|
13420
13565
|
createNestedDroppablePlugin(
|
|
13421
13566
|
{
|
|
@@ -13463,10 +13608,10 @@ var DragDropContextClient = ({
|
|
|
13463
13608
|
)
|
|
13464
13609
|
]);
|
|
13465
13610
|
const sensors = useSensors();
|
|
13466
|
-
const [dragListeners, setDragListeners] = (0,
|
|
13467
|
-
const dragMode = (0,
|
|
13468
|
-
const initialSelector = (0,
|
|
13469
|
-
const nextContextValue = (0,
|
|
13611
|
+
const [dragListeners, setDragListeners] = (0, import_react91.useState)({});
|
|
13612
|
+
const dragMode = (0, import_react91.useRef)(null);
|
|
13613
|
+
const initialSelector = (0, import_react91.useRef)(void 0);
|
|
13614
|
+
const nextContextValue = (0, import_react91.useMemo)(
|
|
13470
13615
|
() => ({
|
|
13471
13616
|
mode: "edit",
|
|
13472
13617
|
areaId: "root",
|
|
@@ -13482,7 +13627,7 @@ var DragDropContextClient = ({
|
|
|
13482
13627
|
setDragListeners
|
|
13483
13628
|
},
|
|
13484
13629
|
children: /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
|
|
13485
|
-
|
|
13630
|
+
import_react90.DragDropProvider,
|
|
13486
13631
|
{
|
|
13487
13632
|
plugins,
|
|
13488
13633
|
sensors,
|
|
@@ -13722,7 +13867,7 @@ var DragDropContext = ({
|
|
|
13722
13867
|
|
|
13723
13868
|
// components/CredBuild/components/Header/index.tsx
|
|
13724
13869
|
init_react_import();
|
|
13725
|
-
var
|
|
13870
|
+
var import_react94 = require("react");
|
|
13726
13871
|
init_store2();
|
|
13727
13872
|
init_lucide_react();
|
|
13728
13873
|
init_Heading();
|
|
@@ -13734,14 +13879,14 @@ init_lucide_react();
|
|
|
13734
13879
|
init_IconButton();
|
|
13735
13880
|
init_get_class_name_factory();
|
|
13736
13881
|
|
|
13737
|
-
// css-module:/home/
|
|
13882
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/MenuBar/styles.module.css#css-module
|
|
13738
13883
|
init_react_import();
|
|
13739
|
-
var
|
|
13884
|
+
var styles_module_default24 = { "MenuBar": "_MenuBar_1m2ld_1", "MenuBar--menuOpen": "_MenuBar--menuOpen_1m2ld_14", "MenuBar-inner": "_MenuBar-inner_1m2ld_29", "MenuBar-history": "_MenuBar-history_1m2ld_45" };
|
|
13740
13885
|
|
|
13741
13886
|
// components/MenuBar/index.tsx
|
|
13742
13887
|
init_store2();
|
|
13743
13888
|
var import_jsx_runtime85 = require("react/jsx-runtime");
|
|
13744
|
-
var
|
|
13889
|
+
var getClassName32 = get_class_name_factory_default("MenuBar", styles_module_default24);
|
|
13745
13890
|
function MenuBar({
|
|
13746
13891
|
menuOpen = false,
|
|
13747
13892
|
renderHeaderActions,
|
|
@@ -13754,7 +13899,7 @@ function MenuBar({
|
|
|
13754
13899
|
return /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
|
|
13755
13900
|
"div",
|
|
13756
13901
|
{
|
|
13757
|
-
className:
|
|
13902
|
+
className: getClassName32({ menuOpen }),
|
|
13758
13903
|
onClick: (event) => {
|
|
13759
13904
|
const element = event.target;
|
|
13760
13905
|
if (window.matchMedia("(min-width: 638px)").matches) {
|
|
@@ -13764,8 +13909,8 @@ function MenuBar({
|
|
|
13764
13909
|
setMenuOpen(false);
|
|
13765
13910
|
}
|
|
13766
13911
|
},
|
|
13767
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime85.jsxs)("div", { className:
|
|
13768
|
-
/* @__PURE__ */ (0, import_jsx_runtime85.jsxs)("div", { className:
|
|
13912
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime85.jsxs)("div", { className: getClassName32("inner"), children: [
|
|
13913
|
+
/* @__PURE__ */ (0, import_jsx_runtime85.jsxs)("div", { className: getClassName32("history"), children: [
|
|
13769
13914
|
/* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
|
|
13770
13915
|
IconButton,
|
|
13771
13916
|
{
|
|
@@ -13802,12 +13947,12 @@ init_react_import();
|
|
|
13802
13947
|
init_lucide_react();
|
|
13803
13948
|
init_IconButton2();
|
|
13804
13949
|
init_store2();
|
|
13805
|
-
var
|
|
13950
|
+
var import_react92 = require("react");
|
|
13806
13951
|
init_lib();
|
|
13807
13952
|
|
|
13808
|
-
// css-module:/home/
|
|
13953
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/ViewportControls/styles.module.css#css-module
|
|
13809
13954
|
init_react_import();
|
|
13810
|
-
var
|
|
13955
|
+
var styles_module_default25 = { "ViewportControls": "_ViewportControls_gefvg_1", "ViewportControls--fullScreen": "_ViewportControls--fullScreen_gefvg_5", "ViewportControls-toggleButton": "_ViewportControls-toggleButton_gefvg_14", "ViewportControls--isExpanded": "_ViewportControls--isExpanded_gefvg_38", "ViewportControls-actions": "_ViewportControls-actions_gefvg_42", "ViewportControls-actionsInner": "_ViewportControls-actionsInner_gefvg_46", "ViewportControls-divider": "_ViewportControls-divider_gefvg_76", "ViewportControls-zoomSelect": "_ViewportControls-zoomSelect_gefvg_83", "ViewportControls-zoom": "_ViewportControls-zoom_gefvg_83", "ViewportButton-inner": "_ViewportButton-inner_gefvg_114", "ViewportButton--isActive": "_ViewportButton--isActive_gefvg_122" };
|
|
13811
13956
|
|
|
13812
13957
|
// components/ViewportControls/index.tsx
|
|
13813
13958
|
var import_jsx_runtime86 = require("react/jsx-runtime");
|
|
@@ -13817,8 +13962,8 @@ var icons = {
|
|
|
13817
13962
|
Monitor: /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(Monitor, { size: 16 }),
|
|
13818
13963
|
FullWidth: /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(Expand, { size: 16 })
|
|
13819
13964
|
};
|
|
13820
|
-
var
|
|
13821
|
-
var getClassNameButton = get_class_name_factory_default("ViewportButton",
|
|
13965
|
+
var getClassName33 = get_class_name_factory_default("ViewportControls", styles_module_default25);
|
|
13966
|
+
var getClassNameButton = get_class_name_factory_default("ViewportButton", styles_module_default25);
|
|
13822
13967
|
var ActionButton = ({
|
|
13823
13968
|
children,
|
|
13824
13969
|
title,
|
|
@@ -13859,7 +14004,7 @@ var ViewportControls = ({
|
|
|
13859
14004
|
const defaultsContainAutoZoom = defaultZoomOptions.find(
|
|
13860
14005
|
(option) => option.value === autoZoom
|
|
13861
14006
|
);
|
|
13862
|
-
const zoomOptions = (0,
|
|
14007
|
+
const zoomOptions = (0, import_react92.useMemo)(() => {
|
|
13863
14008
|
const options = [
|
|
13864
14009
|
...defaultZoomOptions,
|
|
13865
14010
|
...defaultsContainAutoZoom || isNaN(autoZoom) ? [] : [
|
|
@@ -13871,20 +14016,20 @@ var ViewportControls = ({
|
|
|
13871
14016
|
].filter((a) => a.value <= (autoZoom || 1)).sort((a, b) => a.value > b.value ? 1 : -1);
|
|
13872
14017
|
return options.length > 0 ? options : defaultZoomOptions;
|
|
13873
14018
|
}, [autoZoom, defaultsContainAutoZoom]);
|
|
13874
|
-
const [activeViewport, setActiveViewport] = (0,
|
|
14019
|
+
const [activeViewport, setActiveViewport] = (0, import_react92.useState)(
|
|
13875
14020
|
uiViewports.current.width
|
|
13876
14021
|
);
|
|
13877
|
-
(0,
|
|
14022
|
+
(0, import_react92.useEffect)(() => {
|
|
13878
14023
|
setActiveViewport(uiViewports.current.width);
|
|
13879
14024
|
}, [uiViewports.current.width, uiViewports]);
|
|
13880
|
-
const [isExpanded, setIsExpanded] = (0,
|
|
14025
|
+
const [isExpanded, setIsExpanded] = (0, import_react92.useState)(false);
|
|
13881
14026
|
return /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)(
|
|
13882
14027
|
"div",
|
|
13883
14028
|
{
|
|
13884
|
-
className:
|
|
14029
|
+
className: getClassName33({ isExpanded, fullScreen }),
|
|
13885
14030
|
suppressHydrationWarning: true,
|
|
13886
14031
|
children: [
|
|
13887
|
-
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("div", { className:
|
|
14032
|
+
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("div", { className: getClassName33("actions"), children: /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)("div", { className: getClassName33("actionsInner"), children: [
|
|
13888
14033
|
viewports.map((viewport, i) => /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
|
|
13889
14034
|
ActionButton,
|
|
13890
14035
|
{
|
|
@@ -13898,7 +14043,7 @@ var ViewportControls = ({
|
|
|
13898
14043
|
},
|
|
13899
14044
|
i
|
|
13900
14045
|
)),
|
|
13901
|
-
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("div", { className:
|
|
14046
|
+
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("div", { className: getClassName33("divider") }),
|
|
13902
14047
|
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
|
|
13903
14048
|
ActionButton,
|
|
13904
14049
|
{
|
|
@@ -13933,12 +14078,12 @@ var ViewportControls = ({
|
|
|
13933
14078
|
children: /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(ZoomIn, { size: 16 })
|
|
13934
14079
|
}
|
|
13935
14080
|
),
|
|
13936
|
-
/* @__PURE__ */ (0, import_jsx_runtime86.jsxs)("div", { className:
|
|
13937
|
-
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("div", { className:
|
|
14081
|
+
/* @__PURE__ */ (0, import_jsx_runtime86.jsxs)("div", { className: getClassName33("zoom"), children: [
|
|
14082
|
+
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("div", { className: getClassName33("divider") }),
|
|
13938
14083
|
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
|
|
13939
14084
|
"select",
|
|
13940
14085
|
{
|
|
13941
|
-
className:
|
|
14086
|
+
className: getClassName33("zoomSelect"),
|
|
13942
14087
|
value: zoom.toString(),
|
|
13943
14088
|
onClick: (e) => {
|
|
13944
14089
|
e.stopPropagation();
|
|
@@ -13961,8 +14106,9 @@ var ViewportControls = ({
|
|
|
13961
14106
|
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
|
|
13962
14107
|
"button",
|
|
13963
14108
|
{
|
|
13964
|
-
className:
|
|
14109
|
+
className: getClassName33("toggleButton"),
|
|
13965
14110
|
title: "Toggle viewport menu",
|
|
14111
|
+
"aria-expanded": isExpanded,
|
|
13966
14112
|
onClick: () => setIsExpanded((s) => !s),
|
|
13967
14113
|
children: isExpanded ? /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(X, { size: 16 }) : /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(Monitor, { size: 16 })
|
|
13968
14114
|
}
|
|
@@ -13977,14 +14123,14 @@ var import_shallow9 = require("zustand/react/shallow");
|
|
|
13977
14123
|
|
|
13978
14124
|
// lib/frame-context.tsx
|
|
13979
14125
|
init_react_import();
|
|
13980
|
-
var
|
|
14126
|
+
var import_react93 = require("react");
|
|
13981
14127
|
var import_jsx_runtime87 = require("react/jsx-runtime");
|
|
13982
|
-
var FrameContext = (0,
|
|
14128
|
+
var FrameContext = (0, import_react93.createContext)(null);
|
|
13983
14129
|
var FrameProvider = ({
|
|
13984
14130
|
children
|
|
13985
14131
|
}) => {
|
|
13986
|
-
const frameRef = (0,
|
|
13987
|
-
const value = (0,
|
|
14132
|
+
const frameRef = (0, import_react93.useRef)(null);
|
|
14133
|
+
const value = (0, import_react93.useMemo)(
|
|
13988
14134
|
() => ({
|
|
13989
14135
|
frameRef
|
|
13990
14136
|
}),
|
|
@@ -13993,20 +14139,20 @@ var FrameProvider = ({
|
|
|
13993
14139
|
return /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(FrameContext.Provider, { value, children });
|
|
13994
14140
|
};
|
|
13995
14141
|
var useCanvasFrame = () => {
|
|
13996
|
-
const context = (0,
|
|
14142
|
+
const context = (0, import_react93.useContext)(FrameContext);
|
|
13997
14143
|
if (context === null) {
|
|
13998
14144
|
throw new Error("useCanvasFrame must be used within a FrameProvider");
|
|
13999
14145
|
}
|
|
14000
14146
|
return context;
|
|
14001
14147
|
};
|
|
14002
14148
|
|
|
14003
|
-
// css-module:/home/
|
|
14149
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/CredBuild/components/Header/styles.module.css#css-module
|
|
14004
14150
|
init_react_import();
|
|
14005
|
-
var
|
|
14151
|
+
var styles_module_default26 = { "CredBuildHeader": "_CredBuildHeader_qzv5u_1", "CredBuildHeader-inner": "_CredBuildHeader-inner_qzv5u_20", "CredBuildHeader-viewportTools": "_CredBuildHeader-viewportTools_qzv5u_28", "CredBuildHeader-leftActions": "_CredBuildHeader-leftActions_qzv5u_35", "CredBuildHeader-toggle": "_CredBuildHeader-toggle_qzv5u_41", "CredBuildHeader-leftSideBarToggle": "_CredBuildHeader-leftSideBarToggle_qzv5u_47", "CredBuildHeader-rightSideBarToggle": "_CredBuildHeader-rightSideBarToggle_qzv5u_48", "CredBuildHeader-title": "_CredBuildHeader-title_qzv5u_52", "CredBuildHeader-path": "_CredBuildHeader-path_qzv5u_57", "CredBuildHeader-tools": "_CredBuildHeader-tools_qzv5u_68", "CredBuildHeader-menuButton": "_CredBuildHeader-menuButton_qzv5u_75" };
|
|
14006
14152
|
|
|
14007
14153
|
// components/CredBuild/components/Header/index.tsx
|
|
14008
14154
|
var import_jsx_runtime88 = require("react/jsx-runtime");
|
|
14009
|
-
var
|
|
14155
|
+
var getClassName34 = get_class_name_factory_default("CredBuildHeader", styles_module_default26);
|
|
14010
14156
|
var HeaderInner = ({
|
|
14011
14157
|
hidePlugins,
|
|
14012
14158
|
theme
|
|
@@ -14021,7 +14167,7 @@ var HeaderInner = ({
|
|
|
14021
14167
|
} = usePropsContext();
|
|
14022
14168
|
const dispatch = useAppStore((s) => s.dispatch);
|
|
14023
14169
|
const appStore = useAppStoreApi();
|
|
14024
|
-
const defaultHeaderRender = (0,
|
|
14170
|
+
const defaultHeaderRender = (0, import_react94.useMemo)(() => {
|
|
14025
14171
|
if (renderHeader) {
|
|
14026
14172
|
console.warn(
|
|
14027
14173
|
"`renderHeader` is deprecated. Please use `overrides.header` and the `useCredBuild` hook instead"
|
|
@@ -14035,7 +14181,7 @@ var HeaderInner = ({
|
|
|
14035
14181
|
}
|
|
14036
14182
|
return DefaultOverride;
|
|
14037
14183
|
}, [renderHeader, dispatch]);
|
|
14038
|
-
const defaultHeaderActionsRender = (0,
|
|
14184
|
+
const defaultHeaderActionsRender = (0, import_react94.useMemo)(() => {
|
|
14039
14185
|
if (renderHeaderActions) {
|
|
14040
14186
|
console.warn(
|
|
14041
14187
|
"`renderHeaderActions` is deprecated. Please use `overrides.headerActions` and the `useCredBuild` hook instead."
|
|
@@ -14055,7 +14201,7 @@ var HeaderInner = ({
|
|
|
14055
14201
|
const CustomHeaderActions = useAppStore(
|
|
14056
14202
|
(s) => s.overrides.headerActions || defaultHeaderActionsRender
|
|
14057
14203
|
);
|
|
14058
|
-
const [menuOpen, setMenuOpen] = (0,
|
|
14204
|
+
const [menuOpen, setMenuOpen] = (0, import_react94.useState)(false);
|
|
14059
14205
|
const rootTitle = useAppStore((s) => {
|
|
14060
14206
|
const rootData = s.state.indexes.nodes["root"]?.data;
|
|
14061
14207
|
return rootData.props.title ?? "";
|
|
@@ -14084,7 +14230,7 @@ var HeaderInner = ({
|
|
|
14084
14230
|
);
|
|
14085
14231
|
const { frameRef } = useCanvasFrame();
|
|
14086
14232
|
const resetAutoZoom = useResetAutoZoom(frameRef);
|
|
14087
|
-
const toggleSidebars = (0,
|
|
14233
|
+
const toggleSidebars = (0, import_react94.useCallback)(
|
|
14088
14234
|
(sidebar) => {
|
|
14089
14235
|
const widerViewport = window.matchMedia("(min-width: 638px)").matches;
|
|
14090
14236
|
const sideBarVisible = sidebar === "left" ? leftSideBarVisible : rightSideBarVisible;
|
|
@@ -14128,13 +14274,13 @@ var HeaderInner = ({
|
|
|
14128
14274
|
children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
14129
14275
|
"header",
|
|
14130
14276
|
{
|
|
14131
|
-
className:
|
|
14277
|
+
className: getClassName34({
|
|
14132
14278
|
leftSideBarVisible,
|
|
14133
14279
|
rightSideBarVisible,
|
|
14134
14280
|
hidePlugins
|
|
14135
14281
|
}),
|
|
14136
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime88.jsxs)("div", { className:
|
|
14137
|
-
/* @__PURE__ */ (0, import_jsx_runtime88.jsxs)("div", { className:
|
|
14282
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime88.jsxs)("div", { className: getClassName34("inner"), children: [
|
|
14283
|
+
/* @__PURE__ */ (0, import_jsx_runtime88.jsxs)("div", { className: getClassName34("leftActions"), children: [
|
|
14138
14284
|
/* @__PURE__ */ (0, import_jsx_runtime88.jsxs)("div", { style: { marginRight: "8px", display: "flex", gap: "8px", alignItems: "center" }, children: [
|
|
14139
14285
|
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
14140
14286
|
Button,
|
|
@@ -14168,8 +14314,8 @@ var HeaderInner = ({
|
|
|
14168
14314
|
}
|
|
14169
14315
|
)
|
|
14170
14316
|
] }),
|
|
14171
|
-
/* @__PURE__ */ (0, import_jsx_runtime88.jsxs)("div", { className:
|
|
14172
|
-
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)("div", { className:
|
|
14317
|
+
/* @__PURE__ */ (0, import_jsx_runtime88.jsxs)("div", { className: getClassName34("toggle"), children: [
|
|
14318
|
+
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)("div", { className: getClassName34("leftSideBarToggle"), children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
14173
14319
|
IconButton,
|
|
14174
14320
|
{
|
|
14175
14321
|
type: "button",
|
|
@@ -14180,7 +14326,7 @@ var HeaderInner = ({
|
|
|
14180
14326
|
children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(PanelLeft, { size: 16, focusable: "false" })
|
|
14181
14327
|
}
|
|
14182
14328
|
) }),
|
|
14183
|
-
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)("div", { className:
|
|
14329
|
+
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)("div", { className: getClassName34("rightSideBarToggle"), children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
14184
14330
|
IconButton,
|
|
14185
14331
|
{
|
|
14186
14332
|
type: "button",
|
|
@@ -14192,12 +14338,12 @@ var HeaderInner = ({
|
|
|
14192
14338
|
}
|
|
14193
14339
|
) })
|
|
14194
14340
|
] }),
|
|
14195
|
-
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)("div", { className:
|
|
14341
|
+
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)("div", { className: getClassName34("title"), children: /* @__PURE__ */ (0, import_jsx_runtime88.jsxs)(Heading7, { rank: "2", size: "xs", children: [
|
|
14196
14342
|
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)("span", { style: { fontSize: "11px", textTransform: "uppercase", letterSpacing: "0.08em", fontWeight: 600 }, children: headerTitle || rootTitle || "Page" }),
|
|
14197
|
-
headerPath && /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(import_jsx_runtime88.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)("code", { className:
|
|
14343
|
+
headerPath && /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(import_jsx_runtime88.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)("code", { className: getClassName34("path"), style: { fontSize: "10px", opacity: 0.6, marginLeft: "8px" }, children: headerPath }) })
|
|
14198
14344
|
] }) })
|
|
14199
14345
|
] }),
|
|
14200
|
-
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)("div", { className:
|
|
14346
|
+
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)("div", { className: getClassName34("viewportTools"), children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
14201
14347
|
ViewportControls,
|
|
14202
14348
|
{
|
|
14203
14349
|
fullScreen: _experimentalFullScreenCanvas,
|
|
@@ -14223,8 +14369,8 @@ var HeaderInner = ({
|
|
|
14223
14369
|
}
|
|
14224
14370
|
}
|
|
14225
14371
|
) }),
|
|
14226
|
-
/* @__PURE__ */ (0, import_jsx_runtime88.jsxs)("div", { className:
|
|
14227
|
-
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)("div", { className:
|
|
14372
|
+
/* @__PURE__ */ (0, import_jsx_runtime88.jsxs)("div", { className: getClassName34("tools"), children: [
|
|
14373
|
+
/* @__PURE__ */ (0, import_jsx_runtime88.jsx)("div", { className: getClassName34("menuButton"), children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(
|
|
14228
14374
|
IconButton,
|
|
14229
14375
|
{
|
|
14230
14376
|
type: "button",
|
|
@@ -14274,14 +14420,14 @@ var HeaderInner = ({
|
|
|
14274
14420
|
}
|
|
14275
14421
|
);
|
|
14276
14422
|
};
|
|
14277
|
-
var Header = (0,
|
|
14423
|
+
var Header = (0, import_react94.memo)(HeaderInner);
|
|
14278
14424
|
|
|
14279
14425
|
// components/SidebarSection/index.tsx
|
|
14280
14426
|
init_react_import();
|
|
14281
14427
|
|
|
14282
|
-
// css-module:/home/
|
|
14428
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/SidebarSection/styles.module.css#css-module
|
|
14283
14429
|
init_react_import();
|
|
14284
|
-
var
|
|
14430
|
+
var styles_module_default27 = { "SidebarSection": "_SidebarSection_1w6vl_1", "SidebarSection-title": "_SidebarSection-title_1w6vl_12", "SidebarSection--noBorderTop": "_SidebarSection--noBorderTop_1w6vl_38", "SidebarSection-content": "_SidebarSection-content_1w6vl_42", "SidebarSection-breadcrumbLabel": "_SidebarSection-breadcrumbLabel_1w6vl_51", "SidebarSection-breadcrumbs": "_SidebarSection-breadcrumbs_1w6vl_80", "SidebarSection-breadcrumb": "_SidebarSection-breadcrumb_1w6vl_51", "SidebarSection-heading": "_SidebarSection-heading_1w6vl_92", "SidebarSection-loadingOverlay": "_SidebarSection-loadingOverlay_1w6vl_96" };
|
|
14285
14431
|
|
|
14286
14432
|
// components/SidebarSection/index.tsx
|
|
14287
14433
|
init_get_class_name_factory();
|
|
@@ -14291,9 +14437,9 @@ init_Loader();
|
|
|
14291
14437
|
// components/Breadcrumbs/index.tsx
|
|
14292
14438
|
init_react_import();
|
|
14293
14439
|
|
|
14294
|
-
// css-module:/home/
|
|
14440
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/Breadcrumbs/styles.module.css#css-module
|
|
14295
14441
|
init_react_import();
|
|
14296
|
-
var
|
|
14442
|
+
var styles_module_default28 = { "Breadcrumbs": "_Breadcrumbs_1e0gb_1", "Breadcrumbs-breadcrumbLabel": "_Breadcrumbs-breadcrumbLabel_1e0gb_7", "Breadcrumbs-breadcrumb": "_Breadcrumbs-breadcrumb_1e0gb_7" };
|
|
14297
14443
|
|
|
14298
14444
|
// components/Breadcrumbs/index.tsx
|
|
14299
14445
|
init_get_class_name_factory();
|
|
@@ -14301,14 +14447,14 @@ init_lucide_react();
|
|
|
14301
14447
|
|
|
14302
14448
|
// lib/use-breadcrumbs.ts
|
|
14303
14449
|
init_react_import();
|
|
14304
|
-
var
|
|
14450
|
+
var import_react95 = require("react");
|
|
14305
14451
|
init_store2();
|
|
14306
14452
|
var useBreadcrumbs = (renderCount) => {
|
|
14307
14453
|
const selectedId = useAppStore((s) => s.selectedItem?.props.id);
|
|
14308
14454
|
const config = useAppStore((s) => s.config);
|
|
14309
14455
|
const path = useAppStore((s) => s.state.indexes.nodes[selectedId]?.path);
|
|
14310
14456
|
const appStore = useAppStoreApi();
|
|
14311
|
-
return (0,
|
|
14457
|
+
return (0, import_react95.useMemo)(() => {
|
|
14312
14458
|
const breadcrumbs = path?.map((zoneCompound) => {
|
|
14313
14459
|
const [componentId] = zoneCompound.split(":");
|
|
14314
14460
|
if (componentId === "root") {
|
|
@@ -14340,20 +14486,20 @@ var useBreadcrumbs = (renderCount) => {
|
|
|
14340
14486
|
// components/Breadcrumbs/index.tsx
|
|
14341
14487
|
init_store2();
|
|
14342
14488
|
var import_jsx_runtime89 = require("react/jsx-runtime");
|
|
14343
|
-
var
|
|
14489
|
+
var getClassName35 = get_class_name_factory_default("Breadcrumbs", styles_module_default28);
|
|
14344
14490
|
var Breadcrumbs = ({
|
|
14345
14491
|
children,
|
|
14346
14492
|
numParents = 1
|
|
14347
14493
|
}) => {
|
|
14348
14494
|
const setUi = useAppStore((s) => s.setUi);
|
|
14349
14495
|
const breadcrumbs = useBreadcrumbs(numParents);
|
|
14350
|
-
return /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { className:
|
|
14351
|
-
breadcrumbs.map((breadcrumb, i) => /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { className:
|
|
14496
|
+
return /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { className: getClassName35(), children: [
|
|
14497
|
+
breadcrumbs.map((breadcrumb, i) => /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { className: getClassName35("breadcrumb"), children: [
|
|
14352
14498
|
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
|
|
14353
14499
|
"button",
|
|
14354
14500
|
{
|
|
14355
14501
|
type: "button",
|
|
14356
|
-
className:
|
|
14502
|
+
className: getClassName35("breadcrumbLabel"),
|
|
14357
14503
|
onClick: () => setUi({ itemSelector: breadcrumb.selector }),
|
|
14358
14504
|
children: breadcrumb.label
|
|
14359
14505
|
}
|
|
@@ -14366,7 +14512,7 @@ var Breadcrumbs = ({
|
|
|
14366
14512
|
|
|
14367
14513
|
// components/SidebarSection/index.tsx
|
|
14368
14514
|
var import_jsx_runtime90 = require("react/jsx-runtime");
|
|
14369
|
-
var
|
|
14515
|
+
var getClassName36 = get_class_name_factory_default("SidebarSection", styles_module_default27);
|
|
14370
14516
|
var SidebarSection = ({
|
|
14371
14517
|
children,
|
|
14372
14518
|
title,
|
|
@@ -14375,25 +14521,25 @@ var SidebarSection = ({
|
|
|
14375
14521
|
noBorderTop,
|
|
14376
14522
|
isLoading
|
|
14377
14523
|
}) => {
|
|
14378
|
-
return /* @__PURE__ */ (0, import_jsx_runtime90.jsxs)("div", { className:
|
|
14379
|
-
/* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { className:
|
|
14524
|
+
return /* @__PURE__ */ (0, import_jsx_runtime90.jsxs)("div", { className: getClassName36({ noBorderTop }), style: { background }, children: [
|
|
14525
|
+
/* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { className: getClassName36("title"), children: /* @__PURE__ */ (0, import_jsx_runtime90.jsxs)("div", { className: getClassName36("breadcrumbs"), children: [
|
|
14380
14526
|
showBreadcrumbs && /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(Breadcrumbs, {}),
|
|
14381
|
-
/* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { className:
|
|
14527
|
+
/* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { className: getClassName36("heading"), children: /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(Heading7, { rank: "2", size: "xs", children: title }) })
|
|
14382
14528
|
] }) }),
|
|
14383
|
-
/* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { className:
|
|
14384
|
-
isLoading && /* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { className:
|
|
14529
|
+
/* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { className: getClassName36("content"), children }),
|
|
14530
|
+
isLoading && /* @__PURE__ */ (0, import_jsx_runtime90.jsx)("div", { className: getClassName36("loadingOverlay"), children: /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(Loader, { size: 32 }) })
|
|
14385
14531
|
] });
|
|
14386
14532
|
};
|
|
14387
14533
|
|
|
14388
14534
|
// components/CredBuild/components/Canvas/index.tsx
|
|
14389
14535
|
init_react_import();
|
|
14390
14536
|
init_css_box_model_esm();
|
|
14391
|
-
var
|
|
14537
|
+
var import_react96 = require("react");
|
|
14392
14538
|
init_store2();
|
|
14393
14539
|
|
|
14394
|
-
// css-module:/home/
|
|
14540
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/CredBuild/components/Canvas/styles.module.css#css-module
|
|
14395
14541
|
init_react_import();
|
|
14396
|
-
var
|
|
14542
|
+
var styles_module_default29 = { "CredBuildCanvas": "_CredBuildCanvas_1ivia_1", "CredBuildCanvas--fullScreen": "_CredBuildCanvas--fullScreen_1ivia_22", "CredBuildCanvas-inner": "_CredBuildCanvas-inner_1ivia_33", "CredBuildCanvas-root": "_CredBuildCanvas-root_1ivia_42", "CredBuildCanvas--ready": "_CredBuildCanvas--ready_1ivia_67", "CredBuildCanvas-loader": "_CredBuildCanvas-loader_1ivia_72", "CredBuildCanvas--showLoader": "_CredBuildCanvas--showLoader_1ivia_82" };
|
|
14397
14543
|
|
|
14398
14544
|
// components/CredBuild/components/Canvas/index.tsx
|
|
14399
14545
|
init_lib();
|
|
@@ -14401,7 +14547,7 @@ init_Loader();
|
|
|
14401
14547
|
var import_shallow10 = require("zustand/react/shallow");
|
|
14402
14548
|
init_default_viewports();
|
|
14403
14549
|
var import_jsx_runtime91 = require("react/jsx-runtime");
|
|
14404
|
-
var
|
|
14550
|
+
var getClassName37 = get_class_name_factory_default("CredBuildCanvas", styles_module_default29);
|
|
14405
14551
|
var ZOOM_ON_CHANGE = true;
|
|
14406
14552
|
var TRANSITION_DURATION = 150;
|
|
14407
14553
|
var Canvas = () => {
|
|
@@ -14444,17 +14590,17 @@ var Canvas = () => {
|
|
|
14444
14590
|
viewports: s.state.ui.viewports
|
|
14445
14591
|
}))
|
|
14446
14592
|
);
|
|
14447
|
-
const [showTransition, setShowTransition] = (0,
|
|
14448
|
-
const isResizingRef = (0,
|
|
14449
|
-
const defaultRender = (0,
|
|
14593
|
+
const [showTransition, setShowTransition] = (0, import_react96.useState)(false);
|
|
14594
|
+
const isResizingRef = (0, import_react96.useRef)(false);
|
|
14595
|
+
const defaultRender = (0, import_react96.useMemo)(() => {
|
|
14450
14596
|
const CredBuildDefault = ({ children }) => /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(import_jsx_runtime91.Fragment, { children });
|
|
14451
14597
|
return CredBuildDefault;
|
|
14452
14598
|
}, []);
|
|
14453
|
-
const CustomPreview = (0,
|
|
14599
|
+
const CustomPreview = (0, import_react96.useMemo)(
|
|
14454
14600
|
() => overrides.preview || defaultRender,
|
|
14455
14601
|
[overrides, defaultRender]
|
|
14456
14602
|
);
|
|
14457
|
-
const getFrameDimensions = (0,
|
|
14603
|
+
const getFrameDimensions = (0, import_react96.useCallback)(() => {
|
|
14458
14604
|
if (frameRef.current) {
|
|
14459
14605
|
const frame = frameRef.current;
|
|
14460
14606
|
const box = getBox(frame);
|
|
@@ -14462,7 +14608,7 @@ var Canvas = () => {
|
|
|
14462
14608
|
}
|
|
14463
14609
|
return { width: 0, height: 0 };
|
|
14464
14610
|
}, [frameRef]);
|
|
14465
|
-
(0,
|
|
14611
|
+
(0, import_react96.useEffect)(() => {
|
|
14466
14612
|
resetAutoZoom();
|
|
14467
14613
|
}, [
|
|
14468
14614
|
frameRef,
|
|
@@ -14472,7 +14618,7 @@ var Canvas = () => {
|
|
|
14472
14618
|
viewports,
|
|
14473
14619
|
resetAutoZoom
|
|
14474
14620
|
]);
|
|
14475
|
-
(0,
|
|
14621
|
+
(0, import_react96.useEffect)(() => {
|
|
14476
14622
|
const { height: frameHeight } = getFrameDimensions();
|
|
14477
14623
|
if (viewports.current.height === "auto") {
|
|
14478
14624
|
const newRootHeight = frameHeight / zoomConfig.zoom;
|
|
@@ -14490,12 +14636,12 @@ var Canvas = () => {
|
|
|
14490
14636
|
viewports,
|
|
14491
14637
|
zoomConfig.rootHeight
|
|
14492
14638
|
]);
|
|
14493
|
-
(0,
|
|
14639
|
+
(0, import_react96.useEffect)(() => {
|
|
14494
14640
|
if (ZOOM_ON_CHANGE) {
|
|
14495
14641
|
resetAutoZoom();
|
|
14496
14642
|
}
|
|
14497
14643
|
}, [viewports.current.width, viewports, resetAutoZoom]);
|
|
14498
|
-
(0,
|
|
14644
|
+
(0, import_react96.useEffect)(() => {
|
|
14499
14645
|
if (!frameRef.current) return;
|
|
14500
14646
|
const resizeObserver = new ResizeObserver(() => {
|
|
14501
14647
|
if (!isResizingRef.current) {
|
|
@@ -14507,14 +14653,14 @@ var Canvas = () => {
|
|
|
14507
14653
|
resizeObserver.disconnect();
|
|
14508
14654
|
};
|
|
14509
14655
|
}, [frameRef, resetAutoZoom]);
|
|
14510
|
-
const [showLoader, setShowLoader] = (0,
|
|
14511
|
-
(0,
|
|
14656
|
+
const [showLoader, setShowLoader] = (0, import_react96.useState)(false);
|
|
14657
|
+
(0, import_react96.useEffect)(() => {
|
|
14512
14658
|
setTimeout(() => {
|
|
14513
14659
|
setShowLoader(true);
|
|
14514
14660
|
}, 500);
|
|
14515
14661
|
}, []);
|
|
14516
14662
|
const appStoreApi = useAppStoreApi();
|
|
14517
|
-
(0,
|
|
14663
|
+
(0, import_react96.useEffect)(() => {
|
|
14518
14664
|
if (typeof window === "undefined") return;
|
|
14519
14665
|
if (uiProp?.viewports?.current) return;
|
|
14520
14666
|
const viewportWidth = window.innerWidth;
|
|
@@ -14571,7 +14717,7 @@ var Canvas = () => {
|
|
|
14571
14717
|
return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
14572
14718
|
"div",
|
|
14573
14719
|
{
|
|
14574
|
-
className:
|
|
14720
|
+
className: getClassName37({
|
|
14575
14721
|
ready: status === "READY" || !iframe.enabled || !iframe.waitForStyles,
|
|
14576
14722
|
showLoader,
|
|
14577
14723
|
fullScreen: _experimentalFullScreenCanvas
|
|
@@ -14586,11 +14732,11 @@ var Canvas = () => {
|
|
|
14586
14732
|
});
|
|
14587
14733
|
}
|
|
14588
14734
|
},
|
|
14589
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { className:
|
|
14735
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)("div", { className: getClassName37("inner"), ref: frameRef, children: [
|
|
14590
14736
|
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)(
|
|
14591
14737
|
"div",
|
|
14592
14738
|
{
|
|
14593
|
-
className:
|
|
14739
|
+
className: getClassName37("root"),
|
|
14594
14740
|
style: {
|
|
14595
14741
|
width: iframe.enabled ? viewports.current.width : "100%",
|
|
14596
14742
|
height: !zoomConfig.rootHeight || isNaN(zoomConfig.rootHeight) ? "100%" : zoomConfig.rootHeight,
|
|
@@ -14608,7 +14754,7 @@ var Canvas = () => {
|
|
|
14608
14754
|
children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(CustomPreview, { children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Preview, {}) })
|
|
14609
14755
|
}
|
|
14610
14756
|
),
|
|
14611
|
-
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)("div", { className:
|
|
14757
|
+
/* @__PURE__ */ (0, import_jsx_runtime91.jsx)("div", { className: getClassName37("loader"), children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Loader, { size: 24 }) })
|
|
14612
14758
|
] })
|
|
14613
14759
|
}
|
|
14614
14760
|
);
|
|
@@ -14616,15 +14762,15 @@ var Canvas = () => {
|
|
|
14616
14762
|
|
|
14617
14763
|
// lib/use-sidebar-resize.ts
|
|
14618
14764
|
init_react_import();
|
|
14619
|
-
var
|
|
14765
|
+
var import_react97 = require("react");
|
|
14620
14766
|
init_store2();
|
|
14621
14767
|
function useSidebarResize(position, dispatch) {
|
|
14622
|
-
const [width, setWidth] = (0,
|
|
14623
|
-
const sidebarRef = (0,
|
|
14768
|
+
const [width, setWidth] = (0, import_react97.useState)(null);
|
|
14769
|
+
const sidebarRef = (0, import_react97.useRef)(null);
|
|
14624
14770
|
const storeWidth = useAppStore(
|
|
14625
14771
|
(s) => position === "left" ? s.state.ui.leftSideBarWidth : s.state.ui.rightSideBarWidth
|
|
14626
14772
|
);
|
|
14627
|
-
(0,
|
|
14773
|
+
(0, import_react97.useEffect)(() => {
|
|
14628
14774
|
if (typeof window !== "undefined" && !storeWidth) {
|
|
14629
14775
|
try {
|
|
14630
14776
|
const savedWidths = localStorage.getItem("credbuild-sidebar-widths");
|
|
@@ -14649,12 +14795,12 @@ function useSidebarResize(position, dispatch) {
|
|
|
14649
14795
|
}
|
|
14650
14796
|
}
|
|
14651
14797
|
}, [dispatch, position, storeWidth]);
|
|
14652
|
-
(0,
|
|
14798
|
+
(0, import_react97.useEffect)(() => {
|
|
14653
14799
|
if (storeWidth !== void 0) {
|
|
14654
14800
|
setWidth(storeWidth);
|
|
14655
14801
|
}
|
|
14656
14802
|
}, [storeWidth]);
|
|
14657
|
-
const handleResizeEnd = (0,
|
|
14803
|
+
const handleResizeEnd = (0, import_react97.useCallback)(
|
|
14658
14804
|
(width2) => {
|
|
14659
14805
|
dispatch({
|
|
14660
14806
|
type: "setUi",
|
|
@@ -14702,17 +14848,17 @@ init_react_import();
|
|
|
14702
14848
|
|
|
14703
14849
|
// components/CredBuild/components/ResizeHandle/index.tsx
|
|
14704
14850
|
init_react_import();
|
|
14705
|
-
var
|
|
14851
|
+
var import_react98 = require("react");
|
|
14706
14852
|
init_get_class_name_factory();
|
|
14707
14853
|
|
|
14708
|
-
// css-module:/home/
|
|
14854
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/CredBuild/components/ResizeHandle/styles.module.css#css-module
|
|
14709
14855
|
init_react_import();
|
|
14710
|
-
var
|
|
14856
|
+
var styles_module_default30 = { "ResizeHandle": "_ResizeHandle_144bf_2", "ResizeHandle--left": "_ResizeHandle--left_144bf_16", "ResizeHandle--right": "_ResizeHandle--right_144bf_20" };
|
|
14711
14857
|
|
|
14712
14858
|
// components/CredBuild/components/ResizeHandle/index.tsx
|
|
14713
14859
|
init_lib();
|
|
14714
14860
|
var import_jsx_runtime92 = require("react/jsx-runtime");
|
|
14715
|
-
var
|
|
14861
|
+
var getClassName38 = get_class_name_factory_default("ResizeHandle", styles_module_default30);
|
|
14716
14862
|
var ResizeHandle = ({
|
|
14717
14863
|
position,
|
|
14718
14864
|
sidebarRef,
|
|
@@ -14721,11 +14867,11 @@ var ResizeHandle = ({
|
|
|
14721
14867
|
}) => {
|
|
14722
14868
|
const { frameRef } = useCanvasFrame();
|
|
14723
14869
|
const resetAutoZoom = useResetAutoZoom(frameRef);
|
|
14724
|
-
const handleRef = (0,
|
|
14725
|
-
const isDragging = (0,
|
|
14726
|
-
const startX = (0,
|
|
14727
|
-
const startWidth = (0,
|
|
14728
|
-
const handleMouseMove = (0,
|
|
14870
|
+
const handleRef = (0, import_react98.useRef)(null);
|
|
14871
|
+
const isDragging = (0, import_react98.useRef)(false);
|
|
14872
|
+
const startX = (0, import_react98.useRef)(0);
|
|
14873
|
+
const startWidth = (0, import_react98.useRef)(0);
|
|
14874
|
+
const handleMouseMove = (0, import_react98.useCallback)(
|
|
14729
14875
|
(e) => {
|
|
14730
14876
|
if (!isDragging.current) return;
|
|
14731
14877
|
const delta = e.clientX - startX.current;
|
|
@@ -14736,7 +14882,7 @@ var ResizeHandle = ({
|
|
|
14736
14882
|
},
|
|
14737
14883
|
[onResize, position]
|
|
14738
14884
|
);
|
|
14739
|
-
const handleMouseUp = (0,
|
|
14885
|
+
const handleMouseUp = (0, import_react98.useCallback)(() => {
|
|
14740
14886
|
if (!isDragging.current) return;
|
|
14741
14887
|
isDragging.current = false;
|
|
14742
14888
|
document.body.style.cursor = "";
|
|
@@ -14751,7 +14897,7 @@ var ResizeHandle = ({
|
|
|
14751
14897
|
onResizeEnd(finalWidth);
|
|
14752
14898
|
resetAutoZoom();
|
|
14753
14899
|
}, [onResizeEnd, handleMouseMove, resetAutoZoom, sidebarRef]);
|
|
14754
|
-
const handleMouseDown = (0,
|
|
14900
|
+
const handleMouseDown = (0, import_react98.useCallback)(
|
|
14755
14901
|
(e) => {
|
|
14756
14902
|
isDragging.current = true;
|
|
14757
14903
|
startX.current = e.clientX;
|
|
@@ -14772,7 +14918,7 @@ var ResizeHandle = ({
|
|
|
14772
14918
|
"div",
|
|
14773
14919
|
{
|
|
14774
14920
|
ref: handleRef,
|
|
14775
|
-
className:
|
|
14921
|
+
className: getClassName38({ [position]: true }),
|
|
14776
14922
|
onMouseDown: handleMouseDown
|
|
14777
14923
|
}
|
|
14778
14924
|
);
|
|
@@ -14781,13 +14927,13 @@ var ResizeHandle = ({
|
|
|
14781
14927
|
// components/CredBuild/components/Sidebar/index.tsx
|
|
14782
14928
|
init_get_class_name_factory();
|
|
14783
14929
|
|
|
14784
|
-
// css-module:/home/
|
|
14930
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/CredBuild/components/Sidebar/styles.module.css#css-module
|
|
14785
14931
|
init_react_import();
|
|
14786
|
-
var
|
|
14932
|
+
var styles_module_default31 = { "Sidebar": "_Sidebar_1kcif_1", "Sidebar--isVisible": "_Sidebar--isVisible_1kcif_13", "Sidebar--left": "_Sidebar--left_1kcif_17", "Sidebar--right": "_Sidebar--right_1kcif_29", "Sidebar-resizeHandle": "_Sidebar-resizeHandle_1kcif_42" };
|
|
14787
14933
|
|
|
14788
14934
|
// components/CredBuild/components/Sidebar/index.tsx
|
|
14789
14935
|
var import_jsx_runtime93 = require("react/jsx-runtime");
|
|
14790
|
-
var
|
|
14936
|
+
var getClassName39 = get_class_name_factory_default("Sidebar", styles_module_default31);
|
|
14791
14937
|
var Sidebar = ({
|
|
14792
14938
|
position,
|
|
14793
14939
|
sidebarRef,
|
|
@@ -14801,11 +14947,11 @@ var Sidebar = ({
|
|
|
14801
14947
|
"div",
|
|
14802
14948
|
{
|
|
14803
14949
|
ref: sidebarRef,
|
|
14804
|
-
className:
|
|
14950
|
+
className: getClassName39({ [position]: true, isVisible }),
|
|
14805
14951
|
children
|
|
14806
14952
|
}
|
|
14807
14953
|
),
|
|
14808
|
-
/* @__PURE__ */ (0, import_jsx_runtime93.jsx)("div", { className: `${
|
|
14954
|
+
/* @__PURE__ */ (0, import_jsx_runtime93.jsx)("div", { className: `${getClassName39("resizeHandle")}`, children: /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(
|
|
14809
14955
|
ResizeHandle,
|
|
14810
14956
|
{
|
|
14811
14957
|
position,
|
|
@@ -14819,7 +14965,7 @@ var Sidebar = ({
|
|
|
14819
14965
|
|
|
14820
14966
|
// lib/use-delete-hotkeys.ts
|
|
14821
14967
|
init_react_import();
|
|
14822
|
-
var
|
|
14968
|
+
var import_react99 = require("react");
|
|
14823
14969
|
init_use_hotkey();
|
|
14824
14970
|
init_store2();
|
|
14825
14971
|
var isElementVisible = (element) => {
|
|
@@ -14855,7 +15001,7 @@ var shouldBlockDeleteHotkey = (e) => {
|
|
|
14855
15001
|
};
|
|
14856
15002
|
var useDeleteHotkeys = () => {
|
|
14857
15003
|
const appStore = useAppStoreApi();
|
|
14858
|
-
const deleteSelectedComponent = (0,
|
|
15004
|
+
const deleteSelectedComponent = (0, import_react99.useCallback)(
|
|
14859
15005
|
(e) => {
|
|
14860
15006
|
if (shouldBlockDeleteHotkey(e)) {
|
|
14861
15007
|
return false;
|
|
@@ -14881,15 +15027,15 @@ var useDeleteHotkeys = () => {
|
|
|
14881
15027
|
// components/CredBuild/components/Nav/index.tsx
|
|
14882
15028
|
init_react_import();
|
|
14883
15029
|
|
|
14884
|
-
// css-module:/home/
|
|
15030
|
+
// css-module:/home/runner/work/credbuild/credbuild/components/CredBuild/components/Nav/styles.module.css#css-module
|
|
14885
15031
|
init_react_import();
|
|
14886
|
-
var
|
|
15032
|
+
var styles_module_default32 = { "Nav": "_Nav_wbh7e_1", "Nav-list": "_Nav-list_wbh7e_9", "CredBuildHeader-path": "_CredBuildHeader-path_wbh7e_20", "NavItem": "_NavItem_wbh7e_38", "NavItem-link": "_NavItem-link_wbh7e_43", "NavItem-linkIcon": "_NavItem-linkIcon_wbh7e_64", "NavItem--active": "_NavItem--active_wbh7e_77", "NavItem--mobileOnly": "_NavItem--mobileOnly_wbh7e_90", "NavItem--desktopOnly": "_NavItem--desktopOnly_wbh7e_95" };
|
|
14887
15033
|
|
|
14888
15034
|
// components/CredBuild/components/Nav/index.tsx
|
|
14889
15035
|
init_lib();
|
|
14890
15036
|
var import_jsx_runtime94 = require("react/jsx-runtime");
|
|
14891
|
-
var
|
|
14892
|
-
var getClassNameItem3 = get_class_name_factory_default("NavItem",
|
|
15037
|
+
var getClassName40 = get_class_name_factory_default("Nav", styles_module_default32);
|
|
15038
|
+
var getClassNameItem3 = get_class_name_factory_default("NavItem", styles_module_default32);
|
|
14893
15039
|
var MenuItem = ({
|
|
14894
15040
|
label,
|
|
14895
15041
|
icon,
|
|
@@ -14917,9 +15063,9 @@ var Nav = ({
|
|
|
14917
15063
|
items,
|
|
14918
15064
|
mobileActions
|
|
14919
15065
|
}) => {
|
|
14920
|
-
return /* @__PURE__ */ (0, import_jsx_runtime94.jsxs)("nav", { className:
|
|
14921
|
-
/* @__PURE__ */ (0, import_jsx_runtime94.jsx)("ul", { className:
|
|
14922
|
-
mobileActions && /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("div", { className:
|
|
15066
|
+
return /* @__PURE__ */ (0, import_jsx_runtime94.jsxs)("nav", { className: getClassName40(), children: [
|
|
15067
|
+
/* @__PURE__ */ (0, import_jsx_runtime94.jsx)("ul", { className: getClassName40("list"), children: Object.entries(items).map(([key, item]) => /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(MenuItem, { ...item }, key)) }),
|
|
15068
|
+
mobileActions && /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("div", { className: getClassName40("mobileActions"), children: mobileActions })
|
|
14923
15069
|
] });
|
|
14924
15070
|
};
|
|
14925
15071
|
|
|
@@ -14931,18 +15077,18 @@ init_lucide_react();
|
|
|
14931
15077
|
init_react_import();
|
|
14932
15078
|
init_lucide_react();
|
|
14933
15079
|
|
|
14934
|
-
// css-module:/home/
|
|
15080
|
+
// css-module:/home/runner/work/credbuild/credbuild/plugins/blocks/styles.module.css#css-module
|
|
14935
15081
|
init_react_import();
|
|
14936
|
-
var
|
|
15082
|
+
var styles_module_default33 = { "BlocksPlugin": "_BlocksPlugin_1ey1i_1" };
|
|
14937
15083
|
|
|
14938
15084
|
// plugins/blocks/index.tsx
|
|
14939
15085
|
init_lib();
|
|
14940
15086
|
var import_jsx_runtime95 = require("react/jsx-runtime");
|
|
14941
|
-
var
|
|
15087
|
+
var getClassName41 = get_class_name_factory_default("BlocksPlugin", styles_module_default33);
|
|
14942
15088
|
var blocksPlugin = () => ({
|
|
14943
15089
|
name: "blocks",
|
|
14944
15090
|
label: "Blocks",
|
|
14945
|
-
render: () => /* @__PURE__ */ (0, import_jsx_runtime95.jsx)("div", { className:
|
|
15091
|
+
render: () => /* @__PURE__ */ (0, import_jsx_runtime95.jsx)("div", { className: getClassName41(), children: /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(Components, {}) }),
|
|
14946
15092
|
icon: /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(Shapes, {})
|
|
14947
15093
|
});
|
|
14948
15094
|
|
|
@@ -14950,18 +15096,18 @@ var blocksPlugin = () => ({
|
|
|
14950
15096
|
init_react_import();
|
|
14951
15097
|
init_lucide_react();
|
|
14952
15098
|
|
|
14953
|
-
// css-module:/home/
|
|
15099
|
+
// css-module:/home/runner/work/credbuild/credbuild/plugins/outline/styles.module.css#css-module
|
|
14954
15100
|
init_react_import();
|
|
14955
|
-
var
|
|
15101
|
+
var styles_module_default34 = { "OutlinePlugin": "_OutlinePlugin_q92j6_1" };
|
|
14956
15102
|
|
|
14957
15103
|
// plugins/outline/index.tsx
|
|
14958
15104
|
init_lib();
|
|
14959
15105
|
var import_jsx_runtime96 = require("react/jsx-runtime");
|
|
14960
|
-
var
|
|
15106
|
+
var getClassName42 = get_class_name_factory_default("OutlinePlugin", styles_module_default34);
|
|
14961
15107
|
var outlinePlugin = () => ({
|
|
14962
15108
|
name: "outline",
|
|
14963
15109
|
label: "Outline",
|
|
14964
|
-
render: () => /* @__PURE__ */ (0, import_jsx_runtime96.jsx)("div", { className:
|
|
15110
|
+
render: () => /* @__PURE__ */ (0, import_jsx_runtime96.jsx)("div", { className: getClassName42(), children: /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(Outline, {}) }),
|
|
14965
15111
|
icon: /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(List, {})
|
|
14966
15112
|
});
|
|
14967
15113
|
|
|
@@ -14970,14 +15116,14 @@ init_react_import();
|
|
|
14970
15116
|
init_lucide_react();
|
|
14971
15117
|
init_store2();
|
|
14972
15118
|
|
|
14973
|
-
// css-module:/home/
|
|
15119
|
+
// css-module:/home/runner/work/credbuild/credbuild/plugins/fields/styles.module.css#css-module
|
|
14974
15120
|
init_react_import();
|
|
14975
|
-
var
|
|
15121
|
+
var styles_module_default35 = { "FieldsPlugin": "_FieldsPlugin_6as57_1", "FieldsPlugin-header": "_FieldsPlugin-header_6as57_7" };
|
|
14976
15122
|
|
|
14977
15123
|
// plugins/fields/index.tsx
|
|
14978
15124
|
init_lib();
|
|
14979
15125
|
var import_jsx_runtime97 = require("react/jsx-runtime");
|
|
14980
|
-
var
|
|
15126
|
+
var getClassName43 = get_class_name_factory_default("FieldsPlugin", styles_module_default35);
|
|
14981
15127
|
var CurrentTitle = () => {
|
|
14982
15128
|
const label = useAppStore((s) => {
|
|
14983
15129
|
const selectedItem = s.selectedItem;
|
|
@@ -14988,8 +15134,8 @@ var CurrentTitle = () => {
|
|
|
14988
15134
|
var fieldsPlugin = ({ desktopSideBar = "right" } = {}) => ({
|
|
14989
15135
|
name: "fields",
|
|
14990
15136
|
label: "Fields",
|
|
14991
|
-
render: () => /* @__PURE__ */ (0, import_jsx_runtime97.jsxs)("div", { className:
|
|
14992
|
-
/* @__PURE__ */ (0, import_jsx_runtime97.jsx)("div", { className:
|
|
15137
|
+
render: () => /* @__PURE__ */ (0, import_jsx_runtime97.jsxs)("div", { className: getClassName43(), children: [
|
|
15138
|
+
/* @__PURE__ */ (0, import_jsx_runtime97.jsx)("div", { className: getClassName43("header"), children: /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(Breadcrumbs, { numParents: 2, children: /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(CurrentTitle, {}) }) }),
|
|
14993
15139
|
/* @__PURE__ */ (0, import_jsx_runtime97.jsx)(Fields, {})
|
|
14994
15140
|
] }),
|
|
14995
15141
|
icon: /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(RectangleEllipsis, {}),
|
|
@@ -14998,9 +15144,9 @@ var fieldsPlugin = ({ desktopSideBar = "right" } = {}) => ({
|
|
|
14998
15144
|
|
|
14999
15145
|
// components/CredBuild/components/Layout/index.tsx
|
|
15000
15146
|
var import_jsx_runtime98 = require("react/jsx-runtime");
|
|
15001
|
-
var
|
|
15002
|
-
var getLayoutClassName = get_class_name_factory_default("CredBuildLayout",
|
|
15003
|
-
var getPluginTabClassName = get_class_name_factory_default("CredBuildPluginTab",
|
|
15147
|
+
var getClassName44 = get_class_name_factory_default("CredBuild", styles_module_default23);
|
|
15148
|
+
var getLayoutClassName = get_class_name_factory_default("CredBuildLayout", styles_module_default23);
|
|
15149
|
+
var getPluginTabClassName = get_class_name_factory_default("CredBuildPluginTab", styles_module_default23);
|
|
15004
15150
|
var FieldSideBar = () => {
|
|
15005
15151
|
const title = useAppStore(
|
|
15006
15152
|
(s) => s.selectedItem ? s.config.components[s.selectedItem.type]?.["label"] ?? s.selectedItem.type.toString() : s.config.root?.label || "Page"
|
|
@@ -15022,7 +15168,7 @@ var Layout = ({ children }) => {
|
|
|
15022
15168
|
plugins,
|
|
15023
15169
|
height
|
|
15024
15170
|
} = usePropsContext();
|
|
15025
|
-
const iframe = (0,
|
|
15171
|
+
const iframe = (0, import_react100.useMemo)(
|
|
15026
15172
|
() => ({
|
|
15027
15173
|
enabled: true,
|
|
15028
15174
|
waitForStyles: true,
|
|
@@ -15049,7 +15195,7 @@ var Layout = ({ children }) => {
|
|
|
15049
15195
|
sidebarRef: rightSidebarRef,
|
|
15050
15196
|
handleResizeEnd: handleRightSidebarResizeEnd
|
|
15051
15197
|
} = useSidebarResize("right", dispatch);
|
|
15052
|
-
(0,
|
|
15198
|
+
(0, import_react100.useEffect)(() => {
|
|
15053
15199
|
if (!window.matchMedia("(min-width: 638px)").matches) {
|
|
15054
15200
|
dispatch({
|
|
15055
15201
|
type: "setUi",
|
|
@@ -15076,13 +15222,13 @@ var Layout = ({ children }) => {
|
|
|
15076
15222
|
};
|
|
15077
15223
|
}, [dispatch]);
|
|
15078
15224
|
const overrides = useAppStore((s) => s.overrides);
|
|
15079
|
-
const CustomCredBuild = (0,
|
|
15225
|
+
const CustomCredBuild = (0, import_react100.useMemo)(
|
|
15080
15226
|
() => overrides.credbuild || DefaultOverride,
|
|
15081
15227
|
[overrides]
|
|
15082
15228
|
);
|
|
15083
|
-
const [mounted, setMounted] = (0,
|
|
15084
|
-
const [theme, setTheme] = (0,
|
|
15085
|
-
(0,
|
|
15229
|
+
const [mounted, setMounted] = (0, import_react100.useState)(false);
|
|
15230
|
+
const [theme, setTheme] = (0, import_react100.useState)("dark");
|
|
15231
|
+
(0, import_react100.useEffect)(() => {
|
|
15086
15232
|
setMounted(true);
|
|
15087
15233
|
const savedTheme = localStorage.getItem("credbuild-theme");
|
|
15088
15234
|
if (savedTheme) {
|
|
@@ -15101,7 +15247,7 @@ var Layout = ({ children }) => {
|
|
|
15101
15247
|
}, []);
|
|
15102
15248
|
const ready = useAppStore((s) => s.status === "READY");
|
|
15103
15249
|
useMonitorHotkeys();
|
|
15104
|
-
(0,
|
|
15250
|
+
(0, import_react100.useEffect)(() => {
|
|
15105
15251
|
if (ready && iframe.enabled) {
|
|
15106
15252
|
const frameDoc = getFrame();
|
|
15107
15253
|
if (frameDoc) {
|
|
@@ -15121,12 +15267,12 @@ var Layout = ({ children }) => {
|
|
|
15121
15267
|
const setUi = useAppStore((s) => s.setUi);
|
|
15122
15268
|
const currentPlugin = useAppStore((s) => s.state.ui.plugin?.current);
|
|
15123
15269
|
const appStoreApi = useAppStoreApi();
|
|
15124
|
-
const [mobilePanelHeightMode, setMobilePanelHeightMode] = (0,
|
|
15125
|
-
const hasLegacySideBarPlugin = (0,
|
|
15270
|
+
const [mobilePanelHeightMode, setMobilePanelHeightMode] = (0, import_react100.useState)("toggle");
|
|
15271
|
+
const hasLegacySideBarPlugin = (0, import_react100.useMemo)(
|
|
15126
15272
|
() => !!plugins?.find((p) => p.name === "legacy-side-bar"),
|
|
15127
15273
|
[plugins]
|
|
15128
15274
|
);
|
|
15129
|
-
const pluginItems = (0,
|
|
15275
|
+
const pluginItems = (0, import_react100.useMemo)(() => {
|
|
15130
15276
|
const details = {};
|
|
15131
15277
|
const defaultPlugins = [blocksPlugin(), outlinePlugin()];
|
|
15132
15278
|
const isLegacy = (plugin) => plugin.name === "legacy-side-bar" ? -1 : 0;
|
|
@@ -15171,7 +15317,7 @@ var Layout = ({ children }) => {
|
|
|
15171
15317
|
});
|
|
15172
15318
|
return details;
|
|
15173
15319
|
}, [plugins, currentPlugin, leftSideBarVisible, hasLegacySideBarPlugin, setUi]);
|
|
15174
|
-
(0,
|
|
15320
|
+
(0, import_react100.useEffect)(() => {
|
|
15175
15321
|
if (!currentPlugin) {
|
|
15176
15322
|
const names = Object.keys(pluginItems);
|
|
15177
15323
|
setUi({ plugin: { current: names[0] } });
|
|
@@ -15184,7 +15330,7 @@ var Layout = ({ children }) => {
|
|
|
15184
15330
|
return /* @__PURE__ */ (0, import_jsx_runtime98.jsxs)(
|
|
15185
15331
|
"div",
|
|
15186
15332
|
{
|
|
15187
|
-
className: `CredBuild ${theme === "dark" ? "dark" : ""} ${
|
|
15333
|
+
className: `CredBuild ${theme === "dark" ? "dark" : ""} ${getClassName44({
|
|
15188
15334
|
hidePlugins: hasLegacySideBarPlugin
|
|
15189
15335
|
})}`,
|
|
15190
15336
|
"data-theme": theme,
|
|
@@ -15269,7 +15415,7 @@ var Layout = ({ children }) => {
|
|
|
15269
15415
|
)
|
|
15270
15416
|
}
|
|
15271
15417
|
) }) }) }),
|
|
15272
|
-
/* @__PURE__ */ (0, import_jsx_runtime98.jsx)("div", { id: "credbuild-portal-root", className:
|
|
15418
|
+
/* @__PURE__ */ (0, import_jsx_runtime98.jsx)("div", { id: "credbuild-portal-root", className: getClassName44("portal") })
|
|
15273
15419
|
]
|
|
15274
15420
|
}
|
|
15275
15421
|
);
|
|
@@ -15296,7 +15442,7 @@ function CredBuildProvider({ children }) {
|
|
|
15296
15442
|
_experimentalFullScreenCanvas,
|
|
15297
15443
|
_experimentalVirtualization
|
|
15298
15444
|
} = usePropsContext();
|
|
15299
|
-
const iframe = (0,
|
|
15445
|
+
const iframe = (0, import_react101.useMemo)(
|
|
15300
15446
|
() => ({
|
|
15301
15447
|
enabled: true,
|
|
15302
15448
|
waitForStyles: true,
|
|
@@ -15304,7 +15450,7 @@ function CredBuildProvider({ children }) {
|
|
|
15304
15450
|
}),
|
|
15305
15451
|
[_iframe]
|
|
15306
15452
|
);
|
|
15307
|
-
const [generatedAppState] = (0,
|
|
15453
|
+
const [generatedAppState] = (0, import_react101.useState)(() => {
|
|
15308
15454
|
const initial = { ...defaultAppState.ui, ...initialUi };
|
|
15309
15455
|
let clientUiState = {};
|
|
15310
15456
|
if (Object.keys(initialData?.root || {}).length > 0 && !initialData?.root?.props) {
|
|
@@ -15351,7 +15497,7 @@ function CredBuildProvider({ children }) {
|
|
|
15351
15497
|
return walkAppState(newAppState, config);
|
|
15352
15498
|
});
|
|
15353
15499
|
const { appendData = true } = _initialHistory || {};
|
|
15354
|
-
const [blendedHistories] = (0,
|
|
15500
|
+
const [blendedHistories] = (0, import_react101.useState)(
|
|
15355
15501
|
[
|
|
15356
15502
|
..._initialHistory?.histories || [],
|
|
15357
15503
|
...appendData ? [{ state: generatedAppState }] : []
|
|
@@ -15366,7 +15512,7 @@ function CredBuildProvider({ children }) {
|
|
|
15366
15512
|
};
|
|
15367
15513
|
})
|
|
15368
15514
|
);
|
|
15369
|
-
const initialHistoryIndex = (0,
|
|
15515
|
+
const initialHistoryIndex = (0, import_react101.useMemo)(() => {
|
|
15370
15516
|
if (_initialHistory?.index !== void 0 && _initialHistory?.index >= 0 && _initialHistory?.index < blendedHistories.length) {
|
|
15371
15517
|
return _initialHistory?.index;
|
|
15372
15518
|
}
|
|
@@ -15377,7 +15523,7 @@ function CredBuildProvider({ children }) {
|
|
|
15377
15523
|
overrides,
|
|
15378
15524
|
plugins
|
|
15379
15525
|
});
|
|
15380
|
-
const loadedFieldTransforms = (0,
|
|
15526
|
+
const loadedFieldTransforms = (0, import_react101.useMemo)(() => {
|
|
15381
15527
|
const _plugins = plugins || [];
|
|
15382
15528
|
const pluginFieldTransforms = _plugins.reduce(
|
|
15383
15529
|
(acc, plugin) => ({ ...acc, ...plugin.fieldTransforms }),
|
|
@@ -15389,7 +15535,7 @@ function CredBuildProvider({ children }) {
|
|
|
15389
15535
|
};
|
|
15390
15536
|
}, [fieldTransforms, plugins]);
|
|
15391
15537
|
const instanceId = useSafeId();
|
|
15392
|
-
const generateAppStore = (0,
|
|
15538
|
+
const generateAppStore = (0, import_react101.useCallback)(
|
|
15393
15539
|
(state) => {
|
|
15394
15540
|
return {
|
|
15395
15541
|
instanceId,
|
|
@@ -15420,15 +15566,15 @@ function CredBuildProvider({ children }) {
|
|
|
15420
15566
|
loadedFieldTransforms
|
|
15421
15567
|
]
|
|
15422
15568
|
);
|
|
15423
|
-
const [appStore] = (0,
|
|
15569
|
+
const [appStore] = (0, import_react101.useState)(
|
|
15424
15570
|
() => createAppStore(generateAppStore(initialAppState))
|
|
15425
15571
|
);
|
|
15426
|
-
(0,
|
|
15572
|
+
(0, import_react101.useEffect)(() => {
|
|
15427
15573
|
if (process.env.NODE_ENV !== "production") {
|
|
15428
15574
|
window.__CREDBUILD_INTERNAL_DO_NOT_USE = { appStore };
|
|
15429
15575
|
}
|
|
15430
15576
|
}, [appStore]);
|
|
15431
|
-
(0,
|
|
15577
|
+
(0, import_react101.useEffect)(() => {
|
|
15432
15578
|
const state = appStore.getState().state;
|
|
15433
15579
|
appStore.setState({
|
|
15434
15580
|
...generateAppStore(state)
|
|
@@ -15439,8 +15585,8 @@ function CredBuildProvider({ children }) {
|
|
|
15439
15585
|
index: initialHistoryIndex,
|
|
15440
15586
|
initialAppState
|
|
15441
15587
|
});
|
|
15442
|
-
const previousData = (0,
|
|
15443
|
-
(0,
|
|
15588
|
+
const previousData = (0, import_react101.useRef)(null);
|
|
15589
|
+
(0, import_react101.useEffect)(() => {
|
|
15444
15590
|
return appStore.subscribe(
|
|
15445
15591
|
(s) => s.state.data,
|
|
15446
15592
|
(data) => {
|
|
@@ -15454,7 +15600,7 @@ function CredBuildProvider({ children }) {
|
|
|
15454
15600
|
}, [onChange, appStore]);
|
|
15455
15601
|
useRegisterPermissionsSlice(appStore, permissions);
|
|
15456
15602
|
const uCredBuildStore = useRegisterUseCredBuildStore(appStore);
|
|
15457
|
-
(0,
|
|
15603
|
+
(0, import_react101.useEffect)(() => {
|
|
15458
15604
|
const { resolveAndCommitData } = appStore.getState();
|
|
15459
15605
|
setTimeout(() => {
|
|
15460
15606
|
resolveAndCommitData();
|
|
@@ -15799,6 +15945,7 @@ lucide-react/dist/esm/icons/heading-5.js:
|
|
|
15799
15945
|
lucide-react/dist/esm/icons/heading-6.js:
|
|
15800
15946
|
lucide-react/dist/esm/icons/heading.js:
|
|
15801
15947
|
lucide-react/dist/esm/icons/image.js:
|
|
15948
|
+
lucide-react/dist/esm/icons/inbox.js:
|
|
15802
15949
|
lucide-react/dist/esm/icons/info.js:
|
|
15803
15950
|
lucide-react/dist/esm/icons/italic.js:
|
|
15804
15951
|
lucide-react/dist/esm/icons/layers.js:
|