react-science 10.0.0 → 11.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/components/accordion/accordion.d.ts +5 -0
- package/lib/components/accordion/accordion.d.ts.map +1 -1
- package/lib/components/accordion/accordion.js +6 -3
- package/lib/components/accordion/accordion.js.map +1 -1
- package/lib/components/accordion/accordion_context.d.ts +1 -0
- package/lib/components/accordion/accordion_context.d.ts.map +1 -1
- package/lib/components/accordion/accordion_context.js +2 -1
- package/lib/components/accordion/accordion_context.js.map +1 -1
- package/lib/components/accordion/accordion_context.provider.d.ts +1 -0
- package/lib/components/accordion/accordion_context.provider.d.ts.map +1 -1
- package/lib/components/accordion/accordion_context.provider.js +4 -2
- package/lib/components/accordion/accordion_context.provider.js.map +1 -1
- package/lib/components/accordion/accordion_context.state.d.ts +1 -0
- package/lib/components/accordion/accordion_context.state.d.ts.map +1 -1
- package/lib/components/accordion/accordion_context.state.js.map +1 -1
- package/lib/components/color-picker/preview/ColorPreview.d.ts +8 -1
- package/lib/components/color-picker/preview/ColorPreview.d.ts.map +1 -1
- package/lib/components/color-picker/preview/ColorPreview.js.map +1 -1
- package/lib/components/logger/FifoLoggerDialog.d.ts.map +1 -1
- package/lib/components/logger/FifoLoggerDialog.js +2 -2
- package/lib/components/logger/FifoLoggerDialog.js.map +1 -1
- package/lib/components/table/table_body.d.ts +3 -0
- package/lib/components/table/table_body.d.ts.map +1 -1
- package/lib/components/table/table_body.js +33 -10
- package/lib/components/table/table_body.js.map +1 -1
- package/lib/components/table/table_root.d.ts +44 -1
- package/lib/components/table/table_root.d.ts.map +1 -1
- package/lib/components/table/table_root.js +33 -3
- package/lib/components/table/table_root.js.map +1 -1
- package/lib/components/table/table_row_cell.d.ts +1 -0
- package/lib/components/table/table_row_cell.d.ts.map +1 -1
- package/lib/components/table/table_row_cell.js +2 -2
- package/lib/components/table/table_row_cell.js.map +1 -1
- package/lib/components/table/table_utils.d.ts +3 -3
- package/lib/components/table/table_utils.d.ts.map +1 -1
- package/package.json +40 -47
- package/src/components/accordion/accordion.tsx +31 -17
- package/src/components/accordion/accordion_context.provider.tsx +8 -3
- package/src/components/accordion/accordion_context.state.ts +1 -0
- package/src/components/accordion/accordion_context.ts +2 -1
- package/src/components/color-picker/preview/ColorPreview.tsx +5 -1
- package/src/components/logger/FifoLoggerDialog.tsx +3 -4
- package/src/components/table/table_body.tsx +91 -17
- package/src/components/table/table_root.tsx +114 -13
- package/src/components/table/table_row_cell.tsx +3 -2
- package/src/components/table/table_utils.ts +5 -3
- package/lib/app/about/AboutDialogToolbarButton.d.ts +0 -10
- package/lib/app/about/AboutDialogToolbarButton.d.ts.map +0 -1
- package/lib/app/about/AboutDialogToolbarButton.js +0 -9
- package/lib/app/about/AboutDialogToolbarButton.js.map +0 -1
- package/lib/app/about/index.d.ts +0 -2
- package/lib/app/about/index.d.ts.map +0 -1
- package/lib/app/about/index.js +0 -2
- package/lib/app/about/index.js.map +0 -1
- package/lib/app/explorer/ExplorerPlotView.d.ts +0 -2
- package/lib/app/explorer/ExplorerPlotView.d.ts.map +0 -1
- package/lib/app/explorer/ExplorerPlotView.js +0 -16
- package/lib/app/explorer/ExplorerPlotView.js.map +0 -1
- package/lib/app/explorer/MeasurementExplorer.d.ts +0 -11
- package/lib/app/explorer/MeasurementExplorer.d.ts.map +0 -1
- package/lib/app/explorer/MeasurementExplorer.js +0 -114
- package/lib/app/explorer/MeasurementExplorer.js.map +0 -1
- package/lib/app/explorer/MeasurementExplorerWithState.d.ts +0 -2
- package/lib/app/explorer/MeasurementExplorerWithState.d.ts.map +0 -1
- package/lib/app/explorer/MeasurementExplorerWithState.js +0 -11
- package/lib/app/explorer/MeasurementExplorerWithState.js.map +0 -1
- package/lib/app/explorer/index.d.ts +0 -3
- package/lib/app/explorer/index.d.ts.map +0 -1
- package/lib/app/explorer/index.js +0 -3
- package/lib/app/explorer/index.js.map +0 -1
- package/lib/app/helpers/MeasurementPlot.d.ts +0 -22
- package/lib/app/helpers/MeasurementPlot.d.ts.map +0 -1
- package/lib/app/helpers/MeasurementPlot.js +0 -39
- package/lib/app/helpers/MeasurementPlot.js.map +0 -1
- package/lib/app/helpers/MeasurementVariableSelect.d.ts +0 -9
- package/lib/app/helpers/MeasurementVariableSelect.d.ts.map +0 -1
- package/lib/app/helpers/MeasurementVariableSelect.js +0 -11
- package/lib/app/helpers/MeasurementVariableSelect.js.map +0 -1
- package/lib/app/helpers/getColorFromConfig.d.ts +0 -3
- package/lib/app/helpers/getColorFromConfig.d.ts.map +0 -1
- package/lib/app/helpers/getColorFromConfig.js +0 -11
- package/lib/app/helpers/getColorFromConfig.js.map +0 -1
- package/lib/app/helpers/index.d.ts +0 -6
- package/lib/app/helpers/index.d.ts.map +0 -1
- package/lib/app/helpers/index.js +0 -6
- package/lib/app/helpers/index.js.map +0 -1
- package/lib/app/helpers/react-plot.d.ts +0 -8
- package/lib/app/helpers/react-plot.d.ts.map +0 -1
- package/lib/app/helpers/react-plot.js +0 -44
- package/lib/app/helpers/react-plot.js.map +0 -1
- package/lib/app/helpers/splitEntries.d.ts +0 -6
- package/lib/app/helpers/splitEntries.d.ts.map +0 -1
- package/lib/app/helpers/splitEntries.js +0 -16
- package/lib/app/helpers/splitEntries.js.map +0 -1
- package/lib/app/hooks/file-loading.d.ts +0 -9
- package/lib/app/hooks/file-loading.d.ts.map +0 -1
- package/lib/app/hooks/file-loading.js +0 -36
- package/lib/app/hooks/file-loading.js.map +0 -1
- package/lib/app/hooks/index.d.ts +0 -2
- package/lib/app/hooks/index.d.ts.map +0 -1
- package/lib/app/hooks/index.js +0 -2
- package/lib/app/hooks/index.js.map +0 -1
- package/lib/app/index.d.ts +0 -6
- package/lib/app/index.d.ts.map +0 -1
- package/lib/app/index.js +0 -6
- package/lib/app/index.js.map +0 -1
- package/lib/app/kinds/index.d.ts +0 -4
- package/lib/app/kinds/index.d.ts.map +0 -1
- package/lib/app/kinds/index.js +0 -4
- package/lib/app/kinds/index.js.map +0 -1
- package/lib/app/kinds/ir/IrPeaksPanel.d.ts +0 -25
- package/lib/app/kinds/ir/IrPeaksPanel.d.ts.map +0 -1
- package/lib/app/kinds/ir/IrPeaksPanel.js +0 -28
- package/lib/app/kinds/ir/IrPeaksPanel.js.map +0 -1
- package/lib/app/kinds/ir/index.d.ts +0 -2
- package/lib/app/kinds/ir/index.d.ts.map +0 -1
- package/lib/app/kinds/ir/index.js +0 -2
- package/lib/app/kinds/ir/index.js.map +0 -1
- package/lib/app/kinds/iv/index.d.ts +0 -2
- package/lib/app/kinds/iv/index.d.ts.map +0 -1
- package/lib/app/kinds/iv/index.js +0 -2
- package/lib/app/kinds/iv/index.js.map +0 -1
- package/lib/app/kinds/iv/plot-view/IvMeasurementsPlot.d.ts +0 -2
- package/lib/app/kinds/iv/plot-view/IvMeasurementsPlot.d.ts.map +0 -1
- package/lib/app/kinds/iv/plot-view/IvMeasurementsPlot.js +0 -50
- package/lib/app/kinds/iv/plot-view/IvMeasurementsPlot.js.map +0 -1
- package/lib/app/kinds/iv/plot-view/IvPlotVariablesSelector.d.ts +0 -2
- package/lib/app/kinds/iv/plot-view/IvPlotVariablesSelector.d.ts.map +0 -1
- package/lib/app/kinds/iv/plot-view/IvPlotVariablesSelector.js +0 -30
- package/lib/app/kinds/iv/plot-view/IvPlotVariablesSelector.js.map +0 -1
- package/lib/app/kinds/iv/plot-view/IvPlotView.d.ts +0 -2
- package/lib/app/kinds/iv/plot-view/IvPlotView.d.ts.map +0 -1
- package/lib/app/kinds/iv/plot-view/IvPlotView.js +0 -32
- package/lib/app/kinds/iv/plot-view/IvPlotView.js.map +0 -1
- package/lib/app/kinds/iv/plot-view/IvSeries.d.ts +0 -11
- package/lib/app/kinds/iv/plot-view/IvSeries.d.ts.map +0 -1
- package/lib/app/kinds/iv/plot-view/IvSeries.js +0 -23
- package/lib/app/kinds/iv/plot-view/IvSeries.js.map +0 -1
- package/lib/app/kinds/mass/MassPlotView.d.ts +0 -2
- package/lib/app/kinds/mass/MassPlotView.d.ts.map +0 -1
- package/lib/app/kinds/mass/MassPlotView.js +0 -11
- package/lib/app/kinds/mass/MassPlotView.js.map +0 -1
- package/lib/app/kinds/mass/MeasurementMassPlot.d.ts +0 -3
- package/lib/app/kinds/mass/MeasurementMassPlot.d.ts.map +0 -1
- package/lib/app/kinds/mass/MeasurementMassPlot.js +0 -75
- package/lib/app/kinds/mass/MeasurementMassPlot.js.map +0 -1
- package/lib/app/kinds/mass/index.d.ts +0 -3
- package/lib/app/kinds/mass/index.d.ts.map +0 -1
- package/lib/app/kinds/mass/index.js +0 -3
- package/lib/app/kinds/mass/index.js.map +0 -1
- package/lib/app/panels/SignalProcessingPanel.d.ts +0 -11
- package/lib/app/panels/SignalProcessingPanel.d.ts.map +0 -1
- package/lib/app/panels/SignalProcessingPanel.js +0 -104
- package/lib/app/panels/SignalProcessingPanel.js.map +0 -1
- package/lib/app/panels/index.d.ts +0 -5
- package/lib/app/panels/index.d.ts.map +0 -1
- package/lib/app/panels/index.js +0 -5
- package/lib/app/panels/index.js.map +0 -1
- package/lib/app/panels/measurement-config/MeasurementConfigPanel.d.ts +0 -2
- package/lib/app/panels/measurement-config/MeasurementConfigPanel.d.ts.map +0 -1
- package/lib/app/panels/measurement-config/MeasurementConfigPanel.js +0 -25
- package/lib/app/panels/measurement-config/MeasurementConfigPanel.js.map +0 -1
- package/lib/app/panels/measurement-config/MeasurementConfigPanelAccordion.d.ts +0 -2
- package/lib/app/panels/measurement-config/MeasurementConfigPanelAccordion.d.ts.map +0 -1
- package/lib/app/panels/measurement-config/MeasurementConfigPanelAccordion.js +0 -14
- package/lib/app/panels/measurement-config/MeasurementConfigPanelAccordion.js.map +0 -1
- package/lib/app/panels/measurement-config/index.d.ts +0 -3
- package/lib/app/panels/measurement-config/index.d.ts.map +0 -1
- package/lib/app/panels/measurement-config/index.js +0 -3
- package/lib/app/panels/measurement-config/index.js.map +0 -1
- package/lib/app/panels/measurement-info/MeasurementInfoPanel.d.ts +0 -2
- package/lib/app/panels/measurement-info/MeasurementInfoPanel.d.ts.map +0 -1
- package/lib/app/panels/measurement-info/MeasurementInfoPanel.js +0 -23
- package/lib/app/panels/measurement-info/MeasurementInfoPanel.js.map +0 -1
- package/lib/app/panels/measurement-info/MeasurementInfoPanelAccordion.d.ts +0 -2
- package/lib/app/panels/measurement-info/MeasurementInfoPanelAccordion.d.ts.map +0 -1
- package/lib/app/panels/measurement-info/MeasurementInfoPanelAccordion.js +0 -7
- package/lib/app/panels/measurement-info/MeasurementInfoPanelAccordion.js.map +0 -1
- package/lib/app/panels/measurement-info/index.d.ts +0 -3
- package/lib/app/panels/measurement-info/index.d.ts.map +0 -1
- package/lib/app/panels/measurement-info/index.js +0 -3
- package/lib/app/panels/measurement-info/index.js.map +0 -1
- package/lib/app/panels/measurements/MeasurementCheckbox.d.ts +0 -8
- package/lib/app/panels/measurements/MeasurementCheckbox.d.ts.map +0 -1
- package/lib/app/panels/measurements/MeasurementCheckbox.js +0 -22
- package/lib/app/panels/measurements/MeasurementCheckbox.js.map +0 -1
- package/lib/app/panels/measurements/MeasurementColorPreview.d.ts +0 -9
- package/lib/app/panels/measurements/MeasurementColorPreview.d.ts.map +0 -1
- package/lib/app/panels/measurements/MeasurementColorPreview.js +0 -45
- package/lib/app/panels/measurements/MeasurementColorPreview.js.map +0 -1
- package/lib/app/panels/measurements/MeasurementVisibilityToggle.d.ts +0 -12
- package/lib/app/panels/measurements/MeasurementVisibilityToggle.d.ts.map +0 -1
- package/lib/app/panels/measurements/MeasurementVisibilityToggle.js +0 -26
- package/lib/app/panels/measurements/MeasurementVisibilityToggle.js.map +0 -1
- package/lib/app/panels/measurements/MeasurementsPanel.d.ts +0 -4
- package/lib/app/panels/measurements/MeasurementsPanel.d.ts.map +0 -1
- package/lib/app/panels/measurements/MeasurementsPanel.js +0 -42
- package/lib/app/panels/measurements/MeasurementsPanel.js.map +0 -1
- package/lib/app/panels/measurements/MeasurementsPanelAccordion.d.ts +0 -2
- package/lib/app/panels/measurements/MeasurementsPanelAccordion.d.ts.map +0 -1
- package/lib/app/panels/measurements/MeasurementsPanelAccordion.js +0 -20
- package/lib/app/panels/measurements/MeasurementsPanelAccordion.js.map +0 -1
- package/lib/app/panels/measurements/MeasurementsTable.d.ts +0 -6
- package/lib/app/panels/measurements/MeasurementsTable.d.ts.map +0 -1
- package/lib/app/panels/measurements/MeasurementsTable.js +0 -159
- package/lib/app/panels/measurements/MeasurementsTable.js.map +0 -1
- package/lib/app/panels/measurements/index.d.ts +0 -9
- package/lib/app/panels/measurements/index.d.ts.map +0 -1
- package/lib/app/panels/measurements/index.js +0 -9
- package/lib/app/panels/measurements/index.js.map +0 -1
- package/lib/app/panels/measurements/measurement_panel_context.d.ts +0 -7
- package/lib/app/panels/measurements/measurement_panel_context.d.ts.map +0 -1
- package/lib/app/panels/measurements/measurement_panel_context.js +0 -10
- package/lib/app/panels/measurements/measurement_panel_context.js.map +0 -1
- package/lib/app/panels/measurements/measurement_panel_context.provider.d.ts +0 -7
- package/lib/app/panels/measurements/measurement_panel_context.provider.d.ts.map +0 -1
- package/lib/app/panels/measurements/measurement_panel_context.provider.js +0 -6
- package/lib/app/panels/measurements/measurement_panel_context.provider.js.map +0 -1
- package/lib/app-data/enhancers/enhance.d.ts +0 -8
- package/lib/app-data/enhancers/enhance.d.ts.map +0 -1
- package/lib/app-data/enhancers/enhance.js +0 -13
- package/lib/app-data/enhancers/enhance.js.map +0 -1
- package/lib/app-data/enhancers/index.d.ts +0 -2
- package/lib/app-data/enhancers/index.d.ts.map +0 -1
- package/lib/app-data/enhancers/index.js +0 -2
- package/lib/app-data/enhancers/index.js.map +0 -1
- package/lib/app-data/helpers/index.d.ts +0 -2
- package/lib/app-data/helpers/index.d.ts.map +0 -1
- package/lib/app-data/helpers/index.js +0 -2
- package/lib/app-data/helpers/index.js.map +0 -1
- package/lib/app-data/helpers/variables.d.ts +0 -6
- package/lib/app-data/helpers/variables.d.ts.map +0 -1
- package/lib/app-data/helpers/variables.js +0 -20
- package/lib/app-data/helpers/variables.js.map +0 -1
- package/lib/app-data/index.d.ts +0 -7
- package/lib/app-data/index.d.ts.map +0 -1
- package/lib/app-data/index.js +0 -7
- package/lib/app-data/index.js.map +0 -1
- package/lib/app-data/kinds/index.d.ts +0 -3
- package/lib/app-data/kinds/index.d.ts.map +0 -1
- package/lib/app-data/kinds/index.js +0 -3
- package/lib/app-data/kinds/index.js.map +0 -1
- package/lib/app-data/kinds/ir/IrMeasurement.d.ts +0 -13
- package/lib/app-data/kinds/ir/IrMeasurement.d.ts.map +0 -1
- package/lib/app-data/kinds/ir/IrMeasurement.js +0 -2
- package/lib/app-data/kinds/ir/IrMeasurement.js.map +0 -1
- package/lib/app-data/kinds/ir/IrPeak.d.ts +0 -8
- package/lib/app-data/kinds/ir/IrPeak.d.ts.map +0 -1
- package/lib/app-data/kinds/ir/IrPeak.js +0 -2
- package/lib/app-data/kinds/ir/IrPeak.js.map +0 -1
- package/lib/app-data/kinds/ir/index.d.ts +0 -5
- package/lib/app-data/kinds/ir/index.d.ts.map +0 -1
- package/lib/app-data/kinds/ir/index.js +0 -5
- package/lib/app-data/kinds/ir/index.js.map +0 -1
- package/lib/app-data/kinds/ir/irAutoPeakPickingEnhancer.d.ts +0 -20
- package/lib/app-data/kinds/ir/irAutoPeakPickingEnhancer.d.ts.map +0 -1
- package/lib/app-data/kinds/ir/irAutoPeakPickingEnhancer.js +0 -50
- package/lib/app-data/kinds/ir/irAutoPeakPickingEnhancer.js.map +0 -1
- package/lib/app-data/kinds/ir/irMeasurementEnhancer.d.ts +0 -8
- package/lib/app-data/kinds/ir/irMeasurementEnhancer.d.ts.map +0 -1
- package/lib/app-data/kinds/ir/irMeasurementEnhancer.js +0 -47
- package/lib/app-data/kinds/ir/irMeasurementEnhancer.js.map +0 -1
- package/lib/app-data/kinds/iv/IvMeasurement.d.ts +0 -3
- package/lib/app-data/kinds/iv/IvMeasurement.d.ts.map +0 -1
- package/lib/app-data/kinds/iv/IvMeasurement.js +0 -2
- package/lib/app-data/kinds/iv/IvMeasurement.js.map +0 -1
- package/lib/app-data/kinds/iv/index.d.ts +0 -2
- package/lib/app-data/kinds/iv/index.d.ts.map +0 -1
- package/lib/app-data/kinds/iv/index.js +0 -2
- package/lib/app-data/kinds/iv/index.js.map +0 -1
- package/lib/app-data/loaders/biologicLoader.d.ts +0 -11
- package/lib/app-data/loaders/biologicLoader.d.ts.map +0 -1
- package/lib/app-data/loaders/biologicLoader.js +0 -141
- package/lib/app-data/loaders/biologicLoader.js.map +0 -1
- package/lib/app-data/loaders/cdfLoader.d.ts +0 -5
- package/lib/app-data/loaders/cdfLoader.d.ts.map +0 -1
- package/lib/app-data/loaders/cdfLoader.js +0 -164
- package/lib/app-data/loaders/cdfLoader.js.map +0 -1
- package/lib/app-data/loaders/index.d.ts +0 -9
- package/lib/app-data/loaders/index.d.ts.map +0 -1
- package/lib/app-data/loaders/index.js +0 -9
- package/lib/app-data/loaders/index.js.map +0 -1
- package/lib/app-data/loaders/jcampLoader.d.ts +0 -11
- package/lib/app-data/loaders/jcampLoader.d.ts.map +0 -1
- package/lib/app-data/loaders/jcampLoader.js +0 -100
- package/lib/app-data/loaders/jcampLoader.js.map +0 -1
- package/lib/app-data/loaders/loadMeasurements.d.ts +0 -14
- package/lib/app-data/loaders/loadMeasurements.d.ts.map +0 -1
- package/lib/app-data/loaders/loadMeasurements.js +0 -37
- package/lib/app-data/loaders/loadMeasurements.js.map +0 -1
- package/lib/app-data/loaders/proprietary/agilent/cary500Loader.d.ts +0 -5
- package/lib/app-data/loaders/proprietary/agilent/cary500Loader.d.ts.map +0 -1
- package/lib/app-data/loaders/proprietary/agilent/cary500Loader.js +0 -71
- package/lib/app-data/loaders/proprietary/agilent/cary500Loader.js.map +0 -1
- package/lib/app-data/loaders/spcLoader.d.ts +0 -11
- package/lib/app-data/loaders/spcLoader.d.ts.map +0 -1
- package/lib/app-data/loaders/spcLoader.js +0 -41
- package/lib/app-data/loaders/spcLoader.js.map +0 -1
- package/lib/app-data/loaders/utility/getMeasurementInfoFromFile.d.ts +0 -20
- package/lib/app-data/loaders/utility/getMeasurementInfoFromFile.d.ts.map +0 -1
- package/lib/app-data/loaders/utility/getMeasurementInfoFromFile.js +0 -17
- package/lib/app-data/loaders/utility/getMeasurementInfoFromFile.js.map +0 -1
- package/lib/app-data/loaders/utility/index.d.ts +0 -4
- package/lib/app-data/loaders/utility/index.d.ts.map +0 -1
- package/lib/app-data/loaders/utility/index.js +0 -4
- package/lib/app-data/loaders/utility/index.js.map +0 -1
- package/lib/app-data/loaders/utility/measurementLoader.d.ts +0 -6
- package/lib/app-data/loaders/utility/measurementLoader.d.ts.map +0 -1
- package/lib/app-data/loaders/utility/measurementLoader.js +0 -14
- package/lib/app-data/loaders/utility/measurementLoader.js.map +0 -1
- package/lib/app-data/loaders/utility/parserLog.d.ts +0 -10
- package/lib/app-data/loaders/utility/parserLog.d.ts.map +0 -1
- package/lib/app-data/loaders/utility/parserLog.js +0 -19
- package/lib/app-data/loaders/utility/parserLog.js.map +0 -1
- package/lib/app-data/loaders/wdfLoader.d.ts +0 -11
- package/lib/app-data/loaders/wdfLoader.d.ts.map +0 -1
- package/lib/app-data/loaders/wdfLoader.js +0 -104
- package/lib/app-data/loaders/wdfLoader.js.map +0 -1
- package/lib/app-data/state/app_state.actions.d.ts +0 -38
- package/lib/app-data/state/app_state.actions.d.ts.map +0 -1
- package/lib/app-data/state/app_state.actions.js +0 -2
- package/lib/app-data/state/app_state.actions.js.map +0 -1
- package/lib/app-data/state/app_state.d.ts +0 -1323
- package/lib/app-data/state/app_state.d.ts.map +0 -1
- package/lib/app-data/state/app_state.js +0 -43
- package/lib/app-data/state/app_state.js.map +0 -1
- package/lib/app-data/state/app_state.provider.d.ts +0 -5
- package/lib/app-data/state/app_state.provider.d.ts.map +0 -1
- package/lib/app-data/state/app_state.provider.js +0 -8
- package/lib/app-data/state/app_state.provider.js.map +0 -1
- package/lib/app-data/state/data/AppData.d.ts +0 -69
- package/lib/app-data/state/data/AppData.d.ts.map +0 -1
- package/lib/app-data/state/data/AppData.js +0 -2
- package/lib/app-data/state/data/AppData.js.map +0 -1
- package/lib/app-data/state/data/data.helpers.d.ts +0 -54
- package/lib/app-data/state/data/data.helpers.d.ts.map +0 -1
- package/lib/app-data/state/data/data.helpers.js +0 -119
- package/lib/app-data/state/data/data.helpers.js.map +0 -1
- package/lib/app-data/state/data/getEmptyAppData.d.ts +0 -3
- package/lib/app-data/state/data/getEmptyAppData.d.ts.map +0 -1
- package/lib/app-data/state/data/getEmptyAppData.js +0 -17
- package/lib/app-data/state/data/getEmptyAppData.js.map +0 -1
- package/lib/app-data/state/data/index.d.ts +0 -5
- package/lib/app-data/state/data/index.d.ts.map +0 -1
- package/lib/app-data/state/data/index.js +0 -5
- package/lib/app-data/state/data/index.js.map +0 -1
- package/lib/app-data/state/data/kinds.d.ts +0 -4
- package/lib/app-data/state/data/kinds.d.ts.map +0 -1
- package/lib/app-data/state/data/kinds.js +0 -14
- package/lib/app-data/state/data/kinds.js.map +0 -1
- package/lib/app-data/state/index.d.ts +0 -6
- package/lib/app-data/state/index.d.ts.map +0 -1
- package/lib/app-data/state/index.js +0 -6
- package/lib/app-data/state/index.js.map +0 -1
- package/lib/app-data/state/producers/app_state_producer.d.ts +0 -7
- package/lib/app-data/state/producers/app_state_producer.d.ts.map +0 -1
- package/lib/app-data/state/producers/app_state_producer.js +0 -38
- package/lib/app-data/state/producers/app_state_producer.js.map +0 -1
- package/lib/app-data/state/producers/index.d.ts +0 -2
- package/lib/app-data/state/producers/index.d.ts.map +0 -1
- package/lib/app-data/state/producers/index.js +0 -2
- package/lib/app-data/state/producers/index.js.map +0 -1
- package/lib/app-data/state/producers/measurements/addMeasurements.d.ts +0 -3
- package/lib/app-data/state/producers/measurements/addMeasurements.d.ts.map +0 -1
- package/lib/app-data/state/producers/measurements/addMeasurements.js +0 -55
- package/lib/app-data/state/producers/measurements/addMeasurements.js.map +0 -1
- package/lib/app-data/state/producers/measurements/measurements.d.ts +0 -10
- package/lib/app-data/state/producers/measurements/measurements.d.ts.map +0 -1
- package/lib/app-data/state/producers/measurements/measurements.js +0 -95
- package/lib/app-data/state/producers/measurements/measurements.js.map +0 -1
- package/lib/app-data/state/producers/plot-view/helpers/zoom.d.ts +0 -5
- package/lib/app-data/state/producers/plot-view/helpers/zoom.d.ts.map +0 -1
- package/lib/app-data/state/producers/plot-view/helpers/zoom.js +0 -43
- package/lib/app-data/state/producers/plot-view/helpers/zoom.js.map +0 -1
- package/lib/app-data/state/producers/plot-view/plot-view.d.ts +0 -5
- package/lib/app-data/state/producers/plot-view/plot-view.d.ts.map +0 -1
- package/lib/app-data/state/producers/plot-view/plot-view.js +0 -20
- package/lib/app-data/state/producers/plot-view/plot-view.js.map +0 -1
- package/lib/app-data/state/producers/types.d.ts +0 -8
- package/lib/app-data/state/producers/types.d.ts.map +0 -1
- package/lib/app-data/state/producers/types.js +0 -2
- package/lib/app-data/state/producers/types.js.map +0 -1
- package/lib/app-data/state/settings/app_settings.d.ts +0 -9
- package/lib/app-data/state/settings/app_settings.d.ts.map +0 -1
- package/lib/app-data/state/settings/app_settings.js +0 -2
- package/lib/app-data/state/settings/app_settings.js.map +0 -1
- package/lib/app-data/state/settings/get_empty_app_settings.d.ts +0 -3
- package/lib/app-data/state/settings/get_empty_app_settings.d.ts.map +0 -1
- package/lib/app-data/state/settings/get_empty_app_settings.js +0 -8
- package/lib/app-data/state/settings/get_empty_app_settings.js.map +0 -1
- package/lib/app-data/state/settings/index.d.ts +0 -3
- package/lib/app-data/state/settings/index.d.ts.map +0 -1
- package/lib/app-data/state/settings/index.js +0 -3
- package/lib/app-data/state/settings/index.js.map +0 -1
- package/lib/app-data/state/view/app_view.d.ts +0 -35
- package/lib/app-data/state/view/app_view.d.ts.map +0 -1
- package/lib/app-data/state/view/app_view.js +0 -2
- package/lib/app-data/state/view/app_view.js.map +0 -1
- package/lib/app-data/state/view/get_empty_app_view.d.ts +0 -3
- package/lib/app-data/state/view/get_empty_app_view.d.ts.map +0 -1
- package/lib/app-data/state/view/get_empty_app_view.js +0 -8
- package/lib/app-data/state/view/get_empty_app_view.js.map +0 -1
- package/lib/app-data/state/view/index.d.ts +0 -3
- package/lib/app-data/state/view/index.d.ts.map +0 -1
- package/lib/app-data/state/view/index.js +0 -3
- package/lib/app-data/state/view/index.js.map +0 -1
- package/lib/app-data/utils.d.ts +0 -2
- package/lib/app-data/utils.d.ts.map +0 -1
- package/lib/app-data/utils.js +0 -12
- package/lib/app-data/utils.js.map +0 -1
- package/src/app/about/AboutDialogToolbarButton.tsx +0 -35
- package/src/app/about/index.ts +0 -1
- package/src/app/explorer/ExplorerPlotView.tsx +0 -17
- package/src/app/explorer/MeasurementExplorer.tsx +0 -196
- package/src/app/explorer/MeasurementExplorerWithState.tsx +0 -19
- package/src/app/explorer/index.ts +0 -2
- package/src/app/helpers/MeasurementPlot.tsx +0 -92
- package/src/app/helpers/MeasurementVariableSelect.tsx +0 -33
- package/src/app/helpers/getColorFromConfig.ts +0 -12
- package/src/app/helpers/index.ts +0 -5
- package/src/app/helpers/react-plot.tsx +0 -130
- package/src/app/helpers/splitEntries.ts +0 -26
- package/src/app/hooks/file-loading.ts +0 -53
- package/src/app/hooks/index.ts +0 -1
- package/src/app/index.ts +0 -5
- package/src/app/kinds/index.ts +0 -3
- package/src/app/kinds/ir/IrPeaksPanel.tsx +0 -65
- package/src/app/kinds/ir/index.ts +0 -1
- package/src/app/kinds/iv/index.ts +0 -1
- package/src/app/kinds/iv/plot-view/IvMeasurementsPlot.tsx +0 -112
- package/src/app/kinds/iv/plot-view/IvPlotVariablesSelector.tsx +0 -63
- package/src/app/kinds/iv/plot-view/IvPlotView.tsx +0 -55
- package/src/app/kinds/iv/plot-view/IvSeries.tsx +0 -37
- package/src/app/kinds/mass/MassPlotView.tsx +0 -19
- package/src/app/kinds/mass/MeasurementMassPlot.tsx +0 -142
- package/src/app/kinds/mass/index.ts +0 -2
- package/src/app/panels/SignalProcessingPanel.tsx +0 -218
- package/src/app/panels/index.ts +0 -4
- package/src/app/panels/measurement-config/MeasurementConfigPanel.tsx +0 -98
- package/src/app/panels/measurement-config/MeasurementConfigPanelAccordion.tsx +0 -26
- package/src/app/panels/measurement-config/index.ts +0 -2
- package/src/app/panels/measurement-info/MeasurementInfoPanel.tsx +0 -28
- package/src/app/panels/measurement-info/MeasurementInfoPanelAccordion.tsx +0 -11
- package/src/app/panels/measurement-info/index.ts +0 -2
- package/src/app/panels/measurements/MeasurementCheckbox.tsx +0 -37
- package/src/app/panels/measurements/MeasurementColorPreview.tsx +0 -99
- package/src/app/panels/measurements/MeasurementVisibilityToggle.tsx +0 -60
- package/src/app/panels/measurements/MeasurementsPanel.tsx +0 -86
- package/src/app/panels/measurements/MeasurementsPanelAccordion.tsx +0 -35
- package/src/app/panels/measurements/MeasurementsTable.tsx +0 -350
- package/src/app/panels/measurements/index.ts +0 -11
- package/src/app/panels/measurements/measurement_panel_context.provider.tsx +0 -18
- package/src/app/panels/measurements/measurement_panel_context.ts +0 -18
- package/src/app-data/enhancers/enhance.ts +0 -26
- package/src/app-data/enhancers/index.ts +0 -1
- package/src/app-data/helpers/index.ts +0 -1
- package/src/app-data/helpers/variables.ts +0 -29
- package/src/app-data/index.ts +0 -6
- package/src/app-data/kinds/index.ts +0 -2
- package/src/app-data/kinds/ir/IrMeasurement.ts +0 -15
- package/src/app-data/kinds/ir/IrPeak.ts +0 -8
- package/src/app-data/kinds/ir/index.ts +0 -4
- package/src/app-data/kinds/ir/irAutoPeakPickingEnhancer.ts +0 -94
- package/src/app-data/kinds/ir/irMeasurementEnhancer.ts +0 -51
- package/src/app-data/kinds/iv/IvMeasurement.ts +0 -3
- package/src/app-data/kinds/iv/index.ts +0 -1
- package/src/app-data/loaders/biologicLoader.ts +0 -166
- package/src/app-data/loaders/cdfLoader.ts +0 -206
- package/src/app-data/loaders/index.ts +0 -8
- package/src/app-data/loaders/jcampLoader.ts +0 -105
- package/src/app-data/loaders/loadMeasurements.ts +0 -53
- package/src/app-data/loaders/proprietary/agilent/cary500Loader.ts +0 -82
- package/src/app-data/loaders/spcLoader.ts +0 -55
- package/src/app-data/loaders/utility/getMeasurementInfoFromFile.ts +0 -21
- package/src/app-data/loaders/utility/index.ts +0 -3
- package/src/app-data/loaders/utility/measurementLoader.ts +0 -26
- package/src/app-data/loaders/utility/parserLog.ts +0 -39
- package/src/app-data/loaders/wdfLoader.ts +0 -140
- package/src/app-data/state/app_state.actions.ts +0 -49
- package/src/app-data/state/app_state.provider.tsx +0 -24
- package/src/app-data/state/app_state.ts +0 -70
- package/src/app-data/state/data/AppData.ts +0 -77
- package/src/app-data/state/data/data.helpers.ts +0 -192
- package/src/app-data/state/data/getEmptyAppData.ts +0 -18
- package/src/app-data/state/data/index.ts +0 -4
- package/src/app-data/state/data/kinds.ts +0 -16
- package/src/app-data/state/index.ts +0 -14
- package/src/app-data/state/producers/app_state_producer.ts +0 -65
- package/src/app-data/state/producers/index.ts +0 -1
- package/src/app-data/state/producers/measurements/addMeasurements.ts +0 -83
- package/src/app-data/state/producers/measurements/measurements.ts +0 -143
- package/src/app-data/state/producers/plot-view/helpers/zoom.ts +0 -63
- package/src/app-data/state/producers/plot-view/plot-view.ts +0 -29
- package/src/app-data/state/producers/types.ts +0 -11
- package/src/app-data/state/settings/app_settings.ts +0 -8
- package/src/app-data/state/settings/get_empty_app_settings.ts +0 -9
- package/src/app-data/state/settings/index.ts +0 -2
- package/src/app-data/state/view/app_view.ts +0 -29
- package/src/app-data/state/view/get_empty_app_view.ts +0 -9
- package/src/app-data/state/view/index.ts +0 -2
- package/src/app-data/utils.ts +0 -13
- package/src/test-utils.ts +0 -11
package/package.json
CHANGED
|
@@ -1,17 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-science",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "11.1.0",
|
|
4
4
|
"description": "React components to build scientific applications UI",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
7
|
-
"./app": "./lib/app/index.js",
|
|
8
|
-
"./app-data": "./lib/app-data/index.js",
|
|
9
7
|
"./ui": "./lib/components/index.js",
|
|
10
8
|
"./styles/*.css": "./styles/*.css"
|
|
11
9
|
},
|
|
12
10
|
"files": [
|
|
13
11
|
"lib",
|
|
14
|
-
"src",
|
|
12
|
+
"src/components",
|
|
15
13
|
"styles/preflight.css"
|
|
16
14
|
],
|
|
17
15
|
"scripts": {
|
|
@@ -38,59 +36,46 @@
|
|
|
38
36
|
"test": "npm run playwright && npm run test-only && npm run eslint && npm run prettier && npm run check-types",
|
|
39
37
|
"test-only": "vitest run --coverage "
|
|
40
38
|
},
|
|
41
|
-
"
|
|
42
|
-
"
|
|
39
|
+
"repository": {
|
|
40
|
+
"type": "git",
|
|
41
|
+
"url": "git+https://github.com/zakodium-oss/react-science.git"
|
|
43
42
|
},
|
|
44
|
-
"
|
|
45
|
-
|
|
46
|
-
"
|
|
43
|
+
"license": "MIT",
|
|
44
|
+
"bugs": {
|
|
45
|
+
"url": "https://github.com/zakodium-oss/react-science/issues"
|
|
47
46
|
},
|
|
47
|
+
"homepage": "https://github.com/zakodium-oss/react-science#readme",
|
|
48
48
|
"peerDependencies": {
|
|
49
|
-
"@blueprintjs/core": "^5.
|
|
50
|
-
"@blueprintjs/icons": "^5.
|
|
49
|
+
"@blueprintjs/core": "^5.16.0",
|
|
50
|
+
"@blueprintjs/icons": "^5.15.0",
|
|
51
51
|
"fifo-logger": "^1.0.0",
|
|
52
52
|
"react": ">=18.0.0",
|
|
53
53
|
"react-dom": ">=18.0.0"
|
|
54
54
|
},
|
|
55
55
|
"dependencies": {
|
|
56
|
-
"@blueprintjs/select": "^5.3.
|
|
56
|
+
"@blueprintjs/select": "^5.3.5",
|
|
57
57
|
"@emotion/react": "^11.13.5",
|
|
58
58
|
"@emotion/styled": "^11.13.5",
|
|
59
|
-
"@lukeed/uuid": "^2.0.1",
|
|
60
59
|
"@popperjs/core": "^2.11.8",
|
|
61
60
|
"@radix-ui/react-collapsible": "^1.1.1",
|
|
62
61
|
"@radix-ui/react-radio-group": "^1.2.1",
|
|
63
|
-
"@
|
|
64
|
-
"@tanstack/react-query": "^5.61.0",
|
|
62
|
+
"@tanstack/react-query": "^5.61.5",
|
|
65
63
|
"@tanstack/react-table": "^8.20.5",
|
|
66
|
-
"
|
|
67
|
-
"cheminfo-types": "^1.8.1",
|
|
64
|
+
"@tanstack/react-virtual": "^3.10.9",
|
|
68
65
|
"d3-scale-chromatic": "^3.1.0",
|
|
69
|
-
"filelist-utils": "^1.11.2",
|
|
70
66
|
"immer": "^10.1.1",
|
|
71
|
-
"jcampconverter": "^10.0.1",
|
|
72
67
|
"lodash": "^4.17.21",
|
|
73
|
-
"ml-gsd": "^12.1.8",
|
|
74
|
-
"ml-peak-shape-generator": "^4.1.4",
|
|
75
|
-
"ml-signal-processing": "^1.2.0",
|
|
76
|
-
"ml-spectra-processing": "^14.6.2",
|
|
77
|
-
"ms-spectrum": "^3.6.10",
|
|
78
|
-
"netcdfjs": "^3.0.0",
|
|
79
|
-
"react-d3-utils": "^3.0.0",
|
|
80
68
|
"react-dropzone": "14.3.5",
|
|
81
69
|
"react-icons": "^5.3.0",
|
|
82
70
|
"react-inspector": "^6.0.2",
|
|
83
|
-
"react-plot": "^3.0.0",
|
|
84
71
|
"react-popper": "^2.3.0",
|
|
85
|
-
"spc-parser": "^1.0.0",
|
|
86
72
|
"tinycolor2": "^1.6.0",
|
|
87
73
|
"ts-pattern": "^5.5.0",
|
|
88
|
-
"use-resize-observer": "^9.1.0"
|
|
89
|
-
"wdf-parser": "^0.3.0"
|
|
74
|
+
"use-resize-observer": "^9.1.0"
|
|
90
75
|
},
|
|
91
76
|
"devDependencies": {
|
|
92
|
-
"@blueprintjs/core": "^5.
|
|
93
|
-
"@blueprintjs/icons": "^5.
|
|
77
|
+
"@blueprintjs/core": "^5.16.0",
|
|
78
|
+
"@blueprintjs/icons": "^5.15.0",
|
|
94
79
|
"@playwright/experimental-ct-react": "^1.49.0",
|
|
95
80
|
"@playwright/test": "^1.49.0",
|
|
96
81
|
"@storybook/addon-essentials": "^8.4.5",
|
|
@@ -99,39 +84,47 @@
|
|
|
99
84
|
"@storybook/react": "^8.4.5",
|
|
100
85
|
"@storybook/react-vite": "^8.4.5",
|
|
101
86
|
"@types/babel__core": "^7.20.5",
|
|
102
|
-
"@types/d3-scale-chromatic": "^3.0
|
|
87
|
+
"@types/d3-scale-chromatic": "^3.1.0",
|
|
103
88
|
"@types/lodash": "^4.17.13",
|
|
104
89
|
"@types/react": "^18.3.12",
|
|
105
90
|
"@types/react-dom": "^18.3.1",
|
|
106
91
|
"@types/react-inspector": "^4.0.6",
|
|
107
92
|
"@types/tinycolor2": "^1.4.6",
|
|
108
|
-
"@vitejs/plugin-react": "^4.3.
|
|
109
|
-
"@vitest/coverage-v8": "^2.1.
|
|
93
|
+
"@vitejs/plugin-react": "^4.3.4",
|
|
94
|
+
"@vitest/coverage-v8": "^2.1.6",
|
|
95
|
+
"biologic-converter": "^0.6.0",
|
|
110
96
|
"cheminfo-font": "^1.13.1",
|
|
97
|
+
"cheminfo-types": "^1.8.1",
|
|
111
98
|
"cross-env": "^7.0.3",
|
|
112
99
|
"eslint": "^9.15.0",
|
|
113
100
|
"eslint-config-zakodium": "^14.0.0",
|
|
114
101
|
"eslint-plugin-storybook": "^0.11.1",
|
|
115
102
|
"fifo-logger": "^1.0.0",
|
|
116
|
-
"
|
|
103
|
+
"filelist-utils": "^1.11.2",
|
|
104
|
+
"jcampconverter": "^10.0.1",
|
|
105
|
+
"ml-gsd": "^12.1.8",
|
|
106
|
+
"ml-peak-shape-generator": "^4.1.4",
|
|
107
|
+
"ml-signal-processing": "^1.2.0",
|
|
108
|
+
"ml-spectra-processing": "^14.7.0",
|
|
109
|
+
"ms-spectrum": "^3.7.0",
|
|
110
|
+
"netcdfjs": "^3.0.0",
|
|
111
|
+
"prettier": "^3.4.1",
|
|
117
112
|
"react": "^18.3.1",
|
|
113
|
+
"react-d3-utils": "^3.0.0",
|
|
118
114
|
"react-dom": "^18.3.1",
|
|
119
115
|
"react-error-boundary": "^4.1.2",
|
|
120
116
|
"react-kbs": "^2.1.1",
|
|
121
117
|
"react-ocl": "^7.0.2",
|
|
118
|
+
"react-plot": "^3.0.0",
|
|
122
119
|
"rimraf": "^6.0.1",
|
|
120
|
+
"spc-parser": "^1.0.0",
|
|
123
121
|
"storybook": "^8.4.5",
|
|
124
|
-
"typescript": "^5.
|
|
122
|
+
"typescript": "^5.7.2",
|
|
125
123
|
"vite": "^5.4.11",
|
|
126
|
-
"vitest": "^2.1.
|
|
127
|
-
|
|
128
|
-
"repository": {
|
|
129
|
-
"type": "git",
|
|
130
|
-
"url": "git+https://github.com/zakodium-oss/react-science.git"
|
|
131
|
-
},
|
|
132
|
-
"license": "MIT",
|
|
133
|
-
"bugs": {
|
|
134
|
-
"url": "https://github.com/zakodium-oss/react-science/issues"
|
|
124
|
+
"vitest": "^2.1.6",
|
|
125
|
+
"wdf-parser": "^0.3.0"
|
|
135
126
|
},
|
|
136
|
-
"
|
|
127
|
+
"volta": {
|
|
128
|
+
"node": "22.11.0"
|
|
129
|
+
}
|
|
137
130
|
}
|
|
@@ -21,6 +21,11 @@ export interface AccordionItemProps {
|
|
|
21
21
|
title: string;
|
|
22
22
|
children: ReactNode;
|
|
23
23
|
defaultOpened?: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* When set to true, the item's children will not be rendered if the item is closed.
|
|
26
|
+
* When not set or set to false, the item's children will be rendered but hidden when the item is closed.
|
|
27
|
+
*/
|
|
28
|
+
unmountChildren?: boolean;
|
|
24
29
|
toolbar?: ReactNode;
|
|
25
30
|
}
|
|
26
31
|
|
|
@@ -62,8 +67,15 @@ export function Accordion(props: AccordionProps) {
|
|
|
62
67
|
|
|
63
68
|
Accordion.Item = function AccordionItem(props: AccordionItemProps) {
|
|
64
69
|
const { title, children, defaultOpened, toolbar } = props;
|
|
65
|
-
const { item, utils } = useAccordionContext(
|
|
70
|
+
const { item, utils, unmountChildren } = useAccordionContext(
|
|
71
|
+
title,
|
|
72
|
+
defaultOpened,
|
|
73
|
+
);
|
|
66
74
|
|
|
75
|
+
const shouldUnmountChildren =
|
|
76
|
+
props.unmountChildren === undefined
|
|
77
|
+
? unmountChildren
|
|
78
|
+
: props.unmountChildren;
|
|
67
79
|
const onClickHandle = useCallback(
|
|
68
80
|
(event: ReactMouseEvent<HTMLDivElement>) => {
|
|
69
81
|
if (event.shiftKey) {
|
|
@@ -105,27 +117,29 @@ Accordion.Item = function AccordionItem(props: AccordionItemProps) {
|
|
|
105
117
|
</div>
|
|
106
118
|
{toolbar}
|
|
107
119
|
</div>
|
|
108
|
-
|
|
109
|
-
style={{
|
|
110
|
-
display: item?.isOpen ? 'flex' : 'none',
|
|
111
|
-
flex: item?.isOpen ? '1 1 1px' : 'none',
|
|
112
|
-
backgroundColor: 'white',
|
|
113
|
-
maxHeight: '100%',
|
|
114
|
-
overflow: 'hidden',
|
|
115
|
-
}}
|
|
116
|
-
>
|
|
120
|
+
{!item?.isOpen && shouldUnmountChildren ? null : (
|
|
117
121
|
<div
|
|
118
122
|
style={{
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
123
|
+
display: item?.isOpen ? 'flex' : 'none',
|
|
124
|
+
flex: item?.isOpen ? '1 1 1px' : 'none',
|
|
125
|
+
backgroundColor: 'white',
|
|
126
|
+
maxHeight: '100%',
|
|
127
|
+
overflow: 'hidden',
|
|
124
128
|
}}
|
|
125
129
|
>
|
|
126
|
-
|
|
130
|
+
<div
|
|
131
|
+
style={{
|
|
132
|
+
height: '100%',
|
|
133
|
+
width: '100%',
|
|
134
|
+
overflow: 'auto',
|
|
135
|
+
display: 'flex',
|
|
136
|
+
flexDirection: 'column',
|
|
137
|
+
}}
|
|
138
|
+
>
|
|
139
|
+
{children}
|
|
140
|
+
</div>
|
|
127
141
|
</div>
|
|
128
|
-
|
|
142
|
+
)}
|
|
129
143
|
</div>
|
|
130
144
|
);
|
|
131
145
|
};
|
|
@@ -5,9 +5,14 @@ import type { ContextType } from './accordion_context.js';
|
|
|
5
5
|
import { accordionContext } from './accordion_context.js';
|
|
6
6
|
import { reducer } from './accordion_context.state.js';
|
|
7
7
|
|
|
8
|
-
export function AccordionProvider(props: {
|
|
8
|
+
export function AccordionProvider(props: {
|
|
9
|
+
children: ReactNode;
|
|
10
|
+
unmountChildren?: boolean;
|
|
11
|
+
}) {
|
|
12
|
+
const { unmountChildren = false } = props;
|
|
9
13
|
const [state, dispatch] = useReducer(reducer, {
|
|
10
14
|
items: [],
|
|
15
|
+
unmountChildren,
|
|
11
16
|
});
|
|
12
17
|
|
|
13
18
|
const utils = useMemo(
|
|
@@ -37,8 +42,8 @@ export function AccordionProvider(props: { children: ReactNode }) {
|
|
|
37
42
|
);
|
|
38
43
|
|
|
39
44
|
const value = useMemo<ContextType>(() => {
|
|
40
|
-
return [{ items: state.items }, utils];
|
|
41
|
-
}, [state.items, utils]);
|
|
45
|
+
return [{ items: state.items, unmountChildren }, utils];
|
|
46
|
+
}, [state.items, utils, unmountChildren]);
|
|
42
47
|
|
|
43
48
|
return (
|
|
44
49
|
<accordionContext.Provider value={value}>
|
|
@@ -57,6 +57,7 @@ export function useAccordionContext(title: string, defaultOpened?: boolean) {
|
|
|
57
57
|
return useMemo(
|
|
58
58
|
() => ({
|
|
59
59
|
item,
|
|
60
|
+
unmountChildren: state.unmountChildren,
|
|
60
61
|
utils: {
|
|
61
62
|
clear: () => utils.clear(title),
|
|
62
63
|
toggle: () => utils.toggle(title),
|
|
@@ -64,6 +65,6 @@ export function useAccordionContext(title: string, defaultOpened?: boolean) {
|
|
|
64
65
|
create: (defaultOpened?: boolean) => utils.create(title, defaultOpened),
|
|
65
66
|
},
|
|
66
67
|
}),
|
|
67
|
-
[item, title, utils],
|
|
68
|
+
[item, title, utils, state.unmountChildren],
|
|
68
69
|
);
|
|
69
70
|
}
|
|
@@ -1,9 +1,13 @@
|
|
|
1
|
-
import type { ColorConfig } from '../../../app-data/index.js';
|
|
2
1
|
import { assertUnreachable } from '../../utils/assert.js';
|
|
2
|
+
import type { GradientScaleName } from '../gradient_select/index.js';
|
|
3
3
|
|
|
4
4
|
import FixedColorPreview from './FixedColorPreview.js';
|
|
5
5
|
import FixedGradientPreview from './FixedGradientPreview.js';
|
|
6
6
|
|
|
7
|
+
export type ColorConfig =
|
|
8
|
+
| { kind: 'fixed'; color: string }
|
|
9
|
+
| { kind: 'fixedGradient'; gradient: GradientScaleName };
|
|
10
|
+
|
|
7
11
|
export interface ColorPreviewProps {
|
|
8
12
|
color: ColorConfig;
|
|
9
13
|
}
|
|
@@ -102,14 +102,13 @@ export function FifoLoggerDialog(props: FifoLoggerDialogProps) {
|
|
|
102
102
|
compact
|
|
103
103
|
bordered
|
|
104
104
|
tableProps={{ style: { width: '100%' } }}
|
|
105
|
-
renderRowTr={(
|
|
105
|
+
renderRowTr={(trProps, row) => (
|
|
106
106
|
<tr
|
|
107
|
+
{...trProps}
|
|
107
108
|
style={{
|
|
108
109
|
backgroundColor: rowBackgroundColor[row.original.levelLabel],
|
|
109
110
|
}}
|
|
110
|
-
|
|
111
|
-
{children}
|
|
112
|
-
</tr>
|
|
111
|
+
/>
|
|
113
112
|
)}
|
|
114
113
|
/>
|
|
115
114
|
</DialogBody>
|
|
@@ -1,37 +1,111 @@
|
|
|
1
1
|
import type { Row, RowData } from '@tanstack/react-table';
|
|
2
|
+
import type { VirtualItem, Virtualizer } from '@tanstack/react-virtual';
|
|
3
|
+
import { notUndefined } from '@tanstack/react-virtual';
|
|
4
|
+
import type { ReactNode } from 'react';
|
|
2
5
|
import { Fragment } from 'react';
|
|
3
6
|
|
|
4
7
|
import { TableRowCell } from './table_row_cell.js';
|
|
5
|
-
import type {
|
|
6
|
-
TableRowTrRenderer,
|
|
7
|
-
TableRowTrRendererProps,
|
|
8
|
-
} from './table_utils.js';
|
|
8
|
+
import type { TableRowTrProps, TableRowTrRenderer } from './table_utils.js';
|
|
9
9
|
|
|
10
10
|
interface TableBodyProps<TData extends RowData> {
|
|
11
11
|
rows: Array<Row<TData>>;
|
|
12
12
|
renderRowTr: TableRowTrRenderer<TData> | undefined;
|
|
13
|
+
virtualizeRows?: boolean;
|
|
14
|
+
virtualizer: Virtualizer<HTMLDivElement, Element>;
|
|
13
15
|
}
|
|
14
16
|
|
|
15
17
|
export function TableBody<TData extends RowData>(props: TableBodyProps<TData>) {
|
|
16
|
-
const {
|
|
18
|
+
const {
|
|
19
|
+
rows,
|
|
20
|
+
renderRowTr = defaultRenderRowTr as TableRowTrRenderer<TData>,
|
|
21
|
+
virtualizer,
|
|
22
|
+
virtualizeRows,
|
|
23
|
+
} = props;
|
|
24
|
+
|
|
25
|
+
if (virtualizeRows) {
|
|
26
|
+
const virtualItems = virtualizer.getVirtualItems();
|
|
27
|
+
const [before, after] =
|
|
28
|
+
virtualItems.length > 0
|
|
29
|
+
? [
|
|
30
|
+
virtualItems[0].start - virtualizer.options.scrollMargin,
|
|
31
|
+
virtualizer.getTotalSize() - notUndefined(virtualItems.at(-1)).end,
|
|
32
|
+
]
|
|
33
|
+
: [0, 0];
|
|
34
|
+
return (
|
|
35
|
+
<tbody>
|
|
36
|
+
{before > 0 && (
|
|
37
|
+
<tr>
|
|
38
|
+
<td style={{ height: before }} />
|
|
39
|
+
</tr>
|
|
40
|
+
)}
|
|
41
|
+
{virtualItems.map((virtualItem, index) => (
|
|
42
|
+
<TableRow
|
|
43
|
+
key={virtualItem.index}
|
|
44
|
+
row={rows[virtualItem.index]}
|
|
45
|
+
renderRowTr={(row) => {
|
|
46
|
+
const trProps = getTrRenderProps<TData>(row, {
|
|
47
|
+
...virtualItem,
|
|
48
|
+
virtualIndex: index,
|
|
49
|
+
});
|
|
50
|
+
return renderRowTr(trProps, row);
|
|
51
|
+
}}
|
|
52
|
+
/>
|
|
53
|
+
))}
|
|
54
|
+
{after > 0 && (
|
|
55
|
+
<tr>
|
|
56
|
+
<td style={{ height: after }} />
|
|
57
|
+
</tr>
|
|
58
|
+
)}
|
|
59
|
+
</tbody>
|
|
60
|
+
);
|
|
61
|
+
}
|
|
17
62
|
return (
|
|
18
63
|
<tbody>
|
|
19
64
|
{rows.map((row) => (
|
|
20
|
-
<
|
|
21
|
-
{
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
.map((cell) => <TableRowCell key={cell.id} cell={cell} />),
|
|
26
|
-
})}
|
|
27
|
-
</Fragment>
|
|
65
|
+
<TableRow
|
|
66
|
+
key={row.id}
|
|
67
|
+
row={row}
|
|
68
|
+
renderRowTr={(row) => renderRowTr(getTrRenderProps(row), row)}
|
|
69
|
+
/>
|
|
28
70
|
))}
|
|
29
71
|
</tbody>
|
|
30
72
|
);
|
|
31
73
|
}
|
|
32
74
|
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
75
|
+
type TableRowRenderer<TData extends RowData> = (row: Row<TData>) => ReactNode;
|
|
76
|
+
|
|
77
|
+
function TableRow<TData>({
|
|
78
|
+
row,
|
|
79
|
+
renderRowTr,
|
|
80
|
+
}: {
|
|
81
|
+
row: Row<TData>;
|
|
82
|
+
renderRowTr: TableRowRenderer<TData>;
|
|
83
|
+
}) {
|
|
84
|
+
return <Fragment>{renderRowTr(row)}</Fragment>;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
const defaultRenderRowTr: TableRowTrRenderer<unknown> = (trProps) => (
|
|
88
|
+
<tr {...trProps} />
|
|
89
|
+
);
|
|
90
|
+
|
|
91
|
+
type RenderRowVirtualItem = VirtualItem & {
|
|
92
|
+
/**
|
|
93
|
+
* The index of the element within the virtual list being currently rendered.
|
|
94
|
+
*/
|
|
95
|
+
virtualIndex: number;
|
|
96
|
+
};
|
|
97
|
+
|
|
98
|
+
function getTrRenderProps<TData extends RowData>(
|
|
99
|
+
row: Row<TData>,
|
|
100
|
+
virtualItem?: RenderRowVirtualItem,
|
|
101
|
+
): TableRowTrProps {
|
|
102
|
+
const index = virtualItem ? virtualItem.index : row.index;
|
|
103
|
+
|
|
104
|
+
return {
|
|
105
|
+
// index is 0-indexed, so odd rows are even indices
|
|
106
|
+
className: index % 2 === 0 ? 'odd' : '',
|
|
107
|
+
children: row
|
|
108
|
+
.getVisibleCells()
|
|
109
|
+
.map((cell) => <TableRowCell key={cell.id} cell={cell} />),
|
|
110
|
+
};
|
|
37
111
|
}
|
|
@@ -1,38 +1,100 @@
|
|
|
1
1
|
/** @jsxImportSource @emotion/react */
|
|
2
2
|
|
|
3
3
|
import { HTMLTable } from '@blueprintjs/core';
|
|
4
|
+
import styled from '@emotion/styled';
|
|
4
5
|
import type { RowData, TableOptions } from '@tanstack/react-table';
|
|
5
6
|
import {
|
|
6
7
|
getCoreRowModel,
|
|
7
8
|
getSortedRowModel,
|
|
8
9
|
useReactTable,
|
|
9
10
|
} from '@tanstack/react-table';
|
|
10
|
-
import
|
|
11
|
+
import { useVirtualizer } from '@tanstack/react-virtual';
|
|
12
|
+
import type { ReactNode, RefObject, TableHTMLAttributes } from 'react';
|
|
13
|
+
import { useRef } from 'react';
|
|
11
14
|
|
|
12
15
|
import { TableBody } from './table_body.js';
|
|
13
16
|
import { TableHeader } from './table_header.js';
|
|
14
17
|
import type { TableColumnDef, TableRowTrRenderer } from './table_utils.js';
|
|
15
18
|
import { useTableColumns } from './use_table_columns.js';
|
|
16
19
|
|
|
17
|
-
|
|
20
|
+
// Blueprint's HTMLTable `striped` prop's implementation is based on nth-child odd / even
|
|
21
|
+
// We cannot use that with virtualization, so we override its implementation here.
|
|
22
|
+
const CustomHTMLTable = styled(HTMLTable, {
|
|
23
|
+
shouldForwardProp: (prop) => prop !== 'striped',
|
|
24
|
+
})`
|
|
25
|
+
tbody tr.odd td {
|
|
26
|
+
background: ${(props) =>
|
|
27
|
+
props.striped ? 'rgba(143, 153, 168, 0.15)' : 'inherit'};
|
|
28
|
+
}
|
|
29
|
+
`;
|
|
30
|
+
|
|
31
|
+
interface TableBaseProps<TData extends RowData> {
|
|
18
32
|
data: TData[];
|
|
33
|
+
/**
|
|
34
|
+
* Tanstack table definition of columns in the table.
|
|
35
|
+
*/
|
|
19
36
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
20
37
|
columns: Array<TableColumnDef<TData, any>>;
|
|
21
|
-
|
|
38
|
+
/**
|
|
39
|
+
* Show borders between each cell and row of the table.
|
|
40
|
+
*/
|
|
22
41
|
bordered?: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* Reduce the padding around table cells.
|
|
44
|
+
*/
|
|
23
45
|
compact?: boolean;
|
|
46
|
+
/**
|
|
47
|
+
* When hovering over a row, change its background color and set the pointer
|
|
48
|
+
* to be a cursor.
|
|
49
|
+
*/
|
|
24
50
|
interactive?: boolean;
|
|
51
|
+
/**
|
|
52
|
+
* Alternate between gray and white background for each row.
|
|
53
|
+
*/
|
|
25
54
|
striped?: boolean;
|
|
55
|
+
/**
|
|
56
|
+
* Enable header rows which stick to the top of the table.
|
|
57
|
+
*/
|
|
26
58
|
stickyHeader?: boolean;
|
|
59
|
+
/**
|
|
60
|
+
* Use virtualized rows to optimize rendering.
|
|
61
|
+
* When virtualizing rows, and in order to prevent layout shifts,
|
|
62
|
+
* it is recommended that all columns have a fixed width.
|
|
63
|
+
*/
|
|
64
|
+
virtualizeRows?: boolean;
|
|
27
65
|
|
|
28
66
|
reactTable?: Omit<
|
|
29
67
|
TableOptions<TData>,
|
|
30
68
|
'data' | 'columns' | 'getCoreRowModel' | 'getSortedRowModel'
|
|
31
69
|
>;
|
|
32
70
|
tableProps?: Omit<TableHTMLAttributes<HTMLTableElement>, 'children'>;
|
|
71
|
+
/**
|
|
72
|
+
* Override the default row rendering.
|
|
73
|
+
* Make sure to spread the passed `trProps` onto the rendered `<tr>` element.
|
|
74
|
+
*/
|
|
33
75
|
renderRowTr?: TableRowTrRenderer<TData>;
|
|
34
76
|
}
|
|
35
77
|
|
|
78
|
+
interface RegularTableProps<TData extends RowData>
|
|
79
|
+
extends TableBaseProps<TData> {
|
|
80
|
+
virtualizeRows?: false | undefined;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
interface VirtualizedTableProps<TData extends RowData>
|
|
84
|
+
extends TableBaseProps<TData> {
|
|
85
|
+
virtualizeRows: true;
|
|
86
|
+
/**
|
|
87
|
+
* For virtualization of the table rows, provide an estimate of the height of each row.
|
|
88
|
+
* @param index The index of the row in the data array.
|
|
89
|
+
* @return The estimated height of the row at the given index.
|
|
90
|
+
*/
|
|
91
|
+
estimatedRowHeight: (index: number) => number;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
export type TableProps<TData extends RowData> =
|
|
95
|
+
| RegularTableProps<TData>
|
|
96
|
+
| VirtualizedTableProps<TData>;
|
|
97
|
+
|
|
36
98
|
export function Table<TData extends RowData>(props: TableProps<TData>) {
|
|
37
99
|
const {
|
|
38
100
|
data,
|
|
@@ -47,8 +109,11 @@ export function Table<TData extends RowData>(props: TableProps<TData>) {
|
|
|
47
109
|
reactTable,
|
|
48
110
|
tableProps,
|
|
49
111
|
renderRowTr,
|
|
112
|
+
|
|
113
|
+
virtualizeRows,
|
|
50
114
|
} = props;
|
|
51
115
|
|
|
116
|
+
const scrollElementRef = useRef<HTMLDivElement>(null);
|
|
52
117
|
const columnDefs = useTableColumns(columns);
|
|
53
118
|
const table = useReactTable<TData>({
|
|
54
119
|
...reactTable,
|
|
@@ -58,16 +123,52 @@ export function Table<TData extends RowData>(props: TableProps<TData>) {
|
|
|
58
123
|
getSortedRowModel: getSortedRowModel(),
|
|
59
124
|
});
|
|
60
125
|
|
|
126
|
+
const tanstackVirtualizer = useVirtualizer({
|
|
127
|
+
enabled: virtualizeRows,
|
|
128
|
+
count: data.length,
|
|
129
|
+
getScrollElement: () => scrollElementRef.current,
|
|
130
|
+
estimateSize:
|
|
131
|
+
(props.virtualizeRows && props.estimatedRowHeight) || (() => 0),
|
|
132
|
+
overscan: 5,
|
|
133
|
+
});
|
|
134
|
+
|
|
61
135
|
return (
|
|
62
|
-
<
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
136
|
+
<Container virtualizeRows={virtualizeRows} scrollRef={scrollElementRef}>
|
|
137
|
+
<CustomHTMLTable
|
|
138
|
+
bordered={bordered}
|
|
139
|
+
compact={compact}
|
|
140
|
+
interactive={interactive}
|
|
141
|
+
striped={striped}
|
|
142
|
+
{...tableProps}
|
|
143
|
+
>
|
|
144
|
+
<TableHeader sticky={stickyHeader} headers={table.getFlatHeaders()} />
|
|
145
|
+
<TableBody
|
|
146
|
+
rows={table.getRowModel().rows}
|
|
147
|
+
renderRowTr={renderRowTr}
|
|
148
|
+
virtualizer={tanstackVirtualizer}
|
|
149
|
+
virtualizeRows={virtualizeRows}
|
|
150
|
+
/>
|
|
151
|
+
</CustomHTMLTable>
|
|
152
|
+
</Container>
|
|
72
153
|
);
|
|
73
154
|
}
|
|
155
|
+
|
|
156
|
+
const ScrollRefDiv = styled.div`
|
|
157
|
+
height: 100%;
|
|
158
|
+
overflow: auto;
|
|
159
|
+
`;
|
|
160
|
+
|
|
161
|
+
function Container({
|
|
162
|
+
virtualizeRows,
|
|
163
|
+
scrollRef,
|
|
164
|
+
children,
|
|
165
|
+
}: {
|
|
166
|
+
virtualizeRows?: boolean;
|
|
167
|
+
children: ReactNode;
|
|
168
|
+
scrollRef: RefObject<HTMLDivElement>;
|
|
169
|
+
}) {
|
|
170
|
+
if (virtualizeRows) {
|
|
171
|
+
return <ScrollRefDiv ref={scrollRef}>{children}</ScrollRefDiv>;
|
|
172
|
+
}
|
|
173
|
+
return <>{children}</>;
|
|
174
|
+
}
|
|
@@ -3,15 +3,16 @@ import { flexRender } from '@tanstack/react-table';
|
|
|
3
3
|
|
|
4
4
|
interface TableRowCellProps<TData extends RowData> {
|
|
5
5
|
cell: Cell<TData, unknown>;
|
|
6
|
+
className?: string;
|
|
6
7
|
}
|
|
7
8
|
|
|
8
9
|
export function TableRowCell<TData extends RowData>(
|
|
9
10
|
props: TableRowCellProps<TData>,
|
|
10
11
|
) {
|
|
11
|
-
const { cell } = props;
|
|
12
|
+
const { cell, className } = props;
|
|
12
13
|
|
|
13
14
|
return (
|
|
14
|
-
<td style={{ position: 'relative' }}>
|
|
15
|
+
<td style={{ position: 'relative' }} className={className}>
|
|
15
16
|
{flexRender(cell.column.columnDef.cell, cell.getContext())}
|
|
16
17
|
</td>
|
|
17
18
|
);
|
|
@@ -11,10 +11,12 @@ export function createTableColumnHelper<TData extends RowData>() {
|
|
|
11
11
|
return createColumnHelper<TData>();
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
-
export interface
|
|
15
|
-
|
|
14
|
+
export interface TableRowTrProps {
|
|
15
|
+
className: string;
|
|
16
16
|
children: ReactNode;
|
|
17
17
|
}
|
|
18
|
+
|
|
18
19
|
export type TableRowTrRenderer<TData extends RowData> = (
|
|
19
|
-
|
|
20
|
+
trProps: TableRowTrProps,
|
|
21
|
+
row: Row<TData>,
|
|
20
22
|
) => ReactNode;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import type { IconName } from '@blueprintjs/icons';
|
|
2
|
-
import type { ReactElement, ReactNode } from 'react';
|
|
3
|
-
interface AboutDialogToolbarButtonProps {
|
|
4
|
-
name: string;
|
|
5
|
-
icon: IconName | ReactElement;
|
|
6
|
-
body: ReactNode;
|
|
7
|
-
}
|
|
8
|
-
export declare function AboutDialogToolbarButton(props: AboutDialogToolbarButtonProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
-
export {};
|
|
10
|
-
//# sourceMappingURL=AboutDialogToolbarButton.d.ts.map
|