@map-colonies/react-components 3.12.2 → 3.12.3
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/.eslintignore +1 -1
- package/.storybook/main.js +13 -13
- package/.storybook/manager.js +6 -6
- package/.storybook/preview-head.html +21 -21
- package/.storybook/preview.js +18 -18
- package/.storybook/theme.js +9 -9
- package/CHANGELOG.md +828 -819
- package/README.md +53 -53
- package/dist/autocomplete/autocomplete.css +25 -25
- package/dist/autocomplete/autocomplete.d.ts +33 -33
- package/dist/autocomplete/autocomplete.js +478 -478
- package/dist/autocomplete/index.d.ts +1 -1
- package/dist/autocomplete/index.js +5 -5
- package/dist/box/box.d.ts +3 -3
- package/dist/box/box.js +35 -35
- package/dist/box/index.d.ts +1 -1
- package/dist/box/index.js +5 -5
- package/dist/cesium-map/data-sources/custom.data-source.d.ts +5 -5
- package/dist/cesium-map/data-sources/custom.data-source.js +23 -23
- package/dist/cesium-map/data-sources/drawings.data-source.d.ts +34 -34
- package/dist/cesium-map/data-sources/drawings.data-source.js +187 -187
- package/dist/cesium-map/data-sources/index.d.ts +2 -2
- package/dist/cesium-map/data-sources/index.js +14 -14
- package/dist/cesium-map/entities/entity.d.ts +5 -5
- package/dist/cesium-map/entities/entity.description.d.ts +6 -6
- package/dist/cesium-map/entities/entity.description.js +27 -27
- package/dist/cesium-map/entities/entity.js +23 -23
- package/dist/cesium-map/entities/graphics/polygon.graphics.d.ts +5 -5
- package/dist/cesium-map/entities/graphics/polygon.graphics.js +23 -23
- package/dist/cesium-map/entities/graphics/polyline.graphics.d.ts +5 -5
- package/dist/cesium-map/entities/graphics/polyline.graphics.js +23 -23
- package/dist/cesium-map/entities/graphics/rectangle.graphics.d.ts +5 -5
- package/dist/cesium-map/entities/graphics/rectangle.graphics.js +23 -23
- package/dist/cesium-map/entities/index.d.ts +4 -4
- package/dist/cesium-map/entities/index.js +16 -16
- package/dist/cesium-map/index.d.ts +8 -8
- package/dist/cesium-map/index.js +20 -20
- package/dist/cesium-map/layers/3d.tileset.d.ts +7 -7
- package/dist/cesium-map/layers/3d.tileset.js +43 -43
- package/dist/cesium-map/layers/3d.tileset.with.update.d.ts +6 -6
- package/dist/cesium-map/layers/3d.tileset.with.update.js +115 -115
- package/dist/cesium-map/layers/geojson.layer.d.ts +5 -5
- package/dist/cesium-map/layers/geojson.layer.js +23 -23
- package/dist/cesium-map/layers/imagery.layer.d.ts +6 -6
- package/dist/cesium-map/layers/imagery.layer.js +68 -68
- package/dist/cesium-map/layers/index.d.ts +7 -7
- package/dist/cesium-map/layers/index.js +19 -19
- package/dist/cesium-map/layers/osm.layer.d.ts +9 -9
- package/dist/cesium-map/layers/osm.layer.js +36 -36
- package/dist/cesium-map/layers/wms.layer.d.ts +9 -9
- package/dist/cesium-map/layers/wms.layer.js +36 -36
- package/dist/cesium-map/layers/wmts.layer.d.ts +9 -9
- package/dist/cesium-map/layers/wmts.layer.js +36 -36
- package/dist/cesium-map/layers/xyz.layer.d.ts +9 -9
- package/dist/cesium-map/layers/xyz.layer.js +36 -36
- package/dist/cesium-map/layers-manager.d.ts +55 -55
- package/dist/cesium-map/layers-manager.js +246 -246
- package/dist/cesium-map/map-legend/MapLegend.css +135 -135
- package/dist/cesium-map/map-legend/MapLegend.d.ts +15 -15
- package/dist/cesium-map/map-legend/MapLegend.js +57 -57
- package/dist/cesium-map/map-legend/MapLegendList.d.ts +13 -13
- package/dist/cesium-map/map-legend/MapLegendList.js +43 -43
- package/dist/cesium-map/map-legend/MapLegendSidebar.d.ts +16 -16
- package/dist/cesium-map/map-legend/MapLegendSidebar.js +20 -20
- package/dist/cesium-map/map-legend/MapLegendToggle.d.ts +7 -7
- package/dist/cesium-map/map-legend/MapLegendToggle.js +20 -20
- package/dist/cesium-map/map-legend/index.d.ts +3 -3
- package/dist/cesium-map/map-legend/index.js +14 -14
- package/dist/cesium-map/map.css +59 -59
- package/dist/cesium-map/map.d.ts +59 -59
- package/dist/cesium-map/map.js +305 -305
- package/dist/cesium-map/map.types.d.ts +8 -8
- package/dist/cesium-map/map.types.js +12 -12
- package/dist/cesium-map/proxied.types.d.ts +30 -30
- package/dist/cesium-map/proxied.types.js +132 -132
- package/dist/cesium-map/settings/base-maps.css +37 -37
- package/dist/cesium-map/settings/base-maps.d.ts +7 -7
- package/dist/cesium-map/settings/base-maps.js +78 -78
- package/dist/cesium-map/settings/scene-modes.css +19 -19
- package/dist/cesium-map/settings/scene-modes.d.ts +7 -7
- package/dist/cesium-map/settings/scene-modes.js +65 -65
- package/dist/cesium-map/settings/settings.css +52 -52
- package/dist/cesium-map/settings/settings.d.ts +23 -23
- package/dist/cesium-map/settings/settings.js +79 -79
- package/dist/cesium-map/terrain-providers/custom/dummy-quantized-mesh-tile.d.ts +3 -3
- package/dist/cesium-map/terrain-providers/custom/dummy-quantized-mesh-tile.js +245 -245
- package/dist/cesium-map/terrain-providers/custom/quantized-mesh-decoder.d.ts +9 -9
- package/dist/cesium-map/terrain-providers/custom/quantized-mesh-decoder.js +202 -202
- package/dist/cesium-map/terrain-providers/custom/quantized-mesh-terrain-provider.d.ts +50 -50
- package/dist/cesium-map/terrain-providers/custom/quantized-mesh-terrain-provider.js +136 -136
- package/dist/cesium-map/tools/cesium/primitives-conversions.cesium.d.ts +2 -2
- package/dist/cesium-map/tools/cesium/primitives-conversions.cesium.js +38 -38
- package/dist/cesium-map/tools/coordinates-tracker.tool.css +11 -11
- package/dist/cesium-map/tools/coordinates-tracker.tool.d.ts +7 -7
- package/dist/cesium-map/tools/coordinates-tracker.tool.js +78 -78
- package/dist/cesium-map/tools/draw/drawHelper.css +101 -101
- package/dist/cesium-map/tools/draw/drawHelper.d.ts +28 -28
- package/dist/cesium-map/tools/draw/drawHelper.js +1694 -1694
- package/dist/cesium-map/tools/geojson/geojson-to-primitive.d.ts +4 -4
- package/dist/cesium-map/tools/geojson/geojson-to-primitive.js +41 -41
- package/dist/cesium-map/tools/geojson/index.d.ts +2 -2
- package/dist/cesium-map/tools/geojson/index.js +14 -14
- package/dist/cesium-map/tools/geojson/point.geojson.d.ts +3 -3
- package/dist/cesium-map/tools/geojson/point.geojson.js +21 -21
- package/dist/cesium-map/tools/geojson/polygon.geojson.d.ts +3 -3
- package/dist/cesium-map/tools/geojson/polygon.geojson.js +24 -24
- package/dist/cesium-map/tools/geojson/rectangle.geojson.d.ts +3 -3
- package/dist/cesium-map/tools/geojson/rectangle.geojson.js +44 -44
- package/dist/cesium-map/tools/inspector.tool.d.ts +4 -4
- package/dist/cesium-map/tools/inspector.tool.js +33 -33
- package/dist/cesium-map/tools/scale-tracker.tool.css +16 -16
- package/dist/cesium-map/tools/scale-tracker.tool.d.ts +8 -8
- package/dist/cesium-map/tools/scale-tracker.tool.js +158 -158
- package/dist/cesium-map/tools/terranian-height.tool.d.ts +4 -4
- package/dist/cesium-map/tools/terranian-height.tool.js +114 -114
- package/dist/cssbaseline/cssbaseline.d.ts +5 -5
- package/dist/cssbaseline/cssbaseline.js +41 -41
- package/dist/cssbaseline/index.d.ts +1 -1
- package/dist/cssbaseline/index.js +6 -6
- package/dist/date-picker/date-picker.css +9 -9
- package/dist/date-picker/date-picker.d.ts +14 -14
- package/dist/date-picker/date-picker.js +78 -78
- package/dist/date-picker/index.d.ts +1 -1
- package/dist/date-picker/index.js +13 -13
- package/dist/date-range-picker/date-range-picker.css +9 -9
- package/dist/date-range-picker/date-range-picker.d.ts +26 -26
- package/dist/date-range-picker/date-range-picker.form-control.css +3 -3
- package/dist/date-range-picker/date-range-picker.form-control.d.ts +28 -28
- package/dist/date-range-picker/date-range-picker.form-control.js +95 -95
- package/dist/date-range-picker/date-range-picker.js +104 -104
- package/dist/date-range-picker/index.d.ts +2 -2
- package/dist/date-range-picker/index.js +14 -14
- package/dist/file-picker/file-picker.css +63 -63
- package/dist/file-picker/file-picker.d.ts +276 -276
- package/dist/file-picker/file-picker.js +151 -151
- package/dist/file-picker/fs-map.json +1556 -1556
- package/dist/file-picker/index.d.ts +2 -2
- package/dist/file-picker/index.js +14 -14
- package/dist/file-picker/localization.d.ts +11 -11
- package/dist/file-picker/localization.js +124 -124
- package/dist/index.d.ts +13 -13
- package/dist/index.js +25 -25
- package/dist/map-filter-container/container-map.css +5 -5
- package/dist/map-filter-container/container-map.d.ts +11 -11
- package/dist/map-filter-container/container-map.js +31 -31
- package/dist/map-filter-container/index.d.ts +1 -1
- package/dist/map-filter-container/index.js +13 -13
- package/dist/map-filter-container/map-filter-container.d.ts +9 -9
- package/dist/map-filter-container/map-filter-container.js +78 -78
- package/dist/map-filter-container/polygon-selection-ui.d.ts +12 -12
- package/dist/map-filter-container/polygon-selection-ui.js +62 -62
- package/dist/models/defaults.d.ts +28 -28
- package/dist/models/defaults.js +32 -32
- package/dist/models/enums.d.ts +14 -14
- package/dist/models/enums.js +20 -20
- package/dist/models/index.d.ts +1 -1
- package/dist/models/index.js +13 -13
- package/dist/ol-map/feature.d.ts +6 -6
- package/dist/ol-map/feature.js +20 -20
- package/dist/ol-map/index.d.ts +6 -6
- package/dist/ol-map/index.js +18 -18
- package/dist/ol-map/interactions/draw.d.ts +8 -8
- package/dist/ol-map/interactions/draw.js +44 -44
- package/dist/ol-map/interactions/index.d.ts +1 -1
- package/dist/ol-map/interactions/index.js +13 -13
- package/dist/ol-map/layers/index.d.ts +3 -3
- package/dist/ol-map/layers/index.js +15 -15
- package/dist/ol-map/layers/tile-layer.d.ts +9 -9
- package/dist/ol-map/layers/tile-layer.js +48 -48
- package/dist/ol-map/layers/vector-layer.d.ts +4 -4
- package/dist/ol-map/layers/vector-layer.js +48 -48
- package/dist/ol-map/layers/vector-tile-layer.d.ts +10 -10
- package/dist/ol-map/layers/vector-tile-layer.js +66 -66
- package/dist/ol-map/map.css +17 -17
- package/dist/ol-map/map.d.ts +14 -14
- package/dist/ol-map/map.js +117 -117
- package/dist/ol-map/source/index.d.ts +6 -6
- package/dist/ol-map/source/index.js +18 -18
- package/dist/ol-map/source/mvt.d.ts +11 -11
- package/dist/ol-map/source/mvt.js +37 -37
- package/dist/ol-map/source/osm.d.ts +2 -2
- package/dist/ol-map/source/osm.js +14 -14
- package/dist/ol-map/source/vector-source.d.ts +4 -4
- package/dist/ol-map/source/vector-source.js +45 -45
- package/dist/ol-map/source/wms.d.ts +17 -17
- package/dist/ol-map/source/wms.js +30 -30
- package/dist/ol-map/source/wmts.d.ts +21 -21
- package/dist/ol-map/source/wmts.js +59 -59
- package/dist/ol-map/source/xyz.d.ts +12 -12
- package/dist/ol-map/source/xyz.js +27 -27
- package/dist/ol-map/style.d.ts +4 -4
- package/dist/ol-map/style.js +22 -22
- package/dist/popover/index.d.ts +1 -1
- package/dist/popover/index.js +5 -5
- package/dist/popover/popover.d.ts +3 -3
- package/dist/popover/popover.js +35 -35
- package/dist/smart-table/__mock-data__/smartTableMocks.d.ts +7 -7
- package/dist/smart-table/__mock-data__/smartTableMocks.js +17 -17
- package/dist/smart-table/index.d.ts +2 -2
- package/dist/smart-table/index.js +14 -14
- package/dist/smart-table/smart-table-head.d.ts +11 -11
- package/dist/smart-table/smart-table-head.js +22 -22
- package/dist/smart-table/smart-table-row.d.ts +12 -12
- package/dist/smart-table/smart-table-row.js +46 -46
- package/dist/smart-table/smart-table-types.d.ts +9 -9
- package/dist/smart-table/smart-table-types.js +2 -2
- package/dist/smart-table/smart-table.d.ts +17 -17
- package/dist/smart-table/smart-table.js +51 -51
- package/dist/theme/index.d.ts +1 -1
- package/dist/theme/index.js +13 -13
- package/dist/theme/theme.d.ts +8 -8
- package/dist/theme/theme.js +124 -124
- package/dist/utils/map.d.ts +3 -3
- package/dist/utils/map.js +21 -21
- package/dist/utils/projections.d.ts +6 -6
- package/dist/utils/projections.js +10 -10
- package/dist/utils/story.d.ts +12 -12
- package/dist/utils/story.js +2 -2
- package/package.json +3 -3
- package/public/index.html +43 -43
- package/public/manifest.json +25 -25
- package/public/robots.txt +3 -3
- package/src/index.tsx +9 -9
- package/src/lib/autocomplete/autocomplete.css +25 -25
- package/src/lib/autocomplete/autocomplete.stories.tsx +101 -101
- package/src/lib/autocomplete/autocomplete.tsx +681 -681
- package/src/lib/autocomplete/index.ts +1 -1
- package/src/lib/box/box.tsx +7 -7
- package/src/lib/box/index.ts +1 -1
- package/src/lib/cesium-map/context-menu.stories.tsx +444 -444
- package/src/lib/cesium-map/data-sources/custom.data-source.tsx +12 -12
- package/src/lib/cesium-map/data-sources/drawings.data-source.stories.tsx +161 -161
- package/src/lib/cesium-map/data-sources/drawings.data-source.tsx +204 -204
- package/src/lib/cesium-map/data-sources/index.ts +2 -2
- package/src/lib/cesium-map/entities/entity.description.tsx +19 -19
- package/src/lib/cesium-map/entities/entity.graphics.stories.tsx +48 -48
- package/src/lib/cesium-map/entities/entity.stories.tsx +146 -146
- package/src/lib/cesium-map/entities/entity.tsx +10 -10
- package/src/lib/cesium-map/entities/graphics/polygon.graphics.tsx +12 -12
- package/src/lib/cesium-map/entities/graphics/polyline.graphics.tsx +12 -12
- package/src/lib/cesium-map/entities/graphics/rectangle.graphics.tsx +12 -12
- package/src/lib/cesium-map/entities/index.ts +4 -4
- package/src/lib/cesium-map/index.ts +8 -8
- package/src/lib/cesium-map/layers/3d.tileset.stories.tsx +164 -164
- package/src/lib/cesium-map/layers/3d.tileset.tsx +51 -51
- package/src/lib/cesium-map/layers/3d.tileset.with.update.tsx +120 -120
- package/src/lib/cesium-map/layers/geojson.layer.stories.tsx +119 -119
- package/src/lib/cesium-map/layers/geojson.layer.tsx +12 -12
- package/src/lib/cesium-map/layers/imagery.layer.stories.tsx +39 -39
- package/src/lib/cesium-map/layers/imagery.layer.tsx +37 -37
- package/src/lib/cesium-map/layers/index.ts +7 -7
- package/src/lib/cesium-map/layers/layers.rect.stories.tsx +171 -171
- package/src/lib/cesium-map/layers/osm.layer.stories.tsx +40 -40
- package/src/lib/cesium-map/layers/osm.layer.tsx +22 -22
- package/src/lib/cesium-map/layers/wms.layer.stories.tsx +38 -38
- package/src/lib/cesium-map/layers/wms.layer.tsx +22 -22
- package/src/lib/cesium-map/layers/wmts.layer.stories.tsx +53 -53
- package/src/lib/cesium-map/layers/wmts.layer.tsx +22 -22
- package/src/lib/cesium-map/layers/xyz.layer.stories.tsx +37 -37
- package/src/lib/cesium-map/layers/xyz.layer.tsx +22 -22
- package/src/lib/cesium-map/layers-manager.stories.tsx +286 -286
- package/src/lib/cesium-map/layers-manager.ts +354 -354
- package/src/lib/cesium-map/map-legend/MapLegend.css +135 -135
- package/src/lib/cesium-map/map-legend/MapLegend.tsx +92 -92
- package/src/lib/cesium-map/map-legend/MapLegendList.tsx +47 -47
- package/src/lib/cesium-map/map-legend/MapLegendSidebar.tsx +55 -55
- package/src/lib/cesium-map/map-legend/MapLegendToggle.tsx +31 -31
- package/src/lib/cesium-map/map-legend/index.tsx +3 -3
- package/src/lib/cesium-map/map-legend/legends-sidebar.stories.tsx +201 -201
- package/src/lib/cesium-map/map.css +59 -59
- package/src/lib/cesium-map/map.stories.tsx +143 -143
- package/src/lib/cesium-map/map.tsx +446 -446
- package/src/lib/cesium-map/map.types.ts +11 -11
- package/src/lib/cesium-map/proxied.types.ts +54 -54
- package/src/lib/cesium-map/settings/base-maps.css +37 -37
- package/src/lib/cesium-map/settings/base-maps.tsx +94 -94
- package/src/lib/cesium-map/settings/scene-modes.css +19 -19
- package/src/lib/cesium-map/settings/scene-modes.tsx +100 -100
- package/src/lib/cesium-map/settings/settings.css +52 -52
- package/src/lib/cesium-map/settings/settings.stories.tsx +182 -182
- package/src/lib/cesium-map/settings/settings.tsx +141 -141
- package/src/lib/cesium-map/terrain-providers/custom/dummy-quantized-mesh-tile.ts +243 -243
- package/src/lib/cesium-map/terrain-providers/custom/quantized-mesh-decoder.ts +321 -321
- package/src/lib/cesium-map/terrain-providers/custom/quantized-mesh-terrain-provider.ts +237 -237
- package/src/lib/cesium-map/terrain-providers/terrain-provider-heights-tool.stories.tsx +170 -170
- package/src/lib/cesium-map/terrain-providers/terrain-provider.stories.tsx +187 -187
- package/src/lib/cesium-map/tools/cesium/primitives-conversions.cesium.ts +15 -15
- package/src/lib/cesium-map/tools/coordinates-tracker.tool.css +11 -11
- package/src/lib/cesium-map/tools/coordinates-tracker.tool.tsx +79 -79
- package/src/lib/cesium-map/tools/draw/drawHelper.css +101 -101
- package/src/lib/cesium-map/tools/draw/drawHelper.ts +2116 -2116
- package/src/lib/cesium-map/tools/geojson/geojson-to-primitive.ts +54 -54
- package/src/lib/cesium-map/tools/geojson/index.ts +2 -2
- package/src/lib/cesium-map/tools/geojson/point.geojson.ts +29 -29
- package/src/lib/cesium-map/tools/geojson/polygon.geojson.ts +24 -24
- package/src/lib/cesium-map/tools/geojson/rectangle.geojson.ts +21 -21
- package/src/lib/cesium-map/tools/inspector.tool.tsx +15 -15
- package/src/lib/cesium-map/tools/scale-tracker.tool.css +16 -16
- package/src/lib/cesium-map/tools/scale-tracker.tool.tsx +192 -192
- package/src/lib/cesium-map/tools/terranian-height.tool.tsx +171 -171
- package/src/lib/cssbaseline/cssbaseline.tsx +19 -19
- package/src/lib/cssbaseline/index.ts +4 -4
- package/src/lib/date-picker/date-picker.css +9 -9
- package/src/lib/date-picker/date-picker.stories.tsx +130 -130
- package/src/lib/date-picker/date-picker.tsx +90 -90
- package/src/lib/date-picker/index.ts +1 -1
- package/src/lib/date-range-picker/date-range-picker.css +9 -9
- package/src/lib/date-range-picker/date-range-picker.form-control.css +3 -3
- package/src/lib/date-range-picker/date-range-picker.form-control.spec.tsx +58 -58
- package/src/lib/date-range-picker/date-range-picker.form-control.tsx +150 -150
- package/src/lib/date-range-picker/date-range-picker.stories.tsx +207 -207
- package/src/lib/date-range-picker/date-range-picker.tsx +156 -156
- package/src/lib/date-range-picker/index.ts +2 -2
- package/src/lib/file-picker/file-picker.css +63 -63
- package/src/lib/file-picker/file-picker.stories.tsx +447 -447
- package/src/lib/file-picker/file-picker.tsx +180 -180
- package/src/lib/file-picker/fs-map.json +1556 -1556
- package/src/lib/file-picker/index.ts +2 -2
- package/src/lib/file-picker/localization.ts +164 -164
- package/src/lib/index.ts +13 -13
- package/src/lib/map-filter-container/container-map.css +5 -5
- package/src/lib/map-filter-container/container-map.tsx +48 -48
- package/src/lib/map-filter-container/index.ts +1 -1
- package/src/lib/map-filter-container/map-filter-container.tsx +91 -91
- package/src/lib/map-filter-container/polygon-selection-ui.spec.tsx +119 -119
- package/src/lib/map-filter-container/polygon-selection-ui.tsx +111 -111
- package/src/lib/map-filter-container/stories/Map.stories.tsx +76 -76
- package/src/lib/models/defaults.ts +32 -32
- package/src/lib/models/enums.ts +16 -16
- package/src/lib/models/index.ts +1 -1
- package/src/lib/ol-map/feature.tsx +23 -23
- package/src/lib/ol-map/index.ts +6 -6
- package/src/lib/ol-map/interactions/draw.tsx +56 -56
- package/src/lib/ol-map/interactions/index.ts +1 -1
- package/src/lib/ol-map/layers/index.ts +3 -3
- package/src/lib/ol-map/layers/tile-layer.tsx +36 -36
- package/src/lib/ol-map/layers/vector-layer.tsx +32 -32
- package/src/lib/ol-map/layers/vector-tile-layer.tsx +56 -56
- package/src/lib/ol-map/map.css +17 -17
- package/src/lib/ol-map/map.tsx +137 -137
- package/src/lib/ol-map/source/index.ts +6 -6
- package/src/lib/ol-map/source/mvt.tsx +46 -46
- package/src/lib/ol-map/source/osm.tsx +13 -13
- package/src/lib/ol-map/source/stories/mvt.stories.tsx +68 -68
- package/src/lib/ol-map/source/stories/vector-source.stories.tsx +78 -78
- package/src/lib/ol-map/source/stories/wms.stories.tsx +51 -51
- package/src/lib/ol-map/source/stories/wmts.stories.tsx +72 -72
- package/src/lib/ol-map/source/stories/xyz.stories.tsx +53 -53
- package/src/lib/ol-map/source/vector-source.tsx +30 -30
- package/src/lib/ol-map/source/wms.tsx +40 -40
- package/src/lib/ol-map/source/wmts.tsx +82 -82
- package/src/lib/ol-map/source/xyz.tsx +33 -33
- package/src/lib/ol-map/stories/map.stories.tsx +60 -60
- package/src/lib/ol-map/style.ts +24 -24
- package/src/lib/popover/index.ts +1 -1
- package/src/lib/popover/popover.tsx +7 -7
- package/src/lib/smart-table/__mock-data__/smartTableMocks.ts +22 -22
- package/src/lib/smart-table/index.ts +2 -2
- package/src/lib/smart-table/smart-table-head.spec.tsx +116 -116
- package/src/lib/smart-table/smart-table-head.tsx +47 -47
- package/src/lib/smart-table/smart-table-row.spec.tsx +109 -109
- package/src/lib/smart-table/smart-table-row.tsx +78 -78
- package/src/lib/smart-table/smart-table-types.ts +10 -10
- package/src/lib/smart-table/smart-table.spec.tsx +116 -116
- package/src/lib/smart-table/smart-table.tsx +115 -115
- package/src/lib/smart-table/stories/SmartTable.stories.tsx +114 -114
- package/src/lib/theme/index.ts +1 -1
- package/src/lib/theme/theme.ts +123 -123
- package/src/lib/utils/map.ts +19 -19
- package/src/lib/utils/projections.ts +7 -7
- package/src/lib/utils/story.ts +11 -11
- package/src/react-app-env.d.ts +1 -1
- package/src/setupTests.ts +14 -14
- package/tsbuildconfig.json +37 -37
- package/tsconfig.json +26 -26
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { SceneMode } from 'cesium';
|
|
2
|
-
|
|
3
|
-
export type CesiumSceneModeEnum = SceneMode;
|
|
4
|
-
/* eslint-disable */
|
|
5
|
-
export const CesiumSceneMode = {
|
|
6
|
-
MORPHING: SceneMode.MORPHING,
|
|
7
|
-
COLUMBUS_VIEW: SceneMode.COLUMBUS_VIEW,
|
|
8
|
-
SCENE2D: SceneMode.SCENE2D,
|
|
9
|
-
SCENE3D: SceneMode.SCENE3D,
|
|
10
|
-
};
|
|
11
|
-
/* eslint-enable */
|
|
1
|
+
import { SceneMode } from 'cesium';
|
|
2
|
+
|
|
3
|
+
export type CesiumSceneModeEnum = SceneMode;
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
export const CesiumSceneMode = {
|
|
6
|
+
MORPHING: SceneMode.MORPHING,
|
|
7
|
+
COLUMBUS_VIEW: SceneMode.COLUMBUS_VIEW,
|
|
8
|
+
SCENE2D: SceneMode.SCENE2D,
|
|
9
|
+
SCENE3D: SceneMode.SCENE3D,
|
|
10
|
+
};
|
|
11
|
+
/* eslint-enable */
|
|
@@ -1,54 +1,54 @@
|
|
|
1
|
-
import {
|
|
2
|
-
BoundingSphere,
|
|
3
|
-
Cartesian2,
|
|
4
|
-
Cartesian3,
|
|
5
|
-
Cartographic,
|
|
6
|
-
CesiumTerrainProvider,
|
|
7
|
-
ConstantPositionProperty,
|
|
8
|
-
ConstantProperty,
|
|
9
|
-
Ellipsoid,
|
|
10
|
-
EllipsoidTerrainProvider,
|
|
11
|
-
GeographicTilingScheme,
|
|
12
|
-
LabelStyle,
|
|
13
|
-
PolylineDashMaterialProperty,
|
|
14
|
-
Rectangle,
|
|
15
|
-
Resource,
|
|
16
|
-
VerticalOrigin,
|
|
17
|
-
} from 'cesium';
|
|
18
|
-
|
|
19
|
-
// PROXIED CLASSES
|
|
20
|
-
export class CesiumPolylineDashMaterialProperty extends PolylineDashMaterialProperty {}
|
|
21
|
-
|
|
22
|
-
export class CesiumConstantProperty extends ConstantProperty {}
|
|
23
|
-
|
|
24
|
-
export class CesiumConstantPositionProperty extends ConstantPositionProperty {}
|
|
25
|
-
|
|
26
|
-
export class CesiumCartesian2 extends Cartesian2 {}
|
|
27
|
-
|
|
28
|
-
export class CesiumCartesian3 extends Cartesian3 {}
|
|
29
|
-
|
|
30
|
-
export class CesiumCartographic extends Cartographic {}
|
|
31
|
-
|
|
32
|
-
export class CesiumBoundingSphere extends BoundingSphere {}
|
|
33
|
-
|
|
34
|
-
export class CesiumEllipsoid extends Ellipsoid {}
|
|
35
|
-
|
|
36
|
-
export class CesiumGeographicTilingScheme extends GeographicTilingScheme {}
|
|
37
|
-
|
|
38
|
-
export class CesiumRectangle extends Rectangle {}
|
|
39
|
-
|
|
40
|
-
export class CesiumResource extends Resource {}
|
|
41
|
-
|
|
42
|
-
export class CesiumEllipsoidTerrainProvider extends EllipsoidTerrainProvider {}
|
|
43
|
-
|
|
44
|
-
export class CesiumCesiumTerrainProvider extends CesiumTerrainProvider {}
|
|
45
|
-
|
|
46
|
-
// PROXIED ENUMS
|
|
47
|
-
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
48
|
-
export const CesiumVerticalOrigin = VerticalOrigin;
|
|
49
|
-
|
|
50
|
-
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
51
|
-
export const CesiumLabelStyle = LabelStyle;
|
|
52
|
-
|
|
53
|
-
// PROXIED FUNCTIONS
|
|
54
|
-
export { sampleTerrainMostDetailed as cesiumSampleTerrainMostDetailed } from 'cesium';
|
|
1
|
+
import {
|
|
2
|
+
BoundingSphere,
|
|
3
|
+
Cartesian2,
|
|
4
|
+
Cartesian3,
|
|
5
|
+
Cartographic,
|
|
6
|
+
CesiumTerrainProvider,
|
|
7
|
+
ConstantPositionProperty,
|
|
8
|
+
ConstantProperty,
|
|
9
|
+
Ellipsoid,
|
|
10
|
+
EllipsoidTerrainProvider,
|
|
11
|
+
GeographicTilingScheme,
|
|
12
|
+
LabelStyle,
|
|
13
|
+
PolylineDashMaterialProperty,
|
|
14
|
+
Rectangle,
|
|
15
|
+
Resource,
|
|
16
|
+
VerticalOrigin,
|
|
17
|
+
} from 'cesium';
|
|
18
|
+
|
|
19
|
+
// PROXIED CLASSES
|
|
20
|
+
export class CesiumPolylineDashMaterialProperty extends PolylineDashMaterialProperty {}
|
|
21
|
+
|
|
22
|
+
export class CesiumConstantProperty extends ConstantProperty {}
|
|
23
|
+
|
|
24
|
+
export class CesiumConstantPositionProperty extends ConstantPositionProperty {}
|
|
25
|
+
|
|
26
|
+
export class CesiumCartesian2 extends Cartesian2 {}
|
|
27
|
+
|
|
28
|
+
export class CesiumCartesian3 extends Cartesian3 {}
|
|
29
|
+
|
|
30
|
+
export class CesiumCartographic extends Cartographic {}
|
|
31
|
+
|
|
32
|
+
export class CesiumBoundingSphere extends BoundingSphere {}
|
|
33
|
+
|
|
34
|
+
export class CesiumEllipsoid extends Ellipsoid {}
|
|
35
|
+
|
|
36
|
+
export class CesiumGeographicTilingScheme extends GeographicTilingScheme {}
|
|
37
|
+
|
|
38
|
+
export class CesiumRectangle extends Rectangle {}
|
|
39
|
+
|
|
40
|
+
export class CesiumResource extends Resource {}
|
|
41
|
+
|
|
42
|
+
export class CesiumEllipsoidTerrainProvider extends EllipsoidTerrainProvider {}
|
|
43
|
+
|
|
44
|
+
export class CesiumCesiumTerrainProvider extends CesiumTerrainProvider {}
|
|
45
|
+
|
|
46
|
+
// PROXIED ENUMS
|
|
47
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
48
|
+
export const CesiumVerticalOrigin = VerticalOrigin;
|
|
49
|
+
|
|
50
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
51
|
+
export const CesiumLabelStyle = LabelStyle;
|
|
52
|
+
|
|
53
|
+
// PROXIED FUNCTIONS
|
|
54
|
+
export { sampleTerrainMostDetailed as cesiumSampleTerrainMostDetailed } from 'cesium';
|
|
@@ -1,37 +1,37 @@
|
|
|
1
|
-
.mapSelector {
|
|
2
|
-
width: 260px;
|
|
3
|
-
list-style: none;
|
|
4
|
-
padding-left: 0;
|
|
5
|
-
display: flex;
|
|
6
|
-
flex-wrap: wrap;
|
|
7
|
-
grid-gap: 4px;
|
|
8
|
-
min-height: 140px;
|
|
9
|
-
margin-block-start: 0px;
|
|
10
|
-
padding-inline-start: 0px;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
.mapContainer {
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.mapContainerSelected {
|
|
17
|
-
border: blueviolet 2px solid !important;
|
|
18
|
-
border-radius: 2px;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
.mapContainer:hover {
|
|
22
|
-
border: tomato 2px solid;
|
|
23
|
-
border-radius: 2px;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
.mapContainerImg {
|
|
27
|
-
width: 100%;
|
|
28
|
-
height: 100%;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
.mapLabel {
|
|
32
|
-
font-size: 12px;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
.mapLabel::before {
|
|
36
|
-
content: '\00a0';
|
|
37
|
-
}
|
|
1
|
+
.mapSelector {
|
|
2
|
+
width: 260px;
|
|
3
|
+
list-style: none;
|
|
4
|
+
padding-left: 0;
|
|
5
|
+
display: flex;
|
|
6
|
+
flex-wrap: wrap;
|
|
7
|
+
grid-gap: 4px;
|
|
8
|
+
min-height: 140px;
|
|
9
|
+
margin-block-start: 0px;
|
|
10
|
+
padding-inline-start: 0px;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.mapContainer {
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.mapContainerSelected {
|
|
17
|
+
border: blueviolet 2px solid !important;
|
|
18
|
+
border-radius: 2px;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.mapContainer:hover {
|
|
22
|
+
border: tomato 2px solid;
|
|
23
|
+
border-radius: 2px;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.mapContainerImg {
|
|
27
|
+
width: 100%;
|
|
28
|
+
height: 100%;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.mapLabel {
|
|
32
|
+
font-size: 12px;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.mapLabel::before {
|
|
36
|
+
content: '\00a0';
|
|
37
|
+
}
|
|
@@ -1,94 +1,94 @@
|
|
|
1
|
-
import React, { useState, useEffect } from 'react';
|
|
2
|
-
import { createStyles, makeStyles, Theme } from '@material-ui/core/styles';
|
|
3
|
-
import { CesiumViewer, useCesiumMap } from '../map';
|
|
4
|
-
import { IBaseMap, IBaseMaps } from './settings';
|
|
5
|
-
|
|
6
|
-
import './base-maps.css';
|
|
7
|
-
|
|
8
|
-
const useStyle = makeStyles((theme: Theme) =>
|
|
9
|
-
createStyles({
|
|
10
|
-
mapContainer: {
|
|
11
|
-
width: '60px',
|
|
12
|
-
height: '60px',
|
|
13
|
-
border: `${theme.palette.background.paper} 2px solid`,
|
|
14
|
-
},
|
|
15
|
-
})
|
|
16
|
-
);
|
|
17
|
-
|
|
18
|
-
export interface RCesiumBaseMapsProps {
|
|
19
|
-
baseMaps?: IBaseMaps;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
export const CesiumBaseMaps: React.FC<RCesiumBaseMapsProps> = (props) => {
|
|
23
|
-
const mapViewer: CesiumViewer = useCesiumMap();
|
|
24
|
-
const { baseMaps } = props;
|
|
25
|
-
const [currentMap, setCurrentMap] = useState<string>(' ');
|
|
26
|
-
const [selectedBaseMap, setSelectedBaseMap] = useState<
|
|
27
|
-
IBaseMap | undefined
|
|
28
|
-
>();
|
|
29
|
-
const classes = useStyle();
|
|
30
|
-
|
|
31
|
-
useEffect(() => {
|
|
32
|
-
const defaultMap = baseMaps?.maps.find((map: IBaseMap) => map.isCurrent);
|
|
33
|
-
if (defaultMap) {
|
|
34
|
-
setSelectedBaseMap(defaultMap);
|
|
35
|
-
setCurrentMap(defaultMap.title !== undefined ? defaultMap.title : ' ');
|
|
36
|
-
}
|
|
37
|
-
}, [baseMaps]);
|
|
38
|
-
|
|
39
|
-
const handleMapSection = (id: string): void => {
|
|
40
|
-
if (baseMaps) {
|
|
41
|
-
// Remove previous base-map layers
|
|
42
|
-
mapViewer.layersManager?.removeBaseMapLayers();
|
|
43
|
-
|
|
44
|
-
// Change base-map: add base-map layers by zIndex order
|
|
45
|
-
const selectedBaseMap = baseMaps.maps.find(
|
|
46
|
-
(map: IBaseMap) => map.id === id
|
|
47
|
-
);
|
|
48
|
-
if (selectedBaseMap) {
|
|
49
|
-
mapViewer.layersManager?.setBaseMapLayers(selectedBaseMap);
|
|
50
|
-
|
|
51
|
-
setSelectedBaseMap(selectedBaseMap);
|
|
52
|
-
|
|
53
|
-
baseMaps.maps.forEach((map: IBaseMap) => {
|
|
54
|
-
map.isCurrent = selectedBaseMap === map;
|
|
55
|
-
});
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
};
|
|
59
|
-
|
|
60
|
-
return (
|
|
61
|
-
<>
|
|
62
|
-
<label className="mapLabel">{currentMap}</label>
|
|
63
|
-
<ul className="mapSelector">
|
|
64
|
-
{baseMaps?.maps.map((map: IBaseMap) => (
|
|
65
|
-
<li
|
|
66
|
-
className={`mapContainer ${classes.mapContainer} ${
|
|
67
|
-
map === selectedBaseMap ? 'mapContainerSelected' : ''
|
|
68
|
-
}`}
|
|
69
|
-
key={map.id}
|
|
70
|
-
>
|
|
71
|
-
<img
|
|
72
|
-
alt={''}
|
|
73
|
-
className="mapContainerImg"
|
|
74
|
-
src={map.thumbnail}
|
|
75
|
-
onMouseOver={(): void => {
|
|
76
|
-
setCurrentMap(map.title as string);
|
|
77
|
-
}}
|
|
78
|
-
onMouseOut={(): void => {
|
|
79
|
-
setCurrentMap(
|
|
80
|
-
selectedBaseMap?.title !== undefined
|
|
81
|
-
? selectedBaseMap.title
|
|
82
|
-
: ' '
|
|
83
|
-
);
|
|
84
|
-
}}
|
|
85
|
-
onClick={(): void => {
|
|
86
|
-
handleMapSection(map.id);
|
|
87
|
-
}}
|
|
88
|
-
/>
|
|
89
|
-
</li>
|
|
90
|
-
))}
|
|
91
|
-
</ul>
|
|
92
|
-
</>
|
|
93
|
-
);
|
|
94
|
-
};
|
|
1
|
+
import React, { useState, useEffect } from 'react';
|
|
2
|
+
import { createStyles, makeStyles, Theme } from '@material-ui/core/styles';
|
|
3
|
+
import { CesiumViewer, useCesiumMap } from '../map';
|
|
4
|
+
import { IBaseMap, IBaseMaps } from './settings';
|
|
5
|
+
|
|
6
|
+
import './base-maps.css';
|
|
7
|
+
|
|
8
|
+
const useStyle = makeStyles((theme: Theme) =>
|
|
9
|
+
createStyles({
|
|
10
|
+
mapContainer: {
|
|
11
|
+
width: '60px',
|
|
12
|
+
height: '60px',
|
|
13
|
+
border: `${theme.palette.background.paper} 2px solid`,
|
|
14
|
+
},
|
|
15
|
+
})
|
|
16
|
+
);
|
|
17
|
+
|
|
18
|
+
export interface RCesiumBaseMapsProps {
|
|
19
|
+
baseMaps?: IBaseMaps;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export const CesiumBaseMaps: React.FC<RCesiumBaseMapsProps> = (props) => {
|
|
23
|
+
const mapViewer: CesiumViewer = useCesiumMap();
|
|
24
|
+
const { baseMaps } = props;
|
|
25
|
+
const [currentMap, setCurrentMap] = useState<string>(' ');
|
|
26
|
+
const [selectedBaseMap, setSelectedBaseMap] = useState<
|
|
27
|
+
IBaseMap | undefined
|
|
28
|
+
>();
|
|
29
|
+
const classes = useStyle();
|
|
30
|
+
|
|
31
|
+
useEffect(() => {
|
|
32
|
+
const defaultMap = baseMaps?.maps.find((map: IBaseMap) => map.isCurrent);
|
|
33
|
+
if (defaultMap) {
|
|
34
|
+
setSelectedBaseMap(defaultMap);
|
|
35
|
+
setCurrentMap(defaultMap.title !== undefined ? defaultMap.title : ' ');
|
|
36
|
+
}
|
|
37
|
+
}, [baseMaps]);
|
|
38
|
+
|
|
39
|
+
const handleMapSection = (id: string): void => {
|
|
40
|
+
if (baseMaps) {
|
|
41
|
+
// Remove previous base-map layers
|
|
42
|
+
mapViewer.layersManager?.removeBaseMapLayers();
|
|
43
|
+
|
|
44
|
+
// Change base-map: add base-map layers by zIndex order
|
|
45
|
+
const selectedBaseMap = baseMaps.maps.find(
|
|
46
|
+
(map: IBaseMap) => map.id === id
|
|
47
|
+
);
|
|
48
|
+
if (selectedBaseMap) {
|
|
49
|
+
mapViewer.layersManager?.setBaseMapLayers(selectedBaseMap);
|
|
50
|
+
|
|
51
|
+
setSelectedBaseMap(selectedBaseMap);
|
|
52
|
+
|
|
53
|
+
baseMaps.maps.forEach((map: IBaseMap) => {
|
|
54
|
+
map.isCurrent = selectedBaseMap === map;
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
return (
|
|
61
|
+
<>
|
|
62
|
+
<label className="mapLabel">{currentMap}</label>
|
|
63
|
+
<ul className="mapSelector">
|
|
64
|
+
{baseMaps?.maps.map((map: IBaseMap) => (
|
|
65
|
+
<li
|
|
66
|
+
className={`mapContainer ${classes.mapContainer} ${
|
|
67
|
+
map === selectedBaseMap ? 'mapContainerSelected' : ''
|
|
68
|
+
}`}
|
|
69
|
+
key={map.id}
|
|
70
|
+
>
|
|
71
|
+
<img
|
|
72
|
+
alt={''}
|
|
73
|
+
className="mapContainerImg"
|
|
74
|
+
src={map.thumbnail}
|
|
75
|
+
onMouseOver={(): void => {
|
|
76
|
+
setCurrentMap(map.title as string);
|
|
77
|
+
}}
|
|
78
|
+
onMouseOut={(): void => {
|
|
79
|
+
setCurrentMap(
|
|
80
|
+
selectedBaseMap?.title !== undefined
|
|
81
|
+
? selectedBaseMap.title
|
|
82
|
+
: ' '
|
|
83
|
+
);
|
|
84
|
+
}}
|
|
85
|
+
onClick={(): void => {
|
|
86
|
+
handleMapSection(map.id);
|
|
87
|
+
}}
|
|
88
|
+
/>
|
|
89
|
+
</li>
|
|
90
|
+
))}
|
|
91
|
+
</ul>
|
|
92
|
+
</>
|
|
93
|
+
);
|
|
94
|
+
};
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
.mapViewIcon {
|
|
2
|
-
fill: #fff;
|
|
3
|
-
width: 40px;
|
|
4
|
-
height: 40px;
|
|
5
|
-
background: #303336;
|
|
6
|
-
border: 1px solid #444;
|
|
7
|
-
border-radius: 4px;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
.mapViewIcon:hover {
|
|
11
|
-
background: #48b;
|
|
12
|
-
border-color: #aef;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
.mapViewCurrent {
|
|
16
|
-
fill: #aef;
|
|
17
|
-
border: 1px solid #aef;
|
|
18
|
-
border-radius: 4px;
|
|
19
|
-
}
|
|
1
|
+
.mapViewIcon {
|
|
2
|
+
fill: #fff;
|
|
3
|
+
width: 40px;
|
|
4
|
+
height: 40px;
|
|
5
|
+
background: #303336;
|
|
6
|
+
border: 1px solid #444;
|
|
7
|
+
border-radius: 4px;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.mapViewIcon:hover {
|
|
11
|
+
background: #48b;
|
|
12
|
+
border-color: #aef;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.mapViewCurrent {
|
|
16
|
+
fill: #aef;
|
|
17
|
+
border: 1px solid #aef;
|
|
18
|
+
border-radius: 4px;
|
|
19
|
+
}
|
|
@@ -1,100 +1,100 @@
|
|
|
1
|
-
import React, { useState, useEffect } from 'react';
|
|
2
|
-
import { Icon } from '@map-colonies/react-core';
|
|
3
|
-
|
|
4
|
-
import { CesiumSceneMode, CesiumSceneModeEnum } from '../map.types';
|
|
5
|
-
import { CesiumViewer, useCesiumMap } from '../map';
|
|
6
|
-
|
|
7
|
-
import './scene-modes.css';
|
|
8
|
-
|
|
9
|
-
const NOT_FOUND = -1;
|
|
10
|
-
|
|
11
|
-
export interface RCesiumSceneModesProps {
|
|
12
|
-
sceneModes: CesiumSceneModeEnum[];
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
export const CesiumSceneModes: React.FC<RCesiumSceneModesProps> = (props) => {
|
|
16
|
-
const mapViewer: CesiumViewer = useCesiumMap();
|
|
17
|
-
const [currentSceneMode, setCurrentSceneMode] = useState<
|
|
18
|
-
CesiumSceneModeEnum
|
|
19
|
-
>();
|
|
20
|
-
const { sceneModes } = props;
|
|
21
|
-
|
|
22
|
-
const isInMapViews = (sceneMode: CesiumSceneModeEnum): boolean => {
|
|
23
|
-
return sceneModes.findIndex((item) => item === sceneMode) > NOT_FOUND;
|
|
24
|
-
};
|
|
25
|
-
|
|
26
|
-
useEffect(() => {
|
|
27
|
-
setCurrentSceneMode(mapViewer.scene.mode);
|
|
28
|
-
}, []);
|
|
29
|
-
|
|
30
|
-
return (
|
|
31
|
-
<>
|
|
32
|
-
{/* 3D */}
|
|
33
|
-
{isInMapViews(CesiumSceneMode.SCENE3D) && (
|
|
34
|
-
<Icon
|
|
35
|
-
icon={
|
|
36
|
-
<div
|
|
37
|
-
className={`mapViewIcon ${
|
|
38
|
-
currentSceneMode === CesiumSceneMode.SCENE3D
|
|
39
|
-
? 'mapViewCurrent'
|
|
40
|
-
: ''
|
|
41
|
-
}`}
|
|
42
|
-
>
|
|
43
|
-
<svg width="100%" height="100%" viewBox="0 0 64 64">
|
|
44
|
-
<path d="m 32.401392,4.9330437 c -7.087603,0 -14.096095,2.884602 -19.10793,7.8946843 -5.0118352,5.010083 -7.9296167,11.987468 -7.9296167,19.072999 0,7.085531 2.9177815,14.097848 7.9296167,19.107931 4.837653,4.835961 11.541408,7.631372 18.374354,7.82482 0.05712,0.01231 0.454119,0.139729 0.454119,0.139729 l 0.03493,-0.104797 c 0.08246,7.84e-4 0.162033,0.03493 0.244525,0.03493 0.08304,0 0.161515,-0.03414 0.244526,-0.03493 l 0.03493,0.104797 c 0,0 0.309474,-0.129487 0.349323,-0.139729 6.867765,-0.168094 13.582903,-2.965206 18.444218,-7.82482 2.558195,-2.5573 4.551081,-5.638134 5.903547,-8.977584 1.297191,-3.202966 2.02607,-6.661489 2.02607,-10.130347 0,-6.237309 -2.366261,-12.31219 -6.322734,-17.116794 -0.0034,-0.02316 0.0049,-0.04488 0,-0.06986 -0.01733,-0.08745 -0.104529,-0.278855 -0.104797,-0.279458 -5.31e-4,-0.0012 -0.522988,-0.628147 -0.523984,-0.62878 -3.47e-4,-2.2e-4 -0.133444,-0.03532 -0.244525,-0.06987 C 51.944299,13.447603 51.751076,13.104317 51.474391,12.827728 46.462556,7.8176457 39.488996,4.9330437 32.401392,4.9330437 z m -2.130866,3.5281554 0.104797,9.6762289 c -4.111695,-0.08361 -7.109829,-0.423664 -9.257041,-0.943171 1.198093,-2.269271 2.524531,-4.124404 3.91241,-5.414496 2.167498,-2.0147811 3.950145,-2.8540169 5.239834,-3.3185619 z m 2.794579,0 c 1.280302,0.4754953 3.022186,1.3285948 5.065173,3.2486979 1.424667,1.338973 2.788862,3.303645 3.982275,5.728886 -2.29082,0.403367 -5.381258,0.621049 -8.942651,0.698645 L 33.065105,8.4611991 z m 5.728886,0.2445256 c 4.004072,1.1230822 7.793098,3.1481363 10.724195,6.0782083 0.03468,0.03466 0.07033,0.06991 0.104797,0.104797 -0.45375,0.313891 -0.923054,0.663002 -1.956205,1.082899 -0.647388,0.263114 -1.906242,0.477396 -2.829511,0.733577 -1.382296,-2.988132 -3.027146,-5.368585 -4.785716,-7.0213781 -0.422866,-0.397432 -0.835818,-0.6453247 -1.25756,-0.9781032 z m -15.33525,0.7685092 c -0.106753,0.09503 -0.207753,0.145402 -0.31439,0.244526 -1.684973,1.5662541 -3.298068,3.8232211 -4.680919,6.5672591 -0.343797,-0.14942 -1.035052,-0.273198 -1.292493,-0.419186 -0.956528,-0.542427 -1.362964,-1.022024 -1.537018,-1.292493 -0.0241,-0.03745 -0.01868,-0.0401 -0.03493,-0.06986 2.250095,-2.163342 4.948824,-3.869984 7.859752,-5.0302421 z m -9.641296,7.0912431 c 0.464973,0.571618 0.937729,1.169056 1.956205,1.746612 0.349907,0.198425 1.107143,0.335404 1.537018,0.523983 -1.20166,3.172984 -1.998037,7.051901 -2.165798,11.772162 C 14.256557,30.361384 12.934823,30.161483 12.280427,29.90959 10.644437,29.279855 9.6888882,28.674891 9.1714586,28.267775 8.6540289,27.860658 8.6474751,27.778724 8.6474751,27.778724 l -0.069864,0.03493 C 9.3100294,23.691285 11.163248,19.798527 13.817445,16.565477 z m 37.552149,0.523984 c 2.548924,3.289983 4.265057,7.202594 4.890513,11.318043 -0.650428,0.410896 -1.756876,1.001936 -3.563088,1.606882 -1.171552,0.392383 -3.163859,0.759153 -4.960377,1.117832 -0.04367,-4.752703 -0.784809,-8.591423 -1.88634,-11.807094 0.917574,-0.263678 2.170552,-0.486495 2.864443,-0.76851 1.274693,-0.518066 2.003942,-1.001558 2.654849,-1.467153 z m -31.439008,2.619917 c 2.487341,0.672766 5.775813,1.137775 10.479669,1.222628 l 0.104797,10.689263 0,0.03493 0,0.733577 c -5.435005,-0.09059 -9.512219,-0.519044 -12.610536,-1.117831 0.106127,-4.776683 0.879334,-8.55791 2.02607,-11.562569 z m 23.264866,0.31439 c 1.073459,3.067541 1.833795,6.821314 1.816476,11.702298 -3.054474,0.423245 -7.062018,0.648559 -11.702298,0.698644 l 0,-0.838373 -0.104796,-10.654331 c 4.082416,-0.0864 7.404468,-0.403886 9.990618,-0.908238 z M 8.2632205,30.922625 c 0.7558676,0.510548 1.5529563,1.013339 3.0041715,1.57195 0.937518,0.360875 2.612202,0.647642 3.91241,0.978102 0.112814,3.85566 0.703989,7.107756 1.606883,9.920754 -1.147172,-0.324262 -2.644553,-0.640648 -3.423359,-0.978102 -1.516688,-0.657177 -2.386627,-1.287332 -2.864443,-1.71168 -0.477816,-0.424347 -0.489051,-0.489051 -0.489051,-0.489051 L 9.8002387,40.319395 C 8.791691,37.621767 8.1584238,34.769583 8.1584238,31.900727 c 0,-0.330153 0.090589,-0.648169 0.1047967,-0.978102 z m 48.2763445,0.419186 c 0.0047,0.188973 0.06986,0.36991 0.06986,0.558916 0,2.938869 -0.620228,5.873558 -1.676747,8.628261 -0.07435,0.07583 -0.06552,0.07411 -0.454119,0.349323 -0.606965,0.429857 -1.631665,1.042044 -3.318562,1.676747 -1.208528,0.454713 -3.204964,0.850894 -5.135038,1.25756 0.84593,-2.765726 1.41808,-6.005357 1.606883,-9.815957 2.232369,-0.413371 4.483758,-0.840201 5.938479,-1.327425 1.410632,-0.472457 2.153108,-0.89469 2.96924,-1.327425 z m -38.530252,2.864443 c 3.208141,0.56697 7.372279,0.898588 12.575603,0.978103 l 0.174662,9.885821 c -4.392517,-0.06139 -8.106722,-0.320566 -10.863925,-0.803441 -1.051954,-2.664695 -1.692909,-6.043794 -1.88634,-10.060483 z m 26.793022,0.31439 c -0.246298,3.923551 -0.877762,7.263679 -1.816476,9.885822 -2.561957,0.361954 -5.766249,0.560708 -9.431703,0.62878 l -0.174661,-9.815957 c 4.491734,-0.04969 8.334769,-0.293032 11.42284,-0.698645 z M 12.035901,44.860585 c 0.09977,0.04523 0.105535,0.09465 0.209594,0.139729 1.337656,0.579602 3.441099,1.058072 5.589157,1.537018 1.545042,3.399208 3.548524,5.969402 5.589157,7.789888 -3.034411,-1.215537 -5.871615,-3.007978 -8.174142,-5.309699 -1.245911,-1.245475 -2.271794,-2.662961 -3.213766,-4.156936 z m 40.69605,0 c -0.941972,1.493975 -1.967855,2.911461 -3.213765,4.156936 -2.74253,2.741571 -6.244106,4.696717 -9.955686,5.868615 0.261347,-0.241079 0.507495,-0.394491 0.768509,-0.663713 1.674841,-1.727516 3.320792,-4.181056 4.645987,-7.265904 2.962447,-0.503021 5.408965,-1.122293 7.161107,-1.781544 0.284034,-0.106865 0.337297,-0.207323 0.593848,-0.31439 z m -31.404076,2.305527 c 2.645807,0.376448 5.701178,0.649995 9.466635,0.698645 l 0.139729,7.789888 c -1.38739,-0.480844 -3.316218,-1.29837 -5.659022,-3.388427 -1.388822,-1.238993 -2.743668,-3.0113 -3.947342,-5.100106 z m 20.365491,0.104797 c -1.04872,2.041937 -2.174337,3.779068 -3.353494,4.995309 -1.853177,1.911459 -3.425515,2.82679 -4.611055,3.353494 l -0.139729,-7.789887 c 3.13091,-0.05714 5.728238,-0.278725 8.104278,-0.558916 z"></path>
|
|
45
|
-
</svg>
|
|
46
|
-
</div>
|
|
47
|
-
}
|
|
48
|
-
onClick={(): void => {
|
|
49
|
-
mapViewer.scene.morphTo3D();
|
|
50
|
-
setCurrentSceneMode(CesiumSceneMode.SCENE3D);
|
|
51
|
-
}}
|
|
52
|
-
/>
|
|
53
|
-
)}
|
|
54
|
-
{/* 2D */}
|
|
55
|
-
{isInMapViews(CesiumSceneMode.SCENE2D) && (
|
|
56
|
-
<Icon
|
|
57
|
-
icon={
|
|
58
|
-
<div
|
|
59
|
-
className={`mapViewIcon ${
|
|
60
|
-
currentSceneMode === CesiumSceneMode.SCENE2D
|
|
61
|
-
? 'mapViewCurrent'
|
|
62
|
-
: ''
|
|
63
|
-
}`}
|
|
64
|
-
>
|
|
65
|
-
<svg width="100%" height="100%" viewBox="0 0 64 64">
|
|
66
|
-
<path d="m 2.9825053,17.550598 0,1.368113 0,26.267766 0,1.368113 1.36811,0 54.9981397,0 1.36811,0 0,-1.368113 0,-26.267766 0,-1.368113 -1.36811,0 -54.9981397,0 -1.36811,0 z m 2.73623,2.736226 10.3292497,0 0,10.466063 -10.3292497,0 0,-10.466063 z m 13.0654697,0 11.69737,0 0,10.466063 -11.69737,0 0,-10.466063 z m 14.43359,0 11.69737,0 0,10.466063 -11.69737,0 0,-10.466063 z m 14.43359,0 10.32926,0 0,10.466063 -10.32926,0 0,-10.466063 z m -41.9326497,13.202288 10.3292497,0 0,10.329252 -10.3292497,0 0,-10.329252 z m 13.0654697,0 11.69737,0 0,10.329252 -11.69737,0 0,-10.329252 z m 14.43359,0 11.69737,0 0,10.329252 -11.69737,0 0,-10.329252 z m 14.43359,0 10.32926,0 0,10.329252 -10.32926,0 0,-10.329252 z"></path>
|
|
67
|
-
</svg>
|
|
68
|
-
</div>
|
|
69
|
-
}
|
|
70
|
-
onClick={(): void => {
|
|
71
|
-
mapViewer.scene.morphTo2D();
|
|
72
|
-
setCurrentSceneMode(CesiumSceneMode.SCENE2D);
|
|
73
|
-
}}
|
|
74
|
-
/>
|
|
75
|
-
)}
|
|
76
|
-
{/* 2.5D COLOMBUS */}
|
|
77
|
-
{isInMapViews(CesiumSceneMode.COLUMBUS_VIEW) && (
|
|
78
|
-
<Icon
|
|
79
|
-
icon={
|
|
80
|
-
<div
|
|
81
|
-
className={`mapViewIcon ${
|
|
82
|
-
currentSceneMode === CesiumSceneMode.COLUMBUS_VIEW
|
|
83
|
-
? 'mapViewCurrent'
|
|
84
|
-
: ''
|
|
85
|
-
}`}
|
|
86
|
-
>
|
|
87
|
-
<svg width="100%" height="100%" viewBox="0 0 64 64">
|
|
88
|
-
<path d="m 14.723969,17.675598 -0.340489,0.817175 -11.1680536,26.183638 -0.817175,1.872692 2.076986,0 54.7506996,0 2.07698,0 -0.81717,-1.872692 -11.16805,-26.183638 -0.34049,-0.817175 -0.91933,0 -32.414586,0 -0.919322,0 z m 1.838643,2.723916 6.196908,0 -2.928209,10.418977 -7.729111,0 4.460412,-10.418977 z m 9.02297,0 4.903049,0 0,10.418977 -7.831258,0 2.928209,-10.418977 z m 7.626964,0 5.584031,0 2.62176,10.418977 -8.205791,0 0,-10.418977 z m 8.410081,0 5.51593,0 4.46042,10.418977 -7.38863,0 -2.58772,-10.418977 z m -30.678091,13.142892 8.103649,0 -2.89416,10.282782 -9.6018026,0 4.3923136,-10.282782 z m 10.929711,0 8.614384,0 0,10.282782 -11.508544,0 2.89416,-10.282782 z m 11.338299,0 8.852721,0 2.58772,10.282782 -11.440441,0 0,-10.282782 z m 11.678781,0 7.86531,0 4.39231,10.282782 -9.6699,0 -2.58772,-10.282782 z"></path>
|
|
89
|
-
</svg>
|
|
90
|
-
</div>
|
|
91
|
-
}
|
|
92
|
-
onClick={(): void => {
|
|
93
|
-
mapViewer.scene.morphToColumbusView();
|
|
94
|
-
setCurrentSceneMode(CesiumSceneMode.COLUMBUS_VIEW);
|
|
95
|
-
}}
|
|
96
|
-
/>
|
|
97
|
-
)}
|
|
98
|
-
</>
|
|
99
|
-
);
|
|
100
|
-
};
|
|
1
|
+
import React, { useState, useEffect } from 'react';
|
|
2
|
+
import { Icon } from '@map-colonies/react-core';
|
|
3
|
+
|
|
4
|
+
import { CesiumSceneMode, CesiumSceneModeEnum } from '../map.types';
|
|
5
|
+
import { CesiumViewer, useCesiumMap } from '../map';
|
|
6
|
+
|
|
7
|
+
import './scene-modes.css';
|
|
8
|
+
|
|
9
|
+
const NOT_FOUND = -1;
|
|
10
|
+
|
|
11
|
+
export interface RCesiumSceneModesProps {
|
|
12
|
+
sceneModes: CesiumSceneModeEnum[];
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export const CesiumSceneModes: React.FC<RCesiumSceneModesProps> = (props) => {
|
|
16
|
+
const mapViewer: CesiumViewer = useCesiumMap();
|
|
17
|
+
const [currentSceneMode, setCurrentSceneMode] = useState<
|
|
18
|
+
CesiumSceneModeEnum
|
|
19
|
+
>();
|
|
20
|
+
const { sceneModes } = props;
|
|
21
|
+
|
|
22
|
+
const isInMapViews = (sceneMode: CesiumSceneModeEnum): boolean => {
|
|
23
|
+
return sceneModes.findIndex((item) => item === sceneMode) > NOT_FOUND;
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
useEffect(() => {
|
|
27
|
+
setCurrentSceneMode(mapViewer.scene.mode);
|
|
28
|
+
}, []);
|
|
29
|
+
|
|
30
|
+
return (
|
|
31
|
+
<>
|
|
32
|
+
{/* 3D */}
|
|
33
|
+
{isInMapViews(CesiumSceneMode.SCENE3D) && (
|
|
34
|
+
<Icon
|
|
35
|
+
icon={
|
|
36
|
+
<div
|
|
37
|
+
className={`mapViewIcon ${
|
|
38
|
+
currentSceneMode === CesiumSceneMode.SCENE3D
|
|
39
|
+
? 'mapViewCurrent'
|
|
40
|
+
: ''
|
|
41
|
+
}`}
|
|
42
|
+
>
|
|
43
|
+
<svg width="100%" height="100%" viewBox="0 0 64 64">
|
|
44
|
+
<path d="m 32.401392,4.9330437 c -7.087603,0 -14.096095,2.884602 -19.10793,7.8946843 -5.0118352,5.010083 -7.9296167,11.987468 -7.9296167,19.072999 0,7.085531 2.9177815,14.097848 7.9296167,19.107931 4.837653,4.835961 11.541408,7.631372 18.374354,7.82482 0.05712,0.01231 0.454119,0.139729 0.454119,0.139729 l 0.03493,-0.104797 c 0.08246,7.84e-4 0.162033,0.03493 0.244525,0.03493 0.08304,0 0.161515,-0.03414 0.244526,-0.03493 l 0.03493,0.104797 c 0,0 0.309474,-0.129487 0.349323,-0.139729 6.867765,-0.168094 13.582903,-2.965206 18.444218,-7.82482 2.558195,-2.5573 4.551081,-5.638134 5.903547,-8.977584 1.297191,-3.202966 2.02607,-6.661489 2.02607,-10.130347 0,-6.237309 -2.366261,-12.31219 -6.322734,-17.116794 -0.0034,-0.02316 0.0049,-0.04488 0,-0.06986 -0.01733,-0.08745 -0.104529,-0.278855 -0.104797,-0.279458 -5.31e-4,-0.0012 -0.522988,-0.628147 -0.523984,-0.62878 -3.47e-4,-2.2e-4 -0.133444,-0.03532 -0.244525,-0.06987 C 51.944299,13.447603 51.751076,13.104317 51.474391,12.827728 46.462556,7.8176457 39.488996,4.9330437 32.401392,4.9330437 z m -2.130866,3.5281554 0.104797,9.6762289 c -4.111695,-0.08361 -7.109829,-0.423664 -9.257041,-0.943171 1.198093,-2.269271 2.524531,-4.124404 3.91241,-5.414496 2.167498,-2.0147811 3.950145,-2.8540169 5.239834,-3.3185619 z m 2.794579,0 c 1.280302,0.4754953 3.022186,1.3285948 5.065173,3.2486979 1.424667,1.338973 2.788862,3.303645 3.982275,5.728886 -2.29082,0.403367 -5.381258,0.621049 -8.942651,0.698645 L 33.065105,8.4611991 z m 5.728886,0.2445256 c 4.004072,1.1230822 7.793098,3.1481363 10.724195,6.0782083 0.03468,0.03466 0.07033,0.06991 0.104797,0.104797 -0.45375,0.313891 -0.923054,0.663002 -1.956205,1.082899 -0.647388,0.263114 -1.906242,0.477396 -2.829511,0.733577 -1.382296,-2.988132 -3.027146,-5.368585 -4.785716,-7.0213781 -0.422866,-0.397432 -0.835818,-0.6453247 -1.25756,-0.9781032 z m -15.33525,0.7685092 c -0.106753,0.09503 -0.207753,0.145402 -0.31439,0.244526 -1.684973,1.5662541 -3.298068,3.8232211 -4.680919,6.5672591 -0.343797,-0.14942 -1.035052,-0.273198 -1.292493,-0.419186 -0.956528,-0.542427 -1.362964,-1.022024 -1.537018,-1.292493 -0.0241,-0.03745 -0.01868,-0.0401 -0.03493,-0.06986 2.250095,-2.163342 4.948824,-3.869984 7.859752,-5.0302421 z m -9.641296,7.0912431 c 0.464973,0.571618 0.937729,1.169056 1.956205,1.746612 0.349907,0.198425 1.107143,0.335404 1.537018,0.523983 -1.20166,3.172984 -1.998037,7.051901 -2.165798,11.772162 C 14.256557,30.361384 12.934823,30.161483 12.280427,29.90959 10.644437,29.279855 9.6888882,28.674891 9.1714586,28.267775 8.6540289,27.860658 8.6474751,27.778724 8.6474751,27.778724 l -0.069864,0.03493 C 9.3100294,23.691285 11.163248,19.798527 13.817445,16.565477 z m 37.552149,0.523984 c 2.548924,3.289983 4.265057,7.202594 4.890513,11.318043 -0.650428,0.410896 -1.756876,1.001936 -3.563088,1.606882 -1.171552,0.392383 -3.163859,0.759153 -4.960377,1.117832 -0.04367,-4.752703 -0.784809,-8.591423 -1.88634,-11.807094 0.917574,-0.263678 2.170552,-0.486495 2.864443,-0.76851 1.274693,-0.518066 2.003942,-1.001558 2.654849,-1.467153 z m -31.439008,2.619917 c 2.487341,0.672766 5.775813,1.137775 10.479669,1.222628 l 0.104797,10.689263 0,0.03493 0,0.733577 c -5.435005,-0.09059 -9.512219,-0.519044 -12.610536,-1.117831 0.106127,-4.776683 0.879334,-8.55791 2.02607,-11.562569 z m 23.264866,0.31439 c 1.073459,3.067541 1.833795,6.821314 1.816476,11.702298 -3.054474,0.423245 -7.062018,0.648559 -11.702298,0.698644 l 0,-0.838373 -0.104796,-10.654331 c 4.082416,-0.0864 7.404468,-0.403886 9.990618,-0.908238 z M 8.2632205,30.922625 c 0.7558676,0.510548 1.5529563,1.013339 3.0041715,1.57195 0.937518,0.360875 2.612202,0.647642 3.91241,0.978102 0.112814,3.85566 0.703989,7.107756 1.606883,9.920754 -1.147172,-0.324262 -2.644553,-0.640648 -3.423359,-0.978102 -1.516688,-0.657177 -2.386627,-1.287332 -2.864443,-1.71168 -0.477816,-0.424347 -0.489051,-0.489051 -0.489051,-0.489051 L 9.8002387,40.319395 C 8.791691,37.621767 8.1584238,34.769583 8.1584238,31.900727 c 0,-0.330153 0.090589,-0.648169 0.1047967,-0.978102 z m 48.2763445,0.419186 c 0.0047,0.188973 0.06986,0.36991 0.06986,0.558916 0,2.938869 -0.620228,5.873558 -1.676747,8.628261 -0.07435,0.07583 -0.06552,0.07411 -0.454119,0.349323 -0.606965,0.429857 -1.631665,1.042044 -3.318562,1.676747 -1.208528,0.454713 -3.204964,0.850894 -5.135038,1.25756 0.84593,-2.765726 1.41808,-6.005357 1.606883,-9.815957 2.232369,-0.413371 4.483758,-0.840201 5.938479,-1.327425 1.410632,-0.472457 2.153108,-0.89469 2.96924,-1.327425 z m -38.530252,2.864443 c 3.208141,0.56697 7.372279,0.898588 12.575603,0.978103 l 0.174662,9.885821 c -4.392517,-0.06139 -8.106722,-0.320566 -10.863925,-0.803441 -1.051954,-2.664695 -1.692909,-6.043794 -1.88634,-10.060483 z m 26.793022,0.31439 c -0.246298,3.923551 -0.877762,7.263679 -1.816476,9.885822 -2.561957,0.361954 -5.766249,0.560708 -9.431703,0.62878 l -0.174661,-9.815957 c 4.491734,-0.04969 8.334769,-0.293032 11.42284,-0.698645 z M 12.035901,44.860585 c 0.09977,0.04523 0.105535,0.09465 0.209594,0.139729 1.337656,0.579602 3.441099,1.058072 5.589157,1.537018 1.545042,3.399208 3.548524,5.969402 5.589157,7.789888 -3.034411,-1.215537 -5.871615,-3.007978 -8.174142,-5.309699 -1.245911,-1.245475 -2.271794,-2.662961 -3.213766,-4.156936 z m 40.69605,0 c -0.941972,1.493975 -1.967855,2.911461 -3.213765,4.156936 -2.74253,2.741571 -6.244106,4.696717 -9.955686,5.868615 0.261347,-0.241079 0.507495,-0.394491 0.768509,-0.663713 1.674841,-1.727516 3.320792,-4.181056 4.645987,-7.265904 2.962447,-0.503021 5.408965,-1.122293 7.161107,-1.781544 0.284034,-0.106865 0.337297,-0.207323 0.593848,-0.31439 z m -31.404076,2.305527 c 2.645807,0.376448 5.701178,0.649995 9.466635,0.698645 l 0.139729,7.789888 c -1.38739,-0.480844 -3.316218,-1.29837 -5.659022,-3.388427 -1.388822,-1.238993 -2.743668,-3.0113 -3.947342,-5.100106 z m 20.365491,0.104797 c -1.04872,2.041937 -2.174337,3.779068 -3.353494,4.995309 -1.853177,1.911459 -3.425515,2.82679 -4.611055,3.353494 l -0.139729,-7.789887 c 3.13091,-0.05714 5.728238,-0.278725 8.104278,-0.558916 z"></path>
|
|
45
|
+
</svg>
|
|
46
|
+
</div>
|
|
47
|
+
}
|
|
48
|
+
onClick={(): void => {
|
|
49
|
+
mapViewer.scene.morphTo3D();
|
|
50
|
+
setCurrentSceneMode(CesiumSceneMode.SCENE3D);
|
|
51
|
+
}}
|
|
52
|
+
/>
|
|
53
|
+
)}
|
|
54
|
+
{/* 2D */}
|
|
55
|
+
{isInMapViews(CesiumSceneMode.SCENE2D) && (
|
|
56
|
+
<Icon
|
|
57
|
+
icon={
|
|
58
|
+
<div
|
|
59
|
+
className={`mapViewIcon ${
|
|
60
|
+
currentSceneMode === CesiumSceneMode.SCENE2D
|
|
61
|
+
? 'mapViewCurrent'
|
|
62
|
+
: ''
|
|
63
|
+
}`}
|
|
64
|
+
>
|
|
65
|
+
<svg width="100%" height="100%" viewBox="0 0 64 64">
|
|
66
|
+
<path d="m 2.9825053,17.550598 0,1.368113 0,26.267766 0,1.368113 1.36811,0 54.9981397,0 1.36811,0 0,-1.368113 0,-26.267766 0,-1.368113 -1.36811,0 -54.9981397,0 -1.36811,0 z m 2.73623,2.736226 10.3292497,0 0,10.466063 -10.3292497,0 0,-10.466063 z m 13.0654697,0 11.69737,0 0,10.466063 -11.69737,0 0,-10.466063 z m 14.43359,0 11.69737,0 0,10.466063 -11.69737,0 0,-10.466063 z m 14.43359,0 10.32926,0 0,10.466063 -10.32926,0 0,-10.466063 z m -41.9326497,13.202288 10.3292497,0 0,10.329252 -10.3292497,0 0,-10.329252 z m 13.0654697,0 11.69737,0 0,10.329252 -11.69737,0 0,-10.329252 z m 14.43359,0 11.69737,0 0,10.329252 -11.69737,0 0,-10.329252 z m 14.43359,0 10.32926,0 0,10.329252 -10.32926,0 0,-10.329252 z"></path>
|
|
67
|
+
</svg>
|
|
68
|
+
</div>
|
|
69
|
+
}
|
|
70
|
+
onClick={(): void => {
|
|
71
|
+
mapViewer.scene.morphTo2D();
|
|
72
|
+
setCurrentSceneMode(CesiumSceneMode.SCENE2D);
|
|
73
|
+
}}
|
|
74
|
+
/>
|
|
75
|
+
)}
|
|
76
|
+
{/* 2.5D COLOMBUS */}
|
|
77
|
+
{isInMapViews(CesiumSceneMode.COLUMBUS_VIEW) && (
|
|
78
|
+
<Icon
|
|
79
|
+
icon={
|
|
80
|
+
<div
|
|
81
|
+
className={`mapViewIcon ${
|
|
82
|
+
currentSceneMode === CesiumSceneMode.COLUMBUS_VIEW
|
|
83
|
+
? 'mapViewCurrent'
|
|
84
|
+
: ''
|
|
85
|
+
}`}
|
|
86
|
+
>
|
|
87
|
+
<svg width="100%" height="100%" viewBox="0 0 64 64">
|
|
88
|
+
<path d="m 14.723969,17.675598 -0.340489,0.817175 -11.1680536,26.183638 -0.817175,1.872692 2.076986,0 54.7506996,0 2.07698,0 -0.81717,-1.872692 -11.16805,-26.183638 -0.34049,-0.817175 -0.91933,0 -32.414586,0 -0.919322,0 z m 1.838643,2.723916 6.196908,0 -2.928209,10.418977 -7.729111,0 4.460412,-10.418977 z m 9.02297,0 4.903049,0 0,10.418977 -7.831258,0 2.928209,-10.418977 z m 7.626964,0 5.584031,0 2.62176,10.418977 -8.205791,0 0,-10.418977 z m 8.410081,0 5.51593,0 4.46042,10.418977 -7.38863,0 -2.58772,-10.418977 z m -30.678091,13.142892 8.103649,0 -2.89416,10.282782 -9.6018026,0 4.3923136,-10.282782 z m 10.929711,0 8.614384,0 0,10.282782 -11.508544,0 2.89416,-10.282782 z m 11.338299,0 8.852721,0 2.58772,10.282782 -11.440441,0 0,-10.282782 z m 11.678781,0 7.86531,0 4.39231,10.282782 -9.6699,0 -2.58772,-10.282782 z"></path>
|
|
89
|
+
</svg>
|
|
90
|
+
</div>
|
|
91
|
+
}
|
|
92
|
+
onClick={(): void => {
|
|
93
|
+
mapViewer.scene.morphToColumbusView();
|
|
94
|
+
setCurrentSceneMode(CesiumSceneMode.COLUMBUS_VIEW);
|
|
95
|
+
}}
|
|
96
|
+
/>
|
|
97
|
+
)}
|
|
98
|
+
</>
|
|
99
|
+
);
|
|
100
|
+
};
|