// While² — Solid / minimal screens // Splash と同じ世界観で、罫線・pill・checkbox全廃。 // テキストだけで構成、`/\` `_` 系の小さなASCIIヘッダー、key=value、行のみ。 const _INK = '#e8e6df'; // Tiny ASCII headers, in the same /\__ family as the splash logo. // Built by hand from a 3-line, lighter-weight version of the figlet. const HEADERS = { today: [ ' _____ _ _ _ __ ', '/__ \\ / \\ | \\ /_\\ | |', ' | | / /\\ \\| | // \\\\ \\/ ', ' |_| \\/ \\/|_/_/ \\/__|', ], // simpler "single line" wordmark for compactness // we'll keep most headers as `> while² ` prompt instead. }; // Common shell — top prompt as the page header, // content centered horizontally, generous black space. function SolidShell({ prompt, children, footer }) { return (
{/* Prompt header — fixed top, splash-aligned padding */}
>{' '} {prompt} _
{/* Content */}
{children}
{/* Footer prompt nav */} {footer && (
{footer}
)}
); } const PromptLink = ({ active, children }) => ( {active ? > : ' '} {children} ); const NavFooter = ({ current }) => ( <> today new_ config ); // ── HOME ───────────────────────────────────────────────────── // Rows only. Time | name | rule. Overdue rows in cyan. function HomeSolid() { const today = [ { name: 'burnable trash', rule: 'weekly · tue', swipe: 'right' }, { name: 'stretch', rule: 'daily' }, { name: 'haircut', rule: 'every 4w · overdue', warn: true, swipe: 'left' }, ]; const upcoming = [ { t: '04/30', name: 'non-burnable trash', rule: 'biweekly' }, { t: '05/03', name: 'pay rent', rule: 'monthly · 3' }, { t: '05/05', name: 'restock shampoo', rule: 'every 6w' }, { t: '05/06', name: 'book checkup', rule: 'every 12m' }, ]; const TodayRow = ({ name, rule, warn, swipe }) => { // Slide the row content; reveal action label on the opposite side. const slide = swipe === 'right' ? 64 : swipe === 'left' ? -64 : 0; const baseColor = warn ? W2.cyan : _INK; const ruleColor = warn ? W2.cyan : 'rgba(232,230,223,0.45)'; return (
{/* action label, behind */} {swipe === 'right' && (
done_
)} {swipe === 'left' && (
edit_
)} {/* foreground row, translated */}
{name} {rule}
); }; const UpcomingRow = ({ t, name, rule }) => (
{t} {name} {rule}
); return ( while² today} footer={} >
// today
{today.map((t, i) => )}
// upcoming
{upcoming.map((t, i) => )} {/* swipe legend */}
→ swipe :: ✓ done_
← swipe :: edit_
); } // ── NEW TASK ───────────────────────────────────────────────── // 3 variants showing how the form reshapes per `起点` mode. function _NewTaskField({ k, v, hint }) { return (
{k} {v}
{hint && (
{hint}
)}
); } function _NewTaskShell({ children, preview }) { return ( while² new_} footer={<> esc · cancel ↵ save } >
{children}
? {preview}
); } // from completion function NewTaskSolid() { const F = _NewTaskField; return ( <_NewTaskShell preview="done 04/28 → next 05/26 → 06/23 …"> ); } // fixed date · weekly function NewTaskWeekly() { const F = _NewTaskField; // weekday picker: highlight the chosen day(s) const days = ['mon','tue','wed','thu','fri','sat','sun']; const picked = new Set(['tue']); return ( <_NewTaskShell preview="next 04/29 (tue) → 05/06 (tue) → 05/13 (tue) …">
day
{days.map(d => ( {d} ))}
); } // fixed date · monthly function NewTaskMonthly() { const F = _NewTaskField; return ( <_NewTaskShell preview="next 05/03 → 06/03 → 07/03 …"> ); } // ── SETTINGS ───────────────────────────────────────────────── // Pure key = value list. No groups, no toggles. config.txt vibe. function SettingsSolid() { const rows = [ ['operator', 'user.local'], ['timezone', 'asia/tokyo'], ['week_starts', 'mon'], [null, null], ['notify_at', '09:00'], ['recap_at', '21:00'], ['overdue_ping', 'on'], ['sound', 'sonar.short'], [null, null], ['theme', 'dark.cyan'], ['reduce_motion', 'off'], ['dolphin', 'boot_only'], [null, null], ['icloud', 'on'], ['device', 'iPhone 15 · macbook · iPad'], ['last_synced', '2 min ago'], [null, null], ['rules', '23'], ['export', 'while².json ↗'], ['wipe', 'reset all loops'], ]; return ( while² config} footer={<> v0.1.4 · build 0428 ↵ save } >
{rows.map(([k, v], i) => k === null ? (
) : (
{k} = {v}
))}
); } window.HomeSolid = HomeSolid; window.NewTaskSolid = NewTaskSolid; window.NewTaskWeekly = NewTaskWeekly; window.NewTaskMonthly = NewTaskMonthly; window.SettingsSolid = SettingsSolid;