UNPKG

@arcgis/map-components

Version:
57 lines (56 loc) 4.03 kB
import { c as i } from "../../chunks/runtime.js"; import { usePropertyChange as s } from "@arcgis/components-controllers"; import { reEmitEvent as a } from "@arcgis/components-controllers/accessor"; import o from "@arcgis/core/widgets/Features.js"; import { LitElement as r, createEvent as n, noShadowRoot as h } from "@arcgis/lumina"; import { m as d } from "../../chunks/useWidget.js"; import { css as l } 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 c = l`@layer{arcgis-features{display:flex;flex-direction:column;overflow:hidden;.esri-features{flex:1 1 auto;overflow:hidden}}}`, g = d(o); class u extends r { constructor() { super(...arguments), this.widget = g(this), this.viewModel = this.widget.viewModel, this.actions = this.viewModel.actions, this.active = this.widget.active, this.autoDestroyDisabled = !1, this.collapsed = this.widget.collapsed, this.content = this.widget.content, this.featureNavigationTop = this.widget.featureNavigationTop, this.featureViewModelAbilities = this.viewModel.featureViewModelAbilities, this.features = this.widget.features, this.featuresPerPage = this.viewModel.featuresPerPage, this.featuresTitle = this.widget.title, this.goToOverride = this.viewModel.goToOverride, this.headingLevel = this.widget.headingLevel, this.headerActions = this.widget.headerActions, this.hideActionBar = this.widget.visibleElements.actionBar, this.hideCloseButton = this.widget.visibleElements.closeButton, this.hideFeatureMenuHeading = this.widget.visibleElements.featureMenuHeading, this.hideFeatureNavigation = this.widget.visibleElements.featureNavigation, this.hideFlow = this.widget.visibleElements.flow, this.hideHeading = this.widget.visibleElements.heading, this.hideSpinner = this.widget.visibleElements.spinner, this.icon = this.widget.icon, this.includeDefaultActions = this.viewModel.includeDefaultActions, this.initialDisplayMode = this.widget.initialDisplayMode, this.label = this.widget.label, this.map = this.widget.map, this.position = "bottom-left", this.promises = this.widget.promises, this.selectedFeature = this.widget.selectedFeature, this.selectedFeatureIndex = this.widget.selectedFeatureIndex, this.showCollapseButton = this.widget.visibleElements.collapseButton, this.spatialReference = this.widget.spatialReference, this.state = this.viewModel.state, this.timeZone = this.widget.timeZone, this.arcgisPropertyChange = s()("selectedFeature", "selectedFeatureIndex", "state"), this.arcgisReady = n(), this.arcgisTriggerAction = a(() => this.widget, "trigger-action"); } static { this.properties = { actions: 0, active: 7, autoDestroyDisabled: 5, collapsed: 7, content: 1, featureNavigationTop: 5, featureViewModelAbilities: 0, features: 0, featuresPerPage: 9, featuresTitle: 1, goToOverride: 0, headingLevel: 9, headerActions: 0, hideActionBar: 5, hideCloseButton: 5, hideFeatureMenuHeading: 5, hideFeatureNavigation: 5, hideFlow: 5, hideHeading: 5, hideSpinner: 5, icon: 1, includeDefaultActions: 5, initialDisplayMode: 1, label: 1, map: 0, position: 1, promises: 0, referenceElement: 1, selectedFeature: 0, selectedFeatureIndex: 9, showCollapseButton: 5, spatialReference: 0, state: 3, timeZone: 1 }; } static { this.shadowRootOptions = h; } static { this.styles = c; } // #endregion // #region Public Methods async clear() { this.widget?.clear(); } async close() { this.widget?.close(); } /** Permanently destroy the component */ async destroy() { await this.manager.destroy(); } async fetchFeatures(e, t) { return await this.widget?.fetchFeatures(e, t); } async next() { return this.widget?.next(); } async open(e) { this.widget?.open(e); } async previous() { return this.widget?.previous(); } async triggerAction(e) { this.widget?.triggerAction(e); } } i("arcgis-features", u); export { u as ArcgisFeatures };