Some checks failed
DSS Project Analysis / dss-context-update (push) Has been cancelled
- Button.css uses only CSS custom properties, no fallbacks - Token validator now blocks hardcoded values (strict_mode: true) - Hook scripts converted from ESM (.js) to CommonJS (.cjs) - Storybook unified config with HMR disabled for nginx proxy - Added dss-ui package with Figma-synced components and stories 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
81 lines
1.5 KiB
TypeScript
81 lines
1.5 KiB
TypeScript
/**
|
|
* Badge Stories
|
|
* @generated 2025-12-11T14:37:52.567758
|
|
*/
|
|
import type { Meta, StoryObj } from '@storybook/preact';
|
|
import { Badge, type BadgeProps } from '../src/atoms/Badge';
|
|
|
|
const meta: Meta<BadgeProps> = {
|
|
title: '2. Atoms/Badge',
|
|
component: Badge,
|
|
tags: ['autodocs'],
|
|
parameters: {
|
|
docs: {
|
|
description: {
|
|
component: `Auto-generated Badge component
|
|
|
|
**Classification:** atom
|
|
**Slots:** icon, label
|
|
**Figma ID:** 19:6979`
|
|
}
|
|
}
|
|
},
|
|
argTypes: {
|
|
roundness: {
|
|
control: 'select',
|
|
options: ['Default', 'Round'],
|
|
description: 'Roundness variant',
|
|
},
|
|
variant: {
|
|
control: 'select',
|
|
options: ['Destructive', 'Ghost', 'Outline', 'Primary', 'Secondary'],
|
|
description: 'Variant variant',
|
|
},
|
|
state: {
|
|
control: 'select',
|
|
options: ['Default', 'Focus'],
|
|
description: 'State variant',
|
|
},
|
|
},
|
|
};
|
|
|
|
export default meta;
|
|
type Story = StoryObj<BadgeProps>;
|
|
|
|
export const Default: Story = {
|
|
args: {
|
|
roundness: 'Default',
|
|
variant: 'Destructive',
|
|
state: 'Default',
|
|
children: 'Badge'
|
|
},
|
|
};
|
|
|
|
export const Destructive: Story = {
|
|
args: {
|
|
...Default.args,
|
|
variant: 'Destructive',
|
|
},
|
|
};
|
|
|
|
export const Ghost: Story = {
|
|
args: {
|
|
...Default.args,
|
|
variant: 'Ghost',
|
|
},
|
|
};
|
|
|
|
export const Outline: Story = {
|
|
args: {
|
|
...Default.args,
|
|
variant: 'Outline',
|
|
},
|
|
};
|
|
|
|
export const Primary: Story = {
|
|
args: {
|
|
...Default.args,
|
|
variant: 'Primary',
|
|
},
|
|
};
|