Expose a method to retrieve simulation data from outside of OpenCOR#440
Expose a method to retrieve simulation data from outside of OpenCOR#440agarny merged 4 commits intoopencor:mainfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR aims to expose a simulationData(modelParameter) method so simulation results can be retrieved programmatically from outside the OpenCOR UI, addressing the need described in issue #439.
Changes:
- Exposes
simulationData()fromSimulationExperimentViewand plumbs it up throughContentsComponenttoOpenCORviadefineExpose. - Introduces a small demo app (
AppWithSimulationData.vue) showing how to call the new API from a parent component. - Refactors renderer-side theme typing (moves
ThemetovueCommon.ts) and includes minor styling/dependency/version updates.
Reviewed changes
Copilot reviewed 9 out of 17 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| src/renderer/src/components/views/SimulationExperimentView.vue | Adds simulationData() and exposes it to parents. |
| src/renderer/src/components/ContentsComponent.vue | Adds a ref to SimulationExperimentView and exposes a pass-through simulationData(). |
| src/renderer/src/components/OpenCOR.vue | Exposes top-level simulationData() delegating to ContentsComponent. |
| src/renderer/src/common/vueCommon.ts | Defines Theme locally instead of importing from the package entry. |
| src/renderer/src/AppWithSimulationData.vue | New demo usage of OpenCOR ref + simulationData(). |
| src/renderer/src/components/dialogs/SimulationExperimentViewSettingsDialog.vue | Removes unused .plot-card styling. |
| src/renderer/src/App.vue / AppWithOmex.vue / AppWithRawOmex.vue / AppWithMultipleInstances.vue / AppWithinContainers.vue | Style import formatting changes. |
| src/renderer/package.json / package.json | Version bump; renderer dev dependency bump. |
| bun.lock / src/renderer/bun.lock | Lockfile updates. |
| src/renderer/index.ts / src/renderer/index.d.ts | Removes the renderer library entry/type declaration files. |
Comments suppressed due to low confidence (1)
src/renderer/package.json:49
- This PR removes
src/renderer/index.tsandsrc/renderer/index.d.ts, butvite.lib.config.tsstill points the library build entry to./index.tsandscripts/copy.indexdts.jsstill copies../index.d.tsintodist. As-is,bun run build:lib(and the packageexports.types) will break; either restore those entry/type files or update the build/scripts/exports to the new entry point.
},
"version": "0.20260303.1",
"scripts": {
"build": "vite build && bun scripts/generate.version.js",
"build:lib": "vite build --config vite.lib.config.ts && bun scripts/copy.indexdts.js",
"clean": "bun scripts/clean.js",
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 9 out of 17 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 10 out of 18 changed files in this pull request and generated 4 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 10 out of 18 changed files in this pull request and generated 2 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 11 out of 19 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Fixes #439.