@payloadcms/richtext-lexical 3.0.0-beta.53 → 3.0.0-beta.55

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 (727) hide show
  1. package/dist/cell/index.d.ts.map +1 -1
  2. package/dist/cell/index.js +1 -1
  3. package/dist/cell/index.js.map +1 -1
  4. package/dist/exports/client/Field-XBUN6QOM.js +2 -0
  5. package/dist/exports/client/Field-XBUN6QOM.js.map +7 -0
  6. package/dist/exports/client/{RelationshipComponent-5OU5HATX.js → RelationshipComponent-AFXEJMZQ.js} +2 -2
  7. package/dist/exports/client/bundled.css +1 -1
  8. package/dist/exports/client/{chunk-QU5MKT75.js → chunk-5RJS5YZT.js} +2 -2
  9. package/dist/exports/client/chunk-5RJS5YZT.js.map +7 -0
  10. package/dist/exports/client/chunk-JIP5PWU3.js +2 -0
  11. package/dist/exports/client/chunk-JIP5PWU3.js.map +7 -0
  12. package/dist/exports/client/{chunk-MLIITFAS.js → chunk-Q5DYR7MH.js} +2 -2
  13. package/dist/exports/client/chunk-Q5DYR7MH.js.map +7 -0
  14. package/dist/exports/client/{chunk-OSR74ZNW.js → chunk-YL52LJO3.js} +2 -2
  15. package/dist/exports/client/chunk-YL52LJO3.js.map +7 -0
  16. package/dist/exports/client/{component-E2NHAHBC.js → component-F6V63OLD.js} +2 -2
  17. package/dist/exports/client/component-F6V63OLD.js.map +7 -0
  18. package/dist/exports/client/component-PEFMKIXI.js +2 -0
  19. package/dist/exports/client/component-PEFMKIXI.js.map +7 -0
  20. package/dist/exports/client/{component-QWIGEOVD.js → component-VM36FRT2.js} +2 -2
  21. package/dist/exports/client/index.d.ts +37 -27
  22. package/dist/exports/client/index.d.ts.map +1 -1
  23. package/dist/exports/client/index.js +7 -5
  24. package/dist/exports/client/index.js.map +4 -4
  25. package/dist/features/align/feature.client.d.ts +1 -2
  26. package/dist/features/align/feature.client.d.ts.map +1 -1
  27. package/dist/features/align/feature.client.js +9 -16
  28. package/dist/features/align/feature.client.js.map +1 -1
  29. package/dist/features/align/feature.server.d.ts +1 -2
  30. package/dist/features/align/feature.server.d.ts.map +1 -1
  31. package/dist/features/align/feature.server.js +9 -15
  32. package/dist/features/align/feature.server.js.map +1 -1
  33. package/dist/features/align/i18n.js.map +1 -1
  34. package/dist/features/align/toolbarAlignGroup.js.map +1 -1
  35. package/dist/features/blockquote/feature.client.d.ts +1 -2
  36. package/dist/features/blockquote/feature.client.d.ts.map +1 -1
  37. package/dist/features/blockquote/feature.client.js +37 -44
  38. package/dist/features/blockquote/feature.client.js.map +1 -1
  39. package/dist/features/blockquote/feature.server.d.ts +6 -2
  40. package/dist/features/blockquote/feature.server.d.ts.map +1 -1
  41. package/dist/features/blockquote/feature.server.js +35 -40
  42. package/dist/features/blockquote/feature.server.js.map +1 -1
  43. package/dist/features/blockquote/i18n.js.map +1 -1
  44. package/dist/features/blockquote/markdownTransformer.js.map +1 -1
  45. package/dist/features/blocks/component/BlockContent.js +2 -2
  46. package/dist/features/blocks/component/BlockContent.js.map +1 -1
  47. package/dist/features/blocks/component/FormSavePlugin.js.map +1 -1
  48. package/dist/features/blocks/component/index.js +1 -1
  49. package/dist/features/blocks/component/index.js.map +1 -1
  50. package/dist/features/blocks/component/removeEmptyArrayValues.js.map +1 -1
  51. package/dist/features/blocks/drawer/index.js +1 -1
  52. package/dist/features/blocks/drawer/index.js.map +1 -1
  53. package/dist/features/blocks/feature.client.d.ts +1 -2
  54. package/dist/features/blocks/feature.client.d.ts.map +1 -1
  55. package/dist/features/blocks/feature.client.js +74 -80
  56. package/dist/features/blocks/feature.client.js.map +1 -1
  57. package/dist/features/blocks/feature.server.d.ts +1 -2
  58. package/dist/features/blocks/feature.server.d.ts.map +1 -1
  59. package/dist/features/blocks/feature.server.js +88 -90
  60. package/dist/features/blocks/feature.server.js.map +1 -1
  61. package/dist/features/blocks/graphQLPopulationPromise.d.ts +1 -1
  62. package/dist/features/blocks/graphQLPopulationPromise.d.ts.map +1 -1
  63. package/dist/features/blocks/graphQLPopulationPromise.js.map +1 -1
  64. package/dist/features/blocks/i18n.js.map +1 -1
  65. package/dist/features/blocks/nodes/BlocksNode.d.ts +2 -0
  66. package/dist/features/blocks/nodes/BlocksNode.d.ts.map +1 -1
  67. package/dist/features/blocks/nodes/BlocksNode.js +1 -1
  68. package/dist/features/blocks/nodes/BlocksNode.js.map +1 -1
  69. package/dist/features/blocks/plugin/commands.js.map +1 -1
  70. package/dist/features/blocks/plugin/index.d.ts +1 -1
  71. package/dist/features/blocks/plugin/index.d.ts.map +1 -1
  72. package/dist/features/blocks/plugin/index.js.map +1 -1
  73. package/dist/features/blocks/validate.d.ts +1 -1
  74. package/dist/features/blocks/validate.d.ts.map +1 -1
  75. package/dist/features/blocks/validate.js.map +1 -1
  76. package/dist/features/converters/html/converter/converters/linebreak.js.map +1 -1
  77. package/dist/features/converters/html/converter/converters/paragraph.js.map +1 -1
  78. package/dist/features/converters/html/converter/converters/text.js.map +1 -1
  79. package/dist/features/converters/html/converter/defaultConverters.js.map +1 -1
  80. package/dist/features/converters/html/converter/index.js.map +1 -1
  81. package/dist/features/converters/html/converter/types.js.map +1 -1
  82. package/dist/features/converters/html/feature.server.d.ts +1 -2
  83. package/dist/features/converters/html/feature.server.d.ts.map +1 -1
  84. package/dist/features/converters/html/feature.server.js +6 -12
  85. package/dist/features/converters/html/feature.server.js.map +1 -1
  86. package/dist/features/converters/html/field/index.js +1 -1
  87. package/dist/features/converters/html/field/index.js.map +1 -1
  88. package/dist/features/createClientComponent.d.ts +3 -2
  89. package/dist/features/createClientComponent.d.ts.map +1 -1
  90. package/dist/features/createClientComponent.js.map +1 -1
  91. package/dist/features/createFeaturePropComponent.d.ts.map +1 -1
  92. package/dist/features/createFeaturePropComponent.js.map +1 -1
  93. package/dist/features/debug/testRecorder/feature.client.d.ts +1 -2
  94. package/dist/features/debug/testRecorder/feature.client.d.ts.map +1 -1
  95. package/dist/features/debug/testRecorder/feature.client.js +9 -16
  96. package/dist/features/debug/testRecorder/feature.client.js.map +1 -1
  97. package/dist/features/debug/testRecorder/feature.server.d.ts +1 -2
  98. package/dist/features/debug/testRecorder/feature.server.d.ts.map +1 -1
  99. package/dist/features/debug/testRecorder/feature.server.js +8 -13
  100. package/dist/features/debug/testRecorder/feature.server.js.map +1 -1
  101. package/dist/features/debug/testRecorder/plugin/index.d.ts +1 -1
  102. package/dist/features/debug/testRecorder/plugin/index.d.ts.map +1 -1
  103. package/dist/features/debug/testRecorder/plugin/index.js.map +1 -1
  104. package/dist/features/debug/treeView/feature.client.d.ts +1 -2
  105. package/dist/features/debug/treeView/feature.client.d.ts.map +1 -1
  106. package/dist/features/debug/treeView/feature.client.js +9 -16
  107. package/dist/features/debug/treeView/feature.client.js.map +1 -1
  108. package/dist/features/debug/treeView/feature.server.d.ts +1 -2
  109. package/dist/features/debug/treeView/feature.server.d.ts.map +1 -1
  110. package/dist/features/debug/treeView/feature.server.js +8 -13
  111. package/dist/features/debug/treeView/feature.server.js.map +1 -1
  112. package/dist/features/debug/treeView/plugin/index.d.ts +1 -1
  113. package/dist/features/debug/treeView/plugin/index.d.ts.map +1 -1
  114. package/dist/features/debug/treeView/plugin/index.js.map +1 -1
  115. package/dist/features/format/bold/feature.client.d.ts +1 -2
  116. package/dist/features/format/bold/feature.client.d.ts.map +1 -1
  117. package/dist/features/format/bold/feature.client.js +16 -23
  118. package/dist/features/format/bold/feature.client.js.map +1 -1
  119. package/dist/features/format/bold/feature.server.d.ts +1 -2
  120. package/dist/features/format/bold/feature.server.d.ts.map +1 -1
  121. package/dist/features/format/bold/feature.server.js +21 -24
  122. package/dist/features/format/bold/feature.server.js.map +1 -1
  123. package/dist/features/format/bold/markdownTransformers.js.map +1 -1
  124. package/dist/features/format/inlineCode/feature.client.d.ts +1 -2
  125. package/dist/features/format/inlineCode/feature.client.d.ts.map +1 -1
  126. package/dist/features/format/inlineCode/feature.client.js +12 -21
  127. package/dist/features/format/inlineCode/feature.client.js.map +1 -1
  128. package/dist/features/format/inlineCode/feature.server.d.ts +1 -2
  129. package/dist/features/format/inlineCode/feature.server.d.ts.map +1 -1
  130. package/dist/features/format/inlineCode/feature.server.js +11 -16
  131. package/dist/features/format/inlineCode/feature.server.js.map +1 -1
  132. package/dist/features/format/inlineCode/markdownTransformers.js.map +1 -1
  133. package/dist/features/format/italic/feature.client.d.ts +1 -2
  134. package/dist/features/format/italic/feature.client.d.ts.map +1 -1
  135. package/dist/features/format/italic/feature.client.js +13 -22
  136. package/dist/features/format/italic/feature.client.js.map +1 -1
  137. package/dist/features/format/italic/feature.server.d.ts +1 -2
  138. package/dist/features/format/italic/feature.server.d.ts.map +1 -1
  139. package/dist/features/format/italic/feature.server.js +12 -17
  140. package/dist/features/format/italic/feature.server.js.map +1 -1
  141. package/dist/features/format/italic/markdownTransformers.js.map +1 -1
  142. package/dist/features/format/shared/toolbarFormatGroup.js.map +1 -1
  143. package/dist/features/format/strikethrough/feature.client.d.ts +1 -2
  144. package/dist/features/format/strikethrough/feature.client.d.ts.map +1 -1
  145. package/dist/features/format/strikethrough/feature.client.js +12 -21
  146. package/dist/features/format/strikethrough/feature.client.js.map +1 -1
  147. package/dist/features/format/strikethrough/feature.server.d.ts +1 -2
  148. package/dist/features/format/strikethrough/feature.server.d.ts.map +1 -1
  149. package/dist/features/format/strikethrough/feature.server.js +11 -16
  150. package/dist/features/format/strikethrough/feature.server.js.map +1 -1
  151. package/dist/features/format/strikethrough/markdownTransformers.js.map +1 -1
  152. package/dist/features/format/subscript/feature.client.d.ts +1 -2
  153. package/dist/features/format/subscript/feature.client.d.ts.map +1 -1
  154. package/dist/features/format/subscript/feature.client.js +9 -18
  155. package/dist/features/format/subscript/feature.client.js.map +1 -1
  156. package/dist/features/format/subscript/feature.server.d.ts +1 -2
  157. package/dist/features/format/subscript/feature.server.d.ts.map +1 -1
  158. package/dist/features/format/subscript/feature.server.js +8 -13
  159. package/dist/features/format/subscript/feature.server.js.map +1 -1
  160. package/dist/features/format/superscript/feature.client.d.ts +1 -2
  161. package/dist/features/format/superscript/feature.client.d.ts.map +1 -1
  162. package/dist/features/format/superscript/feature.client.js +9 -18
  163. package/dist/features/format/superscript/feature.client.js.map +1 -1
  164. package/dist/features/format/superscript/feature.server.d.ts +1 -2
  165. package/dist/features/format/superscript/feature.server.d.ts.map +1 -1
  166. package/dist/features/format/superscript/feature.server.js +8 -13
  167. package/dist/features/format/superscript/feature.server.js.map +1 -1
  168. package/dist/features/format/underline/feature.client.d.ts +1 -2
  169. package/dist/features/format/underline/feature.client.d.ts.map +1 -1
  170. package/dist/features/format/underline/feature.client.js +9 -18
  171. package/dist/features/format/underline/feature.client.js.map +1 -1
  172. package/dist/features/format/underline/feature.server.d.ts +1 -2
  173. package/dist/features/format/underline/feature.server.d.ts.map +1 -1
  174. package/dist/features/format/underline/feature.server.js +8 -13
  175. package/dist/features/format/underline/feature.server.js.map +1 -1
  176. package/dist/features/heading/feature.client.d.ts +1 -2
  177. package/dist/features/heading/feature.client.d.ts.map +1 -1
  178. package/dist/features/heading/feature.client.js +70 -76
  179. package/dist/features/heading/feature.client.js.map +1 -1
  180. package/dist/features/heading/feature.server.d.ts +1 -2
  181. package/dist/features/heading/feature.server.d.ts.map +1 -1
  182. package/dist/features/heading/feature.server.js +51 -53
  183. package/dist/features/heading/feature.server.js.map +1 -1
  184. package/dist/features/heading/i18n.js +2 -2
  185. package/dist/features/heading/i18n.js.map +1 -1
  186. package/dist/features/heading/markdownTransformer.js.map +1 -1
  187. package/dist/features/horizontalRule/component/index.js.map +1 -1
  188. package/dist/features/horizontalRule/feature.client.d.ts +1 -2
  189. package/dist/features/horizontalRule/feature.client.d.ts.map +1 -1
  190. package/dist/features/horizontalRule/feature.client.js +58 -65
  191. package/dist/features/horizontalRule/feature.client.js.map +1 -1
  192. package/dist/features/horizontalRule/feature.server.d.ts +1 -2
  193. package/dist/features/horizontalRule/feature.server.d.ts.map +1 -1
  194. package/dist/features/horizontalRule/feature.server.js +26 -31
  195. package/dist/features/horizontalRule/feature.server.js.map +1 -1
  196. package/dist/features/horizontalRule/i18n.js.map +1 -1
  197. package/dist/features/horizontalRule/markdownTransformer.js.map +1 -1
  198. package/dist/features/horizontalRule/nodes/HorizontalRuleNode.d.ts +5 -2
  199. package/dist/features/horizontalRule/nodes/HorizontalRuleNode.d.ts.map +1 -1
  200. package/dist/features/horizontalRule/nodes/HorizontalRuleNode.js.map +1 -1
  201. package/dist/features/horizontalRule/plugin/index.d.ts +1 -1
  202. package/dist/features/horizontalRule/plugin/index.d.ts.map +1 -1
  203. package/dist/features/horizontalRule/plugin/index.js.map +1 -1
  204. package/dist/features/indent/feature.client.d.ts +1 -2
  205. package/dist/features/indent/feature.client.d.ts.map +1 -1
  206. package/dist/features/indent/feature.client.js +9 -16
  207. package/dist/features/indent/feature.client.js.map +1 -1
  208. package/dist/features/indent/feature.server.d.ts +1 -2
  209. package/dist/features/indent/feature.server.d.ts.map +1 -1
  210. package/dist/features/indent/feature.server.js +9 -15
  211. package/dist/features/indent/feature.server.js.map +1 -1
  212. package/dist/features/indent/i18n.js.map +1 -1
  213. package/dist/features/indent/toolbarIndentGroup.js.map +1 -1
  214. package/dist/features/link/drawer/baseFields.d.ts +2 -2
  215. package/dist/features/link/drawer/baseFields.d.ts.map +1 -1
  216. package/dist/features/link/drawer/baseFields.js.map +1 -1
  217. package/dist/features/link/drawer/index.js.map +1 -1
  218. package/dist/features/link/drawer/types.js.map +1 -1
  219. package/dist/features/link/feature.client.d.ts +3 -4
  220. package/dist/features/link/feature.client.d.ts.map +1 -1
  221. package/dist/features/link/feature.client.js +34 -41
  222. package/dist/features/link/feature.client.js.map +1 -1
  223. package/dist/features/link/feature.server.d.ts +4 -6
  224. package/dist/features/link/feature.server.d.ts.map +1 -1
  225. package/dist/features/link/feature.server.js +123 -125
  226. package/dist/features/link/feature.server.js.map +1 -1
  227. package/dist/features/link/graphQLPopulationPromise.d.ts +1 -1
  228. package/dist/features/link/graphQLPopulationPromise.d.ts.map +1 -1
  229. package/dist/features/link/graphQLPopulationPromise.js.map +1 -1
  230. package/dist/features/link/i18n.js.map +1 -1
  231. package/dist/features/link/markdownTransformer.js.map +1 -1
  232. package/dist/features/link/nodes/AutoLinkNode.d.ts.map +1 -1
  233. package/dist/features/link/nodes/AutoLinkNode.js +7 -1
  234. package/dist/features/link/nodes/AutoLinkNode.js.map +1 -1
  235. package/dist/features/link/nodes/LinkNode.js +1 -1
  236. package/dist/features/link/nodes/LinkNode.js.map +1 -1
  237. package/dist/features/link/nodes/types.d.ts +7 -4
  238. package/dist/features/link/nodes/types.d.ts.map +1 -1
  239. package/dist/features/link/nodes/types.js.map +1 -1
  240. package/dist/features/link/plugins/autoLink/index.d.ts +1 -1
  241. package/dist/features/link/plugins/autoLink/index.d.ts.map +1 -1
  242. package/dist/features/link/plugins/autoLink/index.js.map +1 -1
  243. package/dist/features/link/plugins/clickableLink/index.d.ts +1 -1
  244. package/dist/features/link/plugins/clickableLink/index.d.ts.map +1 -1
  245. package/dist/features/link/plugins/clickableLink/index.js.map +1 -1
  246. package/dist/features/link/plugins/floatingLinkEditor/LinkEditor/commands.js.map +1 -1
  247. package/dist/features/link/plugins/floatingLinkEditor/LinkEditor/index.js.map +1 -1
  248. package/dist/features/link/plugins/floatingLinkEditor/index.d.ts +1 -1
  249. package/dist/features/link/plugins/floatingLinkEditor/index.d.ts.map +1 -1
  250. package/dist/features/link/plugins/floatingLinkEditor/index.js.map +1 -1
  251. package/dist/features/link/plugins/floatingLinkEditor/types.js.map +1 -1
  252. package/dist/features/link/plugins/floatingLinkEditor/utilities.d.ts +2 -2
  253. package/dist/features/link/plugins/floatingLinkEditor/utilities.d.ts.map +1 -1
  254. package/dist/features/link/plugins/floatingLinkEditor/utilities.js.map +1 -1
  255. package/dist/features/link/plugins/link/index.d.ts +1 -1
  256. package/dist/features/link/plugins/link/index.d.ts.map +1 -1
  257. package/dist/features/link/plugins/link/index.js.map +1 -1
  258. package/dist/features/link/validate.d.ts +1 -1
  259. package/dist/features/link/validate.d.ts.map +1 -1
  260. package/dist/features/link/validate.js.map +1 -1
  261. package/dist/features/lists/checklist/feature.client.d.ts +1 -2
  262. package/dist/features/lists/checklist/feature.client.d.ts.map +1 -1
  263. package/dist/features/lists/checklist/feature.client.js +50 -57
  264. package/dist/features/lists/checklist/feature.client.js.map +1 -1
  265. package/dist/features/lists/checklist/feature.server.d.ts +1 -2
  266. package/dist/features/lists/checklist/feature.server.d.ts.map +1 -1
  267. package/dist/features/lists/checklist/feature.server.js +28 -31
  268. package/dist/features/lists/checklist/feature.server.js.map +1 -1
  269. package/dist/features/lists/checklist/i18n.js.map +1 -1
  270. package/dist/features/lists/checklist/markdownTransformers.js.map +1 -1
  271. package/dist/features/lists/checklist/plugin/index.d.ts +1 -1
  272. package/dist/features/lists/checklist/plugin/index.d.ts.map +1 -1
  273. package/dist/features/lists/checklist/plugin/index.js.map +1 -1
  274. package/dist/features/lists/htmlConverter.d.ts +1 -1
  275. package/dist/features/lists/htmlConverter.d.ts.map +1 -1
  276. package/dist/features/lists/htmlConverter.js.map +1 -1
  277. package/dist/features/lists/orderedList/feature.client.d.ts +1 -2
  278. package/dist/features/lists/orderedList/feature.client.d.ts.map +1 -1
  279. package/dist/features/lists/orderedList/feature.client.js +39 -46
  280. package/dist/features/lists/orderedList/feature.client.js.map +1 -1
  281. package/dist/features/lists/orderedList/feature.server.d.ts +1 -2
  282. package/dist/features/lists/orderedList/feature.server.d.ts.map +1 -1
  283. package/dist/features/lists/orderedList/feature.server.js +28 -31
  284. package/dist/features/lists/orderedList/feature.server.js.map +1 -1
  285. package/dist/features/lists/orderedList/i18n.js.map +1 -1
  286. package/dist/features/lists/orderedList/markdownTransformer.js.map +1 -1
  287. package/dist/features/lists/plugin/index.d.ts +11 -1
  288. package/dist/features/lists/plugin/index.d.ts.map +1 -1
  289. package/dist/features/lists/plugin/index.js.map +1 -1
  290. package/dist/features/lists/shared/markdown.d.ts +1 -1
  291. package/dist/features/lists/shared/markdown.js.map +1 -1
  292. package/dist/features/lists/shared/slashMenuListGroup.js.map +1 -1
  293. package/dist/features/lists/unorderedList/feature.client.d.ts +1 -2
  294. package/dist/features/lists/unorderedList/feature.client.d.ts.map +1 -1
  295. package/dist/features/lists/unorderedList/feature.client.js +40 -49
  296. package/dist/features/lists/unorderedList/feature.client.js.map +1 -1
  297. package/dist/features/lists/unorderedList/feature.server.d.ts +1 -2
  298. package/dist/features/lists/unorderedList/feature.server.d.ts.map +1 -1
  299. package/dist/features/lists/unorderedList/feature.server.js +26 -31
  300. package/dist/features/lists/unorderedList/feature.server.js.map +1 -1
  301. package/dist/features/lists/unorderedList/i18n.js.map +1 -1
  302. package/dist/features/lists/unorderedList/markdownTransformer.js.map +1 -1
  303. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/heading/client.d.ts +0 -1
  304. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/heading/client.d.ts.map +1 -1
  305. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/heading/client.js.map +1 -1
  306. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/heading/converter.js.map +1 -1
  307. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/heading/index.js +1 -1
  308. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/heading/index.js.map +1 -1
  309. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/link/client.d.ts +0 -1
  310. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/link/client.d.ts.map +1 -1
  311. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/link/client.js.map +1 -1
  312. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/link/converter.js.map +1 -1
  313. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/link/index.js +1 -1
  314. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/link/index.js.map +1 -1
  315. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/list/client.d.ts +0 -1
  316. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/list/client.d.ts.map +1 -1
  317. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/list/client.js.map +1 -1
  318. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/list/converter.d.ts.map +1 -1
  319. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/list/converter.js.map +1 -1
  320. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/list/index.js +1 -1
  321. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/list/index.js.map +1 -1
  322. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/listItem/client.d.ts +0 -1
  323. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/listItem/client.d.ts.map +1 -1
  324. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/listItem/client.js.map +1 -1
  325. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/listItem/converter.d.ts.map +1 -1
  326. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/listItem/converter.js.map +1 -1
  327. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/listItem/index.js +1 -1
  328. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/listItem/index.js.map +1 -1
  329. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/quote/client.d.ts +0 -1
  330. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/quote/client.d.ts.map +1 -1
  331. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/quote/client.js.map +1 -1
  332. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/quote/converter.d.ts.map +1 -1
  333. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/quote/converter.js.map +1 -1
  334. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/quote/index.js +1 -1
  335. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/quote/index.js.map +1 -1
  336. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/unknown/client.d.ts +0 -1
  337. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/unknown/client.d.ts.map +1 -1
  338. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/unknown/client.js.map +1 -1
  339. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/unknown/converter.js.map +1 -1
  340. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/unknown/index.js +1 -1
  341. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/unknown/index.js.map +1 -1
  342. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/upload/client.d.ts +0 -1
  343. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/upload/client.d.ts.map +1 -1
  344. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/upload/client.js.map +1 -1
  345. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/upload/converter.js.map +1 -1
  346. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/upload/index.js +1 -1
  347. package/dist/features/migrations/lexicalPluginToLexical/converter/converters/upload/index.js.map +1 -1
  348. package/dist/features/migrations/lexicalPluginToLexical/converter/defaultConverters.js.map +1 -1
  349. package/dist/features/migrations/lexicalPluginToLexical/converter/index.js.map +1 -1
  350. package/dist/features/migrations/lexicalPluginToLexical/converter/types.d.ts +1 -1
  351. package/dist/features/migrations/lexicalPluginToLexical/converter/types.js.map +1 -1
  352. package/dist/features/migrations/lexicalPluginToLexical/feature.client.d.ts +1 -2
  353. package/dist/features/migrations/lexicalPluginToLexical/feature.client.d.ts.map +1 -1
  354. package/dist/features/migrations/lexicalPluginToLexical/feature.client.js +20 -27
  355. package/dist/features/migrations/lexicalPluginToLexical/feature.client.js.map +1 -1
  356. package/dist/features/migrations/lexicalPluginToLexical/feature.server.d.ts +1 -2
  357. package/dist/features/migrations/lexicalPluginToLexical/feature.server.d.ts.map +1 -1
  358. package/dist/features/migrations/lexicalPluginToLexical/feature.server.js +39 -42
  359. package/dist/features/migrations/lexicalPluginToLexical/feature.server.js.map +1 -1
  360. package/dist/features/migrations/lexicalPluginToLexical/nodes/unknownConvertedNode/Component.js.map +1 -1
  361. package/dist/features/migrations/lexicalPluginToLexical/nodes/unknownConvertedNode/index.js.map +1 -1
  362. package/dist/features/migrations/slateToLexical/converter/converters/blockquote/client.d.ts +0 -1
  363. package/dist/features/migrations/slateToLexical/converter/converters/blockquote/client.d.ts.map +1 -1
  364. package/dist/features/migrations/slateToLexical/converter/converters/blockquote/client.js.map +1 -1
  365. package/dist/features/migrations/slateToLexical/converter/converters/blockquote/converter.d.ts.map +1 -1
  366. package/dist/features/migrations/slateToLexical/converter/converters/blockquote/converter.js.map +1 -1
  367. package/dist/features/migrations/slateToLexical/converter/converters/blockquote/index.js +1 -1
  368. package/dist/features/migrations/slateToLexical/converter/converters/blockquote/index.js.map +1 -1
  369. package/dist/features/migrations/slateToLexical/converter/converters/heading/client.d.ts +0 -1
  370. package/dist/features/migrations/slateToLexical/converter/converters/heading/client.d.ts.map +1 -1
  371. package/dist/features/migrations/slateToLexical/converter/converters/heading/client.js.map +1 -1
  372. package/dist/features/migrations/slateToLexical/converter/converters/heading/converter.js.map +1 -1
  373. package/dist/features/migrations/slateToLexical/converter/converters/heading/index.js +1 -1
  374. package/dist/features/migrations/slateToLexical/converter/converters/heading/index.js.map +1 -1
  375. package/dist/features/migrations/slateToLexical/converter/converters/indent/client.d.ts +0 -1
  376. package/dist/features/migrations/slateToLexical/converter/converters/indent/client.d.ts.map +1 -1
  377. package/dist/features/migrations/slateToLexical/converter/converters/indent/client.js.map +1 -1
  378. package/dist/features/migrations/slateToLexical/converter/converters/indent/converter.js.map +1 -1
  379. package/dist/features/migrations/slateToLexical/converter/converters/indent/index.js +1 -1
  380. package/dist/features/migrations/slateToLexical/converter/converters/indent/index.js.map +1 -1
  381. package/dist/features/migrations/slateToLexical/converter/converters/link/client.d.ts +0 -1
  382. package/dist/features/migrations/slateToLexical/converter/converters/link/client.d.ts.map +1 -1
  383. package/dist/features/migrations/slateToLexical/converter/converters/link/client.js.map +1 -1
  384. package/dist/features/migrations/slateToLexical/converter/converters/link/converter.js.map +1 -1
  385. package/dist/features/migrations/slateToLexical/converter/converters/link/index.js +1 -1
  386. package/dist/features/migrations/slateToLexical/converter/converters/link/index.js.map +1 -1
  387. package/dist/features/migrations/slateToLexical/converter/converters/listItem/client.d.ts +0 -1
  388. package/dist/features/migrations/slateToLexical/converter/converters/listItem/client.d.ts.map +1 -1
  389. package/dist/features/migrations/slateToLexical/converter/converters/listItem/client.js.map +1 -1
  390. package/dist/features/migrations/slateToLexical/converter/converters/listItem/converter.d.ts.map +1 -1
  391. package/dist/features/migrations/slateToLexical/converter/converters/listItem/converter.js.map +1 -1
  392. package/dist/features/migrations/slateToLexical/converter/converters/listItem/index.js +1 -1
  393. package/dist/features/migrations/slateToLexical/converter/converters/listItem/index.js.map +1 -1
  394. package/dist/features/migrations/slateToLexical/converter/converters/orderedList/client.d.ts +0 -1
  395. package/dist/features/migrations/slateToLexical/converter/converters/orderedList/client.d.ts.map +1 -1
  396. package/dist/features/migrations/slateToLexical/converter/converters/orderedList/client.js.map +1 -1
  397. package/dist/features/migrations/slateToLexical/converter/converters/orderedList/converter.d.ts.map +1 -1
  398. package/dist/features/migrations/slateToLexical/converter/converters/orderedList/converter.js.map +1 -1
  399. package/dist/features/migrations/slateToLexical/converter/converters/orderedList/index.js +1 -1
  400. package/dist/features/migrations/slateToLexical/converter/converters/orderedList/index.js.map +1 -1
  401. package/dist/features/migrations/slateToLexical/converter/converters/relationship/client.d.ts +0 -1
  402. package/dist/features/migrations/slateToLexical/converter/converters/relationship/client.d.ts.map +1 -1
  403. package/dist/features/migrations/slateToLexical/converter/converters/relationship/client.js.map +1 -1
  404. package/dist/features/migrations/slateToLexical/converter/converters/relationship/converter.js.map +1 -1
  405. package/dist/features/migrations/slateToLexical/converter/converters/relationship/index.js +1 -1
  406. package/dist/features/migrations/slateToLexical/converter/converters/relationship/index.js.map +1 -1
  407. package/dist/features/migrations/slateToLexical/converter/converters/unknown/client.d.ts +0 -1
  408. package/dist/features/migrations/slateToLexical/converter/converters/unknown/client.d.ts.map +1 -1
  409. package/dist/features/migrations/slateToLexical/converter/converters/unknown/client.js.map +1 -1
  410. package/dist/features/migrations/slateToLexical/converter/converters/unknown/converter.js.map +1 -1
  411. package/dist/features/migrations/slateToLexical/converter/converters/unknown/index.js +1 -1
  412. package/dist/features/migrations/slateToLexical/converter/converters/unknown/index.js.map +1 -1
  413. package/dist/features/migrations/slateToLexical/converter/converters/unorderedList/client.d.ts +0 -1
  414. package/dist/features/migrations/slateToLexical/converter/converters/unorderedList/client.d.ts.map +1 -1
  415. package/dist/features/migrations/slateToLexical/converter/converters/unorderedList/client.js.map +1 -1
  416. package/dist/features/migrations/slateToLexical/converter/converters/unorderedList/converter.d.ts.map +1 -1
  417. package/dist/features/migrations/slateToLexical/converter/converters/unorderedList/converter.js.map +1 -1
  418. package/dist/features/migrations/slateToLexical/converter/converters/unorderedList/index.js +1 -1
  419. package/dist/features/migrations/slateToLexical/converter/converters/unorderedList/index.js.map +1 -1
  420. package/dist/features/migrations/slateToLexical/converter/converters/upload/client.d.ts +0 -1
  421. package/dist/features/migrations/slateToLexical/converter/converters/upload/client.d.ts.map +1 -1
  422. package/dist/features/migrations/slateToLexical/converter/converters/upload/client.js.map +1 -1
  423. package/dist/features/migrations/slateToLexical/converter/converters/upload/converter.js.map +1 -1
  424. package/dist/features/migrations/slateToLexical/converter/converters/upload/index.js +1 -1
  425. package/dist/features/migrations/slateToLexical/converter/converters/upload/index.js.map +1 -1
  426. package/dist/features/migrations/slateToLexical/converter/defaultConverters.js.map +1 -1
  427. package/dist/features/migrations/slateToLexical/converter/index.js.map +1 -1
  428. package/dist/features/migrations/slateToLexical/converter/types.d.ts +1 -1
  429. package/dist/features/migrations/slateToLexical/converter/types.js.map +1 -1
  430. package/dist/features/migrations/slateToLexical/feature.client.d.ts +1 -2
  431. package/dist/features/migrations/slateToLexical/feature.client.d.ts.map +1 -1
  432. package/dist/features/migrations/slateToLexical/feature.client.js +20 -27
  433. package/dist/features/migrations/slateToLexical/feature.client.js.map +1 -1
  434. package/dist/features/migrations/slateToLexical/feature.server.d.ts +3 -2
  435. package/dist/features/migrations/slateToLexical/feature.server.d.ts.map +1 -1
  436. package/dist/features/migrations/slateToLexical/feature.server.js +41 -42
  437. package/dist/features/migrations/slateToLexical/feature.server.js.map +1 -1
  438. package/dist/features/migrations/slateToLexical/nodes/unknownConvertedNode/Component.js.map +1 -1
  439. package/dist/features/migrations/slateToLexical/nodes/unknownConvertedNode/index.js.map +1 -1
  440. package/dist/features/paragraph/feature.client.d.ts +1 -2
  441. package/dist/features/paragraph/feature.client.d.ts.map +1 -1
  442. package/dist/features/paragraph/feature.client.js +33 -40
  443. package/dist/features/paragraph/feature.client.js.map +1 -1
  444. package/dist/features/paragraph/feature.server.d.ts +1 -2
  445. package/dist/features/paragraph/feature.server.d.ts.map +1 -1
  446. package/dist/features/paragraph/feature.server.js +10 -15
  447. package/dist/features/paragraph/feature.server.js.map +1 -1
  448. package/dist/features/paragraph/i18n.js.map +1 -1
  449. package/dist/features/relationship/drawer/commands.js.map +1 -1
  450. package/dist/features/relationship/drawer/index.d.ts.map +1 -1
  451. package/dist/features/relationship/drawer/index.js.map +1 -1
  452. package/dist/features/relationship/feature.client.d.ts +3 -4
  453. package/dist/features/relationship/feature.client.d.ts.map +1 -1
  454. package/dist/features/relationship/feature.client.js +60 -67
  455. package/dist/features/relationship/feature.client.js.map +1 -1
  456. package/dist/features/relationship/feature.server.d.ts +4 -4
  457. package/dist/features/relationship/feature.server.d.ts.map +1 -1
  458. package/dist/features/relationship/feature.server.js +45 -51
  459. package/dist/features/relationship/feature.server.js.map +1 -1
  460. package/dist/features/relationship/graphQLPopulationPromise.d.ts +1 -1
  461. package/dist/features/relationship/graphQLPopulationPromise.d.ts.map +1 -1
  462. package/dist/features/relationship/graphQLPopulationPromise.js.map +1 -1
  463. package/dist/features/relationship/i18n.js.map +1 -1
  464. package/dist/features/relationship/nodes/RelationshipNode.d.ts +6 -2
  465. package/dist/features/relationship/nodes/RelationshipNode.d.ts.map +1 -1
  466. package/dist/features/relationship/nodes/RelationshipNode.js +1 -1
  467. package/dist/features/relationship/nodes/RelationshipNode.js.map +1 -1
  468. package/dist/features/relationship/nodes/components/RelationshipComponent.d.ts.map +1 -1
  469. package/dist/features/relationship/nodes/components/RelationshipComponent.js.map +1 -1
  470. package/dist/features/relationship/plugins/index.d.ts +1 -1
  471. package/dist/features/relationship/plugins/index.d.ts.map +1 -1
  472. package/dist/features/relationship/plugins/index.js.map +1 -1
  473. package/dist/features/relationship/utils/EnabledRelationshipsCondition.js.map +1 -1
  474. package/dist/features/shared/slashMenu/basicGroup.js.map +1 -1
  475. package/dist/features/shared/toolbar/addDropdownGroup.js.map +1 -1
  476. package/dist/features/shared/toolbar/featureButtonsGroup.js.map +1 -1
  477. package/dist/features/shared/toolbar/textDropdownGroup.js.map +1 -1
  478. package/dist/features/toolbars/fixed/Toolbar/index.d.ts +1 -1
  479. package/dist/features/toolbars/fixed/Toolbar/index.d.ts.map +1 -1
  480. package/dist/features/toolbars/fixed/Toolbar/index.js.map +1 -1
  481. package/dist/features/toolbars/fixed/feature.client.d.ts +1 -2
  482. package/dist/features/toolbars/fixed/feature.client.d.ts.map +1 -1
  483. package/dist/features/toolbars/fixed/feature.client.js +9 -16
  484. package/dist/features/toolbars/fixed/feature.client.js.map +1 -1
  485. package/dist/features/toolbars/fixed/feature.server.d.ts +1 -2
  486. package/dist/features/toolbars/fixed/feature.server.d.ts.map +1 -1
  487. package/dist/features/toolbars/fixed/feature.server.js +16 -18
  488. package/dist/features/toolbars/fixed/feature.server.js.map +1 -1
  489. package/dist/features/toolbars/inline/Toolbar/index.d.ts +1 -1
  490. package/dist/features/toolbars/inline/Toolbar/index.d.ts.map +1 -1
  491. package/dist/features/toolbars/inline/Toolbar/index.js.map +1 -1
  492. package/dist/features/toolbars/inline/feature.client.d.ts +1 -2
  493. package/dist/features/toolbars/inline/feature.client.d.ts.map +1 -1
  494. package/dist/features/toolbars/inline/feature.client.js +9 -16
  495. package/dist/features/toolbars/inline/feature.client.js.map +1 -1
  496. package/dist/features/toolbars/inline/feature.server.d.ts +1 -2
  497. package/dist/features/toolbars/inline/feature.server.d.ts.map +1 -1
  498. package/dist/features/toolbars/inline/feature.server.js +8 -13
  499. package/dist/features/toolbars/inline/feature.server.js.map +1 -1
  500. package/dist/features/toolbars/shared/ToolbarButton/index.d.ts.map +1 -1
  501. package/dist/features/toolbars/shared/ToolbarButton/index.js.map +1 -1
  502. package/dist/features/toolbars/shared/ToolbarDropdown/DropDown.js.map +1 -1
  503. package/dist/features/toolbars/shared/ToolbarDropdown/index.d.ts.map +1 -1
  504. package/dist/features/toolbars/shared/ToolbarDropdown/index.js.map +1 -1
  505. package/dist/features/toolbars/types.d.ts +37 -5
  506. package/dist/features/toolbars/types.d.ts.map +1 -1
  507. package/dist/features/toolbars/types.js.map +1 -1
  508. package/dist/features/typeUtilities.d.ts +1 -1
  509. package/dist/features/typeUtilities.d.ts.map +1 -1
  510. package/dist/features/typeUtilities.js.map +1 -1
  511. package/dist/features/typesClient.d.ts +182 -0
  512. package/dist/features/typesClient.d.ts.map +1 -0
  513. package/dist/features/typesClient.js +3 -0
  514. package/dist/features/typesClient.js.map +1 -0
  515. package/dist/features/{types.d.ts → typesServer.d.ts} +40 -193
  516. package/dist/features/typesServer.d.ts.map +1 -0
  517. package/dist/features/typesServer.js +3 -0
  518. package/dist/features/typesServer.js.map +1 -0
  519. package/dist/features/upload/component/ExtraFieldsDrawer/index.js.map +1 -1
  520. package/dist/features/upload/component/index.d.ts.map +1 -1
  521. package/dist/features/upload/component/index.js +1 -1
  522. package/dist/features/upload/component/index.js.map +1 -1
  523. package/dist/features/upload/drawer/commands.js.map +1 -1
  524. package/dist/features/upload/drawer/index.d.ts.map +1 -1
  525. package/dist/features/upload/drawer/index.js.map +1 -1
  526. package/dist/features/upload/feature.client.d.ts +1 -2
  527. package/dist/features/upload/feature.client.d.ts.map +1 -1
  528. package/dist/features/upload/feature.client.js +62 -69
  529. package/dist/features/upload/feature.client.js.map +1 -1
  530. package/dist/features/upload/feature.server.d.ts +3 -4
  531. package/dist/features/upload/feature.server.d.ts.map +1 -1
  532. package/dist/features/upload/feature.server.js +166 -168
  533. package/dist/features/upload/feature.server.js.map +1 -1
  534. package/dist/features/upload/graphQLPopulationPromise.d.ts +1 -1
  535. package/dist/features/upload/graphQLPopulationPromise.d.ts.map +1 -1
  536. package/dist/features/upload/graphQLPopulationPromise.js.map +1 -1
  537. package/dist/features/upload/i18n.js.map +1 -1
  538. package/dist/features/upload/nodes/UploadNode.d.ts +6 -2
  539. package/dist/features/upload/nodes/UploadNode.d.ts.map +1 -1
  540. package/dist/features/upload/nodes/UploadNode.js +1 -1
  541. package/dist/features/upload/nodes/UploadNode.js.map +1 -1
  542. package/dist/features/upload/plugin/index.d.ts +1 -1
  543. package/dist/features/upload/plugin/index.d.ts.map +1 -1
  544. package/dist/features/upload/plugin/index.js.map +1 -1
  545. package/dist/features/upload/validate.d.ts +1 -1
  546. package/dist/features/upload/validate.d.ts.map +1 -1
  547. package/dist/features/upload/validate.js.map +1 -1
  548. package/dist/field/Field.d.ts.map +1 -1
  549. package/dist/field/Field.js.map +1 -1
  550. package/dist/field/index.d.ts.map +1 -1
  551. package/dist/field/index.js +9 -7
  552. package/dist/field/index.js.map +1 -1
  553. package/dist/i18n.js.map +1 -1
  554. package/dist/index.d.ts +12 -8
  555. package/dist/index.d.ts.map +1 -1
  556. package/dist/index.js +19 -17
  557. package/dist/index.js.map +1 -1
  558. package/dist/lexical/EditorPlugin.d.ts +1 -1
  559. package/dist/lexical/EditorPlugin.d.ts.map +1 -1
  560. package/dist/lexical/EditorPlugin.js.map +1 -1
  561. package/dist/lexical/LexicalEditor.js.map +1 -1
  562. package/dist/lexical/LexicalProvider.js.map +1 -1
  563. package/dist/lexical/config/client/EditorConfigProvider.d.ts.map +1 -1
  564. package/dist/lexical/config/client/EditorConfigProvider.js.map +1 -1
  565. package/dist/lexical/config/client/default.js.map +1 -1
  566. package/dist/lexical/config/client/loader.d.ts +1 -1
  567. package/dist/lexical/config/client/loader.d.ts.map +1 -1
  568. package/dist/lexical/config/client/loader.js +2 -2
  569. package/dist/lexical/config/client/loader.js.map +1 -1
  570. package/dist/lexical/config/client/sanitize.d.ts +1 -1
  571. package/dist/lexical/config/client/sanitize.d.ts.map +1 -1
  572. package/dist/lexical/config/client/sanitize.js +1 -1
  573. package/dist/lexical/config/client/sanitize.js.map +1 -1
  574. package/dist/lexical/config/server/default.d.ts +2 -2
  575. package/dist/lexical/config/server/default.d.ts.map +1 -1
  576. package/dist/lexical/config/server/default.js.map +1 -1
  577. package/dist/lexical/config/server/loader.d.ts +2 -2
  578. package/dist/lexical/config/server/loader.d.ts.map +1 -1
  579. package/dist/lexical/config/server/loader.js +2 -2
  580. package/dist/lexical/config/server/loader.js.map +1 -1
  581. package/dist/lexical/config/server/sanitize.d.ts +1 -1
  582. package/dist/lexical/config/server/sanitize.d.ts.map +1 -1
  583. package/dist/lexical/config/server/sanitize.js.map +1 -1
  584. package/dist/lexical/config/types.d.ts +4 -3
  585. package/dist/lexical/config/types.d.ts.map +1 -1
  586. package/dist/lexical/config/types.js.map +1 -1
  587. package/dist/lexical/nodes/index.js.map +1 -1
  588. package/dist/lexical/plugins/MarkdownShortcut/index.js.map +1 -1
  589. package/dist/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/LexicalMenu.js.map +1 -1
  590. package/dist/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/index.js.map +1 -1
  591. package/dist/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/types.d.ts +16 -1
  592. package/dist/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/types.d.ts.map +1 -1
  593. package/dist/lexical/plugins/SlashMenu/LexicalTypeaheadMenuPlugin/types.js.map +1 -1
  594. package/dist/lexical/plugins/SlashMenu/index.js.map +1 -1
  595. package/dist/lexical/plugins/SlashMenu/useMenuTriggerMatch.js.map +1 -1
  596. package/dist/lexical/plugins/handles/AddBlockHandlePlugin/index.js.map +1 -1
  597. package/dist/lexical/plugins/handles/DraggableBlockPlugin/debounce.js.map +1 -1
  598. package/dist/lexical/plugins/handles/DraggableBlockPlugin/getBoundingRectWithoutTransform.js.map +1 -1
  599. package/dist/lexical/plugins/handles/DraggableBlockPlugin/highlightElemOriginalPosition.js.map +1 -1
  600. package/dist/lexical/plugins/handles/DraggableBlockPlugin/index.js.map +1 -1
  601. package/dist/lexical/plugins/handles/DraggableBlockPlugin/setTargetLine.d.ts +0 -1
  602. package/dist/lexical/plugins/handles/DraggableBlockPlugin/setTargetLine.d.ts.map +1 -1
  603. package/dist/lexical/plugins/handles/DraggableBlockPlugin/setTargetLine.js.map +1 -1
  604. package/dist/lexical/plugins/handles/utils/calculateDistanceFromScrollerElem.js.map +1 -1
  605. package/dist/lexical/plugins/handles/utils/doesLineHeightAffectElement.js.map +1 -1
  606. package/dist/lexical/plugins/handles/utils/getCollapsedMargins.js.map +1 -1
  607. package/dist/lexical/plugins/handles/utils/getNodeCloseToPoint.js.map +1 -1
  608. package/dist/lexical/plugins/handles/utils/getTopLevelNodeKeys.js.map +1 -1
  609. package/dist/lexical/plugins/handles/utils/isOnHandleElement.js.map +1 -1
  610. package/dist/lexical/plugins/handles/utils/setHandlePosition.js.map +1 -1
  611. package/dist/lexical/theme/EditorTheme.js.map +1 -1
  612. package/dist/lexical/ui/ContentEditable.js.map +1 -1
  613. package/dist/lexical/ui/icons/AI/index.js.map +1 -1
  614. package/dist/lexical/ui/icons/Add/index.js.map +1 -1
  615. package/dist/lexical/ui/icons/AlignCenter/index.js.map +1 -1
  616. package/dist/lexical/ui/icons/AlignJustify/index.js.map +1 -1
  617. package/dist/lexical/ui/icons/AlignLeft/index.js.map +1 -1
  618. package/dist/lexical/ui/icons/AlignRight/index.js.map +1 -1
  619. package/dist/lexical/ui/icons/Block/index.js.map +1 -1
  620. package/dist/lexical/ui/icons/Blockquote/index.js.map +1 -1
  621. package/dist/lexical/ui/icons/Bold/index.js.map +1 -1
  622. package/dist/lexical/ui/icons/Checklist/index.js.map +1 -1
  623. package/dist/lexical/ui/icons/Code/index.js.map +1 -1
  624. package/dist/lexical/ui/icons/CodeBlock/index.js.map +1 -1
  625. package/dist/lexical/ui/icons/H1/index.js.map +1 -1
  626. package/dist/lexical/ui/icons/H2/index.js.map +1 -1
  627. package/dist/lexical/ui/icons/H3/index.js.map +1 -1
  628. package/dist/lexical/ui/icons/H4/index.js.map +1 -1
  629. package/dist/lexical/ui/icons/H5/index.js.map +1 -1
  630. package/dist/lexical/ui/icons/H6/index.js.map +1 -1
  631. package/dist/lexical/ui/icons/HorizontalRule/index.js.map +1 -1
  632. package/dist/lexical/ui/icons/IndentDecrease/index.js.map +1 -1
  633. package/dist/lexical/ui/icons/IndentIncrease/index.js.map +1 -1
  634. package/dist/lexical/ui/icons/Italic/index.js.map +1 -1
  635. package/dist/lexical/ui/icons/Link/index.js.map +1 -1
  636. package/dist/lexical/ui/icons/OrderedList/index.js.map +1 -1
  637. package/dist/lexical/ui/icons/Relationship/index.js.map +1 -1
  638. package/dist/lexical/ui/icons/Strikethrough/index.js.map +1 -1
  639. package/dist/lexical/ui/icons/Subscript/index.js.map +1 -1
  640. package/dist/lexical/ui/icons/Superscript/index.js.map +1 -1
  641. package/dist/lexical/ui/icons/Text/index.js.map +1 -1
  642. package/dist/lexical/ui/icons/Underline/index.js.map +1 -1
  643. package/dist/lexical/ui/icons/UnorderedList/index.js.map +1 -1
  644. package/dist/lexical/ui/icons/Upload/index.js.map +1 -1
  645. package/dist/lexical/utils/canUseDOM.js.map +1 -1
  646. package/dist/lexical/utils/cloneDeep.js.map +1 -1
  647. package/dist/lexical/utils/environment.js.map +1 -1
  648. package/dist/lexical/utils/getDOMRangeRect.js.map +1 -1
  649. package/dist/lexical/utils/getSelectedNode.js.map +1 -1
  650. package/dist/lexical/utils/guard.js.map +1 -1
  651. package/dist/lexical/utils/invariant.js.map +1 -1
  652. package/dist/lexical/utils/joinClasses.js.map +1 -1
  653. package/dist/lexical/utils/markdown/createBlockNode.d.ts +1 -1
  654. package/dist/lexical/utils/markdown/createBlockNode.d.ts.map +1 -1
  655. package/dist/lexical/utils/markdown/createBlockNode.js.map +1 -1
  656. package/dist/lexical/utils/nodeFormat.js.map +1 -1
  657. package/dist/lexical/utils/point.js.map +1 -1
  658. package/dist/lexical/utils/rect.js.map +1 -1
  659. package/dist/lexical/utils/setFloatingElemPosition.js.map +1 -1
  660. package/dist/lexical/utils/setFloatingElemPositionForLinkEditor.js.map +1 -1
  661. package/dist/lexical/utils/swipe.js.map +1 -1
  662. package/dist/lexical/utils/url.js.map +1 -1
  663. package/dist/nodeTypes.d.ts +27 -0
  664. package/dist/nodeTypes.d.ts.map +1 -0
  665. package/dist/nodeTypes.js +3 -0
  666. package/dist/nodeTypes.js.map +1 -0
  667. package/dist/populateGraphQL/defaultValue.js.map +1 -1
  668. package/dist/populateGraphQL/populate.d.ts.map +1 -1
  669. package/dist/populateGraphQL/populate.js.map +1 -1
  670. package/dist/populateGraphQL/populateLexicalPopulationPromises.d.ts +1 -1
  671. package/dist/populateGraphQL/populateLexicalPopulationPromises.d.ts.map +1 -1
  672. package/dist/populateGraphQL/populateLexicalPopulationPromises.js.map +1 -1
  673. package/dist/populateGraphQL/recursivelyPopulateFieldsForGraphQL.d.ts +1 -1
  674. package/dist/populateGraphQL/recursivelyPopulateFieldsForGraphQL.d.ts.map +1 -1
  675. package/dist/populateGraphQL/recursivelyPopulateFieldsForGraphQL.js.map +1 -1
  676. package/dist/types.d.ts +7 -7
  677. package/dist/types.d.ts.map +1 -1
  678. package/dist/types.js.map +1 -1
  679. package/dist/utilities/createClientFeature.d.ts +13 -0
  680. package/dist/utilities/createClientFeature.d.ts.map +1 -0
  681. package/dist/utilities/createClientFeature.js +30 -0
  682. package/dist/utilities/createClientFeature.js.map +1 -0
  683. package/dist/utilities/createServerFeature.d.ts +16 -0
  684. package/dist/utilities/createServerFeature.d.ts.map +1 -0
  685. package/dist/utilities/createServerFeature.js +34 -0
  686. package/dist/utilities/createServerFeature.js.map +1 -0
  687. package/dist/utilities/forEachNodeRecursively.js.map +1 -1
  688. package/dist/utilities/generateComponentMap.d.ts +2 -2
  689. package/dist/utilities/generateComponentMap.d.ts.map +1 -1
  690. package/dist/utilities/generateComponentMap.js +4 -4
  691. package/dist/utilities/generateComponentMap.js.map +1 -1
  692. package/dist/utilities/generateSchemaMap.d.ts +2 -2
  693. package/dist/utilities/generateSchemaMap.d.ts.map +1 -1
  694. package/dist/utilities/generateSchemaMap.js +1 -1
  695. package/dist/utilities/generateSchemaMap.js.map +1 -1
  696. package/dist/utilities/migrateSlateToLexical/index.d.ts +15 -0
  697. package/dist/utilities/migrateSlateToLexical/index.d.ts.map +1 -0
  698. package/dist/utilities/migrateSlateToLexical/index.js +105 -0
  699. package/dist/utilities/migrateSlateToLexical/index.js.map +1 -0
  700. package/dist/utilities/migrateSlateToLexical/recurse.d.ts +9 -0
  701. package/dist/utilities/migrateSlateToLexical/recurse.d.ts.map +1 -0
  702. package/dist/utilities/migrateSlateToLexical/recurse.js +77 -0
  703. package/dist/utilities/migrateSlateToLexical/recurse.js.map +1 -0
  704. package/dist/utilities/recurseNodeTree.js.map +1 -1
  705. package/dist/utilities/useLexicalFeature.d.ts +1 -1
  706. package/dist/utilities/useLexicalFeature.d.ts.map +1 -1
  707. package/dist/utilities/useLexicalFeature.js.map +1 -1
  708. package/dist/validate/index.js.map +1 -1
  709. package/dist/validate/validateNodes.d.ts +1 -1
  710. package/dist/validate/validateNodes.d.ts.map +1 -1
  711. package/dist/validate/validateNodes.js.map +1 -1
  712. package/package.json +10 -10
  713. package/dist/exports/client/Field-YMWNSE3A.js +0 -2
  714. package/dist/exports/client/Field-YMWNSE3A.js.map +0 -7
  715. package/dist/exports/client/chunk-MLIITFAS.js.map +0 -7
  716. package/dist/exports/client/chunk-OSR74ZNW.js.map +0 -7
  717. package/dist/exports/client/chunk-QU5MKT75.js.map +0 -7
  718. package/dist/exports/client/chunk-ZITHDR53.js +0 -2
  719. package/dist/exports/client/chunk-ZITHDR53.js.map +0 -7
  720. package/dist/exports/client/component-E2NHAHBC.js.map +0 -7
  721. package/dist/exports/client/component-X4LSLSWF.js +0 -2
  722. package/dist/exports/client/component-X4LSLSWF.js.map +0 -7
  723. package/dist/features/types.d.ts.map +0 -1
  724. package/dist/features/types.js +0 -3
  725. package/dist/features/types.js.map +0 -1
  726. /package/dist/exports/client/{RelationshipComponent-5OU5HATX.js.map → RelationshipComponent-AFXEJMZQ.js.map} +0 -0
  727. /package/dist/exports/client/{component-QWIGEOVD.js.map → component-VM36FRT2.js.map} +0 -0
