nmrium 0.37.0 → 0.38.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (374) hide show
  1. package/lib/component/1d/FooterBanner.js +1 -1
  2. package/lib/component/1d/Viewer1D.js +26 -21
  3. package/lib/component/1d/database/DatabaseSpectrum.js +2 -1
  4. package/lib/component/1d/integral/Integral.d.ts +2 -6
  5. package/lib/component/1d/integral/IntegralResizable.d.ts +2 -6
  6. package/lib/component/1d/integral/IntegralResizable.js +2 -3
  7. package/lib/component/1d/multiAnalysis/MultiAnalysisRanges.js +1 -1
  8. package/lib/component/1d/multiplicityTree/MultiplicityTree.js +7 -9
  9. package/lib/component/1d/peaks/PeakAnnotation.js +1 -2
  10. package/lib/component/1d/ranges/Range.js +9 -8
  11. package/lib/component/1d/ranges/Ranges.js +5 -7
  12. package/lib/component/1d/tool/BaseLineZones.js +1 -2
  13. package/lib/component/1d-2d/components/FloatMoleculeStructures/DraggableStructure.js +4 -5
  14. package/lib/component/1d-2d/components/FloatMoleculeStructures/index.js +13 -17
  15. package/lib/component/2d/1d-tracer/Left1DChart.js +1 -1
  16. package/lib/component/2d/1d-tracer/VerticalSliceChart.js +1 -1
  17. package/lib/component/2d/Chart2D.js +1 -1
  18. package/lib/component/2d/Viewer2D.js +10 -9
  19. package/lib/component/2d/fid/FidCanvas.js +4 -6
  20. package/lib/component/2d/ft/Contours.js +1 -1
  21. package/lib/component/2d/utilities/DimensionLayout.d.ts +9 -24
  22. package/lib/component/2d/utilities/scale.d.ts +2 -1
  23. package/lib/component/2d/utilities/scale.js +1 -1
  24. package/lib/component/2d/zones/Zones.js +1 -1
  25. package/lib/component/EventsTrackers/KeysListenerTracker.js +28 -21
  26. package/lib/component/NMRium.js +15 -7
  27. package/lib/component/assignment/AssignmentsReducer.d.ts +1 -1
  28. package/lib/component/context/DispatchContext.d.ts +23 -3
  29. package/lib/component/context/DispatchContext.js +1 -1
  30. package/lib/component/context/LoggerContext.js +1 -1
  31. package/lib/component/elements/Button.js +7 -9
  32. package/lib/component/elements/IsotopesViewer.js +1 -1
  33. package/lib/component/elements/ReactTable/ReactTable.js +1 -2
  34. package/lib/component/elements/formik/FormikCheckBox.js +1 -1
  35. package/lib/component/elements/formik/FormikColorInput.js +1 -1
  36. package/lib/component/elements/formik/FormikColorPicker.js +1 -1
  37. package/lib/component/elements/formik/FormikColumnFormatField.js +1 -1
  38. package/lib/component/elements/formik/FormikInput.js +1 -1
  39. package/lib/component/elements/formik/FormikSelect.js +2 -2
  40. package/lib/component/elements/formik/FormikSlider.js +1 -1
  41. package/lib/component/elements/formik/FormikTextarea.js +2 -2
  42. package/lib/component/header/ApodizationOptionsPanel.js +4 -5
  43. package/lib/component/header/AutoPeakPickingOptionPanel.js +1 -2
  44. package/lib/component/header/BaseLineCorrectionPanel.js +4 -5
  45. package/lib/component/header/Header.js +4 -6
  46. package/lib/component/header/PhaseCorrectionPanel.js +7 -8
  47. package/lib/component/header/RangesPickingOptionPanel.js +1 -2
  48. package/lib/component/header/ZeroFillingOptionsPanel.js +3 -11
  49. package/lib/component/header/Zones2DOptionPanel.js +5 -6
  50. package/lib/component/hooks/useExport.js +1 -0
  51. package/lib/component/hooks/useToolsFunctions.js +8 -10
  52. package/lib/component/loader/DropZone.js +4 -5
  53. package/lib/component/loader/NoData.js +1 -1
  54. package/lib/component/modal/AlignSpectraModal.js +1 -2
  55. package/lib/component/modal/EditPeakShapeModal.js +1 -2
  56. package/lib/component/modal/ImportPublicationStringModal.js +1 -2
  57. package/lib/component/modal/LoadJCAMPModal.js +2 -3
  58. package/lib/component/modal/MoleculeStructureEditorModal.js +24 -19
  59. package/lib/component/modal/PredictSpectraModal.d.ts +1 -1
  60. package/lib/component/modal/PredictSpectraModal.js +24 -21
  61. package/lib/component/modal/changeSum/SelectMolecule.js +1 -1
  62. package/lib/component/modal/editRange/EditRangeModal.js +3 -4
  63. package/lib/component/modal/editRange/forms/components/AddSignalFormTab.js +2 -2
  64. package/lib/component/modal/editRange/forms/components/CouplingsTable.js +1 -1
  65. package/lib/component/modal/metaImportation/MetaImportationModal.js +2 -3
  66. package/lib/component/modal/setting/settings-tabs/DatabasesTabContent.js +4 -4
  67. package/lib/component/modal/setting/settings-tabs/FormattingTabContent.js +2 -2
  68. package/lib/component/modal/setting/settings-tabs/InfoBlockTabContent.js +2 -2
  69. package/lib/component/panels/AutomaticAssignment/AutomaticAssignmentTable.js +1 -2
  70. package/lib/component/panels/AutomaticAssignment/useAutoAssignments.js +7 -6
  71. package/lib/component/panels/InformationPanel.js +6 -6
  72. package/lib/component/panels/IntegralsPanel/IntegralPanel.js +11 -20
  73. package/lib/component/panels/IntegralsPanel/IntegralTable.js +10 -10
  74. package/lib/component/panels/MatrixGenerationPanel/ExclusionsZonesTable.js +1 -1
  75. package/lib/component/panels/MatrixGenerationPanel/FiltersOptions.js +4 -4
  76. package/lib/component/panels/MatrixGenerationPanel/MatrixGenerationPanel.js +1 -2
  77. package/lib/component/panels/MoleculesPanel/MoleculeHeader.js +1 -2
  78. package/lib/component/panels/MoleculesPanel/MoleculePanel.js +10 -13
  79. package/lib/component/panels/MoleculesPanel/MoleculePanelHeader.js +5 -6
  80. package/lib/component/panels/MoleculesPanel/Utilities.d.ts +4 -1
  81. package/lib/component/panels/MoleculesPanel/Utilities.js +2 -2
  82. package/lib/component/panels/MoleculesPanel/useAtomAssignment.js +8 -9
  83. package/lib/component/panels/MultipleSpectraAnalysisPanel/MultipleSpectraAnalysisPanel.js +3 -4
  84. package/lib/component/panels/MultipleSpectraAnalysisPanel/MultipleSpectraAnalysisTable.js +1 -2
  85. package/lib/component/panels/MultipleSpectraAnalysisPanel/preferences/AnalysisTablePreferences.js +2 -2
  86. package/lib/component/panels/MultipleSpectraAnalysisPanel/preferences/LegendsPreferences.js +2 -2
  87. package/lib/component/panels/MultipleSpectraAnalysisPanel/preferences/MultipleAnalysisCodeEditor.js +1 -1
  88. package/lib/component/panels/Panels.js +1 -1
  89. package/lib/component/panels/PeaksPanel/PeaksPanel.js +4 -5
  90. package/lib/component/panels/PeaksPanel/PeaksTable.js +4 -5
  91. package/lib/component/panels/RangesPanel/RangesHeader.js +12 -15
  92. package/lib/component/panels/RangesPanel/RangesPanel.js +24 -29
  93. package/lib/component/panels/RangesPanel/TableColumns/RangeAssignmentsColumn.js +1 -1
  94. package/lib/component/panels/RangesPanel/TableColumns/RelativeColumn.js +3 -3
  95. package/lib/component/panels/RangesPanel/TableColumns/SignalDeltaColumn.js +1 -2
  96. package/lib/component/panels/RangesPanel/hooks/useEditRangeModal.d.ts +1 -1
  97. package/lib/component/panels/RangesPanel/hooks/useEditRangeModal.js +16 -14
  98. package/lib/component/panels/SpectrumsPanel/SpectraPanelHeader.js +16 -16
  99. package/lib/component/panels/SpectrumsPanel/SpectraTable.js +7 -5
  100. package/lib/component/panels/SpectrumsPanel/SpectrumsTabs.js +4 -5
  101. package/lib/component/panels/SpectrumsPanel/base/ShowHideSpectrumButton.js +3 -7
  102. package/lib/component/panels/SpectrumsPanel/base/setting/SpectrumSetting.js +4 -2
  103. package/lib/component/panels/SpectrumsPanel/base/setting/processSnapPlot.js +2 -2
  104. package/lib/component/panels/SummaryPanel/CorrelationTable/CorrelationTableRow.js +4 -8
  105. package/lib/component/panels/SummaryPanel/SummaryPanel.js +39 -34
  106. package/lib/component/panels/SummaryPanel/utilities/Utilities.js +1 -1
  107. package/lib/component/panels/ZonesPanel/TableColumns/ActionsColumn.d.ts +2 -13
  108. package/lib/component/panels/ZonesPanel/TableColumns/ActionsColumn.js +22 -20
  109. package/lib/component/panels/ZonesPanel/TableColumns/SignalAssignmentsColumn.d.ts +2 -2
  110. package/lib/component/panels/ZonesPanel/TableColumns/SignalAssignmentsColumn.js +1 -1
  111. package/lib/component/panels/ZonesPanel/TableColumns/SignalAssignmentsColumns.d.ts +2 -2
  112. package/lib/component/panels/ZonesPanel/TableColumns/SignalDeltaColumn.d.ts +2 -2
  113. package/lib/component/panels/ZonesPanel/TableColumns/SignalDeltaColumn.js +6 -7
  114. package/lib/component/panels/ZonesPanel/TableColumns/ZoneAssignmentsColumn.d.ts +2 -2
  115. package/lib/component/panels/ZonesPanel/TableColumns/ZoneAssignmentsColumn.js +1 -1
  116. package/lib/component/panels/ZonesPanel/TableColumns/ZoneAssignmentsColumns.d.ts +2 -2
  117. package/lib/component/panels/ZonesPanel/ZonesPanel.js +15 -18
  118. package/lib/component/panels/ZonesPanel/ZonesTable.js +2 -51
  119. package/lib/component/panels/ZonesPanel/ZonesTableRow.d.ts +3 -3
  120. package/lib/component/panels/ZonesPanel/hooks/useMapZones.d.ts +16 -0
  121. package/lib/component/panels/ZonesPanel/hooks/useMapZones.js +52 -0
  122. package/lib/component/panels/databasePanel/DatabasePanel.js +15 -11
  123. package/lib/component/panels/filtersPanel/FilterPanel.js +1 -2
  124. package/lib/component/panels/filtersPanel/FiltersTable.js +8 -9
  125. package/lib/component/panels/header/DefaultPanelHeader.js +1 -1
  126. package/lib/component/panels/header/SpectraAutomaticPickingButton.js +2 -3
  127. package/lib/component/panels/predictionPanel/PredictionPanel.js +4 -5
  128. package/lib/component/reducer/IgnoreActions.d.ts +2 -1
  129. package/lib/component/reducer/IgnoreActions.js +35 -32
  130. package/lib/component/reducer/Reducer.d.ts +8 -5
  131. package/lib/component/reducer/Reducer.js +202 -220
  132. package/lib/component/reducer/actions/AssignmentsActions.d.ts +7 -6
  133. package/lib/component/reducer/actions/AssignmentsActions.js +2 -2
  134. package/lib/component/reducer/actions/CorrelationsActions.d.ts +21 -13
  135. package/lib/component/reducer/actions/CorrelationsActions.js +25 -20
  136. package/lib/component/reducer/actions/DatabaseActions.d.ts +15 -2
  137. package/lib/component/reducer/actions/DatabaseActions.js +5 -2
  138. package/lib/component/reducer/actions/DimensionsActions.d.ts +8 -3
  139. package/lib/component/reducer/actions/DimensionsActions.js +3 -5
  140. package/lib/component/reducer/actions/DomainActions.d.ts +11 -5
  141. package/lib/component/reducer/actions/DomainActions.js +13 -19
  142. package/lib/component/reducer/actions/FiltersActions.d.ts +70 -23
  143. package/lib/component/reducer/actions/FiltersActions.js +250 -255
  144. package/lib/component/reducer/actions/GlobalActions.d.ts +7 -2
  145. package/lib/component/reducer/actions/GlobalActions.js +3 -3
  146. package/lib/component/reducer/actions/IntegralsActions.d.ts +28 -7
  147. package/lib/component/reducer/actions/IntegralsActions.js +16 -15
  148. package/lib/component/reducer/actions/LoadActions.d.ts +23 -5
  149. package/lib/component/reducer/actions/LoadActions.js +52 -52
  150. package/lib/component/reducer/actions/MoleculeActions.d.ts +38 -9
  151. package/lib/component/reducer/actions/MoleculeActions.js +27 -18
  152. package/lib/component/reducer/actions/PeaksActions.d.ts +39 -8
  153. package/lib/component/reducer/actions/PeaksActions.js +19 -11
  154. package/lib/component/reducer/actions/PreferencesActions.d.ts +8 -3
  155. package/lib/component/reducer/actions/PreferencesActions.js +5 -3
  156. package/lib/component/reducer/actions/RangesActions.d.ts +85 -18
  157. package/lib/component/reducer/actions/RangesActions.js +80 -65
  158. package/lib/component/reducer/actions/SpectraAnalysisAction.d.ts +7 -1
  159. package/lib/component/reducer/actions/SpectrumsActions.d.ts +57 -24
  160. package/lib/component/reducer/actions/SpectrumsActions.js +69 -60
  161. package/lib/component/reducer/actions/ToolsActions.d.ts +59 -21
  162. package/lib/component/reducer/actions/ToolsActions.js +54 -32
  163. package/lib/component/reducer/actions/ZonesActions.d.ts +79 -15
  164. package/lib/component/reducer/actions/ZonesActions.js +68 -49
  165. package/lib/component/reducer/helper/Zoom1DManager.d.ts +6 -5
  166. package/lib/component/reducer/helper/Zoom1DManager.js +1 -1
  167. package/lib/component/reducer/helper/ZoomHistoryManager.js +2 -2
  168. package/lib/component/reducer/helper/get2DRange.d.ts +7 -1
  169. package/lib/component/reducer/preferences/preferencesReducer.d.ts +1 -1
  170. package/lib/component/reducer/types/ActionType.d.ts +6 -0
  171. package/lib/component/reducer/types/ActionType.js +1 -0
  172. package/lib/component/toolbar/BasicToolBar.js +6 -9
  173. package/lib/component/toolbar/FunctionToolBar.js +4 -9
  174. package/lib/component/toolbar/ToolBar.js +1 -1
  175. package/lib/component/toolbar/ToolTypes.d.ts +2 -2
  176. package/lib/component/utility/Events.d.ts +4 -4
  177. package/lib/component/utility/Events.js +2 -2
  178. package/lib/component/utility/GroupByInfoKey.js +1 -1
  179. package/lib/component/utility/getSpectraObjectPaths.js +1 -1
  180. package/lib/data/PredictionManager.d.ts +7 -9
  181. package/lib/data/PredictionManager.js +3 -3
  182. package/lib/data/data1d/Spectrum1D/getSpectrumErrorValue.js +1 -1
  183. package/lib/data/data1d/Spectrum1D/initiateDatum1D.js +1 -1
  184. package/lib/data/data1d/Spectrum1D/ranges/changeRangeRelativeValue.d.ts +2 -3
  185. package/lib/data/data1d/Spectrum1D/ranges/changeRangeRelativeValue.js +5 -4
  186. package/lib/data/data1d/Spectrum1D/ranges/generateSpectrumFromRanges.d.ts +5 -3
  187. package/lib/data/data1d/Spectrum1D/ranges/initiateRanges.d.ts +1 -35
  188. package/lib/data/data1d/Spectrum1D/ranges/mapRanges.d.ts +2 -35
  189. package/lib/data/data1d/filter1d/baselineCorrection.d.ts +7 -10
  190. package/lib/data/data1d/multipleSpectraAnalysis.d.ts +1 -1
  191. package/lib/data/data2d/Spectrum2D/initiateDatum2D.js +1 -1
  192. package/lib/data/data2d/Spectrum2D/zones/changeZoneSignal.d.ts +5 -1
  193. package/lib/data/data2d/Spectrum2D/zones/changeZoneSignal.js +6 -8
  194. package/lib/data/data2d/Spectrum2D/zones/detectZonesManual.d.ts +2 -0
  195. package/lib/data/data2d/Spectrum2D/zones/initiateZones.d.ts +2 -0
  196. package/lib/data/data2d/Spectrum2D/zones/mapZones.d.ts +2 -0
  197. package/lib/data/matrixGeneration.js +4 -2
  198. package/lib/data/molecules/Molecule.d.ts +3 -3
  199. package/lib/data/molecules/MoleculeManager.d.ts +5 -5
  200. package/lib/data/molecules/MoleculeManager.js +1 -1
  201. package/lib/data/utilities/generateColor.js +1 -1
  202. package/lib/data/utilities/isNumber.d.ts +1 -0
  203. package/lib/data/utilities/isNumber.js +3 -0
  204. package/lib/versionInfo.js +1 -1
  205. package/lib-cjs/component/1d/FooterBanner.js +1 -1
  206. package/lib-cjs/component/1d/Viewer1D.js +25 -20
  207. package/lib-cjs/component/1d/database/DatabaseSpectrum.js +2 -1
  208. package/lib-cjs/component/1d/integral/IntegralResizable.js +2 -3
  209. package/lib-cjs/component/1d/multiAnalysis/MultiAnalysisRanges.js +1 -1
  210. package/lib-cjs/component/1d/multiplicityTree/MultiplicityTree.js +7 -9
  211. package/lib-cjs/component/1d/peaks/PeakAnnotation.js +1 -2
  212. package/lib-cjs/component/1d/ranges/Range.js +9 -8
  213. package/lib-cjs/component/1d/ranges/Ranges.js +5 -7
  214. package/lib-cjs/component/1d/tool/BaseLineZones.js +1 -2
  215. package/lib-cjs/component/1d-2d/components/FloatMoleculeStructures/DraggableStructure.js +4 -5
  216. package/lib-cjs/component/1d-2d/components/FloatMoleculeStructures/index.js +13 -17
  217. package/lib-cjs/component/2d/1d-tracer/Left1DChart.js +1 -1
  218. package/lib-cjs/component/2d/1d-tracer/VerticalSliceChart.js +1 -1
  219. package/lib-cjs/component/2d/Chart2D.js +1 -1
  220. package/lib-cjs/component/2d/Viewer2D.js +10 -9
  221. package/lib-cjs/component/2d/fid/FidCanvas.js +4 -6
  222. package/lib-cjs/component/2d/ft/Contours.js +1 -1
  223. package/lib-cjs/component/2d/utilities/scale.js +1 -1
  224. package/lib-cjs/component/2d/zones/Zones.js +1 -1
  225. package/lib-cjs/component/EventsTrackers/KeysListenerTracker.js +28 -21
  226. package/lib-cjs/component/NMRium.js +15 -7
  227. package/lib-cjs/component/context/DispatchContext.js +1 -1
  228. package/lib-cjs/component/context/LoggerContext.js +1 -1
  229. package/lib-cjs/component/elements/Button.js +7 -9
  230. package/lib-cjs/component/elements/IsotopesViewer.js +1 -1
  231. package/lib-cjs/component/elements/ReactTable/ReactTable.js +1 -2
  232. package/lib-cjs/component/elements/Tab/Tabs.js +1 -1
  233. package/lib-cjs/component/elements/formik/FormikCheckBox.js +1 -1
  234. package/lib-cjs/component/elements/formik/FormikColorInput.js +1 -1
  235. package/lib-cjs/component/elements/formik/FormikColorPicker.js +1 -1
  236. package/lib-cjs/component/elements/formik/FormikColumnFormatField.js +1 -1
  237. package/lib-cjs/component/elements/formik/FormikInput.js +1 -1
  238. package/lib-cjs/component/elements/formik/FormikSelect.js +2 -2
  239. package/lib-cjs/component/elements/formik/FormikSlider.js +1 -1
  240. package/lib-cjs/component/elements/formik/FormikTextarea.js +2 -2
  241. package/lib-cjs/component/header/ApodizationOptionsPanel.js +3 -4
  242. package/lib-cjs/component/header/AutoPeakPickingOptionPanel.js +1 -2
  243. package/lib-cjs/component/header/BaseLineCorrectionPanel.js +4 -5
  244. package/lib-cjs/component/header/Header.js +4 -6
  245. package/lib-cjs/component/header/PhaseCorrectionPanel.js +7 -8
  246. package/lib-cjs/component/header/RangesPickingOptionPanel.js +1 -2
  247. package/lib-cjs/component/header/ZeroFillingOptionsPanel.js +3 -11
  248. package/lib-cjs/component/header/Zones2DOptionPanel.js +5 -6
  249. package/lib-cjs/component/highlight/index.js +1 -1
  250. package/lib-cjs/component/hooks/useExport.js +1 -0
  251. package/lib-cjs/component/hooks/useTableSortBy.js +1 -1
  252. package/lib-cjs/component/hooks/useToolsFunctions.js +8 -10
  253. package/lib-cjs/component/hooks/useXYReduce.js +1 -1
  254. package/lib-cjs/component/loader/DropZone.js +4 -5
  255. package/lib-cjs/component/loader/NoData.js +1 -1
  256. package/lib-cjs/component/modal/AlignSpectraModal.js +1 -2
  257. package/lib-cjs/component/modal/EditPeakShapeModal.js +1 -2
  258. package/lib-cjs/component/modal/ImportPublicationStringModal.js +1 -2
  259. package/lib-cjs/component/modal/LoadJCAMPModal.js +2 -3
  260. package/lib-cjs/component/modal/MoleculeStructureEditorModal.js +24 -19
  261. package/lib-cjs/component/modal/PredictSpectraModal.js +24 -21
  262. package/lib-cjs/component/modal/changeSum/SelectMolecule.js +1 -1
  263. package/lib-cjs/component/modal/editRange/EditRangeModal.js +3 -4
  264. package/lib-cjs/component/modal/editRange/forms/components/AddSignalFormTab.js +2 -2
  265. package/lib-cjs/component/modal/editRange/forms/components/CouplingsTable.js +1 -1
  266. package/lib-cjs/component/modal/metaImportation/MetaImportationModal.js +2 -3
  267. package/lib-cjs/component/modal/setting/settings-tabs/DatabasesTabContent.js +4 -4
  268. package/lib-cjs/component/modal/setting/settings-tabs/FormattingTabContent.js +2 -2
  269. package/lib-cjs/component/modal/setting/settings-tabs/InfoBlockTabContent.js +2 -2
  270. package/lib-cjs/component/panels/AutomaticAssignment/AutomaticAssignmentTable.js +1 -2
  271. package/lib-cjs/component/panels/AutomaticAssignment/useAutoAssignments.js +7 -6
  272. package/lib-cjs/component/panels/InformationPanel.js +6 -6
  273. package/lib-cjs/component/panels/IntegralsPanel/IntegralPanel.js +11 -20
  274. package/lib-cjs/component/panels/IntegralsPanel/IntegralTable.js +10 -10
  275. package/lib-cjs/component/panels/MatrixGenerationPanel/ExclusionsZonesTable.js +1 -1
  276. package/lib-cjs/component/panels/MatrixGenerationPanel/FiltersOptions.js +4 -4
  277. package/lib-cjs/component/panels/MatrixGenerationPanel/MatrixGenerationPanel.js +1 -2
  278. package/lib-cjs/component/panels/MoleculesPanel/MoleculeHeader.js +1 -2
  279. package/lib-cjs/component/panels/MoleculesPanel/MoleculePanel.js +10 -13
  280. package/lib-cjs/component/panels/MoleculesPanel/MoleculePanelHeader.js +5 -6
  281. package/lib-cjs/component/panels/MoleculesPanel/Utilities.js +2 -2
  282. package/lib-cjs/component/panels/MoleculesPanel/useAtomAssignment.js +8 -9
  283. package/lib-cjs/component/panels/MultipleSpectraAnalysisPanel/MultipleSpectraAnalysisPanel.js +3 -4
  284. package/lib-cjs/component/panels/MultipleSpectraAnalysisPanel/MultipleSpectraAnalysisTable.js +1 -2
  285. package/lib-cjs/component/panels/MultipleSpectraAnalysisPanel/preferences/AnalysisTablePreferences.js +2 -2
  286. package/lib-cjs/component/panels/MultipleSpectraAnalysisPanel/preferences/LegendsPreferences.js +2 -2
  287. package/lib-cjs/component/panels/MultipleSpectraAnalysisPanel/preferences/MultipleAnalysisCodeEditor.js +1 -1
  288. package/lib-cjs/component/panels/Panels.js +1 -1
  289. package/lib-cjs/component/panels/PeaksPanel/PeaksPanel.js +4 -5
  290. package/lib-cjs/component/panels/PeaksPanel/PeaksTable.js +4 -5
  291. package/lib-cjs/component/panels/RangesPanel/RangesHeader.js +12 -15
  292. package/lib-cjs/component/panels/RangesPanel/RangesPanel.js +24 -29
  293. package/lib-cjs/component/panels/RangesPanel/TableColumns/RangeAssignmentsColumn.js +1 -1
  294. package/lib-cjs/component/panels/RangesPanel/TableColumns/RelativeColumn.js +3 -3
  295. package/lib-cjs/component/panels/RangesPanel/TableColumns/SignalDeltaColumn.js +1 -2
  296. package/lib-cjs/component/panels/RangesPanel/hooks/useEditRangeModal.js +16 -14
  297. package/lib-cjs/component/panels/SpectrumsPanel/SpectraPanelHeader.js +16 -16
  298. package/lib-cjs/component/panels/SpectrumsPanel/SpectraTable.js +7 -5
  299. package/lib-cjs/component/panels/SpectrumsPanel/SpectrumsTabs.js +4 -5
  300. package/lib-cjs/component/panels/SpectrumsPanel/base/ShowHideSpectrumButton.js +3 -7
  301. package/lib-cjs/component/panels/SpectrumsPanel/base/setting/SpectrumSetting.js +4 -2
  302. package/lib-cjs/component/panels/SpectrumsPanel/base/setting/processSnapPlot.js +2 -2
  303. package/lib-cjs/component/panels/SummaryPanel/CorrelationTable/CorrelationTableRow.js +4 -8
  304. package/lib-cjs/component/panels/SummaryPanel/SummaryPanel.js +39 -34
  305. package/lib-cjs/component/panels/SummaryPanel/utilities/Utilities.js +1 -1
  306. package/lib-cjs/component/panels/ZonesPanel/TableColumns/ActionsColumn.js +22 -20
  307. package/lib-cjs/component/panels/ZonesPanel/TableColumns/SignalAssignmentsColumn.js +1 -1
  308. package/lib-cjs/component/panels/ZonesPanel/TableColumns/SignalDeltaColumn.js +6 -7
  309. package/lib-cjs/component/panels/ZonesPanel/TableColumns/ZoneAssignmentsColumn.js +1 -1
  310. package/lib-cjs/component/panels/ZonesPanel/ZonesPanel.js +15 -18
  311. package/lib-cjs/component/panels/ZonesPanel/ZonesTable.js +2 -51
  312. package/lib-cjs/component/panels/ZonesPanel/hooks/useMapZones.js +56 -0
  313. package/lib-cjs/component/panels/databasePanel/DatabasePanel.js +14 -10
  314. package/lib-cjs/component/panels/filtersPanel/FilterPanel.js +1 -2
  315. package/lib-cjs/component/panels/filtersPanel/FiltersTable.js +8 -9
  316. package/lib-cjs/component/panels/header/DefaultPanelHeader.js +1 -1
  317. package/lib-cjs/component/panels/header/SpectraAutomaticPickingButton.js +2 -3
  318. package/lib-cjs/component/panels/predictionPanel/PredictionPanel.js +4 -5
  319. package/lib-cjs/component/reducer/IgnoreActions.js +35 -55
  320. package/lib-cjs/component/reducer/Reducer.js +202 -220
  321. package/lib-cjs/component/reducer/actions/AssignmentsActions.js +3 -3
  322. package/lib-cjs/component/reducer/actions/CorrelationsActions.js +23 -18
  323. package/lib-cjs/component/reducer/actions/DatabaseActions.js +4 -1
  324. package/lib-cjs/component/reducer/actions/DimensionsActions.js +3 -6
  325. package/lib-cjs/component/reducer/actions/DomainActions.js +15 -23
  326. package/lib-cjs/component/reducer/actions/FiltersActions.js +267 -272
  327. package/lib-cjs/component/reducer/actions/GlobalActions.js +4 -4
  328. package/lib-cjs/component/reducer/actions/IntegralsActions.js +19 -18
  329. package/lib-cjs/component/reducer/actions/LoadActions.js +55 -55
  330. package/lib-cjs/component/reducer/actions/MoleculeActions.js +31 -22
  331. package/lib-cjs/component/reducer/actions/PeaksActions.js +23 -15
  332. package/lib-cjs/component/reducer/actions/PreferencesActions.js +7 -5
  333. package/lib-cjs/component/reducer/actions/RangesActions.js +81 -64
  334. package/lib-cjs/component/reducer/actions/SpectrumsActions.js +77 -67
  335. package/lib-cjs/component/reducer/actions/ToolsActions.js +54 -31
  336. package/lib-cjs/component/reducer/actions/ZonesActions.js +73 -52
  337. package/lib-cjs/component/reducer/core/Constants.js +1 -1
  338. package/lib-cjs/component/reducer/helper/Zoom1DManager.js +2 -2
  339. package/lib-cjs/component/reducer/helper/ZoomHistoryManager.js +2 -2
  340. package/lib-cjs/component/reducer/types/ActionType.js +2 -0
  341. package/lib-cjs/component/toolbar/BasicToolBar.js +6 -9
  342. package/lib-cjs/component/toolbar/FunctionToolBar.js +4 -9
  343. package/lib-cjs/component/toolbar/ToolBar.js +1 -1
  344. package/lib-cjs/component/utility/GroupByInfoKey.js +1 -1
  345. package/lib-cjs/component/utility/getSpectraObjectPaths.js +1 -1
  346. package/lib-cjs/data/PredictionManager.js +3 -3
  347. package/lib-cjs/data/SpectraManager.js +1 -1
  348. package/lib-cjs/data/data1d/Spectrum1D/getSpectrumErrorValue.js +1 -1
  349. package/lib-cjs/data/data1d/Spectrum1D/initiateDatum1D.js +1 -1
  350. package/lib-cjs/data/data1d/Spectrum1D/ranges/changeRangeRelativeValue.js +5 -4
  351. package/lib-cjs/data/data1d/multipleSpectraAnalysis.js +2 -2
  352. package/lib-cjs/data/data2d/Spectrum2D/initiateDatum2D.js +1 -1
  353. package/lib-cjs/data/data2d/Spectrum2D/zones/changeZoneSignal.js +6 -8
  354. package/lib-cjs/data/matrixGeneration.js +4 -2
  355. package/lib-cjs/data/molecules/MoleculeManager.js +1 -1
  356. package/lib-cjs/data/utilities/generateColor.js +1 -1
  357. package/lib-cjs/data/utilities/isNumber.js +7 -0
  358. package/lib-cjs/versionInfo.js +1 -1
  359. package/package.json +24 -23
  360. package/lib/component/reducer/actions/HistoryActions.d.ts +0 -4
  361. package/lib/component/reducer/actions/HistoryActions.js +0 -40
  362. package/lib/component/reducer/types/HistoryTypes.d.ts +0 -4
  363. package/lib/component/reducer/types/HistoryTypes.js +0 -4
  364. package/lib/component/reducer/types/Types.d.ts +0 -132
  365. package/lib/component/reducer/types/Types.js +0 -126
  366. package/lib/component/toolbar/HistoryToolBar.d.ts +0 -8
  367. package/lib/component/toolbar/HistoryToolBar.js +0 -30
  368. package/lib/data/utilities/isMolFileEmpty.d.ts +0 -1
  369. package/lib/data/utilities/isMolFileEmpty.js +0 -6
  370. package/lib-cjs/component/reducer/actions/HistoryActions.js +0 -45
  371. package/lib-cjs/component/reducer/types/HistoryTypes.js +0 -7
  372. package/lib-cjs/component/reducer/types/Types.js +0 -131
  373. package/lib-cjs/component/toolbar/HistoryToolBar.js +0 -35
  374. package/lib-cjs/data/utilities/isMolFileEmpty.js +0 -10
