nmrium 2.2.0 → 2.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/component/1d/PredictionErrorsNotations.js +3 -3
- package/lib/component/1d/PredictionErrorsNotations.js.map +1 -1
- package/lib/component/1d/peaks/Peaks.d.ts.map +1 -1
- package/lib/component/1d/peaks/Peaks.js +2 -1
- package/lib/component/1d/peaks/Peaks.js.map +1 -1
- package/lib/component/1d/peaks/usePeakShapesPath.d.ts.map +1 -1
- package/lib/component/1d/peaks/usePeakShapesPath.js.map +1 -1
- package/lib/component/1d/ranges/AssignmentLabel.js +1 -1
- package/lib/component/1d/ranges/AssignmentLabel.js.map +1 -1
- package/lib/component/1d/ranges/FloatingRangeTablePreferencesModal.d.ts +9 -0
- package/lib/component/1d/ranges/FloatingRangeTablePreferencesModal.d.ts.map +1 -0
- package/lib/component/1d/ranges/FloatingRangeTablePreferencesModal.js +138 -0
- package/lib/component/1d/ranges/FloatingRangeTablePreferencesModal.js.map +1 -0
- package/lib/component/1d/ranges/FloatingRanges.d.ts.map +1 -0
- package/lib/component/1d/ranges/FloatingRanges.js +362 -0
- package/lib/component/1d/ranges/FloatingRanges.js.map +1 -0
- package/lib/component/1d/ranges/Ranges.js +2 -2
- package/lib/component/1d/ranges/Ranges.js.map +1 -1
- package/lib/component/1d-2d/FieldEdition.d.ts +2 -2
- package/lib/component/1d-2d/FieldEdition.d.ts.map +1 -1
- package/lib/component/1d-2d/FieldEdition.js +2 -2
- package/lib/component/1d-2d/FieldEdition.js.map +1 -1
- package/lib/component/1d-2d/components/FloatMoleculeStructures/DraggableStructure.js +7 -7
- package/lib/component/1d-2d/components/FloatMoleculeStructures/DraggableStructure.js.map +1 -1
- package/lib/component/2d/zones/SignalsGuideLines.js +1 -1
- 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.map +1 -1
- package/lib/component/EventsTrackers/BrushTracker.js.map +1 -1
- package/lib/component/SVGTable.d.ts +5 -3
- package/lib/component/SVGTable.d.ts.map +1 -1
- package/lib/component/SVGTable.js +16 -16
- package/lib/component/SVGTable.js.map +1 -1
- package/lib/component/context/KeyModifierContext.d.ts.map +1 -1
- package/lib/component/context/KeyModifierContext.js.map +1 -1
- package/lib/component/context/LoggerContext.d.ts.map +1 -1
- package/lib/component/context/LoggerContext.js.map +1 -1
- package/lib/component/context/SortSpectraContext.d.ts.map +1 -1
- package/lib/component/context/SortSpectraContext.js.map +1 -1
- package/lib/component/elements/ActionsButtonsPopover.d.ts +2 -2
- package/lib/component/elements/ActionsButtonsPopover.d.ts.map +1 -1
- package/lib/component/elements/ActionsButtonsPopover.js +6 -9
- package/lib/component/elements/ActionsButtonsPopover.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/Sections.d.ts.map +1 -1
- package/lib/component/elements/Sections.js.map +1 -1
- package/lib/component/elements/TabTitle.d.ts.map +1 -1
- package/lib/component/elements/TabTitle.js +2 -2
- package/lib/component/elements/TabTitle.js.map +1 -1
- package/lib/component/elements/ToolbarPopoverItem.d.ts +1 -0
- package/lib/component/elements/ToolbarPopoverItem.d.ts.map +1 -1
- package/lib/component/elements/ToolbarPopoverItem.js +10 -3
- package/lib/component/elements/ToolbarPopoverItem.js.map +1 -1
- package/lib/component/elements/dropDownButton/DropDownButton.d.ts.map +1 -1
- package/lib/component/elements/dropDownButton/DropDownButton.js +2 -2
- package/lib/component/elements/dropDownButton/DropDownButton.js.map +1 -1
- package/lib/component/elements/export/ExportOptionsModal.d.ts +1 -1
- package/lib/component/elements/export/ExportOptionsModal.d.ts.map +1 -1
- package/lib/component/elements/export/ExportOptionsModal.js +31 -110
- package/lib/component/elements/export/ExportOptionsModal.js.map +1 -1
- package/lib/component/elements/export/units.d.ts +0 -28
- package/lib/component/elements/export/units.d.ts.map +1 -1
- package/lib/component/elements/export/units.js +0 -5
- package/lib/component/elements/export/units.js.map +1 -1
- package/lib/component/elements/export/utilities/getExportOptions.d.ts.map +1 -1
- package/lib/component/elements/export/utilities/getExportOptions.js.map +1 -1
- package/lib/component/elements/print/pageSize.d.ts +1 -1
- package/lib/component/elements/print/pageSize.d.ts.map +1 -1
- package/lib/component/hooks/useExport.d.ts.map +1 -1
- package/lib/component/hooks/useExport.js.map +1 -1
- package/lib/component/hooks/usePanelPreferences.d.ts +3 -3
- package/lib/component/hooks/usePanelPreferences.d.ts.map +1 -1
- package/lib/component/hooks/useTextMetrics.d.ts.map +1 -1
- package/lib/component/hooks/useTextMetrics.js +1 -0
- package/lib/component/hooks/useTextMetrics.js.map +1 -1
- package/lib/component/main/NMRiumViewer.js +1 -1
- package/lib/component/main/NMRiumViewer.js.map +1 -1
- package/lib/component/modal/EditPeakShapeModal.js +2 -2
- package/lib/component/modal/EditPeakShapeModal.js.map +1 -1
- package/lib/component/modal/SaveAsModal.d.ts +2 -2
- package/lib/component/modal/SaveAsModal.d.ts.map +1 -1
- package/lib/component/modal/SaveAsModal.js +43 -35
- package/lib/component/modal/SaveAsModal.js.map +1 -1
- package/lib/component/modal/editRange/EditRangeModal.js +4 -3
- package/lib/component/modal/editRange/EditRangeModal.js.map +1 -1
- package/lib/component/modal/editRange/forms/components/NewSignalTab.js +2 -2
- package/lib/component/modal/editRange/forms/components/NewSignalTab.js.map +1 -1
- package/lib/component/modal/setting/tanstack_general_settings/errors/context.d.ts +5 -5
- package/lib/component/modal/setting/tanstack_general_settings/errors/context.js +3 -3
- package/lib/component/modal/setting/tanstack_general_settings/errors/context.js.map +1 -1
- package/lib/component/modal/setting/tanstack_general_settings/errors/renderer.d.ts +5 -5
- package/lib/component/modal/setting/tanstack_general_settings/errors/renderer.js +2 -2
- package/lib/component/modal/setting/tanstack_general_settings/errors/renderer.js.map +1 -1
- package/lib/component/modal/setting/tanstack_general_settings/general_settings_dialog_body.d.ts +5 -5
- package/lib/component/modal/setting/tanstack_general_settings/general_settings_dialog_body.js +2 -2
- package/lib/component/modal/setting/tanstack_general_settings/general_settings_dialog_body.js.map +1 -1
- package/lib/component/modal/setting/tanstack_general_settings/general_settings_dialog_header.d.ts +5 -5
- package/lib/component/modal/setting/tanstack_general_settings/general_settings_dialog_header.js +2 -2
- package/lib/component/modal/setting/tanstack_general_settings/general_settings_dialog_header.js.map +1 -1
- package/lib/component/modal/setting/tanstack_general_settings/tabs/auto_processing_tab.d.ts +5 -5
- package/lib/component/modal/setting/tanstack_general_settings/tabs/auto_processing_tab.js +2 -2
- package/lib/component/modal/setting/tanstack_general_settings/tabs/auto_processing_tab.js.map +1 -1
- package/lib/component/modal/setting/tanstack_general_settings/tabs/export_tab.fields.d.ts +14 -14
- package/lib/component/modal/setting/tanstack_general_settings/tabs/export_tab.fields.js +2 -2
- package/lib/component/modal/setting/tanstack_general_settings/tabs/export_tab.fields.js.map +1 -1
- package/lib/component/modal/setting/tanstack_general_settings/tabs/spectra_label_tab.d.ts.map +1 -1
- package/lib/component/modal/setting/tanstack_general_settings/tabs/spectra_label_tab.js +3 -2
- package/lib/component/modal/setting/tanstack_general_settings/tabs/spectra_label_tab.js.map +1 -1
- package/lib/component/modal/setting/tanstack_general_settings/tabs/title_block_tab.d.ts.map +1 -1
- package/lib/component/modal/setting/tanstack_general_settings/tabs/title_block_tab.js +3 -2
- package/lib/component/modal/setting/tanstack_general_settings/tabs/title_block_tab.js.map +1 -1
- package/lib/component/panels/MoleculesPanel/MoleculePanelHeader.d.ts.map +1 -1
- package/lib/component/panels/MoleculesPanel/MoleculePanelHeader.js +30 -3
- package/lib/component/panels/MoleculesPanel/MoleculePanelHeader.js.map +1 -1
- package/lib/component/panels/PeaksPanel/PeaksPreferences.js +18 -18
- package/lib/component/panels/PeaksPanel/PeaksPreferences.js.map +1 -1
- package/lib/component/panels/PeaksPanel/PeaksTable.js +11 -11
- package/lib/component/panels/PeaksPanel/PeaksTable.js.map +1 -1
- package/lib/component/panels/RangesPanel/RangesHeader.d.ts.map +1 -1
- package/lib/component/panels/RangesPanel/RangesHeader.js.map +1 -1
- package/lib/component/panels/RangesPanel/RangesPreferences.js +22 -22
- package/lib/component/panels/RangesPanel/RangesPreferences.js.map +1 -1
- package/lib/component/panels/RangesPanel/RangesTable.d.ts +2 -2
- package/lib/component/panels/RangesPanel/RangesTable.d.ts.map +1 -1
- package/lib/component/panels/RangesPanel/RangesTable.js +5 -4
- package/lib/component/panels/RangesPanel/RangesTable.js.map +1 -1
- package/lib/component/panels/RangesPanel/RangesTableRow.d.ts +2 -2
- package/lib/component/panels/RangesPanel/RangesTableRow.js +2 -2
- package/lib/component/panels/RangesPanel/RangesTableRow.js.map +1 -1
- package/lib/component/panels/SpectraPanel/SpectraTable.d.ts.map +1 -1
- package/lib/component/panels/SpectraPanel/SpectraTable.js +5 -1
- package/lib/component/panels/SpectraPanel/SpectraTable.js.map +1 -1
- package/lib/component/panels/SpectraPanel/base/RenderAsHTML.d.ts.map +1 -1
- package/lib/component/panels/SpectraPanel/base/RenderAsHTML.js +7 -4
- package/lib/component/panels/SpectraPanel/base/RenderAsHTML.js.map +1 -1
- package/lib/component/panels/SpectraPanel/base/SpectrumName.d.ts.map +1 -1
- package/lib/component/panels/SpectraPanel/base/SpectrumName.js +5 -1
- package/lib/component/panels/SpectraPanel/base/SpectrumName.js.map +1 -1
- package/lib/component/panels/SpectraPanel/base/setting/SpectrumSetting.d.ts.map +1 -1
- package/lib/component/panels/SpectraPanel/base/setting/SpectrumSetting.js +2 -2
- package/lib/component/panels/SpectraPanel/base/setting/SpectrumSetting.js.map +1 -1
- package/lib/component/panels/SummaryPanel/SummaryPanel.d.ts.map +1 -1
- package/lib/component/panels/SummaryPanel/SummaryPanel.js.map +1 -1
- package/lib/component/panels/hooks/useMoleculeAnnotationCore.d.ts +3 -2
- package/lib/component/panels/hooks/useMoleculeAnnotationCore.d.ts.map +1 -1
- package/lib/component/panels/hooks/useMoleculeAnnotationCore.js +14 -8
- package/lib/component/panels/hooks/useMoleculeAnnotationCore.js.map +1 -1
- package/lib/component/panels/informationPanel/MixedValuesBadge.d.ts.map +1 -1
- package/lib/component/panels/informationPanel/MixedValuesBadge.js +2 -2
- package/lib/component/panels/informationPanel/MixedValuesBadge.js.map +1 -1
- package/lib/component/panels/informationPanel/SpectraPicker.d.ts.map +1 -1
- package/lib/component/panels/informationPanel/SpectraPicker.js +2 -2
- package/lib/component/panels/informationPanel/SpectraPicker.js.map +1 -1
- package/lib/component/reducer/actions/DomainActions.d.ts.map +1 -1
- 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.map +1 -1
- package/lib/component/reducer/actions/LoadAction.d.ts.map +1 -1
- package/lib/component/reducer/actions/LoadAction.js.map +1 -1
- package/lib/component/reducer/helper/setRangesViewProperty.d.ts.map +1 -1
- package/lib/component/reducer/helper/setRangesViewProperty.js.map +1 -1
- package/lib/component/reducer/preferences/panelsPreferencesDefaultValues.d.ts.map +1 -1
- package/lib/component/reducer/preferences/panelsPreferencesDefaultValues.js +35 -26
- package/lib/component/reducer/preferences/panelsPreferencesDefaultValues.js.map +1 -1
- package/lib/component/reducer/preferences/preferencesReducer.d.ts +2 -2
- package/lib/component/reducer/preferences/preferencesReducer.d.ts.map +1 -1
- package/lib/component/reducer/preferences/utilities/initWorkspace.d.ts +2 -2
- package/lib/component/reducer/preferences/utilities/mapWorkspaces.d.ts +2 -2
- package/lib/component/reducer/preferences/utilities/mapWorkspaces.d.ts.map +1 -1
- package/lib/component/toolbar/ToolTypes.d.ts +2 -2
- package/lib/component/utility/export.d.ts.map +1 -1
- package/lib/component/utility/export.js +1 -0
- package/lib/component/utility/export.js.map +1 -1
- package/lib/data/PredictionManager.js.map +1 -1
- package/lib/data/constants/signalsKinds.d.ts +1 -2
- package/lib/data/constants/signalsKinds.d.ts.map +1 -1
- package/lib/data/data1d/multipleSpectraAnalysis.d.ts +2 -2
- package/lib/data/matrixGeneration.d.ts.map +1 -1
- package/lib/data/matrixGeneration.js.map +1 -1
- package/lib/versionInfo.js +1 -1
- package/package.json +30 -31
- package/src/component/1d/PredictionErrorsNotations.tsx +5 -4
- package/src/component/1d/peaks/Peaks.tsx +5 -2
- package/src/component/1d/peaks/usePeakShapesPath.ts +0 -1
- package/src/component/1d/ranges/AssignmentLabel.tsx +1 -1
- package/src/component/1d/ranges/FloatingRangeTablePreferencesModal.tsx +238 -0
- package/src/component/1d/ranges/FloatingRanges.tsx +529 -0
- package/src/component/1d/ranges/Ranges.tsx +2 -2
- package/src/component/1d-2d/FieldEdition.tsx +4 -4
- package/src/component/1d-2d/components/FloatMoleculeStructures/DraggableStructure.tsx +8 -8
- package/src/component/2d/zones/SignalsGuideLines.tsx +1 -1
- package/src/component/2d/zones/ZonesAssignmentsLabels.tsx +1 -1
- package/src/component/EventsTrackers/BrushTracker.tsx +1 -2
- package/src/component/SVGTable.tsx +35 -33
- package/src/component/context/KeyModifierContext.tsx +1 -2
- package/src/component/context/LoggerContext.tsx +1 -7
- package/src/component/context/SortSpectraContext.tsx +1 -3
- package/src/component/elements/ActionsButtonsPopover.tsx +12 -14
- package/src/component/elements/Button.tsx +1 -6
- package/src/component/elements/Sections.tsx +5 -3
- package/src/component/elements/TabTitle.tsx +7 -5
- package/src/component/elements/ToolbarPopoverItem.tsx +13 -2
- package/src/component/elements/dropDownButton/DropDownButton.tsx +7 -5
- package/src/component/elements/export/ExportOptionsModal.tsx +56 -276
- package/src/component/elements/export/units.ts +0 -6
- package/src/component/elements/export/utilities/getExportOptions.ts +1 -0
- package/src/component/elements/print/pageSize.ts +1 -1
- package/src/component/hooks/useExport.tsx +1 -3
- package/src/component/hooks/usePanelPreferences.ts +4 -4
- package/src/component/hooks/useTextMetrics.ts +1 -0
- package/src/component/main/NMRiumViewer.tsx +1 -1
- package/src/component/modal/EditPeakShapeModal.tsx +2 -2
- package/src/component/modal/SaveAsModal.tsx +89 -82
- package/src/component/modal/editRange/EditRangeModal.tsx +6 -4
- package/src/component/modal/editRange/forms/components/NewSignalTab.tsx +3 -3
- package/src/component/modal/setting/WorkspaceItem.tsx +2 -2
- package/src/component/modal/setting/tanstack_general_settings/errors/context.tsx +3 -3
- package/src/component/modal/setting/tanstack_general_settings/errors/renderer.tsx +2 -2
- package/src/component/modal/setting/tanstack_general_settings/general_settings_dialog_body.tsx +2 -2
- package/src/component/modal/setting/tanstack_general_settings/general_settings_dialog_header.tsx +2 -2
- package/src/component/modal/setting/tanstack_general_settings/tabs/auto_processing_tab.tsx +2 -2
- package/src/component/modal/setting/tanstack_general_settings/tabs/export_tab.fields.tsx +2 -2
- package/src/component/modal/setting/tanstack_general_settings/tabs/spectra_label_tab.tsx +3 -2
- package/src/component/modal/setting/tanstack_general_settings/tabs/title_block_tab.tsx +3 -2
- package/src/component/panels/MoleculesPanel/MoleculePanelHeader.tsx +41 -8
- package/src/component/panels/PeaksPanel/PeaksPreferences.tsx +18 -18
- package/src/component/panels/PeaksPanel/PeaksTable.tsx +11 -11
- package/src/component/panels/RangesPanel/RangesHeader.tsx +1 -2
- package/src/component/panels/RangesPanel/RangesPanel.tsx +2 -2
- package/src/component/panels/RangesPanel/RangesPreferences.tsx +22 -22
- package/src/component/panels/RangesPanel/RangesTable.tsx +19 -17
- package/src/component/panels/RangesPanel/RangesTableRow.tsx +25 -25
- package/src/component/panels/SpectraPanel/SpectraTable.tsx +12 -1
- package/src/component/panels/SpectraPanel/base/RenderAsHTML.tsx +22 -4
- package/src/component/panels/SpectraPanel/base/SpectrumName.tsx +15 -6
- package/src/component/panels/SpectraPanel/base/setting/SpectrumSetting.tsx +3 -2
- package/src/component/panels/SummaryPanel/SummaryPanel.tsx +1 -5
- package/src/component/panels/hooks/useMoleculeAnnotationCore.ts +17 -9
- package/src/component/panels/informationPanel/MixedValuesBadge.tsx +3 -2
- package/src/component/panels/informationPanel/SpectraPicker.tsx +12 -4
- package/src/component/panels/multipleAnalysisPanel/AnalysisChart.tsx +2 -2
- package/src/component/reducer/actions/DomainActions.ts +1 -4
- package/src/component/reducer/actions/FiltersActions.ts +1 -2
- package/src/component/reducer/actions/LoadAction.ts +1 -3
- package/src/component/reducer/helper/setRangesViewProperty.ts +1 -2
- package/src/component/reducer/preferences/panelsPreferencesDefaultValues.ts +32 -19
- package/src/component/reducer/preferences/preferencesReducer.ts +2 -2
- package/src/component/reducer/preferences/utilities/initWorkspace.ts +2 -2
- package/src/component/reducer/preferences/utilities/mapWorkspaces.ts +2 -2
- package/src/component/toolbar/ToolTypes.ts +2 -2
- package/src/component/utility/export.ts +1 -0
- package/src/data/PredictionManager.ts +4 -6
- package/src/data/constants/signalsKinds.ts +1 -1
- package/src/data/data1d/multipleSpectraAnalysis.ts +2 -2
- package/src/data/matrixGeneration.ts +1 -5
- package/src/versionInfo.ts +1 -1
- package/lib/component/1d/FloatingRanges.d.ts.map +0 -1
- package/lib/component/1d/FloatingRanges.js +0 -263
- package/lib/component/1d/FloatingRanges.js.map +0 -1
- package/lib/component/elements/export/utilities/exportOptionValidationSchema.d.ts +0 -17
- package/lib/component/elements/export/utilities/exportOptionValidationSchema.d.ts.map +0 -1
- package/lib/component/elements/export/utilities/exportOptionValidationSchema.js +0 -79
- package/lib/component/elements/export/utilities/exportOptionValidationSchema.js.map +0 -1
- package/lib/component/elements/export/utilities/getModes.d.ts +0 -4
- package/lib/component/elements/export/utilities/getModes.d.ts.map +0 -1
- package/lib/component/elements/export/utilities/getModes.js +0 -11
- package/lib/component/elements/export/utilities/getModes.js.map +0 -1
- package/src/component/1d/FloatingRanges.tsx +0 -378
- package/src/component/elements/export/utilities/exportOptionValidationSchema.ts +0 -106
- package/src/component/elements/export/utilities/getModes.ts +0 -14
- /package/lib/component/1d/{FloatingRanges.d.ts → ranges/FloatingRanges.d.ts} +0 -0
|
@@ -1,4 +1,10 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import {
|
|
2
|
+
Button,
|
|
3
|
+
Checkbox,
|
|
4
|
+
Icon,
|
|
5
|
+
InputGroup,
|
|
6
|
+
PopoverNext,
|
|
7
|
+
} from '@blueprintjs/core';
|
|
2
8
|
import styled from '@emotion/styled';
|
|
3
9
|
import { useState } from 'react';
|
|
4
10
|
|
|
@@ -232,11 +238,13 @@ export function SpectraPicker({
|
|
|
232
238
|
: `${selectedTotal} / ${total}`;
|
|
233
239
|
|
|
234
240
|
return (
|
|
235
|
-
<
|
|
241
|
+
<PopoverNext
|
|
242
|
+
lazy
|
|
236
243
|
isOpen={disabled ? false : open}
|
|
237
244
|
onInteraction={setOpen}
|
|
238
245
|
placement="bottom-start"
|
|
239
|
-
|
|
246
|
+
arrow={false}
|
|
247
|
+
animation="minimal"
|
|
240
248
|
content={
|
|
241
249
|
<SpectraPickerContent
|
|
242
250
|
selected={selected}
|
|
@@ -255,6 +263,6 @@ export function SpectraPicker({
|
|
|
255
263
|
</span>
|
|
256
264
|
<Icon icon="caret-down" size={12} />
|
|
257
265
|
</SpectraTrigger>
|
|
258
|
-
</
|
|
266
|
+
</PopoverNext>
|
|
259
267
|
);
|
|
260
268
|
}
|
|
@@ -3,7 +3,7 @@ import { css } from '@emotion/react';
|
|
|
3
3
|
import type {
|
|
4
4
|
JpathTableColumn,
|
|
5
5
|
Spectrum,
|
|
6
|
-
|
|
6
|
+
WorkspacePanelPreferences,
|
|
7
7
|
} from '@zakodium/nmrium-core';
|
|
8
8
|
import dlv from 'dlv';
|
|
9
9
|
import type { ChangeEvent } from 'react';
|
|
@@ -82,7 +82,7 @@ function getPlotDataAsString(
|
|
|
82
82
|
options: {
|
|
83
83
|
plotOptions: PlotOptions;
|
|
84
84
|
spectra: Spectrum[];
|
|
85
|
-
spectraPanelPreferences:
|
|
85
|
+
spectraPanelPreferences: WorkspacePanelPreferences['spectra'];
|
|
86
86
|
},
|
|
87
87
|
) {
|
|
88
88
|
const { plotOptions, spectra, spectraPanelPreferences } = options;
|
|
@@ -60,10 +60,7 @@ function is2DFTSpectrum(
|
|
|
60
60
|
}
|
|
61
61
|
|
|
62
62
|
export type DomainActions =
|
|
63
|
-
|
|
|
64
|
-
| SetYDomainAction
|
|
65
|
-
| SetAxisDomainAction
|
|
66
|
-
| MoveAction;
|
|
63
|
+
SetXDomainAction | SetYDomainAction | SetAxisDomainAction | MoveAction;
|
|
67
64
|
|
|
68
65
|
function getActiveData(draft: Draft<State>): Spectrum1D[] {
|
|
69
66
|
let data = draft.data.filter(
|
|
@@ -1704,8 +1704,7 @@ function deleteFilter(datum: Spectrum, id?: string) {
|
|
|
1704
1704
|
} else {
|
|
1705
1705
|
removedFilter = datum.filters.find((filter) => filter.id === id);
|
|
1706
1706
|
datum.filters = filters.filter((filter) => filter.id !== id) as
|
|
1707
|
-
|
|
|
1708
|
-
| Filter2DEntry[];
|
|
1707
|
+
Filter1DEntry[] | Filter2DEntry[];
|
|
1709
1708
|
}
|
|
1710
1709
|
|
|
1711
1710
|
// do not reprocess the filters when the deleted filter is inactive
|
|
@@ -55,9 +55,7 @@ type LoadDropFilesAction = ActionType<'LOAD_DROP_FILES', InputProps>;
|
|
|
55
55
|
type InitiateAction = ActionType<'INITIATE', InitiateProps>;
|
|
56
56
|
|
|
57
57
|
export type LoadAction =
|
|
58
|
-
|
|
|
59
|
-
| LoadDropFilesAction
|
|
60
|
-
| InitiateAction;
|
|
58
|
+
SetIsLoadingAction | LoadDropFilesAction | InitiateAction;
|
|
61
59
|
|
|
62
60
|
function convertHybridizationStringValuesInCorrelations(
|
|
63
61
|
correlations: CorrelationData,
|
|
@@ -29,8 +29,7 @@ export function setRangesViewProperty<T extends keyof RangesViewState>(
|
|
|
29
29
|
options: {
|
|
30
30
|
spectrumKey?: string;
|
|
31
31
|
value:
|
|
32
|
-
|
|
33
|
-
| RangesViewState[T];
|
|
32
|
+
((value: RangesViewState[T]) => RangesViewState[T]) | RangesViewState[T];
|
|
34
33
|
},
|
|
35
34
|
) {
|
|
36
35
|
const rangesView = draft.view.ranges;
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import type {
|
|
2
2
|
BaseNucleus1DPreferences,
|
|
3
3
|
BaseNucleus2DPreferences,
|
|
4
|
+
FloatingRangesTablePreferences,
|
|
4
5
|
MatrixGenerationOptions,
|
|
5
6
|
MultipleSpectraAnalysisPreferences,
|
|
6
7
|
PanelsPreferences,
|
|
7
8
|
PeaksNucleusPreferences,
|
|
9
|
+
RangesNucleusPreferences,
|
|
8
10
|
SpectraPreferences,
|
|
9
11
|
Zones1DNucleusPreferences,
|
|
10
12
|
Zones2DNucleusPreferences,
|
|
@@ -124,10 +126,8 @@ const getZoneDefaultValues = (nucleus?: string): PanelsPreferences['zones'] => {
|
|
|
124
126
|
}
|
|
125
127
|
};
|
|
126
128
|
|
|
127
|
-
const
|
|
128
|
-
|
|
129
|
-
): PanelsPreferences['ranges'] => {
|
|
130
|
-
const preferences = {
|
|
129
|
+
const createBaseRangesTablePreferences =
|
|
130
|
+
(): FloatingRangesTablePreferences => ({
|
|
131
131
|
showSerialNumber: true,
|
|
132
132
|
from: { show: false, format: '0.00' },
|
|
133
133
|
to: { show: false, format: '0.00' },
|
|
@@ -136,14 +136,25 @@ const getRangeDefaultValues = (
|
|
|
136
136
|
deltaPPM: { show: true, format: '0.00' },
|
|
137
137
|
deltaHz: { show: false, format: '0.00' },
|
|
138
138
|
coupling: { show: true, format: '0.00' },
|
|
139
|
-
jGraphTolerance: isProton(nucleus || '') ? 0.2 : nucleus === '13C' ? 2 : 0, //J Graph tolerance for: 1H: 0.2Hz 13C: 2Hz
|
|
140
139
|
showKind: true,
|
|
141
140
|
showMultiplicity: true,
|
|
142
141
|
showAssignment: true,
|
|
143
|
-
showDeleteAction: true,
|
|
144
|
-
showZoomAction: true,
|
|
145
|
-
showEditAction: true,
|
|
146
142
|
showAssignmentLabel: true,
|
|
143
|
+
signalKinds: ['signal'],
|
|
144
|
+
});
|
|
145
|
+
|
|
146
|
+
const getRangeDefaultValues = (
|
|
147
|
+
nucleus?: string,
|
|
148
|
+
): PanelsPreferences['ranges'] => {
|
|
149
|
+
const preferences: RangesNucleusPreferences = {
|
|
150
|
+
floatingTablePreferences: createBaseRangesTablePreferences(),
|
|
151
|
+
tablePreferences: {
|
|
152
|
+
...createBaseRangesTablePreferences(),
|
|
153
|
+
showDeleteAction: true,
|
|
154
|
+
showZoomAction: true,
|
|
155
|
+
showEditAction: true,
|
|
156
|
+
},
|
|
157
|
+
jGraphTolerance: isProton(nucleus || '') ? 0.2 : nucleus === '13C' ? 2 : 0, //J Graph tolerance for: 1H: 0.2Hz 13C: 2Hz
|
|
147
158
|
isSumConstant: true,
|
|
148
159
|
};
|
|
149
160
|
|
|
@@ -154,17 +165,19 @@ const getPeaksDefaultValues = (
|
|
|
154
165
|
nucleus?: string,
|
|
155
166
|
): PanelsPreferences['peaks'] => {
|
|
156
167
|
const preferences: PeaksNucleusPreferences = {
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
+
tablePreferences: {
|
|
169
|
+
showSerialNumber: true,
|
|
170
|
+
deltaPPM: { show: true, format: '0.00' },
|
|
171
|
+
deltaHz: { show: false, format: '0.00' },
|
|
172
|
+
peakWidth: { show: false, format: '0.00' },
|
|
173
|
+
intensity: { show: true, format: '0.00' },
|
|
174
|
+
fwhm: { show: true, format: '0.00000' },
|
|
175
|
+
mu: { show: false, format: '0.00000' },
|
|
176
|
+
gamma: { show: false, format: '0.000' },
|
|
177
|
+
showKind: true,
|
|
178
|
+
showDeleteAction: true,
|
|
179
|
+
showEditPeakShapeAction: true,
|
|
180
|
+
},
|
|
168
181
|
defaultPeakShape: DEFAULT_PEAK_SHAPE,
|
|
169
182
|
};
|
|
170
183
|
return getPreferences(preferences, nucleus);
|
|
@@ -9,8 +9,8 @@ import type {
|
|
|
9
9
|
PanelPreferencesType,
|
|
10
10
|
PanelsPreferences,
|
|
11
11
|
PrintPageOptions,
|
|
12
|
-
WorkSpaceSource,
|
|
13
12
|
Workspace,
|
|
13
|
+
WorkspaceSource,
|
|
14
14
|
} from '@zakodium/nmrium-core';
|
|
15
15
|
import { CURRENT_EXPORT_VERSION, migrateSettings } from '@zakodium/nmrium-core';
|
|
16
16
|
import type { Draft } from 'immer';
|
|
@@ -223,7 +223,7 @@ export type PreferencesActions =
|
|
|
223
223
|
| CutSpectraAnalysisAction
|
|
224
224
|
| ToggleSplitPanelAction;
|
|
225
225
|
|
|
226
|
-
export type WorkspaceWithSource = Workspace & { source:
|
|
226
|
+
export type WorkspaceWithSource = Workspace & { source: WorkspaceSource };
|
|
227
227
|
type WorkspacesWithSource = Record<string, WorkspaceWithSource>;
|
|
228
228
|
|
|
229
229
|
export interface PreferencesState {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { WorkspaceSource } from '@zakodium/nmrium-core';
|
|
2
2
|
import lodashMerge from 'lodash/merge.js';
|
|
3
3
|
|
|
4
4
|
import { workspaceDefaultProperties } from '../../../workspaces/workspaceDefaultProperties.js';
|
|
@@ -6,7 +6,7 @@ import type { WorkspaceWithSource } from '../preferencesReducer.js';
|
|
|
6
6
|
|
|
7
7
|
export function initWorkspace(
|
|
8
8
|
preferences: any,
|
|
9
|
-
data: { source:
|
|
9
|
+
data: { source: WorkspaceSource; label: string },
|
|
10
10
|
): WorkspaceWithSource {
|
|
11
11
|
return lodashMerge({}, workspaceDefaultProperties, preferences, data);
|
|
12
12
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type {
|
|
2
|
-
WorkSpaceSource,
|
|
3
2
|
Workspace,
|
|
4
3
|
WorkspacePreferences,
|
|
4
|
+
WorkspaceSource,
|
|
5
5
|
} from '@zakodium/nmrium-core';
|
|
6
6
|
import lodashMerge from 'lodash/merge.js';
|
|
7
7
|
|
|
@@ -10,7 +10,7 @@ import { workspaceDefaultProperties } from '../../../workspaces/workspaceDefault
|
|
|
10
10
|
interface MapWorkspacesOptions {
|
|
11
11
|
ignoreKeys?: object;
|
|
12
12
|
mergeWithDefaultProperties?: boolean;
|
|
13
|
-
source?:
|
|
13
|
+
source?: WorkspaceSource;
|
|
14
14
|
}
|
|
15
15
|
|
|
16
16
|
export function mapWorkspaces(
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { Info1D, Info2D } from '@zakodium/nmr-types';
|
|
2
|
-
import type {
|
|
2
|
+
import type { NMRiumToolbarPreferences } from '@zakodium/nmrium-core';
|
|
3
3
|
import { Filters1D, Filters2D } from 'nmr-processing';
|
|
4
4
|
|
|
5
5
|
import type { DisplayerMode } from '../reducer/Reducer.js';
|
|
@@ -32,7 +32,7 @@ export interface ToolOptionItem {
|
|
|
32
32
|
isExperimental?: true;
|
|
33
33
|
}
|
|
34
34
|
|
|
35
|
-
export type MainTool = keyof
|
|
35
|
+
export type MainTool = keyof NMRiumToolbarPreferences;
|
|
36
36
|
|
|
37
37
|
/**
|
|
38
38
|
* Tools that are selectable in panels, not in the main toolbar.
|
|
@@ -302,6 +302,7 @@ function copyDataURLClipboardFireFox(image: string) {
|
|
|
302
302
|
const range = document.createRange();
|
|
303
303
|
range.selectNode(img);
|
|
304
304
|
globalThis.getSelection()?.addRange(range);
|
|
305
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
305
306
|
document.execCommand('Copy');
|
|
306
307
|
img.remove();
|
|
307
308
|
}
|
|
@@ -343,12 +343,10 @@ function mapZones(zones: NMRZone[]): Zone[] {
|
|
|
343
343
|
kind: kind || 'signal',
|
|
344
344
|
x: { ...x, originalDelta: x.delta || 0 },
|
|
345
345
|
y: { ...y, originalDelta: y.delta || 0 },
|
|
346
|
-
peaks: peaks?.map(
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
}),
|
|
351
|
-
),
|
|
346
|
+
peaks: peaks?.map((peak): Peak2D => ({
|
|
347
|
+
...peak,
|
|
348
|
+
id: peak.id || crypto.randomUUID(),
|
|
349
|
+
})),
|
|
352
350
|
};
|
|
353
351
|
});
|
|
354
352
|
return {
|
|
@@ -8,7 +8,7 @@ import type {
|
|
|
8
8
|
SpectraAnalysisColumns,
|
|
9
9
|
Spectrum1D,
|
|
10
10
|
Spectrum,
|
|
11
|
-
|
|
11
|
+
WorkspacePanelPreferences,
|
|
12
12
|
} from '@zakodium/nmrium-core';
|
|
13
13
|
import {
|
|
14
14
|
ANALYSIS_COLUMN_TYPES,
|
|
@@ -314,7 +314,7 @@ function calculate(
|
|
|
314
314
|
export function getDataAsString(
|
|
315
315
|
spectraAnalysis: SpectraAnalysisData,
|
|
316
316
|
spectra: Spectrum1D[],
|
|
317
|
-
spectraPanelPreferences:
|
|
317
|
+
spectraPanelPreferences: WorkspacePanelPreferences['spectra'],
|
|
318
318
|
) {
|
|
319
319
|
const spectraData = convertSpectraArrayToObject(spectra);
|
|
320
320
|
if (spectraAnalysis) {
|
|
@@ -32,11 +32,7 @@ interface BooleanField extends Field<boolean> {
|
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
type CommonField =
|
|
35
|
-
|
|
|
36
|
-
| StringField
|
|
37
|
-
| NumberField
|
|
38
|
-
| BooleanField
|
|
39
|
-
| LabelField;
|
|
35
|
+
SelectField | StringField | NumberField | BooleanField | LabelField;
|
|
40
36
|
|
|
41
37
|
interface ListField extends Field<string[]> {
|
|
42
38
|
type: 'list';
|
package/src/versionInfo.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export default { version: 'v2.
|
|
1
|
+
export default { version: 'v2.3.0' };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FloatingRanges.d.ts","sourceRoot":"","sources":["../../../src/component/1d/FloatingRanges.tsx"],"names":[],"mappings":"AAoWA,wBAAgB,cAAc,2CAqB7B"}
|
|
@@ -1,263 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import styled from '@emotion/styled';
|
|
3
|
-
import { checkMultiplicity } from 'nmr-processing';
|
|
4
|
-
import { memo, useEffect, useState } from 'react';
|
|
5
|
-
import { BsArrowsMove } from 'react-icons/bs';
|
|
6
|
-
import { FaTimes } from 'react-icons/fa';
|
|
7
|
-
import { Rnd } from 'react-rnd';
|
|
8
|
-
import { isSpectrum1D } from '../../data/data1d/Spectrum1D/index.js';
|
|
9
|
-
import { isSignalRange } from '../../data/utilities/RangeUtilities.js';
|
|
10
|
-
import { SVGTable } from '../SVGTable.js';
|
|
11
|
-
import { useChartData } from '../context/ChartContext.js';
|
|
12
|
-
import { useDispatch } from '../context/DispatchContext.js';
|
|
13
|
-
import { useGlobal } from '../context/GlobalContext.js';
|
|
14
|
-
import { ActionsButtonsPopover } from '../elements/ActionsButtonsPopover.js';
|
|
15
|
-
import { useActiveNucleusTab } from '../hooks/useActiveNucleusTab.js';
|
|
16
|
-
import { usePanelPreferences } from '../hooks/usePanelPreferences.js';
|
|
17
|
-
import { useSVGUnitConverter } from '../hooks/useSVGUnitConverter.js';
|
|
18
|
-
import useSpectraByActiveNucleus from '../hooks/useSpectraPerNucleus.js';
|
|
19
|
-
import { useCheckExportStatus } from '../hooks/useViewportSize.js';
|
|
20
|
-
import { extractChemicalElement } from '../utility/extractChemicalElement.js';
|
|
21
|
-
import { formatNumber } from '../utility/formatNumber.js';
|
|
22
|
-
const ReactRnd = styled(Rnd) `
|
|
23
|
-
border: 1px solid transparent;
|
|
24
|
-
|
|
25
|
-
:hover {
|
|
26
|
-
background-color: white;
|
|
27
|
-
border: 1px solid #ebecf1;
|
|
28
|
-
|
|
29
|
-
button {
|
|
30
|
-
visibility: visible;
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
`;
|
|
34
|
-
function useMapRanges(ranges) {
|
|
35
|
-
const output = [];
|
|
36
|
-
const activeTab = useActiveNucleusTab();
|
|
37
|
-
const preferences = usePanelPreferences('ranges', activeTab);
|
|
38
|
-
for (const range of ranges) {
|
|
39
|
-
const { id, from, to, integration, signals = [] } = range;
|
|
40
|
-
const relativeFlag = isSignalRange(range);
|
|
41
|
-
const formattedValue = formatNumber(integration, preferences.relative.format);
|
|
42
|
-
const integrationValue = relativeFlag
|
|
43
|
-
? formattedValue
|
|
44
|
-
: `[ ${formattedValue} ]`;
|
|
45
|
-
const rangeText = `${formatNumber(from, preferences.from.format)} - ${formatNumber(to, preferences.to.format)}`;
|
|
46
|
-
if (signals.length > 0) {
|
|
47
|
-
for (const signal of signals) {
|
|
48
|
-
const { multiplicity, delta, js = [] } = signal;
|
|
49
|
-
const coupling = js
|
|
50
|
-
.map((jsItem) => !Number.isNaN(jsItem.coupling)
|
|
51
|
-
? formatNumber(jsItem.coupling, preferences.coupling.format)
|
|
52
|
-
: '')
|
|
53
|
-
.join(',');
|
|
54
|
-
const signalDelta = !checkMultiplicity(multiplicity, ['m'])
|
|
55
|
-
? rangeText
|
|
56
|
-
: formatNumber(delta, preferences.deltaPPM.format);
|
|
57
|
-
output.push({
|
|
58
|
-
id,
|
|
59
|
-
delta: signalDelta,
|
|
60
|
-
multiplicity,
|
|
61
|
-
integration: integrationValue,
|
|
62
|
-
coupling,
|
|
63
|
-
});
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
else {
|
|
67
|
-
output.push({
|
|
68
|
-
id,
|
|
69
|
-
delta: rangeText,
|
|
70
|
-
multiplicity: 'm',
|
|
71
|
-
integration: integrationValue,
|
|
72
|
-
coupling: '',
|
|
73
|
-
});
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
return output;
|
|
77
|
-
}
|
|
78
|
-
function InnerSVGRangesTable(props) {
|
|
79
|
-
const { ranges } = props;
|
|
80
|
-
const { view: { spectra: { activeTab }, }, } = useChartData();
|
|
81
|
-
const data = useMapRanges(ranges);
|
|
82
|
-
if (!data)
|
|
83
|
-
return null;
|
|
84
|
-
const element = extractChemicalElement(activeTab);
|
|
85
|
-
const columns = [
|
|
86
|
-
{
|
|
87
|
-
accessorKey: 'delta',
|
|
88
|
-
header: 'δ (ppm)',
|
|
89
|
-
width: 100,
|
|
90
|
-
rowSpanGroupKey: 'id',
|
|
91
|
-
headerTextProps: { fontWeight: 'bold' },
|
|
92
|
-
cellBoxProps: { stroke: '#dedede', fill: 'white', fillOpacity: 0.8 },
|
|
93
|
-
headerBoxProps: { stroke: '#dedede', fill: '#E5E8EB' },
|
|
94
|
-
},
|
|
95
|
-
{
|
|
96
|
-
accessorKey: 'integration',
|
|
97
|
-
header: `Rel. ${element}`,
|
|
98
|
-
width: 60,
|
|
99
|
-
rowSpanGroupKey: 'id',
|
|
100
|
-
headerTextProps: { fontWeight: 'bold' },
|
|
101
|
-
cellBoxProps: { stroke: '#dedede', fill: 'white', fillOpacity: 0.8 },
|
|
102
|
-
headerBoxProps: { stroke: '#dedede', fill: '#E5E8EB' },
|
|
103
|
-
},
|
|
104
|
-
{
|
|
105
|
-
accessorKey: 'multiplicity',
|
|
106
|
-
header: 'Mult.',
|
|
107
|
-
width: 60,
|
|
108
|
-
rowSpanGroupKey: 'id',
|
|
109
|
-
headerTextProps: { fontWeight: 'bold' },
|
|
110
|
-
cellBoxProps: { stroke: '#dedede', fill: 'white', fillOpacity: 0.8 },
|
|
111
|
-
headerBoxProps: { stroke: '#dedede', fill: '#E5E8EB' },
|
|
112
|
-
},
|
|
113
|
-
{
|
|
114
|
-
accessorKey: 'coupling',
|
|
115
|
-
header: 'J (Hz)',
|
|
116
|
-
width: 120,
|
|
117
|
-
headerTextProps: { fontWeight: 'bold' },
|
|
118
|
-
cellBoxProps: { stroke: '#dedede', fill: 'white', fillOpacity: 0.8 },
|
|
119
|
-
headerBoxProps: { stroke: '#dedede', fill: '#E5E8EB' },
|
|
120
|
-
},
|
|
121
|
-
];
|
|
122
|
-
return _jsx(SVGTable, { data: data, columns: columns });
|
|
123
|
-
}
|
|
124
|
-
const SVGRangesTable = memo(InnerSVGRangesTable);
|
|
125
|
-
function DraggableRanges(props) {
|
|
126
|
-
const { ranges = [], bonding: externalBounding, spectrumKey } = props;
|
|
127
|
-
const dispatch = useDispatch();
|
|
128
|
-
const { viewerRef } = useGlobal();
|
|
129
|
-
const [bounding, setBounding] = useState(externalBounding);
|
|
130
|
-
const [isMoveActive, setIsMoveActive] = useState(false);
|
|
131
|
-
const { percentToPixel, pixelToPercent } = useSVGUnitConverter();
|
|
132
|
-
const isExportProcessStart = useCheckExportStatus();
|
|
133
|
-
useEffect(() => {
|
|
134
|
-
setBounding({ ...externalBounding });
|
|
135
|
-
}, [externalBounding]);
|
|
136
|
-
function handleResize(internalBounding) {
|
|
137
|
-
const { width = 0, height = 0 } = convertToPixel(externalBounding);
|
|
138
|
-
internalBounding.width += width;
|
|
139
|
-
internalBounding.height += height;
|
|
140
|
-
setBounding((prevBounding) => ({
|
|
141
|
-
...prevBounding,
|
|
142
|
-
...convertToPercent(internalBounding),
|
|
143
|
-
}));
|
|
144
|
-
}
|
|
145
|
-
function handleDrag(internalBounding) {
|
|
146
|
-
setBounding((prevBounding) => ({
|
|
147
|
-
...prevBounding,
|
|
148
|
-
...convertToPercent(internalBounding),
|
|
149
|
-
}));
|
|
150
|
-
}
|
|
151
|
-
function handleChangeInsetBounding(bounding) {
|
|
152
|
-
if (typeof bounding?.width === 'number' &&
|
|
153
|
-
typeof bounding?.height === 'number') {
|
|
154
|
-
const { width, height } = externalBounding;
|
|
155
|
-
bounding.width += width;
|
|
156
|
-
bounding.height += height;
|
|
157
|
-
}
|
|
158
|
-
dispatch({
|
|
159
|
-
type: 'CHANGE_RANGES_VIEW_FLOATING_BOX_BOUNDING',
|
|
160
|
-
payload: {
|
|
161
|
-
spectrumKey,
|
|
162
|
-
bounding: convertToPercent(bounding),
|
|
163
|
-
target: 'rangesBounding',
|
|
164
|
-
},
|
|
165
|
-
});
|
|
166
|
-
}
|
|
167
|
-
function convertToPixel(bounding) {
|
|
168
|
-
const { x, y, height, width } = bounding;
|
|
169
|
-
const output = {};
|
|
170
|
-
if (x) {
|
|
171
|
-
output.x = percentToPixel(x, 'x');
|
|
172
|
-
}
|
|
173
|
-
if (y) {
|
|
174
|
-
output.y = percentToPixel(y, 'y');
|
|
175
|
-
}
|
|
176
|
-
if (width) {
|
|
177
|
-
output.width = width;
|
|
178
|
-
}
|
|
179
|
-
if (height) {
|
|
180
|
-
output.height = height;
|
|
181
|
-
}
|
|
182
|
-
return output;
|
|
183
|
-
}
|
|
184
|
-
function convertToPercent(bounding) {
|
|
185
|
-
const { x, y, height, width } = bounding;
|
|
186
|
-
const output = {};
|
|
187
|
-
if (x) {
|
|
188
|
-
output.x = pixelToPercent(x, 'x');
|
|
189
|
-
}
|
|
190
|
-
if (y) {
|
|
191
|
-
output.y = pixelToPercent(y, 'y');
|
|
192
|
-
}
|
|
193
|
-
if (width) {
|
|
194
|
-
output.width = width;
|
|
195
|
-
}
|
|
196
|
-
if (height) {
|
|
197
|
-
output.height = height;
|
|
198
|
-
}
|
|
199
|
-
return output;
|
|
200
|
-
}
|
|
201
|
-
function handleRemove() {
|
|
202
|
-
dispatch({
|
|
203
|
-
type: 'TOGGLE_RANGES_VIEW_PROPERTY',
|
|
204
|
-
payload: { key: 'showRanges', spectrumKey },
|
|
205
|
-
});
|
|
206
|
-
}
|
|
207
|
-
const actionButtons = [
|
|
208
|
-
{
|
|
209
|
-
icon: _jsx(BsArrowsMove, {}),
|
|
210
|
-
intent: 'none',
|
|
211
|
-
title: 'Move ranges table',
|
|
212
|
-
style: { cursor: 'move' },
|
|
213
|
-
className: 'handle',
|
|
214
|
-
},
|
|
215
|
-
{
|
|
216
|
-
icon: _jsx(FaTimes, {}),
|
|
217
|
-
intent: 'danger',
|
|
218
|
-
title: 'Hide ranges table',
|
|
219
|
-
onClick: handleRemove,
|
|
220
|
-
},
|
|
221
|
-
];
|
|
222
|
-
if (!viewerRef || ranges.length === 0)
|
|
223
|
-
return null;
|
|
224
|
-
const { x: xInPercent, y: yInPercent } = bounding;
|
|
225
|
-
const x = percentToPixel(xInPercent, 'x');
|
|
226
|
-
const y = percentToPixel(yInPercent, 'y');
|
|
227
|
-
if (isExportProcessStart) {
|
|
228
|
-
return (_jsx("g", { transform: `translate(${x} ${y})`, children: _jsx(SVGRangesTable, { ranges: ranges }) }));
|
|
229
|
-
}
|
|
230
|
-
return (_jsx(ReactRnd, { default: { x, y, width: 'auto', height: 'auto' }, position: { x, y }, enableResizing: false, minWidth: 100, minHeight: 50, dragHandleClassName: "handle", enableUserSelectHack: false, bounds: `#${viewerRef.id}`, onDragStart: () => setIsMoveActive(true), onResize: (e, dir, eRef, size, position) => handleResize({ ...size, ...position }), onResizeStop: (e, dir, eRef, size, position) => handleChangeInsetBounding({ ...size, ...position }), onDrag: (e, { x, y }) => {
|
|
231
|
-
handleDrag({ x, y });
|
|
232
|
-
}, onDragStop: (e, { x, y }) => {
|
|
233
|
-
handleChangeInsetBounding({ x, y });
|
|
234
|
-
setIsMoveActive(false);
|
|
235
|
-
}, resizeHandleWrapperStyle: { backgroundColor: 'white' }, children: _jsx(ActionsButtonsPopover, { buttons: actionButtons, fill: true, positioningStrategy: "fixed", direction: "row", targetProps: { style: { width: '100%', height: '100%' } }, space: 2, ...(isMoveActive && { isOpen: true }), x: x, y: y, children: _jsx(SVGRangesTable, { ranges: ranges }) }) }));
|
|
236
|
-
}
|
|
237
|
-
function useSpectraRanges() {
|
|
238
|
-
const spectra = useSpectraByActiveNucleus();
|
|
239
|
-
const output = {};
|
|
240
|
-
for (const spectrum of spectra) {
|
|
241
|
-
if (!isSpectrum1D(spectrum)) {
|
|
242
|
-
continue;
|
|
243
|
-
}
|
|
244
|
-
const { id: spectrumKey, ranges } = spectrum;
|
|
245
|
-
if (!Array.isArray(ranges?.values) || ranges.values.length === 0) {
|
|
246
|
-
continue;
|
|
247
|
-
}
|
|
248
|
-
output[spectrumKey] = ranges.values;
|
|
249
|
-
}
|
|
250
|
-
return output;
|
|
251
|
-
}
|
|
252
|
-
export function FloatingRanges() {
|
|
253
|
-
const spectraRanges = useSpectraRanges();
|
|
254
|
-
const { view: { ranges }, } = useChartData();
|
|
255
|
-
const options = Object.entries(ranges);
|
|
256
|
-
return options.map(([spectrumKey, viewOptions]) => {
|
|
257
|
-
const { showRanges, rangesBounding } = viewOptions;
|
|
258
|
-
if (!showRanges)
|
|
259
|
-
return null;
|
|
260
|
-
return (_jsx(DraggableRanges, { spectrumKey: spectrumKey, bonding: rangesBounding, ranges: spectraRanges[spectrumKey] }, spectrumKey));
|
|
261
|
-
});
|
|
262
|
-
}
|
|
263
|
-
//# sourceMappingURL=FloatingRanges.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FloatingRanges.js","sourceRoot":"","sources":["../../../src/component/1d/FloatingRanges.tsx"],"names":[],"mappings":";AAAA,OAAO,MAAM,MAAM,iBAAiB,CAAC;AAGrC,OAAO,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AACnD,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAClD,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AACzC,OAAO,EAAE,GAAG,EAAE,MAAM,WAAW,CAAC;AAEhC,OAAO,EAAE,YAAY,EAAE,MAAM,uCAAuC,CAAC;AACrE,OAAO,EAAE,aAAa,EAAE,MAAM,wCAAwC,CAAC;AAEvE,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC1D,OAAO,EAAE,WAAW,EAAE,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,SAAS,EAAE,MAAM,6BAA6B,CAAC;AAExD,OAAO,EAAE,qBAAqB,EAAE,MAAM,sCAAsC,CAAC;AAC7E,OAAO,EAAE,mBAAmB,EAAE,MAAM,iCAAiC,CAAC;AACtE,OAAO,EAAE,mBAA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,CAAC;IACtC,CAAC;IAED,OAAO,MAAM,CAAC;AAChB,CAAC;AAED,MAAM,UAAU,cAAc;IAC5B,MAAM,aAAa,GAAG,gBAAgB,EAAE,CAAC;IACzC,MAAM,EACJ,IAAI,EAAE,EAAE,MAAM,EAAE,GACjB,GAAG,YAAY,EAAE,CAAC;IAEnB,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;IAEvC,OAAO,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,WAAW,EAAE,WAAW,CAAC,EAAE,EAAE;QAChD,MAAM,EAAE,UAAU,EAAE,cAAc,EAAE,GAAG,WAAW,CAAC;QACnD,IAAI,CAAC,UAAU;YAAE,OAAO,IAAI,CAAC;QAE7B,OAAO,CACL,KAAC,eAAe,IAEd,WAAW,EAAE,WAAW,EACxB,OAAO,EAAE,cAAc,EACvB,MAAM,EAAE,aAAa,CAAC,WAAW,CAAC,IAH7B,WAAW,CAIhB,CACH,CAAC;IACJ,CAAC,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import type { Layout, PageSizeName } from '@zakodium/nmrium-core';
|
|
2
|
-
import * as Yup from 'yup';
|
|
3
|
-
export declare const exportOptionValidationSchema: Yup.Lazy<{
|
|
4
|
-
width: number;
|
|
5
|
-
height: number;
|
|
6
|
-
mode: NonNullable<"basic" | "advance" | undefined>;
|
|
7
|
-
dpi: number;
|
|
8
|
-
unit: NonNullable<"in" | "ft" | "m" | "px" | "yd" | "cm" | "mm" | "pt" | "pc" | undefined>;
|
|
9
|
-
useDefaultSettings: NonNullable<boolean | undefined>;
|
|
10
|
-
} | {
|
|
11
|
-
mode: NonNullable<"basic" | "advance" | undefined>;
|
|
12
|
-
layout: NonNullable<Layout | undefined>;
|
|
13
|
-
size: NonNullable<PageSizeName | undefined>;
|
|
14
|
-
dpi: number;
|
|
15
|
-
useDefaultSettings: NonNullable<boolean | undefined>;
|
|
16
|
-
}, Yup.AnyObject, any>;
|
|
17
|
-
//# sourceMappingURL=exportOptionValidationSchema.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"exportOptionValidationSchema.d.ts","sourceRoot":"","sources":["../../../../../src/component/elements/export/utilities/exportOptionValidationSchema.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAEV,MAAM,EACN,YAAY,EAEb,MAAM,uBAAuB,CAAC;AAC/B,OAAO,KAAK,GAAG,MAAM,KAAK,CAAC;AA6F3B,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;sBAMxC,CAAC"}
|