nmrium 1.9.0 → 1.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/component/1d/ApodizationLine.js +1 -1
- package/lib/component/1d/ApodizationLine.js.map +1 -1
- package/lib/component/1d/BrushTracker1D.d.ts.map +1 -1
- package/lib/component/1d/BrushTracker1D.js.map +1 -1
- package/lib/component/1d/FooterBanner.js.map +1 -1
- package/lib/component/1d/LinesSeries.js +2 -2
- package/lib/component/1d/LinesSeries.js.map +1 -1
- package/lib/component/1d/SVGContent1D.d.ts.map +1 -1
- package/lib/component/1d/SVGContent1D.js +2 -1
- package/lib/component/1d/SVGContent1D.js.map +1 -1
- package/lib/component/1d/SimilarityTree.d.ts.map +1 -1
- package/lib/component/1d/SimilarityTree.js.map +1 -1
- package/lib/component/1d/inset/InsetProvider.d.ts.map +1 -1
- package/lib/component/1d/inset/InsetProvider.js.map +1 -1
- package/lib/component/1d/integral/IntegralResizable.d.ts.map +1 -1
- package/lib/component/1d/integral/IntegralResizable.js.map +1 -1
- package/lib/component/1d/matrix/Boxplot.js.map +1 -1
- package/lib/component/1d/multiAnalysis/AnalysisRange.d.ts.map +1 -1
- package/lib/component/1d/multiAnalysis/AnalysisRange.js.map +1 -1
- package/lib/component/1d/multiplicityTree/MultiplicityTree.d.ts.map +1 -1
- package/lib/component/1d/multiplicityTree/MultiplicityTree.js +13 -20
- package/lib/component/1d/multiplicityTree/MultiplicityTree.js.map +1 -1
- package/lib/component/1d/multiplicityTree/generateTreeNodes.d.ts +1 -0
- package/lib/component/1d/multiplicityTree/generateTreeNodes.d.ts.map +1 -1
- package/lib/component/1d/multiplicityTree/generateTreeNodes.js +2 -1
- package/lib/component/1d/multiplicityTree/generateTreeNodes.js.map +1 -1
- package/lib/component/1d/peaks/PeakAnnotationsSpreadMode.d.ts.map +1 -1
- package/lib/component/1d/peaks/PeakAnnotationsSpreadMode.js.map +1 -1
- package/lib/component/1d/peaks/PeakEditionManager.d.ts.map +1 -1
- package/lib/component/1d/peaks/PeakEditionManager.js +2 -2
- package/lib/component/1d/peaks/PeakEditionManager.js.map +1 -1
- package/lib/component/1d/peaks/Peaks.d.ts +4 -1
- package/lib/component/1d/peaks/Peaks.d.ts.map +1 -1
- package/lib/component/1d/peaks/Peaks.js.map +1 -1
- package/lib/component/1d/ranges/AssignmentLabel.d.ts +2 -1
- package/lib/component/1d/ranges/AssignmentLabel.d.ts.map +1 -1
- package/lib/component/1d/ranges/AssignmentLabel.js +6 -4
- package/lib/component/1d/ranges/AssignmentLabel.js.map +1 -1
- package/lib/component/1d/ranges/Atoms.js +2 -2
- package/lib/component/1d/ranges/Atoms.js.map +1 -1
- package/lib/component/1d/ranges/Range.d.ts +2 -1
- package/lib/component/1d/ranges/Range.d.ts.map +1 -1
- package/lib/component/1d/ranges/Range.js +28 -56
- package/lib/component/1d/ranges/Range.js.map +1 -1
- package/lib/component/1d/ranges/Ranges.d.ts.map +1 -1
- package/lib/component/1d/ranges/Ranges.js +19 -13
- package/lib/component/1d/ranges/Ranges.js.map +1 -1
- package/lib/component/1d/ranges/useAssignmentsPopoverActionsButtons.d.ts +14 -0
- package/lib/component/1d/ranges/useAssignmentsPopoverActionsButtons.d.ts.map +1 -0
- package/lib/component/1d/ranges/useAssignmentsPopoverActionsButtons.js +67 -0
- package/lib/component/1d/ranges/useAssignmentsPopoverActionsButtons.js.map +1 -0
- package/lib/component/1d/tool/BaseLineZones.d.ts.map +1 -1
- package/lib/component/1d/tool/BaseLineZones.js.map +1 -1
- package/lib/component/1d/utilities/intersectionResolver.d.ts.map +1 -1
- package/lib/component/1d/utilities/intersectionResolver.js.map +1 -1
- package/lib/component/1d-2d/FieldEdition.d.ts.map +1 -1
- package/lib/component/1d-2d/FieldEdition.js.map +1 -1
- package/lib/component/2d/1d-tracer/VerticalSliceChart.js.map +1 -1
- package/lib/component/2d/1d-tracer/phase-correction-traces/PhaseTraces.js +1 -1
- package/lib/component/2d/1d-tracer/phase-correction-traces/PhaseTraces.js.map +1 -1
- package/lib/component/2d/1d-tracer/phase-correction-traces/SpectrumPhaseTrace.js +1 -1
- package/lib/component/2d/1d-tracer/phase-correction-traces/SpectrumPhaseTrace.js.map +1 -1
- package/lib/component/2d/BrushTracker2D.d.ts.map +1 -1
- package/lib/component/2d/BrushTracker2D.js +41 -46
- package/lib/component/2d/BrushTracker2D.js.map +1 -1
- package/lib/component/2d/FooterBanner.d.ts +2 -2
- package/lib/component/2d/FooterBanner.d.ts.map +1 -1
- package/lib/component/2d/FooterBanner.js +63 -97
- package/lib/component/2d/FooterBanner.js.map +1 -1
- package/lib/component/2d/SVGContent2D.d.ts +2 -2
- package/lib/component/2d/SVGContent2D.d.ts.map +1 -1
- package/lib/component/2d/SVGContent2D.js.map +1 -1
- package/lib/component/2d/SlicingView.js +1 -1
- package/lib/component/2d/SlicingView.js.map +1 -1
- package/lib/component/2d/Viewer2D.js +1 -1
- package/lib/component/2d/Viewer2D.js.map +1 -1
- package/lib/component/2d/ft/FTContainer.d.ts +2 -2
- package/lib/component/2d/ft/FTContainer.d.ts.map +1 -1
- package/lib/component/2d/ft/FTContainer.js +1 -1
- package/lib/component/2d/ft/FTContainer.js.map +1 -1
- package/lib/component/2d/tools/XYLabelPointer.d.ts +2 -2
- package/lib/component/2d/tools/XYLabelPointer.d.ts.map +1 -1
- package/lib/component/2d/tools/XYLabelPointer.js +10 -9
- package/lib/component/2d/tools/XYLabelPointer.js.map +1 -1
- package/lib/component/2d/useTracesSpectra.d.ts +3 -2
- package/lib/component/2d/useTracesSpectra.d.ts.map +1 -1
- package/lib/component/2d/useTracesSpectra.js +19 -12
- package/lib/component/2d/useTracesSpectra.js.map +1 -1
- package/lib/component/2d/utilities/extractSpectrumSignals.js +2 -2
- package/lib/component/2d/utilities/extractSpectrumSignals.js.map +1 -1
- package/lib/component/2d/zones/Signal.js.map +1 -1
- package/lib/component/2d/zones/SignalsGuideLines.d.ts.map +1 -1
- package/lib/component/2d/zones/SignalsGuideLines.js +15 -13
- package/lib/component/2d/zones/SignalsGuideLines.js.map +1 -1
- package/lib/component/2d/zones/ZonesAssignmentsLabels.js +1 -1
- package/lib/component/2d/zones/ZonesAssignmentsLabels.js.map +1 -1
- package/lib/component/EventsTrackers/BrushTracker.d.ts +5 -6
- package/lib/component/EventsTrackers/BrushTracker.d.ts.map +1 -1
- package/lib/component/EventsTrackers/BrushTracker.js +2 -0
- package/lib/component/EventsTrackers/BrushTracker.js.map +1 -1
- package/lib/component/assignment/utilities/getAssignments.js +1 -2
- package/lib/component/assignment/utilities/getAssignments.js.map +1 -1
- package/lib/component/context/KeyModifierContext.d.ts +3 -2
- package/lib/component/context/KeyModifierContext.d.ts.map +1 -1
- package/lib/component/context/KeyModifierContext.js +7 -4
- package/lib/component/context/KeyModifierContext.js.map +1 -1
- package/lib/component/elements/ActionsButtonsPopover.d.ts.map +1 -1
- package/lib/component/elements/ActionsButtonsPopover.js +17 -3
- package/lib/component/elements/ActionsButtonsPopover.js.map +1 -1
- package/lib/component/elements/AssignmentsCell.d.ts.map +1 -1
- package/lib/component/elements/AssignmentsCell.js.map +1 -1
- package/lib/component/elements/Button.d.ts.map +1 -1
- package/lib/component/elements/Button.js.map +1 -1
- package/lib/component/elements/CheckController.d.ts.map +1 -1
- package/lib/component/elements/CheckController.js.map +1 -1
- package/lib/component/elements/ContextMenuBluePrint.d.ts.map +1 -1
- package/lib/component/elements/ContextMenuBluePrint.js.map +1 -1
- package/lib/component/elements/D3Axis.d.ts.map +1 -1
- package/lib/component/elements/DraggableDialog.d.ts.map +1 -1
- package/lib/component/elements/DraggableDialog.js.map +1 -1
- package/lib/component/elements/Input.d.ts.map +1 -1
- package/lib/component/elements/Input.js.map +1 -1
- package/lib/component/elements/Input2.d.ts.map +1 -1
- package/lib/component/elements/Input2.js.map +1 -1
- package/lib/component/elements/Input2Controller.d.ts.map +1 -1
- package/lib/component/elements/Input2Controller.js.map +1 -1
- package/lib/component/elements/Label.d.ts.map +1 -1
- package/lib/component/elements/Label.js.map +1 -1
- package/lib/component/elements/NumberInput2.d.ts.map +1 -1
- package/lib/component/elements/NumberInput2.js.map +1 -1
- package/lib/component/elements/NumberInput2Controller.d.ts.map +1 -1
- package/lib/component/elements/NumberInput2Controller.js.map +1 -1
- package/lib/component/elements/ReactTable/ReactTable.d.ts.map +1 -1
- package/lib/component/elements/ReactTable/ReactTable.js.map +1 -1
- package/lib/component/elements/ReadOnly.d.ts.map +1 -1
- package/lib/component/elements/ReadOnly.js.map +1 -1
- package/lib/component/elements/Sections.js.map +1 -1
- package/lib/component/elements/Select.d.ts.map +1 -1
- package/lib/component/elements/Select.js.map +1 -1
- package/lib/component/elements/ToolbarPopoverItem.d.ts.map +1 -1
- package/lib/component/elements/export/ExportContent.d.ts.map +1 -1
- package/lib/component/elements/export/ExportContent.js.map +1 -1
- package/lib/component/elements/print/PrintContent.d.ts.map +1 -1
- package/lib/component/elements/print/PrintContent.js.map +1 -1
- package/lib/component/hooks/useActiveSpectrumIntegralsViewState.d.ts.map +1 -1
- package/lib/component/hooks/useActiveSpectrumIntegralsViewState.js +2 -4
- package/lib/component/hooks/useActiveSpectrumIntegralsViewState.js.map +1 -1
- package/lib/component/hooks/useActiveSpectrumPeaksViewState.d.ts.map +1 -1
- package/lib/component/hooks/useActiveSpectrumPeaksViewState.js +2 -4
- package/lib/component/hooks/useActiveSpectrumPeaksViewState.js.map +1 -1
- package/lib/component/hooks/useActiveSpectrumRangesViewState.d.ts.map +1 -1
- package/lib/component/hooks/useActiveSpectrumRangesViewState.js +2 -4
- package/lib/component/hooks/useActiveSpectrumRangesViewState.js.map +1 -1
- package/lib/component/hooks/useActiveSpectrumStyleOptions.js +2 -2
- package/lib/component/hooks/useActiveSpectrumStyleOptions.js.map +1 -1
- package/lib/component/hooks/useActiveSpectrumZonesViewState.d.ts.map +1 -1
- package/lib/component/hooks/useActiveSpectrumZonesViewState.js +2 -4
- package/lib/component/hooks/useActiveSpectrumZonesViewState.js.map +1 -1
- package/lib/component/hooks/useExport.js +1 -1
- package/lib/component/hooks/useExport.js.map +1 -1
- package/lib/component/hooks/useSaveSettings.d.ts.map +1 -1
- package/lib/component/hooks/useSaveSettings.js +28 -47
- package/lib/component/hooks/useSaveSettings.js.map +1 -1
- package/lib/component/hooks/useSetActiveSpectrumAction.d.ts +2 -1
- package/lib/component/hooks/useSetActiveSpectrumAction.d.ts.map +1 -1
- package/lib/component/hooks/useSetActiveSpectrumAction.js +2 -2
- package/lib/component/hooks/useSetActiveSpectrumAction.js.map +1 -1
- package/lib/component/hooks/useSpectrumWithDataSource.js +1 -1
- package/lib/component/hooks/useSpectrumWithDataSource.js.map +1 -1
- package/lib/component/hooks/useWorkspaceAction.d.ts +1 -1
- package/lib/component/hooks/useWorkspaceAction.d.ts.map +1 -1
- package/lib/component/hooks/useWorkspaceAction.js +3 -0
- package/lib/component/hooks/useWorkspaceAction.js.map +1 -1
- package/lib/component/modal/ImportPublicationStringModal.d.ts.map +1 -1
- package/lib/component/modal/ImportPublicationStringModal.js.map +1 -1
- package/lib/component/modal/changeSum/ChangeSumModal.d.ts.map +1 -1
- package/lib/component/modal/changeSum/ChangeSumModal.js.map +1 -1
- package/lib/component/modal/metaImportation/MetaImportationModal.d.ts.map +1 -1
- package/lib/component/modal/metaImportation/MetaImportationModal.js.map +1 -1
- package/lib/component/modal/setting/GeneralSettings.d.ts.map +1 -1
- package/lib/component/modal/setting/GeneralSettings.js +5 -1
- package/lib/component/modal/setting/GeneralSettings.js.map +1 -1
- package/lib/component/panels/IntegralsPanel/IntegralTable.d.ts.map +1 -1
- package/lib/component/panels/IntegralsPanel/IntegralTable.js.map +1 -1
- package/lib/component/panels/MoleculesPanel/MoleculePanelHeader.d.ts +1 -1
- package/lib/component/panels/MoleculesPanel/MoleculePanelHeader.d.ts.map +1 -1
- package/lib/component/panels/MoleculesPanel/MoleculePanelHeader.js +14 -10
- package/lib/component/panels/MoleculesPanel/MoleculePanelHeader.js.map +1 -1
- package/lib/component/panels/MoleculesPanel/hooks/useAtomAssignment.d.ts.map +1 -1
- package/lib/component/panels/MoleculesPanel/hooks/useAtomAssignment.js +17 -17
- package/lib/component/panels/MoleculesPanel/hooks/useAtomAssignment.js.map +1 -1
- package/lib/component/panels/MoleculesPanel/utilities/getAssignIds.d.ts.map +1 -1
- package/lib/component/panels/MoleculesPanel/utilities/getAssignIds.js +0 -3
- package/lib/component/panels/MoleculesPanel/utilities/getAssignIds.js.map +1 -1
- package/lib/component/panels/RangesPanel/RangesPanel.js +1 -1
- package/lib/component/panels/RangesPanel/RangesPanel.js.map +1 -1
- package/lib/component/panels/RangesPanel/RangesTable.d.ts.map +1 -1
- package/lib/component/panels/RangesPanel/RangesTable.js +1 -1
- package/lib/component/panels/RangesPanel/RangesTable.js.map +1 -1
- package/lib/component/panels/RangesPanel/RangesTableRow.d.ts.map +1 -1
- package/lib/component/panels/RangesPanel/RangesTableRow.js +5 -20
- package/lib/component/panels/RangesPanel/RangesTableRow.js.map +1 -1
- package/lib/component/panels/RangesPanel/TableColumns/ActionsColumn.d.ts.map +1 -1
- package/lib/component/panels/RangesPanel/TableColumns/ActionsColumn.js.map +1 -1
- package/lib/component/panels/RangesPanel/TableColumns/SignalAssignmentColumn.d.ts +9 -0
- package/lib/component/panels/RangesPanel/TableColumns/SignalAssignmentColumn.d.ts.map +1 -0
- package/lib/component/panels/RangesPanel/TableColumns/SignalAssignmentColumn.js +19 -0
- package/lib/component/panels/RangesPanel/TableColumns/SignalAssignmentColumn.js.map +1 -0
- package/lib/component/panels/RangesPanel/TableColumns/SignalAssignmentsColumn.d.ts.map +1 -1
- package/lib/component/panels/RangesPanel/TableColumns/SignalAssignmentsColumn.js.map +1 -1
- package/lib/component/panels/RangesPanel/TableColumns/SignalDeltaColumn.js +2 -2
- package/lib/component/panels/SummaryPanel/SummaryPanel.js +6 -6
- package/lib/component/panels/SummaryPanel/SummaryPanel.js.map +1 -1
- package/lib/component/panels/accordionItems.d.ts.map +1 -1
- package/lib/component/panels/accordionItems.js.map +1 -1
- package/lib/component/panels/extra/preferences/NucleusPreferences.d.ts.map +1 -1
- package/lib/component/panels/informationPanel/InformationEditionModal.d.ts.map +1 -1
- package/lib/component/panels/informationPanel/InformationEditionModal.js.map +1 -1
- package/lib/component/panels/predictionPanel/PredictionPanel.d.ts.map +1 -1
- package/lib/component/panels/predictionPanel/PredictionPanel.js +13 -9
- package/lib/component/panels/predictionPanel/PredictionPanel.js.map +1 -1
- package/lib/component/reducer/Reducer.js +7 -7
- package/lib/component/reducer/Reducer.js.map +1 -1
- package/lib/component/reducer/actions/AssignmentsActions.d.ts.map +1 -1
- package/lib/component/reducer/actions/AssignmentsActions.js +9 -9
- package/lib/component/reducer/actions/AssignmentsActions.js.map +1 -1
- package/lib/component/reducer/actions/CorrelationsActions.d.ts.map +1 -1
- package/lib/component/reducer/actions/CorrelationsActions.js +21 -21
- package/lib/component/reducer/actions/CorrelationsActions.js.map +1 -1
- package/lib/component/reducer/actions/DatabaseActions.js +1 -1
- package/lib/component/reducer/actions/DatabaseActions.js.map +1 -1
- package/lib/component/reducer/actions/DomainActions.d.ts.map +1 -1
- package/lib/component/reducer/actions/DomainActions.js +10 -18
- package/lib/component/reducer/actions/DomainActions.js.map +1 -1
- package/lib/component/reducer/actions/FiltersActions.d.ts.map +1 -1
- package/lib/component/reducer/actions/FiltersActions.js +28 -44
- package/lib/component/reducer/actions/FiltersActions.js.map +1 -1
- package/lib/component/reducer/actions/InsetActions.d.ts.map +1 -1
- package/lib/component/reducer/actions/InsetActions.js +9 -18
- package/lib/component/reducer/actions/InsetActions.js.map +1 -1
- package/lib/component/reducer/actions/IntegralsActions.d.ts +1 -1
- package/lib/component/reducer/actions/IntegralsActions.d.ts.map +1 -1
- package/lib/component/reducer/actions/IntegralsActions.js +43 -48
- package/lib/component/reducer/actions/IntegralsActions.js.map +1 -1
- package/lib/component/reducer/actions/MoleculeActions.d.ts +2 -1
- package/lib/component/reducer/actions/MoleculeActions.d.ts.map +1 -1
- package/lib/component/reducer/actions/MoleculeActions.js +64 -10
- package/lib/component/reducer/actions/MoleculeActions.js.map +1 -1
- package/lib/component/reducer/actions/PeaksActions.d.ts.map +1 -1
- package/lib/component/reducer/actions/PeaksActions.js +110 -121
- package/lib/component/reducer/actions/PeaksActions.js.map +1 -1
- package/lib/component/reducer/actions/PreferencesActions.d.ts.map +1 -1
- package/lib/component/reducer/actions/PreferencesActions.js +2 -1
- package/lib/component/reducer/actions/PreferencesActions.js.map +1 -1
- package/lib/component/reducer/actions/RangesActions.d.ts +18 -18
- package/lib/component/reducer/actions/RangesActions.d.ts.map +1 -1
- package/lib/component/reducer/actions/RangesActions.js +148 -171
- package/lib/component/reducer/actions/RangesActions.js.map +1 -1
- package/lib/component/reducer/actions/SpectraActions.d.ts.map +1 -1
- package/lib/component/reducer/actions/SpectraActions.js +29 -31
- package/lib/component/reducer/actions/SpectraActions.js.map +1 -1
- package/lib/component/reducer/actions/ToolsActions.d.ts.map +1 -1
- package/lib/component/reducer/actions/ToolsActions.js +10 -11
- package/lib/component/reducer/actions/ToolsActions.js.map +1 -1
- package/lib/component/reducer/actions/ZonesActions.d.ts +8 -9
- package/lib/component/reducer/actions/ZonesActions.d.ts.map +1 -1
- package/lib/component/reducer/actions/ZonesActions.js +123 -151
- package/lib/component/reducer/actions/ZonesActions.js.map +1 -1
- package/lib/component/reducer/helper/get2DRange.d.ts +3 -1
- package/lib/component/reducer/helper/get2DRange.d.ts.map +1 -1
- package/lib/component/reducer/helper/get2DRange.js.map +1 -1
- package/lib/component/reducer/helper/getSpectrum.js +1 -1
- package/lib/component/reducer/helper/getSpectrum.js.map +1 -1
- package/lib/component/reducer/helper/setIntegralsViewProperty.js +1 -1
- package/lib/component/reducer/helper/setIntegralsViewProperty.js.map +1 -1
- package/lib/component/reducer/helper/setRangesViewProperty.js +1 -1
- package/lib/component/reducer/helper/setRangesViewProperty.js.map +1 -1
- package/lib/component/useWatchForm.d.ts.map +1 -1
- package/lib/component/useWatchForm.js.map +1 -1
- package/lib/component/utility/stackOverlappingLabels.d.ts +1 -1
- package/lib/component/utility/stackOverlappingLabels.d.ts.map +1 -1
- package/lib/component/utility/stackOverlappingLabels.js.map +1 -1
- package/lib/data/SpectraManager.d.ts.map +1 -1
- package/lib/data/SpectraManager.js.map +1 -1
- package/lib/data/data1d/Spectrum1D/isRangeAssigned.d.ts.map +1 -1
- package/lib/data/data1d/Spectrum1D/isRangeAssigned.js +0 -3
- package/lib/data/data1d/Spectrum1D/isRangeAssigned.js.map +1 -1
- package/lib/data/data1d/Spectrum1D/ranges/autoRangesDetection.d.ts +8 -1
- package/lib/data/data1d/Spectrum1D/ranges/autoRangesDetection.d.ts.map +1 -1
- package/lib/data/data1d/Spectrum1D/ranges/autoRangesDetection.js +1 -2
- package/lib/data/data1d/Spectrum1D/ranges/autoRangesDetection.js.map +1 -1
- package/lib/data/data1d/Spectrum1D/ranges/changeRangeSignal.d.ts +2 -2
- package/lib/data/data1d/Spectrum1D/ranges/changeRangeSignal.js +3 -3
- package/lib/data/data1d/Spectrum1D/ranges/detectRanges.d.ts +4 -14
- package/lib/data/data1d/Spectrum1D/ranges/detectRanges.d.ts.map +1 -1
- package/lib/data/data1d/Spectrum1D/ranges/detectRanges.js +1 -1
- package/lib/data/data1d/Spectrum1D/ranges/detectRanges.js.map +1 -1
- package/lib/data/data2d/Spectrum2D/initiateDatum2D.js.map +1 -1
- package/lib/data/data2d/Spectrum2D/zones/changeZoneSignal.d.ts +3 -5
- package/lib/data/data2d/Spectrum2D/zones/changeZoneSignal.d.ts.map +1 -1
- package/lib/data/data2d/Spectrum2D/zones/changeZoneSignal.js +3 -5
- package/lib/data/data2d/Spectrum2D/zones/changeZoneSignal.js.map +1 -1
- package/lib/data/data2d/Spectrum2D/zones/detectZones.d.ts +2 -1
- package/lib/data/data2d/Spectrum2D/zones/detectZones.d.ts.map +1 -1
- package/lib/data/data2d/Spectrum2D/zones/detectZones.js.map +1 -1
- package/lib/data/data2d/Spectrum2D/zones/detectZonesManual.d.ts +7 -63
- package/lib/data/data2d/Spectrum2D/zones/detectZonesManual.d.ts.map +1 -1
- package/lib/data/data2d/Spectrum2D/zones/detectZonesManual.js +9 -14
- package/lib/data/data2d/Spectrum2D/zones/detectZonesManual.js.map +1 -1
- package/lib/data/data2d/Spectrum2D/zones/getDetectionZones.d.ts +2 -10
- package/lib/data/data2d/Spectrum2D/zones/getDetectionZones.d.ts.map +1 -1
- package/lib/data/data2d/Spectrum2D/zones/getDetectionZones.js +23 -43
- package/lib/data/data2d/Spectrum2D/zones/getDetectionZones.js.map +1 -1
- package/lib/data/data2d/Spectrum2D/zones/initiateZones.d.ts +1 -54
- package/lib/data/data2d/Spectrum2D/zones/initiateZones.d.ts.map +1 -1
- package/lib/data/data2d/Spectrum2D/zones/initiateZones.js +1 -1
- package/lib/data/data2d/Spectrum2D/zones/initiateZones.js.map +1 -1
- package/lib/data/molecules/Molecule.d.ts.map +1 -1
- package/lib/data/molecules/Molecule.js.map +1 -1
- package/lib/data/types/data1d/RangeDetectionResult.d.ts.map +1 -1
- package/lib/data/utilities/FindUtilities.d.ts.map +1 -1
- package/lib/data/utilities/FindUtilities.js +11 -11
- package/lib/data/utilities/FindUtilities.js.map +1 -1
- package/lib/utils/clipboard/clipboardComponents.d.ts.map +1 -1
- package/lib/utils/clipboard/clipboardComponents.js.map +1 -1
- package/lib/utils/clipboard/clipboardHooks.d.ts +2 -2
- package/lib/utils/clipboard/clipboardHooks.d.ts.map +1 -1
- package/lib/utils/clipboard/clipboardHooks.js +10 -4
- package/lib/utils/clipboard/clipboardHooks.js.map +1 -1
- package/lib/versionInfo.d.ts.map +1 -1
- package/lib/versionInfo.js +1 -1
- package/lib/versionInfo.js.map +1 -1
- package/package.json +33 -31
- package/src/component/1d/ApodizationLine.tsx +1 -1
- package/src/component/1d/BrushTracker1D.tsx +10 -10
- package/src/component/1d/FooterBanner.tsx +2 -2
- package/src/component/1d/LinesSeries.tsx +2 -2
- package/src/component/1d/SVGContent1D.tsx +6 -2
- package/src/component/1d/SimilarityTree.tsx +3 -2
- package/src/component/1d/inset/InsetProvider.tsx +4 -2
- package/src/component/1d/integral/IntegralResizable.tsx +2 -1
- package/src/component/1d/matrix/Boxplot.tsx +3 -3
- package/src/component/1d/multiAnalysis/AnalysisRange.tsx +2 -1
- package/src/component/1d/multiplicityTree/MultiplicityTree.tsx +24 -23
- package/src/component/1d/multiplicityTree/generateTreeNodes.ts +10 -1
- package/src/component/1d/peaks/PeakAnnotationsSpreadMode.tsx +4 -2
- package/src/component/1d/peaks/PeakEditionManager.tsx +8 -3
- package/src/component/1d/peaks/Peaks.tsx +5 -1
- package/src/component/1d/ranges/AssignmentLabel.tsx +8 -5
- package/src/component/1d/ranges/Atoms.tsx +2 -2
- package/src/component/1d/ranges/Range.tsx +42 -74
- package/src/component/1d/ranges/Ranges.tsx +33 -28
- package/src/component/1d/ranges/useAssignmentsPopoverActionsButtons.tsx +93 -0
- package/src/component/1d/tool/BaseLineZones.tsx +2 -1
- package/src/component/1d/utilities/intersectionResolver.ts +3 -4
- package/src/component/1d-2d/FieldEdition.tsx +2 -2
- package/src/component/2d/1d-tracer/VerticalSliceChart.tsx +2 -2
- package/src/component/2d/1d-tracer/phase-correction-traces/PhaseTraces.tsx +1 -1
- package/src/component/2d/1d-tracer/phase-correction-traces/SpectrumPhaseTrace.tsx +1 -1
- package/src/component/2d/BrushTracker2D.tsx +50 -55
- package/src/component/2d/FooterBanner.tsx +80 -105
- package/src/component/2d/SVGContent2D.tsx +2 -3
- package/src/component/2d/SlicingView.tsx +1 -1
- package/src/component/2d/Viewer2D.tsx +2 -2
- package/src/component/2d/ft/FTContainer.tsx +4 -5
- package/src/component/2d/tools/XYLabelPointer.tsx +12 -11
- package/src/component/2d/useTracesSpectra.ts +28 -16
- package/src/component/2d/utilities/extractSpectrumSignals.ts +2 -2
- package/src/component/2d/zones/Signal.tsx +1 -1
- package/src/component/2d/zones/SignalsGuideLines.tsx +21 -19
- package/src/component/2d/zones/ZonesAssignmentsLabels.tsx +4 -4
- package/src/component/EventsTrackers/BrushTracker.tsx +24 -17
- package/src/component/assignment/utilities/getAssignments.ts +1 -2
- package/src/component/context/KeyModifierContext.tsx +13 -5
- package/src/component/elements/ActionsButtonsPopover.tsx +25 -8
- package/src/component/elements/AssignmentsCell.tsx +1 -2
- package/src/component/elements/Button.tsx +3 -2
- package/src/component/elements/CheckController.tsx +2 -1
- package/src/component/elements/ContextMenuBluePrint.tsx +2 -1
- package/src/component/elements/D3Axis.tsx +3 -3
- package/src/component/elements/DraggableDialog.tsx +2 -1
- package/src/component/elements/Input.tsx +4 -2
- package/src/component/elements/Input2.tsx +1 -2
- package/src/component/elements/Input2Controller.tsx +2 -1
- package/src/component/elements/Label.tsx +2 -1
- package/src/component/elements/NumberInput2.tsx +4 -2
- package/src/component/elements/NumberInput2Controller.tsx +3 -1
- package/src/component/elements/ReactTable/ReactTable.tsx +1 -3
- package/src/component/elements/ReadOnly.tsx +4 -2
- package/src/component/elements/Sections.tsx +5 -4
- package/src/component/elements/Select.tsx +4 -2
- package/src/component/elements/ToolbarPopoverItem.tsx +3 -3
- package/src/component/elements/export/ExportContent.tsx +1 -2
- package/src/component/elements/print/PrintContent.tsx +1 -2
- package/src/component/hooks/useActiveSpectrumIntegralsViewState.ts +2 -6
- package/src/component/hooks/useActiveSpectrumPeaksViewState.ts +2 -6
- package/src/component/hooks/useActiveSpectrumRangesViewState.ts +2 -6
- package/src/component/hooks/useActiveSpectrumStyleOptions.ts +2 -2
- package/src/component/hooks/useActiveSpectrumZonesViewState.ts +2 -6
- package/src/component/hooks/useExport.tsx +1 -1
- package/src/component/hooks/useSaveSettings.tsx +68 -81
- package/src/component/hooks/useSetActiveSpectrumAction.ts +3 -2
- package/src/component/hooks/useSpectrumWithDataSource.ts +1 -1
- package/src/component/hooks/useWorkspaceAction.ts +5 -0
- package/src/component/modal/ImportPublicationStringModal.tsx +1 -2
- package/src/component/modal/changeSum/ChangeSumModal.tsx +4 -2
- package/src/component/modal/metaImportation/MetaImportationModal.tsx +1 -2
- package/src/component/modal/setting/GeneralSettings.tsx +7 -2
- package/src/component/panels/IntegralsPanel/IntegralTable.tsx +4 -2
- package/src/component/panels/MoleculesPanel/MoleculePanelHeader.tsx +17 -13
- package/src/component/panels/MoleculesPanel/hooks/useAtomAssignment.tsx +17 -15
- package/src/component/panels/MoleculesPanel/utilities/getAssignIds.ts +0 -4
- package/src/component/panels/RangesPanel/RangesPanel.tsx +1 -1
- package/src/component/panels/RangesPanel/RangesTable.tsx +3 -8
- package/src/component/panels/RangesPanel/RangesTableRow.tsx +14 -47
- package/src/component/panels/RangesPanel/TableColumns/ActionsColumn.tsx +1 -2
- package/src/component/panels/RangesPanel/TableColumns/SignalAssignmentColumn.tsx +40 -0
- package/src/component/panels/RangesPanel/TableColumns/SignalAssignmentsColumn.tsx +1 -2
- package/src/component/panels/RangesPanel/TableColumns/SignalDeltaColumn.tsx +2 -2
- package/src/component/panels/SummaryPanel/SummaryPanel.tsx +6 -6
- package/src/component/panels/accordionItems.tsx +4 -2
- package/src/component/panels/extra/preferences/NucleusPreferences.tsx +2 -2
- package/src/component/panels/informationPanel/InformationEditionModal.tsx +4 -2
- package/src/component/panels/predictionPanel/PredictionPanel.tsx +17 -9
- package/src/component/reducer/Reducer.ts +8 -8
- package/src/component/reducer/actions/AssignmentsActions.ts +8 -13
- package/src/component/reducer/actions/CorrelationsActions.ts +21 -22
- package/src/component/reducer/actions/DatabaseActions.ts +1 -1
- package/src/component/reducer/actions/DomainActions.ts +16 -22
- package/src/component/reducer/actions/FiltersActions.ts +34 -58
- package/src/component/reducer/actions/InsetActions.ts +9 -19
- package/src/component/reducer/actions/IntegralsActions.ts +48 -59
- package/src/component/reducer/actions/MoleculeActions.ts +94 -14
- package/src/component/reducer/actions/PeaksActions.ts +112 -136
- package/src/component/reducer/actions/PreferencesActions.ts +4 -3
- package/src/component/reducer/actions/RangesActions.ts +196 -244
- package/src/component/reducer/actions/SpectraActions.ts +40 -45
- package/src/component/reducer/actions/ToolsActions.ts +9 -13
- package/src/component/reducer/actions/ZonesActions.ts +158 -218
- package/src/component/reducer/helper/get2DRange.ts +4 -1
- package/src/component/reducer/helper/getSpectrum.ts +1 -1
- package/src/component/reducer/helper/setIntegralsViewProperty.ts +1 -1
- package/src/component/reducer/helper/setRangesViewProperty.ts +1 -1
- package/src/component/useWatchForm.tsx +2 -1
- package/src/component/utility/stackOverlappingLabels.ts +4 -1
- package/src/data/SpectraManager.ts +0 -2
- package/src/data/data1d/Spectrum1D/isRangeAssigned.ts +0 -4
- package/src/data/data1d/Spectrum1D/ranges/autoRangesDetection.ts +15 -5
- package/src/data/data1d/Spectrum1D/ranges/changeRangeSignal.ts +5 -5
- package/src/data/data1d/Spectrum1D/ranges/detectRanges.ts +5 -14
- package/src/data/data2d/Spectrum2D/initiateDatum2D.ts +2 -2
- package/src/data/data2d/Spectrum2D/zones/changeZoneSignal.ts +3 -5
- package/src/data/data2d/Spectrum2D/zones/detectZones.ts +3 -2
- package/src/data/data2d/Spectrum2D/zones/detectZonesManual.ts +19 -16
- package/src/data/data2d/Spectrum2D/zones/getDetectionZones.ts +35 -56
- package/src/data/data2d/Spectrum2D/zones/initiateZones.ts +1 -1
- package/src/data/molecules/Molecule.ts +2 -1
- package/src/data/types/data1d/RangeDetectionResult.ts +4 -2
- package/src/data/utilities/FindUtilities.ts +9 -8
- package/src/utils/clipboard/clipboardComponents.tsx +2 -1
- package/src/utils/clipboard/clipboardHooks.ts +14 -8
- package/src/versionInfo.ts +1 -1
- package/lib/component/panels/RangesPanel/TableColumns/RangeAssignmentColumn.d.ts +0 -8
- package/lib/component/panels/RangesPanel/TableColumns/RangeAssignmentColumn.d.ts.map +0 -1
- package/lib/component/panels/RangesPanel/TableColumns/RangeAssignmentColumn.js +0 -17
- package/lib/component/panels/RangesPanel/TableColumns/RangeAssignmentColumn.js.map +0 -1
- package/lib/component/panels/RangesPanel/TableColumns/RangeAssignmentsColumn.d.ts +0 -17
- package/lib/component/panels/RangesPanel/TableColumns/RangeAssignmentsColumn.d.ts.map +0 -1
- package/lib/component/panels/RangesPanel/TableColumns/RangeAssignmentsColumn.js +0 -40
- package/lib/component/panels/RangesPanel/TableColumns/RangeAssignmentsColumn.js.map +0 -1
- package/src/component/panels/RangesPanel/TableColumns/RangeAssignmentColumn.tsx +0 -36
- package/src/component/panels/RangesPanel/TableColumns/RangeAssignmentsColumn.tsx +0 -89
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import styled from '@emotion/styled';
|
|
2
|
-
import type { Range } from '@zakodium/nmr-types';
|
|
2
|
+
import type { Range, Signal1D } from '@zakodium/nmr-types';
|
|
3
3
|
import type { Spectrum1D } from '@zakodium/nmrium-core';
|
|
4
4
|
import { useRef } from 'react';
|
|
5
5
|
import { LuLink, LuUnlink } from 'react-icons/lu';
|
|
@@ -157,10 +157,10 @@ interface UseRangeAssignmentOptions {
|
|
|
157
157
|
}
|
|
158
158
|
|
|
159
159
|
function useRangeAssignment(options: UseRangeAssignmentOptions) {
|
|
160
|
-
const { rangeId, signalsIds, spectrumId } = options;
|
|
160
|
+
const { rangeId, signalsIds, spectrumId, signalId } = options;
|
|
161
161
|
|
|
162
162
|
const assignmentData = useAssignmentContext();
|
|
163
|
-
const assignmentContext = useAssignment(
|
|
163
|
+
const assignmentContext = useAssignment(signalId, spectrumId);
|
|
164
164
|
const highlightId = [rangeId]
|
|
165
165
|
.concat(assignmentContext.assignedDiaIds?.x || [])
|
|
166
166
|
.concat(filterAssignedIDs(assignmentData.data, signalsIds));
|
|
@@ -177,13 +177,15 @@ function isRangeSignalAssigned(
|
|
|
177
177
|
options: Pick<IndicationLineProps, 'range' | 'nbAtoms' | 'diaIDs'>,
|
|
178
178
|
) {
|
|
179
179
|
const { range, ...otherProps } = options;
|
|
180
|
-
if (isAssigned(range)) {
|
|
181
|
-
return true;
|
|
182
|
-
}
|
|
183
|
-
|
|
184
180
|
return isAssigned(otherProps);
|
|
185
181
|
}
|
|
186
182
|
|
|
183
|
+
function hasDiaIds(signals: Signal1D[]) {
|
|
184
|
+
return signals.some(
|
|
185
|
+
(signal) => Array.isArray(signal?.diaIDs) && signal.diaIDs.length > 0,
|
|
186
|
+
);
|
|
187
|
+
}
|
|
188
|
+
|
|
187
189
|
function IndicationLine(props: IndicationLineProps) {
|
|
188
190
|
const isAssignBtnTrigged = useRef(false);
|
|
189
191
|
const {
|
|
@@ -197,7 +199,7 @@ function IndicationLine(props: IndicationLineProps) {
|
|
|
197
199
|
nbAtoms,
|
|
198
200
|
id: signalId,
|
|
199
201
|
} = props;
|
|
200
|
-
const { id: rangeId,
|
|
202
|
+
const { id: rangeId, signals } = range;
|
|
201
203
|
const highlightColor = useHighlightColor();
|
|
202
204
|
const isSignalAssigned = isRangeSignalAssigned({ range, diaIDs, nbAtoms });
|
|
203
205
|
|
|
@@ -213,7 +215,7 @@ function IndicationLine(props: IndicationLineProps) {
|
|
|
213
215
|
signalId,
|
|
214
216
|
});
|
|
215
217
|
|
|
216
|
-
const hasDiaIDs =
|
|
218
|
+
const hasDiaIDs = hasDiaIds(signals);
|
|
217
219
|
const isAssignmentActive = assignmentContext.isActive;
|
|
218
220
|
const isHighlighted = highlightContext.isActive || isAssignmentActive;
|
|
219
221
|
|
|
@@ -237,11 +239,12 @@ function IndicationLine(props: IndicationLineProps) {
|
|
|
237
239
|
|
|
238
240
|
function removeAssignmentLabel() {
|
|
239
241
|
dispatch({
|
|
240
|
-
type: '
|
|
242
|
+
type: 'CHANGE_1D_SIGNAL_ASSIGNMENT_LABEL',
|
|
241
243
|
payload: {
|
|
242
244
|
value: '',
|
|
243
245
|
rangeId,
|
|
244
246
|
spectrumId,
|
|
247
|
+
signalId,
|
|
245
248
|
},
|
|
246
249
|
});
|
|
247
250
|
}
|
|
@@ -263,7 +266,7 @@ function IndicationLine(props: IndicationLineProps) {
|
|
|
263
266
|
|
|
264
267
|
function unAssignHandler() {
|
|
265
268
|
dispatch({
|
|
266
|
-
type: '
|
|
269
|
+
type: 'UNASSIGN_1D_SIGNAL',
|
|
267
270
|
payload: {
|
|
268
271
|
rangeKey: rangeId,
|
|
269
272
|
spectrumId,
|
|
@@ -341,6 +344,7 @@ function IndicationLine(props: IndicationLineProps) {
|
|
|
341
344
|
axis={axis}
|
|
342
345
|
rangeId={rangeId}
|
|
343
346
|
spectrumId={spectrumId}
|
|
347
|
+
signalId={signalId}
|
|
344
348
|
/>
|
|
345
349
|
</g>
|
|
346
350
|
</ActionsButtonsPopover>
|
|
@@ -353,11 +357,12 @@ interface AssignmentLabelProps {
|
|
|
353
357
|
x: number;
|
|
354
358
|
y: number;
|
|
355
359
|
rangeId: string;
|
|
360
|
+
signalId: string;
|
|
356
361
|
spectrumId: string;
|
|
357
362
|
}
|
|
358
363
|
|
|
359
364
|
function AssignmentLabel(props: AssignmentLabelProps) {
|
|
360
|
-
const { axis, assignment, x, y, rangeId, spectrumId } = props;
|
|
365
|
+
const { axis, assignment, x, y, rangeId, signalId, spectrumId } = props;
|
|
361
366
|
const { isNewAssignment, dismissNewLabel } = useTriggerNewAssignmentLabel(
|
|
362
367
|
getAxisRangeId({ axis, rangeId }),
|
|
363
368
|
);
|
|
@@ -366,11 +371,12 @@ function AssignmentLabel(props: AssignmentLabelProps) {
|
|
|
366
371
|
function handleChange(value: string) {
|
|
367
372
|
dismissNewLabel();
|
|
368
373
|
dispatch({
|
|
369
|
-
type: '
|
|
374
|
+
type: 'CHANGE_1D_SIGNAL_ASSIGNMENT_LABEL',
|
|
370
375
|
payload: {
|
|
371
376
|
value,
|
|
372
377
|
rangeId,
|
|
373
378
|
spectrumId,
|
|
379
|
+
signalId,
|
|
374
380
|
},
|
|
375
381
|
});
|
|
376
382
|
}
|
|
@@ -413,12 +419,8 @@ export function SignalsGuideLines() {
|
|
|
413
419
|
|
|
414
420
|
return (
|
|
415
421
|
<ShareDataProvider>
|
|
416
|
-
{spectrumData
|
|
417
|
-
|
|
418
|
-
)}
|
|
419
|
-
{spectrumData[0] && (
|
|
420
|
-
<IndicationLines axis="y" spectrum={spectrumData[1]} />
|
|
421
|
-
)}
|
|
422
|
+
{spectrumData.x && <IndicationLines axis="x" spectrum={spectrumData.x} />}
|
|
423
|
+
{spectrumData.y && <IndicationLines axis="y" spectrum={spectrumData.y} />}
|
|
422
424
|
</ShareDataProvider>
|
|
423
425
|
);
|
|
424
426
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import styled from '@emotion/styled';
|
|
2
2
|
import type { Signal1D, Zone, Zones as ZonesType } from '@zakodium/nmr-types';
|
|
3
|
-
import type { Spectrum2D } from '@zakodium/nmrium-core';
|
|
3
|
+
import type { Spectrum1D, Spectrum2D } from '@zakodium/nmrium-core';
|
|
4
4
|
import { useEffect, useLayoutEffect, useRef, useState } from 'react';
|
|
5
5
|
import { PiTextTSlash } from 'react-icons/pi';
|
|
6
6
|
|
|
@@ -40,7 +40,7 @@ interface TargetBoundary {
|
|
|
40
40
|
y2: number;
|
|
41
41
|
}
|
|
42
42
|
|
|
43
|
-
function getDistance(x1:
|
|
43
|
+
function getDistance(x1: number, y1: number, x2: number, y2: number) {
|
|
44
44
|
const deltaX = x2 - x1;
|
|
45
45
|
const deltaY = y2 - y1;
|
|
46
46
|
return Math.hypot(deltaX, deltaY);
|
|
@@ -249,7 +249,7 @@ function findClosestAssignment(signals: Signal1D[], target: number) {
|
|
|
249
249
|
}
|
|
250
250
|
|
|
251
251
|
function getAssignmentLabel(
|
|
252
|
-
spectrum:
|
|
252
|
+
spectrum: Spectrum1D | null,
|
|
253
253
|
options: { from: number; to: number; center: number },
|
|
254
254
|
) {
|
|
255
255
|
if (!spectrum) return null;
|
|
@@ -264,7 +264,7 @@ function getDefaultAssignmentLabel(options: GetDefaultAssignmentOptions) {
|
|
|
264
264
|
const { signals, x, y } = zone;
|
|
265
265
|
if (signals.length === 0) return '';
|
|
266
266
|
|
|
267
|
-
const
|
|
267
|
+
const { x: topSpectrum, y: leftSpectrum } = getTracesSpectra({
|
|
268
268
|
activeSpectra,
|
|
269
269
|
nuclei,
|
|
270
270
|
spectra,
|
|
@@ -1,4 +1,12 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type {
|
|
2
|
+
CSSProperties,
|
|
3
|
+
KeyboardEvent,
|
|
4
|
+
MouseEvent,
|
|
5
|
+
PointerEvent,
|
|
6
|
+
ReactNode,
|
|
7
|
+
Reducer,
|
|
8
|
+
WheelEvent,
|
|
9
|
+
} from 'react';
|
|
2
10
|
import {
|
|
3
11
|
createContext,
|
|
4
12
|
useCallback,
|
|
@@ -9,6 +17,7 @@ import {
|
|
|
9
17
|
} from 'react';
|
|
10
18
|
import { assert } from 'react-science/ui';
|
|
11
19
|
|
|
20
|
+
import type { EventModifierKeys } from '../context/KeyModifierContext.tsx';
|
|
12
21
|
import type { ActionType } from '../reducer/types/ActionType.js';
|
|
13
22
|
|
|
14
23
|
type AdvanceOmit<T, K extends keyof any> = T extends any ? Omit<T, K> : never;
|
|
@@ -20,14 +29,12 @@ export type BaseDetectBrushingOptions = AdvanceOmit<
|
|
|
20
29
|
type Step = 'initial' | 'start' | 'end' | 'brushing';
|
|
21
30
|
|
|
22
31
|
export type BrushAxis = 'X' | 'Y' | 'XY';
|
|
23
|
-
export interface BrushTrackerData {
|
|
32
|
+
export interface BrushTrackerData extends EventModifierKeys {
|
|
24
33
|
step: Step;
|
|
25
34
|
startX: number;
|
|
26
35
|
endX: number;
|
|
27
36
|
startY: number;
|
|
28
37
|
endY: number;
|
|
29
|
-
shiftKey: boolean;
|
|
30
|
-
altKey: boolean;
|
|
31
38
|
mouseButton: MouseButton;
|
|
32
39
|
}
|
|
33
40
|
|
|
@@ -52,9 +59,7 @@ interface BrushScreenCoordination {
|
|
|
52
59
|
}
|
|
53
60
|
|
|
54
61
|
interface BrushTrackerState
|
|
55
|
-
extends BrushTrackerData,
|
|
56
|
-
BrushCoordination,
|
|
57
|
-
BrushScreenCoordination {
|
|
62
|
+
extends BrushTrackerData, BrushCoordination, BrushScreenCoordination {
|
|
58
63
|
step: Step;
|
|
59
64
|
boundingRect: DOMRect | null;
|
|
60
65
|
}
|
|
@@ -64,6 +69,8 @@ const initialState: BrushTrackerState = {
|
|
|
64
69
|
mouseButton: 'unknown',
|
|
65
70
|
shiftKey: false,
|
|
66
71
|
altKey: false,
|
|
72
|
+
ctrlKey: false,
|
|
73
|
+
metaKey: false,
|
|
67
74
|
startX: 0,
|
|
68
75
|
endX: 0,
|
|
69
76
|
startY: 0,
|
|
@@ -103,11 +110,11 @@ interface Position {
|
|
|
103
110
|
y: number;
|
|
104
111
|
}
|
|
105
112
|
|
|
106
|
-
export type ClickOptions =
|
|
113
|
+
export type ClickOptions = MouseEvent & Position;
|
|
107
114
|
export type OnClick = (element: ClickOptions) => void;
|
|
108
115
|
export type { OnClick as OnDoubleClick };
|
|
109
116
|
export type ZoomOptions = Pick<
|
|
110
|
-
|
|
117
|
+
WheelEvent,
|
|
111
118
|
'deltaY' | 'shiftKey' | 'deltaMode' | 'altKey' | 'deltaX' | 'ctrlKey'
|
|
112
119
|
> &
|
|
113
120
|
Position & { invertScroll?: boolean; isBidirectionalZoom: boolean };
|
|
@@ -128,7 +135,7 @@ interface BrushTrackerProps {
|
|
|
128
135
|
clickTriggerMode?: 'native' | 'debounced';
|
|
129
136
|
}
|
|
130
137
|
|
|
131
|
-
function getMouseXY(event:
|
|
138
|
+
function getMouseXY(event: MouseEvent, currentTarget?: Element) {
|
|
132
139
|
const boundingRect = (
|
|
133
140
|
currentTarget ?? event.currentTarget
|
|
134
141
|
).getBoundingClientRect();
|
|
@@ -164,7 +171,7 @@ export function BrushTracker(options: BrushTrackerProps) {
|
|
|
164
171
|
const lastRef = useRef<Position>({ x: 0, y: 0 });
|
|
165
172
|
|
|
166
173
|
const handleClickWithDebounce = useCallback(
|
|
167
|
-
(event:
|
|
174
|
+
(event: MouseEvent, currentTarget: Element) => {
|
|
168
175
|
const { x, y } = getMouseXY(event, currentTarget);
|
|
169
176
|
|
|
170
177
|
// Clear timeout
|
|
@@ -191,13 +198,13 @@ export function BrushTracker(options: BrushTrackerProps) {
|
|
|
191
198
|
[onClick, onDoubleClick],
|
|
192
199
|
);
|
|
193
200
|
|
|
194
|
-
function handleClick(event:
|
|
201
|
+
function handleClick(event: MouseEvent) {
|
|
195
202
|
if (isDraggingRef.current || clickTriggerMode !== 'native') return;
|
|
196
203
|
const { x, y } = getMouseXY(event);
|
|
197
204
|
onClick({ ...event, x, y });
|
|
198
205
|
}
|
|
199
206
|
|
|
200
|
-
function handleDoubleClick(event:
|
|
207
|
+
function handleDoubleClick(event: MouseEvent) {
|
|
201
208
|
if (isDraggingRef.current || clickTriggerMode !== 'native') return;
|
|
202
209
|
|
|
203
210
|
const { x, y } = getMouseXY(event);
|
|
@@ -205,7 +212,7 @@ export function BrushTracker(options: BrushTrackerProps) {
|
|
|
205
212
|
}
|
|
206
213
|
|
|
207
214
|
const pointerDownHandler = useCallback(
|
|
208
|
-
(event:
|
|
215
|
+
(event: PointerEvent) => {
|
|
209
216
|
event.persist();
|
|
210
217
|
const currentTarget = event.currentTarget;
|
|
211
218
|
isDraggingRef.current = false; // Reset dragging flag
|
|
@@ -241,7 +248,7 @@ export function BrushTracker(options: BrushTrackerProps) {
|
|
|
241
248
|
}
|
|
242
249
|
}
|
|
243
250
|
|
|
244
|
-
function moveCallback(event: PointerEvent) {
|
|
251
|
+
function moveCallback(event: globalThis.PointerEvent) {
|
|
245
252
|
isDraggingRef.current = true; // set flag to true to skip click event if the user dragged the mouse
|
|
246
253
|
const { clientX, clientY, shiftKey, altKey, ctrlKey } = event;
|
|
247
254
|
|
|
@@ -310,7 +317,7 @@ export function BrushTracker(options: BrushTrackerProps) {
|
|
|
310
317
|
);
|
|
311
318
|
|
|
312
319
|
const handleMouseWheel = useCallback(
|
|
313
|
-
(event:
|
|
320
|
+
(event: WheelEvent) => {
|
|
314
321
|
const boundingRect = event.currentTarget.getBoundingClientRect();
|
|
315
322
|
const x = event.clientX - boundingRect.x;
|
|
316
323
|
const y = event.clientY - boundingRect.y;
|
|
@@ -350,7 +357,7 @@ export function BrushTracker(options: BrushTrackerProps) {
|
|
|
350
357
|
}
|
|
351
358
|
}, [onBrush, onBrushEnd, state]);
|
|
352
359
|
|
|
353
|
-
function handleStopBrush(event:
|
|
360
|
+
function handleStopBrush(event: KeyboardEvent) {
|
|
354
361
|
const isEscapePressed = event.key === 'Escape';
|
|
355
362
|
const isBrushing = state.step === 'brushing';
|
|
356
363
|
if (!isEscapePressed || !isBrushing) return;
|
|
@@ -20,8 +20,7 @@ export function getAssignments(spectra: Spectrum[]) {
|
|
|
20
20
|
|
|
21
21
|
function setRangesAssignments(assignments: Assignments, ranges: Ranges) {
|
|
22
22
|
const diaIDRecords: Array<{ id: string; diaIDs: string[] }> = [];
|
|
23
|
-
for (const {
|
|
24
|
-
diaIDRecords.push({ id, diaIDs: diaIDs || [] });
|
|
23
|
+
for (const { signals } of ranges.values) {
|
|
25
24
|
for (const signal of signals) {
|
|
26
25
|
diaIDRecords.push({ id: signal.id, diaIDs: signal.diaIDs || [] });
|
|
27
26
|
}
|
|
@@ -51,10 +51,18 @@ interface KeyModifierProviderProps {
|
|
|
51
51
|
|
|
52
52
|
const isMac = globalThis.navigator?.userAgent?.toLowerCase().includes('mac');
|
|
53
53
|
|
|
54
|
-
export
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
54
|
+
export type EventModifierKeys = Record<
|
|
55
|
+
'shiftKey' | 'altKey' | 'metaKey' | 'ctrlKey',
|
|
56
|
+
boolean
|
|
57
|
+
>;
|
|
58
|
+
|
|
59
|
+
export function getModifiers(eventKeys: EventModifierKeys) {
|
|
60
|
+
const { shiftKey, altKey, metaKey, ctrlKey } = eventKeys;
|
|
61
|
+
return {
|
|
62
|
+
ctrlKey: isMac ? metaKey : ctrlKey,
|
|
63
|
+
shiftKey,
|
|
64
|
+
altKey,
|
|
65
|
+
};
|
|
58
66
|
}
|
|
59
67
|
|
|
60
68
|
function toModifiersKey(keyModifiers: KeyModifiers): ModifiersKey {
|
|
@@ -62,7 +70,7 @@ function toModifiersKey(keyModifiers: KeyModifiers): ModifiersKey {
|
|
|
62
70
|
return `shift[${shiftKey ? 'true' : 'false'}]_ctrl[${ctrlKey ? 'true' : 'false'}]_alt[${altKey ? 'true' : 'false'}]`;
|
|
63
71
|
}
|
|
64
72
|
|
|
65
|
-
function getModifiersKey(event:
|
|
73
|
+
function getModifiersKey(event: EventModifierKeys) {
|
|
66
74
|
const keyModifiers = getModifiers(event);
|
|
67
75
|
return toModifiersKey(keyModifiers);
|
|
68
76
|
}
|
|
@@ -51,11 +51,10 @@ function isSeparator(
|
|
|
51
51
|
|
|
52
52
|
type Direction = 'column' | 'row';
|
|
53
53
|
|
|
54
|
-
export interface ActionsButtonsPopoverProps
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
> {
|
|
54
|
+
export interface ActionsButtonsPopoverProps extends Omit<
|
|
55
|
+
PopoverProps,
|
|
56
|
+
'interactionKind' | 'content' | 'modifiers' | 'renderTarget'
|
|
57
|
+
> {
|
|
59
58
|
buttons: ActionButtonProps[];
|
|
60
59
|
contentStyle?: CSSProperties;
|
|
61
60
|
direction?: Direction;
|
|
@@ -73,6 +72,24 @@ function ActionButton(props: ButtonProps) {
|
|
|
73
72
|
return <Button {...props} />;
|
|
74
73
|
}
|
|
75
74
|
|
|
75
|
+
function filterButtons(buttons: ActionButtonProps[]) {
|
|
76
|
+
const visibleButtons: ActionButtonProps[] = [];
|
|
77
|
+
let disablePopover = true;
|
|
78
|
+
|
|
79
|
+
for (const button of buttons) {
|
|
80
|
+
const isSeparatorComponent = isSeparator(button);
|
|
81
|
+
|
|
82
|
+
const show = isSeparatorComponent || button?.visible !== false;
|
|
83
|
+
if (show) visibleButtons.push(button);
|
|
84
|
+
|
|
85
|
+
if (!isSeparatorComponent && button?.visible !== false) {
|
|
86
|
+
disablePopover = false;
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
return { visibleButtons, disablePopover };
|
|
91
|
+
}
|
|
92
|
+
|
|
76
93
|
export function ActionsButtonsPopover(props: ActionsButtonsPopoverProps) {
|
|
77
94
|
const {
|
|
78
95
|
targetTagName = 'div',
|
|
@@ -89,15 +106,14 @@ export function ActionsButtonsPopover(props: ActionsButtonsPopoverProps) {
|
|
|
89
106
|
offsetYMode = 'fixed',
|
|
90
107
|
offsetXMode = 'fixed',
|
|
91
108
|
autoFlip = true,
|
|
109
|
+
disabled,
|
|
92
110
|
...otherProps
|
|
93
111
|
} = props;
|
|
94
112
|
|
|
95
113
|
const [cursor, setCursor] = useState({ x: 0, y: 0 });
|
|
96
114
|
const Wrapper = targetTagName as any;
|
|
97
115
|
|
|
98
|
-
const visibleButtons = buttons
|
|
99
|
-
(button) => isSeparator(button) || button?.visible !== false,
|
|
100
|
-
);
|
|
116
|
+
const { visibleButtons, disablePopover } = filterButtons(buttons);
|
|
101
117
|
|
|
102
118
|
const offsetY = offsetYMode === 'fixed' ? externalOffsetY : cursor.y;
|
|
103
119
|
const offsetX = offsetXMode === 'fixed' ? externalOffsetX : cursor.x;
|
|
@@ -121,6 +137,7 @@ export function ActionsButtonsPopover(props: ActionsButtonsPopoverProps) {
|
|
|
121
137
|
interactionKind="hover"
|
|
122
138
|
enforceFocus={false}
|
|
123
139
|
onOpening={handleMouseEnter}
|
|
140
|
+
disabled={disablePopover || disabled}
|
|
124
141
|
renderTarget={({ onMouseEnter, ...otherProps }) => (
|
|
125
142
|
<Wrapper
|
|
126
143
|
{...targetProps}
|
|
@@ -20,8 +20,7 @@ const AssignmentTableCell = styled.td<AssignmentTableCellProps>`
|
|
|
20
20
|
`;
|
|
21
21
|
|
|
22
22
|
interface AssignmentsCellProps
|
|
23
|
-
extends HTMLAttributes<HTMLTableCellElement>,
|
|
24
|
-
AssignmentTableCellProps {
|
|
23
|
+
extends HTMLAttributes<HTMLTableCellElement>, AssignmentTableCellProps {
|
|
25
24
|
onRemove?: HTMLAttributes<HTMLButtonElement>['onClick'];
|
|
26
25
|
}
|
|
27
26
|
|
|
@@ -234,8 +234,9 @@ type ElementProps<E = unknown> = E extends ElementType
|
|
|
234
234
|
? ComponentPropsWithoutRef<E>
|
|
235
235
|
: never;
|
|
236
236
|
|
|
237
|
-
interface InnerButtonProps<
|
|
238
|
-
extends
|
|
237
|
+
interface InnerButtonProps<
|
|
238
|
+
E extends ElementType = 'button',
|
|
239
|
+
> extends Partial<ButtonStyle> {
|
|
239
240
|
toolTip?: string;
|
|
240
241
|
tooltipOrientation?: TooltipOrientation;
|
|
241
242
|
wrapperClassName?: string;
|
|
@@ -4,7 +4,8 @@ import type { ControllerProps, FieldValues } from 'react-hook-form';
|
|
|
4
4
|
import { Controller } from 'react-hook-form';
|
|
5
5
|
|
|
6
6
|
interface CheckControllerProps<TFieldValues extends FieldValues = FieldValues>
|
|
7
|
-
extends
|
|
7
|
+
extends
|
|
8
|
+
Omit<CheckboxProps, 'name'>,
|
|
8
9
|
Pick<ControllerProps<TFieldValues>, 'control' | 'name'> {
|
|
9
10
|
controllerProps?: Omit<
|
|
10
11
|
ControllerProps<TFieldValues>,
|
|
@@ -24,7 +24,8 @@ export interface BaseContextMenuProps {
|
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
interface ContextMenuProps<E>
|
|
27
|
-
extends
|
|
27
|
+
extends
|
|
28
|
+
BaseContextMenuProps,
|
|
28
29
|
Omit<BluePrintContextMenuProps, 'onSelect' | 'content' | 'children'> {
|
|
29
30
|
as?: E;
|
|
30
31
|
children: ReactNode;
|
|
@@ -18,7 +18,8 @@ type SecondaryGridElementProps = PrimaryGridElementProps & {
|
|
|
18
18
|
};
|
|
19
19
|
|
|
20
20
|
interface D3AxisProps
|
|
21
|
-
extends
|
|
21
|
+
extends
|
|
22
|
+
BaseD3AxisProps,
|
|
22
23
|
Pick<SVGAttributes<SVGGElement>, 'transform' | 'children' | 'className'>,
|
|
23
24
|
UseLinearPrimaryTicksResult {
|
|
24
25
|
gridSize?: number;
|
|
@@ -29,8 +30,7 @@ interface D3AxisProps
|
|
|
29
30
|
|
|
30
31
|
interface TicketsProps extends UseLinearPrimaryTicksResult, BaseD3AxisProps {}
|
|
31
32
|
interface BaseLineProps
|
|
32
|
-
extends Pick<UseLinearPrimaryTicksResult, 'scale'>,
|
|
33
|
-
BaseD3AxisProps {}
|
|
33
|
+
extends Pick<UseLinearPrimaryTicksResult, 'scale'>, BaseD3AxisProps {}
|
|
34
34
|
|
|
35
35
|
interface GridProps<T> extends UseLinearPrimaryTicksResult {
|
|
36
36
|
axisPosition: AxisPosition;
|
|
@@ -47,8 +47,10 @@ export interface InputStyle {
|
|
|
47
47
|
inputWrapper?: CSSProperties;
|
|
48
48
|
}
|
|
49
49
|
|
|
50
|
-
interface InputProps
|
|
51
|
-
|
|
50
|
+
interface InputProps extends Omit<
|
|
51
|
+
React.InputHTMLAttributes<HTMLInputElement>,
|
|
52
|
+
'style'
|
|
53
|
+
> {
|
|
52
54
|
style?: InputStyle;
|
|
53
55
|
autoSelect?: boolean;
|
|
54
56
|
checkValue?: (element: number | string) => boolean;
|
|
@@ -27,8 +27,7 @@ interface BaseInputProps {
|
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
export interface Input2Props<FilterItem extends string = string>
|
|
30
|
-
extends Omit<InputGroupProps, 'onChange' | 'inputRef'>,
|
|
31
|
-
BaseInputProps {
|
|
30
|
+
extends Omit<InputGroupProps, 'onChange' | 'inputRef'>, BaseInputProps {
|
|
32
31
|
getFilterValue?: (item: FilterItem) => string;
|
|
33
32
|
filterItems?: FilterItem[];
|
|
34
33
|
}
|
|
@@ -23,7 +23,8 @@ const CustomFormGroup = styled(FormGroup)<{ isFill?: boolean }>`
|
|
|
23
23
|
`;
|
|
24
24
|
|
|
25
25
|
interface Input2ControllerProps<TFieldValues extends FieldValues = FieldValues>
|
|
26
|
-
extends
|
|
26
|
+
extends
|
|
27
|
+
Omit<Input2Props, 'name'>,
|
|
27
28
|
Pick<ControllerProps<TFieldValues>, 'control' | 'name'>,
|
|
28
29
|
InputMapValueFunctions {
|
|
29
30
|
controllerProps?: Omit<
|
|
@@ -15,7 +15,8 @@ export interface LabelStyle {
|
|
|
15
15
|
container?: CSSProperties;
|
|
16
16
|
}
|
|
17
17
|
interface LabelProps
|
|
18
|
-
extends
|
|
18
|
+
extends
|
|
19
|
+
Omit<LabelHTMLAttributes<HTMLLabelElement>, 'style'>,
|
|
19
20
|
Partial<ContainerQueryWrapperProps> {
|
|
20
21
|
title: string;
|
|
21
22
|
renderTitle?: (title: string, className?: string) => ReactNode;
|
|
@@ -14,7 +14,8 @@ import {
|
|
|
14
14
|
import useCombinedRefs from '../hooks/useCombinedRefs.js';
|
|
15
15
|
|
|
16
16
|
interface ValueProps
|
|
17
|
-
extends
|
|
17
|
+
extends
|
|
18
|
+
Pick<React.InputHTMLAttributes<HTMLInputElement>, 'name' | 'style'>,
|
|
18
19
|
Pick<NumericInputProps, 'onValueChange' | 'value'> {
|
|
19
20
|
checkValue?: (element?: number) => boolean;
|
|
20
21
|
debounceTime?: number;
|
|
@@ -24,7 +25,8 @@ interface UseInputProps extends Omit<ValueProps, 'name'> {
|
|
|
24
25
|
ref: ForwardedRef<HTMLInputElement>;
|
|
25
26
|
}
|
|
26
27
|
export interface NumberInput2Props
|
|
27
|
-
extends
|
|
28
|
+
extends
|
|
29
|
+
Omit<
|
|
28
30
|
Omit<HTMLInputProps, 'size'> & NumericInputProps,
|
|
29
31
|
'value' | 'onValueChange'
|
|
30
32
|
>,
|
|
@@ -6,7 +6,9 @@ import { NumberInput2 } from './NumberInput2.js';
|
|
|
6
6
|
|
|
7
7
|
interface NumberInput2ControllerProps<
|
|
8
8
|
TFieldValues extends FieldValues = FieldValues,
|
|
9
|
-
>
|
|
9
|
+
>
|
|
10
|
+
extends
|
|
11
|
+
Omit<NumberInput2Props, 'name'>,
|
|
10
12
|
Pick<ControllerProps<TFieldValues>, 'control' | 'name'> {
|
|
11
13
|
controllerProps?: Omit<
|
|
12
14
|
ControllerProps<TFieldValues>,
|
|
@@ -74,9 +74,7 @@ export interface TableContextMenuProps {
|
|
|
74
74
|
contextMenu?: BaseContextMenuProps['options'];
|
|
75
75
|
}
|
|
76
76
|
interface ReactTableProps<T extends object>
|
|
77
|
-
extends TableContextMenuProps,
|
|
78
|
-
ClickEvent,
|
|
79
|
-
SortEvent {
|
|
77
|
+
extends TableContextMenuProps, ClickEvent, SortEvent {
|
|
80
78
|
data: T[];
|
|
81
79
|
columns: Array<Column<T>>;
|
|
82
80
|
highlightedSource?: HighlightEventSource;
|
|
@@ -38,8 +38,10 @@ const MessageContainer = styled.div<{ show: boolean }>`
|
|
|
38
38
|
padding: 16px;
|
|
39
39
|
`;
|
|
40
40
|
|
|
41
|
-
interface ReadOnlyProps
|
|
42
|
-
|
|
41
|
+
interface ReadOnlyProps extends Pick<
|
|
42
|
+
React.HTMLAttributes<HTMLDivElement>,
|
|
43
|
+
'onClick'
|
|
44
|
+
> {
|
|
43
45
|
enabled: boolean;
|
|
44
46
|
children: ReactNode;
|
|
45
47
|
message?: string;
|
|
@@ -448,8 +448,7 @@ function Wrapper(props: WrapperProps) {
|
|
|
448
448
|
}
|
|
449
449
|
|
|
450
450
|
interface MainSectionHeaderProps
|
|
451
|
-
extends Pick<HTMLProps<HTMLDivElement>, 'onClick'>,
|
|
452
|
-
BaseSectionProps {
|
|
451
|
+
extends Pick<HTMLProps<HTMLDivElement>, 'onClick'>, BaseSectionProps {
|
|
453
452
|
isOpen: boolean;
|
|
454
453
|
sticky: boolean;
|
|
455
454
|
dragHandleElement?: ReactNode;
|
|
@@ -512,8 +511,10 @@ function MainSectionHeader(props: MainSectionHeaderProps) {
|
|
|
512
511
|
);
|
|
513
512
|
}
|
|
514
513
|
|
|
515
|
-
interface DroppableProps
|
|
516
|
-
|
|
514
|
+
interface DroppableProps extends Pick<
|
|
515
|
+
SectionItemProps,
|
|
516
|
+
'id' | 'onReorder' | 'index'
|
|
517
|
+
> {
|
|
517
518
|
children: ReactNode;
|
|
518
519
|
}
|
|
519
520
|
|
|
@@ -30,8 +30,10 @@ const BaseSelect = styled.select<{ width: number | string | undefined }>`
|
|
|
30
30
|
}
|
|
31
31
|
`;
|
|
32
32
|
|
|
33
|
-
interface SelectProps<T extends object>
|
|
34
|
-
|
|
33
|
+
interface SelectProps<T extends object> extends Omit<
|
|
34
|
+
SelectHTMLAttributes<HTMLSelectElement>,
|
|
35
|
+
'style' | 'onChange'
|
|
36
|
+
> {
|
|
35
37
|
onChange?: (element: string) => void;
|
|
36
38
|
items: T[];
|
|
37
39
|
defaultValue?: string | number | undefined;
|
|
@@ -8,14 +8,14 @@ import type {
|
|
|
8
8
|
import { Toolbar, TooltipHelpContent } from 'react-science/ui';
|
|
9
9
|
|
|
10
10
|
export interface ToolbarPopoverMenuItem<T = object>
|
|
11
|
-
extends MenuItemProps,
|
|
12
|
-
Pick<ToolbarItemProps, 'tooltipProps'> {
|
|
11
|
+
extends MenuItemProps, Pick<ToolbarItemProps, 'tooltipProps'> {
|
|
13
12
|
data?: T;
|
|
14
13
|
tooltip?: string | TooltipItem;
|
|
15
14
|
}
|
|
16
15
|
|
|
17
16
|
interface CustomToolbarPopoverItemProps<T = object>
|
|
18
|
-
extends
|
|
17
|
+
extends
|
|
18
|
+
Omit<ToolbarPopoverItemProps, 'onClick' | 'content' | 'itemProps'>,
|
|
19
19
|
Pick<
|
|
20
20
|
ToolbarItemProps,
|
|
21
21
|
'tooltip' | 'icon' | 'tooltipProps' | 'active' | 'id'
|
|
@@ -34,8 +34,7 @@ interface InnerExportFrameProps extends BaseExportFrameProps {
|
|
|
34
34
|
exportOptions: ExportSettings;
|
|
35
35
|
}
|
|
36
36
|
interface ExportFrameProps
|
|
37
|
-
extends BaseExportFrameProps,
|
|
38
|
-
Partial<BaseExportProps> {
|
|
37
|
+
extends BaseExportFrameProps, Partial<BaseExportProps> {
|
|
39
38
|
exportOptions?: ExportSettings;
|
|
40
39
|
onExportDialogClose?: () => void;
|
|
41
40
|
confirmButtonText?: string;
|