@arcgis/coding-components 5.0.0-next.140 → 5.0.0-next.141

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.
Files changed (91) hide show
  1. package/dist/addons.js +1 -1
  2. package/dist/cdn/{ONS4ZING.js → 2KPWNHGP.js} +2 -2
  3. package/dist/cdn/2Q4RC3I2.js +4 -0
  4. package/dist/cdn/{ESQGKD4N.js → 2WFPKGNS.js} +2 -2
  5. package/dist/cdn/{AVDFLRTR.js → 2ZFE7VBS.js} +2 -2
  6. package/dist/cdn/{3FYTZKBP.js → 5BOQ5CDP.js} +1 -1
  7. package/dist/cdn/{C4EXEFHY.js → 5WHTC46G.js} +1 -1
  8. package/dist/cdn/{QEWPVXQ4.js → 62XTF2HV.js} +2 -2
  9. package/dist/cdn/{YYSVEFB6.js → AW57YOFI.js} +2 -2
  10. package/dist/cdn/BORLI5BL.js +13 -0
  11. package/dist/cdn/{G5T4EI7D.js → BSOIYFXU.js} +1 -1
  12. package/dist/cdn/{MO5R3BGP.js → BZCHBOQW.js} +2 -2
  13. package/dist/cdn/{ZZLSZBHB.js → CTONLFET.js} +2 -2
  14. package/dist/cdn/{K72FNTFN.js → DD7E4CTD.js} +2 -2
  15. package/dist/cdn/{YP3EICK5.js → DP5QMA47.js} +1 -1
  16. package/dist/cdn/DXKTKMXW.js +4 -0
  17. package/dist/cdn/FYTHJBIB.js +4 -0
  18. package/dist/cdn/{2ULX4YEB.js → G4IU5ZYX.js} +2 -2
  19. package/dist/cdn/{FVV4UAL5.js → GDON7RSD.js} +2 -2
  20. package/dist/cdn/{JTC4R6ZU.js → GE4G4GOF.js} +1 -1
  21. package/dist/cdn/{57JMNO5L.js → GRFHHJXW.js} +2 -2
  22. package/dist/cdn/{36M2T4ND.js → GWVYODXM.js} +2 -2
  23. package/dist/cdn/{62EN7QRE.js → HML5AZXI.js} +2 -2
  24. package/dist/cdn/{6HNTPPBF.js → J6YY3ZWZ.js} +1 -1
  25. package/dist/cdn/{7VAC6CMK.js → JZFVKLPE.js} +3 -3
  26. package/dist/cdn/LATZL6NN.js +4 -0
  27. package/dist/cdn/{DYMWCNFZ.js → LQHBSD4W.js} +2 -2
  28. package/dist/cdn/{6IKRQB72.js → N35JT2LB.js} +2 -2
  29. package/dist/cdn/{XTDTOBWV.js → NICG7HLY.js} +2 -2
  30. package/dist/cdn/{C7R3BXTS.js → NL6FLTKV.js} +2 -2
  31. package/dist/cdn/OO7CPYNX.js +4 -0
  32. package/dist/cdn/{P7JTV3RL.js → Q6SKY4Y3.js} +2 -2
  33. package/dist/cdn/{LJIVTQAR.js → RFWHUMFC.js} +2 -2
  34. package/dist/cdn/{VHZ4ET75.js → RGHWTK7O.js} +2 -2
  35. package/dist/cdn/{DHKHGAIN.js → RKGCVGAS.js} +1 -1
  36. package/dist/cdn/{2U5KSGDI.js → RVSQPK6O.js} +2 -2
  37. package/dist/cdn/{OFEE2U6F.js → SRMRL3U2.js} +2 -2
  38. package/dist/cdn/{DL4FPVPY.js → UCGGLYRZ.js} +2 -2
  39. package/dist/cdn/{7ZISFGDD.js → V54XUQYT.js} +2 -2
  40. package/dist/cdn/{IVLAW36F.js → VWEPFRQO.js} +2 -2
  41. package/dist/cdn/{2OHDWLLP.js → WUPM5AJR.js} +2 -2
  42. package/dist/cdn/{FNALAI66.js → WXTQR45B.js} +2 -2
  43. package/dist/cdn/{GZS2QNLW.js → WZNOW6ED.js} +2 -2
  44. package/dist/cdn/XEUUGRIV.js +4 -0
  45. package/dist/cdn/{ZU5A2KCX.js → XLJSTTSB.js} +2 -2
  46. package/dist/cdn/{QJG5IKIQ.js → Y3Q4THV3.js} +2 -2
  47. package/dist/cdn/{DWCX7EOA.js → ZGLMCIOB.js} +1 -1
  48. package/dist/cdn/{HAVQXZ3S.js → ZSD2KBQQ.js} +2 -2
  49. package/dist/cdn/{4SD3AP46.js → ZVQZ4OSA.js} +2 -2
  50. package/dist/cdn/index.js +2 -2
  51. package/dist/chunks/arcade-defaults.js +1 -1
  52. package/dist/chunks/arcade-executor.js +1 -1
  53. package/dist/chunks/arcade-mode.js +1 -1
  54. package/dist/chunks/arcade-service-accessors.js +1 -1
  55. package/dist/chunks/colorize.js +1 -1
  56. package/dist/chunks/fields.js +1 -1
  57. package/dist/chunks/language-defaults-base.js +1 -1
  58. package/dist/chunks/markdown.js +1 -1
  59. package/dist/chunks/monaco-importer.js +1 -1
  60. package/dist/chunks/monaco-theme.js +1 -1
  61. package/dist/chunks/runtime.js +1 -1
  62. package/dist/chunks/setup-monaco-theme.js +1 -1
  63. package/dist/chunks/sql-expr-defaults.js +1 -1
  64. package/dist/chunks/sql-expr-mode.js +1 -1
  65. package/dist/chunks/sql-expr-service-accessors.js +1 -1
  66. package/dist/chunks/useT9n.js +1 -1
  67. package/dist/chunks/utilities.js +1 -1
  68. package/dist/components/arcgis-arcade-coding-assistant/customElement.js +1 -1
  69. package/dist/components/arcgis-arcade-editor/customElement.js +18 -17
  70. package/dist/components/arcgis-arcade-results/customElement.js +17 -17
  71. package/dist/components/arcgis-arcade-suggestions/customElement.js +8 -8
  72. package/dist/components/arcgis-code-editor/customElement.js +1 -1
  73. package/dist/components/arcgis-code-editor-shell/customElement.js +1 -1
  74. package/dist/components/arcgis-code-viewer/customElement.js +1 -1
  75. package/dist/components/arcgis-editor-variables/customElement.js +4 -4
  76. package/dist/components/arcgis-language-api-panel/customElement.js +13 -13
  77. package/dist/components/arcgis-sql-expression-editor/customElement.js +19 -19
  78. package/dist/components/arcgis-sql-expression-fields/customElement.js +1 -1
  79. package/dist/docs/api.json +1 -1
  80. package/dist/docs/docs.json +1 -1
  81. package/dist/docs/web-types.json +1 -1
  82. package/dist/index.js +1 -1
  83. package/dist/loader.js +1 -1
  84. package/package.json +5 -5
  85. package/dist/cdn/5ARRYYLL.js +0 -13
  86. package/dist/cdn/5DATPYV6.js +0 -4
  87. package/dist/cdn/66W55DBK.js +0 -4
  88. package/dist/cdn/FCJTX2NB.js +0 -4
  89. package/dist/cdn/MCUF3HVR.js +0 -4
  90. package/dist/cdn/NJ3F2V6N.js +0 -4
  91. package/dist/cdn/P37FDVCH.js +0 -4
