@arcgis/coding-components 4.34.0-next.3 → 4.34.0-next.30
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/arcade-coding-assistant/chat-helper.d.ts +25 -7
- package/dist/addons/arcade-coding-assistant/temporary-strings.d.ts +47 -0
- package/dist/addons/arcade-coding-assistant/useArcadeAssistant.d.ts +15 -7
- package/dist/addons.js +32 -23
- package/dist/cdn/{TUHPJEG5.js → 243HZ7UI.js} +2 -2
- package/dist/cdn/{J3HINC5N.js → 275GUA3M.js} +2 -2
- package/dist/cdn/{HAL3EXK4.js → 3J5TNLID.js} +2 -2
- package/dist/cdn/{Q4NJDLN3.js → 4DTIYTO6.js} +2 -2
- package/dist/cdn/{XNMOJ2SC.js → 4YQMMXJW.js} +2 -2
- package/dist/cdn/{D2Q4JNSY.js → 63FQPWTO.js} +2 -2
- package/dist/cdn/{CCQCZKCC.js → 6FY2AO4H.js} +2 -2
- package/dist/cdn/{Z3HBU3YI.js → 6TAOJNTW.js} +2 -2
- package/dist/cdn/73X3KSHQ.js +4 -0
- package/dist/cdn/{E4PTTXH5.js → 7ZZRCI6T.js} +2 -2
- package/dist/cdn/{FKQ7SSE6.js → ACFFT2B3.js} +2 -2
- package/dist/cdn/AQUP2HXZ.js +4 -0
- package/dist/cdn/AUUFEK2C.js +4 -0
- package/dist/cdn/{D4OPUHHF.js → C6IJOPEB.js} +2 -2
- package/dist/cdn/{ZBGL3SYO.js → CG3PBJU2.js} +1 -1
- package/dist/cdn/{RKCAAVN6.js → CSS7NGXW.js} +2 -2
- package/dist/cdn/{PULCYE7H.js → D3YK5GGC.js} +2 -2
- package/dist/cdn/{RFV2R57W.js → DQ3CWBLF.js} +2 -2
- package/dist/cdn/DU4OWFNM.js +6 -0
- package/dist/cdn/{YHNSFDD7.js → DU5TBBFS.js} +6 -5
- package/dist/cdn/{CPQVVDWR.js → E6HEGXX7.js} +2 -2
- package/dist/cdn/{HD2PUJ4M.js → EYUSBYIW.js} +2 -2
- package/dist/cdn/{NRWICP4W.js → G2IB3XMP.js} +1 -1
- package/dist/cdn/{PN27PZAJ.js → HJJWMOF6.js} +1 -1
- package/dist/cdn/IOZSQPXO.js +4 -0
- package/dist/cdn/{5PZD27HR.js → KBZEMXOZ.js} +2 -2
- package/dist/cdn/{JWPIQMYD.js → KT6QWFGE.js} +2 -2
- package/dist/cdn/{K7OR2NZQ.js → KYTS4Y5Z.js} +2 -2
- package/dist/cdn/{6QMJS7YE.js → L7QUBKS2.js} +2 -2
- package/dist/cdn/{X52LNMUC.js → LCWDBLK5.js} +2 -2
- package/dist/cdn/{NUXDGLLB.js → MWJDLSR7.js} +2 -2
- package/dist/cdn/{QD7WBTTH.js → MXYCSRPO.js} +2 -2
- package/dist/cdn/{PGN77MRP.js → N72EMFRZ.js} +2 -2
- package/dist/cdn/{GOQNPC4I.js → OBNBH4MW.js} +2 -2
- package/dist/cdn/{4UJSQGRR.js → OR4EO6XC.js} +3 -3
- package/dist/cdn/{IB5UEIFQ.js → PUWOUCEX.js} +3 -3
- package/dist/cdn/{IYAABMEA.js → S33IAILZ.js} +2 -2
- package/dist/cdn/{SPSZUVWZ.js → SDJ67XRE.js} +2 -2
- package/dist/cdn/{3OPZD6HG.js → VNQVJXEK.js} +2 -2
- package/dist/cdn/{VPRYSGQQ.js → WG2TPIR6.js} +2 -2
- package/dist/cdn/{F2YRSIVP.js → X5FPHYTE.js} +2 -2
- package/dist/cdn/assets/code-editor/sql-expr.worker.js +66327 -65375
- package/dist/cdn/index.js +2 -2
- package/dist/chunks/arcade-defaults.js +2 -2
- package/dist/chunks/arcade-executor.js +42 -41
- package/dist/chunks/arcade-mode.js +1 -1
- package/dist/chunks/arcade-service-accessors.js +1 -1
- package/dist/chunks/editor.js +1 -1
- package/dist/chunks/fields.js +1 -1
- package/dist/chunks/language-defaults-base.js +4 -3
- package/dist/chunks/markdown.js +1 -1
- package/dist/chunks/monaco-importer.js +64 -44
- package/dist/chunks/runtime.js +1 -1
- package/dist/chunks/setup-monaco.js +1 -1
- package/dist/chunks/sql-expr-contribution.js +1 -1
- package/dist/chunks/sql-expr-defaults.js +1 -1
- package/dist/chunks/sql-expr-mode.js +1 -1
- package/dist/chunks/useT9n.js +1 -1
- package/dist/components/arcgis-arcade-coding-assistant/customElement.d.ts +6 -7
- package/dist/components/arcgis-arcade-coding-assistant/customElement.js +395 -176
- package/dist/components/arcgis-arcade-coding-assistant/functional.d.ts +69 -13
- package/dist/components/arcgis-arcade-coding-assistant/index.d.ts +12 -6
- package/dist/components/arcgis-arcade-coding-assistant/index.js +12 -6
- package/dist/components/arcgis-arcade-coding-assistant/types.d.ts +45 -0
- package/dist/components/arcgis-arcade-editor/customElement.js +1 -1
- 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 +2 -2
- package/dist/components/arcgis-editor-variables/customElement.js +1 -1
- package/dist/components/arcgis-language-api-panel/customElement.js +1 -1
- package/dist/components/arcgis-sql-expression-editor/customElement.js +1 -1
- package/dist/components/arcgis-sql-expression-fields/customElement.js +1 -1
- package/dist/docs/api.json +5 -5
- package/dist/docs/docs.json +5 -5
- package/dist/docs/web-types.json +1 -1
- package/dist/index.js +1 -1
- package/dist/loader.js +2 -2
- package/dist/utils/arcade-executor.d.ts +4 -0
- package/dist/utils/utilities.d.ts +1 -1
- package/package.json +6 -6
- package/dist/cdn/K3KP6FDP.js +0 -4
- package/dist/cdn/MX7D2TXJ.js +0 -5
- package/dist/cdn/SLKYJBMF.js +0 -4
- package/dist/cdn/Z75HQNTN.js +0 -4
package/dist/cdn/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
2
2
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
3
|
-
v4.34.0-next.
|
|
4
|
-
import{B as i,o as e}from"./
|
|
3
|
+
v4.34.0-next.30 */
|
|
4
|
+
import{B as i,o as e}from"./EYUSBYIW.js";import"./73X3KSHQ.js";import"./G2IB3XMP.js";var r=e(i,{"arcgis-arcade-coding-assistant":[()=>import("./DU4OWFNM.js"),"appVersion,assistantsEnabled,closed,closePanel:,editorRef:,feedbackServiceUrl,helpBase,insertText:,layer,portalUrl,serviceUrl;destroy"],"arcgis-arcade-editor":[()=>import("./CSS7NGXW.js"),"customPanels:,editorInstance:,editorOptions:,hideDocumentationActions,hideSideBar,openedSidePanel:,profile:,script,sideActionBarExpanded,snippets:,suggestions:,testData:;getEditorInstance,getScript,getTestResult,setFocus"],"arcgis-arcade-results":[()=>import("./LCWDBLK5.js"),"consoleLogs:,loading,openedResultPanel,result:"],"arcgis-arcade-suggestions":[()=>import("./OBNBH4MW.js"),"closed,suggestions:"],"arcgis-code-editor":[()=>import("./PUWOUCEX.js"),"editorInstance:,editorOptions:,language,modelId,value;getEditorInstance,getValue,insertSnippet,insertText,setFocus,setValue"],"arcgis-editor-variables":[()=>import("./KT6QWFGE.js"),"closed,loading,modelId,variable:"],"arcgis-language-api-panel":[()=>import("./N72EMFRZ.js"),"apiLibrary:,closed,hideDocumentationActions,languageId,loading"],"arcgis-sql-expression-editor":[()=>import("./3J5TNLID.js"),"hideSideBar,profile:,script"],"arcgis-sql-expression-fields":[()=>import("./IOZSQPXO.js"),"loading,modelId"]});r({resourcesUrl:import.meta.url});var o=new CSSStyleSheet;o.replaceSync("@layer{:not([hydrated]):is(arcgis-arcade-editor,arcgis-code-editor,arcgis-sql-expression-editor){visibility:hidden}:root{--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-side-panel-w: 600px;--arcgis-coding-components-side-panel-max-w: 45%;--arcgis-editor-comment: #606060;--arcgis-editor-constant: #9809C8;--arcgis-editor-date: #296389;--arcgis-editor-identifier: #0000B3;--arcgis-editor-keyword: #BF4900;--arcgis-editor-number: #136D3D;--arcgis-editor-string: #A31515}.calcite-mode-dark{--arcgis-editor-comment: #BFBFBF;--arcgis-editor-constant: #CDBAEA;--arcgis-editor-date: #97A6CE;--arcgis-editor-identifier: #9FD4F3;--arcgis-editor-keyword: #EEAA5A;--arcgis-editor-number: #AAD04B;--arcgis-editor-string: #F2877B}}");document.adoptedStyleSheets=[...document.adoptedStyleSheets,o];window.$arcgis||Object.defineProperty(window,"$arcgis",{configurable:!1,enumerable:!0,writable:!1,value:{}}),((a,r)=>{a.t=(c,...x)=>Promise.all(x.map(x=>x.then?x:(!a?.forceESM&&a?.import||(x=>import(x+".js").then(m=>m.default??m)))("@arcgis/core/"+x))).then(c);r.p=a.t(([m])=>{r.t=m.trackAccess;r.o=m.createObservable;r.c=m.createTrackingTarget;r.r=m.runTracked},"applications/Components/reactiveUtils")})($arcgis,i)
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { i as y,
|
|
1
|
+
import { i as y, c as P, a as T, d as b, f as A, L as x, E as D } from "./language-defaults-base.js";
|
|
2
2
|
import { supportedLocales as F, fetchT9nStringsBundle as M } from "@arcgis/components-utils";
|
|
3
3
|
import { g as m } from "./runtime.js";
|
|
4
4
|
import { CompletionItemKind as w, InsertTextFormat as f, InsertTextMode as d } from "vscode-languageserver-types";
|
|
5
5
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
6
6
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
7
|
-
v4.34.0-next.
|
|
7
|
+
v4.34.0-next.30 */
|
|
8
8
|
async function S(e) {
|
|
9
9
|
const { apiVersion: i, bundles: t, hiddenApiItems: n } = e.toEditorProfileDefinition(), r = await h(e.dictionaryVariables);
|
|
10
10
|
return { apiVersion: i, bundles: t, variables: r, hiddenApiItems: n?.map((s) => s.toLowerCase()) };
|
|
@@ -1,93 +1,94 @@
|
|
|
1
|
-
import { createArcadeExecutor as
|
|
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/4.34/esri/copyright.txt for details.
|
|
4
|
-
v4.34.0-next.
|
|
5
|
-
const
|
|
6
|
-
function
|
|
4
|
+
v4.34.0-next.30 */
|
|
5
|
+
const G = "https://developers.arcgis.com/arcade/", O = 100, A = 100;
|
|
6
|
+
function u(t) {
|
|
7
7
|
return !!t && typeof t == "object" && "declaredRootClass" in t && typeof t.declaredRootClass == "string" && t.declaredRootClass === "esri.arcade.featureset.support.FeatureSet";
|
|
8
8
|
}
|
|
9
|
-
function
|
|
9
|
+
function g(t) {
|
|
10
10
|
return !!t && typeof t == "object" && "arcadeDeclaredClass" in t && typeof t.arcadeDeclaredClass == "string" && t.arcadeDeclaredClass === "esri.arcade.Feature";
|
|
11
11
|
}
|
|
12
|
-
function
|
|
12
|
+
function b(t) {
|
|
13
13
|
return !!t && typeof t == "object" && "declaredClass" in t && typeof t.declaredClass == "string" && t.declaredClass === "esri.arcade.Dictionary";
|
|
14
14
|
}
|
|
15
|
-
function
|
|
15
|
+
function R(t) {
|
|
16
16
|
return !!t && typeof t == "object" && "declaredClass" in t && typeof t.declaredClass == "string" && t.declaredClass.startsWith("esri.geometry.");
|
|
17
17
|
}
|
|
18
|
-
function
|
|
18
|
+
function w(t) {
|
|
19
19
|
return !!t && typeof t == "object" && "declaredClass" in t && typeof t.declaredClass == "string" && t.declaredClass.startsWith("esri.rest.knowledgeGraph.KnowledgeGraph");
|
|
20
20
|
}
|
|
21
|
-
function
|
|
21
|
+
function h(t) {
|
|
22
22
|
return !!t && typeof t == "object" && "declaredClass" in t && typeof t.declaredClass == "string" && t.declaredClass === "esri.arcade.Portal";
|
|
23
23
|
}
|
|
24
|
-
function
|
|
24
|
+
function D(t) {
|
|
25
25
|
return !!t && typeof t == "object" && "declaredClass" in t && typeof t.declaredClass == "string" && t.declaredClass === "esri.arcade.Attachment";
|
|
26
26
|
}
|
|
27
|
-
function
|
|
27
|
+
function S(t) {
|
|
28
28
|
return !!t && typeof t == "object" && "declaredRootClass" in t && typeof t.declaredRootClass == "string" && t.declaredRootClass === "esri.arcade.arcadedate";
|
|
29
29
|
}
|
|
30
|
-
function
|
|
30
|
+
function x(t) {
|
|
31
31
|
return !!t && typeof t == "object" && "declaredRootClass" in t && typeof t.declaredRootClass == "string" && t.declaredRootClass === "esri.core.sql.dateonly";
|
|
32
32
|
}
|
|
33
|
-
function
|
|
33
|
+
function F(t) {
|
|
34
34
|
return !!t && typeof t == "object" && "declaredRootClass" in t && typeof t.declaredRootClass == "string" && t.declaredRootClass === "esri.core.sql.timeonly";
|
|
35
35
|
}
|
|
36
|
-
function
|
|
36
|
+
function T(t) {
|
|
37
37
|
return !!t && typeof t == "object" && "length" in t && typeof t.length == "function" && "get" in t && typeof t.get == "function" && "toArray" in t && typeof t.toArray == "function" && "_elements" in t && Array.isArray(t._elements);
|
|
38
38
|
}
|
|
39
|
-
function
|
|
40
|
-
return t == null ? { type: "null" } : Array.isArray(t) ? { type: "array", value: t } :
|
|
39
|
+
function j(t) {
|
|
40
|
+
return t == null ? { type: "null" } : Array.isArray(t) ? { type: "array", value: t } : T(t) ? { type: "array", value: t.toArray() } : t instanceof Date ? { type: "date", value: t } : typeof t == "string" ? { type: "text", value: t } : typeof t == "number" ? { type: "number", value: t } : typeof t == "boolean" ? { type: "boolean", value: t } : typeof t != "object" ? { type: "unknown" } : S(t) ? { type: "date", value: t } : x(t) ? { type: "dateOnly", value: t } : F(t) ? { type: "time", value: t } : D(t) ? { type: "attachment", value: t } : h(t) ? { type: "portal", value: t } : u(t) ? { type: "featureSet", value: t, features: [], iterator: null } : g(t) ? { type: "feature", value: t } : b(t) ? { type: "dictionary", value: t } : R(t) ? { type: "geometry", value: t } : w(t) ? { type: "knowledgeGraph", value: t } : { type: "unknown" };
|
|
41
41
|
}
|
|
42
|
-
function
|
|
42
|
+
function I(t, r = "en") {
|
|
43
43
|
return t.value instanceof Date ? new Intl.DateTimeFormat(r, { dateStyle: "medium", timeStyle: "long" }).format(t.value) : t.value.toDateTime().setLocale(r).toFormat(t.value.isUnknownTimeZone ? "FF" : "FF ZZZZZ");
|
|
44
44
|
}
|
|
45
|
-
function
|
|
45
|
+
function B(t) {
|
|
46
46
|
return t.value.toString();
|
|
47
47
|
}
|
|
48
|
-
function
|
|
48
|
+
function E(t) {
|
|
49
49
|
return t.value.toString();
|
|
50
50
|
}
|
|
51
|
-
async function
|
|
52
|
-
const e =
|
|
53
|
-
return e.type !== "featureSet" || (await e.value.load(), e.iterator = e.value.iterator({ aborted: !1 }), e.features = await e.iterator.nextBatchAsArcadeFeatures(
|
|
51
|
+
async function Z(t, r = "system") {
|
|
52
|
+
const e = j(t);
|
|
53
|
+
return e.type !== "featureSet" || (await e.value.load(), e.iterator = e.value.iterator({ aborted: !1 }), e.features = await e.iterator.nextBatchAsArcadeFeatures(A, r) ?? []), e;
|
|
54
54
|
}
|
|
55
|
-
async function
|
|
56
|
-
const
|
|
57
|
-
|
|
55
|
+
async function P(t, r, e, i) {
|
|
56
|
+
const a = /* @__PURE__ */ new Date();
|
|
57
|
+
i ??= () => {
|
|
58
58
|
};
|
|
59
59
|
try {
|
|
60
|
-
const n = performance.now(), o = await
|
|
60
|
+
const n = performance.now(), o = await C(r ?? "", {
|
|
61
61
|
variables: t?.variables ?? []
|
|
62
|
-
}), c = performance.now(), { profileVariableInstances: f, spatialReference: y, timeZone: d } = e,
|
|
62
|
+
}), c = performance.now(), { profileVariableInstances: f, spatialReference: y, timeZone: d, services: p } = e, m = {
|
|
63
63
|
spatialReference: y,
|
|
64
64
|
timeZone: d,
|
|
65
65
|
rawOutput: !0,
|
|
66
|
-
console:
|
|
67
|
-
|
|
66
|
+
console: i,
|
|
67
|
+
services: p
|
|
68
|
+
}, l = await o.executeAsync(
|
|
68
69
|
f,
|
|
69
|
-
|
|
70
|
-
), s = await
|
|
71
|
-
return s.timeStamp =
|
|
70
|
+
m
|
|
71
|
+
), s = await Z(l, d);
|
|
72
|
+
return s.timeStamp = a, s.compilationTime = c - n, s.executionTime = performance.now() - c, s;
|
|
72
73
|
} catch (n) {
|
|
73
74
|
let o = "Unknown Error";
|
|
74
75
|
return n instanceof Error && (o = n.message), {
|
|
75
76
|
type: "error",
|
|
76
77
|
value: o,
|
|
77
78
|
error: n,
|
|
78
|
-
timeStamp:
|
|
79
|
+
timeStamp: a,
|
|
79
80
|
compilationTime: 0,
|
|
80
81
|
executionTime: 0
|
|
81
82
|
};
|
|
82
83
|
}
|
|
83
84
|
}
|
|
84
85
|
export {
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
86
|
+
A as B,
|
|
87
|
+
G as D,
|
|
88
|
+
O as M,
|
|
89
|
+
B as a,
|
|
90
|
+
I as b,
|
|
91
|
+
P as e,
|
|
92
|
+
E as f,
|
|
93
|
+
j as v
|
|
93
94
|
};
|
|
@@ -8,7 +8,7 @@ import { InsertTextFormat as y, CompletionItemKind as o, DiagnosticSeverity as m
|
|
|
8
8
|
import { debounce as F, Deferred as _ } from "@arcgis/components-utils";
|
|
9
9
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
10
10
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
11
|
-
v4.34.0-next.
|
|
11
|
+
v4.34.0-next.30 */
|
|
12
12
|
const S = [
|
|
13
13
|
"<=",
|
|
14
14
|
">=",
|
package/dist/chunks/editor.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { css as e } from "@lit/reactive-element/css-tag.js";
|
|
2
2
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
|
-
v4.34.0-next.
|
|
4
|
+
v4.34.0-next.30 */
|
|
5
5
|
const o = e`@layer{arcgis-arcade-editor,arcgis-sql-expression-editor{.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)}.side-panel{max-width:var(--arcgis-coding-components-side-panel-max-w);width:var(--arcgis-coding-components-side-panel-w)}.side-panel calcite-flow{height:100%}}}`;
|
|
6
6
|
export {
|
|
7
7
|
o as s
|
package/dist/chunks/fields.js
CHANGED
|
@@ -12,7 +12,7 @@ import { filterApiLibraryForContext as le } from "@arcgis/languages-api-utils";
|
|
|
12
12
|
import { Emitter as x, Uri as $ } from "monaco-editor";
|
|
13
13
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
14
14
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
15
|
-
v4.34.0-next.
|
|
15
|
+
v4.34.0-next.30 */
|
|
16
16
|
function B(t) {
|
|
17
17
|
return !!t && typeof t == "object" && "declaredClass" in t && typeof t.declaredClass == "string" && t.declaredClass.startsWith("esri.layers.") && g(t) && "queryFeatures" in t && typeof t.queryFeatures == "function";
|
|
18
18
|
}
|
|
@@ -883,8 +883,9 @@ export {
|
|
|
883
883
|
Re as E,
|
|
884
884
|
ke as L,
|
|
885
885
|
We as a,
|
|
886
|
-
|
|
887
|
-
|
|
886
|
+
B as b,
|
|
887
|
+
Be as c,
|
|
888
|
+
Ue as d,
|
|
888
889
|
Oe as f,
|
|
889
890
|
Ne as i
|
|
890
891
|
};
|
package/dist/chunks/markdown.js
CHANGED
|
@@ -4,7 +4,7 @@ import { IStandaloneThemeService as G } from "monaco-editor/esm/vs/editor/standa
|
|
|
4
4
|
import { generateTokensCSSForColorMap as te } 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/4.34/esri/copyright.txt for details.
|
|
7
|
-
v4.34.0-next.
|
|
7
|
+
v4.34.0-next.30 */
|
|
8
8
|
async function ne(l, t) {
|
|
9
9
|
return await (await ee()).colorize(l, t, { tabSize: 2 });
|
|
10
10
|
}
|
|
@@ -1,83 +1,103 @@
|
|
|
1
|
-
import { createFilterExpression as
|
|
2
|
-
import { format as
|
|
1
|
+
import { createFilterExpression as f } from "@arcgis/components-utils";
|
|
2
|
+
import { format as p } from "@arcgis/arcade-languageservice";
|
|
3
3
|
import "monaco-editor";
|
|
4
4
|
import "monaco-editor/esm/vs/editor/standalone/browser/standaloneServices.js";
|
|
5
5
|
import "monaco-editor/esm/vs/editor/standalone/common/standaloneTheme.js";
|
|
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/4.34/esri/copyright.txt for details.
|
|
9
|
-
v4.34.0-next.
|
|
10
|
-
function
|
|
9
|
+
v4.34.0-next.30 */
|
|
10
|
+
function $(e, n, l, i) {
|
|
11
11
|
if (!n)
|
|
12
12
|
return [];
|
|
13
|
-
const
|
|
14
|
-
if (!
|
|
13
|
+
const t = Array.isArray(n) ? n : [n];
|
|
14
|
+
if (!t.length)
|
|
15
15
|
return [];
|
|
16
|
-
const
|
|
17
|
-
return e.filter((
|
|
16
|
+
const m = f(l);
|
|
17
|
+
return e.filter((o) => t.some((a) => m.test(String(o[a] ?? ""))));
|
|
18
18
|
}
|
|
19
|
-
function
|
|
19
|
+
function E(e) {
|
|
20
20
|
return e ? `${e.portal.url}/home/item.html?id=${e.id}` : "";
|
|
21
21
|
}
|
|
22
|
-
function
|
|
22
|
+
function M(e, n, l = "add", i) {
|
|
23
23
|
if (!e)
|
|
24
24
|
return;
|
|
25
|
-
const t = e.getSelection(),
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
25
|
+
const t = e.getSelection(), m = t && (t.startLineNumber !== t.endLineNumber || t.startColumn !== t.endColumn);
|
|
26
|
+
let o = [];
|
|
27
|
+
const a = e.getValue() ?? "";
|
|
28
|
+
if (l === "replace") {
|
|
29
|
+
const u = `${i}
|
|
30
|
+
${n}`, s = e.getModel(), r = s?.getLineCount() ?? 1, c = s?.getLineMaxColumn(r) ?? 1;
|
|
31
|
+
o = [
|
|
32
|
+
{
|
|
33
|
+
range: {
|
|
34
|
+
startLineNumber: 1,
|
|
35
|
+
startColumn: 1,
|
|
36
|
+
endLineNumber: r,
|
|
37
|
+
endColumn: c
|
|
38
|
+
},
|
|
39
|
+
text: u
|
|
40
|
+
}
|
|
41
|
+
];
|
|
42
|
+
} else {
|
|
43
|
+
const u = m ? {
|
|
44
|
+
startLineNumber: t.startLineNumber,
|
|
45
|
+
startColumn: t.startColumn,
|
|
46
|
+
endLineNumber: t.endLineNumber,
|
|
47
|
+
endColumn: t.endColumn
|
|
48
|
+
} : (() => {
|
|
49
|
+
const r = e.getPosition();
|
|
50
|
+
return {
|
|
51
|
+
startLineNumber: r?.lineNumber ?? 1,
|
|
52
|
+
startColumn: r?.column ?? 1,
|
|
53
|
+
endLineNumber: r?.lineNumber ?? 1,
|
|
54
|
+
endColumn: r?.column ?? 1
|
|
55
|
+
};
|
|
56
|
+
})();
|
|
57
|
+
let s = !1;
|
|
58
|
+
if (i) {
|
|
59
|
+
const r = i.replace(/[.*+?^${}()|[\]\\]/gu, "\\$&");
|
|
60
|
+
s = !new RegExp(`^\\s*${r}\\s*$`, "mu").test(a);
|
|
61
|
+
}
|
|
62
|
+
s && o.push({
|
|
42
63
|
range: {
|
|
43
64
|
startLineNumber: 1,
|
|
44
65
|
startColumn: 1,
|
|
45
66
|
endLineNumber: 1,
|
|
46
67
|
endColumn: 1
|
|
47
68
|
},
|
|
48
|
-
text:
|
|
69
|
+
text: `${i}
|
|
49
70
|
`
|
|
71
|
+
}), o.push({
|
|
72
|
+
range: u,
|
|
73
|
+
text: n
|
|
50
74
|
});
|
|
51
75
|
}
|
|
52
|
-
i.push({
|
|
53
|
-
range: s,
|
|
54
|
-
text: n
|
|
55
|
-
});
|
|
56
76
|
try {
|
|
57
|
-
e.pushUndoStop(), e.executeEdits("insertText",
|
|
58
|
-
} catch (
|
|
59
|
-
console.error("Failed to edit model:",
|
|
77
|
+
e.pushUndoStop(), e.executeEdits("insertText", o), e.pushUndoStop(), e.focus();
|
|
78
|
+
} catch (u) {
|
|
79
|
+
console.error("Failed to edit model:", u);
|
|
60
80
|
}
|
|
61
81
|
}
|
|
62
|
-
function
|
|
82
|
+
function R(e) {
|
|
63
83
|
try {
|
|
64
|
-
return
|
|
84
|
+
return p(e);
|
|
65
85
|
} catch {
|
|
66
86
|
return e;
|
|
67
87
|
}
|
|
68
88
|
}
|
|
69
|
-
const
|
|
89
|
+
const g = async () => {
|
|
70
90
|
const { editor: e } = await import("monaco-editor/esm/vs/editor/editor.api.js");
|
|
71
91
|
return e;
|
|
72
92
|
};
|
|
73
|
-
let
|
|
93
|
+
let d = null;
|
|
74
94
|
async function S() {
|
|
75
|
-
return
|
|
95
|
+
return d ??= g(), await d;
|
|
76
96
|
}
|
|
77
97
|
export {
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
98
|
+
R as a,
|
|
99
|
+
M as e,
|
|
100
|
+
$ as f,
|
|
81
101
|
S as i,
|
|
82
|
-
|
|
102
|
+
E as p
|
|
83
103
|
};
|
package/dist/chunks/runtime.js
CHANGED
|
@@ -2,7 +2,7 @@ import { makeRuntime as e } from "@arcgis/lumina";
|
|
|
2
2
|
import { trackAccess as s, createObservable as r, createTrackingTarget as a, runTracked as c } from "@arcgis/core/applications/Components/reactiveUtils.js";
|
|
3
3
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
4
4
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
5
|
-
v4.34.0-next.
|
|
5
|
+
v4.34.0-next.30 */
|
|
6
6
|
const t = e({ defaultAssetPath: "https://jsdev.arcgis.com/next/coding-components/", hydratedAttribute: "hydrated" }), { customElement: n, getAssetPath: d, setAssetPath: i } = t;
|
|
7
7
|
t.t = s;
|
|
8
8
|
t.o = r;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import i from "@arcgis/core/request.js";
|
|
2
2
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
|
-
v4.34.0-next.
|
|
4
|
+
v4.34.0-next.30 */
|
|
5
5
|
function p() {
|
|
6
6
|
return !!window.MonacoEnvironment?.getWorkerUrl;
|
|
7
7
|
}
|
|
@@ -8,7 +8,7 @@ import { g as c } from "./arcade-service-accessors.js";
|
|
|
8
8
|
import { a as n } from "./sql-expr-defaults.js";
|
|
9
9
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
10
10
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
11
|
-
v4.34.0-next.
|
|
11
|
+
v4.34.0-next.30 */
|
|
12
12
|
const s = /* @__PURE__ */ new Set();
|
|
13
13
|
function g(e, o) {
|
|
14
14
|
return () => {
|
|
@@ -4,7 +4,7 @@ import { fetchT9nStringsBundle as M } from "@arcgis/components-utils";
|
|
|
4
4
|
import { g as b } from "./runtime.js";
|
|
5
5
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
6
6
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
7
|
-
v4.34.0-next.
|
|
7
|
+
v4.34.0-next.30 */
|
|
8
8
|
const x = (r) => {
|
|
9
9
|
const e = r.variables[0], i = e && e.type === "featureSet" ? A(e) : void 0, { apiVersion: t, bundles: o, hiddenApiItems: s } = r.toEditorProfileDefinition();
|
|
10
10
|
return {
|
|
@@ -7,7 +7,7 @@ import { Deferred as _, debounce as N } from "@arcgis/components-utils";
|
|
|
7
7
|
import { a as d } from "./sql-expr-defaults.js";
|
|
8
8
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
9
9
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
10
|
-
v4.34.0-next.
|
|
10
|
+
v4.34.0-next.30 */
|
|
11
11
|
let h = new _();
|
|
12
12
|
class k {
|
|
13
13
|
constructor(e) {
|
package/dist/chunks/useT9n.js
CHANGED
|
@@ -2,7 +2,7 @@ import { makeT9nController as o } from "@arcgis/lumina/controllers";
|
|
|
2
2
|
import { g as t } from "./runtime.js";
|
|
3
3
|
/*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
4
4
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
5
|
-
v4.34.0-next.
|
|
5
|
+
v4.34.0-next.30 */
|
|
6
6
|
const s = o(t);
|
|
7
7
|
export {
|
|
8
8
|
s as u
|
|
@@ -2,12 +2,10 @@
|
|
|
2
2
|
/// <reference types="../../index.d.ts" />
|
|
3
3
|
import { JsxNode, PublicLitElement as LitElement, TargetedEvent } from '@arcgis/lumina';
|
|
4
4
|
import { ArcgisArcadeEditor } from '../arcgis-arcade-editor/customElement.js';
|
|
5
|
+
import { ResponseDisplayCard } from './functional';
|
|
6
|
+
import { HistoryItem, FeedbackState, Context } from './types';
|
|
7
|
+
import { PropertyValues } from 'lit';
|
|
5
8
|
|
|
6
|
-
type HistoryItem = {
|
|
7
|
-
script?: string;
|
|
8
|
-
error?: string;
|
|
9
|
-
question: string;
|
|
10
|
-
};
|
|
11
9
|
/**
|
|
12
10
|
* Arcade Assistant component for AI-powered Arcade code generation.
|
|
13
11
|
*
|
|
@@ -16,6 +14,8 @@ type HistoryItem = {
|
|
|
16
14
|
export declare class ArcgisArcadeCodingAssistant extends LitElement {
|
|
17
15
|
closePanel?: (e: Event) => void;
|
|
18
16
|
insertText?: (text: string) => void;
|
|
17
|
+
/** @default "" */
|
|
18
|
+
helpBase?: string;
|
|
19
19
|
/**
|
|
20
20
|
* Whether ai assistants are enabled in the organization's settings.
|
|
21
21
|
*
|
|
@@ -23,7 +23,7 @@ export declare class ArcgisArcadeCodingAssistant extends LitElement {
|
|
|
23
23
|
*/
|
|
24
24
|
assistantsEnabled: boolean;
|
|
25
25
|
layer: __esri.CatalogFootprintLayer | __esri.CSVLayer | __esri.FeatureLayer | __esri.GeoJSONLayer | __esri.OGCFeatureLayer | __esri.OrientedImageryLayer | __esri.SceneLayer | __esri.Sublayer | __esri.SubtypeSublayer | __esri.VoxelLayer | __esri.WFSLayer;
|
|
26
|
-
|
|
26
|
+
portalUrl: string;
|
|
27
27
|
serviceUrl: string;
|
|
28
28
|
/** @default false */
|
|
29
29
|
closed: boolean;
|
|
@@ -33,4 +33,3 @@ export declare class ArcgisArcadeCodingAssistant extends LitElement {
|
|
|
33
33
|
/** Permanently destroy the component */
|
|
34
34
|
destroy(): Promise<void>;
|
|
35
35
|
}
|
|
36
|
-
export {};
|