@notectl/core 1.7.3 → 2.0.1
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.
- package/LICENSE +21 -0
- package/README.md +56 -31
- package/custom-elements.json +350 -6
- package/dist/chunks/AttrRegistry-Ckj9eCHj.mjs +2 -0
- package/dist/chunks/AttrRegistry-Ckj9eCHj.mjs.map +1 -0
- package/dist/chunks/AttributedMarkCommands-x7h4Xy7V.mjs +2 -0
- package/dist/chunks/AttributedMarkCommands-x7h4Xy7V.mjs.map +1 -0
- package/dist/chunks/BlockInsertion-zPxm6oa_.mjs +2 -0
- package/dist/chunks/BlockInsertion-zPxm6oa_.mjs.map +1 -0
- package/dist/chunks/BlockTypePickerRegistry-DcSE6IXB.mjs +2 -0
- package/dist/chunks/BlockTypePickerRegistry-DcSE6IXB.mjs.map +1 -0
- package/dist/chunks/ColorGrid-CpkbKfXg.mjs +2 -0
- package/dist/chunks/ColorGrid-CpkbKfXg.mjs.map +1 -0
- package/dist/chunks/ColorPickerPopup-CDUvkgcK.mjs +2 -0
- package/dist/chunks/ColorPickerPopup-CDUvkgcK.mjs.map +1 -0
- package/dist/chunks/ColorValidation-DCSKq9B2.mjs +2 -0
- package/dist/chunks/{ColorValidation-CV4f1wu6.mjs.map → ColorValidation-DCSKq9B2.mjs.map} +1 -1
- package/dist/chunks/Commands-DwXBBVGR.mjs +2 -0
- package/dist/chunks/Commands-DwXBBVGR.mjs.map +1 -0
- package/dist/chunks/Decoration-D49mFXrH.mjs +2 -0
- package/dist/chunks/Decoration-D49mFXrH.mjs.map +1 -0
- package/dist/chunks/Document-HC8s50qJ.mjs +2 -0
- package/dist/chunks/Document-HC8s50qJ.mjs.map +1 -0
- package/dist/chunks/DocumentParser-w70-Axud.mjs +2 -0
- package/dist/chunks/DocumentParser-w70-Axud.mjs.map +1 -0
- package/dist/chunks/DomUtils-CznMAZZg.mjs +2 -0
- package/dist/chunks/DomUtils-CznMAZZg.mjs.map +1 -0
- package/dist/chunks/HTMLUtils-Cxy99Ak2.mjs +2 -0
- package/dist/chunks/HTMLUtils-Cxy99Ak2.mjs.map +1 -0
- package/dist/chunks/HeadingPlugin-B-LF-AMM.mjs +2 -0
- package/dist/chunks/HeadingPlugin-B-LF-AMM.mjs.map +1 -0
- package/dist/chunks/KeyboardNav-DsYhKKuV.mjs +2 -0
- package/dist/chunks/KeyboardNav-DsYhKKuV.mjs.map +1 -0
- package/dist/chunks/MarkCommands-CTuVDqnn.mjs +2 -0
- package/dist/chunks/MarkCommands-CTuVDqnn.mjs.map +1 -0
- package/dist/chunks/NavigationQueries-DCOv4Ca5.mjs +2 -0
- package/dist/chunks/NavigationQueries-DCOv4Ca5.mjs.map +1 -0
- package/dist/chunks/NotectlEditor-DBBJkPCW.mjs +3 -0
- package/dist/chunks/NotectlEditor-DBBJkPCW.mjs.map +1 -0
- package/dist/chunks/Platform-CU6itXZo.mjs +2 -0
- package/dist/chunks/Platform-CU6itXZo.mjs.map +1 -0
- package/dist/chunks/PluginHelpers-CdPR0MuT.mjs +2 -0
- package/dist/chunks/PluginHelpers-CdPR0MuT.mjs.map +1 -0
- package/dist/chunks/PopupManager-Du3dYnsJ.mjs +2 -0
- package/dist/chunks/PopupManager-Du3dYnsJ.mjs.map +1 -0
- package/dist/chunks/PopupPositioning-DtvqMSop.mjs +2 -0
- package/dist/chunks/PopupPositioning-DtvqMSop.mjs.map +1 -0
- package/dist/chunks/PrintTypes-DukwDSWS.mjs +2 -0
- package/dist/chunks/PrintTypes-DukwDSWS.mjs.map +1 -0
- package/dist/chunks/RangeIterator-CprUbOWv.mjs +2 -0
- package/dist/chunks/{RangeIterator-Bh4Vl_6D.mjs.map → RangeIterator-CprUbOWv.mjs.map} +1 -1
- package/dist/chunks/Selection-DhbizDM4.mjs +2 -0
- package/dist/chunks/{Selection-BRTab5hO.mjs.map → Selection-DhbizDM4.mjs.map} +1 -1
- package/dist/chunks/SelectionTransactions-DB3YDIEa.mjs +2 -0
- package/dist/chunks/SelectionTransactions-DB3YDIEa.mjs.map +1 -0
- package/dist/chunks/ShortcutFormatting-BLKS0Gys.mjs +2 -0
- package/dist/chunks/ShortcutFormatting-BLKS0Gys.mjs.map +1 -0
- package/dist/chunks/StyleRuntime-BmsLoEa8.mjs +2 -0
- package/dist/chunks/{StyleRuntime-CP4NCwKT.mjs.map → StyleRuntime-BmsLoEa8.mjs.map} +1 -1
- package/dist/chunks/TextDirectionLocale-BraFI9JF.mjs +2 -0
- package/dist/chunks/TextDirectionLocale-BraFI9JF.mjs.map +1 -0
- package/dist/chunks/TypeBrands-Bp_Z_o5Y.mjs +2 -0
- package/dist/chunks/{TypeBrands-C09nE2qO.mjs.map → TypeBrands-Bp_Z_o5Y.mjs.map} +1 -1
- package/dist/chunks/XmlPatterns-DxQXGjP8.mjs +2 -0
- package/dist/chunks/XmlPatterns-DxQXGjP8.mjs.map +1 -0
- package/dist/chunks/ar-B93SPJT7.mjs +2 -0
- package/dist/chunks/ar-B93SPJT7.mjs.map +1 -0
- package/dist/chunks/ar-BAmGa08u.mjs +2 -0
- package/dist/chunks/ar-BAmGa08u.mjs.map +1 -0
- package/dist/chunks/ar-BYNFEVLc.mjs +2 -0
- package/dist/chunks/ar-BYNFEVLc.mjs.map +1 -0
- package/dist/chunks/ar-Bnc7y8BP.mjs +2 -0
- package/dist/chunks/ar-Bnc7y8BP.mjs.map +1 -0
- package/dist/chunks/ar-Bp3rDZky.mjs +2 -0
- package/dist/chunks/ar-Bp3rDZky.mjs.map +1 -0
- package/dist/chunks/ar-BtOQ7lro.mjs +2 -0
- package/dist/chunks/ar-BtOQ7lro.mjs.map +1 -0
- package/dist/chunks/ar-C5JEHhw9.mjs +2 -0
- package/dist/chunks/ar-C5JEHhw9.mjs.map +1 -0
- package/dist/chunks/ar-CL3QL0tw.mjs +2 -0
- package/dist/chunks/ar-CL3QL0tw.mjs.map +1 -0
- package/dist/chunks/ar-CYtG-XlN.mjs +2 -0
- package/dist/chunks/ar-CYtG-XlN.mjs.map +1 -0
- package/dist/chunks/ar-CzVj8p__.mjs +2 -0
- package/dist/chunks/ar-CzVj8p__.mjs.map +1 -0
- package/dist/chunks/ar-D7PS3e2g.mjs +2 -0
- package/dist/chunks/ar-D7PS3e2g.mjs.map +1 -0
- package/dist/chunks/ar-D8adM2Uy.mjs +2 -0
- package/dist/chunks/ar-D8adM2Uy.mjs.map +1 -0
- package/dist/chunks/ar-D9jyShaB.mjs +2 -0
- package/dist/chunks/ar-D9jyShaB.mjs.map +1 -0
- package/dist/chunks/ar-DR6OA3ZO.mjs +2 -0
- package/dist/chunks/ar-DR6OA3ZO.mjs.map +1 -0
- package/dist/chunks/ar-Deibepjm.mjs +2 -0
- package/dist/chunks/ar-Deibepjm.mjs.map +1 -0
- package/dist/chunks/ar-Dlb5riUN.mjs +2 -0
- package/dist/chunks/ar-Dlb5riUN.mjs.map +1 -0
- package/dist/chunks/ar-DmmxE2W7.mjs +2 -0
- package/dist/chunks/ar-DmmxE2W7.mjs.map +1 -0
- package/dist/chunks/ar-Ds6Z2Gzf.mjs +2 -0
- package/dist/chunks/ar-Ds6Z2Gzf.mjs.map +1 -0
- package/dist/chunks/ar-DtIHQ8nU.mjs +2 -0
- package/dist/chunks/ar-DtIHQ8nU.mjs.map +1 -0
- package/dist/chunks/ar-J8B-on-0.mjs +2 -0
- package/dist/chunks/ar-J8B-on-0.mjs.map +1 -0
- package/dist/chunks/ar-b6VdnxAs.mjs +2 -0
- package/dist/chunks/ar-b6VdnxAs.mjs.map +1 -0
- package/dist/chunks/ar-iU02mRe5.mjs +2 -0
- package/dist/chunks/ar-iU02mRe5.mjs.map +1 -0
- package/dist/chunks/ar-mSCYQYnL.mjs +2 -0
- package/dist/chunks/ar-mSCYQYnL.mjs.map +1 -0
- package/dist/chunks/color-picker-Byjl_xr9.mjs +2 -0
- package/dist/chunks/color-picker-Byjl_xr9.mjs.map +1 -0
- package/dist/chunks/de-8aCC5jBM.mjs +2 -0
- package/dist/chunks/de-8aCC5jBM.mjs.map +1 -0
- package/dist/chunks/de-B4y4ndUw.mjs +2 -0
- package/dist/chunks/de-B4y4ndUw.mjs.map +1 -0
- package/dist/chunks/de-B5fcZ0FQ.mjs +2 -0
- package/dist/chunks/de-B5fcZ0FQ.mjs.map +1 -0
- package/dist/chunks/de-BT9VmwoJ.mjs +2 -0
- package/dist/chunks/de-BT9VmwoJ.mjs.map +1 -0
- package/dist/chunks/de-BZWSyJTG.mjs +2 -0
- package/dist/chunks/de-BZWSyJTG.mjs.map +1 -0
- package/dist/chunks/de-CFD_Wgik.mjs +2 -0
- package/dist/chunks/de-CFD_Wgik.mjs.map +1 -0
- package/dist/chunks/de-CLYtb6kD.mjs +2 -0
- package/dist/chunks/de-CLYtb6kD.mjs.map +1 -0
- package/dist/chunks/de-CP5v-98M.mjs +2 -0
- package/dist/chunks/de-CP5v-98M.mjs.map +1 -0
- package/dist/chunks/de-CYJ6uWno.mjs +2 -0
- package/dist/chunks/de-CYJ6uWno.mjs.map +1 -0
- package/dist/chunks/de-ChcKkF7A.mjs +2 -0
- package/dist/chunks/de-ChcKkF7A.mjs.map +1 -0
- package/dist/chunks/de-CicoU066.mjs +2 -0
- package/dist/chunks/de-CicoU066.mjs.map +1 -0
- package/dist/chunks/de-CjLAdBt2.mjs +2 -0
- package/dist/chunks/de-CjLAdBt2.mjs.map +1 -0
- package/dist/chunks/de-CtFvAXwF.mjs +2 -0
- package/dist/chunks/de-CtFvAXwF.mjs.map +1 -0
- package/dist/chunks/de-D1OAXtxJ.mjs +2 -0
- package/dist/chunks/de-D1OAXtxJ.mjs.map +1 -0
- package/dist/chunks/de-DBbzCQrm.mjs +2 -0
- package/dist/chunks/de-DBbzCQrm.mjs.map +1 -0
- package/dist/chunks/de-DOLwx_M7.mjs +2 -0
- package/dist/chunks/de-DOLwx_M7.mjs.map +1 -0
- package/dist/chunks/de-De2miMxo.mjs +2 -0
- package/dist/chunks/de-De2miMxo.mjs.map +1 -0
- package/dist/chunks/de-OTfhhinm.mjs +2 -0
- package/dist/chunks/de-OTfhhinm.mjs.map +1 -0
- package/dist/chunks/de-PZ9-LlBp.mjs +2 -0
- package/dist/chunks/de-PZ9-LlBp.mjs.map +1 -0
- package/dist/chunks/de-UREymH-5.mjs +2 -0
- package/dist/chunks/de-UREymH-5.mjs.map +1 -0
- package/dist/chunks/de-chYdoK9q.mjs +2 -0
- package/dist/chunks/de-chYdoK9q.mjs.map +1 -0
- package/dist/chunks/de-fXvs5vQT.mjs +2 -0
- package/dist/chunks/de-fXvs5vQT.mjs.map +1 -0
- package/dist/chunks/de-xJh5C_pk.mjs +2 -0
- package/dist/chunks/de-xJh5C_pk.mjs.map +1 -0
- package/dist/chunks/es-B9UhsaEI.mjs +2 -0
- package/dist/chunks/es-B9UhsaEI.mjs.map +1 -0
- package/dist/chunks/es-BHGwPgrP.mjs +2 -0
- package/dist/chunks/es-BHGwPgrP.mjs.map +1 -0
- package/dist/chunks/es-BTqy_aQ4.mjs +2 -0
- package/dist/chunks/es-BTqy_aQ4.mjs.map +1 -0
- package/dist/chunks/es-BbGOZGS_.mjs +2 -0
- package/dist/chunks/es-BbGOZGS_.mjs.map +1 -0
- package/dist/chunks/es-BjPsub0k.mjs +2 -0
- package/dist/chunks/es-BjPsub0k.mjs.map +1 -0
- package/dist/chunks/es-Bk0bRDFE.mjs +2 -0
- package/dist/chunks/es-Bk0bRDFE.mjs.map +1 -0
- package/dist/chunks/es-BkS6DsrM.mjs +2 -0
- package/dist/chunks/es-BkS6DsrM.mjs.map +1 -0
- package/dist/chunks/es-BzEpr4Bk.mjs +2 -0
- package/dist/chunks/es-BzEpr4Bk.mjs.map +1 -0
- package/dist/chunks/es-C2lnWyA0.mjs +2 -0
- package/dist/chunks/es-C2lnWyA0.mjs.map +1 -0
- package/dist/chunks/es-C7e35Muh.mjs +2 -0
- package/dist/chunks/es-C7e35Muh.mjs.map +1 -0
- package/dist/chunks/es-CBk43isB.mjs +2 -0
- package/dist/chunks/es-CBk43isB.mjs.map +1 -0
- package/dist/chunks/es-CE8t9fuM.mjs +2 -0
- package/dist/chunks/es-CE8t9fuM.mjs.map +1 -0
- package/dist/chunks/es-CFjzqIbS.mjs +2 -0
- package/dist/chunks/es-CFjzqIbS.mjs.map +1 -0
- package/dist/chunks/es-Ce-AEYxc.mjs +2 -0
- package/dist/chunks/es-Ce-AEYxc.mjs.map +1 -0
- package/dist/chunks/es-Co4AJr8Y.mjs +2 -0
- package/dist/chunks/es-Co4AJr8Y.mjs.map +1 -0
- package/dist/chunks/es-Cu5_OA4X.mjs +2 -0
- package/dist/chunks/es-Cu5_OA4X.mjs.map +1 -0
- package/dist/chunks/es-Cud6JXHf.mjs +2 -0
- package/dist/chunks/es-Cud6JXHf.mjs.map +1 -0
- package/dist/chunks/es-D-II7LZC.mjs +2 -0
- package/dist/chunks/es-D-II7LZC.mjs.map +1 -0
- package/dist/chunks/es-DBBSeOaD.mjs +2 -0
- package/dist/chunks/es-DBBSeOaD.mjs.map +1 -0
- package/dist/chunks/es-DCwjeUUu.mjs +2 -0
- package/dist/chunks/es-DCwjeUUu.mjs.map +1 -0
- package/dist/chunks/es-DvgH3-WZ.mjs +2 -0
- package/dist/chunks/es-DvgH3-WZ.mjs.map +1 -0
- package/dist/chunks/es-MgguVgIs.mjs +2 -0
- package/dist/chunks/es-MgguVgIs.mjs.map +1 -0
- package/dist/chunks/es-yXjjcxgb.mjs +2 -0
- package/dist/chunks/es-yXjjcxgb.mjs.map +1 -0
- package/dist/chunks/fr-B-_yKIAY.mjs +2 -0
- package/dist/chunks/fr-B-_yKIAY.mjs.map +1 -0
- package/dist/chunks/fr-BGyF2ym0.mjs +2 -0
- package/dist/chunks/fr-BGyF2ym0.mjs.map +1 -0
- package/dist/chunks/fr-BoRJ3B2-.mjs +2 -0
- package/dist/chunks/fr-BoRJ3B2-.mjs.map +1 -0
- package/dist/chunks/fr-BrKk4SPg.mjs +2 -0
- package/dist/chunks/fr-BrKk4SPg.mjs.map +1 -0
- package/dist/chunks/fr-C-y09LKg.mjs +2 -0
- package/dist/chunks/fr-C-y09LKg.mjs.map +1 -0
- package/dist/chunks/fr-C1W7jyd6.mjs +2 -0
- package/dist/chunks/fr-C1W7jyd6.mjs.map +1 -0
- package/dist/chunks/fr-C8CtmWBj.mjs +2 -0
- package/dist/chunks/fr-C8CtmWBj.mjs.map +1 -0
- package/dist/chunks/fr-C9oiPW0k.mjs +2 -0
- package/dist/chunks/fr-C9oiPW0k.mjs.map +1 -0
- package/dist/chunks/fr-CEkk4UyZ.mjs +2 -0
- package/dist/chunks/fr-CEkk4UyZ.mjs.map +1 -0
- package/dist/chunks/fr-Ccaetiwi.mjs +2 -0
- package/dist/chunks/fr-Ccaetiwi.mjs.map +1 -0
- package/dist/chunks/fr-Ccku5KzA.mjs +2 -0
- package/dist/chunks/fr-Ccku5KzA.mjs.map +1 -0
- package/dist/chunks/fr-CfUg1FxU.mjs +2 -0
- package/dist/chunks/fr-CfUg1FxU.mjs.map +1 -0
- package/dist/chunks/fr-DDkBcjmO.mjs +2 -0
- package/dist/chunks/fr-DDkBcjmO.mjs.map +1 -0
- package/dist/chunks/fr-DNwLChcm.mjs +2 -0
- package/dist/chunks/fr-DNwLChcm.mjs.map +1 -0
- package/dist/chunks/fr-DvneSjCf.mjs +2 -0
- package/dist/chunks/fr-DvneSjCf.mjs.map +1 -0
- package/dist/chunks/fr-Dx4Qqimj.mjs +2 -0
- package/dist/chunks/fr-Dx4Qqimj.mjs.map +1 -0
- package/dist/chunks/fr-RHXmueoO.mjs +2 -0
- package/dist/chunks/fr-RHXmueoO.mjs.map +1 -0
- package/dist/chunks/fr-VdiCNF4J.mjs +2 -0
- package/dist/chunks/fr-VdiCNF4J.mjs.map +1 -0
- package/dist/chunks/fr-Wiobfk5s.mjs +2 -0
- package/dist/chunks/fr-Wiobfk5s.mjs.map +1 -0
- package/dist/chunks/fr-YMiDtWuG.mjs +2 -0
- package/dist/chunks/fr-YMiDtWuG.mjs.map +1 -0
- package/dist/chunks/fr-_Oxf0k66.mjs +2 -0
- package/dist/chunks/fr-_Oxf0k66.mjs.map +1 -0
- package/dist/chunks/fr-gurfH-7T.mjs +2 -0
- package/dist/chunks/fr-gurfH-7T.mjs.map +1 -0
- package/dist/chunks/fr-zP7EjxDL.mjs +2 -0
- package/dist/chunks/fr-zP7EjxDL.mjs.map +1 -0
- package/dist/chunks/hi-B2W8pFqK.mjs +2 -0
- package/dist/chunks/hi-B2W8pFqK.mjs.map +1 -0
- package/dist/chunks/hi-B2m69ZCq.mjs +2 -0
- package/dist/chunks/hi-B2m69ZCq.mjs.map +1 -0
- package/dist/chunks/hi-BMIt3y_-.mjs +2 -0
- package/dist/chunks/hi-BMIt3y_-.mjs.map +1 -0
- package/dist/chunks/hi-BdtVhAzs.mjs +2 -0
- package/dist/chunks/hi-BdtVhAzs.mjs.map +1 -0
- package/dist/chunks/hi-BmkfaZpg.mjs +2 -0
- package/dist/chunks/hi-BmkfaZpg.mjs.map +1 -0
- package/dist/chunks/hi-C-l_R2SO.mjs +2 -0
- package/dist/chunks/hi-C-l_R2SO.mjs.map +1 -0
- package/dist/chunks/hi-C1LhM-oY.mjs +2 -0
- package/dist/chunks/hi-C1LhM-oY.mjs.map +1 -0
- package/dist/chunks/hi-CGEbGI1l.mjs +2 -0
- package/dist/chunks/hi-CGEbGI1l.mjs.map +1 -0
- package/dist/chunks/hi-CPuhj7IA.mjs +2 -0
- package/dist/chunks/hi-CPuhj7IA.mjs.map +1 -0
- package/dist/chunks/hi-CT5WERqi.mjs +2 -0
- package/dist/chunks/hi-CT5WERqi.mjs.map +1 -0
- package/dist/chunks/hi-CbLPPQ0b.mjs +2 -0
- package/dist/chunks/hi-CbLPPQ0b.mjs.map +1 -0
- package/dist/chunks/hi-ClvEtEKe.mjs +2 -0
- package/dist/chunks/hi-ClvEtEKe.mjs.map +1 -0
- package/dist/chunks/hi-CpBWHmYH.mjs +2 -0
- package/dist/chunks/hi-CpBWHmYH.mjs.map +1 -0
- package/dist/chunks/hi-DAfl8nU_.mjs +2 -0
- package/dist/chunks/hi-DAfl8nU_.mjs.map +1 -0
- package/dist/chunks/hi-DVof3w0y.mjs +2 -0
- package/dist/chunks/hi-DVof3w0y.mjs.map +1 -0
- package/dist/chunks/hi-DtlvSQkD.mjs +2 -0
- package/dist/chunks/hi-DtlvSQkD.mjs.map +1 -0
- package/dist/chunks/hi-FH3CAJuR.mjs +2 -0
- package/dist/chunks/hi-FH3CAJuR.mjs.map +1 -0
- package/dist/chunks/hi-Ga9h9a_1.mjs +2 -0
- package/dist/chunks/hi-Ga9h9a_1.mjs.map +1 -0
- package/dist/chunks/hi-Zc17M1T-.mjs +2 -0
- package/dist/chunks/hi-Zc17M1T-.mjs.map +1 -0
- package/dist/chunks/hi-g7i0bmig.mjs +2 -0
- package/dist/chunks/hi-g7i0bmig.mjs.map +1 -0
- package/dist/chunks/hi-js2P6byR.mjs +2 -0
- package/dist/chunks/hi-js2P6byR.mjs.map +1 -0
- package/dist/chunks/hi-ntUsOspQ.mjs +2 -0
- package/dist/chunks/hi-ntUsOspQ.mjs.map +1 -0
- package/dist/chunks/hi-yxAcR3w6.mjs +2 -0
- package/dist/chunks/hi-yxAcR3w6.mjs.map +1 -0
- package/dist/chunks/index-CVwf0cdH.mjs +2 -0
- package/dist/chunks/index-CVwf0cdH.mjs.map +1 -0
- package/dist/chunks/index-D3BZFsAD.mjs +2 -0
- package/dist/chunks/index-D3BZFsAD.mjs.map +1 -0
- package/dist/chunks/pt--IiroJQw.mjs +2 -0
- package/dist/chunks/pt--IiroJQw.mjs.map +1 -0
- package/dist/chunks/pt-BF72W8M5.mjs +2 -0
- package/dist/chunks/pt-BF72W8M5.mjs.map +1 -0
- package/dist/chunks/pt-BX_t4luI.mjs +2 -0
- package/dist/chunks/pt-BX_t4luI.mjs.map +1 -0
- package/dist/chunks/pt-B_XJ2s9X.mjs +2 -0
- package/dist/chunks/pt-B_XJ2s9X.mjs.map +1 -0
- package/dist/chunks/pt-C-Vp7Rxj.mjs +2 -0
- package/dist/chunks/pt-C-Vp7Rxj.mjs.map +1 -0
- package/dist/chunks/pt-CD2aCZXf.mjs +2 -0
- package/dist/chunks/pt-CD2aCZXf.mjs.map +1 -0
- package/dist/chunks/pt-CFjzqIbS.mjs +2 -0
- package/dist/chunks/pt-CFjzqIbS.mjs.map +1 -0
- package/dist/chunks/pt-CHjmBegF.mjs +2 -0
- package/dist/chunks/pt-CHjmBegF.mjs.map +1 -0
- package/dist/chunks/pt-CQRzEocL.mjs +2 -0
- package/dist/chunks/pt-CQRzEocL.mjs.map +1 -0
- package/dist/chunks/pt-Cem2WxUk.mjs +2 -0
- package/dist/chunks/pt-Cem2WxUk.mjs.map +1 -0
- package/dist/chunks/pt-D6kdF3fH.mjs +2 -0
- package/dist/chunks/pt-D6kdF3fH.mjs.map +1 -0
- package/dist/chunks/pt-DJfJVeY8.mjs +2 -0
- package/dist/chunks/pt-DJfJVeY8.mjs.map +1 -0
- package/dist/chunks/pt-DfB-IaYi.mjs +2 -0
- package/dist/chunks/pt-DfB-IaYi.mjs.map +1 -0
- package/dist/chunks/pt-DlNdH9pu.mjs +2 -0
- package/dist/chunks/pt-DlNdH9pu.mjs.map +1 -0
- package/dist/chunks/pt-DrJ0-8Yo.mjs +2 -0
- package/dist/chunks/pt-DrJ0-8Yo.mjs.map +1 -0
- package/dist/chunks/pt-DsBJpgpe.mjs +2 -0
- package/dist/chunks/pt-DsBJpgpe.mjs.map +1 -0
- package/dist/chunks/pt-DwdSYJzC.mjs +2 -0
- package/dist/chunks/pt-DwdSYJzC.mjs.map +1 -0
- package/dist/chunks/pt-Dx9UkZ3j.mjs +2 -0
- package/dist/chunks/pt-Dx9UkZ3j.mjs.map +1 -0
- package/dist/chunks/pt-K0BUlM9X.mjs +2 -0
- package/dist/chunks/pt-K0BUlM9X.mjs.map +1 -0
- package/dist/chunks/pt-TuA3_GDM.mjs +2 -0
- package/dist/chunks/pt-TuA3_GDM.mjs.map +1 -0
- package/dist/chunks/pt-cN6r-f7f.mjs +2 -0
- package/dist/chunks/pt-cN6r-f7f.mjs.map +1 -0
- package/dist/chunks/pt-uNGpVM3D.mjs +2 -0
- package/dist/chunks/pt-uNGpVM3D.mjs.map +1 -0
- package/dist/chunks/pt-v1E9u-Jx.mjs +2 -0
- package/dist/chunks/pt-v1E9u-Jx.mjs.map +1 -0
- package/dist/chunks/ru-0h51zrqE.mjs +2 -0
- package/dist/chunks/ru-0h51zrqE.mjs.map +1 -0
- package/dist/chunks/ru-4S8w6UN_.mjs +2 -0
- package/dist/chunks/ru-4S8w6UN_.mjs.map +1 -0
- package/dist/chunks/ru-B0cRw90L.mjs +2 -0
- package/dist/chunks/ru-B0cRw90L.mjs.map +1 -0
- package/dist/chunks/ru-B3O7WXNM.mjs +2 -0
- package/dist/chunks/ru-B3O7WXNM.mjs.map +1 -0
- package/dist/chunks/ru-B6zVAzvI.mjs +2 -0
- package/dist/chunks/ru-B6zVAzvI.mjs.map +1 -0
- package/dist/chunks/ru-B8teJin_.mjs +2 -0
- package/dist/chunks/ru-B8teJin_.mjs.map +1 -0
- package/dist/chunks/ru-BCriPw-8.mjs +2 -0
- package/dist/chunks/ru-BCriPw-8.mjs.map +1 -0
- package/dist/chunks/ru-BNOU16E5.mjs +2 -0
- package/dist/chunks/ru-BNOU16E5.mjs.map +1 -0
- package/dist/chunks/ru-BO6BIS5W.mjs +2 -0
- package/dist/chunks/ru-BO6BIS5W.mjs.map +1 -0
- package/dist/chunks/ru-Bdy1lLuc.mjs +2 -0
- package/dist/chunks/ru-Bdy1lLuc.mjs.map +1 -0
- package/dist/chunks/ru-BgBctNVm.mjs +2 -0
- package/dist/chunks/ru-BgBctNVm.mjs.map +1 -0
- package/dist/chunks/ru-CNLx7T3O.mjs +2 -0
- package/dist/chunks/ru-CNLx7T3O.mjs.map +1 -0
- package/dist/chunks/ru-CVSCT776.mjs +2 -0
- package/dist/chunks/ru-CVSCT776.mjs.map +1 -0
- package/dist/chunks/ru-CZvkdGnf.mjs +2 -0
- package/dist/chunks/ru-CZvkdGnf.mjs.map +1 -0
- package/dist/chunks/ru-CegMPuML.mjs +2 -0
- package/dist/chunks/ru-CegMPuML.mjs.map +1 -0
- package/dist/chunks/ru-CiLrD2Nz.mjs +2 -0
- package/dist/chunks/ru-CiLrD2Nz.mjs.map +1 -0
- package/dist/chunks/ru-ClEM6OKY.mjs +2 -0
- package/dist/chunks/ru-ClEM6OKY.mjs.map +1 -0
- package/dist/chunks/ru-CrbxCeQf.mjs +2 -0
- package/dist/chunks/ru-CrbxCeQf.mjs.map +1 -0
- package/dist/chunks/ru-D3j2x2xu.mjs +2 -0
- package/dist/chunks/ru-D3j2x2xu.mjs.map +1 -0
- package/dist/chunks/ru-DdHqb4Mh.mjs +2 -0
- package/dist/chunks/ru-DdHqb4Mh.mjs.map +1 -0
- package/dist/chunks/ru-DjgNdOdJ.mjs +2 -0
- package/dist/chunks/ru-DjgNdOdJ.mjs.map +1 -0
- package/dist/chunks/ru-Tzd5N37W.mjs +2 -0
- package/dist/chunks/ru-Tzd5N37W.mjs.map +1 -0
- package/dist/chunks/ru-XKNCzkR2.mjs +2 -0
- package/dist/chunks/ru-XKNCzkR2.mjs.map +1 -0
- package/dist/chunks/zh--oNSMazK.mjs +2 -0
- package/dist/chunks/zh--oNSMazK.mjs.map +1 -0
- package/dist/chunks/zh-BfeWdPIz.mjs +2 -0
- package/dist/chunks/zh-BfeWdPIz.mjs.map +1 -0
- package/dist/chunks/zh-BnOxGKxF.mjs +2 -0
- package/dist/chunks/zh-BnOxGKxF.mjs.map +1 -0
- package/dist/chunks/zh-BqMtE-jN.mjs +2 -0
- package/dist/chunks/zh-BqMtE-jN.mjs.map +1 -0
- package/dist/chunks/zh-C3aI7A2o.mjs +2 -0
- package/dist/chunks/zh-C3aI7A2o.mjs.map +1 -0
- package/dist/chunks/zh-C6YALJZt.mjs +2 -0
- package/dist/chunks/zh-C6YALJZt.mjs.map +1 -0
- package/dist/chunks/zh-CWdTbUOP.mjs +2 -0
- package/dist/chunks/zh-CWdTbUOP.mjs.map +1 -0
- package/dist/chunks/zh-CY01pMD4.mjs +2 -0
- package/dist/chunks/zh-CY01pMD4.mjs.map +1 -0
- package/dist/chunks/zh-Cmt7n9FY.mjs +2 -0
- package/dist/chunks/zh-Cmt7n9FY.mjs.map +1 -0
- package/dist/chunks/zh-CpP2kee3.mjs +2 -0
- package/dist/chunks/zh-CpP2kee3.mjs.map +1 -0
- package/dist/chunks/zh-Cpbg4evx.mjs +2 -0
- package/dist/chunks/zh-Cpbg4evx.mjs.map +1 -0
- package/dist/chunks/zh-Cqb55JWa.mjs +2 -0
- package/dist/chunks/zh-Cqb55JWa.mjs.map +1 -0
- package/dist/chunks/zh-DCQZ6gss.mjs +2 -0
- package/dist/chunks/zh-DCQZ6gss.mjs.map +1 -0
- package/dist/chunks/zh-DG2CNTUU.mjs +2 -0
- package/dist/chunks/zh-DG2CNTUU.mjs.map +1 -0
- package/dist/chunks/zh-DTiTJbzz.mjs +2 -0
- package/dist/chunks/zh-DTiTJbzz.mjs.map +1 -0
- package/dist/chunks/zh-Da1z6qbB.mjs +2 -0
- package/dist/chunks/zh-Da1z6qbB.mjs.map +1 -0
- package/dist/chunks/zh-Di3WqY4_.mjs +2 -0
- package/dist/chunks/zh-Di3WqY4_.mjs.map +1 -0
- package/dist/chunks/zh-DlBt06Pr.mjs +2 -0
- package/dist/chunks/zh-DlBt06Pr.mjs.map +1 -0
- package/dist/chunks/zh-Dt-wVrNr.mjs +2 -0
- package/dist/chunks/zh-Dt-wVrNr.mjs.map +1 -0
- package/dist/chunks/zh-ND6vW2M-.mjs +2 -0
- package/dist/chunks/zh-ND6vW2M-.mjs.map +1 -0
- package/dist/chunks/zh-Yd3GNsa0.mjs +2 -0
- package/dist/chunks/zh-Yd3GNsa0.mjs.map +1 -0
- package/dist/chunks/zh-lhynyH6Q.mjs +2 -0
- package/dist/chunks/zh-lhynyH6Q.mjs.map +1 -0
- package/dist/chunks/zh-v9NmlEIN.mjs +2 -0
- package/dist/chunks/zh-v9NmlEIN.mjs.map +1 -0
- package/dist/commands/BlockInsertion.d.ts +64 -0
- package/dist/commands/BlockInsertion.d.ts.map +1 -0
- package/dist/commands/CommandHelpers.d.ts +4 -0
- package/dist/commands/CommandHelpers.d.ts.map +1 -1
- package/dist/commands/Commands.d.ts +9 -3
- package/dist/commands/Commands.d.ts.map +1 -1
- package/dist/commands/GapCursorCommands.d.ts.map +1 -1
- package/dist/commands/MovementCommands.d.ts +1 -4
- package/dist/commands/MovementCommands.d.ts.map +1 -1
- package/dist/commands/NodeSelectionCommands.d.ts +3 -1
- package/dist/commands/NodeSelectionCommands.d.ts.map +1 -1
- package/dist/commands/PasteCommand.d.ts.map +1 -1
- package/dist/commands/WordBoundary.d.ts +4 -9
- package/dist/commands/WordBoundary.d.ts.map +1 -1
- package/dist/editor/Announcer.d.ts +1 -2
- package/dist/editor/Announcer.d.ts.map +1 -1
- package/dist/{model → editor}/BuiltinSpecs.d.ts +1 -1
- package/dist/editor/BuiltinSpecs.d.ts.map +1 -0
- package/dist/editor/ContentSerializer.d.ts +24 -0
- package/dist/editor/ContentSerializer.d.ts.map +1 -0
- package/dist/editor/EditorConfigController.d.ts +38 -0
- package/dist/editor/EditorConfigController.d.ts.map +1 -0
- package/dist/editor/EditorDOM.d.ts +3 -4
- package/dist/editor/EditorDOM.d.ts.map +1 -1
- package/dist/editor/EditorEventEmitter.d.ts +30 -0
- package/dist/editor/EditorEventEmitter.d.ts.map +1 -0
- package/dist/editor/EditorLifecycleCoordinator.d.ts +24 -0
- package/dist/editor/EditorLifecycleCoordinator.d.ts.map +1 -0
- package/dist/editor/EditorLocale.d.ts +9 -0
- package/dist/editor/EditorLocale.d.ts.map +1 -0
- package/dist/editor/EditorStyleCoordinator.d.ts +9 -0
- package/dist/editor/EditorStyleCoordinator.d.ts.map +1 -0
- package/dist/editor/EditorThemeController.d.ts.map +1 -1
- package/dist/editor/NotectlEditor.d.ts +20 -54
- package/dist/editor/NotectlEditor.d.ts.map +1 -1
- package/dist/editor/PaperLayoutController.d.ts +1 -1
- package/dist/editor/PaperLayoutController.d.ts.map +1 -1
- package/dist/editor/PluginBootstrapper.d.ts +18 -0
- package/dist/editor/PluginBootstrapper.d.ts.map +1 -0
- package/dist/editor/locales/ar.d.ts +4 -0
- package/dist/editor/locales/ar.d.ts.map +1 -0
- package/dist/editor/locales/de.d.ts +4 -0
- package/dist/editor/locales/de.d.ts.map +1 -0
- package/dist/editor/locales/es.d.ts +4 -0
- package/dist/editor/locales/es.d.ts.map +1 -0
- package/dist/editor/locales/fr.d.ts +4 -0
- package/dist/editor/locales/fr.d.ts.map +1 -0
- package/dist/editor/locales/hi.d.ts +4 -0
- package/dist/editor/locales/hi.d.ts.map +1 -0
- package/dist/editor/locales/pt.d.ts +4 -0
- package/dist/editor/locales/pt.d.ts.map +1 -0
- package/dist/editor/locales/ru.d.ts +4 -0
- package/dist/editor/locales/ru.d.ts.map +1 -0
- package/dist/editor/locales/zh.d.ts +4 -0
- package/dist/editor/locales/zh.d.ts.map +1 -0
- package/dist/editor/styles/base.d.ts +1 -1
- package/dist/editor/styles/base.d.ts.map +1 -1
- package/dist/editor/styles/code-block.d.ts +1 -1
- package/dist/editor/styles/code-block.d.ts.map +1 -1
- package/dist/editor/styles/font-select.d.ts +1 -1
- package/dist/editor/styles/font-select.d.ts.map +1 -1
- package/dist/editor/styles/font-size-select.d.ts +1 -1
- package/dist/editor/styles/font-size-select.d.ts.map +1 -1
- package/dist/editor/styles/heading-select.d.ts +1 -1
- package/dist/editor/styles/heading-select.d.ts.map +1 -1
- package/dist/editor/styles/image.d.ts +1 -1
- package/dist/editor/styles/image.d.ts.map +1 -1
- package/dist/editor/styles/list.d.ts +1 -1
- package/dist/editor/styles/list.d.ts.map +1 -1
- package/dist/editor/styles/table.d.ts +1 -1
- package/dist/editor/styles/table.d.ts.map +1 -1
- package/dist/editor/styles/toolbar.d.ts +1 -1
- package/dist/editor/styles/toolbar.d.ts.map +1 -1
- package/dist/editor/theme/ThemeEngine.d.ts.map +1 -1
- package/dist/editor/theme/ThemeTokens.d.ts +17 -1
- package/dist/editor/theme/ThemeTokens.d.ts.map +1 -1
- package/dist/fonts.mjs +1 -6
- package/dist/fonts.mjs.map +1 -1
- package/dist/full.d.ts +46 -0
- package/dist/full.d.ts.map +1 -0
- package/dist/full.mjs +2 -0
- package/dist/full.mjs.map +1 -0
- package/dist/html.d.ts +16 -0
- package/dist/html.d.ts.map +1 -0
- package/dist/html.mjs +2 -0
- package/dist/html.mjs.map +1 -0
- package/dist/i18n/Locale.d.ts +1 -0
- package/dist/i18n/Locale.d.ts.map +1 -1
- package/dist/i18n/index.d.ts +0 -1
- package/dist/i18n/index.d.ts.map +1 -1
- package/dist/index.d.ts +30 -94
- package/dist/index.d.ts.map +1 -1
- package/dist/input/ClipboardHandler.d.ts +22 -0
- package/dist/input/ClipboardHandler.d.ts.map +1 -1
- package/dist/input/CompositionTracker.d.ts +2 -1
- package/dist/input/CompositionTracker.d.ts.map +1 -1
- package/dist/{model → input}/HTMLParser.d.ts +3 -3
- package/dist/input/HTMLParser.d.ts.map +1 -0
- package/dist/input/InputHandler.d.ts +1 -1
- package/dist/input/InputHandler.d.ts.map +1 -1
- package/dist/input/InputManager.d.ts +37 -0
- package/dist/input/InputManager.d.ts.map +1 -0
- package/dist/input/InternalClipboard.d.ts +3 -13
- package/dist/input/InternalClipboard.d.ts.map +1 -1
- package/dist/input/KeyboardHandler.d.ts +12 -1
- package/dist/input/KeyboardHandler.d.ts.map +1 -1
- package/dist/input/PasteHandler.d.ts +28 -17
- package/dist/input/PasteHandler.d.ts.map +1 -1
- package/dist/model/AttrRegistry.d.ts +1 -1
- package/dist/model/AttrRegistry.d.ts.map +1 -1
- package/dist/model/BlockAlignment.d.ts +8 -0
- package/dist/model/BlockAlignment.d.ts.map +1 -0
- package/dist/model/BlockTypeLabels.d.ts +7 -0
- package/dist/model/BlockTypeLabels.d.ts.map +1 -0
- package/dist/model/CompositionState.d.ts +8 -0
- package/dist/model/CompositionState.d.ts.map +1 -0
- package/dist/model/Document.d.ts.map +1 -1
- package/dist/{input → model}/FileHandlerRegistry.d.ts +1 -1
- package/dist/{input → model}/FileHandlerRegistry.d.ts.map +1 -1
- package/dist/model/HTMLUtils.d.ts +8 -0
- package/dist/model/HTMLUtils.d.ts.map +1 -1
- package/dist/{input → model}/InputRule.d.ts.map +1 -1
- package/dist/{input → model}/InputRuleRegistry.d.ts.map +1 -1
- package/dist/{input → model}/Keymap.d.ts.map +1 -1
- package/dist/{input → model}/KeymapRegistry.d.ts.map +1 -1
- package/dist/model/MarkSpec.d.ts +2 -2
- package/dist/model/MarkSpec.d.ts.map +1 -1
- package/dist/model/NodeSpec.d.ts +0 -3
- package/dist/model/NodeSpec.d.ts.map +1 -1
- package/dist/model/PaperSize.d.ts.map +1 -0
- package/dist/model/PasteInterceptor.d.ts +21 -0
- package/dist/model/PasteInterceptor.d.ts.map +1 -0
- package/dist/model/RichBlockData.d.ts +24 -0
- package/dist/model/RichBlockData.d.ts.map +1 -0
- package/dist/model/SchemaRegistry.d.ts +2 -0
- package/dist/model/SchemaRegistry.d.ts.map +1 -1
- package/dist/model/WordBoundary.d.ts +12 -0
- package/dist/model/WordBoundary.d.ts.map +1 -0
- package/dist/notectl-core.mjs +1 -3888
- package/dist/notectl-core.mjs.map +1 -1
- package/dist/notectl-core.umd.js +1 -9523
- package/dist/notectl-core.umd.js.map +1 -1
- package/dist/{view → platform}/Platform.d.ts +2 -0
- package/dist/platform/Platform.d.ts.map +1 -0
- package/dist/plugins/Plugin.d.ts +8 -5
- package/dist/plugins/Plugin.d.ts.map +1 -1
- package/dist/plugins/PluginManager.d.ts +10 -3
- package/dist/plugins/PluginManager.d.ts.map +1 -1
- package/dist/plugins/alignment/AlignmentLocale.d.ts +3 -10
- package/dist/plugins/alignment/AlignmentLocale.d.ts.map +1 -1
- package/dist/plugins/alignment/AlignmentPlugin.d.ts +3 -13
- package/dist/plugins/alignment/AlignmentPlugin.d.ts.map +1 -1
- package/dist/plugins/alignment/index.d.ts +3 -1
- package/dist/plugins/alignment/index.d.ts.map +1 -1
- package/dist/plugins/alignment/locales/ar.d.ts +4 -0
- package/dist/plugins/alignment/locales/ar.d.ts.map +1 -0
- package/dist/plugins/alignment/locales/de.d.ts +4 -0
- package/dist/plugins/alignment/locales/de.d.ts.map +1 -0
- package/dist/plugins/alignment/locales/es.d.ts +4 -0
- package/dist/plugins/alignment/locales/es.d.ts.map +1 -0
- package/dist/plugins/alignment/locales/fr.d.ts +4 -0
- package/dist/plugins/alignment/locales/fr.d.ts.map +1 -0
- package/dist/plugins/alignment/locales/hi.d.ts +4 -0
- package/dist/plugins/alignment/locales/hi.d.ts.map +1 -0
- package/dist/plugins/alignment/locales/pt.d.ts +4 -0
- package/dist/plugins/alignment/locales/pt.d.ts.map +1 -0
- package/dist/plugins/alignment/locales/ru.d.ts +4 -0
- package/dist/plugins/alignment/locales/ru.d.ts.map +1 -0
- package/dist/plugins/alignment/locales/zh.d.ts +4 -0
- package/dist/plugins/alignment/locales/zh.d.ts.map +1 -0
- package/dist/plugins/alignment.mjs +1 -5
- package/dist/plugins/alignment.mjs.map +1 -1
- package/dist/plugins/blockquote/BlockquoteKeyboardHandlers.d.ts +4 -0
- package/dist/plugins/blockquote/BlockquoteKeyboardHandlers.d.ts.map +1 -0
- package/dist/plugins/blockquote/BlockquoteLocale.d.ts +1 -8
- package/dist/plugins/blockquote/BlockquoteLocale.d.ts.map +1 -1
- package/dist/plugins/blockquote/BlockquotePlugin.d.ts +1 -3
- package/dist/plugins/blockquote/BlockquotePlugin.d.ts.map +1 -1
- package/dist/plugins/blockquote/BlockquoteStyles.d.ts +3 -0
- package/dist/plugins/blockquote/BlockquoteStyles.d.ts.map +1 -0
- package/dist/plugins/blockquote/index.d.ts +2 -0
- package/dist/plugins/blockquote/index.d.ts.map +1 -1
- package/dist/plugins/blockquote/locales/ar.d.ts +4 -0
- package/dist/plugins/blockquote/locales/ar.d.ts.map +1 -0
- package/dist/plugins/blockquote/locales/de.d.ts +4 -0
- package/dist/plugins/blockquote/locales/de.d.ts.map +1 -0
- package/dist/plugins/blockquote/locales/es.d.ts +4 -0
- package/dist/plugins/blockquote/locales/es.d.ts.map +1 -0
- package/dist/plugins/blockquote/locales/fr.d.ts +4 -0
- package/dist/plugins/blockquote/locales/fr.d.ts.map +1 -0
- package/dist/plugins/blockquote/locales/hi.d.ts +4 -0
- package/dist/plugins/blockquote/locales/hi.d.ts.map +1 -0
- package/dist/plugins/blockquote/locales/pt.d.ts +4 -0
- package/dist/plugins/blockquote/locales/pt.d.ts.map +1 -0
- package/dist/plugins/blockquote/locales/ru.d.ts +4 -0
- package/dist/plugins/blockquote/locales/ru.d.ts.map +1 -0
- package/dist/plugins/blockquote/locales/zh.d.ts +4 -0
- package/dist/plugins/blockquote/locales/zh.d.ts.map +1 -0
- package/dist/plugins/blockquote.mjs +1 -4
- package/dist/plugins/blockquote.mjs.map +1 -1
- package/dist/plugins/caret-navigation/CaretNavigationLocale.d.ts +21 -0
- package/dist/plugins/caret-navigation/CaretNavigationLocale.d.ts.map +1 -0
- package/dist/plugins/caret-navigation/CaretNavigationPlugin.d.ts +2 -1
- package/dist/plugins/caret-navigation/CaretNavigationPlugin.d.ts.map +1 -1
- package/dist/plugins/caret-navigation/index.d.ts +2 -0
- package/dist/plugins/caret-navigation/index.d.ts.map +1 -1
- package/dist/plugins/caret-navigation/locales/ar.d.ts +4 -0
- package/dist/plugins/caret-navigation/locales/ar.d.ts.map +1 -0
- package/dist/plugins/caret-navigation/locales/de.d.ts +4 -0
- package/dist/plugins/caret-navigation/locales/de.d.ts.map +1 -0
- package/dist/plugins/caret-navigation/locales/es.d.ts +4 -0
- package/dist/plugins/caret-navigation/locales/es.d.ts.map +1 -0
- package/dist/plugins/caret-navigation/locales/fr.d.ts +4 -0
- package/dist/plugins/caret-navigation/locales/fr.d.ts.map +1 -0
- package/dist/plugins/caret-navigation/locales/hi.d.ts +4 -0
- package/dist/plugins/caret-navigation/locales/hi.d.ts.map +1 -0
- package/dist/plugins/caret-navigation/locales/pt.d.ts +4 -0
- package/dist/plugins/caret-navigation/locales/pt.d.ts.map +1 -0
- package/dist/plugins/caret-navigation/locales/ru.d.ts +4 -0
- package/dist/plugins/caret-navigation/locales/ru.d.ts.map +1 -0
- package/dist/plugins/caret-navigation/locales/zh.d.ts +4 -0
- package/dist/plugins/caret-navigation/locales/zh.d.ts.map +1 -0
- package/dist/plugins/caret-navigation.mjs +1 -4
- package/dist/plugins/caret-navigation.mjs.map +1 -1
- package/dist/plugins/code-block/CodeBlockKeyboardHandlers.d.ts.map +1 -1
- package/dist/plugins/code-block/CodeBlockLocale.d.ts +5 -8
- package/dist/plugins/code-block/CodeBlockLocale.d.ts.map +1 -1
- package/dist/plugins/code-block/CodeBlockNodeView.d.ts +2 -1
- package/dist/plugins/code-block/CodeBlockNodeView.d.ts.map +1 -1
- package/dist/plugins/code-block/CodeBlockPlugin.d.ts +7 -2
- package/dist/plugins/code-block/CodeBlockPlugin.d.ts.map +1 -1
- package/dist/plugins/code-block/CodeBlockService.d.ts.map +1 -1
- package/dist/plugins/code-block/CodeBlockTypes.d.ts +7 -1
- package/dist/plugins/code-block/CodeBlockTypes.d.ts.map +1 -1
- package/dist/plugins/code-block/highlighter/RegexTokenizer.d.ts +14 -0
- package/dist/plugins/code-block/highlighter/RegexTokenizer.d.ts.map +1 -0
- package/dist/plugins/code-block/highlighter/TokenizerTypes.d.ts +15 -0
- package/dist/plugins/code-block/highlighter/TokenizerTypes.d.ts.map +1 -0
- package/dist/plugins/code-block/highlighter/languages/index.d.ts +3 -0
- package/dist/plugins/code-block/highlighter/languages/index.d.ts.map +1 -0
- package/dist/plugins/code-block/highlighter/languages/json.d.ts +3 -0
- package/dist/plugins/code-block/highlighter/languages/json.d.ts.map +1 -0
- package/dist/plugins/code-block/highlighter/languages/xml.d.ts +3 -0
- package/dist/plugins/code-block/highlighter/languages/xml.d.ts.map +1 -0
- package/dist/plugins/code-block/index.d.ts +7 -1
- package/dist/plugins/code-block/index.d.ts.map +1 -1
- package/dist/plugins/code-block/locales/ar.d.ts +4 -0
- package/dist/plugins/code-block/locales/ar.d.ts.map +1 -0
- package/dist/plugins/code-block/locales/de.d.ts +4 -0
- package/dist/plugins/code-block/locales/de.d.ts.map +1 -0
- package/dist/plugins/code-block/locales/es.d.ts +4 -0
- package/dist/plugins/code-block/locales/es.d.ts.map +1 -0
- package/dist/plugins/code-block/locales/fr.d.ts +4 -0
- package/dist/plugins/code-block/locales/fr.d.ts.map +1 -0
- package/dist/plugins/code-block/locales/hi.d.ts +4 -0
- package/dist/plugins/code-block/locales/hi.d.ts.map +1 -0
- package/dist/plugins/code-block/locales/pt.d.ts +4 -0
- package/dist/plugins/code-block/locales/pt.d.ts.map +1 -0
- package/dist/plugins/code-block/locales/ru.d.ts +4 -0
- package/dist/plugins/code-block/locales/ru.d.ts.map +1 -0
- package/dist/plugins/code-block/locales/zh.d.ts +4 -0
- package/dist/plugins/code-block/locales/zh.d.ts.map +1 -0
- package/dist/plugins/code-block.mjs +1 -5
- package/dist/plugins/code-block.mjs.map +1 -1
- package/dist/plugins/font/FontLocale.d.ts +1 -8
- package/dist/plugins/font/FontLocale.d.ts.map +1 -1
- package/dist/plugins/font/FontPlugin.d.ts +1 -3
- package/dist/plugins/font/FontPlugin.d.ts.map +1 -1
- package/dist/plugins/font/index.d.ts +2 -0
- package/dist/plugins/font/index.d.ts.map +1 -1
- package/dist/plugins/font/locales/ar.d.ts +4 -0
- package/dist/plugins/font/locales/ar.d.ts.map +1 -0
- package/dist/plugins/font/locales/de.d.ts +4 -0
- package/dist/plugins/font/locales/de.d.ts.map +1 -0
- package/dist/plugins/font/locales/es.d.ts +4 -0
- package/dist/plugins/font/locales/es.d.ts.map +1 -0
- package/dist/plugins/font/locales/fr.d.ts +4 -0
- package/dist/plugins/font/locales/fr.d.ts.map +1 -0
- package/dist/plugins/font/locales/hi.d.ts +4 -0
- package/dist/plugins/font/locales/hi.d.ts.map +1 -0
- package/dist/plugins/font/locales/pt.d.ts +4 -0
- package/dist/plugins/font/locales/pt.d.ts.map +1 -0
- package/dist/plugins/font/locales/ru.d.ts +4 -0
- package/dist/plugins/font/locales/ru.d.ts.map +1 -0
- package/dist/plugins/font/locales/zh.d.ts +4 -0
- package/dist/plugins/font/locales/zh.d.ts.map +1 -0
- package/dist/plugins/font-size/FontSizeLocale.d.ts +1 -8
- package/dist/plugins/font-size/FontSizeLocale.d.ts.map +1 -1
- package/dist/plugins/font-size/FontSizePlugin.d.ts +1 -3
- package/dist/plugins/font-size/FontSizePlugin.d.ts.map +1 -1
- package/dist/plugins/font-size/FontSizePopup.d.ts +1 -1
- package/dist/plugins/font-size/FontSizePopup.d.ts.map +1 -1
- package/dist/plugins/font-size/index.d.ts +2 -0
- package/dist/plugins/font-size/index.d.ts.map +1 -1
- package/dist/plugins/font-size/locales/ar.d.ts +4 -0
- package/dist/plugins/font-size/locales/ar.d.ts.map +1 -0
- package/dist/plugins/font-size/locales/de.d.ts +4 -0
- package/dist/plugins/font-size/locales/de.d.ts.map +1 -0
- package/dist/plugins/font-size/locales/es.d.ts +4 -0
- package/dist/plugins/font-size/locales/es.d.ts.map +1 -0
- package/dist/plugins/font-size/locales/fr.d.ts +4 -0
- package/dist/plugins/font-size/locales/fr.d.ts.map +1 -0
- package/dist/plugins/font-size/locales/hi.d.ts +4 -0
- package/dist/plugins/font-size/locales/hi.d.ts.map +1 -0
- package/dist/plugins/font-size/locales/pt.d.ts +4 -0
- package/dist/plugins/font-size/locales/pt.d.ts.map +1 -0
- package/dist/plugins/font-size/locales/ru.d.ts +4 -0
- package/dist/plugins/font-size/locales/ru.d.ts.map +1 -0
- package/dist/plugins/font-size/locales/zh.d.ts +4 -0
- package/dist/plugins/font-size/locales/zh.d.ts.map +1 -0
- package/dist/plugins/font-size.mjs +1 -4
- package/dist/plugins/font-size.mjs.map +1 -1
- package/dist/plugins/font.mjs +1 -4
- package/dist/plugins/font.mjs.map +1 -1
- package/dist/plugins/gap-cursor/GapCursorLocale.d.ts +7 -0
- package/dist/plugins/gap-cursor/GapCursorLocale.d.ts.map +1 -0
- package/dist/plugins/gap-cursor/GapCursorPlugin.d.ts +7 -3
- package/dist/plugins/gap-cursor/GapCursorPlugin.d.ts.map +1 -1
- package/dist/plugins/gap-cursor/locales/ar.d.ts +4 -0
- package/dist/plugins/gap-cursor/locales/ar.d.ts.map +1 -0
- package/dist/plugins/gap-cursor/locales/de.d.ts +4 -0
- package/dist/plugins/gap-cursor/locales/de.d.ts.map +1 -0
- package/dist/plugins/gap-cursor/locales/es.d.ts +4 -0
- package/dist/plugins/gap-cursor/locales/es.d.ts.map +1 -0
- package/dist/plugins/gap-cursor/locales/fr.d.ts +4 -0
- package/dist/plugins/gap-cursor/locales/fr.d.ts.map +1 -0
- package/dist/plugins/gap-cursor/locales/hi.d.ts +4 -0
- package/dist/plugins/gap-cursor/locales/hi.d.ts.map +1 -0
- package/dist/plugins/gap-cursor/locales/pt.d.ts +4 -0
- package/dist/plugins/gap-cursor/locales/pt.d.ts.map +1 -0
- package/dist/plugins/gap-cursor/locales/ru.d.ts +4 -0
- package/dist/plugins/gap-cursor/locales/ru.d.ts.map +1 -0
- package/dist/plugins/gap-cursor/locales/zh.d.ts +4 -0
- package/dist/plugins/gap-cursor/locales/zh.d.ts.map +1 -0
- package/dist/plugins/gap-cursor.mjs +1 -64
- package/dist/plugins/gap-cursor.mjs.map +1 -1
- package/dist/plugins/hard-break.mjs +1 -4
- package/dist/plugins/hard-break.mjs.map +1 -1
- package/dist/plugins/heading/HeadingBlockTypePicker.d.ts +1 -1
- package/dist/plugins/heading/HeadingBlockTypePicker.d.ts.map +1 -1
- package/dist/plugins/heading/HeadingInputRules.d.ts.map +1 -1
- package/dist/plugins/heading/HeadingKeyboardHandlers.d.ts.map +1 -1
- package/dist/plugins/heading/HeadingLocale.d.ts +1 -8
- package/dist/plugins/heading/HeadingLocale.d.ts.map +1 -1
- package/dist/plugins/heading/HeadingPlugin.d.ts +2 -4
- package/dist/plugins/heading/HeadingPlugin.d.ts.map +1 -1
- package/dist/plugins/heading/index.d.ts +3 -0
- package/dist/plugins/heading/index.d.ts.map +1 -1
- package/dist/plugins/heading/locales/ar.d.ts +4 -0
- package/dist/plugins/heading/locales/ar.d.ts.map +1 -0
- package/dist/plugins/heading/locales/de.d.ts +4 -0
- package/dist/plugins/heading/locales/de.d.ts.map +1 -0
- package/dist/plugins/heading/locales/es.d.ts +4 -0
- package/dist/plugins/heading/locales/es.d.ts.map +1 -0
- package/dist/plugins/heading/locales/fr.d.ts +4 -0
- package/dist/plugins/heading/locales/fr.d.ts.map +1 -0
- package/dist/plugins/heading/locales/hi.d.ts +4 -0
- package/dist/plugins/heading/locales/hi.d.ts.map +1 -0
- package/dist/plugins/heading/locales/pt.d.ts +4 -0
- package/dist/plugins/heading/locales/pt.d.ts.map +1 -0
- package/dist/plugins/heading/locales/ru.d.ts +4 -0
- package/dist/plugins/heading/locales/ru.d.ts.map +1 -0
- package/dist/plugins/heading/locales/zh.d.ts +4 -0
- package/dist/plugins/heading/locales/zh.d.ts.map +1 -0
- package/dist/plugins/heading.mjs +1 -4
- package/dist/plugins/heading.mjs.map +1 -1
- package/dist/plugins/highlight/HighlightLocale.d.ts +1 -8
- package/dist/plugins/highlight/HighlightLocale.d.ts.map +1 -1
- package/dist/plugins/highlight/HighlightPlugin.d.ts +1 -3
- package/dist/plugins/highlight/HighlightPlugin.d.ts.map +1 -1
- package/dist/plugins/highlight/index.d.ts +2 -0
- package/dist/plugins/highlight/index.d.ts.map +1 -1
- package/dist/plugins/highlight/locales/ar.d.ts +4 -0
- package/dist/plugins/highlight/locales/ar.d.ts.map +1 -0
- package/dist/plugins/highlight/locales/de.d.ts +4 -0
- package/dist/plugins/highlight/locales/de.d.ts.map +1 -0
- package/dist/plugins/highlight/locales/es.d.ts +4 -0
- package/dist/plugins/highlight/locales/es.d.ts.map +1 -0
- package/dist/plugins/highlight/locales/fr.d.ts +4 -0
- package/dist/plugins/highlight/locales/fr.d.ts.map +1 -0
- package/dist/plugins/highlight/locales/hi.d.ts +4 -0
- package/dist/plugins/highlight/locales/hi.d.ts.map +1 -0
- package/dist/plugins/highlight/locales/pt.d.ts +4 -0
- package/dist/plugins/highlight/locales/pt.d.ts.map +1 -0
- package/dist/plugins/highlight/locales/ru.d.ts +4 -0
- package/dist/plugins/highlight/locales/ru.d.ts.map +1 -0
- package/dist/plugins/highlight/locales/zh.d.ts +4 -0
- package/dist/plugins/highlight/locales/zh.d.ts.map +1 -0
- package/dist/plugins/highlight.mjs +1 -4
- package/dist/plugins/highlight.mjs.map +1 -1
- package/dist/plugins/horizontal-rule/HorizontalRuleLocale.d.ts +1 -8
- package/dist/plugins/horizontal-rule/HorizontalRuleLocale.d.ts.map +1 -1
- package/dist/plugins/horizontal-rule/HorizontalRulePlugin.d.ts +1 -3
- package/dist/plugins/horizontal-rule/HorizontalRulePlugin.d.ts.map +1 -1
- package/dist/plugins/horizontal-rule/index.d.ts +2 -0
- package/dist/plugins/horizontal-rule/index.d.ts.map +1 -1
- package/dist/plugins/horizontal-rule/locales/ar.d.ts +4 -0
- package/dist/plugins/horizontal-rule/locales/ar.d.ts.map +1 -0
- package/dist/plugins/horizontal-rule/locales/de.d.ts +4 -0
- package/dist/plugins/horizontal-rule/locales/de.d.ts.map +1 -0
- package/dist/plugins/horizontal-rule/locales/es.d.ts +4 -0
- package/dist/plugins/horizontal-rule/locales/es.d.ts.map +1 -0
- package/dist/plugins/horizontal-rule/locales/fr.d.ts +4 -0
- package/dist/plugins/horizontal-rule/locales/fr.d.ts.map +1 -0
- package/dist/plugins/horizontal-rule/locales/hi.d.ts +4 -0
- package/dist/plugins/horizontal-rule/locales/hi.d.ts.map +1 -0
- package/dist/plugins/horizontal-rule/locales/pt.d.ts +4 -0
- package/dist/plugins/horizontal-rule/locales/pt.d.ts.map +1 -0
- package/dist/plugins/horizontal-rule/locales/ru.d.ts +4 -0
- package/dist/plugins/horizontal-rule/locales/ru.d.ts.map +1 -0
- package/dist/plugins/horizontal-rule/locales/zh.d.ts +4 -0
- package/dist/plugins/horizontal-rule/locales/zh.d.ts.map +1 -0
- package/dist/plugins/horizontal-rule.mjs +1 -4
- package/dist/plugins/horizontal-rule.mjs.map +1 -1
- package/dist/plugins/image/ImageLocale.d.ts +9 -8
- package/dist/plugins/image/ImageLocale.d.ts.map +1 -1
- package/dist/plugins/image/ImageNodeView.d.ts +8 -1
- package/dist/plugins/image/ImageNodeView.d.ts.map +1 -1
- package/dist/plugins/image/ImagePlugin.d.ts +2 -3
- package/dist/plugins/image/ImagePlugin.d.ts.map +1 -1
- package/dist/plugins/image/ImagePopup.d.ts +11 -0
- package/dist/plugins/image/ImagePopup.d.ts.map +1 -0
- package/dist/plugins/image/ImageUpload.d.ts +1 -2
- package/dist/plugins/image/ImageUpload.d.ts.map +1 -1
- package/dist/plugins/image/index.d.ts +2 -0
- package/dist/plugins/image/index.d.ts.map +1 -1
- package/dist/plugins/image/locales/ar.d.ts +4 -0
- package/dist/plugins/image/locales/ar.d.ts.map +1 -0
- package/dist/plugins/image/locales/de.d.ts +4 -0
- package/dist/plugins/image/locales/de.d.ts.map +1 -0
- package/dist/plugins/image/locales/es.d.ts +4 -0
- package/dist/plugins/image/locales/es.d.ts.map +1 -0
- package/dist/plugins/image/locales/fr.d.ts +4 -0
- package/dist/plugins/image/locales/fr.d.ts.map +1 -0
- package/dist/plugins/image/locales/hi.d.ts +4 -0
- package/dist/plugins/image/locales/hi.d.ts.map +1 -0
- package/dist/plugins/image/locales/pt.d.ts +4 -0
- package/dist/plugins/image/locales/pt.d.ts.map +1 -0
- package/dist/plugins/image/locales/ru.d.ts +4 -0
- package/dist/plugins/image/locales/ru.d.ts.map +1 -0
- package/dist/plugins/image/locales/zh.d.ts +4 -0
- package/dist/plugins/image/locales/zh.d.ts.map +1 -0
- package/dist/plugins/image.mjs +1 -6
- package/dist/plugins/image.mjs.map +1 -1
- package/dist/plugins/link/LinkLocale.d.ts +1 -8
- package/dist/plugins/link/LinkLocale.d.ts.map +1 -1
- package/dist/plugins/link/LinkPlugin.d.ts +1 -3
- package/dist/plugins/link/LinkPlugin.d.ts.map +1 -1
- package/dist/plugins/link/index.d.ts +2 -0
- package/dist/plugins/link/index.d.ts.map +1 -1
- package/dist/plugins/link/locales/ar.d.ts +4 -0
- package/dist/plugins/link/locales/ar.d.ts.map +1 -0
- package/dist/plugins/link/locales/de.d.ts +4 -0
- package/dist/plugins/link/locales/de.d.ts.map +1 -0
- package/dist/plugins/link/locales/es.d.ts +4 -0
- package/dist/plugins/link/locales/es.d.ts.map +1 -0
- package/dist/plugins/link/locales/fr.d.ts +4 -0
- package/dist/plugins/link/locales/fr.d.ts.map +1 -0
- package/dist/plugins/link/locales/hi.d.ts +4 -0
- package/dist/plugins/link/locales/hi.d.ts.map +1 -0
- package/dist/plugins/link/locales/pt.d.ts +4 -0
- package/dist/plugins/link/locales/pt.d.ts.map +1 -0
- package/dist/plugins/link/locales/ru.d.ts +4 -0
- package/dist/plugins/link/locales/ru.d.ts.map +1 -0
- package/dist/plugins/link/locales/zh.d.ts +4 -0
- package/dist/plugins/link/locales/zh.d.ts.map +1 -0
- package/dist/plugins/link.mjs +1 -4
- package/dist/plugins/link.mjs.map +1 -1
- package/dist/plugins/list/ListLocale.d.ts +1 -8
- package/dist/plugins/list/ListLocale.d.ts.map +1 -1
- package/dist/plugins/list/ListPlugin.d.ts +1 -3
- package/dist/plugins/list/ListPlugin.d.ts.map +1 -1
- package/dist/plugins/list/index.d.ts +2 -0
- package/dist/plugins/list/index.d.ts.map +1 -1
- package/dist/plugins/list/locales/ar.d.ts +4 -0
- package/dist/plugins/list/locales/ar.d.ts.map +1 -0
- package/dist/plugins/list/locales/de.d.ts +4 -0
- package/dist/plugins/list/locales/de.d.ts.map +1 -0
- package/dist/plugins/list/locales/es.d.ts +4 -0
- package/dist/plugins/list/locales/es.d.ts.map +1 -0
- package/dist/plugins/list/locales/fr.d.ts +4 -0
- package/dist/plugins/list/locales/fr.d.ts.map +1 -0
- package/dist/plugins/list/locales/hi.d.ts +4 -0
- package/dist/plugins/list/locales/hi.d.ts.map +1 -0
- package/dist/plugins/list/locales/pt.d.ts +4 -0
- package/dist/plugins/list/locales/pt.d.ts.map +1 -0
- package/dist/plugins/list/locales/ru.d.ts +4 -0
- package/dist/plugins/list/locales/ru.d.ts.map +1 -0
- package/dist/plugins/list/locales/zh.d.ts +4 -0
- package/dist/plugins/list/locales/zh.d.ts.map +1 -0
- package/dist/plugins/list.mjs +1 -4
- package/dist/plugins/list.mjs.map +1 -1
- package/dist/plugins/print/PrintLocale.d.ts +1 -8
- package/dist/plugins/print/PrintLocale.d.ts.map +1 -1
- package/dist/plugins/print/PrintPlugin.d.ts +1 -1
- package/dist/plugins/print/PrintPlugin.d.ts.map +1 -1
- package/dist/plugins/print/PrintServiceImpl.d.ts.map +1 -1
- package/dist/plugins/print/PrintStyleCollector.d.ts.map +1 -1
- package/dist/plugins/print/PrintTypes.d.ts +1 -1
- package/dist/plugins/print/PrintTypes.d.ts.map +1 -1
- package/dist/plugins/print/index.d.ts +5 -0
- package/dist/plugins/print/index.d.ts.map +1 -0
- package/dist/plugins/print/locales/ar.d.ts +4 -0
- package/dist/plugins/print/locales/ar.d.ts.map +1 -0
- package/dist/plugins/print/locales/de.d.ts +4 -0
- package/dist/plugins/print/locales/de.d.ts.map +1 -0
- package/dist/plugins/print/locales/es.d.ts +4 -0
- package/dist/plugins/print/locales/es.d.ts.map +1 -0
- package/dist/plugins/print/locales/fr.d.ts +4 -0
- package/dist/plugins/print/locales/fr.d.ts.map +1 -0
- package/dist/plugins/print/locales/hi.d.ts +4 -0
- package/dist/plugins/print/locales/hi.d.ts.map +1 -0
- package/dist/plugins/print/locales/pt.d.ts +4 -0
- package/dist/plugins/print/locales/pt.d.ts.map +1 -0
- package/dist/plugins/print/locales/ru.d.ts +4 -0
- package/dist/plugins/print/locales/ru.d.ts.map +1 -0
- package/dist/plugins/print/locales/zh.d.ts +4 -0
- package/dist/plugins/print/locales/zh.d.ts.map +1 -0
- package/dist/plugins/print.mjs +2 -0
- package/dist/plugins/print.mjs.map +1 -0
- package/dist/plugins/shared/ColorGrid.d.ts.map +1 -1
- package/dist/plugins/shared/ColorMarkOperations.d.ts +1 -2
- package/dist/plugins/shared/ColorMarkOperations.d.ts.map +1 -1
- package/dist/plugins/shared/ColorPickerPopup.d.ts +1 -8
- package/dist/plugins/shared/ColorPickerPopup.d.ts.map +1 -1
- package/dist/plugins/shared/KeyboardNav.d.ts +17 -0
- package/dist/plugins/shared/KeyboardNav.d.ts.map +1 -0
- package/dist/plugins/shared/PluginHelpers.d.ts +18 -0
- package/dist/plugins/shared/PluginHelpers.d.ts.map +1 -0
- package/dist/plugins/shared/PopupKeyboardPatterns.d.ts +1 -1
- package/dist/plugins/shared/PopupKeyboardPatterns.d.ts.map +1 -1
- package/dist/plugins/shared/PopupManager.d.ts +2 -0
- package/dist/plugins/shared/PopupManager.d.ts.map +1 -1
- package/dist/plugins/shared/PopupPositioning.d.ts +1 -0
- package/dist/plugins/shared/PopupPositioning.d.ts.map +1 -1
- package/dist/plugins/shared/ShortcutFormatting.d.ts +9 -0
- package/dist/plugins/shared/ShortcutFormatting.d.ts.map +1 -0
- package/dist/plugins/shared/XmlPatterns.d.ts +10 -0
- package/dist/plugins/shared/XmlPatterns.d.ts.map +1 -0
- package/dist/plugins/shared/index.d.ts +13 -0
- package/dist/plugins/shared/index.d.ts.map +1 -0
- package/dist/plugins/shared.mjs +2 -0
- package/dist/plugins/shared.mjs.map +1 -0
- package/dist/plugins/smart-paste/SmartPasteLocale.d.ts +7 -0
- package/dist/plugins/smart-paste/SmartPasteLocale.d.ts.map +1 -0
- package/dist/plugins/smart-paste/SmartPastePlugin.d.ts +19 -0
- package/dist/plugins/smart-paste/SmartPastePlugin.d.ts.map +1 -0
- package/dist/plugins/smart-paste/SmartPasteTypes.d.ts +24 -0
- package/dist/plugins/smart-paste/SmartPasteTypes.d.ts.map +1 -0
- package/dist/plugins/smart-paste/detectors/JsonDetector.d.ts +6 -0
- package/dist/plugins/smart-paste/detectors/JsonDetector.d.ts.map +1 -0
- package/dist/plugins/smart-paste/detectors/XmlDetector.d.ts +26 -0
- package/dist/plugins/smart-paste/detectors/XmlDetector.d.ts.map +1 -0
- package/dist/plugins/smart-paste/index.d.ts +7 -0
- package/dist/plugins/smart-paste/index.d.ts.map +1 -0
- package/dist/plugins/smart-paste/locales/ar.d.ts +4 -0
- package/dist/plugins/smart-paste/locales/ar.d.ts.map +1 -0
- package/dist/plugins/smart-paste/locales/de.d.ts +4 -0
- package/dist/plugins/smart-paste/locales/de.d.ts.map +1 -0
- package/dist/plugins/smart-paste/locales/es.d.ts +4 -0
- package/dist/plugins/smart-paste/locales/es.d.ts.map +1 -0
- package/dist/plugins/smart-paste/locales/fr.d.ts +4 -0
- package/dist/plugins/smart-paste/locales/fr.d.ts.map +1 -0
- package/dist/plugins/smart-paste/locales/hi.d.ts +4 -0
- package/dist/plugins/smart-paste/locales/hi.d.ts.map +1 -0
- package/dist/plugins/smart-paste/locales/pt.d.ts +4 -0
- package/dist/plugins/smart-paste/locales/pt.d.ts.map +1 -0
- package/dist/plugins/smart-paste/locales/ru.d.ts +4 -0
- package/dist/plugins/smart-paste/locales/ru.d.ts.map +1 -0
- package/dist/plugins/smart-paste/locales/zh.d.ts +4 -0
- package/dist/plugins/smart-paste/locales/zh.d.ts.map +1 -0
- package/dist/plugins/smart-paste.mjs +2 -0
- package/dist/plugins/smart-paste.mjs.map +1 -0
- package/dist/plugins/strikethrough/StrikethroughLocale.d.ts +1 -8
- package/dist/plugins/strikethrough/StrikethroughLocale.d.ts.map +1 -1
- package/dist/plugins/strikethrough/StrikethroughPlugin.d.ts +1 -3
- package/dist/plugins/strikethrough/StrikethroughPlugin.d.ts.map +1 -1
- package/dist/plugins/strikethrough/index.d.ts +2 -0
- package/dist/plugins/strikethrough/index.d.ts.map +1 -1
- package/dist/plugins/strikethrough/locales/ar.d.ts +4 -0
- package/dist/plugins/strikethrough/locales/ar.d.ts.map +1 -0
- package/dist/plugins/strikethrough/locales/de.d.ts +4 -0
- package/dist/plugins/strikethrough/locales/de.d.ts.map +1 -0
- package/dist/plugins/strikethrough/locales/es.d.ts +4 -0
- package/dist/plugins/strikethrough/locales/es.d.ts.map +1 -0
- package/dist/plugins/strikethrough/locales/fr.d.ts +4 -0
- package/dist/plugins/strikethrough/locales/fr.d.ts.map +1 -0
- package/dist/plugins/strikethrough/locales/hi.d.ts +4 -0
- package/dist/plugins/strikethrough/locales/hi.d.ts.map +1 -0
- package/dist/plugins/strikethrough/locales/pt.d.ts +4 -0
- package/dist/plugins/strikethrough/locales/pt.d.ts.map +1 -0
- package/dist/plugins/strikethrough/locales/ru.d.ts +4 -0
- package/dist/plugins/strikethrough/locales/ru.d.ts.map +1 -0
- package/dist/plugins/strikethrough/locales/zh.d.ts +4 -0
- package/dist/plugins/strikethrough/locales/zh.d.ts.map +1 -0
- package/dist/plugins/strikethrough.mjs +1 -4
- package/dist/plugins/strikethrough.mjs.map +1 -1
- package/dist/plugins/super-sub/SuperSubLocale.d.ts +1 -8
- package/dist/plugins/super-sub/SuperSubLocale.d.ts.map +1 -1
- package/dist/plugins/super-sub/SuperSubPlugin.d.ts +1 -3
- package/dist/plugins/super-sub/SuperSubPlugin.d.ts.map +1 -1
- package/dist/plugins/super-sub/index.d.ts +2 -0
- package/dist/plugins/super-sub/index.d.ts.map +1 -1
- package/dist/plugins/super-sub/locales/ar.d.ts +4 -0
- package/dist/plugins/super-sub/locales/ar.d.ts.map +1 -0
- package/dist/plugins/super-sub/locales/de.d.ts +4 -0
- package/dist/plugins/super-sub/locales/de.d.ts.map +1 -0
- package/dist/plugins/super-sub/locales/es.d.ts +4 -0
- package/dist/plugins/super-sub/locales/es.d.ts.map +1 -0
- package/dist/plugins/super-sub/locales/fr.d.ts +4 -0
- package/dist/plugins/super-sub/locales/fr.d.ts.map +1 -0
- package/dist/plugins/super-sub/locales/hi.d.ts +4 -0
- package/dist/plugins/super-sub/locales/hi.d.ts.map +1 -0
- package/dist/plugins/super-sub/locales/pt.d.ts +4 -0
- package/dist/plugins/super-sub/locales/pt.d.ts.map +1 -0
- package/dist/plugins/super-sub/locales/ru.d.ts +4 -0
- package/dist/plugins/super-sub/locales/ru.d.ts.map +1 -0
- package/dist/plugins/super-sub/locales/zh.d.ts +4 -0
- package/dist/plugins/super-sub/locales/zh.d.ts.map +1 -0
- package/dist/plugins/super-sub.mjs +1 -4
- package/dist/plugins/super-sub.mjs.map +1 -1
- package/dist/plugins/table/TableCommands.d.ts +8 -8
- package/dist/plugins/table/TableCommands.d.ts.map +1 -1
- package/dist/plugins/table/TableContextMenu.d.ts.map +1 -1
- package/dist/plugins/table/TableControlsDOM.d.ts +4 -4
- package/dist/plugins/table/TableControlsDOM.d.ts.map +1 -1
- package/dist/plugins/table/TableLocale.d.ts +1 -8
- package/dist/plugins/table/TableLocale.d.ts.map +1 -1
- package/dist/plugins/table/TableNavigation.d.ts +1 -1
- package/dist/plugins/table/TableNavigation.d.ts.map +1 -1
- package/dist/plugins/table/TablePlugin.d.ts +3 -5
- package/dist/plugins/table/TablePlugin.d.ts.map +1 -1
- package/dist/plugins/table/TableSelection.d.ts +2 -0
- package/dist/plugins/table/TableSelection.d.ts.map +1 -1
- package/dist/plugins/table/index.d.ts +1 -5
- package/dist/plugins/table/index.d.ts.map +1 -1
- package/dist/plugins/table/locales/ar.d.ts +4 -0
- package/dist/plugins/table/locales/ar.d.ts.map +1 -0
- package/dist/plugins/table/locales/de.d.ts +4 -0
- package/dist/plugins/table/locales/de.d.ts.map +1 -0
- package/dist/plugins/table/locales/es.d.ts +4 -0
- package/dist/plugins/table/locales/es.d.ts.map +1 -0
- package/dist/plugins/table/locales/fr.d.ts +4 -0
- package/dist/plugins/table/locales/fr.d.ts.map +1 -0
- package/dist/plugins/table/locales/hi.d.ts +4 -0
- package/dist/plugins/table/locales/hi.d.ts.map +1 -0
- package/dist/plugins/table/locales/pt.d.ts +4 -0
- package/dist/plugins/table/locales/pt.d.ts.map +1 -0
- package/dist/plugins/table/locales/ru.d.ts +4 -0
- package/dist/plugins/table/locales/ru.d.ts.map +1 -0
- package/dist/plugins/table/locales/zh.d.ts +4 -0
- package/dist/plugins/table/locales/zh.d.ts.map +1 -0
- package/dist/plugins/table.mjs +1 -20
- package/dist/plugins/table.mjs.map +1 -1
- package/dist/plugins/text-color/TextColorLocale.d.ts +1 -8
- package/dist/plugins/text-color/TextColorLocale.d.ts.map +1 -1
- package/dist/plugins/text-color/TextColorPlugin.d.ts +1 -3
- package/dist/plugins/text-color/TextColorPlugin.d.ts.map +1 -1
- package/dist/plugins/text-color/index.d.ts +2 -0
- package/dist/plugins/text-color/index.d.ts.map +1 -1
- package/dist/plugins/text-color/locales/ar.d.ts +4 -0
- package/dist/plugins/text-color/locales/ar.d.ts.map +1 -0
- package/dist/plugins/text-color/locales/de.d.ts +4 -0
- package/dist/plugins/text-color/locales/de.d.ts.map +1 -0
- package/dist/plugins/text-color/locales/es.d.ts +4 -0
- package/dist/plugins/text-color/locales/es.d.ts.map +1 -0
- package/dist/plugins/text-color/locales/fr.d.ts +4 -0
- package/dist/plugins/text-color/locales/fr.d.ts.map +1 -0
- package/dist/plugins/text-color/locales/hi.d.ts +4 -0
- package/dist/plugins/text-color/locales/hi.d.ts.map +1 -0
- package/dist/plugins/text-color/locales/pt.d.ts +4 -0
- package/dist/plugins/text-color/locales/pt.d.ts.map +1 -0
- package/dist/plugins/text-color/locales/ru.d.ts +4 -0
- package/dist/plugins/text-color/locales/ru.d.ts.map +1 -0
- package/dist/plugins/text-color/locales/zh.d.ts +4 -0
- package/dist/plugins/text-color/locales/zh.d.ts.map +1 -0
- package/dist/plugins/text-color.mjs +1 -4
- package/dist/plugins/text-color.mjs.map +1 -1
- package/dist/plugins/text-direction/DirectionDetection.d.ts +17 -0
- package/dist/plugins/text-direction/DirectionDetection.d.ts.map +1 -0
- package/dist/plugins/text-direction/ShiftDirectionHandler.d.ts +12 -0
- package/dist/plugins/text-direction/ShiftDirectionHandler.d.ts.map +1 -0
- package/dist/plugins/text-direction/TextDirectionCorePlugin.d.ts +35 -0
- package/dist/plugins/text-direction/TextDirectionCorePlugin.d.ts.map +1 -0
- package/dist/plugins/text-direction/TextDirectionLocale.d.ts +20 -0
- package/dist/plugins/text-direction/TextDirectionLocale.d.ts.map +1 -0
- package/dist/plugins/text-direction/TextDirectionMiddleware.d.ts +18 -0
- package/dist/plugins/text-direction/TextDirectionMiddleware.d.ts.map +1 -0
- package/dist/plugins/text-direction/TextDirectionPlugin.d.ts +59 -0
- package/dist/plugins/text-direction/TextDirectionPlugin.d.ts.map +1 -0
- package/dist/plugins/text-direction/index.d.ts +5 -0
- package/dist/plugins/text-direction/index.d.ts.map +1 -0
- package/dist/plugins/text-direction/locales/ar.d.ts +4 -0
- package/dist/plugins/text-direction/locales/ar.d.ts.map +1 -0
- package/dist/plugins/text-direction/locales/de.d.ts +4 -0
- package/dist/plugins/text-direction/locales/de.d.ts.map +1 -0
- package/dist/plugins/text-direction/locales/es.d.ts +4 -0
- package/dist/plugins/text-direction/locales/es.d.ts.map +1 -0
- package/dist/plugins/text-direction/locales/fr.d.ts +4 -0
- package/dist/plugins/text-direction/locales/fr.d.ts.map +1 -0
- package/dist/plugins/text-direction/locales/hi.d.ts +4 -0
- package/dist/plugins/text-direction/locales/hi.d.ts.map +1 -0
- package/dist/plugins/text-direction/locales/pt.d.ts +4 -0
- package/dist/plugins/text-direction/locales/pt.d.ts.map +1 -0
- package/dist/plugins/text-direction/locales/ru.d.ts +4 -0
- package/dist/plugins/text-direction/locales/ru.d.ts.map +1 -0
- package/dist/plugins/text-direction/locales/zh.d.ts +4 -0
- package/dist/plugins/text-direction/locales/zh.d.ts.map +1 -0
- package/dist/plugins/text-direction-advanced/index.d.ts +5 -0
- package/dist/plugins/text-direction-advanced/index.d.ts.map +1 -0
- package/dist/plugins/text-direction-advanced.mjs +2 -0
- package/dist/plugins/text-direction-advanced.mjs.map +1 -0
- package/dist/plugins/text-direction.mjs +2 -0
- package/dist/plugins/text-direction.mjs.map +1 -0
- package/dist/plugins/text-formatting/TextFormattingLocale.d.ts +1 -8
- package/dist/plugins/text-formatting/TextFormattingLocale.d.ts.map +1 -1
- package/dist/plugins/text-formatting/TextFormattingPlugin.d.ts +1 -3
- package/dist/plugins/text-formatting/TextFormattingPlugin.d.ts.map +1 -1
- package/dist/plugins/text-formatting/index.d.ts +2 -0
- package/dist/plugins/text-formatting/index.d.ts.map +1 -1
- package/dist/plugins/text-formatting/locales/ar.d.ts +4 -0
- package/dist/plugins/text-formatting/locales/ar.d.ts.map +1 -0
- package/dist/plugins/text-formatting/locales/de.d.ts +4 -0
- package/dist/plugins/text-formatting/locales/de.d.ts.map +1 -0
- package/dist/plugins/text-formatting/locales/es.d.ts +4 -0
- package/dist/plugins/text-formatting/locales/es.d.ts.map +1 -0
- package/dist/plugins/text-formatting/locales/fr.d.ts +4 -0
- package/dist/plugins/text-formatting/locales/fr.d.ts.map +1 -0
- package/dist/plugins/text-formatting/locales/hi.d.ts +4 -0
- package/dist/plugins/text-formatting/locales/hi.d.ts.map +1 -0
- package/dist/plugins/text-formatting/locales/pt.d.ts +4 -0
- package/dist/plugins/text-formatting/locales/pt.d.ts.map +1 -0
- package/dist/plugins/text-formatting/locales/ru.d.ts +4 -0
- package/dist/plugins/text-formatting/locales/ru.d.ts.map +1 -0
- package/dist/plugins/text-formatting/locales/zh.d.ts +4 -0
- package/dist/plugins/text-formatting/locales/zh.d.ts.map +1 -0
- package/dist/plugins/text-formatting.mjs +1 -4
- package/dist/plugins/text-formatting.mjs.map +1 -1
- package/dist/plugins/toolbar/ToolbarItem.d.ts +2 -18
- package/dist/plugins/toolbar/ToolbarItem.d.ts.map +1 -1
- package/dist/plugins/toolbar/ToolbarKeyboardNav.d.ts +5 -11
- package/dist/plugins/toolbar/ToolbarKeyboardNav.d.ts.map +1 -1
- package/dist/plugins/toolbar/ToolbarLocale.d.ts +2 -8
- package/dist/plugins/toolbar/ToolbarLocale.d.ts.map +1 -1
- package/dist/plugins/toolbar/ToolbarOverflowController.d.ts.map +1 -1
- package/dist/plugins/toolbar/ToolbarPlugin.d.ts +2 -2
- package/dist/plugins/toolbar/ToolbarPlugin.d.ts.map +1 -1
- package/dist/plugins/toolbar/ToolbarPopupController.d.ts +3 -1
- package/dist/plugins/toolbar/ToolbarPopupController.d.ts.map +1 -1
- package/dist/plugins/toolbar/ToolbarRenderers.d.ts +2 -1
- package/dist/plugins/toolbar/ToolbarRenderers.d.ts.map +1 -1
- package/dist/plugins/toolbar/index.d.ts +4 -1
- package/dist/plugins/toolbar/index.d.ts.map +1 -1
- package/dist/plugins/toolbar/locales/ar.d.ts +4 -0
- package/dist/plugins/toolbar/locales/ar.d.ts.map +1 -0
- package/dist/plugins/toolbar/locales/de.d.ts +4 -0
- package/dist/plugins/toolbar/locales/de.d.ts.map +1 -0
- package/dist/plugins/toolbar/locales/es.d.ts +4 -0
- package/dist/plugins/toolbar/locales/es.d.ts.map +1 -0
- package/dist/plugins/toolbar/locales/fr.d.ts +4 -0
- package/dist/plugins/toolbar/locales/fr.d.ts.map +1 -0
- package/dist/plugins/toolbar/locales/hi.d.ts +4 -0
- package/dist/plugins/toolbar/locales/hi.d.ts.map +1 -0
- package/dist/plugins/toolbar/locales/pt.d.ts +4 -0
- package/dist/plugins/toolbar/locales/pt.d.ts.map +1 -0
- package/dist/plugins/toolbar/locales/ru.d.ts +4 -0
- package/dist/plugins/toolbar/locales/ru.d.ts.map +1 -0
- package/dist/plugins/toolbar/locales/zh.d.ts +4 -0
- package/dist/plugins/toolbar/locales/zh.d.ts.map +1 -0
- package/dist/plugins/toolbar.mjs +1 -7
- package/dist/plugins/toolbar.mjs.map +1 -1
- package/dist/presets/FullPreset.d.ts +4 -1
- package/dist/presets/FullPreset.d.ts.map +1 -1
- package/dist/presets/MinimalPreset.d.ts +3 -0
- package/dist/presets/MinimalPreset.d.ts.map +1 -1
- package/dist/presets/PresetTypes.d.ts +4 -0
- package/dist/presets/PresetTypes.d.ts.map +1 -1
- package/dist/presets/full.d.ts +17 -0
- package/dist/presets/full.d.ts.map +1 -0
- package/dist/presets/full.mjs +2 -0
- package/dist/presets/full.mjs.map +1 -0
- package/dist/presets/minimal.d.ts +17 -0
- package/dist/presets/minimal.d.ts.map +1 -0
- package/dist/presets/minimal.mjs +2 -0
- package/dist/presets/minimal.mjs.map +1 -0
- package/dist/presets.d.ts +20 -0
- package/dist/presets.d.ts.map +1 -0
- package/dist/presets.mjs +2 -0
- package/dist/presets.mjs.map +1 -0
- package/dist/serialization/CSSClassCollector.d.ts.map +1 -0
- package/dist/serialization/ContentHTMLTypes.d.ts.map +1 -0
- package/dist/serialization/DocumentParser.d.ts.map +1 -0
- package/dist/{editor → serialization}/DocumentSerializer.d.ts +2 -0
- package/dist/serialization/DocumentSerializer.d.ts.map +1 -0
- package/dist/{editor → serialization}/MarkSerializer.d.ts +3 -2
- package/dist/serialization/MarkSerializer.d.ts.map +1 -0
- package/dist/serialization/index.d.ts +12 -0
- package/dist/serialization/index.d.ts.map +1 -0
- package/dist/state/BlockBoundaryMovement.d.ts +7 -0
- package/dist/state/BlockBoundaryMovement.d.ts.map +1 -0
- package/dist/state/InlineContentOps.d.ts.map +1 -1
- package/dist/{model/NavigationUtils.d.ts → state/NavigationQueries.d.ts} +3 -3
- package/dist/state/NavigationQueries.d.ts.map +1 -0
- package/dist/state/StepInversion.d.ts +7 -0
- package/dist/state/StepInversion.d.ts.map +1 -0
- package/dist/state/Steps.d.ts +108 -0
- package/dist/state/Steps.d.ts.map +1 -0
- package/dist/state/Transaction.d.ts +5 -174
- package/dist/state/Transaction.d.ts.map +1 -1
- package/dist/state/TransactionBuilder.d.ts +69 -0
- package/dist/state/TransactionBuilder.d.ts.map +1 -0
- package/dist/test/PluginTestUtils.d.ts +0 -2
- package/dist/test/PluginTestUtils.d.ts.map +1 -1
- package/dist/test/TestUtils.d.ts +2 -2
- package/dist/test/TestUtils.d.ts.map +1 -1
- package/dist/view/BlockRendering.d.ts +10 -0
- package/dist/view/BlockRendering.d.ts.map +1 -0
- package/dist/view/BlockWrapperManagement.d.ts +27 -0
- package/dist/view/BlockWrapperManagement.d.ts.map +1 -0
- package/dist/view/CaretNavigation.d.ts +1 -8
- package/dist/view/CaretNavigation.d.ts.map +1 -1
- package/dist/view/CursorWrapper.d.ts.map +1 -1
- package/dist/view/DecorationRendering.d.ts +17 -0
- package/dist/view/DecorationRendering.d.ts.map +1 -0
- package/dist/view/DomUtils.d.ts +13 -0
- package/dist/view/DomUtils.d.ts.map +1 -0
- package/dist/view/EditorView.d.ts +9 -12
- package/dist/view/EditorView.d.ts.map +1 -1
- package/dist/view/GapCursorNavigation.d.ts +12 -0
- package/dist/view/GapCursorNavigation.d.ts.map +1 -0
- package/dist/view/InlineRendering.d.ts +11 -0
- package/dist/view/InlineRendering.d.ts.map +1 -0
- package/dist/view/MarkRendering.d.ts +5 -0
- package/dist/view/MarkRendering.d.ts.map +1 -1
- package/dist/view/Reconciler.d.ts +2 -6
- package/dist/view/Reconciler.d.ts.map +1 -1
- package/dist/view/SelectionSync.d.ts +41 -2
- package/dist/view/SelectionSync.d.ts.map +1 -1
- package/dist/view/ViewMovementCommands.d.ts.map +1 -1
- package/package.json +218 -8
- package/dist/chunks/AttrRegistry-D9Jx_RVb.mjs +0 -16
- package/dist/chunks/AttrRegistry-D9Jx_RVb.mjs.map +0 -1
- package/dist/chunks/AttributedMarkCommands-BtLea72z.mjs +0 -80
- package/dist/chunks/AttributedMarkCommands-BtLea72z.mjs.map +0 -1
- package/dist/chunks/CaretNavigation-7JYpIKbs.mjs +0 -311
- package/dist/chunks/CaretNavigation-7JYpIKbs.mjs.map +0 -1
- package/dist/chunks/ColorGrid--lBQ7jCK.mjs +0 -81
- package/dist/chunks/ColorGrid--lBQ7jCK.mjs.map +0 -1
- package/dist/chunks/ColorPickerPopup-TpIRlXc8.mjs +0 -37
- package/dist/chunks/ColorPickerPopup-TpIRlXc8.mjs.map +0 -1
- package/dist/chunks/ColorValidation-CV4f1wu6.mjs +0 -39
- package/dist/chunks/Document-Brtw2jL1.mjs +0 -190
- package/dist/chunks/Document-Brtw2jL1.mjs.map +0 -1
- package/dist/chunks/HTMLUtils-DTqQzcKR.mjs +0 -35
- package/dist/chunks/HTMLUtils-DTqQzcKR.mjs.map +0 -1
- package/dist/chunks/MarkCommands-6RUJ4L3r.mjs +0 -94
- package/dist/chunks/MarkCommands-6RUJ4L3r.mjs.map +0 -1
- package/dist/chunks/NavigationUtils-Cspt2ZrK.mjs +0 -47
- package/dist/chunks/NavigationUtils-Cspt2ZrK.mjs.map +0 -1
- package/dist/chunks/NodeResolver-C2XYkeOi.mjs +0 -81
- package/dist/chunks/NodeResolver-C2XYkeOi.mjs.map +0 -1
- package/dist/chunks/NodeSpec-NZVvcCuH.mjs +0 -8
- package/dist/chunks/NodeSpec-NZVvcCuH.mjs.map +0 -1
- package/dist/chunks/Platform-S_xqIqcM.mjs +0 -26
- package/dist/chunks/Platform-S_xqIqcM.mjs.map +0 -1
- package/dist/chunks/PopupPositioning-CgjgAKjp.mjs +0 -34
- package/dist/chunks/PopupPositioning-CgjgAKjp.mjs.map +0 -1
- package/dist/chunks/RangeIterator-Bh4Vl_6D.mjs +0 -16
- package/dist/chunks/Selection-BRTab5hO.mjs +0 -52
- package/dist/chunks/StyleRuntime-CP4NCwKT.mjs +0 -235
- package/dist/chunks/ToolbarItem-BpZggUGo.mjs +0 -8
- package/dist/chunks/ToolbarItem-BpZggUGo.mjs.map +0 -1
- package/dist/chunks/ToolbarKeyboardNav-DhpL8zNV.mjs +0 -46
- package/dist/chunks/ToolbarKeyboardNav-DhpL8zNV.mjs.map +0 -1
- package/dist/chunks/TypeBrands-C09nE2qO.mjs +0 -27
- package/dist/chunks/index--7pBhSF4.mjs +0 -542
- package/dist/chunks/index--7pBhSF4.mjs.map +0 -1
- package/dist/chunks/index-BXCkjDax.mjs +0 -161
- package/dist/chunks/index-BXCkjDax.mjs.map +0 -1
- package/dist/chunks/index-BXtw5PNN.mjs +0 -39
- package/dist/chunks/index-BXtw5PNN.mjs.map +0 -1
- package/dist/chunks/index-BcDRT4K2.mjs +0 -1019
- package/dist/chunks/index-BcDRT4K2.mjs.map +0 -1
- package/dist/chunks/index-BjFBWBOC.mjs +0 -168
- package/dist/chunks/index-BjFBWBOC.mjs.map +0 -1
- package/dist/chunks/index-C1opJocO.mjs +0 -92
- package/dist/chunks/index-C1opJocO.mjs.map +0 -1
- package/dist/chunks/index-CCyqQ0Dz.mjs +0 -228
- package/dist/chunks/index-CCyqQ0Dz.mjs.map +0 -1
- package/dist/chunks/index-Cd3uJLP3.mjs +0 -73
- package/dist/chunks/index-Cd3uJLP3.mjs.map +0 -1
- package/dist/chunks/index-DSAuGP4n.mjs +0 -410
- package/dist/chunks/index-DSAuGP4n.mjs.map +0 -1
- package/dist/chunks/index-DtRfqsq5.mjs +0 -924
- package/dist/chunks/index-DtRfqsq5.mjs.map +0 -1
- package/dist/chunks/index-Dum8yE_t.mjs +0 -62
- package/dist/chunks/index-Dum8yE_t.mjs.map +0 -1
- package/dist/chunks/index-DxbQirny.mjs +0 -63
- package/dist/chunks/index-DxbQirny.mjs.map +0 -1
- package/dist/chunks/index-ErZ5_a1o.mjs +0 -296
- package/dist/chunks/index-ErZ5_a1o.mjs.map +0 -1
- package/dist/chunks/index-WpbK_s_H.mjs +0 -119
- package/dist/chunks/index-WpbK_s_H.mjs.map +0 -1
- package/dist/chunks/index-WrqH1wG8.mjs +0 -50
- package/dist/chunks/index-WrqH1wG8.mjs.map +0 -1
- package/dist/chunks/index-fsVJLutn.mjs +0 -118
- package/dist/chunks/index-fsVJLutn.mjs.map +0 -1
- package/dist/chunks/index-fx3KIap3.mjs +0 -50
- package/dist/chunks/index-fx3KIap3.mjs.map +0 -1
- package/dist/chunks/index-oOJo-ywB.mjs +0 -467
- package/dist/chunks/index-oOJo-ywB.mjs.map +0 -1
- package/dist/chunks/index-toj88jtL.mjs +0 -101
- package/dist/chunks/index-toj88jtL.mjs.map +0 -1
- package/dist/chunks/resolvePluginLocale-B4w1OkPy.mjs +0 -34
- package/dist/chunks/resolvePluginLocale-B4w1OkPy.mjs.map +0 -1
- package/dist/editor/CSSClassCollector.d.ts.map +0 -1
- package/dist/editor/ContentHTMLTypes.d.ts.map +0 -1
- package/dist/editor/DocumentParser.d.ts.map +0 -1
- package/dist/editor/DocumentSerializer.d.ts.map +0 -1
- package/dist/editor/MarkSerializer.d.ts.map +0 -1
- package/dist/editor/PaperSize.d.ts.map +0 -1
- package/dist/i18n/resolvePluginLocale.d.ts +0 -3
- package/dist/i18n/resolvePluginLocale.d.ts.map +0 -1
- package/dist/model/BuiltinSpecs.d.ts.map +0 -1
- package/dist/model/HTMLParser.d.ts.map +0 -1
- package/dist/model/NavigationUtils.d.ts.map +0 -1
- package/dist/view/Platform.d.ts.map +0 -1
- /package/dist/{input → model}/InputRule.d.ts +0 -0
- /package/dist/{input → model}/InputRuleRegistry.d.ts +0 -0
- /package/dist/{input → model}/Keymap.d.ts +0 -0
- /package/dist/{input → model}/KeymapRegistry.d.ts +0 -0
- /package/dist/{editor → model}/PaperSize.d.ts +0 -0
- /package/dist/{editor → serialization}/CSSClassCollector.d.ts +0 -0
- /package/dist/{editor → serialization}/ContentHTMLTypes.d.ts +0 -0
- /package/dist/{editor → serialization}/DocumentParser.d.ts +0 -0
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
import { r as e } from "./resolvePluginLocale-B4w1OkPy.mjs";
|
|
2
|
-
import { k as t } from "./Document-Brtw2jL1.mjs";
|
|
3
|
-
import { c as o } from "./NodeSpec-NZVvcCuH.mjs";
|
|
4
|
-
import { i as r, a as i, b as l, d as n } from "./Selection-BRTab5hO.mjs";
|
|
5
|
-
import { n as a } from "./TypeBrands-C09nE2qO.mjs";
|
|
6
|
-
import { f as s } from "./ToolbarItem-BpZggUGo.mjs";
|
|
7
|
-
const c = { label: "Horizontal Rule", tooltip: (e2) => `Horizontal Rule (${e2})` }, p = { en: c, de: { label: "Trennlinie", tooltip: (e2) => `Trennlinie (${e2})` }, es: { label: "Línea horizontal", tooltip: (e2) => `Línea horizontal (${e2})` }, fr: { label: "Ligne horizontale", tooltip: (e2) => `Ligne horizontale (${e2})` }, zh: { label: "分隔线", tooltip: (e2) => `分隔线 (${e2})` }, ru: { label: "Горизонтальная линия", tooltip: (e2) => `Горизонтальная линия (${e2})` }, ar: { label: "خط أفقي", tooltip: (e2) => `خط أفقي (${e2})` }, hi: { label: "क्षैतिज रेखा", tooltip: (e2) => `क्षैतिज रेखा (${e2})` } }, u = {};
|
|
8
|
-
function h(e2) {
|
|
9
|
-
const t2 = e2.selection;
|
|
10
|
-
return r(t2) || i(t2) ? -1 : e2.doc.children.findIndex((e3) => e3.id === t2.anchor.blockId);
|
|
11
|
-
}
|
|
12
|
-
class d {
|
|
13
|
-
id = "horizontal-rule";
|
|
14
|
-
name = "Horizontal Rule";
|
|
15
|
-
priority = 40;
|
|
16
|
-
config;
|
|
17
|
-
locale;
|
|
18
|
-
constructor(e2) {
|
|
19
|
-
this.config = { ...u, ...e2 };
|
|
20
|
-
}
|
|
21
|
-
init(t2) {
|
|
22
|
-
this.locale = e(p, t2, this.config.locale), this.registerNodeSpec(t2), this.registerCommands(t2), this.registerKeymap(t2), this.registerInputRule(t2), this.registerToolbarItem(t2);
|
|
23
|
-
}
|
|
24
|
-
registerNodeSpec(e2) {
|
|
25
|
-
e2.registerNodeSpec({ type: "horizontal_rule", group: "block", isVoid: true, toDOM: (e3) => o("hr", e3.id), toHTML: () => "<hr>", parseHTML: [{ tag: "hr" }], sanitize: { tags: ["hr"] } });
|
|
26
|
-
}
|
|
27
|
-
registerCommands(e2) {
|
|
28
|
-
e2.registerCommand("insertHorizontalRule", () => this.insertHorizontalRule(e2));
|
|
29
|
-
}
|
|
30
|
-
registerKeymap(e2) {
|
|
31
|
-
e2.registerKeymap({ "Mod-Shift-H": () => e2.executeCommand("insertHorizontalRule") });
|
|
32
|
-
}
|
|
33
|
-
registerInputRule(e2) {
|
|
34
|
-
e2.registerInputRule({ pattern: /^-{3,} $/, handler(e3, o2, s2, c2) {
|
|
35
|
-
const p2 = e3.selection;
|
|
36
|
-
if (r(p2) || i(p2)) return null;
|
|
37
|
-
if (!l(p2)) return null;
|
|
38
|
-
const u2 = e3.getBlock(p2.anchor.blockId);
|
|
39
|
-
if (!u2 || "paragraph" !== u2.type) return null;
|
|
40
|
-
const d2 = h(e3);
|
|
41
|
-
if (-1 === d2) return null;
|
|
42
|
-
const m = t(a("paragraph"));
|
|
43
|
-
return e3.transaction("input").deleteTextAt(p2.anchor.blockId, 0, c2).setBlockType(p2.anchor.blockId, a("horizontal_rule")).insertNode([], d2 + 1, m).setSelection(n(m.id, 0)).build();
|
|
44
|
-
} });
|
|
45
|
-
}
|
|
46
|
-
registerToolbarItem(e2) {
|
|
47
|
-
e2.registerToolbarItem({ id: "horizontal-rule", group: "block", icon: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M4 11h16v2H4z"/></svg>', label: this.locale.label, tooltip: this.locale.tooltip(s("Mod-Shift-H")), command: "insertHorizontalRule", priority: 60, separatorAfter: this.config.separatorAfter, isActive: () => false });
|
|
48
|
-
}
|
|
49
|
-
insertHorizontalRule(e2) {
|
|
50
|
-
const o2 = e2.getState();
|
|
51
|
-
if (r(o2.selection) || i(o2.selection)) return false;
|
|
52
|
-
const l2 = h(o2);
|
|
53
|
-
if (-1 === l2) return false;
|
|
54
|
-
const s2 = t(a("horizontal_rule")), c2 = t(a("paragraph")), p2 = o2.transaction("command").insertNode([], l2 + 1, s2).insertNode([], l2 + 2, c2).setSelection(n(c2.id, 0)).build();
|
|
55
|
-
return e2.dispatch(p2), true;
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
export {
|
|
59
|
-
d as H,
|
|
60
|
-
p as a,
|
|
61
|
-
c as b
|
|
62
|
-
};
|
|
63
|
-
//# sourceMappingURL=index-DxbQirny.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index-DxbQirny.mjs","sources":["../../src/plugins/horizontal-rule/HorizontalRuleLocale.ts","../../src/plugins/horizontal-rule/HorizontalRulePlugin.ts"],"sourcesContent":["/** Locale interface and default English locale for the HorizontalRulePlugin. */\n\n// --- Locale Interface ---\n\nexport interface HorizontalRuleLocale {\n\treadonly label: string;\n\treadonly tooltip: (shortcut: string) => string;\n}\n\n// --- Default English Locale ---\n\nexport const HORIZONTAL_RULE_LOCALE_EN: HorizontalRuleLocale = {\n\tlabel: 'Horizontal Rule',\n\ttooltip: (shortcut: string) => `Horizontal Rule (${shortcut})`,\n};\n\n// --- German Locale ---\n\nexport const HORIZONTAL_RULE_LOCALE_DE: HorizontalRuleLocale = {\n\tlabel: 'Trennlinie',\n\ttooltip: (shortcut: string) => `Trennlinie (${shortcut})`,\n};\n\n// --- Spanish Locale ---\n\nexport const HORIZONTAL_RULE_LOCALE_ES: HorizontalRuleLocale = {\n\tlabel: 'Línea horizontal',\n\ttooltip: (shortcut: string) => `Línea horizontal (${shortcut})`,\n};\n\n// --- French Locale ---\n\nexport const HORIZONTAL_RULE_LOCALE_FR: HorizontalRuleLocale = {\n\tlabel: 'Ligne horizontale',\n\ttooltip: (shortcut: string) => `Ligne horizontale (${shortcut})`,\n};\n\n// --- Chinese (Simplified) Locale ---\n\nexport const HORIZONTAL_RULE_LOCALE_ZH: HorizontalRuleLocale = {\n\tlabel: '分隔线',\n\ttooltip: (shortcut: string) => `分隔线 (${shortcut})`,\n};\n\n// --- Russian Locale ---\n\nexport const HORIZONTAL_RULE_LOCALE_RU: HorizontalRuleLocale = {\n\tlabel: 'Горизонтальная линия',\n\ttooltip: (shortcut: string) => `Горизонтальная линия (${shortcut})`,\n};\n\n// --- Arabic Locale ---\n\nexport const HORIZONTAL_RULE_LOCALE_AR: HorizontalRuleLocale = {\n\tlabel: 'خط أفقي',\n\ttooltip: (shortcut: string) => `خط أفقي (${shortcut})`,\n};\n\n// --- Hindi Locale ---\n\nexport const HORIZONTAL_RULE_LOCALE_HI: HorizontalRuleLocale = {\n\tlabel: 'क्षैतिज रेखा',\n\ttooltip: (shortcut: string) => `क्षैतिज रेखा (${shortcut})`,\n};\n\n// --- Locale Map ---\n\nexport const HORIZONTAL_RULE_LOCALES: Record<string, HorizontalRuleLocale> = {\n\ten: HORIZONTAL_RULE_LOCALE_EN,\n\tde: HORIZONTAL_RULE_LOCALE_DE,\n\tes: HORIZONTAL_RULE_LOCALE_ES,\n\tfr: HORIZONTAL_RULE_LOCALE_FR,\n\tzh: HORIZONTAL_RULE_LOCALE_ZH,\n\tru: HORIZONTAL_RULE_LOCALE_RU,\n\tar: HORIZONTAL_RULE_LOCALE_AR,\n\thi: HORIZONTAL_RULE_LOCALE_HI,\n};\n","/**\n * HorizontalRulePlugin: registers a horizontal rule (divider) void block type\n * with NodeSpec, insert command, input rule, keyboard shortcut, and toolbar button.\n */\n\nimport { resolvePluginLocale } from '../../i18n/resolvePluginLocale.js';\nimport { createBlockNode } from '../../model/Document.js';\nimport { createBlockElement } from '../../model/NodeSpec.js';\nimport {\n\tcreateCollapsedSelection,\n\tisCollapsed,\n\tisGapCursor,\n\tisNodeSelection,\n} from '../../model/Selection.js';\nimport { nodeType } from '../../model/TypeBrands.js';\nimport type { EditorState } from '../../state/EditorState.js';\nimport type { Plugin, PluginContext } from '../Plugin.js';\nimport { formatShortcut } from '../toolbar/ToolbarItem.js';\nimport { HORIZONTAL_RULE_LOCALES, type HorizontalRuleLocale } from './HorizontalRuleLocale.js';\n\n// --- Attribute Registry Augmentation ---\n\ndeclare module '../../model/AttrRegistry.js' {\n\tinterface NodeAttrRegistry {\n\t\thorizontal_rule: Record<string, never>;\n\t}\n}\n\n// --- Configuration ---\n\nexport interface HorizontalRuleConfig {\n\t/** When true, a separator is rendered after the toolbar item. */\n\treadonly separatorAfter?: boolean;\n\t/** Locale override for user-facing strings. */\n\treadonly locale?: HorizontalRuleLocale;\n}\n\nconst DEFAULT_CONFIG: HorizontalRuleConfig = {};\n\n// --- Helpers ---\n\n/** Finds the index of the cursor's block among top-level document children. */\nfunction findBlockIndexForCursor(state: EditorState): number {\n\tconst sel = state.selection;\n\tif (isNodeSelection(sel) || isGapCursor(sel)) return -1;\n\treturn state.doc.children.findIndex((b) => b.id === sel.anchor.blockId);\n}\n\n// --- Plugin ---\n\nexport class HorizontalRulePlugin implements Plugin {\n\treadonly id = 'horizontal-rule';\n\treadonly name = 'Horizontal Rule';\n\treadonly priority = 40;\n\n\tprivate readonly config: HorizontalRuleConfig;\n\tprivate locale!: HorizontalRuleLocale;\n\n\tconstructor(config?: Partial<HorizontalRuleConfig>) {\n\t\tthis.config = { ...DEFAULT_CONFIG, ...config };\n\t}\n\n\tinit(context: PluginContext): void {\n\t\tthis.locale = resolvePluginLocale(HORIZONTAL_RULE_LOCALES, context, this.config.locale);\n\t\tthis.registerNodeSpec(context);\n\t\tthis.registerCommands(context);\n\t\tthis.registerKeymap(context);\n\t\tthis.registerInputRule(context);\n\t\tthis.registerToolbarItem(context);\n\t}\n\n\tprivate registerNodeSpec(context: PluginContext): void {\n\t\tcontext.registerNodeSpec({\n\t\t\ttype: 'horizontal_rule',\n\t\t\tgroup: 'block',\n\t\t\tisVoid: true,\n\t\t\ttoDOM(node) {\n\t\t\t\treturn createBlockElement('hr', node.id);\n\t\t\t},\n\t\t\ttoHTML() {\n\t\t\t\treturn '<hr>';\n\t\t\t},\n\t\t\tparseHTML: [{ tag: 'hr' }],\n\t\t\tsanitize: { tags: ['hr'] },\n\t\t});\n\t}\n\n\tprivate registerCommands(context: PluginContext): void {\n\t\tcontext.registerCommand('insertHorizontalRule', () => {\n\t\t\treturn this.insertHorizontalRule(context);\n\t\t});\n\t}\n\n\tprivate registerKeymap(context: PluginContext): void {\n\t\tcontext.registerKeymap({\n\t\t\t'Mod-Shift-H': () => context.executeCommand('insertHorizontalRule'),\n\t\t});\n\t}\n\n\tprivate registerInputRule(context: PluginContext): void {\n\t\tcontext.registerInputRule({\n\t\t\tpattern: /^-{3,} $/,\n\t\t\thandler(state, _match, _start, end) {\n\t\t\t\tconst sel = state.selection;\n\t\t\t\tif (isNodeSelection(sel) || isGapCursor(sel)) return null;\n\t\t\t\tif (!isCollapsed(sel)) return null;\n\n\t\t\t\tconst block = state.getBlock(sel.anchor.blockId);\n\t\t\t\tif (!block || block.type !== 'paragraph') return null;\n\n\t\t\t\tconst blockIndex: number = findBlockIndexForCursor(state);\n\t\t\t\tif (blockIndex === -1) return null;\n\n\t\t\t\tconst newParagraph = createBlockNode(nodeType('paragraph'));\n\n\t\t\t\treturn state\n\t\t\t\t\t.transaction('input')\n\t\t\t\t\t.deleteTextAt(sel.anchor.blockId, 0, end)\n\t\t\t\t\t.setBlockType(sel.anchor.blockId, nodeType('horizontal_rule'))\n\t\t\t\t\t.insertNode([], blockIndex + 1, newParagraph)\n\t\t\t\t\t.setSelection(createCollapsedSelection(newParagraph.id, 0))\n\t\t\t\t\t.build();\n\t\t\t},\n\t\t});\n\t}\n\n\tprivate registerToolbarItem(context: PluginContext): void {\n\t\tconst icon =\n\t\t\t'<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\"><path d=\"M4 11h16v2H4z\"/></svg>';\n\n\t\tcontext.registerToolbarItem({\n\t\t\tid: 'horizontal-rule',\n\t\t\tgroup: 'block',\n\t\t\ticon,\n\t\t\tlabel: this.locale.label,\n\t\t\ttooltip: this.locale.tooltip(formatShortcut('Mod-Shift-H')),\n\t\t\tcommand: 'insertHorizontalRule',\n\t\t\tpriority: 60,\n\t\t\tseparatorAfter: this.config.separatorAfter,\n\t\t\tisActive: () => false,\n\t\t});\n\t}\n\n\t/**\n\t * Inserts a horizontal rule after the current block,\n\t * followed by a new paragraph for continued editing.\n\t */\n\tprivate insertHorizontalRule(context: PluginContext): boolean {\n\t\tconst state: EditorState = context.getState();\n\t\tif (isNodeSelection(state.selection) || isGapCursor(state.selection)) return false;\n\t\tconst blockIndex: number = findBlockIndexForCursor(state);\n\t\tif (blockIndex === -1) return false;\n\n\t\tconst hrBlock = createBlockNode(nodeType('horizontal_rule'));\n\t\tconst newParagraph = createBlockNode(nodeType('paragraph'));\n\n\t\tconst tr = state\n\t\t\t.transaction('command')\n\t\t\t.insertNode([], blockIndex + 1, hrBlock)\n\t\t\t.insertNode([], blockIndex + 2, newParagraph)\n\t\t\t.setSelection(createCollapsedSelection(newParagraph.id, 0))\n\t\t\t.build();\n\n\t\tcontext.dispatch(tr);\n\t\treturn true;\n\t}\n}\n"],"names":["HORIZONTAL_RULE_LOCALE_EN","label","tooltip","shortcut","HORIZONTAL_RULE_LOCALES","en","de","es","fr","zh","ru","ar","hi","DEFAULT_CONFIG","findBlockIndexForCursor","state","sel","selection","isNodeSelection","isGapCursor","doc","children","findIndex","b","id","anchor","blockId","HorizontalRulePlugin","name","priority","config","locale","this","context","resolvePluginLocale","registerNodeSpec","registerCommands","registerKeymap","registerInputRule","registerToolbarItem","type","group","isVoid","toDOM","node","createBlockElement","toHTML","parseHTML","tag","sanitize","tags","registerCommand","insertHorizontalRule","executeCommand","pattern","_match","_start","end","isCollapsed","block","getBlock","blockIndex","newParagraph","createBlockNode","nodeType","transaction","deleteTextAt","setBlockType","insertNode","setSelection","createCollapsedSelection","build","icon","formatShortcut","command","separatorAfter","isActive","getState","hrBlock","tr","dispatch"],"mappings":";;;;;;AAWO,MAAMA,IAAkD,EAC9DC,OAAO,mBACPC,SAAUC,CAAAA,OAAqB,oBAAoBA,SAsDvCC,IAAgE,EAC5EC,IAAIL,GACJM,IAnD8D,EAC9DL,OAAO,cACPC,SAAUC,CAAAA,OAAqB,eAAeA,SAkD9CI,IA7C8D,EAC9DN,OAAO,oBACPC,SAAUC,CAAAA,OAAqB,qBAAqBA,EAAAA,IAAAA,GA4CpDK,IAvC8D,EAC9DP,OAAO,qBACPC,SAAUC,CAAAA,OAAqB,sBAAsBA,SAsCrDM,IAjC8D,EAC9DR,OAAO,OACPC,SAAUC,CAAAA,OAAqB,QAAQA,EAAAA,IAAAA,GAgC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A,EAElB;AAAA,EAMQ,qBAAqB3C,IAAAA;AAC5B,UAAMlB,KAAqBkB,GAAQ4C;AACnC,QAAI3D,EAAgBH,GAAME,SAAAA,KAAcE,EAAYJ,GAAME,WAAY,QAAA;AACtE,UAAM4C,KAAqB/C,EAAwBC;AACnD,QAAA,OAAI8C,GAAmB,QAAA;AAEvB,UAAMiB,KAAUf,EAAgBC,EAAS,iBAAA,CAAA,GACnCF,KAAeC,EAAgBC,EAAS,WAAA,CAAA,GAExCe,KAAKhE,GACTkD,YAAY,SAAA,EACZG,WAAW,CAAA,GAAIP,KAAa,GAAGiB,EAAAA,EAC/BV,WAAW,IAAIP,KAAa,GAAGC,IAC/BO,aAAaC,EAAyBR,GAAatC,IAAI,CAAA,CAAA,EACvD+C;AAGF,WADAtC,GAAQ+C,SAASD,EAAAA,GAAAA;AAAAA,EAElB;AAAA;"}
|
|
@@ -1,296 +0,0 @@
|
|
|
1
|
-
import { k as t, f as n, u as e, d as o, c as r, t as i, g as c } from "./Document-Brtw2jL1.mjs";
|
|
2
|
-
import { i as s, b as l, s as d, a as u } from "./NavigationUtils-Cspt2ZrK.mjs";
|
|
3
|
-
import { f } from "./NodeResolver-C2XYkeOi.mjs";
|
|
4
|
-
import { b as a, s as b, d as k, i as g, a as I, j as h, e as m, c as p } from "./Selection-BRTab5hO.mjs";
|
|
5
|
-
import { n as S, i as B } from "./TypeBrands-C09nE2qO.mjs";
|
|
6
|
-
function x(t2, n2) {
|
|
7
|
-
if (0 === n2.length) return t2.doc.children;
|
|
8
|
-
const e2 = t2.getBlock(n2[n2.length - 1]);
|
|
9
|
-
return e2 ? e2.children : [];
|
|
10
|
-
}
|
|
11
|
-
function O(e2) {
|
|
12
|
-
return t(S("paragraph"), [n("")], e2);
|
|
13
|
-
}
|
|
14
|
-
function N(t2, n2) {
|
|
15
|
-
if (a(t2)) return { blockId: t2.anchor.blockId, offset: t2.anchor.offset };
|
|
16
|
-
const e2 = b(t2, n2);
|
|
17
|
-
return { blockId: e2.from.blockId, offset: e2.from.offset };
|
|
18
|
-
}
|
|
19
|
-
function T(t2, n2) {
|
|
20
|
-
const i2 = f(t2.doc, n2.nodeId);
|
|
21
|
-
if (!i2) return null;
|
|
22
|
-
const c2 = i2.length > 1 ? i2.slice(0, -1) : [], s2 = x(t2, c2), l2 = s2.findIndex((t3) => "id" in t3 && t3.id === n2.nodeId);
|
|
23
|
-
if (l2 < 0) return null;
|
|
24
|
-
const d2 = t2.transaction("input");
|
|
25
|
-
if (1 === s2.length && 0 === c2.length) {
|
|
26
|
-
const t3 = e();
|
|
27
|
-
return d2.insertNode(c2, 0, O(t3)), d2.removeNode(c2, 1), d2.setSelection(k(t3, 0)), d2.build();
|
|
28
|
-
}
|
|
29
|
-
d2.removeNode(c2, l2);
|
|
30
|
-
const u2 = s2[l2 - 1];
|
|
31
|
-
if (u2 && o(u2)) {
|
|
32
|
-
const n3 = (function(t3) {
|
|
33
|
-
let n4 = t3;
|
|
34
|
-
for (; ; ) {
|
|
35
|
-
let t4;
|
|
36
|
-
for (let e2 = n4.children.length - 1; e2 >= 0; e2--) {
|
|
37
|
-
const r2 = n4.children[e2];
|
|
38
|
-
if (r2 && o(r2)) {
|
|
39
|
-
t4 = r2;
|
|
40
|
-
break;
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
if (!t4) return n4.id;
|
|
44
|
-
n4 = t4;
|
|
45
|
-
}
|
|
46
|
-
})(u2);
|
|
47
|
-
if (n3) {
|
|
48
|
-
const e2 = t2.getBlock(n3), o2 = e2 ? r(e2) : 0;
|
|
49
|
-
d2.setSelection(k(n3, o2));
|
|
50
|
-
}
|
|
51
|
-
} else {
|
|
52
|
-
const t3 = s2[l2 + 1];
|
|
53
|
-
if (t3 && o(t3)) {
|
|
54
|
-
const n3 = (function(t4) {
|
|
55
|
-
let n4 = t4;
|
|
56
|
-
for (; ; ) {
|
|
57
|
-
const t5 = n4.children.find((t6) => o(t6));
|
|
58
|
-
if (!t5) return n4.id;
|
|
59
|
-
n4 = t5;
|
|
60
|
-
}
|
|
61
|
-
})(t3);
|
|
62
|
-
n3 && d2.setSelection(k(n3, 0));
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
return d2.build();
|
|
66
|
-
}
|
|
67
|
-
function A(t2, n2) {
|
|
68
|
-
const e2 = t2.selection, o2 = t2.getBlockOrder();
|
|
69
|
-
return g(e2) ? (function(t3, n3, e3, o3) {
|
|
70
|
-
const i2 = o3.indexOf(n3.nodeId), c2 = f(t3.doc, n3.nodeId) ?? [];
|
|
71
|
-
if ("left" === e3 || "up" === e3) {
|
|
72
|
-
if (i2 > 0) {
|
|
73
|
-
const e4 = o3[i2 - 1];
|
|
74
|
-
if (!e4) return null;
|
|
75
|
-
if (s(t3, e4)) return t3.transaction("input").setSelection(h(n3.nodeId, "before", c2)).build();
|
|
76
|
-
const l2 = t3.getBlock(e4), d2 = l2 ? r(l2) : 0;
|
|
77
|
-
return t3.transaction("input").setSelection(k(e4, d2)).build();
|
|
78
|
-
}
|
|
79
|
-
return t3.transaction("input").setSelection(h(n3.nodeId, "before", c2)).build();
|
|
80
|
-
}
|
|
81
|
-
if (i2 < o3.length - 1) {
|
|
82
|
-
const e4 = o3[i2 + 1];
|
|
83
|
-
return e4 ? s(t3, e4) ? t3.transaction("input").setSelection(h(n3.nodeId, "after", c2)).build() : t3.transaction("input").setSelection(k(e4, 0)).build() : null;
|
|
84
|
-
}
|
|
85
|
-
return t3.transaction("input").setSelection(h(n3.nodeId, "after", c2)).build();
|
|
86
|
-
})(t2, e2, n2, o2) : I(e2) ? null : a(e2) ? (function(t3, n3, e3, o3) {
|
|
87
|
-
const i2 = o3.indexOf(n3.anchor.blockId), c2 = t3.getBlock(n3.anchor.blockId);
|
|
88
|
-
if (!c2) return null;
|
|
89
|
-
const l2 = r(c2);
|
|
90
|
-
if (("right" === e3 || "down" === e3) && n3.anchor.offset === l2 && i2 < o3.length - 1) {
|
|
91
|
-
const n4 = o3[i2 + 1];
|
|
92
|
-
if (n4 && s(t3, n4)) {
|
|
93
|
-
const e4 = f(t3.doc, n4) ?? [];
|
|
94
|
-
return t3.transaction("input").setSelection(m(n4, e4)).build();
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
if (("left" === e3 || "up" === e3) && 0 === n3.anchor.offset && i2 > 0) {
|
|
98
|
-
const n4 = o3[i2 - 1];
|
|
99
|
-
if (n4 && s(t3, n4)) {
|
|
100
|
-
const e4 = f(t3.doc, n4) ?? [];
|
|
101
|
-
return t3.transaction("input").setSelection(m(n4, e4)).build();
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
return null;
|
|
105
|
-
})(t2, e2, n2, o2) : null;
|
|
106
|
-
}
|
|
107
|
-
function j(t2, n2) {
|
|
108
|
-
if ("after" === n2.side) return M(t2, n2);
|
|
109
|
-
const e2 = t2.getBlockOrder(), o2 = e2.indexOf(n2.blockId);
|
|
110
|
-
if (o2 <= 0) return null;
|
|
111
|
-
const i2 = e2[o2 - 1];
|
|
112
|
-
if (!i2) return null;
|
|
113
|
-
if (s(t2, i2)) {
|
|
114
|
-
const n3 = f(t2.doc, i2) ?? [];
|
|
115
|
-
return t2.transaction("input").setSelection(m(i2, n3)).build();
|
|
116
|
-
}
|
|
117
|
-
const c2 = t2.getBlock(i2);
|
|
118
|
-
if (!c2) return null;
|
|
119
|
-
const l2 = r(c2);
|
|
120
|
-
return t2.transaction("input").setSelection(k(i2, l2)).build();
|
|
121
|
-
}
|
|
122
|
-
function y(t2, n2) {
|
|
123
|
-
if ("before" === n2.side) return M(t2, n2);
|
|
124
|
-
const e2 = t2.getBlockOrder(), o2 = e2.indexOf(n2.blockId);
|
|
125
|
-
if (o2 >= e2.length - 1) return null;
|
|
126
|
-
const r2 = e2[o2 + 1];
|
|
127
|
-
if (!r2) return null;
|
|
128
|
-
if (s(t2, r2)) {
|
|
129
|
-
const n3 = f(t2.doc, r2) ?? [];
|
|
130
|
-
return t2.transaction("input").setSelection(m(r2, n3)).build();
|
|
131
|
-
}
|
|
132
|
-
return t2.transaction("input").setSelection(k(r2, 0)).build();
|
|
133
|
-
}
|
|
134
|
-
function M(t2, n2) {
|
|
135
|
-
const e2 = f(t2.doc, n2.blockId) ?? [];
|
|
136
|
-
return T(t2, m(n2.blockId, e2));
|
|
137
|
-
}
|
|
138
|
-
function H(t2, n2, o2 = "input") {
|
|
139
|
-
const r2 = t2.selection;
|
|
140
|
-
if (g(r2)) return (function(t3, n3, o3, r3) {
|
|
141
|
-
const i3 = f(t3.doc, n3.nodeId), c2 = i3 && i3.length > 1 ? i3.slice(0, -1) : [], s3 = x(t3, c2), l3 = s3.findIndex((t4) => "id" in t4 && t4.id === n3.nodeId), d3 = e(), u2 = t3.transaction(r3), a2 = l3 >= 0 ? l3 + 1 : s3.length;
|
|
142
|
-
return u2.insertNode(c2, a2, O(d3)), u2.insertText(d3, 0, o3, []), u2.setSelection(k(d3, o3.length)), u2.build();
|
|
143
|
-
})(t2, r2, n2, o2);
|
|
144
|
-
if (I(r2)) return (function(t3, n3, o3, r3) {
|
|
145
|
-
const i3 = f(t3.doc, n3.blockId), c2 = i3 && i3.length > 1 ? i3.slice(0, -1) : [], s3 = x(t3, c2), l3 = s3.findIndex((t4) => "id" in t4 && t4.id === n3.blockId), d3 = "before" === n3.side ? Math.max(l3, 0) : l3 >= 0 ? l3 + 1 : s3.length, u2 = e(), a2 = t3.transaction(r3);
|
|
146
|
-
return a2.insertNode(c2, d3, O(u2)), a2.insertText(u2, 0, o3, []), a2.setSelection(k(u2, o3.length)), a2.build();
|
|
147
|
-
})(t2, r2, n2, o2);
|
|
148
|
-
const i2 = t2.transaction(o2), s2 = (function(t3) {
|
|
149
|
-
if (t3.storedMarks) return t3.storedMarks;
|
|
150
|
-
if (g(t3.selection) || I(t3.selection)) return [];
|
|
151
|
-
const n3 = t3.getBlock(t3.selection.anchor.blockId);
|
|
152
|
-
return n3 ? c(n3, t3.selection.anchor.offset) : [];
|
|
153
|
-
})(t2);
|
|
154
|
-
a(r2) || _(t2, i2);
|
|
155
|
-
const { blockId: l2, offset: d2 } = N(r2, t2.getBlockOrder());
|
|
156
|
-
return i2.insertText(l2, d2, n2, s2), i2.setSelection(k(l2, d2 + n2.length)), i2.build();
|
|
157
|
-
}
|
|
158
|
-
function v(t2) {
|
|
159
|
-
if (g(t2.selection)) return T(t2, t2.selection);
|
|
160
|
-
if (I(t2.selection)) return null;
|
|
161
|
-
if (a(t2.selection)) return null;
|
|
162
|
-
const n2 = t2.transaction("input");
|
|
163
|
-
_(t2, n2);
|
|
164
|
-
const e2 = b(t2.selection, t2.getBlockOrder());
|
|
165
|
-
return n2.setSelection(k(e2.from.blockId, e2.from.offset)), n2.build();
|
|
166
|
-
}
|
|
167
|
-
function C(t2) {
|
|
168
|
-
const n2 = t2.selection;
|
|
169
|
-
if (g(n2)) return (function(t3, n3) {
|
|
170
|
-
const o3 = f(t3.doc, n3.nodeId);
|
|
171
|
-
if (!o3) return null;
|
|
172
|
-
const r3 = o3.length > 1 ? o3.slice(0, -1) : [], i3 = x(t3, r3).findIndex((t4) => "id" in t4 && t4.id === n3.nodeId);
|
|
173
|
-
if (i3 < 0) return null;
|
|
174
|
-
const c3 = e(), s2 = t3.transaction("input");
|
|
175
|
-
return s2.insertNode(r3, i3 + 1, O(c3)), s2.setSelection(k(c3, 0)), s2.build();
|
|
176
|
-
})(t2, n2);
|
|
177
|
-
if (I(n2)) return (function(t3, n3) {
|
|
178
|
-
const o3 = f(t3.doc, n3.blockId);
|
|
179
|
-
if (!o3) return null;
|
|
180
|
-
const r3 = o3.length > 1 ? o3.slice(0, -1) : [], i3 = x(t3, r3).findIndex((t4) => "id" in t4 && t4.id === n3.blockId);
|
|
181
|
-
if (i3 < 0) return null;
|
|
182
|
-
const c3 = "before" === n3.side ? i3 : i3 + 1, s2 = e(), l2 = t3.transaction("input");
|
|
183
|
-
return l2.insertNode(r3, c3, O(s2)), l2.setSelection(k(s2, 0)), l2.build();
|
|
184
|
-
})(t2, n2);
|
|
185
|
-
const o2 = t2.transaction("input");
|
|
186
|
-
a(n2) || _(t2, o2);
|
|
187
|
-
const { blockId: r2, offset: i2 } = N(n2, t2.getBlockOrder()), c2 = e();
|
|
188
|
-
return o2.splitBlock(r2, i2, c2), o2.setSelection(k(c2, 0)), o2.build();
|
|
189
|
-
}
|
|
190
|
-
function K(t2) {
|
|
191
|
-
const n2 = t2.selection;
|
|
192
|
-
if (g(n2) || I(n2)) return null;
|
|
193
|
-
const e2 = t2.transaction("input");
|
|
194
|
-
a(n2) || _(t2, e2);
|
|
195
|
-
const { blockId: o2, offset: r2 } = N(n2, t2.getBlockOrder()), c2 = i(B("hard_break"));
|
|
196
|
-
return e2.insertInlineNode(o2, r2, c2), e2.setSelection(k(o2, r2 + 1)), e2.build();
|
|
197
|
-
}
|
|
198
|
-
function D(t2) {
|
|
199
|
-
const n2 = t2.selection;
|
|
200
|
-
if (g(n2) || I(n2)) return null;
|
|
201
|
-
const e2 = t2.getBlockOrder(), o2 = e2.indexOf(n2.anchor.blockId);
|
|
202
|
-
if (o2 <= 0) return null;
|
|
203
|
-
const i2 = e2[o2 - 1];
|
|
204
|
-
if (!i2) return null;
|
|
205
|
-
if (l(t2, n2.anchor.blockId) || l(t2, i2)) return null;
|
|
206
|
-
if (!d(t2, n2.anchor.blockId, i2) && u(t2, n2.anchor.blockId)) return null;
|
|
207
|
-
if (s(t2, i2)) {
|
|
208
|
-
const n3 = f(t2.doc, i2) ?? [];
|
|
209
|
-
return t2.transaction("input").setSelection(m(i2, n3)).build();
|
|
210
|
-
}
|
|
211
|
-
const c2 = t2.getBlock(i2);
|
|
212
|
-
if (!c2) return null;
|
|
213
|
-
const a2 = r(c2);
|
|
214
|
-
return t2.transaction("input").mergeBlocksAt(i2, n2.anchor.blockId).setSelection(k(i2, a2)).build();
|
|
215
|
-
}
|
|
216
|
-
function E(t2) {
|
|
217
|
-
const n2 = t2.selection;
|
|
218
|
-
if (g(n2) || I(n2)) return null;
|
|
219
|
-
const e2 = t2.getBlockOrder(), o2 = e2.indexOf(n2.anchor.blockId);
|
|
220
|
-
if (o2 >= e2.length - 1) return null;
|
|
221
|
-
const r2 = e2[o2 + 1];
|
|
222
|
-
if (!r2) return null;
|
|
223
|
-
if (l(t2, n2.anchor.blockId) || l(t2, r2)) return null;
|
|
224
|
-
if (!d(t2, n2.anchor.blockId, r2) && u(t2, n2.anchor.blockId)) return null;
|
|
225
|
-
if (s(t2, r2)) {
|
|
226
|
-
const n3 = f(t2.doc, r2) ?? [];
|
|
227
|
-
return t2.transaction("input").setSelection(m(r2, n3)).build();
|
|
228
|
-
}
|
|
229
|
-
return t2.transaction("input").mergeBlocksAt(n2.anchor.blockId, r2).setSelection(k(n2.anchor.blockId, n2.anchor.offset)).build();
|
|
230
|
-
}
|
|
231
|
-
function L(t2) {
|
|
232
|
-
const n2 = t2.doc.children, e2 = n2[0], o2 = n2[n2.length - 1];
|
|
233
|
-
if (!e2 || !o2) return t2.transaction("command").setSelection(t2.selection).build();
|
|
234
|
-
const i2 = r(o2);
|
|
235
|
-
return t2.transaction("command").setSelection(p({ blockId: e2.id, offset: 0 }, { blockId: o2.id, offset: i2 })).build();
|
|
236
|
-
}
|
|
237
|
-
function _(t2, n2) {
|
|
238
|
-
if (g(t2.selection) || I(t2.selection)) return;
|
|
239
|
-
const e2 = t2.getBlockOrder(), o2 = b(t2.selection, e2), i2 = e2.indexOf(o2.from.blockId), c2 = e2.indexOf(o2.to.blockId);
|
|
240
|
-
if (i2 === c2) n2.deleteTextAt(o2.from.blockId, o2.from.offset, o2.to.offset);
|
|
241
|
-
else {
|
|
242
|
-
const s2 = t2.getBlock(o2.from.blockId);
|
|
243
|
-
if (!s2) return;
|
|
244
|
-
const l2 = r(s2);
|
|
245
|
-
o2.from.offset < l2 && n2.deleteTextAt(o2.from.blockId, o2.from.offset, l2), o2.to.offset > 0 && n2.deleteTextAt(o2.to.blockId, 0, o2.to.offset);
|
|
246
|
-
for (let s3 = i2 + 1; s3 < c2; s3++) {
|
|
247
|
-
const i3 = e2[s3];
|
|
248
|
-
if (!i3) continue;
|
|
249
|
-
const c3 = t2.getBlock(i3);
|
|
250
|
-
if (!c3) continue;
|
|
251
|
-
const l3 = r(c3);
|
|
252
|
-
l3 > 0 && n2.deleteTextAt(i3, 0, l3), n2.mergeBlocksAt(o2.from.blockId, i3);
|
|
253
|
-
}
|
|
254
|
-
n2.mergeBlocksAt(o2.from.blockId, o2.to.blockId);
|
|
255
|
-
}
|
|
256
|
-
}
|
|
257
|
-
class w {
|
|
258
|
-
id = "hard-break";
|
|
259
|
-
name = "Hard Break";
|
|
260
|
-
priority = 10;
|
|
261
|
-
init(t2) {
|
|
262
|
-
this.registerInlineNodeSpec(t2), this.registerCommands(t2), this.registerKeymap(t2);
|
|
263
|
-
}
|
|
264
|
-
registerInlineNodeSpec(t2) {
|
|
265
|
-
t2.registerInlineNodeSpec({ type: "hard_break", toDOM: () => document.createElement("br"), toHTMLString: () => "<br>", parseHTML: [{ tag: "br" }], sanitize: { tags: ["br"] } });
|
|
266
|
-
}
|
|
267
|
-
registerCommands(t2) {
|
|
268
|
-
t2.registerCommand("insertHardBreak", () => {
|
|
269
|
-
const n2 = K(t2.getState());
|
|
270
|
-
return !!n2 && (t2.dispatch(n2), true);
|
|
271
|
-
});
|
|
272
|
-
}
|
|
273
|
-
registerKeymap(t2) {
|
|
274
|
-
t2.registerKeymap({ "Shift-Enter": () => {
|
|
275
|
-
const n2 = K(t2.getState());
|
|
276
|
-
return !!n2 && (t2.dispatch(n2), true);
|
|
277
|
-
} });
|
|
278
|
-
}
|
|
279
|
-
}
|
|
280
|
-
export {
|
|
281
|
-
w as H,
|
|
282
|
-
v as a,
|
|
283
|
-
D as b,
|
|
284
|
-
C as c,
|
|
285
|
-
T as d,
|
|
286
|
-
j as e,
|
|
287
|
-
y as f,
|
|
288
|
-
K as g,
|
|
289
|
-
_ as h,
|
|
290
|
-
H as i,
|
|
291
|
-
E as m,
|
|
292
|
-
A as n,
|
|
293
|
-
N as r,
|
|
294
|
-
L as s
|
|
295
|
-
};
|
|
296
|
-
//# sourceMappingURL=index-ErZ5_a1o.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index-ErZ5_a1o.mjs","sources":["../../src/commands/CommandHelpers.ts","../../src/commands/NodeSelectionCommands.ts","../../src/commands/GapCursorCommands.ts","../../src/commands/Commands.ts","../../src/plugins/hard-break/HardBreakPlugin.ts"],"sourcesContent":["/**\n * Shared helpers used across multiple command modules.\n *\n * - {@link getSiblings} — resolves a parent path to its child list\n * - {@link createEmptyParagraph} — builds an empty paragraph BlockNode\n * - {@link resolveInsertPoint} — normalizes a text selection to a single insert position\n */\n\nimport type { BlockNode, ChildNode } from '../model/Document.js';\nimport { createBlockNode, createTextNode } from '../model/Document.js';\nimport { isCollapsed, selectionRange } from '../model/Selection.js';\nimport type { Selection } from '../model/Selection.js';\nimport type { BlockId } from '../model/TypeBrands.js';\nimport { nodeType } from '../model/TypeBrands.js';\nimport type { EditorState } from '../state/EditorState.js';\n\n/** The resolved insert position within a single block. */\nexport interface InsertPoint {\n\treadonly blockId: BlockId;\n\treadonly offset: number;\n}\n\n/** Resolves the children of a parent path: doc root or a nested block. */\nexport function getSiblings(\n\tstate: EditorState,\n\tparentPath: readonly BlockId[],\n): readonly ChildNode[] {\n\tif (parentPath.length === 0) return state.doc.children;\n\tconst parent: BlockNode | undefined = state.getBlock(\n\t\tparentPath[parentPath.length - 1] as BlockId,\n\t);\n\treturn parent ? parent.children : [];\n}\n\n/** Creates an empty paragraph block node with the given ID. */\nexport function createEmptyParagraph(id: BlockId): BlockNode {\n\treturn createBlockNode(nodeType('paragraph'), [createTextNode('')], id);\n}\n\n/**\n * Normalizes a text selection to a single insert point.\n *\n * - Collapsed selection → anchor position.\n * - Range selection → normalized `from` position (document-order start).\n */\nexport function resolveInsertPoint(sel: Selection, blockOrder: readonly BlockId[]): InsertPoint {\n\tif (isCollapsed(sel)) {\n\t\treturn { blockId: sel.anchor.blockId, offset: sel.anchor.offset };\n\t}\n\tconst range = selectionRange(sel, blockOrder);\n\treturn { blockId: range.from.blockId, offset: range.from.offset };\n}\n","/**\n * Commands for NodeSelection: deleting void blocks, inserting paragraphs\n * after void blocks, and navigating arrow keys into/out of void blocks.\n */\n\nimport { type BlockNode, generateBlockId, getBlockLength, isBlockNode } from '../model/Document.js';\nimport { isVoidBlock } from '../model/NavigationUtils.js';\nimport { findNodePath } from '../model/NodeResolver.js';\nimport type { NodeSelection } from '../model/Selection.js';\nimport {\n\tcreateCollapsedSelection,\n\tcreateGapCursor,\n\tcreateNodeSelection,\n\tisCollapsed,\n\tisGapCursor,\n\tisNodeSelection,\n} from '../model/Selection.js';\nimport type { BlockId } from '../model/TypeBrands.js';\nimport type { EditorState } from '../state/EditorState.js';\nimport type { Transaction } from '../state/Transaction.js';\nimport { createEmptyParagraph, getSiblings } from './CommandHelpers.js';\n\n/**\n * Deletes the void block targeted by a NodeSelection and places cursor\n * on the adjacent block. If it's the only block, replaces with empty paragraph.\n */\nexport function deleteNodeSelection(state: EditorState, sel: NodeSelection): Transaction | null {\n\tconst path = findNodePath(state.doc, sel.nodeId);\n\tif (!path) return null;\n\n\tconst parentPath: BlockId[] = path.length > 1 ? (path.slice(0, -1) as BlockId[]) : [];\n\tconst siblings = getSiblings(state, parentPath);\n\n\tconst index: number = siblings.findIndex((c) => 'id' in c && c.id === sel.nodeId);\n\tif (index < 0) return null;\n\n\tconst builder = state.transaction('input');\n\n\t// If this is the only block in the document, insert empty paragraph first\n\tif (siblings.length === 1 && parentPath.length === 0) {\n\t\tconst newId = generateBlockId();\n\t\tbuilder.insertNode(parentPath, 0, createEmptyParagraph(newId));\n\t\tbuilder.removeNode(parentPath, 1);\n\t\tbuilder.setSelection(createCollapsedSelection(newId, 0));\n\t\treturn builder.build();\n\t}\n\n\tbuilder.removeNode(parentPath, index);\n\n\t// Find where to place cursor: prefer previous sibling leaf, else next sibling leaf.\n\tconst prevSibling = siblings[index - 1];\n\tif (prevSibling && isBlockNode(prevSibling)) {\n\t\tconst prevLeafId = findLastLeafBlockId(prevSibling);\n\t\tif (prevLeafId) {\n\t\t\tconst prevLeaf = state.getBlock(prevLeafId);\n\t\t\tconst prevLen = prevLeaf ? getBlockLength(prevLeaf) : 0;\n\t\t\tbuilder.setSelection(createCollapsedSelection(prevLeafId, prevLen));\n\t\t}\n\t} else {\n\t\tconst nextSibling = siblings[index + 1];\n\t\tif (nextSibling && isBlockNode(nextSibling)) {\n\t\t\tconst nextLeafId = findFirstLeafBlockId(nextSibling);\n\t\t\tif (nextLeafId) {\n\t\t\t\tbuilder.setSelection(createCollapsedSelection(nextLeafId, 0));\n\t\t\t}\n\t\t}\n\t}\n\n\treturn builder.build();\n}\n\n/** Inserts a new paragraph after a NodeSelection-targeted void block. */\nexport function insertParagraphAfterNodeSelection(\n\tstate: EditorState,\n\tsel: NodeSelection,\n): Transaction | null {\n\tconst path = findNodePath(state.doc, sel.nodeId);\n\tif (!path) return null;\n\n\tconst parentPath: BlockId[] = path.length > 1 ? (path.slice(0, -1) as BlockId[]) : [];\n\tconst siblings = getSiblings(state, parentPath);\n\n\tconst index: number = siblings.findIndex((c) => 'id' in c && c.id === sel.nodeId);\n\tif (index < 0) return null;\n\n\tconst newId = generateBlockId();\n\tconst builder = state.transaction('input');\n\tbuilder.insertNode(parentPath, index + 1, createEmptyParagraph(newId));\n\tbuilder.setSelection(createCollapsedSelection(newId, 0));\n\treturn builder.build();\n}\n\n/** Inserts text in a new paragraph after a NodeSelection-targeted void block. */\nexport function insertTextAfterNodeSelection(\n\tstate: EditorState,\n\tsel: NodeSelection,\n\ttext: string,\n\torigin: 'input' | 'paste',\n): Transaction {\n\tconst path = findNodePath(state.doc, sel.nodeId);\n\tconst parentPath: BlockId[] = path && path.length > 1 ? (path.slice(0, -1) as BlockId[]) : [];\n\tconst siblings = getSiblings(state, parentPath);\n\n\tconst index: number = siblings.findIndex((c) => 'id' in c && c.id === sel.nodeId);\n\n\tconst newId = generateBlockId();\n\tconst builder = state.transaction(origin);\n\n\tconst insertIdx = index >= 0 ? index + 1 : siblings.length;\n\tbuilder.insertNode(parentPath, insertIdx, createEmptyParagraph(newId));\n\tbuilder.insertText(newId, 0, text, []);\n\tbuilder.setSelection(createCollapsedSelection(newId, text.length));\n\treturn builder.build();\n}\n\n/**\n * Navigates arrow keys into/out of void blocks.\n * Returns a transaction if navigation should create a NodeSelection, or null.\n */\nexport function navigateArrowIntoVoid(\n\tstate: EditorState,\n\tdirection: 'left' | 'right' | 'up' | 'down',\n): Transaction | null {\n\tconst sel = state.selection;\n\tconst blockOrder = state.getBlockOrder();\n\n\t// If currently on a NodeSelection, navigate away from it\n\tif (isNodeSelection(sel)) {\n\t\treturn navigateAwayFromNodeSelection(state, sel, direction, blockOrder);\n\t}\n\n\t// GapCursor is handled by navigateFromGapCursor in CaretNavigation\n\tif (isGapCursor(sel)) return null;\n\n\t// Text selection: check if navigating into a void block\n\tif (!isCollapsed(sel)) return null;\n\n\treturn navigateIntoVoid(state, sel, direction, blockOrder);\n}\n\n/** Finds the first leaf (deepest-first-child) block ID in a subtree. */\nexport function findFirstLeafBlockId(node: BlockNode): BlockId {\n\tlet current: BlockNode = node;\n\twhile (true) {\n\t\tconst firstBlockChild = current.children.find((child): child is BlockNode =>\n\t\t\tisBlockNode(child),\n\t\t);\n\t\tif (!firstBlockChild) return current.id;\n\t\tcurrent = firstBlockChild;\n\t}\n}\n\n/** Finds the last leaf (deepest-last-child) block ID in a subtree. */\nexport function findLastLeafBlockId(node: BlockNode): BlockId {\n\tlet current: BlockNode = node;\n\twhile (true) {\n\t\tlet lastBlockChild: BlockNode | undefined;\n\t\tfor (let i = current.children.length - 1; i >= 0; i--) {\n\t\t\tconst child = current.children[i];\n\t\t\tif (child && isBlockNode(child)) {\n\t\t\t\tlastBlockChild = child;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\tif (!lastBlockChild) return current.id;\n\t\tcurrent = lastBlockChild;\n\t}\n}\n\n// ---------------------------------------------------------------------------\n// Internal helpers\n// ---------------------------------------------------------------------------\n\n/** Handles navigation away from a NodeSelection (arrow keys while void is selected). */\nfunction navigateAwayFromNodeSelection(\n\tstate: EditorState,\n\tsel: NodeSelection,\n\tdirection: 'left' | 'right' | 'up' | 'down',\n\tblockOrder: readonly BlockId[],\n): Transaction | null {\n\tconst nodeIdx = blockOrder.indexOf(sel.nodeId);\n\tconst nodePath = (findNodePath(state.doc, sel.nodeId) ?? []) as BlockId[];\n\n\tif (direction === 'left' || direction === 'up') {\n\t\tif (nodeIdx > 0) {\n\t\t\tconst prevId = blockOrder[nodeIdx - 1];\n\t\t\tif (!prevId) return null;\n\t\t\tif (isVoidBlock(state, prevId)) {\n\t\t\t\treturn state\n\t\t\t\t\t.transaction('input')\n\t\t\t\t\t.setSelection(createGapCursor(sel.nodeId, 'before', nodePath))\n\t\t\t\t\t.build();\n\t\t\t}\n\t\t\tconst prevBlock = state.getBlock(prevId);\n\t\t\tconst prevLen = prevBlock ? getBlockLength(prevBlock) : 0;\n\t\t\treturn state\n\t\t\t\t.transaction('input')\n\t\t\t\t.setSelection(createCollapsedSelection(prevId, prevLen))\n\t\t\t\t.build();\n\t\t}\n\t\treturn state\n\t\t\t.transaction('input')\n\t\t\t.setSelection(createGapCursor(sel.nodeId, 'before', nodePath))\n\t\t\t.build();\n\t}\n\n\t// right or down\n\tif (nodeIdx < blockOrder.length - 1) {\n\t\tconst nextId = blockOrder[nodeIdx + 1];\n\t\tif (!nextId) return null;\n\t\tif (isVoidBlock(state, nextId)) {\n\t\t\treturn state\n\t\t\t\t.transaction('input')\n\t\t\t\t.setSelection(createGapCursor(sel.nodeId, 'after', nodePath))\n\t\t\t\t.build();\n\t\t}\n\t\treturn state.transaction('input').setSelection(createCollapsedSelection(nextId, 0)).build();\n\t}\n\treturn state\n\t\t.transaction('input')\n\t\t.setSelection(createGapCursor(sel.nodeId, 'after', nodePath))\n\t\t.build();\n}\n\n/** Handles text selection navigating into an adjacent void block. */\nfunction navigateIntoVoid(\n\tstate: EditorState,\n\tsel: { readonly anchor: { readonly blockId: BlockId; readonly offset: number } },\n\tdirection: 'left' | 'right' | 'up' | 'down',\n\tblockOrder: readonly BlockId[],\n): Transaction | null {\n\tconst blockIdx = blockOrder.indexOf(sel.anchor.blockId);\n\tconst block = state.getBlock(sel.anchor.blockId);\n\tif (!block) return null;\n\tconst blockLen = getBlockLength(block);\n\n\tif (direction === 'right' || direction === 'down') {\n\t\tif (sel.anchor.offset === blockLen && blockIdx < blockOrder.length - 1) {\n\t\t\tconst nextId = blockOrder[blockIdx + 1];\n\t\t\tif (nextId && isVoidBlock(state, nextId)) {\n\t\t\t\tconst path = findNodePath(state.doc, nextId) ?? [];\n\t\t\t\treturn state\n\t\t\t\t\t.transaction('input')\n\t\t\t\t\t.setSelection(createNodeSelection(nextId, path as BlockId[]))\n\t\t\t\t\t.build();\n\t\t\t}\n\t\t}\n\t}\n\n\tif (direction === 'left' || direction === 'up') {\n\t\tif (sel.anchor.offset === 0 && blockIdx > 0) {\n\t\t\tconst prevId = blockOrder[blockIdx - 1];\n\t\t\tif (prevId && isVoidBlock(state, prevId)) {\n\t\t\t\tconst path = findNodePath(state.doc, prevId) ?? [];\n\t\t\t\treturn state\n\t\t\t\t\t.transaction('input')\n\t\t\t\t\t.setSelection(createNodeSelection(prevId, path as BlockId[]))\n\t\t\t\t\t.build();\n\t\t\t}\n\t\t}\n\t}\n\n\treturn null;\n}\n","/**\n * Commands for GapCursor: deleting void blocks adjacent to gap cursors\n * and inserting paragraphs at gap positions.\n */\n\nimport { generateBlockId, getBlockLength } from '../model/Document.js';\nimport { isVoidBlock } from '../model/NavigationUtils.js';\nimport { findNodePath } from '../model/NodeResolver.js';\nimport type { GapCursorSelection, NodeSelection } from '../model/Selection.js';\nimport { createCollapsedSelection, createNodeSelection } from '../model/Selection.js';\nimport type { BlockId } from '../model/TypeBrands.js';\nimport type { EditorState } from '../state/EditorState.js';\nimport type { Transaction } from '../state/Transaction.js';\nimport { createEmptyParagraph, getSiblings } from './CommandHelpers.js';\nimport { deleteNodeSelection } from './NodeSelectionCommands.js';\n\n/**\n * Deletes the void block adjacent to a GapCursor when pressing Backspace.\n *\n * - `side === 'after'` → void block is behind the cursor → delete it.\n * - `side === 'before'` → void block is ahead → navigate backward (to previous block).\n * - At document start with `side === 'before'` → `null` (no-op).\n */\nexport function deleteBackwardAtGap(\n\tstate: EditorState,\n\tsel: GapCursorSelection,\n): Transaction | null {\n\tif (sel.side === 'after') {\n\t\treturn deleteVoidAtGap(state, sel);\n\t}\n\n\t// side === 'before': navigate to previous block\n\tconst blockOrder: readonly BlockId[] = state.getBlockOrder();\n\tconst blockIdx: number = blockOrder.indexOf(sel.blockId);\n\n\tif (blockIdx <= 0) return null;\n\n\tconst prevId: BlockId | undefined = blockOrder[blockIdx - 1];\n\tif (!prevId) return null;\n\n\tif (isVoidBlock(state, prevId)) {\n\t\tconst path = findNodePath(state.doc, prevId) ?? [];\n\t\treturn state\n\t\t\t.transaction('input')\n\t\t\t.setSelection(createNodeSelection(prevId, path as BlockId[]))\n\t\t\t.build();\n\t}\n\n\tconst prevBlock = state.getBlock(prevId);\n\tif (!prevBlock) return null;\n\tconst prevLen: number = getBlockLength(prevBlock);\n\treturn state.transaction('input').setSelection(createCollapsedSelection(prevId, prevLen)).build();\n}\n\n/**\n * Deletes the void block adjacent to a GapCursor when pressing Delete.\n *\n * - `side === 'before'` → void block is ahead of the cursor → delete it.\n * - `side === 'after'` → void block is behind → navigate forward (to next block).\n * - At document end with `side === 'after'` → `null` (no-op).\n */\nexport function deleteForwardAtGap(\n\tstate: EditorState,\n\tsel: GapCursorSelection,\n): Transaction | null {\n\tif (sel.side === 'before') {\n\t\treturn deleteVoidAtGap(state, sel);\n\t}\n\n\t// side === 'after': navigate to next block\n\tconst blockOrder: readonly BlockId[] = state.getBlockOrder();\n\tconst blockIdx: number = blockOrder.indexOf(sel.blockId);\n\n\tif (blockIdx >= blockOrder.length - 1) return null;\n\n\tconst nextId: BlockId | undefined = blockOrder[blockIdx + 1];\n\tif (!nextId) return null;\n\n\tif (isVoidBlock(state, nextId)) {\n\t\tconst path = findNodePath(state.doc, nextId) ?? [];\n\t\treturn state\n\t\t\t.transaction('input')\n\t\t\t.setSelection(createNodeSelection(nextId, path as BlockId[]))\n\t\t\t.build();\n\t}\n\n\treturn state.transaction('input').setSelection(createCollapsedSelection(nextId, 0)).build();\n}\n\n/** Deletes the void block that the GapCursor is adjacent to, delegating to deleteNodeSelection. */\nfunction deleteVoidAtGap(state: EditorState, sel: GapCursorSelection): Transaction | null {\n\tconst path = (findNodePath(state.doc, sel.blockId) ?? []) as BlockId[];\n\tconst nodeSel: NodeSelection = createNodeSelection(sel.blockId, path);\n\treturn deleteNodeSelection(state, nodeSel);\n}\n\n/** Inserts a new paragraph at a GapCursor position (before or after the void block). */\nexport function insertParagraphAtGap(\n\tstate: EditorState,\n\tsel: GapCursorSelection,\n): Transaction | null {\n\tconst path = findNodePath(state.doc, sel.blockId);\n\tif (!path) return null;\n\n\tconst parentPath: BlockId[] = path.length > 1 ? (path.slice(0, -1) as BlockId[]) : [];\n\tconst siblings = getSiblings(state, parentPath);\n\n\tconst index: number = siblings.findIndex((c) => 'id' in c && c.id === sel.blockId);\n\tif (index < 0) return null;\n\n\tconst insertIdx: number = sel.side === 'before' ? index : index + 1;\n\tconst newId = generateBlockId();\n\tconst builder = state.transaction('input');\n\tbuilder.insertNode(parentPath, insertIdx, createEmptyParagraph(newId));\n\tbuilder.setSelection(createCollapsedSelection(newId, 0));\n\treturn builder.build();\n}\n\n/** Inserts text in a new paragraph at a GapCursor position. */\nexport function insertTextAtGap(\n\tstate: EditorState,\n\tsel: GapCursorSelection,\n\ttext: string,\n\torigin: 'input' | 'paste',\n): Transaction {\n\tconst path = findNodePath(state.doc, sel.blockId);\n\tconst parentPath: BlockId[] = path && path.length > 1 ? (path.slice(0, -1) as BlockId[]) : [];\n\tconst siblings = getSiblings(state, parentPath);\n\n\tconst index: number = siblings.findIndex((c) => 'id' in c && c.id === sel.blockId);\n\tconst insertIdx: number =\n\t\tsel.side === 'before' ? Math.max(index, 0) : index >= 0 ? index + 1 : siblings.length;\n\n\tconst newId = generateBlockId();\n\tconst builder = state.transaction(origin);\n\tbuilder.insertNode(parentPath, insertIdx, createEmptyParagraph(newId));\n\tbuilder.insertText(newId, 0, text, []);\n\tbuilder.setSelection(createCollapsedSelection(newId, text.length));\n\treturn builder.build();\n}\n","/**\n * Core editor commands and barrel re-exports from submodules.\n *\n * This module contains text insertion, block splitting, block merging,\n * selection deletion, and select-all. Mark, delete, gap-cursor, node-selection,\n * and word-boundary commands are re-exported from their respective modules.\n */\n\nimport {\n\ttype Mark,\n\tcreateInlineNode,\n\tgenerateBlockId,\n\tgetBlockLength,\n\tgetBlockMarksAtOffset,\n} from '../model/Document.js';\nimport {\n\tisInsideIsolating,\n\tisIsolatingBlock,\n\tisVoidBlock,\n\tsharesParent,\n} from '../model/NavigationUtils.js';\nimport { findNodePath } from '../model/NodeResolver.js';\nimport {\n\tcreateCollapsedSelection,\n\tcreateNodeSelection,\n\tcreateSelection,\n\tisCollapsed,\n\tisGapCursor,\n\tisNodeSelection,\n\tselectionRange,\n} from '../model/Selection.js';\nimport { type BlockId, inlineType } from '../model/TypeBrands.js';\nimport type { EditorState } from '../state/EditorState.js';\nimport type { Transaction } from '../state/Transaction.js';\nimport type { TransactionBuilder } from '../state/Transaction.js';\nimport { resolveInsertPoint } from './CommandHelpers.js';\nimport { insertParagraphAtGap, insertTextAtGap } from './GapCursorCommands.js';\nimport {\n\tdeleteNodeSelection,\n\tinsertParagraphAfterNodeSelection,\n\tinsertTextAfterNodeSelection,\n} from './NodeSelectionCommands.js';\n\n// --- Re-exports from submodules ---\n\nexport {\n\tcanCrossBlockBoundary,\n\tisInsideIsolating,\n\tisIsolatingBlock,\n\tisVoidBlock,\n\tsharesParent,\n} from '../model/NavigationUtils.js';\n\nexport type { FeatureConfig } from './MarkCommands.js';\nexport {\n\tisMarkActive,\n\ttoggleBold,\n\ttoggleItalic,\n\ttoggleMark,\n\ttoggleUnderline,\n} from './MarkCommands.js';\n\nexport {\n\tdeleteBackward,\n\tdeleteForward,\n\tdeleteSoftLineBackward,\n\tdeleteSoftLineForward,\n\tdeleteWordBackward,\n\tdeleteWordForward,\n} from './DeleteCommands.js';\n\nexport {\n\tdeleteNodeSelection,\n\tfindFirstLeafBlockId,\n\tfindLastLeafBlockId,\n\tinsertParagraphAfterNodeSelection,\n\tinsertTextAfterNodeSelection,\n\tnavigateArrowIntoVoid,\n} from './NodeSelectionCommands.js';\n\nexport {\n\tdeleteBackwardAtGap,\n\tdeleteForwardAtGap,\n\tinsertParagraphAtGap,\n\tinsertTextAtGap,\n} from './GapCursorCommands.js';\n\nexport {\n\tfindWordBoundaryBackward,\n\tfindWordBoundaryForward,\n} from './WordBoundary.js';\n\nexport {\n\tapplyAttributedMark,\n\tgetMarkAttrAtSelection,\n\tisAttributedMarkActive,\n\tremoveAttributedMark,\n} from './AttributedMarkCommands.js';\n\nexport { forEachBlockInRange } from './RangeIterator.js';\n\n// --- Text Commands ---\n\n/** Inserts text at the current selection, replacing any selected range. */\nexport function insertTextCommand(\n\tstate: EditorState,\n\ttext: string,\n\torigin: 'input' | 'paste' = 'input',\n): Transaction {\n\tconst sel = state.selection;\n\n\t// NodeSelection: insert paragraph after void block with the text\n\tif (isNodeSelection(sel)) {\n\t\treturn insertTextAfterNodeSelection(state, sel, text, origin);\n\t}\n\n\t// GapCursor: insert paragraph at the gap position with the text\n\tif (isGapCursor(sel)) {\n\t\treturn insertTextAtGap(state, sel, text, origin);\n\t}\n\n\tconst builder = state.transaction(origin);\n\tconst marks = resolveActiveMarks(state);\n\n\tif (!isCollapsed(sel)) {\n\t\taddDeleteSelectionSteps(state, builder);\n\t}\n\n\tconst { blockId: insertBlockId, offset: insertOffset } = resolveInsertPoint(\n\t\tsel,\n\t\tstate.getBlockOrder(),\n\t);\n\n\tbuilder.insertText(insertBlockId, insertOffset, text, marks);\n\tbuilder.setSelection(createCollapsedSelection(insertBlockId, insertOffset + text.length));\n\n\treturn builder.build();\n}\n\n/** Deletes the current selection. */\nexport function deleteSelectionCommand(state: EditorState): Transaction | null {\n\tif (isNodeSelection(state.selection)) {\n\t\treturn deleteNodeSelection(state, state.selection);\n\t}\n\tif (isGapCursor(state.selection)) return null;\n\tif (isCollapsed(state.selection)) return null;\n\n\tconst builder = state.transaction('input');\n\taddDeleteSelectionSteps(state, builder);\n\n\tconst range = selectionRange(state.selection, state.getBlockOrder());\n\tbuilder.setSelection(createCollapsedSelection(range.from.blockId, range.from.offset));\n\n\treturn builder.build();\n}\n\n/** Splits the current block at the cursor position (Enter key). */\nexport function splitBlockCommand(state: EditorState): Transaction | null {\n\tconst sel = state.selection;\n\n\t// NodeSelection: insert empty paragraph after the void block\n\tif (isNodeSelection(sel)) {\n\t\treturn insertParagraphAfterNodeSelection(state, sel);\n\t}\n\n\t// GapCursor: insert empty paragraph at the gap position\n\tif (isGapCursor(sel)) {\n\t\treturn insertParagraphAtGap(state, sel);\n\t}\n\n\tconst builder = state.transaction('input');\n\n\tif (!isCollapsed(sel)) {\n\t\taddDeleteSelectionSteps(state, builder);\n\t}\n\n\tconst { blockId, offset } = resolveInsertPoint(sel, state.getBlockOrder());\n\tconst newBlockId = generateBlockId();\n\n\t// splitBlock operates at the same level in the tree — the StepApplication\n\t// handles this correctly because it looks up the block by ID recursively.\n\tbuilder.splitBlock(blockId, offset, newBlockId);\n\tbuilder.setSelection(createCollapsedSelection(newBlockId, 0));\n\n\treturn builder.build();\n}\n\n/** Inserts a hard line break (InlineNode) at the current cursor position. */\nexport function insertHardBreakCommand(state: EditorState): Transaction | null {\n\tconst sel = state.selection;\n\n\tif (isNodeSelection(sel) || isGapCursor(sel)) return null;\n\n\tconst builder = state.transaction('input');\n\n\tif (!isCollapsed(sel)) {\n\t\taddDeleteSelectionSteps(state, builder);\n\t}\n\n\tconst { blockId: insertBlockId, offset: insertOffset } = resolveInsertPoint(\n\t\tsel,\n\t\tstate.getBlockOrder(),\n\t);\n\n\tconst hardBreak = createInlineNode(inlineType('hard_break'));\n\tbuilder.insertInlineNode(insertBlockId, insertOffset, hardBreak);\n\tbuilder.setSelection(createCollapsedSelection(insertBlockId, insertOffset + 1));\n\n\treturn builder.build();\n}\n\n/**\n * Merges the current block with the previous block, respecting\n * isolating boundaries and void blocks.\n */\nexport function mergeBlockBackward(state: EditorState): Transaction | null {\n\tconst sel = state.selection;\n\tif (isNodeSelection(sel) || isGapCursor(sel)) return null;\n\tconst blockOrder = state.getBlockOrder();\n\tconst blockIdx = blockOrder.indexOf(sel.anchor.blockId);\n\n\tif (blockIdx <= 0) return null;\n\n\tconst prevBlockId = blockOrder[blockIdx - 1];\n\tif (!prevBlockId) return null;\n\n\t// Never merge isolating blocks directly (e.g. table cells).\n\tif (isIsolatingBlock(state, sel.anchor.blockId) || isIsolatingBlock(state, prevBlockId)) {\n\t\treturn null;\n\t}\n\n\t// Prevent merge across isolating boundaries\n\tif (!sharesParent(state, sel.anchor.blockId, prevBlockId)) {\n\t\tif (isInsideIsolating(state, sel.anchor.blockId)) return null;\n\t}\n\n\t// If previous block is void, select it instead of merging\n\tif (isVoidBlock(state, prevBlockId)) {\n\t\tconst path = findNodePath(state.doc, prevBlockId) ?? [];\n\t\treturn state\n\t\t\t.transaction('input')\n\t\t\t.setSelection(createNodeSelection(prevBlockId, path as BlockId[]))\n\t\t\t.build();\n\t}\n\n\tconst prevBlock = state.getBlock(prevBlockId);\n\tif (!prevBlock) return null;\n\tconst prevLen = getBlockLength(prevBlock);\n\n\treturn state\n\t\t.transaction('input')\n\t\t.mergeBlocksAt(prevBlockId, sel.anchor.blockId)\n\t\t.setSelection(createCollapsedSelection(prevBlockId, prevLen))\n\t\t.build();\n}\n\n/**\n * Merges the next block into the current block, respecting\n * isolating boundaries and void blocks.\n */\nexport function mergeBlockForward(state: EditorState): Transaction | null {\n\tconst sel = state.selection;\n\tif (isNodeSelection(sel) || isGapCursor(sel)) return null;\n\tconst blockOrder = state.getBlockOrder();\n\tconst blockIdx = blockOrder.indexOf(sel.anchor.blockId);\n\n\tif (blockIdx >= blockOrder.length - 1) return null;\n\n\tconst nextBlockId = blockOrder[blockIdx + 1];\n\tif (!nextBlockId) return null;\n\n\t// Never merge isolating blocks directly (e.g. table cells).\n\tif (isIsolatingBlock(state, sel.anchor.blockId) || isIsolatingBlock(state, nextBlockId)) {\n\t\treturn null;\n\t}\n\n\t// Prevent merge across isolating boundaries\n\tif (!sharesParent(state, sel.anchor.blockId, nextBlockId)) {\n\t\tif (isInsideIsolating(state, sel.anchor.blockId)) return null;\n\t}\n\n\t// If next block is void, select it instead of merging\n\tif (isVoidBlock(state, nextBlockId)) {\n\t\tconst path = findNodePath(state.doc, nextBlockId) ?? [];\n\t\treturn state\n\t\t\t.transaction('input')\n\t\t\t.setSelection(createNodeSelection(nextBlockId, path as BlockId[]))\n\t\t\t.build();\n\t}\n\n\treturn state\n\t\t.transaction('input')\n\t\t.mergeBlocksAt(sel.anchor.blockId, nextBlockId)\n\t\t.setSelection(createCollapsedSelection(sel.anchor.blockId, sel.anchor.offset))\n\t\t.build();\n}\n\n/** Selects all content in the editor. */\nexport function selectAll(state: EditorState): Transaction {\n\tconst blocks = state.doc.children;\n\tconst firstBlock = blocks[0];\n\tconst lastBlock = blocks[blocks.length - 1];\n\tif (!firstBlock || !lastBlock)\n\t\treturn state.transaction('command').setSelection(state.selection).build();\n\tconst lastBlockLen = getBlockLength(lastBlock);\n\n\treturn state\n\t\t.transaction('command')\n\t\t.setSelection(\n\t\t\tcreateSelection(\n\t\t\t\t{ blockId: firstBlock.id, offset: 0 },\n\t\t\t\t{ blockId: lastBlock.id, offset: lastBlockLen },\n\t\t\t),\n\t\t)\n\t\t.build();\n}\n\n// --- Internal Helpers ---\n\nfunction resolveActiveMarks(state: EditorState): readonly Mark[] {\n\tif (state.storedMarks) return state.storedMarks;\n\tif (isNodeSelection(state.selection) || isGapCursor(state.selection)) return [];\n\n\tconst block = state.getBlock(state.selection.anchor.blockId);\n\tif (!block) return [];\n\n\treturn getBlockMarksAtOffset(block, state.selection.anchor.offset);\n}\n\nexport function addDeleteSelectionSteps(state: EditorState, builder: TransactionBuilder): void {\n\tif (isNodeSelection(state.selection) || isGapCursor(state.selection)) return;\n\tconst blockOrder = state.getBlockOrder();\n\tconst range = selectionRange(state.selection, blockOrder);\n\tconst fromIdx = blockOrder.indexOf(range.from.blockId);\n\tconst toIdx = blockOrder.indexOf(range.to.blockId);\n\n\tif (fromIdx === toIdx) {\n\t\tbuilder.deleteTextAt(range.from.blockId, range.from.offset, range.to.offset);\n\t} else {\n\t\tconst firstBlock = state.getBlock(range.from.blockId);\n\t\tif (!firstBlock) return;\n\t\tconst firstLen = getBlockLength(firstBlock);\n\n\t\t// Delete from the end of first block\n\t\tif (range.from.offset < firstLen) {\n\t\t\tbuilder.deleteTextAt(range.from.blockId, range.from.offset, firstLen);\n\t\t}\n\n\t\t// Delete from start of last block\n\t\tif (range.to.offset > 0) {\n\t\t\tbuilder.deleteTextAt(range.to.blockId, 0, range.to.offset);\n\t\t}\n\n\t\t// Delete middle blocks entirely and merge last into first\n\t\tfor (let i = fromIdx + 1; i < toIdx; i++) {\n\t\t\tconst midBlockId = blockOrder[i];\n\t\t\tif (!midBlockId) continue;\n\t\t\tconst midBlock = state.getBlock(midBlockId);\n\t\t\tif (!midBlock) continue;\n\t\t\tconst midLen = getBlockLength(midBlock);\n\t\t\tif (midLen > 0) {\n\t\t\t\tbuilder.deleteTextAt(midBlockId, 0, midLen);\n\t\t\t}\n\t\t\tbuilder.mergeBlocksAt(range.from.blockId, midBlockId);\n\t\t}\n\n\t\t// Merge last block into first\n\t\tbuilder.mergeBlocksAt(range.from.blockId, range.to.blockId);\n\t}\n}\n","/**\n * HardBreakPlugin: registers a hard line break (Shift+Enter → `<br>`)\n * as an InlineNode, with command and keymap bindings.\n */\n\nimport { insertHardBreakCommand } from '../../commands/Commands.js';\nimport type { Plugin, PluginContext } from '../Plugin.js';\n\n// --- Attribute Registry Augmentation ---\n\ndeclare module '../../model/AttrRegistry.js' {\n\tinterface InlineNodeAttrRegistry {\n\t\thard_break: Record<string, never>;\n\t}\n}\n\n// --- Plugin ---\n\nexport class HardBreakPlugin implements Plugin {\n\treadonly id = 'hard-break';\n\treadonly name = 'Hard Break';\n\treadonly priority = 10;\n\n\tinit(context: PluginContext): void {\n\t\tthis.registerInlineNodeSpec(context);\n\t\tthis.registerCommands(context);\n\t\tthis.registerKeymap(context);\n\t}\n\n\tprivate registerInlineNodeSpec(context: PluginContext): void {\n\t\tcontext.registerInlineNodeSpec({\n\t\t\ttype: 'hard_break',\n\t\t\ttoDOM() {\n\t\t\t\treturn document.createElement('br');\n\t\t\t},\n\t\t\ttoHTMLString() {\n\t\t\t\treturn '<br>';\n\t\t\t},\n\t\t\tparseHTML: [{ tag: 'br' }],\n\t\t\tsanitize: { tags: ['br'] },\n\t\t});\n\t}\n\n\tprivate registerCommands(context: PluginContext): void {\n\t\tcontext.registerCommand('insertHardBreak', () => {\n\t\t\tconst state = context.getState();\n\t\t\tconst tr = insertHardBreakCommand(state);\n\t\t\tif (!tr) return false;\n\t\t\tcontext.dispatch(tr);\n\t\t\treturn true;\n\t\t});\n\t}\n\n\tprivate registerKeymap(context: PluginContext): void {\n\t\tcontext.registerKeymap({\n\t\t\t'Shift-Enter': () => {\n\t\t\t\tconst state = context.getState();\n\t\t\t\tconst tr = insertHardBreakCommand(state);\n\t\t\t\tif (!tr) return false;\n\t\t\t\tcontext.dispatch(tr);\n\t\t\t\treturn true;\n\t\t\t},\n\t\t});\n\t}\n}\n"],"names":["getSiblings","state","parentPath","length","doc","children","parent","getBlock","createEmptyParagraph","id","createBlockNode","nodeType","createTextNode","resolveInsertPoint","sel","blockOrder","isCollapsed","blockId","anchor","offset","range","selectionRange","from","deleteNodeSelection","path","findNodePath","nodeId","slice","siblings","index","findIndex","c","builder","transaction","newId","generateBlockId","insertNode","removeNode","setSelection","createCollapsedSelection","build","prevSibling","isBlockNode","prevLeafId","node","current","lastBlockChild","i","child","prevLeaf","prevLen","getBlockLength","nextSibling","nextLeafId","firstBlockChild","find","navigateArrowIntoVoid","direction","selection","getBlockOrder","isNodeSelection","nodeIdx","indexOf","nodePath","prevId","isVoidBlock","createGapCursor","prevBlock","nextId","isGapCursor","blockIdx","block","blockLen","createNodeSelection","deleteBackwardAtGap","side","deleteVoidAtGap","deleteForwardAtGap","insertTextCommand","text","origin","insertIdx","insertText","Math","max","marks","storedMarks","getBlockMarksAtOffset","addDeleteSelectionSteps","insertBlockId","insertOffset","deleteSelectionCommand","splitBlockCommand","newBlockId","splitBlock","insertHardBreakCommand","hardBreak","createInlineNode","inlineType","insertInlineNode","mergeBlockBackward","prevBlockId","isIsolatingBlock","sharesParent","isInsideIsolating","mergeBlocksAt","mergeBlockForward","nextBlockId","selectAll","blocks","firstBlock","lastBlock","lastBlockLen","createSelection","fromIdx","toIdx","to","deleteTextAt","firstLen","midBlockId","midBlock","midLen","HardBreakPlugin","name","priority","context","this","registerInlineNodeSpec","registerCommands","registerKeymap","type","toDOM","document","createElement","toHTMLString","parseHTML","tag","sanitize","tags","registerCommand","tr","getState","dispatch"],"mappings":";;;;;AAuBO,SAASA,EACfC,IACAC,IAAAA;AAEA,MAA0B,MAAtBA,GAAWC,OAAc,QAAOF,GAAMG,IAAIC;AAC9C,QAAMC,KAAgCL,GAAMM,SAC3CL,GAAWA,GAAWC,SAAS,CAAA,CAAA;AAEhC,SAAOG,KAASA,GAAOD,WAAW,CAAA;AACnC;AAGO,SAASG,EAAqBC;AACpC,SAAOC,EAAgBC,EAAS,WAAA,GAAc,CAACC,EAAe,MAAMH,EAAAA;AACrE;AAQO,SAASI,EAAmBC,IAAgBC,IAAAA;AAClD,MAAIC,EAAYF,EAAAA,EACf,QAAO,EAAEG,SAASH,GAAII,OAAOD,SAASE,QAAQL,GAAII,OAAOC,OAAAA;AAE1D,QAAMC,KAAQC,EAAeP,IAAKC,EAAAA;AAClC,SAAO,EA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,KAAK,KAAA,CAAA,GACnBC,UAAU,EAAEC,MAAM,CAAC,IAAA,EAAA,EAAA,CAAA;AAAA,EAErB;AAAA,EAEQ,iBAAiBb,IAAAA;AACxBA,IAAAA,GAAQc,gBAAgB,mBAAmB,MAAA;AAC1C,YACMC,KAAK7C,EADG8B,GAAQgB,SAAAA,CAAAA;AAEtB,aAAA,CAAA,CAAKD,OACLf,GAAQiB,SAASF,EAAAA,GAAAA;AAAAA;EAGnB;AAAA,EAEQ,eAAef,IAAAA;AACtBA,IAAAA,GAAQI,eAAe,EACtB,eAAe,MAAA;AACd,YACMW,KAAK7C,EADG8B,GAAQgB;AAEtB,aAAA,CAAA,CAAKD,OACLf,GAAQiB,SAASF,EAAAA,GAAAA;AAAAA,IACV,EAAA,CAAA;AAAA,EAGV;;"}
|
|
@@ -1,119 +0,0 @@
|
|
|
1
|
-
import { i as t, g as e, a as n, r as o } from "./AttributedMarkCommands-BtLea72z.mjs";
|
|
2
|
-
import { r as i } from "./resolvePluginLocale-B4w1OkPy.mjs";
|
|
3
|
-
import { e as r } from "./HTMLUtils-DTqQzcKR.mjs";
|
|
4
|
-
import { m as a } from "./TypeBrands-C09nE2qO.mjs";
|
|
5
|
-
import { a as l, g as s } from "./StyleRuntime-CP4NCwKT.mjs";
|
|
6
|
-
import { b as c } from "./ColorValidation-CV4f1wu6.mjs";
|
|
7
|
-
const f = { label: "Font", tooltip: "Font Family" }, m = { en: f, de: { label: "Schriftart", tooltip: "Schriftfamilie" }, es: { label: "Fuente", tooltip: "Familia de fuente" }, fr: { label: "Police", tooltip: "Famille de police" }, zh: { label: "字体", tooltip: "字体系列" }, ru: { label: "Шрифт", tooltip: "Семейство шрифтов" }, ar: { label: "الخط", tooltip: "عائلة الخط" }, hi: { label: "फ़ॉन्ट", tooltip: "फ़ॉन्ट परिवार" } };
|
|
8
|
-
class p {
|
|
9
|
-
id = "font";
|
|
10
|
-
name = "Font";
|
|
11
|
-
priority = 22;
|
|
12
|
-
config;
|
|
13
|
-
locale;
|
|
14
|
-
injectedStyleElement = null;
|
|
15
|
-
context = null;
|
|
16
|
-
constructor(t2) {
|
|
17
|
-
this.config = t2;
|
|
18
|
-
}
|
|
19
|
-
init(t2) {
|
|
20
|
-
this.locale = i(m, t2, this.config.locale), t2.registerStyleSheet("\n/* Font Select — Width overrides for combobox button */\n.notectl-toolbar-btn--font {\n min-width: 100px;\n max-width: 160px;\n}\n\n/* Font Picker Popup */\n.notectl-font-picker {\n min-width: 200px;\n max-height: 320px;\n overflow-y: auto;\n}\n\n.notectl-font-picker__list {\n padding: 4px 0;\n}\n\n.notectl-font-picker__item {\n display: flex;\n align-items: center;\n gap: 8px;\n width: 100%;\n padding: 7px 12px;\n border: none;\n background: none;\n cursor: pointer;\n font-size: 14px;\n color: var(--notectl-fg);\n line-height: 1.4;\n text-align: left;\n white-space: nowrap;\n font-family: inherit;\n transition: background 0.1s;\n}\n\n@media (hover: hover) {\n .notectl-font-picker__item:hover {\n background: var(--notectl-hover-bg);\n }\n}\n\n.notectl-font-picker__item--active {\n background: var(--notectl-active-bg);\n color: var(--notectl-primary-fg);\n}\n\n@media (hover: hover) {\n .notectl-font-picker__item--active:hover {\n background: var(--notectl-active-bg);\n }\n}\n\n.notectl-font-picker__check {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 16px;\n flex-shrink: 0;\n font-size: 13px;\n font-weight: 600;\n color: var(--notectl-primary-fg);\n}\n\n.notectl-font-picker__label {\n flex: 1;\n}\n\n.notectl-font-picker__separator {\n height: 1px;\n background: var(--notectl-border);\n margin: 4px 8px;\n}\n"), this.context = t2, this.registerMarkSpec(t2), this.registerCommands(t2), this.registerToolbarItem(t2), this.injectFontFaces();
|
|
21
|
-
}
|
|
22
|
-
destroy() {
|
|
23
|
-
this.injectedStyleElement?.remove(), this.injectedStyleElement = null, this.context = null;
|
|
24
|
-
}
|
|
25
|
-
registerMarkSpec(t2) {
|
|
26
|
-
t2.registerMarkSpec({ type: "font", rank: 6, attrs: { family: { default: "" } }, toDOM(t3) {
|
|
27
|
-
const e2 = document.createElement("span"), n2 = t3.attrs?.family ?? "";
|
|
28
|
-
return n2 && l(e2, "fontFamily", n2), e2;
|
|
29
|
-
}, toHTMLString: (t3, e2) => {
|
|
30
|
-
const n2 = String(t3.attrs?.family ?? "");
|
|
31
|
-
return n2 && c(n2) ? `<span style="font-family: ${r(n2)}">${e2}</span>` : e2;
|
|
32
|
-
}, toHTMLStyle: (t3) => {
|
|
33
|
-
const e2 = String(t3.attrs?.family ?? "");
|
|
34
|
-
return e2 && c(e2) ? `font-family: ${r(e2)}` : null;
|
|
35
|
-
}, parseHTML: [{ tag: "span", getAttrs: (t3) => {
|
|
36
|
-
const e2 = t3.style.fontFamily;
|
|
37
|
-
return !!e2 && { family: e2 };
|
|
38
|
-
} }], sanitize: { tags: ["span"] } });
|
|
39
|
-
}
|
|
40
|
-
registerCommands(t2) {
|
|
41
|
-
t2.registerCommand("removeFont", () => {
|
|
42
|
-
const e2 = t2.getState();
|
|
43
|
-
return this.removeFont(t2, e2);
|
|
44
|
-
}), t2.registerCommand("setFont", () => false);
|
|
45
|
-
}
|
|
46
|
-
get defaultFont() {
|
|
47
|
-
if (this.config.defaultFont) {
|
|
48
|
-
const t3 = this.config.fonts.find((t4) => t4.name === this.config.defaultFont);
|
|
49
|
-
if (t3) return t3;
|
|
50
|
-
}
|
|
51
|
-
const t2 = this.config.fonts[0];
|
|
52
|
-
if (!t2) throw new Error("FontPlugin: fonts list is empty");
|
|
53
|
-
return t2;
|
|
54
|
-
}
|
|
55
|
-
registerToolbarItem(t2) {
|
|
56
|
-
t2.registerToolbarItem({ id: "font", group: "format", label: this.locale.label, tooltip: this.locale.tooltip, command: "removeFont", priority: 5, popupType: "combobox", separatorAfter: this.config.separatorAfter, getLabel: (t3) => this.resolveFontName(this.getActiveFont(t3)), renderPopup: (t3, e2, n2) => {
|
|
57
|
-
this.renderFontPopup(t3, e2, n2);
|
|
58
|
-
}, isActive: (t3) => this.isFontActive(t3) });
|
|
59
|
-
}
|
|
60
|
-
resolveFontName(t2) {
|
|
61
|
-
if (!t2) return this.defaultFont.name;
|
|
62
|
-
const e2 = this.config.fonts.find((e3) => e3.family === t2);
|
|
63
|
-
return e2?.name ?? (t2.split(",")[0] ?? "").trim().replace(/'/g, "");
|
|
64
|
-
}
|
|
65
|
-
isFontActive(e2) {
|
|
66
|
-
return t(e2, "font");
|
|
67
|
-
}
|
|
68
|
-
getActiveFont(t2) {
|
|
69
|
-
return e(t2, "font", (t3) => t3.attrs.family ?? null);
|
|
70
|
-
}
|
|
71
|
-
applyFont(t2, e2, o2) {
|
|
72
|
-
const i2 = { type: a("font"), attrs: { family: o2 } }, r2 = n(e2, i2);
|
|
73
|
-
return !!r2 && (t2.dispatch(r2), true);
|
|
74
|
-
}
|
|
75
|
-
removeFont(t2, e2) {
|
|
76
|
-
const n2 = o(e2, a("font"));
|
|
77
|
-
return !!n2 && (t2.dispatch(n2), true);
|
|
78
|
-
}
|
|
79
|
-
injectFontFaces() {
|
|
80
|
-
const t2 = [];
|
|
81
|
-
for (const e3 of this.config.fonts) if (e3.fontFaces?.length) for (const n3 of e3.fontFaces) {
|
|
82
|
-
const o2 = [`font-family: '${(e3.family.split(",")[0] ?? "").trim().replace(/'/g, "")}'`, `src: ${n3.src}`];
|
|
83
|
-
n3.weight && o2.push(`font-weight: ${n3.weight}`), n3.style && o2.push(`font-style: ${n3.style}`), o2.push(`font-display: ${n3.display ?? "swap"}`), t2.push(`@font-face {
|
|
84
|
-
${o2.join(";\n ")};
|
|
85
|
-
}`);
|
|
86
|
-
}
|
|
87
|
-
if (0 === t2.length) return;
|
|
88
|
-
const e2 = document.createElement("style");
|
|
89
|
-
e2.setAttribute("data-notectl-fonts", "");
|
|
90
|
-
const n2 = this.context ? s(this.context.getContainer()) : void 0;
|
|
91
|
-
n2 && e2.setAttribute("nonce", n2), e2.textContent = t2.join("\n\n"), document.head.appendChild(e2), this.injectedStyleElement = e2;
|
|
92
|
-
}
|
|
93
|
-
renderFontPopup(t2, e2, n2) {
|
|
94
|
-
t2.classList.add("notectl-font-picker");
|
|
95
|
-
const o2 = e2.getState(), i2 = this.getActiveFont(o2), r2 = this.defaultFont.family, a2 = e2.getContainer(), l2 = document.createElement("div");
|
|
96
|
-
l2.className = "notectl-font-picker__list", l2.setAttribute("role", "listbox"), l2.setAttribute("aria-label", this.locale.label);
|
|
97
|
-
for (const t3 of this.config.fonts) {
|
|
98
|
-
const o3 = t3.family === r2, s2 = o3 && !i2 || i2 === t3.family, c2 = this.createFontItem(t3.name, t3.family, s2, (i3) => {
|
|
99
|
-
i3.preventDefault(), i3.stopPropagation(), o3 ? e2.executeCommand("removeFont") : this.applyFont(e2, e2.getState(), t3.family), n2({ restoreFocusTo: a2 });
|
|
100
|
-
});
|
|
101
|
-
t3.category && c2.setAttribute("data-category", t3.category), l2.appendChild(c2);
|
|
102
|
-
}
|
|
103
|
-
t2.appendChild(l2);
|
|
104
|
-
}
|
|
105
|
-
createFontItem(t2, e2, n2, o2) {
|
|
106
|
-
const i2 = document.createElement("button");
|
|
107
|
-
i2.type = "button", i2.className = "notectl-font-picker__item", i2.setAttribute("role", "option"), i2.setAttribute("aria-selected", String(n2)), n2 && i2.classList.add("notectl-font-picker__item--active");
|
|
108
|
-
const r2 = document.createElement("span");
|
|
109
|
-
r2.className = "notectl-font-picker__check", r2.textContent = n2 ? "✓" : "", i2.appendChild(r2);
|
|
110
|
-
const a2 = document.createElement("span");
|
|
111
|
-
return a2.className = "notectl-font-picker__label", a2.textContent = t2, e2 && l(a2, "fontFamily", e2), i2.appendChild(a2), i2.addEventListener("mousedown", o2), i2;
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
|
-
export {
|
|
115
|
-
p as F,
|
|
116
|
-
m as a,
|
|
117
|
-
f as b
|
|
118
|
-
};
|
|
119
|
-
//# sourceMappingURL=index-WpbK_s_H.mjs.map
|