import { AppProvider } from "@godxjp/ui/app"; import { Avatar, AvatarFallback, Card, CardContent, CardDescription, CardHeader, CardTitle, } from "@godxjp/ui/data-display"; import { Text } from "@godxjp/ui/general"; import { Flex, PageContainer, Topbar, TopbarItem } from "@godxjp/ui/layout"; import { AppSettingPicker } from "@godxjp/ui/navigation"; /** * AppSettingPicker — ONE provider-bound Select for any single AppProvider setting, * chosen via `kind` (locale/timezone/date/time plus theme/brand/density/fontSize). It replaces the * former Locale/Timezone/Date-format/Time-format pickers (4 components → 1). Mount under * and it reads/writes the matching context with NO value/onValueChange; pass * those to control it instead. Composed only from real @godxjp/ui components. */ export default function Demo() { return ( インライン表示 表示言語 kind で対象設定を選ぶ 旧 Locale / Timezone / DateFormat / TimeFormat ピッカーを 1 コンポーネントに統合。 <AppProvider> 配下に置くと value / onValueChange なしでコンテキストを読み書きする。 表示言語 {/* locale defaults to the icon-only switcher; a labeled settings-form row opts into the full trigger with an explicit appearance="labeled". */} タイムゾーン 日付フォーマット 時刻フォーマット テーマ ブランド 密度 文字サイズ 狭いコンテナと長いラベル 320px 相当で長いタイムゾーン名の折返し・クリッピングを確認する。 アイコンのみ(トップバー) appearance="icon" は正方形トリガーとローカライズ済み accessible name を保持し、選択肢はメニュー内で完全表示する。 G } end={ } /> バーのセル(appearance="bar") icon と同じ構造上の省略を保ったまま、箱だけがバーの セルになる。バーの高さいっぱいに伸び、角は --topbar-item-radius(TopbarItem と同じつまみ)で四角い。 ホバーの面はバーそのものを塗る。 icon をバーに置くと --control-height の丸い錠剤が背の高い帯の中に浮き、バー本来のクロームとは別系統に読める。 プロジェクト} end={ <> } /> 無効化 disabled で操作を止める。 タイムゾーン (disabled) ); }