@@ -15,7 +15,12 @@ import {
1515 Convert2Scan , Convert2Thres ,
1616} from '../../helpers/chem' ;
1717import { MuButton , commonStyle } from './common' ;
18- import { extractPeaksEdit , formatLcmsPeaksForBackend , formatLcmsIntegralsForBackend } from '../../helpers/extractPeaksEdit' ;
18+ import {
19+ extractPeaksEdit ,
20+ formatLcmsPeaksForBackend ,
21+ formatLcmsIntegralsForBackend ,
22+ getLcmsMzPageData ,
23+ } from '../../helpers/extractPeaksEdit' ;
1924import Format from '../../helpers/format' ;
2025
2126const styles = ( ) => (
@@ -29,7 +34,10 @@ const getAxesSelection = (axesUnitsSt, curveIdx) => {
2934 const axes = axesUnitsSt ?. axes ;
3035 if ( ! Array . isArray ( axes ) || axes . length === 0 ) return { xUnit : '' , yUnit : '' } ;
3136 const idx = Number . isFinite ( curveIdx ) ? curveIdx : 0 ;
32- return axes [ idx ] || axes [ 0 ] || { xUnit : '' , yUnit : '' } ;
37+ return axes [ idx ] || axes [ 0 ] || {
38+ xUnit : '' ,
39+ yUnit : '' ,
40+ } ;
3341} ;
3442
3543const resolveAxisLabels = ( xLabel , yLabel , axesUnitsSt , curveIdx ) => {
@@ -178,7 +186,11 @@ const onClickCb = (
178186) => (
179187 ( ) => {
180188 const defaultCurves = feature ? [ { feature } ] : [ ] ;
181- const curves = Array . isArray ( curveList ) && curveList . length > 0 ? curveList : defaultCurves ;
189+ let curves = Array . isArray ( curveList ) && curveList . length > 0 ? curveList : defaultCurves ;
190+ if ( layoutSt === 'LC/MS' ) {
191+ curves = curves . filter ( ( c ) => c . lcmsKind === 'uvvis' ) ;
192+ if ( curves . length === 0 ) curves = defaultCurves ;
193+ }
182194 const fallbackIdx = Number . isFinite ( curveSt ?. curveIdx ) ? curveSt . curveIdx : 0 ;
183195 const indicesToSend = curves . length > 0
184196 ? curves . map ( ( _ , index ) => index )
@@ -216,6 +228,7 @@ const onClickCb = (
216228 payload . lcms_peaks_text = Format . formatedLCMS ( hplcMsSt , isAscend , decimalSt ) ;
217229 payload . lcms_uvvis_wavelength = hplcMsSt ?. uvvis ?. selectedWaveLength ?? null ;
218230 payload . lcms_mz_page = hplcMsSt ?. tic ?. currentPageValue ?? null ;
231+ payload . lcms_mz_page_data = getLcmsMzPageData ( hplcMsSt ) ;
219232 }
220233 if ( Number . isFinite ( curveSt ?. curveIdx ) ) {
221234 payload . curveSt = { curveIdx : curveSt . curveIdx } ;
0 commit comments