Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Components: Retire DARK_GRAY colors #43773

Merged
merged 3 commits into from
Sep 1, 2022
Merged
Show file tree
Hide file tree
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
5 changes: 2 additions & 3 deletions packages/components/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,8 @@

- `ToggleControl`: Add `__nextHasNoMargin` prop for opting into the new margin-free styles ([#43717](https://github.com/WordPress/gutenberg/pull/43717)).
- `CheckboxControl`: Add `__nextHasNoMargin` prop for opting into the new margin-free styles ([#43720](https://github.com/WordPress/gutenberg/pull/43720)).

### Enhancements

- `RangeControl`: Tweak dark gray marking color to be consistent with the grays in `@wordpress/base-styles` ([#43773](https://github.com/WordPress/gutenberg/pull/43773)).
- `UnitControl`: Tweak unit dropdown color to be consistent with the grays in `@wordpress/base-styles` ([#43773](https://github.com/WordPress/gutenberg/pull/43773)).
- `CardHeader`, `CardBody`, `CardFooter`: Tweak `isShady` background colors to be consistent with the grays in `@wordpress/base-styles` ([#43719](https://github.com/WordPress/gutenberg/pull/43719)).
- `InputControl`, `SelectControl`: Tweak `disabled` colors to be consistent with the grays in `@wordpress/base-styles` ([#43719](https://github.com/WordPress/gutenberg/pull/43719)).

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ export const Mark = styled.span`

const markLabelFill = ( { isFilled }: RangeMarkProps ) => {
return css( {
color: isFilled ? COLORS.darkGray[ 300 ] : COLORS.lightGray[ 600 ],
color: isFilled ? COLORS.gray[ 700 ] : COLORS.lightGray[ 600 ],
} );
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ const baseUnitLabelStyles = ( { selectSize }: SelectProps ) => {
box-sizing: border-box;
padding: 2px 1px;
width: 20px;
color: ${ COLORS.darkGray[ 500 ] };
color: ${ COLORS.gray[ 800 ] };
font-size: 8px;
line-height: 1;
letter-spacing: -0.5px;
Expand Down
10 changes: 0 additions & 10 deletions packages/components/src/utils/colors-values.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,6 @@ const GRAY = {
100: '#f0f0f0',
};

// TODO: Replace usages of these with the equivalents in `GRAY`
const DARK_GRAY = {
500: '#555d66', // Use this most of the time for dark items.
300: '#6c7781', // Lightest gray that can be used for AA text contrast.
};

// TODO: Replace usages of these with the equivalents in `GRAY`
const LIGHT_GRAY = {
800: '#b5bcc2',
Expand Down Expand Up @@ -66,10 +60,6 @@ const UI = {
};

export const COLORS = Object.freeze( {
/**
* @deprecated Try to use `gray` instead.
*/
darkGray: DARK_GRAY,
/**
* The main gray color object.
*/
Expand Down