From 8febacda29380363a61d96da4689509e371931cf Mon Sep 17 00:00:00 2001
From: Shawn Allen
Date: Thu, 18 Jul 2019 16:33:00 -0700
Subject: [PATCH 1/6] color palette table style tweaks
---
docs/color-system.js | 2 +-
pages/css/utilities/borders.md | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/docs/color-system.js b/docs/color-system.js
index a0422eb850..bde03f8f70 100644
--- a/docs/color-system.js
+++ b/docs/color-system.js
@@ -200,7 +200,7 @@ export const Var = styled(Text).attrs({
`
export const PaletteHeading = ({indicatorColor, children, ...rest}) => (
-
+
{children}
)
diff --git a/pages/css/utilities/borders.md b/pages/css/utilities/borders.md
index 3f4325b2de..df0dfb860d 100644
--- a/pages/css/utilities/borders.md
+++ b/pages/css/utilities/borders.md
@@ -231,4 +231,4 @@ You can adjust border widths on all sides or each side individually with respons
'variable',
'value'
]}
- borderSpacing="0 4px" />
+ style={{borderSpacing: '0 4px'}} />
From 4604360d8167696858af7c9c3d14d8295aa57c06 Mon Sep 17 00:00:00 2001
From: Shawn Allen
Date: Thu, 18 Jul 2019 16:33:28 -0700
Subject: [PATCH 2/6] nix zap octicon from alias columns in color tables
---
docs/color-system.js | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/docs/color-system.js b/docs/color-system.js
index bde03f8f70..a52a51a9e3 100644
--- a/docs/color-system.js
+++ b/docs/color-system.js
@@ -3,7 +3,6 @@ import PropTypes from 'prop-types'
import chroma from 'chroma-js'
import styled from 'styled-components'
import {Box, StyledOcticon, Text} from '@primer/components'
-import {Zap} from '@githubprimer/octicons-react'
import {colors, getPaletteByName} from './color-variables'
import Table from './Table'
@@ -105,12 +104,12 @@ PaletteCell.propTypes = {
PaletteCell.Alias = ({aliases, type, ...rest}) =>
aliases && aliases[type] ? (
-
.{aliases[type]}
) : (
|
)
+
PaletteCell.Alias.propTypes = {
aliases: PropTypes.object.isRequired,
type: PropTypes.string.isRequired
From 35d2444105f8d7de45880e6335e781fc10d9ec22 Mon Sep 17 00:00:00 2001
From: Shawn Allen
Date: Thu, 18 Jul 2019 16:33:53 -0700
Subject: [PATCH 3/6] remove system utility columns from color tables
---
docs/color-system.js | 4 +++-
pages/css/support/color-system.md | 2 +-
pages/css/utilities/colors.md | 2 +-
3 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/docs/color-system.js b/docs/color-system.js
index a52a51a9e3..1f4a41149a 100644
--- a/docs/color-system.js
+++ b/docs/color-system.js
@@ -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.Smart.propTypes = {
type: PropTypes.string.isRequired
}
@@ -153,6 +154,7 @@ PaletteValue.PrefixedClass = ({prefix, slug}) => (
.{prefix}-{slug}
)
+
PaletteValue.PrefixedClass.propTypes = {
prefix: PropTypes.string.isRequired,
slug: PropTypes.string.isRequired
diff --git a/pages/css/support/color-system.md b/pages/css/support/color-system.md
index 864927db91..4857029752 100644
--- a/pages/css/support/color-system.md
+++ b/pages/css/support/color-system.md
@@ -42,7 +42,7 @@ import {PaletteTable, PaletteCell, overlayColor} from '../../../docs/color-syste
diff --git a/pages/css/utilities/colors.md b/pages/css/utilities/colors.md
index 2e858d1f8c..c115017f55 100644
--- a/pages/css/utilities/colors.md
+++ b/pages/css/utilities/colors.md
@@ -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 => },
- {title: 'Class', Cell: props => , Value: PaletteValue.PrefixedClass},
+ // {title: 'Class', Cell: props => , Value: PaletteValue.PrefixedClass},
'variable',
{title: 'Value', Cell: PaletteCell.Background, Value: PaletteValue.Value},
]
From 273680639889c87378918b0b36412a30748f2bd3 Mon Sep 17 00:00:00 2001
From: Shawn Allen
Date: Thu, 18 Jul 2019 16:34:20 -0700
Subject: [PATCH 4/6] make the color utility tables "sparse" (only show colors
with alias classes)
---
pages/css/utilities/colors.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/pages/css/utilities/colors.md b/pages/css/utilities/colors.md
index c115017f55..92d165cde2 100644
--- a/pages/css/utilities/colors.md
+++ b/pages/css/utilities/colors.md
@@ -29,7 +29,7 @@ Background colors are most commonly used for filling large blocks of content or
{palettes.map(({name, title, value}) => (
-
+
{title}
@@ -133,7 +133,7 @@ You can set the color inheritance on an element by using the `text-inherit` clas
{palettes.map(({name, title, value}) => (
-
+
{title}
From ef1f39ddec582021684cd4de3f673e0d9e88d7c3 Mon Sep 17 00:00:00 2001
From: Shawn Allen
Date: Thu, 18 Jul 2019 16:37:59 -0700
Subject: [PATCH 5/6] lint
---
docs/color-system.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/color-system.js b/docs/color-system.js
index 1f4a41149a..4f282e3b66 100644
--- a/docs/color-system.js
+++ b/docs/color-system.js
@@ -2,7 +2,7 @@ import React from 'react'
import PropTypes from 'prop-types'
import chroma from 'chroma-js'
import styled from 'styled-components'
-import {Box, StyledOcticon, Text} from '@primer/components'
+import {Box, Text} from '@primer/components'
import {colors, getPaletteByName} from './color-variables'
import Table from './Table'
From 7554b3e552d46f5822cd2f3e48e47cd47d97cbe8 Mon Sep 17 00:00:00 2001
From: simurai
Date: Fri, 19 Jul 2019 10:18:34 +0900
Subject: [PATCH 6/6] Fix "Table of Contents"
---
pages/css/utilities/colors.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pages/css/utilities/colors.md b/pages/css/utilities/colors.md
index 92d165cde2..8e4fdd58c9 100644
--- a/pages/css/utilities/colors.md
+++ b/pages/css/utilities/colors.md
@@ -18,7 +18,7 @@ const textColumns = [
Use color utilities to apply color to the background of elements, text, and borders.
-# Table of contents
+## Table of Contents
## Background colors