chore: catch up Storybook preview, coverage, and story hygiene
Stories were throwing without AuthModal/CreateFlow providers, autodocs was a no-op, and several DS/create-flow screens had no stories.
This commit is contained in:
@@ -1,23 +1,23 @@
|
||||
import HeaderLockup from "../../app/components/type/HeaderLockup";
|
||||
import {
|
||||
HEADER_LOCKUP_JUSTIFICATION_OPTIONS,
|
||||
HEADER_LOCKUP_SIZE_OPTIONS,
|
||||
} from "../../lib/propNormalization";
|
||||
|
||||
export default {
|
||||
title: "Components/Type/HeaderLockup",
|
||||
component: HeaderLockup,
|
||||
parameters: {
|
||||
layout: "centered",
|
||||
backgrounds: {
|
||||
default: "dark",
|
||||
values: [{ name: "dark", value: "#000000" }],
|
||||
},
|
||||
},
|
||||
argTypes: {
|
||||
justification: {
|
||||
control: { type: "select" },
|
||||
options: ["left", "center", "Left", "Center"],
|
||||
options: [...HEADER_LOCKUP_JUSTIFICATION_OPTIONS],
|
||||
},
|
||||
size: {
|
||||
control: { type: "select" },
|
||||
options: ["L", "M", "l", "m"],
|
||||
options: [...HEADER_LOCKUP_SIZE_OPTIONS],
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
@@ -0,0 +1,77 @@
|
||||
import InputLabel from "../../app/components/type/InputLabel";
|
||||
import {
|
||||
INPUT_LABEL_PALETTE_OPTIONS,
|
||||
INPUT_LABEL_SIZE_OPTIONS,
|
||||
} from "../../lib/propNormalization";
|
||||
|
||||
export default {
|
||||
title: "Components/Type/InputLabel",
|
||||
component: InputLabel,
|
||||
parameters: {
|
||||
layout: "centered",
|
||||
docs: {
|
||||
description: {
|
||||
component:
|
||||
"Reusable form-input label with optional asterisk, help icon, and helper text. Figma Utility / InputLabel; canonical code under type/.",
|
||||
},
|
||||
},
|
||||
},
|
||||
argTypes: {
|
||||
label: { control: { type: "text" } },
|
||||
helpIcon: { control: { type: "boolean" } },
|
||||
asterisk: { control: { type: "boolean" } },
|
||||
helperText: { control: { type: "boolean" } },
|
||||
size: {
|
||||
control: { type: "select" },
|
||||
options: [...INPUT_LABEL_SIZE_OPTIONS],
|
||||
},
|
||||
palette: {
|
||||
control: { type: "select" },
|
||||
options: [...INPUT_LABEL_PALETTE_OPTIONS],
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
export const Default = {
|
||||
args: {
|
||||
label: "Community name",
|
||||
size: "s",
|
||||
palette: "default",
|
||||
},
|
||||
};
|
||||
|
||||
export const Required = {
|
||||
args: {
|
||||
label: "Community name",
|
||||
asterisk: true,
|
||||
size: "s",
|
||||
palette: "default",
|
||||
},
|
||||
};
|
||||
|
||||
export const WithHelp = {
|
||||
args: {
|
||||
label: "Applicable scope",
|
||||
helpIcon: true,
|
||||
size: "m",
|
||||
palette: "default",
|
||||
},
|
||||
};
|
||||
|
||||
export const OptionalHelper = {
|
||||
args: {
|
||||
label: "Website",
|
||||
helperText: true,
|
||||
size: "s",
|
||||
palette: "default",
|
||||
},
|
||||
};
|
||||
|
||||
export const Inverse = {
|
||||
args: {
|
||||
label: "Community name",
|
||||
asterisk: true,
|
||||
size: "m",
|
||||
palette: "inverse",
|
||||
},
|
||||
};
|
||||
@@ -1,19 +1,16 @@
|
||||
import NumberedList from "../../app/components/type/NumberedList";
|
||||
import { NUMBERED_LIST_SIZE_OPTIONS } from "../../lib/propNormalization";
|
||||
|
||||
export default {
|
||||
title: "Components/Type/NumberedList",
|
||||
component: NumberedList,
|
||||
parameters: {
|
||||
layout: "centered",
|
||||
backgrounds: {
|
||||
default: "dark",
|
||||
values: [{ name: "dark", value: "#000000" }],
|
||||
},
|
||||
},
|
||||
argTypes: {
|
||||
size: {
|
||||
control: { type: "select" },
|
||||
options: ["M", "S", "m", "s"],
|
||||
options: [...NUMBERED_LIST_SIZE_OPTIONS],
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user