UNPKG

@arcgis/map-components

Version:
44 lines (43 loc) 2.57 kB
import { c as i } from "../../chunks/runtime.js"; import { usePropertyChange as s } from "@arcgis/components-controllers"; import a from "@arcgis/core/widgets/Feature.js"; import { LitElement as n, createEvent as o, 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.14 */ const r = l`@layer{arcgis-feature{display:block}}`, c = d(a); class p extends n { constructor() { super(...arguments), this.widget = c(this), this.viewModel = this.widget.viewModel, this.autoDestroyDisabled = !1, this.defaultPopupTemplateEnabled = this.widget.defaultPopupTemplateEnabled, this.graphic = this.widget.graphic, this.headingLevel = this.widget.headingLevel, this.hideContentAttachments = this.widget.visibleElements.content.attachments, this.hideContentExpression = this.widget.visibleElements.content.expression, this.hideContentFields = this.widget.visibleElements.content.fields, this.hideContentMedia = this.widget.visibleElements.content.media, this.hideContentText = this.widget.visibleElements.content.text, this.hideLastEditInfo = this.widget.visibleElements.lastEditedInfo, this.hideTitle = this.widget.visibleElements.title, this.icon = this.widget.icon, this.label = this.widget.label, this.location = this.viewModel.location, this.map = this.widget.map, this.position = "bottom-left", this.spatialReference = this.widget.spatialReference, this.state = this.viewModel.state, this.arcgisPropertyChange = s()("state"), this.arcgisReady = o(); } static { this.properties = { autoDestroyDisabled: 5, defaultPopupTemplateEnabled: 5, graphic: 0, headingLevel: 9, hideContentAttachments: 5, hideContentExpression: 5, hideContentFields: 5, hideContentMedia: 5, hideContentText: 5, hideLastEditInfo: 5, hideTitle: 5, icon: 1, label: 1, location: 0, map: 0, position: 1, referenceElement: 1, spatialReference: 0, state: 3 }; } static { this.shadowRootOptions = h; } static { this.styles = r; } // #endregion // #region Public Methods /** Permanently destroy the component */ async destroy() { await this.manager.destroy(); } async nextMedia(t) { this.widget?.nextMedia(t); } async previousMedia(t) { this.widget?.previousMedia(t); } async setActiveMedia(t, e) { this.widget?.setActiveMedia(t, e); } } i("arcgis-feature", p); export { p as ArcgisFeature };