Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 3 additions & 31 deletions components/atom/icon/demo/articles/ArticleDesign.js
Original file line number Diff line number Diff line change
@@ -1,26 +1,14 @@
import {Fragment, useState} from 'react'
import {Fragment} from 'react'
import {IconBrandGithub, IconBrandGithubFilled} from '@tabler/icons-react'

import PropTypes from 'prop-types'

import {
AntDesignIcon,
Article,
Cell,
Code,
Grid,
H2,
Label,
Paragraph,
RadioButton,
RadioButtonGroup
} from '@s-ui/documentation-library'
import {Article, Cell, Code, Grid, H2, Label, Paragraph} from '@s-ui/documentation-library'

import AtomIcon, {ATOM_ICON_COLORS, ATOM_ICON_DESIGNS} from '../../src/index.js'
import {flexCenteredStyle, ICONS} from '../settings.js'
import {flexCenteredStyle} from '../settings.js'

const ArticleDesign = ({className}) => {
const [selectedIcon, setIcon] = useState(Object.values(ICONS)[0])
return (
<Article className={className}>
<H2>Design</H2>
Expand All @@ -34,22 +22,6 @@ const ArticleDesign = ({className}) => {
–––
<br />
<br />
<RadioButtonGroup onChange={(event, value) => setIcon(value)} value={selectedIcon}>
{Object.values(ICONS).map(({name, label}, index) => (
<RadioButton
key={index}
value={{name, label}}
aria-label={label}
label={
<AtomIcon>
<AntDesignIcon icon={name} style={{color: 'currentColor'}} />
</AtomIcon>
}
/>
))}
</RadioButtonGroup>
<br />
<br />
<Grid cols={9} gutter={[8, 8]}>
<Cell />
{Object.values(ATOM_ICON_COLORS).map((iconColor, index) => (
Expand Down
Loading