Skip to content

Commit

Permalink
remove additional margin overrides and add prop to components based o…
Browse files Browse the repository at this point in the history
…n PR feedback
  • Loading branch information
brookewp committed Nov 30, 2022
1 parent 0b2a766 commit 2b06d5e
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 14 deletions.
1 change: 1 addition & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ The following contributors merged PRs in this release:
- FocalPointPicker: Update the design of the focal point handle. ([45053](https://github.com/WordPress/gutenberg/pull/45053))
- FontSizePicker: Update hint text to match the design. ([44966](https://github.com/WordPress/gutenberg/pull/44966))
- CheckboxControl: Move icons out of labels. ([45535](https://github.com/WordPress/gutenberg/pull/45535))
- RangeControl: remove margin overrides and add new opt-in prop. ([45985](https://github.com/WordPress/gutenberg/pull/45985))

#### Block Editor

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ const UnconnectedBorderControl = (
/>
{ withSlider && (
<RangeControl
__nextHasNoMarginBottom
label={ __( 'Border width' ) }
hideLabelFromVision
className={ sliderClassName }
Expand Down
11 changes: 1 addition & 10 deletions packages/components/src/border-control/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,7 @@ import { css } from '@emotion/react';
*/
import { COLORS, CONFIG, boxSizingReset, rtl } from '../utils';
import { space } from '../ui/utils/space';
import {
StyledField,
StyledLabel,
} from '../base-control/styles/base-control-styles';
import { StyledLabel } from '../base-control/styles/base-control-styles';
import {
ValueInput as UnitControlWrapper,
UnitSelect,
Expand Down Expand Up @@ -193,10 +190,4 @@ export const borderStyleButton = css`
export const borderSlider = () => css`
flex: 1 1 60%;
${ rtl( { marginRight: space( 3 ) } )() }
${ StyledField } {
margin-bottom: 0;
font-size: 0;
display: flex;
}
`;
1 change: 1 addition & 0 deletions packages/components/src/color-picker/input-with-slider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ export const InputWithSlider = ( {
size="__unstable-large"
/>
<RangeControl
__nextHasNoMarginBottom
label={ label }
hideLabelFromVision
min={ min }
Expand Down
4 changes: 0 additions & 4 deletions packages/components/src/color-picker/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,6 @@ export const SelectControl = styled( InnerSelectControl )`
export const RangeControl = styled( InnerRangeControl )`
flex: 1;
margin-right: ${ space( 2 ) };
${ StyledField } {
margin-bottom: 0;
}
`;

// Make the Hue circle picker not go out of the bar.
Expand Down

0 comments on commit 2b06d5e

Please sign in to comment.