@rio-cloud/rio-uikit 1.0.0 → 1.2.0
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/.DS_Store +0 -0
- package/DropdownHeader.d.ts +2 -0
- package/DropdownHeader.js +2 -0
- package/FeedbackInlineButtons.d.ts +2 -0
- package/FeedbackInlineButtons.js +2 -0
- package/FeedbackRating.d.ts +2 -0
- package/FeedbackRating.js +2 -0
- package/FeedbackReactions.d.ts +2 -0
- package/FeedbackReactions.js +2 -0
- package/MapAdditionalLayerSettings.d.ts +2 -0
- package/MapAdditionalLayerSettings.js +2 -0
- package/MapSettingsDropdownHeader.d.ts +2 -0
- package/MapSettingsDropdownHeader.js +2 -0
- package/SmoothScrollbars.d.ts +2 -0
- package/SmoothScrollbars.js +2 -0
- package/components/.DS_Store +0 -0
- package/components/actionBarItem/ActionBarItemListItem.js +2 -2
- package/components/assetTree/AssetTree.js +2 -1
- package/components/assetTree/Tree.d.ts +4 -0
- package/components/assetTree/Tree.js +2 -2
- package/components/assetTree/TreeOptions.d.ts +1 -0
- package/components/assetTree/TreeOptions.js +16 -2
- package/components/assetTree/TreeSidebarCategories.js +1 -1
- package/components/calendarStripe/CalendarStripe.js +2 -2
- package/components/feedback/FeedbackInlineButtons.d.ts +13 -0
- package/components/feedback/FeedbackInlineButtons.js +9 -0
- package/components/feedback/FeedbackRating.d.ts +65 -0
- package/components/feedback/FeedbackRating.js +23 -0
- package/components/feedback/FeedbackReactions.d.ts +71 -0
- package/components/feedback/FeedbackReactions.js +26 -0
- package/components/listMenu/ListMenu.d.ts +5 -1
- package/components/listMenu/ListMenu.js +2 -2
- package/components/map/.DS_Store +0 -0
- package/components/map/components/.DS_Store +0 -0
- package/components/map/components/features/basics/Marker.js +1 -1
- package/components/map/components/features/settings/MapSettingsItem.d.ts +1 -0
- package/components/map/components/features/settings/MapSettingsItem.js +14 -11
- package/components/map/components/features/settings/MapSettingsTile.d.ts +3 -2
- package/components/map/components/features/settings/MapSettingsTile.js +40 -5
- package/components/map/components/features/settings/builtinSettings/MapAdditionalLayerSettings.d.ts +9 -0
- package/components/map/components/features/settings/builtinSettings/MapAdditionalLayerSettings.js +15 -0
- package/components/map/components/features/settings/builtinSettings/MapClusterSettings.d.ts +3 -0
- package/components/map/components/features/settings/builtinSettings/MapClusterSettings.js +8 -2
- package/components/map/components/features/settings/builtinSettings/MapLayerSettings.js +15 -9
- package/components/map/components/features/settings/builtinSettings/MapTypeSettings.d.ts +6 -0
- package/components/map/components/features/settings/builtinSettings/MapTypeSettings.js +20 -2
- package/components/map/components/features/settings/buttons/MapCenterMarkerButton.js +2 -2
- package/components/map/components/features/settings/items/MapCustomerPoiSettingsItem.d.ts +2 -0
- package/components/map/components/features/settings/items/MapLayerIncidentsItem.d.ts +2 -0
- package/components/map/components/features/settings/items/MapLayerRoadRestrictionsItem.d.ts +2 -0
- package/components/map/components/features/settings/items/MapLayerTrafficItem.d.ts +2 -0
- package/components/map/components/features/settings/items/MapSettingsDropdownHeader.d.ts +4 -0
- package/components/map/components/features/settings/items/MapSettingsDropdownHeader.js +9 -0
- package/components/map/components/features/settings/items/MapWorkshopPoiSettingsItem.d.ts +2 -0
- package/components/map/icons/MapIcon.d.ts +1 -2
- package/components/map/icons/MapIcon.js +3 -1
- package/components/map/utils/mapTypes.d.ts +1 -1
- package/components/map/utils/mapTypes.js +12 -4
- package/components/mapMarker/ClusterMapMarker.d.ts +8 -0
- package/components/mapMarker/ClusterMapMarker.js +5 -4
- package/components/mapMarker/SingleMapMarker.d.ts +40 -5
- package/components/mapMarker/SingleMapMarker.js +19 -6
- package/components/selects/DropdownHeader.d.ts +1 -0
- package/components/selects/DropdownHeader.js +2 -2
- package/components/selects/Multiselect.js +2 -2
- package/components/selects/MultiselectToggleFilter.js +1 -1
- package/components/states/CustomState.js +21 -8
- package/components/states/StateButton.d.ts +8 -1
- package/components/states/StateButton.js +5 -4
- package/hooks/useAfterMount.js +8 -4
- package/lib/.DS_Store +0 -0
- package/lib/es/.DS_Store +0 -0
- package/lib/es/DropdownHeader.d.ts +2 -0
- package/lib/es/DropdownHeader.js +7 -0
- package/lib/es/FeedbackInlineButtons.d.ts +2 -0
- package/lib/es/FeedbackInlineButtons.js +7 -0
- package/lib/es/FeedbackRating.d.ts +2 -0
- package/lib/es/FeedbackRating.js +7 -0
- package/lib/es/FeedbackReactions.d.ts +2 -0
- package/lib/es/FeedbackReactions.js +7 -0
- package/lib/es/MapAdditionalLayerSettings.d.ts +2 -0
- package/lib/es/MapAdditionalLayerSettings.js +7 -0
- package/lib/es/MapSettingsDropdownHeader.d.ts +2 -0
- package/lib/es/MapSettingsDropdownHeader.js +7 -0
- package/lib/es/SmoothScrollbars.d.ts +2 -0
- package/lib/es/SmoothScrollbars.js +7 -0
- package/lib/es/components/.DS_Store +0 -0
- package/lib/es/components/actionBarItem/ActionBarItemListItem.js +2 -2
- package/lib/es/components/assetTree/AssetTree.js +2 -1
- package/lib/es/components/assetTree/Tree.d.ts +4 -0
- package/lib/es/components/assetTree/Tree.js +2 -2
- package/lib/es/components/assetTree/TreeOptions.d.ts +1 -0
- package/lib/es/components/assetTree/TreeOptions.js +16 -2
- package/lib/es/components/assetTree/TreeSidebarCategories.js +1 -1
- package/lib/es/components/calendarStripe/CalendarStripe.js +1 -1
- package/lib/es/components/feedback/FeedbackInlineButtons.d.ts +13 -0
- package/lib/es/components/feedback/FeedbackInlineButtons.js +11 -0
- package/lib/es/components/feedback/FeedbackRating.d.ts +65 -0
- package/lib/es/components/feedback/FeedbackRating.js +25 -0
- package/lib/es/components/feedback/FeedbackReactions.d.ts +71 -0
- package/lib/es/components/feedback/FeedbackReactions.js +28 -0
- package/lib/es/components/listMenu/ListMenu.d.ts +5 -1
- package/lib/es/components/listMenu/ListMenu.js +2 -2
- package/lib/es/components/map/components/features/basics/Marker.js +1 -1
- package/lib/es/components/map/components/features/settings/MapSettingsItem.d.ts +1 -0
- package/lib/es/components/map/components/features/settings/MapSettingsItem.js +13 -10
- package/lib/es/components/map/components/features/settings/MapSettingsTile.d.ts +3 -2
- package/lib/es/components/map/components/features/settings/MapSettingsTile.js +39 -4
- package/lib/es/components/map/components/features/settings/builtinSettings/MapAdditionalLayerSettings.d.ts +9 -0
- package/lib/es/components/map/components/features/settings/builtinSettings/MapAdditionalLayerSettings.js +17 -0
- package/lib/es/components/map/components/features/settings/builtinSettings/MapClusterSettings.d.ts +3 -0
- package/lib/es/components/map/components/features/settings/builtinSettings/MapClusterSettings.js +8 -2
- package/lib/es/components/map/components/features/settings/builtinSettings/MapLayerSettings.js +14 -8
- package/lib/es/components/map/components/features/settings/builtinSettings/MapTypeSettings.d.ts +6 -0
- package/lib/es/components/map/components/features/settings/builtinSettings/MapTypeSettings.js +20 -2
- package/lib/es/components/map/components/features/settings/buttons/MapCenterMarkerButton.js +1 -1
- package/lib/es/components/map/components/features/settings/items/MapCustomerPoiSettingsItem.d.ts +2 -0
- package/lib/es/components/map/components/features/settings/items/MapLayerIncidentsItem.d.ts +2 -0
- package/lib/es/components/map/components/features/settings/items/MapLayerRoadRestrictionsItem.d.ts +2 -0
- package/lib/es/components/map/components/features/settings/items/MapLayerTrafficItem.d.ts +2 -0
- package/lib/es/components/map/components/features/settings/items/MapSettingsDropdownHeader.d.ts +4 -0
- package/lib/es/components/map/components/features/settings/items/MapSettingsDropdownHeader.js +11 -0
- package/lib/es/components/map/components/features/settings/items/MapWorkshopPoiSettingsItem.d.ts +2 -0
- package/lib/es/components/map/icons/MapIcon.d.ts +1 -2
- package/lib/es/components/map/icons/MapIcon.js +3 -1
- package/lib/es/components/map/utils/mapTypes.d.ts +1 -1
- package/lib/es/components/map/utils/mapTypes.js +12 -4
- package/lib/es/components/mapMarker/ClusterMapMarker.d.ts +8 -0
- package/lib/es/components/mapMarker/ClusterMapMarker.js +5 -4
- package/lib/es/components/mapMarker/SingleMapMarker.d.ts +40 -5
- package/lib/es/components/mapMarker/SingleMapMarker.js +18 -5
- package/lib/es/components/selects/DropdownHeader.d.ts +1 -0
- package/lib/es/components/selects/DropdownHeader.js +2 -2
- package/lib/es/components/selects/Multiselect.js +1 -1
- package/lib/es/components/selects/MultiselectToggleFilter.js +1 -1
- package/lib/es/components/states/CustomState.js +20 -7
- package/lib/es/components/states/StateButton.d.ts +8 -1
- package/lib/es/components/states/StateButton.js +5 -4
- package/lib/es/hooks/useAfterMount.js +8 -4
- package/lib/es/styles/variables/colors/colors.json +8 -10
- package/lib/es/utils/deviceUtils.d.ts +1 -0
- package/lib/es/utils/deviceUtils.js +3 -1
- package/lib/es/version.json +1 -1
- package/package.json +30 -27
- package/styles/variables/colors/colors.json +8 -10
- package/utils/deviceUtils.d.ts +1 -0
- package/utils/deviceUtils.js +1 -0
- package/version.json +1 -1
- package/BrowserWarning.d.ts +0 -5
- package/BrowserWarning.js +0 -2
- package/DomMarker.d.ts +0 -5
- package/DomMarker.js +0 -2
- package/EnhancedMapEvent.d.ts +0 -11
- package/GroupSelectionUtil.d.ts +0 -2
- package/GroupSelectionUtil.js +0 -2
- package/IncidentsLayer.d.ts +0 -4
- package/IncidentsLayer.js +0 -2
- package/TrafficLayer.d.ts +0 -4
- package/TrafficLayer.js +0 -2
- package/TruckLayer.d.ts +0 -4
- package/TruckLayer.js +0 -2
- package/components/assetTree/excludeFromList.d.ts +0 -1
- package/components/assetTree/excludeFromList.js +0 -1
- package/components/browserWarning/BrowserIcons.d.ts +0 -2
- package/components/browserWarning/BrowserIcons.js +0 -5
- package/components/browserWarning/BrowserWarning.d.ts +0 -15
- package/components/browserWarning/BrowserWarning.js +0 -46
- package/components/browserWarning/BrowserWarningMessageDE.d.ts +0 -4
- package/components/browserWarning/BrowserWarningMessageDE.js +0 -6
- package/components/browserWarning/BrowserWarningMessageEN.d.ts +0 -4
- package/components/browserWarning/BrowserWarningMessageEN.js +0 -6
- package/components/carousel/CarouselCaption.d.ts +0 -13
- package/components/carousel/CarouselCaption.js +0 -18
- package/components/carousel/CarouselItem.d.ts +0 -36
- package/components/carousel/CarouselItem.js +0 -85
- package/components/dialog/baseDialogPropTypes.d.ts +0 -14
- package/components/dialog/baseDialogPropTypes.js +0 -13
- package/components/driverName/DriverName.d.ts +0 -18
- package/components/driverName/DriverName.js +0 -18
- package/components/dropdown/menuItemsPropTypes.d.ts +0 -9
- package/components/dropdown/menuItemsPropTypes.js +0 -8
- package/components/map/components/MapSettingContext.d.ts +0 -15
- package/components/map/components/MapSettingContext.js +0 -5
- package/components/map/components/context.d.ts +0 -2
- package/components/map/components/context.js +0 -3
- package/components/map/components/features/basics/MapLayerGroup.d.ts +0 -23
- package/components/map/components/features/basics/MapLayerGroup.js +0 -45
- package/components/map/components/features/basics/marker/DomMarker.d.ts +0 -33
- package/components/map/components/features/basics/marker/DomMarker.js +0 -55
- package/components/map/components/features/basics/marker/Marker.d.ts +0 -21
- package/components/map/components/features/basics/marker/Marker.js +0 -116
- package/components/map/components/features/basics/marker/TextMarker.d.ts +0 -17
- package/components/map/components/features/basics/marker/TextMarker.js +0 -28
- package/components/map/components/features/layers/IncidentsLayer.d.ts +0 -2
- package/components/map/components/features/layers/IncidentsLayer.js +0 -25
- package/components/map/components/features/layers/Layer.d.ts +0 -15
- package/components/map/components/features/layers/Layer.js +0 -23
- package/components/map/components/features/layers/RoadRestrictionLayer.d.ts +0 -2
- package/components/map/components/features/layers/RoadRestrictionLayer.js +0 -26
- package/components/map/components/features/layers/TrafficLayer.d.ts +0 -2
- package/components/map/components/features/layers/TrafficLayer.js +0 -39
- package/components/map/components/features/layers/baselayers/DefaultRasterLayer.d.ts +0 -2
- package/components/map/components/features/layers/baselayers/DefaultRasterLayer.js +0 -17
- package/components/map/components/features/layers/baselayers/DefaultVectorLayer.d.ts +0 -2
- package/components/map/components/features/layers/baselayers/DefaultVectorLayer.js +0 -14
- package/components/map/components/features/layers/baselayers/FleetStyleLayer.d.ts +0 -2
- package/components/map/components/features/layers/baselayers/FleetStyleLayer.js +0 -15
- package/components/map/components/features/layers/baselayers/NightLayer.d.ts +0 -2
- package/components/map/components/features/layers/baselayers/NightLayer.js +0 -14
- package/components/map/components/features/layers/baselayers/SatelliteLayer.d.ts +0 -2
- package/components/map/components/features/layers/baselayers/SatelliteLayer.js +0 -15
- package/components/map/components/features/layers/baselayers/TerrainLayer.d.ts +0 -2
- package/components/map/components/features/layers/baselayers/TerrainLayer.js +0 -15
- package/components/map/components/features/layers/baselayers/useBaseLayer.d.ts +0 -2
- package/components/map/components/features/layers/baselayers/useBaseLayer.js +0 -47
- package/components/map/components/mapUtils.d.ts +0 -50
- package/components/map/components/mapUtils.js +0 -148
- package/components/map/herePolyfill.d.ts +0 -0
- package/components/map/herePolyfill.js +0 -7
- package/components/map/utils/proptypes.d.ts +0 -47
- package/components/map/utils/proptypes.js +0 -50
- package/components/map/utils/validation.d.ts +0 -2
- package/components/map/utils/validation.js +0 -8
- package/components/mapMarker/MarkerColor.d.ts +0 -3
- package/components/mapMarker/MarkerColor.js +0 -12
- package/components/menuItems/getMenuItems.d.ts +0 -2
- package/components/menuItems/getMenuItems.js +0 -7
- package/components/selects/BaseDropdownMenu.d.ts +0 -83
- package/components/selects/BaseDropdownMenu.js +0 -255
- package/components/selects/WithFeedback.d.ts +0 -27
- package/components/selects/WithFeedback.js +0 -12
- package/components/states/baseStatePropTypes.d.ts +0 -26
- package/components/states/baseStatePropTypes.js +0 -26
- package/components/table/tableSettingsPropTypes.d.ts +0 -8
- package/components/table/tableSettingsPropTypes.js +0 -6
- package/lib/es/BrowserWarning.d.ts +0 -5
- package/lib/es/BrowserWarning.js +0 -6
- package/lib/es/DomMarker.d.ts +0 -5
- package/lib/es/DomMarker.js +0 -6
- package/lib/es/EnhancedMapEvent.d.ts +0 -11
- package/lib/es/GroupSelectionUtil.d.ts +0 -2
- package/lib/es/GroupSelectionUtil.js +0 -5
- package/lib/es/IncidentsLayer.d.ts +0 -4
- package/lib/es/IncidentsLayer.js +0 -6
- package/lib/es/TrafficLayer.d.ts +0 -4
- package/lib/es/TrafficLayer.js +0 -6
- package/lib/es/TruckLayer.d.ts +0 -4
- package/lib/es/TruckLayer.js +0 -6
- package/lib/es/components/assetTree/autoAnimateFrames.d.ts +0 -1
- package/lib/es/components/assetTree/autoAnimateFrames.js +0 -55
- package/lib/es/components/assetTree/excludeFromList.d.ts +0 -1
- package/lib/es/components/assetTree/excludeFromList.js +0 -5
- package/lib/es/components/browserWarning/BrowserIcons.d.ts +0 -2
- package/lib/es/components/browserWarning/BrowserIcons.js +0 -11
- package/lib/es/components/browserWarning/BrowserWarning.d.ts +0 -15
- package/lib/es/components/browserWarning/BrowserWarning.js +0 -49
- package/lib/es/components/browserWarning/BrowserWarningMessageDE.d.ts +0 -4
- package/lib/es/components/browserWarning/BrowserWarningMessageDE.js +0 -9
- package/lib/es/components/browserWarning/BrowserWarningMessageEN.d.ts +0 -4
- package/lib/es/components/browserWarning/BrowserWarningMessageEN.js +0 -9
- package/lib/es/components/carousel/CarouselCaption.d.ts +0 -13
- package/lib/es/components/carousel/CarouselCaption.js +0 -20
- package/lib/es/components/carousel/CarouselItem.d.ts +0 -36
- package/lib/es/components/carousel/CarouselItem.js +0 -87
- package/lib/es/components/charts/Sector.d.ts +0 -0
- package/lib/es/components/charts/Sector.js +0 -1
- package/lib/es/components/dialog/baseDialogPropTypes.d.ts +0 -14
- package/lib/es/components/dialog/baseDialogPropTypes.js +0 -16
- package/lib/es/components/driverName/DriverName.d.ts +0 -18
- package/lib/es/components/driverName/DriverName.js +0 -23
- package/lib/es/components/dropdown/menuItemsPropTypes.d.ts +0 -9
- package/lib/es/components/dropdown/menuItemsPropTypes.js +0 -11
- package/lib/es/components/map/components/MapSettingContext.d.ts +0 -15
- package/lib/es/components/map/components/MapSettingContext.js +0 -8
- package/lib/es/components/map/components/context.d.ts +0 -2
- package/lib/es/components/map/components/context.js +0 -6
- package/lib/es/components/map/components/features/basics/MapLayerGroup.d.ts +0 -23
- package/lib/es/components/map/components/features/basics/MapLayerGroup.js +0 -48
- package/lib/es/components/map/components/features/basics/marker/DomMarker.d.ts +0 -33
- package/lib/es/components/map/components/features/basics/marker/DomMarker.js +0 -58
- package/lib/es/components/map/components/features/basics/marker/Marker.d.ts +0 -21
- package/lib/es/components/map/components/features/basics/marker/Marker.js +0 -123
- package/lib/es/components/map/components/features/basics/marker/TextMarker.d.ts +0 -17
- package/lib/es/components/map/components/features/basics/marker/TextMarker.js +0 -31
- package/lib/es/components/map/components/features/layers/IncidentsLayer.d.ts +0 -2
- package/lib/es/components/map/components/features/layers/IncidentsLayer.js +0 -27
- package/lib/es/components/map/components/features/layers/Layer.d.ts +0 -15
- package/lib/es/components/map/components/features/layers/Layer.js +0 -26
- package/lib/es/components/map/components/features/layers/MapBaseLayer.d.ts +0 -8
- package/lib/es/components/map/components/features/layers/MapBaseLayer.js +0 -35
- package/lib/es/components/map/components/features/layers/RoadRestrictionLayer.d.ts +0 -2
- package/lib/es/components/map/components/features/layers/RoadRestrictionLayer.js +0 -28
- package/lib/es/components/map/components/features/layers/TrafficLayer.d.ts +0 -2
- package/lib/es/components/map/components/features/layers/TrafficLayer.js +0 -41
- package/lib/es/components/map/components/features/layers/baselayers/DefaultRasterLayer.d.ts +0 -4
- package/lib/es/components/map/components/features/layers/baselayers/DefaultRasterLayer.js +0 -36
- package/lib/es/components/map/components/features/layers/baselayers/DefaultVectorLayer.d.ts +0 -4
- package/lib/es/components/map/components/features/layers/baselayers/DefaultVectorLayer.js +0 -16
- package/lib/es/components/map/components/features/layers/baselayers/FleetStyleLayer.d.ts +0 -4
- package/lib/es/components/map/components/features/layers/baselayers/FleetStyleLayer.js +0 -17
- package/lib/es/components/map/components/features/layers/baselayers/NightLayer.d.ts +0 -4
- package/lib/es/components/map/components/features/layers/baselayers/NightLayer.js +0 -16
- package/lib/es/components/map/components/features/layers/baselayers/SatelliteLayer.d.ts +0 -4
- package/lib/es/components/map/components/features/layers/baselayers/SatelliteLayer.js +0 -34
- package/lib/es/components/map/components/features/layers/baselayers/TerrainLayer.d.ts +0 -4
- package/lib/es/components/map/components/features/layers/baselayers/TerrainLayer.js +0 -17
- package/lib/es/components/map/components/features/layers/baselayers/useBaseLayer.d.ts +0 -11
- package/lib/es/components/map/components/features/layers/baselayers/useBaseLayer.js +0 -76
- package/lib/es/components/map/components/mapUtils.d.ts +0 -50
- package/lib/es/components/map/components/mapUtils.js +0 -154
- package/lib/es/components/map/herePolyfill.d.ts +0 -0
- package/lib/es/components/map/herePolyfill.js +0 -7
- package/lib/es/components/map/utils/proptypes.d.ts +0 -47
- package/lib/es/components/map/utils/proptypes.js +0 -53
- package/lib/es/components/map/utils/validation.d.ts +0 -2
- package/lib/es/components/map/utils/validation.js +0 -14
- package/lib/es/components/mapMarker/MarkerColor.d.ts +0 -3
- package/lib/es/components/mapMarker/MarkerColor.js +0 -15
- package/lib/es/components/menuItems/getMenuItems.d.ts +0 -2
- package/lib/es/components/menuItems/getMenuItems.js +0 -10
- package/lib/es/components/selects/BaseDropdownMenu.d.ts +0 -83
- package/lib/es/components/selects/BaseDropdownMenu.js +0 -260
- package/lib/es/components/selects/WithFeedback.d.ts +0 -27
- package/lib/es/components/selects/WithFeedback.js +0 -15
- package/lib/es/components/states/baseStatePropTypes.d.ts +0 -26
- package/lib/es/components/states/baseStatePropTypes.js +0 -30
- package/lib/es/components/table/tableSettingsPropTypes.d.ts +0 -8
- package/lib/es/components/table/tableSettingsPropTypes.js +0 -10
- package/lib/es/mapIndex.d.ts +0 -38
- package/lib/es/mapIndex.js +0 -77
- package/lib/es/styles/variables/colors.json +0 -74
- package/lib/es/themes/Volkswagen/components/applicationHeader/modulePropTypes.d.ts +0 -6
- package/lib/es/themes/Volkswagen/components/applicationHeader/modulePropTypes.js +0 -8
- package/lib/es/types.d.ts +0 -71
- package/lib/es/types.js +0 -2
- package/lib/es/utils/GroupSelectionUtil.d.ts +0 -1
- package/lib/es/utils/GroupSelectionUtil.js +0 -85
- package/lib/es/utils/addEventListener.d.ts +0 -3
- package/lib/es/utils/addEventListener.js +0 -17
- package/lib/es/utils/addFocusListener.d.ts +0 -3
- package/lib/es/utils/addFocusListener.js +0 -24
- package/lib/es/utils/getOffsetTopWholeScreen.d.ts +0 -1
- package/lib/es/utils/getOffsetTopWholeScreen.js +0 -9
- package/lib/es/utils/init.d.ts +0 -2
- package/lib/es/utils/init.js +0 -121
- package/lib/es/utils/logPropError.d.ts +0 -3
- package/lib/es/utils/logPropError.js +0 -28
- package/lib/es/utils/ownerDocument.d.ts +0 -1
- package/lib/es/utils/ownerDocument.js +0 -12
- package/mapIndex.d.ts +0 -38
- package/mapIndex.js +0 -42
- package/styles/variables/colors.json +0 -74
- package/themes/Volkswagen/components/applicationHeader/modulePropTypes.d.ts +0 -6
- package/themes/Volkswagen/components/applicationHeader/modulePropTypes.js +0 -5
- package/types.d.ts +0 -71
- package/types.js +0 -1
- package/utils/GroupSelectionUtil.d.ts +0 -1
- package/utils/GroupSelectionUtil.js +0 -80
- package/utils/addEventListener.d.ts +0 -3
- package/utils/addEventListener.js +0 -13
- package/utils/addFocusListener.d.ts +0 -3
- package/utils/addFocusListener.js +0 -21
- package/utils/getOffsetTopWholeScreen.d.ts +0 -1
- package/utils/getOffsetTopWholeScreen.js +0 -6
- package/utils/init.d.ts +0 -2
- package/utils/init.js +0 -117
- package/utils/logPropError.d.ts +0 -3
- package/utils/logPropError.js +0 -23
- package/utils/ownerDocument.d.ts +0 -1
- package/utils/ownerDocument.js +0 -8
|
@@ -1,123 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getOrCreateIcon = exports.isDomMakerNeeded = exports.isHMapIcon = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
/* eslint-disable no-undef */
|
|
6
|
-
const react_1 = tslib_1.__importStar(require("react"));
|
|
7
|
-
const server_1 = tslib_1.__importDefault(require("react-dom/server"));
|
|
8
|
-
const prop_types_1 = tslib_1.__importDefault(require("prop-types"));
|
|
9
|
-
const proptypes_1 = tslib_1.__importDefault(require("../../../../utils/proptypes"));
|
|
10
|
-
const eventHandling_1 = require("../../../../utils/eventHandling");
|
|
11
|
-
const MapException_1 = tslib_1.__importDefault(require("../../../../exceptions/MapException"));
|
|
12
|
-
const context_1 = require("../../../context");
|
|
13
|
-
const isHMapIcon = icon => icon instanceof H.map.Icon;
|
|
14
|
-
exports.isHMapIcon = isHMapIcon;
|
|
15
|
-
const isDomMakerNeeded = icon => (!icon ? false : !(0, exports.isHMapIcon)(icon));
|
|
16
|
-
exports.isDomMakerNeeded = isDomMakerNeeded;
|
|
17
|
-
function getOrCreateIcon(icon) {
|
|
18
|
-
if (!icon || (0, exports.isHMapIcon)(icon) || icon instanceof H.map.DomIcon) {
|
|
19
|
-
return;
|
|
20
|
-
}
|
|
21
|
-
const renderedIcon = react_1.default.isValidElement(icon)
|
|
22
|
-
? server_1.default.renderToStaticMarkup(react_1.default.cloneElement(icon))
|
|
23
|
-
: icon;
|
|
24
|
-
return new H.map.DomIcon(renderedIcon);
|
|
25
|
-
}
|
|
26
|
-
exports.getOrCreateIcon = getOrCreateIcon;
|
|
27
|
-
const convertPosition = pos => (Array.isArray(pos) ? new H.geo.MultiPoint(pos) : pos);
|
|
28
|
-
const checkPositionProperties = position => {
|
|
29
|
-
['lat', 'lng'].forEach(propertyName => {
|
|
30
|
-
// eslint-disable-next-line no-prototype-builtins
|
|
31
|
-
if (!position.hasOwnProperty(propertyName)) {
|
|
32
|
-
throw new MapException_1.default(`Error in Marker: position object requires property "${propertyName}"`);
|
|
33
|
-
}
|
|
34
|
-
});
|
|
35
|
-
};
|
|
36
|
-
const getPosition = position => {
|
|
37
|
-
if (!position) {
|
|
38
|
-
throw new MapException_1.default('Error in Marker: invalid position property');
|
|
39
|
-
}
|
|
40
|
-
if (Array.isArray(position)) {
|
|
41
|
-
position.forEach(pos => checkPositionProperties(pos));
|
|
42
|
-
}
|
|
43
|
-
else {
|
|
44
|
-
checkPositionProperties(position);
|
|
45
|
-
}
|
|
46
|
-
return position;
|
|
47
|
-
};
|
|
48
|
-
const getConvertedPosition = position => convertPosition(getPosition(position));
|
|
49
|
-
const setupMarker = (props, api) => {
|
|
50
|
-
const { position, customData, icon, draggable, eventListenerMap } = props;
|
|
51
|
-
const MarkerConstructor = (0, exports.isDomMakerNeeded)(icon) ? H.map.DomMarker : H.map.Marker;
|
|
52
|
-
const marker = new MarkerConstructor(getConvertedPosition(position), {
|
|
53
|
-
icon: getOrCreateIcon(icon, api.settings.baseLayer),
|
|
54
|
-
});
|
|
55
|
-
marker.setData(customData);
|
|
56
|
-
marker.draggable = !!draggable;
|
|
57
|
-
api.map.addObject(marker);
|
|
58
|
-
(0, eventHandling_1.addEventListenerMap)(marker, eventListenerMap, api.map);
|
|
59
|
-
return marker;
|
|
60
|
-
};
|
|
61
|
-
const destroyMarker = (marker, api) => {
|
|
62
|
-
(0, eventHandling_1.removeEventListenerMap)(marker);
|
|
63
|
-
if (api.map.getObjects().includes(marker)) {
|
|
64
|
-
api.map.removeObject(marker);
|
|
65
|
-
}
|
|
66
|
-
marker.dispose();
|
|
67
|
-
};
|
|
68
|
-
const Marker = props => {
|
|
69
|
-
const { position, customData, icon, eventListenerMap } = props;
|
|
70
|
-
const { api } = (0, react_1.useContext)(context_1.MapContext);
|
|
71
|
-
const markerRef = (0, react_1.useRef)();
|
|
72
|
-
(0, react_1.useEffect)(() => {
|
|
73
|
-
markerRef.current = setupMarker(props, api);
|
|
74
|
-
return () => {
|
|
75
|
-
if (markerRef.current) {
|
|
76
|
-
destroyMarker(markerRef.current, api);
|
|
77
|
-
markerRef.current = undefined;
|
|
78
|
-
}
|
|
79
|
-
};
|
|
80
|
-
}, []);
|
|
81
|
-
// Update marker position
|
|
82
|
-
(0, react_1.useEffect)(() => {
|
|
83
|
-
if (markerRef.current) {
|
|
84
|
-
markerRef.current.setGeometry(getConvertedPosition(position));
|
|
85
|
-
}
|
|
86
|
-
}, [position, markerRef.current]);
|
|
87
|
-
// Update marker custom data
|
|
88
|
-
(0, react_1.useEffect)(() => {
|
|
89
|
-
if (markerRef.current) {
|
|
90
|
-
markerRef.current.setData(customData);
|
|
91
|
-
}
|
|
92
|
-
}, [customData, markerRef.current]);
|
|
93
|
-
// Update EventListenerMap
|
|
94
|
-
(0, react_1.useEffect)(() => {
|
|
95
|
-
if (markerRef.current) {
|
|
96
|
-
// use exports to make methods accessible for stubbing
|
|
97
|
-
const mapApi = (0, eventHandling_1.removeEventListenerMap)(markerRef.current);
|
|
98
|
-
(0, eventHandling_1.addEventListenerMap)(markerRef.current, eventListenerMap, mapApi);
|
|
99
|
-
}
|
|
100
|
-
}, [eventListenerMap, markerRef.current]);
|
|
101
|
-
// If icon type changed, we need to change the marker type
|
|
102
|
-
(0, react_1.useEffect)(() => {
|
|
103
|
-
if (!(markerRef.current && icon)) {
|
|
104
|
-
return;
|
|
105
|
-
}
|
|
106
|
-
if ((0, exports.isDomMakerNeeded)(icon)) {
|
|
107
|
-
destroyMarker(markerRef.current, api);
|
|
108
|
-
markerRef.current = setupMarker(props, api);
|
|
109
|
-
}
|
|
110
|
-
else {
|
|
111
|
-
markerRef.current.setIcon(getOrCreateIcon(icon));
|
|
112
|
-
}
|
|
113
|
-
}, [icon, markerRef.current]);
|
|
114
|
-
return null;
|
|
115
|
-
};
|
|
116
|
-
Marker.propTypes = {
|
|
117
|
-
position: prop_types_1.default.oneOfType([proptypes_1.default.position, proptypes_1.default.positions]).isRequired,
|
|
118
|
-
icon: proptypes_1.default.icon,
|
|
119
|
-
eventListenerMap: prop_types_1.default.object,
|
|
120
|
-
customData: prop_types_1.default.object,
|
|
121
|
-
draggable: prop_types_1.default.bool,
|
|
122
|
-
};
|
|
123
|
-
exports.default = Marker;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
export const emptyTextException: "Error in TextMarker: TextMarker without text makes no sense";
|
|
2
|
-
export const wrongTypeException: "Error in TextMarker: property text must be string type";
|
|
3
|
-
export default TextMarker;
|
|
4
|
-
declare function TextMarker(props: any): import("react/jsx-runtime").JSX.Element;
|
|
5
|
-
declare namespace TextMarker {
|
|
6
|
-
namespace propTypes {
|
|
7
|
-
const position: PropTypes.Validator<NonNullable<NonNullable<PropTypes.InferProps<{
|
|
8
|
-
lat: PropTypes.Validator<number>;
|
|
9
|
-
lng: PropTypes.Validator<number>;
|
|
10
|
-
}> | (PropTypes.InferProps<{
|
|
11
|
-
lat: PropTypes.Validator<number>;
|
|
12
|
-
lng: PropTypes.Validator<number>;
|
|
13
|
-
}> | null | undefined)[] | null | undefined>>>;
|
|
14
|
-
const text: PropTypes.Validator<string>;
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
import PropTypes from "prop-types";
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.wrongTypeException = exports.emptyTextException = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
6
|
-
const react_1 = tslib_1.__importDefault(require("react"));
|
|
7
|
-
const prop_types_1 = tslib_1.__importDefault(require("prop-types"));
|
|
8
|
-
const MapException_1 = tslib_1.__importDefault(require("../../../../exceptions/MapException"));
|
|
9
|
-
const proptypes_1 = tslib_1.__importDefault(require("../../../../utils/proptypes"));
|
|
10
|
-
const Marker_1 = tslib_1.__importDefault(require("./Marker"));
|
|
11
|
-
exports.emptyTextException = 'Error in TextMarker: TextMarker without text makes no sense';
|
|
12
|
-
exports.wrongTypeException = 'Error in TextMarker: property text must be string type';
|
|
13
|
-
const TextMarker = props => {
|
|
14
|
-
const other = tslib_1.__rest(props, []);
|
|
15
|
-
const textDiv = `<div class="bg-white padding-x-5 padding-y-3 border border-color-darker shadow-accent">${getText(props.text)}</div>`;
|
|
16
|
-
return (0, jsx_runtime_1.jsx)(Marker_1.default, Object.assign({}, other, { icon: textDiv }));
|
|
17
|
-
};
|
|
18
|
-
const getText = text => {
|
|
19
|
-
if (!text) {
|
|
20
|
-
throw new MapException_1.default(exports.emptyTextException);
|
|
21
|
-
}
|
|
22
|
-
if (typeof text !== 'string') {
|
|
23
|
-
throw new MapException_1.default(exports.wrongTypeException);
|
|
24
|
-
}
|
|
25
|
-
return text;
|
|
26
|
-
};
|
|
27
|
-
TextMarker.propTypes = {
|
|
28
|
-
position: prop_types_1.default.oneOfType([proptypes_1.default.position, proptypes_1.default.positions]).isRequired,
|
|
29
|
-
text: prop_types_1.default.string.isRequired,
|
|
30
|
-
};
|
|
31
|
-
exports.default = TextMarker;
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const tslib_1 = require("tslib");
|
|
4
|
-
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
-
const react_1 = tslib_1.__importDefault(require("react"));
|
|
6
|
-
const Layer_1 = tslib_1.__importDefault(require("./Layer"));
|
|
7
|
-
// Layer that shows construction sites marker that are interactive and use a popup for details
|
|
8
|
-
// Since "vector.normal.trafficincidents" is deprecated we have to use the Here Traffic Service v7
|
|
9
|
-
// see: https://developer.here.com/documentation/maps/3.1.46.0/api_reference/H.service.Platform.html
|
|
10
|
-
const createTrafficIncidentsLayer = api => {
|
|
11
|
-
const config = `
|
|
12
|
-
sources:
|
|
13
|
-
omv:
|
|
14
|
-
type: OMV
|
|
15
|
-
layers:
|
|
16
|
-
incident_icons:
|
|
17
|
-
data: {source: omv}
|
|
18
|
-
`;
|
|
19
|
-
return api.platform.getTrafficVectorTileService().createLayer(new H.map.render.webgl.Style(config));
|
|
20
|
-
};
|
|
21
|
-
// For raster map, we use the old deprecated fallback for now
|
|
22
|
-
const createTrafficIncidentsLayerFallback = api => api.defaultLayers.vector.normal.trafficincidents;
|
|
23
|
-
const IncidentsLayer = props => {
|
|
24
|
-
const { useWebGL } = props, remainingProps = tslib_1.__rest(props, ["useWebGL"]);
|
|
25
|
-
return ((0, jsx_runtime_1.jsx)(Layer_1.default, Object.assign({}, remainingProps, { createLayer: useWebGL ? createTrafficIncidentsLayer : createTrafficIncidentsLayerFallback })));
|
|
26
|
-
};
|
|
27
|
-
exports.default = IncidentsLayer;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
export default Layer;
|
|
2
|
-
declare function Layer(props: any): null;
|
|
3
|
-
declare namespace Layer {
|
|
4
|
-
namespace propTypes {
|
|
5
|
-
const api: PropTypes.Requireable<PropTypes.InferProps<{
|
|
6
|
-
map: PropTypes.Requireable<H.Map>;
|
|
7
|
-
platform: PropTypes.Requireable<H.service.Platform>;
|
|
8
|
-
defaultLayers: PropTypes.Requireable<object>;
|
|
9
|
-
group: PropTypes.Requireable<NonNullable<H.Map | H.map.Group | null | undefined>>;
|
|
10
|
-
}>>;
|
|
11
|
-
const createLayer: PropTypes.Validator<(...args: any[]) => any>;
|
|
12
|
-
const layerIndex: PropTypes.Requireable<number>;
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
import PropTypes from "prop-types";
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const tslib_1 = require("tslib");
|
|
4
|
-
const react_1 = require("react");
|
|
5
|
-
const prop_types_1 = tslib_1.__importDefault(require("prop-types"));
|
|
6
|
-
const proptypes_1 = tslib_1.__importDefault(require("../../../utils/proptypes"));
|
|
7
|
-
const Layer = props => {
|
|
8
|
-
const { api, createLayer, layerIndex } = props;
|
|
9
|
-
(0, react_1.useEffect)(() => {
|
|
10
|
-
const newLayer = createLayer(api);
|
|
11
|
-
api.map.addLayer(newLayer, layerIndex);
|
|
12
|
-
return () => {
|
|
13
|
-
if (newLayer) {
|
|
14
|
-
api.map.removeLayer(newLayer);
|
|
15
|
-
newLayer.dispose();
|
|
16
|
-
}
|
|
17
|
-
};
|
|
18
|
-
}, [api.map]);
|
|
19
|
-
return null;
|
|
20
|
-
};
|
|
21
|
-
Layer.propTypes = {
|
|
22
|
-
api: proptypes_1.default.api,
|
|
23
|
-
createLayer: prop_types_1.default.func.isRequired,
|
|
24
|
-
layerIndex: prop_types_1.default.number,
|
|
25
|
-
};
|
|
26
|
-
exports.default = Layer;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
export type MapBaseLayerProps = {
|
|
2
|
-
baseLayerName: string;
|
|
3
|
-
language: string;
|
|
4
|
-
enableWebGL: boolean;
|
|
5
|
-
darkMode: boolean;
|
|
6
|
-
};
|
|
7
|
-
declare const MapBaseLayer: (props: MapBaseLayerProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
8
|
-
export default MapBaseLayer;
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const tslib_1 = require("tslib");
|
|
4
|
-
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
-
const react_1 = require("react");
|
|
6
|
-
const constants_1 = require("../../constants");
|
|
7
|
-
const DefaultRasterLayer_1 = tslib_1.__importDefault(require("./baselayers/DefaultRasterLayer"));
|
|
8
|
-
require("./baselayers/DefaultVectorLayer");
|
|
9
|
-
const FleetStyleLayer_1 = tslib_1.__importDefault(require("./baselayers/FleetStyleLayer"));
|
|
10
|
-
const NightLayer_1 = tslib_1.__importDefault(require("./baselayers/NightLayer"));
|
|
11
|
-
const SatelliteLayer_1 = tslib_1.__importDefault(require("./baselayers/SatelliteLayer"));
|
|
12
|
-
const TerrainLayer_1 = tslib_1.__importDefault(require("./baselayers/TerrainLayer"));
|
|
13
|
-
const MapContext_1 = require("../../MapContext");
|
|
14
|
-
const MapBaseLayer = (props) => {
|
|
15
|
-
const { baseLayerName, language, enableWebGL, darkMode } = props;
|
|
16
|
-
const { api } = (0, react_1.useContext)(MapContext_1.MapContext);
|
|
17
|
-
switch (baseLayerName) {
|
|
18
|
-
case constants_1.MAP_TYPE_DEFAULT: {
|
|
19
|
-
return !darkMode && enableWebGL ? (
|
|
20
|
-
// <DefaultVectorLayer api={api} language={language} key={baseLayerName} />
|
|
21
|
-
(0, jsx_runtime_1.jsx)(DefaultRasterLayer_1.default, { api: api, language: language, darkMode: darkMode, isWebGL: enableWebGL }, baseLayerName)) : ((0, jsx_runtime_1.jsx)(DefaultRasterLayer_1.default, { api: api, language: language, darkMode: darkMode, isWebGL: enableWebGL }, baseLayerName));
|
|
22
|
-
}
|
|
23
|
-
case constants_1.MAP_TYPE_FLEET_STYLE:
|
|
24
|
-
return (0, jsx_runtime_1.jsx)(FleetStyleLayer_1.default, { api: api, language: language, isWebGL: enableWebGL }, baseLayerName);
|
|
25
|
-
case constants_1.MAP_TYPE_SATELLITE:
|
|
26
|
-
return (0, jsx_runtime_1.jsx)(SatelliteLayer_1.default, { api: api, language: language, isWebGL: enableWebGL }, baseLayerName);
|
|
27
|
-
case constants_1.MAP_TYPE_TERRAIN:
|
|
28
|
-
return (0, jsx_runtime_1.jsx)(TerrainLayer_1.default, { api: api, language: language, isWebGL: enableWebGL }, baseLayerName);
|
|
29
|
-
case constants_1.MAP_TYPE_NIGHT:
|
|
30
|
-
return (0, jsx_runtime_1.jsx)(NightLayer_1.default, { api: api, language: language, isWebGL: enableWebGL }, baseLayerName);
|
|
31
|
-
default:
|
|
32
|
-
return null;
|
|
33
|
-
}
|
|
34
|
-
};
|
|
35
|
-
exports.default = MapBaseLayer;
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const tslib_1 = require("tslib");
|
|
4
|
-
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
-
const react_1 = tslib_1.__importDefault(require("react"));
|
|
6
|
-
const constants_1 = require("../../constants");
|
|
7
|
-
const Layer_1 = tslib_1.__importDefault(require("./Layer"));
|
|
8
|
-
// Layer for rendering truck road signs
|
|
9
|
-
// incident_icons, traffic_flow, traffic_incidents
|
|
10
|
-
// FIXME: 'truckonlytile' is HERE Map Tile v2 and therefore deprecated
|
|
11
|
-
const createRoadRestrictionLayer = useWebGL => api => {
|
|
12
|
-
// "createIncidentsLayer" and "createFlowLayer" are also deprecated
|
|
13
|
-
// using the "api.platform.getTrafficService(null, 7)" Traffic Service version 7
|
|
14
|
-
// does not offer equivalent functions like:
|
|
15
|
-
// return api.platform.getTrafficService(null, 7).createFlowLayer();
|
|
16
|
-
return api.platform
|
|
17
|
-
.getMapTileService({ type: 'base' })
|
|
18
|
-
.createTileLayer('truckonlytile', 'normal.day', constants_1.TILE_SIZE, constants_1.FORMAT, {
|
|
19
|
-
style: 'default',
|
|
20
|
-
ppi: undefined,
|
|
21
|
-
});
|
|
22
|
-
};
|
|
23
|
-
const RoadRestrictionLayer = props => {
|
|
24
|
-
const { useWebGL } = props, remainingProps = tslib_1.__rest(props, ["useWebGL"]);
|
|
25
|
-
const createLayer = createRoadRestrictionLayer(useWebGL);
|
|
26
|
-
return (0, jsx_runtime_1.jsx)(Layer_1.default, Object.assign({}, remainingProps, { createLayer: createLayer }));
|
|
27
|
-
};
|
|
28
|
-
exports.default = RoadRestrictionLayer;
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const tslib_1 = require("tslib");
|
|
4
|
-
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
-
const react_1 = tslib_1.__importStar(require("react"));
|
|
6
|
-
const constants_1 = require("../../constants");
|
|
7
|
-
const Layer_1 = tslib_1.__importDefault(require("./Layer"));
|
|
8
|
-
const createRasterTrafficLayer = api => {
|
|
9
|
-
return api.platform
|
|
10
|
-
.getMapTileService({ type: 'traffic' })
|
|
11
|
-
.createTileLayer('flowtile', 'normal.day.grey', constants_1.TILE_SIZE, constants_1.FORMAT, {
|
|
12
|
-
style: 'alps',
|
|
13
|
-
});
|
|
14
|
-
};
|
|
15
|
-
// Here Traffic v7 API
|
|
16
|
-
const createVectorTrafficLayer = api => {
|
|
17
|
-
// Pre-defined opinionated rendering of traffic
|
|
18
|
-
return api.defaultLayers.vector.traffic.map;
|
|
19
|
-
// To control the rendering, use the style config.
|
|
20
|
-
// Unfortunately there is no documentation on how the "pre-defined"
|
|
21
|
-
// style looks like as it also renders incidents icons (but inactive)
|
|
22
|
-
// const config = `
|
|
23
|
-
// sources:
|
|
24
|
-
// omv:
|
|
25
|
-
// type: OMV
|
|
26
|
-
// layers:
|
|
27
|
-
// traffic_incidents:
|
|
28
|
-
// data: {source: omv}
|
|
29
|
-
// draw:
|
|
30
|
-
// lines:
|
|
31
|
-
// order: 340
|
|
32
|
-
// width: 2px
|
|
33
|
-
// color: red
|
|
34
|
-
// `;
|
|
35
|
-
// return api.platform.getTrafficVectorTileService().createLayer(new H.map.render.webgl.Style(config));
|
|
36
|
-
};
|
|
37
|
-
const TrafficLayer = props => {
|
|
38
|
-
const { useWebGL } = props, remainingProps = tslib_1.__rest(props, ["useWebGL"]);
|
|
39
|
-
return (0, jsx_runtime_1.jsx)(Layer_1.default, Object.assign({}, remainingProps, { createLayer: useWebGL ? createVectorTrafficLayer : createRasterTrafficLayer }));
|
|
40
|
-
};
|
|
41
|
-
exports.default = TrafficLayer;
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
require("./useBaseLayer");
|
|
4
|
-
require("../../../constants");
|
|
5
|
-
// https://developer.here.com/documentation/map-tile/dev_guide/topics/resource-info.html
|
|
6
|
-
const DefaultRasterLayer = (props) => {
|
|
7
|
-
var _a, _b;
|
|
8
|
-
const { api, language, isWebGL } = props;
|
|
9
|
-
const rasterTileService = (_a = api.platform) === null || _a === void 0 ? void 0 : _a.getRasterTileService({
|
|
10
|
-
format: 'png',
|
|
11
|
-
queryParams: {
|
|
12
|
-
lang: 'en',
|
|
13
|
-
ppi: window.devicePixelRatio >= 1.7 ? 400 : 100,
|
|
14
|
-
style: 'explore.day',
|
|
15
|
-
features: 'pois:all,environmental_zones:all,congestion_zones:all,vehicle_restrictions:active_and_inactive',
|
|
16
|
-
},
|
|
17
|
-
});
|
|
18
|
-
const rasterTileProvider = new H.service.rasterTile.Provider(rasterTileService, {
|
|
19
|
-
engineType: H.Map.EngineType['HARP'],
|
|
20
|
-
tileSize: 512,
|
|
21
|
-
});
|
|
22
|
-
const rasterTileLayer = new H.map.layer.TileLayer(rasterTileProvider);
|
|
23
|
-
const defaultLayer = rasterTileLayer;
|
|
24
|
-
(_b = api.map) === null || _b === void 0 ? void 0 : _b.setBaseLayer(defaultLayer);
|
|
25
|
-
// useBaseLayer({
|
|
26
|
-
// api,
|
|
27
|
-
// language,
|
|
28
|
-
// mapType: MAP_TYPE_DEFAULT,
|
|
29
|
-
// additionalParameters: {
|
|
30
|
-
// // should not be used as Vector map does not support it it would different anyhow
|
|
31
|
-
// // style: 'alps',
|
|
32
|
-
// },
|
|
33
|
-
// });
|
|
34
|
-
return null;
|
|
35
|
-
};
|
|
36
|
-
exports.default = DefaultRasterLayer;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const useBaseLayer_1 = require("./useBaseLayer");
|
|
4
|
-
const constants_1 = require("../../../constants");
|
|
5
|
-
const DefaultVectorLayer = (props) => {
|
|
6
|
-
const { api, language } = props;
|
|
7
|
-
(0, useBaseLayer_1.useBaseLayer)({
|
|
8
|
-
api,
|
|
9
|
-
language,
|
|
10
|
-
mapType: constants_1.MAP_TYPE_DEFAULT,
|
|
11
|
-
additionalParameters: {},
|
|
12
|
-
isWebGL: true,
|
|
13
|
-
});
|
|
14
|
-
return null;
|
|
15
|
-
};
|
|
16
|
-
exports.default = DefaultVectorLayer;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const useBaseLayer_1 = require("./useBaseLayer");
|
|
4
|
-
const constants_1 = require("../../../constants");
|
|
5
|
-
const FleetStyleLayer = (props) => {
|
|
6
|
-
const { api, language } = props;
|
|
7
|
-
(0, useBaseLayer_1.useBaseLayer)({
|
|
8
|
-
api,
|
|
9
|
-
language,
|
|
10
|
-
mapType: constants_1.MAP_TYPE_FLEET_STYLE,
|
|
11
|
-
additionalParameters: {
|
|
12
|
-
style: 'fleet',
|
|
13
|
-
},
|
|
14
|
-
});
|
|
15
|
-
return null;
|
|
16
|
-
};
|
|
17
|
-
exports.default = FleetStyleLayer;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const useBaseLayer_1 = require("./useBaseLayer");
|
|
4
|
-
const constants_1 = require("../../../constants");
|
|
5
|
-
// https://developer.here.com/documentation/map-tile/dev_guide/topics/resource-info.html
|
|
6
|
-
const NightLayer = (props) => {
|
|
7
|
-
const { api, language } = props;
|
|
8
|
-
(0, useBaseLayer_1.useBaseLayer)({
|
|
9
|
-
api,
|
|
10
|
-
language,
|
|
11
|
-
mapType: constants_1.MAP_TYPE_NIGHT,
|
|
12
|
-
additionalParameters: {},
|
|
13
|
-
});
|
|
14
|
-
return null;
|
|
15
|
-
};
|
|
16
|
-
exports.default = NightLayer;
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
require("./useBaseLayer");
|
|
4
|
-
require("../../../constants");
|
|
5
|
-
const SatelliteLayer = (props) => {
|
|
6
|
-
var _a, _b;
|
|
7
|
-
const { api, language, isWebGL } = props;
|
|
8
|
-
const satelliteTileService = (_a = api.platform) === null || _a === void 0 ? void 0 : _a.getRasterTileService({
|
|
9
|
-
format: 'jpeg',
|
|
10
|
-
queryParams: {
|
|
11
|
-
lang: 'en',
|
|
12
|
-
ppi: window.devicePixelRatio >= 1.7 ? 400 : 100,
|
|
13
|
-
style: 'explore.satellite.day',
|
|
14
|
-
features: 'pois:all,environmental_zones:all,congestion_zones:all,vehicle_restrictions:active_and_inactive',
|
|
15
|
-
},
|
|
16
|
-
});
|
|
17
|
-
const satelliteTileProvider = new H.service.rasterTile.Provider(satelliteTileService, {
|
|
18
|
-
engineType: H.Map.EngineType['HARP'],
|
|
19
|
-
tileSize: 512,
|
|
20
|
-
});
|
|
21
|
-
const satelliteTileLayer = new H.map.layer.TileLayer(satelliteTileProvider);
|
|
22
|
-
const defaultLayer = satelliteTileLayer;
|
|
23
|
-
(_b = api.map) === null || _b === void 0 ? void 0 : _b.setBaseLayer(defaultLayer);
|
|
24
|
-
// useBaseLayer({
|
|
25
|
-
// api,
|
|
26
|
-
// language,
|
|
27
|
-
// mapType: MAP_TYPE_SATELLITE,
|
|
28
|
-
// additionalParameters: {
|
|
29
|
-
// style: 'default',
|
|
30
|
-
// },
|
|
31
|
-
// });
|
|
32
|
-
return null;
|
|
33
|
-
};
|
|
34
|
-
exports.default = SatelliteLayer;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const useBaseLayer_1 = require("./useBaseLayer");
|
|
4
|
-
const constants_1 = require("../../../constants");
|
|
5
|
-
const TerrainLayer = (props) => {
|
|
6
|
-
const { api, language } = props;
|
|
7
|
-
(0, useBaseLayer_1.useBaseLayer)({
|
|
8
|
-
api,
|
|
9
|
-
language,
|
|
10
|
-
mapType: constants_1.MAP_TYPE_TERRAIN,
|
|
11
|
-
additionalParameters: {
|
|
12
|
-
style: 'default',
|
|
13
|
-
},
|
|
14
|
-
});
|
|
15
|
-
return null;
|
|
16
|
-
};
|
|
17
|
-
exports.default = TerrainLayer;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/// <reference types="heremaps" />
|
|
2
|
-
import type { MapApi } from '../../../../utils/mapTypes';
|
|
3
|
-
export declare const getDefaultBaseLayer: (defaultLayers: H.service.DefaultLayers | undefined, mapType: string, useWebGL: boolean) => H.map.layer.TileLayer | null | undefined;
|
|
4
|
-
export type UseBaseLayerProps = {
|
|
5
|
-
api: MapApi;
|
|
6
|
-
additionalParameters: object;
|
|
7
|
-
language: string;
|
|
8
|
-
isWebGL?: boolean;
|
|
9
|
-
mapType: string;
|
|
10
|
-
};
|
|
11
|
-
export declare const useBaseLayer: (props: UseBaseLayerProps) => void;
|
|
@@ -1,76 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.useBaseLayer = exports.getDefaultBaseLayer = void 0;
|
|
4
|
-
const react_1 = require("react");
|
|
5
|
-
require("../../../../utils/mapUtils");
|
|
6
|
-
const constants_1 = require("../../../constants");
|
|
7
|
-
// Obtain the default map types from the platform object:
|
|
8
|
-
const getDefaultBaseLayer = (defaultLayers, mapType, useWebGL) => {
|
|
9
|
-
if (mapType === constants_1.MAP_TYPE_SATELLITE) {
|
|
10
|
-
return defaultLayers === null || defaultLayers === void 0 ? void 0 : defaultLayers.raster.satellite.map;
|
|
11
|
-
}
|
|
12
|
-
if (mapType === constants_1.MAP_TYPE_TERRAIN) {
|
|
13
|
-
return defaultLayers === null || defaultLayers === void 0 ? void 0 : defaultLayers.raster.terrain.map;
|
|
14
|
-
}
|
|
15
|
-
if (mapType === constants_1.MAP_TYPE_FLEET_STYLE) {
|
|
16
|
-
return defaultLayers === null || defaultLayers === void 0 ? void 0 : defaultLayers.raster.normal.map;
|
|
17
|
-
}
|
|
18
|
-
if (mapType === constants_1.MAP_TYPE_NIGHT) {
|
|
19
|
-
return defaultLayers === null || defaultLayers === void 0 ? void 0 : defaultLayers.raster.normal.mapnight;
|
|
20
|
-
}
|
|
21
|
-
if (useWebGL) {
|
|
22
|
-
return defaultLayers === null || defaultLayers === void 0 ? void 0 : defaultLayers.vector.normal.map;
|
|
23
|
-
}
|
|
24
|
-
return defaultLayers === null || defaultLayers === void 0 ? void 0 : defaultLayers.raster.normal.map;
|
|
25
|
-
};
|
|
26
|
-
exports.getDefaultBaseLayer = getDefaultBaseLayer;
|
|
27
|
-
function getPpi() {
|
|
28
|
-
return window.devicePixelRatio >= 1.7 ? 400 : 100;
|
|
29
|
-
}
|
|
30
|
-
const useBaseLayer = (props) => {
|
|
31
|
-
const { api, additionalParameters = {}, language, isWebGL = false, mapType } = props;
|
|
32
|
-
const [baseLayer, setBaseLayer] = (0, react_1.useState)(null);
|
|
33
|
-
// When the language changes from the outside, re-create the base layer with the new locale
|
|
34
|
-
(0, react_1.useEffect)(() => {
|
|
35
|
-
setBaseLayer(null);
|
|
36
|
-
}, [language]);
|
|
37
|
-
(0, react_1.useEffect)(() => {
|
|
38
|
-
var _a, _b;
|
|
39
|
-
if (!baseLayer) {
|
|
40
|
-
// Base raster
|
|
41
|
-
// const rasterTileService = api.platform?.getRasterTileService({
|
|
42
|
-
// format: 'png', // or jpg, png8
|
|
43
|
-
// queryParams: {
|
|
44
|
-
// lang: 'en',
|
|
45
|
-
// ppi: getPpi(),
|
|
46
|
-
// style: 'explore.day',
|
|
47
|
-
// features:
|
|
48
|
-
// 'pois:all,environmental_zones:all,congestion_zones:all,vehicle_restrictions:active_and_inactive',
|
|
49
|
-
// },
|
|
50
|
-
// });
|
|
51
|
-
// const rasterTileProvider = new H.service.rasterTile.Provider(rasterTileService, {
|
|
52
|
-
// engineType: H.Map.EngineType['P2D'],
|
|
53
|
-
// tileSize: 512,
|
|
54
|
-
// });
|
|
55
|
-
// const rasterTileLayer = new H.map.layer.TileLayer(rasterTileProvider);
|
|
56
|
-
// const defaultLayer = rasterTileLayer;
|
|
57
|
-
// api.map?.setBaseLayer(defaultLayer);
|
|
58
|
-
// setBaseLayer(defaultLayer);
|
|
59
|
-
const additionalParametersWithLocale = Object.assign(Object.assign({}, additionalParameters), {
|
|
60
|
-
// Define the overall map language here so that all counties use that locale
|
|
61
|
-
// and don't show their native label names. For more details see:
|
|
62
|
-
// https://developer.here.com/documentation/examples/maps-js/maps/map-multi-language-support
|
|
63
|
-
// Note: it takes the short locale like "de", "en" etc.
|
|
64
|
-
lg: language.includes('-') ? language.split('-')[0] : language,
|
|
65
|
-
// ppi: getPPI(),
|
|
66
|
-
engineType: isWebGL ? H.Map.EngineType['HARP'] : H.Map.EngineType['P2D'] });
|
|
67
|
-
const defaultLayers = (_a = api.platform) === null || _a === void 0 ? void 0 : _a.createDefaultLayers(additionalParametersWithLocale);
|
|
68
|
-
const newBaseLayer = (0, exports.getDefaultBaseLayer)(defaultLayers, mapType, isWebGL);
|
|
69
|
-
if (newBaseLayer) {
|
|
70
|
-
(_b = api.map) === null || _b === void 0 ? void 0 : _b.setBaseLayer(newBaseLayer);
|
|
71
|
-
setBaseLayer(newBaseLayer);
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
});
|
|
75
|
-
};
|
|
76
|
-
exports.useBaseLayer = useBaseLayer;
|