@arcgis/coding-components 5.0.0-next.94 → 5.0.0-next.96
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/addons.js +26 -25
- package/dist/cdn/23PDSGPR.js +14 -0
- package/dist/cdn/{W3I4P6B2.js → 2IHT4EHN.js} +1 -1
- package/dist/cdn/{B5GJ3P5G.js → 2MJ3LNJG.js} +2 -2
- package/dist/cdn/3EIGQ66V.js +6 -0
- package/dist/cdn/{C7S7FIMX.js → 3TJXZ4VM.js} +2 -2
- package/dist/cdn/{A5WEEHGM.js → 4XOVY2PR.js} +2 -2
- package/dist/cdn/{KLR2TH2U.js → 74HYZGLA.js} +2 -2
- package/dist/cdn/{UYCZT4PR.js → 7MZAZXK6.js} +2 -2
- package/dist/cdn/{24A2GMXS.js → ALOCWFFI.js} +2 -2
- package/dist/cdn/{R5L3UDPZ.js → ATN3CPT7.js} +2 -2
- package/dist/cdn/{UYYBSWI5.js → CFWTHL36.js} +2 -2
- package/dist/cdn/{NCWCEJ4H.js → CL75QVV7.js} +1 -1
- package/dist/cdn/CZVOOL7Z.js +4 -0
- package/dist/cdn/{FL7A5ZFN.js → DHGFCLAZ.js} +2 -2
- package/dist/cdn/{YAFEASDQ.js → E2DG62ZU.js} +3 -3
- package/dist/cdn/{RDOPAVSY.js → EGHYNAYE.js} +1 -1
- package/dist/cdn/{WZBQ3LI4.js → FKCQQTH6.js} +2 -2
- package/dist/cdn/{IOYAZ7XQ.js → H7K3SILV.js} +2 -2
- package/dist/cdn/{6HA5DFLF.js → HQT5JM76.js} +1 -1
- package/dist/cdn/{JSQ46V4B.js → JHGOFJEK.js} +2 -2
- package/dist/cdn/{YGMFTUQQ.js → JP6SZ4AZ.js} +1 -1
- package/dist/cdn/K7DUQYV7.js +4 -0
- package/dist/cdn/{KMR6BDYB.js → KJ5IPWOF.js} +2 -2
- package/dist/cdn/KNRXKMFC.js +4 -0
- package/dist/cdn/KPDZ6444.js +4 -0
- package/dist/cdn/{TTNKFUSY.js → LKJPHOMR.js} +2 -2
- package/dist/cdn/LTDEFINS.js +4 -0
- package/dist/cdn/{45RYMSYG.js → MY2WCV66.js} +2 -2
- package/dist/cdn/{CL5UX33P.js → MYCHXXED.js} +2 -2
- package/dist/cdn/{2YVIARN5.js → N4YKPCZU.js} +2 -2
- package/dist/cdn/P5LNJNN6.js +4 -0
- package/dist/cdn/{V6ZXLVEU.js → PWKEJCJP.js} +2 -2
- package/dist/cdn/QLFIDEKK.js +6 -0
- package/dist/cdn/QSIYBJ46.js +4 -0
- package/dist/cdn/{FQGB2RRB.js → RRLS2TOQ.js} +2 -2
- package/dist/cdn/TBXTOKU6.js +4 -0
- package/dist/cdn/{5WHTEHPM.js → TWGO77FS.js} +2 -2
- package/dist/cdn/{CBWWEN4S.js → TZB4YFKZ.js} +1 -1
- package/dist/cdn/UGKWIQHT.js +4 -0
- package/dist/cdn/{Z3ZSRJMV.js → VD3QVBSU.js} +2 -2
- package/dist/cdn/{UHQMWHSA.js → VOUYQ4DG.js} +1 -1
- package/dist/cdn/{JUKZO7ZY.js → WOSGVDYX.js} +2 -2
- package/dist/cdn/{IKQMRUER.js → WQXADMUM.js} +2 -2
- package/dist/cdn/WVCBT3G6.js +4 -0
- package/dist/cdn/{H2A4L7G6.js → WXP3C3JC.js} +2 -2
- package/dist/cdn/{SNLDOFIP.js → XCK3XVPS.js} +2 -2
- package/dist/cdn/{NVZTZU3Q.js → XYPRW4OO.js} +2 -2
- package/dist/cdn/{E5NOGZC7.js → ZI2PMS6G.js} +2 -2
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.ar.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.bg.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.bs.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.ca.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.cs.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.da.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.de.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.el.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.es.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.et.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.fi.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.fr.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.he.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.hr.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.hu.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.id.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.it.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.ja.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.ko.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.lt.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.lv.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.nl.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.no.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.pl.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.pt-BR.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.pt-PT.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.ro.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.ru.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.sk.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.sl.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.sr.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.sv.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.th.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.tr.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.uk.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.vi.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.zh-CN.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.zh-HK.json +1 -1
- package/dist/cdn/assets/arcade-coding-assistant/t9n/messages.zh-TW.json +1 -1
- package/dist/cdn/assets/code-editor/sql-expr.worker.js +760 -758
- package/dist/cdn/index.js +2 -2
- package/dist/chunks/arcade-contribution.js +1 -1
- package/dist/chunks/arcade-defaults.js +1 -1
- package/dist/chunks/arcade-executor.js +1 -1
- package/dist/chunks/arcade-mode.js +55 -54
- package/dist/chunks/arcade-service-accessors.js +1 -1
- package/dist/chunks/colorize.js +1 -1
- package/dist/chunks/editor.js +1 -1
- package/dist/chunks/fields.js +1 -1
- package/dist/chunks/language-defaults-base.js +203 -202
- package/dist/chunks/markdown.js +1 -1
- package/dist/chunks/monaco-importer.js +1 -1
- package/dist/chunks/monaco-theme.js +1 -1
- package/dist/chunks/runtime.js +1 -1
- package/dist/chunks/sql-expr-defaults.js +1 -1
- package/dist/chunks/sql-expr-mode.js +67 -66
- package/dist/chunks/sql-expr-service-accessors.js +1 -1
- package/dist/chunks/useT9n.js +1 -1
- package/dist/chunks/utilities.js +1 -1
- package/dist/components/arcgis-arcade-coding-assistant/customElement.js +5 -5
- package/dist/components/arcgis-arcade-editor/customElement.js +67 -65
- package/dist/components/arcgis-arcade-results/customElement.js +1 -1
- package/dist/components/arcgis-arcade-suggestions/customElement.js +1 -1
- package/dist/components/arcgis-code-editor/customElement.js +1 -1
- package/dist/components/arcgis-code-viewer/customElement.js +15 -14
- package/dist/components/arcgis-editor-variables/customElement.js +10 -9
- package/dist/components/arcgis-language-api-panel/customElement.js +1 -1
- package/dist/components/arcgis-sql-expression-editor/customElement.js +22 -21
- package/dist/components/arcgis-sql-expression-fields/customElement.js +1 -1
- package/dist/docs/api.json +2 -2
- package/dist/docs/docs.json +2 -2
- package/dist/docs/web-types.json +1 -1
- package/dist/index.js +1 -1
- package/dist/loader.js +1 -1
- package/dist/monacoStyles.js +1 -1
- package/package.json +5 -5
- package/dist/cdn/3OHWJOMD.js +0 -4
- package/dist/cdn/6ROKBSGI.js +0 -4
- package/dist/cdn/75OSZZJF.js +0 -4
- package/dist/cdn/A6DSFADQ.js +0 -4
- package/dist/cdn/APXINRPI.js +0 -4
- package/dist/cdn/BQJBSDM2.js +0 -4
- package/dist/cdn/BQNN5XLA.js +0 -6
- package/dist/cdn/CUL2JAK4.js +0 -14
- package/dist/cdn/FNP2QIRS.js +0 -4
- package/dist/cdn/GNLRKAD5.js +0 -6
- package/dist/cdn/M5VQUFXO.js +0 -4
- package/dist/cdn/X2UROQYS.js +0 -4
- package/dist/cdn/XQ7S4CXK.js +0 -4
package/dist/cdn/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
2
2
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
3
|
-
v5.0.0-next.
|
|
4
|
-
import{J as s,v as e}from"./
|
|
3
|
+
v5.0.0-next.96 */
|
|
4
|
+
import{J as s,v as e}from"./QLFIDEKK.js";import"./WVCBT3G6.js";import"./2IHT4EHN.js";var t=e(s,{"arcgis-arcade-coding-assistant":[()=>import("./3EIGQ66V.js"),"appVersion,assistantsEnabled,closed,closePanel:,editorRef:,feedbackServiceUrl,helpBase,insertText:,layer,portalUrl,serviceUrl;destroy"],"arcgis-arcade-editor":[()=>import("./K7DUQYV7.js"),"arcadeAssistant:,customPanels:,editorInstance:,editorOptions:,hideDocumentationActions,hideSideBar,openedSidePanel:,profile:,script,sideActionBarExpanded,snippets:,suggestions:,testData:;getEditorInstance,getScript,getTestResult,setFocus"],"arcgis-arcade-results":[()=>import("./H7K3SILV.js"),"calciteModeDark,consoleLogs:,loading,openedResultPanel,result:"],"arcgis-arcade-suggestions":[()=>import("./TWGO77FS.js"),"closed,suggestions:"],"arcgis-code-editor":[()=>import("./MYCHXXED.js"),"editorInstance:,editorOptions:,language,modelId:,value;getEditorInstance,getValue,insertSnippet,insertText,setFocus,setValue"],"arcgis-code-viewer":[()=>import("./CZVOOL7Z.js"),"language,round"],"arcgis-editor-variables":[()=>import("./UGKWIQHT.js"),"closed,loading,modelId,variable:"],"arcgis-language-api-panel":[()=>import("./FKCQQTH6.js"),"apiLibrary:,closed,hideDocumentationActions,languageId,loading"],"arcgis-sql-expression-editor":[()=>import("./KPDZ6444.js"),"hideSideBar,profile:,script;setFocus"],"arcgis-sql-expression-fields":[()=>import("./74HYZGLA.js"),"loading,modelId"]});t({resourcesUrl:import.meta.url});var i=new CSSStyleSheet();var ___=new CSSStyleSheet();___.replaceSync(`@layer{/*!-----------------------------------------------------------
|
|
5
5
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
6
6
|
* Version: 0.52.2(404545bded1df6ffa41ea0af4e8ddb219018c6c1)
|
|
7
7
|
* Released under the MIT license
|
|
@@ -11,7 +11,7 @@ import { b as n } from "./arcade-defaults.js";
|
|
|
11
11
|
import { g as h } from "./arcade-service-accessors.js";
|
|
12
12
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
13
13
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
14
|
-
v5.0.0-next.
|
|
14
|
+
v5.0.0-next.96 */
|
|
15
15
|
const k = ["arcade", "arcgis-sql-expression"], i = /* @__PURE__ */ new Set(), g = /* @__PURE__ */ new Map();
|
|
16
16
|
function c(e) {
|
|
17
17
|
let r = g.get(e);
|
|
@@ -5,7 +5,7 @@ import { CompletionItemKind as w, InsertTextFormat as u, InsertTextMode as p } f
|
|
|
5
5
|
import { getDeclaredPixelMembers as I } from "@arcgis/core/applications/Components/arcadeEditorUtils.js";
|
|
6
6
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
7
7
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
8
|
-
v5.0.0-next.
|
|
8
|
+
v5.0.0-next.96 */
|
|
9
9
|
async function C(e) {
|
|
10
10
|
const { apiVersion: r, bundles: t, hiddenApiItems: i } = e.toEditorProfileDefinition(), n = await h(e.dictionaryVariables);
|
|
11
11
|
return { apiVersion: r, bundles: t, variables: n, hiddenApiItems: i?.map((s) => s.toLowerCase()) };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { createArcadeExecutor as C } from "@arcgis/core/arcade.js";
|
|
2
2
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
|
-
v5.0.0-next.
|
|
4
|
+
v5.0.0-next.96 */
|
|
5
5
|
const O = "https://developers.arcgis.com/arcade/", P = 100, A = 100;
|
|
6
6
|
function g(t) {
|
|
7
7
|
return !!t && typeof t == "object" && "declaredRootClass" in t && typeof t.declaredRootClass == "string" && t.declaredRootClass === "esri.arcade.featureset.support.FeatureSet";
|
|
@@ -1,16 +1,17 @@
|
|
|
1
|
-
import { Range as
|
|
1
|
+
import { Range as _, languages as l, MarkerSeverity as p, Emitter as M } from "monaco-editor";
|
|
2
2
|
import "monaco-editor/esm/vs/editor/standalone/browser/standaloneServices.js";
|
|
3
3
|
import "monaco-editor/esm/vs/editor/standalone/common/standaloneTheme.js";
|
|
4
4
|
import "monaco-editor/esm/vs/platform/hover/browser/hover.js";
|
|
5
5
|
import "monaco-editor/esm/vs/editor/common/languages/supports/tokenization.js";
|
|
6
|
-
import { ArcadeKeywords as
|
|
7
|
-
import { i as
|
|
8
|
-
import { InsertTextFormat as
|
|
6
|
+
import { ArcadeKeywords as y } from "@arcgis/arcade-languageservice";
|
|
7
|
+
import { i as w } from "./monaco-importer.js";
|
|
8
|
+
import { InsertTextFormat as A, CompletionItemKind as o, DiagnosticSeverity as m } from "vscode-languageserver-types";
|
|
9
9
|
import { debounce as F } from "@arcgis/toolkit/function";
|
|
10
|
-
import {
|
|
10
|
+
import { rethrowError as f } from "@arcgis/toolkit/log";
|
|
11
|
+
import { Deferred as b } from "@arcgis/toolkit/promise";
|
|
11
12
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
12
13
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
13
|
-
v5.0.0-next.
|
|
14
|
+
v5.0.0-next.96 */
|
|
14
15
|
const S = [
|
|
15
16
|
"<=",
|
|
16
17
|
">=",
|
|
@@ -73,7 +74,7 @@ const S = [
|
|
|
73
74
|
// ^.*\{[^}"']*$
|
|
74
75
|
increaseIndentPattern: /^((?!\/\/).)*(\{[^}"'`]*|\([^)"'`]*|\[[^\]"'`]*)$/u
|
|
75
76
|
}
|
|
76
|
-
},
|
|
77
|
+
}, P = {
|
|
77
78
|
// Set defaultToken to invalid to see what you do not tokenize yet
|
|
78
79
|
defaultToken: "invalid",
|
|
79
80
|
tokenPostfix: ".arcgis",
|
|
@@ -82,7 +83,7 @@ const S = [
|
|
|
82
83
|
// builtinFunctions: [...arcadeService.FunctionNames],
|
|
83
84
|
// Arcade keywords. 'from' is a special case as we want to treat it as a keyword in
|
|
84
85
|
// import statement but as an identifier in var statement.
|
|
85
|
-
keywords:
|
|
86
|
+
keywords: y,
|
|
86
87
|
operators: S,
|
|
87
88
|
constants: ["true", "false", "null"],
|
|
88
89
|
// we include these common regular expressions
|
|
@@ -252,22 +253,22 @@ const S = [
|
|
|
252
253
|
]
|
|
253
254
|
}
|
|
254
255
|
};
|
|
255
|
-
class
|
|
256
|
+
class D {
|
|
256
257
|
constructor(e, n, {
|
|
257
258
|
defaults: c,
|
|
258
259
|
diagnosticsService: g
|
|
259
260
|
}) {
|
|
260
|
-
this._languageId = e, this._worker = n, this._disposables = [], this._modelListeners = /* @__PURE__ */ new Map(), this._diagnosticsService = g, this._defaults = c,
|
|
261
|
+
this._languageId = e, this._worker = n, this._disposables = [], this._modelListeners = /* @__PURE__ */ new Map(), this._diagnosticsService = g, this._defaults = c, w().then((s) => {
|
|
261
262
|
const u = (i) => {
|
|
262
263
|
const r = i.getLanguageId();
|
|
263
264
|
if (r !== this._languageId)
|
|
264
265
|
return;
|
|
265
266
|
const a = F(() => {
|
|
266
|
-
this._doValidate(i, r).catch((
|
|
267
|
-
throw
|
|
267
|
+
this._doValidate(i, r).catch((L) => {
|
|
268
|
+
throw L;
|
|
268
269
|
});
|
|
269
|
-
}),
|
|
270
|
-
this._modelListeners.set(i.uri.toString(), [
|
|
270
|
+
}), v = i.onDidChangeContent(a), E = i.onDidChangeAttached(a);
|
|
271
|
+
this._modelListeners.set(i.uri.toString(), [v, E]), this._doValidate(i, r).catch(f("DiagnosticsAdapter"));
|
|
271
272
|
}, d = (i) => {
|
|
272
273
|
const r = i.uri.toString();
|
|
273
274
|
s.setModelMarkers(i, this._languageId, []);
|
|
@@ -295,7 +296,7 @@ class P {
|
|
|
295
296
|
), this._disposables.push(
|
|
296
297
|
c.onModelContextDidChange((i) => {
|
|
297
298
|
s.getModels().forEach((r) => {
|
|
298
|
-
r.getLanguageId() === this._languageId && r.uri.toString() === i && this._doValidate(r, this._languageId).catch(
|
|
299
|
+
r.getLanguageId() === this._languageId && r.uri.toString() === i && this._doValidate(r, this._languageId).catch(f("DiagnosticsAdapter"));
|
|
299
300
|
});
|
|
300
301
|
})
|
|
301
302
|
), this._disposables.push({
|
|
@@ -311,10 +312,10 @@ class P {
|
|
|
311
312
|
async _doValidate(e, n) {
|
|
312
313
|
if (e.isAttachedToEditor())
|
|
313
314
|
try {
|
|
314
|
-
const c = await
|
|
315
|
+
const c = await w(), g = await this._worker(e.uri), s = this._defaults.getApiContextForModel(e.uri), u = await g.doValidation(e.uri.toString(), s), d = u.map((i) => $(e.uri, i));
|
|
315
316
|
this._diagnosticsService.fireDiagnosticsChange(e.uri, u), c.setModelMarkers(e, n, d);
|
|
316
317
|
} catch (c) {
|
|
317
|
-
|
|
318
|
+
f("DiagnosticsAdapter")(c);
|
|
318
319
|
}
|
|
319
320
|
}
|
|
320
321
|
}
|
|
@@ -342,22 +343,22 @@ function $(t, e) {
|
|
|
342
343
|
message: e.message
|
|
343
344
|
};
|
|
344
345
|
}
|
|
345
|
-
function
|
|
346
|
+
function V(t) {
|
|
346
347
|
return { character: t.column - 1, line: t.lineNumber - 1 };
|
|
347
348
|
}
|
|
348
349
|
function h(t) {
|
|
349
|
-
return new
|
|
350
|
+
return new _(t.start.line + 1, t.start.character + 1, t.end.line + 1, t.end.character + 1);
|
|
350
351
|
}
|
|
351
|
-
function
|
|
352
|
+
function R(t) {
|
|
352
353
|
return {
|
|
353
354
|
range: h(t.range),
|
|
354
355
|
text: t.newText
|
|
355
356
|
};
|
|
356
357
|
}
|
|
357
|
-
function
|
|
358
|
+
function K(t) {
|
|
358
359
|
return typeof t.insert < "u" && typeof t.replace < "u";
|
|
359
360
|
}
|
|
360
|
-
function
|
|
361
|
+
function N(t) {
|
|
361
362
|
const e = l.CompletionItemKind;
|
|
362
363
|
switch (t) {
|
|
363
364
|
case o.Text:
|
|
@@ -414,12 +415,12 @@ function K(t) {
|
|
|
414
415
|
return e.Property;
|
|
415
416
|
}
|
|
416
417
|
}
|
|
417
|
-
class
|
|
418
|
+
class z {
|
|
418
419
|
constructor(e, n) {
|
|
419
420
|
this._worker = e, this._defaults = n, this.triggerCharacters = [".", "("];
|
|
420
421
|
}
|
|
421
422
|
async provideCompletionItems(e, n) {
|
|
422
|
-
const c = await this._worker(e.uri), g = this._defaults.getApiContextForModel(e.uri), s = await c.doComplete(e.uri.toString(),
|
|
423
|
+
const c = await this._worker(e.uri), g = this._defaults.getApiContextForModel(e.uri), s = await c.doComplete(e.uri.toString(), V(n), g), u = e.getWordUntilPosition(n), d = new _(n.lineNumber, u.startColumn, n.lineNumber, u.endColumn), i = s.items.map((r) => {
|
|
423
424
|
const a = {
|
|
424
425
|
label: r.label,
|
|
425
426
|
insertText: r.insertText || r.label,
|
|
@@ -427,12 +428,12 @@ class N {
|
|
|
427
428
|
filterText: r.filterText,
|
|
428
429
|
detail: r.detail,
|
|
429
430
|
range: d,
|
|
430
|
-
kind:
|
|
431
|
+
kind: N(r.kind)
|
|
431
432
|
};
|
|
432
|
-
return r.textEdit && (
|
|
433
|
+
return r.textEdit && (K(r.textEdit) ? a.range = {
|
|
433
434
|
insert: h(r.textEdit.insert),
|
|
434
435
|
replace: h(r.textEdit.replace)
|
|
435
|
-
} : a.range = h(r.textEdit.range), a.insertText = r.textEdit.newText), r.additionalTextEdits && (a.additionalTextEdits = r.additionalTextEdits.map(
|
|
436
|
+
} : a.range = h(r.textEdit.range), a.insertText = r.textEdit.newText), r.additionalTextEdits && (a.additionalTextEdits = r.additionalTextEdits.map(R)), r.insertTextFormat === A.Snippet && (a.insertTextRules = l.CompletionItemInsertTextRule.InsertAsSnippet), r.documentation && (typeof r.documentation == "string" ? a.documentation = r.documentation : a.documentation = {
|
|
436
437
|
supportThemeIcons: !1,
|
|
437
438
|
value: r.documentation.value,
|
|
438
439
|
supportHtml: !0
|
|
@@ -444,7 +445,7 @@ class N {
|
|
|
444
445
|
};
|
|
445
446
|
}
|
|
446
447
|
}
|
|
447
|
-
class
|
|
448
|
+
class O {
|
|
448
449
|
constructor(e, n) {
|
|
449
450
|
this._worker = e, this._defaults = n;
|
|
450
451
|
}
|
|
@@ -453,8 +454,8 @@ class z {
|
|
|
453
454
|
return (await n.doFormat(e.uri.toString(), c)).map((s) => ({ range: h(s.range), text: s.newText }));
|
|
454
455
|
}
|
|
455
456
|
}
|
|
456
|
-
let
|
|
457
|
-
class
|
|
457
|
+
let k = new b();
|
|
458
|
+
class C {
|
|
458
459
|
constructor(e) {
|
|
459
460
|
this._defaults = e, this._worker = null, this._client = null, this._configChangeListener = this._defaults.onDidChange(() => this.stopWorker());
|
|
460
461
|
}
|
|
@@ -462,17 +463,17 @@ class b {
|
|
|
462
463
|
this._configChangeListener.dispose(), this.stopWorker();
|
|
463
464
|
}
|
|
464
465
|
stopWorker() {
|
|
465
|
-
this._worker && (this._worker.dispose(), this._worker = null,
|
|
466
|
+
this._worker && (this._worker.dispose(), this._worker = null, k = new b()), this._client = null;
|
|
466
467
|
}
|
|
467
468
|
/**
|
|
468
469
|
* Wait for the worker to be ready.
|
|
469
470
|
* @returns A promise that resolves when the worker is ready.
|
|
470
471
|
*/
|
|
471
472
|
static async waitForWorker() {
|
|
472
|
-
return await
|
|
473
|
+
return await k.promise;
|
|
473
474
|
}
|
|
474
475
|
async _getClientProxy() {
|
|
475
|
-
const e = await
|
|
476
|
+
const e = await w();
|
|
476
477
|
if (!this._client) {
|
|
477
478
|
const { languageId: n } = this._defaults;
|
|
478
479
|
this._worker = e.createWebWorker({
|
|
@@ -480,7 +481,7 @@ class b {
|
|
|
480
481
|
label: n,
|
|
481
482
|
createData: { languageId: n },
|
|
482
483
|
host: this._defaults.workerHost
|
|
483
|
-
}),
|
|
484
|
+
}), k.resolve(this._worker), this._client = this._worker.getProxy();
|
|
484
485
|
}
|
|
485
486
|
return await this._client;
|
|
486
487
|
}
|
|
@@ -489,19 +490,19 @@ class b {
|
|
|
489
490
|
return await this._worker?.withSyncedResources(e), n;
|
|
490
491
|
}
|
|
491
492
|
}
|
|
492
|
-
let
|
|
493
|
-
async function
|
|
494
|
-
return await
|
|
495
|
-
if (!
|
|
493
|
+
let x;
|
|
494
|
+
async function te(...t) {
|
|
495
|
+
return await C.waitForWorker(), await new Promise((e, n) => {
|
|
496
|
+
if (!x) {
|
|
496
497
|
n(new Error("Arcade not registered!"));
|
|
497
498
|
return;
|
|
498
499
|
}
|
|
499
|
-
e(
|
|
500
|
+
e(x(...t));
|
|
500
501
|
});
|
|
501
502
|
}
|
|
502
|
-
class
|
|
503
|
+
class H {
|
|
503
504
|
constructor() {
|
|
504
|
-
this._onDiagnosticsChange = new
|
|
505
|
+
this._onDiagnosticsChange = new M();
|
|
505
506
|
}
|
|
506
507
|
/**
|
|
507
508
|
* An event to signal changes to the diagnostics.
|
|
@@ -519,25 +520,25 @@ class O {
|
|
|
519
520
|
this._onDiagnosticsChange.fire({ uri: e, diagnostics: n });
|
|
520
521
|
}
|
|
521
522
|
}
|
|
522
|
-
const
|
|
523
|
-
function
|
|
524
|
-
return
|
|
523
|
+
const I = new H();
|
|
524
|
+
function re() {
|
|
525
|
+
return I;
|
|
525
526
|
}
|
|
526
|
-
function
|
|
527
|
-
const e = new
|
|
528
|
-
|
|
527
|
+
function ne(t) {
|
|
528
|
+
const e = new C(t), n = async (...c) => await e.getLanguageServiceWorker(...c);
|
|
529
|
+
x = n, l.setMonarchTokensProvider(t.languageId, P), l.setLanguageConfiguration(t.languageId, T), l.registerCompletionItemProvider(
|
|
529
530
|
t.languageId,
|
|
530
|
-
new
|
|
531
|
+
new z(n, t)
|
|
531
532
|
), l.registerDocumentFormattingEditProvider(
|
|
532
533
|
t.languageId,
|
|
533
|
-
new
|
|
534
|
-
), new
|
|
534
|
+
new O(n, t)
|
|
535
|
+
), new D(t.languageId, n, {
|
|
535
536
|
defaults: t,
|
|
536
|
-
diagnosticsService:
|
|
537
|
+
diagnosticsService: I
|
|
537
538
|
});
|
|
538
539
|
}
|
|
539
540
|
export {
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
541
|
+
re as getArcadeDiagnosticService,
|
|
542
|
+
te as getArcadeWorker,
|
|
543
|
+
ne as setupMode
|
|
543
544
|
};
|
|
@@ -6,7 +6,7 @@ import { IHoverService as m } from "monaco-editor/esm/vs/platform/hover/browser/
|
|
|
6
6
|
import "monaco-editor/esm/vs/editor/common/languages/supports/tokenization.js";
|
|
7
7
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
8
8
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
9
|
-
v5.0.0-next.
|
|
9
|
+
v5.0.0-next.96 */
|
|
10
10
|
function g() {
|
|
11
11
|
return !!window.MonacoEnvironment?.getWorker;
|
|
12
12
|
}
|
package/dist/chunks/colorize.js
CHANGED
|
@@ -4,7 +4,7 @@ import { IStandaloneThemeService as n } from "monaco-editor/esm/vs/editor/standa
|
|
|
4
4
|
import { generateTokensCSSForColorMap as a } from "monaco-editor/esm/vs/editor/common/languages/supports/tokenization.js";
|
|
5
5
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
6
6
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
7
|
-
v5.0.0-next.
|
|
7
|
+
v5.0.0-next.96 */
|
|
8
8
|
async function c(e, o) {
|
|
9
9
|
return await (await i()).colorize(e, o, { tabSize: 2 });
|
|
10
10
|
}
|
package/dist/chunks/editor.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { css as o } from "lit";
|
|
2
2
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
|
-
v5.0.0-next.
|
|
4
|
+
v5.0.0-next.96 */
|
|
5
5
|
const i = o`@layer{arcgis-arcade-editor,arcgis-sql-expression-editor{--arcgis-coding-components-border: 1px solid var(--calcite-color-border-3);--arcgis-coding-components-background-color: var(--calcite-color-foreground-1);--arcgis-coding-components-side-action-bar-max-w: 25%;--arcgis-coding-components-code-editor-side-panel-w: 600px;--arcgis-coding-components-code-editor-side-panel-max-w: 45%;.flex-adjustable{flex:1 1 auto;overflow:hidden}.flex-panel{flex:1 0 auto}.position-relative{position:relative}.flex-row{display:flex;flex-direction:row;overflow:hidden}.flex-column{display:flex;flex-direction:column;overflow:hidden}.border-inline-start{border-inline-start:var(--arcgis-coding-components-border)!important;box-sizing:border-box}.border-inline-end{border-inline-end:var(--arcgis-coding-components-border)!important;box-sizing:border-box}.side-action-bar{max-width:var(--arcgis-coding-components-side-action-bar-max-w)}.code-editor-side-panel{max-width:var(--arcgis-coding-components-code-editor-side-panel-max-w);width:var(--arcgis-coding-components-code-editor-side-panel-w)}.code-editor-side-panel calcite-flow{height:100%}}}`;
|
|
6
6
|
export {
|
|
7
7
|
i as s
|
package/dist/chunks/fields.js
CHANGED