Buttons: Improve the .button-link CSS class for link-like buttons.

Updates `.button-link` adding color and underline to make link-like buttons look
like links by default. Introduces `.button-link-delete` as a modifier, stackable
CSS class for red button-links.

Props Cheffheid, afercia.

See #34242.
Fixes #35126.


git-svn-id: https://develop.svn.wordpress.org/trunk@40052 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrea Fercia
2017-02-09 16:46:58 +00:00
parent 87364b0586
commit 7487559dfd
16 changed files with 109 additions and 114 deletions

View File

@@ -149,8 +149,7 @@ TABLE OF CONTENTS:
.wp-core-ui .button.focus,
.wp-core-ui .button:focus,
.wp-core-ui .button-secondary:focus,
.wp-core-ui .button-link:focus {
.wp-core-ui .button-secondary:focus {
border-color: #5b9dd9;
-webkit-box-shadow: 0 0 3px rgba( 0, 115, 170, .8 );
box-shadow: 0 0 3px rgba( 0, 115, 170, .8 );
@@ -210,9 +209,42 @@ TABLE OF CONTENTS:
background: none;
outline: none;
cursor: pointer;
/* Mimics the default link style in common.css */
color: #0073aa;
text-decoration: underline;
-webkit-transition-property: border, background, color;
transition-property: border, background, color;
-webkit-transition-duration: .05s;
transition-duration: .05s;
-webkit-transition-timing-function: ease-in-out;
transition-timing-function: ease-in-out;
}
.wp-core-ui .button-link:hover,
.wp-core-ui .button-link:active {
color: #00a0d2;
}
.wp-core-ui .button-link:focus {
color: #124964;
-webkit-box-shadow:
0 0 0 1px #5b9dd9,
0 0 2px 1px rgba(30, 140, 190, .8);
box-shadow:
0 0 0 1px #5b9dd9,
0 0 2px 1px rgba(30, 140, 190, .8);
}
.wp-core-ui .button-link-delete {
color: #a00;
}
.wp-core-ui .button-link-delete:hover,
.wp-core-ui .button-link-delete:focus {
color: #f00;
}
.ie8 .wp-core-ui .button-link:focus {
outline: #5b9dd9 solid 1px;
}

View File

@@ -189,6 +189,10 @@
transition: color .1s ease-in-out, background .1s ease-in-out;
}
.media-modal-close.button-link {
text-decoration: none;
}
.media-modal-close:active {
-webkit-box-shadow: none;
box-shadow: none;
@@ -995,6 +999,8 @@
border-radius: 3px;
-webkit-box-shadow: 0 0 0 1px rgba( 0, 0, 0, 0.3 );
box-shadow: 0 0 0 1px rgba( 0, 0, 0, 0.3 );
-webkit-transition: none;
transition: none;
}
.wp-core-ui .attachment-close:hover,
@@ -1007,12 +1013,14 @@
height: 24px;
width: 24px;
padding: 0;
border: 0;
position: absolute;
z-index: 10;
top: 0;
right: 0;
outline: none;
background: #eee;
cursor: pointer;
-webkit-box-shadow: 0 0 0 1px #fff, 0 0 0 2px rgba( 0, 0, 0, 0.15 );
box-shadow: 0 0 0 1px #fff, 0 0 0 2px rgba( 0, 0, 0, 0.15 );
}
@@ -1250,6 +1258,8 @@
position: absolute;
top: 0;
right: 0;
-webkit-transition: none;
transition: none;
}
.upload-errors .upload-error {
@@ -1442,6 +1452,7 @@
line-height: 16px;
border-right: 1px solid #ddd;
color: #0073aa;
text-decoration: none;
}
.media-selection .button-link:hover,
@@ -1978,6 +1989,12 @@
padding: 0;
color: #666;
text-transform: uppercase;
text-decoration: none;
}
.image-details .advanced-toggle:hover,
.image-details .advanced-toggle:active {
color: #666;
}
.image-details .advanced-toggle:after {

View File

@@ -92,6 +92,7 @@
height: 22px;
width: 22px;
color: #72777c;
text-decoration: none;
}
#wp-auth-check-wrap .wp-auth-check-close:before {