@mx-space/cli 0.7.8 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (55) hide show
  1. package/dist/{Lexical.dev-rcxzwpir.mjs → Lexical.dev-By5dOKBN.mjs} +1486 -356
  2. package/dist/{Lexical.node-BUsI9gWr.mjs → Lexical.node-fXM8Jp7p.mjs} +39 -17
  3. package/dist/{Lexical.prod-C8HtkSD6.mjs → Lexical.prod-BlCvXPGa.mjs} +2279 -1768
  4. package/dist/LexicalClipboard.dev--HxGoSkO.mjs +915 -0
  5. package/dist/{LexicalClipboard.node-CO-MCKx5.mjs → LexicalClipboard.node-C3mRbrmW.mjs} +10 -3
  6. package/dist/LexicalClipboard.prod-DNJzFMcT.mjs +371 -0
  7. package/dist/LexicalCodeCore.dev-DjSrd4A4.mjs +1109 -0
  8. package/dist/LexicalCodeCore.prod-DTDShkR3.mjs +642 -0
  9. package/dist/{LexicalDragon.dev-gBP8WSRS.mjs → LexicalDragon.dev-DwprRH0z.mjs} +3 -3
  10. package/dist/{LexicalDragon.node-OG6G55nl.mjs → LexicalDragon.node-BVhw4C7s.mjs} +2 -2
  11. package/dist/{LexicalDragon.prod-DP-_Q8cv.mjs → LexicalDragon.prod-nh4J-8vn.mjs} +3 -3
  12. package/dist/{LexicalExtension.dev-DVbjljrm.mjs → LexicalExtension.dev-BPNyvGqe.mjs} +335 -6
  13. package/dist/{LexicalExtension.node-CF3EAPN7.mjs → LexicalExtension.node-BVlcrgOx.mjs} +15 -8
  14. package/dist/{LexicalExtension.prod-DklHHErZ.mjs → LexicalExtension.prod-DFKbiNt-.mjs} +375 -265
  15. package/dist/{LexicalHeadless.dev-DdWLM7Nl.mjs → LexicalHeadless.dev-B-cj7Pr5.mjs} +2 -2
  16. package/dist/{LexicalHeadless.prod-CoiiTDzR.mjs → LexicalHeadless.prod-Byp1vNzT.mjs} +2 -2
  17. package/dist/LexicalHtml.dev-prBAwszN.mjs +2424 -0
  18. package/dist/LexicalHtml.node-BvNF96jZ.mjs +56 -0
  19. package/dist/LexicalHtml.prod-Sz3CW1ht.mjs +1207 -0
  20. package/dist/{LexicalLink.dev-BS1Bf-yD.mjs → LexicalLink.dev-NySTYhVR.mjs} +42 -8
  21. package/dist/{LexicalLink.prod-B_crkoHP.mjs → LexicalLink.prod-BuCM8gts.mjs} +209 -191
  22. package/dist/{LexicalList.dev-OMqmcnQ-.mjs → LexicalList.dev-DIMOvSFD.mjs} +252 -80
  23. package/dist/{LexicalList.prod-CpL1s8vS.mjs → LexicalList.prod-MVqfA6Vo.mjs} +364 -278
  24. package/dist/{LexicalMarkdown.dev-BHSdx_Gr.mjs → LexicalMarkdown.dev-C7aylvCG.mjs} +729 -552
  25. package/dist/LexicalMarkdown.prod-CfQSM406.mjs +868 -0
  26. package/dist/{LexicalRichText.dev-Bz9A_WbM.mjs → LexicalRichText.dev-DfICq6lU.mjs} +272 -77
  27. package/dist/{LexicalRichText.node-DDpwfE-P.mjs → LexicalRichText.node-Bg9jND3Q.mjs} +21 -8
  28. package/dist/LexicalRichText.prod-GsFzCK-o.mjs +550 -0
  29. package/dist/{LexicalSelection.dev-CQ380fnD.mjs → LexicalSelection.dev-DGjj12wW.mjs} +50 -38
  30. package/dist/{LexicalSelection.node-DesBMjIE.mjs → LexicalSelection.node-BU5L4193.mjs} +4 -4
  31. package/dist/{LexicalSelection.prod-D2jivCDB.mjs → LexicalSelection.prod-D-PwRbyK.mjs} +158 -140
  32. package/dist/{LexicalTable.dev-Ca7mQ7Jk.mjs → LexicalTable.dev-ChP7cugd.mjs} +215 -53
  33. package/dist/{LexicalTable.prod-DyPAcC7y.mjs → LexicalTable.prod-Bpr9YRXp.mjs} +668 -573
  34. package/dist/{LexicalUtils.dev-HxM8F0g6.mjs → LexicalUtils.dev-BiFU3789.mjs} +10 -47
  35. package/dist/{LexicalUtils.node-lCWjRjoG.mjs → LexicalUtils.node-j3Llm7Y3.mjs} +2 -2
  36. package/dist/{LexicalUtils.prod-Bti5w4ki.mjs → LexicalUtils.prod-DCvrA78p.mjs} +103 -105
  37. package/dist/bin/mxs.d.mts +1 -1
  38. package/dist/bin/mxs.mjs +1 -1
  39. package/dist/esm-By7trG9K.mjs +2 -0
  40. package/dist/{esm-CK9m5JKX.mjs → esm-Dg-WhPCe.mjs} +989 -989
  41. package/dist/index.d.mts +1 -1
  42. package/dist/index.mjs +1 -1
  43. package/dist/{mxs-BZt1cLW9.mjs → mxs-DT0oYk6U.mjs} +11935 -11866
  44. package/package.json +15 -14
  45. package/dist/LexicalClipboard.dev-BpqRwTLP.mjs +0 -494
  46. package/dist/LexicalClipboard.prod-B_xdeiAC.mjs +0 -291
  47. package/dist/LexicalCodeCore.dev-7_cexm39.mjs +0 -537
  48. package/dist/LexicalCodeCore.prod-Bd6WFHcO.mjs +0 -381
  49. package/dist/LexicalHtml.dev-C3ZSWBFZ.mjs +0 -684
  50. package/dist/LexicalHtml.node-D0TD152E.mjs +0 -24
  51. package/dist/LexicalHtml.prod-CX47X0zl.mjs +0 -430
  52. package/dist/LexicalMarkdown.prod-C-S7Ii6-.mjs +0 -754
  53. package/dist/LexicalRichText.prod-C8qXACDL.mjs +0 -427
  54. package/dist/esm-DRbkkY3r.mjs +0 -2
  55. /package/dist/{mxs-CM8-6uAr.d.mts → mxs-iqJBopvE.d.mts} +0 -0
