@frontify/guideline-blocks-settings 0.28.0 → 0.28.2

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 (307) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/dist/_virtual/jsx-runtime.es.js +5 -0
  3. package/dist/_virtual/jsx-runtime.es.js.map +1 -0
  4. package/dist/_virtual/react-jsx-runtime.development.es.js +5 -0
  5. package/dist/_virtual/react-jsx-runtime.development.es.js.map +1 -0
  6. package/dist/_virtual/react-jsx-runtime.production.min.es.js +5 -0
  7. package/dist/_virtual/react-jsx-runtime.production.min.es.js.map +1 -0
  8. package/dist/components/Attachments/AttachmentItem.es.js +180 -0
  9. package/dist/components/Attachments/AttachmentItem.es.js.map +1 -0
  10. package/dist/components/Attachments/Attachments.es.js +145 -0
  11. package/dist/components/Attachments/Attachments.es.js.map +1 -0
  12. package/dist/components/BlockInjectButton/BlockInjectButton.es.js +150 -0
  13. package/dist/components/BlockInjectButton/BlockInjectButton.es.js.map +1 -0
  14. package/dist/components/BlockItemWrapper/BlockItemWrapper.es.js +73 -0
  15. package/dist/components/BlockItemWrapper/BlockItemWrapper.es.js.map +1 -0
  16. package/dist/components/BlockItemWrapper/Toolbar.es.js +113 -0
  17. package/dist/components/BlockItemWrapper/Toolbar.es.js.map +1 -0
  18. package/dist/components/BlockItemWrapper/constants.es.js +6 -0
  19. package/dist/components/BlockItemWrapper/constants.es.js.map +1 -0
  20. package/dist/components/DownloadButton/DownloadButton.es.js +39 -0
  21. package/dist/components/DownloadButton/DownloadButton.es.js.map +1 -0
  22. package/dist/components/RichTextEditor/RichTextEditor.es.js +42 -0
  23. package/dist/components/RichTextEditor/RichTextEditor.es.js.map +1 -0
  24. package/dist/components/RichTextEditor/SerializedText.es.js +13 -0
  25. package/dist/components/RichTextEditor/SerializedText.es.js.map +1 -0
  26. package/dist/components/RichTextEditor/constants.es.js +5 -0
  27. package/dist/components/RichTextEditor/constants.es.js.map +1 -0
  28. package/dist/components/RichTextEditor/pluginPresets/defaultPluginsWithLinkChooser.es.js +34 -0
  29. package/dist/components/RichTextEditor/pluginPresets/defaultPluginsWithLinkChooser.es.js.map +1 -0
  30. package/dist/components/RichTextEditor/plugins/ButtonPlugin/ButtonMarkupElement/ButtonMarkupElementNode.es.js +54 -0
  31. package/dist/components/RichTextEditor/plugins/ButtonPlugin/ButtonMarkupElement/ButtonMarkupElementNode.es.js.map +1 -0
  32. package/dist/components/RichTextEditor/plugins/ButtonPlugin/ButtonMarkupElement/index.es.js +12 -0
  33. package/dist/components/RichTextEditor/plugins/ButtonPlugin/ButtonMarkupElement/index.es.js.map +1 -0
  34. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/ButtonButton.es.js +17 -0
  35. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/ButtonButton.es.js.map +1 -0
  36. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/ButtonToolbarButton.es.js +30 -0
  37. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/ButtonToolbarButton.es.js.map +1 -0
  38. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/CustomFloatingButton.es.js +16 -0
  39. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/CustomFloatingButton.es.js.map +1 -0
  40. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/EditButtonModal/EditModal.es.js +37 -0
  41. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/EditButtonModal/EditModal.es.js.map +1 -0
  42. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/FloatingButton.es.js +25 -0
  43. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/FloatingButton.es.js.map +1 -0
  44. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/FloatingButtonEditButton.es.js +20 -0
  45. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/FloatingButtonEditButton.es.js.map +1 -0
  46. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/FloatingButtonUrlInput.es.js +26 -0
  47. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/FloatingButtonUrlInput.es.js.map +1 -0
  48. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/InsertButtonModal/InsertButtonModal.es.js +69 -0
  49. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/InsertButtonModal/InsertButtonModal.es.js.map +1 -0
  50. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/InsertButtonModal/useInsertModal.es.js +105 -0
  51. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/InsertButtonModal/useInsertModal.es.js.map +1 -0
  52. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/UnlinkButton.es.js +20 -0
  53. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/UnlinkButton.es.js.map +1 -0
  54. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/floatingButtonStore.es.js +32 -0
  55. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/floatingButtonStore.es.js.map +1 -0
  56. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useFloatingButtonEdit.es.js +58 -0
  57. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useFloatingButtonEdit.es.js.map +1 -0
  58. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useFloatingButtonEnter.es.js +19 -0
  59. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useFloatingButtonEnter.es.js.map +1 -0
  60. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useFloatingButtonEscape.es.js +26 -0
  61. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useFloatingButtonEscape.es.js.map +1 -0
  62. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useFloatingButtonInsert.es.js +43 -0
  63. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useFloatingButtonInsert.es.js.map +1 -0
  64. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useVirtualFloatingButton.es.js +18 -0
  65. package/dist/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useVirtualFloatingButton.es.js.map +1 -0
  66. package/dist/components/RichTextEditor/plugins/ButtonPlugin/createButtonPlugin.es.js +62 -0
  67. package/dist/components/RichTextEditor/plugins/ButtonPlugin/createButtonPlugin.es.js.map +1 -0
  68. package/dist/components/RichTextEditor/plugins/ButtonPlugin/transforms/insertButton.es.js +13 -0
  69. package/dist/components/RichTextEditor/plugins/ButtonPlugin/transforms/insertButton.es.js.map +1 -0
  70. package/dist/components/RichTextEditor/plugins/ButtonPlugin/transforms/submitFloatingButton.es.js +25 -0
  71. package/dist/components/RichTextEditor/plugins/ButtonPlugin/transforms/submitFloatingButton.es.js.map +1 -0
  72. package/dist/components/RichTextEditor/plugins/ButtonPlugin/transforms/unwrapButton.es.js +35 -0
  73. package/dist/components/RichTextEditor/plugins/ButtonPlugin/transforms/unwrapButton.es.js.map +1 -0
  74. package/dist/components/RichTextEditor/plugins/ButtonPlugin/transforms/upsertButton.es.js +86 -0
  75. package/dist/components/RichTextEditor/plugins/ButtonPlugin/transforms/upsertButton.es.js.map +1 -0
  76. package/dist/components/RichTextEditor/plugins/ButtonPlugin/transforms/upsertButtonText.es.js +24 -0
  77. package/dist/components/RichTextEditor/plugins/ButtonPlugin/transforms/upsertButtonText.es.js.map +1 -0
  78. package/dist/components/RichTextEditor/plugins/ButtonPlugin/transforms/wrapButton.es.js +19 -0
  79. package/dist/components/RichTextEditor/plugins/ButtonPlugin/transforms/wrapButton.es.js.map +1 -0
  80. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/createButtonNode.es.js +13 -0
  81. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/createButtonNode.es.js.map +1 -0
  82. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/getButtonStyle.es.js +11 -0
  83. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/getButtonStyle.es.js.map +1 -0
  84. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/getUrl.es.js +10 -0
  85. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/getUrl.es.js.map +1 -0
  86. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/styles.es.js +75 -0
  87. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/styles.es.js.map +1 -0
  88. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/triggerFloatingButton.es.js +18 -0
  89. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/triggerFloatingButton.es.js.map +1 -0
  90. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/triggerFloatingButtonEdit.es.js +17 -0
  91. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/triggerFloatingButtonEdit.es.js.map +1 -0
  92. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/triggerFloatingButtonInsert.es.js +14 -0
  93. package/dist/components/RichTextEditor/plugins/ButtonPlugin/utils/triggerFloatingButtonInsert.es.js.map +1 -0
  94. package/dist/components/RichTextEditor/plugins/ButtonPlugin/withButton.es.js +53 -0
  95. package/dist/components/RichTextEditor/plugins/ButtonPlugin/withButton.es.js.map +1 -0
  96. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/CustomFloatingLink.es.js +19 -0
  97. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/CustomFloatingLink.es.js.map +1 -0
  98. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/EditLinkModal/EditModal.es.js +37 -0
  99. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/EditLinkModal/EditModal.es.js.map +1 -0
  100. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/EditLinkModal/useFloatingLinkEdit.es.js +53 -0
  101. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/EditLinkModal/useFloatingLinkEdit.es.js.map +1 -0
  102. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/FloatingLink.es.js +29 -0
  103. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/FloatingLink.es.js.map +1 -0
  104. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/InsertLinkModal/InsertLinkModal.es.js +8 -0
  105. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/InsertLinkModal/InsertLinkModal.es.js.map +1 -0
  106. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/InsertLinkModal/InsertModal.es.js +80 -0
  107. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/InsertLinkModal/InsertModal.es.js.map +1 -0
  108. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/InsertLinkModal/useFloatingLinkInsert.es.js +40 -0
  109. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/InsertLinkModal/useFloatingLinkInsert.es.js.map +1 -0
  110. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/InsertLinkModal/useInsertModal.es.js +93 -0
  111. package/dist/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/InsertLinkModal/useInsertModal.es.js.map +1 -0
  112. package/dist/components/RichTextEditor/plugins/LinkPlugin/LinkButton.es.js +25 -0
  113. package/dist/components/RichTextEditor/plugins/LinkPlugin/LinkButton.es.js.map +1 -0
  114. package/dist/components/RichTextEditor/plugins/LinkPlugin/LinkMarkupElement/LinkMarkupElementNode.es.js +27 -0
  115. package/dist/components/RichTextEditor/plugins/LinkPlugin/LinkMarkupElement/LinkMarkupElementNode.es.js.map +1 -0
  116. package/dist/components/RichTextEditor/plugins/LinkPlugin/LinkMarkupElement/index.es.js +12 -0
  117. package/dist/components/RichTextEditor/plugins/LinkPlugin/LinkMarkupElement/index.es.js.map +1 -0
  118. package/dist/components/RichTextEditor/plugins/LinkPlugin/id.es.js +5 -0
  119. package/dist/components/RichTextEditor/plugins/LinkPlugin/id.es.js.map +1 -0
  120. package/dist/components/RichTextEditor/plugins/LinkPlugin/index.es.js +39 -0
  121. package/dist/components/RichTextEditor/plugins/LinkPlugin/index.es.js.map +1 -0
  122. package/dist/components/RichTextEditor/plugins/LinkPlugin/utils/getUrl.es.js +18 -0
  123. package/dist/components/RichTextEditor/plugins/LinkPlugin/utils/getUrl.es.js.map +1 -0
  124. package/dist/components/RichTextEditor/plugins/LinkPlugin/utils/relativeUrlRegex.es.js +5 -0
  125. package/dist/components/RichTextEditor/plugins/LinkPlugin/utils/relativeUrlRegex.es.js.map +1 -0
  126. package/dist/components/RichTextEditor/plugins/LinkPlugin/utils/url.es.js +17 -0
  127. package/dist/components/RichTextEditor/plugins/LinkPlugin/utils/url.es.js.map +1 -0
  128. package/dist/components/RichTextEditor/plugins/TextStylePlugins/custom1Plugin.es.js +45 -0
  129. package/dist/components/RichTextEditor/plugins/TextStylePlugins/custom1Plugin.es.js.map +1 -0
  130. package/dist/components/RichTextEditor/plugins/TextStylePlugins/custom2Plugin.es.js +45 -0
  131. package/dist/components/RichTextEditor/plugins/TextStylePlugins/custom2Plugin.es.js.map +1 -0
  132. package/dist/components/RichTextEditor/plugins/TextStylePlugins/custom3Plugin.es.js +45 -0
  133. package/dist/components/RichTextEditor/plugins/TextStylePlugins/custom3Plugin.es.js.map +1 -0
  134. package/dist/components/RichTextEditor/plugins/TextStylePlugins/heading1Plugin.es.js +46 -0
  135. package/dist/components/RichTextEditor/plugins/TextStylePlugins/heading1Plugin.es.js.map +1 -0
  136. package/dist/components/RichTextEditor/plugins/TextStylePlugins/heading2Plugin.es.js +39 -0
  137. package/dist/components/RichTextEditor/plugins/TextStylePlugins/heading2Plugin.es.js.map +1 -0
  138. package/dist/components/RichTextEditor/plugins/TextStylePlugins/heading3Plugin.es.js +39 -0
  139. package/dist/components/RichTextEditor/plugins/TextStylePlugins/heading3Plugin.es.js.map +1 -0
  140. package/dist/components/RichTextEditor/plugins/TextStylePlugins/heading4Plugin.es.js +39 -0
  141. package/dist/components/RichTextEditor/plugins/TextStylePlugins/heading4Plugin.es.js.map +1 -0
  142. package/dist/components/RichTextEditor/plugins/TextStylePlugins/helpers.es.js +40 -0
  143. package/dist/components/RichTextEditor/plugins/TextStylePlugins/helpers.es.js.map +1 -0
  144. package/dist/components/RichTextEditor/plugins/TextStylePlugins/imageCaptionPlugin.es.js +46 -0
  145. package/dist/components/RichTextEditor/plugins/TextStylePlugins/imageCaptionPlugin.es.js.map +1 -0
  146. package/dist/components/RichTextEditor/plugins/TextStylePlugins/imageTitlePlugin.es.js +46 -0
  147. package/dist/components/RichTextEditor/plugins/TextStylePlugins/imageTitlePlugin.es.js.map +1 -0
  148. package/dist/components/RichTextEditor/plugins/TextStylePlugins/paragraphPlugin.es.js +41 -0
  149. package/dist/components/RichTextEditor/plugins/TextStylePlugins/paragraphPlugin.es.js.map +1 -0
  150. package/dist/components/RichTextEditor/plugins/TextStylePlugins/quotePlugin.es.js +48 -0
  151. package/dist/components/RichTextEditor/plugins/TextStylePlugins/quotePlugin.es.js.map +1 -0
  152. package/dist/components/RichTextEditor/plugins/shared/LinkSelector/DocumentLink.es.js +68 -0
  153. package/dist/components/RichTextEditor/plugins/shared/LinkSelector/DocumentLink.es.js.map +1 -0
  154. package/dist/components/RichTextEditor/plugins/shared/LinkSelector/DocumentLinks.es.js +55 -0
  155. package/dist/components/RichTextEditor/plugins/shared/LinkSelector/DocumentLinks.es.js.map +1 -0
  156. package/dist/components/RichTextEditor/plugins/shared/LinkSelector/LinkSelector.es.js +62 -0
  157. package/dist/components/RichTextEditor/plugins/shared/LinkSelector/LinkSelector.es.js.map +1 -0
  158. package/dist/components/RichTextEditor/plugins/shared/LinkSelector/PageLink.es.js +61 -0
  159. package/dist/components/RichTextEditor/plugins/shared/LinkSelector/PageLink.es.js.map +1 -0
  160. package/dist/components/RichTextEditor/plugins/shared/LinkSelector/PageLinks.es.js +34 -0
  161. package/dist/components/RichTextEditor/plugins/shared/LinkSelector/PageLinks.es.js.map +1 -0
  162. package/dist/components/RichTextEditor/plugins/shared/LinkSelector/SectionLink.es.js +26 -0
  163. package/dist/components/RichTextEditor/plugins/shared/LinkSelector/SectionLink.es.js.map +1 -0
  164. package/dist/components/RichTextEditor/plugins/styles.es.js +168 -0
  165. package/dist/components/RichTextEditor/plugins/styles.es.js.map +1 -0
  166. package/dist/components/RichTextEditor/serializer/nodes/button.es.js +16 -0
  167. package/dist/components/RichTextEditor/serializer/nodes/button.es.js.map +1 -0
  168. package/dist/components/RichTextEditor/serializer/nodes/checkItemNode.es.js +19 -0
  169. package/dist/components/RichTextEditor/serializer/nodes/checkItemNode.es.js.map +1 -0
  170. package/dist/components/RichTextEditor/serializer/nodes/default.es.js +17 -0
  171. package/dist/components/RichTextEditor/serializer/nodes/default.es.js.map +1 -0
  172. package/dist/components/RichTextEditor/serializer/nodes/link.es.js +15 -0
  173. package/dist/components/RichTextEditor/serializer/nodes/link.es.js.map +1 -0
  174. package/dist/components/RichTextEditor/serializer/nodes/mentionHtmlNode.es.js +12 -0
  175. package/dist/components/RichTextEditor/serializer/nodes/mentionHtmlNode.es.js.map +1 -0
  176. package/dist/components/RichTextEditor/serializer/serializeNodesToHtmlRecursive.es.js +61 -0
  177. package/dist/components/RichTextEditor/serializer/serializeNodesToHtmlRecursive.es.js.map +1 -0
  178. package/dist/components/RichTextEditor/serializer/serializeToHtml.es.js +25 -0
  179. package/dist/components/RichTextEditor/serializer/serializeToHtml.es.js.map +1 -0
  180. package/dist/components/RichTextEditor/serializer/utlis/reactCssPropsToCss.es.js +8 -0
  181. package/dist/components/RichTextEditor/serializer/utlis/reactCssPropsToCss.es.js.map +1 -0
  182. package/dist/components/RichTextEditor/serializer/utlis/serializeLeafToHtml.es.js +13 -0
  183. package/dist/components/RichTextEditor/serializer/utlis/serializeLeafToHtml.es.js.map +1 -0
  184. package/dist/helpers/addHttps.es.js +14 -0
  185. package/dist/helpers/addHttps.es.js.map +1 -0
  186. package/dist/helpers/convertToRichTextValue.es.js +6 -0
  187. package/dist/helpers/convertToRichTextValue.es.js.map +1 -0
  188. package/dist/helpers/customCoordinatesGetterFactory.es.js +32 -0
  189. package/dist/helpers/customCoordinatesGetterFactory.es.js.map +1 -0
  190. package/dist/helpers/hasRichTextValue.es.js +15 -0
  191. package/dist/helpers/hasRichTextValue.es.js.map +1 -0
  192. package/dist/helpers/isDownloadable.es.js +6 -0
  193. package/dist/helpers/isDownloadable.es.js.map +1 -0
  194. package/dist/helpers/mapColorPalettes.es.js +16 -0
  195. package/dist/helpers/mapColorPalettes.es.js.map +1 -0
  196. package/dist/hooks/useAttachments.es.js +31 -0
  197. package/dist/hooks/useAttachments.es.js.map +1 -0
  198. package/dist/hooks/useDndSensors.es.js +20 -0
  199. package/dist/hooks/useDndSensors.es.js.map +1 -0
  200. package/dist/index.cjs.js +46 -0
  201. package/dist/index.cjs.js.map +1 -0
  202. package/dist/index.d.ts +964 -0
  203. package/dist/index.es.js +178 -0
  204. package/dist/index.es.js.map +1 -0
  205. package/dist/index.umd.js +46 -0
  206. package/dist/index.umd.js.map +1 -0
  207. package/dist/settings/background.es.js +22 -0
  208. package/dist/settings/background.es.js.map +1 -0
  209. package/dist/settings/border.es.js +61 -0
  210. package/dist/settings/border.es.js.map +1 -0
  211. package/dist/settings/borderRadius.es.js +56 -0
  212. package/dist/settings/borderRadius.es.js.map +1 -0
  213. package/dist/settings/borderRadiusExtended.es.js +64 -0
  214. package/dist/settings/borderRadiusExtended.es.js.map +1 -0
  215. package/dist/settings/defaultValues.es.js +19 -0
  216. package/dist/settings/defaultValues.es.js.map +1 -0
  217. package/dist/settings/gutter.es.js +56 -0
  218. package/dist/settings/gutter.es.js.map +1 -0
  219. package/dist/settings/margin.es.js +53 -0
  220. package/dist/settings/margin.es.js.map +1 -0
  221. package/dist/settings/marginExtended.es.js +65 -0
  222. package/dist/settings/marginExtended.es.js.map +1 -0
  223. package/dist/settings/padding.es.js +53 -0
  224. package/dist/settings/padding.es.js.map +1 -0
  225. package/dist/settings/paddingExtended.es.js +65 -0
  226. package/dist/settings/paddingExtended.es.js.map +1 -0
  227. package/dist/settings/securityDownloadable.es.js +19 -0
  228. package/dist/settings/securityDownloadable.es.js.map +1 -0
  229. package/dist/settings/securityGlobalControl.es.js +33 -0
  230. package/dist/settings/securityGlobalControl.es.js.map +1 -0
  231. package/dist/settings/types.es.js +48 -0
  232. package/dist/settings/types.es.js.map +1 -0
  233. package/dist/styles.css +1 -0
  234. package/dist/styles.css.es.js +5 -0
  235. package/dist/styles.css.es.js.map +1 -0
  236. package/dist/utilities/color/getReadableColor.es.js +14 -0
  237. package/dist/utilities/color/getReadableColor.es.js.map +1 -0
  238. package/dist/utilities/color/isDark.es.js +10 -0
  239. package/dist/utilities/color/isDark.es.js.map +1 -0
  240. package/dist/utilities/color/setAlpha.es.js +6 -0
  241. package/dist/utilities/color/setAlpha.es.js.map +1 -0
  242. package/dist/utilities/color/toColorObject.es.js +9 -0
  243. package/dist/utilities/color/toColorObject.es.js.map +1 -0
  244. package/dist/utilities/color/toHex8String.es.js +7 -0
  245. package/dist/utilities/color/toHex8String.es.js.map +1 -0
  246. package/dist/utilities/color/toHexString.es.js +7 -0
  247. package/dist/utilities/color/toHexString.es.js.map +1 -0
  248. package/dist/utilities/color/toRgbaString.es.js +7 -0
  249. package/dist/utilities/color/toRgbaString.es.js.map +1 -0
  250. package/dist/utilities/color/toShortRgba.es.js +11 -0
  251. package/dist/utilities/color/toShortRgba.es.js.map +1 -0
  252. package/dist/utilities/moveItemInArray.es.js +12 -0
  253. package/dist/utilities/moveItemInArray.es.js.map +1 -0
  254. package/dist/utilities/react/getBackgroundColorStyles.es.js +8 -0
  255. package/dist/utilities/react/getBackgroundColorStyles.es.js.map +1 -0
  256. package/dist/utilities/react/getBorderStyles.es.js +12 -0
  257. package/dist/utilities/react/getBorderStyles.es.js.map +1 -0
  258. package/dist/utilities/react/getRadiusStyles.es.js +8 -0
  259. package/dist/utilities/react/getRadiusStyles.es.js.map +1 -0
  260. package/dist/utilities/react/joinClassNames.es.js +5 -0
  261. package/dist/utilities/react/joinClassNames.es.js.map +1 -0
  262. package/package.json +25 -24
  263. package/src/components/Attachments/AttachmentItem.tsx +2 -2
  264. package/src/components/Attachments/Attachments.spec.ct.tsx +4 -4
  265. package/src/components/Attachments/Attachments.tsx +2 -2
  266. package/src/components/BlockInjectButton/BlockInjectButton.spec.ct.tsx +2 -2
  267. package/src/components/BlockItemWrapper/BlockItemWrapper.spec.ct.tsx +8 -8
  268. package/src/components/BlockItemWrapper/Toolbar.tsx +1 -1
  269. package/src/components/RichTextEditor/RichTextEditor.spec.ct.tsx +8 -8
  270. package/src/components/RichTextEditor/pluginPresets/defaultPluginsWithLinkChooser.tsx +2 -2
  271. package/src/components/RichTextEditor/plugins/ButtonPlugin/components/ButtonToolbarButton.tsx +1 -1
  272. package/src/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/FloatingButtonUrlInput.tsx +1 -1
  273. package/src/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/InsertButtonModal/useInsertModal.ts +1 -1
  274. package/src/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useFloatingButtonEdit.ts +1 -1
  275. package/src/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useFloatingButtonEnter.ts +1 -1
  276. package/src/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useFloatingButtonEscape.ts +1 -1
  277. package/src/components/RichTextEditor/plugins/ButtonPlugin/components/FloatingButton/useFloatingButtonInsert.ts +1 -1
  278. package/src/components/RichTextEditor/plugins/ButtonPlugin/createButtonPlugin.ts +2 -0
  279. package/src/components/RichTextEditor/plugins/ButtonPlugin/transforms/insertButton.ts +2 -2
  280. package/src/components/RichTextEditor/plugins/ButtonPlugin/transforms/unwrapButton.ts +1 -1
  281. package/src/components/RichTextEditor/plugins/ButtonPlugin/transforms/upsertButton.ts +5 -5
  282. package/src/components/RichTextEditor/plugins/ButtonPlugin/transforms/wrapButton.ts +2 -2
  283. package/src/components/RichTextEditor/plugins/ButtonPlugin/utils/createButtonNode.ts +1 -1
  284. package/src/components/RichTextEditor/plugins/ButtonPlugin/utils/triggerFloatingButton.ts +1 -1
  285. package/src/components/RichTextEditor/plugins/ButtonPlugin/utils/triggerFloatingButtonInsert.ts +1 -1
  286. package/src/components/RichTextEditor/plugins/ButtonPlugin/withButton.ts +1 -1
  287. package/src/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/EditLinkModal/useFloatingLinkEdit.ts +1 -1
  288. package/src/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/InsertLinkModal/useFloatingLinkInsert.ts +1 -1
  289. package/src/components/RichTextEditor/plugins/LinkPlugin/FloatingLink/InsertLinkModal/useInsertModal.ts +1 -1
  290. package/src/components/RichTextEditor/plugins/LinkPlugin/LinkButton.tsx +1 -1
  291. package/src/components/RichTextEditor/plugins/LinkPlugin/utils/relativeUrlRegex.spec.ts +24 -27
  292. package/src/components/RichTextEditor/serializer/nodes/checkItemNode.ts +1 -1
  293. package/src/components/RichTextEditor/serializer/nodes/default.ts +2 -2
  294. package/src/components/RichTextEditor/serializer/nodes/link.ts +1 -1
  295. package/src/components/RichTextEditor/serializer/serializeNodesToHtmlRecursive.ts +4 -4
  296. package/src/components/RichTextEditor/serializer/serializeToHtml.ts +2 -2
  297. package/src/hooks/useAttachments.ts +1 -1
  298. package/src/hooks/useDndSensors.ts +1 -1
  299. package/src/index.ts +3 -3
  300. package/src/settings/background.spec.ts +1 -1
  301. package/src/settings/border.spec.ts +1 -1
  302. package/src/settings/borderRadiusExtended.spec.ts +4 -4
  303. package/src/settings/marginExtended.spec.ts +4 -4
  304. package/src/settings/paddingExtended.spec.ts +4 -4
  305. package/src/styles.css +3 -0
  306. package/src/utilities/react/getBorderStyles.ts +1 -1
  307. package/vite.config.ts +22 -2
