@onereach/ui-components 6.2.0-beta.3281.0 → 6.2.0-beta.3286.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.
- package/dist/bundled/v2/components/OrCode/OrCode.js +2 -2
- package/dist/bundled/v2/components/OrCode/index.js +4 -5
- package/dist/bundled/v2/components/OrCode/lang.js +5 -5
- package/dist/bundled/v2/components/OrCode/libs.js +4 -5
- package/dist/bundled/v2/components/OrCode/theme.js +1 -1
- package/dist/bundled/v2/components/OrCodeV3/OrCode.js +24 -12
- package/dist/bundled/v2/components/OrCodeV3/index.js +2 -3
- package/dist/bundled/v2/components/OrCodeV3/libs.d.ts +1 -3
- package/dist/bundled/v2/components/OrCodeV3/libs.js +2 -3
- package/dist/bundled/v2/components/index.js +5 -6
- package/dist/bundled/v2/{index-86927ce2.js → index-5ce3ef85.js} +831 -10
- package/dist/bundled/{v3/index-b6bfd165.js → v2/index-5dd41049.js} +4 -4
- package/dist/bundled/{v3/index-ae9c3d66.js → v2/index-5ee42d1f.js} +2 -2
- package/dist/bundled/v2/{index-8bffe4d5.js → index-61aeae22.js} +1 -184
- package/dist/bundled/v2/{index-bd1ee981.js → index-648acd9e.js} +1 -1
- package/dist/bundled/{v3/index-83070a21.js → v2/index-64a3a364.js} +3 -3
- package/dist/bundled/v2/{index-14ee755d.js → index-c26082b9.js} +1 -1
- package/dist/bundled/v2/{index-118afe52.js → index-e72fe4a8.js} +2 -2
- package/dist/bundled/v2/{index-586d2cf4.js → index-f31843f4.js} +2 -2
- package/dist/bundled/v2/index.js +5 -6
- package/dist/bundled/v3/{OrCode.vue_vue_type_script_lang-8355d429.js → OrCode.vue_vue_type_script_lang-8c5b4f6e.js} +2 -2
- package/dist/bundled/v3/{OrCode.vue_vue_type_script_lang-29120928.js → OrCode.vue_vue_type_script_lang-b46a0f8a.js} +24 -12
- package/dist/bundled/v3/components/OrCode/OrCode.js +2 -2
- package/dist/bundled/v3/components/OrCode/index.js +5 -6
- package/dist/bundled/v3/components/OrCode/lang.js +5 -5
- package/dist/bundled/v3/components/OrCode/libs.js +4 -5
- package/dist/bundled/v3/components/OrCode/theme.js +1 -1
- package/dist/bundled/v3/components/OrCodeV3/OrCode.js +2 -2
- package/dist/bundled/v3/components/OrCodeV3/index.js +3 -4
- package/dist/bundled/v3/components/OrCodeV3/libs.d.ts +1 -3
- package/dist/bundled/v3/components/OrCodeV3/libs.js +2 -3
- package/dist/bundled/v3/components/index.js +7 -8
- package/dist/bundled/v3/{index-1ec4fb10.js → index-19d70079.js} +2 -2
- package/dist/bundled/{v2/index-181d90ab.js → v3/index-22f7d3aa.js} +3 -3
- package/dist/bundled/v3/{index-93c7d0e8.js → index-792c62f6.js} +2 -2
- package/dist/bundled/{v2/index-49b0c759.js → v3/index-84ea2fc8.js} +4 -4
- package/dist/bundled/v3/{index-e488383c.js → index-929b54f2.js} +1 -184
- package/dist/bundled/{v2/index-bbdfebea.js → v3/index-b71d76f4.js} +2 -2
- package/dist/bundled/v3/{index-68fb579e.js → index-bb6d92dd.js} +1 -1
- package/dist/bundled/v3/{index-7006d0a5.js → index-df2529d7.js} +1 -1
- package/dist/bundled/v3/{index-b6a28985.js → index-f92296d7.js} +831 -10
- package/dist/bundled/v3/index.js +7 -8
- package/dist/esm/v2/{OrCode-920482b7.js → OrCode-adb9790d.js} +16 -4
- package/dist/esm/v2/components/index.js +3 -3
- package/dist/esm/v2/components/or-code-v3/index.js +3 -4
- package/dist/esm/v2/components/or-code-v3/libs.d.ts +1 -3
- package/dist/esm/v2/index.js +3 -3
- package/dist/esm/v3/{OrCode-a9234c28.js → OrCode-5457417e.js} +16 -4
- package/dist/esm/v3/components/index.js +3 -3
- package/dist/esm/v3/components/or-code-v3/index.js +3 -4
- package/dist/esm/v3/components/or-code-v3/libs.d.ts +1 -3
- package/dist/esm/v3/index.js +3 -3
- package/package.json +1 -1
- package/src/components/or-code-v3/OrCode.vue +14 -4
- package/src/components/or-code-v3/libs.ts +1 -6
- package/dist/bundled/v2/index-c6b2aeae.js +0 -825
- package/dist/bundled/v3/index-e556efde.js +0 -825
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { C as ContextTracker, E as ExternalTokenizer, L as LRParser } from './index-
|
|
2
|
-
import {
|
|
3
|
-
import { cssLanguage, css } from './index-
|
|
4
|
-
import { typescriptLanguage, jsxLanguage, tsxLanguage, javascriptLanguage, javascript } from './index-
|
|
1
|
+
import { C as ContextTracker, E as ExternalTokenizer, L as LRParser } from './index-648acd9e.js';
|
|
2
|
+
import { a3 as styleTags, a4 as tags, ah as parseMixed, a5 as LanguageSupport, E as EditorView, s as syntaxTree, b as EditorSelection, a6 as LRLanguage, a7 as indentNodeProp, ab as foldNodeProp, ai as bracketMatchingHandle } from './index-61aeae22.js';
|
|
3
|
+
import { cssLanguage, css } from './index-e72fe4a8.js';
|
|
4
|
+
import { typescriptLanguage, jsxLanguage, tsxLanguage, javascriptLanguage, javascript } from './index-64a3a364.js';
|
|
5
5
|
|
|
6
6
|
// This file was generated by lezer-generator. You probably shouldn't edit it.
|
|
7
7
|
const scriptText = 54,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { html } from './index-
|
|
1
|
+
import { ap as NodeType, N as NodeProp, a3 as styleTags, ao as NodeSet, a4 as tags, an as Parser, as as Tag, ar as Tree, ah as parseMixed, a5 as LanguageSupport, P as Prec, k as keymap, at as Language, s as syntaxTree, b as EditorSelection, af as defineLanguageFacet, ab as foldNodeProp, a7 as indentNodeProp, au as languageDataProp, av as foldService, aw as LanguageDescription, ax as ParseContext } from './index-61aeae22.js';
|
|
2
|
+
import { html } from './index-5dd41049.js';
|
|
3
3
|
|
|
4
4
|
class CompositeBlock {
|
|
5
5
|
constructor(type,
|
|
@@ -12429,41 +12429,6 @@ class TabWidget extends WidgetType {
|
|
|
12429
12429
|
return false;
|
|
12430
12430
|
}
|
|
12431
12431
|
}
|
|
12432
|
-
const plugin = /*@__PURE__*/ViewPlugin.fromClass(class {
|
|
12433
|
-
constructor() {
|
|
12434
|
-
this.height = 1000;
|
|
12435
|
-
this.attrs = {
|
|
12436
|
-
style: "padding-bottom: 1000px"
|
|
12437
|
-
};
|
|
12438
|
-
}
|
|
12439
|
-
update(update) {
|
|
12440
|
-
let {
|
|
12441
|
-
view
|
|
12442
|
-
} = update;
|
|
12443
|
-
let height = view.viewState.editorHeight - view.defaultLineHeight - view.documentPadding.top - 0.5;
|
|
12444
|
-
if (height != this.height) {
|
|
12445
|
-
this.height = height;
|
|
12446
|
-
this.attrs = {
|
|
12447
|
-
style: `padding-bottom: ${height}px`
|
|
12448
|
-
};
|
|
12449
|
-
}
|
|
12450
|
-
}
|
|
12451
|
-
});
|
|
12452
|
-
/**
|
|
12453
|
-
Returns an extension that makes sure the content has a bottom
|
|
12454
|
-
margin equivalent to the height of the editor, minus one line
|
|
12455
|
-
height, so that every line in the document can be scrolled to the
|
|
12456
|
-
top of the editor.
|
|
12457
|
-
|
|
12458
|
-
This is only meaningful when the editor is scrollable, and should
|
|
12459
|
-
not be enabled in editors that take the size of their content.
|
|
12460
|
-
*/
|
|
12461
|
-
function scrollPastEnd() {
|
|
12462
|
-
return [plugin, contentAttributes.of(view => {
|
|
12463
|
-
var _a;
|
|
12464
|
-
return ((_a = view.plugin(plugin)) === null || _a === void 0 ? void 0 : _a.attrs) || null;
|
|
12465
|
-
})];
|
|
12466
|
-
}
|
|
12467
12432
|
|
|
12468
12433
|
/**
|
|
12469
12434
|
Mark lines that have a cursor on them with the `"cm-activeLine"`
|
|
@@ -12497,57 +12462,6 @@ const activeLineHighlighter = /*@__PURE__*/ViewPlugin.fromClass(class {
|
|
|
12497
12462
|
}, {
|
|
12498
12463
|
decorations: v => v.decorations
|
|
12499
12464
|
});
|
|
12500
|
-
class Placeholder extends WidgetType {
|
|
12501
|
-
constructor(content) {
|
|
12502
|
-
super();
|
|
12503
|
-
this.content = content;
|
|
12504
|
-
}
|
|
12505
|
-
toDOM() {
|
|
12506
|
-
let wrap = document.createElement("span");
|
|
12507
|
-
wrap.className = "cm-placeholder";
|
|
12508
|
-
wrap.style.pointerEvents = "none";
|
|
12509
|
-
wrap.appendChild(typeof this.content == "string" ? document.createTextNode(this.content) : this.content);
|
|
12510
|
-
if (typeof this.content == "string") wrap.setAttribute("aria-label", "placeholder " + this.content);else wrap.setAttribute("aria-hidden", "true");
|
|
12511
|
-
return wrap;
|
|
12512
|
-
}
|
|
12513
|
-
coordsAt(dom) {
|
|
12514
|
-
let rects = dom.firstChild ? clientRectsFor(dom.firstChild) : [];
|
|
12515
|
-
if (!rects.length) return null;
|
|
12516
|
-
let style = window.getComputedStyle(dom.parentNode);
|
|
12517
|
-
let rect = flattenRect(rects[0], style.direction != "rtl");
|
|
12518
|
-
let lineHeight = parseInt(style.lineHeight);
|
|
12519
|
-
if (rect.bottom - rect.top > lineHeight * 1.5) return {
|
|
12520
|
-
left: rect.left,
|
|
12521
|
-
right: rect.right,
|
|
12522
|
-
top: rect.top,
|
|
12523
|
-
bottom: rect.top + lineHeight
|
|
12524
|
-
};
|
|
12525
|
-
return rect;
|
|
12526
|
-
}
|
|
12527
|
-
ignoreEvent() {
|
|
12528
|
-
return false;
|
|
12529
|
-
}
|
|
12530
|
-
}
|
|
12531
|
-
/**
|
|
12532
|
-
Extension that enables a placeholder—a piece of example content
|
|
12533
|
-
to show when the editor is empty.
|
|
12534
|
-
*/
|
|
12535
|
-
function placeholder(content) {
|
|
12536
|
-
return ViewPlugin.fromClass(class {
|
|
12537
|
-
constructor(view) {
|
|
12538
|
-
this.view = view;
|
|
12539
|
-
this.placeholder = Decoration.set([Decoration.widget({
|
|
12540
|
-
widget: new Placeholder(content),
|
|
12541
|
-
side: 1
|
|
12542
|
-
}).range(0)]);
|
|
12543
|
-
}
|
|
12544
|
-
get decorations() {
|
|
12545
|
-
return this.view.state.doc.length ? Decoration.none : this.placeholder;
|
|
12546
|
-
}
|
|
12547
|
-
}, {
|
|
12548
|
-
decorations: v => v.decorations
|
|
12549
|
-
});
|
|
12550
|
-
}
|
|
12551
12465
|
|
|
12552
12466
|
// Don't compute precise column positions for line offsets above this
|
|
12553
12467
|
// (since it could get expensive). Assume offset==column for them.
|
|
@@ -12725,13 +12639,6 @@ class TooltipViewManager {
|
|
|
12725
12639
|
return true;
|
|
12726
12640
|
}
|
|
12727
12641
|
}
|
|
12728
|
-
/**
|
|
12729
|
-
Creates an extension that configures tooltip behavior.
|
|
12730
|
-
*/
|
|
12731
|
-
function tooltips() {
|
|
12732
|
-
let config = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
12733
|
-
return tooltipConfig.of(config);
|
|
12734
|
-
}
|
|
12735
12642
|
function windowSpace(view) {
|
|
12736
12643
|
let {
|
|
12737
12644
|
win
|
|
@@ -13236,27 +13143,7 @@ function getTooltip(view, tooltip) {
|
|
|
13236
13143
|
let found = plugin.manager.tooltips.indexOf(tooltip);
|
|
13237
13144
|
return found < 0 ? null : plugin.manager.tooltipViews[found];
|
|
13238
13145
|
}
|
|
13239
|
-
/**
|
|
13240
|
-
Returns true if any hover tooltips are currently active.
|
|
13241
|
-
*/
|
|
13242
|
-
function hasHoverTooltips(state) {
|
|
13243
|
-
return state.facet(showHoverTooltip).some(x => x);
|
|
13244
|
-
}
|
|
13245
13146
|
const closeHoverTooltipEffect = /*@__PURE__*/StateEffect.define();
|
|
13246
|
-
/**
|
|
13247
|
-
Transaction effect that closes all hover tooltips.
|
|
13248
|
-
*/
|
|
13249
|
-
const closeHoverTooltips = /*@__PURE__*/closeHoverTooltipEffect.of(null);
|
|
13250
|
-
/**
|
|
13251
|
-
Tell the tooltip extension to recompute the position of the active
|
|
13252
|
-
tooltips. This can be useful when something happens (such as a
|
|
13253
|
-
re-positioning or CSS change affecting the editor) that could
|
|
13254
|
-
invalidate the existing tooltip positions.
|
|
13255
|
-
*/
|
|
13256
|
-
function repositionTooltips(view) {
|
|
13257
|
-
var _a;
|
|
13258
|
-
(_a = view.plugin(tooltipPlugin)) === null || _a === void 0 ? void 0 : _a.maybeMeasure();
|
|
13259
|
-
}
|
|
13260
13147
|
const panelConfig = /*@__PURE__*/Facet.define({
|
|
13261
13148
|
combine(configs) {
|
|
13262
13149
|
let topContainer, bottomContainer;
|
|
@@ -13271,12 +13158,6 @@ const panelConfig = /*@__PURE__*/Facet.define({
|
|
|
13271
13158
|
}
|
|
13272
13159
|
});
|
|
13273
13160
|
/**
|
|
13274
|
-
Configures the panel-managing extension.
|
|
13275
|
-
*/
|
|
13276
|
-
function panels(config) {
|
|
13277
|
-
return config ? [panelConfig.of(config)] : [];
|
|
13278
|
-
}
|
|
13279
|
-
/**
|
|
13280
13161
|
Get the active panel created by the given constructor, if any.
|
|
13281
13162
|
This can be useful when you need access to your panels' DOM
|
|
13282
13163
|
structure.
|
|
@@ -13857,70 +13738,6 @@ line](https://codemirror.net/6/docs/ref/#view.highlightActiveLine).
|
|
|
13857
13738
|
function highlightActiveLineGutter() {
|
|
13858
13739
|
return activeLineGutterHighlighter;
|
|
13859
13740
|
}
|
|
13860
|
-
const WhitespaceDeco = /*@__PURE__*/new Map();
|
|
13861
|
-
function getWhitespaceDeco(space) {
|
|
13862
|
-
let deco = WhitespaceDeco.get(space);
|
|
13863
|
-
if (!deco) WhitespaceDeco.set(space, deco = Decoration.mark({
|
|
13864
|
-
attributes: space === "\t" ? {
|
|
13865
|
-
class: "cm-highlightTab"
|
|
13866
|
-
} : {
|
|
13867
|
-
class: "cm-highlightSpace",
|
|
13868
|
-
"data-display": space.replace(/ /g, "·")
|
|
13869
|
-
}
|
|
13870
|
-
}));
|
|
13871
|
-
return deco;
|
|
13872
|
-
}
|
|
13873
|
-
function matcher(decorator) {
|
|
13874
|
-
return ViewPlugin.define(view => ({
|
|
13875
|
-
decorations: decorator.createDeco(view),
|
|
13876
|
-
update(u) {
|
|
13877
|
-
this.decorations = decorator.updateDeco(u, this.decorations);
|
|
13878
|
-
}
|
|
13879
|
-
}), {
|
|
13880
|
-
decorations: v => v.decorations
|
|
13881
|
-
});
|
|
13882
|
-
}
|
|
13883
|
-
const whitespaceHighlighter = /*@__PURE__*/matcher( /*@__PURE__*/new MatchDecorator({
|
|
13884
|
-
regexp: /\t| +/g,
|
|
13885
|
-
decoration: match => getWhitespaceDeco(match[0]),
|
|
13886
|
-
boundary: /\S/
|
|
13887
|
-
}));
|
|
13888
|
-
/**
|
|
13889
|
-
Returns an extension that highlights whitespace, adding a
|
|
13890
|
-
`cm-highlightSpace` class to stretches of spaces, and a
|
|
13891
|
-
`cm-highlightTab` class to individual tab characters. By default,
|
|
13892
|
-
the former are shown as faint dots, and the latter as arrows.
|
|
13893
|
-
*/
|
|
13894
|
-
function highlightWhitespace() {
|
|
13895
|
-
return whitespaceHighlighter;
|
|
13896
|
-
}
|
|
13897
|
-
const trailingHighlighter = /*@__PURE__*/matcher( /*@__PURE__*/new MatchDecorator({
|
|
13898
|
-
regexp: /\s+$/g,
|
|
13899
|
-
decoration: /*@__PURE__*/Decoration.mark({
|
|
13900
|
-
class: "cm-trailingSpace"
|
|
13901
|
-
}),
|
|
13902
|
-
boundary: /\S/
|
|
13903
|
-
}));
|
|
13904
|
-
/**
|
|
13905
|
-
Returns an extension that adds a `cm-trailingSpace` class to all
|
|
13906
|
-
trailing whitespace.
|
|
13907
|
-
*/
|
|
13908
|
-
function highlightTrailingWhitespace() {
|
|
13909
|
-
return trailingHighlighter;
|
|
13910
|
-
}
|
|
13911
|
-
|
|
13912
|
-
/**
|
|
13913
|
-
@internal
|
|
13914
|
-
*/
|
|
13915
|
-
const __test = {
|
|
13916
|
-
HeightMap,
|
|
13917
|
-
HeightOracle,
|
|
13918
|
-
MeasuredHeights,
|
|
13919
|
-
QueryType,
|
|
13920
|
-
ChangedRange,
|
|
13921
|
-
computeOrder,
|
|
13922
|
-
moveVisually
|
|
13923
|
-
};
|
|
13924
13741
|
|
|
13925
13742
|
// FIXME profile adding a per-Tree TreeNode cache, validating it by
|
|
13926
13743
|
// parent pointer
|
|
@@ -18718,4 +18535,4 @@ function createTokenType(extra, tagStr) {
|
|
|
18718
18535
|
return type.id;
|
|
18719
18536
|
}
|
|
18720
18537
|
|
|
18721
|
-
export {
|
|
18538
|
+
export { rectangularSelection as $, Annotation as A, gutter as B, Compartment as C, Direction as D, EditorView as E, Facet as F, RangeSet as G, showTooltip as H, IndentContext as I, GutterMarker as J, lineNumbers as K, highlightActiveLineGutter as L, highlightSpecialChars as M, NodeProp as N, foldGutter as O, Prec as P, drawSelection as Q, RangeSetBuilder as R, StateField as S, Transaction as T, dropCursor as U, ViewPlugin as V, WidgetType as W, indentOnInput as X, syntaxHighlighting as Y, defaultHighlightStyle as Z, bracketMatching as _, EditorState as a, crosshairCursor as a0, highlightActiveLine as a1, foldKeymap as a2, styleTags as a3, tags as a4, LanguageSupport as a5, LRLanguage as a6, indentNodeProp as a7, continuedIndent as a8, flatIndent as a9, delimitedIndent as aa, foldNodeProp as ab, foldInside as ac, sublanguageProp as ad, IterMode as ae, defineLanguageFacet as af, NodeWeakMap as ag, parseMixed as ah, bracketMatchingHandle as ai, getTooltip as aj, MapMode as ak, RangeValue as al, HighlightStyle as am, Parser as an, NodeSet as ao, NodeType as ap, DefaultBufferLength as aq, Tree as ar, Tag as as, Language as at, languageDataProp as au, foldService as av, LanguageDescription as aw, ParseContext as ax, EditorSelection as b, combineConfig as c, ChangeSet as d, ChangeDesc as e, Text as f, getIndentation as g, indentUnit as h, indentString as i, countColumn as j, keymap as k, getIndentUnit as l, StateEffect as m, matchBrackets as n, findClusterBreak as o, Decoration as p, codePointAt as q, codePointSize as r, syntaxTree as s, getPanel as t, CharCategory as u, fromCodePoint as v, showPanel as w, runScopeHandlers as x, hoverTooltip as y, logException as z };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { an as Parser, ao as NodeSet, ap as NodeType, aq as DefaultBufferLength, N as NodeProp, ar as Tree, ae as IterMode } from './index-61aeae22.js';
|
|
2
2
|
|
|
3
3
|
/// A parse stack. These are used internally by the parser to track
|
|
4
4
|
/// parsing progress. They also provide some properties and methods
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { C as ContextTracker, E as ExternalTokenizer, L as LRParser, a as LocalTokenGroup } from './index-
|
|
2
|
-
import {
|
|
3
|
-
import { i as ifNotIn, e as completeFromList, s as snippetCompletion } from './index-
|
|
1
|
+
import { C as ContextTracker, E as ExternalTokenizer, L as LRParser, a as LocalTokenGroup } from './index-648acd9e.js';
|
|
2
|
+
import { a3 as styleTags, a4 as tags, a5 as LanguageSupport, E as EditorView, s as syntaxTree, b as EditorSelection, a6 as LRLanguage, a7 as indentNodeProp, a8 as continuedIndent, a9 as flatIndent, aa as delimitedIndent, ab as foldNodeProp, ac as foldInside, ad as sublanguageProp, ae as IterMode, af as defineLanguageFacet, ag as NodeWeakMap } from './index-61aeae22.js';
|
|
3
|
+
import { i as ifNotIn, e as completeFromList, s as snippetCompletion } from './index-c26082b9.js';
|
|
4
4
|
|
|
5
5
|
// This file was generated by lezer-generator. You probably shouldn't edit it.
|
|
6
6
|
const noSemi = 302,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { s as syntaxTree, E as EditorView, r as codePointSize, q as codePointAt, b as EditorSelection, u as CharCategory, P as Prec, k as keymap, F as Facet, c as combineConfig, D as Direction, aj as getTooltip, V as ViewPlugin, z as logException, m as StateEffect, S as StateField, H as showTooltip, ak as MapMode, al as RangeValue, G as RangeSet, v as fromCodePoint, A as Annotation, f as Text, h as indentUnit, p as Decoration, W as WidgetType } from './index-61aeae22.js';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
An instance of this is passed to completion source functions.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { E as ExternalTokenizer, L as LRParser } from './index-
|
|
2
|
-
import {
|
|
1
|
+
import { E as ExternalTokenizer, L as LRParser } from './index-648acd9e.js';
|
|
2
|
+
import { a3 as styleTags, a4 as tags$1, a5 as LanguageSupport, s as syntaxTree, a6 as LRLanguage, a7 as indentNodeProp, a8 as continuedIndent, ab as foldNodeProp, ac as foldInside, ae as IterMode, ag as NodeWeakMap } from './index-61aeae22.js';
|
|
3
3
|
|
|
4
4
|
// This file was generated by lezer-generator. You probably shouldn't edit it.
|
|
5
5
|
const descendantOp = 95,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { L as LRParser } from './index-
|
|
2
|
-
import {
|
|
1
|
+
import { L as LRParser } from './index-648acd9e.js';
|
|
2
|
+
import { a3 as styleTags, a4 as tags, a5 as LanguageSupport, a6 as LRLanguage, a7 as indentNodeProp, a8 as continuedIndent, ab as foldNodeProp, ac as foldInside } from './index-61aeae22.js';
|
|
3
3
|
|
|
4
4
|
const jsonHighlighting = styleTags({
|
|
5
5
|
String: tags.string,
|
package/dist/bundled/v2/index.js
CHANGED
|
@@ -84,13 +84,12 @@ export { CardCollectionView, defaultViewModes, gridView, listView } from './comp
|
|
|
84
84
|
export { default as OrCheckboxTreeV3 } from './components/OrCheckboxTreeV3/OrCheckboxTree.js';
|
|
85
85
|
export { default as OrCheckboxV3 } from './components/OrCheckboxV3/OrCheckbox.js';
|
|
86
86
|
export { OrCodeLanguages } from './components/OrCode/constants.js';
|
|
87
|
-
export { b as basicSetup } from './index-
|
|
88
|
-
export {
|
|
89
|
-
export {
|
|
90
|
-
export {
|
|
91
|
-
export { html } from './index-49b0c759.js';
|
|
87
|
+
export { b as basicSetup, a as lintGutter, l as linter } from './index-5ce3ef85.js';
|
|
88
|
+
export { javascript } from './index-64a3a364.js';
|
|
89
|
+
export { json, jsonParseLinter } from './index-f31843f4.js';
|
|
90
|
+
export { html } from './index-5dd41049.js';
|
|
92
91
|
export { CodeLanguage } from './components/OrCodeV3/props.js';
|
|
93
|
-
export {
|
|
92
|
+
export { E as EditorView } from './index-61aeae22.js';
|
|
94
93
|
export { default as OrCollapse } from './components/OrCollapse/OrCollapse.js';
|
|
95
94
|
export { amber, black, blue, blueGrey, brown, cyan, deepOrange, deepPurple, green, indigo, lightBlue, lightGreen, lime, orange, pink, purple, red, teal, white, yellow } from './components/OrColorPicker/constants.js';
|
|
96
95
|
export { InputBoxSize as CombinedInputSize, InputBoxSize as DatePickerSize, InputBoxSize as DateTimePickerSize, InputBoxSize, InputBoxVariant, InputBoxSize as InputSize, InputBoxSize as SearchSize, InputBoxSize as SelectSize, InputBoxSize as TagInputSize, InputBoxSize as TextareaSize, InputBoxSize as TimePickerSize } from './components/OrInputBoxV3/props.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { b as basicSetup, i as indentWithTab } from './index-
|
|
1
|
+
import { E as EditorView, a as EditorState, k as keymap } from './index-929b54f2.js';
|
|
2
|
+
import { b as basicSetup, i as indentWithTab } from './index-f92296d7.js';
|
|
3
3
|
import { u as useElementHover } from './index-929e224a.js';
|
|
4
4
|
import { defineComponent, ref } from 'vue-demi';
|
|
5
5
|
import script$3 from './components/OrTeleport/OrTeleport.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineComponent, ref, computed, reactive, toRef, watch, onMounted, onUnmounted } from 'vue-demi';
|
|
2
|
-
import { b as basicSetup, i as indentWithTab } from './index-
|
|
3
|
-
import {
|
|
2
|
+
import { b as basicSetup, i as indentWithTab } from './index-f92296d7.js';
|
|
3
|
+
import { C as Compartment, k as keymap, a as EditorState, E as EditorView } from './index-929b54f2.js';
|
|
4
4
|
import { CodeLanguage } from './components/OrCodeV3/props.js';
|
|
5
5
|
import { Code, CodeControl } from './components/OrCodeV3/styles.js';
|
|
6
6
|
import './components/OrErrorV3/OrError.js';
|
|
@@ -94,19 +94,19 @@ var script = defineComponent({
|
|
|
94
94
|
const getLanguageExtension = async language => {
|
|
95
95
|
switch (language) {
|
|
96
96
|
case CodeLanguage.HTML:
|
|
97
|
-
return (await import('./index-
|
|
97
|
+
return (await import('./index-84ea2fc8.js')).html();
|
|
98
98
|
case CodeLanguage.CSS:
|
|
99
|
-
return (await import('./index-
|
|
99
|
+
return (await import('./index-792c62f6.js')).css();
|
|
100
100
|
case CodeLanguage.JS:
|
|
101
|
-
return (await import('./index-
|
|
101
|
+
return (await import('./index-22f7d3aa.js')).javascript();
|
|
102
102
|
case CodeLanguage.TS:
|
|
103
|
-
return (await import('./index-
|
|
103
|
+
return (await import('./index-22f7d3aa.js')).javascript({
|
|
104
104
|
typescript: true
|
|
105
105
|
});
|
|
106
106
|
case CodeLanguage.JSON:
|
|
107
|
-
return (await import('./index-
|
|
107
|
+
return (await import('./index-19d70079.js')).json();
|
|
108
108
|
case CodeLanguage.MD:
|
|
109
|
-
return (await import('./index-
|
|
109
|
+
return (await import('./index-b71d76f4.js')).markdown();
|
|
110
110
|
}
|
|
111
111
|
};
|
|
112
112
|
// Methods
|
|
@@ -159,11 +159,7 @@ var script = defineComponent({
|
|
|
159
159
|
const state = EditorState.create({
|
|
160
160
|
doc: proxyModelValue.value,
|
|
161
161
|
extensions: [...defaultExtensions, addedExtensionCompartment.of([])]
|
|
162
|
-
// selection: selection.ranges.some((range) => range.to > modelValue.length)
|
|
163
|
-
// ? { anchor: modelValue.length }
|
|
164
|
-
// : selection,
|
|
165
162
|
});
|
|
166
|
-
|
|
167
163
|
const editorView = new EditorView({
|
|
168
164
|
state,
|
|
169
165
|
dispatch: transaction => {
|
|
@@ -173,6 +169,22 @@ var script = defineComponent({
|
|
|
173
169
|
}
|
|
174
170
|
}
|
|
175
171
|
});
|
|
172
|
+
watch(proxyModelValue, value => {
|
|
173
|
+
const modelValue = value !== null && value !== void 0 ? value : '';
|
|
174
|
+
const {
|
|
175
|
+
selection
|
|
176
|
+
} = editorView.state;
|
|
177
|
+
editorView.dispatch({
|
|
178
|
+
changes: {
|
|
179
|
+
from: 0,
|
|
180
|
+
to: editorView.state.doc.length,
|
|
181
|
+
insert: modelValue
|
|
182
|
+
},
|
|
183
|
+
selection: selection.ranges.some(range => range.to > modelValue.length) ? {
|
|
184
|
+
anchor: modelValue.length
|
|
185
|
+
} : selection
|
|
186
|
+
});
|
|
187
|
+
});
|
|
176
188
|
watch([() => props.extensions, () => props.language], async _ref => {
|
|
177
189
|
let [extensions, language] = _ref;
|
|
178
190
|
const languageExt = await getLanguageExtension(language);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { s as script } from '../../OrCode.vue_vue_type_script_lang-
|
|
2
|
-
export { s as default } from '../../OrCode.vue_vue_type_script_lang-
|
|
1
|
+
import { s as script } from '../../OrCode.vue_vue_type_script_lang-8c5b4f6e.js';
|
|
2
|
+
export { s as default } from '../../OrCode.vue_vue_type_script_lang-8c5b4f6e.js';
|
|
3
3
|
import { resolveComponent, openBlock, createElementBlock, createVNode, withCtx, renderSlot, createElementVNode, normalizeClass, createBlock, createCommentVNode, withDirectives, vShow } from 'vue';
|
|
4
4
|
import { s as styleInject } from '../../style-inject.es-4c6f2515.js';
|
|
5
5
|
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
export { OrCodeLanguages } from './constants.js';
|
|
2
|
-
export { s as OrCode } from '../../OrCode.vue_vue_type_script_lang-
|
|
3
|
-
export { b as basicSetup } from '../../index-
|
|
4
|
-
export {
|
|
5
|
-
export {
|
|
6
|
-
export {
|
|
7
|
-
export { html } from '../../index-b6bfd165.js';
|
|
2
|
+
export { s as OrCode } from '../../OrCode.vue_vue_type_script_lang-8c5b4f6e.js';
|
|
3
|
+
export { b as basicSetup, a as lintGutter, l as linter } from '../../index-f92296d7.js';
|
|
4
|
+
export { javascript } from '../../index-22f7d3aa.js';
|
|
5
|
+
export { json, jsonParseLinter } from '../../index-19d70079.js';
|
|
6
|
+
export { html } from '../../index-84ea2fc8.js';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { html } from '../../index-
|
|
2
|
-
import { css } from '../../index-
|
|
3
|
-
import { json } from '../../index-
|
|
4
|
-
import { javascript } from '../../index-
|
|
5
|
-
import { markdown } from '../../index-
|
|
1
|
+
import { html } from '../../index-84ea2fc8.js';
|
|
2
|
+
import { css } from '../../index-792c62f6.js';
|
|
3
|
+
import { json } from '../../index-19d70079.js';
|
|
4
|
+
import { javascript } from '../../index-22f7d3aa.js';
|
|
5
|
+
import { markdown } from '../../index-b71d76f4.js';
|
|
6
6
|
import { OrCodeLanguages } from './constants.js';
|
|
7
7
|
|
|
8
8
|
const JS = javascript({
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
export { b as basicSetup } from '../../index-
|
|
2
|
-
export {
|
|
3
|
-
export {
|
|
4
|
-
export {
|
|
5
|
-
export { html } from '../../index-b6bfd165.js';
|
|
1
|
+
export { b as basicSetup, a as lintGutter, l as linter } from '../../index-f92296d7.js';
|
|
2
|
+
export { javascript } from '../../index-22f7d3aa.js';
|
|
3
|
+
export { json, jsonParseLinter } from '../../index-19d70079.js';
|
|
4
|
+
export { html } from '../../index-84ea2fc8.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { E as EditorView, aj as HighlightStyle, a4 as tags, Y as syntaxHighlighting } from '../../index-929b54f2.js';
|
|
2
2
|
|
|
3
3
|
// Using https://github.com/one-dark/vscode-one-dark-theme/ as reference for the colors
|
|
4
4
|
const chalky = 'var(--c-warning-darken-20)',
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { s as script } from '../../OrCode.vue_vue_type_script_lang-
|
|
2
|
-
export { s as default } from '../../OrCode.vue_vue_type_script_lang-
|
|
1
|
+
import { s as script } from '../../OrCode.vue_vue_type_script_lang-b46a0f8a.js';
|
|
2
|
+
export { s as default } from '../../OrCode.vue_vue_type_script_lang-b46a0f8a.js';
|
|
3
3
|
import { resolveComponent, openBlock, createElementBlock, normalizeClass, createBlock, withCtx, createElementVNode, renderSlot, createVNode, withModifiers, createTextVNode, toDisplayString, createCommentVNode, withDirectives, vShow } from 'vue';
|
|
4
4
|
|
|
5
5
|
const _hoisted_1 = {
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
export { CodeLanguage } from './props.js';
|
|
2
|
-
export { s as OrCodeV3 } from '../../OrCode.vue_vue_type_script_lang-
|
|
3
|
-
export {
|
|
4
|
-
export {
|
|
5
|
-
export { A as Annotation, a as AnnotationType, B as BidiSpan, t as BlockInfo, u as BlockType, C as ChangeDesc, b as ChangeSet, c as CharCategory, d as Compartment, D as Decoration, v as Direction, E as EditorSelection, e as EditorState, w as EditorView, F as Facet, G as GutterMarker, L as Line, M as MapMode, x as MatchDecorator, P as Prec, R as Range, f as RangeSet, g as RangeSetBuilder, h as RangeValue, y as RectangleMarker, S as SelectionRange, i as StateEffect, j as StateEffectType, k as StateField, T as Text, l as Transaction, V as ViewPlugin, z as ViewUpdate, W as WidgetType, _ as __test, H as closeHoverTooltips, m as codePointAt, n as codePointSize, o as combineConfig, p as countColumn, I as crosshairCursor, J as drawSelection, K as dropCursor, q as findClusterBreak, r as findColumn, s as fromCodePoint, N as getPanel, O as getTooltip, Q as gutter, U as gutterLineClass, X as gutters, Y as hasHoverTooltips, Z as highlightActiveLine, $ as highlightActiveLineGutter, a0 as highlightSpecialChars, a1 as highlightTrailingWhitespace, a2 as highlightWhitespace, a3 as hoverTooltip, a4 as keymap, a5 as layer, a6 as lineNumberMarkers, a7 as lineNumbers, a8 as logException, a9 as panels, aa as placeholder, ab as rectangularSelection, ac as repositionTooltips, ad as runScopeHandlers, ae as scrollPastEnd, af as showPanel, ag as showTooltip, ah as tooltips } from '../../index-e488383c.js';
|
|
2
|
+
export { s as OrCodeV3 } from '../../OrCode.vue_vue_type_script_lang-b46a0f8a.js';
|
|
3
|
+
export { json, jsonParseLinter } from '../../index-19d70079.js';
|
|
4
|
+
export { E as EditorView } from '../../index-929b54f2.js';
|
|
@@ -1,3 +1,2 @@
|
|
|
1
|
-
export {
|
|
2
|
-
export {
|
|
3
|
-
export { A as Annotation, a as AnnotationType, B as BidiSpan, t as BlockInfo, u as BlockType, C as ChangeDesc, b as ChangeSet, c as CharCategory, d as Compartment, D as Decoration, v as Direction, E as EditorSelection, e as EditorState, w as EditorView, F as Facet, G as GutterMarker, L as Line, M as MapMode, x as MatchDecorator, P as Prec, R as Range, f as RangeSet, g as RangeSetBuilder, h as RangeValue, y as RectangleMarker, S as SelectionRange, i as StateEffect, j as StateEffectType, k as StateField, T as Text, l as Transaction, V as ViewPlugin, z as ViewUpdate, W as WidgetType, _ as __test, H as closeHoverTooltips, m as codePointAt, n as codePointSize, o as combineConfig, p as countColumn, I as crosshairCursor, J as drawSelection, K as dropCursor, q as findClusterBreak, r as findColumn, s as fromCodePoint, N as getPanel, O as getTooltip, Q as gutter, U as gutterLineClass, X as gutters, Y as hasHoverTooltips, Z as highlightActiveLine, $ as highlightActiveLineGutter, a0 as highlightSpecialChars, a1 as highlightTrailingWhitespace, a2 as highlightWhitespace, a3 as hoverTooltip, a4 as keymap, a5 as layer, a6 as lineNumberMarkers, a7 as lineNumbers, a8 as logException, a9 as panels, aa as placeholder, ab as rectangularSelection, ac as repositionTooltips, ad as runScopeHandlers, ae as scrollPastEnd, af as showPanel, ag as showTooltip, ah as tooltips } from '../../index-e488383c.js';
|
|
1
|
+
export { json, jsonParseLinter } from '../../index-19d70079.js';
|
|
2
|
+
export { E as EditorView } from '../../index-929b54f2.js';
|
|
@@ -23,16 +23,15 @@ export { s as OrCheckboxTreeV3 } from '../OrCheckboxTree.vue_vue_type_script_lan
|
|
|
23
23
|
export { s as OrCheckboxV3 } from '../OrCheckbox.vue_vue_type_script_lang-4fa909d8.js';
|
|
24
24
|
export { s as OrChip } from '../OrChip.vue_vue_type_script_lang-8ccf3d2d.js';
|
|
25
25
|
export { s as OrChips } from '../OrChips.vue_vue_type_script_lang-70be98b5.js';
|
|
26
|
-
export { s as OrCode } from '../OrCode.vue_vue_type_script_lang-
|
|
26
|
+
export { s as OrCode } from '../OrCode.vue_vue_type_script_lang-8c5b4f6e.js';
|
|
27
27
|
export { OrCodeLanguages } from './OrCode/constants.js';
|
|
28
|
-
export { b as basicSetup } from '../index-
|
|
29
|
-
export {
|
|
30
|
-
export {
|
|
31
|
-
export {
|
|
32
|
-
export {
|
|
33
|
-
export { s as OrCodeV3 } from '../OrCode.vue_vue_type_script_lang-29120928.js';
|
|
28
|
+
export { b as basicSetup, a as lintGutter, l as linter } from '../index-f92296d7.js';
|
|
29
|
+
export { javascript } from '../index-22f7d3aa.js';
|
|
30
|
+
export { json, jsonParseLinter } from '../index-19d70079.js';
|
|
31
|
+
export { html } from '../index-84ea2fc8.js';
|
|
32
|
+
export { s as OrCodeV3 } from '../OrCode.vue_vue_type_script_lang-b46a0f8a.js';
|
|
34
33
|
export { CodeLanguage } from './OrCodeV3/props.js';
|
|
35
|
-
export {
|
|
34
|
+
export { E as EditorView } from '../index-929b54f2.js';
|
|
36
35
|
export { s as OrCollapse } from '../OrCollapse.vue_vue_type_script_lang-69503c45.js';
|
|
37
36
|
export { s as OrColorPicker } from '../OrColorPicker.vue_vue_type_script_lang-7b6d1e64.js';
|
|
38
37
|
export { amber, black, blue, blueGrey, brown, cyan, deepOrange, deepPurple, green, indigo, lightBlue, lightGreen, lime, orange, pink, purple, red, teal, white, yellow } from './OrColorPicker/constants.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { L as LRParser } from './index-
|
|
2
|
-
import {
|
|
1
|
+
import { L as LRParser } from './index-df2529d7.js';
|
|
2
|
+
import { a3 as styleTags, a4 as tags, a5 as LanguageSupport, a6 as LRLanguage, a7 as indentNodeProp, a8 as continuedIndent, ab as foldNodeProp, ac as foldInside } from './index-929b54f2.js';
|
|
3
3
|
|
|
4
4
|
const jsonHighlighting = styleTags({
|
|
5
5
|
String: tags.string,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { C as ContextTracker, E as ExternalTokenizer, L as LRParser, a as LocalTokenGroup } from './index-
|
|
2
|
-
import {
|
|
3
|
-
import { i as ifNotIn, e as completeFromList, s as snippetCompletion } from './index-
|
|
1
|
+
import { C as ContextTracker, E as ExternalTokenizer, L as LRParser, a as LocalTokenGroup } from './index-df2529d7.js';
|
|
2
|
+
import { a3 as styleTags, a4 as tags, a5 as LanguageSupport, E as EditorView, s as syntaxTree, b as EditorSelection, a6 as LRLanguage, a7 as indentNodeProp, a8 as continuedIndent, a9 as flatIndent, aa as delimitedIndent, ab as foldNodeProp, ac as foldInside, ad as sublanguageProp, ae as IterMode, af as defineLanguageFacet, ag as NodeWeakMap } from './index-929b54f2.js';
|
|
3
|
+
import { i as ifNotIn, e as completeFromList, s as snippetCompletion } from './index-bb6d92dd.js';
|
|
4
4
|
|
|
5
5
|
// This file was generated by lezer-generator. You probably shouldn't edit it.
|
|
6
6
|
const noSemi = 302,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { E as ExternalTokenizer, L as LRParser } from './index-
|
|
2
|
-
import {
|
|
1
|
+
import { E as ExternalTokenizer, L as LRParser } from './index-df2529d7.js';
|
|
2
|
+
import { a3 as styleTags, a4 as tags$1, a5 as LanguageSupport, s as syntaxTree, a6 as LRLanguage, a7 as indentNodeProp, a8 as continuedIndent, ab as foldNodeProp, ac as foldInside, ae as IterMode, ag as NodeWeakMap } from './index-929b54f2.js';
|
|
3
3
|
|
|
4
4
|
// This file was generated by lezer-generator. You probably shouldn't edit it.
|
|
5
5
|
const descendantOp = 95,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { C as ContextTracker, E as ExternalTokenizer, L as LRParser } from './index-
|
|
2
|
-
import {
|
|
3
|
-
import { cssLanguage, css } from './index-
|
|
4
|
-
import { typescriptLanguage, jsxLanguage, tsxLanguage, javascriptLanguage, javascript } from './index-
|
|
1
|
+
import { C as ContextTracker, E as ExternalTokenizer, L as LRParser } from './index-df2529d7.js';
|
|
2
|
+
import { a3 as styleTags, a4 as tags, ah as parseMixed, a5 as LanguageSupport, E as EditorView, s as syntaxTree, b as EditorSelection, a6 as LRLanguage, a7 as indentNodeProp, ab as foldNodeProp, ai as bracketMatchingHandle } from './index-929b54f2.js';
|
|
3
|
+
import { cssLanguage, css } from './index-792c62f6.js';
|
|
4
|
+
import { typescriptLanguage, jsxLanguage, tsxLanguage, javascriptLanguage, javascript } from './index-22f7d3aa.js';
|
|
5
5
|
|
|
6
6
|
// This file was generated by lezer-generator. You probably shouldn't edit it.
|
|
7
7
|
const scriptText = 54,
|