@blokkli/editor 2.0.0-alpha.36 → 2.0.0-alpha.37

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 (218) hide show
  1. package/dist/global/types/blockOptions.d.ts +4 -3
  2. package/dist/module.d.mts +2 -2
  3. package/dist/module.json +1 -1
  4. package/dist/module.mjs +71 -4
  5. package/dist/modules/agent/index.d.mts +1 -1
  6. package/dist/modules/agent/index.mjs +236 -6
  7. package/dist/modules/agent/runtime/app/composables/agentProvider.js +31 -14
  8. package/dist/modules/agent/runtime/app/composables/defineBlokkliAgentTool.d.ts +2 -20
  9. package/dist/modules/agent/runtime/app/composables/defineBlokkliAgentTool.js +0 -3
  10. package/dist/modules/agent/runtime/app/features/agent/Panel/Conversation/Item/Assistant/index.vue +2 -2
  11. package/dist/modules/agent/runtime/app/features/agent/Panel/Conversation/Item/User/index.vue +1 -2
  12. package/dist/modules/agent/runtime/app/features/agent/Panel/DebugGallery/index.vue +1 -2
  13. package/dist/modules/agent/runtime/app/features/agent/Panel/Input/Actions/index.d.vue.ts +1 -0
  14. package/dist/modules/agent/runtime/app/features/agent/Panel/Input/Actions/index.vue +66 -59
  15. package/dist/modules/agent/runtime/app/features/agent/Panel/Input/Actions/index.vue.d.ts +1 -0
  16. package/dist/modules/agent/runtime/app/features/agent/Panel/Input/index.vue +10 -12
  17. package/dist/modules/agent/runtime/app/features/agent/Panel/Welcome/de.md +2 -2
  18. package/dist/modules/agent/runtime/app/features/agent/Panel/Welcome/en.md +2 -2
  19. package/dist/modules/agent/runtime/app/features/agent/Panel/index.vue +1 -5
  20. package/dist/modules/agent/runtime/app/features/agent/index.vue +89 -37
  21. package/dist/modules/agent/runtime/app/helpers/index.d.ts +16 -19
  22. package/dist/modules/agent/runtime/app/helpers/index.js +22 -46
  23. package/dist/modules/agent/runtime/app/helpers/pageStructure.js +1 -1
  24. package/dist/modules/agent/runtime/app/tools/add_content_search_paragraph/index.js +5 -9
  25. package/dist/modules/agent/runtime/app/tools/add_fragment/index.js +2 -6
  26. package/dist/modules/agent/runtime/app/tools/add_media_paragraph/index.js +2 -6
  27. package/dist/modules/agent/runtime/app/tools/add_paragraphs/index.js +2 -3
  28. package/dist/modules/agent/runtime/app/tools/add_reusable_paragraph/index.js +2 -6
  29. package/dist/modules/agent/runtime/app/tools/add_template/index.js +2 -6
  30. package/dist/modules/agent/runtime/app/tools/analyze_content/index.d.ts +2 -0
  31. package/dist/modules/agent/runtime/app/tools/analyze_content/index.js +120 -0
  32. package/dist/modules/agent/runtime/app/tools/check_readability/index.d.ts +2 -0
  33. package/dist/modules/agent/runtime/app/tools/check_readability/index.js +57 -0
  34. package/dist/modules/agent/runtime/app/tools/duplicate_paragraphs/index.js +2 -6
  35. package/dist/modules/agent/runtime/app/tools/get_all_page_content/index.js +1 -1
  36. package/dist/modules/agent/runtime/app/tools/get_bundle_info/index.js +2 -1
  37. package/dist/modules/agent/runtime/app/tools/get_content_fields/index.js +1 -1
  38. package/dist/modules/agent/runtime/app/tools/get_paragraph_context/index.js +2 -5
  39. package/dist/modules/agent/runtime/app/tools/get_paragraph_options/index.js +2 -1
  40. package/dist/modules/agent/runtime/app/tools/get_selected_paragraphs/index.js +2 -3
  41. package/dist/modules/agent/runtime/app/tools/helpers.d.ts +53 -0
  42. package/dist/modules/agent/runtime/app/tools/helpers.js +187 -0
  43. package/dist/modules/agent/runtime/app/tools/move_paragraphs/index.js +2 -6
  44. package/dist/modules/agent/runtime/app/tools/schemas.d.ts +0 -52
  45. package/dist/modules/agent/runtime/app/tools/schemas.js +0 -187
  46. package/dist/modules/agent/runtime/app/tools/search_content/index.js +40 -47
  47. package/dist/modules/agent/runtime/app/tools/set_paragraph_options/index.js +2 -5
  48. package/dist/modules/agent/runtime/app/types/index.d.ts +0 -61
  49. package/dist/modules/agent/runtime/server/Session.d.ts +25 -6
  50. package/dist/modules/agent/runtime/server/Session.js +109 -30
  51. package/dist/modules/agent/runtime/server/SessionManager.d.ts +3 -0
  52. package/dist/modules/agent/runtime/server/SessionManager.js +4 -1
  53. package/dist/modules/agent/runtime/server/agent.js +3 -2
  54. package/dist/modules/agent/runtime/server/default-skills/fixReadability.d.ts +2 -0
  55. package/dist/modules/agent/runtime/server/default-skills/fixReadability.js +69 -0
  56. package/dist/modules/agent/runtime/server/default-system-prompts/page-context.js +28 -0
  57. package/dist/modules/agent/runtime/server/server-tools/index.d.ts +10 -2
  58. package/dist/modules/agent/runtime/server/server-tools/index.js +1 -1
  59. package/dist/modules/agent/runtime/server/server-tools/load_tools/index.js +1 -1
  60. package/dist/modules/agent/runtime/shared/types.d.ts +46 -11
  61. package/dist/modules/agent/runtime/shared/types.js +22 -10
  62. package/dist/modules/charts/index.d.mts +1 -1
  63. package/dist/modules/charts/index.mjs +21 -7
  64. package/dist/modules/charts/runtime/blokkli/skills/charts.js +6 -6
  65. package/dist/modules/charts/runtime/blokkli/tools/chart_schemas.d.ts +25 -2
  66. package/dist/modules/charts/runtime/blokkli/tools/chart_schemas.js +39 -1
  67. package/dist/modules/charts/runtime/blokkli/tools/create_chart/index.js +24 -17
  68. package/dist/modules/charts/runtime/blokkli/tools/get_chart_data/index.js +11 -19
  69. package/dist/modules/charts/runtime/blokkli/tools/get_chart_type_options/index.js +2 -4
  70. package/dist/modules/charts/runtime/blokkli/tools/update_chart/index.js +8 -20
  71. package/dist/modules/charts/runtime/chartTypes/area.d.ts +6 -1
  72. package/dist/modules/charts/runtime/chartTypes/bar.d.ts +7 -1
  73. package/dist/modules/charts/runtime/chartTypes/define.d.ts +1 -1
  74. package/dist/modules/charts/runtime/chartTypes/donut.d.ts +5 -1
  75. package/dist/modules/charts/runtime/chartTypes/heatmap.d.ts +3 -1
  76. package/dist/modules/charts/runtime/chartTypes/index.d.ts +18 -0
  77. package/dist/modules/charts/runtime/chartTypes/line.d.ts +6 -1
  78. package/dist/modules/charts/runtime/chartTypes/pie.d.ts +4 -1
  79. package/dist/modules/charts/runtime/chartTypes/radar.d.ts +6 -1
  80. package/dist/modules/charts/runtime/chartTypes/radialBar.d.ts +5 -1
  81. package/dist/modules/charts/runtime/chartTypes/shared.d.ts +20 -5
  82. package/dist/modules/charts/runtime/chartTypes/types.d.ts +6 -6
  83. package/dist/modules/charts/runtime/components/ChartRenderer/index.d.vue.ts +145 -2
  84. package/dist/modules/charts/runtime/components/ChartRenderer/index.vue +2 -2
  85. package/dist/modules/charts/runtime/components/ChartRenderer/index.vue.d.ts +145 -2
  86. package/dist/modules/charts/runtime/components/index.d.ts +1 -0
  87. package/dist/modules/charts/runtime/components/index.js +1 -0
  88. package/dist/modules/charts/runtime/features/charts/Editor/ChartTypeOptions/index.d.vue.ts +3 -2
  89. package/dist/modules/charts/runtime/features/charts/Editor/ChartTypeOptions/index.vue.d.ts +3 -2
  90. package/dist/modules/charts/runtime/features/charts/Editor/CsvImport/index.vue +1 -2
  91. package/dist/modules/charts/runtime/features/charts/Editor/FootnoteEditor/index.vue +1 -1
  92. package/dist/modules/charts/runtime/features/charts/Editor/Preview/index.d.vue.ts +2 -0
  93. package/dist/modules/charts/runtime/features/charts/Editor/Preview/index.vue +35 -13
  94. package/dist/modules/charts/runtime/features/charts/Editor/Preview/index.vue.d.ts +2 -0
  95. package/dist/modules/charts/runtime/features/charts/Editor/index.d.vue.ts +1 -0
  96. package/dist/modules/charts/runtime/features/charts/Editor/index.vue +9 -3
  97. package/dist/modules/charts/runtime/features/charts/Editor/index.vue.d.ts +1 -0
  98. package/dist/modules/charts/runtime/features/charts/Editor/useChartEditorState.js +1 -1
  99. package/dist/modules/charts/runtime/features/charts/index.vue +6 -6
  100. package/dist/modules/charts/runtime/helpers/index.d.ts +25 -0
  101. package/dist/modules/charts/runtime/helpers/index.js +63 -0
  102. package/dist/modules/charts/runtime/types.d.ts +10 -28
  103. package/dist/modules/charts/runtime/types.js +0 -64
  104. package/dist/modules/drupal/index.d.mts +1 -1
  105. package/dist/modules/drupal/runtime/adapter/index.d.ts +3 -1
  106. package/dist/modules/drupal/runtime/adapter/index.js +4 -4
  107. package/dist/modules/table-of-contents/index.d.mts +1 -1
  108. package/dist/runtime/components/BlokkliItem.vue +1 -1
  109. package/dist/runtime/composables/defineBlokkli.js +1 -1
  110. package/dist/runtime/editor/components/AnimationCanvas/index.vue +13 -7
  111. package/dist/runtime/editor/components/Banner/index.d.vue.ts +1 -0
  112. package/dist/runtime/editor/components/Banner/index.vue +1 -1
  113. package/dist/runtime/editor/components/Banner/index.vue.d.ts +1 -0
  114. package/dist/runtime/editor/components/DropdownItem/index.d.vue.ts +1 -0
  115. package/dist/runtime/editor/components/DropdownItem/index.vue +3 -2
  116. package/dist/runtime/editor/components/DropdownItem/index.vue.d.ts +1 -0
  117. package/dist/runtime/editor/components/EditProvider.vue +7 -4
  118. package/dist/runtime/editor/components/FlexTextarea/index.d.vue.ts +5 -1
  119. package/dist/runtime/editor/components/FlexTextarea/index.vue +24 -101
  120. package/dist/runtime/editor/components/FlexTextarea/index.vue.d.ts +5 -1
  121. package/dist/runtime/editor/components/NestedEditorOverlay/index.vue +28 -9
  122. package/dist/runtime/editor/components/Popup/index.d.vue.ts +30 -0
  123. package/dist/runtime/editor/components/Popup/index.vue +82 -0
  124. package/dist/runtime/editor/components/Popup/index.vue.d.ts +30 -0
  125. package/dist/runtime/editor/components/Resizable/index.vue +4 -1
  126. package/dist/runtime/editor/components/Toolbar/index.vue +107 -6
  127. package/dist/runtime/editor/components/index.d.ts +4 -3
  128. package/dist/runtime/editor/components/index.js +6 -4
  129. package/dist/runtime/editor/composables/defineDropAreas.js +3 -3
  130. package/dist/runtime/editor/composables/defineDropHandler.d.ts +3 -0
  131. package/dist/runtime/editor/composables/defineDropHandler.js +10 -0
  132. package/dist/runtime/editor/composables/index.d.ts +1 -0
  133. package/dist/runtime/editor/composables/index.js +1 -0
  134. package/dist/runtime/editor/css/output.css +1 -1
  135. package/dist/runtime/editor/events/index.d.ts +9 -0
  136. package/dist/runtime/editor/features/add-list/index.vue +58 -1
  137. package/dist/runtime/editor/features/analyze/Main.d.vue.ts +3 -2
  138. package/dist/runtime/editor/features/analyze/Main.vue +28 -44
  139. package/dist/runtime/editor/features/analyze/Main.vue.d.ts +3 -2
  140. package/dist/runtime/editor/features/analyze/analyzers/readability.js +65 -0
  141. package/dist/runtime/editor/features/analyze/analyzers/types.d.ts +19 -0
  142. package/dist/runtime/editor/features/analyze/index.vue +18 -15
  143. package/dist/runtime/editor/features/clipboard/DropElement/Video.d.vue.ts +8 -0
  144. package/dist/runtime/editor/features/clipboard/{List/Item → DropElement}/Video.vue +1 -5
  145. package/dist/runtime/editor/features/clipboard/DropElement/Video.vue.d.ts +8 -0
  146. package/dist/runtime/editor/features/clipboard/DropElement/helpers.d.ts +1 -0
  147. package/dist/runtime/editor/features/clipboard/DropElement/helpers.js +14 -0
  148. package/dist/runtime/editor/features/clipboard/DropElement/index.d.vue.ts +16 -0
  149. package/dist/runtime/editor/features/clipboard/DropElement/index.vue +97 -0
  150. package/dist/runtime/editor/features/clipboard/DropElement/index.vue.d.ts +16 -0
  151. package/dist/runtime/editor/features/clipboard/helpers.d.ts +15 -0
  152. package/dist/runtime/editor/features/clipboard/helpers.js +62 -0
  153. package/dist/runtime/editor/features/clipboard/index.vue +585 -337
  154. package/dist/runtime/editor/features/clipboard/types.d.ts +14 -2
  155. package/dist/runtime/editor/features/dragging-overlay/DragItems/index.vue +17 -5
  156. package/dist/runtime/editor/features/dragging-overlay/Renderer/index.vue +2 -2
  157. package/dist/runtime/editor/features/dragging-overlay/index.vue +125 -219
  158. package/dist/runtime/editor/features/editable-field/Overlay/Plaintext/index.vue +4 -4
  159. package/dist/runtime/editor/features/editable-field/Overlay/index.vue +6 -0
  160. package/dist/runtime/editor/features/library/index.vue +14 -0
  161. package/dist/runtime/editor/features/media-library/index.vue +32 -1
  162. package/dist/runtime/editor/features/options/Form/ComplexType/index.d.vue.ts +11 -0
  163. package/dist/runtime/editor/features/options/Form/ComplexType/index.vue +36 -0
  164. package/dist/runtime/editor/features/options/Form/ComplexType/index.vue.d.ts +11 -0
  165. package/dist/runtime/editor/features/options/Form/Item.d.vue.ts +3 -2
  166. package/dist/runtime/editor/features/options/Form/Item.vue +10 -2
  167. package/dist/runtime/editor/features/options/Form/Item.vue.d.ts +3 -2
  168. package/dist/runtime/editor/features/options/Form/index.vue +5 -0
  169. package/dist/runtime/editor/features/search/index.vue +25 -1
  170. package/dist/runtime/editor/features/structure/index.vue +25 -1
  171. package/dist/runtime/editor/features/tour/index.vue +22 -12
  172. package/dist/runtime/editor/helpers/clipboardData/index.d.ts +11 -0
  173. package/dist/runtime/editor/helpers/clipboardData/index.js +157 -0
  174. package/dist/runtime/editor/helpers/options/index.js +5 -0
  175. package/dist/runtime/editor/icons/svg/stars.svg +5 -1
  176. package/dist/runtime/editor/plugins/Sidebar/Detached/index.d.vue.ts +1 -1
  177. package/dist/runtime/editor/plugins/Sidebar/Detached/index.vue.d.ts +1 -1
  178. package/dist/runtime/editor/plugins/Sidebar/index.d.vue.ts +14 -3
  179. package/dist/runtime/editor/plugins/Sidebar/index.vue +4 -2
  180. package/dist/runtime/editor/plugins/Sidebar/index.vue.d.ts +14 -3
  181. package/dist/runtime/editor/providers/analyze.d.ts +43 -0
  182. package/dist/runtime/editor/providers/analyze.js +78 -0
  183. package/dist/runtime/editor/providers/animation.d.ts +4 -0
  184. package/dist/runtime/editor/providers/animation.js +6 -0
  185. package/dist/runtime/editor/providers/dragdrop.d.ts +55 -0
  186. package/dist/runtime/editor/providers/dragdrop.js +37 -0
  187. package/dist/runtime/editor/providers/storage.js +15 -0
  188. package/dist/runtime/editor/providers/ui.d.ts +6 -0
  189. package/dist/runtime/editor/providers/ui.js +19 -0
  190. package/dist/runtime/editor/translations/de.json +73 -61
  191. package/dist/runtime/editor/translations/fr.json +67 -55
  192. package/dist/runtime/editor/translations/gsw_CH.json +71 -59
  193. package/dist/runtime/editor/translations/it.json +67 -55
  194. package/dist/runtime/editor/types/app.d.ts +4 -2
  195. package/dist/runtime/editor/types/draggable.d.ts +1 -0
  196. package/dist/runtime/editor/types/ui.d.ts +1 -1
  197. package/dist/runtime/helpers/injections.d.ts +1 -1
  198. package/dist/runtime/types/blockOptions.d.ts +2 -1
  199. package/dist/runtime/types/definitions.d.ts +4 -0
  200. package/dist/shared/{editor.CWQIFIEQ.d.mts → editor.BdBm1Z7C.d.mts} +12 -0
  201. package/dist/types.d.mts +1 -1
  202. package/package.json +5 -3
  203. package/dist/modules/charts/runtime/components/Fragment/BlokkliChart.d.vue.ts +0 -3
  204. package/dist/modules/charts/runtime/components/Fragment/BlokkliChart.vue +0 -29
  205. package/dist/modules/charts/runtime/components/Fragment/BlokkliChart.vue.d.ts +0 -3
  206. package/dist/runtime/editor/features/clipboard/List/Item/File.d.vue.ts +0 -4
  207. package/dist/runtime/editor/features/clipboard/List/Item/File.vue +0 -60
  208. package/dist/runtime/editor/features/clipboard/List/Item/File.vue.d.ts +0 -4
  209. package/dist/runtime/editor/features/clipboard/List/Item/Video.d.vue.ts +0 -4
  210. package/dist/runtime/editor/features/clipboard/List/Item/Video.vue.d.ts +0 -4
  211. package/dist/runtime/editor/features/clipboard/List/index.d.vue.ts +0 -11
  212. package/dist/runtime/editor/features/clipboard/List/index.vue +0 -72
  213. package/dist/runtime/editor/features/clipboard/List/index.vue.d.ts +0 -11
  214. package/dist/runtime/editor/features/tour/Popup/index.d.vue.ts +0 -9
  215. package/dist/runtime/editor/features/tour/Popup/index.vue +0 -34
  216. package/dist/runtime/editor/features/tour/Popup/index.vue.d.ts +0 -9
  217. package/dist/runtime/editor/providers/dropArea.d.ts +0 -48
  218. package/dist/runtime/editor/providers/dropArea.js +0 -22