@@ -1,61 +1,59 @@
1
1
  import { HeadingNode } from '@lexical/rich-text';
2
2
  // eslint-disable-next-line payload/no-imports-from-exports-dir
3
- import { HeadingFeatureClientComponent } from '../../exports/client/index.js';
3
+ import { HeadingFeatureClient } from '../../exports/client/index.js';
4
+ import { createServerFeature } from '../../utilities/createServerFeature.js';
4
5
  import { convertLexicalNodesToHTML } from '../converters/html/converter/index.js';
5
6
  import { createNode } from '../typeUtilities.js';
6
7
  import { i18n } from './i18n.js';
7
8
  import { MarkdownTransformer } from './markdownTransformer.js';
8
- export const HeadingFeature = (props)=>{
9
- if (!props) {
10
- props = {};
11
- }
12
- const { enabledHeadingSizes = [
13
- 'h1',
14
- 'h2',
15
- 'h3',
16
- 'h4',
17
- 'h5',
18
- 'h6'
19
- ] } = props;
20
- return {
21
- feature: ()=>{
22
- return {
23
- ClientComponent: HeadingFeatureClientComponent,
24
- clientFeatureProps: props,
25
- i18n,
26
- markdownTransformers: [
27
- MarkdownTransformer(enabledHeadingSizes)
28
- ],
29
- nodes: [
30
- createNode({
31
- converters: {
32
- html: {
33
- converter: async ({ converters, node, parent, req })=>{
34
- const childrenText = await convertLexicalNodesToHTML({
35
- converters,
36
- lexicalNodes: node.children,
37
- parent: {
38
- ...node,
39
- parent
40
- },
41
- req
42
- });
43
- return '<' + node?.tag + '>' + childrenText + '</' + node?.tag + '>';
44
- },
45
- nodeTypes: [
46
- HeadingNode.getType()
47
- ]
48
- }
49
- },
50
- node: HeadingNode
51
- })
52
- ],
53
- serverFeatureProps: props
54
- };
55
- },
56
- key: 'heading',
57
- serverFeatureProps: props
58
- };
59
- };
9
+ export const HeadingFeature = createServerFeature({
10
+ feature: ({ props })=>{
11
+ if (!props) {
12
+ props = {};
13
+ }
14
+ const { enabledHeadingSizes = [
15
+ 'h1',
16
+ 'h2',
17
+ 'h3',
18
+ 'h4',
19
+ 'h5',
20
+ 'h6'
21
+ ] } = props;
22
+ return {
23
+ ClientFeature: HeadingFeatureClient,
24
+ clientFeatureProps: props,
25
+ i18n,
26
+ markdownTransformers: [
27
+ MarkdownTransformer(enabledHeadingSizes)
28
+ ],
29
+ nodes: [
30
+ createNode({
31
+ converters: {
32
+ html: {
33
+ converter: async ({ converters, node, parent, req })=>{
34
+ const childrenText = await convertLexicalNodesToHTML({
35
+ converters,
36
+ lexicalNodes: node.children,
37
+ parent: {
38
+ ...node,
39
+ parent
40
+ },
41
+ req
42
+ });
43
+ return '<' + node?.tag + '>' + childrenText + '</' + node?.tag + '>';
44
+ },
45
+ nodeTypes: [
46
+ HeadingNode.getType()
47
+ ]
48
+ }
49
+ },
50
+ node: HeadingNode
51
+ })
52
+ ],
53
+ sanitizedServerFeatureProps: props
54
+ };
55
+ },
56
+ key: 'heading'
57
+ });
60
58
 
