react-os-shell 3.8.5 → 3.8.6

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.
Files changed (53) hide show
  1. package/dist/Browser-P7SNR5LU.js +7 -0
  2. package/dist/{Browser-46EJUBW5.js.map → Browser-P7SNR5LU.js.map} +1 -1
  3. package/dist/{Calculator-5E7C5YLX.js → Calculator-2HX5CQHC.js} +4 -4
  4. package/dist/{Calculator-5E7C5YLX.js.map → Calculator-2HX5CQHC.js.map} +1 -1
  5. package/dist/{CurrencyConverter-27Q7CDIJ.js → CurrencyConverter-CCYVPA2T.js} +4 -4
  6. package/dist/{CurrencyConverter-27Q7CDIJ.js.map → CurrencyConverter-CCYVPA2T.js.map} +1 -1
  7. package/dist/{Documents-U7KFKFNT.js → Documents-ADOY3W75.js} +4 -4
  8. package/dist/{Documents-U7KFKFNT.js.map → Documents-ADOY3W75.js.map} +1 -1
  9. package/dist/Files-RN4J6XLJ.js +12 -0
  10. package/dist/{Files-ZBUFKYWD.js.map → Files-RN4J6XLJ.js.map} +1 -1
  11. package/dist/{Notepad-5OGGCJGO.js → Notepad-BK5LWKJD.js} +4 -4
  12. package/dist/{Notepad-5OGGCJGO.js.map → Notepad-BK5LWKJD.js.map} +1 -1
  13. package/dist/{PomodoroTimer-2FXTKPCH.js → PomodoroTimer-CHR6G3HN.js} +5 -5
  14. package/dist/{PomodoroTimer-2FXTKPCH.js.map → PomodoroTimer-CHR6G3HN.js.map} +1 -1
  15. package/dist/Preview-7IAIHIKG.js +8 -0
  16. package/dist/{Preview-JA4S64C6.js.map → Preview-7IAIHIKG.js.map} +1 -1
  17. package/dist/Spreadsheet-256IMVEN.js +7 -0
  18. package/dist/{Spreadsheet-G6CQ6FU4.js.map → Spreadsheet-256IMVEN.js.map} +1 -1
  19. package/dist/{Stock-YZFDBHRV.js → Stock-ALK2CV7R.js} +4 -4
  20. package/dist/{Stock-YZFDBHRV.js.map → Stock-ALK2CV7R.js.map} +1 -1
  21. package/dist/{Weather-ECNKTQWZ.js → Weather-CW5JMDKQ.js} +4 -4
  22. package/dist/{Weather-ECNKTQWZ.js.map → Weather-CW5JMDKQ.js.map} +1 -1
  23. package/dist/{WorldClock-WRIK5RPI.js → WorldClock-7B4JZOQR.js} +4 -4
  24. package/dist/{WorldClock-WRIK5RPI.js.map → WorldClock-7B4JZOQR.js.map} +1 -1
  25. package/dist/apps/index.d.ts +14 -13
  26. package/dist/apps/index.js +19 -19
  27. package/dist/{chunk-HJ5ZNXPB.js → chunk-JXW7H3DU.js} +54 -3
  28. package/dist/chunk-JXW7H3DU.js.map +1 -0
  29. package/dist/{chunk-YWRNK24T.js → chunk-K2EXGE4R.js} +5 -5
  30. package/dist/{chunk-YWRNK24T.js.map → chunk-K2EXGE4R.js.map} +1 -1
  31. package/dist/{chunk-S3ZVBCKK.js → chunk-K4673QDA.js} +4 -4
  32. package/dist/{chunk-S3ZVBCKK.js.map → chunk-K4673QDA.js.map} +1 -1
  33. package/dist/{chunk-3T75O6VR.js → chunk-NMZUO4FQ.js} +4 -4
  34. package/dist/{chunk-3T75O6VR.js.map → chunk-NMZUO4FQ.js.map} +1 -1
  35. package/dist/{chunk-3BN3QZX5.js → chunk-PM5G3GVW.js} +3 -3
  36. package/dist/{chunk-3BN3QZX5.js.map → chunk-PM5G3GVW.js.map} +1 -1
  37. package/dist/{chunk-QTDUNBNQ.js → chunk-TPVASTEY.js} +4 -4
  38. package/dist/{chunk-QTDUNBNQ.js.map → chunk-TPVASTEY.js.map} +1 -1
  39. package/dist/{chunk-6FET2LA4.js → chunk-WSSULY4B.js} +4 -4
  40. package/dist/{chunk-6FET2LA4.js.map → chunk-WSSULY4B.js.map} +1 -1
  41. package/dist/{chunk-OY6GC3ZI.js → chunk-XBV6Y6TT.js} +4 -4
  42. package/dist/{chunk-OY6GC3ZI.js.map → chunk-XBV6Y6TT.js.map} +1 -1
  43. package/dist/{chunk-F2KBTMSP.js → chunk-YLJY5LDU.js} +3 -3
  44. package/dist/{chunk-F2KBTMSP.js.map → chunk-YLJY5LDU.js.map} +1 -1
  45. package/dist/index.d.ts +82 -81
  46. package/dist/index.js +12 -12
  47. package/dist/{types-CXBKusuC.d.ts → types-CTPtgkiG.d.ts} +1 -1
  48. package/package.json +1 -1
  49. package/dist/Browser-46EJUBW5.js +0 -7
  50. package/dist/Files-ZBUFKYWD.js +0 -12
  51. package/dist/Preview-JA4S64C6.js +0 -8
  52. package/dist/Spreadsheet-G6CQ6FU4.js +0 -7
  53. package/dist/chunk-HJ5ZNXPB.js.map +0 -1
