react-cheminfo 0.65.0 → 0.67.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/README.md +33 -17
- package/lib/download/ui/FigureDownloadPanel.d.ts +7 -1
- package/lib/download/ui/FigureDownloadPanel.d.ts.map +1 -1
- package/lib/download/ui/FigureDownloadPanel.js +2 -2
- package/lib/download/ui/FigureDownloadPanel.js.map +1 -1
- package/lib/ecosystem/core/sites.js +3 -3
- package/lib/ecosystem/core/sites.js.map +1 -1
- package/lib/ecosystem/core/types.d.ts +1 -1
- package/lib/ecosystem/core/types.d.ts.map +1 -1
- package/lib/ecosystem/ui/glyphs.js +1 -1
- package/lib/ecosystem/ui/glyphs.js.map +1 -1
- package/lib/i18n/core/chromeCatalog.d.ts +1 -1
- package/lib/i18n/core/chromeCatalog.d.ts.map +1 -1
- package/lib/i18n/core/messageCatalog.d.ts +2 -2
- package/lib/i18n/vite/localeCatalog.d.ts +1 -1
- package/lib/ir/core/analysisSpectra.d.ts +23 -6
- package/lib/ir/core/analysisSpectra.d.ts.map +1 -1
- package/lib/ir/core/analysisSpectra.js.map +1 -1
- package/lib/ir/core/bandLabelPlan.d.ts.map +1 -1
- package/lib/ir/core/bandLabelPlan.js +11 -6
- package/lib/ir/core/bandLabelPlan.js.map +1 -1
- package/lib/ir/core/index.d.ts +15 -11
- package/lib/ir/core/index.d.ts.map +1 -1
- package/lib/ir/core/index.js +9 -6
- package/lib/ir/core/index.js.map +1 -1
- package/lib/ir/core/irBand.d.ts +45 -14
- package/lib/ir/core/irBand.d.ts.map +1 -1
- package/lib/ir/core/irBand.js +28 -6
- package/lib/ir/core/irBand.js.map +1 -1
- package/lib/ir/core/irCommands.d.ts +11 -0
- package/lib/ir/core/irCommands.d.ts.map +1 -1
- package/lib/ir/core/irCommands.js +11 -1
- package/lib/ir/core/irCommands.js.map +1 -1
- package/lib/ir/core/irDomain.d.ts +4 -3
- package/lib/ir/core/irDomain.d.ts.map +1 -1
- package/lib/ir/core/irDomain.js +10 -7
- package/lib/ir/core/irDomain.js.map +1 -1
- package/lib/ir/core/irEditorApi.d.ts +12 -0
- package/lib/ir/core/irEditorApi.d.ts.map +1 -1
- package/lib/ir/core/irFormat.d.ts +14 -2
- package/lib/ir/core/irFormat.d.ts.map +1 -1
- package/lib/ir/core/irFormat.js +33 -4
- package/lib/ir/core/irFormat.js.map +1 -1
- package/lib/ir/core/irMode.d.ts +35 -8
- package/lib/ir/core/irMode.d.ts.map +1 -1
- package/lib/ir/core/irMode.js +38 -10
- package/lib/ir/core/irMode.js.map +1 -1
- package/lib/ir/core/irReducer.d.ts +2 -30
- package/lib/ir/core/irReducer.d.ts.map +1 -1
- package/lib/ir/core/irReducer.js +1 -24
- package/lib/ir/core/irReducer.js.map +1 -1
- package/lib/ir/core/irSidePanels.d.ts +7 -1
- package/lib/ir/core/irSidePanels.d.ts.map +1 -1
- package/lib/ir/core/irSpectrum.d.ts +52 -26
- package/lib/ir/core/irSpectrum.d.ts.map +1 -1
- package/lib/ir/core/irSpectrum.js +21 -15
- package/lib/ir/core/irSpectrum.js.map +1 -1
- package/lib/ir/core/irState.d.ts +46 -5
- package/lib/ir/core/irState.d.ts.map +1 -1
- package/lib/ir/core/irState.js +38 -1
- package/lib/ir/core/irState.js.map +1 -1
- package/lib/ir/core/irTechnique.d.ts +94 -0
- package/lib/ir/core/irTechnique.d.ts.map +1 -0
- package/lib/ir/core/irTechnique.js +87 -0
- package/lib/ir/core/irTechnique.js.map +1 -0
- package/lib/ir/core/irTechniqueCommands.d.ts +26 -0
- package/lib/ir/core/irTechniqueCommands.d.ts.map +1 -0
- package/lib/ir/core/irTechniqueCommands.js +68 -0
- package/lib/ir/core/irTechniqueCommands.js.map +1 -0
- package/lib/ir/core/pickBands.d.ts +6 -5
- package/lib/ir/core/pickBands.d.ts.map +1 -1
- package/lib/ir/core/pickBands.js +49 -26
- package/lib/ir/core/pickBands.js.map +1 -1
- package/lib/ir/core/ramanBands.d.ts +30 -0
- package/lib/ir/core/ramanBands.d.ts.map +1 -0
- package/lib/ir/core/ramanBands.js +83 -0
- package/lib/ir/core/ramanBands.js.map +1 -0
- package/lib/ir/core/spectrumJcamp.d.ts +10 -5
- package/lib/ir/core/spectrumJcamp.d.ts.map +1 -1
- package/lib/ir/core/spectrumJcamp.js +63 -15
- package/lib/ir/core/spectrumJcamp.js.map +1 -1
- package/lib/ir/core/toIrSpectrum.d.ts.map +1 -1
- package/lib/ir/core/toIrSpectrum.js +17 -2
- package/lib/ir/core/toIrSpectrum.js.map +1 -1
- package/lib/ir/ui/BandRow.d.ts +30 -0
- package/lib/ir/ui/BandRow.d.ts.map +1 -0
- package/lib/ir/ui/BandRow.js +42 -0
- package/lib/ir/ui/BandRow.js.map +1 -0
- package/lib/ir/ui/BandsPanel.d.ts +4 -0
- package/lib/ir/ui/BandsPanel.d.ts.map +1 -1
- package/lib/ir/ui/BandsPanel.js +14 -59
- package/lib/ir/ui/BandsPanel.js.map +1 -1
- package/lib/ir/ui/IrAboutDialog.d.ts +7 -0
- package/lib/ir/ui/IrAboutDialog.d.ts.map +1 -1
- package/lib/ir/ui/IrAboutDialog.js +16 -3
- package/lib/ir/ui/IrAboutDialog.js.map +1 -1
- package/lib/ir/ui/IrCanvas.d.ts +7 -0
- package/lib/ir/ui/IrCanvas.d.ts.map +1 -1
- package/lib/ir/ui/IrCanvas.js +9 -4
- package/lib/ir/ui/IrCanvas.js.map +1 -1
- package/lib/ir/ui/IrChart.d.ts +2 -1
- package/lib/ir/ui/IrChart.d.ts.map +1 -1
- package/lib/ir/ui/IrChart.js +22 -21
- package/lib/ir/ui/IrChart.js.map +1 -1
- package/lib/ir/ui/IrCommandProvider.d.ts +7 -0
- package/lib/ir/ui/IrCommandProvider.d.ts.map +1 -1
- package/lib/ir/ui/IrCommandProvider.js +2 -2
- package/lib/ir/ui/IrCommandProvider.js.map +1 -1
- package/lib/ir/ui/IrCommandTooltip.d.ts +7 -0
- package/lib/ir/ui/IrCommandTooltip.d.ts.map +1 -1
- package/lib/ir/ui/IrCommandTooltip.js +3 -2
- package/lib/ir/ui/IrCommandTooltip.js.map +1 -1
- package/lib/ir/ui/IrDocumentationDialog.d.ts +8 -1
- package/lib/ir/ui/IrDocumentationDialog.d.ts.map +1 -1
- package/lib/ir/ui/IrDocumentationDialog.js +30 -7
- package/lib/ir/ui/IrDocumentationDialog.js.map +1 -1
- package/lib/ir/ui/IrEditor.d.ts +25 -5
- package/lib/ir/ui/IrEditor.d.ts.map +1 -1
- package/lib/ir/ui/IrEditor.js +3 -20
- package/lib/ir/ui/IrEditor.js.map +1 -1
- package/lib/ir/ui/IrHeader.d.ts.map +1 -1
- package/lib/ir/ui/IrHeader.js +5 -1
- package/lib/ir/ui/IrHeader.js.map +1 -1
- package/lib/ir/ui/IrLogo.d.ts +11 -3
- package/lib/ir/ui/IrLogo.d.ts.map +1 -1
- package/lib/ir/ui/IrLogo.js +14 -5
- package/lib/ir/ui/IrLogo.js.map +1 -1
- package/lib/ir/ui/IrShell.d.ts +9 -1
- package/lib/ir/ui/IrShell.d.ts.map +1 -1
- package/lib/ir/ui/IrShell.js +26 -74
- package/lib/ir/ui/IrShell.js.map +1 -1
- package/lib/ir/ui/IrSidePanel.d.ts +11 -0
- package/lib/ir/ui/IrSidePanel.d.ts.map +1 -1
- package/lib/ir/ui/IrSidePanel.js +12 -3
- package/lib/ir/ui/IrSidePanel.js.map +1 -1
- package/lib/ir/ui/IrStatusBar.d.ts +3 -2
- package/lib/ir/ui/IrStatusBar.d.ts.map +1 -1
- package/lib/ir/ui/IrStatusBar.js +14 -9
- package/lib/ir/ui/IrStatusBar.js.map +1 -1
- package/lib/ir/ui/IrToolbar.d.ts +3 -0
- package/lib/ir/ui/IrToolbar.d.ts.map +1 -1
- package/lib/ir/ui/IrToolbar.js +10 -3
- package/lib/ir/ui/IrToolbar.js.map +1 -1
- package/lib/ir/ui/IrTraces.d.ts +4 -1
- package/lib/ir/ui/IrTraces.d.ts.map +1 -1
- package/lib/ir/ui/IrTraces.js +2 -0
- package/lib/ir/ui/IrTraces.js.map +1 -1
- package/lib/ir/ui/RamanEditor.d.ts +64 -0
- package/lib/ir/ui/RamanEditor.d.ts.map +1 -0
- package/lib/ir/ui/RamanEditor.js +17 -0
- package/lib/ir/ui/RamanEditor.js.map +1 -0
- package/lib/ir/ui/SpectraPanel.d.ts.map +1 -1
- package/lib/ir/ui/SpectraPanel.js +2 -2
- package/lib/ir/ui/SpectraPanel.js.map +1 -1
- package/lib/ir/ui/SpectrumRow.d.ts +7 -0
- package/lib/ir/ui/SpectrumRow.d.ts.map +1 -1
- package/lib/ir/ui/SpectrumRow.js +4 -5
- package/lib/ir/ui/SpectrumRow.js.map +1 -1
- package/lib/ir/ui/VibrationalEditor.d.ts +62 -0
- package/lib/ir/ui/VibrationalEditor.d.ts.map +1 -0
- package/lib/ir/ui/VibrationalEditor.js +33 -0
- package/lib/ir/ui/VibrationalEditor.js.map +1 -0
- package/lib/ir/ui/bandsTsv.d.ts +19 -0
- package/lib/ir/ui/bandsTsv.d.ts.map +1 -0
- package/lib/ir/ui/bandsTsv.js +38 -0
- package/lib/ir/ui/bandsTsv.js.map +1 -0
- package/lib/ir/ui/index.d.ts +1 -0
- package/lib/ir/ui/index.d.ts.map +1 -1
- package/lib/ir/ui/index.js.map +1 -1
- package/lib/ir/ui/irActions.d.ts +3 -3
- package/lib/ir/ui/irActions.d.ts.map +1 -1
- package/lib/ir/ui/irChartProps.d.ts +21 -4
- package/lib/ir/ui/irChartProps.d.ts.map +1 -1
- package/lib/ir/ui/irChartProps.js +3 -2
- package/lib/ir/ui/irChartProps.js.map +1 -1
- package/lib/ir/ui/irCommandContext.d.ts +8 -0
- package/lib/ir/ui/irCommandContext.d.ts.map +1 -1
- package/lib/ir/ui/irCommandContext.js +14 -3
- package/lib/ir/ui/irCommandContext.js.map +1 -1
- package/lib/ir/ui/irHostPanels.d.ts +53 -0
- package/lib/ir/ui/irHostPanels.d.ts.map +1 -0
- package/lib/ir/ui/irHostPanels.js +41 -0
- package/lib/ir/ui/irHostPanels.js.map +1 -0
- package/lib/ir/ui/useIrEditor.d.ts +3 -3
- package/lib/ir/ui/useIrEditor.d.ts.map +1 -1
- package/lib/ir/ui/useIrEditor.js +13 -4
- package/lib/ir/ui/useIrEditor.js.map +1 -1
- package/lib/ir/ui/useIrHandle.d.ts +14 -0
- package/lib/ir/ui/useIrHandle.d.ts.map +1 -0
- package/lib/ir/ui/useIrHandle.js +39 -0
- package/lib/ir/ui/useIrHandle.js.map +1 -0
- package/lib/ir/ui/useIrSide.d.ts +27 -0
- package/lib/ir/ui/useIrSide.d.ts.map +1 -0
- package/lib/ir/ui/useIrSide.js +42 -0
- package/lib/ir/ui/useIrSide.js.map +1 -0
- package/lib/ir/ui/useIrText.d.ts +40 -0
- package/lib/ir/ui/useIrText.d.ts.map +1 -0
- package/lib/ir/ui/useIrText.js +118 -0
- package/lib/ir/ui/useIrText.js.map +1 -0
- package/lib/ir/ui/useIrZoom.d.ts +15 -0
- package/lib/ir/ui/useIrZoom.d.ts.map +1 -1
- package/lib/ir/ui/useIrZoom.js +6 -4
- package/lib/ir/ui/useIrZoom.js.map +1 -1
- package/lib/ir/ui/useValueAxisZoom.d.ts +20 -0
- package/lib/ir/ui/useValueAxisZoom.d.ts.map +1 -0
- package/lib/ir/ui/useValueAxisZoom.js +54 -0
- package/lib/ir/ui/useValueAxisZoom.js.map +1 -0
- package/lib/ir.d.ts +3 -0
- package/lib/ir.d.ts.map +1 -1
- package/lib/ir.js +3 -0
- package/lib/ir.js.map +1 -1
- package/lib/locales/de.json +29 -2
- package/lib/locales/en.json +29 -2
- package/lib/locales/es.json +29 -2
- package/lib/locales/fr.json +29 -2
- package/lib/locales/it.json +29 -2
- package/lib/molecule3d/core/animatedPng.d.ts +25 -0
- package/lib/molecule3d/core/animatedPng.d.ts.map +1 -0
- package/lib/molecule3d/core/animatedPng.js +59 -0
- package/lib/molecule3d/core/animatedPng.js.map +1 -0
- package/lib/molecule3d/core/file.d.ts +24 -0
- package/lib/molecule3d/core/file.d.ts.map +1 -0
- package/lib/molecule3d/core/file.js +2 -0
- package/lib/molecule3d/core/file.js.map +1 -0
- package/lib/molecule3d/core/index.d.ts +4 -1
- package/lib/molecule3d/core/index.d.ts.map +1 -1
- package/lib/molecule3d/core/index.js +1 -0
- package/lib/molecule3d/core/index.js.map +1 -1
- package/lib/molecule3d/core/settings.d.ts +0 -7
- package/lib/molecule3d/core/settings.d.ts.map +1 -1
- package/lib/molecule3d/core/settings.js.map +1 -1
- package/lib/molecule3d/ui/Molecule3DExport.d.ts +10 -2
- package/lib/molecule3d/ui/Molecule3DExport.d.ts.map +1 -1
- package/lib/molecule3d/ui/Molecule3DExport.js +15 -2
- package/lib/molecule3d/ui/Molecule3DExport.js.map +1 -1
- package/lib/molecule3d/ui/Molecule3DToolbar.js +9 -2
- package/lib/molecule3d/ui/Molecule3DToolbar.js.map +1 -1
- package/lib/molecule3d/ui/MoleculeCanvas3D.d.ts.map +1 -1
- package/lib/molecule3d/ui/MoleculeCanvas3D.js +23 -41
- package/lib/molecule3d/ui/MoleculeCanvas3D.js.map +1 -1
- package/lib/molecule3d/ui/drawScene.d.ts +2 -1
- package/lib/molecule3d/ui/drawScene.d.ts.map +1 -1
- package/lib/molecule3d/ui/drawScene.js.map +1 -1
- package/lib/molecule3d/ui/exportMoleculeImage.d.ts +15 -1
- package/lib/molecule3d/ui/exportMoleculeImage.d.ts.map +1 -1
- package/lib/molecule3d/ui/exportMoleculeImage.js +14 -2
- package/lib/molecule3d/ui/exportMoleculeImage.js.map +1 -1
- package/lib/molecule3d/ui/moleculeFrames.d.ts +47 -0
- package/lib/molecule3d/ui/moleculeFrames.d.ts.map +1 -0
- package/lib/molecule3d/ui/moleculeFrames.js +65 -0
- package/lib/molecule3d/ui/moleculeFrames.js.map +1 -0
- package/lib/molecule3d/ui/moleculeViewer3DProps.d.ts +14 -1
- package/lib/molecule3d/ui/moleculeViewer3DProps.d.ts.map +1 -1
- package/lib/molecule3d/ui/renderMolecule.d.ts +3 -3
- package/lib/molecule3d/ui/renderMolecule.d.ts.map +1 -1
- package/lib/molecule3d/ui/renderMolecule.js +2 -1
- package/lib/molecule3d/ui/renderMolecule.js.map +1 -1
- package/lib/molecule3d/ui/sceneDrawer.d.ts +2 -1
- package/lib/molecule3d/ui/sceneDrawer.d.ts.map +1 -1
- package/lib/molecule3d/ui/sceneDrawer.js +9 -1
- package/lib/molecule3d/ui/sceneDrawer.js.map +1 -1
- package/lib/molecule3d/ui/useImageExport.d.ts +8 -3
- package/lib/molecule3d/ui/useImageExport.d.ts.map +1 -1
- package/lib/molecule3d/ui/useImageExport.js +13 -4
- package/lib/molecule3d/ui/useImageExport.js.map +1 -1
- package/lib/molecule3d/ui/useMoleculeScene.d.ts +2 -1
- package/lib/molecule3d/ui/useMoleculeScene.d.ts.map +1 -1
- package/lib/molecule3d/ui/useMoleculeScene.js.map +1 -1
- package/lib/molecule3d/ui/useMoleculeViewer.d.ts +16 -0
- package/lib/molecule3d/ui/useMoleculeViewer.d.ts.map +1 -0
- package/lib/molecule3d/ui/useMoleculeViewer.js +37 -0
- package/lib/molecule3d/ui/useMoleculeViewer.js.map +1 -0
- package/lib/molecule3d/ui/usePolarSurfaceArea.d.ts +3 -3
- package/lib/molecule3d/ui/usePolarSurfaceArea.d.ts.map +1 -1
- package/lib/molecule3d/ui/usePolarSurfaceArea.js +4 -3
- package/lib/molecule3d/ui/usePolarSurfaceArea.js.map +1 -1
- package/lib/molecule3d/ui/viewer.d.ts +4 -1
- package/lib/molecule3d/ui/viewer.d.ts.map +1 -1
- package/lib/molecule3d/ui/viewer.js +21 -19
- package/lib/molecule3d/ui/viewer.js.map +1 -1
- package/lib/molecule3d/ui/viewerTypes.d.ts +6 -0
- package/lib/molecule3d/ui/viewerTypes.d.ts.map +1 -1
- package/lib/molstar/core/captureScene.d.ts +19 -1
- package/lib/molstar/core/captureScene.d.ts.map +1 -1
- package/lib/molstar/core/captureScene.js +57 -2
- package/lib/molstar/core/captureScene.js.map +1 -1
- package/lib/molstar/core/index.d.ts +5 -2
- package/lib/molstar/core/index.d.ts.map +1 -1
- package/lib/molstar/core/index.js +4 -2
- package/lib/molstar/core/index.js.map +1 -1
- package/lib/molstar/core/trajectory.d.ts +56 -0
- package/lib/molstar/core/trajectory.d.ts.map +1 -0
- package/lib/molstar/core/trajectory.js +96 -0
- package/lib/molstar/core/trajectory.js.map +1 -0
- package/lib/panel/ui/PanelRail.d.ts.map +1 -1
- package/lib/panel/ui/PanelRail.js +1 -1
- package/lib/panel/ui/PanelRail.js.map +1 -1
- package/lib/raman.d.ts +17 -0
- package/lib/raman.d.ts.map +1 -0
- package/lib/raman.js +12 -0
- package/lib/raman.js.map +1 -0
- package/lib/router/core/basePath.d.ts +2 -2
- package/lib/router/core/basePath.js +2 -2
- package/lib/router/core/siteAddresses.d.ts +1 -1
- package/lib/router/core/siteAddresses.js +1 -1
- package/lib/seo/core/siteFiles.js +1 -1
- package/lib/seo/core/siteFiles.js.map +1 -1
- package/lib/server/answerAddresses.d.ts +3 -3
- package/lib/server/answerAddresses.js +3 -3
- package/lib/structure/core/index.d.ts +2 -0
- package/lib/structure/core/index.d.ts.map +1 -1
- package/lib/structure/core/index.js +1 -0
- package/lib/structure/core/index.js.map +1 -1
- package/lib/structure/core/structureTransfer.d.ts +29 -0
- package/lib/structure/core/structureTransfer.d.ts.map +1 -0
- package/lib/structure/core/structureTransfer.js +26 -0
- package/lib/structure/core/structureTransfer.js.map +1 -0
- package/lib/structure/ui/EditorImportButton.d.ts +20 -0
- package/lib/structure/ui/EditorImportButton.d.ts.map +1 -0
- package/lib/structure/ui/EditorImportButton.js +24 -0
- package/lib/structure/ui/EditorImportButton.js.map +1 -0
- package/lib/structure/ui/EditorImportProblem.d.ts +17 -0
- package/lib/structure/ui/EditorImportProblem.d.ts.map +1 -0
- package/lib/structure/ui/EditorImportProblem.js +32 -0
- package/lib/structure/ui/EditorImportProblem.js.map +1 -0
- package/lib/structure/ui/StructureDrop.d.ts +39 -0
- package/lib/structure/ui/StructureDrop.d.ts.map +1 -0
- package/lib/structure/ui/StructureDrop.js +19 -0
- package/lib/structure/ui/StructureDrop.js.map +1 -0
- package/lib/structure/ui/StructureDropOverlay.d.ts +16 -0
- package/lib/structure/ui/StructureDropOverlay.d.ts.map +1 -0
- package/lib/structure/ui/StructureDropOverlay.js +29 -0
- package/lib/structure/ui/StructureDropOverlay.js.map +1 -0
- package/lib/structure/ui/StructureEditor.d.ts +3 -80
- package/lib/structure/ui/StructureEditor.d.ts.map +1 -1
- package/lib/structure/ui/StructureEditor.js +21 -33
- package/lib/structure/ui/StructureEditor.js.map +1 -1
- package/lib/structure/ui/importedStructure.d.ts +25 -0
- package/lib/structure/ui/importedStructure.d.ts.map +1 -0
- package/lib/structure/ui/importedStructure.js +74 -0
- package/lib/structure/ui/importedStructure.js.map +1 -0
- package/lib/structure/ui/index.d.ts +2 -0
- package/lib/structure/ui/index.d.ts.map +1 -1
- package/lib/structure/ui/index.js +1 -0
- package/lib/structure/ui/index.js.map +1 -1
- package/lib/structure/ui/structureEditorProps.d.ts +98 -0
- package/lib/structure/ui/structureEditorProps.d.ts.map +1 -0
- package/lib/structure/ui/structureEditorProps.js +2 -0
- package/lib/structure/ui/structureEditorProps.js.map +1 -0
- package/lib/structure/ui/useDebouncedChange.d.ts +16 -0
- package/lib/structure/ui/useDebouncedChange.d.ts.map +1 -0
- package/lib/structure/ui/useDebouncedChange.js +30 -0
- package/lib/structure/ui/useDebouncedChange.js.map +1 -0
- package/lib/structure/ui/useStructureDrop.d.ts +30 -0
- package/lib/structure/ui/useStructureDrop.d.ts.map +1 -0
- package/lib/structure/ui/useStructureDrop.js +49 -0
- package/lib/structure/ui/useStructureDrop.js.map +1 -0
- package/lib/structure/ui/useStructureImport.d.ts +45 -0
- package/lib/structure/ui/useStructureImport.d.ts.map +1 -0
- package/lib/structure/ui/useStructureImport.js +62 -0
- package/lib/structure/ui/useStructureImport.js.map +1 -0
- package/package.json +5 -1
- package/src/download/ui/FigureDownloadPanel.tsx +9 -2
- package/src/ecosystem/core/sites.ts +3 -3
- package/src/ecosystem/core/types.ts +1 -1
- package/src/ecosystem/ui/glyphs.tsx +1 -1
- package/src/i18n/core/messageCatalog.ts +2 -2
- package/src/i18n/vite/localeCatalog.ts +1 -1
- package/src/ir/core/analysisSpectra.ts +26 -10
- package/src/ir/core/bandLabelPlan.ts +21 -10
- package/src/ir/core/index.ts +31 -7
- package/src/ir/core/irBand.ts +52 -14
- package/src/ir/core/irCommands.ts +15 -1
- package/src/ir/core/irDomain.ts +9 -7
- package/src/ir/core/irEditorApi.ts +13 -0
- package/src/ir/core/irFormat.ts +39 -6
- package/src/ir/core/irMode.ts +42 -10
- package/src/ir/core/irReducer.ts +3 -51
- package/src/ir/core/irSidePanels.ts +8 -1
- package/src/ir/core/irSpectrum.ts +59 -30
- package/src/ir/core/irState.ts +73 -5
- package/src/ir/core/irTechnique.ts +115 -0
- package/src/ir/core/irTechniqueCommands.ts +82 -0
- package/src/ir/core/pickBands.ts +63 -28
- package/src/ir/core/ramanBands.ts +105 -0
- package/src/ir/core/spectrumJcamp.ts +65 -16
- package/src/ir/core/toIrSpectrum.ts +20 -2
- package/src/ir/ui/BandRow.tsx +107 -0
- package/src/ir/ui/BandsPanel.tsx +32 -125
- package/src/ir/ui/IrAboutDialog.tsx +69 -28
- package/src/ir/ui/IrCanvas.tsx +29 -3
- package/src/ir/ui/IrChart.tsx +31 -24
- package/src/ir/ui/IrCommandProvider.tsx +10 -3
- package/src/ir/ui/IrCommandTooltip.tsx +11 -2
- package/src/ir/ui/IrDocumentationDialog.tsx +99 -55
- package/src/ir/ui/IrEditor.tsx +27 -40
- package/src/ir/ui/IrHeader.tsx +10 -3
- package/src/ir/ui/IrLogo.tsx +28 -9
- package/src/ir/ui/IrShell.tsx +47 -96
- package/src/ir/ui/IrSidePanel.tsx +36 -10
- package/src/ir/ui/IrStatusBar.tsx +17 -12
- package/src/ir/ui/IrToolbar.tsx +26 -15
- package/src/ir/ui/IrTraces.tsx +5 -1
- package/src/ir/ui/RamanEditor.tsx +71 -0
- package/src/ir/ui/SpectraPanel.tsx +2 -1
- package/src/ir/ui/SpectrumRow.tsx +14 -5
- package/src/ir/ui/VibrationalEditor.tsx +113 -0
- package/src/ir/ui/bandsTsv.ts +46 -0
- package/src/ir/ui/index.ts +1 -0
- package/src/ir/ui/irActions.ts +3 -3
- package/src/ir/ui/irChartProps.ts +21 -4
- package/src/ir/ui/irCommandContext.tsx +18 -3
- package/src/ir/ui/irHostPanels.ts +76 -0
- package/src/ir/ui/useIrEditor.ts +20 -8
- package/src/ir/ui/useIrHandle.ts +51 -0
- package/src/ir/ui/useIrSide.ts +60 -0
- package/src/ir/ui/useIrText.ts +170 -0
- package/src/ir/ui/useIrZoom.ts +22 -3
- package/src/ir/ui/useValueAxisZoom.ts +67 -0
- package/src/ir.ts +3 -0
- package/src/locales/de.json +29 -2
- package/src/locales/en.json +29 -2
- package/src/locales/es.json +29 -2
- package/src/locales/fr.json +29 -2
- package/src/locales/it.json +29 -2
- package/src/molecule3d/core/animatedPng.ts +79 -0
- package/src/molecule3d/core/file.ts +23 -0
- package/src/molecule3d/core/index.ts +3 -1
- package/src/molecule3d/core/settings.ts +0 -8
- package/src/molecule3d/ui/Molecule3DExport.tsx +43 -5
- package/src/molecule3d/ui/Molecule3DToolbar.tsx +9 -2
- package/src/molecule3d/ui/MoleculeCanvas3D.tsx +24 -38
- package/src/molecule3d/ui/drawScene.ts +2 -1
- package/src/molecule3d/ui/exportMoleculeImage.ts +28 -3
- package/src/molecule3d/ui/moleculeFrames.ts +88 -0
- package/src/molecule3d/ui/moleculeViewer3DProps.ts +14 -5
- package/src/molecule3d/ui/renderMolecule.ts +5 -3
- package/src/molecule3d/ui/sceneDrawer.ts +14 -2
- package/src/molecule3d/ui/useImageExport.ts +22 -5
- package/src/molecule3d/ui/useMoleculeScene.ts +2 -1
- package/src/molecule3d/ui/useMoleculeViewer.ts +46 -0
- package/src/molecule3d/ui/usePolarSurfaceArea.ts +6 -4
- package/src/molecule3d/ui/viewer.ts +34 -27
- package/src/molecule3d/ui/viewerTypes.ts +6 -0
- package/src/molstar/core/captureScene.ts +85 -2
- package/src/molstar/core/index.ts +13 -2
- package/src/molstar/core/trajectory.ts +117 -0
- package/src/panel/ui/PanelRail.tsx +3 -0
- package/src/raman.ts +20 -0
- package/src/router/core/basePath.ts +2 -2
- package/src/router/core/siteAddresses.ts +1 -1
- package/src/seo/core/siteFiles.ts +1 -1
- package/src/server/answerAddresses.ts +3 -3
- package/src/structure/core/index.ts +8 -0
- package/src/structure/core/structureTransfer.ts +37 -0
- package/src/structure/ui/EditorImportButton.tsx +59 -0
- package/src/structure/ui/EditorImportProblem.tsx +63 -0
- package/src/structure/ui/StructureDrop.tsx +66 -0
- package/src/structure/ui/StructureDropOverlay.tsx +50 -0
- package/src/structure/ui/StructureEditor.tsx +49 -134
- package/src/structure/ui/importedStructure.ts +83 -0
- package/src/structure/ui/index.ts +2 -0
- package/src/structure/ui/structureEditorProps.ts +103 -0
- package/src/structure/ui/useDebouncedChange.ts +41 -0
- package/src/structure/ui/useStructureDrop.ts +76 -0
- package/src/structure/ui/useStructureImport.ts +122 -0
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import type { CSSProperties } from 'react';
|
|
2
|
+
import type { CanvasEditorInputFormat } from 'react-ocl';
|
|
3
|
+
|
|
4
|
+
import type { StructureTransfer } from '../core/structureTransfer.ts';
|
|
5
|
+
|
|
6
|
+
import type {
|
|
7
|
+
StructureEditorChange,
|
|
8
|
+
StructureEditorMode,
|
|
9
|
+
} from './editorChange.ts';
|
|
10
|
+
|
|
11
|
+
/** What `StructureEditor` needs. */
|
|
12
|
+
export interface StructureEditorProps {
|
|
13
|
+
/**
|
|
14
|
+
* Called after every edit, once the drawing has been still for `debounce`
|
|
15
|
+
* milliseconds, with every notation read out of the editor.
|
|
16
|
+
*/
|
|
17
|
+
onChange: (change: StructureEditorChange) => void;
|
|
18
|
+
/**
|
|
19
|
+
* Draw a query fragment rather than a whole structure, which is what a
|
|
20
|
+
* substructure filter needs.
|
|
21
|
+
* @default false
|
|
22
|
+
*/
|
|
23
|
+
fragment?: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* How `value` is written.
|
|
26
|
+
* @default 'idcode'
|
|
27
|
+
*/
|
|
28
|
+
inputFormat?: CanvasEditorInputFormat;
|
|
29
|
+
/**
|
|
30
|
+
* What the canvas holds. Read once, when the editor appears and again on
|
|
31
|
+
* every change of `revision`: the editor is uncontrolled, so feeding the
|
|
32
|
+
* drawing back into it would replace the structure and reset every
|
|
33
|
+
* coordinate under the pen.
|
|
34
|
+
* @default ''
|
|
35
|
+
*/
|
|
36
|
+
value?: string;
|
|
37
|
+
/**
|
|
38
|
+
* Bumped by the caller to load `value` into the canvas again, which is what
|
|
39
|
+
* an example, a share link or a Clear button does. Changing it discards
|
|
40
|
+
* whatever was being drawn.
|
|
41
|
+
* @default 0
|
|
42
|
+
*/
|
|
43
|
+
revision?: number;
|
|
44
|
+
/**
|
|
45
|
+
* How long the drawing has to be still before `onChange` is called, in
|
|
46
|
+
* milliseconds. Long enough that drawing a ring does not publish six
|
|
47
|
+
* structures; `0` reports every stroke.
|
|
48
|
+
* @default 300
|
|
49
|
+
*/
|
|
50
|
+
debounce?: number;
|
|
51
|
+
/**
|
|
52
|
+
* Smallest height of the drawing area, in pixels. Raised to whatever the
|
|
53
|
+
* toolbar needs, which is usually more.
|
|
54
|
+
* @default 320
|
|
55
|
+
*/
|
|
56
|
+
minHeight?: number;
|
|
57
|
+
/**
|
|
58
|
+
* Whether the editor draws one structure or a reaction. A reaction canvas
|
|
59
|
+
* has its own toolbar and its own arrow.
|
|
60
|
+
* @default 'molecule'
|
|
61
|
+
*/
|
|
62
|
+
mode?: StructureEditorMode;
|
|
63
|
+
/**
|
|
64
|
+
* Explain each toolbar button in a tooltip, and put a button in the corner
|
|
65
|
+
* that opens a guide to the mouse and the keyboard, which F1 opens too.
|
|
66
|
+
* @default true
|
|
67
|
+
*/
|
|
68
|
+
help?: boolean;
|
|
69
|
+
/**
|
|
70
|
+
* Put a button in the corner that opens every notation of the drawing — its
|
|
71
|
+
* SMILES, its molfiles, its canonical identifiers — and the picture of it,
|
|
72
|
+
* ready to copy or to save. A reaction has none of those, so it is never
|
|
73
|
+
* offered one.
|
|
74
|
+
* @default true
|
|
75
|
+
*/
|
|
76
|
+
exportable?: boolean;
|
|
77
|
+
/**
|
|
78
|
+
* Take a structure dropped on the canvas — a molfile, an SDF, a SMILES or
|
|
79
|
+
* an idCode, as a file or as text dragged from another page — and put a
|
|
80
|
+
* button in the corner that opens one from disk. A reaction canvas takes
|
|
81
|
+
* none.
|
|
82
|
+
* @default true
|
|
83
|
+
*/
|
|
84
|
+
importable?: boolean;
|
|
85
|
+
/**
|
|
86
|
+
* Take what is dropped or opened yourself instead of letting the editor read
|
|
87
|
+
* it, for a page that reads more than the canvas does — an XYZ, a PDB, a 3D
|
|
88
|
+
* geometry the canvas would flatten. The page then loads the structure back
|
|
89
|
+
* through `value` and `revision`, like any other.
|
|
90
|
+
* @default undefined
|
|
91
|
+
*/
|
|
92
|
+
onImport?: (transfer: StructureTransfer) => void;
|
|
93
|
+
/**
|
|
94
|
+
* Class the container carries, so a site can reach it from its stylesheet.
|
|
95
|
+
* @default undefined
|
|
96
|
+
*/
|
|
97
|
+
className?: string;
|
|
98
|
+
/**
|
|
99
|
+
* Extra style for the container, merged over the packaged one.
|
|
100
|
+
* @default undefined
|
|
101
|
+
*/
|
|
102
|
+
style?: CSSProperties;
|
|
103
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { useCallback, useEffect, useRef, useState } from 'react';
|
|
2
|
+
|
|
3
|
+
import { createPendingCall } from '../core/pendingCall.ts';
|
|
4
|
+
|
|
5
|
+
import type { StructureEditorChange } from './editorChange.ts';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Report the last edit of a burst rather than every one of them.
|
|
9
|
+
*
|
|
10
|
+
* The editor's own event is read out before the wait starts, so what arrives
|
|
11
|
+
* late is a plain object rather than a handle on an editor that has moved on.
|
|
12
|
+
* An editor removed mid-burst — a tab switched, a card folded — still reports
|
|
13
|
+
* its last edit, which would otherwise be lost with the timer.
|
|
14
|
+
* @param onChange - What the caller wants told.
|
|
15
|
+
* @param delay - How long the drawing has to be still, in milliseconds.
|
|
16
|
+
* @param resetKey - Dropped edits: a burst still waiting when the caller
|
|
17
|
+
* replaces the structure describes a canvas that no longer exists.
|
|
18
|
+
* @returns The handler to give the canvas.
|
|
19
|
+
*/
|
|
20
|
+
export function useDebouncedChange(
|
|
21
|
+
onChange: (change: StructureEditorChange) => void,
|
|
22
|
+
delay: number,
|
|
23
|
+
resetKey: number,
|
|
24
|
+
): (change: StructureEditorChange) => void {
|
|
25
|
+
const [pending] = useState(createPendingCall<StructureEditorChange>);
|
|
26
|
+
const onChangeRef = useRef(onChange);
|
|
27
|
+
useEffect(() => {
|
|
28
|
+
onChangeRef.current = onChange;
|
|
29
|
+
});
|
|
30
|
+
useEffect(() => {
|
|
31
|
+
pending.drop();
|
|
32
|
+
}, [pending, resetKey]);
|
|
33
|
+
useEffect(() => () => pending.flush(), [pending]);
|
|
34
|
+
|
|
35
|
+
return useCallback(
|
|
36
|
+
(change: StructureEditorChange) => {
|
|
37
|
+
pending.push(change, delay, (value) => onChangeRef.current(value));
|
|
38
|
+
},
|
|
39
|
+
[pending, delay],
|
|
40
|
+
);
|
|
41
|
+
}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import type { DragEvent } from 'react';
|
|
2
|
+
import { useMemo, useState } from 'react';
|
|
3
|
+
|
|
4
|
+
import type { StructureTransfer } from '../core/structureTransfer.ts';
|
|
5
|
+
import {
|
|
6
|
+
carriesStructure,
|
|
7
|
+
readStructureTransfer,
|
|
8
|
+
} from '../core/structureTransfer.ts';
|
|
9
|
+
|
|
10
|
+
/** The drag handlers of one element. */
|
|
11
|
+
export interface DropHandlers {
|
|
12
|
+
onDragEnter?: (event: DragEvent<HTMLElement>) => void;
|
|
13
|
+
onDragOver?: (event: DragEvent<HTMLElement>) => void;
|
|
14
|
+
onDragLeave?: (event: DragEvent<HTMLElement>) => void;
|
|
15
|
+
onDrop?: (event: DragEvent<HTMLElement>) => void;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
/** A drop target, in two parts: the element and the overlay it raises. */
|
|
19
|
+
export interface StructureDropTarget {
|
|
20
|
+
/** Whether a file or text is being dragged over the target. */
|
|
21
|
+
over: boolean;
|
|
22
|
+
/** Put on the element that takes the drop. */
|
|
23
|
+
targetProps: DropHandlers;
|
|
24
|
+
/**
|
|
25
|
+
* Put on the overlay drawn while `over`. It covers the target and takes
|
|
26
|
+
* every drag event from then on, so moving across the canvas and the buttons
|
|
27
|
+
* underneath never reads as leaving, and leaving the overlay is leaving.
|
|
28
|
+
*/
|
|
29
|
+
overlayProps: DropHandlers;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* Take a file or text dropped on an element.
|
|
34
|
+
* @param onDrop - Where the drop goes; `undefined` takes none.
|
|
35
|
+
* @returns Whether a drag is over the element, and the handlers to put on it
|
|
36
|
+
* and on its overlay.
|
|
37
|
+
*/
|
|
38
|
+
export function useStructureDrop(
|
|
39
|
+
onDrop: ((transfer: StructureTransfer) => void) | undefined,
|
|
40
|
+
): StructureDropTarget {
|
|
41
|
+
const [over, setOver] = useState(false);
|
|
42
|
+
|
|
43
|
+
return useMemo(() => {
|
|
44
|
+
if (onDrop === undefined) {
|
|
45
|
+
return { over: false, targetProps: {}, overlayProps: {} };
|
|
46
|
+
}
|
|
47
|
+
const accept = (event: DragEvent<HTMLElement>): boolean => {
|
|
48
|
+
if (!carriesStructure(event.dataTransfer.types)) return false;
|
|
49
|
+
event.preventDefault();
|
|
50
|
+
event.dataTransfer.dropEffect = 'copy';
|
|
51
|
+
return true;
|
|
52
|
+
};
|
|
53
|
+
return {
|
|
54
|
+
over,
|
|
55
|
+
targetProps: {
|
|
56
|
+
onDragEnter: (event) => {
|
|
57
|
+
if (accept(event)) setOver(true);
|
|
58
|
+
},
|
|
59
|
+
onDragOver: accept,
|
|
60
|
+
},
|
|
61
|
+
overlayProps: {
|
|
62
|
+
onDragOver: accept,
|
|
63
|
+
onDragLeave: (event) => {
|
|
64
|
+
if (event.target === event.currentTarget) setOver(false);
|
|
65
|
+
},
|
|
66
|
+
onDrop: (event) => {
|
|
67
|
+
setOver(false);
|
|
68
|
+
const transfer = readStructureTransfer(event.dataTransfer);
|
|
69
|
+
if (transfer === null) return;
|
|
70
|
+
event.preventDefault();
|
|
71
|
+
onDrop(transfer);
|
|
72
|
+
},
|
|
73
|
+
},
|
|
74
|
+
};
|
|
75
|
+
}, [onDrop, over]);
|
|
76
|
+
}
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import { useCallback, useRef, useState } from 'react';
|
|
2
|
+
|
|
3
|
+
import type { StructureTransfer } from '../core/structureTransfer.ts';
|
|
4
|
+
|
|
5
|
+
import type { StructureEditorMoleculeChange } from './editorChange.ts';
|
|
6
|
+
|
|
7
|
+
/** What {@link useStructureImport} needs. */
|
|
8
|
+
export interface StructureImportOptions {
|
|
9
|
+
/** Bumped by the caller to load its own value, which drops any import. */
|
|
10
|
+
revision: number;
|
|
11
|
+
/** Whether the editor draws a query fragment. */
|
|
12
|
+
fragment: boolean;
|
|
13
|
+
/** The caller's own reader, which then takes every drop instead. */
|
|
14
|
+
onImport: ((transfer: StructureTransfer) => void) | undefined;
|
|
15
|
+
/** Where a structure the editor read goes: the path an edit takes. */
|
|
16
|
+
onRead: (change: StructureEditorMoleculeChange) => void;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
/** Why the last drop loaded nothing. */
|
|
20
|
+
export interface StructureImportProblem {
|
|
21
|
+
/** The file that was read, `null` for dragged text. */
|
|
22
|
+
file: string | null;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
/** The editor's imports, as the canvas and its corner need them. */
|
|
26
|
+
export interface StructureImport {
|
|
27
|
+
/**
|
|
28
|
+
* The idCode the canvas loads instead of the caller's value, `null` while it
|
|
29
|
+
* shows that value.
|
|
30
|
+
*/
|
|
31
|
+
idCode: string | null;
|
|
32
|
+
/** The canvas's key: a new one per import, which loads it. */
|
|
33
|
+
canvasKey: string;
|
|
34
|
+
/** Read a drop or a chosen file. */
|
|
35
|
+
load: (transfer: StructureTransfer) => void;
|
|
36
|
+
/** Why the last drop loaded nothing, `null` when it did. */
|
|
37
|
+
problem: StructureImportProblem | null;
|
|
38
|
+
/** Forget the problem. */
|
|
39
|
+
dismiss: () => void;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
/** One import into the canvas, and which load of it it replaced. */
|
|
43
|
+
interface Imported {
|
|
44
|
+
revision: number;
|
|
45
|
+
count: number;
|
|
46
|
+
idCode: string;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* Load what is dropped on the editor, or opened from disk, into its canvas.
|
|
51
|
+
*
|
|
52
|
+
* The canvas is uncontrolled, so a dropped structure — one the editor never
|
|
53
|
+
* produced — remounts it with a new key, and is then reported like an edit.
|
|
54
|
+
* A drop overtaken by a later one is dropped rather than applied late.
|
|
55
|
+
* @param options - See {@link StructureImportOptions}.
|
|
56
|
+
* @returns See {@link StructureImport}.
|
|
57
|
+
*/
|
|
58
|
+
export function useStructureImport(
|
|
59
|
+
options: StructureImportOptions,
|
|
60
|
+
): StructureImport {
|
|
61
|
+
const { revision, fragment, onImport, onRead } = options;
|
|
62
|
+
const [imported, setImported] = useState<Imported | null>(null);
|
|
63
|
+
const [problem, setProblem] = useState<StructureImportProblem | null>(null);
|
|
64
|
+
const token = useRef(0);
|
|
65
|
+
|
|
66
|
+
const load = useCallback(
|
|
67
|
+
(transfer: StructureTransfer) => {
|
|
68
|
+
setProblem(null);
|
|
69
|
+
if (onImport !== undefined) {
|
|
70
|
+
onImport(transfer);
|
|
71
|
+
return;
|
|
72
|
+
}
|
|
73
|
+
const current = ++token.current;
|
|
74
|
+
void readTransfer(transfer, fragment).then(({ file, change }) => {
|
|
75
|
+
if (current !== token.current) return;
|
|
76
|
+
if (change === null) {
|
|
77
|
+
setProblem({ file });
|
|
78
|
+
return;
|
|
79
|
+
}
|
|
80
|
+
setImported((previous) => ({
|
|
81
|
+
revision,
|
|
82
|
+
count: previous?.revision === revision ? previous.count + 1 : 1,
|
|
83
|
+
idCode: change.idCode,
|
|
84
|
+
}));
|
|
85
|
+
onRead(change);
|
|
86
|
+
});
|
|
87
|
+
},
|
|
88
|
+
[fragment, onImport, onRead, revision],
|
|
89
|
+
);
|
|
90
|
+
|
|
91
|
+
const dismiss = useCallback(() => setProblem(null), []);
|
|
92
|
+
const current = imported?.revision === revision ? imported : null;
|
|
93
|
+
|
|
94
|
+
return {
|
|
95
|
+
idCode: current?.idCode ?? null,
|
|
96
|
+
canvasKey: `${revision}.${current?.count ?? 0}`,
|
|
97
|
+
load,
|
|
98
|
+
problem,
|
|
99
|
+
dismiss,
|
|
100
|
+
};
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
async function readTransfer(
|
|
104
|
+
transfer: StructureTransfer,
|
|
105
|
+
fragment: boolean,
|
|
106
|
+
): Promise<{
|
|
107
|
+
file: string | null;
|
|
108
|
+
change: StructureEditorMoleculeChange | null;
|
|
109
|
+
}> {
|
|
110
|
+
const file = transfer.kind === 'files' ? transfer.files[0] : undefined;
|
|
111
|
+
try {
|
|
112
|
+
const text =
|
|
113
|
+
transfer.kind === 'text' ? transfer.text : ((await file?.text()) ?? '');
|
|
114
|
+
const { readImportedStructure } = await import('./importedStructure.ts');
|
|
115
|
+
return {
|
|
116
|
+
file: file?.name ?? null,
|
|
117
|
+
change: readImportedStructure(text, fragment),
|
|
118
|
+
};
|
|
119
|
+
} catch {
|
|
120
|
+
return { file: file?.name ?? null, change: null };
|
|
121
|
+
}
|
|
122
|
+
}
|