@payloadcms/richtext-lexical 3.0.0-beta.4 → 3.0.0-beta.41

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 (840) hide show
  1. package/dist/cell/index.d.ts +5 -2
  2. package/dist/cell/index.d.ts.map +1 -1
  3. package/dist/cell/index.js +44 -29
  4. package/dist/cell/index.js.map +1 -1
  5. package/dist/exports/components.d.ts +7 -2
  6. package/dist/exports/components.d.ts.map +1 -1
  7. package/dist/exports/components.js +7 -2
  8. package/dist/exports/components.js.map +1 -1
  9. package/dist/field/Field.d.ts +0 -2
  10. package/dist/field/Field.d.ts.map +1 -1
  11. package/dist/field/Field.js +66 -47
  12. package/dist/field/Field.js.map +1 -1
  13. package/dist/field/features/align/feature.client.d.ts +4 -1
  14. package/dist/field/features/align/feature.client.d.ts.map +1 -1
  15. package/dist/field/features/align/feature.client.js +135 -54
  16. package/dist/field/features/align/feature.client.js.map +1 -1
  17. package/dist/field/features/align/feature.server.d.ts.map +1 -1
  18. package/dist/field/features/align/feature.server.js +2 -0
  19. package/dist/field/features/align/feature.server.js.map +1 -1
  20. package/dist/field/features/align/i18n.d.ts +3 -0
  21. package/dist/field/features/align/i18n.d.ts.map +1 -0
  22. package/dist/field/features/align/i18n.js +196 -0
  23. package/dist/field/features/align/i18n.js.map +1 -0
  24. package/dist/field/features/align/toolbarAlignGroup.d.ts +3 -0
  25. package/dist/field/features/align/toolbarAlignGroup.d.ts.map +1 -0
  26. package/dist/field/features/align/toolbarAlignGroup.js +12 -0
  27. package/dist/field/features/align/toolbarAlignGroup.js.map +1 -0
  28. package/dist/field/features/blockquote/feature.client.d.ts +4 -1
  29. package/dist/field/features/blockquote/feature.client.d.ts.map +1 -1
  30. package/dist/field/features/blockquote/feature.client.js +60 -46
  31. package/dist/field/features/blockquote/feature.client.js.map +1 -1
  32. package/dist/field/features/blockquote/feature.server.d.ts +1 -1
  33. package/dist/field/features/blockquote/feature.server.d.ts.map +1 -1
  34. package/dist/field/features/blockquote/feature.server.js +9 -7
  35. package/dist/field/features/blockquote/feature.server.js.map +1 -1
  36. package/dist/field/features/blockquote/i18n.d.ts +3 -0
  37. package/dist/field/features/blockquote/i18n.d.ts.map +1 -0
  38. package/dist/field/features/blockquote/i18n.js +100 -0
  39. package/dist/field/features/blockquote/i18n.js.map +1 -0
  40. package/dist/field/features/blockquote/markdownTransformer.d.ts.map +1 -1
  41. package/dist/field/features/blockquote/markdownTransformer.js +2 -4
  42. package/dist/field/features/blockquote/markdownTransformer.js.map +1 -1
  43. package/dist/field/features/blocks/component/BlockContent.d.ts.map +1 -1
  44. package/dist/field/features/blocks/component/BlockContent.js +65 -50
  45. package/dist/field/features/blocks/component/BlockContent.js.map +1 -1
  46. package/dist/field/features/blocks/component/index.d.ts.map +1 -1
  47. package/dist/field/features/blocks/component/index.js +60 -17
  48. package/dist/field/features/blocks/component/index.js.map +1 -1
  49. package/dist/field/features/blocks/component/index.scss +0 -4
  50. package/dist/field/features/blocks/drawer/index.d.ts.map +1 -1
  51. package/dist/field/features/blocks/drawer/index.js +4 -5
  52. package/dist/field/features/blocks/drawer/index.js.map +1 -1
  53. package/dist/field/features/blocks/feature.client.d.ts +4 -1
  54. package/dist/field/features/blocks/feature.client.d.ts.map +1 -1
  55. package/dist/field/features/blocks/feature.client.js +58 -27
  56. package/dist/field/features/blocks/feature.client.js.map +1 -1
  57. package/dist/field/features/blocks/feature.server.d.ts +2 -5
  58. package/dist/field/features/blocks/feature.server.d.ts.map +1 -1
  59. package/dist/field/features/blocks/feature.server.js +111 -77
  60. package/dist/field/features/blocks/feature.server.js.map +1 -1
  61. package/dist/field/features/blocks/i18n.d.ts +3 -0
  62. package/dist/field/features/blocks/i18n.d.ts.map +1 -0
  63. package/dist/field/features/blocks/i18n.js +100 -0
  64. package/dist/field/features/blocks/i18n.js.map +1 -0
  65. package/dist/field/features/blocks/nodes/BlocksNode.d.ts +2 -4
  66. package/dist/field/features/blocks/nodes/BlocksNode.d.ts.map +1 -1
  67. package/dist/field/features/blocks/nodes/BlocksNode.js +3 -3
  68. package/dist/field/features/blocks/nodes/BlocksNode.js.map +1 -1
  69. package/dist/field/features/blocks/plugin/commands.d.ts.map +1 -1
  70. package/dist/field/features/blocks/plugin/commands.js +1 -2
  71. package/dist/field/features/blocks/plugin/commands.js.map +1 -1
  72. package/dist/field/features/blocks/plugin/index.d.ts +3 -2
  73. package/dist/field/features/blocks/plugin/index.d.ts.map +1 -1
  74. package/dist/field/features/blocks/plugin/index.js +10 -11
  75. package/dist/field/features/blocks/plugin/index.js.map +1 -1
  76. package/dist/field/features/blocks/populationPromise.d.ts.map +1 -1
  77. package/dist/field/features/blocks/populationPromise.js +5 -19
  78. package/dist/field/features/blocks/populationPromise.js.map +1 -1
  79. package/dist/field/features/blocks/validate.d.ts.map +1 -1
  80. package/dist/field/features/blocks/validate.js +22 -36
  81. package/dist/field/features/blocks/validate.js.map +1 -1
  82. package/dist/field/features/converters/html/field/index.d.ts +8 -2
  83. package/dist/field/features/converters/html/field/index.d.ts.map +1 -1
  84. package/dist/field/features/converters/html/field/index.js +36 -5
  85. package/dist/field/features/converters/html/field/index.js.map +1 -1
  86. package/dist/field/features/createFeaturePropComponent.d.ts.map +1 -1
  87. package/dist/field/features/createFeaturePropComponent.js +6 -1
  88. package/dist/field/features/createFeaturePropComponent.js.map +1 -1
  89. package/dist/field/features/debug/{testrecorder → testRecorder}/feature.client.d.ts +4 -1
  90. package/dist/field/features/debug/testRecorder/feature.client.d.ts.map +1 -0
  91. package/dist/field/features/debug/{testrecorder → testRecorder}/feature.client.js.map +1 -1
  92. package/dist/field/features/debug/{testrecorder → testRecorder}/feature.server.d.ts.map +1 -1
  93. package/dist/field/features/debug/{testrecorder → testRecorder}/feature.server.js +1 -1
  94. package/dist/field/features/debug/{testrecorder → testRecorder}/feature.server.js.map +1 -1
  95. package/dist/field/features/debug/testRecorder/plugin/index.d.ts +5 -0
  96. package/dist/field/features/debug/testRecorder/plugin/index.d.ts.map +1 -0
  97. package/dist/field/features/debug/{testrecorder → testRecorder}/plugin/index.js +68 -44
  98. package/dist/field/features/debug/testRecorder/plugin/index.js.map +1 -0
  99. package/dist/field/features/debug/{treeview → treeView}/feature.client.d.ts +4 -1
  100. package/dist/field/features/debug/treeView/feature.client.d.ts.map +1 -0
  101. package/dist/field/features/debug/{treeview → treeView}/feature.client.js.map +1 -1
  102. package/dist/field/features/debug/{treeview → treeView}/feature.server.d.ts.map +1 -1
  103. package/dist/field/features/debug/{treeview → treeView}/feature.server.js +1 -1
  104. package/dist/field/features/debug/{treeview → treeView}/feature.server.js.map +1 -1
  105. package/dist/field/features/debug/treeView/plugin/index.d.ts +4 -0
  106. package/dist/field/features/debug/treeView/plugin/index.d.ts.map +1 -0
  107. package/dist/field/features/debug/{treeview → treeView}/plugin/index.js +6 -7
  108. package/dist/field/features/debug/treeView/plugin/index.js.map +1 -0
  109. package/dist/field/features/format/bold/feature.client.d.ts +4 -1
  110. package/dist/field/features/format/bold/feature.client.d.ts.map +1 -1
  111. package/dist/field/features/format/bold/feature.client.js +26 -23
  112. package/dist/field/features/format/bold/feature.client.js.map +1 -1
  113. package/dist/field/features/format/{inlinecode → inlineCode}/feature.client.d.ts +4 -1
  114. package/dist/field/features/format/inlineCode/feature.client.d.ts.map +1 -0
  115. package/dist/field/features/format/inlineCode/feature.client.js +46 -0
  116. package/dist/field/features/format/inlineCode/feature.client.js.map +1 -0
  117. package/dist/field/features/format/{inlinecode → inlineCode}/feature.server.d.ts.map +1 -1
  118. package/dist/field/features/format/{inlinecode → inlineCode}/feature.server.js +1 -1
  119. package/dist/field/features/format/{inlinecode → inlineCode}/feature.server.js.map +1 -1
  120. package/dist/field/features/format/{inlinecode → inlineCode}/markdownTransformers.d.ts.map +1 -1
  121. package/dist/field/features/format/{inlinecode → inlineCode}/markdownTransformers.js.map +1 -1
  122. package/dist/field/features/format/italic/feature.client.d.ts +4 -1
  123. package/dist/field/features/format/italic/feature.client.d.ts.map +1 -1
  124. package/dist/field/features/format/italic/feature.client.js +27 -24
  125. package/dist/field/features/format/italic/feature.client.js.map +1 -1
  126. package/dist/field/features/format/shared/toolbarFormatGroup.d.ts +3 -0
  127. package/dist/field/features/format/shared/toolbarFormatGroup.d.ts.map +1 -0
  128. package/dist/field/features/format/shared/toolbarFormatGroup.js +10 -0
  129. package/dist/field/features/format/shared/toolbarFormatGroup.js.map +1 -0
  130. package/dist/field/features/format/strikethrough/feature.client.d.ts +4 -1
  131. package/dist/field/features/format/strikethrough/feature.client.d.ts.map +1 -1
  132. package/dist/field/features/format/strikethrough/feature.client.js +27 -24
  133. package/dist/field/features/format/strikethrough/feature.client.js.map +1 -1
  134. package/dist/field/features/format/subscript/feature.client.d.ts +4 -1
  135. package/dist/field/features/format/subscript/feature.client.d.ts.map +1 -1
  136. package/dist/field/features/format/subscript/feature.client.js +25 -22
  137. package/dist/field/features/format/subscript/feature.client.js.map +1 -1
  138. package/dist/field/features/format/superscript/feature.client.d.ts +4 -1
  139. package/dist/field/features/format/superscript/feature.client.d.ts.map +1 -1
  140. package/dist/field/features/format/superscript/feature.client.js +25 -22
  141. package/dist/field/features/format/superscript/feature.client.js.map +1 -1
  142. package/dist/field/features/format/underline/feature.client.d.ts +4 -1
  143. package/dist/field/features/format/underline/feature.client.d.ts.map +1 -1
  144. package/dist/field/features/format/underline/feature.client.js +25 -22
  145. package/dist/field/features/format/underline/feature.client.js.map +1 -1
  146. package/dist/field/features/heading/feature.client.d.ts +4 -1
  147. package/dist/field/features/heading/feature.client.d.ts.map +1 -1
  148. package/dist/field/features/heading/feature.client.js +76 -54
  149. package/dist/field/features/heading/feature.client.js.map +1 -1
  150. package/dist/field/features/heading/feature.server.d.ts.map +1 -1
  151. package/dist/field/features/heading/feature.server.js +7 -5
  152. package/dist/field/features/heading/feature.server.js.map +1 -1
  153. package/dist/field/features/heading/i18n.d.ts +3 -0
  154. package/dist/field/features/heading/i18n.d.ts.map +1 -0
  155. package/dist/field/features/heading/i18n.js +100 -0
  156. package/dist/field/features/heading/i18n.js.map +1 -0
  157. package/dist/field/features/heading/markdownTransformer.d.ts.map +1 -1
  158. package/dist/field/features/heading/markdownTransformer.js +1 -2
  159. package/dist/field/features/heading/markdownTransformer.js.map +1 -1
  160. package/dist/field/features/horizontalRule/component/index.d.ts +10 -0
  161. package/dist/field/features/horizontalRule/component/index.d.ts.map +1 -0
  162. package/dist/field/features/horizontalRule/component/index.js +67 -0
  163. package/dist/field/features/horizontalRule/component/index.js.map +1 -0
  164. package/dist/field/features/horizontalRule/feature.client.d.ts +6 -0
  165. package/dist/field/features/horizontalRule/feature.client.d.ts.map +1 -0
  166. package/dist/field/features/horizontalRule/feature.client.js +77 -0
  167. package/dist/field/features/horizontalRule/feature.client.js.map +1 -0
  168. package/dist/field/features/horizontalRule/feature.server.d.ts +3 -0
  169. package/dist/field/features/horizontalRule/feature.server.d.ts.map +1 -0
  170. package/dist/field/features/horizontalRule/feature.server.js +38 -0
  171. package/dist/field/features/horizontalRule/feature.server.js.map +1 -0
  172. package/dist/field/features/horizontalRule/i18n.d.ts +3 -0
  173. package/dist/field/features/horizontalRule/i18n.d.ts.map +1 -0
  174. package/dist/field/features/horizontalRule/i18n.js +100 -0
  175. package/dist/field/features/horizontalRule/i18n.js.map +1 -0
  176. package/dist/field/features/horizontalRule/markdownTransformer.d.ts +3 -0
  177. package/dist/field/features/horizontalRule/markdownTransformer.d.ts.map +1 -0
  178. package/dist/field/features/horizontalRule/markdownTransformer.js +23 -0
  179. package/dist/field/features/horizontalRule/markdownTransformer.js.map +1 -0
  180. package/dist/field/features/horizontalRule/nodes/HorizontalRuleNode.d.ts +53 -0
  181. package/dist/field/features/horizontalRule/nodes/HorizontalRuleNode.d.ts.map +1 -0
  182. package/dist/field/features/horizontalRule/nodes/HorizontalRuleNode.js +92 -0
  183. package/dist/field/features/horizontalRule/nodes/HorizontalRuleNode.js.map +1 -0
  184. package/dist/field/features/horizontalRule/plugin/index.d.ts +7 -0
  185. package/dist/field/features/horizontalRule/plugin/index.d.ts.map +1 -0
  186. package/dist/field/features/horizontalRule/plugin/index.js +31 -0
  187. package/dist/field/features/horizontalRule/plugin/index.js.map +1 -0
  188. package/dist/field/features/horizontalRule/plugin/index.scss +20 -0
  189. package/dist/field/features/indent/feature.client.d.ts +4 -1
  190. package/dist/field/features/indent/feature.client.d.ts.map +1 -1
  191. package/dist/field/features/indent/feature.client.js +47 -42
  192. package/dist/field/features/indent/feature.client.js.map +1 -1
  193. package/dist/field/features/indent/feature.server.d.ts.map +1 -1
  194. package/dist/field/features/indent/feature.server.js +2 -0
  195. package/dist/field/features/indent/feature.server.js.map +1 -1
  196. package/dist/field/features/indent/i18n.d.ts +3 -0
  197. package/dist/field/features/indent/i18n.d.ts.map +1 -0
  198. package/dist/field/features/indent/i18n.js +132 -0
  199. package/dist/field/features/indent/i18n.js.map +1 -0
  200. package/dist/field/features/indent/toolbarIndentGroup.d.ts +3 -0
  201. package/dist/field/features/indent/toolbarIndentGroup.d.ts.map +1 -0
  202. package/dist/field/features/indent/toolbarIndentGroup.js +10 -0
  203. package/dist/field/features/indent/toolbarIndentGroup.js.map +1 -0
  204. package/dist/field/features/link/drawer/baseFields.d.ts +2 -2
  205. package/dist/field/features/link/drawer/baseFields.d.ts.map +1 -1
  206. package/dist/field/features/link/drawer/baseFields.js +30 -43
  207. package/dist/field/features/link/drawer/baseFields.js.map +1 -1
  208. package/dist/field/features/link/drawer/index.js +30 -21
  209. package/dist/field/features/link/drawer/index.js.map +1 -1
  210. package/dist/field/features/link/drawer/types.d.ts +4 -2
  211. package/dist/field/features/link/drawer/types.d.ts.map +1 -1
  212. package/dist/field/features/link/drawer/types.js.map +1 -1
  213. package/dist/field/features/link/feature.client.d.ts +13 -1
  214. package/dist/field/features/link/feature.client.d.ts.map +1 -1
  215. package/dist/field/features/link/feature.client.js +65 -47
  216. package/dist/field/features/link/feature.client.js.map +1 -1
  217. package/dist/field/features/link/feature.server.d.ts +10 -5
  218. package/dist/field/features/link/feature.server.d.ts.map +1 -1
  219. package/dist/field/features/link/feature.server.js +58 -11
  220. package/dist/field/features/link/feature.server.js.map +1 -1
  221. package/dist/field/features/link/i18n.d.ts +3 -0
  222. package/dist/field/features/link/i18n.d.ts.map +1 -0
  223. package/dist/field/features/link/i18n.js +100 -0
  224. package/dist/field/features/link/i18n.js.map +1 -0
  225. package/dist/field/features/link/markdownTransformer.d.ts +6 -0
  226. package/dist/field/features/link/markdownTransformer.d.ts.map +1 -0
  227. package/dist/field/features/link/markdownTransformer.js +50 -0
  228. package/dist/field/features/link/markdownTransformer.js.map +1 -0
  229. package/dist/field/features/link/nodes/AutoLinkNode.d.ts.map +1 -1
  230. package/dist/field/features/link/nodes/AutoLinkNode.js +1 -2
  231. package/dist/field/features/link/nodes/AutoLinkNode.js.map +1 -1
  232. package/dist/field/features/link/nodes/LinkNode.d.ts +4 -4
  233. package/dist/field/features/link/nodes/LinkNode.d.ts.map +1 -1
  234. package/dist/field/features/link/nodes/LinkNode.js +6 -7
  235. package/dist/field/features/link/nodes/LinkNode.js.map +1 -1
  236. package/dist/field/features/link/plugins/autoLink/index.d.ts +3 -2
  237. package/dist/field/features/link/plugins/autoLink/index.d.ts.map +1 -1
  238. package/dist/field/features/link/plugins/autoLink/index.js +11 -12
  239. package/dist/field/features/link/plugins/autoLink/index.js.map +1 -1
  240. package/dist/field/features/link/plugins/clickableLink/index.d.ts +3 -2
  241. package/dist/field/features/link/plugins/clickableLink/index.d.ts.map +1 -1
  242. package/dist/field/features/link/plugins/clickableLink/index.js +5 -6
  243. package/dist/field/features/link/plugins/clickableLink/index.js.map +1 -1
  244. package/dist/field/features/link/plugins/floatingLinkEditor/LinkEditor/commands.d.ts.map +1 -1
  245. package/dist/field/features/link/plugins/floatingLinkEditor/LinkEditor/commands.js +1 -2
  246. package/dist/field/features/link/plugins/floatingLinkEditor/LinkEditor/commands.js.map +1 -1
  247. package/dist/field/features/link/plugins/floatingLinkEditor/LinkEditor/index.d.ts.map +1 -1
  248. package/dist/field/features/link/plugins/floatingLinkEditor/LinkEditor/index.js +177 -135
  249. package/dist/field/features/link/plugins/floatingLinkEditor/LinkEditor/index.js.map +1 -1
  250. package/dist/field/features/link/plugins/floatingLinkEditor/index.d.ts +3 -4
  251. package/dist/field/features/link/plugins/floatingLinkEditor/index.d.ts.map +1 -1
  252. package/dist/field/features/link/plugins/floatingLinkEditor/index.js +2 -1
  253. package/dist/field/features/link/plugins/floatingLinkEditor/index.js.map +1 -1
  254. package/dist/field/features/link/plugins/floatingLinkEditor/index.scss +11 -3
  255. package/dist/field/features/link/plugins/floatingLinkEditor/utilities.d.ts +1 -3
  256. package/dist/field/features/link/plugins/floatingLinkEditor/utilities.d.ts.map +1 -1
  257. package/dist/field/features/link/plugins/floatingLinkEditor/utilities.js +12 -30
  258. package/dist/field/features/link/plugins/floatingLinkEditor/utilities.js.map +1 -1
  259. package/dist/field/features/link/plugins/link/index.d.ts +3 -1
  260. package/dist/field/features/link/plugins/link/index.d.ts.map +1 -1
  261. package/dist/field/features/link/plugins/link/index.js +5 -14
  262. package/dist/field/features/link/plugins/link/index.js.map +1 -1
  263. package/dist/field/features/link/populationPromise.d.ts.map +1 -1
  264. package/dist/field/features/link/populationPromise.js +11 -26
  265. package/dist/field/features/link/populationPromise.js.map +1 -1
  266. package/dist/field/features/link/validate.d.ts +5 -0
  267. package/dist/field/features/link/validate.d.ts.map +1 -0
  268. package/dist/field/features/link/validate.js +32 -0
  269. package/dist/field/features/link/validate.js.map +1 -0
  270. package/dist/field/features/lists/checklist/feature.client.d.ts +4 -1
  271. package/dist/field/features/lists/checklist/feature.client.d.ts.map +1 -1
  272. package/dist/field/features/lists/checklist/feature.client.js +69 -44
  273. package/dist/field/features/lists/checklist/feature.client.js.map +1 -1
  274. package/dist/field/features/lists/checklist/feature.server.d.ts +1 -1
  275. package/dist/field/features/lists/checklist/feature.server.d.ts.map +1 -1
  276. package/dist/field/features/lists/checklist/feature.server.js +12 -10
  277. package/dist/field/features/lists/checklist/feature.server.js.map +1 -1
  278. package/dist/field/features/lists/checklist/i18n.d.ts +3 -0
  279. package/dist/field/features/lists/checklist/i18n.d.ts.map +1 -0
  280. package/dist/field/features/lists/checklist/i18n.js +100 -0
  281. package/dist/field/features/lists/checklist/i18n.js.map +1 -0
  282. package/dist/field/features/lists/checklist/markdownTransformers.d.ts.map +1 -1
  283. package/dist/field/features/lists/checklist/markdownTransformers.js +2 -3
  284. package/dist/field/features/lists/checklist/markdownTransformers.js.map +1 -1
  285. package/dist/field/features/lists/checklist/plugin/index.d.ts +2 -2
  286. package/dist/field/features/lists/checklist/plugin/index.d.ts.map +1 -1
  287. package/dist/field/features/lists/checklist/plugin/index.js +5 -5
  288. package/dist/field/features/lists/checklist/plugin/index.js.map +1 -1
  289. package/dist/field/features/lists/htmlConverter.d.ts.map +1 -1
  290. package/dist/field/features/lists/htmlConverter.js +13 -6
  291. package/dist/field/features/lists/htmlConverter.js.map +1 -1
  292. package/dist/field/features/lists/{orderedlist → orderedList}/feature.client.d.ts +4 -1
  293. package/dist/field/features/lists/orderedList/feature.client.d.ts.map +1 -0
  294. package/dist/field/features/lists/orderedList/feature.client.js +97 -0
  295. package/dist/field/features/lists/orderedList/feature.client.js.map +1 -0
  296. package/dist/field/features/lists/orderedList/feature.server.d.ts.map +1 -0
  297. package/dist/field/features/lists/{orderedlist → orderedList}/feature.server.js +10 -8
  298. package/dist/field/features/lists/orderedList/feature.server.js.map +1 -0
  299. package/dist/field/features/lists/orderedList/i18n.d.ts +3 -0
  300. package/dist/field/features/lists/orderedList/i18n.d.ts.map +1 -0
  301. package/dist/field/features/lists/orderedList/i18n.js +100 -0
  302. package/dist/field/features/lists/orderedList/i18n.js.map +1 -0
  303. package/dist/field/features/lists/orderedList/markdownTransformer.d.ts.map +1 -0
  304. package/dist/field/features/lists/{orderedlist → orderedList}/markdownTransformer.js +2 -3
  305. package/dist/field/features/lists/orderedList/markdownTransformer.js.map +1 -0
  306. package/dist/field/features/lists/plugin/index.d.ts +2 -2
  307. package/dist/field/features/lists/plugin/index.d.ts.map +1 -1
  308. package/dist/field/features/lists/plugin/index.js +5 -5
  309. package/dist/field/features/lists/plugin/index.js.map +1 -1
  310. package/dist/field/features/lists/{common → shared}/markdown.d.ts.map +1 -1
  311. package/dist/field/features/lists/{common → shared}/markdown.js +1 -2
  312. package/dist/field/features/lists/shared/markdown.js.map +1 -0
  313. package/dist/field/features/lists/shared/slashMenuListGroup.d.ts +3 -0
  314. package/dist/field/features/lists/shared/slashMenuListGroup.d.ts.map +1 -0
  315. package/dist/field/features/lists/shared/slashMenuListGroup.js +11 -0
  316. package/dist/field/features/lists/shared/slashMenuListGroup.js.map +1 -0
  317. package/dist/field/features/lists/{unorderedlist → unorderedList}/feature.client.d.ts +4 -1
  318. package/dist/field/features/lists/unorderedList/feature.client.d.ts.map +1 -0
  319. package/dist/field/features/lists/unorderedList/feature.client.js +97 -0
  320. package/dist/field/features/lists/unorderedList/feature.client.js.map +1 -0
  321. package/dist/field/features/lists/unorderedList/feature.server.d.ts.map +1 -0
  322. package/dist/field/features/lists/{unorderedlist → unorderedList}/feature.server.js +9 -7
  323. package/dist/field/features/lists/unorderedList/feature.server.js.map +1 -0
  324. package/dist/field/features/lists/unorderedList/i18n.d.ts +3 -0
  325. package/dist/field/features/lists/unorderedList/i18n.d.ts.map +1 -0
  326. package/dist/field/features/lists/unorderedList/i18n.js +100 -0
  327. package/dist/field/features/lists/unorderedList/i18n.js.map +1 -0
  328. package/dist/field/features/lists/unorderedList/markdownTransformer.d.ts.map +1 -0
  329. package/dist/field/features/lists/{unorderedlist → unorderedList}/markdownTransformer.js +2 -3
  330. package/dist/field/features/lists/unorderedList/markdownTransformer.js.map +1 -0
  331. package/dist/field/features/migrations/lexicalPluginToLexical/converter/converters/upload/converter.d.ts.map +1 -1
  332. package/dist/field/features/migrations/lexicalPluginToLexical/converter/converters/upload/converter.js +2 -4
  333. package/dist/field/features/migrations/lexicalPluginToLexical/converter/converters/upload/converter.js.map +1 -1
  334. package/dist/field/features/migrations/lexicalPluginToLexical/feature.client.d.ts +4 -1
  335. package/dist/field/features/migrations/lexicalPluginToLexical/feature.client.d.ts.map +1 -1
  336. package/dist/field/features/migrations/lexicalPluginToLexical/nodes/unknownConvertedNode/Component.js +9 -1
  337. package/dist/field/features/migrations/lexicalPluginToLexical/nodes/unknownConvertedNode/Component.js.map +1 -1
  338. package/dist/field/features/migrations/lexicalPluginToLexical/nodes/unknownConvertedNode/index.d.ts +2 -4
  339. package/dist/field/features/migrations/lexicalPluginToLexical/nodes/unknownConvertedNode/index.d.ts.map +1 -1
  340. package/dist/field/features/migrations/lexicalPluginToLexical/nodes/unknownConvertedNode/index.js +4 -5
  341. package/dist/field/features/migrations/lexicalPluginToLexical/nodes/unknownConvertedNode/index.js.map +1 -1
  342. package/dist/field/features/migrations/slateToLexical/converter/converters/blockquote/client.d.ts +1 -1
  343. package/dist/field/features/migrations/slateToLexical/converter/converters/blockquote/client.js +1 -1
  344. package/dist/field/features/migrations/slateToLexical/converter/converters/blockquote/client.js.map +1 -1
  345. package/dist/field/features/migrations/slateToLexical/converter/converters/blockquote/index.js +2 -2
  346. package/dist/field/features/migrations/slateToLexical/converter/converters/blockquote/index.js.map +1 -1
  347. package/dist/field/features/migrations/slateToLexical/converter/converters/relationship/converter.d.ts.map +1 -1
  348. package/dist/field/features/migrations/slateToLexical/converter/converters/relationship/converter.js +2 -4
  349. package/dist/field/features/migrations/slateToLexical/converter/converters/relationship/converter.js.map +1 -1
  350. package/dist/field/features/migrations/slateToLexical/converter/converters/upload/converter.d.ts.map +1 -1
  351. package/dist/field/features/migrations/slateToLexical/converter/converters/upload/converter.js +2 -4
  352. package/dist/field/features/migrations/slateToLexical/converter/converters/upload/converter.js.map +1 -1
  353. package/dist/field/features/migrations/slateToLexical/converter/index.d.ts.map +1 -1
  354. package/dist/field/features/migrations/slateToLexical/converter/index.js +2 -1
  355. package/dist/field/features/migrations/slateToLexical/converter/index.js.map +1 -1
  356. package/dist/field/features/migrations/slateToLexical/feature.client.d.ts +4 -1
  357. package/dist/field/features/migrations/slateToLexical/feature.client.d.ts.map +1 -1
  358. package/dist/field/features/migrations/slateToLexical/nodes/unknownConvertedNode/Component.js +9 -1
  359. package/dist/field/features/migrations/slateToLexical/nodes/unknownConvertedNode/Component.js.map +1 -1
  360. package/dist/field/features/migrations/slateToLexical/nodes/unknownConvertedNode/index.d.ts +2 -4
  361. package/dist/field/features/migrations/slateToLexical/nodes/unknownConvertedNode/index.d.ts.map +1 -1
  362. package/dist/field/features/migrations/slateToLexical/nodes/unknownConvertedNode/index.js +4 -5
  363. package/dist/field/features/migrations/slateToLexical/nodes/unknownConvertedNode/index.js.map +1 -1
  364. package/dist/field/features/paragraph/feature.client.d.ts +4 -1
  365. package/dist/field/features/paragraph/feature.client.d.ts.map +1 -1
  366. package/dist/field/features/paragraph/feature.client.js +54 -41
  367. package/dist/field/features/paragraph/feature.client.js.map +1 -1
  368. package/dist/field/features/paragraph/feature.server.d.ts.map +1 -1
  369. package/dist/field/features/paragraph/feature.server.js +2 -0
  370. package/dist/field/features/paragraph/feature.server.js.map +1 -1
  371. package/dist/field/features/paragraph/i18n.d.ts +3 -0
  372. package/dist/field/features/paragraph/i18n.d.ts.map +1 -0
  373. package/dist/field/features/paragraph/i18n.js +132 -0
  374. package/dist/field/features/paragraph/i18n.js.map +1 -0
  375. package/dist/field/features/relationship/drawer/commands.d.ts.map +1 -1
  376. package/dist/field/features/relationship/drawer/commands.js +1 -2
  377. package/dist/field/features/relationship/drawer/commands.js.map +1 -1
  378. package/dist/field/features/relationship/drawer/index.d.ts.map +1 -1
  379. package/dist/field/features/relationship/drawer/index.js +17 -15
  380. package/dist/field/features/relationship/drawer/index.js.map +1 -1
  381. package/dist/field/features/relationship/feature.client.d.ts +17 -2
  382. package/dist/field/features/relationship/feature.client.d.ts.map +1 -1
  383. package/dist/field/features/relationship/feature.client.js +51 -28
  384. package/dist/field/features/relationship/feature.client.js.map +1 -1
  385. package/dist/field/features/relationship/feature.server.d.ts +10 -1
  386. package/dist/field/features/relationship/feature.server.d.ts.map +1 -1
  387. package/dist/field/features/relationship/feature.server.js +7 -4
  388. package/dist/field/features/relationship/feature.server.js.map +1 -1
  389. package/dist/field/features/relationship/i18n.d.ts +3 -0
  390. package/dist/field/features/relationship/i18n.d.ts.map +1 -0
  391. package/dist/field/features/relationship/i18n.js +100 -0
  392. package/dist/field/features/relationship/i18n.js.map +1 -0
  393. package/dist/field/features/relationship/nodes/RelationshipNode.d.ts +4 -9
  394. package/dist/field/features/relationship/nodes/RelationshipNode.d.ts.map +1 -1
  395. package/dist/field/features/relationship/nodes/RelationshipNode.js +12 -11
  396. package/dist/field/features/relationship/nodes/RelationshipNode.js.map +1 -1
  397. package/dist/field/features/relationship/nodes/components/RelationshipComponent.d.ts.map +1 -1
  398. package/dist/field/features/relationship/nodes/components/RelationshipComponent.js +119 -50
  399. package/dist/field/features/relationship/nodes/components/RelationshipComponent.js.map +1 -1
  400. package/dist/field/features/relationship/plugins/index.d.ts +2 -2
  401. package/dist/field/features/relationship/plugins/index.d.ts.map +1 -1
  402. package/dist/field/features/relationship/plugins/index.js +14 -15
  403. package/dist/field/features/relationship/plugins/index.js.map +1 -1
  404. package/dist/field/features/relationship/populationPromise.d.ts +2 -1
  405. package/dist/field/features/relationship/populationPromise.d.ts.map +1 -1
  406. package/dist/field/features/relationship/populationPromise.js +25 -19
  407. package/dist/field/features/relationship/populationPromise.js.map +1 -1
  408. package/dist/field/features/shared/slashMenu/basicGroup.d.ts +3 -0
  409. package/dist/field/features/shared/slashMenu/basicGroup.d.ts.map +1 -0
  410. package/dist/field/features/shared/slashMenu/basicGroup.js +11 -0
  411. package/dist/field/features/shared/slashMenu/basicGroup.js.map +1 -0
  412. package/dist/field/features/shared/toolbar/addDropdownGroup.d.ts +3 -0
  413. package/dist/field/features/shared/toolbar/addDropdownGroup.d.ts.map +1 -0
  414. package/dist/field/features/shared/toolbar/addDropdownGroup.js +12 -0
  415. package/dist/field/features/shared/toolbar/addDropdownGroup.js.map +1 -0
  416. package/dist/field/features/shared/toolbar/featureButtonsGroup.d.ts +3 -0
  417. package/dist/field/features/shared/toolbar/featureButtonsGroup.d.ts.map +1 -0
  418. package/dist/field/features/shared/toolbar/featureButtonsGroup.js +10 -0
  419. package/dist/field/features/shared/toolbar/featureButtonsGroup.js.map +1 -0
  420. package/dist/field/features/shared/toolbar/textDropdownGroup.d.ts +3 -0
  421. package/dist/field/features/shared/toolbar/textDropdownGroup.d.ts.map +1 -0
  422. package/dist/field/features/shared/toolbar/textDropdownGroup.js +12 -0
  423. package/dist/field/features/shared/toolbar/textDropdownGroup.js.map +1 -0
  424. package/dist/field/features/toolbars/fixed/Toolbar/index.d.ts +5 -0
  425. package/dist/field/features/toolbars/fixed/Toolbar/index.d.ts.map +1 -0
  426. package/dist/field/features/toolbars/fixed/Toolbar/index.js +211 -0
  427. package/dist/field/features/toolbars/fixed/Toolbar/index.js.map +1 -0
  428. package/dist/field/features/toolbars/fixed/Toolbar/index.scss +119 -0
  429. package/dist/field/features/toolbars/fixed/feature.client.d.ts +7 -0
  430. package/dist/field/features/toolbars/fixed/feature.client.d.ts.map +1 -0
  431. package/dist/field/features/toolbars/fixed/feature.client.js +20 -0
  432. package/dist/field/features/toolbars/fixed/feature.client.js.map +1 -0
  433. package/dist/field/features/toolbars/fixed/feature.server.d.ts +19 -0
  434. package/dist/field/features/toolbars/fixed/feature.server.d.ts.map +1 -0
  435. package/dist/field/features/toolbars/fixed/feature.server.js +20 -0
  436. package/dist/field/features/toolbars/fixed/feature.server.js.map +1 -0
  437. package/dist/field/features/toolbars/inline/Toolbar/index.d.ts +4 -0
  438. package/dist/field/features/toolbars/inline/Toolbar/index.d.ts.map +1 -0
  439. package/dist/field/features/toolbars/inline/Toolbar/index.js +320 -0
  440. package/dist/field/features/toolbars/inline/Toolbar/index.js.map +1 -0
  441. package/dist/field/{lexical/plugins/FloatingSelectToolbar → features/toolbars/inline/Toolbar}/index.scss +7 -11
  442. package/dist/field/features/toolbars/inline/feature.client.d.ts +6 -0
  443. package/dist/field/features/toolbars/inline/feature.client.d.ts.map +1 -0
  444. package/dist/field/features/toolbars/inline/feature.client.js +20 -0
  445. package/dist/field/features/toolbars/inline/feature.client.js.map +1 -0
  446. package/dist/field/features/toolbars/inline/feature.server.d.ts +3 -0
  447. package/dist/field/features/toolbars/inline/feature.server.d.ts.map +1 -0
  448. package/dist/field/features/toolbars/inline/feature.server.js +15 -0
  449. package/dist/field/features/toolbars/inline/feature.server.js.map +1 -0
  450. package/dist/field/features/toolbars/shared/ToolbarButton/index.d.ts +10 -0
  451. package/dist/field/features/toolbars/shared/ToolbarButton/index.d.ts.map +1 -0
  452. package/dist/field/{lexical/plugins/FloatingSelectToolbar → features/toolbars/shared}/ToolbarButton/index.js +34 -22
  453. package/dist/field/features/toolbars/shared/ToolbarButton/index.js.map +1 -0
  454. package/dist/field/{lexical/plugins/FloatingSelectToolbar → features/toolbars/shared}/ToolbarButton/index.scss +3 -1
  455. package/dist/field/features/toolbars/shared/ToolbarDropdown/DropDown.d.ts +23 -0
  456. package/dist/field/features/toolbars/shared/ToolbarDropdown/DropDown.d.ts.map +1 -0
  457. package/dist/field/{lexical/plugins/FloatingSelectToolbar → features/toolbars/shared}/ToolbarDropdown/DropDown.js +74 -100
  458. package/dist/field/features/toolbars/shared/ToolbarDropdown/DropDown.js.map +1 -0
  459. package/dist/field/features/toolbars/shared/ToolbarDropdown/index.d.ts +23 -0
  460. package/dist/field/features/toolbars/shared/ToolbarDropdown/index.d.ts.map +1 -0
  461. package/dist/field/features/toolbars/shared/ToolbarDropdown/index.js +142 -0
  462. package/dist/field/features/toolbars/shared/ToolbarDropdown/index.js.map +1 -0
  463. package/dist/field/{lexical/plugins/FloatingSelectToolbar → features/toolbars/shared}/ToolbarDropdown/index.scss +25 -13
  464. package/dist/field/features/toolbars/types.d.ts +48 -0
  465. package/dist/field/features/toolbars/types.d.ts.map +1 -0
  466. package/dist/field/features/toolbars/types.js.map +1 -0
  467. package/dist/field/features/typeUtilities.d.ts +8 -0
  468. package/dist/field/features/typeUtilities.d.ts.map +1 -0
  469. package/dist/field/features/typeUtilities.js +8 -0
  470. package/dist/field/features/typeUtilities.js.map +1 -0
  471. package/dist/field/features/types.d.ts +172 -63
  472. package/dist/field/features/types.d.ts.map +1 -1
  473. package/dist/field/features/types.js.map +1 -1
  474. package/dist/field/features/upload/component/ExtraFieldsDrawer/index.d.ts.map +1 -1
  475. package/dist/field/features/upload/component/ExtraFieldsDrawer/index.js +32 -25
  476. package/dist/field/features/upload/component/ExtraFieldsDrawer/index.js.map +1 -1
  477. package/dist/field/features/upload/component/index.d.ts.map +1 -1
  478. package/dist/field/features/upload/component/index.js +159 -76
  479. package/dist/field/features/upload/component/index.js.map +1 -1
  480. package/dist/field/features/upload/drawer/commands.d.ts.map +1 -1
  481. package/dist/field/features/upload/drawer/commands.js +1 -2
  482. package/dist/field/features/upload/drawer/commands.js.map +1 -1
  483. package/dist/field/features/upload/drawer/index.d.ts.map +1 -1
  484. package/dist/field/features/upload/drawer/index.js +16 -16
  485. package/dist/field/features/upload/drawer/index.js.map +1 -1
  486. package/dist/field/features/upload/feature.client.d.ts +4 -1
  487. package/dist/field/features/upload/feature.client.d.ts.map +1 -1
  488. package/dist/field/features/upload/feature.client.js +52 -26
  489. package/dist/field/features/upload/feature.client.js.map +1 -1
  490. package/dist/field/features/upload/feature.server.d.ts +10 -3
  491. package/dist/field/features/upload/feature.server.d.ts.map +1 -1
  492. package/dist/field/features/upload/feature.server.js +41 -11
  493. package/dist/field/features/upload/feature.server.js.map +1 -1
  494. package/dist/field/features/upload/i18n.d.ts +3 -0
  495. package/dist/field/features/upload/i18n.d.ts.map +1 -0
  496. package/dist/field/features/upload/i18n.js +100 -0
  497. package/dist/field/features/upload/i18n.js.map +1 -0
  498. package/dist/field/features/upload/nodes/UploadNode.d.ts +3 -15
  499. package/dist/field/features/upload/nodes/UploadNode.d.ts.map +1 -1
  500. package/dist/field/features/upload/nodes/UploadNode.js +35 -14
  501. package/dist/field/features/upload/nodes/UploadNode.js.map +1 -1
  502. package/dist/field/features/upload/plugin/index.d.ts +5 -4
  503. package/dist/field/features/upload/plugin/index.d.ts.map +1 -1
  504. package/dist/field/features/upload/plugin/index.js +16 -19
  505. package/dist/field/features/upload/plugin/index.js.map +1 -1
  506. package/dist/field/features/upload/populationPromise.d.ts.map +1 -1
  507. package/dist/field/features/upload/populationPromise.js +16 -10
  508. package/dist/field/features/upload/populationPromise.js.map +1 -1
  509. package/dist/field/features/upload/validate.d.ts +2 -1
  510. package/dist/field/features/upload/validate.d.ts.map +1 -1
  511. package/dist/field/features/upload/validate.js +36 -9
  512. package/dist/field/features/upload/validate.js.map +1 -1
  513. package/dist/field/index.d.ts +3 -1
  514. package/dist/field/index.d.ts.map +1 -1
  515. package/dist/field/index.js +39 -26
  516. package/dist/field/index.js.map +1 -1
  517. package/dist/field/index.scss +1 -22
  518. package/dist/field/lexical/EditorPlugin.d.ts +1 -0
  519. package/dist/field/lexical/EditorPlugin.d.ts.map +1 -1
  520. package/dist/field/lexical/EditorPlugin.js +8 -4
  521. package/dist/field/lexical/EditorPlugin.js.map +1 -1
  522. package/dist/field/lexical/LexicalEditor.d.ts +3 -1
  523. package/dist/field/lexical/LexicalEditor.d.ts.map +1 -1
  524. package/dist/field/lexical/LexicalEditor.js +157 -76
  525. package/dist/field/lexical/LexicalEditor.js.map +1 -1
  526. package/dist/field/lexical/LexicalEditor.scss +13 -20
  527. package/dist/field/lexical/LexicalProvider.d.ts +1 -1
  528. package/dist/field/lexical/LexicalProvider.d.ts.map +1 -1
  529. package/dist/field/lexical/LexicalProvider.js +52 -41
  530. package/dist/field/lexical/LexicalProvider.js.map +1 -1
  531. package/dist/field/lexical/config/client/EditorConfigProvider.d.ts +15 -4
  532. package/dist/field/lexical/config/client/EditorConfigProvider.d.ts.map +1 -1
  533. package/dist/field/lexical/config/client/EditorConfigProvider.js +61 -11
  534. package/dist/field/lexical/config/client/EditorConfigProvider.js.map +1 -1
  535. package/dist/field/lexical/config/client/default.d.ts +1 -1
  536. package/dist/field/lexical/config/client/default.d.ts.map +1 -1
  537. package/dist/field/lexical/config/client/default.js.map +1 -1
  538. package/dist/field/lexical/config/client/sanitize.d.ts +3 -2
  539. package/dist/field/lexical/config/client/sanitize.d.ts.map +1 -1
  540. package/dist/field/lexical/config/client/sanitize.js +83 -33
  541. package/dist/field/lexical/config/client/sanitize.js.map +1 -1
  542. package/dist/field/lexical/config/server/default.d.ts +2 -3
  543. package/dist/field/lexical/config/server/default.d.ts.map +1 -1
  544. package/dist/field/lexical/config/server/default.js +12 -10
  545. package/dist/field/lexical/config/server/default.js.map +1 -1
  546. package/dist/field/lexical/config/server/loader.d.ts +5 -2
  547. package/dist/field/lexical/config/server/loader.d.ts.map +1 -1
  548. package/dist/field/lexical/config/server/loader.js +4 -2
  549. package/dist/field/lexical/config/server/loader.js.map +1 -1
  550. package/dist/field/lexical/config/server/sanitize.d.ts +2 -1
  551. package/dist/field/lexical/config/server/sanitize.d.ts.map +1 -1
  552. package/dist/field/lexical/config/server/sanitize.js +32 -6
  553. package/dist/field/lexical/config/server/sanitize.js.map +1 -1
  554. package/dist/field/lexical/config/types.d.ts +3 -1
  555. package/dist/field/lexical/config/types.d.ts.map +1 -1
  556. package/dist/field/lexical/config/types.js.map +1 -1
  557. package/dist/field/lexical/plugins/MarkdownShortcut/index.d.ts.map +1 -1
  558. package/dist/field/lexical/plugins/MarkdownShortcut/index.js +3 -3
  559. package/dist/field/lexical/plugins/MarkdownShortcut/index.js.map +1 -1
  560. package/dist/field/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/LexicalMenu.d.ts +10 -10
  561. package/dist/field/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/LexicalMenu.d.ts.map +1 -1
  562. package/dist/field/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/LexicalMenu.js +74 -77
  563. package/dist/field/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/LexicalMenu.js.map +1 -1
  564. package/dist/field/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/index.d.ts +5 -5
  565. package/dist/field/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/index.d.ts.map +1 -1
  566. package/dist/field/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/index.js +8 -10
  567. package/dist/field/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/index.js.map +1 -1
  568. package/dist/field/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/types.d.ts +19 -27
  569. package/dist/field/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/types.d.ts.map +1 -1
  570. package/dist/field/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/types.js +1 -37
  571. package/dist/field/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/types.js.map +1 -1
  572. package/dist/field/lexical/plugins/SlashMenu/index.d.ts +2 -2
  573. package/dist/field/lexical/plugins/SlashMenu/index.d.ts.map +1 -1
  574. package/dist/field/lexical/plugins/SlashMenu/index.js +108 -92
  575. package/dist/field/lexical/plugins/SlashMenu/index.js.map +1 -1
  576. package/dist/field/lexical/plugins/handles/AddBlockHandlePlugin/index.d.ts +2 -2
  577. package/dist/field/lexical/plugins/handles/AddBlockHandlePlugin/index.d.ts.map +1 -1
  578. package/dist/field/lexical/plugins/handles/AddBlockHandlePlugin/index.js +47 -125
  579. package/dist/field/lexical/plugins/handles/AddBlockHandlePlugin/index.js.map +1 -1
  580. package/dist/field/lexical/plugins/handles/AddBlockHandlePlugin/index.scss +2 -2
  581. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/highlightElemOriginalPosition.d.ts +1 -1
  582. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/highlightElemOriginalPosition.d.ts.map +1 -1
  583. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/highlightElemOriginalPosition.js.map +1 -1
  584. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/index.d.ts +2 -2
  585. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/index.d.ts.map +1 -1
  586. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/index.js +116 -66
  587. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/index.js.map +1 -1
  588. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/index.scss +20 -3
  589. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/setTargetLine.d.ts +8 -1
  590. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/setTargetLine.d.ts.map +1 -1
  591. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/setTargetLine.js +83 -16
  592. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/setTargetLine.js.map +1 -1
  593. package/dist/field/lexical/plugins/handles/utils/calculateDistanceFromScrollerElem.d.ts +5 -0
  594. package/dist/field/lexical/plugins/handles/utils/calculateDistanceFromScrollerElem.d.ts.map +1 -0
  595. package/dist/field/lexical/plugins/handles/utils/calculateDistanceFromScrollerElem.js +21 -0
  596. package/dist/field/lexical/plugins/handles/utils/calculateDistanceFromScrollerElem.js.map +1 -0
  597. package/dist/field/lexical/plugins/handles/utils/doesLineHeightAffectElement.d.ts +9 -0
  598. package/dist/field/lexical/plugins/handles/utils/doesLineHeightAffectElement.d.ts.map +1 -0
  599. package/dist/field/lexical/plugins/handles/utils/doesLineHeightAffectElement.js +35 -0
  600. package/dist/field/lexical/plugins/handles/utils/doesLineHeightAffectElement.js.map +1 -0
  601. package/dist/field/lexical/plugins/handles/{DraggableBlockPlugin → utils}/getNodeCloseToPoint.d.ts +5 -1
  602. package/dist/field/lexical/plugins/handles/utils/getNodeCloseToPoint.d.ts.map +1 -0
  603. package/dist/field/lexical/plugins/handles/{DraggableBlockPlugin → utils}/getNodeCloseToPoint.js +5 -18
  604. package/dist/field/lexical/plugins/handles/utils/getNodeCloseToPoint.js.map +1 -0
  605. package/dist/field/lexical/plugins/handles/utils/getTopLevelNodeKeys.d.ts.map +1 -1
  606. package/dist/field/lexical/plugins/handles/utils/getTopLevelNodeKeys.js +1 -2
  607. package/dist/field/lexical/plugins/handles/utils/getTopLevelNodeKeys.js.map +1 -1
  608. package/dist/field/lexical/plugins/handles/utils/setHandlePosition.d.ts +1 -1
  609. package/dist/field/lexical/plugins/handles/utils/setHandlePosition.d.ts.map +1 -1
  610. package/dist/field/lexical/plugins/handles/utils/setHandlePosition.js +19 -7
  611. package/dist/field/lexical/plugins/handles/utils/setHandlePosition.js.map +1 -1
  612. package/dist/field/lexical/theme/EditorTheme.d.ts.map +1 -1
  613. package/dist/field/lexical/theme/EditorTheme.js +1 -0
  614. package/dist/field/lexical/theme/EditorTheme.js.map +1 -1
  615. package/dist/field/lexical/theme/EditorTheme.scss +18 -14
  616. package/dist/field/lexical/ui/ContentEditable.d.ts +1 -1
  617. package/dist/field/lexical/ui/ContentEditable.d.ts.map +1 -1
  618. package/dist/field/lexical/ui/ContentEditable.js +3 -3
  619. package/dist/field/lexical/ui/ContentEditable.js.map +1 -1
  620. package/dist/field/lexical/ui/ContentEditable.scss +55 -4
  621. package/dist/field/lexical/ui/icons/AI/index.js +26 -17
  622. package/dist/field/lexical/ui/icons/AI/index.js.map +1 -1
  623. package/dist/field/lexical/ui/icons/Add/index.d.ts +3 -0
  624. package/dist/field/lexical/ui/icons/Add/index.d.ts.map +1 -0
  625. package/dist/field/lexical/ui/icons/Add/index.js +21 -0
  626. package/dist/field/lexical/ui/icons/Add/index.js.map +1 -0
  627. package/dist/field/lexical/ui/icons/Add/light.svg +4 -0
  628. package/dist/field/lexical/ui/icons/AlignCenter/index.js +21 -15
  629. package/dist/field/lexical/ui/icons/AlignCenter/index.js.map +1 -1
  630. package/dist/field/lexical/ui/icons/AlignJustify/index.js +21 -15
  631. package/dist/field/lexical/ui/icons/AlignJustify/index.js.map +1 -1
  632. package/dist/field/lexical/ui/icons/AlignLeft/index.js +21 -15
  633. package/dist/field/lexical/ui/icons/AlignLeft/index.js.map +1 -1
  634. package/dist/field/lexical/ui/icons/AlignRight/index.js +21 -15
  635. package/dist/field/lexical/ui/icons/AlignRight/index.js.map +1 -1
  636. package/dist/field/lexical/ui/icons/Block/index.js +30 -24
  637. package/dist/field/lexical/ui/icons/Block/index.js.map +1 -1
  638. package/dist/field/lexical/ui/icons/Blockquote/index.js +8 -6
  639. package/dist/field/lexical/ui/icons/Blockquote/index.js.map +1 -1
  640. package/dist/field/lexical/ui/icons/Bold/index.js +8 -6
  641. package/dist/field/lexical/ui/icons/Bold/index.js.map +1 -1
  642. package/dist/field/lexical/ui/icons/Checklist/index.js +19 -14
  643. package/dist/field/lexical/ui/icons/Checklist/index.js.map +1 -1
  644. package/dist/field/lexical/ui/icons/Code/index.js +14 -9
  645. package/dist/field/lexical/ui/icons/Code/index.js.map +1 -1
  646. package/dist/field/lexical/ui/icons/CodeBlock/index.js +14 -9
  647. package/dist/field/lexical/ui/icons/CodeBlock/index.js.map +1 -1
  648. package/dist/field/lexical/ui/icons/DraggableBlock/light.svg +9 -0
  649. package/dist/field/lexical/ui/icons/H1/index.js +8 -6
  650. package/dist/field/lexical/ui/icons/H1/index.js.map +1 -1
  651. package/dist/field/lexical/ui/icons/H2/index.js +8 -6
  652. package/dist/field/lexical/ui/icons/H2/index.js.map +1 -1
  653. package/dist/field/lexical/ui/icons/H3/index.js +8 -6
  654. package/dist/field/lexical/ui/icons/H3/index.js.map +1 -1
  655. package/dist/field/lexical/ui/icons/H4/index.js +8 -6
  656. package/dist/field/lexical/ui/icons/H4/index.js.map +1 -1
  657. package/dist/field/lexical/ui/icons/H5/index.js +8 -6
  658. package/dist/field/lexical/ui/icons/H5/index.js.map +1 -1
  659. package/dist/field/lexical/ui/icons/H6/index.js +8 -6
  660. package/dist/field/lexical/ui/icons/H6/index.js.map +1 -1
  661. package/dist/field/lexical/ui/icons/HorizontalRule/index.d.ts +3 -0
  662. package/dist/field/lexical/ui/icons/HorizontalRule/index.d.ts.map +1 -0
  663. package/dist/field/lexical/ui/icons/HorizontalRule/index.js +21 -0
  664. package/dist/field/lexical/ui/icons/HorizontalRule/index.js.map +1 -0
  665. package/dist/field/lexical/ui/icons/IndentDecrease/index.js +25 -18
  666. package/dist/field/lexical/ui/icons/IndentDecrease/index.js.map +1 -1
  667. package/dist/field/lexical/ui/icons/IndentIncrease/index.js +25 -18
  668. package/dist/field/lexical/ui/icons/IndentIncrease/index.js.map +1 -1
  669. package/dist/field/lexical/ui/icons/Italic/index.js +8 -6
  670. package/dist/field/lexical/ui/icons/Italic/index.js.map +1 -1
  671. package/dist/field/lexical/ui/icons/Link/index.d.ts.map +1 -1
  672. package/dist/field/lexical/ui/icons/Link/index.js +10 -18
  673. package/dist/field/lexical/ui/icons/Link/index.js.map +1 -1
  674. package/dist/field/lexical/ui/icons/OrderedList/index.js +29 -21
  675. package/dist/field/lexical/ui/icons/OrderedList/index.js.map +1 -1
  676. package/dist/field/lexical/ui/icons/Relationship/index.js +26 -17
  677. package/dist/field/lexical/ui/icons/Relationship/index.js.map +1 -1
  678. package/dist/field/lexical/ui/icons/Strikethrough/index.js +14 -9
  679. package/dist/field/lexical/ui/icons/Strikethrough/index.js.map +1 -1
  680. package/dist/field/lexical/ui/icons/Subscript/index.js +8 -6
  681. package/dist/field/lexical/ui/icons/Subscript/index.js.map +1 -1
  682. package/dist/field/lexical/ui/icons/Superscript/index.js +8 -6
  683. package/dist/field/lexical/ui/icons/Superscript/index.js.map +1 -1
  684. package/dist/field/lexical/ui/icons/Text/index.js +8 -6
  685. package/dist/field/lexical/ui/icons/Text/index.js.map +1 -1
  686. package/dist/field/lexical/ui/icons/Underline/index.js +14 -9
  687. package/dist/field/lexical/ui/icons/Underline/index.js.map +1 -1
  688. package/dist/field/lexical/ui/icons/UnorderedList/index.js +45 -36
  689. package/dist/field/lexical/ui/icons/UnorderedList/index.js.map +1 -1
  690. package/dist/field/lexical/ui/icons/Upload/index.js +24 -18
  691. package/dist/field/lexical/ui/icons/Upload/index.js.map +1 -1
  692. package/dist/field/lexical/utils/getSelectedNode.d.ts.map +1 -1
  693. package/dist/field/lexical/utils/getSelectedNode.js +1 -2
  694. package/dist/field/lexical/utils/getSelectedNode.js.map +1 -1
  695. package/dist/field/lexical/utils/nodeFormat.d.ts +2 -1
  696. package/dist/field/lexical/utils/nodeFormat.d.ts.map +1 -1
  697. package/dist/field/lexical/utils/nodeFormat.js.map +1 -1
  698. package/dist/field/lexical/utils/setFloatingElemPosition.d.ts +11 -1
  699. package/dist/field/lexical/utils/setFloatingElemPosition.d.ts.map +1 -1
  700. package/dist/field/lexical/utils/setFloatingElemPosition.js +16 -13
  701. package/dist/field/lexical/utils/setFloatingElemPosition.js.map +1 -1
  702. package/dist/field/lexical/utils/url.d.ts.map +1 -1
  703. package/dist/field/lexical/utils/url.js +13 -2
  704. package/dist/field/lexical/utils/url.js.map +1 -1
  705. package/dist/forEachNodeRecursively.d.ts +10 -0
  706. package/dist/forEachNodeRecursively.d.ts.map +1 -0
  707. package/dist/forEachNodeRecursively.js +24 -0
  708. package/dist/forEachNodeRecursively.js.map +1 -0
  709. package/dist/generateComponentMap.d.ts.map +1 -1
  710. package/dist/generateComponentMap.js +21 -29
  711. package/dist/generateComponentMap.js.map +1 -1
  712. package/dist/generateSchemaMap.d.ts.map +1 -1
  713. package/dist/generateSchemaMap.js +4 -12
  714. package/dist/generateSchemaMap.js.map +1 -1
  715. package/dist/i18n.d.ts +3 -0
  716. package/dist/i18n.d.ts.map +1 -0
  717. package/dist/i18n.js +164 -0
  718. package/dist/i18n.js.map +1 -0
  719. package/dist/index.d.ts +25 -21
  720. package/dist/index.d.ts.map +1 -1
  721. package/dist/index.js +296 -183
  722. package/dist/index.js.map +1 -1
  723. package/dist/populate/defaultValue.d.ts +0 -1
  724. package/dist/populate/defaultValue.d.ts.map +1 -1
  725. package/dist/populate/defaultValue.js +1 -19
  726. package/dist/populate/defaultValue.js.map +1 -1
  727. package/dist/populate/populate.d.ts +5 -4
  728. package/dist/populate/populate.d.ts.map +1 -1
  729. package/dist/populate/populate.js +13 -11
  730. package/dist/populate/populate.js.map +1 -1
  731. package/dist/populate/populateLexicalPopulationPromises.d.ts +12 -0
  732. package/dist/populate/populateLexicalPopulationPromises.d.ts.map +1 -0
  733. package/dist/populate/populateLexicalPopulationPromises.js +36 -0
  734. package/dist/populate/populateLexicalPopulationPromises.js.map +1 -0
  735. package/dist/populate/recurseNestedFields.d.ts +8 -4
  736. package/dist/populate/recurseNestedFields.d.ts.map +1 -1
  737. package/dist/populate/recurseNestedFields.js +4 -5
  738. package/dist/populate/recurseNestedFields.js.map +1 -1
  739. package/dist/scss/app.scss +2 -3
  740. package/dist/scss/vars.scss +0 -7
  741. package/dist/types.d.ts +45 -6
  742. package/dist/types.d.ts.map +1 -1
  743. package/dist/types.js.map +1 -1
  744. package/dist/useLexicalFeature.d.ts.map +1 -1
  745. package/dist/useLexicalFeature.js +6 -1
  746. package/dist/useLexicalFeature.js.map +1 -1
  747. package/dist/validate/index.d.ts +1 -1
  748. package/dist/validate/index.d.ts.map +1 -1
  749. package/dist/validate/index.js +3 -2
  750. package/dist/validate/index.js.map +1 -1
  751. package/dist/validate/validateNodes.js +1 -1
  752. package/dist/validate/validateNodes.js.map +1 -1
  753. package/package.json +71 -51
  754. package/dist/field/features/align/floatingSelectToolbarAlignDropdownSection.d.ts +0 -3
  755. package/dist/field/features/align/floatingSelectToolbarAlignDropdownSection.d.ts.map +0 -1
  756. package/dist/field/features/align/floatingSelectToolbarAlignDropdownSection.js +0 -12
  757. package/dist/field/features/align/floatingSelectToolbarAlignDropdownSection.js.map +0 -1
  758. package/dist/field/features/common/floatingSelectToolbarFeaturesButtonsSection/index.d.ts +0 -3
  759. package/dist/field/features/common/floatingSelectToolbarFeaturesButtonsSection/index.d.ts.map +0 -1
  760. package/dist/field/features/common/floatingSelectToolbarFeaturesButtonsSection/index.js +0 -10
  761. package/dist/field/features/common/floatingSelectToolbarFeaturesButtonsSection/index.js.map +0 -1
  762. package/dist/field/features/common/floatingSelectToolbarTextDropdownSection/index.d.ts +0 -3
  763. package/dist/field/features/common/floatingSelectToolbarTextDropdownSection/index.d.ts.map +0 -1
  764. package/dist/field/features/common/floatingSelectToolbarTextDropdownSection/index.js +0 -12
  765. package/dist/field/features/common/floatingSelectToolbarTextDropdownSection/index.js.map +0 -1
  766. package/dist/field/features/debug/testrecorder/feature.client.d.ts.map +0 -1
  767. package/dist/field/features/debug/testrecorder/plugin/index.d.ts +0 -5
  768. package/dist/field/features/debug/testrecorder/plugin/index.d.ts.map +0 -1
  769. package/dist/field/features/debug/testrecorder/plugin/index.js.map +0 -1
  770. package/dist/field/features/debug/treeview/feature.client.d.ts.map +0 -1
  771. package/dist/field/features/debug/treeview/plugin/index.d.ts +0 -4
  772. package/dist/field/features/debug/treeview/plugin/index.d.ts.map +0 -1
  773. package/dist/field/features/debug/treeview/plugin/index.js.map +0 -1
  774. package/dist/field/features/format/common/floatingSelectToolbarSection.d.ts +0 -3
  775. package/dist/field/features/format/common/floatingSelectToolbarSection.d.ts.map +0 -1
  776. package/dist/field/features/format/common/floatingSelectToolbarSection.js +0 -10
  777. package/dist/field/features/format/common/floatingSelectToolbarSection.js.map +0 -1
  778. package/dist/field/features/format/inlinecode/feature.client.d.ts.map +0 -1
  779. package/dist/field/features/format/inlinecode/feature.client.js +0 -43
  780. package/dist/field/features/format/inlinecode/feature.client.js.map +0 -1
  781. package/dist/field/features/indent/floatingSelectToolbarIndentSection.d.ts +0 -3
  782. package/dist/field/features/indent/floatingSelectToolbarIndentSection.d.ts.map +0 -1
  783. package/dist/field/features/indent/floatingSelectToolbarIndentSection.js +0 -10
  784. package/dist/field/features/indent/floatingSelectToolbarIndentSection.js.map +0 -1
  785. package/dist/field/features/indent/index.scss +0 -4
  786. package/dist/field/features/lists/common/markdown.js.map +0 -1
  787. package/dist/field/features/lists/orderedlist/feature.client.d.ts.map +0 -1
  788. package/dist/field/features/lists/orderedlist/feature.client.js +0 -72
  789. package/dist/field/features/lists/orderedlist/feature.client.js.map +0 -1
  790. package/dist/field/features/lists/orderedlist/feature.server.d.ts.map +0 -1
  791. package/dist/field/features/lists/orderedlist/feature.server.js.map +0 -1
  792. package/dist/field/features/lists/orderedlist/markdownTransformer.d.ts.map +0 -1
  793. package/dist/field/features/lists/orderedlist/markdownTransformer.js.map +0 -1
  794. package/dist/field/features/lists/unorderedlist/feature.client.d.ts.map +0 -1
  795. package/dist/field/features/lists/unorderedlist/feature.client.js +0 -72
  796. package/dist/field/features/lists/unorderedlist/feature.client.js.map +0 -1
  797. package/dist/field/features/lists/unorderedlist/feature.server.d.ts.map +0 -1
  798. package/dist/field/features/lists/unorderedlist/feature.server.js.map +0 -1
  799. package/dist/field/features/lists/unorderedlist/markdownTransformer.d.ts.map +0 -1
  800. package/dist/field/features/lists/unorderedlist/markdownTransformer.js.map +0 -1
  801. package/dist/field/lexical/plugins/FloatingSelectToolbar/ToolbarButton/index.d.ts +0 -8
  802. package/dist/field/lexical/plugins/FloatingSelectToolbar/ToolbarButton/index.d.ts.map +0 -1
  803. package/dist/field/lexical/plugins/FloatingSelectToolbar/ToolbarButton/index.js.map +0 -1
  804. package/dist/field/lexical/plugins/FloatingSelectToolbar/ToolbarDropdown/DropDown.d.ts +0 -17
  805. package/dist/field/lexical/plugins/FloatingSelectToolbar/ToolbarDropdown/DropDown.d.ts.map +0 -1
  806. package/dist/field/lexical/plugins/FloatingSelectToolbar/ToolbarDropdown/DropDown.js.map +0 -1
  807. package/dist/field/lexical/plugins/FloatingSelectToolbar/ToolbarDropdown/index.d.ts +0 -18
  808. package/dist/field/lexical/plugins/FloatingSelectToolbar/ToolbarDropdown/index.d.ts.map +0 -1
  809. package/dist/field/lexical/plugins/FloatingSelectToolbar/ToolbarDropdown/index.js +0 -42
  810. package/dist/field/lexical/plugins/FloatingSelectToolbar/ToolbarDropdown/index.js.map +0 -1
  811. package/dist/field/lexical/plugins/FloatingSelectToolbar/index.d.ts +0 -6
  812. package/dist/field/lexical/plugins/FloatingSelectToolbar/index.d.ts.map +0 -1
  813. package/dist/field/lexical/plugins/FloatingSelectToolbar/index.js +0 -270
  814. package/dist/field/lexical/plugins/FloatingSelectToolbar/index.js.map +0 -1
  815. package/dist/field/lexical/plugins/FloatingSelectToolbar/types.d.ts +0 -40
  816. package/dist/field/lexical/plugins/FloatingSelectToolbar/types.d.ts.map +0 -1
  817. package/dist/field/lexical/plugins/FloatingSelectToolbar/types.js.map +0 -1
  818. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/getNodeCloseToPoint.d.ts.map +0 -1
  819. package/dist/field/lexical/plugins/handles/DraggableBlockPlugin/getNodeCloseToPoint.js.map +0 -1
  820. package/dist/populate/richTextRelationshipPromise.d.ts +0 -23
  821. package/dist/populate/richTextRelationshipPromise.d.ts.map +0 -1
  822. package/dist/populate/richTextRelationshipPromise.js +0 -68
  823. package/dist/populate/richTextRelationshipPromise.js.map +0 -1
  824. package/dist/scss/fonts.scss +0 -75
  825. package/src/index.ts +0 -423
  826. /package/dist/field/features/debug/{testrecorder → testRecorder}/feature.client.js +0 -0
  827. /package/dist/field/features/debug/{testrecorder → testRecorder}/feature.server.d.ts +0 -0
  828. /package/dist/field/features/debug/{testrecorder → testRecorder}/plugin/index.scss +0 -0
  829. /package/dist/field/features/debug/{treeview → treeView}/feature.client.js +0 -0
  830. /package/dist/field/features/debug/{treeview → treeView}/feature.server.d.ts +0 -0
  831. /package/dist/field/features/debug/{treeview → treeView}/plugin/index.scss +0 -0
  832. /package/dist/field/features/format/{inlinecode → inlineCode}/feature.server.d.ts +0 -0
  833. /package/dist/field/features/format/{inlinecode → inlineCode}/markdownTransformers.d.ts +0 -0
  834. /package/dist/field/features/format/{inlinecode → inlineCode}/markdownTransformers.js +0 -0
  835. /package/dist/field/features/lists/{orderedlist → orderedList}/feature.server.d.ts +0 -0
  836. /package/dist/field/features/lists/{orderedlist → orderedList}/markdownTransformer.d.ts +0 -0
  837. /package/dist/field/features/lists/{common → shared}/markdown.d.ts +0 -0
  838. /package/dist/field/features/lists/{unorderedlist → unorderedList}/feature.server.d.ts +0 -0
  839. /package/dist/field/features/lists/{unorderedlist → unorderedList}/markdownTransformer.d.ts +0 -0
  840. /package/dist/field/{lexical/plugins/FloatingSelectToolbar → features/toolbars}/types.js +0 -0
