@wix/ricos 11.22.0 → 11.23.0

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 (1142) hide show
  1. package/css/all-plugins-viewer.css +176 -176
  2. package/css/plugin-audio-viewer.global.css +3 -3
  3. package/css/plugin-audio-viewer.global.inject.mjs +4 -4
  4. package/css/plugin-button-viewer.global.css +1 -1
  5. package/css/plugin-button-viewer.global.inject.mjs +2 -2
  6. package/css/plugin-card-viewer.global.css +1 -1
  7. package/css/plugin-card-viewer.global.inject.mjs +2 -2
  8. package/css/plugin-collapsible-list-viewer.global.css +1 -1
  9. package/css/plugin-collapsible-list-viewer.global.inject.mjs +2 -2
  10. package/css/plugin-divider-viewer.global.css +1 -1
  11. package/css/plugin-divider-viewer.global.inject.mjs +2 -2
  12. package/css/plugin-file-upload-viewer.global.css +1 -1
  13. package/css/plugin-file-upload-viewer.global.inject.mjs +2 -2
  14. package/css/plugin-gallery-viewer.global.css +1 -1
  15. package/css/plugin-gallery-viewer.global.inject.mjs +2 -2
  16. package/css/plugin-giphy-viewer.global.css +1 -1
  17. package/css/plugin-giphy-viewer.global.inject.mjs +2 -2
  18. package/css/plugin-hashtag-viewer.global.css +1 -1
  19. package/css/plugin-hashtag-viewer.global.inject.mjs +2 -2
  20. package/css/plugin-html-viewer.global.css +1 -1
  21. package/css/plugin-html-viewer.global.inject.mjs +2 -2
  22. package/css/plugin-image-viewer.global.css +1 -1
  23. package/css/plugin-image-viewer.global.inject.mjs +2 -2
  24. package/css/plugin-link-preview-viewer.global.css +2 -2
  25. package/css/plugin-link-preview-viewer.global.inject.mjs +3 -3
  26. package/css/plugin-link-viewer.global.css +1 -1
  27. package/css/plugin-link-viewer.global.inject.mjs +2 -2
  28. package/css/plugin-mentions-viewer.global.css +1 -1
  29. package/css/plugin-mentions-viewer.global.inject.mjs +2 -2
  30. package/css/plugin-paywall-viewer.global.css +1 -1
  31. package/css/plugin-paywall-viewer.global.inject.mjs +2 -2
  32. package/css/plugin-smart-block-viewer.global.css +1 -1
  33. package/css/plugin-smart-block-viewer.global.inject.mjs +2 -2
  34. package/css/plugin-social-polls-viewer.global.css +1 -1
  35. package/css/plugin-social-polls-viewer.global.inject.mjs +2 -2
  36. package/css/plugin-spoiler-viewer.global.css +1 -1
  37. package/css/plugin-spoiler-viewer.global.inject.mjs +2 -2
  38. package/css/plugin-table-viewer.global.css +3 -3
  39. package/css/plugin-table-viewer.global.inject.mjs +4 -4
  40. package/css/plugin-toc-viewer.global.css +1 -1
  41. package/css/plugin-toc-viewer.global.inject.mjs +2 -2
  42. package/css/plugin-vertical-embed-viewer.global.css +2 -2
  43. package/css/plugin-vertical-embed-viewer.global.inject.mjs +3 -3
  44. package/css/plugin-video-viewer.global.css +1 -1
  45. package/css/plugin-video-viewer.global.inject.mjs +2 -2
  46. package/css/ricos-viewer.global.css +1 -1
  47. package/css/ricos-viewer.global.inject.mjs +2 -2
  48. package/dist/cjs/_shared/dropdown-modal/dropdown-modal-scss.js +2 -2
  49. package/dist/cjs/_shared/dropdown-modal/dropdown-modal-scss.js.map +1 -1
  50. package/dist/cjs/_shared/editor-base-url/editor-base-url-context.js +14 -13
  51. package/dist/cjs/_shared/editor-base-url/editor-base-url-context.js.map +3 -3
  52. package/dist/cjs/_shared/figure/add-caption-button-scss.js +9 -9
  53. package/dist/cjs/_shared/figure/add-caption-button-scss.js.map +1 -1
  54. package/dist/cjs/_shared/figure/viewer-caption-scss.js +2 -2
  55. package/dist/cjs/_shared/figure/viewer-caption-scss.js.map +1 -1
  56. package/dist/cjs/_shared/figure/viewer-figure-scss.js +1 -1
  57. package/dist/cjs/_shared/figure/viewer-figure-scss.js.map +1 -1
  58. package/dist/cjs/_shared/font-weight.js +27 -0
  59. package/dist/cjs/_shared/font-weight.js.map +7 -0
  60. package/dist/cjs/_shared/get-common-marker-style.js +35 -0
  61. package/dist/cjs/_shared/get-common-marker-style.js.map +7 -0
  62. package/dist/cjs/_shared/get-decorations-marker-style.js +58 -0
  63. package/dist/cjs/_shared/get-decorations-marker-style.js.map +7 -0
  64. package/dist/cjs/_shared/get-list-marker-style.js +43 -0
  65. package/dist/cjs/_shared/get-list-marker-style.js.map +7 -0
  66. package/dist/cjs/_shared/link-modal/open-link-modal/site-pages/site-pages.js +2 -4
  67. package/dist/cjs/_shared/link-modal/open-link-modal/site-pages/site-pages.js.map +2 -2
  68. package/dist/cjs/_shared/list-item-divider/list-item-divider-scss.js +1 -1
  69. package/dist/cjs/_shared/list-item-divider/list-item-divider-scss.js.map +1 -1
  70. package/dist/cjs/_shared/list-item-select/list-item-select-scss.js +2 -2
  71. package/dist/cjs/_shared/list-item-select/list-item-select-scss.js.map +1 -1
  72. package/dist/cjs/_shared/list-item-toggle/list-item-toggle-scss.js +3 -3
  73. package/dist/cjs/_shared/list-item-toggle/list-item-toggle-scss.js.map +1 -1
  74. package/dist/cjs/_shared/{site-pages/serverless-types/serverless-types.js → list-marker-style-scss.js} +11 -3
  75. package/dist/cjs/_shared/list-marker-style-scss.js.map +7 -0
  76. package/dist/cjs/_shared/overlay-hoc/overlay-hoc-scss.js +1 -1
  77. package/dist/cjs/_shared/overlay-hoc/overlay-hoc-scss.js.map +1 -1
  78. package/dist/cjs/_shared/plugin-toolbar/create-settings-button.js +7 -1
  79. package/dist/cjs/_shared/plugin-toolbar/create-settings-button.js.map +2 -2
  80. package/dist/cjs/_shared/plugin-toolbar/separator/toolbar-button-separator-scss.js +2 -2
  81. package/dist/cjs/_shared/plugin-toolbar/separator/toolbar-button-separator-scss.js.map +1 -1
  82. package/dist/cjs/_shared/plugin-toolbar/url-link-button/url-link-button-scss.js +2 -2
  83. package/dist/cjs/_shared/plugin-toolbar/url-link-button/url-link-button-scss.js.map +1 -1
  84. package/dist/cjs/_shared/pm-node-types.js.map +2 -2
  85. package/dist/cjs/_shared/prompt-input-area/attachment-bar/attachment-bar-scss.js +7 -7
  86. package/dist/cjs/_shared/prompt-input-area/attachment-bar/attachment-bar-scss.js.map +1 -1
  87. package/dist/cjs/_shared/prompt-input-area/prompt-input-area-scss.js +13 -13
  88. package/dist/cjs/_shared/prompt-input-area/prompt-input-area-scss.js.map +1 -1
  89. package/dist/cjs/_shared/prompt-input-area/widget-prompt-input-area-scss.js +8 -8
  90. package/dist/cjs/_shared/prompt-input-area/widget-prompt-input-area-scss.js.map +1 -1
  91. package/dist/cjs/_shared/shape-select-modal/shape-select-modal-content-scss.js +7 -7
  92. package/dist/cjs/_shared/shape-select-modal/shape-select-modal-content-scss.js.map +1 -1
  93. package/dist/cjs/_shared/shape-view-renderer/shape-view-renderer-scss.js +2 -2
  94. package/dist/cjs/_shared/shape-view-renderer/shape-view-renderer-scss.js.map +1 -1
  95. package/dist/cjs/_shared/site-pages/site-pages-fetch-context/use-fetch-site-pages.js +93 -27
  96. package/dist/cjs/_shared/site-pages/site-pages-fetch-context/use-fetch-site-pages.js.map +3 -3
  97. package/dist/cjs/_shared/site-pages/site-pages-fetch-context.js +2 -6
  98. package/dist/cjs/_shared/site-pages/site-pages-fetch-context.js.map +2 -2
  99. package/dist/cjs/_shared/site-pages/types.js.map +2 -2
  100. package/dist/cjs/_shared/toolbar-button/toolbar-button-scss.js +3 -3
  101. package/dist/cjs/_shared/toolbar-button/toolbar-button-scss.js.map +1 -1
  102. package/dist/cjs/bundled-dependencies/ai-assistant-avatar.js +4 -4
  103. package/dist/cjs/bundled-dependencies/ai-assistant-avatar.js.map +1 -1
  104. package/dist/cjs/editor-common/statics/styles/general-scss.js +18 -18
  105. package/dist/cjs/editor-common/statics/styles/general-scss.js.map +1 -1
  106. package/dist/cjs/index.js.map +2 -2
  107. package/dist/cjs/internal.js.map +2 -2
  108. package/dist/cjs/legacy.js.map +2 -2
  109. package/dist/cjs/plugin-ai/ai-content-modal/ai-content-modal-scss.js +8 -8
  110. package/dist/cjs/plugin-ai/ai-content-modal/ai-content-modal-scss.js.map +1 -1
  111. package/dist/cjs/plugin-ai/ai-content-modal/feed/feed-scss.js +2 -2
  112. package/dist/cjs/plugin-ai/ai-content-modal/feed/feed-scss.js.map +1 -1
  113. package/dist/cjs/plugin-ai/ai-content-modal/no-selection-message/no-selection-message-scss.js +1 -1
  114. package/dist/cjs/plugin-ai/ai-content-modal/no-selection-message/no-selection-message-scss.js.map +1 -1
  115. package/dist/cjs/plugin-ai/ai-content-modal/text-cursor/text-cursor-scss.js +2 -2
  116. package/dist/cjs/plugin-ai/ai-content-modal/text-cursor/text-cursor-scss.js.map +1 -1
  117. package/dist/cjs/plugin-ai/ai-content-modal/textual-prompt-input-area/textual-prompt-input-area-scss.js +5 -5
  118. package/dist/cjs/plugin-ai/ai-content-modal/textual-prompt-input-area/textual-prompt-input-area-scss.js.map +1 -1
  119. package/dist/cjs/plugin-ai/ai-image-modal/ai-image-modal-scss.js +6 -6
  120. package/dist/cjs/plugin-ai/ai-image-modal/ai-image-modal-scss.js.map +1 -1
  121. package/dist/cjs/plugin-ai/ai-plus-button/ai-plus-button-scss.js +1 -1
  122. package/dist/cjs/plugin-ai/ai-plus-button/ai-plus-button-scss.js.map +1 -1
  123. package/dist/cjs/plugin-ai/error-message/error-message-scss.js +1 -1
  124. package/dist/cjs/plugin-ai/error-message/error-message-scss.js.map +1 -1
  125. package/dist/cjs/plugin-ai/prompt-input-area/prompt-input-area-scss.js +4 -4
  126. package/dist/cjs/plugin-ai/prompt-input-area/prompt-input-area-scss.js.map +1 -1
  127. package/dist/cjs/plugin-ai/toolbar/toolbar-button-scss.js +2 -2
  128. package/dist/cjs/plugin-ai/toolbar/toolbar-button-scss.js.map +1 -1
  129. package/dist/cjs/plugin-animation/animation-panel-scss.js +9 -9
  130. package/dist/cjs/plugin-animation/animation-panel-scss.js.map +1 -1
  131. package/dist/cjs/plugin-audio/statics/styles/audio-embed-scss.js +1 -1
  132. package/dist/cjs/plugin-audio/statics/styles/audio-embed-scss.js.map +1 -1
  133. package/dist/cjs/plugin-audio/statics/styles/audio-scss.js +21 -21
  134. package/dist/cjs/plugin-audio/statics/styles/audio-scss.js.map +1 -1
  135. package/dist/cjs/plugin-audio/statics/styles/icon-button-scss.js +1 -1
  136. package/dist/cjs/plugin-audio/statics/styles/icon-button-scss.js.map +1 -1
  137. package/dist/cjs/plugin-audio/statics/styles/settings-modal-scss.js +1 -1
  138. package/dist/cjs/plugin-audio/statics/styles/settings-modal-scss.js.map +1 -1
  139. package/dist/cjs/plugin-audio/statics/styles/sound-control-scss.js +2 -2
  140. package/dist/cjs/plugin-audio/statics/styles/sound-control-scss.js.map +1 -1
  141. package/dist/cjs/plugin-block-drag-handle/box-select.js +1 -0
  142. package/dist/cjs/plugin-block-drag-handle/box-select.js.map +2 -2
  143. package/dist/cjs/plugin-block-drag-handle/dom.js +20 -8
  144. package/dist/cjs/plugin-block-drag-handle/dom.js.map +2 -2
  145. package/dist/cjs/plugin-block-drag-handle/plugin.js +35 -4
  146. package/dist/cjs/plugin-block-drag-handle/plugin.js.map +2 -2
  147. package/dist/cjs/plugin-block-drag-handle/styles-scss.js +8 -8
  148. package/dist/cjs/plugin-block-drag-handle/styles-scss.js.map +1 -1
  149. package/dist/cjs/plugin-button/statics/styles/button-input-modal-scss.js +2 -2
  150. package/dist/cjs/plugin-button/statics/styles/button-input-modal-scss.js.map +1 -1
  151. package/dist/cjs/plugin-button/statics/styles/button-text-field-scss.js +1 -1
  152. package/dist/cjs/plugin-button/statics/styles/button-text-field-scss.js.map +1 -1
  153. package/dist/cjs/plugin-button/statics/styles/default-styles-scss.js +5 -5
  154. package/dist/cjs/plugin-button/statics/styles/default-styles-scss.js.map +1 -1
  155. package/dist/cjs/plugin-card/card-node-view.js +39 -35
  156. package/dist/cjs/plugin-card/card-node-view.js.map +2 -2
  157. package/dist/cjs/plugin-card/card-scss.js +20 -19
  158. package/dist/cjs/plugin-card/card-scss.js.map +2 -2
  159. package/dist/cjs/plugin-card/card-viewer-scss.js +6 -6
  160. package/dist/cjs/plugin-card/card-viewer-scss.js.map +1 -1
  161. package/dist/cjs/plugin-card/extension.js +3 -1
  162. package/dist/cjs/plugin-card/extension.js.map +2 -2
  163. package/dist/cjs/plugin-card/index.js.map +1 -1
  164. package/dist/cjs/plugin-card/page-gap.js +3 -1
  165. package/dist/cjs/plugin-card/page-gap.js.map +2 -2
  166. package/dist/cjs/plugin-card/types-next.js.map +1 -1
  167. package/dist/cjs/plugin-card/types.js.map +1 -1
  168. package/dist/cjs/plugin-code-block/statics/styles/code-block-scss.js +6 -6
  169. package/dist/cjs/plugin-code-block/statics/styles/code-block-scss.js.map +1 -1
  170. package/dist/cjs/plugin-collapsible-list/statics/styles/collapsible-list-component-scss.js +6 -6
  171. package/dist/cjs/plugin-collapsible-list/statics/styles/collapsible-list-component-scss.js.map +1 -1
  172. package/dist/cjs/plugin-collapsible-list/statics/styles/collapsible-list-pair-scss.js +18 -18
  173. package/dist/cjs/plugin-collapsible-list/statics/styles/collapsible-list-pair-scss.js.map +1 -1
  174. package/dist/cjs/plugin-collapsible-list/statics/styles/collapsible-list-settings-scss.js +2 -2
  175. package/dist/cjs/plugin-collapsible-list/statics/styles/collapsible-list-settings-scss.js.map +1 -1
  176. package/dist/cjs/plugin-collapsible-list/statics/styles/new-pair-button-scss.js +3 -3
  177. package/dist/cjs/plugin-collapsible-list/statics/styles/new-pair-button-scss.js.map +1 -1
  178. package/dist/cjs/plugin-divider/statics/styles/divider-viewer-scss.js +13 -13
  179. package/dist/cjs/plugin-divider/statics/styles/divider-viewer-scss.js.map +1 -1
  180. package/dist/cjs/plugin-divider/toolbar/modals/divider-design-panel-scss.js +1 -1
  181. package/dist/cjs/plugin-divider/toolbar/modals/divider-design-panel-scss.js.map +1 -1
  182. package/dist/cjs/plugin-emoji/modals/emoji-suggestions-modal-scss.js +1 -1
  183. package/dist/cjs/plugin-emoji/modals/emoji-suggestions-modal-scss.js.map +1 -1
  184. package/dist/cjs/plugin-figure/tiptap/caption-scss.js +3 -3
  185. package/dist/cjs/plugin-figure/tiptap/caption-scss.js.map +1 -1
  186. package/dist/cjs/plugin-figure/tiptap/figure-scss.js +3 -3
  187. package/dist/cjs/plugin-figure/tiptap/figure-scss.js.map +1 -1
  188. package/dist/cjs/plugin-file-upload/statics/styles/file-upload-viewer-scss.js +15 -15
  189. package/dist/cjs/plugin-file-upload/statics/styles/file-upload-viewer-scss.js.map +1 -1
  190. package/dist/cjs/plugin-gallery/modals/settings/gallery-settings-modal-scss.js +3 -3
  191. package/dist/cjs/plugin-gallery/modals/settings/gallery-settings-modal-scss.js.map +1 -1
  192. package/dist/cjs/plugin-gallery/modals/settings/layout-settings/layout-controls-section/image-ratio-control-scss.js +6 -6
  193. package/dist/cjs/plugin-gallery/modals/settings/layout-settings/layout-controls-section/image-ratio-control-scss.js.map +1 -1
  194. package/dist/cjs/plugin-gallery/modals/settings/layout-settings/layout-controls-section/thumbnail-alignment-control-scss.js +5 -5
  195. package/dist/cjs/plugin-gallery/modals/settings/layout-settings/layout-controls-section/thumbnail-alignment-control-scss.js.map +1 -1
  196. package/dist/cjs/plugin-gallery/modals/settings/media-settings/media-list/sortable-item-scss.js +1 -1
  197. package/dist/cjs/plugin-gallery/modals/settings/media-settings/media-list/sortable-item-scss.js.map +1 -1
  198. package/dist/cjs/plugin-gallery/modals/settings/media-settings/media-list/sortable-list-scss.js +3 -3
  199. package/dist/cjs/plugin-gallery/modals/settings/media-settings/media-list/sortable-list-scss.js.map +1 -1
  200. package/dist/cjs/plugin-gallery/statics/styles/gallery-component-scss.js +1 -1
  201. package/dist/cjs/plugin-gallery/statics/styles/gallery-component-scss.js.map +1 -1
  202. package/dist/cjs/plugin-gallery/statics/styles/gallery-media-scss.js +21 -21
  203. package/dist/cjs/plugin-gallery/statics/styles/gallery-media-scss.js.map +1 -1
  204. package/dist/cjs/plugin-gallery/statics/styles/viewer-scss.js +1 -1
  205. package/dist/cjs/plugin-gallery/statics/styles/viewer-scss.js.map +1 -1
  206. package/dist/cjs/plugin-gallery/viewer/layout-collage-scss.js +5 -5
  207. package/dist/cjs/plugin-gallery/viewer/layout-collage-scss.js.map +1 -1
  208. package/dist/cjs/plugin-gallery/viewer/layout-column-scss.js +4 -4
  209. package/dist/cjs/plugin-gallery/viewer/layout-column-scss.js.map +1 -1
  210. package/dist/cjs/plugin-gallery/viewer/layout-fullsize-scss.js +4 -4
  211. package/dist/cjs/plugin-gallery/viewer/layout-fullsize-scss.js.map +1 -1
  212. package/dist/cjs/plugin-gallery/viewer/layout-grid-scss.js +2 -2
  213. package/dist/cjs/plugin-gallery/viewer/layout-grid-scss.js.map +1 -1
  214. package/dist/cjs/plugin-gallery/viewer/layout-masonry-scss.js +7 -7
  215. package/dist/cjs/plugin-gallery/viewer/layout-masonry-scss.js.map +1 -1
  216. package/dist/cjs/plugin-gallery/viewer/layout-panorama-scss.js +1 -1
  217. package/dist/cjs/plugin-gallery/viewer/layout-panorama-scss.js.map +1 -1
  218. package/dist/cjs/plugin-gallery/viewer/layout-slider-scss.js +6 -6
  219. package/dist/cjs/plugin-gallery/viewer/layout-slider-scss.js.map +1 -1
  220. package/dist/cjs/plugin-gallery/viewer/layout-thumbnail-scss.js +11 -11
  221. package/dist/cjs/plugin-gallery/viewer/layout-thumbnail-scss.js.map +1 -1
  222. package/dist/cjs/plugin-giphy/components/giphy-selector-scss.js +9 -9
  223. package/dist/cjs/plugin-giphy/components/giphy-selector-scss.js.map +1 -1
  224. package/dist/cjs/plugin-giphy/viewer/giphy-viewer-scss.js +4 -4
  225. package/dist/cjs/plugin-giphy/viewer/giphy-viewer-scss.js.map +1 -1
  226. package/dist/cjs/plugin-giphy/viewer/play-icon-scss.js +2 -2
  227. package/dist/cjs/plugin-giphy/viewer/play-icon-scss.js.map +1 -1
  228. package/dist/cjs/plugin-hashtag/statics/hashtag-scss.js +2 -2
  229. package/dist/cjs/plugin-hashtag/statics/hashtag-scss.js.map +1 -1
  230. package/dist/cjs/plugin-headings/dropdown/headings-dropdown-scss.js +5 -5
  231. package/dist/cjs/plugin-headings/dropdown/headings-dropdown-scss.js.map +1 -1
  232. package/dist/cjs/plugin-html/statics/styles/HtmlComponent-scss.js +2 -2
  233. package/dist/cjs/plugin-html/statics/styles/HtmlComponent-scss.js.map +1 -1
  234. package/dist/cjs/plugin-html/statics/styles/Iframe-scss.js +1 -1
  235. package/dist/cjs/plugin-html/statics/styles/Iframe-scss.js.map +1 -1
  236. package/dist/cjs/plugin-html/tiptap/ai-widget-scss.js +2 -2
  237. package/dist/cjs/plugin-html/tiptap/ai-widget-scss.js.map +1 -1
  238. package/dist/cjs/plugin-html/tiptap/loader-scss.js +9 -9
  239. package/dist/cjs/plugin-html/tiptap/loader-scss.js.map +1 -1
  240. package/dist/cjs/plugin-html/tiptap/preset-bar/preset-bar-scss.js +2 -2
  241. package/dist/cjs/plugin-html/tiptap/preset-bar/preset-bar-scss.js.map +1 -1
  242. package/dist/cjs/plugin-image/components/corner-radius-handles-scss.js +4 -4
  243. package/dist/cjs/plugin-image/components/corner-radius-handles-scss.js.map +1 -1
  244. package/dist/cjs/plugin-image/components/crop-edge-handles-scss.js +1 -1
  245. package/dist/cjs/plugin-image/components/crop-edge-handles-scss.js.map +1 -1
  246. package/dist/cjs/plugin-image/crop-overlay/crop-overlay-scss.js +14 -14
  247. package/dist/cjs/plugin-image/crop-overlay/crop-overlay-scss.js.map +1 -1
  248. package/dist/cjs/plugin-image/statics/styles/image-viewer-scss.js +20 -20
  249. package/dist/cjs/plugin-image/statics/styles/image-viewer-scss.js.map +1 -1
  250. package/dist/cjs/plugin-image/statics/styles/settings-modal-scss.js +1 -1
  251. package/dist/cjs/plugin-image/statics/styles/settings-modal-scss.js.map +1 -1
  252. package/dist/cjs/plugin-image/toolbar/shape-crop-modal-scss.js +4 -4
  253. package/dist/cjs/plugin-image/toolbar/shape-crop-modal-scss.js.map +1 -1
  254. package/dist/cjs/plugin-inline-ai/ai-selection-tooltip-scss.js +10 -10
  255. package/dist/cjs/plugin-inline-ai/ai-selection-tooltip-scss.js.map +1 -1
  256. package/dist/cjs/plugin-inline-ai/aria-avatar-row-scss.js +1 -1
  257. package/dist/cjs/plugin-inline-ai/aria-avatar-row-scss.js.map +1 -1
  258. package/dist/cjs/plugin-inline-ai/aria-surface-row-scss.js +4 -4
  259. package/dist/cjs/plugin-inline-ai/aria-surface-row-scss.js.map +1 -1
  260. package/dist/cjs/plugin-inline-ai/html-placeholder-scss.js +3 -3
  261. package/dist/cjs/plugin-inline-ai/html-placeholder-scss.js.map +1 -1
  262. package/dist/cjs/plugin-inline-ai/modal-scss.js +9 -9
  263. package/dist/cjs/plugin-inline-ai/modal-scss.js.map +1 -1
  264. package/dist/cjs/plugin-inline-ai/pending-widget-placeholder-scss.js +12 -12
  265. package/dist/cjs/plugin-inline-ai/pending-widget-placeholder-scss.js.map +1 -1
  266. package/dist/cjs/plugin-inline-ai/spinner-scss.js +2 -2
  267. package/dist/cjs/plugin-inline-ai/spinner-scss.js.map +1 -1
  268. package/dist/cjs/plugin-inline-ai/toolbar/toolbar-button-scss.js +2 -2
  269. package/dist/cjs/plugin-inline-ai/toolbar/toolbar-button-scss.js.map +1 -1
  270. package/dist/cjs/plugin-line-spacing/custom-spacing-editor-modal/custom-spacing-editor-modal-scss.js +1 -1
  271. package/dist/cjs/plugin-line-spacing/custom-spacing-editor-modal/custom-spacing-editor-modal-scss.js.map +1 -1
  272. package/dist/cjs/plugin-link/editor.js +2 -2
  273. package/dist/cjs/plugin-link/editor.js.map +2 -2
  274. package/dist/cjs/plugin-link/statics/link-viewer-scss.js +4 -4
  275. package/dist/cjs/plugin-link/statics/link-viewer-scss.js.map +1 -1
  276. package/dist/cjs/plugin-link/toolbar/anchor-link-button-scss.js +1 -1
  277. package/dist/cjs/plugin-link/toolbar/anchor-link-button-scss.js.map +1 -1
  278. package/dist/cjs/plugin-link-preview/statics/styles/insert-modal-scss.js +1 -1
  279. package/dist/cjs/plugin-link-preview/statics/styles/insert-modal-scss.js.map +1 -1
  280. package/dist/cjs/plugin-link-preview/statics/styles/link-preview-scss.js +18 -18
  281. package/dist/cjs/plugin-link-preview/statics/styles/link-preview-scss.js.map +1 -1
  282. package/dist/cjs/plugin-link-preview/statics/styles/settings-modal-scss.js +1 -1
  283. package/dist/cjs/plugin-link-preview/statics/styles/settings-modal-scss.js.map +1 -1
  284. package/dist/cjs/plugin-mentions/statics/mention-list-scss.js +3 -3
  285. package/dist/cjs/plugin-mentions/statics/mention-list-scss.js.map +1 -1
  286. package/dist/cjs/plugin-mentions/statics/mentions-scss.js +4 -4
  287. package/dist/cjs/plugin-mentions/statics/mentions-scss.js.map +1 -1
  288. package/dist/cjs/plugin-paywall/paywall-fallback-scss.js +1 -1
  289. package/dist/cjs/plugin-paywall/paywall-fallback-scss.js.map +1 -1
  290. package/dist/cjs/plugin-paywall/plugin-paywall.js.map +2 -2
  291. package/dist/cjs/plugin-smart-block/components/cell-accessory-scss.js +22 -22
  292. package/dist/cjs/plugin-smart-block/components/cell-accessory-scss.js.map +1 -1
  293. package/dist/cjs/plugin-smart-block/components/cell-quote-glyph-scss.js +3 -3
  294. package/dist/cjs/plugin-smart-block/components/cell-quote-glyph-scss.js.map +1 -1
  295. package/dist/cjs/plugin-smart-block/components/cell-star-rating-scss.js +4 -4
  296. package/dist/cjs/plugin-smart-block/components/cell-star-rating-scss.js.map +1 -1
  297. package/dist/cjs/plugin-smart-block/components/cell-stat-scss.js +20 -20
  298. package/dist/cjs/plugin-smart-block/components/cell-stat-scss.js.map +1 -1
  299. package/dist/cjs/plugin-smart-block/components/circle-donut-scss.js +7 -7
  300. package/dist/cjs/plugin-smart-block/components/circle-donut-scss.js.map +1 -1
  301. package/dist/cjs/plugin-smart-block/components/shape-overlay-scss.js +1 -1
  302. package/dist/cjs/plugin-smart-block/components/shape-overlay-scss.js.map +1 -1
  303. package/dist/cjs/plugin-smart-block/components/smart-block-view-scss.js +50 -50
  304. package/dist/cjs/plugin-smart-block/components/smart-block-view-scss.js.map +1 -1
  305. package/dist/cjs/plugin-smart-block/components/stars-scss.js +8 -8
  306. package/dist/cjs/plugin-smart-block/components/stars-scss.js.map +1 -1
  307. package/dist/cjs/plugin-smart-block/modals/variant-picker-scss.js +7 -7
  308. package/dist/cjs/plugin-smart-block/modals/variant-picker-scss.js.map +1 -1
  309. package/dist/cjs/plugin-smart-block/tiptap/smart-block-editor-scss.js +13 -13
  310. package/dist/cjs/plugin-smart-block/tiptap/smart-block-editor-scss.js.map +1 -1
  311. package/dist/cjs/plugin-social-polls/components/image-upload/image-upload-scss.js +9 -9
  312. package/dist/cjs/plugin-social-polls/components/image-upload/image-upload-scss.js.map +1 -1
  313. package/dist/cjs/plugin-social-polls/components/insert-modal/insert-modal-scss.js +1 -1
  314. package/dist/cjs/plugin-social-polls/components/insert-modal/insert-modal-scss.js.map +1 -1
  315. package/dist/cjs/plugin-social-polls/components/poll-header/poll-header-scss.js +3 -3
  316. package/dist/cjs/plugin-social-polls/components/poll-header/poll-header-scss.js.map +1 -1
  317. package/dist/cjs/plugin-social-polls/components/poll-option/option-scss.js +23 -23
  318. package/dist/cjs/plugin-social-polls/components/poll-option/option-scss.js.map +1 -1
  319. package/dist/cjs/plugin-social-polls/components/poll-option/webview/option-webview-scss.js +24 -24
  320. package/dist/cjs/plugin-social-polls/components/poll-option/webview/option-webview-scss.js.map +1 -1
  321. package/dist/cjs/plugin-social-polls/components/poll-scss.js +19 -19
  322. package/dist/cjs/plugin-social-polls/components/poll-scss.js.map +1 -1
  323. package/dist/cjs/plugin-social-polls/components/settings-modal/settings-modal-scss.js +2 -2
  324. package/dist/cjs/plugin-social-polls/components/settings-modal/settings-modal-scss.js.map +1 -1
  325. package/dist/cjs/plugin-social-polls/components/text-field/text-field-scss.js +12 -12
  326. package/dist/cjs/plugin-social-polls/components/text-field/text-field-scss.js.map +1 -1
  327. package/dist/cjs/plugin-social-polls/components/voted-users/voted-users-scss.js +20 -20
  328. package/dist/cjs/plugin-social-polls/components/voted-users/voted-users-scss.js.map +1 -1
  329. package/dist/cjs/plugin-spoiler/get-text-buttons.js +2 -2
  330. package/dist/cjs/plugin-spoiler/get-text-buttons.js.map +2 -2
  331. package/dist/cjs/plugin-spoiler/statics/styles/spoiler-scss.js +18 -18
  332. package/dist/cjs/plugin-spoiler/statics/styles/spoiler-scss.js.map +1 -1
  333. package/dist/cjs/plugin-table/modals/table-grid-selector-scss.js +5 -5
  334. package/dist/cjs/plugin-table/modals/table-grid-selector-scss.js.map +1 -1
  335. package/dist/cjs/plugin-table/statics/styles/cell-scss.js +15 -15
  336. package/dist/cjs/plugin-table/statics/styles/cell-scss.js.map +1 -1
  337. package/dist/cjs/plugin-table/statics/styles/resizer-scss.js +18 -18
  338. package/dist/cjs/plugin-table/statics/styles/resizer-scss.js.map +1 -1
  339. package/dist/cjs/plugin-table/statics/styles/table-settings-modal-scss.js +1 -1
  340. package/dist/cjs/plugin-table/statics/styles/table-settings-modal-scss.js.map +1 -1
  341. package/dist/cjs/plugin-table/statics/styles/table-viewer-scss.js +6 -6
  342. package/dist/cjs/plugin-table/statics/styles/table-viewer-scss.js.map +1 -1
  343. package/dist/cjs/plugin-table/tiptap/decorations/tableHandles-scss.js +9 -9
  344. package/dist/cjs/plugin-table/tiptap/decorations/tableHandles-scss.js.map +1 -1
  345. package/dist/cjs/plugin-table/tiptap/plugins/table-scss.js +33 -33
  346. package/dist/cjs/plugin-table/tiptap/plugins/table-scss.js.map +1 -1
  347. package/dist/cjs/plugin-table/toolbar/modals/border-scope-selector-scss.js +2 -2
  348. package/dist/cjs/plugin-table/toolbar/modals/border-scope-selector-scss.js.map +1 -1
  349. package/dist/cjs/plugin-text-color/sketch/text-highlight-button.js +2 -2
  350. package/dist/cjs/plugin-text-color/sketch/text-highlight-button.js.map +2 -2
  351. package/dist/cjs/plugin-text-color/text-button-color-scss.js +2 -2
  352. package/dist/cjs/plugin-text-color/text-button-color-scss.js.map +1 -1
  353. package/dist/cjs/plugin-toc/toc-view-scss.js +2 -2
  354. package/dist/cjs/plugin-toc/toc-view-scss.js.map +1 -1
  355. package/dist/cjs/plugin-vertical-embed/components/Ribbon-scss.js +3 -3
  356. package/dist/cjs/plugin-vertical-embed/components/Ribbon-scss.js.map +1 -1
  357. package/dist/cjs/plugin-vertical-embed/components/card-content-scss.js +23 -23
  358. package/dist/cjs/plugin-vertical-embed/components/card-content-scss.js.map +1 -1
  359. package/dist/cjs/plugin-vertical-embed/components/card-scss.js +19 -19
  360. package/dist/cjs/plugin-vertical-embed/components/card-scss.js.map +1 -1
  361. package/dist/cjs/plugin-vertical-embed/components/description-scss.js +2 -2
  362. package/dist/cjs/plugin-vertical-embed/components/description-scss.js.map +1 -1
  363. package/dist/cjs/plugin-vertical-embed/modals/settings-modal-scss.js +2 -2
  364. package/dist/cjs/plugin-vertical-embed/modals/settings-modal-scss.js.map +1 -1
  365. package/dist/cjs/plugin-vertical-embed/tiptap/component-scss.js +10 -10
  366. package/dist/cjs/plugin-vertical-embed/tiptap/component-scss.js.map +1 -1
  367. package/dist/cjs/plugin-vertical-embed/toolbar/items-list-scss.js +1 -1
  368. package/dist/cjs/plugin-vertical-embed/toolbar/items-list-scss.js.map +1 -1
  369. package/dist/cjs/plugin-vertical-embed/viewer/vertical-embed-viewer-scss.js +6 -6
  370. package/dist/cjs/plugin-vertical-embed/viewer/vertical-embed-viewer-scss.js.map +1 -1
  371. package/dist/cjs/plugin-video/statics/styles/default-video-styles-scss.js +8 -8
  372. package/dist/cjs/plugin-video/statics/styles/default-video-styles-scss.js.map +1 -1
  373. package/dist/cjs/plugin-video/statics/styles/video-viewer-scss.js +3 -3
  374. package/dist/cjs/plugin-video/statics/styles/video-viewer-scss.js.map +1 -1
  375. package/dist/cjs/plugin-video/toolbar/embed-video-scss.js +1 -1
  376. package/dist/cjs/plugin-video/toolbar/embed-video-scss.js.map +1 -1
  377. package/dist/cjs/ricos-common-plugins/bold/extension.js +4 -5
  378. package/dist/cjs/ricos-common-plugins/bold/extension.js.map +2 -2
  379. package/dist/cjs/ricos-common-plugins/decoration-plugins/list-item-sizing.js +13 -1
  380. package/dist/cjs/ricos-common-plugins/decoration-plugins/list-item-sizing.js.map +2 -2
  381. package/dist/cjs/ricos-common-plugins/font-size/block-font-size-plugin.js +2 -1
  382. package/dist/cjs/ricos-common-plugins/font-size/block-font-size-plugin.js.map +2 -2
  383. package/dist/cjs/ricos-common-plugins/font-size/dropdown/font-size-dropdown-scss.js +1 -1
  384. package/dist/cjs/ricos-common-plugins/font-size/dropdown/font-size-dropdown-scss.js.map +1 -1
  385. package/dist/cjs/ricos-common-plugins/gap-spacer/gap-spacer-component/gap-spacer-styles-scss.js +8 -8
  386. package/dist/cjs/ricos-common-plugins/gap-spacer/gap-spacer-component/gap-spacer-styles-scss.js.map +1 -1
  387. package/dist/cjs/ricos-common-plugins/layout/layouts-scss.js +33 -33
  388. package/dist/cjs/ricos-common-plugins/layout/layouts-scss.js.map +1 -1
  389. package/dist/cjs/ricos-common-plugins/layout/paywall-toolbar-button.js +100 -0
  390. package/dist/cjs/ricos-common-plugins/layout/paywall-toolbar-button.js.map +7 -0
  391. package/dist/cjs/ricos-common-plugins/layout/plugin-layout.js +178 -173
  392. package/dist/cjs/ricos-common-plugins/layout/plugin-layout.js.map +2 -2
  393. package/dist/cjs/ricos-common-plugins/layout/section-dividers/section-dividers-panel-scss.js +2 -2
  394. package/dist/cjs/ricos-common-plugins/layout/section-dividers/section-dividers-panel-scss.js.map +1 -1
  395. package/dist/cjs/ricos-common-plugins/layout/section-dividers/section-dividers-scss.js +4 -4
  396. package/dist/cjs/ricos-common-plugins/layout/section-dividers/section-dividers-scss.js.map +1 -1
  397. package/dist/cjs/ricos-common-plugins/list-item/extension.js +9 -0
  398. package/dist/cjs/ricos-common-plugins/list-item/extension.js.map +2 -2
  399. package/dist/cjs/ricos-common-plugins/list-item/list-converters.js +5 -3
  400. package/dist/cjs/ricos-common-plugins/list-item/list-converters.js.map +2 -2
  401. package/dist/cjs/ricos-common-plugins/list-item/list-marker-selection.js +291 -0
  402. package/dist/cjs/ricos-common-plugins/list-item/list-marker-selection.js.map +7 -0
  403. package/dist/cjs/ricos-common-plugins/quick-actions/modal/modal-scss.js +2 -2
  404. package/dist/cjs/ricos-common-plugins/quick-actions/modal/modal-scss.js.map +1 -1
  405. package/dist/cjs/ricos-common-plugins/statics/styles-scss.js +18 -18
  406. package/dist/cjs/ricos-common-plugins/statics/styles-scss.js.map +1 -1
  407. package/dist/cjs/ricos-common-plugins/strikethrough/strikethrough.js +2 -2
  408. package/dist/cjs/ricos-common-plugins/strikethrough/strikethrough.js.map +2 -2
  409. package/dist/cjs/ricos-common-plugins/strikethrough/strikethrough.testkit.js +1 -0
  410. package/dist/cjs/ricos-common-plugins/strikethrough/strikethrough.testkit.js.map +2 -2
  411. package/dist/cjs/ricos-common-plugins/title/headings-scss.js +8 -8
  412. package/dist/cjs/ricos-common-plugins/title/headings-scss.js.map +1 -1
  413. package/dist/cjs/ricos-common-plugins/underline/underline.js +2 -2
  414. package/dist/cjs/ricos-common-plugins/underline/underline.js.map +2 -2
  415. package/dist/cjs/ricos-editor/statics/styles/editor-styles-scss.js +9 -9
  416. package/dist/cjs/ricos-editor/statics/styles/editor-styles-scss.js.map +1 -1
  417. package/dist/cjs/ricos-modals/statics/styles/drawer-scss.js +9 -9
  418. package/dist/cjs/ricos-modals/statics/styles/drawer-scss.js.map +1 -1
  419. package/dist/cjs/ricos-modals/statics/styles/fullscreen-scss.js +1 -1
  420. package/dist/cjs/ricos-modals/statics/styles/fullscreen-scss.js.map +1 -1
  421. package/dist/cjs/ricos-modals/statics/styles/popper-scss.js +3 -3
  422. package/dist/cjs/ricos-modals/statics/styles/popper-scss.js.map +1 -1
  423. package/dist/cjs/ricos-schema/next-schema/version.js +1 -1
  424. package/dist/cjs/ricos-schema/next-schema/version.js.map +1 -1
  425. package/dist/cjs/ricos-styles/statics/styles/style-presets-scss.js +4 -4
  426. package/dist/cjs/ricos-styles/statics/styles/style-presets-scss.js.map +1 -1
  427. package/dist/cjs/ricos-types/next/ricos-types.js.map +1 -1
  428. package/dist/cjs/ricos-types/ricos-types.js.map +1 -1
  429. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/blockquote/blockquote-scss.js +3 -3
  430. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/blockquote/blockquote-scss.js.map +1 -1
  431. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/codeblock/codeblock-scss.js +3 -3
  432. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/codeblock/codeblock-scss.js.map +1 -1
  433. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/heading/heading-scss.js +9 -9
  434. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/heading/heading-scss.js.map +1 -1
  435. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/layout/layout-scss.js +10 -10
  436. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/layout/layout-scss.js.map +1 -1
  437. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/lists/list-item.js +10 -1
  438. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/lists/list-item.js.map +2 -2
  439. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/lists/lists-scss.js +6 -6
  440. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/lists/lists-scss.js.map +1 -1
  441. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/paragraph/paragraph-scss.js +4 -4
  442. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/paragraph/paragraph-scss.js.map +1 -1
  443. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/plugins/link-viewer-wrapper-scss.js +2 -2
  444. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/plugins/link-viewer-wrapper-scss.js.map +1 -1
  445. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/plugins/plugin-scss.js +15 -15
  446. package/dist/cjs/ricos-viewer-next/ContentViewer/rericos/renderers/plugins/plugin-scss.js.map +1 -1
  447. package/dist/cjs/ricos-viewer-next/modals/fullscreen/fullscreen-scss.js +12 -12
  448. package/dist/cjs/ricos-viewer-next/modals/fullscreen/fullscreen-scss.js.map +1 -1
  449. package/dist/cjs/ricos-viewer-next/statics/alignment-scss.js +16 -16
  450. package/dist/cjs/ricos-viewer-next/statics/alignment-scss.js.map +1 -1
  451. package/dist/cjs/ricos-viewer-next/statics/indentation-scss.js +7 -7
  452. package/dist/cjs/ricos-viewer-next/statics/indentation-scss.js.map +1 -1
  453. package/dist/cjs/ricos-viewer-next/statics/rich-content-viewer-scss.js +9 -9
  454. package/dist/cjs/ricos-viewer-next/statics/rich-content-viewer-scss.js.map +1 -1
  455. package/dist/cjs/ricos-viewer-next/statics/rtl-scss.js +2 -2
  456. package/dist/cjs/ricos-viewer-next/statics/rtl-scss.js.map +1 -1
  457. package/dist/cjs/text-selection-toolbar/statics/styles/viewer-inline-toolbar-scss.js +2 -2
  458. package/dist/cjs/text-selection-toolbar/statics/styles/viewer-inline-toolbar-scss.js.map +1 -1
  459. package/dist/cjs/tiptap/core/editor.js +5 -2
  460. package/dist/cjs/tiptap/core/editor.js.map +2 -2
  461. package/dist/cjs/tiptap-editor/statics/styles/tiptap-editor-styles-scss.js +13 -13
  462. package/dist/cjs/tiptap-editor/statics/styles/tiptap-editor-styles-scss.js.map +1 -1
  463. package/dist/cjs/tiptap-extensions/placeholder-scss.js +1 -1
  464. package/dist/cjs/tiptap-extensions/placeholder-scss.js.map +1 -1
  465. package/dist/cjs/tiptap-extensions/statics/styles-scss.js +4 -4
  466. package/dist/cjs/tiptap-extensions/statics/styles-scss.js.map +1 -1
  467. package/dist/cjs/toolbars-v3/components/InsertPluginToolbar/insert-plugin-toolbar-scss.js +1 -1
  468. package/dist/cjs/toolbars-v3/components/InsertPluginToolbar/insert-plugin-toolbar-scss.js.map +1 -1
  469. package/dist/cjs/toolbars-v3/components/MaxWidthCalculationWrapper/max-width-calculation-wrapper.js +2 -1
  470. package/dist/cjs/toolbars-v3/components/MaxWidthCalculationWrapper/max-width-calculation-wrapper.js.map +2 -2
  471. package/dist/cjs/toolbars-v3/components/Toolbar/RicosDesktopToolbar/OverflownButtons-scss.js +3 -3
  472. package/dist/cjs/toolbars-v3/components/Toolbar/RicosDesktopToolbar/OverflownButtons-scss.js.map +1 -1
  473. package/dist/cjs/toolbars-v3/components/Toolbar/RicosDesktopToolbar/RicosDesktopToolbar-scss.js +3 -3
  474. package/dist/cjs/toolbars-v3/components/Toolbar/RicosDesktopToolbar/RicosDesktopToolbar-scss.js.map +1 -1
  475. package/dist/cjs/toolbars-v3/components/Toolbar/RicosDesktopToolbar/RicosDesktopToolbarWrapper-scss.js +4 -4
  476. package/dist/cjs/toolbars-v3/components/Toolbar/RicosDesktopToolbar/RicosDesktopToolbarWrapper-scss.js.map +1 -1
  477. package/dist/cjs/toolbars-v3/components/Toolbar/RicosMobileToolbar/RicosMobileToolbar-scss.js +9 -9
  478. package/dist/cjs/toolbars-v3/components/Toolbar/RicosMobileToolbar/RicosMobileToolbar-scss.js.map +1 -1
  479. package/dist/cjs/toolbars-v3/components/Toolbar/RicosMobileToolbar/mobile-toolbar-overlay/mobile-toolbar-overlay-scss.js +1 -1
  480. package/dist/cjs/toolbars-v3/components/Toolbar/RicosMobileToolbar/mobile-toolbar-overlay/mobile-toolbar-overlay-scss.js.map +1 -1
  481. package/dist/cjs/toolbars-v3/components/buttons/AddPluginMenuButtons/AddPluginMenuMobileButton-scss.js +1 -1
  482. package/dist/cjs/toolbars-v3/components/buttons/AddPluginMenuButtons/AddPluginMenuMobileButton-scss.js.map +1 -1
  483. package/dist/cjs/toolbars-v3/components/buttons/FontSizeButton/FontSizeButton-scss.js +5 -5
  484. package/dist/cjs/toolbars-v3/components/buttons/FontSizeButton/FontSizeButton-scss.js.map +1 -1
  485. package/dist/cjs/toolbars-v3/modals/FloatingPluginMenu/styles/floating-add-plugin-menu-scss.js +6 -6
  486. package/dist/cjs/toolbars-v3/modals/FloatingPluginMenu/styles/floating-add-plugin-menu-scss.js.map +1 -1
  487. package/dist/cjs/toolbars-v3/ricos-toolbars/footer/FooterToolbar-scss.js +1 -1
  488. package/dist/cjs/toolbars-v3/ricos-toolbars/footer/FooterToolbar-scss.js.map +1 -1
  489. package/dist/cjs/toolbars-v3/ricos-toolbars/formatting/use-is-visible.js +4 -0
  490. package/dist/cjs/toolbars-v3/ricos-toolbars/formatting/use-is-visible.js.map +2 -2
  491. package/dist/cjs/ui-components/Components/Image-scss.js +1 -1
  492. package/dist/cjs/ui-components/Components/Image-scss.js.map +1 -1
  493. package/dist/cjs/ui-components/Components/double-loader-scss.js +4 -4
  494. package/dist/cjs/ui-components/Components/double-loader-scss.js.map +1 -1
  495. package/dist/cjs/ui-components/color-picker/button-color-swatches/button-color-swatches-scss.js +2 -2
  496. package/dist/cjs/ui-components/color-picker/button-color-swatches/button-color-swatches-scss.js.map +1 -1
  497. package/dist/cjs/ui-components/color-picker/new-color-picker/components/gradient-picker/gradient-picker-scss.js +13 -13
  498. package/dist/cjs/ui-components/color-picker/new-color-picker/components/gradient-picker/gradient-picker-scss.js.map +1 -1
  499. package/dist/cjs/ui-components/color-picker/new-color-picker/components/new-color-swatches/new-color-swatches-scss.js +1 -1
  500. package/dist/cjs/ui-components/color-picker/new-color-picker/components/new-color-swatches/new-color-swatches-scss.js.map +1 -1
  501. package/dist/cjs/ui-components/color-picker/new-color-picker/components/simple-color-picker/simple-color-picker-scss.js +2 -2
  502. package/dist/cjs/ui-components/color-picker/new-color-picker/components/simple-color-picker/simple-color-picker-scss.js.map +1 -1
  503. package/dist/cjs/ui-components/color-picker/new-color-picker/components/single-color-swatch/single-color-swatch-scss.js +2 -2
  504. package/dist/cjs/ui-components/color-picker/new-color-picker/components/single-color-swatch/single-color-swatch-scss.js.map +1 -1
  505. package/dist/cjs/ui-components/color-picker/new-color-picker/new-color-picker-scss.js +1 -1
  506. package/dist/cjs/ui-components/color-picker/new-color-picker/new-color-picker-scss.js.map +1 -1
  507. package/dist/cjs/ui-components/input-with-slider/input-with-slider-scss.js +1 -1
  508. package/dist/cjs/ui-components/input-with-slider/input-with-slider-scss.js.map +1 -1
  509. package/dist/cjs/ui-components/layout-background-loader/layout-background-loader-scss.js +3 -3
  510. package/dist/cjs/ui-components/layout-background-loader/layout-background-loader-scss.js.map +1 -1
  511. package/dist/cjs/ui-components/modal-layout/floating-layout/floating-desktop-layout-scss.js +1 -1
  512. package/dist/cjs/ui-components/modal-layout/floating-layout/floating-desktop-layout-scss.js.map +1 -1
  513. package/dist/cjs/ui-components/modal-layout/fullscreen-mobile-layout/fullscreen-mobile-layout-scss.js +4 -4
  514. package/dist/cjs/ui-components/modal-layout/fullscreen-mobile-layout/fullscreen-mobile-layout-scss.js.map +1 -1
  515. package/dist/cjs/ui-components/panel/panel-scss.js +2 -2
  516. package/dist/cjs/ui-components/panel/panel-scss.js.map +1 -1
  517. package/dist/cjs/ui-components/panel-header/panel-header-scss.js +1 -1
  518. package/dist/cjs/ui-components/panel-header/panel-header-scss.js.map +1 -1
  519. package/dist/cjs/ui-components/settings-panel-discard-modal/settings-panel-discard-modal-scss.js +1 -1
  520. package/dist/cjs/ui-components/settings-panel-discard-modal/settings-panel-discard-modal-scss.js.map +1 -1
  521. package/dist/cjs/ui-components/statics/styles/generic-error-scss.js +1 -1
  522. package/dist/cjs/ui-components/statics/styles/generic-error-scss.js.map +1 -1
  523. package/dist/cjs/ui-components/statics/styles/loaders-scss.js +8 -8
  524. package/dist/cjs/ui-components/statics/styles/loaders-scss.js.map +1 -1
  525. package/dist/cjs/ui-components/statics/styles/media-item-error-msg-scss.js +3 -3
  526. package/dist/cjs/ui-components/statics/styles/media-item-error-msg-scss.js.map +1 -1
  527. package/dist/cjs/ui-components/statics/styles/slider-scss.js +5 -5
  528. package/dist/cjs/ui-components/statics/styles/slider-scss.js.map +1 -1
  529. package/dist/cjs/ui-components/thumbnail-picker/thumbnail-picker-scss.js +1 -1
  530. package/dist/cjs/ui-components/thumbnail-picker/thumbnail-picker-scss.js.map +1 -1
  531. package/dist/cjs/ui-components/wixel-assistant/assistant-timeline-scss.js +16 -16
  532. package/dist/cjs/ui-components/wixel-assistant/assistant-timeline-scss.js.map +1 -1
  533. package/dist/cjs/wix-rich-content-common/statics/styles/fonts-scss.js +1 -1
  534. package/dist/cjs/wix-rich-content-common/statics/styles/fonts-scss.js.map +1 -1
  535. package/dist/cjs/wix-rich-content-common/statics/styles/general-scss.js +11 -11
  536. package/dist/cjs/wix-rich-content-common/statics/styles/general-scss.js.map +1 -1
  537. package/dist/docs/api-docs-reference.cjs +1 -1
  538. package/dist/docs/api-docs-reference.js +1 -1
  539. package/dist/docs/api-docs.md +2 -2
  540. package/dist/docs/sections/editor.md +2 -2
  541. package/dist/es/_shared/dropdown-modal/dropdown-modal-scss.js +5 -5
  542. package/dist/es/_shared/dropdown-modal/dropdown-modal-scss.js.map +1 -1
  543. package/dist/es/_shared/editor-base-url/editor-base-url-context.js +13 -12
  544. package/dist/es/_shared/editor-base-url/editor-base-url-context.js.map +2 -2
  545. package/dist/es/_shared/figure/add-caption-button-scss.js +11 -11
  546. package/dist/es/_shared/figure/add-caption-button-scss.js.map +1 -1
  547. package/dist/es/_shared/figure/viewer-caption-scss.js +2 -2
  548. package/dist/es/_shared/figure/viewer-caption-scss.js.map +1 -1
  549. package/dist/es/_shared/figure/viewer-figure-scss.js +1 -1
  550. package/dist/es/_shared/figure/viewer-figure-scss.js.map +1 -1
  551. package/dist/es/_shared/font-weight.js +7 -0
  552. package/dist/es/_shared/font-weight.js.map +7 -0
  553. package/dist/es/_shared/get-common-marker-style.js +15 -0
  554. package/dist/es/_shared/get-common-marker-style.js.map +7 -0
  555. package/dist/es/_shared/get-decorations-marker-style.js +41 -0
  556. package/dist/es/_shared/get-decorations-marker-style.js.map +7 -0
  557. package/dist/es/_shared/get-list-marker-style.js +23 -0
  558. package/dist/es/_shared/get-list-marker-style.js.map +7 -0
  559. package/dist/es/_shared/link-modal/open-link-modal/site-pages/site-pages.js +2 -4
  560. package/dist/es/_shared/link-modal/open-link-modal/site-pages/site-pages.js.map +2 -2
  561. package/dist/es/_shared/list-item-divider/list-item-divider-scss.js +3 -3
  562. package/dist/es/_shared/list-item-divider/list-item-divider-scss.js.map +1 -1
  563. package/dist/es/_shared/list-item-select/list-item-select-scss.js +4 -4
  564. package/dist/es/_shared/list-item-select/list-item-select-scss.js.map +1 -1
  565. package/dist/es/_shared/list-item-toggle/list-item-toggle-scss.js +5 -5
  566. package/dist/es/_shared/list-item-toggle/list-item-toggle-scss.js.map +1 -1
  567. package/dist/es/_shared/list-marker-style-scss.js +28 -0
  568. package/dist/es/_shared/list-marker-style-scss.js.map +7 -0
  569. package/dist/es/_shared/overlay-hoc/overlay-hoc-scss.js +3 -3
  570. package/dist/es/_shared/overlay-hoc/overlay-hoc-scss.js.map +1 -1
  571. package/dist/es/_shared/plugin-toolbar/create-settings-button.js +7 -1
  572. package/dist/es/_shared/plugin-toolbar/create-settings-button.js.map +2 -2
  573. package/dist/es/_shared/plugin-toolbar/separator/toolbar-button-separator-scss.js +4 -4
  574. package/dist/es/_shared/plugin-toolbar/separator/toolbar-button-separator-scss.js.map +1 -1
  575. package/dist/es/_shared/plugin-toolbar/url-link-button/url-link-button-scss.js +4 -4
  576. package/dist/es/_shared/plugin-toolbar/url-link-button/url-link-button-scss.js.map +1 -1
  577. package/dist/es/_shared/pm-node-types.js.map +2 -2
  578. package/dist/es/_shared/prompt-input-area/attachment-bar/attachment-bar-scss.js +9 -9
  579. package/dist/es/_shared/prompt-input-area/attachment-bar/attachment-bar-scss.js.map +1 -1
  580. package/dist/es/_shared/prompt-input-area/prompt-input-area-scss.js +15 -15
  581. package/dist/es/_shared/prompt-input-area/prompt-input-area-scss.js.map +1 -1
  582. package/dist/es/_shared/prompt-input-area/widget-prompt-input-area-scss.js +10 -10
  583. package/dist/es/_shared/prompt-input-area/widget-prompt-input-area-scss.js.map +1 -1
  584. package/dist/es/_shared/shape-select-modal/shape-select-modal-content-scss.js +9 -9
  585. package/dist/es/_shared/shape-select-modal/shape-select-modal-content-scss.js.map +1 -1
  586. package/dist/es/_shared/shape-view-renderer/shape-view-renderer-scss.js +4 -4
  587. package/dist/es/_shared/shape-view-renderer/shape-view-renderer-scss.js.map +1 -1
  588. package/dist/es/_shared/site-pages/site-pages-fetch-context/use-fetch-site-pages.js +82 -26
  589. package/dist/es/_shared/site-pages/site-pages-fetch-context/use-fetch-site-pages.js.map +3 -3
  590. package/dist/es/_shared/site-pages/site-pages-fetch-context.js +2 -6
  591. package/dist/es/_shared/site-pages/site-pages-fetch-context.js.map +2 -2
  592. package/dist/es/_shared/site-pages/types.js.map +2 -2
  593. package/dist/es/_shared/toolbar-button/toolbar-button-scss.js +5 -5
  594. package/dist/es/_shared/toolbar-button/toolbar-button-scss.js.map +1 -1
  595. package/dist/es/bundled-dependencies/ai-assistant-avatar.js +6 -6
  596. package/dist/es/bundled-dependencies/ai-assistant-avatar.js.map +1 -1
  597. package/dist/es/editor-common/statics/styles/general-scss.js +20 -20
  598. package/dist/es/editor-common/statics/styles/general-scss.js.map +1 -1
  599. package/dist/es/index.js.map +2 -2
  600. package/dist/es/internal.js.map +2 -2
  601. package/dist/es/legacy.js +3 -1
  602. package/dist/es/legacy.js.map +2 -2
  603. package/dist/es/plugin-ai/ai-content-modal/ai-content-modal-scss.js +10 -10
  604. package/dist/es/plugin-ai/ai-content-modal/ai-content-modal-scss.js.map +1 -1
  605. package/dist/es/plugin-ai/ai-content-modal/feed/feed-scss.js +4 -4
  606. package/dist/es/plugin-ai/ai-content-modal/feed/feed-scss.js.map +1 -1
  607. package/dist/es/plugin-ai/ai-content-modal/no-selection-message/no-selection-message-scss.js +3 -3
  608. package/dist/es/plugin-ai/ai-content-modal/no-selection-message/no-selection-message-scss.js.map +1 -1
  609. package/dist/es/plugin-ai/ai-content-modal/text-cursor/text-cursor-scss.js +4 -4
  610. package/dist/es/plugin-ai/ai-content-modal/text-cursor/text-cursor-scss.js.map +1 -1
  611. package/dist/es/plugin-ai/ai-content-modal/textual-prompt-input-area/textual-prompt-input-area-scss.js +7 -7
  612. package/dist/es/plugin-ai/ai-content-modal/textual-prompt-input-area/textual-prompt-input-area-scss.js.map +1 -1
  613. package/dist/es/plugin-ai/ai-image-modal/ai-image-modal-scss.js +8 -8
  614. package/dist/es/plugin-ai/ai-image-modal/ai-image-modal-scss.js.map +1 -1
  615. package/dist/es/plugin-ai/ai-plus-button/ai-plus-button-scss.js +3 -3
  616. package/dist/es/plugin-ai/ai-plus-button/ai-plus-button-scss.js.map +1 -1
  617. package/dist/es/plugin-ai/error-message/error-message-scss.js +3 -3
  618. package/dist/es/plugin-ai/error-message/error-message-scss.js.map +1 -1
  619. package/dist/es/plugin-ai/prompt-input-area/prompt-input-area-scss.js +6 -6
  620. package/dist/es/plugin-ai/prompt-input-area/prompt-input-area-scss.js.map +1 -1
  621. package/dist/es/plugin-ai/toolbar/toolbar-button-scss.js +4 -4
  622. package/dist/es/plugin-ai/toolbar/toolbar-button-scss.js.map +1 -1
  623. package/dist/es/plugin-animation/animation-panel-scss.js +11 -11
  624. package/dist/es/plugin-animation/animation-panel-scss.js.map +1 -1
  625. package/dist/es/plugin-audio/statics/styles/audio-embed-scss.js +3 -3
  626. package/dist/es/plugin-audio/statics/styles/audio-embed-scss.js.map +1 -1
  627. package/dist/es/plugin-audio/statics/styles/audio-scss.js +21 -21
  628. package/dist/es/plugin-audio/statics/styles/audio-scss.js.map +1 -1
  629. package/dist/es/plugin-audio/statics/styles/icon-button-scss.js +1 -1
  630. package/dist/es/plugin-audio/statics/styles/icon-button-scss.js.map +1 -1
  631. package/dist/es/plugin-audio/statics/styles/settings-modal-scss.js +3 -3
  632. package/dist/es/plugin-audio/statics/styles/settings-modal-scss.js.map +1 -1
  633. package/dist/es/plugin-audio/statics/styles/sound-control-scss.js +2 -2
  634. package/dist/es/plugin-audio/statics/styles/sound-control-scss.js.map +1 -1
  635. package/dist/es/plugin-audio/viewer-styles-inject.js +4 -4
  636. package/dist/es/plugin-block-drag-handle/box-select.js +1 -0
  637. package/dist/es/plugin-block-drag-handle/box-select.js.map +2 -2
  638. package/dist/es/plugin-block-drag-handle/dom.js +20 -8
  639. package/dist/es/plugin-block-drag-handle/dom.js.map +2 -2
  640. package/dist/es/plugin-block-drag-handle/plugin.js +37 -5
  641. package/dist/es/plugin-block-drag-handle/plugin.js.map +2 -2
  642. package/dist/es/plugin-block-drag-handle/styles-scss.js +10 -10
  643. package/dist/es/plugin-block-drag-handle/styles-scss.js.map +1 -1
  644. package/dist/es/plugin-button/statics/styles/button-input-modal-scss.js +4 -4
  645. package/dist/es/plugin-button/statics/styles/button-input-modal-scss.js.map +1 -1
  646. package/dist/es/plugin-button/statics/styles/button-text-field-scss.js +3 -3
  647. package/dist/es/plugin-button/statics/styles/button-text-field-scss.js.map +1 -1
  648. package/dist/es/plugin-button/statics/styles/default-styles-scss.js +5 -5
  649. package/dist/es/plugin-button/statics/styles/default-styles-scss.js.map +1 -1
  650. package/dist/es/plugin-button/viewer-styles-inject.js +2 -2
  651. package/dist/es/plugin-card/card-node-view.js +39 -35
  652. package/dist/es/plugin-card/card-node-view.js.map +2 -2
  653. package/dist/es/plugin-card/card-scss.js +20 -19
  654. package/dist/es/plugin-card/card-scss.js.map +2 -2
  655. package/dist/es/plugin-card/card-viewer-scss.js +6 -6
  656. package/dist/es/plugin-card/card-viewer-scss.js.map +1 -1
  657. package/dist/es/plugin-card/extension.js +3 -1
  658. package/dist/es/plugin-card/extension.js.map +2 -2
  659. package/dist/es/plugin-card/index.js.map +1 -1
  660. package/dist/es/plugin-card/page-gap.js +3 -1
  661. package/dist/es/plugin-card/page-gap.js.map +2 -2
  662. package/dist/es/plugin-card/viewer-styles-inject.js +2 -2
  663. package/dist/es/plugin-code-block/statics/styles/code-block-scss.js +8 -8
  664. package/dist/es/plugin-code-block/statics/styles/code-block-scss.js.map +1 -1
  665. package/dist/es/plugin-collapsible-list/statics/styles/collapsible-list-component-scss.js +6 -6
  666. package/dist/es/plugin-collapsible-list/statics/styles/collapsible-list-component-scss.js.map +1 -1
  667. package/dist/es/plugin-collapsible-list/statics/styles/collapsible-list-pair-scss.js +18 -18
  668. package/dist/es/plugin-collapsible-list/statics/styles/collapsible-list-pair-scss.js.map +1 -1
  669. package/dist/es/plugin-collapsible-list/statics/styles/collapsible-list-settings-scss.js +4 -4
  670. package/dist/es/plugin-collapsible-list/statics/styles/collapsible-list-settings-scss.js.map +1 -1
  671. package/dist/es/plugin-collapsible-list/statics/styles/new-pair-button-scss.js +5 -5
  672. package/dist/es/plugin-collapsible-list/statics/styles/new-pair-button-scss.js.map +1 -1
  673. package/dist/es/plugin-collapsible-list/viewer-styles-inject.js +2 -2
  674. package/dist/es/plugin-divider/statics/styles/divider-viewer-scss.js +13 -13
  675. package/dist/es/plugin-divider/statics/styles/divider-viewer-scss.js.map +1 -1
  676. package/dist/es/plugin-divider/toolbar/modals/divider-design-panel-scss.js +3 -3
  677. package/dist/es/plugin-divider/toolbar/modals/divider-design-panel-scss.js.map +1 -1
  678. package/dist/es/plugin-divider/viewer-styles-inject.js +2 -2
  679. package/dist/es/plugin-emoji/modals/emoji-suggestions-modal-scss.js +3 -3
  680. package/dist/es/plugin-emoji/modals/emoji-suggestions-modal-scss.js.map +1 -1
  681. package/dist/es/plugin-figure/tiptap/caption-scss.js +5 -5
  682. package/dist/es/plugin-figure/tiptap/caption-scss.js.map +1 -1
  683. package/dist/es/plugin-figure/tiptap/figure-scss.js +5 -5
  684. package/dist/es/plugin-figure/tiptap/figure-scss.js.map +1 -1
  685. package/dist/es/plugin-file-upload/statics/styles/file-upload-viewer-scss.js +15 -15
  686. package/dist/es/plugin-file-upload/statics/styles/file-upload-viewer-scss.js.map +1 -1
  687. package/dist/es/plugin-file-upload/viewer-styles-inject.js +2 -2
  688. package/dist/es/plugin-gallery/modals/settings/gallery-settings-modal-scss.js +5 -5
  689. package/dist/es/plugin-gallery/modals/settings/gallery-settings-modal-scss.js.map +1 -1
  690. package/dist/es/plugin-gallery/modals/settings/layout-settings/layout-controls-section/image-ratio-control-scss.js +8 -8
  691. package/dist/es/plugin-gallery/modals/settings/layout-settings/layout-controls-section/image-ratio-control-scss.js.map +1 -1
  692. package/dist/es/plugin-gallery/modals/settings/layout-settings/layout-controls-section/thumbnail-alignment-control-scss.js +7 -7
  693. package/dist/es/plugin-gallery/modals/settings/layout-settings/layout-controls-section/thumbnail-alignment-control-scss.js.map +1 -1
  694. package/dist/es/plugin-gallery/modals/settings/media-settings/media-list/sortable-item-scss.js +3 -3
  695. package/dist/es/plugin-gallery/modals/settings/media-settings/media-list/sortable-item-scss.js.map +1 -1
  696. package/dist/es/plugin-gallery/modals/settings/media-settings/media-list/sortable-list-scss.js +5 -5
  697. package/dist/es/plugin-gallery/modals/settings/media-settings/media-list/sortable-list-scss.js.map +1 -1
  698. package/dist/es/plugin-gallery/statics/styles/gallery-component-scss.js +3 -3
  699. package/dist/es/plugin-gallery/statics/styles/gallery-component-scss.js.map +1 -1
  700. package/dist/es/plugin-gallery/statics/styles/gallery-media-scss.js +21 -21
  701. package/dist/es/plugin-gallery/statics/styles/gallery-media-scss.js.map +1 -1
  702. package/dist/es/plugin-gallery/statics/styles/viewer-scss.js +1 -1
  703. package/dist/es/plugin-gallery/statics/styles/viewer-scss.js.map +1 -1
  704. package/dist/es/plugin-gallery/viewer/layout-collage-scss.js +5 -5
  705. package/dist/es/plugin-gallery/viewer/layout-collage-scss.js.map +1 -1
  706. package/dist/es/plugin-gallery/viewer/layout-column-scss.js +4 -4
  707. package/dist/es/plugin-gallery/viewer/layout-column-scss.js.map +1 -1
  708. package/dist/es/plugin-gallery/viewer/layout-fullsize-scss.js +4 -4
  709. package/dist/es/plugin-gallery/viewer/layout-fullsize-scss.js.map +1 -1
  710. package/dist/es/plugin-gallery/viewer/layout-grid-scss.js +2 -2
  711. package/dist/es/plugin-gallery/viewer/layout-grid-scss.js.map +1 -1
  712. package/dist/es/plugin-gallery/viewer/layout-masonry-scss.js +7 -7
  713. package/dist/es/plugin-gallery/viewer/layout-masonry-scss.js.map +1 -1
  714. package/dist/es/plugin-gallery/viewer/layout-panorama-scss.js +1 -1
  715. package/dist/es/plugin-gallery/viewer/layout-panorama-scss.js.map +1 -1
  716. package/dist/es/plugin-gallery/viewer/layout-slider-scss.js +6 -6
  717. package/dist/es/plugin-gallery/viewer/layout-slider-scss.js.map +1 -1
  718. package/dist/es/plugin-gallery/viewer/layout-thumbnail-scss.js +11 -11
  719. package/dist/es/plugin-gallery/viewer/layout-thumbnail-scss.js.map +1 -1
  720. package/dist/es/plugin-gallery/viewer-styles-inject.js +2 -2
  721. package/dist/es/plugin-giphy/components/giphy-selector-scss.js +11 -11
  722. package/dist/es/plugin-giphy/components/giphy-selector-scss.js.map +1 -1
  723. package/dist/es/plugin-giphy/viewer/giphy-viewer-scss.js +4 -4
  724. package/dist/es/plugin-giphy/viewer/giphy-viewer-scss.js.map +1 -1
  725. package/dist/es/plugin-giphy/viewer/play-icon-scss.js +2 -2
  726. package/dist/es/plugin-giphy/viewer/play-icon-scss.js.map +1 -1
  727. package/dist/es/plugin-giphy/viewer-styles-inject.js +2 -2
  728. package/dist/es/plugin-hashtag/statics/hashtag-scss.js +2 -2
  729. package/dist/es/plugin-hashtag/statics/hashtag-scss.js.map +1 -1
  730. package/dist/es/plugin-hashtag/viewer-styles-inject.js +2 -2
  731. package/dist/es/plugin-headings/dropdown/headings-dropdown-scss.js +9 -9
  732. package/dist/es/plugin-headings/dropdown/headings-dropdown-scss.js.map +1 -1
  733. package/dist/es/plugin-html/statics/styles/HtmlComponent-scss.js +2 -2
  734. package/dist/es/plugin-html/statics/styles/HtmlComponent-scss.js.map +1 -1
  735. package/dist/es/plugin-html/statics/styles/Iframe-scss.js +1 -1
  736. package/dist/es/plugin-html/statics/styles/Iframe-scss.js.map +1 -1
  737. package/dist/es/plugin-html/tiptap/ai-widget-scss.js +4 -4
  738. package/dist/es/plugin-html/tiptap/ai-widget-scss.js.map +1 -1
  739. package/dist/es/plugin-html/tiptap/loader-scss.js +11 -11
  740. package/dist/es/plugin-html/tiptap/loader-scss.js.map +1 -1
  741. package/dist/es/plugin-html/tiptap/preset-bar/preset-bar-scss.js +4 -4
  742. package/dist/es/plugin-html/tiptap/preset-bar/preset-bar-scss.js.map +1 -1
  743. package/dist/es/plugin-html/viewer-styles-inject.js +2 -2
  744. package/dist/es/plugin-image/components/corner-radius-handles-scss.js +6 -6
  745. package/dist/es/plugin-image/components/corner-radius-handles-scss.js.map +1 -1
  746. package/dist/es/plugin-image/components/crop-edge-handles-scss.js +3 -3
  747. package/dist/es/plugin-image/components/crop-edge-handles-scss.js.map +1 -1
  748. package/dist/es/plugin-image/crop-overlay/crop-overlay-scss.js +16 -16
  749. package/dist/es/plugin-image/crop-overlay/crop-overlay-scss.js.map +1 -1
  750. package/dist/es/plugin-image/statics/styles/image-viewer-scss.js +20 -20
  751. package/dist/es/plugin-image/statics/styles/image-viewer-scss.js.map +1 -1
  752. package/dist/es/plugin-image/statics/styles/settings-modal-scss.js +3 -3
  753. package/dist/es/plugin-image/statics/styles/settings-modal-scss.js.map +1 -1
  754. package/dist/es/plugin-image/toolbar/shape-crop-modal-scss.js +6 -6
  755. package/dist/es/plugin-image/toolbar/shape-crop-modal-scss.js.map +1 -1
  756. package/dist/es/plugin-image/viewer-styles-inject.js +2 -2
  757. package/dist/es/plugin-inline-ai/ai-selection-tooltip-scss.js +12 -12
  758. package/dist/es/plugin-inline-ai/ai-selection-tooltip-scss.js.map +1 -1
  759. package/dist/es/plugin-inline-ai/aria-avatar-row-scss.js +3 -3
  760. package/dist/es/plugin-inline-ai/aria-avatar-row-scss.js.map +1 -1
  761. package/dist/es/plugin-inline-ai/aria-surface-row-scss.js +6 -6
  762. package/dist/es/plugin-inline-ai/aria-surface-row-scss.js.map +1 -1
  763. package/dist/es/plugin-inline-ai/html-placeholder-scss.js +5 -5
  764. package/dist/es/plugin-inline-ai/html-placeholder-scss.js.map +1 -1
  765. package/dist/es/plugin-inline-ai/modal-scss.js +11 -11
  766. package/dist/es/plugin-inline-ai/modal-scss.js.map +1 -1
  767. package/dist/es/plugin-inline-ai/pending-widget-placeholder-scss.js +14 -14
  768. package/dist/es/plugin-inline-ai/pending-widget-placeholder-scss.js.map +1 -1
  769. package/dist/es/plugin-inline-ai/spinner-scss.js +4 -4
  770. package/dist/es/plugin-inline-ai/spinner-scss.js.map +1 -1
  771. package/dist/es/plugin-inline-ai/toolbar/toolbar-button-scss.js +4 -4
  772. package/dist/es/plugin-inline-ai/toolbar/toolbar-button-scss.js.map +1 -1
  773. package/dist/es/plugin-line-spacing/custom-spacing-editor-modal/custom-spacing-editor-modal-scss.js +3 -3
  774. package/dist/es/plugin-line-spacing/custom-spacing-editor-modal/custom-spacing-editor-modal-scss.js.map +1 -1
  775. package/dist/es/plugin-link/editor.js +2 -2
  776. package/dist/es/plugin-link/editor.js.map +2 -2
  777. package/dist/es/plugin-link/statics/link-viewer-scss.js +4 -4
  778. package/dist/es/plugin-link/statics/link-viewer-scss.js.map +1 -1
  779. package/dist/es/plugin-link/toolbar/anchor-link-button-scss.js +3 -3
  780. package/dist/es/plugin-link/toolbar/anchor-link-button-scss.js.map +1 -1
  781. package/dist/es/plugin-link/viewer-styles-inject.js +2 -2
  782. package/dist/es/plugin-link-preview/statics/styles/insert-modal-scss.js +3 -3
  783. package/dist/es/plugin-link-preview/statics/styles/insert-modal-scss.js.map +1 -1
  784. package/dist/es/plugin-link-preview/statics/styles/link-preview-scss.js +18 -18
  785. package/dist/es/plugin-link-preview/statics/styles/link-preview-scss.js.map +1 -1
  786. package/dist/es/plugin-link-preview/statics/styles/settings-modal-scss.js +3 -3
  787. package/dist/es/plugin-link-preview/statics/styles/settings-modal-scss.js.map +1 -1
  788. package/dist/es/plugin-link-preview/viewer-styles-inject.js +3 -3
  789. package/dist/es/plugin-mentions/statics/mention-list-scss.js +6 -6
  790. package/dist/es/plugin-mentions/statics/mention-list-scss.js.map +1 -1
  791. package/dist/es/plugin-mentions/statics/mentions-scss.js +4 -4
  792. package/dist/es/plugin-mentions/statics/mentions-scss.js.map +1 -1
  793. package/dist/es/plugin-mentions/viewer-styles-inject.js +2 -2
  794. package/dist/es/plugin-paywall/paywall-fallback-scss.js +1 -1
  795. package/dist/es/plugin-paywall/paywall-fallback-scss.js.map +1 -1
  796. package/dist/es/plugin-paywall/plugin-paywall.js.map +2 -2
  797. package/dist/es/plugin-smart-block/components/cell-accessory-scss.js +22 -22
  798. package/dist/es/plugin-smart-block/components/cell-accessory-scss.js.map +1 -1
  799. package/dist/es/plugin-smart-block/components/cell-quote-glyph-scss.js +3 -3
  800. package/dist/es/plugin-smart-block/components/cell-quote-glyph-scss.js.map +1 -1
  801. package/dist/es/plugin-smart-block/components/cell-star-rating-scss.js +4 -4
  802. package/dist/es/plugin-smart-block/components/cell-star-rating-scss.js.map +1 -1
  803. package/dist/es/plugin-smart-block/components/cell-stat-scss.js +20 -20
  804. package/dist/es/plugin-smart-block/components/cell-stat-scss.js.map +1 -1
  805. package/dist/es/plugin-smart-block/components/circle-donut-scss.js +7 -7
  806. package/dist/es/plugin-smart-block/components/circle-donut-scss.js.map +1 -1
  807. package/dist/es/plugin-smart-block/components/shape-overlay-scss.js +3 -3
  808. package/dist/es/plugin-smart-block/components/shape-overlay-scss.js.map +1 -1
  809. package/dist/es/plugin-smart-block/components/smart-block-view-scss.js +50 -50
  810. package/dist/es/plugin-smart-block/components/smart-block-view-scss.js.map +1 -1
  811. package/dist/es/plugin-smart-block/components/stars-scss.js +8 -8
  812. package/dist/es/plugin-smart-block/components/stars-scss.js.map +1 -1
  813. package/dist/es/plugin-smart-block/modals/variant-picker-scss.js +9 -9
  814. package/dist/es/plugin-smart-block/modals/variant-picker-scss.js.map +1 -1
  815. package/dist/es/plugin-smart-block/tiptap/smart-block-editor-scss.js +15 -15
  816. package/dist/es/plugin-smart-block/tiptap/smart-block-editor-scss.js.map +1 -1
  817. package/dist/es/plugin-smart-block/viewer-styles-inject.js +2 -2
  818. package/dist/es/plugin-social-polls/components/image-upload/image-upload-scss.js +9 -9
  819. package/dist/es/plugin-social-polls/components/image-upload/image-upload-scss.js.map +1 -1
  820. package/dist/es/plugin-social-polls/components/insert-modal/insert-modal-scss.js +3 -3
  821. package/dist/es/plugin-social-polls/components/insert-modal/insert-modal-scss.js.map +1 -1
  822. package/dist/es/plugin-social-polls/components/poll-header/poll-header-scss.js +3 -3
  823. package/dist/es/plugin-social-polls/components/poll-header/poll-header-scss.js.map +1 -1
  824. package/dist/es/plugin-social-polls/components/poll-option/option-scss.js +23 -23
  825. package/dist/es/plugin-social-polls/components/poll-option/option-scss.js.map +1 -1
  826. package/dist/es/plugin-social-polls/components/poll-option/webview/option-webview-scss.js +24 -24
  827. package/dist/es/plugin-social-polls/components/poll-option/webview/option-webview-scss.js.map +1 -1
  828. package/dist/es/plugin-social-polls/components/poll-scss.js +19 -19
  829. package/dist/es/plugin-social-polls/components/poll-scss.js.map +1 -1
  830. package/dist/es/plugin-social-polls/components/settings-modal/settings-modal-scss.js +4 -4
  831. package/dist/es/plugin-social-polls/components/settings-modal/settings-modal-scss.js.map +1 -1
  832. package/dist/es/plugin-social-polls/components/text-field/text-field-scss.js +12 -12
  833. package/dist/es/plugin-social-polls/components/text-field/text-field-scss.js.map +1 -1
  834. package/dist/es/plugin-social-polls/components/voted-users/voted-users-scss.js +20 -20
  835. package/dist/es/plugin-social-polls/components/voted-users/voted-users-scss.js.map +1 -1
  836. package/dist/es/plugin-social-polls/viewer-styles-inject.js +2 -2
  837. package/dist/es/plugin-spoiler/get-text-buttons.js +2 -2
  838. package/dist/es/plugin-spoiler/get-text-buttons.js.map +2 -2
  839. package/dist/es/plugin-spoiler/statics/styles/spoiler-scss.js +18 -18
  840. package/dist/es/plugin-spoiler/statics/styles/spoiler-scss.js.map +1 -1
  841. package/dist/es/plugin-spoiler/viewer-styles-inject.js +2 -2
  842. package/dist/es/plugin-table/modals/table-grid-selector-scss.js +7 -7
  843. package/dist/es/plugin-table/modals/table-grid-selector-scss.js.map +1 -1
  844. package/dist/es/plugin-table/statics/styles/cell-scss.js +15 -15
  845. package/dist/es/plugin-table/statics/styles/cell-scss.js.map +1 -1
  846. package/dist/es/plugin-table/statics/styles/resizer-scss.js +20 -20
  847. package/dist/es/plugin-table/statics/styles/resizer-scss.js.map +1 -1
  848. package/dist/es/plugin-table/statics/styles/table-settings-modal-scss.js +3 -3
  849. package/dist/es/plugin-table/statics/styles/table-settings-modal-scss.js.map +1 -1
  850. package/dist/es/plugin-table/statics/styles/table-viewer-scss.js +6 -6
  851. package/dist/es/plugin-table/statics/styles/table-viewer-scss.js.map +1 -1
  852. package/dist/es/plugin-table/tiptap/decorations/tableHandles-scss.js +11 -11
  853. package/dist/es/plugin-table/tiptap/decorations/tableHandles-scss.js.map +1 -1
  854. package/dist/es/plugin-table/tiptap/plugins/table-scss.js +35 -35
  855. package/dist/es/plugin-table/tiptap/plugins/table-scss.js.map +1 -1
  856. package/dist/es/plugin-table/toolbar/modals/border-scope-selector-scss.js +4 -4
  857. package/dist/es/plugin-table/toolbar/modals/border-scope-selector-scss.js.map +1 -1
  858. package/dist/es/plugin-table/viewer-styles-inject.js +4 -4
  859. package/dist/es/plugin-text-color/sketch/text-highlight-button.js +2 -2
  860. package/dist/es/plugin-text-color/sketch/text-highlight-button.js.map +2 -2
  861. package/dist/es/plugin-text-color/text-button-color-scss.js +4 -4
  862. package/dist/es/plugin-text-color/text-button-color-scss.js.map +1 -1
  863. package/dist/es/plugin-toc/toc-view-scss.js +2 -2
  864. package/dist/es/plugin-toc/toc-view-scss.js.map +1 -1
  865. package/dist/es/plugin-toc/viewer-styles-inject.js +2 -2
  866. package/dist/es/plugin-vertical-embed/components/Ribbon-scss.js +3 -3
  867. package/dist/es/plugin-vertical-embed/components/Ribbon-scss.js.map +1 -1
  868. package/dist/es/plugin-vertical-embed/components/card-content-scss.js +23 -23
  869. package/dist/es/plugin-vertical-embed/components/card-content-scss.js.map +1 -1
  870. package/dist/es/plugin-vertical-embed/components/card-scss.js +19 -19
  871. package/dist/es/plugin-vertical-embed/components/card-scss.js.map +1 -1
  872. package/dist/es/plugin-vertical-embed/components/description-scss.js +2 -2
  873. package/dist/es/plugin-vertical-embed/components/description-scss.js.map +1 -1
  874. package/dist/es/plugin-vertical-embed/modals/settings-modal-scss.js +4 -4
  875. package/dist/es/plugin-vertical-embed/modals/settings-modal-scss.js.map +1 -1
  876. package/dist/es/plugin-vertical-embed/tiptap/component-scss.js +12 -12
  877. package/dist/es/plugin-vertical-embed/tiptap/component-scss.js.map +1 -1
  878. package/dist/es/plugin-vertical-embed/toolbar/items-list-scss.js +3 -3
  879. package/dist/es/plugin-vertical-embed/toolbar/items-list-scss.js.map +1 -1
  880. package/dist/es/plugin-vertical-embed/viewer/vertical-embed-viewer-scss.js +6 -6
  881. package/dist/es/plugin-vertical-embed/viewer/vertical-embed-viewer-scss.js.map +1 -1
  882. package/dist/es/plugin-vertical-embed/viewer-styles-inject.js +3 -3
  883. package/dist/es/plugin-video/statics/styles/default-video-styles-scss.js +10 -10
  884. package/dist/es/plugin-video/statics/styles/default-video-styles-scss.js.map +1 -1
  885. package/dist/es/plugin-video/statics/styles/video-viewer-scss.js +3 -3
  886. package/dist/es/plugin-video/statics/styles/video-viewer-scss.js.map +1 -1
  887. package/dist/es/plugin-video/toolbar/embed-video-scss.js +3 -3
  888. package/dist/es/plugin-video/toolbar/embed-video-scss.js.map +1 -1
  889. package/dist/es/plugin-video/viewer-styles-inject.js +2 -2
  890. package/dist/es/ricos-common-plugins/bold/extension.js +1 -2
  891. package/dist/es/ricos-common-plugins/bold/extension.js.map +2 -2
  892. package/dist/es/ricos-common-plugins/decoration-plugins/list-item-sizing.js +13 -1
  893. package/dist/es/ricos-common-plugins/decoration-plugins/list-item-sizing.js.map +2 -2
  894. package/dist/es/ricos-common-plugins/font-size/block-font-size-plugin.js +2 -1
  895. package/dist/es/ricos-common-plugins/font-size/block-font-size-plugin.js.map +2 -2
  896. package/dist/es/ricos-common-plugins/font-size/dropdown/font-size-dropdown-scss.js +3 -3
  897. package/dist/es/ricos-common-plugins/font-size/dropdown/font-size-dropdown-scss.js.map +1 -1
  898. package/dist/es/ricos-common-plugins/gap-spacer/gap-spacer-component/gap-spacer-styles-scss.js +10 -10
  899. package/dist/es/ricos-common-plugins/gap-spacer/gap-spacer-component/gap-spacer-styles-scss.js.map +1 -1
  900. package/dist/es/ricos-common-plugins/layout/layouts-scss.js +35 -35
  901. package/dist/es/ricos-common-plugins/layout/layouts-scss.js.map +1 -1
  902. package/dist/es/ricos-common-plugins/layout/paywall-toolbar-button.js +74 -0
  903. package/dist/es/ricos-common-plugins/layout/paywall-toolbar-button.js.map +7 -0
  904. package/dist/es/ricos-common-plugins/layout/plugin-layout.js +178 -173
  905. package/dist/es/ricos-common-plugins/layout/plugin-layout.js.map +2 -2
  906. package/dist/es/ricos-common-plugins/layout/section-dividers/section-dividers-panel-scss.js +4 -4
  907. package/dist/es/ricos-common-plugins/layout/section-dividers/section-dividers-panel-scss.js.map +1 -1
  908. package/dist/es/ricos-common-plugins/layout/section-dividers/section-dividers-scss.js +6 -6
  909. package/dist/es/ricos-common-plugins/layout/section-dividers/section-dividers-scss.js.map +1 -1
  910. package/dist/es/ricos-common-plugins/list-item/extension.js +9 -0
  911. package/dist/es/ricos-common-plugins/list-item/extension.js.map +2 -2
  912. package/dist/es/ricos-common-plugins/list-item/list-converters.js +5 -3
  913. package/dist/es/ricos-common-plugins/list-item/list-converters.js.map +2 -2
  914. package/dist/es/ricos-common-plugins/list-item/list-marker-selection.js +274 -0
  915. package/dist/es/ricos-common-plugins/list-item/list-marker-selection.js.map +7 -0
  916. package/dist/es/ricos-common-plugins/quick-actions/modal/modal-scss.js +4 -4
  917. package/dist/es/ricos-common-plugins/quick-actions/modal/modal-scss.js.map +1 -1
  918. package/dist/es/ricos-common-plugins/statics/styles-scss.js +20 -20
  919. package/dist/es/ricos-common-plugins/statics/styles-scss.js.map +1 -1
  920. package/dist/es/ricos-common-plugins/strikethrough/strikethrough.js +2 -2
  921. package/dist/es/ricos-common-plugins/strikethrough/strikethrough.js.map +2 -2
  922. package/dist/es/ricos-common-plugins/strikethrough/strikethrough.testkit.js +1 -0
  923. package/dist/es/ricos-common-plugins/strikethrough/strikethrough.testkit.js.map +2 -2
  924. package/dist/es/ricos-common-plugins/title/headings-scss.js +10 -10
  925. package/dist/es/ricos-common-plugins/title/headings-scss.js.map +1 -1
  926. package/dist/es/ricos-common-plugins/underline/underline.js +2 -2
  927. package/dist/es/ricos-common-plugins/underline/underline.js.map +2 -2
  928. package/dist/es/ricos-editor/statics/styles/editor-styles-scss.js +11 -11
  929. package/dist/es/ricos-editor/statics/styles/editor-styles-scss.js.map +1 -1
  930. package/dist/es/ricos-modals/statics/styles/drawer-scss.js +11 -11
  931. package/dist/es/ricos-modals/statics/styles/drawer-scss.js.map +1 -1
  932. package/dist/es/ricos-modals/statics/styles/fullscreen-scss.js +3 -3
  933. package/dist/es/ricos-modals/statics/styles/fullscreen-scss.js.map +1 -1
  934. package/dist/es/ricos-modals/statics/styles/popper-scss.js +5 -5
  935. package/dist/es/ricos-modals/statics/styles/popper-scss.js.map +1 -1
  936. package/dist/es/ricos-schema/next-schema/version.js +1 -1
  937. package/dist/es/ricos-schema/next-schema/version.js.map +1 -1
  938. package/dist/es/ricos-styles/statics/styles/style-presets-scss.js +8 -8
  939. package/dist/es/ricos-styles/statics/styles/style-presets-scss.js.map +1 -1
  940. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/blockquote/blockquote-scss.js +3 -3
  941. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/blockquote/blockquote-scss.js.map +1 -1
  942. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/codeblock/codeblock-scss.js +3 -3
  943. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/codeblock/codeblock-scss.js.map +1 -1
  944. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/heading/heading-scss.js +9 -9
  945. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/heading/heading-scss.js.map +1 -1
  946. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/layout/layout-scss.js +10 -10
  947. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/layout/layout-scss.js.map +1 -1
  948. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/lists/list-item.js +10 -1
  949. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/lists/list-item.js.map +2 -2
  950. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/lists/lists-scss.js +6 -6
  951. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/lists/lists-scss.js.map +1 -1
  952. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/paragraph/paragraph-scss.js +4 -4
  953. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/paragraph/paragraph-scss.js.map +1 -1
  954. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/plugins/link-viewer-wrapper-scss.js +2 -2
  955. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/plugins/link-viewer-wrapper-scss.js.map +1 -1
  956. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/plugins/plugin-scss.js +15 -15
  957. package/dist/es/ricos-viewer-next/ContentViewer/rericos/renderers/plugins/plugin-scss.js.map +1 -1
  958. package/dist/es/ricos-viewer-next/modals/fullscreen/fullscreen-scss.js +14 -14
  959. package/dist/es/ricos-viewer-next/modals/fullscreen/fullscreen-scss.js.map +1 -1
  960. package/dist/es/ricos-viewer-next/statics/alignment-scss.js +16 -16
  961. package/dist/es/ricos-viewer-next/statics/alignment-scss.js.map +1 -1
  962. package/dist/es/ricos-viewer-next/statics/indentation-scss.js +7 -7
  963. package/dist/es/ricos-viewer-next/statics/indentation-scss.js.map +1 -1
  964. package/dist/es/ricos-viewer-next/statics/rich-content-viewer-scss.js +9 -9
  965. package/dist/es/ricos-viewer-next/statics/rich-content-viewer-scss.js.map +1 -1
  966. package/dist/es/ricos-viewer-next/statics/rtl-scss.js +2 -2
  967. package/dist/es/ricos-viewer-next/statics/rtl-scss.js.map +1 -1
  968. package/dist/es/text-selection-toolbar/statics/styles/viewer-inline-toolbar-scss.js +4 -4
  969. package/dist/es/text-selection-toolbar/statics/styles/viewer-inline-toolbar-scss.js.map +1 -1
  970. package/dist/es/tiptap/core/editor.js +5 -2
  971. package/dist/es/tiptap/core/editor.js.map +2 -2
  972. package/dist/es/tiptap-editor/statics/styles/tiptap-editor-styles-scss.js +15 -15
  973. package/dist/es/tiptap-editor/statics/styles/tiptap-editor-styles-scss.js.map +1 -1
  974. package/dist/es/tiptap-extensions/placeholder-scss.js +3 -3
  975. package/dist/es/tiptap-extensions/placeholder-scss.js.map +1 -1
  976. package/dist/es/tiptap-extensions/statics/styles-scss.js +6 -6
  977. package/dist/es/tiptap-extensions/statics/styles-scss.js.map +1 -1
  978. package/dist/es/toolbars-v3/components/InsertPluginToolbar/insert-plugin-toolbar-scss.js +3 -3
  979. package/dist/es/toolbars-v3/components/InsertPluginToolbar/insert-plugin-toolbar-scss.js.map +1 -1
  980. package/dist/es/toolbars-v3/components/MaxWidthCalculationWrapper/max-width-calculation-wrapper.js +2 -1
  981. package/dist/es/toolbars-v3/components/MaxWidthCalculationWrapper/max-width-calculation-wrapper.js.map +2 -2
  982. package/dist/es/toolbars-v3/components/Toolbar/RicosDesktopToolbar/OverflownButtons-scss.js +5 -5
  983. package/dist/es/toolbars-v3/components/Toolbar/RicosDesktopToolbar/OverflownButtons-scss.js.map +1 -1
  984. package/dist/es/toolbars-v3/components/Toolbar/RicosDesktopToolbar/RicosDesktopToolbar-scss.js +5 -5
  985. package/dist/es/toolbars-v3/components/Toolbar/RicosDesktopToolbar/RicosDesktopToolbar-scss.js.map +1 -1
  986. package/dist/es/toolbars-v3/components/Toolbar/RicosDesktopToolbar/RicosDesktopToolbarWrapper-scss.js +6 -6
  987. package/dist/es/toolbars-v3/components/Toolbar/RicosDesktopToolbar/RicosDesktopToolbarWrapper-scss.js.map +1 -1
  988. package/dist/es/toolbars-v3/components/Toolbar/RicosMobileToolbar/RicosMobileToolbar-scss.js +11 -11
  989. package/dist/es/toolbars-v3/components/Toolbar/RicosMobileToolbar/RicosMobileToolbar-scss.js.map +1 -1
  990. package/dist/es/toolbars-v3/components/Toolbar/RicosMobileToolbar/mobile-toolbar-overlay/mobile-toolbar-overlay-scss.js +3 -3
  991. package/dist/es/toolbars-v3/components/Toolbar/RicosMobileToolbar/mobile-toolbar-overlay/mobile-toolbar-overlay-scss.js.map +1 -1
  992. package/dist/es/toolbars-v3/components/buttons/AddPluginMenuButtons/AddPluginMenuMobileButton-scss.js +5 -5
  993. package/dist/es/toolbars-v3/components/buttons/AddPluginMenuButtons/AddPluginMenuMobileButton-scss.js.map +1 -1
  994. package/dist/es/toolbars-v3/components/buttons/FontSizeButton/FontSizeButton-scss.js +7 -7
  995. package/dist/es/toolbars-v3/components/buttons/FontSizeButton/FontSizeButton-scss.js.map +1 -1
  996. package/dist/es/toolbars-v3/modals/FloatingPluginMenu/styles/floating-add-plugin-menu-scss.js +8 -8
  997. package/dist/es/toolbars-v3/modals/FloatingPluginMenu/styles/floating-add-plugin-menu-scss.js.map +1 -1
  998. package/dist/es/toolbars-v3/ricos-toolbars/footer/FooterToolbar-scss.js +3 -3
  999. package/dist/es/toolbars-v3/ricos-toolbars/footer/FooterToolbar-scss.js.map +1 -1
  1000. package/dist/es/toolbars-v3/ricos-toolbars/formatting/use-is-visible.js +4 -0
  1001. package/dist/es/toolbars-v3/ricos-toolbars/formatting/use-is-visible.js.map +2 -2
  1002. package/dist/es/ui-components/Components/Image-scss.js +3 -3
  1003. package/dist/es/ui-components/Components/Image-scss.js.map +1 -1
  1004. package/dist/es/ui-components/Components/double-loader-scss.js +6 -6
  1005. package/dist/es/ui-components/Components/double-loader-scss.js.map +1 -1
  1006. package/dist/es/ui-components/color-picker/button-color-swatches/button-color-swatches-scss.js +4 -4
  1007. package/dist/es/ui-components/color-picker/button-color-swatches/button-color-swatches-scss.js.map +1 -1
  1008. package/dist/es/ui-components/color-picker/new-color-picker/components/gradient-picker/gradient-picker-scss.js +15 -15
  1009. package/dist/es/ui-components/color-picker/new-color-picker/components/gradient-picker/gradient-picker-scss.js.map +1 -1
  1010. package/dist/es/ui-components/color-picker/new-color-picker/components/new-color-swatches/new-color-swatches-scss.js +3 -3
  1011. package/dist/es/ui-components/color-picker/new-color-picker/components/new-color-swatches/new-color-swatches-scss.js.map +1 -1
  1012. package/dist/es/ui-components/color-picker/new-color-picker/components/simple-color-picker/simple-color-picker-scss.js +4 -4
  1013. package/dist/es/ui-components/color-picker/new-color-picker/components/simple-color-picker/simple-color-picker-scss.js.map +1 -1
  1014. package/dist/es/ui-components/color-picker/new-color-picker/components/single-color-swatch/single-color-swatch-scss.js +4 -4
  1015. package/dist/es/ui-components/color-picker/new-color-picker/components/single-color-swatch/single-color-swatch-scss.js.map +1 -1
  1016. package/dist/es/ui-components/color-picker/new-color-picker/new-color-picker-scss.js +3 -3
  1017. package/dist/es/ui-components/color-picker/new-color-picker/new-color-picker-scss.js.map +1 -1
  1018. package/dist/es/ui-components/input-with-slider/input-with-slider-scss.js +3 -3
  1019. package/dist/es/ui-components/input-with-slider/input-with-slider-scss.js.map +1 -1
  1020. package/dist/es/ui-components/layout-background-loader/layout-background-loader-scss.js +5 -5
  1021. package/dist/es/ui-components/layout-background-loader/layout-background-loader-scss.js.map +1 -1
  1022. package/dist/es/ui-components/modal-layout/floating-layout/floating-desktop-layout-scss.js +3 -3
  1023. package/dist/es/ui-components/modal-layout/floating-layout/floating-desktop-layout-scss.js.map +1 -1
  1024. package/dist/es/ui-components/modal-layout/fullscreen-mobile-layout/fullscreen-mobile-layout-scss.js +6 -6
  1025. package/dist/es/ui-components/modal-layout/fullscreen-mobile-layout/fullscreen-mobile-layout-scss.js.map +1 -1
  1026. package/dist/es/ui-components/panel/panel-scss.js +4 -4
  1027. package/dist/es/ui-components/panel/panel-scss.js.map +1 -1
  1028. package/dist/es/ui-components/panel-header/panel-header-scss.js +3 -3
  1029. package/dist/es/ui-components/panel-header/panel-header-scss.js.map +1 -1
  1030. package/dist/es/ui-components/settings-panel-discard-modal/settings-panel-discard-modal-scss.js +3 -3
  1031. package/dist/es/ui-components/settings-panel-discard-modal/settings-panel-discard-modal-scss.js.map +1 -1
  1032. package/dist/es/ui-components/statics/styles/generic-error-scss.js +3 -3
  1033. package/dist/es/ui-components/statics/styles/generic-error-scss.js.map +1 -1
  1034. package/dist/es/ui-components/statics/styles/loaders-scss.js +10 -10
  1035. package/dist/es/ui-components/statics/styles/loaders-scss.js.map +1 -1
  1036. package/dist/es/ui-components/statics/styles/media-item-error-msg-scss.js +5 -5
  1037. package/dist/es/ui-components/statics/styles/media-item-error-msg-scss.js.map +1 -1
  1038. package/dist/es/ui-components/statics/styles/slider-scss.js +9 -9
  1039. package/dist/es/ui-components/statics/styles/slider-scss.js.map +1 -1
  1040. package/dist/es/ui-components/thumbnail-picker/thumbnail-picker-scss.js +3 -3
  1041. package/dist/es/ui-components/thumbnail-picker/thumbnail-picker-scss.js.map +1 -1
  1042. package/dist/es/ui-components/wixel-assistant/assistant-timeline-scss.js +18 -18
  1043. package/dist/es/ui-components/wixel-assistant/assistant-timeline-scss.js.map +1 -1
  1044. package/dist/es/wix-rich-content-common/statics/styles/fonts-scss.js +3 -3
  1045. package/dist/es/wix-rich-content-common/statics/styles/fonts-scss.js.map +1 -1
  1046. package/dist/es/wix-rich-content-common/statics/styles/general-scss.js +13 -13
  1047. package/dist/es/wix-rich-content-common/statics/styles/general-scss.js.map +1 -1
  1048. package/dist/src/_shared/editor-base-url/editor-base-url-context.d.ts.map +1 -1
  1049. package/dist/src/_shared/font-weight.d.ts +3 -0
  1050. package/dist/src/_shared/font-weight.d.ts.map +1 -0
  1051. package/dist/src/_shared/get-all-plugin-testkits.d.ts +1 -0
  1052. package/dist/src/_shared/get-all-plugin-testkits.d.ts.map +1 -1
  1053. package/dist/src/_shared/get-common-marker-style.d.ts +3 -0
  1054. package/dist/src/_shared/get-common-marker-style.d.ts.map +1 -0
  1055. package/dist/src/_shared/get-common-marker-style.spec.d.ts +2 -0
  1056. package/dist/src/_shared/get-common-marker-style.spec.d.ts.map +1 -0
  1057. package/dist/src/_shared/get-decorations-marker-style.d.ts +4 -0
  1058. package/dist/src/_shared/get-decorations-marker-style.d.ts.map +1 -0
  1059. package/dist/src/_shared/get-decorations-marker-style.spec.d.ts +2 -0
  1060. package/dist/src/_shared/get-decorations-marker-style.spec.d.ts.map +1 -0
  1061. package/dist/src/_shared/get-list-marker-style.d.ts +3 -0
  1062. package/dist/src/_shared/get-list-marker-style.d.ts.map +1 -0
  1063. package/dist/src/_shared/get-list-marker-style.spec.d.ts +2 -0
  1064. package/dist/src/_shared/get-list-marker-style.spec.d.ts.map +1 -0
  1065. package/dist/src/_shared/plugin-toolbar/create-settings-button.d.ts +2 -2
  1066. package/dist/src/_shared/plugin-toolbar/create-settings-button.d.ts.map +1 -1
  1067. package/dist/src/_shared/pm-node-types.d.ts +2 -1
  1068. package/dist/src/_shared/pm-node-types.d.ts.map +1 -1
  1069. package/dist/src/_shared/site-pages/site-pages-fetch-context/use-fetch-site-pages.d.ts +2 -0
  1070. package/dist/src/_shared/site-pages/site-pages-fetch-context/use-fetch-site-pages.d.ts.map +1 -1
  1071. package/dist/src/_shared/site-pages/site-pages-fetch-context/use-fetch-site-pages.spec.d.ts +2 -0
  1072. package/dist/src/_shared/site-pages/site-pages-fetch-context/use-fetch-site-pages.spec.d.ts.map +1 -0
  1073. package/dist/src/_shared/site-pages/site-pages-fetch-context.d.ts.map +1 -1
  1074. package/dist/src/_shared/site-pages/types.d.ts +24 -2
  1075. package/dist/src/_shared/site-pages/types.d.ts.map +1 -1
  1076. package/dist/src/index.d.ts +3 -2
  1077. package/dist/src/index.d.ts.map +1 -1
  1078. package/dist/src/internal.d.ts +1 -1
  1079. package/dist/src/internal.d.ts.map +1 -1
  1080. package/dist/src/legacy.d.ts +1 -1
  1081. package/dist/src/legacy.d.ts.map +1 -1
  1082. package/dist/src/plugin-block-drag-handle/box-select.d.ts +1 -0
  1083. package/dist/src/plugin-block-drag-handle/box-select.d.ts.map +1 -1
  1084. package/dist/src/plugin-block-drag-handle/dom.d.ts +1 -0
  1085. package/dist/src/plugin-block-drag-handle/dom.d.ts.map +1 -1
  1086. package/dist/src/plugin-block-drag-handle/plugin.d.ts.map +1 -1
  1087. package/dist/src/plugin-card/card-node-view.d.ts +3 -1
  1088. package/dist/src/plugin-card/card-node-view.d.ts.map +1 -1
  1089. package/dist/src/plugin-card/card-node-view.spec.d.ts +3 -0
  1090. package/dist/src/plugin-card/card-node-view.spec.d.ts.map +1 -0
  1091. package/dist/src/plugin-card/extension.d.ts.map +1 -1
  1092. package/dist/src/plugin-card/index.d.ts +1 -1
  1093. package/dist/src/plugin-card/index.d.ts.map +1 -1
  1094. package/dist/src/plugin-card/page-gap.d.ts +3 -0
  1095. package/dist/src/plugin-card/page-gap.d.ts.map +1 -1
  1096. package/dist/src/plugin-card/types-next.d.ts +12 -0
  1097. package/dist/src/plugin-card/types-next.d.ts.map +1 -1
  1098. package/dist/src/plugin-card/types.d.ts +12 -0
  1099. package/dist/src/plugin-card/types.d.ts.map +1 -1
  1100. package/dist/src/plugin-link/editor.d.ts.map +1 -1
  1101. package/dist/src/plugin-paywall/plugin-paywall.d.ts +27 -0
  1102. package/dist/src/plugin-paywall/plugin-paywall.d.ts.map +1 -1
  1103. package/dist/src/plugin-spoiler/get-text-buttons.d.ts.map +1 -1
  1104. package/dist/src/plugin-text-color/sketch/text-highlight-button.d.ts.map +1 -1
  1105. package/dist/src/ricos-common-plugins/bold/extension.d.ts.map +1 -1
  1106. package/dist/src/ricos-common-plugins/decoration-plugins/list-item-sizing.d.ts +9 -7
  1107. package/dist/src/ricos-common-plugins/decoration-plugins/list-item-sizing.d.ts.map +1 -1
  1108. package/dist/src/ricos-common-plugins/font-size/block-font-size-plugin.d.ts.map +1 -1
  1109. package/dist/src/ricos-common-plugins/layout/paywall-toolbar-button.d.ts +6 -0
  1110. package/dist/src/ricos-common-plugins/layout/paywall-toolbar-button.d.ts.map +1 -0
  1111. package/dist/src/ricos-common-plugins/layout/paywall-toolbar-button.spec.d.ts +2 -0
  1112. package/dist/src/ricos-common-plugins/layout/paywall-toolbar-button.spec.d.ts.map +1 -0
  1113. package/dist/src/ricos-common-plugins/layout/plugin-layout.d.ts.map +1 -1
  1114. package/dist/src/ricos-common-plugins/list-item/extension.d.ts.map +1 -1
  1115. package/dist/src/ricos-common-plugins/list-item/list-converters.d.ts.map +1 -1
  1116. package/dist/src/ricos-common-plugins/list-item/list-marker-selection.d.ts +25 -0
  1117. package/dist/src/ricos-common-plugins/list-item/list-marker-selection.d.ts.map +1 -0
  1118. package/dist/src/ricos-common-plugins/list-item/list-marker-selection.spec.d.ts +2 -0
  1119. package/dist/src/ricos-common-plugins/list-item/list-marker-selection.spec.d.ts.map +1 -0
  1120. package/dist/src/ricos-common-plugins/strikethrough/strikethrough.testkit.d.ts +1 -0
  1121. package/dist/src/ricos-common-plugins/strikethrough/strikethrough.testkit.d.ts.map +1 -1
  1122. package/dist/src/ricos-common-plugins/testkit.d.ts +1 -0
  1123. package/dist/src/ricos-common-plugins/testkit.d.ts.map +1 -1
  1124. package/dist/src/ricos-schema/next-schema/version.d.ts +1 -1
  1125. package/dist/src/ricos-styles/tests/test-cases.d.ts +3 -3
  1126. package/dist/src/ricos-types/next/ricos-types.d.ts +1 -1
  1127. package/dist/src/ricos-types/ricos-types.d.ts +1 -1
  1128. package/dist/src/ricos-viewer-next/ContentViewer/rericos/renderers/lists/list-item.d.ts.map +1 -1
  1129. package/dist/src/testkit.d.ts +2 -0
  1130. package/dist/src/testkit.d.ts.map +1 -1
  1131. package/dist/src/tiptap/core/editor.d.ts.map +1 -1
  1132. package/dist/src/toolbars-v3/components/MaxWidthCalculationWrapper/max-width-calculation-wrapper.d.ts.map +1 -1
  1133. package/dist/src/toolbars-v3/components/MaxWidthCalculationWrapper/max-width-calculation-wrapper.spec.d.ts +2 -0
  1134. package/dist/src/toolbars-v3/components/MaxWidthCalculationWrapper/max-width-calculation-wrapper.spec.d.ts.map +1 -0
  1135. package/dist/src/toolbars-v3/ricos-toolbars/formatting/use-is-visible.d.ts.map +1 -1
  1136. package/generated/public.d.ts +54 -1
  1137. package/package.json +6 -6
  1138. package/dist/cjs/_shared/site-pages/serverless-types/serverless-types.js.map +0 -7
  1139. package/dist/es/_shared/site-pages/serverless-types/serverless-types.js +0 -1
  1140. package/dist/es/_shared/site-pages/serverless-types/serverless-types.js.map +0 -7
  1141. package/dist/src/_shared/site-pages/serverless-types/serverless-types.d.ts +0 -27
  1142. package/dist/src/_shared/site-pages/serverless-types/serverless-types.d.ts.map +0 -1
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/plugin-block-drag-handle/plugin.ts"],
4
- "sourcesContent": ["import {\n TIPTAP_COLLAPSIBLE_ITEM_TYPE,\n TIPTAP_COLLAPSIBLE_LIST_TYPE,\n TIPTAP_LAYOUT_CELL_TYPE,\n TIPTAP_LAYOUT_TYPE,\n TIPTAP_TABLE_TYPE,\n} from './../ricos-content/index.js';\nimport type { RicosExtension, TFunction } from './../ricos-types/index.js';\nimport { dragDropInsertPos } from './../_shared/drag-drop-insert-pos.js';\nimport type { Node as PmNode, ResolvedPos } from './../tiptap/pm/model.js';\nimport type { EditorState, Selection, Transaction } from './../tiptap/pm/state.js';\nimport { NodeSelection, Plugin } from './../tiptap/pm/state.js';\nimport type { EditorView } from './../tiptap/pm/view.js';\nimport { Decoration, DecorationSet } from './../tiptap/pm/view.js';\n\nimport { isBannerLayout } from '../ricos-common-plugins/layout/banner-drop-prevention-plugin.js';\nimport { type BoxSelectCallbacks, cancelActiveBoxSelect, startBoxSelect } from './box-select.js';\nimport {\n type HandleElementOptions,\n createHandleElement,\n destroyHandleElement,\n getBlockPosFromHandleUnderPointer,\n getScrollParent,\n getViewScale,\n isPointerInBlockHoverRect,\n isPointerInHandleGutter,\n remeasureHandleElements,\n} from './dom.js';\nimport {\n clearDraggingPositions,\n getDraggingPositions,\n isHandleDragActive,\n isHandleDragCancelled,\n mapDraggingPositions,\n} from './drag-state.js';\nimport {\n createBlockDragDropTransaction,\n findReorderBlocksAtCoords,\n isBlockDragHandleDrop,\n resolveHandleDrop,\n safePosAtCoords,\n setCaretInsideDroppedNode,\n} from './drop.js';\nimport { buildDragGhost } from './ghost.js';\nimport { hasBlockAtY, isPointerInAnyBlockHandleZone } from './gutter.js';\nimport {\n type BlockDragHandleState,\n blockDragHandlePluginKey,\n emptyState,\n getPluginState,\n setHoveredPos,\n} from './plugin-key.js';\nimport {\n deselectAllBlocks,\n findNeutralSelectionNear,\n getContiguousRange,\n isCardChromeNode,\n isDomInsideTable,\n isEmptyTextBlock,\n isReorderContainerNode,\n isSelectionInsideTable,\n mapSelectedPositionsThroughTransaction,\n normalizeSelectBox,\n sameSelectBox,\n selectBlocks,\n} from './selection.js';\nimport styles from './styles-scss.js';\n\n// The reorderable block(s) adjacent to a resolved coordinate: the block containing it,\n// or — when the coordinate sits exactly on a container boundary — the blocks on both\n// sides. The reorderable block is the child of the nearest reorder container (the doc,\n// or a card's content section in the card model) — the walk steps past the page chrome,\n// and a coordinate inside non-reorderable chrome (a card's header or footer) yields no\n// candidates at all.\nconst resolveReorderCandidates = (\n $pos: ResolvedPos,\n coordPos: number\n): { pos: number; node: PmNode }[] => {\n for (let d = 1; d <= $pos.depth; d++) {\n const node = $pos.node(d);\n if (isReorderContainerNode($pos.node(d - 1)) && !isCardChromeNode(node)) {\n return [{ pos: $pos.before(d), node }];\n }\n if (!isCardChromeNode(node)) {\n return [];\n }\n }\n if (!isReorderContainerNode($pos.parent)) {\n return [];\n }\n return [\n $pos.nodeBefore ? { pos: coordPos - $pos.nodeBefore.nodeSize, node: $pos.nodeBefore } : null,\n $pos.nodeAfter ? { pos: coordPos, node: $pos.nodeAfter } : null,\n ].filter((c): c is { pos: number; node: PmNode } => c !== null && !isCardChromeNode(c.node));\n};\n\nconst resolveHoveredBlockPos = (\n view: EditorView,\n clientX: number,\n clientY: number\n): number | null => {\n const coordResult = safePosAtCoords(view, clientX, clientY);\n\n if (coordResult) {\n const isRtl = getComputedStyle(view.dom).direction === 'rtl';\n const scale = getViewScale(view);\n const $pos = view.state.doc.resolve(coordResult.pos);\n for (const { pos } of resolveReorderCandidates($pos, coordResult.pos)) {\n const dom = view.nodeDOM(pos);\n if (\n dom instanceof HTMLElement &&\n isPointerInBlockHoverRect(dom, clientX, clientY, isRtl, scale)\n ) {\n return pos;\n }\n }\n }\n\n return findReorderBlocksAtCoords(view, clientX, clientY)[0] ?? null;\n};\n\nconst samePositions = (a: number[], b: number[]): boolean =>\n a.length === b.length && a.every((pos, i) => pos === b[i]);\n\nconst setPluginState = (view: EditorView, next: BlockDragHandleState): void => {\n const current = getPluginState(view);\n if (\n current.hoveredPos === next.hoveredPos &&\n samePositions(current.selectedPositions, next.selectedPositions) &&\n sameSelectBox(current.selectionBox, next.selectionBox)\n ) {\n return;\n }\n view.dispatch(view.state.tr.setMeta(blockDragHandlePluginKey, next));\n};\n\n// Comfortably past the 200ms settle animation, so clearing never cuts it short.\nconst DROP_SETTLE_CLEAR_MS = 400;\n\n// Retires the settle class once its one-shot animation has played, so a later redraw\n// of the same node doesn't replay the pop. Reference-guarded: newer state wins.\nconst scheduleDropSettleRetire = (view: EditorView, droppedPositions: number[]): void => {\n window.setTimeout(() => {\n if (view.isDestroyed) {\n return;\n }\n const current = getPluginState(view);\n if (current.droppedPositions === droppedPositions) {\n view.dispatch(\n view.state.tr.setMeta(blockDragHandlePluginKey, { ...current, droppedPositions: null })\n );\n }\n }, DROP_SETTLE_CLEAR_MS);\n};\n\nconst getMultiSelectHandlePos = (selectedPositions: number[]): number | null =>\n selectedPositions.length > 1 ? selectedPositions[0] : null;\n\n/** Position of the collapsible list enclosing the selection, or null. */\nconst getEnclosingCollapsibleListPos = (selection: Selection): number | null => {\n const $from = selection.$from;\n for (let d = $from.depth; d >= 1; d--) {\n if ($from.node(d).type.name === TIPTAP_COLLAPSIBLE_LIST_TYPE) {\n return $from.before(d);\n }\n }\n return null;\n};\n\n// Cheap fingerprint of everything the decorations read off the selection, so they\n// rebuild on selection-only transactions (which keep the same plugin-state object and\n// would otherwise hit a stale cache entry). Inputs: NodeSelection identity (drives the\n// selected ring), and which collapsible list the caret sits inside (drives the\n// focused-list grip yield in getHandlePositions).\nconst getSelectionDecorationKey = (selection: Selection): string => {\n const nodeSelectionKey = selection instanceof NodeSelection ? `node:${selection.from}` : '';\n const focusedListPos = getEnclosingCollapsibleListPos(selection);\n return `${nodeSelectionKey}|${focusedListPos !== null ? `collapsible:${focusedListPos}` : ''}`;\n};\n\n/**\n * Read-only editors reach every handler in this plugin: ProseMirror runs\n * `handleDOMEvents` through `runCustomHandler`, which fires *before* — and\n * independently of — the `view.editable` gate that guards its own built-in handlers. So\n * without this check a read-only editor still grows grips, box-selects, and (via the\n * custom drop path) dispatches document-changing transactions into consumer persistence.\n */\nconst isEditable = (view: EditorView): boolean => view.editable;\n\n// A banner layout is pinned to its slot — `filterTransaction` in\n// banner-drop-prevention-plugin rejects any transaction that moves one — so a grip on a\n// banner could only ever start a drag whose drop is silently discarded. Don't offer it.\nconst filterBannerLayoutHandles = (doc: PmNode, positions: number[]): number[] =>\n positions.filter(pos => {\n const node = doc.nodeAt(pos);\n return !node || !isBannerLayout(node);\n });\n\nexport const getHandlePositions = (\n doc: PmNode,\n selection: Selection,\n hoveredPos: number | null,\n selectedPositions: number[],\n pinnedDragPositions: number[] | null\n): number[] => {\n if (pinnedDragPositions?.length) {\n const pos = pinnedDragPositions[0];\n if (doc.nodeAt(pos)) {\n return filterBannerLayoutHandles(doc, [pos]);\n }\n }\n // While the caret is inside a collapsible list, the list's own per-item DndIcons are\n // the reorder affordance (they render on exactly this condition — see the\n // isInCollapsibleList gate in CollapsibleListItem), and the whole-list grip's gutter\n // slot collides with the first item's icon. Yield the grip; it returns as soon as\n // focus leaves the list. A NodeSelection ON the list is \"the list is selected\", not\n // \"editing inside it\" (selection.from equals the list position, not a position\n // strictly inside), so grip-click selection keeps its grip.\n const isFocusedCollapsibleList = (pos: number, node: PmNode): boolean =>\n node.type.name === TIPTAP_COLLAPSIBLE_LIST_TYPE &&\n selection.from > pos &&\n selection.to < pos + node.nodeSize;\n\n const isGrippable = (pos: number | null): pos is number => {\n if (pos === null) {\n return false;\n }\n const node = doc.nodeAt(pos);\n return !!node && !isEmptyTextBlock(node) && !isFocusedCollapsibleList(pos, node);\n };\n const multiHandlePos = getMultiSelectHandlePos(selectedPositions);\n if (multiHandlePos !== null && doc.nodeAt(multiHandlePos)) {\n // Multi-select handle for the selection + an individual handle for a hovered\n // non-selected block (so the user can click it to deselect or start a new selection).\n const hoveredNonSelected =\n isGrippable(hoveredPos) && !selectedPositions.includes(hoveredPos) ? [hoveredPos] : [];\n return filterBannerLayoutHandles(doc, [...new Set([multiHandlePos, ...hoveredNonSelected])]);\n }\n return filterBannerLayoutHandles(doc, isGrippable(hoveredPos) ? [hoveredPos] : []);\n};\n\nexport const shouldShowBlockSelectedRing = (\n pos: number,\n doc: PmNode,\n pluginState: BlockDragHandleState,\n selection: EditorView['state']['selection'],\n typesWithOwnFocusRing: ReadonlySet<string>\n): boolean => {\n const node = doc.nodeAt(pos);\n if (!node) {\n return false;\n }\n const isMultiSelect = pluginState.selectedPositions.length > 1;\n // The table is an html-node, so the react-node own-ring collector misses it — but its\n // plugin normalises a grip NodeSelection into the whole-table cell selection, which\n // paints per-cell outlines of its own. Adding the ring on top double-frames it. (Not\n // added to typesWithOwnFocusRing itself: that set also drives shouldSetNodeSelection,\n // where the table must keep its isolating-container multi-select behavior.)\n const hasOwnRing =\n typesWithOwnFocusRing.has(node.type.name) || node.type.name === TIPTAP_TABLE_TYPE;\n // Own-ring blocks paint via NodeSelection in single-select — skip plugin ring.\n // In multi-select, show it unless NodeSelection is already active on this node.\n if (hasOwnRing && !isMultiSelect) {\n return false;\n }\n if (hasOwnRing && selection instanceof NodeSelection && selection.from === pos) {\n return false;\n }\n if (pluginState.selectedPositions.includes(pos)) {\n return true;\n }\n return (\n pluginState.selectedPositions.length === 0 &&\n selection instanceof NodeSelection &&\n selection.from === pos\n );\n};\n\nconst isTextEditTarget = (target: EventTarget | null): boolean => {\n if (!(target instanceof HTMLElement)) {\n return false;\n }\n if (target.closest('[data-block-drag-handle], [data-layout-cell-resize-handle], button')) {\n return false;\n }\n // blockquote and pre are the rendered tags of the blockquote and code-block\n // textblocks — without them here, clicks on their editable DOM fall into the\n // non-text branch and can start box-select instead of placing the caret.\n return !!target.closest(\n ':is(p, h1, h2, h3, h4, h5, h6, li, td, th, blockquote, pre, [data-layout-cell-content])'\n );\n};\n\n// TipTap node-view item grips (collapsible DndIcon, etc.) — not the block-drag widget.\n// Box-select must not steal mousedown from these or item reorder never starts.\nconst isNodeViewDragHandleTarget = (target: EventTarget | null): boolean => {\n if (!(target instanceof Element)) {\n return false;\n }\n const handle = target.closest('[data-drag-handle]');\n return !!handle && !handle.closest('[data-block-drag-handle]');\n};\n\n// Interactive table chrome that owns its own mousedown and lives in (or beside) the\n// left gutter where box-select starts: whole-table selector/anchor, row & column\n// handles, and the add-row/col buttons. Box-select must yield to these so their own\n// select/drag still fires. Stable data-hooks (not hashed class names).\nconst TABLE_CHROME_SELECTOR =\n '[data-table-handle],[data-hook=\"table-selector\"],[data-hook=\"row-handle\"],[data-hook=\"column-handle\"],[data-hook=\"addRow\"],[data-hook=\"addCol\"]';\n\nexport const isTableChromeTarget = (target: EventTarget | null): boolean =>\n target instanceof Element && !!target.closest(TABLE_CHROME_SELECTOR);\n\n// Yield only to elements that own their own mousedown: node-view grips and the table's\n// interactive chrome. The plain table body/gutter is intentionally NOT ignored, so a\n// marquee can start there just like in a paragraph's gutter. (The table node is\n// `draggable`, so bailing here would let its native drag fire instead of box-select.)\nexport const shouldIgnoreBoxSelectTarget = (target: EventTarget | null): boolean =>\n isNodeViewDragHandleTarget(target) || isTableChromeTarget(target);\n\nconst isDragHandleTarget = (target: EventTarget | null): boolean =>\n target instanceof Element && !!target.closest('[data-block-drag-handle]');\n\n// Publishes where this drag will actually insert, so the drop cursor draws its\n// line there instead of resolving its own (different) position via posAtCoords.\n// Called on every dragover; the resolver is the same one the drop itself uses.\nconst publishDropInsertPos = (\n view: EditorView,\n clientX: number,\n clientY: number\n): number | null => {\n if (!view.dragging?.slice) {\n return null;\n }\n const dragPositions = getHandleDragPositions(view);\n const pos = dragPositions.length\n ? (resolveHandleDrop(view, clientX, clientY, dragPositions)?.insertPos ?? null)\n : null;\n // Publish `null` too — it means \"no valid drop here\", which hides the cursor.\n // Clearing instead would let it fall back to posAtCoords and paint a line for a\n // drop that will never happen.\n dragDropInsertPos.set(view, pos);\n return pos;\n};\n\n// The zones box-select can start from: the hovered and selected blocks' handle zones,\n// plus the editor-level gutter strip (checked inside isPointerInAnyBlockHandleZone).\nconst isPointerInActiveHandleZone = (\n view: EditorView,\n clientX: number,\n clientY: number\n): boolean => {\n const { hoveredPos, selectedPositions } = getPluginState(view);\n return isPointerInAnyBlockHandleZone(view, clientX, clientY, [\n ...(hoveredPos !== null ? [hoveredPos] : []),\n ...selectedPositions,\n ]);\n};\n\n// Shared by mouseleave and the document-level gutter tracking below.\nconst clearHoveredPos = (view: EditorView): void => {\n const current = getPluginState(view);\n if (current.hoveredPos !== null) {\n setPluginState(view, { ...current, hoveredPos: null });\n }\n};\n\nconst applyHoverAtPointer = (view: EditorView, clientX: number, clientY: number): void => {\n if (isHandleDragActive(view)) {\n return;\n }\n const current = getPluginState(view);\n\n const handlePosUnderPointer = getBlockPosFromHandleUnderPointer(clientX, clientY);\n\n // The grip under the pointer wins over the geometric hover resolution — while the\n // pointer is on a grip, that grip's block must stay hovered or the grip unmounts\n // under the pointer mid-interaction.\n const toExistingPos = (pos: number | null): number | null =>\n pos !== null && view.state.doc.nodeAt(pos) ? pos : null;\n const resolvedPos =\n toExistingPos(handlePosUnderPointer) ??\n toExistingPos(resolveHoveredBlockPos(view, clientX, clientY));\n const hoveredPos = filterBannerLayoutHandles(\n view.state.doc,\n resolvedPos !== null ? [resolvedPos] : []\n )[0];\n\n // While the pointer travels through the hovered block's grip corridor, keep that\n // block hovered — both when the pointer resolved to nothing (moving off the block\n // edge toward the grip) and when it resolved to a DIFFERENT block whose content\n // occupies the corridor (text wrapping around a floated image sits between the image\n // and its grip, and would steal the hover right before the pointer reaches it). A\n // grip under the pointer still wins: it already took over the resolution above.\n const shouldFallBackToPrevious =\n hoveredPos !== current.hoveredPos &&\n current.hoveredPos !== null &&\n handlePosUnderPointer === null &&\n isPointerInHandleGutter(view, clientX, clientY, [current.hoveredPos]);\n\n const nextPos = shouldFallBackToPrevious\n ? toExistingPos(current.hoveredPos)\n : (hoveredPos ?? null);\n\n setHoveredPos(view, nextPos);\n};\n\nconst clearSelectedBlocks = (view: EditorView): void => {\n const current = getPluginState(view);\n if (current.selectedPositions.length === 0 && current.selectionBox === null) {\n return;\n }\n setPluginState(view, {\n ...current,\n selectedPositions: [],\n selectionBox: null,\n });\n};\n\n// Interactive chrome that owns its own mousedown (see shouldIgnoreBoxSelectTarget) makes\n// box-select yield. Inside a table, also drop stale block selection so Escape →\n// cell-selection isn't fighting it.\nconst yieldsToOwnMousedownTarget = (view: EditorView, target: EventTarget | null): boolean => {\n if (!shouldIgnoreBoxSelectTarget(target)) {\n return false;\n }\n if (isDomInsideTable(view, target)) {\n clearSelectedBlocks(view);\n }\n return true;\n};\n\nconst getHandleDragPositions = (view: EditorView): number[] => {\n // A cancelled drag must not fall back to selectedPositions — that would resolve a drop\n // (and draw a cursor) for content the drag no longer owns.\n if (isHandleDragCancelled(view)) {\n return [];\n }\n const dragging = getDraggingPositions(view);\n return dragging?.length ? dragging : getPluginState(view).selectedPositions;\n};\n\nconst makeBoxSelectCallbacks = (\n view: EditorView,\n typesWithOwnFocusRing: ReadonlySet<string>\n): BoxSelectCallbacks => ({\n setSelectionBox: box => {\n const current = getPluginState(view);\n setPluginState(view, { ...current, selectionBox: box });\n },\n selectBlocks: positions => selectBlocks(view, positions, typesWithOwnFocusRing),\n clearSelected: () => deselectAllBlocks(view),\n});\n\n// Structural containers whose native drags carry their own dedicated UX (column\n// reorder, collapsible item reorder, the layout/table chrome drags) — leave their\n// visuals to their owners.\nconst NATIVE_DRAG_VISUALS_EXCLUDED = new Set<string>([\n TIPTAP_LAYOUT_TYPE,\n TIPTAP_LAYOUT_CELL_TYPE,\n TIPTAP_TABLE_TYPE,\n TIPTAP_COLLAPSIBLE_ITEM_TYPE,\n TIPTAP_COLLAPSIBLE_LIST_TYPE,\n]);\n\n// The node the browser is about to drag, mirroring ProseMirror's own choice: the\n// NodeSelection when the drag starts inside it (PM selects a draggable node on\n// mousedown), else the nearest draggable ancestor of the drag origin.\nconst resolveNativeDragPos = (view: EditorView, target: EventTarget | null): number | null => {\n if (!(target instanceof Element)) {\n return null;\n }\n const { selection, doc } = view.state;\n if (selection instanceof NodeSelection) {\n const selectedDom = view.nodeDOM(selection.from);\n if (selectedDom instanceof HTMLElement && selectedDom.contains(target)) {\n return selection.from;\n }\n }\n let pos: number;\n try {\n pos = view.posAtDOM(target, 0);\n } catch {\n return null;\n }\n const $pos = doc.resolve(pos);\n // An atom's body resolves to the position before it.\n if ($pos.nodeAfter?.type.spec.draggable) {\n return pos;\n }\n for (let depth = $pos.depth; depth >= 1; depth--) {\n if ($pos.node(depth).type.spec.draggable) {\n return $pos.before(depth);\n }\n }\n return null;\n};\n\nconst dispatchHandleDragDrop = (view: EditorView, event: DragEvent): boolean => {\n const positions = getHandleDragPositions(view);\n if (positions.length === 0) {\n return false;\n }\n\n const result = createBlockDragDropTransaction(view, event, positions);\n if (!result) {\n return false;\n }\n\n const { tr, insertedPositions } = result;\n // The single-closed-node path already set its selection in\n // createBlockDragDropTransaction; a multi-block drop must set its own selection too —\n // otherwise the pre-drag selection (a NodeSelection on a block this transaction just\n // deleted) gets mapped via Selection.near onto an adjacent image/table. Same rule as\n // the single-block drop: a drag never leaves a NodeSelection behind — a caret inside\n // the text-carrying primary, or a neutral caret just outside the group.\n if (insertedPositions.length > 1 && !setCaretInsideDroppedNode(tr, insertedPositions[0])) {\n const range = getContiguousRange(tr.doc, insertedPositions) ?? {\n from: insertedPositions[0],\n to: insertedPositions[0],\n };\n tr.setSelection(findNeutralSelectionNear(tr.doc, insertedPositions, range));\n }\n // Click selects; drag doesn't. A single block always lands with a plain caret — leave\n // it unselected: no ring, the settle pop (droppedPositions) is the landing feedback.\n // A multi-select keeps its group selected so a dropped group reads exactly like a\n // fresh multi-select and can be re-grabbed.\n tr.setMeta(blockDragHandlePluginKey, {\n ...getPluginState(view),\n selectedPositions: insertedPositions.length > 1 ? insertedPositions : [],\n selectionBox: null,\n hoveredPos: null,\n droppedPositions: insertedPositions,\n });\n // Mark as a user-initiated drop so platform-level filterTransaction plugins recognise it.\n tr.setMeta('uiEvent', 'drop');\n // The Wix editor's typing guard (filterTransaction) blocks ReplaceSteps containing text nodes\n // when disableTyping is active, unless this meta is set. Block reordering always involves\n // text-containing nodes, so we must opt out of that guard explicitly.\n tr.setMeta('allowTextReplace', true);\n view.dispatch(tr);\n scheduleDropSettleRetire(view, insertedPositions);\n return true;\n};\n\n/**\n * Everything that paints a drag's pickup/settle visuals: the source blocks' dim-and-shrink\n * (pinned at dragstart, cleared on drop/dragend) and the landed blocks' settle pop.\n *\n * The positions are mutated outside transactions on purpose — a dispatch inside dragstart\n * re-renders the source subtree before the browser captures the drag, which aborts the\n * drag in Chrome — so decorations read them through the getters and skip their cache\n * while either is set. It also owns the view reference: set once the view mounts, before\n * any transaction can reach the plugin's apply(), which uses it to keep the\n * dragging-positions WeakMap (keyed by view) in sync with docChanged transactions,\n * including remote ones arriving mid-drag.\n */\nconst createDragVisuals = () => {\n let view: EditorView | null = null;\n\n // Grip drags: also renders the pinned grip and feeds getHandleDragPositions, which\n // publishes the drop position.\n let pinnedHandlePositions: number[] | null = null;\n\n // Native body drags (an image dragged by its body, a divider, …) get the same pickup\n // VISUALS as grip drags — the card ghost and the source dim — while their drop stays\n // stock ProseMirror (posAtCoords, droppable into layout cells). Tracked separately\n // from pinnedHandlePositions on purpose: the pinned state would hijack exactly the\n // drop behavior these drags must keep.\n let nativeDragPositions: number[] | null = null;\n\n // Decorations only re-evaluate on a view update, and an in-flight drag dispatches\n // nothing — so the pickup/drop animation classes need a state-identical \"poke\"\n // transaction to make PM re-render them.\n const pokeDecorations = () => {\n if (!view || view.isDestroyed) {\n return;\n }\n view.dispatch(view.state.tr.setMeta(blockDragHandlePluginKey, { ...getPluginState(view) }));\n };\n\n // The two drag kinds share this lifecycle shape; only the position slot differs.\n const makeLifecycle = (\n get: () => number[] | null,\n set: (positions: number[] | null) => void\n ) => ({\n onDragStart: (positions: number[]) => {\n set(positions);\n // Deferred a frame (see the createDragVisuals comment): one frame in, PM patches\n // the decoration class onto the existing DOM in place.\n requestAnimationFrame(() => {\n if (get() === positions) {\n pokeDecorations();\n }\n });\n },\n onDragEnd: () => {\n if (get() === null) {\n return;\n }\n set(null);\n pokeDecorations();\n },\n // The drop dispatches its own transaction immediately after — dropping the pin\n // first lets that single render carry the final state (no stale drag-source\n // classes, no extra poke dispatch inside the drop's already-heavy task).\n onDropCommit: () => {\n set(null);\n },\n });\n\n // A native drop is ProseMirror's transaction, so the landing position is never in our\n // hands — recover it afterwards: remember the dragged node's identity before the drop,\n // then find it again in the new doc and play the same settle pop the grip path plays.\n // Multiple identity matches (a copy-drop, missing ids) resolve to the node rendered\n // nearest the drop point.\n const scheduleNativeDropSettle = (event: DragEvent) => {\n const settleView = view;\n const positions = nativeDragPositions;\n const source =\n settleView && positions?.length ? settleView.state.doc.nodeAt(positions[0]) : null;\n if (!settleView || !source) {\n return;\n }\n const docBefore = settleView.state.doc;\n const sourceType = source.type;\n const sourceId: unknown = source.attrs?.id;\n const { clientX, clientY } = event;\n // A microtask, NOT a timeout: it flushes after ProseMirror's own drop handling\n // (same event, after this handler) has dispatched — or not, when the drop was\n // rejected — but still BEFORE the browser paints. Painted-then-classed would show\n // the node at full scale for a frame and the settle would read as a pulse\n // (normal → 0.97 → normal) instead of a scale-up.\n queueMicrotask(() => {\n if (settleView.isDestroyed || settleView.state.doc === docBefore) {\n return;\n }\n const matches: number[] = [];\n settleView.state.doc.descendants((node, pos) => {\n if (node.type === sourceType && (!sourceId || node.attrs?.id === sourceId)) {\n matches.push(pos);\n }\n return true;\n });\n const landed = matches.length\n ? matches.reduce((best, pos) => {\n const distanceTo = (p: number): number => {\n const dom = settleView.nodeDOM(p);\n if (!(dom instanceof HTMLElement)) {\n return Number.POSITIVE_INFINITY;\n }\n const rect = dom.getBoundingClientRect();\n return Math.hypot(\n rect.left + rect.width / 2 - clientX,\n rect.top + rect.height / 2 - clientY\n );\n };\n return distanceTo(pos) < distanceTo(best) ? pos : best;\n })\n : null;\n if (landed === null) {\n return;\n }\n const droppedPositions = [landed];\n settleView.dispatch(\n settleView.state.tr.setMeta(blockDragHandlePluginKey, {\n ...getPluginState(settleView),\n droppedPositions,\n })\n );\n scheduleDropSettleRetire(settleView, droppedPositions);\n });\n };\n\n return {\n setView: (nextView: EditorView | null) => {\n view = nextView;\n },\n mapDraggingPositions: (tr: Transaction) => {\n if (view) {\n mapDraggingPositions(view, tr);\n }\n },\n pinnedHandlePositions: () => pinnedHandlePositions,\n nativeDragPositions: () => nativeDragPositions,\n pokeDecorations,\n handleLifecycle: makeLifecycle(\n () => pinnedHandlePositions,\n positions => {\n pinnedHandlePositions = positions;\n }\n ),\n nativeLifecycle: makeLifecycle(\n () => nativeDragPositions,\n positions => {\n nativeDragPositions = positions;\n }\n ),\n scheduleNativeDropSettle,\n };\n};\n\n/**\n * Builds the plugin's decoration set for the `decorations` prop: selected rings, the\n * in-flight drag's source dim, the drop settle pop, and the grip widgets.\n *\n * Cached per plugin-state object plus a selection fingerprint (see\n * getSelectionDecorationKey) — the state object is reused across selection-only\n * transactions, so the reference alone is not enough. Entries are GC'd automatically\n * when the old state object is no longer reachable (WeakMap semantics). The cache is\n * skipped while a drag is in flight: its positions are mutated outside transactions\n * (see createDragVisuals), so drag-source visuals must always be rebuilt fresh.\n */\nconst createDecorationBuilder = (\n t: TFunction,\n typesWithOwnFocusRing: ReadonlySet<string>,\n dragLifecycle: NonNullable<HandleElementOptions['dragLifecycle']>\n) => {\n // Everything a grip needs except its position is fixed for the builder's lifetime, so\n // the two option sets (single grip, multi-select grip) are built once, not per widget.\n const singleHandleOptions: HandleElementOptions = {\n t,\n typesWithOwnFocusRing,\n dragLifecycle,\n isMultiHandle: false,\n };\n const multiHandleOptions: HandleElementOptions = { ...singleHandleOptions, isMultiHandle: true };\n\n const createHandleWidget = (handlePos: number, isMultiHandle: boolean): Decoration =>\n Decoration.widget(\n handlePos,\n (view, getPos) =>\n createHandleElement(view, getPos, isMultiHandle ? multiHandleOptions : singleHandleOptions),\n {\n // Before the node, as its previous DOM sibling — the grip shares the block's\n // offsetParent, which positionHandle relies on.\n side: -1,\n // PM diffs widgets by key: the same key keeps the same <button> (and its live\n // listeners) across updates; the two variants differ so switching modes rebuilds.\n key: `block-drag-handle-${isMultiHandle ? 'multi-' : ''}${handlePos}`,\n destroy: destroyHandleElement,\n }\n );\n\n const cache = new WeakMap<BlockDragHandleState, { selectionKey: string; set: DecorationSet }>();\n\n const build = (\n doc: PmNode,\n selection: Selection,\n pluginState: BlockDragHandleState,\n pinnedPositions: number[] | null,\n nativeSourcePositions: number[] | null\n ): DecorationSet => {\n const decos: Decoration[] = [];\n const ringPositions = new Set<number>(pluginState.selectedPositions);\n\n if (selection instanceof NodeSelection && pluginState.selectedPositions.length === 0) {\n ringPositions.add(selection.from);\n }\n\n for (const pos of ringPositions) {\n const node = doc.nodeAt(pos);\n if (!node) {\n continue;\n }\n if (!shouldShowBlockSelectedRing(pos, doc, pluginState, selection, typesWithOwnFocusRing)) {\n continue;\n }\n decos.push(\n Decoration.node(pos, pos + node.nodeSize, {\n class: styles.blockSelected,\n })\n );\n }\n\n // Pickup shrink: the in-flight drag's source blocks dim and scale down. Rendered by\n // PM itself — mutating the managed DOM directly gets redrawn away and can abort\n // the native drag. Native body drags contribute their source through the separate\n // native list (visuals only — grips and drop resolution stay pinned-only).\n for (const pos of [...(pinnedPositions ?? []), ...(nativeSourcePositions ?? [])]) {\n const node = doc.nodeAt(pos);\n if (node) {\n decos.push(Decoration.node(pos, pos + node.nodeSize, { class: styles.blockDragSource }));\n }\n }\n\n // Drop settle: freshly inserted DOM plays its scale-back-to-normal mount animation.\n if (pluginState.droppedPositions) {\n for (const pos of pluginState.droppedPositions) {\n const node = doc.nodeAt(pos);\n if (node) {\n decos.push(Decoration.node(pos, pos + node.nodeSize, { class: styles.blockDropSettle }));\n }\n }\n }\n\n const handlePositions = getHandlePositions(\n doc,\n selection,\n pluginState.hoveredPos,\n pluginState.selectedPositions,\n pinnedPositions\n );\n\n const isMultiHandle = pluginState.selectedPositions.length > 1;\n for (const handlePos of handlePositions) {\n if (doc.nodeAt(handlePos)) {\n decos.push(createHandleWidget(handlePos, isMultiHandle));\n }\n }\n\n return DecorationSet.create(doc, decos);\n };\n\n return (\n state: EditorState,\n pinnedPositions: number[] | null,\n nativeSourcePositions: number[] | null\n ): DecorationSet => {\n const pluginState = blockDragHandlePluginKey.getState(state) ?? emptyState();\n if (pinnedPositions || nativeSourcePositions) {\n return build(state.doc, state.selection, pluginState, pinnedPositions, nativeSourcePositions);\n }\n const selectionKey = getSelectionDecorationKey(state.selection);\n const cached = cache.get(pluginState);\n if (cached && cached.selectionKey === selectionKey) {\n return cached.set;\n }\n const set = build(state.doc, state.selection, pluginState, null, null);\n cache.set(pluginState, { selectionKey, set });\n return set;\n };\n};\n\n// React nodes already paint some focus indication of their own — either custom rendering\n// (image/gif/video via `getContainerClasses`, button focus classes, etc.) or, absent that,\n// the legacy Styles HOC's own `pluginContainer`/`hasFocus` classes — so they should not also\n// get `.blockSelected` on the outer PM node shell. `hide-selection` is the node's own opt-out\n// of that (e.g. collapsible-list/-item still rely on `.blockSelected` rather than painting a\n// ring themselves) — read here rather than re-deriving the same fact from unrelated groups.\nconst getTypesWithOwnFocusRing = (extensions: RicosExtension[]): ReadonlySet<string> =>\n new Set(\n extensions\n .filter(\n extension => extension.type === 'react-node' && !extension.groups.includes('hide-selection')\n )\n .map(({ name }) => name)\n );\n\nexport const createBlockDragHandlePlugin = (extensions: RicosExtension[], t: TFunction): Plugin => {\n const typesWithOwnFocusRing = getTypesWithOwnFocusRing(extensions);\n const dragVisuals = createDragVisuals();\n const buildDecorations = createDecorationBuilder(\n t,\n typesWithOwnFocusRing,\n dragVisuals.handleLifecycle\n );\n let hoverRafId: number | null = null;\n let pendingHover: { clientX: number; clientY: number } | null = null;\n\n const cancelScheduledHoverUpdate = () => {\n if (hoverRafId !== null) {\n cancelAnimationFrame(hoverRafId);\n hoverRafId = null;\n }\n pendingHover = null;\n };\n\n const flushScheduledHoverUpdate = (view: EditorView) => {\n hoverRafId = null;\n const pending = pendingHover;\n pendingHover = null;\n if (!pending) {\n return;\n }\n applyHoverAtPointer(view, pending.clientX, pending.clientY);\n };\n\n const scheduleHoverUpdate = (view: EditorView, clientX: number, clientY: number) => {\n pendingHover = { clientX, clientY };\n if (hoverRafId !== null) {\n return;\n }\n hoverRafId = requestAnimationFrame(() => flushScheduledHoverUpdate(view));\n };\n\n return new Plugin<BlockDragHandleState>({\n key: blockDragHandlePluginKey,\n state: {\n init: () => emptyState(),\n apply(tr, prev) {\n const meta = tr.getMeta(blockDragHandlePluginKey);\n if (meta !== undefined) {\n return meta;\n }\n if (tr.docChanged) {\n dragVisuals.mapDraggingPositions(tr);\n\n return {\n hoveredPos: null,\n selectedPositions: mapSelectedPositionsThroughTransaction(prev.selectedPositions, tr),\n selectionBox: null,\n };\n }\n return prev;\n },\n },\n view(editorView) {\n dragVisuals.setView(editorView);\n const marquee = document.createElement('div');\n marquee.className = styles.blockSelectMarquee;\n marquee.setAttribute('aria-hidden', 'true');\n document.body.append(marquee);\n\n // Lazily resolved — cached after first use so neither per-transaction marquee syncs\n // nor the document-level mousemove below walk the DOM (a getComputedStyle per\n // ancestor) every time.\n let scrollParent: Element | null | undefined; // undefined = not yet resolved\n const getCachedScrollParent = (): Element | null => {\n if (scrollParent === undefined) {\n scrollParent = getScrollParent(editorView.dom);\n }\n return scrollParent;\n };\n\n const syncMarquee = () => {\n const box = getPluginState(editorView).selectionBox;\n if (!box) {\n marquee.style.display = 'none';\n return;\n }\n // selectionBox is in viewport (clientX/Y) coordinates — use directly for position:fixed CSS.\n // Clamp to the scroll container's visible rect so the marquee doesn't overflow the editor.\n const raw = normalizeSelectBox(box);\n const clipParent = getCachedScrollParent();\n const clip = clipParent\n ? clipParent.getBoundingClientRect()\n : new DOMRect(0, 0, window.innerWidth, window.innerHeight);\n const top = Math.max(raw.top, clip.top);\n const bottom = Math.min(raw.bottom, clip.bottom);\n const left = Math.max(raw.left, clip.left);\n const right = Math.min(raw.right, clip.right);\n if (bottom <= top || right <= left) {\n marquee.style.display = 'none';\n return;\n }\n marquee.style.display = 'block';\n marquee.style.left = `${left}px`;\n marquee.style.top = `${top}px`;\n marquee.style.width = `${right - left}px`;\n marquee.style.height = `${bottom - top}px`;\n };\n\n syncMarquee();\n\n // Capture-phase listener: intercepts mousedown before child native listeners\n // (e.g. image DraggableHOC) can call stopPropagation and swallow the event.\n // Only activates for clicks in the editor's left gutter on blocks that have\n // no visible handle. Blocks with handles are handled by the\n // bubble-phase handleDOMEvents.mousedown via hoveredPositions.\n const onMouseDownCapture = (event: MouseEvent) => {\n if (event.button !== 0 || !isEditable(editorView)) {\n return;\n }\n if (isDragHandleTarget(event.target)) {\n return;\n }\n if (yieldsToOwnMousedownTarget(editorView, event.target)) {\n return;\n }\n // Text targets can clear selection via the bubble handler — don't intercept them.\n // Only capture for non-text targets (images, etc.) whose DraggableHOC calls\n // stopPropagation and prevents the bubble handler from running.\n if (isTextEditTarget(event.target)) {\n return;\n }\n // The zone check covers the editor-level gutter strip and, for blocks with their\n // own internal gutter (e.g. smart blocks), the hovered/selected blocks' handle\n // zones — the bubble handler uses this same fallback but is never reached when\n // node-views stop propagation on mousedown.\n if (!isPointerInActiveHandleZone(editorView, event.clientX, event.clientY)) {\n return;\n }\n if (!hasBlockAtY(editorView, event.clientY)) {\n return;\n }\n startBoxSelect(\n editorView,\n event,\n makeBoxSelectCallbacks(editorView, typesWithOwnFocusRing)\n );\n };\n\n editorView.dom.addEventListener('mousedown', onMouseDownCapture, {\n capture: true,\n });\n\n // Native body drags (an image dragged by its body, a divider, …) get the grip\n // drag's pickup visuals — card ghost + source dim — while their drop stays stock\n // ProseMirror (droppable into layout cells). Document-level bubble ON PURPOSE:\n // tiptap's React node-view onDragStart is delegated at the React root (outside\n // view.dom), where it dispatches the NodeSelection and sets its own drag image —\n // running after it means the selection is resolvable and the last setDragImage\n // (ours, the card) is the one the browser uses.\n const onDocumentDragStart = (event: DragEvent) => {\n if (!isEditable(editorView) || !event.dataTransfer) {\n return;\n }\n const target = event.target;\n if (!(target instanceof Element) || !editorView.dom.contains(target)) {\n return;\n }\n // Grip drags build their ghost in their own dragstart listener (dom.ts).\n if (target.closest('[data-block-drag-handle]')) {\n return;\n }\n const pos = resolveNativeDragPos(editorView, target);\n const node = pos !== null ? editorView.state.doc.nodeAt(pos) : null;\n if (pos === null || !node || NATIVE_DRAG_VISUALS_EXCLUDED.has(node.type.name)) {\n return;\n }\n const dom = editorView.nodeDOM(pos);\n if (!(dom instanceof HTMLElement)) {\n return;\n }\n buildDragGhost(dom, [pos], event.dataTransfer, event.clientX, event.clientY);\n dragVisuals.nativeLifecycle.onDragStart([pos]);\n };\n document.addEventListener('dragstart', onDocumentDragStart);\n\n // Deferred a frame: a nodeView that grows on this transaction only reaches its new\n // size once React has rendered it, so measuring inline would still read the\n // pre-change layout.\n let remeasureRafId = 0;\n const scheduleHandleRemeasure = () => {\n if (remeasureRafId) {\n return;\n }\n remeasureRafId = requestAnimationFrame(() => {\n remeasureRafId = 0;\n remeasureHandleElements(editorView);\n });\n };\n\n return {\n update() {\n // Read-only can be turned on mid-interaction (`setEditable(false)`), which the\n // event-level guards can't see: they only stop what starts afterwards. Retire\n // whatever is already in flight so no grip, marquee or drag outlives editing.\n if (!isEditable(editorView)) {\n cancelActiveBoxSelect(editorView);\n clearDraggingPositions(editorView);\n clearSelectedBlocks(editorView);\n dragVisuals.nativeLifecycle.onDragEnd();\n }\n syncMarquee();\n scheduleHandleRemeasure();\n },\n destroy() {\n editorView.dom.removeEventListener('mousedown', onMouseDownCapture, {\n capture: true,\n });\n document.removeEventListener('dragstart', onDocumentDragStart);\n // A marquee still in flight owns window/document listeners and an auto-scroll\n // RAF that outlive the view: its next pointermove would dispatch into a\n // destroyed view, and its pointerup would measure blocks through a null docView.\n cancelActiveBoxSelect(editorView);\n cancelScheduledHoverUpdate();\n if (remeasureRafId) {\n cancelAnimationFrame(remeasureRafId);\n }\n marquee.remove();\n dragVisuals.setView(null);\n },\n };\n },\n props: {\n handleDOMEvents: {\n dragend(view) {\n // Grip drags clean up via their own button listener; this is a backstop for\n // drags that end without a drop in this editor (Escape-cancelled, or dropped\n // outside) in case the button's own dragend never fires. Idempotent.\n clearDraggingPositions(view);\n dragDropInsertPos.clear(view);\n dragVisuals.nativeLifecycle.onDragEnd();\n return false;\n },\n dragover(view, event) {\n const active = isEditable(view) && isBlockDragHandleDrop(view);\n if (active) {\n // Runs before the drop cursor's own listener (ProseMirror registers its\n // DOM handlers during construction, ahead of plugin views), so the\n // position published here is what the cursor reads this same frame.\n // Deliberately synchronous, not RAF-throttled like the hover path: deferring\n // this a frame desyncs it from the drop cursor's own same-tick read, which\n // is exactly the \"cursor and drop diverge\" class of bug this plugin's drop\n // resolution was built to eliminate (confirmed by reverting to throttled and\n // watching the drop-cursor-agreement browser spec fail).\n publishDropInsertPos(view, event.clientX, event.clientY);\n event.preventDefault();\n return true;\n }\n return false;\n },\n drop(view, event) {\n const active = isEditable(view) && isBlockDragHandleDrop(view);\n if (!active) {\n // A native drag's drop is ProseMirror's to perform (return false) — its\n // dispatch renders the cleared drag-source state in the same frame. The\n // settle pop is scheduled for one tick later, once that dispatch has landed.\n dragVisuals.scheduleNativeDropSettle(event);\n dragVisuals.nativeLifecycle.onDropCommit();\n return false;\n }\n // Always swallow the event for handle drags — even when dispatchHandleDragDrop\n // is a no-op (same-place drop). If we return false, ProseMirror's built-in\n // handler fires with view.dragging still set and inserts the slice as a copy.\n // preventDefault is on us (PM does not call it for custom handlers): without\n // it the browser still performs its own default drop behavior.\n event.preventDefault();\n dragVisuals.handleLifecycle.onDropCommit();\n const dispatched = dispatchHandleDragDrop(view, event);\n if (!dispatched) {\n // A no-op drop (same place, rejected target) dispatches nothing, but the\n // pickup decorations still need a render to retire — without this poke the\n // blocks stay dimmed until the next unrelated transaction.\n dragVisuals.pokeDecorations();\n }\n clearDraggingPositions(view);\n dragDropInsertPos.clear(view);\n view.dragging = null;\n // Belt-and-suspenders: normally cleared by the source button's own `dragend`,\n // but a drop that moves the block upward can destroy that button (its decoration\n // no longer exists at the old position) before `dragend` fires on it, stranding\n // the pin at a stale position.\n dragVisuals.handleLifecycle.onDragEnd();\n return true;\n },\n mousedown(view, event) {\n if (!isEditable(view)) {\n return false;\n }\n // A pending hover update (scheduled on the pre-click mousemove) would dispatch a\n // plugin-state transaction mid-click. Racing the browser's native click-to-caret\n // placement, that misplaces the caret — e.g. clicking a table cell lands the caret\n // outside the table. Cancel it here so the click resolves against a stable doc.\n cancelScheduledHoverUpdate();\n if (event.button !== 0) {\n return false;\n }\n if (isDragHandleTarget(event.target)) {\n return false;\n }\n if (yieldsToOwnMousedownTarget(view, event.target)) {\n return false;\n }\n\n if (isTextEditTarget(event.target)) {\n // A plain click on editable text is a caret click even inside the handle band\n // (it reaches 28px into the block): a marquee here would swallow the caret.\n if (!event.shiftKey) {\n clearSelectedBlocks(view);\n return false;\n }\n // Shift-click on inline content (links, spans, etc.) — let PM handle it so the\n // link toolbar and selection extension still work.\n if (\n event.target instanceof Element &&\n getComputedStyle(event.target).display.startsWith('inline')\n ) {\n return false;\n }\n } else if (\n !event.shiftKey &&\n !isPointerInActiveHandleZone(view, event.clientX, event.clientY)\n ) {\n // Box-select starts from the handle zone (grip area) without a modifier, and\n // from anywhere else with Shift.\n return false;\n }\n\n startBoxSelect(view, event, makeBoxSelectCallbacks(view, typesWithOwnFocusRing));\n return true;\n },\n keydown(view, event) {\n if (event.key === 'Escape') {\n // Table owns Escape (edit → cell selection → whole table). Don't dispatch\n // mid-keydown and race TableEscapeNavigation.\n if (isSelectionInsideTable(view.state.selection)) {\n return false;\n }\n clearDraggingPositions(view);\n clearSelectedBlocks(view);\n }\n return false;\n },\n mousemove(view, event) {\n if (!isEditable(view)) {\n return false;\n }\n if (isHandleDragActive(view)) {\n return false;\n }\n // Don't refresh hover while a button is held — the pointer is mid-click or\n // mid-selection, and a hover dispatch there races native caret placement.\n if (event.buttons !== 0) {\n return false;\n }\n scheduleHoverUpdate(view, event.clientX, event.clientY);\n return false;\n },\n mouseleave(view) {\n cancelScheduledHoverUpdate();\n if (isHandleDragActive(view)) {\n return false;\n }\n clearHoveredPos(view);\n return false;\n },\n },\n decorations: state =>\n buildDecorations(\n state,\n dragVisuals.pinnedHandlePositions(),\n dragVisuals.nativeDragPositions()\n ),\n },\n });\n};\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,2BAMO;AAEP,kCAAkC;AAGlC,mBAAsC;AAEtC,kBAA0C;AAE1C,2CAA+B;AAC/B,wBAA+E;AAC/E,iBAUO;AACP,wBAMO;AACP,kBAOO;AACP,mBAA+B;AAC/B,oBAA2D;AAC3D,wBAMO;AACP,uBAaO;AACP,yBAAmB;AAQnB,MAAM,2BAA2B,CAC/B,MACA,aACoC;AACpC,WAAS,IAAI,GAAG,KAAK,KAAK,OAAO,KAAK;AACpC,UAAM,OAAO,KAAK,KAAK,CAAC;AACxB,YAAI,yCAAuB,KAAK,KAAK,IAAI,CAAC,CAAC,KAAK,KAAC,mCAAiB,IAAI,GAAG;AACvE,aAAO,CAAC,EAAE,KAAK,KAAK,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;AAAA,MACA,aAAa,WACX;AAAA,QACE;AAAA,QACA,YAAY,sBAAsB;AAAA,QAClC,YAAY,oBAAoB;AAAA,MAClC;AAAA,IACJ;AAAA,EACF,CAAC;AACH;",
4
+ "sourcesContent": ["import {\n TIPTAP_COLLAPSIBLE_ITEM_TYPE,\n TIPTAP_COLLAPSIBLE_LIST_TYPE,\n TIPTAP_LAYOUT_CELL_TYPE,\n TIPTAP_LAYOUT_TYPE,\n TIPTAP_TABLE_TYPE,\n} from './../ricos-content/index.js';\nimport type { RicosExtension, TFunction } from './../ricos-types/index.js';\nimport { dragDropInsertPos } from './../_shared/drag-drop-insert-pos.js';\nimport type { Node as PmNode, ResolvedPos } from './../tiptap/pm/model.js';\nimport type { EditorState, Selection, Transaction } from './../tiptap/pm/state.js';\nimport { NodeSelection, Plugin, TextSelection } from './../tiptap/pm/state.js';\nimport type { EditorView } from './../tiptap/pm/view.js';\nimport { Decoration, DecorationSet } from './../tiptap/pm/view.js';\n\nimport { isBannerLayout } from '../ricos-common-plugins/layout/banner-drop-prevention-plugin.js';\nimport { type BoxSelectCallbacks, cancelActiveBoxSelect, startBoxSelect } from './box-select.js';\nimport {\n type HandleElementOptions,\n createHandleElement,\n destroyHandleElement,\n getBlockPosFromHandleUnderPointer,\n getScrollParent,\n getViewScale,\n isPointerInBlockHoverRect,\n isPointerInBlockInset,\n isPointerInHandleGutter,\n remeasureHandleElements,\n} from './dom.js';\nimport {\n clearDraggingPositions,\n getDraggingPositions,\n isHandleDragActive,\n isHandleDragCancelled,\n mapDraggingPositions,\n} from './drag-state.js';\nimport {\n createBlockDragDropTransaction,\n findReorderBlocksAtCoords,\n isBlockDragHandleDrop,\n resolveHandleDrop,\n safePosAtCoords,\n setCaretInsideDroppedNode,\n} from './drop.js';\nimport { buildDragGhost } from './ghost.js';\nimport { hasBlockAtY, isPointerInAnyBlockHandleZone } from './gutter.js';\nimport {\n type BlockDragHandleState,\n blockDragHandlePluginKey,\n emptyState,\n getPluginState,\n setHoveredPos,\n} from './plugin-key.js';\nimport {\n deselectAllBlocks,\n findNeutralSelectionNear,\n getContiguousRange,\n isCardChromeNode,\n isDomInsideTable,\n isEmptyTextBlock,\n isReorderContainerNode,\n isSelectionInsideTable,\n mapSelectedPositionsThroughTransaction,\n normalizeSelectBox,\n sameSelectBox,\n selectBlocks,\n} from './selection.js';\nimport styles from './styles-scss.js';\n\n// The reorderable block(s) adjacent to a resolved coordinate: the block containing it,\n// or — when the coordinate sits exactly on a container boundary — the blocks on both\n// sides. The reorderable block is the child of the nearest reorder container (the doc,\n// or a card's content section in the card model) — the walk steps past the page chrome,\n// and a coordinate inside non-reorderable chrome (a card's header or footer) yields no\n// candidates at all.\nconst resolveReorderCandidates = (\n $pos: ResolvedPos,\n coordPos: number\n): { pos: number; node: PmNode }[] => {\n for (let d = 1; d <= $pos.depth; d++) {\n const node = $pos.node(d);\n if (isReorderContainerNode($pos.node(d - 1)) && !isCardChromeNode(node)) {\n return [{ pos: $pos.before(d), node }];\n }\n if (!isCardChromeNode(node)) {\n return [];\n }\n }\n if (!isReorderContainerNode($pos.parent)) {\n return [];\n }\n return [\n $pos.nodeBefore ? { pos: coordPos - $pos.nodeBefore.nodeSize, node: $pos.nodeBefore } : null,\n $pos.nodeAfter ? { pos: coordPos, node: $pos.nodeAfter } : null,\n ].filter((c): c is { pos: number; node: PmNode } => c !== null && !isCardChromeNode(c.node));\n};\n\nconst resolveHoveredBlockPos = (\n view: EditorView,\n clientX: number,\n clientY: number\n): number | null => {\n const coordResult = safePosAtCoords(view, clientX, clientY);\n\n if (coordResult) {\n const isRtl = getComputedStyle(view.dom).direction === 'rtl';\n const scale = getViewScale(view);\n const $pos = view.state.doc.resolve(coordResult.pos);\n for (const { pos } of resolveReorderCandidates($pos, coordResult.pos)) {\n const dom = view.nodeDOM(pos);\n if (\n dom instanceof HTMLElement &&\n isPointerInBlockHoverRect(dom, clientX, clientY, isRtl, scale)\n ) {\n return pos;\n }\n }\n }\n\n return findReorderBlocksAtCoords(view, clientX, clientY)[0] ?? null;\n};\n\nconst samePositions = (a: number[], b: number[]): boolean =>\n a.length === b.length && a.every((pos, i) => pos === b[i]);\n\nconst setPluginState = (view: EditorView, next: BlockDragHandleState): void => {\n const current = getPluginState(view);\n if (\n current.hoveredPos === next.hoveredPos &&\n samePositions(current.selectedPositions, next.selectedPositions) &&\n sameSelectBox(current.selectionBox, next.selectionBox)\n ) {\n return;\n }\n view.dispatch(view.state.tr.setMeta(blockDragHandlePluginKey, next));\n};\n\n// Comfortably past the 200ms settle animation, so clearing never cuts it short.\nconst DROP_SETTLE_CLEAR_MS = 400;\n\n// Retires the settle class once its one-shot animation has played, so a later redraw\n// of the same node doesn't replay the pop. Reference-guarded: newer state wins.\nconst scheduleDropSettleRetire = (view: EditorView, droppedPositions: number[]): void => {\n window.setTimeout(() => {\n if (view.isDestroyed) {\n return;\n }\n const current = getPluginState(view);\n if (current.droppedPositions === droppedPositions) {\n view.dispatch(\n view.state.tr.setMeta(blockDragHandlePluginKey, { ...current, droppedPositions: null })\n );\n }\n }, DROP_SETTLE_CLEAR_MS);\n};\n\nconst getMultiSelectHandlePos = (selectedPositions: number[]): number | null =>\n selectedPositions.length > 1 ? selectedPositions[0] : null;\n\n/** Position of the collapsible list enclosing the selection, or null. */\nconst getEnclosingCollapsibleListPos = (selection: Selection): number | null => {\n const $from = selection.$from;\n for (let d = $from.depth; d >= 1; d--) {\n if ($from.node(d).type.name === TIPTAP_COLLAPSIBLE_LIST_TYPE) {\n return $from.before(d);\n }\n }\n return null;\n};\n\n// Cheap fingerprint of everything the decorations read off the selection, so they\n// rebuild on selection-only transactions (which keep the same plugin-state object and\n// would otherwise hit a stale cache entry). Inputs: NodeSelection identity (drives the\n// selected ring), and which collapsible list the caret sits inside (drives the\n// focused-list grip yield in getHandlePositions).\nconst getSelectionDecorationKey = (selection: Selection): string => {\n const nodeSelectionKey = selection instanceof NodeSelection ? `node:${selection.from}` : '';\n const focusedListPos = getEnclosingCollapsibleListPos(selection);\n return `${nodeSelectionKey}|${focusedListPos !== null ? `collapsible:${focusedListPos}` : ''}`;\n};\n\n/**\n * Read-only editors reach every handler in this plugin: ProseMirror runs\n * `handleDOMEvents` through `runCustomHandler`, which fires *before* — and\n * independently of — the `view.editable` gate that guards its own built-in handlers. So\n * without this check a read-only editor still grows grips, box-selects, and (via the\n * custom drop path) dispatches document-changing transactions into consumer persistence.\n */\nconst isEditable = (view: EditorView): boolean => view.editable;\n\n// A banner layout is pinned to its slot — `filterTransaction` in\n// banner-drop-prevention-plugin rejects any transaction that moves one — so a grip on a\n// banner could only ever start a drag whose drop is silently discarded. Don't offer it.\nconst filterBannerLayoutHandles = (doc: PmNode, positions: number[]): number[] =>\n positions.filter(pos => {\n const node = doc.nodeAt(pos);\n return !node || !isBannerLayout(node);\n });\n\nexport const getHandlePositions = (\n doc: PmNode,\n selection: Selection,\n hoveredPos: number | null,\n selectedPositions: number[],\n pinnedDragPositions: number[] | null\n): number[] => {\n if (pinnedDragPositions?.length) {\n const pos = pinnedDragPositions[0];\n if (doc.nodeAt(pos)) {\n return filterBannerLayoutHandles(doc, [pos]);\n }\n }\n // While the caret is inside a collapsible list, the list's own per-item DndIcons are\n // the reorder affordance (they render on exactly this condition — see the\n // isInCollapsibleList gate in CollapsibleListItem), and the whole-list grip's gutter\n // slot collides with the first item's icon. Yield the grip; it returns as soon as\n // focus leaves the list. A NodeSelection ON the list is \"the list is selected\", not\n // \"editing inside it\" (selection.from equals the list position, not a position\n // strictly inside), so grip-click selection keeps its grip.\n const isFocusedCollapsibleList = (pos: number, node: PmNode): boolean =>\n node.type.name === TIPTAP_COLLAPSIBLE_LIST_TYPE &&\n selection.from > pos &&\n selection.to < pos + node.nodeSize;\n\n const isGrippable = (pos: number | null): pos is number => {\n if (pos === null) {\n return false;\n }\n const node = doc.nodeAt(pos);\n return !!node && !isEmptyTextBlock(node) && !isFocusedCollapsibleList(pos, node);\n };\n const multiHandlePos = getMultiSelectHandlePos(selectedPositions);\n if (multiHandlePos !== null && doc.nodeAt(multiHandlePos)) {\n // Multi-select handle for the selection + an individual handle for a hovered\n // non-selected block (so the user can click it to deselect or start a new selection).\n const hoveredNonSelected =\n isGrippable(hoveredPos) && !selectedPositions.includes(hoveredPos) ? [hoveredPos] : [];\n return filterBannerLayoutHandles(doc, [...new Set([multiHandlePos, ...hoveredNonSelected])]);\n }\n return filterBannerLayoutHandles(doc, isGrippable(hoveredPos) ? [hoveredPos] : []);\n};\n\nexport const shouldShowBlockSelectedRing = (\n pos: number,\n doc: PmNode,\n pluginState: BlockDragHandleState,\n selection: EditorView['state']['selection'],\n typesWithOwnFocusRing: ReadonlySet<string>\n): boolean => {\n const node = doc.nodeAt(pos);\n if (!node) {\n return false;\n }\n const isMultiSelect = pluginState.selectedPositions.length > 1;\n // The table is an html-node, so the react-node own-ring collector misses it — but its\n // plugin normalises a grip NodeSelection into the whole-table cell selection, which\n // paints per-cell outlines of its own. Adding the ring on top double-frames it. (Not\n // added to typesWithOwnFocusRing itself: that set also drives shouldSetNodeSelection,\n // where the table must keep its isolating-container multi-select behavior.)\n const hasOwnRing =\n typesWithOwnFocusRing.has(node.type.name) || node.type.name === TIPTAP_TABLE_TYPE;\n // Own-ring blocks paint via NodeSelection in single-select — skip plugin ring.\n // In multi-select, show it unless NodeSelection is already active on this node.\n if (hasOwnRing && !isMultiSelect) {\n return false;\n }\n if (hasOwnRing && selection instanceof NodeSelection && selection.from === pos) {\n return false;\n }\n if (pluginState.selectedPositions.includes(pos)) {\n return true;\n }\n return (\n pluginState.selectedPositions.length === 0 &&\n selection instanceof NodeSelection &&\n selection.from === pos\n );\n};\n\nconst isTextEditTarget = (target: EventTarget | null): boolean => {\n if (!(target instanceof HTMLElement)) {\n return false;\n }\n if (target.closest('[data-block-drag-handle], [data-layout-cell-resize-handle], button')) {\n return false;\n }\n // blockquote and pre are the rendered tags of the blockquote and code-block\n // textblocks — without them here, clicks on their editable DOM fall into the\n // non-text branch and can start box-select instead of placing the caret.\n return !!target.closest(\n ':is(p, h1, h2, h3, h4, h5, h6, li, td, th, blockquote, pre, [data-layout-cell-content])'\n );\n};\n\n// TipTap node-view item grips (collapsible DndIcon, etc.) — not the block-drag widget.\n// Box-select must not steal mousedown from these or item reorder never starts.\nconst isNodeViewDragHandleTarget = (target: EventTarget | null): boolean => {\n if (!(target instanceof Element)) {\n return false;\n }\n const handle = target.closest('[data-drag-handle]');\n return !!handle && !handle.closest('[data-block-drag-handle]');\n};\n\n// Interactive table chrome that owns its own mousedown and lives in (or beside) the\n// left gutter where box-select starts: whole-table selector/anchor, row & column\n// handles, and the add-row/col buttons. Box-select must yield to these so their own\n// select/drag still fires. Stable data-hooks (not hashed class names).\nconst TABLE_CHROME_SELECTOR =\n '[data-table-handle],[data-hook=\"table-selector\"],[data-hook=\"row-handle\"],[data-hook=\"column-handle\"],[data-hook=\"addRow\"],[data-hook=\"addCol\"]';\n\nexport const isTableChromeTarget = (target: EventTarget | null): boolean =>\n target instanceof Element && !!target.closest(TABLE_CHROME_SELECTOR);\n\n// Yield only to elements that own their own mousedown: node-view grips and the table's\n// interactive chrome. The plain table body/gutter is intentionally NOT ignored, so a\n// marquee can start there just like in a paragraph's gutter. (The table node is\n// `draggable`, so bailing here would let its native drag fire instead of box-select.)\nexport const shouldIgnoreBoxSelectTarget = (target: EventTarget | null): boolean =>\n isNodeViewDragHandleTarget(target) || isTableChromeTarget(target);\n\nconst isDragHandleTarget = (target: EventTarget | null): boolean =>\n target instanceof Element && !!target.closest('[data-block-drag-handle]');\n\n// Publishes where this drag will actually insert, so the drop cursor draws its\n// line there instead of resolving its own (different) position via posAtCoords.\n// Called on every dragover; the resolver is the same one the drop itself uses.\nconst publishDropInsertPos = (\n view: EditorView,\n clientX: number,\n clientY: number\n): number | null => {\n if (!view.dragging?.slice) {\n return null;\n }\n const dragPositions = getHandleDragPositions(view);\n const pos = dragPositions.length\n ? (resolveHandleDrop(view, clientX, clientY, dragPositions)?.insertPos ?? null)\n : null;\n // Publish `null` too — it means \"no valid drop here\", which hides the cursor.\n // Clearing instead would let it fall back to posAtCoords and paint a line for a\n // drop that will never happen.\n dragDropInsertPos.set(view, pos);\n return pos;\n};\n\n// The zones box-select can start from: the hovered and selected blocks' handle zones,\n// plus the editor-level gutter strip (checked inside isPointerInAnyBlockHandleZone).\nconst isPointerInActiveHandleZone = (\n view: EditorView,\n clientX: number,\n clientY: number\n): boolean => {\n const { hoveredPos, selectedPositions } = getPluginState(view);\n return isPointerInAnyBlockHandleZone(view, clientX, clientY, [\n ...(hoveredPos !== null ? [hoveredPos] : []),\n ...selectedPositions,\n ]);\n};\n\n// Text blocks hit-test as text all the way to their border box; their padding is gutter.\n// Resolves the block from the event target, not by measuring every block at the pointer.\nconst isPointerInTextBlockInset = (view: EditorView, event: MouseEvent): boolean => {\n if (!(event.target instanceof Node)) {\n return false;\n }\n let $pos;\n try {\n $pos = view.state.doc.resolve(view.posAtDOM(event.target, 0));\n } catch {\n return false;\n }\n if (!$pos.parent.isTextblock || $pos.depth === 0) {\n return false;\n }\n const dom = view.nodeDOM($pos.before());\n return (\n dom instanceof HTMLElement && isPointerInBlockInset(dom, event.clientX, getViewScale(view))\n );\n};\n\nconst placeCaretAtCoords = (view: EditorView, clientX: number, clientY: number): void => {\n const coords = safePosAtCoords(view, clientX, clientY);\n if (!coords) {\n return;\n }\n view.dispatch(view.state.tr.setSelection(TextSelection.near(view.state.doc.resolve(coords.pos))));\n view.focus();\n};\n\n// Shared by mouseleave and the document-level gutter tracking below.\nconst clearHoveredPos = (view: EditorView): void => {\n const current = getPluginState(view);\n if (current.hoveredPos !== null) {\n setPluginState(view, { ...current, hoveredPos: null });\n }\n};\n\nconst applyHoverAtPointer = (view: EditorView, clientX: number, clientY: number): void => {\n if (isHandleDragActive(view)) {\n return;\n }\n const current = getPluginState(view);\n\n const handlePosUnderPointer = getBlockPosFromHandleUnderPointer(clientX, clientY);\n\n // The grip under the pointer wins over the geometric hover resolution — while the\n // pointer is on a grip, that grip's block must stay hovered or the grip unmounts\n // under the pointer mid-interaction.\n const toExistingPos = (pos: number | null): number | null =>\n pos !== null && view.state.doc.nodeAt(pos) ? pos : null;\n const resolvedPos =\n toExistingPos(handlePosUnderPointer) ??\n toExistingPos(resolveHoveredBlockPos(view, clientX, clientY));\n const hoveredPos = filterBannerLayoutHandles(\n view.state.doc,\n resolvedPos !== null ? [resolvedPos] : []\n )[0];\n\n // While the pointer travels through the hovered block's grip corridor, keep that\n // block hovered — both when the pointer resolved to nothing (moving off the block\n // edge toward the grip) and when it resolved to a DIFFERENT block whose content\n // occupies the corridor (text wrapping around a floated image sits between the image\n // and its grip, and would steal the hover right before the pointer reaches it). A\n // grip under the pointer still wins: it already took over the resolution above.\n const shouldFallBackToPrevious =\n hoveredPos !== current.hoveredPos &&\n current.hoveredPos !== null &&\n handlePosUnderPointer === null &&\n isPointerInHandleGutter(view, clientX, clientY, [current.hoveredPos]);\n\n const nextPos = shouldFallBackToPrevious\n ? toExistingPos(current.hoveredPos)\n : (hoveredPos ?? null);\n\n setHoveredPos(view, nextPos);\n};\n\nconst clearSelectedBlocks = (view: EditorView): void => {\n const current = getPluginState(view);\n if (current.selectedPositions.length === 0 && current.selectionBox === null) {\n return;\n }\n setPluginState(view, {\n ...current,\n selectedPositions: [],\n selectionBox: null,\n });\n};\n\n// Interactive chrome that owns its own mousedown (see shouldIgnoreBoxSelectTarget) makes\n// box-select yield. Inside a table, also drop stale block selection so Escape →\n// cell-selection isn't fighting it.\nconst yieldsToOwnMousedownTarget = (view: EditorView, target: EventTarget | null): boolean => {\n if (!shouldIgnoreBoxSelectTarget(target)) {\n return false;\n }\n if (isDomInsideTable(view, target)) {\n clearSelectedBlocks(view);\n }\n return true;\n};\n\nconst getHandleDragPositions = (view: EditorView): number[] => {\n // A cancelled drag must not fall back to selectedPositions — that would resolve a drop\n // (and draw a cursor) for content the drag no longer owns.\n if (isHandleDragCancelled(view)) {\n return [];\n }\n const dragging = getDraggingPositions(view);\n return dragging?.length ? dragging : getPluginState(view).selectedPositions;\n};\n\nconst makeBoxSelectCallbacks = (\n view: EditorView,\n typesWithOwnFocusRing: ReadonlySet<string>\n): BoxSelectCallbacks => ({\n setSelectionBox: box => {\n const current = getPluginState(view);\n setPluginState(view, { ...current, selectionBox: box });\n },\n selectBlocks: positions => selectBlocks(view, positions, typesWithOwnFocusRing),\n clearSelected: () => deselectAllBlocks(view),\n});\n\n// Structural containers whose native drags carry their own dedicated UX (column\n// reorder, collapsible item reorder, the layout/table chrome drags) — leave their\n// visuals to their owners.\nconst NATIVE_DRAG_VISUALS_EXCLUDED = new Set<string>([\n TIPTAP_LAYOUT_TYPE,\n TIPTAP_LAYOUT_CELL_TYPE,\n TIPTAP_TABLE_TYPE,\n TIPTAP_COLLAPSIBLE_ITEM_TYPE,\n TIPTAP_COLLAPSIBLE_LIST_TYPE,\n]);\n\n// The node the browser is about to drag, mirroring ProseMirror's own choice: the\n// NodeSelection when the drag starts inside it (PM selects a draggable node on\n// mousedown), else the nearest draggable ancestor of the drag origin.\nconst resolveNativeDragPos = (view: EditorView, target: EventTarget | null): number | null => {\n if (!(target instanceof Element)) {\n return null;\n }\n const { selection, doc } = view.state;\n if (selection instanceof NodeSelection) {\n const selectedDom = view.nodeDOM(selection.from);\n if (selectedDom instanceof HTMLElement && selectedDom.contains(target)) {\n return selection.from;\n }\n }\n let pos: number;\n try {\n pos = view.posAtDOM(target, 0);\n } catch {\n return null;\n }\n const $pos = doc.resolve(pos);\n // An atom's body resolves to the position before it.\n if ($pos.nodeAfter?.type.spec.draggable) {\n return pos;\n }\n for (let depth = $pos.depth; depth >= 1; depth--) {\n if ($pos.node(depth).type.spec.draggable) {\n return $pos.before(depth);\n }\n }\n return null;\n};\n\nconst dispatchHandleDragDrop = (view: EditorView, event: DragEvent): boolean => {\n const positions = getHandleDragPositions(view);\n if (positions.length === 0) {\n return false;\n }\n\n const result = createBlockDragDropTransaction(view, event, positions);\n if (!result) {\n return false;\n }\n\n const { tr, insertedPositions } = result;\n // The single-closed-node path already set its selection in\n // createBlockDragDropTransaction; a multi-block drop must set its own selection too —\n // otherwise the pre-drag selection (a NodeSelection on a block this transaction just\n // deleted) gets mapped via Selection.near onto an adjacent image/table. Same rule as\n // the single-block drop: a drag never leaves a NodeSelection behind — a caret inside\n // the text-carrying primary, or a neutral caret just outside the group.\n if (insertedPositions.length > 1 && !setCaretInsideDroppedNode(tr, insertedPositions[0])) {\n const range = getContiguousRange(tr.doc, insertedPositions) ?? {\n from: insertedPositions[0],\n to: insertedPositions[0],\n };\n tr.setSelection(findNeutralSelectionNear(tr.doc, insertedPositions, range));\n }\n // Click selects; drag doesn't. A single block always lands with a plain caret — leave\n // it unselected: no ring, the settle pop (droppedPositions) is the landing feedback.\n // A multi-select keeps its group selected so a dropped group reads exactly like a\n // fresh multi-select and can be re-grabbed.\n tr.setMeta(blockDragHandlePluginKey, {\n ...getPluginState(view),\n selectedPositions: insertedPositions.length > 1 ? insertedPositions : [],\n selectionBox: null,\n hoveredPos: null,\n droppedPositions: insertedPositions,\n });\n // Mark as a user-initiated drop so platform-level filterTransaction plugins recognise it.\n tr.setMeta('uiEvent', 'drop');\n // The Wix editor's typing guard (filterTransaction) blocks ReplaceSteps containing text nodes\n // when disableTyping is active, unless this meta is set. Block reordering always involves\n // text-containing nodes, so we must opt out of that guard explicitly.\n tr.setMeta('allowTextReplace', true);\n view.dispatch(tr);\n scheduleDropSettleRetire(view, insertedPositions);\n return true;\n};\n\n/**\n * Everything that paints a drag's pickup/settle visuals: the source blocks' dim-and-shrink\n * (pinned at dragstart, cleared on drop/dragend) and the landed blocks' settle pop.\n *\n * The positions are mutated outside transactions on purpose — a dispatch inside dragstart\n * re-renders the source subtree before the browser captures the drag, which aborts the\n * drag in Chrome — so decorations read them through the getters and skip their cache\n * while either is set. It also owns the view reference: set once the view mounts, before\n * any transaction can reach the plugin's apply(), which uses it to keep the\n * dragging-positions WeakMap (keyed by view) in sync with docChanged transactions,\n * including remote ones arriving mid-drag.\n */\nconst createDragVisuals = () => {\n let view: EditorView | null = null;\n\n // Grip drags: also renders the pinned grip and feeds getHandleDragPositions, which\n // publishes the drop position.\n let pinnedHandlePositions: number[] | null = null;\n\n // Native body drags (an image dragged by its body, a divider, …) get the same pickup\n // VISUALS as grip drags — the card ghost and the source dim — while their drop stays\n // stock ProseMirror (posAtCoords, droppable into layout cells). Tracked separately\n // from pinnedHandlePositions on purpose: the pinned state would hijack exactly the\n // drop behavior these drags must keep.\n let nativeDragPositions: number[] | null = null;\n\n // Decorations only re-evaluate on a view update, and an in-flight drag dispatches\n // nothing — so the pickup/drop animation classes need a state-identical \"poke\"\n // transaction to make PM re-render them.\n const pokeDecorations = () => {\n if (!view || view.isDestroyed) {\n return;\n }\n view.dispatch(view.state.tr.setMeta(blockDragHandlePluginKey, { ...getPluginState(view) }));\n };\n\n // The two drag kinds share this lifecycle shape; only the position slot differs.\n const makeLifecycle = (\n get: () => number[] | null,\n set: (positions: number[] | null) => void\n ) => ({\n onDragStart: (positions: number[]) => {\n set(positions);\n // Deferred a frame (see the createDragVisuals comment): one frame in, PM patches\n // the decoration class onto the existing DOM in place.\n requestAnimationFrame(() => {\n if (get() === positions) {\n pokeDecorations();\n }\n });\n },\n onDragEnd: () => {\n if (get() === null) {\n return;\n }\n set(null);\n pokeDecorations();\n },\n // The drop dispatches its own transaction immediately after — dropping the pin\n // first lets that single render carry the final state (no stale drag-source\n // classes, no extra poke dispatch inside the drop's already-heavy task).\n onDropCommit: () => {\n set(null);\n },\n });\n\n // A native drop is ProseMirror's transaction, so the landing position is never in our\n // hands — recover it afterwards: remember the dragged node's identity before the drop,\n // then find it again in the new doc and play the same settle pop the grip path plays.\n // Multiple identity matches (a copy-drop, missing ids) resolve to the node rendered\n // nearest the drop point.\n const scheduleNativeDropSettle = (event: DragEvent) => {\n const settleView = view;\n const positions = nativeDragPositions;\n const source =\n settleView && positions?.length ? settleView.state.doc.nodeAt(positions[0]) : null;\n if (!settleView || !source) {\n return;\n }\n const docBefore = settleView.state.doc;\n const sourceType = source.type;\n const sourceId: unknown = source.attrs?.id;\n const { clientX, clientY } = event;\n // A microtask, NOT a timeout: it flushes after ProseMirror's own drop handling\n // (same event, after this handler) has dispatched — or not, when the drop was\n // rejected — but still BEFORE the browser paints. Painted-then-classed would show\n // the node at full scale for a frame and the settle would read as a pulse\n // (normal → 0.97 → normal) instead of a scale-up.\n queueMicrotask(() => {\n if (settleView.isDestroyed || settleView.state.doc === docBefore) {\n return;\n }\n const matches: number[] = [];\n settleView.state.doc.descendants((node, pos) => {\n if (node.type === sourceType && (!sourceId || node.attrs?.id === sourceId)) {\n matches.push(pos);\n }\n return true;\n });\n const landed = matches.length\n ? matches.reduce((best, pos) => {\n const distanceTo = (p: number): number => {\n const dom = settleView.nodeDOM(p);\n if (!(dom instanceof HTMLElement)) {\n return Number.POSITIVE_INFINITY;\n }\n const rect = dom.getBoundingClientRect();\n return Math.hypot(\n rect.left + rect.width / 2 - clientX,\n rect.top + rect.height / 2 - clientY\n );\n };\n return distanceTo(pos) < distanceTo(best) ? pos : best;\n })\n : null;\n if (landed === null) {\n return;\n }\n const droppedPositions = [landed];\n settleView.dispatch(\n settleView.state.tr.setMeta(blockDragHandlePluginKey, {\n ...getPluginState(settleView),\n droppedPositions,\n })\n );\n scheduleDropSettleRetire(settleView, droppedPositions);\n });\n };\n\n return {\n setView: (nextView: EditorView | null) => {\n view = nextView;\n },\n mapDraggingPositions: (tr: Transaction) => {\n if (view) {\n mapDraggingPositions(view, tr);\n }\n },\n pinnedHandlePositions: () => pinnedHandlePositions,\n nativeDragPositions: () => nativeDragPositions,\n pokeDecorations,\n handleLifecycle: makeLifecycle(\n () => pinnedHandlePositions,\n positions => {\n pinnedHandlePositions = positions;\n }\n ),\n nativeLifecycle: makeLifecycle(\n () => nativeDragPositions,\n positions => {\n nativeDragPositions = positions;\n }\n ),\n scheduleNativeDropSettle,\n };\n};\n\n/**\n * Builds the plugin's decoration set for the `decorations` prop: selected rings, the\n * in-flight drag's source dim, the drop settle pop, and the grip widgets.\n *\n * Cached per plugin-state object plus a selection fingerprint (see\n * getSelectionDecorationKey) — the state object is reused across selection-only\n * transactions, so the reference alone is not enough. Entries are GC'd automatically\n * when the old state object is no longer reachable (WeakMap semantics). The cache is\n * skipped while a drag is in flight: its positions are mutated outside transactions\n * (see createDragVisuals), so drag-source visuals must always be rebuilt fresh.\n */\nconst createDecorationBuilder = (\n t: TFunction,\n typesWithOwnFocusRing: ReadonlySet<string>,\n dragLifecycle: NonNullable<HandleElementOptions['dragLifecycle']>\n) => {\n // Everything a grip needs except its position is fixed for the builder's lifetime, so\n // the two option sets (single grip, multi-select grip) are built once, not per widget.\n const singleHandleOptions: HandleElementOptions = {\n t,\n typesWithOwnFocusRing,\n dragLifecycle,\n isMultiHandle: false,\n };\n const multiHandleOptions: HandleElementOptions = { ...singleHandleOptions, isMultiHandle: true };\n\n const createHandleWidget = (handlePos: number, isMultiHandle: boolean): Decoration =>\n Decoration.widget(\n handlePos,\n (view, getPos) =>\n createHandleElement(view, getPos, isMultiHandle ? multiHandleOptions : singleHandleOptions),\n {\n // Before the node, as its previous DOM sibling — the grip shares the block's\n // offsetParent, which positionHandle relies on.\n side: -1,\n // PM diffs widgets by key: the same key keeps the same <button> (and its live\n // listeners) across updates; the two variants differ so switching modes rebuilds.\n key: `block-drag-handle-${isMultiHandle ? 'multi-' : ''}${handlePos}`,\n destroy: destroyHandleElement,\n }\n );\n\n const cache = new WeakMap<BlockDragHandleState, { selectionKey: string; set: DecorationSet }>();\n\n const build = (\n doc: PmNode,\n selection: Selection,\n pluginState: BlockDragHandleState,\n pinnedPositions: number[] | null,\n nativeSourcePositions: number[] | null\n ): DecorationSet => {\n const decos: Decoration[] = [];\n const ringPositions = new Set<number>(pluginState.selectedPositions);\n\n if (selection instanceof NodeSelection && pluginState.selectedPositions.length === 0) {\n ringPositions.add(selection.from);\n }\n\n for (const pos of ringPositions) {\n const node = doc.nodeAt(pos);\n if (!node) {\n continue;\n }\n if (!shouldShowBlockSelectedRing(pos, doc, pluginState, selection, typesWithOwnFocusRing)) {\n continue;\n }\n decos.push(\n Decoration.node(pos, pos + node.nodeSize, {\n class: styles.blockSelected,\n })\n );\n }\n\n // Pickup shrink: the in-flight drag's source blocks dim and scale down. Rendered by\n // PM itself — mutating the managed DOM directly gets redrawn away and can abort\n // the native drag. Native body drags contribute their source through the separate\n // native list (visuals only — grips and drop resolution stay pinned-only).\n for (const pos of [...(pinnedPositions ?? []), ...(nativeSourcePositions ?? [])]) {\n const node = doc.nodeAt(pos);\n if (node) {\n decos.push(Decoration.node(pos, pos + node.nodeSize, { class: styles.blockDragSource }));\n }\n }\n\n // Drop settle: freshly inserted DOM plays its scale-back-to-normal mount animation.\n if (pluginState.droppedPositions) {\n for (const pos of pluginState.droppedPositions) {\n const node = doc.nodeAt(pos);\n if (node) {\n decos.push(Decoration.node(pos, pos + node.nodeSize, { class: styles.blockDropSettle }));\n }\n }\n }\n\n const handlePositions = getHandlePositions(\n doc,\n selection,\n pluginState.hoveredPos,\n pluginState.selectedPositions,\n pinnedPositions\n );\n\n const isMultiHandle = pluginState.selectedPositions.length > 1;\n for (const handlePos of handlePositions) {\n if (doc.nodeAt(handlePos)) {\n decos.push(createHandleWidget(handlePos, isMultiHandle));\n }\n }\n\n return DecorationSet.create(doc, decos);\n };\n\n return (\n state: EditorState,\n pinnedPositions: number[] | null,\n nativeSourcePositions: number[] | null\n ): DecorationSet => {\n const pluginState = blockDragHandlePluginKey.getState(state) ?? emptyState();\n if (pinnedPositions || nativeSourcePositions) {\n return build(state.doc, state.selection, pluginState, pinnedPositions, nativeSourcePositions);\n }\n const selectionKey = getSelectionDecorationKey(state.selection);\n const cached = cache.get(pluginState);\n if (cached && cached.selectionKey === selectionKey) {\n return cached.set;\n }\n const set = build(state.doc, state.selection, pluginState, null, null);\n cache.set(pluginState, { selectionKey, set });\n return set;\n };\n};\n\n// React nodes already paint some focus indication of their own — either custom rendering\n// (image/gif/video via `getContainerClasses`, button focus classes, etc.) or, absent that,\n// the legacy Styles HOC's own `pluginContainer`/`hasFocus` classes — so they should not also\n// get `.blockSelected` on the outer PM node shell. `hide-selection` is the node's own opt-out\n// of that (e.g. collapsible-list/-item still rely on `.blockSelected` rather than painting a\n// ring themselves) — read here rather than re-deriving the same fact from unrelated groups.\nconst getTypesWithOwnFocusRing = (extensions: RicosExtension[]): ReadonlySet<string> =>\n new Set(\n extensions\n .filter(\n extension => extension.type === 'react-node' && !extension.groups.includes('hide-selection')\n )\n .map(({ name }) => name)\n );\n\nexport const createBlockDragHandlePlugin = (extensions: RicosExtension[], t: TFunction): Plugin => {\n const typesWithOwnFocusRing = getTypesWithOwnFocusRing(extensions);\n const dragVisuals = createDragVisuals();\n const buildDecorations = createDecorationBuilder(\n t,\n typesWithOwnFocusRing,\n dragVisuals.handleLifecycle\n );\n let hoverRafId: number | null = null;\n let pendingHover: { clientX: number; clientY: number } | null = null;\n\n const cancelScheduledHoverUpdate = () => {\n if (hoverRafId !== null) {\n cancelAnimationFrame(hoverRafId);\n hoverRafId = null;\n }\n pendingHover = null;\n };\n\n const flushScheduledHoverUpdate = (view: EditorView) => {\n hoverRafId = null;\n const pending = pendingHover;\n pendingHover = null;\n if (!pending) {\n return;\n }\n applyHoverAtPointer(view, pending.clientX, pending.clientY);\n };\n\n const scheduleHoverUpdate = (view: EditorView, clientX: number, clientY: number) => {\n pendingHover = { clientX, clientY };\n if (hoverRafId !== null) {\n return;\n }\n hoverRafId = requestAnimationFrame(() => flushScheduledHoverUpdate(view));\n };\n\n return new Plugin<BlockDragHandleState>({\n key: blockDragHandlePluginKey,\n state: {\n init: () => emptyState(),\n apply(tr, prev) {\n const meta = tr.getMeta(blockDragHandlePluginKey);\n if (meta !== undefined) {\n return meta;\n }\n if (tr.docChanged) {\n dragVisuals.mapDraggingPositions(tr);\n\n return {\n hoveredPos: null,\n selectedPositions: mapSelectedPositionsThroughTransaction(prev.selectedPositions, tr),\n selectionBox: null,\n };\n }\n return prev;\n },\n },\n view(editorView) {\n dragVisuals.setView(editorView);\n const marquee = document.createElement('div');\n marquee.className = styles.blockSelectMarquee;\n marquee.setAttribute('aria-hidden', 'true');\n document.body.append(marquee);\n\n // Lazily resolved — cached after first use so neither per-transaction marquee syncs\n // nor the document-level mousemove below walk the DOM (a getComputedStyle per\n // ancestor) every time.\n let scrollParent: Element | null | undefined; // undefined = not yet resolved\n const getCachedScrollParent = (): Element | null => {\n if (scrollParent === undefined) {\n scrollParent = getScrollParent(editorView.dom);\n }\n return scrollParent;\n };\n\n const syncMarquee = () => {\n const box = getPluginState(editorView).selectionBox;\n if (!box) {\n marquee.style.display = 'none';\n return;\n }\n // selectionBox is in viewport (clientX/Y) coordinates — use directly for position:fixed CSS.\n // Clamp to the scroll container's visible rect so the marquee doesn't overflow the editor.\n const raw = normalizeSelectBox(box);\n const clipParent = getCachedScrollParent();\n const clip = clipParent\n ? clipParent.getBoundingClientRect()\n : new DOMRect(0, 0, window.innerWidth, window.innerHeight);\n const top = Math.max(raw.top, clip.top);\n const bottom = Math.min(raw.bottom, clip.bottom);\n const left = Math.max(raw.left, clip.left);\n const right = Math.min(raw.right, clip.right);\n if (bottom <= top || right <= left) {\n marquee.style.display = 'none';\n return;\n }\n marquee.style.display = 'block';\n marquee.style.left = `${left}px`;\n marquee.style.top = `${top}px`;\n marquee.style.width = `${right - left}px`;\n marquee.style.height = `${bottom - top}px`;\n };\n\n syncMarquee();\n\n // Capture-phase listener: intercepts mousedown before child native listeners\n // (e.g. image DraggableHOC) can call stopPropagation and swallow the event.\n // Only activates for clicks in the editor's left gutter on blocks that have\n // no visible handle. Blocks with handles are handled by the\n // bubble-phase handleDOMEvents.mousedown via hoveredPositions.\n const onMouseDownCapture = (event: MouseEvent) => {\n if (event.button !== 0 || !isEditable(editorView)) {\n return;\n }\n if (isDragHandleTarget(event.target)) {\n return;\n }\n if (yieldsToOwnMousedownTarget(editorView, event.target)) {\n return;\n }\n // Text targets can clear selection via the bubble handler — don't intercept them.\n // Only capture for non-text targets (images, etc.) whose DraggableHOC calls\n // stopPropagation and prevents the bubble handler from running.\n if (isTextEditTarget(event.target)) {\n return;\n }\n // The zone check covers the editor-level gutter strip and, for blocks with their\n // own internal gutter (e.g. smart blocks), the hovered/selected blocks' handle\n // zones — the bubble handler uses this same fallback but is never reached when\n // node-views stop propagation on mousedown.\n if (!isPointerInActiveHandleZone(editorView, event.clientX, event.clientY)) {\n return;\n }\n if (!hasBlockAtY(editorView, event.clientY)) {\n return;\n }\n startBoxSelect(\n editorView,\n event,\n makeBoxSelectCallbacks(editorView, typesWithOwnFocusRing)\n );\n };\n\n editorView.dom.addEventListener('mousedown', onMouseDownCapture, {\n capture: true,\n });\n\n // Native body drags (an image dragged by its body, a divider, …) get the grip\n // drag's pickup visuals — card ghost + source dim — while their drop stays stock\n // ProseMirror (droppable into layout cells). Document-level bubble ON PURPOSE:\n // tiptap's React node-view onDragStart is delegated at the React root (outside\n // view.dom), where it dispatches the NodeSelection and sets its own drag image —\n // running after it means the selection is resolvable and the last setDragImage\n // (ours, the card) is the one the browser uses.\n const onDocumentDragStart = (event: DragEvent) => {\n if (!isEditable(editorView) || !event.dataTransfer) {\n return;\n }\n const target = event.target;\n if (!(target instanceof Element) || !editorView.dom.contains(target)) {\n return;\n }\n // Grip drags build their ghost in their own dragstart listener (dom.ts).\n if (target.closest('[data-block-drag-handle]')) {\n return;\n }\n const pos = resolveNativeDragPos(editorView, target);\n const node = pos !== null ? editorView.state.doc.nodeAt(pos) : null;\n if (pos === null || !node || NATIVE_DRAG_VISUALS_EXCLUDED.has(node.type.name)) {\n return;\n }\n const dom = editorView.nodeDOM(pos);\n if (!(dom instanceof HTMLElement)) {\n return;\n }\n buildDragGhost(dom, [pos], event.dataTransfer, event.clientX, event.clientY);\n dragVisuals.nativeLifecycle.onDragStart([pos]);\n };\n document.addEventListener('dragstart', onDocumentDragStart);\n\n // Deferred a frame: a nodeView that grows on this transaction only reaches its new\n // size once React has rendered it, so measuring inline would still read the\n // pre-change layout.\n let remeasureRafId = 0;\n const scheduleHandleRemeasure = () => {\n if (remeasureRafId) {\n return;\n }\n remeasureRafId = requestAnimationFrame(() => {\n remeasureRafId = 0;\n remeasureHandleElements(editorView);\n });\n };\n\n return {\n update() {\n // Read-only can be turned on mid-interaction (`setEditable(false)`), which the\n // event-level guards can't see: they only stop what starts afterwards. Retire\n // whatever is already in flight so no grip, marquee or drag outlives editing.\n if (!isEditable(editorView)) {\n cancelActiveBoxSelect(editorView);\n clearDraggingPositions(editorView);\n clearSelectedBlocks(editorView);\n dragVisuals.nativeLifecycle.onDragEnd();\n }\n syncMarquee();\n scheduleHandleRemeasure();\n },\n destroy() {\n editorView.dom.removeEventListener('mousedown', onMouseDownCapture, {\n capture: true,\n });\n document.removeEventListener('dragstart', onDocumentDragStart);\n // A marquee still in flight owns window/document listeners and an auto-scroll\n // RAF that outlive the view: its next pointermove would dispatch into a\n // destroyed view, and its pointerup would measure blocks through a null docView.\n cancelActiveBoxSelect(editorView);\n cancelScheduledHoverUpdate();\n if (remeasureRafId) {\n cancelAnimationFrame(remeasureRafId);\n }\n marquee.remove();\n dragVisuals.setView(null);\n },\n };\n },\n props: {\n handleDOMEvents: {\n dragend(view) {\n // Grip drags clean up via their own button listener; this is a backstop for\n // drags that end without a drop in this editor (Escape-cancelled, or dropped\n // outside) in case the button's own dragend never fires. Idempotent.\n clearDraggingPositions(view);\n dragDropInsertPos.clear(view);\n dragVisuals.nativeLifecycle.onDragEnd();\n return false;\n },\n dragover(view, event) {\n const active = isEditable(view) && isBlockDragHandleDrop(view);\n if (active) {\n // Runs before the drop cursor's own listener (ProseMirror registers its\n // DOM handlers during construction, ahead of plugin views), so the\n // position published here is what the cursor reads this same frame.\n // Deliberately synchronous, not RAF-throttled like the hover path: deferring\n // this a frame desyncs it from the drop cursor's own same-tick read, which\n // is exactly the \"cursor and drop diverge\" class of bug this plugin's drop\n // resolution was built to eliminate (confirmed by reverting to throttled and\n // watching the drop-cursor-agreement browser spec fail).\n publishDropInsertPos(view, event.clientX, event.clientY);\n event.preventDefault();\n return true;\n }\n return false;\n },\n drop(view, event) {\n const active = isEditable(view) && isBlockDragHandleDrop(view);\n if (!active) {\n // A native drag's drop is ProseMirror's to perform (return false) — its\n // dispatch renders the cleared drag-source state in the same frame. The\n // settle pop is scheduled for one tick later, once that dispatch has landed.\n dragVisuals.scheduleNativeDropSettle(event);\n dragVisuals.nativeLifecycle.onDropCommit();\n return false;\n }\n // Always swallow the event for handle drags — even when dispatchHandleDragDrop\n // is a no-op (same-place drop). If we return false, ProseMirror's built-in\n // handler fires with view.dragging still set and inserts the slice as a copy.\n // preventDefault is on us (PM does not call it for custom handlers): without\n // it the browser still performs its own default drop behavior.\n event.preventDefault();\n dragVisuals.handleLifecycle.onDropCommit();\n const dispatched = dispatchHandleDragDrop(view, event);\n if (!dispatched) {\n // A no-op drop (same place, rejected target) dispatches nothing, but the\n // pickup decorations still need a render to retire — without this poke the\n // blocks stay dimmed until the next unrelated transaction.\n dragVisuals.pokeDecorations();\n }\n clearDraggingPositions(view);\n dragDropInsertPos.clear(view);\n view.dragging = null;\n // Belt-and-suspenders: normally cleared by the source button's own `dragend`,\n // but a drop that moves the block upward can destroy that button (its decoration\n // no longer exists at the old position) before `dragend` fires on it, stranding\n // the pin at a stale position.\n dragVisuals.handleLifecycle.onDragEnd();\n return true;\n },\n mousedown(view, event) {\n if (!isEditable(view)) {\n return false;\n }\n // A pending hover update (scheduled on the pre-click mousemove) would dispatch a\n // plugin-state transaction mid-click. Racing the browser's native click-to-caret\n // placement, that misplaces the caret — e.g. clicking a table cell lands the caret\n // outside the table. Cancel it here so the click resolves against a stable doc.\n cancelScheduledHoverUpdate();\n if (event.button !== 0) {\n return false;\n }\n if (isDragHandleTarget(event.target)) {\n return false;\n }\n if (yieldsToOwnMousedownTarget(view, event.target)) {\n return false;\n }\n\n if (isTextEditTarget(event.target)) {\n // A plain click on editable text is a caret click even inside the handle band\n // (it reaches 28px into the block): a marquee here would swallow the caret.\n // The block's own padding before its content edge is gutter, not text.\n if (!event.shiftKey) {\n if (!isPointerInTextBlockInset(view, event)) {\n clearSelectedBlocks(view);\n return false;\n }\n // A plain click there still means \"caret on this line\" (an empty paragraph's\n // padding is all there is to click) — only a drag turns it into a marquee.\n const { clientX, clientY } = event;\n startBoxSelect(view, event, {\n ...makeBoxSelectCallbacks(view, typesWithOwnFocusRing),\n onPlainClick: () => placeCaretAtCoords(view, clientX, clientY),\n });\n return true;\n } else if (\n event.target instanceof Element &&\n getComputedStyle(event.target).display.startsWith('inline')\n ) {\n // Shift-click on inline content (links, spans, etc.) — let PM handle it so the\n // link toolbar and selection extension still work.\n return false;\n }\n } else if (\n !event.shiftKey &&\n !isPointerInActiveHandleZone(view, event.clientX, event.clientY)\n ) {\n // Box-select starts from the handle zone (grip area) without a modifier, and\n // from anywhere else with Shift.\n return false;\n }\n\n startBoxSelect(view, event, makeBoxSelectCallbacks(view, typesWithOwnFocusRing));\n return true;\n },\n keydown(view, event) {\n if (event.key === 'Escape') {\n // Table owns Escape (edit → cell selection → whole table). Don't dispatch\n // mid-keydown and race TableEscapeNavigation.\n if (isSelectionInsideTable(view.state.selection)) {\n return false;\n }\n clearDraggingPositions(view);\n clearSelectedBlocks(view);\n }\n return false;\n },\n mousemove(view, event) {\n if (!isEditable(view)) {\n return false;\n }\n if (isHandleDragActive(view)) {\n return false;\n }\n // Don't refresh hover while a button is held — the pointer is mid-click or\n // mid-selection, and a hover dispatch there races native caret placement.\n if (event.buttons !== 0) {\n return false;\n }\n scheduleHoverUpdate(view, event.clientX, event.clientY);\n return false;\n },\n mouseleave(view) {\n cancelScheduledHoverUpdate();\n if (isHandleDragActive(view)) {\n return false;\n }\n clearHoveredPos(view);\n return false;\n },\n },\n decorations: state =>\n buildDecorations(\n state,\n dragVisuals.pinnedHandlePositions(),\n dragVisuals.nativeDragPositions()\n ),\n },\n });\n};\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAA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BAAO;AAAA,QACT;AAAA,QACA,WAAW,MAAM;AACf,qCAA2B;AAC3B,kBAAI,sCAAmB,IAAI,GAAG;AAC5B,mBAAO;AAAA,UACT;AACA,0BAAgB,IAAI;AACpB,iBAAO;AAAA,QACT;AAAA,MACF;AAAA,MACA,aAAa,WACX;AAAA,QACE;AAAA,QACA,YAAY,sBAAsB;AAAA,QAClC,YAAY,oBAAoB;AAAA,MAClC;AAAA,IACJ;AAAA,EACF,CAAC;AACH;",
6
6
  "names": ["styles"]
7
7
  }
@@ -22,13 +22,13 @@ __export(styles_exports, {
22
22
  });
23
23
  module.exports = __toCommonJS(styles_exports);
24
24
  var styles_default = {
25
- "blockSelected": "MVPD-",
26
- "blockDragSource": "Qafg5",
27
- "blockDropSettle": "_9MQom",
28
- "block-drop-settle": "R4mkh",
29
- "blockDragHandle": "KeskF",
30
- "visible": "MUU-v",
31
- "blockDragHandleButton": "nFIrS",
32
- "blockSelectMarquee": "j6JZ5"
25
+ "blockSelected": "CKmcD",
26
+ "blockDragSource": "ttFdR",
27
+ "blockDropSettle": "_60ynF",
28
+ "block-drop-settle": "KEzPo",
29
+ "blockDragHandle": "P9YIb",
30
+ "visible": "kVWBV",
31
+ "blockDragHandleButton": "JwVzr",
32
+ "blockSelectMarquee": "bqOW5"
33
33
  };
34
34
  //# sourceMappingURL=styles-scss.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/plugin-block-drag-handle/styles.scss"],
4
- "sourcesContent": ["export default {\n \"blockSelected\": \"MVPD-\",\n \"blockDragSource\": \"Qafg5\",\n \"blockDropSettle\": \"_9MQom\",\n \"block-drop-settle\": \"R4mkh\",\n \"blockDragHandle\": \"KeskF\",\n \"visible\": \"MUU-v\",\n \"blockDragHandleButton\": \"nFIrS\",\n \"blockSelectMarquee\": \"j6JZ5\"\n};"],
4
+ "sourcesContent": ["export default {\n \"blockSelected\": \"CKmcD\",\n \"blockDragSource\": \"ttFdR\",\n \"blockDropSettle\": \"_60ynF\",\n \"block-drop-settle\": \"KEzPo\",\n \"blockDragHandle\": \"P9YIb\",\n \"visible\": \"kVWBV\",\n \"blockDragHandleButton\": \"JwVzr\",\n \"blockSelectMarquee\": \"bqOW5\"\n};"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAAO,iBAAQ;AAAA,EACb,iBAAiB;AAAA,EACjB,mBAAmB;AAAA,EACnB,mBAAmB;AAAA,EACnB,qBAAqB;AAAA,EACrB,mBAAmB;AAAA,EACnB,WAAW;AAAA,EACX,yBAAyB;AAAA,EACzB,sBAAsB;AACxB;",
6
6
  "names": []
7
7
  }
@@ -22,7 +22,7 @@ __export(button_input_modal_exports, {
22
22
  });
23
23
  module.exports = __toCommonJS(button_input_modal_exports);
24
24
  var button_input_modal_default = {
25
- "content": "Hq2Y3",
26
- "modal": "_78dex"
25
+ "content": "uVlPG",
26
+ "modal": "C5fUj"
27
27
  };
28
28
  //# sourceMappingURL=button-input-modal-scss.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../src/plugin-button/statics/styles/button-input-modal.scss"],
4
- "sourcesContent": ["export default {\n \"content\": \"Hq2Y3\",\n \"modal\": \"_78dex\"\n};"],
4
+ "sourcesContent": ["export default {\n \"content\": \"uVlPG\",\n \"modal\": \"C5fUj\"\n};"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAAO,6BAAQ;AAAA,EACb,WAAW;AAAA,EACX,SAAS;AACX;",
6
6
  "names": []
7
7
  }
@@ -22,6 +22,6 @@ __export(button_text_field_exports, {
22
22
  });
23
23
  module.exports = __toCommonJS(button_text_field_exports);
24
24
  var button_text_field_default = {
25
- "formField": "fTDQW"
25
+ "formField": "PyKrx"
26
26
  };
27
27
  //# sourceMappingURL=button-text-field-scss.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../src/plugin-button/statics/styles/button-text-field.scss"],
4
- "sourcesContent": ["export default {\n \"formField\": \"fTDQW\"\n};"],
4
+ "sourcesContent": ["export default {\n \"formField\": \"PyKrx\"\n};"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAAO,4BAAQ;AAAA,EACb,aAAa;AACf;",
6
6
  "names": []
7
7
  }
@@ -22,10 +22,10 @@ __export(default_styles_exports, {
22
22
  });
23
23
  module.exports = __toCommonJS(default_styles_exports);
24
24
  var default_styles_default = {
25
- "button_container": "L7MQS",
26
- "button_text": "_3gdeY",
27
- "button_text_editor": "oGTzb",
28
- "button_text_input": "nsaAd",
29
- "button_size_content": "loMaF"
25
+ "button_container": "_8G2EF",
26
+ "button_text": "Xaaib",
27
+ "button_text_editor": "_6u2am",
28
+ "button_text_input": "z2jX0",
29
+ "button_size_content": "-NoYR"
30
30
  };
31
31
  //# sourceMappingURL=default-styles-scss.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../src/plugin-button/statics/styles/default-styles.scss"],
4
- "sourcesContent": ["export default {\n \"button_container\": \"L7MQS\",\n \"button_text\": \"_3gdeY\",\n \"button_text_editor\": \"oGTzb\",\n \"button_text_input\": \"nsaAd\",\n \"button_size_content\": \"loMaF\"\n};"],
4
+ "sourcesContent": ["export default {\n \"button_container\": \"_8G2EF\",\n \"button_text\": \"Xaaib\",\n \"button_text_editor\": \"_6u2am\",\n \"button_text_input\": \"z2jX0\",\n \"button_size_content\": \"-NoYR\"\n};"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAAO,yBAAQ;AAAA,EACb,oBAAoB;AAAA,EACpB,eAAe;AAAA,EACf,sBAAsB;AAAA,EACtB,qBAAqB;AAAA,EACrB,uBAAuB;AACzB;",
6
6
  "names": []
7
7
  }
@@ -146,7 +146,13 @@ const updateCardView = (cardElement, contentElement, boundaryLineWrapper, bounda
146
146
  }
147
147
  };
