Skip to content

Commit

Permalink
Update destructive tertiary button styles, and template list (#36915)
Browse files Browse the repository at this point in the history
* Update destructive tertiary button styles, and template list

* Make trash button variant "secondary"

* Make template delete action tertiary
  • Loading branch information
jameskoster committed Nov 29, 2021
1 parent 2caede2 commit f3c9ed0
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 1 deletion.
14 changes: 14 additions & 0 deletions packages/components/src/button/style.scss
Expand Up @@ -201,6 +201,20 @@
}
}

&.is-destructive.is-tertiary {
box-shadow: none;

&:hover:not(:disabled) {
box-shadow: inset 0 0 0 $border-width $alert-red;
color: $alert-red;
}

&:focus:not(:disabled) {
box-shadow: inset 0 0 0 1px $white, 0 0 0 var(--wp-admin-border-width-focus) $alert-red;
color: $alert-red;
}
}


/**
* Link buttons.
Expand Down
1 change: 1 addition & 0 deletions packages/edit-site/src/components/list/actions/index.js
Expand Up @@ -68,6 +68,7 @@ export default function Actions( { template } ) {
/>
<MenuItem
isDestructive
isTertiary
onClick={ () => {
removeTemplate( template );
onClose();
Expand Down
2 changes: 1 addition & 1 deletion packages/editor/src/components/post-trash/index.js
Expand Up @@ -22,7 +22,7 @@ function PostTrash( { isNew, postId, postType, ...props } ) {
<Button
className="editor-post-trash"
isDestructive
variant="tertiary"
variant="secondary"
onClick={ onClick }
>
{ __( 'Move to trash' ) }
Expand Down

0 comments on commit f3c9ed0

Please sign in to comment.