@@ -1,270 +0,0 @@
1
- 'use client';
2
- import lexicalComposerContextImport from '@lexical/react/LexicalComposerContext.js';
3
- const { useLexicalComposerContext } = lexicalComposerContextImport;
4
- import lexicalUtilsImport from '@lexical/utils';
5
- const { mergeRegister } = lexicalUtilsImport;
6
- import lexicalImport from 'lexical';
7
- const { $getSelection, $isRangeSelection, $isTextNode, COMMAND_PRIORITY_LOW, SELECTION_CHANGE_COMMAND } = lexicalImport;
8
- import { useCallback, useEffect, useRef, useState } from 'react';
9
- import * as React from 'react';
10
- import { createPortal } from 'react-dom';
11
- import { useEditorConfigContext } from '../../config/client/EditorConfigProvider.js';
12
- import { getDOMRangeRect } from '../../utils/getDOMRangeRect.js';
13
- import { setFloatingElemPosition } from '../../utils/setFloatingElemPosition.js';
14
- import { ToolbarButton } from './ToolbarButton/index.js';
15
- import { ToolbarDropdown } from './ToolbarDropdown/index.js';
16
- import './index.scss';
17
- function ButtonSectionEntry({ anchorElem, editor, entry }) {
18
- if (entry.Component) {
19
- return entry?.Component && /*#__PURE__*/ React.createElement(entry.Component, {
20
- anchorElem: anchorElem,
21
- editor: editor,
22
- entry: entry,
23
- key: entry.key
24
- });
25
- }
26
- return /*#__PURE__*/ React.createElement(ToolbarButton, {
27
- entry: entry,
28
- key: entry.key
29
- }, entry?.ChildComponent && /*#__PURE__*/ React.createElement(entry.ChildComponent, null));
30
- }
31
- function ToolbarSection({ anchorElem, editor, index, section }) {
32
- const { editorConfig } = useEditorConfigContext();
33
- const Icon = section?.type === 'dropdown' && section.entries.length && section.ChildComponent ? section.ChildComponent : null;
34
- return /*#__PURE__*/ React.createElement("div", {
35
- className: `floating-select-toolbar-popup__section floating-select-toolbar-popup__section-${section.key}`,
36
- key: section.key
37
- }, section.type === 'dropdown' && section.entries.length && (Icon ? /*#__PURE__*/ React.createElement(ToolbarDropdown, {
38
- Icon: Icon,
39
- anchorElem: anchorElem,
40
- editor: editor,
41
- entries: section.entries,
42
- sectionKey: section.key
43
- }) : /*#__PURE__*/ React.createElement(ToolbarDropdown, {
44
- anchorElem: anchorElem,
45
- editor: editor,
46
- entries: section.entries,
47
- sectionKey: section.key
48
- })), section.type === 'buttons' && section.entries.length && section.entries.map((entry)=>{
49
- return /*#__PURE__*/ React.createElement(ButtonSectionEntry, {
50
- anchorElem: anchorElem,
51
- editor: editor,
52
- entry: entry,
53
- key: entry.key
54
- });
55
- }), index < editorConfig.features.floatingSelectToolbar?.sections.length - 1 && /*#__PURE__*/ React.createElement("div", {
56
- className: "divider"
57
- }));
58
- }
59
- function FloatingSelectToolbar({ anchorElem, editor }) {
60
- const popupCharStylesEditorRef = useRef(null);
61
- const caretRef = useRef(null);
62
- const { editorConfig } = useEditorConfigContext();
63
- const closeFloatingToolbar = useCallback(()=>{
64
- if (popupCharStylesEditorRef?.current) {
65
- const isOpacityZero = popupCharStylesEditorRef.current.style.opacity === '0';
66
- const isPointerEventsNone = popupCharStylesEditorRef.current.style.pointerEvents === 'none';
67
- if (!isOpacityZero) {
68
- popupCharStylesEditorRef.current.style.opacity = '0';
69
- }
70
- if (!isPointerEventsNone) {
71
- popupCharStylesEditorRef.current.style.pointerEvents = 'none';
72
- }
73
- }
74
- }, [
75
- popupCharStylesEditorRef
76
- ]);
77
- const mouseMoveListener = useCallback((e)=>{
78
- if (popupCharStylesEditorRef?.current && (e.buttons === 1 || e.buttons === 3)) {
79
- const isOpacityZero = popupCharStylesEditorRef.current.style.opacity === '0';
80
- const isPointerEventsNone = popupCharStylesEditorRef.current.style.pointerEvents === 'none';
81
- if (!isOpacityZero || !isPointerEventsNone) {
82
- // Check if the mouse is not over the popup
83
- const x = e.clientX;
84
- const y = e.clientY;
85
- const elementUnderMouse = document.elementFromPoint(x, y);
86
- if (!popupCharStylesEditorRef.current.contains(elementUnderMouse)) {
87
- // Mouse is not over the target element => not a normal click, but probably a drag
88
- closeFloatingToolbar();
89
- }
90
- }
91
- }
92
- }, [
93
- closeFloatingToolbar
94
- ]);
95
- const mouseUpListener = useCallback(()=>{
96
- if (popupCharStylesEditorRef?.current) {
97
- if (popupCharStylesEditorRef.current.style.opacity !== '1') {
98
- popupCharStylesEditorRef.current.style.opacity = '1';
99
- }
100
- if (popupCharStylesEditorRef.current.style.pointerEvents !== 'auto') {
101
- popupCharStylesEditorRef.current.style.pointerEvents = 'auto';
102
- }
103
- }
104
- }, [
105
- popupCharStylesEditorRef
106
- ]);
107
- useEffect(()=>{
108
- document.addEventListener('mousemove', mouseMoveListener);
109
- document.addEventListener('mouseup', mouseUpListener);
110
- return ()=>{
111
- document.removeEventListener('mousemove', mouseMoveListener);
112
- document.removeEventListener('mouseup', mouseUpListener);
113
- };
114
- }, [
115
- popupCharStylesEditorRef,
116
- mouseMoveListener,
117
- mouseUpListener
118
- ]);
119
- const updateTextFormatFloatingToolbar = useCallback(()=>{
120
- const selection = $getSelection();
121
- const popupCharStylesEditorElem = popupCharStylesEditorRef.current;
122
- const nativeSelection = window.getSelection();
123
- if (popupCharStylesEditorElem === null) {
124
- return;
125
- }
126
- const rootElement = editor.getRootElement();
127
- if (selection !== null && nativeSelection !== null && !nativeSelection.isCollapsed && rootElement !== null && rootElement.contains(nativeSelection.anchorNode)) {
128
- const rangeRect = getDOMRangeRect(nativeSelection, rootElement);
129
- setFloatingElemPosition(rangeRect, popupCharStylesEditorElem, anchorElem, 'center');
130
- if (caretRef.current) {
131
- setFloatingElemPosition(rangeRect, caretRef.current, popupCharStylesEditorElem, 'center', 10, 5, true);
132
- }
133
- }
134
- }, [
135
- editor,
136
- anchorElem
137
- ]);
138
- useEffect(()=>{
139
- const scrollerElem = anchorElem.parentElement;
140
- const update = ()=>{
141
- editor.getEditorState().read(()=>{
142
- updateTextFormatFloatingToolbar();
143
- });
144
- };
145
- window.addEventListener('resize', update);
146
- if (scrollerElem) {
147
- scrollerElem.addEventListener('scroll', update);
148
- }
149
- return ()=>{
150
- window.removeEventListener('resize', update);
151
- if (scrollerElem) {
152
- scrollerElem.removeEventListener('scroll', update);
153
- }
154
- };
155
- }, [
156
- editor,
157
- updateTextFormatFloatingToolbar,
158
- anchorElem
159
- ]);
160
- useEffect(()=>{
161
- editor.getEditorState().read(()=>{
162
- updateTextFormatFloatingToolbar();
163
- });
164
- return mergeRegister(editor.registerUpdateListener(({ editorState })=>{
165
- editorState.read(()=>{
166
- updateTextFormatFloatingToolbar();
167
- });
168
- }), editor.registerCommand(SELECTION_CHANGE_COMMAND, ()=>{
169
- updateTextFormatFloatingToolbar();
170
- return false;
171
- }, COMMAND_PRIORITY_LOW));
172
- }, [
173
- editor,
174
- updateTextFormatFloatingToolbar
175
- ]);
176
- return /*#__PURE__*/ React.createElement("div", {
177
- className: "floating-select-toolbar-popup",
178
- ref: popupCharStylesEditorRef
179
- }, /*#__PURE__*/ React.createElement("div", {
180
- className: "caret",
181
- ref: caretRef
182
- }), editor.isEditable() && /*#__PURE__*/ React.createElement(React.Fragment, null, editorConfig?.features && editorConfig.features?.floatingSelectToolbar?.sections.map((section, i)=>{
183
- return /*#__PURE__*/ React.createElement(ToolbarSection, {
184
- anchorElem: anchorElem,
185
- editor: editor,
186
- index: i,
187
- key: section.key,
188
- section: section
189
- });
190
- })));
191
- }
192
- function useFloatingTextFormatToolbar(editor, anchorElem) {
193
- const [isText, setIsText] = useState(false);
194
- const updatePopup = useCallback(()=>{
195
- editor.getEditorState().read(()=>{
196
- // Should not to pop up the floating toolbar when using IME input
197
- if (editor.isComposing()) {
198
- return;
199
- }
200
- const selection = $getSelection();
201
- const nativeSelection = window.getSelection();
202
- const rootElement = editor.getRootElement();
203
- if (nativeSelection !== null && (!$isRangeSelection(selection) || rootElement === null || !rootElement.contains(nativeSelection.anchorNode))) {
204
- setIsText(false);
205
- return;
206
- }
207
- if (!$isRangeSelection(selection)) {
208
- return;
209
- }
210
- if (selection.getTextContent() !== '') {
211
- const nodes = selection.getNodes();
212
- let foundNodeWithText = false;
213
- for (const node of nodes){
214
- if ($isTextNode(node)) {
215
- setIsText(true);
216
- foundNodeWithText = true;
217
- break;
218
- }
219
- }
220
- if (!foundNodeWithText) {
221
- setIsText(false);
222
- }
223
- } else {
224
- setIsText(false);
225
- }
226
- const rawTextContent = selection.getTextContent().replace(/\n/g, '');
227
- if (!selection.isCollapsed() && rawTextContent === '') {
228
- setIsText(false);
229
- return;
230
- }
231
- });
232
- }, [
233
- editor
234
- ]);
235
- useEffect(()=>{
236
- document.addEventListener('selectionchange', updatePopup);
237
- document.addEventListener('mouseup', updatePopup);
238
- return ()=>{
239
- document.removeEventListener('selectionchange', updatePopup);
240
- document.removeEventListener('mouseup', updatePopup);
241
- };
242
- }, [
243
- updatePopup
244
- ]);
245
- useEffect(()=>{
246
- return mergeRegister(editor.registerUpdateListener(()=>{
247
- updatePopup();
248
- }), editor.registerRootListener(()=>{
249
- if (editor.getRootElement() === null) {
250
- setIsText(false);
251
- }
252
- }));
253
- }, [
254
- editor,
255
- updatePopup
256
- ]);
257
- if (!isText) {
258
- return null;
259
- }
260
- return /*#__PURE__*/ createPortal(/*#__PURE__*/ React.createElement(FloatingSelectToolbar, {
261
- anchorElem: anchorElem,
262
- editor: editor
263
- }), anchorElem);
264
- }
265
- export function FloatingSelectToolbarPlugin({ anchorElem = document.body }) {
266
- const [editor] = useLexicalComposerContext();
267
- return useFloatingTextFormatToolbar(editor, anchorElem);
268
- }
269
-
270
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../../../src/field/lexical/plugins/FloatingSelectToolbar/index.tsx"],"sourcesContent":["'use client'\nimport type { LexicalEditor } from 'lexical'\n\nimport lexicalComposerContextImport from '@lexical/react/LexicalComposerContext.js'\nconst { useLexicalComposerContext } = lexicalComposerContextImport\n\nimport lexicalUtilsImport from '@lexical/utils'\nconst { mergeRegister } = lexicalUtilsImport\n\nimport lexicalImport from 'lexical'\nconst {\n $getSelection,\n $isRangeSelection,\n $isTextNode,\n COMMAND_PRIORITY_LOW,\n SELECTION_CHANGE_COMMAND,\n} = lexicalImport\n\nimport { useCallback, useEffect, useRef, useState } from 'react'\nimport * as React from 'react'\nimport { createPortal } from 'react-dom'\n\nimport type { FloatingToolbarSection, FloatingToolbarSectionEntry } from './types.js'\n\nimport { useEditorConfigContext } from '../../config/client/EditorConfigProvider.js'\nimport { getDOMRangeRect } from '../../utils/getDOMRangeRect.js'\nimport { setFloatingElemPosition } from '../../utils/setFloatingElemPosition.js'\nimport { ToolbarButton } from './ToolbarButton/index.js'\nimport { ToolbarDropdown } from './ToolbarDropdown/index.js'\nimport './index.scss'\n\nfunction ButtonSectionEntry({\n anchorElem,\n editor,\n entry,\n}: {\n anchorElem: HTMLElement\n editor: LexicalEditor\n entry: FloatingToolbarSectionEntry\n}): React.ReactNode {\n if (entry.Component) {\n return (\n entry?.Component && (\n <entry.Component anchorElem={anchorElem} editor={editor} entry={entry} key={entry.key} />\n )\n )\n }\n\n return (\n <ToolbarButton entry={entry} key={entry.key}>\n {entry?.ChildComponent && <entry.ChildComponent />}\n </ToolbarButton>\n )\n}\n\nfunction ToolbarSection({\n anchorElem,\n editor,\n index,\n section,\n}: {\n anchorElem: HTMLElement\n editor: LexicalEditor\n index: number\n section: FloatingToolbarSection\n}): React.ReactNode {\n const { editorConfig } = useEditorConfigContext()\n\n const Icon =\n section?.type === 'dropdown' && section.entries.length && section.ChildComponent\n ? section.ChildComponent\n : null\n\n return (\n <div\n className={`floating-select-toolbar-popup__section floating-select-toolbar-popup__section-${section.key}`}\n key={section.key}\n >\n {section.type === 'dropdown' &&\n section.entries.length &&\n (Icon ? (\n <ToolbarDropdown\n Icon={Icon}\n anchorElem={anchorElem}\n editor={editor}\n entries={section.entries}\n sectionKey={section.key}\n />\n ) : (\n <ToolbarDropdown\n anchorElem={anchorElem}\n editor={editor}\n entries={section.entries}\n sectionKey={section.key}\n />\n ))}\n {section.type === 'buttons' &&\n section.entries.length &&\n section.entries.map((entry) => {\n return (\n <ButtonSectionEntry\n anchorElem={anchorElem}\n editor={editor}\n entry={entry}\n key={entry.key}\n />\n )\n })}\n {index < editorConfig.features.floatingSelectToolbar?.sections.length - 1 && (\n <div className=\"divider\" />\n )}\n </div>\n )\n}\n\nfunction FloatingSelectToolbar({\n anchorElem,\n editor,\n}: {\n anchorElem: HTMLElement\n editor: LexicalEditor\n}): React.ReactNode {\n const popupCharStylesEditorRef = useRef<HTMLDivElement | null>(null)\n const caretRef = useRef<HTMLDivElement | null>(null)\n\n const { editorConfig } = useEditorConfigContext()\n\n const closeFloatingToolbar = useCallback(() => {\n if (popupCharStylesEditorRef?.current) {\n const isOpacityZero = popupCharStylesEditorRef.current.style.opacity === '0'\n const isPointerEventsNone = popupCharStylesEditorRef.current.style.pointerEvents === 'none'\n\n if (!isOpacityZero) {\n popupCharStylesEditorRef.current.style.opacity = '0'\n }\n if (!isPointerEventsNone) {\n popupCharStylesEditorRef.current.style.pointerEvents = 'none'\n }\n }\n }, [popupCharStylesEditorRef])\n\n const mouseMoveListener = useCallback(\n (e: MouseEvent) => {\n if (popupCharStylesEditorRef?.current && (e.buttons === 1 || e.buttons === 3)) {\n const isOpacityZero = popupCharStylesEditorRef.current.style.opacity === '0'\n const isPointerEventsNone = popupCharStylesEditorRef.current.style.pointerEvents === 'none'\n if (!isOpacityZero || !isPointerEventsNone) {\n // Check if the mouse is not over the popup\n const x = e.clientX\n const y = e.clientY\n const elementUnderMouse = document.elementFromPoint(x, y)\n if (!popupCharStylesEditorRef.current.contains(elementUnderMouse)) {\n // Mouse is not over the target element => not a normal click, but probably a drag\n closeFloatingToolbar()\n }\n }\n }\n },\n [closeFloatingToolbar],\n )\n\n const mouseUpListener = useCallback(() => {\n if (popupCharStylesEditorRef?.current) {\n if (popupCharStylesEditorRef.current.style.opacity !== '1') {\n popupCharStylesEditorRef.current.style.opacity = '1'\n }\n if (popupCharStylesEditorRef.current.style.pointerEvents !== 'auto') {\n popupCharStylesEditorRef.current.style.pointerEvents = 'auto'\n }\n }\n }, [popupCharStylesEditorRef])\n\n useEffect(() => {\n document.addEventListener('mousemove', mouseMoveListener)\n document.addEventListener('mouseup', mouseUpListener)\n\n return () => {\n document.removeEventListener('mousemove', mouseMoveListener)\n document.removeEventListener('mouseup', mouseUpListener)\n }\n }, [popupCharStylesEditorRef, mouseMoveListener, mouseUpListener])\n\n const updateTextFormatFloatingToolbar = useCallback(() => {\n const selection = $getSelection()\n\n const popupCharStylesEditorElem = popupCharStylesEditorRef.current\n const nativeSelection = window.getSelection()\n\n if (popupCharStylesEditorElem === null) {\n return\n }\n\n const rootElement = editor.getRootElement()\n if (\n selection !== null &&\n nativeSelection !== null &&\n !nativeSelection.isCollapsed &&\n rootElement !== null &&\n rootElement.contains(nativeSelection.anchorNode)\n ) {\n const rangeRect = getDOMRangeRect(nativeSelection, rootElement)\n\n setFloatingElemPosition(rangeRect, popupCharStylesEditorElem, anchorElem, 'center')\n\n if (caretRef.current) {\n setFloatingElemPosition(\n rangeRect, // selection to position around\n caretRef.current, // what to position\n popupCharStylesEditorElem, // anchor elem\n 'center',\n 10,\n 5,\n true,\n )\n }\n }\n }, [editor, anchorElem])\n\n useEffect(() => {\n const scrollerElem = anchorElem.parentElement\n\n const update = () => {\n editor.getEditorState().read(() => {\n updateTextFormatFloatingToolbar()\n })\n }\n\n window.addEventListener('resize', update)\n if (scrollerElem) {\n scrollerElem.addEventListener('scroll', update)\n }\n\n return () => {\n window.removeEventListener('resize', update)\n if (scrollerElem) {\n scrollerElem.removeEventListener('scroll', update)\n }\n }\n }, [editor, updateTextFormatFloatingToolbar, anchorElem])\n\n useEffect(() => {\n editor.getEditorState().read(() => {\n updateTextFormatFloatingToolbar()\n })\n return mergeRegister(\n editor.registerUpdateListener(({ editorState }) => {\n editorState.read(() => {\n updateTextFormatFloatingToolbar()\n })\n }),\n\n editor.registerCommand(\n SELECTION_CHANGE_COMMAND,\n () => {\n updateTextFormatFloatingToolbar()\n return false\n },\n COMMAND_PRIORITY_LOW,\n ),\n )\n }, [editor, updateTextFormatFloatingToolbar])\n\n return (\n <div className=\"floating-select-toolbar-popup\" ref={popupCharStylesEditorRef}>\n <div className=\"caret\" ref={caretRef} />\n {editor.isEditable() && (\n <React.Fragment>\n {editorConfig?.features &&\n editorConfig.features?.floatingSelectToolbar?.sections.map((section, i) => {\n return (\n <ToolbarSection\n anchorElem={anchorElem}\n editor={editor}\n index={i}\n key={section.key}\n section={section}\n />\n )\n })}\n </React.Fragment>\n )}\n </div>\n )\n}\n\nfunction useFloatingTextFormatToolbar(\n editor: LexicalEditor,\n anchorElem: HTMLElement,\n): JSX.Element | null {\n const [isText, setIsText] = useState(false)\n\n const updatePopup = useCallback(() => {\n editor.getEditorState().read(() => {\n // Should not to pop up the floating toolbar when using IME input\n if (editor.isComposing()) {\n return\n }\n const selection = $getSelection()\n const nativeSelection = window.getSelection()\n const rootElement = editor.getRootElement()\n\n if (\n nativeSelection !== null &&\n (!$isRangeSelection(selection) ||\n rootElement === null ||\n !rootElement.contains(nativeSelection.anchorNode))\n ) {\n setIsText(false)\n return\n }\n\n if (!$isRangeSelection(selection)) {\n return\n }\n\n if (selection.getTextContent() !== '') {\n const nodes = selection.getNodes()\n let foundNodeWithText = false\n for (const node of nodes) {\n if ($isTextNode(node)) {\n setIsText(true)\n foundNodeWithText = true\n break\n }\n }\n if (!foundNodeWithText) {\n setIsText(false)\n }\n } else {\n setIsText(false)\n }\n\n const rawTextContent = selection.getTextContent().replace(/\\n/g, '')\n if (!selection.isCollapsed() && rawTextContent === '') {\n setIsText(false)\n return\n }\n })\n }, [editor])\n\n useEffect(() => {\n document.addEventListener('selectionchange', updatePopup)\n document.addEventListener('mouseup', updatePopup)\n return () => {\n document.removeEventListener('selectionchange', updatePopup)\n document.removeEventListener('mouseup', updatePopup)\n }\n }, [updatePopup])\n\n useEffect(() => {\n return mergeRegister(\n editor.registerUpdateListener(() => {\n updatePopup()\n }),\n editor.registerRootListener(() => {\n if (editor.getRootElement() === null) {\n setIsText(false)\n }\n }),\n )\n }, [editor, updatePopup])\n\n if (!isText) {\n return null\n }\n\n return createPortal(<FloatingSelectToolbar anchorElem={anchorElem} editor={editor} />, anchorElem)\n}\n\nexport function FloatingSelectToolbarPlugin({\n anchorElem = document.body,\n}: {\n anchorElem?: HTMLElement\n}): JSX.Element | null {\n const [editor] = useLexicalComposerContext()\n return useFloatingTextFormatToolbar(editor, anchorElem)\n}\n"],"names":["lexicalComposerContextImport","useLexicalComposerContext","lexicalUtilsImport","mergeRegister","lexicalImport","$getSelection","$isRangeSelection","$isTextNode","COMMAND_PRIORITY_LOW","SELECTION_CHANGE_COMMAND","useCallback","useEffect","useRef","useState","React","createPortal","useEditorConfigContext","getDOMRangeRect","setFloatingElemPosition","ToolbarButton","ToolbarDropdown","ButtonSectionEntry","anchorElem","editor","entry","Component","key","ChildComponent","ToolbarSection","index","section","editorConfig","Icon","type","entries","length","div","className","sectionKey","map","features","floatingSelectToolbar","sections","FloatingSelectToolbar","popupCharStylesEditorRef","caretRef","closeFloatingToolbar","current","isOpacityZero","style","opacity","isPointerEventsNone","pointerEvents","mouseMoveListener","e","buttons","x","clientX","y","clientY","elementUnderMouse","document","elementFromPoint","contains","mouseUpListener","addEventListener","removeEventListener","updateTextFormatFloatingToolbar","selection","popupCharStylesEditorElem","nativeSelection","window","getSelection","rootElement","getRootElement","isCollapsed","anchorNode","rangeRect","scrollerElem","parentElement","update","getEditorState","read","registerUpdateListener","editorState","registerCommand","ref","isEditable","Fragment","i","useFloatingTextFormatToolbar","isText","setIsText","updatePopup","isComposing","getTextContent","nodes","getNodes","foundNodeWithText","node","rawTextContent","replace","registerRootListener","FloatingSelectToolbarPlugin","body"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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,GAAGM,OAAO,CAAC,OAAO;YACjE,IAAI,CAACjC,UAAUO,WAAW,MAAMyB,mBAAmB,IAAI;gBACrDR,UAAU;gBACV;YACF;QACF;IACF,GAAG;QAACrE;KAAO;IAEXZ,UAAU;QACRkD,SAASI,gBAAgB,CAAC,mBAAmB4B;QAC7ChC,SAASI,gBAAgB,CAAC,WAAW4B;QACrC,OAAO;YACLhC,SAASK,mBAAmB,CAAC,mBAAmB2B;YAChDhC,SAASK,mBAAmB,CAAC,WAAW2B;QAC1C;IACF,GAAG;QAACA;KAAY;IAEhBlF,UAAU;QACR,OAAOR,cACLoB,OAAO4D,sBAAsB,CAAC;YAC5BU;QACF,IACAtE,OAAO+E,oBAAoB,CAAC;YAC1B,IAAI/E,OAAOmD,cAAc,OAAO,MAAM;gBACpCkB,UAAU;YACZ;QACF;IAEJ,GAAG;QAACrE;QAAQsE;KAAY;IAExB,IAAI,CAACF,QAAQ;QACX,OAAO;IACT;IAEA,qBAAO5E,2BAAa,oBAAC4B;QAAsBrB,YAAYA;QAAYC,QAAQA;QAAYD;AACzF;AAEA,OAAO,SAASiF,4BAA4B,EAC1CjF,aAAauC,SAAS2C,IAAI,EAG3B;IACC,MAAM,CAACjF,OAAO,GAAGtB;IACjB,OAAOyF,6BAA6BnE,QAAQD;AAC9C"}
@@ -1,40 +0,0 @@
1
- import type { BaseSelection, LexicalEditor } from 'lexical';
2
- import type React from 'react';
3
- export type FloatingToolbarSection = {
4
- ChildComponent?: React.FC;
5
- entries: Array<FloatingToolbarSectionEntry>;
6
- key: string;
7
- order?: number;
8
- type: 'dropdown';
9
- } | {
10
- entries: Array<FloatingToolbarSectionEntry>;
11
- key: string;
12
- order?: number;
13
- type: 'buttons';
14
- };
15
- export type FloatingToolbarSectionEntry = {
16
- ChildComponent?: React.FC;
17
- /** Use component to ignore the children and onClick properties. It does not use the default, pre-defined format Button component */
18
- Component?: React.FC<{
19
- anchorElem: HTMLElement;
20
- editor: LexicalEditor;
21
- entry: FloatingToolbarSectionEntry;
22
- }>;
23
- isActive?: ({ editor, selection }: {
24
- editor: LexicalEditor;
25
- selection: BaseSelection;
26
- }) => boolean;
27
- isEnabled?: ({ editor, selection, }: {
28
- editor: LexicalEditor;
29
- selection: BaseSelection;
30
- }) => boolean;
31
- key: string;
32
- /** The label is displayed as text if the entry is part of a dropdown section */
33
- label?: string;
34
- onClick?: ({ editor, isActive }: {
35
- editor: LexicalEditor;
36
- isActive: boolean;
37
- }) => void;
38
- order?: number;
39
- };
40
- //# sourceMappingURL=types.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../src/field/lexical/plugins/FloatingSelectToolbar/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,SAAS,CAAA;AAC3D,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAE9B,MAAM,MAAM,sBAAsB,GAC9B;IACE,cAAc,CAAC,EAAE,KAAK,CAAC,EAAE,CAAA;IACzB,OAAO,EAAE,KAAK,CAAC,2BAA2B,CAAC,CAAA;IAC3C,GAAG,EAAE,MAAM,CAAA;IACX,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,IAAI,EAAE,UAAU,CAAA;CACjB,GACD;IACE,OAAO,EAAE,KAAK,CAAC,2BAA2B,CAAC,CAAA;IAC3C,GAAG,EAAE,MAAM,CAAA;IACX,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,IAAI,EAAE,SAAS,CAAA;CAChB,CAAA;AAEL,MAAM,MAAM,2BAA2B,GAAG;IACxC,cAAc,CAAC,EAAE,KAAK,CAAC,EAAE,CAAA;IACzB,oIAAoI;IACpI,SAAS,CAAC,EAAE,KAAK,CAAC,EAAE,CAAC;QACnB,UAAU,EAAE,WAAW,CAAA;QACvB,MAAM,EAAE,aAAa,CAAA;QACrB,KAAK,EAAE,2BAA2B,CAAA;KACnC,CAAC,CAAA;IACF,QAAQ,CAAC,EAAE,CAAC,EAAE,MAAM,EAAE,SAAS,EAAE,EAAE;QAAE,MAAM,EAAE,aAAa,CAAC;QAAC,SAAS,EAAE,aAAa,CAAA;KAAE,KAAK,OAAO,CAAA;IAClG,SAAS,CAAC,EAAE,CAAC,EACX,MAAM,EACN,SAAS,GACV,EAAE;QACD,MAAM,EAAE,aAAa,CAAA;QACrB,SAAS,EAAE,aAAa,CAAA;KACzB,KAAK,OAAO,CAAA;IACb,GAAG,EAAE,MAAM,CAAA;IACX,gFAAgF;IAChF,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,EAAE;QAAE,MAAM,EAAE,aAAa,CAAC;QAAC,QAAQ,EAAE,OAAO,CAAA;KAAE,KAAK,IAAI,CAAA;IACtF,KAAK,CAAC,EAAE,MAAM,CAAA;CACf,CAAA"}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../../../src/field/lexical/plugins/FloatingSelectToolbar/types.ts"],"sourcesContent":["import type { BaseSelection, LexicalEditor } from 'lexical'\nimport type React from 'react'\n\nexport type FloatingToolbarSection =\n | {\n ChildComponent?: React.FC\n entries: Array<FloatingToolbarSectionEntry>\n key: string\n order?: number\n type: 'dropdown'\n }\n | {\n entries: Array<FloatingToolbarSectionEntry>\n key: string\n order?: number\n type: 'buttons'\n }\n\nexport type FloatingToolbarSectionEntry = {\n ChildComponent?: React.FC\n /** Use component to ignore the children and onClick properties. It does not use the default, pre-defined format Button component */\n Component?: React.FC<{\n anchorElem: HTMLElement\n editor: LexicalEditor\n entry: FloatingToolbarSectionEntry\n }>\n isActive?: ({ editor, selection }: { editor: LexicalEditor; selection: BaseSelection }) => boolean\n isEnabled?: ({\n editor,\n selection,\n }: {\n editor: LexicalEditor\n selection: BaseSelection\n }) => boolean\n key: string\n /** The label is displayed as text if the entry is part of a dropdown section */\n label?: string\n onClick?: ({ editor, isActive }: { editor: LexicalEditor; isActive: boolean }) => void\n order?: number\n}\n"],"names":[],"rangeMappings":"","mappings":"AAkBA,WAqBC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"getNodeCloseToPoint.d.ts","sourceRoot":"","sources":["../../../../../../src/field/lexical/plugins/handles/DraggableBlockPlugin/getNodeCloseToPoint.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,SAAS,CAAA;AAKzD,OAAO,EAAE,KAAK,EAAE,MAAM,yBAAyB,CAAA;AAW/C,KAAK,KAAK,GAAG;IACX,UAAU,EAAE,WAAW,CAAA;IACvB,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,MAAM,EAAE,aAAa,CAAA;IACrB,gHAAgH;IAChH,KAAK,CAAC,EAAE,OAAO,CAAA;IACf,gBAAgB,CAAC,EAAE,MAAM,CAAA;IACzB,KAAK,EAAE,KAAK,CAAA;IACZ;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB,CAAA;AAED,KAAK,MAAM,GAAG;IACZ,SAAS,EAAE,WAAW,GAAG,IAAI,CAAA;IAC7B,SAAS,EAAE,WAAW,GAAG,IAAI,CAAA;IAC7B,YAAY,EAAE,MAAM,CAAA;IACpB,yBAAyB,EAAE,OAAO,CAAA;CACnC,CAAA;AAaD,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,KAAK,GAAG,MAAM,CAkLxD"}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../../../../src/field/lexical/plugins/handles/DraggableBlockPlugin/getNodeCloseToPoint.ts"],"sourcesContent":["import type { LexicalEditor, LexicalNode } from 'lexical'\n\nimport lexicalImport from 'lexical'\nconst { $getNodeByKey } = lexicalImport\n\nimport { Point } from '../../../utils/point.js'\nimport { Rect } from '../../../utils/rect.js'\nimport { getCollapsedMargins } from '../utils/getCollapsedMargins.js'\nimport { getTopLevelNodeKeys } from '../utils/getTopLevelNodeKeys.js'\nimport { getBoundingClientRectWithoutTransform } from './getBoundingRectWithoutTransform.js'\n\n// Directions\nconst Downward = 1\nconst Upward = -1\nconst Indeterminate = 0\n\ntype Props = {\n anchorElem: HTMLElement\n cache_treshold?: number\n editor: LexicalEditor\n /** fuzzy makes the search not exact. If no exact match found, find the closes node instead of returning null */\n fuzzy?: boolean\n horizontalOffset?: number\n point: Point\n /**\n * The index to start searching from. It can be a considerable performance optimization to start searching from the index of the\n * previously found node, as the node is likely to be close to the next node.\n */\n startIndex?: number\n useEdgeAsDefault?: boolean\n verbose?: boolean\n}\n\ntype Output = {\n blockElem: HTMLElement | null\n blockNode: LexicalNode | null\n foundAtIndex: number\n isFoundNodeEmptyParagraph: boolean\n}\n\nconst cache = {\n props: null as Props | null,\n result: null as Output | null,\n}\n\nfunction isPointClose(previous: Point, current: Point, threshold: number = 20): boolean {\n const dx = previous.x - current.x\n const dy = previous.y - current.y\n return dx * dx + dy * dy <= threshold * threshold\n}\n\nexport function getNodeCloseToPoint(props: Props): Output {\n const {\n anchorElem,\n cache_treshold = 20,\n editor,\n fuzzy = false,\n horizontalOffset = 0,\n point: { x, y },\n startIndex = 0,\n useEdgeAsDefault = false,\n verbose = false,\n } = props\n\n // Use cache\n if (\n cache_treshold > 0 &&\n cache.props &&\n cache.result &&\n cache.props.fuzzy === props.fuzzy &&\n cache.props.horizontalOffset === props.horizontalOffset &&\n cache.props.useEdgeAsDefault === props.useEdgeAsDefault &&\n isPointClose(cache.props.point, props.point, cache_treshold)\n ) {\n if (verbose) {\n //console.log('Returning cached result')\n }\n return cache.result\n }\n\n const anchorElementRect = anchorElem.getBoundingClientRect()\n const topLevelNodeKeys = getTopLevelNodeKeys(editor)\n\n const closestBlockElem: {\n blockElem: HTMLElement | null\n blockNode: LexicalNode | null\n distance: number\n foundAtIndex: number\n isFoundNodeEmptyParagraph: boolean\n } = {\n blockElem: null,\n blockNode: null,\n distance: Infinity,\n foundAtIndex: -1,\n isFoundNodeEmptyParagraph: false,\n }\n\n // Return null if matching block element is the first or last node\n editor.getEditorState().read(() => {\n if (useEdgeAsDefault) {\n const [firstNode, lastNode] = [\n editor.getElementByKey(topLevelNodeKeys[0]),\n editor.getElementByKey(topLevelNodeKeys[topLevelNodeKeys.length - 1]),\n ]\n\n const [firstNodeRect, lastNodeRect] = [\n getBoundingClientRectWithoutTransform(firstNode),\n getBoundingClientRectWithoutTransform(lastNode),\n ]\n\n if (firstNodeRect && lastNodeRect) {\n if (y < firstNodeRect.top) {\n closestBlockElem.blockElem = firstNode\n closestBlockElem.distance = firstNodeRect.top - y\n closestBlockElem.blockNode = $getNodeByKey(topLevelNodeKeys[0])\n closestBlockElem.foundAtIndex = 0\n } else if (y > lastNodeRect.bottom) {\n closestBlockElem.distance = y - lastNodeRect.bottom\n closestBlockElem.blockNode = $getNodeByKey(topLevelNodeKeys[topLevelNodeKeys.length - 1])\n closestBlockElem.blockElem = lastNode\n closestBlockElem.foundAtIndex = topLevelNodeKeys.length - 1\n }\n\n if (closestBlockElem?.blockElem) {\n if (verbose) {\n //console.log('useEdgeAsDefault', useEdgeAsDefault)\n }\n\n return {\n blockElem: null,\n isFoundNodeEmptyParagraph: false,\n } as Output\n }\n }\n }\n\n // Find matching block element\n let index = startIndex\n let direction = Indeterminate\n\n if (verbose) {\n //console.log('start index', startIndex)\n }\n\n while (index >= 0 && index < topLevelNodeKeys.length) {\n const key = topLevelNodeKeys[index]\n const elem = editor.getElementByKey(key)\n if (elem === null) {\n break\n }\n const point = new Point(x + horizontalOffset, y)\n //const domRect = Rect.fromDOM(elem)\n // Do not consider transform of blocks when calculating distance\n const domRect = Rect.fromDOMRect(getBoundingClientRectWithoutTransform(elem))\n\n const { marginBottom, marginTop } = getCollapsedMargins(elem)\n\n const rect = domRect.generateNewRect({\n bottom: domRect.bottom + marginBottom,\n left: anchorElementRect.left,\n right: anchorElementRect.right,\n top: domRect.top - marginTop,\n })\n\n const { distance, isOnBottomSide, isOnTopSide } = rect.distanceFromPoint(point)\n\n if (verbose) {\n //console.log('distance', distance)\n }\n\n if (distance === 0) {\n closestBlockElem.blockElem = elem\n closestBlockElem.blockNode = $getNodeByKey(key)\n closestBlockElem.foundAtIndex = index\n closestBlockElem.distance = distance\n\n // Check if blockNode is an empty text node\n if (\n closestBlockElem.blockNode &&\n closestBlockElem.blockNode.getType() === 'paragraph' &&\n closestBlockElem.blockNode.getTextContent() === ''\n ) {\n if (!fuzzy) {\n closestBlockElem.blockElem = null\n closestBlockElem.blockNode = null\n }\n\n closestBlockElem.isFoundNodeEmptyParagraph = true\n }\n break\n } else if (fuzzy) {\n if (distance < closestBlockElem.distance) {\n closestBlockElem.blockElem = elem\n closestBlockElem.blockNode = $getNodeByKey(key)\n closestBlockElem.distance = distance\n closestBlockElem.foundAtIndex = index\n }\n }\n\n if (direction === Indeterminate) {\n if (isOnTopSide) {\n direction = Upward\n } else if (isOnBottomSide) {\n direction = Downward\n } else {\n // stop search block element\n direction = Infinity\n }\n }\n\n index += direction\n }\n })\n\n // Store in cache before returning\n cache.props = props\n cache.result = {\n blockElem: closestBlockElem.blockElem,\n blockNode: closestBlockElem.blockNode,\n foundAtIndex: closestBlockElem.foundAtIndex,\n isFoundNodeEmptyParagraph: closestBlockElem.isFoundNodeEmptyParagraph,\n }\n\n return {\n blockElem: closestBlockElem.blockElem,\n blockNode: closestBlockElem.blockNode,\n foundAtIndex: closestBlockElem.foundAtIndex,\n isFoundNodeEmptyParagraph: closestBlockElem.isFoundNodeEmptyParagraph,\n }\n}\n"],"names":["lexicalImport","$getNodeByKey","Point","Rect","getCollapsedMargins","getTopLevelNodeKeys","getBoundingClientRectWithoutTransform","Downward","Upward","Indeterminate","cache","props","result","isPointClose","previous","current","threshold","dx","x","dy","y","getNodeCloseToPoint","anchorElem","cache_treshold","editor","fuzzy","horizontalOffset","point","startIndex","useEdgeAsDefault","verbose","anchorElementRect","getBoundingClientRect","topLevelNodeKeys","closestBlockElem","blockElem","blockNode","distance","Infinity","foundAtIndex","isFoundNodeEmptyParagraph","getEditorState","read","firstNode","lastNode","getElementByKey","length","firstNodeRect","lastNodeRect","top","bottom","index","direction","key","elem","domRect","fromDOMRect","marginBottom","marginTop","rect","generateNewRect","left","right","isOnBottomSide","isOnTopSide","distanceFromPoint","getType","getTextContent"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAEA,OAAOA,mBAAmB,UAAS;AACnC,MAAM,EAAEC,aAAa,EAAE,GAAGD;AAE1B,SAASE,KAAK,QAAQ,0BAAyB;AAC/C,SAASC,IAAI,QAAQ,yBAAwB;AAC7C,SAASC,mBAAmB,QAAQ,kCAAiC;AACrE,SAASC,mBAAmB,QAAQ,kCAAiC;AACrE,SAASC,qCAAqC,QAAQ,uCAAsC;AAE5F,aAAa;AACb,MAAMC,WAAW;AACjB,MAAMC,SAAS,CAAC;AAChB,MAAMC,gBAAgB;AA0BtB,MAAMC,QAAQ;IACZC,OAAO;IACPC,QAAQ;AACV;AAEA,SAASC,aAAaC,QAAe,EAAEC,OAAc,EAAEC,YAAoB,EAAE;IAC3E,MAAMC,KAAKH,SAASI,CAAC,GAAGH,QAAQG,CAAC;IACjC,MAAMC,KAAKL,SAASM,CAAC,GAAGL,QAAQK,CAAC;IACjC,OAAOH,KAAKA,KAAKE,KAAKA,MAAMH,YAAYA;AAC1C;AAEA,OAAO,SAASK,oBAAoBV,KAAY;IAC9C,MAAM,EACJW,UAAU,EACVC,iBAAiB,EAAE,EACnBC,MAAM,EACNC,QAAQ,KAAK,EACbC,mBAAmB,CAAC,EACpBC,OAAO,EAAET,CAAC,EAAEE,CAAC,EAAE,EACfQ,aAAa,CAAC,EACdC,mBAAmB,KAAK,EACxBC,UAAU,KAAK,EAChB,GAAGnB;IAEJ,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GAAGnC,cAAcoD;gBAC3CnB,iBAAiBK,YAAY,GAAGY;gBAChCjB,iBAAiBG,QAAQ,GAAGA;gBAE5B,2CAA2C;gBAC3C,IACEH,iBAAiBE,SAAS,IAC1BF,iBAAiBE,SAAS,CAAC8B,OAAO,OAAO,eACzChC,iBAAiBE,SAAS,CAAC+B,cAAc,OAAO,IAChD;oBACA,IAAI,CAAC1C,OAAO;wBACVS,iBAAiBC,SAAS,GAAG;wBAC7BD,iBAAiBE,SAAS,GAAG;oBAC/B;oBAEAF,iBAAiBM,yBAAyB,GAAG;gBAC/C;gBACA;YACF,OAAO,IAAIf,OAAO;gBAChB,IAAIY,WAAWH,iBAAiBG,QAAQ,EAAE;oBACxCH,iBAAiBC,SAAS,GAAGmB;oBAC7BpB,iBAAiBE,SAAS,GAAGnC,cAAcoD;oBAC3CnB,iBAAiBG,QAAQ,GAAGA;oBAC5BH,iBAAiBK,YAAY,GAAGY;gBAClC;YACF;YAEA,IAAIC,cAAc3C,eAAe;gBAC/B,IAAIuD,aAAa;oBACfZ,YAAY5C;gBACd,OAAO,IAAIuD,gBAAgB;oBACzBX,YAAY7C;gBACd,OAAO;oBACL,4BAA4B;oBAC5B6C,YAAYd;gBACd;YACF;YAEAa,SAASC;QACX;IACF;IAEA,kCAAkC;IAClC1C,MAAMC,KAAK,GAAGA;IACdD,MAAME,MAAM,GAAG;QACbuB,WAAWD,iBAAiBC,SAAS;QACrCC,WAAWF,iBAAiBE,SAAS;QACrCG,cAAcL,iBAAiBK,YAAY;QAC3CC,2BAA2BN,iBAAiBM,yBAAyB;IACvE;IAEA,OAAO;QACLL,WAAWD,iBAAiBC,SAAS;QACrCC,WAAWF,iBAAiBE,SAAS;QACrCG,cAAcL,iBAAiBK,YAAY;QAC3CC,2BAA2BN,iBAAiBM,yBAAyB;IACvE;AACF"}
@@ -1,23 +0,0 @@
1
- import type { SerializedEditorState, SerializedLexicalNode } from 'lexical';
2
- import type { PayloadRequest, RichTextAdapter, RichTextField } from 'payload/types';
3
- import type { PopulationPromise } from '../field/features/types.js';
4
- import type { AdapterProps } from '../types.js';
5
- export type Args = Parameters<RichTextAdapter<SerializedEditorState, AdapterProps>['populationPromise']>[0] & {
6
- editorPopulationPromises: Map<string, Array<PopulationPromise>>;
7
- };
8
- type RecurseRichTextArgs = {
9
- children: SerializedLexicalNode[];
10
- currentDepth: number;
11
- depth: number;
12
- editorPopulationPromises: Map<string, Array<PopulationPromise>>;
13
- field: RichTextField<SerializedEditorState, AdapterProps>;
14
- overrideAccess: boolean;
15
- promises: Promise<void>[];
16
- req: PayloadRequest;
17
- showHiddenFields: boolean;
18
- siblingDoc?: Record<string, unknown>;
19
- };
20
- export declare const recurseRichText: ({ children, context, currentDepth, depth, editorPopulationPromises, field, findMany, flattenLocales, overrideAccess, populationPromises, promises, req, showHiddenFields, siblingDoc, }: RecurseRichTextArgs & Args) => void;
21
- export declare const richTextRelationshipPromise: ({ context, currentDepth, depth, editorPopulationPromises, field, findMany, flattenLocales, overrideAccess, populationPromises, req, showHiddenFields, siblingDoc, }: Args) => Promise<void>;
22
- export {};
23
- //# sourceMappingURL=richTextRelationshipPromise.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"richTextRelationshipPromise.d.ts","sourceRoot":"","sources":["../../src/populate/richTextRelationshipPromise.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAA;AAC3E,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,eAAe,CAAA;AAEnF,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAA;AACnE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAE/C,MAAM,MAAM,IAAI,GAAG,UAAU,CAC3B,eAAe,CAAC,qBAAqB,EAAE,YAAY,CAAC,CAAC,mBAAmB,CAAC,CAC1E,CAAC,CAAC,CAAC,GAAG;IACL,wBAAwB,EAAE,GAAG,CAAC,MAAM,EAAE,KAAK,CAAC,iBAAiB,CAAC,CAAC,CAAA;CAChE,CAAA;AAED,KAAK,mBAAmB,GAAG;IACzB,QAAQ,EAAE,qBAAqB,EAAE,CAAA;IACjC,YAAY,EAAE,MAAM,CAAA;IACpB,KAAK,EAAE,MAAM,CAAA;IACb,wBAAwB,EAAE,GAAG,CAAC,MAAM,EAAE,KAAK,CAAC,iBAAiB,CAAC,CAAC,CAAA;IAC/D,KAAK,EAAE,aAAa,CAAC,qBAAqB,EAAE,YAAY,CAAC,CAAA;IACzD,cAAc,EAAE,OAAO,CAAA;IACvB,QAAQ,EAAE,OAAO,CAAC,IAAI,CAAC,EAAE,CAAA;IACzB,GAAG,EAAE,cAAc,CAAA;IACnB,gBAAgB,EAAE,OAAO,CAAA;IACzB,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;CACrC,CAAA;AAED,eAAO,MAAM,eAAe,4LAezB,mBAAmB,GAAG,IAAI,KAAG,IAiD/B,CAAA;AAED,eAAO,MAAM,2BAA2B,wKAarC,IAAI,KAAG,QAAQ,IAAI,CAqBrB,CAAA"}
@@ -1,68 +0,0 @@
1
- export const recurseRichText = ({ children, context, currentDepth = 0, depth, editorPopulationPromises, field, findMany, flattenLocales, overrideAccess = false, populationPromises, promises, req, showHiddenFields, siblingDoc })=>{
2
- if (depth <= 0 || currentDepth > depth) {
3
- return;
4
- }
5
- if (Array.isArray(children)) {
6
- children.forEach((node)=>{
7
- if (editorPopulationPromises?.has(node.type)) {
8
- for (const promise of editorPopulationPromises.get(node.type)){
9
- promises.push(...promise({
10
- context,
11
- currentDepth,
12
- depth,
13
- editorPopulationPromises,
14
- field,
15
- findMany,
16
- flattenLocales,
17
- node,
18
- overrideAccess,
19
- populationPromises,
20
- req,
21
- showHiddenFields,
22
- siblingDoc
23
- }));
24
- }
25
- }
26
- if ('children' in node && Array.isArray(node?.children) && node?.children?.length) {
27
- recurseRichText({
28
- children: node.children,
29
- context,
30
- currentDepth,
31
- depth,
32
- editorPopulationPromises,
33
- field,
34
- findMany,
35
- flattenLocales,
36
- overrideAccess,
37
- populationPromises,
38
- promises,
39
- req,
40
- showHiddenFields,
41
- siblingDoc
42
- });
43
- }
44
- });
45
- }
46
- };
47
- export const richTextRelationshipPromise = async ({ context, currentDepth, depth, editorPopulationPromises, field, findMany, flattenLocales, overrideAccess, populationPromises, req, showHiddenFields, siblingDoc })=>{
48
- const promises = [];
49
- recurseRichText({
50
- children: siblingDoc[field?.name]?.root?.children ?? [],
51
- context,
52
- currentDepth,
53
- depth,
54
- editorPopulationPromises,
55
- field,
56
- findMany,
57
- flattenLocales,
58
- overrideAccess,
59
- populationPromises,
60
- promises,
61
- req,
62
- showHiddenFields,
63
- siblingDoc
64
- });
65
- await Promise.all(promises);
66
- };
67
-
68
- //# sourceMappingURL=richTextRelationshipPromise.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../src/populate/richTextRelationshipPromise.ts"],"sourcesContent":["import type { SerializedEditorState, SerializedLexicalNode } from 'lexical'\nimport type { PayloadRequest, RichTextAdapter, RichTextField } from 'payload/types'\n\nimport type { PopulationPromise } from '../field/features/types.js'\nimport type { AdapterProps } from '../types.js'\n\nexport type Args = Parameters<\n RichTextAdapter<SerializedEditorState, AdapterProps>['populationPromise']\n>[0] & {\n editorPopulationPromises: Map<string, Array<PopulationPromise>>\n}\n\ntype RecurseRichTextArgs = {\n children: SerializedLexicalNode[]\n currentDepth: number\n depth: number\n editorPopulationPromises: Map<string, Array<PopulationPromise>>\n field: RichTextField<SerializedEditorState, AdapterProps>\n overrideAccess: boolean\n promises: Promise<void>[]\n req: PayloadRequest\n showHiddenFields: boolean\n siblingDoc?: Record<string, unknown>\n}\n\nexport const recurseRichText = ({\n children,\n context,\n currentDepth = 0,\n depth,\n editorPopulationPromises,\n field,\n findMany,\n flattenLocales,\n overrideAccess = false,\n populationPromises,\n promises,\n req,\n showHiddenFields,\n siblingDoc,\n}: RecurseRichTextArgs & Args): void => {\n if (depth <= 0 || currentDepth > depth) {\n return\n }\n\n if (Array.isArray(children)) {\n children.forEach((node) => {\n if (editorPopulationPromises?.has(node.type)) {\n for (const promise of editorPopulationPromises.get(node.type)) {\n promises.push(\n ...promise({\n context,\n currentDepth,\n depth,\n editorPopulationPromises,\n field,\n findMany,\n flattenLocales,\n node,\n overrideAccess,\n populationPromises,\n req,\n showHiddenFields,\n siblingDoc,\n }),\n )\n }\n }\n\n if ('children' in node && Array.isArray(node?.children) && node?.children?.length) {\n recurseRichText({\n children: node.children as SerializedLexicalNode[],\n context,\n currentDepth,\n depth,\n editorPopulationPromises,\n field,\n findMany,\n flattenLocales,\n overrideAccess,\n populationPromises,\n promises,\n req,\n showHiddenFields,\n siblingDoc,\n })\n }\n })\n }\n}\n\nexport const richTextRelationshipPromise = async ({\n context,\n currentDepth,\n depth,\n editorPopulationPromises,\n field,\n findMany,\n flattenLocales,\n overrideAccess,\n populationPromises,\n req,\n showHiddenFields,\n siblingDoc,\n}: Args): Promise<void> => {\n const promises = []\n\n recurseRichText({\n children: (siblingDoc[field?.name] as SerializedEditorState)?.root?.children ?? [],\n context,\n currentDepth,\n depth,\n editorPopulationPromises,\n field,\n findMany,\n flattenLocales,\n overrideAccess,\n populationPromises,\n promises,\n req,\n showHiddenFields,\n siblingDoc,\n })\n\n await Promise.all(promises)\n}\n"],"names":["recurseRichText","children","context","currentDepth","depth","editorPopulationPromises","field","findMany","flattenLocales","overrideAccess","populationPromises","promises","req","showHiddenFields","siblingDoc","Array","isArray","forEach","node","has","type","promise","get","push","length","richTextRelationshipPromise","name","root","Promise","all"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAyBA,OAAO,MAAMA,kBAAkB,CAAC,EAC9BC,QAAQ,EACRC,OAAO,EACPC,eAAe,CAAC,EAChBC,KAAK,EACLC,wBAAwB,EACxBC,KAAK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 +0,0 @@
1
- @font-face {
2
- font-family: 'Suisse Intl';
3
- src:
4
- url('../assets/fonts/SuisseIntl.woff2') format('woff2'),
5
- url('../assets/fonts/SuisseIntl.woff') format('woff');
6
- font-weight: normal;
7
- font-style: normal;
8
- }
9
-
10
- @font-face {
11
- font-family: 'Suisse Intl';
12
- src:
13
- url('../assets/fonts/SuisseIntl-Medium.woff2') format('woff2'),
14
- url('../assets/fonts/SuisseIntl-Medium.woff') format('woff');
15
- font-weight: 500;
16
- font-style: normal;
17
- }
18
-
19
- @font-face {
20
- font-family: 'Suisse Intl';
21
- src:
22
- url('../assets/fonts/SuisseIntl-SemiBold.woff2') format('woff2'),
23
- url('../assets/fonts/SuisseIntl-SemiBold.woff') format('woff');
24
- font-weight: 600;
25
- font-style: normal;
26
- }
27
-
28
- @font-face {
29
- font-family: 'Suisse Intl';
30
- src:
31
- url('../assets/fonts/SuisseIntl-Bold.woff2') format('woff2'),
32
- url('../assets/fonts/SuisseIntl-Bold.woff') format('woff');
33
- font-weight: bold;
34
- font-style: normal;
35
- }
36
-
37
- @font-face {
38
- font-family: 'Merriweather';
39
- font-style: normal;
40
- font-weight: 400;
41
- src:
42
- local(''),
43
- url('../assets/fonts/merriweather-v30-latin-regular.woff2') format('woff2'),
44
- url('../assets/fonts/merriweather-v30-latin-regular.woff') format('woff');
45
- }
46
-
47
- @font-face {
48
- font-family: 'Merriweather';
49
- font-style: italic;
50
- font-weight: 400;
51
- src:
52
- local(''),
53
- url('../assets/fonts/merriweather-v30-latin-italic.woff2') format('woff2'),
54
- url('../assets/fonts/merriweather-v30-latin-italic.woff') format('woff');
55
- }
56
-
57
- @font-face {
58
- font-family: 'Merriweather';
59
- font-style: normal;
60
- font-weight: 900;
61
- src:
62
- local(''),
63
- url('../assets/fonts/merriweather-v30-latin-900.woff2') format('woff2'),
64
- url('../assets/fonts/merriweather-v30-latin-900.woff') format('woff');
65
- }
66
-
67
- @font-face {
68
- font-family: 'Merriweather';
69
- font-style: italic;
70
- font-weight: 900;
71
- src:
72
- local(''),
73
- url('../assets/fonts/merriweather-v30-latin-900italic.woff2') format('woff2'),
74
- url('../assets/fonts/merriweather-v30-latin-900italic.woff') format('woff');
75
- }