148
148
  const createCardNodeView = (options) => {
149
- const { renderCardHeader, isMobile, getBoundaryWarningPortal } = options;
149
+ const {
150
+ renderCardHeader,
151
+ renderAddPageButton,
152
+ isMobile,
153
+ getBoundaryWarningPortal,
154
+ showPageControls = true
155
+ } = options;
150
156
  return ({ node, editor, getPos }) => {
151
157
  let currentNode = node;
152
158
  const cardWrapper = document.createElement("div");
@@ -154,31 +160,17 @@ const createCardNodeView = (options) => {
154
160
  let headerContainer = null;
155
161
  let headerRenderer = null;
156
162
  const getCardIndex = () => {
157
- const doc = editor.state.doc;
158
163
  const cardPos = getPos();
159
164
  if (typeof cardPos !== "number") {
160
165
  return 0;
161
166
  }
162
- let currentIndex = 0;
163
- let found = false;
164
- doc.forEach((docNode, pos) => {
165
- if (found) {
166
- return;
167
- }
168
- if (docNode.type.name === "CARD") {
169
- currentIndex++;
170
- if (pos === cardPos) {
171
- found = true;
172
- }
173
- }
174
- });
175
- const pendingInsertions = getCardStorage(editor).pendingCardInsertions;
176
- for (const insertion of pendingInsertions) {
177
- if (insertion.afterCardIndex < currentIndex) {
178
- currentIndex += insertion.count;
167
+ let index = editor.state.doc.resolve(cardPos).index(0);
168
+ for (const insertion of getCardStorage(editor).pendingCardInsertions) {
169
+ if (insertion.afterCardIndex <= index) {
170
+ index += insertion.count;
179
171
  }
180
172
  }
181
- return currentIndex;
173
+ return index;
182
174
  };
183
175
  const getIsLastCard = () => {
184
176
  const doc = editor.state.doc;
@@ -209,7 +201,8 @@ const createCardNodeView = (options) => {
209
201
  editor,
210
202
  props: {
211
203
  cardNode: currentNode,
212
- index: getCardIndex()
204
+ // CardHeaderProps.index is the 1-based page number
205
+ index: getCardIndex() + 1
213
206
  }
214
207
  });
215
208
  headerContainer.appendChild(headerRenderer.element);
@@ -250,7 +243,7 @@ const createCardNodeView = (options) => {
250
243
  selectionSvg.appendChild(selectionRect);
251
244
  cardElement.append(contentElement, boundaryLineWrapper, selectionSvg);
252
245
  const cardGap = document.createElement("div");
253
- cardGap.className = import_card_scss.default.cardGap;
246
+ cardGap.className = showPageControls ? import_card_scss.default.cardGap : `${import_card_scss.default.cardGap} ${import_card_scss.default.noControls}`;
254
247
  cardGap.setAttribute("contenteditable", "false");
255
248
  const updateLastCardClass = () => {
256
249
  const isLast = getIsLastCard();
@@ -295,16 +288,31 @@ const createCardNodeView = (options) => {
295
288
  const handleMergeHoverChange = (isHovered) => {
296
289
  cardGap.classList.toggle(import_card_scss.default.mergeHover, isHovered);
297
290
  };
298
- const pageGapRenderer = new import_react.ReactRenderer(import_page_gap.PageGap, {
291
+ let pageGapState = { isLastCard: getIsLastCard(), index: getCardIndex() };
292
+ const pageGapRenderer = showPageControls ? new import_react.ReactRenderer(import_page_gap.PageGap, {
299
293
  editor,
300
294
  props: {
301
295
  onAddPage: handleAddPage,
302
296
  onMergePages: handleMergePages,
303
297
  onMergeHoverChange: handleMergeHoverChange,
304
- isLastCard: getIsLastCard()
298
+ ...pageGapState,
299
+ renderAddPageButton
305
300
  }
306
- });
307
- cardGap.appendChild(pageGapRenderer.element);
301
+ }) : null;
302
+ const updatePageGap = () => {
303
+ if (!pageGapRenderer) {
304
+ return;
305
+ }
306
+ const isLastCard = getIsLastCard();
307
+ const index = getCardIndex();
308
+ if (isLastCard !== pageGapState.isLastCard || index !== pageGapState.index) {
309
+ pageGapState = { isLastCard, index };
310
+ pageGapRenderer.updateProps(pageGapState);
311
+ }
312
+ };
313
+ if (pageGapRenderer) {
314
+ cardGap.appendChild(pageGapRenderer.element);
315
+ }
308
316
  cardWrapper.append(cardElement, cardGap);
309
317
  const resizeObserver = new ResizeObserver(() => {
310
318
  updateCardView(
@@ -329,12 +337,10 @@ const createCardNodeView = (options) => {
329
337
  if (headerRenderer) {
330
338
  headerRenderer.updateProps({
331
339
  cardNode: currentNode,
332
- index: getCardIndex()
340
+ index: getCardIndex() + 1
333
341
  });
334
342
  }
335
- pageGapRenderer.updateProps({
336
- isLastCard: getIsLastCard()
337
- });
343
+ updatePageGap();
338
344
  updateLastCardClass();
339
345
  };
340
346
  editor.on("update", updateHeaderIndex);
@@ -390,12 +396,10 @@ const createCardNodeView = (options) => {
390
396
  if (headerRenderer) {
391
397
  headerRenderer.updateProps({
392
398
  cardNode: currentNode,
393
- index: getCardIndex()
399
+ index: getCardIndex() + 1
394
400
  });
395
401
  }
396
- pageGapRenderer.updateProps({
397
- isLastCard: getIsLastCard()
398
- });
402
+ updatePageGap();
399
403
  updateLastCardClass();
400
404
  return true;
401
405
  },
@@ -421,7 +425,7 @@ const createCardNodeView = (options) => {
421
425
  getCardStorage(editor).onPageFormatChange.delete(handlePageFormatChange);
422
426
  getCardStorage(editor).onPendingCardInsertionsChange.delete(updateHeaderIndex);
423
427
  boundaryLineRenderer.destroy();
424
- pageGapRenderer.destroy();
428
+ pageGapRenderer?.destroy();
425
429
  if (headerRenderer) {
426
430
  headerRenderer.destroy();
427
431
  }