@arcgis/coding-components 4.31.0-next.2 → 4.31.0-next.4
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/arcgis-coding-components/arcgis-coding-components.esm.js +2 -2
- package/dist/arcgis-coding-components/assets/code-editor/css.worker.js +1 -1
- package/dist/arcgis-coding-components/assets/code-editor/html.worker.js +1 -1
- package/dist/arcgis-coding-components/assets/code-editor/json.worker.js +1 -1
- package/dist/arcgis-coding-components/assets/code-editor/sql-expr.worker.js +11 -0
- package/dist/arcgis-coding-components/assets/code-editor/ts.worker.js +1 -1
- package/dist/arcgis-coding-components/assets/sql-expression-editor/api/sql-expression-api.t9n.en.json +735 -0
- package/dist/arcgis-coding-components/index.esm.js +2 -2
- package/dist/arcgis-coding-components/p-103bdac3.js +6 -0
- package/dist/arcgis-coding-components/{p-7984ea8e.js → p-26c67f7c.js} +2 -2
- package/dist/arcgis-coding-components/{p-e8211ffe.js → p-2d14950e.js} +1 -1
- package/dist/arcgis-coding-components/p-374b59c1.js +6 -0
- package/dist/arcgis-coding-components/{p-62ee6251.js → p-4e56f8ae.js} +1 -1
- package/dist/arcgis-coding-components/{p-5ef7cce5.js → p-5da03560.js} +1 -1
- package/dist/arcgis-coding-components/p-5e173b51.entry.js +6 -0
- package/dist/arcgis-coding-components/{p-bb7e832e.js → p-736d890c.js} +3 -3
- package/dist/arcgis-coding-components/{p-03ea6cd7.js → p-86625411.js} +3 -3
- package/dist/arcgis-coding-components/{p-93a97573.js → p-8d67b196.js} +3 -3
- package/dist/arcgis-coding-components/{p-60c2a820.js → p-8e93417c.js} +2 -2
- package/dist/arcgis-coding-components/{p-36fedc23.js → p-a256ee9c.js} +10 -10
- package/dist/arcgis-coding-components/{p-0c6de9b3.js → p-a36c357f.js} +2 -2
- package/dist/arcgis-coding-components/{p-e7ee4d64.js → p-ab0f6db7.js} +3 -3
- package/dist/arcgis-coding-components/p-b23a3f4e.entry.js +6 -0
- package/dist/arcgis-coding-components/{p-9eced6fc.js → p-b570d7af.js} +2 -2
- package/dist/arcgis-coding-components/p-de5cabbb.js +6 -0
- package/dist/arcgis-coding-components/p-e6cac921.entry.js +6 -0
- package/dist/cjs/{app-globals-aee5f4b5.js → app-globals-209c2310.js} +1 -1
- package/dist/cjs/arcade-defaults-ee308e3a.js +116 -0
- package/dist/cjs/{arcade-mode-b85ae7d4.js → arcade-mode-f2c3951e.js} +62 -62
- package/dist/cjs/arcgis-arcade-editor_6.cjs.entry.js +177 -1491
- package/dist/cjs/arcgis-coding-components.cjs.js +4 -4
- package/dist/cjs/arcgis-sql-expression-editor.cjs.entry.js +81 -0
- package/dist/cjs/arcgis-sql-expression-fields.cjs.entry.js +80 -0
- package/dist/cjs/{css-7cc05f76.js → css-bbd000cd.js} +1 -1
- package/dist/cjs/{cssMode-2b0daeae.js → cssMode-ad163e66.js} +4 -4
- package/dist/cjs/{html-f56911e1.js → html-5c67b9d0.js} +4 -4
- package/dist/cjs/{htmlMode-43eed674.js → htmlMode-e32a97bd.js} +4 -4
- package/dist/cjs/{index-b34238a6.js → index-8b891c40.js} +9 -1
- package/dist/cjs/index.cjs.js +4 -3
- package/dist/cjs/{javascript-5115cb76.js → javascript-e159fa2f.js} +4 -4
- package/dist/cjs/{jsonMode-550dda36.js → jsonMode-5c107443.js} +4 -4
- package/dist/cjs/{arcade-defaults-a8d8f8e2.js → language-defaults-base-4300e691.js} +61 -162
- package/dist/cjs/loader.cjs.js +4 -4
- package/dist/cjs/sql-expr-defaults-783d9c24.js +1285 -0
- package/dist/cjs/sql-expr-mode-6cac37ed.js +25135 -0
- package/dist/cjs/{tsMode-336306a9.js → tsMode-83c4587f.js} +5 -5
- package/dist/cjs/{typescript-b395242f.js → typescript-f6ca5d84.js} +4 -4
- package/dist/components/arcade-defaults.js +8 -1557
- package/dist/components/arcade-mode.js +2 -2
- package/dist/components/arcade-results.js +6 -4
- package/dist/components/arcade-suggestions.js +7 -5
- package/dist/components/arcade-variables.js +8 -6
- package/dist/components/arcgis-arcade-editor.js +33 -32
- package/dist/components/arcgis-arcade-results.js +1 -1
- package/dist/components/arcgis-arcade-suggestions.js +1 -1
- package/dist/components/arcgis-arcade-variables.js +1 -1
- package/dist/components/arcgis-assets.d.ts +1 -1
- package/dist/components/arcgis-assets.js +1 -1
- package/dist/components/arcgis-code-editor.js +1 -1
- package/dist/components/arcgis-language-api-panel.js +1 -1
- package/dist/components/arcgis-sql-expression-editor.d.ts +11 -0
- package/dist/components/arcgis-sql-expression-editor.js +120 -0
- package/dist/components/arcgis-sql-expression-fields.d.ts +11 -0
- package/dist/components/arcgis-sql-expression-fields.js +11 -0
- package/dist/components/chunk-6TARY3NN.js +1159 -0
- package/dist/components/code-editor.js +41 -7
- package/dist/components/fields.js +2 -2
- package/dist/components/index.js +1 -1
- package/dist/components/index2.js +30 -22
- package/dist/components/language-api-panel.js +13 -40
- package/dist/components/language-defaults-base.js +1551 -0
- package/dist/components/markdown.js +1 -1
- package/dist/components/sql-expr-defaults.js +131 -0
- package/dist/components/sql-expr-mode.js +25132 -0
- package/dist/components/sql-expression-fields.js +102 -0
- package/dist/components/useT9n.js +45 -8
- package/dist/components/utilities.js +1 -1
- package/dist/esm/{app-globals-59faaf33.js → app-globals-60a61d0d.js} +1 -1
- package/dist/esm/arcade-defaults-b1a5f013.js +111 -0
- package/dist/esm/{arcade-mode-5d46035e.js → arcade-mode-7e6764ac.js} +3 -3
- package/dist/esm/arcgis-arcade-editor_6.entry.js +124 -1438
- package/dist/esm/arcgis-coding-components.js +5 -5
- package/dist/esm/arcgis-sql-expression-editor.entry.js +77 -0
- package/dist/esm/arcgis-sql-expression-fields.entry.js +76 -0
- package/dist/esm/{css-e257dc49.js → css-7d75b7ca.js} +1 -1
- package/dist/esm/{cssMode-c11f7f40.js → cssMode-95305ae2.js} +3 -3
- package/dist/esm/{html-a6c37a99.js → html-84fc596c.js} +3 -3
- package/dist/esm/{htmlMode-1270bc7d.js → htmlMode-c961f619.js} +3 -3
- package/dist/esm/{index-a970952c.js → index-1c1754c0.js} +9 -1
- package/dist/esm/index.js +4 -3
- package/dist/esm/{javascript-ee179624.js → javascript-0aa4505f.js} +4 -4
- package/dist/esm/{jsonMode-07502ccb.js → jsonMode-86b234eb.js} +3 -3
- package/dist/esm/{arcade-defaults-9eb28407.js → language-defaults-base-949fa7fb.js} +55 -158
- package/dist/esm/loader.js +5 -5
- package/dist/esm/sql-expr-defaults-f2f50289.js +1279 -0
- package/dist/esm/sql-expr-mode-14c94be3.js +25132 -0
- package/dist/esm/{tsMode-96749a12.js → tsMode-ee945c40.js} +3 -3
- package/dist/esm/{typescript-a3cf9881.js → typescript-8bd2bb48.js} +3 -3
- package/dist/loader/cdn.js +1 -1
- package/dist/loader/index.cjs.js +1 -1
- package/dist/loader/index.es2017.js +1 -1
- package/dist/loader/index.js +1 -1
- package/dist/types/components/arcade-editor/arcade-editor.d.ts +33 -8
- package/dist/types/components/arcade-results/arcade-results.d.ts +43 -1
- package/dist/types/components/arcade-suggestions/arcade-suggestions.d.ts +22 -1
- package/dist/types/components/arcade-variables/arcade-variables.d.ts +28 -1
- package/dist/types/components/code-editor/code-editor.d.ts +2 -1
- package/dist/types/components/language-api-panel/language-api-panel.d.ts +34 -8
- package/dist/types/components/sql-expression-editor/sql-expression-editor.d.ts +24 -0
- package/dist/types/components/sql-expression-fields/sql-expression-fields.d.ts +32 -0
- package/dist/types/components.d.ts +85 -11
- package/dist/types/data/actions-runner-1/_work/arcgis-web-components/arcgis-web-components/packages/coding-packages/coding-components/.stencil/stories/internal/sql-expression-editor/sql-expression-editor.stories.d.ts +13 -0
- package/dist/types/dependencies.d.ts +6 -10
- package/dist/types/utils/language-defaults-base.d.ts +2 -9
- package/dist/types/utils/profile/predefined-profile.d.ts +3 -1
- package/dist/types/utils/sql-expr-monaco/DependentFiles/DateOnly.d.ts +41 -0
- package/dist/types/utils/sql-expr-monaco/DependentFiles/SqlInterval.d.ts +16 -0
- package/dist/types/utils/sql-expr-monaco/DependentFiles/SqlTimestampOffset.d.ts +26 -0
- package/dist/types/utils/sql-expr-monaco/DependentFiles/TimeOnly.d.ts +37 -0
- package/dist/types/utils/sql-expr-monaco/DependentFiles/UnknownTimeZone.d.ts +11 -0
- package/dist/types/utils/sql-expr-monaco/DependentFiles/WhereGrammar.d.ts +122 -0
- package/dist/types/utils/sql-expr-monaco/DependentFiles/sqlCompareUtils.d.ts +5 -0
- package/dist/types/utils/sql-expr-monaco/DependentFiles/sqlDateParsingUtils.d.ts +18 -0
- package/dist/types/utils/sql-expr-monaco/DependentFiles/sqlUtils.d.ts +6 -0
- package/dist/types/utils/sql-expr-monaco/DependentFiles/standardizedFunctions.d.ts +156 -0
- package/dist/types/utils/sql-expr-monaco/DependentFiles/support.d.ts +150 -0
- package/dist/types/utils/sql-expr-monaco/PeggyGrammar/sql92grammar.d.ts +1397 -0
- package/dist/types/utils/sql-expr-monaco/libraries/date/properties/index.d.ts +59 -0
- package/dist/types/utils/sql-expr-monaco/libraries/numeric/properties/index.d.ts +295 -0
- package/dist/types/utils/sql-expr-monaco/libraries/string/properties/index.d.ts +135 -0
- package/dist/types/utils/sql-expr-monaco/sql-expr-completion.d.ts +5 -0
- package/dist/types/utils/sql-expr-monaco/sql-expr-contribution.d.ts +11 -0
- package/dist/types/utils/sql-expr-monaco/sql-expr-defaults.d.ts +22 -0
- package/dist/types/utils/sql-expr-monaco/sql-expr-language-features.d.ts +540 -0
- package/dist/types/utils/sql-expr-monaco/sql-expr-language-syntax.d.ts +8 -0
- package/dist/types/utils/sql-expr-monaco/sql-expr-mode.d.ts +10 -0
- package/dist/types/utils/sql-expr-monaco/sql-expr-validation-adapter.d.ts +3 -0
- package/dist/types/utils/sql-expr-monaco/sql-expr-validation-diagnostic-adapter.d.ts +41 -0
- package/dist/types/utils/sql-expr-monaco/sql-expr-validation-utils.d.ts +99 -0
- package/dist/types/utils/sql-expr-monaco/sql-expr-validation.d.ts +41 -0
- package/dist/types/utils/sql-expr-monaco/sql-expr-worker-manager.d.ts +15 -0
- package/dist/types/utils/sql-expr-monaco/sql-expr.worker.d.ts +21 -0
- package/dist/types/utils/sql-expr-monaco/types.d.ts +91 -0
- package/dist/types/utils/sql-expr-profile/predefined-profile.d.ts +2 -0
- package/package.json +25 -20
- package/dist/arcgis-coding-components/p-81c37dab.entry.js +0 -6
- package/dist/components/chunk-IHYYRFLQ.js +0 -1363
- package/dist/types/components/arcade-editor/t9n-types.d.ts +0 -8
- package/dist/types/components/arcade-results/t9n-types.d.ts +0 -13
- package/dist/types/components/arcade-suggestions/t9n-types.d.ts +0 -6
- package/dist/types/components/arcade-variables/t9n-types.d.ts +0 -8
- package/dist/types/components/language-api-panel/t9n-types.d.ts +0 -8
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://js.arcgis.com/4.31/esri/copyright.txt for details.
|
|
4
|
-
* v4.31.0-next.
|
|
4
|
+
* v4.31.0-next.4
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
8
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
9
9
|
|
|
10
|
-
const index = require('./index-
|
|
11
|
-
const appGlobals = require('./app-globals-
|
|
10
|
+
const index = require('./index-8b891c40.js');
|
|
11
|
+
const appGlobals = require('./app-globals-209c2310.js');
|
|
12
12
|
|
|
13
13
|
/*
|
|
14
14
|
Stencil Client Patch Browser v4.17.1 | MIT Licensed | https://stenciljs.com
|
|
@@ -24,7 +24,7 @@ var patchBrowser = () => {
|
|
|
24
24
|
|
|
25
25
|
patchBrowser().then(async (options) => {
|
|
26
26
|
await appGlobals.globalScripts();
|
|
27
|
-
return index.bootstrapLazy([["arcgis-arcade-editor_6.cjs",[[0,"arcgis-arcade-editor",{"profile":[16],"script":[1025],"testData":[16],"suggestions":[16],"snippets":[16],"hideDocumentationActions":[4,"hide-documentation-actions"],"hideSideBar":[4,"hide-side-bar"],"sideActionBarExpanded":[1540,"side-action-bar-expanded"],"openedSidePanel":[1537,"opened-side-panel"],"editorOptions":[16],"editorInstance":[16],"
|
|
27
|
+
return index.bootstrapLazy([["arcgis-sql-expression-fields.cjs",[[1,"arcgis-sql-expression-fields",{"loading":[4],"modelId":[1,"model-id"],"_mutationCounter":[32],"_flowItemRenderers":[32],"_filterValue":[32]},null,{"modelId":["modelIdPropChanged"]}]]],["arcgis-arcade-editor_6.cjs",[[0,"arcgis-arcade-editor",{"profile":[16],"script":[1025],"testData":[16],"suggestions":[16],"snippets":[16],"hideDocumentationActions":[4,"hide-documentation-actions"],"hideSideBar":[4,"hide-side-bar"],"sideActionBarExpanded":[1540,"side-action-bar-expanded"],"openedSidePanel":[1537,"opened-side-panel"],"editorOptions":[16],"editorInstance":[16],"_preparingArcade":[32],"_editorProfile":[32],"_apiLibrary":[32],"_showExecutionPanel":[32],"_resultPanel":[32],"_executingScript":[32],"_consoleLogs":[32],"_executionResult":[32],"messages":[32],"getScript":[64],"setFocus":[64],"getEditorInstance":[64],"getTestResult":[64],"updateThemeColors":[64]},null,{"messages":["_messagesChanged"],"profile":["_profileChanged"],"testData":["_testDataChanged"],"snippets":["_snippetChanged"]}],[1,"arcgis-arcade-results",{"loading":[4],"openedResultPanel":[1537,"opened-result-panel"],"result":[16],"consoleLogs":[16]}],[1,"arcgis-arcade-suggestions",{"suggestions":[16],"_selectedSuggestion":[32],"_filterValue":[32],"_colorizeStyle":[32]},null,{"suggestions":["suggestionsPropChanged"]}],[1,"arcgis-arcade-variables",{"loading":[4],"modelId":[1,"model-id"],"_mutationCounter":[32],"_flowItemRenderers":[32],"_filterValue":[32]},null,{"modelId":["modelIdPropChanged"]}],[0,"arcgis-code-editor",{"value":[1],"language":[1],"modelId":[1,"model-id"],"options":[16],"editorInstance":[16],"getValue":[64],"setValue":[64],"insertText":[64],"insertSnippet":[64],"getEditorInstance":[64],"setFocus":[64]},null,{"language":["languagePropChange"],"modelId":["modelIdPropChange"],"options":["optionsPropChange"]}],[1,"arcgis-language-api-panel",{"hideDocumentationActions":[4,"hide-documentation-actions"],"loading":[4],"apiLibrary":[16],"_selectedApiItem":[32],"_filterValue":[32],"_colorizeStyle":[32]}]]],["arcgis-sql-expression-editor.cjs",[[0,"arcgis-sql-expression-editor",{"profile":[16],"_preparing":[32],"_editorProfile":[32],"_activeAction":[32],"_apiLibrary":[32]},null,{"profile":["_profileChanged"]}]]]], options);
|
|
28
28
|
});
|
|
29
29
|
|
|
30
30
|
exports.setNonce = index.setNonce;
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
|
+
* See https://js.arcgis.com/4.31/esri/copyright.txt for details.
|
|
4
|
+
* v4.31.0-next.4
|
|
5
|
+
*/
|
|
6
|
+
'use strict';
|
|
7
|
+
|
|
8
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
9
|
+
|
|
10
|
+
const index = require('./index-8b891c40.js');
|
|
11
|
+
const sqlExprDefaults = require('./sql-expr-defaults-783d9c24.js');
|
|
12
|
+
const languageDefaultsBase = require('./language-defaults-base-4300e691.js');
|
|
13
|
+
|
|
14
|
+
const sqlExpressionEditorCss = "arcgis-sql-expression-editor{display:flex;flex-direction:column;position:relative;overflow:hidden;border:1px solid var(--calcite-color-border-3);box-sizing:border-box;background-color:var(--calcite-color-foreground-1);height:100%}arcgis-sql-expression-editor .flex-adjustable{flex:1 1 auto;overflow:hidden}arcgis-sql-expression-editor .flex-panel{flex:1 0 auto}arcgis-sql-expression-editor .position-relative{position:relative}arcgis-sql-expression-editor .flex-row{display:flex;flex-direction:row;overflow:hidden}arcgis-sql-expression-editor .flex-column{display:flex;flex-direction:column;overflow:hidden}arcgis-sql-expression-editor .border-inline-start{border-inline-start:1px solid var(--calcite-color-border-3);box-sizing:border-box}arcgis-sql-expression-editor .border-inline-end{border-inline-end:1px solid var(--calcite-color-border-3);box-sizing:border-box}arcgis-sql-expression-editor .side-action-bar{max-width:25%}arcgis-sql-expression-editor .side-panel{max-width:45%;width:600px}arcgis-sql-expression-editor .side-panel calcite-flow{height:100%}";
|
|
15
|
+
const ArcgisSqlExpressionEditorStyle0 = sqlExpressionEditorCss;
|
|
16
|
+
|
|
17
|
+
const SqlExpressionEditor = class {
|
|
18
|
+
constructor(hostRef) {
|
|
19
|
+
index.registerInstance(this, hostRef);
|
|
20
|
+
this.manager = sqlExprDefaults.useControllerManager(this);
|
|
21
|
+
// #endregion
|
|
22
|
+
// #region Private properties
|
|
23
|
+
this._modelId = languageDefaultsBase.generateGuid();
|
|
24
|
+
this._insertAsSnippet = (e) => void this._codeEditorElt?.insertSnippet(e.detail).catch(console.error);
|
|
25
|
+
this._preparing = false;
|
|
26
|
+
this._editorProfile = undefined;
|
|
27
|
+
this._activeAction = undefined;
|
|
28
|
+
this._apiLibrary = undefined;
|
|
29
|
+
this.profile = undefined;
|
|
30
|
+
}
|
|
31
|
+
_profileChanged() {
|
|
32
|
+
this._updateSqlExprDefaults().catch(console.error);
|
|
33
|
+
}
|
|
34
|
+
// #endregion
|
|
35
|
+
// #region Private methods API
|
|
36
|
+
async _updateSqlExprDefaults() {
|
|
37
|
+
this._preparing = true;
|
|
38
|
+
try {
|
|
39
|
+
await sqlExprDefaults.sqlExprDefaults.setProfileForModel(this._modelId, this.profile);
|
|
40
|
+
this._apiLibrary = await sqlExprDefaults.sqlExprDefaults.getApiLibrary(this._modelId);
|
|
41
|
+
}
|
|
42
|
+
catch {
|
|
43
|
+
this._editorProfile = undefined;
|
|
44
|
+
}
|
|
45
|
+
finally {
|
|
46
|
+
// this._editorProfilePromise = Promise.resolve(this._editorProfile);
|
|
47
|
+
this._preparing = false;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
_setActiveAction(action) {
|
|
51
|
+
this._activeAction = action;
|
|
52
|
+
}
|
|
53
|
+
_handleActionClick(e) {
|
|
54
|
+
const action = e.target;
|
|
55
|
+
this._setActiveAction(action.dataset.panelName);
|
|
56
|
+
}
|
|
57
|
+
// #endregion
|
|
58
|
+
// #region Component lifecycle events
|
|
59
|
+
async componentWillLoad() {
|
|
60
|
+
await this._updateSqlExprDefaults().catch(console.error);
|
|
61
|
+
// The profile has to be refreshed on locale change
|
|
62
|
+
// this.manager.watch("messages", () => void this._updateEditorProfile().catch(console.error));
|
|
63
|
+
}
|
|
64
|
+
disconnectedCallback() {
|
|
65
|
+
sqlExprDefaults.sqlExprDefaults.disposeForModel(this._modelId);
|
|
66
|
+
}
|
|
67
|
+
// #endregion
|
|
68
|
+
render() {
|
|
69
|
+
return (index.h(index.Host, { key: '67f7ebf7a28a8ffc3fe967721389d45c4e2003a1' }, index.h("div", { key: 'b3bf4ec2a8d04105e97489593ccec95cd33237f0', class: "flex-row flex-adjustable" }, index.h("div", { key: 'fdac47e22baf64c72f786f9e09b637050f417f94', class: "flex-column flex-adjustable" }, index.h("arcgis-code-editor", { key: 'f4151dd39ec3523907cd907ebb7558e05bca9cc1', language: "arcgis-sql-expression", modelId: this._modelId, ref: (e) => (this._codeEditorElt = e) })), this._activeAction === "fields" && (index.h("arcgis-sql-expression-fields", { key: 'aa0e5d88429d4bf865b9adc506028efefec1a73a', class: "side-panel flex-panel border-inline-start", loading: this._preparing, modelId: this._modelId, "data-panel-name": "none", onArcgisFieldSelected: this._insertAsSnippet, onArcgisClose: () => this._setActiveAction(undefined) })), this._activeAction === "functions" && (index.h("arcgis-language-api-panel", { key: '7826dbb1b08894c6c6385806a3aef6cff77395d0', class: "side-panel flex-panel border-inline-start", onArcgisItemSelected: this._insertAsSnippet, onArcgisClose: () => this._setActiveAction(undefined), loading: this._preparing, apiLibrary: this._apiLibrary, "data-panel-name": "none" })), index.h("calcite-action-bar", { key: 'ee618d666b70405495627a9d15238e8723c6f961', class: "side-action-bar border-inline-start", expanded: false, position: "end" }, index.h("calcite-action", { key: '2c828df5dded6347e13e59ba9e313824baa606ff', id: "fields-action", text: "Fields", icon: "profile-variables", active: this._activeAction === "fields", "data-panel-name": "fields",
|
|
70
|
+
// need to use an arrow function to automatically bind 'this'
|
|
71
|
+
onClick: (e) => this._handleActionClick(e) }), index.h("calcite-action", { key: 'eab785c5b14cadeb5047db1957134f5accfedc76', id: "functions-action", text: "Functions", icon: "function", active: this._activeAction === "functions", "data-panel-name": "functions", onClick: (e) => this._handleActionClick(e) })))));
|
|
72
|
+
}
|
|
73
|
+
static get assetsDirs() { return ["assets"]; }
|
|
74
|
+
get el() { return index.getElement(this); }
|
|
75
|
+
static get watchers() { return {
|
|
76
|
+
"profile": ["_profileChanged"]
|
|
77
|
+
}; }
|
|
78
|
+
};
|
|
79
|
+
SqlExpressionEditor.style = ArcgisSqlExpressionEditorStyle0;
|
|
80
|
+
|
|
81
|
+
exports.arcgis_sql_expression_editor = SqlExpressionEditor;
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
|
+
* See https://js.arcgis.com/4.31/esri/copyright.txt for details.
|
|
4
|
+
* v4.31.0-next.4
|
|
5
|
+
*/
|
|
6
|
+
'use strict';
|
|
7
|
+
|
|
8
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
9
|
+
|
|
10
|
+
const index = require('./index-8b891c40.js');
|
|
11
|
+
const sqlExprDefaults = require('./sql-expr-defaults-783d9c24.js');
|
|
12
|
+
require('./language-defaults-base-4300e691.js');
|
|
13
|
+
|
|
14
|
+
const sqlExpressionFieldsCss = ":host calcite-flow{height:100%}:host calcite-list-item-group{background-color:var(--calcite-color-foreground-2)}";
|
|
15
|
+
const ArcgisSqlExpressionFieldsStyle0 = sqlExpressionFieldsCss;
|
|
16
|
+
|
|
17
|
+
const SqlExpressionFields = class {
|
|
18
|
+
constructor(hostRef) {
|
|
19
|
+
index.registerInstance(this, hostRef);
|
|
20
|
+
this.arcgisClose = index.createEvent(this, "arcgisClose", 3);
|
|
21
|
+
this.arcgisFieldSelected = index.createEvent(this, "arcgisFieldSelected", 3);
|
|
22
|
+
this.manager = sqlExprDefaults.useControllerManager(this);
|
|
23
|
+
// #endregion
|
|
24
|
+
// #region Private Methods
|
|
25
|
+
this._handleSelectField = (event) => {
|
|
26
|
+
if (event.target instanceof HTMLElement) {
|
|
27
|
+
const tagName = event.target.tagName;
|
|
28
|
+
switch (tagName.toLowerCase()) {
|
|
29
|
+
case "calcite-list-item":
|
|
30
|
+
// TODO: why is value missing from HTMLCalciteListElement type?
|
|
31
|
+
this.arcgisFieldSelected.emit(event.target.value ?? "");
|
|
32
|
+
break;
|
|
33
|
+
case "calcite-action":
|
|
34
|
+
event.stopPropagation();
|
|
35
|
+
break;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
this._emitClose = () => {
|
|
40
|
+
this.arcgisClose.emit();
|
|
41
|
+
};
|
|
42
|
+
this._mutationCounter = 1;
|
|
43
|
+
this._flowItemRenderers = [];
|
|
44
|
+
this._filterValue = "";
|
|
45
|
+
this.loading = false;
|
|
46
|
+
this.modelId = undefined;
|
|
47
|
+
}
|
|
48
|
+
modelIdPropChanged() {
|
|
49
|
+
this._flowItemRenderers = [];
|
|
50
|
+
}
|
|
51
|
+
// #endregion
|
|
52
|
+
// #region Lifecycle
|
|
53
|
+
disconnectedCallback() {
|
|
54
|
+
this._flowObserver?.disconnect();
|
|
55
|
+
}
|
|
56
|
+
// #endregion
|
|
57
|
+
render() {
|
|
58
|
+
const layer = sqlExprDefaults.sqlExprDefaults.getFeatureLayerForModel(this.modelId ?? "");
|
|
59
|
+
if (this.loading || !this.modelId || !layer) {
|
|
60
|
+
return index.h("calcite-block", { heading: "Available Fields" });
|
|
61
|
+
}
|
|
62
|
+
return (index.h("calcite-flow", null, index.h("calcite-flow-item", { heading: "Available Fields", closable: true, description: "Select a field to insert into the expression", onCalciteFlowItemClose: this._emitClose }, index.h("calcite-list", { filterEnabled: true }, layer.fields.map((field) => (index.h("calcite-list-item", { key: field.name, onClick: this._handleSelectField, label: field.name, description: field.alias, value: field.name }, field.domain && (index.h("calcite-action", { slot: "actions-end", text: "open", icon: "chevron-right", onClick: () => {
|
|
63
|
+
const domain = field.domain;
|
|
64
|
+
if (domain.type === "coded-value") {
|
|
65
|
+
this._flowItemRenderers = [
|
|
66
|
+
...this._flowItemRenderers,
|
|
67
|
+
() => (index.h("calcite-flow-item", { closable: true, heading: "Domains", description: field.name, onCalciteFlowItemClose: this._emitClose }, index.h("calcite-list", null, domain.codedValues.map((value) => (index.h("calcite-list-item", { key: value.code, onClick: this._handleSelectField, label: value.name, description: String(value.code), value: value.code })))))),
|
|
68
|
+
];
|
|
69
|
+
}
|
|
70
|
+
} }))))))), this._flowItemRenderers.map((renderer) => renderer())));
|
|
71
|
+
}
|
|
72
|
+
static get assetsDirs() { return ["assets"]; }
|
|
73
|
+
get el() { return index.getElement(this); }
|
|
74
|
+
static get watchers() { return {
|
|
75
|
+
"modelId": ["modelIdPropChanged"]
|
|
76
|
+
}; }
|
|
77
|
+
};
|
|
78
|
+
SqlExpressionFields.style = ArcgisSqlExpressionFieldsStyle0;
|
|
79
|
+
|
|
80
|
+
exports.arcgis_sql_expression_fields = SqlExpressionFields;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://js.arcgis.com/4.31/esri/copyright.txt for details.
|
|
4
|
-
* v4.31.0-next.
|
|
4
|
+
* v4.31.0-next.4
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const
|
|
9
|
-
require('./index-
|
|
8
|
+
const languageDefaultsBase = require('./language-defaults-base-4300e691.js');
|
|
9
|
+
require('./index-8b891c40.js');
|
|
10
10
|
|
|
11
11
|
/*!-----------------------------------------------------------------------------
|
|
12
12
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
@@ -31,7 +31,7 @@ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "defau
|
|
|
31
31
|
|
|
32
32
|
// src/fillers/monaco-editor-core.ts
|
|
33
33
|
var monaco_editor_core_exports = {};
|
|
34
|
-
__reExport(monaco_editor_core_exports,
|
|
34
|
+
__reExport(monaco_editor_core_exports, languageDefaultsBase.monaco_editor_core_star);
|
|
35
35
|
|
|
36
36
|
// src/language/css/workerManager.ts
|
|
37
37
|
var STOP_WHEN_IDLE_FOR = 2 * 60 * 1e3;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://js.arcgis.com/4.31/esri/copyright.txt for details.
|
|
4
|
-
* v4.31.0-next.
|
|
4
|
+
* v4.31.0-next.4
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const
|
|
9
|
-
require('./index-
|
|
8
|
+
const languageDefaultsBase = require('./language-defaults-base-4300e691.js');
|
|
9
|
+
require('./index-8b891c40.js');
|
|
10
10
|
|
|
11
11
|
/*!-----------------------------------------------------------------------------
|
|
12
12
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
@@ -31,7 +31,7 @@ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "defau
|
|
|
31
31
|
|
|
32
32
|
// src/fillers/monaco-editor-core.ts
|
|
33
33
|
var monaco_editor_core_exports = {};
|
|
34
|
-
__reExport(monaco_editor_core_exports,
|
|
34
|
+
__reExport(monaco_editor_core_exports, languageDefaultsBase.monaco_editor_core_star);
|
|
35
35
|
|
|
36
36
|
// src/basic-languages/html/html.ts
|
|
37
37
|
var EMPTY_ELEMENTS = [
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://js.arcgis.com/4.31/esri/copyright.txt for details.
|
|
4
|
-
* v4.31.0-next.
|
|
4
|
+
* v4.31.0-next.4
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const
|
|
9
|
-
require('./index-
|
|
8
|
+
const languageDefaultsBase = require('./language-defaults-base-4300e691.js');
|
|
9
|
+
require('./index-8b891c40.js');
|
|
10
10
|
|
|
11
11
|
/*!-----------------------------------------------------------------------------
|
|
12
12
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
@@ -31,7 +31,7 @@ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "defau
|
|
|
31
31
|
|
|
32
32
|
// src/fillers/monaco-editor-core.ts
|
|
33
33
|
var monaco_editor_core_exports = {};
|
|
34
|
-
__reExport(monaco_editor_core_exports,
|
|
34
|
+
__reExport(monaco_editor_core_exports, languageDefaultsBase.monaco_editor_core_star);
|
|
35
35
|
|
|
36
36
|
// src/language/html/workerManager.ts
|
|
37
37
|
var STOP_WHEN_IDLE_FOR = 2 * 60 * 1e3;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://js.arcgis.com/4.31/esri/copyright.txt for details.
|
|
4
|
-
* v4.31.0-next.
|
|
4
|
+
* v4.31.0-next.4
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
@@ -1217,6 +1217,14 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
|
|
|
1217
1217
|
return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require(
|
|
1218
1218
|
/* webpackMode: "lazy" */
|
|
1219
1219
|
'./arcgis-arcade-editor_6.cjs.entry.js')); }).then(processMod, consoleError);
|
|
1220
|
+
case 'arcgis-sql-expression-editor.cjs':
|
|
1221
|
+
return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require(
|
|
1222
|
+
/* webpackMode: "lazy" */
|
|
1223
|
+
'./arcgis-sql-expression-editor.cjs.entry.js')); }).then(processMod, consoleError);
|
|
1224
|
+
case 'arcgis-sql-expression-fields.cjs':
|
|
1225
|
+
return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require(
|
|
1226
|
+
/* webpackMode: "lazy" */
|
|
1227
|
+
'./arcgis-sql-expression-fields.cjs.entry.js')); }).then(processMod, consoleError);
|
|
1220
1228
|
}
|
|
1221
1229
|
}
|
|
1222
1230
|
return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require(
|
package/dist/cjs/index.cjs.js
CHANGED
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://js.arcgis.com/4.31/esri/copyright.txt for details.
|
|
4
|
-
* v4.31.0-next.
|
|
4
|
+
* v4.31.0-next.4
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
8
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
9
9
|
|
|
10
|
-
const arcadeDefaults = require('./arcade-defaults-
|
|
11
|
-
require('./
|
|
10
|
+
const arcadeDefaults = require('./arcade-defaults-ee308e3a.js');
|
|
11
|
+
require('./language-defaults-base-4300e691.js');
|
|
12
|
+
require('./index-8b891c40.js');
|
|
12
13
|
|
|
13
14
|
|
|
14
15
|
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://js.arcgis.com/4.31/esri/copyright.txt for details.
|
|
4
|
-
* v4.31.0-next.
|
|
4
|
+
* v4.31.0-next.4
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const typescript = require('./typescript-
|
|
9
|
-
require('./
|
|
10
|
-
require('./index-
|
|
8
|
+
const typescript = require('./typescript-f6ca5d84.js');
|
|
9
|
+
require('./language-defaults-base-4300e691.js');
|
|
10
|
+
require('./index-8b891c40.js');
|
|
11
11
|
|
|
12
12
|
/*!-----------------------------------------------------------------------------
|
|
13
13
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://js.arcgis.com/4.31/esri/copyright.txt for details.
|
|
4
|
-
* v4.31.0-next.
|
|
4
|
+
* v4.31.0-next.4
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const
|
|
9
|
-
require('./index-
|
|
8
|
+
const languageDefaultsBase = require('./language-defaults-base-4300e691.js');
|
|
9
|
+
require('./index-8b891c40.js');
|
|
10
10
|
|
|
11
11
|
/*!-----------------------------------------------------------------------------
|
|
12
12
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
@@ -31,7 +31,7 @@ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "defau
|
|
|
31
31
|
|
|
32
32
|
// src/fillers/monaco-editor-core.ts
|
|
33
33
|
var monaco_editor_core_exports = {};
|
|
34
|
-
__reExport(monaco_editor_core_exports,
|
|
34
|
+
__reExport(monaco_editor_core_exports, languageDefaultsBase.monaco_editor_core_star);
|
|
35
35
|
|
|
36
36
|
// src/language/json/workerManager.ts
|
|
37
37
|
var STOP_WHEN_IDLE_FOR = 2 * 60 * 1e3;
|