@intlayer/design-system 4.0.2 → 4.0.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.
Files changed (104) hide show
  1. package/README.md +1 -1
  2. package/dist/.vite/manifest.json +26 -156
  3. package/dist/components/Accordion/Accordion.cjs +1 -1
  4. package/dist/components/Accordion/Accordion.cjs.map +1 -1
  5. package/dist/components/Accordion/Accordion.mjs +1 -1
  6. package/dist/components/Accordion/Accordion.mjs.map +1 -1
  7. package/dist/components/DictionaryEditor/DictionaryEditor.cjs +3 -15
  8. package/dist/components/DictionaryEditor/DictionaryEditor.cjs.map +1 -1
  9. package/dist/components/DictionaryEditor/DictionaryEditor.d.ts.map +1 -1
  10. package/dist/components/DictionaryEditor/DictionaryEditor.mjs +3 -15
  11. package/dist/components/DictionaryEditor/DictionaryEditor.mjs.map +1 -1
  12. package/dist/components/DictionaryEditor/NodeWrapper/StringWrapper.cjs +2 -2
  13. package/dist/components/DictionaryEditor/NodeWrapper/StringWrapper.cjs.map +1 -1
  14. package/dist/components/DictionaryEditor/NodeWrapper/StringWrapper.d.ts.map +1 -1
  15. package/dist/components/DictionaryEditor/NodeWrapper/StringWrapper.mjs +1 -1
  16. package/dist/components/DictionaryEditor/NodeWrapper/StringWrapper.mjs.map +1 -1
  17. package/dist/components/DictionaryEditor/ValidDictionaryChangeButtons.cjs +2 -8
  18. package/dist/components/DictionaryEditor/ValidDictionaryChangeButtons.cjs.map +1 -1
  19. package/dist/components/DictionaryEditor/ValidDictionaryChangeButtons.d.ts.map +1 -1
  20. package/dist/components/DictionaryEditor/ValidDictionaryChangeButtons.mjs +2 -8
  21. package/dist/components/DictionaryEditor/ValidDictionaryChangeButtons.mjs.map +1 -1
  22. package/dist/components/DictionaryEditor/index.cjs +0 -8
  23. package/dist/components/DictionaryEditor/index.cjs.map +1 -1
  24. package/dist/components/DictionaryEditor/index.d.ts +0 -2
  25. package/dist/components/DictionaryEditor/index.d.ts.map +1 -1
  26. package/dist/components/DictionaryEditor/index.mjs +1 -9
  27. package/dist/components/DictionaryEditor/index.mjs.map +1 -1
  28. package/dist/components/DictionaryEditor/useEditedContentStore.d.ts +1 -1
  29. package/dist/components/DictionaryFieldEditor/DictionariesSelector/DictionariesSelector.cjs +2 -20
  30. package/dist/components/DictionaryFieldEditor/DictionariesSelector/DictionariesSelector.cjs.map +1 -1
  31. package/dist/components/DictionaryFieldEditor/DictionariesSelector/DictionariesSelector.d.ts.map +1 -1
  32. package/dist/components/DictionaryFieldEditor/DictionariesSelector/DictionariesSelector.mjs +2 -20
  33. package/dist/components/DictionaryFieldEditor/DictionariesSelector/DictionariesSelector.mjs.map +1 -1
  34. package/dist/components/DictionaryFieldEditor/DictionaryFieldEditor.cjs +7 -24
  35. package/dist/components/DictionaryFieldEditor/DictionaryFieldEditor.cjs.map +1 -1
  36. package/dist/components/DictionaryFieldEditor/DictionaryFieldEditor.d.ts.map +1 -1
  37. package/dist/components/DictionaryFieldEditor/DictionaryFieldEditor.mjs +7 -24
  38. package/dist/components/DictionaryFieldEditor/DictionaryFieldEditor.mjs.map +1 -1
  39. package/dist/components/DictionaryFieldEditor/EditorView/EditorView.cjs +6 -35
  40. package/dist/components/DictionaryFieldEditor/EditorView/EditorView.cjs.map +1 -1
  41. package/dist/components/DictionaryFieldEditor/EditorView/EditorView.d.ts.map +1 -1
  42. package/dist/components/DictionaryFieldEditor/EditorView/EditorView.mjs +4 -33
  43. package/dist/components/DictionaryFieldEditor/EditorView/EditorView.mjs.map +1 -1
  44. package/dist/components/DictionaryFieldEditor/EditorView/TextEditor.cjs +5 -23
  45. package/dist/components/DictionaryFieldEditor/EditorView/TextEditor.cjs.map +1 -1
  46. package/dist/components/DictionaryFieldEditor/EditorView/TextEditor.d.ts.map +1 -1
  47. package/dist/components/DictionaryFieldEditor/EditorView/TextEditor.mjs +5 -23
  48. package/dist/components/DictionaryFieldEditor/EditorView/TextEditor.mjs.map +1 -1
  49. package/dist/components/DictionaryFieldEditor/JSONEditor.cjs +2 -29
  50. package/dist/components/DictionaryFieldEditor/JSONEditor.cjs.map +1 -1
  51. package/dist/components/DictionaryFieldEditor/JSONEditor.d.ts.map +1 -1
  52. package/dist/components/DictionaryFieldEditor/JSONEditor.mjs +2 -29
  53. package/dist/components/DictionaryFieldEditor/JSONEditor.mjs.map +1 -1
  54. package/dist/components/DictionaryFieldEditor/NavigationView/NavigationViewNode.cjs +8 -33
  55. package/dist/components/DictionaryFieldEditor/NavigationView/NavigationViewNode.cjs.map +1 -1
  56. package/dist/components/DictionaryFieldEditor/NavigationView/NavigationViewNode.d.ts.map +1 -1
  57. package/dist/components/DictionaryFieldEditor/NavigationView/NavigationViewNode.mjs +4 -29
  58. package/dist/components/DictionaryFieldEditor/NavigationView/NavigationViewNode.mjs.map +1 -1
  59. package/dist/components/DictionaryFieldEditor/NodeEditor.cjs +6 -38
  60. package/dist/components/DictionaryFieldEditor/NodeEditor.cjs.map +1 -1
  61. package/dist/components/DictionaryFieldEditor/NodeEditor.d.ts.map +1 -1
  62. package/dist/components/DictionaryFieldEditor/NodeEditor.mjs +6 -38
  63. package/dist/components/DictionaryFieldEditor/NodeEditor.mjs.map +1 -1
  64. package/dist/components/DictionaryFieldEditor/NodeTypeSelector.cjs +3 -27
  65. package/dist/components/DictionaryFieldEditor/NodeTypeSelector.cjs.map +1 -1
  66. package/dist/components/DictionaryFieldEditor/NodeTypeSelector.d.ts.map +1 -1
  67. package/dist/components/DictionaryFieldEditor/NodeTypeSelector.mjs +3 -27
  68. package/dist/components/DictionaryFieldEditor/NodeTypeSelector.mjs.map +1 -1
  69. package/dist/components/DictionaryFieldEditor/SaveForm/SaveForm.cjs +2 -14
  70. package/dist/components/DictionaryFieldEditor/SaveForm/SaveForm.cjs.map +1 -1
  71. package/dist/components/DictionaryFieldEditor/SaveForm/SaveForm.d.ts.map +1 -1
  72. package/dist/components/DictionaryFieldEditor/SaveForm/SaveForm.mjs +2 -14
  73. package/dist/components/DictionaryFieldEditor/SaveForm/SaveForm.mjs.map +1 -1
  74. package/dist/components/Modal/Modal.cjs +1 -1
  75. package/dist/components/Modal/Modal.mjs +1 -1
  76. package/dist/components/Navbar/MobileNavbar.cjs +1 -1
  77. package/dist/components/Navbar/MobileNavbar.mjs +1 -1
  78. package/dist/components/RightDrawer/RightDrawer.cjs +2 -3
  79. package/dist/components/RightDrawer/RightDrawer.cjs.map +1 -1
  80. package/dist/components/RightDrawer/RightDrawer.mjs +1 -2
  81. package/dist/components/RightDrawer/RightDrawer.mjs.map +1 -1
  82. package/dist/components/index.cjs +0 -8
  83. package/dist/components/index.cjs.map +1 -1
  84. package/dist/components/index.mjs +0 -8
  85. package/dist/components/index.mjs.map +1 -1
  86. package/dist/hooks/index.cjs +1 -1
  87. package/dist/hooks/index.mjs +2 -2
  88. package/dist/hooks/usePersistedStore.cjs +8 -5
  89. package/dist/hooks/usePersistedStore.cjs.map +1 -1
  90. package/dist/hooks/usePersistedStore.d.ts +2 -1
  91. package/dist/hooks/usePersistedStore.d.ts.map +1 -1
  92. package/dist/hooks/usePersistedStore.mjs +8 -5
  93. package/dist/hooks/usePersistedStore.mjs.map +1 -1
  94. package/dist/hooks/useScrollBlockage/index.cjs +5 -31
  95. package/dist/hooks/useScrollBlockage/index.cjs.map +1 -1
  96. package/dist/hooks/useScrollBlockage/index.mjs +5 -31
  97. package/dist/hooks/useScrollBlockage/index.mjs.map +1 -1
  98. package/dist/hooks/useScrollDetection.cjs +1 -1
  99. package/dist/hooks/useScrollDetection.mjs +1 -1
  100. package/dist/index-Cg-S9ry9.cjs +77 -0
  101. package/dist/index-Cg-S9ry9.cjs.map +1 -0
  102. package/dist/index-O_7rYrbW.js +78 -0
  103. package/dist/index-O_7rYrbW.js.map +1 -0
  104. package/package.json +18 -15
package/README.md CHANGED
@@ -17,7 +17,7 @@
17
17
  </a>
18
18
  </div>
19
19
 
20
- # @intlayer/design-system: NPM Package containing the UI library of Intlayer
20
+ # @intlayer/design-system: Containing the UI library of Intlayer
21
21
 
22
22
  **Intlayer** is a suite of packages designed specifically for JavaScript developers. It is compatible with frameworks like React, React, and Express.js.
23
23
 
@@ -60,6 +60,14 @@
60
60
  "src/components/DictionaryEditor/NodeWrapper/StringWrapper.tsx"
61
61
  ]
62
62
  },
63
+ "_index-Cg-S9ry9.cjs": {
64
+ "file": "index-Cg-S9ry9.cjs",
65
+ "name": "index",
66
+ "imports": [
67
+ "src/hooks/useGetElementOrWindow.ts",
68
+ "src/hooks/useScrollBlockage/useScrollBlockageStore.ts"
69
+ ]
70
+ },
63
71
  "_index-DFc7og1d.cjs": {
64
72
  "file": "index-DFc7og1d.cjs",
65
73
  "name": "index"
@@ -77,6 +85,14 @@
77
85
  "file": "index-DcWYZrJW.js",
78
86
  "name": "index"
79
87
  },
