UNPKG

@arcgis/map-components

Version:
168 lines (166 loc) 7.59 kB
/// <reference types="@arcgis/core/interfaces.d.ts" /> /// <reference types="../../index.d.ts" /> import { Use } from '@arcgis/lumina/controllers'; import { default as Bookmarks } from '@arcgis/core/widgets/Bookmarks.js'; import { PublicLitElement as LitElement, TargetedEvent } from '@arcgis/lumina'; import { ArcgisReferenceElement } from '../../utils/component-utils'; declare const useBookmarksWidget: (component: LitElement & Pick<Bookmarks, "icon" | "label" | "viewModel" | "disabled" | "goToOverride" | "dragEnabled" | "filterPlaceholder" | "filterText" | "defaultCreateOptions" | "bookmarks" | "defaultEditOptions"> & { state?: unknown; viewModel?: __esri.BookmarksViewModel | undefined; closed?: boolean; icon: import('@arcgis/components-utils').Nil | string; label: import('@arcgis/components-utils').Nil | string; referenceElement?: ArcgisReferenceElement | string; position: __esri.UIPosition; arcgisReady: import('@arcgis/lumina').EventEmitter; arcgisPropertyChange: import('@arcgis/lumina').EventEmitter<{ name: string; }> | undefined; el: HTMLElement & { childElem?: HTMLElement & { ownedBy?: HTMLElement; }; view?: __esri.LinkChartView | __esri.MapView | __esri.SceneView; }; autoDestroyDisabled: boolean; destroy: () => Promise<void>; }) => Bookmarks; /** * The Bookmarks component allow end users to quickly navigate to a particular area of interest. It displays a list of [bookmarks](https://developers.arcgis.com/javascript/latest/api-reference/esri-webmap-Bookmark.html), which are typically defined inside the [WebMap](https://developers.arcgis.com/javascript/latest/api-reference/esri-WebMap.html#bookmarks). * * [Read more...](https://developers.arcgis.com/javascript/latest/references/map-components/arcgis-bookmarks/) */ export declare class ArcgisBookmarks extends LitElement { /** * Emitted when the component's close button is clicked. * * @since 4.33 */ readonly arcgisClose: TargetedEvent<this>; /** * 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 temporarily hide it. If this * is set, make sure to call the [destroy](https://developers.arcgis.com/javascript/latest/references/map-components/arcgis-bookmarks/#destroy) method when you are done to * prevent memory leaks. * * @default false */ autoDestroyDisabled: boolean; /** * A collection of [Bookmark](https://developers.arcgis.com/javascript/latest/api-reference/esri-webmap-Bookmark.html)s. * * [Read more...](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-Bookmarks.html#bookmarks) */ bookmarks: __esri.Collection<__esri.Bookmark>; /** * Indicates whether a component is closed. When `true`, the component will be hidden. * * @since 4.33 * @default false */ closed: boolean; /** * Specifies how new bookmarks will be created if [visibleElements.addBookmarkButton](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-Bookmarks.html#VisibleElements) is set to `true`. * * [Read more...](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-Bookmarks.html#defaultCreateOptions) */ defaultCreateOptions: __esri.BookmarkOptions; /** * Specifies how bookmarks will be edited, if [visibleElements.editBookmarkButton](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-Bookmarks.html#VisibleElements) is set to `true`. * * [Read more...](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-Bookmarks.html#defaultEditOptions) */ defaultEditOptions: __esri.BookmarkOptions; /** * When true, the widget is visually withdrawn and cannot be interacted with. * * @default false */ disabled: boolean; /** * Indicates if a Bookmark is able to be dragged in order to update its position in the list. * * @default false */ dragEnabled: boolean; /** * Defines the text used as a placeholder when visibleElements.filter is set to `true`. * * [Read more...](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-Bookmarks.html#filterPlaceholder) */ filterPlaceholder: string; /** * Defines the text used to filter the bookmarks when visibleElements.filter is set to `true`. * * [Read more...](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-Bookmarks.html#filterText) */ filterText: string; /** * This function provides the ability to override either the * [MapView goTo()](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#goTo) or * [SceneView goTo()](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-SceneView.html#goTo) methods. * * [Read more...](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-Bookmarks.html#goToOverride) * * @since 4.33 */ goToOverride: nullish | __esri.GoToOverride; /** @default false */ hideFlow: boolean; /** @default false */ hideThumbnail: boolean; /** @default false */ hideTime: boolean; /** * Icon which represents the component. * Typically used when the component is controlled by another component (e.g. by the Expand component). * * @see [Calcite Icons](https://developers.arcgis.com/calcite-design-system/icons/) * @default "bookmark" */ icon: string; /** * The widget's default label. * * [Read more...](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-Bookmarks.html#label) */ label: string; /** @default "bottom-left" */ position: __esri.UIPosition; /** * By assigning the `id` attribute of the Map or Scene component to this property, you can position a child component anywhere in the DOM while still maintaining a connection to the Map or Scene. * * @see [Associate components with a Map or Scene component](https://developers.arcgis.com/javascript/latest/programming-patterns/#associate-components-with-a-map-or-scene-component) */ referenceElement?: ArcgisReferenceElement | string; /** @default false */ showAddBookmarkButton: boolean; /** @default false */ showCloseButton: boolean; /** @default false */ showCollapseButton: boolean; /** @default false */ showEditBookmarkButton: boolean; /** @default false */ showFilter: boolean; /** @default false */ showHeading: boolean; /** * The current state of the component. * * @default "ready" */ readonly state: "ready" | "loading"; /** Permanently destroy the component. */ destroy(): Promise<void>; readonly arcgisEdit: TargetedEvent<this, __esri.BookmarksBookmarkEditEvent>; /** Emitted when the value of a property is changed. Use this to listen to changes to properties. */ readonly arcgisPropertyChange: TargetedEvent<this, { name: "state"; }>; /** Emitted when the component associated with a map or scene view is is ready to be interacted with. */ readonly arcgisReady: TargetedEvent<this, void>; readonly arcgisSelect: TargetedEvent<this, __esri.BookmarksBookmarkSelectEvent>; } export {};