@@ -1,38 +1,41 @@
1
- import * as types from './types/Types';
2
1
  const ignoreActions = new Set([
3
- types.APPLY_KEY_PREFERENCES,
4
- types.BRUSH_END,
5
- types.RESET_DOMAIN,
6
- types.RESET_SELECTED_TOOL,
7
- types.SET_KEY_PREFERENCES,
8
- types.SET_LOADING_FLAG,
9
- types.SET_ORIGINAL_DOMAIN,
10
- types.SET_SELECTED_FILTER,
11
- types.SET_SELECTED_TOOL,
12
- types.SET_SPECTRUMS_VERTICAL_ALIGN,
13
- types.SET_VERTICAL_INDICATOR_X_POSITION,
14
- types.SET_WIDTH,
15
- types.SET_DIMENSIONS,
16
- types.SET_X_DOMAIN,
17
- types.SET_Y_DOMAIN,
18
- types.SET_ZOOM,
19
- types.TOGGLE_REAL_IMAGINARY_VISIBILITY,
20
- types.CALCULATE_MANUAL_PHASE_CORRECTION_FILTER,
21
- types.CHANGE_SPECTRUM_DISPLAY_VIEW_MODE,
22
- types.FULL_ZOOM_OUT,
23
- types.SAVE_AS_SVG,
24
- types.SET_ACTIVE_TAB,
25
- types.CHANGE_VISIBILITY,
26
- types.CHANGE_ACTIVE_SPECTRUM,
27
- types.CHANGE_SPECTRUM_COLOR,
28
- types.SET_MOUSE_OVER_DISPLAYER,
29
- types.SHOW_J_GRAPH,
30
- types.SHOW_MULTIPLICITY_TREES,
31
- types.SHOW_RANGES_INTEGRALS,
32
- types.CHANGE_FLOAT_MOLECULE_POSITION,
2
+ 'INITIALIZE_NMRIUM',
3
+ 'APPLY_KEY_PREFERENCES',
4
+ 'BRUSH_END',
5
+ 'RESET_SELECTED_TOOL',
6
+ 'SET_KEY_PREFERENCES',
7
+ 'SET_LOADING_FLAG',
8
+ 'SET_SELECTED_TOOL',
9
+ 'SET_SPECTRUMS_VERTICAL_ALIGN',
10
+ 'SET_VERTICAL_INDICATOR_X_POSITION',
11
+ 'SET_DIMENSIONS',
12
+ 'SET_X_DOMAIN',
13
+ 'SET_Y_DOMAIN',
14
+ 'SET_ZOOM',
15
+ 'CALCULATE_MANUAL_PHASE_CORRECTION_FILTER',
16
+ 'CHANGE_SPECTRUM_DISPLAY_VIEW_MODE',
17
+ 'FULL_ZOOM_OUT',
18
+ 'SET_ACTIVE_TAB',
19
+ 'CHANGE_SPECTRUM_VISIBILITY',
20
+ 'CHANGE_SPECTRA_VISIBILITY_BY_NUCLEUS',
21
+ 'CHANGE_ACTIVE_SPECTRUM',
22
+ 'SET_MOUSE_OVER_DISPLAYER',
23
+ 'CHANGE_FLOAT_MOLECULE_POSITION',
24
+ 'ALIGN_SPECTRA',
25
+ 'TOGGLE_REAL_IMAGINARY_VISIBILITY',
26
+ 'FLOAT_MOLECULE_OVER_SPECTRUM',
27
+ 'TOGGLE_SPECTRA_LEGEND',
28
+ 'TOGGLE_PEAKS_VIEW_PROPERTY',
29
+ 'TOGGLE_MOLECULE_ATOM_NUMBER',
30
+ 'SHOW_J_GRAPH',
31
+ 'SHOW_MULTIPLICITY_TREES',
32
+ 'SHOW_RANGES_INTEGRALS',
33
+ 'SHOW_ZONES',
34
+ 'SHOW_ZONES_PEAKS',
35
+ 'SHOW_ZONES_SIGNALS',
33
36
  ]);
