@rfkit/charts 1.0.96 → 1.0.98

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.
@@ -11,6 +11,7 @@ interface SegmentContainerProps {
11
11
  style: React.CSSProperties;
12
12
  stationPositions: StationPosition[];
13
13
  currentFrequency: number;
14
+ segmentIndex: number;
14
15
  }
15
16
  declare const SegmentContainer: React.FC<SegmentContainerProps>;
16
17
  export default SegmentContainer;
package/index.js CHANGED
@@ -11426,7 +11426,7 @@ StationAllocation_styles_module_options.domAPI = styleDomAPI_default();
11426
11426
  StationAllocation_styles_module_options.insertStyleElement = insertStyleElement_default();
11427
11427
  injectStylesIntoStyleTag_default()(StationAllocation_styles_module.Z, StationAllocation_styles_module_options);
11428
11428
  const components_StationAllocation_styles_module = StationAllocation_styles_module.Z && StationAllocation_styles_module.Z.locals ? StationAllocation_styles_module.Z.locals : void 0;
11429
- const SegmentContainer_SegmentContainer = /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react__.memo)(({ style, stationPositions, currentFrequency })=>/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)("div", {
11429
+ const SegmentContainer_SegmentContainer = /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react__.memo)(({ style, stationPositions, currentFrequency, segmentIndex })=>/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)("div", {
11430
11430
  className: components_StationAllocation_styles_module.segmentContainer,
11431
11431
  style: style,
11432
11432
  children: stationPositions.map(({ station, position }, index)=>{
@@ -11438,7 +11438,7 @@ const SegmentContainer_SegmentContainer = /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_M
11438
11438
  width: position.width
11439
11439
  },
11440
11440
  title: `${station.signalName} - ${station.frequency}${station.orgName ? ` (${station.orgName})` : ''}`
11441
- }, `station-${station.signalName}-${station.frequency}-${index}`);
11441
+ }, `segment-${segmentIndex}-station-${station.signalName}-${station.frequency}-${index}`);
11442
11442
  })
11443
11443
  }));
11444
11444
  const StationAllocation_SegmentContainer = SegmentContainer_SegmentContainer;
@@ -11522,7 +11522,8 @@ const StationAllocation_StationAllocation = ({ show = true, display = true })=>{
11522
11522
  children: segmentData.map(({ segmentIndex, stationPositions, style })=>/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(StationAllocation_SegmentContainer, {
11523
11523
  style: style,
11524
11524
  stationPositions: stationPositions,
11525
- currentFrequency: currentFrequency
11525
+ currentFrequency: currentFrequency,
11526
+ segmentIndex: segmentIndex
11526
11527
  }, `segment-${segmentIndex}`))
11527
11528
  })
11528
11529
  });
@@ -13502,7 +13503,7 @@ function useSpectrumAnalyzer(props) {
13502
13503
  data: getExtraData(occupancyData.current),
13503
13504
  totalOccupancy: totalOccupancyData.current
13504
13505
  });
13505
- if (templateData.current && templateData.current.length > 0) updateSpectrum({
13506
+ if (templateData.current?.length > 0) updateSpectrum({
13506
13507
  template: getExtraData(templateData.current)
13507
13508
  });
13508
13509
  }
@@ -13546,7 +13547,7 @@ function useSpectrumAnalyzer(props) {
13546
13547
  if (e.extraData) updateExtraData(e.extraData);
13547
13548
  if (e.data) {
13548
13549
  analyzer.current.process(e);
13549
- if (templateData.current.length > 0) processExceedingData(e.data, templateData.current, e.timestamp);
13550
+ if (templateData.current?.length > 0) processExceedingData(e.data, templateData.current, e.timestamp);
13550
13551
  }
13551
13552
  if (e.maxData) analyzer.current.setMaxData(e.maxData);
13552
13553
  if (e.template) updateTemplateData(e.template);
package/package.json CHANGED
@@ -5,6 +5,6 @@
5
5
  "types": "index.d.ts",
6
6
  "author": "Hxgh",
7
7
  "license": "MIT",
8
- "version": "1.0.96",
8
+ "version": "1.0.98",
9
9
  "private": false
10
10
  }