Skip to content
Closed
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
16 changes: 9 additions & 7 deletions packages/components/src/color-picker/component.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -129,14 +129,16 @@ const ColorPicker = (
}
/>
</HStack>
<Spacer margin={ 4 } />
{ showInputs && (
<ColorInput
colorType={ colorType }
color={ safeColordColor }
onChange={ handleChange }
enableAlpha={ enableAlpha }
/>
<>
<Spacer margin={ 4 } />
<ColorInput
colorType={ colorType }
color={ safeColordColor }
onChange={ handleChange }
enableAlpha={ enableAlpha }
/>
</>
) }
</AuxiliaryColorArtefactWrapper>
</ColorfulWrapper>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { colord } from 'colord';
import { useInstanceId } from '@wordpress/compose';
import { useEffect, useRef, useState } from '@wordpress/element';
import { __, sprintf } from '@wordpress/i18n';
import { plus } from '@wordpress/icons';
import { plus, trash } from '@wordpress/icons';
import { LEFT, RIGHT } from '@wordpress/keycodes';

/**
Expand Down Expand Up @@ -228,6 +228,8 @@ function ControlPoints( {
{ ! disableRemove && (
<Button
className="components-custom-gradient-picker__remove-control-point"
icon={ trash }
label={ __( 'Remove control point' ) }
onClick={ () => {
onChange(
removeControlPoint(
Expand All @@ -237,10 +239,7 @@ function ControlPoints( {
);
onClose();
} }
variant="link"
>
{ __( 'Remove Control Point' ) }
</Button>
/>
) }
</>
) }
Expand Down
6 changes: 4 additions & 2 deletions packages/components/src/custom-gradient-picker/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,11 @@ $components-custom-gradient-picker__padding: $grid-unit-20; // 48px container, 1

.components-custom-gradient-picker__color-picker-popover .components-custom-gradient-picker__remove-control-point {
margin-left: auto;
margin-right: auto;
padding: 0;
margin-right: $grid-unit-20;
display: block;
margin-bottom: $grid-unit-10;
min-width: $button-size-small;
height: $button-size-small;
}

.components-custom-gradient-picker__inserter {
Expand Down