Classes
Interfaces
Methods
(inner) createGazetteer(iShareUrl, options) → {Promise.<module:ol-ishare/ui/gazetteer~Gazetteer>}
Factory function to create a UI Gazetteer instance pre-configured with UI text loaded from iShare Language Editor
Parameters:
| Name | Type | Description |
|---|---|---|
iShareUrl |
String | Base URL for iShare Web app |
options |
module:ol-ishare/ui/gazetteer~GazetteerOptions | Gazetteer options |
Returns:
Promise which resolves to a UI Gazetteer instance
Type Definitions
GazetteerOptions
Properties:
| Name | Type | Description |
|---|---|---|
target |
String | DOM element that the control will be created within |
iShareUrl |
String | Base URL for iShare Web app. If
|
profile |
String | Name of profile that the search is
associated with. If |
sources |
Array.<module:ol-ishare/ui/gazetteer~GazetteerSource> | List of GazetteerSource instances that will be queried for
results. See |
placeholder |
String | Placeholder text displayed by the input |
noResults |
String | Message to display when no results are found |
queryTooShort |
String | Accessibility hint to indicate that
the query is too short. The string can contain an optional placeholder for
|
selectedOption |
String | Accessibility hint to indicate the
selected option. The string can contain optional placeholders for
|
resultsDescription |
String | Accessibility hint to indicate
which options are available and which is selected. The string can contain
optional placeholders for |
assistiveHint |
String | Accessibility hint to provide an initial instruction to the assistive tech user. |
Type:
GazetteerResult
Properties:
| Name | Type | Description |
|---|---|---|
id |
string | Unique ID of the result (UPRN, planning application reference etc.) |
coord |
Array.<number> | Coordinate of result e.g. |
bbox |
Array.<number> | Bounding box coordinates of the result e.g. |
srs |
string | Spatial reference system code of |
text |
string | Result text |
formatted |
string | Result text with matching part of text highlighted via html |