1
1
mirror of https://github.com/primer/css.git synced 2024-12-29 09:06:07 +03:00

remove system utility columns from color tables

This commit is contained in:
Shawn Allen 2019-07-18 16:33:53 -07:00
parent 4604360d81
commit 35d2444105
3 changed files with 5 additions and 3 deletions

View File

@ -59,7 +59,7 @@ export function PaletteTableFragment(props) {
}
PaletteTable.defaultProps = {
columns: ['alias', 'className', 'variable', 'value'],
columns: ['alias', 'variable', 'value'],
hasHeader: true
}
@ -127,6 +127,7 @@ PaletteCell.Smart = ({type, ...rest}) => {
return <PaletteCell.Background {...rest} />
}
}
PaletteCell.Smart.propTypes = {
type: PropTypes.string.isRequired
}
@ -153,6 +154,7 @@ PaletteValue.PrefixedClass = ({prefix, slug}) => (
.{prefix}-{slug}
</Var>
)
PaletteValue.PrefixedClass.propTypes = {
prefix: PropTypes.string.isRequired,
slug: PropTypes.string.isRequired

View File

@ -42,7 +42,7 @@ import {PaletteTable, PaletteCell, overlayColor} from '../../../docs/color-syste
<StyledOcticon icon={LinkIcon} color="inherit !important" height={20} />
</Flex>
<PaletteTable
columns={['variable', 'value' /*, 'className' */]}
columns={['variable', 'value']}
values={[{variable: name, value, slug: name}].concat(values)}
hasHeader={false}
cellPadding="8px 16px" />

View File

@ -11,7 +11,7 @@ import {palettes, allColors} from '../../../docs/color-variables'
import {PaletteTable, PaletteTableFragment, PaletteHeading, PaletteCell, PaletteValue} from '../../../docs/color-system'
const textColumns = [
{title: 'Alias', Cell: props => <PaletteCell.Alias {...props} style={{borderBottom: `1px solid ${props.value} !important`}} />},
{title: 'Class', Cell: props => <PaletteCell.Text {...props} style={{borderBottom: props.aliases.text ? `1px solid ${props.value} !important` : null}} />, Value: PaletteValue.PrefixedClass},
// {title: 'Class', Cell: props => <PaletteCell.Text {...props} style={{borderBottom: props.aliases.text ? `1px solid ${props.value} !important` : null}} />, Value: PaletteValue.PrefixedClass},
'variable',
{title: 'Value', Cell: PaletteCell.Background, Value: PaletteValue.Value},
]