diff --git a/README.md b/README.md index 57f101aa1..73b174646 100644 --- a/README.md +++ b/README.md @@ -27,6 +27,7 @@ There are two ways to add Toolkit to your project: - [**OverviewMap**](https://esri.github.io/arcgis-toolkit-dotnet/overview-map.html): Displays an interactive inset map for a map or scene. - **PopupViewer**: Display details and media, edit attributes, geometry and related records, and manage the attachments of features and graphics (popups are defined in the popup property of features and graphics). - **ScaleLine**: Displays current scale reference. +- **[SearchView](https://esri.github.io/arcgis-toolkit-dotnet/search-view.html)**: Enables searching using one or more locators, with support for suggestions, automatic zooming, and custom search sources. - **SymbolDisplay**: Renders a symbol in a control. - **TimeSlider**: Allows interactively defining a temporal range (i.e. time extent) and animating time moving forward or backward. Can be used to manipulate the time extent in a MapView or SceneView. diff --git a/docs/controls.md b/docs/controls.md index 369dcca28..b0f8b4702 100644 --- a/docs/controls.md +++ b/docs/controls.md @@ -66,6 +66,11 @@ Displays current scale reference. ![ScaleLine](https://user-images.githubusercontent.com/1378165/73390077-3debb900-428a-11ea-8b2f-dfd4914a637e.png) +### SearchView + +Enables searching using one or more locators, with support for suggestions, automatic zooming, and custom search sources. + +![SearchView](https://user-images.githubusercontent.com/29742178/142301018-4bbeb0f2-3021-49a7-b5ec-f642c5700bd0.png) ### SymbolDisplay @@ -94,6 +99,7 @@ Allows interactively defining a temporal range (i.e. time extent) and animating |[OverviewMap](overview-map.md) | ✔ | ✔ | ❌ | ❌ | ✔ | |PopupViewer | ✔ | ✔ | ✔ | ✔ | ✔ | |ScaleLine | ✔ | ✔ | ✔ | ✔ | ✔ | +|[SearchView](search-view.md) | ✔ | ✔ | ❌ | ❌ | ✔ | |SignInForm | | Preview | | | | |SymbolDisplay | ✔ | ✔ | ✔ | ✔ | ✔ | |TableOfContents | N/A | Preview | N/A | N/A | N/A | diff --git a/docs/search-view.md b/docs/search-view.md new file mode 100644 index 000000000..c8ce91a18 --- /dev/null +++ b/docs/search-view.md @@ -0,0 +1,62 @@ +# Search View + +Search View enables searching using one or more locators, with support for suggestions, automatic zooming, and custom search sources. + +![image](https://user-images.githubusercontent.com/29742178/142301018-4bbeb0f2-3021-49a7-b5ec-f642c5700bd0.png) + +> **NOTE**: Search View uses metered ArcGIS services by default, so you will need to configure an API key. See [Security and authentication documentation](https://developers.arcgis.com/documentation/mapping-apis-and-services/security/#api-keys) for more information. + + +## Features + +- Updates search suggestions as you type +- Supports using the Esri world geocoder or any other ArcGIS locators +- Supports searching using custom search sources +- Supports searching multiple sources simultaneously +- Allows for customization of the display of search results +- Allows you to repeat a search within a defined area, and shows a button to enable that search when the view's viewpoint changes +- Separates the behavior (`SearchViewModel`) and the display (`SearchView`) to allow you to create a custom UI if needed + +## Customization + +The following properties enable customization of the view: + +- `EnableAutomaticConfiguration` - Controls whether view is automatically configured for the attached GeoView's map or scene. By default, this will set up a single World Geocoder search source. In future releases, this behavior may be extended to support other web map configuration options. +- `EnableRepeatSearchHereButton` - Controls whether a 'Repeat Search Here' button is shown when the user navigates the attached GeoView after a search is completed. +- `EnableResultListView` - Controls whether a result list is displayed. +- `EnableIndividualResultDisplay` - Controls whether the result list is shown when there is only one result. +- `MutlipleResultZoomBuffer` - Controls the buffer distance around collection results when a GeoView is attached and a search has multiple results. + +## Usage - WPF + +```xaml + + + + +``` + +## Usage - UWP + +```xaml + + + + +``` + +## Usage - Xamarin.Forms + +SearchView shows results in a list on top of underlying content, so it is best to position the view near the top of the page, on top of the MapView or SceneView. + +```xaml + + + + + + + + + +``` \ No newline at end of file diff --git a/src/Samples/Toolkit.SampleApp.UWP/Samples/SearchView/SearchViewCustomizationSample.xaml b/src/Samples/Toolkit.SampleApp.UWP/Samples/SearchView/SearchViewCustomizationSample.xaml new file mode 100644 index 000000000..e1661762b --- /dev/null +++ b/src/Samples/Toolkit.SampleApp.UWP/Samples/SearchView/SearchViewCustomizationSample.xaml @@ -0,0 +1,80 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +