react-os-shell 3.6.0 → 3.6.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/Browser-RGJLDLYV.js +7 -0
- package/dist/{Browser-KMCFAQ6B.js.map → Browser-RGJLDLYV.js.map} +1 -1
- package/dist/{Calculator-LGYXEZTY.js → Calculator-5PABMVXY.js} +4 -4
- package/dist/{Calculator-LGYXEZTY.js.map → Calculator-5PABMVXY.js.map} +1 -1
- package/dist/{CurrencyConverter-JI5ECSQA.js → CurrencyConverter-2DTZV4JC.js} +4 -4
- package/dist/{CurrencyConverter-JI5ECSQA.js.map → CurrencyConverter-2DTZV4JC.js.map} +1 -1
- package/dist/{Documents-Q3IGUDRC.js → Documents-QXCHQJKC.js} +4 -4
- package/dist/{Documents-Q3IGUDRC.js.map → Documents-QXCHQJKC.js.map} +1 -1
- package/dist/Files-TKXL7YM6.js +12 -0
- package/dist/{Files-JQMMXIM3.js.map → Files-TKXL7YM6.js.map} +1 -1
- package/dist/{Notepad-RGNFWBH7.js → Notepad-UJUXL7Y2.js} +4 -4
- package/dist/{Notepad-RGNFWBH7.js.map → Notepad-UJUXL7Y2.js.map} +1 -1
- package/dist/{PomodoroTimer-5WZ37PLI.js → PomodoroTimer-PFZVSP3I.js} +5 -5
- package/dist/{PomodoroTimer-5WZ37PLI.js.map → PomodoroTimer-PFZVSP3I.js.map} +1 -1
- package/dist/Preview-RXEAN4NM.js +8 -0
- package/dist/{Preview-6QVSOGRM.js.map → Preview-RXEAN4NM.js.map} +1 -1
- package/dist/Spreadsheet-UPQBWU7A.js +7 -0
- package/dist/{Spreadsheet-FHAQX6CU.js.map → Spreadsheet-UPQBWU7A.js.map} +1 -1
- package/dist/{Stock-ERDFTUOZ.js → Stock-OMLDYMWN.js} +4 -4
- package/dist/{Stock-ERDFTUOZ.js.map → Stock-OMLDYMWN.js.map} +1 -1
- package/dist/{Weather-6WBY4ANL.js → Weather-7QUTCZKH.js} +4 -4
- package/dist/{Weather-6WBY4ANL.js.map → Weather-7QUTCZKH.js.map} +1 -1
- package/dist/{WorldClock-ZOLBVSJC.js → WorldClock-M6IVJBYN.js} +4 -4
- package/dist/{WorldClock-ZOLBVSJC.js.map → WorldClock-M6IVJBYN.js.map} +1 -1
- package/dist/apps/index.js +19 -19
- package/dist/{chunk-L5TFGRBY.js → chunk-5AQOJ5BG.js} +5 -5
- package/dist/{chunk-L5TFGRBY.js.map → chunk-5AQOJ5BG.js.map} +1 -1
- package/dist/{chunk-65NSWQAT.js → chunk-H4NP7TMW.js} +4 -4
- package/dist/{chunk-65NSWQAT.js.map → chunk-H4NP7TMW.js.map} +1 -1
- package/dist/{chunk-2OONWKUI.js → chunk-HIJSKVIO.js} +4 -4
- package/dist/{chunk-2OONWKUI.js.map → chunk-HIJSKVIO.js.map} +1 -1
- package/dist/{chunk-6VMTAVUD.js → chunk-L7B66ALK.js} +3 -3
- package/dist/{chunk-6VMTAVUD.js.map → chunk-L7B66ALK.js.map} +1 -1
- package/dist/{chunk-CML7B3S4.js → chunk-O3BLL2WA.js} +4 -4
- package/dist/{chunk-CML7B3S4.js.map → chunk-O3BLL2WA.js.map} +1 -1
- package/dist/{chunk-6OWYD4O6.js → chunk-S22GZ4OQ.js} +31 -2
- package/dist/chunk-S22GZ4OQ.js.map +1 -0
- package/dist/{chunk-JQGXIQVO.js → chunk-UNSKKZIK.js} +4 -4
- package/dist/{chunk-JQGXIQVO.js.map → chunk-UNSKKZIK.js.map} +1 -1
- package/dist/{chunk-TVSL5Y5H.js → chunk-W75O4R5Y.js} +4 -4
- package/dist/{chunk-TVSL5Y5H.js.map → chunk-W75O4R5Y.js.map} +1 -1
- package/dist/{chunk-XRBSB7FX.js → chunk-WPZDC7HH.js} +3 -3
- package/dist/{chunk-XRBSB7FX.js.map → chunk-WPZDC7HH.js.map} +1 -1
- package/dist/index.js +10 -10
- package/package.json +1 -1
- package/dist/Browser-KMCFAQ6B.js +0 -7
- package/dist/Files-JQMMXIM3.js +0 -12
- package/dist/Preview-6QVSOGRM.js +0 -8
- package/dist/Spreadsheet-FHAQX6CU.js +0 -7
- package/dist/chunk-6OWYD4O6.js.map +0 -1
|
@@ -2387,6 +2387,34 @@ var DEFAULT_WIDGETS = [
|
|
|
2387
2387
|
{ id: "page:/currency", type: "page", label: "Currency Converter", route: "/currency" },
|
|
2388
2388
|
{ id: "page:/world-clock", type: "page", label: "World Clock", route: "/world-clock" }
|
|
2389
2389
|
];
|
|
2390
|
+
function seedDefaultWidgetPositions(widgets) {
|
|
2391
|
+
const PAD = 20, GAP = 16, MAX_AUTO_H = 220;
|
|
2392
|
+
const cs = getComputedStyle(document.documentElement);
|
|
2393
|
+
const tbH = parseInt(cs.getPropertyValue("--taskbar-height")) || 0;
|
|
2394
|
+
const tbW = parseInt(cs.getPropertyValue("--taskbar-width")) || 0;
|
|
2395
|
+
const tbPos = cs.getPropertyValue("--taskbar-position").trim() || "bottom";
|
|
2396
|
+
const sidebarW = parseInt(cs.getPropertyValue("--sidebar-width")) || 0;
|
|
2397
|
+
const leftStart = (tbPos === "left" ? tbW : 0) + sidebarW + PAD;
|
|
2398
|
+
const topStart = (tbPos === "top" ? tbH : 0) + PAD;
|
|
2399
|
+
const maxBottom = window.innerHeight - (tbPos === "bottom" ? tbH : 0) - PAD;
|
|
2400
|
+
const rightLimit = window.innerWidth - PAD;
|
|
2401
|
+
let x = leftStart, y = topStart;
|
|
2402
|
+
for (const item of widgets) {
|
|
2403
|
+
if (!item.route) continue;
|
|
2404
|
+
const e = WINDOW_REGISTRY[item.route];
|
|
2405
|
+
if (!e || !isPageEntry(e)) continue;
|
|
2406
|
+
const entry = e;
|
|
2407
|
+
const w = entry.dimensions?.[0] ?? 320;
|
|
2408
|
+
const h = entry.dimensions?.[1] ?? 240;
|
|
2409
|
+
const stackH = entry.autoHeight ? Math.min(h, MAX_AUTO_H) : h;
|
|
2410
|
+
if (y > topStart && y + stackH > maxBottom && x + (w + GAP) + w <= rightLimit) {
|
|
2411
|
+
x += w + GAP;
|
|
2412
|
+
y = topStart;
|
|
2413
|
+
}
|
|
2414
|
+
setWindowDefaultPosition(item.id, { x, y, w, h });
|
|
2415
|
+
y += stackH + GAP;
|
|
2416
|
+
}
|
|
2417
|
+
}
|
|
2390
2418
|
function restoreWindowState() {
|
|
2391
2419
|
try {
|
|
2392
2420
|
if (window.location.pathname === "/login") return [];
|
|
@@ -2395,6 +2423,7 @@ function restoreWindowState() {
|
|
|
2395
2423
|
if (stored) return JSON.parse(stored);
|
|
2396
2424
|
} catch {
|
|
2397
2425
|
}
|
|
2426
|
+
seedDefaultWidgetPositions(DEFAULT_WIDGETS);
|
|
2398
2427
|
return DEFAULT_WIDGETS;
|
|
2399
2428
|
}
|
|
2400
2429
|
var AUTH_PAGES = ["/login", "/forgot-password", "/reset-password", "/force-change-password"];
|
|
@@ -2534,5 +2563,5 @@ function WindowManagerProvider({ children }) {
|
|
|
2534
2563
|
}
|
|
2535
2564
|
|
|
2536
2565
|
export { CancelButton, CopyButton, DocFavStar, LoadingSpinner, Modal, ModalActions, PopupMenu, PopupMenuDivider, PopupMenuItem, PopupMenuLabel, ShellPrefsProvider, ThumbCard, WINDOW_REGISTRY, WindowCrashedFallback, WindowErrorBoundary, WindowManagerProvider, WindowTitle, activateModal, client_default, commitExposeHighlight, exitExposeMode, getActiveModalId, getActiveWindowRoute, getExposeHighlight, getWindowPosition, isEntityEntry, isPageEntry, registerModalEscapeInterceptor, setExposeHighlight, setShellApiClient, setShellWindowRegistry, setWindowDefaultPosition, setWindowPosition, subscribeExposeHighlight, toggleExposeMode, useIsMobile, useLocalStoragePrefs, useModalActive, useShellPrefs, useWidgetSettings, useWindowManager, useWindowMenuItem, useWindowTitle };
|
|
2537
|
-
//# sourceMappingURL=chunk-
|
|
2538
|
-
//# sourceMappingURL=chunk-
|
|
2566
|
+
//# sourceMappingURL=chunk-S22GZ4OQ.js.map
|
|
2567
|
+
//# sourceMappingURL=chunk-S22GZ4OQ.js.map
|