maxsimcli 3.7.1 → 3.8.1
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/assets/CHANGELOG.md +15 -0
- package/dist/assets/dashboard/client/assets/index-BsuHkXQ_.css +32 -0
- package/dist/assets/dashboard/client/assets/index-DaoQD7tI.js +217 -0
- package/dist/assets/dashboard/client/index.html +2 -2
- package/dist/assets/dashboard/server.js +25 -0
- package/package.json +1 -1
- package/dist/assets/dashboard/client/assets/index-CLHOfmAa.js +0 -209
- package/dist/assets/dashboard/client/assets/index-CgawG8dn.css +0 -32
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
href="https://fonts.googleapis.com/css2?family=Geist:wght@400;500;600;700;800;900&family=Geist+Mono:wght@400;500;600;700&display=swap"
|
|
11
11
|
rel="stylesheet"
|
|
12
12
|
/>
|
|
13
|
-
<script type="module" crossorigin src="/assets/index-
|
|
14
|
-
<link rel="stylesheet" crossorigin href="/assets/index-
|
|
13
|
+
<script type="module" crossorigin src="/assets/index-DaoQD7tI.js"></script>
|
|
14
|
+
<link rel="stylesheet" crossorigin href="/assets/index-BsuHkXQ_.css">
|
|
15
15
|
</head>
|
|
16
16
|
<body>
|
|
17
17
|
<div id="root"></div>
|
|
@@ -58279,6 +58279,31 @@ app.post("/api/shutdown", (_req, res) => {
|
|
|
58279
58279
|
res.json({ shutdown: true });
|
|
58280
58280
|
setTimeout(() => shutdownFn?.(), 100);
|
|
58281
58281
|
});
|
|
58282
|
+
const simpleModeConfigPath = node_path.join(__dirname, "simple-mode-config.json");
|
|
58283
|
+
app.get("/api/simple-mode-config", (_req, res) => {
|
|
58284
|
+
try {
|
|
58285
|
+
if (!node_fs.existsSync(simpleModeConfigPath)) return res.json({});
|
|
58286
|
+
const data = JSON.parse(node_fs.readFileSync(simpleModeConfigPath, "utf-8"));
|
|
58287
|
+
return res.json(data);
|
|
58288
|
+
} catch {
|
|
58289
|
+
return res.json({});
|
|
58290
|
+
}
|
|
58291
|
+
});
|
|
58292
|
+
app.post("/api/simple-mode-config", (req, res) => {
|
|
58293
|
+
const { default_mode } = req.body;
|
|
58294
|
+
if (default_mode !== "simple" && default_mode !== "advanced") return res.status(400).json({ error: "default_mode must be \"simple\" or \"advanced\"" });
|
|
58295
|
+
let existing = {};
|
|
58296
|
+
if (node_fs.existsSync(simpleModeConfigPath)) try {
|
|
58297
|
+
existing = JSON.parse(node_fs.readFileSync(simpleModeConfigPath, "utf-8"));
|
|
58298
|
+
} catch {}
|
|
58299
|
+
existing.default_mode = default_mode;
|
|
58300
|
+
node_fs.writeFileSync(simpleModeConfigPath, JSON.stringify(existing, null, 2), "utf-8");
|
|
58301
|
+
log("INFO", "simple-mode-config", `default_mode set to ${default_mode}`);
|
|
58302
|
+
return res.json({
|
|
58303
|
+
written: true,
|
|
58304
|
+
default_mode
|
|
58305
|
+
});
|
|
58306
|
+
});
|
|
58282
58307
|
if (node_fs.existsSync(clientDir)) app.use(build_default(clientDir, { single: true }));
|
|
58283
58308
|
else app.get("/", (_req, res) => {
|
|
58284
58309
|
res.send("<html><body><p>Dashboard client not found. Run <code>pnpm run build</code> first.</p></body></html>");
|
package/package.json
CHANGED