File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2323 "url" : " git+https://github.com/opencor/webapp.git"
2424 },
2525 "type" : " module" ,
26- "version" : " 0.20260304.1 " ,
26+ "version" : " 0.20260304.2 " ,
2727 "engines" : {
2828 "bun" : " >=1.2.0"
2929 },
Original file line number Diff line number Diff line change 22 IOpenCOREmits ,
33 IOpenCORExpose ,
44 IOpenCORProps ,
5- IOpenCORSimulationData ,
5+ IOpenCORSimulationDataEvent ,
66 OpenCORSimulationData ,
77 OpenCORTheme
88} from './index.ts' ;
Original file line number Diff line number Diff line change @@ -12,12 +12,12 @@ export interface IOpenCORExpose {
1212}
1313
1414export interface IOpenCOREmits extends /* @vue -ignore */ Record < string , unknown [ ] > {
15- simulationData : [ IOpenCORSimulationData ] ;
15+ simulationData : [ IOpenCORSimulationDataEvent ] ;
1616}
1717
1818export type OpenCORSimulationData = Record < string , Float64Array | undefined > ;
1919
20- export interface IOpenCORSimulationData {
20+ export interface IOpenCORSimulationDataEvent {
2121 simulationData : OpenCORSimulationData ;
2222 issues : string [ ] ;
2323}
Original file line number Diff line number Diff line change 4242 },
4343 "./style.css" : " ./dist/opencor.css"
4444 },
45- "version" : " 0.20260304.1 " ,
45+ "version" : " 0.20260304.2 " ,
4646 "scripts" : {
4747 "build" : " vite build && bun scripts/generate.version.js" ,
4848 "build:lib" : " vite build --config vite.lib.config.ts && bun scripts/copy.indexdts.js" ,
Original file line number Diff line number Diff line change 1919<script setup lang="ts">
2020import * as vue from ' vue' ;
2121
22- import type { IOpenCORExpose , IOpenCORSimulationData } from ' ../index.ts' ;
22+ import type { IOpenCORExpose , IOpenCORSimulationDataEvent } from ' ../index.ts' ;
2323
2424import OpenCOR from ' ./components/OpenCOR.vue' ;
2525
@@ -55,18 +55,18 @@ const untrackAllModelParameters = () => {
5555 simulationDataTracked .value = [];
5656};
5757
58- const onSimulationData = (res : IOpenCORSimulationData ) => {
58+ const onSimulationData = (event : IOpenCORSimulationDataEvent ) => {
5959 console .log (' ---[Simulation data]---' );
6060
61- for (const modelParameter of Object .keys (res .simulationData )) {
61+ for (const modelParameter of Object .keys (event .simulationData )) {
6262 console .log (` Simulation data for "${modelParameter }": ` );
63- console .log (res .simulationData [modelParameter ]);
63+ console .log (event .simulationData [modelParameter ]);
6464 }
6565
66- if (res .issues .length > 0 ) {
66+ if (event .issues .length > 0 ) {
6767 console .log (' Issues:' );
6868
69- res .issues .forEach ((issue : string ) => {
69+ event .issues .forEach ((issue : string ) => {
7070 console .log (` - ${issue } ` );
7171 });
7272 } else {
Original file line number Diff line number Diff line change @@ -71,7 +71,7 @@ import { electronApi } from '../common/electronApi.ts';
7171import * as locApi from ' ../libopencor/locApi.ts' ;
7272
7373import SimulationExperimentView from ' ./views/SimulationExperimentView.vue' ;
74- import type { IOpenCORSimulationData } from ' ../../index.ts' ;
74+ import type { IOpenCORSimulationDataEvent } from ' ../../index.ts' ;
7575
7676interface IFileTab {
7777 file: locApi .File ;
@@ -178,7 +178,7 @@ const closeAllFiles = (): void => {
178178 }
179179};
180180
181- const simulationData = (modelParameters : string []): Promise <IOpenCORSimulationData > => {
181+ const simulationData = (modelParameters : string []): Promise <IOpenCORSimulationDataEvent > => {
182182 if (! props .simulationOnly ) {
183183 return Promise .resolve ({
184184 simulationData: common .undefinedSimulationData (modelParameters ),
Original file line number Diff line number Diff line change @@ -247,7 +247,7 @@ import * as vueusecore from '@vueuse/core';
247247import Popover from ' primevue/popover' ;
248248import * as vue from ' vue' ;
249249
250- import type { IOpenCORSimulationData } from ' ../../../index.ts' ;
250+ import type { IOpenCORSimulationDataEvent } from ' ../../../index.ts' ;
251251
252252import * as colors from ' ../../common/colors.ts' ;
253253import * as common from ' ../../common/common.ts' ;
@@ -669,8 +669,8 @@ const interactiveOldSettings = vue.ref<string>(JSON.stringify(vue.toRaw(interact
669669
670670// A helper function to retrieve simulation data for one or more model parameters.
671671
672- const simulationData = (modelParameters : string []): Promise <IOpenCORSimulationData > => {
673- const res: IOpenCORSimulationData = {
672+ const simulationData = (modelParameters : string []): Promise <IOpenCORSimulationDataEvent > => {
673+ const res: IOpenCORSimulationDataEvent = {
674674 simulationData: common .undefinedSimulationData (modelParameters ),
675675 issues: []
676676 };
You can’t perform that action at this time.
0 commit comments