88
+ "_index-O_7rYrbW.js": {
89
+ "file": "index-O_7rYrbW.js",
90
+ "name": "index",
91
+ "imports": [
92
+ "src/hooks/useGetElementOrWindow.ts",
93
+ "src/hooks/useScrollBlockage/useScrollBlockageStore.ts"
94
+ ]
95
+ },
80
96
  "_jsx-runtime-CgFM7lM3.cjs": {
81
97
  "file": "jsx-runtime-CgFM7lM3.cjs",
82
98
  "name": "jsx-runtime"
@@ -85,14 +101,6 @@
85
101
  "file": "jsx-runtime-DQkoUcjV.js",
86
102
  "name": "jsx-runtime"
87
103
  },
88
- "_shallow-lhDIFtEp.cjs": {
89
- "file": "shallow-lhDIFtEp.cjs",
90
- "name": "shallow"
91
- },
92
- "_shallow-m9BpCkKh.js": {
93
- "file": "shallow-m9BpCkKh.js",
94
- "name": "shallow"
95
- },
96
104
  "_zod-BV4nCGJE.js": {
97
105
  "file": "zod-BV4nCGJE.js",
98
106
  "name": "zod"
@@ -641,10 +649,7 @@
641
649
  "isEntry": true,
642
650
  "imports": [
643
651
  "_jsx-runtime-CgFM7lM3.cjs",
644
- "_shallow-lhDIFtEp.cjs",
645
652
  "_index-DTCehvKe.cjs",
646
- "src/components/DictionaryEditor/useEditedContentStore.ts",
647
- "src/components/DictionaryEditor/useEditionPanelStore.ts",
648
653
  "src/components/DictionaryEditor/ValidDictionaryChangeButtons.tsx"
649
654
  ]
650
655
  },
@@ -700,8 +705,7 @@
700
705
  "_jsx-runtime-CgFM7lM3.cjs",
701
706
  "src/components/EditableField/EditableFieldInput.tsx",
702
707
  "src/components/EditableField/EditableFieldTextArea.tsx",
703
- "src/utils/cn.ts",
704
- "src/utils/dictionary.ts"
708
+ "src/utils/cn.ts"
705
709
  ]
706
710
  },
707
711
  "src/components/DictionaryEditor/NodeWrapper/TranslationWrapper.tsx": {
@@ -732,14 +736,12 @@
732
736
  "isEntry": true,
733
737
  "imports": [
734
738
  "_jsx-runtime-CgFM7lM3.cjs",
735
- "_shallow-lhDIFtEp.cjs",
736
739
  "src/hooks/useScrollBlockage/useScrollBlockageStore.ts",
737
740
  "src/hooks/useAsync/useAsyncStateStore.tsx",
738
741
  "src/hooks/intlayerAPIHooks.ts",
739
742
  "src/components/Form/FormBase.tsx",
740
743
  "src/components/Form/FormField.tsx",
741
744
  "_Form-CSMiPnjC.cjs",
742
- "src/components/DictionaryEditor/useEditedContentStore.ts",
743
745
  "src/components/DictionaryEditor/validDictionaryChangeButtons.content.tsx",
744
746
  "src/components/DictionaryEditor/validDictionaryChangeButtonsSchema.ts"
745
747
  ]
@@ -750,27 +752,9 @@
750
752
  "src": "src/components/DictionaryEditor/index.tsx",
751
753
  "isEntry": true,
752
754
  "imports": [
753
- "src/components/DictionaryEditor/useEditedContentStore.ts",
754
- "src/components/DictionaryEditor/useEditionPanelStore.ts",
755
- "src/components/DictionaryEditor/DictionaryEditor.tsx",
756
- "src/utils/dictionary.ts"
757
- ]
758
- },
759
- "src/components/DictionaryEditor/useEditedContentStore.ts": {
760
- "file": "components/DictionaryEditor/useEditedContentStore.cjs",
761
- "name": "components/DictionaryEditor/useEditedContentStore",
762
- "src": "src/components/DictionaryEditor/useEditedContentStore.ts",
763
- "isEntry": true,
764
- "imports": [
765
- "src/utils/dictionary.ts"
755
+ "src/components/DictionaryEditor/DictionaryEditor.tsx"
766
756
  ]
767
757
  },
