@panoramax/web-viewer 3.2.3 → 4.0.0-develop-9f9cf858
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.gitlab-ci.yml +13 -6
- package/CHANGELOG.md +56 -1
- package/CODE_OF_CONDUCT.md +1 -1
- package/README.md +1 -1
- package/build/editor.html +10 -1
- package/build/index.css +12 -12
- package/build/index.css.map +1 -1
- package/build/index.html +1 -1
- package/build/index.js +2126 -14
- package/build/index.js.map +1 -1
- package/build/map.html +1 -1
- package/build/photo.html +1 -0
- package/build/static/media/atkinson-hyperlegible-next-latin-400-normal..woff +0 -0
- package/build/static/media/atkinson-hyperlegible-next-latin-400-normal..woff2 +0 -0
- package/build/static/media/atkinson-hyperlegible-next-latin-ext-400-normal..woff +0 -0
- package/build/static/media/atkinson-hyperlegible-next-latin-ext-400-normal..woff2 +0 -0
- package/build/viewer.html +12 -1
- package/build/widgets.html +1 -0
- package/config/jest/mocks.js +201 -0
- package/config/paths.js +2 -0
- package/config/webpack.config.js +52 -0
- package/docs/03_URL_settings.md +14 -16
- package/docs/05_Compatibility.md +59 -76
- package/docs/09_Develop.md +46 -11
- package/docs/90_Releases.md +2 -2
- package/docs/images/class_diagram.drawio +60 -45
- package/docs/images/class_diagram.jpg +0 -0
- package/docs/images/screenshot.jpg +0 -0
- package/docs/index.md +135 -0
- package/docs/reference/components/core/Basic.md +196 -0
- package/docs/reference/components/core/CoverageMap.md +210 -0
- package/docs/reference/components/core/Editor.md +224 -0
- package/docs/reference/components/core/PhotoViewer.md +307 -0
- package/docs/reference/components/core/Viewer.md +350 -0
- package/docs/reference/components/layout/BottomDrawer.md +35 -0
- package/docs/reference/components/layout/CorneredGrid.md +29 -0
- package/docs/reference/components/layout/Mini.md +45 -0
- package/docs/reference/components/layout/Tabs.md +45 -0
- package/docs/reference/components/menus/MapBackground.md +32 -0
- package/docs/reference/components/menus/MapFilters.md +15 -0
- package/docs/reference/components/menus/MapLayers.md +15 -0
- package/docs/reference/components/menus/MapLegend.md +15 -0
- package/docs/reference/components/menus/PictureLegend.md +16 -0
- package/docs/reference/components/menus/PictureMetadata.md +15 -0
- package/docs/reference/components/menus/PlayerOptions.md +15 -0
- package/docs/reference/components/menus/QualityScoreDoc.md +15 -0
- package/docs/reference/components/menus/ReportForm.md +15 -0
- package/docs/reference/components/menus/ShareMenu.md +15 -0
- package/docs/reference/components/ui/Button.md +40 -0
- package/docs/reference/components/ui/ButtonGroup.md +36 -0
- package/docs/reference/components/ui/CopyButton.md +38 -0
- package/docs/reference/components/ui/Grade.md +32 -0
- package/docs/reference/components/ui/LinkButton.md +45 -0
- package/docs/reference/components/ui/ListGroup.md +22 -0
- package/docs/reference/components/ui/Loader.md +56 -0
- package/docs/reference/components/ui/Map.md +239 -0
- package/docs/reference/components/ui/MapMore.md +256 -0
- package/docs/reference/components/ui/Photo.md +385 -0
- package/docs/reference/components/ui/Popup.md +56 -0
- package/docs/reference/components/ui/ProgressBar.md +32 -0
- package/docs/reference/components/ui/QualityScore.md +45 -0
- package/docs/reference/components/ui/SearchBar.md +63 -0
- package/docs/reference/components/ui/TogglableGroup.md +39 -0
- package/docs/reference/components/ui/widgets/GeoSearch.md +32 -0
- package/docs/reference/components/ui/widgets/Legend.md +49 -0
- package/docs/reference/components/ui/widgets/MapFiltersButton.md +33 -0
- package/docs/reference/components/ui/widgets/MapLayersButton.md +15 -0
- package/docs/reference/components/ui/widgets/OSMEditors.md +15 -0
- package/docs/reference/components/ui/widgets/PictureLegendActions.md +32 -0
- package/docs/reference/components/ui/widgets/Player.md +33 -0
- package/docs/reference/components/ui/widgets/Zoom.md +15 -0
- package/docs/reference/utils/API.md +334 -0
- package/docs/reference/utils/InitParameters.md +68 -0
- package/docs/reference/utils/URLHandler.md +107 -0
- package/docs/reference.md +79 -0
- package/docs/shortcuts.md +11 -0
- package/docs/tutorials/aerial_imagery.md +19 -0
- package/docs/tutorials/authentication.md +10 -0
- package/docs/tutorials/custom_widgets.md +59 -0
- package/docs/tutorials/map_style.md +39 -0
- package/docs/tutorials/migrate_v4.md +153 -0
- package/docs/tutorials/synced_coverage.md +43 -0
- package/mkdocs.yml +66 -5
- package/package.json +22 -17
- package/public/editor.html +21 -29
- package/public/index.html +17 -12
- package/public/map.html +19 -18
- package/public/photo.html +55 -0
- package/public/viewer.html +22 -26
- package/public/widgets.html +306 -0
- package/scripts/doc.js +79 -0
- package/src/components/core/Basic.css +48 -0
- package/src/components/core/Basic.js +349 -0
- package/src/components/core/CoverageMap.css +9 -0
- package/src/components/core/CoverageMap.js +139 -0
- package/src/components/core/Editor.css +23 -0
- package/src/components/core/Editor.js +390 -0
- package/src/components/core/PhotoViewer.css +48 -0
- package/src/components/core/PhotoViewer.js +499 -0
- package/src/components/core/Viewer.css +98 -0
- package/src/components/core/Viewer.js +564 -0
- package/src/components/core/index.js +12 -0
- package/src/components/index.js +13 -0
- package/src/components/layout/BottomDrawer.js +257 -0
- package/src/components/layout/CorneredGrid.js +112 -0
- package/src/components/layout/Mini.js +117 -0
- package/src/components/layout/Tabs.js +133 -0
- package/src/components/layout/index.js +9 -0
- package/src/components/menus/MapBackground.js +106 -0
- package/src/components/menus/MapFilters.js +400 -0
- package/src/components/menus/MapLayers.js +143 -0
- package/src/components/menus/MapLegend.js +34 -0
- package/src/components/menus/PictureLegend.js +257 -0
- package/src/components/menus/PictureMetadata.js +317 -0
- package/src/components/menus/PlayerOptions.js +95 -0
- package/src/components/menus/QualityScoreDoc.js +36 -0
- package/src/components/menus/ReportForm.js +133 -0
- package/src/components/menus/Share.js +100 -0
- package/src/components/menus/index.js +15 -0
- package/src/components/styles.js +383 -0
- package/src/components/ui/Button.js +77 -0
- package/src/components/ui/ButtonGroup.css +57 -0
- package/src/components/ui/ButtonGroup.js +68 -0
- package/src/components/ui/CopyButton.js +106 -0
- package/src/components/ui/Grade.js +54 -0
- package/src/components/ui/LinkButton.js +67 -0
- package/src/components/ui/ListGroup.js +66 -0
- package/src/components/ui/Loader.js +203 -0
- package/src/components/{Map.css → ui/Map.css} +5 -17
- package/src/components/{Map.js → ui/Map.js} +148 -156
- package/src/components/ui/MapMore.js +324 -0
- package/src/components/{Photo.css → ui/Photo.css} +6 -6
- package/src/components/{Photo.js → ui/Photo.js} +313 -101
- package/src/components/ui/Popup.js +145 -0
- package/src/components/ui/ProgressBar.js +104 -0
- package/src/components/ui/QualityScore.js +147 -0
- package/src/components/ui/SearchBar.js +367 -0
- package/src/components/ui/TogglableGroup.js +157 -0
- package/src/components/ui/index.js +22 -0
- package/src/components/ui/widgets/GeoSearch.css +21 -0
- package/src/components/ui/widgets/GeoSearch.js +139 -0
- package/src/components/ui/widgets/Legend.js +113 -0
- package/src/components/ui/widgets/MapFiltersButton.js +104 -0
- package/src/components/ui/widgets/MapLayersButton.js +79 -0
- package/src/components/ui/widgets/OSMEditors.js +155 -0
- package/src/components/ui/widgets/PictureLegendActions.js +117 -0
- package/src/components/ui/widgets/Player.css +7 -0
- package/src/components/ui/widgets/Player.js +151 -0
- package/src/components/ui/widgets/Zoom.js +82 -0
- package/src/components/ui/widgets/index.js +13 -0
- package/src/img/loader_base.jpg +0 -0
- package/src/img/panoramax.svg +13 -0
- package/src/img/switch_big.svg +20 -10
- package/src/index.js +7 -9
- package/src/translations/br.json +1 -0
- package/src/translations/da.json +38 -15
- package/src/translations/de.json +5 -3
- package/src/translations/en.json +35 -15
- package/src/translations/eo.json +38 -15
- package/src/translations/es.json +1 -1
- package/src/translations/fr.json +36 -16
- package/src/translations/hu.json +1 -1
- package/src/translations/it.json +39 -16
- package/src/translations/ja.json +182 -1
- package/src/translations/nl.json +106 -6
- package/src/translations/pl.json +1 -1
- package/src/translations/sv.json +182 -0
- package/src/translations/zh_Hant.json +35 -14
- package/src/utils/API.js +109 -49
- package/src/utils/InitParameters.js +388 -0
- package/src/utils/PhotoAdapter.js +1 -0
- package/src/utils/URLHandler.js +362 -0
- package/src/utils/geocoder.js +152 -0
- package/src/utils/{I18n.js → i18n.js} +7 -3
- package/src/utils/index.js +11 -0
- package/src/utils/{Map.js → map.js} +256 -77
- package/src/utils/picture.js +442 -0
- package/src/utils/utils.js +324 -0
- package/src/utils/widgets.js +55 -0
- package/tests/components/core/Basic.test.js +121 -0
- package/tests/components/core/BasicMock.js +25 -0
- package/tests/components/core/CoverageMap.test.js +20 -0
- package/tests/components/core/Editor.test.js +20 -0
- package/tests/components/core/PhotoViewer.test.js +57 -0
- package/tests/components/core/Viewer.test.js +84 -0
- package/tests/components/core/__snapshots__/PhotoViewer.test.js.snap +73 -0
- package/tests/components/core/__snapshots__/Viewer.test.js.snap +145 -0
- package/tests/components/ui/CopyButton.test.js +52 -0
- package/tests/components/ui/Loader.test.js +55 -0
- package/tests/components/{Map.test.js → ui/Map.test.js} +73 -61
- package/tests/components/{Photo.test.js → ui/Photo.test.js} +97 -63
- package/tests/components/ui/Popup.test.js +26 -0
- package/tests/components/ui/QualityScore.test.js +18 -0
- package/tests/components/ui/SearchBar.test.js +110 -0
- package/tests/components/ui/__snapshots__/CopyButton.test.js.snap +33 -0
- package/tests/components/ui/__snapshots__/Loader.test.js.snap +56 -0
- package/tests/components/{__snapshots__ → ui/__snapshots__}/Map.test.js.snap +11 -38
- package/tests/components/{__snapshots__ → ui/__snapshots__}/Photo.test.js.snap +70 -6
- package/tests/components/ui/__snapshots__/Popup.test.js.snap +29 -0
- package/tests/components/ui/__snapshots__/QualityScore.test.js.snap +11 -0
- package/tests/components/ui/__snapshots__/SearchBar.test.js.snap +65 -0
- package/tests/utils/API.test.js +83 -83
- package/tests/utils/InitParameters.test.js +499 -0
- package/tests/utils/URLHandler.test.js +401 -0
- package/tests/utils/__snapshots__/API.test.js.snap +10 -0
- package/tests/utils/__snapshots__/URLHandler.test.js.snap +21 -0
- package/tests/utils/__snapshots__/{Map.test.js.snap → geocoder.test.js.snap} +1 -1
- package/tests/utils/__snapshots__/map.test.js.snap +11 -0
- package/tests/utils/__snapshots__/picture.test.js.snap +327 -0
- package/tests/utils/__snapshots__/widgets.test.js.snap +19 -0
- package/tests/utils/geocoder.test.js +37 -0
- package/tests/utils/{I18n.test.js → i18n.test.js} +8 -8
- package/tests/utils/map.test.js +126 -0
- package/tests/utils/picture.test.js +745 -0
- package/tests/utils/utils.test.js +288 -0
- package/tests/utils/widgets.test.js +31 -0
- package/docs/01_Start.md +0 -149
- package/docs/02_Usage.md +0 -831
- package/docs/04_Advanced_examples.md +0 -216
- package/src/Editor.css +0 -37
- package/src/Editor.js +0 -361
- package/src/StandaloneMap.js +0 -114
- package/src/Viewer.css +0 -203
- package/src/Viewer.js +0 -1246
- package/src/components/CoreView.css +0 -70
- package/src/components/CoreView.js +0 -175
- package/src/components/Loader.css +0 -74
- package/src/components/Loader.js +0 -120
- package/src/img/loader_hd.jpg +0 -0
- package/src/utils/Exif.js +0 -193
- package/src/utils/Utils.js +0 -631
- package/src/utils/Widgets.js +0 -562
- package/src/viewer/URLHash.js +0 -469
- package/src/viewer/Widgets.css +0 -880
- package/src/viewer/Widgets.js +0 -1470
- package/tests/Editor.test.js +0 -126
- package/tests/StandaloneMap.test.js +0 -45
- package/tests/Viewer.test.js +0 -366
- package/tests/__snapshots__/Editor.test.js.snap +0 -298
- package/tests/__snapshots__/StandaloneMap.test.js.snap +0 -30
- package/tests/__snapshots__/Viewer.test.js.snap +0 -195
- package/tests/components/CoreView.test.js +0 -92
- package/tests/components/Loader.test.js +0 -38
- package/tests/components/__snapshots__/Loader.test.js.snap +0 -15
- package/tests/utils/Exif.test.js +0 -124
- package/tests/utils/Map.test.js +0 -113
- package/tests/utils/Utils.test.js +0 -300
- package/tests/utils/Widgets.test.js +0 -107
- package/tests/utils/__snapshots__/Exif.test.js.snap +0 -43
- package/tests/utils/__snapshots__/Utils.test.js.snap +0 -41
- package/tests/utils/__snapshots__/Widgets.test.js.snap +0 -44
- package/tests/viewer/URLHash.test.js +0 -559
- package/tests/viewer/Widgets.test.js +0 -127
- package/tests/viewer/__snapshots__/URLHash.test.js.snap +0 -108
- package/tests/viewer/__snapshots__/Widgets.test.js.snap +0 -403
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
<a name="Panoramax.utils.URLHandler"></a>
|
|
2
|
+
|
|
3
|
+
## Panoramax.utils.URLHandler
|
|
4
|
+
**Kind**: static class of <code>Panoramax.utils</code>
|
|
5
|
+
**Emits**: [<code>url-changed</code>](#Panoramax.utils.URLHandler+event_url-changed)
|
|
6
|
+
|
|
7
|
+
* [.URLHandler](#Panoramax.utils.URLHandler)
|
|
8
|
+
* [new URLHandler(parent)](#new_Panoramax.utils.URLHandler_new)
|
|
9
|
+
* [.listenToChanges()](#Panoramax.utils.URLHandler+listenToChanges)
|
|
10
|
+
* [.nextURLParams()](#Panoramax.utils.URLHandler+nextURLParams) ⇒ <code>object</code>
|
|
11
|
+
* [.nextURLString()](#Panoramax.utils.URLHandler+nextURLString) ⇒ <code>string</code>
|
|
12
|
+
* [.currentURLParams([readFromHash])](#Panoramax.utils.URLHandler+currentURLParams) ⇒ <code>object</code>
|
|
13
|
+
* [.currentMapString()](#Panoramax.utils.URLHandler+currentMapString) ⇒ <code>string</code>
|
|
14
|
+
* [.currentPSVString()](#Panoramax.utils.URLHandler+currentPSVString) ⇒ <code>string</code>
|
|
15
|
+
* [.nextShortLink()](#Panoramax.utils.URLHandler+nextShortLink) ⇒ <code>str</code>
|
|
16
|
+
* [.getUnmanagedParameters(prevUrl)](#Panoramax.utils.URLHandler+getUnmanagedParameters)
|
|
17
|
+
* ["url-changed"](#Panoramax.utils.URLHandler+event_url-changed)
|
|
18
|
+
|
|
19
|
+
<a name="new_Panoramax.utils.URLHandler_new"></a>
|
|
20
|
+
|
|
21
|
+
### new URLHandler(parent)
|
|
22
|
+
Updates the URL query part with various parent component information.
|
|
23
|
+
|
|
24
|
+
Note that you may call `listenToChanges()` for this class to be effective once parent is ready-enough.
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
| Param | Type | Description |
|
|
28
|
+
| --- | --- | --- |
|
|
29
|
+
| parent | [<code>Basic</code>](../components/core/Basic.md/#Panoramax.components.core.Basic) | The parent component |
|
|
30
|
+
|
|
31
|
+
<a name="Panoramax.utils.URLHandler+listenToChanges"></a>
|
|
32
|
+
|
|
33
|
+
### urlHandler.listenToChanges()
|
|
34
|
+
Start listening to URL & parent changes through events.
|
|
35
|
+
This leads to parent & URL updates.
|
|
36
|
+
|
|
37
|
+
**Kind**: instance method of [<code>URLHandler</code>](#Panoramax.utils.URLHandler)
|
|
38
|
+
<a name="Panoramax.utils.URLHandler+nextURLParams"></a>
|
|
39
|
+
|
|
40
|
+
### urlHandler.nextURLParams() ⇒ <code>object</code>
|
|
41
|
+
Compute next values to insert in URL
|
|
42
|
+
|
|
43
|
+
**Kind**: instance method of [<code>URLHandler</code>](#Panoramax.utils.URLHandler)
|
|
44
|
+
**Returns**: <code>object</code> - Query parameters
|
|
45
|
+
<a name="Panoramax.utils.URLHandler+nextURLString"></a>
|
|
46
|
+
|
|
47
|
+
### urlHandler.nextURLString() ⇒ <code>string</code>
|
|
48
|
+
Compute next URL query string (based on `nextURLParams()`)
|
|
49
|
+
|
|
50
|
+
**Kind**: instance method of [<code>URLHandler</code>](#Panoramax.utils.URLHandler)
|
|
51
|
+
**Returns**: <code>string</code> - The query string
|
|
52
|
+
<a name="Panoramax.utils.URLHandler+currentURLParams"></a>
|
|
53
|
+
|
|
54
|
+
### urlHandler.currentURLParams([readFromHash]) ⇒ <code>object</code>
|
|
55
|
+
Transforms current URL query string into key->value object
|
|
56
|
+
|
|
57
|
+
**Kind**: instance method of [<code>URLHandler</code>](#Panoramax.utils.URLHandler)
|
|
58
|
+
**Returns**: <code>object</code> - Key-value read from current URL query
|
|
59
|
+
|
|
60
|
+
| Param | Type | Default | Description |
|
|
61
|
+
| --- | --- | --- | --- |
|
|
62
|
+
| [readFromHash] | <code>boolean</code> | <code>false</code> | Switch to reading from hash URL part (for retro-compatibility) |
|
|
63
|
+
|
|
64
|
+
<a name="Panoramax.utils.URLHandler+currentMapString"></a>
|
|
65
|
+
|
|
66
|
+
### urlHandler.currentMapString() ⇒ <code>string</code>
|
|
67
|
+
Get string representation of map position
|
|
68
|
+
|
|
69
|
+
**Kind**: instance method of [<code>URLHandler</code>](#Panoramax.utils.URLHandler)
|
|
70
|
+
**Returns**: <code>string</code> - zoom/lat/lon or zoom/lat/lon/bearing/pitch
|
|
71
|
+
<a name="Panoramax.utils.URLHandler+currentPSVString"></a>
|
|
72
|
+
|
|
73
|
+
### urlHandler.currentPSVString() ⇒ <code>string</code>
|
|
74
|
+
Get PSV view position as string
|
|
75
|
+
|
|
76
|
+
**Kind**: instance method of [<code>URLHandler</code>](#Panoramax.utils.URLHandler)
|
|
77
|
+
**Returns**: <code>string</code> - x/y/z
|
|
78
|
+
<a name="Panoramax.utils.URLHandler+nextShortLink"></a>
|
|
79
|
+
|
|
80
|
+
### urlHandler.nextShortLink() ⇒ <code>str</code>
|
|
81
|
+
Get short link URL (query replaced by Base64)
|
|
82
|
+
|
|
83
|
+
**Kind**: instance method of [<code>URLHandler</code>](#Panoramax.utils.URLHandler)
|
|
84
|
+
**Returns**: <code>str</code> - The short link URL
|
|
85
|
+
<a name="Panoramax.utils.URLHandler+getUnmanagedParameters"></a>
|
|
86
|
+
|
|
87
|
+
### urlHandler.getUnmanagedParameters(prevUrl)
|
|
88
|
+
Returns a string containing only parameters out of URLHandler scope
|
|
89
|
+
|
|
90
|
+
**Kind**: instance method of [<code>URLHandler</code>](#Panoramax.utils.URLHandler)
|
|
91
|
+
|
|
92
|
+
| Param | Type | Description |
|
|
93
|
+
| --- | --- | --- |
|
|
94
|
+
| prevUrl | <code>URL</code> | The previously set URL |
|
|
95
|
+
|
|
96
|
+
<a name="Panoramax.utils.URLHandler+event_url-changed"></a>
|
|
97
|
+
|
|
98
|
+
### "url-changed"
|
|
99
|
+
URL changed event
|
|
100
|
+
|
|
101
|
+
**Kind**: event emitted by [<code>URLHandler</code>](#Panoramax.utils.URLHandler)
|
|
102
|
+
**Properties**
|
|
103
|
+
|
|
104
|
+
| Name | Type | Description |
|
|
105
|
+
| --- | --- | --- |
|
|
106
|
+
| detail.url | <code>string</code> | The new used URL |
|
|
107
|
+
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
# API reference overview
|
|
2
|
+
|
|
3
|
+
All of components and classes are grouped in the imported library named `Panoramax`.
|
|
4
|
+
|
|
5
|
+
## `components.core`
|
|
6
|
+
|
|
7
|
+
Main web components:
|
|
8
|
+
|
|
9
|
+
- [Basic](./reference/components/core/Basic.md) : base class for other components, embedding shared logic.
|
|
10
|
+
- [CoverageMap](./reference/components/core/CoverageMap.md) : map showing Panoramax data availability.
|
|
11
|
+
- [Editor](./reference/components/core/Editor.md) : photo and map display for editing purposes.7
|
|
12
|
+
- [PhotoViewer](./reference/components/core/PhotoViewer.md) : the classic photo-only viewer.
|
|
13
|
+
- [Viewer](./reference/components/core/Viewer.md) : the photo and map viewer.
|
|
14
|
+
|
|
15
|
+
## `components.layout`
|
|
16
|
+
|
|
17
|
+
Layout helpers:
|
|
18
|
+
|
|
19
|
+
- [BottomDrawer](./reference/components/layout/BottomDrawer.md) : a mobile-like drawer from screen bottom.
|
|
20
|
+
- [CorneredGrid](./reference/components/layout/CorneredGrid.md) : corner-oriented layout over a background component.
|
|
21
|
+
- [Mini](./reference/components/layout/Mini.md) : reduced and collapsable mini component.
|
|
22
|
+
- [Tabs](./reference/components/layout/Tabs.md) : tabbed content manager.
|
|
23
|
+
|
|
24
|
+
## `components.menus`
|
|
25
|
+
|
|
26
|
+
All-in-one, ready-to-use menus for complex operations. Note that they don't embed a container (like popup or panel) to be reusable in any situation.
|
|
27
|
+
|
|
28
|
+
- [MapBackground](./reference/components/menus/MapBackground.md) : change map background.
|
|
29
|
+
- [MapFilters](./reference/components/menus/MapFilters.md) : set map filters.
|
|
30
|
+
- [MapLayers](./reference/components/menus/MapLayers.md) : change map theme and background.
|
|
31
|
+
- [MapLegend](./reference/components/menus/MapLegend.md) : display map sources and Panoramax info.
|
|
32
|
+
- [PictureLegend](./reference/components/menus/PictureLegend.md) : display date, author and info for a picture.
|
|
33
|
+
- [PictureMetadata](./reference/components/menus/PictureMetadata.md) : display full details about a picture.
|
|
34
|
+
- [PlayerOptions](./reference/components/menus/PlayerOptions.md) : speed and constrast settings for play sequence feature.
|
|
35
|
+
- [QualityScoreDoc](./reference/components/menus/QualityScoreDoc.md) : details about quality score computation.
|
|
36
|
+
- [ReportForm](./reference/components/menus/ReportForm.md) : picture issue reporting form.
|
|
37
|
+
- [ShareMenu](./reference/components/menus/ShareMenu.md) : links and iframe sharing.
|
|
38
|
+
|
|
39
|
+
## `components.ui`
|
|
40
|
+
|
|
41
|
+
Basic UI components:
|
|
42
|
+
|
|
43
|
+
- [Button](./reference/components/ui/Button.md) : a simple button.
|
|
44
|
+
- [ButtonGroup](./reference/components/ui/ButtonGroup.md) : button bar.
|
|
45
|
+
- [CopyButton](./reference/components/ui/CopyButton.md) : a copy-to-clipboard button.
|
|
46
|
+
- [Grade](./reference/components/ui/Grade.md) : a 5-star rating display.
|
|
47
|
+
- [LinkButton](./reference/components/ui/LinkButton.md) : a link button.
|
|
48
|
+
- [ListGroup](./reference/components/ui/ListGroup.md) : a menu-like list of buttons and links.
|
|
49
|
+
- [Loader](./reference/components/ui/Loader.md) : the fullscreen initial loader.
|
|
50
|
+
- [Map](./reference/components/ui/Map.md) : the browseable map (MapLibre GL).
|
|
51
|
+
- [MapMore](./reference/components/ui/MapMore.md) : advanced version of the browseable map.
|
|
52
|
+
- [Photo](./reference/components/ui/Photo.md) : the picture display (Photo Sphere Viewer).
|
|
53
|
+
- [Popup](./reference/components/ui/Popup.md) : an overlaying popup/modal.
|
|
54
|
+
- [ProgressBar](./reference/components/ui/ProgressBar.md) : a progress bar.
|
|
55
|
+
- [QualityScore](./reference/components/ui/QualityScore.md) : a A/B/C/D/E grade display and input.
|
|
56
|
+
- [SearchBar](./reference/components/ui/SearchBar.md) : a search bar.
|
|
57
|
+
- [TogglableGroup](./reference/components/ui/TogglableGroup.md) : an helper for showing a menu on button click.
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
## `components.ui.widgets`
|
|
61
|
+
|
|
62
|
+
More complex UI components (but not menus):
|
|
63
|
+
|
|
64
|
+
- [GeoSearch](./reference/components/ui/widgets/GeoSearch.md) : a geocoder search bar with GPS location tool.
|
|
65
|
+
- [Legend](./reference/components/ui/widgets/Legend.md) : a togglable map/picture legend.
|
|
66
|
+
- [MapFiltersButton](./reference/components/ui/widgets/MapFiltersButton.md) : a togglable map filters button & menu.
|
|
67
|
+
- [MapLayersButton](./reference/components/ui/widgets/MapLayersButton.md) : a togglable map layers button & menu.
|
|
68
|
+
- [OSMEditors](./reference/components/ui/widgets/OSMEditors.md) : shortcuts for OpenStreetMap editing tools.
|
|
69
|
+
- [PictureLegendActions](./reference/components/ui/widgets/PictureLegendActions.md) : various actions from picture legend.
|
|
70
|
+
- [Player](./reference/components/ui/widgets/Player.md) : the previous/next/play/pause toolbar.
|
|
71
|
+
- [Zoom](./reference/components/ui/widgets/Zoom.md) : the +/- zoom toolbar.
|
|
72
|
+
|
|
73
|
+
## `utils`
|
|
74
|
+
|
|
75
|
+
General helpers outside of single component scope:
|
|
76
|
+
|
|
77
|
+
- [API](./reference/utils/API.md) : the Panoramax API helper (many get & post HTTP helpers).
|
|
78
|
+
- [InitParameters](./reference/utils/InitParameters.md) : helper for merging URL and component parameters.
|
|
79
|
+
- [URLHandler](./reference/utils/URLHandler.md) : the window URL manager (changes query part).
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
# Keyboard shortcuts
|
|
2
|
+
|
|
3
|
+
All interactions with the viewer can be done using the mouse, and some can be also done using keyboard.
|
|
4
|
+
|
|
5
|
+
* __Arrows__ (or 2/4/8/6 on keypad): move inside the picture, or move the map
|
|
6
|
+
* __Page up/down__ (or 3/9 on keypad) : go to next or previous picture in sequence
|
|
7
|
+
* __+ / -__ : zoom picture or map in or out
|
|
8
|
+
* __*__ (or 5 on keypad) : move picture or map to its center
|
|
9
|
+
* __Home / ↖️__ (or 7 on keypad) : switch map and picture as main shown component
|
|
10
|
+
* __End__ (or 1 on keypad) : hide minimized map or picture
|
|
11
|
+
* __Space__ : play or pause current sequence
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Adding aerial imagery
|
|
2
|
+
|
|
3
|
+
In complement of classic _streets_ rendering, you can add an aerial imagery as map background. This is possible using a WMS or WMTS service, and setting configuration as following (this example uses the French IGN aerial imagery):
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<pnx-viewer
|
|
7
|
+
endpoint="https://panoramax.ign.fr/api"
|
|
8
|
+
map='{"raster": {
|
|
9
|
+
"type": "raster",
|
|
10
|
+
"tiles": [
|
|
11
|
+
"https://data.geopf.fr/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=ORTHOIMAGERY.ORTHOPHOTOS&STYLE=normal&FORMAT=image/jpeg&TILEMATRIXSET=PM_0_21&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}"
|
|
12
|
+
],
|
|
13
|
+
"minzoom": 0,
|
|
14
|
+
"maxzoom": 21,
|
|
15
|
+
"attribution": "© IGN",
|
|
16
|
+
"tileSize": 256
|
|
17
|
+
}}'
|
|
18
|
+
/>
|
|
19
|
+
```
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# Authentication against API
|
|
2
|
+
|
|
3
|
+
If the STAC API you're using needs some kind of authentication, you can pass it through any core component options. Parameter `fetchOptions` allows you to set custom parameters for the [JS fetch function](https://developer.mozilla.org/en-US/docs/Web/API/fetch#parameters), like the `credentials` setting. For example:
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<pnx-viewer
|
|
7
|
+
endpoint="https://your-secured-stac.fr/api"
|
|
8
|
+
fetchOptions='{ "credentials": "include" }'
|
|
9
|
+
/>
|
|
10
|
+
```
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
# Manage custom widgets
|
|
2
|
+
|
|
3
|
+
The viewer allows you to manage finely its widgets, you can either add or replace all widgets offered by the viewer.
|
|
4
|
+
|
|
5
|
+
We use internally [slots](https://developer.mozilla.org/docs/Web/HTML/Element/slot) to make this possible. Each corner of the viewer is identified uniquely, so you can add in the exact place you'd like. This is in a similar fashion to MapLibre GL or Leaflet widgets management.
|
|
6
|
+
|
|
7
|
+
!!! note
|
|
8
|
+
|
|
9
|
+
This is only available for __Viewer__ & __Photo Viewer__ components, not for _Coverage Map_ or _Editor_.
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
## Add a new widget
|
|
13
|
+
|
|
14
|
+
Let's say you want to add a custom widget without removing existing viewer ones. You can insert your element inside of the viewer markup:
|
|
15
|
+
|
|
16
|
+
```html
|
|
17
|
+
<pnx-viewer
|
|
18
|
+
endpoint="https://panoramax.openstreetmap.fr/"
|
|
19
|
+
>
|
|
20
|
+
<p slot="top-right">My custom text</p>
|
|
21
|
+
</pnx-viewer>
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
The magic happens here thanks to the `slop="top-right"` attribute on your element. You can use any corner you like (`top-left`, `top`, `top-right`, `bottom-left`, `bottom`, `bottom-right`), and add several elements on a same corner (they will stack depending of existing CSS styles).
|
|
25
|
+
|
|
26
|
+
## Replace all widgets
|
|
27
|
+
|
|
28
|
+
For finer control, you may want to get rid of all existing widgets before adding your own ones. This is also possible by setting `widgets="false"` attribute on the viewer:
|
|
29
|
+
|
|
30
|
+
```html
|
|
31
|
+
<pnx-viewer
|
|
32
|
+
endpoint="https://panoramax.openstreetmap.fr/"
|
|
33
|
+
widgets="false"
|
|
34
|
+
>
|
|
35
|
+
<p slot="top-right">My custom text</p>
|
|
36
|
+
</pnx-viewer>
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
Note that this keeps only the _Mini_ map/picture display (in bottom-left corner).
|
|
40
|
+
|
|
41
|
+
!!! note
|
|
42
|
+
|
|
43
|
+
If you don't need map at all, you can also use the [Photo Viewer](../reference/components/core/PhotoViewer.md) component, which is a picture display without any map.
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
## Reuse default widgets
|
|
47
|
+
|
|
48
|
+
You may also want to reuse differently existing widgets. Note that all of them are listed in the [API reference](../reference.md). Just insert them as slotted components inside the viewer:
|
|
49
|
+
|
|
50
|
+
```html
|
|
51
|
+
<pnx-viewer
|
|
52
|
+
endpoint="https://panoramax.openstreetmap.fr/"
|
|
53
|
+
widgets="false"
|
|
54
|
+
>
|
|
55
|
+
<pnx-widget-zoom slot="top-right" />
|
|
56
|
+
</pnx-viewer>
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
Note that parent variables (`_parent` and `_t`) are automatically passed through by the viewer, no need to add it manually.
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# Change map background style
|
|
2
|
+
|
|
3
|
+
All components can be configured to use a different map background than the default one. By default, an OpenStreetMap France classic style if offered. Changing the style is done by passing a `mapstyle` parameter on viewer setup. It should follow the [MapLibre Style specification](https://maplibre.org/maplibre-style-spec/) and be passed as an object, or an URL to such style:
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<pnx-viewer
|
|
7
|
+
endpoint="https://api.panoramax.xyz/api"
|
|
8
|
+
mapstyle="https://my.tiles.provider/basic.json"
|
|
9
|
+
/>
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Note that we also support PMTiles (for a simpler tile hosting), so your style file can contain vector source defined like this:
|
|
13
|
+
|
|
14
|
+
```html
|
|
15
|
+
<pnx-viewer
|
|
16
|
+
endpoint="https://api.panoramax.xyz/api"
|
|
17
|
+
mapstyle='{
|
|
18
|
+
"sources": {
|
|
19
|
+
"protomaps": {
|
|
20
|
+
"type": "vector",
|
|
21
|
+
"url": "pmtiles://https://example.com/example.pmtiles",
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
...
|
|
25
|
+
}'
|
|
26
|
+
/>
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
And you can also customize the map attribution, especially if your style JSON doesn't contain any by default, for example:
|
|
30
|
+
|
|
31
|
+
```html
|
|
32
|
+
<pnx-viewer
|
|
33
|
+
endpoint="https://api.panoramax.xyz/api"
|
|
34
|
+
mapstyle="https://my.tiles.provider/basic.json"
|
|
35
|
+
map='{
|
|
36
|
+
"attributionControl": { "customAttribution": "© IGN" }
|
|
37
|
+
}'
|
|
38
|
+
/>
|
|
39
|
+
```
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
# Migration from v3 to v4
|
|
2
|
+
|
|
3
|
+
The version 4 of _Panoramax Web Viewer_ has seen major changes, migrating from custom code to Web Components. This requires you to change a few things compared to version 3.
|
|
4
|
+
|
|
5
|
+
!!! note
|
|
6
|
+
|
|
7
|
+
If at some point you're lost or need help, you can contact us through [issues](https://gitlab.com/panoramax/clients/web-viewer/-/issues) or by [email](mailto:panoramax@panoramax.fr).
|
|
8
|
+
|
|
9
|
+
## 🪄 Initializing components
|
|
10
|
+
|
|
11
|
+
The way you create a component (viewer, editor, coverage map) is different :
|
|
12
|
+
|
|
13
|
+
=== "v4"
|
|
14
|
+
|
|
15
|
+
Now, you have to create a HTML-like component and pass attributes.
|
|
16
|
+
|
|
17
|
+
```html
|
|
18
|
+
<pnx-viewer id="myviewer" endpoint="https://api.panoramax.xyz/api" />
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
You can then access it in JS to manage it.
|
|
22
|
+
|
|
23
|
+
```js
|
|
24
|
+
let myviewer = document.getElementById("myviewer");
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
Also note that custom MapLibre style must be passed as `mapstyle` attribute.
|
|
28
|
+
|
|
29
|
+
=== "v3"
|
|
30
|
+
|
|
31
|
+
Before, you created a `div` with ID, then passed it to JS class.
|
|
32
|
+
|
|
33
|
+
```js
|
|
34
|
+
let myViewer = new Panoramax.Viewer("viewer", "https://api.panoramax.xyz/api");
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
And MapLibre style was passed as a `style` property in option object.
|
|
38
|
+
|
|
39
|
+
## ⏯️ Widgets options
|
|
40
|
+
|
|
41
|
+
Viewer widgets options are managed quite differently in version 4:
|
|
42
|
+
|
|
43
|
+
- You can disable all widgets with `widgets="false" map="false"` options
|
|
44
|
+
- You can add or replace widgets using web component slots (insert your own widgets as child of viewer)
|
|
45
|
+
|
|
46
|
+
This allows to do things like:
|
|
47
|
+
|
|
48
|
+
```html
|
|
49
|
+
<pnx-viewer
|
|
50
|
+
endpoint="https://panoramax.openstreetmap.fr/"
|
|
51
|
+
widgets="false"
|
|
52
|
+
>
|
|
53
|
+
<p slot="top-right">My custom text</p>
|
|
54
|
+
</pnx-viewer>
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
This offers more flexibility, check out [how to manage custom widgets in dedicated documentation](./custom_widgets.md).
|
|
58
|
+
|
|
59
|
+
## 🏷️ Class & packages names
|
|
60
|
+
|
|
61
|
+
Many stuff was moved around, and have a bit different naming. Main classes should be called directly by their web component name:
|
|
62
|
+
|
|
63
|
+
| v3 class | v4 web component |
|
|
64
|
+
|----------|------------------|
|
|
65
|
+
| `Panoramax.Viewer` | `<pnx-viewer>` |
|
|
66
|
+
| `Panoramax.Editor` | `<pnx-editor>` |
|
|
67
|
+
| `Panoramax.StandaloneMap` | `<pnx-coverage-map>` |
|
|
68
|
+
|
|
69
|
+
A new main component is available, named __Photo Viewer__ (`<pnx-photo-viewer>`) for showing up only picture (without map).
|
|
70
|
+
|
|
71
|
+
And source code is splitted in more packages:
|
|
72
|
+
|
|
73
|
+
* `Panoramax.components` : everything you can see graphically
|
|
74
|
+
* `.core` : Viewer, Editor, Coverage Map and Basic (common code)
|
|
75
|
+
* `.layout` : helper classes for layout
|
|
76
|
+
* `.menus` : complex menus (map filters, picture metadata...)
|
|
77
|
+
* `.ui` : re-usable small graphical components
|
|
78
|
+
* `.ui.widgets` : specialized small graphical components (button + menu, extended search bar...)
|
|
79
|
+
* `Panoramax.utils` : helper classes and functions
|
|
80
|
+
|
|
81
|
+
## 👂 Events
|
|
82
|
+
|
|
83
|
+
Many events names were changed, and some of them moved to sub-components.
|
|
84
|
+
|
|
85
|
+
| v3 class | v3 event name | v4 class | v4 event name |
|
|
86
|
+
|----------|-----------------------------------|------------------------|---------------|
|
|
87
|
+
| CoreView | `map:background-changed` | components.ui.Map | `background-changed` |
|
|
88
|
+
| CoreView | `map:picture-click` | components.ui.Map | `picture-click` |
|
|
89
|
+
| CoreView | `map:sequence-hover` | components.ui.Map | `sequence-hover` |
|
|
90
|
+
| CoreView | `map:sequence-click` | components.ui.Map | `sequence-click` |
|
|
91
|
+
| CoreView | `map:users-changed` | components.ui.Map | `users-changed` |
|
|
92
|
+
| CoreView | `psv:picture-loaded` | components.ui.Photo | `picture-loaded` |
|
|
93
|
+
| CoreView | `psv:picture-loading` | components.ui.Photo | `picture-loading` |
|
|
94
|
+
| CoreView | `psv:picture-preview-started` | components.ui.Photo | `picture-preview-started` |
|
|
95
|
+
| CoreView | `psv:picture-preview-stopped` | components.ui.Photo | `picture-preview-stopped` |
|
|
96
|
+
| CoreView | `psv:picture-tiles-loaded` | components.ui.Photo | `picture-tiles-loaded` |
|
|
97
|
+
| CoreView | `psv:view-rotated` | components.ui.Photo | `view-rotated` |
|
|
98
|
+
| CoreView | `psv:transition-duration-changed` | components.ui.Photo | `transition-duration-changed` |
|
|
99
|
+
| Viewer | `filters-changed` | components.ui.MapMore | `filters-changed` |
|
|
100
|
+
| Viewer | `focus-changed` | components.core.Viewer | `focus-changed` |
|
|
101
|
+
| Viewer | `josm-live-enabled` | ❌ Removed | |
|
|
102
|
+
| Viewer | `josm-live-disabled` | ❌ Removed | |
|
|
103
|
+
| Viewer | `pictures-navigation-changed` | components.ui.Photo | `pictures-navigation-changed` |
|
|
104
|
+
| Viewer | `sequence-playing` | components.ui.Photo | `sequence-playing` |
|
|
105
|
+
| Viewer | `sequence-stopped` | components.ui.Photo | `sequence-stopped` |
|
|
106
|
+
|
|
107
|
+
To listen to these events, you can use `map` and `psv` properties of your component.
|
|
108
|
+
|
|
109
|
+
```js
|
|
110
|
+
myviewer.addEventListener("focus-changed", e => console.log(e));
|
|
111
|
+
myviewer.psv.addEventListener("sequence-playing", e => console.log(e));
|
|
112
|
+
|
|
113
|
+
// Note that MapLibre uses on/once functions for events
|
|
114
|
+
myviewer.map.on("picture-click", e => console.log(e));
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
To make use of these sub-components events easier, note that you can also call them from parent component using the property name as a prefix. For example:
|
|
118
|
+
|
|
119
|
+
```js
|
|
120
|
+
// Transfers listener to map sub-component
|
|
121
|
+
myviewer.addEventListener("map:moveend", e => console.log(e));
|
|
122
|
+
|
|
123
|
+
// Works for any sub-component, like URL Handler or PSV
|
|
124
|
+
myviewer.addEventListener("urlHandler:url-changed", e => console.log(e));
|
|
125
|
+
myviewer.addEventListener("psv:picture-loaded", e => console.log(e));
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
To know more about available events per component, please refer [to their individual API page](../reference.md).
|
|
129
|
+
|
|
130
|
+
## ⚙️ Functions
|
|
131
|
+
|
|
132
|
+
Many functions were changed as well, in order to reduce source files size and make things more logical. You can find [all API reference in this doc](../reference.md), here's a summary:
|
|
133
|
+
|
|
134
|
+
| v3 | v4 |
|
|
135
|
+
|---------------------|---------------------|
|
|
136
|
+
| `Viewer.refreshPSV` | `(components.ui).Photo.forceRefresh` |
|
|
137
|
+
| `Viewer`'s play/stop/toggle sequence | Gone to `(components.ui).Photo` |
|
|
138
|
+
| `Viewer`'s get/set pictures navigation | Gone to `(components.ui).Photo` |
|
|
139
|
+
| `Viewer.toggleJOSMLive` | Made private in `(components.ui.widgets).Share` |
|
|
140
|
+
| `Viewer`'s set/toggle focus/unfocused | Managed through `(components.core).Viewer` `focus` attribute and `mini` property |
|
|
141
|
+
| `Viewer.setFilters` | `(components.ui).MapMore` |
|
|
142
|
+
|
|
143
|
+
## 🌍 URL parameters
|
|
144
|
+
|
|
145
|
+
URL parameters are now managed in the URL _search_ part (everything after the `?`), whereas in version 3 it was managed through _hash_ part (everything after the `#`). To ensure long-term compatibility, you may just replace the `#` in your URL by `?`. Here's an example of these new URL:
|
|
146
|
+
|
|
147
|
+
```urlencoded
|
|
148
|
+
https://panoramax.ign.fr/?background=streets&focus=map&map=9/48.6659/2.3237&speed=250
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
## 🪛 Initialization parameters
|
|
152
|
+
|
|
153
|
+
Parameters passed to __Viewer__ are more finely read, they can come from Web Component itself (attributes), browser local storage or URL search parameters. URL ones are read first, then local storage, and finally component attributes. This can be misleading while you develop, [read more about this on Develop documentation](../09_Develop.md#parameters-handling).
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# Coverage map synced with external component
|
|
2
|
+
|
|
3
|
+
Let's say you want to list all sequences of an user. You can display a standalone map which can be synced with your custom list. Create your _Coverage Map_ web component:
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<pnx-coverage-map
|
|
7
|
+
id="coverage"
|
|
8
|
+
class="fullpage"
|
|
9
|
+
endpoint="https://api.panoramax.xyz/api"
|
|
10
|
+
/>
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
Then, access it through JavaScript for further interaction:
|
|
14
|
+
|
|
15
|
+
```js
|
|
16
|
+
// Retrieve component from DOM
|
|
17
|
+
var coverage = document.getElementById("coverage");
|
|
18
|
+
|
|
19
|
+
// Wait for map initial load
|
|
20
|
+
coverage.addEventListener("ready", () => {
|
|
21
|
+
// Change visible map area
|
|
22
|
+
coverage.map.fitBounds([0, 0, 180, 90]);
|
|
23
|
+
|
|
24
|
+
// Listen to sequence hovered on map
|
|
25
|
+
// You can alternatively use: coverage.addEventListener("map:sequence-hover", ...)
|
|
26
|
+
coverage.map.on("sequence-hover", e => {
|
|
27
|
+
console.log("Hovered sequence", e.seqId);
|
|
28
|
+
});
|
|
29
|
+
|
|
30
|
+
// Listen to user clicks on map
|
|
31
|
+
coverage.addEventListener("select", e => {
|
|
32
|
+
console.log("Selected sequence", e.detail.seqId, "picture", e.detail.picId);
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
// You can also programatically change selection on map
|
|
36
|
+
coverage.select(
|
|
37
|
+
"c463d190-06b0-47fb-98a8-b4a775a39ad6", // A sequence ID
|
|
38
|
+
"bdea1eb4-4496-46da-a4d5-b22b16e75fa8" // A picture ID (can be null if unknown)
|
|
39
|
+
);
|
|
40
|
+
}, {once: true});
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
All available interaction are listed in [Coverage Map reference](../reference/components/core/CoverageMap.md).
|
package/mkdocs.yml
CHANGED
|
@@ -20,6 +20,7 @@ plugins:
|
|
|
20
20
|
markdown_extensions:
|
|
21
21
|
- admonition
|
|
22
22
|
- pymdownx.superfences
|
|
23
|
+
- pymdownx.details
|
|
23
24
|
- pymdownx.tabbed:
|
|
24
25
|
alternate_style: true
|
|
25
26
|
- pymdownx.highlight:
|
|
@@ -34,12 +35,72 @@ markdown_extensions:
|
|
|
34
35
|
emoji_generator: !!python/name:material.extensions.emoji.to_svg
|
|
35
36
|
|
|
36
37
|
nav:
|
|
37
|
-
- 'Quick start': '
|
|
38
|
-
-
|
|
38
|
+
- 'Quick start': 'index.md'
|
|
39
|
+
- 'Migrating to v4': 'tutorials/migrate_v4.md'
|
|
40
|
+
- Tips:
|
|
39
41
|
- 'URL settings': '03_URL_settings.md'
|
|
40
|
-
-
|
|
41
|
-
-
|
|
42
|
+
- Shortcuts: 'shortcuts.md'
|
|
43
|
+
- Tutorials:
|
|
44
|
+
- 'Change map style': 'tutorials/map_style.md'
|
|
45
|
+
- 'Add aerial imagery': 'tutorials/aerial_imagery.md'
|
|
46
|
+
- 'Server authentication': 'tutorials/authentication.md'
|
|
47
|
+
- 'Custom widgets': 'tutorials/custom_widgets.md'
|
|
48
|
+
- 'Synced coverage map': 'tutorials/synced_coverage.md'
|
|
49
|
+
- Develop:
|
|
42
50
|
- 'Where to start': '09_Develop.md'
|
|
43
|
-
- 'Viewer''s API reference': '02_Usage.md'
|
|
44
51
|
- 'STAC API compatibility': '05_Compatibility.md'
|
|
45
52
|
- 'Make a release': '90_Releases.md'
|
|
53
|
+
- 'API reference':
|
|
54
|
+
- Overview: 'reference.md'
|
|
55
|
+
- components:
|
|
56
|
+
- core:
|
|
57
|
+
- Basic: 'reference/components/core/Basic.md'
|
|
58
|
+
- CoverageMap: 'reference/components/core/CoverageMap.md'
|
|
59
|
+
- Editor: 'reference/components/core/Editor.md'
|
|
60
|
+
- PhotoViewer: 'reference/components/core/PhotoViewer.md'
|
|
61
|
+
- Viewer: 'reference/components/core/Viewer.md'
|
|
62
|
+
- layout:
|
|
63
|
+
- BottomDrawer: 'reference/components/layout/BottomDrawer.md'
|
|
64
|
+
- CorneredGrid: 'reference/components/layout/CorneredGrid.md'
|
|
65
|
+
- Mini: 'reference/components/layout/Mini.md'
|
|
66
|
+
- Tabs: 'reference/components/layout/Tabs.md'
|
|
67
|
+
- menus:
|
|
68
|
+
- MapBackground: 'reference/components/menus/MapBackground.md'
|
|
69
|
+
- MapFilters: 'reference/components/menus/MapFilters.md'
|
|
70
|
+
- MapLayers: 'reference/components/menus/MapLayers.md'
|
|
71
|
+
- MapLegend: 'reference/components/menus/MapLegend.md'
|
|
72
|
+
- PictureLegend: 'reference/components/menus/PictureLegend.md'
|
|
73
|
+
- PictureMetadata: 'reference/components/menus/PictureMetadata.md'
|
|
74
|
+
- PlayerOptions: 'reference/components/menus/PlayerOptions.md'
|
|
75
|
+
- QualityScoreDoc: 'reference/components/menus/QualityScoreDoc.md'
|
|
76
|
+
- ReportForm: 'reference/components/menus/ReportForm.md'
|
|
77
|
+
- ShareMenu: 'reference/components/menus/ShareMenu.md'
|
|
78
|
+
- ui:
|
|
79
|
+
- widgets:
|
|
80
|
+
- GeoSearch: 'reference/components/ui/widgets/GeoSearch.md'
|
|
81
|
+
- Legend: 'reference/components/ui/widgets/Legend.md'
|
|
82
|
+
- MapFiltersButton: 'reference/components/ui/widgets/MapFiltersButton.md'
|
|
83
|
+
- MapLayersButton: 'reference/components/ui/widgets/MapLayersButton.md'
|
|
84
|
+
- OSMEditors: 'reference/components/ui/widgets/OSMEditors.md'
|
|
85
|
+
- PictureLegendActions: 'reference/components/ui/widgets/PictureLegendActions.md'
|
|
86
|
+
- Player: 'reference/components/ui/widgets/Player.md'
|
|
87
|
+
- Zoom: 'reference/components/ui/widgets/Zoom.md'
|
|
88
|
+
- Button: 'reference/components/ui/Button.md'
|
|
89
|
+
- ButtonGroup: 'reference/components/ui/ButtonGroup.md'
|
|
90
|
+
- CopyButton: 'reference/components/ui/CopyButton.md'
|
|
91
|
+
- Grade: 'reference/components/ui/Grade.md'
|
|
92
|
+
- LinkButton: 'reference/components/ui/LinkButton.md'
|
|
93
|
+
- ListGroup: 'reference/components/ui/ListGroup.md'
|
|
94
|
+
- Loader: 'reference/components/ui/Loader.md'
|
|
95
|
+
- Map: 'reference/components/ui/Map.md'
|
|
96
|
+
- MapMore: 'reference/components/ui/MapMore.md'
|
|
97
|
+
- Photo: 'reference/components/ui/Photo.md'
|
|
98
|
+
- Popup: 'reference/components/ui/Popup.md'
|
|
99
|
+
- ProgressBar: 'reference/components/ui/ProgressBar.md'
|
|
100
|
+
- QualityScore: 'reference/components/ui/QualityScore.md'
|
|
101
|
+
- SearchBar: 'reference/components/ui/SearchBar.md'
|
|
102
|
+
- TogglableGroup: 'reference/components/ui/TogglableGroup.md'
|
|
103
|
+
- utils:
|
|
104
|
+
- API: 'reference/utils/API.md'
|
|
105
|
+
- InitParameters: 'reference/utils/InitParameters.md'
|
|
106
|
+
- URLHandler: 'reference/utils/URLHandler.md'
|