@@ -0,0 +1,964 @@
1
+ /// <reference types="react" />
2
+
3
+ import { AnyObject } from '@udecode/plate';
4
+ import { AppBridgeBlock } from '@frontify/app-bridge';
5
+ import { Asset } from '@frontify/app-bridge';
6
+ import type { AssetInputBlock as AssetInputBlock_2 } from '@frontify/sidebar-settings';
7
+ import type { BaseBlock as BaseBlock_2 } from '@frontify/sidebar-settings';
8
+ import type { Bundle as Bundle_2 } from '@frontify/sidebar-settings';
9
+ import type { ChecklistBlock as ChecklistBlock_2 } from '@frontify/sidebar-settings';
10
+ import type { ChoicesType as ChoicesType_2 } from '@frontify/sidebar-settings';
11
+ import { Color } from '@frontify/fondue';
12
+ import { Color as Color_2 } from '@frontify/sidebar-settings';
13
+ import type { ColorInputBlock as ColorInputBlock_2 } from '@frontify/sidebar-settings';
14
+ import { ColorPalette } from '@frontify/app-bridge';
15
+ import { CSSProperties } from 'react';
16
+ import type { DropdownBlock as DropdownBlock_2 } from '@frontify/sidebar-settings';
17
+ import type { DynamicSettingBlock as DynamicSettingBlock_2 } from '@frontify/sidebar-settings';
18
+ import type { DynamicSupportedBlock as DynamicSupportedBlock_2 } from '@frontify/sidebar-settings';
19
+ import type { FC } from 'react';
20
+ import type { FileType } from '@frontify/app-bridge';
21
+ import type { FontInputBlock as FontInputBlock_2 } from '@frontify/sidebar-settings';
22
+ import type { InputBlock as InputBlock_2 } from '@frontify/sidebar-settings';
23
+ import { InsertNodesOptions } from '@udecode/plate';
24
+ import { JSX as JSX_2 } from 'react/jsx-runtime';
25
+ import { KeyboardCoordinateGetter } from '@dnd-kit/core';
26
+ import type { LegacyAssetInputBlock as LegacyAssetInputBlock_2 } from '@frontify/sidebar-settings';
27
+ import type { LinkChooserBlock as LinkChooserBlock_2 } from '@frontify/sidebar-settings';
28
+ import { MarkupElement } from '@frontify/fondue';
29
+ import { MenuItemStyle } from '@frontify/fondue';
30
+ import type { MultiInputBlock as MultiInputBlock_2 } from '@frontify/sidebar-settings';
31
+ import type { NotificationBlock as NotificationBlock_2 } from '@frontify/sidebar-settings';
32
+ import { Palette } from '@frontify/fondue';
33
+ import { PlateEditor } from '@udecode/plate';
34
+ import { PlatePlugin } from '@udecode/plate';
35
+ import { Plugin as Plugin_2 } from '@frontify/fondue';
36
+ import { PluginComposer } from '@frontify/fondue';
37
+ import { PluginProps } from '@frontify/fondue';
38
+ import { PropsWithChildren } from 'react';
39
+ import { RangeBeforeOptions } from '@udecode/plate';
40
+ import { ReactNode } from 'react';
41
+ import type { SectionHeadingBlock as SectionHeadingBlock_2 } from '@frontify/sidebar-settings';
42
+ import type { SegmentedControlsBlock as SegmentedControlsBlock_2 } from '@frontify/sidebar-settings';
43
+ import { SensorDescriptor } from '@dnd-kit/core';
44
+ import { SensorOptions } from '@dnd-kit/core';
45
+ import type { SettingBlock as SettingBlock_2 } from '@frontify/sidebar-settings';
46
+ import type { SimpleSettingBlock as SimpleSettingBlock_2 } from '@frontify/sidebar-settings';
47
+ import type { SwitchBlock as SwitchBlock_2 } from '@frontify/sidebar-settings';
48
+ import type { TemplateInputBlock as TemplateInputBlock_2 } from '@frontify/sidebar-settings';
49
+ import type { TextareaBlock as TextareaBlock_2 } from '@frontify/sidebar-settings';
50
+ import { TextStyleRenderElementProps } from '@frontify/fondue';
51
+ import { TLinkElement } from '@udecode/plate';
52
+ import { TText } from '@udecode/plate';
53
+ import { UnwrapNodesOptions } from '@udecode/plate';
54
+ import { Value } from '@udecode/plate';
55
+ import type { ValueOrPromisedValue as ValueOrPromisedValue_2 } from '@frontify/sidebar-settings';
56
+ import { WithOverride } from '@udecode/plate';
57
+ import { WrapNodesOptions } from '@udecode/plate';
58
+
59
+ export declare const addHttps: (url: string) => string;
60
+
61
+ export declare const AllTextStylePlugins: (Custom1Plugin | Custom2Plugin | Custom3Plugin | Heading1Plugin | Heading2Plugin | Heading3Plugin | Heading4Plugin | ImageCaptionPlugin | ImageTitlePlugin | ParagraphPlugin | QuotePlugin)[];
62
+
63
+ export declare const AllTextStyles: TextStyles[];
64
+
65
+ export declare type AssetInputBlock = AssetInputBlock_2<AppBridgeBlock>;
66
+
67
+ export declare type AttachmentItemProps = SortableAttachmentItemProps & {
68
+ isDragging?: boolean;
69
+ transformStyle?: Record<string, unknown>;
70
+ draggableProps?: Record<string, unknown>;
71
+ isOverlay?: boolean;
72
+ };
73
+
74
+ export declare const Attachments: ({ items, onDelete, onReplaceWithBrowse, onReplaceWithUpload, onBrowse, onUpload, onSorted, appBridge, }: AttachmentsProps) => JSX_2.Element | null;
75
+
76
+ export declare type AttachmentsProps = {
77
+ items?: Asset[];
78
+ appBridge: AppBridgeBlock;
79
+ onReplaceWithUpload: (attachmentToReplace: Asset, newAsset: Asset) => Promise<void>;
80
+ onReplaceWithBrowse: (attachmentToReplace: Asset, newAsset: Asset) => Promise<void>;
81
+ onDelete: (attachmentToDelete: Asset) => void;
82
+ onUpload: (uploadedAttachments: Asset[]) => Promise<void>;
83
+ onBrowse: (browserAttachments: Asset[]) => void;
84
+ onSorted: (sortedAttachments: Asset[]) => void;
85
+ };
86
+
87
+ /**
88
+ * Returns background settings: background switch, background color
89
+ *
90
+ * @param options Options for the settings
91
+ * @param options.id Custom suffix for the setting ids
92
+ * @param options.defaultValue Default value for the background switch
93
+ * @param options.defaultColor Default value for the background color
94
+ * @param options.preventDefaultColor Whether the background color should be empty by default
95
+ * @param options.switchLabel Label for the background switch
96
+ * @returns {SettingBlock} Returns background settings
97
+ */
98
+ declare type BackgroundSettingsType = {
99
+ id?: string;
100
+ defaultValue?: boolean;
101
+ defaultColor?: Color;
102
+ preventDefaultColor?: boolean;
103
+ switchLabel?: string;
104
+ };
105
+
106
+ export declare type BaseBlock<T = undefined> = BaseBlock_2<AppBridgeBlock, T>;
107
+
108
+ declare type BaseToolbarItem = {
109
+ icon: JSX.Element;
110
+ tooltip?: string;
111
+ };
112
+
113
+ export declare const BlockButtonStyles: Record<string, CSSProperties & {
114
+ hover?: CSSProperties;
115
+ }>;
116
+
117
+ export declare type BlockConfigExport = {
118
+ /**
119
+ * Block component to render.
120
+ * {@link https://developer.frontify.com/d/XFPCrGNrXQQM/content-blocks#/details-concepts-1/content-blocks}
121
+ */
122
+ block: FC<BlockProps>;
123
+ /**
124
+ * Contains the block settings and its structure.
125
+ * {@link https://developer.frontify.com/d/XFPCrGNrXQQM/content-blocks#/details-concepts-1/block-settings-1}
126
+ */
127
+ settings: ReturnType<typeof defineSettings>;
128
+ /**
129
+ * Block lifecycle hook ran before the block gets added in the Guideline.
130
+ * The hook support both synchronous or asynchronous execution.
131
+ * {@link https://developer.frontify.com/d/XFPCrGNrXQQM/content-blocks#/details-concepts-1/block-lifecycle/on-block-creation}
132
+ */
133
+ onBlockCreated?: (({ appBridge }: {
134
+ appBridge: AppBridgeBlock;
135
+ }) => void) | (({ appBridge }: {
136
+ appBridge: AppBridgeBlock;
137
+ }) => Promise<void>);
138
+ /**
139
+ * Block lifecycle hook ran before the block gets deleted from the Guideline.
140
+ * The hook support both synchronous or asynchronous execution.
141
+ * {@link https://developer.frontify.com/d/XFPCrGNrXQQM/content-blocks#/details-concepts-1/block-lifecycle/on-block-deletion}
142
+ */
143
+ onBlockDeleted?: (({ appBridge }: {
144
+ appBridge: AppBridgeBlock;
145
+ }) => void) | (({ appBridge }: {
146
+ appBridge: AppBridgeBlock;
147
+ }) => Promise<void>);
148
+ };
149
+
150
+ export declare const BlockInjectButton: ({ onDrop, label, icon, secondaryLabel, isLoading, fillParentContainer, onAssetChooseClick, onUploadClick, withMenu, onClick, validFileType, verticalLayout, }: BlockInjectButtonProps) => JSX_2.Element;
151
+
152
+ export declare type BlockInjectButtonProps = {
153
+ isLoading?: boolean;
154
+ label?: string;
155
+ validFileType?: keyof typeof FileType;
156
+ secondaryLabel?: string;
157
+ icon?: JSX.Element;
158
+ onDrop?: (files: FileList) => void;
159
+ fillParentContainer?: boolean;
160
+ onUploadClick?: () => void;
161
+ onAssetChooseClick?: () => void;
162
+ withMenu?: boolean;
163
+ onClick?: () => void;
164
+ verticalLayout?: boolean;
165
+ };
166
+
167
+ export declare const BlockItemWrapper: ({ children, toolbarFlyoutItems, toolbarItems, shouldHideWrapper, shouldHideComponent, isDragging, shouldFillContainer, outlineOffset, shouldBeShown, }: PropsWithChildren<BlockItemWrapperProps>) => string | number | boolean | JSX_2.Element | Iterable<ReactNode> | null | undefined;
168
+
169
+ export declare type BlockItemWrapperProps = {
170
+ shouldHideWrapper?: boolean;
171
+ shouldHideComponent?: boolean;
172
+ toolbarItems: (ToolbarItem | undefined)[];
173
+ toolbarFlyoutItems: FlyoutToolbarItem[][];
174
+ isDragging?: boolean;
175
+ shouldFillContainer?: boolean;
176
+ outlineOffset?: number;
177
+ shouldBeShown?: boolean;
178
+ };
179
+
180
+ export declare type BlockProps = {
181
+ /**
182
+ * The Frontify App Bridge provides an interface to the Frontify app internals.
183
+ * {@link https://developer.frontify.com/d/XFPCrGNrXQQM/content-blocks#/details-concepts-1/content-blocks/introducing-the-app-bridge}
184
+ */
185
+ appBridge: AppBridgeBlock;
186
+ };
187
+
188
+ export declare type BlockSettingsStructureExport = {
189
+ [Sections.Main]?: SettingBlock[];
190
+ [Sections.Basics]?: SettingBlock[];
191
+ [Sections.Layout]?: SettingBlock[];
192
+ [Sections.Style]?: SettingBlock[];
193
+ [Sections.Security]?: SettingBlock[];
194
+ } & {
195
+ [customSectionName: string]: SettingBlock[];
196
+ };
197
+
198
+ export declare const BlockStyles: Record<string, CSSProperties & {
199
+ hover?: CSSProperties;
200
+ }>;
201
+
202
+ /**
203
+ * Returns border radius settings: border radius switch, radius slider, custom radius input
204
+ *
205
+ * @param options Options for the settings
206
+ * @param options.id Custom suffix for the setting ids
207
+ * @param options.dependentSettingId Id of setting which the border radius is dependent on
208
+ * @returns {SettingBlock} Returns border settings
209
+ */
210
+ declare type BorderRadiusSettingsType = {
211
+ id?: string;
212
+ dependentSettingId?: string;
213
+ radiusStyleMap?: Record<Radius, string>;
214
+ defaultRadius?: Radius;
215
+ };
216
+
217
+ /**
218
+ * Returns border radius settings: border radius switch, radius slider, custom radius inputs for every corner
219
+ *
220
+ * @param options Options for the settings
221
+ * @param options.id Custom suffix for the setting ids
222
+ * @param options.dependentSettingId Id of setting which the border radius is dependent on
223
+ * @returns {SettingBlock} Returns border settings
224
+ */
225
+ declare type BorderRadiusSettingsType_2 = {
226
+ id?: string;
227
+ dependentSettingId?: string;
228
+ defaultValue?: Radius;
229
+ };
230
+
231
+ export declare type BorderSettings = {
232
+ hasBorder: boolean;
233
+ borderStyle: BorderStyle;
234
+ borderWidth: string;
235
+ borderColor: Color_2;
236
+ };
237
+
238
+ /**
239
+ * Returns border settings: border switch, border style, border width, border color
240
+ *
241
+ * @param options Options for the settings
242
+ * @param options.id Custom suffix for the setting ids
243
+ * @param options.switchLabel Label for the border switch
244
+ * @param options.defaultValue Default value for the border switch
245
+ * @returns {SettingBlock} Returns border settings
246
+ */
247
+ declare type BorderSettingsType = {
248
+ id?: string;
249
+ defaultValue?: boolean;
250
+ defaultColor?: Color_2;
251
+ switchLabel?: string;
252
+ };
253
+
254
+ export declare enum BorderStyle {
255
+ Solid = "Solid",
256
+ Dashed = "Dashed",
257
+ Dotted = "Dotted"
258
+ }
259
+
260
+ export declare const borderStyleMap: Record<BorderStyle, string>;
261
+
262
+ export declare type Bundle = Bundle_2<AppBridgeBlock>;
263
+
264
+ export declare const BUTTON_PLUGIN = "button-plugin";
265
+
266
+ export declare interface ButtonPlugin {
267
+ forceSubmit?: boolean;
268
+ /**
269
+ * Allow custom config for rangeBeforeOptions.
270
+ * @example default
271
+ * {
272
+ * matchString: ' ',
273
+ * skipInvalid: true,
274
+ * afterMatch: true,
275
+ * }
276
+ */
277
+ rangeBeforeOptions?: RangeBeforeOptions;
278
+ /**
279
+ * Hotkeys to trigger floating button.
280
+ * @default 'command+k, ctrl+k'
281
+ */
282
+ triggerFloatingButtonHotkeys: string;
283
+ /**
284
+ * Callback to validate an url.
285
+ * @default isUrl
286
+ */
287
+ isUrl: (text: string) => boolean;
288
+ /**
289
+ * Callback to optionally get the href for a url
290
+ * @returns href: an optional link to be used that is different from the text content (example https://google.com for google.com)
291
+ */
292
+ getUrlHref?: (url: string) => string | undefined;
293
+ /**
294
+ * On keyboard shortcut or toolbar mousedown, get the link url by calling this promise. The
295
+ * default behavior is to use the browser's native `prompt`.
296
+ */
297
+ getLinkUrl?: (prevUrl: string | null) => Promise<string | null>;
298
+ }
299
+
300
+ export declare class ButtonPlugin extends Plugin_2 {
301
+ styles: CSSProperties;
302
+ private appBridge;
303
+ constructor({ styles, ...props }: ButtonPluginProps);
304
+ plugins(): PlatePlugin<AnyObject, Value, PlateEditor<Value>>[];
305
+ }
306
+
307
+ export declare type ButtonPluginProps = Omit<PluginProps, 'styles'> & {
308
+ styles?: Record<string, CSSProperties & {
309
+ hover?: CSSProperties;
310
+ }>;
311
+ } & {
312
+ appBridge: AppBridgeBlock;
313
+ };
314
+
315
+ declare type ButtonToolbarItem = BaseToolbarItem & {
316
+ onClick: () => void;
317
+ };
318
+
319
+ export declare type ChecklistBlock = ChecklistBlock_2<AppBridgeBlock>;
320
+
321
+ export declare type ChoicesType = ChoicesType_2<AppBridgeBlock>;
322
+
323
+ export declare type ColorInputBlock = ColorInputBlock_2<AppBridgeBlock>;
324
+
325
+ export declare const convertToRteValue: (textStyle?: string, text?: string, align?: 'center' | 'right' | 'left' | 'justify') => string;
326
+
327
+ export declare const createButtonNode: <V extends Value>(editor: PlateEditor<V>, { url, text, buttonStyle, target, children }: CreateButtonNodeOptions) => TButtonElement;
328
+
329
+ export declare interface CreateButtonNodeOptions {
330
+ url: string;
331
+ text?: string;
332
+ buttonStyle?: RichTextButtonStyle;
333
+ target?: string;
334
+ children?: TText[];
335
+ }
336
+
337
+ /**
338
+ * Enables support for hyperlinks.
339
+ */
340
+ export declare const createButtonPlugin: (appBridge: AppBridgeBlock) => PlatePlugin<AnyObject, Value, PlateEditor<Value>>;
341
+
342
+ export declare const createLinkPlugin: (appBridge: AppBridgeBlock) => PlatePlugin<AnyObject, Value, PlateEditor<Value>>;
343
+
344
+ export declare const createParagraphPlugin: (styles: CSSProperties) => PlatePlugin<AnyObject, Value, PlateEditor<Value>>;
345
+
346
+ export declare const createQuotePlugin: (styles: CSSProperties) => PlatePlugin<AnyObject, Value, PlateEditor<Value>>;
347
+
348
+ export declare class Custom1Plugin extends Plugin_2 {
349
+ styles: CSSProperties;
350
+ constructor({ styles, ...props }?: PluginProps);
351
+ plugins(): PlatePlugin<AnyObject, Value, PlateEditor<Value>>[];
352
+ }
353
+
354
+ export declare class Custom2Plugin extends Plugin_2 {
355
+ styles: CSSProperties;
356
+ constructor({ styles, ...props }?: PluginProps);
357
+ plugins(): PlatePlugin<AnyObject, Value, PlateEditor<Value>>[];
358
+ }
359
+
360
+ export declare class Custom3Plugin extends Plugin_2 {
361
+ styles: CSSProperties;
362
+ constructor({ styles, ...props }?: PluginProps);
363
+ plugins(): PlatePlugin<AnyObject, Value, PlateEditor<Value>>[];
364
+ }
365
+
366
+ export declare const customCoordinatesGetterFactory: (columnGap: number, rowGap: number) => KeyboardCoordinateGetter;
367
+
368
+ export declare const DEFAULT_DRAG_TOOLTIP = "Drag or press \u21B5 to move";
369
+
370
+ export declare const DEFAULT_DRAGGING_TOOLTIP = "Move with \u2191\u2193\u2190\u2192 and confirm with \u21B5";
371
+
372
+ /**
373
+ * Type helper to make it easier to export a theme, accepts a direct {@link BlockConfigExport} object.
374
+ */
375
+ export declare const defineBlock: (config: BlockConfigExport) => BlockConfigExport;
376
+
377
+ /**
378
+ * Type helper to make it easier to export block's settings structure, accepts a direct {@link BlockSettingsStructureExport} object
379
+ * or a function return a direct {@link BlockSettingsStructureExport} or a function returning a Promise of {@link BlockSettingsStructureExport}.
380
+ */
381
+ export declare const defineSettings: <T extends BlockSettingsStructureExport | (() => Promise<BlockSettingsStructureExport>) | (() => BlockSettingsStructureExport)>(settingsStructure: T) => T;
382
+
383
+ export declare const DownloadButton: ({ onDownload }: DownloadButtonProps) => JSX_2.Element;
384
+
385
+ declare type DownloadButtonProps = {
386
+ onDownload: () => void;
387
+ };
388
+
389
+ declare type DraghandleToolbarItem = BaseToolbarItem & {
390
+ draggableProps: Record<string, unknown>;
391
+ setActivatorNodeRef?: (node: HTMLElement | null) => void;
392
+ };
393
+
394
+ export declare type DropdownBlock = DropdownBlock_2<AppBridgeBlock>;
395
+
396
+ export declare type DynamicSettingBlock<Block extends DynamicSupportedBlock = DynamicSupportedBlock> = DynamicSettingBlock_2<AppBridgeBlock, Block>;
397
+
398
+ export declare type DynamicSupportedBlock = DynamicSupportedBlock_2<AppBridgeBlock>;
399
+
400
+ export declare const ELEMENT_BUTTON = "button";
401
+
402
+ declare type FlyoutToolbarItem = {
403
+ title: string;
404
+ onClick: () => void;
405
+ icon: JSX.Element;
406
+ style?: MenuItemStyle;
407
+ };
408
+
409
+ export declare type FontInputBlock = FontInputBlock_2<AppBridgeBlock>;
410
+
411
+ export declare const getBackgroundColorStyles: (backgroundColor: Color) => CSSProperties;
412
+
413
+ export declare const getBackgroundSettings: (options?: BackgroundSettingsType) => SettingBlock;
414
+
415
+ export declare const getBorderRadiusSettings: (options?: BorderRadiusSettingsType) => SettingBlock;
416
+
417
+ export declare const getBorderRadiusSlider: (id: string, defaultValue?: Radius) => SettingBlock;
418
+
419
+ export declare const getBorderSettings: (options?: BorderSettingsType) => SettingBlock;
420
+
421
+ export declare const getBorderStyles: (style?: BorderStyle, borderWidth?: string, color?: Color) => CSSProperties;
422
+
423
+ export declare const getDefaultPluginsWithLinkChooser: (appBridge: AppBridgeBlock) => PluginComposer;
424
+
425
+ export declare const getExtendedBorderRadiusSettings: (options?: BorderRadiusSettingsType_2) => SettingBlock;
426
+
427
+ export declare const getGutterSettings: (options?: GutterSettingsType) => SettingBlock;
428
+
429
+ /**
430
+ * Returns margin settings: margin switch, margin slider, custom margin input for every direction
431
+ *
432
+ * @param options Options for the settings
433
+ * @param options.id Custom suffix for the setting ids
434
+ * @returns {SettingBlock} Returns margin settings
435
+ */
436
+ export declare const getMarginExtendedSettings: (options?: MarginSettingsType_2) => SettingBlock;
437
+
438
+ export declare const getMarginSettings: (options?: MarginSettingsType) => SettingBlock;
439
+
440
+ /**
441
+ * Returns margin settings: margin switch, margin slider, custom margin input
442
+ *
443
+ * @param {string} id Custom suffix for the setting ids
444
+ * @returns {SettingBlock} Returns margin settings
445
+ */
446
+ export declare const getMarginSlider: (id: string) => SettingBlock;
447
+
448
+ /**
449
+ * Returns padding settings: padding switch, padding slider, custom padding input for every direction
450
+ *
451
+ * @param options Options for the settings
452
+ * @param options.id Custom suffix for the setting ids
453
+ * @returns {SettingBlock} Returns padding settings
454
+ */
455
+ export declare const getPaddingExtendedSettings: (options?: PaddingSettingsType_2) => SettingBlock;
456
+
457
+ export declare const getPaddingSettings: (options?: PaddingSettingsType) => SettingBlock;
458
+
459
+ /**
460
+ * Returns padding settings: padding switch, padding slider, custom padding input
461
+ *
462
+ * @param options Options for the settings
463
+ * @param options.id Custom suffix for the setting ids
464
+ * @returns {SettingBlock} Returns padding settings
465
+ */
466
+ export declare const getPaddingSlider: (id: string) => SettingBlock;
467
+
468
+ export declare const getRadiusStyles: (radiusChoice: Radius, hasRadius?: boolean, radiusValue?: number) => CSSProperties;
469
+
470
+ export declare const getReadableColor: (textColor: unknown, backgroundColor: unknown) => string;
471
+
472
+ export declare const getSecurityDownloadableSetting: (options?: SecurityDownloadableSettingType) => SettingBlock;
473
+
474
+ export declare const getSecurityGlobalControlId: (id?: string) => string;
475
+
476
+ /**
477
+ * Returns segment controls for global security settings.
478
+ *
479
+ * @param {string} id custom id for the setting block
480
+ *
481
+ * @returns {SettingBlock} Returns
482
+ */
483
+ export declare const getSecurityGlobalControlSetting: (id?: string) => SettingBlock[];
484
+
485
+ export declare const getUrlFromEditor: (editor: PlateEditor) => string;
486
+
487
+ /**
488
+ * Returns gutter settings: gutter switch, gutter choices or gutter custom input
489
+ *
490
+ * @param options Options for the settings
491
+ * @param options.id Custom id for the gutters switch
492
+ * @param options.dependentSettingId Id of the dependent setting
493
+ * @param options.spacingChoiceId Id of the spacing choice
494
+ * @param options.defaultValueChoices Default value for the spacing choice
495
+ * @returns {SettingBlock} Returns the gutter settings
496
+ */
497
+ declare type GutterSettingsType = {
498
+ id?: string;
499
+ dependentSettingId?: string;
500
+ spacingChoiceId?: string;
501
+ spacingCustomId?: string;
502
+ defaultValueChoices?: GutterSpacing;
503
+ };
504
+
505
+ export declare enum GutterSpacing {
506
+ Auto = "Auto",
507
+ S = "S",
508
+ M = "M",
509
+ L = "L"
510
+ }
511
+
512
+ export declare const gutterSpacingStyleMap: Record<GutterSpacing, string>;
513
+
514
+ export declare const hasRichTextValue: (string?: string) => boolean;
515
+
516
+ export declare class Heading1Plugin extends Plugin_2 {
517
+ styles: CSSProperties;
518
+ constructor({ styles, ...props }?: PluginProps);
519
+ plugins(): PlatePlugin<AnyObject, Value, PlateEditor<Value>>[];
520
+ }
521
+
522
+ export declare class Heading2Plugin extends Plugin_2 {
523
+ styles: CSSProperties;
524
+ constructor({ styles, ...props }?: PluginProps);
525
+ plugins(): PlatePlugin<AnyObject, Value, PlateEditor<Value>>[];
526
+ }
527
+
528
+ export declare class Heading3Plugin extends Plugin_2 {
529
+ styles: CSSProperties;
530
+ constructor({ styles, ...props }?: PluginProps);
531
+ plugins(): PlatePlugin<AnyObject, Value, PlateEditor<Value>>[];
532
+ }
533
+
534
+ export declare class Heading4Plugin extends Plugin_2 {
535
+ styles: CSSProperties;
536
+ constructor({ styles, ...props }?: PluginProps);
537
+ plugins(): PlatePlugin<AnyObject, Value, PlateEditor<Value>>[];
538
+ }
539
+
540
+ export declare class ImageCaptionPlugin extends Plugin_2 {
541
+ styles: CSSProperties;
542
+ constructor({ styles, ...props }?: PluginProps);
543
+ plugins(): PlatePlugin<AnyObject, Value, PlateEditor<Value>>[];
544
+ }
545
+
546
+ export declare class ImageTitlePlugin extends Plugin_2 {
547
+ styles: CSSProperties;
548
+ constructor({ styles, ...props }?: PluginProps);
549
+ plugins(): PlatePlugin<AnyObject, Value, PlateEditor<Value>>[];
550
+ }
551
+
552
+ export declare type InputBlock = InputBlock_2<AppBridgeBlock>;
553
+
554
+ export declare const insertButton: <V extends Value>(editor: PlateEditor<V>, createButtonNodeOptions: CreateButtonNodeOptions, options?: InsertNodesOptions<V> | undefined) => void;
555
+
556
+ export declare const isDark: (color: unknown, threshold?: number) => boolean;
557
+
558
+ export declare const isDownloadable: (security: Security, downloadable: boolean, globalAssetDownloadEnabled: boolean) => boolean;
559
+
560
+ /**
561
+ * Cleans and joins an array of inputs with possible undefined or boolean values.
562
+ *
563
+ * @param {Array} classNames Array of class names
564
+ * @returns Clean string to be used for class name.
565
+ */
566
+ export declare const joinClassNames: (classNames: (string | undefined | boolean)[]) => string;
567
+
568
+ export declare type LegacyAssetInputBlock = LegacyAssetInputBlock_2<AppBridgeBlock>;
569
+
570
+ export declare type LinkChooserBlock = LinkChooserBlock_2<AppBridgeBlock>;
571
+
572
+ export declare class LinkPlugin extends Plugin_2 {
573
+ private appBridge;
574
+ styles: CSSProperties;
575
+ constructor(props?: LinkPluginProps, styles?: CSSProperties & {
576
+ hover?: CSSProperties | undefined;
577
+ });
578
+ plugins(): PlatePlugin<AnyObject, Value, PlateEditor<Value>>[];
579
+ }
580
+
581
+ export declare type LinkPluginProps = PluginProps & {
582
+ appBridge: AppBridgeBlock;
583
+ };
584
+
585
+ export declare const mapAppBridgeColorPalettesToFonduePalettes: (colorPalettes: ColorPalette[]) => Palette[];
586
+
587
+ export declare const mapAppBridgeColorPaletteToFonduePalette: (colorPalette: ColorPalette) => Palette;
588
+
589
+ export declare enum Margin {
590
+ None = "None",
591
+ Small = "Small",
592
+ Medium = "Medium",
593
+ Large = "Large"
594
+ }
595
+
596
+ export declare type MarginExtendedSettings = {
597
+ hasExtendedCustomMargin: boolean;
598
+ extendedMarginChoice: Margin;
599
+ extendedMarginTop: string;
600
+ extendedMarginRight: string;
601
+ extendedMarginBottom: string;
602
+ extendedMarginLeft: string;
603
+ };
604
+
605
+ export declare type MarginSettings = {
606
+ marginChoice: Margin;
607
+ hasCustomMarginValue: boolean;
608
+ marginValue: string;
609
+ };
610
+
611
+ declare type MarginSettingsType = {
612
+ id?: string;
613
+ marginStyleMap?: Record<Margin, string>;
614
+ };
615
+
616
+ declare type MarginSettingsType_2 = {
617
+ id?: string;
618
+ };
619
+
620
+ export declare const marginStyleMap: Record<Margin, string>;
621
+
622
+ /**
623
+ * Moves an item from the 'from' position to the 'to' position and updates the array
624
+ *
625
+ * @param {Array} array Array of items
626
+ * @param {Number} from Initial index of the item
627
+ * @param {Number} to New index of the item
628
+ * @returns {Array} New array with the item moved to the new position
629
+ */
630
+ export declare const moveItemInArray: <T>(array: T[], from: number, to: number) => T[];
631
+
632
+ export declare type MultiInputBlock = MultiInputBlock_2<AppBridgeBlock>;
633
+
634
+ export declare type NotificationBlock = NotificationBlock_2<AppBridgeBlock>;
635
+
636
+ export declare enum Padding {
637
+ None = "None",
638
+ Small = "Small",
639
+ Medium = "Medium",
640
+ Large = "Large"
641
+ }
642
+
643
+ export declare type PaddingExtendedSettings = {
644
+ hasExtendedCustomPadding: boolean;
645
+ extendedPaddingChoice: Padding;
646
+ extendedPaddingTop: string;
647
+ extendedPaddingRight: string;
648
+ extendedPaddingBottom: string;
649
+ extendedPaddingLeft: string;
650
+ };
651
+
652
+ export declare type PaddingSettings = {
653
+ paddingChoice: Padding;
654
+ hasCustomPaddingValue: boolean;
655
+ paddingValue: string;
656
+ };
657
+
658
+ declare type PaddingSettingsType = {
659
+ id?: string;
660
+ paddingStyleMap?: Record<Padding, string>;
661
+ };
662
+
663
+ declare type PaddingSettingsType_2 = {
664
+ id?: string;
665
+ };
666
+
667
+ export declare const paddingStyleMap: Record<Padding, string>;
668
+
669
+ export declare const PARAGRAPH_CLASSES = "tw-m-0 tw-px-0 tw-py-0";
670
+
671
+ export declare class ParagraphMarkupElement extends MarkupElement {
672
+ constructor(id?: TextStyles, node?: ({ element, attributes, children, styles }: TextStyleRenderElementProps) => JSX_2.Element);
673
+ }
674
+
675
+ export declare const ParagraphMarkupElementNode: ({ element, attributes, children, styles }: TextStyleRenderElementProps) => JSX_2.Element;
676
+
677
+ export declare class ParagraphPlugin extends Plugin_2 {
678
+ styles: CSSProperties;
679
+ constructor({ styles, ...props }?: PluginProps);
680
+ plugins(): PlatePlugin<AnyObject, Value, PlateEditor<Value>>[];
681
+ }
682
+
683
+ export declare const QuoteMarkupElementNode: ({ element, attributes, children, styles }: TextStyleRenderElementProps) => JSX_2.Element;
684
+
685
+ export declare class QuotePlugin extends Plugin_2 {
686
+ styles: CSSProperties;
687
+ constructor({ styles, ...props }?: PluginProps);
688
+ plugins(): PlatePlugin<AnyObject, Value, PlateEditor<Value>>[];
689
+ }
690
+
691
+ export declare enum Radius {
692
+ None = "None",
693
+ Small = "Small",
694
+ Medium = "Medium",
695
+ Large = "Large"
696
+ }
697
+
698
+ export declare type RadiusExtendedSettings = {
699
+ hasExtendedCustomRadius: boolean;
700
+ extendedRadiusChoice: Radius;
701
+ extendedRadiusTopLeft: string;
702
+ extendedRadiusTopRight: string;
703
+ extendedRadiusBottomLeft: string;
704
+ extendedRadiusBottomRight: string;
705
+ };
706
+
707
+ export declare type RadiusSettings = {
708
+ hasRadius: boolean;
709
+ radiusValue: string;
710
+ radiusChoice: Radius;
711
+ };
712
+
713
+ export declare const radiusStyleMap: Record<Radius, string>;
714
+
715
+ export declare type RichTextButtonStyle = 'primary' | 'secondary' | 'tertiary';
716
+
717
+ export declare const RichTextEditor: ({ id, isEditing, value, columns, gap, placeholder, plugins, onTextChange, showSerializedText, }: RichTextEditorProps) => JSX_2.Element;
718
+
719
+ declare type RichTextEditorProps = {
720
+ id?: string;
721
+ isEditing: boolean;
722
+ value?: string;
723
+ placeholder?: string;
724
+ columns?: number;
725
+ gap?: string;
726
+ plugins?: PluginComposer;
727
+ showSerializedText?: boolean;
728
+ onTextChange?: (value: string) => void;
729
+ };
730
+
731
+ export declare type SectionHeadingBlock = SectionHeadingBlock_2<AppBridgeBlock>;
732
+
733
+ export declare enum Sections {
734
+ Main = "main",
735
+ Basics = "basics",
736
+ Layout = "layout",
737
+ Style = "style",
738
+ Security = "security",
739
+ Targets = "targets"
740
+ }
741
+
742
+ export declare enum Security {
743
+ Global = "Global",
744
+ Custom = "Custom"
745
+ }
746
+
747
+ /**
748
+ * Returns the downloadable security settings.
749
+ *
750
+ * @param {string} id custom id for the setting block
751
+ * @param {string} globalControlId custom id for the global control setting block
752
+ *
753
+ * @returns {SettingBlock} Returns downloadable security settings.
754
+ */
755
+ declare type SecurityDownloadableSettingType = {
756
+ id?: string;
757
+ globalControlId?: string;
758
+ };
759
+
760
+ export declare type SegmentedControlsBlock = SegmentedControlsBlock_2<AppBridgeBlock>;
761
+
762
+ /**
763
+ * Sets alpha value and returns rgba string.
764
+ *
765
+ * @param {string} color Rgb or hex string.
766
+ * @returns {String} To be used as css value.
767
+ */
768
+ export declare const setAlpha: (alpha: number, color?: string) => string;
769
+
770
+ export declare type SettingBlock = SettingBlock_2<AppBridgeBlock>;
771
+
772
+ declare type ShortNotationColor = {
773
+ r: number;
774
+ g: number;
775
+ b: number;
776
+ a?: number;
777
+ };
778
+
779
+ export declare type SimpleSettingBlock = SimpleSettingBlock_2<AppBridgeBlock>;
780
+
781
+ export declare type SortableAttachmentItemProps = {
782
+ item: Asset;
783
+ isEditing: boolean;
784
+ onDelete: () => void;
785
+ isLoading?: boolean;
786
+ onReplaceWithBrowse: () => void;
787
+ onReplaceWithUpload: (uploadedAsset: Asset) => void;
788
+ };
789
+
790
+ export declare const submitFloatingButton: <V extends Value>(editor: PlateEditor<V>) => true | undefined;
791
+
792
+ export declare type SwitchBlock = SwitchBlock_2<AppBridgeBlock>;
793
+
794
+ export declare type TButtonElement = TLinkElement & {
795
+ chosenLink?: {
796
+ searchResult?: {
797
+ link?: string;
798
+ };
799
+ };
800
+ };
801
+
802
+ export declare type TemplateInputBlock = TemplateInputBlock_2<AppBridgeBlock>;
803
+
804
+ export declare type TextareaBlock = TextareaBlock_2<AppBridgeBlock>;
805
+
806
+ export declare const TextStylePluginsWithoutImage: (Custom1Plugin | Custom2Plugin | Custom3Plugin | Heading1Plugin | Heading2Plugin | Heading3Plugin | Heading4Plugin | ParagraphPlugin | QuotePlugin)[];
807
+
808
+ export declare const enum TextStyles {
809
+ heading1 = "heading1",
810
+ heading2 = "heading2",
811
+ heading3 = "heading3",
812
+ heading4 = "heading4",
813
+ custom1 = "custom1",
814
+ custom2 = "custom2",
815
+ custom3 = "custom3",
816
+ quote = "quote",
817
+ imageCaption = "imageCaption",
818
+ imageTitle = "imageTitle",
819
+ p = "p"
820
+ }
821
+
822
+ export declare const TextStylesWithoutImage: TextStyles[];
823
+
824
+ export declare const THEME_PREFIX = "--f-theme-settings-";
825
+
826
+ /**
827
+ * Maps color strings to color objects.
828
+ *
829
+ * @param {String} String representing color
830
+ * @returns {Color} Color object
831
+ */
832
+ export declare const toColorObject: (colorString: string) => Color;
833
+
834
+ /**
835
+ * Maps color object of rgba values to hex alpha string.
836
+ *
837
+ * @param {Object} Color object
838
+ * @returns {String} To be used as css value.
839
+ */
840
+ export declare const toHex8String: (color: Color) => string;
841
+
842
+ /**
843
+ * Maps color object of rgba values to hex alpha string.
844
+ */
845
+ export declare const toHexString: (color: Color) => string;
846
+
847
+ export declare type ToolbarItem = DraghandleToolbarItem | ButtonToolbarItem;
848
+
849
+ export declare type ToolbarProps = {
850
+ items: ToolbarItem[];
851
+ flyoutItems: FlyoutToolbarItem[][];
852
+ isFlyoutOpen: boolean;
853
+ setIsFlyoutOpen: (isOpen: boolean) => void;
854
+ isDragging?: boolean;
855
+ isFlyoutDisabled?: boolean;
856
+ };
857
+
858
+ /**
859
+ * Maps color object of rgba values to rgba string.
860
+ *
861
+ * @param {Object} Color object
862
+ * @returns {String} To be used as css value.
863
+ */
864
+ export declare const toRgbaString: (color: Color) => string;
865
+
866
+ /**
867
+ * Maps color object from long to short rgba notation.
868
+ *
869
+ * @param {Object} Color object
870
+ * @returns {Object} ShortNotationColor object
871
+ */
872
+ export declare const toShortRgba: (color: unknown) => ShortNotationColor;
873
+
874
+ export declare const triggerFloatingButton: <V extends Value>(editor: PlateEditor<V>, { focused, }?: {
875
+ focused?: boolean | undefined;
876
+ }) => void;
877
+
878
+ export declare const triggerFloatingButtonEdit: <V extends Value>(editor: PlateEditor<V>) => void;
879
+
880
+ /**
881
+ * Trigger floating button.
882
+ *
883
+ * Do not trigger when:
884
+ * - selection is across blocks
885
+ * - selection has more than one leaf node
886
+ * - lowest selection is not text
887
+ * - selection has a button node
888
+ */
889
+ export declare const triggerFloatingButtonInsert: <V extends Value>(editor: PlateEditor<V>, { focused, }?: {
890
+ focused?: boolean | undefined;
891
+ }) => void;
892
+
893
+ /**
894
+ * Unwrap button node.
895
+ */
896
+ export declare const unwrapButton: <V extends Value>(editor: PlateEditor<V>, options?: UnwrapNodesOptions & {
897
+ split?: boolean;
898
+ }) => boolean;
899
+
900
+ /**
901
+ * If selection in a button or is not url:
902
+ * - insert text with url, exit
903
+ * If selection is expanded or `update` in a button:
904
+ * - remove button node, get button text
905
+ * Then:
906
+ * - insert button node
907
+ */
908
+ export declare const upsertButton: <V extends Value>(editor: PlateEditor<V>, { url, text, buttonStyle, target, insertTextInButton, insertNodesOptions, isUrl, }: UpsertButtonOptions<V>) => true | undefined;
909
+
910
+ export declare type UpsertButtonOptions<V extends Value = Value> = CreateButtonNodeOptions & {
911
+ /**
912
+ * If true, insert text when selection is in url.
913
+ */
914
+ insertTextInButton?: boolean;
915
+ insertNodesOptions?: InsertNodesOptions<V>;
916
+ unwrapNodesOptions?: UnwrapNodesOptions<V>;
917
+ wrapNodesOptions?: WrapNodesOptions<V>;
918
+ isUrl?: (url: string) => boolean;
919
+ };
920
+
921
+ /**
922
+ * If the text is different than the button above text, replace button children by a new text.
923
+ * The new text has the same marks than the first text replaced.
924
+ */
925
+ export declare const upsertButtonText: <V extends Value>(editor: PlateEditor<V>, { text }: UpsertButtonOptions<V>) => void;
926
+
927
+ export declare const useAttachments: (appBridge: AppBridgeBlock, assetId: string) => {
928
+ onAddAttachments: (newAssets: Asset[]) => Promise<void>;
929
+ onAttachmentDelete: (assetToDelete: Asset) => Promise<void>;
930
+ onAttachmentReplace: (attachmentToReplace: Asset, newAsset: Asset) => Promise<void>;
931
+ onAttachmentsSorted: (assets: Asset[]) => Promise<void>;
932
+ attachments: Asset[];
933
+ };
934
+
935
+ export declare const useDndSensors: (columnGap?: number, rowGap?: number) => SensorDescriptor<SensorOptions>[];
936
+
937
+ export declare type ValueOrPromisedValue<T> = ValueOrPromisedValue_2<AppBridgeBlock, T>;
938
+
939
+ /**
940
+ * Insert space after a url to wrap a button.
941
+ * Lookup from the block start to the cursor to check if there is an url.
942
+ * If not found, lookup before the cursor for a space character to check the url.
943
+ *
944
+ * On insert data:
945
+ * Paste a string inside a button element will edit its children text but not its url.
946
+ *
947
+ */
948
+ export declare const withButton: WithOverride;
949
+
950
+ /**
951
+ * Wrap a button node with split.
952
+ */
953
+ export declare const wrapButton: <V extends Value>(editor: PlateEditor<V>, { url, buttonStyle, target, ...options }: WrapButtonOptions<V>) => void;
954
+
955
+ export declare interface WrapButtonOptions<V extends Value = Value> extends WrapNodesOptions<V> {
956
+ url: string;
957
+ buttonStyle?: RichTextButtonStyle;
958
+ target?: string;
959
+ }
960
+
961
+
962
+ export * from "@frontify/sidebar-settings";
963
+
964
+ export { }