@momentum-ui/react-collaboration
Version:
Cisco Momentum UI Framework for React Collaboration Applications
134 lines (131 loc) • 3.28 kB
text/typescript
import {
commonMdcButton,
commonHTMLAttributes,
commonStyles,
} from '../../storybook/helper.stories.argtypes';
import { BUTTON_PILL_CONSTANTS as CONSTANTS } from './';
export default {
...commonStyles,
...commonHTMLAttributes,
...commonMdcButton,
children: {
description:
'Provides the child nodes for this element, passed into default slot of momentum-design button.',
control: { type: 'text' },
table: {
type: {
summary: 'ReactNode',
},
defaultValue: {
summary: 'undefined',
},
},
},
color: {
description: 'Modifies the color of this `<ButtonPill />`.',
options: [undefined, ...Object.values(CONSTANTS.COLORS)],
control: { type: 'select' },
table: {
type: {
summary: 'string',
},
defaultValue: {
summary: 'undefined',
},
},
},
shallowDisabled: {
description:
'Whether to render the `<ButtonPill />` looking as if disabled, but allowing onPress actions to still be passed. Maps to softDisabled internally.',
options: [true, false],
control: { type: 'boolean' },
table: {
type: {
summary: 'boolean',
},
defaultValue: {
summary: CONSTANTS.DEFAULTS.SHALLOW_DISABLED,
},
},
},
disabledOutline: {
description:
'Whether to render the `<ButtonPill />` with an outline even when disabled/shallowDisabled. Respects existing outline prop and will not display outline if outline is false.',
options: [true, false],
control: { type: 'boolean' },
table: {
type: {
summary: 'boolean',
},
defaultValue: {
summary: CONSTANTS.DEFAULTS.DISABLED_OUTLINE,
},
},
},
ghost: {
description: 'Whether this component has a transparent background.',
options: [true, false],
control: { type: 'boolean' },
table: {
type: {
summary: 'boolean',
},
defaultValue: {
summary: CONSTANTS.DEFAULTS.GHOST,
},
},
},
isGrown: {
description: 'If this component should grow its width to the parent container.',
options: [true, false],
control: { type: 'boolean' },
table: {
type: {
summary: 'boolean',
},
defaultValue: {
summary: CONSTANTS.DEFAULTS.GROWN,
},
},
},
outline: {
description: 'Whether this component has an outline/border.',
options: [true, false],
control: { type: 'boolean' },
table: {
type: {
summary: 'boolean',
},
defaultValue: {
summary: CONSTANTS.DEFAULTS.OUTLINE,
},
},
},
inverted: {
description:
'Whether this component has inverted background (black for dark mode and white for light mode)',
options: [true, false],
control: { type: 'boolean' },
table: {
type: {
summary: 'boolean',
},
defaultValue: {
summary: false,
},
},
},
size: {
description: 'Modifies the size of this `<ButtonPill />`.',
options: [undefined, ...Object.values(CONSTANTS.SIZES)],
control: { type: 'select' },
table: {
type: {
summary: 'number',
},
defaultValue: {
summary: CONSTANTS.DEFAULTS.SIZE,
},
},
},
};