@arcgis/coding-components 4.31.0-next.90 → 4.31.0-next.92
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/sql-expr.worker.js +38 -38
- package/dist/arcgis-coding-components/index.esm.js +2 -2
- package/dist/arcgis-coding-components/{p-a5293265.js → p-15c50740.js} +3 -3
- package/dist/arcgis-coding-components/{p-e4fc8c3b.js → p-1b973f94.js} +2 -2
- package/dist/arcgis-coding-components/{p-4d64ee3a.js → p-24d29d6d.js} +2 -2
- package/dist/arcgis-coding-components/{p-34373603.js → p-34ed6566.js} +2 -2
- package/dist/arcgis-coding-components/{p-dc7b82be.js → p-3d44583f.js} +2 -2
- package/dist/arcgis-coding-components/{p-6c584f5b.js → p-471617cb.js} +1 -1
- package/dist/arcgis-coding-components/p-56e91f98.entry.js +6 -0
- package/dist/arcgis-coding-components/{p-3a1449ed.js → p-7d49eb93.js} +1 -1
- package/dist/arcgis-coding-components/{p-bfd84405.js → p-7dc30f97.js} +2 -2
- package/dist/arcgis-coding-components/{p-9e9659f9.js → p-85d5cb7e.js} +1 -1
- package/dist/arcgis-coding-components/{p-19c5a618.entry.js → p-947c71eb.entry.js} +2 -2
- package/dist/arcgis-coding-components/{p-c1e3a7d0.js → p-a2ad6313.js} +2 -2
- package/dist/arcgis-coding-components/{p-889368cf.js → p-a7d37ee7.js} +2 -2
- package/dist/arcgis-coding-components/{p-608c32ba.entry.js → p-a7f4a70e.entry.js} +2 -2
- package/dist/arcgis-coding-components/{p-2e583d2b.js → p-b3db07c0.js} +2 -2
- package/dist/arcgis-coding-components/{p-9a202c0a.js → p-c4757cc3.js} +10 -10
- package/dist/arcgis-coding-components/{p-1f4e58d8.js → p-d396ff86.js} +2 -2
- package/dist/arcgis-coding-components/{p-2fa5555f.js → p-fd76fcdf.js} +2 -2
- package/dist/cjs/{app-globals-9cb3e755.js → app-globals-ea3d8f2a.js} +1 -1
- package/dist/cjs/{arcade-defaults-f3ce9d99.js → arcade-defaults-9cb56c22.js} +3 -3
- package/dist/cjs/{arcade-mode-46f00800.js → arcade-mode-1f84ac48.js} +3 -3
- package/dist/cjs/arcgis-arcade-editor_6.cjs.entry.js +46 -22
- package/dist/cjs/arcgis-coding-components.cjs.js +3 -3
- package/dist/cjs/arcgis-sql-expression-editor.cjs.entry.js +4 -4
- package/dist/cjs/arcgis-sql-expression-fields.cjs.entry.js +4 -4
- package/dist/cjs/{css-5124cbb6.js → css-ec306a7b.js} +1 -1
- package/dist/cjs/{cssMode-3a5705b5.js → cssMode-3e849128.js} +3 -3
- package/dist/cjs/{html-2c7d029e.js → html-7d797680.js} +3 -3
- package/dist/cjs/{htmlMode-45b992ac.js → htmlMode-7a5dd0a9.js} +3 -3
- package/dist/cjs/{index-e594c589.js → index-9c03f952.js} +1 -1
- package/dist/cjs/index.cjs.js +4 -4
- package/dist/cjs/{javascript-d0667153.js → javascript-3e07a288.js} +4 -4
- package/dist/cjs/{jsonMode-48c96561.js → jsonMode-da60682c.js} +3 -3
- package/dist/cjs/loader.cjs.js +3 -3
- package/dist/cjs/{sql-expr-defaults-b530b9d1.js → sql-expr-defaults-b961f377.js} +10 -10
- package/dist/cjs/{sql-expr-mode-ad9e75dc.js → sql-expr-mode-849b8ca0.js} +3 -3
- package/dist/cjs/{tsMode-b9f5edcc.js → tsMode-5ba938c7.js} +3 -3
- package/dist/cjs/{typescript-f9e73a88.js → typescript-2c5105b6.js} +3 -3
- package/dist/cjs/{useT9n-fbae98b6.js → useT9n-0188a2cb.js} +3 -3
- package/dist/components/arcade-defaults.js +1 -1
- package/dist/components/arcade-mode.js +1 -1
- package/dist/components/arcade-results.js +1 -1
- package/dist/components/arcade-suggestions.js +1 -1
- package/dist/components/arcgis-arcade-editor.js +40 -16
- package/dist/components/arcgis-arcade-results.js +1 -1
- package/dist/components/arcgis-arcade-suggestions.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-editor-variables.js +1 -1
- package/dist/components/arcgis-language-api-panel.js +1 -1
- package/dist/components/arcgis-sql-expression-editor.js +1 -1
- package/dist/components/arcgis-sql-expression-fields.js +1 -1
- package/dist/components/chunk-IUUKU7EW.js +1 -1
- package/dist/components/code-editor.js +1 -1
- package/dist/components/editor-variables.js +1 -1
- package/dist/components/fields.js +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/index2.js +1 -1
- package/dist/components/language-api-panel.js +1 -1
- package/dist/components/markdown.js +1 -1
- package/dist/components/sql-expr-defaults.js +1 -1
- package/dist/components/sql-expr-mode.js +1 -1
- package/dist/components/useT9n.js +1 -1
- package/dist/components/utilities.js +1 -1
- package/dist/esm/{app-globals-fe84b217.js → app-globals-0f12920a.js} +1 -1
- package/dist/esm/{arcade-defaults-27766d79.js → arcade-defaults-f2ec0d1a.js} +3 -3
- package/dist/esm/{arcade-mode-f1b8a6b5.js → arcade-mode-0ea806ff.js} +3 -3
- package/dist/esm/arcgis-arcade-editor_6.entry.js +46 -22
- package/dist/esm/arcgis-coding-components.js +4 -4
- package/dist/esm/arcgis-sql-expression-editor.entry.js +4 -4
- package/dist/esm/arcgis-sql-expression-fields.entry.js +4 -4
- package/dist/esm/{css-db025e79.js → css-fb67725a.js} +1 -1
- package/dist/esm/{cssMode-23f7acab.js → cssMode-9e883742.js} +3 -3
- package/dist/esm/{html-3925dd99.js → html-c303cdfd.js} +3 -3
- package/dist/esm/{htmlMode-dac73a67.js → htmlMode-31bec7d5.js} +3 -3
- package/dist/esm/{index-c844a568.js → index-bbfcd75f.js} +1 -1
- package/dist/esm/index.js +4 -4
- package/dist/esm/{javascript-ecd9171b.js → javascript-c6bdcb57.js} +4 -4
- package/dist/esm/{jsonMode-8d1fcc86.js → jsonMode-b97f3470.js} +3 -3
- package/dist/esm/loader.js +4 -4
- package/dist/esm/{sql-expr-defaults-e43594c1.js → sql-expr-defaults-70865c10.js} +10 -10
- package/dist/esm/{sql-expr-mode-9e529b68.js → sql-expr-mode-95f78170.js} +3 -3
- package/dist/esm/{tsMode-c4741f53.js → tsMode-a4929bb6.js} +3 -3
- package/dist/esm/{typescript-35fd56f5.js → typescript-830e9670.js} +3 -3
- package/dist/esm/{useT9n-2c5c6550.js → useT9n-190fb620.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 +3 -0
- package/package.json +11 -11
- package/dist/arcgis-coding-components/p-4af1d698.entry.js +0 -6
|
@@ -1,9 +1,9 @@
|
|
|
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.92
|
|
5
5
|
*/
|
|
6
|
-
import{O as t}from"./p-
|
|
6
|
+
import{O as t}from"./p-c4757cc3.js";import"./p-7d49eb93.js";
|
|
7
7
|
/*!-----------------------------------------------------------------------------
|
|
8
8
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
9
9
|
* Version: 0.45.0(5e5af013f8d295555a7210df0d5f2cea0bf5dd56)
|
|
@@ -1,6 +1,6 @@
|
|
|
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.92
|
|
5
5
|
*/
|
|
6
|
-
import{m as e,r as t,Q as s,R as r,w as n,T as i,D as a,V as o}from"./p-9a202c0a.js";import"./p-3a1449ed.js";var c=[[],[],[]];["++","--"].forEach((e=>c[e.length-1]?.push(e))),["-","+","!","~"].forEach((e=>c[e.length-1]?.push(e))),["||","&&"].forEach((e=>c[e.length-1]?.push(e))),["=","/=","*=","%=","+=","-="].forEach((e=>c[e.length-1]?.push(e))),["|","&",">>","<<",">>>","^","==","!=","<","<=",">",">=","+","-","*","/","%"].forEach((e=>c[e.length-1]?.push(e)));var u=Object.values({Break:"break",Continue:"continue",Else:"else",For:"for",From:"from",Function:"function",If:"if",Import:"import",Export:"export",In:"in",Return:"return",Var:"var",While:"while"});Object.values({False:"false",Null:"null",True:"true"}).map((t=>({label:t,kind:e.exports.CompletionItemKind.Constant}))),u.map((t=>({label:t,kind:e.exports.CompletionItemKind.Keyword})));const l={wordPattern:/(-?\d*\.\d\w*)|([^`~!#%\^&\*\(\)\-=\+\[\{\]\}\\\|;:'",\.<>\/\?\s]+)/gu,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]},{open:"`",close:"`",notIn:["string","comment"]}],autoCloseBefore:";:.,=}])` \n\t",folding:{markers:{start:/^\s*\/\/\s*#?region\b/u,end:/^\s*\/\/\s*#?endregion\b/u}},indentationRules:{decreaseIndentPattern:/^((?!.*?\/\*).*\*\/)?\s*[\}\]\)].*$/u,increaseIndentPattern:/^((?!\/\/).)*(\{[^}"'`]*|\([^)"'`]*|\[[^\]"'`]*)$/u}},g={defaultToken:"invalid",tokenPostfix:".arcgis",ignoreCase:!0,keywords:u.filter((e=>"from"!==e)),operators:["<=",">=","==","!=","+","-","*","/","%","++","--","<<",">>",">>>","&","|","^","!","~","&&","||","=","+=","-=","*=","**=","/=","%="],constants:["true","false","null"],symbols:/[=><!~?:&|+\-*\/\^%]+/u,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/u,digits:/\d+(_+\d+)*/u,octaldigits:/[0-7]+(_+[0-7]+)*/u,binarydigits:/[0-1]+(_+[0-1]+)*/u,hexdigits:/[[0-9a-fA-F]+(_+[0-9a-fA-F]+)*/u,regexpctl:/[(){}\[\]\$\^|\-*+?\.]/u,regexpesc:/\\(?:[bBdDfnrstvwWn0\\\/]|@regexpctl|c[A-Z]|x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4})/u,tokenizer:{root:[[/[{}]/u,"delimiter.bracket"],{include:"common"}],common:[[/import(?=\s)/u,{token:"keyword",next:"@import"}],[/[a-z_$][\w$]*/u,{cases:{"@constants":"constant","@keywords":"keyword","@default":"identifier"}}],{include:"@whitespace"},[/\/(?=([^\\\/]|\\.)+\/([gimsuy]*)(\s*)(\.|;|\/|,|\)|\]|\}|$))/u,{token:"regexp",bracket:"@open",next:"@regexp"}],[/[()\[\]]/u,"@brackets"],[/[<>](?!@symbols)/u,"@brackets"],[/@symbols/u,{cases:{"@operators":"delimiter","@default":""}}],[/(@digits)[eE]([\-+]?(@digits))?/u,"number"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?/u,"number"],[/0[xX](@hexdigits)/u,"number"],[/0[oO]?(@octaldigits)/u,"number"],[/0[bB](@binarydigits)/u,"number"],[/(@digits)/u,"number"],[/[;,.]/u,"delimiter"],[/"([^"\\]|\\.)*$/u,"string.invalid"],[/'([^'\\]|\\.)*$/u,"string.invalid"],[/"/u,"string","@string_double"],[/'/u,"string","@string_single"],[/`/u,"string","@string_backtick"]],import:[[/import(?=\s)/u,{token:"keyword"}],{include:"@whitespace"},[/[a-z_$][\w$]*/u,"identifier"],{include:"@whitespace"},[/from/u,{token:"keyword",next:"@popall"}]],whitespace:[[/[ \t\r\n]+/u,""],[/\/\*/u,"comment","@comment"],[/\/\/.*$/u,"comment"]],comment:[[/[^\/*]+/u,"comment"],[/\*\//u,"comment","@pop"],[/[\/*]/u,"comment"]],regexp:[[/(\{)(\d+(?:,\d*)?)(\})/u,["regexp.escape.control","regexp.escape.control","regexp.escape.control"]],[/(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/u,["regexp.escape.control",{token:"regexp.escape.control",next:"@regexrange"}]],[/(\()(\?:|\?=|\?!)/u,["regexp.escape.control","regexp.escape.control"]],[/[()]/u,"regexp.escape.control"],[/@regexpctl/u,"regexp.escape.control"],[/[^\\\/]/u,"regexp"],[/@regexpesc/u,"regexp.escape"],[/\\\./u,"regexp.invalid"],[/(\/)([gimsuy]*)/u,[{token:"regexp",bracket:"@close",next:"@pop"},"keyword.other"]]],regexrange:[[/-/u,"regexp.escape.control"],[/\^/u,"regexp.invalid"],[/@regexpesc/u,"regexp.escape"],[/[^\]]/u,"regexp"],[/\]/u,{token:"regexp.escape.control",next:"@pop",bracket:"@close"}]],string_double:[[/[^\\"]+/u,"string"],[/@escapes/u,"string.escape"],[/\\./u,"string.escape.invalid"],[/"/u,"string","@pop"]],string_single:[[/[^\\']+/u,"string"],[/@escapes/u,"string.escape"],[/\\./u,"string.escape.invalid"],[/'/u,"string","@pop"]],string_backtick:[[/\$\{/u,{token:"delimiter.bracket",next:"@bracketCounting"}],[/[^\\`$]+/u,"string"],[/@escapes/u,"string.escape"],[/\\./u,"string.escape.invalid"],[/`/u,"string","@pop"]],bracketCounting:[[/\{/u,"delimiter.bracket","@bracketCounting"],[/\}/u,"delimiter.bracket","@pop"],{include:"common"}]}};class p{constructor(e,s,{defaults:r,diagnosticsService:n}){this._languageId=e,this._worker=s,this._disposables=[],this._listener=new Map,this._diagnosticsService=n,this._defaults=r;const a=e=>{const t=e.getLanguageId();if(t!==this._languageId)return;const s=i((()=>{this._doValidate(e,t).catch((e=>{throw e}))}));this._listener.set(e.uri.toString(),e.onDidChangeContent(s)),this._doValidate(e,t).catch(console.error)},o=e=>{const s=e.uri.toString();t.setModelMarkers(e,this._languageId,[]);const r=this._listener.get(s);r&&(r.dispose(),this._listener.delete(s))};this._disposables.push(t.onDidCreateModel(a)),this._disposables.push(t.onWillDisposeModel((e=>{o(e)}))),this._disposables.push(t.onDidChangeModelLanguage((e=>{o(e.model),a(e.model)}))),this._disposables.push(r.onDidChange((()=>{t.getModels().forEach((e=>{e.getLanguageId()===this._languageId&&(o(e),a(e))}))}))),this._disposables.push(r.onModelContextDidChange((e=>{t.getModels().forEach((t=>{t.getLanguageId()===this._languageId&&t.uri.toString()===e&&this._doValidate(t,this._languageId).catch(console.error)}))}))),this._disposables.push({dispose:()=>{this._listener.forEach((e=>e.dispose())),this._listener.clear()}}),t.getModels().forEach(a)}dispose(){this._disposables.forEach((e=>e.dispose())),this._disposables=[]}async _doValidate(e,s){if(e.isAttachedToEditor())try{const r=await this._worker(e.uri),n=this._defaults.getApiContextForModel(e.uri),i=await r.doValidation(e.uri.toString(),n),a=i.map((e=>{return{severity:d((t=e).severity),startLineNumber:t.range.start.line+1,startColumn:t.range.start.character+1,endLineNumber:t.range.end.line+1,endColumn:t.range.end.character+1,message:t.message};var t}));this._diagnosticsService.fireDiagnosticsChange(e.uri,i),t.setModelMarkers(e,s,a)}catch(e){console.error(e)}}}function d(t){switch(t){case e.exports.DiagnosticSeverity.Error:return s.Error;case e.exports.DiagnosticSeverity.Warning:return s.Warning;case e.exports.DiagnosticSeverity.Information:return s.Info;case e.exports.DiagnosticSeverity.Hint:return s.Hint;default:return s.Info}}function h(e){return new r(e.start.line+1,e.start.character+1,e.end.line+1,e.end.character+1)}function m(e){return{range:h(e.range),text:e.newText}}function x(t){const s=n.CompletionItemKind;switch(t){case e.exports.CompletionItemKind.Text:return s.Text;case e.exports.CompletionItemKind.Method:return s.Method;case e.exports.CompletionItemKind.Function:return s.Function;case e.exports.CompletionItemKind.Constructor:return s.Constructor;case e.exports.CompletionItemKind.Field:return s.Field;case e.exports.CompletionItemKind.Variable:return s.Variable;case e.exports.CompletionItemKind.Class:return s.Class;case e.exports.CompletionItemKind.Interface:return s.Interface;case e.exports.CompletionItemKind.Module:return s.Module;case e.exports.CompletionItemKind.Property:return s.Property;case e.exports.CompletionItemKind.Unit:return s.Unit;case e.exports.CompletionItemKind.Value:return s.Value;case e.exports.CompletionItemKind.Enum:return s.Enum;case e.exports.CompletionItemKind.Keyword:return s.Keyword;case e.exports.CompletionItemKind.Snippet:return s.Snippet;case e.exports.CompletionItemKind.Color:return s.Color;case e.exports.CompletionItemKind.File:return s.File;case e.exports.CompletionItemKind.Reference:return s.Reference;case e.exports.CompletionItemKind.Folder:return s.Folder;case e.exports.CompletionItemKind.EnumMember:return s.EnumMember;case e.exports.CompletionItemKind.Constant:return s.Constant;case e.exports.CompletionItemKind.Struct:return s.Struct;case e.exports.CompletionItemKind.Event:return s.Event;case e.exports.CompletionItemKind.Operator:return s.Operator;case e.exports.CompletionItemKind.TypeParameter:return s.TypeParameter;default:return s.Property}}class w{constructor(e,t){this._worker=e,this._defaults=t,this.triggerCharacters=[".","("]}async provideCompletionItems(t,s){const i=await this._worker(t.uri),a=this._defaults.getApiContextForModel(t.uri),o=await i.doComplete(t.uri.toString(),function(e){return{character:e.column-1,line:e.lineNumber-1}}(s),a),c=t.getWordUntilPosition(s),u=new r(s.lineNumber,c.startColumn,s.lineNumber,c.endColumn),l=o.items.map((t=>{const s={label:t.label,insertText:t.insertText||t.label,sortText:t.sortText,filterText:t.filterText,detail:t.detail,range:u,kind:x(t.kind)};var r;return t.textEdit&&(s.range=void 0!==(r=t.textEdit).insert&&void 0!==r.replace?{insert:h(t.textEdit.insert),replace:h(t.textEdit.replace)}:h(t.textEdit.range),s.insertText=t.textEdit.newText),t.additionalTextEdits&&(s.additionalTextEdits=t.additionalTextEdits.map(m)),t.insertTextFormat===e.exports.InsertTextFormat.Snippet&&(s.insertTextRules=n.CompletionItemInsertTextRule.InsertAsSnippet),t.documentation&&(s.documentation="string"==typeof t.documentation?t.documentation:{supportThemeIcons:!1,value:t.documentation.value,supportHtml:!0}),s}));return{incomplete:o.isIncomplete,suggestions:l}}}class k{constructor(e,t){this._worker=e,this._defaults=t}async provideDocumentFormattingEdits(e){const t=await this._worker(e.uri),s=this._defaults.getApiContextForModel(e.uri.toString());return(await t.doFormat(e.uri.toString(),s)).map((e=>({range:h(e.range),text:e.newText})))}}let f,b=new a;class y{constructor(e){this._defaults=e,this._worker=null,this._client=null,this._configChangeListener=this._defaults.onDidChange((()=>this.stopWorker()))}dispose(){this._configChangeListener.dispose(),this.stopWorker()}stopWorker(){this._worker&&(this._worker.dispose(),this._worker=null,b=new a),this._client=null}static async waitForWorker(){return await b.promise}async _getClientProxy(){if(!this._client){const{languageId:e}=this._defaults;this._worker=t.createWebWorker({moduleId:"ArcadeWorker",label:e,createData:{languageId:e},host:this._defaults.workerHost}),b.resolve(this._worker),this._client=this._worker.getProxy()}return await this._client}async getLanguageServiceWorker(...e){const t=await this._getClientProxy();return await(this._worker?.withSyncedResources(e)),t}}async function v(...e){return await y.waitForWorker(),await new Promise(((t,s)=>{f?t(f(...e)):s(new Error("Arcade not registered!"))}))}const C=new class{constructor(){this._onDiagnosticsChange=new o}get onDiagnosticsChange(){return this._onDiagnosticsChange.event}fireDiagnosticsChange(e,t){this._onDiagnosticsChange.fire({uri:e,diagnostics:t})}};function _(){return C}function F(e){const t=new y(e),s=async(...e)=>await t.getLanguageServiceWorker(...e);f=s,n.setMonarchTokensProvider(e.languageId,g),n.setLanguageConfiguration(e.languageId,l),n.registerCompletionItemProvider(e.languageId,new w(s,e)),n.registerDocumentFormattingEditProvider(e.languageId,new k(s,e)),new p(e.languageId,s,{defaults:e,diagnosticsService:C})}export{_ as getArcadeDiagnosticService,v as getArcadeWorker,F as setupMode}
|
|
6
|
+
import{m as e,r as t,Q as s,R as r,w as n,T as i,D as a,V as o}from"./p-c4757cc3.js";import"./p-7d49eb93.js";var c=[[],[],[]];["++","--"].forEach((e=>c[e.length-1]?.push(e))),["-","+","!","~"].forEach((e=>c[e.length-1]?.push(e))),["||","&&"].forEach((e=>c[e.length-1]?.push(e))),["=","/=","*=","%=","+=","-="].forEach((e=>c[e.length-1]?.push(e))),["|","&",">>","<<",">>>","^","==","!=","<","<=",">",">=","+","-","*","/","%"].forEach((e=>c[e.length-1]?.push(e)));var u=Object.values({Break:"break",Continue:"continue",Else:"else",For:"for",From:"from",Function:"function",If:"if",Import:"import",Export:"export",In:"in",Return:"return",Var:"var",While:"while"});Object.values({False:"false",Null:"null",True:"true"}).map((t=>({label:t,kind:e.exports.CompletionItemKind.Constant}))),u.map((t=>({label:t,kind:e.exports.CompletionItemKind.Keyword})));const l={wordPattern:/(-?\d*\.\d\w*)|([^`~!#%\^&\*\(\)\-=\+\[\{\]\}\\\|;:'",\.<>\/\?\s]+)/gu,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]},{open:"`",close:"`",notIn:["string","comment"]}],autoCloseBefore:";:.,=}])` \n\t",folding:{markers:{start:/^\s*\/\/\s*#?region\b/u,end:/^\s*\/\/\s*#?endregion\b/u}},indentationRules:{decreaseIndentPattern:/^((?!.*?\/\*).*\*\/)?\s*[\}\]\)].*$/u,increaseIndentPattern:/^((?!\/\/).)*(\{[^}"'`]*|\([^)"'`]*|\[[^\]"'`]*)$/u}},g={defaultToken:"invalid",tokenPostfix:".arcgis",ignoreCase:!0,keywords:u.filter((e=>"from"!==e)),operators:["<=",">=","==","!=","+","-","*","/","%","++","--","<<",">>",">>>","&","|","^","!","~","&&","||","=","+=","-=","*=","**=","/=","%="],constants:["true","false","null"],symbols:/[=><!~?:&|+\-*\/\^%]+/u,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/u,digits:/\d+(_+\d+)*/u,octaldigits:/[0-7]+(_+[0-7]+)*/u,binarydigits:/[0-1]+(_+[0-1]+)*/u,hexdigits:/[[0-9a-fA-F]+(_+[0-9a-fA-F]+)*/u,regexpctl:/[(){}\[\]\$\^|\-*+?\.]/u,regexpesc:/\\(?:[bBdDfnrstvwWn0\\\/]|@regexpctl|c[A-Z]|x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4})/u,tokenizer:{root:[[/[{}]/u,"delimiter.bracket"],{include:"common"}],common:[[/import(?=\s)/u,{token:"keyword",next:"@import"}],[/[a-z_$][\w$]*/u,{cases:{"@constants":"constant","@keywords":"keyword","@default":"identifier"}}],{include:"@whitespace"},[/\/(?=([^\\\/]|\\.)+\/([gimsuy]*)(\s*)(\.|;|\/|,|\)|\]|\}|$))/u,{token:"regexp",bracket:"@open",next:"@regexp"}],[/[()\[\]]/u,"@brackets"],[/[<>](?!@symbols)/u,"@brackets"],[/@symbols/u,{cases:{"@operators":"delimiter","@default":""}}],[/(@digits)[eE]([\-+]?(@digits))?/u,"number"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?/u,"number"],[/0[xX](@hexdigits)/u,"number"],[/0[oO]?(@octaldigits)/u,"number"],[/0[bB](@binarydigits)/u,"number"],[/(@digits)/u,"number"],[/[;,.]/u,"delimiter"],[/"([^"\\]|\\.)*$/u,"string.invalid"],[/'([^'\\]|\\.)*$/u,"string.invalid"],[/"/u,"string","@string_double"],[/'/u,"string","@string_single"],[/`/u,"string","@string_backtick"]],import:[[/import(?=\s)/u,{token:"keyword"}],{include:"@whitespace"},[/[a-z_$][\w$]*/u,"identifier"],{include:"@whitespace"},[/from/u,{token:"keyword",next:"@popall"}]],whitespace:[[/[ \t\r\n]+/u,""],[/\/\*/u,"comment","@comment"],[/\/\/.*$/u,"comment"]],comment:[[/[^\/*]+/u,"comment"],[/\*\//u,"comment","@pop"],[/[\/*]/u,"comment"]],regexp:[[/(\{)(\d+(?:,\d*)?)(\})/u,["regexp.escape.control","regexp.escape.control","regexp.escape.control"]],[/(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/u,["regexp.escape.control",{token:"regexp.escape.control",next:"@regexrange"}]],[/(\()(\?:|\?=|\?!)/u,["regexp.escape.control","regexp.escape.control"]],[/[()]/u,"regexp.escape.control"],[/@regexpctl/u,"regexp.escape.control"],[/[^\\\/]/u,"regexp"],[/@regexpesc/u,"regexp.escape"],[/\\\./u,"regexp.invalid"],[/(\/)([gimsuy]*)/u,[{token:"regexp",bracket:"@close",next:"@pop"},"keyword.other"]]],regexrange:[[/-/u,"regexp.escape.control"],[/\^/u,"regexp.invalid"],[/@regexpesc/u,"regexp.escape"],[/[^\]]/u,"regexp"],[/\]/u,{token:"regexp.escape.control",next:"@pop",bracket:"@close"}]],string_double:[[/[^\\"]+/u,"string"],[/@escapes/u,"string.escape"],[/\\./u,"string.escape.invalid"],[/"/u,"string","@pop"]],string_single:[[/[^\\']+/u,"string"],[/@escapes/u,"string.escape"],[/\\./u,"string.escape.invalid"],[/'/u,"string","@pop"]],string_backtick:[[/\$\{/u,{token:"delimiter.bracket",next:"@bracketCounting"}],[/[^\\`$]+/u,"string"],[/@escapes/u,"string.escape"],[/\\./u,"string.escape.invalid"],[/`/u,"string","@pop"]],bracketCounting:[[/\{/u,"delimiter.bracket","@bracketCounting"],[/\}/u,"delimiter.bracket","@pop"],{include:"common"}]}};class p{constructor(e,s,{defaults:r,diagnosticsService:n}){this._languageId=e,this._worker=s,this._disposables=[],this._listener=new Map,this._diagnosticsService=n,this._defaults=r;const a=e=>{const t=e.getLanguageId();if(t!==this._languageId)return;const s=i((()=>{this._doValidate(e,t).catch((e=>{throw e}))}));this._listener.set(e.uri.toString(),e.onDidChangeContent(s)),this._doValidate(e,t).catch(console.error)},o=e=>{const s=e.uri.toString();t.setModelMarkers(e,this._languageId,[]);const r=this._listener.get(s);r&&(r.dispose(),this._listener.delete(s))};this._disposables.push(t.onDidCreateModel(a)),this._disposables.push(t.onWillDisposeModel((e=>{o(e)}))),this._disposables.push(t.onDidChangeModelLanguage((e=>{o(e.model),a(e.model)}))),this._disposables.push(r.onDidChange((()=>{t.getModels().forEach((e=>{e.getLanguageId()===this._languageId&&(o(e),a(e))}))}))),this._disposables.push(r.onModelContextDidChange((e=>{t.getModels().forEach((t=>{t.getLanguageId()===this._languageId&&t.uri.toString()===e&&this._doValidate(t,this._languageId).catch(console.error)}))}))),this._disposables.push({dispose:()=>{this._listener.forEach((e=>e.dispose())),this._listener.clear()}}),t.getModels().forEach(a)}dispose(){this._disposables.forEach((e=>e.dispose())),this._disposables=[]}async _doValidate(e,s){if(e.isAttachedToEditor())try{const r=await this._worker(e.uri),n=this._defaults.getApiContextForModel(e.uri),i=await r.doValidation(e.uri.toString(),n),a=i.map((e=>{return{severity:d((t=e).severity),startLineNumber:t.range.start.line+1,startColumn:t.range.start.character+1,endLineNumber:t.range.end.line+1,endColumn:t.range.end.character+1,message:t.message};var t}));this._diagnosticsService.fireDiagnosticsChange(e.uri,i),t.setModelMarkers(e,s,a)}catch(e){console.error(e)}}}function d(t){switch(t){case e.exports.DiagnosticSeverity.Error:return s.Error;case e.exports.DiagnosticSeverity.Warning:return s.Warning;case e.exports.DiagnosticSeverity.Information:return s.Info;case e.exports.DiagnosticSeverity.Hint:return s.Hint;default:return s.Info}}function h(e){return new r(e.start.line+1,e.start.character+1,e.end.line+1,e.end.character+1)}function m(e){return{range:h(e.range),text:e.newText}}function x(t){const s=n.CompletionItemKind;switch(t){case e.exports.CompletionItemKind.Text:return s.Text;case e.exports.CompletionItemKind.Method:return s.Method;case e.exports.CompletionItemKind.Function:return s.Function;case e.exports.CompletionItemKind.Constructor:return s.Constructor;case e.exports.CompletionItemKind.Field:return s.Field;case e.exports.CompletionItemKind.Variable:return s.Variable;case e.exports.CompletionItemKind.Class:return s.Class;case e.exports.CompletionItemKind.Interface:return s.Interface;case e.exports.CompletionItemKind.Module:return s.Module;case e.exports.CompletionItemKind.Property:return s.Property;case e.exports.CompletionItemKind.Unit:return s.Unit;case e.exports.CompletionItemKind.Value:return s.Value;case e.exports.CompletionItemKind.Enum:return s.Enum;case e.exports.CompletionItemKind.Keyword:return s.Keyword;case e.exports.CompletionItemKind.Snippet:return s.Snippet;case e.exports.CompletionItemKind.Color:return s.Color;case e.exports.CompletionItemKind.File:return s.File;case e.exports.CompletionItemKind.Reference:return s.Reference;case e.exports.CompletionItemKind.Folder:return s.Folder;case e.exports.CompletionItemKind.EnumMember:return s.EnumMember;case e.exports.CompletionItemKind.Constant:return s.Constant;case e.exports.CompletionItemKind.Struct:return s.Struct;case e.exports.CompletionItemKind.Event:return s.Event;case e.exports.CompletionItemKind.Operator:return s.Operator;case e.exports.CompletionItemKind.TypeParameter:return s.TypeParameter;default:return s.Property}}class w{constructor(e,t){this._worker=e,this._defaults=t,this.triggerCharacters=[".","("]}async provideCompletionItems(t,s){const i=await this._worker(t.uri),a=this._defaults.getApiContextForModel(t.uri),o=await i.doComplete(t.uri.toString(),function(e){return{character:e.column-1,line:e.lineNumber-1}}(s),a),c=t.getWordUntilPosition(s),u=new r(s.lineNumber,c.startColumn,s.lineNumber,c.endColumn),l=o.items.map((t=>{const s={label:t.label,insertText:t.insertText||t.label,sortText:t.sortText,filterText:t.filterText,detail:t.detail,range:u,kind:x(t.kind)};var r;return t.textEdit&&(s.range=void 0!==(r=t.textEdit).insert&&void 0!==r.replace?{insert:h(t.textEdit.insert),replace:h(t.textEdit.replace)}:h(t.textEdit.range),s.insertText=t.textEdit.newText),t.additionalTextEdits&&(s.additionalTextEdits=t.additionalTextEdits.map(m)),t.insertTextFormat===e.exports.InsertTextFormat.Snippet&&(s.insertTextRules=n.CompletionItemInsertTextRule.InsertAsSnippet),t.documentation&&(s.documentation="string"==typeof t.documentation?t.documentation:{supportThemeIcons:!1,value:t.documentation.value,supportHtml:!0}),s}));return{incomplete:o.isIncomplete,suggestions:l}}}class k{constructor(e,t){this._worker=e,this._defaults=t}async provideDocumentFormattingEdits(e){const t=await this._worker(e.uri),s=this._defaults.getApiContextForModel(e.uri.toString());return(await t.doFormat(e.uri.toString(),s)).map((e=>({range:h(e.range),text:e.newText})))}}let f,b=new a;class y{constructor(e){this._defaults=e,this._worker=null,this._client=null,this._configChangeListener=this._defaults.onDidChange((()=>this.stopWorker()))}dispose(){this._configChangeListener.dispose(),this.stopWorker()}stopWorker(){this._worker&&(this._worker.dispose(),this._worker=null,b=new a),this._client=null}static async waitForWorker(){return await b.promise}async _getClientProxy(){if(!this._client){const{languageId:e}=this._defaults;this._worker=t.createWebWorker({moduleId:"ArcadeWorker",label:e,createData:{languageId:e},host:this._defaults.workerHost}),b.resolve(this._worker),this._client=this._worker.getProxy()}return await this._client}async getLanguageServiceWorker(...e){const t=await this._getClientProxy();return await(this._worker?.withSyncedResources(e)),t}}async function v(...e){return await y.waitForWorker(),await new Promise(((t,s)=>{f?t(f(...e)):s(new Error("Arcade not registered!"))}))}const C=new class{constructor(){this._onDiagnosticsChange=new o}get onDiagnosticsChange(){return this._onDiagnosticsChange.event}fireDiagnosticsChange(e,t){this._onDiagnosticsChange.fire({uri:e,diagnostics:t})}};function _(){return C}function F(e){const t=new y(e),s=async(...e)=>await t.getLanguageServiceWorker(...e);f=s,n.setMonarchTokensProvider(e.languageId,g),n.setLanguageConfiguration(e.languageId,l),n.registerCompletionItemProvider(e.languageId,new w(s,e)),n.registerDocumentFormattingEditProvider(e.languageId,new k(s,e)),new p(e.languageId,s,{defaults:e,diagnosticsService:C})}export{_ as getArcadeDiagnosticService,v as getArcadeWorker,F as setupMode}
|
|
@@ -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.92
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const sqlExprDefaults = require('./sql-expr-defaults-
|
|
9
|
-
const index = require('./index-
|
|
8
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
9
|
+
const index = require('./index-9c03f952.js');
|
|
10
10
|
|
|
11
11
|
// #region convert editor profile to apiProfile
|
|
12
12
|
/**
|
|
@@ -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.92
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const sqlExprDefaults = require('./sql-expr-defaults-
|
|
9
|
-
require('./index-
|
|
8
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
9
|
+
require('./index-9c03f952.js');
|
|
10
10
|
|
|
11
11
|
var V={False:"false",Null:"null",True:"true"},f={Break:"break",Continue:"continue",Else:"else",For:"for",From:"from",Function:"function",If:"if",Import:"import",Export:"export",In:"in",Return:"return",Var:"var",While:"while"},xe=["++","--"],Ge=["-","+","!","~"],Je=["=","/=","*=","%=","+=","-="],Qe=["||","&&"],Lt=["|","&",">>","<<",">>>","^","==","!=","<","<=",">",">=","+","-","*","/","%"];var U=[[],[],[]];xe.forEach(e=>U[e.length-1]?.push(e));Ge.forEach(e=>U[e.length-1]?.push(e));Qe.forEach(e=>U[e.length-1]?.push(e));Je.forEach(e=>U[e.length-1]?.push(e));Lt.forEach(e=>U[e.length-1]?.push(e));var lt=Object.values(f),pt=Object.values(V);pt.map(e=>({label:e,kind:sqlExprDefaults.main.exports.CompletionItemKind.Constant}));lt.map(e=>({label:e,kind:sqlExprDefaults.main.exports.CompletionItemKind.Keyword}));
|
|
12
12
|
|
|
@@ -1,16 +1,16 @@
|
|
|
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.92
|
|
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 sqlExprDefaults = require('./sql-expr-defaults-
|
|
12
|
-
const useT9n = require('./useT9n-
|
|
13
|
-
const arcadeDefaults = require('./arcade-defaults-
|
|
10
|
+
const index = require('./index-9c03f952.js');
|
|
11
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
12
|
+
const useT9n = require('./useT9n-0188a2cb.js');
|
|
13
|
+
const arcadeDefaults = require('./arcade-defaults-9cb56c22.js');
|
|
14
14
|
|
|
15
15
|
const DevelopersWebSitePath = "https://developers.arcgis.com/arcade/";
|
|
16
16
|
const MaxArrayItems = 100;
|
|
@@ -307,7 +307,7 @@ async function getArcadeDiagnosticService() {
|
|
|
307
307
|
* @returns arcade mode module
|
|
308
308
|
*/
|
|
309
309
|
async function getMode$1() {
|
|
310
|
-
return await Promise.resolve().then(function () { return require('./arcade-mode-
|
|
310
|
+
return await Promise.resolve().then(function () { return require('./arcade-mode-1f84ac48.js'); });
|
|
311
311
|
}
|
|
312
312
|
|
|
313
313
|
const arcadeEditorCss = "arcgis-arcade-editor{display:flex;flex-direction:column;position:relative;overflow:hidden;border:var(--arcgis-coding-components-border);box-sizing:border-box;background-color:var(--arcgis-coding-components-background-color);height:100%}arcgis-arcade-editor .flex-adjustable{flex:1 1 auto;overflow:hidden}arcgis-arcade-editor .flex-panel{flex:1 0 auto}arcgis-arcade-editor .position-relative{position:relative}arcgis-arcade-editor .flex-row{display:flex;flex-direction:row;overflow:hidden}arcgis-arcade-editor .flex-column{display:flex;flex-direction:column;overflow:hidden}arcgis-arcade-editor .border-inline-start{border-inline-start:var(--arcgis-coding-components-border);box-sizing:border-box}arcgis-arcade-editor .border-inline-end{border-inline-end:var(--arcgis-coding-components-border);box-sizing:border-box}arcgis-arcade-editor .sticky{position:sticky;top:0px;z-index:10}arcgis-arcade-editor .notice-container{margin:var(--calcite-spacing-xxs);padding:var(--calcite-spacing-sm);background-color:var(--calcite-color-foreground-1);text-align:center}arcgis-arcade-editor .side-action-bar{max-width:var(--arcgis-coding-components-side-action-bar-max-w)}arcgis-arcade-editor .side-panel{max-width:var(--arcgis-coding-components-side-panel-max-w);width:var(--arcgis-coding-components-side-panel-w)}arcgis-arcade-editor .side-panel calcite-flow{height:100%}arcgis-arcade-editor .main-action-bar{border-bottom:var(--arcgis-coding-components-border);flex:0 0 auto}arcgis-arcade-editor .main-action-bar calcite-action-group{padding-inline-end:var(--calcite-spacing-sm)}arcgis-arcade-editor .main-action-bar calcite-action-group calcite-action{padding-inline-end:var(--calcite-spacing-sm)}arcgis-arcade-editor .main-action-bar calcite-action-group calcite-action:not(:first-child){padding-inline-start:var(--calcite-spacing-sm)}arcgis-arcade-editor .main-action-bar calcite-action-group:last-child{border-inline-end-width:0px}arcgis-arcade-editor .main-action-bar calcite-action-group:not(:first-child){padding-inline-start:var(--calcite-spacing-sm)}arcgis-arcade-editor arcgis-arcade-results{border-top:var(--arcgis-coding-components-border);box-sizing:border-box;max-height:50%;min-height:50%;margin-bottom:-1px}arcgis-arcade-editor calcite-flow [slot=footer]{word-break:break-word}";
|
|
@@ -370,6 +370,26 @@ const ArcgisArcadeEditor = class {
|
|
|
370
370
|
this._insertAsText = (e) => void this._codeEditorElt?.insertText(e.detail).catch(console.error);
|
|
371
371
|
this._onResultPanelChange = (e) => void (this._resultPanel = e.detail);
|
|
372
372
|
this._onExecutionPanelClose = () => void (this._showExecutionPanel = false);
|
|
373
|
+
this._addExecuteScriptAction = () => {
|
|
374
|
+
const action = this.editorInstance?.addAction({
|
|
375
|
+
// An unique identifier for the action.
|
|
376
|
+
id: "run-script",
|
|
377
|
+
label: "Run Arcade Expression",
|
|
378
|
+
keybindings: [sqlExprDefaults.KeyCode.F5],
|
|
379
|
+
contextMenuGroupId: "code",
|
|
380
|
+
contextMenuOrder: 1,
|
|
381
|
+
run: () => {
|
|
382
|
+
if (this.testData) {
|
|
383
|
+
this._executeScript().catch(console.error);
|
|
384
|
+
}
|
|
385
|
+
},
|
|
386
|
+
});
|
|
387
|
+
if (action) {
|
|
388
|
+
// update disposables with action
|
|
389
|
+
this._executeScriptAction = action;
|
|
390
|
+
this._disposables.push(action);
|
|
391
|
+
}
|
|
392
|
+
};
|
|
373
393
|
this._preparingArcade = false;
|
|
374
394
|
this._editorProfile = undefined;
|
|
375
395
|
this._apiLibrary = undefined;
|
|
@@ -403,6 +423,13 @@ const ArcgisArcadeEditor = class {
|
|
|
403
423
|
await this._updateApiLibrary();
|
|
404
424
|
}
|
|
405
425
|
_testDataChanged() {
|
|
426
|
+
if (!this.testData && this._executeScriptAction) {
|
|
427
|
+
this._disposeSafely(this._executeScriptAction);
|
|
428
|
+
this._executeScriptAction = undefined;
|
|
429
|
+
}
|
|
430
|
+
if (this.testData && !this._executeScriptAction) {
|
|
431
|
+
this._addExecuteScriptAction();
|
|
432
|
+
}
|
|
406
433
|
if (!this._showExecutionPanel) {
|
|
407
434
|
return;
|
|
408
435
|
}
|
|
@@ -474,20 +501,9 @@ const ArcgisArcadeEditor = class {
|
|
|
474
501
|
// We are doing this as late as possible
|
|
475
502
|
const diagnosticsService = await getArcadeDiagnosticService();
|
|
476
503
|
this._disposables.push(diagnosticsService.onDiagnosticsChange((event) => !this._preparingArcade && this.arcgisDiagnosticsChange.emit(event.diagnostics)));
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
id: "run-script",
|
|
481
|
-
label: "Run Arcade Expression",
|
|
482
|
-
keybindings: [sqlExprDefaults.KeyCode.F5],
|
|
483
|
-
contextMenuGroupId: "code",
|
|
484
|
-
contextMenuOrder: 1,
|
|
485
|
-
run: () => {
|
|
486
|
-
if (this.testData) {
|
|
487
|
-
this._executeScript().catch(console.error);
|
|
488
|
-
}
|
|
489
|
-
},
|
|
490
|
-
});
|
|
504
|
+
if (this.testData) {
|
|
505
|
+
this._addExecuteScriptAction();
|
|
506
|
+
}
|
|
491
507
|
await this._codeEditorElt?.setFocus();
|
|
492
508
|
}
|
|
493
509
|
disconnectedCallback() {
|
|
@@ -519,6 +535,14 @@ const ArcgisArcadeEditor = class {
|
|
|
519
535
|
async _updateApiLibrary() {
|
|
520
536
|
this._apiLibrary = await arcadeDefaults.arcadeDefaults.getApiLibraryForModel(this._modelId);
|
|
521
537
|
}
|
|
538
|
+
// Method to safely dispose of an IDisposable
|
|
539
|
+
_disposeSafely(disposable) {
|
|
540
|
+
const index = this._disposables.indexOf(disposable);
|
|
541
|
+
if (index !== -1) {
|
|
542
|
+
this._disposables.splice(index, 1);
|
|
543
|
+
}
|
|
544
|
+
disposable.dispose();
|
|
545
|
+
}
|
|
522
546
|
// #endregion
|
|
523
547
|
//#region Render Main Action Bar
|
|
524
548
|
renderMainActionBar() {
|
|
@@ -601,7 +625,7 @@ const ArcgisArcadeEditor = class {
|
|
|
601
625
|
//#endregion
|
|
602
626
|
//#region Render
|
|
603
627
|
render() {
|
|
604
|
-
return (index.h(index.Host, { key: '
|
|
628
|
+
return (index.h(index.Host, { key: '49ab207dfd02ab53dfaf10f309c2eab88755d48b' }, this.renderMainActionBar(), index.h("div", { key: '58e93da383a3774594fcf8f2b6ca9d5f42d79140', class: "flex-row flex-adjustable" }, index.h("div", { key: 'cf8296908b3c6bea7a4668f19e6b12bde2bc7607', class: "flex-column flex-adjustable" }, this.renderMainPanel(), this.renderResultsPanel()), this.renderSidePanel(), this.renderSideActionBar())));
|
|
605
629
|
}
|
|
606
630
|
static get assetsDirs() { return ["assets"]; }
|
|
607
631
|
get el() { return index.getElement(this); }
|
|
@@ -3933,7 +3957,7 @@ sqlExprDefaults.languages.onLanguage(arcadeDefaults.arcadeDefaults.languageId, (
|
|
|
3933
3957
|
* @returns sql-expression mode module
|
|
3934
3958
|
*/
|
|
3935
3959
|
async function getMode() {
|
|
3936
|
-
return await Promise.resolve().then(function () { return require('./sql-expr-mode-
|
|
3960
|
+
return await Promise.resolve().then(function () { return require('./sql-expr-mode-849b8ca0.js'); });
|
|
3937
3961
|
}
|
|
3938
3962
|
|
|
3939
3963
|
// Register the language in Monaco
|
|
@@ -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.92
|
|
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-9c03f952.js');
|
|
11
|
+
const appGlobals = require('./app-globals-ea3d8f2a.js');
|
|
12
12
|
|
|
13
13
|
/*
|
|
14
14
|
Stencil Client Patch Browser v4.20.0 | MIT Licensed | https://stenciljs.com
|
|
@@ -1,15 +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.92
|
|
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 useT9n = require('./useT9n-
|
|
12
|
-
const sqlExprDefaults = require('./sql-expr-defaults-
|
|
10
|
+
const index = require('./index-9c03f952.js');
|
|
11
|
+
const useT9n = require('./useT9n-0188a2cb.js');
|
|
12
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
13
13
|
|
|
14
14
|
const sqlExpressionEditorCss = "arcgis-sql-expression-editor{display:flex;flex-direction:column;position:relative;overflow:hidden;border:var(--arcgis-coding-components-border);box-sizing:border-box;background-color:var(--arcgis-coding-components-background-color);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:var(--arcgis-coding-components-border);box-sizing:border-box}arcgis-sql-expression-editor .border-inline-end{border-inline-end:var(--arcgis-coding-components-border);box-sizing:border-box}arcgis-sql-expression-editor .side-action-bar{max-width:var(--arcgis-coding-components-side-action-bar-max-w)}arcgis-sql-expression-editor .side-panel{max-width:var(--arcgis-coding-components-side-panel-max-w);width:var(--arcgis-coding-components-side-panel-w)}arcgis-sql-expression-editor .side-panel calcite-flow{height:100%}";
|
|
15
15
|
const ArcgisSqlExpressionEditorStyle0 = sqlExpressionEditorCss;
|
|
@@ -1,15 +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.92
|
|
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 useT9n = require('./useT9n-
|
|
12
|
-
const sqlExprDefaults = require('./sql-expr-defaults-
|
|
10
|
+
const index = require('./index-9c03f952.js');
|
|
11
|
+
const useT9n = require('./useT9n-0188a2cb.js');
|
|
12
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
13
13
|
|
|
14
14
|
const sqlExpressionFieldsCss = ":host calcite-flow{height:100%}:host calcite-list-item-group{background-color:var(--calcite-color-foreground-2)}";
|
|
15
15
|
const ArcgisSqlExpressionFieldsStyle0 = sqlExpressionFieldsCss;
|
|
@@ -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.92
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const sqlExprDefaults = require('./sql-expr-defaults-
|
|
9
|
-
require('./index-
|
|
8
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
9
|
+
require('./index-9c03f952.js');
|
|
10
10
|
|
|
11
11
|
/*!-----------------------------------------------------------------------------
|
|
12
12
|
* 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.92
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const sqlExprDefaults = require('./sql-expr-defaults-
|
|
9
|
-
require('./index-
|
|
8
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
9
|
+
require('./index-9c03f952.js');
|
|
10
10
|
|
|
11
11
|
/*!-----------------------------------------------------------------------------
|
|
12
12
|
* 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.92
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const sqlExprDefaults = require('./sql-expr-defaults-
|
|
9
|
-
require('./index-
|
|
8
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
9
|
+
require('./index-9c03f952.js');
|
|
10
10
|
|
|
11
11
|
/*!-----------------------------------------------------------------------------
|
|
12
12
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
package/dist/cjs/index.cjs.js
CHANGED
|
@@ -1,15 +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.92
|
|
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
|
-
const sqlExprDefaults = require('./sql-expr-defaults-
|
|
12
|
-
require('./index-
|
|
10
|
+
const arcadeDefaults = require('./arcade-defaults-9cb56c22.js');
|
|
11
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
12
|
+
require('./index-9c03f952.js');
|
|
13
13
|
|
|
14
14
|
|
|
15
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.92
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const typescript = require('./typescript-
|
|
9
|
-
require('./sql-expr-defaults-
|
|
10
|
-
require('./index-
|
|
8
|
+
const typescript = require('./typescript-2c5105b6.js');
|
|
9
|
+
require('./sql-expr-defaults-b961f377.js');
|
|
10
|
+
require('./index-9c03f952.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.92
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const sqlExprDefaults = require('./sql-expr-defaults-
|
|
9
|
-
require('./index-
|
|
8
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
9
|
+
require('./index-9c03f952.js');
|
|
10
10
|
|
|
11
11
|
/*!-----------------------------------------------------------------------------
|
|
12
12
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -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.92
|
|
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-9c03f952.js');
|
|
11
|
+
const appGlobals = require('./app-globals-ea3d8f2a.js');
|
|
12
12
|
|
|
13
13
|
const defineCustomElements = async (win, options) => {
|
|
14
14
|
if (typeof window === 'undefined') return undefined;
|
|
@@ -1,11 +1,11 @@
|
|
|
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.92
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-9c03f952.js');
|
|
9
9
|
|
|
10
10
|
function _interopNamespace(e) {
|
|
11
11
|
if (e && e.__esModule) return e;
|
|
@@ -124694,7 +124694,7 @@ registerLanguage({
|
|
|
124694
124694
|
mimetypes: ["text/css"],
|
|
124695
124695
|
loader: () => {
|
|
124696
124696
|
{
|
|
124697
|
-
return Promise.resolve().then(function () { return require('./css-
|
|
124697
|
+
return Promise.resolve().then(function () { return require('./css-ec306a7b.js'); });
|
|
124698
124698
|
}
|
|
124699
124699
|
}
|
|
124700
124700
|
});
|
|
@@ -124712,7 +124712,7 @@ registerLanguage({
|
|
|
124712
124712
|
mimetypes: ["text/html", "text/x-jshtm", "text/template", "text/ng-template"],
|
|
124713
124713
|
loader: () => {
|
|
124714
124714
|
{
|
|
124715
|
-
return Promise.resolve().then(function () { return require('./html-
|
|
124715
|
+
return Promise.resolve().then(function () { return require('./html-7d797680.js'); });
|
|
124716
124716
|
}
|
|
124717
124717
|
}
|
|
124718
124718
|
});
|
|
@@ -124732,7 +124732,7 @@ registerLanguage({
|
|
|
124732
124732
|
mimetypes: ["text/javascript"],
|
|
124733
124733
|
loader: () => {
|
|
124734
124734
|
{
|
|
124735
|
-
return Promise.resolve().then(function () { return require('./javascript-
|
|
124735
|
+
return Promise.resolve().then(function () { return require('./javascript-3e07a288.js'); });
|
|
124736
124736
|
}
|
|
124737
124737
|
}
|
|
124738
124738
|
});
|
|
@@ -124750,7 +124750,7 @@ registerLanguage({
|
|
|
124750
124750
|
mimetypes: ["text/typescript"],
|
|
124751
124751
|
loader: () => {
|
|
124752
124752
|
{
|
|
124753
|
-
return Promise.resolve().then(function () { return require('./typescript-
|
|
124753
|
+
return Promise.resolve().then(function () { return require('./typescript-2c5105b6.js'); });
|
|
124754
124754
|
}
|
|
124755
124755
|
}
|
|
124756
124756
|
});
|
|
@@ -124871,7 +124871,7 @@ var lessDefaults = new LanguageServiceDefaultsImpl$3("less", optionsDefault$1, m
|
|
|
124871
124871
|
monaco_editor_core_exports$3.languages.css = { cssDefaults, lessDefaults, scssDefaults };
|
|
124872
124872
|
function getMode$3() {
|
|
124873
124873
|
{
|
|
124874
|
-
return Promise.resolve().then(function () { return require('./cssMode-
|
|
124874
|
+
return Promise.resolve().then(function () { return require('./cssMode-3e849128.js'); });
|
|
124875
124875
|
}
|
|
124876
124876
|
}
|
|
124877
124877
|
monaco_editor_core_exports$3.languages.onLanguage("less", () => {
|
|
@@ -124996,7 +124996,7 @@ monaco_editor_core_exports$2.languages.html = {
|
|
|
124996
124996
|
};
|
|
124997
124997
|
function getMode$2() {
|
|
124998
124998
|
{
|
|
124999
|
-
return Promise.resolve().then(function () { return require('./htmlMode-
|
|
124999
|
+
return Promise.resolve().then(function () { return require('./htmlMode-7a5dd0a9.js'); });
|
|
125000
125000
|
}
|
|
125001
125001
|
}
|
|
125002
125002
|
function registerHTMLLanguageService(languageId, options = optionsDefault, modeConfiguration = getConfigurationDefault(languageId)) {
|
|
@@ -125098,7 +125098,7 @@ var jsonDefaults = new LanguageServiceDefaultsImpl$1("json", diagnosticDefault,
|
|
|
125098
125098
|
monaco_editor_core_exports$1.languages.json = { jsonDefaults };
|
|
125099
125099
|
function getMode$1() {
|
|
125100
125100
|
{
|
|
125101
|
-
return Promise.resolve().then(function () { return require('./jsonMode-
|
|
125101
|
+
return Promise.resolve().then(function () { return require('./jsonMode-da60682c.js'); });
|
|
125102
125102
|
}
|
|
125103
125103
|
}
|
|
125104
125104
|
monaco_editor_core_exports$1.languages.register({
|
|
@@ -125367,7 +125367,7 @@ monaco_editor_core_exports.languages.typescript = {
|
|
|
125367
125367
|
};
|
|
125368
125368
|
function getMode() {
|
|
125369
125369
|
{
|
|
125370
|
-
return Promise.resolve().then(function () { return require('./tsMode-
|
|
125370
|
+
return Promise.resolve().then(function () { return require('./tsMode-5ba938c7.js'); });
|
|
125371
125371
|
}
|
|
125372
125372
|
}
|
|
125373
125373
|
monaco_editor_core_exports.languages.onLanguage("typescript", () => {
|
|
@@ -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.92
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const sqlExprDefaults = require('./sql-expr-defaults-
|
|
9
|
-
require('./index-
|
|
8
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
9
|
+
require('./index-9c03f952.js');
|
|
10
10
|
|
|
11
11
|
// hold onto a promise that resolves when the worker is ready
|
|
12
12
|
let deferredWorker = new sqlExprDefaults.Deferred();
|
|
@@ -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.92
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const sqlExprDefaults = require('./sql-expr-defaults-
|
|
9
|
-
require('./index-
|
|
8
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
9
|
+
require('./index-9c03f952.js');
|
|
10
10
|
|
|
11
11
|
/*!-----------------------------------------------------------------------------
|
|
12
12
|
* 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.92
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const sqlExprDefaults = require('./sql-expr-defaults-
|
|
9
|
-
require('./index-
|
|
8
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
9
|
+
require('./index-9c03f952.js');
|
|
10
10
|
|
|
11
11
|
/*!-----------------------------------------------------------------------------
|
|
12
12
|
* 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.92
|
|
5
5
|
*/
|
|
6
6
|
'use strict';
|
|
7
7
|
|
|
8
|
-
const sqlExprDefaults = require('./sql-expr-defaults-
|
|
9
|
-
const index = require('./index-
|
|
8
|
+
const sqlExprDefaults = require('./sql-expr-defaults-b961f377.js');
|
|
9
|
+
const index = require('./index-9c03f952.js');
|
|
10
10
|
|
|
11
11
|
// src/framework.ts
|
|
12
12
|
function retrieveComponentMembers(component, isLit) {
|