34
37
  function checkActionType(type) {
35
- if (!ignoreActions.has(type))
38
+ if (!ignoreActions?.has(type))
36
39
  return true;
37
40
  return false;
38
41
  }
@@ -2,11 +2,14 @@ import { CorrelationData } from 'nmr-correlation';
2
2
  import { Source, Spectrum } from 'nmr-load-save';
3
3
  import { Reducer } from 'react';
4
4
  import { ApodizationOptions } from '../../data/data1d/filter1d/apodization';
5
+ import { BaselineCorrectionZone } from '../../data/data1d/filter1d/baselineCorrection';
5
6
  import { ContoursLevels } from '../../data/data2d/Spectrum2D/contours';
6
7
  import { MoleculesView, StateMoleculeExtended } from '../../data/molecules/Molecule';
7
8
  import { Nuclei } from '../../data/types/common/Nucleus';
8
9
  import { PeaksViewState } from '../../data/types/view-state/PeaksViewState';
9
10
  import { UsedColors } from '../../types/UsedColors';
11
+ import { Action, Dispatch } from '../context/DispatchContext';
12
+ import { Tool } from '../toolbar/ToolTypes';
10
13
  import { DISPLAYER_MODE } from './core/Constants';
11
14
  import { ZoomHistory } from './helper/ZoomHistoryManager';
