@m4l/gclick 0.1.0 → 0.2.0-JAEBeta.1
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/@types/deviceData.d.ts +12 -9
- package/@types/general.d.ts +1 -1
- package/@types/index.d.ts +2 -2
- package/@types/types.d.ts +25 -1
- package/@types/vpts.d.ts +6 -3
- package/components/Device/Device.d.ts +6 -0
- package/components/Device/Device.js +32 -0
- package/components/Device/Device.styles.d.ts +2 -0
- package/components/Device/Device.styles.js +95 -0
- package/components/Device/constants.d.ts +14 -0
- package/components/Device/constants.js +4 -0
- package/components/Device/dictionary.d.ts +14 -0
- package/components/Device/dictionary.js +19 -0
- package/components/{DeviceStatus/hooks/helper.d.ts → Device/helpers/helperDeviceStatus.d.ts} +1 -1
- package/components/{DeviceStatus/hooks/helper.js → Device/helpers/helperDeviceStatus.js} +5 -5
- package/components/Device/helpers.d.ts +18 -0
- package/components/Device/helpers.js +27 -0
- package/components/Device/hooks/constants.d.ts +16 -0
- package/components/{DeviceStatus → Device}/hooks/constants.js +13 -15
- package/components/Device/hooks/useDevice.d.ts +12 -0
- package/components/Device/hooks/useDevice.js +23 -0
- package/components/{DeviceStatus → Device}/hooks/useDeviceStatus.d.ts +2 -2
- package/components/{DeviceStatus → Device}/hooks/useDeviceStatus.js +4 -4
- package/components/Device/icons.d.ts +11 -0
- package/components/{DeviceStatus → Device}/icons.js +2 -2
- package/components/Device/index.d.ts +6 -0
- package/components/Device/slots/DeviceSlots.d.ts +15 -0
- package/components/Device/slots/DeviceSlots.js +32 -0
- package/components/Device/slots/slots.d.ts +7 -0
- package/components/Device/slots/slots.js +11 -0
- package/components/Device/types.d.ts +30 -0
- package/components/DeviceLabel/DeviceLabel.js +1 -1
- package/components/DeviceLabel/slots/DeviceLabelSlots.d.ts +9 -3
- package/components/DeviceLabel/types.d.ts +2 -2
- package/components/DeviceStatus/DeviceStatus.js +3 -15
- package/components/DeviceStatus/DeviceStatus.styles.js +1 -13
- package/components/DeviceStatus/constants.js +1 -4
- package/components/DeviceStatus/dictionary.d.ts +10 -10
- package/components/DeviceStatus/dictionary.js +1 -12
- package/components/DeviceStatus/icons.d.ts +1 -1
- package/components/DeviceStatus/index.d.ts +3 -2
- package/components/DeviceStatus/slots/DeviceStatusSlots.js +1 -11
- package/components/DeviceStatus/slots/slots.js +1 -7
- package/components/index.d.ts +1 -1
- package/components/indicators/IndicatorBattery/IndicatorBattery.styles.js +2 -2
- package/components/indicators/IndicatorBattery/dictionary.js +5 -1
- package/components/indicators/IndicatorBattery/index.d.ts +1 -0
- package/components/indicators/IndicatorCSQ/IndicatorCSQ.js +7 -5
- package/components/indicators/IndicatorCSQ/constants.d.ts +2 -2
- package/components/indicators/IndicatorCSQ/constants.js +4 -3
- package/components/indicators/IndicatorCSQ/dictionary.d.ts +5 -2
- package/components/indicators/IndicatorCSQ/dictionary.js +15 -12
- package/components/indicators/IndicatorCSQ/helpers/getQualityLabel/getQualityLabel.d.ts +22 -2
- package/components/indicators/IndicatorCSQ/helpers/getQualityLabel/getQualityLabel.js +15 -29
- package/components/indicators/IndicatorCSQ/index.d.ts +3 -3
- package/components/indicators/IndicatorCSQ/slots/IndicatorCSQSlots.js +6 -6
- package/components/indicators/IndicatorCSQ/types.d.ts +6 -2
- package/components/indicators/IndicatorValueAndMagnitude/IndicatorValueAndMagnitude.d.ts +5 -0
- package/components/indicators/IndicatorValueAndMagnitude/IndicatorValueAndMagnitude.js +15 -0
- package/components/indicators/IndicatorValueAndMagnitude/IndicatorValueAndMagnitude.styles.d.ts +2 -0
- package/components/indicators/IndicatorValueAndMagnitude/IndicatorValueAndMagnitude.styles.js +41 -0
- package/components/indicators/IndicatorValueAndMagnitude/constants.d.ts +2 -0
- package/components/indicators/IndicatorValueAndMagnitude/constants.js +7 -0
- package/components/indicators/IndicatorValueAndMagnitude/index.d.ts +1 -0
- package/components/indicators/IndicatorValueAndMagnitude/index.js +1 -0
- package/components/indicators/IndicatorValueAndMagnitude/slots/slots.d.ts +6 -0
- package/components/indicators/IndicatorValueAndMagnitude/slots/slots.js +10 -0
- package/components/indicators/IndicatorValueAndMagnitude/slots/styled.d.ts +12 -0
- package/components/indicators/IndicatorValueAndMagnitude/slots/styled.js +27 -0
- package/components/indicators/IndicatorValueAndMagnitude/types.d.ts +14 -0
- package/components/indicators/IndicatorValueStatus/IndicatorValueStatus.js +25 -0
- package/components/indicators/IndicatorValueStatus/IndicatorValueStatus.styles.js +76 -0
- package/components/indicators/IndicatorValueStatus/constants.js +8 -0
- package/components/indicators/IndicatorValueStatus/index.js +1 -0
- package/components/indicators/IndicatorValueStatus/slots/IndicatorValueStatusEnum.js +11 -0
- package/components/indicators/IndicatorValueStatus/slots/IndicatorValueStatusSlots.js +32 -0
- package/components/indicators/IndicatorValueStatus/types.d.ts +4 -0
- package/components/indicators/index.d.ts +2 -0
- package/components/maps/components/GpsMap/GpsMap.js +26 -9
- package/components/maps/components/GpsMap/GpsMap.styles.js +81 -93
- package/components/maps/components/GpsMap/Leaflet.styles.d.ts +6 -0
- package/components/maps/components/GpsMap/Leaflet.styles.js +535 -0
- package/components/maps/components/GpsMap/classes/index.d.ts +1 -1
- package/components/maps/components/GpsMap/classes/index.js +6 -76
- package/components/maps/components/GpsMap/classes/types.d.ts +5 -16
- package/components/maps/components/GpsMap/constants.d.ts +9 -3
- package/components/maps/components/GpsMap/constants.js +25 -13
- package/components/maps/components/GpsMap/contexts/MapContext/MapContext.js +4 -26
- package/components/maps/components/GpsMap/contexts/MapContext/index.d.ts +1 -1
- package/components/maps/components/GpsMap/contexts/MapContext/store.js +50 -75
- package/components/maps/components/GpsMap/contexts/MapContext/types.d.ts +98 -87
- package/components/maps/components/GpsMap/dictionary.d.ts +19 -8
- package/components/maps/components/GpsMap/dictionary.js +30 -17
- package/components/maps/components/GpsMap/external/{Control → MapControl}/index.d.ts +3 -3
- package/components/maps/components/GpsMap/external/{Control → MapControl}/index.js +9 -7
- package/components/maps/components/GpsMap/external/MapControl/types.d.ts +26 -0
- package/components/maps/components/GpsMap/external/googleMutant/index.d.ts +1 -1
- package/components/maps/components/GpsMap/featureRenders/CommonFeatureRender/index.js +3 -3
- package/components/maps/components/GpsMap/featureRenders/FeatureDivIconLabel/index.js +1 -1
- package/components/maps/components/GpsMap/featureRenders/MarkerIconLabel/types.d.ts +3 -2
- package/components/maps/components/GpsMap/featureRenders/index.d.ts +0 -1
- package/components/maps/components/GpsMap/hooks/index.d.ts +3 -0
- package/components/maps/components/GpsMap/hooks/index.js +1 -0
- package/components/maps/components/GpsMap/hooks/useDisableMapEventsOnFlag/index.d.ts +6 -0
- package/components/maps/components/GpsMap/hooks/useDisableMapEventsOnFlag/index.js +31 -0
- package/components/maps/components/GpsMap/hooks/useDisableMapEventsOnMouseOver/index.d.ts +6 -0
- package/components/maps/components/GpsMap/hooks/{useDisableZoomEvents → useDisableMapEventsOnMouseOver}/index.js +10 -2
- package/components/maps/components/GpsMap/icons.d.ts +10 -7
- package/components/maps/components/GpsMap/icons.js +17 -16
- package/components/maps/components/GpsMap/index.d.ts +2 -1
- package/components/maps/components/GpsMap/popups/MapPopupDevice/MapPopupDevice.js +9 -1
- package/components/maps/components/GpsMap/popups/index.d.ts +1 -0
- package/components/maps/components/GpsMap/slots/slots.d.ts +27 -4
- package/components/maps/components/GpsMap/slots/slots.js +16 -7
- package/components/maps/components/GpsMap/slots/styled.d.ts +18 -0
- package/components/maps/components/GpsMap/slots/styled.js +37 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/index.js +8 -7
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/BottomRigthTools/index.d.ts +10 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/BottomRigthTools/index.js +10 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/{TopRigthTools → BottomRigthTools}/subcomponents/ZoomButtons/index.js +3 -3
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/BottomRigthTools/types.d.ts +2 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/hooks/types.d.ts +8 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/hooks/useTool.d.ts +13 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/hooks/useTool.js +64 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/index.d.ts +0 -2
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/index.js +42 -87
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/ButtonTool/index.d.ts +9 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/ButtonTool/index.js +24 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/ButtonTool/types.d.ts +2 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/MapLayersTool.d.ts +4 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/MapLayersTool.js +30 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/MapLayersTool.styles.d.ts +2 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/MapLayersTool.styles.js +45 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/hooks/types.d.ts +11 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/hooks/useMapLayersTool.d.ts +9 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/hooks/useMapLayersTool.js +37 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/slots/slots.d.ts +6 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/slots/slots.js +10 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/slots/styled.d.ts +12 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/slots/styled.js +26 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/subcomponents/MapLayerRow.d.ts +5 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/subcomponents/MapLayerRow.js +71 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/subcomponents/types.d.ts +6 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapLayersTool/types.d.ts +9 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/{TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/MapSourcesTool/index.d.ts → TopRigthTools/subcomponents/MapSourcesTool/MapSourcesTool.d.ts} +1 -1
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/MapSourcesTool.js +38 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/MapSourcesTool.styles.d.ts +2 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/MapSourcesTool.styles.js +87 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/hooks/useMapSourcesTool.d.ts +12 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/hooks/useMapSourcesTool.js +22 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/slots/slots.d.ts +9 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/slots/slots.js +13 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/slots/styled.d.ts +21 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/slots/styled.js +41 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/sourceTypes/bing.d.ts +2 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/sourceTypes/bing.js +47 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/sourceTypes/google.d.ts +2 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/sourceTypes/google.js +107 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/sourceTypes/others.d.ts +2 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/sourceTypes/others.js +33 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/subcomponents/MapSourceCard.d.ts +6 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/subcomponents/MapSourceCard.js +88 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/subcomponents/types.d.ts +7 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MapSourcesTool/types.d.ts +9 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/MeasureTool.js +31 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/MeasureTool.styles.d.ts +7 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/MeasureTool.styles.js +154 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/constants.d.ts +25 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/constants.js +37 -14
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/hooks/useMeasure/helpers.d.ts +29 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/hooks/useMeasure/helpers.js +14 -6
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/hooks/useMeasure/index.d.ts +2 -2
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/hooks/useMeasure/index.js +26 -20
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/hooks/useMeasure/types.d.ts +1 -2
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/slots/slots.d.ts +8 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/slots/slots.js +12 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/slots/styled.d.ts +18 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/slots/styled.js +37 -0
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/subcomponents/MeasureData/index.js +19 -17
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/subcomponents/MeasureData/types.d.ts +18 -2
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/types.d.ts +9 -1
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/types.d.ts +2 -5
- package/components/maps/components/GpsMap/subcomponents/Controls/types.d.ts +1 -1
- package/components/maps/components/GpsMap/subcomponents/LayersContainer/index.js +2 -1
- package/components/maps/components/GpsMap/subcomponents/LayersContainer/subcomponents/MyLayer/index.js +2 -1
- package/components/maps/components/GpsMap/subcomponents/MapEventController/MapEventController.d.ts +6 -0
- package/components/maps/components/GpsMap/subcomponents/MapEventController/MapEventController.js +8 -0
- package/components/maps/components/GpsMap/subcomponents/TileLayers/subcomponents/TileLayerGoogle/darkStyles.d.ts +13 -0
- package/components/maps/components/GpsMap/subcomponents/TileLayers/subcomponents/TileLayerGoogle/index.js +82 -59
- package/components/maps/components/GpsMap/subcomponents/TileLayers/subcomponents/TileLayerOthers/index.js +25 -15
- package/components/maps/components/GpsMap/types.d.ts +24 -5
- package/components/maps/components/GpsMapTools/GpsMapTools.d.ts +1 -0
- package/components/maps/components/GpsMapTools/index.d.ts +1 -0
- package/components/maps/components/GpsMapTools/subcomponents/TabsGpsTools/index.js +1 -1
- package/components/maps/components/GpsMapTools/subcomponents/TabsGpsTools/subcomponents/GeofencesList/hooks/useColumns.js +29 -32
- package/components/maps/components/GpsMapTools/types.d.ts +0 -16
- package/components/maps/index.d.ts +1 -0
- package/components/maps/utils/coordsToQuadKey.d.ts +4 -0
- package/components/maps/{components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/MapSourcesTool/sourceTypes/utils.js → utils/coordsToQuadKey.js} +2 -2
- package/components/maps/utils/index.d.ts +1 -0
- package/contexts/RealTimeConsumerContext/RealTimeConsumerContext.js +1 -1
- package/contexts/RealTimeProducerContext/sourceDataMechanisms/athmospherejs/index.d.ts +1 -1
- package/contexts/RealTimeProducerContext/sourceDataMechanisms/athmospherejs/index.js +1 -1
- package/contexts/RealTimeProducerContext/sourceDataMechanisms/dummy/constants.d.ts +67 -2
- package/contexts/RealTimeProducerContext/sourceDataMechanisms/dummy/constants.js +115 -30
- package/contexts/RealTimeProducerContext/sourceDataMechanisms/dummy/dummy.js +5 -38
- package/contexts/RealTimeProducerContext/sourceDataMechanisms/dummy/group.d.ts +9 -36
- package/contexts/RealTimeProducerContext/sourceDataMechanisms/dummy/group.js +27 -19
- package/contexts/RealTimeProducerContext/sourceDataMechanisms/dummy/helpers.d.ts +3 -2
- package/contexts/RealTimeProducerContext/sourceDataMechanisms/dummy/helpers.js +9 -2
- package/contexts/RealTimeProducerContext/sourceDataMechanisms/factory.js +1 -1
- package/formatters/CourseFormatter/CourseFormatter.js +6 -4
- package/formatters/CourseFormatter/helper.d.ts +2 -1
- package/formatters/CourseFormatter/helper.js +2 -4
- package/formatters/CourseFormatter/index.d.ts +1 -0
- package/formatters/CourseFormatter/slots/CourseFormatterSlots.d.ts +1 -1
- package/formatters/CourseFormatter/slots/CourseFormatterSlots.js +2 -2
- package/formatters/index.js +1 -0
- package/index.d.ts +1 -0
- package/index.js +94 -59
- package/package.json +16 -3
- package/utils/cssToCSSProperties.d.ts +37 -0
- package/utils/getPrecisionFromHdop/constants.d.ts +13 -0
- package/utils/getPrecisionFromHdop/constants.js +73 -0
- package/utils/getPrecisionFromHdop/getPrecisionFromHdop.d.ts +31 -0
- package/utils/getPrecisionFromHdop/getPrecisionFromHdop.js +59 -0
- package/utils/getPrecisionFromHdop/index.d.ts +3 -0
- package/utils/getPrecisionFromHdop/index.js +1 -0
- package/utils/getPrecisionFromHdop/types.d.ts +42 -0
- package/utils/getVptUpdatedAtWithGuard.d.ts +4 -0
- package/utils/getVptUpdatedAtWithGuard.js +13 -0
- package/utils/getVptValueWithGuard.d.ts +9 -0
- package/utils/getVptValueWithGuard.js +18 -0
- package/utils/index.d.ts +3 -0
- package/components/DeviceStatus/hooks/constants.d.ts +0 -11
- package/components/maps/components/GpsMap/external/Control/types.d.ts +0 -7
- package/components/maps/components/GpsMap/featureRenders/DeviceFeatureRender/constants.js +0 -4
- package/components/maps/components/GpsMap/featureRenders/DeviceFeatureRender/index.js +0 -112
- package/components/maps/components/GpsMap/hooks/useDisableZoomEvents/index.d.ts +0 -6
- package/components/maps/components/GpsMap/slots/GpsMapSlots.d.ts +0 -4
- package/components/maps/components/GpsMap/slots/GpsMapSlots.js +0 -24
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/index.js +0 -13
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/index.d.ts +0 -10
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/index.js +0 -58
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/LayersTool/hooks/useCheckedLayers.d.ts +0 -9
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/LayersTool/hooks/useCheckedLayers.js +0 -17
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/LayersTool/hooks/useColumns.d.ts +0 -18
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/LayersTool/hooks/useColumns.js +0 -139
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/LayersTool/hooks/useMaster.d.ts +0 -12
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/LayersTool/hooks/useMaster.js +0 -52
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/LayersTool/hooks/useRowActionsGetter.d.ts +0 -8
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/LayersTool/hooks/useRowActionsGetter.js +0 -43
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/LayersTool/index.d.ts +0 -4
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/LayersTool/index.js +0 -30
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/LayersTool/model.d.ts +0 -26
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/MapSourcesTool/index.js +0 -133
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/MapSourcesTool/sourceTypes/bing.d.ts +0 -2
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/MapSourcesTool/sourceTypes/bing.js +0 -39
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/MapSourcesTool/sourceTypes/google.d.ts +0 -4
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/MapSourcesTool/sourceTypes/google.js +0 -73
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/MapSourcesTool/sourceTypes/osm.d.ts +0 -2
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/MapSourcesTool/sourceTypes/osm.js +0 -25
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/subcomponentes/MapSourcesTool/sourceTypes/utils.d.ts +0 -4
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopLeftTools/subcomponents/PopoverToolButton/types.d.ts +0 -4
- package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/index.js +0 -40
- /package/components/{maps/components/GpsMap/contexts/MapContext/helper.js → Device/index.js} +0 -0
- /package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/{TopRigthTools → BottomRigthTools}/subcomponents/ZoomButtons/index.d.ts +0 -0
- /package/components/maps/components/GpsMap/subcomponents/Controls/subcomponents/TopRigthTools/subcomponents/MeasureTool/{index.d.ts → MeasureTool.d.ts} +0 -0
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare const DeviceRootStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
|
|
2
|
+
ownerState: Partial<import('../types').DeviceOwnerState> & Record<string, unknown>;
|
|
3
|
+
}, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
|
|
4
|
+
export declare const DeviceStatusIconStyled: import('@emotion/styled').StyledComponent<Pick<import('@m4l/components').IconProps, keyof import('@m4l/components').IconProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
|
|
5
|
+
ownerState: Partial<import('../types').DeviceOwnerState> & Record<string, unknown>;
|
|
6
|
+
}, {}, {}>;
|
|
7
|
+
export declare const DeviceStatusRigthContainerStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
|
|
8
|
+
ownerState: Partial<import('../types').DeviceOwnerState> & Record<string, unknown>;
|
|
9
|
+
}, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
|
|
10
|
+
export declare const DeviceTitleContainerStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
|
|
11
|
+
ownerState: Partial<import('../types').DeviceOwnerState> & Record<string, unknown>;
|
|
12
|
+
}, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
|
|
13
|
+
export declare const DeviceStatusLabelStyled: import('@emotion/styled').StyledComponent<Pick<import('@m4l/components/src/components/mui_extended/Typography/types').TypographyProps, keyof import('@m4l/components/src/components/mui_extended/Typography/types').TypographyProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
|
|
14
|
+
ownerState: Partial<import('../types').DeviceOwnerState> & Record<string, unknown>;
|
|
15
|
+
}, {}, {}>;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { styled } from "@mui/material/styles";
|
|
2
|
+
import { C as COMPONET_DEVICE_KEY_COMPONENT } from "../constants.js";
|
|
3
|
+
import { d as deviceStatusStyles } from "../Device.styles.js";
|
|
4
|
+
import { D as DeviceSlots } from "./slots.js";
|
|
5
|
+
import { Icon, Typography } from "@m4l/components";
|
|
6
|
+
const DeviceRootStyled = styled("div", {
|
|
7
|
+
name: COMPONET_DEVICE_KEY_COMPONENT,
|
|
8
|
+
slot: DeviceSlots.root
|
|
9
|
+
})(deviceStatusStyles?.root);
|
|
10
|
+
const DeviceStatusIconStyled = styled(Icon, {
|
|
11
|
+
name: COMPONET_DEVICE_KEY_COMPONENT,
|
|
12
|
+
slot: DeviceSlots.statusIcon
|
|
13
|
+
})(deviceStatusStyles?.statusIcon);
|
|
14
|
+
const DeviceStatusRigthContainerStyled = styled("div", {
|
|
15
|
+
name: COMPONET_DEVICE_KEY_COMPONENT,
|
|
16
|
+
slot: DeviceSlots.statusRigthContainer
|
|
17
|
+
})(deviceStatusStyles?.statusRigthContainer);
|
|
18
|
+
const DeviceTitleContainerStyled = styled("div", {
|
|
19
|
+
name: COMPONET_DEVICE_KEY_COMPONENT,
|
|
20
|
+
slot: DeviceSlots.titleContainer
|
|
21
|
+
})(deviceStatusStyles?.titleContainer);
|
|
22
|
+
const DeviceStatusLabelStyled = styled(Typography, {
|
|
23
|
+
name: COMPONET_DEVICE_KEY_COMPONENT,
|
|
24
|
+
slot: DeviceSlots.statusLabel
|
|
25
|
+
})(deviceStatusStyles?.statusLabel);
|
|
26
|
+
export {
|
|
27
|
+
DeviceRootStyled as D,
|
|
28
|
+
DeviceStatusIconStyled as a,
|
|
29
|
+
DeviceStatusRigthContainerStyled as b,
|
|
30
|
+
DeviceTitleContainerStyled as c,
|
|
31
|
+
DeviceStatusLabelStyled as d
|
|
32
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
var DeviceSlots = /* @__PURE__ */ ((DeviceSlots2) => {
|
|
2
|
+
DeviceSlots2["root"] = "root";
|
|
3
|
+
DeviceSlots2["statusIcon"] = "statusIcon";
|
|
4
|
+
DeviceSlots2["statusRigthContainer"] = "statusRigthContainer";
|
|
5
|
+
DeviceSlots2["titleContainer"] = "titleContainer";
|
|
6
|
+
DeviceSlots2["statusLabel"] = "statusLabel";
|
|
7
|
+
return DeviceSlots2;
|
|
8
|
+
})(DeviceSlots || {});
|
|
9
|
+
export {
|
|
10
|
+
DeviceSlots as D
|
|
11
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { DeviceSlots } from './slots/slots';
|
|
2
|
+
import { COMPONET_DEVICE_KEY_COMPONENT } from './constants';
|
|
3
|
+
import { Theme } from '@mui/material/styles';
|
|
4
|
+
import { DeviceDataType } from '../../@types';
|
|
5
|
+
import { M4LOverridesStyleRules } from '../../@types/augmentations';
|
|
6
|
+
import { ChipColorOptions, Sizes } from '@m4l/styles';
|
|
7
|
+
import { IconColorDeep } from '@m4l/components';
|
|
8
|
+
export interface DeviceProps {
|
|
9
|
+
variant?: 'withStatus' | 'withId';
|
|
10
|
+
deviceData: DeviceDataType;
|
|
11
|
+
size?: Sizes;
|
|
12
|
+
}
|
|
13
|
+
export type useDeviceProps = Pick<DeviceProps, 'deviceData' | 'variant'> & {
|
|
14
|
+
withLabel?: boolean;
|
|
15
|
+
};
|
|
16
|
+
export type useDeviceStatusProps = Pick<DeviceProps, 'deviceData'> & {
|
|
17
|
+
withLabel?: boolean;
|
|
18
|
+
};
|
|
19
|
+
export type DeviceSlotsType = keyof typeof DeviceSlots;
|
|
20
|
+
export type DeviceOwnerState = {
|
|
21
|
+
iconKey: string;
|
|
22
|
+
size: Sizes;
|
|
23
|
+
variant: 'withStatus' | 'withId';
|
|
24
|
+
/**
|
|
25
|
+
* Color compatible con chip para reestilar el typography
|
|
26
|
+
*/
|
|
27
|
+
color: IconColorDeep;
|
|
28
|
+
palletColor?: ChipColorOptions;
|
|
29
|
+
};
|
|
30
|
+
export type DeviceStyles = M4LOverridesStyleRules<DeviceSlotsType, typeof COMPONET_DEVICE_KEY_COMPONENT, Theme>;
|
|
@@ -8,7 +8,7 @@ const regex = /#[^#]+#/g;
|
|
|
8
8
|
const DeviceLabel = (props) => {
|
|
9
9
|
const { deviceData, labelTemplate = "#settings.name# #resourceSerialId#", withImage, className } = props;
|
|
10
10
|
const { host_static_assets, environment_assets } = useEnvironment();
|
|
11
|
-
const src = `${host_static_assets}/${environment_assets}/frontend/components/device/assets/images/${deviceData?.settings?.
|
|
11
|
+
const src = `${host_static_assets}/${environment_assets}/frontend/components/device/assets/images/${deviceData?.settings?.iconId}`;
|
|
12
12
|
let label = labelTemplate;
|
|
13
13
|
const matches = label.match(regex);
|
|
14
14
|
if (matches) {
|
|
@@ -1,3 +1,9 @@
|
|
|
1
|
-
export declare const DeviceRootStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
export declare const DeviceRootStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
|
|
2
|
+
ownerState?: (Partial<import('../../Device/types').DeviceOwnerState> & Record<string, unknown>) | undefined;
|
|
3
|
+
}, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
|
|
4
|
+
export declare const ImageStyled: import('@emotion/styled').StyledComponent<Pick<import('@m4l/components/src/components/Image').ImageProps, keyof import('@m4l/components/src/components/Image').ImageProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
|
|
5
|
+
ownerState?: (Partial<import('../../Device/types').DeviceOwnerState> & Record<string, unknown>) | undefined;
|
|
6
|
+
}, {}, {}>;
|
|
7
|
+
export declare const LabelStyled: import('@emotion/styled').StyledComponent<Pick<import('@m4l/components/src/components/mui_extended/Typography/types').TypographyProps, keyof import('@m4l/components/src/components/mui_extended/Typography/types').TypographyProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material/styles').Theme> & Record<string, unknown> & {
|
|
8
|
+
ownerState?: (Partial<import('../../Device/types').DeviceOwnerState> & Record<string, unknown>) | undefined;
|
|
9
|
+
}, {}, {}>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { OverridesStyleRules } from '@mui/material/styles/overrides';
|
|
2
1
|
import { DeviceSlots } from './slots/slots';
|
|
3
2
|
import { COMPONET_KEY_COMPONENT } from './constants';
|
|
4
3
|
import { Theme } from '@mui/material/styles';
|
|
5
4
|
import { DeviceDataType } from '../../@types';
|
|
5
|
+
import { M4LOverridesStyleRules } from '@m4l/components';
|
|
6
6
|
export type DeviceProps = {
|
|
7
7
|
/**
|
|
8
8
|
* Plantilla de la etiqueta que se muestra en el componente.
|
|
@@ -23,4 +23,4 @@ export type DeviceProps = {
|
|
|
23
23
|
};
|
|
24
24
|
export type DeviceSlotsType = keyof typeof DeviceSlots;
|
|
25
25
|
export type DeviceOwnerState = {};
|
|
26
|
-
export type DeviceStyles =
|
|
26
|
+
export type DeviceStyles = M4LOverridesStyleRules<DeviceSlotsType, typeof COMPONET_KEY_COMPONENT, Theme>;
|
|
@@ -1,15 +1,3 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import { Icon } from "@m4l/components";
|
|
5
|
-
import { u as useDeviceStatus } from "./hooks/useDeviceStatus.js";
|
|
6
|
-
const DeviceStatus = (props) => {
|
|
7
|
-
const { deviceData } = props;
|
|
8
|
-
const { host_static_assets, environment_assets } = useEnvironment();
|
|
9
|
-
const { iconKey, color } = useDeviceStatus({ deviceData });
|
|
10
|
-
const src = `${host_static_assets}/${environment_assets}/frontend/components/device_status/assets/icons/${iconKey}.svg`;
|
|
11
|
-
return /* @__PURE__ */ jsx(DeviceStatusRootStyled, { ownerState: { iconKey }, children: /* @__PURE__ */ jsx(Icon, { src, color }) });
|
|
12
|
-
};
|
|
13
|
-
export {
|
|
14
|
-
DeviceStatus as D
|
|
15
|
-
};
|
|
1
|
+
import "react/jsx-runtime";
|
|
2
|
+
import "@m4l/core";
|
|
3
|
+
import "@m4l/components";
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
export declare const MDS_DICTIONARY_ID = "
|
|
1
|
+
export declare const MDS_DICTIONARY_ID = "device";
|
|
2
2
|
export declare function getDeviceStatusComponentsDictionary(): string[];
|
|
3
3
|
export declare const MDS_DICTIONARY: {
|
|
4
|
-
readonly LABEL_OFF: "
|
|
5
|
-
readonly LABEL_MOVING: "
|
|
6
|
-
readonly LABEL_STOPPED: "
|
|
7
|
-
readonly LABEL_STOPPED_RALENTI: "
|
|
8
|
-
readonly LABEL_STOPPED_E_RALENTI: "
|
|
9
|
-
readonly LABEL_TOWING: "
|
|
10
|
-
readonly LABEL_NO_GPS_SIGNAL: "
|
|
11
|
-
readonly LABEL_POWER_SAVING: "
|
|
12
|
-
readonly LABEL_MAX_SPEED: "
|
|
4
|
+
readonly LABEL_OFF: "device.label_off";
|
|
5
|
+
readonly LABEL_MOVING: "device.label_moving";
|
|
6
|
+
readonly LABEL_STOPPED: "device.label_stopped";
|
|
7
|
+
readonly LABEL_STOPPED_RALENTI: "device.label_stopped_ralenti";
|
|
8
|
+
readonly LABEL_STOPPED_E_RALENTI: "device.label_stopped_e_ralenti";
|
|
9
|
+
readonly LABEL_TOWING: "device.label_towing";
|
|
10
|
+
readonly LABEL_NO_GPS_SIGNAL: "device.label_no_gps_signal";
|
|
11
|
+
readonly LABEL_POWER_SAVING: "device.label_power_saving";
|
|
12
|
+
readonly LABEL_MAX_SPEED: "device.label_max_speed";
|
|
13
13
|
};
|
|
@@ -1,18 +1,7 @@
|
|
|
1
|
-
const MDS_DICTIONARY_ID = "
|
|
1
|
+
const MDS_DICTIONARY_ID = "device";
|
|
2
2
|
function getDeviceStatusComponentsDictionary() {
|
|
3
3
|
return [MDS_DICTIONARY_ID].concat();
|
|
4
4
|
}
|
|
5
|
-
const MDS_DICTIONARY = {
|
|
6
|
-
LABEL_OFF: `${MDS_DICTIONARY_ID}.label_off`,
|
|
7
|
-
LABEL_MOVING: `${MDS_DICTIONARY_ID}.label_moving`,
|
|
8
|
-
LABEL_STOPPED: `${MDS_DICTIONARY_ID}.label_stopped`,
|
|
9
|
-
LABEL_STOPPED_RALENTI: `${MDS_DICTIONARY_ID}.label_stopped_ralenti`,
|
|
10
|
-
LABEL_STOPPED_E_RALENTI: `${MDS_DICTIONARY_ID}.label_stopped_e_ralenti`,
|
|
11
|
-
LABEL_TOWING: `${MDS_DICTIONARY_ID}.label_towing`,
|
|
12
|
-
LABEL_POWER_SAVING: `${MDS_DICTIONARY_ID}.label_power_saving`,
|
|
13
|
-
LABEL_MAX_SPEED: `${MDS_DICTIONARY_ID}.label_max_speed`
|
|
14
|
-
};
|
|
15
5
|
export {
|
|
16
|
-
MDS_DICTIONARY as M,
|
|
17
6
|
getDeviceStatusComponentsDictionary as g
|
|
18
7
|
};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export * from './DeviceStatus';
|
|
2
2
|
export { getDeviceStatusComponentsDictionary } from './dictionary';
|
|
3
|
-
export { getDeviceStatusByData } from '
|
|
4
|
-
export { DEVICE_STATUSES_CONFIG } from '
|
|
3
|
+
export { getDeviceStatusByData } from '../Device/helpers/helperDeviceStatus';
|
|
4
|
+
export { DEVICE_STATUSES_CONFIG } from '../Device/hooks/constants';
|
|
5
|
+
export { useDeviceStatus } from '../Device/hooks/useDeviceStatus';
|
|
@@ -1,11 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { C as COMPONET_KEY_COMPONENT } from "../constants.js";
|
|
3
|
-
import { d as deviceStatusStyles } from "../DeviceStatus.styles.js";
|
|
4
|
-
import { D as DeviceStatusSlots } from "./slots.js";
|
|
5
|
-
const DeviceStatusRootStyled = styled("div", {
|
|
6
|
-
name: COMPONET_KEY_COMPONENT,
|
|
7
|
-
slot: DeviceStatusSlots.root
|
|
8
|
-
})(deviceStatusStyles?.root);
|
|
9
|
-
export {
|
|
10
|
-
DeviceStatusRootStyled as D
|
|
11
|
-
};
|
|
1
|
+
import "@mui/material/styles";
|
package/components/index.d.ts
CHANGED
|
@@ -4,11 +4,11 @@ const indicatorBatteryStyles = {
|
|
|
4
4
|
* Contenedor del indicador de batería
|
|
5
5
|
*/
|
|
6
6
|
root: ({ theme }) => ({
|
|
7
|
-
width:
|
|
7
|
+
// width: 'fit-content',
|
|
8
8
|
display: "flex",
|
|
9
9
|
flexDirection: "column",
|
|
10
10
|
gap: theme.vars.size.baseSpacings.sp2,
|
|
11
|
-
backgroundColor: theme.vars.palette
|
|
11
|
+
backgroundColor: theme.vars.palette?.background.base
|
|
12
12
|
}),
|
|
13
13
|
/**
|
|
14
14
|
* Título del indicador de batería
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
const INDICATOR_BATTERY_DICTIONARY_KEY = "indicator_battery";
|
|
2
|
+
const getIndicatorBatteryComponentsDictionary = () => {
|
|
3
|
+
return [INDICATOR_BATTERY_DICTIONARY_KEY];
|
|
4
|
+
};
|
|
2
5
|
const INDICATOR_BATTERY_DICTIONARY = {
|
|
3
6
|
titleMain: `${INDICATOR_BATTERY_DICTIONARY_KEY}.title_main`,
|
|
4
7
|
titleBackup: `${INDICATOR_BATTERY_DICTIONARY_KEY}.title_backup`,
|
|
@@ -12,5 +15,6 @@ const INDICATOR_BATTERY_DICTIONARY = {
|
|
|
12
15
|
statusOverVoltage: `${INDICATOR_BATTERY_DICTIONARY_KEY}.label_status_over_voltage`
|
|
13
16
|
};
|
|
14
17
|
export {
|
|
15
|
-
INDICATOR_BATTERY_DICTIONARY as I
|
|
18
|
+
INDICATOR_BATTERY_DICTIONARY as I,
|
|
19
|
+
getIndicatorBatteryComponentsDictionary as g
|
|
16
20
|
};
|
|
@@ -2,17 +2,19 @@ import { jsxs, jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import { useModuleDictionary } from "@m4l/core";
|
|
3
3
|
import { g as getQualityLabel } from "./helpers/getQualityLabel/getQualityLabel.js";
|
|
4
4
|
import { I as IndicatorCSQRootStyled, C as ContainerTitleAndChipStyled, T as TitleStyled, a as ChipStyled } from "./slots/IndicatorCSQSlots.js";
|
|
5
|
-
import {
|
|
5
|
+
import { I as INDICATOR_CSQ_DICTIONARY } from "./dictionary.js";
|
|
6
|
+
import { I as INDICATOR_CSQ_CLASSES } from "./constants.js";
|
|
7
|
+
import clsx from "clsx";
|
|
6
8
|
import { S as SignalIcon } from "./subcomponents/SignalIcon/SignalIcon.js";
|
|
7
9
|
const IndicatorCSQ = (props) => {
|
|
8
|
-
const { value, size } = props;
|
|
10
|
+
const { value, size, className } = props;
|
|
9
11
|
const { getLabel } = useModuleDictionary();
|
|
10
12
|
const { labelQuality, color, percentage } = getQualityLabel({ getLabel, quality: value });
|
|
11
|
-
return /* @__PURE__ */ jsxs(IndicatorCSQRootStyled, { role: "status", "aria-label": "CSQ Signal", children: [
|
|
13
|
+
return /* @__PURE__ */ jsxs(IndicatorCSQRootStyled, { className: clsx(className, INDICATOR_CSQ_CLASSES.root), role: "status", "aria-label": "CSQ Signal", children: [
|
|
12
14
|
/* @__PURE__ */ jsx(SignalIcon, { percentage, size }),
|
|
13
15
|
/* @__PURE__ */ jsxs(ContainerTitleAndChipStyled, { children: [
|
|
14
|
-
/* @__PURE__ */ jsx(TitleStyled, { variant: "paragraphDens", children: getLabel(
|
|
15
|
-
/* @__PURE__ */ jsx(ChipStyled, { label: `${value} - ${labelQuality}
|
|
16
|
+
/* @__PURE__ */ jsx(TitleStyled, { variant: "paragraphDens", children: getLabel(INDICATOR_CSQ_DICTIONARY.LABEL_CSQ_TITLE) }),
|
|
17
|
+
/* @__PURE__ */ jsx(ChipStyled, { label: value !== null && value !== void 0 ? `${value} - ${labelQuality}` : labelQuality, variant: "contained", color })
|
|
16
18
|
] })
|
|
17
19
|
] });
|
|
18
20
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Key component for the CSQSignal component
|
|
3
3
|
*/
|
|
4
|
-
export declare const
|
|
4
|
+
export declare const INDICATOR_CSQ_KEY_COMPONENT = "M4LCSQSignal";
|
|
5
5
|
/**
|
|
6
6
|
* Classes for the CSQSignal component
|
|
7
7
|
*/
|
|
8
|
-
export declare const
|
|
8
|
+
export declare const INDICATOR_CSQ_CLASSES: Record<string, string>;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { getComponentClasses } from "@m4l/components";
|
|
2
2
|
import { I as IndicatorCSQSlots } from "./slots/IndicatorCSQEnum.js";
|
|
3
|
-
const
|
|
4
|
-
getComponentClasses(
|
|
3
|
+
const INDICATOR_CSQ_KEY_COMPONENT = "M4LCSQSignal";
|
|
4
|
+
const INDICATOR_CSQ_CLASSES = getComponentClasses(INDICATOR_CSQ_KEY_COMPONENT, IndicatorCSQSlots);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
INDICATOR_CSQ_CLASSES as I,
|
|
7
|
+
INDICATOR_CSQ_KEY_COMPONENT as a
|
|
7
8
|
};
|
|
@@ -1,7 +1,10 @@
|
|
|
1
|
-
export declare const
|
|
2
|
-
export declare const
|
|
1
|
+
export declare const getIndicatorCSQComponentsDictionary: () => string[];
|
|
2
|
+
export declare const INDICATOR_CSQ_DICTIONARY: {
|
|
3
3
|
readonly LABEL_CSQ_TITLE: "indicator_csq.label_csq_title";
|
|
4
|
+
readonly LABEL_QUALITY_NOT_AVAILABLE: "indicator_csq.label_quality_not_available";
|
|
4
5
|
readonly LABEL_QUALITY_NOT_DETECTABLE: "indicator_csq.label_quality_not_detectable";
|
|
6
|
+
readonly LABEL_QUALITY_NOT_SIGNAL: "indicator_csq.label_quality_not_signal";
|
|
7
|
+
readonly LABEL_QUALITY_VERY_WEAK: "indicator_csq.label_quality_very_weak";
|
|
5
8
|
readonly LABEL_QUALITY_WEAK: "indicator_csq.label_quality_weak";
|
|
6
9
|
readonly LABEL_QUALITY_ACCEPTABLE: "indicator_csq.label_quality_acceptable";
|
|
7
10
|
readonly LABEL_QUALITY_GOOD: "indicator_csq.label_quality_good";
|
|
@@ -1,16 +1,19 @@
|
|
|
1
|
-
const
|
|
2
|
-
const
|
|
3
|
-
return [
|
|
1
|
+
const INDICATOR_CSQ_KEY_DICTIONARY = "indicator_csq";
|
|
2
|
+
const getIndicatorCSQComponentsDictionary = () => {
|
|
3
|
+
return [INDICATOR_CSQ_KEY_DICTIONARY];
|
|
4
4
|
};
|
|
5
|
-
const
|
|
6
|
-
LABEL_CSQ_TITLE: `${
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
5
|
+
const INDICATOR_CSQ_DICTIONARY = {
|
|
6
|
+
LABEL_CSQ_TITLE: `${INDICATOR_CSQ_KEY_DICTIONARY}.label_csq_title`,
|
|
7
|
+
LABEL_QUALITY_NOT_AVAILABLE: `${INDICATOR_CSQ_KEY_DICTIONARY}.label_quality_not_available`,
|
|
8
|
+
LABEL_QUALITY_NOT_DETECTABLE: `${INDICATOR_CSQ_KEY_DICTIONARY}.label_quality_not_detectable`,
|
|
9
|
+
LABEL_QUALITY_NOT_SIGNAL: `${INDICATOR_CSQ_KEY_DICTIONARY}.label_quality_not_signal`,
|
|
10
|
+
LABEL_QUALITY_VERY_WEAK: `${INDICATOR_CSQ_KEY_DICTIONARY}.label_quality_very_weak`,
|
|
11
|
+
LABEL_QUALITY_WEAK: `${INDICATOR_CSQ_KEY_DICTIONARY}.label_quality_weak`,
|
|
12
|
+
LABEL_QUALITY_ACCEPTABLE: `${INDICATOR_CSQ_KEY_DICTIONARY}.label_quality_acceptable`,
|
|
13
|
+
LABEL_QUALITY_GOOD: `${INDICATOR_CSQ_KEY_DICTIONARY}.label_quality_good`,
|
|
14
|
+
LABEL_QUALITY_EXCELLENT: `${INDICATOR_CSQ_KEY_DICTIONARY}.label_quality_excellent`
|
|
12
15
|
};
|
|
13
16
|
export {
|
|
14
|
-
|
|
15
|
-
|
|
17
|
+
INDICATOR_CSQ_DICTIONARY as I,
|
|
18
|
+
getIndicatorCSQComponentsDictionary as g
|
|
16
19
|
};
|
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
import { GetQualityLabelProps, GetQualityLabelReturn } from './types';
|
|
2
2
|
export declare const QUALITY_RANGES: readonly [{
|
|
3
|
+
readonly min: 0;
|
|
4
|
+
readonly max: 0;
|
|
5
|
+
readonly value: "indicator_csq.label_quality_not_signal";
|
|
6
|
+
readonly color: "error";
|
|
7
|
+
readonly percentage: 0;
|
|
8
|
+
}, {
|
|
9
|
+
readonly min: 1;
|
|
10
|
+
readonly max: 1;
|
|
11
|
+
readonly value: "indicator_csq.label_quality_very_weak";
|
|
12
|
+
readonly color: "error";
|
|
13
|
+
readonly percentage: 0;
|
|
14
|
+
}, {
|
|
3
15
|
readonly min: 2;
|
|
4
16
|
readonly max: 9;
|
|
5
17
|
readonly value: "indicator_csq.label_quality_weak";
|
|
@@ -19,10 +31,16 @@ export declare const QUALITY_RANGES: readonly [{
|
|
|
19
31
|
readonly percentage: 75;
|
|
20
32
|
}, {
|
|
21
33
|
readonly min: 20;
|
|
22
|
-
readonly max:
|
|
34
|
+
readonly max: 31;
|
|
23
35
|
readonly value: "indicator_csq.label_quality_excellent";
|
|
24
36
|
readonly color: "persianGreen";
|
|
25
37
|
readonly percentage: 100;
|
|
38
|
+
}, {
|
|
39
|
+
readonly min: 32;
|
|
40
|
+
readonly max: number;
|
|
41
|
+
readonly value: "indicator_csq.label_quality_not_detectable";
|
|
42
|
+
readonly color: "error";
|
|
43
|
+
readonly percentage: 0;
|
|
26
44
|
}];
|
|
27
45
|
/**
|
|
28
46
|
* Get quality label based on CSQ signal quality value
|
|
@@ -30,7 +48,9 @@ export declare const QUALITY_RANGES: readonly [{
|
|
|
30
48
|
* @returns quality label string
|
|
31
49
|
*
|
|
32
50
|
* Quality ranges:
|
|
33
|
-
* -
|
|
51
|
+
* - null / undefined / NaN: not available
|
|
52
|
+
* - 0: Not signal
|
|
53
|
+
* - 1: Very weak
|
|
34
54
|
* - 2-9: Weak
|
|
35
55
|
* - 10-14: Acceptable
|
|
36
56
|
* - 15-19: Good
|
|
@@ -1,41 +1,27 @@
|
|
|
1
|
-
import {
|
|
2
|
-
const SPECIAL_QUALITY_VALUES = [0, 1, 99];
|
|
3
|
-
const DEFAULT_QUALITY_LABEL = CSQ_SIGNAL_DICTIONARY.LABEL_QUALITY_NOT_DETECTABLE;
|
|
1
|
+
import { I as INDICATOR_CSQ_DICTIONARY } from "../../dictionary.js";
|
|
4
2
|
const QUALITY_RANGES = [
|
|
5
|
-
{ min:
|
|
6
|
-
{ min:
|
|
7
|
-
{ min:
|
|
8
|
-
{ min:
|
|
3
|
+
{ min: 0, max: 0, value: INDICATOR_CSQ_DICTIONARY.LABEL_QUALITY_NOT_SIGNAL, color: "error", percentage: 0 },
|
|
4
|
+
{ min: 1, max: 1, value: INDICATOR_CSQ_DICTIONARY.LABEL_QUALITY_VERY_WEAK, color: "error", percentage: 0 },
|
|
5
|
+
{ min: 2, max: 9, value: INDICATOR_CSQ_DICTIONARY.LABEL_QUALITY_WEAK, color: "orange", percentage: 25 },
|
|
6
|
+
{ min: 10, max: 14, value: INDICATOR_CSQ_DICTIONARY.LABEL_QUALITY_ACCEPTABLE, color: "warning", percentage: 50 },
|
|
7
|
+
{ min: 15, max: 19, value: INDICATOR_CSQ_DICTIONARY.LABEL_QUALITY_GOOD, color: "info", percentage: 75 },
|
|
8
|
+
{ min: 20, max: 31, value: INDICATOR_CSQ_DICTIONARY.LABEL_QUALITY_EXCELLENT, color: "persianGreen", percentage: 100 },
|
|
9
|
+
{ min: 32, max: Infinity, value: INDICATOR_CSQ_DICTIONARY.LABEL_QUALITY_NOT_DETECTABLE, color: "error", percentage: 0 }
|
|
9
10
|
];
|
|
10
11
|
const getQualityLabel = (props) => {
|
|
11
12
|
const { getLabel, quality } = props;
|
|
12
|
-
if (quality === null || quality === void 0) {
|
|
13
|
+
if (quality === null || quality === void 0 || isNaN(quality)) {
|
|
13
14
|
return {
|
|
14
|
-
labelQuality: getLabel(
|
|
15
|
-
color: "
|
|
15
|
+
labelQuality: getLabel(INDICATOR_CSQ_DICTIONARY.LABEL_QUALITY_NOT_AVAILABLE),
|
|
16
|
+
color: "default",
|
|
16
17
|
percentage: 0
|
|
17
18
|
};
|
|
18
19
|
}
|
|
19
|
-
const
|
|
20
|
-
if (isNaN(key)) {
|
|
21
|
-
return {
|
|
22
|
-
labelQuality: getLabel(DEFAULT_QUALITY_LABEL),
|
|
23
|
-
color: "error",
|
|
24
|
-
percentage: 0
|
|
25
|
-
};
|
|
26
|
-
}
|
|
27
|
-
if (SPECIAL_QUALITY_VALUES.includes(key)) {
|
|
28
|
-
return {
|
|
29
|
-
labelQuality: getLabel(DEFAULT_QUALITY_LABEL),
|
|
30
|
-
color: "error",
|
|
31
|
-
percentage: 0
|
|
32
|
-
};
|
|
33
|
-
}
|
|
34
|
-
const qualityRange = QUALITY_RANGES.find((range) => key >= range.min && key <= range.max);
|
|
20
|
+
const qualityRange = QUALITY_RANGES.find((range) => quality >= range.min && quality <= range.max) ?? QUALITY_RANGES[QUALITY_RANGES.length - 1];
|
|
35
21
|
return {
|
|
36
|
-
labelQuality: getLabel(qualityRange
|
|
37
|
-
color: qualityRange
|
|
38
|
-
percentage: qualityRange
|
|
22
|
+
labelQuality: getLabel(qualityRange.value),
|
|
23
|
+
color: qualityRange.color,
|
|
24
|
+
percentage: qualityRange.percentage
|
|
39
25
|
};
|
|
40
26
|
};
|
|
41
27
|
export {
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { IndicatorCSQ
|
|
2
|
-
export type { IndicatorCSQProps
|
|
3
|
-
export {
|
|
1
|
+
export { IndicatorCSQ } from './IndicatorCSQ';
|
|
2
|
+
export type { IndicatorCSQProps } from './types';
|
|
3
|
+
export { getIndicatorCSQComponentsDictionary } from './dictionary';
|
|
@@ -1,26 +1,26 @@
|
|
|
1
1
|
import { I as IndicatorCSQSlots } from "./IndicatorCSQEnum.js";
|
|
2
2
|
import { i as indicatorCSQStyles } from "../IndicatorCSQ.styles.js";
|
|
3
|
-
import {
|
|
3
|
+
import { a as INDICATOR_CSQ_KEY_COMPONENT } from "../constants.js";
|
|
4
4
|
import { Typography, Chip } from "@m4l/components";
|
|
5
5
|
import { styled } from "@mui/material/styles";
|
|
6
6
|
const IndicatorCSQRootStyled = styled("div", {
|
|
7
|
-
name:
|
|
7
|
+
name: INDICATOR_CSQ_KEY_COMPONENT,
|
|
8
8
|
slot: IndicatorCSQSlots.root
|
|
9
9
|
})(indicatorCSQStyles?.root);
|
|
10
10
|
const SignalIconStyled = styled("svg", {
|
|
11
|
-
name:
|
|
11
|
+
name: INDICATOR_CSQ_KEY_COMPONENT,
|
|
12
12
|
slot: IndicatorCSQSlots.signalIcon
|
|
13
13
|
})(indicatorCSQStyles?.signalIcon);
|
|
14
14
|
const ContainerTitleAndChipStyled = styled("div", {
|
|
15
|
-
name:
|
|
15
|
+
name: INDICATOR_CSQ_KEY_COMPONENT,
|
|
16
16
|
slot: IndicatorCSQSlots.containerTitleAndChip
|
|
17
17
|
})(indicatorCSQStyles?.containerTitleAndChip);
|
|
18
18
|
const TitleStyled = styled(Typography, {
|
|
19
|
-
name:
|
|
19
|
+
name: INDICATOR_CSQ_KEY_COMPONENT,
|
|
20
20
|
slot: IndicatorCSQSlots.title
|
|
21
21
|
})(indicatorCSQStyles?.title);
|
|
22
22
|
const ChipStyled = styled(Chip, {
|
|
23
|
-
name:
|
|
23
|
+
name: INDICATOR_CSQ_KEY_COMPONENT,
|
|
24
24
|
slot: IndicatorCSQSlots.chip
|
|
25
25
|
})(indicatorCSQStyles?.chip);
|
|
26
26
|
export {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { M4LOverridesStyleRules } from '@m4l/components';
|
|
2
2
|
import { IndicatorCSQSlots } from './slots/IndicatorCSQEnum';
|
|
3
|
-
import {
|
|
3
|
+
import { INDICATOR_CSQ_KEY_COMPONENT } from './constants';
|
|
4
4
|
import { Theme } from '@mui/material';
|
|
5
5
|
import { Sizes } from '@m4l/styles';
|
|
6
6
|
export interface IndicatorCSQProps {
|
|
@@ -12,10 +12,14 @@ export interface IndicatorCSQProps {
|
|
|
12
12
|
* Size of the indicator
|
|
13
13
|
*/
|
|
14
14
|
size?: Extract<Sizes, 'small' | 'medium'>;
|
|
15
|
+
/**
|
|
16
|
+
* className
|
|
17
|
+
*/
|
|
18
|
+
className?: string;
|
|
15
19
|
}
|
|
16
20
|
export type IndicatorCSQSlotsType = keyof typeof IndicatorCSQSlots;
|
|
17
21
|
export type IndicatorCSQOwnerState = {
|
|
18
22
|
percentage: number;
|
|
19
23
|
size: IndicatorCSQProps['size'];
|
|
20
24
|
};
|
|
21
|
-
export type IndicatorCSQStyles = M4LOverridesStyleRules<IndicatorCSQSlotsType, typeof
|
|
25
|
+
export type IndicatorCSQStyles = M4LOverridesStyleRules<IndicatorCSQSlotsType, typeof INDICATOR_CSQ_KEY_COMPONENT, Theme>;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { IndicatorValueAndMagnitudeProps } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* Valor y magnitud component, para mostrar en los IndicatorValueStatus
|
|
4
|
+
*/
|
|
5
|
+
export declare const IndicatorValueAndMagnitude: (props: IndicatorValueAndMagnitudeProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
+
import { R as RootStyled, V as ValueStyled, C as ContainerUnitStyled, U as UnitStyled } from "./slots/styled.js";
|
|
3
|
+
const IndicatorValueAndMagnitude = (props) => {
|
|
4
|
+
const { value, magnitude, minWidth } = props;
|
|
5
|
+
const ownerState = {
|
|
6
|
+
minWidth
|
|
7
|
+
};
|
|
8
|
+
return /* @__PURE__ */ jsxs(RootStyled, { children: [
|
|
9
|
+
/* @__PURE__ */ jsx(ValueStyled, { variant: "subtitleDens", fontFamily: "Jura", color: "text.secondary", ellipsis: true, skeletonWidth: "30px", ownerState, children: value }),
|
|
10
|
+
magnitude && /* @__PURE__ */ jsx(ContainerUnitStyled, { children: /* @__PURE__ */ jsx(UnitStyled, { variant: "body", fontFamily: "Jura", skeletonWidth: "15px", ellipsis: true, children: magnitude }) })
|
|
11
|
+
] });
|
|
12
|
+
};
|
|
13
|
+
export {
|
|
14
|
+
IndicatorValueAndMagnitude as I
|
|
15
|
+
};
|