SMP: Minecraft-style join window with live status; allow beta tunnel origin for dev HMR
This commit is contained in:
parent
8fa1f50e8a
commit
d540a6a873
7 changed files with 318 additions and 6 deletions
11
opencode.md
11
opencode.md
|
|
@ -83,7 +83,7 @@ src/app/
|
|||
MobileHome.tsx → "skeuo" theme, phone: app grid + dock
|
||||
WinWindow.tsx → a single draggable/resizable window
|
||||
apps.tsx → APPS registry + the content of each app + in-app terminal
|
||||
+ embedded-site windows
|
||||
+ embedded-site windows + the Minecraft-style SMP menu
|
||||
useDesktopIcons.ts → desktop icon grid + drag/drop (THE KEY FILE, see below)
|
||||
useDragOrder.ts → simple list reordering (mobile home screen only)
|
||||
useTheme.ts → theme state via useSyncExternalStore
|
||||
|
|
@ -211,6 +211,15 @@ list reordering, not free placement. Don't confuse the two.
|
|||
`eslint-disable-next-line` with a comment. Don't add more without a reason.
|
||||
- Watch for `pointercancel`: any custom pointer gesture over an `<img>`, link,
|
||||
or text selection needs `draggable=false` / `user-select: none`.
|
||||
- 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
|
||||
only: icons all stacked at `(0,0)`, buttons dead. Changing `next.config.ts`
|
||||
needs a dev-server restart. For a public URL prefer a production build
|
||||
(`npm run build && npm run start`): no HMR socket, so nothing to reject.
|
||||
- The SMP service shortcut opens `SMP_APP` (in `apps.tsx`, registered in
|
||||
`APP_BY_ID` only, like `ALACRITTY_APP`) — a Minecraft-style join menu that
|
||||
reads live data from `/api/ping?url=minecraft://…`.
|
||||
- Service shortcuts show the real site in an iframe via
|
||||
`createWebsiteApp({ embed: true })` (the shortcut's `embed` flag). It only
|
||||
works for sites that don't send `X-Frame-Options` / a `frame-ancestors` CSP.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue