nmrium 0.38.0 → 0.38.2
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 +27 -4
- package/lib/component/1d/ExclusionZoneAnnotation.js +1 -1
- package/lib/component/1d/ExclusionZonesAnnotations.js +1 -1
- package/lib/component/1d/FooterBanner.js +5 -5
- package/lib/component/1d/SpectraLegends.js +2 -3
- package/lib/component/1d/Viewer1D.js +1 -1
- package/lib/component/1d/database/DatabaseSpectrum.js +2 -1
- package/lib/component/1d/integral/Integral.d.ts +1 -1
- package/lib/component/1d/integral/IntegralResizable.d.ts +1 -1
- package/lib/component/1d/jCouplingGraph/JsCouplings.d.ts +1 -1
- package/lib/component/1d/multiAnalysis/MultiAnalysisRanges.js +2 -2
- package/lib/component/1d/multiplicityTree/LevelNode.d.ts +1 -1
- package/lib/component/1d/multiplicityTree/MultiplicityTree.d.ts +1 -1
- package/lib/component/1d/multiplicityTree/StringNode.d.ts +1 -1
- package/lib/component/1d/multiplicityTree/buildTreeNode.d.ts +1 -1
- package/lib/component/1d/peaks/usePeakShapesPath.d.ts +2 -1
- package/lib/component/1d/ranges/Range.d.ts +1 -1
- package/lib/component/1d/tool/PeakPointer.js +6 -6
- package/lib/component/1d/tool/XLabelPointer.js +5 -5
- package/lib/component/1d-2d/components/FloatMoleculeStructures/DraggableStructure.d.ts +1 -1
- package/lib/component/1d-2d/components/FloatMoleculeStructures/index.d.ts +1 -1
- package/lib/component/1d-2d/tools/BrushX.js +2 -3
- package/lib/component/1d-2d/tools/BrushXY.js +2 -3
- package/lib/component/1d-2d/tools/CrossLinePointer.js +4 -5
- package/lib/component/2d/Chart2D.js +4 -4
- package/lib/component/2d/FooterBanner.js +5 -5
- package/lib/component/2d/Viewer2D.js +1 -1
- package/lib/component/2d/tools/XYLabelPointer.js +5 -5
- package/lib/component/2d/zones/Signal.d.ts +1 -1
- package/lib/component/2d/zones/SignalCrosshair.d.ts +1 -1
- package/lib/component/2d/zones/Zone.d.ts +1 -1
- package/lib/component/EventsTrackers/BrushTracker.d.ts +20 -12
- package/lib/component/EventsTrackers/BrushTracker.js +35 -22
- package/lib/component/EventsTrackers/MouseTracker.d.ts +6 -2
- package/lib/component/EventsTrackers/MouseTracker.js +4 -1
- package/lib/component/NMRium.d.ts +4 -5
- package/lib/component/NMRium.js +11 -14
- package/lib/component/assignment/AssignmentsReducer.d.ts +2 -2
- package/lib/component/context/PreferencesContext.d.ts +6 -6
- package/lib/component/elements/Button.d.ts +13 -11
- package/lib/component/elements/Button.js +16 -25
- package/lib/component/elements/ColorInput.d.ts +0 -1
- package/lib/component/elements/ColorInput.js +2 -2
- package/lib/component/elements/EditableColumn.js +5 -2
- package/lib/component/elements/Input.js +2 -4
- package/lib/component/elements/Label.d.ts +1 -0
- package/lib/component/elements/Label.js +2 -2
- package/lib/component/elements/MolecularFormulaInput.d.ts +2 -2
- package/lib/component/elements/MolecularFormulaInput.js +15 -18
- package/lib/component/elements/NextPrev.d.ts +5 -3
- package/lib/component/elements/NextPrev.js +26 -8
- package/lib/component/elements/NumberInput.js +2 -2
- package/lib/component/elements/ReactTable/ReactTable.js +4 -4
- package/lib/component/elements/formik/FormikCheckBox.d.ts +2 -1
- package/lib/component/elements/formik/FormikCheckBox.js +2 -2
- package/lib/component/elements/formik/FormikColumnFormatField.d.ts +4 -0
- package/lib/component/elements/formik/FormikColumnFormatField.js +19 -16
- package/lib/component/elements/formik/FormikInput.js +10 -6
- package/lib/component/elements/formik/FormikSelect.js +1 -1
- package/lib/component/header/ApodizationOptionsPanel.js +4 -3
- package/lib/component/header/AutoPeakPickingOptionPanel.js +16 -7
- package/lib/component/header/BaseLineCorrectionPanel.js +5 -2
- package/lib/component/header/PhaseCorrectionPanel.js +5 -2
- package/lib/component/header/RangesPickingOptionPanel.js +15 -7
- package/lib/component/header/ZeroFillingOptionsPanel.js +1 -1
- package/lib/component/highlight/index.d.ts +1 -1
- package/lib/component/hooks/useActiveSpectra.d.ts +1 -1
- package/lib/component/hooks/useActiveSpectrum.d.ts +1 -1
- package/lib/component/hooks/useActiveSpectrumPeaksViewState.d.ts +1 -1
- package/lib/component/hooks/useCheckPointsNumberInWindowArea.d.ts +2 -0
- package/lib/component/hooks/useCheckPointsNumberInWindowArea.js +17 -0
- package/lib/component/hooks/useCheckToolsVisibility.d.ts +2 -2
- package/lib/component/hooks/useDatumWithSpectraStatistics.d.ts +3 -2
- package/lib/component/hooks/useExport.js +1 -1
- package/lib/component/hooks/useFilter.d.ts +2 -1
- package/lib/component/hooks/usePanelPreferences.d.ts +3 -3
- package/lib/component/hooks/usePanelPreferences.js +4 -0
- package/lib/component/hooks/useSaveSettings.d.ts +1 -1
- package/lib/component/hooks/useSaveSettings.js +1 -1
- package/lib/component/hooks/useVerticalAlign.d.ts +1 -1
- package/lib/component/loader/DropZone.js +1 -2
- package/lib/component/modal/EditPeakShapeModal.d.ts +2 -2
- package/lib/component/modal/LoadJCAMPModal.d.ts +3 -3
- package/lib/component/modal/LoadJCAMPModal.js +35 -66
- package/lib/component/modal/ModalStyle.js +0 -10
- package/lib/component/modal/MoleculeStructureEditorModal.d.ts +2 -1
- package/lib/component/modal/MoleculeStructureEditorModal.js +12 -6
- package/lib/component/modal/MultipletAnalysisModal.d.ts +2 -2
- package/lib/component/modal/PredictSpectraModal.d.ts +4 -2
- package/lib/component/modal/PredictSpectraModal.js +43 -105
- package/lib/component/modal/SaveAsModal.d.ts +2 -0
- package/lib/component/modal/SaveAsModal.js +21 -14
- package/lib/component/modal/changeSum/ChangeSumModal.js +25 -38
- package/lib/component/modal/editRange/forms/components/AddSignalFormTab.d.ts +1 -1
- package/lib/component/modal/editRange/forms/components/DeltaInput.js +2 -0
- package/lib/component/modal/editRange/forms/components/SignalsForm.d.ts +2 -2
- package/lib/component/modal/metaImportation/MetaImportationModal.js +15 -5
- package/lib/component/modal/setting/GeneralSettings.js +1 -6
- package/lib/component/modal/setting/settings-tabs/DatabasesTabContent.d.ts +1 -1
- package/lib/component/panels/IntegralsPanel/IntegralPanel.d.ts +1 -1
- package/lib/component/panels/IntegralsPanel/IntegralTable.d.ts +1 -1
- package/lib/component/panels/IntegralsPanel/IntegralsPreferences.js +7 -15
- package/lib/component/panels/MoleculesPanel/MoleculeHeader.js +2 -2
- package/lib/component/panels/MoleculesPanel/MoleculePanel.d.ts +1 -11
- package/lib/component/panels/MoleculesPanel/MoleculePanel.js +20 -25
- package/lib/component/panels/MoleculesPanel/MoleculePanelHeader.d.ts +6 -11
- package/lib/component/panels/MoleculesPanel/MoleculePanelHeader.js +71 -81
- package/lib/component/panels/MoleculesPanel/Utilities.d.ts +1 -1
- package/lib/component/panels/MoleculesPanel/Utilities.js +3 -1
- package/lib/component/panels/MultipleSpectraAnalysisPanel/base/AnalysisColumnHeader.js +6 -6
- package/lib/component/panels/MultipleSpectraAnalysisPanel/preferences/AnalysisTablePreferences.js +2 -2
- package/lib/component/panels/MultipleSpectraAnalysisPanel/preferences/index.js +2 -2
- package/lib/component/panels/PeaksPanel/PeaksPanel.d.ts +1 -1
- package/lib/component/panels/RangesPanel/RangesHeader.js +39 -53
- package/lib/component/panels/RangesPanel/RangesPreferences.d.ts +1 -1
- package/lib/component/panels/RangesPanel/RangesPreferences.js +7 -22
- package/lib/component/panels/RangesPanel/RangesTable.d.ts +2 -2
- package/lib/component/panels/RangesPanel/RangesTableRow.d.ts +2 -2
- package/lib/component/panels/RangesPanel/TableColumns/SignalDeltaHzColumn.d.ts +1 -1
- package/lib/component/panels/RangesPanel/hooks/useMapRanges.d.ts +1 -1
- package/lib/component/panels/SpectrumsPanel/SpectraTable.js +5 -1
- package/lib/component/panels/SpectrumsPanel/base/SpectraColumnsManager.js +10 -4
- package/lib/component/panels/SpectrumsPanel/base/setting/processSnapPlot.d.ts +2 -2
- package/lib/component/panels/SummaryPanel/CorrelationTable/AdditionalColumnField.js +1 -1
- package/lib/component/panels/SummaryPanel/CorrelationTable/CorrelationTableRow.js +1 -1
- package/lib/component/panels/SummaryPanel/CorrelationTable/editLink/EditPathLength.d.ts +1 -1
- package/lib/component/panels/ZonesPanel/hooks/useMapZones.d.ts +1 -1
- package/lib/component/panels/databasePanel/DatabasePanel.d.ts +1 -1
- package/lib/component/panels/databasePanel/DatabasePanel.js +11 -28
- package/lib/component/panels/databasePanel/DatabasePreferences.js +2 -2
- package/lib/component/panels/header/DefaultPanelHeader.d.ts +2 -3
- package/lib/component/panels/header/DefaultPanelHeader.js +18 -26
- package/lib/component/panels/header/PanelHeader.d.ts +7 -0
- package/lib/component/panels/header/PanelHeader.js +12 -0
- package/lib/component/panels/predictionPanel/PredictionOptionsPanel.d.ts +9 -0
- package/lib/component/panels/predictionPanel/PredictionOptionsPanel.js +94 -0
- package/lib/component/panels/predictionPanel/PredictionPanel.d.ts +1 -1
- package/lib/component/panels/predictionPanel/PredictionPanel.js +107 -37
- package/lib/component/panels/predictionPanel/PredictionPreferences.d.ts +3 -0
- package/lib/component/panels/predictionPanel/PredictionPreferences.js +24 -0
- package/lib/component/panels/predictionPanel/PredictionSimpleOptions.d.ts +2 -0
- package/lib/component/panels/predictionPanel/PredictionSimpleOptions.js +44 -0
- package/lib/component/reducer/Reducer.d.ts +5 -87
- package/lib/component/reducer/Reducer.js +1 -25
- package/lib/component/reducer/actions/FiltersActions.d.ts +1 -2
- package/lib/component/reducer/actions/FiltersActions.js +47 -52
- package/lib/component/reducer/actions/HistoryActions.d.ts +4 -0
- package/lib/component/reducer/actions/HistoryActions.js +40 -0
- package/lib/component/reducer/actions/IntegralsActions.d.ts +1 -1
- package/lib/component/reducer/actions/LoadActions.d.ts +1 -2
- package/lib/component/reducer/actions/LoadActions.js +1 -1
- package/lib/component/reducer/actions/MoleculeActions.d.ts +7 -4
- package/lib/component/reducer/actions/MoleculeActions.js +57 -28
- package/lib/component/reducer/actions/PeaksActions.d.ts +1 -2
- package/lib/component/reducer/actions/PeaksActions.js +3 -3
- package/lib/component/reducer/actions/RangesActions.d.ts +4 -5
- package/lib/component/reducer/actions/RangesActions.js +5 -27
- package/lib/component/reducer/actions/SpectrumsActions.js +2 -2
- package/lib/component/reducer/actions/ToolsActions.d.ts +2 -2
- package/lib/component/reducer/actions/ZonesActions.d.ts +2 -1
- package/lib/component/reducer/actions/ZonesActions.js +1 -2
- package/lib/component/reducer/helper/getActiveSpectra.d.ts +1 -1
- package/lib/component/reducer/helper/getActiveSpectrum.d.ts +1 -1
- package/lib/component/reducer/helper/getVerticalAlign.d.ts +1 -1
- package/lib/component/reducer/preferences/panelsPreferencesDefaultValues.d.ts +1 -1
- package/lib/component/reducer/preferences/preferencesReducer.d.ts +1 -1
- package/lib/component/reducer/preferences/utilities/getActiveWorkspace.d.ts +1 -1
- package/lib/component/reducer/preferences/utilities/getPreferencesByWorkspace.d.ts +2 -3
- package/lib/component/reducer/preferences/utilities/initWorkspace.d.ts +1 -1
- package/lib/component/reducer/preferences/utilities/mapNucleiFormatting.d.ts +1 -1
- package/lib/component/reducer/preferences/utilities/mapWorkspaces.d.ts +1 -1
- package/lib/component/toolbar/BasicToolBar.js +6 -11
- package/lib/component/toolbar/ToolTypes.d.ts +2 -2
- package/lib/component/toolbar/ToolTypes.js +1 -1
- package/lib/component/workspaces/assignment.d.ts +1 -1
- package/lib/component/workspaces/basic.d.ts +1 -1
- package/lib/component/workspaces/embedded.d.ts +1 -1
- package/lib/component/workspaces/exercise.d.ts +1 -1
- package/lib/component/workspaces/index.d.ts +6 -6
- package/lib/component/workspaces/prediction.d.ts +1 -1
- package/lib/component/workspaces/prediction.js +193 -0
- package/lib/component/workspaces/process1D.d.ts +1 -1
- package/lib/component/workspaces/workspaceDefaultProperties.d.ts +1 -1
- package/lib/component/workspaces/workspaceDefaultProperties.js +1 -1
- package/lib/data/PredictionManager.d.ts +2 -1
- package/lib/data/PredictionManager.js +16 -2
- package/lib/data/SpectraManager.d.ts +1 -2
- package/lib/data/constants/DefaultApodizationOptions.d.ts +2 -0
- package/lib/data/constants/DefaultApodizationOptions.js +5 -0
- package/lib/data/data1d/Spectrum1D/SumManager.d.ts +1 -1
- package/lib/data/data1d/Spectrum1D/convertDataToFloat64Array.d.ts +2 -2
- package/lib/data/data1d/Spectrum1D/generateJGraphData.d.ts +1 -1
- package/lib/data/data1d/Spectrum1D/index.d.ts +1 -5
- package/lib/data/data1d/Spectrum1D/index.js +1 -5
- package/lib/data/data1d/Spectrum1D/initiateDatum1D.js +3 -3
- package/lib/data/data1d/Spectrum1D/integrals/initiateIntegrals.d.ts +2 -1
- package/lib/data/data1d/Spectrum1D/integrals/initiateIntegrals.js +1 -1
- package/lib/data/data1d/Spectrum1D/isRangeAssigned.d.ts +1 -1
- package/lib/data/data1d/Spectrum1D/peaks/autoPeakPicking.d.ts +2 -1
- package/lib/data/data1d/Spectrum1D/peaks/autoPeakPicking.js +1 -2
- package/lib/data/data1d/Spectrum1D/peaks/initiatePeaks.d.ts +3 -2
- package/lib/data/data1d/Spectrum1D/peaks/initiatePeaks.js +1 -1
- package/lib/data/data1d/Spectrum1D/peaks/lookupPeak.d.ts +2 -2
- package/lib/data/data1d/Spectrum1D/peaks/optimizePeaks.d.ts +2 -1
- package/lib/data/data1d/Spectrum1D/peaks/optimizePeaks.js +1 -2
- package/lib/data/data1d/Spectrum1D/ranges/addRange.d.ts +7 -7
- package/lib/data/data1d/Spectrum1D/ranges/addRange.js +5 -24
- package/lib/data/data1d/Spectrum1D/ranges/autoRangesDetection.d.ts +2 -1
- package/lib/data/data1d/Spectrum1D/ranges/changeRange.d.ts +2 -1
- package/lib/data/data1d/Spectrum1D/ranges/changeRange.js +1 -1
- package/lib/data/data1d/Spectrum1D/ranges/checkRangeKind.d.ts +1 -1
- package/lib/data/data1d/Spectrum1D/ranges/detectRange.js +1 -1
- package/lib/data/data1d/Spectrum1D/ranges/detectRanges.js +1 -2
- package/lib/data/data1d/Spectrum1D/ranges/initiateRanges.d.ts +37 -2
- package/lib/data/data1d/Spectrum1D/ranges/initiateRanges.js +1 -1
- package/lib/data/data1d/database.js +2 -4
- package/lib/data/data1d/multipleSpectraAnalysis.d.ts +3 -30
- package/lib/data/data1d/multipleSpectraAnalysis.js +4 -15
- package/lib/data/data2d/Spectrum2D/getMissingProjection.d.ts +3 -2
- package/lib/data/data2d/Spectrum2D/getShift.js +1 -1
- package/lib/data/data2d/Spectrum2D/getSlice.d.ts +1 -1
- package/lib/data/data2d/Spectrum2D/initiateDatum2D.js +1 -1
- package/lib/data/data2d/Spectrum2D/zones/detectZones.d.ts +1 -1
- package/lib/data/data2d/Spectrum2D/zones/detectZonesManual.d.ts +1 -1
- package/lib/data/data2d/Spectrum2D/zones/initiateZones.d.ts +3 -2
- package/lib/data/data2d/Spectrum2D/zones/isZoneExists.d.ts +2 -1
- package/lib/data/data2d/Spectrum2D/zones/mapZones.d.ts +3 -2
- package/lib/data/getDefaultMatrixFilters.d.ts +1 -1
- package/lib/data/types/data1d/ComplexData1D.d.ts +2 -2
- package/lib/data/types/data1d/RangeDetectionResult.d.ts +1 -1
- package/lib/data/utilities/FindUtilities.d.ts +2 -1
- package/lib/data/utilities/RangeUtilities.d.ts +1 -1
- package/lib/data/utilities/ZoneUtilities.d.ts +1 -1
- package/lib/data/utilities/calculateSanPlot.d.ts +2 -2
- package/lib/types/NMRiumDataReturn.d.ts +1 -3
- package/lib/versionInfo.js +1 -1
- package/lib-cjs/component/1d/ApodizationLine.js +28 -5
- package/lib-cjs/component/1d/ExclusionZoneAnnotation.js +3 -26
- package/lib-cjs/component/1d/ExclusionZonesAnnotations.js +5 -28
- package/lib-cjs/component/1d/FooterBanner.js +2 -2
- package/lib-cjs/component/1d/SpectraLegends.js +1 -2
- package/lib-cjs/component/1d/database/DatabaseSpectrum.js +2 -1
- package/lib-cjs/component/1d/multiAnalysis/MultiAnalysisRanges.js +2 -2
- package/lib-cjs/component/1d/tool/PeakPointer.js +3 -3
- package/lib-cjs/component/1d/tool/XLabelPointer.js +2 -2
- package/lib-cjs/component/1d-2d/tools/BrushX.js +1 -2
- package/lib-cjs/component/1d-2d/tools/BrushXY.js +1 -2
- package/lib-cjs/component/1d-2d/tools/CrossLinePointer.js +2 -3
- package/lib-cjs/component/2d/Chart2D.js +4 -4
- package/lib-cjs/component/2d/FooterBanner.js +2 -2
- package/lib-cjs/component/2d/tools/XYLabelPointer.js +2 -2
- package/lib-cjs/component/EventsTrackers/BrushTracker.js +36 -22
- package/lib-cjs/component/EventsTrackers/MouseTracker.js +4 -1
- package/lib-cjs/component/NMRium.js +8 -11
- package/lib-cjs/component/elements/Button.js +16 -25
- package/lib-cjs/component/elements/ColorInput.js +2 -2
- package/lib-cjs/component/elements/EditableColumn.js +5 -2
- package/lib-cjs/component/elements/Input.js +2 -4
- package/lib-cjs/component/elements/Label.js +2 -2
- package/lib-cjs/component/elements/MolecularFormulaInput.js +14 -16
- package/lib-cjs/component/elements/NextPrev.js +26 -8
- package/lib-cjs/component/elements/NumberInput.js +2 -2
- package/lib-cjs/component/elements/ReactTable/ReactTable.js +4 -4
- package/lib-cjs/component/elements/formik/FormikCheckBox.js +2 -2
- package/lib-cjs/component/elements/formik/FormikColumnFormatField.js +20 -16
- package/lib-cjs/component/elements/formik/FormikInput.js +10 -6
- package/lib-cjs/component/elements/formik/FormikSelect.js +1 -1
- package/lib-cjs/component/header/ApodizationOptionsPanel.js +6 -5
- package/lib-cjs/component/header/AutoPeakPickingOptionPanel.js +15 -6
- package/lib-cjs/component/header/BaseLineCorrectionPanel.js +6 -3
- package/lib-cjs/component/header/PhaseCorrectionPanel.js +6 -26
- package/lib-cjs/component/header/RangesPickingOptionPanel.js +15 -7
- package/lib-cjs/component/header/ZeroFillingOptionsPanel.js +2 -25
- package/lib-cjs/component/hooks/useCheckPointsNumberInWindowArea.js +24 -0
- package/lib-cjs/component/hooks/useExport.js +1 -1
- package/lib-cjs/component/hooks/usePanelPreferences.js +4 -0
- package/lib-cjs/component/hooks/useSaveSettings.js +1 -1
- package/lib-cjs/component/loader/DropZone.js +1 -2
- package/lib-cjs/component/modal/LoadJCAMPModal.js +60 -67
- package/lib-cjs/component/modal/ModalStyle.js +0 -10
- package/lib-cjs/component/modal/MoleculeStructureEditorModal.js +12 -6
- package/lib-cjs/component/modal/PredictSpectraModal.js +43 -126
- package/lib-cjs/component/modal/SaveAsModal.js +22 -14
- package/lib-cjs/component/modal/changeSum/ChangeSumModal.js +24 -37
- package/lib-cjs/component/modal/editRange/forms/components/DeltaInput.js +2 -0
- package/lib-cjs/component/modal/metaImportation/MetaImportationModal.js +15 -5
- package/lib-cjs/component/modal/setting/GeneralSettings.js +1 -6
- package/lib-cjs/component/panels/IntegralsPanel/IntegralsPreferences.js +6 -14
- package/lib-cjs/component/panels/MoleculesPanel/MoleculeHeader.js +2 -2
- package/lib-cjs/component/panels/MoleculesPanel/MoleculePanel.js +19 -24
- package/lib-cjs/component/panels/MoleculesPanel/MoleculePanelHeader.js +76 -86
- package/lib-cjs/component/panels/MoleculesPanel/Utilities.js +3 -1
- package/lib-cjs/component/panels/MultipleSpectraAnalysisPanel/base/AnalysisColumnHeader.js +6 -6
- package/lib-cjs/component/panels/MultipleSpectraAnalysisPanel/preferences/AnalysisTablePreferences.js +2 -2
- package/lib-cjs/component/panels/MultipleSpectraAnalysisPanel/preferences/index.js +2 -2
- package/lib-cjs/component/panels/RangesPanel/RangesHeader.js +38 -52
- package/lib-cjs/component/panels/RangesPanel/RangesPreferences.js +5 -20
- package/lib-cjs/component/panels/SpectrumsPanel/SpectraTable.js +5 -1
- package/lib-cjs/component/panels/SpectrumsPanel/base/SpectraColumnsManager.js +10 -4
- package/lib-cjs/component/panels/SummaryPanel/CorrelationTable/AdditionalColumnField.js +1 -1
- package/lib-cjs/component/panels/SummaryPanel/CorrelationTable/CorrelationTableRow.js +1 -1
- package/lib-cjs/component/panels/databasePanel/DatabasePanel.js +11 -28
- package/lib-cjs/component/panels/databasePanel/DatabasePreferences.js +25 -2
- package/lib-cjs/component/panels/header/DefaultPanelHeader.js +18 -26
- package/lib-cjs/component/panels/header/PanelHeader.js +15 -0
- package/lib-cjs/component/panels/predictionPanel/PredictionOptionsPanel.js +122 -0
- package/lib-cjs/component/panels/predictionPanel/PredictionPanel.js +107 -37
- package/lib-cjs/component/panels/predictionPanel/PredictionPreferences.js +29 -0
- package/lib-cjs/component/panels/predictionPanel/PredictionSimpleOptions.js +72 -0
- package/lib-cjs/component/reducer/Reducer.js +2 -27
- package/lib-cjs/component/reducer/actions/FiltersActions.js +66 -94
- package/lib-cjs/component/reducer/actions/HistoryActions.js +45 -0
- package/lib-cjs/component/reducer/actions/MoleculeActions.js +58 -32
- package/lib-cjs/component/reducer/actions/PeaksActions.js +3 -3
- package/lib-cjs/component/reducer/actions/RangesActions.js +7 -52
- package/lib-cjs/component/reducer/actions/SpectrumsActions.js +4 -27
- package/lib-cjs/component/reducer/actions/ZonesActions.js +4 -28
- package/lib-cjs/component/toolbar/BasicToolBar.js +5 -10
- package/lib-cjs/component/toolbar/ToolTypes.js +9 -32
- package/lib-cjs/component/workspaces/prediction.js +193 -0
- package/lib-cjs/component/workspaces/workspaceDefaultProperties.js +21 -44
- package/lib-cjs/data/PredictionManager.js +16 -2
- package/lib-cjs/data/constants/DefaultApodizationOptions.js +8 -0
- package/lib-cjs/data/data1d/Spectrum1D/index.js +7 -11
- package/lib-cjs/data/data1d/Spectrum1D/initiateDatum1D.js +9 -32
- package/lib-cjs/data/data1d/Spectrum1D/integrals/initiateIntegrals.js +2 -2
- package/lib-cjs/data/data1d/Spectrum1D/peaks/autoPeakPicking.js +1 -2
- package/lib-cjs/data/data1d/Spectrum1D/peaks/initiatePeaks.js +2 -2
- package/lib-cjs/data/data1d/Spectrum1D/peaks/optimizePeaks.js +1 -2
- package/lib-cjs/data/data1d/Spectrum1D/ranges/addRange.js +7 -26
- package/lib-cjs/data/data1d/Spectrum1D/ranges/changeRange.js +2 -2
- package/lib-cjs/data/data1d/Spectrum1D/ranges/detectRange.js +2 -2
- package/lib-cjs/data/data1d/Spectrum1D/ranges/detectRanges.js +3 -4
- package/lib-cjs/data/data1d/Spectrum1D/ranges/initiateRanges.js +2 -2
- package/lib-cjs/data/data1d/database.js +2 -4
- package/lib-cjs/data/data1d/multipleSpectraAnalysis.js +5 -16
- package/lib-cjs/data/data2d/Spectrum2D/getShift.js +3 -26
- package/lib-cjs/data/data2d/Spectrum2D/initiateDatum2D.js +2 -25
- package/lib-cjs/versionInfo.js +1 -1
- package/package.json +25 -25
- package/lib/component/panels/predictionPanel/PredictionOptions.d.ts +0 -7
- package/lib/component/panels/predictionPanel/PredictionOptions.js +0 -74
- package/lib/component/workspaces/Workspace.d.ts +0 -188
- package/lib/component/workspaces/Workspace.js +0 -1
- package/lib/data/Filters.d.ts +0 -12
- package/lib/data/Filters.js +0 -12
- package/lib/data/FiltersManager.d.ts +0 -30
- package/lib/data/FiltersManager.js +0 -175
- package/lib/data/data1d/Spectrum1D/getShiftX.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/getShiftX.js +0 -6
- package/lib/data/data1d/Spectrum1D/getSpectrumErrorValue.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/getSpectrumErrorValue.js +0 -4
- package/lib/data/data1d/Spectrum1D/integrals/checkIntegralKind.d.ts +0 -7
- package/lib/data/data1d/Spectrum1D/integrals/checkIntegralKind.js +0 -9
- package/lib/data/data1d/Spectrum1D/integrals/mapIntegrals.d.ts +0 -12
- package/lib/data/data1d/Spectrum1D/integrals/mapIntegrals.js +0 -36
- package/lib/data/data1d/Spectrum1D/integrals/updateIntegrals.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/integrals/updateIntegrals.js +0 -6
- package/lib/data/data1d/Spectrum1D/integrals/updateIntegralsRelativeValues.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/integrals/updateIntegralsRelativeValues.js +0 -5
- package/lib/data/data1d/Spectrum1D/integrals/updateRelatives.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/integrals/updateRelatives.js +0 -26
- package/lib/data/data1d/Spectrum1D/peaks/mapPeaks.d.ts +0 -3
- package/lib/data/data1d/Spectrum1D/peaks/mapPeaks.js +0 -45
- package/lib/data/data1d/Spectrum1D/peaks/updatePeaks.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/peaks/updatePeaks.js +0 -7
- package/lib/data/data1d/Spectrum1D/ranges/mapRanges.d.ts +0 -4
- package/lib/data/data1d/Spectrum1D/ranges/mapRanges.js +0 -78
- package/lib/data/data1d/Spectrum1D/ranges/updateRanges.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/ranges/updateRanges.js +0 -9
- package/lib/data/data1d/Spectrum1D/ranges/updateRangesRelativeValues.d.ts +0 -2
- package/lib/data/data1d/Spectrum1D/ranges/updateRangesRelativeValues.js +0 -5
- package/lib/data/data1d/filter1d/apodization.d.ts +0 -27
- package/lib/data/data1d/filter1d/apodization.js +0 -81
- package/lib/data/data1d/filter1d/baselineCorrection.d.ts +0 -33
- package/lib/data/data1d/filter1d/baselineCorrection.js +0 -51
- package/lib/data/data1d/filter1d/digitalFilter.d.ts +0 -20
- package/lib/data/data1d/filter1d/digitalFilter.js +0 -44
- package/lib/data/data1d/filter1d/equallySpaced.d.ts +0 -33
- package/lib/data/data1d/filter1d/equallySpaced.js +0 -52
- package/lib/data/data1d/filter1d/exclusionZones.d.ts +0 -15
- package/lib/data/data1d/filter1d/exclusionZones.js +0 -32
- package/lib/data/data1d/filter1d/fft.d.ts +0 -18
- package/lib/data/data1d/filter1d/fft.js +0 -90
- package/lib/data/data1d/filter1d/phaseCorrection.d.ts +0 -26
- package/lib/data/data1d/filter1d/phaseCorrection.js +0 -64
- package/lib/data/data1d/filter1d/shiftX.d.ts +0 -20
- package/lib/data/data1d/filter1d/shiftX.js +0 -26
- package/lib/data/data1d/filter1d/signalProcessing.d.ts +0 -26
- package/lib/data/data1d/filter1d/signalProcessing.js +0 -65
- package/lib/data/data1d/filter1d/utils/padDataToNextPowerOfTwo.d.ts +0 -2
- package/lib/data/data1d/filter1d/utils/padDataToNextPowerOfTwo.js +0 -35
- package/lib/data/data1d/filter1d/zeroFilling.d.ts +0 -22
- package/lib/data/data1d/filter1d/zeroFilling.js +0 -60
- package/lib/data/data2d/filter2d/shiftX.d.ts +0 -18
- package/lib/data/data2d/filter2d/shiftX.js +0 -27
- package/lib/data/data2d/filter2d/shiftY.d.ts +0 -18
- package/lib/data/data2d/filter2d/shiftY.js +0 -27
- package/lib/data/types/view-state/PeaksViewState.d.ts +0 -17
- package/lib/data/types/view-state/PeaksViewState.js +0 -1
- package/lib/types/NMRiumGeneralPreferences.d.ts +0 -7
- package/lib/types/NMRiumGeneralPreferences.js +0 -1
- package/lib/types/NMRiumPanelPreferences.d.ts +0 -17
- package/lib/types/NMRiumPanelPreferences.js +0 -1
- package/lib/types/NMRiumToolBarPreferences.d.ts +0 -22
- package/lib/types/NMRiumToolBarPreferences.js +0 -1
- package/lib/types/PanelPreferencesType.d.ts +0 -4
- package/lib/types/PanelPreferencesType.js +0 -1
- package/lib-cjs/component/panels/predictionPanel/PredictionOptions.js +0 -102
- package/lib-cjs/component/workspaces/Workspace.js +0 -2
- package/lib-cjs/data/Filters.js +0 -38
- package/lib-cjs/data/FiltersManager.js +0 -206
- package/lib-cjs/data/data1d/Spectrum1D/getShiftX.js +0 -33
- package/lib-cjs/data/data1d/Spectrum1D/getSpectrumErrorValue.js +0 -8
- package/lib-cjs/data/data1d/Spectrum1D/integrals/checkIntegralKind.js +0 -13
- package/lib-cjs/data/data1d/Spectrum1D/integrals/mapIntegrals.js +0 -40
- package/lib-cjs/data/data1d/Spectrum1D/integrals/updateIntegrals.js +0 -10
- package/lib-cjs/data/data1d/Spectrum1D/integrals/updateIntegralsRelativeValues.js +0 -9
- package/lib-cjs/data/data1d/Spectrum1D/integrals/updateRelatives.js +0 -30
- package/lib-cjs/data/data1d/Spectrum1D/peaks/mapPeaks.js +0 -49
- package/lib-cjs/data/data1d/Spectrum1D/peaks/updatePeaks.js +0 -11
- package/lib-cjs/data/data1d/Spectrum1D/ranges/mapRanges.js +0 -82
- package/lib-cjs/data/data1d/Spectrum1D/ranges/updateRanges.js +0 -13
- package/lib-cjs/data/data1d/Spectrum1D/ranges/updateRangesRelativeValues.js +0 -9
- package/lib-cjs/data/data1d/filter1d/apodization.js +0 -88
- package/lib-cjs/data/data1d/filter1d/baselineCorrection.js +0 -60
- package/lib-cjs/data/data1d/filter1d/digitalFilter.js +0 -50
- package/lib-cjs/data/data1d/filter1d/equallySpaced.js +0 -61
- package/lib-cjs/data/data1d/filter1d/exclusionZones.js +0 -38
- package/lib-cjs/data/data1d/filter1d/fft.js +0 -96
- package/lib-cjs/data/data1d/filter1d/phaseCorrection.js +0 -70
- package/lib-cjs/data/data1d/filter1d/shiftX.js +0 -32
- package/lib-cjs/data/data1d/filter1d/signalProcessing.js +0 -95
- package/lib-cjs/data/data1d/filter1d/utils/padDataToNextPowerOfTwo.js +0 -39
- package/lib-cjs/data/data1d/filter1d/zeroFilling.js +0 -66
- package/lib-cjs/data/data2d/filter2d/shiftX.js +0 -33
- package/lib-cjs/data/data2d/filter2d/shiftY.js +0 -33
- package/lib-cjs/data/types/view-state/PeaksViewState.js +0 -2
- package/lib-cjs/types/NMRiumGeneralPreferences.js +0 -2
- package/lib-cjs/types/NMRiumPanelPreferences.js +0 -2
- package/lib-cjs/types/NMRiumToolBarPreferences.js +0 -2
- package/lib-cjs/types/PanelPreferencesType.js +0 -2
|
@@ -1,24 +1,15 @@
|
|
|
1
|
-
import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
import { Formik } from 'formik';
|
|
3
|
-
import {
|
|
3
|
+
import { useImperativeHandle, useRef, forwardRef, useMemo } from 'react';
|
|
4
4
|
import { usePreferences } from '../../context/PreferencesContext';
|
|
5
5
|
import Label from '../../elements/Label';
|
|
6
|
+
import { formatFieldInputStyle, formatFieldLabelStyle, } from '../../elements/formik/FormikColumnFormatField';
|
|
6
7
|
import FormikInput from '../../elements/formik/FormikInput';
|
|
7
8
|
import useNucleus from '../../hooks/useNucleus';
|
|
8
9
|
import { usePanelPreferencesByNuclei } from '../../hooks/usePanelPreferences';
|
|
9
10
|
import { getUniqueNuclei } from '../../utility/getUniqueNuclei';
|
|
10
11
|
import { NucleusPreferences, } from '../extra/preferences/NucleusPreferences';
|
|
11
12
|
import { PreferencesContainer } from '../extra/preferences/PreferencesContainer';
|
|
12
|
-
const styles = {
|
|
13
|
-
inputLabel: {
|
|
14
|
-
flex: 2,
|
|
15
|
-
},
|
|
16
|
-
inputWrapper: {
|
|
17
|
-
width: '100px',
|
|
18
|
-
flex: '4',
|
|
19
|
-
borderRadius: '5px',
|
|
20
|
-
},
|
|
21
|
-
};
|
|
22
13
|
const formatFields = [
|
|
23
14
|
{
|
|
24
15
|
id: 1,
|
|
@@ -75,23 +66,17 @@ function RangesPreferences(props, ref) {
|
|
|
75
66
|
const nucleus = useNucleus();
|
|
76
67
|
const nuclei = useMemo(() => getUniqueNuclei(nucleus), [nucleus]);
|
|
77
68
|
const preferencesByNuclei = usePanelPreferencesByNuclei('ranges', nuclei);
|
|
78
|
-
|
|
79
|
-
formRef.current.setValues(preferencesByNuclei);
|
|
80
|
-
}, [preferencesByNuclei]);
|
|
81
|
-
const saveHandler = useCallback((values) => {
|
|
69
|
+
function saveHandler(values) {
|
|
82
70
|
preferences.dispatch({
|
|
83
71
|
type: 'SET_PANELS_PREFERENCES',
|
|
84
72
|
payload: { key: 'ranges', value: values },
|
|
85
73
|
});
|
|
86
|
-
}
|
|
74
|
+
}
|
|
87
75
|
useImperativeHandle(ref, () => ({
|
|
88
76
|
saveSetting: () => {
|
|
89
77
|
formRef.current.submitForm();
|
|
90
78
|
},
|
|
91
79
|
}), []);
|
|
92
|
-
return (_jsx(PreferencesContainer, { children: _jsx(Formik, { initialValues:
|
|
93
|
-
label: styles.inputLabel,
|
|
94
|
-
wrapper: styles.inputWrapper,
|
|
95
|
-
}, children: _jsx(FormikInput, { name: `nuclei.${n}.jGraphTolerance`, type: "number" }) })) }, n))) }) }) }));
|
|
80
|
+
return (_jsx(PreferencesContainer, { children: _jsx(Formik, { initialValues: preferencesByNuclei, enableReinitialize: true, onSubmit: saveHandler, innerRef: formRef, children: _jsx(_Fragment, { children: nuclei?.map((n) => (_jsx(NucleusPreferences, { nucleus: n, fields: formatFields, renderBottom: () => (_jsx(Label, { title: "J Graph tolerance (Hz) :", style: formatFieldLabelStyle, children: _jsxs("div", { style: { display: 'flex' }, children: [_jsx("div", { style: { width: '23px' } }), _jsx(FormikInput, { name: `nuclei.${n}.jGraphTolerance`, type: "number", style: formatFieldInputStyle })] }) })) }, n))) }) }) }));
|
|
96
81
|
}
|
|
97
|
-
export default
|
|
82
|
+
export default forwardRef(RangesPreferences);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { WorkSpacePanelPreferences } from 'nmr-load-save';
|
|
2
|
+
import { Info1D } from 'nmr-processing';
|
|
2
3
|
import { ContextMenuProps } from '../../elements/ReactTable/ReactTable';
|
|
3
|
-
import { WorkSpacePanelPreferences } from '../../workspaces/Workspace';
|
|
4
4
|
interface RangesTableProps extends ContextMenuProps {
|
|
5
5
|
onUnlink: (a: any, b?: any) => void;
|
|
6
6
|
preferences: WorkSpacePanelPreferences['ranges'];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { WorkSpacePanelPreferences } from 'nmr-load-save';
|
|
2
|
+
import { Info1D } from 'nmr-processing';
|
|
2
3
|
import { CSSProperties } from 'react';
|
|
3
4
|
import { ContextMenuProps } from '../../elements/ReactTable/ReactTable';
|
|
4
|
-
import { WorkSpacePanelPreferences } from '../../workspaces/Workspace';
|
|
5
5
|
import { RangeData } from './hooks/useMapRanges';
|
|
6
6
|
interface RangesTableRowProps extends ContextMenuProps {
|
|
7
7
|
rowData: any;
|
|
@@ -122,7 +122,11 @@ export function SpectraTable(props) {
|
|
|
122
122
|
maxWidth: '30px',
|
|
123
123
|
},
|
|
124
124
|
Cell: ({ row }) => {
|
|
125
|
-
|
|
125
|
+
const { display, info: { dimension, isFid }, } = row.original;
|
|
126
|
+
if (dimension === 2 && isFid) {
|
|
127
|
+
return _jsx("div", {});
|
|
128
|
+
}
|
|
129
|
+
return (_jsx(ColorIndicator, { display: display, dimension: dimension, onClick: (event) => onOpenSettingModal(event, row.original) }));
|
|
126
130
|
},
|
|
127
131
|
},
|
|
128
132
|
}), [onChangeVisibility, onOpenSettingModal]);
|
|
@@ -26,7 +26,10 @@ export function SpectraColumnsManager({ nucleus, onAdd, onDelete, datalist, mapO
|
|
|
26
26
|
{
|
|
27
27
|
Header: 'Label',
|
|
28
28
|
Cell: ({ row }) => {
|
|
29
|
-
return (_jsx(FormikInput, { name: `nuclei.${nucleus}.columns.${row.index}.label`, style: {
|
|
29
|
+
return (_jsx(FormikInput, { name: `nuclei.${nucleus}.columns.${row.index}.label`, style: {
|
|
30
|
+
input: { ...style, ...inputStyle },
|
|
31
|
+
inputWrapper: { border: 'none' },
|
|
32
|
+
} }));
|
|
30
33
|
},
|
|
31
34
|
},
|
|
32
35
|
{
|
|
@@ -36,7 +39,10 @@ export function SpectraColumnsManager({ nucleus, onAdd, onDelete, datalist, mapO
|
|
|
36
39
|
if (column?.name) {
|
|
37
40
|
return (_jsx("span", { style: style, children: column?.jpath?.join('.') || column.description }));
|
|
38
41
|
}
|
|
39
|
-
return (_jsx(FormikInput, { name: `nuclei.${nucleus}.columns.${row.index}.jpath`, style: {
|
|
42
|
+
return (_jsx(FormikInput, { name: `nuclei.${nucleus}.columns.${row.index}.jpath`, style: {
|
|
43
|
+
input: { ...style, ...inputStyle },
|
|
44
|
+
inputWrapper: { border: 'none' },
|
|
45
|
+
}, datalist: datalist, mapOnChangeValue: mapOnChangeValue, mapValue: mapValue }));
|
|
40
46
|
},
|
|
41
47
|
},
|
|
42
48
|
{
|
|
@@ -46,11 +52,11 @@ export function SpectraColumnsManager({ nucleus, onAdd, onDelete, datalist, mapO
|
|
|
46
52
|
},
|
|
47
53
|
{
|
|
48
54
|
Header: '',
|
|
49
|
-
style: { width: '
|
|
55
|
+
style: { width: '80px' },
|
|
50
56
|
id: 'add-button',
|
|
51
57
|
Cell: ({ row }) => {
|
|
52
58
|
const record = row.original;
|
|
53
|
-
return (_jsxs("div", { style: { display: 'flex' }, children: [_jsx(Button.Done, { fill: "outline", onClick: () => onAdd(nucleus, row.index + 1), children: _jsx(FaPlus, {}) }), !record?.name && (_jsx(Button.Danger, { fill: "outline", onClick: () => onDelete(nucleus, row.index), children: _jsx(FaTimes, {}) }))] }));
|
|
59
|
+
return (_jsxs("div", { style: { display: 'flex', justifyContent: 'space-between' }, children: [_jsx(Button.Done, { fill: "outline", onClick: () => onAdd(nucleus, row.index + 1), children: _jsx(FaPlus, {}) }), !record?.name && (_jsx(Button.Danger, { fill: "outline", onClick: () => onDelete(nucleus, row.index), children: _jsx(FaTimes, {}) }))] }));
|
|
54
60
|
},
|
|
55
61
|
},
|
|
56
62
|
], [datalist, mapOnChangeValue, mapValue, nucleus, onAdd, onDelete]);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare function processSnapPlot<T extends '1D' | '2D'>(dimension: T, data: T extends '1D' ?
|
|
1
|
+
import { NmrData2DFt, NmrData1D } from 'cheminfo-types';
|
|
2
|
+
export declare function processSnapPlot<T extends '1D' | '2D'>(dimension: T, data: T extends '1D' ? NmrData1D : NmrData2DFt['rr'], yLogBase: number): {
|
|
3
3
|
sanPlot: any;
|
|
4
4
|
lines: any;
|
|
5
5
|
};
|
|
@@ -77,7 +77,7 @@ function AdditionalColumnField({ rowCorrelation, columnCorrelation, commonLinks,
|
|
|
77
77
|
const contextMenu = useMemo(() => {
|
|
78
78
|
// allow the edition of correlations
|
|
79
79
|
const commonLinksMenu = commonLinks.flatMap((commonLink) => {
|
|
80
|
-
const commonLinkContextMenuLabel = `${getAbbreviation(commonLink)} (${commonLink.signal.x ? commonLink.signal.x.delta.toFixed(2) : '?'}, ${commonLink.signal.y ? commonLink.signal.y.delta.toFixed(2) : '?'})${commonLink.edited?.moved === true ? '[MOVED]' : ''}`;
|
|
80
|
+
const commonLinkContextMenuLabel = `${getAbbreviation(commonLink)} (${commonLink.signal.x?.delta ? commonLink.signal.x.delta.toFixed(2) : '?'}, ${commonLink.signal.y?.delta ? commonLink.signal.y.delta.toFixed(2) : '?'})${commonLink.edited?.moved === true ? '[MOVED]' : ''}`;
|
|
81
81
|
return commonLink.pseudo === false
|
|
82
82
|
? [
|
|
83
83
|
{
|
|
@@ -178,7 +178,7 @@ function CorrelationTableRow({ additionalColumnData, correlations, correlation,
|
|
|
178
178
|
}
|
|
179
179
|
}, children: [getLabel(correlations, correlation), _jsx(ContextMenu, { ref: contextRef, context: contextMenu })] }), _jsx("td", { title: t, ...otherTableDataProps, children: getCorrelationDelta(correlation)
|
|
180
180
|
? getCorrelationDelta(correlation)?.toFixed(2)
|
|
181
|
-
: '' }), _jsx("td", { title: t, ...otherTableDataProps, children: correlation.atomType !== 'H' ? (_jsx(EditableColumn, { type: "number", value: correlation.equivalence, style: equivalenceCellStyle, onSave: onSaveEquivalencesHandler })) : (_jsx("
|
|
181
|
+
: '' }), _jsx("td", { title: t, ...otherTableDataProps, children: correlation.atomType !== 'H' ? (_jsx(EditableColumn, { type: "number", value: correlation.equivalence, style: equivalenceCellStyle, onSave: onSaveEquivalencesHandler })) : (_jsx("span", { style: equivalenceCellStyle, children: correlation.equivalence })) }), _jsx("td", { title: t, ...otherTableDataProps, children: correlation.atomType !== 'H' ? (_jsx(EditableColumn, { type: "text", value: correlation.protonsCount.join(','), style: correlation.edited.protonsCount ? { color: 'blue' } : {}, onSave: (e) => onSaveEditNumericValuesHandler(e, 'protonsCount') })) : ('') }), _jsx("td", { title: t, ...otherTableDataProps,
|
|
182
182
|
style: { ...tableDataProps.style, borderRight: '1px solid' }, children: correlation.atomType !== 'H' ? (_jsx(EditableColumn, { type: "text", value: correlation.hybridization
|
|
183
183
|
.map((hybrid) => `sp${hybrid}`)
|
|
184
184
|
.join(','), style: correlation.edited.hybridization ? { color: 'blue' } : {}, onSave: (e) => onSaveEditNumericValuesHandler(e, 'hybridization') })) : ('') }), additionalColumnFields] }));
|
|
@@ -2,13 +2,14 @@ import { jsx as _jsx, jsxs as _jsxs } from "@emotion/react/jsx-runtime";
|
|
|
2
2
|
/** @jsxImportSource @emotion/react */
|
|
3
3
|
import { css } from '@emotion/react';
|
|
4
4
|
import { readFromWebSource, serializeNmriumState, } from 'nmr-load-save';
|
|
5
|
+
import { mapRanges } from 'nmr-processing';
|
|
5
6
|
import OCL from 'openchemlib/full';
|
|
6
7
|
import { useCallback, useState, useRef, memo, useEffect, useMemo } from 'react';
|
|
7
8
|
import { BsHexagon, BsHexagonFill } from 'react-icons/bs';
|
|
8
9
|
import { FaICursor } from 'react-icons/fa';
|
|
9
10
|
import { IoSearchOutline } from 'react-icons/io5';
|
|
10
11
|
import { useAccordionContext } from 'react-science/ui';
|
|
11
|
-
import { isSpectrum1D
|
|
12
|
+
import { isSpectrum1D } from '../../../data/data1d/Spectrum1D';
|
|
12
13
|
import { getSum } from '../../../data/data1d/Spectrum1D/SumManager';
|
|
13
14
|
import { initiateDatabase, prepareData, DATA_BASES, } from '../../../data/data1d/database';
|
|
14
15
|
import { useChartData } from '../../context/ChartContext';
|
|
@@ -35,24 +36,6 @@ import PreferencesHeader from '../header/PreferencesHeader';
|
|
|
35
36
|
import DatabasePreferences from './DatabasePreferences';
|
|
36
37
|
import { DatabaseStructureSearchModal } from './DatabaseStructureSearchModal';
|
|
37
38
|
import DatabaseTable from './DatabaseTable';
|
|
38
|
-
const style = css `
|
|
39
|
-
.header {
|
|
40
|
-
height: 30px;
|
|
41
|
-
padding: 2px 0 2px 5px;
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
.input-container {
|
|
45
|
-
width: 100%;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
.search-input {
|
|
49
|
-
width: 100% !important;
|
|
50
|
-
border-radius: 5px;
|
|
51
|
-
border: 0.55px solid gray;
|
|
52
|
-
padding: 0 5px;
|
|
53
|
-
outline: none;
|
|
54
|
-
}
|
|
55
|
-
`;
|
|
56
39
|
const emptyKeywords = {
|
|
57
40
|
solvent: '-1',
|
|
58
41
|
searchKeywords: '',
|
|
@@ -151,8 +134,7 @@ function DatabasePanelInner({ nucleus, selectedTool, databases, defaultDatabase,
|
|
|
151
134
|
baseURL: url,
|
|
152
135
|
})));
|
|
153
136
|
}
|
|
154
|
-
catch
|
|
155
|
-
reportError(error);
|
|
137
|
+
catch {
|
|
156
138
|
alert.error(`Failed to load ${url}`);
|
|
157
139
|
}
|
|
158
140
|
finally {
|
|
@@ -188,14 +170,15 @@ function DatabasePanelInner({ nucleus, selectedTool, databases, defaultDatabase,
|
|
|
188
170
|
return prepareData(result.data);
|
|
189
171
|
}, [result.data]);
|
|
190
172
|
const resurrectHandler = useCallback((rowData) => {
|
|
191
|
-
|
|
173
|
+
let { index, baseURL, jcampURL: jcampRelativeURL } = rowData;
|
|
192
174
|
const { ranges, solvent, names = [] } = result.data[index];
|
|
193
175
|
if (jcampRelativeURL) {
|
|
176
|
+
const url = new URL(jcampRelativeURL, baseURL);
|
|
194
177
|
setTimeout(async () => {
|
|
195
178
|
const hideLoading = await alert.showLoading(`load jcamp in progress...`);
|
|
196
179
|
try {
|
|
197
180
|
const { data } = await readFromWebSource({
|
|
198
|
-
entries: [{ baseURL, relativePath:
|
|
181
|
+
entries: [{ baseURL: url.origin, relativePath: url.pathname }],
|
|
199
182
|
});
|
|
200
183
|
const spectrum = data?.spectra?.[0] || null;
|
|
201
184
|
if (spectrum && isSpectrum1D(spectrum)) {
|
|
@@ -265,7 +248,6 @@ function DatabasePanelInner({ nucleus, selectedTool, databases, defaultDatabase,
|
|
|
265
248
|
};
|
|
266
249
|
return (_jsxs("div", { css: [
|
|
267
250
|
tablePanelStyle,
|
|
268
|
-
style,
|
|
269
251
|
isFlipped &&
|
|
270
252
|
css `
|
|
271
253
|
.table-container {
|
|
@@ -275,11 +257,11 @@ function DatabasePanelInner({ nucleus, selectedTool, databases, defaultDatabase,
|
|
|
275
257
|
}
|
|
276
258
|
}
|
|
277
259
|
`,
|
|
278
|
-
], children: [!isFlipped && (_jsxs(DefaultPanelHeader, { showSettingButton: true, onSettingClick: settingsPanelHandler, canDelete: false,
|
|
260
|
+
], children: [!isFlipped && (_jsxs(DefaultPanelHeader, { showSettingButton: true, onSettingClick: settingsPanelHandler, canDelete: false, children: [_jsx(ToggleButton, { defaultValue: selectedTool === options.databaseRangesSelection.id, popupTitle: "Filter by select ranges", popupPlacement: "right", onClick: enableFilterHandler, children: _jsx(FaICursor, { style: {
|
|
279
261
|
pointerEvents: 'none',
|
|
280
262
|
fontSize: '12px',
|
|
281
263
|
transform: 'rotate(90deg)',
|
|
282
|
-
} }) }, `${selectedTool}`), _jsx(Select, { style: { flex: 2 }, items: databases, itemTextField: "label", itemValueField: "key", onChange: handleChangeDatabase, placeholder: "Select database", defaultValue: defaultDatabase }), _jsx(Select, { style: { flex: 1 }, items: result.solvents, placeholder: "Solvent", onChange: handleSearch, value: keywords.solvent }), _jsx(Input, { value: keywords.searchKeywords, renderIcon: () => _jsx(IoSearchOutline, {}), style: { inputWrapper: { flex: 3 } }, className: "search-input", type: "text", debounceTime: 250, placeholder: "Search for parameter...", onChange: handleSearch, onClear: clearHandler, canClear: true }), _jsx(Button.Done, { fill: "clear", onClick: openSearchByStructure, style: { marginLeft: '5px' }, children: !idCode ? (_jsx(BsHexagon, { style: {
|
|
264
|
+
} }) }, `${selectedTool}`), _jsx(Select, { style: { flex: 2, marginLeft: '5px' }, items: databases, itemTextField: "label", itemValueField: "key", onChange: handleChangeDatabase, placeholder: "Select database", defaultValue: defaultDatabase }), _jsx(Select, { style: { flex: 1, margin: '0px 5px' }, items: result.solvents, placeholder: "Solvent", onChange: handleSearch, value: keywords.solvent }), _jsx(Input, { value: keywords.searchKeywords, renderIcon: () => _jsx(IoSearchOutline, {}), style: { inputWrapper: { flex: 3 } }, className: "search-input", type: "text", debounceTime: 250, placeholder: "Search for parameter...", onChange: handleSearch, onClear: clearHandler, canClear: true }), _jsx(Button.Done, { fill: "clear", onClick: openSearchByStructure, style: { marginLeft: '5px' }, children: !idCode ? (_jsx(BsHexagon, { style: {
|
|
283
265
|
fontSize: '14px',
|
|
284
266
|
} })) : (_jsx(BsHexagonFill, { style: {
|
|
285
267
|
fontSize: '14px',
|
|
@@ -309,10 +291,11 @@ function mapSolventsToSelect(solvents) {
|
|
|
309
291
|
return result;
|
|
310
292
|
}
|
|
311
293
|
async function saveJcampAsJson(rowData, filteredData) {
|
|
312
|
-
const { index, baseURL, jcampURL
|
|
294
|
+
const { index, baseURL, jcampURL, names, ocl = {}, smiles } = rowData;
|
|
313
295
|
const { ranges } = filteredData.data[index];
|
|
296
|
+
const url = new URL(jcampURL, baseURL);
|
|
314
297
|
const { data: { spectra, source } = { source: {}, spectra: [] }, version } = await readFromWebSource({
|
|
315
|
-
entries: [{ baseURL, relativePath:
|
|
298
|
+
entries: [{ baseURL: url.origin, relativePath: url.pathname }],
|
|
316
299
|
});
|
|
317
300
|
let molfile = '';
|
|
318
301
|
let molecule = null;
|
|
@@ -4,7 +4,7 @@ import { useEffect, useCallback, useImperativeHandle, useRef, forwardRef, } from
|
|
|
4
4
|
import { usePreferences } from '../../context/PreferencesContext';
|
|
5
5
|
import Label from '../../elements/Label';
|
|
6
6
|
import FormikColorInput from '../../elements/formik/FormikColorInput';
|
|
7
|
-
import FormikColumnFormatField from '../../elements/formik/FormikColumnFormatField';
|
|
7
|
+
import FormikColumnFormatField, { formatFieldInputStyle, formatFieldLabelStyle, } from '../../elements/formik/FormikColumnFormatField';
|
|
8
8
|
import FormikInput from '../../elements/formik/FormikInput';
|
|
9
9
|
import { usePanelPreferences } from '../../hooks/usePanelPreferences';
|
|
10
10
|
import { PreferencesContainer } from '../extra/preferences/PreferencesContainer';
|
|
@@ -27,6 +27,6 @@ function DatabasePreferences(props, ref) {
|
|
|
27
27
|
formRef.current.submitForm();
|
|
28
28
|
},
|
|
29
29
|
}));
|
|
30
|
-
return (_jsx(PreferencesContainer, { children: _jsx(Formik, { initialValues: {}, onSubmit: saveHandler, innerRef: formRef, children: _jsxs(_Fragment, { children: [_jsxs(PreferencesGroup, { children: [_jsx(FormikColumnFormatField, { label: "Preview jcamp", checkControllerName: "previewJcamp", hideFormatField: true }), _jsx(FormikColorInput, { name: "color" }), _jsx(Label, { title: "Margin bottom (px) :", style:
|
|
30
|
+
return (_jsx(PreferencesContainer, { children: _jsx(Formik, { initialValues: {}, onSubmit: saveHandler, innerRef: formRef, children: _jsxs(_Fragment, { children: [_jsxs(PreferencesGroup, { children: [_jsx(FormikColumnFormatField, { label: "Preview jcamp", checkControllerName: "previewJcamp", hideFormatField: true }), _jsx(Label, { title: "Color", style: formatFieldLabelStyle, children: _jsx(FormikColorInput, { name: "color" }) }), _jsx(Label, { title: "Margin bottom (px) :", style: formatFieldLabelStyle, children: _jsx(FormikInput, { name: "marginBottom", type: "number", style: formatFieldInputStyle }) })] }), _jsxs(PreferencesGroup, { header: "Table Preferences", children: [_jsx(FormikColumnFormatField, { label: "Structure", checkControllerName: "showSmiles", hideFormatField: true }), _jsx(FormikColumnFormatField, { label: "Solvent", checkControllerName: "showSolvent", hideFormatField: true }), _jsx(FormikColumnFormatField, { label: "Names", checkControllerName: "showNames", hideFormatField: true }), _jsx(FormikColumnFormatField, { label: "Range", checkControllerName: "range.show", formatControllerName: "range.format" }), _jsx(FormikColumnFormatField, { label: "\u03B4 (ppm)", checkControllerName: "delta.show", formatControllerName: "delta.format" }), _jsx(FormikColumnFormatField, { label: "Assignment", checkControllerName: "showAssignment", hideFormatField: true }), _jsx(FormikColumnFormatField, { label: "J (Hz)", checkControllerName: "coupling.show", formatControllerName: "coupling.format" }), _jsx(FormikColumnFormatField, { label: "Multiplicity", checkControllerName: "showMultiplicity", hideFormatField: true }), _jsx(FormikColumnFormatField, { label: "Save as nmrium", checkControllerName: "allowSaveAsNMRium", hideFormatField: true })] })] }) }) }));
|
|
31
31
|
}
|
|
32
32
|
export default forwardRef(DatabasePreferences);
|
|
@@ -17,6 +17,5 @@ interface DefaultPanelHeaderProps {
|
|
|
17
17
|
className?: string;
|
|
18
18
|
renderRightButtons?: () => ReactNode;
|
|
19
19
|
}
|
|
20
|
-
declare function DefaultPanelHeader({ counter, onDelete, deleteToolTip, onFilter, filterToolTip, filterIsActive, counterFiltered, children, onSettingClick, showSettingButton, canDelete, disableDelete, style, className, renderRightButtons, }: DefaultPanelHeaderProps): import("
|
|
21
|
-
|
|
22
|
-
export default _default;
|
|
20
|
+
declare function DefaultPanelHeader({ counter, onDelete, deleteToolTip, onFilter, filterToolTip, filterIsActive, counterFiltered, children, onSettingClick, showSettingButton, canDelete, disableDelete, style, className, renderRightButtons, }: DefaultPanelHeaderProps): import("react/jsx-runtime").JSX.Element;
|
|
21
|
+
export default DefaultPanelHeader;
|
|
@@ -1,34 +1,26 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "
|
|
2
|
-
/** @jsxImportSource @emotion/react */
|
|
3
|
-
import { css } from '@emotion/react';
|
|
4
|
-
import { memo } from 'react';
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
5
2
|
import { FaRegTrashAlt, FaCog, FaFilter } from 'react-icons/fa';
|
|
6
3
|
import Button from '../../elements/Button';
|
|
7
4
|
import ToggleButton from '../../elements/ToggleButton';
|
|
8
5
|
import ToolTip from '../../elements/ToolTip/ToolTip';
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
line-height: 22px;
|
|
25
|
-
padding: 0 10px;
|
|
26
|
-
white-space: nowrap;
|
|
27
|
-
}
|
|
28
|
-
`;
|
|
6
|
+
import PanelHeader from './PanelHeader';
|
|
7
|
+
const styles = {
|
|
8
|
+
leftContainer: {
|
|
9
|
+
display: 'flex',
|
|
10
|
+
flexDirection: 'row',
|
|
11
|
+
flex: 1,
|
|
12
|
+
},
|
|
13
|
+
counterLabel: {
|
|
14
|
+
margin: 0,
|
|
15
|
+
textAlign: 'right',
|
|
16
|
+
lineHeight: '22px',
|
|
17
|
+
padding: '0 10px',
|
|
18
|
+
whiteSpace: 'nowrap',
|
|
19
|
+
},
|
|
20
|
+
};
|
|
29
21
|
function DefaultPanelHeader({ counter, onDelete = () => null, deleteToolTip = 'Delete', onFilter = () => null, filterToolTip = '', filterIsActive = false, counterFiltered = 0, children, onSettingClick = () => null, showSettingButton = false, canDelete = true, disableDelete = false, style = {}, className = '', renderRightButtons, }) {
|
|
30
|
-
return (_jsxs(
|
|
22
|
+
return (_jsxs(PanelHeader, { style, className, children: [_jsxs("div", { style: styles.leftContainer, children: [canDelete && (_jsx(Button.BarButton, { color: { base: 'black', hover: 'red' }, onClick: onDelete, disabled: counter === 0 || disableDelete, toolTip: deleteToolTip, tooltipOrientation: "horizontal", children: _jsx(FaRegTrashAlt, {}) })), filterToolTip ? (_jsx(ToggleButton, { popupTitle: filterToolTip, popupPlacement: "right", onClick: onFilter, defaultValue: filterIsActive, children: _jsx(FaFilter, { style: { pointerEvents: 'none', fontSize: '12px' } }) })) : null, children] }), renderRightButtons?.(), counter !== undefined && (_jsxs("p", { style: styles.counterLabel, children: ["[", ' ', filterIsActive && counterFiltered !== undefined
|
|
31
23
|
? `${counterFiltered}/${counter}`
|
|
32
24
|
: counter, ' ', "]"] })), showSettingButton && (_jsx(ToolTip, { title: "Preferences", popupPlacement: "left", children: _jsx("button", { type: "button", onClick: onSettingClick, children: _jsx(FaCog, {}) }) }))] }));
|
|
33
25
|
}
|
|
34
|
-
export default
|
|
26
|
+
export default DefaultPanelHeader;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
const containerStyle = {
|
|
3
|
+
display: 'flex',
|
|
4
|
+
flexDirection: 'row',
|
|
5
|
+
borderBottom: '0.55px solid rgb(240 240 240)',
|
|
6
|
+
padding: '2px 5px',
|
|
7
|
+
alignItems: 'center',
|
|
8
|
+
};
|
|
9
|
+
export default function PanelHeader(props) {
|
|
10
|
+
const { style = {}, children } = props;
|
|
11
|
+
return _jsxs("div", { style: { ...containerStyle, ...style }, children: [children, " "] });
|
|
12
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { FormikConfig } from 'formik';
|
|
3
|
+
import { PredictionOptions } from '../../../data/PredictionManager';
|
|
4
|
+
interface PredictionOptionsPanelProps extends Pick<FormikConfig<any>, 'onSubmit'> {
|
|
5
|
+
options: PredictionOptions;
|
|
6
|
+
hideName?: boolean;
|
|
7
|
+
}
|
|
8
|
+
declare const _default: import("react").ForwardRefExoticComponent<PredictionOptionsPanelProps & import("react").RefAttributes<unknown>>;
|
|
9
|
+
export default _default;
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { Formik } from 'formik';
|
|
3
|
+
import { forwardRef } from 'react';
|
|
4
|
+
import * as Yup from 'yup';
|
|
5
|
+
import { FREQUENCIES, } from '../../../data/PredictionManager';
|
|
6
|
+
import generateNumbersPowerOfX from '../../../data/utilities/generateNumbersPowerOfX';
|
|
7
|
+
import { GroupPane } from '../../elements/GroupPane';
|
|
8
|
+
import IsotopesViewer from '../../elements/IsotopesViewer';
|
|
9
|
+
import Label from '../../elements/Label';
|
|
10
|
+
import FormikCheckBox from '../../elements/formik/FormikCheckBox';
|
|
11
|
+
import FormikErrorsSummary from '../../elements/formik/FormikErrorsSummary';
|
|
12
|
+
import FormikInput from '../../elements/formik/FormikInput';
|
|
13
|
+
import FormikSelect from '../../elements/formik/FormikSelect';
|
|
14
|
+
const NUMBER_OF_POINTS_1D = generateNumbersPowerOfX(12, 19);
|
|
15
|
+
const NUMBER_OF_POINTS_2D = generateNumbersPowerOfX(10, 10, {
|
|
16
|
+
format: (value) => value,
|
|
17
|
+
});
|
|
18
|
+
const predictionFormValidation = Yup.object().shape({
|
|
19
|
+
name: Yup.string().label('Name'),
|
|
20
|
+
frequency: Yup.number().integer().required().label('Frequency'),
|
|
21
|
+
'1d': Yup.object({
|
|
22
|
+
'1H': Yup.object({
|
|
23
|
+
from: Yup.number().required().label("1H ' From ' "),
|
|
24
|
+
to: Yup.number().required().label("1H ' To ' "),
|
|
25
|
+
}),
|
|
26
|
+
'13C': Yup.object().shape({
|
|
27
|
+
from: Yup.number().required().label("13C ' From ' "),
|
|
28
|
+
to: Yup.number().required().label("13C ' To ' "),
|
|
29
|
+
}),
|
|
30
|
+
lineWidth: Yup.number().integer().min(1).required().label('Line Width'),
|
|
31
|
+
nbPoints: Yup.number().integer().required().label('1D Number Of Points'),
|
|
32
|
+
}),
|
|
33
|
+
'2d': Yup.object({
|
|
34
|
+
nbPoints: Yup.object({
|
|
35
|
+
x: Yup.number().integer().required().label('2D Number Of Points'),
|
|
36
|
+
y: Yup.number().integer().required().label('2D Number Of Points'),
|
|
37
|
+
}),
|
|
38
|
+
}),
|
|
39
|
+
spectra: Yup.object({
|
|
40
|
+
proton: Yup.boolean(),
|
|
41
|
+
carbon: Yup.boolean(),
|
|
42
|
+
cosy: Yup.boolean(),
|
|
43
|
+
hsqc: Yup.boolean(),
|
|
44
|
+
hmbc: Yup.boolean(),
|
|
45
|
+
}).test('check-options', 'You must check one of the options to start prediction', (obj) => {
|
|
46
|
+
if (Object.values(obj).includes(true)) {
|
|
47
|
+
return true;
|
|
48
|
+
}
|
|
49
|
+
return false;
|
|
50
|
+
}),
|
|
51
|
+
});
|
|
52
|
+
const labelStyle = {
|
|
53
|
+
label: { flex: 4, fontWeight: '500' },
|
|
54
|
+
wrapper: { flex: 8, display: 'flex', alignItems: 'center' },
|
|
55
|
+
container: { padding: '5px 0' },
|
|
56
|
+
};
|
|
57
|
+
const inputStyle = {
|
|
58
|
+
input: {
|
|
59
|
+
padding: '5px',
|
|
60
|
+
},
|
|
61
|
+
};
|
|
62
|
+
const styles = {
|
|
63
|
+
select: {
|
|
64
|
+
width: '100%',
|
|
65
|
+
minWidth: '100px',
|
|
66
|
+
maxWidth: '280px',
|
|
67
|
+
height: 30,
|
|
68
|
+
margin: 0,
|
|
69
|
+
},
|
|
70
|
+
groupHeader: {
|
|
71
|
+
borderBottom: '1px solid #efefef',
|
|
72
|
+
paddingBottom: '5px',
|
|
73
|
+
fontWeight: '600',
|
|
74
|
+
color: '#005d9e',
|
|
75
|
+
},
|
|
76
|
+
};
|
|
77
|
+
function PredictionOptionsPanel(props, ref) {
|
|
78
|
+
const { options, onSubmit, hideName = false } = props;
|
|
79
|
+
return (_jsx(Formik, { initialValues: options, validationSchema: predictionFormValidation, enableReinitialize: true, onSubmit: onSubmit, innerRef: ref, children: _jsxs(_Fragment, { children: [_jsx(FormikErrorsSummary, {}), !hideName && (_jsx(Label, { title: "Name", style: labelStyle, children: _jsx(FormikInput, { name: "name", style: inputStyle }) })), _jsx(Label, { title: "Frequency", style: labelStyle, children: _jsx(FormikSelect, { items: FREQUENCIES, style: styles.select, name: "frequency" }) }), _jsxs(GroupPane, { text: "1D Options", style: {
|
|
80
|
+
header: styles.groupHeader,
|
|
81
|
+
}, children: [_jsxs(Label, { title: "1H", renderTitle: (title) => (_jsx(IsotopesViewer, { value: title, className: "custom-label" })), style: labelStyle, children: [_jsx(Label, { title: "From", children: _jsx(FormikInput, { name: "1d.1H.from", type: "number", style: inputStyle }) }), _jsx(Label, { title: "To", style: { label: { padding: '0 10px' } }, children: _jsx(FormikInput, { name: "1d.1H.to", type: "number", style: inputStyle }) })] }), _jsxs(Label, { title: "13C", renderTitle: (title) => (_jsx(IsotopesViewer, { value: title, className: "custom-label" })), style: labelStyle, children: [_jsx(Label, { title: "From", children: _jsx(FormikInput, { name: "1d.13C.from", type: "number", style: inputStyle }) }), _jsx(Label, { title: "To", style: { label: { padding: '0 10px' } }, children: _jsx(FormikInput, { name: "1d.13C.to", type: "number", style: inputStyle }) })] }), _jsxs(Label, { title: "Line Width", style: labelStyle, children: [_jsx(FormikInput, { name: "1d.lineWidth", type: "number", style: inputStyle }), _jsx("span", { style: { paddingLeft: '0.4rem' }, children: " Hz " })] }), _jsx(Label, { title: "Number of Points", style: labelStyle, children: _jsx(FormikSelect, { items: NUMBER_OF_POINTS_1D, name: "1d.nbPoints", style: styles.select }) })] }), _jsx(GroupPane, { text: "2D Options", style: {
|
|
82
|
+
header: styles.groupHeader,
|
|
83
|
+
}, children: _jsxs(Label, { title: "Number of Points", style: labelStyle, children: [_jsx(FormikSelect, { items: NUMBER_OF_POINTS_2D, name: "2d.nbPoints.x", style: { margin: 0, height: 30 } }), _jsx("span", { style: { padding: '0 10px' }, children: " X " }), _jsx(FormikSelect, { items: NUMBER_OF_POINTS_2D, name: "2d.nbPoints.y", style: { margin: 0, height: 30 } })] }) }), _jsx(GroupPane, { text: "Spectra", style: {
|
|
84
|
+
header: styles.groupHeader,
|
|
85
|
+
}, children: _jsxs("div", { style: { display: 'flex', justifyContent: 'space-around' }, children: [_jsx(IsotopesOption, { title: "1H", name: "spectra.proton" }), _jsx(IsotopesOption, { title: "13C", name: "spectra.carbon" }), _jsx(IsotopesOption, { title: "COSY", name: "spectra.cosy" }), _jsx(IsotopesOption, { title: "HSQC", name: "spectra.hsqc" }), _jsx(IsotopesOption, { title: "HMBC", name: "spectra.hmbc" })] }) })] }) }));
|
|
86
|
+
}
|
|
87
|
+
function IsotopesOption(props) {
|
|
88
|
+
const { name, title } = props;
|
|
89
|
+
return (_jsx(FormikCheckBox, { name: name, style: {
|
|
90
|
+
checkbox: { display: 'flex' },
|
|
91
|
+
container: { flexDirection: 'row-reverse', padding: '0 5px' },
|
|
92
|
+
}, renderLabel: () => (_jsx("label", { htmlFor: name, children: _jsx(IsotopesViewer, { value: title, style: { padding: '0 5px' } }) })) }));
|
|
93
|
+
}
|
|
94
|
+
export default forwardRef(PredictionOptionsPanel);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export default function
|
|
1
|
+
export default function PredictionPanel(): import("@emotion/react/jsx-runtime").JSX.Element;
|