nmrium 2.4.0 → 2.5.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.
Files changed (277) hide show
  1. package/lib/component/1d/HorizontalAxis1D.d.ts.map +1 -1
  2. package/lib/component/1d/HorizontalAxis1D.js +4 -1
  3. package/lib/component/1d/HorizontalAxis1D.js.map +1 -1
  4. package/lib/component/1d/SVGContent1D.d.ts.map +1 -1
  5. package/lib/component/1d/SVGContent1D.js +2 -1
  6. package/lib/component/1d/SVGContent1D.js.map +1 -1
  7. package/lib/component/1d/Viewer1D.d.ts.map +1 -1
  8. package/lib/component/1d/Viewer1D.js +2 -1
  9. package/lib/component/1d/Viewer1D.js.map +1 -1
  10. package/lib/component/1d/integral/IntegralResizable.d.ts.map +1 -1
  11. package/lib/component/1d/integral/IntegralResizable.js +4 -4
  12. package/lib/component/1d/integral/IntegralResizable.js.map +1 -1
  13. package/lib/component/1d/ranges/Range.d.ts.map +1 -1
  14. package/lib/component/1d/ranges/Range.js +3 -3
  15. package/lib/component/1d/ranges/Range.js.map +1 -1
  16. package/lib/component/1d/ranges/Signals.d.ts +2 -0
  17. package/lib/component/1d/ranges/Signals.d.ts.map +1 -0
  18. package/lib/component/1d/ranges/Signals.js +16 -0
  19. package/lib/component/1d/ranges/Signals.js.map +1 -0
  20. package/lib/component/1d-2d/components/RangeIndicator.d.ts +13 -0
  21. package/lib/component/1d-2d/components/RangeIndicator.d.ts.map +1 -0
  22. package/lib/component/1d-2d/components/RangeIndicator.js +52 -0
  23. package/lib/component/1d-2d/components/RangeIndicator.js.map +1 -0
  24. package/lib/component/1d-2d/components/Signals1D.d.ts +19 -0
  25. package/lib/component/1d-2d/components/Signals1D.d.ts.map +1 -0
  26. package/lib/component/1d-2d/components/Signals1D.js +155 -0
  27. package/lib/component/1d-2d/components/Signals1D.js.map +1 -0
  28. package/lib/component/1d-2d/tools/CrossLinePointer.d.ts +16 -1
  29. package/lib/component/1d-2d/tools/CrossLinePointer.d.ts.map +1 -1
  30. package/lib/component/1d-2d/tools/CrossLinePointer.js +25 -15
  31. package/lib/component/1d-2d/tools/CrossLinePointer.js.map +1 -1
  32. package/lib/component/1d-2d/tools/CursorToolIcon.d.ts +9 -0
  33. package/lib/component/1d-2d/tools/CursorToolIcon.d.ts.map +1 -0
  34. package/lib/component/1d-2d/tools/CursorToolIcon.js +58 -0
  35. package/lib/component/1d-2d/tools/CursorToolIcon.js.map +1 -0
  36. package/lib/component/2d/1d-tracer/Left1DChart.d.ts.map +1 -1
  37. package/lib/component/2d/1d-tracer/Left1DChart.js +3 -2
  38. package/lib/component/2d/1d-tracer/Left1DChart.js.map +1 -1
  39. package/lib/component/2d/1d-tracer/Ranges1D.d.ts.map +1 -1
  40. package/lib/component/2d/1d-tracer/Ranges1D.js +4 -60
  41. package/lib/component/2d/1d-tracer/Ranges1D.js.map +1 -1
  42. package/lib/component/2d/1d-tracer/Top1DChart.d.ts.map +1 -1
  43. package/lib/component/2d/1d-tracer/Top1DChart.js +3 -2
  44. package/lib/component/2d/1d-tracer/Top1DChart.js.map +1 -1
  45. package/lib/component/2d/DirectAxis2D.d.ts.map +1 -1
  46. package/lib/component/2d/DirectAxis2D.js +4 -1
  47. package/lib/component/2d/DirectAxis2D.js.map +1 -1
  48. package/lib/component/2d/IndirectAxis2D.d.ts.map +1 -1
  49. package/lib/component/2d/IndirectAxis2D.js +5 -2
  50. package/lib/component/2d/IndirectAxis2D.js.map +1 -1
  51. package/lib/component/2d/Viewer2D.d.ts.map +1 -1
  52. package/lib/component/2d/Viewer2D.js +2 -1
  53. package/lib/component/2d/Viewer2D.js.map +1 -1
  54. package/lib/component/AnchorSVG.d.ts +5 -6
  55. package/lib/component/AnchorSVG.d.ts.map +1 -1
  56. package/lib/component/AnchorSVG.js +9 -6
  57. package/lib/component/AnchorSVG.js.map +1 -1
  58. package/lib/component/EventsTrackers/BrushTracker.d.ts.map +1 -1
  59. package/lib/component/EventsTrackers/BrushTracker.js +14 -4
  60. package/lib/component/EventsTrackers/BrushTracker.js.map +1 -1
  61. package/lib/component/EventsTrackers/MouseTracker.d.ts +3 -0
  62. package/lib/component/EventsTrackers/MouseTracker.d.ts.map +1 -1
  63. package/lib/component/EventsTrackers/MouseTracker.js +15 -0
  64. package/lib/component/EventsTrackers/MouseTracker.js.map +1 -1
  65. package/lib/component/context/KeyModifierContext.d.ts +1 -0
  66. package/lib/component/context/KeyModifierContext.d.ts.map +1 -1
  67. package/lib/component/context/KeyModifierContext.js +22 -6
  68. package/lib/component/context/KeyModifierContext.js.map +1 -1
  69. package/lib/component/elements/D3Axis.d.ts.map +1 -1
  70. package/lib/component/elements/D3Axis.js +4 -3
  71. package/lib/component/elements/D3Axis.js.map +1 -1
  72. package/lib/component/header/AutoPeakPickingOptionPanel.d.ts.map +1 -1
  73. package/lib/component/header/AutoPeakPickingOptionPanel.js +59 -31
  74. package/lib/component/header/AutoPeakPickingOptionPanel.js.map +1 -1
  75. package/lib/component/header/RangesPickingOptionPanel.d.ts.map +1 -1
  76. package/lib/component/header/RangesPickingOptionPanel.js +34 -19
  77. package/lib/component/header/RangesPickingOptionPanel.js.map +1 -1
  78. package/lib/component/hooks/useAddMultipletSignal.d.ts +7 -0
  79. package/lib/component/hooks/useAddMultipletSignal.d.ts.map +1 -0
  80. package/lib/component/hooks/useAddMultipletSignal.js +28 -0
  81. package/lib/component/hooks/useAddMultipletSignal.js.map +1 -0
  82. package/lib/component/hooks/useFilter.d.ts.map +1 -1
  83. package/lib/component/hooks/useFilter.js.map +1 -1
  84. package/lib/component/hooks/useSpectrum.d.ts +3 -1
  85. package/lib/component/hooks/useSpectrum.d.ts.map +1 -1
  86. package/lib/component/hooks/useSpectrum.js +1 -1
  87. package/lib/component/hooks/useSpectrum.js.map +1 -1
  88. package/lib/component/hooks/useSpectrumWithDataSource.d.ts +1 -1
  89. package/lib/component/hooks/useSpectrumWithDataSource.d.ts.map +1 -1
  90. package/lib/component/hooks/useSpectrumWithDataSource.js.map +1 -1
  91. package/lib/component/hooks/useTempSpectrum.d.ts +1 -1
  92. package/lib/component/hooks/useTempSpectrum.d.ts.map +1 -1
  93. package/lib/component/hooks/use_ticks_config.d.ts +1 -4
  94. package/lib/component/hooks/use_ticks_config.d.ts.map +1 -1
  95. package/lib/component/hooks/use_ticks_config.js +1 -6
  96. package/lib/component/hooks/use_ticks_config.js.map +1 -1
  97. package/lib/component/modal/PublicationStringModal.d.ts +1 -1
  98. package/lib/component/modal/PublicationStringModal.d.ts.map +1 -1
  99. package/lib/component/modal/PublicationStringModal.js +2 -2
  100. package/lib/component/modal/PublicationStringModal.js.map +1 -1
  101. package/lib/component/modal/setting/tanstack_general_settings/errors/context.d.ts +118 -0
  102. package/lib/component/modal/setting/tanstack_general_settings/errors/context.d.ts.map +1 -1
  103. package/lib/component/modal/setting/tanstack_general_settings/errors/renderer.d.ts +118 -0
  104. package/lib/component/modal/setting/tanstack_general_settings/errors/renderer.d.ts.map +1 -1
  105. package/lib/component/modal/setting/tanstack_general_settings/general_settings_dialog_body.d.ts +118 -0
  106. package/lib/component/modal/setting/tanstack_general_settings/general_settings_dialog_body.d.ts.map +1 -1
  107. package/lib/component/modal/setting/tanstack_general_settings/general_settings_dialog_footer.d.ts +96 -0
  108. package/lib/component/modal/setting/tanstack_general_settings/general_settings_dialog_footer.d.ts.map +1 -1
  109. package/lib/component/modal/setting/tanstack_general_settings/general_settings_dialog_header.d.ts +96 -0
  110. package/lib/component/modal/setting/tanstack_general_settings/general_settings_dialog_header.d.ts.map +1 -1
  111. package/lib/component/modal/setting/tanstack_general_settings/hooks/use_safe_workspace.d.ts +16 -0
  112. package/lib/component/modal/setting/tanstack_general_settings/hooks/use_safe_workspace.d.ts.map +1 -1
  113. package/lib/component/modal/setting/tanstack_general_settings/tabs/auto_processing_tab.d.ts +96 -0
  114. package/lib/component/modal/setting/tanstack_general_settings/tabs/auto_processing_tab.d.ts.map +1 -1
  115. package/lib/component/modal/setting/tanstack_general_settings/tabs/axis_tab.d.ts +96 -0
  116. package/lib/component/modal/setting/tanstack_general_settings/tabs/axis_tab.d.ts.map +1 -1
  117. package/lib/component/modal/setting/tanstack_general_settings/tabs/axis_tab.js +12 -1
  118. package/lib/component/modal/setting/tanstack_general_settings/tabs/axis_tab.js.map +1 -1
  119. package/lib/component/modal/setting/tanstack_general_settings/tabs/database_tab.d.ts +96 -0
  120. package/lib/component/modal/setting/tanstack_general_settings/tabs/database_tab.d.ts.map +1 -1
  121. package/lib/component/modal/setting/tanstack_general_settings/tabs/export_tab.d.ts +96 -0
  122. package/lib/component/modal/setting/tanstack_general_settings/tabs/export_tab.d.ts.map +1 -1
  123. package/lib/component/modal/setting/tanstack_general_settings/tabs/external_api_tab.d.ts +96 -0
  124. package/lib/component/modal/setting/tanstack_general_settings/tabs/external_api_tab.d.ts.map +1 -1
  125. package/lib/component/modal/setting/tanstack_general_settings/tabs/general_tab.d.ts +96 -0
  126. package/lib/component/modal/setting/tanstack_general_settings/tabs/general_tab.d.ts.map +1 -1
  127. package/lib/component/modal/setting/tanstack_general_settings/tabs/import_filters_tab.d.ts +96 -0
  128. package/lib/component/modal/setting/tanstack_general_settings/tabs/import_filters_tab.d.ts.map +1 -1
  129. package/lib/component/modal/setting/tanstack_general_settings/tabs/nuclei_tab.d.ts +96 -0
  130. package/lib/component/modal/setting/tanstack_general_settings/tabs/nuclei_tab.d.ts.map +1 -1
  131. package/lib/component/modal/setting/tanstack_general_settings/tabs/panels_tab.d.ts +96 -0
  132. package/lib/component/modal/setting/tanstack_general_settings/tabs/panels_tab.d.ts.map +1 -1
  133. package/lib/component/modal/setting/tanstack_general_settings/tabs/spectra_colors_tab.d.ts +96 -0
  134. package/lib/component/modal/setting/tanstack_general_settings/tabs/spectra_colors_tab.d.ts.map +1 -1
  135. package/lib/component/modal/setting/tanstack_general_settings/tabs/spectra_label_tab.d.ts +96 -0
  136. package/lib/component/modal/setting/tanstack_general_settings/tabs/spectra_label_tab.d.ts.map +1 -1
  137. package/lib/component/modal/setting/tanstack_general_settings/tabs/title_block_tab.d.ts +96 -0
  138. package/lib/component/modal/setting/tanstack_general_settings/tabs/title_block_tab.d.ts.map +1 -1
  139. package/lib/component/modal/setting/tanstack_general_settings/tabs/tools_tab.d.ts +96 -0
  140. package/lib/component/modal/setting/tanstack_general_settings/tabs/tools_tab.d.ts.map +1 -1
  141. package/lib/component/modal/setting/tanstack_general_settings/validation/axis_tab_validation.d.ts +22 -0
  142. package/lib/component/modal/setting/tanstack_general_settings/validation/axis_tab_validation.d.ts.map +1 -1
  143. package/lib/component/modal/setting/tanstack_general_settings/validation/axis_tab_validation.js +15 -2
  144. package/lib/component/modal/setting/tanstack_general_settings/validation/axis_tab_validation.js.map +1 -1
  145. package/lib/component/modal/setting/tanstack_general_settings/validation.d.ts +22 -0
  146. package/lib/component/modal/setting/tanstack_general_settings/validation.d.ts.map +1 -1
  147. package/lib/component/panels/MoleculesPanel/hooks/useAtomAssignment.js +1 -1
  148. package/lib/component/panels/MoleculesPanel/hooks/useAtomAssignment.js.map +1 -1
  149. package/lib/component/panels/RangesPanel/RangesPanel.d.ts.map +1 -1
  150. package/lib/component/panels/RangesPanel/RangesPanel.js +1 -3
  151. package/lib/component/panels/RangesPanel/RangesPanel.js.map +1 -1
  152. package/lib/component/panels/RangesPanel/RangesTableRow.d.ts.map +1 -1
  153. package/lib/component/panels/RangesPanel/RangesTableRow.js +10 -12
  154. package/lib/component/panels/RangesPanel/RangesTableRow.js.map +1 -1
  155. package/lib/component/panels/RangesPanel/TableColumns/SignalAssignmentsColumn.d.ts +1 -1
  156. package/lib/component/panels/RangesPanel/TableColumns/SignalAssignmentsColumn.d.ts.map +1 -1
  157. package/lib/component/panels/RangesPanel/TableColumns/SignalAssignmentsColumn.js +1 -1
  158. package/lib/component/panels/RangesPanel/TableColumns/SignalAssignmentsColumn.js.map +1 -1
  159. package/lib/component/panels/filtersPanel/processings_sections_panel.d.ts.map +1 -1
  160. package/lib/component/panels/filtersPanel/processings_sections_panel.js +13 -23
  161. package/lib/component/panels/filtersPanel/processings_sections_panel.js.map +1 -1
  162. package/lib/component/panels/hooks/use_processings_mutation.d.ts +10 -0
  163. package/lib/component/panels/hooks/use_processings_mutation.d.ts.map +1 -0
  164. package/lib/component/panels/hooks/use_processings_mutation.js +130 -0
  165. package/lib/component/panels/hooks/use_processings_mutation.js.map +1 -0
  166. package/lib/component/panels/informationPanel/InformationPanel.js +1 -1
  167. package/lib/component/panels/informationPanel/InformationPanel.js.map +1 -1
  168. package/lib/component/reducer/Reducer.d.ts.map +1 -1
  169. package/lib/component/reducer/Reducer.js +2 -0
  170. package/lib/component/reducer/Reducer.js.map +1 -1
  171. package/lib/component/reducer/actions/CorrelationsActions.js +1 -1
  172. package/lib/component/reducer/actions/CorrelationsActions.js.map +1 -1
  173. package/lib/component/reducer/actions/FiltersActions.d.ts +2 -0
  174. package/lib/component/reducer/actions/FiltersActions.d.ts.map +1 -1
  175. package/lib/component/reducer/actions/FiltersActions.js +1 -1
  176. package/lib/component/reducer/actions/FiltersActions.js.map +1 -1
  177. package/lib/component/reducer/actions/RangesActions.d.ts.map +1 -1
  178. package/lib/component/reducer/actions/RangesActions.js +13 -24
  179. package/lib/component/reducer/actions/RangesActions.js.map +1 -1
  180. package/lib/component/reducer/actions/SpectraActions.d.ts +8 -2
  181. package/lib/component/reducer/actions/SpectraActions.d.ts.map +1 -1
  182. package/lib/component/reducer/actions/SpectraActions.js +6 -1
  183. package/lib/component/reducer/actions/SpectraActions.js.map +1 -1
  184. package/lib/component/reducer/preferences/actions/setPreferences.d.ts +2 -2
  185. package/lib/component/reducer/preferences/actions/setPreferences.d.ts.map +1 -1
  186. package/lib/component/reducer/preferences/actions/setPreferences.js +8 -5
  187. package/lib/component/reducer/preferences/actions/setPreferences.js.map +1 -1
  188. package/lib/component/reducer/preferences/preferencesReducer.d.ts +1 -1
  189. package/lib/component/reducer/preferences/preferencesReducer.d.ts.map +1 -1
  190. package/lib/component/toolbar/ToolTypes.d.ts +21 -1
  191. package/lib/component/toolbar/ToolTypes.d.ts.map +1 -1
  192. package/lib/component/toolbar/ToolTypes.js +40 -0
  193. package/lib/component/toolbar/ToolTypes.js.map +1 -1
  194. package/lib/component/toolbar/nmr_toolbar.d.ts.map +1 -1
  195. package/lib/component/toolbar/nmr_toolbar.js +9 -35
  196. package/lib/component/toolbar/nmr_toolbar.js.map +1 -1
  197. package/lib/component/workspaces/workspaceDefaultProperties.d.ts.map +1 -1
  198. package/lib/component/workspaces/workspaceDefaultProperties.js +19 -2
  199. package/lib/component/workspaces/workspaceDefaultProperties.js.map +1 -1
  200. package/lib/data/data1d/Spectrum1D/initiateDatum1D.d.ts.map +1 -1
  201. package/lib/data/data1d/Spectrum1D/initiateDatum1D.js +13 -5
  202. package/lib/data/data1d/Spectrum1D/initiateDatum1D.js.map +1 -1
  203. package/lib/data/data2d/Spectrum2D/initiateDatum2D.d.ts.map +1 -1
  204. package/lib/data/data2d/Spectrum2D/initiateDatum2D.js +12 -4
  205. package/lib/data/data2d/Spectrum2D/initiateDatum2D.js.map +1 -1
  206. package/lib/data/data2d/Spectrum2D/isSpectrum2D.d.ts +1 -1
  207. package/lib/data/data2d/Spectrum2D/isSpectrum2D.d.ts.map +1 -1
  208. package/lib/data/data2d/Spectrum2D/isSpectrum2D.js.map +1 -1
  209. package/lib/data/utilities/RangeUtilities.d.ts +1 -6
  210. package/lib/data/utilities/RangeUtilities.d.ts.map +1 -1
  211. package/lib/data/utilities/RangeUtilities.js +10 -27
  212. package/lib/data/utilities/RangeUtilities.js.map +1 -1
  213. package/lib/versionInfo.js +1 -1
  214. package/package.json +15 -14
  215. package/src/component/1d/HorizontalAxis1D.tsx +12 -2
  216. package/src/component/1d/SVGContent1D.tsx +2 -0
  217. package/src/component/1d/Viewer1D.tsx +2 -0
  218. package/src/component/1d/integral/IntegralResizable.tsx +6 -6
  219. package/src/component/1d/ranges/Range.tsx +6 -6
  220. package/src/component/1d/ranges/Signals.tsx +28 -0
  221. package/src/component/1d-2d/components/RangeIndicator.tsx +106 -0
  222. package/src/component/1d-2d/components/Signals1D.tsx +306 -0
  223. package/src/component/1d-2d/tools/CrossLinePointer.tsx +75 -32
  224. package/src/component/1d-2d/tools/CursorToolIcon.tsx +110 -0
  225. package/src/component/2d/1d-tracer/Left1DChart.tsx +4 -2
  226. package/src/component/2d/1d-tracer/Ranges1D.tsx +4 -100
  227. package/src/component/2d/1d-tracer/Top1DChart.tsx +4 -2
  228. package/src/component/2d/DirectAxis2D.tsx +12 -3
  229. package/src/component/2d/IndirectAxis2D.tsx +9 -5
  230. package/src/component/2d/Viewer2D.tsx +5 -2
  231. package/src/component/AnchorSVG.tsx +27 -28
  232. package/src/component/EventsTrackers/BrushTracker.tsx +21 -7
  233. package/src/component/EventsTrackers/MouseTracker.tsx +21 -0
  234. package/src/component/context/KeyModifierContext.tsx +27 -8
  235. package/src/component/elements/D3Axis.tsx +31 -9
  236. package/src/component/header/AutoPeakPickingOptionPanel.tsx +173 -102
  237. package/src/component/header/RangesPickingOptionPanel.tsx +72 -59
  238. package/src/component/hooks/useAddMultipletSignal.tsx +32 -0
  239. package/src/component/hooks/useFilter.ts +2 -1
  240. package/src/component/hooks/useSpectrum.ts +7 -1
  241. package/src/component/hooks/useSpectrumWithDataSource.ts +16 -8
  242. package/src/component/hooks/use_ticks_config.ts +1 -7
  243. package/src/component/modal/PublicationStringModal.tsx +3 -3
  244. package/src/component/modal/setting/tanstack_general_settings/tabs/axis_tab.tsx +76 -12
  245. package/src/component/modal/setting/tanstack_general_settings/validation/axis_tab_validation.ts +16 -2
  246. package/src/component/panels/MoleculesPanel/hooks/useAtomAssignment.tsx +1 -1
  247. package/src/component/panels/RangesPanel/RangesPanel.tsx +1 -3
  248. package/src/component/panels/RangesPanel/RangesTableRow.tsx +10 -12
  249. package/src/component/panels/RangesPanel/TableColumns/SignalAssignmentsColumn.tsx +2 -2
  250. package/src/component/panels/filtersPanel/processings_sections_panel.tsx +27 -44
  251. package/src/component/panels/hooks/use_processings_mutation.ts +171 -0
  252. package/src/component/panels/informationPanel/InformationPanel.tsx +1 -1
  253. package/src/component/reducer/Reducer.ts +2 -0
  254. package/src/component/reducer/actions/CorrelationsActions.ts +1 -1
  255. package/src/component/reducer/actions/FiltersActions.ts +1 -1
  256. package/src/component/reducer/actions/RangesActions.ts +14 -25
  257. package/src/component/reducer/actions/SpectraActions.ts +20 -1
  258. package/src/component/reducer/preferences/actions/setPreferences.ts +18 -10
  259. package/src/component/reducer/preferences/preferencesReducer.ts +1 -1
  260. package/src/component/toolbar/ToolTypes.ts +92 -1
  261. package/src/component/toolbar/nmr_toolbar.tsx +12 -69
  262. package/src/component/workspaces/workspaceDefaultProperties.ts +19 -2
  263. package/src/data/data1d/Spectrum1D/initiateDatum1D.ts +14 -8
  264. package/src/data/data2d/Spectrum2D/initiateDatum2D.ts +12 -4
  265. package/src/data/data2d/Spectrum2D/isSpectrum2D.ts +1 -1
  266. package/src/data/utilities/RangeUtilities.ts +12 -36
  267. package/src/versionInfo.ts +1 -1
  268. package/lib/component/1d/integral/IntegralIndicator.d.ts +0 -9
  269. package/lib/component/1d/integral/IntegralIndicator.d.ts.map +0 -1
  270. package/lib/component/1d/integral/IntegralIndicator.js +0 -22
  271. package/lib/component/1d/integral/IntegralIndicator.js.map +0 -1
  272. package/lib/component/2d/1d-tracer/Signals1D.d.ts +0 -11
  273. package/lib/component/2d/1d-tracer/Signals1D.d.ts.map +0 -1
  274. package/lib/component/2d/1d-tracer/Signals1D.js +0 -90
  275. package/lib/component/2d/1d-tracer/Signals1D.js.map +0 -1
  276. package/src/component/1d/integral/IntegralIndicator.tsx +0 -43
  277. package/src/component/2d/1d-tracer/Signals1D.tsx +0 -145
