- {(
- [
- ["brand", "Brand"],
- ["solid", "Standard Solid"],
- ["outline", "Standard Outline"],
- ] as const
- ).map(([appearance, title]) => (
+ {appearances.map(([appearance, title]) => (
{title}
-
- {rolesFor(appearance).map(([variant, label]) => (
-
- ))}
+
+
))}
@@ -118,7 +126,7 @@ function SizesBoard() {
)
}
-// `showNote={false}` keeps the representative page UI-only; the verification Stories keep the state notes.
+// `showNote={false}` keeps the representative page UI-only; the verification Story keeps the note and the Activated readout.
function BrandStates({ showNote = true }: { showNote?: boolean }) {
const [count, setCount] = useState(0)
return (
@@ -132,7 +140,7 @@ function BrandStates({ showNote = true }: { showNote?: boolean }) {
Disabled
-
+ {showNote ? : null}
{showNote ? (
Hover와 Pressed는 Storybook이 고정한 상태입니다. Interact 위에서 실제 Hover·Pressed·포인터 이탈을 확인합니다. Disabled는 실행되지 않습니다.
@@ -149,15 +157,17 @@ const standardStates = [
["Disabled", { disabled: true }],
] as const
-function StandardStateTable({ appearance, title }: { appearance: "solid" | "outline"; title: string }) {
+// Without `title` the table sits under a StateBoard label (representative page) and drops the Role column:
+// every button already shows its role name, so the row header would repeat it.
+function StandardStateTable({ appearance, title }: { appearance: "solid" | "outline"; title?: string }) {
return (
- {title}
-
+ {title ?
{title}
: null}
+
- | Role |
+ {title ? Role | : null}
{standardStates.map(([state]) => (
{state}
@@ -168,7 +178,7 @@ function StandardStateTable({ appearance, title }: { appearance: "solid" | "outl
|
{rolesFor(appearance).map(([variant, label]) => (
- | {label} |
+ {title ? {label} | : null}
{standardStates.map(([state, props]) => (
|