61
59
  //# sourceMappingURL=feature.server.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/features/heading/feature.server.ts"],"sourcesContent":["import type { HeadingTagType } from '@lexical/rich-text'\n\nimport { HeadingNode } from '@lexical/rich-text'\n\nimport type { FeatureProviderProviderServer } from '../types.js'\n\n// eslint-disable-next-line payload/no-imports-from-exports-dir\nimport { HeadingFeatureClientComponent } from '../../exports/client/index.js'\nimport { convertLexicalNodesToHTML } from '../converters/html/converter/index.js'\nimport { createNode } from '../typeUtilities.js'\nimport { i18n } from './i18n.js'\nimport { MarkdownTransformer } from './markdownTransformer.js'\n\nexport type HeadingFeatureProps = {\n enabledHeadingSizes?: HeadingTagType[]\n}\n\nexport const HeadingFeature: FeatureProviderProviderServer<\n HeadingFeatureProps,\n HeadingFeatureProps\n> = (props) => {\n if (!props) {\n props = {}\n }\n\n const { enabledHeadingSizes = ['h1', 'h2', 'h3', 'h4', 'h5', 'h6'] } = props\n\n return {\n feature: () => {\n return {\n ClientComponent: HeadingFeatureClientComponent,\n clientFeatureProps: props,\n i18n,\n markdownTransformers: [MarkdownTransformer(enabledHeadingSizes)],\n nodes: [\n createNode({\n converters: {\n html: {\n converter: async ({ converters, node, parent, req }) => {\n const childrenText = await convertLexicalNodesToHTML({\n converters,\n lexicalNodes: node.children,\n parent: {\n ...node,\n parent,\n },\n req,\n })\n\n return '<' + node?.tag + '>' + childrenText + '</' + node?.tag + '>'\n },\n nodeTypes: [HeadingNode.getType()],\n },\n },\n node: HeadingNode,\n }),\n ],\n serverFeatureProps: props,\n }\n },\n key: 'heading',\n serverFeatureProps: props,\n }\n}\n"],"names":["HeadingNode","HeadingFeatureClientComponent","convertLexicalNodesToHTML","createNode","i18n","MarkdownTransformer","HeadingFeature","props","enabledHeadingSizes","feature","ClientComponent","clientFeatureProps","markdownTransformers","nodes","converters","html","converter","node","parent","req","childrenText","lexicalNodes","children","tag","nodeTypes","getType","serverFeatureProps","key"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAEA,SAASA,WAAW,QAAQ,qBAAoB;AAIhD,+DAA+D;AAC/D,SAASC,6BAA6B,QAAQ,gCAA+B;AAC7E,SAASC,yBAAyB,QAAQ,wCAAuC;AACjF,SAASC,UAAU,QAAQ,sBAAqB;AAChD,SAASC,IAAI,QAAQ,YAAW;AAChC,SAASC,mBAAmB,QAAQ,2BAA0B;AAM9D,OAAO,MAAMC,iBAGT,CAACC;IACH,IAAI,CAACA,OAAO;QACVA,QAAQ,CAAC;IACX;IAEA,MAAM,EAAEC,sBAAsB;QAAC;QAAM;QAAM;QAAM;QAAM;QAAM;KAAK,EAAE,GAAGD;IAEvE,OAAO;QACLE,SAAS;YACP,OAAO;gBACLC,iBAAiBT;gBACjBU,oBAAoBJ;gBACpBH;gBACAQ,sBAAsB;oBAACP,oBAAoBG;iBAAqB;gBAChEK,OAAO;oBACLV,WAAW;wBACTW,YAAY;4BACVC,MAAM;gCACJC,WAAW,OAAO,EAAEF,UAAU,EAAEG,IAAI,EAAEC,MAAM,EAAEC,GAAG,EAAE;oCACjD,MAAMC,eAAe,MAAMlB,0BAA0B;wCACnDY;wCACAO,cAAcJ,KAAKK,QAAQ;wCAC3BJ,QAAQ;4CACN,GAAGD,IAAI;4CACPC;wCACF;wCACAC;oCACF;oCAEA,OAAO,MAAMF,MAAMM,MAAM,MAAMH,eAAe,OAAOH,MAAMM,MAAM;gCACnE;gCACAC,WAAW;oCAACxB,YAAYyB,OAAO;iCAAG;4BACpC;wBACF;wBACAR,MAAMjB;oBACR;iBACD;gBACD0B,oBAAoBnB;YACtB;QACF;QACAoB,KAAK;QACLD,oBAAoBnB;IACtB;AACF,EAAC"}
