@templatical/editor 0.60.3 → 0.61.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (211) hide show
  1. package/dist/{AiChatPanel-DPoq2Til.js → AiChatPanel-DF5TvO9H.js} +166 -166
  2. package/dist/{AiPanels-UdfhAzzu.js → AiPanels-zRqC5DIP.js} +1 -1
  3. package/dist/{AiRewriteMenu-DOreXB10.js → AiRewriteMenu-CmZKTO-O.js} +6 -6
  4. package/dist/{BlockIssueBadge-DQ_6NI4p.js → BlockIssueBadge-Bug5iqcK.js} +2 -2
  5. package/dist/{BlockPreviewCanvas-YaFum01Z.js → BlockPreviewCanvas-knSyWaCP.js} +3 -3
  6. package/dist/{CloudPanels-Bxv7vUYr.js → CloudPanels-BbHJHZri.js} +3 -3
  7. package/dist/{CollaborationNotices-PqWv0q8W.js → CollaborationNotices-BM35YG72.js} +1 -1
  8. package/dist/{CollaboratorBar-p-_PWqXW.js → CollaboratorBar-DMsEOndt.js} +1 -1
  9. package/dist/{CommentsPanel-BUo-YhSX.js → CommentsPanel-BMYvXRKK.js} +1 -1
  10. package/dist/{CommentsSidebar-D_Pz7FPz.js → CommentsSidebar-_8at1Rug.js} +139 -139
  11. package/dist/{CountdownToolbar-BQdhVNaK.js → CountdownToolbar-BprSuPJk.js} +3 -3
  12. package/dist/{IssuesPanel-C7mBrK6a.js → IssuesPanel-CeCvUfa7.js} +8 -8
  13. package/dist/{LanguageMenu-wS43Ck1x.js → LanguageMenu-CkGqLYjf.js} +124 -124
  14. package/dist/{LocaleNotices-CAvDAawJ.js → LocaleNotices-D0be8ovO.js} +10 -10
  15. package/dist/{LogicTagInsertButton-Clc3JTg_.js → LogicTagInsertButton-BzEZUTRZ.js} +3 -3
  16. package/dist/{MediaEditModal-YXOL0d_y.js → MediaEditModal-Bg-7RojG.js} +1 -1
  17. package/dist/{MediaPanels-VCv5epgs.js → MediaPanels-E9gLZ1Qb.js} +1 -1
  18. package/dist/{MergeTagInput-B5a9noTB.js → MergeTagInput-By2FSStk.js} +1 -1
  19. package/dist/{MergeTagModeToggle-D1r2aH5x.js → MergeTagModeToggle-DtjOZhoD.js} +3 -3
  20. package/dist/{MergeTagTextarea-CA9dPfMH.js → MergeTagTextarea-BjHlamJv.js} +14 -14
  21. package/dist/{ParagraphEditor-zMOqNnmx.js → ParagraphEditor-Ctu4fSsl.js} +23 -23
  22. package/dist/{RestoreVersionDialog-DdPpilBS.js → RestoreVersionDialog-DvZoTJVa.js} +3 -3
  23. package/dist/{RichTextEditorContent-gnRxu4-L.js → RichTextEditorContent-B1p7Ykq8.js} +4 -4
  24. package/dist/{SaveBlockDialog-CQzccFIM.js → SaveBlockDialog-DHfT-Tpx.js} +7 -7
  25. package/dist/{SavedBlocksBrowserModal-8cZ9z-pL.js → SavedBlocksBrowserModal-BjJuuXQv.js} +9 -9
  26. package/dist/{SavedBlocksPanels-C9Oztudc.js → SavedBlocksPanels-D6eiMQZ3.js} +1 -1
  27. package/dist/{SavedBlocksPickBar-udG0wuTf.js → SavedBlocksPickBar-BkgCDSXe.js} +2 -2
  28. package/dist/{TemplateSettings-DsaSsCC8.js → TemplateSettings-DQAbNsiS.js} +6 -6
  29. package/dist/{TestEmailModal-BP6954nj.js → TestEmailModal-m_AEa36T.js} +7 -7
  30. package/dist/{TestEmailPanel-5YlcWwPJ.js → TestEmailPanel-OApkuaVd.js} +1 -1
  31. package/dist/{TitleEditor-Cy-6WZuK.js → TitleEditor-Cwdtfk15.js} +9 -9
  32. package/dist/{Toolbar-Br0W6NE0.js → Toolbar-D_T55elL.js} +358 -358
  33. package/dist/{TplModal-DnytM7wO.js → TplModal-2MKm5y6r.js} +1 -1
  34. package/dist/{VersionHistoryMenu-D-RCk3oB.js → VersionHistoryMenu-B3-xJ7GO.js} +5 -5
  35. package/dist/{VersionHistoryPanels-DIqWP71K.js → VersionHistoryPanels-CCM0IQBg.js} +1 -1
  36. package/dist/{VersionPreviewBanner-DMg2sw3V.js → VersionPreviewBanner-DLAB4ZbS.js} +1 -1
  37. package/dist/{WrapperBlock-DoNQX0Ml.js → WrapperBlock-BZl10HLy.js} +2 -2
  38. package/dist/{blockTypeIcons-BePGuX0b.js → blockTypeIcons-C691ZY1l.js} +3 -3
  39. package/dist/bundle-stats.json +6 -6
  40. package/dist/cdn/chunks/{AiChatPanel-cIT2haLo.js → AiChatPanel-BYAsgmoC.js} +146 -146
  41. package/dist/cdn/chunks/AiChatPanel-BYAsgmoC.js.map +1 -0
  42. package/dist/cdn/chunks/{AiPanels-B4GG8w3J.js → AiPanels-MY_YPls8.js} +2 -2
  43. package/dist/cdn/chunks/{AiPanels-B4GG8w3J.js.map → AiPanels-MY_YPls8.js.map} +1 -1
  44. package/dist/cdn/chunks/{AiRewriteMenu-BqwwNUzj.js → AiRewriteMenu-BSePiXe_.js} +4 -4
  45. package/dist/cdn/chunks/{AiRewriteMenu-BqwwNUzj.js.map → AiRewriteMenu-BSePiXe_.js.map} +1 -1
  46. package/dist/cdn/chunks/{BlockIssueBadge-C50pmOMZ.js → BlockIssueBadge-fYeNnepj.js} +2 -2
  47. package/dist/cdn/chunks/{BlockIssueBadge-C50pmOMZ.js.map → BlockIssueBadge-fYeNnepj.js.map} +1 -1
  48. package/dist/cdn/chunks/{BlockPreviewCanvas-T13OIi1f.js → BlockPreviewCanvas-B153A3hu.js} +4 -4
  49. package/dist/cdn/chunks/{BlockPreviewCanvas-T13OIi1f.js.map → BlockPreviewCanvas-B153A3hu.js.map} +1 -1
  50. package/dist/cdn/chunks/{CloudPanels-DDNWZ7ET.js → CloudPanels-Bv26_Sd8.js} +3 -3
  51. package/dist/cdn/chunks/{CloudPanels-DDNWZ7ET.js.map → CloudPanels-Bv26_Sd8.js.map} +1 -1
  52. package/dist/cdn/chunks/{CollaborationNotices-CTmjjbHv.js → CollaborationNotices-COkmBmps.js} +2 -2
  53. package/dist/cdn/chunks/{CollaborationNotices-CTmjjbHv.js.map → CollaborationNotices-COkmBmps.js.map} +1 -1
  54. package/dist/cdn/chunks/{CollaboratorBar-CzHjawjF.js → CollaboratorBar-BSzI8YIU.js} +2 -2
  55. package/dist/cdn/chunks/{CollaboratorBar-CzHjawjF.js.map → CollaboratorBar-BSzI8YIU.js.map} +1 -1
  56. package/dist/cdn/chunks/{CommentsPanel-Dh0_eRBe.js → CommentsPanel-R27fqh9O.js} +2 -2
  57. package/dist/cdn/chunks/{CommentsPanel-Dh0_eRBe.js.map → CommentsPanel-R27fqh9O.js.map} +1 -1
  58. package/dist/cdn/chunks/{CommentsSidebar-JxZ-O2mY.js → CommentsSidebar-BEiOQ_zT.js} +133 -133
  59. package/dist/cdn/chunks/CommentsSidebar-BEiOQ_zT.js.map +1 -0
  60. package/dist/cdn/chunks/{CountdownToolbar-D16RWxkh.js → CountdownToolbar-DOhXnbsq.js} +4 -4
  61. package/dist/cdn/chunks/{CountdownToolbar-D16RWxkh.js.map → CountdownToolbar-DOhXnbsq.js.map} +1 -1
  62. package/dist/cdn/chunks/{IssuesPanel-BtAn12hl.js → IssuesPanel-DgxiS3hF.js} +2 -2
  63. package/dist/cdn/chunks/{IssuesPanel-BtAn12hl.js.map → IssuesPanel-DgxiS3hF.js.map} +1 -1
  64. package/dist/cdn/chunks/{LanguageMenu-D71nO6LO.js → LanguageMenu-B6kt8SgX.js} +105 -105
  65. package/dist/cdn/chunks/LanguageMenu-B6kt8SgX.js.map +1 -0
  66. package/dist/cdn/chunks/{LocaleNotices-CzrNKR-N.js → LocaleNotices-Bleg4gTu.js} +10 -10
  67. package/dist/cdn/chunks/LocaleNotices-Bleg4gTu.js.map +1 -0
  68. package/dist/cdn/chunks/{LogicTagInsertButton-B4wuPoMa.js → LogicTagInsertButton-DGg1Wvhp.js} +2 -2
  69. package/dist/cdn/chunks/{LogicTagInsertButton-B4wuPoMa.js.map → LogicTagInsertButton-DGg1Wvhp.js.map} +1 -1
  70. package/dist/cdn/chunks/{MediaEditModal-DJ2wxInt.js → MediaEditModal-BQO6ggJK.js} +2 -2
  71. package/dist/cdn/chunks/{MediaEditModal-DJ2wxInt.js.map → MediaEditModal-BQO6ggJK.js.map} +1 -1
  72. package/dist/cdn/chunks/{MediaPanels-BJawNjr9.js → MediaPanels-Ciahwsyt.js} +2 -2
  73. package/dist/cdn/chunks/{MediaPanels-BJawNjr9.js.map → MediaPanels-Ciahwsyt.js.map} +1 -1
  74. package/dist/cdn/chunks/{MergeTagInput-DZD-p4nR.js → MergeTagInput-BVfTwujW.js} +2 -2
  75. package/dist/cdn/chunks/{MergeTagInput-DZD-p4nR.js.map → MergeTagInput-BVfTwujW.js.map} +1 -1
  76. package/dist/cdn/chunks/{MergeTagModeToggle-DGuJCgqO.js → MergeTagModeToggle-BoI0C1Y6.js} +2 -2
  77. package/dist/cdn/chunks/{MergeTagModeToggle-DGuJCgqO.js.map → MergeTagModeToggle-BoI0C1Y6.js.map} +1 -1
  78. package/dist/cdn/chunks/{MergeTagTextarea-BRiaRBr_.js → MergeTagTextarea-DGDv-pdn.js} +15 -15
  79. package/dist/cdn/chunks/MergeTagTextarea-DGDv-pdn.js.map +1 -0
  80. package/dist/cdn/chunks/{ParagraphEditor-BClN3WxA.js → ParagraphEditor-D0q36Myd.js} +24 -24
  81. package/dist/cdn/chunks/{ParagraphEditor-BClN3WxA.js.map → ParagraphEditor-D0q36Myd.js.map} +1 -1
  82. package/dist/cdn/chunks/{RestoreVersionDialog-CVfKIT1K.js → RestoreVersionDialog-CJggFdbi.js} +3 -3
  83. package/dist/cdn/chunks/{RestoreVersionDialog-CVfKIT1K.js.map → RestoreVersionDialog-CJggFdbi.js.map} +1 -1
  84. package/dist/cdn/chunks/{RichTextEditorContent-CtV0Q0SO.js → RichTextEditorContent-D3ihUF8v.js} +4 -4
  85. package/dist/cdn/chunks/{RichTextEditorContent-CtV0Q0SO.js.map → RichTextEditorContent-D3ihUF8v.js.map} +1 -1
  86. package/dist/cdn/chunks/{SaveBlockDialog-Cy6mI_xB.js → SaveBlockDialog-BzES5tqd.js} +6 -6
  87. package/dist/cdn/chunks/{SaveBlockDialog-Cy6mI_xB.js.map → SaveBlockDialog-BzES5tqd.js.map} +1 -1
  88. package/dist/cdn/chunks/{SavedBlocksBrowserModal-DW917QDB.js → SavedBlocksBrowserModal-CLNcZcLd.js} +6 -6
  89. package/dist/cdn/chunks/{SavedBlocksBrowserModal-DW917QDB.js.map → SavedBlocksBrowserModal-CLNcZcLd.js.map} +1 -1
  90. package/dist/cdn/chunks/{SavedBlocksPanels-Cyzerpxs.js → SavedBlocksPanels-R0W9LElD.js} +2 -2
  91. package/dist/cdn/chunks/{SavedBlocksPanels-Cyzerpxs.js.map → SavedBlocksPanels-R0W9LElD.js.map} +1 -1
  92. package/dist/cdn/chunks/{SavedBlocksPickBar-D6n86773.js → SavedBlocksPickBar-JNi5Rx4V.js} +3 -3
  93. package/dist/cdn/chunks/{SavedBlocksPickBar-D6n86773.js.map → SavedBlocksPickBar-JNi5Rx4V.js.map} +1 -1
  94. package/dist/cdn/chunks/{TemplateSettings--_ZfbhnU.js → TemplateSettings-C5wsNcgX.js} +4 -4
  95. package/dist/cdn/chunks/{TemplateSettings--_ZfbhnU.js.map → TemplateSettings-C5wsNcgX.js.map} +1 -1
  96. package/dist/cdn/chunks/{TestEmailModal-V_UFUIaf.js → TestEmailModal-BxIAwjww.js} +6 -6
  97. package/dist/cdn/chunks/{TestEmailModal-V_UFUIaf.js.map → TestEmailModal-BxIAwjww.js.map} +1 -1
  98. package/dist/cdn/chunks/{TestEmailPanel-CBfqsO2u.js → TestEmailPanel-B8BsWXjE.js} +2 -2
  99. package/dist/cdn/chunks/{TestEmailPanel-CBfqsO2u.js.map → TestEmailPanel-B8BsWXjE.js.map} +1 -1
  100. package/dist/cdn/chunks/{TitleEditor-CimWOQVn.js → TitleEditor-DhcI1aRS.js} +8 -8
  101. package/dist/cdn/chunks/{TitleEditor-CimWOQVn.js.map → TitleEditor-DhcI1aRS.js.map} +1 -1
  102. package/dist/cdn/chunks/{Toolbar-czJfutfE.js → Toolbar-Ch3h2BUs.js} +202 -202
  103. package/dist/cdn/chunks/Toolbar-Ch3h2BUs.js.map +1 -0
  104. package/dist/cdn/chunks/{TplModal-BtJJ5-En.js → TplModal-CPOqOxVf.js} +2 -2
  105. package/dist/cdn/chunks/{TplModal-BtJJ5-En.js.map → TplModal-CPOqOxVf.js.map} +1 -1
  106. package/dist/cdn/chunks/{VersionHistoryMenu-CVGlUPwS.js → VersionHistoryMenu-DTDO48HI.js} +2 -2
  107. package/dist/cdn/chunks/{VersionHistoryMenu-CVGlUPwS.js.map → VersionHistoryMenu-DTDO48HI.js.map} +1 -1
  108. package/dist/cdn/chunks/{VersionHistoryPanels-BS0USHsp.js → VersionHistoryPanels-CVrXHYxT.js} +2 -2
  109. package/dist/cdn/chunks/{VersionHistoryPanels-BS0USHsp.js.map → VersionHistoryPanels-CVrXHYxT.js.map} +1 -1
  110. package/dist/cdn/chunks/{VersionPreviewBanner-5RFz4AQx.js → VersionPreviewBanner-C1H_fYAr.js} +2 -2
  111. package/dist/cdn/chunks/{VersionPreviewBanner-5RFz4AQx.js.map → VersionPreviewBanner-C1H_fYAr.js.map} +1 -1
  112. package/dist/cdn/chunks/{WrapperBlock-CSjYFYUT.js → WrapperBlock-B8SJ7Q4w.js} +3 -3
  113. package/dist/cdn/chunks/{WrapperBlock-CSjYFYUT.js.map → WrapperBlock-B8SJ7Q4w.js.map} +1 -1
  114. package/dist/cdn/chunks/{blockTypeIcons-BOonB9gK.js → blockTypeIcons-ZKw-Eiu0.js} +2 -2
  115. package/dist/cdn/chunks/{blockTypeIcons-BOonB9gK.js.map → blockTypeIcons-ZKw-Eiu0.js.map} +1 -1
  116. package/dist/cdn/chunks/{composables-BHsV8gkq.js → composables-CKXPwWo9.js} +152 -152
  117. package/dist/cdn/chunks/composables-CKXPwWo9.js.map +1 -0
  118. package/dist/cdn/chunks/dompurify-BflADeuH.js +850 -0
  119. package/dist/cdn/chunks/dompurify-BflADeuH.js.map +1 -0
  120. package/dist/cdn/chunks/{editor-modal-BVM_0uoL.js → editor-modal-BlSmX9Ch.js} +4 -4
  121. package/dist/cdn/chunks/{editor-modal-BVM_0uoL.js.map → editor-modal-BlSmX9Ch.js.map} +1 -1
  122. package/dist/cdn/chunks/en-jObtIVCp.js +1 -0
  123. package/dist/cdn/chunks/{extensions-BeGvJ6f0.js → extensions-Bq9nXmBP.js} +3 -3
  124. package/dist/cdn/chunks/{extensions-BeGvJ6f0.js.map → extensions-Bq9nXmBP.js.map} +1 -1
  125. package/dist/cdn/chunks/{icons-CWEBTtbR.js → icons-DdVB-5WO.js} +28 -28
  126. package/dist/cdn/chunks/{icons-CWEBTtbR.js.map → icons-DdVB-5WO.js.map} +1 -1
  127. package/dist/cdn/chunks/keys-ywH4jHJ2.js.map +1 -1
  128. package/dist/cdn/chunks/{sanitizeHtml-Db0S2JVP.js → sanitizeHtml-Plkmw1Qt.js} +2 -2
  129. package/dist/cdn/chunks/{sanitizeHtml-Db0S2JVP.js.map → sanitizeHtml-Plkmw1Qt.js.map} +1 -1
  130. package/dist/cdn/chunks/{socialIcons-DMelHF3p.js → socialIcons-CSe4YJ52.js} +2 -2
  131. package/dist/cdn/chunks/{socialIcons-DMelHF3p.js.map → socialIcons-CSe4YJ52.js.map} +1 -1
  132. package/dist/cdn/chunks/{src-B32tyank.js → src-Bk1LF1np.js} +16 -14
  133. package/dist/cdn/chunks/src-Bk1LF1np.js.map +1 -0
  134. package/dist/cdn/chunks/{tiptap-LIEsAVOF.js → tiptap-DDhueoan.js} +15 -7
  135. package/dist/cdn/chunks/{tiptap-LIEsAVOF.js.map → tiptap-DDhueoan.js.map} +1 -1
  136. package/dist/cdn/chunks/useLanguageName-DDhdVpqh.js +41 -0
  137. package/dist/cdn/chunks/useLanguageName-DDhdVpqh.js.map +1 -0
  138. package/dist/cdn/editor.css +1 -1
  139. package/dist/cdn/editor.js +64 -62
  140. package/dist/cdn/editor.js.map +1 -1
  141. package/dist/{check-C82yyyf1.js → check-8ZykoWzl.js} +1 -1
  142. package/dist/{chevron-down-BaBVjNbM.js → chevron-down-D_CUJHwi.js} +1 -1
  143. package/dist/{chevron-right-DkS-bw8X.js → chevron-right-B2WYkQtG.js} +1 -1
  144. package/dist/{chevron-up-C1KzUIK4.js → chevron-up-L-H27use.js} +1 -1
  145. package/dist/{circle-exclamation-point-DsmqtTUQ.js → circle-exclamation-point-BCx1tR91.js} +1 -1
  146. package/dist/{clock-dpIs7vo0.js → clock-DOOnNINY.js} +1 -1
  147. package/dist/{composables-DG_CMpuY.js → composables-26aR45W3.js} +1222 -1222
  148. package/dist/{createLucideIcon-BSam2AUu.js → createLucideIcon-BKeRiObH.js} +5 -5
  149. package/dist/{dist-CRcnmuxb.js → dist-B1bGGOA0.js} +2 -2
  150. package/dist/{dist-DRbuXmjl.js → dist-C3ZVR_pd.js} +2 -2
  151. package/dist/{dist-BvNveHdP.js → dist-C8aVVj28.js} +2 -2
  152. package/dist/dist-CTzstDyz.js +4 -0
  153. package/dist/{dist-xc8l1i2C.js → dist-CcxrHURm.js} +786 -778
  154. package/dist/{dist-LrtNpIZD.js → dist-D41-1sSL.js} +6 -6
  155. package/dist/{dist-BKFfCbrD.js → dist-DRJhbfT9.js} +2 -2
  156. package/dist/{dist-DCGVHlXC.js → dist-DkQutATU.js} +2 -2
  157. package/dist/{dist-BMULQVZF.js → dist-DyrUc7rM.js} +2 -2
  158. package/dist/{dist-CiOtB5na.js → dist-p_84-Inl.js} +2 -2
  159. package/dist/{dist-Bsg1RBUb.js → dist-tG9_FTOs.js} +2 -2
  160. package/dist/dist-zQ8L1LNg.js +4 -0
  161. package/dist/{editor-modal-odubnc9x.js → editor-modal-CRtEWHbQ.js} +15 -15
  162. package/dist/en-CMswCXqE.js +1 -0
  163. package/dist/{extensions-Cao-H_tB.js → extensions-zHf8YFRw.js} +4 -4
  164. package/dist/{eye-CxCHEszj.js → eye-BjZOVab7.js} +1 -1
  165. package/dist/{image-DvXPzqNd.js → image-g47lDP0J.js} +1 -1
  166. package/dist/index.d.ts +5 -1
  167. package/dist/{info-2KHWaZ2L.js → info-DXij4QjB.js} +1 -1
  168. package/dist/{link-_OmrcJMv.js → link-BFJF0mWz.js} +1 -1
  169. package/dist/{list-Dekd7JE8.js → list-Cso9vnLq.js} +1 -1
  170. package/dist/{loader-circle-D_hT5mFS.js → loader-circle-uLY01591.js} +1 -1
  171. package/dist/{message-circle-DDbiG-jz.js → message-circle-amY03UMa.js} +1 -1
  172. package/dist/{package-cORUe57D.js → package-DnjoSQa1.js} +1 -1
  173. package/dist/{pencil-D67H4fxq.js → pencil-D1HBG4pb.js} +1 -1
  174. package/dist/{plus-BpTZAx28.js → plus-PzFvtj-Z.js} +1 -1
  175. package/dist/{refresh-cw-B4T0IFwI.js → refresh-cw-BPDv-S-4.js} +1 -1
  176. package/dist/{rotate-ccw-BDQgjpuo.js → rotate-ccw-DQZVEj1V.js} +1 -1
  177. package/dist/sanitizeHtml-DxmFirMi.js +945 -0
  178. package/dist/{search-Dp9pkaVt.js → search-BUBeKVdD.js} +1 -1
  179. package/dist/{send-DO9GhgCH.js → send-BJEuoIc2.js} +1 -1
  180. package/dist/{smartphone-CPW3I3hV.js → smartphone-DZ5xyNU4.js} +1 -1
  181. package/dist/{socialIcons-DXOO2y7u.js → socialIcons-mWE33bOn.js} +3 -3
  182. package/dist/{sparkles-CIBjNfij.js → sparkles-zWGR8hrs.js} +1 -1
  183. package/dist/{square-3W65qrrH.js → square--3H462TJ.js} +1 -1
  184. package/dist/style.css +1 -1
  185. package/dist/templatical-editor.js +78 -76
  186. package/dist/{text-align-start-Bs70tpRU.js → text-align-start-B5Dx2Ylg.js} +13 -13
  187. package/dist/{trash-CTzhAm1o.js → trash-CJsobpw0.js} +1 -1
  188. package/dist/{triangle-exclamation-point-D_13CuJY.js → triangle-exclamation-point-Bi7ZKTZU.js} +1 -1
  189. package/dist/{upload-DFxkP9MI.js → upload-DZ_-FNJ4.js} +1 -1
  190. package/dist/useLanguageName-CEFzafHB.js +39 -0
  191. package/dist/{useScrollToBlock-194ePl4q.js → useScrollToBlock-eZXiGa8o.js} +1 -1
  192. package/dist/{x-D7L8mLHJ.js → x-CuyPLm0U.js} +1 -1
  193. package/package.json +24 -24
  194. package/dist/cdn/chunks/AiChatPanel-cIT2haLo.js.map +0 -1
  195. package/dist/cdn/chunks/CommentsSidebar-JxZ-O2mY.js.map +0 -1
  196. package/dist/cdn/chunks/LanguageMenu-D71nO6LO.js.map +0 -1
  197. package/dist/cdn/chunks/LocaleNotices-CzrNKR-N.js.map +0 -1
  198. package/dist/cdn/chunks/MergeTagTextarea-BRiaRBr_.js.map +0 -1
  199. package/dist/cdn/chunks/Toolbar-czJfutfE.js.map +0 -1
  200. package/dist/cdn/chunks/composables-BHsV8gkq.js.map +0 -1
  201. package/dist/cdn/chunks/dompurify-JVtr5-B1.js +0 -872
  202. package/dist/cdn/chunks/dompurify-JVtr5-B1.js.map +0 -1
  203. package/dist/cdn/chunks/en-DlDEofnd.js +0 -1
  204. package/dist/cdn/chunks/languageName-DEEOhDWI.js +0 -12
  205. package/dist/cdn/chunks/languageName-DEEOhDWI.js.map +0 -1
  206. package/dist/cdn/chunks/src-B32tyank.js.map +0 -1
  207. package/dist/dist-BnPPgVlu.js +0 -4
  208. package/dist/dist-zAzcxDCA.js +0 -4
  209. package/dist/en-CAImT1hl.js +0 -1
  210. package/dist/languageName-DEEOhDWI.js +0 -10
  211. package/dist/sanitizeHtml-Ru5_-IbM.js +0 -973
