@blokkli/editor 2.0.0-alpha.23 → 2.0.0-alpha.25

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 (259) hide show
  1. package/dist/module.json +1 -1
  2. package/dist/module.mjs +252 -92
  3. package/dist/runtime/blokkliPlugins/BlockIndicator/index.vue.d.ts +38 -0
  4. package/dist/runtime/blokkliPlugins/ContextMenu/index.vue +1 -1
  5. package/dist/runtime/blokkliPlugins/ContextMenu/index.vue.d.ts +15 -0
  6. package/dist/runtime/blokkliPlugins/DebugOverlay/index.vue.d.ts +6 -0
  7. package/dist/runtime/blokkliPlugins/ItemAction/index.vue.d.ts +28 -3
  8. package/dist/runtime/blokkliPlugins/Sidebar/Detached/index.vue +6 -4
  9. package/dist/runtime/blokkliPlugins/Sidebar/index.vue +11 -3
  10. package/dist/runtime/blokkliPlugins/Sidebar/index.vue.d.ts +138 -3
  11. package/dist/runtime/blokkliPlugins/ToolbarButton/index.vue +5 -1
  12. package/dist/runtime/blokkliPlugins/ToolbarButton/index.vue.d.ts +116 -0
  13. package/dist/runtime/blokkliPlugins/TourItem/index.vue +22 -13
  14. package/dist/runtime/blokkliPlugins/TourItem/index.vue.d.ts +22 -0
  15. package/dist/runtime/blokkliPlugins/ViewOption/index.vue.d.ts +98 -0
  16. package/dist/runtime/blokkliPlugins/index.d.ts +1 -3
  17. package/dist/runtime/blokkliPlugins/index.js +0 -4
  18. package/dist/runtime/components/Blocks/NotImplemented/index.vue +24 -0
  19. package/dist/runtime/components/Blocks/NotImplemented/index.vue.d.ts +6 -0
  20. package/dist/runtime/components/BlokkliEditable.vue.d.ts +11 -0
  21. package/dist/runtime/components/BlokkliItem.vue +16 -3
  22. package/dist/runtime/components/BlokkliItem.vue.d.ts +2 -0
  23. package/dist/runtime/components/BlokkliProvider.vue.d.ts +1 -1
  24. package/dist/runtime/components/Edit/Actions/ItemDropdown.vue +1 -1
  25. package/dist/runtime/components/Edit/Actions/index.vue +78 -73
  26. package/dist/runtime/components/Edit/AddListItem/index.vue +9 -35
  27. package/dist/runtime/components/Edit/AddListItem/index.vue.d.ts +6 -15
  28. package/dist/runtime/components/Edit/AppMenu/MenuButton.vue +39 -0
  29. package/dist/runtime/{blokkliPlugins/MenuButton/index.vue.d.ts → components/Edit/AppMenu/MenuButton.vue.d.ts} +0 -4
  30. package/dist/runtime/components/Edit/AppMenu/index.vue +62 -40
  31. package/dist/runtime/components/Edit/ArtboardTooltip/index.vue +6 -0
  32. package/dist/runtime/components/Edit/BlockProxy/index.vue +2 -2
  33. package/dist/runtime/components/Edit/BlokkliErrorBoundary.vue +3 -0
  34. package/dist/runtime/components/Edit/BlokkliRootErrorBoundary.vue +4 -1
  35. package/dist/runtime/components/Edit/Dialog/index.vue +33 -47
  36. package/dist/runtime/components/Edit/Dialog/index.vue.d.ts +2 -0
  37. package/dist/runtime/components/Edit/DraggableList.vue +12 -9
  38. package/dist/runtime/components/Edit/EditIndicator.vue +11 -4
  39. package/dist/runtime/components/Edit/EditProvider.vue +75 -55
  40. package/dist/runtime/components/Edit/EditProvider.vue.d.ts +1 -1
  41. package/dist/runtime/components/Edit/Features/AddList/Actions/Action.vue +53 -0
  42. package/dist/runtime/components/Edit/Features/AddList/Actions/Action.vue.d.ts +7 -0
  43. package/dist/runtime/components/Edit/Features/AddList/Actions/index.vue +41 -0
  44. package/dist/runtime/components/Edit/Features/AddList/Actions/index.vue.d.ts +5 -0
  45. package/dist/runtime/components/Edit/Features/AddList/Blocks/index.vue +13 -50
  46. package/dist/runtime/components/Edit/Features/AddList/Blocks/index.vue.d.ts +5 -0
  47. package/dist/runtime/components/Edit/Features/AddList/index.vue +76 -119
  48. package/dist/runtime/components/Edit/Features/Analyze/Icon.vue +85 -0
  49. package/dist/runtime/components/Edit/Features/Analyze/Icon.vue.d.ts +5 -0
  50. package/dist/runtime/components/Edit/Features/Analyze/Main.vue +288 -59
  51. package/dist/runtime/components/Edit/Features/Analyze/Main.vue.d.ts +8 -1
  52. package/dist/runtime/components/Edit/Features/Analyze/Renderer/fragment.glsl +25 -13
  53. package/dist/runtime/components/Edit/Features/Analyze/Renderer/index.vue +114 -52
  54. package/dist/runtime/components/Edit/Features/Analyze/Renderer/index.vue.d.ts +16 -2
  55. package/dist/runtime/components/Edit/Features/Analyze/Renderer/vertex.glsl +31 -11
  56. package/dist/runtime/components/Edit/Features/Analyze/Results/Results.vue +2 -0
  57. package/dist/runtime/components/Edit/Features/Analyze/Results/Results.vue.d.ts +8 -1
  58. package/dist/runtime/components/Edit/Features/Analyze/Results/ResultsItem.vue +4 -4
  59. package/dist/runtime/components/Edit/Features/Analyze/Results/ResultsItem.vue.d.ts +20 -2
  60. package/dist/runtime/components/Edit/Features/Analyze/Results/ResultsItemNodes.vue +11 -18
  61. package/dist/runtime/components/Edit/Features/Analyze/Results/ResultsItemNodes.vue.d.ts +10 -3
  62. package/dist/runtime/components/Edit/Features/Analyze/Results/ResultsItemNodesTarget.vue +46 -40
  63. package/dist/runtime/components/Edit/Features/Analyze/Results/ResultsItemNodesTarget.vue.d.ts +10 -4
  64. package/dist/runtime/components/Edit/Features/Analyze/Summary/Chart.vue +8 -4
  65. package/dist/runtime/components/Edit/Features/Analyze/analyzers/axe.js +1 -0
  66. package/dist/runtime/components/Edit/Features/Analyze/analyzers/helpers/Context.d.ts +4 -3
  67. package/dist/runtime/components/Edit/Features/Analyze/analyzers/helpers/Context.js +2 -1
  68. package/dist/runtime/components/Edit/Features/Analyze/analyzers/readability.js +61 -20
  69. package/dist/runtime/components/Edit/Features/Analyze/analyzers/types.d.ts +15 -1
  70. package/dist/runtime/components/Edit/Features/Analyze/index.vue +23 -2
  71. package/dist/runtime/components/Edit/Features/Artboard/Overview/index.vue +22 -8
  72. package/dist/runtime/components/Edit/Features/Artboard/Renderer.vue +42 -21
  73. package/dist/runtime/components/Edit/Features/Artboard/Scrollbar/index.vue +10 -4
  74. package/dist/runtime/components/Edit/Features/Assistant/Overlay/index.vue +2 -28
  75. package/dist/runtime/components/Edit/Features/Assistant/index.vue +18 -14
  76. package/dist/runtime/components/Edit/Features/BlockScheduler/Dialog/index.vue +11 -1
  77. package/dist/runtime/components/Edit/Features/BlockScheduler/index.vue +2 -2
  78. package/dist/runtime/components/Edit/Features/Clipboard/List/index.vue +1 -1
  79. package/dist/runtime/components/Edit/Features/Clipboard/index.vue +52 -18
  80. package/dist/runtime/components/Edit/Features/CommandPalette/Palette/Item/index.vue +0 -2
  81. package/dist/runtime/components/Edit/Features/CommandPalette/Palette/Item/index.vue.d.ts +6 -4
  82. package/dist/runtime/components/Edit/Features/CommandPalette/Palette/index.vue +77 -27
  83. package/dist/runtime/components/Edit/Features/CommandPalette/index.vue +7 -4
  84. package/dist/runtime/components/Edit/Features/Comments/index.vue +2 -2
  85. package/dist/runtime/components/Edit/Features/Debug/Main.vue.d.ts +1 -1
  86. package/dist/runtime/components/Edit/Features/Debug/Rects/index.vue +2 -2
  87. package/dist/runtime/components/Edit/Features/Debug/Section/Logging.vue.d.ts +1 -1
  88. package/dist/runtime/components/Edit/Features/DraggingOverlay/DragItems/DragItem.vue +113 -0
  89. package/dist/runtime/components/Edit/Features/DraggingOverlay/DragItems/DragItem.vue.d.ts +25 -0
  90. package/dist/runtime/components/Edit/Features/DraggingOverlay/DragItems/index.vue +8 -97
  91. package/dist/runtime/components/Edit/Features/DraggingOverlay/Renderer/fragment.glsl +2 -5
  92. package/dist/runtime/components/Edit/Features/DraggingOverlay/Renderer/index.vue +38 -5
  93. package/dist/runtime/components/Edit/Features/DraggingOverlay/Renderer/vertex.glsl +10 -1
  94. package/dist/runtime/components/Edit/Features/DraggingOverlay/index.vue +1 -2
  95. package/dist/runtime/components/Edit/Features/EditForm/Frame/index.vue +8 -2
  96. package/dist/runtime/components/Edit/Features/EditForm/index.vue +3 -9
  97. package/dist/runtime/components/Edit/Features/EditableField/Overlay/Plaintext/index.vue +1 -1
  98. package/dist/runtime/components/Edit/Features/EditableField/Overlay/index.vue +4 -3
  99. package/dist/runtime/components/Edit/Features/EditableField/index.vue +2 -2
  100. package/dist/runtime/components/Edit/Features/EditableMask/index.vue +1 -1
  101. package/dist/runtime/components/Edit/Features/EntityTitle/index.vue +7 -2
  102. package/dist/runtime/components/Edit/Features/Exit/index.vue +12 -9
  103. package/dist/runtime/components/Edit/Features/Fragments/index.vue +27 -31
  104. package/dist/runtime/components/Edit/Features/ImportExisting/Dialog/index.vue +1 -0
  105. package/dist/runtime/components/Edit/Features/ImportExisting/index.vue +25 -24
  106. package/dist/runtime/components/Edit/Features/Library/EditReusable/index.vue +4 -4
  107. package/dist/runtime/components/Edit/Features/Library/LibraryDialog/index.vue +9 -2
  108. package/dist/runtime/components/Edit/Features/Library/ReusableDialog/index.vue +13 -3
  109. package/dist/runtime/components/Edit/Features/Library/index.vue +26 -24
  110. package/dist/runtime/components/Edit/Features/MediaLibrary/Library/index.vue +3 -2
  111. package/dist/runtime/components/Edit/Features/MultiSelect/Renderer/index.vue +1 -3
  112. package/dist/runtime/components/Edit/Features/Options/Form/Item.vue.d.ts +1 -1
  113. package/dist/runtime/components/Edit/Features/PreviewGrant/index.vue +3 -1
  114. package/dist/runtime/components/Edit/Features/Publish/Dialog/index.vue +10 -0
  115. package/dist/runtime/components/Edit/Features/Publish/index.vue +17 -15
  116. package/dist/runtime/components/Edit/Features/ResponsivePreview/Frame/index.vue +3 -2
  117. package/dist/runtime/components/Edit/Features/ResponsivePreview/index.vue +3 -2
  118. package/dist/runtime/components/Edit/Features/Revert/index.vue +24 -18
  119. package/dist/runtime/components/Edit/Features/Search/Overlay/Results/Content/index.vue +8 -2
  120. package/dist/runtime/components/Edit/Features/Search/Overlay/Results/Page/index.vue +12 -2
  121. package/dist/runtime/components/Edit/Features/Search/Overlay/index.vue +11 -3
  122. package/dist/runtime/components/Edit/Features/Search/index.vue +1 -1
  123. package/dist/runtime/components/Edit/Features/Selection/AddButtons/Overlay/index.vue +128 -31
  124. package/dist/runtime/components/Edit/Features/Selection/AddButtons/Overlay/index.vue.d.ts +6 -6
  125. package/dist/runtime/components/Edit/Features/Selection/AddButtons/index.vue +3 -6
  126. package/dist/runtime/components/Edit/Features/Selection/Renderer/index.vue +1 -1
  127. package/dist/runtime/components/Edit/Features/Settings/Dialog/index.vue +1 -0
  128. package/dist/runtime/components/Edit/Features/Settings/index.vue +26 -18
  129. package/dist/runtime/components/Edit/Features/Structure/List/Field/index.vue +3 -3
  130. package/dist/runtime/components/Edit/Features/TouchActionBar/index.vue +2 -2
  131. package/dist/runtime/components/Edit/Features/Tour/Overlay/index.vue +3 -3
  132. package/dist/runtime/components/Edit/Features/Tour/Popup/index.vue +2 -2
  133. package/dist/runtime/components/Edit/Features/Tour/index.vue +12 -10
  134. package/dist/runtime/components/Edit/Features/Transform/Dialog/index.vue +7 -1
  135. package/dist/runtime/components/Edit/Features/Transform/index.vue +1 -1
  136. package/dist/runtime/components/Edit/Features/Translations/index.vue +18 -17
  137. package/dist/runtime/components/Edit/Form/Textarea/index.vue +1 -1
  138. package/dist/runtime/components/Edit/FormOverlay/index.vue +13 -4
  139. package/dist/runtime/components/Edit/Indicators/index.vue +1 -1
  140. package/dist/runtime/components/Edit/InfoBox/index.vue +3 -2
  141. package/dist/runtime/components/Edit/InfoBox/index.vue.d.ts +6 -1
  142. package/dist/runtime/components/Edit/ItemIconBox/index.vue +41 -0
  143. package/dist/runtime/components/Edit/{AddListItemIcon → ItemIconBox}/index.vue.d.ts +5 -5
  144. package/dist/runtime/components/Edit/Konami/Game/index.vue +0 -1
  145. package/dist/runtime/components/Edit/Konami/index.vue +3 -5
  146. package/dist/runtime/components/Edit/Messages/Item/index.vue +11 -2
  147. package/dist/runtime/components/Edit/Messages/index.vue +6 -1
  148. package/dist/runtime/components/Edit/Overlay/index.vue +70 -0
  149. package/dist/runtime/components/Edit/Overlay/index.vue.d.ts +2 -0
  150. package/dist/runtime/components/Edit/PreviewProvider.vue +3 -3
  151. package/dist/runtime/components/Edit/ScaleToFit/index.vue +4 -4
  152. package/dist/runtime/components/Edit/SystemRequirements/index.vue +36 -36
  153. package/dist/runtime/components/Edit/Toolbar/index.vue +47 -48
  154. package/dist/runtime/components/Edit/index.d.ts +2 -2
  155. package/dist/runtime/components/Edit/index.js +2 -2
  156. package/dist/runtime/composables/defineBlokkliFeature.d.ts +1 -1
  157. package/dist/runtime/composables/useBlokkli.d.ts +6 -1
  158. package/dist/runtime/composables/useBlokkli.js +4 -1
  159. package/dist/runtime/css/output.css +1 -1
  160. package/dist/runtime/helpers/composables/defineAddAction.d.ts +2 -0
  161. package/dist/runtime/helpers/composables/defineAddAction.js +10 -0
  162. package/dist/runtime/helpers/composables/defineElementStyle.d.ts +2 -0
  163. package/dist/runtime/helpers/composables/defineElementStyle.js +33 -0
  164. package/dist/runtime/helpers/composables/defineItemDropdownAction.d.ts +1 -1
  165. package/dist/runtime/helpers/composables/defineItemDropdownAction.js +2 -2
  166. package/dist/runtime/helpers/composables/defineMenuButton.d.ts +2 -0
  167. package/dist/runtime/helpers/composables/defineMenuButton.js +10 -0
  168. package/dist/runtime/helpers/composables/defineRenderer.d.ts +1 -1
  169. package/dist/runtime/helpers/composables/onBroadcastEvent.d.ts +1 -1
  170. package/dist/runtime/helpers/composables/useBlockRegistration.d.ts +1 -1
  171. package/dist/runtime/helpers/composables/useBlockRegistration.js +12 -1
  172. package/dist/runtime/helpers/composables/useDebugLogger.d.ts +1 -1
  173. package/dist/runtime/helpers/composables/useDialog.d.ts +3 -0
  174. package/dist/runtime/helpers/composables/useDialog.js +16 -0
  175. package/dist/runtime/helpers/composables/useFocusTrap.d.ts +52 -0
  176. package/dist/runtime/helpers/composables/useFocusTrap.js +59 -0
  177. package/dist/runtime/helpers/composables/useGlobalBlokkliObject.d.ts +1 -1
  178. package/dist/runtime/helpers/{useTransitionedValue.js → composables/useTransitionedValue.js} +1 -1
  179. package/dist/runtime/helpers/dropTargets/index.d.ts +1 -1
  180. package/dist/runtime/helpers/dropTargets/index.js +17 -3
  181. package/dist/runtime/helpers/imports/index.d.ts +2 -1
  182. package/dist/runtime/helpers/imports/index.js +10 -1
  183. package/dist/runtime/helpers/{animationProvider.d.ts → providers/animation.d.ts} +100 -7
  184. package/dist/runtime/helpers/{animationProvider.js → providers/animation.js} +21 -11
  185. package/dist/runtime/helpers/providers/blocks.d.ts +25 -3
  186. package/dist/runtime/helpers/providers/blocks.js +19 -0
  187. package/dist/runtime/helpers/providers/commands.d.ts +41 -0
  188. package/dist/runtime/helpers/{commandsProvider.js → providers/commands.js} +1 -1
  189. package/dist/runtime/helpers/providers/debug.d.ts +125 -0
  190. package/dist/runtime/helpers/{debugProvider.js → providers/debug.js} +2 -2
  191. package/dist/runtime/helpers/providers/definition.d.ts +87 -0
  192. package/dist/runtime/helpers/providers/directive.d.ts +88 -2
  193. package/dist/runtime/helpers/providers/directive.js +18 -2
  194. package/dist/runtime/helpers/providers/dom.d.ts +225 -0
  195. package/dist/runtime/helpers/{domProvider.js → providers/dom.js} +34 -76
  196. package/dist/runtime/helpers/providers/dropArea.d.ts +47 -0
  197. package/dist/runtime/helpers/{dropAreaProvider.js → providers/dropArea.js} +1 -1
  198. package/dist/runtime/helpers/providers/element.d.ts +58 -1
  199. package/dist/runtime/helpers/providers/features.d.ts +56 -0
  200. package/dist/runtime/helpers/{featuresProvider.js → providers/features.js} +1 -1
  201. package/dist/runtime/helpers/providers/fields.d.ts +19 -4
  202. package/dist/runtime/helpers/providers/fields.js +1 -1
  203. package/dist/runtime/helpers/providers/indicators.d.ts +44 -0
  204. package/dist/runtime/helpers/providers/keyboard.d.ts +76 -0
  205. package/dist/runtime/helpers/{keyboardProvider.js → providers/keyboard.js} +1 -8
  206. package/dist/runtime/helpers/providers/plugin.d.ts +81 -0
  207. package/dist/runtime/helpers/providers/plugin.js +64 -0
  208. package/dist/runtime/helpers/{selectionProvider.d.ts → providers/selection.d.ts} +4 -1
  209. package/dist/runtime/helpers/{selectionProvider.js → providers/selection.js} +1 -1
  210. package/dist/runtime/helpers/providers/state.d.ts +227 -0
  211. package/dist/runtime/helpers/{stateProvider.js → providers/state.js} +3 -3
  212. package/dist/runtime/helpers/providers/storage.d.ts +64 -0
  213. package/dist/runtime/helpers/{textProvider.d.ts → providers/texts.d.ts} +1 -1
  214. package/dist/runtime/helpers/providers/theme.d.ts +119 -0
  215. package/dist/runtime/helpers/{themeProvider.js → providers/theme.js} +3 -3
  216. package/dist/runtime/helpers/providers/tour.d.ts +49 -0
  217. package/dist/runtime/helpers/{tourProvider.js → providers/tour.js} +1 -1
  218. package/dist/runtime/helpers/providers/types.d.ts +170 -0
  219. package/dist/runtime/helpers/{typesProvider.js → providers/types.js} +45 -1
  220. package/dist/runtime/helpers/providers/ui.d.ts +339 -0
  221. package/dist/runtime/helpers/{uiProvider.js → providers/ui.js} +94 -86
  222. package/dist/runtime/helpers/runtimeHelpers/index.d.ts +1 -1
  223. package/dist/runtime/helpers/symbols.d.ts +1 -0
  224. package/dist/runtime/helpers/symbols.js +3 -0
  225. package/dist/runtime/icons/click.svg +1 -0
  226. package/dist/runtime/types/blockOptions.d.ts +349 -0
  227. package/dist/runtime/types/index.d.ts +34 -31
  228. package/package.json +2 -2
  229. package/dist/runtime/blokkliPlugins/AddAction/index.vue +0 -96
  230. package/dist/runtime/blokkliPlugins/AddAction/index.vue.d.ts +0 -26
  231. package/dist/runtime/blokkliPlugins/MenuButton/index.vue +0 -68
  232. package/dist/runtime/components/Edit/AddListItemIcon/index.vue +0 -19
  233. package/dist/runtime/helpers/commandsProvider.d.ts +0 -9
  234. package/dist/runtime/helpers/debugProvider.d.ts +0 -33
  235. package/dist/runtime/helpers/definitionProvider.d.ts +0 -19
  236. package/dist/runtime/helpers/domProvider.d.ts +0 -90
  237. package/dist/runtime/helpers/dropAreaProvider.d.ts +0 -9
  238. package/dist/runtime/helpers/featuresProvider.d.ts +0 -17
  239. package/dist/runtime/helpers/indicatorsProvider.d.ts +0 -10
  240. package/dist/runtime/helpers/keyboardProvider.d.ts +0 -20
  241. package/dist/runtime/helpers/pluginProvider.d.ts +0 -26
  242. package/dist/runtime/helpers/pluginProvider.js +0 -62
  243. package/dist/runtime/helpers/stateProvider.d.ts +0 -47
  244. package/dist/runtime/helpers/storageProvider.d.ts +0 -17
  245. package/dist/runtime/helpers/themeProvider.d.ts +0 -30
  246. package/dist/runtime/helpers/tourProvider.d.ts +0 -11
  247. package/dist/runtime/helpers/typesProvider.d.ts +0 -36
  248. package/dist/runtime/helpers/uiProvider.d.ts +0 -60
  249. package/dist/runtime/types/blokkOptions.d.ts +0 -100
  250. /package/dist/runtime/helpers/{addElementClasses.d.ts → composables/addElementClasses.d.ts} +0 -0
  251. /package/dist/runtime/helpers/{addElementClasses.js → composables/addElementClasses.js} +0 -0
  252. /package/dist/runtime/helpers/{useTransitionedValue.d.ts → composables/useTransitionedValue.d.ts} +0 -0
  253. /package/dist/runtime/helpers/{broadcastProvider.d.ts → providers/broadcast.d.ts} +0 -0
  254. /package/dist/runtime/helpers/{broadcastProvider.js → providers/broadcast.js} +0 -0
  255. /package/dist/runtime/helpers/{definitionProvider.js → providers/definition.js} +0 -0
  256. /package/dist/runtime/helpers/{indicatorsProvider.js → providers/indicators.js} +0 -0
  257. /package/dist/runtime/helpers/{storageProvider.js → providers/storage.js} +0 -0
  258. /package/dist/runtime/helpers/{textProvider.js → providers/texts.js} +0 -0
  259. /package/dist/runtime/types/{blokkOptions.js → blockOptions.js} +0 -0
