overleaf/services/web/frontend/stories/icon.stories.js
Alf Eaton 7c97f8ab6e Switch to new JSX runtime (#4225)
* Use new JSX runtime and update Babel Node target
* Update .eslintrc
* Remove React imports

GitOrigin-RevId: 559de0267f8f2934c56a860ea8701bb522aa861a
2021-06-24 02:06:59 +00:00

50 lines
812 B
JavaScript

import Icon from '../js/shared/components/icon'
export const Type = args => {
return (
<>
<Icon {...args} />
<div>
<a
href="https://fontawesome.com/v4.7.0/icons/"
target="_blank"
rel="noopener"
>
Font Awesome icons
</a>
</div>
</>
)
}
Type.args = {
type: 'tasks',
}
export const Spinner = args => {
return <Icon {...args} />
}
Spinner.args = {
type: 'spinner',
spin: true,
}
export const FixedWidth = args => {
return <Icon {...args} />
}
FixedWidth.args = {
type: 'tasks',
modifier: 'fw',
}
export const AccessibilityLabel = args => {
return <Icon {...args} />
}
AccessibilityLabel.args = {
type: 'check',
accessibilityLabel: 'Check',
}
export default {
title: 'Icon',
component: Icon,
}