@vc-shell/framework 1.1.62 → 1.1.64

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (115) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/core/composables/useLanguages/index.ts +16 -73
  3. package/core/services/index.ts +1 -0
  4. package/core/services/language-service.ts +88 -0
  5. package/dist/core/composables/useLanguages/index.d.ts +4 -15
  6. package/dist/core/composables/useLanguages/index.d.ts.map +1 -1
  7. package/dist/core/services/index.d.ts +1 -0
  8. package/dist/core/services/index.d.ts.map +1 -1
  9. package/dist/core/services/language-service.d.ts +15 -0
  10. package/dist/core/services/language-service.d.ts.map +1 -0
  11. package/dist/framework.js +6038 -6021
  12. package/dist/index.d.ts.map +1 -1
  13. package/dist/injection-keys.d.ts +2 -1
  14. package/dist/injection-keys.d.ts.map +1 -1
  15. package/dist/shared/components/language-selector/language-selector.vue.d.ts.map +1 -1
  16. package/dist/tsconfig.tsbuildinfo +1 -1
  17. package/dist/vendor-boolbase-A_-Pp38P.js +23 -0
  18. package/dist/{vendor-cheerio-CleDsuQZ.js → vendor-cheerio-C46iBpCu.js} +10 -10
  19. package/dist/{vendor-cheerio-select-CVkYl3Z-.js → vendor-cheerio-select-C8emRZsx.js} +5 -5
  20. package/dist/vendor-core-js-DFA7rceR.js +1206 -0
  21. package/dist/{vendor-css-select-CtIzVIiG.js → vendor-css-select-DR9bp36p.js} +3 -3
  22. package/dist/{vendor-dom-serializer-CugO0RdN.js → vendor-dom-serializer-Sk3xHhQk.js} +1 -1
  23. package/dist/{vendor-domutils-D3Y2YQFR.js → vendor-domutils-BiVCXO8c.js} +2 -2
  24. package/dist/{vendor-entities-v26HW8wW.js → vendor-entities-CCReaWqU.js} +35 -34
  25. package/dist/{vendor-floating-ui-core-C9uEvi1M.js → vendor-floating-ui-core-DpX2jufl.js} +10 -10
  26. package/dist/{vendor-floating-ui-dom-CZkYGmv4.js → vendor-floating-ui-dom-C4AKN5Mo.js} +8 -8
  27. package/dist/{vendor-floating-ui-utils-Bx3BTd6_.js → vendor-floating-ui-utils-CRaCuFxS.js} +29 -29
  28. package/dist/{vendor-floating-ui-vue-CLOiVYP7.js → vendor-floating-ui-vue-OwtolkBv.js} +12 -12
  29. package/dist/{vendor-htmlparser2-CXL_uhMI.js → vendor-htmlparser2-CpQu33io.js} +1 -1
  30. package/dist/{vendor-intlify-core-base-FyGSkd6r.js → vendor-intlify-core-base-txnziOTW.js} +9 -9
  31. package/dist/{vendor-intlify-message-compiler-D_vL9-DK.js → vendor-intlify-message-compiler-XquMv3aB.js} +5 -3
  32. package/dist/{vendor-intlify-shared-BMbzEQSk.js → vendor-intlify-shared-CE1Dfvjf.js} +11 -11
  33. package/dist/{vendor-iso-639-1-dVGfSUIM.js → vendor-iso-639-1-BJO6WZAt.js} +3 -3
  34. package/dist/{vendor-markdown-it-4AJoRTAg.js → vendor-markdown-it-RJo-N9ov.js} +1 -1
  35. package/dist/{vendor-markdown-it-task-lists-Byg1-ms9.js → vendor-markdown-it-task-lists-BxLwscWK.js} +2 -2
  36. package/dist/{vendor-microsoft-applicationinsights-analytics-js-DA-ctcAL.js → vendor-microsoft-applicationinsights-analytics-js-CauId95v.js} +5 -5
  37. package/dist/{vendor-microsoft-applicationinsights-cfgsync-js-COfRj-2q.js → vendor-microsoft-applicationinsights-cfgsync-js-DGfB75It.js} +3 -3
  38. package/dist/{vendor-microsoft-applicationinsights-channel-js-MTPYhH-I.js → vendor-microsoft-applicationinsights-channel-js-B4PYlGv8.js} +11 -11
  39. package/dist/{vendor-microsoft-applicationinsights-common-CDVnJ6MR.js → vendor-microsoft-applicationinsights-common-Bj6sQeoz.js} +7 -7
  40. package/dist/{vendor-microsoft-applicationinsights-core-js-D7Aicf8S.js → vendor-microsoft-applicationinsights-core-js-Cga21Mpw.js} +13 -13
  41. package/dist/{vendor-microsoft-applicationinsights-dependencies-js-CvQWWraU.js → vendor-microsoft-applicationinsights-dependencies-js-CH87Sln6.js} +68 -68
  42. package/dist/{vendor-microsoft-applicationinsights-properties-js-C0Iv1cZE.js → vendor-microsoft-applicationinsights-properties-js-CLE2OEt_.js} +5 -5
  43. package/dist/{vendor-microsoft-applicationinsights-web-BRuQAzjU.js → vendor-microsoft-applicationinsights-web-8IaeIl22.js} +8 -8
  44. package/dist/{vendor-nevware21-ts-async-FAyg3c9V.js → vendor-nevware21-ts-async-DadHEt7N.js} +3 -3
  45. package/dist/{vendor-nth-check-BE7AeBMg.js → vendor-nth-check-CS1D-zr5.js} +1 -1
  46. package/dist/{vendor-parse5-htmlparser2-tree-adapter-CNubfdOP.js → vendor-parse5-htmlparser2-tree-adapter-BWywtwol.js} +9 -9
  47. package/dist/{vendor-parse5-DqztJOGh.js → vendor-parse5-zq5Hn0y9.js} +3 -1
  48. package/dist/{vendor-prettier-D8C9GG-0.js → vendor-prettier-DaiSFsWE.js} +1184 -1167
  49. package/dist/vendor-prosemirror-commands-B8fhFbTo.js +385 -0
  50. package/dist/{vendor-prosemirror-dropcursor-CwZhBUcZ.js → vendor-prosemirror-dropcursor-CdHQ9kQG.js} +2 -2
  51. package/dist/{vendor-prosemirror-gapcursor-COcwb4TJ.js → vendor-prosemirror-gapcursor-W-ky5QTm.js} +4 -4
  52. package/dist/{vendor-prosemirror-history-DmPvdOpr.js → vendor-prosemirror-history-CrtTR5Cd.js} +2 -2
  53. package/dist/{vendor-prosemirror-keymap-CS1uIBpE.js → vendor-prosemirror-keymap-DWvoDWf6.js} +1 -1
  54. package/dist/{vendor-prosemirror-markdown-sO1Pn6SW.js → vendor-prosemirror-markdown-CuzWQ2N6.js} +2 -2
  55. package/dist/{vendor-prosemirror-model-DwojkhDQ.js → vendor-prosemirror-model-CVTn1Stc.js} +2 -2
  56. package/dist/{vendor-prosemirror-schema-list-rrOzMlj0.js → vendor-prosemirror-schema-list-Ds6x_KLX.js} +2 -2
  57. package/dist/{vendor-prosemirror-state-BN86J-Ko.js → vendor-prosemirror-state-CRUasa1V.js} +2 -2
  58. package/dist/{vendor-prosemirror-tables-C7XMqyon.js → vendor-prosemirror-tables-DzTfCeHX.js} +5 -5
  59. package/dist/{vendor-prosemirror-transform-B0c_LAV_.js → vendor-prosemirror-transform-BeDaI3CS.js} +1 -1
  60. package/dist/{vendor-prosemirror-view-DyWzmy4t.js → vendor-prosemirror-view-BGYdOWiJ.js} +76 -74
  61. package/dist/{vendor-semver-BoKYtkQw.js → vendor-semver-FuwqpOls.js} +435 -435
  62. package/dist/vendor-tanstack-vue-virtual-CD9yLWd7.js +1 -0
  63. package/dist/{vendor-tippy-js-BGdgwGX-.js → vendor-tippy-js-nNhcw_JH.js} +15 -15
  64. package/dist/{vendor-tiptap-core-BgwY40dr.js → vendor-tiptap-core-dlTW4S11.js} +76 -65
  65. package/dist/{vendor-tiptap-extension-blockquote-BVW0VVC0.js → vendor-tiptap-extension-blockquote-iAIM-meW.js} +1 -1
  66. package/dist/{vendor-tiptap-extension-bold-xhi5xxPT.js → vendor-tiptap-extension-bold-bkOLNH6E.js} +1 -1
  67. package/dist/{vendor-tiptap-extension-bubble-menu-DhWtcCL3.js → vendor-tiptap-extension-bubble-menu-BRWVLpun.js} +6 -6
  68. package/dist/{vendor-tiptap-extension-bullet-list-Ba21suMY.js → vendor-tiptap-extension-bullet-list-DfU428XB.js} +1 -1
  69. package/dist/{vendor-tiptap-extension-code-DFTxp7wE.js → vendor-tiptap-extension-code-CgIql8q6.js} +1 -1
  70. package/dist/{vendor-tiptap-extension-code-block-B2KK5g8S.js → vendor-tiptap-extension-code-block-V26-erQk.js} +2 -2
  71. package/dist/{vendor-tiptap-extension-document-CW8jybcc.js → vendor-tiptap-extension-document-BYF_BzDD.js} +1 -1
  72. package/dist/{vendor-tiptap-extension-dropcursor-DdRuETKJ.js → vendor-tiptap-extension-dropcursor-DqjaaFex.js} +2 -2
  73. package/dist/{vendor-tiptap-extension-floating-menu-Da7fpnr7.js → vendor-tiptap-extension-floating-menu-vptdm_Y0.js} +6 -6
  74. package/dist/{vendor-tiptap-extension-gapcursor-CafmhWSf.js → vendor-tiptap-extension-gapcursor-DxLBw8V0.js} +2 -2
  75. package/dist/{vendor-tiptap-extension-hard-break-n9aI6ybJ.js → vendor-tiptap-extension-hard-break-DygHhzqw.js} +1 -1
  76. package/dist/{vendor-tiptap-extension-heading-xj24usOy.js → vendor-tiptap-extension-heading-C-ArDc3_.js} +1 -1
  77. package/dist/{vendor-tiptap-extension-history-C2uOLua2.js → vendor-tiptap-extension-history-C41RW3Bv.js} +2 -2
  78. package/dist/{vendor-tiptap-extension-horizontal-rule--uXIYeaK.js → vendor-tiptap-extension-horizontal-rule-BGMGd9fo.js} +2 -2
  79. package/dist/{vendor-tiptap-extension-image-BJx5lyoG.js → vendor-tiptap-extension-image-DChcWb4v.js} +1 -1
  80. package/dist/{vendor-tiptap-extension-italic-DPAViC4y.js → vendor-tiptap-extension-italic-BNJrFvrR.js} +1 -1
  81. package/dist/{vendor-tiptap-extension-link-aDGmrWTi.js → vendor-tiptap-extension-link-DFN4ENph.js} +2 -2
  82. package/dist/{vendor-tiptap-extension-list-item-DE9dJ64Q.js → vendor-tiptap-extension-list-item-3qKYhGHe.js} +1 -1
  83. package/dist/{vendor-tiptap-extension-ordered-list-CcNtDDJm.js → vendor-tiptap-extension-ordered-list-D3QL0eiW.js} +1 -1
  84. package/dist/{vendor-tiptap-extension-paragraph-DvlrAzIW.js → vendor-tiptap-extension-paragraph-DZfkaJJ-.js} +1 -1
  85. package/dist/{vendor-tiptap-extension-placeholder-DyW7px66.js → vendor-tiptap-extension-placeholder-CoOAmd0a.js} +7 -7
  86. package/dist/{vendor-tiptap-extension-strike-DMMLEFkd.js → vendor-tiptap-extension-strike-BlGNozxy.js} +1 -1
  87. package/dist/{vendor-tiptap-extension-table-BpegTABL.js → vendor-tiptap-extension-table-CZn6Xykb.js} +16 -16
  88. package/dist/{vendor-tiptap-extension-table-cell-8rHRq4BW.js → vendor-tiptap-extension-table-cell-BQuS-XFD.js} +1 -1
  89. package/dist/{vendor-tiptap-extension-table-header-DZ1y7iS2.js → vendor-tiptap-extension-table-header-ZrtK7HiQ.js} +1 -1
  90. package/dist/{vendor-tiptap-extension-table-row-DmkNUw4L.js → vendor-tiptap-extension-table-row-CBrXvqsO.js} +1 -1
  91. package/dist/{vendor-tiptap-extension-text-Cwas3TQT.js → vendor-tiptap-extension-text-DwA7jrBq.js} +1 -1
  92. package/dist/{vendor-tiptap-extension-underline-Hz5uJRfR.js → vendor-tiptap-extension-underline-CIVtuRLl.js} +1 -1
  93. package/dist/{vendor-tiptap-markdown-Dj1XZWg4.js → vendor-tiptap-markdown-CidDIpZ-.js} +12 -11
  94. package/dist/vendor-tiptap-pm-9TOy65Oe.js +1 -0
  95. package/dist/{vendor-tiptap-starter-kit-Cxj07T7v.js → vendor-tiptap-starter-kit-BdU6UtqB.js} +19 -19
  96. package/dist/{vendor-tiptap-vue-3-DF4kzEFI.js → vendor-tiptap-vue-3-CnYccgV4.js} +3 -3
  97. package/dist/{vendor-truncate-html-Bx1HJzRq.js → vendor-truncate-html-DYC0Lj9o.js} +1 -1
  98. package/dist/{vendor-vee-validate-rules-DDeNM2Gc.js → vendor-vee-validate-rules-4oWUZPpG.js} +4 -2
  99. package/dist/{vendor-vue-currency-input-DxWnS-HB.js → vendor-vue-currency-input-BqaYAdhD.js} +88 -86
  100. package/dist/vendor-vue-demi-CD9yLWd7.js +1 -0
  101. package/dist/{vendor-vue-i18n-DC6m6S7G.js → vendor-vue-i18n-BeXi5L3e.js} +423 -412
  102. package/dist/{vendor-vue3-application-insights-dAGGfA_M.js → vendor-vue3-application-insights-C8xbxXXX.js} +2 -2
  103. package/dist/{vendor-vuepic-vue-datepicker-_JffV5We.js → vendor-vuepic-vue-datepicker-DkHsqyoL.js} +257 -257
  104. package/dist/vendor-vueuse-components-B0zqjNRW.js +542 -0
  105. package/dist/{vendor-vueuse-core-cB-c7DzH.js → vendor-vueuse-core-CYgwn-B2.js} +31 -30
  106. package/dist/{vendor-vueuse-shared-Dg7PMM0z.js → vendor-vueuse-shared-B_uDJJ6V.js} +33 -33
  107. package/package.json +5 -5
  108. package/shared/components/language-selector/language-selector.vue +16 -8
  109. package/dist/vendor-boolbase-Bgn9I6iN.js +0 -21
  110. package/dist/vendor-core-js-l0sNRNKZ.js +0 -1
  111. package/dist/vendor-prosemirror-commands-C6teL3Xo.js +0 -344
  112. package/dist/vendor-tanstack-vue-virtual-l0sNRNKZ.js +0 -1
  113. package/dist/vendor-tiptap-pm-l0sNRNKZ.js +0 -1
  114. package/dist/vendor-vue-demi-l0sNRNKZ.js +0 -1
  115. package/dist/vendor-vueuse-components-DtK_mxpP.js +0 -219