@@ -1,4 +1,4 @@
1
- // ../../node_modules/.pnpm/@tiptap+core@3.33.1_@tiptap+pm@3.33.1/node_modules/@tiptap/core/dist/rolldown-runtime-D7D4PA-g.js
1
+ // ../../node_modules/.pnpm/@tiptap+core@3.34.0_@tiptap+pm@3.34.0/node_modules/@tiptap/core/dist/rolldown-runtime-D7D4PA-g.js
2
2
  var e = Object.defineProperty, t = (t, n) => {
3
3
  let r = {};
4
4
  for (var i in t) e(r, i, {
@@ -4068,10 +4068,10 @@ function qr(e, t, n) {
4068
4068
  };
4069
4069
  }
4070
4070
  }
4071
- var Jr = typeof navigator < "u" ? navigator : null, Yr = typeof document < "u" ? document : null, Xr = Jr && Jr.userAgent || "", Zr = /Edge\/(\d+)/.exec(Xr), Qr = /MSIE \d/.exec(Xr), $r = /Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(Xr), I = !!(Qr || $r || Zr), ei = Qr ? document.documentMode : $r ? +$r[1] : Zr ? +Zr[1] : 0, L = !I && /gecko\/(\d+)/i.test(Xr);
4072
- L && +(/Firefox\/(\d+)/.exec(Xr) || [0, 0])[1];
4073
- var ti = !I && /Chrome\/(\d+)/.exec(Xr), R = !!ti, ni = ti ? +ti[1] : 0, z = !I && !!Jr && /Apple Computer/.test(Jr.vendor), ri = z && (/Mobile\/\w+/.test(Xr) || !!Jr && Jr.maxTouchPoints > 2), B = ri || (Jr ? /Mac/.test(Jr.platform) : !1), ii = Jr ? /Win/.test(Jr.platform) : !1, ai = /Android \d/.test(Xr), oi = !!Yr && "webkitFontSmoothing" in Yr.documentElement.style, si = oi ? +(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent) || [0, 0])[1] : 0;
4074
- function ci(e) {
4071
+ var I = typeof navigator < "u" ? navigator : null, Jr = typeof document < "u" ? document : null, Yr = I && I.userAgent || "", Xr = /Edge\/(\d+)/.exec(Yr), Zr = /MSIE \d/.exec(Yr), Qr = /Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(Yr), L = !!(Zr || Qr || Xr), $r = Zr ? document.documentMode : Qr ? +Qr[1] : Xr ? +Xr[1] : 0, R = !L && /gecko\/(\d+)/i.test(Yr);
4072
+ R && +(/Firefox\/(\d+)/.exec(Yr) || [0, 0])[1];
4073
+ var ei = !L && /Chrome\/(\d+)/.exec(Yr), z = !!ei, ti = ei ? +ei[1] : 0, B = !L && !!I && /Apple Computer/.test(I.vendor), ni = B && (/Mobile\/\w+/.test(Yr) || !!I && I.maxTouchPoints > 2), V = ni || (I ? /Mac/.test(I.platform) : !1), ri = I ? /Win/.test(I.platform) : !1, ii = /Android \d/.test(Yr), ai = !!Jr && "webkitFontSmoothing" in Jr.documentElement.style, oi = ai ? +(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent) || [0, 0])[1] : 0;
4074
+ function si(e) {
4075
4075
  let t = e.defaultView && e.defaultView.visualViewport;
4076
4076
  return t ? {
4077
4077
  left: 0,
@@ -4085,10 +4085,10 @@ function ci(e) {
4085
4085
  bottom: e.documentElement.clientHeight
4086
4086
  };
4087
4087
  }
4088
- function li(e, t) {
4088
+ function ci(e, t) {
4089
4089
  return typeof e == "number" ? e : e[t];
4090
4090
  }
4091
- function ui(e) {
4091
+ function li(e) {
4092
4092
  let t = e.getBoundingClientRect(), n = t.width / e.offsetWidth || 1, r = t.height / e.offsetHeight || 1;
4093
4093
  return {
4094
4094
  left: t.left,
@@ -4097,16 +4097,16 @@ function ui(e) {
4097
4097
  bottom: t.top + e.clientHeight * r
4098
4098
  };
4099
4099
  }
4100
- function di(e, t, n) {
4101
- if (!Ei(t) && t.left == 0) return;
4100
+ function ui(e, t, n) {
4101
+ if (!Ti(t) && t.left == 0) return;
4102
4102
  let r = e.someProp("scrollThreshold") || 0, i = e.someProp("scrollMargin") || 5, a = e.dom.ownerDocument;
4103
4103
  for (let o = n || e.dom; o;) {
4104
4104
  if (!P(o)) {
4105
4105
  o = Mr(o);
4106
4106
  continue;
4107
4107
  }
4108
- let e = o == a.body, n = e ? ci(a) : ui(o), s = 0, c = 0;
4109
- if (t.top < n.top + li(r, "top") ? c = -(n.top - t.top + li(i, "top")) : t.bottom > n.bottom - li(r, "bottom") && (c = t.bottom - t.top > n.bottom - n.top ? t.top + li(i, "top") - n.top : t.bottom - n.bottom + li(i, "bottom")), t.left < n.left + li(r, "left") ? s = -(n.left - t.left + li(i, "left")) : t.right > n.right - li(r, "right") && (s = t.right - n.right + li(i, "right")), s || c) {
4108
+ let e = o == a.body, n = e ? si(a) : li(o), s = 0, c = 0;
4109
+ if (t.top < n.top + ci(r, "top") ? c = -(n.top - t.top + ci(i, "top")) : t.bottom > n.bottom - ci(r, "bottom") && (c = t.bottom - t.top > n.bottom - n.top ? t.top + ci(i, "top") - n.top : t.bottom - n.bottom + ci(i, "bottom")), t.left < n.left + ci(r, "left") ? s = -(n.left - t.left + ci(i, "left")) : t.right > n.right - ci(r, "right") && (s = t.right - n.right + ci(i, "right")), s || c) {
4110
4110
  if (e) a.defaultView.scrollBy(s, c);
4111
4111
  else {
4112
4112
  let e = o.scrollLeft, n = o.scrollTop;
@@ -4125,7 +4125,7 @@ function di(e, t, n) {
4125
4125
  o = l == "absolute" ? o.offsetParent : Mr(o);
4126
4126
  }
4127
4127
  }
4128
- function fi(e) {
4128
+ function di(e) {
4129
4129
  let t = e.dom.getBoundingClientRect(), n = Math.max(0, t.top), r, i;
4130
4130
  for (let a = (t.left + t.right) / 2, o = n + 1; o < Math.min(innerHeight, t.bottom); o += 5) {
4131
4131
  let t = e.root.elementFromPoint(a, o);
@@ -4139,10 +4139,10 @@ function fi(e) {
4139
4139
  return {
4140
4140
  refDOM: r,
4141
4141
  refTop: i,
4142
- stack: pi(e.dom)
4142
+ stack: fi(e.dom)
4143
4143
  };
4144
4144
  }
4145
- function pi(e) {
4145
+ function fi(e) {
4146
4146
  let t = [], n = e.ownerDocument;
4147
4147
  for (let r = e; r && (t.push({
4148
4148
  dom: r,
@@ -4151,26 +4151,26 @@ function pi(e) {
4151
4151
  }), e != n); r = Mr(r));
4152
4152
  return t;
4153
4153
  }
4154
- function mi({ refDOM: e, refTop: t, stack: n }) {
4154
+ function pi({ refDOM: e, refTop: t, stack: n }) {
4155
4155
  let r = e ? e.getBoundingClientRect().top : 0;
4156
- hi(n, r == 0 ? 0 : r - t);
4156
+ mi(n, r == 0 ? 0 : r - t);
4157
4157
  }
4158
- function hi(e, t) {
4158
+ function mi(e, t) {
4159
4159
  for (let n = 0; n < e.length; n++) {
4160
4160
  let { dom: r, top: i, left: a } = e[n];
4161
4161
  r.scrollTop != i + t && (r.scrollTop = i + t), r.scrollLeft != a && (r.scrollLeft = a);
4162
4162
  }
4163
4163
  }
4164
- var gi = null;
4165
- function _i(e) {
4164
+ var hi = null;
4165
+ function gi(e) {
4166
4166
  if (e.setActive) return e.setActive();
4167
- if (gi) return e.focus(gi);
4168
- let t = pi(e);
4169
- e.focus(gi == null ? { get preventScroll() {
4170
- return gi = { preventScroll: !0 }, !0;
4171
- } } : void 0), gi || (gi = !1, hi(t, 0));
4167
+ if (hi) return e.focus(hi);
4168
+ let t = fi(e);
4169
+ e.focus(hi == null ? { get preventScroll() {
4170
+ return hi = { preventScroll: !0 }, !0;
4171
+ } } : void 0), hi || (hi = !1, mi(t, 0));
4172
4172
  }
4173
- function vi(e, t) {
4173
+ function _i(e, t) {
4174
4174
  let n, r = 2e8, i, a = 0, o = t.top, s = t.top, c, l;
4175
4175
  for (let u = e.firstChild, d = 0; u; u = u.nextSibling, d++) {
4176
4176
  let e;
@@ -4196,17 +4196,17 @@ function vi(e, t) {
4196
4196
  !n && (t.left >= p.right && t.top >= p.top || t.left >= p.left && t.top >= p.bottom) && (a = d + 1);
4197
4197
  }
4198
4198
  }
4199
- return !n && c && (n = c, i = l, r = 0), n && F(n) ? yi(n, i) : !n || r ? {
4199
+ return !n && c && (n = c, i = l, r = 0), n && F(n) ? vi(n, i) : !n || r ? {
4200
4200
  node: e,
4201
4201
  offset: a
4202
- } : vi(n, i);
4202
+ } : _i(n, i);
4203
4203
  }
4204
- function yi(e, t) {
4204
+ function vi(e, t) {
4205
4205
  let n = e.nodeValue.length, r = document.createRange(), i;
4206
4206
  for (let a = 0; a < n; a++) {
4207
4207
  r.setEnd(e, a + 1), r.setStart(e, a);
4208
- let n = Di(r, 1);
4209
- if (n.top != n.bottom && bi(t, n)) {
4208
+ let n = Ei(r, 1);
4209
+ if (n.top != n.bottom && yi(t, n)) {
4210
4210
  i = {
4211
4211
  node: e,
4212
4212
  offset: a + +(t.left >= (n.left + n.right) / 2)
@@ -4219,22 +4219,22 @@ function yi(e, t) {
4219
4219
  offset: 0
4220
4220
  };
4221
4221
  }
4222
- function bi(e, t) {
4222
+ function yi(e, t) {
4223
4223
  return e.left >= t.left - 1 && e.left <= t.right + 1 && e.top >= t.top - 1 && e.top <= t.bottom + 1;
4224
4224
  }
4225
- function xi(e, t) {
4225
+ function bi(e, t) {
4226
4226
  let n = e.parentNode;
4227
4227
  return n && /^li$/i.test(n.nodeName) && t.left < e.getBoundingClientRect().left ? n : e;
4228
4228
  }
4229
- function Si(e, t, n) {
4230
- let { node: r, offset: i } = vi(t, n), a = -1;
4229
+ function xi(e, t, n) {
4230
+ let { node: r, offset: i } = _i(t, n), a = -1;
4231
4231
  if (P(r) && !r.firstChild) {
4232
4232
  let e = r.getBoundingClientRect();
4233
4233
  a = e.left != e.right && n.left > (e.left + e.right) / 2 ? 1 : -1;
4234
4234
  }
4235
4235
  return e.docView.posFromDOM(r, i, a);
4236
4236
  }
4237
- function Ci(e, t, n, r) {
4237
+ function Si(e, t, n, r) {
4238
4238
  let i = -1;
4239
4239
  for (let n = t, a = !1; n != e.dom;) {
4240
4240
  let t = e.docView.nearestDesc(n, !0), o;
@@ -4244,7 +4244,7 @@ function Ci(e, t, n, r) {
4244
4244
  }
4245
4245
  return i > -1 ? i : e.docView.posFromDOM(t, n, -1);
4246
4246
  }
4247
- function wi(e, t, n) {
4247
+ function Ci(e, t, n) {
4248
4248
  let r = e.childNodes.length;
4249
4249
  if (r && n.top < n.bottom) for (let i = Math.max(0, Math.min(r - 1, Math.floor(r * (t.top - n.top) / (n.bottom - n.top)) - 2)), a = i;;) {
4250
4250
  let n = e.childNodes[a];
@@ -4252,92 +4252,92 @@ function wi(e, t, n) {
4252
4252
  let e = n.getClientRects();
4253
4253
  for (let r = 0; r < e.length; r++) {
4254
4254
  let i = e[r];
4255
- if (bi(t, i)) return wi(n, t, i);
4255
+ if (yi(t, i)) return Ci(n, t, i);
4256
4256
  }
4257
4257
  }
4258
4258
  if ((a = (a + 1) % r) == i) break;
4259
4259
  }
4260
4260
  return e;
4261
4261
  }
4262
- function Ti(e, t) {
4262
+ function wi(e, t) {
4263
4263
  let n = e.dom.ownerDocument, r, i = 0, a = qr(n, t.left, t.top);
4264
4264
  a && ({node: r, offset: i} = a);
4265
4265
  let o = (e.root.elementFromPoint ? e.root : n).elementFromPoint(t.left, t.top), s;
4266
4266
  if (!o || !e.dom.contains(o)) {
4267
4267
  let n = e.dom.getBoundingClientRect();
4268
- if (!bi(t, n) || (o = wi(e.dom, t, n), !o)) return null;
4268
+ if (!yi(t, n) || (o = Ci(e.dom, t, n), !o)) return null;
4269
4269
  }
4270
- if (z) for (let e = o; r && e; e = Mr(e)) e.draggable && (r = void 0);
4271
- if (o = xi(o, t), r) {
4272
- if (L && P(r) && (i = Math.min(i, r.childNodes.length), i < r.childNodes.length)) {
4270
+ if (B) for (let e = o; r && e; e = Mr(e)) e.draggable && (r = void 0);
4271
+ if (o = bi(o, t), r) {
4272
+ if (R && P(r) && (i = Math.min(i, r.childNodes.length), i < r.childNodes.length)) {
4273
4273
  let e = r.childNodes[i], n;
4274
4274
  e.nodeName == "IMG" && (n = e.getBoundingClientRect()).right <= t.left && n.bottom > t.top && i++;
4275
4275
  }
4276
4276
  let n;
4277
- oi && i && P(r) && P(n = r.childNodes[i - 1]) && n.contentEditable == "false" && n.getBoundingClientRect().top >= t.top && i--, r == e.dom && i == r.childNodes.length - 1 && P(r.lastChild) && t.top > r.lastChild.getBoundingClientRect().bottom ? s = e.state.doc.content.size : i != 0 && P(r) && r.childNodes[i - 1].nodeName == "BR" || (s = Ci(e, r, i, t));
4277
+ ai && i && P(r) && P(n = r.childNodes[i - 1]) && n.contentEditable == "false" && n.getBoundingClientRect().top >= t.top && i--, r == e.dom && i == r.childNodes.length - 1 && P(r.lastChild) && t.top > r.lastChild.getBoundingClientRect().bottom ? s = e.state.doc.content.size : i != 0 && P(r) && r.childNodes[i - 1].nodeName == "BR" || (s = Si(e, r, i, t));
4278
4278
  }
4279
- s ??= Si(e, o, t);
4279
+ s ??= xi(e, o, t);
4280
4280
  let c = e.docView.nearestDesc(o, !0);
4281
4281
  return {
4282
4282
  pos: s,
4283
4283
  inside: c ? c.posAtStart - c.border : -1
4284
4284
  };
4285
4285
  }
4286
- function Ei(e) {
4286
+ function Ti(e) {
4287
4287
  return e.top < e.bottom || e.left < e.right;
4288
4288
  }
4289
- function Di(e, t) {
4289
+ function Ei(e, t) {
4290
4290
  let n = e.getClientRects();
4291
4291
  if (n.length) {
4292
4292
  let e = n[t < 0 ? 0 : n.length - 1];
4293
- if (Ei(e)) return e;
4293
+ if (Ti(e)) return e;
4294
4294
  }
4295
- return Array.prototype.find.call(n, Ei) || e.getBoundingClientRect();
4295
+ return Array.prototype.find.call(n, Ti) || e.getBoundingClientRect();
4296
4296
  }
4297
- var Oi = /[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/;
4298
- function ki(e, t, n) {
4299
- let { node: r, offset: i, atom: a } = e.docView.domFromPos(t, n < 0 ? -1 : 1), o = oi || L;
4297
+ var Di = /[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/;
4298
+ function Oi(e, t, n) {
4299
+ let { node: r, offset: i, atom: a } = e.docView.domFromPos(t, n < 0 ? -1 : 1), o = ai || R;
4300
4300
  if (F(r)) {
4301
- if (o && (Oi.test(r.nodeValue) || (n < 0 ? !i : i == r.nodeValue.length))) {
4302
- let e = Di(Pr(r, i, i), n);
4303
- if (L && i && /\s/.test(r.nodeValue[i - 1]) && i < r.nodeValue.length) {
4304
- let t = Di(Pr(r, i - 1, i - 1), -1);
4301
+ if (o && (Di.test(r.nodeValue) || (n < 0 ? !i : i == r.nodeValue.length))) {
4302
+ let e = Ei(Pr(r, i, i), n);
4303
+ if (R && i && /\s/.test(r.nodeValue[i - 1]) && i < r.nodeValue.length) {
4304
+ let t = Ei(Pr(r, i - 1, i - 1), -1);
4305
4305
  if (t.top == e.top) {
4306
- let n = Di(Pr(r, i, i + 1), -1);
4307
- if (n.top != e.top) return Ai(n, n.left < t.left);
4306
+ let n = Ei(Pr(r, i, i + 1), -1);
4307
+ if (n.top != e.top) return ki(n, n.left < t.left);
4308
4308
  }
4309
4309
  }
4310
4310
  return e;
4311
4311
  }
4312
4312
  {
4313
4313
  let e = i, t = i, a = n < 0 ? 1 : -1;
4314
- return n < 0 && !i ? (t++, a = -1) : n >= 0 && i == r.nodeValue.length ? (e--, a = 1) : n < 0 ? e-- : t++, Ai(Di(Pr(r, e, t), a), a < 0);
4314
+ return n < 0 && !i ? (t++, a = -1) : n >= 0 && i == r.nodeValue.length ? (e--, a = 1) : n < 0 ? e-- : t++, ki(Ei(Pr(r, e, t), a), a < 0);
4315
4315
  }
4316
4316
  }
4317
4317
  if (!e.state.doc.resolve(t - (a || 0)).parent.inlineContent) {
4318
4318
  if (a == null && i && (n < 0 || i == N(r))) {
4319
4319
  let e = r.childNodes[i - 1];
4320
- if (P(e)) return ji(e.getBoundingClientRect(), !1);
4320
+ if (P(e)) return Ai(e.getBoundingClientRect(), !1);
4321
4321
  }
4322
4322
  if (a == null && i < N(r)) {
4323
4323
  let e = r.childNodes[i];
4324
- if (P(e)) return ji(e.getBoundingClientRect(), !0);
4324
+ if (P(e)) return Ai(e.getBoundingClientRect(), !0);
4325
4325
  }
4326
- return ji(r.getBoundingClientRect(), n >= 0);
4326
+ return Ai(r.getBoundingClientRect(), n >= 0);
4327
4327
  }
4328
4328
  if (a == null && i && (n < 0 || i == N(r))) {
4329
4329
  let e = r.childNodes[i - 1], t = F(e) ? Pr(e, N(e) - +!o) : P(e) && (e.nodeName != "BR" || !e.nextSibling) ? e : null;
4330
- if (t) return Ai(Di(t, 1), !1);
4330
+ if (t) return ki(Ei(t, 1), !1);
4331
4331
  }
4332
4332
  if (a == null && i < N(r)) {
4333
4333
  let e = r.childNodes[i];
4334
4334
  for (; e.pmViewDesc && e.pmViewDesc.ignoreForCoords;) e = e.nextSibling;
4335
4335
  let t = e ? F(e) ? Pr(e, 0, +!o) : P(e) ? e : null : null;
4336
- if (t) return Ai(Di(t, -1), !0);
4336
+ if (t) return ki(Ei(t, -1), !0);
4337
4337
  }
4338
- return Ai(Di(F(r) ? Pr(r) : r, -n), n >= 0);
4338
+ return ki(Ei(F(r) ? Pr(r) : r, -n), n >= 0);
4339
4339
  }
4340
- function Ai(e, t) {
4340
+ function ki(e, t) {
4341
4341
  if (e.width == 0) return e;
4342
4342
  let n = t ? e.left : e.right;
4343
4343
  return {
@@ -4347,7 +4347,7 @@ function Ai(e, t) {
4347
4347
  right: n
4348
4348
  };
4349
4349
  }
4350
- function ji(e, t) {
4350
+ function Ai(e, t) {
4351
4351
  if (e.height == 0) return e;
4352
4352
  let n = t ? e.top : e.bottom;
4353
4353
  return {
@@ -4357,7 +4357,7 @@ function ji(e, t) {
4357
4357
  right: e.right
4358
4358
  };
4359
4359
  }
4360
- function Mi(e, t, n) {
4360
+ function ji(e, t, n) {
4361
4361
  let r = e.state, i = e.root.activeElement;
4362
4362
  r != t && e.updateState(t), i != e.dom && e.focus();
4363
4363
  try {
@@ -4366,9 +4366,9 @@ function Mi(e, t, n) {
4366
4366
  r != t && e.updateState(r), i != e.dom && i && i.focus();
4367
4367
  }
4368
4368
  }
4369
- function Ni(e, t, n) {
4369
+ function Mi(e, t, n) {
4370
4370
  let r = t.selection, i = n == "up" ? r.$from : r.$to;
4371
- return Mi(e, t, () => {
4371
+ return ji(e, t, () => {
4372
4372
  let { node: t } = e.docView.domFromPos(i.pos, n == "up" ? -1 : 1);
4373
4373
  for (;;) {
4374
4374
  let n = e.docView.nearestDesc(t, !0);
@@ -4379,7 +4379,7 @@ function Ni(e, t, n) {
4379
4379
  }
4380
4380
  t = n.dom.parentNode;
4381
4381
  }
4382
- let r = ki(e, i.pos, 1);
4382
+ let r = Oi(e, i.pos, 1);
4383
4383
  for (let e = t.firstChild; e; e = e.nextSibling) {
4384
4384
  let t;
4385
4385
  if (P(e)) t = e.getClientRects();
@@ -4393,12 +4393,12 @@ function Ni(e, t, n) {
4393
4393
  return !0;
4394
4394
  });
4395
4395
  }
4396
- var Pi = /[\u0590-\u08ac]/;
4397
- function Fi(e, t, n) {
4396
+ var Ni = /[\u0590-\u08ac]/;
4397
+ function Pi(e, t, n) {
4398
4398
  let { $head: r } = t.selection;
4399
4399
  if (!r.parent.isTextblock) return !1;
4400
4400
  let i = r.parentOffset, a = !i, o = i == r.parent.content.size, s = e.domSelection();
4401
- return s ? !Pi.test(r.parent.textContent) || !s.modify ? n == "left" || n == "backward" ? a : o : Mi(e, t, () => {
4401
+ return s ? !Ni.test(r.parent.textContent) || !s.modify ? n == "left" || n == "backward" ? a : o : ji(e, t, () => {
4402
4402
  let { focusNode: t, focusOffset: i, anchorNode: a, anchorOffset: o } = e.domSelectionRange(), c = s.caretBidiLevel;
4403
4403
  s.modify("move", n, "character");
4404
4404
  let l = r.depth ? e.docView.domAfterPos(r.before()) : e.dom, { focusNode: u, focusOffset: d } = e.domSelectionRange(), f = u && !zr(l, u) || t == u && i == d;
@@ -4408,13 +4408,13 @@ function Fi(e, t, n) {
4408
4408
  return c != null && (s.caretBidiLevel = c), f;
4409
4409
  }) : r.pos == r.start() || r.pos == r.end();
4410
4410
  }
4411
- var Ii = null, Li = null, Ri = !1;
4412
- function zi(e, t, n) {
4413
- return Ii == t && Li == n ? Ri : (Ii = t, Li = n, Ri = n == "up" || n == "down" ? Ni(e, t, n) : Fi(e, t, n));
4411
+ var Fi = null, Ii = null, Li = !1;
4412
+ function Ri(e, t, n) {
4413
+ return Fi == t && Ii == n ? Li : (Fi = t, Ii = n, Li = n == "up" || n == "down" ? Mi(e, t, n) : Pi(e, t, n));
4414
4414
  }
4415
- var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4415
+ var H = 0, zi = 1, Bi = 2, U = 3, Vi = class {
4416
4416
  constructor(e, t, n, r) {
4417
- this.parent = e, this.children = t, this.dom = n, this.contentDOM = r, this.dirty = V, n.pmViewDesc = this;
4417
+ this.parent = e, this.children = t, this.dom = n, this.contentDOM = r, this.dirty = H, n.pmViewDesc = this;
4418
4418
  }
4419
4419
  matchesWidget(e) {
4420
4420
  return !1;
@@ -4566,7 +4566,7 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4566
4566
  if (r) return this.children[n].domFromPos(r - this.children[n].border, t);
4567
4567
  for (; n > 0; n--) {
4568
4568
  let e = this.children[n - 1];
4569
- if (e.size || !(e instanceof Yi || e instanceof Ui && e.side >= 0)) break;
4569
+ if (e.size || !(e instanceof Ji || e instanceof Hi && e.side >= 0)) break;
4570
4570
  }
4571
4571
  if (t <= 0) {
4572
4572
  let e, r = !0;
@@ -4651,7 +4651,7 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4651
4651
  s = l;
4652
4652
  }
4653
4653
  let o = this.domFromPos(e, e ? -1 : 1), s = t == e ? o : this.domFromPos(t, t ? -1 : 1), c = n.root.getSelection(), l = n.domSelectionRange(), u = !1;
4654
- if ((L || z) && e == t) {
4654
+ if ((R || B) && e == t) {
4655
4655
  let { node: e, offset: t } = o;
4656
4656
  if (F(e)) {
4657
4657
  if (u = !!(t && e.nodeValue[t - 1] == "\n"), u && t == e.nodeValue.length) for (let t = e, n; t; t = t.parentNode) {
@@ -4670,13 +4670,13 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4670
4670
  u = n && (n.nodeName == "BR" || n.contentEditable == "false");
4671
4671
  }
4672
4672
  }
4673
- if (L && l.focusNode && l.focusNode != s.node && P(l.focusNode)) {
4673
+ if (R && l.focusNode && l.focusNode != s.node && P(l.focusNode)) {
4674
4674
  let e = l.focusNode.childNodes[l.focusOffset];
4675
4675
  e && e.contentEditable == "false" && (r = !0);
4676
4676
  }
4677
- if (!(r || u && z) && Ir(o.node, o.offset, l.anchorNode, l.anchorOffset) && Ir(s.node, s.offset, l.focusNode, l.focusOffset)) return;
4677
+ if (!(r || u && B) && Ir(o.node, o.offset, l.anchorNode, l.anchorOffset) && Ir(s.node, s.offset, l.focusNode, l.focusOffset)) return;
4678
4678
  let d = !1;
4679
- if ((c.extend || e == t) && !(u && L)) {
4679
+ if ((c.extend || e == t) && !(u && R)) {
4680
4680
  c.collapse(o.node, o.offset);
4681
4681
  try {
4682
4682
  e != t && c.extend(s.node, s.offset), d = !0;
@@ -4703,19 +4703,19 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4703
4703
  if (n == a ? e <= a && t >= n : e < a && t > n) {
4704
4704
  let r = n + i.border, o = a - i.border;
4705
4705
  if (e >= r && t <= o) {
4706
- this.dirty = e == n || t == a ? Vi : Bi, e == r && t == o && (i.contentLost || i.dom.parentNode != this.contentDOM) ? i.dirty = H : i.markDirty(e - r, t - r);
4706
+ this.dirty = e == n || t == a ? Bi : zi, e == r && t == o && (i.contentLost || i.dom.parentNode != this.contentDOM) ? i.dirty = U : i.markDirty(e - r, t - r);
4707
4707
  return;
4708
4708
  }
4709
- i.dirty = i.dom == i.contentDOM && i.dom.parentNode == this.contentDOM && !i.children.length ? Vi : H;
4709
+ i.dirty = i.dom == i.contentDOM && i.dom.parentNode == this.contentDOM && !i.children.length ? Bi : U;
4710
4710
  }
4711
4711
  n = a;
4712
4712
  }
4713
- this.dirty = Vi;
4713
+ this.dirty = Bi;
4714
4714
  }
4715
4715
  markParentsDirty() {
4716
4716
  let e = 1;
4717
4717
  for (let t = this.parent; t; t = t.parent, e++) {
4718
- let n = e == 1 ? Vi : Bi;
4718
+ let n = e == 1 ? Bi : zi;
4719
4719
  t.dirty < n && (t.dirty = n);
4720
4720
  }
4721
4721
  }
@@ -4731,7 +4731,7 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4731
4731
  isText(e) {
4732
4732
  return !1;
4733
4733
  }
4734
- }, Ui = class extends Hi {
4734
+ }, Hi = class extends Vi {
4735
4735
  constructor(e, t, n, r) {
4736
4736
  let i, a = t.type.toDOM;
4737
4737
  if (typeof a == "function" && (a = a(n, () => {
@@ -4744,7 +4744,7 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4744
4744
  super(e, [], a, null), this.widget = t, this.widget = t, i = this;
4745
4745
  }
4746
4746
  matchesWidget(e) {
4747
- return this.dirty == V && e.type.eq(this.widget.type);
4747
+ return this.dirty == H && e.type.eq(this.widget.type);
4748
4748
  }
4749
4749
  parseRule() {
4750
4750
  return { ignore: !0 };
@@ -4768,7 +4768,7 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4768
4768
  get side() {
4769
4769
  return this.widget.type.side;
4770
4770
  }
4771
- }, Wi = class extends Hi {
4771
+ }, Ui = class extends Vi {
4772
4772
  constructor(e, t, n, r) {
4773
4773
  super(e, [], t, null), this.textDOM = n, this.text = r;
4774
4774
  }
@@ -4787,7 +4787,7 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4787
4787
  ignoreMutation(e) {
4788
4788
  return e.type === "characterData" && e.target.nodeValue == e.oldValue;
4789
4789
  }
4790
- }, Gi = class e extends Hi {
4790
+ }, Wi = class e extends Vi {
4791
4791
  constructor(e, t, n, r, i) {
4792
4792
  super(e, [], n, r), this.mark = t, this.spec = i;
4793
4793
  }
@@ -4796,25 +4796,25 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4796
4796
  return o && o.dom || (o = $e.renderSpec(document, n.type.spec.toDOM(n, r), null, n.attrs)), new e(t, n, o.dom, o.contentDOM || o.dom, o);
4797
4797
  }
4798
4798
  parseRule() {
4799
- return this.dirty & H || this.mark.type.spec.reparseInView ? null : {
4799
+ return this.dirty & U || this.mark.type.spec.reparseInView ? null : {
4800
4800
  mark: this.mark.type.name,
4801
4801
  attrs: this.mark.attrs,
4802
4802
  contentElement: this.contentDOM
4803
4803
  };
4804
4804
  }
4805
4805
  matchesMark(e) {
4806
- return this.dirty != H && this.mark.eq(e);
4806
+ return this.dirty != U && this.mark.eq(e);
4807
4807
  }
4808
4808
  markDirty(e, t) {
4809
- if (super.markDirty(e, t), this.dirty != V) {
4809
+ if (super.markDirty(e, t), this.dirty != H) {
4810
4810
  let e = this.parent;
4811
4811
  for (; !e.node;) e = e.parent;
4812
- e.dirty < this.dirty && (e.dirty = this.dirty), this.dirty = V;
4812
+ e.dirty < this.dirty && (e.dirty = this.dirty), this.dirty = H;
4813
4813
  }
4814
4814
  }
4815
4815
  slice(t, n, r) {
4816
4816
  let i = e.create(this.parent, this.mark, !0, r), a = this.children, o = this.size;
4817
- n < o && (a = fa(a, n, o, r)), t > 0 && (a = fa(a, 0, t, r));
4817
+ n < o && (a = da(a, n, o, r)), t > 0 && (a = da(a, 0, t, r));
4818
4818
  for (let e = 0; e < a.length; e++) a[e].parent = i;
4819
4819
  return i.children = a, i;
4820
4820
  }
@@ -4824,7 +4824,7 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4824
4824
  destroy() {
4825
4825
  this.spec.destroy && this.spec.destroy(), super.destroy();
4826
4826
  }
4827
- }, Ki = class e extends Hi {
4827
+ }, Gi = class e extends Vi {
4828
4828
  constructor(e, t, n, r, i, a, o) {
4829
4829
  super(e, [], i, a), this.node = t, this.outerDeco = n, this.innerDeco = r, this.nodeDOM = o;
4830
4830
  }
@@ -4842,7 +4842,7 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4842
4842
  }
4843
4843
  !d && !n.isText && u.nodeName != "BR" && (u.hasAttribute("contenteditable") || (u.contentEditable = "false"), n.type.spec.draggable && (u.draggable = !0));
4844
4844
  let f = u;
4845
- return u = ra(u, r, n), l ? c = new Xi(t, n, r, i, u, d || null, f, l) : n.isText ? new Ji(t, n, r, i, u, f) : new e(t, n, r, i, u, d || null, f);
4845
+ return u = na(u, r, n), l ? c = new Yi(t, n, r, i, u, d || null, f, l) : n.isText ? new qi(t, n, r, i, u, f) : new e(t, n, r, i, u, d || null, f);
4846
4846
  }
4847
4847
  parseRule(e) {
4848
4848
  if (this.node.type.spec.reparseInView) return null;
@@ -4868,7 +4868,7 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4868
4868
  return t;
4869
4869
  }
4870
4870
  matchesNode(e, t, n) {
4871
- return this.dirty == V && e.eq(this.node) && ia(t, this.outerDeco) && n.eq(this.innerDeco);
4871
+ return this.dirty == H && e.eq(this.node) && ra(t, this.outerDeco) && n.eq(this.innerDeco);
4872
4872
  }
4873
4873
  get size() {
4874
4874
  return this.node.nodeSize;
@@ -4877,14 +4877,14 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4877
4877
  return +!this.node.isLeaf;
4878
4878
  }
4879
4879
  updateChildren(e, t) {
4880
- let n = this.node.inlineContent, r = t, i = e.composing ? this.localCompositionInfo(e, t) : null, a = i && i.pos > -1 ? i : null, o = i && i.pos < 0, s = new oa(this, a && a.node, e), c = this.node.inlineContent, l = c && this.node.isBlock;
4881
- la(this.node, this.innerDeco, (t, i, a) => {
4880
+ let n = this.node.inlineContent, r = t, i = e.composing ? this.localCompositionInfo(e, t) : null, a = i && i.pos > -1 ? i : null, o = i && i.pos < 0, s = new aa(this, a && a.node, e), c = this.node.inlineContent, l = c && this.node.isBlock;
4881
+ ca(this.node, this.innerDeco, (t, i, a) => {
4882
4882
  t.spec.marks ? s.syncToMarks(t.spec.marks, n, e, i) : t.type.side >= 0 && !a && s.syncToMarks(i == this.node.childCount ? d.none : this.node.child(i).marks, n, e, i), s.placeWidget(t, e, r);
4883
4883
  }, (t, a, u, d) => {
4884
4884
  s.syncToMarks(t.marks, n, e, d), l && t.isAtom && !t.isText && s.addHackNode("IMG", s.top);
4885
4885
  let f;
4886
4886
  s.findNodeMatch(t, a, u, d) || o && e.state.selection.from > r && e.state.selection.to < r + t.nodeSize && (f = s.findIndexWithChild(i.node)) > -1 && s.updateNodeAt(t, a, u, f, e) || s.updateNextNode(t, a, u, e, d, r) || s.addNode(t, a, u, e, r), r += t.nodeSize, c && (l = t.isAtom && !t.isText);
4887
- }), s.syncToMarks([], n, e, 0), this.node.isTextblock && s.addTextblockHacks(), s.destroyRest(), (s.changed || this.dirty == Vi) && (a && this.protectLocalComposition(e, a), Zi(this.contentDOM, this.children, e), ri && ua(this.dom));
4887
+ }), s.syncToMarks([], n, e, 0), this.node.isTextblock && s.addTextblockHacks(), s.destroyRest(), (s.changed || this.dirty == Bi) && (a && this.protectLocalComposition(e, a), Xi(this.contentDOM, this.children, e), ni && la(this.dom));
4888
4888
  }
4889
4889
  localCompositionInfo(e, t) {
4890
4890
  let { from: n, to: r } = e.state.selection;
@@ -4892,7 +4892,7 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4892
4892
  let i = e.input.compositionNode;
4893
4893
  if (!i || !this.dom.contains(i.parentNode)) return null;
4894
4894
  if (this.node.inlineContent) {
4895
- let e = i.nodeValue, a = da(this.node.content, e, n - t, r - t);
4895
+ let e = i.nodeValue, a = ua(this.node.content, e, n - t, r - t);
4896
4896
  return a < 0 ? null : {
4897
4897
  node: i,
4898
4898
  pos: a,
@@ -4913,19 +4913,19 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4913
4913
  for (; i.nextSibling;) i.parentNode.removeChild(i.nextSibling);
4914
4914
  i.pmViewDesc && (i.pmViewDesc = void 0);
4915
4915
  }
4916
- let a = new Wi(this, i, t, r);
4917
- e.input.compositionNodes.push(a), this.children = fa(this.children, n, n + r.length, e, a);
4916
+ let a = new Ui(this, i, t, r);
4917
+ e.input.compositionNodes.push(a), this.children = da(this.children, n, n + r.length, e, a);
4918
4918
  }
4919
4919
  update(e, t, n, r) {
4920
- return this.dirty == H || !e.sameMarkup(this.node) ? !1 : (this.updateInner(e, t, n, r), !0);
4920
+ return this.dirty == U || !e.sameMarkup(this.node) ? !1 : (this.updateInner(e, t, n, r), !0);
4921
4921
  }
4922
4922
  updateInner(e, t, n, r) {
4923
- this.updateOuterDeco(t), this.node = e, this.innerDeco = n, this.contentDOM && this.updateChildren(r, this.posAtStart), this.dirty = V;
4923
+ this.updateOuterDeco(t), this.node = e, this.innerDeco = n, this.contentDOM && this.updateChildren(r, this.posAtStart), this.dirty = H;
4924
4924
  }
4925
4925
  updateOuterDeco(e) {
4926
- if (ia(e, this.outerDeco)) return;
4926
+ if (ra(e, this.outerDeco)) return;
4927
4927
  let t = !P(this.nodeDOM), n = this.dom;
4928
- this.dom = ta(this.dom, this.nodeDOM, ea(this.outerDeco, this.node, t), ea(e, this.node, t)), this.dom != n && (n.pmViewDesc = void 0, this.dom.pmViewDesc = this), this.outerDeco = e;
4928
+ this.dom = ea(this.dom, this.nodeDOM, $i(this.outerDeco, this.node, t), $i(e, this.node, t)), this.dom != n && (n.pmViewDesc = void 0, this.dom.pmViewDesc = this), this.outerDeco = e;
4929
4929
  }
4930
4930
  selectNode() {
4931
4931
  P(this.nodeDOM) && (this.nodeDOM.classList.add("ProseMirror-selectednode"), (this.contentDOM || !this.node.type.spec.draggable) && (this.nodeDOM.draggable = !0));
@@ -4937,12 +4937,12 @@ var V = 0, Bi = 1, Vi = 2, H = 3, Hi = class {
4937
4937
  return this.node.isAtom;
4938
4938
  }
4939
4939
  };
4940
- function qi(e, t, n, r, i) {
4941
- ra(r, t, e);
4942
- let a = new Ki(void 0, e, t, n, r, r, r);
4940
+ function Ki(e, t, n, r, i) {
4941
+ na(r, t, e);
4942
+ let a = new Gi(void 0, e, t, n, r, r, r);
4943
4943
  return a.contentDOM && a.updateChildren(i, 0), a;
4944
4944
  }
4945
- var Ji = class e extends Ki {
4945
+ var qi = class e extends Gi {
4946
4946
  constructor(e, t, n, r, i, a) {
4947
4947
  super(e, t, n, r, i, null, a);
4948
4948
  }
@@ -4952,7 +4952,7 @@ var Ji = class e extends Ki {
4952
4952
  return { skip: e || !0 };
4953
4953
  }
4954
4954
  update(e, t, n, r) {
4955
- return this.dirty == H || this.dirty != V && !this.inParent() || !e.sameMarkup(this.node) ? !1 : (this.updateOuterDeco(t), (this.dirty != V || e.text != this.node.text) && e.text != this.nodeDOM.nodeValue && (this.nodeDOM.nodeValue = e.text, r.trackWrites == this.nodeDOM && (r.trackWrites = null)), this.node = e, this.dirty = V, !0);
4955
+ return this.dirty == U || this.dirty != H && !this.inParent() || !e.sameMarkup(this.node) ? !1 : (this.updateOuterDeco(t), (this.dirty != H || e.text != this.node.text) && e.text != this.nodeDOM.nodeValue && (this.nodeDOM.nodeValue = e.text, r.trackWrites == this.nodeDOM && (r.trackWrites = null)), this.node = e, this.dirty = H, !0);
4956
4956
  }
4957
4957
  inParent() {
4958
4958
  let e = this.parent.contentDOM;
@@ -4976,7 +4976,7 @@ var Ji = class e extends Ki {
4976
4976
  return new e(this.parent, i, this.outerDeco, this.innerDeco, a, a);
4977
4977
  }
4978
4978
  markDirty(e, t) {
4979
- super.markDirty(e, t), this.dom != this.nodeDOM && (e == 0 || t == this.nodeDOM.nodeValue.length) && (this.dirty = H);
4979
+ super.markDirty(e, t), this.dom != this.nodeDOM && (e == 0 || t == this.nodeDOM.nodeValue.length) && (this.dirty = U);
4980
4980
  }
4981
4981
  get domAtom() {
4982
4982
  return !1;
@@ -4984,12 +4984,12 @@ var Ji = class e extends Ki {
4984
4984
  isText(e) {
4985
4985
  return this.node.text == e;
4986
4986
  }
4987
- }, Yi = class extends Hi {
4987
+ }, Ji = class extends Vi {
4988
4988
  parseRule() {
4989
4989
  return { ignore: !0 };
4990
4990
  }
4991
4991
  matchesHack(e) {
4992
- return this.dirty == V && this.dom.nodeName == e;
4992
+ return this.dirty == H && this.dom.nodeName == e;
4993
4993
  }
4994
4994
  get domAtom() {
4995
4995
  return !0;
@@ -4997,12 +4997,12 @@ var Ji = class e extends Ki {
4997
4997
  get ignoreForCoords() {
4998
4998
  return this.dom.nodeName == "IMG";
4999
4999
  }
5000
- }, Xi = class extends Ki {
5000
+ }, Yi = class extends Gi {
5001
5001
  constructor(e, t, n, r, i, a, o, s) {
5002
5002
  super(e, t, n, r, i, a, o), this.spec = s;
5003
5003
  }
5004
5004
  update(e, t, n, r) {
5005
- if (this.dirty == H) return !1;
5005
+ if (this.dirty == U) return !1;
5006
5006
  if (this.spec.update && (this.node.type == e.type || this.spec.multiType)) {
5007
5007
  let i = this.spec.update(e, t, n);
5008
5008
  return i && this.updateInner(e, t, n, r), i;
@@ -5028,56 +5028,56 @@ var Ji = class e extends Ki {
5028
5028
  return this.spec.ignoreMutation ? this.spec.ignoreMutation(e) : super.ignoreMutation(e);
5029
5029
  }
5030
5030
  };
5031
- function Zi(e, t, n) {
5031
+ function Xi(e, t, n) {
5032
5032
  let r = e.firstChild, i = !1;
5033
5033
  for (let a = 0; a < t.length; a++) {
5034
5034
  let o = t[a], s = o.dom;
5035
5035
  if (s.parentNode == e) {
5036
- for (; s != r;) r = aa(r), i = !0;
5036
+ for (; s != r;) r = ia(r), i = !0;
5037
5037
  r = r.nextSibling;
5038
5038
  } else i = !0, e.insertBefore(s, r);
5039
- if (o instanceof Gi) {
5039
+ if (o instanceof Wi) {
5040
5040
  let t = r ? r.previousSibling : e.lastChild;
5041
- Zi(o.contentDOM, o.children, n), r = t ? t.nextSibling : e.firstChild;
5041
+ Xi(o.contentDOM, o.children, n), r = t ? t.nextSibling : e.firstChild;
5042
5042
  }
5043
5043
  }
5044
- for (; r;) r = aa(r), i = !0;
5044
+ for (; r;) r = ia(r), i = !0;
5045
5045
  i && n.trackWrites == e && (n.trackWrites = null);
5046
5046
  }
5047
- var Qi = function(e) {
5047
+ var Zi = function(e) {
5048
5048
  e && (this.nodeName = e);
5049
5049
  };
5050
- Qi.prototype = Object.create(null);
5051
- var $i = [new Qi()];
5052
- function ea(e, t, n) {
5053
- if (e.length == 0) return $i;
5054
- let r = n ? $i[0] : new Qi(), i = [r];
5050
+ Zi.prototype = Object.create(null);
5051
+ var Qi = [new Zi()];
5052
+ function $i(e, t, n) {
5053
+ if (e.length == 0) return Qi;
5054
+ let r = n ? Qi[0] : new Zi(), i = [r];
5055
5055
  for (let a = 0; a < e.length; a++) {
5056
5056
  let o = e[a].type.attrs;
5057
5057
  if (o) {
5058
- o.nodeName && i.push(r = new Qi(o.nodeName));
5058
+ o.nodeName && i.push(r = new Zi(o.nodeName));
5059
5059
  for (let e in o) {
5060
5060
  let a = o[e];
5061
- a != null && (n && i.length == 1 && i.push(r = new Qi(t.isInline ? "span" : "div")), e == "class" ? r.class = (r.class ? r.class + " " : "") + a : e == "style" ? r.style = (r.style ? r.style + ";" : "") + a : e != "nodeName" && (r[e] = a));
5061
+ a != null && (n && i.length == 1 && i.push(r = new Zi(t.isInline ? "span" : "div")), e == "class" ? r.class = (r.class ? r.class + " " : "") + a : e == "style" ? r.style = (r.style ? r.style + ";" : "") + a : e != "nodeName" && (r[e] = a));
5062
5062
  }
5063
5063
  }
5064
5064
  }
5065
5065
  return i;
5066
5066
  }
5067
- function ta(e, t, n, r) {
5068
- if (n == $i && r == $i) return t;
5067
+ function ea(e, t, n, r) {
5068
+ if (n == Qi && r == Qi) return t;
5069
5069
  let i = t;
5070
5070
  for (let t = 0; t < r.length; t++) {
5071
5071
  let a = r[t], o = n[t];
5072
5072
  if (t) {
5073
5073
  let t;
5074
- o && o.nodeName == a.nodeName && i != e && (t = i.parentNode) && t.nodeName.toLowerCase() == a.nodeName || (t = document.createElement(a.nodeName), t.pmIsDeco = !0, t.appendChild(i), o = $i[0]), i = t;
5074
+ o && o.nodeName == a.nodeName && i != e && (t = i.parentNode) && t.nodeName.toLowerCase() == a.nodeName || (t = document.createElement(a.nodeName), t.pmIsDeco = !0, t.appendChild(i), o = Qi[0]), i = t;
5075
5075
  }
5076
- na(i, o || $i[0], a);
5076
+ ta(i, o || Qi[0], a);
5077
5077
  }
5078
5078
  return i;
5079
5079
  }
5080
- function na(e, t, n) {
5080
+ function ta(e, t, n) {
5081
5081
  for (let r in t) r != "class" && r != "style" && r != "nodeName" && !(r in n) && e.removeAttribute(r);
5082
5082
  for (let r in n) r != "class" && r != "style" && r != "nodeName" && n[r] != t[r] && e.setAttribute(r, n[r]);
5083
5083
  if (t.class != n.class) {
@@ -5094,21 +5094,21 @@ function na(e, t, n) {
5094
5094
  n.style && (e.style.cssText += n.style);
5095
5095
  }
5096
5096
  }
5097
- function ra(e, t, n) {
5098
- return ta(e, e, $i, ea(t, n, !P(e)));
5097
+ function na(e, t, n) {
5098
+ return ea(e, e, Qi, $i(t, n, !P(e)));
5099
5099
  }
5100
- function ia(e, t) {
5100
+ function ra(e, t) {
5101
5101
  if (e.length != t.length) return !1;
5102
5102
  for (let n = 0; n < e.length; n++) if (!e[n].type.eq(t[n].type)) return !1;
5103
5103
  return !0;
5104
5104
  }
5105
- function aa(e) {
5105
+ function ia(e) {
5106
5106
  let t = e.nextSibling;
5107
5107
  return e.parentNode.removeChild(e), t;
5108
5108
  }
5109
- var oa = class {
5109
+ var aa = class {
5110
5110
  constructor(e, t, n) {
5111
- this.lock = t, this.view = n, this.index = 0, this.stack = [], this.changed = !1, this.top = e, this.preMatch = sa(e.node.content, e);
5111
+ this.lock = t, this.view = n, this.index = 0, this.stack = [], this.changed = !1, this.top = e, this.preMatch = oa(e.node.content, e);
5112
5112
  }
5113
5113
  destroyBetween(e, t) {
5114
5114
  if (e != t) {
@@ -5122,7 +5122,7 @@ var oa = class {
5122
5122
  syncToMarks(e, t, n, r) {
5123
5123
  let i = 0, a = this.stack.length >> 1, o = Math.min(a, e.length);
5124
5124
  for (; i < o && (i == a - 1 ? this.top : this.stack[i + 1 << 1]).matchesMark(e[i]) && e[i].type.spec.spanning !== !1;) i++;
5125
- for (; i < a;) this.destroyRest(), this.top.dirty = V, this.index = this.stack.pop(), this.top = this.stack.pop(), a--;
5125
+ for (; i < a;) this.destroyRest(), this.top.dirty = H, this.index = this.stack.pop(), this.top = this.stack.pop(), a--;
5126
5126
  for (; a < e.length;) {
5127
5127
  this.stack.push(this.top, this.index + 1);
5128
5128
  let i = -1, o = this.top.children.length;
@@ -5136,11 +5136,11 @@ var oa = class {
5136
5136
  }
5137
5137
  if (i < 0 && this.index < this.top.children.length) {
5138
5138
  let t = this.top.children[this.index];
5139
- t instanceof Gi && t.dirty != H && t.mark.type == e[a].type && t.spec.update && !this.isLocked(t.dom) && t.spec.update(e[a]) && (t.mark = e[a], i = this.index, this.changed = !0);
5139
+ t instanceof Wi && t.dirty != U && t.mark.type == e[a].type && t.spec.update && !this.isLocked(t.dom) && t.spec.update(e[a]) && (t.mark = e[a], i = this.index, this.changed = !0);
5140
5140
  }
5141
5141
  if (i > -1) i > this.index && (this.changed = !0, this.destroyBetween(this.index, i)), this.top = this.top.children[this.index];
5142
5142
  else {
5143
- let r = Gi.create(this.top, e[a], t, n);
5143
+ let r = Wi.create(this.top, e[a], t, n);
5144
5144
  this.top.children.splice(this.index, 0, r), this.top = r, this.changed = !0;
5145
5145
  }
5146
5146
  this.index = 0, a++;
@@ -5160,7 +5160,7 @@ var oa = class {
5160
5160
  }
5161
5161
  updateNodeAt(e, t, n, r, i) {
5162
5162
  let a = this.top.children[r];
5163
- return a.dirty == H && a.dom == a.contentDOM && (a.dirty = Vi), a.update(e, t, n, i) ? (this.destroyBetween(this.index, r), this.index++, !0) : !1;
5163
+ return a.dirty == U && a.dom == a.contentDOM && (a.dirty = Bi), a.update(e, t, n, i) ? (this.destroyBetween(this.index, r), this.index++, !0) : !1;
5164
5164
  }
5165
5165
  findIndexWithChild(e) {
5166
5166
  for (;;) {
@@ -5179,20 +5179,20 @@ var oa = class {
5179
5179
  updateNextNode(e, t, n, r, i, a) {
5180
5180
  for (let o = this.index; o < this.top.children.length; o++) {
5181
5181
  let s = this.top.children[o];
5182
- if (s instanceof Ki) {
5182
+ if (s instanceof Gi) {
5183
5183
  let c = this.preMatch.matched.get(s);
5184
5184
  if (c != null && c != i) return !1;
5185
- let l = s.dom, u, d = this.isLocked(l) && !(e.isText && s.node && s.node.isText && s.nodeDOM.nodeValue == e.text && s.dirty != H && ia(t, s.outerDeco));
5185
+ let l = s.dom, u, d = this.isLocked(l) && !(e.isText && s.node && s.node.isText && s.nodeDOM.nodeValue == e.text && s.dirty != U && ra(t, s.outerDeco));
5186
5186
  if (!d && s.update(e, t, n, r)) return this.destroyBetween(this.index, o), s.dom != l && (this.changed = !0), this.index++, !0;
5187
- if (!d && (u = this.recreateWrapper(s, e, t, n, r, a))) return this.destroyBetween(this.index, o), this.top.children[this.index] = u, u.contentDOM && (u.dirty = Vi, u.updateChildren(r, a + 1), u.dirty = V), this.changed = !0, this.index++, !0;
5187
+ if (!d && (u = this.recreateWrapper(s, e, t, n, r, a))) return this.destroyBetween(this.index, o), this.top.children[this.index] = u, u.contentDOM && (u.dirty = Bi, u.updateChildren(r, a + 1), u.dirty = H), this.changed = !0, this.index++, !0;
5188
5188
  break;
5189
5189
  }
5190
5190
  }
5191
5191
  return !1;
5192
5192
  }
5193
5193
  recreateWrapper(e, t, n, r, i, a) {
5194
- if (e.dirty || t.isAtom || !e.children.length || !e.node.content.eq(t.content) || !ia(n, e.outerDeco) || !r.eq(e.innerDeco)) return null;
5195
- let o = Ki.create(this.top, t, n, r, i, a);
5194
+ if (e.dirty || t.isAtom || !e.children.length || !e.node.content.eq(t.content) || !ra(n, e.outerDeco) || !r.eq(e.innerDeco)) return null;
5195
+ let o = Gi.create(this.top, t, n, r, i, a);
5196
5196
  if (o.contentDOM) {
5197
5197
  o.children = e.children, e.children = [];
5198
5198
  for (let e of o.children) e.parent = o;
@@ -5200,28 +5200,28 @@ var oa = class {
5200
5200
  return e.destroy(), o;
5201
5201
  }
5202
5202
  addNode(e, t, n, r, i) {
5203
- let a = Ki.create(this.top, e, t, n, r, i);
5203
+ let a = Gi.create(this.top, e, t, n, r, i);
5204
5204
  a.contentDOM && a.updateChildren(r, i + 1), this.top.children.splice(this.index++, 0, a), this.changed = !0;
5205
5205
  }
5206
5206
  placeWidget(e, t, n) {
5207
5207
  let r = this.index < this.top.children.length ? this.top.children[this.index] : null;
5208
5208
  if (r && r.matchesWidget(e) && (e == r.widget || !r.widget.type.toDOM.parentNode)) this.index++;
5209
5209
  else {
5210
- let r = new Ui(this.top, e, t, n);
5210
+ let r = new Hi(this.top, e, t, n);
5211
5211
  this.top.children.splice(this.index++, 0, r), this.changed = !0;
5212
5212
  }
5213
5213
  }
5214
5214
  addTextblockHacks() {
5215
5215
  let e = this.top.children[this.index - 1], t = this.top;
5216
- for (; e instanceof Gi;) t = e, e = t.children[t.children.length - 1];
5217
- (!e || !(e instanceof Ji) || /\n$/.test(e.node.text) || this.view.requiresGeckoHackNode && /\s$/.test(e.node.text)) && ((z || R) && e && e.dom.contentEditable == "false" && this.addHackNode("IMG", t), this.addHackNode("BR", this.top));
5216
+ for (; e instanceof Wi;) t = e, e = t.children[t.children.length - 1];
5217
+ (!e || !(e instanceof qi) || /\n$/.test(e.node.text) || this.view.requiresGeckoHackNode && /\s$/.test(e.node.text)) && ((B || z) && e && e.dom.contentEditable == "false" && this.addHackNode("IMG", t), this.addHackNode("BR", this.top));
5218
5218
  }
5219
5219
  addHackNode(e, t) {
5220
5220
  if (t == this.top && this.index < t.children.length && t.children[this.index].matchesHack(e)) this.index++;
5221
5221
  else {
5222
5222
  let n = document.createElement(e);
5223
5223
  e == "IMG" && (n.className = "ProseMirror-separator", n.alt = ""), e == "BR" && (n.className = "ProseMirror-trailingBreak");
5224
- let r = new Yi(this.top, [], n, null);
5224
+ let r = new Ji(this.top, [], n, null);
5225
5225
  t == this.top ? t.children.splice(this.index++, 0, r) : t.children.push(r), this.changed = !0;
5226
5226
  }
5227
5227
  }
@@ -5229,13 +5229,13 @@ var oa = class {
5229
5229
  return this.lock && (e == this.lock || P(e) && e.contains(this.lock.parentNode));
5230
5230
  }
5231
5231
  };
5232
- function sa(e, t) {
5232
+ function oa(e, t) {
5233
5233
  let n = t, r = n.children.length, i = e.childCount, a = /* @__PURE__ */ new Map(), o = [];
5234
5234
  outer: for (; i > 0;) {
5235
5235
  let s;
5236
5236
  for (;;) if (r) {
5237
5237
  let e = n.children[r - 1];
5238
- if (e instanceof Gi) n = e, r = e.children.length;
5238
+ if (e instanceof Wi) n = e, r = e.children.length;
5239
5239
  else {
5240
5240
  s = e, r--;
5241
5241
  break;
@@ -5254,10 +5254,10 @@ function sa(e, t) {
5254
5254
  matches: o.reverse()
5255
5255
  };
5256
5256
  }
5257
- function ca(e, t) {
5257
+ function sa(e, t) {
5258
5258
  return e.type.side - t.type.side;
5259
5259
  }
5260
- function la(e, t, n, r) {
5260
+ function ca(e, t, n, r) {
5261
5261
  let i = t.locals(e), a = 0;
5262
5262
  if (i.length == 0) {
5263
5263
  for (let n = 0; n < e.childCount; n++) {
@@ -5275,7 +5275,7 @@ function la(e, t, n, r) {
5275
5275
  }
5276
5276
  if (u) {
5277
5277
  if (d) {
5278
- d.sort(ca);
5278
+ d.sort(sa);
5279
5279
  for (let e = 0; e < d.length; e++) n(d[e], l, !!c);
5280
5280
  } else n(u, l, !!c);
5281
5281
  }
@@ -5296,13 +5296,13 @@ function la(e, t, n, r) {
5296
5296
  r(f, h, t.forChild(a, f), p), a = m;
5297
5297
  }
5298
5298
  }
5299
- function ua(e) {
5299
+ function la(e) {
5300
5300
  if (e.nodeName == "UL" || e.nodeName == "OL") {
5301
5301
  let t = e.style.cssText;
5302
5302
  e.style.cssText = t + "; list-style: square !important", window.getComputedStyle(e).listStyle, e.style.cssText = t;
5303
5303
  }
5304
5304
  }
5305
- function da(e, t, n, r) {
5305
+ function ua(e, t, n, r) {
5306
5306
  for (let i = 0, a = 0; i < e.childCount && a <= r;) {
5307
5307
  let o = e.child(i++), s = a;
5308
5308
  if (a += o.nodeSize, !o.isText) continue;
@@ -5321,7 +5321,7 @@ function da(e, t, n, r) {
5321
5321
  }
5322
5322
  return -1;
5323
5323
  }
5324
- function fa(e, t, n, r, i) {
5324
+ function da(e, t, n, r, i) {
5325
5325
  let a = [];
5326
5326
  for (let o = 0, s = 0; o < e.length; o++) {
5327
5327
  let c = e[o], l = s, u = s += c.size;
@@ -5329,7 +5329,7 @@ function fa(e, t, n, r, i) {
5329
5329
  }
5330
5330
  return a;
5331
5331
  }
5332
- function pa(e, t = null) {
5332
+ function fa(e, t = null) {
5333
5333
  let n = e.domSelectionRange(), r = e.state.doc;
5334
5334
  if (!n.focusNode) return null;
5335
5335
  let i = e.docView.nearestDesc(n.focusNode), a = i && i.size == 0, o = e.docView.posFromDOM(n.focusNode, n.focusOffset, 1);
@@ -5340,7 +5340,7 @@ function pa(e, t = null) {
5340
5340
  if (i && i.node.isAtom && k.isSelectable(i.node) && i.parent && !(i.node.isInline && Hr(n.focusNode, n.focusOffset, i.dom))) {
5341
5341
  let e = i.posBefore;
5342
5342
  l = new k(o == e ? s : r.resolve(e));
5343
- } else if (L && t == "key" && o > e.state.selection.to && P(n.focusNode) && n.focusOffset == n.focusNode.childNodes.length && i && i.posAtStart > e.state.selection.to) for (let e = n.focusNode;; e = e.parentNode) {
5343
+ } else if (R && t == "key" && o > e.state.selection.to && P(n.focusNode) && n.focusOffset == n.focusNode.childNodes.length && i && i.posAtStart > e.state.selection.to) for (let e = n.focusNode;; e = e.parentNode) {
5344
5344
  if (getComputedStyle(e).overflow != "visible") {
5345
5345
  l = D.findFrom(r.resolve(i.posAtStart), 1);
5346
5346
  break;
@@ -5362,78 +5362,78 @@ function pa(e, t = null) {
5362
5362
  let u = r.resolve(c);
5363
5363
  if (!l) {
5364
5364
  let n = t == "pointer" || e.state.selection.head < s.pos && !a ? 1 : -1;
5365
- l = wa(e, u, s, n);
5365
+ l = Ca(e, u, s, n);
5366
5366
  }
5367
5367
  return l;
5368
5368
  }
5369
- function ma(e) {
5370
- return e.editable ? e.hasFocus() : Ea(e) && document.activeElement && document.activeElement.contains(e.dom);
5369
+ function pa(e) {
5370
+ return e.editable ? e.hasFocus() : Ta(e) && document.activeElement && document.activeElement.contains(e.dom);
5371
5371
  }
5372
- function ha(e, t = !1) {
5372
+ function ma(e, t = !1) {
5373
5373
  let n = e.state.selection;
5374
- if (Sa(e, n), !ma(e)) return;
5374
+ if (xa(e, n), !pa(e)) return;
5375
5375
  let r = e.input.mouseDown;
5376
- if (!t && R && r) {
5376
+ if (!t && z && r) {
5377
5377
  let t = e.domSelectionRange(), n = e.domObserver.currentSelection;
5378
5378
  if (t.anchorNode && n.anchorNode && Ir(t.anchorNode, t.anchorOffset, n.anchorNode, n.anchorOffset) && r.delaySelUpdate()) {
5379
5379
  e.domObserver.setCurSelection();
5380
5380
  return;
5381
5381
  }
5382
5382
  }
5383
- if (e.domObserver.disconnectSelection(), e.cursorWrapper) xa(e);
5383
+ if (e.domObserver.disconnectSelection(), e.cursorWrapper) ba(e);
5384
5384
  else {
5385
5385
  let { anchor: r, head: i } = n, a, o;
5386
- ga && !(n instanceof O) && (n.$from.parent.inlineContent || (a = _a(e, n.from)), !n.empty && !n.$from.parent.inlineContent && (o = _a(e, n.to))), e.docView.setSelection(r, i, e, t), ga && (a && ya(a), o && ya(o)), n.visible ? e.dom.classList.remove("ProseMirror-hideselection") : (e.dom.classList.add("ProseMirror-hideselection"), "onselectionchange" in document && ba(e));
5386
+ ha && !(n instanceof O) && (n.$from.parent.inlineContent || (a = ga(e, n.from)), !n.empty && !n.$from.parent.inlineContent && (o = ga(e, n.to))), e.docView.setSelection(r, i, e, t), ha && (a && va(a), o && va(o)), n.visible ? e.dom.classList.remove("ProseMirror-hideselection") : (e.dom.classList.add("ProseMirror-hideselection"), "onselectionchange" in document && ya(e));
5387
5387
  }
5388
5388
  e.domObserver.setCurSelection(), e.domObserver.connectSelection();
5389
5389
  }
5390
- var ga = z || R && ni < 63;
5391
- function _a(e, t) {
5390
+ var ha = B || z && ti < 63;
5391
+ function ga(e, t) {
5392
5392
  let { node: n, offset: r } = e.docView.domFromPos(t, 0), i = r < n.childNodes.length ? n.childNodes[r] : null, a = r ? n.childNodes[r - 1] : null;
5393
- if (z && i && i.contentEditable == "false") return va(i);
5393
+ if (B && i && i.contentEditable == "false") return _a(i);
5394
5394
  if ((!i || i.contentEditable == "false") && (!a || a.contentEditable == "false")) {
5395
- if (i) return va(i);
5396
- if (a) return va(a);
5395
+ if (i) return _a(i);
5396
+ if (a) return _a(a);
5397
5397
  }
5398
5398
  }
5399
- function va(e) {
5400
- return e.contentEditable = "true", z && e.draggable && (e.draggable = !1, e.wasDraggable = !0), e;
5399
+ function _a(e) {
5400
+ return e.contentEditable = "true", B && e.draggable && (e.draggable = !1, e.wasDraggable = !0), e;
5401
5401
  }
5402
- function ya(e) {
5402
+ function va(e) {
5403
5403
  e.contentEditable = "false", e.wasDraggable &&= (e.draggable = !0, null);
5404
5404
  }
5405
- function ba(e) {
5405
+ function ya(e) {
5406
5406
  let t = e.dom.ownerDocument;
5407
5407
  t.removeEventListener("selectionchange", e.input.hideSelectionGuard);
5408
5408
  let n = e.domSelectionRange(), r = n.anchorNode, i = n.anchorOffset;
5409
5409
  t.addEventListener("selectionchange", e.input.hideSelectionGuard = () => {
5410
5410
  (n.anchorNode != r || n.anchorOffset != i) && (t.removeEventListener("selectionchange", e.input.hideSelectionGuard), setTimeout(() => {
5411
- (!ma(e) || e.state.selection.visible) && e.dom.classList.remove("ProseMirror-hideselection");
5411
+ (!pa(e) || e.state.selection.visible) && e.dom.classList.remove("ProseMirror-hideselection");
5412
5412
  }, 20));
5413
5413
  });
5414
5414
  }
5415
- function xa(e) {
5415
+ function ba(e) {
5416
5416
  let t = e.domSelection();
5417
5417
  if (!t) return;
5418
5418
  let n = e.cursorWrapper.dom, r = n.nodeName == "IMG";
5419
- r ? t.collapse(n.parentNode, M(n) + 1) : t.collapse(n, 0), !r && !e.state.selection.visible && I && ei <= 11 && (n.disabled = !0, n.disabled = !1);
5419
+ r ? t.collapse(n.parentNode, M(n) + 1) : t.collapse(n, 0), !r && !e.state.selection.visible && L && $r <= 11 && (n.disabled = !0, n.disabled = !1);
5420
5420
  }
5421
- function Sa(e, t) {
5421
+ function xa(e, t) {
5422
5422
  if (t instanceof k) {
5423
5423
  let n = e.docView.descAt(t.from);
5424
- n != e.lastSelectedViewDesc && (Ca(e), n && n.selectNode(), e.lastSelectedViewDesc = n);
5425
- } else Ca(e);
5424
+ n != e.lastSelectedViewDesc && (Sa(e), n && n.selectNode(), e.lastSelectedViewDesc = n);
5425
+ } else Sa(e);
5426
5426
  }
5427
- function Ca(e) {
5427
+ function Sa(e) {
5428
5428
  e.lastSelectedViewDesc &&= (e.lastSelectedViewDesc.parent && e.lastSelectedViewDesc.deselectNode(), void 0);
5429
5429
  }
5430
- function wa(e, t, n, r) {
5430
+ function Ca(e, t, n, r) {
5431
5431
  return e.someProp("createSelectionBetween", (r) => r(e, t, n)) || O.between(t, n, r);
5432
5432
  }
5433
- function Ta(e) {
5434
- return e.editable && !e.hasFocus() ? !1 : Ea(e);
5433
+ function wa(e) {
5434
+ return e.editable && !e.hasFocus() ? !1 : Ta(e);
5435
5435
  }
5436
- function Ea(e) {
5436
+ function Ta(e) {
5437
5437
  let t = e.domSelectionRange();
5438
5438
  if (!t.anchorNode) return !1;
5439
5439
  try {
@@ -5442,98 +5442,98 @@ function Ea(e) {
5442
5442
  return !1;
5443
5443
  }
5444
5444
  }
5445
- function Da(e) {
5445
+ function Ea(e) {
5446
5446
  let t = e.docView.domFromPos(e.state.selection.anchor, 0), n = e.domSelectionRange();
5447
5447
  return Ir(t.node, t.offset, n.anchorNode, n.anchorOffset);
5448
5448
  }
5449
- function Oa(e, t) {
5449
+ function Da(e, t) {
5450
5450
  let { $anchor: n, $head: r } = e.selection, i = t > 0 ? n.max(r) : n.min(r), a = i.parent.inlineContent ? i.depth ? e.doc.resolve(t > 0 ? i.after() : i.before()) : null : i;
5451
5451
  return a && D.findFrom(a, t);
5452
5452
  }
5453
- function ka(e, t) {
5453
+ function Oa(e, t) {
5454
5454
  return e.dispatch(e.state.tr.setSelection(t).scrollIntoView()), !0;
5455
5455
  }
5456
- function Aa(e, t, n) {
5456
+ function ka(e, t, n) {
5457
5457
  let r = e.state.selection;
5458
5458
  if (r instanceof O) {
5459
5459
  if (n.indexOf("s") > -1) {
5460
5460
  let { $head: n } = r, i = n.textOffset ? null : t < 0 ? n.nodeBefore : n.nodeAfter;
5461
5461
  if (!i || i.isText || !i.isLeaf) return !1;
5462
5462
  let a = e.state.doc.resolve(n.pos + i.nodeSize * (t < 0 ? -1 : 1));
5463
- return ka(e, new O(r.$anchor, a));
5463
+ return Oa(e, new O(r.$anchor, a));
5464
5464
  }
5465
5465
  if (!r.empty) return !1;
5466
5466
  if (e.endOfTextblock(t > 0 ? "forward" : "backward")) {
5467
- let n = Oa(e.state, t);
5468
- return n && n instanceof k ? ka(e, n) : !1;
5467
+ let n = Da(e.state, t);
5468
+ return n && n instanceof k ? Oa(e, n) : !1;
5469
5469
  }
5470
- if (!B || n.indexOf("m") < 0) {
5470
+ if (!V || n.indexOf("m") < 0) {
5471
5471
  let n = r.$head, i = n.textOffset ? null : t < 0 ? n.nodeBefore : n.nodeAfter, a;
5472
5472
  if (!i || i.isText) return !1;
5473
5473
  let o = t < 0 ? n.pos - i.nodeSize : n.pos;
5474
- return i.isAtom || (a = e.docView.descAt(o)) && !a.contentDOM ? k.isSelectable(i) ? ka(e, new k(t < 0 ? e.state.doc.resolve(n.pos - i.nodeSize) : n)) : ka(e, new O(e.state.doc.resolve(t < 0 ? o : o + i.nodeSize))) : !1;
5474
+ return i.isAtom || (a = e.docView.descAt(o)) && !a.contentDOM ? k.isSelectable(i) ? Oa(e, new k(t < 0 ? e.state.doc.resolve(n.pos - i.nodeSize) : n)) : Oa(e, new O(e.state.doc.resolve(t < 0 ? o : o + i.nodeSize))) : !1;
5475
5475
  }
5476
- } else if (r instanceof k && r.node.isInline) return ka(e, new O(t > 0 ? r.$to : r.$from));
5476
+ } else if (r instanceof k && r.node.isInline) return Oa(e, new O(t > 0 ? r.$to : r.$from));
5477
5477
  else {
5478
- let n = Oa(e.state, t);
5479
- return n ? ka(e, n) : !1;
5478
+ let n = Da(e.state, t);
5479
+ return n ? Oa(e, n) : !1;
5480
5480
  }
5481
5481
  }
5482
- function ja(e, t) {
5482
+ function Aa(e, t) {
5483
5483
  let n = e.pmViewDesc;
5484
5484
  return n ? n.size == 0 && (t < 0 || e.nextSibling || e.nodeName != "BR") : P(e) && e.contentEditable == "false";
5485
5485
  }
5486
- function Ma(e, t) {
5487
- return t < 0 ? Na(e) : Pa(e);
5486
+ function ja(e, t) {
5487
+ return t < 0 ? Ma(e) : Na(e);
5488
5488
  }
5489
- function Na(e) {
5489
+ function Ma(e) {
5490
5490
  let t = e.domSelectionRange(), n = t.focusNode, r = t.focusOffset;
5491
5491
  if (!n) return;
5492
5492
  let i, a, o = !1;
5493
- for (L && P(n) && r < N(n) && ja(n.childNodes[r], -1) && (o = !0);;) if (r > 0) {
5493
+ for (R && P(n) && r < N(n) && Aa(n.childNodes[r], -1) && (o = !0);;) if (r > 0) {
5494
5494
  if (!P(n)) break;
5495
5495
  let e = n.childNodes[r - 1];
5496
- if (ja(e, -1)) i = n, a = --r;
5496
+ if (Aa(e, -1)) i = n, a = --r;
5497
5497
  else if (F(e)) n = e, r = n.nodeValue.length;
5498
5498
  else break;
5499
- } else if (Fa(n)) break;
5499
+ } else if (Pa(n)) break;
5500
5500
  else {
5501
5501
  let t = n.previousSibling;
5502
- for (; t && ja(t, -1);) i = n.parentNode, a = M(t), t = t.previousSibling;
5502
+ for (; t && Aa(t, -1);) i = n.parentNode, a = M(t), t = t.previousSibling;
5503
5503
  if (t) n = t, r = N(n);
5504
5504
  else {
5505
5505
  if (n = n.parentNode, n == e.dom) break;
5506
5506
  r = 0;
5507
5507
  }
5508
5508
  }
5509
- o ? Ra(e, n, r) : i && Ra(e, i, a);
5509
+ o ? La(e, n, r) : i && La(e, i, a);
5510
5510
  }
5511
- function Pa(e) {
5511
+ function Na(e) {
5512
5512
  let t = e.domSelectionRange(), n = t.focusNode, r = t.focusOffset;
5513
5513
  if (!n) return;
5514
5514
  let i = N(n), a, o;
5515
5515
  for (;;) if (r < i) {
5516
5516
  if (!P(n)) break;
5517
5517
  let e = n.childNodes[r];
5518
- if (ja(e, 1)) a = n, o = ++r;
5518
+ if (Aa(e, 1)) a = n, o = ++r;
5519
5519
  else break;
5520
- } else if (Fa(n)) break;
5520
+ } else if (Pa(n)) break;
5521
5521
  else {
5522
5522
  let t = n.nextSibling;
5523
- for (; t && ja(t, 1);) a = t.parentNode, o = M(t) + 1, t = t.nextSibling;
5523
+ for (; t && Aa(t, 1);) a = t.parentNode, o = M(t) + 1, t = t.nextSibling;
5524
5524
  if (t) n = t, r = 0, i = N(n);
5525
5525
  else {
5526
5526
  if (n = n.parentNode, n == e.dom) break;
5527
5527
  r = i = 0;
5528
5528
  }
5529
5529
  }
5530
- a && Ra(e, a, o);
5530
+ a && La(e, a, o);
5531
5531
  }
5532
- function Fa(e) {
5532
+ function Pa(e) {
5533
5533
  let t = e.pmViewDesc;
5534
5534
  return t && t.node && t.node.isBlock;
5535
5535
  }
5536
- function Ia(e, t) {
5536
+ function Fa(e, t) {
5537
5537
  for (; e && t == e.childNodes.length && !Ur(e);) t = M(e) + 1, e = e.parentNode;
5538
5538
  for (; e && t < e.childNodes.length;) {
5539
5539
  let n = e.childNodes[t];
@@ -5542,7 +5542,7 @@ function Ia(e, t) {
5542
5542
  e = n, t = 0;
5543
5543
  }
5544
5544
  }
5545
- function La(e, t) {
5545
+ function Ia(e, t) {
5546
5546
  for (; e && !t && !Ur(e);) t = M(e), e = e.parentNode;
5547
5547
  for (; e && t;) {
5548
5548
  let n = e.childNodes[t - 1];
@@ -5551,22 +5551,22 @@ function La(e, t) {
5551
5551
  e = n, t = e.childNodes.length;
5552
5552
  }
5553
5553
  }
5554
- function Ra(e, t, n) {
5554
+ function La(e, t, n) {
5555
5555
  if (!F(t)) {
5556
5556
  let e, r;
5557
- (r = Ia(t, n)) ? (t = r, n = 0) : (e = La(t, n)) && (t = e, n = e.nodeValue.length);
5557
+ (r = Fa(t, n)) ? (t = r, n = 0) : (e = Ia(t, n)) && (t = e, n = e.nodeValue.length);
5558
5558
  }
5559
5559
  let r = e.domSelection(), i = e.domSelectionRange();
5560
5560
  if (!r) return;
5561
5561
  Wr(i) ? r.collapse(t, n) : r.extend && (r.collapse(i.anchorNode, i.anchorOffset), r.extend(t, n)), e.domObserver.setCurSelection();
5562
5562
  let { state: a } = e;
5563
5563
  setTimeout(() => {
5564
- e.state == a && ha(e);
5564
+ e.state == a && ma(e);
5565
5565
  }, 50);
5566
5566
  }
5567
- function za(e, t) {
5567
+ function Ra(e, t) {
5568
5568
  let n = e.state.doc.resolve(t);
5569
- if (!(R || ii) && n.parent.inlineContent) {
5569
+ if (!(z || ri) && n.parent.inlineContent) {
5570
5570
  let r = e.coordsAtPos(t);
5571
5571
  if (t > n.start()) {
5572
5572
  let n = e.coordsAtPos(t - 1), i = (n.top + n.bottom) / 2;
@@ -5584,21 +5584,21 @@ function za(e, t) {
5584
5584
  }
5585
5585
  return getComputedStyle(r).direction == "rtl" ? "rtl" : "ltr";
5586
5586
  }
5587
- function Ba(e, t, n) {
5587
+ function za(e, t, n) {
5588
5588
  let r = e.state.selection;
5589
- if (r instanceof O && !r.empty || n.indexOf("s") > -1 || B && n.indexOf("m") > -1) return !1;
5589
+ if (r instanceof O && !r.empty || n.indexOf("s") > -1 || V && n.indexOf("m") > -1) return !1;
5590
5590
  let { $from: i, $to: a } = r;
5591
5591
  if (!i.parent.inlineContent || e.endOfTextblock(t < 0 ? "up" : "down")) {
5592
- let n = Oa(e.state, t);
5593
- if (n && n instanceof k) return ka(e, n);
5592
+ let n = Da(e.state, t);
5593
+ if (n && n instanceof k) return Oa(e, n);
5594
5594
  }
5595
5595
  if (!i.parent.inlineContent) {
5596
5596
  let n = t < 0 ? i : a, o = r instanceof Tn ? D.near(n, t) : D.findFrom(n, t);
5597
- return o ? ka(e, o) : !1;
5597
+ return o ? Oa(e, o) : !1;
5598
5598
  }
5599
5599
  return !1;
5600
5600
  }
5601
- function Va(e, t) {
5601
+ function Ba(e, t) {
5602
5602
  if (!(e.state.selection instanceof O)) return !0;
5603
5603
  let { $head: n, $anchor: r, empty: i } = e.state.selection;
5604
5604
  if (!n.sameParent(r)) return !0;
@@ -5611,38 +5611,38 @@ function Va(e, t) {
5611
5611
  }
5612
5612
  return !1;
5613
5613
  }
5614
- function Ha(e, t, n) {
5614
+ function Va(e, t, n) {
5615
5615
  e.domObserver.stop(), t.contentEditable = n, e.domObserver.start();
5616
5616
  }
5617
- function Ua(e) {
5618
- if (!z || e.state.selection.$head.parentOffset > 0) return !1;
5617
+ function Ha(e) {
5618
+ if (!B || e.state.selection.$head.parentOffset > 0) return !1;
5619
5619
  let { focusNode: t, focusOffset: n } = e.domSelectionRange();
5620
5620
  if (t && P(t) && n == 0 && t.firstChild && P(t.firstChild) && t.firstChild.contentEditable == "false") {
5621
5621
  let n = t.firstChild;
5622
- Ha(e, n, "true"), setTimeout(() => Ha(e, n, "false"), 20);
5622
+ Va(e, n, "true"), setTimeout(() => Va(e, n, "false"), 20);
5623
5623
  }
5624
5624
  return !1;
5625
5625
  }
5626
- function Wa(e) {
5626
+ function Ua(e) {
5627
5627
  let t = "";
5628
5628
  return e.ctrlKey && (t += "c"), e.metaKey && (t += "m"), e.altKey && (t += "a"), e.shiftKey && (t += "s"), t;
5629
5629
  }
5630
- function Ga(e, t) {
5631
- let n = t.keyCode, r = Wa(t);
5632
- if (n == 8 || B && n == 72 && r == "c") return Va(e, -1) || Ma(e, -1);
5633
- if (n == 46 && !t.shiftKey || B && n == 68 && r == "c") return Va(e, 1) || Ma(e, 1);
5630
+ function Wa(e, t) {
5631
+ let n = t.keyCode, r = Ua(t);
5632
+ if (n == 8 || V && n == 72 && r == "c") return Ba(e, -1) || ja(e, -1);
5633
+ if (n == 46 && !t.shiftKey || V && n == 68 && r == "c") return Ba(e, 1) || ja(e, 1);
5634
5634
  if (n == 13 || n == 27) return !0;
5635
- if (n == 37 || B && n == 66 && r == "c") {
5636
- let t = n == 37 ? za(e, e.state.selection.from) == "ltr" ? -1 : 1 : -1;
5637
- return Aa(e, t, r) || Ma(e, t);
5635
+ if (n == 37 || V && n == 66 && r == "c") {
5636
+ let t = n == 37 ? Ra(e, e.state.selection.from) == "ltr" ? -1 : 1 : -1;
5637
+ return ka(e, t, r) || ja(e, t);
5638
5638
  }
5639
- if (n == 39 || B && n == 70 && r == "c") {
5640
- let t = n == 39 ? za(e, e.state.selection.from) == "ltr" ? 1 : -1 : 1;
5641
- return Aa(e, t, r) || Ma(e, t);
5639
+ if (n == 39 || V && n == 70 && r == "c") {
5640
+ let t = n == 39 ? Ra(e, e.state.selection.from) == "ltr" ? 1 : -1 : 1;
5641
+ return ka(e, t, r) || ja(e, t);
5642
5642
  }
5643
- return n == 38 || B && n == 80 && r == "c" ? Ba(e, -1, r) || Ma(e, -1) : n == 40 || B && n == 78 && r == "c" ? Ua(e) || Ba(e, 1, r) || Ma(e, 1) : !(r != (B ? "m" : "c") || n != 66 && n != 73 && n != 89 && n != 90);
5643
+ return n == 38 || V && n == 80 && r == "c" ? za(e, -1, r) || ja(e, -1) : n == 40 || V && n == 78 && r == "c" ? Ha(e) || za(e, 1, r) || ja(e, 1) : !(r != (V ? "m" : "c") || n != 66 && n != 73 && n != 89 && n != 90);
5644
5644
  }
5645
- function Ka(e, t) {
5645
+ function Ga(e, t) {
5646
5646
  e.someProp("transformCopied", (n) => {
5647
5647
  t = n(t, e);
5648
5648
  });
@@ -5652,10 +5652,10 @@ function Ka(e, t) {
5652
5652
  let e = r.firstChild;
5653
5653
  n.push(e.type.name, e.attrs == e.type.defaultAttrs ? null : e.attrs), r = e.content;
5654
5654
  }
5655
- let o = e.someProp("clipboardSerializer") || $e.fromSchema(e.state.schema), s = no(), c = s.createElement("div");
5655
+ let o = e.someProp("clipboardSerializer") || $e.fromSchema(e.state.schema), s = to(), c = s.createElement("div");
5656
5656
  c.appendChild(o.serializeFragment(r, { document: s }));
5657
5657
  let l = c.firstChild, u, d = 0;
5658
- for (; l && P(l) && (u = to[l.nodeName.toLowerCase()]);) {
5658
+ for (; l && P(l) && (u = eo[l.nodeName.toLowerCase()]);) {
5659
5659
  for (let e = u.length - 1; e >= 0; e--) {
5660
5660
  let t = s.createElement(u[e]);
5661
5661
  for (; c.firstChild;) t.appendChild(c.firstChild);
@@ -5669,7 +5669,7 @@ function Ka(e, t) {
5669
5669
  slice: t
5670
5670
  };
5671
5671
  }
5672
- function qa(e, t, n, r, i) {
5672
+ function Ka(e, t, n, r, i) {
5673
5673
  let a = i.parent.type.spec.code, o, c;
5674
5674
  if (!n && !t) return null;
5675
5675
  let l = !!t && (r || a || !n);
@@ -5690,7 +5690,7 @@ function qa(e, t, n, r, i) {
5690
5690
  }
5691
5691
  } else e.someProp("transformPastedHTML", (t) => {
5692
5692
  n = t(n, e);
5693
- }), o = ao(n), oi && oo(o);
5693
+ }), o = io(n), ai && ao(o);
5694
5694
  let u = o && o.querySelector("[data-pm-slice]"), d = u && /^(\d+) (\d+)(?: -(\d+))? (.*)/.exec(u.getAttribute("data-pm-slice") || "");
5695
5695
  if (d && d[3]) for (let e = +d[3]; e > 0; e--) {
5696
5696
  let e = o.firstChild;
@@ -5702,21 +5702,21 @@ function qa(e, t, n, r, i) {
5702
5702
  preserveWhitespace: !!(l || d),
5703
5703
  context: i,
5704
5704
  ruleFromNode(e) {
5705
- return e.nodeName == "BR" && !e.nextSibling && e.parentNode && !Ja.test(e.parentNode.nodeName) ? { ignore: !0 } : null;
5705
+ return e.nodeName == "BR" && !e.nextSibling && e.parentNode && !qa.test(e.parentNode.nodeName) ? { ignore: !0 } : null;
5706
5706
  }
5707
- }), d) c = so(eo(c, +d[1], +d[2]), d[4]);
5708
- else if (c = p.maxOpen(Ya(c.content, i), !0), c.openStart || c.openEnd) {
5707
+ }), d) c = oo($a(c, +d[1], +d[2]), d[4]);
5708
+ else if (c = p.maxOpen(Ja(c.content, i), !0), c.openStart || c.openEnd) {
5709
5709
  let e = 0, t = 0;
5710
5710
  for (let t = c.content.firstChild; e < c.openStart && !t.type.spec.isolating; e++, t = t.firstChild);
5711
5711
  for (let e = c.content.lastChild; t < c.openEnd && !e.type.spec.isolating; t++, e = e.lastChild);
5712
- c = eo(c, e, t);
5712
+ c = $a(c, e, t);
5713
5713
  }
5714
5714
  return e.someProp("transformPasted", (t) => {
5715
5715
  c = t(c, e, l);
5716
5716
  }), c;
5717
5717
  }
5718
- var Ja = /^(a|abbr|acronym|b|cite|code|del|em|i|ins|kbd|label|output|q|ruby|s|samp|span|strong|sub|sup|time|u|tt|var)$/i;
5719
- function Ya(e, t) {
5718
+ var qa = /^(a|abbr|acronym|b|cite|code|del|em|i|ins|kbd|label|output|q|ruby|s|samp|span|strong|sub|sup|time|u|tt|var)$/i;
5719
+ function Ja(e, t) {
5720
5720
  if (e.childCount < 2) return e;
5721
5721
  for (let n = t.depth; n >= 0; n--) {
5722
5722
  let r = t.node(n).contentMatchAt(t.index(n)), i, a = [];
@@ -5724,40 +5724,40 @@ function Ya(e, t) {
5724
5724
  if (!a) return;
5725
5725
  let t = r.findWrapping(e.type), n;
5726
5726
  if (!t) return a = null;
5727
- if (n = a.length && i.length && Za(t, i, e, a[a.length - 1], 0)) a[a.length - 1] = n;
5727
+ if (n = a.length && i.length && Xa(t, i, e, a[a.length - 1], 0)) a[a.length - 1] = n;
5728
5728
  else {
5729
- a.length && (a[a.length - 1] = Qa(a[a.length - 1], i.length));
5730
- let n = Xa(e, t);
5729
+ a.length && (a[a.length - 1] = Za(a[a.length - 1], i.length));
5730
+ let n = Ya(e, t);
5731
5731
  a.push(n), r = r.matchType(n.type), i = t;
5732
5732
  }
5733
5733
  }), a) return s.from(a);
5734
5734
  }
5735
5735
  return e;
5736
5736
  }
5737
- function Xa(e, t, n = 0) {
5737
+ function Ya(e, t, n = 0) {
5738
5738
  for (let r = t.length - 1; r >= n; r--) e = t[r].create(null, s.from(e));
5739
5739
  return e;
5740
5740
  }
5741
- function Za(e, t, n, r, i) {
5741
+ function Xa(e, t, n, r, i) {
5742
5742
  if (i < e.length && i < t.length && e[i] == t[i]) {
5743
- let a = Za(e, t, n, r.lastChild, i + 1);
5743
+ let a = Xa(e, t, n, r.lastChild, i + 1);
5744
5744
  if (a) return r.copy(r.content.replaceChild(r.childCount - 1, a));
5745
- if (r.contentMatchAt(r.childCount).matchType(i == e.length - 1 ? n.type : e[i + 1])) return r.copy(r.content.append(s.from(Xa(n, e, i + 1))));
5745
+ if (r.contentMatchAt(r.childCount).matchType(i == e.length - 1 ? n.type : e[i + 1])) return r.copy(r.content.append(s.from(Ya(n, e, i + 1))));
5746
5746
  }
5747
5747
  }
5748
- function Qa(e, t) {
5748
+ function Za(e, t) {
5749
5749
  if (t == 0) return e;
5750
- let n = e.content.replaceChild(e.childCount - 1, Qa(e.lastChild, t - 1)), r = e.contentMatchAt(e.childCount).fillBefore(s.empty, !0);
5750
+ let n = e.content.replaceChild(e.childCount - 1, Za(e.lastChild, t - 1)), r = e.contentMatchAt(e.childCount).fillBefore(s.empty, !0);
5751
5751
  return e.copy(n.append(r));
5752
5752
  }
5753
- function $a(e, t, n, r, i, a) {
5753
+ function Qa(e, t, n, r, i, a) {
5754
5754
  let o = t < 0 ? e.firstChild : e.lastChild, c = o.content;
5755
- return e.childCount > 1 && (a = 0), i < r - 1 && (c = $a(c, t, n, r, i + 1, a)), i >= n && (c = t < 0 ? o.contentMatchAt(0).fillBefore(c, a <= i).append(c) : c.append(o.contentMatchAt(o.childCount).fillBefore(s.empty, !0))), e.replaceChild(t < 0 ? 0 : e.childCount - 1, o.copy(c));
5755
+ return e.childCount > 1 && (a = 0), i < r - 1 && (c = Qa(c, t, n, r, i + 1, a)), i >= n && (c = t < 0 ? o.contentMatchAt(0).fillBefore(c, a <= i).append(c) : c.append(o.contentMatchAt(o.childCount).fillBefore(s.empty, !0))), e.replaceChild(t < 0 ? 0 : e.childCount - 1, o.copy(c));
5756
5756
  }
5757
- function eo(e, t, n) {
5758
- return t < e.openStart && (e = new p($a(e.content, -1, t, e.openStart, 0, e.openEnd), t, e.openEnd)), n < e.openEnd && (e = new p($a(e.content, 1, n, e.openEnd, 0, 0), e.openStart, n)), e;
5757
+ function $a(e, t, n) {
5758
+ return t < e.openStart && (e = new p(Qa(e.content, -1, t, e.openStart, 0, e.openEnd), t, e.openEnd)), n < e.openEnd && (e = new p(Qa(e.content, 1, n, e.openEnd, 0, 0), e.openStart, n)), e;
5759
5759
  }
5760
- var to = {
5760
+ var eo = {
5761
5761
  thead: ["table"],
5762
5762
  tbody: ["table"],
5763
5763
  tfoot: ["table"],
@@ -5776,26 +5776,26 @@ var to = {
5776
5776
  "tr"
5777
5777
  ]
5778
5778
  };
5779
- function no() {
5779
+ function to() {
5780
5780
  return document.implementation.createHTMLDocument("title");
5781
5781
  }
5782
- var ro = null;
5783
- function io(e) {
5782
+ var no = null;
5783
+ function ro(e) {
5784
5784
  let t = window.trustedTypes;
5785
5785
  if (!t) return e;
5786
- if (!ro) {
5787
- if (ro = t.defaultPolicy) try {
5788
- return ro.createHTML(e);
5786
+ if (!no) {
5787
+ if (no = t.defaultPolicy) try {
5788
+ return no.createHTML(e);
5789
5789
  } catch {}
5790
- ro = t.createPolicy("ProseMirrorClipboard", { createHTML: (e) => e });
5790
+ no = t.createPolicy("ProseMirrorClipboard", { createHTML: (e) => e });
5791
5791
  }
5792
- return ro.createHTML(e);
5792
+ return no.createHTML(e);
5793
5793
  }
5794
- function ao(e) {
5794
+ function io(e) {
5795
5795
  let t = /^(\s*<meta [^>]*>)*/.exec(e);
5796
5796
  t && (e = e.slice(t[0].length));
5797
- let n = no(), r = n.body, i = /<([a-z][^>\s]+)/i.exec(e), a;
5798
- if ((a = i && to[i[1].toLowerCase()]) && (e = a.map((e) => "<" + e + ">").join("") + e + a.map((e) => "</" + e + ">").reverse().join("")), r.innerHTML = io(e), a) for (let e = 0; e < a.length; e++) r = r.querySelector(a[e]) || r;
5797
+ let n = to(), r = n.body, i = /<([a-z][^>\s]+)/i.exec(e), a;
5798
+ if ((a = i && eo[i[1].toLowerCase()]) && (e = a.map((e) => "<" + e + ">").join("") + e + a.map((e) => "</" + e + ">").reverse().join("")), r.innerHTML = ro(e), a) for (let e = 0; e < a.length; e++) r = r.querySelector(a[e]) || r;
5799
5799
  for (let e = 0; e < n.styleSheets.length; e++) {
5800
5800
  let t = n.styleSheets[e];
5801
5801
  for (let e = 0; e < t.rules.length; e++) {
@@ -5808,14 +5808,14 @@ function ao(e) {
5808
5808
  }
5809
5809
  return r;
5810
5810
  }
5811
- function oo(e) {
5812
- let t = e.querySelectorAll(R ? "span:not([class]):not([style])" : "span.Apple-converted-space");
5811
+ function ao(e) {
5812
+ let t = e.querySelectorAll(z ? "span:not([class]):not([style])" : "span.Apple-converted-space");
5813
5813
  for (let n = 0; n < t.length; n++) {
5814
5814
  let r = t[n];
5815
5815
  r.childNodes.length == 1 && r.textContent == "\xA0" && r.parentNode && r.parentNode.replaceChild(e.ownerDocument.createTextNode(" "), r);
5816
5816
  }
5817
5817
  }
5818
- function so(e, t) {
5818
+ function oo(e, t) {
5819
5819
  if (!e.size) return e;
5820
5820
  let n = e.content.firstChild.type.schema, r;
5821
5821
  try {
@@ -5836,10 +5836,10 @@ function so(e, t) {
5836
5836
  }
5837
5837
  return new p(i, a, o);
5838
5838
  }
5839
- var U = {}, W = {}, co = {
5839
+ var W = {}, G = {}, so = {
5840
5840
  touchstart: !0,
5841
5841
  touchmove: !0
5842
- }, lo = class {
5842
+ }, co = class {
5843
5843
  constructor() {
5844
5844
  this.shiftKey = !1, this.mouseDown = null, this.lastKeyCode = null, this.lastKeyCodeTime = 0, this.lastKeyDispatched = !1, this.lastClick = {
5845
5845
  time: 0,
@@ -5850,62 +5850,62 @@ var U = {}, W = {}, co = {
5850
5850
  }, this.lastSelectionOrigin = null, this.lastSelectionTime = 0, this.lastIOSEnter = 0, this.lastIOSEnterFallbackTimeout = -1, this.lastFocus = 0, this.lastTouch = 0, this.lastChromeDelete = 0, this.composing = !1, this.compositionNode = null, this.composingTimeout = -1, this.compositionNodes = [], this.compositionEndedAt = -2e8, this.compositionID = 1, this.badSafariComposition = !1, this.compositionPendingChanges = 0, this.domChangeCount = 0, this.eventHandlers = Object.create(null), this.hideSelectionGuard = null;
5851
5851
  }
5852
5852
  };
5853
- function uo(e) {
5854
- for (let t in U) {
5855
- let n = U[t];
5853
+ function lo(e) {
5854
+ for (let t in W) {
5855
+ let n = W[t];
5856
5856
  e.dom.addEventListener(t, e.input.eventHandlers[t] = (t) => {
5857
- go(e, t) && !ho(e, t) && (e.editable || !(t.type in W)) && n(e, t);
5858
- }, co[t] ? { passive: !0 } : void 0);
5857
+ ho(e, t) && !mo(e, t) && (e.editable || !(t.type in G)) && n(e, t);
5858
+ }, so[t] ? { passive: !0 } : void 0);
5859
5859
  }
5860
- z && e.dom.addEventListener("input", () => null), mo(e);
5860
+ B && e.dom.addEventListener("input", () => null), po(e);
5861
5861
  }
5862
- function fo(e, t) {
5862
+ function uo(e, t) {
5863
5863
  e.input.lastSelectionOrigin = t, e.input.lastSelectionTime = Date.now();
5864
5864
  }
5865
- function po(e) {
5865
+ function fo(e) {
5866
5866
  e.input.mouseDown && e.input.mouseDown.done(), e.domObserver.stop();
5867
5867
  for (let t in e.input.eventHandlers) e.dom.removeEventListener(t, e.input.eventHandlers[t]);
5868
5868
  clearTimeout(e.input.composingTimeout), clearTimeout(e.input.lastIOSEnterFallbackTimeout);
5869
5869
  }
5870
- function mo(e) {
5870
+ function po(e) {
5871
5871
  e.someProp("handleDOMEvents", (t) => {
5872
- for (let n in t) e.input.eventHandlers[n] || e.dom.addEventListener(n, e.input.eventHandlers[n] = (t) => ho(e, t));
5872
+ for (let n in t) e.input.eventHandlers[n] || e.dom.addEventListener(n, e.input.eventHandlers[n] = (t) => mo(e, t));
5873
5873
  });
5874
5874
  }
5875
- function ho(e, t) {
5875
+ function mo(e, t) {
5876
5876
  return e.someProp("handleDOMEvents", (n) => {
5877
5877
  let r = n[t.type];
5878
5878
  return r ? r(e, t) || t.defaultPrevented : !1;
5879
5879
  });
5880
5880
  }
5881
- function go(e, t) {
5881
+ function ho(e, t) {
5882
5882
  if (!t.bubbles) return !0;
5883
5883
  if (t.defaultPrevented) return !1;
5884
5884
  for (let n = t.target; n != e.dom; n = n.parentNode) if (!n || n.nodeType == 11 || n.pmViewDesc && n.pmViewDesc.stopEvent(t)) return !1;
5885
5885
  return !0;
5886
5886
  }
5887
- function _o(e, t) {
5888
- !ho(e, t) && U[t.type] && (e.editable || !(t.type in W)) && U[t.type](e, t);
5887
+ function go(e, t) {
5888
+ !mo(e, t) && W[t.type] && (e.editable || !(t.type in G)) && W[t.type](e, t);
5889
5889
  }
5890
- function vo(e, t) {
5890
+ function _o(e, t) {
5891
5891
  let { input: n } = e;
5892
5892
  return n.lastKeyDispatched || e.composing ? !1 : (n.lastKeyDispatched = !0, typeof t == "string" && (t = Gr(t == "Backspace" ? 8 : 13, t)), e.someProp("handleKeyDown", (n) => n(e, t)));
5893
5893
  }
5894
- W.keydown = (e, t) => {
5894
+ G.keydown = (e, t) => {
5895
5895
  let n = t;
5896
- if (e.input.shiftKey = n.keyCode == 16 || n.shiftKey, !Fo(e) && (e.input.lastKeyCode = n.keyCode, e.input.lastKeyCodeTime = Date.now(), e.input.lastKeyDispatched = !1, !(ai && R && n.keyCode == 13))) {
5897
- if (n.keyCode != 229 && e.domObserver.forceFlush(), ri && n.keyCode == 13 && !n.ctrlKey && !n.altKey && !n.metaKey) {
5896
+ if (e.input.shiftKey = n.keyCode == 16 || n.shiftKey, !Po(e) && (e.input.lastKeyCode = n.keyCode, e.input.lastKeyCodeTime = Date.now(), e.input.lastKeyDispatched = !1, !(ii && z && n.keyCode == 13))) {
5897
+ if (n.keyCode != 229 && e.domObserver.forceFlush(), ni && n.keyCode == 13 && !n.ctrlKey && !n.altKey && !n.metaKey) {
5898
5898
  let t = Date.now();
5899
5899
  e.input.lastIOSEnter = t, e.input.lastIOSEnterFallbackTimeout = setTimeout(() => {
5900
- e.input.lastIOSEnter == t && (vo(e, "Enter"), e.input.lastIOSEnter = 0);
5900
+ e.input.lastIOSEnter == t && (_o(e, "Enter"), e.input.lastIOSEnter = 0);
5901
5901
  }, 200);
5902
- } else vo(e, n) || Ga(e, n) ? n.preventDefault() : fo(e, "key");
5902
+ } else _o(e, n) || Wa(e, n) ? n.preventDefault() : uo(e, "key");
5903
5903
  }
5904
- }, W.keyup = (e, t) => {
5904
+ }, G.keyup = (e, t) => {
5905
5905
  t.keyCode == 16 && (e.input.shiftKey = !1);
5906
- }, W.keypress = (e, t) => {
5906
+ }, G.keypress = (e, t) => {
5907
5907
  let n = t;
5908
- if (Fo(e) || !n.charCode || n.ctrlKey && !n.altKey || B && n.metaKey) return;
5908
+ if (Po(e) || !n.charCode || n.ctrlKey && !n.altKey || V && n.metaKey) return;
5909
5909
  if (e.someProp("handleKeyPress", (t) => t(e, n))) {
5910
5910
  n.preventDefault();
5911
5911
  return;
@@ -5916,33 +5916,33 @@ W.keydown = (e, t) => {
5916
5916
  !/[\r\n]/.test(t) && !e.someProp("handleTextInput", (n) => n(e, r.$from.pos, r.$to.pos, t, i)) && e.dispatch(i()), n.preventDefault();
5917
5917
  }
5918
5918
  };
5919
- function yo(e) {
5919
+ function vo(e) {
5920
5920
  return {
5921
5921
  left: e.clientX,
5922
5922
  top: e.clientY
5923
5923
  };
5924
5924
  }
5925
- function bo(e, t) {
5925
+ function yo(e, t) {
5926
5926
  let n = t.x - e.clientX, r = t.y - e.clientY;
5927
5927
  return n * n + r * r < 100;
5928
5928
  }
5929
- function xo(e, t, n, r, i) {
5929
+ function bo(e, t, n, r, i) {
5930
5930
  if (r == -1) return !1;
5931
5931
  let a = e.state.doc.resolve(r);
5932
5932
  for (let r = a.depth + 1; r > 0; r--) if (e.someProp(t, (t) => r > a.depth ? t(e, n, a.nodeAfter, a.before(r), i, !0) : t(e, n, a.node(r), a.before(r), i, !1))) return !0;
5933
5933
  return !1;
5934
5934
  }
5935
- function So(e, t, n) {
5935
+ function xo(e, t, n) {
5936
5936
  if (e.focused || e.focus(), e.state.selection.eq(t)) return;
5937
5937
  let r = e.state.tr.setSelection(t);
5938
5938
  r.setMeta("pointer", !0), e.dispatch(r);
5939
5939
  }
5940
- function Co(e, t) {
5940
+ function So(e, t) {
5941
5941
  if (t == -1) return !1;
5942
5942
  let n = e.state.doc.resolve(t), r = n.nodeAfter;
5943
- return r && r.isAtom && k.isSelectable(r) ? (So(e, new k(n)), !0) : !1;
5943
+ return r && r.isAtom && k.isSelectable(r) ? (xo(e, new k(n)), !0) : !1;
5944
5944
  }
5945
- function wo(e, t) {
5945
+ function Co(e, t) {
5946
5946
  if (t == -1) return !1;
5947
5947
  let n = e.state.selection, r, i;
5948
5948
  n instanceof k && (r = n.node);
@@ -5954,23 +5954,23 @@ function wo(e, t) {
5954
5954
  break;
5955
5955
  }
5956
5956
  }
5957
- return i != null && (So(e, k.create(e.state.doc, i)), !0);
5957
+ return i != null && (xo(e, k.create(e.state.doc, i)), !0);
5958
5958
  }
5959
- function To(e, t, n, r, i) {
5960
- return xo(e, "handleClickOn", t, n, r) || e.someProp("handleClick", (n) => n(e, t, r)) || (i ? wo(e, n) : Co(e, n));
5959
+ function wo(e, t, n, r, i) {
5960
+ return bo(e, "handleClickOn", t, n, r) || e.someProp("handleClick", (n) => n(e, t, r)) || (i ? Co(e, n) : So(e, n));
5961
5961
  }
5962
- function Eo(e, t, n, r) {
5963
- return xo(e, "handleDoubleClickOn", t, n, r) || e.someProp("handleDoubleClick", (n) => n(e, t, r));
5962
+ function To(e, t, n, r) {
5963
+ return bo(e, "handleDoubleClickOn", t, n, r) || e.someProp("handleDoubleClick", (n) => n(e, t, r));
5964
5964
  }
5965
- function Do(e, t, n, r) {
5966
- return xo(e, "handleTripleClickOn", t, n, r) || e.someProp("handleTripleClick", (n) => n(e, t, r)) || Oo(e, n, r);
5965
+ function Eo(e, t, n, r) {
5966
+ return bo(e, "handleTripleClickOn", t, n, r) || e.someProp("handleTripleClick", (n) => n(e, t, r)) || Do(e, n, r);
5967
5967
  }
5968
- function Oo(e, t, n) {
5968
+ function Do(e, t, n) {
5969
5969
  if (n.button != 0) return !1;
5970
- let r = ko(e, t, !0), i = e.state.doc;
5971
- return r ? (So(e, r), r instanceof O && i.eq(e.state.doc) && (e.input.mouseDown = new Po(e, r)), !0) : !1;
5970
+ let r = Oo(e, t, !0), i = e.state.doc;
5971
+ return r ? (xo(e, r), r instanceof O && i.eq(e.state.doc) && (e.input.mouseDown = new No(e, r)), !0) : !1;
5972
5972
  }
5973
- function ko(e, t, n) {
5973
+ function Oo(e, t, n) {
5974
5974
  let r = e.state.doc;
5975
5975
  if (t == -1) return r.inlineContent ? O.create(r, 0, r.content.size) : null;
5976
5976
  let i = r.resolve(t);
@@ -5981,25 +5981,25 @@ function ko(e, t, n) {
5981
5981
  }
5982
5982
  return null;
5983
5983
  }
5984
- function Ao(e) {
5985
- return Vo(e);
5984
+ function ko(e) {
5985
+ return Bo(e);
5986
5986
  }
5987
- var jo = B ? "metaKey" : "ctrlKey";
5988
- U.mousedown = (e, t) => {
5987
+ var Ao = V ? "metaKey" : "ctrlKey";
5988
+ W.mousedown = (e, t) => {
5989
5989
  let n = t;
5990
5990
  e.input.shiftKey = n.shiftKey;
5991
- let r = Ao(e), i = Date.now(), a = "singleClick";
5992
- i - e.input.lastClick.time < 500 && bo(n, e.input.lastClick) && !n[jo] && e.input.lastClick.button == n.button && (e.input.lastClick.type == "singleClick" ? a = "doubleClick" : e.input.lastClick.type == "doubleClick" && (a = "tripleClick")), e.input.lastClick = {
5991
+ let r = ko(e), i = Date.now(), a = "singleClick";
5992
+ i - e.input.lastClick.time < 500 && yo(n, e.input.lastClick) && !n[Ao] && e.input.lastClick.button == n.button && (e.input.lastClick.type == "singleClick" ? a = "doubleClick" : e.input.lastClick.type == "doubleClick" && (a = "tripleClick")), e.input.lastClick = {
5993
5993
  time: i,
5994
5994
  x: n.clientX,
5995
5995
  y: n.clientY,
5996
5996
  type: a,
5997
5997
  button: n.button
5998
5998
  }, e.input.mouseDown && e.input.mouseDown.done();
5999
- let o = e.posAtCoords(yo(n));
6000
- o && (a == "singleClick" ? e.input.mouseDown = new No(e, o, n, !!r) : (a == "doubleClick" ? Eo : Do)(e, o.pos, o.inside, n) ? n.preventDefault() : fo(e, "pointer"));
5999
+ let o = e.posAtCoords(vo(n));
6000
+ o && (a == "singleClick" ? e.input.mouseDown = new Mo(e, o, n, !!r) : (a == "doubleClick" ? To : Eo)(e, o.pos, o.inside, n) ? n.preventDefault() : uo(e, "pointer"));
6001
6001
  };
6002
- var Mo = class {
6002
+ var jo = class {
6003
6003
  constructor(e) {
6004
6004
  this.view = e, this.mightDrag = null, e.root.addEventListener("mouseup", this.up = this.up.bind(this)), e.root.addEventListener("mousemove", this.move = this.move.bind(this));
6005
6005
  }
@@ -6015,9 +6015,9 @@ var Mo = class {
6015
6015
  delaySelUpdate() {
6016
6016
  return !1;
6017
6017
  }
6018
- }, No = class extends Mo {
6018
+ }, Mo = class extends jo {
6019
6019
  constructor(e, t, n, r) {
6020
- super(e), this.pos = t, this.event = n, this.flushed = r, this.delayedSelectionSync = !1, this.startDoc = e.state.doc, this.selectNode = !!n[jo], this.allowDefault = n.shiftKey;
6020
+ super(e), this.pos = t, this.event = n, this.flushed = r, this.delayedSelectionSync = !1, this.startDoc = e.state.doc, this.selectNode = !!n[Ao], this.allowDefault = n.shiftKey;
6021
6021
  let i, a;
6022
6022
  if (t.inside > -1) i = e.state.doc.nodeAt(t.inside), a = t.inside;
6023
6023
  else {
@@ -6031,23 +6031,23 @@ var Mo = class {
6031
6031
  node: i,
6032
6032
  pos: a,
6033
6033
  addAttr: !(!this.target || this.target.draggable),
6034
- setUneditable: !!(this.target && L && !this.target.hasAttribute("contentEditable"))
6034
+ setUneditable: !!(this.target && R && !this.target.hasAttribute("contentEditable"))
6035
6035
  }), this.target && this.mightDrag && (this.mightDrag.addAttr || this.mightDrag.setUneditable) && (this.view.domObserver.stop(), this.mightDrag.addAttr && (this.target.draggable = !0), this.mightDrag.setUneditable && setTimeout(() => {
6036
6036
  this.view.input.mouseDown == this && this.target.setAttribute("contentEditable", "false");
6037
- }, 20), this.view.domObserver.start()), fo(e, "pointer");
6037
+ }, 20), this.view.domObserver.start()), uo(e, "pointer");
6038
6038
  }
6039
6039
  done() {
6040
6040
  super.done(), this.mightDrag && this.target && (this.view.domObserver.stop(), this.mightDrag.addAttr && this.target.removeAttribute("draggable"), this.mightDrag.setUneditable && this.target.removeAttribute("contentEditable"), this.view.domObserver.start()), this.delayedSelectionSync && setTimeout(() => {
6041
- this.view.isDestroyed || ha(this.view);
6041
+ this.view.isDestroyed || ma(this.view);
6042
6042
  });
6043
6043
  }
6044
6044
  up(e) {
6045
6045
  if (this.done(), !this.view.dom.contains(e.target)) return;
6046
6046
  let t = this.pos;
6047
- this.view.state.doc != this.startDoc && (t = this.view.posAtCoords(yo(e))), this.updateAllowDefault(e), this.allowDefault || !t ? fo(this.view, "pointer") : To(this.view, t.pos, t.inside, e, this.selectNode) ? e.preventDefault() : e.button == 0 && (this.flushed || z && this.mightDrag && !this.mightDrag.node.isAtom || R && !this.view.state.selection.visible && Math.min(Math.abs(t.pos - this.view.state.selection.from), Math.abs(t.pos - this.view.state.selection.to)) <= 2) ? (So(this.view, D.near(this.view.state.doc.resolve(t.pos))), e.preventDefault()) : fo(this.view, "pointer");
6047
+ this.view.state.doc != this.startDoc && (t = this.view.posAtCoords(vo(e))), this.updateAllowDefault(e), this.allowDefault || !t ? uo(this.view, "pointer") : wo(this.view, t.pos, t.inside, e, this.selectNode) ? e.preventDefault() : e.button == 0 && (this.flushed || B && this.mightDrag && !this.mightDrag.node.isAtom || z && !this.view.state.selection.visible && Math.min(Math.abs(t.pos - this.view.state.selection.from), Math.abs(t.pos - this.view.state.selection.to)) <= 2) ? (xo(this.view, D.near(this.view.state.doc.resolve(t.pos))), e.preventDefault()) : uo(this.view, "pointer");
6048
6048
  }
6049
6049
  move(e) {
6050
- this.updateAllowDefault(e), fo(this.view, "pointer"), super.move(e);
6050
+ this.updateAllowDefault(e), uo(this.view, "pointer"), super.move(e);
6051
6051
  }
6052
6052
  updateAllowDefault(e) {
6053
6053
  !this.allowDefault && (Math.abs(this.event.x - e.clientX) > 4 || Math.abs(this.event.y - e.clientY) > 4) && (this.allowDefault = !0);
@@ -6055,7 +6055,7 @@ var Mo = class {
6055
6055
  delaySelUpdate() {
6056
6056
  return this.allowDefault ? (this.delayedSelectionSync = !0, !0) : !1;
6057
6057
  }
6058
- }, Po = class extends Mo {
6058
+ }, No = class extends jo {
6059
6059
  constructor(e, t) {
6060
6060
  super(e), this.startSelection = t, this.startDoc = e.state.doc;
6061
6061
  }
@@ -6064,28 +6064,28 @@ var Mo = class {
6064
6064
  this.done();
6065
6065
  return;
6066
6066
  }
6067
- e.preventDefault(), fo(this.view, "pointer");
6068
- let t = this.view.posAtCoords(yo(e)), n = t && ko(this.view, t.inside, !1);
6067
+ e.preventDefault(), uo(this.view, "pointer");
6068
+ let t = this.view.posAtCoords(vo(e)), n = t && Oo(this.view, t.inside, !1);
6069
6069
  if (!n) return;
6070
6070
  let { doc: r } = this.view.state, i = this.startSelection, [a, o] = n.from < i.from ? [i.to, n.from] : [i.from, n.to];
6071
- So(this.view, O.create(r, a, o));
6071
+ xo(this.view, O.create(r, a, o));
6072
6072
  }
6073
6073
  };
6074
- U.touchstart = (e) => {
6075
- e.input.lastTouch = Date.now(), Ao(e), fo(e, "pointer");
6076
- }, U.touchmove = (e) => {
6077
- e.input.lastTouch = Date.now(), fo(e, "pointer");
6078
- }, U.contextmenu = (e) => Ao(e);
6079
- function Fo(e, t) {
6080
- return e.composing ? !0 : z && Math.abs(Date.now() - e.input.compositionEndedAt) < 500 ? (e.input.compositionEndedAt = -2e8, !0) : !1;
6081
- }
6082
- var Io = ai ? 5e3 : -1;
6083
- W.compositionstart = W.compositionupdate = (e) => {
6074
+ W.touchstart = (e) => {
6075
+ e.input.lastTouch = Date.now(), ko(e), uo(e, "pointer");
6076
+ }, W.touchmove = (e) => {
6077
+ e.input.lastTouch = Date.now(), uo(e, "pointer");
6078
+ }, W.contextmenu = (e) => ko(e);
6079
+ function Po(e, t) {
6080
+ return e.composing ? !0 : B && Math.abs(Date.now() - e.input.compositionEndedAt) < 500 ? (e.input.compositionEndedAt = -2e8, !0) : !1;
6081
+ }
6082
+ var Fo = ii ? 5e3 : -1;
6083
+ G.compositionstart = G.compositionupdate = (e) => {
6084
6084
  if (!e.composing) {
6085
6085
  e.domObserver.flush();
6086
6086
  let { state: t } = e, n = t.selection.$to;
6087
- if (t.selection instanceof O && t.selection.empty && (t.storedMarks || !n.textOffset && n.parentOffset && n.nodeBefore.marks.some((e) => e.type.spec.inclusive === !1) || R && ii && Lo(e))) e.markCursor = e.state.storedMarks || n.marks(), Vo(e, !0), e.markCursor = null;
6088
- else if (Vo(e, !t.selection.empty), L && t.selection.empty && n.parentOffset && !n.textOffset && n.nodeBefore.marks.length) {
6087
+ if (t.selection instanceof O && t.selection.empty && (t.storedMarks || !n.textOffset && n.parentOffset && n.nodeBefore.marks.some((e) => e.type.spec.inclusive === !1) || z && ri && Io(e))) e.markCursor = e.state.storedMarks || n.marks(), Bo(e, !0), e.markCursor = null;
6088
+ else if (Bo(e, !t.selection.empty), R && t.selection.empty && n.parentOffset && !n.textOffset && n.nodeBefore.marks.length) {
6089
6089
  let t = e.domSelectionRange();
6090
6090
  for (let n = t.focusNode, r = t.focusOffset; n && P(n) && r != 0;) {
6091
6091
  let t = r < 0 ? n.lastChild : n.childNodes[r - 1];
@@ -6100,24 +6100,24 @@ W.compositionstart = W.compositionupdate = (e) => {
6100
6100
  }
6101
6101
  e.input.composing = !0;
6102
6102
  }
6103
- Ro(e, Io);
6103
+ Lo(e, Fo);
6104
6104
  };
6105
- function Lo(e) {
6105
+ function Io(e) {
6106
6106
  let { focusNode: t, focusOffset: n } = e.domSelectionRange();
6107
6107
  if (!t || !P(t) || n >= t.childNodes.length) return !1;
6108
6108
  let r = t.childNodes[n];
6109
6109
  return P(r) && r.contentEditable == "false";
6110
6110
  }
6111
- W.compositionend = (e, t) => {
6112
- e.composing && (e.input.composing = !1, e.input.compositionEndedAt = Date.now(), e.input.compositionPendingChanges = e.domObserver.pendingRecords().length ? e.input.compositionID : 0, e.input.compositionNode = null, e.input.badSafariComposition ? e.domObserver.forceFlush() : e.input.compositionPendingChanges && Promise.resolve().then(() => e.domObserver.flush()), e.input.compositionID++, Ro(e, 20));
6111
+ G.compositionend = (e, t) => {
6112
+ e.composing && (e.input.composing = !1, e.input.compositionEndedAt = Date.now(), e.input.compositionPendingChanges = e.domObserver.pendingRecords().length ? e.input.compositionID : 0, e.input.compositionNode = null, e.input.badSafariComposition ? e.domObserver.forceFlush() : e.input.compositionPendingChanges && Promise.resolve().then(() => e.domObserver.flush()), e.input.compositionID++, Lo(e, 20));
6113
6113
  };
6114
- function Ro(e, t) {
6115
- clearTimeout(e.input.composingTimeout), t > -1 && (e.input.composingTimeout = setTimeout(() => Vo(e), t));
6114
+ function Lo(e, t) {
6115
+ clearTimeout(e.input.composingTimeout), t > -1 && (e.input.composingTimeout = setTimeout(() => Bo(e), t));
6116
6116
  }
6117
- function zo(e) {
6117
+ function Ro(e) {
6118
6118
  for (e.composing && (e.input.composing = !1, e.input.compositionEndedAt = Date.now()); e.input.compositionNodes.length > 0;) e.input.compositionNodes.pop().markParentsDirty();
6119
6119
  }
6120
- function Bo(e) {
6120
+ function zo(e) {
6121
6121
  let t = e.domSelectionRange();
6122
6122
  if (!t.focusNode) return null;
6123
6123
  let n = Br(t.focusNode, t.focusOffset), r = Vr(t.focusNode, t.focusOffset);
@@ -6132,16 +6132,16 @@ function Bo(e) {
6132
6132
  }
6133
6133
  return n || r;
6134
6134
  }
6135
- function Vo(e, t = !1) {
6136
- if (!(ai && e.domObserver.flushingSoon >= 0)) {
6137
- if (e.domObserver.forceFlush(), zo(e), t || e.docView && e.docView.dirty) {
6138
- let n = pa(e), r = e.state.selection;
6135
+ function Bo(e, t = !1) {
6136
+ if (!(ii && e.domObserver.flushingSoon >= 0)) {
6137
+ if (e.domObserver.forceFlush(), Ro(e), t || e.docView && e.docView.dirty) {
6138
+ let n = fa(e), r = e.state.selection;
6139
6139
  return n && !n.eq(r) ? e.dispatch(e.state.tr.setSelection(n)) : (e.markCursor || t) && !r.$from.node(r.$from.sharedDepth(r.to)).inlineContent ? e.dispatch(e.state.tr.deleteSelection()) : e.updateState(e.state), !0;
6140
6140
  }
6141
6141
  return !1;
6142
6142
  }
6143
6143
  }
6144
- function Ho(e, t) {
6144
+ function Vo(e, t) {
6145
6145
  if (!e.dom.parentNode) return;
6146
6146
  let n = e.dom.parentNode.appendChild(document.createElement("div"));
6147
6147
  n.appendChild(t), n.style.cssText = "position: fixed; left: -10000px; top: 10px";
@@ -6150,59 +6150,59 @@ function Ho(e, t) {
6150
6150
  n.parentNode && n.parentNode.removeChild(n), e.focus();
6151
6151
  }, 50);
6152
6152
  }
6153
- var Uo = I && ei < 15 || ri && si < 604;
6154
- U.copy = W.cut = (e, t) => {
6153
+ var Ho = L && $r < 15 || ni && oi < 604;
6154
+ W.copy = G.cut = (e, t) => {
6155
6155
  let n = t, r = e.state.selection, i = n.type == "cut";
6156
6156
  if (r.empty) return;
6157
- let a = Uo ? null : n.clipboardData, { dom: o, text: s } = Ka(e, r.content());
6158
- a ? (n.preventDefault(), a.clearData(), a.setData("text/html", o.innerHTML), a.setData("text/plain", s)) : Ho(e, o), i && e.dispatch(e.state.tr.deleteSelection().scrollIntoView().setMeta("uiEvent", "cut"));
6157
+ let a = Ho ? null : n.clipboardData, { dom: o, text: s } = Ga(e, r.content());
6158
+ a ? (n.preventDefault(), a.clearData(), a.setData("text/html", o.innerHTML), a.setData("text/plain", s)) : Vo(e, o), i && e.dispatch(e.state.tr.deleteSelection().scrollIntoView().setMeta("uiEvent", "cut"));
6159
6159
  };
6160
- function Wo(e) {
6160
+ function Uo(e) {
6161
6161
  return e.openStart == 0 && e.openEnd == 0 && e.content.childCount == 1 ? e.content.firstChild : null;
6162
6162
  }
6163
- function Go(e, t) {
6163
+ function Wo(e, t) {
6164
6164
  if (!e.dom.parentNode) return;
6165
6165
  let n = e.input.shiftKey || e.state.selection.$from.parent.type.spec.code, r = e.dom.parentNode.appendChild(document.createElement(n ? "textarea" : "div"));
6166
6166
  n || (r.contentEditable = "true"), r.style.cssText = "position: fixed; left: -10000px; top: 10px", r.focus();
6167
6167
  let i = e.input.shiftKey && e.input.lastKeyCode != 45;
6168
6168
  setTimeout(() => {
6169
- e.focus(), r.parentNode && r.parentNode.removeChild(r), n ? Ko(e, r.value, null, i, t) : Ko(e, r.textContent, r.innerHTML, i, t);
6169
+ e.focus(), r.parentNode && r.parentNode.removeChild(r), n ? Go(e, r.value, null, i, t) : Go(e, r.textContent, r.innerHTML, i, t);
6170
6170
  }, 50);
6171
6171
  }
6172
- function Ko(e, t, n, r, i) {
6173
- let a = qa(e, t, n, r, e.state.selection.$from);
6172
+ function Go(e, t, n, r, i) {
6173
+ let a = Ka(e, t, n, r, e.state.selection.$from);
6174
6174
  if (e.someProp("handlePaste", (t) => t(e, i, a || p.empty))) return !0;
6175
6175
  if (!a) return !1;
6176
- let o = Wo(a), s = o ? e.state.tr.replaceSelectionWith(o, r) : e.state.tr.replaceSelection(a);
6176
+ let o = Uo(a), s = o ? e.state.tr.replaceSelectionWith(o, r) : e.state.tr.replaceSelection(a);
6177
6177
  return e.dispatch(s.scrollIntoView().setMeta("paste", !0).setMeta("uiEvent", "paste")), !0;
6178
6178
  }
6179
- function qo(e) {
6179
+ function Ko(e) {
6180
6180
  let t = e.getData("text/plain") || e.getData("Text");
6181
6181
  if (t) return t;
6182
6182
  let n = e.getData("text/uri-list");
6183
6183
  return n ? n.replace(/\r?\n/g, " ") : "";
6184
6184
  }
6185
- W.paste = (e, t) => {
6185
+ G.paste = (e, t) => {
6186
6186
  let n = t;
6187
- if (e.composing && !ai) return;
6188
- let r = Uo ? null : n.clipboardData, i = e.input.shiftKey && e.input.lastKeyCode != 45;
6189
- r && Ko(e, qo(r), r.getData("text/html"), i, n) ? n.preventDefault() : Go(e, n);
6187
+ if (e.composing && !ii) return;
6188
+ let r = Ho ? null : n.clipboardData, i = e.input.shiftKey && e.input.lastKeyCode != 45;
6189
+ r && Go(e, Ko(r), r.getData("text/html"), i, n) ? n.preventDefault() : Wo(e, n);
6190
6190
  };
6191
- var Jo = class {
6191
+ var qo = class {
6192
6192
  constructor(e, t, n) {
6193
6193
  this.slice = e, this.move = t, this.node = n;
6194
6194
  }
6195
- }, Yo = B ? "altKey" : "ctrlKey";
6196
- function Xo(e, t) {
6195
+ }, Jo = V ? "altKey" : "ctrlKey";
6196
+ function Yo(e, t) {
6197
6197
  let n;
6198
6198
  return e.someProp("dragCopies", (e) => {
6199
6199
  n ||= e(t);
6200
- }), n == null ? !t[Yo] : !n;
6200
+ }), n == null ? !t[Jo] : !n;
6201
6201
  }
6202
- U.dragstart = (e, t) => {
6202
+ W.dragstart = (e, t) => {
6203
6203
  let n = t, r = e.input.mouseDown;
6204
6204
  if (r && r.done(), !n.dataTransfer) return;
6205
- let i = e.state.selection, a = i.empty ? null : e.posAtCoords(yo(n)), o;
6205
+ let i = e.state.selection, a = i.empty ? null : e.posAtCoords(vo(n)), o;
6206
6206
  if (!(a && a.pos >= i.from && a.pos <= (i instanceof k ? i.to - 1 : i.to))) {
6207
6207
  if (r && r.mightDrag) o = k.create(e.state.doc, r.mightDrag.pos);
6208
6208
  else if (n.target && P(n.target)) {
@@ -6210,29 +6210,29 @@ U.dragstart = (e, t) => {
6210
6210
  t && t.node.type.spec.draggable && t != e.docView && (o = k.create(e.state.doc, t.posBefore));
6211
6211
  }
6212
6212
  }
6213
- let { dom: s, text: c, slice: l } = Ka(e, (o || e.state.selection).content());
6214
- (!n.dataTransfer.files.length || !R || ni > 120) && n.dataTransfer.clearData(), n.dataTransfer.setData(Uo ? "Text" : "text/html", s.innerHTML), n.dataTransfer.effectAllowed = "copyMove", Uo || n.dataTransfer.setData("text/plain", c), e.dragging = new Jo(l, Xo(e, n), o);
6215
- }, U.dragend = (e) => {
6213
+ let { dom: s, text: c, slice: l } = Ga(e, (o || e.state.selection).content());
6214
+ (!n.dataTransfer.files.length || !z || ti > 120) && n.dataTransfer.clearData(), n.dataTransfer.setData(Ho ? "Text" : "text/html", s.innerHTML), n.dataTransfer.effectAllowed = "copyMove", Ho || n.dataTransfer.setData("text/plain", c), e.dragging = new qo(l, Yo(e, n), o);
6215
+ }, W.dragend = (e) => {
6216
6216
  let t = e.dragging;
6217
6217
  window.setTimeout(() => {
6218
6218
  e.dragging == t && (e.dragging = null);
6219
6219
  }, 50);
6220
- }, W.dragover = W.dragenter = (e, t) => t.preventDefault(), W.drop = (e, t) => {
6220
+ }, G.dragover = G.dragenter = (e, t) => t.preventDefault(), G.drop = (e, t) => {
6221
6221
  try {
6222
- Zo(e, t, e.dragging);
6222
+ Xo(e, t, e.dragging);
6223
6223
  } finally {
6224
6224
  e.dragging = null;
6225
6225
  }
6226
6226
  };
6227
- function Zo(e, t, n) {
6227
+ function Xo(e, t, n) {
6228
6228
  if (!t.dataTransfer) return;
6229
- let r = e.posAtCoords(yo(t));
6229
+ let r = e.posAtCoords(vo(t));
6230
6230
  if (!r) return;
6231
6231
  let i = e.state.doc.resolve(r.pos), a = n && n.slice;
6232
6232
  a ? e.someProp("transformPasted", (t) => {
6233
6233
  a = t(a, e, !1);
6234
- }) : a = qa(e, qo(t.dataTransfer), Uo ? null : t.dataTransfer.getData("text/html"), !1, i);
6235
- let o = !!(n && Xo(e, t));
6234
+ }) : a = Ka(e, Ko(t.dataTransfer), Ho ? null : t.dataTransfer.getData("text/html"), !1, i);
6235
+ let o = !!(n && Yo(e, t));
6236
6236
  if (e.someProp("handleDrop", (n) => n(e, t, a || p.empty, o))) {
6237
6237
  t.preventDefault();
6238
6238
  return;
@@ -6252,11 +6252,11 @@ function Zo(e, t, n) {
6252
6252
  if (u && k.isSelectable(a.content.firstChild) && f.nodeAfter && f.nodeAfter.sameMarkup(a.content.firstChild)) c.setSelection(new k(f));
6253
6253
  else {
6254
6254
  let t = c.mapping.map(s);
6255
- c.mapping.maps[c.mapping.maps.length - 1].forEach((e, n, r, i) => t = i), c.setSelection(wa(e, f, c.doc.resolve(t)));
6255
+ c.mapping.maps[c.mapping.maps.length - 1].forEach((e, n, r, i) => t = i), c.setSelection(Ca(e, f, c.doc.resolve(t)));
6256
6256
  }
6257
6257
  e.focus(), e.dispatch(c.setMeta("uiEvent", "drop"));
6258
6258
  }
6259
- U.focus = (e) => {
6259
+ W.focus = (e) => {
6260
6260
  if (e.input.lastFocus = Date.now(), !e.focused) {
6261
6261
  e.domObserver.stop(), e.dom.classList.add("ProseMirror-focused"), e.domObserver.start(), e.focused = !0;
6262
6262
  let t = e.domSelectionRange();
@@ -6264,32 +6264,32 @@ U.focus = (e) => {
6264
6264
  let { focusNode: n, focusOffset: r } = t;
6265
6265
  setTimeout(() => {
6266
6266
  let t = e.domSelectionRange();
6267
- t.focusNode == n && t.focusOffset == r && e.docView && e.hasFocus() && ha(e);
6267
+ t.focusNode == n && t.focusOffset == r && e.docView && e.hasFocus() && ma(e);
6268
6268
  }, 20);
6269
6269
  }
6270
6270
  }
6271
- }, U.blur = (e, t) => {
6271
+ }, W.blur = (e, t) => {
6272
6272
  let n = t;
6273
6273
  e.focused &&= (e.domObserver.stop(), e.dom.classList.remove("ProseMirror-focused"), e.domObserver.start(), n.relatedTarget && e.dom.contains(n.relatedTarget) && e.domObserver.currentSelection.clear(), !1);
6274
- }, U.beforeinput = (e, t) => {
6275
- if (ai && t.inputType == "deleteContentBackward") {
6274
+ }, W.beforeinput = (e, t) => {
6275
+ if (ii && t.inputType == "deleteContentBackward") {
6276
6276
  e.domObserver.flushSoon();
6277
6277
  let { domChangeCount: t } = e.input;
6278
6278
  setTimeout(() => {
6279
- if (e.input.domChangeCount != t || e.domObserver.pendingRecords().length || (e.dom.blur(), e.focus(), vo(e, "Backspace"))) return;
6279
+ if (e.input.domChangeCount != t || e.domObserver.pendingRecords().length || (e.dom.blur(), e.focus(), _o(e, "Backspace"))) return;
6280
6280
  let { $cursor: n } = e.state.selection;
6281
6281
  n && n.pos > 0 && e.dispatch(e.state.tr.delete(n.pos - 1, n.pos).scrollIntoView());
6282
6282
  }, 50);
6283
6283
  }
6284
6284
  };
6285
- for (let e in W) U[e] = W[e];
6286
- function Qo(e, t) {
6285
+ for (let e in G) W[e] = G[e];
6286
+ function Zo(e, t) {
6287
6287
  if (e == t) return !0;
6288
6288
  for (let n in e) if (e[n] !== t[n]) return !1;
6289
6289
  for (let n in t) if (!(n in e)) return !1;
6290
6290
  return !0;
6291
6291
  }
6292
- var $o = class {
6292
+ var Qo = class {
6293
6293
  constructor(e) {
6294
6294
  this.frag = e, this.index = 0, this.off = 0;
6295
6295
  }
@@ -6301,60 +6301,60 @@ var $o = class {
6301
6301
  }
6302
6302
  return null;
6303
6303
  }
6304
- }, es = class e {
6304
+ }, $o = class e {
6305
6305
  constructor(e, t) {
6306
- this.toDOM = e, this.spec = t || as, this.side = this.spec.side || 0;
6306
+ this.toDOM = e, this.spec = t || is, this.side = this.spec.side || 0;
6307
6307
  }
6308
6308
  map(e, t, n, r) {
6309
6309
  let { pos: i, deleted: a } = e.mapResult(t.from + r, this.side < 0 ? -1 : 1);
6310
- return a ? null : new rs(i - n, i - n, this);
6310
+ return a ? null : new ns(i - n, i - n, this);
6311
6311
  }
6312
6312
  valid() {
6313
6313
  return !0;
6314
6314
  }
6315
6315
  eq(t) {
6316
- return this == t || t instanceof e && (this.spec.key && this.spec.key == t.spec.key || this.toDOM == t.toDOM && Qo(this.spec, t.spec));
6316
+ return this == t || t instanceof e && (this.spec.key && this.spec.key == t.spec.key || this.toDOM == t.toDOM && Zo(this.spec, t.spec));
6317
6317
  }
6318
6318
  destroy(e) {
6319
6319
  this.spec.destroy && this.spec.destroy(e);
6320
6320
  }
6321
- }, ts = class e {
6321
+ }, es = class e {
6322
6322
  constructor(e, t) {
6323
- this.attrs = e, this.spec = t || as;
6323
+ this.attrs = e, this.spec = t || is;
6324
6324
  }
6325
6325
  map(e, t, n, r) {
6326
6326
  let i = e.map(t.from + r, this.spec.inclusiveStart ? -1 : 1) - n, a = e.map(t.to + r, this.spec.inclusiveEnd ? 1 : -1) - n;
6327
- return i >= a ? null : new rs(i, a, this);
6327
+ return i >= a ? null : new ns(i, a, this);
6328
6328
  }
6329
6329
  valid(e, t) {
6330
6330
  return t.from < t.to;
6331
6331
  }
6332
6332
  eq(t) {
6333
- return this == t || t instanceof e && Qo(this.attrs, t.attrs) && Qo(this.spec, t.spec);
6333
+ return this == t || t instanceof e && Zo(this.attrs, t.attrs) && Zo(this.spec, t.spec);
6334
6334
  }
6335
6335
  static is(t) {
6336
6336
  return t.type instanceof e;
6337
6337
  }
6338
6338
  destroy() {}
6339
- }, ns = class e {
6339
+ }, ts = class e {
6340
6340
  constructor(e, t) {
6341
- this.attrs = e, this.spec = t || as;
6341
+ this.attrs = e, this.spec = t || is;
6342
6342
  }
6343
6343
  map(e, t, n, r) {
6344
6344
  let i = e.mapResult(t.from + r, 1);
6345
6345
  if (i.deleted) return null;
6346
6346
  let a = e.mapResult(t.to + r, -1);
6347
- return a.deleted || a.pos <= i.pos ? null : new rs(i.pos - n, a.pos - n, this);
6347
+ return a.deleted || a.pos <= i.pos ? null : new ns(i.pos - n, a.pos - n, this);
6348
6348
  }
6349
6349
  valid(e, t, n) {
6350
6350
  let r = n.nodeAt(t.from);
6351
6351
  return !!r && !r.isText && t.from + r.nodeSize == t.to;
6352
6352
  }
6353
6353
  eq(t) {
6354
- return this == t || t instanceof e && Qo(this.attrs, t.attrs) && Qo(this.spec, t.spec);
6354
+ return this == t || t instanceof e && Zo(this.attrs, t.attrs) && Zo(this.spec, t.spec);
6355
6355
  }
6356
6356
  destroy() {}
6357
- }, rs = class e {
6357
+ }, ns = class e {
6358
6358
  constructor(e, t, n) {
6359
6359
  this.from = e, this.to = t, this.type = n;
6360
6360
  }
@@ -6368,29 +6368,29 @@ var $o = class {
6368
6368
  return this.type.map(e, this, t, n);
6369
6369
  }
6370
6370
  static widget(t, n, r) {
6371
- return new e(t, t, new es(n, r));
6371
+ return new e(t, t, new $o(n, r));
6372
6372
  }
6373
6373
  static inline(t, n, r, i) {
6374
- return new e(t, n, new ts(r, i));
6374
+ return new e(t, n, new es(r, i));
6375
6375
  }
6376
6376
  static node(t, n, r, i) {
6377
- return new e(t, n, new ns(r, i));
6377
+ return new e(t, n, new ts(r, i));
6378
6378
  }
6379
6379
  get spec() {
6380
6380
  return this.type.spec;
6381
6381
  }
6382
6382
  get inline() {
6383
- return this.type instanceof ts;
6383
+ return this.type instanceof es;
6384
6384
  }
6385
6385
  get widget() {
6386
- return this.type instanceof es;
6386
+ return this.type instanceof $o;
6387
6387
  }
6388
- }, is = [], as = {}, G = class e {
6388
+ }, rs = [], is = {}, K = class e {
6389
6389
  constructor(e, t) {
6390
- this.local = e.length ? e : is, this.children = t.length ? t : is;
6390
+ this.local = e.length ? e : rs, this.children = t.length ? t : rs;
6391
6391
  }
6392
6392
  static create(e, t) {
6393
- return t.length ? ps(t, e, 0, as) : K;
6393
+ return t.length ? fs(t, e, 0, is) : q;
6394
6394
  }
6395
6395
  find(e, t, n) {
6396
6396
  let r = [];
@@ -6407,40 +6407,40 @@ var $o = class {
6407
6407
  }
6408
6408
  }
6409
6409
  map(e, t, n) {
6410
- return this == K || e.maps.length == 0 ? this : this.mapInner(e, t, 0, 0, n || as);
6410
+ return this == q || e.maps.length == 0 ? this : this.mapInner(e, t, 0, 0, n || is);
6411
6411
  }
6412
6412
  mapInner(t, n, r, i, a) {
6413
6413
  let o;
6414
6414
  if (this.local.length) {
6415
- let e = new $o(n.content);
6415
+ let e = new Qo(n.content);
6416
6416
  for (let s = 0; s < this.local.length; s++) {
6417
6417
  let c = this.local[s].map(t, r, i);
6418
6418
  c && c.type.valid(n, c, e) ? (o ||= []).push(c) : a.onRemove && a.onRemove(this.local[s].spec);
6419
6419
  }
6420
6420
  }
6421
- return this.children.length ? cs(this.children, o || [], t, n, r, i, a) : o ? new e(o.sort(ms), is) : K;
6421
+ return this.children.length ? ss(this.children, o || [], t, n, r, i, a) : o ? new e(o.sort(ps), rs) : q;
6422
6422
  }
6423
6423
  add(t, n) {
6424
- return n.length ? this == K ? e.create(t, n) : this.addInner(t, n, 0) : this;
6424
+ return n.length ? this == q ? e.create(t, n) : this.addInner(t, n, 0) : this;
6425
6425
  }
6426
6426
  addInner(t, n, r) {
6427
6427
  let i, a = 0;
6428
6428
  t.forEach((e, t) => {
6429
6429
  let o = t + r, s;
6430
- if (s = ds(n, e, o)) {
6430
+ if (s = us(n, e, o)) {
6431
6431
  for (i ||= this.children.slice(); a < i.length && i[a] < t;) a += 3;
6432
- i[a] == t ? i[a + 2] = i[a + 2].addInner(e, s, o + 1) : i.splice(a, 0, t, t + e.nodeSize, ps(s, e, o + 1, as)), a += 3;
6432
+ i[a] == t ? i[a + 2] = i[a + 2].addInner(e, s, o + 1) : i.splice(a, 0, t, t + e.nodeSize, fs(s, e, o + 1, is)), a += 3;
6433
6433
  }
6434
6434
  });
6435
- let o = ls(a ? fs(n) : n, -r);
6435
+ let o = cs(a ? ds(n) : n, -r);
6436
6436
  if (o.length) {
6437
- let e = new $o(t.content);
6437
+ let e = new Qo(t.content);
6438
6438
  for (let n = 0; n < o.length; n++) o[n].type.valid(t, o[n], e) || o.splice(n--, 1);
6439
6439
  }
6440
- return new e(o.length ? this.local.concat(o).sort(ms) : this.local, i || this.children);
6440
+ return new e(o.length ? this.local.concat(o).sort(ps) : this.local, i || this.children);
6441
6441
  }
6442
6442
  remove(e) {
6443
- return e.length == 0 || this == K ? this : this.removeInner(e, 0);
6443
+ return e.length == 0 || this == q ? this : this.removeInner(e, 0);
6444
6444
  }
6445
6445
  removeInner(t, n) {
6446
6446
  let r = this.children, i = this.local;
@@ -6450,15 +6450,15 @@ var $o = class {
6450
6450
  if (!i) continue;
6451
6451
  r == this.children && (r = this.children.slice());
6452
6452
  let s = r[e + 2].removeInner(i, a + 1);
6453
- s == K ? (r.splice(e, 3), e -= 3) : r[e + 2] = s;
6453
+ s == q ? (r.splice(e, 3), e -= 3) : r[e + 2] = s;
6454
6454
  }
6455
6455
  if (i.length) {
6456
6456
  for (let e = 0, r; e < t.length; e++) if (r = t[e]) for (let e = 0; e < i.length; e++) i[e].eq(r, n) && (i == this.local && (i = this.local.slice()), i.splice(e--, 1));
6457
6457
  }
6458
- return r == this.children && i == this.local ? this : i.length || r.length ? new e(i, r) : K;
6458
+ return r == this.children && i == this.local ? this : i.length || r.length ? new e(i, r) : q;
6459
6459
  }
6460
6460
  forChild(t, n) {
6461
- if (this == K) return this;
6461
+ if (this == q) return this;
6462
6462
  if (n.isLeaf) return e.empty;
6463
6463
  let r, i;
6464
6464
  for (let e = 0; e < this.children.length; e += 3) if (this.children[e] >= t) {
@@ -6468,16 +6468,16 @@ var $o = class {
6468
6468
  let a = t + 1, o = a + n.content.size;
6469
6469
  for (let e = 0; e < this.local.length; e++) {
6470
6470
  let t = this.local[e];
6471
- if (t.from < o && t.to > a && t.type instanceof ts) {
6471
+ if (t.from < o && t.to > a && t.type instanceof es) {
6472
6472
  let e = Math.max(a, t.from) - a, n = Math.min(o, t.to) - a;
6473
6473
  e < n && (i ||= []).push(t.copy(e, n));
6474
6474
  }
6475
6475
  }
6476
6476
  if (i) {
6477
- let t = new e(i.sort(ms), is);
6478
- return r ? new ss([t, r]) : t;
6477
+ let t = new e(i.sort(ps), rs);
6478
+ return r ? new as([t, r]) : t;
6479
6479
  }
6480
- return r || K;
6480
+ return r || q;
6481
6481
  }
6482
6482
  eq(t) {
6483
6483
  if (this == t) return !0;
@@ -6487,34 +6487,34 @@ var $o = class {
6487
6487
  return !0;
6488
6488
  }
6489
6489
  locals(e) {
6490
- return hs(this.localsInner(e));
6490
+ return ms(this.localsInner(e));
6491
6491
  }
6492
6492
  localsInner(e) {
6493
- if (this == K) return is;
6494
- if (e.inlineContent || !this.local.some(ts.is)) return this.local;
6493
+ if (this == q) return rs;
6494
+ if (e.inlineContent || !this.local.some(es.is)) return this.local;
6495
6495
  let t = [];
6496
- for (let e = 0; e < this.local.length; e++) this.local[e].type instanceof ts || t.push(this.local[e]);
6496
+ for (let e = 0; e < this.local.length; e++) this.local[e].type instanceof es || t.push(this.local[e]);
6497
6497
  return t;
6498
6498
  }
6499
6499
  forEachSet(e) {
6500
6500
  e(this);
6501
6501
  }
6502
6502
  };
6503
- G.empty = new G([], []), G.removeOverlap = hs;
6504
- var K = G.empty, ss = class e {
6503
+ K.empty = new K([], []), K.removeOverlap = ms;
6504
+ var q = K.empty, as = class e {
6505
6505
  constructor(e) {
6506
6506
  this.members = e;
6507
6507
  }
6508
6508
  map(t, n) {
6509
- let r = this.members.map((e) => e.map(t, n, as));
6509
+ let r = this.members.map((e) => e.map(t, n, is));
6510
6510
  return e.from(r);
6511
6511
  }
6512
6512
  forChild(t, n) {
6513
- if (n.isLeaf) return G.empty;
6513
+ if (n.isLeaf) return K.empty;
6514
6514
  let r = [];
6515
6515
  for (let i = 0; i < this.members.length; i++) {
6516
6516
  let a = this.members[i].forChild(t, n);
6517
- a != K && (a instanceof e ? r = r.concat(a.members) : r.push(a));
6517
+ a != q && (a instanceof e ? r = r.concat(a.members) : r.push(a));
6518
6518
  }
6519
6519
  return e.from(r);
6520
6520
  }
@@ -6535,20 +6535,20 @@ var K = G.empty, ss = class e {
6535
6535
  }
6536
6536
  }
6537
6537
  }
6538
- return t ? hs(n ? t : t.sort(ms)) : is;
6538
+ return t ? ms(n ? t : t.sort(ps)) : rs;
6539
6539
  }
6540
6540
  static from(t) {
6541
6541
  switch (t.length) {
6542
- case 0: return K;
6542
+ case 0: return q;
6543
6543
  case 1: return t[0];
6544
- default: return new e(t.every((e) => e instanceof G) ? t : t.reduce((e, t) => e.concat(t instanceof G ? t : t.members), []));
6544
+ default: return new e(t.every((e) => e instanceof K) ? t : t.reduce((e, t) => e.concat(t instanceof K ? t : t.members), []));
6545
6545
  }
6546
6546
  }
6547
6547
  forEachSet(e) {
6548
6548
  for (let t = 0; t < this.members.length; t++) this.members[t].forEachSet(e);
6549
6549
  }
6550
6550
  };
6551
- function cs(e, t, n, r, i, a, o) {
6551
+ function ss(e, t, n, r, i, a, o) {
6552
6552
  let s = e.slice();
6553
6553
  for (let e = 0, t = a; e < n.maps.length; e++) {
6554
6554
  let r = 0;
@@ -6577,11 +6577,11 @@ function cs(e, t, n, r, i, a, o) {
6577
6577
  let d = n.map(e[t + 1] + a, -1) - i, { index: f, offset: p } = r.content.findIndex(u), m = r.maybeChild(f);
6578
6578
  if (m && p == u && p + m.nodeSize == d) {
6579
6579
  let r = s[t + 2].mapInner(n, m, l + 1, e[t] + a + 1, o);
6580
- r == K ? (s[t + 1] = -2, c = !0) : (s[t] = u, s[t + 1] = d, s[t + 2] = r);
6580
+ r == q ? (s[t + 1] = -2, c = !0) : (s[t] = u, s[t + 1] = d, s[t + 2] = r);
6581
6581
  } else c = !0;
6582
6582
  }
6583
6583
  if (c) {
6584
- let c = ps(us(s, e, t, n, i, a, o), r, 0, o);
6584
+ let c = fs(ls(s, e, t, n, i, a, o), r, 0, o);
6585
6585
  t = c.local;
6586
6586
  for (let e = 0; e < s.length; e += 3) s[e + 1] < 0 && (s.splice(e, 3), e -= 3);
6587
6587
  for (let e = 0, t = 0; e < c.children.length; e += 3) {
@@ -6590,18 +6590,18 @@ function cs(e, t, n, r, i, a, o) {
6590
6590
  s.splice(t, 0, c.children[e], c.children[e + 1], c.children[e + 2]);
6591
6591
  }
6592
6592
  }
6593
- return new G(t.sort(ms), s);
6593
+ return new K(t.sort(ps), s);
6594
6594
  }
6595
- function ls(e, t) {
6595
+ function cs(e, t) {
6596
6596
  if (!t || !e.length) return e;
6597
6597
  let n = [];
6598
6598
  for (let r = 0; r < e.length; r++) {
6599
6599
  let i = e[r];
6600
- n.push(new rs(i.from + t, i.to + t, i.type));
6600
+ n.push(new ns(i.from + t, i.to + t, i.type));
6601
6601
  }
6602
6602
  return n;
6603
6603
  }
6604
- function us(e, t, n, r, i, a, o) {
6604
+ function ls(e, t, n, r, i, a, o) {
6605
6605
  function s(e, t) {
6606
6606
  for (let a = 0; a < e.local.length; a++) {
6607
6607
  let s = e.local[a].map(r, i, t);
@@ -6612,71 +6612,71 @@ function us(e, t, n, r, i, a, o) {
6612
6612
  for (let n = 0; n < e.length; n += 3) e[n + 1] == -1 && s(e[n + 2], t[n] + a + 1);
6613
6613
  return n;
6614
6614
  }
6615
- function ds(e, t, n) {
6615
+ function us(e, t, n) {
6616
6616
  if (t.isLeaf) return null;
6617
6617
  let r = n + t.nodeSize, i = null;
6618
6618
  for (let t = 0, a; t < e.length; t++) (a = e[t]) && a.from > n && a.to < r && ((i ||= []).push(a), e[t] = null);
6619
6619
  return i;
6620
6620
  }
6621
- function fs(e) {
6621
+ function ds(e) {
6622
6622
  let t = [];
6623
6623
  for (let n = 0; n < e.length; n++) e[n] != null && t.push(e[n]);
6624
6624
  return t;
6625
6625
  }
6626
- function ps(e, t, n, r) {
6626
+ function fs(e, t, n, r) {
6627
6627
  let i = [], a = !1;
6628
6628
  t.forEach((t, o) => {
6629
- let s = ds(e, t, o + n);
6629
+ let s = us(e, t, o + n);
6630
6630
  if (s) {
6631
6631
  a = !0;
6632
- let e = ps(s, t, n + o + 1, r);
6633
- e != K && i.push(o, o + t.nodeSize, e);
6632
+ let e = fs(s, t, n + o + 1, r);
6633
+ e != q && i.push(o, o + t.nodeSize, e);
6634
6634
  }
6635
6635
  });
6636
- let o = ls(a ? fs(e) : e, -n).sort(ms);
6636
+ let o = cs(a ? ds(e) : e, -n).sort(ps);
6637
6637
  if (o.length) {
6638
- let e = new $o(t.content);
6638
+ let e = new Qo(t.content);
6639
6639
  for (let n = 0; n < o.length; n++) o[n].type.valid(t, o[n], e) || (r.onRemove && r.onRemove(o[n].spec), o.splice(n--, 1));
6640
6640
  }
6641
- return o.length || i.length ? new G(o, i) : K;
6641
+ return o.length || i.length ? new K(o, i) : q;
6642
6642
  }
6643
- function ms(e, t) {
6643
+ function ps(e, t) {
6644
6644
  return e.from - t.from || e.to - t.to;
6645
6645
  }
6646
- function hs(e) {
6646
+ function ms(e) {
6647
6647
  let t = e;
6648
6648
  for (let n = 0; n < t.length - 1; n++) {
6649
6649
  let r = t[n];
6650
6650
  if (r.from != r.to) for (let i = n + 1; i < t.length; i++) {
6651
6651
  let a = t[i];
6652
- if (a.from == r.from) a.to != r.to && (t == e && (t = e.slice()), t[i] = a.copy(a.from, r.to), gs(t, i + 1, a.copy(r.to, a.to)));
6652
+ if (a.from == r.from) a.to != r.to && (t == e && (t = e.slice()), t[i] = a.copy(a.from, r.to), hs(t, i + 1, a.copy(r.to, a.to)));
6653
6653
  else {
6654
- a.from < r.to && (t == e && (t = e.slice()), t[n] = r.copy(r.from, a.from), gs(t, i, r.copy(a.from, r.to)));
6654
+ a.from < r.to && (t == e && (t = e.slice()), t[n] = r.copy(r.from, a.from), hs(t, i, r.copy(a.from, r.to)));
6655
6655
  break;
6656
6656
  }
6657
6657
  }
6658
6658
  }
6659
6659
  return t;
6660
6660
  }
6661
- function gs(e, t, n) {
6662
- for (; t < e.length && ms(n, e[t]) > 0;) t++;
6661
+ function hs(e, t, n) {
6662
+ for (; t < e.length && ps(n, e[t]) > 0;) t++;
6663
6663
  e.splice(t, 0, n);
6664
6664
  }
6665
- function _s(e) {
6665
+ function gs(e) {
6666
6666
  let t = [];
6667
6667
  return e.someProp("decorations", (n) => {
6668
6668
  let r = n(e.state);
6669
- r && r != K && t.push(r);
6670
- }), e.cursorWrapper && t.push(G.create(e.state.doc, [e.cursorWrapper.deco])), ss.from(t);
6669
+ r && r != q && t.push(r);
6670
+ }), e.cursorWrapper && t.push(K.create(e.state.doc, [e.cursorWrapper.deco])), as.from(t);
6671
6671
  }
6672
- var vs = {
6672
+ var _s = {
6673
6673
  childList: !0,
6674
6674
  characterData: !0,
6675
6675
  characterDataOldValue: !0,
6676
6676
  attributes: !0,
6677
6677
  attributeOldValue: !0,
6678
6678
  subtree: !0
6679
- }, ys = I && ei <= 11, bs = class {
6679
+ }, vs = L && $r <= 11, ys = class {
6680
6680
  constructor() {
6681
6681
  this.anchorNode = null, this.anchorOffset = 0, this.focusNode = null, this.focusOffset = 0;
6682
6682
  }
@@ -6689,12 +6689,12 @@ var vs = {
6689
6689
  eq(e) {
6690
6690
  return e.anchorNode == this.anchorNode && e.anchorOffset == this.anchorOffset && e.focusNode == this.focusNode && e.focusOffset == this.focusOffset;
6691
6691
  }
6692
- }, xs = class {
6692
+ }, bs = class {
6693
6693
  constructor(e, t) {
6694
- this.view = e, this.handleDOMChange = t, this.queue = [], this.flushingSoon = -1, this.observer = null, this.currentSelection = new bs(), this.onCharData = null, this.suppressingSelectionUpdates = !1, this.lastChangedTextNode = null, this.observer = window.MutationObserver && new window.MutationObserver((t) => {
6694
+ this.view = e, this.handleDOMChange = t, this.queue = [], this.flushingSoon = -1, this.observer = null, this.currentSelection = new ys(), this.onCharData = null, this.suppressingSelectionUpdates = !1, this.lastChangedTextNode = null, this.observer = window.MutationObserver && new window.MutationObserver((t) => {
6695
6695
  for (let e = 0; e < t.length; e++) this.queue.push(t[e]);
6696
- I && ei <= 11 && t.some((e) => e.type == "childList" && e.removedNodes.length || e.type == "characterData" && e.oldValue.length > e.target.nodeValue.length) ? this.flushSoon() : z && e.composing && t.some((e) => e.type == "childList" && e.target.nodeName == "TR") ? (e.input.badSafariComposition = !0, this.flushSoon()) : this.flush();
6697
- }), ys && (this.onCharData = (e) => {
6696
+ L && $r <= 11 && t.some((e) => e.type == "childList" && e.removedNodes.length || e.type == "characterData" && e.oldValue.length > e.target.nodeValue.length) ? this.flushSoon() : B && e.composing && t.some((e) => e.type == "childList" && e.target.nodeName == "TR") ? (e.input.badSafariComposition = !0, this.flushSoon()) : this.flush();
6697
+ }), vs && (this.onCharData = (e) => {
6698
6698
  this.queue.push({
6699
6699
  target: e.target,
6700
6700
  type: "characterData",
@@ -6711,7 +6711,7 @@ var vs = {
6711
6711
  this.flushingSoon > -1 && (window.clearTimeout(this.flushingSoon), this.flushingSoon = -1, this.flush());
6712
6712
  }
6713
6713
  start() {
6714
- this.observer && (this.observer.takeRecords(), this.observer.observe(this.view.dom, vs)), this.onCharData && this.view.dom.addEventListener("DOMCharacterDataModified", this.onCharData), this.connectSelection();
6714
+ this.observer && (this.observer.takeRecords(), this.observer.observe(this.view.dom, _s)), this.onCharData && this.view.dom.addEventListener("DOMCharacterDataModified", this.onCharData), this.connectSelection();
6715
6715
  }
6716
6716
  stop() {
6717
6717
  if (this.observer) {
@@ -6734,9 +6734,9 @@ var vs = {
6734
6734
  this.suppressingSelectionUpdates = !0, setTimeout(() => this.suppressingSelectionUpdates = !1, 50);
6735
6735
  }
6736
6736
  onSelectionChange() {
6737
- if (Ta(this.view)) {
6738
- if (this.suppressingSelectionUpdates) return ha(this.view);
6739
- if (I && ei <= 11 && !this.view.state.selection.empty) {
6737
+ if (wa(this.view)) {
6738
+ if (this.suppressingSelectionUpdates) return ma(this.view);
6739
+ if (L && $r <= 11 && !this.view.state.selection.empty) {
6740
6740
  let e = this.view.domSelectionRange();
6741
6741
  if (e.focusNode && Ir(e.focusNode, e.focusOffset, e.anchorNode, e.anchorOffset)) return this.flushSoon();
6742
6742
  }
@@ -6770,13 +6770,13 @@ var vs = {
6770
6770
  let t = this.pendingRecords();
6771
6771
  t.length && (this.queue = []);
6772
6772
  let n, r = !1;
6773
- !this.suppressingSelectionUpdates && Ta(e) && (n = e.domSelectionRange(), r = !this.currentSelection.eq(n) && !this.ignoreSelectionChange(n));
6773
+ !this.suppressingSelectionUpdates && wa(e) && (n = e.domSelectionRange(), r = !this.currentSelection.eq(n) && !this.ignoreSelectionChange(n));
6774
6774
  let i = -1, a = -1, o = !1, s = [];
6775
6775
  if (e.editable) for (let e = 0; e < t.length; e++) {
6776
6776
  let n = this.registerMutation(t[e], s);
6777
6777
  n && (i = i < 0 ? n.from : Math.min(n.from, i), a = a < 0 ? n.to : Math.max(n.to, a), n.typeOver && (o = !0));
6778
6778
  }
6779
- if (s.some((e) => e.nodeName == "BR") && (e.input.lastKeyCode == 8 || e.input.lastKeyCode == 46 || R && (e.composing || e.input.compositionEndedAt > Date.now() - 50) && t.some((e) => e.type == "childList" && e.removedNodes.length))) {
6779
+ if (s.some((e) => e.nodeName == "BR") && (e.input.lastKeyCode == 8 || e.input.lastKeyCode == 46 || z && (e.composing || e.input.compositionEndedAt > Date.now() - 50) && t.some((e) => e.type == "childList" && e.removedNodes.length))) {
6780
6780
  for (let e of s) if (e.nodeName == "BR" && e.parentNode) {
6781
6781
  let t = e.nextSibling;
6782
6782
  for (; t && P(t);) {
@@ -6787,7 +6787,7 @@ var vs = {
6787
6787
  t = t.firstChild;
6788
6788
  }
6789
6789
  }
6790
- } else if (L && s.length) {
6790
+ } else if (R && s.length) {
6791
6791
  let t = s.filter((e) => e.nodeName == "BR");
6792
6792
  if (t.length == 2) {
6793
6793
  let [e, n] = t;
@@ -6796,12 +6796,12 @@ var vs = {
6796
6796
  let { focusNode: n } = this.currentSelection;
6797
6797
  for (let r of t) {
6798
6798
  let t = r.parentNode;
6799
- t && t.nodeName == "LI" && (!n || Ds(e, n) != t) && r.remove();
6799
+ t && t.nodeName == "LI" && (!n || Es(e, n) != t) && r.remove();
6800
6800
  }
6801
6801
  }
6802
6802
  }
6803
6803
  let c = null;
6804
- i < 0 && r && e.input.lastFocus > Date.now() - 200 && Math.max(e.input.lastTouch, e.input.lastClick.time) < Date.now() - 300 && Wr(n) && (c = pa(e)) && c.eq(D.near(e.state.doc.resolve(0), 1)) ? (e.input.lastFocus = 0, ha(e), this.currentSelection.set(n), e.scrollToSelection()) : (i > -1 || r) && (i > -1 && (e.docView.markDirty(i, a), ws(e)), e.input.badSafariComposition && (e.input.badSafariComposition = !1, Os(e, s)), this.handleDOMChange(i, a, o, s), e.docView && e.docView.dirty ? e.updateState(e.state) : n && !this.currentSelection.eq(n) && ha(e), n && this.currentSelection.set(n));
6804
+ i < 0 && r && e.input.lastFocus > Date.now() - 200 && Math.max(e.input.lastTouch, e.input.lastClick.time) < Date.now() - 300 && Wr(n) && (c = fa(e)) && c.eq(D.near(e.state.doc.resolve(0), 1)) ? (e.input.lastFocus = 0, ma(e), this.currentSelection.set(n), e.scrollToSelection()) : (i > -1 || r) && (i > -1 && (e.docView.markDirty(i, a), Cs(e)), e.input.badSafariComposition && (e.input.badSafariComposition = !1, Ds(e, s)), this.handleDOMChange(i, a, o, s), e.docView && e.docView.dirty ? e.updateState(e.state) : n && !this.currentSelection.eq(n) && ma(e), n && this.currentSelection.set(n));
6805
6805
  }
6806
6806
  registerMutation(e, t) {
6807
6807
  if (t.indexOf(e.target) > -1) return null;
@@ -6817,7 +6817,7 @@ var vs = {
6817
6817
  to: n.posAfter
6818
6818
  };
6819
6819
  let r = e.previousSibling, i = e.nextSibling;
6820
- if (I && ei <= 11 && e.addedNodes.length) for (let t = 0; t < e.addedNodes.length; t++) {
6820
+ if (L && $r <= 11 && e.addedNodes.length) for (let t = 0; t < e.addedNodes.length; t++) {
6821
6821
  let { previousSibling: n, nextSibling: a } = e.addedNodes[t];
6822
6822
  (!n || Array.prototype.indexOf.call(e.addedNodes, n) < 0) && (r = n), (!a || Array.prototype.indexOf.call(e.addedNodes, a) < 0) && (i = a);
6823
6823
  }
@@ -6836,18 +6836,18 @@ var vs = {
6836
6836
  typeOver: e.target.nodeValue == e.oldValue
6837
6837
  });
6838
6838
  }
6839
- }, Ss = /* @__PURE__ */ new WeakMap(), Cs = !1;
6840
- function ws(e) {
6841
- if (!Ss.has(e) && (Ss.set(e, null), [
6839
+ }, xs = /* @__PURE__ */ new WeakMap(), Ss = !1;
6840
+ function Cs(e) {
6841
+ if (!xs.has(e) && (xs.set(e, null), [
6842
6842
  "normal",
6843
6843
  "nowrap",
6844
6844
  "pre-line"
6845
6845
  ].indexOf(getComputedStyle(e.dom).whiteSpace) !== -1)) {
6846
- if (e.requiresGeckoHackNode = L, Cs) return;
6847
- console.warn("ProseMirror expects the CSS white-space property to be set, preferably to 'pre-wrap'. It is recommended to load style/prosemirror.css from the prosemirror-view package."), Cs = !0;
6846
+ if (e.requiresGeckoHackNode = R, Ss) return;
6847
+ console.warn("ProseMirror expects the CSS white-space property to be set, preferably to 'pre-wrap'. It is recommended to load style/prosemirror.css from the prosemirror-view package."), Ss = !0;
6848
6848
  }
6849
6849
  }
6850
- function Ts(e, t) {
6850
+ function ws(e, t) {
6851
6851
  let n = t.startContainer, r = t.startOffset, i = t.endContainer, a = t.endOffset, o = e.domAtPos(e.state.selection.anchor);
6852
6852
  return Ir(o.node, o.offset, i, a) && ([n, r, i, a] = [
6853
6853
  i,
@@ -6861,25 +6861,25 @@ function Ts(e, t) {
6861
6861
  focusOffset: a
6862
6862
  };
6863
6863
  }
6864
- function Es(e, t) {
6864
+ function Ts(e, t) {
6865
6865
  if (t.getComposedRanges) {
6866
6866
  let n = t.getComposedRanges(e.root)[0];
6867
- if (n) return Ts(e, n);
6867
+ if (n) return ws(e, n);
6868
6868
  }
6869
6869
  let n;
6870
6870
  function r(e) {
6871
6871
  e.preventDefault(), e.stopImmediatePropagation(), n = e.getTargetRanges()[0];
6872
6872
  }
6873
- return e.dom.addEventListener("beforeinput", r, !0), document.execCommand("indent"), e.dom.removeEventListener("beforeinput", r, !0), n ? Ts(e, n) : null;
6873
+ return e.dom.addEventListener("beforeinput", r, !0), document.execCommand("indent"), e.dom.removeEventListener("beforeinput", r, !0), n ? ws(e, n) : null;
6874
6874
  }
6875
- function Ds(e, t) {
6875
+ function Es(e, t) {
6876
6876
  for (let n = t.parentNode; n && n != e.dom; n = n.parentNode) {
6877
6877
  let t = e.docView.nearestDesc(n, !0);
6878
6878
  if (t && t.node.isBlock) return n;
6879
6879
  }
6880
6880
  return null;
6881
6881
  }
6882
- function Os(e, t) {
6882
+ function Ds(e, t) {
6883
6883
  let { focusNode: n, focusOffset: r } = e.domSelectionRange();
6884
6884
  for (let i of t) if (i.parentNode?.nodeName == "TR") {
6885
6885
  let t = i.nextSibling;
@@ -6895,7 +6895,7 @@ function Os(e, t) {
6895
6895
  } else i.parentNode.removeChild(i);
6896
6896
  }
6897
6897
  }
6898
- function ks(e, t, n, r) {
6898
+ function Os(e, t, n, r) {
6899
6899
  let { node: i, fromOffset: a, toOffset: o, from: s, to: c } = e.docView.parseRange(t, n), l = e.domSelectionRange(), u, d = l.anchorNode;
6900
6900
  if (d && zr(e.dom, d) && (u = [{
6901
6901
  node: d,
@@ -6903,7 +6903,7 @@ function ks(e, t, n, r) {
6903
6903
  }], Wr(l) || u.push({
6904
6904
  node: l.focusNode,
6905
6905
  offset: l.focusOffset
6906
- })), R && e.input.lastKeyCode === 8) for (let e = o; e > a; e--) {
6906
+ })), z && e.input.lastKeyCode === 8) for (let e = o; e > a; e--) {
6907
6907
  let t = i.childNodes[e - 1], n = t.pmViewDesc;
6908
6908
  if (t.nodeName == "BR" && !n) {
6909
6909
  o = e;
@@ -6919,7 +6919,7 @@ function ks(e, t, n, r) {
6919
6919
  to: o,
6920
6920
  preserveWhitespace: m.parent.type.whitespace != "pre" || "full",
6921
6921
  findPositions: u,
6922
- ruleFromNode: As(r),
6922
+ ruleFromNode: ks(r),
6923
6923
  context: m
6924
6924
  });
6925
6925
  if (u && u[0].pos != null) {
@@ -6936,24 +6936,24 @@ function ks(e, t, n, r) {
6936
6936
  to: c
6937
6937
  };
6938
6938
  }
6939
- var As = (e) => (t) => {
6939
+ var ks = (e) => (t) => {
6940
6940
  let n = t.pmViewDesc;
6941
6941
  if (n) return n.parseRule(e);
6942
6942
  if (t.nodeName == "BR" && t.parentNode) {
6943
- if (z && /^(ul|ol)$/i.test(t.parentNode.nodeName)) {
6943
+ if (B && /^(ul|ol)$/i.test(t.parentNode.nodeName)) {
6944
6944
  let e = document.createElement("div");
6945
6945
  return e.appendChild(document.createElement("li")), { skip: e };
6946
6946
  }
6947
- if (t.parentNode.lastChild == t || z && /^(tr|table)$/i.test(t.parentNode.nodeName)) return { ignore: !0 };
6947
+ if (t.parentNode.lastChild == t || B && /^(tr|table)$/i.test(t.parentNode.nodeName)) return { ignore: !0 };
6948
6948
  } else if (t.nodeName == "IMG" && t.getAttribute("mark-placeholder")) return { ignore: !0 };
6949
6949
  return null;
6950
- }, js = /^(a|abbr|acronym|b|bd[io]|big|br|button|cite|code|data(list)?|del|dfn|em|i|img|ins|kbd|label|map|mark|meter|output|q|ruby|s|samp|small|span|strong|su[bp]|time|u|tt|var)$/i;
6951
- function Ms(e, t, n, r, i) {
6950
+ }, As = /^(a|abbr|acronym|b|bd[io]|big|br|button|cite|code|data(list)?|del|dfn|em|i|img|ins|kbd|label|map|mark|meter|output|q|ruby|s|samp|small|span|strong|su[bp]|time|u|tt|var)$/i;
6951
+ function js(e, t, n, r, i) {
6952
6952
  let a = e.input.compositionPendingChanges || (e.composing ? e.input.compositionID : 0);
6953
6953
  if (e.input.compositionPendingChanges = 0, t < 0) {
6954
- let t = e.input.lastSelectionTime > Date.now() - 50 ? e.input.lastSelectionOrigin : null, n = pa(e, t);
6954
+ let t = e.input.lastSelectionTime > Date.now() - 50 ? e.input.lastSelectionOrigin : null, n = fa(e, t);
6955
6955
  if (n && !e.state.selection.eq(n)) {
6956
- if (R && ai && e.input.lastKeyCode === 13 && Date.now() - 100 < e.input.lastKeyCodeTime && vo(e, "Enter")) return;
6956
+ if (z && ii && e.input.lastKeyCode === 13 && Date.now() - 100 < e.input.lastKeyCodeTime && _o(e, "Enter")) return;
6957
6957
  let r = e.state.tr.setSelection(n);
6958
6958
  t == "pointer" ? r.setMeta("pointer", !0) : t == "key" && r.scrollIntoView(), a && r.setMeta("composition", a), e.dispatch(r);
6959
6959
  }
@@ -6961,10 +6961,10 @@ function Ms(e, t, n, r, i) {
6961
6961
  }
6962
6962
  let o = e.state.doc.resolve(t), s = o.sharedDepth(n);
6963
6963
  t = o.before(s + 1), n = e.state.doc.resolve(n).after(s + 1);
6964
- let c = e.state.selection, l = ks(e, t, n, i), u = e.state.doc, d = u.slice(l.from, l.to), f, p;
6964
+ let c = e.state.selection, l = Os(e, t, n, i), u = e.state.doc, d = u.slice(l.from, l.to), f, p;
6965
6965
  e.input.lastKeyCode === 8 && Date.now() - 100 < e.input.lastKeyCodeTime ? (f = e.state.selection.to, p = "end") : (f = e.state.selection.from, p = "start"), e.input.lastKeyCode = null;
6966
- let m = Rs(d.content, l.doc.content, l.from, f, p);
6967
- if (m && e.input.domChangeCount++, (ri && e.input.lastIOSEnter > Date.now() - 225 || ai) && i.some((e) => P(e) && !js.test(e.nodeName)) && (!m || m.endA >= m.endB) && vo(e, "Enter")) {
6966
+ let m = Ls(d.content, l.doc.content, l.from, f, p);
6967
+ if (m && e.input.domChangeCount++, (ni && e.input.lastIOSEnter > Date.now() - 225 || ii) && i.some((e) => P(e) && !As.test(e.nodeName)) && (!m || m.endA >= m.endB) && _o(e, "Enter")) {
6968
6968
  e.input.lastIOSEnter = 0;
6969
6969
  return;
6970
6970
  }
@@ -6976,7 +6976,7 @@ function Ms(e, t, n, r, i) {
6976
6976
  };
6977
6977
  else {
6978
6978
  if (l.sel) {
6979
- let t = Ns(e, e.state.doc, l.sel);
6979
+ let t = Ms(e, e.state.doc, l.sel);
6980
6980
  if (t && !t.eq(e.state.selection)) {
6981
6981
  let n = e.state.tr.setSelection(t);
6982
6982
  a && n.setMeta("composition", a), e.dispatch(n);
@@ -6985,31 +6985,31 @@ function Ms(e, t, n, r, i) {
6985
6985
  return;
6986
6986
  }
6987
6987
  }
6988
- e.state.selection.from < e.state.selection.to && m.start == m.endB && e.state.selection instanceof O && (m.start > e.state.selection.from && m.start <= e.state.selection.from + 2 && e.state.selection.from >= l.from ? m.start = e.state.selection.from : m.endA < e.state.selection.to && m.endA >= e.state.selection.to - 2 && e.state.selection.to <= l.to && (m.endB += e.state.selection.to - m.endA, m.endA = e.state.selection.to)), I && ei <= 11 && m.endB == m.start + 1 && m.endA == m.start && m.start > l.from && l.doc.textBetween(m.start - l.from - 1, m.start - l.from + 1) == " \xA0" && (m.start--, m.endA--, m.endB--);
6988
+ e.state.selection.from < e.state.selection.to && m.start == m.endB && e.state.selection instanceof O && (m.start > e.state.selection.from && m.start <= e.state.selection.from + 2 && e.state.selection.from >= l.from ? m.start = e.state.selection.from : m.endA < e.state.selection.to && m.endA >= e.state.selection.to - 2 && e.state.selection.to <= l.to && (m.endB += e.state.selection.to - m.endA, m.endA = e.state.selection.to)), L && $r <= 11 && m.endB == m.start + 1 && m.endA == m.start && m.start > l.from && l.doc.textBetween(m.start - l.from - 1, m.start - l.from + 1) == " \xA0" && (m.start--, m.endA--, m.endB--);
6989
6989
  let h = l.doc.resolveNoCache(m.start - l.from), g = l.doc.resolveNoCache(m.endB - l.from), _ = u.resolve(m.start), ee = h.sameParent(g) && h.parent.inlineContent && _.end() >= m.endA;
6990
- if ((ri && e.input.lastIOSEnter > Date.now() - 225 && (!ee || i.some((e) => e.nodeName == "DIV" || e.nodeName == "P")) || !ee && Is(l.doc, h.pos, g.pos)) && vo(e, "Enter")) {
6990
+ if ((ni && e.input.lastIOSEnter > Date.now() - 225 && (!ee || i.some((e) => e.nodeName == "DIV" || e.nodeName == "P")) || !ee && Fs(l.doc, h.pos, g.pos)) && _o(e, "Enter")) {
6991
6991
  e.input.lastIOSEnter = 0;
6992
6992
  return;
6993
6993
  }
6994
- if (e.state.selection.anchor > m.start && (ee ? m.endA > m.start && m.endB == m.start : Fs(u, m.start, m.endA, h, g)) && vo(e, "Backspace")) {
6995
- ai && R && e.domObserver.suppressSelectionUpdates();
6994
+ if (e.state.selection.anchor > m.start && (ee ? m.endA > m.start && m.endB == m.start : Ps(u, m.start, m.endA, h, g)) && _o(e, "Backspace")) {
6995
+ ii && z && e.domObserver.suppressSelectionUpdates();
6996
6996
  return;
6997
6997
  }
6998
- R && m.endB == m.start && (e.input.lastChromeDelete = Date.now()), ai && !ee && h.start() != g.start() && g.parentOffset == 0 && h.depth == g.depth && l.sel && l.sel.anchor == l.sel.head && l.sel.head == m.endA && (m.endB -= 2, g = l.doc.resolveNoCache(m.endB - l.from), setTimeout(() => vo(e, "Enter"), 20));
6998
+ z && m.endB == m.start && (e.input.lastChromeDelete = Date.now()), ii && !ee && h.start() != g.start() && g.parentOffset == 0 && h.depth == g.depth && l.sel && l.sel.anchor == l.sel.head && l.sel.head == m.endA && (m.endB -= 2, g = l.doc.resolveNoCache(m.endB - l.from), setTimeout(() => _o(e, "Enter"), 20));
6999
6999
  let v = m.start, y = m.endA, b = (t) => {
7000
7000
  let n = t || e.state.tr.replace(v, y, l.doc.slice(m.start - l.from, m.endB - l.from));
7001
7001
  if (l.sel) {
7002
- let t = Ns(e, n.doc, l.sel);
7003
- t && !(R && e.composing && t.empty && (m.start != m.endB || e.input.lastChromeDelete < Date.now() - 100) && (t.head == v || t.head == n.mapping.map(y) - 1) || I && t.empty && t.head == v) && n.setSelection(t);
7002
+ let t = Ms(e, n.doc, l.sel);
7003
+ t && !(z && e.composing && t.empty && (m.start != m.endB || e.input.lastChromeDelete < Date.now() - 100) && (t.head == v || t.head == n.mapping.map(y) - 1) || L && t.empty && t.head == v) && n.setSelection(t);
7004
7004
  }
7005
7005
  return a && n.setMeta("composition", a), n.scrollIntoView();
7006
7006
  }, x;
7007
7007
  if (ee) {
7008
7008
  if (h.pos == g.pos) {
7009
- I && ei <= 11 && h.parentOffset == 0 && (e.domObserver.suppressSelectionUpdates(), setTimeout(() => ha(e), 20));
7009
+ L && $r <= 11 && h.parentOffset == 0 && (e.domObserver.suppressSelectionUpdates(), setTimeout(() => ma(e), 20));
7010
7010
  let t = b(e.state.tr.delete(v, y)), n = u.resolve(m.start).marksAcross(u.resolve(m.endA));
7011
7011
  n && t.ensureMarks(n), e.dispatch(t);
7012
- } else if (m.endA == m.endB && (x = Ps(h.parent.content.cut(h.parentOffset, g.parentOffset), _.parent.content.cut(_.parentOffset, m.endA - _.start())))) {
7012
+ } else if (m.endA == m.endB && (x = Ns(h.parent.content.cut(h.parentOffset, g.parentOffset), _.parent.content.cut(_.parentOffset, m.endA - _.start())))) {
7013
7013
  let t = b(e.state.tr);
7014
7014
  x.type == "add" ? t.addMark(v, y, x.mark) : t.removeMark(v, y, x.mark), e.dispatch(t);
7015
7015
  } else if (h.parent.child(h.index()).isText && h.index() == g.index() - +!g.textOffset) {
@@ -7018,10 +7018,10 @@ function Ms(e, t, n, r, i) {
7018
7018
  } else e.dispatch(b());
7019
7019
  } else e.dispatch(b());
7020
7020
  }
7021
- function Ns(e, t, n) {
7022
- return Math.max(n.anchor, n.head) > t.content.size ? null : wa(e, t.resolve(n.anchor), t.resolve(n.head));
7021
+ function Ms(e, t, n) {
7022
+ return Math.max(n.anchor, n.head) > t.content.size ? null : Ca(e, t.resolve(n.anchor), t.resolve(n.head));
7023
7023
  }
7024
- function Ps(e, t) {
7024
+ function Ns(e, t) {
7025
7025
  let n = e.firstChild.marks, r = t.firstChild.marks, i = n, a = r, o, c, l;
7026
7026
  for (let e = 0; e < r.length; e++) i = r[e].removeFromSet(i);
7027
7027
  for (let e = 0; e < n.length; e++) a = n[e].removeFromSet(a);
@@ -7035,24 +7035,24 @@ function Ps(e, t) {
7035
7035
  type: o
7036
7036
  };
7037
7037
  }
7038
- function Fs(e, t, n, r, i) {
7039
- if (n - t <= i.pos - r.pos || Ls(r, !0, !1) < i.pos) return !1;
7038
+ function Ps(e, t, n, r, i) {
7039
+ if (n - t <= i.pos - r.pos || Is(r, !0, !1) < i.pos) return !1;
7040
7040
  let a = e.resolve(t);
7041
7041
  if (!r.parent.inlineContent) {
7042
7042
  let e = a.nodeAfter;
7043
7043
  return e != null && n == t + e.nodeSize;
7044
7044
  }
7045
7045
  if (a.parentOffset < a.parent.content.size || !a.parent.isTextblock) return !1;
7046
- let o = e.resolve(Ls(a, !0, !0));
7047
- return !o.parent.isTextblock || o.pos > n || Ls(o, !0, !1) < n ? !1 : r.parent.content.cut(r.parentOffset).eq(o.parent.content);
7046
+ let o = e.resolve(Is(a, !0, !0));
7047
+ return !o.parent.isTextblock || o.pos > n || Is(o, !0, !1) < n ? !1 : r.parent.content.cut(r.parentOffset).eq(o.parent.content);
7048
7048
  }
7049
- function Is(e, t, n) {
7049
+ function Fs(e, t, n) {
7050
7050
  let r = 0, i = 0;
7051
7051
  return e.nodesBetween(t, n, (e, a) => {
7052
7052
  e.isTextblock && a >= t && a < n ? r++ : (e.isText ? /\S/.test(e.text.slice(Math.max(0, t - a), Math.min(e.nodeSize, n - a))) : e.isLeaf) && i++;
7053
7053
  }), i == 0 && r == 1;
7054
7054
  }
7055
- function Ls(e, t, n) {
7055
+ function Is(e, t, n) {
7056
7056
  let r = e.depth, i = t ? e.end() : e.pos;
7057
7057
  for (; r > 0 && (t || e.indexAfter(r) == e.node(r).childCount);) r--, i++, t = !1;
7058
7058
  if (n) {
@@ -7061,7 +7061,7 @@ function Ls(e, t, n) {
7061
7061
  }
7062
7062
  return i;
7063
7063
  }
7064
- function Rs(e, t, n, r, i) {
7064
+ function Ls(e, t, n, r, i) {
7065
7065
  let a = e.findDiffStart(t, n), o = n + e.size, s = n + t.size;
7066
7066
  if (a == null) return null;
7067
7067
  let { a: c, b: l } = e.findDiffEnd(t, o, s);
@@ -7082,9 +7082,9 @@ function Rs(e, t, n, r, i) {
7082
7082
  endB: l
7083
7083
  };
7084
7084
  }
7085
- var zs = class {
7085
+ var Rs = class {
7086
7086
  constructor(e, t) {
7087
- this._root = null, this.focused = !1, this.trackWrites = null, this.mounted = !1, this.markCursor = null, this.cursorWrapper = null, this.lastSelectedViewDesc = void 0, this.input = new lo(), this.prevDirectPlugins = [], this.pluginViews = [], this.requiresGeckoHackNode = !1, this.dragging = null, this._props = t, this.state = t.state, this.directPlugins = t.plugins || [], this.directPlugins.forEach(Ks), this.dispatch = this.dispatch.bind(this), this.dom = e && e.mount || document.createElement("div"), e && (e.appendChild ? e.appendChild(this.dom) : typeof e == "function" ? e(this.dom) : e.mount && (this.mounted = !0)), this.editable = Hs(this), Vs(this), this.nodeViews = Ws(this), this.docView = qi(this.state.doc, Bs(this), _s(this), this.dom, this), this.domObserver = new xs(this, (e, t, n, r) => Ms(this, e, t, n, r)), this.domObserver.start(), uo(this), this.updatePluginViews();
7087
+ this._root = null, this.focused = !1, this.trackWrites = null, this.mounted = !1, this.markCursor = null, this.cursorWrapper = null, this.lastSelectedViewDesc = void 0, this.input = new co(), this.prevDirectPlugins = [], this.pluginViews = [], this.requiresGeckoHackNode = !1, this.dragging = null, this._props = t, this.state = t.state, this.directPlugins = t.plugins || [], this.directPlugins.forEach(Gs), this.dispatch = this.dispatch.bind(this), this.dom = e && e.mount || document.createElement("div"), e && (e.appendChild ? e.appendChild(this.dom) : typeof e == "function" ? e(this.dom) : e.mount && (this.mounted = !0)), this.editable = Vs(this), Bs(this), this.nodeViews = Us(this), this.docView = Ki(this.state.doc, zs(this), gs(this), this.dom, this), this.domObserver = new bs(this, (e, t, n, r) => js(this, e, t, n, r)), this.domObserver.start(), lo(this), this.updatePluginViews();
7088
7088
  }
7089
7089
  get composing() {
7090
7090
  return this.input.composing;
@@ -7099,9 +7099,9 @@ var zs = class {
7099
7099
  return this._props;
7100
7100
  }
7101
7101
  update(e) {
7102
- e.handleDOMEvents != this._props.handleDOMEvents && mo(this);
7102
+ e.handleDOMEvents != this._props.handleDOMEvents && po(this);
7103
7103
  let t = this._props;
7104
- this._props = e, e.plugins && (e.plugins.forEach(Ks), this.directPlugins = e.plugins), this.updateStateInner(e.state, t);
7104
+ this._props = e, e.plugins && (e.plugins.forEach(Gs), this.directPlugins = e.plugins), this.updateStateInner(e.state, t);
7105
7105
  }
7106
7106
  setProps(e) {
7107
7107
  let t = {};
@@ -7115,35 +7115,35 @@ var zs = class {
7115
7115
  }
7116
7116
  updateStateInner(e, t) {
7117
7117
  let n = this.state, r = !1, i = !1;
7118
- e.storedMarks && this.composing && (zo(this), i = !0), this.state = e;
7118
+ e.storedMarks && this.composing && (Ro(this), i = !0), this.state = e;
7119
7119
  let a = n.plugins != e.plugins || this._props.plugins != t.plugins;
7120
7120
  if (a || this._props.plugins != t.plugins || this._props.nodeViews != t.nodeViews) {
7121
- let e = Ws(this);
7122
- Gs(e, this.nodeViews) && (this.nodeViews = e, r = !0);
7121
+ let e = Us(this);
7122
+ Ws(e, this.nodeViews) && (this.nodeViews = e, r = !0);
7123
7123
  }
7124
- (a || t.handleDOMEvents != this._props.handleDOMEvents) && mo(this), this.editable = Hs(this), Vs(this);
7125
- let o = _s(this), s = Bs(this), c = n.plugins != e.plugins && !n.doc.eq(e.doc) ? "reset" : e.scrollToSelection > n.scrollToSelection ? "to selection" : "preserve", l = r || !this.docView.matchesNode(e.doc, s, o);
7124
+ (a || t.handleDOMEvents != this._props.handleDOMEvents) && po(this), this.editable = Vs(this), Bs(this);
7125
+ let o = gs(this), s = zs(this), c = n.plugins != e.plugins && !n.doc.eq(e.doc) ? "reset" : e.scrollToSelection > n.scrollToSelection ? "to selection" : "preserve", l = r || !this.docView.matchesNode(e.doc, s, o);
7126
7126
  (l || !e.selection.eq(n.selection)) && (i = !0);
7127
- let u = c == "preserve" && i && this.dom.style.overflowAnchor == null && fi(this);
7127
+ let u = c == "preserve" && i && this.dom.style.overflowAnchor == null && di(this);
7128
7128
  if (i) {
7129
7129
  this.domObserver.stop();
7130
- let t = l && (I || R) && !this.composing && !n.selection.empty && !e.selection.empty && Us(n.selection, e.selection);
7130
+ let t = l && (L || z) && !this.composing && !n.selection.empty && !e.selection.empty && Hs(n.selection, e.selection);
7131
7131
  if (l) {
7132
- let n = R ? this.trackWrites = this.domSelectionRange().focusNode : null;
7133
- this.composing && (this.input.compositionNode = Bo(this)), (r || !this.docView.update(e.doc, s, o, this)) && (this.docView.updateOuterDeco(s), this.docView.destroy(), this.docView = qi(e.doc, s, o, this.dom, this)), !n || this.trackWrites && this.dom.contains(this.trackWrites) || (t = !0);
7132
+ let n = z ? this.trackWrites = this.domSelectionRange().focusNode : null;
7133
+ this.composing && (this.input.compositionNode = zo(this)), (r || !this.docView.update(e.doc, s, o, this)) && (this.docView.updateOuterDeco(s), this.docView.destroy(), this.docView = Ki(e.doc, s, o, this.dom, this)), !n || this.trackWrites && this.dom.contains(this.trackWrites) || (t = !0);
7134
7134
  }
7135
7135
  let i = this.input.mouseDown;
7136
- t || !(i && this.domObserver.currentSelection.eq(this.domSelectionRange()) && Da(this) && i.delaySelUpdate()) ? ha(this, t) : (Sa(this, e.selection), this.domObserver.setCurSelection()), this.domObserver.start();
7136
+ t || !(i && this.domObserver.currentSelection.eq(this.domSelectionRange()) && Ea(this) && i.delaySelUpdate()) ? ma(this, t) : (xa(this, e.selection), this.domObserver.setCurSelection()), this.domObserver.start();
7137
7137
  }
7138
- this.updatePluginViews(n), this.dragging?.node && !n.doc.eq(e.doc) && this.updateDraggedNode(this.dragging, n), c == "reset" ? this.dom.scrollTop = 0 : c == "to selection" ? this.scrollToSelection() : u && mi(u);
7138
+ this.updatePluginViews(n), this.dragging?.node && !n.doc.eq(e.doc) && this.updateDraggedNode(this.dragging, n), c == "reset" ? this.dom.scrollTop = 0 : c == "to selection" ? this.scrollToSelection() : u && pi(u);
7139
7139
  }
7140
7140
  scrollToSelection() {
7141
7141
  let e = this.domSelectionRange().focusNode;
7142
7142
  if (e && zr(this.dom, e) && !this.someProp("handleScrollToSelection", (e) => e(this))) {
7143
7143
  if (this.state.selection instanceof k) {
7144
7144
  let t = this.docView.domAfterPos(this.state.selection.from);
7145
- P(t) && di(this, t.getBoundingClientRect(), e);
7146
- } else di(this, this.coordsAtPos(this.state.selection.head, 1), e);
7145
+ P(t) && ui(this, t.getBoundingClientRect(), e);
7146
+ } else ui(this, this.coordsAtPos(this.state.selection.head, 1), e);
7147
7147
  }
7148
7148
  }
7149
7149
  destroyPluginViews() {
@@ -7173,7 +7173,7 @@ var zs = class {
7173
7173
  let e = n.from + (this.state.doc.content.size - t.doc.content.size);
7174
7174
  (e > 0 && e < this.state.doc.content.size && this.state.doc.nodeAt(e)) == n.node && (r = e);
7175
7175
  }
7176
- this.dragging = new Jo(e.slice, e.move, r < 0 ? void 0 : k.create(this.state.doc, r));
7176
+ this.dragging = new qo(e.slice, e.move, r < 0 ? void 0 : k.create(this.state.doc, r));
7177
7177
  }
7178
7178
  someProp(e, t) {
7179
7179
  let n = this._props && this._props[e], r;
@@ -7189,7 +7189,7 @@ var zs = class {
7189
7189
  }
7190
7190
  }
7191
7191
  hasFocus() {
7192
- if (I) {
7192
+ if (L) {
7193
7193
  let e = this.root.activeElement;
7194
7194
  if (e == this.dom) return !0;
7195
7195
  if (!e || !this.dom.contains(e)) return !1;
@@ -7202,7 +7202,7 @@ var zs = class {
7202
7202
  return this.root.activeElement == this.dom;
7203
7203
  }
7204
7204
  focus() {
7205
- this.domObserver.stop(), this.editable && _i(this.dom), ha(this), this.domObserver.start();
7205
+ this.domObserver.stop(), this.editable && gi(this.dom), ma(this), this.domObserver.start();
7206
7206
  }
7207
7207
  get root() {
7208
7208
  let e = this._root;
@@ -7215,10 +7215,10 @@ var zs = class {
7215
7215
  this._root = null;
7216
7216
  }
7217
7217
  posAtCoords(e) {
7218
- return Ti(this, e);
7218
+ return wi(this, e);
7219
7219
  }
7220
7220
  coordsAtPos(e, t = 1) {
7221
- return ki(this, e, t);
7221
+ return Oi(this, e, t);
7222
7222
  }
7223
7223
  domAtPos(e, t = 0) {
7224
7224
  return this.docView.domFromPos(e, t);
@@ -7233,29 +7233,29 @@ var zs = class {
7233
7233
  return r;
7234
7234
  }
7235
7235
  endOfTextblock(e, t) {
7236
- return zi(this, t || this.state, e);
7236
+ return Ri(this, t || this.state, e);
7237
7237
  }
7238
7238
  pasteHTML(e, t) {
7239
- return Ko(this, "", e, !1, t || new ClipboardEvent("paste"));
7239
+ return Go(this, "", e, !1, t || new ClipboardEvent("paste"));
7240
7240
  }
7241
7241
  pasteText(e, t) {
7242
- return Ko(this, e, null, !0, t || new ClipboardEvent("paste"));
7242
+ return Go(this, e, null, !0, t || new ClipboardEvent("paste"));
7243
7243
  }
7244
7244
  serializeForClipboard(e) {
7245
- return Ka(this, e);
7245
+ return Ga(this, e);
7246
7246
  }
7247
7247
  destroy() {
7248
- this.docView && (po(this), this.destroyPluginViews(), this.mounted ? (this.docView.update(this.state.doc, [], _s(this), this), this.dom.textContent = "") : this.dom.parentNode && this.dom.parentNode.removeChild(this.dom), this.docView.destroy(), this.docView = null, Fr());
7248
+ this.docView && (fo(this), this.destroyPluginViews(), this.mounted ? (this.docView.update(this.state.doc, [], gs(this), this), this.dom.textContent = "") : this.dom.parentNode && this.dom.parentNode.removeChild(this.dom), this.docView.destroy(), this.docView = null, Fr());
7249
7249
  }
7250
7250
  get isDestroyed() {
7251
7251
  return this.docView == null;
7252
7252
  }
7253
7253
  dispatchEvent(e) {
7254
- return _o(this, e);
7254
+ return go(this, e);
7255
7255
  }
7256
7256
  domSelectionRange() {
7257
7257
  let e = this.dom.isConnected !== !1 && this.domSelection();
7258
- return e ? z && this.root.nodeType === 11 && Kr(this.dom.ownerDocument) == this.dom && Es(this, e) || e : {
7258
+ return e ? B && this.root.nodeType === 11 && Kr(this.dom.ownerDocument) == this.dom && Ts(this, e) || e : {
7259
7259
  focusNode: null,
7260
7260
  focusOffset: 0,
7261
7261
  anchorNode: null,
@@ -7266,43 +7266,43 @@ var zs = class {
7266
7266
  return this.root.getSelection();
7267
7267
  }
7268
7268
  };
7269
- zs.prototype.dispatch = function(e) {
7269
+ Rs.prototype.dispatch = function(e) {
7270
7270
  let t = this._props.dispatchTransaction;
7271
7271
  t ? t.call(this, e) : this.updateState(this.state.apply(e));
7272
7272
  };
7273
- function Bs(e) {
7273
+ function zs(e) {
7274
7274
  let t = Object.create(null);
7275
7275
  return t.class = "ProseMirror", t.contenteditable = String(e.editable), e.someProp("attributes", (n) => {
7276
7276
  if (typeof n == "function" && (n = n(e.state)), n) for (let e in n) e == "class" ? t.class += " " + n[e] : e == "style" ? t.style = (t.style ? t.style + ";" : "") + n[e] : !t[e] && e != "contenteditable" && e != "nodeName" && (t[e] = String(n[e]));
7277
- }), t.translate ||= "no", [rs.node(0, e.state.doc.content.size, t)];
7277
+ }), t.translate ||= "no", [ns.node(0, e.state.doc.content.size, t)];
7278
7278
  }
7279
- function Vs(e) {
7279
+ function Bs(e) {
7280
7280
  if (e.markCursor) {
7281
7281
  let t = document.createElement("img");
7282
7282
  t.className = "ProseMirror-separator", t.setAttribute("mark-placeholder", "true"), t.setAttribute("alt", ""), e.cursorWrapper = {
7283
7283
  dom: t,
7284
- deco: rs.widget(e.state.selection.from, t, {
7284
+ deco: ns.widget(e.state.selection.from, t, {
7285
7285
  raw: !0,
7286
7286
  marks: e.markCursor
7287
7287
  })
7288
7288
  };
7289
7289
  } else e.cursorWrapper = null;
7290
7290
  }
7291
- function Hs(e) {
7291
+ function Vs(e) {
7292
7292
  return !e.someProp("editable", (t) => t(e.state) === !1);
7293
7293
  }
7294
- function Us(e, t) {
7294
+ function Hs(e, t) {
7295
7295
  let n = Math.min(e.$anchor.sharedDepth(e.head), t.$anchor.sharedDepth(t.head));
7296
7296
  return e.$anchor.start(n) != t.$anchor.start(n);
7297
7297
  }
7298
- function Ws(e) {
7298
+ function Us(e) {
7299
7299
  let t = Object.create(null);
7300
7300
  function n(e) {
7301
7301
  for (let n in e) Object.prototype.hasOwnProperty.call(t, n) || (t[n] = e[n]);
7302
7302
  }
7303
7303
  return e.someProp("nodeViews", n), e.someProp("markViews", n), t;
7304
7304
  }
7305
- function Gs(e, t) {
7305
+ function Ws(e, t) {
7306
7306
  let n = 0, r = 0;
7307
7307
  for (let r in e) {
7308
7308
  if (e[r] != t[r]) return !0;
@@ -7311,10 +7311,10 @@ function Gs(e, t) {
7311
7311
  for (let e in t) r++;
7312
7312
  return n != r;
7313
7313
  }
7314
- function Ks(e) {
7314
+ function Gs(e) {
7315
7315
  if (e.spec.state || e.spec.filterTransaction || e.spec.appendTransaction) throw RangeError("Plugins passed directly to the view must not have a state component");
7316
7316
  }
7317
- for (var qs = {
7317
+ for (var Ks = {
7318
7318
  8: "Backspace",
7319
7319
  9: "Tab",
7320
7320
  10: "Enter",
@@ -7367,7 +7367,7 @@ for (var qs = {
7367
7367
  220: "\\",
7368
7368
  221: "]",
7369
7369
  222: "'"
7370
- }, Js = {
7370
+ }, qs = {
7371
7371
  48: ")",
7372
7372
  49: "!",
7373
7373
  50: "@",
@@ -7392,17 +7392,17 @@ for (var qs = {
7392
7392
  220: "|",
7393
7393
  221: "}",
7394
7394
  222: "\""
7395
- }, Ys = typeof navigator < "u" && /Mac/.test(navigator.platform), Xs = typeof navigator < "u" && /MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent), q = 0; q < 10; q++) qs[48 + q] = qs[96 + q] = String(q);
7396
- for (var q = 1; q <= 24; q++) qs[q + 111] = "F" + q;
7397
- for (var q = 65; q <= 90; q++) qs[q] = String.fromCharCode(q + 32), Js[q] = String.fromCharCode(q);
7398
- for (var Zs in qs) Js.hasOwnProperty(Zs) || (Js[Zs] = qs[Zs]);
7399
- function Qs(e) {
7400
- var t = !(Ys && e.metaKey && e.shiftKey && !e.ctrlKey && !e.altKey || Xs && e.shiftKey && e.key && e.key.length == 1 || e.key == "Unidentified") && e.key || (e.shiftKey ? Js : qs)[e.keyCode] || e.key || "Unidentified";
7395
+ }, Js = typeof navigator < "u" && /Mac/.test(navigator.platform), Ys = typeof navigator < "u" && /MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent), J = 0; J < 10; J++) Ks[48 + J] = Ks[96 + J] = String(J);
7396
+ for (var J = 1; J <= 24; J++) Ks[J + 111] = "F" + J;
7397
+ for (var J = 65; J <= 90; J++) Ks[J] = String.fromCharCode(J + 32), qs[J] = String.fromCharCode(J);
7398
+ for (var Xs in Ks) qs.hasOwnProperty(Xs) || (qs[Xs] = Ks[Xs]);
7399
+ function Zs(e) {
7400
+ var t = !(Js && e.metaKey && e.shiftKey && !e.ctrlKey && !e.altKey || Ys && e.shiftKey && e.key && e.key.length == 1 || e.key == "Unidentified") && e.key || (e.shiftKey ? qs : Ks)[e.keyCode] || e.key || "Unidentified";
7401
7401
  return t == "Esc" && (t = "Escape"), t == "Del" && (t = "Delete"), t == "Left" && (t = "ArrowLeft"), t == "Up" && (t = "ArrowUp"), t == "Right" && (t = "ArrowRight"), t == "Down" && (t = "ArrowDown"), t;
7402
7402
  }
7403
7403
  // ../../node_modules/.pnpm/prosemirror-keymap@1.2.3/node_modules/prosemirror-keymap/dist/index.js
7404
- var $s = typeof navigator < "u" && /Mac|iP(hone|[oa]d)/.test(navigator.platform), ec = typeof navigator < "u" && /Win/.test(navigator.platform);
7405
- function tc(e) {
7404
+ var Qs = typeof navigator < "u" && /Mac|iP(hone|[oa]d)/.test(navigator.platform), $s = typeof navigator < "u" && /Win/.test(navigator.platform);
7405
+ function ec(e) {
7406
7406
  let t = e.split(/-(?!$)/), n = t[t.length - 1];
7407
7407
  n == "Space" && (n = " ");
7408
7408
  let r, i, a, o;
@@ -7412,34 +7412,34 @@ function tc(e) {
7412
7412
  else if (/^a(lt)?$/i.test(n)) r = !0;
7413
7413
  else if (/^(c|ctrl|control)$/i.test(n)) i = !0;
7414
7414
  else if (/^s(hift)?$/i.test(n)) a = !0;
7415
- else if (/^mod$/i.test(n)) $s ? o = !0 : i = !0;
7415
+ else if (/^mod$/i.test(n)) Qs ? o = !0 : i = !0;
7416
7416
  else throw Error("Unrecognized modifier name: " + n);
7417
7417
  }
7418
7418
  return r && (n = "Alt-" + n), i && (n = "Ctrl-" + n), o && (n = "Meta-" + n), a && (n = "Shift-" + n), n;
7419
7419
  }
7420
- function nc(e) {
7420
+ function tc(e) {
7421
7421
  let t = Object.create(null);
7422
- for (let n in e) t[tc(n)] = e[n];
7422
+ for (let n in e) t[ec(n)] = e[n];
7423
7423
  return t;
7424
7424
  }
7425
- function rc(e, t, n = !0) {
7425
+ function nc(e, t, n = !0) {
7426
7426
  return t.altKey && (e = "Alt-" + e), t.ctrlKey && (e = "Ctrl-" + e), t.metaKey && (e = "Meta-" + e), n && t.shiftKey && (e = "Shift-" + e), e;
7427
7427
  }
7428
- function ic(e) {
7429
- return new A({ props: { handleKeyDown: ac(e) } });
7428
+ function rc(e) {
7429
+ return new A({ props: { handleKeyDown: ic(e) } });
7430
7430
  }
7431
- function ac(e) {
7432
- let t = nc(e);
7431
+ function ic(e) {
7432
+ let t = tc(e);
7433
7433
  return function(e, n) {
7434
- let r = Qs(n), i, a = t[rc(r, n)];
7434
+ let r = Zs(n), i, a = t[nc(r, n)];
7435
7435
  if (a && a(e.state, e.dispatch, e)) return !0;
7436
7436
  if (r.length == 1 && r != " ") {
7437
7437
  if (n.shiftKey) {
7438
- let i = t[rc(r, n, !1)];
7438
+ let i = t[nc(r, n, !1)];
7439
7439
  if (i && i(e.state, e.dispatch, e)) return !0;
7440
7440
  }
7441
- if ((n.altKey || n.metaKey || n.ctrlKey) && !(ec && n.ctrlKey && n.altKey) && (i = qs[n.keyCode]) && i != r) {
7442
- let r = t[rc(i, n)];
7441
+ if ((n.altKey || n.metaKey || n.ctrlKey) && !($s && n.ctrlKey && n.altKey) && (i = Ks[n.keyCode]) && i != r) {
7442
+ let r = t[nc(i, n)];
7443
7443
  if (r && r(e.state, e.dispatch, e)) return !0;
7444
7444
  }
7445
7445
  }
@@ -7447,29 +7447,29 @@ function ac(e) {
7447
7447
  };
7448
7448
  }
7449
7449
  // ../../node_modules/.pnpm/rope-sequence@1.3.4/node_modules/rope-sequence/dist/index.js
7450
- var oc = 200, J = function() {};
7451
- J.prototype.append = function(e) {
7452
- return e.length ? (e = J.from(e), !this.length && e || e.length < oc && this.leafAppend(e) || this.length < oc && e.leafPrepend(this) || this.appendInner(e)) : this;
7453
- }, J.prototype.prepend = function(e) {
7454
- return e.length ? J.from(e).append(this) : this;
7455
- }, J.prototype.appendInner = function(e) {
7456
- return new cc(this, e);
7457
- }, J.prototype.slice = function(e, t) {
7458
- return e === void 0 && (e = 0), t === void 0 && (t = this.length), e >= t ? J.empty : this.sliceInner(Math.max(0, e), Math.min(this.length, t));
7459
- }, J.prototype.get = function(e) {
7450
+ var ac = 200, Y = function() {};
7451
+ Y.prototype.append = function(e) {
7452
+ return e.length ? (e = Y.from(e), !this.length && e || e.length < ac && this.leafAppend(e) || this.length < ac && e.leafPrepend(this) || this.appendInner(e)) : this;
7453
+ }, Y.prototype.prepend = function(e) {
7454
+ return e.length ? Y.from(e).append(this) : this;
7455
+ }, Y.prototype.appendInner = function(e) {
7456
+ return new sc(this, e);
7457
+ }, Y.prototype.slice = function(e, t) {
7458
+ return e === void 0 && (e = 0), t === void 0 && (t = this.length), e >= t ? Y.empty : this.sliceInner(Math.max(0, e), Math.min(this.length, t));
7459
+ }, Y.prototype.get = function(e) {
7460
7460
  if (!(e < 0 || e >= this.length)) return this.getInner(e);
7461
- }, J.prototype.forEach = function(e, t, n) {
7461
+ }, Y.prototype.forEach = function(e, t, n) {
7462
7462
  t === void 0 && (t = 0), n === void 0 && (n = this.length), t <= n ? this.forEachInner(e, t, n, 0) : this.forEachInvertedInner(e, t, n, 0);
7463
- }, J.prototype.map = function(e, t, n) {
7463
+ }, Y.prototype.map = function(e, t, n) {
7464
7464
  t === void 0 && (t = 0), n === void 0 && (n = this.length);
7465
7465
  var r = [];
7466
7466
  return this.forEach(function(t, n) {
7467
7467
  return r.push(e(t, n));
7468
7468
  }, t, n), r;
7469
- }, J.from = function(e) {
7470
- return e instanceof J ? e : e && e.length ? new sc(e) : J.empty;
7469
+ }, Y.from = function(e) {
7470
+ return e instanceof Y ? e : e && e.length ? new oc(e) : Y.empty;
7471
7471
  };
7472
- var sc = /* @__PURE__ */ function(e) {
7472
+ var oc = /* @__PURE__ */ function(e) {
7473
7473
  function t(t) {
7474
7474
  e.call(this), this.values = t;
7475
7475
  }
@@ -7489,17 +7489,17 @@ var sc = /* @__PURE__ */ function(e) {
7489
7489
  }, t.prototype.forEachInvertedInner = function(e, t, n, r) {
7490
7490
  for (var i = t - 1; i >= n; i--) if (e(this.values[i], r + i) === !1) return !1;
7491
7491
  }, t.prototype.leafAppend = function(e) {
7492
- if (this.length + e.length <= oc) return new t(this.values.concat(e.flatten()));
7492
+ if (this.length + e.length <= ac) return new t(this.values.concat(e.flatten()));
7493
7493
  }, t.prototype.leafPrepend = function(e) {
7494
- if (this.length + e.length <= oc) return new t(e.flatten().concat(this.values));
7494
+ if (this.length + e.length <= ac) return new t(e.flatten().concat(this.values));
7495
7495
  }, n.length.get = function() {
7496
7496
  return this.values.length;
7497
7497
  }, n.depth.get = function() {
7498
7498
  return 0;
7499
7499
  }, Object.defineProperties(t.prototype, n), t;
7500
- }(J);
7501
- J.empty = new sc([]);
7502
- var cc = /* @__PURE__ */ function(e) {
7500
+ }(Y);
7501
+ Y.empty = new oc([]);
7502
+ var sc = /* @__PURE__ */ function(e) {
7503
7503
  function t(t, n) {
7504
7504
  e.call(this), this.left = t, this.right = n, this.length = t.length + n.length, this.depth = Math.max(t.depth, n.depth) + 1;
7505
7505
  }
@@ -7526,7 +7526,7 @@ var cc = /* @__PURE__ */ function(e) {
7526
7526
  }, t.prototype.appendInner = function(e) {
7527
7527
  return this.left.depth >= Math.max(this.right.depth, e.depth) + 1 ? new t(this.left, new t(this.right, e)) : new t(this, e);
7528
7528
  }, t;
7529
- }(J), lc = 500, uc = class e {
7529
+ }(Y), cc = 500, lc = class e {
7530
7530
  constructor(e, t) {
7531
7531
  this.items = e, this.eventCount = t;
7532
7532
  }
@@ -7544,9 +7544,9 @@ var cc = /* @__PURE__ */ function(e) {
7544
7544
  if (!t.step) i || (i = this.remapping(r, n + 1), a = i.maps.length), a--, u.push(t);
7545
7545
  else {
7546
7546
  if (i) {
7547
- u.push(new fc(t.map));
7547
+ u.push(new dc(t.map));
7548
7548
  let e = t.step.map(i.slice(a)), n;
7549
- e && o.maybeStep(e).doc && (n = o.mapping.maps[o.mapping.maps.length - 1], l.push(new fc(n, void 0, void 0, l.length + u.length))), a--, n && i.appendMap(n, a);
7549
+ e && o.maybeStep(e).doc && (n = o.mapping.maps[o.mapping.maps.length - 1], l.push(new dc(n, void 0, void 0, l.length + u.length))), a--, n && i.appendMap(n, a);
7550
7550
  } else o.maybeStep(t.step);
7551
7551
  if (t.selection) return s = i ? t.selection.map(i.slice(a)) : t.selection, c = new e(this.items.slice(0, r).append(u.reverse().concat(l)), this.eventCount - 1), !1;
7552
7552
  }
@@ -7559,11 +7559,11 @@ var cc = /* @__PURE__ */ function(e) {
7559
7559
  addTransform(t, n, r, i) {
7560
7560
  let a = [], o = this.eventCount, s = this.items, c = !i && s.length ? s.get(s.length - 1) : null;
7561
7561
  for (let e = 0; e < t.steps.length; e++) {
7562
- let r = t.steps[e].invert(t.docs[e]), l = new fc(t.mapping.maps[e], r, n), u;
7562
+ let r = t.steps[e].invert(t.docs[e]), l = new dc(t.mapping.maps[e], r, n), u;
7563
7563
  (u = c && c.merge(l)) && (l = u, e ? a.pop() : s = s.slice(0, s.length - 1)), a.push(l), n &&= (o++, void 0), i || (c = l);
7564
7564
  }
7565
7565
  let l = o - r.depth;
7566
- return l > mc && (s = dc(s, l), o -= l), new e(s.append(a), o);
7566
+ return l > pc && (s = uc(s, l), o -= l), new e(s.append(a), o);
7567
7567
  }
7568
7568
  remapping(e, t) {
7569
7569
  let n = new _t();
@@ -7573,7 +7573,7 @@ var cc = /* @__PURE__ */ function(e) {
7573
7573
  }, e, t), n;
7574
7574
  }
7575
7575
  addMaps(t) {
7576
- return this.eventCount == 0 ? this : new e(this.items.append(t.map((e) => new fc(e))), this.eventCount);
7576
+ return this.eventCount == 0 ? this : new e(this.items.append(t.map((e) => new dc(e))), this.eventCount);
7577
7577
  }
7578
7578
  rebased(t, n) {
7579
7579
  if (!this.eventCount) return this;
@@ -7590,13 +7590,13 @@ var cc = /* @__PURE__ */ function(e) {
7590
7590
  let i = a.maps[n];
7591
7591
  if (e.step) {
7592
7592
  let o = t.steps[n].invert(t.docs[n]), l = e.selection && e.selection.map(a.slice(c + 1, n));
7593
- l && s++, r.push(new fc(i, o, l));
7594
- } else r.push(new fc(i));
7593
+ l && s++, r.push(new dc(i, o, l));
7594
+ } else r.push(new dc(i));
7595
7595
  }, i);
7596
7596
  let l = [];
7597
- for (let e = n; e < o; e++) l.push(new fc(a.maps[e]));
7597
+ for (let e = n; e < o; e++) l.push(new dc(a.maps[e]));
7598
7598
  let u = this.items.slice(0, i).append(l).append(r), d = new e(u, s);
7599
- return d.emptyItemCount() > lc && (d = d.compress(this.items.length - r.length)), d;
7599
+ return d.emptyItemCount() > cc && (d = d.compress(this.items.length - r.length)), d;
7600
7600
  }
7601
7601
  emptyItemCount() {
7602
7602
  let e = 0;
@@ -7613,21 +7613,21 @@ var cc = /* @__PURE__ */ function(e) {
7613
7613
  if (r--, o && n.appendMap(o, r), t) {
7614
7614
  let s = e.selection && e.selection.map(n.slice(r));
7615
7615
  s && a++;
7616
- let c = new fc(o.invert(), t, s), l, u = i.length - 1;
7616
+ let c = new dc(o.invert(), t, s), l, u = i.length - 1;
7617
7617
  (l = i.length && i[u].merge(c)) ? i[u] = l : i.push(c);
7618
7618
  }
7619
7619
  } else e.map && r--;
7620
- }, this.items.length, 0), new e(J.from(i.reverse()), a);
7620
+ }, this.items.length, 0), new e(Y.from(i.reverse()), a);
7621
7621
  }
7622
7622
  };
7623
- uc.empty = new uc(J.empty, 0);
7624
- function dc(e, t) {
7623
+ lc.empty = new lc(Y.empty, 0);
7624
+ function uc(e, t) {
7625
7625
  let n;
7626
7626
  return e.forEach((e, r) => {
7627
7627
  if (e.selection && t-- == 0) return n = r, !1;
7628
7628
  }), e.slice(n);
7629
7629
  }
7630
- var fc = class e {
7630
+ var dc = class e {
7631
7631
  constructor(e, t, n, r) {
7632
7632
  this.map = e, this.step = t, this.selection = n, this.mirrorOffset = r;
7633
7633
  }
@@ -7637,25 +7637,25 @@ var fc = class e {
7637
7637
  if (n) return new e(n.getMap().invert(), n, this.selection);
7638
7638
  }
7639
7639
  }
7640
- }, pc = class {
7640
+ }, fc = class {
7641
7641
  constructor(e, t, n, r, i) {
7642
7642
  this.done = e, this.undone = t, this.prevRanges = n, this.prevTime = r, this.prevComposition = i;
7643
7643
  }
7644
- }, mc = 20;
7645
- function hc(e, t, n, r) {
7646
- let i = n.getMeta(wc), a;
7644
+ }, pc = 20;
7645
+ function mc(e, t, n, r) {
7646
+ let i = n.getMeta(Cc), a;
7647
7647
  if (i) return i.historyState;
7648
- n.getMeta(Tc) && (e = new pc(e.done, e.undone, null, 0, -1));
7648
+ n.getMeta(wc) && (e = new fc(e.done, e.undone, null, 0, -1));
7649
7649
  let o = n.getMeta("appendedTransaction");
7650
7650
  if (n.steps.length == 0) return e;
7651
- if (o && o.getMeta(wc)) return o.getMeta(wc).redo ? new pc(e.done.addTransform(n, void 0, r, Sc(t)), e.undone, _c(n.mapping.maps), e.prevTime, e.prevComposition) : new pc(e.done, e.undone.addTransform(n, void 0, r, Sc(t)), null, e.prevTime, e.prevComposition);
7651
+ if (o && o.getMeta(Cc)) return o.getMeta(Cc).redo ? new fc(e.done.addTransform(n, void 0, r, xc(t)), e.undone, gc(n.mapping.maps), e.prevTime, e.prevComposition) : new fc(e.done, e.undone.addTransform(n, void 0, r, xc(t)), null, e.prevTime, e.prevComposition);
7652
7652
  if (n.getMeta("addToHistory") !== !1 && !(o && o.getMeta("addToHistory") === !1)) {
7653
- let i = n.getMeta("composition"), a = e.prevTime == 0 || !o && e.prevComposition != i && (e.prevTime < (n.time || 0) - r.newGroupDelay || !gc(n, e.prevRanges)), s = o ? vc(e.prevRanges, n.mapping) : _c(n.mapping.maps);
7654
- return new pc(e.done.addTransform(n, a ? t.selection.getBookmark() : void 0, r, Sc(t)), uc.empty, s, n.time, i ?? e.prevComposition);
7653
+ let i = n.getMeta("composition"), a = e.prevTime == 0 || !o && e.prevComposition != i && (e.prevTime < (n.time || 0) - r.newGroupDelay || !hc(n, e.prevRanges)), s = o ? _c(e.prevRanges, n.mapping) : gc(n.mapping.maps);
7654
+ return new fc(e.done.addTransform(n, a ? t.selection.getBookmark() : void 0, r, xc(t)), lc.empty, s, n.time, i ?? e.prevComposition);
7655
7655
  }
7656
- return (a = n.getMeta("rebased")) ? new pc(e.done.rebased(n, a), e.undone.rebased(n, a), vc(e.prevRanges, n.mapping), e.prevTime, e.prevComposition) : new pc(e.done.addMaps(n.mapping.maps), e.undone.addMaps(n.mapping.maps), vc(e.prevRanges, n.mapping), e.prevTime, e.prevComposition);
7656
+ return (a = n.getMeta("rebased")) ? new fc(e.done.rebased(n, a), e.undone.rebased(n, a), _c(e.prevRanges, n.mapping), e.prevTime, e.prevComposition) : new fc(e.done.addMaps(n.mapping.maps), e.undone.addMaps(n.mapping.maps), _c(e.prevRanges, n.mapping), e.prevTime, e.prevComposition);
7657
7657
  }
7658
- function gc(e, t) {
7658
+ function hc(e, t) {
7659
7659
  if (!t) return !1;
7660
7660
  if (!e.docChanged) return !0;
7661
7661
  let n = !1;
@@ -7663,12 +7663,12 @@ function gc(e, t) {
7663
7663
  for (let i = 0; i < t.length; i += 2) e <= t[i + 1] && r >= t[i] && (n = !0);
7664
7664
  }), n;
7665
7665
  }
7666
- function _c(e) {
7666
+ function gc(e) {
7667
7667
  let t = [];
7668
7668
  for (let n = e.length - 1; n >= 0 && t.length == 0; n--) e[n].forEach((e, n, r, i) => t.push(r, i));
7669
7669
  return t;
7670
7670
  }
7671
- function vc(e, t) {
7671
+ function _c(e, t) {
7672
7672
  if (!e) return null;
7673
7673
  let n = [];
7674
7674
  for (let r = 0; r < e.length; r += 2) {
@@ -7677,69 +7677,69 @@ function vc(e, t) {
7677
7677
  }
7678
7678
  return n;
7679
7679
  }
7680
- function yc(e, t, n) {
7681
- let r = Sc(t), i = wc.get(t).spec.config, a = (n ? e.undone : e.done).popEvent(t, r);
7680
+ function vc(e, t, n) {
7681
+ let r = xc(t), i = Cc.get(t).spec.config, a = (n ? e.undone : e.done).popEvent(t, r);
7682
7682
  if (!a) return null;
7683
- let o = a.selection.resolve(a.transform.doc), s = (n ? e.done : e.undone).addTransform(a.transform, t.selection.getBookmark(), i, r), c = new pc(n ? s : a.remaining, n ? a.remaining : s, null, 0, -1);
7684
- return a.transform.setSelection(o).setMeta(wc, {
7683
+ let o = a.selection.resolve(a.transform.doc), s = (n ? e.done : e.undone).addTransform(a.transform, t.selection.getBookmark(), i, r), c = new fc(n ? s : a.remaining, n ? a.remaining : s, null, 0, -1);
7684
+ return a.transform.setSelection(o).setMeta(Cc, {
7685
7685
  redo: n,
7686
7686
  historyState: c
7687
7687
  });
7688
7688
  }
7689
- var bc = !1, xc = null;
7690
- function Sc(e) {
7689
+ var yc = !1, bc = null;
7690
+ function xc(e) {
7691
7691
  let t = e.plugins;
7692
- if (xc != t) {
7693
- bc = !1, xc = t;
7692
+ if (bc != t) {
7693
+ yc = !1, bc = t;
7694
7694
  for (let e = 0; e < t.length; e++) if (t[e].spec.historyPreserveItems) {
7695
- bc = !0;
7695
+ yc = !0;
7696
7696
  break;
7697
7697
  }
7698
7698
  }
7699
- return bc;
7699
+ return yc;
7700
7700
  }
7701
- function Cc(e) {
7702
- return e.setMeta(Tc, !0);
7701
+ function Sc(e) {
7702
+ return e.setMeta(wc, !0);
7703
7703
  }
7704
- var wc = new j("history"), Tc = new j("closeHistory");
7705
- function Ec(e = {}) {
7704
+ var Cc = new j("history"), wc = new j("closeHistory");
7705
+ function Tc(e = {}) {
7706
7706
  return e = {
7707
7707
  depth: e.depth || 100,
7708
7708
  newGroupDelay: e.newGroupDelay || 500
7709
7709
  }, new A({
7710
- key: wc,
7710
+ key: Cc,
7711
7711
  state: {
7712
7712
  init() {
7713
- return new pc(uc.empty, uc.empty, null, 0, -1);
7713
+ return new fc(lc.empty, lc.empty, null, 0, -1);
7714
7714
  },
7715
7715
  apply(t, n, r) {
7716
- return hc(n, r, t, e);
7716
+ return mc(n, r, t, e);
7717
7717
  }
7718
7718
  },
7719
7719
  config: e,
7720
7720
  props: { handleDOMEvents: { beforeinput(e, t) {
7721
- let n = t.inputType, r = n == "historyUndo" ? Oc : n == "historyRedo" ? kc : null;
7721
+ let n = t.inputType, r = n == "historyUndo" ? Dc : n == "historyRedo" ? Oc : null;
7722
7722
  return !r || !e.editable ? !1 : (t.preventDefault(), r(e.state, e.dispatch));
7723
7723
  } } }
7724
7724
  });
7725
7725
  }
7726
- function Dc(e, t) {
7726
+ function Ec(e, t) {
7727
7727
  return (n, r) => {
7728
- let i = wc.getState(n);
7728
+ let i = Cc.getState(n);
7729
7729
  if (!i || (e ? i.undone : i.done).eventCount == 0) return !1;
7730
7730
  if (r) {
7731
- let a = yc(i, n, e);
7731
+ let a = vc(i, n, e);
7732
7732
  a && r(t ? a.scrollIntoView() : a);
7733
7733
  }
7734
7734
  return !0;
7735
7735
  };
7736
7736
  }
7737
- var Oc = Dc(!1, !0), kc = Dc(!0, !0);
7738
- function Ac(e) {
7739
- return e.getMeta(wc) != null;
7737
+ var Dc = Ec(!1, !0), Oc = Ec(!0, !0);
7738
+ function kc(e) {
7739
+ return e.getMeta(Cc) != null;
7740
7740
  }
7741
- // ../../node_modules/.pnpm/@tiptap+core@3.33.1_@tiptap+pm@3.33.1/node_modules/@tiptap/core/dist/index.js
7742
- function jc(e) {
7741
+ // ../../node_modules/.pnpm/@tiptap+core@3.34.0_@tiptap+pm@3.34.0/node_modules/@tiptap/core/dist/index.js
7742
+ function Ac(e) {
7743
7743
  let { state: t, transaction: n } = e, { selection: r } = n, { doc: i } = n, { storedMarks: a } = n;
7744
7744
  return {
7745
7745
  ...t,
@@ -7763,7 +7763,7 @@ function jc(e) {
7763
7763
  }
7764
7764
  };
7765
7765
  }
7766
- var Mc = class e {
7766
+ var jc = class e {
7767
7767
  constructor(e) {
7768
7768
  this.editor = e.editor, this.rawCommands = this.editor.extensionManager.commands, this.customState = e.state;
7769
7769
  }
@@ -7823,7 +7823,7 @@ var Mc = class e {
7823
7823
  tr: e,
7824
7824
  editor: r,
7825
7825
  view: a,
7826
- state: jc({
7826
+ state: Ac({
7827
7827
  state: i,
7828
7828
  transaction: e
7829
7829
  }),
@@ -7836,12 +7836,12 @@ var Mc = class e {
7836
7836
  };
7837
7837
  return o;
7838
7838
  }
7839
- }, Nc = () => ({ editor: e, view: t }) => (requestAnimationFrame(() => {
7839
+ }, Mc = () => ({ editor: e, view: t }) => (requestAnimationFrame(() => {
7840
7840
  if (!e.isDestroyed) {
7841
7841
  var n;
7842
7842
  t.dom.blur(), (n = window) == null || (n = n.getSelection()) == null || n.removeAllRanges();
7843
7843
  }
7844
- }), !0), Pc = (e = !0) => ({ commands: t }) => t.setContent("", { emitUpdate: e }), Fc = () => ({ tr: e, dispatch: t }) => {
7844
+ }), !0), Nc = (e = !0) => ({ commands: t }) => t.setContent("", { emitUpdate: e }), Pc = () => ({ tr: e, dispatch: t }) => {
7845
7845
  let { selection: n } = e, { ranges: r } = n;
7846
7846
  if (!t) return !0;
7847
7847
  let i = e.mapping.maps.length;
@@ -7866,12 +7866,12 @@ var Mc = class e {
7866
7866
  }), e.doc.eq(t)) break;
7867
7867
  }
7868
7868
  }), !0;
7869
- }, Ic = (e) => (t) => e(t), Lc = () => ({ state: e, dispatch: t }) => or(e, t), Rc = (e, t) => ({ editor: n, tr: r }) => {
7869
+ }, Fc = (e) => (t) => e(t), Ic = () => ({ state: e, dispatch: t }) => or(e, t), Lc = (e, t) => ({ editor: n, tr: r }) => {
7870
7870
  let { state: i } = n, a = i.doc.slice(e.from, e.to);
7871
7871
  r.deleteRange(e.from, e.to);
7872
7872
  let o = r.mapping.map(t);
7873
7873
  return r.insert(o, a.content), r.setSelection(new O(r.doc.resolve(Math.max(o - 1, 0)))), !0;
7874
- }, zc = () => ({ tr: e, dispatch: t }) => {
7874
+ }, Rc = () => ({ tr: e, dispatch: t }) => {
7875
7875
  let { selection: n } = e, r = n.$anchor.node();
7876
7876
  if (r.content.size > 0) return !1;
7877
7877
  let i = e.selection.$anchor;
@@ -7884,15 +7884,15 @@ var Mc = class e {
7884
7884
  }
7885
7885
  return !1;
7886
7886
  };
7887
- function Y(e, t) {
7887
+ function X(e, t) {
7888
7888
  if (typeof e == "string") {
7889
7889
  if (!t.nodes[e]) throw Error(`There is no node type named '${e}'. Maybe you forgot to add the extension?`);
7890
7890
  return t.nodes[e];
7891
7891
  }
7892
7892
  return e;
7893
7893
  }
7894
- var Bc = (e) => ({ tr: t, state: n, dispatch: r }) => {
7895
- let i = Y(e, n.schema), a = t.selection.$anchor;
7894
+ var zc = (e) => ({ tr: t, state: n, dispatch: r }) => {
7895
+ let i = X(e, n.schema), a = t.selection.$anchor;
7896
7896
  for (let e = a.depth; e > 0; --e) if (a.node(e).type === i) {
7897
7897
  if (r) {
7898
7898
  let n = a.before(e), r = a.after(e);
@@ -7901,41 +7901,41 @@ var Bc = (e) => ({ tr: t, state: n, dispatch: r }) => {
7901
7901
  return !0;
7902
7902
  }
7903
7903
  return !1;
7904
- }, Vc = (e) => ({ tr: t, dispatch: n }) => {
7904
+ }, Bc = (e) => ({ tr: t, dispatch: n }) => {
7905
7905
  let { from: r, to: i } = e;
7906
7906
  return n && t.delete(r, i), !0;
7907
- }, Hc = (e) => e.content ? /^text(\*|\+)/.test(e.content) : !1, Uc = (e, t, n) => {
7907
+ }, Vc = (e) => e.content ? /^text(\*|\+)/.test(e.content) : !1, Hc = (e, t, n) => {
7908
7908
  if (!e.parent.isInline || n === "left" && e.pos > e.start() || n === "right" && e.pos < e.end()) return e.pos;
7909
7909
  let r = t.nodes[e.parent.type.name].spec;
7910
- return Hc(r) ? n === "left" ? e.start() - 1 : e.end() + 1 : e.pos;
7911
- }, Wc = (e, t, n) => ({
7912
- from: Uc(e, n, "left"),
7913
- to: Uc(t, n, "right")
7914
- }), Gc = () => ({ state: e, dispatch: t }) => {
7910
+ return Vc(r) ? n === "left" ? e.start() - 1 : e.end() + 1 : e.pos;
7911
+ }, Uc = (e, t, n) => ({
7912
+ from: Hc(e, n, "left"),
7913
+ to: Hc(t, n, "right")
7914
+ }), Wc = () => ({ state: e, dispatch: t }) => {
7915
7915
  if (e.selection.empty) return !1;
7916
7916
  if (t) {
7917
7917
  let n = e.tr, { ranges: r } = e.selection, i = e.selection instanceof O ? e.selection.$from.marksAcross(e.selection.$to) : null, a = n.steps.length;
7918
7918
  r.forEach((t) => {
7919
- let r = n.mapping.slice(a), { from: i, to: o } = Wc(n.doc.resolve(r.map(t.$from.pos)), n.doc.resolve(r.map(t.$to.pos)), e.schema);
7919
+ let r = n.mapping.slice(a), { from: i, to: o } = Uc(n.doc.resolve(r.map(t.$from.pos)), n.doc.resolve(r.map(t.$to.pos)), e.schema);
7920
7920
  n.deleteRange(i, o);
7921
7921
  }), n.selection.empty || n.setSelection(O.near(n.doc.resolve(n.selection.from))), i && n.ensureMarks(i), n.scrollIntoView(), t(n);
7922
7922
  }
7923
7923
  return !0;
7924
- }, Kc = () => ({ commands: e }) => e.keyboardShortcut("Enter"), qc = () => ({ state: e, dispatch: t }) => ar(e, t);
7925
- function Jc(e) {
7924
+ }, Gc = () => ({ commands: e }) => e.keyboardShortcut("Enter"), Kc = () => ({ state: e, dispatch: t }) => ar(e, t);
7925
+ function qc(e) {
7926
7926
  return Object.prototype.toString.call(e) === "[object RegExp]";
7927
7927
  }
7928
- function Yc(e, t, n = { strict: !0 }) {
7928
+ function Jc(e, t, n = { strict: !0 }) {
7929
7929
  let r = Object.keys(t);
7930
- return !r.length || r.every((r) => n.strict ? t[r] === e[r] : Jc(t[r]) ? t[r].test(e[r]) : t[r] === e[r]);
7930
+ return !r.length || r.every((r) => n.strict ? t[r] === e[r] : qc(t[r]) ? t[r].test(e[r]) : t[r] === e[r]);
7931
7931
  }
7932
- function Xc(e, t, n = {}) {
7933
- return e.find((e) => e.type === t && Yc(Object.fromEntries(Object.keys(n).map((t) => [t, e.attrs[t]])), n));
7932
+ function Yc(e, t, n = {}) {
7933
+ return e.find((e) => e.type === t && Jc(Object.fromEntries(Object.keys(n).map((t) => [t, e.attrs[t]])), n));
7934
7934
  }
7935
- function Zc(e, t, n = {}) {
7936
- return !!Xc(e, t, n);
7935
+ function Xc(e, t, n = {}) {
7936
+ return !!Yc(e, t, n);
7937
7937
  }
7938
- function Qc(e, t, n) {
7938
+ function Zc(e, t, n) {
7939
7939
  if (!e || !t) return;
7940
7940
  let r = e.parent.childAfter(e.parentOffset);
7941
7941
  if (r.node && r.node.marks.some((e) => e.type === t) || (r = e.parent.childBefore(e.parentOffset)), !r.node || !r.node.marks.some((e) => e.type === t)) return;
@@ -7943,16 +7943,16 @@ function Qc(e, t, n) {
7943
7943
  let e = r.node.marks.find((e) => e.type === t);
7944
7944
  e && (n = e.attrs);
7945
7945
  }
7946
- if (!Xc([...r.node.marks], t, n)) return;
7946
+ if (!Yc([...r.node.marks], t, n)) return;
7947
7947
  let i = r.index, a = e.start() + r.offset, o = i + 1, s = a + r.node.nodeSize;
7948
- for (; i > 0 && Zc([...e.parent.child(i - 1).marks], t, n);) --i, a -= e.parent.child(i).nodeSize;
7949
- for (; o < e.parent.childCount && Zc([...e.parent.child(o).marks], t, n);) s += e.parent.child(o).nodeSize, o += 1;
7948
+ for (; i > 0 && Xc([...e.parent.child(i - 1).marks], t, n);) --i, a -= e.parent.child(i).nodeSize;
7949
+ for (; o < e.parent.childCount && Xc([...e.parent.child(o).marks], t, n);) s += e.parent.child(o).nodeSize, o += 1;
7950
7950
  return {
7951
7951
  from: a,
7952
7952
  to: s
7953
7953
  };
7954
7954
  }
7955
- function X(e, t) {
7955
+ function Qc(e, t) {
7956
7956
  if (typeof e == "string") {
7957
7957
  if (!t.marks[e]) throw Error(`There is no mark type named '${e}'. Maybe you forgot to add the extension?`);
7958
7958
  return t.marks[e];
@@ -7960,9 +7960,9 @@ function X(e, t) {
7960
7960
  return e;
7961
7961
  }
7962
7962
  var $c = (e, t) => ({ tr: n, state: r, dispatch: i }) => {
7963
- let a = X(e, r.schema), { doc: o, selection: s } = n, { $from: c, from: l, to: u } = s;
7963
+ let a = Qc(e, r.schema), { doc: o, selection: s } = n, { $from: c, from: l, to: u } = s;
7964
7964
  if (i) {
7965
- let e = Qc(c, a, t);
7965
+ let e = Zc(c, a, t);
7966
7966
  if (e && e.from <= l && e.to >= u) {
7967
7967
  let t = O.create(o, e.from, e.to);
7968
7968
  n.setSelection(t);
@@ -8239,7 +8239,7 @@ var Al = (e) => ({ editor: t, view: n, tr: r, dispatch: i }) => {
8239
8239
  }), !0;
8240
8240
  };
8241
8241
  function jl(e, t, n = {}) {
8242
- let { from: r, to: i, empty: a } = e.selection, o = t ? Y(t, e.schema) : null, s = [];
8242
+ let { from: r, to: i, empty: a } = e.selection, o = t ? X(t, e.schema) : null, s = [];
8243
8243
  e.doc.nodesBetween(r, i, (e, t) => {
8244
8244
  if (e.isText) return;
8245
8245
  let n = Math.max(r, t), a = Math.min(i, t + e.nodeSize);
@@ -8249,10 +8249,10 @@ function jl(e, t, n = {}) {
8249
8249
  to: a
8250
8250
  });
8251
8251
  });
8252
- let c = i - r, l = s.filter((e) => !o || o.name === e.node.type.name).filter((e) => Yc(e.node.attrs, n, { strict: !1 }));
8252
+ let c = i - r, l = s.filter((e) => !o || o.name === e.node.type.name).filter((e) => Jc(e.node.attrs, n, { strict: !1 }));
8253
8253
  return a ? !!l.length : l.reduce((e, t) => e + t.to - t.from, 0) >= c;
8254
8254
  }
8255
- var Ml = (e, t = {}) => ({ state: n, dispatch: r }) => jl(n, Y(e, n.schema), t) ? nr(n, r) : !1, Nl = () => ({ state: e, dispatch: t }) => sr(e, t), Pl = (e) => ({ state: t, dispatch: n }) => Or(Y(e, t.schema))(t, n), Fl = () => ({ state: e, dispatch: t }) => rr(e, t);
8255
+ var Ml = (e, t = {}) => ({ state: n, dispatch: r }) => jl(n, X(e, n.schema), t) ? nr(n, r) : !1, Nl = () => ({ state: e, dispatch: t }) => sr(e, t), Pl = (e) => ({ state: t, dispatch: n }) => Or(X(e, t.schema))(t, n), Fl = () => ({ state: e, dispatch: t }) => rr(e, t);
8256
8256
  function Il(e, t) {
8257
8257
  return t.nodes[e] ? "node" : t.marks[e] ? "mark" : null;
8258
8258
  }
@@ -8263,7 +8263,7 @@ function Ll(e, t) {
8263
8263
  var Rl = (e, t) => ({ tr: n, state: r, dispatch: i }) => {
8264
8264
  let a = null, o = null, s = Il(typeof e == "string" ? e : e.name, r.schema);
8265
8265
  if (!s) return !1;
8266
- s === "node" && (a = Y(e, r.schema)), s === "mark" && (o = X(e, r.schema));
8266
+ s === "node" && (a = X(e, r.schema)), s === "mark" && (o = Qc(e, r.schema));
8267
8267
  let c = !1;
8268
8268
  return n.selection.ranges.forEach((e) => {
8269
8269
  r.doc.nodesBetween(e.$from.pos, e.$to.pos, (e, r) => {
@@ -8305,7 +8305,7 @@ var ql = (e, { errorOnInvalidContent: t, emitUpdate: n = !0, parseOptions: r = {
8305
8305
  });
8306
8306
  };
8307
8307
  function Jl(e, t) {
8308
- let n = X(t, e.schema), { from: r, to: i, empty: a } = e.selection, o = [];
8308
+ let n = Qc(t, e.schema), { from: r, to: i, empty: a } = e.selection, o = [];
8309
8309
  a ? (e.storedMarks && o.push(...e.storedMarks), o.push(...e.selection.$head.marks())) : e.doc.nodesBetween(r, i, (e) => {
8310
8310
  o.push(...e.marks);
8311
8311
  });
@@ -8751,7 +8751,7 @@ function Mu(e, t, n) {
8751
8751
  });
8752
8752
  }
8753
8753
  function Nu(e, t) {
8754
- let n = Y(t, e.schema), { from: r, to: i } = e.selection, a = [];
8754
+ let n = X(t, e.schema), { from: r, to: i } = e.selection, a = [];
8755
8755
  e.doc.nodesBetween(r, i, (e) => {
8756
8756
  a.push(e);
8757
8757
  });
@@ -8824,7 +8824,7 @@ function Ru(e, t = 0) {
8824
8824
  function zu(e, t, n) {
8825
8825
  let r = [];
8826
8826
  return e === t ? n.resolve(e).marks().forEach((t) => {
8827
- let i = Qc(n.resolve(e), t.type);
8827
+ let i = Zc(n.resolve(e), t.type);
8828
8828
  i && r.push({
8829
8829
  mark: t,
8830
8830
  ...i
@@ -8873,8 +8873,8 @@ var Wu = (e, t = 500) => {
8873
8873
  }), n;
8874
8874
  };
8875
8875
  function Gu(e, t, n = {}) {
8876
- let { empty: r, ranges: i } = e.selection, a = t ? X(t, e.schema) : null;
8877
- if (r) return !!(e.storedMarks || e.selection.$from.marks()).filter((e) => !a || a.name === e.type.name).find((e) => Yc(e.attrs, n, { strict: !1 }));
8876
+ let { empty: r, ranges: i } = e.selection, a = t ? Qc(t, e.schema) : null;
8877
+ if (r) return !!(e.storedMarks || e.selection.$from.marks()).filter((e) => !a || a.name === e.type.name).find((e) => Jc(e.attrs, n, { strict: !1 }));
8878
8878
  let o = 0, s = [];
8879
8879
  if (i.forEach(({ $from: t, $to: n }) => {
8880
8880
  let r = t.pos, i = n.pos;
@@ -8889,7 +8889,7 @@ function Gu(e, t, n = {}) {
8889
8889
  })));
8890
8890
  });
8891
8891
  }), o === 0) return !1;
8892
- let c = s.filter((e) => !a || a.name === e.mark.type.name).filter((e) => Yc(e.mark.attrs, n, { strict: !1 })).reduce((e, t) => e + t.to - t.from, 0), l = s.filter((e) => !a || e.mark.type !== a && e.mark.type.excludes(a)).reduce((e, t) => e + t.to - t.from, 0);
8892
+ let c = s.filter((e) => !a || a.name === e.mark.type.name).filter((e) => Jc(e.mark.attrs, n, { strict: !1 })).reduce((e, t) => e + t.to - t.from, 0), l = s.filter((e) => !a || e.mark.type !== a && e.mark.type.excludes(a)).reduce((e, t) => e + t.to - t.from, 0);
8893
8893
  return (c > 0 ? c + l : c) >= o;
8894
8894
  }
8895
8895
  function Ku(e, t, n = {}) {
@@ -9126,7 +9126,7 @@ function bd(e, t, n) {
9126
9126
  });
9127
9127
  }
9128
9128
  var xd = (e, t = {}) => ({ tr: n, state: r, dispatch: i }) => {
9129
- let { selection: a } = n, { empty: o, ranges: s } = a, c = X(e, r.schema);
9129
+ let { selection: a } = n, { empty: o, ranges: s } = a, c = Qc(e, r.schema);
9130
9130
  if (i) {
9131
9131
  if (o) {
9132
9132
  let e = Jl(r, c);
@@ -9149,7 +9149,7 @@ var xd = (e, t = {}) => ({ tr: n, state: r, dispatch: i }) => {
9149
9149
  }
9150
9150
  return bd(r, n, c);
9151
9151
  }, Sd = (e, t) => ({ tr: n }) => (n.setMeta(e, t), !0), Cd = (e, t = {}) => ({ state: n, dispatch: r, chain: i }) => {
9152
- let a = Y(e, n.schema), o;
9152
+ let a = X(e, n.schema), o;
9153
9153
  return n.selection.$anchor.sameParent(n.selection.$head) && (o = n.selection.$anchor.parent.attrs), a.isTextblock ? i().command(({ commands: e }) => vr(a, {
9154
9154
  ...o,
9155
9155
  ...t
@@ -9180,7 +9180,7 @@ var xd = (e, t = {}) => ({ tr: n, state: r, dispatch: i }) => {
9180
9180
  t.setSelection(l);
9181
9181
  }
9182
9182
  return !0;
9183
- }, Dd = (e) => ({ state: t, dispatch: n }) => jr(Y(e, t.schema))(t, n);
9183
+ }, Dd = (e) => ({ state: t, dispatch: n }) => jr(X(e, t.schema))(t, n);
9184
9184
  function Od(e, t) {
9185
9185
  let n = e.storedMarks || e.selection.$to.parentOffset && e.selection.$from.marks();
9186
9186
  if (n) {
@@ -9214,7 +9214,7 @@ var kd = ({ keepMarks: e = !0 } = {}) => ({ tr: t, state: n, dispatch: r, editor
9214
9214
  }
9215
9215
  return _;
9216
9216
  }, Ad = (e, t = {}) => ({ tr: n, state: r, dispatch: i, editor: a }) => {
9217
- let o = Y(e, r.schema), { $from: c, $to: l } = r.selection, u = r.selection.node;
9217
+ let o = X(e, r.schema), { $from: c, $to: l } = r.selection, u = r.selection.node;
9218
9218
  if (u && u.isBlock || c.depth < 2 || !c.sameParent(l)) return !1;
9219
9219
  let d = c.node(-1);
9220
9220
  if (d.type !== o) return !1;
@@ -9340,7 +9340,7 @@ function Hd(e) {
9340
9340
  return O.between(r, i);
9341
9341
  }
9342
9342
  var Ud = (e, t, n, r = {}) => ({ editor: i, tr: a, state: o, dispatch: c, chain: l, commands: u, can: d }) => {
9343
- let { extensions: f, splittableMarks: p } = i.extensionManager, m = Y(e, o.schema), h = Y(t, o.schema), { selection: g, storedMarks: _ } = o, { $from: ee, $to: v } = g, y = ee.blockRange(v), b = _ || g.$to.parentOffset && g.$from.marks();
9343
+ let { extensions: f, splittableMarks: p } = i.extensionManager, m = X(e, o.schema), h = X(t, o.schema), { selection: g, storedMarks: _ } = o, { $from: ee, $to: v } = g, y = ee.blockRange(v), b = _ || g.$to.parentOffset && g.$from.marks();
9344
9344
  if (!y) return !1;
9345
9345
  let x = $l((e) => Xu(e.type.name, f))(g), te = g.from === 0 && g.to === o.doc.content.size, ne = o.doc.content.content, re = ne.length === 1 ? ne[0] : null, ie = te && re && Xu(re.type.name, f) ? {
9346
9346
  node: re,
@@ -9385,16 +9385,16 @@ var Ud = (e, t, n, r = {}) => ({ editor: i, tr: a, state: o, dispatch: c, chain:
9385
9385
  return a.ensureMarks(t), e ? !0 : u.clearNodes();
9386
9386
  }).wrapInList(m, r).command(() => Bd(a, m)).command(() => Vd(a, m)).run();
9387
9387
  }, Wd = (e, t = {}, n = {}) => ({ state: r, commands: i }) => {
9388
- let { extendEmptyMarkRange: a = !1 } = n, o = X(e, r.schema);
9388
+ let { extendEmptyMarkRange: a = !1 } = n, o = Qc(e, r.schema);
9389
9389
  return Gu(r, o, t) ? i.unsetMark(o, { extendEmptyMarkRange: a }) : i.setMark(o, t);
9390
9390
  }, Gd = (e, t, n = {}) => ({ state: r, commands: i }) => {
9391
- let a = Y(e, r.schema), o = Y(t, r.schema), s = jl(r, a, n), c;
9391
+ let a = X(e, r.schema), o = X(t, r.schema), s = jl(r, a, n), c;
9392
9392
  return r.selection.$anchor.sameParent(r.selection.$head) && (c = r.selection.$anchor.parent.attrs), s ? i.setNode(o, c) : i.setNode(a, {
9393
9393
  ...c,
9394
9394
  ...n
9395
9395
  });
9396
9396
  }, Kd = (e, t = {}) => ({ state: n, commands: r }) => {
9397
- let i = Y(e, n.schema);
9397
+ let i = X(e, n.schema);
9398
9398
  return jl(n, i, t) ? r.lift(i) : r.wrapIn(i, t);
9399
9399
  }, qd = () => ({ state: e, dispatch: t }) => {
9400
9400
  let n = e.plugins;
@@ -9425,10 +9425,10 @@ var Ud = (e, t, n, r = {}) => ({ editor: i, tr: a, state: o, dispatch: c, chain:
9425
9425
  }
9426
9426
  return !0;
9427
9427
  }, Yd = (e, t = {}) => ({ tr: n, state: r, dispatch: i }) => {
9428
- let { extendEmptyMarkRange: a = !1 } = t, { selection: o } = n, s = X(e, r.schema), { $from: c, empty: l, ranges: u } = o;
9428
+ let { extendEmptyMarkRange: a = !1 } = t, { selection: o } = n, s = Qc(e, r.schema), { $from: c, empty: l, ranges: u } = o;
9429
9429
  if (!i) return !0;
9430
9430
  if (l && a) {
9431
- let { from: e, to: t } = o, r = Qc(c, s, c.marks().find((e) => e.type === s)?.attrs);
9431
+ let { from: e, to: t } = o, r = Zc(c, s, c.marks().find((e) => e.type === s)?.attrs);
9432
9432
  r && (e = r.from, t = r.to), n.removeMark(e, t, s);
9433
9433
  } else u.forEach((e) => {
9434
9434
  n.removeMark(e.$from.pos, e.$to.pos, s);
@@ -9444,7 +9444,7 @@ var Ud = (e, t, n, r = {}) => ({ editor: i, tr: a, state: o, dispatch: c, chain:
9444
9444
  }, Zd = (e, t = {}) => ({ tr: n, state: r, dispatch: i }) => {
9445
9445
  let a = null, o = null, s = Il(typeof e == "string" ? e : e.name, r.schema);
9446
9446
  if (!s) return !1;
9447
- s === "node" && (a = Y(e, r.schema)), s === "mark" && (o = X(e, r.schema));
9447
+ s === "node" && (a = X(e, r.schema)), s === "mark" && (o = Qc(e, r.schema));
9448
9448
  let c = !1;
9449
9449
  return n.selection.ranges.forEach((e) => {
9450
9450
  let s = e.$from.pos, l = e.$to.pos, u, d, f, p;
@@ -9476,19 +9476,19 @@ var Ud = (e, t, n, r = {}) => ({ editor: i, tr: a, state: o, dispatch: c, chain:
9476
9476
  }, Qd = new j("__tiptap_decorations__"), $d = (e) => ({ tr: t, dispatch: n }) => (n && t.setMeta(Qd, {
9477
9477
  type: "force",
9478
9478
  name: e
9479
- }), !0), ef = (e, t = {}) => ({ state: n, dispatch: r }) => _r(Y(e, n.schema), t)(n, r), tf = (e, t = {}) => ({ state: n, dispatch: r }) => wr(Y(e, n.schema), t)(n, r), nf = /* @__PURE__ */ t({
9480
- blur: () => Nc,
9481
- clearContent: () => Pc,
9482
- clearNodes: () => Fc,
9483
- command: () => Ic,
9484
- createParagraphNear: () => Lc,
9485
- cut: () => Rc,
9486
- deleteCurrentNode: () => zc,
9487
- deleteNode: () => Bc,
9488
- deleteRange: () => Vc,
9489
- deleteSelection: () => Gc,
9490
- enter: () => Kc,
9491
- exitCode: () => qc,
9479
+ }), !0), ef = (e, t = {}) => ({ state: n, dispatch: r }) => _r(X(e, n.schema), t)(n, r), tf = (e, t = {}) => ({ state: n, dispatch: r }) => wr(X(e, n.schema), t)(n, r), nf = /* @__PURE__ */ t({
9480
+ blur: () => Mc,
9481
+ clearContent: () => Nc,
9482
+ clearNodes: () => Pc,
9483
+ command: () => Fc,
9484
+ createParagraphNear: () => Ic,
9485
+ cut: () => Lc,
9486
+ deleteCurrentNode: () => Rc,
9487
+ deleteNode: () => zc,
9488
+ deleteRange: () => Bc,
9489
+ deleteSelection: () => Wc,
9490
+ enter: () => Gc,
9491
+ exitCode: () => Kc,
9492
9492
  extendMarkRange: () => $c,
9493
9493
  first: () => el,
9494
9494
  focus: () => sl,
@@ -9591,7 +9591,7 @@ function uf(e, t) {
9591
9591
  function df(e, t, n) {
9592
9592
  let { decorations: r, widgetKeys: i } = uf(t, n);
9593
9593
  return {
9594
- set: G.create(e, r),
9594
+ set: K.create(e, r),
9595
9595
  widgetKeys: i
9596
9596
  };
9597
9597
  }
@@ -9679,7 +9679,7 @@ function bf(e, t, n, r) {
9679
9679
  } });
9680
9680
  }
9681
9681
  function xf(e, t, n) {
9682
- let r = t.decorationSetsByExtension[e] ?? G.empty, i = new Set(t.widgetKeysByExtension[e] ?? []);
9682
+ let r = t.decorationSetsByExtension[e] ?? K.empty, i = new Set(t.widgetKeysByExtension[e] ?? []);
9683
9683
  return {
9684
9684
  set: bf(r, n.mapping, n.doc, i),
9685
9685
  widgetKeys: i
@@ -9687,7 +9687,7 @@ function xf(e, t, n) {
9687
9687
  }
9688
9688
  function Sf(e, t) {
9689
9689
  let n = Object.values(t).flatMap((e) => e.find());
9690
- return G.create(e, n);
9690
+ return K.create(e, n);
9691
9691
  }
9692
9692
  function Cf(e) {
9693
9693
  let t = /* @__PURE__ */ new Set();
@@ -9799,7 +9799,7 @@ var Of = class {
9799
9799
  }
9800
9800
  },
9801
9801
  props: { decorations(e) {
9802
- return Qd.getState(e)?.mergedDecorationSet ?? G.empty;
9802
+ return Qd.getState(e)?.mergedDecorationSet ?? K.empty;
9803
9803
  } }
9804
9804
  });
9805
9805
  }
@@ -9808,7 +9808,7 @@ var Of = class {
9808
9808
  return a.type === "full" ? this.buildFullSet(e, t, i) : this.rebuildRanges(e, t, n, r, i, a.ranges);
9809
9809
  }
9810
9810
  rebuildRanges(e, t, n, r, i, a) {
9811
- let o = n.decorationSetsByExtension[e] ?? G.empty, s = new Set(n.widgetKeysByExtension[e] ?? []), c = bf(o, r.mapping, r.doc, s), l = i.doc.content.size;
9811
+ let o = n.decorationSetsByExtension[e] ?? K.empty, s = new Set(n.widgetKeysByExtension[e] ?? []), c = bf(o, r.mapping, r.doc, s), l = i.doc.content.size;
9812
9812
  for (let { from: n, to: r } of a) {
9813
9813
  let a = c.find(n, r).filter((e) => ff({
9814
9814
  position: e.from,
@@ -10410,7 +10410,7 @@ var Cp = class {
10410
10410
  this.find = e.find, this.handler = e.handler, this.undoable = e.undoable ?? !0;
10411
10411
  }
10412
10412
  }, Tp = (e, t) => {
10413
- if (Jc(t)) return t.exec(e);
10413
+ if (qc(t)) return t.exec(e);
10414
10414
  let n = t(e);
10415
10415
  if (!n) return null;
10416
10416
  let r = [n.text];
@@ -10439,13 +10439,13 @@ function Dp(e) {
10439
10439
  to: r,
10440
10440
  text: i,
10441
10441
  insertText: c
10442
- }), f = u ? n + i.length : r, p = jc({
10442
+ }), f = u ? n + i.length : r, p = Ac({
10443
10443
  state: l.state,
10444
10444
  transaction: d
10445
10445
  }), m = {
10446
10446
  from: n - (o[0].length - i.length),
10447
10447
  to: f
10448
- }, { commands: h, chain: g, can: _ } = new Mc({
10448
+ }, { commands: h, chain: g, can: _ } = new jc({
10449
10449
  editor: t,
10450
10450
  state: p
10451
10451
  });
@@ -10456,7 +10456,7 @@ function Dp(e) {
10456
10456
  commands: h,
10457
10457
  chain: g,
10458
10458
  can: _
10459
- }) === null || !d.steps.length ? !1 : (u && (l.dispatch(u), !l.state.doc.eq(u.doc)) || (Cc(d), d.setMeta("inputRule", !0), a.undoable && d.setMeta(s, {
10459
+ }) === null || !d.steps.length ? !1 : (u && (l.dispatch(u), !l.state.doc.eq(u.doc)) || (Sc(d), d.setMeta("inputRule", !0), a.undoable && d.setMeta(s, {
10460
10460
  transform: d,
10461
10461
  from: n,
10462
10462
  to: f,
@@ -10499,6 +10499,14 @@ function Ap(e) {
10499
10499
  apply(e, i, a) {
10500
10500
  let o = e.getMeta(r);
10501
10501
  if (o) return o;
10502
+ if (i && e.getMeta("appendedTransaction")?.getMeta(r)) {
10503
+ let t = new vn(i.transform.before);
10504
+ for (let n of [...i.transform.steps, ...e.steps]) t.step(n);
10505
+ return {
10506
+ ...i,
10507
+ transform: t
10508
+ };
10509
+ }
10502
10510
  let c = e.getMeta("applyInputRules");
10503
10511
  return c && setTimeout(() => {
10504
10512
  let { text: e } = c;
@@ -10615,7 +10623,7 @@ var jp = class {
10615
10623
  this.find = e.find, this.handler = e.handler;
10616
10624
  }
10617
10625
  }, Pp = (e, t, n) => {
10618
- if (Jc(t)) return [...e.matchAll(t)];
10626
+ if (qc(t)) return [...e.matchAll(t)];
10619
10627
  let r = t(e, n);
10620
10628
  return r ? r.map((t) => {
10621
10629
  let n = [t.text];
@@ -10623,7 +10631,7 @@ var jp = class {
10623
10631
  }) : [];
10624
10632
  };
10625
10633
  function Fp(e) {
10626
- let { editor: t, state: n, from: r, to: i, rule: a, pasteEvent: o, dropEvent: s } = e, { commands: c, chain: l, can: u } = new Mc({
10634
+ let { editor: t, state: n, from: r, to: i, rule: a, pasteEvent: o, dropEvent: s } = e, { commands: c, chain: l, can: u } = new jc({
10627
10635
  editor: t,
10628
10636
  state: n
10629
10637
  }), d = [];
@@ -10663,7 +10671,7 @@ function Rp(e) {
10663
10671
  c = null;
10664
10672
  }
10665
10673
  let l = ({ state: e, from: n, to: r, rule: i, pasteEvt: a }) => {
10666
- let s = e.tr, l = jc({
10674
+ let s = e.tr, l = Ac({
10667
10675
  state: e,
10668
10676
  transaction: s
10669
10677
  });
@@ -10781,7 +10789,7 @@ var zp = class {
10781
10789
  ...t
10782
10790
  };
10783
10791
  }
10784
- let o = ic(a);
10792
+ let o = rc(a);
10785
10793
  r.push(o);
10786
10794
  let s = Z(t, "addInputRules", n);
10787
10795
  if (Yu(t, e.options.enableInputRules) && s) {
@@ -10848,7 +10856,7 @@ var zp = class {
10848
10856
  options: t.options,
10849
10857
  storage: this.editor.extensionStorage[t.name],
10850
10858
  editor: e,
10851
- type: Y(t.name, this.schema)
10859
+ type: X(t.name, this.schema)
10852
10860
  });
10853
10861
  if (!r) return [];
10854
10862
  let i = r();
@@ -10909,7 +10917,7 @@ var zp = class {
10909
10917
  options: t.options,
10910
10918
  storage: this.editor.extensionStorage[t.name],
10911
10919
  editor: e,
10912
- type: X(t.name, this.schema)
10920
+ type: Qc(t.name, this.schema)
10913
10921
  });
10914
10922
  return r ? [t.name, (i, a, o) => {
10915
10923
  let s = _u(i, n);
@@ -11147,10 +11155,10 @@ var Jp = $.create({
11147
11155
  if (e.some((e) => e.getMeta("composition"))) return;
11148
11156
  let r = e.some((e) => e.docChanged) && !t.doc.eq(n.doc), i = e.some((e) => e.getMeta("preventClearDocument"));
11149
11157
  if (!r || i || !qp(t) || !Zu(n.doc)) return;
11150
- let a = n.tr, o = jc({
11158
+ let a = n.tr, o = Ac({
11151
11159
  state: n,
11152
11160
  transaction: a
11153
- }), { commands: s } = new Mc({
11161
+ }), { commands: s } = new jc({
11154
11162
  editor: this.editor,
11155
11163
  state: o
11156
11164
  });
@@ -11440,10 +11448,10 @@ var tm = class e {
11440
11448
  return this.commandManager.commands;
11441
11449
  }
11442
11450
  chain() {
11443
- return this.commandManager ? this.commandManager.chain() : Mc.createFakeChain();
11451
+ return this.commandManager ? this.commandManager.chain() : jc.createFakeChain();
11444
11452
  }
11445
11453
  can() {
11446
- return this.commandManager ? this.commandManager.can() : Mc.createFallbackCan();
11454
+ return this.commandManager ? this.commandManager.can() : jc.createFallbackCan();
11447
11455
  }
11448
11456
  injectCSS() {
11449
11457
  this.options.injectCSS && typeof document < "u" && (this.css = jf(nm, this.options.injectNonce));
@@ -11525,7 +11533,7 @@ var tm = class e {
11525
11533
  this.extensionManager = new zp(n, this);
11526
11534
  }
11527
11535
  createCommandManager() {
11528
- this.commandManager = new Mc({ editor: this });
11536
+ this.commandManager = new jc({ editor: this });
11529
11537
  }
11530
11538
  createSchema() {
11531
11539
  this.schema = this.extensionManager.schema;
@@ -11563,7 +11571,7 @@ var tm = class e {
11563
11571
  }
11564
11572
  createView(e) {
11565
11573
  let { editorProps: t, enableExtensionDispatchTransaction: n } = this.options, r = t.dispatchTransaction || this.dispatchTransaction.bind(this), i = n ? this.extensionManager.dispatchTransaction(r) : r, a = t.transformPastedHTML, o = this.extensionManager.transformPastedHTML(a);
11566
- this.editorView = new zs(e, {
11574
+ this.editorView = new Rs(e, {
11567
11575
  ...t,
11568
11576
  attributes: this.getEditorViewAttributes(),
11569
11577
  dispatchTransaction: i,
@@ -11698,7 +11706,7 @@ var tm = class e {
11698
11706
  ...this.spec,
11699
11707
  extensionName: e
11700
11708
  } : this.spec;
11701
- return rs.inline(this.from, this.to, this.attrs, t);
11709
+ return ns.inline(this.from, this.to, this.attrs, t);
11702
11710
  }
11703
11711
  }, om = class extends im {
11704
11712
  constructor(e, t, n = {}, r) {
@@ -11712,7 +11720,7 @@ var tm = class e {
11712
11720
  ...this.spec,
11713
11721
  extensionName: e
11714
11722
  } : this.spec;
11715
- return rs.node(this.from, this.to, this.attrs, t);
11723
+ return ns.node(this.from, this.to, this.attrs, t);
11716
11724
  }
11717
11725
  }, sm = class extends im {
11718
11726
  constructor(e, t, n, r) {
@@ -11730,7 +11738,7 @@ var tm = class e {
11730
11738
  ...this.spec,
11731
11739
  key: this.key
11732
11740
  };
11733
- return rs.widget(this.pos, this.render, t);
11741
+ return ns.widget(this.pos, this.render, t);
11734
11742
  }
11735
11743
  };
11736
11744
  function cm(e, t) {
@@ -12216,4 +12224,4 @@ var Mm = class {
12216
12224
  };
12217
12225
  }
12218
12226
  };
12219
- export { Mu as $, D as $n, cd as $t, jc as A, rl as An, il as At, dl as B, hm as Bn, jl as Bt, kf as C, ip as Cn, Wu as Ct, nf as D, Fu as Dn, yu as Dt, Yl as E, _d as En, Cm as Et, jf as F, uu as Fn, zf as Ft, Zl as G, ac as Gn, Hf as Gt, Mf as H, Ac as Hn, Qu as Ht, um as I, mm as In, fu as It, Ql as J, Wn as Jn, rd as Jt, lu as K, rs as Kn, td as Kt, Ff as L, jm as Ln, Xu as Lt, up as M, hl as Mn, Ju as Mt, gd as N, ap as Nn, pu as Nt, op as O, _p as On, Ap as Ot, pl as P, wu as Pn, Yu as Pt, Ou as Q, j as Qn, sd as Qt, _l as R, pm as Rn, Ol as Rt, sm as S, Yc as Sn, ku as St, Af as T, Rp as Tn, hd as Tt, Qp as U, kc as Un, $u as Ut, Rf as V, Ec as Vn, Zu as Vt, Xl as W, Oc as Wn, Bf as Wt, vu as X, k as Xn, ad as Xt, eu as Y, Gn as Yn, id as Yt, Du as Z, A as Zn, od as Zt, Om as _, gu as _n, Hu as _t, rm as a, pd as an, tu as at, Em as b, fm as bn, Nf as bt, xm as c, Uf as cn, X as ct, md as d, al as dn, Nu as dt, ld as en, O as er, Pu as et, Mp as f, Df as fn, Y as ft, tm as g, bp as gn, Cu as gt, om as h, vp as hn, Eu as ht, Of as i, ed as in, p as ir, Z as it, Kl as j, yd as jn, qu as jt, sp as k, Tu as kn, Ku as kt, am as l, tl as ln, zu as lt, Dm as m, km as mn, _u as mt, Qd as n, dd as nn, Zt as nr, Lu as nt, jp as o, Jc as on, Jl as ot, Cp as p, dm as pn, Vu as pt, $l as q, G as qn, nd as qt, im as r, fd as rn, s as rr, Ru as rt, $ as s, ol as sn, Qc as st, Mc as t, ud as tn, T as tr, du as tt, wp as u, Wf as un, Bu as ut, Np as v, xp as vn, Il as vt, Q as w, mp as wn, ju as wt, Mm as x, Am as xn, Au as xt, Tm as y, nl as yn, Uu as yt, Ll as z, Sp as zn, Gu as zt };
12227
+ export { Mu as $, D as $n, cd as $t, Ac as A, rl as An, il as At, dl as B, hm as Bn, jl as Bt, kf as C, ip as Cn, Wu as Ct, nf as D, Fu as Dn, yu as Dt, Yl as E, _d as En, Cm as Et, jf as F, uu as Fn, zf as Ft, Zl as G, ic as Gn, Hf as Gt, Mf as H, kc as Hn, Qu as Ht, um as I, mm as In, fu as It, Ql as J, Wn as Jn, rd as Jt, lu as K, ns as Kn, td as Kt, Ff as L, jm as Ln, Xu as Lt, up as M, hl as Mn, Ju as Mt, gd as N, ap as Nn, pu as Nt, op as O, _p as On, Ap as Ot, pl as P, wu as Pn, Yu as Pt, Ou as Q, j as Qn, sd as Qt, _l as R, pm as Rn, Ol as Rt, sm as S, Jc as Sn, ku as St, Af as T, Rp as Tn, hd as Tt, Qp as U, Oc as Un, $u as Ut, Rf as V, Tc as Vn, Zu as Vt, Xl as W, Dc as Wn, Bf as Wt, vu as X, k as Xn, ad as Xt, eu as Y, Gn as Yn, id as Yt, Du as Z, A as Zn, od as Zt, Om as _, gu as _n, Hu as _t, rm as a, pd as an, tu as at, Em as b, fm as bn, Nf as bt, xm as c, Uf as cn, Qc as ct, md as d, al as dn, Nu as dt, ld as en, O as er, Pu as et, Mp as f, Df as fn, X as ft, tm as g, bp as gn, Cu as gt, om as h, vp as hn, Eu as ht, Of as i, ed as in, p as ir, Z as it, Kl as j, yd as jn, qu as jt, sp as k, Tu as kn, Ku as kt, am as l, tl as ln, zu as lt, Dm as m, km as mn, _u as mt, Qd as n, dd as nn, Zt as nr, Lu as nt, jp as o, qc as on, Jl as ot, Cp as p, dm as pn, Vu as pt, $l as q, K as qn, nd as qt, im as r, fd as rn, s as rr, Ru as rt, $ as s, ol as sn, Zc as st, jc as t, ud as tn, T as tr, du as tt, wp as u, Wf as un, Bu as ut, Np as v, xp as vn, Il as vt, Q as w, mp as wn, ju as wt, Mm as x, Am as xn, Au as xt, Tm as y, nl as yn, Uu as yt, Ll as z, Sp as zn, Gu as zt };