768
- "src/components/DictionaryEditor/useEditionPanelStore.ts": {
769
- "file": "components/DictionaryEditor/useEditionPanelStore.cjs",
770
- "name": "components/DictionaryEditor/useEditionPanelStore",
771
- "src": "src/components/DictionaryEditor/useEditionPanelStore.ts",
772
- "isEntry": true
773
- },
774
758
  "src/components/DictionaryEditor/validDictionaryChangeButtons.content.tsx": {
775
759
  "file": "components/DictionaryEditor/validDictionaryChangeButtons.content.cjs",
776
760
  "name": "components/DictionaryEditor/validDictionaryChangeButtons.content",
@@ -790,21 +774,11 @@
790
774
  "isEntry": true,
791
775
  "imports": [
792
776
  "_jsx-runtime-CgFM7lM3.cjs",
793
- "_shallow-lhDIFtEp.cjs",
794
777
  "src/hooks/useScrollBlockage/useScrollBlockageStore.ts",
795
778
  "src/hooks/useAsync/useAsyncStateStore.tsx",
796
779
  "_index-DFc7og1d.cjs",
797
780
  "src/components/Toaster/Toast.tsx",
798
781
  "src/hooks/useGetAllDictionaries.tsx",
799
- "src/components/DictionaryEditor/useEditedContentStore.ts",
800
- "src/components/DictionaryEditor/useEditionPanelStore.ts",
801
- "src/components/Button/Button.tsx",
802
- "src/components/EditableField/EditableFieldInput.tsx",
803
- "src/components/EditableField/EditableFieldTextArea.tsx",
804
- "src/components/Form/FormBase.tsx",
805
- "src/components/Form/FormField.tsx",
806
- "_Form-CSMiPnjC.cjs",
807
- "src/components/DictionaryEditor/validDictionaryChangeButtons.content.tsx",
808
782
  "src/components/Loader/index.tsx",
809
783
  "src/components/DictionaryFieldEditor/DictionaryFieldEditor.tsx",
810
784
  "src/components/DictionaryFieldEditor/DictionariesSelector/dictionariesSelector.content.ts"
@@ -928,22 +902,13 @@
928
902
  "isEntry": true,
929
903
  "imports": [
930
904
  "_jsx-runtime-CgFM7lM3.cjs",
931
- "_shallow-lhDIFtEp.cjs",
932
905
  "src/components/Button/Button.tsx",
933
906
  "src/components/Container/index.tsx",
934
- "src/components/DictionaryEditor/useEditedContentStore.ts",
935
- "src/components/DictionaryEditor/useEditionPanelStore.ts",
936
- "src/components/EditableField/EditableFieldInput.tsx",
937
- "src/components/EditableField/EditableFieldTextArea.tsx",
907
+ "src/components/Headers/index.tsx",
938
908
  "src/hooks/useScrollBlockage/useScrollBlockageStore.ts",
939
909
  "src/hooks/useAsync/useAsyncStateStore.tsx",
940
910
  "_index-DFc7og1d.cjs",
941
911
  "src/components/Toaster/Toast.tsx",
942
- "src/components/Form/FormBase.tsx",
943
- "src/components/Form/FormField.tsx",
944
- "_Form-CSMiPnjC.cjs",
945
- "src/components/DictionaryEditor/validDictionaryChangeButtons.content.tsx",
946
- "src/components/Headers/index.tsx",
947
912
  "src/components/DropDown/index.tsx",
948
913
  "src/components/Input/Input.tsx",
949
914
  "src/components/Input/InputPassword.tsx",
@@ -965,22 +930,10 @@
965
930
  "isEntry": true,
966
931
  "imports": [
967
932
  "_jsx-runtime-CgFM7lM3.cjs",
968
- "_shallow-lhDIFtEp.cjs",
969
933
  "src/components/EditableField/EditableFieldInput.tsx",
970
934
  "src/components/EditableField/EditableFieldTextArea.tsx",
971
935
  "src/utils/camelCase.ts",
972
- "src/utils/dictionary.ts",
973
936
  "src/components/Button/Button.tsx",
974
- "src/components/DictionaryEditor/useEditedContentStore.ts",
975
- "src/components/DictionaryEditor/useEditionPanelStore.ts",
976
- "src/hooks/useScrollBlockage/useScrollBlockageStore.ts",
977
- "src/hooks/useAsync/useAsyncStateStore.tsx",
978
- "_index-DFc7og1d.cjs",
979
- "src/components/Toaster/Toast.tsx",
980
- "src/components/Form/FormBase.tsx",
981
- "src/components/Form/FormField.tsx",
982
- "_Form-CSMiPnjC.cjs",
983
- "src/components/DictionaryEditor/validDictionaryChangeButtons.content.tsx",
984
937
  "src/components/Label/index.tsx",
985
938
  "src/components/DictionaryFieldEditor/editorView.content.ts",
986
939
  "src/components/DictionaryFieldEditor/getIsEditableSection.ts",
@@ -995,22 +948,12 @@
995
948
  "isEntry": true,
996
949
  "imports": [
997
950
  "_jsx-runtime-CgFM7lM3.cjs",
998
- "_shallow-lhDIFtEp.cjs",
999
951
  "src/hooks/useScrollBlockage/useScrollBlockageStore.ts",
1000
952
  "src/hooks/useAsync/useAsyncStateStore.tsx",
1001
953
  "src/hooks/intlayerAPIHooks.ts",
1002
- "src/utils/dictionary.ts",
1003
954
  "src/utils/object.ts",
1004
955
  "src/components/Button/Button.tsx",
1005
956
  "src/components/ContentEditor/ContentEditorTextArea.tsx",
1006
- "src/components/DictionaryEditor/useEditedContentStore.ts",
1007
- "src/components/DictionaryEditor/useEditionPanelStore.ts",
1008
- "src/components/EditableField/EditableFieldInput.tsx",
1009
- "src/components/EditableField/EditableFieldTextArea.tsx",
1010
- "src/components/Form/FormBase.tsx",
1011
- "src/components/Form/FormField.tsx",
1012
- "_Form-CSMiPnjC.cjs",
1013
- "src/components/DictionaryEditor/validDictionaryChangeButtons.content.tsx",
1014
957
  "src/components/Container/index.tsx",
1015
958
  "src/components/DropDown/index.tsx",
1016
959
  "src/components/Input/Input.tsx",
@@ -1045,20 +988,6 @@
1045
988
  "isEntry": true,
1046
989
  "imports": [
1047
990
  "_jsx-runtime-CgFM7lM3.cjs",
1048
- "_shallow-lhDIFtEp.cjs",
1049
- "src/components/DictionaryEditor/useEditedContentStore.ts",
1050
- "src/components/DictionaryEditor/useEditionPanelStore.ts",
1051
- "src/components/Button/Button.tsx",
1052
- "src/components/EditableField/EditableFieldInput.tsx",
1053
- "src/components/EditableField/EditableFieldTextArea.tsx",
1054
- "src/hooks/useScrollBlockage/useScrollBlockageStore.ts",
1055
- "src/hooks/useAsync/useAsyncStateStore.tsx",
1056
- "_index-DFc7og1d.cjs",
1057
- "src/components/Toaster/Toast.tsx",
1058
- "src/components/Form/FormBase.tsx",
1059
- "src/components/Form/FormField.tsx",
1060
- "_Form-CSMiPnjC.cjs",
1061
- "src/components/DictionaryEditor/validDictionaryChangeButtons.content.tsx",
1062
991
  "src/components/IDE/MonacoCode.tsx"
1063
992
  ]
1064
993
  },
@@ -1079,23 +1008,9 @@
1079
1008
  "isEntry": true,
1080
1009
  "imports": [
1081
1010
  "_jsx-runtime-CgFM7lM3.cjs",
1082
- "_shallow-lhDIFtEp.cjs",
1083
1011
  "src/utils/camelCase.ts",
1084
- "src/utils/dictionary.ts",
1085
1012
  "src/components/Accordion/Accordion.tsx",
1086
1013
  "src/components/Button/Button.tsx",
1087
- "src/components/DictionaryEditor/useEditedContentStore.ts",
1088
- "src/components/DictionaryEditor/useEditionPanelStore.ts",
1089
- "src/components/EditableField/EditableFieldInput.tsx",
1090
- "src/components/EditableField/EditableFieldTextArea.tsx",
1091
- "src/hooks/useScrollBlockage/useScrollBlockageStore.ts",
1092
- "src/hooks/useAsync/useAsyncStateStore.tsx",
1093
- "_index-DFc7og1d.cjs",
1094
- "src/components/Toaster/Toast.tsx",
1095
- "src/components/Form/FormBase.tsx",
1096
- "src/components/Form/FormField.tsx",
1097
- "_Form-CSMiPnjC.cjs",
1098
- "src/components/DictionaryEditor/validDictionaryChangeButtons.content.tsx",
1099
1014
  "src/components/DictionaryFieldEditor/getIsEditableSection.ts",
1100
1015
  "src/components/DictionaryFieldEditor/NavigationView/navigationViewNode.content.ts"
1101
1016
  ]
@@ -1113,21 +1028,7 @@
1113
1028
  "isEntry": true,
1114
1029
  "imports": [
1115
1030
  "_jsx-runtime-CgFM7lM3.cjs",
1116
- "_shallow-lhDIFtEp.cjs",
1117
1031
  "src/components/Container/index.tsx",
1118
- "src/components/DictionaryEditor/useEditedContentStore.ts",
1119
- "src/components/DictionaryEditor/useEditionPanelStore.ts",
1120
- "src/components/Button/Button.tsx",
1121
- "src/components/EditableField/EditableFieldInput.tsx",
1122
- "src/components/EditableField/EditableFieldTextArea.tsx",
1123
- "src/hooks/useScrollBlockage/useScrollBlockageStore.ts",
1124
- "src/hooks/useAsync/useAsyncStateStore.tsx",
1125
- "_index-DFc7og1d.cjs",
1126
- "src/components/Toaster/Toast.tsx",
1127
- "src/components/Form/FormBase.tsx",
1128
- "src/components/Form/FormField.tsx",
1129
- "_Form-CSMiPnjC.cjs",
1130
- "src/components/DictionaryEditor/validDictionaryChangeButtons.content.tsx",
1131
1032
  "src/components/LocaleSwitcherContentDropDown/LocaleSwitcherContent.tsx",
1132
1033
  "src/components/LocaleSwitcherContentDropDown/LocaleSwitcherContentContext.tsx",
1133
1034
  "src/components/DictionaryFieldEditor/EditorView/EditorView.tsx",
@@ -1142,21 +1043,6 @@
1142
1043
  "isEntry": true,
1143
1044
  "imports": [
1144
1045
  "_jsx-runtime-CgFM7lM3.cjs",
1145
- "_shallow-lhDIFtEp.cjs",
1146
- "src/utils/dictionary.ts",
1147
- "src/components/DictionaryEditor/useEditedContentStore.ts",
1148
- "src/components/DictionaryEditor/useEditionPanelStore.ts",
1149
- "src/components/Button/Button.tsx",
1150
- "src/components/EditableField/EditableFieldInput.tsx",
1151
- "src/components/EditableField/EditableFieldTextArea.tsx",
1152
- "src/hooks/useScrollBlockage/useScrollBlockageStore.ts",
1153
- "src/hooks/useAsync/useAsyncStateStore.tsx",
1154
- "_index-DFc7og1d.cjs",
1155
- "src/components/Toaster/Toast.tsx",
1156
- "src/components/Form/FormBase.tsx",
1157
- "src/components/Form/FormField.tsx",
1158
- "_Form-CSMiPnjC.cjs",
1159
- "src/components/DictionaryEditor/validDictionaryChangeButtons.content.tsx",
1160
1046
  "src/components/Select/Multiselect.tsx",
1161
1047
  "src/components/Select/Select.tsx",
1162
1048
  "src/components/DictionaryFieldEditor/nodeTypeSelector.content.ts"
@@ -1169,7 +1055,6 @@
1169
1055
  "isEntry": true,
1170
1056
  "imports": [
1171
1057
  "_jsx-runtime-CgFM7lM3.cjs",
1172
- "_shallow-lhDIFtEp.cjs",
1173
1058
  "_index-DFc7og1d.cjs",
1174
1059
  "src/components/Button/Button.tsx",
1175
1060
  "src/components/Auth/ExternalsLoginButtons/externalsLoginButtons.content.ts",
@@ -1189,11 +1074,6 @@
1189
1074
  "src/components/Auth/ResetPasswordForm/resetPasswordContent.content.ts",
1190
1075
  "src/components/Auth/ResetPasswordForm/useResetPasswordSchema.content.ts",
1191
1076
  "src/components/Modal/Modal.tsx",
1192
- "src/components/DictionaryEditor/useEditedContentStore.ts",
1193
- "src/components/DictionaryEditor/useEditionPanelStore.ts",
1194
- "src/components/EditableField/EditableFieldInput.tsx",
1195
- "src/components/EditableField/EditableFieldTextArea.tsx",
1196
- "src/components/DictionaryEditor/validDictionaryChangeButtons.content.tsx",
1197
1077
  "src/components/DictionaryFieldEditor/SaveForm/saveForm.content.tsx",
1198
1078
  "src/components/DictionaryFieldEditor/SaveForm/SaveFormSchema.ts"
1199
1079
  ]
@@ -2224,7 +2104,7 @@
2224
2104
  "imports": [
2225
2105
  "_jsx-runtime-CgFM7lM3.cjs",
2226
2106
  "src/hooks/useGetElementOrWindow.ts",
2227
- "src/hooks/useScrollBlockage/index.tsx",
2107
+ "_index-Cg-S9ry9.cjs",
2228
2108
  "src/hooks/useAsync/useAsyncStateStore.tsx",
2229
2109
  "_index-DFc7og1d.cjs",
2230
2110
  "src/components/Toaster/Toast.tsx",
@@ -2269,7 +2149,7 @@
2269
2149
  "isEntry": true,
2270
2150
  "imports": [
2271
2151
  "_jsx-runtime-CgFM7lM3.cjs",
2272
- "src/hooks/useScrollBlockage/index.tsx",
2152
+ "_index-Cg-S9ry9.cjs",
2273
2153
  "src/hooks/useScrollDetection.ts",
2274
2154
  "src/hooks/useAsync/useAsyncStateStore.tsx",
2275
2155
  "_index-DFc7og1d.cjs",
@@ -2390,9 +2270,8 @@
2390
2270
  "isEntry": true,
2391
2271
  "imports": [
2392
2272
  "_jsx-runtime-CgFM7lM3.cjs",
2393
- "_shallow-lhDIFtEp.cjs",
2273
+ "_index-Cg-S9ry9.cjs",
2394
2274
  "src/hooks/useDevice.ts",
2395
- "src/hooks/useScrollBlockage/index.tsx",
2396
2275
  "src/utils/isElementAtTopAndNotCovered.tsx",
2397
2276
  "src/components/Container/index.tsx",
2398
2277
  "src/components/MaxWidthSmoother/index.tsx",
@@ -2630,8 +2509,6 @@
2630
2509
  "src/components/RightDrawer/useRightDrawerStore.ts",
2631
2510
  "src/components/PressableSpan/PressableSpan.tsx",
2632
2511
  "src/components/ContentSelector/ContentSelector.tsx",
2633
- "src/components/DictionaryEditor/useEditedContentStore.ts",
2634
- "src/components/DictionaryEditor/useEditionPanelStore.ts",
2635
2512
  "src/components/DictionaryEditor/DictionaryEditor.tsx",
2636
2513
  "src/components/DictionaryFieldEditor/DictionariesSelector/DictionariesSelector.tsx",
2637
2514
  "src/components/DictionaryFieldEditor/DictionaryCreationForm/DictionaryCreationForm.tsx",
@@ -2703,8 +2580,7 @@
2703
2580
  "src/components/LocaleSwitcherDropDown/LocaleSwitcher.tsx",
2704
2581
  "src/components/LocaleSwitcherContentDropDown/LocaleSwitcherContent.tsx",
2705
2582
  "src/components/LocaleSwitcherContentDropDown/LocaleSwitcherContentContext.tsx",
2706
- "src/components/ClickOutsideDiv/index.tsx",
2707
- "src/utils/dictionary.ts"
2583
+ "src/components/ClickOutsideDiv/index.tsx"
2708
2584
  ]
2709
2585
  },
2710
2586
  "src/hooks/index.ts": {
@@ -2715,7 +2591,7 @@
2715
2591
  "imports": [
2716
2592
  "src/hooks/useDevice.ts",
2717
2593
  "src/hooks/useGetElementOrWindow.ts",
2718
- "src/hooks/useScrollBlockage/index.tsx",
2594
+ "_index-Cg-S9ry9.cjs",
2719
2595
  "src/hooks/useIsMounted.ts",
2720
2596
  "src/hooks/useScrollDetection.ts",
2721
2597
  "src/hooks/useAsync/useAsync.ts",
@@ -2839,7 +2715,7 @@
2839
2715
  "src": "src/hooks/useScrollBlockage/index.tsx",
2840
2716
  "isEntry": true,
2841
2717
  "imports": [
2842
- "_shallow-lhDIFtEp.cjs",
2718
+ "_index-Cg-S9ry9.cjs",
2843
2719
  "src/hooks/useGetElementOrWindow.ts",
2844
2720
  "src/hooks/useScrollBlockage/useScrollBlockageStore.ts"
2845
2721
  ]
@@ -2857,7 +2733,7 @@
2857
2733
  "isEntry": true,
2858
2734
  "imports": [
2859
2735
  "src/hooks/useGetElementOrWindow.ts",
2860
- "src/hooks/useScrollBlockage/index.tsx"
2736
+ "_index-Cg-S9ry9.cjs"
2861
2737
  ]
2862
2738
  },
2863
2739
  "src/tailwind.config.ts": {
@@ -2884,12 +2760,6 @@
2884
2760
  "src": "src/utils/cn.ts",
2885
2761
  "isEntry": true
2886
2762
  },
2887
- "src/utils/dictionary.ts": {
2888
- "file": "utils/dictionary.cjs",
2889
- "name": "utils/dictionary",
2890
- "src": "src/utils/dictionary.ts",
2891
- "isEntry": true
2892
- },
2893
2763
  "src/utils/isElementAtTopAndNotCovered.tsx": {
2894
2764
  "file": "utils/isElementAtTopAndNotCovered.cjs",
2895
2765
  "name": "utils/isElementAtTopAndNotCovered",
@@ -21,7 +21,7 @@ const Accordion = ({
21
21
  setIsOpen(isOpenDefault);
22
22
  }
23
23
  }, [isOpenDefault]);
24
- return /* @__PURE__ */ jsxRuntime.jsxRuntimeExports.jsxs("div", { children: [
24
+ return /* @__PURE__ */ jsxRuntime.jsxRuntimeExports.jsxs("div", { className: "w-full", children: [
25
25
  /* @__PURE__ */ jsxRuntime.jsxRuntimeExports.jsx(
26
26
  components_Button_Button.Button,
27
27
  {
@@ -1 +1 @@
1
- {"version":3,"file":"Accordion.cjs","sources":["../../../src/components/Accordion/Accordion.tsx"],"sourcesContent":["'use client';\n\nimport { ChevronDown } from 'lucide-react';\nimport { useEffect, useState, type FC, type ReactNode } from 'react';\nimport { cn } from '../../utils/cn';\nimport { Button, ButtonProps } from '../Button';\nimport { MaxHeightSmoother } from '../MaxHeightSmoother';\n\ntype AccordionProps = {\n header: ReactNode;\n children: ReactNode;\n isOpen?: boolean;\n} & ButtonProps;\n\n/**\n * Accordion component that allows the user to expand and collapse content.\n * It provides a header with a chevron icon that controls the visibility of the content.\n *\n * @param header - The content of the header.\n * @param children - The content to be expanded and collapsed.\n * @param isOpen - Whether the content is expanded or collapsed by default.\n *\n * @example\n * <Accordion header=\"Accordion Header\" isOpen={true}>\n * <p>Accordion content</p>\n * </Accordion>\n *\n */\nexport const Accordion: FC<AccordionProps> = ({\n children,\n header,\n isOpen: isOpenDefault = false,\n onClick,\n ...props\n}) => {\n const [isOpen, setIsOpen] = useState(isOpenDefault);\n const isHidden = isOpen == undefined ? undefined : !isOpen;\n\n useEffect(() => {\n if (isOpenDefault != undefined) {\n setIsOpen(isOpenDefault);\n }\n }, [isOpenDefault]);\n\n return (\n <div>\n <Button\n variant=\"hoverable\"\n color=\"text\"\n onClick={(e) => {\n setIsOpen((prevIsOpen) => !prevIsOpen);\n onClick?.(e);\n }}\n isFullWidth\n className=\"flex items-center justify-between gap-2 bg-red-300\"\n IconRight={ChevronDown}\n iconClassName={cn(\n 'transform transition-transform duration-500 ease-in-out',\n isOpen ? 'rotate-0' : '-rotate-180'\n )}\n {...props}\n >\n {header}\n </Button>\n\n <MaxHeightSmoother\n tabIndex={isHidden !== false ? undefined : -1}\n isHidden={isHidden}\n >\n {children}\n </MaxHeightSmoother>\n </div>\n );\n};\n"],"names":["useState","useEffect","jsx","Button","ChevronDown","cn","MaxHeightSmoother"],"mappings":";;;;;;;;;AA4BO,MAAM,YAAgC,CAAC;AAAA,EAC5C;AAAA,EACA;AAAA,EACA,QAAQ,gBAAgB;AAAA,EACxB;AAAA,EACA,GAAG;AACL,MAAM;AACJ,QAAM,CAAC,QAAQ,SAAS,IAAIA,WAAAA,SAAS,aAAa;AAClD,QAAM,WAAW,UAAU,SAAY,SAAY,CAAC;AAEpDC,aAAAA,UAAU,MAAM;AACd,QAAI,iBAAiB,QAAW;AAC9B,gBAAU,aAAa;AAAA,IAAA;AAAA,EACzB,GACC,CAAC,aAAa,CAAC;AAElB,2DACG,OACC,EAAA,UAAA;AAAA,IAAAC,2BAAA,kBAAA;AAAA,MAACC,yBAAA;AAAA,MAAA;AAAA,QACC,SAAQ;AAAA,QACR,OAAM;AAAA,QACN,SAAS,CAAC,MAAM;AACJ,oBAAA,CAAC,eAAe,CAAC,UAAU;AACrC,oBAAU,CAAC;AAAA,QACb;AAAA,QACA,aAAW;AAAA,QACX,WAAU;AAAA,QACV,WAAWC,YAAA;AAAA,QACX,eAAeC,SAAA;AAAA,UACb;AAAA,UACA,SAAS,aAAa;AAAA,QACxB;AAAA,QACC,GAAG;AAAA,QAEH,UAAA;AAAA,MAAA;AAAA,IACH;AAAA,IAEAH,2BAAA,kBAAA;AAAA,MAACI,mCAAA;AAAA,MAAA;AAAA,QACC,UAAU,aAAa,QAAQ,SAAY;AAAA,QAC3C;AAAA,QAEC;AAAA,MAAA;AAAA,IAAA;AAAA,EACH,GACF;AAEJ;;"}
1
+ {"version":3,"file":"Accordion.cjs","sources":["../../../src/components/Accordion/Accordion.tsx"],"sourcesContent":["'use client';\n\nimport { ChevronDown } from 'lucide-react';\nimport { useEffect, useState, type FC, type ReactNode } from 'react';\nimport { cn } from '../../utils/cn';\nimport { Button, ButtonProps } from '../Button';\nimport { MaxHeightSmoother } from '../MaxHeightSmoother';\n\ntype AccordionProps = {\n header: ReactNode;\n children: ReactNode;\n isOpen?: boolean;\n} & ButtonProps;\n\n/**\n * Accordion component that allows the user to expand and collapse content.\n * It provides a header with a chevron icon that controls the visibility of the content.\n *\n * @param header - The content of the header.\n * @param children - The content to be expanded and collapsed.\n * @param isOpen - Whether the content is expanded or collapsed by default.\n *\n * @example\n * <Accordion header=\"Accordion Header\" isOpen={true}>\n * <p>Accordion content</p>\n * </Accordion>\n *\n */\nexport const Accordion: FC<AccordionProps> = ({\n children,\n header,\n isOpen: isOpenDefault = false,\n onClick,\n ...props\n}) => {\n const [isOpen, setIsOpen] = useState(isOpenDefault);\n const isHidden = isOpen == undefined ? undefined : !isOpen;\n\n useEffect(() => {\n if (isOpenDefault != undefined) {\n setIsOpen(isOpenDefault);\n }\n }, [isOpenDefault]);\n\n return (\n <div className=\"w-full\">\n <Button\n variant=\"hoverable\"\n color=\"text\"\n onClick={(e) => {\n setIsOpen((prevIsOpen) => !prevIsOpen);\n onClick?.(e);\n }}\n isFullWidth\n className=\"flex items-center justify-between gap-2 bg-red-300\"\n IconRight={ChevronDown}\n iconClassName={cn(\n 'transform transition-transform duration-500 ease-in-out',\n isOpen ? 'rotate-0' : '-rotate-180'\n )}\n {...props}\n >\n {header}\n </Button>\n\n <MaxHeightSmoother\n tabIndex={isHidden !== false ? undefined : -1}\n isHidden={isHidden}\n >\n {children}\n </MaxHeightSmoother>\n </div>\n );\n};\n"],"names":["useState","useEffect","jsxs","jsx","Button","ChevronDown","cn","MaxHeightSmoother"],"mappings":";;;;;;;;;AA4BO,MAAM,YAAgC,CAAC;AAAA,EAC5C;AAAA,EACA;AAAA,EACA,QAAQ,gBAAgB;AAAA,EACxB;AAAA,EACA,GAAG;AACL,MAAM;AACJ,QAAM,CAAC,QAAQ,SAAS,IAAIA,WAAAA,SAAS,aAAa;AAClD,QAAM,WAAW,UAAU,SAAY,SAAY,CAAC;AAEpDC,aAAAA,UAAU,MAAM;AACd,QAAI,iBAAiB,QAAW;AAC9B,gBAAU,aAAa;AAAA,IAAA;AAAA,EACzB,GACC,CAAC,aAAa,CAAC;AAGhB,SAAAC,2BAAA,kBAAA,KAAC,OAAI,EAAA,WAAU,UACb,UAAA;AAAA,IAAAC,2BAAA,kBAAA;AAAA,MAACC,yBAAA;AAAA,MAAA;AAAA,QACC,SAAQ;AAAA,QACR,OAAM;AAAA,QACN,SAAS,CAAC,MAAM;AACJ,oBAAA,CAAC,eAAe,CAAC,UAAU;AACrC,oBAAU,CAAC;AAAA,QACb;AAAA,QACA,aAAW;AAAA,QACX,WAAU;AAAA,QACV,WAAWC,YAAA;AAAA,QACX,eAAeC,SAAA;AAAA,UACb;AAAA,UACA,SAAS,aAAa;AAAA,QACxB;AAAA,QACC,GAAG;AAAA,QAEH,UAAA;AAAA,MAAA;AAAA,IACH;AAAA,IAEAH,2BAAA,kBAAA;AAAA,MAACI,mCAAA;AAAA,MAAA;AAAA,QACC,UAAU,aAAa,QAAQ,SAAY;AAAA,QAC3C;AAAA,QAEC;AAAA,MAAA;AAAA,IAAA;AAAA,EACH,GACF;AAEJ;;"}
@@ -19,7 +19,7 @@ const Accordion = ({
19
19
  setIsOpen(isOpenDefault);
20
20
  }
21
21
  }, [isOpenDefault]);
22
- return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
22
+ return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "w-full", children: [
23
23
  /* @__PURE__ */ jsxRuntimeExports.jsx(
24
24
  Button,
25
25
  {
@@ -1 +1 @@
1
- {"version":3,"file":"Accordion.mjs","sources":["../../../src/components/Accordion/Accordion.tsx"],"sourcesContent":["'use client';\n\nimport { ChevronDown } from 'lucide-react';\nimport { useEffect, useState, type FC, type ReactNode } from 'react';\nimport { cn } from '../../utils/cn';\nimport { Button, ButtonProps } from '../Button';\nimport { MaxHeightSmoother } from '../MaxHeightSmoother';\n\ntype AccordionProps = {\n header: ReactNode;\n children: ReactNode;\n isOpen?: boolean;\n} & ButtonProps;\n\n/**\n * Accordion component that allows the user to expand and collapse content.\n * It provides a header with a chevron icon that controls the visibility of the content.\n *\n * @param header - The content of the header.\n * @param children - The content to be expanded and collapsed.\n * @param isOpen - Whether the content is expanded or collapsed by default.\n *\n * @example\n * <Accordion header=\"Accordion Header\" isOpen={true}>\n * <p>Accordion content</p>\n * </Accordion>\n *\n */\nexport const Accordion: FC<AccordionProps> = ({\n children,\n header,\n isOpen: isOpenDefault = false,\n onClick,\n ...props\n}) => {\n const [isOpen, setIsOpen] = useState(isOpenDefault);\n const isHidden = isOpen == undefined ? undefined : !isOpen;\n\n useEffect(() => {\n if (isOpenDefault != undefined) {\n setIsOpen(isOpenDefault);\n }\n }, [isOpenDefault]);\n\n return (\n <div>\n <Button\n variant=\"hoverable\"\n color=\"text\"\n onClick={(e) => {\n setIsOpen((prevIsOpen) => !prevIsOpen);\n onClick?.(e);\n }}\n isFullWidth\n className=\"flex items-center justify-between gap-2 bg-red-300\"\n IconRight={ChevronDown}\n iconClassName={cn(\n 'transform transition-transform duration-500 ease-in-out',\n isOpen ? 'rotate-0' : '-rotate-180'\n )}\n {...props}\n >\n {header}\n </Button>\n\n <MaxHeightSmoother\n tabIndex={isHidden !== false ? undefined : -1}\n isHidden={isHidden}\n >\n {children}\n </MaxHeightSmoother>\n </div>\n );\n};\n"],"names":["jsx"],"mappings":";;;;;;;AA4BO,MAAM,YAAgC,CAAC;AAAA,EAC5C;AAAA,EACA;AAAA,EACA,QAAQ,gBAAgB;AAAA,EACxB;AAAA,EACA,GAAG;AACL,MAAM;AACJ,QAAM,CAAC,QAAQ,SAAS,IAAI,SAAS,aAAa;AAClD,QAAM,WAAW,UAAU,SAAY,SAAY,CAAC;AAEpD,YAAU,MAAM;AACd,QAAI,iBAAiB,QAAW;AAC9B,gBAAU,aAAa;AAAA,IAAA;AAAA,EACzB,GACC,CAAC,aAAa,CAAC;AAElB,gDACG,OACC,EAAA,UAAA;AAAA,IAAAA,kCAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,SAAQ;AAAA,QACR,OAAM;AAAA,QACN,SAAS,CAAC,MAAM;AACJ,oBAAA,CAAC,eAAe,CAAC,UAAU;AACrC,oBAAU,CAAC;AAAA,QACb;AAAA,QACA,aAAW;AAAA,QACX,WAAU;AAAA,QACV,WAAW;AAAA,QACX,eAAe;AAAA,UACb;AAAA,UACA,SAAS,aAAa;AAAA,QACxB;AAAA,QACC,GAAG;AAAA,QAEH,UAAA;AAAA,MAAA;AAAA,IACH;AAAA,IAEAA,kCAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,UAAU,aAAa,QAAQ,SAAY;AAAA,QAC3C;AAAA,QAEC;AAAA,MAAA;AAAA,IAAA;AAAA,EACH,GACF;AAEJ;"}
1
+ {"version":3,"file":"Accordion.mjs","sources":["../../../src/components/Accordion/Accordion.tsx"],"sourcesContent":["'use client';\n\nimport { ChevronDown } from 'lucide-react';\nimport { useEffect, useState, type FC, type ReactNode } from 'react';\nimport { cn } from '../../utils/cn';\nimport { Button, ButtonProps } from '../Button';\nimport { MaxHeightSmoother } from '../MaxHeightSmoother';\n\ntype AccordionProps = {\n header: ReactNode;\n children: ReactNode;\n isOpen?: boolean;\n} & ButtonProps;\n\n/**\n * Accordion component that allows the user to expand and collapse content.\n * It provides a header with a chevron icon that controls the visibility of the content.\n *\n * @param header - The content of the header.\n * @param children - The content to be expanded and collapsed.\n * @param isOpen - Whether the content is expanded or collapsed by default.\n *\n * @example\n * <Accordion header=\"Accordion Header\" isOpen={true}>\n * <p>Accordion content</p>\n * </Accordion>\n *\n */\nexport const Accordion: FC<AccordionProps> = ({\n children,\n header,\n isOpen: isOpenDefault = false,\n onClick,\n ...props\n}) => {\n const [isOpen, setIsOpen] = useState(isOpenDefault);\n const isHidden = isOpen == undefined ? undefined : !isOpen;\n\n useEffect(() => {\n if (isOpenDefault != undefined) {\n setIsOpen(isOpenDefault);\n }\n }, [isOpenDefault]);\n\n return (\n <div className=\"w-full\">\n <Button\n variant=\"hoverable\"\n color=\"text\"\n onClick={(e) => {\n setIsOpen((prevIsOpen) => !prevIsOpen);\n onClick?.(e);\n }}\n isFullWidth\n className=\"flex items-center justify-between gap-2 bg-red-300\"\n IconRight={ChevronDown}\n iconClassName={cn(\n 'transform transition-transform duration-500 ease-in-out',\n isOpen ? 'rotate-0' : '-rotate-180'\n )}\n {...props}\n >\n {header}\n </Button>\n\n <MaxHeightSmoother\n tabIndex={isHidden !== false ? undefined : -1}\n isHidden={isHidden}\n >\n {children}\n </MaxHeightSmoother>\n </div>\n );\n};\n"],"names":["jsxs","jsx"],"mappings":";;;;;;;AA4BO,MAAM,YAAgC,CAAC;AAAA,EAC5C;AAAA,EACA;AAAA,EACA,QAAQ,gBAAgB;AAAA,EACxB;AAAA,EACA,GAAG;AACL,MAAM;AACJ,QAAM,CAAC,QAAQ,SAAS,IAAI,SAAS,aAAa;AAClD,QAAM,WAAW,UAAU,SAAY,SAAY,CAAC;AAEpD,YAAU,MAAM;AACd,QAAI,iBAAiB,QAAW;AAC9B,gBAAU,aAAa;AAAA,IAAA;AAAA,EACzB,GACC,CAAC,aAAa,CAAC;AAGhB,SAAAA,kCAAA,KAAC,OAAI,EAAA,WAAU,UACb,UAAA;AAAA,IAAAC,kCAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,SAAQ;AAAA,QACR,OAAM;AAAA,QACN,SAAS,CAAC,MAAM;AACJ,oBAAA,CAAC,eAAe,CAAC,UAAU;AACrC,oBAAU,CAAC;AAAA,QACb;AAAA,QACA,aAAW;AAAA,QACX,WAAU;AAAA,QACV,WAAW;AAAA,QACX,eAAe;AAAA,UACb;AAAA,UACA,SAAS,aAAa;AAAA,QACxB;AAAA,QACC,GAAG;AAAA,QAEH,UAAA;AAAA,MAAA;AAAA,IACH;AAAA,IAEAA,kCAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,UAAU,aAAa,QAAQ,SAAY;AAAA,QAC3C;AAAA,QAEC;AAAA,MAAA;AAAA,IAAA;AAAA,EACH,GACF;AAEJ;"}
@@ -3,27 +3,15 @@
3
3
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
4
4
  const jsxRuntime = require("../../jsx-runtime-CgFM7lM3.cjs");
5
5
  const require$$0 = require("react");
6
- const shallow = require("../../shallow-lhDIFtEp.cjs");
6
+ const editorReact = require("@intlayer/editor-react");
7
7
  const components_DictionaryEditor_NodeWrapper_ArrayWrapper = require("../../index-DTCehvKe.cjs");
8
- const components_DictionaryEditor_useEditedContentStore = require("./useEditedContentStore.cjs");
9
- const components_DictionaryEditor_useEditionPanelStore = require("./useEditionPanelStore.cjs");
10
8
  const components_DictionaryEditor_ValidDictionaryChangeButtons = require("./ValidDictionaryChangeButtons.cjs");
11
9
  const DictionaryEditor = ({
12
10
  dictionary,
13
11
  ...props
14
12
  }) => {
15
- const { addEditedContent, editedContent } = components_DictionaryEditor_useEditedContentStore.useEditedContentStore(
16
- shallow.useShallow((s) => ({
17
- addEditedContent: s.addEditedContent,
18
- editedContent: s.editedContent
19
- }))
20
- );
21
- const { focusedContent, setFocusedContentKeyPath } = components_DictionaryEditor_useEditionPanelStore.useEditionPanelStore(
22
- shallow.useShallow((s) => ({
23
- focusedContent: s.focusedContent,
24
- setFocusedContentKeyPath: s.setFocusedContentKeyPath
25
- }))
26
- );
13
+ const { editedContent, addEditedContent } = editorReact.useEditedContent();
14
+ const { focusedContent, setFocusedContentKeyPath } = editorReact.useFocusDictionary();
27
15
  const focusedKeyPath = focusedContent?.keyPath;
28
16
  return /* @__PURE__ */ jsxRuntime.jsxRuntimeExports.jsxs("div", { className: "flex h-full flex-col justify-between gap-2", children: [
29
17
  /* @__PURE__ */ jsxRuntime.jsxRuntimeExports.jsx("div", { children: /* @__PURE__ */ require$$0.createElement(
@@ -1 +1 @@
1
- {"version":3,"file":"DictionaryEditor.cjs","sources":["../../../src/components/DictionaryEditor/DictionaryEditor.tsx"],"sourcesContent":["'use client';\n\nimport type { Locales } from '@intlayer/config/client';\nimport type { Dictionary, KeyPath } from '@intlayer/core';\nimport type { FC } from 'react';\nimport { useShallow } from 'zustand/react/shallow';\nimport { NodeWrapper } from './NodeWrapper';\nimport { useEditedContentStore } from './useEditedContentStore';\nimport { useEditionPanelStore } from './useEditionPanelStore';\nimport { ValidDictionaryChangeButtons } from './ValidDictionaryChangeButtons';\n\ntype DictionaryEditorProps = {\n dictionary: Dictionary;\n locale: Locales;\n onClickEdit?: (keyPath: KeyPath[]) => void;\n};\n\nexport const DictionaryEditor: FC<DictionaryEditorProps> = ({\n dictionary,\n ...props\n}) => {\n const { addEditedContent, editedContent } = useEditedContentStore(\n useShallow((s) => ({\n addEditedContent: s.addEditedContent,\n editedContent: s.editedContent,\n }))\n );\n const { focusedContent, setFocusedContentKeyPath } = useEditionPanelStore(\n useShallow((s) => ({\n focusedContent: s.focusedContent,\n setFocusedContentKeyPath: s.setFocusedContentKeyPath,\n }))\n );\n\n const focusedKeyPath = focusedContent?.keyPath;\n\n return (\n <div className=\"flex h-full flex-col justify-between gap-2\">\n <div>\n <NodeWrapper\n {...props}\n keyPath={[]}\n key={JSON.stringify(\n (editedContent[dictionary.key] ?? dictionary).content\n )}\n editedContent={editedContent[dictionary.key]?.content}\n focusedKeyPath={focusedKeyPath}\n section={dictionary.content}\n onContentChange={(content) => {\n addEditedContent(dictionary.key, content.newValue, content.keyPath);\n }}\n onFocusKeyPath={setFocusedContentKeyPath}\n />\n </div>\n <ValidDictionaryChangeButtons dictionary={dictionary} />\n </div>\n );\n};\n"],"names":["useEditedContentStore","useShallow","useEditionPanelStore","jsxs","jsx","createElement","NodeWrapper","ValidDictionaryChangeButtons"],"mappings":";;;;;;;;;;AAiBO,MAAM,mBAA8C,CAAC;AAAA,EAC1D;AAAA,EACA,GAAG;AACL,MAAM;AACE,QAAA,EAAE,kBAAkB,cAAA,IAAkBA,kDAAA;AAAA,IAC1CC,QAAA,WAAW,CAAC,OAAO;AAAA,MACjB,kBAAkB,EAAE;AAAA,MACpB,eAAe,EAAE;AAAA,IAAA,EACjB;AAAA,EACJ;AACM,QAAA,EAAE,gBAAgB,yBAAA,IAA6BC,iDAAA;AAAA,IACnDD,QAAA,WAAW,CAAC,OAAO;AAAA,MACjB,gBAAgB,EAAE;AAAA,MAClB,0BAA0B,EAAE;AAAA,IAAA,EAC5B;AAAA,EACJ;AAEA,QAAM,iBAAiB,gBAAgB;AAGrC,SAAAE,2BAAA,kBAAA,KAAC,OAAI,EAAA,WAAU,8CACb,UAAA;AAAA,IAAAC,iDAAC,OACC,EAAA,UAAAC,2BAAA;AAAA,MAACC,qDAAA;AAAA,MAAA;AAAA,QACE,GAAG;AAAA,QACJ,SAAS,CAAC;AAAA,QACV,KAAK,KAAK;AAAA,WACP,cAAc,WAAW,GAAG,KAAK,YAAY;AAAA,QAChD;AAAA,QACA,eAAe,cAAc,WAAW,GAAG,GAAG;AAAA,QAC9C;AAAA,QACA,SAAS,WAAW;AAAA,QACpB,iBAAiB,CAAC,YAAY;AAC5B,2BAAiB,WAAW,KAAK,QAAQ,UAAU,QAAQ,OAAO;AAAA,QACpE;AAAA,QACA,gBAAgB;AAAA,MAAA;AAAA,IAAA,GAEpB;AAAA,IACAF,iDAACG,yDAAAA,gCAA6B,WAAwB,CAAA;AAAA,EAAA,GACxD;AAEJ;;"}
1
+ {"version":3,"file":"DictionaryEditor.cjs","sources":["../../../src/components/DictionaryEditor/DictionaryEditor.tsx"],"sourcesContent":["'use client';\n\nimport type { Locales } from '@intlayer/config/client';\nimport type { Dictionary, KeyPath } from '@intlayer/core';\nimport { useEditedContent, useFocusDictionary } from '@intlayer/editor-react';\nimport type { FC } from 'react';\nimport { NodeWrapper } from './NodeWrapper';\nimport { ValidDictionaryChangeButtons } from './ValidDictionaryChangeButtons';\n\ntype DictionaryEditorProps = {\n dictionary: Dictionary;\n locale: Locales;\n onClickEdit?: (keyPath: KeyPath[]) => void;\n};\n\nexport const DictionaryEditor: FC<DictionaryEditorProps> = ({\n dictionary,\n ...props\n}) => {\n const { editedContent, addEditedContent } = useEditedContent();\n const { focusedContent, setFocusedContentKeyPath } = useFocusDictionary();\n\n const focusedKeyPath = focusedContent?.keyPath;\n\n return (\n <div className=\"flex h-full flex-col justify-between gap-2\">\n <div>\n <NodeWrapper\n {...props}\n keyPath={[]}\n key={JSON.stringify(\n (editedContent[dictionary.key] ?? dictionary).content\n )}\n editedContent={editedContent[dictionary.key]?.content}\n focusedKeyPath={focusedKeyPath}\n section={dictionary.content}\n onContentChange={(content) => {\n addEditedContent(dictionary.key, content.newValue, content.keyPath);\n }}\n onFocusKeyPath={setFocusedContentKeyPath}\n />\n </div>\n <ValidDictionaryChangeButtons dictionary={dictionary} />\n </div>\n );\n};\n"],"names":["useEditedContent","useFocusDictionary","jsxs","jsx","createElement","NodeWrapper","ValidDictionaryChangeButtons"],"mappings":";;;;;;;;AAeO,MAAM,mBAA8C,CAAC;AAAA,EAC1D;AAAA,EACA,GAAG;AACL,MAAM;AACJ,QAAM,EAAE,eAAe,iBAAiB,IAAIA,6BAAiB;AAC7D,QAAM,EAAE,gBAAgB,yBAAyB,IAAIC,+BAAmB;AAExE,QAAM,iBAAiB,gBAAgB;AAGrC,SAAAC,2BAAA,kBAAA,KAAC,OAAI,EAAA,WAAU,8CACb,UAAA;AAAA,IAAAC,iDAAC,OACC,EAAA,UAAAC,2BAAA;AAAA,MAACC,qDAAA;AAAA,MAAA;AAAA,QACE,GAAG;AAAA,QACJ,SAAS,CAAC;AAAA,QACV,KAAK,KAAK;AAAA,WACP,cAAc,WAAW,GAAG,KAAK,YAAY;AAAA,QAChD;AAAA,QACA,eAAe,cAAc,WAAW,GAAG,GAAG;AAAA,QAC9C;AAAA,QACA,SAAS,WAAW;AAAA,QACpB,iBAAiB,CAAC,YAAY;AAC5B,2BAAiB,WAAW,KAAK,QAAQ,UAAU,QAAQ,OAAO;AAAA,QACpE;AAAA,QACA,gBAAgB;AAAA,MAAA;AAAA,IAAA,GAEpB;AAAA,IACAF,iDAACG,yDAAAA,gCAA6B,WAAwB,CAAA;AAAA,EAAA,GACxD;AAEJ;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"DictionaryEditor.d.ts","sourceRoot":"","sources":["../../../src/components/DictionaryEditor/DictionaryEditor.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAC;AACvD,OAAO,KAAK,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAC1D,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAOhC,KAAK,qBAAqB,GAAG;IAC3B,UAAU,EAAE,UAAU,CAAC;IACvB,MAAM,EAAE,OAAO,CAAC;IAChB,WAAW,CAAC,EAAE,CAAC,OAAO,EAAE,OAAO,EAAE,KAAK,IAAI,CAAC;CAC5C,CAAC;AAEF,eAAO,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,CAwCtD,CAAC"}
1
+ {"version":3,"file":"DictionaryEditor.d.ts","sourceRoot":"","sources":["../../../src/components/DictionaryEditor/DictionaryEditor.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAC;AACvD,OAAO,KAAK,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAE1D,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAIhC,KAAK,qBAAqB,GAAG;IAC3B,UAAU,EAAE,UAAU,CAAC;IACvB,MAAM,EAAE,OAAO,CAAC;IAChB,WAAW,CAAC,EAAE,CAAC,OAAO,EAAE,OAAO,EAAE,KAAK,IAAI,CAAC;CAC5C,CAAC;AAEF,eAAO,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,CA8BtD,CAAC"}
@@ -1,27 +1,15 @@
1
1
  "use client";
2
2
  import { j as jsxRuntimeExports } from "../../jsx-runtime-DQkoUcjV.js";
3
3
  import { createElement } from "react";
4
- import { u as useShallow } from "../../shallow-m9BpCkKh.js";
4
+ import { useEditedContent, useFocusDictionary } from "@intlayer/editor-react";
5
5
  import { N as NodeWrapper } from "../../index-BdTa-9zc.js";
6
- import { useEditedContentStore } from "./useEditedContentStore.mjs";
7
- import { useEditionPanelStore } from "./useEditionPanelStore.mjs";
8
6
  import { ValidDictionaryChangeButtons } from "./ValidDictionaryChangeButtons.mjs";
9
7
  const DictionaryEditor = ({
10
8
  dictionary,
11
9
  ...props
12
10
  }) => {
13
- const { addEditedContent, editedContent } = useEditedContentStore(
14
- useShallow((s) => ({
15
- addEditedContent: s.addEditedContent,
16
- editedContent: s.editedContent
17
- }))
18
- );
19
- const { focusedContent, setFocusedContentKeyPath } = useEditionPanelStore(
20
- useShallow((s) => ({
21
- focusedContent: s.focusedContent,
22
- setFocusedContentKeyPath: s.setFocusedContentKeyPath
23
- }))
24
- );
11
+ const { editedContent, addEditedContent } = useEditedContent();
12
+ const { focusedContent, setFocusedContentKeyPath } = useFocusDictionary();
25
13
  const focusedKeyPath = focusedContent?.keyPath;
26
14
  return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex h-full flex-col justify-between gap-2", children: [
27
15
  /* @__PURE__ */ jsxRuntimeExports.jsx("div", { children: /* @__PURE__ */ createElement(
@@ -1 +1 @@
1
- {"version":3,"file":"DictionaryEditor.mjs","sources":["../../../src/components/DictionaryEditor/DictionaryEditor.tsx"],"sourcesContent":["'use client';\n\nimport type { Locales } from '@intlayer/config/client';\nimport type { Dictionary, KeyPath } from '@intlayer/core';\nimport type { FC } from 'react';\nimport { useShallow } from 'zustand/react/shallow';\nimport { NodeWrapper } from './NodeWrapper';\nimport { useEditedContentStore } from './useEditedContentStore';\nimport { useEditionPanelStore } from './useEditionPanelStore';\nimport { ValidDictionaryChangeButtons } from './ValidDictionaryChangeButtons';\n\ntype DictionaryEditorProps = {\n dictionary: Dictionary;\n locale: Locales;\n onClickEdit?: (keyPath: KeyPath[]) => void;\n};\n\nexport const DictionaryEditor: FC<DictionaryEditorProps> = ({\n dictionary,\n ...props\n}) => {\n const { addEditedContent, editedContent } = useEditedContentStore(\n useShallow((s) => ({\n addEditedContent: s.addEditedContent,\n editedContent: s.editedContent,\n }))\n );\n const { focusedContent, setFocusedContentKeyPath } = useEditionPanelStore(\n useShallow((s) => ({\n focusedContent: s.focusedContent,\n setFocusedContentKeyPath: s.setFocusedContentKeyPath,\n }))\n );\n\n const focusedKeyPath = focusedContent?.keyPath;\n\n return (\n <div className=\"flex h-full flex-col justify-between gap-2\">\n <div>\n <NodeWrapper\n {...props}\n keyPath={[]}\n key={JSON.stringify(\n (editedContent[dictionary.key] ?? dictionary).content\n )}\n editedContent={editedContent[dictionary.key]?.content}\n focusedKeyPath={focusedKeyPath}\n section={dictionary.content}\n onContentChange={(content) => {\n addEditedContent(dictionary.key, content.newValue, content.keyPath);\n }}\n onFocusKeyPath={setFocusedContentKeyPath}\n />\n </div>\n <ValidDictionaryChangeButtons dictionary={dictionary} />\n </div>\n );\n};\n"],"names":["jsxs","jsx"],"mappings":";;;;;;;;AAiBO,MAAM,mBAA8C,CAAC;AAAA,EAC1D;AAAA,EACA,GAAG;AACL,MAAM;AACE,QAAA,EAAE,kBAAkB,cAAA,IAAkB;AAAA,IAC1C,WAAW,CAAC,OAAO;AAAA,MACjB,kBAAkB,EAAE;AAAA,MACpB,eAAe,EAAE;AAAA,IAAA,EACjB;AAAA,EACJ;AACM,QAAA,EAAE,gBAAgB,yBAAA,IAA6B;AAAA,IACnD,WAAW,CAAC,OAAO;AAAA,MACjB,gBAAgB,EAAE;AAAA,MAClB,0BAA0B,EAAE;AAAA,IAAA,EAC5B;AAAA,EACJ;AAEA,QAAM,iBAAiB,gBAAgB;AAGrC,SAAAA,kCAAA,KAAC,OAAI,EAAA,WAAU,8CACb,UAAA;AAAA,IAAAC,sCAAC,OACC,EAAA,UAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACE,GAAG;AAAA,QACJ,SAAS,CAAC;AAAA,QACV,KAAK,KAAK;AAAA,WACP,cAAc,WAAW,GAAG,KAAK,YAAY;AAAA,QAChD;AAAA,QACA,eAAe,cAAc,WAAW,GAAG,GAAG;AAAA,QAC9C;AAAA,QACA,SAAS,WAAW;AAAA,QACpB,iBAAiB,CAAC,YAAY;AAC5B,2BAAiB,WAAW,KAAK,QAAQ,UAAU,QAAQ,OAAO;AAAA,QACpE;AAAA,QACA,gBAAgB;AAAA,MAAA;AAAA,IAAA,GAEpB;AAAA,IACAA,sCAAC,gCAA6B,WAAwB,CAAA;AAAA,EAAA,GACxD;AAEJ;"}
1
+ {"version":3,"file":"DictionaryEditor.mjs","sources":["../../../src/components/DictionaryEditor/DictionaryEditor.tsx"],"sourcesContent":["'use client';\n\nimport type { Locales } from '@intlayer/config/client';\nimport type { Dictionary, KeyPath } from '@intlayer/core';\nimport { useEditedContent, useFocusDictionary } from '@intlayer/editor-react';\nimport type { FC } from 'react';\nimport { NodeWrapper } from './NodeWrapper';\nimport { ValidDictionaryChangeButtons } from './ValidDictionaryChangeButtons';\n\ntype DictionaryEditorProps = {\n dictionary: Dictionary;\n locale: Locales;\n onClickEdit?: (keyPath: KeyPath[]) => void;\n};\n\nexport const DictionaryEditor: FC<DictionaryEditorProps> = ({\n dictionary,\n ...props\n}) => {\n const { editedContent, addEditedContent } = useEditedContent();\n const { focusedContent, setFocusedContentKeyPath } = useFocusDictionary();\n\n const focusedKeyPath = focusedContent?.keyPath;\n\n return (\n <div className=\"flex h-full flex-col justify-between gap-2\">\n <div>\n <NodeWrapper\n {...props}\n keyPath={[]}\n key={JSON.stringify(\n (editedContent[dictionary.key] ?? dictionary).content\n )}\n editedContent={editedContent[dictionary.key]?.content}\n focusedKeyPath={focusedKeyPath}\n section={dictionary.content}\n onContentChange={(content) => {\n addEditedContent(dictionary.key, content.newValue, content.keyPath);\n }}\n onFocusKeyPath={setFocusedContentKeyPath}\n />\n </div>\n <ValidDictionaryChangeButtons dictionary={dictionary} />\n </div>\n );\n};\n"],"names":["jsxs","jsx"],"mappings":";;;;;;AAeO,MAAM,mBAA8C,CAAC;AAAA,EAC1D;AAAA,EACA,GAAG;AACL,MAAM;AACJ,QAAM,EAAE,eAAe,iBAAiB,IAAI,iBAAiB;AAC7D,QAAM,EAAE,gBAAgB,yBAAyB,IAAI,mBAAmB;AAExE,QAAM,iBAAiB,gBAAgB;AAGrC,SAAAA,kCAAA,KAAC,OAAI,EAAA,WAAU,8CACb,UAAA;AAAA,IAAAC,sCAAC,OACC,EAAA,UAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACE,GAAG;AAAA,QACJ,SAAS,CAAC;AAAA,QACV,KAAK,KAAK;AAAA,WACP,cAAc,WAAW,GAAG,KAAK,YAAY;AAAA,QAChD;AAAA,QACA,eAAe,cAAc,WAAW,GAAG,GAAG;AAAA,QAC9C;AAAA,QACA,SAAS,WAAW;AAAA,QACpB,iBAAiB,CAAC,YAAY;AAC5B,2BAAiB,WAAW,KAAK,QAAQ,UAAU,QAAQ,OAAO;AAAA,QACpE;AAAA,QACA,gBAAgB;AAAA,MAAA;AAAA,IAAA,GAEpB;AAAA,IACAA,sCAAC,gCAA6B,WAAwB,CAAA;AAAA,EAAA,GACxD;AAEJ;"}
@@ -1,10 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const jsxRuntime = require("../../../jsx-runtime-CgFM7lM3.cjs");
4
+ const core = require("@intlayer/core");
4
5
  require("../../EditableField/EditableFieldInput.cjs");
5
6
  const components_EditableField_EditableFieldTextArea = require("../../EditableField/EditableFieldTextArea.cjs");
6
7
  const utils_cn = require("../../../utils/cn.cjs");
7
- const utils_dictionary = require("../../../utils/dictionary.cjs");
8
8
  const StringWrapper = ({
9
9
  keyPath,
10
10
  section,
@@ -12,7 +12,7 @@ const StringWrapper = ({
12
12
  onContentChange,
13
13
  onFocusKeyPath
14
14
  }) => {
15
- const editedContentValue = utils_dictionary.getDictionaryValueByKeyPath(
15
+ const editedContentValue = core.getDictionaryValueByKeyPath(
16
16
  editedContent,
17
17
  keyPath
18
18
  );
@@ -1 +1 @@
1
- {"version":3,"file":"StringWrapper.cjs","sources":["../../../../src/components/DictionaryEditor/NodeWrapper/StringWrapper.tsx"],"sourcesContent":["import type { FC } from 'react';\nimport { EditableFieldTextArea } from '../..//EditableField';\nimport { cn } from '../../../utils/cn';\nimport { getDictionaryValueByKeyPath } from '../../../utils/dictionary';\nimport type { NodeWrapperProps } from './index';\n\ntype StringWrapperProps = Omit<NodeWrapperProps, 'section'> & {\n section: string;\n};\n\nexport const StringWrapper: FC<StringWrapperProps> = ({\n keyPath,\n section,\n editedContent,\n onContentChange,\n onFocusKeyPath,\n}) => {\n const editedContentValue = getDictionaryValueByKeyPath(\n editedContent,\n keyPath\n );\n\n if (editedContentValue && typeof editedContentValue !== 'string') {\n return <>Error loading section</>;\n }\n\n const level = keyPath.length;\n\n const content = editedContentValue ?? section;\n\n return (\n <button\n className={cn(\n 'w-full rounded-md p-2 text-left transition',\n 'hover:bg-card/30 dark:hover:bg-card-dark/30 [&:has(.section:hover)]:bg-transparent',\n level === 2 && 'hover:bg-card/30 dark:hover:bg-card-dark/30',\n level >= 3 && ''\n )}\n onClick={(e) => {\n e.stopPropagation();\n onFocusKeyPath(keyPath);\n }}\n >\n <EditableFieldTextArea\n defaultValue={content}\n onSave={(newValue) => onContentChange({ keyPath, newValue })}\n onCancel={() => null}\n />\n </button>\n );\n};\n"],"names":["getDictionaryValueByKeyPath","jsx","cn","EditableFieldTextArea"],"mappings":";;;;;;;AAUO,MAAM,gBAAwC,CAAC;AAAA,EACpD;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,MAAM;AACJ,QAAM,qBAAqBA,iBAAA;AAAA,IACzB;AAAA,IACA;AAAA,EACF;AAEI,MAAA,sBAAsB,OAAO,uBAAuB,UAAU;AAChE,qGAAS,UAAqB,wBAAA,CAAA;AAAA,EAAA;AAGhC,QAAM,QAAQ,QAAQ;AAEtB,QAAM,UAAU,sBAAsB;AAGpC,SAAAC,2BAAA,kBAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAWC,SAAA;AAAA,QACT;AAAA,QACA;AAAA,QACA,UAAU,KAAK;AAAA,QACf,SAAS,KAAK;AAAA,MAChB;AAAA,MACA,SAAS,CAAC,MAAM;AACd,UAAE,gBAAgB;AAClB,uBAAe,OAAO;AAAA,MACxB;AAAA,MAEA,UAAAD,2BAAA,kBAAA;AAAA,QAACE,+CAAA;AAAA,QAAA;AAAA,UACC,cAAc;AAAA,UACd,QAAQ,CAAC,aAAa,gBAAgB,EAAE,SAAS,UAAU;AAAA,UAC3D,UAAU,MAAM;AAAA,QAAA;AAAA,MAAA;AAAA,IAClB;AAAA,EACF;AAEJ;;"}
1
+ {"version":3,"file":"StringWrapper.cjs","sources":["../../../../src/components/DictionaryEditor/NodeWrapper/StringWrapper.tsx"],"sourcesContent":["import { getDictionaryValueByKeyPath } from '@intlayer/core';\nimport type { FC } from 'react';\nimport { EditableFieldTextArea } from '../..//EditableField';\nimport { cn } from '../../../utils/cn';\nimport type { NodeWrapperProps } from './index';\n\ntype StringWrapperProps = Omit<NodeWrapperProps, 'section'> & {\n section: string;\n};\n\nexport const StringWrapper: FC<StringWrapperProps> = ({\n keyPath,\n section,\n editedContent,\n onContentChange,\n onFocusKeyPath,\n}) => {\n const editedContentValue = getDictionaryValueByKeyPath(\n editedContent,\n keyPath\n );\n\n if (editedContentValue && typeof editedContentValue !== 'string') {\n return <>Error loading section</>;\n }\n\n const level = keyPath.length;\n\n const content = editedContentValue ?? section;\n\n return (\n <button\n className={cn(\n 'w-full rounded-md p-2 text-left transition',\n 'hover:bg-card/30 dark:hover:bg-card-dark/30 [&:has(.section:hover)]:bg-transparent',\n level === 2 && 'hover:bg-card/30 dark:hover:bg-card-dark/30',\n level >= 3 && ''\n )}\n onClick={(e) => {\n e.stopPropagation();\n onFocusKeyPath(keyPath);\n }}\n >\n <EditableFieldTextArea\n defaultValue={content}\n onSave={(newValue) => onContentChange({ keyPath, newValue })}\n onCancel={() => null}\n />\n </button>\n );\n};\n"],"names":["getDictionaryValueByKeyPath","jsx","cn","EditableFieldTextArea"],"mappings":";;;;;;;AAUO,MAAM,gBAAwC,CAAC;AAAA,EACpD;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,MAAM;AACJ,QAAM,qBAAqBA,KAAA;AAAA,IACzB;AAAA,IACA;AAAA,EACF;AAEI,MAAA,sBAAsB,OAAO,uBAAuB,UAAU;AAChE,qGAAS,UAAqB,wBAAA,CAAA;AAAA,EAAA;AAGhC,QAAM,QAAQ,QAAQ;AAEtB,QAAM,UAAU,sBAAsB;AAGpC,SAAAC,2BAAA,kBAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAWC,SAAA;AAAA,QACT;AAAA,QACA;AAAA,QACA,UAAU,KAAK;AAAA,QACf,SAAS,KAAK;AAAA,MAChB;AAAA,MACA,SAAS,CAAC,MAAM;AACd,UAAE,gBAAgB;AAClB,uBAAe,OAAO;AAAA,MACxB;AAAA,MAEA,UAAAD,2BAAA,kBAAA;AAAA,QAACE,+CAAA;AAAA,QAAA;AAAA,UACC,cAAc;AAAA,UACd,QAAQ,CAAC,aAAa,gBAAgB,EAAE,SAAS,UAAU;AAAA,UAC3D,UAAU,MAAM;AAAA,QAAA;AAAA,MAAA;AAAA,IAClB;AAAA,EACF;AAEJ;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"StringWrapper.d.ts","sourceRoot":"","sources":["../../../../src/components/DictionaryEditor/NodeWrapper/StringWrapper.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAIhC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAEhD,KAAK,kBAAkB,GAAG,IAAI,CAAC,gBAAgB,EAAE,SAAS,CAAC,GAAG;IAC5D,OAAO,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,eAAO,MAAM,aAAa,EAAE,EAAE,CAAC,kBAAkB,CAwChD,CAAC"}
1
+ {"version":3,"file":"StringWrapper.d.ts","sourceRoot":"","sources":["../../../../src/components/DictionaryEditor/NodeWrapper/StringWrapper.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAGhC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAEhD,KAAK,kBAAkB,GAAG,IAAI,CAAC,gBAAgB,EAAE,SAAS,CAAC,GAAG;IAC5D,OAAO,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,eAAO,MAAM,aAAa,EAAE,EAAE,CAAC,kBAAkB,CAwChD,CAAC"}
@@ -1,8 +1,8 @@
1
1
  import { j as jsxRuntimeExports } from "../../../jsx-runtime-DQkoUcjV.js";
2
+ import { getDictionaryValueByKeyPath } from "@intlayer/core";
2
3
  import "../../EditableField/EditableFieldInput.mjs";
3
4
  import { EditableFieldTextArea } from "../../EditableField/EditableFieldTextArea.mjs";
4
5
  import { cn } from "../../../utils/cn.mjs";
5
- import { getDictionaryValueByKeyPath } from "../../../utils/dictionary.mjs";
6
6
  const StringWrapper = ({
7
7
  keyPath,
8
8
  section,
@@ -1 +1 @@
1
- {"version":3,"file":"StringWrapper.mjs","sources":["../../../../src/components/DictionaryEditor/NodeWrapper/StringWrapper.tsx"],"sourcesContent":["import type { FC } from 'react';\nimport { EditableFieldTextArea } from '../..//EditableField';\nimport { cn } from '../../../utils/cn';\nimport { getDictionaryValueByKeyPath } from '../../../utils/dictionary';\nimport type { NodeWrapperProps } from './index';\n\ntype StringWrapperProps = Omit<NodeWrapperProps, 'section'> & {\n section: string;\n};\n\nexport const StringWrapper: FC<StringWrapperProps> = ({\n keyPath,\n section,\n editedContent,\n onContentChange,\n onFocusKeyPath,\n}) => {\n const editedContentValue = getDictionaryValueByKeyPath(\n editedContent,\n keyPath\n );\n\n if (editedContentValue && typeof editedContentValue !== 'string') {\n return <>Error loading section</>;\n }\n\n const level = keyPath.length;\n\n const content = editedContentValue ?? section;\n\n return (\n <button\n className={cn(\n 'w-full rounded-md p-2 text-left transition',\n 'hover:bg-card/30 dark:hover:bg-card-dark/30 [&:has(.section:hover)]:bg-transparent',\n level === 2 && 'hover:bg-card/30 dark:hover:bg-card-dark/30',\n level >= 3 && ''\n )}\n onClick={(e) => {\n e.stopPropagation();\n onFocusKeyPath(keyPath);\n }}\n >\n <EditableFieldTextArea\n defaultValue={content}\n onSave={(newValue) => onContentChange({ keyPath, newValue })}\n onCancel={() => null}\n />\n </button>\n );\n};\n"],"names":["jsx"],"mappings":";;;;;AAUO,MAAM,gBAAwC,CAAC;AAAA,EACpD;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,MAAM;AACJ,QAAM,qBAAqB;AAAA,IACzB;AAAA,IACA;AAAA,EACF;AAEI,MAAA,sBAAsB,OAAO,uBAAuB,UAAU;AAChE,+EAAS,UAAqB,wBAAA,CAAA;AAAA,EAAA;AAGhC,QAAM,QAAQ,QAAQ;AAEtB,QAAM,UAAU,sBAAsB;AAGpC,SAAAA,kCAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAW;AAAA,QACT;AAAA,QACA;AAAA,QACA,UAAU,KAAK;AAAA,QACf,SAAS,KAAK;AAAA,MAChB;AAAA,MACA,SAAS,CAAC,MAAM;AACd,UAAE,gBAAgB;AAClB,uBAAe,OAAO;AAAA,MACxB;AAAA,MAEA,UAAAA,kCAAA;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,cAAc;AAAA,UACd,QAAQ,CAAC,aAAa,gBAAgB,EAAE,SAAS,UAAU;AAAA,UAC3D,UAAU,MAAM;AAAA,QAAA;AAAA,MAAA;AAAA,IAClB;AAAA,EACF;AAEJ;"}
1
+ {"version":3,"file":"StringWrapper.mjs","sources":["../../../../src/components/DictionaryEditor/NodeWrapper/StringWrapper.tsx"],"sourcesContent":["import { getDictionaryValueByKeyPath } from '@intlayer/core';\nimport type { FC } from 'react';\nimport { EditableFieldTextArea } from '../..//EditableField';\nimport { cn } from '../../../utils/cn';\nimport type { NodeWrapperProps } from './index';\n\ntype StringWrapperProps = Omit<NodeWrapperProps, 'section'> & {\n section: string;\n};\n\nexport const StringWrapper: FC<StringWrapperProps> = ({\n keyPath,\n section,\n editedContent,\n onContentChange,\n onFocusKeyPath,\n}) => {\n const editedContentValue = getDictionaryValueByKeyPath(\n editedContent,\n keyPath\n );\n\n if (editedContentValue && typeof editedContentValue !== 'string') {\n return <>Error loading section</>;\n }\n\n const level = keyPath.length;\n\n const content = editedContentValue ?? section;\n\n return (\n <button\n className={cn(\n 'w-full rounded-md p-2 text-left transition',\n 'hover:bg-card/30 dark:hover:bg-card-dark/30 [&:has(.section:hover)]:bg-transparent',\n level === 2 && 'hover:bg-card/30 dark:hover:bg-card-dark/30',\n level >= 3 && ''\n )}\n onClick={(e) => {\n e.stopPropagation();\n onFocusKeyPath(keyPath);\n }}\n >\n <EditableFieldTextArea\n defaultValue={content}\n onSave={(newValue) => onContentChange({ keyPath, newValue })}\n onCancel={() => null}\n />\n </button>\n );\n};\n"],"names":["jsx"],"mappings":";;;;;AAUO,MAAM,gBAAwC,CAAC;AAAA,EACpD;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,MAAM;AACJ,QAAM,qBAAqB;AAAA,IACzB;AAAA,IACA;AAAA,EACF;AAEI,MAAA,sBAAsB,OAAO,uBAAuB,UAAU;AAChE,+EAAS,UAAqB,wBAAA,CAAA;AAAA,EAAA;AAGhC,QAAM,QAAQ,QAAQ;AAEtB,QAAM,UAAU,sBAAsB;AAGpC,SAAAA,kCAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAW;AAAA,QACT;AAAA,QACA;AAAA,QACA,UAAU,KAAK;AAAA,QACf,SAAS,KAAK;AAAA,MAChB;AAAA,MACA,SAAS,CAAC,MAAM;AACd,UAAE,gBAAgB;AAClB,uBAAe,OAAO;AAAA,MACxB;AAAA,MAEA,UAAAA,kCAAA;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,cAAc;AAAA,UACd,QAAQ,CAAC,aAAa,gBAAgB,EAAE,SAAS,UAAU;AAAA,UAC3D,UAAU,MAAM;AAAA,QAAA;AAAA,MAAA;AAAA,IAClB;AAAA,EACF;AAEJ;"}