@@ -0,0 +1,385 @@
1
+ import { f as J, c as h, l as T, a as A, j as v, r as B, R as U, b as O } from "./vendor-prosemirror-transform-BeDaI3CS.js";
2
+ import { S as y, F as S } from "./vendor-prosemirror-model-CVTn1Stc.js";
3
+ import { T as I, N as d, S as V, A as P } from "./vendor-prosemirror-state-CRUasa1V.js";
4
+ const M = (t, e) => t.selection.empty ? !1 : (e && e(t.tr.deleteSelection().scrollIntoView()), !0);
5
+ function N(t, e) {
6
+ let { $cursor: r } = t.selection;
7
+ return !r || (e ? !e.endOfTextblock("backward", t) : r.parentOffset > 0) ? null : r;
8
+ }
9
+ const G = (t, e, r) => {
10
+ let n = N(t, r);
11
+ if (!n)
12
+ return !1;
13
+ let o = z(n);
14
+ if (!o) {
15
+ let i = n.blockRange(), f = i && T(i);
16
+ return f == null ? !1 : (e && e(t.tr.lift(i, f).scrollIntoView()), !0);
17
+ }
18
+ let l = o.nodeBefore;
19
+ if (D(t, o, e, -1))
20
+ return !0;
21
+ if (n.parent.content.size == 0 && (x(l, "end") || d.isSelectable(l)))
22
+ for (let i = n.depth; ; i--) {
23
+ let f = B(t.doc, n.before(i), n.after(i), y.empty);
24
+ if (f && f.slice.size < f.to - f.from) {
25
+ if (e) {
26
+ let s = t.tr.step(f);
27
+ s.setSelection(x(l, "end") ? V.findFrom(s.doc.resolve(s.mapping.map(o.pos, -1)), -1) : d.create(s.doc, o.pos - l.nodeSize)), e(s.scrollIntoView());
28
+ }
29
+ return !0;
30
+ }
31
+ if (i == 1 || n.node(i - 1).childCount > 1)
32
+ break;
33
+ }
34
+ return l.isAtom && o.depth == n.depth - 1 ? (e && e(t.tr.delete(o.pos - l.nodeSize, o.pos).scrollIntoView()), !0) : !1;
35
+ }, oe = (t, e, r) => {
36
+ let n = N(t, r);
37
+ if (!n)
38
+ return !1;
39
+ let o = z(n);
40
+ return o ? E(t, o, e) : !1;
41
+ }, le = (t, e, r) => {
42
+ let n = W(t, r);
43
+ if (!n)
44
+ return !1;
45
+ let o = j(n);
46
+ return o ? E(t, o, e) : !1;
47
+ };
48
+ function E(t, e, r) {
49
+ let n = e.nodeBefore, o = n, l = e.pos - 1;
50
+ for (; !o.isTextblock; l--) {
51
+ if (o.type.spec.isolating)
52
+ return !1;
53
+ let c = o.lastChild;
54
+ if (!c)
55
+ return !1;
56
+ o = c;
57
+ }
58
+ let i = e.nodeAfter, f = i, s = e.pos + 1;
59
+ for (; !f.isTextblock; s++) {
60
+ if (f.type.spec.isolating)
61
+ return !1;
62
+ let c = f.firstChild;
63
+ if (!c)
64
+ return !1;
65
+ f = c;
66
+ }
67
+ let p = B(t.doc, l, s, y.empty);
68
+ if (!p || p.from != l || p instanceof U && p.slice.size >= s - l)
69
+ return !1;
70
+ if (r) {
71
+ let c = t.tr.step(p);
72
+ c.setSelection(I.create(c.doc, l)), r(c.scrollIntoView());
73
+ }
74
+ return !0;
75
+ }
76
+ function x(t, e, r = !1) {
77
+ for (let n = t; n; n = e == "start" ? n.firstChild : n.lastChild) {
78
+ if (n.isTextblock)
79
+ return !0;
80
+ if (r && n.childCount != 1)
81
+ return !1;
82
+ }
83
+ return !1;
84
+ }
85
+ const H = (t, e, r) => {
86
+ let { $head: n, empty: o } = t.selection, l = n;
87
+ if (!o)
88
+ return !1;
89
+ if (n.parent.isTextblock) {
90
+ if (r ? !r.endOfTextblock("backward", t) : n.parentOffset > 0)
91
+ return !1;
92
+ l = z(n);
93
+ }
94
+ let i = l && l.nodeBefore;
95
+ return !i || !d.isSelectable(i) ? !1 : (e && e(t.tr.setSelection(d.create(t.doc, l.pos - i.nodeSize)).scrollIntoView()), !0);
96
+ };
97
+ function z(t) {
98
+ if (!t.parent.type.spec.isolating)
99
+ for (let e = t.depth - 1; e >= 0; e--) {
100
+ if (t.index(e) > 0)
101
+ return t.doc.resolve(t.before(e + 1));
102
+ if (t.node(e).type.spec.isolating)
103
+ break;
104
+ }
105
+ return null;
106
+ }
107
+ function W(t, e) {
108
+ let { $cursor: r } = t.selection;
109
+ return !r || (e ? !e.endOfTextblock("forward", t) : r.parentOffset < r.parent.content.size) ? null : r;
110
+ }
111
+ const K = (t, e, r) => {
112
+ let n = W(t, r);
113
+ if (!n)
114
+ return !1;
115
+ let o = j(n);
116
+ if (!o)
117
+ return !1;
118
+ let l = o.nodeAfter;
119
+ if (D(t, o, e, 1))
120
+ return !0;
121
+ if (n.parent.content.size == 0 && (x(l, "start") || d.isSelectable(l))) {
122
+ let i = B(t.doc, n.before(), n.after(), y.empty);
123
+ if (i && i.slice.size < i.to - i.from) {
124
+ if (e) {
125
+ let f = t.tr.step(i);
126
+ f.setSelection(x(l, "start") ? V.findFrom(f.doc.resolve(f.mapping.map(o.pos)), 1) : d.create(f.doc, f.mapping.map(o.pos))), e(f.scrollIntoView());
127
+ }
128
+ return !0;
129
+ }
130
+ }
131
+ return l.isAtom && o.depth == n.depth - 1 ? (e && e(t.tr.delete(o.pos, o.pos + l.nodeSize).scrollIntoView()), !0) : !1;
132
+ }, L = (t, e, r) => {
133
+ let { $head: n, empty: o } = t.selection, l = n;
134
+ if (!o)
135
+ return !1;
136
+ if (n.parent.isTextblock) {
137
+ if (r ? !r.endOfTextblock("forward", t) : n.parentOffset < n.parent.content.size)
138
+ return !1;
139
+ l = j(n);
140
+ }
141
+ let i = l && l.nodeAfter;
142
+ return !i || !d.isSelectable(i) ? !1 : (e && e(t.tr.setSelection(d.create(t.doc, l.pos)).scrollIntoView()), !0);
143
+ };
144
+ function j(t) {
145
+ if (!t.parent.type.spec.isolating)
146
+ for (let e = t.depth - 1; e >= 0; e--) {
147
+ let r = t.node(e);
148
+ if (t.index(e) + 1 < r.childCount)
149
+ return t.doc.resolve(t.after(e + 1));
150
+ if (r.type.spec.isolating)
151
+ break;
152
+ }
153
+ return null;
154
+ }
155
+ const ie = (t, e) => {
156
+ let r = t.selection, n = r instanceof d, o;
157
+ if (n) {
158
+ if (r.node.isTextblock || !A(t.doc, r.from))
159
+ return !1;
160
+ o = r.from;
161
+ } else if (o = v(t.doc, r.from, -1), o == null)
162
+ return !1;
163
+ if (e) {
164
+ let l = t.tr.join(o);
165
+ n && l.setSelection(d.create(l.doc, o - t.doc.resolve(o).nodeBefore.nodeSize)), e(l.scrollIntoView());
166
+ }
167
+ return !0;
168
+ }, fe = (t, e) => {
169
+ let r = t.selection, n;
170
+ if (r instanceof d) {
171
+ if (r.node.isTextblock || !A(t.doc, r.to))
172
+ return !1;
173
+ n = r.to;
174
+ } else if (n = v(t.doc, r.to, 1), n == null)
175
+ return !1;
176
+ return e && e(t.tr.join(n).scrollIntoView()), !0;
177
+ }, se = (t, e) => {
178
+ let { $from: r, $to: n } = t.selection, o = r.blockRange(n), l = o && T(o);
179
+ return l == null ? !1 : (e && e(t.tr.lift(o, l).scrollIntoView()), !0);
180
+ }, Q = (t, e) => {
181
+ let { $head: r, $anchor: n } = t.selection;
182
+ return !r.parent.type.spec.code || !r.sameParent(n) ? !1 : (e && e(t.tr.insertText(`
183
+ `).scrollIntoView()), !0);
184
+ };
185
+ function R(t) {
186
+ for (let e = 0; e < t.edgeCount; e++) {
187
+ let { type: r } = t.edge(e);
188
+ if (r.isTextblock && !r.hasRequiredAttrs())
189
+ return r;
190
+ }
191
+ return null;
192
+ }
193
+ const ce = (t, e) => {
194
+ let { $head: r, $anchor: n } = t.selection;
195
+ if (!r.parent.type.spec.code || !r.sameParent(n))
196
+ return !1;
197
+ let o = r.node(-1), l = r.indexAfter(-1), i = R(o.contentMatchAt(l));
198
+ if (!i || !o.canReplaceWith(l, l, i))
199
+ return !1;
200
+ if (e) {
201
+ let f = r.after(), s = t.tr.replaceWith(f, f, i.createAndFill());
202
+ s.setSelection(V.near(s.doc.resolve(f), 1)), e(s.scrollIntoView());
203
+ }
204
+ return !0;
205
+ }, X = (t, e) => {
206
+ let r = t.selection, { $from: n, $to: o } = r;
207
+ if (r instanceof P || n.parent.inlineContent || o.parent.inlineContent)
208
+ return !1;
209
+ let l = R(o.parent.contentMatchAt(o.indexAfter()));
210
+ if (!l || !l.isTextblock)
211
+ return !1;
212
+ if (e) {
213
+ let i = (!n.parentOffset && o.index() < o.parent.childCount ? n : o).pos, f = t.tr.insert(i, l.createAndFill());
214
+ f.setSelection(I.create(f.doc, i + 1)), e(f.scrollIntoView());
215
+ }
216
+ return !0;
217
+ }, Y = (t, e) => {
218
+ let { $cursor: r } = t.selection;
219
+ if (!r || r.parent.content.size)
220
+ return !1;
221
+ if (r.depth > 1 && r.after() != r.end(-1)) {
222
+ let l = r.before();
223
+ if (h(t.doc, l))
224
+ return e && e(t.tr.split(l).scrollIntoView()), !0;
225
+ }
226
+ let n = r.blockRange(), o = n && T(n);
227
+ return o == null ? !1 : (e && e(t.tr.lift(n, o).scrollIntoView()), !0);
228
+ };
229
+ function Z(t) {
230
+ return (e, r) => {
231
+ let { $from: n, $to: o } = e.selection;
232
+ if (e.selection instanceof d && e.selection.node.isBlock)
233
+ return !n.parentOffset || !h(e.doc, n.pos) ? !1 : (r && r(e.tr.split(n.pos).scrollIntoView()), !0);
234
+ if (!n.depth)
235
+ return !1;
236
+ let l = [], i, f, s = !1, p = !1;
237
+ for (let a = n.depth; ; a--)
238
+ if (n.node(a).isBlock) {
239
+ s = n.end(a) == n.pos + (n.depth - a), p = n.start(a) == n.pos - (n.depth - a), f = R(n.node(a - 1).contentMatchAt(n.indexAfter(a - 1))), l.unshift(s && f ? { type: f } : null), i = a;
240
+ break;
241
+ } else {
242
+ if (a == 1)
243
+ return !1;
244
+ l.unshift(null);
245
+ }
246
+ let c = e.tr;
247
+ (e.selection instanceof I || e.selection instanceof P) && c.deleteSelection();
248
+ let m = c.mapping.map(n.pos), k = h(c.doc, m, l.length, l);
249
+ if (k || (l[0] = f ? { type: f } : null, k = h(c.doc, m, l.length, l)), !k)
250
+ return !1;
251
+ if (c.split(m, l.length, l), !s && p && n.node(i).type != f) {
252
+ let a = c.mapping.map(n.before(i)), u = c.doc.resolve(a);
253
+ f && n.node(i - 1).canReplaceWith(u.index(), u.index() + 1, f) && c.setNodeMarkup(c.mapping.map(n.before(i)), f);
254
+ }
255
+ return r && r(c.scrollIntoView()), !0;
256
+ };
257
+ }
258
+ const _ = Z(), ae = (t, e) => {
259
+ let { $from: r, to: n } = t.selection, o, l = r.sharedDepth(n);
260
+ return l == 0 ? !1 : (o = r.before(l), e && e(t.tr.setSelection(d.create(t.doc, o))), !0);
261
+ };
262
+ function ee(t, e, r) {
263
+ let n = e.nodeBefore, o = e.nodeAfter, l = e.index();
264
+ return !n || !o || !n.type.compatibleContent(o.type) ? !1 : !n.content.size && e.parent.canReplace(l - 1, l) ? (r && r(t.tr.delete(e.pos - n.nodeSize, e.pos).scrollIntoView()), !0) : !e.parent.canReplace(l, l + 1) || !(o.isTextblock || A(t.doc, e.pos)) ? !1 : (r && r(t.tr.join(e.pos).scrollIntoView()), !0);
265
+ }
266
+ function D(t, e, r, n) {
267
+ let o = e.nodeBefore, l = e.nodeAfter, i, f, s = o.type.spec.isolating || l.type.spec.isolating;
268
+ if (!s && ee(t, e, r))
269
+ return !0;
270
+ let p = !s && e.parent.canReplace(e.index(), e.index() + 1);
271
+ if (p && (i = (f = o.contentMatchAt(o.childCount)).findWrapping(l.type)) && f.matchType(i[0] || l.type).validEnd) {
272
+ if (r) {
273
+ let a = e.pos + l.nodeSize, u = S.empty;
274
+ for (let w = i.length - 1; w >= 0; w--)
275
+ u = S.from(i[w].create(null, u));
276
+ u = S.from(o.copy(u));
277
+ let b = t.tr.step(new O(e.pos - 1, a, e.pos, a, new y(u, 1, 0), i.length, !0)), g = b.doc.resolve(a + 2 * i.length);
278
+ g.nodeAfter && g.nodeAfter.type == o.type && A(b.doc, g.pos) && b.join(g.pos), r(b.scrollIntoView());
279
+ }
280
+ return !0;
281
+ }
282
+ let c = l.type.spec.isolating || n > 0 && s ? null : V.findFrom(e, 1), m = c && c.$from.blockRange(c.$to), k = m && T(m);
283
+ if (k != null && k >= e.depth)
284
+ return r && r(t.tr.lift(m, k).scrollIntoView()), !0;
285
+ if (p && x(l, "start", !0) && x(o, "end")) {
286
+ let a = o, u = [];
287
+ for (; u.push(a), !a.isTextblock; )
288
+ a = a.lastChild;
289
+ let b = l, g = 1;
290
+ for (; !b.isTextblock; b = b.firstChild)
291
+ g++;
292
+ if (a.canReplace(a.childCount, a.childCount, b.content)) {
293
+ if (r) {
294
+ let w = S.empty;
295
+ for (let C = u.length - 1; C >= 0; C--)
296
+ w = S.from(u[C].copy(w));
297
+ let q = t.tr.step(new O(e.pos - u.length, e.pos + l.nodeSize, e.pos + g, e.pos + l.nodeSize - g, new y(w, u.length, 0), 0, !0));
298
+ r(q.scrollIntoView());
299
+ }
300
+ return !0;
301
+ }
302
+ }
303
+ return !1;
304
+ }
305
+ function $(t) {
306
+ return function(e, r) {
307
+ let n = e.selection, o = t < 0 ? n.$from : n.$to, l = o.depth;
308
+ for (; o.node(l).isInline; ) {
309
+ if (!l)
310
+ return !1;
311
+ l--;
312
+ }
313
+ return o.node(l).isTextblock ? (r && r(e.tr.setSelection(I.create(e.doc, t < 0 ? o.start(l) : o.end(l)))), !0) : !1;
314
+ };
315
+ }
316
+ const ue = $(-1), pe = $(1);
317
+ function de(t, e = null) {
318
+ return function(r, n) {
319
+ let { $from: o, $to: l } = r.selection, i = o.blockRange(l), f = i && J(i, t, e);
320
+ return f ? (n && n(r.tr.wrap(i, f).scrollIntoView()), !0) : !1;
321
+ };
322
+ }
323
+ function me(t, e = null) {
324
+ return function(r, n) {
325
+ let o = !1;
326
+ for (let l = 0; l < r.selection.ranges.length && !o; l++) {
327
+ let { $from: { pos: i }, $to: { pos: f } } = r.selection.ranges[l];
328
+ r.doc.nodesBetween(i, f, (s, p) => {
329
+ if (o)
330
+ return !1;
331
+ if (!(!s.isTextblock || s.hasMarkup(t, e)))
332
+ if (s.type == t)
333
+ o = !0;
334
+ else {
335
+ let c = r.doc.resolve(p), m = c.index();
336
+ o = c.parent.canReplaceWith(m, m + 1, t);
337
+ }
338
+ });
339
+ }
340
+ if (!o)
341
+ return !1;
342
+ if (n) {
343
+ let l = r.tr;
344
+ for (let i = 0; i < r.selection.ranges.length; i++) {
345
+ let { $from: { pos: f }, $to: { pos: s } } = r.selection.ranges[i];
346
+ l.setBlockType(f, s, t, e);
347
+ }
348
+ n(l.scrollIntoView());
349
+ }
350
+ return !0;
351
+ };
352
+ }
353
+ function F(...t) {
354
+ return function(e, r, n) {
355
+ for (let o = 0; o < t.length; o++)
356
+ if (t[o](e, r, n))
357
+ return !0;
358
+ return !1;
359
+ };
360
+ }
361
+ F(M, G, H);
362
+ F(M, K, L);
363
+ F(Q, X, Y, _);
364
+ typeof navigator < "u" ? /Mac|iP(hone|[oa]d)/.test(navigator.platform) : typeof os < "u" && os.platform && os.platform() == "darwin";
365
+ export {
366
+ ue as a,
367
+ pe as b,
368
+ ae as c,
369
+ L as d,
370
+ H as e,
371
+ se as f,
372
+ le as g,
373
+ oe as h,
374
+ K as i,
375
+ ie as j,
376
+ fe as k,
377
+ Y as l,
378
+ G as m,
379
+ Q as n,
380
+ ce as o,
381
+ M as p,
382
+ X as q,
383
+ me as s,
384
+ de as w
385
+ };
@@ -1,5 +1,5 @@
1
- import { P as w } from "./vendor-prosemirror-state-BN86J-Ko.js";
2
- import { d as v } from "./vendor-prosemirror-transform-B0c_LAV_.js";
1
+ import { P as w } from "./vendor-prosemirror-state-CRUasa1V.js";
2
+ import { d as v } from "./vendor-prosemirror-transform-BeDaI3CS.js";
3
3
  function y(m = {}) {
4
4
  return new w({
5
5
  view(e) {
@@ -1,7 +1,7 @@
1
- import { k as S } from "./vendor-prosemirror-keymap-CS1uIBpE.js";
2
- import { P as v, T as m, N as g, S as u } from "./vendor-prosemirror-state-BN86J-Ko.js";
3
- import { F as h, S as x } from "./vendor-prosemirror-model-DwojkhDQ.js";
4
- import { D as w, a as y } from "./vendor-prosemirror-view-DyWzmy4t.js";
1
+ import { k as S } from "./vendor-prosemirror-keymap-DWvoDWf6.js";
2
+ import { P as v, T as m, N as g, S as u } from "./vendor-prosemirror-state-CRUasa1V.js";
3
+ import { F as h, S as x } from "./vendor-prosemirror-model-CVTn1Stc.js";
4
+ import { D as w, a as y } from "./vendor-prosemirror-view-BGYdOWiJ.js";
5
5
  class i extends u {
6
6
  /**
7
7
  Create a gap cursor.
@@ -1,6 +1,6 @@
1
1
  import { R as b } from "./vendor-rope-sequence-sEGCUMi8.js";
2
- import { M as k } from "./vendor-prosemirror-transform-B0c_LAV_.js";
3
- import { P as H, a as O } from "./vendor-prosemirror-state-BN86J-Ko.js";
2
+ import { M as k } from "./vendor-prosemirror-transform-BeDaI3CS.js";
3
+ import { P as H, a as O } from "./vendor-prosemirror-state-CRUasa1V.js";
4
4
  const D = 500;
5
5
  class c {
6
6
  constructor(t, e) {
@@ -1,5 +1,5 @@
1
1
  import { k as u, b as c } from "./vendor-w3c-keyname-CLxH8j-f.js";
2
- import { P as d } from "./vendor-prosemirror-state-BN86J-Ko.js";
2
+ import { P as d } from "./vendor-prosemirror-state-CRUasa1V.js";
3
3
  const p = typeof navigator < "u" && /Mac|iP(hone|[oa]d)/.test(navigator.platform), y = typeof navigator < "u" && /Win/.test(navigator.platform);
4
4
  function m(e) {
5
5
  let r = e.split(/-(?!$)/), t = r[r.length - 1];
@@ -1,5 +1,5 @@
1
- import { a as A, M as w } from "./vendor-prosemirror-model-DwojkhDQ.js";
2
- import { M as S } from "./vendor-markdown-it-4AJoRTAg.js";
1
+ import { a as A, M as w } from "./vendor-prosemirror-model-CVTn1Stc.js";
2
+ import { M as S } from "./vendor-markdown-it-RJo-N9ov.js";
3
3
  const D = new A({
4
4
  nodes: {
5
5
  doc: {
@@ -1825,7 +1825,7 @@ class v {
1825
1825
  @internal
1826
1826
  */
1827
1827
  checkAttrs(t) {
1828
- ht(this.attrs, t, "node");
1828
+ ht(this.attrs, t, "node", this.name);
1829
1829
  }
1830
1830
  /**
1831
1831
  Check whether the given mark type is allowed in this node.
@@ -1932,7 +1932,7 @@ class F {
1932
1932
  @internal
1933
1933
  */
1934
1934
  checkAttrs(t) {
1935
- ht(this.attrs, t, "mark");
1935
+ ht(this.attrs, t, "mark", this.name);
1936
1936
  }
1937
1937
  /**
1938
1938
  Queries whether a given mark type is
@@ -1,5 +1,5 @@
1
- import { b as h, f as w, l as C, a as S, c as L } from "./vendor-prosemirror-transform-B0c_LAV_.js";
2
- import { F as u, S as I, N as x } from "./vendor-prosemirror-model-DwojkhDQ.js";
1
+ import { b as h, f as w, l as C, a as S, c as L } from "./vendor-prosemirror-transform-BeDaI3CS.js";
2
+ import { F as u, S as I, N as x } from "./vendor-prosemirror-model-CVTn1Stc.js";
3
3
  function O(r, t = null) {
4
4
  return function(e, l) {
5
5
  let { $from: o, $to: n } = e.selection, f = o.blockRange(n);
@@ -1,5 +1,5 @@
1
- import { S as m, F as x, b as B, M as R } from "./vendor-prosemirror-model-DwojkhDQ.js";
2
- import { R as P, b as K, T as $ } from "./vendor-prosemirror-transform-B0c_LAV_.js";
1
+ import { S as m, F as x, b as B, M as R } from "./vendor-prosemirror-model-CVTn1Stc.js";
2
+ import { R as P, b as K, T as $ } from "./vendor-prosemirror-transform-BeDaI3CS.js";
3
3
  const O = /* @__PURE__ */ Object.create(null);
4
4
  class l {
5
5
  /**
@@ -1,8 +1,8 @@
1
- import { P as fe, a as Z, S as N, b as ye, T as E, N as Se } from "./vendor-prosemirror-state-BN86J-Ko.js";
2
- import { F as R, S as v } from "./vendor-prosemirror-model-DwojkhDQ.js";
3
- import { D as X, a as q } from "./vendor-prosemirror-view-DyWzmy4t.js";
4
- import { k as Ae } from "./vendor-prosemirror-keymap-CS1uIBpE.js";
5
- import { T as Re } from "./vendor-prosemirror-transform-B0c_LAV_.js";
1
+ import { P as fe, a as Z, S as N, b as ye, T as E, N as Se } from "./vendor-prosemirror-state-CRUasa1V.js";
2
+ import { F as R, S as v } from "./vendor-prosemirror-model-CVTn1Stc.js";
3
+ import { D as X, a as q } from "./vendor-prosemirror-view-BGYdOWiJ.js";
4
+ import { k as Ae } from "./vendor-prosemirror-keymap-DWvoDWf6.js";
5
+ import { T as Re } from "./vendor-prosemirror-transform-BeDaI3CS.js";
6
6
  var J, U;
7
7
  if (typeof WeakMap < "u") {
8
8
  let t = /* @__PURE__ */ new WeakMap();
@@ -1,4 +1,4 @@
1
- import { S as w, F as g, M as se, c as oe, R as le } from "./vendor-prosemirror-model-DwojkhDQ.js";
1
+ import { S as w, F as g, M as se, c as oe, R as le } from "./vendor-prosemirror-model-CVTn1Stc.js";
2
2
  const Q = 65535, U = Math.pow(2, 16);
3
3
  function ae(s, e) {
4
4
  return s + e * U;