@blokkli/editor 2.0.0-alpha.63 → 2.0.0-alpha.64

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 (213) hide show
  1. package/dist/global/types/blockOptions.d.ts +32 -27
  2. package/dist/module.d.mts +2 -2
  3. package/dist/module.json +1 -1
  4. package/dist/module.mjs +108 -5
  5. package/dist/modules/agent/index.d.mts +1 -1
  6. package/dist/modules/agent/index.mjs +2 -1
  7. package/dist/modules/agent/runtime/app/components/Attachment/PreviewCsv/index.vue +1 -1
  8. package/dist/modules/agent/runtime/app/features/agent/ConversationsAdmin/SplitView/index.d.vue.ts +1 -1
  9. package/dist/modules/agent/runtime/app/features/agent/ConversationsAdmin/SplitView/index.vue.d.ts +1 -1
  10. package/dist/modules/agent/runtime/app/features/agent/Panel/Input/Actions/index.vue +1 -1
  11. package/dist/modules/agent/runtime/app/features/agent/Panel/Welcome/index.vue +1 -1
  12. package/dist/modules/agent/runtime/app/features/agent/Transcript/index.vue +1 -1
  13. package/dist/modules/agent/runtime/app/features/agent/index.vue +1 -1
  14. package/dist/modules/agent/runtime/app/tools/add_content_search_paragraphs/index.d.ts +1 -1
  15. package/dist/modules/agent/runtime/app/tools/add_fragment/index.d.ts +1 -1
  16. package/dist/modules/agent/runtime/app/tools/add_media_paragraph/index.d.ts +1 -1
  17. package/dist/modules/agent/runtime/app/tools/add_paragraphs/index.d.ts +1 -1
  18. package/dist/modules/agent/runtime/app/tools/add_reusable_paragraph/index.d.ts +1 -1
  19. package/dist/modules/agent/runtime/app/tools/add_template/index.d.ts +1 -1
  20. package/dist/modules/agent/runtime/app/tools/ask_question/Component.vue +1 -1
  21. package/dist/modules/agent/runtime/app/tools/ask_question/index.d.ts +1 -1
  22. package/dist/modules/agent/runtime/app/tools/auto_translate_paragraphs/index.d.ts +1 -1
  23. package/dist/modules/agent/runtime/app/tools/delete_paragraphs/index.d.ts +1 -1
  24. package/dist/modules/agent/runtime/app/tools/detach_reusable_paragraph/index.d.ts +1 -1
  25. package/dist/modules/agent/runtime/app/tools/duplicate_paragraphs/index.d.ts +1 -1
  26. package/dist/modules/agent/runtime/app/tools/fieldDiffApproval.js +1 -3
  27. package/dist/modules/agent/runtime/app/tools/find_paragraphs/index.d.ts +2 -2
  28. package/dist/modules/agent/runtime/app/tools/get_bundle_info/index.js +6 -2
  29. package/dist/modules/agent/runtime/app/tools/get_content_fields/index.d.ts +3 -3
  30. package/dist/modules/agent/runtime/app/tools/get_paragraph_context/index.d.ts +5 -5
  31. package/dist/modules/agent/runtime/app/tools/get_paragraphs_in_viewport/index.d.ts +1 -1
  32. package/dist/modules/agent/runtime/app/tools/get_referenced_entities/index.d.ts +1 -1
  33. package/dist/modules/agent/runtime/app/tools/go_to_history_index/index.d.ts +1 -1
  34. package/dist/modules/agent/runtime/app/tools/move_paragraphs/index.d.ts +1 -1
  35. package/dist/modules/agent/runtime/app/tools/rearrange_paragraphs/index.d.ts +1 -1
  36. package/dist/modules/agent/runtime/app/tools/replace_content_search_item/index.d.ts +1 -1
  37. package/dist/modules/agent/runtime/app/tools/replace_media_field/index.d.ts +1 -1
  38. package/dist/modules/agent/runtime/app/tools/schemas.d.ts +2 -2
  39. package/dist/modules/agent/runtime/app/tools/set_paragraph_options/index.d.ts +1 -1
  40. package/dist/modules/agent/runtime/app/tools/swap_paragraphs/index.d.ts +1 -1
  41. package/dist/modules/agent/runtime/app/tools/update_text_fields/index.d.ts +3 -3
  42. package/dist/modules/agent/runtime/server/classes/FieldStreamParser/index.js +10 -15
  43. package/dist/modules/agent/runtime/shared/toolParams.d.ts +3 -3
  44. package/dist/modules/agent/runtime/shared/types.d.ts +3 -3
  45. package/dist/modules/charts/index.d.mts +14 -1
  46. package/dist/modules/charts/index.mjs +37 -2
  47. package/dist/modules/charts/runtime/features/charts/Editor/AdvancedConfigPanel/index.vue +1 -1
  48. package/dist/modules/charts/runtime/features/charts/Editor/ChartTypeOptions/Field.vue +19 -9
  49. package/dist/modules/charts/runtime/features/charts/Editor/CsvImport/OutputPreviewTable/index.vue +1 -1
  50. package/dist/modules/charts/runtime/features/charts/Editor/DataTable/index.vue +16 -8
  51. package/dist/modules/charts/runtime/features/charts/Editor/NumberFormatEditor/index.vue +23 -7
  52. package/dist/modules/charts/runtime/features/charts/Editor/index.vue +5 -6
  53. package/dist/modules/drupal/graphql/base/fragment.paragraphsBlokkliEditState.graphql +5 -0
  54. package/dist/modules/drupal/index.d.mts +1 -1
  55. package/dist/modules/drupal/runtime/adapter/index.js +3 -0
  56. package/dist/modules/iframes/index.d.mts +1 -1
  57. package/dist/modules/index.d.mts +1 -1
  58. package/dist/modules/readability/index.d.mts +1 -1
  59. package/dist/modules/readability/index.mjs +2 -1
  60. package/dist/modules/table-of-contents/index.d.mts +1 -1
  61. package/dist/runtime/components/Blocks/NotImplemented/index.vue +1 -1
  62. package/dist/runtime/editor/components/Actions/Title/index.vue +1 -1
  63. package/dist/runtime/editor/components/Actions/index.vue +1 -1
  64. package/dist/runtime/editor/components/ArtboardTooltip/index.d.vue.ts +1 -0
  65. package/dist/runtime/editor/components/ArtboardTooltip/index.vue +2 -2
  66. package/dist/runtime/editor/components/ArtboardTooltip/index.vue.d.ts +1 -0
  67. package/dist/runtime/editor/components/Avatar/index.vue +1 -1
  68. package/dist/runtime/editor/components/BlockPreviewItem/index.vue +1 -1
  69. package/dist/runtime/editor/components/BlockPreviewRenderer/index.vue +1 -1
  70. package/dist/runtime/editor/components/BlockProxy/index.vue +1 -1
  71. package/dist/runtime/editor/components/BlokkliRootErrorBoundary.vue +1 -1
  72. package/dist/runtime/editor/components/BundleSelector/index.vue +1 -1
  73. package/dist/runtime/editor/components/ColorDropdown/index.vue +1 -1
  74. package/dist/runtime/editor/components/Dialog/index.vue +1 -1
  75. package/dist/runtime/editor/components/DiffApproval/Toolbar/index.vue +1 -1
  76. package/dist/runtime/editor/components/DiffApproval/types.js +1 -3
  77. package/dist/runtime/editor/components/DiffViewer/State.vue +1 -1
  78. package/dist/runtime/editor/components/DraggableList.vue +1 -1
  79. package/dist/runtime/editor/components/Dropdown/index.d.vue.ts +1 -0
  80. package/dist/runtime/editor/components/Dropdown/index.vue +2 -2
  81. package/dist/runtime/editor/components/Dropdown/index.vue.d.ts +1 -0
  82. package/dist/runtime/editor/components/DropdownItem/index.vue +1 -1
  83. package/dist/runtime/editor/components/EditIndicator.vue +1 -1
  84. package/dist/runtime/editor/components/EditProvider.vue +2 -2
  85. package/dist/runtime/editor/components/FileDropHandler/index.vue +1 -1
  86. package/dist/runtime/editor/components/Form/RadioTabs/index.vue +1 -1
  87. package/dist/runtime/editor/components/Form/Search/index.d.vue.ts +1 -0
  88. package/dist/runtime/editor/components/Form/Search/index.vue +2 -2
  89. package/dist/runtime/editor/components/Form/Search/index.vue.d.ts +1 -0
  90. package/dist/runtime/editor/components/FormOverlay/index.vue +1 -1
  91. package/dist/runtime/editor/components/Icon/index.vue +1 -1
  92. package/dist/runtime/editor/components/Indicators/index.vue +31 -100
  93. package/dist/runtime/editor/components/Konami/Game/index.vue +1 -1
  94. package/dist/runtime/editor/components/Messages/index.vue +1 -1
  95. package/dist/runtime/editor/components/NestedEditorOverlay/index.d.vue.ts +1 -0
  96. package/dist/runtime/editor/components/NestedEditorOverlay/index.vue +2 -1
  97. package/dist/runtime/editor/components/NestedEditorOverlay/index.vue.d.ts +1 -0
  98. package/dist/runtime/editor/components/Overlay/index.vue +1 -1
  99. package/dist/runtime/editor/components/Pagination/index.vue +1 -1
  100. package/dist/runtime/editor/components/Panel/Section/index.vue +1 -1
  101. package/dist/runtime/editor/components/Panel/Tabs/index.d.vue.ts +1 -1
  102. package/dist/runtime/editor/components/Panel/Tabs/index.vue.d.ts +1 -1
  103. package/dist/runtime/editor/components/PluginConfigForm/index.vue +1 -1
  104. package/dist/runtime/editor/components/PluginConfigFormInline/FilterSelect/index.vue +1 -1
  105. package/dist/runtime/editor/components/PluginConfigFormInline/index.vue +1 -1
  106. package/dist/runtime/editor/components/Popup/index.vue +1 -1
  107. package/dist/runtime/editor/components/PreviewProvider.vue +3 -2
  108. package/dist/runtime/editor/components/RelativeTime/index.vue +7 -13
  109. package/dist/runtime/editor/components/Resizable/index.vue +1 -1
  110. package/dist/runtime/editor/components/RichText/Editor/index.vue +1 -1
  111. package/dist/runtime/editor/components/ScaleToFit/index.vue +1 -1
  112. package/dist/runtime/editor/components/SearchOverlay/index.vue +1 -1
  113. package/dist/runtime/editor/components/SidebarFloater/index.vue +1 -1
  114. package/dist/runtime/editor/components/StatusIcon/index.vue +1 -1
  115. package/dist/runtime/editor/components/StatusIndicator/index.vue +1 -1
  116. package/dist/runtime/editor/components/SystemRequirements/index.vue +1 -1
  117. package/dist/runtime/editor/components/Tabs/index.d.vue.ts +1 -1
  118. package/dist/runtime/editor/components/Tabs/index.vue.d.ts +1 -1
  119. package/dist/runtime/editor/components/Toolbar/ViewOptions/List/Button/index.vue +2 -1
  120. package/dist/runtime/editor/components/Toolbar/index.vue +1 -1
  121. package/dist/runtime/editor/components/Transition/Collapse/index.vue +1 -1
  122. package/dist/runtime/editor/components/Transition/List/index.vue +1 -1
  123. package/dist/runtime/editor/composables/defineViewOption.js +5 -1
  124. package/dist/runtime/editor/composables/useStickyToolbar.js +1 -4
  125. package/dist/runtime/editor/css/output.css +1 -1
  126. package/dist/runtime/editor/features/add-list/Help/index.vue +1 -1
  127. package/dist/runtime/editor/features/add-list/index.vue +1 -1
  128. package/dist/runtime/editor/features/analyze/index.vue +1 -1
  129. package/dist/runtime/editor/features/anchors/Overlay/index.vue +11 -5
  130. package/dist/runtime/editor/features/anchors/index.vue +2 -1
  131. package/dist/runtime/editor/features/artboard/Overview/index.vue +1 -1
  132. package/dist/runtime/editor/features/artboard/Renderer.vue +1 -1
  133. package/dist/runtime/editor/features/artboard/Scrollbar/index.vue +1 -1
  134. package/dist/runtime/editor/features/block-scheduler/Dialog/index.vue +1 -1
  135. package/dist/runtime/editor/features/block-transfer/index.vue +1 -1
  136. package/dist/runtime/editor/features/breadcrumbs/index.vue +1 -1
  137. package/dist/runtime/editor/features/changelog/changelog.json +8 -0
  138. package/dist/runtime/editor/features/clipboard/DropElement/index.vue +1 -1
  139. package/dist/runtime/editor/features/comments/AddForm/index.vue +1 -1
  140. package/dist/runtime/editor/features/comments/Thread/index.vue +1 -1
  141. package/dist/runtime/editor/features/complex-options/index.vue +1 -0
  142. package/dist/runtime/editor/features/debug/Main.vue +1 -1
  143. package/dist/runtime/editor/features/dev-mode/index.vue +1 -1
  144. package/dist/runtime/editor/features/dragging-overlay/DragItems/index.vue +1 -1
  145. package/dist/runtime/editor/features/dragging-overlay/index.vue +1 -1
  146. package/dist/runtime/editor/features/droppable-field-edit/Overlay/index.vue +1 -1
  147. package/dist/runtime/editor/features/editable-field/Overlay/Frame/index.vue +1 -1
  148. package/dist/runtime/editor/features/editable-field/Overlay/Plaintext/index.d.vue.ts +1 -5
  149. package/dist/runtime/editor/features/editable-field/Overlay/Plaintext/index.vue.d.ts +1 -5
  150. package/dist/runtime/editor/features/editable-field/Overlay/ReadabilityIndicator/ChunkOverlay.vue +1 -1
  151. package/dist/runtime/editor/features/editable-field/Overlay/index.vue +1 -1
  152. package/dist/runtime/editor/features/editable-mask/index.vue +1 -1
  153. package/dist/runtime/editor/features/entity-title/index.vue +17 -7
  154. package/dist/runtime/editor/features/help/Dialog/index.vue +1 -1
  155. package/dist/runtime/editor/features/help/Shortcuts/index.vue +1 -1
  156. package/dist/runtime/editor/features/history/List/index.vue +1 -1
  157. package/dist/runtime/editor/features/import-existing/Dialog/index.vue +1 -1
  158. package/dist/runtime/editor/features/library/index.vue +1 -0
  159. package/dist/runtime/editor/features/media-library/index.vue +1 -1
  160. package/dist/runtime/editor/features/options/Form/Item.vue +5 -12
  161. package/dist/runtime/editor/features/options/Form/Radios/index.d.vue.ts +5 -4
  162. package/dist/runtime/editor/features/options/Form/Radios/index.vue +8 -5
  163. package/dist/runtime/editor/features/options/Form/Radios/index.vue.d.ts +5 -4
  164. package/dist/runtime/editor/features/options/Form/Text/index.d.vue.ts +4 -0
  165. package/dist/runtime/editor/features/options/Form/Text/index.vue +11 -3
  166. package/dist/runtime/editor/features/options/Form/Text/index.vue.d.ts +4 -0
  167. package/dist/runtime/editor/features/options/index.vue +1 -1
  168. package/dist/runtime/editor/features/publish/Dialog/Item.vue +4 -7
  169. package/dist/runtime/editor/features/publish/Dialog/PublishOption.vue +1 -1
  170. package/dist/runtime/editor/features/referenced-entities/List/Item/index.vue +1 -0
  171. package/dist/runtime/editor/features/responsive-preview/Frame/index.vue +1 -1
  172. package/dist/runtime/editor/features/search/index.vue +1 -1
  173. package/dist/runtime/editor/features/selection/AddButtons/Renderer/index.vue +1 -1
  174. package/dist/runtime/editor/features/settings/Dialog/FeatureSetting/index.vue +1 -1
  175. package/dist/runtime/editor/features/settings/index.vue +1 -1
  176. package/dist/runtime/editor/features/structure/List/Item/index.vue +1 -1
  177. package/dist/runtime/editor/features/structure/index.vue +1 -1
  178. package/dist/runtime/editor/features/templates/DialogManageTemplates/Item.vue +1 -0
  179. package/dist/runtime/editor/features/templates/DialogManageTemplates/index.vue +1 -1
  180. package/dist/runtime/editor/features/theme/index.vue +1 -1
  181. package/dist/runtime/editor/features/touch-action-bar/Bar/index.vue +1 -1
  182. package/dist/runtime/editor/features/tour/Overlay/index.vue +1 -1
  183. package/dist/runtime/editor/features/transform/Dialog/index.vue +1 -1
  184. package/dist/runtime/editor/features/translations/SelectionTable/index.vue +1 -1
  185. package/dist/runtime/editor/features/workspace/index.vue +1 -1
  186. package/dist/runtime/editor/helpers/diff/index.d.ts +11 -0
  187. package/dist/runtime/editor/helpers/diff/index.js +13 -7
  188. package/dist/runtime/editor/helpers/options/index.d.ts +2 -0
  189. package/dist/runtime/editor/helpers/options/index.js +21 -0
  190. package/dist/runtime/editor/plugins/BlockIndicator/index.d.vue.ts +24 -1
  191. package/dist/runtime/editor/plugins/BlockIndicator/index.vue +17 -7
  192. package/dist/runtime/editor/plugins/BlockIndicator/index.vue.d.ts +24 -1
  193. package/dist/runtime/editor/plugins/ItemAction/index.d.vue.ts +1 -0
  194. package/dist/runtime/editor/plugins/ItemAction/index.vue +1 -1
  195. package/dist/runtime/editor/plugins/ItemAction/index.vue.d.ts +1 -0
  196. package/dist/runtime/editor/plugins/Sidebar/index.vue +1 -1
  197. package/dist/runtime/editor/plugins/ToolbarButton/index.vue +1 -1
  198. package/dist/runtime/editor/providers/animation.d.ts +2 -0
  199. package/dist/runtime/editor/providers/definition.d.ts +4 -3
  200. package/dist/runtime/editor/providers/definition.js +10 -2
  201. package/dist/runtime/editor/providers/plugin.d.ts +1 -0
  202. package/dist/runtime/editor/providers/state.d.ts +8 -0
  203. package/dist/runtime/editor/providers/state.js +3 -0
  204. package/dist/runtime/editor/translations/de.json +2 -0
  205. package/dist/runtime/editor/translations/fr.json +2 -0
  206. package/dist/runtime/editor/translations/gsw_CH.json +2 -0
  207. package/dist/runtime/editor/translations/it.json +2 -0
  208. package/dist/runtime/editor/types/state.d.ts +7 -0
  209. package/dist/runtime/editor/types/ui.d.ts +1 -0
  210. package/dist/shared/{editor.D28NbXr3.d.mts → editor.BDyiQvbV.d.mts} +434 -406
  211. package/dist/shared/{editor.Gu7mgJ5Q.mjs → editor.BGemL1Oh.mjs} +146 -146
  212. package/dist/types.d.mts +1 -1
  213. package/package.json +74 -82