@@ -1,17 +1,55 @@
1
1
  import type { BlokkliIcon } from '#blokkli-build/icons';
2
2
  declare const _default: __VLS_WithSlots<import("vue").DefineComponent<{
3
+ /**
4
+ * Unique identifier for this indicator.
5
+ *
6
+ * Should be unique per block instance.
7
+ */
3
8
  id: string;
9
+ /**
10
+ * The UUID of the block this indicator is attached to.
11
+ */
4
12
  uuid: string;
13
+ /**
14
+ * Optional text label to display in the indicator.
15
+ */
5
16
  label?: string;
17
+ /**
18
+ * Which side of the block to display the indicator.
19
+ *
20
+ * @default 'left'
21
+ */
6
22
  position?: "left" | "right";
23
+ /**
24
+ * Optional icon to display in the indicator.
25
+ */
7
26
  icon?: BlokkliIcon;
8
27
  }, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
9
28
  click: () => any;
10
29
  }, string, import("vue").PublicProps, Readonly<{
30
+ /**
31
+ * Unique identifier for this indicator.
32
+ *
33
+ * Should be unique per block instance.
34
+ */
11
35
  id: string;
36
+ /**
37
+ * The UUID of the block this indicator is attached to.
38
+ */
12
39
  uuid: string;
40
+ /**
41
+ * Optional text label to display in the indicator.
42
+ */
13
43
  label?: string;
44
+ /**
45
+ * Which side of the block to display the indicator.
46
+ *
47
+ * @default 'left'
48
+ */
14
49
  position?: "left" | "right";
50
+ /**
51
+ * Optional icon to display in the indicator.
52
+ */
15
53
  icon?: BlokkliIcon;
16
54
  }> & Readonly<{
17
55
  onClick?: (() => any) | undefined;
@@ -1,7 +1,7 @@
1
1
  <template>
2
2
  <Component :is="tag" @contextmenu.stop.prevent="onContextMenu">
3
3
  <slot />
4
- <Teleport to="body">
4
+ <Teleport :to="ui.mainLayoutElement.value">
5
5
  <BlokkliTransition name="context-menu">
6
6
  <ContextMenuMenu
7
7
  v-if="isVisible"
@@ -1,7 +1,22 @@
1
1
  import type { ContextMenu } from '#blokkli/types';
2
2
  type __VLS_Props = {
3
+ /**
4
+ * Unique identifier for this context menu.
5
+ *
6
+ * Used to track which menu is currently open.
7
+ */
3
8
  id: string;
9
+ /**
10
+ * Array of menu items to display.
11
+ *
12
+ * Each item can have nested sub-menus.
13
+ */
4
14
  menu: ContextMenu[];
15
+ /**
16
+ * The HTML tag to use for the wrapper element.
17
+ *
18
+ * @default 'div'
19
+ */
5
20
  tag?: string;
6
21
  };
7
22
  declare var __VLS_10: {};
@@ -1,5 +1,11 @@
1
1
  type __VLS_Props = {
2
+ /**
3
+ * Unique identifier for this debug overlay.
4
+ */
2
5
  id: string;
6
+ /**
7
+ * The title displayed in the debug overlay selector.
8
+ */
3
9
  title: string;
4
10
  };
5
11
  declare var __VLS_5: {};
@@ -1,9 +1,14 @@
1
1
  import type { BlokkliIcon } from '#blokkli-build/icons';
2
2
  import type { RenderedFieldListItem } from '#blokkli/types';
3
3
  type __VLS_Props = {
4
+ /**
5
+ * Unique identifier for this item action.
6
+ */
4
7
  id: string;
5
8
  /**
6
9
  * The title of the action.
10
+ *
11
+ * Displayed in the tooltip and keyboard shortcut hints.
7
12
  */
8
13
  title: string;
9
14
  /**
@@ -11,30 +16,50 @@ type __VLS_Props = {
11
16
  */
12
17
  disabled?: boolean;
13
18
  /**
14
- * Whether the button should be displayed in an active state (e.g. when it's a dropdown).
19
+ * Whether the button should be displayed in an active state.
20
+ *
21
+ * Useful when the action opens a dropdown or dialog.
15
22
  */
16
23
  active?: boolean;
17
24
  /**
18
- * The key code to use for the shortcut.
25
+ * The key code to use for the keyboard shortcut.
26
+ *
27
+ * @example 'c' for the "c" key
19
28
  */
20
29
  keyCode?: string;
21
30
  /**
22
- * Wheter the shortcut needs the meta modifier key.
31
+ * Whether the shortcut needs the meta modifier key.
32
+ *
33
+ * On Mac this is Cmd, on Windows/Linux this is Ctrl.
23
34
  */
24
35
  meta?: boolean;
25
36
  /**
26
37
  * Whether the action supports multiple items.
38
+ *
39
+ * If false, the action is disabled when more than one item is selected.
27
40
  */
28
41
  multiple?: boolean;
29
42
  /**
30
43
  * Whether the action is only available in edit mode.
44
+ *
45
+ * If true, the action is hidden in preview mode.
31
46
  */
32
47
  editOnly?: boolean;
33
48
  /**
34
49
  * The weight, used for positioning the button.
50
+ *
51
+ * Lower weights appear first. Use 'last' to always position at the end.
35
52
  */
36
53
  weight?: number | string | 'last';
54
+ /**
55
+ * Optional icon to display in the button.
56
+ */
37
57
  icon?: BlokkliIcon;
58
+ /**
59
+ * Optional text for the interactive tour.
60
+ *
61
+ * If provided, this action will be included in the editor tour.
62
+ */
38
63
  tourText?: string;
39
64
  };
40
65
  declare var __VLS_5: {}, __VLS_19: {
@@ -15,9 +15,11 @@
15
15
  class="bk-sidebar-title"
16
16
  @mousedown.stop="onMouseDown($event, 'move')"
17
17
  >
18
- <slot name="icon">
19
- <Icon v-if="icon" :name="icon" />
20
- </slot>
18
+ <div class="bk-sidebar-title-icon">
19
+ <slot name="icon">
20
+ <Icon v-if="icon" :name="icon" />
21
+ </slot>
22
+ </div>
21
23
  <span>{{ title }}</span>
22
24
  <button
23
25
  @click.prevent.stop.capture="isMinimized = !isMinimized"
@@ -70,7 +72,7 @@ import {
70
72
  } from "#imports";
71
73
  import { Icon, ViewportBlockingRect, ScrollBoundary } from "#blokkli/components";
72
74
  import onBlokkliEvent from "#blokkli/helpers/composables/onBlokkliEvent";
73
- import { addElementClasses } from "#blokkli/helpers/addElementClasses";
75
+ import { addElementClasses } from "#blokkli/helpers/composables/addElementClasses";
74
76
  const props = defineProps({
75
77
  id: { type: String, required: true },
76
78
  title: { type: String, required: true },
@@ -53,6 +53,7 @@
53
53
  </template>
54
54
  <template #default="{ width, height, isResizing }">
55
55
  <div class="bk-sidebar-content-wrapper">
56
+ <Loading v-if="isLoading" white />
56
57
  <div ref="sidebarContent" class="bk-sidebar-content">
57
58
  <slot
58
59
  :key="isRenderedDetached ? 'detached' : 'attached'"
@@ -85,6 +86,7 @@
85
86
  </div>
86
87
  </div>
87
88
  <div class="bk-sidebar-content-wrapper">
89
+ <Loading v-if="isLoading" white />
88
90
  <div ref="sidebarContent" class="bk-sidebar-content">
89
91
  <slot
90
92
  :key="isRenderedDetached ? 'detached' : 'attached'"
@@ -110,7 +112,12 @@ import {
110
112
  onBeforeUnmount,
111
113
  useTemplateRef
112
114
  } from "#imports";
113
- import { Icon, ShortcutIndicator, ScrollBoundary } from "#blokkli/components";
115
+ import {
116
+ Icon,
117
+ ShortcutIndicator,
118
+ ScrollBoundary,
119
+ Loading
120
+ } from "#blokkli/components";
114
121
  import SidebarDetached from "./Detached/index.vue";
115
122
  import defineCommands from "#blokkli/helpers/composables/defineCommands";
116
123
  import onBlokkliEvent from "#blokkli/helpers/composables/onBlokkliEvent";
@@ -122,7 +129,7 @@ const props = defineProps({
122
129
  tourText: { type: String, required: false, default: void 0 },
123
130
  editOnly: { type: Boolean, required: false },
124
131
  icon: { type: null, required: true },
125
- weight: { type: [String, Number], required: false, default: 0 },
132
+ weight: { type: [String, Number], required: true },
126
133
  renderAlways: { type: Boolean, required: false },
127
134
  disabled: { type: Boolean, required: false },
128
135
  region: { type: String, required: false, default: "right" },
@@ -132,7 +139,8 @@ const props = defineProps({
132
139
  meta: { type: Boolean, required: false },
133
140
  shift: { type: Boolean, required: false },
134
141
  keyCode: { type: String, required: false, default: void 0 },
135
- beta: { type: Boolean, required: false }
142
+ beta: { type: Boolean, required: false },
143
+ isLoading: { type: Boolean, required: false }
136
144
  });
137
145
  const emit = defineEmits(["updated"]);
138
146
  const { storage, state, ui, $t } = useBlokkli();
@@ -1,49 +1,185 @@
1
1
  import type { BlokkliIcon } from '#blokkli-build/icons';
2
2
  import type { SidebarRegion } from '#blokkli/types';
3
3
  declare const _default: __VLS_WithSlots<import("vue").DefineComponent<{
4
+ /**
5
+ * Unique identifier for this sidebar.
6
+ */
4
7
  id: string;
8
+ /**
9
+ * The title displayed in the sidebar header.
10
+ */
5
11
  title: string;
12
+ /**
13
+ * Optional text for the interactive tour.
14
+ *
15
+ * If provided, this sidebar will be included in the editor tour.
16
+ */
6
17
  tourText?: string;
18
+ /**
19
+ * Whether the sidebar is only available in edit mode.
20
+ *
21
+ * If true, the sidebar is hidden in preview mode.
22
+ */
7
23
  editOnly?: boolean;
24
+ /**
25
+ * The icon displayed in the sidebar toggle button.
26
+ */
8
27
  icon: BlokkliIcon;
9
- weight?: string | number;
28
+ /**
29
+ * The weight, used for positioning the sidebar button.
30
+ *
31
+ * Lower weights appear first.
32
+ */
33
+ weight: string | number;
34
+ /**
35
+ * Whether to always render the sidebar content.
36
+ *
37
+ * By default, content is only rendered when the sidebar is open.
38
+ */
10
39
  renderAlways?: boolean;
40
+ /**
41
+ * Whether the sidebar is disabled.
42
+ */
11
43
  disabled?: boolean;
44
+ /**
45
+ * Which region to display the sidebar in.
46
+ *
47
+ * @default 'right'
48
+ */
12
49
  region?: SidebarRegion;
50
+ /**
51
+ * Minimum width when detached (in pixels).
52
+ */
13
53
  minWidth?: number;
54
+ /**
55
+ * Minimum height when detached (in pixels).
56
+ */
14
57
  minHeight?: number;
58
+ /**
59
+ * Default size when detached.
60
+ */
15
61
  size?: {
16
62
  width: number;
17
63
  height: number;
18
64
  };
65
+ /**
66
+ * Whether the keyboard shortcut needs the meta modifier key.
67
+ *
68
+ * On Mac this is Cmd, on Windows/Linux this is Ctrl.
69
+ */
19
70
  meta?: boolean;
71
+ /**
72
+ * Whether the keyboard shortcut needs the shift modifier key.
73
+ */
20
74
  shift?: boolean;
75
+ /**
76
+ * The key code to use for the keyboard shortcut.
77
+ *
78
+ * @example 'l' for the "l" key
79
+ */
21
80
  keyCode?: string;
81
+ /**
82
+ * Whether to display a BETA indicator badge.
83
+ */
22
84
  beta?: boolean;
85
+ /**
86
+ * Whether the sidebar content is currently loading.
87
+ *
88
+ * Displays a loading spinner when true.
89
+ */
90
+ isLoading?: boolean;
23
91
  }, {
24
92
  showSidebar: () => void;
25
93
  }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
26
94
  updated: () => any;
27
95
  }, string, import("vue").PublicProps, Readonly<{
96
+ /**
97
+ * Unique identifier for this sidebar.
98
+ */
28
99
  id: string;
100
+ /**
101
+ * The title displayed in the sidebar header.
102
+ */
29
103
  title: string;
104
+ /**
105
+ * Optional text for the interactive tour.
106
+ *
107
+ * If provided, this sidebar will be included in the editor tour.
108
+ */
30
109
  tourText?: string;
110
+ /**
111
+ * Whether the sidebar is only available in edit mode.
112
+ *
113
+ * If true, the sidebar is hidden in preview mode.
114
+ */
31
115
  editOnly?: boolean;
116
+ /**
117
+ * The icon displayed in the sidebar toggle button.
118
+ */
32
119
  icon: BlokkliIcon;
33
- weight?: string | number;
120
+ /**
121
+ * The weight, used for positioning the sidebar button.
122
+ *
123
+ * Lower weights appear first.
124
+ */
125
+ weight: string | number;
126
+ /**
127
+ * Whether to always render the sidebar content.
128
+ *
129
+ * By default, content is only rendered when the sidebar is open.
130
+ */
34
131
  renderAlways?: boolean;
132
+ /**
133
+ * Whether the sidebar is disabled.
134
+ */
35
135
  disabled?: boolean;
136
+ /**
137
+ * Which region to display the sidebar in.
138
+ *
139
+ * @default 'right'
140
+ */
36
141
  region?: SidebarRegion;
142
+ /**
143
+ * Minimum width when detached (in pixels).
144
+ */
37
145
  minWidth?: number;
146
+ /**
147
+ * Minimum height when detached (in pixels).
148
+ */
38
149
  minHeight?: number;
150
+ /**
151
+ * Default size when detached.
152
+ */
39
153
  size?: {
40
154
  width: number;
41
155
  height: number;
42
156
  };
157
+ /**
158
+ * Whether the keyboard shortcut needs the meta modifier key.
159
+ *
160
+ * On Mac this is Cmd, on Windows/Linux this is Ctrl.
161
+ */
43
162
  meta?: boolean;
163
+ /**
164
+ * Whether the keyboard shortcut needs the shift modifier key.
165
+ */
44
166
  shift?: boolean;
167
+ /**
168
+ * The key code to use for the keyboard shortcut.
169
+ *
170
+ * @example 'l' for the "l" key
171
+ */
45
172
  keyCode?: string;
173
+ /**
174
+ * Whether to display a BETA indicator badge.
175
+ */
46
176
  beta?: boolean;
177
+ /**
178
+ * Whether the sidebar content is currently loading.
179
+ *
180
+ * Displays a loading spinner when true.
181
+ */
182
+ isLoading?: boolean;
47
183
  }> & Readonly<{
48
184
  onUpdated?: (() => any) | undefined;
49
185
  }>, {
@@ -51,7 +187,6 @@ declare const _default: __VLS_WithSlots<import("vue").DefineComponent<{
51
187
  width: number;
52
188
  height: number;
53
189
  };
54
- weight: string | number;
55
190
  keyCode: string;
56
191
  tourText: string;
57
192
  minWidth: number;
@@ -45,7 +45,8 @@ const props = defineProps({
45
45
  icon: { type: null, required: false },
46
46
  shortcutGroup: { type: String, required: false },
47
47
  tourText: { type: String, required: false },
48
- weight: { type: [Number, String], required: false }
48
+ weight: { type: [Number, String], required: false },
49
+ noCommand: { type: Boolean, required: false }
49
50
  });
50
51
  const { debug } = useBlokkli();
51
52
  const logger = debug.createLogger("PluginToolbar");
@@ -59,6 +60,9 @@ function onClick() {
59
60
  emit("click");
60
61
  }
61
62
  defineCommands(() => {
63
+ if (props.noCommand) {
64
+ return;
65
+ }
62
66
  return {
63
67
  id: "plugin:toolbar_button:" + props.id,
64
68
  label: props.title,
@@ -1,40 +1,156 @@
1
1
  import type { BlokkliIcon } from '#blokkli-build/icons';
2
2
  declare const _default: __VLS_WithSlots<import("vue").DefineComponent<{
3
+ /**
4
+ * Unique identifier for this toolbar button.
5
+ */
3
6
  id: string;
7
+ /**
8
+ * The title displayed in the tooltip.
9
+ */
4
10
  title: string;
11
+ /**
12
+ * Which toolbar region to render the button in.
13
+ *
14
+ * Different regions appear in different locations of the toolbar.
15
+ */
5
16
  region: "after-title" | "before-title" | "before-sidebar" | "after-menu" | "before-sidebar-right" | "view-options";
17
+ /**
18
+ * Whether the button is only available in edit mode.
19
+ *
20
+ * If true, the button is hidden in preview mode.
21
+ */
6
22
  editOnly?: boolean;
23
+ /**
24
+ * Whether the button is disabled.
25
+ */
7
26
  disabled?: boolean;
27
+ /**
28
+ * Whether the button should be displayed in an active state.
29
+ *
30
+ * Useful when the button opens a dropdown or toggles a feature.
31
+ */
8
32
  active?: boolean;
33
+ /**
34
+ * Whether the keyboard shortcut needs the meta modifier key.
35
+ *
36
+ * On Mac this is Cmd, on Windows/Linux this is Ctrl.
37
+ */
9
38
  meta?: boolean;
39
+ /**
40
+ * Whether the keyboard shortcut needs the shift modifier key.
41
+ */
10
42
  shift?: boolean;
43
+ /**
44
+ * The key code to use for the keyboard shortcut.
45
+ *
46
+ * @example 'h' for the "h" key
47
+ */
11
48
  keyCode?: string;
49
+ /**
50
+ * Optional icon to display in the button.
51
+ */
12
52
  icon?: BlokkliIcon;
53
+ /**
54
+ * The keyboard shortcut group.
55
+ *
56
+ * Used for organizing shortcuts in the shortcuts panel.
57
+ */
13
58
  shortcutGroup?: string;
59
+ /**
60
+ * Optional text for the interactive tour.
61
+ *
62
+ * If provided, this button will be included in the editor tour.
63
+ */
14
64
  tourText?: string;
15
65
  /**
16
66
  * The weight, used for positioning the button.
67
+ *
68
+ * Lower weights appear first.
17
69
  */
18
70
  weight?: number | string;
71
+ /**
72
+ * Whether to skip registering this button as a command.
73
+ *
74
+ * Useful when you want the button UI without command palette integration.
75
+ */
76
+ noCommand?: boolean;
19
77
  }, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
20
78
  click: (...args: any[]) => void;
21
79
  }, string, import("vue").PublicProps, Readonly<{
80
+ /**
81
+ * Unique identifier for this toolbar button.
82
+ */
22
83
  id: string;
84
+ /**
85
+ * The title displayed in the tooltip.
86
+ */
23
87
  title: string;
88
+ /**
89
+ * Which toolbar region to render the button in.
90
+ *
91
+ * Different regions appear in different locations of the toolbar.
92
+ */
24
93
  region: "after-title" | "before-title" | "before-sidebar" | "after-menu" | "before-sidebar-right" | "view-options";
94
+ /**
95
+ * Whether the button is only available in edit mode.
96
+ *
97
+ * If true, the button is hidden in preview mode.
98
+ */
25
99
  editOnly?: boolean;
100
+ /**
101
+ * Whether the button is disabled.
102
+ */
26
103
  disabled?: boolean;
104
+ /**
105
+ * Whether the button should be displayed in an active state.
106
+ *
107
+ * Useful when the button opens a dropdown or toggles a feature.
108
+ */
27
109
  active?: boolean;
110
+ /**
111
+ * Whether the keyboard shortcut needs the meta modifier key.
112
+ *
113
+ * On Mac this is Cmd, on Windows/Linux this is Ctrl.
114
+ */
28
115
  meta?: boolean;
116
+ /**
117
+ * Whether the keyboard shortcut needs the shift modifier key.
118
+ */
29
119
  shift?: boolean;
120
+ /**
121
+ * The key code to use for the keyboard shortcut.
122
+ *
123
+ * @example 'h' for the "h" key
124
+ */
30
125
  keyCode?: string;
126
+ /**
127
+ * Optional icon to display in the button.
128
+ */
31
129
  icon?: BlokkliIcon;
130
+ /**
131
+ * The keyboard shortcut group.
132
+ *
133
+ * Used for organizing shortcuts in the shortcuts panel.
134
+ */
32
135
  shortcutGroup?: string;
136
+ /**
137
+ * Optional text for the interactive tour.
138
+ *
139
+ * If provided, this button will be included in the editor tour.
140
+ */
33
141
  tourText?: string;
34
142
  /**
35
143
  * The weight, used for positioning the button.
144
+ *
145
+ * Lower weights appear first.
36
146
  */
37
147
  weight?: number | string;
148
+ /**
149
+ * Whether to skip registering this button as a command.
150
+ *
151
+ * Useful when you want the button UI without command palette integration.
152
+ */
153
+ noCommand?: boolean;
38
154
  }> & Readonly<{
39
155
  onClick?: ((...args: any[]) => any) | undefined;
40
156
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, {
@@ -9,32 +9,41 @@ const props = defineProps({
9
9
  id: { type: String, required: true },
10
10
  title: { type: String, required: true },
11
11
  text: { type: String, required: true },
12
- selector: { type: String, required: false }
12
+ selector: { type: String, required: false },
13
+ element: { type: null, required: false }
13
14
  });
14
- const { element } = useBlokkli();
15
- const findElement = (el) => {
15
+ const { element: elementProvider } = useBlokkli();
16
+ const findInstanceElement = (el) => {
16
17
  if (el instanceof Text) {
17
- return findElement(el.nextElementSibling);
18
+ return findInstanceElement(el.nextElementSibling);
18
19
  } else if (el instanceof HTMLElement) {
19
20
  return el;
20
21
  }
21
22
  };
22
23
  const instance = getCurrentInstance();
24
+ function getElement() {
25
+ if (props.element) {
26
+ return props.element;
27
+ }
28
+ if (props.selector) {
29
+ const match = elementProvider.query(
30
+ document.documentElement,
31
+ props.selector,
32
+ `TourItem Plugin: ${props.id}`
33
+ );
34
+ if (match) {
35
+ return match;
36
+ }
37
+ }
38
+ return findInstanceElement(instance?.vnode.el);
39
+ }
23
40
  defineTourItem(() => {
24
41
  return {
25
42
  id: props.id,
26
43
  title: props.title,
27
44
  text: props.text,
28
45
  element: () => {
29
- const provided = props.selector ? element.query(
30
- document.documentElement,
31
- props.selector,
32
- `TourItem Plugin: ${props.id}`
33
- ) : void 0;
34
- const el = provided || findElement(instance?.vnode.el);
35
- if (el instanceof HTMLElement) {
36
- return el;
37
- }
46
+ return getElement();
38
47
  }
39
48
  };
40
49
  });