Customize: Fix alignment of Customize, Activate, and Live Preview buttons appearing on the Themes admin screen.

Amends [41893].
Props Mahvash-Fatima.
See #42215.
Fixes #42275.

Built from https://develop.svn.wordpress.org/trunk@41949


git-svn-id: http://core.svn.wordpress.org/trunk@41783 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Weston Ruter 2017-10-19 18:10:47 +00:00
parent d695648084
commit c8105f1460
11 changed files with 154 additions and 100 deletions

View File

@ -1675,6 +1675,12 @@ p.customize-section-description {
margin-left: 12px;
}
.theme-browser .theme.active .theme-actions,
.wp-customizer .theme-browser .theme .theme-actions {
padding: 10px 15px;
box-shadow: inset 0 1px 0 rgba(0,0,0,0.1);
}
@media screen and ( max-width: 640px ) {
.customize-section-description-container + #customize-control-custom_css:last-child {
margin-left: 0;
@ -2098,21 +2104,6 @@ p.customize-section-description {
font-size: 15px;
}
.theme-id-container {
position: relative;
}
.theme-browser .theme.active .theme-actions,
.wp-customizer .theme-browser .theme .theme-actions {
position: absolute;
top: 50%;
-webkit-transform: translateY(-50%);
transform: translateY(-50%);
left: 0;
padding: 10px 15px;
box-shadow: inset 0 1px 0 rgba(0,0,0,0.1);
}
#customize-controls .theme-overlay .theme-name {
font-size: 32px;
}
@ -3042,3 +3033,11 @@ body.adding-widget .add-new-widget:before,
box-shadow: inset 0 1px 0 rgba(0,0,0,0.1);
}
}
@media screen and ( max-width: 600px ) {
.theme-browser .theme.active .theme-actions,
.wp-customizer .theme-browser .theme .theme-actions {
padding: 8px 15px;
box-shadow: none;
}
}

File diff suppressed because one or more lines are too long

View File

@ -1675,6 +1675,12 @@ p.customize-section-description {
margin-right: 12px;
}
.theme-browser .theme.active .theme-actions,
.wp-customizer .theme-browser .theme .theme-actions {
padding: 10px 15px;
box-shadow: inset 0 1px 0 rgba(0,0,0,0.1);
}
@media screen and ( max-width: 640px ) {
.customize-section-description-container + #customize-control-custom_css:last-child {
margin-right: 0;
@ -2098,21 +2104,6 @@ p.customize-section-description {
font-size: 15px;
}
.theme-id-container {
position: relative;
}
.theme-browser .theme.active .theme-actions,
.wp-customizer .theme-browser .theme .theme-actions {
position: absolute;
top: 50%;
-webkit-transform: translateY(-50%);
transform: translateY(-50%);
right: 0;
padding: 10px 15px;
box-shadow: inset 0 1px 0 rgba(0,0,0,0.1);
}
#customize-controls .theme-overlay .theme-name {
font-size: 32px;
}
@ -3042,3 +3033,11 @@ body.adding-widget .add-new-widget:before,
box-shadow: inset 0 1px 0 rgba(0,0,0,0.1);
}
}
@media screen and ( max-width: 600px ) {
.theme-browser .theme.active .theme-actions,
.wp-customizer .theme-browser .theme .theme-actions {
padding: 8px 15px;
box-shadow: none;
}
}

File diff suppressed because one or more lines are too long

View File

