@ubnt/store.core 9.12.0-alpha.1 → 9.12.0-alpha.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +10 -0
- package/lib/assets/check2.svg +3 -3
- package/lib/assets/check3.svg +3 -3
- package/lib/assets/efg.png +0 -0
- package/lib/assets/minus4.svg +8 -8
- package/lib/assets/minus5.svg +8 -8
- package/lib/assets/plus5.svg +9 -9
- package/lib/assets/plus6.svg +9 -9
- package/lib/assets/ucg-max.png +0 -0
- package/lib/assets/ucgMax.jpg +0 -0
- package/lib/assets/ucgMax2.jpg +0 -0
- package/lib/assets/ucgUltra.jpg +0 -0
- package/lib/assets/ucgUltra2.jpg +0 -0
- package/lib/assets/udmPro.jpg +0 -0
- package/lib/assets/udmPro2.jpg +0 -0
- package/lib/assets/udmProMax.jpg +0 -0
- package/lib/assets/udmProMax2.jpg +0 -0
- package/lib/assets/udmProSpecial.jpg +0 -0
- package/lib/assets/udmProSpecial2.jpg +0 -0
- package/lib/components/ModelCompareV3/ModelComparePropertyValueGridItem.js +1 -1
- package/lib/components/ModelCompareV3/ModelComparePropertyValueGridItem.mjs +1 -1
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/ucgMax.jpg.js +5 -5
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/ucgMax.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/ucgUltra.jpg.js +5 -5
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/ucgUltra.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmPro.jpg.js +5 -5
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmPro.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmProMax.jpg.js +5 -5
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmProMax.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmProSpecial.jpg.js +5 -5
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmProSpecial.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/ucgMax.jpg.js +1 -1
- package/lib/components/ModelCompareV3/assets/Consoles/ucgMax.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/ucgUltra.jpg.js +1 -1
- package/lib/components/ModelCompareV3/assets/Consoles/ucgUltra.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/udmPro.jpg.js +1 -1
- package/lib/components/ModelCompareV3/assets/Consoles/udmPro.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/udmProMax.jpg.js +1 -1
- package/lib/components/ModelCompareV3/assets/Consoles/udmProMax.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/udmProSpecial.jpg.js +1 -1
- package/lib/components/ModelCompareV3/assets/Consoles/udmProSpecial.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/check.svg.js +1 -1
- package/lib/components/ModelCompareV3/assets/check.svg.mjs +2 -2
- package/lib/components/ModelCompareV3/data/CloudGateways.js +15 -15
- package/lib/components/ModelCompareV3/data/CloudGateways.mjs +10 -10
- package/lib/components/ModelCompareV3/data/products/ucgMax.js +1 -1
- package/lib/components/ModelCompareV3/data/products/ucgMax.mjs +1 -1
- package/lib/components/ModelCompareV3/data/products/ucgUltra.js +1 -1
- package/lib/components/ModelCompareV3/data/products/ucgUltra.mjs +1 -1
- package/lib/components/ModelCompareV3/data/products/udmPro.js +1 -1
- package/lib/components/ModelCompareV3/data/products/udmPro.mjs +1 -1
- package/lib/components/ModelCompareV3/data/products/udmProMax.js +1 -1
- package/lib/components/ModelCompareV3/data/products/udmProMax.mjs +1 -1
- package/lib/components/ModelCompareV3/data/products/udmProSpecial.js +1 -1
- package/lib/components/ModelCompareV3/data/products/udmProSpecial.mjs +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.constants.js +311 -15
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.constants.js.map +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.constants.mjs +309 -15
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.constants.mjs.map +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.js +38 -22
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.js.map +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.mjs +38 -22
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.mjs.map +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.types.d.ts +10 -2
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.types.js +2 -0
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.types.js.map +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.types.mjs +2 -0
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.types.mjs.map +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/HddSlots/HddSlots.d.ts +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/HddSlots/HddSlots.js +5 -4
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/HddSlots/HddSlots.js.map +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/HddSlots/HddSlots.mjs +5 -4
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/HddSlots/HddSlots.mjs.map +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputSections/CounterSection.js +2 -2
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputSections/CounterSection.mjs +2 -2
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/minus.svg.js +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/minus.svg.mjs +2 -2
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/plus.svg.js +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/plus.svg.mjs +2 -2
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/useComputeResourceCalculator.js +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/useComputeResourceCalculator.js.map +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/useComputeResourceCalculator.mjs +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/useComputeResourceCalculator.mjs.map +1 -1
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerSelectModal/PoeConsumerSelectModal.js +2 -2
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerSelectModal/PoeConsumerSelectModal.mjs +2 -2
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/minus.svg.js +1 -1
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/minus.svg.mjs +2 -2
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/plus.svg.js +1 -1
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/plus.svg.mjs +2 -2
- package/lib/components/ResourceCalculatorV1/assets/consoles/efg.png.js +27 -0
- package/lib/components/ResourceCalculatorV1/assets/consoles/efg.png.js.map +1 -0
- package/lib/components/ResourceCalculatorV1/assets/consoles/efg.png.mjs +3 -0
- package/lib/components/ResourceCalculatorV1/assets/consoles/efg.png.mjs.map +1 -0
- package/lib/components/ResourceCalculatorV1/assets/consoles/ucg-max.png.js +27 -0
- package/lib/components/ResourceCalculatorV1/assets/consoles/ucg-max.png.js.map +1 -0
- package/lib/components/ResourceCalculatorV1/assets/consoles/ucg-max.png.mjs +3 -0
- package/lib/components/ResourceCalculatorV1/assets/consoles/ucg-max.png.mjs.map +1 -0
- package/lib/components/ResourceCalculatorV1/translations/en.json.js +4 -1
- package/lib/components/ResourceCalculatorV1/translations/en.json.js.map +1 -1
- package/lib/components/ResourceCalculatorV1/translations/en.json.mjs +4 -1
- package/lib/components/ResourceCalculatorV1/translations/en.json.mjs.map +1 -1
- package/lib/components/ResourceCalculatorV1/translations/useResourceCalculatorTranslation.d.ts +2 -2
- package/lib/components/VariantSelector/CheckBox/CheckBox.js +1 -1
- package/lib/components/VariantSelector/CheckBox/CheckBox.mjs +1 -1
- package/lib/components/VariantSelector/CheckBox/assets/check.svg.js +1 -1
- package/lib/components/VariantSelector/CheckBox/assets/check.svg.mjs +2 -2
- package/lib/constants/icons/options/colors/black.svg.js +5 -5
- package/lib/constants/icons/options/colors/index.js +3 -3
- package/lib/constants/icons/options/styles/black.svg.js +5 -5
- package/lib/constants/icons/options/styles/index.js +3 -3
- package/lib/constants/optionIcons.js +6 -6
- package/lib/constants/optionIcons.mjs +4 -4
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useComputeResourceCalculator.js","sources":["../../../../src/components/ResourceCalculatorV1/ComputeResourceCalculator/useComputeResourceCalculator.ts"],"sourcesContent":["import { useMemo } from \"react\";\n\nimport type {\n ComputeResourceCalculatorInputs,\n Device,\n} from \"./ComputeResourceCalculator.types\";\nimport { FeatureId } from \"./ComputeResourceCalculator.types\";\n\nexport const useComputeResourceCalculator = ({\n deviceResourceData,\n inputs,\n}: {\n deviceResourceData: Device[\"loadData\"];\n inputs: ComputeResourceCalculatorInputs;\n}) => {\n const networkResources = useMemo(() => {\n const networkDeviceResources = deviceResourceData.Network;\n const networkInputs = inputs[FeatureId.Network];\n\n if (!networkInputs.enabled || !networkDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (networkInputs.enabled) {\n const cpu =\n networkDeviceResources.enableFeature.cpu.value *\n networkDeviceResources.enableFeature.cpu.weight;\n const memory =\n networkDeviceResources.enableFeature.memory.value *\n networkDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (networkInputs.accessPoints > 0) {\n const cpu =\n networkInputs.accessPoints *\n (networkDeviceResources.accessPoint.data.cpu.value *\n networkDeviceResources.accessPoint.data.cpu.weight);\n const memory =\n networkInputs.accessPoints *\n (networkDeviceResources.accessPoint.data.memory.value *\n networkDeviceResources.accessPoint.data.memory.weight);\n sum += cpu + memory;\n }\n\n if (networkInputs.vpn) {\n const cpu =\n networkDeviceResources.vpn.cpu.value *\n networkDeviceResources.vpn.cpu.weight;\n const memory =\n networkDeviceResources.vpn.memory.value *\n networkDeviceResources.vpn.memory.weight;\n sum += cpu + memory;\n }\n\n if (networkInputs.detections) {\n const cpu =\n networkDeviceResources.securityDetection.cpu.value *\n networkDeviceResources.securityDetection.cpu.weight;\n const memory =\n networkDeviceResources.securityDetection.memory.value *\n networkDeviceResources.securityDetection.memory.weight;\n\n sum += cpu + memory + networkDeviceResources.threatManagementLoad;\n }\n\n if (networkInputs.adBlocking) {\n const cpu =\n networkDeviceResources.adBlocking.cpu.value *\n networkDeviceResources.adBlocking.cpu.weight;\n const memory =\n networkDeviceResources.adBlocking.memory.value *\n networkDeviceResources.adBlocking.memory.weight;\n sum += cpu + memory;\n }\n\n if (networkInputs.qos) {\n const cpu =\n networkDeviceResources.qos.cpu.value *\n networkDeviceResources.qos.cpu.weight;\n const memory =\n networkDeviceResources.qos.memory.value *\n networkDeviceResources.qos.memory.weight;\n sum += cpu + memory;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const protectResources = useMemo(() => {\n const protectDeviceResources = deviceResourceData.Protect;\n const protectInputs = inputs[FeatureId.Protect];\n\n // Increasing weight of camera values by 50%.\n const CAMERA_WEIGHT_FACTOR = 1.5;\n\n if (!protectInputs.enabled || !protectDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (protectInputs.enabled) {\n const cpu =\n protectDeviceResources.enableFeature.cpu.value *\n protectDeviceResources.enableFeature.cpu.weight;\n const memory =\n protectDeviceResources.enableFeature.memory.value *\n protectDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (protectInputs.cameraHd > 0) {\n const cpu =\n protectInputs.cameraHd *\n protectDeviceResources.cameraHd.data.cpu.value *\n protectDeviceResources.cameraHd.data.cpu.weight;\n const memory =\n protectInputs.cameraHd *\n protectDeviceResources.cameraHd.data.memory.value *\n protectDeviceResources.cameraHd.data.memory.weight;\n sum += (cpu + memory) * CAMERA_WEIGHT_FACTOR;\n }\n\n if (protectInputs.camera2k > 0) {\n const cpu =\n protectInputs.camera2k *\n protectDeviceResources.camera2k.data.cpu.value *\n protectDeviceResources.camera2k.data.cpu.weight;\n const memory =\n protectInputs.camera2k *\n protectDeviceResources.camera2k.data.memory.value *\n protectDeviceResources.camera2k.data.memory.weight;\n sum += (cpu + memory) * CAMERA_WEIGHT_FACTOR;\n }\n\n if (protectInputs.camera4k > 0) {\n const cpu =\n protectInputs.camera4k *\n protectDeviceResources.camera4k.data.cpu.value *\n protectDeviceResources.camera4k.data.cpu.weight;\n const memory =\n protectInputs.camera4k *\n protectDeviceResources.camera4k.data.memory.value *\n protectDeviceResources.camera4k.data.memory.weight;\n sum += (cpu + memory) * CAMERA_WEIGHT_FACTOR;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const talkResources = useMemo(() => {\n const talkDeviceResources = deviceResourceData.Talk;\n const talkInputs = inputs[FeatureId.Talk];\n\n if (!talkInputs.enabled || !talkDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (talkInputs.enabled) {\n const cpu =\n talkDeviceResources.enableFeature.cpu.value *\n talkDeviceResources.enableFeature.cpu.weight;\n const memory =\n talkDeviceResources.enableFeature.memory.value *\n talkDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (talkInputs.phones) {\n const cpu =\n talkInputs.phones *\n talkDeviceResources.phone.data.cpu.value *\n talkDeviceResources.phone.data.cpu.weight;\n const memory =\n talkInputs.phones *\n talkDeviceResources.phone.data.memory.value *\n talkDeviceResources.phone.data.memory.weight;\n sum += cpu + memory;\n }\n\n if (talkInputs.record) {\n const cpu =\n talkDeviceResources.record.cpu.value *\n talkDeviceResources.record.cpu.weight;\n const memory =\n talkDeviceResources.record.memory.value *\n talkDeviceResources.record.memory.weight;\n sum += cpu + memory;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const accessResources = useMemo(() => {\n const accessDeviceResources = deviceResourceData.Access;\n const accessInputs = inputs[FeatureId.Access];\n\n if (!accessInputs.enabled || !accessDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (accessInputs.enabled) {\n const cpu =\n accessDeviceResources.enableFeature.cpu.value *\n accessDeviceResources.enableFeature.cpu.weight;\n const memory =\n accessDeviceResources.enableFeature.memory.value *\n accessDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (accessInputs.doors > 0) {\n const cpu =\n accessInputs.doors *\n (accessDeviceResources.door.data.cpu.value *\n accessDeviceResources.door.data.cpu.weight);\n const memory =\n accessInputs.doors *\n (accessDeviceResources.door.data.memory.value *\n accessDeviceResources.door.data.memory.weight);\n sum += cpu + memory;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const computedResourcesLoadRatio = useMemo(() => {\n return (\n networkResources + talkResources + accessResources + protectResources\n );\n }, [networkResources, talkResources, accessResources, protectResources]);\n\n return {\n computedResourcesLoadRatio,\n };\n};\n"],"names":["useComputeResourceCalculator","deviceResourceData","inputs","networkResources","useMemo","networkDeviceResources","Network","networkInputs","FeatureId","enabled","sum","cpu","enableFeature","value","weight","memory","accessPoints","accessPoint","data","vpn","detections","securityDetection","threatManagementLoad","adBlocking","qos","protectResources","protectDeviceResources","Protect","protectInputs","CAMERA_WEIGHT_FACTOR","cameraHd","camera2k","camera4k","talkResources","talkDeviceResources","Talk","talkInputs","phones","phone","record","accessResources","accessDeviceResources","Access","accessInputs","doors","door","computedResourcesLoadRatio"],"mappings":";;;;;AAQO,MAAMA,+BAA+BA,CAAC;EAC3CC,kBAAA;EACAC;AACF,CAGM,KAAA;EACE,MAAAC,gBAAA,GAAmBC,KAAAA,CAAAA,QAAQ,MAAM;IACrC,MAAMC,yBAAyBJ,kBAAmB,CAAAK,OAAA;IAC5C,MAAAC,aAAA,GAAgBL,MAAO,CAAAM,+BAAA,CAAAA,SAAA,CAAUF,OAAO,CAAA;IAE9C,IAAI,CAACC,aAAA,CAAcE,OAAW,IAAA,CAACJ,sBAAwB,EAAA;MAC9C,OAAA,CAAA;IACT;IAEA,IAAIK,GAAM,GAAA,CAAA;IAEV,IAAIH,cAAcE,OAAS,EAAA;MACzB,MAAME,MACJN,sBAAuB,CAAAO,aAAA,CAAcD,IAAIE,KACzC,GAAAR,sBAAA,CAAuBO,cAAcD,GAAI,CAAAG,MAAA;MAC3C,MAAMC,SACJV,sBAAuB,CAAAO,aAAA,CAAcG,OAAOF,KAC5C,GAAAR,sBAAA,CAAuBO,cAAcG,MAAO,CAAAD,MAAA;MAC9CJ,GAAA,IAAOC,GAAM,GAAAI,MAAA;IACf;IAEI,IAAAR,aAAA,CAAcS,eAAe,CAAG,EAAA;MAC5B,MAAAL,GAAA,GACJJ,aAAc,CAAAS,YAAA,IACbX,sBAAuB,CAAAY,WAAA,CAAYC,IAAK,CAAAP,GAAA,CAAIE,KAC3C,GAAAR,sBAAA,CAAuBY,WAAY,CAAAC,IAAA,CAAKP,GAAI,CAAAG,MAAA,CAAA;MAC1C,MAAAC,MAAA,GACJR,aAAc,CAAAS,YAAA,IACbX,sBAAuB,CAAAY,WAAA,CAAYC,IAAK,CAAAH,MAA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IAAOC,GAAM,GAAAI,MAAA;IACf;IAEO,OAAAL,GAAA;EAAA,CACN,EAAA,CAACT,kBAAoB,EAAAC,MAAM,CAAC,CAAA;EAEzB,MAAA4C,0BAAA,GAA6B1C,KAAAA,CAAAA,QAAQ,MAAM;IAE7C,OAAAD,gBAAA,GAAmB8B,gBAAgBO,eAAkB,GAAAf,gBAAA;KAEtD,CAACtB,gBAAA,EAAkB8B,aAAe,EAAAO,eAAA,EAAiBf,gBAAgB,CAAC,CAAA;EAEhE,OAAA;IACLqB;EAAA,CACF;AACF,CAAA;"}
|
|
1
|
+
{"version":3,"file":"useComputeResourceCalculator.js","sources":["../../../../src/components/ResourceCalculatorV1/ComputeResourceCalculator/useComputeResourceCalculator.ts"],"sourcesContent":["import { useMemo } from \"react\";\n\nimport type {\n ComputeResourceCalculatorInputs,\n Device,\n} from \"./ComputeResourceCalculator.types\";\nimport { FeatureId } from \"./ComputeResourceCalculator.types\";\n\nexport const useComputeResourceCalculator = ({\n deviceResourceData,\n inputs,\n}: {\n deviceResourceData: Device[\"loadData\"];\n inputs: ComputeResourceCalculatorInputs;\n}) => {\n const networkResources = useMemo(() => {\n const networkDeviceResources = deviceResourceData.Network;\n const networkInputs = inputs[FeatureId.Network];\n\n if (!networkInputs.enabled || !networkDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (networkInputs.enabled) {\n const cpu =\n networkDeviceResources.enableFeature.cpu.value *\n networkDeviceResources.enableFeature.cpu.weight;\n const memory =\n networkDeviceResources.enableFeature.memory.value *\n networkDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (networkInputs.accessPoints > 0) {\n const cpu =\n networkInputs.accessPoints *\n (networkDeviceResources.accessPoint.data.cpu.value *\n networkDeviceResources.accessPoint.data.cpu.weight);\n const memory =\n networkInputs.accessPoints *\n (networkDeviceResources.accessPoint.data.memory.value *\n networkDeviceResources.accessPoint.data.memory.weight);\n sum += cpu + memory;\n }\n\n if (networkInputs.vpn) {\n const cpu =\n networkDeviceResources.vpn.cpu.value *\n networkDeviceResources.vpn.cpu.weight;\n const memory =\n networkDeviceResources.vpn.memory.value *\n networkDeviceResources.vpn.memory.weight;\n sum += cpu + memory;\n }\n\n if (networkInputs.detections) {\n const cpu =\n networkDeviceResources.securityDetection.cpu.value *\n networkDeviceResources.securityDetection.cpu.weight;\n const memory =\n networkDeviceResources.securityDetection.memory.value *\n networkDeviceResources.securityDetection.memory.weight;\n\n sum += cpu + memory;\n }\n\n if (networkInputs.adBlocking) {\n const cpu =\n networkDeviceResources.adBlocking.cpu.value *\n networkDeviceResources.adBlocking.cpu.weight;\n const memory =\n networkDeviceResources.adBlocking.memory.value *\n networkDeviceResources.adBlocking.memory.weight;\n sum += cpu + memory;\n }\n\n if (networkInputs.qos) {\n const cpu =\n networkDeviceResources.qos.cpu.value *\n networkDeviceResources.qos.cpu.weight;\n const memory =\n networkDeviceResources.qos.memory.value *\n networkDeviceResources.qos.memory.weight;\n sum += cpu + memory;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const protectResources = useMemo(() => {\n const protectDeviceResources = deviceResourceData.Protect;\n const protectInputs = inputs[FeatureId.Protect];\n\n // Increasing weight of camera values by 50%.\n const CAMERA_WEIGHT_FACTOR = 1.5;\n\n if (!protectInputs.enabled || !protectDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (protectInputs.enabled) {\n const cpu =\n protectDeviceResources.enableFeature.cpu.value *\n protectDeviceResources.enableFeature.cpu.weight;\n const memory =\n protectDeviceResources.enableFeature.memory.value *\n protectDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (protectInputs.cameraHd > 0) {\n const cpu =\n protectInputs.cameraHd *\n protectDeviceResources.cameraHd.data.cpu.value *\n protectDeviceResources.cameraHd.data.cpu.weight;\n const memory =\n protectInputs.cameraHd *\n protectDeviceResources.cameraHd.data.memory.value *\n protectDeviceResources.cameraHd.data.memory.weight;\n sum += (cpu + memory) * CAMERA_WEIGHT_FACTOR;\n }\n\n if (protectInputs.camera2k > 0) {\n const cpu =\n protectInputs.camera2k *\n protectDeviceResources.camera2k.data.cpu.value *\n protectDeviceResources.camera2k.data.cpu.weight;\n const memory =\n protectInputs.camera2k *\n protectDeviceResources.camera2k.data.memory.value *\n protectDeviceResources.camera2k.data.memory.weight;\n sum += (cpu + memory) * CAMERA_WEIGHT_FACTOR;\n }\n\n if (protectInputs.camera4k > 0) {\n const cpu =\n protectInputs.camera4k *\n protectDeviceResources.camera4k.data.cpu.value *\n protectDeviceResources.camera4k.data.cpu.weight;\n const memory =\n protectInputs.camera4k *\n protectDeviceResources.camera4k.data.memory.value *\n protectDeviceResources.camera4k.data.memory.weight;\n sum += (cpu + memory) * CAMERA_WEIGHT_FACTOR;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const talkResources = useMemo(() => {\n const talkDeviceResources = deviceResourceData.Talk;\n const talkInputs = inputs[FeatureId.Talk];\n\n if (!talkInputs.enabled || !talkDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (talkInputs.enabled) {\n const cpu =\n talkDeviceResources.enableFeature.cpu.value *\n talkDeviceResources.enableFeature.cpu.weight;\n const memory =\n talkDeviceResources.enableFeature.memory.value *\n talkDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (talkInputs.phones) {\n const cpu =\n talkInputs.phones *\n talkDeviceResources.phone.data.cpu.value *\n talkDeviceResources.phone.data.cpu.weight;\n const memory =\n talkInputs.phones *\n talkDeviceResources.phone.data.memory.value *\n talkDeviceResources.phone.data.memory.weight;\n sum += cpu + memory;\n }\n\n if (talkInputs.record) {\n const cpu =\n talkDeviceResources.record.cpu.value *\n talkDeviceResources.record.cpu.weight;\n const memory =\n talkDeviceResources.record.memory.value *\n talkDeviceResources.record.memory.weight;\n sum += cpu + memory;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const accessResources = useMemo(() => {\n const accessDeviceResources = deviceResourceData.Access;\n const accessInputs = inputs[FeatureId.Access];\n\n if (!accessInputs.enabled || !accessDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (accessInputs.enabled) {\n const cpu =\n accessDeviceResources.enableFeature.cpu.value *\n accessDeviceResources.enableFeature.cpu.weight;\n const memory =\n accessDeviceResources.enableFeature.memory.value *\n accessDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (accessInputs.doors > 0) {\n const cpu =\n accessInputs.doors *\n (accessDeviceResources.door.data.cpu.value *\n accessDeviceResources.door.data.cpu.weight);\n const memory =\n accessInputs.doors *\n (accessDeviceResources.door.data.memory.value *\n accessDeviceResources.door.data.memory.weight);\n sum += cpu + memory;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const computedResourcesLoadRatio = useMemo(() => {\n return (\n networkResources + talkResources + accessResources + protectResources\n );\n }, [networkResources, talkResources, accessResources, protectResources]);\n\n return {\n computedResourcesLoadRatio,\n };\n};\n"],"names":["useComputeResourceCalculator","deviceResourceData","inputs","networkResources","useMemo","networkDeviceResources","Network","networkInputs","FeatureId","enabled","sum","cpu","enableFeature","value","weight","memory","accessPoints","accessPoint","data","vpn","detections","securityDetection","adBlocking","qos","protectResources","protectDeviceResources","Protect","protectInputs","CAMERA_WEIGHT_FACTOR","cameraHd","camera2k","camera4k","talkResources","talkDeviceResources","Talk","talkInputs","phones","phone","record","accessResources","accessDeviceResources","Access","accessInputs","doors","door","computedResourcesLoadRatio"],"mappings":";;;;;AAQO,MAAMA,+BAA+BA,CAAC;EAC3CC,kBAAA;EACAC;AACF,CAGM,KAAA;EACE,MAAAC,gBAAA,GAAmBC,KAAAA,CAAAA,QAAQ,MAAM;IACrC,MAAMC,yBAAyBJ,kBAAmB,CAAAK,OAAA;IAC5C,MAAAC,aAAA,GAAgBL,MAAO,CAAAM,+BAAA,CAAAA,SAAA,CAAUF,OAAO,CAAA;IAE9C,IAAI,CAACC,aAAA,CAAcE,OAAW,IAAA,CAACJ,sBAAwB,EAAA;MAC9C,OAAA,CA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5B,cAAcD,GAAI,CAAAG,MAAA;MAC1C,MAAMC,SACJyB,qBAAsB,CAAA5B,aAAA,CAAcG,OAAOF,KAC3C,GAAA2B,qBAAA,CAAsB5B,cAAcG,MAAO,CAAAD,MAAA;MAC7CJ,GAAA,IAAOC,GAAM,GAAAI,MAAA;IACf;IAEI,IAAA2B,YAAA,CAAaC,QAAQ,CAAG,EAAA;MACpB,MAAAhC,GAAA,GACJ+B,YAAa,CAAAC,KAAA,IACZH,qBAAsB,CAAAI,IAAA,CAAK1B,IAAK,CAAAP,GAAA,CAAIE,KACnC,GAAA2B,qBAAA,CAAsBI,IAAK,CAAA1B,IAAA,CAAKP,GAAI,CAAAG,MAAA,CAAA;MAClC,MAAAC,MAAA,GACJ2B,YAAa,CAAAC,KAAA,IACZH,qBAAsB,CAAAI,IAAA,CAAK1B,IAAK,CAAAH,MAAA,CAAOF,KACtC,GAAA2B,qBAAA,CAAsBI,IAAK,CAAA1B,IAAA,CAAKH,MAAO,CAAAD,MAAA,CAAA;MAC3CJ,GAAA,IAAOC,GAAM,GAAAI,MAAA;IACf;IAEO,OAAAL,GAAA;EAAA,CACN,EAAA,CAACT,kBAAoB,EAAAC,MAAM,CAAC,CAAA;EAEzB,MAAA2C,0BAAA,GAA6BzC,KAAAA,CAAAA,QAAQ,MAAM;IAE7C,OAAAD,gBAAA,GAAmB6B,gBAAgBO,eAAkB,GAAAf,gBAAA;KAEtD,CAACrB,gBAAA,EAAkB6B,aAAe,EAAAO,eAAA,EAAiBf,gBAAgB,CAAC,CAAA;EAEhE,OAAA;IACLqB;EAAA,CACF;AACF,CAAA;"}
|
|
@@ -30,7 +30,7 @@ const useComputeResourceCalculator = ({
|
|
|
30
30
|
if (networkInputs.detections) {
|
|
31
31
|
const cpu = networkDeviceResources.securityDetection.cpu.value * networkDeviceResources.securityDetection.cpu.weight;
|
|
32
32
|
const memory = networkDeviceResources.securityDetection.memory.value * networkDeviceResources.securityDetection.memory.weight;
|
|
33
|
-
sum += cpu + memory
|
|
33
|
+
sum += cpu + memory;
|
|
34
34
|
}
|
|
35
35
|
if (networkInputs.adBlocking) {
|
|
36
36
|
const cpu = networkDeviceResources.adBlocking.cpu.value * networkDeviceResources.adBlocking.cpu.weight;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useComputeResourceCalculator.mjs","sources":["../../../../src/components/ResourceCalculatorV1/ComputeResourceCalculator/useComputeResourceCalculator.ts"],"sourcesContent":["import { useMemo } from \"react\";\n\nimport type {\n ComputeResourceCalculatorInputs,\n Device,\n} from \"./ComputeResourceCalculator.types\";\nimport { FeatureId } from \"./ComputeResourceCalculator.types\";\n\nexport const useComputeResourceCalculator = ({\n deviceResourceData,\n inputs,\n}: {\n deviceResourceData: Device[\"loadData\"];\n inputs: ComputeResourceCalculatorInputs;\n}) => {\n const networkResources = useMemo(() => {\n const networkDeviceResources = deviceResourceData.Network;\n const networkInputs = inputs[FeatureId.Network];\n\n if (!networkInputs.enabled || !networkDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (networkInputs.enabled) {\n const cpu =\n networkDeviceResources.enableFeature.cpu.value *\n networkDeviceResources.enableFeature.cpu.weight;\n const memory =\n networkDeviceResources.enableFeature.memory.value *\n networkDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (networkInputs.accessPoints > 0) {\n const cpu =\n networkInputs.accessPoints *\n (networkDeviceResources.accessPoint.data.cpu.value *\n networkDeviceResources.accessPoint.data.cpu.weight);\n const memory =\n networkInputs.accessPoints *\n (networkDeviceResources.accessPoint.data.memory.value *\n networkDeviceResources.accessPoint.data.memory.weight);\n sum += cpu + memory;\n }\n\n if (networkInputs.vpn) {\n const cpu =\n networkDeviceResources.vpn.cpu.value *\n networkDeviceResources.vpn.cpu.weight;\n const memory =\n networkDeviceResources.vpn.memory.value *\n networkDeviceResources.vpn.memory.weight;\n sum += cpu + memory;\n }\n\n if (networkInputs.detections) {\n const cpu =\n networkDeviceResources.securityDetection.cpu.value *\n networkDeviceResources.securityDetection.cpu.weight;\n const memory =\n networkDeviceResources.securityDetection.memory.value *\n networkDeviceResources.securityDetection.memory.weight;\n\n sum += cpu + memory + networkDeviceResources.threatManagementLoad;\n }\n\n if (networkInputs.adBlocking) {\n const cpu =\n networkDeviceResources.adBlocking.cpu.value *\n networkDeviceResources.adBlocking.cpu.weight;\n const memory =\n networkDeviceResources.adBlocking.memory.value *\n networkDeviceResources.adBlocking.memory.weight;\n sum += cpu + memory;\n }\n\n if (networkInputs.qos) {\n const cpu =\n networkDeviceResources.qos.cpu.value *\n networkDeviceResources.qos.cpu.weight;\n const memory =\n networkDeviceResources.qos.memory.value *\n networkDeviceResources.qos.memory.weight;\n sum += cpu + memory;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const protectResources = useMemo(() => {\n const protectDeviceResources = deviceResourceData.Protect;\n const protectInputs = inputs[FeatureId.Protect];\n\n // Increasing weight of camera values by 50%.\n const CAMERA_WEIGHT_FACTOR = 1.5;\n\n if (!protectInputs.enabled || !protectDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (protectInputs.enabled) {\n const cpu =\n protectDeviceResources.enableFeature.cpu.value *\n protectDeviceResources.enableFeature.cpu.weight;\n const memory =\n protectDeviceResources.enableFeature.memory.value *\n protectDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (protectInputs.cameraHd > 0) {\n const cpu =\n protectInputs.cameraHd *\n protectDeviceResources.cameraHd.data.cpu.value *\n protectDeviceResources.cameraHd.data.cpu.weight;\n const memory =\n protectInputs.cameraHd *\n protectDeviceResources.cameraHd.data.memory.value *\n protectDeviceResources.cameraHd.data.memory.weight;\n sum += (cpu + memory) * CAMERA_WEIGHT_FACTOR;\n }\n\n if (protectInputs.camera2k > 0) {\n const cpu =\n protectInputs.camera2k *\n protectDeviceResources.camera2k.data.cpu.value *\n protectDeviceResources.camera2k.data.cpu.weight;\n const memory =\n protectInputs.camera2k *\n protectDeviceResources.camera2k.data.memory.value *\n protectDeviceResources.camera2k.data.memory.weight;\n sum += (cpu + memory) * CAMERA_WEIGHT_FACTOR;\n }\n\n if (protectInputs.camera4k > 0) {\n const cpu =\n protectInputs.camera4k *\n protectDeviceResources.camera4k.data.cpu.value *\n protectDeviceResources.camera4k.data.cpu.weight;\n const memory =\n protectInputs.camera4k *\n protectDeviceResources.camera4k.data.memory.value *\n protectDeviceResources.camera4k.data.memory.weight;\n sum += (cpu + memory) * CAMERA_WEIGHT_FACTOR;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const talkResources = useMemo(() => {\n const talkDeviceResources = deviceResourceData.Talk;\n const talkInputs = inputs[FeatureId.Talk];\n\n if (!talkInputs.enabled || !talkDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (talkInputs.enabled) {\n const cpu =\n talkDeviceResources.enableFeature.cpu.value *\n talkDeviceResources.enableFeature.cpu.weight;\n const memory =\n talkDeviceResources.enableFeature.memory.value *\n talkDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (talkInputs.phones) {\n const cpu =\n talkInputs.phones *\n talkDeviceResources.phone.data.cpu.value *\n talkDeviceResources.phone.data.cpu.weight;\n const memory =\n talkInputs.phones *\n talkDeviceResources.phone.data.memory.value *\n talkDeviceResources.phone.data.memory.weight;\n sum += cpu + memory;\n }\n\n if (talkInputs.record) {\n const cpu =\n talkDeviceResources.record.cpu.value *\n talkDeviceResources.record.cpu.weight;\n const memory =\n talkDeviceResources.record.memory.value *\n talkDeviceResources.record.memory.weight;\n sum += cpu + memory;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const accessResources = useMemo(() => {\n const accessDeviceResources = deviceResourceData.Access;\n const accessInputs = inputs[FeatureId.Access];\n\n if (!accessInputs.enabled || !accessDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (accessInputs.enabled) {\n const cpu =\n accessDeviceResources.enableFeature.cpu.value *\n accessDeviceResources.enableFeature.cpu.weight;\n const memory =\n accessDeviceResources.enableFeature.memory.value *\n accessDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (accessInputs.doors > 0) {\n const cpu =\n accessInputs.doors *\n (accessDeviceResources.door.data.cpu.value *\n accessDeviceResources.door.data.cpu.weight);\n const memory =\n accessInputs.doors *\n (accessDeviceResources.door.data.memory.value *\n accessDeviceResources.door.data.memory.weight);\n sum += cpu + memory;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const computedResourcesLoadRatio = useMemo(() => {\n return (\n networkResources + talkResources + accessResources + protectResources\n );\n }, [networkResources, talkResources, accessResources, protectResources]);\n\n return {\n computedResourcesLoadRatio,\n };\n};\n"],"names":["useComputeResourceCalculator","deviceResourceData","inputs","networkResources","useMemo","networkDeviceResources","Network","networkInputs","FeatureId","enabled","sum","cpu","enableFeature","value","weight","memory","accessPoints","accessPoint","data","vpn","detections","securityDetection","threatManagementLoad","adBlocking","qos","protectResources","protectDeviceResources","Protect","protectInputs","CAMERA_WEIGHT_FACTOR","cameraHd","camera2k","camera4k","talkResources","talkDeviceResources","Talk","talkInputs","phones","phone","record","accessResources","accessDeviceResources","Access","accessInputs","doors","door","computedResourcesLoadRatio"],"mappings":";;;AAQO,MAAMA,+BAA+BA,CAAC;EAC3CC,kBAAA;EACAC;AACF,CAGM,KAAA;EACE,MAAAC,gBAAA,GAAmBC,QAAQ,MAAM;IACrC,MAAMC,yBAAyBJ,kBAAmB,CAAAK,OAAA;IAC5C,MAAAC,aAAA,GAAgBL,MAAO,CAAAM,SAAA,CAAUF,OAAO,CAAA;IAE9C,IAAI,CAACC,aAAA,CAAcE,OAAW,IAAA,CAACJ,sBAAwB,EAAA;MAC9C,OAAA,CAAA;IACT;IAEA,IAAIK,GAAM,GAAA,CAAA;IAEV,IAAIH,cAAcE,OAAS,EAAA;MACzB,MAAME,MACJN,sBAAuB,CAAAO,aAAA,CAAcD,IAAIE,KACzC,GAAAR,sBAAA,CAAuBO,cAAcD,GAAI,CAAAG,MAAA;MAC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;MACpB,MAAAjC,GAAA,GACJgC,YAAa,CAAAC,KAAA,IACZH,qBAAsB,CAAAI,IAAA,CAAK3B,IAAK,CAAAP,GAAA,CAAIE,KACnC,GAAA4B,qBAAA,CAAsBI,IAAK,CAAA3B,IAAA,CAAKP,GAAI,CAAAG,MAAA,CAAA;MAClC,MAAAC,MAAA,GACJ4B,YAAa,CAAAC,KAAA,IACZH,qBAAsB,CAAAI,IAAA,CAAK3B,IAAK,CAAAH,MAAA,CAAOF,KACtC,GAAA4B,qBAAA,CAAsBI,IAAK,CAAA3B,IAAA,CAAKH,MAAO,CAAAD,MAAA,CAAA;MAC3CJ,GAAA,IAAOC,GAAM,GAAAI,MAAA;IACf;IAEO,OAAAL,GAAA;EAAA,CACN,EAAA,CAACT,kBAAoB,EAAAC,MAAM,CAAC,CAAA;EAEzB,MAAA4C,0BAAA,GAA6B1C,QAAQ,MAAM;IAE7C,OAAAD,gBAAA,GAAmB8B,gBAAgBO,eAAkB,GAAAf,gBAAA;KAEtD,CAACtB,gBAAA,EAAkB8B,aAAe,EAAAO,eAAA,EAAiBf,gBAAgB,CAAC,CAAA;EAEhE,OAAA;IACLqB;EAAA,CACF;AACF,CAAA;"}
|
|
1
|
+
{"version":3,"file":"useComputeResourceCalculator.mjs","sources":["../../../../src/components/ResourceCalculatorV1/ComputeResourceCalculator/useComputeResourceCalculator.ts"],"sourcesContent":["import { useMemo } from \"react\";\n\nimport type {\n ComputeResourceCalculatorInputs,\n Device,\n} from \"./ComputeResourceCalculator.types\";\nimport { FeatureId } from \"./ComputeResourceCalculator.types\";\n\nexport const useComputeResourceCalculator = ({\n deviceResourceData,\n inputs,\n}: {\n deviceResourceData: Device[\"loadData\"];\n inputs: ComputeResourceCalculatorInputs;\n}) => {\n const networkResources = useMemo(() => {\n const networkDeviceResources = deviceResourceData.Network;\n const networkInputs = inputs[FeatureId.Network];\n\n if (!networkInputs.enabled || !networkDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (networkInputs.enabled) {\n const cpu =\n networkDeviceResources.enableFeature.cpu.value *\n networkDeviceResources.enableFeature.cpu.weight;\n const memory =\n networkDeviceResources.enableFeature.memory.value *\n networkDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (networkInputs.accessPoints > 0) {\n const cpu =\n networkInputs.accessPoints *\n (networkDeviceResources.accessPoint.data.cpu.value *\n networkDeviceResources.accessPoint.data.cpu.weight);\n const memory =\n networkInputs.accessPoints *\n (networkDeviceResources.accessPoint.data.memory.value *\n networkDeviceResources.accessPoint.data.memory.weight);\n sum += cpu + memory;\n }\n\n if (networkInputs.vpn) {\n const cpu =\n networkDeviceResources.vpn.cpu.value *\n networkDeviceResources.vpn.cpu.weight;\n const memory =\n networkDeviceResources.vpn.memory.value *\n networkDeviceResources.vpn.memory.weight;\n sum += cpu + memory;\n }\n\n if (networkInputs.detections) {\n const cpu =\n networkDeviceResources.securityDetection.cpu.value *\n networkDeviceResources.securityDetection.cpu.weight;\n const memory =\n networkDeviceResources.securityDetection.memory.value *\n networkDeviceResources.securityDetection.memory.weight;\n\n sum += cpu + memory;\n }\n\n if (networkInputs.adBlocking) {\n const cpu =\n networkDeviceResources.adBlocking.cpu.value *\n networkDeviceResources.adBlocking.cpu.weight;\n const memory =\n networkDeviceResources.adBlocking.memory.value *\n networkDeviceResources.adBlocking.memory.weight;\n sum += cpu + memory;\n }\n\n if (networkInputs.qos) {\n const cpu =\n networkDeviceResources.qos.cpu.value *\n networkDeviceResources.qos.cpu.weight;\n const memory =\n networkDeviceResources.qos.memory.value *\n networkDeviceResources.qos.memory.weight;\n sum += cpu + memory;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const protectResources = useMemo(() => {\n const protectDeviceResources = deviceResourceData.Protect;\n const protectInputs = inputs[FeatureId.Protect];\n\n // Increasing weight of camera values by 50%.\n const CAMERA_WEIGHT_FACTOR = 1.5;\n\n if (!protectInputs.enabled || !protectDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (protectInputs.enabled) {\n const cpu =\n protectDeviceResources.enableFeature.cpu.value *\n protectDeviceResources.enableFeature.cpu.weight;\n const memory =\n protectDeviceResources.enableFeature.memory.value *\n protectDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (protectInputs.cameraHd > 0) {\n const cpu =\n protectInputs.cameraHd *\n protectDeviceResources.cameraHd.data.cpu.value *\n protectDeviceResources.cameraHd.data.cpu.weight;\n const memory =\n protectInputs.cameraHd *\n protectDeviceResources.cameraHd.data.memory.value *\n protectDeviceResources.cameraHd.data.memory.weight;\n sum += (cpu + memory) * CAMERA_WEIGHT_FACTOR;\n }\n\n if (protectInputs.camera2k > 0) {\n const cpu =\n protectInputs.camera2k *\n protectDeviceResources.camera2k.data.cpu.value *\n protectDeviceResources.camera2k.data.cpu.weight;\n const memory =\n protectInputs.camera2k *\n protectDeviceResources.camera2k.data.memory.value *\n protectDeviceResources.camera2k.data.memory.weight;\n sum += (cpu + memory) * CAMERA_WEIGHT_FACTOR;\n }\n\n if (protectInputs.camera4k > 0) {\n const cpu =\n protectInputs.camera4k *\n protectDeviceResources.camera4k.data.cpu.value *\n protectDeviceResources.camera4k.data.cpu.weight;\n const memory =\n protectInputs.camera4k *\n protectDeviceResources.camera4k.data.memory.value *\n protectDeviceResources.camera4k.data.memory.weight;\n sum += (cpu + memory) * CAMERA_WEIGHT_FACTOR;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const talkResources = useMemo(() => {\n const talkDeviceResources = deviceResourceData.Talk;\n const talkInputs = inputs[FeatureId.Talk];\n\n if (!talkInputs.enabled || !talkDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (talkInputs.enabled) {\n const cpu =\n talkDeviceResources.enableFeature.cpu.value *\n talkDeviceResources.enableFeature.cpu.weight;\n const memory =\n talkDeviceResources.enableFeature.memory.value *\n talkDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (talkInputs.phones) {\n const cpu =\n talkInputs.phones *\n talkDeviceResources.phone.data.cpu.value *\n talkDeviceResources.phone.data.cpu.weight;\n const memory =\n talkInputs.phones *\n talkDeviceResources.phone.data.memory.value *\n talkDeviceResources.phone.data.memory.weight;\n sum += cpu + memory;\n }\n\n if (talkInputs.record) {\n const cpu =\n talkDeviceResources.record.cpu.value *\n talkDeviceResources.record.cpu.weight;\n const memory =\n talkDeviceResources.record.memory.value *\n talkDeviceResources.record.memory.weight;\n sum += cpu + memory;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const accessResources = useMemo(() => {\n const accessDeviceResources = deviceResourceData.Access;\n const accessInputs = inputs[FeatureId.Access];\n\n if (!accessInputs.enabled || !accessDeviceResources) {\n return 0;\n }\n\n let sum = 0;\n\n if (accessInputs.enabled) {\n const cpu =\n accessDeviceResources.enableFeature.cpu.value *\n accessDeviceResources.enableFeature.cpu.weight;\n const memory =\n accessDeviceResources.enableFeature.memory.value *\n accessDeviceResources.enableFeature.memory.weight;\n sum += cpu + memory;\n }\n\n if (accessInputs.doors > 0) {\n const cpu =\n accessInputs.doors *\n (accessDeviceResources.door.data.cpu.value *\n accessDeviceResources.door.data.cpu.weight);\n const memory =\n accessInputs.doors *\n (accessDeviceResources.door.data.memory.value *\n accessDeviceResources.door.data.memory.weight);\n sum += cpu + memory;\n }\n\n return sum;\n }, [deviceResourceData, inputs]);\n\n const computedResourcesLoadRatio = useMemo(() => {\n return (\n networkResources + talkResources + accessResources + protectResources\n );\n }, [networkResources, talkResources, accessResources, protectResources]);\n\n return {\n computedResourcesLoadRatio,\n };\n};\n"],"names":["useComputeResourceCalculator","deviceResourceData","inputs","networkResources","useMemo","networkDeviceResources","Network","networkInputs","FeatureId","enabled","sum","cpu","enableFeature","value","weight","memory","accessPoints","accessPoint","data","vpn","detections","securityDetection","adBlocking","qos","protectResources","protectDeviceResources","Protect","protectInputs","CAMERA_WEIGHT_FACTOR","cameraHd","camera2k","camera4k","talkResources","talkDeviceResources","Talk","talkInputs","phones","phone","record","accessResources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AAA,CACF;AACF,CAAA;"}
|
|
@@ -19,8 +19,8 @@ var ComputeResourceCalculator_types = require('../../../../ComputeResourceCalcul
|
|
|
19
19
|
var CustomImage = require('../../../../../CustomImage/CustomImage.js');
|
|
20
20
|
var SearchIcon = require("../../../../../../assets/search2.svg");
|
|
21
21
|
var StyleableSvgImage = require('../../../../../StyleableSvgImage/StyleableSvgImage.js');
|
|
22
|
-
var MinusIcon = require("../../../../../../assets/
|
|
23
|
-
var PlusIcon = require("../../../../../../assets/
|
|
22
|
+
var MinusIcon = require("../../../../../../assets/minus5.svg");
|
|
23
|
+
var PlusIcon = require("../../../../../../assets/plus6.svg");
|
|
24
24
|
function _interopDefault(e) {
|
|
25
25
|
return e && e.__esModule ? e : {
|
|
26
26
|
default: e
|
|
@@ -17,8 +17,8 @@ import { isMessageFormatted } from '../../../../ComputeResourceCalculator/Comput
|
|
|
17
17
|
import { CustomImage } from '../../../../../CustomImage/CustomImage.mjs';
|
|
18
18
|
import SearchIcon__default from "../../../../../../assets/search2.svg";
|
|
19
19
|
import { StyleableSvgImage } from '../../../../../StyleableSvgImage/StyleableSvgImage.mjs';
|
|
20
|
-
import MinusIcon__default from "../../../../../../assets/
|
|
21
|
-
import PlusIcon__default from "../../../../../../assets/
|
|
20
|
+
import MinusIcon__default from "../../../../../../assets/minus5.svg";
|
|
21
|
+
import PlusIcon__default from "../../../../../../assets/plus6.svg";
|
|
22
22
|
"use strict";
|
|
23
23
|
const PoeConsumerSelectModal = ({
|
|
24
24
|
isOpen,
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
var MinusIcon = require("../../../../../../assets/
|
|
6
|
+
var MinusIcon = require("../../../../../../assets/minus5.svg");
|
|
7
7
|
function _interopDefault(e) {
|
|
8
8
|
return e && e.__esModule ? e : {
|
|
9
9
|
default: e
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from "../../../../../../assets/
|
|
2
|
-
export { default } from "../../../../../../assets/
|
|
1
|
+
export * from "../../../../../../assets/minus5.svg";
|
|
2
|
+
export { default } from "../../../../../../assets/minus5.svg";
|
|
3
3
|
//# sourceMappingURL=minus.svg.mjs.map
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
var PlusIcon = require("../../../../../../assets/
|
|
6
|
+
var PlusIcon = require("../../../../../../assets/plus6.svg");
|
|
7
7
|
function _interopDefault(e) {
|
|
8
8
|
return e && e.__esModule ? e : {
|
|
9
9
|
default: e
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from "../../../../../../assets/
|
|
2
|
-
export { default } from "../../../../../../assets/
|
|
1
|
+
export * from "../../../../../../assets/plus6.svg";
|
|
2
|
+
export { default } from "../../../../../../assets/plus6.svg";
|
|
3
3
|
//# sourceMappingURL=plus.svg.mjs.map
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
var efg = require("../../../../assets/efg.png");
|
|
7
|
+
function _interopDefault(e) {
|
|
8
|
+
return e && e.__esModule ? e : {
|
|
9
|
+
default: e
|
|
10
|
+
};
|
|
11
|
+
}
|
|
12
|
+
var efg__default = /*#__PURE__*/_interopDefault(efg);
|
|
13
|
+
Object.defineProperty(exports, "default", {
|
|
14
|
+
enumerable: true,
|
|
15
|
+
get: function () {
|
|
16
|
+
return efg__default["default"];
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
Object.keys(efg).forEach(function (k) {
|
|
20
|
+
if (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
|
|
21
|
+
enumerable: true,
|
|
22
|
+
get: function () {
|
|
23
|
+
return efg[k];
|
|
24
|
+
}
|
|
25
|
+
});
|
|
26
|
+
});
|
|
27
|
+
//# sourceMappingURL=efg.png.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"efg.png.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"efg.png.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
var ucgMax = require("../../../../assets/ucg-max.png");
|
|
7
|
+
function _interopDefault(e) {
|
|
8
|
+
return e && e.__esModule ? e : {
|
|
9
|
+
default: e
|
|
10
|
+
};
|
|
11
|
+
}
|
|
12
|
+
var ucgMax__default = /*#__PURE__*/_interopDefault(ucgMax);
|
|
13
|
+
Object.defineProperty(exports, "default", {
|
|
14
|
+
enumerable: true,
|
|
15
|
+
get: function () {
|
|
16
|
+
return ucgMax__default["default"];
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
Object.keys(ucgMax).forEach(function (k) {
|
|
20
|
+
if (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
|
|
21
|
+
enumerable: true,
|
|
22
|
+
get: function () {
|
|
23
|
+
return ucgMax[k];
|
|
24
|
+
}
|
|
25
|
+
});
|
|
26
|
+
});
|
|
27
|
+
//# sourceMappingURL=ucg-max.png.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ucg-max.png.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ucg-max.png.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -42,12 +42,13 @@ var EN_TRANSLATION = {
|
|
|
42
42
|
"talk.phones": "Phones",
|
|
43
43
|
"talk.callRecording": "Call Recording",
|
|
44
44
|
protect: protect,
|
|
45
|
+
"protect.noStorage": "No Storage",
|
|
45
46
|
"protect.hdCameras": "HD Cameras",
|
|
46
47
|
"protect.2kCameras": "2K Cameras",
|
|
47
48
|
"protect.4kCameras": "4K Cameras",
|
|
48
49
|
"protect.storageDriveSize": "Storage Drive Size",
|
|
49
50
|
"protect.days": "Days",
|
|
50
|
-
"protect.CkG2PlusNote": "Recording retention calculated for the pre-installed 1 TB HDD. Increase retention by upgrading storage capacity.",
|
|
51
|
+
"protect.CkG2PlusNote": "Recording retention calculated for the pre-installed 1 TB HDD/SSD. Increase retention by upgrading storage capacity.",
|
|
51
52
|
"protect.DreamWallNote": "Recording retention calculated for the pre-installed 512 GB microSD card. Increase retention by upgrading storage capacity.",
|
|
52
53
|
"protect.storageProtection": "This drive is reserved for storage protection.",
|
|
53
54
|
network: network,
|
|
@@ -65,6 +66,8 @@ var EN_TRANSLATION = {
|
|
|
65
66
|
"device.CloudKey+": "CloudKey+",
|
|
66
67
|
"device.UDW": "UDW",
|
|
67
68
|
"device.UDR": "UDR",
|
|
69
|
+
"device.EFG": "EFG",
|
|
70
|
+
"device.UCG Max": "UCG Max",
|
|
68
71
|
showMore: showMore,
|
|
69
72
|
showLess: showLess,
|
|
70
73
|
add: add,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"en.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"en.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -37,12 +37,13 @@ var EN_TRANSLATION = {
|
|
|
37
37
|
"talk.phones": "Phones",
|
|
38
38
|
"talk.callRecording": "Call Recording",
|
|
39
39
|
protect: protect,
|
|
40
|
+
"protect.noStorage": "No Storage",
|
|
40
41
|
"protect.hdCameras": "HD Cameras",
|
|
41
42
|
"protect.2kCameras": "2K Cameras",
|
|
42
43
|
"protect.4kCameras": "4K Cameras",
|
|
43
44
|
"protect.storageDriveSize": "Storage Drive Size",
|
|
44
45
|
"protect.days": "Days",
|
|
45
|
-
"protect.CkG2PlusNote": "Recording retention calculated for the pre-installed 1 TB HDD. Increase retention by upgrading storage capacity.",
|
|
46
|
+
"protect.CkG2PlusNote": "Recording retention calculated for the pre-installed 1 TB HDD/SSD. Increase retention by upgrading storage capacity.",
|
|
46
47
|
"protect.DreamWallNote": "Recording retention calculated for the pre-installed 512 GB microSD card. Increase retention by upgrading storage capacity.",
|
|
47
48
|
"protect.storageProtection": "This drive is reserved for storage protection.",
|
|
48
49
|
network: network,
|
|
@@ -60,6 +61,8 @@ var EN_TRANSLATION = {
|
|
|
60
61
|
"device.CloudKey+": "CloudKey+",
|
|
61
62
|
"device.UDW": "UDW",
|
|
62
63
|
"device.UDR": "UDR",
|
|
64
|
+
"device.EFG": "EFG",
|
|
65
|
+
"device.UCG Max": "UCG Max",
|
|
63
66
|
showMore: showMore,
|
|
64
67
|
showLess: showLess,
|
|
65
68
|
add: add,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"en.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"en.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/lib/components/ResourceCalculatorV1/translations/useResourceCalculatorTranslation.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare const useResourceCalculatorTranslation: () => {
|
|
2
|
-
intl: import("@formatjs/intl").IntlShape<"add" | "network" | "protect" | "talk" | "access" | "portCount" | "ports" | "capacityCalculator" | "computeResources" | "estimatesMayVary" | "cloudKeyNote" | "capacityExceeded" | "systemCapacity" | "poeCapacity" | "access.doors" | "talk.phones" | "talk.callRecording" | "protect.hdCameras" | "protect.2kCameras" | "protect.4kCameras" | "protect.storageDriveSize" | "protect.days" | "protect.CkG2PlusNote" | "protect.DreamWallNote" | "protect.storageProtection" | "network.accessPoints" | "network.vpn" | "network.securityDetections" | "network.adBlocking" | "network.qos" | "network.clientsPerAP" | "network.maxFeaturesNote" | "device.UDM Pro Max" | "device.UDM Pro / SE" | "device.UNVR" | "device.UNVR Pro" | "device.CloudKey+" | "device.UDW" | "device.UDR" | "showMore" | "showLess" | "notAvailable" | "addPorts" | "recommendedPoeSwitches" | "requirements" | "watts" | "removePorts" | "poePowerBudget" | "assignPoeDevices" | "adjustYourDevice" | "poeConsumer.empty" | "poeConsumer.Swiss Army Knife Ultra" | "poeConsumer.U7 Pro" | "poeConsumer.U6 Pro" | "poeConsumer.U6 Long-Range" | "poeConsumer.AC Pro" | "poeConsumer.U6 Enterprise" | "poeConsumer.U6+" | "poeConsumer.AC Mesh" | "poeConsumer.U6 Mesh" | "poeConsumer.U6 In-Wall" | "poeConsumer.U6 Enterprise In-Wall" | "poeConsumer.AC Mesh Pro" | "poeConsumer.Building Bridge XG" | "poeConsumer.Building Bridge" | "poeConsumer.AC In-Wall" | "poeConsumer.U6 Lite" | "poeConsumer.WiFi BaseStation XG" | "poeConsumer.AC Long-Range" | "poeConsumer.AC Lite" | "poeConsumer.AI Pro" | "poeConsumer.G5 Bullet" | "poeConsumer.G5 Dome" | "poeConsumer.G5 Flex" | "poeConsumer.G5 Pro" | "poeConsumer.G5 Pro with Enhancer" | "poeConsumer.AI Theta" | "poeConsumer.G4 PTZ" | "poeConsumer.AI 360" | "poeConsumer.AI Bullet" | "poeConsumer.G4 Pro" | "poeConsumer.G4 Bullet" | "poeConsumer.G4 Dome" | "poeConsumer.G3 Flex" | "poeConsumer.G4 Doorbell Pro PoE Kit" | "poeConsumer.AI DSLR" | "poeConsumer.AI DSLR LD" | "poeConsumer.Protect Viewport" | "poeConsumer.Protect Floodlight" | "poeConsumer.Access Hub" | "poeConsumer.Access Reader G2 Pro" | "poeConsumer.Access Reader G2" | "poeConsumer.Access Reader Lite" | "poeConsumer.Connect Display" | "poeConsumer.Phone Touch Max" | "poeConsumer.Phone Touch" | "poeConsumer.Analog Telephone Adapter" | "category.Access Points" | "category.Cameras" | "category.Door Access" | "category.Connect Display" | "category.Talk" | "poeProvider.Standard 24 PoE" | "poeProvider.Standard 48 PoE" | "poeProvider.Pro 24 PoE" | "poeProvider.Pro 48 PoE" | "poeProvider.Lite 16 PoE" | "poeProvider.Lite 8 PoE" | "poeProvider.Flex" | "poeProvider.Standard 16 PoE" | "poeProvider.Pro Max 24 PoE" | "poeProvider.Pro Max 48 PoE" | "poeProvider.Enterprise 24 PoE" | "poeProvider.Enterprise 48 PoE" | "poeProvider.Mission Critical" | "poeProvider.8 PoE (Gen1)" | "poeProvider.Standard 24 PoE (Gen1)" | "poeProvider.Standard 48 PoE (Gen1)" | "poeProvider.XG 6 PoE (Gen1)" | "poeProvider.Pro 8 PoE" | "poeProvider.Enterprise 8 PoE" | "poeProvider.Industrial" | "poeProvider.8 PoE, SFP (Gen1)" | "poeProvider.Standard 16 PoE (Gen1)" | "poeProvider.Ultra" | "poeProvider.Ultra 60W" | "poeProvider.Ultra 210W" | "designCenter.title" | "designCenter.startYourProject">;
|
|
3
|
-
formatMessage: (id: "add" | "network" | "protect" | "talk" | "access" | "portCount" | "ports" | "capacityCalculator" | "computeResources" | "estimatesMayVary" | "cloudKeyNote" | "capacityExceeded" | "systemCapacity" | "poeCapacity" | "access.doors" | "talk.phones" | "talk.callRecording" | "protect.hdCameras" | "protect.2kCameras" | "protect.4kCameras" | "protect.storageDriveSize" | "protect.days" | "protect.CkG2PlusNote" | "protect.DreamWallNote" | "protect.storageProtection" | "network.accessPoints" | "network.vpn" | "network.securityDetections" | "network.adBlocking" | "network.qos" | "network.clientsPerAP" | "network.maxFeaturesNote" | "device.UDM Pro Max" | "device.UDM Pro / SE" | "device.UNVR" | "device.UNVR Pro" | "device.CloudKey+" | "device.UDW" | "device.UDR" | "showMore" | "showLess" | "notAvailable" | "addPorts" | "recommendedPoeSwitches" | "requirements" | "watts" | "removePorts" | "poePowerBudget" | "assignPoeDevices" | "adjustYourDevice" | "poeConsumer.empty" | "poeConsumer.Swiss Army Knife Ultra" | "poeConsumer.U7 Pro" | "poeConsumer.U6 Pro" | "poeConsumer.U6 Long-Range" | "poeConsumer.AC Pro" | "poeConsumer.U6 Enterprise" | "poeConsumer.U6+" | "poeConsumer.AC Mesh" | "poeConsumer.U6 Mesh" | "poeConsumer.U6 In-Wall" | "poeConsumer.U6 Enterprise In-Wall" | "poeConsumer.AC Mesh Pro" | "poeConsumer.Building Bridge XG" | "poeConsumer.Building Bridge" | "poeConsumer.AC In-Wall" | "poeConsumer.U6 Lite" | "poeConsumer.WiFi BaseStation XG" | "poeConsumer.AC Long-Range" | "poeConsumer.AC Lite" | "poeConsumer.AI Pro" | "poeConsumer.G5 Bullet" | "poeConsumer.G5 Dome" | "poeConsumer.G5 Flex" | "poeConsumer.G5 Pro" | "poeConsumer.G5 Pro with Enhancer" | "poeConsumer.AI Theta" | "poeConsumer.G4 PTZ" | "poeConsumer.AI 360" | "poeConsumer.AI Bullet" | "poeConsumer.G4 Pro" | "poeConsumer.G4 Bullet" | "poeConsumer.G4 Dome" | "poeConsumer.G3 Flex" | "poeConsumer.G4 Doorbell Pro PoE Kit" | "poeConsumer.AI DSLR" | "poeConsumer.AI DSLR LD" | "poeConsumer.Protect Viewport" | "poeConsumer.Protect Floodlight" | "poeConsumer.Access Hub" | "poeConsumer.Access Reader G2 Pro" | "poeConsumer.Access Reader G2" | "poeConsumer.Access Reader Lite" | "poeConsumer.Connect Display" | "poeConsumer.Phone Touch Max" | "poeConsumer.Phone Touch" | "poeConsumer.Analog Telephone Adapter" | "category.Access Points" | "category.Cameras" | "category.Door Access" | "category.Connect Display" | "category.Talk" | "poeProvider.Standard 24 PoE" | "poeProvider.Standard 48 PoE" | "poeProvider.Pro 24 PoE" | "poeProvider.Pro 48 PoE" | "poeProvider.Lite 16 PoE" | "poeProvider.Lite 8 PoE" | "poeProvider.Flex" | "poeProvider.Standard 16 PoE" | "poeProvider.Pro Max 24 PoE" | "poeProvider.Pro Max 48 PoE" | "poeProvider.Enterprise 24 PoE" | "poeProvider.Enterprise 48 PoE" | "poeProvider.Mission Critical" | "poeProvider.8 PoE (Gen1)" | "poeProvider.Standard 24 PoE (Gen1)" | "poeProvider.Standard 48 PoE (Gen1)" | "poeProvider.XG 6 PoE (Gen1)" | "poeProvider.Pro 8 PoE" | "poeProvider.Enterprise 8 PoE" | "poeProvider.Industrial" | "poeProvider.8 PoE, SFP (Gen1)" | "poeProvider.Standard 16 PoE (Gen1)" | "poeProvider.Ultra" | "poeProvider.Ultra 60W" | "poeProvider.Ultra 210W" | "designCenter.title" | "designCenter.startYourProject", values?: {
|
|
2
|
+
intl: import("@formatjs/intl").IntlShape<"add" | "network" | "protect" | "talk" | "access" | "portCount" | "ports" | "capacityCalculator" | "computeResources" | "estimatesMayVary" | "cloudKeyNote" | "capacityExceeded" | "systemCapacity" | "poeCapacity" | "access.doors" | "talk.phones" | "talk.callRecording" | "protect.noStorage" | "protect.hdCameras" | "protect.2kCameras" | "protect.4kCameras" | "protect.storageDriveSize" | "protect.days" | "protect.CkG2PlusNote" | "protect.DreamWallNote" | "protect.storageProtection" | "network.accessPoints" | "network.vpn" | "network.securityDetections" | "network.adBlocking" | "network.qos" | "network.clientsPerAP" | "network.maxFeaturesNote" | "device.UDM Pro Max" | "device.UDM Pro / SE" | "device.UNVR" | "device.UNVR Pro" | "device.CloudKey+" | "device.UDW" | "device.UDR" | "device.EFG" | "device.UCG Max" | "showMore" | "showLess" | "notAvailable" | "addPorts" | "recommendedPoeSwitches" | "requirements" | "watts" | "removePorts" | "poePowerBudget" | "assignPoeDevices" | "adjustYourDevice" | "poeConsumer.empty" | "poeConsumer.Swiss Army Knife Ultra" | "poeConsumer.U7 Pro" | "poeConsumer.U6 Pro" | "poeConsumer.U6 Long-Range" | "poeConsumer.AC Pro" | "poeConsumer.U6 Enterprise" | "poeConsumer.U6+" | "poeConsumer.AC Mesh" | "poeConsumer.U6 Mesh" | "poeConsumer.U6 In-Wall" | "poeConsumer.U6 Enterprise In-Wall" | "poeConsumer.AC Mesh Pro" | "poeConsumer.Building Bridge XG" | "poeConsumer.Building Bridge" | "poeConsumer.AC In-Wall" | "poeConsumer.U6 Lite" | "poeConsumer.WiFi BaseStation XG" | "poeConsumer.AC Long-Range" | "poeConsumer.AC Lite" | "poeConsumer.AI Pro" | "poeConsumer.G5 Bullet" | "poeConsumer.G5 Dome" | "poeConsumer.G5 Flex" | "poeConsumer.G5 Pro" | "poeConsumer.G5 Pro with Enhancer" | "poeConsumer.AI Theta" | "poeConsumer.G4 PTZ" | "poeConsumer.AI 360" | "poeConsumer.AI Bullet" | "poeConsumer.G4 Pro" | "poeConsumer.G4 Bullet" | "poeConsumer.G4 Dome" | "poeConsumer.G3 Flex" | "poeConsumer.G4 Doorbell Pro PoE Kit" | "poeConsumer.AI DSLR" | "poeConsumer.AI DSLR LD" | "poeConsumer.Protect Viewport" | "poeConsumer.Protect Floodlight" | "poeConsumer.Access Hub" | "poeConsumer.Access Reader G2 Pro" | "poeConsumer.Access Reader G2" | "poeConsumer.Access Reader Lite" | "poeConsumer.Connect Display" | "poeConsumer.Phone Touch Max" | "poeConsumer.Phone Touch" | "poeConsumer.Analog Telephone Adapter" | "category.Access Points" | "category.Cameras" | "category.Door Access" | "category.Connect Display" | "category.Talk" | "poeProvider.Standard 24 PoE" | "poeProvider.Standard 48 PoE" | "poeProvider.Pro 24 PoE" | "poeProvider.Pro 48 PoE" | "poeProvider.Lite 16 PoE" | "poeProvider.Lite 8 PoE" | "poeProvider.Flex" | "poeProvider.Standard 16 PoE" | "poeProvider.Pro Max 24 PoE" | "poeProvider.Pro Max 48 PoE" | "poeProvider.Enterprise 24 PoE" | "poeProvider.Enterprise 48 PoE" | "poeProvider.Mission Critical" | "poeProvider.8 PoE (Gen1)" | "poeProvider.Standard 24 PoE (Gen1)" | "poeProvider.Standard 48 PoE (Gen1)" | "poeProvider.XG 6 PoE (Gen1)" | "poeProvider.Pro 8 PoE" | "poeProvider.Enterprise 8 PoE" | "poeProvider.Industrial" | "poeProvider.8 PoE, SFP (Gen1)" | "poeProvider.Standard 16 PoE (Gen1)" | "poeProvider.Ultra" | "poeProvider.Ultra 60W" | "poeProvider.Ultra 210W" | "designCenter.title" | "designCenter.startYourProject">;
|
|
3
|
+
formatMessage: (id: "add" | "network" | "protect" | "talk" | "access" | "portCount" | "ports" | "capacityCalculator" | "computeResources" | "estimatesMayVary" | "cloudKeyNote" | "capacityExceeded" | "systemCapacity" | "poeCapacity" | "access.doors" | "talk.phones" | "talk.callRecording" | "protect.noStorage" | "protect.hdCameras" | "protect.2kCameras" | "protect.4kCameras" | "protect.storageDriveSize" | "protect.days" | "protect.CkG2PlusNote" | "protect.DreamWallNote" | "protect.storageProtection" | "network.accessPoints" | "network.vpn" | "network.securityDetections" | "network.adBlocking" | "network.qos" | "network.clientsPerAP" | "network.maxFeaturesNote" | "device.UDM Pro Max" | "device.UDM Pro / SE" | "device.UNVR" | "device.UNVR Pro" | "device.CloudKey+" | "device.UDW" | "device.UDR" | "device.EFG" | "device.UCG Max" | "showMore" | "showLess" | "notAvailable" | "addPorts" | "recommendedPoeSwitches" | "requirements" | "watts" | "removePorts" | "poePowerBudget" | "assignPoeDevices" | "adjustYourDevice" | "poeConsumer.empty" | "poeConsumer.Swiss Army Knife Ultra" | "poeConsumer.U7 Pro" | "poeConsumer.U6 Pro" | "poeConsumer.U6 Long-Range" | "poeConsumer.AC Pro" | "poeConsumer.U6 Enterprise" | "poeConsumer.U6+" | "poeConsumer.AC Mesh" | "poeConsumer.U6 Mesh" | "poeConsumer.U6 In-Wall" | "poeConsumer.U6 Enterprise In-Wall" | "poeConsumer.AC Mesh Pro" | "poeConsumer.Building Bridge XG" | "poeConsumer.Building Bridge" | "poeConsumer.AC In-Wall" | "poeConsumer.U6 Lite" | "poeConsumer.WiFi BaseStation XG" | "poeConsumer.AC Long-Range" | "poeConsumer.AC Lite" | "poeConsumer.AI Pro" | "poeConsumer.G5 Bullet" | "poeConsumer.G5 Dome" | "poeConsumer.G5 Flex" | "poeConsumer.G5 Pro" | "poeConsumer.G5 Pro with Enhancer" | "poeConsumer.AI Theta" | "poeConsumer.G4 PTZ" | "poeConsumer.AI 360" | "poeConsumer.AI Bullet" | "poeConsumer.G4 Pro" | "poeConsumer.G4 Bullet" | "poeConsumer.G4 Dome" | "poeConsumer.G3 Flex" | "poeConsumer.G4 Doorbell Pro PoE Kit" | "poeConsumer.AI DSLR" | "poeConsumer.AI DSLR LD" | "poeConsumer.Protect Viewport" | "poeConsumer.Protect Floodlight" | "poeConsumer.Access Hub" | "poeConsumer.Access Reader G2 Pro" | "poeConsumer.Access Reader G2" | "poeConsumer.Access Reader Lite" | "poeConsumer.Connect Display" | "poeConsumer.Phone Touch Max" | "poeConsumer.Phone Touch" | "poeConsumer.Analog Telephone Adapter" | "category.Access Points" | "category.Cameras" | "category.Door Access" | "category.Connect Display" | "category.Talk" | "poeProvider.Standard 24 PoE" | "poeProvider.Standard 48 PoE" | "poeProvider.Pro 24 PoE" | "poeProvider.Pro 48 PoE" | "poeProvider.Lite 16 PoE" | "poeProvider.Lite 8 PoE" | "poeProvider.Flex" | "poeProvider.Standard 16 PoE" | "poeProvider.Pro Max 24 PoE" | "poeProvider.Pro Max 48 PoE" | "poeProvider.Enterprise 24 PoE" | "poeProvider.Enterprise 48 PoE" | "poeProvider.Mission Critical" | "poeProvider.8 PoE (Gen1)" | "poeProvider.Standard 24 PoE (Gen1)" | "poeProvider.Standard 48 PoE (Gen1)" | "poeProvider.XG 6 PoE (Gen1)" | "poeProvider.Pro 8 PoE" | "poeProvider.Enterprise 8 PoE" | "poeProvider.Industrial" | "poeProvider.8 PoE, SFP (Gen1)" | "poeProvider.Standard 16 PoE (Gen1)" | "poeProvider.Ultra" | "poeProvider.Ultra 60W" | "poeProvider.Ultra 210W" | "designCenter.title" | "designCenter.startYourProject", values?: {
|
|
4
4
|
[x: string]: import("intl-messageformat").PrimitiveType | import("intl-messageformat").FormatXMLElementFn<string, string>;
|
|
5
5
|
}) => string;
|
|
6
6
|
};
|
|
@@ -4,7 +4,7 @@ var jsxRuntime = require('react/jsx-runtime');
|
|
|
4
4
|
require('./assets/check.svg.js');
|
|
5
5
|
require('./assets/plus.svg.js');
|
|
6
6
|
var CheckBox_styles = require('./CheckBox.styles.js');
|
|
7
|
-
var CheckIcon = require("../../../assets/
|
|
7
|
+
var CheckIcon = require("../../../assets/check3.svg");
|
|
8
8
|
var PlusIcon = require("../../../assets/plus4.svg");
|
|
9
9
|
function _interopDefault(e) {
|
|
10
10
|
return e && e.__esModule ? e : {
|
|
@@ -2,7 +2,7 @@ import { jsxs, jsx } from 'react/jsx-runtime';
|
|
|
2
2
|
import './assets/check.svg.mjs';
|
|
3
3
|
import './assets/plus.svg.mjs';
|
|
4
4
|
import { CheckBox as CheckBox$1, Input, CheckIcon, PlusIcon } from './CheckBox.styles.mjs';
|
|
5
|
-
import CheckIcon__default from "../../../assets/
|
|
5
|
+
import CheckIcon__default from "../../../assets/check3.svg";
|
|
6
6
|
import PlusIcon__default from "../../../assets/plus4.svg";
|
|
7
7
|
"use strict";
|
|
8
8
|
const CheckBox = function CheckBox2({
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
var CheckIcon = require("../../../../assets/
|
|
6
|
+
var CheckIcon = require("../../../../assets/check3.svg");
|
|
7
7
|
function _interopDefault(e) {
|
|
8
8
|
return e && e.__esModule ? e : {
|
|
9
9
|
default: e
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from "../../../../assets/
|
|
2
|
-
export { default } from "../../../../assets/
|
|
1
|
+
export * from "../../../../assets/check3.svg";
|
|
2
|
+
export { default } from "../../../../assets/check3.svg";
|
|
3
3
|
//# sourceMappingURL=check.svg.mjs.map
|
|
@@ -3,24 +3,24 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
var
|
|
6
|
+
var _externalAssets_NxsKXHyJ = require("../../../../assets/black.svg");
|
|
7
7
|
function _interopDefault(e) {
|
|
8
8
|
return e && e.__esModule ? e : {
|
|
9
9
|
default: e
|
|
10
10
|
};
|
|
11
11
|
}
|
|
12
|
-
var
|
|
12
|
+
var _externalAssets_NxsKXHyJ__default = /*#__PURE__*/_interopDefault(_externalAssets_NxsKXHyJ);
|
|
13
13
|
Object.defineProperty(exports, "default", {
|
|
14
14
|
enumerable: true,
|
|
15
15
|
get: function () {
|
|
16
|
-
return
|
|
16
|
+
return _externalAssets_NxsKXHyJ__default["default"];
|
|
17
17
|
}
|
|
18
18
|
});
|
|
19
|
-
Object.keys(
|
|
19
|
+
Object.keys(_externalAssets_NxsKXHyJ).forEach(function (k) {
|
|
20
20
|
if (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
|
|
21
21
|
enumerable: true,
|
|
22
22
|
get: function () {
|
|
23
|
-
return
|
|
23
|
+
return _externalAssets_NxsKXHyJ[k];
|
|
24
24
|
}
|
|
25
25
|
});
|
|
26
26
|
});
|
|
@@ -6,7 +6,7 @@ require('./darkGrey.svg.js');
|
|
|
6
6
|
require('./grey.svg.js');
|
|
7
7
|
require('./lightGrey.svg.js');
|
|
8
8
|
require('./white.svg.js');
|
|
9
|
-
var
|
|
9
|
+
var _externalAssets_NxsKXHyJ = require("../../../../assets/black.svg");
|
|
10
10
|
var _externalAssets_DTFMFQ51 = require("../../../../assets/blue.svg");
|
|
11
11
|
var _externalAssets_B1Gj17va = require("../../../../assets/darkGrey.svg");
|
|
12
12
|
var _externalAssets_So87DWAv = require("../../../../assets/grey.svg");
|
|
@@ -17,7 +17,7 @@ function _interopDefault(e) {
|
|
|
17
17
|
default: e
|
|
18
18
|
};
|
|
19
19
|
}
|
|
20
|
-
var
|
|
20
|
+
var _externalAssets_NxsKXHyJ__default = /*#__PURE__*/_interopDefault(_externalAssets_NxsKXHyJ);
|
|
21
21
|
var _externalAssets_DTFMFQ51__default = /*#__PURE__*/_interopDefault(_externalAssets_DTFMFQ51);
|
|
22
22
|
var _externalAssets_B1Gj17va__default = /*#__PURE__*/_interopDefault(_externalAssets_B1Gj17va);
|
|
23
23
|
var _externalAssets_So87DWAv__default = /*#__PURE__*/_interopDefault(_externalAssets_So87DWAv);
|
|
@@ -27,7 +27,7 @@ var _externalAssets_Dh1AHi98__default = /*#__PURE__*/_interopDefault(_externalAs
|
|
|
27
27
|
Object.defineProperty(exports, "black", {
|
|
28
28
|
enumerable: true,
|
|
29
29
|
get: function () {
|
|
30
|
-
return
|
|
30
|
+
return _externalAssets_NxsKXHyJ__default["default"];
|
|
31
31
|
}
|
|
32
32
|
});
|
|
33
33
|
Object.defineProperty(exports, "blue", {
|
|
@@ -3,24 +3,24 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
var
|
|
6
|
+
var _externalAssets_WKvVtlSv = require("../../../../assets/black.svg");
|
|
7
7
|
function _interopDefault(e) {
|
|
8
8
|
return e && e.__esModule ? e : {
|
|
9
9
|
default: e
|
|
10
10
|
};
|
|
11
11
|
}
|
|
12
|
-
var
|
|
12
|
+
var _externalAssets_WKvVtlSv__default = /*#__PURE__*/_interopDefault(_externalAssets_WKvVtlSv);
|
|
13
13
|
Object.defineProperty(exports, "default", {
|
|
14
14
|
enumerable: true,
|
|
15
15
|
get: function () {
|
|
16
|
-
return
|
|
16
|
+
return _externalAssets_WKvVtlSv__default["default"];
|
|
17
17
|
}
|
|
18
18
|
});
|
|
19
|
-
Object.keys(
|
|
19
|
+
Object.keys(_externalAssets_WKvVtlSv).forEach(function (k) {
|
|
20
20
|
if (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
|
|
21
21
|
enumerable: true,
|
|
22
22
|
get: function () {
|
|
23
|
-
return
|
|
23
|
+
return _externalAssets_WKvVtlSv[k];
|
|
24
24
|
}
|
|
25
25
|
});
|
|
26
26
|
});
|
|
@@ -6,7 +6,7 @@ require('./camo.png.js');
|
|
|
6
6
|
require('./concrete.png.js');
|
|
7
7
|
require('./marble.png.js');
|
|
8
8
|
require('./wood.png.js');
|
|
9
|
-
var
|
|
9
|
+
var _externalAssets_WKvVtlSv = require("../../../../assets/black.svg");
|
|
10
10
|
var _externalAssets_DxR_vr6$ = require("../../../../assets/blackFabric.png");
|
|
11
11
|
var _externalAssets_D_2KPJKL = require("../../../../assets/camo.png");
|
|
12
12
|
var _externalAssets_AeQRmq$G = require("../../../../assets/concrete.png");
|
|
@@ -17,7 +17,7 @@ function _interopDefault(e) {
|
|
|
17
17
|
default: e
|
|
18
18
|
};
|
|
19
19
|
}
|
|
20
|
-
var
|
|
20
|
+
var _externalAssets_WKvVtlSv__default = /*#__PURE__*/_interopDefault(_externalAssets_WKvVtlSv);
|
|
21
21
|
var _externalAssets_DxR_vr6$__default = /*#__PURE__*/_interopDefault(_externalAssets_DxR_vr6$);
|
|
22
22
|
var _externalAssets_D_2KPJKL__default = /*#__PURE__*/_interopDefault(_externalAssets_D_2KPJKL);
|
|
23
23
|
var _externalAssets_AeQRmq$G__default = /*#__PURE__*/_interopDefault(_externalAssets_AeQRmq$G);
|
|
@@ -27,7 +27,7 @@ var _externalAssets_kQL$tT0V__default = /*#__PURE__*/_interopDefault(_externalAs
|
|
|
27
27
|
Object.defineProperty(exports, "black", {
|
|
28
28
|
enumerable: true,
|
|
29
29
|
get: function () {
|
|
30
|
-
return
|
|
30
|
+
return _externalAssets_WKvVtlSv__default["default"];
|
|
31
31
|
}
|
|
32
32
|
});
|
|
33
33
|
Object.defineProperty(exports, "blackFabric", {
|