@arcgis/coding-components 5.0.0-next.163 → 5.0.0-next.165
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/cdn/{NEEMZKOL.js → 2L6LB337.js} +1 -1
- package/dist/cdn/4IUBBV3F.js +4 -0
- package/dist/cdn/{WQGZW7TU.js → 7R25VCNT.js} +1 -1
- package/dist/cdn/{RO427XLV.js → A25KOTF5.js} +1 -1
- package/dist/cdn/{KX2GUS7A.js → FLR5NNW4.js} +1 -1
- package/dist/cdn/{FOOS4KBL.js → KRMO2D34.js} +1 -1
- package/dist/cdn/{26MOVMMM.js → LKHTGB23.js} +1 -1
- package/dist/cdn/MPBM2OB4.js +60 -0
- package/dist/cdn/{BUY5C6Q3.js → RDH3NRSC.js} +1 -1
- package/dist/cdn/{BRSZWZFH.js → SURR7QIN.js} +1 -1
- package/dist/cdn/{X5AMXKB3.js → TGOQLCSV.js} +1 -1
- package/dist/cdn/{X4I7WY6U.js → X34XPSPB.js} +1 -1
- package/dist/cdn/{5SBFB2DR.js → YCYFQ3ZA.js} +1 -1
- package/dist/cdn/assets/code-editor/sql-expr.worker.js +2 -2
- package/dist/cdn/index.js +1 -1
- package/dist/chunks/language-defaults-base.js +9 -9
- package/dist/chunks/markdown.js +409 -388
- package/dist/components/arcgis-arcade-coding-assistant/customElement.js +352 -302
- package/dist/components/arcgis-arcade-editor/customElement.d.ts +1 -1
- package/dist/components/arcgis-arcade-editor/customElement.js +11 -11
- package/dist/components/types.d.ts +8 -11
- package/dist/docs/api.json +1 -1
- package/dist/docs/docs.json +1 -1
- package/dist/docs/web-types.json +1 -1
- package/dist/loader.js +1 -1
- package/dist/utils/arcade-assistant/types.d.ts +2 -0
- package/dist/utils/arcade-executor.d.ts +3 -3
- package/package.json +5 -5
- package/dist/cdn/PWP6N6LB.js +0 -4
- package/dist/cdn/SKYRSHU7.js +0 -60
- /package/dist/cdn/{JV7SUK33.js → UH5Q5C4Q.js} +0 -0
|
@@ -52,7 +52,7 @@ export abstract class ArcgisArcadeEditor extends LitElement {
|
|
|
52
52
|
* }
|
|
53
53
|
* ```
|
|
54
54
|
*
|
|
55
|
-
* To get the full list of available options, see the Monaco Editor options [documentation](https://microsoft.github.io/monaco-editor/
|
|
55
|
+
* To get the full list of available options, see the Monaco Editor options [documentation](https://microsoft.github.io/monaco-editor/docs.html#interfaces/editor_editor_api.editor.IEditorOptions.html) for more details.
|
|
56
56
|
*/
|
|
57
57
|
accessor editorOptions: Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined;
|
|
58
58
|
/**
|
|
@@ -11,8 +11,8 @@ import "monaco-editor/esm/vs/editor/browser/editorDom.js";
|
|
|
11
11
|
import "monaco-editor/esm/vs/editor/browser/controller/mouseTarget.js";
|
|
12
12
|
import { LitElement as k, createEvent as v, safeClassMap as l } from "@arcgis/lumina";
|
|
13
13
|
import { generateGuid as M } from "@arcgis/toolkit/string";
|
|
14
|
-
import { D as
|
|
15
|
-
import { s as
|
|
14
|
+
import { D as L, e as x } from "../../chunks/arcade-executor.js";
|
|
15
|
+
import { s as T, g as U } from "../../chunks/arcade-service-accessors.js";
|
|
16
16
|
import { b as c } from "../../chunks/arcade-defaults.js";
|
|
17
17
|
import { u as F } from "../../chunks/useT9n.js";
|
|
18
18
|
import { createRef as N, ref as H } from "lit/directives/ref.js";
|
|
@@ -28,7 +28,7 @@ const j = C`:host{height:100%}calcite-tooltip:not([calcite-hydrated])>*{display:
|
|
|
28
28
|
return a("warn", "User is not signed in."), !1;
|
|
29
29
|
}
|
|
30
30
|
};
|
|
31
|
-
async function
|
|
31
|
+
async function Q({
|
|
32
32
|
portalUrl: i,
|
|
33
33
|
profile: e
|
|
34
34
|
}) {
|
|
@@ -63,9 +63,9 @@ async function X({
|
|
|
63
63
|
feedbackServiceUrl: E
|
|
64
64
|
};
|
|
65
65
|
}
|
|
66
|
-
class
|
|
66
|
+
class X extends k {
|
|
67
67
|
constructor() {
|
|
68
|
-
super(...arguments), this._codeEditorElt = N(), this._componentReadyDefer = Promise.withResolvers(), this._disposables = [], this._editorProfilePromise = Promise.resolve(void 0), this.messages = F(), this._modelId = M(), this._openArcadeHelp = () => void window.open(
|
|
68
|
+
super(...arguments), this._codeEditorElt = N(), this._componentReadyDefer = Promise.withResolvers(), this._disposables = [], this._editorProfilePromise = Promise.resolve(void 0), this.messages = F(), this._modelId = M(), this._openArcadeHelp = () => void window.open(L, "Arcade Help"), this._toggleSidePanel = (e) => {
|
|
69
69
|
if (!e.target)
|
|
70
70
|
return;
|
|
71
71
|
const t = e.target?.dataset.panelName ?? "none";
|
|
@@ -96,7 +96,7 @@ class K extends k {
|
|
|
96
96
|
}
|
|
97
97
|
async load() {
|
|
98
98
|
const e = I("./assets");
|
|
99
|
-
|
|
99
|
+
T(e), await this._updateDataModelDeps(), await this._updateArcadeAssistantRemoteState();
|
|
100
100
|
}
|
|
101
101
|
willUpdate(e) {
|
|
102
102
|
(e.has("messages") || e.has("profile")) && this.hasUpdated && this._updateDataModelDeps(), e.has("testData") && this._testDataChanged(), e.has("snippets") && c.updateApiContextForModel(this._modelId, {
|
|
@@ -105,7 +105,7 @@ class K extends k {
|
|
|
105
105
|
}
|
|
106
106
|
async loaded() {
|
|
107
107
|
this._componentReadyDefer.resolve(), await this._updateApiLibrary();
|
|
108
|
-
const e = await
|
|
108
|
+
const e = await U();
|
|
109
109
|
this._disposables.push(e.onDiagnosticsChange((t) => !this._preparingArcade && this.arcgisDiagnosticsChange.emit(t.diagnostics))), this.testData && this._addExecuteScriptAction();
|
|
110
110
|
}
|
|
111
111
|
disconnectedCallback() {
|
|
@@ -192,7 +192,7 @@ class K extends k {
|
|
|
192
192
|
t !== -1 && this._disposables.splice(t, 1), e.dispose();
|
|
193
193
|
}
|
|
194
194
|
async _updateArcadeAssistantRemoteState() {
|
|
195
|
-
this.arcadeAssistant && (this._arcadeAssistantRemoteState = await
|
|
195
|
+
this.arcadeAssistant && (this._arcadeAssistantRemoteState = await Q({
|
|
196
196
|
...this.arcadeAssistant,
|
|
197
197
|
profile: this.profile
|
|
198
198
|
}));
|
|
@@ -251,7 +251,7 @@ class K extends k {
|
|
|
251
251
|
if (this.hideSideBar)
|
|
252
252
|
return null;
|
|
253
253
|
const { openedSidePanel: e } = this;
|
|
254
|
-
return s`<arcgis-language-api-panel slot=side-panel class=${l(e === "api" ? "" : "hidden")} .loading=${this._preparingArcade} .apiLibrary=${this._apiLibrary} .hideDocumentationActions=${this.hideDocumentationActions} @arcgisInternalItemSelected=${this._insertAsSnippet} @arcgisInternalClosePanel=${this._toggleSidePanel} data-panel-name=none .closed=${e !== "api"}></arcgis-language-api-panel><arcgis-editor-variables slot=side-panel class=${l(e === "variables" ? "" : "hidden")} .loading=${this._preparingArcade} .modelId=${this._modelId} @arcgisInternalItemSelected=${this._insertAsText} @arcgisInternalClosePanel=${this._toggleSidePanel} data-panel-name=none .variable=${this._editorProfile} .closed=${e !== "variables"}></arcgis-editor-variables>${this.suggestions?.length && s`<arcgis-arcade-suggestions slot=side-panel class=${l(e === "suggestions" ? "" : "hidden")} .closed=${e !== "suggestions"} .suggestions=${this.suggestions} @arcgisInternalItemSelected=${this._insertAsText} @arcgisInternalClosePanel=${this._toggleSidePanel} data-panel-name=none></arcgis-arcade-suggestions>` || ""}${this.arcadeAssistant && this._arcadeAssistantRemoteState.shouldRender && s`<arcgis-arcade-coding-assistant slot=side-panel class=${l(e === "arcade-assistant" ? "" : "hidden")} .closed=${e !== "arcade-assistant"} .insertText=${this._insertText.bind(this)} .closePanel=${this._toggleSidePanel} .portalUrl=${this.arcadeAssistant.portalUrl} .serviceUrl=${"serviceUrl" in this._arcadeAssistantRemoteState ? this._arcadeAssistantRemoteState.serviceUrl : void 0} .helpBase=${this._arcadeAssistantRemoteState.helpBase} .assistantsEnabled=${this._arcadeAssistantRemoteState.assistantsEnabled} .feedbackServiceUrl=${this._arcadeAssistantRemoteState.feedbackServiceUrl} .editorRef=${this.el} .appVersion=${this.arcadeAssistant.appVersion}></arcgis-arcade-coding-assistant>` || ""}${this.customPanels?.map((t) => s`<calcite-flow slot=side-panel class=${l(e === t.id ? "" : "hidden")}>${t?.useFlows ? t.renderer?.({
|
|
254
|
+
return s`<arcgis-language-api-panel slot=side-panel class=${l(e === "api" ? "" : "hidden")} .loading=${this._preparingArcade} .apiLibrary=${this._apiLibrary} .hideDocumentationActions=${this.hideDocumentationActions} @arcgisInternalItemSelected=${this._insertAsSnippet} @arcgisInternalClosePanel=${this._toggleSidePanel} data-panel-name=none .closed=${e !== "api"}></arcgis-language-api-panel><arcgis-editor-variables slot=side-panel class=${l(e === "variables" ? "" : "hidden")} .loading=${this._preparingArcade} .modelId=${this._modelId} @arcgisInternalItemSelected=${this._insertAsText} @arcgisInternalClosePanel=${this._toggleSidePanel} data-panel-name=none .variable=${this._editorProfile} .closed=${e !== "variables"}></arcgis-editor-variables>${this.suggestions?.length && s`<arcgis-arcade-suggestions slot=side-panel class=${l(e === "suggestions" ? "" : "hidden")} .closed=${e !== "suggestions"} .suggestions=${this.suggestions} @arcgisInternalItemSelected=${this._insertAsText} @arcgisInternalClosePanel=${this._toggleSidePanel} data-panel-name=none></arcgis-arcade-suggestions>` || ""}${this.arcadeAssistant && this._arcadeAssistantRemoteState.shouldRender && s`<arcgis-arcade-coding-assistant slot=side-panel class=${l(e === "arcade-assistant" ? "" : "hidden")} .closed=${e !== "arcade-assistant"} .insertText=${this._insertText.bind(this)} .closePanel=${this._toggleSidePanel} .portalUrl=${this.arcadeAssistant.portalUrl} .serviceUrl=${"serviceUrl" in this._arcadeAssistantRemoteState ? this._arcadeAssistantRemoteState.serviceUrl : void 0} .helpBase=${this._arcadeAssistantRemoteState.helpBase} .assistantsEnabled=${this._arcadeAssistantRemoteState.assistantsEnabled} .feedbackServiceUrl=${this._arcadeAssistantRemoteState.feedbackServiceUrl} .editorRef=${this.el} .appVersion=${this.arcadeAssistant.appVersion} .disableQuestionAnswerLogging=${this.arcadeAssistant.disableQuestionAnswerLogging}></arcgis-arcade-coding-assistant>` || ""}${this.customPanels?.map((t) => s`<calcite-flow slot=side-panel class=${l(e === t.id ? "" : "hidden")}>${t?.useFlows ? t.renderer?.({
|
|
255
255
|
closePanel: this._toggleSidePanel,
|
|
256
256
|
insertText: this._insertText.bind(this),
|
|
257
257
|
closed: e !== t.id,
|
|
@@ -272,7 +272,7 @@ class K extends k {
|
|
|
272
272
|
return s`<arcgis-code-editor-shell>${this.renderMainActionBar()}${this.renderMainPanel()}${this.renderResultsPanel()}${this.renderSidePanel()}${this.renderSideActionBar()}</arcgis-code-editor-shell>`;
|
|
273
273
|
}
|
|
274
274
|
}
|
|
275
|
-
D("arcgis-arcade-editor",
|
|
275
|
+
D("arcgis-arcade-editor", X);
|
|
276
276
|
export {
|
|
277
|
-
|
|
277
|
+
X as ArcgisArcadeEditor
|
|
278
278
|
};
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import type VoxelLayer from "@arcgis/core/layers/VoxelLayer";
|
|
2
|
-
import type ImageryLayer from "@arcgis/core/layers/ImageryLayer";
|
|
3
|
-
import type ImageryTileLayer from "@arcgis/core/layers/ImageryTileLayer";
|
|
1
|
+
import type VoxelLayer from "@arcgis/core/layers/VoxelLayer.js";
|
|
2
|
+
import type ImageryLayer from "@arcgis/core/layers/ImageryLayer.js";
|
|
3
|
+
import type ImageryTileLayer from "@arcgis/core/layers/ImageryTileLayer.js";
|
|
4
4
|
import type FeatureLayer from "@arcgis/core/layers/FeatureLayer.js";
|
|
5
|
-
import type WebMap from "@arcgis/core/WebMap";
|
|
6
|
-
import type WebScene from "@arcgis/core/WebScene";
|
|
7
|
-
import type Map from "@arcgis/core/Map";
|
|
8
|
-
import type SpatialReference from "@arcgis/core/geometry/SpatialReference";
|
|
5
|
+
import type WebMap from "@arcgis/core/WebMap.js";
|
|
6
|
+
import type WebScene from "@arcgis/core/WebScene.js";
|
|
7
|
+
import type Map from "@arcgis/core/Map.js";
|
|
8
|
+
import type SpatialReference from "@arcgis/core/geometry/SpatialReference.js";
|
|
9
9
|
import type { Diagnostic as ArcadeLanguageServiceDiagnostic } from "@arcgis/arcade-languageservice";
|
|
10
10
|
import type { ApiItem, BundleType, ProfileId } from "@arcgis/languages-api-utils";
|
|
11
|
-
import type { ProfileVariableInstances, ArcadeServices } from "@arcgis/core/arcade";
|
|
11
|
+
import type { ProfileVariableInstances, ArcadeServices } from "@arcgis/core/arcade.js";
|
|
12
12
|
|
|
13
13
|
export type Diagnostic = ArcadeLanguageServiceDiagnostic;
|
|
14
14
|
|
|
@@ -222,7 +222,6 @@ export interface IEditorCodeSuggestion {
|
|
|
222
222
|
|
|
223
223
|
export type SidePanelName = "api" | "none" | "suggestions" | "variables";
|
|
224
224
|
|
|
225
|
-
/** @internal */
|
|
226
225
|
export interface IContextReferences {
|
|
227
226
|
/**
|
|
228
227
|
* Spatial reference object used to define the spatial reference for the arcade runtime.
|
|
@@ -242,8 +241,6 @@ export interface IContextReferences {
|
|
|
242
241
|
* If a profile doesn't contain a map, the spatial reference of geometries will be defaulted to
|
|
243
242
|
* wkid: 3857.
|
|
244
243
|
* The test context objects allows to set the execution spatial reference for such scenario.
|
|
245
|
-
*
|
|
246
|
-
* @internal
|
|
247
244
|
*/
|
|
248
245
|
export interface IEditorTestContext extends IContextReferences {
|
|
249
246
|
/**
|