@@ -1,381 +0,0 @@
1
- import { o as getPeerDependencyFromEditor } from "./LexicalExtension.node-CF3EAPN7.mjs";
2
- import { At as COMMAND_PRIORITY_LOW, B as $getSiblingCaret, Gn as isHTMLElement, Ht as ElementNode, Mn as defineExtension, Qn as removeClassNamesFromElement, Rn as getTextDirection, Tn as addClassNamesToElement, Y as $isElementNode, ct as $isTextNode, er as setDOMStyleFromCSS, et as $isLineBreakNode, f as $createParagraphNode, g as $createTabNode, j as $getEditor, l as $create, n as $applyNodeReplacement, on as KEY_ENTER_COMMAND, rt as $isRangeSelection, st as $isTabNode, u as $createLineBreakNode, wn as TextNode, z as $getSelection } from "./Lexical.node-BUsI9gWr.mjs";
3
- //#region ../../node_modules/.pnpm/@lexical+code-core@0.44.0/node_modules/@lexical/code-core/LexicalCodeCore.prod.mjs
4
- /**
5
- * Copyright (c) Meta Platforms, Inc. and affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- *
10
- */
11
- function C(t, ...e) {
12
- const n = new URL("https://lexical.dev/docs/error"), r = new URLSearchParams();
13
- r.append("code", t);
14
- for (const t of e) r.append("v", t);
15
- throw n.search = r.toString(), Error(`Minified Lexical error #${t}; visit ${n.toString()} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`);
16
- }
17
- function N(t, e) {
18
- let r = t;
19
- for (let o = $getSiblingCaret(t, e); o && (X(o.origin) || $isTabNode(o.origin)); o = o.getAdjacentCaret()) r = o.origin;
20
- return r;
21
- }
22
- function O(t) {
23
- return N(t, "previous");
24
- }
25
- function A(t) {
26
- return N(t, "next");
27
- }
28
- function H(n) {
29
- const r = O(n), i = A(n);
30
- let o = r;
31
- for (; null !== o;) {
32
- if (X(o)) {
33
- const e = getTextDirection(o.getTextContent());
34
- if (null !== e) return e;
35
- }
36
- if (o === i) break;
37
- o = o.getNextSibling();
38
- }
39
- const s = r.getParent();
40
- if ($isElementNode(s)) {
41
- const t = s.getDirection();
42
- if ("ltr" === t || "rtl" === t) return t;
43
- }
44
- return null;
45
- }
46
- function L(t, e) {
47
- let i = null, o = null, s = t, l = e, u = t.getTextContent();
48
- for (;;) {
49
- if (0 === l) {
50
- if (s = s.getPreviousSibling(), null === s) break;
51
- if (X(s) || $isTabNode(s) || $isLineBreakNode(s) || C(167), $isLineBreakNode(s)) {
52
- i = {
53
- node: s,
54
- offset: 1
55
- };
56
- break;
57
- }
58
- l = Math.max(0, s.getTextContentSize() - 1), u = s.getTextContent();
59
- } else l--;
60
- const t = u[l];
61
- X(s) && " " !== t && (o = {
62
- node: s,
63
- offset: l
64
- });
65
- }
66
- if (null !== o) return o;
67
- let g = null;
68
- if (e < t.getTextContentSize()) X(t) && (g = t.getTextContent()[e]);
69
- else {
70
- const e = t.getNextSibling();
71
- X(e) && (g = e.getTextContent()[0]);
72
- }
73
- if (null !== g && " " !== g) return i;
74
- {
75
- const n = function(t, e) {
76
- let n = t, i = e, o = t.getTextContent(), s = t.getTextContentSize();
77
- for (;;) {
78
- if (!X(n) || i === s) {
79
- if (n = n.getNextSibling(), null === n || $isLineBreakNode(n)) return null;
80
- X(n) && (i = 0, o = n.getTextContent(), s = n.getTextContentSize());
81
- }
82
- if (X(n)) {
83
- if (" " !== o[i]) return {
84
- node: n,
85
- offset: i
86
- };
87
- i++;
88
- }
89
- }
90
- }(t, e);
91
- return null !== n ? n : i;
92
- }
93
- }
94
- function F(t) {
95
- const e = A(t);
96
- return $isLineBreakNode(e) && C(168), e;
97
- }
98
- const J = "javascript", D = () => J;
99
- function M(t, e) {
100
- for (const n of t.childNodes) {
101
- if (isHTMLElement(n) && n.tagName === e) return !0;
102
- M(n, e);
103
- }
104
- return !1;
105
- }
106
- const k = "data-language", w = "data-highlight-language", P = "data-theme";
107
- var z = class z extends ElementNode {
108
- __language;
109
- __theme;
110
- __isSyntaxHighlightSupported;
111
- static getType() {
112
- return "code";
113
- }
114
- static clone(t) {
115
- return new z(t.__language, t.__key);
116
- }
117
- constructor(t, e) {
118
- super(e), this.__language = t || void 0, this.__isSyntaxHighlightSupported = !1, this.__theme = void 0;
119
- }
120
- afterCloneFrom(t) {
121
- super.afterCloneFrom(t), this.__language = t.__language, this.__theme = t.__theme, this.__isSyntaxHighlightSupported = t.__isSyntaxHighlightSupported;
122
- }
123
- createDOM(t) {
124
- const e = document.createElement("code");
125
- addClassNamesToElement(e, t.theme.code), e.setAttribute("spellcheck", "false");
126
- const n = this.getLanguage();
127
- n && (e.setAttribute(k, n), this.getIsSyntaxHighlightSupported() && e.setAttribute(w, n));
128
- const r = this.getTheme();
129
- r && e.setAttribute(P, r);
130
- const i = this.getStyle();
131
- return i && setDOMStyleFromCSS(e.style, i), e;
132
- }
133
- updateDOM(t, e, n) {
134
- const r = this.__language, i = t.__language;
135
- r ? r !== i && e.setAttribute(k, r) : i && e.removeAttribute(k);
136
- const o = this.__isSyntaxHighlightSupported;
137
- t.__isSyntaxHighlightSupported && i ? o && r ? r !== i && e.setAttribute(w, r) : e.removeAttribute(w) : o && r && e.setAttribute(w, r);
138
- const s = this.__theme, l = t.__theme;
139
- s ? s !== l && e.setAttribute(P, s) : l && e.removeAttribute(P);
140
- const g = this.__style, a = t.__style;
141
- return g !== a && setDOMStyleFromCSS(e.style, g, a), !1;
142
- }
143
- exportDOM(t) {
144
- const e = document.createElement("pre");
145
- addClassNamesToElement(e, t._config.theme.code), e.setAttribute("spellcheck", "false");
146
- const n = this.getLanguage();
147
- n && (e.setAttribute(k, n), this.getIsSyntaxHighlightSupported() && e.setAttribute(w, n));
148
- const r = this.getTheme();
149
- r && e.setAttribute(P, r);
150
- const i = this.getStyle();
151
- return i && setDOMStyleFromCSS(e.style, i), { element: e };
152
- }
153
- static importDOM() {
154
- return {
155
- code: (t) => null != t.textContent && (/\r?\n/.test(t.textContent) || M(t, "BR")) ? {
156
- conversion: j,
157
- priority: 1
158
- } : null,
159
- div: () => ({
160
- conversion: R,
161
- priority: 1
162
- }),
163
- pre: () => ({
164
- conversion: j,
165
- priority: 0
166
- }),
167
- table: (t) => q(t) ? {
168
- conversion: B,
169
- priority: 3
170
- } : null,
171
- td: (t) => {
172
- const e = t, n = e.closest("table");
173
- return e.classList.contains("js-file-line") || n && q(n) ? {
174
- conversion: U,
175
- priority: 3
176
- } : null;
177
- },
178
- tr: (t) => {
179
- const e = t.closest("table");
180
- return e && q(e) ? {
181
- conversion: U,
182
- priority: 3
183
- } : null;
184
- }
185
- };
186
- }
187
- static importJSON(t) {
188
- return I().updateFromJSON(t);
189
- }
190
- updateFromJSON(t) {
191
- return super.updateFromJSON(t).setLanguage(t.language).setTheme(t.theme);
192
- }
193
- exportJSON() {
194
- return {
195
- ...super.exportJSON(),
196
- language: this.getLanguage(),
197
- theme: this.getTheme()
198
- };
199
- }
200
- insertNewAfter(t, e = !0) {
201
- if (!getPeerDependencyFromEditor($getEditor(), "@lexical/code")) {
202
- const e = G(t);
203
- if (e) return e;
204
- }
205
- const { anchor: r, focus: i } = t, o = (r.isBefore(i) ? r : i).getNode();
206
- if ($isTextNode(o)) {
207
- let t = O(o);
208
- const e = [];
209
- for (;;) if ($isTabNode(t)) e.push($createTabNode()), t = t.getNextSibling();
210
- else {
211
- if (!X(t)) break;
212
- {
213
- let n = 0;
214
- const r = t.getTextContent(), i = t.getTextContentSize();
215
- for (; n < i && " " === r[n];) n++;
216
- if (0 !== n && e.push(V(" ".repeat(n))), n !== i) break;
217
- t = t.getNextSibling();
218
- }
219
- }
220
- const i = o.splitText(r.offset)[0], s = 0 === r.offset ? 0 : 1, l = i.getIndexWithinParent() + s, u = o.getParentOrThrow(), g = [$createLineBreakNode(), ...e];
221
- u.splice(l, 0, g);
222
- const a = e[e.length - 1];
223
- a ? a.select() : 0 === r.offset ? i.selectPrevious() : i.getNextSibling().selectNext(0, 0);
224
- }
225
- if (W(o)) {
226
- const { offset: e } = t.anchor;
227
- o.splice(e, 0, [$createLineBreakNode()]), o.select(e + 1, e + 1);
228
- }
229
- return null;
230
- }
231
- canIndent() {
232
- return !1;
233
- }
234
- collapseAtStart() {
235
- const t = $createParagraphNode();
236
- return this.getChildren().forEach((e) => t.append(e)), this.replace(t), !0;
237
- }
238
- setLanguage(t) {
239
- const e = this.getWritable();
240
- return e.__language = t || void 0, e;
241
- }
242
- getLanguage() {
243
- return this.getLatest().__language;
244
- }
245
- setIsSyntaxHighlightSupported(t) {
246
- const e = this.getWritable();
247
- return e.__isSyntaxHighlightSupported = t, e;
248
- }
249
- getIsSyntaxHighlightSupported() {
250
- return this.getLatest().__isSyntaxHighlightSupported;
251
- }
252
- setTheme(t) {
253
- const e = this.getWritable();
254
- return e.__theme = t || void 0, e;
255
- }
256
- getTheme() {
257
- return this.getLatest().__theme;
258
- }
259
- };
260
- function I(t, e) {
261
- return $create(z).setLanguage(t).setTheme(e);
262
- }
263
- function W(t) {
264
- return t instanceof z;
265
- }
266
- function j(t) {
267
- return { node: I(t.getAttribute(k)) };
268
- }
269
- function R(t) {
270
- const e = t, n = $(e);
271
- return n || function(t) {
272
- let e = t.parentElement;
273
- for (; null !== e;) {
274
- if ($(e)) return !0;
275
- e = e.parentElement;
276
- }
277
- return !1;
278
- }(e) ? { node: n ? I() : null } : { node: null };
279
- }
280
- function B() {
281
- return { node: I() };
282
- }
283
- function U() {
284
- return { node: null };
285
- }
286
- function $(t) {
287
- return null !== t.style.fontFamily.match("monospace");
288
- }
289
- function q(t) {
290
- return t.classList.contains("js-file-line-container");
291
- }
292
- function G(t) {
293
- const { anchor: e } = t;
294
- if (t.isCollapsed() && "element" === e.type) {
295
- const t = e.getNode();
296
- if (W(t)) {
297
- const n = t.getChildrenSize();
298
- if (n >= 2 && e.offset === n) {
299
- const e = t.getLastChild();
300
- if ($isLineBreakNode(e) && $isLineBreakNode(e.getPreviousSibling())) {
301
- const e = $createParagraphNode();
302
- return t.splice(n - 2, 2, []).insertAfter(e, !1), e.select(), e;
303
- }
304
- }
305
- }
306
- }
307
- return null;
308
- }
309
- var K = class K extends TextNode {
310
- __highlightType;
311
- constructor(t = "", e, n) {
312
- super(t, n), this.__highlightType = e;
313
- }
314
- static getType() {
315
- return "code-highlight";
316
- }
317
- static clone(t) {
318
- return new K(t.__text, t.__highlightType || void 0, t.__key);
319
- }
320
- afterCloneFrom(t) {
321
- super.afterCloneFrom(t), this.__highlightType = t.__highlightType;
322
- }
323
- getHighlightType() {
324
- return this.getLatest().__highlightType;
325
- }
326
- setHighlightType(t) {
327
- const e = this.getWritable();
328
- return e.__highlightType = t || void 0, e;
329
- }
330
- canHaveFormat() {
331
- return !1;
332
- }
333
- createDOM(t) {
334
- const e = super.createDOM(t);
335
- return addClassNamesToElement(e, Q(t.theme, this.__highlightType)), e;
336
- }
337
- updateDOM(t, e, n) {
338
- const r = super.updateDOM(t, e, n), i = Q(n.theme, t.__highlightType), o = Q(n.theme, this.__highlightType);
339
- return i !== o && (i && removeClassNamesFromElement(e, i), o && addClassNamesToElement(e, o)), r;
340
- }
341
- static importJSON(t) {
342
- return V().updateFromJSON(t);
343
- }
344
- updateFromJSON(t) {
345
- return super.updateFromJSON(t).setHighlightType(t.highlightType);
346
- }
347
- exportJSON() {
348
- return {
349
- ...super.exportJSON(),
350
- highlightType: this.getHighlightType()
351
- };
352
- }
353
- setFormat(t) {
354
- return this;
355
- }
356
- isParentRequired() {
357
- return !0;
358
- }
359
- createParentElementNode() {
360
- return I();
361
- }
362
- };
363
- function Q(t, e) {
364
- return e && t && t.codeHighlight && t.codeHighlight[e];
365
- }
366
- function V(t = "", e) {
367
- return $applyNodeReplacement(new K(t, e));
368
- }
369
- function X(t) {
370
- return t instanceof K;
371
- }
372
- const Y = defineExtension({
373
- name: "@lexical/code",
374
- nodes: () => [z, K],
375
- register: (t) => t.registerCommand(KEY_ENTER_COMMAND, (t) => {
376
- const e = $getSelection();
377
- return !(!$isRangeSelection(e) || !G(e)) && (t.preventDefault(), !0);
378
- }, COMMAND_PRIORITY_LOW)
379
- });
380
- //#endregion
381
- export { V as $createCodeHighlightNode, I as $createCodeNode, H as $getCodeLineDirection, F as $getEndOfCodeInLine, O as $getFirstCodeNodeOfLine, A as $getLastCodeNodeOfLine, L as $getStartOfCodeInLine, X as $isCodeHighlightNode, W as $isCodeNode, Y as CodeExtension, K as CodeHighlightNode, z as CodeNode, J as DEFAULT_CODE_LANGUAGE, D as getDefaultCodeLanguage };