1
+ {"version":3,"sources":["../../../src/features/heading/feature.server.ts"],"sourcesContent":["import type { HeadingTagType } from '@lexical/rich-text'\n\nimport { HeadingNode } from '@lexical/rich-text'\n\n// eslint-disable-next-line payload/no-imports-from-exports-dir\nimport { HeadingFeatureClient } from '../../exports/client/index.js'\nimport { createServerFeature } from '../../utilities/createServerFeature.js'\nimport { convertLexicalNodesToHTML } from '../converters/html/converter/index.js'\nimport { createNode } from '../typeUtilities.js'\nimport { i18n } from './i18n.js'\nimport { MarkdownTransformer } from './markdownTransformer.js'\n\nexport type HeadingFeatureProps = {\n enabledHeadingSizes?: HeadingTagType[]\n}\n\nexport const HeadingFeature = createServerFeature<\n HeadingFeatureProps,\n HeadingFeatureProps,\n HeadingFeatureProps\n>({\n feature: ({ props }) => {\n if (!props) {\n props = {}\n }\n\n const { enabledHeadingSizes = ['h1', 'h2', 'h3', 'h4', 'h5', 'h6'] } = props\n\n return {\n ClientFeature: HeadingFeatureClient,\n clientFeatureProps: props,\n i18n,\n markdownTransformers: [MarkdownTransformer(enabledHeadingSizes)],\n nodes: [\n createNode({\n converters: {\n html: {\n converter: async ({ converters, node, parent, req }) => {\n const childrenText = await convertLexicalNodesToHTML({\n converters,\n lexicalNodes: node.children,\n parent: {\n ...node,\n parent,\n },\n req,\n })\n\n return '<' + node?.tag + '>' + childrenText + '</' + node?.tag + '>'\n },\n nodeTypes: [HeadingNode.getType()],\n },\n },\n node: HeadingNode,\n }),\n ],\n sanitizedServerFeatureProps: props,\n }\n },\n key: 'heading',\n})\n"],"names":["HeadingNode","HeadingFeatureClient","createServerFeature","convertLexicalNodesToHTML","createNode","i18n","MarkdownTransformer","HeadingFeature","feature","props","enabledHeadingSizes","ClientFeature","clientFeatureProps","markdownTransformers","nodes","converters","html","converter","node","parent","req","childrenText","lexicalNodes","children","tag","nodeTypes","getType","sanitizedServerFeatureProps","key"],"mappings":"AAEA,SAASA,WAAW,QAAQ,qBAAoB;AAEhD,+DAA+D;AAC/D,SAASC,oBAAoB,QAAQ,gCAA+B;AACpE,SAASC,mBAAmB,QAAQ,yCAAwC;AAC5E,SAASC,yBAAyB,QAAQ,wCAAuC;AACjF,SAASC,UAAU,QAAQ,sBAAqB;AAChD,SAASC,IAAI,QAAQ,YAAW;AAChC,SAASC,mBAAmB,QAAQ,2BAA0B;AAM9D,OAAO,MAAMC,iBAAiBL,oBAI5B;IACAM,SAAS,CAAC,EAAEC,KAAK,EAAE;QACjB,IAAI,CAACA,OAAO;YACVA,QAAQ,CAAC;QACX;QAEA,MAAM,EAAEC,sBAAsB;YAAC;YAAM;YAAM;YAAM;YAAM;YAAM;SAAK,EAAE,GAAGD;QAEvE,OAAO;YACLE,eAAeV;YACfW,oBAAoBH;YACpBJ;YACAQ,sBAAsB;gBAACP,oBAAoBI;aAAqB;YAChEI,OAAO;gBACLV,WAAW;oBACTW,YAAY;wBACVC,MAAM;4BACJC,WAAW,OAAO,EAAEF,UAAU,EAAEG,IAAI,EAAEC,MAAM,EAAEC,GAAG,EAAE;gCACjD,MAAMC,eAAe,MAAMlB,0BAA0B;oCACnDY;oCACAO,cAAcJ,KAAKK,QAAQ;oCAC3BJ,QAAQ;wCACN,GAAGD,IAAI;wCACPC;oCACF;oCACAC;gCACF;gCAEA,OAAO,MAAMF,MAAMM,MAAM,MAAMH,eAAe,OAAOH,MAAMM,MAAM;4BACnE;4BACAC,WAAW;gCAACzB,YAAY0B,OAAO;6BAAG;wBACpC;oBACF;oBACAR,MAAMlB;gBACR;aACD;YACD2B,6BAA6BlB;QAC/B;IACF;IACAmB,KAAK;AACP,GAAE"}
@@ -48,13 +48,13 @@ export const i18n = {
48
48
  label: '[SURAT]\n\nKepala {{headingLevel}}'
49
49
  },
50
50
  nb: {
51
- label: 'Overskrift {{overskriftsnivå}}'
51
+ label: 'Overskrift {{headingLevel}}'
52
52
  },
53
53
  nl: {
54
54
  label: 'Kop {{headingLevel}}'
55
55
  },
56
56
  pl: {
57
- label: 'Nagłówek {{poziom nagłówka}}'
57
+ label: 'Nagłówek {{headingLevel}}'
58
58
  },
