|
- import * as React from 'react';
- import type { Meta } from '@storybook/react';
- import { ActionButton as Component, ActionButtonProps as Props } from '.';
- import { Button } from '@tesseract-design/web-base';
-
- const meta: Meta<typeof Component> = {
- component: Component,
- argTypes: {
- type: {
- control: { type: 'select' },
- options: Button.AVAILABLE_TYPES,
- },
- variant: {
- control: { type: 'select' },
- options: Button.AVAILABLE_VARIANTS,
- },
- size: {
- control: { type: 'select' },
- options: Button.AVAILABLE_SIZES,
- },
- onClick: {
- table: {
- disable: true,
- },
- action: 'clicked',
- },
- },
- args: Component.defaultProps ?? {},
- };
-
- export const ActionButton = (args: Omit<Props, 'ref'>) => (
- <Component
- {...args}
- >
- Button
- </Component>
- );
-
- export default meta;
|