Skip to content

Commit 514dec8

Browse files
author
glass-ships
committed
interface modeldata extends plotly plot data
1 parent 05ad9d1 commit 514dec8

File tree

2 files changed

+5
-7
lines changed

2 files changed

+5
-7
lines changed

refl1d/webview/client/package.json

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,10 @@
2828
"vue": "^3.5.13"
2929
},
3030
"devDependencies": {
31+
"@tsconfig/node22": "22.0.0",
3132
"@types/plotly.js": "^2.35.1",
3233
"@types/uuid": "^10.0.0",
3334
"@vitejs/plugin-vue": "^5.2.1",
34-
"@tsconfig/node22": "22.0.0",
3535
"@vue/tsconfig": "^0.7.0",
3636
"@vue/eslint-config-prettier": "10.1.0",
3737
"@vue/eslint-config-typescript": "^14.1.4",
@@ -48,8 +48,5 @@
4848
"prettier-plugin-css-order": "^2.1.2",
4949
"prettier-plugin-jsdoc": "^1.3.0",
5050
"@ianvs/prettier-plugin-sort-imports": "^4.4.0"
51-
},
52-
"trustedDependencies": [
53-
"es5-ext"
54-
]
51+
}
5552
}

refl1d/webview/client/src/components/DataView.vue

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ const reflectivity_type = ref<ReflectivityPlot>("Reflectivity");
3232
const MARKER_OPACITY = 0.5;
3333
type Trace = Partial<Plotly.PlotData>;
3434
type PolarizationString = "" | "--" | "-+" | "+-" | "++" | "unpolarized";
35-
type ModelData = {
35+
// type ModelData = {
36+
interface ModelData extends Plotly.PlotData {
3637
label: string;
3738
polarization: PolarizationString;
3839
Q: number[];
@@ -43,7 +44,7 @@ type ModelData = {
4344
background_in: number;
4445
R?: number[];
4546
dR?: number[];
46-
};
47+
}
4748
4849
function generate_new_traces(model_data: ModelData[][], view: ReflectivityPlot, calculate_residuals: boolean = false) {
4950
if (model_data.length === 0) {

0 commit comments

Comments
 (0)