A next-generation tool to create blazing-fast documentation sites
API
created:5/19/2021
updated:5/19/2021
loc
104
comments
30%
todos
2
passed
10
coverage
69%

Starter

This example demonstrates documenting a hypothetical Button component that supports variants, icons, text, and padding

import { VariantButton } from 'component-controls-stories';

Overview

In the Playground, you can view the source code, apply zoom or background...

Name
Description
Default
Controls
text

button label of text

string
-
variant

variant kind

disabledprimaryaccentsuccesswarningerror
primary
fontSize

font size for the Button label

number
18
icon

icon kind

nonesearchleft-arrowright-arrowdown-arrowup-arrow
none
iconSide

on which side of the label should the icon be placed

leftright
left
iconSize

icon size

smallmediumlarge
small
padding

padding variants

smallmediumlarge
medium
Name
Description
Default
VariantButtonProps(8 properties)
text

button label of text

string
-
variant

variant kind

disabledprimaryaccentsuccesswarningerror
primary
fontSize

font size for the Button label

number
18
icon

icon kind

nonesearchleft-arrowright-arrowdown-arrowup-arrow
none
iconSide

on which side of the label should the icon be placed

leftright
left
iconSize

icon size

smallmediumlarge
small
padding

padding variants

smallmediumlarge
medium
isPrimary

boolean switch for primary variant

boolean
false
AllHTMLAttributes(106 properties)
HTMLAttributes(43 properties)
AriaAttributes(48 properties)
DOMAttributes(161 properties)
ClassAttributes(1 properties)
Attributes(1 properties)

Commits

Date
Author
Commit Message
5/17/2021

atanasster

avatar of atanasster
feat: include/exclude controls as function
5/11/2021

atanasster

avatar of atanasster
fix: icon type
4/20/2021

atanasster

avatar of atanasster
docs: refactor starter story for tests
3 commits
package
imports
peer
@primer/octicons-react
SearchIconArrowUpIconArrowRightIconArrowLeftIconArrowDownIcon
react
ReactFC