@ -222,6 +222,21 @@ body.js .theme-browser.search-loading {
opacity: 1;
}
.theme-id-container {
position: relative;
}
.theme-browser .theme.active .theme-actions,
.theme-browser .theme .theme-actions {
position: absolute;
top: 50%;
-webkit-transform: translateY(-50%);
transform: translateY(-50%);
left: 0;
padding: 10px 15px;
box-shadow: inset 0 1px 0 rgba(0,0,0,0.1);
}
.theme-browser .theme.active .theme-actions .button-primary {
margin-left: 0;
}
@ -1892,6 +1907,16 @@ body.full-overlay-active {
margin-top: 6px;
line-height: normal;
}
.theme-browser .theme .theme-actions .button {
margin-bottom: 0;
}
.theme-browser .theme.active .theme-actions,
.theme-browser .theme .theme-actions {
padding-top: 8px;
padding-bottom: 8px;
}
}
@media aural {

File diff suppressed because one or more lines are too long

View File

@ -222,6 +222,21 @@ body.js .theme-browser.search-loading {
opacity: 1;
}
.theme-id-container {
position: relative;
}
.theme-browser .theme.active .theme-actions,
.theme-browser .theme .theme-actions {
position: absolute;
top: 50%;
-webkit-transform: translateY(-50%);
transform: translateY(-50%);
right: 0;
padding: 10px 15px;
box-shadow: inset 0 1px 0 rgba(0,0,0,0.1);
}
.theme-browser .theme.active .theme-actions .button-primary {
margin-right: 0;
}
@ -1892,6 +1907,16 @@ body.full-overlay-active {
margin-top: 6px;
line-height: normal;
}
.theme-browser .theme .theme-actions .button {
margin-bottom: 0;
}
.theme-browser .theme.active .theme-actions,
.theme-browser .theme .theme-actions {
padding-top: 8px;
padding-bottom: 8px;
}
}
@media aural {

File diff suppressed because one or more lines are too long

View File

@ -264,6 +264,8 @@ if ( $tab ) {
printf( __( 'By %s' ), '{{ data.author }}' );
?>
</div>
<div class="theme-id-container">
<h3 class="theme-name">{{ data.name }}</h3>
<div class="theme-actions">
@ -289,6 +291,7 @@ if ( $tab ) {
<button class="button preview install-theme-preview"><?php _e( 'Preview' ); ?></button>
<# } #>
</div>
</div>
<# if ( data.installed ) { #>
<div class="notice notice-success notice-alt"><p><?php _ex( 'Installed', 'theme' ); ?></p></div>

View File

@ -273,6 +273,7 @@ foreach ( $themes as $theme ) :
<span class="more-details" id="<?php echo $aria_action; ?>"><?php _e( 'Theme Details' ); ?></span>
<div class="theme-author"><?php printf( __( 'By %s' ), $theme['author'] ); ?></div>
<div class="theme-id-container">
<?php if ( $theme['active'] ) { ?>
<h2 class="theme-name" id="<?php echo $aria_name; ?>">
<?php
@ -285,7 +286,6 @@ foreach ( $themes as $theme ) :
<?php } ?>
<div class="theme-actions">
<?php if ( $theme['active'] ) { ?>
<?php if ( $theme['actions']['customize'] && current_user_can( 'edit_theme_options' ) && current_user_can( 'customize' ) ) { ?>
<a class="button button-primary customize load-customize hide-if-no-customize" href="<?php echo $theme['actions']['customize']; ?>"><?php _e( 'Customize' ); ?></a>
@ -302,6 +302,7 @@ foreach ( $themes as $theme ) :
<?php } ?>
</div>
</div>
</div>
<?php endforeach; ?>
</div>
@ -407,6 +408,7 @@ $can_install = current_user_can( 'install_themes' );
?>
</div>
<div class="theme-id-container">
<# if ( data.active ) { #>
<h2 class="theme-name" id="{{ data.id }}-name">
<?php
@ -432,6 +434,7 @@ $can_install = current_user_can( 'install_themes' );
<a class="button button-primary load-customize hide-if-no-customize" href="{{{ data.actions.customize }}}"><?php _e( 'Live Preview' ); ?></a>
<# } #>
</div>
</div>
</script>
<script id="tmpl-theme-single" type="text/template">

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.9-beta3-41948';
$wp_version = '4.9-beta3-41949';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.