@@ -662,6 +662,47 @@ function hideSnapPreview() {
662
662
  snapPreviewEl.style.opacity = "0";
663
663
  snapPreviewEl.style.display = "none";
664
664
  }
665
+ var GESTURE_STYLE_ID = "rosh-gesture-style";
666
+ function ensureGestureStyle() {
667
+ if (typeof document === "undefined" || document.getElementById(GESTURE_STYLE_ID)) return;
668
+ const style = document.createElement("style");
669
+ style.id = GESTURE_STYLE_ID;
670
+ style.textContent = "body.rosh-gesturing .backdrop-blur-sm{backdrop-filter:none!important;-webkit-backdrop-filter:none!important}body.rosh-gesturing [data-modal-panel]{will-change:transform}";
671
+ document.head.appendChild(style);
672
+ }
673
+ var RESIZE_CURSOR = {
674
+ se: "nwse-resize",
675
+ nw: "nwse-resize",
676
+ sw: "nesw-resize",
677
+ ne: "nesw-resize",
678
+ n: "ns-resize",
679
+ s: "ns-resize",
680
+ e: "ew-resize",
681
+ w: "ew-resize"
682
+ };
683
+ function beginPointerGesture(handle, pointerId, cursor) {
684
+ ensureGestureStyle();
685
+ try {
686
+ handle.setPointerCapture(pointerId);
687
+ } catch {
688
+ }
689
+ document.body.classList.add("rosh-gesturing");
690
+ const shield = document.createElement("div");
691
+ shield.setAttribute("data-drag-shield", "");
692
+ shield.style.cssText = `position:fixed;inset:0;z-index:2147483647;cursor:${cursor};background:transparent;touch-action:none`;
693
+ document.body.appendChild(shield);
694
+ let done = false;
695
+ return () => {
696
+ if (done) return;
697
+ done = true;
698
+ try {
699
+ handle.releasePointerCapture(pointerId);
700
+ } catch {
701
+ }
702
+ shield.remove();
703
+ document.body.classList.remove("rosh-gesturing");
704
+ };
705
+ }
665
706
  window.addEventListener("deactivate-all-modals", deactivateAllModals);
666
707
  function getZForModal(id) {
667
708
  const idx = activationOrder.indexOf(id);
@@ -1303,6 +1344,7 @@ function Modal({ open, onClose, title, icon, copyText, size = "lg", dirty = fals
1303
1344
  return;
1304
1345
  }
1305
1346
  e.preventDefault();
1347
+ const endGesture = beginPointerGesture(e.currentTarget, e.pointerId, "move");
1306
1348
  const sx = e.clientX, sy = e.clientY;
1307
1349
  const panel = panelRef.current;
1308
1350
  const rect = panel?.getBoundingClientRect();
@@ -1350,6 +1392,7 @@ function Modal({ open, onClose, title, icon, copyText, size = "lg", dirty = fals
1350
1392
  const up = () => {
1351
1393
  window.removeEventListener("pointermove", move);
1352
1394
  window.removeEventListener("pointerup", up);
1395
+ endGesture();
1353
1396
  hideSnapPreview();
1354
1397
  const finalBox = { ...boxRef.current };
1355
1398
  if (!widget && currentZone) {
@@ -1371,6 +1414,7 @@ function Modal({ open, onClose, title, icon, copyText, size = "lg", dirty = fals
1371
1414
  if (e.button !== 0) return;
1372
1415
  e.preventDefault();
1373
1416
  e.stopPropagation();
1417
+ const endGesture = beginPointerGesture(e.currentTarget, e.pointerId, RESIZE_CURSOR[corner]);
1374
1418
  const sx = e.clientX, sy = e.clientY;
1375
1419
  const panel = panelRef.current;
1376
1420
  const rect = panel?.getBoundingClientRect();
@@ -1411,7 +1455,12 @@ function Modal({ open, onClose, title, icon, copyText, size = "lg", dirty = fals
1411
1455
  const next = pending;
1412
1456
  pending = null;
1413
1457
  boxRef.current = next;
1414
- setBox(next);
1458
+ if (panel) {
1459
+ panel.style.left = `${next.x}px`;
1460
+ panel.style.top = `${next.y}px`;
1461
+ panel.style.width = `${next.w}px`;
1462
+ panel.style.height = `${next.h}px`;
1463
+ }
1415
1464
  };
1416
1465
  const move = (ev) => {
1417
1466
  pending = compute(ev.clientX - sx, ev.clientY - sy);
@@ -1422,6 +1471,8 @@ function Modal({ open, onClose, title, icon, copyText, size = "lg", dirty = fals
1422
1471
  window.removeEventListener("pointerup", up);
1423
1472
  if (raf) cancelAnimationFrame(raf);
1424
1473
  flush();
1474
+ endGesture();
1475
+ setBox({ ...boxRef.current });
1425
1476
  };
1426
1477
  window.addEventListener("pointermove", move);
1427
1478
  window.addEventListener("pointerup", up);
@@ -2563,5 +2614,5 @@ function WindowManagerProvider({ children }) {
2563
2614
  }
2564
2615
 
2565
2616
  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 };
2566
- //# sourceMappingURL=chunk-HJ5ZNXPB.js.map
2567
- //# sourceMappingURL=chunk-HJ5ZNXPB.js.map
2617
+ //# sourceMappingURL=chunk-JXW7H3DU.js.map
2618
+ //# sourceMappingURL=chunk-JXW7H3DU.js.map