Use dark colors for code blocks Copy
1
import "@arcgis/map-components/components/arcgis-features";
No specific import is needed for this component.
The Features component allows users to view a feature's popupTemplate content such as attributes, actions, related records, etc., without having to be tied to the View.
Demo Properties activeactive: boolean
Indicates if the widget is active when it is visible and is not waiting for results.
Property
autoDestroyDisabled: boolean
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 method when you are done to prevent memory leaks.
Property
closed: boolean
Indicates whether a component is closed. When true
, the component will be hidden.
collapsed: boolean
Indicates whether the popup displays its content.
Property
The content of the Features widget.
Property
featureNavigationTop: boolean
Indicates whether the feature navigation arrows are displayed at the top of the widget.
Property
An array of features associated with the Features widget.
Property
featuresPerPage: number
The number of features to fetch at one time.
Property
featuresTitle: string
The title of the Features widget.
Property
Defines the specific abilities that can be used when querying and displaying content.
Property
goToOverride: (((view: MapView | SceneView, goToParameters: GoToParameters) => void))
This function provides the ability to override either the MapView goTo() or SceneView goTo() methods.
Property
The actions that are displayed in the header of the widget.
Property
headingLevel: number
Indicates the heading level to use for the title of the widget.
Property
hideActionBar: boolean
Indicates whether to hide the action bar that holds the feature's action.
Property
hideCloseButton: boolean
Indicates whether to hide the close button.
Property
hideFeatureMenuHeading: boolean
Indicates whether to hide a heading and description on the widget feature menu list.
Property
hideFeatureNavigation: boolean
Indicates whether to hide pagination for feature navigation. This allows the user to scroll through various selected features using pagination arrows.
Property
hideFlow: boolean
Determines whether the component should be shown within its built-in flow component or if the flow component should be excluded. The component will be displayed within its original flow component if false
. The flow component will be omitted if set to true
. To place the component into an existing Calcite flow component, set this property to false
.
Property
hideHeading: boolean
Indicates whether is hide the heading.
Property
hideSpinner: boolean
Indicates whether to hide the loading spinner.
Property
icon: string
Icon which represents the component. Typically used when the component is controlled by another component (e.g. by the Expand component).
Property
includeDefaultActions: boolean
Indicates whether or not to include defaultActions.
Property
initialDisplayMode: "feature" | "list"
Indicates whether to initially display a list of features, or the content for one feature.
Property
label: string
The widget's default label.
Property
A map is required when the input features have a popupTemplate that contains Arcade expressions in ExpressionInfo or ExpressionContent that may use the $map
profile variable to access data from layers within a map.
Property
position: "bottom-leading" | "bottom-left" | "bottom-right" | "bottom-trailing" | "manual" | "top-leading" | "top-left" | "top-right" | "top-trailing"
Property
promises: Array<Promise<any>>
An array of pending Promises that have not yet been fulfilled.
Property
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.
readonlyProperty
The selected feature accessed by the Features widget.
Property
selectedFeatureIndex: number
Index of the feature that is selected.
Property
showCollapseButton: boolean
Property
The spatial reference used for Arcade operations.
state: "disabled" | "ready"
The current state of the component.
Property
timeZone: string
Dates and times displayed in the widget will be displayed in this time zone.
No slots to display.
Events arcgisCloseEvent
arcgisClose: CustomEvent<void>
Emitted when the component's close button is clicked.
bubblesEvents triggered on this element will be propagated to their outermost elements.
composedThe event is composable and will propagate across the shadow DOM into the standard DOM.
cancelableThe event's default behavior can be canceled, allowing for custom behavior to be implemented instead.
arcgisPropertyChangeEvent
arcgisPropertyChange: CustomEvent<{ name: "state" | "selectedFeature" | "selectedFeatureIndex"; }>
Emitted when the value of a property is changed. Use this to listen to changes to properties.
bubblesEvents triggered on this element will be propagated to their outermost elements.
composedThe event is composable and will propagate across the shadow DOM into the standard DOM.
cancelableThe event's default behavior can be canceled, allowing for custom behavior to be implemented instead.
arcgisReadyEvent
arcgisReady: CustomEvent<void>
Emitted when the component associated with a map or scene view is is ready to be interacted with.
bubblesEvents triggered on this element will be propagated to their outermost elements.
composedThe event is composable and will propagate across the shadow DOM into the standard DOM.
cancelableThe event's default behavior can be canceled, allowing for custom behavior to be implemented instead.
arcgisTriggerActionEvent
arcgisTriggerAction: FeaturesTriggerActionEvent
Emitted when an action is triggered on the component.
bubblesEvents triggered on this element will be propagated to their outermost elements.
composedThe event is composable and will propagate across the shadow DOM into the standard DOM.
cancelableThe event's default behavior can be canceled, allowing for custom behavior to be implemented instead.
Methods Method Signatureclear
clear(): Promise<void>
close
close(): Promise<void>
componentOnReady
componentOnReady(): Promise<void>
destroy
destroy(): Promise<void>
fetchFeatures
fetchFeatures(screenPoint: __esri.FeaturesFetchFeaturesScreenPoint, options?: __esri.FetchFeaturesOptions): Promise<__esri.FetchPopupFeaturesResult>
next
next(): Promise<__esri.FeaturesViewModel>
open
open(options?: __esri.FeaturesOpenOptions): Promise<void>
previous
previous(): Promise<__esri.FeaturesViewModel>
triggerAction
triggerAction(actionIndex: number): Promise<void>
Method
clear(): Promise<void>
Method
close(): Promise<void>
Closes the component.
Method
componentOnReady(): Promise<void>
Create a promise that resolves once component is fully loaded.
ExampleUse dark colors for code blocks Copy
1
2
3
4
const arcgisFeatures = document.querySelector("arcgis-features");
document.body.append(arcgisFeatures);
await arcgisFeatures.componentOnReady();
console.log("arcgis-features is ready to go!");
Method
destroy(): Promise<void>
Permanently destroy the component.
Method
fetchFeatures(screenPoint: __esri.FeaturesFetchFeaturesScreenPoint, options?: __esri.FetchFeaturesOptions): Promise<__esri.FetchPopupFeaturesResult>
Use this method to return feature(s) at a given screen location. These features are fetched from all of the layer views. In order to use this, a layer must already have an associated PopupTemplate. This method allows a developer to control how the input location is handled.
Parameters Parameter Type Optional?screenPoint
FeaturesFetchFeaturesScreenPoint
options
FetchFeaturesOptions | undefined
Method
next(): Promise<__esri.FeaturesViewModel>
Method
open(options?: __esri.FeaturesOpenOptions): Promise<void>
Opens Features with content defined either explicitly or driven from the PopupTemplate of input features.
Parameters Parameter Type Optional?options
FeaturesOpenOptions | undefined
Method
previous(): Promise<__esri.FeaturesViewModel>
Method
triggerAction(actionIndex: number): Promise<void>
actionIndex
number
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4