59
59
  pt: {
60
60
  label: 'Cabeçalho {{headingLevel}}'
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/features/heading/i18n.ts"],"sourcesContent":["import type { GenericLanguages } from '@payloadcms/translations'\n\nexport const i18n: Partial<GenericLanguages> = {\n ar: {\n label: 'العنوان {{headingLevel}}',\n },\n az: {\n label: 'Başlıq {{headingLevel}}',\n },\n bg: {\n label: 'Заглавие {{headingLevel}}',\n },\n cs: {\n label: 'Nadpis {{headingLevel}}',\n },\n de: {\n label: 'Überschrift {{headingLevel}}',\n },\n en: {\n label: 'Heading {{headingLevel}}',\n },\n es: {\n label: 'Encabezado {{headingLevel}}',\n },\n fa: {\n label: '[SKIPPED]',\n },\n fr: {\n label: 'En-tête {{headingLevel}}',\n },\n he: {\n label: 'כותרת {{רמת כותרת}}',\n },\n hr: {\n label: 'Naslov {{headingLevel}}',\n },\n hu: {\n label: 'Címsor {{headingLevel}}',\n },\n it: {\n label: 'Intestazione {{headingLevel}}',\n },\n ja: {\n label: '見出し{{headingLevel}}',\n },\n ko: {\n label: '제목 {{headingLevel}}',\n },\n my: {\n label: '[SURAT]\\n\\nKepala {{headingLevel}}',\n },\n nb: {\n label: 'Overskrift {{overskriftsnivå}}',\n },\n nl: {\n label: 'Kop {{headingLevel}}',\n },\n pl: {\n label: 'Nagłówek {{poziom nagłówka}}',\n },\n pt: {\n label: 'Cabeçalho {{headingLevel}}',\n },\n ro: {\n label: 'Titlu {{headingLevel}}',\n },\n rs: {\n label: 'Naslov {{headingLevel}}',\n },\n 'rs-latin': {\n label: 'Naslov {{headingLevel}}',\n },\n ru: {\n label: 'Заголовок {{headingLevel}}',\n },\n sk: {\n label: 'Nadpis {{headingLevel}}',\n },\n sv: {\n label: 'Rubrik {{headingLevel}}',\n },\n th: {\n label: 'หัวข้อ {{headingLevel}}',\n },\n tr: {\n label: 'Başlık {{headingLevel}}',\n },\n uk: {\n label: 'Заголовок {{headingLevel}}',\n },\n vi: {\n label: 'Tiêu đề {{headingLevel}}',\n },\n zh: {\n label: '标题 {{headingLevel}}',\n },\n 'zh-TW': {\n label: '標題 {{headingLevel}}',\n },\n}\n"],"names":["i18n","ar","label","az","bg","cs","de","en","es","fa","fr","he","hr","hu","it","ja","ko","my","nb","nl","pl","pt","ro","rs","ru","sk","sv","th","tr","uk","vi","zh"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAEA,OAAO,MAAMA,OAAkC;IAC7CC,IAAI;QACFC,OAAO;IACT;IACAC,IAAI;QACFD,OAAO;IACT;IACAE,IAAI;QACFF,OAAO;IACT;IACAG,IAAI;QACFH,OAAO;IACT;IACAI,IAAI;QACFJ,OAAO;IACT;IACAK,IAAI;QACFL,OAAO;IACT;IACAM,IAAI;QACFN,OAAO;IACT;IACAO,IAAI;QACFP,OAAO;IACT;IACAQ,IAAI;QACFR,OAAO;IACT;IACAS,IAAI;QACFT,OAAO;IACT;IACAU,IAAI;QACFV,OAAO;IACT;IACAW,IAAI;QACFX,OAAO;IACT;IACAY,IAAI;QACFZ,OAAO;IACT;IACAa,IAAI;QACFb,OAAO;IACT;IACAc,IAAI;QACFd,OAAO;IACT;IACAe,IAAI;QACFf,OAAO;IACT;IACAgB,IAAI;QACFhB,OAAO;IACT;IACAiB,IAAI;QACFjB,OAAO;IACT;IACAkB,IAAI;QACFlB,OAAO;IACT;IACAmB,IAAI;QACFnB,OAAO;IACT;IACAoB,IAAI;QACFpB,OAAO;IACT;IACAqB,IAAI;QACFrB,OAAO;IACT;IACA,YAAY;QACVA,OAAO;IACT;IACAsB,IAAI;QACFtB,OAAO;IACT;IACAuB,IAAI;QACFvB,OAAO;IACT;IACAwB,IAAI;QACFxB,OAAO;IACT;IACAyB,IAAI;QACFzB,OAAO;IACT;IACA0B,IAAI;QACF1B,OAAO;IACT;IACA2B,IAAI;QACF3B,OAAO;IACT;IACA4B,IAAI;QACF5B,OAAO;IACT;IACA6B,IAAI;QACF7B,OAAO;IACT;IACA,SAAS;QACPA,OAAO;IACT;AACF,EAAC"}
1
+ {"version":3,"sources":["../../../src/features/heading/i18n.ts"],"sourcesContent":["import type { GenericLanguages } from '@payloadcms/translations'\n\nexport const i18n: Partial<GenericLanguages> = {\n ar: {\n label: 'العنوان {{headingLevel}}',\n },\n az: {\n label: 'Başlıq {{headingLevel}}',\n },\n bg: {\n label: 'Заглавие {{headingLevel}}',\n },\n cs: {\n label: 'Nadpis {{headingLevel}}',\n },\n de: {\n label: 'Überschrift {{headingLevel}}',\n },\n en: {\n label: 'Heading {{headingLevel}}',\n },\n es: {\n label: 'Encabezado {{headingLevel}}',\n },\n fa: {\n label: '[SKIPPED]',\n },\n fr: {\n label: 'En-tête {{headingLevel}}',\n },\n he: {\n label: 'כותרת {{רמת כותרת}}',\n },\n hr: {\n label: 'Naslov {{headingLevel}}',\n },\n hu: {\n label: 'Címsor {{headingLevel}}',\n },\n it: {\n label: 'Intestazione {{headingLevel}}',\n },\n ja: {\n label: '見出し{{headingLevel}}',\n },\n ko: {\n label: '제목 {{headingLevel}}',\n },\n my: {\n label: '[SURAT]\\n\\nKepala {{headingLevel}}',\n },\n nb: {\n label: 'Overskrift {{headingLevel}}',\n },\n nl: {\n label: 'Kop {{headingLevel}}',\n },\n pl: {\n label: 'Nagłówek {{headingLevel}}',\n },\n pt: {\n label: 'Cabeçalho {{headingLevel}}',\n },\n ro: {\n label: 'Titlu {{headingLevel}}',\n },\n rs: {\n label: 'Naslov {{headingLevel}}',\n },\n 'rs-latin': {\n label: 'Naslov {{headingLevel}}',\n },\n ru: {\n label: 'Заголовок {{headingLevel}}',\n },\n sk: {\n label: 'Nadpis {{headingLevel}}',\n },\n sv: {\n label: 'Rubrik {{headingLevel}}',\n },\n th: {\n label: 'หัวข้อ {{headingLevel}}',\n },\n tr: {\n label: 'Başlık {{headingLevel}}',\n },\n uk: {\n label: 'Заголовок {{headingLevel}}',\n },\n vi: {\n label: 'Tiêu đề {{headingLevel}}',\n },\n zh: {\n label: '标题 {{headingLevel}}',\n },\n 'zh-TW': {\n label: '標題 {{headingLevel}}',\n },\n}\n"],"names":["i18n","ar","label","az","bg","cs","de","en","es","fa","fr","he","hr","hu","it","ja","ko","my","nb","nl","pl","pt","ro","rs","ru","sk","sv","th","tr","uk","vi","zh"],"mappings":"AAEA,OAAO,MAAMA,OAAkC;IAC7CC,IAAI;QACFC,OAAO;IACT;IACAC,IAAI;QACFD,OAAO;IACT;IACAE,IAAI;QACFF,OAAO;IACT;IACAG,IAAI;QACFH,OAAO;IACT;IACAI,IAAI;QACFJ,OAAO;IACT;IACAK,IAAI;QACFL,OAAO;IACT;IACAM,IAAI;QACFN,OAAO;IACT;IACAO,IAAI;QACFP,OAAO;IACT;IACAQ,IAAI;QACFR,OAAO;IACT;IACAS,IAAI;QACFT,OAAO;IACT;IACAU,IAAI;QACFV,OAAO;IACT;IACAW,IAAI;QACFX,OAAO;IACT;IACAY,IAAI;QACFZ,OAAO;IACT;IACAa,IAAI;QACFb,OAAO;IACT;IACAc,IAAI;QACFd,OAAO;IACT;IACAe,IAAI;QACFf,OAAO;IACT;IACAgB,IAAI;QACFhB,OAAO;IACT;IACAiB,IAAI;QACFjB,OAAO;IACT;IACAkB,IAAI;QACFlB,OAAO;IACT;IACAmB,IAAI;QACFnB,OAAO;IACT;IACAoB,IAAI;QACFpB,OAAO;IACT;IACAqB,IAAI;QACFrB,OAAO;IACT;IACA,YAAY;QACVA,OAAO;IACT;IACAsB,IAAI;QACFtB,OAAO;IACT;IACAuB,IAAI;QACFvB,OAAO;IACT;IACAwB,IAAI;QACFxB,OAAO;IACT;IACAyB,IAAI;QACFzB,OAAO;IACT;IACA0B,IAAI;QACF1B,OAAO;IACT;IACA2B,IAAI;QACF3B,OAAO;IACT;IACA4B,IAAI;QACF5B,OAAO;IACT;IACA6B,IAAI;QACF7B,OAAO;IACT;IACA,SAAS;QACPA,OAAO;IACT;AACF,EAAC"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/features/heading/markdownTransformer.ts"],"sourcesContent":["import type { ElementTransformer } from '@lexical/markdown'\nimport type { HeadingTagType } from '@lexical/rich-text'\n\nimport { $createHeadingNode, $isHeadingNode, HeadingNode } from '@lexical/rich-text'\n\nimport { createBlockNode } from '../../lexical/utils/markdown/createBlockNode.js'\n\nexport const MarkdownTransformer: (enabledHeadingSizes: HeadingTagType[]) => ElementTransformer = (\n enabledHeadingSizes,\n) => {\n // Convert enabledHeadingSizes to a list of numbers (1 for h1, 2 for h2, etc.)\n const enabledSizes = enabledHeadingSizes.map((tag) => Number(tag.slice(1)))\n\n // Create a regex pattern that matches any of the enabled sizes\n const pattern = `^(${enabledSizes.map((size) => `#{${size}}`).join('|')})\\\\s`\n const regExp = new RegExp(pattern)\n\n return {\n type: 'element',\n dependencies: [HeadingNode],\n export: (node, exportChildren) => {\n if (!$isHeadingNode(node)) {\n return null\n }\n const level = Number(node.getTag().slice(1))\n return '#'.repeat(level) + ' ' + exportChildren(node)\n },\n regExp,\n replace: createBlockNode((match) => {\n const tag = ('h' + match[1].length) as HeadingTagType\n return $createHeadingNode(tag)\n }),\n }\n}\n"],"names":["$createHeadingNode","$isHeadingNode","HeadingNode","createBlockNode","MarkdownTransformer","enabledHeadingSizes","enabledSizes","map","tag","Number","slice","pattern","size","join","regExp","RegExp","type","dependencies","export","node","exportChildren","level","getTag","repeat","replace","match","length"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAGA,SAASA,kBAAkB,EAAEC,cAAc,EAAEC,WAAW,QAAQ,qBAAoB;AAEpF,SAASC,eAAe,QAAQ,kDAAiD;AAEjF,OAAO,MAAMC,sBAAqF,CAChGC;IAEA,8EAA8E;IAC9E,MAAMC,eAAeD,oBAAoBE,GAAG,CAAC,CAACC,MAAQC,OAAOD,IAAIE,KAAK,CAAC;IAEvE,+DAA+D;IAC/D,MAAMC,UAAU,CAAC,EAAE,EAAEL,aAAaC,GAAG,CAAC,CAACK,OAAS,CAAC,EAAE,EAAEA,KAAK,CAAC,CAAC,EAAEC,IAAI,CAAC,KAAK,IAAI,CAAC;IAC7E,MAAMC,SAAS,IAAIC,OAAOJ;IAE1B,OAAO;QACLK,MAAM;QACNC,cAAc;YAACf;SAAY;QAC3BgB,QAAQ,CAACC,MAAMC;YACb,IAAI,CAACnB,eAAekB,OAAO;gBACzB,OAAO;YACT;YACA,MAAME,QAAQZ,OAAOU,KAAKG,MAAM,GAAGZ,KAAK,CAAC;YACzC,OAAO,IAAIa,MAAM,CAACF,SAAS,MAAMD,eAAeD;QAClD;QACAL;QACAU,SAASrB,gBAAgB,CAACsB;YACxB,MAAMjB,MAAO,MAAMiB,KAAK,CAAC,EAAE,CAACC,MAAM;YAClC,OAAO1B,mBAAmBQ;QAC5B;IACF;AACF,EAAC"}
1
+ {"version":3,"sources":["../../../src/features/heading/markdownTransformer.ts"],"sourcesContent":["import type { ElementTransformer } from '@lexical/markdown'\nimport type { HeadingTagType } from '@lexical/rich-text'\n\nimport { $createHeadingNode, $isHeadingNode, HeadingNode } from '@lexical/rich-text'\n\nimport { createBlockNode } from '../../lexical/utils/markdown/createBlockNode.js'\n\nexport const MarkdownTransformer: (enabledHeadingSizes: HeadingTagType[]) => ElementTransformer = (\n enabledHeadingSizes,\n) => {\n // Convert enabledHeadingSizes to a list of numbers (1 for h1, 2 for h2, etc.)\n const enabledSizes = enabledHeadingSizes.map((tag) => Number(tag.slice(1)))\n\n // Create a regex pattern that matches any of the enabled sizes\n const pattern = `^(${enabledSizes.map((size) => `#{${size}}`).join('|')})\\\\s`\n const regExp = new RegExp(pattern)\n\n return {\n type: 'element',\n dependencies: [HeadingNode],\n export: (node, exportChildren) => {\n if (!$isHeadingNode(node)) {\n return null\n }\n const level = Number(node.getTag().slice(1))\n return '#'.repeat(level) + ' ' + exportChildren(node)\n },\n regExp,\n replace: createBlockNode((match) => {\n const tag = ('h' + match[1].length) as HeadingTagType\n return $createHeadingNode(tag)\n }),\n }\n}\n"],"names":["$createHeadingNode","$isHeadingNode","HeadingNode","createBlockNode","MarkdownTransformer","enabledHeadingSizes","enabledSizes","map","tag","Number","slice","pattern","size","join","regExp","RegExp","type","dependencies","export","node","exportChildren","level","getTag","repeat","replace","match","length"],"mappings":"AAGA,SAASA,kBAAkB,EAAEC,cAAc,EAAEC,WAAW,QAAQ,qBAAoB;AAEpF,SAASC,eAAe,QAAQ,kDAAiD;AAEjF,OAAO,MAAMC,sBAAqF,CAChGC;IAEA,8EAA8E;IAC9E,MAAMC,eAAeD,oBAAoBE,GAAG,CAAC,CAACC,MAAQC,OAAOD,IAAIE,KAAK,CAAC;IAEvE,+DAA+D;IAC/D,MAAMC,UAAU,CAAC,EAAE,EAAEL,aAAaC,GAAG,CAAC,CAACK,OAAS,CAAC,EAAE,EAAEA,KAAK,CAAC,CAAC,EAAEC,IAAI,CAAC,KAAK,IAAI,CAAC;IAC7E,MAAMC,SAAS,IAAIC,OAAOJ;IAE1B,OAAO;QACLK,MAAM;QACNC,cAAc;YAACf;SAAY;QAC3BgB,QAAQ,CAACC,MAAMC;YACb,IAAI,CAACnB,eAAekB,OAAO;gBACzB,OAAO;YACT;YACA,MAAME,QAAQZ,OAAOU,KAAKG,MAAM,GAAGZ,KAAK,CAAC;YACzC,OAAO,IAAIa,MAAM,CAACF,SAAS,MAAMD,eAAeD;QAClD;QACAL;QACAU,SAASrB,gBAAgB,CAACsB;YACxB,MAAMjB,MAAO,MAAMiB,KAAK,CAAC,EAAE,CAACC,MAAM;YAClC,OAAO1B,mBAAmBQ;QAC5B;IACF;AACF,EAAC"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/features/horizontalRule/component/index.tsx"],"sourcesContent":["'use client'\n\nimport type { NodeKey } from 'lexical'\n\nimport { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext.js'\nimport { useLexicalNodeSelection } from '@lexical/react/useLexicalNodeSelection.js'\nimport { addClassNamesToElement, mergeRegister, removeClassNamesFromElement } from '@lexical/utils'\nimport {\n $getNodeByKey,\n $getSelection,\n $isNodeSelection,\n CLICK_COMMAND,\n COMMAND_PRIORITY_LOW,\n KEY_BACKSPACE_COMMAND,\n KEY_DELETE_COMMAND,\n} from 'lexical'\nimport { useCallback, useEffect } from 'react'\n\nimport { $isHorizontalRuleNode } from '../nodes/HorizontalRuleNode.js'\n\nconst isSelectedClassName = 'selected'\n\n/**\n * React component rendered in the lexical editor, WITHIN the hr element created by createDOM of the HorizontalRuleNode.\n *\n * @param nodeKey every node has a unique key (this key is not saved to the database and thus may differ between sessions). It's useful for working with the CURRENT lexical editor state\n */\nexport function HorizontalRuleComponent({ nodeKey }: { nodeKey: NodeKey }) {\n const [editor] = useLexicalComposerContext()\n const [isSelected, setSelected, clearSelection] = useLexicalNodeSelection(nodeKey)\n\n const $onDelete = useCallback(\n (event: KeyboardEvent) => {\n if (isSelected && $isNodeSelection($getSelection())) {\n event.preventDefault()\n const node = $getNodeByKey(nodeKey)\n if ($isHorizontalRuleNode(node)) {\n node.remove()\n return true\n }\n }\n return false\n },\n [isSelected, nodeKey],\n )\n\n useEffect(() => {\n return mergeRegister(\n editor.registerCommand(\n CLICK_COMMAND,\n (event: MouseEvent) => {\n const hrElem = editor.getElementByKey(nodeKey)\n\n if (event.target === hrElem) {\n if (!event.shiftKey) {\n clearSelection()\n }\n setSelected(!isSelected)\n return true\n }\n\n return false\n },\n COMMAND_PRIORITY_LOW,\n ),\n editor.registerCommand(KEY_DELETE_COMMAND, $onDelete, COMMAND_PRIORITY_LOW),\n editor.registerCommand(KEY_BACKSPACE_COMMAND, $onDelete, COMMAND_PRIORITY_LOW),\n )\n }, [clearSelection, editor, isSelected, nodeKey, $onDelete, setSelected])\n\n useEffect(() => {\n const hrElem = editor.getElementByKey(nodeKey)\n if (hrElem !== null) {\n if (isSelected) {\n addClassNamesToElement(hrElem, isSelectedClassName)\n } else {\n removeClassNamesFromElement(hrElem, isSelectedClassName)\n }\n }\n }, [editor, isSelected, nodeKey])\n\n return null\n}\n"],"names":["useLexicalComposerContext","useLexicalNodeSelection","addClassNamesToElement","mergeRegister","removeClassNamesFromElement","$getNodeByKey","$getSelection","$isNodeSelection","CLICK_COMMAND","COMMAND_PRIORITY_LOW","KEY_BACKSPACE_COMMAND","KEY_DELETE_COMMAND","useCallback","useEffect","$isHorizontalRuleNode","isSelectedClassName","HorizontalRuleComponent","nodeKey","editor","isSelected","setSelected","clearSelection","$onDelete","event","preventDefault","node","remove","registerCommand","hrElem","getElementByKey","target","shiftKey"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA;AAIA,SAASA,yBAAyB,QAAQ,2CAA0C;AACpF,SAASC,uBAAuB,QAAQ,4CAA2C;AACnF,SAASC,sBAAsB,EAAEC,aAAa,EAAEC,2BAA2B,QAAQ,iBAAgB;AACnG,SACEC,aAAa,EACbC,aAAa,EACbC,gBAAgB,EAChBC,aAAa,EACbC,oBAAoB,EACpBC,qBAAqB,EACrBC,kBAAkB,QACb,UAAS;AAChB,SAASC,WAAW,EAAEC,SAAS,QAAQ,QAAO;AAE9C,SAASC,qBAAqB,QAAQ,iCAAgC;AAEtE,MAAMC,sBAAsB;AAE5B;;;;CAIC,GACD,OAAO,SAASC,wBAAwB,EAAEC,OAAO,EAAwB;IACvE,MAAM,CAACC,OAAO,GAAGlB;IACjB,MAAM,CAACmB,YAAYC,aAAaC,eAAe,GAAGpB,wBAAwBgB;IAE1E,MAAMK,YAAYV,YAChB,CAACW;QACC,IAAIJ,cAAcZ,iBAAiBD,kBAAkB;YACnDiB,MAAMC,cAAc;YACpB,MAAMC,OAAOpB,cAAcY;YAC3B,IAAIH,sBAAsBW,OAAO;gBAC/BA,KAAKC,MAAM;gBACX,OAAO;YACT;QACF;QACA,OAAO;IACT,GACA;QAACP;QAAYF;KAAQ;IAGvBJ,UAAU;QACR,OAAOV,cACLe,OAAOS,eAAe,CACpBnB,eACA,CAACe;YACC,MAAMK,SAASV,OAAOW,eAAe,CAACZ;YAEtC,IAAIM,MAAMO,MAAM,KAAKF,QAAQ;gBAC3B,IAAI,CAACL,MAAMQ,QAAQ,EAAE;oBACnBV;gBACF;gBACAD,YAAY,CAACD;gBACb,OAAO;YACT;YAEA,OAAO;QACT,GACAV,uBAEFS,OAAOS,eAAe,CAAChB,oBAAoBW,WAAWb,uBACtDS,OAAOS,eAAe,CAACjB,uBAAuBY,WAAWb;IAE7D,GAAG;QAACY;QAAgBH;QAAQC;QAAYF;QAASK;QAAWF;KAAY;IAExEP,UAAU;QACR,MAAMe,SAASV,OAAOW,eAAe,CAACZ;QACtC,IAAIW,WAAW,MAAM;YACnB,IAAIT,YAAY;gBACdjB,uBAAuB0B,QAAQb;YACjC,OAAO;gBACLX,4BAA4BwB,QAAQb;YACtC;QACF;IACF,GAAG;QAACG;QAAQC;QAAYF;KAAQ;IAEhC,OAAO;AACT"}
1
+ {"version":3,"sources":["../../../../src/features/horizontalRule/component/index.tsx"],"sourcesContent":["'use client'\n\nimport type { NodeKey } from 'lexical'\n\nimport { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext.js'\nimport { useLexicalNodeSelection } from '@lexical/react/useLexicalNodeSelection.js'\nimport { addClassNamesToElement, mergeRegister, removeClassNamesFromElement } from '@lexical/utils'\nimport {\n $getNodeByKey,\n $getSelection,\n $isNodeSelection,\n CLICK_COMMAND,\n COMMAND_PRIORITY_LOW,\n KEY_BACKSPACE_COMMAND,\n KEY_DELETE_COMMAND,\n} from 'lexical'\nimport { useCallback, useEffect } from 'react'\n\nimport { $isHorizontalRuleNode } from '../nodes/HorizontalRuleNode.js'\n\nconst isSelectedClassName = 'selected'\n\n/**\n * React component rendered in the lexical editor, WITHIN the hr element created by createDOM of the HorizontalRuleNode.\n *\n * @param nodeKey every node has a unique key (this key is not saved to the database and thus may differ between sessions). It's useful for working with the CURRENT lexical editor state\n */\nexport function HorizontalRuleComponent({ nodeKey }: { nodeKey: NodeKey }) {\n const [editor] = useLexicalComposerContext()\n const [isSelected, setSelected, clearSelection] = useLexicalNodeSelection(nodeKey)\n\n const $onDelete = useCallback(\n (event: KeyboardEvent) => {\n if (isSelected && $isNodeSelection($getSelection())) {\n event.preventDefault()\n const node = $getNodeByKey(nodeKey)\n if ($isHorizontalRuleNode(node)) {\n node.remove()\n return true\n }\n }\n return false\n },\n [isSelected, nodeKey],\n )\n\n useEffect(() => {\n return mergeRegister(\n editor.registerCommand(\n CLICK_COMMAND,\n (event: MouseEvent) => {\n const hrElem = editor.getElementByKey(nodeKey)\n\n if (event.target === hrElem) {\n if (!event.shiftKey) {\n clearSelection()\n }\n setSelected(!isSelected)\n return true\n }\n\n return false\n },\n COMMAND_PRIORITY_LOW,\n ),\n editor.registerCommand(KEY_DELETE_COMMAND, $onDelete, COMMAND_PRIORITY_LOW),\n editor.registerCommand(KEY_BACKSPACE_COMMAND, $onDelete, COMMAND_PRIORITY_LOW),\n )\n }, [clearSelection, editor, isSelected, nodeKey, $onDelete, setSelected])\n\n useEffect(() => {\n const hrElem = editor.getElementByKey(nodeKey)\n if (hrElem !== null) {\n if (isSelected) {\n addClassNamesToElement(hrElem, isSelectedClassName)\n } else {\n removeClassNamesFromElement(hrElem, isSelectedClassName)\n }\n }\n }, [editor, isSelected, nodeKey])\n\n return null\n}\n"],"names":["useLexicalComposerContext","useLexicalNodeSelection","addClassNamesToElement","mergeRegister","removeClassNamesFromElement","$getNodeByKey","$getSelection","$isNodeSelection","CLICK_COMMAND","COMMAND_PRIORITY_LOW","KEY_BACKSPACE_COMMAND","KEY_DELETE_COMMAND","useCallback","useEffect","$isHorizontalRuleNode","isSelectedClassName","HorizontalRuleComponent","nodeKey","editor","isSelected","setSelected","clearSelection","$onDelete","event","preventDefault","node","remove","registerCommand","hrElem","getElementByKey","target","shiftKey"],"mappings":"AAAA;AAIA,SAASA,yBAAyB,QAAQ,2CAA0C;AACpF,SAASC,uBAAuB,QAAQ,4CAA2C;AACnF,SAASC,sBAAsB,EAAEC,aAAa,EAAEC,2BAA2B,QAAQ,iBAAgB;AACnG,SACEC,aAAa,EACbC,aAAa,EACbC,gBAAgB,EAChBC,aAAa,EACbC,oBAAoB,EACpBC,qBAAqB,EACrBC,kBAAkB,QACb,UAAS;AAChB,SAASC,WAAW,EAAEC,SAAS,QAAQ,QAAO;AAE9C,SAASC,qBAAqB,QAAQ,iCAAgC;AAEtE,MAAMC,sBAAsB;AAE5B;;;;CAIC,GACD,OAAO,SAASC,wBAAwB,EAAEC,OAAO,EAAwB;IACvE,MAAM,CAACC,OAAO,GAAGlB;IACjB,MAAM,CAACmB,YAAYC,aAAaC,eAAe,GAAGpB,wBAAwBgB;IAE1E,MAAMK,YAAYV,YAChB,CAACW;QACC,IAAIJ,cAAcZ,iBAAiBD,kBAAkB;YACnDiB,MAAMC,cAAc;YACpB,MAAMC,OAAOpB,cAAcY;YAC3B,IAAIH,sBAAsBW,OAAO;gBAC/BA,KAAKC,MAAM;gBACX,OAAO;YACT;QACF;QACA,OAAO;IACT,GACA;QAACP;QAAYF;KAAQ;IAGvBJ,UAAU;QACR,OAAOV,cACLe,OAAOS,eAAe,CACpBnB,eACA,CAACe;YACC,MAAMK,SAASV,OAAOW,eAAe,CAACZ;YAEtC,IAAIM,MAAMO,MAAM,KAAKF,QAAQ;gBAC3B,IAAI,CAACL,MAAMQ,QAAQ,EAAE;oBACnBV;gBACF;gBACAD,YAAY,CAACD;gBACb,OAAO;YACT;YAEA,OAAO;QACT,GACAV,uBAEFS,OAAOS,eAAe,CAAChB,oBAAoBW,WAAWb,uBACtDS,OAAOS,eAAe,CAACjB,uBAAuBY,WAAWb;IAE7D,GAAG;QAACY;QAAgBH;QAAQC;QAAYF;QAASK;QAAWF;KAAY;IAExEP,UAAU;QACR,MAAMe,SAASV,OAAOW,eAAe,CAACZ;QACtC,IAAIW,WAAW,MAAM;YACnB,IAAIT,YAAY;gBACdjB,uBAAuB0B,QAAQb;YACjC,OAAO;gBACLX,4BAA4BwB,QAAQb;YACtC;QACF;IACF,GAAG;QAACG;QAAQC;QAAYF;KAAQ;IAEhC,OAAO;AACT"}
@@ -1,5 +1,4 @@
1
- /// <reference types="react" resolution-mode="require"/>
2
- export declare const HorizontalRuleFeatureClientComponent: import("react").FC<{
1
+ export declare const HorizontalRuleFeatureClient: import("react").FC<{
3
2
  featureKey: string;
4
3
  order: number;
5
4
  }>;
@@ -1 +1 @@
1
- {"version":3,"file":"feature.client.d.ts","sourceRoot":"","sources":["../../../src/features/horizontalRule/feature.client.tsx"],"names":[],"mappings":";AAgFA,eAAO,MAAM,oCAAoC;;;EAEhD,CAAA"}
1
+ {"version":3,"file":"feature.client.d.ts","sourceRoot":"","sources":["../../../src/features/horizontalRule/feature.client.tsx"],"names":[],"mappings":"AAgBA,eAAO,MAAM,2BAA2B;;;EAmDtC,CAAA"}
@@ -1,77 +1,70 @@
1
1
  'use client';
2
2
  import { $isNodeSelection } from 'lexical';
3
3
  import { HorizontalRuleIcon } from '../../lexical/ui/icons/HorizontalRule/index.js';
4
- import { createClientComponent } from '../createClientComponent.js';
4
+ import { createClientFeature } from '../../utilities/createClientFeature.js';
5
5
  import { slashMenuBasicGroupWithItems } from '../shared/slashMenu/basicGroup.js';
6
6
  import { toolbarAddDropdownGroupWithItems } from '../shared/toolbar/addDropdownGroup.js';
7
7
  import { MarkdownTransformer } from './markdownTransformer.js';
8
8
  import { $isHorizontalRuleNode, HorizontalRuleNode, INSERT_HORIZONTAL_RULE_COMMAND } from './nodes/HorizontalRuleNode.js';
9
9
  import { HorizontalRulePlugin } from './plugin/index.js';
10
- const HorizontalRuleFeatureClient = (props)=>{
11
- return {
12
- clientFeatureProps: props,
13
- feature: ()=>({
14
- clientFeatureProps: props,
15
- markdownTransformers: [
16
- MarkdownTransformer
17
- ],
18
- nodes: [
19
- HorizontalRuleNode
20
- ],
21
- plugins: [
22
- {
23
- Component: HorizontalRulePlugin,
24
- position: 'normal'
10
+ export const HorizontalRuleFeatureClient = createClientFeature({
11
+ markdownTransformers: [
12
+ MarkdownTransformer
13
+ ],
14
+ nodes: [
15
+ HorizontalRuleNode
16
+ ],
17
+ plugins: [
18
+ {
19
+ Component: HorizontalRulePlugin,
20
+ position: 'normal'
21
+ }
22
+ ],
23
+ slashMenu: {
24
+ groups: [
25
+ slashMenuBasicGroupWithItems([
26
+ {
27
+ Icon: HorizontalRuleIcon,
28
+ key: 'horizontalRule',
29
+ keywords: [
30
+ 'hr',
31
+ 'horizontal rule',
32
+ 'line',
33
+ 'separator'
34
+ ],
35
+ label: ({ i18n })=>{
36
+ return i18n.t('lexical:horizontalRule:label');
37
+ },
38
+ onSelect: ({ editor })=>{
39
+ editor.dispatchCommand(INSERT_HORIZONTAL_RULE_COMMAND, undefined);
25
40
  }
26
- ],
27
- slashMenu: {
28
- groups: [
29
- slashMenuBasicGroupWithItems([
30
- {
31
- Icon: HorizontalRuleIcon,
32
- key: 'horizontalRule',
33
- keywords: [
34
- 'hr',
35
- 'horizontal rule',
36
- 'line',
37
- 'separator'
38
- ],
39
- label: ({ i18n })=>{
40
- return i18n.t('lexical:horizontalRule:label');
41
- },
42
- onSelect: ({ editor })=>{
43
- editor.dispatchCommand(INSERT_HORIZONTAL_RULE_COMMAND, undefined);
44
- }
45
- }
46
- ])
47
- ]
48
- },
49
- toolbarFixed: {
50
- groups: [
51
- toolbarAddDropdownGroupWithItems([
52
- {
53
- ChildComponent: HorizontalRuleIcon,
54
- isActive: ({ selection })=>{
55
- if (!$isNodeSelection(selection) || !selection.getNodes().length) {
56
- return false;
57
- }
58
- const firstNode = selection.getNodes()[0];
59
- return $isHorizontalRuleNode(firstNode);
60
- },
61
- key: 'horizontalRule',
62
- label: ({ i18n })=>{
63
- return i18n.t('lexical:horizontalRule:label');
64
- },
65
- onSelect: ({ editor })=>{
66
- editor.dispatchCommand(INSERT_HORIZONTAL_RULE_COMMAND, undefined);
67
- }
68
- }
69
- ])
70
- ]
71
41
  }
72
- })
73
- };
74
- };
75
- export const HorizontalRuleFeatureClientComponent = createClientComponent(HorizontalRuleFeatureClient);
42
+ ])
43
+ ]
44
+ },
45
+ toolbarFixed: {
46
+ groups: [
47
+ toolbarAddDropdownGroupWithItems([
48
+ {
49
+ ChildComponent: HorizontalRuleIcon,
50
+ isActive: ({ selection })=>{
51
+ if (!$isNodeSelection(selection) || !selection.getNodes().length) {
52
+ return false;
53
+ }
54
+ const firstNode = selection.getNodes()[0];
55
+ return $isHorizontalRuleNode(firstNode);
56
+ },
57
+ key: 'horizontalRule',
58
+ label: ({ i18n })=>{
59
+ return i18n.t('lexical:horizontalRule:label');
60
+ },
61
+ onSelect: ({ editor })=>{
62
+ editor.dispatchCommand(INSERT_HORIZONTAL_RULE_COMMAND, undefined);
63
+ }
64
+ }
65
+ ])
66
+ ]
67
+ }
68
+ });
76
69
 
77
70
  //# sourceMappingURL=feature.client.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/features/horizontalRule/feature.client.tsx"],"sourcesContent":["'use client'\n\nimport type { ClientTranslationKeys } from '@payloadcms/translations'\n\nimport { $isNodeSelection } from 'lexical'\n\nimport type { FeatureProviderProviderClient } from '../types.js'\n\nimport { HorizontalRuleIcon } from '../../lexical/ui/icons/HorizontalRule/index.js'\nimport { createClientComponent } from '../createClientComponent.js'\nimport { slashMenuBasicGroupWithItems } from '../shared/slashMenu/basicGroup.js'\nimport { toolbarAddDropdownGroupWithItems } from '../shared/toolbar/addDropdownGroup.js'\nimport { MarkdownTransformer } from './markdownTransformer.js'\nimport {\n $isHorizontalRuleNode,\n HorizontalRuleNode,\n INSERT_HORIZONTAL_RULE_COMMAND,\n} from './nodes/HorizontalRuleNode.js'\nimport { HorizontalRulePlugin } from './plugin/index.js'\n\nconst HorizontalRuleFeatureClient: FeatureProviderProviderClient<undefined> = (props) => {\n return {\n clientFeatureProps: props,\n feature: () => ({\n clientFeatureProps: props,\n markdownTransformers: [MarkdownTransformer],\n nodes: [HorizontalRuleNode],\n plugins: [\n {\n Component: HorizontalRulePlugin,\n position: 'normal',\n },\n ],\n slashMenu: {\n groups: [\n slashMenuBasicGroupWithItems([\n {\n Icon: HorizontalRuleIcon,\n key: 'horizontalRule',\n keywords: ['hr', 'horizontal rule', 'line', 'separator'],\n label: ({ i18n }) => {\n return i18n.t('lexical:horizontalRule:label')\n },\n\n onSelect: ({ editor }) => {\n editor.dispatchCommand(INSERT_HORIZONTAL_RULE_COMMAND, undefined)\n },\n },\n ]),\n ],\n },\n\n toolbarFixed: {\n groups: [\n toolbarAddDropdownGroupWithItems([\n {\n ChildComponent: HorizontalRuleIcon,\n isActive: ({ selection }) => {\n if (!$isNodeSelection(selection) || !selection.getNodes().length) {\n return false\n }\n\n const firstNode = selection.getNodes()[0]\n return $isHorizontalRuleNode(firstNode)\n },\n key: 'horizontalRule',\n label: ({ i18n }) => {\n return i18n.t('lexical:horizontalRule:label')\n },\n onSelect: ({ editor }) => {\n editor.dispatchCommand(INSERT_HORIZONTAL_RULE_COMMAND, undefined)\n },\n },\n ]),\n ],\n },\n }),\n }\n}\n\nexport const HorizontalRuleFeatureClientComponent = createClientComponent(\n HorizontalRuleFeatureClient,\n)\n"],"names":["$isNodeSelection","HorizontalRuleIcon","createClientComponent","slashMenuBasicGroupWithItems","toolbarAddDropdownGroupWithItems","MarkdownTransformer","$isHorizontalRuleNode","HorizontalRuleNode","INSERT_HORIZONTAL_RULE_COMMAND","HorizontalRulePlugin","HorizontalRuleFeatureClient","props","clientFeatureProps","feature","markdownTransformers","nodes","plugins","Component","position","slashMenu","groups","Icon","key","keywords","label","i18n","t","onSelect","editor","dispatchCommand","undefined","toolbarFixed","ChildComponent","isActive","selection","getNodes","length","firstNode","HorizontalRuleFeatureClientComponent"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA;AAIA,SAASA,gBAAgB,QAAQ,UAAS;AAI1C,SAASC,kBAAkB,QAAQ,iDAAgD;AACnF,SAASC,qBAAqB,QAAQ,8BAA6B;AACnE,SAASC,4BAA4B,QAAQ,oCAAmC;AAChF,SAASC,gCAAgC,QAAQ,wCAAuC;AACxF,SAASC,mBAAmB,QAAQ,2BAA0B;AAC9D,SACEC,qBAAqB,EACrBC,kBAAkB,EAClBC,8BAA8B,QACzB,gCAA+B;AACtC,SAASC,oBAAoB,QAAQ,oBAAmB;AAExD,MAAMC,8BAAwE,CAACC;IAC7E,OAAO;QACLC,oBAAoBD;QACpBE,SAAS,IAAO,CAAA;gBACdD,oBAAoBD;gBACpBG,sBAAsB;oBAACT;iBAAoB;gBAC3CU,OAAO;oBAACR;iBAAmB;gBAC3BS,SAAS;oBACP;wBACEC,WAAWR;wBACXS,UAAU;oBACZ;iBACD;gBACDC,WAAW;oBACTC,QAAQ;wBACNjB,6BAA6B;4BAC3B;gCACEkB,MAAMpB;gCACNqB,KAAK;gCACLC,UAAU;oCAAC;oCAAM;oCAAmB;oCAAQ;iCAAY;gCACxDC,OAAO,CAAC,EAAEC,IAAI,EAAE;oCACd,OAAOA,KAAKC,CAAC,CAAC;gCAChB;gCAEAC,UAAU,CAAC,EAAEC,MAAM,EAAE;oCACnBA,OAAOC,eAAe,CAACrB,gCAAgCsB;gCACzD;4BACF;yBACD;qBACF;gBACH;gBAEAC,cAAc;oBACZX,QAAQ;wBACNhB,iCAAiC;4BAC/B;gCACE4B,gBAAgB/B;gCAChBgC,UAAU,CAAC,EAAEC,SAAS,EAAE;oCACtB,IAAI,CAAClC,iBAAiBkC,cAAc,CAACA,UAAUC,QAAQ,GAAGC,MAAM,EAAE;wCAChE,OAAO;oCACT;oCAEA,MAAMC,YAAYH,UAAUC,QAAQ,EAAE,CAAC,EAAE;oCACzC,OAAO7B,sBAAsB+B;gCAC/B;gCACAf,KAAK;gCACLE,OAAO,CAAC,EAAEC,IAAI,EAAE;oCACd,OAAOA,KAAKC,CAAC,CAAC;gCAChB;gCACAC,UAAU,CAAC,EAAEC,MAAM,EAAE;oCACnBA,OAAOC,eAAe,CAACrB,gCAAgCsB;gCACzD;4BACF;yBACD;qBACF;gBACH;YACF,CAAA;IACF;AACF;AAEA,OAAO,MAAMQ,uCAAuCpC,sBAClDQ,6BACD"}
1
+ {"version":3,"sources":["../../../src/features/horizontalRule/feature.client.tsx"],"sourcesContent":["'use client'\n\nimport { $isNodeSelection } from 'lexical'\n\nimport { HorizontalRuleIcon } from '../../lexical/ui/icons/HorizontalRule/index.js'\nimport { createClientFeature } from '../../utilities/createClientFeature.js'\nimport { slashMenuBasicGroupWithItems } from '../shared/slashMenu/basicGroup.js'\nimport { toolbarAddDropdownGroupWithItems } from '../shared/toolbar/addDropdownGroup.js'\nimport { MarkdownTransformer } from './markdownTransformer.js'\nimport {\n $isHorizontalRuleNode,\n HorizontalRuleNode,\n INSERT_HORIZONTAL_RULE_COMMAND,\n} from './nodes/HorizontalRuleNode.js'\nimport { HorizontalRulePlugin } from './plugin/index.js'\n\nexport const HorizontalRuleFeatureClient = createClientFeature({\n markdownTransformers: [MarkdownTransformer],\n nodes: [HorizontalRuleNode],\n plugins: [\n {\n Component: HorizontalRulePlugin,\n position: 'normal',\n },\n ],\n slashMenu: {\n groups: [\n slashMenuBasicGroupWithItems([\n {\n Icon: HorizontalRuleIcon,\n key: 'horizontalRule',\n keywords: ['hr', 'horizontal rule', 'line', 'separator'],\n label: ({ i18n }) => {\n return i18n.t('lexical:horizontalRule:label')\n },\n\n onSelect: ({ editor }) => {\n editor.dispatchCommand(INSERT_HORIZONTAL_RULE_COMMAND, undefined)\n },\n },\n ]),\n ],\n },\n toolbarFixed: {\n groups: [\n toolbarAddDropdownGroupWithItems([\n {\n ChildComponent: HorizontalRuleIcon,\n isActive: ({ selection }) => {\n if (!$isNodeSelection(selection) || !selection.getNodes().length) {\n return false\n }\n\n const firstNode = selection.getNodes()[0]\n return $isHorizontalRuleNode(firstNode)\n },\n key: 'horizontalRule',\n label: ({ i18n }) => {\n return i18n.t('lexical:horizontalRule:label')\n },\n onSelect: ({ editor }) => {\n editor.dispatchCommand(INSERT_HORIZONTAL_RULE_COMMAND, undefined)\n },\n },\n ]),\n ],\n },\n})\n"],"names":["$isNodeSelection","HorizontalRuleIcon","createClientFeature","slashMenuBasicGroupWithItems","toolbarAddDropdownGroupWithItems","MarkdownTransformer","$isHorizontalRuleNode","HorizontalRuleNode","INSERT_HORIZONTAL_RULE_COMMAND","HorizontalRulePlugin","HorizontalRuleFeatureClient","markdownTransformers","nodes","plugins","Component","position","slashMenu","groups","Icon","key","keywords","label","i18n","t","onSelect","editor","dispatchCommand","undefined","toolbarFixed","ChildComponent","isActive","selection","getNodes","length","firstNode"],"mappings":"AAAA;AAEA,SAASA,gBAAgB,QAAQ,UAAS;AAE1C,SAASC,kBAAkB,QAAQ,iDAAgD;AACnF,SAASC,mBAAmB,QAAQ,yCAAwC;AAC5E,SAASC,4BAA4B,QAAQ,oCAAmC;AAChF,SAASC,gCAAgC,QAAQ,wCAAuC;AACxF,SAASC,mBAAmB,QAAQ,2BAA0B;AAC9D,SACEC,qBAAqB,EACrBC,kBAAkB,EAClBC,8BAA8B,QACzB,gCAA+B;AACtC,SAASC,oBAAoB,QAAQ,oBAAmB;AAExD,OAAO,MAAMC,8BAA8BR,oBAAoB;IAC7DS,sBAAsB;QAACN;KAAoB;IAC3CO,OAAO;QAACL;KAAmB;IAC3BM,SAAS;QACP;YACEC,WAAWL;YACXM,UAAU;QACZ;KACD;IACDC,WAAW;QACTC,QAAQ;YACNd,6BAA6B;gBAC3B;oBACEe,MAAMjB;oBACNkB,KAAK;oBACLC,UAAU;wBAAC;wBAAM;wBAAmB;wBAAQ;qBAAY;oBACxDC,OAAO,CAAC,EAAEC,IAAI,EAAE;wBACd,OAAOA,KAAKC,CAAC,CAAC;oBAChB;oBAEAC,UAAU,CAAC,EAAEC,MAAM,EAAE;wBACnBA,OAAOC,eAAe,CAAClB,gCAAgCmB;oBACzD;gBACF;aACD;SACF;IACH;IACAC,cAAc;QACZX,QAAQ;YACNb,iCAAiC;gBAC/B;oBACEyB,gBAAgB5B;oBAChB6B,UAAU,CAAC,EAAEC,SAAS,EAAE;wBACtB,IAAI,CAAC/B,iBAAiB+B,cAAc,CAACA,UAAUC,QAAQ,GAAGC,MAAM,EAAE;4BAChE,OAAO;wBACT;wBAEA,MAAMC,YAAYH,UAAUC,QAAQ,EAAE,CAAC,EAAE;wBACzC,OAAO1B,sBAAsB4B;oBAC/B;oBACAf,KAAK;oBACLE,OAAO,CAAC,EAAEC,IAAI,EAAE;wBACd,OAAOA,KAAKC,CAAC,CAAC;oBAChB;oBACAC,UAAU,CAAC,EAAEC,MAAM,EAAE;wBACnBA,OAAOC,eAAe,CAAClB,gCAAgCmB;oBACzD;gBACF;aACD;SACF;IACH;AACF,GAAE"}
@@ -1,3 +1,2 @@
1
- import type { FeatureProviderProviderServer } from '../types.js';
2
- export declare const HorizontalRuleFeature: FeatureProviderProviderServer<undefined, undefined>;
1
+ export declare const HorizontalRuleFeature: import("../typesServer.js").FeatureProviderProviderServer<undefined, undefined, undefined>;
3
2
  //# sourceMappingURL=feature.server.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"feature.server.d.ts","sourceRoot":"","sources":["../../../src/features/horizontalRule/feature.server.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,aAAa,CAAA;AAShE,eAAO,MAAM,qBAAqB,EAAE,6BAA6B,CAAC,SAAS,EAAE,SAAS,CA4BrF,CAAA"}
1
+ {"version":3,"file":"feature.server.d.ts","sourceRoot":"","sources":["../../../src/features/horizontalRule/feature.server.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,qBAAqB,4FAoBhC,CAAA"}
@@ -1,39 +1,34 @@
1
1
  // eslint-disable-next-line payload/no-imports-from-exports-dir
2
- import { HorizontalRuleFeatureClientComponent } from '../../exports/client/index.js';
2
+ import { HorizontalRuleFeatureClient } from '../../exports/client/index.js';
3
+ import { createServerFeature } from '../../utilities/createServerFeature.js';
3
4
  import { createNode } from '../typeUtilities.js';
4
5
  import { i18n } from './i18n.js';
5
6
  import { MarkdownTransformer } from './markdownTransformer.js';
6
7
  import { HorizontalRuleNode } from './nodes/HorizontalRuleNode.js';
7
- export const HorizontalRuleFeature = (props)=>{
8
- return {
9
- feature: ()=>{
10
- return {
11
- ClientComponent: HorizontalRuleFeatureClientComponent,
12
- i18n,
13
- markdownTransformers: [
14
- MarkdownTransformer
15
- ],
16
- nodes: [
17
- createNode({
18
- converters: {
19
- html: {
20
- converter: ()=>{
21
- return `<hr/>`;
22
- },
23
- nodeTypes: [
24
- HorizontalRuleNode.getType()
25
- ]
26
- }
8
+ export const HorizontalRuleFeature = createServerFeature({
9
+ feature: {
10
+ ClientFeature: HorizontalRuleFeatureClient,
11
+ i18n,
12
+ markdownTransformers: [
13
+ MarkdownTransformer
14
+ ],
15
+ nodes: [
16
+ createNode({
17
+ converters: {
18
+ html: {
19
+ converter: ()=>{
20
+ return `<hr/>`;
27
21
  },
28
- node: HorizontalRuleNode
29
- })
30
- ],
31
- serverFeatureProps: props
32
- };
33
- },
34
- key: 'horizontalRule',
35
- serverFeatureProps: props
36
- };
37
- };
22
+ nodeTypes: [
23
+ HorizontalRuleNode.getType()
24
+ ]
25
+ }
26
+ },
27
+ node: HorizontalRuleNode
28
+ })
29
+ ]
30
+ },
31
+ key: 'horizontalRule'
32
+ });
38
33
 
39
34
  //# sourceMappingURL=feature.server.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/features/horizontalRule/feature.server.ts"],"sourcesContent":["import type { FeatureProviderProviderServer } from '../types.js'\n\n// eslint-disable-next-line payload/no-imports-from-exports-dir\nimport { HorizontalRuleFeatureClientComponent } from '../../exports/client/index.js'\nimport { createNode } from '../typeUtilities.js'\nimport { i18n } from './i18n.js'\nimport { MarkdownTransformer } from './markdownTransformer.js'\nimport { HorizontalRuleNode } from './nodes/HorizontalRuleNode.js'\n\nexport const HorizontalRuleFeature: FeatureProviderProviderServer<undefined, undefined> = (\n props,\n) => {\n return {\n feature: () => {\n return {\n ClientComponent: HorizontalRuleFeatureClientComponent,\n i18n,\n markdownTransformers: [MarkdownTransformer],\n nodes: [\n createNode({\n converters: {\n html: {\n converter: () => {\n return `<hr/>`\n },\n nodeTypes: [HorizontalRuleNode.getType()],\n },\n },\n node: HorizontalRuleNode,\n }),\n ],\n serverFeatureProps: props,\n }\n },\n key: 'horizontalRule',\n serverFeatureProps: props,\n }\n}\n"],"names":["HorizontalRuleFeatureClientComponent","createNode","i18n","MarkdownTransformer","HorizontalRuleNode","HorizontalRuleFeature","props","feature","ClientComponent","markdownTransformers","nodes","converters","html","converter","nodeTypes","getType","node","serverFeatureProps","key"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAEA,+DAA+D;AAC/D,SAASA,oCAAoC,QAAQ,gCAA+B;AACpF,SAASC,UAAU,QAAQ,sBAAqB;AAChD,SAASC,IAAI,QAAQ,YAAW;AAChC,SAASC,mBAAmB,QAAQ,2BAA0B;AAC9D,SAASC,kBAAkB,QAAQ,gCAA+B;AAElE,OAAO,MAAMC,wBAA6E,CACxFC;IAEA,OAAO;QACLC,SAAS;YACP,OAAO;gBACLC,iBAAiBR;gBACjBE;gBACAO,sBAAsB;oBAACN;iBAAoB;gBAC3CO,OAAO;oBACLT,WAAW;wBACTU,YAAY;4BACVC,MAAM;gCACJC,WAAW;oCACT,OAAO,CAAC,KAAK,CAAC;gCAChB;gCACAC,WAAW;oCAACV,mBAAmBW,OAAO;iCAAG;4BAC3C;wBACF;wBACAC,MAAMZ;oBACR;iBACD;gBACDa,oBAAoBX;YACtB;QACF;QACAY,KAAK;QACLD,oBAAoBX;IACtB;AACF,EAAC"}
1
+ {"version":3,"sources":["../../../src/features/horizontalRule/feature.server.ts"],"sourcesContent":["// eslint-disable-next-line payload/no-imports-from-exports-dir\nimport { HorizontalRuleFeatureClient } from '../../exports/client/index.js'\nimport { createServerFeature } from '../../utilities/createServerFeature.js'\nimport { createNode } from '../typeUtilities.js'\nimport { i18n } from './i18n.js'\nimport { MarkdownTransformer } from './markdownTransformer.js'\nimport { HorizontalRuleNode } from './nodes/HorizontalRuleNode.js'\n\nexport const HorizontalRuleFeature = createServerFeature({\n feature: {\n ClientFeature: HorizontalRuleFeatureClient,\n i18n,\n markdownTransformers: [MarkdownTransformer],\n nodes: [\n createNode({\n converters: {\n html: {\n converter: () => {\n return `<hr/>`\n },\n nodeTypes: [HorizontalRuleNode.getType()],\n },\n },\n node: HorizontalRuleNode,\n }),\n ],\n },\n key: 'horizontalRule',\n})\n"],"names":["HorizontalRuleFeatureClient","createServerFeature","createNode","i18n","MarkdownTransformer","HorizontalRuleNode","HorizontalRuleFeature","feature","ClientFeature","markdownTransformers","nodes","converters","html","converter","nodeTypes","getType","node","key"],"mappings":"AAAA,+DAA+D;AAC/D,SAASA,2BAA2B,QAAQ,gCAA+B;AAC3E,SAASC,mBAAmB,QAAQ,yCAAwC;AAC5E,SAASC,UAAU,QAAQ,sBAAqB;AAChD,SAASC,IAAI,QAAQ,YAAW;AAChC,SAASC,mBAAmB,QAAQ,2BAA0B;AAC9D,SAASC,kBAAkB,QAAQ,gCAA+B;AAElE,OAAO,MAAMC,wBAAwBL,oBAAoB;IACvDM,SAAS;QACPC,eAAeR;QACfG;QACAM,sBAAsB;YAACL;SAAoB;QAC3CM,OAAO;YACLR,WAAW;gBACTS,YAAY;oBACVC,MAAM;wBACJC,WAAW;4BACT,OAAO,CAAC,KAAK,CAAC;wBAChB;wBACAC,WAAW;4BAACT,mBAAmBU,OAAO;yBAAG;oBAC3C;gBACF;gBACAC,MAAMX;YACR;SACD;IACH;IACAY,KAAK;AACP,GAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/features/horizontalRule/i18n.ts"],"sourcesContent":["import type { GenericLanguages } from '@payloadcms/translations'\n\nexport const i18n: Partial<GenericLanguages> = {\n ar: {\n label: 'القاعدة الأفقية',\n },\n az: {\n label: 'Üfüqi Xətt',\n },\n bg: {\n label: 'Хоризонтална линия',\n },\n cs: {\n label: 'Vodorovný pravítko',\n },\n de: {\n label: 'Trennlinie',\n },\n en: {\n label: 'Horizontal Rule',\n },\n es: {\n label: 'Regla Horizontal',\n },\n fa: {\n label: 'قاعده افقی',\n },\n fr: {\n label: 'Règle horizontale',\n },\n he: {\n label: 'קו אופקי',\n },\n hr: {\n label: 'Vodoravna linija',\n },\n hu: {\n label: 'Vízszintes vonal',\n },\n it: {\n label: 'Regola Orizzontale',\n },\n ja: {\n label: '水平線',\n },\n ko: {\n label: '수평 규칙',\n },\n my: {\n label: 'Peraturan Mendatar',\n },\n nb: {\n label: 'Horisontal Regel',\n },\n nl: {\n label: 'Horizontale Regel',\n },\n pl: {\n label: 'Pozioma Linia',\n },\n pt: {\n label: 'Regra Horizontal',\n },\n ro: {\n label: 'Linie orizontală',\n },\n rs: {\n label: 'Horizontalna linija',\n },\n 'rs-latin': {\n label: 'Horizontalna linija',\n },\n ru: {\n label: 'Горизонтальная линия',\n },\n sk: {\n label: 'Vodorovná čiara',\n },\n sv: {\n label: 'Horisontell linje',\n },\n th: {\n label: 'กฎขีดตรง',\n },\n tr: {\n label: 'Yatay Çizgi',\n },\n uk: {\n label: 'Горизонтальна лінія',\n },\n vi: {\n label: 'Quy tắc ngang',\n },\n zh: {\n label: '水平线',\n },\n 'zh-TW': {\n label: '水平線',\n },\n}\n"],"names":["i18n","ar","label","az","bg","cs","de","en","es","fa","fr","he","hr","hu","it","ja","ko","my","nb","nl","pl","pt","ro","rs","ru","sk","sv","th","tr","uk","vi","zh"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAEA,OAAO,MAAMA,OAAkC;IAC7CC,IAAI;QACFC,OAAO;IACT;IACAC,IAAI;QACFD,OAAO;IACT;IACAE,IAAI;QACFF,OAAO;IACT;IACAG,IAAI;QACFH,OAAO;IACT;IACAI,IAAI;QACFJ,OAAO;IACT;IACAK,IAAI;QACFL,OAAO;IACT;IACAM,IAAI;QACFN,OAAO;IACT;IACAO,IAAI;QACFP,OAAO;IACT;IACAQ,IAAI;QACFR,OAAO;IACT;IACAS,IAAI;QACFT,OAAO;IACT;IACAU,IAAI;QACFV,OAAO;IACT;IACAW,IAAI;QACFX,OAAO;IACT;IACAY,IAAI;QACFZ,OAAO;IACT;IACAa,IAAI;QACFb,OAAO;IACT;IACAc,IAAI;QACFd,OAAO;IACT;IACAe,IAAI;QACFf,OAAO;IACT;IACAgB,IAAI;QACFhB,OAAO;IACT;IACAiB,IAAI;QACFjB,OAAO;IACT;IACAkB,IAAI;QACFlB,OAAO;IACT;IACAmB,IAAI;QACFnB,OAAO;IACT;IACAoB,IAAI;QACFpB,OAAO;IACT;IACAqB,IAAI;QACFrB,OAAO;IACT;IACA,YAAY;QACVA,OAAO;IACT;IACAsB,IAAI;QACFtB,OAAO;IACT;IACAuB,IAAI;QACFvB,OAAO;IACT;IACAwB,IAAI;QACFxB,OAAO;IACT;IACAyB,IAAI;QACFzB,OAAO;IACT;IACA0B,IAAI;QACF1B,OAAO;IACT;IACA2B,IAAI;QACF3B,OAAO;IACT;IACA4B,IAAI;QACF5B,OAAO;IACT;IACA6B,IAAI;QACF7B,OAAO;IACT;IACA,SAAS;QACPA,OAAO;IACT;AACF,EAAC"}
1
+ {"version":3,"sources":["../../../src/features/horizontalRule/i18n.ts"],"sourcesContent":["import type { GenericLanguages } from '@payloadcms/translations'\n\nexport const i18n: Partial<GenericLanguages> = {\n ar: {\n label: 'القاعدة الأفقية',\n },\n az: {\n label: 'Üfüqi Xətt',\n },\n bg: {\n label: 'Хоризонтална линия',\n },\n cs: {\n label: 'Vodorovný pravítko',\n },\n de: {\n label: 'Trennlinie',\n },\n en: {\n label: 'Horizontal Rule',\n },\n es: {\n label: 'Regla Horizontal',\n },\n fa: {\n label: 'قاعده افقی',\n },\n fr: {\n label: 'Règle horizontale',\n },\n he: {\n label: 'קו אופקי',\n },\n hr: {\n label: 'Vodoravna linija',\n },\n hu: {\n label: 'Vízszintes vonal',\n },\n it: {\n label: 'Regola Orizzontale',\n },\n ja: {\n label: '水平線',\n },\n ko: {\n label: '수평 규칙',\n },\n my: {\n label: 'Peraturan Mendatar',\n },\n nb: {\n label: 'Horisontal Regel',\n },\n nl: {\n label: 'Horizontale Regel',\n },\n pl: {\n label: 'Pozioma Linia',\n },\n pt: {\n label: 'Regra Horizontal',\n },\n ro: {\n label: 'Linie orizontală',\n },\n rs: {\n label: 'Horizontalna linija',\n },\n 'rs-latin': {\n label: 'Horizontalna linija',\n },\n ru: {\n label: 'Горизонтальная линия',\n },\n sk: {\n label: 'Vodorovná čiara',\n },\n sv: {\n label: 'Horisontell linje',\n },\n th: {\n label: 'กฎขีดตรง',\n },\n tr: {\n label: 'Yatay Çizgi',\n },\n uk: {\n label: 'Горизонтальна лінія',\n },\n vi: {\n label: 'Quy tắc ngang',\n },\n zh: {\n label: '水平线',\n },\n 'zh-TW': {\n label: '水平線',\n },\n}\n"],"names":["i18n","ar","label","az","bg","cs","de","en","es","fa","fr","he","hr","hu","it","ja","ko","my","nb","nl","pl","pt","ro","rs","ru","sk","sv","th","tr","uk","vi","zh"],"mappings":"AAEA,OAAO,MAAMA,OAAkC;IAC7CC,IAAI;QACFC,OAAO;IACT;IACAC,IAAI;QACFD,OAAO;IACT;IACAE,IAAI;QACFF,OAAO;IACT;IACAG,IAAI;QACFH,OAAO;IACT;IACAI,IAAI;QACFJ,OAAO;IACT;IACAK,IAAI;QACFL,OAAO;IACT;IACAM,IAAI;QACFN,OAAO;IACT;IACAO,IAAI;QACFP,OAAO;IACT;IACAQ,IAAI;QACFR,OAAO;IACT;IACAS,IAAI;QACFT,OAAO;IACT;IACAU,IAAI;QACFV,OAAO;IACT;IACAW,IAAI;QACFX,OAAO;IACT;IACAY,IAAI;QACFZ,OAAO;IACT;IACAa,IAAI;QACFb,OAAO;IACT;IACAc,IAAI;QACFd,OAAO;IACT;IACAe,IAAI;QACFf,OAAO;IACT;IACAgB,IAAI;QACFhB,OAAO;IACT;IACAiB,IAAI;QACFjB,OAAO;IACT;IACAkB,IAAI;QACFlB,OAAO;IACT;IACAmB,IAAI;QACFnB,OAAO;IACT;IACAoB,IAAI;QACFpB,OAAO;IACT;IACAqB,IAAI;QACFrB,OAAO;IACT;IACA,YAAY;QACVA,OAAO;IACT;IACAsB,IAAI;QACFtB,OAAO;IACT;IACAuB,IAAI;QACFvB,OAAO;IACT;IACAwB,IAAI;QACFxB,OAAO;IACT;IACAyB,IAAI;QACFzB,OAAO;IACT;IACA0B,IAAI;QACF1B,OAAO;IACT;IACA2B,IAAI;QACF3B,OAAO;IACT;IACA4B,IAAI;QACF5B,OAAO;IACT;IACA6B,IAAI;QACF7B,OAAO;IACT;IACA,SAAS;QACPA,OAAO;IACT;AACF,EAAC"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/features/horizontalRule/markdownTransformer.ts"],"sourcesContent":["import type { ElementTransformer } from '@lexical/markdown'\n\nimport {\n $createHorizontalRuleNode,\n $isHorizontalRuleNode,\n HorizontalRuleNode,\n} from './nodes/HorizontalRuleNode.js'\n\nexport const MarkdownTransformer: ElementTransformer = {\n type: 'element',\n dependencies: [HorizontalRuleNode],\n export: (node, exportChildren) => {\n if (!$isHorizontalRuleNode(node)) {\n return null\n }\n return '---'\n },\n // match ---\n regExp: /^---\\s*$/,\n replace: (parentNode) => {\n const node = $createHorizontalRuleNode()\n if (node) {\n parentNode.replace(node)\n }\n },\n}\n"],"names":["$createHorizontalRuleNode","$isHorizontalRuleNode","HorizontalRuleNode","MarkdownTransformer","type","dependencies","export","node","exportChildren","regExp","replace","parentNode"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;","mappings":"AAEA,SACEA,yBAAyB,EACzBC,qBAAqB,EACrBC,kBAAkB,QACb,gCAA+B;AAEtC,OAAO,MAAMC,sBAA0C;IACrDC,MAAM;IACNC,cAAc;QAACH;KAAmB;IAClCI,QAAQ,CAACC,MAAMC;QACb,IAAI,CAACP,sBAAsBM,OAAO;YAChC,OAAO;QACT;QACA,OAAO;IACT;IACA,YAAY;IACZE,QAAQ;IACRC,SAAS,CAACC;QACR,MAAMJ,OAAOP;QACb,IAAIO,MAAM;YACRI,WAAWD,OAAO,CAACH;QACrB;IACF;AACF,EAAC"}
1
+ {"version":3,"sources":["../../../src/features/horizontalRule/markdownTransformer.ts"],"sourcesContent":["import type { ElementTransformer } from '@lexical/markdown'\n\nimport {\n $createHorizontalRuleNode,\n $isHorizontalRuleNode,\n HorizontalRuleNode,\n} from './nodes/HorizontalRuleNode.js'\n\nexport const MarkdownTransformer: ElementTransformer = {\n type: 'element',\n dependencies: [HorizontalRuleNode],\n export: (node, exportChildren) => {\n if (!$isHorizontalRuleNode(node)) {\n return null\n }\n return '---'\n },\n // match ---\n regExp: /^---\\s*$/,\n replace: (parentNode) => {\n const node = $createHorizontalRuleNode()\n if (node) {\n parentNode.replace(node)\n }\n },\n}\n"],"names":["$createHorizontalRuleNode","$isHorizontalRuleNode","HorizontalRuleNode","MarkdownTransformer","type","dependencies","export","node","exportChildren","regExp","replace","parentNode"],"mappings":"AAEA,SACEA,yBAAyB,EACzBC,qBAAqB,EACrBC,kBAAkB,QACb,gCAA+B;AAEtC,OAAO,MAAMC,sBAA0C;IACrDC,MAAM;IACNC,cAAc;QAACH;KAAmB;IAClCI,QAAQ,CAACC,MAAMC;QACb,IAAI,CAACP,sBAAsBM,OAAO;YAChC,OAAO;QACT;QACA,OAAO;IACT;IACA,YAAY;IACZE,QAAQ;IACRC,SAAS,CAACC;QACR,MAAMJ,OAAOP;QACb,IAAIO,MAAM;YACRI,WAAWD,OAAO,CAACH;QACrB;IACF;AACF,EAAC"}
@@ -1,10 +1,13 @@
1
- import type { DOMConversionMap, DOMExportOutput, EditorConfig, LexicalCommand, LexicalNode, SerializedLexicalNode } from 'lexical';
1
+ import type { DOMConversionMap, DOMExportOutput, EditorConfig, LexicalCommand, LexicalNode, SerializedLexicalNode, Spread } from 'lexical';
2
2
  import { DecoratorNode } from 'lexical';
3
3
  import * as React from 'react';
4
4
  /**
5
5
  * Serialized representation of a horizontal rule node. Serialized = converted to JSON. This is what is stored in the database / in the lexical editor state.
6
6
  */
7
- export type SerializedHorizontalRuleNode = SerializedLexicalNode;
7
+ export type SerializedHorizontalRuleNode = Spread<{
8
+ children?: never;
9
+ type: 'horizontalrule';
10
+ }, SerializedLexicalNode>;
8
11
  export declare const INSERT_HORIZONTAL_RULE_COMMAND: LexicalCommand<void>;
9
12
  /**
10
13
  * This node is a DecoratorNode. DecoratorNodes allow you to render React components in the editor.
@@ -1 +1 @@
1
- {"version":3,"file":"HorizontalRuleNode.d.ts","sourceRoot":"","sources":["../../../../src/features/horizontalRule/nodes/HorizontalRuleNode.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,gBAAgB,EAEhB,eAAe,EACf,YAAY,EACZ,cAAc,EACd,WAAW,EACX,qBAAqB,EACtB,MAAM,SAAS,CAAA;AAGhB,OAAO,EAAyB,aAAa,EAAiB,MAAM,SAAS,CAAA;AAC7E,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAQ9B;;GAEG;AACH,MAAM,MAAM,4BAA4B,GAAG,qBAAqB,CAAA;AAEhE,eAAO,MAAM,8BAA8B,EAAE,cAAc,CAAC,IAAI,CAE/D,CAAA;AAED;;;;;;GAMG;AACH,qBAAa,kBAAmB,SAAQ,aAAa,CAAC,KAAK,CAAC,YAAY,CAAC;IACvE,MAAM,CAAC,KAAK,CAAC,IAAI,EAAE,kBAAkB,GAAG,kBAAkB;IAI1D,MAAM,CAAC,OAAO,IAAI,MAAM;IAIxB;;;;OAIG;IACH,MAAM,CAAC,SAAS,IAAI,gBAAgB,GAAG,IAAI;IAS3C;;OAEG;IACH,MAAM,CAAC,UAAU,CAAC,cAAc,EAAE,4BAA4B,GAAG,kBAAkB;IAInF;;OAEG;IACH,SAAS,CAAC,MAAM,EAAE,YAAY,GAAG,WAAW;IAM5C;;OAEG;IACH,QAAQ,IAAI,KAAK,CAAC,YAAY;IAI9B;;;;OAIG;IACH,SAAS,IAAI,eAAe;IAG5B;;OAEG;IACH,UAAU,IAAI,qBAAqB;IAOnC,cAAc,IAAI,MAAM;IAIxB,QAAQ,IAAI,KAAK;IAIjB,SAAS,IAAI,OAAO;CAGrB;AAMD,wBAAgB,yBAAyB,IAAI,kBAAkB,CAE9D;AAED,wBAAgB,qBAAqB,CACnC,IAAI,EAAE,WAAW,GAAG,IAAI,GAAG,SAAS,GACnC,IAAI,IAAI,kBAAkB,CAE5B"}
1
+ {"version":3,"file":"HorizontalRuleNode.d.ts","sourceRoot":"","sources":["../../../../src/features/horizontalRule/nodes/HorizontalRuleNode.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,gBAAgB,EAEhB,eAAe,EACf,YAAY,EACZ,cAAc,EACd,WAAW,EACX,qBAAqB,EACrB,MAAM,EACP,MAAM,SAAS,CAAA;AAGhB,OAAO,EAAyB,aAAa,EAAiB,MAAM,SAAS,CAAA;AAC7E,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAQ9B;;GAEG;AACH,MAAM,MAAM,4BAA4B,GAAG,MAAM,CAC/C;IACE,QAAQ,CAAC,EAAE,KAAK,CAAA;IAChB,IAAI,EAAE,gBAAgB,CAAA;CACvB,EACD,qBAAqB,CACtB,CAAA;AAED,eAAO,MAAM,8BAA8B,EAAE,cAAc,CAAC,IAAI,CAE/D,CAAA;AAED;;;;;;GAMG;AACH,qBAAa,kBAAmB,SAAQ,aAAa,CAAC,KAAK,CAAC,YAAY,CAAC;IACvE,MAAM,CAAC,KAAK,CAAC,IAAI,EAAE,kBAAkB,GAAG,kBAAkB;IAI1D,MAAM,CAAC,OAAO,IAAI,MAAM;IAIxB;;;;OAIG;IACH,MAAM,CAAC,SAAS,IAAI,gBAAgB,GAAG,IAAI;IAS3C;;OAEG;IACH,MAAM,CAAC,UAAU,CAAC,cAAc,EAAE,4BAA4B,GAAG,kBAAkB;IAInF;;OAEG;IACH,SAAS,CAAC,MAAM,EAAE,YAAY,GAAG,WAAW;IAM5C;;OAEG;IACH,QAAQ,IAAI,KAAK,CAAC,YAAY;IAI9B;;;;OAIG;IACH,SAAS,IAAI,eAAe;IAG5B;;OAEG;IACH,UAAU,IAAI,qBAAqB;IAOnC,cAAc,IAAI,MAAM;IAIxB,QAAQ,IAAI,KAAK;IAIjB,SAAS,IAAI,OAAO;CAGrB;AAMD,wBAAgB,yBAAyB,IAAI,kBAAkB,CAE9D;AAED,wBAAgB,qBAAqB,CACnC,IAAI,EAAE,WAAW,GAAG,IAAI,GAAG,SAAS,GACnC,IAAI,IAAI,kBAAkB,CAE5B"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/features/horizontalRule/nodes/HorizontalRuleNode.tsx"],"sourcesContent":["import type {\n DOMConversionMap,\n DOMConversionOutput,\n DOMExportOutput,\n EditorConfig,\n LexicalCommand,\n LexicalNode,\n SerializedLexicalNode,\n} from 'lexical'\n\nimport { addClassNamesToElement } from '@lexical/utils'\nimport { $applyNodeReplacement, DecoratorNode, createCommand } from 'lexical'\nimport * as React from 'react'\n\nconst HorizontalRuleComponent = React.lazy(() =>\n import('../component/index.js').then((module) => ({\n default: module.HorizontalRuleComponent,\n })),\n)\n\n/**\n * Serialized representation of a horizontal rule node. Serialized = converted to JSON. This is what is stored in the database / in the lexical editor state.\n */\nexport type SerializedHorizontalRuleNode = SerializedLexicalNode\n\nexport const INSERT_HORIZONTAL_RULE_COMMAND: LexicalCommand<void> = createCommand(\n 'INSERT_HORIZONTAL_RULE_COMMAND',\n)\n\n/**\n * This node is a DecoratorNode. DecoratorNodes allow you to render React components in the editor.\n *\n * They need both createDom and decorate functions. createDom => outside of the html. decorate => React Component inside of the html.\n *\n * If we used DecoratorBlockNode instead, we would only need a decorate method\n */\nexport class HorizontalRuleNode extends DecoratorNode<React.ReactElement> {\n static clone(node: HorizontalRuleNode): HorizontalRuleNode {\n return new HorizontalRuleNode(node.__key)\n }\n\n static getType(): string {\n return 'horizontalrule'\n }\n\n /**\n * Defines what happens if you copy an hr element from another page and paste it into the lexical editor\n *\n * This also determines the behavior of lexical's internal HTML -> Lexical converter\n */\n static importDOM(): DOMConversionMap | null {\n return {\n hr: () => ({\n conversion: $convertHorizontalRuleElement,\n priority: 0,\n }),\n }\n }\n\n /**\n * The data for this node is stored serialized as JSON. This is the \"load function\" of that node: it takes the saved data and converts it into a node.\n */\n static importJSON(serializedNode: SerializedHorizontalRuleNode): HorizontalRuleNode {\n return $createHorizontalRuleNode()\n }\n\n /**\n * Determines how the hr element is rendered in the lexical editor. This is only the \"initial\" / \"outer\" HTML element.\n */\n createDOM(config: EditorConfig): HTMLElement {\n const element = document.createElement('hr')\n addClassNamesToElement(element, config.theme.hr)\n return element\n }\n\n /**\n * Allows you to render a React component within whatever createDOM returns.\n */\n decorate(): React.ReactElement {\n return <HorizontalRuleComponent nodeKey={this.__key} />\n }\n\n /**\n * Opposite of importDOM, this function defines what happens when you copy an hr element from the lexical editor and paste it into another page.\n *\n * This also determines the behavior of lexical's internal Lexical -> HTML converter\n */\n exportDOM(): DOMExportOutput {\n return { element: document.createElement('hr') }\n }\n /**\n * Opposite of importJSON. This determines what data is saved in the database / in the lexical editor state.\n */\n exportJSON(): SerializedLexicalNode {\n return {\n type: 'horizontalrule',\n version: 1,\n }\n }\n\n getTextContent(): string {\n return '\\n'\n }\n\n isInline(): false {\n return false\n }\n\n updateDOM(): boolean {\n return false\n }\n}\n\nfunction $convertHorizontalRuleElement(): DOMConversionOutput {\n return { node: $createHorizontalRuleNode() }\n}\n\nexport function $createHorizontalRuleNode(): HorizontalRuleNode {\n return $applyNodeReplacement(new HorizontalRuleNode())\n}\n\nexport function $isHorizontalRuleNode(\n node: LexicalNode | null | undefined,\n): node is HorizontalRuleNode {\n return node instanceof HorizontalRuleNode\n}\n"],"names":["addClassNamesToElement","$applyNodeReplacement","DecoratorNode","createCommand","React","HorizontalRuleComponent","lazy","then","module","default","INSERT_HORIZONTAL_RULE_COMMAND","HorizontalRuleNode","clone","node","__key","getType","importDOM","hr","conversion","$convertHorizontalRuleElement","priority","importJSON","serializedNode","$createHorizontalRuleNode","createDOM","config","element","document","createElement","theme","decorate","nodeKey","exportDOM","exportJSON","type","version","getTextContent","isInline","updateDOM","$isHorizontalRuleNode"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";AAUA,SAASA,sBAAsB,QAAQ,iBAAgB;AACvD,SAASC,qBAAqB,EAAEC,aAAa,EAAEC,aAAa,QAAQ,UAAS;AAC7E,YAAYC,WAAW,QAAO;AAE9B,MAAMC,wCAA0BD,MAAME,IAAI,CAAC,IACzC,MAAM,CAAC,yBAAyBC,IAAI,CAAC,CAACC,SAAY,CAAA;YAChDC,SAASD,OAAOH,uBAAuB;QACzC,CAAA;AAQF,OAAO,MAAMK,iCAAuDP,cAClE,kCACD;AAED;;;;;;CAMC,GACD,OAAO,MAAMQ,2BAA2BT;IACtC,OAAOU,MAAMC,IAAwB,EAAsB;QACzD,OAAO,IAAIF,mBAAmBE,KAAKC,KAAK;IAC1C;IAEA,OAAOC,UAAkB;QACvB,OAAO;IACT;IAEA;;;;GAIC,GACD,OAAOC,YAAqC;QAC1C,OAAO;YACLC,IAAI,IAAO,CAAA;oBACTC,YAAYC;oBACZC,UAAU;gBACZ,CAAA;QACF;IACF;IAEA;;GAEC,GACD,OAAOC,WAAWC,cAA4C,EAAsB;QAClF,OAAOC;IACT;IAEA;;GAEC,GACDC,UAAUC,MAAoB,EAAe;QAC3C,MAAMC,UAAUC,SAASC,aAAa,CAAC;QACvC5B,uBAAuB0B,SAASD,OAAOI,KAAK,CAACZ,EAAE;QAC/C,OAAOS;IACT;IAEA;;GAEC,GACDI,WAA+B;QAC7B,qBAAO,KAACzB;YAAwB0B,SAAS,IAAI,CAACjB,KAAK;;IACrD;IAEA;;;;GAIC,GACDkB,YAA6B;QAC3B,OAAO;YAAEN,SAASC,SAASC,aAAa,CAAC;QAAM;IACjD;IACA;;GAEC,GACDK,aAAoC;QAClC,OAAO;YACLC,MAAM;YACNC,SAAS;QACX;IACF;IAEAC,iBAAyB;QACvB,OAAO;IACT;IAEAC,WAAkB;QAChB,OAAO;IACT;IAEAC,YAAqB;QACnB,OAAO;IACT;AACF;AAEA,SAASnB;IACP,OAAO;QAAEN,MAAMU;IAA4B;AAC7C;AAEA,OAAO,SAASA;IACd,OAAOtB,sBAAsB,IAAIU;AACnC;AAEA,OAAO,SAAS4B,sBACd1B,IAAoC;IAEpC,OAAOA,gBAAgBF;AACzB"}
1
+ {"version":3,"sources":["../../../../src/features/horizontalRule/nodes/HorizontalRuleNode.tsx"],"sourcesContent":["import type {\n DOMConversionMap,\n DOMConversionOutput,\n DOMExportOutput,\n EditorConfig,\n LexicalCommand,\n LexicalNode,\n SerializedLexicalNode,\n Spread,\n} from 'lexical'\n\nimport { addClassNamesToElement } from '@lexical/utils'\nimport { $applyNodeReplacement, DecoratorNode, createCommand } from 'lexical'\nimport * as React from 'react'\n\nconst HorizontalRuleComponent = React.lazy(() =>\n import('../component/index.js').then((module) => ({\n default: module.HorizontalRuleComponent,\n })),\n)\n\n/**\n * Serialized representation of a horizontal rule node. Serialized = converted to JSON. This is what is stored in the database / in the lexical editor state.\n */\nexport type SerializedHorizontalRuleNode = Spread<\n {\n children?: never // required so that our typed editor state doesn't automatically add children\n type: 'horizontalrule'\n },\n SerializedLexicalNode\n>\n\nexport const INSERT_HORIZONTAL_RULE_COMMAND: LexicalCommand<void> = createCommand(\n 'INSERT_HORIZONTAL_RULE_COMMAND',\n)\n\n/**\n * This node is a DecoratorNode. DecoratorNodes allow you to render React components in the editor.\n *\n * They need both createDom and decorate functions. createDom => outside of the html. decorate => React Component inside of the html.\n *\n * If we used DecoratorBlockNode instead, we would only need a decorate method\n */\nexport class HorizontalRuleNode extends DecoratorNode<React.ReactElement> {\n static clone(node: HorizontalRuleNode): HorizontalRuleNode {\n return new HorizontalRuleNode(node.__key)\n }\n\n static getType(): string {\n return 'horizontalrule'\n }\n\n /**\n * Defines what happens if you copy an hr element from another page and paste it into the lexical editor\n *\n * This also determines the behavior of lexical's internal HTML -> Lexical converter\n */\n static importDOM(): DOMConversionMap | null {\n return {\n hr: () => ({\n conversion: $convertHorizontalRuleElement,\n priority: 0,\n }),\n }\n }\n\n /**\n * The data for this node is stored serialized as JSON. This is the \"load function\" of that node: it takes the saved data and converts it into a node.\n */\n static importJSON(serializedNode: SerializedHorizontalRuleNode): HorizontalRuleNode {\n return $createHorizontalRuleNode()\n }\n\n /**\n * Determines how the hr element is rendered in the lexical editor. This is only the \"initial\" / \"outer\" HTML element.\n */\n createDOM(config: EditorConfig): HTMLElement {\n const element = document.createElement('hr')\n addClassNamesToElement(element, config.theme.hr)\n return element\n }\n\n /**\n * Allows you to render a React component within whatever createDOM returns.\n */\n decorate(): React.ReactElement {\n return <HorizontalRuleComponent nodeKey={this.__key} />\n }\n\n /**\n * Opposite of importDOM, this function defines what happens when you copy an hr element from the lexical editor and paste it into another page.\n *\n * This also determines the behavior of lexical's internal Lexical -> HTML converter\n */\n exportDOM(): DOMExportOutput {\n return { element: document.createElement('hr') }\n }\n /**\n * Opposite of importJSON. This determines what data is saved in the database / in the lexical editor state.\n */\n exportJSON(): SerializedLexicalNode {\n return {\n type: 'horizontalrule',\n version: 1,\n }\n }\n\n getTextContent(): string {\n return '\\n'\n }\n\n isInline(): false {\n return false\n }\n\n updateDOM(): boolean {\n return false\n }\n}\n\nfunction $convertHorizontalRuleElement(): DOMConversionOutput {\n return { node: $createHorizontalRuleNode() }\n}\n\nexport function $createHorizontalRuleNode(): HorizontalRuleNode {\n return $applyNodeReplacement(new HorizontalRuleNode())\n}\n\nexport function $isHorizontalRuleNode(\n node: LexicalNode | null | undefined,\n): node is HorizontalRuleNode {\n return node instanceof HorizontalRuleNode\n}\n"],"names":["addClassNamesToElement","$applyNodeReplacement","DecoratorNode","createCommand","React","HorizontalRuleComponent","lazy","then","module","default","INSERT_HORIZONTAL_RULE_COMMAND","HorizontalRuleNode","clone","node","__key","getType","importDOM","hr","conversion","$convertHorizontalRuleElement","priority","importJSON","serializedNode","$createHorizontalRuleNode","createDOM","config","element","document","createElement","theme","decorate","nodeKey","exportDOM","exportJSON","type","version","getTextContent","isInline","updateDOM","$isHorizontalRuleNode"],"mappings":";AAWA,SAASA,sBAAsB,QAAQ,iBAAgB;AACvD,SAASC,qBAAqB,EAAEC,aAAa,EAAEC,aAAa,QAAQ,UAAS;AAC7E,YAAYC,WAAW,QAAO;AAE9B,MAAMC,wCAA0BD,MAAME,IAAI,CAAC,IACzC,MAAM,CAAC,yBAAyBC,IAAI,CAAC,CAACC,SAAY,CAAA;YAChDC,SAASD,OAAOH,uBAAuB;QACzC,CAAA;AAcF,OAAO,MAAMK,iCAAuDP,cAClE,kCACD;AAED;;;;;;CAMC,GACD,OAAO,MAAMQ,2BAA2BT;IACtC,OAAOU,MAAMC,IAAwB,EAAsB;QACzD,OAAO,IAAIF,mBAAmBE,KAAKC,KAAK;IAC1C;IAEA,OAAOC,UAAkB;QACvB,OAAO;IACT;IAEA;;;;GAIC,GACD,OAAOC,YAAqC;QAC1C,OAAO;YACLC,IAAI,IAAO,CAAA;oBACTC,YAAYC;oBACZC,UAAU;gBACZ,CAAA;QACF;IACF;IAEA;;GAEC,GACD,OAAOC,WAAWC,cAA4C,EAAsB;QAClF,OAAOC;IACT;IAEA;;GAEC,GACDC,UAAUC,MAAoB,EAAe;QAC3C,MAAMC,UAAUC,SAASC,aAAa,CAAC;QACvC5B,uBAAuB0B,SAASD,OAAOI,KAAK,CAACZ,EAAE;QAC/C,OAAOS;IACT;IAEA;;GAEC,GACDI,WAA+B;QAC7B,qBAAO,KAACzB;YAAwB0B,SAAS,IAAI,CAACjB,KAAK;;IACrD;IAEA;;;;GAIC,GACDkB,YAA6B;QAC3B,OAAO;YAAEN,SAASC,SAASC,aAAa,CAAC;QAAM;IACjD;IACA;;GAEC,GACDK,aAAoC;QAClC,OAAO;YACLC,MAAM;YACNC,SAAS;QACX;IACF;IAEAC,iBAAyB;QACvB,OAAO;IACT;IAEAC,WAAkB;QAChB,OAAO;IACT;IAEAC,YAAqB;QACnB,OAAO;IACT;AACF;AAEA,SAASnB;IACP,OAAO;QAAEN,MAAMU;IAA4B;AAC7C;AAEA,OAAO,SAASA;IACd,OAAOtB,sBAAsB,IAAIU;AACnC;AAEA,OAAO,SAAS4B,sBACd1B,IAAoC;IAEpC,OAAOA,gBAAgBF;AACzB"}
@@ -1,4 +1,4 @@
1
- import type { PluginComponent } from '../../types.js';
1
+ import type { PluginComponent } from '../../typesClient.js';
2
2
  import './index.scss';
3
3
  /**
4
4
  * Registers the INSERT_HORIZONTAL_RULE_COMMAND lexical command and defines the behavior for when it is called.
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/features/horizontalRule/plugin/index.tsx"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAA;AAMrD,OAAO,cAAc,CAAA;AAErB;;GAEG;AACH,eAAO,MAAM,oBAAoB,EAAE,eAAe,CAAC,SAAS,CA2B3D,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/features/horizontalRule/plugin/index.tsx"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAA;AAM3D,OAAO,cAAc,CAAA;AAErB;;GAEG;AACH,eAAO,MAAM,oBAAoB,EAAE,eAAe,CAAC,SAAS,CA2B3D,CAAA"}