@@ -1,72 +1,9 @@
1
- import styled from '@emotion/styled';
2
- import type { Jcoupling, Range, Signal1D } from '@zakodium/nmr-types';
1
+ import type { Range } from '@zakodium/nmr-types';
3
2
 
4
3
  import { getOpacityBasedOnSignalKind } from '../../../data/utilities/RangeUtilities.ts';
5
- import { useChartData } from '../../context/ChartContext.tsx';
6
- import { useDispatch } from '../../context/DispatchContext.tsx';
4
+ import { RangeIndicator } from '../../1d-2d/components/RangeIndicator.tsx';
7
5
  import { useScale2DX, useScale2DY } from '../utilities/scale.js';
8
6
 
9
- interface Range1DTraceProps {
10
- position: number;
11
- size: number;
12
- orientation?: 'horizontal' | 'vertical';
13
- opacity?: number;
14
- onClick?: (e: React.MouseEvent<SVGGElement, MouseEvent>) => void;
15
- }
16
-
17
- interface ElementLayout {
18
- groupTransform: string;
19
- pathD: string;
20
- }
21
-
22
- const Path = styled.path`
23
- fill: none;
24
- stroke-width: 1px;
25
- shape-rendering: crispedges;
26
- stroke: black;
27
-
28
- &:hover {
29
- stroke: red;
30
- }
31
- `;
32
- const length = 5;
33
- const innerMargin = 10;
34
-
35
- function Range1DTrace(props: Range1DTraceProps) {
36
- const {
37
- position,
38
- size,
39
- orientation = 'horizontal',
40
- opacity = 1,
41
- onClick,
42
- } = props;
43
- const { margin } = useChartData();
44
-
45
- const layout: ElementLayout =
46
- orientation === 'vertical'
47
- ? {
48
- groupTransform: `translate(${margin.left - innerMargin} ${position})`,
49
- pathD: `M0 0 L${length} 0 L${length} ${size} L0 ${size}`,
50
- }
51
- : {
52
- groupTransform: `translate(${position} ${margin.top - innerMargin})`,
53
- pathD: `M0 0 L0 ${length} L${size} ${length} L${size} 0`,
54
- };
55
-
56
- return (
57
- <g transform={layout.groupTransform} style={{ opacity }} onClick={onClick}>
58
- <rect
59
- x={orientation === 'vertical' ? -(margin.left - innerMargin) : 0}
60
- y={orientation === 'vertical' ? 0 : -(margin.top - innerMargin)}
61
- width={orientation === 'vertical' ? margin.left : size}
62
- height={orientation === 'vertical' ? size : margin.top}
63
- fill="transparent"
64
- />
65
- <Path d={layout.pathD} />
66
- </g>
67
- );
68
- }
69
-
70
7
  interface Ranges1DProps {
71
8
  ranges: Range[];
72
9
  orientation: 'horizontal' | 'vertical';
@@ -74,10 +11,9 @@ interface Ranges1DProps {
74
11
  }
75
12
 
76
13
  export function Ranges1D(props: Ranges1DProps) {
77
- const { ranges, orientation, spectrumId } = props;
14
+ const { ranges, orientation } = props;
78
15
  const scaleX = useScale2DX();
79
16
  const scaleY = useScale2DY();
80
- const dispatch = useDispatch();
81
17
  const scale = orientation === 'horizontal' ? scaleX : scaleY;
82
18
 
83
19
  return ranges.map((range) => {
@@ -89,44 +25,12 @@ export function Ranges1D(props: Ranges1DProps) {
89
25
  const start = Math.min(fromInPixel, toInPixel);
90
26
  const size = Math.abs(fromInPixel - toInPixel);
91
27
 
92
- function handleAddSignal(e: React.MouseEvent<SVGGElement, MouseEvent>) {
93
- const boundingRect = e.currentTarget.getBoundingClientRect();
94
- const x = e.clientX - boundingRect.left + start;
95
- const y = e.clientY - boundingRect.top + start;
96
-
97
- const valueInPixel = orientation === 'horizontal' ? x : y;
98
- const delta = scale.invert(valueInPixel);
99
-
100
- const updatedRange = structuredClone(range);
101
- const signal: Signal1D = {
102
- id: crypto.randomUUID(),
103
- delta,
104
- js: [
105
- {
106
- multiplicity: 'm',
107
- } as Jcoupling,
108
- ],
109
- kind: 'signal',
110
- multiplicity: 'm',
111
- };
112
- updatedRange.signals.push(signal);
113
-
114
- dispatch({
115
- type: 'UPDATE_RANGE',
116
- payload: {
117
- range: updatedRange,
118
- spectrumId,
119
- },
120
- });
121
- }
122
-
123
28
  return (
124
- <Range1DTrace
29
+ <RangeIndicator
125
30
  orientation={orientation}
126
31
  key={id}
127
32
  position={start}
128
33
  size={size}
129
- onClick={handleAddSignal}
130
34
  opacity={opacity}
131
35
  />
132
36
  );
@@ -1,13 +1,13 @@
1
1
  import type { Spectrum1D } from '@zakodium/nmrium-core';
2
2
  import { memo, useRef } from 'react';
3
3
 
4
+ import { Signals1D } from '../../1d-2d/components/Signals1D.tsx';
4
5
  import { useChartData } from '../../context/ChartContext.js';
5
6
  import useXYReduce from '../../hooks/useXYReduce.js';
6
7
  import { PathBuilder } from '../../utility/PathBuilder.js';
7
8
  import { use1DTraceYScale, useScale2DX } from '../utilities/scale.js';
8
9
 
9
10
  import { Ranges1D } from './Ranges1D.tsx';
10
- import { Signals1D } from './Signals1D.tsx';
11
11
 
12
12
  interface Top1DChartProps {
13
13
  verticalMargin?: number;
@@ -41,6 +41,7 @@ function Top1DChart({ verticalMargin = 10, data: spectrum }: Top1DChartProps) {
41
41
  const { width, margin, displayerKey } = useChartData();
42
42
  const height = margin.top;
43
43
  const svgRef = useRef<SVGSVGElement>(null);
44
+ const scale = useScale2DX();
44
45
 
45
46
  const path = usePath(spectrum, { height, verticalMargin });
46
47
  const ranges = spectrum.ranges.values;
@@ -83,9 +84,10 @@ function Top1DChart({ verticalMargin = 10, data: spectrum }: Top1DChartProps) {
83
84
  />
84
85
  <Signals1D
85
86
  ranges={ranges}
86
- svgRef={svgRef}
87
87
  orientation="horizontal"
88
88
  spectrumId={spectrum.id}
89
+ scale={scale}
90
+ position={margin.top}
89
91
  />
90
92
  </g>
91
93
  </svg>
@@ -1,5 +1,6 @@
1
1
  import { memo, useRef } from 'react';
2
2
  import { useLinearPrimaryTicks } from 'react-d3-utils';
3
+ import { SVGStyledText } from 'react-science/ui';
3
4
 
4
5
  import { useIsInset } from '../1d/inset/InsetProvider.tsx';
5
6
  import { AxisUnitPicker } from '../1d-2d/components/axis_unit_picker.tsx';
@@ -8,6 +9,7 @@ import { D3Axis } from '../elements/D3Axis.js';
8
9
  import { useCheckExportStatus } from '../hooks/useViewportSize.tsx';
9
10
  import { axisUnitToLabel, useDirectAxisUnit } from '../hooks/use_axis_unit.ts';
10
11
  import { useGridline2DConfig } from '../hooks/use_gridlines_config.ts';
12
+ import { useTicksConfig } from '../hooks/use_ticks_config.ts';
11
13
 
12
14
  import { useScale2DX } from './utilities/scale.js';
13
15
 
@@ -93,11 +95,18 @@ interface UnitLabelProps {
93
95
  }
94
96
  function UnitLabel(props: UnitLabelProps) {
95
97
  const { width, children } = props;
96
-
98
+ const { labelStyle } = useTicksConfig();
97
99
  return (
98
- <text fill="#000" x={width - 60} y="20" dy="0.71em" textAnchor="end">
100
+ <SVGStyledText
101
+ fill="black"
102
+ x={width - 60}
103
+ y="20"
104
+ dy="0.71em"
105
+ textAnchor="end"
106
+ {...labelStyle}
107
+ >
99
108
  {children}
100
- </text>
109
+ </SVGStyledText>
101
110
  );
102
111
  }
103
112
 
@@ -1,5 +1,6 @@
1
1
  import { memo, useRef } from 'react';
2
2
  import { useLinearPrimaryTicks } from 'react-d3-utils';
3
+ import { SVGStyledText } from 'react-science/ui';
3
4
 
4
5
  import { useIsInset } from '../1d/inset/InsetProvider.tsx';
5
6
  import { AxisUnitPicker } from '../1d-2d/components/axis_unit_picker.tsx';
@@ -13,6 +14,7 @@ import {
13
14
  useIndirectAxisUnit,
14
15
  } from '../hooks/use_axis_unit.ts';
15
16
  import { useGridline2DConfig } from '../hooks/use_gridlines_config.ts';
17
+ import { useTicksConfig } from '../hooks/use_ticks_config.ts';
16
18
 
17
19
  import { useScale2DY } from './utilities/scale.js';
18
20
 
@@ -108,8 +110,8 @@ interface UnitLabelProps {
108
110
  }
109
111
  function UnitLabel(props: UnitLabelProps) {
110
112
  const { children } = props;
111
-
112
- const { getTextWidth } = useTextMetrics({ labelSize: 10 });
113
+ const { labelStyle } = useTicksConfig();
114
+ const { getTextWidth } = useTextMetrics({ labelSize: labelStyle.fontSize });
113
115
  const labelHeight = getTextWidth(children);
114
116
 
115
117
  return (
@@ -124,14 +126,16 @@ function UnitLabel(props: UnitLabelProps) {
124
126
  y={-5}
125
127
  opacity={0.8}
126
128
  />
127
- <text
128
- fill="#000"
129
+
130
+ <SVGStyledText
131
+ fill="black"
129
132
  transform="rotate(-90)"
130
133
  dominantBaseline="middle"
131
134
  textAnchor="end"
135
+ {...labelStyle}
132
136
  >
133
137
  {children}
134
- </text>
138
+ </SVGStyledText>
135
139
  </>
136
140
  );
137
141
  }
@@ -5,6 +5,7 @@ import { SVGRootContainer } from '../1d-2d/components/SVGRootContainer.js';
5
5
  import { ViewerResponsiveWrapper } from '../1d-2d/components/ViewerResponsiveWrapper.js';
6
6
  import BrushXY from '../1d-2d/tools/BrushXY.js';
7
7
  import CrossLinePointer from '../1d-2d/tools/CrossLinePointer.js';
8
+ import { CursorToolIcon } from '../1d-2d/tools/CursorToolIcon.tsx';
8
9
  import { MouseTracker } from '../EventsTrackers/MouseTracker.js';
9
10
  import { useChartData } from '../context/ChartContext.js';
10
11
  import Spinner from '../loader/Spinner.js';
@@ -60,8 +61,10 @@ function Viewer2D(props: Viewer2DProps) {
60
61
  selectedTool === options.phaseCorrectionTwoDimensions.id && (
61
62
  <PhaseTraces />
62
63
  )}
63
-
64
- <CrossLinePointer />
64
+ <CursorToolIcon />
65
+ <CrossLinePointer axis="X" dimensionBorder={DIMENSION.TOP} />
66
+ <CrossLinePointer axis="Y" dimensionBorder={DIMENSION.LEFT} />
67
+ <CrossLinePointer axis="XY" dimensionBorder={DIMENSION.MAIN} />
65
68
  <XYLabelPointer data1D={spectrumData} layout={DIMENSION} />
66
69
 
67
70
  <>
@@ -1,9 +1,4 @@
1
- import type {
2
- CSSProperties,
3
- KeyboardEvent,
4
- MouseEvent,
5
- RefObject,
6
- } from 'react';
1
+ import type { CSSProperties, KeyboardEvent, MouseEvent } from 'react';
7
2
  import { useRef, useState } from 'react';
8
3
 
9
4
  type CursorOrientation = 'horizontal' | 'vertical';
@@ -36,13 +31,13 @@ interface AnchorPosition {
36
31
  interface AnchorProps {
37
32
  position: AnchorPosition;
38
33
  shape?: AnchorShape;
39
- svgRef: RefObject<SVGSVGElement>;
40
34
  svgHeight: number;
41
35
  anchorStyle?: AnchorStyle;
42
36
  restoreFocusOnLeave?: boolean;
43
- onDragMove: (newPosition: AnchorPosition) => void;
44
- onDragEnd: (lastPosition: AnchorPosition) => void;
45
- onDelete: () => void;
37
+ onDragMove?: (newPosition: AnchorPosition) => void;
38
+ onDragEnd?: (lastPosition: AnchorPosition) => void;
39
+ onDragStart?: (position: AnchorPosition) => void;
40
+ onDelete?: () => void;
46
41
  cursorOrientation?: CursorOrientation;
47
42
  }
48
43
 
@@ -201,18 +196,19 @@ function ShapeRenderer({
201
196
  );
202
197
  }
203
198
 
204
- export function Anchor({
205
- position,
206
- shape,
207
- svgRef,
208
- svgHeight,
209
- anchorStyle = {},
210
- restoreFocusOnLeave = false,
211
- onDragMove,
212
- onDragEnd,
213
- onDelete,
214
- cursorOrientation = 'horizontal',
215
- }: AnchorProps) {
199
+ export function Anchor(props: AnchorProps) {
200
+ const {
201
+ position,
202
+ shape,
203
+ svgHeight,
204
+ anchorStyle = {},
205
+ restoreFocusOnLeave = false,
206
+ onDragStart,
207
+ onDragMove,
208
+ onDragEnd,
209
+ onDelete,
210
+ cursorOrientation = 'horizontal',
211
+ } = props;
216
212
  const {
217
213
  size = 16,
218
214
  hoverSize = size,
@@ -255,31 +251,34 @@ export function Anchor({
255
251
  function handleMouseDown(e: MouseEvent<SVGGElement>) {
256
252
  e.preventDefault();
257
253
  setDragging(true);
258
- const { x, y } = clientToSvg(e, svgRef.current);
254
+
255
+ const svg = e.currentTarget.ownerSVGElement;
256
+
257
+ const { x, y } = clientToSvg(e, svg);
259
258
  dragState.current = {
260
259
  startX: x,
261
260
  startY: y,
262
261
  startAnchorX: position.x,
263
262
  startAnchorY: position.y,
264
263
  };
265
-
264
+ onDragStart?.(position);
266
265
  const onMove = (e: globalThis.MouseEvent) => {
267
266
  const current = dragState.current;
268
267
  if (!current) return;
269
268
  const { x, y } = clientToSvg(
270
269
  e as unknown as MouseEvent<SVGGElement>,
271
- svgRef.current,
270
+ svg,
272
271
  );
273
272
  const newX = current.startAnchorX + x - current.startX;
274
273
  const newY = current.startAnchorY + y - current.startY;
275
274
 
276
- onDragMove({ x: newX, y: newY });
275
+ onDragMove?.({ x: newX, y: newY });
277
276
  };
278
277
 
279
278
  const onUp = () => {
280
279
  setDragging(false);
281
280
  dragState.current = null;
282
- onDragEnd({ x: position.x, y: position.y });
281
+ onDragEnd?.({ x: position.x, y: position.y });
283
282
 
284
283
  window.removeEventListener('mousemove', onMove);
285
284
  window.removeEventListener('mouseup', onUp);
@@ -292,7 +291,7 @@ export function Anchor({
292
291
  function handleKeyDown(e: KeyboardEvent<SVGGElement>) {
293
292
  if (e.key === 'Delete' || e.key === 'Backspace') {
294
293
  e.preventDefault();
295
- onDelete();
294
+ onDelete?.();
296
295
  }
297
296
  }
298
297
 
@@ -134,7 +134,9 @@ interface BrushTrackerProps {
134
134
  brushDetectionOptions?: BaseDetectBrushingOptions;
135
135
  clickTriggerMode?: 'native' | 'debounced';
136
136
  }
137
-
137
+ function isSelfControlledTarget(target: EventTarget) {
138
+ return (target as Element).closest('[data-self-control="true"]') !== null;
139
+ }
138
140
  function getMouseXY(event: MouseEvent, currentTarget?: Element) {
139
141
  const boundingRect = (
140
142
  currentTarget ?? event.currentTarget
@@ -169,6 +171,7 @@ export function BrushTracker(options: BrushTrackerProps) {
169
171
  const boundingRectRef = useRef<DOMRect | null>(null);
170
172
  const startPositionRef = useRef<Position>({ x: 0, y: 0 });
171
173
  const lastRef = useRef<Position>({ x: 0, y: 0 });
174
+ const isSelfControlledRef = useRef(false);
172
175
 
173
176
  const handleClickWithDebounce = useCallback(
174
177
  (event: MouseEvent, currentTarget: Element) => {
@@ -199,25 +202,36 @@ export function BrushTracker(options: BrushTrackerProps) {
199
202
  );
200
203
 
201
204
  function handleClick(event: MouseEvent) {
202
- if (isDraggingRef.current || clickTriggerMode !== 'native') return;
205
+ if (
206
+ isDraggingRef.current ||
207
+ clickTriggerMode !== 'native' ||
208
+ isSelfControlledRef.current
209
+ ) {
210
+ return;
211
+ }
212
+
203
213
  const { x, y } = getMouseXY(event);
204
214
  onClick({ ...event, x, y });
205
215
  }
206
216
 
207
217
  function handleDoubleClick(event: MouseEvent) {
208
- if (isDraggingRef.current || clickTriggerMode !== 'native') return;
209
-
218
+ if (
219
+ isDraggingRef.current ||
220
+ clickTriggerMode !== 'native' ||
221
+ isSelfControlledRef.current
222
+ ) {
223
+ return;
224
+ }
210
225
  const { x, y } = getMouseXY(event);
211
226
  onDoubleClick({ ...event, x, y });
212
227
  }
213
-
214
228
  const pointerDownHandler = useCallback(
215
229
  (event: PointerEvent) => {
216
230
  event.persist();
217
231
  const currentTarget = event.currentTarget;
232
+ isSelfControlledRef.current = isSelfControlledTarget(event.target);
218
233
 
219
- const target = event.target as HTMLElement;
220
- if (target.closest('[data-self-control="true"]')) {
234
+ if (isSelfControlledRef.current) {
221
235
  return;
222
236
  }
223
237
 
@@ -23,12 +23,33 @@ interface MouseTrackerProps {
23
23
  noPropagation?: boolean;
24
24
  }
25
25
 
26
+ const disableMouseAttribute = 'data-disable-mouse-tracking' as const;
27
+
28
+ function isMouseTrackingDisabled(target: EventTarget) {
29
+ return (
30
+ (target as Element).closest(`[${CSS.escape(disableMouseAttribute)}]`) !==
31
+ null
32
+ );
33
+ }
34
+
35
+ export const disableMouseTrackingProps = {
36
+ [disableMouseAttribute]: true,
37
+ } as const;
38
+
26
39
  export function MouseTracker(props: MouseTrackerProps) {
27
40
  const { children, className, style, noPropagation } = props;
28
41
  const [mouseTrackerState, setMouseTrackerState] =
29
42
  useState<MouseTrackerData | null>(null);
30
43
  const mouseMoveHandler = useCallback(
31
44
  (event: MouseEvent) => {
45
+ if (isMouseTrackingDisabled(event.target)) {
46
+ setMouseTrackerState(null);
47
+ if (noPropagation) {
48
+ event.stopPropagation();
49
+ }
50
+ return;
51
+ }
52
+
32
53
  const boundingRect = event.currentTarget.getBoundingClientRect();
33
54
  const x = event.clientX - boundingRect.x;
34
55
  const y = event.clientY - boundingRect.y;
@@ -22,6 +22,7 @@ interface KeyModifiers {
22
22
  }
23
23
  interface KeyModifiersState extends KeyModifiers {
24
24
  modifiersKey: ModifiersKey | null;
25
+ isPrimary: boolean;
25
26
  }
26
27
 
27
28
  const defaultKeyModifiersState: KeyModifiersState = {
@@ -29,6 +30,7 @@ const defaultKeyModifiersState: KeyModifiersState = {
29
30
  shiftKey: false,
30
31
  altKey: false,
31
32
  modifiersKey: null,
33
+ isPrimary: false,
32
34
  };
33
35
 
34
36
  const KeyModifierContext = createContext<KeyModifiersState>(
@@ -96,27 +98,35 @@ export function useMapKeyModifiers() {
96
98
  }, [invert]);
97
99
  }
98
100
 
101
+ function isPrimaryActive(shiftKey: boolean, invert: boolean): boolean {
102
+ const primaryKey = getPrimaryKey(invert);
103
+ const shiftOnlyKey = toModifiersKey({
104
+ shiftKey,
105
+ ctrlKey: false,
106
+ altKey: false,
107
+ });
108
+ return shiftOnlyKey === primaryKey;
109
+ }
110
+
99
111
  export function KeyModifiersProvider({ children }: KeyModifierProviderProps) {
100
- const [modifiers, setModifiers] = useState<KeyModifiersState>(
101
- defaultKeyModifiersState,
102
- );
103
112
  const {
104
113
  current: {
105
114
  general: { invert },
106
115
  },
107
116
  } = usePreferences();
117
+ const [modifiers, setModifiers] = useState<KeyModifiers>(
118
+ defaultKeyModifiersState,
119
+ );
108
120
 
109
121
  useEffect(() => {
110
122
  function handleKeyDown(event: KeyboardEvent) {
111
123
  const keyModifiers = getModifiers(event);
112
- const modifiersKey = toModifiersKey(keyModifiers);
113
- setModifiers({ ...keyModifiers, modifiersKey });
124
+ setModifiers(keyModifiers);
114
125
  }
115
126
 
116
127
  function handleKeyUp(event: KeyboardEvent) {
117
128
  const keyModifiers = getModifiers(event);
118
- const modifiersKey = toModifiersKey(keyModifiers);
119
- setModifiers({ ...keyModifiers, modifiersKey });
129
+ setModifiers(keyModifiers);
120
130
  }
121
131
 
122
132
  document.addEventListener('keydown', handleKeyDown);
@@ -128,8 +138,17 @@ export function KeyModifiersProvider({ children }: KeyModifierProviderProps) {
128
138
  };
129
139
  }, [invert]);
130
140
 
141
+ const state = useMemo(() => {
142
+ const modifiersKey = toModifiersKey(modifiers);
143
+ return {
144
+ ...modifiers,
145
+ isPrimary: isPrimaryActive(modifiers.shiftKey, invert),
146
+ modifiersKey,
147
+ };
148
+ }, [invert, modifiers]);
149
+
131
150
  return (
132
- <KeyModifierContext.Provider value={modifiers}>
151
+ <KeyModifierContext.Provider value={state}>
133
152
  {children}
134
153
  </KeyModifierContext.Provider>
135
154
  );
@@ -51,6 +51,8 @@ function isVerticalAxis(axisPosition: AxisPosition) {
51
51
 
52
52
  function BaseLine(props: BaseLineProps) {
53
53
  const { axisPosition, tickLength = 6, scale } = props;
54
+ const { primaryTicks } = useTicksConfig();
55
+
54
56
  const [x1, x2] = scale.range();
55
57
  const sign = ['left', 'top'].includes(axisPosition) ? -1 : 1;
56
58
 
@@ -60,12 +62,20 @@ function BaseLine(props: BaseLineProps) {
60
62
  path = `M${sign * tickLength},${x2} H0 V${x1} H${sign * tickLength}`;
61
63
  }
62
64
 
63
- return <path d={path} stroke="black" fill="none" className="domain" />;
65
+ return (
66
+ <path
67
+ d={path}
68
+ stroke="black"
69
+ fill="none"
70
+ className="domain"
71
+ {...primaryTicks.tickStyle}
72
+ />
73
+ );
64
74
  }
65
75
 
66
76
  function Tickets(props: TicketsProps) {
67
77
  const { ticks, tickLength = 6, axisPosition } = props;
68
- const config = useTicksConfig();
78
+ const { primaryTicks, secondaryTicks } = useTicksConfig();
69
79
 
70
80
  if (!Array.isArray(ticks) || ticks.length === 0) return null;
71
81
 
@@ -127,19 +137,31 @@ function Tickets(props: TicketsProps) {
127
137
  transform={`translate(${isVertical ? `0,${position}` : `${position},0`})`}
128
138
  className="tick"
129
139
  >
130
- {config.isSecondaryEnabled && isFirst && (
131
- <line {...positionSecondaryFirstLineConfig} stroke="black" />
140
+ {secondaryTicks.enabled && isFirst && (
141
+ <line
142
+ {...positionSecondaryFirstLineConfig}
143
+ stroke="black"
144
+ {...secondaryTicks.tickStyle}
145
+ />
132
146
  )}
133
147
 
134
- <line {...positionPrimaryLineConfig} stroke="black" />
135
-
136
- {config.isSecondaryEnabled && (
137
- <line {...positionSecondaryLineConfig} stroke="black" />
148
+ <line
149
+ {...positionPrimaryLineConfig}
150
+ stroke="black"
151
+ {...primaryTicks.tickStyle}
152
+ />
153
+
154
+ {secondaryTicks.enabled && (
155
+ <line
156
+ {...positionSecondaryLineConfig}
157
+ stroke="black"
158
+ {...secondaryTicks.tickStyle}
159
+ />
138
160
  )}
139
161
 
140
162
  <SVGStyledText
141
163
  fill="black"
142
- {...config.textStyle}
164
+ {...primaryTicks.textStyle}
143
165
  {...positionTextConfig}
144
166
  >
145
167
  {label}