@@ -1 +1 @@
1
- {"timestamp":"2026-01-20T17:17:11","compiler":{"name":"@arcgis/lumina-compiler","version":"5.0.0-next.140","typescriptVersion":"5.9.3"},"components":[{"filePath":"src/components/arcade-editor/arcade-editor.tsx","tag":"arcgis-arcade-editor","overview":"","readme":"","usage":{},"docs":"[**Arcade**](https://developers.arcgis.com/arcade/) is a portable, and lightweight expression language used to create custom content throughout the [ArcGIS system](https://www.esri.com/en-us/arcgis/products/index).\nLike other expression languages, it can perform mathematical calculations, format text, and evaluate logical statements.\nIt also supports multi-statement expressions, variables, and flow control statements. Arcade is unique when compared to other expression and scripting languages due to its inclusion of [feature](https://developers.arcgis.com/arcade/guide/types/#feature) and [geometry](https://developers.arcgis.com/arcade/guide/types/#geometry) data types.\n\nMap Viewer (MV) was the first ArcGIS Online product to incorporate the new Arcade editor after [the editor's introduction in the November 2022 ArcGIS Online release](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/introducing-the-new-arcade-editor-in-arcgis-online/).\nThis was possible thanks to the Arcade editor component, which enabled MV to implement its own Arcade expression builder.\nYou can now also find the editor in ArcGIS Dashboards, ArcGIS Field Maps, and ArcGIS Velocity.\n\nYou can easily get your own dedicated Arcade expression builder with the **Arcade editor** component, which includes:\n\n- An easy to use [layout](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/discover-the-arcade-editors-powerful-new-features/#the-new-layout)\n- An optional minimal layout if you, for example, decide to manually exclude things such as test data, padding, line numbers, and the sidebar\n- A way to execute Arcade expressions in a configurable code editor\n- [Suggestions and code completion](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/discover-the-arcade-editors-powerful-new-features/#suggestions-and-code-completion)\n- [WCAG 2.0 compliant code colorization / syntax highlighting](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/accessibility-and-arcade-working-in-color/)\n- Built-in [keyboard shortcuts](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/discover-the-arcade-editors-powerful-new-features/#keyboard-shortcuts)\n- In-editor help for finding information about profile variables relevant to your profile, documentation for constants and functions, a link to the official Arcade documentation, and, in some case, suggestions.\n- Support for many [languages and directionality](https://developers.arcgis.com/javascript/latest/localization/)","docsTags":[{"name":"superclass","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}],"encapsulation":"shadow","dependents":[],"dependencies":[],"dependencyGraph":{},"props":[{"name":"arcadeAssistant","type":"ArcadeAssistantConfig | undefined","complexType":{"original":"ArcadeAssistantConfig | undefined","resolved":"ArcadeAssistantConfig | undefined","references":{"ArcadeAssistantConfig":{"location":"local","path":"utils/arcade-assistant/types","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"enables and configures the arcade assistant @internal","docsTags":[],"values":[],"optional":true,"required":false},{"name":"customPanels","type":"ICustomPanel[] | undefined","complexType":{"original":"ICustomPanel[] | undefined","resolved":"ICustomPanel[] | undefined","references":{"ICustomPanel":{"location":"local","path":"utils/custom-panel","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"Custom panels to be displayed in the side panel.\nWill be placed below the default panels but above the help panel.","docsTags":[{"name":"internal"}],"values":[],"optional":true,"required":false},{"name":"editorOptions","type":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined","complexType":{"original":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined","resolved":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined","references":{"editor":{"location":"import","path":"monaco-editor","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"Options to update on the editor.\nFor example:\n```json\n{\n \"fontSize\": 18\n}\n```\n\nTo get the full list of available options, see the Monaco Editor options [documentation](https://microsoft.github.io/monaco-editor/typedoc/variables/editor.EditorOptions.html) for more details.","docsTags":[],"values":[],"optional":true,"required":false},{"name":"hideDocumentationActions","type":"boolean","complexType":{"original":"boolean","resolved":"boolean","references":{}},"mutable":true,"attr":"hide-documentation-actions","reflectToAttr":false,"docs":"If true, it will hide the documentation action in the side panel","docsTags":[],"default":"false","values":[{"type":"boolean"}],"optional":true,"required":false},{"name":"hideSideBar","type":"boolean","complexType":{"original":"boolean","resolved":"boolean","references":{}},"mutable":true,"attr":"hide-side-bar","reflectToAttr":false,"docs":"If true, it will hide the side actions bar. The editor will be in a minimalistic UX.","docsTags":[],"default":"false","values":[{"type":"boolean"}],"optional":true,"required":false},{"name":"openedSidePanel","type":"T extends Required<WithCustomPanels> ? SidePanelName : string","complexType":{"original":"T extends Required<WithCustomPanels> ? SidePanelName : string","resolved":"T extends Required<WithCustomPanels> ? SidePanelName : string","references":{"T":{"location":"local","id":"notImplemented"},"Required":{"location":"global","path":"global:","id":"notImplemented"},"WithCustomPanels":{"location":"local","id":"notImplemented"},"SidePanelName":{"location":"local","id":"notImplemented"}}},"mutable":true,"attr":"opened-side-panel","reflectToAttr":true,"docs":"The name of the opened side panel. 'none' means 'no panel opened'.","docsTags":[],"default":"\"none\"","values":[],"optional":true,"required":false},{"name":"profile","type":"IEditorProfileDefinition | IPredefinedProfile | undefined","complexType":{"original":"IEditorProfileDefinition | IPredefinedProfile | undefined","resolved":"IEditorProfileDefinition | IPredefinedProfile | undefined","references":{"IEditorProfileDefinition":{"location":"local","path":"utils/profile/types","id":"notImplemented"},"IPredefinedProfile":{"location":"local","path":"utils/profile/types","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"The profile contains metadata used by the editor for editing context and help.\nExample:\n```\n {\n bundles: [\"core\", \"dataAccess\", \"geometry\", \"portal-access\"],\n variables: [\n {\n name: \"$feature\",\n description: \"The feature passed to the script during execution.\",\n definition: aFeatureLayerInstance\n }\n ]\n }\n```","docsTags":[],"values":[],"optional":true,"required":false},{"name":"script","type":"string","complexType":{"original":"string","resolved":"string","references":{}},"mutable":true,"attr":"script","reflectToAttr":false,"docs":"The arcade script. Use this property to define or update the script.","docsTags":[],"default":"\"\"","values":[{"type":"string"}],"optional":true,"required":false},{"name":"sideActionBarExpanded","type":"boolean","complexType":{"original":"boolean","resolved":"boolean","references":{}},"mutable":true,"attr":"side-action-bar-expanded","reflectToAttr":true,"docs":"If true, the side action bar will be expanded","docsTags":[],"default":"false","values":[{"type":"boolean"}],"optional":true,"required":false},{"name":"snippets","type":"ApiSnippet[] | undefined","complexType":{"original":"ApiSnippet[] | undefined","resolved":"ApiSnippet[] | undefined","references":{"ApiSnippet":{"location":"import","path":"@arcgis/languages-api-utils","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"Collection of snippets","docsTags":[],"values":[],"optional":true,"required":false},{"name":"suggestions","type":"IEditorCodeSuggestion[] | IEditorCodeSuggestionGroup[] | undefined","complexType":{"original":"IEditorCodeSuggestion[] | IEditorCodeSuggestionGroup[] | undefined","resolved":"IEditorCodeSuggestion[] | IEditorCodeSuggestionGroup[] | undefined","references":{"IEditorCodeSuggestion":{"location":"local","path":"utils/editor-suggestions","id":"notImplemented"},"IEditorCodeSuggestionGroup":{"location":"local","path":"utils/editor-suggestions","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"Collection of suggestions","docsTags":[],"values":[],"optional":true,"required":false},{"name":"testData","type":"IEditorTestContext | undefined","complexType":{"original":"IEditorTestContext | undefined","resolved":"IEditorTestContext | undefined","references":{"IEditorTestContext":{"location":"local","path":"utils/arcade-executor","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"Test data used to execute the script in the editor. If undefined the execute script UX will be hidden.","docsTags":[],"values":[],"optional":true,"required":false}],"methods":[{"name":"componentOnReady","returns":{"type":"Promise<this>","docs":""},"complexType":{"signature":"(): Promise<this>","parameters":[],"return":"Promise<this>","references":{"Promise":{"location":"import","path":"typescript/lib/lib.es5.d.ts","id":"notImplemented"}}},"signature":"componentOnReady(): Promise<this>","parameters":[],"docs":"Create a promise that resolves once component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisArcadeEditor = document.querySelector(\"arcgis-arcade-editor\");\ndocument.body.append(arcgisArcadeEditor);\nawait arcgisArcadeEditor.componentOnReady();\nconsole.log(\"arcgis-arcade-editor is ready to go!\");\n```"},{"name":"inheritedFrom","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}]},{"name":"getScript","returns":{"type":"Promise<string | undefined>","docs":""},"complexType":{"signature":"(): Promise<string | undefined>","parameters":[],"return":"Promise<string | undefined>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"getScript(): Promise<string | undefined>","parameters":[],"docs":"","docsTags":[],"deprecation":"**Deprecated** since 4.30. Use `script` property instead."},{"name":"getTestResult","returns":{"type":"Promise<ArcadeResult>","docs":""},"complexType":{"signature":"(): Promise<ArcadeResult>","parameters":[],"return":"Promise<ArcadeResult>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"},"ArcadeResult":{"location":"local","path":"utils/arcade-executor","id":"notImplemented"}}},"signature":"getTestResult(): Promise<ArcadeResult>","parameters":[],"docs":"Returns the Arcade result for the script for the provided test data.","docsTags":[]},{"name":"setFocus","returns":{"type":"Promise<void>","docs":""},"complexType":{"signature":"(): Promise<void>","parameters":[],"return":"Promise<void>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"setFocus(): Promise<void>","parameters":[],"docs":"Set the focus on the element.","docsTags":[]}],"events":[{"event":"arcgisDiagnosticsChange","detail":"Diagnostic[]","bubbles":false,"complexType":{"original":"Diagnostic[]","resolved":"Diagnostic[]","references":{"Diagnostic":{"location":"import","path":"@arcgis/arcade-languageservice","id":"notImplemented"}}},"cancelable":true,"composed":true,"docs":"Emitted when the diagnostics collection has changed.","docsTags":[]},{"event":"arcgisScriptChange","detail":"string","bubbles":false,"complexType":{"original":"string","resolved":"string","references":{}},"cancelable":true,"composed":true,"docs":"Emitted when the script string has changed.","docsTags":[]}],"styles":[],"slots":[],"parts":[],"listeners":[]},{"filePath":"src/components/code-editor/code-editor.tsx","tag":"arcgis-code-editor","overview":"","readme":"","usage":{},"docs":"","docsTags":[{"name":"internal"},{"name":"superclass","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}],"encapsulation":"shadow","dependents":[],"dependencies":[],"dependencyGraph":{},"props":[{"name":"editorInstance","type":"Editor.IStandaloneCodeEditor | undefined","complexType":{"original":"Editor.IStandaloneCodeEditor | undefined","resolved":"Editor.IStandaloneCodeEditor | undefined","references":{"editor":{"location":"import","path":"monaco-editor","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"The instance of the Monaco Editor after the component has been rendered.\nTo determine when a component is rendered, you can use componentOnReady() method.\nThe method returns a Promise that resolves after the component rendered for the first time.","docsTags":[{"name":"readonly","text":""}],"values":[],"optional":true,"required":false},{"name":"editorOptions","type":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined","complexType":{"original":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined","resolved":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined","references":{"editor":{"location":"import","path":"monaco-editor","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"Options to update on the editor.\nFor example:\n```json\n{\n \"fontSize\": 18\n}\n```\n\nTo get the full list of options set on the editor, use the editorInstance property and see Monaco Editor options documentation for more details.","docsTags":[],"values":[],"optional":true,"required":false},{"name":"language","type":"string | undefined","complexType":{"original":"string | undefined","resolved":"string | undefined","references":{}},"mutable":true,"attr":"language","reflectToAttr":false,"docs":"The language for the editor.\nCurrently supported language: arcade, arcgis-sql-expression, json, css, html, javascript, typescript, and text.","docsTags":[],"values":[{"type":"string"}],"optional":true,"required":false},{"name":"modelId","type":"`${string}-${string}-${string}-${string}-${string}`","complexType":{"original":"`${string}-${string}-${string}-${string}-${string}`","resolved":"`${string}-${string}-${string}-${string}-${string}`","references":{}},"mutable":true,"attr":"model-id","reflectToAttr":false,"docs":"A unique identifier for the model.\nThe unique identifier is sometimes used by language defaults to store model metadata.\nFor example, with arcade, the model id is used to store the arcade profile and other metadata.\nThe unique identifier is especially useful when there are multiple editors on the same page.","docsTags":[],"values":[{"type":"string"}],"optional":true,"required":false},{"name":"value","type":"string","complexType":{"original":"string","resolved":"string","references":{}},"mutable":true,"attr":"value","reflectToAttr":false,"docs":"The initial value for the editor.\nThe value is the script, code, css, json, etc.","docsTags":[],"default":"\"\"","values":[{"type":"string"}],"optional":true,"required":false}],"methods":[{"name":"componentOnReady","returns":{"type":"Promise<this>","docs":""},"complexType":{"signature":"(): Promise<this>","parameters":[],"return":"Promise<this>","references":{"Promise":{"location":"import","path":"typescript/lib/lib.es5.d.ts","id":"notImplemented"}}},"signature":"componentOnReady(): Promise<this>","parameters":[],"docs":"Create a promise that resolves once component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisCodeEditor = document.querySelector(\"arcgis-code-editor\");\ndocument.body.append(arcgisCodeEditor);\nawait arcgisCodeEditor.componentOnReady();\nconsole.log(\"arcgis-code-editor is ready to go!\");\n```"},{"name":"inheritedFrom","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}]},{"name":"getValue","returns":{"type":"Promise<string>","docs":""},"complexType":{"signature":"(): Promise<string>","parameters":[],"return":"Promise<string>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"getValue(): Promise<string>","parameters":[],"docs":"","docsTags":[],"deprecation":"**Deprecated** since 4.30. Use `value` property instead."},{"name":"insertSnippet","returns":{"type":"Promise<void>","docs":""},"complexType":{"signature":"(text: string | null | undefined): Promise<void>","parameters":[{"name":"text","type":"string | null | undefined","docs":"The string snippet to insert"}],"return":"Promise<void>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"insertSnippet(text: string | null | undefined): Promise<void>","parameters":[{"name":"text","type":"string | null | undefined","docs":"The string snippet to insert"}],"docs":"Inserts a snippet at the current position in the editor.","docsTags":[]},{"name":"insertText","returns":{"type":"Promise<void>","docs":""},"complexType":{"signature":"(text: string | null | undefined): Promise<void>","parameters":[{"name":"text","type":"string | null | undefined","docs":"The string to insert"}],"return":"Promise<void>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"insertText(text: string | null | undefined): Promise<void>","parameters":[{"name":"text","type":"string | null | undefined","docs":"The string to insert"}],"docs":"Inserts a text at the current position in the editor.","docsTags":[]},{"name":"setFocus","returns":{"type":"Promise<void>","docs":""},"complexType":{"signature":"(): Promise<void>","parameters":[],"return":"Promise<void>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"setFocus(): Promise<void>","parameters":[],"docs":"Sets the focus on the editor.","docsTags":[]},{"name":"setValue","returns":{"type":"Promise<void>","docs":""},"complexType":{"signature":"(text: string | null | undefined): Promise<void>","parameters":[{"name":"text","type":"string | null | undefined","docs":""}],"return":"Promise<void>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"setValue(text: string | null | undefined): Promise<void>","parameters":[{"name":"text","type":"string | null | undefined","docs":""}],"docs":"","docsTags":[],"deprecation":"**Deprecated** since 4.30. Use `value` property instead."}],"events":[{"event":"arcgisSelectionChange","detail":"{\n selection: Selection;\n model: Editor.ITextModel | null | undefined;\n}","bubbles":false,"complexType":{"original":"{\n selection: Selection;\n model: Editor.ITextModel | null | undefined;\n}","resolved":"{\n selection: Selection;\n model: Editor.ITextModel | null | undefined;\n}","references":{"Selection":{"location":"import","path":"monaco-editor","id":"notImplemented"},"editor":{"location":"import","path":"monaco-editor","id":"notImplemented"}}},"cancelable":true,"composed":true,"docs":"Emitted when the selection has changed.","docsTags":[]},{"event":"arcgisValueChange","detail":"string","bubbles":false,"complexType":{"original":"string","resolved":"string","references":{}},"cancelable":true,"composed":true,"docs":"Emitted when the value has changed (script, code, css, json, etc.)","docsTags":[]}],"styles":[],"slots":[],"parts":[],"listeners":[]},{"filePath":"src/components/code-editor-shell/code-editor-shell.tsx","tag":"arcgis-code-editor-shell","overview":"","readme":"","usage":{},"docs":"A layout component for code editors that provides slots for an editor, results panel, side panel, and action bars.","docsTags":[{"name":"internal"},{"name":"superclass","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}],"encapsulation":"shadow","dependents":[],"dependencies":[],"dependencyGraph":{},"props":[],"methods":[{"name":"componentOnReady","returns":{"type":"Promise<this>","docs":""},"complexType":{"signature":"(): Promise<this>","parameters":[],"return":"Promise<this>","references":{"Promise":{"location":"import","path":"typescript/lib/lib.es5.d.ts","id":"notImplemented"}}},"signature":"componentOnReady(): Promise<this>","parameters":[],"docs":"Create a promise that resolves once component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst codeEditorShell = document.querySelector(\"arcgis-code-editor-shell\");\ndocument.body.append(codeEditorShell);\nawait codeEditorShell.componentOnReady();\nconsole.log(\"arcgis-code-editor-shell is ready to go!\");\n```"},{"name":"inheritedFrom","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}]}],"events":[],"styles":[{"name":"--arcgis-coding-components-border","annotation":"prop","docs":"The border style for the editor shell *"},{"name":"--arcgis-coding-components-background-color","annotation":"prop","docs":"The background color for the editor shell *"},{"name":"--arcgis-coding-components-side-action-bar-max-w","annotation":"prop","docs":"The max width for the side action bar *"},{"name":"--arcgis-coding-components-code-editor-side-panel-w","annotation":"prop","docs":"The width for the code editor side panel *"},{"name":"--arcgis-coding-components-code-editor-side-panel-max-w","annotation":"prop","docs":"The max width for the code editor side panel *"},{"name":"--arcgis-coding-components-code-editor-results-panel-max-h","annotation":"prop","docs":"The max height for the code editor results panel *"},{"name":"--arcgis-coding-components-code-editor-results-panel-h","annotation":"prop","docs":"The default height for the code editor results panel (preferred over min-h). *"}],"slots":[{"name":"top-action-bar","docs":"A slot for placing a top action bar above the editor area."},{"name":"editor","docs":"A slot for placing the main code editor component."},{"name":"results-panel","docs":"A slot for placing a results panel below the code editor."},{"name":"side-panel","docs":"A slot for placing a side panel next to the code editor area."},{"name":"side-action-bar","docs":"A slot for placing a side action bar next to the side panel."}],"parts":[],"listeners":[]},{"filePath":"src/components/code-viewer/code-viewer.tsx","tag":"arcgis-code-viewer","overview":"","readme":"","usage":{},"docs":"A code viewer component for displaying code snippets.\nSupports syntax highlighting for various programming languages, include arcade and arcgis-sql-expression.","docsTags":[{"name":"example","text":"```tsx\n<arcgis-code-viewer language=\"javascript\">\nfunction greet() {\n console.log(\"Hello, World!\");\n}\n</arcgis-code-viewer>\n```"},{"name":"example","text":"HTML snippets (preserve markup)\n```tsx\n<arcgis-code-viewer language=\"html\">\n <template>\n <div class=\"greeting\"><span>Hello</span> World!</div>\n </template>\n</arcgis-code-viewer>\n```\nWhen `language=\"html\"`, the component will attempt to preserve your original markup instead of reducing it\nto plain text. For safety and to prevent the markup from rendering in-page, wrap the snippet in a `<template>`.\nIf no `<template>` is provided, the component falls back to concatenating the `outerHTML` of element nodes and the\nraw text of text nodes. Script contents are treated as inert string data; they are never executed."},{"name":"internal"},{"name":"superclass","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}],"encapsulation":"shadow","dependents":[],"dependencies":[],"dependencyGraph":{},"props":[{"name":"language","type":"string","complexType":{"original":"string","resolved":"string","references":{}},"mutable":true,"attr":"language","reflectToAttr":false,"docs":"The language for the component.\nCurrently supported language: arcade, arcgis-sql-expression, plus all the following languages found in monaco-editor's repo:\nhttps://github.com/microsoft/monaco-editor/tree/main/src/basic-languages.\n\nNote: The number of supported languages is limited in cdn builds to reduce package size. In cdn builds,\nonly the following languages are supported: css, html, javascript, typescript, and arcade, arcgis-sql-expression.","docsTags":[],"default":"\"arcade\"","values":[{"type":"string"}],"optional":true,"required":false},{"name":"round","type":"boolean","complexType":{"original":"boolean","resolved":"boolean","references":{}},"mutable":true,"attr":"round","reflectToAttr":true,"docs":"When `true`, adds a round style to the component.","docsTags":[],"default":"false","values":[{"type":"boolean"}],"optional":true,"required":false}],"methods":[{"name":"componentOnReady","returns":{"type":"Promise<this>","docs":""},"complexType":{"signature":"(): Promise<this>","parameters":[],"return":"Promise<this>","references":{"Promise":{"location":"import","path":"typescript/lib/lib.es5.d.ts","id":"notImplemented"}}},"signature":"componentOnReady(): Promise<this>","parameters":[],"docs":"Create a promise that resolves once component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisCodeViewer = document.querySelector(\"arcgis-code-viewer\");\ndocument.body.append(arcgisCodeViewer);\nawait arcgisCodeViewer.componentOnReady();\nconsole.log(\"arcgis-code-viewer is ready to go!\");\n```"},{"name":"inheritedFrom","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}]}],"events":[],"styles":[],"slots":[],"parts":[],"listeners":[]},{"filePath":"src/components/sql-expression-editor/sql-expression-editor.tsx","tag":"arcgis-sql-expression-editor","overview":"","readme":"","usage":{},"docs":"The SQL Expression Editor provides a familiar code editor experience for writing your own SQL expressions.\nIt supports syntax highlighting, code completion, and validation, allowing users to write SQL expressions using the\n[standardized SQL functions](https://doc.arcgis.com/en/arcgis-online/reference/sql-agol.htm) supported by ArcGIS.","docsTags":[{"name":"internal"},{"name":"superclass","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}],"encapsulation":"shadow","dependents":[],"dependencies":[],"dependencyGraph":{},"props":[{"name":"hideSideBar","type":"boolean","complexType":{"original":"boolean","resolved":"boolean","references":{}},"mutable":true,"attr":"hide-side-bar","reflectToAttr":false,"docs":"If true, it will hide the side actions bar. The editor will be in a minimalistic UX.","docsTags":[{"name":"example","text":"```html\n <arcgis-sql-expression-editor hideSideBar></arcgis-sql-expression-editor>\n```"}],"default":"false","values":[{"type":"boolean"}],"optional":true,"required":false},{"name":"profile","type":"IPredefinedProfile | undefined","complexType":{"original":"IPredefinedProfile | undefined","resolved":"IPredefinedProfile | undefined","references":{"IPredefinedProfile":{"location":"local","path":"utils/profile/types","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"The profile to use for the editor. The profile defines the variables and functions that are available to the editor.","docsTags":[{"name":"example","text":"```jsx\n<arcgis-sql-expression-editor profile={id: \"field-calculation\", definitions: { $layer: layer }}></arcgis-sql-expression-editor>\n```"}],"values":[],"optional":true,"required":false},{"name":"script","type":"string","complexType":{"original":"string","resolved":"string","references":{}},"mutable":true,"attr":"script","reflectToAttr":false,"docs":"The sql expression script. Use this property to define or update the script.","docsTags":[{"name":"example","text":"```html\n<arcgis-sql-expression-editor script=\"CAST(2.45 AS INTEGER)\"></arcgis-sql-expression-editor>\n```"}],"default":"\"\"","values":[{"type":"string"}],"optional":true,"required":false}],"methods":[{"name":"componentOnReady","returns":{"type":"Promise<this>","docs":""},"complexType":{"signature":"(): Promise<this>","parameters":[],"return":"Promise<this>","references":{"Promise":{"location":"import","path":"typescript/lib/lib.es5.d.ts","id":"notImplemented"}}},"signature":"componentOnReady(): Promise<this>","parameters":[],"docs":"Create a promise that resolves once component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisSqlExpressionEditor = document.querySelector(\"arcgis-sql-expression-editor\");\ndocument.body.append(arcgisSqlExpressionEditor);\nawait arcgisSqlExpressionEditor.componentOnReady();\nconsole.log(\"arcgis-sql-expression-editor is ready to go!\");\n```"},{"name":"inheritedFrom","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}]},{"name":"setFocus","returns":{"type":"Promise<void>","docs":""},"complexType":{"signature":"(): Promise<void>","parameters":[],"return":"Promise<void>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"setFocus(): Promise<void>","parameters":[],"docs":"Set the focus on the element.","docsTags":[]}],"events":[{"event":"arcgisDiagnosticsChange","detail":"editor.IMarkerData[]","bubbles":false,"complexType":{"original":"editor.IMarkerData[]","resolved":"editor.IMarkerData[]","references":{"editor":{"location":"import","path":"monaco-editor","id":"notImplemented"}}},"cancelable":true,"composed":true,"docs":"Emitted when the diagnostics collection has changed.","docsTags":[]},{"event":"arcgisScriptChange","detail":"string","bubbles":false,"complexType":{"original":"string","resolved":"string","references":{}},"cancelable":true,"composed":true,"docs":"Emitted when the script string has changed.","docsTags":[]}],"styles":[],"slots":[],"parts":[],"listeners":[]}],"typeLibrary":{}}
1
+ {"timestamp":"2026-01-21T04:40:05","compiler":{"name":"@arcgis/lumina-compiler","version":"5.0.0-next.141","typescriptVersion":"5.9.3"},"components":[{"filePath":"src/components/arcade-editor/arcade-editor.tsx","tag":"arcgis-arcade-editor","overview":"","readme":"","usage":{},"docs":"[**Arcade**](https://developers.arcgis.com/arcade/) is a portable, and lightweight expression language used to create custom content throughout the [ArcGIS system](https://www.esri.com/en-us/arcgis/products/index).\nLike other expression languages, it can perform mathematical calculations, format text, and evaluate logical statements.\nIt also supports multi-statement expressions, variables, and flow control statements. Arcade is unique when compared to other expression and scripting languages due to its inclusion of [feature](https://developers.arcgis.com/arcade/guide/types/#feature) and [geometry](https://developers.arcgis.com/arcade/guide/types/#geometry) data types.\n\nMap Viewer (MV) was the first ArcGIS Online product to incorporate the new Arcade editor after [the editor's introduction in the November 2022 ArcGIS Online release](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/introducing-the-new-arcade-editor-in-arcgis-online/).\nThis was possible thanks to the Arcade editor component, which enabled MV to implement its own Arcade expression builder.\nYou can now also find the editor in ArcGIS Dashboards, ArcGIS Field Maps, and ArcGIS Velocity.\n\nYou can easily get your own dedicated Arcade expression builder with the **Arcade editor** component, which includes:\n\n- An easy to use [layout](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/discover-the-arcade-editors-powerful-new-features/#the-new-layout)\n- An optional minimal layout if you, for example, decide to manually exclude things such as test data, padding, line numbers, and the sidebar\n- A way to execute Arcade expressions in a configurable code editor\n- [Suggestions and code completion](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/discover-the-arcade-editors-powerful-new-features/#suggestions-and-code-completion)\n- [WCAG 2.0 compliant code colorization / syntax highlighting](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/accessibility-and-arcade-working-in-color/)\n- Built-in [keyboard shortcuts](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/discover-the-arcade-editors-powerful-new-features/#keyboard-shortcuts)\n- In-editor help for finding information about profile variables relevant to your profile, documentation for constants and functions, a link to the official Arcade documentation, and, in some case, suggestions.\n- Support for many [languages and directionality](https://developers.arcgis.com/javascript/latest/localization/)","docsTags":[{"name":"superclass","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}],"encapsulation":"shadow","dependents":[],"dependencies":[],"dependencyGraph":{},"props":[{"name":"arcadeAssistant","type":"ArcadeAssistantConfig | undefined","complexType":{"original":"ArcadeAssistantConfig | undefined","resolved":"ArcadeAssistantConfig | undefined","references":{"ArcadeAssistantConfig":{"location":"local","path":"utils/arcade-assistant/types","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"enables and configures the arcade assistant @internal","docsTags":[],"values":[],"optional":true,"required":false},{"name":"customPanels","type":"ICustomPanel[] | undefined","complexType":{"original":"ICustomPanel[] | undefined","resolved":"ICustomPanel[] | undefined","references":{"ICustomPanel":{"location":"local","path":"utils/custom-panel","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"Custom panels to be displayed in the side panel.\nWill be placed below the default panels but above the help panel.","docsTags":[{"name":"internal"}],"values":[],"optional":true,"required":false},{"name":"editorOptions","type":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined","complexType":{"original":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined","resolved":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined","references":{"editor":{"location":"import","path":"monaco-editor","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"Options to update on the editor.\nFor example:\n```json\n{\n \"fontSize\": 18\n}\n```\n\nTo get the full list of available options, see the Monaco Editor options [documentation](https://microsoft.github.io/monaco-editor/typedoc/variables/editor.EditorOptions.html) for more details.","docsTags":[],"values":[],"optional":true,"required":false},{"name":"hideDocumentationActions","type":"boolean","complexType":{"original":"boolean","resolved":"boolean","references":{}},"mutable":true,"attr":"hide-documentation-actions","reflectToAttr":false,"docs":"If true, it will hide the documentation action in the side panel","docsTags":[],"default":"false","values":[{"type":"boolean"}],"optional":true,"required":false},{"name":"hideSideBar","type":"boolean","complexType":{"original":"boolean","resolved":"boolean","references":{}},"mutable":true,"attr":"hide-side-bar","reflectToAttr":false,"docs":"If true, it will hide the side actions bar. The editor will be in a minimalistic UX.","docsTags":[],"default":"false","values":[{"type":"boolean"}],"optional":true,"required":false},{"name":"openedSidePanel","type":"T extends Required<WithCustomPanels> ? SidePanelName : string","complexType":{"original":"T extends Required<WithCustomPanels> ? SidePanelName : string","resolved":"T extends Required<WithCustomPanels> ? SidePanelName : string","references":{"T":{"location":"local","id":"notImplemented"},"Required":{"location":"global","path":"global:","id":"notImplemented"},"WithCustomPanels":{"location":"local","id":"notImplemented"},"SidePanelName":{"location":"local","id":"notImplemented"}}},"mutable":true,"attr":"opened-side-panel","reflectToAttr":true,"docs":"The name of the opened side panel. 'none' means 'no panel opened'.","docsTags":[],"default":"\"none\"","values":[],"optional":true,"required":false},{"name":"profile","type":"IEditorProfileDefinition | IPredefinedProfile | undefined","complexType":{"original":"IEditorProfileDefinition | IPredefinedProfile | undefined","resolved":"IEditorProfileDefinition | IPredefinedProfile | undefined","references":{"IEditorProfileDefinition":{"location":"local","path":"utils/profile/types","id":"notImplemented"},"IPredefinedProfile":{"location":"local","path":"utils/profile/types","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"The profile contains metadata used by the editor for editing context and help.\nExample:\n```\n {\n bundles: [\"core\", \"dataAccess\", \"geometry\", \"portal-access\"],\n variables: [\n {\n name: \"$feature\",\n description: \"The feature passed to the script during execution.\",\n definition: aFeatureLayerInstance\n }\n ]\n }\n```","docsTags":[],"values":[],"optional":true,"required":false},{"name":"script","type":"string","complexType":{"original":"string","resolved":"string","references":{}},"mutable":true,"attr":"script","reflectToAttr":false,"docs":"The arcade script. Use this property to define or update the script.","docsTags":[],"default":"\"\"","values":[{"type":"string"}],"optional":true,"required":false},{"name":"sideActionBarExpanded","type":"boolean","complexType":{"original":"boolean","resolved":"boolean","references":{}},"mutable":true,"attr":"side-action-bar-expanded","reflectToAttr":true,"docs":"If true, the side action bar will be expanded","docsTags":[],"default":"false","values":[{"type":"boolean"}],"optional":true,"required":false},{"name":"snippets","type":"ApiSnippet[] | undefined","complexType":{"original":"ApiSnippet[] | undefined","resolved":"ApiSnippet[] | undefined","references":{"ApiSnippet":{"location":"import","path":"@arcgis/languages-api-utils","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"Collection of snippets","docsTags":[],"values":[],"optional":true,"required":false},{"name":"suggestions","type":"IEditorCodeSuggestion[] | IEditorCodeSuggestionGroup[] | undefined","complexType":{"original":"IEditorCodeSuggestion[] | IEditorCodeSuggestionGroup[] | undefined","resolved":"IEditorCodeSuggestion[] | IEditorCodeSuggestionGroup[] | undefined","references":{"IEditorCodeSuggestion":{"location":"local","path":"utils/editor-suggestions","id":"notImplemented"},"IEditorCodeSuggestionGroup":{"location":"local","path":"utils/editor-suggestions","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"Collection of suggestions","docsTags":[],"values":[],"optional":true,"required":false},{"name":"testData","type":"IEditorTestContext | undefined","complexType":{"original":"IEditorTestContext | undefined","resolved":"IEditorTestContext | undefined","references":{"IEditorTestContext":{"location":"local","path":"utils/arcade-executor","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"Test data used to execute the script in the editor. If undefined the execute script UX will be hidden.","docsTags":[],"values":[],"optional":true,"required":false}],"methods":[{"name":"componentOnReady","returns":{"type":"Promise<this>","docs":""},"complexType":{"signature":"(): Promise<this>","parameters":[],"return":"Promise<this>","references":{"Promise":{"location":"import","path":"typescript/lib/lib.es5.d.ts","id":"notImplemented"}}},"signature":"componentOnReady(): Promise<this>","parameters":[],"docs":"Create a promise that resolves once component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisArcadeEditor = document.querySelector(\"arcgis-arcade-editor\");\ndocument.body.append(arcgisArcadeEditor);\nawait arcgisArcadeEditor.componentOnReady();\nconsole.log(\"arcgis-arcade-editor is ready to go!\");\n```"},{"name":"inheritedFrom","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}]},{"name":"getScript","returns":{"type":"Promise<string | undefined>","docs":""},"complexType":{"signature":"(): Promise<string | undefined>","parameters":[],"return":"Promise<string | undefined>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"getScript(): Promise<string | undefined>","parameters":[],"docs":"","docsTags":[],"deprecation":"**Deprecated** since 4.30. Use `script` property instead."},{"name":"getTestResult","returns":{"type":"Promise<ArcadeResult>","docs":""},"complexType":{"signature":"(): Promise<ArcadeResult>","parameters":[],"return":"Promise<ArcadeResult>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"},"ArcadeResult":{"location":"local","path":"utils/arcade-executor","id":"notImplemented"}}},"signature":"getTestResult(): Promise<ArcadeResult>","parameters":[],"docs":"Returns the Arcade result for the script for the provided test data.","docsTags":[]},{"name":"setFocus","returns":{"type":"Promise<void>","docs":""},"complexType":{"signature":"(): Promise<void>","parameters":[],"return":"Promise<void>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"setFocus(): Promise<void>","parameters":[],"docs":"Set the focus on the element.","docsTags":[]}],"events":[{"event":"arcgisDiagnosticsChange","detail":"Diagnostic[]","bubbles":false,"complexType":{"original":"Diagnostic[]","resolved":"Diagnostic[]","references":{"Diagnostic":{"location":"import","path":"@arcgis/arcade-languageservice","id":"notImplemented"}}},"cancelable":true,"composed":true,"docs":"Emitted when the diagnostics collection has changed.","docsTags":[]},{"event":"arcgisScriptChange","detail":"string","bubbles":false,"complexType":{"original":"string","resolved":"string","references":{}},"cancelable":true,"composed":true,"docs":"Emitted when the script string has changed.","docsTags":[]}],"styles":[],"slots":[],"parts":[],"listeners":[]},{"filePath":"src/components/code-editor/code-editor.tsx","tag":"arcgis-code-editor","overview":"","readme":"","usage":{},"docs":"","docsTags":[{"name":"internal"},{"name":"superclass","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}],"encapsulation":"shadow","dependents":[],"dependencies":[],"dependencyGraph":{},"props":[{"name":"editorInstance","type":"Editor.IStandaloneCodeEditor | undefined","complexType":{"original":"Editor.IStandaloneCodeEditor | undefined","resolved":"Editor.IStandaloneCodeEditor | undefined","references":{"editor":{"location":"import","path":"monaco-editor","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"The instance of the Monaco Editor after the component has been rendered.\nTo determine when a component is rendered, you can use componentOnReady() method.\nThe method returns a Promise that resolves after the component rendered for the first time.","docsTags":[{"name":"readonly","text":""}],"values":[],"optional":true,"required":false},{"name":"editorOptions","type":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined","complexType":{"original":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined","resolved":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined","references":{"editor":{"location":"import","path":"monaco-editor","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"Options to update on the editor.\nFor example:\n```json\n{\n \"fontSize\": 18\n}\n```\n\nTo get the full list of options set on the editor, use the editorInstance property and see Monaco Editor options documentation for more details.","docsTags":[],"values":[],"optional":true,"required":false},{"name":"language","type":"string | undefined","complexType":{"original":"string | undefined","resolved":"string | undefined","references":{}},"mutable":true,"attr":"language","reflectToAttr":false,"docs":"The language for the editor.\nCurrently supported language: arcade, arcgis-sql-expression, json, css, html, javascript, typescript, and text.","docsTags":[],"values":[{"type":"string"}],"optional":true,"required":false},{"name":"modelId","type":"`${string}-${string}-${string}-${string}-${string}`","complexType":{"original":"`${string}-${string}-${string}-${string}-${string}`","resolved":"`${string}-${string}-${string}-${string}-${string}`","references":{}},"mutable":true,"attr":"model-id","reflectToAttr":false,"docs":"A unique identifier for the model.\nThe unique identifier is sometimes used by language defaults to store model metadata.\nFor example, with arcade, the model id is used to store the arcade profile and other metadata.\nThe unique identifier is especially useful when there are multiple editors on the same page.","docsTags":[],"values":[{"type":"string"}],"optional":true,"required":false},{"name":"value","type":"string","complexType":{"original":"string","resolved":"string","references":{}},"mutable":true,"attr":"value","reflectToAttr":false,"docs":"The initial value for the editor.\nThe value is the script, code, css, json, etc.","docsTags":[],"default":"\"\"","values":[{"type":"string"}],"optional":true,"required":false}],"methods":[{"name":"componentOnReady","returns":{"type":"Promise<this>","docs":""},"complexType":{"signature":"(): Promise<this>","parameters":[],"return":"Promise<this>","references":{"Promise":{"location":"import","path":"typescript/lib/lib.es5.d.ts","id":"notImplemented"}}},"signature":"componentOnReady(): Promise<this>","parameters":[],"docs":"Create a promise that resolves once component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisCodeEditor = document.querySelector(\"arcgis-code-editor\");\ndocument.body.append(arcgisCodeEditor);\nawait arcgisCodeEditor.componentOnReady();\nconsole.log(\"arcgis-code-editor is ready to go!\");\n```"},{"name":"inheritedFrom","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}]},{"name":"getValue","returns":{"type":"Promise<string>","docs":""},"complexType":{"signature":"(): Promise<string>","parameters":[],"return":"Promise<string>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"getValue(): Promise<string>","parameters":[],"docs":"","docsTags":[],"deprecation":"**Deprecated** since 4.30. Use `value` property instead."},{"name":"insertSnippet","returns":{"type":"Promise<void>","docs":""},"complexType":{"signature":"(text: string | null | undefined): Promise<void>","parameters":[{"name":"text","type":"string | null | undefined","docs":"The string snippet to insert"}],"return":"Promise<void>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"insertSnippet(text: string | null | undefined): Promise<void>","parameters":[{"name":"text","type":"string | null | undefined","docs":"The string snippet to insert"}],"docs":"Inserts a snippet at the current position in the editor.","docsTags":[]},{"name":"insertText","returns":{"type":"Promise<void>","docs":""},"complexType":{"signature":"(text: string | null | undefined): Promise<void>","parameters":[{"name":"text","type":"string | null | undefined","docs":"The string to insert"}],"return":"Promise<void>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"insertText(text: string | null | undefined): Promise<void>","parameters":[{"name":"text","type":"string | null | undefined","docs":"The string to insert"}],"docs":"Inserts a text at the current position in the editor.","docsTags":[]},{"name":"setFocus","returns":{"type":"Promise<void>","docs":""},"complexType":{"signature":"(): Promise<void>","parameters":[],"return":"Promise<void>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"setFocus(): Promise<void>","parameters":[],"docs":"Sets the focus on the editor.","docsTags":[]},{"name":"setValue","returns":{"type":"Promise<void>","docs":""},"complexType":{"signature":"(text: string | null | undefined): Promise<void>","parameters":[{"name":"text","type":"string | null | undefined","docs":""}],"return":"Promise<void>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"setValue(text: string | null | undefined): Promise<void>","parameters":[{"name":"text","type":"string | null | undefined","docs":""}],"docs":"","docsTags":[],"deprecation":"**Deprecated** since 4.30. Use `value` property instead."}],"events":[{"event":"arcgisSelectionChange","detail":"{\n selection: Selection;\n model: Editor.ITextModel | null | undefined;\n}","bubbles":false,"complexType":{"original":"{\n selection: Selection;\n model: Editor.ITextModel | null | undefined;\n}","resolved":"{\n selection: Selection;\n model: Editor.ITextModel | null | undefined;\n}","references":{"Selection":{"location":"import","path":"monaco-editor","id":"notImplemented"},"editor":{"location":"import","path":"monaco-editor","id":"notImplemented"}}},"cancelable":true,"composed":true,"docs":"Emitted when the selection has changed.","docsTags":[]},{"event":"arcgisValueChange","detail":"string","bubbles":false,"complexType":{"original":"string","resolved":"string","references":{}},"cancelable":true,"composed":true,"docs":"Emitted when the value has changed (script, code, css, json, etc.)","docsTags":[]}],"styles":[],"slots":[],"parts":[],"listeners":[]},{"filePath":"src/components/code-editor-shell/code-editor-shell.tsx","tag":"arcgis-code-editor-shell","overview":"","readme":"","usage":{},"docs":"A layout component for code editors that provides slots for an editor, results panel, side panel, and action bars.","docsTags":[{"name":"internal"},{"name":"superclass","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}],"encapsulation":"shadow","dependents":[],"dependencies":[],"dependencyGraph":{},"props":[],"methods":[{"name":"componentOnReady","returns":{"type":"Promise<this>","docs":""},"complexType":{"signature":"(): Promise<this>","parameters":[],"return":"Promise<this>","references":{"Promise":{"location":"import","path":"typescript/lib/lib.es5.d.ts","id":"notImplemented"}}},"signature":"componentOnReady(): Promise<this>","parameters":[],"docs":"Create a promise that resolves once component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst codeEditorShell = document.querySelector(\"arcgis-code-editor-shell\");\ndocument.body.append(codeEditorShell);\nawait codeEditorShell.componentOnReady();\nconsole.log(\"arcgis-code-editor-shell is ready to go!\");\n```"},{"name":"inheritedFrom","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}]}],"events":[],"styles":[{"name":"--arcgis-coding-components-border","annotation":"prop","docs":"The border style for the editor shell *"},{"name":"--arcgis-coding-components-background-color","annotation":"prop","docs":"The background color for the editor shell *"},{"name":"--arcgis-coding-components-side-action-bar-max-w","annotation":"prop","docs":"The max width for the side action bar *"},{"name":"--arcgis-coding-components-code-editor-side-panel-w","annotation":"prop","docs":"The width for the code editor side panel *"},{"name":"--arcgis-coding-components-code-editor-side-panel-max-w","annotation":"prop","docs":"The max width for the code editor side panel *"},{"name":"--arcgis-coding-components-code-editor-results-panel-max-h","annotation":"prop","docs":"The max height for the code editor results panel *"},{"name":"--arcgis-coding-components-code-editor-results-panel-h","annotation":"prop","docs":"The default height for the code editor results panel (preferred over min-h). *"}],"slots":[{"name":"top-action-bar","docs":"A slot for placing a top action bar above the editor area."},{"name":"editor","docs":"A slot for placing the main code editor component."},{"name":"results-panel","docs":"A slot for placing a results panel below the code editor."},{"name":"side-panel","docs":"A slot for placing a side panel next to the code editor area."},{"name":"side-action-bar","docs":"A slot for placing a side action bar next to the side panel."}],"parts":[],"listeners":[]},{"filePath":"src/components/code-viewer/code-viewer.tsx","tag":"arcgis-code-viewer","overview":"","readme":"","usage":{},"docs":"A code viewer component for displaying code snippets.\nSupports syntax highlighting for various programming languages, include arcade and arcgis-sql-expression.","docsTags":[{"name":"example","text":"```tsx\n<arcgis-code-viewer language=\"javascript\">\nfunction greet() {\n console.log(\"Hello, World!\");\n}\n</arcgis-code-viewer>\n```"},{"name":"example","text":"HTML snippets (preserve markup)\n```tsx\n<arcgis-code-viewer language=\"html\">\n <template>\n <div class=\"greeting\"><span>Hello</span> World!</div>\n </template>\n</arcgis-code-viewer>\n```\nWhen `language=\"html\"`, the component will attempt to preserve your original markup instead of reducing it\nto plain text. For safety and to prevent the markup from rendering in-page, wrap the snippet in a `<template>`.\nIf no `<template>` is provided, the component falls back to concatenating the `outerHTML` of element nodes and the\nraw text of text nodes. Script contents are treated as inert string data; they are never executed."},{"name":"internal"},{"name":"superclass","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}],"encapsulation":"shadow","dependents":[],"dependencies":[],"dependencyGraph":{},"props":[{"name":"language","type":"string","complexType":{"original":"string","resolved":"string","references":{}},"mutable":true,"attr":"language","reflectToAttr":false,"docs":"The language for the component.\nCurrently supported language: arcade, arcgis-sql-expression, plus all the following languages found in monaco-editor's repo:\nhttps://github.com/microsoft/monaco-editor/tree/main/src/basic-languages.\n\nNote: The number of supported languages is limited in cdn builds to reduce package size. In cdn builds,\nonly the following languages are supported: css, html, javascript, typescript, and arcade, arcgis-sql-expression.","docsTags":[],"default":"\"arcade\"","values":[{"type":"string"}],"optional":true,"required":false},{"name":"round","type":"boolean","complexType":{"original":"boolean","resolved":"boolean","references":{}},"mutable":true,"attr":"round","reflectToAttr":true,"docs":"When `true`, adds a round style to the component.","docsTags":[],"default":"false","values":[{"type":"boolean"}],"optional":true,"required":false}],"methods":[{"name":"componentOnReady","returns":{"type":"Promise<this>","docs":""},"complexType":{"signature":"(): Promise<this>","parameters":[],"return":"Promise<this>","references":{"Promise":{"location":"import","path":"typescript/lib/lib.es5.d.ts","id":"notImplemented"}}},"signature":"componentOnReady(): Promise<this>","parameters":[],"docs":"Create a promise that resolves once component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisCodeViewer = document.querySelector(\"arcgis-code-viewer\");\ndocument.body.append(arcgisCodeViewer);\nawait arcgisCodeViewer.componentOnReady();\nconsole.log(\"arcgis-code-viewer is ready to go!\");\n```"},{"name":"inheritedFrom","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}]}],"events":[],"styles":[],"slots":[],"parts":[],"listeners":[]},{"filePath":"src/components/sql-expression-editor/sql-expression-editor.tsx","tag":"arcgis-sql-expression-editor","overview":"","readme":"","usage":{},"docs":"The SQL Expression Editor provides a familiar code editor experience for writing your own SQL expressions.\nIt supports syntax highlighting, code completion, and validation, allowing users to write SQL expressions using the\n[standardized SQL functions](https://doc.arcgis.com/en/arcgis-online/reference/sql-agol.htm) supported by ArcGIS.","docsTags":[{"name":"internal"},{"name":"superclass","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}],"encapsulation":"shadow","dependents":[],"dependencies":[],"dependencyGraph":{},"props":[{"name":"hideSideBar","type":"boolean","complexType":{"original":"boolean","resolved":"boolean","references":{}},"mutable":true,"attr":"hide-side-bar","reflectToAttr":false,"docs":"If true, it will hide the side actions bar. The editor will be in a minimalistic UX.","docsTags":[{"name":"example","text":"```html\n <arcgis-sql-expression-editor hideSideBar></arcgis-sql-expression-editor>\n```"}],"default":"false","values":[{"type":"boolean"}],"optional":true,"required":false},{"name":"profile","type":"IPredefinedProfile | undefined","complexType":{"original":"IPredefinedProfile | undefined","resolved":"IPredefinedProfile | undefined","references":{"IPredefinedProfile":{"location":"local","path":"utils/profile/types","id":"notImplemented"}}},"mutable":true,"reflectToAttr":false,"docs":"The profile to use for the editor. The profile defines the variables and functions that are available to the editor.","docsTags":[{"name":"example","text":"```jsx\n<arcgis-sql-expression-editor profile={id: \"field-calculation\", definitions: { $layer: layer }}></arcgis-sql-expression-editor>\n```"}],"values":[],"optional":true,"required":false},{"name":"script","type":"string","complexType":{"original":"string","resolved":"string","references":{}},"mutable":true,"attr":"script","reflectToAttr":false,"docs":"The sql expression script. Use this property to define or update the script.","docsTags":[{"name":"example","text":"```html\n<arcgis-sql-expression-editor script=\"CAST(2.45 AS INTEGER)\"></arcgis-sql-expression-editor>\n```"}],"default":"\"\"","values":[{"type":"string"}],"optional":true,"required":false}],"methods":[{"name":"componentOnReady","returns":{"type":"Promise<this>","docs":""},"complexType":{"signature":"(): Promise<this>","parameters":[],"return":"Promise<this>","references":{"Promise":{"location":"import","path":"typescript/lib/lib.es5.d.ts","id":"notImplemented"}}},"signature":"componentOnReady(): Promise<this>","parameters":[],"docs":"Create a promise that resolves once component is fully loaded.","docsTags":[{"name":"example","text":"```js\nconst arcgisSqlExpressionEditor = document.querySelector(\"arcgis-sql-expression-editor\");\ndocument.body.append(arcgisSqlExpressionEditor);\nawait arcgisSqlExpressionEditor.componentOnReady();\nconsole.log(\"arcgis-sql-expression-editor is ready to go!\");\n```"},{"name":"inheritedFrom","text":"{\"name\":\"PublicLitElement\",\"module\":\"PublicLitElement\",\"package\":\"@arcgis/lumina\"}"}]},{"name":"setFocus","returns":{"type":"Promise<void>","docs":""},"complexType":{"signature":"(): Promise<void>","parameters":[],"return":"Promise<void>","references":{"Promise":{"location":"global","path":"global:","id":"notImplemented"}}},"signature":"setFocus(): Promise<void>","parameters":[],"docs":"Set the focus on the element.","docsTags":[]}],"events":[{"event":"arcgisDiagnosticsChange","detail":"editor.IMarkerData[]","bubbles":false,"complexType":{"original":"editor.IMarkerData[]","resolved":"editor.IMarkerData[]","references":{"editor":{"location":"import","path":"monaco-editor","id":"notImplemented"}}},"cancelable":true,"composed":true,"docs":"Emitted when the diagnostics collection has changed.","docsTags":[]},{"event":"arcgisScriptChange","detail":"string","bubbles":false,"complexType":{"original":"string","resolved":"string","references":{}},"cancelable":true,"composed":true,"docs":"Emitted when the script string has changed.","docsTags":[]}],"styles":[],"slots":[],"parts":[],"listeners":[]}],"typeLibrary":{}}
@@ -1 +1 @@
1
- {"$schema":"https://raw.githubusercontent.com/JetBrains/web-types/master/schema/web-types.json","name":"@arcgis/coding-components","version":"5.0.0-next.140","description-markup":"markdown","contributions":{"html":{"elements":[{"name":"arcgis-arcade-editor","description":"[**Arcade**](https://developers.arcgis.com/arcade/) is a portable, and lightweight expression language used to create custom content throughout the [ArcGIS system](https://www.esri.com/en-us/arcgis/products/index).\nLike other expression languages, it can perform mathematical calculations, format text, and evaluate logical statements.\nIt also supports multi-statement expressions, variables, and flow control statements. Arcade is unique when compared to other expression and scripting languages due to its inclusion of [feature](https://developers.arcgis.com/arcade/guide/types/#feature) and [geometry](https://developers.arcgis.com/arcade/guide/types/#geometry) data types.\n\nMap Viewer (MV) was the first ArcGIS Online product to incorporate the new Arcade editor after [the editor's introduction in the November 2022 ArcGIS Online release](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/introducing-the-new-arcade-editor-in-arcgis-online/).\nThis was possible thanks to the Arcade editor component, which enabled MV to implement its own Arcade expression builder.\nYou can now also find the editor in ArcGIS Dashboards, ArcGIS Field Maps, and ArcGIS Velocity.\n\nYou can easily get your own dedicated Arcade expression builder with the **Arcade editor** component, which includes:\n\n- An easy to use [layout](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/discover-the-arcade-editors-powerful-new-features/#the-new-layout)\n- An optional minimal layout if you, for example, decide to manually exclude things such as test data, padding, line numbers, and the sidebar\n- A way to execute Arcade expressions in a configurable code editor\n- [Suggestions and code completion](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/discover-the-arcade-editors-powerful-new-features/#suggestions-and-code-completion)\n- [WCAG 2.0 compliant code colorization / syntax highlighting](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/accessibility-and-arcade-working-in-color/)\n- Built-in [keyboard shortcuts](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/discover-the-arcade-editors-powerful-new-features/#keyboard-shortcuts)\n- In-editor help for finding information about profile variables relevant to your profile, documentation for constants and functions, a link to the official Arcade documentation, and, in some case, suggestions.\n- Support for many [languages and directionality](https://developers.arcgis.com/javascript/latest/localization/)\n--\n\n### Events\n- **arcgisDiagnosticsChange** - Emitted when the diagnostics collection has changed.\n- **arcgisScriptChange** - Emitted when the script string has changed.\n\n### Methods\n- `componentOnReady(): Promise<this>` - Create a promise that resolves once component is fully loaded.\n- `getScript(): Promise<string | undefined>` - **Deprecated**: **Deprecated** since 4.30. Use `script` property instead.. \n- `getTestResult(): Promise<ArcadeResult>` - Returns the Arcade result for the script for the provided test data.\n- `setFocus(): Promise<void>` - Set the focus on the element.","doc-url":"https://developers.arcgis.com/javascript/latest/references/coding-components/arcgis-arcade-editor/","attributes":[{"name":"hide-documentation-actions","description":"If true, it will hide the documentation action in the side panel","default":"false","value":{"type":"boolean"}},{"name":"hide-side-bar","description":"If true, it will hide the side actions bar. The editor will be in a minimalistic UX.","default":"false","value":{"type":"boolean"}},{"name":"opened-side-panel","description":"The name of the opened side panel. 'none' means 'no panel opened'.","default":"\"none\"","value":{}},{"name":"script","description":"The arcade script. Use this property to define or update the script.","default":"\"\"","value":{"type":"string"}},{"name":"side-action-bar-expanded","description":"If true, the side action bar will be expanded","default":"false","value":{"type":"boolean"}}],"events":[{"name":"arcgisDiagnosticsChange","type":"Diagnostic[]","description":"Emitted when the diagnostics collection has changed."},{"name":"arcgisScriptChange","type":"string","description":"Emitted when the script string has changed."}],"js":{"properties":[{"name":"arcadeAssistant","description":"enables and configures the arcade assistant @internal","type":"ArcadeAssistantConfig | undefined"},{"name":"customPanels","description":"Custom panels to be displayed in the side panel.\nWill be placed below the default panels but above the help panel.","type":"ICustomPanel[] | undefined"},{"name":"editorOptions","description":"Options to update on the editor.\nFor example:\n```json\n{\n \"fontSize\": 18\n}\n```\n\nTo get the full list of available options, see the Monaco Editor options [documentation](https://microsoft.github.io/monaco-editor/typedoc/variables/editor.EditorOptions.html) for more details.","type":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined"},{"name":"hideDocumentationActions","description":"If true, it will hide the documentation action in the side panel","type":"boolean"},{"name":"hideSideBar","description":"If true, it will hide the side actions bar. The editor will be in a minimalistic UX.","type":"boolean"},{"name":"openedSidePanel","description":"The name of the opened side panel. 'none' means 'no panel opened'.","type":"T extends Required<WithCustomPanels> ? SidePanelName : string"},{"name":"profile","description":"The profile contains metadata used by the editor for editing context and help.\nExample:\n```\n {\n bundles: [\"core\", \"dataAccess\", \"geometry\", \"portal-access\"],\n variables: [\n {\n name: \"$feature\",\n description: \"The feature passed to the script during execution.\",\n definition: aFeatureLayerInstance\n }\n ]\n }\n```","type":"IEditorProfileDefinition | IPredefinedProfile | undefined"},{"name":"script","description":"The arcade script. Use this property to define or update the script.","type":"string"},{"name":"sideActionBarExpanded","description":"If true, the side action bar will be expanded","type":"boolean"},{"name":"snippets","description":"Collection of snippets","type":"ApiSnippet[] | undefined"},{"name":"suggestions","description":"Collection of suggestions","type":"IEditorCodeSuggestion[] | IEditorCodeSuggestionGroup[] | undefined"},{"name":"testData","description":"Test data used to execute the script in the editor. If undefined the execute script UX will be hidden.","type":"IEditorTestContext | undefined"}],"events":[{"name":"arcgisDiagnosticsChange","type":"Diagnostic[]","description":"Emitted when the diagnostics collection has changed."},{"name":"arcgisScriptChange","type":"string","description":"Emitted when the script string has changed."}]}},{"name":"arcgis-code-editor","description":"### Events\n- **arcgisSelectionChange** - Emitted when the selection has changed.\n- **arcgisValueChange** - Emitted when the value has changed (script, code, css, json, etc.)\n\n### Methods\n- `componentOnReady(): Promise<this>` - Create a promise that resolves once component is fully loaded.\n- `getValue(): Promise<string>` - **Deprecated**: **Deprecated** since 4.30. Use `value` property instead.. \n- `insertSnippet(text: string | null | undefined): Promise<void>` - Inserts a snippet at the current position in the editor.\n- `insertText(text: string | null | undefined): Promise<void>` - Inserts a text at the current position in the editor.\n- `setFocus(): Promise<void>` - Sets the focus on the editor.\n- `setValue(text: string | null | undefined): Promise<void>` - **Deprecated**: **Deprecated** since 4.30. Use `value` property instead.. ","doc-url":"https://developers.arcgis.com/javascript/latest/references/coding-components/arcgis-code-editor/","attributes":[{"name":"language","description":"The language for the editor.\nCurrently supported language: arcade, arcgis-sql-expression, json, css, html, javascript, typescript, and text.","value":{"type":"string"}},{"name":"model-id","description":"A unique identifier for the model.\nThe unique identifier is sometimes used by language defaults to store model metadata.\nFor example, with arcade, the model id is used to store the arcade profile and other metadata.\nThe unique identifier is especially useful when there are multiple editors on the same page.","value":{"type":"string"}},{"name":"value","description":"The initial value for the editor.\nThe value is the script, code, css, json, etc.","default":"\"\"","value":{"type":"string"}}],"events":[{"name":"arcgisSelectionChange","type":"{\n selection: Selection;\n model: Editor.ITextModel | null | undefined;\n}","description":"Emitted when the selection has changed."},{"name":"arcgisValueChange","type":"string","description":"Emitted when the value has changed (script, code, css, json, etc.)"}],"js":{"properties":[{"name":"editorInstance","description":"The instance of the Monaco Editor after the component has been rendered.\nTo determine when a component is rendered, you can use componentOnReady() method.\nThe method returns a Promise that resolves after the component rendered for the first time.","type":"Editor.IStandaloneCodeEditor | undefined"},{"name":"editorOptions","description":"Options to update on the editor.\nFor example:\n```json\n{\n \"fontSize\": 18\n}\n```\n\nTo get the full list of options set on the editor, use the editorInstance property and see Monaco Editor options documentation for more details.","type":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined"},{"name":"language","description":"The language for the editor.\nCurrently supported language: arcade, arcgis-sql-expression, json, css, html, javascript, typescript, and text.","type":"string | undefined"},{"name":"modelId","description":"A unique identifier for the model.\nThe unique identifier is sometimes used by language defaults to store model metadata.\nFor example, with arcade, the model id is used to store the arcade profile and other metadata.\nThe unique identifier is especially useful when there are multiple editors on the same page.","type":"`${string}-${string}-${string}-${string}-${string}`"},{"name":"value","description":"The initial value for the editor.\nThe value is the script, code, css, json, etc.","type":"string"}],"events":[{"name":"arcgisSelectionChange","type":"{\n selection: Selection;\n model: Editor.ITextModel | null | undefined;\n}","description":"Emitted when the selection has changed."},{"name":"arcgisValueChange","type":"string","description":"Emitted when the value has changed (script, code, css, json, etc.)"}]}},{"name":"arcgis-code-editor-shell","description":"A layout component for code editors that provides slots for an editor, results panel, side panel, and action bars.\n--\n\n### Methods\n- `componentOnReady(): Promise<this>` - Create a promise that resolves once component is fully loaded.\n\n### Slots\n- **top-action-bar** - A slot for placing a top action bar above the editor area.\n- **editor** - A slot for placing the main code editor component.\n- **results-panel** - A slot for placing a results panel below the code editor.\n- **side-panel** - A slot for placing a side panel next to the code editor area.\n- **side-action-bar** - A slot for placing a side action bar next to the side panel.\n\n### CSS Properties\n- **--arcgis-coding-components-border** - The border style for the editor shell * \n- **--arcgis-coding-components-background-color** - The background color for the editor shell * \n- **--arcgis-coding-components-side-action-bar-max-w** - The max width for the side action bar * \n- **--arcgis-coding-components-code-editor-side-panel-w** - The width for the code editor side panel * \n- **--arcgis-coding-components-code-editor-side-panel-max-w** - The max width for the code editor side panel * \n- **--arcgis-coding-components-code-editor-results-panel-max-h** - The max height for the code editor results panel * \n- **--arcgis-coding-components-code-editor-results-panel-h** - The default height for the code editor results panel (preferred over min-h). * ","doc-url":"https://developers.arcgis.com/javascript/latest/references/coding-components/arcgis-code-editor-shell/","attributes":[],"slots":[{"name":"top-action-bar","description":"A slot for placing a top action bar above the editor area."},{"name":"editor","description":"A slot for placing the main code editor component."},{"name":"results-panel","description":"A slot for placing a results panel below the code editor."},{"name":"side-panel","description":"A slot for placing a side panel next to the code editor area."},{"name":"side-action-bar","description":"A slot for placing a side action bar next to the side panel."}],"events":[],"js":{"properties":[],"events":[]}},{"name":"arcgis-code-viewer","description":"A code viewer component for displaying code snippets.\nSupports syntax highlighting for various programming languages, include arcade and arcgis-sql-expression.\n--\n\n### Methods\n- `componentOnReady(): Promise<this>` - Create a promise that resolves once component is fully loaded.","doc-url":"https://developers.arcgis.com/javascript/latest/references/coding-components/arcgis-code-viewer/","attributes":[{"name":"language","description":"The language for the component.\nCurrently supported language: arcade, arcgis-sql-expression, plus all the following languages found in monaco-editor's repo:\nhttps://github.com/microsoft/monaco-editor/tree/main/src/basic-languages.\n\nNote: The number of supported languages is limited in cdn builds to reduce package size. In cdn builds,\nonly the following languages are supported: css, html, javascript, typescript, and arcade, arcgis-sql-expression.","default":"\"arcade\"","value":{"type":"string"}},{"name":"round","description":"When `true`, adds a round style to the component.","default":"false","value":{"type":"boolean"}}],"events":[],"js":{"properties":[{"name":"language","description":"The language for the component.\nCurrently supported language: arcade, arcgis-sql-expression, plus all the following languages found in monaco-editor's repo:\nhttps://github.com/microsoft/monaco-editor/tree/main/src/basic-languages.\n\nNote: The number of supported languages is limited in cdn builds to reduce package size. In cdn builds,\nonly the following languages are supported: css, html, javascript, typescript, and arcade, arcgis-sql-expression.","type":"string"},{"name":"round","description":"When `true`, adds a round style to the component.","type":"boolean"}],"events":[]}},{"name":"arcgis-sql-expression-editor","description":"The SQL Expression Editor provides a familiar code editor experience for writing your own SQL expressions.\nIt supports syntax highlighting, code completion, and validation, allowing users to write SQL expressions using the\n[standardized SQL functions](https://doc.arcgis.com/en/arcgis-online/reference/sql-agol.htm) supported by ArcGIS.\n--\n\n### Events\n- **arcgisDiagnosticsChange** - Emitted when the diagnostics collection has changed.\n- **arcgisScriptChange** - Emitted when the script string has changed.\n\n### Methods\n- `componentOnReady(): Promise<this>` - Create a promise that resolves once component is fully loaded.\n- `setFocus(): Promise<void>` - Set the focus on the element.","doc-url":"https://developers.arcgis.com/javascript/latest/references/coding-components/arcgis-sql-expression-editor/","attributes":[{"name":"hide-side-bar","description":"If true, it will hide the side actions bar. The editor will be in a minimalistic UX.","default":"false","value":{"type":"boolean"}},{"name":"script","description":"The sql expression script. Use this property to define or update the script.","default":"\"\"","value":{"type":"string"}}],"events":[{"name":"arcgisDiagnosticsChange","type":"editor.IMarkerData[]","description":"Emitted when the diagnostics collection has changed."},{"name":"arcgisScriptChange","type":"string","description":"Emitted when the script string has changed."}],"js":{"properties":[{"name":"hideSideBar","description":"If true, it will hide the side actions bar. The editor will be in a minimalistic UX.","type":"boolean"},{"name":"profile","description":"The profile to use for the editor. The profile defines the variables and functions that are available to the editor.","type":"IPredefinedProfile | undefined"},{"name":"script","description":"The sql expression script. Use this property to define or update the script.","type":"string"}],"events":[{"name":"arcgisDiagnosticsChange","type":"editor.IMarkerData[]","description":"Emitted when the diagnostics collection has changed."},{"name":"arcgisScriptChange","type":"string","description":"Emitted when the script string has changed."}]}}]},"css":{"properties":[{"name":"--arcgis-coding-components-border","description":"The border style for the editor shell *"},{"name":"--arcgis-coding-components-background-color","description":"The background color for the editor shell *"},{"name":"--arcgis-coding-components-side-action-bar-max-w","description":"The max width for the side action bar *"},{"name":"--arcgis-coding-components-code-editor-side-panel-w","description":"The width for the code editor side panel *"},{"name":"--arcgis-coding-components-code-editor-side-panel-max-w","description":"The max width for the code editor side panel *"},{"name":"--arcgis-coding-components-code-editor-results-panel-max-h","description":"The max height for the code editor results panel *"},{"name":"--arcgis-coding-components-code-editor-results-panel-h","description":"The default height for the code editor results panel (preferred over min-h). *"}],"pseudo-elements":[]}}}
1
+ {"$schema":"https://raw.githubusercontent.com/JetBrains/web-types/master/schema/web-types.json","name":"@arcgis/coding-components","version":"5.0.0-next.141","description-markup":"markdown","contributions":{"html":{"elements":[{"name":"arcgis-arcade-editor","description":"[**Arcade**](https://developers.arcgis.com/arcade/) is a portable, and lightweight expression language used to create custom content throughout the [ArcGIS system](https://www.esri.com/en-us/arcgis/products/index).\nLike other expression languages, it can perform mathematical calculations, format text, and evaluate logical statements.\nIt also supports multi-statement expressions, variables, and flow control statements. Arcade is unique when compared to other expression and scripting languages due to its inclusion of [feature](https://developers.arcgis.com/arcade/guide/types/#feature) and [geometry](https://developers.arcgis.com/arcade/guide/types/#geometry) data types.\n\nMap Viewer (MV) was the first ArcGIS Online product to incorporate the new Arcade editor after [the editor's introduction in the November 2022 ArcGIS Online release](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/introducing-the-new-arcade-editor-in-arcgis-online/).\nThis was possible thanks to the Arcade editor component, which enabled MV to implement its own Arcade expression builder.\nYou can now also find the editor in ArcGIS Dashboards, ArcGIS Field Maps, and ArcGIS Velocity.\n\nYou can easily get your own dedicated Arcade expression builder with the **Arcade editor** component, which includes:\n\n- An easy to use [layout](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/discover-the-arcade-editors-powerful-new-features/#the-new-layout)\n- An optional minimal layout if you, for example, decide to manually exclude things such as test data, padding, line numbers, and the sidebar\n- A way to execute Arcade expressions in a configurable code editor\n- [Suggestions and code completion](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/discover-the-arcade-editors-powerful-new-features/#suggestions-and-code-completion)\n- [WCAG 2.0 compliant code colorization / syntax highlighting](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/accessibility-and-arcade-working-in-color/)\n- Built-in [keyboard shortcuts](https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/discover-the-arcade-editors-powerful-new-features/#keyboard-shortcuts)\n- In-editor help for finding information about profile variables relevant to your profile, documentation for constants and functions, a link to the official Arcade documentation, and, in some case, suggestions.\n- Support for many [languages and directionality](https://developers.arcgis.com/javascript/latest/localization/)\n--\n\n### Events\n- **arcgisDiagnosticsChange** - Emitted when the diagnostics collection has changed.\n- **arcgisScriptChange** - Emitted when the script string has changed.\n\n### Methods\n- `componentOnReady(): Promise<this>` - Create a promise that resolves once component is fully loaded.\n- `getScript(): Promise<string | undefined>` - **Deprecated**: **Deprecated** since 4.30. Use `script` property instead.. \n- `getTestResult(): Promise<ArcadeResult>` - Returns the Arcade result for the script for the provided test data.\n- `setFocus(): Promise<void>` - Set the focus on the element.","doc-url":"https://developers.arcgis.com/javascript/latest/references/coding-components/arcgis-arcade-editor/","attributes":[{"name":"hide-documentation-actions","description":"If true, it will hide the documentation action in the side panel","default":"false","value":{"type":"boolean"}},{"name":"hide-side-bar","description":"If true, it will hide the side actions bar. The editor will be in a minimalistic UX.","default":"false","value":{"type":"boolean"}},{"name":"opened-side-panel","description":"The name of the opened side panel. 'none' means 'no panel opened'.","default":"\"none\"","value":{}},{"name":"script","description":"The arcade script. Use this property to define or update the script.","default":"\"\"","value":{"type":"string"}},{"name":"side-action-bar-expanded","description":"If true, the side action bar will be expanded","default":"false","value":{"type":"boolean"}}],"events":[{"name":"arcgisDiagnosticsChange","type":"Diagnostic[]","description":"Emitted when the diagnostics collection has changed."},{"name":"arcgisScriptChange","type":"string","description":"Emitted when the script string has changed."}],"js":{"properties":[{"name":"arcadeAssistant","description":"enables and configures the arcade assistant @internal","type":"ArcadeAssistantConfig | undefined"},{"name":"customPanels","description":"Custom panels to be displayed in the side panel.\nWill be placed below the default panels but above the help panel.","type":"ICustomPanel[] | undefined"},{"name":"editorOptions","description":"Options to update on the editor.\nFor example:\n```json\n{\n \"fontSize\": 18\n}\n```\n\nTo get the full list of available options, see the Monaco Editor options [documentation](https://microsoft.github.io/monaco-editor/typedoc/variables/editor.EditorOptions.html) for more details.","type":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined"},{"name":"hideDocumentationActions","description":"If true, it will hide the documentation action in the side panel","type":"boolean"},{"name":"hideSideBar","description":"If true, it will hide the side actions bar. The editor will be in a minimalistic UX.","type":"boolean"},{"name":"openedSidePanel","description":"The name of the opened side panel. 'none' means 'no panel opened'.","type":"T extends Required<WithCustomPanels> ? SidePanelName : string"},{"name":"profile","description":"The profile contains metadata used by the editor for editing context and help.\nExample:\n```\n {\n bundles: [\"core\", \"dataAccess\", \"geometry\", \"portal-access\"],\n variables: [\n {\n name: \"$feature\",\n description: \"The feature passed to the script during execution.\",\n definition: aFeatureLayerInstance\n }\n ]\n }\n```","type":"IEditorProfileDefinition | IPredefinedProfile | undefined"},{"name":"script","description":"The arcade script. Use this property to define or update the script.","type":"string"},{"name":"sideActionBarExpanded","description":"If true, the side action bar will be expanded","type":"boolean"},{"name":"snippets","description":"Collection of snippets","type":"ApiSnippet[] | undefined"},{"name":"suggestions","description":"Collection of suggestions","type":"IEditorCodeSuggestion[] | IEditorCodeSuggestionGroup[] | undefined"},{"name":"testData","description":"Test data used to execute the script in the editor. If undefined the execute script UX will be hidden.","type":"IEditorTestContext | undefined"}],"events":[{"name":"arcgisDiagnosticsChange","type":"Diagnostic[]","description":"Emitted when the diagnostics collection has changed."},{"name":"arcgisScriptChange","type":"string","description":"Emitted when the script string has changed."}]}},{"name":"arcgis-code-editor","description":"### Events\n- **arcgisSelectionChange** - Emitted when the selection has changed.\n- **arcgisValueChange** - Emitted when the value has changed (script, code, css, json, etc.)\n\n### Methods\n- `componentOnReady(): Promise<this>` - Create a promise that resolves once component is fully loaded.\n- `getValue(): Promise<string>` - **Deprecated**: **Deprecated** since 4.30. Use `value` property instead.. \n- `insertSnippet(text: string | null | undefined): Promise<void>` - Inserts a snippet at the current position in the editor.\n- `insertText(text: string | null | undefined): Promise<void>` - Inserts a text at the current position in the editor.\n- `setFocus(): Promise<void>` - Sets the focus on the editor.\n- `setValue(text: string | null | undefined): Promise<void>` - **Deprecated**: **Deprecated** since 4.30. Use `value` property instead.. ","doc-url":"https://developers.arcgis.com/javascript/latest/references/coding-components/arcgis-code-editor/","attributes":[{"name":"language","description":"The language for the editor.\nCurrently supported language: arcade, arcgis-sql-expression, json, css, html, javascript, typescript, and text.","value":{"type":"string"}},{"name":"model-id","description":"A unique identifier for the model.\nThe unique identifier is sometimes used by language defaults to store model metadata.\nFor example, with arcade, the model id is used to store the arcade profile and other metadata.\nThe unique identifier is especially useful when there are multiple editors on the same page.","value":{"type":"string"}},{"name":"value","description":"The initial value for the editor.\nThe value is the script, code, css, json, etc.","default":"\"\"","value":{"type":"string"}}],"events":[{"name":"arcgisSelectionChange","type":"{\n selection: Selection;\n model: Editor.ITextModel | null | undefined;\n}","description":"Emitted when the selection has changed."},{"name":"arcgisValueChange","type":"string","description":"Emitted when the value has changed (script, code, css, json, etc.)"}],"js":{"properties":[{"name":"editorInstance","description":"The instance of the Monaco Editor after the component has been rendered.\nTo determine when a component is rendered, you can use componentOnReady() method.\nThe method returns a Promise that resolves after the component rendered for the first time.","type":"Editor.IStandaloneCodeEditor | undefined"},{"name":"editorOptions","description":"Options to update on the editor.\nFor example:\n```json\n{\n \"fontSize\": 18\n}\n```\n\nTo get the full list of options set on the editor, use the editorInstance property and see Monaco Editor options documentation for more details.","type":"Editor.IEditorOptions & Editor.IGlobalEditorOptions | undefined"},{"name":"language","description":"The language for the editor.\nCurrently supported language: arcade, arcgis-sql-expression, json, css, html, javascript, typescript, and text.","type":"string | undefined"},{"name":"modelId","description":"A unique identifier for the model.\nThe unique identifier is sometimes used by language defaults to store model metadata.\nFor example, with arcade, the model id is used to store the arcade profile and other metadata.\nThe unique identifier is especially useful when there are multiple editors on the same page.","type":"`${string}-${string}-${string}-${string}-${string}`"},{"name":"value","description":"The initial value for the editor.\nThe value is the script, code, css, json, etc.","type":"string"}],"events":[{"name":"arcgisSelectionChange","type":"{\n selection: Selection;\n model: Editor.ITextModel | null | undefined;\n}","description":"Emitted when the selection has changed."},{"name":"arcgisValueChange","type":"string","description":"Emitted when the value has changed (script, code, css, json, etc.)"}]}},{"name":"arcgis-code-editor-shell","description":"A layout component for code editors that provides slots for an editor, results panel, side panel, and action bars.\n--\n\n### Methods\n- `componentOnReady(): Promise<this>` - Create a promise that resolves once component is fully loaded.\n\n### Slots\n- **top-action-bar** - A slot for placing a top action bar above the editor area.\n- **editor** - A slot for placing the main code editor component.\n- **results-panel** - A slot for placing a results panel below the code editor.\n- **side-panel** - A slot for placing a side panel next to the code editor area.\n- **side-action-bar** - A slot for placing a side action bar next to the side panel.\n\n### CSS Properties\n- **--arcgis-coding-components-border** - The border style for the editor shell * \n- **--arcgis-coding-components-background-color** - The background color for the editor shell * \n- **--arcgis-coding-components-side-action-bar-max-w** - The max width for the side action bar * \n- **--arcgis-coding-components-code-editor-side-panel-w** - The width for the code editor side panel * \n- **--arcgis-coding-components-code-editor-side-panel-max-w** - The max width for the code editor side panel * \n- **--arcgis-coding-components-code-editor-results-panel-max-h** - The max height for the code editor results panel * \n- **--arcgis-coding-components-code-editor-results-panel-h** - The default height for the code editor results panel (preferred over min-h). * ","doc-url":"https://developers.arcgis.com/javascript/latest/references/coding-components/arcgis-code-editor-shell/","attributes":[],"slots":[{"name":"top-action-bar","description":"A slot for placing a top action bar above the editor area."},{"name":"editor","description":"A slot for placing the main code editor component."},{"name":"results-panel","description":"A slot for placing a results panel below the code editor."},{"name":"side-panel","description":"A slot for placing a side panel next to the code editor area."},{"name":"side-action-bar","description":"A slot for placing a side action bar next to the side panel."}],"events":[],"js":{"properties":[],"events":[]}},{"name":"arcgis-code-viewer","description":"A code viewer component for displaying code snippets.\nSupports syntax highlighting for various programming languages, include arcade and arcgis-sql-expression.\n--\n\n### Methods\n- `componentOnReady(): Promise<this>` - Create a promise that resolves once component is fully loaded.","doc-url":"https://developers.arcgis.com/javascript/latest/references/coding-components/arcgis-code-viewer/","attributes":[{"name":"language","description":"The language for the component.\nCurrently supported language: arcade, arcgis-sql-expression, plus all the following languages found in monaco-editor's repo:\nhttps://github.com/microsoft/monaco-editor/tree/main/src/basic-languages.\n\nNote: The number of supported languages is limited in cdn builds to reduce package size. In cdn builds,\nonly the following languages are supported: css, html, javascript, typescript, and arcade, arcgis-sql-expression.","default":"\"arcade\"","value":{"type":"string"}},{"name":"round","description":"When `true`, adds a round style to the component.","default":"false","value":{"type":"boolean"}}],"events":[],"js":{"properties":[{"name":"language","description":"The language for the component.\nCurrently supported language: arcade, arcgis-sql-expression, plus all the following languages found in monaco-editor's repo:\nhttps://github.com/microsoft/monaco-editor/tree/main/src/basic-languages.\n\nNote: The number of supported languages is limited in cdn builds to reduce package size. In cdn builds,\nonly the following languages are supported: css, html, javascript, typescript, and arcade, arcgis-sql-expression.","type":"string"},{"name":"round","description":"When `true`, adds a round style to the component.","type":"boolean"}],"events":[]}},{"name":"arcgis-sql-expression-editor","description":"The SQL Expression Editor provides a familiar code editor experience for writing your own SQL expressions.\nIt supports syntax highlighting, code completion, and validation, allowing users to write SQL expressions using the\n[standardized SQL functions](https://doc.arcgis.com/en/arcgis-online/reference/sql-agol.htm) supported by ArcGIS.\n--\n\n### Events\n- **arcgisDiagnosticsChange** - Emitted when the diagnostics collection has changed.\n- **arcgisScriptChange** - Emitted when the script string has changed.\n\n### Methods\n- `componentOnReady(): Promise<this>` - Create a promise that resolves once component is fully loaded.\n- `setFocus(): Promise<void>` - Set the focus on the element.","doc-url":"https://developers.arcgis.com/javascript/latest/references/coding-components/arcgis-sql-expression-editor/","attributes":[{"name":"hide-side-bar","description":"If true, it will hide the side actions bar. The editor will be in a minimalistic UX.","default":"false","value":{"type":"boolean"}},{"name":"script","description":"The sql expression script. Use this property to define or update the script.","default":"\"\"","value":{"type":"string"}}],"events":[{"name":"arcgisDiagnosticsChange","type":"editor.IMarkerData[]","description":"Emitted when the diagnostics collection has changed."},{"name":"arcgisScriptChange","type":"string","description":"Emitted when the script string has changed."}],"js":{"properties":[{"name":"hideSideBar","description":"If true, it will hide the side actions bar. The editor will be in a minimalistic UX.","type":"boolean"},{"name":"profile","description":"The profile to use for the editor. The profile defines the variables and functions that are available to the editor.","type":"IPredefinedProfile | undefined"},{"name":"script","description":"The sql expression script. Use this property to define or update the script.","type":"string"}],"events":[{"name":"arcgisDiagnosticsChange","type":"editor.IMarkerData[]","description":"Emitted when the diagnostics collection has changed."},{"name":"arcgisScriptChange","type":"string","description":"Emitted when the script string has changed."}]}}]},"css":{"properties":[{"name":"--arcgis-coding-components-border","description":"The border style for the editor shell *"},{"name":"--arcgis-coding-components-background-color","description":"The background color for the editor shell *"},{"name":"--arcgis-coding-components-side-action-bar-max-w","description":"The max width for the side action bar *"},{"name":"--arcgis-coding-components-code-editor-side-panel-w","description":"The width for the code editor side panel *"},{"name":"--arcgis-coding-components-code-editor-side-panel-max-w","description":"The max width for the code editor side panel *"},{"name":"--arcgis-coding-components-code-editor-results-panel-max-h","description":"The max height for the code editor results panel *"},{"name":"--arcgis-coding-components-code-editor-results-panel-h","description":"The default height for the code editor results panel (preferred over min-h). *"}],"pseudo-elements":[]}}}
package/dist/index.js CHANGED
@@ -3,7 +3,7 @@ import { a as o } from "./chunks/arcade-defaults.js";
3
3
  import { s as x } from "./chunks/sql-expr-defaults.js";
4
4
  /*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
5
5
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
6
- v5.0.0-next.140 */
6
+ v5.0.0-next.141 */
7
7
  export {
8
8
  o as arcade,
9
9
  e as getAssetPath,
package/dist/loader.js CHANGED
@@ -2,7 +2,7 @@ import { r as e } from "./chunks/runtime.js";
2
2
  import { makeDefineCustomElements as s } from "@arcgis/lumina";
3
3
  /*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
4
4
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
5
- v5.0.0-next.140 */
5
+ v5.0.0-next.141 */
6
6
  const a = s(e, {
7
7
  "arcgis-arcade-coding-assistant": [() => import("./components/arcgis-arcade-coding-assistant/customElement.js"), "appVersion,assistantsEnabled,closed,closePanel:,editorRef:,feedbackServiceUrl,helpBase,insertText:,layer,portalUrl,serviceUrl;destroy"],
8
8
  "arcgis-arcade-editor": [() => import("./components/arcgis-arcade-editor/customElement.js"), "arcadeAssistant:,customPanels:,editorInstance:,editorOptions:,hideDocumentationActions,hideSideBar,messages:,openedSidePanel,profile:,script,sideActionBarExpanded,snippets:,suggestions:,testData:;getEditorInstance,getScript,getTestResult,setFocus"],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arcgis/coding-components",
3
- "version": "5.0.0-next.140",
3
+ "version": "5.0.0-next.141",
4
4
  "description": "Contains components for editing code in different languages. The currently supported languages are html, css, json, TypeScript, JavaScript, and Arcade.",
5
5
  "keywords": [
6
6
  "ArcGIS",
@@ -47,10 +47,10 @@
47
47
  "monaco-editor": "^0.52.0",
48
48
  "tslib": "^2.8.1",
49
49
  "vscode-languageserver-types": "^3.17.5",
50
- "@arcgis/arcade-languageservice": "5.0.0-next.140",
51
- "@arcgis/languages-api-utils": "5.0.0-next.140",
52
- "@arcgis/toolkit": "5.0.0-next.140",
53
- "@arcgis/lumina": "5.0.0-next.140"
50
+ "@arcgis/lumina": "5.0.0-next.141",
51
+ "@arcgis/arcade-languageservice": "5.0.0-next.141",
52
+ "@arcgis/languages-api-utils": "5.0.0-next.141",
53
+ "@arcgis/toolkit": "5.0.0-next.141"
54
54
  },
55
55
  "peerDependencies": {
56
56
  "@arcgis/core": ">=5.0.0-next.62 <5.1",
@@ -1,13 +0,0 @@
1
- /*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
2
- See https://js.arcgis.com/5.0/esri/copyright.txt for details.
3
- v5.0.0-next.140 */
4
- import{a as S}from"./DHKHGAIN.js";import a from"./6HNTPPBF.js";import{a as O}from"./4SD3AP46.js";import"./ZU5A2KCX.js";import"./C4EXEFHY.js";import{d as F}from"./G5T4EI7D.js";import{b as C,c as L}from"./YYSVEFB6.js";import{D as m,E as p,F as T,G as v,H as y,J as M,g as P,h as b,j as t,n as x,p as d,t as r}from"./DYMWCNFZ.js";import"./DWCX7EOA.js";import"./JTC4R6ZU.js";export default $arcgis.t(([{b:o,c:R,d:h,e:_,f:j,g:D}])=>{var J=b`:host{display:flex;flex-direction:column;width:100%;background-color:var(--calcite-color-foreground-1);color:var(--calcite-color-text-2);.flex-adjustable{flex:1 1 auto;overflow:hidden}.flex-row{display:flex;flex-direction:row;overflow:hidden}.flex-column{display:flex;flex-direction:column;overflow:hidden}.y-scrollable-container{overflow-y:auto;block-size:100%;background-color:var(--calcite-color-foreground-1)}header{border-bottom:1px solid var(--calcite-color-border-3);flex:0 0 auto}.ltr-container{direction:ltr}calcite-action-bar{calcite-action-group{padding-inline-end:var(--calcite-spacing-sm);calcite-action{padding-inline-end:var(--calcite-spacing-sm)}calcite-action:not(:first-child){padding-inline-start:var(--calcite-spacing-sm)}}calcite-action-group:last-child{border-inline-end-width:0px}calcite-action-group:not(:first-child){padding-inline-start:var(--calcite-spacing-sm)}}.notice-container{margin:var(--calcite-spacing-xxs);padding:var(--calcite-spacing-sm);background-color:var(--calcite-color-foreground-1)}.color-info{color:var(--calcite-color-status-info)}.color-error{color:var(--calcite-color-status-danger)}.color-success{color:var(--calcite-color-status-success)}[class*=result-value-]{font-size:var(--calcite-font-size--2);line-height:1.25rem;background-color:var(--calcite-color-foreground-1);margin:var(--calcite-spacing-md)}.console-logs-container{background-color:var(--calcite-color-foreground-1);padding:0 var(--calcite-spacing-md);font-family:var(--calcite-code-family);font-size:var(--calcite-font-size--2);font-weight:var(--calcite-font-weight-normal)}.result-value-table{table{display:block;max-width:fit-content;overflow-x:auto;border-spacing:0;border-collapse:collapse;text-align:start;white-space:nowrap;thead{background-color:var(--calcite-color-foreground-2)}tr{border-top:1px solid var(--calcite-color-border-3);border-bottom:1px solid var(--calcite-color-border-3)}th,td{border-inline-start:1px solid var(--calcite-color-border-3);border-inline-end:1px solid var(--calcite-color-border-3);text-align:start;padding:var(--calcite-spacing-xxs);.string-value{white-space:pre}}th{font-weight:var(--calcite-font-weight-medium)}}}.tree-item-label,.number-value,.string-value,.boolean-value{font-family:var(--calcite-code-family)}.tree-item-label,.value-type{color:var(--calcite-color-text-2);font-weight:var(--calcite-font-weight-normal)}.dictionary-property{color:var(--arcgis-editor-identifier)}.number-value{color:var(--arcgis-editor-number)}.string-value{color:var(--arcgis-editor-string);white-space:pre-wrap}.constant-value{color:var(--arcgis-editor-constant)}.date-value{color:var(--arcgis-editor-date)}}`,l={lines:!0,selectionMode:"none",scale:"s",oncalciteTreeSelect:e=>e.currentTarget.selectedItems.forEach(a=>a.selected=!1)},g={onClick:e=>{let a=e.currentTarget;a.expanded=!a.expanded}},n=({name:e})=>t`<span class="dictionary-property">${e}</span><span>:&nbsp;</span>`,z=({value:e,subtree:a=!1})=>t`<calcite-tree slot=${(a?"children":void 0)??y} .lines=${l.lines} .selectionMode=${l.selectionMode} .scale=${l.scale} @calciteTreeSelect=${l.oncalciteTreeSelect}><calcite-tree-item class="string-value">${JSON.stringify(e.castAsJson(),void 0,2)}</calcite-tree-item></calcite-tree>`,N=({value:e,subtree:a=!1})=>t`<calcite-tree slot=${(a?"children":void 0)??y} .lines=${l.lines} .selectionMode=${l.selectionMode} .scale=${l.scale} @calciteTreeSelect=${l.oncalciteTreeSelect}><calcite-tree-item><div class="tree-item-label">${n({name:"type"})}${e.type}</div></calcite-tree-item><calcite-tree-item><div class="tree-item-label">${n({name:"value"})}<span class="string-value">${JSON.stringify(e,void 0,2)}</span></div></calcite-tree-item></calcite-tree>`,f=({arcadeResult:e})=>{switch(e.type){case"unknown":case"null":return t`<span class="constant-value">${e.type}</span>`;case"text":return t`<span class="string-value">${d(e.value)}</span>`;case"number":return t`<span class="number-value">${e.value.toString()}</span>`;case"boolean":return t`<span class="constant-value">${e.value.toString()}</span>`;case"date":return t`<span class="date-value">${_(e)}</span>`;case"dateOnly":return t`<span class="string-value">${d(j(e))}</span>`;case"time":return t`<span class="string-value">${d(D(e))}</span>`;default:return null}},E=({arcadeResult:e,t9nStrings:a})=>{let s=e.value??[],c=Math.max(s.length-o,0);return t`<span>${`${e.type}(${s.length??0})`}</span>${c>0?t`<span>&nbsp;${r(a.showingfirstitemsformat,{count:o.toString()})}</span>`:null}`},I=({value:e,subtree:a,t9nStrings:s})=>{let c=e.geometry?.();return t`<calcite-tree slot=${"children"} .lines=${l.lines} .selectionMode=${l.selectionMode} .scale=${l.scale} @calciteTreeSelect=${l.oncalciteTreeSelect}>${e.keys().map(i=>{let u=h(e.field(i));return e.arcadeDeclaredClass==="esri.arcade.Feature"&&u.type==="geometry"?null:k({arcadeResult:u,name:i,t9nStrings:s})})}${c?k({arcadeResult:{type:"geometry",value:c},name:"geometry",t9nStrings:s}):null}</calcite-tree>`},G=({arcadeResult:e,t9nStrings:a})=>t`<div class="value-type"><span>${e.type}:</span>${e.features.length>=R?t`<span>&nbsp;${r(a.showingfirstitemsformat,{count:R.toString()})}</span>`:null}</div>`,A=({items:e,subtree:a,t9nStrings:s})=>t`<calcite-tree slot=${"children"} .lines=${l.lines} .selectionMode=${l.selectionMode} .scale=${l.scale} @calciteTreeSelect=${l.oncalciteTreeSelect}>${e.map((c,i)=>{let u=h(c);return k({arcadeResult:u,name:i,expanded:!a,t9nStrings:s})})}</calcite-tree>`,k=({arcadeResult:e,name:a,expanded:s,t9nStrings:c})=>{switch(e.type){case"null":case"unknown":case"text":case"number":case"date":case"dateOnly":case"time":case"boolean":return t`<calcite-tree-item><div class="tree-item-label">${n({name:a})}${f({arcadeResult:e})}</div></calcite-tree-item>`;case"array":{let i=(e.value??[]).slice(0,o);return t`<calcite-tree-item .expanded=${s} @click=${g.onClick}><div class="tree-item-label">${n({name:a})}${E({arcadeResult:e,t9nStrings:c})}</div>${A({items:i,subtree:!0,t9nStrings:c})}</calcite-tree-item>`}case"geometry":return t`<calcite-tree-item .expanded=${s} @click=${g.onClick}><div class="tree-item-label">${n({name:a})}<span>${e.type}</span></div>${N({value:e.value,subtree:!0})}</calcite-tree-item>`;case"attachment":return t`<calcite-tree-item .expanded=${s} @click=${g.onClick}><div class="tree-item-label">${n({name:a})}<span>${e.type}</span></div>${z({value:e.value,subtree:!0})}</calcite-tree-item>`;case"feature":case"dictionary":case"portal":return t`<calcite-tree-item .expanded=${s} @click=${g.onClick}><div class="tree-item-label">${n({name:a})}<span>${e.type}</span></div>${I({value:e.value,subtree:!0,t9nStrings:c})}</calcite-tree-item>`;default:return null}},V=({arcadeResult:e})=>{let a=F(e.value.fields);return t`<table><thead><tr>${a.map(s=>t`<th>${s.name}</th>`)}</tr></thead><tbody>${e.features.map(s=>t`<tr>${a.map(c=>{try{let i=h(s.field(c.name));return t`<td>${f({arcadeResult:i})}</td>`}catch{return t`<td></td>`}})}</tr>`)}</tbody></table>`};function q(){let e=`:host {
5
- `,a=S["light-theme"];Object.entries(a).forEach(([c,i])=>{e+=` --arcgis-editor-${c}: ${i};
6
- `}),e+=`}
7
- `,e+=`:host([calcite-mode-dark]) {
8
- `;let s=S["dark-theme"];return Object.entries(s).forEach(([c,i])=>{e+=`
9
- --arcgis-editor-${c}: ${i};`}),e+=`
10
- }
11
- `,b`
12
- ${P(e)}
13
- `}var $={onClick:e=>{let a=e.currentTarget;a.expanded=!a.expanded}},w=class extends T{constructor(){super(...arguments),this.messages=O(),this.outputRef=m(),this.consoleRef=m(),this.logRef=m(),this.openedResultPanel="output",this.calciteModeDark=!1,this.arcgisClose=x({bubbles:!1}),this.arcgisOpenedResultPanelChange=x({bubbles:!1})}static{this.properties={consoleLogs:0,loading:5,openedResultPanel:3,result:0,calciteModeDark:7}}static{this.styles=[J,q()]}load(){this.manager.onLifecycle(()=>{let a=C(this.el,["class"],this.updateTheme.bind(this));return this.updateTheme(),()=>a()})}loaded(){this.openedResultPanel&&(this.openedResultPanel==="output"&&this.outputRef.value?this.outputRef.value.setFocus():this.openedResultPanel==="console"&&this.consoleRef.value?this.consoleRef.value.setFocus():this.openedResultPanel==="log"&&this.logRef.value&&this.logRef.value.setFocus())}updateResultPanel(a){this.openedResultPanel=a,this.arcgisOpenedResultPanelChange.emit(a)}_switchResultPanel(a){let s=a.currentTarget.dataset.panelName;s&&this.updateResultPanel(s)}_emitClose(){this.arcgisClose.emit()}updateTheme(){this.calciteModeDark=L(this.el)==="dark"}renderConsolePanel(){return this.openedResultPanel!=="console"?null:this.loading&&!this.consoleLogs?.length?t`<calcite-loader scale=s type=indeterminate label></calcite-loader>`:t`<div class="console-logs-container ltr-container">${this.consoleLogs?.length?this.consoleLogs.map(a=>t`<p>${a}</p>`):t`<p>${this.messages.consolemessage}</p>`}</div>`}renderLogPanel(){if(this.openedResultPanel!=="log")return null;if(this.loading)return t`<calcite-loader scale=s type=indeterminate label></calcite-loader>`;let a=this.result?.type==="error"?"color-error":"color-success";return t`<calcite-list label=results>${this.result?t`<calcite-list-item .label=${r(this.messages.lastexecutionformat,{timeStamp:new Intl.DateTimeFormat(this.messages._t9nLocale,{dateStyle:"medium",timeStyle:"medium"}).format(this.result.timeStamp)})}><calcite-icon slot=content-start icon=information scale=s class=${v(a)}></calcite-icon></calcite-list-item><calcite-list-item .label=${r(this.messages.compilationtimeformat,{time:new Intl.NumberFormat(this.messages._t9nLocale,{style:"unit",unit:"millisecond",maximumFractionDigits:2}).format(this.result.compilationTime??0)})}><calcite-icon slot=content-start icon=information scale=s class=${v(a)}></calcite-icon></calcite-list-item><calcite-list-item .label=${r(this.messages.executiontimeformat,{time:new Intl.NumberFormat(this.messages._t9nLocale,{style:"unit",unit:"millisecond",maximumFractionDigits:2}).format(this.result.executionTime??0)})}><calcite-icon slot=content-start icon=information scale=s class=${v(a)}></calcite-icon></calcite-list-item>`:t`<calcite-list-item .label=${this.messages.runscriptmessage}><calcite-icon slot=content-start icon=information scale=s class="color-info"></calcite-icon></calcite-list-item>`}</calcite-list>`}renderOutputPanel(){if(this.openedResultPanel!=="output")return null;if(this.loading)return t`<calcite-loader scale=s type=indeterminate label></calcite-loader>`;switch(this.result?.type){case"error":return t`<div class="result-value-simple flex-adjustable">${r(this.messages.executionerrorformat??"",{message:this.result.value})}</div>`;case"null":case"unknown":return t`<div class="result-value-simple ltr-container">${f({arcadeResult:this.result})}</div>`;case"text":case"number":case"date":case"dateOnly":case"time":case"boolean":return t`<div class="result-value-simple ltr-container"><span class="value-type">${this.result.type}:&nbsp;</span>${f({arcadeResult:this.result})}</div>`;case"array":{let a=(this.result.value??[]).slice(0,o);return t`<div class="result-value-simple ltr-container"><calcite-tree .lines=${l.lines} .selectionMode=${l.selectionMode} .scale=${l.scale} @calciteTreeSelect=${l.oncalciteTreeSelect}><calcite-tree-item expanded @click=${$.onClick}><div class="tree-item-label">${E({arcadeResult:this.result,t9nStrings:this.messages})}</div>${A({items:a,subtree:!0,t9nStrings:this.messages})}</calcite-tree-item></calcite-tree></div>`}case"geometry":return t`<div class="result-value-simple ltr-container"><calcite-tree .lines=${l.lines} .selectionMode=${l.selectionMode} .scale=${l.scale} @calciteTreeSelect=${l.oncalciteTreeSelect}><calcite-tree-item expanded @click=${$.onClick}><div class="tree-item-label">${this.result.type}</div>${N({value:this.result.value,subtree:!0})}</calcite-tree-item></calcite-tree></div>`;case"attachment":return t`<div class="result-value-simple ltr-container"><calcite-tree .lines=${l.lines} .selectionMode=${l.selectionMode} .scale=${l.scale} @calciteTreeSelect=${l.oncalciteTreeSelect}><calcite-tree-item expanded @click=${$.onClick}><div class="tree-item-label">${this.result.type}</div>${z({value:this.result.value,subtree:!0})}</calcite-tree-item></calcite-tree></div>`;case"feature":case"dictionary":case"portal":case"pixel":return t`<div class="result-value-simple ltr-container"><calcite-tree .lines=${l.lines} .selectionMode=${l.selectionMode} .scale=${l.scale} @calciteTreeSelect=${l.oncalciteTreeSelect}><calcite-tree-item expanded @click=${$.onClick}><div class="tree-item-label">${this.result.type}</div>${I({value:this.result.value,subtree:!0,t9nStrings:this.messages})}</calcite-tree-item></calcite-tree></div>`;case"featureSet":return t`<div class="result-value-table ltr-container">${G({arcadeResult:this.result,t9nStrings:this.messages})}${V({arcadeResult:this.result})}</div>`;case"knowledgeGraph":return t`<div class="result-value-simple ltr-container"><span class="value-type">${this.result.type}:&nbsp;</span><span class="string-value">${this.result.value.url}</span></div>`;default:return t`<div class="result-value-simple flex-adjustable ltr-container">${this.messages.runscriptmessage}</div>`}}render(){return t`<header class="flex-row"><calcite-action-bar class="flex-adjustable" layout=horizontal scale=s expanded expand-disabled><calcite-action-group scale=s><calcite-action .active=${this.openedResultPanel==="output"} .text=${this.messages.output??""} text-enabled scale=s icon=list-show-all icon-flip-rtl @click=${this._switchResultPanel} data-panel-name=output ${p(this.outputRef)}></calcite-action><calcite-action .active=${this.openedResultPanel==="console"} .text=${this.messages.console??""} text-enabled scale=s icon=console icon-flip-rtl @click=${this._switchResultPanel} data-panel-name=console ${p(this.consoleRef)}></calcite-action><calcite-action .active=${this.openedResultPanel==="log"} .text=${this.messages.log??""} text-enabled scale=s icon=list icon-flip-rtl @click=${this._switchResultPanel} data-panel-name=log ${p(this.logRef)}></calcite-action></calcite-action-group></calcite-action-bar><calcite-action scale=s icon=x .text=${this.messages.close??""} @click=${this._emitClose}></calcite-action></header><article class="flex-adjustable">${this.loading?t`<calcite-loader scale=s type=indeterminate label></calcite-loader>`:t`<div class="flex-column y-scrollable-container">${this.renderOutputPanel()}${this.renderConsolePanel()}${this.renderLogPanel()}</div>`}</article>`}};M("arcgis-arcade-results",w);return w},a)
@@ -1,4 +0,0 @@
1
- /*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
2
- See https://js.arcgis.com/5.0/esri/copyright.txt for details.
3
- v5.0.0-next.140 */
4
- import c from"./QEWPVXQ4.js";import"./57JMNO5L.js";import b from"./FNALAI66.js";import a from"./IVLAW36F.js";import"./C4EXEFHY.js";import"./G5T4EI7D.js";import"./ONS4ZING.js";import"./7VAC6CMK.js";import"./YP3EICK5.js";import"./LJIVTQAR.js";import"./YYSVEFB6.js";import"./DYMWCNFZ.js";import"./DWCX7EOA.js";import"./36M2T4ND.js";import"./JTC4R6ZU.js";export default $arcgis.t(([,,{a:a,b:b,c:c}])=>{return{getSqlExprDiagnosticService:b,getSqlExprWorker:a,setupMode:c}},a,b,c)
@@ -1,4 +0,0 @@
1
- /*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
2
- See https://js.arcgis.com/5.0/esri/copyright.txt for details.
3
- v5.0.0-next.140 */
4
- import{b,c as r,d as _}from"./2U5KSGDI.js";import{a as v}from"./3FYTZKBP.js";import{a as f}from"./4SD3AP46.js";import"./ZU5A2KCX.js";import{a as p}from"./ONS4ZING.js";import"./7VAC6CMK.js";import"./YP3EICK5.js";import"./LJIVTQAR.js";import{d as h,e as m}from"./YYSVEFB6.js";import{E as l,F as d,J as u,h as g,j as s,l as c,n as a}from"./DYMWCNFZ.js";import"./DWCX7EOA.js";import"./36M2T4ND.js";import"./JTC4R6ZU.js";function S(o){return!Array.isArray(o)||!o.length?!1:Array.isArray(o[0].suggestions)}var $=g`:host{background-color:var(--calcite-color-foreground-1);.notice-container{margin:var(--calcite-spacing-xxs);padding:var(--calcite-spacing-sm);background-color:var(--calcite-color-foreground-1)}.sticky{position:sticky;top:0;z-index:10}calcite-flow{height:100%}calcite-block{p:first-of-type{margin-top:0}code{font-family:var(--calcite-code-family)}pre{direction:ltr;overflow-x:auto;background-color:var(--calcite-color-foreground-2);padding:var(--calcite-spacing-sm);code{font-size:var(--calcite-font-size--2)}}}calcite-list-item-group{background-color:var(--calcite-color-foreground-2)}calcite-flow{[slot=footer]{word-break:break-word}}}`,n=class extends d{constructor(){super(...arguments),this._beforeBack=async()=>{this._selectedSuggestion=void 0},this.messages=f(),this._colorizeStyle="",this._filterValue="",this.closed=!1,this.arcgisClose=a({bubbles:!1}),this.arcgisItemSelected=a({bubbles:!1})}static{this.properties={_colorizeStyle:16,_filterValue:16,_selectedSuggestion:16,suggestions:0,closed:5}}static{this.styles=$}load(){this._colorizeStyle=r(),this._themeChangedListener=_(()=>this._colorizeStyle=r())}willUpdate(e){e.has("suggestions")&&this.suggestionsPropChanged()}disconnectedCallback(){super.disconnectedCallback(),this._flowObserver?.disconnect(),this._themeChangedListener?.dispose()}suggestionsPropChanged(){this._selectedSuggestion=void 0}flowFocusHandler(e){if(!e){this._flowObserver?.disconnect(),this._flowObserver=void 0;return}this._flowObserver||(this._flowObserver=new MutationObserver(()=>{m(e.querySelector("calcite-flow-item:last-child"),"calcite-input")}),this._flowObserver.observe(e,{attributes:!0,attributeFilter:["id"],childList:!0}))}_updateFilterValue(e){this._filterValue=e.currentTarget?.value??""}_emitItemSelected(e,t){let i=e;(!i.key||i.key==="Enter")&&(e.preventDefault(),this.arcgisItemSelected.emit(t.code))}_showSuggestionDetail(e,t){e.stopPropagation(),this._selectedSuggestion=t}_emitClose(){this.arcgisClose.emit()}_colorizeCode(e){e!==void 0&&b(e,this._selectedSuggestion.code,"arcade")}renderSuggestionGroups(){return this.suggestions===void 0?null:S(this.suggestions)?this.suggestions.map(e=>s`<calcite-list-item-group .heading=${e.label}>${this.renderSuggestionListItems(e.suggestions)}</calcite-list-item-group>`):this.renderSuggestionListItems(this.suggestions)}renderSuggestionListItems(e){return e=p(e,"label",this._filterValue),e.length?e.map(t=>s`<calcite-list-item .label=${t.label} .description=${t.description} @calciteListItemSelect=${i=>this._emitItemSelected(i,t)} @keydown=${i=>this._emitItemSelected(i,t)} data-item=${t??c}><calcite-action slot=actions-end .text=${this.messages.expand??""} scale=s icon=chevron-right icon-flip-rtl @click=${i=>this._showSuggestionDetail(i,t)} data-item=${t??c}></calcite-action></calcite-list-item>`):s`<div class="notice-container">${this.messages.noitems}</div>`}renderSuggestionFlowItem(){let e=this._selectedSuggestion;return e?s`<calcite-flow-item heading-level=2 .heading=${this.messages.suggestions} closable @calciteFlowItemClose=${this._emitClose} .beforeBack=${this._beforeBack} selected><calcite-button width=half slot=footer appearance=outline kind=brand icon-start=code scale=s @click=${t=>this._emitItemSelected(t,e)} data-item=${e??c} ${l(h)}>${this.messages.insert}</calcite-button><calcite-block open .heading=${e.label} .description=${e.description}><div .innerHTML=${v(e.documentation)??""}></div><pre><code ${l(this._colorizeCode)}></code></pre></calcite-block></calcite-flow-item>`:null}render(){return this.closed?null:s`<style>${this._colorizeStyle}</style><calcite-flow ${l(this.flowFocusHandler)}><calcite-flow-item heading-level=2 .heading=${this.messages.suggestions} closable @calciteFlowItemClose=${this._emitClose} .selected=${!this._selectedSuggestion}><calcite-input .value=${this._filterValue} icon=magnifying-glass clearable @calciteInputInput=${this._updateFilterValue} class="sticky" scale=m></calcite-input><calcite-list label=suggestions>${this.renderSuggestionGroups()}</calcite-list></calcite-flow-item>${this.renderSuggestionFlowItem()}</calcite-flow>`}};u("arcgis-arcade-suggestions",n);export{n as ArcgisArcadeSuggestions};
@@ -1,4 +0,0 @@
1
- /*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
2
- See https://js.arcgis.com/5.0/esri/copyright.txt for details.
3
- v5.0.0-next.140 */
4
- import{a as _}from"./4SD3AP46.js";import"./ZU5A2KCX.js";import f from"./QEWPVXQ4.js";import"./57JMNO5L.js";import c from"./FNALAI66.js";import b from"./IVLAW36F.js";import"./C4EXEFHY.js";import"./G5T4EI7D.js";import"./ONS4ZING.js";import"./7VAC6CMK.js";import"./YP3EICK5.js";import"./LJIVTQAR.js";import"./YYSVEFB6.js";import{D as l,E as h,F as p,G as r,J as g,h as n,j as e,n as o,s as d}from"./DYMWCNFZ.js";import{d as a}from"./DWCX7EOA.js";import"./36M2T4ND.js";import"./JTC4R6ZU.js";export default $arcgis.t(([,s,{b:f}])=>{var m=n`:host{height:100%}calcite-tooltip:not([calcite-hydrated])>*{display:none}`,c=class extends p{constructor(){super(...arguments),this._codeEditorElt=l(),this._disposables=[],this.messages=_(),this._modelId=d(),this._preparing=!1,this.sideActionBarExpanded=!1,this.script="",this.hideSideBar=!1,this.arcgisDiagnosticsChange=o({bubbles:!1}),this.arcgisScriptChange=o({bubbles:!1})}static{this.properties={_activeAction:16,_apiLibrary:16,_editorProfile:16,_preparing:16,sideActionBarExpanded:16,profile:0,script:1,hideSideBar:5}}static{this.styles=[m]}async setFocus(){await this._codeEditorElt.value?.setFocus()}async load(){await this._updateEditorProfile().catch(a(this))}willUpdate(i){(i.has("messages")||i.has("profile"))&&this._updateDataModelDeps()}async loaded(){let i=await f();this._disposables.push(i.onDiagnosticsChange(t=>!this._preparing&&this.arcgisDiagnosticsChange.emit(t.diagnostics)))}disconnectedCallback(){for(super.disconnectedCallback();this._disposables.length;)this._disposables.pop()?.dispose()}async _updateDataModelDeps(){await this._updateEditorProfile(),await this._updateApiLibrary()}async _updateEditorProfile(){this._preparing=!0;try{await s.setProfileForModel(this._modelId,this.profile,{locale:this.messages._t9nLocale}),this._editorProfile=s.getEditorProfileForModel(this._modelId)}catch{this._editorProfile=void 0}finally{this._preparing=!1}}_setActiveAction(i){if(this._activeAction===i){this._activeAction=void 0;return}this._activeAction=i}_handleActionClick(i){let t=i.target;this._setActiveAction(t.dataset.panelName)}_insertAsSnippet(i){this._codeEditorElt.value?.insertSnippet(i.detail).catch(a(this))}_insertAsText(i){this._codeEditorElt.value?.insertText(i.detail.replaceAll('"',"'")).catch(a(this))}async _updateApiLibrary(){this._apiLibrary=await s.getApiLibraryForModel(this._modelId)}_onCodeEditorValueChange(i){i.stopPropagation(),this.script=i.detail,this.arcgisScriptChange.emit(i.detail)}_getFeatureSetVariable(){let i,t=s.getEditorProfileForModel(this._modelId);return t?.variables?.length&&t?.variables?.[0]?.type!=="featureSet"?a(this)("Encountered unexpected editor profile"):i=t?.variables?.[0],i}_toggleSideActionBarExpanded(){this.sideActionBarExpanded=!this.sideActionBarExpanded}render(){let i=this._getFeatureSetVariable();return e`<arcgis-code-editor-shell><arcgis-code-editor slot=editor language=arcgis-sql-expression .modelId=${this._modelId} .value=${this.script??""} @arcgisValueChange=${this._onCodeEditorValueChange} ${h(this._codeEditorElt)}></arcgis-code-editor>${!this.hideSideBar&&i&&e`<arcgis-editor-variables slot=side-panel .variable=${i} .closed=${this._activeAction!=="fields"} class=${r(this._activeAction==="fields"?"":"hidden")} .loading=${this._preparing} .modelId=${this._modelId} @arcgisItemSelected=${this._insertAsText} @arcgisClose=${()=>this._setActiveAction(void 0)} data-panel-name=none></arcgis-editor-variables>`||""}${!this.hideSideBar&&e`<arcgis-language-api-panel slot=side-panel class=${r(this._activeAction==="functions"?"":"hidden")} .closed=${this._activeAction!=="functions"} @arcgisItemSelected=${this._insertAsSnippet} @arcgisClose=${()=>this._setActiveAction(void 0)} .loading=${this._preparing} .apiLibrary=${this._apiLibrary} data-panel-name=none hide-documentation-actions .languageId=${s.languageId}></arcgis-language-api-panel>`||""}${!this.hideSideBar&&e`<calcite-action-bar slot=side-action-bar .expanded=${this.sideActionBarExpanded} position=end @calciteActionBarToggle=${this._toggleSideActionBarExpanded}>${i&&e`<calcite-action id=fields-action .text=${this.messages.fields??"Fields"} icon=profile-variables .active=${this._activeAction==="fields"} data-panel-name=fields @click=${this._handleActionClick}></calcite-action>`||""}${i&&!this.sideActionBarExpanded&&e`<calcite-tooltip reference-element=fields-action><span>${this.messages.fields??"Fields"}</span></calcite-tooltip>`||""}<calcite-action id=functions-action .text=${this.messages.functions??"Functions"} icon=function .active=${this._activeAction==="functions"} data-panel-name=functions @click=${this._handleActionClick}></calcite-action>${!this.sideActionBarExpanded&&e`<calcite-tooltip reference-element=functions-action><span>${this.messages.functions??"Functions"}</span></calcite-tooltip>`||""}</calcite-action-bar>`||""}</arcgis-code-editor-shell>`}};g("arcgis-sql-expression-editor",c);return c},b,c,f)
@@ -1,4 +0,0 @@
1
- /*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
2
- See https://js.arcgis.com/5.0/esri/copyright.txt for details.
3
- v5.0.0-next.140 */
4
- import{a as n}from"./3FYTZKBP.js";import{a as f}from"./4SD3AP46.js";import"./ZU5A2KCX.js";import{a as g}from"./ONS4ZING.js";import"./YP3EICK5.js";import{d as p,e as u}from"./YYSVEFB6.js";import{E as c,F as d,J as h,h as m,j as s,n as a,r as o}from"./DYMWCNFZ.js";import"./DWCX7EOA.js";import"./JTC4R6ZU.js";var b=m`:host{background-color:var(--calcite-color-foreground-1);.notice-container{margin:var(--calcite-spacing-xxs);padding:var(--calcite-spacing-sm);background-color:var(--calcite-color-foreground-1)}.sticky{position:sticky;top:0;z-index:10}calcite-flow{height:100%}calcite-block{p:first-of-type{margin-top:0}}calcite-list-item-group{background-color:var(--calcite-color-foreground-2)}calcite-flow{[slot=footer]{word-break:break-word}}}`,r=class extends d{constructor(){super(...arguments),this.messages=f(),this._unselectItem=async()=>{this._selectedApiItem=void 0},this._filterValue="",this.languageId="arcade",this.hideDocumentationActions=!1,this.loading=!1,this.closed=!1,this.arcgisClose=a({bubbles:!1}),this.arcgisItemSelected=a({bubbles:!1})}static{this.properties={_filterValue:16,_selectedApiItem:16,languageId:1,apiLibrary:0,hideDocumentationActions:5,loading:5,closed:5}}static{this.styles=b}willUpdate(e){if(e.has("apiLibrary")){if(!this._selectedApiItem)return;for(let i of this.apiLibrary??[])for(let t of i.items)if(t.name===this._selectedApiItem.name){this._selectedApiItem=t;return}this._selectedApiItem=void 0}}disconnectedCallback(){super.disconnectedCallback(),this._flowObserver?.disconnect()}flowFocusHandler(e){if(!e){this._flowObserver?.disconnect(),this._flowObserver=void 0;return}this._flowObserver||(this._flowObserver=new MutationObserver(()=>{u(e.querySelector("calcite-flow-item:last-child"),"calcite-input")}),this._flowObserver.observe(e,{attributes:!0,attributeFilter:["id"],childList:!0}))}_emitItemSelected(e,i){if(!i)return;let t=e;(!t.key||t.key==="Enter")&&(e.preventDefault(),this.arcgisItemSelected.emit(i.completion.insertText??""))}_emitClose(){this.arcgisClose.emit()}_emitItemSelectedAndClose(e,i){let t=e;(!t.key||t.key==="Enter")&&(e.preventDefault(),this.arcgisItemSelected.emit(i.completion.insertText??""))}_selectItem(e,i){e.stopPropagation(),this._selectedApiItem=i}_updateFilterValue(e){this._filterValue=e.currentTarget.value??""}_elementToMarkdown(e){e!==void 0&&(e.innerHTML=n(this._selectedApiItem.examples))}renderApiCategory(e){let i=g(e.items,"name",this._filterValue);return i.length?s`<calcite-list-item-group .heading=${e.title}>${i.map(t=>s`<calcite-list-item .label=${o(t.completion.detail)} @calciteListItemSelect=${l=>this._emitItemSelected(l,t)} @keydown=${l=>this._emitItemSelected(l,t)}><calcite-action slot=actions-end .text=${this.messages.expand??""} icon=chevron-right icon-flip-rtl scale=s @click=${l=>this._selectItem(l,t)}></calcite-action></calcite-list-item>`)}</calcite-list-item-group>`:null}renderApiItemFlowItem(){let e=this._selectedApiItem;return e?s`<calcite-flow-item heading-level=2 .heading=${this.messages.constantsandfunctions} .beforeBack=${this._unselectItem} closable @calciteFlowItemClose=${this._emitClose} selected>${this.hideDocumentationActions?null:s`<calcite-button width=half slot=footer appearance=outline kind=brand scale=s .href=${e.link} target=Help icon-start=information>${this.messages.moreinformation}</calcite-button>`}<calcite-button .width=${this.hideDocumentationActions?"full":"half"} slot=footer appearance=outline kind=brand icon-start=code scale=s @click=${i=>this._emitItemSelectedAndClose(i,e)} ${c(p)}>${this.messages.insert}</calcite-button><calcite-block expanded .heading=${o(e.completion.detail)}><div .innerHTML=${n(e.completion.documentation)??""}></div>${e.examples?s`<div ${c(this._elementToMarkdown)}></div>`:null}</calcite-block></calcite-flow-item>`:null}render(){if(this.closed)return null;let e=(this.apiLibrary??[]).map(t=>this.renderApiCategory(t)),i=e.every(t=>!t);return s`<calcite-flow ${c(this.flowFocusHandler)}><calcite-flow-item heading-level=2 .heading=${this.messages.constantsandfunctions} closable @calciteFlowItemClose=${this._emitClose} .selected=${!this._selectedApiItem}><calcite-input .value=${this._filterValue} icon=magnifying-glass clearable @calciteInputInput=${this._updateFilterValue} class="sticky" scale=m></calcite-input>${this.loading?s`<calcite-loader scale=s type=indeterminate .label=${this.messages.loading??"Loading"}></calcite-loader>`:s`<calcite-list label="arcade api">${i?s`<div class="notice-container">${this.messages.noitems}</div>`:e}</calcite-list>`}</calcite-flow-item>${this.renderApiItemFlowItem()}</calcite-flow>`}};h("arcgis-language-api-panel",r);export{r as ArcgisLanguageApiPanel};
@@ -1,4 +0,0 @@
1
- /*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
2
- See https://js.arcgis.com/5.0/esri/copyright.txt for details.
3
- v5.0.0-next.140 */
4
- import{a as g}from"./4SD3AP46.js";import"./ZU5A2KCX.js";import{e as f}from"./YYSVEFB6.js";import{E as h,F as m,J as u,h as c,j as i,n as r,q as d}from"./DYMWCNFZ.js";import{c as n}from"./DWCX7EOA.js";import"./JTC4R6ZU.js";var b=c`:host{background-color:var(--calcite-color-foreground-1);.notice-container{margin:var(--calcite-spacing-xxs);padding:var(--calcite-spacing-sm);background-color:var(--calcite-color-foreground-1)}.sticky{position:sticky;top:0;z-index:10}calcite-flow{height:100%}calcite-list-item-group{background-color:var(--calcite-color-foreground-2);word-break:break-word}}`;function p(a){a.key==="Enter"&&a.stopPropagation()}var o=class extends m{constructor(){super(...arguments),this._beforeBack=async()=>{this.removeLastPanelRenderer(),this._filterValue=""},this.messages=g(),this._filterValue="",this._flowItemRenderers=[],this._mode="profile",this._mutationCounter=1,this.loading=!1,this.closed=!1,this.arcgisClose=r({bubbles:!1}),this.arcgisItemSelected=r({bubbles:!1})}static{this.properties={_filterValue:16,_flowItemRenderers:16,_mode:16,_mutationCounter:16,loading:5,modelId:1,closed:5,variable:0}}static{this.styles=b}load(){this._variableChanged()}willUpdate(e){e.has("modelId")&&(this._flowItemRenderers=[]),e.has("variable")&&this._variableChanged()}disconnectedCallback(){super.disconnectedCallback(),this._flowObserver?.disconnect()}_variableChanged(){this._mode=this.variable?.type==="featureSet"?"featureSet":"profile"}addPanelRenderer(e){this._flowItemRenderers=[...this._flowItemRenderers,e]}removeLastPanelRenderer(){this._flowItemRenderers=this._flowItemRenderers.slice(0,-1)}_isMode(e){return this._mode===e}flowFocusHandler(e){if(!e){this._flowObserver?.disconnect(),this._flowObserver=void 0;return}this._flowObserver||(this._flowObserver=new MutationObserver(()=>{f(e.querySelector("calcite-flow-item:last-child"),"calcite-input")}),this._flowObserver.observe(e,{attributes:!0,attributeFilter:["id"],childList:!0}))}_updateFilterValue(e){this._filterValue=e.currentTarget.value}_emitClose(){this.arcgisClose.emit()}_backToTop(){this._flowItemRenderers=[]}_emitItemSelected(e,t){if(t.nonInteractive)return;let s=e;(!s.key||s.key==="Enter")&&(e.preventDefault(),this.arcgisItemSelected.emit(t.snippet))}_showCollectionPanel(e,t){e.stopPropagation(),this.addPanelRenderer(s=>this.renderCollectionBasedVariable(t,!1,s))}_getHeadingForCollection(e){if(!e)return"";switch(this._mode){case"profile":return this.messages.profilevariables??"";case"featureSet":return this.messages.fields??""}}_getDescriptionForCollection(e){if(!e)return"";switch(this._mode){case"profile":return e.breadcrumb;case"featureSet":return e.variables[0]?.getLabel()??""}}renderCollectionBasedVariable(e,t=!1,s=!1){if(!e)return null;let l=this.loading;return!l&&!e.loaded&&(e.loadSource().then(()=>setTimeout(()=>{this._mutationCounter+=1})).catch(()=>{n("error",this,"Error loading collection"),l=!1}),l=!0),i`<calcite-flow-item heading-level=2 .heading=${this._getHeadingForCollection(e)} .description=${this._getDescriptionForCollection(e)} .beforeBack=${this._beforeBack} closable @calciteFlowItemClose=${this._emitClose} .selected=${s}><calcite-action slot=header-actions-end .text=${this.messages.backtotop??""} scale=m .hidden=${t||this._isMode("featureSet")} icon=chevrons-left icon-flip-rtl @click=${this._backToTop}></calcite-action><calcite-input .value=${this._filterValue} icon=magnifying-glass clearable @calciteInputInput=${this._updateFilterValue} class="sticky" scale=m .label=${this.messages.filterthevariablesbyname??""} name=variable-filter></calcite-input>${l?i`<calcite-loader scale=s type=indeterminate .label=${this.messages.loading??""}></calcite-loader>`:i`<calcite-list label=variables>${this.renderEditorVariables(e)}</calcite-list>`}</calcite-flow-item>`}renderEditorVariables(e){let t=d(this._filterValue),s=e.variables.filter(l=>l.passFilter(t));return s.length?s.map(l=>this.renderEditorVariable(l)):i`<div class="notice-container">${this.messages.noitems}</div>`}renderEditorVariable(e){switch(e.type){case"group":return this._isMode("featureSet")&&e.isHeader?i`<calcite-list-item-group .heading=${e.getLabel()}></calcite-list-item-group>`:this._isMode("featureSet")&&e._label?.code==="fields"?this.renderEditorVariables(e):i`<calcite-list-item-group .heading=${e.getLabel()}>${this.renderEditorVariables(e)}</calcite-list-item-group>`;default:return i`<calcite-list-item .label=${e.getLabel()} .description=${e.getDescription()} @calciteListItemSelect=${t=>this._emitItemSelected(t,e)} @keydown=${t=>this._emitItemSelected(t,e)}>${e.isCollection?i`<calcite-action slot=actions-end .text=${this.messages.expand??""} scale=s icon=chevron-right icon-flip-rtl @click=${t=>this._showCollectionPanel(t,e)} @keydown=${p}></calcite-action>`:null}${e.icon?i`<calcite-icon .icon=${e.icon} scale=s slot=content-start></calcite-icon>`:null}</calcite-list-item>`}}render(){return this.closed?null:!this.loading&&this.variable?.loaded&&!this.variable?.variables.length?i`<calcite-flow><calcite-flow-item heading-level=2 .heading=${this.messages.profilevariables} closable @calciteFlowItemClose=${this._emitClose}><div class="notice-container">${this.messages.noprofilevariablesmessage}</div></calcite-flow-item></calcite-flow>`:i`<calcite-flow ${h(this.flowFocusHandler)}>${this.renderCollectionBasedVariable(this.variable,!0,this._flowItemRenderers.length===0)}${this._flowItemRenderers.map((e,t,s)=>e(t===s.length-1))}</calcite-flow>`}};u("arcgis-editor-variables",o);export{o as ArcgisEditorVariables};
@@ -1,4 +0,0 @@
1
- /*! All material copyright Esri, All Rights Reserved, unless otherwise specified.
2
- See https://js.arcgis.com/5.0/esri/copyright.txt for details.
3
- v5.0.0-next.140 */
4
- import d from"./7ZISFGDD.js";import c from"./FVV4UAL5.js";import b from"./6HNTPPBF.js";import{a as M}from"./4SD3AP46.js";import"./ZU5A2KCX.js";import a from"./IVLAW36F.js";import"./G5T4EI7D.js";import"./ONS4ZING.js";import"./7VAC6CMK.js";import"./YP3EICK5.js";import"./LJIVTQAR.js";import"./YYSVEFB6.js";import{D,E as C,F as B,G as r,J as I,K as L,h as E,j as i,l as f,n as $,s as y}from"./DYMWCNFZ.js";import{a as w,c as R,d as o}from"./DWCX7EOA.js";import{Ll as k,Rc as j,lk as z}from"./36M2T4ND.js";import"./JTC4R6ZU.js";export default $arcgis.t(([H,,{a:F,h:A},l,{a:T,b:U}])=>{z();j();var V=E`:host{height:100%}calcite-tooltip:not([calcite-hydrated])>*{display:none}.main-action-bar{calcite-action-group{padding-inline-end:var(--calcite-spacing-sm)}calcite-action-group calcite-action{padding-inline-end:var(--calcite-spacing-sm)}calcite-action-group calcite-action:not(:first-child){padding-inline-start:var(--calcite-spacing-sm)}calcite-action-group:last-child{border-inline-end-width:0px}calcite-action-group:not(:first-child){padding-inline-start:var(--calcite-spacing-sm)}}`,G="https://services6.arcgis.com/HXHga6CfMLMBOlBX/ArcGIS/rest/services/survey123_6e349a50b4504ca6b6107216d568db5f_form/FeatureServer/0",a=(s,e)=>R(s,"Arcade Assistant",e),X=s=>{let{aiAssistantsEnabled:e}=s;return e===void 0?(a("warn","`areAiAssistantsEnabled` is not defined in the organizations settings."),!1):e},K=s=>!(!s||!("id"in s)),q=async s=>(await H.getCredential(s)).token;async function J({portalUrl:s,profile:e}){if(!K(e))return a("warn","Addon initialization failed. Reason: unsupported profile."),{shouldRender:!1};let t=s.replace(/\/sharing\/rest(\/.*)?$/iu,"").replace(/\/$/u,""),n=await q(s),c=`${t}/sharing/rest/portals/self?f=json&token=${n}`,h=`${t}/sharing/rest/portals/self/settings?f=json&token=${n}`,p=`${t}/sharing/rest/portals/self/signinSettings?f=json&token=${n}`,u=await Promise.allSettled([fetch(c,{credentials:"include"}).then(d=>d.json()),fetch(h,{credentials:"include"}).then(d=>d.json()),fetch(p,{credentials:"include"}).then(d=>d.json())]),[g,_,m]=u,S=g.status==="fulfilled"?g.value:(a("warn",`Failed to fetch selfUrl. Reason: ${g.reason}.`),{}),P=_.status==="fulfilled"?_.value:(a("warn",`Failed to fetch settingsUrl. Reason: ${_.reason}.`),{}),N=m.status==="fulfilled"?m.value:(a("warn",`Failed to fetch signinSettingsUrl. Reason: ${m.reason}.`),{}),x=S?.helperServices?.aiAssistantServices?.url;if(!x)return a("warn","Service URL is not available in the portal self response."),{shouldRender:!1};let O=S.helpBase||"";if(!P)return a("warn","Settings response is not available."),{shouldRender:!1};let v=X(P);return N.blockBetaApps===!0&&(a("warn","Arcade Assistant is blocked by the organization settings. To enable it, do not block beta apps in the organization settings."),v=!1),{shouldRender:!0,serviceUrl:x,helpBase:O,assistantsEnabled:v,feedbackServiceUrl:G}}var b=class extends B{constructor(){super(...arguments),this._codeEditorElt=D(),this._componentReadyDefer=new w,this._disposables=[],this._editorProfilePromise=Promise.resolve(void 0),this.messages=M(),this._modelId=y(),this._openArcadeHelp=()=>void window.open(F,"Arcade Help"),this._toggleSidePanel=e=>{if(!e.target)return;let t=e.target?.dataset.panelName??"none";this.openedSidePanel=t===this.openedSidePanel?"none":t,this.openedSidePanel==="none"&&this._codeEditorElt.value?.setFocus().catch(o(this))},this._consoleLogs=[],this._executingScript=!1,this._preparingArcade=!1,this._resultPanel="output",this._showExecutionPanel=!1,this._arcadeAssistantRemoteState={shouldRender:!1},this.hideDocumentationActions=!1,this.hideSideBar=!1,this.openedSidePanel="none",this.script="",this.sideActionBarExpanded=!1,this.arcgisDiagnosticsChange=$({bubbles:!1}),this.arcgisScriptChange=$({bubbles:!1})}static{this.properties={_apiLibrary:16,_consoleLogs:16,_editorProfile:16,_executingScript:16,_executionResult:16,_preparingArcade:16,_resultPanel:16,_showExecutionPanel:16,_arcadeAssistantRemoteState:16,editorInstance:32,editorOptions:0,hideDocumentationActions:5,hideSideBar:5,openedSidePanel:3,profile:0,script:1,sideActionBarExpanded:7,snippets:0,suggestions:0,testData:0,customPanels:0,arcadeAssistant:0}}static{this.styles=[V]}get editorInstance(){return this._codeEditorElt.value?.editorInstance}async getEditorInstance(){return await this._componentReadyDefer.promise,this._codeEditorElt.value?.editorInstance}async getScript(){return await this._componentReadyDefer.promise,this._codeEditorElt.value?.value}async getTestResult(){if(!this.testData)return{type:"error",value:"Missing test data",error:null};let e=await this._editorProfilePromise;if(!e)return{type:"error",value:"Missing editor profile",error:null};await this._componentReadyDefer.promise;let t=this._codeEditorElt.value?.value;return await A(e.definition,t,this.testData)}async setFocus(){await this._componentReadyDefer.promise,await this._codeEditorElt.value?.setFocus()}async load(){let e=L("./assets");T(e),await this._updateDataModelDeps(),await this._updateArcadeAssistantRemoteState()}willUpdate(e){(e.has("messages")||e.has("profile"))&&this.hasUpdated&&this._updateDataModelDeps(),e.has("testData")&&this._testDataChanged(),e.has("snippets")&&l.updateApiContextForModel(this._modelId,{snippets:this.snippets}),e.has("arcadeAssistant")&&this._updateArcadeAssistantRemoteState()}async loaded(){this._componentReadyDefer.resolve(),await this._updateApiLibrary();let e=await U();this._disposables.push(e.onDiagnosticsChange(t=>!this._preparingArcade&&this.arcgisDiagnosticsChange.emit(t.diagnostics))),this.testData&&this._addExecuteScriptAction()}disconnectedCallback(){for(super.disconnectedCallback();this._disposables.length;)this._disposables.pop()?.dispose()}async _updateDataModelDeps(){await this._updateEditorProfile(),await this._updateApiLibrary()}_testDataChanged(){!this.testData&&this._executeScriptAction&&(this._disposeSafely(this._executeScriptAction),this._executeScriptAction=void 0),this.testData&&!this._executeScriptAction&&this._addExecuteScriptAction(),this._showExecutionPanel&&this._executeScript().catch(o(this))}async _updateEditorProfile(){this._preparingArcade=!0;try{await l.setProfileForModel(this._modelId,this.profile,{locale:this.messages._t9nLocale,snippets:this.snippets}),this._editorProfile=l.getEditorProfileForModel(this._modelId)}catch{this._editorProfile=void 0}finally{this._editorProfilePromise=Promise.resolve(this._editorProfile),this._preparingArcade=!1}}async _updateApiLibrary(){this._apiLibrary=await l.getApiLibraryForModel(this._modelId)}async _executeScript(){let e=this.testData;if(!this._codeEditorElt.value||!e)return;let t=await this._editorProfilePromise;if(!t){this._executionResult={type:"error",value:"Missing editor profile",error:null};return}this._showExecutionPanel=!0,this._executingScript=!0,this._consoleLogs=[],setTimeout(()=>void(async()=>{let n=this._codeEditorElt.value?.value;this._executionResult=await A(t.definition,n,e,c=>setTimeout(()=>this._consoleLogs=[...this._consoleLogs,c],0)),this._executingScript=!1})(),0)}_toggleShowExecutionPanel(){this._showExecutionPanel=!this._showExecutionPanel}_toggleSideActionBarExpanded(){this.sideActionBarExpanded=!this.sideActionBarExpanded}_onCodeEditorValueChange(e){e.stopPropagation(),this.script=e.detail,this.arcgisScriptChange.emit(e.detail)}_insertAsSnippet(e){this._codeEditorElt.value?.insertSnippet(e.detail).catch(o(this))}_insertAsText(e){this._insertText(e.detail)}_insertText(e){this._codeEditorElt.value?.insertText(e).catch(o(this))}_onResultPanelChange(e){this._resultPanel=e.detail}_onExecutionPanelClose(){this._showExecutionPanel=!1}_addExecuteScriptAction(){let e=this.editorInstance?.addAction({id:"run-script",label:"Run Arcade Expression",keybindings:[k.F5],contextMenuGroupId:"code",contextMenuOrder:1,run:()=>{this.testData&&this._executeScript().catch(o(this))}});e&&(this._executeScriptAction=e,this._disposables.push(e))}_disposeSafely(e){let t=this._disposables.indexOf(e);t!==-1&&this._disposables.splice(t,1),e.dispose()}async _updateArcadeAssistantRemoteState(){this.arcadeAssistant&&(this._arcadeAssistantRemoteState=await J({...this.arcadeAssistant,profile:this.profile}))}renderMainActionBar(){return this.testData?i`<calcite-action-bar class="main-action-bar" layout=horizontal scale=s expanded expand-disabled slot=top-action-bar><calcite-action-group scale=s><calcite-action .text=${this.messages.run??""} text-enabled icon=play scale=s .loading=${this._preparingArcade} @click=${()=>void this._executeScript().catch(o(this))}></calcite-action>${this._executionResult?i`<calcite-action .text=${this.messages.lastresults??""} .active=${this._showExecutionPanel} text-enabled icon=access-string-results icon-flip-rtl scale=s @click=${this._toggleShowExecutionPanel}></calcite-action>`:null}</calcite-action-group></calcite-action-bar>`:null}renderMainPanel(){return i`<arcgis-code-editor slot=editor .editorOptions=${this.editorOptions} .language=${l.languageId} .value=${this.script??""} .modelId=${this._modelId} @arcgisValueChange=${this._onCodeEditorValueChange} ${C(this._codeEditorElt)}></arcgis-code-editor>`}renderAction({id:e,label:t,icon:n,active:c,panelName:h,iconFlipRtl:p=!1,onClick:u=this._toggleSidePanel}){return i`<calcite-action id=${e??f} .text=${t} .textEnabled=${this.sideActionBarExpanded} .icon=${n} .active=${c} @click=${u} data-panel-name=${h??f} .iconFlipRtl=${p}></calcite-action>${!this.sideActionBarExpanded&&i`<calcite-tooltip .referenceElement=${e}><span>${t}</span></calcite-tooltip>`||""}`}renderSideActionBar(){return this.hideSideBar?null:i`<calcite-action-bar slot=side-action-bar class="side-action-bar" .expanded=${this.sideActionBarExpanded} position=end @calciteActionBarToggle=${this._toggleSideActionBarExpanded}><calcite-action-group>${this.renderAction({id:"profile-variables-action",label:this.messages.profilevariables??"",icon:"profile-variables",active:this.openedSidePanel==="variables",panelName:"variables"})}${this.renderAction({id:"function-action",label:this.messages.constantsandfunctions??"",icon:"function",active:this.openedSidePanel==="api",panelName:"api"})}${this.suggestions?.length?this.renderAction({id:"suggestions-action",label:this.messages.suggestions??"",icon:"lightbulb",active:this.openedSidePanel==="suggestions",panelName:"suggestions"}):null}${this._arcadeAssistantRemoteState.shouldRender&&this.renderAction({id:"arcade-assistant-action",label:this.messages.arcadeassistant??"Arcade assistant",icon:"effects",active:this.openedSidePanel==="arcade-assistant",panelName:"arcade-assistant"})||""}${this.customPanels?.map(e=>e.enabled===!1?null:this.renderAction({id:e.id,label:e.name,icon:e.icon,active:this.openedSidePanel===e.id,panelName:e.id}))}${this.hideDocumentationActions?null:this.renderAction({id:"developer-website-action",label:this.messages.help??"",icon:"question",active:!1,panelName:"none",iconFlipRtl:this.messages._lang==="ar",onClick:this._openArcadeHelp})}</calcite-action-group></calcite-action-bar>`}renderSidePanel(){if(this.hideSideBar)return null;let{openedSidePanel:e}=this;return i`<arcgis-language-api-panel slot=side-panel class=${r(e==="api"?"":"hidden")} .loading=${this._preparingArcade} .apiLibrary=${this._apiLibrary} .hideDocumentationActions=${this.hideDocumentationActions} @arcgisItemSelected=${this._insertAsSnippet} @arcgisClose=${this._toggleSidePanel} data-panel-name=none .closed=${e!=="api"}></arcgis-language-api-panel><arcgis-editor-variables slot=side-panel class=${r(e==="variables"?"":"hidden")} .loading=${this._preparingArcade} .modelId=${this._modelId} @arcgisItemSelected=${this._insertAsText} @arcgisClose=${this._toggleSidePanel} data-panel-name=none .variable=${this._editorProfile} .closed=${e!=="variables"}></arcgis-editor-variables>${this.suggestions?.length&&i`<arcgis-arcade-suggestions slot=side-panel class=${r(e==="suggestions"?"":"hidden")} .closed=${e!=="suggestions"} .suggestions=${this.suggestions} @arcgisItemSelected=${this._insertAsText} @arcgisClose=${this._toggleSidePanel} data-panel-name=none></arcgis-arcade-suggestions>`||""}${this.arcadeAssistant&&this._arcadeAssistantRemoteState.shouldRender&&i`<arcgis-arcade-coding-assistant slot=side-panel class=${r(e==="arcade-assistant"?"":"hidden")} .closed=${e!=="arcade-assistant"} .insertText=${this._insertText.bind(this)} .closePanel=${this._toggleSidePanel} .portalUrl=${this.arcadeAssistant.portalUrl} .serviceUrl=${this._arcadeAssistantRemoteState.serviceUrl} .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=>i`<calcite-flow slot=side-panel class=${r(e===t.id?"":"hidden")}>${t?.useFlows?t.renderer?.({closePanel:this._toggleSidePanel,insertText:this._insertText.bind(this),closed:e!==t.id,editorRef:this.el}):i`<calcite-flow-item .heading=${t.name} heading-level=2 closable .closed=${e!==t.id} @calciteFlowItemClose=${this._toggleSidePanel} .description=${t.description}>${t.renderer?.({closePanel:this._toggleSidePanel,insertText:this._insertText.bind(this),closed:e!==t.id,editorRef:this.el})}</calcite-flow-item>`}</calcite-flow>`)}`}renderResultsPanel(){return this._showExecutionPanel?i`<arcgis-arcade-results slot=results-panel .openedResultPanel=${this._resultPanel} .loading=${this._executingScript} .result=${this._executionResult} .consoleLogs=${this._consoleLogs} @arcgisOpenedResultPanelChange=${this._onResultPanelChange} @arcgisClose=${this._onExecutionPanelClose}></arcgis-arcade-results>`:null}render(){return i`<arcgis-code-editor-shell>${this.renderMainActionBar()}${this.renderMainPanel()}${this.renderResultsPanel()}${this.renderSidePanel()}${this.renderSideActionBar()}</arcgis-code-editor-shell>`}};I("arcgis-arcade-editor",b);return b},"identity/IdentityManager",a,b,c,d)