@@ -0,0 +1,3 @@
1
+ import type { DraggableItemTypes } from '../types/draggable.js';
2
+ import type { DropHandler } from '../providers/dragdrop.js';
3
+ export declare function defineDropHandler<K extends keyof DraggableItemTypes>(itemType: K, handler: DropHandler<K>): void;
@@ -0,0 +1,10 @@
1
+ import { onBeforeUnmount, onMounted, useBlokkli } from "#imports";
2
+ export function defineDropHandler(itemType, handler) {
3
+ const { dragdrop } = useBlokkli();
4
+ onMounted(() => {
5
+ dragdrop.registerDropHandler(itemType, handler);
6
+ });
7
+ onBeforeUnmount(() => {
8
+ dragdrop.unregisterDropHandler(itemType, handler);
9
+ });
10
+ }
@@ -2,6 +2,7 @@ export { addElementClasses } from './addElementClasses.js';
2
2
  export { defineAddAction } from './defineAddAction.js';
3
3
  export { defineCommands } from './defineCommands.js';
4
4
  export { defineDropAreas } from './defineDropAreas.js';
5
+ export { defineDropHandler } from './defineDropHandler.js';
5
6
  export { defineElementStyle } from './defineElementStyle.js';
6
7
  export { defineItemDropdownAction } from './defineItemDropdownAction.js';
7
8
  export { defineMenuButton } from './defineMenuButton.js';
@@ -2,6 +2,7 @@ export { addElementClasses } from "./addElementClasses.js";
2
2
  export { defineAddAction } from "./defineAddAction.js";
3
3
  export { defineCommands } from "./defineCommands.js";
4
4
  export { defineDropAreas } from "./defineDropAreas.js";
5
+ export { defineDropHandler } from "./defineDropHandler.js";
5
6
  export { defineElementStyle } from "./defineElementStyle.js";
6
7
  export { defineItemDropdownAction } from "./defineItemDropdownAction.js";
7
8
  export { defineMenuButton } from "./defineMenuButton.js";