@tetrascience-npm/tetrascience-react-ui 0.7.0-beta.107.1 → 0.7.0-beta.108.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.
- package/dist/components/charts/ChromatogramChart/ChromatogramChart.cjs +1 -1
- package/dist/components/charts/ChromatogramChart/ChromatogramChart.cjs.map +1 -1
- package/dist/components/charts/ChromatogramChart/ChromatogramChart.js +221 -207
- package/dist/components/charts/ChromatogramChart/ChromatogramChart.js.map +1 -1
- package/dist/components/charts/ChromatogramChart/annotations.cjs +1 -1
- package/dist/components/charts/ChromatogramChart/annotations.cjs.map +1 -1
- package/dist/components/charts/ChromatogramChart/annotations.js +99 -36
- package/dist/components/charts/ChromatogramChart/annotations.js.map +1 -1
- package/dist/components/charts/ChromatogramChart/boundaryMarkers.cjs +1 -1
- package/dist/components/charts/ChromatogramChart/boundaryMarkers.cjs.map +1 -1
- package/dist/components/charts/ChromatogramChart/boundaryMarkers.js +12 -12
- package/dist/components/charts/ChromatogramChart/boundaryMarkers.js.map +1 -1
- package/dist/components/charts/ChromatogramChart/constants.cjs +1 -1
- package/dist/components/charts/ChromatogramChart/constants.cjs.map +1 -1
- package/dist/components/charts/ChromatogramChart/constants.js +11 -5
- package/dist/components/charts/ChromatogramChart/constants.js.map +1 -1
- package/dist/components/charts/ChromatogramChart/dataProcessing.cjs +1 -1
- package/dist/components/charts/ChromatogramChart/dataProcessing.cjs.map +1 -1
- package/dist/components/charts/ChromatogramChart/dataProcessing.js +49 -38
- package/dist/components/charts/ChromatogramChart/dataProcessing.js.map +1 -1
- package/dist/components/charts/ChromatogramChart/plotBuilder.cjs +2 -0
- package/dist/components/charts/ChromatogramChart/plotBuilder.cjs.map +1 -0
- package/dist/components/charts/ChromatogramChart/plotBuilder.js +207 -0
- package/dist/components/charts/ChromatogramChart/plotBuilder.js.map +1 -0
- package/dist/components/charts/ChromatogramChart/regionOverlays.cjs +2 -0
- package/dist/components/charts/ChromatogramChart/regionOverlays.cjs.map +1 -0
- package/dist/components/charts/ChromatogramChart/regionOverlays.js +26 -0
- package/dist/components/charts/ChromatogramChart/regionOverlays.js.map +1 -0
- package/dist/components/charts/StackedChromatogramChart/StackedChromatogramChart.cjs +2 -0
- package/dist/components/charts/StackedChromatogramChart/StackedChromatogramChart.cjs.map +1 -0
- package/dist/components/charts/StackedChromatogramChart/StackedChromatogramChart.js +40 -0
- package/dist/components/charts/StackedChromatogramChart/StackedChromatogramChart.js.map +1 -0
- package/dist/components/charts/StackedChromatogramChart/transforms.cjs +2 -0
- package/dist/components/charts/StackedChromatogramChart/transforms.cjs.map +1 -0
- package/dist/components/charts/StackedChromatogramChart/transforms.js +31 -0
- package/dist/components/charts/StackedChromatogramChart/transforms.js.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.css +1 -1
- package/dist/index.d.ts +141 -0
- package/dist/index.js +562 -558
- package/dist/index.js.map +1 -1
- package/dist/index.tailwind.css +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -121,6 +121,8 @@ export declare function allPositions(dims: PlateDimensions): WellId[];
|
|
|
121
121
|
|
|
122
122
|
export declare function applyFilterCondition(cellValue: string, operator: FilterOperator, filterValue: string): boolean;
|
|
123
123
|
|
|
124
|
+
export declare function applyStackingTransform(inputSeries: ChromatogramSeries[], inputAnnotations: PeakAnnotation[][] | undefined, mode: StackingMode, stackOffset: number, stackingOrder?: "first-on-bottom" | "first-on-top"): TransformResult;
|
|
125
|
+
|
|
124
126
|
export declare interface AreaDataSeries {
|
|
125
127
|
x: number[];
|
|
126
128
|
y: number[];
|
|
@@ -806,6 +808,44 @@ export declare interface ChromatogramChartProps {
|
|
|
806
808
|
annotationOverlapThreshold?: number;
|
|
807
809
|
/** Show export button in modebar (default: true) */
|
|
808
810
|
showExportButton?: boolean;
|
|
811
|
+
/**
|
|
812
|
+
* IDs of peaks that should render in the "selected" visual state.
|
|
813
|
+
* Fully controlled — the component owns no selection state of its own.
|
|
814
|
+
* IDs match the id field on PeakAnnotation (user-provided) or the
|
|
815
|
+
* auto-generated IDs for auto-detected peaks ("peak-{seriesIndex}-{peakIndex}").
|
|
816
|
+
*/
|
|
817
|
+
selectedPeakIds?: string[];
|
|
818
|
+
/**
|
|
819
|
+
* Called when the user clicks on a peak annotation or its invisible hit target.
|
|
820
|
+
* The consumer decides whether to add/remove the id from selectedPeakIds
|
|
821
|
+
* (toggle vs. replace behaviour is the consumer's responsibility).
|
|
822
|
+
*/
|
|
823
|
+
onPeakClick?: (event: PeakSelectEvent) => void;
|
|
824
|
+
/**
|
|
825
|
+
* Called when the cursor enters or leaves a peak hit target.
|
|
826
|
+
* Receives null on unhover. As a side-effect, the series line for the
|
|
827
|
+
* hovered peak thickens by selectionAppearance.hoverLineWidthMultiplier.
|
|
828
|
+
*/
|
|
829
|
+
onPeakHover?: (event: PeakSelectEvent | null) => void;
|
|
830
|
+
/**
|
|
831
|
+
* Override the default visual behaviour for selected / unselected / hover states.
|
|
832
|
+
* All sub-fields are optional — defaults are applied for any omitted value.
|
|
833
|
+
* Only has a visual effect when selectedPeakIds or onPeakClick/onPeakHover are used.
|
|
834
|
+
*/
|
|
835
|
+
selectionAppearance?: PeakSelectionAppearance;
|
|
836
|
+
/**
|
|
837
|
+
* Annotation label style (default: "arrow").
|
|
838
|
+
* - "arrow" — arrowhead pointing to the peak with a floating label box
|
|
839
|
+
* - "inline" — no arrow; label sits 4 px above the actual trace Y value
|
|
840
|
+
*/
|
|
841
|
+
annotationStyle?: "arrow" | "inline";
|
|
842
|
+
/** Title font size in pixels (default: 20) */
|
|
843
|
+
titleFontSize?: number;
|
|
844
|
+
/**
|
|
845
|
+
* Top margin override when a title is shown (default: from
|
|
846
|
+
* CHROMATOGRAM_LAYOUT.MARGIN_TOP_WITH_TITLE).
|
|
847
|
+
*/
|
|
848
|
+
titleTopMargin?: number;
|
|
809
849
|
}
|
|
810
850
|
|
|
811
851
|
export declare interface ChromatogramProps {
|
|
@@ -2126,6 +2166,13 @@ export declare function parseRowLabel(label: string): number;
|
|
|
2126
2166
|
* Used for both user-provided annotations and auto-detected peaks.
|
|
2127
2167
|
*/
|
|
2128
2168
|
export declare interface PeakAnnotation {
|
|
2169
|
+
/**
|
|
2170
|
+
* Stable identifier used for selection (selectedPeakIds).
|
|
2171
|
+
* Auto-generated by the component if omitted:
|
|
2172
|
+
* - User annotations: "user-ann-{index}"
|
|
2173
|
+
* - Auto-detected peaks: "peak-{seriesIndex}-{peakIndex}"
|
|
2174
|
+
*/
|
|
2175
|
+
id?: string;
|
|
2129
2176
|
/** Retention time of the peak (x-axis position) */
|
|
2130
2177
|
x: number;
|
|
2131
2178
|
/** Signal intensity at peak (y-axis position) */
|
|
@@ -2144,6 +2191,23 @@ export declare interface PeakAnnotation {
|
|
|
2144
2191
|
startMarker?: BoundaryMarkerType;
|
|
2145
2192
|
/** Marker style for end boundary (default: "diamond") */
|
|
2146
2193
|
endMarker?: BoundaryMarkerType;
|
|
2194
|
+
/**
|
|
2195
|
+
* Optional per-peak color override. When set, overrides the default
|
|
2196
|
+
* series-color / grey for the annotation label, arrow, border, and boundary markers.
|
|
2197
|
+
*/
|
|
2198
|
+
color?: string;
|
|
2199
|
+
/**
|
|
2200
|
+
* When true, overlay a thickened line along the underlying trace between startX and endX.
|
|
2201
|
+
* Requires startX/endX. Uses peak.color if set, otherwise series color.
|
|
2202
|
+
*/
|
|
2203
|
+
regionOverlay?: boolean;
|
|
2204
|
+
/** Line width for the region overlay (default: 3.5) */
|
|
2205
|
+
regionOverlayWidth?: number;
|
|
2206
|
+
/**
|
|
2207
|
+
* Plotly hovertemplate HTML string used by the region overlay and the invisible
|
|
2208
|
+
* hit-area marker for this peak. Falls back to a default summary when omitted.
|
|
2209
|
+
*/
|
|
2210
|
+
hoverText?: string;
|
|
2147
2211
|
/* Excluded from this release type: _computed */
|
|
2148
2212
|
}
|
|
2149
2213
|
|
|
@@ -2172,6 +2236,48 @@ export declare interface PeakDetectionOptions {
|
|
|
2172
2236
|
relativeThreshold?: boolean;
|
|
2173
2237
|
}
|
|
2174
2238
|
|
|
2239
|
+
/**
|
|
2240
|
+
* Payload delivered to onPeakClick and onPeakHover callbacks.
|
|
2241
|
+
*/
|
|
2242
|
+
declare interface PeakSelectEvent {
|
|
2243
|
+
/** The resolved peak ID (matches id field on PeakAnnotation) */
|
|
2244
|
+
id: string;
|
|
2245
|
+
/** The annotation object for this peak */
|
|
2246
|
+
peak: PeakAnnotation;
|
|
2247
|
+
/** Index of the series this peak belongs to (0-based; -1 for legacy user annotations) */
|
|
2248
|
+
seriesIndex: number;
|
|
2249
|
+
/** Display name of the series */
|
|
2250
|
+
seriesName: string;
|
|
2251
|
+
/** True when the peak was found by automatic peak detection, false for user-provided annotations */
|
|
2252
|
+
isAutoDetected: boolean;
|
|
2253
|
+
}
|
|
2254
|
+
|
|
2255
|
+
/**
|
|
2256
|
+
* Visual overrides for the selected / unselected / hover states.
|
|
2257
|
+
* All fields are optional — defaults are applied for any omitted field.
|
|
2258
|
+
*
|
|
2259
|
+
* Defaults:
|
|
2260
|
+
* selected.borderColor "#3b82f6"
|
|
2261
|
+
* selected.backgroundColor "#dbeafe"
|
|
2262
|
+
* selected.bold true
|
|
2263
|
+
* unselected.opacity 0.4 (applied when any other peak is selected)
|
|
2264
|
+
* hoverLineWidthMultiplier 1.67 (1.5 px → ~2.5 px)
|
|
2265
|
+
*/
|
|
2266
|
+
declare interface PeakSelectionAppearance {
|
|
2267
|
+
selected?: {
|
|
2268
|
+
borderColor?: string;
|
|
2269
|
+
backgroundColor?: string;
|
|
2270
|
+
/** Wrap annotation text in <b> tags when selected */
|
|
2271
|
+
bold?: boolean;
|
|
2272
|
+
};
|
|
2273
|
+
unselected?: {
|
|
2274
|
+
/** Opacity of annotations whose peak is NOT selected while another peak IS selected (0–1) */
|
|
2275
|
+
opacity?: number;
|
|
2276
|
+
};
|
|
2277
|
+
/** Multiplier applied to the base line width (1.5 px) on peak hover */
|
|
2278
|
+
hoverLineWidthMultiplier?: number;
|
|
2279
|
+
}
|
|
2280
|
+
|
|
2175
2281
|
export declare const PieChart: default_2.FC<PieChartProps>;
|
|
2176
2282
|
|
|
2177
2283
|
export declare type PieChartProps = {
|
|
@@ -3501,6 +3607,35 @@ export declare const spinnerVariants: (props?: ({
|
|
|
3501
3607
|
size?: "default" | "sm" | "lg" | "md" | null | undefined;
|
|
3502
3608
|
} & ClassProp) | undefined) => string;
|
|
3503
3609
|
|
|
3610
|
+
export declare function StackedChromatogramChart({ series, stackingMode, stackOffset, stackingOrder, annotations, ...restProps }: StackedChromatogramChartProps): JSX.Element;
|
|
3611
|
+
|
|
3612
|
+
export declare interface StackedChromatogramChartProps extends Omit<ChromatogramChartProps, "series" | "annotations" | "yRange"> {
|
|
3613
|
+
/** Array of data series to display */
|
|
3614
|
+
series: ChromatogramSeries[];
|
|
3615
|
+
/** Stacking mode: 'overlay' (default) or 'stack' */
|
|
3616
|
+
stackingMode?: StackingMode;
|
|
3617
|
+
/**
|
|
3618
|
+
* Y-offset between stacked series in data units (e.g., AU).
|
|
3619
|
+
* Only applies in 'stack' mode; ignored in 'overlay'.
|
|
3620
|
+
*/
|
|
3621
|
+
stackOffset?: number;
|
|
3622
|
+
/**
|
|
3623
|
+
* Peak annotations per series, parallel to the series array.
|
|
3624
|
+
* annotations[i] corresponds to series[i].
|
|
3625
|
+
* In stack mode, y values are shifted by the series offset.
|
|
3626
|
+
*/
|
|
3627
|
+
annotations?: PeakAnnotation[][];
|
|
3628
|
+
/**
|
|
3629
|
+
* Controls which end of the stack series[0] lands on (stack mode only).
|
|
3630
|
+
* - "first-on-bottom" (default) — series[0] sits at the base; series[N-1] is highest.
|
|
3631
|
+
* - "first-on-top" — series[0] is shifted to the top; series[N-1] is at the base.
|
|
3632
|
+
* Annotations follow the chosen direction.
|
|
3633
|
+
*/
|
|
3634
|
+
stackingOrder?: "first-on-bottom" | "first-on-top";
|
|
3635
|
+
}
|
|
3636
|
+
|
|
3637
|
+
export declare type StackingMode = "overlay" | "stack";
|
|
3638
|
+
|
|
3504
3639
|
export declare function StatCard({ label, value, delta, deltaLabel, trend, description, className, ...props }: StatCardProps): JSX.Element;
|
|
3505
3640
|
|
|
3506
3641
|
export declare interface StatCardProps extends React_2.ComponentProps<"div"> {
|
|
@@ -4000,6 +4135,12 @@ declare type ToolUIPartApproval = {
|
|
|
4000
4135
|
*/
|
|
4001
4136
|
export declare const toPlotlyColorscale: (ramp: readonly string[]) => Array<[number, string]>;
|
|
4002
4137
|
|
|
4138
|
+
declare interface TransformResult {
|
|
4139
|
+
series: ChromatogramSeries[];
|
|
4140
|
+
annotations: PeakAnnotation[];
|
|
4141
|
+
yRange: [number, number];
|
|
4142
|
+
}
|
|
4143
|
+
|
|
4003
4144
|
export declare function triagePlateMapCsvByBarcode(text: string, options?: PlateMapCsvTriageOptions): PlateMapCsvTriage;
|
|
4004
4145
|
|
|
4005
4146
|
export declare function triagePlateMapCsvFile(file: File, options?: PlateMapCsvTriageOptions): Promise<PlateMapCsvTriage | undefined>;
|