UNPKG

@arcgis/map-components

Version:
83 lines (81 loc) 3.29 kB
/// <reference types="@arcgis/core/interfaces.d.ts" /> /// <reference types="../../index.d.ts" /> import { Use } from '@arcgis/components-controllers'; import { Nil } from '@arcgis/components-utils'; import { default as ZoomViewModel } from '@arcgis/core/widgets/Zoom/ZoomViewModel.js'; import { JsxNode, PublicLitElement as LitElement, TargetedEvent } from '@arcgis/lumina'; import { ArcgisReferenceElement } from '../../utils/component-utils'; type Layout = "horizontal" | "vertical"; declare const useZoomViewModel: (component: import('@arcgis/components-controllers').StencilLifecycles & { manager: import('@arcgis/components-controllers').ControllerManager; el: HTMLElement; autoDestroyDisabled?: boolean; destroy?: () => Promise<void>; } & Pick<ZoomViewModel, never> & { reactiveUtils?: typeof __esri.reactiveUtils; state?: "ready" | "disabled" | undefined; icon: Nil | string; label: Nil | string; referenceElement: ArcgisReferenceElement | Nil | string; arcgisReady: import('@arcgis/components-controllers').EventEmitter; position: __esri.UIPosition; arcgisPropertyChange: import('@arcgis/components-controllers').EventEmitter<{ name: string; }> | undefined; el: HTMLElement & { childElem?: HTMLElement & { ownedBy?: HTMLElement; }; view?: __esri.MapView | __esri.SceneView | undefined; }; autoDestroyDisabled: boolean; destroy: () => Promise<void>; }, options?: { editConstructorProperties(props: unknown): unknown; } | undefined) => ZoomViewModel; /** Zoom component allows users to zoom in/out within a view. */ export declare class ArcgisZoom extends LitElement { private messages: Partial<{ componentLabel: string; zoomIn: string; zoomOut: string; }> & import('@arcgis/components-controllers').T9nMeta<{ componentLabel: string; zoomIn: string; zoomOut: string; }>; /** * If true, the component will not be destroyed automatically when * it is disconnected from the document. This is useful when you * want to move the component to a different place on the page, or * temporary hide it. If this is set, make sure to call the * \`destroy\` method when you are done to prevent memory leaks. */ autoDestroyDisabled: boolean; /** Icon which represents the component. */ icon: Nil | string; /** The component's default label. */ label: Nil | string; /** Determines the layout/orientation of the Zoom widget. */ layout: Layout; /** Replace localized message strings with your own strings. */ messageOverrides?: typeof this.messages._overrides; position: __esri.UIPosition; referenceElement: ArcgisReferenceElement | Nil | string; /** * The current state of the component. */ readonly state: "ready" | "disabled"; /** Permanently destroy the component */ destroy(): Promise<void>; /** Zooms the view in by an LOD factor of 0.5. */ zoomIn(): Promise<void>; /** Zooms the view out by an LOD factor of 2. */ zoomOut(): Promise<void>; readonly arcgisPropertyChange: TargetedEvent<this, { name: "state"; }>; readonly arcgisReady: TargetedEvent<this, undefined>; } export {};