Skip to content

Commit 645e8c6

Browse files
authored
Added support for external data.
2 parents 49518cd + d3549ef commit 645e8c6

38 files changed

+20494
-505
lines changed

bun.lock

Lines changed: 73 additions & 79 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

electron.vite.config.ts

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,6 @@ export default electronVite.defineConfig({
2828
target: 'esnext'
2929
},
3030
envDir: path.join(import.meta.dirname, 'src/renderer'),
31-
optimizeDeps: {
32-
esbuildOptions: {
33-
target: 'esnext'
34-
}
35-
},
3631
plugins: [
3732
// Note: this must be in sync with src/renderer/vite.config.ts.
3833

package.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
"url": "git+https://github.com/opencor/webapp.git"
2424
},
2525
"type": "module",
26-
"version": "0.20260325.2",
26+
"version": "0.20260330.0",
2727
"engines": {
2828
"bun": ">=1.2.0"
2929
},
@@ -64,7 +64,7 @@
6464
"xxhash-wasm": "^1.1.0"
6565
},
6666
"devDependencies": {
67-
"@biomejs/biome": "^2.4.8",
67+
"@biomejs/biome": "^2.4.9",
6868
"@electron-toolkit/tsconfig": "^2.0.0",
6969
"@electron-toolkit/utils": "^4.0.0",
7070
"@tailwindcss/postcss": "^4.2.2",
@@ -73,26 +73,26 @@
7373
"@types/plotly.js": "^3.0.10",
7474
"@vitejs/plugin-vue": "^6.0.5",
7575
"@vue/tsconfig": "^0.9.1",
76-
"@wasm-fmt/clang-format": "^22.1.1",
76+
"@wasm-fmt/clang-format": "^22.1.2",
7777
"autoprefixer": "^10.4.27",
7878
"cmake-js": "^8.0.0",
79-
"electron": "^41.0.3",
79+
"electron": "^41.1.0",
8080
"electron-builder": "^26.8.1",
8181
"electron-conf": "^1.3.0",
8282
"electron-updater": "^6.8.3",
8383
"electron-vite": "^5.0.0",
8484
"esbuild": "^0.27.4",
85-
"node-addon-api": "^8.6.0",
85+
"node-addon-api": "^8.7.0",
8686
"postcss": "^8.5.8",
8787
"rollup-plugin-visualizer": "^7.0.1",
88-
"stylelint": "^17.5.0",
88+
"stylelint": "^17.6.0",
8989
"stylelint-config-standard": "^40.0.0",
9090
"tailwindcss": "^4.2.2",
9191
"tailwindcss-primeui": "^0.6.1",
9292
"tar": "^7.5.13",
9393
"typescript": "^6.0.2",
9494
"unplugin-vue-components": "^32.0.0",
95-
"vite": "^7.3.1",
95+
"vite": "^8.0.3",
9696
"vue-tsc": "^3.2.6"
9797
}
9898
}

src/renderer/bun.lock

Lines changed: 58 additions & 66 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/renderer/package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
},
4343
"./style.css": "./dist/opencor.css"
4444
},
45-
"version": "0.20260325.2",
45+
"version": "0.20260330.0",
4646
"scripts": {
4747
"build": "vite build && bun scripts/generate.version.js",
4848
"build:lib": "vite build --config vite.lib.config.ts && bunx --bun vue-tsc --project tsconfig.lib.types.json",
@@ -75,7 +75,7 @@
7575
"xxhash-wasm": "^1.1.0"
7676
},
7777
"devDependencies": {
78-
"@biomejs/biome": "^2.4.8",
78+
"@biomejs/biome": "^2.4.9",
7979
"@tailwindcss/postcss": "^4.2.2",
8080
"@tailwindcss/vite": "^4.2.2",
8181
"@types/node": "^25.5.0",
@@ -86,13 +86,13 @@
8686
"esbuild": "^0.27.4",
8787
"postcss": "^8.5.8",
8888
"rollup-plugin-visualizer": "^7.0.1",
89-
"stylelint": "^17.5.0",
89+
"stylelint": "^17.6.0",
9090
"stylelint-config-standard": "^40.0.0",
9191
"tailwindcss": "^4.2.2",
9292
"tailwindcss-primeui": "^0.6.1",
9393
"typescript": "^6.0.2",
9494
"unplugin-vue-components": "^32.0.0",
95-
"vite": "^7.3.1",
95+
"vite": "^8.0.3",
9696
"vue-tsc": "^3.2.6"
9797
}
9898
}

src/renderer/scripts/dependencies.update.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,15 @@ import path from 'node:path';
66
import { fileURLToPath } from 'node:url';
77

88
const run = (command, args) => {
9-
const result = spawnSync({
9+
const res = spawnSync({
1010
cmd: [command, ...args],
1111
stdio: ['inherit', 'inherit', 'inherit']
1212
});
1313

14-
if (result.exitCode !== 0) {
14+
if (res.exitCode !== 0) {
1515
console.error(`Command failed: ${command} ${args.join(' ')}`);
1616

17-
process.exit(result.exitCode);
17+
process.exit(res.exitCode);
1818
}
1919
};
2020

src/renderer/src/common/common.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -120,23 +120,23 @@ export const formatTime = (time: number): string => {
120120
let res = '';
121121

122122
if (d) {
123-
res = `${String(d)}d`;
123+
res = `${d}d`;
124124
}
125125

126126
if (h || ((m || s || ms) && res)) {
127-
res += `${res ? ' ' : ''}${String(h)}h`;
127+
res += `${res ? ' ' : ''}${h}h`;
128128
}
129129

130130
if (m || ((s || ms) && res)) {
131-
res += `${res ? ' ' : ''}${String(m)}m`;
131+
res += `${res ? ' ' : ''}${m}m`;
132132
}
133133

134134
if (s || (ms && res)) {
135-
res += `${res ? ' ' : ''}${String(s)}s`;
135+
res += `${res ? ' ' : ''}${s}s`;
136136
}
137137

138138
if (ms || !res) {
139-
res += `${res ? ' ' : ''}${String(ms)}ms`;
139+
res += `${res ? ' ' : ''}${ms}ms`;
140140
}
141141

142142
return res;

src/renderer/src/common/constants.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,4 @@ export const SPIN_REPEAT_DELAY: number = 40;
1313

1414
const crtYear: number = new Date().getFullYear();
1515

16-
export const COPYRIGHT: string = crtYear === 2025 ? '2025' : `2025-${String(crtYear)}`;
16+
export const COPYRIGHT: string = crtYear === 2025 ? '2025' : `2025-${crtYear}`;

src/renderer/src/common/locCommon.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ export const file = (
192192
}
193193

194194
throw new Error(
195-
`Failed to fetch the file through OpenCOR's CORS proxy. The server responded with a status of ${String(response.status)}.`
195+
`Failed to fetch the file through OpenCOR's CORS proxy. The server responded with a status of ${response.status}.`
196196
);
197197
})
198198
.catch((error: unknown) => {
@@ -209,7 +209,7 @@ export const file = (
209209
}
210210

211211
throw new Error(
212-
`Failed to fetch the file directly. The server responded with a status of ${String(response.status)}.`
212+
`Failed to fetch the file directly. The server responded with a status of ${response.status}.`
213213
);
214214
});
215215
})

0 commit comments

Comments
 (0)