@panoramax/web-viewer 3.2.3 → 4.0.0-develop-39167b4d
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 +53 -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
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@panoramax/web-viewer",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.0.0-develop-39167b4d",
|
|
4
4
|
"description": "Panoramax web viewer for geolocated pictures",
|
|
5
5
|
"main": "build/index.js",
|
|
6
6
|
"author": "Panoramax team",
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"build": "node scripts/build.js",
|
|
10
10
|
"test": "node scripts/test.js",
|
|
11
11
|
"lint": "npx eslint --fix src/*.js src/**/*.js",
|
|
12
|
-
"doc": "
|
|
12
|
+
"doc": "node scripts/doc.js",
|
|
13
13
|
"coverage": "node scripts/test.js --coverage --watchAll=false",
|
|
14
14
|
"trypublish": "npm publish || true"
|
|
15
15
|
},
|
|
@@ -60,6 +60,7 @@
|
|
|
60
60
|
"jest": "^27.4.3",
|
|
61
61
|
"jest-resolve": "^29.4.1",
|
|
62
62
|
"jest-watch-typeahead": "^2.1.1",
|
|
63
|
+
"jsdoc-to-markdown": "^9.1.1",
|
|
63
64
|
"mini-css-extract-plugin": "^2.7.2",
|
|
64
65
|
"postcss": "^8.4.21",
|
|
65
66
|
"postcss-flexbugs-fixes": "^5.0.2",
|
|
@@ -88,17 +89,20 @@
|
|
|
88
89
|
"workbox-webpack-plugin": "^6.5.4"
|
|
89
90
|
},
|
|
90
91
|
"dependencies": {
|
|
91
|
-
"@
|
|
92
|
-
"@fortawesome/
|
|
93
|
-
"@fortawesome/free-
|
|
94
|
-
"@
|
|
95
|
-
"@photo-sphere-viewer/
|
|
96
|
-
"@photo-sphere-viewer/
|
|
97
|
-
"@photo-sphere-viewer/
|
|
98
|
-
"@photo-sphere-viewer/
|
|
99
|
-
"
|
|
100
|
-
"
|
|
101
|
-
"
|
|
92
|
+
"@fontsource/atkinson-hyperlegible-next": "^5.2.2",
|
|
93
|
+
"@fortawesome/fontawesome-svg-core": "^6.7.2",
|
|
94
|
+
"@fortawesome/free-regular-svg-icons": "^6.7.2",
|
|
95
|
+
"@fortawesome/free-solid-svg-icons": "^6.7.2",
|
|
96
|
+
"@photo-sphere-viewer/core": "5.12.1",
|
|
97
|
+
"@photo-sphere-viewer/equirectangular-tiles-adapter": "5.12.1",
|
|
98
|
+
"@photo-sphere-viewer/gallery-plugin": "5.12.1",
|
|
99
|
+
"@photo-sphere-viewer/markers-plugin": "5.12.1",
|
|
100
|
+
"@photo-sphere-viewer/virtual-tour-plugin": "5.12.1",
|
|
101
|
+
"json5": "^2.2.3",
|
|
102
|
+
"lit": "^3.2.1",
|
|
103
|
+
"maplibre-gl": "^5.3.0",
|
|
104
|
+
"pmtiles": "^4.3.0",
|
|
105
|
+
"query-selector-shadow-dom": "^1.0.1"
|
|
102
106
|
},
|
|
103
107
|
"eslintConfig": {
|
|
104
108
|
"env": {
|
|
@@ -188,10 +192,11 @@
|
|
|
188
192
|
"setupFiles": [
|
|
189
193
|
"react-app-polyfill/jsdom"
|
|
190
194
|
],
|
|
191
|
-
"setupFilesAfterEnv": [
|
|
195
|
+
"setupFilesAfterEnv": [
|
|
196
|
+
"<rootDir>/config/jest/mocks.js"
|
|
197
|
+
],
|
|
192
198
|
"testMatch": [
|
|
193
|
-
"<rootDir>/tests
|
|
194
|
-
"<rootDir>/tests/**/*.{spec,test}.{js,jsx,ts,tsx}"
|
|
199
|
+
"<rootDir>/tests/**/*.test.js"
|
|
195
200
|
],
|
|
196
201
|
"testEnvironment": "jsdom",
|
|
197
202
|
"transform": {
|
|
@@ -252,4 +257,4 @@
|
|
|
252
257
|
]
|
|
253
258
|
]
|
|
254
259
|
}
|
|
255
|
-
}
|
|
260
|
+
}
|
package/public/editor.html
CHANGED
|
@@ -13,10 +13,7 @@
|
|
|
13
13
|
}
|
|
14
14
|
#editor.fullpage {
|
|
15
15
|
position: fixed;
|
|
16
|
-
|
|
17
|
-
bottom: 0;
|
|
18
|
-
left: 0;
|
|
19
|
-
right: 0;
|
|
16
|
+
inset: 0;
|
|
20
17
|
height: unset;
|
|
21
18
|
width: unset;
|
|
22
19
|
margin: 0;
|
|
@@ -27,30 +24,25 @@
|
|
|
27
24
|
<noscript>
|
|
28
25
|
You need to enable JavaScript to run this app.
|
|
29
26
|
</noscript>
|
|
30
|
-
|
|
31
|
-
<
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
);
|
|
53
|
-
};
|
|
54
|
-
</script>
|
|
27
|
+
|
|
28
|
+
<pnx-editor
|
|
29
|
+
id="editor"
|
|
30
|
+
class="fullpage"
|
|
31
|
+
endpoint="https://panoramax.openstreetmap.fr/api"
|
|
32
|
+
sequence="ecfe4b2c-0acd-4d3a-a10d-c3e6818755c8"
|
|
33
|
+
picture="329af5c6-4761-4a6d-9c1e-674fd6daa8b6"
|
|
34
|
+
background="aerial"
|
|
35
|
+
raster='{
|
|
36
|
+
type: "raster",
|
|
37
|
+
tiles: [
|
|
38
|
+
"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}"
|
|
39
|
+
],
|
|
40
|
+
minzoom: 0,
|
|
41
|
+
maxzoom: 21,
|
|
42
|
+
attribution: "© IGN",
|
|
43
|
+
tileSize: 256
|
|
44
|
+
}'
|
|
45
|
+
></pnx-editor>
|
|
46
|
+
|
|
55
47
|
</body>
|
|
56
48
|
</html>
|
package/public/index.html
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
2
|
<html lang="en">
|
|
3
3
|
<head>
|
|
4
|
-
<meta charset="utf-8"
|
|
5
|
-
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"
|
|
4
|
+
<meta charset="utf-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
|
|
6
6
|
<title>Panoramax JS Library</title>
|
|
7
7
|
<style>
|
|
8
8
|
body {
|
|
@@ -18,9 +18,8 @@
|
|
|
18
18
|
}
|
|
19
19
|
.oneView {
|
|
20
20
|
text-align: center;
|
|
21
|
-
flex
|
|
22
|
-
|
|
23
|
-
min-width: 30%;
|
|
21
|
+
flex: 1;
|
|
22
|
+
min-width: 400px;
|
|
24
23
|
}
|
|
25
24
|
iframe {
|
|
26
25
|
width: 100%;
|
|
@@ -34,24 +33,30 @@
|
|
|
34
33
|
You need to enable JavaScript to run this app.
|
|
35
34
|
</noscript>
|
|
36
35
|
<h1>Panoramax JavaScript Client</h1>
|
|
37
|
-
<p>Panoramax JS library offers different views to suit your needs
|
|
36
|
+
<p>Panoramax JS library offers different views to suit your needs.<br />You can also give a look at the <a href="./widgets.html">widgets test page</a>.</p>
|
|
38
37
|
|
|
39
38
|
<div class="allViews">
|
|
40
39
|
<div class="oneView">
|
|
41
|
-
<h2
|
|
42
|
-
<p>General-purpose map and picture display.<br /><a href="./viewer.html">Full page</a> | <a href="https://
|
|
40
|
+
<h2>Viewer</h2>
|
|
41
|
+
<p>General-purpose map and picture display.<br /><a href="./viewer.html">Full page</a> | <a href="https://viewer.geovisio.fr/docs/reference/components/core/Viewer/">Docs</a></p>
|
|
43
42
|
<iframe src="./viewer.html?server=meta"></iframe>
|
|
44
43
|
</div>
|
|
45
44
|
|
|
46
45
|
<div class="oneView">
|
|
47
|
-
<h2
|
|
48
|
-
<p>
|
|
46
|
+
<h2>Photo Viewer</h2>
|
|
47
|
+
<p>Picture-only display.<br /><a href="./photo.html">Full page</a> | <a href="https://viewer.geovisio.fr/docs/reference/components/core/PhotoViewer/">Docs</a></p>
|
|
48
|
+
<iframe src="./photo.html?server=meta"></iframe>
|
|
49
|
+
</div>
|
|
50
|
+
|
|
51
|
+
<div class="oneView">
|
|
52
|
+
<h2>Coverage Map</h2>
|
|
53
|
+
<p>A map-only view, to locate sequences and pictures.<br /><a href="./map.html">Full page</a> | <a href="https://viewer.geovisio.fr/docs/reference/components/core/CoverageMap/">Docs</a></p>
|
|
49
54
|
<iframe src="./map.html"></iframe>
|
|
50
55
|
</div>
|
|
51
56
|
|
|
52
57
|
<div class="oneView">
|
|
53
|
-
<h2
|
|
54
|
-
<p>A map and picture view, focused around metadata editing.<br /><a href="./editor.html">Full page</a> | <a href="https://
|
|
58
|
+
<h2>Editor</h2>
|
|
59
|
+
<p>A map and picture view, focused around metadata editing.<br /><a href="./editor.html">Full page</a> | <a href="https://viewer.geovisio.fr/docs/reference/components/core/Editor/">Docs</a></p>
|
|
55
60
|
<iframe src="./editor.html"></iframe>
|
|
56
61
|
</div>
|
|
57
62
|
</div>
|
package/public/map.html
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
<head>
|
|
4
4
|
<meta charset="utf-8">
|
|
5
5
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
|
6
|
-
<title>Panoramax
|
|
6
|
+
<title>Panoramax Coverage Map</title>
|
|
7
7
|
<style>
|
|
8
8
|
#map {
|
|
9
9
|
position: relative;
|
|
@@ -27,27 +27,28 @@
|
|
|
27
27
|
<noscript>
|
|
28
28
|
You need to enable JavaScript to run this app.
|
|
29
29
|
</noscript>
|
|
30
|
-
|
|
30
|
+
|
|
31
|
+
<pnx-coverage-map
|
|
32
|
+
id="coverage"
|
|
33
|
+
class="fullpage"
|
|
34
|
+
endpoint="https://api.panoramax.xyz/api"
|
|
35
|
+
/>
|
|
36
|
+
|
|
31
37
|
<script>
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
map = new Panoramax.StandaloneMap(
|
|
35
|
-
"map",
|
|
36
|
-
"https://api.panoramax.xyz/api",
|
|
37
|
-
);
|
|
38
|
+
// Retrieve component from DOM
|
|
39
|
+
var coverage = document.getElementById("coverage");
|
|
38
40
|
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
41
|
+
coverage.addEventListener("ready", () => {
|
|
42
|
+
// Listen to sequence hovered on map
|
|
43
|
+
coverage.map.on("sequence-hover", e => {
|
|
44
|
+
console.log("Hovered sequence", e.seqId);
|
|
45
|
+
});
|
|
44
46
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
});
|
|
47
|
+
// Listen to user clicks on map
|
|
48
|
+
coverage.addEventListener("select", e => {
|
|
49
|
+
console.log("Selected sequence", e.detail.seqId, "picture", e.detail.picId);
|
|
49
50
|
});
|
|
50
|
-
};
|
|
51
|
+
}, {once: true});
|
|
51
52
|
</script>
|
|
52
53
|
</body>
|
|
53
54
|
</html>
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="utf-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
|
|
6
|
+
<title>Panoramax Photo Viewer</title>
|
|
7
|
+
<style>
|
|
8
|
+
#viewer {
|
|
9
|
+
position: relative;
|
|
10
|
+
width: 95%;
|
|
11
|
+
margin: 2.5%;
|
|
12
|
+
height: 400px;
|
|
13
|
+
}
|
|
14
|
+
#viewer.fullpage {
|
|
15
|
+
position: fixed;
|
|
16
|
+
top: 0;
|
|
17
|
+
bottom: 0;
|
|
18
|
+
left: 0;
|
|
19
|
+
right: 0;
|
|
20
|
+
height: unset;
|
|
21
|
+
width: unset;
|
|
22
|
+
margin: 0;
|
|
23
|
+
}
|
|
24
|
+
</style>
|
|
25
|
+
</head>
|
|
26
|
+
<body>
|
|
27
|
+
<noscript>
|
|
28
|
+
You need to enable JavaScript to run this app.
|
|
29
|
+
</noscript>
|
|
30
|
+
|
|
31
|
+
<pnx-photo-viewer
|
|
32
|
+
id="viewer"
|
|
33
|
+
class="fullpage"
|
|
34
|
+
sequence="ecfe4b2c-0acd-4d3a-a10d-c3e6818755c8"
|
|
35
|
+
picture="329af5c6-4761-4a6d-9c1e-674fd6daa8b6"
|
|
36
|
+
/>
|
|
37
|
+
|
|
38
|
+
<script>
|
|
39
|
+
var servers = {
|
|
40
|
+
meta: "https://api.panoramax.xyz/api",
|
|
41
|
+
ign: "https://panoramax.ign.fr/api",
|
|
42
|
+
osm: "https://panoramax.openstreetmap.fr/api",
|
|
43
|
+
local: "http://localhost:5000/api",
|
|
44
|
+
dev: "https://panoramax.codeureusesenliberte.fr/api",
|
|
45
|
+
};
|
|
46
|
+
var urlParams = new URLSearchParams(window.location.search);
|
|
47
|
+
var server = servers[urlParams.get("server") || "meta"];
|
|
48
|
+
|
|
49
|
+
window.onload = () => {
|
|
50
|
+
var viewer = document.getElementById("viewer");
|
|
51
|
+
viewer.setAttribute("endpoint", server);
|
|
52
|
+
};
|
|
53
|
+
</script>
|
|
54
|
+
</body>
|
|
55
|
+
</html>
|
package/public/viewer.html
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
2
|
<html lang="en">
|
|
3
3
|
<head>
|
|
4
|
-
<meta charset="utf-8"
|
|
5
|
-
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"
|
|
4
|
+
<meta charset="utf-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
|
|
6
6
|
<title>Panoramax Web Viewer</title>
|
|
7
7
|
<style>
|
|
8
8
|
#viewer {
|
|
@@ -27,9 +27,25 @@
|
|
|
27
27
|
<noscript>
|
|
28
28
|
You need to enable JavaScript to run this app.
|
|
29
29
|
</noscript>
|
|
30
|
-
|
|
30
|
+
|
|
31
|
+
<pnx-viewer
|
|
32
|
+
id="viewer"
|
|
33
|
+
class="fullpage"
|
|
34
|
+
map='{
|
|
35
|
+
raster: {
|
|
36
|
+
type: "raster",
|
|
37
|
+
tiles: [
|
|
38
|
+
"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}"
|
|
39
|
+
],
|
|
40
|
+
minzoom: 0,
|
|
41
|
+
maxzoom: 21,
|
|
42
|
+
attribution: "© IGN",
|
|
43
|
+
tileSize: 256
|
|
44
|
+
}
|
|
45
|
+
}'
|
|
46
|
+
/>
|
|
47
|
+
|
|
31
48
|
<script>
|
|
32
|
-
var viewer;
|
|
33
49
|
var servers = {
|
|
34
50
|
meta: "https://api.panoramax.xyz/api",
|
|
35
51
|
ign: "https://panoramax.ign.fr/api",
|
|
@@ -41,28 +57,8 @@
|
|
|
41
57
|
var server = servers[urlParams.get("server") || "meta"];
|
|
42
58
|
|
|
43
59
|
window.onload = () => {
|
|
44
|
-
viewer =
|
|
45
|
-
|
|
46
|
-
server,
|
|
47
|
-
{
|
|
48
|
-
widgets: {
|
|
49
|
-
iframeBaseURL: "https://api.panoramax.xyz/"
|
|
50
|
-
},
|
|
51
|
-
map: {
|
|
52
|
-
startWide: true,
|
|
53
|
-
raster: {
|
|
54
|
-
type: "raster",
|
|
55
|
-
tiles: [
|
|
56
|
-
"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}"
|
|
57
|
-
],
|
|
58
|
-
minzoom: 0,
|
|
59
|
-
maxzoom: 21,
|
|
60
|
-
attribution: "© IGN",
|
|
61
|
-
tileSize: 256
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
);
|
|
60
|
+
var viewer = document.getElementById("viewer");
|
|
61
|
+
viewer.setAttribute("endpoint", server);
|
|
66
62
|
};
|
|
67
63
|
</script>
|
|
68
64
|
</body>
|