@@ -1,3 +1,4 @@
1
+ export type DefinitionString = string | Record<string, string>;
1
2
  type DefinitionOptionText = {
2
3
  /**
3
4
  * The option type.
@@ -10,13 +11,17 @@ type DefinitionOptionText = {
10
11
  /**
11
12
  * The label displayed in the editor.
12
13
  */
13
- label: string;
14
+ label: DefinitionString;
14
15
  /**
15
16
  * Optional description providing additional context.
16
17
  *
17
18
  * Displayed below the option label in the editor.
18
19
  */
19
- description?: string;
20
+ description?: DefinitionString;
21
+ /**
22
+ * The placeholder.
23
+ */
24
+ placeholder?: DefinitionString;
20
25
  /**
21
26
  * The HTML input type.
22
27
  *
@@ -38,13 +43,13 @@ type DefinitionOptionNumberBase = {
38
43
  /**
39
44
  * The label displayed in the editor.
40
45
  */
41
- label: string;
46
+ label: DefinitionString;
42
47
  /**
43
48
  * Optional description providing additional context.
44
49
  *
45
50
  * Displayed below the option label in the editor.
46
51
  */
47
- description?: string;
52
+ description?: DefinitionString;
48
53
  /**
49
54
  * Minimum allowed value.
50
55
  *
@@ -93,13 +98,13 @@ type DefinitionOptionRange = {
93
98
  /**
94
99
  * The label displayed in the editor.
95
100
  */
96
- label: string;
101
+ label: DefinitionString;
97
102
  /**
98
103
  * Optional description providing additional context.
99
104
  *
100
105
  * Displayed below the option label in the editor.
101
106
  */
102
- description?: string;
107
+ description?: DefinitionString;
103
108
  /**
104
109
  * Minimum allowed value.
105
110
  */
@@ -127,13 +132,13 @@ type DefinitionOptionDateTimeLocal = {
127
132
  /**
128
133
  * The label displayed in the editor.
129
134
  */
130
- label: string;
135
+ label: DefinitionString;
131
136
  /**
132
137
  * Optional description providing additional context.
133
138
  *
134
139
  * Displayed below the option label in the editor.
135
140
  */
136
- description?: string;
141
+ description?: DefinitionString;
137
142
  /**
138
143
  * The default value as an ISO 8601 datetime string.
139
144
  *
@@ -167,13 +172,13 @@ type DefinitionOptionCheckbox = {
167
172
  /**
168
173
  * The label displayed in the editor.
169
174
  */
170
- label: string;
175
+ label: DefinitionString;
171
176
  /**
172
177
  * Optional description providing additional context.
173
178
  *
174
179
  * Displayed below the option label in the editor.
175
180
  */
176
- description?: string;
181
+ description?: DefinitionString;
177
182
  /**
178
183
  * Optional group name for organizing options.
179
184
  *
@@ -195,13 +200,13 @@ type DefinitionOptionColor = {
195
200
  /**
196
201
  * The label displayed in the editor.
197
202
  */
198
- label: string;
203
+ label: DefinitionString;
199
204
  /**
200
205
  * Optional description providing additional context.
201
206
  *
202
207
  * Displayed below the option label in the editor.
203
208
  */
204
- description?: string;
209
+ description?: DefinitionString;
205
210
  /**
206
211
  * Optional group name for organizing options.
207
212
  *
@@ -217,13 +222,13 @@ type DefinitionOptionCheckboxes = {
217
222
  /**
218
223
  * The label displayed in the editor.
219
224
  */
220
- label: string;
225
+ label: DefinitionString;
221
226
  /**
222
227
  * Optional description providing additional context.
223
228
  *
224
229
  * Displayed below the option label in the editor.
225
230
  */
226
- description?: string;
231
+ description?: DefinitionString;
227
232
  /**
228
233
  * The default values.
229
234
  */
@@ -233,7 +238,7 @@ type DefinitionOptionCheckboxes = {
233
238
  *
234
239
  * Key is the option value, value is the display label.
235
240
  */
236
- options: Record<string, string>;
241
+ options: Record<string, DefinitionString>;
237
242
  /**
238
243
  * Optional group name for organizing options.
239
244
  *
@@ -251,11 +256,11 @@ type DefinitionOptionRadiosGridOption = {
251
256
  /**
252
257
  * The label displayed for this option.
253
258
  */
254
- label: string;
259
+ label: DefinitionString;
255
260
  /**
256
261
  * Optional description providing additional context for this option.
257
262
  */
258
- description?: string;
263
+ description?: DefinitionString;
259
264
  };
260
265
  type DefinitionOptionRadiosGrid = {
261
266
  /**
@@ -285,11 +290,11 @@ type DefinitionOptionRadiosColorsOption = {
285
290
  /**
286
291
  * The label displayed for this option.
287
292
  */
288
- label: string;
293
+ label: DefinitionString;
289
294
  /**
290
295
  * Optional description providing additional context for this option.
291
296
  */
292
- description?: string;
297
+ description?: DefinitionString;
293
298
  };
294
299
  type DefinitionOptionRadiosColors = {
295
300
  /**
@@ -317,8 +322,8 @@ type DefinitionOptionRadiosRadios = {
317
322
  * label and optional description.
318
323
  */
319
324
  options: Record<string, string | {
320
- label: string;
321
- description?: string;
325
+ label: DefinitionString;
326
+ description?: DefinitionString;
322
327
  }>;
323
328
  };
324
329
  type DefinitionOptionRadiosIconsOptionBase<Icon extends string = string> = {
@@ -331,11 +336,11 @@ type DefinitionOptionRadiosIconsOptionBase<Icon extends string = string> = {
331
336
  /**
332
337
  * The label displayed for this option.
333
338
  */
334
- label: string;
339
+ label: DefinitionString;
335
340
  /**
336
341
  * Optional description providing additional context for this option.
337
342
  */
338
- description?: string;
343
+ description?: DefinitionString;
339
344
  };
340
345
  type DefinitionOptionRadiosIconsBase<Icon extends string = string> = {
341
346
  /**
@@ -357,13 +362,13 @@ type DefinitionOptionRadiosBase<Icon extends string = string> = {
357
362
  /**
358
363
  * The label displayed in the editor.
359
364
  */
360
- label: string;
365
+ label: DefinitionString;
361
366
  /**
362
367
  * Optional description providing additional context.
363
368
  *
364
369
  * Displayed below the option label in the editor.
365
370
  */
366
- description?: string;
371
+ description?: DefinitionString;
367
372
  /**
368
373
  * The default value.
369
374
  *
@@ -379,10 +384,10 @@ type DefinitionOptionRadiosBase<Icon extends string = string> = {
379
384
  } & (DefinitionOptionRadiosColors | DefinitionOptionRadiosGrid | DefinitionOptionRadiosRadios | DefinitionOptionRadiosIconsBase<Icon>);
380
385
  type DefinitionOptionJsonBase<DataType extends string = string> = {
381
386
  type: 'json';
382
- label: string;
387
+ label: DefinitionString;
383
388
  default: string;
384
389
  dataType?: DataType;
385
- description?: string;
390
+ description?: DefinitionString;
386
391
  group?: string;
387
392
  };
388
393
  export type BlockOptionDefinitionBase<Icon extends string = string, DataType extends string = string> = DefinitionOptionJsonBase<DataType> | DefinitionOptionColor | DefinitionOptionCheckbox | DefinitionOptionCheckboxes | DefinitionOptionRadiosBase<Icon> | DefinitionOptionText | DefinitionOptionRange | DefinitionOptionNumber | DefinitionOptionDateTimeLocal;
package/dist/module.d.mts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { NuxtModule } from 'nuxt/schema';
2
- import { M as ModuleOptions } from './shared/editor.D28NbXr3.mjs';
3
- export { a as ModuleHooks } from './shared/editor.D28NbXr3.mjs';
2
+ import { M as ModuleOptions } from './shared/editor.BDyiQvbV.mjs';
3
+ export { a as ModuleHooks } from './shared/editor.BDyiQvbV.mjs';
4
4
  import 'consola';
5
5
  import '../dist/global/types/definitions.js';
6
6
  import '../dist/global/types/theme.js';
package/dist/module.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@blokkli/editor",
3
3
  "configKey": "blokkli",
4
- "version": "2.0.0-alpha.63",
4
+ "version": "2.0.0-alpha.64",
5
5
  "compatibility": {
6
6
  "nuxt": ">=3.15.0"
7
7
  },
package/dist/module.mjs CHANGED
@@ -5,7 +5,7 @@ import MagicString from 'magic-string';
5
5
  import { walk } from 'estree-walker-ts';
6
6
  import { pathToFileURL } from 'node:url';
7
7
  import { parseURL, parseQuery } from 'ufo';
8
- import { C as Collector, a as CollectedFile, c as extractObjectLiteral, p as parseTsObject, t as toValidVariableName, o as onlyUnique, f as falsy, s as sortObjectKeys } from './shared/editor.Gu7mgJ5Q.mjs';
8
+ import { C as Collector, a as CollectedFile, c as extractObjectLiteral, p as parseTsObject, t as toValidVariableName, o as onlyUnique, f as falsy, s as sortObjectKeys } from './shared/editor.BGemL1Oh.mjs';
9
9
  import { dirname, resolve, relative } from 'pathe';
10
10
  import micromatch from 'micromatch';
11
11
  import { hash } from 'ohash';
@@ -19,7 +19,7 @@ import 'typescript';
19
19
  import 'oxc-walker';
20
20
 
21
21
  const name = "@blokkli/editor";
22
- const version = "2.0.0-alpha.63";
22
+ const version = "2.0.0-alpha.64";
23
23
 
24
24
  function validateOption(optionKey, option, icons) {
25
25
  const errors = [];
@@ -1198,6 +1198,11 @@ class ModuleHelper {
1198
1198
  resolvers;
1199
1199
  fileCache;
1200
1200
  options;
1201
+ /**
1202
+ * npm packages to pre-bundle via Vite's optimizeDeps, collected from the core
1203
+ * module and enabled sub-modules. Flushed by {@link applyBuildConfig}.
1204
+ */
1205
+ packageDependencies = /* @__PURE__ */ new Set();
1201
1206
  isDev;
1202
1207
  isModuleBuild;
1203
1208
  isPrepare;
@@ -1254,6 +1259,43 @@ class ModuleHelper {
1254
1259
  from: this.resolvers.module.resolve("./runtime/composables/" + name)
1255
1260
  });
1256
1261
  }
1262
+ /**
1263
+ * Register npm packages that the editor imports at runtime so Vite
1264
+ * pre-bundles them.
1265
+ *
1266
+ * Without this, Vite discovers a dependency lazily on first import (often via
1267
+ * a dynamic `import()`) and triggers a full page reload to re-optimize. The
1268
+ * core module declares its own dependencies; optional modules (agent, charts,
1269
+ * …) declare theirs only when enabled, so projects that don't use a module
1270
+ * don't pre-bundle its dependencies.
1271
+ *
1272
+ * Collected here and flushed to the Vite config by {@link applyBuildConfig},
1273
+ * which the core module calls once all modules have run their setup.
1274
+ *
1275
+ * @param names - Bare package specifiers (e.g. 'echarts', '@tiptap/core').
1276
+ */
1277
+ addPackageDependency(...names) {
1278
+ for (const name of names) {
1279
+ this.packageDependencies.add(name);
1280
+ }
1281
+ }
1282
+ /**
1283
+ * Apply collected build configuration to the Nuxt/Vite config.
1284
+ *
1285
+ * Called once by the core module after every module's setup has run, so it
1286
+ * sees the full set of {@link addPackageDependency} registrations.
1287
+ */
1288
+ applyBuildConfig() {
1289
+ this.nuxt.options.vite.optimizeDeps ??= {};
1290
+ const include = this.nuxt.options.vite.optimizeDeps.include ??= [];
1291
+ const exclude = this.nuxt.options.vite.optimizeDeps.exclude ?? [];
1292
+ for (const name of this.packageDependencies) {
1293
+ if (include.includes(name) || exclude.includes(name)) {
1294
+ continue;
1295
+ }
1296
+ include.push(name);
1297
+ }
1298
+ }
1257
1299
  addAlias(name, path) {
1258
1300
  this.nuxt.options.alias[name] = path;
1259
1301
  this.nuxt.options.nitro.typescript ||= {};
@@ -4059,6 +4101,39 @@ const optionsSchema = withHelper((helper) => {
4059
4101
  }
4060
4102
  return defineFileTemplate(fileName, (ctx) => {
4061
4103
  const globalOptions = ctx.helper.options.globalOptions || {};
4104
+ const defaultLanguage = ctx.helper.options.defaultLanguage || "en";
4105
+ const normalizeDefinitionString = (value) => {
4106
+ if (typeof value === "string") {
4107
+ return { [defaultLanguage]: value };
4108
+ }
4109
+ return value;
4110
+ };
4111
+ const normalizeOption = (option) => {
4112
+ if (!option || typeof option !== "object") {
4113
+ return option;
4114
+ }
4115
+ const result = { ...option };
4116
+ if ("label" in result) {
4117
+ result.label = normalizeDefinitionString(result.label);
4118
+ }
4119
+ if ("description" in result) {
4120
+ result.description = normalizeDefinitionString(result.description);
4121
+ }
4122
+ if (result.options && typeof result.options === "object") {
4123
+ const normalizedOptions = {};
4124
+ for (const [key, value] of Object.entries(result.options)) {
4125
+ if (result.type === "checkboxes") {
4126
+ normalizedOptions[key] = normalizeDefinitionString(value);
4127
+ } else if (typeof value === "string") {
4128
+ normalizedOptions[key] = { label: { [defaultLanguage]: value } };
4129
+ } else {
4130
+ normalizedOptions[key] = normalizeOption(value);
4131
+ }
4132
+ }
4133
+ result.options = normalizedOptions;
4134
+ }
4135
+ return result;
4136
+ };
4062
4137
  const blocks = [...ctx.blocks.files.values()];
4063
4138
  const schema = blocks.reduce((acc, v) => {
4064
4139
  if (v.definition && isBlock(v.definition)) {
@@ -4074,6 +4149,12 @@ const optionsSchema = withHelper((helper) => {
4074
4149
  }
4075
4150
  return acc;
4076
4151
  }, {});
4152
+ for (const bundle of Object.keys(schema)) {
4153
+ const options = schema[bundle];
4154
+ for (const key of Object.keys(options)) {
4155
+ options[key] = normalizeOption(options[key]);
4156
+ }
4157
+ }
4077
4158
  const sorted = sortObjectKeys(schema);
4078
4159
  return JSON.stringify(sorted, null, 2);
4079
4160
  });
@@ -4590,9 +4671,31 @@ const module$1 = defineNuxtModule({
4590
4671
  const moduleDir = import.meta.url;
4591
4672
  const resolver = createResolver(moduleDir);
4592
4673
  nuxt.options.build.transpile.push(resolver.resolve("runtime"));
4593
- nuxt.options.vite.optimizeDeps ??= {};
4594
- nuxt.options.vite.optimizeDeps.include ??= [];
4595
- nuxt.options.vite.optimizeDeps.include.push("papaparse", "pofile");
4674
+ helper.addPackageDependency(
4675
+ "@floating-ui/dom",
4676
+ "@tiptap/core",
4677
+ "@tiptap/extension-emoji",
4678
+ "@tiptap/extension-mention",
4679
+ "@tiptap/extension-task-item",
4680
+ "@tiptap/extension-task-list",
4681
+ "@tiptap/starter-kit",
4682
+ "@tiptap/vue-3",
4683
+ "@vue/devtools-core",
4684
+ "@vue/devtools-kit",
4685
+ "axe-core",
4686
+ // CJS
4687
+ "fzf",
4688
+ "get-video-id",
4689
+ "html-diff-ts",
4690
+ "mitt",
4691
+ "papaparse",
4692
+ // CJS
4693
+ "pofile",
4694
+ // CJS
4695
+ "qrcode.vue",
4696
+ "twgl.js"
4697
+ );
4698
+ helper.applyBuildConfig();
4596
4699
  helper.addComponent("BlokkliField");
4597
4700
  helper.addComponent("BlokkliEditable");
4598
4701
  helper.addComponent("BlokkliProvider");
@@ -1,4 +1,4 @@
1
- import { B as BlokkliModule } from '../../shared/editor.D28NbXr3.mjs';
1
+ import { B as BlokkliModule } from '../../shared/editor.BDyiQvbV.mjs';
2
2
  import 'nuxt/schema';
3
3
  import 'consola';
4
4
  import '../../../dist/global/types/definitions.js';
@@ -3,7 +3,7 @@ import { fileURLToPath } from 'node:url';
3
3
  import * as path from 'node:path';
4
4
  import { defineBlokkliModule } from '../index.mjs';
5
5
  import * as fs from 'node:fs';
6
- import { C as Collector, a as CollectedFile, b as extractStringProperty } from '../../shared/editor.Gu7mgJ5Q.mjs';
6
+ import { C as Collector, a as CollectedFile, e as extractStringProperty } from '../../shared/editor.BGemL1Oh.mjs';
7
7
  import { d as defineCodeTemplate } from '../../shared/editor.6D5vApr0.mjs';
8
8
  import MagicString from 'magic-string';
9
9
  import { parse } from 'acorn';
@@ -645,6 +645,7 @@ export default defineNuxtConfig({
645
645
  "#blokkli/agent/server",
646
646
  moduleResolver.resolve("./runtime/server")
647
647
  );
648
+ ctx.helper.addPackageDependency("mammoth", "marked", "turndown", "zod");
648
649
  const moduleBlokkliDirs = ctx.helper.options.blokkliDirs || [];
649
650
  const moduleToolsDir = moduleResolver.resolve("./runtime/app/tools");
650
651
  const projectToolsDir = path.resolve(nuxt.options.rootDir, "blokkli/tools");
@@ -30,7 +30,7 @@ const bodyRows = computed(() => {
30
30
  });
31
31
  </script>
32
32
 
33
- <style>/*! tailwindcss v4.2.4 | MIT License | https://tailwindcss.com */
33
+ <style>/*! tailwindcss v4.3.1 | MIT License | https://tailwindcss.com */
34
34
  .bk-agent-attachment-table {
35
35
  width: 100%;
36
36
  border-collapse: collapse;
@@ -25,7 +25,7 @@ declare const __VLS_export: <TItem>(__VLS_props: NonNullable<Awaited<typeof __VL
25
25
  isSelected: boolean;
26
26
  }) => unknown;
27
27
  };
28
- emit: (evt: "update:page", value: number) => void;
28
+ emit: (event: "update:page", value: number) => void;
29
29
  }>) => import("vue").VNode & {
30
30
  __ctx?: Awaited<typeof __VLS_setup>;
31
31
  };
@@ -25,7 +25,7 @@ declare const __VLS_export: <TItem>(__VLS_props: NonNullable<Awaited<typeof __VL
25
25
  isSelected: boolean;
26
26
  }) => unknown;
27
27
  };
28
- emit: (evt: "update:page", value: number) => void;
28
+ emit: (event: "update:page", value: number) => void;
29
29
  }>) => import("vue").VNode & {
30
30
  __ctx?: Awaited<typeof __VLS_setup>;
31
31
  };
@@ -92,7 +92,7 @@ const { $t } = useBlokkli();
92
92
  const isExpanded = ref(false);
93
93
  </script>
94
94
 
95
- <style>/*! tailwindcss v4.2.4 | MIT License | https://tailwindcss.com */
95
+ <style>/*! tailwindcss v4.3.1 | MIT License | https://tailwindcss.com */
96
96
  .bk-agent-input-actions-button {
97
97
  display: flex;
98
98
  height: 40px;
@@ -42,7 +42,7 @@ const disclaimer = computed(() => {
42
42
  });
43
43
  </script>
44
44
 
45
- <style>/*! tailwindcss v4.2.4 | MIT License | https://tailwindcss.com */
45
+ <style>/*! tailwindcss v4.3.1 | MIT License | https://tailwindcss.com */
46
46
  .bk-agent-welcome-text ul + p {
47
47
  margin-top: 30px;
48
48
  }
@@ -134,7 +134,7 @@ export default {
134
134
  };
135
135
  </script>
136
136
 
137
- <style>/*! tailwindcss v4.2.4 | MIT License | https://tailwindcss.com */
137
+ <style>/*! tailwindcss v4.3.1 | MIT License | https://tailwindcss.com */
138
138
  .bk-agent-transcript-block {
139
139
  margin: 0px;
140
140
  border-radius: 4px;
@@ -168,7 +168,7 @@ export default {
168
168
  };
169
169
  </script>
170
170
 
171
- <style>/*! tailwindcss v4.2.4 | MIT License | https://tailwindcss.com */
171
+ <style>/*! tailwindcss v4.3.1 | MIT License | https://tailwindcss.com */
172
172
  @keyframes bk-sparkle {
173
173
  0%,
174
174
  100% {
@@ -13,11 +13,11 @@ export declare const paramsSchema: z.ZodObject<{
13
13
  }, z.core.$strip>;
14
14
  export declare const resultSchema: z.ZodUnion<readonly [z.ZodObject<{
15
15
  type: z.ZodEnum<{
16
+ options: "options";
16
17
  rewrite: "rewrite";
17
18
  delete: "delete";
18
19
  add: "add";
19
20
  move: "move";
20
- options: "options";
21
21
  }>;
22
22
  label: z.ZodString;
23
23
  }, z.core.$strip>, z.ZodObject<{
@@ -10,11 +10,11 @@ export declare const paramsSchema: z.ZodObject<{
10
10
  }, z.core.$strip>;
11
11
  export declare const resultSchema: z.ZodUnion<readonly [z.ZodObject<{
12
12
  type: z.ZodEnum<{
13
+ options: "options";
13
14
  rewrite: "rewrite";
14
15
  delete: "delete";
15
16
  add: "add";
16
17
  move: "move";
17
- options: "options";
18
18
  }>;
19
19
  label: z.ZodString;
20
20
  }, z.core.$strip>, z.ZodObject<{
@@ -12,11 +12,11 @@ export declare const paramsSchema: z.ZodObject<{
12
12
  }, z.core.$strip>;
13
13
  export declare const resultSchema: z.ZodUnion<readonly [z.ZodObject<{
14
14
  type: z.ZodEnum<{
15
+ options: "options";
15
16
  rewrite: "rewrite";
16
17
  delete: "delete";
17
18
  add: "add";
18
19
  move: "move";
19
- options: "options";
20
20
  }>;
21
21
  label: z.ZodString;
22
22
  }, z.core.$strip>, z.ZodObject<{
@@ -20,11 +20,11 @@ export declare const paramsSchema: z.ZodObject<{
20
20
  }, z.core.$strip>;
21
21
  export declare const resultSchema: z.ZodUnion<readonly [z.ZodObject<{
22
22
  type: z.ZodEnum<{
23
+ options: "options";
23
24
  rewrite: "rewrite";
24
25
  delete: "delete";
25
26
  add: "add";
26
27
  move: "move";
27
- options: "options";
28
28
  }>;
29
29
  label: z.ZodString;
30
30
  }, z.core.$strip>, z.ZodObject<{
@@ -10,11 +10,11 @@ export declare const paramsSchema: z.ZodObject<{
10
10
  }, z.core.$strip>;
11
11
  export declare const resultSchema: z.ZodUnion<readonly [z.ZodObject<{
12
12
  type: z.ZodEnum<{
13
+ options: "options";
13
14
  rewrite: "rewrite";
14
15
  delete: "delete";
15
16
  add: "add";
16
17
  move: "move";
17
- options: "options";
18
18
  }>;
19
19
  label: z.ZodString;
20
20
  }, z.core.$strip>, z.ZodObject<{
@@ -10,11 +10,11 @@ export declare const paramsSchema: z.ZodObject<{
10
10
  }, z.core.$strip>;
11
11
  export declare const resultSchema: z.ZodUnion<readonly [z.ZodObject<{
12
12
  type: z.ZodEnum<{
13
+ options: "options";
13
14
  rewrite: "rewrite";
14
15
  delete: "delete";
15
16
  add: "add";
16
17
  move: "move";
17
- options: "options";
18
18
  }>;
19
19
  label: z.ZodString;
20
20
  }, z.core.$strip>, z.ZodObject<{
@@ -115,7 +115,7 @@ function cancel() {
115
115
  }
116
116
  </script>
117
117
 
118
- <style>/*! tailwindcss v4.2.4 | MIT License | https://tailwindcss.com */
118
+ <style>/*! tailwindcss v4.3.1 | MIT License | https://tailwindcss.com */
119
119
  :is(.bk-agent-tool-question-list .bk-radio,.bk-agent-tool-question-list .bk-checkbox) input + span {
120
120
  font-size: var(--text-sm, 14px);
121
121
  line-height: var(--bk-tw-leading, var(--text-sm--line-height, calc(1.25 / 0.875)));
@@ -5,7 +5,7 @@ export declare const paramsSchema: z.ZodObject<{
5
5
  value: z.ZodString;
6
6
  label: z.ZodString;
7
7
  }, z.core.$strip>>;
8
- multiSelect: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodTransform<unknown, unknown>, z.ZodBoolean>>>;
8
+ multiSelect: z.ZodDefault<z.ZodOptional<z.ZodPreprocess<z.ZodBoolean>>>;
9
9
  paragraphUuids: z.ZodOptional<z.ZodArray<z.ZodString>>;
10
10
  }, z.core.$strip>;
11
11
  export declare const resultSchema: z.ZodObject<{
@@ -2,7 +2,7 @@ import { z } from 'zod';
2
2
  import { fieldDiffResultSchema } from '../schemas.js';
3
3
  import { type SkippedField } from '../fieldDiffApproval.js';
4
4
  export declare const paramsSchema: z.ZodObject<{
5
- uuids: z.ZodPipe<z.ZodTransform<unknown, unknown>, z.ZodArray<z.ZodString>>;
5
+ uuids: z.ZodPreprocess<z.ZodArray<z.ZodString>>;
6
6
  }, z.core.$strip>;
7
7
  export type AutoTranslateParams = z.infer<typeof paramsSchema>;
8
8
  export type AutoTranslateResult = z.infer<typeof fieldDiffResultSchema>;
@@ -4,11 +4,11 @@ export declare const paramsSchema: z.ZodObject<{
4
4
  }, z.core.$strip>;
5
5
  export declare const resultSchema: z.ZodUnion<readonly [z.ZodObject<{
6
6
  type: z.ZodEnum<{
7
+ options: "options";
7
8
  rewrite: "rewrite";
8
9
  delete: "delete";
9
10
  add: "add";
10
11
  move: "move";
11
- options: "options";
12
12
  }>;
13
13
  label: z.ZodString;
14
14
  }, z.core.$strip>, z.ZodObject<{
@@ -4,11 +4,11 @@ export declare const paramsSchema: z.ZodObject<{
4
4
  }, z.core.$strip>;
5
5
  export declare const resultSchema: z.ZodUnion<readonly [z.ZodObject<{
6
6
  type: z.ZodEnum<{
7
+ options: "options";
7
8
  rewrite: "rewrite";
8
9
  delete: "delete";
9
10
  add: "add";
10
11
  move: "move";
11
- options: "options";
12
12
  }>;
13
13
  label: z.ZodString;
14
14
  }, z.core.$strip>, z.ZodObject<{
@@ -10,11 +10,11 @@ export declare const paramsSchema: z.ZodObject<{
10
10
  }, z.core.$strip>;
11
11
  export declare const resultSchema: z.ZodUnion<readonly [z.ZodObject<{
12
12
  type: z.ZodEnum<{
13
+ options: "options";
13
14
  rewrite: "rewrite";
14
15
  delete: "delete";
15
16
  add: "add";
16
17
  move: "move";
17
- options: "options";
18
18
  }>;
19
19
  label: z.ZodString;
20
20
  }, z.core.$strip>, z.ZodObject<{
@@ -18,9 +18,7 @@ export function decideFieldUpdates(items, selected, reasons) {
18
18
  let totalCount = 0;
19
19
  for (const item of items) {
20
20
  if (item.segments) {
21
- const atoms = flattenSegments(item.segments).filter(
22
- (s) => s.status !== "matched" || s.beforeHtml !== s.afterHtml
23
- );
21
+ const atoms = flattenSegments(item.segments).filter((s) => s.changed);
24
22
  totalCount += atoms.length;
25
23
  const acceptedById = {};
26
24
  const rejectedSegments = [];
@@ -2,8 +2,8 @@ import { z } from 'zod';
2
2
  export declare const paramsSchema: z.ZodObject<{
3
3
  bundle: z.ZodOptional<z.ZodString>;
4
4
  bundles: z.ZodOptional<z.ZodArray<z.ZodString>>;
5
- hasChildren: z.ZodOptional<z.ZodPipe<z.ZodTransform<unknown, unknown>, z.ZodBoolean>>;
6
- isRootLevel: z.ZodOptional<z.ZodPipe<z.ZodTransform<unknown, unknown>, z.ZodBoolean>>;
5
+ hasChildren: z.ZodOptional<z.ZodPreprocess<z.ZodBoolean>>;
6
+ isRootLevel: z.ZodOptional<z.ZodPreprocess<z.ZodBoolean>>;
7
7
  nestingLevel: z.ZodOptional<z.ZodNumber>;
8
8
  parentBundle: z.ZodOptional<z.ZodString>;
9
9
  inField: z.ZodOptional<z.ZodString>;