From 19838832d7dfa1f3ee51c03df3027179126fdf90 Mon Sep 17 00:00:00 2001 From: Martin Dvorak Date: Thu, 24 Sep 2026 14:55:13 +0000 Subject: [PATCH] windows stop 10px above the taskbar instead of overlapping it --- opencode.md | 8 ++++---- src/app/components/WindowsDesktop.tsx | 10 +++++----- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/opencode.md b/opencode.md index 853a05f..8582fc8 100644 --- a/opencode.md +++ b/opencode.md @@ -228,10 +228,10 @@ list reordering, not free placement. Don't confuse the two. the panel), a `resize` effect re-clamps on browser resize, and `.win-window.centered` carries `max-width`/`max-height`. Keep these in sync if you add a new window path, or windows will escape the viewport. The bottom - limit is `TASKBAR_HEIGHT = 44` in `WindowsDesktop.tsx` (panel `bottom:10px` + - `height:44px`; 44 lets a window tuck 10px behind the panel's top edge, which - looked better than stopping dead flush); note `useDesktopIcons.ts` has its - **own** `TASKBAR_HEIGHT = 48` for the icon grid. + limit is `TASKBAR_HEIGHT = 64` in `WindowsDesktop.tsx` (panel `bottom:10px` + + `height:44px` = 54, plus a 10px gap), so a dragged window stops just above the + taskbar; note `useDesktopIcons.ts` has its **own** `TASKBAR_HEIGHT = 48` for + the icon grid. - Exposing the **dev** server over a tunnel needs the tunnel host in `allowedDevOrigins` (`next.config.ts`). Without it Next dev rejects the cross-origin HMR WebSocket, so the client never hydrates — the page is SSR diff --git a/src/app/components/WindowsDesktop.tsx b/src/app/components/WindowsDesktop.tsx index 4223a9d..573c2e1 100644 --- a/src/app/components/WindowsDesktop.tsx +++ b/src/app/components/WindowsDesktop.tsx @@ -9,11 +9,11 @@ import { useTheme } from "./useTheme"; import { useDesktopIcons } from "./useDesktopIcons"; import { WALLPAPER, friends } from "../data"; -// The panel is anchored at `bottom: 10px` and is 44px tall, so its top edge is -// 54px above the viewport bottom. Windows clamp at 44px from the bottom, i.e. -// they tuck 10px behind the panel's top edge - a slight overlap that reads -// better than stopping dead flush. -const TASKBAR_HEIGHT = 44; +// The panel sits at `bottom: 10px` with a height of 44px, so its top edge is +// 54px above the viewport bottom. Windows clamp 10px above that, so a dragged +// window stops just above the taskbar with a small gap instead of touching or +// overlapping it. +const TASKBAR_HEIGHT = 64; const LEFT_APPS = APPS.filter((a) => a.id !== "services" && a.id !== "friends");