12
15
  export interface ActiveSpectrum {
@@ -115,7 +118,7 @@ export interface State {
115
118
  * Last action type
116
119
  * base on the action type we can decide to trigger or not the callback function (onDataChange)
117
120
  */
118
- actionType: string;
121
+ actionType: Action['type'];
119
122
  /**
120
123
  * web source of data
121
124
  */
@@ -253,7 +256,7 @@ export interface State {
253
256
  * The current selected tool
254
257
  * @default `options.zoom.id`
255
258
  */
256
- selectedTool: string;
259
+ selectedTool: Tool;
257
260
  /**
258
261
  * The current active options panel
259
262
  * Part of tools has an options panel for more control over the tool, once the user select the tool then the options panel will be shown in the header
@@ -268,7 +271,7 @@ export interface State {
268
271
  * list of zones for Baseline correction filter
269
272
  */
270
273
  baselineCorrection: {
271
- zones: any[];
274
+ zones: BaselineCorrectionZone[];
272
275
  options: any;
273
276
  };
274
277
  apodizationOptions: ApodizationOptions;
@@ -300,6 +303,6 @@ export interface State {
300
303
  usedColors: UsedColors;
301
304
  }
302
305
  export declare function initState(state: State): State;
303
- export declare function dispatchMiddleware(dispatch: any): (action: any) => void;
304
- export declare const spectrumReducer: Reducer<State, any>;
306
+ export declare function dispatchMiddleware(dispatch: Dispatch): (action: Action) => void;
307
+ export declare const spectrumReducer: Reducer<State, Action>;
305
308
  export {};