react-os-shell 0.3.11 → 0.3.13
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-LTLVDRYP.js → Browser-6JQTSHQF.js} +3 -3
- package/dist/{Browser-LTLVDRYP.js.map → Browser-6JQTSHQF.js.map} +1 -1
- package/dist/{Calculator-R27HR2QS.js → Calculator-6ANBG6S2.js} +4 -4
- package/dist/{Calculator-R27HR2QS.js.map → Calculator-6ANBG6S2.js.map} +1 -1
- package/dist/{Calendar-7LZR4JFF.js → Calendar-R4IBIPIU.js} +3 -3
- package/dist/{Calendar-7LZR4JFF.js.map → Calendar-R4IBIPIU.js.map} +1 -1
- package/dist/{CurrencyConverter-2HOKHG57.js → CurrencyConverter-RVLGYNDE.js} +4 -4
- package/dist/{CurrencyConverter-2HOKHG57.js.map → CurrencyConverter-RVLGYNDE.js.map} +1 -1
- package/dist/{Documents-5JVPDRMQ.js → Documents-AUK2YPDI.js} +3 -3
- package/dist/{Documents-5JVPDRMQ.js.map → Documents-AUK2YPDI.js.map} +1 -1
- package/dist/{Email-W6QOOSVU.js → Email-7FJHS6Y7.js} +3 -3
- package/dist/{Email-W6QOOSVU.js.map → Email-7FJHS6Y7.js.map} +1 -1
- package/dist/Files-SDJNXCBA.js +11 -0
- package/dist/{Files-L7YDPTYL.js.map → Files-SDJNXCBA.js.map} +1 -1
- package/dist/{Minesweeper-FD5O42OI.js → Minesweeper-ZDK33A6S.js} +3 -3
- package/dist/{Minesweeper-FD5O42OI.js.map → Minesweeper-ZDK33A6S.js.map} +1 -1
- package/dist/{Notepad-SK6OPBVW.js → Notepad-SRHBJ75G.js} +3 -3
- package/dist/{Notepad-SK6OPBVW.js.map → Notepad-SRHBJ75G.js.map} +1 -1
- package/dist/{PomodoroTimer-JYV2DEED.js → PomodoroTimer-OJMQVA4G.js} +4 -4
- package/dist/{PomodoroTimer-JYV2DEED.js.map → PomodoroTimer-OJMQVA4G.js.map} +1 -1
- package/dist/Preview-TM66HUAB.js +8 -0
- package/dist/{Preview-ZMU2376L.js.map → Preview-TM66HUAB.js.map} +1 -1
- package/dist/Spreadsheet-DCCAXIY5.js +6 -0
- package/dist/{Spreadsheet-SBN532NF.js.map → Spreadsheet-DCCAXIY5.js.map} +1 -1
- package/dist/{Weather-BDBAUFOF.js → Weather-ZYNKEAOJ.js} +4 -4
- package/dist/{Weather-BDBAUFOF.js.map → Weather-ZYNKEAOJ.js.map} +1 -1
- package/dist/{WorldClock-FIDZCNY6.js → WorldClock-A6P3MXEI.js} +4 -4
- package/dist/{WorldClock-FIDZCNY6.js.map → WorldClock-A6P3MXEI.js.map} +1 -1
- package/dist/apps/index.js +19 -19
- package/dist/{chunk-WKET7CLC.js → chunk-AUVFH7ZO.js} +3 -3
- package/dist/{chunk-WKET7CLC.js.map → chunk-AUVFH7ZO.js.map} +1 -1
- package/dist/{chunk-WGPDZ54I.js → chunk-BN6O5UP4.js} +4 -4
- package/dist/{chunk-WGPDZ54I.js.map → chunk-BN6O5UP4.js.map} +1 -1
- package/dist/{chunk-F3XQURUE.js → chunk-C2FMUKVE.js} +3 -3
- package/dist/{chunk-F3XQURUE.js.map → chunk-C2FMUKVE.js.map} +1 -1
- package/dist/{chunk-CNOME73V.js → chunk-GI7ABQPU.js} +18 -25
- package/dist/chunk-GI7ABQPU.js.map +1 -0
- package/dist/{chunk-HTXOHKRX.js → chunk-WFXSWH4D.js} +4 -4
- package/dist/{chunk-HTXOHKRX.js.map → chunk-WFXSWH4D.js.map} +1 -1
- package/dist/{chunk-Z3256PR3.js → chunk-Z4JTKA7I.js} +3 -3
- package/dist/{chunk-Z3256PR3.js.map → chunk-Z4JTKA7I.js.map} +1 -1
- package/dist/index.js +6 -6
- package/package.json +1 -1
- package/dist/Files-L7YDPTYL.js +0 -11
- package/dist/Preview-ZMU2376L.js +0 -8
- package/dist/Spreadsheet-SBN532NF.js +0 -6
- package/dist/chunk-CNOME73V.js.map +0 -1
|
@@ -2240,6 +2240,13 @@ function WindowManagerProvider({ children }) {
|
|
|
2240
2240
|
const closeEntity = useCallback((id) => {
|
|
2241
2241
|
setOpenWindows((prev) => prev.filter((m) => m.id !== id));
|
|
2242
2242
|
}, []);
|
|
2243
|
+
const activateAfterMount = (windowKey) => {
|
|
2244
|
+
setTimeout(() => {
|
|
2245
|
+
const panel = document.querySelector(`[data-modal-panel][data-window-key="${windowKey}"]`);
|
|
2246
|
+
const mid = panel?.getAttribute("data-modal-id");
|
|
2247
|
+
if (mid) activateModal(mid);
|
|
2248
|
+
}, 50);
|
|
2249
|
+
};
|
|
2243
2250
|
const openEntity = useCallback((entityType, entityId, snapshot, label, route) => {
|
|
2244
2251
|
if (!WINDOW_REGISTRY[entityType] || !isEntityEntry(WINDOW_REGISTRY[entityType])) return;
|
|
2245
2252
|
const id = label || entityId;
|
|
@@ -2247,18 +2254,10 @@ function WindowManagerProvider({ children }) {
|
|
|
2247
2254
|
setOpenWindows((prev) => {
|
|
2248
2255
|
const existing = prev.find((m) => m.entityId === entityId && m.entityType === entityType);
|
|
2249
2256
|
if (existing) {
|
|
2250
|
-
|
|
2251
|
-
const panels = document.querySelectorAll("[data-modal-panel]");
|
|
2252
|
-
panels.forEach((p) => {
|
|
2253
|
-
const titleEl = p.querySelector("[data-window-title]");
|
|
2254
|
-
if (titleEl?.textContent?.includes(existing.label)) {
|
|
2255
|
-
const mid = p.getAttribute("data-modal-id");
|
|
2256
|
-
if (mid) activateModal(mid);
|
|
2257
|
-
}
|
|
2258
|
-
});
|
|
2259
|
-
}, 50);
|
|
2257
|
+
activateAfterMount(existing.id);
|
|
2260
2258
|
return prev;
|
|
2261
2259
|
}
|
|
2260
|
+
activateAfterMount(id);
|
|
2262
2261
|
return [...prev, {
|
|
2263
2262
|
id,
|
|
2264
2263
|
type: "modal",
|
|
@@ -2279,9 +2278,10 @@ function WindowManagerProvider({ children }) {
|
|
|
2279
2278
|
if (entry.multiInstance) {
|
|
2280
2279
|
const instanceCount = prev.filter((m) => m.type === "page" && m.route === path).length;
|
|
2281
2280
|
const nextNum = instanceCount + 1;
|
|
2282
|
-
const
|
|
2281
|
+
const id2 = `page:${path}:${Math.random().toString(36).slice(2, 8)}`;
|
|
2282
|
+
activateAfterMount(id2);
|
|
2283
2283
|
return [...prev, {
|
|
2284
|
-
id,
|
|
2284
|
+
id: id2,
|
|
2285
2285
|
type: "page",
|
|
2286
2286
|
label: instanceCount === 0 ? entry.label : `${entry.label} ${nextNum}`,
|
|
2287
2287
|
route: path,
|
|
@@ -2293,20 +2293,13 @@ function WindowManagerProvider({ children }) {
|
|
|
2293
2293
|
if (entry.widget) {
|
|
2294
2294
|
return prev.filter((m) => m !== existing);
|
|
2295
2295
|
}
|
|
2296
|
-
|
|
2297
|
-
const panels = document.querySelectorAll("[data-modal-panel]");
|
|
2298
|
-
panels.forEach((p) => {
|
|
2299
|
-
const titleEl = p.querySelector("[data-window-title]");
|
|
2300
|
-
if (titleEl?.textContent?.includes(existing.label)) {
|
|
2301
|
-
const mid = p.getAttribute("data-modal-id");
|
|
2302
|
-
if (mid) activateModal(mid);
|
|
2303
|
-
}
|
|
2304
|
-
});
|
|
2305
|
-
}, 50);
|
|
2296
|
+
activateAfterMount(existing.id);
|
|
2306
2297
|
return prev;
|
|
2307
2298
|
}
|
|
2299
|
+
const id = `page:${path}`;
|
|
2300
|
+
activateAfterMount(id);
|
|
2308
2301
|
return [...prev, {
|
|
2309
|
-
id
|
|
2302
|
+
id,
|
|
2310
2303
|
type: "page",
|
|
2311
2304
|
label: entry.label,
|
|
2312
2305
|
route: path,
|
|
@@ -2361,5 +2354,5 @@ function WindowManagerProvider({ children }) {
|
|
|
2361
2354
|
}
|
|
2362
2355
|
|
|
2363
2356
|
export { CancelButton, CopyButton, DocFavStar, LoadingSpinner, Modal, ModalActions, PopupMenu, PopupMenuDivider, PopupMenuItem, PopupMenuLabel, ThumbCard, WINDOW_REGISTRY, WindowManagerProvider, WindowTitle, activateModal, client_default, commitExposeHighlight, exitExposeMode, getActiveModalId, getActiveWindowRoute, getExposeHighlight, isEntityEntry, isPageEntry, setExposeHighlight, setShellApiClient, setShellWindowRegistry, setWindowDefaultPosition, subscribeExposeHighlight, toggleExposeMode, useIsMobile, useModalActive, useWidgetSettings, useWindowManager, useWindowMenuItem, useWindowTitle };
|
|
2364
|
-
//# sourceMappingURL=chunk-
|
|
2365
|
-
//# sourceMappingURL=chunk-
|
|
2357
|
+
//# sourceMappingURL=chunk-GI7ABQPU.js.map
|
|
2358
|
+
//# sourceMappingURL=chunk-GI7ABQPU.js.map
|