xrdwb17xu: Add the full-screen snap feed with media and quote slides on phones

This commit is contained in:
2026-10-20 08:21:28 -06:00
parent 25fd360a2b
commit bf5e0ed475
12 changed files with 815 additions and 61 deletions
+22
View File
@@ -0,0 +1,22 @@
"use client";
import { createContext, useContext } from "react";
/** Widest `.app` width that gets the phone layout (spec "Mobile layout", ADR 0001 section 3). */
export const COMPACT_MAX_WIDTH = 760;
/** True when `.app` is 760px wide or less. Matches `@container app (max-width: 760px)`. */
export function isCompactWidth(width: number): boolean {
return width > 0 && width <= COMPACT_MAX_WIDTH;
}
/**
* Whether the signed-in shell is in the phone layout. AppShell measures `.app`
* and provides it; outside the shell (tests, other pages) it is false, so the
* desktop markup renders.
*/
export const CompactLayoutContext = createContext(false);
export function useCompactLayout(): boolean {
return useContext(CompactLayoutContext);
}