UNPKG

@arcgis/map-components

Version:
56 lines (55 loc) 3.89 kB
import { c as t } from "../../chunks/runtime.js"; import { usePropertyChange as i } from "@arcgis/components-controllers"; import s from "@arcgis/core/widgets/Editor.js"; import { LitElement as o, createEvent as a, noShadowRoot as l } from "@arcgis/lumina"; import { m as n } from "../../chunks/useWidget.js"; import { css as r } from "@lit/reactive-element/css-tag.js"; /*! All material copyright Esri, All Rights Reserved, unless otherwise specified. See https://js.arcgis.com/4.32/esri/copyright.txt for details. v4.32.13 */ const g = r`@layer{arcgis-editor{display:block}}`, d = n(s); class h extends o { constructor() { super(...arguments), this.widget = d(this), this.viewModel = this.widget.viewModel, this.activeWorkflow = this.widget.activeWorkflow, this.autoDestroyDisabled = !1, this.headingLevel = this.widget.headingLevel, this.hideCreateFeaturesSection = this.widget.visibleElements.createFeaturesSection, this.hideEditFeaturesSection = this.widget.visibleElements.editFeaturesSection, this.hideLabelsToggle = this.widget.visibleElements.labelsToggle, this.hideSnappingControlsElementsEnabledToggle = this.widget.visibleElements.snappingControlsElements.enabledToggle, this.hideSnappingControlsElementsFeatureEnabledToggle = this.widget.visibleElements.snappingControlsElements.featureEnabledToggle, this.hideSnappingControlsElementsLayerList = this.widget.visibleElements.snappingControlsElements.layerList, this.hideSnappingControlsElementsSelfEnabledToggle = this.widget.visibleElements.snappingControlsElements.selfEnabledToggle, this.hideTooltipsToggle = this.widget.visibleElements.tooltipsToggle, this.icon = this.widget.icon, this.label = this.widget.label, this.labelOptions = this.widget.labelOptions, this.layerInfos = this.widget.layerInfos, this.position = "bottom-left", this.showSnappingControlsElementsHeader = this.widget.visibleElements.snappingControlsElements.header, this.snappingOptions = this.widget.snappingOptions, this.state = this.viewModel.state, this.supportingWidgetDefaults = this.widget.supportingWidgetDefaults, this.tooltipOptions = this.widget.tooltipOptions, this.arcgisPropertyChange = i()("activeWorkflow", "state"), this.arcgisReady = a(); } static { this.properties = { activeWorkflow: 0, autoDestroyDisabled: 5, headingLevel: 9, hideCreateFeaturesSection: 5, hideEditFeaturesSection: 5, hideLabelsToggle: 5, hideSnappingControlsElementsEnabledToggle: 5, hideSnappingControlsElementsFeatureEnabledToggle: 5, hideSnappingControlsElementsLayerList: 5, hideSnappingControlsElementsSelfEnabledToggle: 5, hideTooltipsToggle: 5, icon: 1, label: 1, labelOptions: 0, layerInfos: 0, position: 1, referenceElement: 1, showSnappingControlsElementsHeader: 5, snappingOptions: 0, state: 3, supportingWidgetDefaults: 0, tooltipOptions: 0 }; } static { this.shadowRootOptions = l; } static { this.styles = g; } // #endregion // #region Public Methods async cancelWorkflow() { await this.widget?.cancelWorkflow(); } async deleteFeatureFromWorkflow() { await this.widget?.deleteFeatureFromWorkflow(); } /** Permanently destroy the component */ async destroy() { await this.manager.destroy(); } async startCreateFeaturesWorkflowAtFeatureCreation(e) { await this.widget?.startCreateFeaturesWorkflowAtFeatureCreation(e); } async startCreateFeaturesWorkflowAtFeatureTypeSelection() { await this.widget?.startCreateFeaturesWorkflowAtFeatureTypeSelection(); } async startUpdateWorkflowAtFeatureEdit(e) { await this.widget?.startUpdateWorkflowAtFeatureEdit(e); } async startUpdateWorkflowAtFeatureSelection() { await this.widget?.startUpdateWorkflowAtFeatureSelection(); } async startUpdateWorkflowAtMultipleFeatureSelection(e) { await this.widget?.startUpdateWorkflowAtMultipleFeatureSelection(e); } } t("arcgis-editor", h); export { h as ArcgisEditor };