@abi-software/simulationvuer 3.0.10 → 3.0.12
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/simulationvuer.js +1689 -1678
- package/dist/simulationvuer.umd.cjs +2 -2
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/src/components/SimulationVuer.vue +56 -9
package/package.json
CHANGED
|
@@ -274,7 +274,8 @@ export default {
|
|
|
274
274
|
|
|
275
275
|
this.activeSubscriptions.push(payload);
|
|
276
276
|
|
|
277
|
-
//
|
|
277
|
+
// Ask OpenCOR to track the simulation data associated with the subscription's component and variable (and the
|
|
278
|
+
// VOI, if requested).
|
|
278
279
|
|
|
279
280
|
const modelParameters = [];
|
|
280
281
|
|
|
@@ -292,6 +293,48 @@ export default {
|
|
|
292
293
|
* @arg `subscriptionId `
|
|
293
294
|
*/
|
|
294
295
|
removeDataSubscription(subscriptionId) {
|
|
296
|
+
// Ask OpenCOR to stop tracking the simulation data associated with the subscription's component and variable (and
|
|
297
|
+
// the VOI, if requested and unless it's requested by another subscription).
|
|
298
|
+
|
|
299
|
+
const subscription = this.activeSubscriptions.find((activeSubscription) => {
|
|
300
|
+
return activeSubscription.windowId === subscriptionId;
|
|
301
|
+
});
|
|
302
|
+
|
|
303
|
+
if (!subscription) {
|
|
304
|
+
console.warn(`removeDataSubscription: no active subscription found for id ${subscriptionId}.`);
|
|
305
|
+
|
|
306
|
+
return;
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
const isVoiTrackedByAnotherSubscription = this.activeSubscriptions.some((activeSubscription) => {
|
|
310
|
+
return activeSubscription.windowId !== subscriptionId && activeSubscription.withVOI;
|
|
311
|
+
});
|
|
312
|
+
const isModelParameterTrackedByAnotherSubscription = this.activeSubscriptions.some((activeSubscription) => {
|
|
313
|
+
return (
|
|
314
|
+
activeSubscription.windowId !== subscriptionId &&
|
|
315
|
+
activeSubscription.component === subscription.component &&
|
|
316
|
+
activeSubscription.variable === subscription.variable
|
|
317
|
+
);
|
|
318
|
+
});
|
|
319
|
+
|
|
320
|
+
if (!isVoiTrackedByAnotherSubscription || !isModelParameterTrackedByAnotherSubscription) {
|
|
321
|
+
const modelParameters = [];
|
|
322
|
+
|
|
323
|
+
if (subscription.withVOI && !isVoiTrackedByAnotherSubscription) {
|
|
324
|
+
modelParameters.push('VOI');
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
if (!isModelParameterTrackedByAnotherSubscription) {
|
|
328
|
+
modelParameters.push(`${subscription.component}/${subscription.variable}`);
|
|
329
|
+
}
|
|
330
|
+
|
|
331
|
+
if (modelParameters.length) {
|
|
332
|
+
this.$refs.opencorRef?.untrackSimulationData(modelParameters);
|
|
333
|
+
}
|
|
334
|
+
}
|
|
335
|
+
|
|
336
|
+
// Remove the subscription from our list of active subscriptions.
|
|
337
|
+
|
|
295
338
|
this.activeSubscriptions = this.activeSubscriptions.filter((activeSubscription) => {
|
|
296
339
|
return activeSubscription.windowId !== subscriptionId;
|
|
297
340
|
});
|
|
@@ -778,7 +821,10 @@ export default {
|
|
|
778
821
|
}
|
|
779
822
|
}
|
|
780
823
|
|
|
781
|
-
:deep(.p-floatlabel:has(input:focus)) label,
|
|
824
|
+
:deep(.p-floatlabel:has(input:focus)) label,
|
|
825
|
+
:deep(.p-floatlabel:has(input:-webkit-autofill)) label,
|
|
826
|
+
:deep(.p-floatlabel:has(textarea:focus)) label,
|
|
827
|
+
:deep(.p-floatlabel:has(.p-inputwrapper-focus)) label {
|
|
782
828
|
color: #8300BF;
|
|
783
829
|
}
|
|
784
830
|
|
|
@@ -786,6 +832,10 @@ export default {
|
|
|
786
832
|
border-color: #8300BF;
|
|
787
833
|
}
|
|
788
834
|
|
|
835
|
+
:deep(.p-progressbar-value) {
|
|
836
|
+
background-color: #8300BF !important;
|
|
837
|
+
}
|
|
838
|
+
|
|
789
839
|
:deep(.p-select:not(.p-disabled).p-focus) {
|
|
790
840
|
border-color: #8300BF;
|
|
791
841
|
}
|
|
@@ -993,8 +1043,10 @@ span.error {
|
|
|
993
1043
|
<style>
|
|
994
1044
|
/* Note: not sure why, but the following rules need to be global!? */
|
|
995
1045
|
|
|
996
|
-
.p-
|
|
997
|
-
|
|
1046
|
+
.p-contextmenu-item-label,
|
|
1047
|
+
.p-select-option-label {
|
|
1048
|
+
font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
|
|
1049
|
+
font-size: 0.875rem;
|
|
998
1050
|
}
|
|
999
1051
|
|
|
1000
1052
|
.p-select-option:not(.p-select-option-selected):not(.p-disabled).p-focus {
|
|
@@ -1010,9 +1062,4 @@ span.error {
|
|
|
1010
1062
|
background: white !important;
|
|
1011
1063
|
color: #8300BF !important;
|
|
1012
1064
|
}
|
|
1013
|
-
|
|
1014
|
-
.p-select-option-label {
|
|
1015
|
-
font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
|
|
1016
|
-
font-size: 0.875rem;
|
|
1017
|
-
}
|
|
1018
1065
|
</style>
|