Skip to content

Commit cde933e

Browse files
committed
After [36171] remove all the occurrences of the old CSS clearfix.
The old clearfix was applied to very specific items and defined multiple times across CSS files. Uses the new generic `.wp-clearfix` utility class instead. See #26396. git-svn-id: https://develop.svn.wordpress.org/trunk@36422 602fd350-edb4-49c9-b593-d223f7449a82
1 parent 3964f0e commit cde933e

13 files changed

Lines changed: 24 additions & 72 deletions

src/wp-admin/css/list-tables.css

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -974,14 +974,6 @@ tr.inline-edit-row td,
974974
line-height: 2.5;
975975
}
976976

977-
.inline-edit-row fieldset .inline-edit-group:after {
978-
content: ".";
979-
display: block;
980-
height: 0;
981-
clear: both;
982-
visibility: hidden;
983-
}
984-
985977
.inline-edit-row p.submit {
986978
clear: both;
987979
padding: 0.5em;

src/wp-admin/css/nav-menus.css

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -747,23 +747,6 @@ body.menu-max-depth-11 { min-width: 1280px !important; }
747747
margin-left: -4px;
748748
}
749749

750-
/* Clearfix */
751-
#menu-item-name-wrap:after,
752-
#menu-item-url-wrap:after,
753-
#menu-name-label:after,
754-
#menu-settings-column .inside:after,
755-
#nav-menus-frame:after,
756-
.nav-menus-php #post-body-content:after,
757-
.nav-menus-php .button-controls:after,
758-
.nav-menus-php .major-publishing-actions:after,
759-
.nav-menus-php .menu-item-settings:after {
760-
clear: both;
761-
content: ".";
762-
display: block;
763-
height: 0;
764-
visibility: hidden;
765-
}
766-
767750
#nav-menus-frame,
768751
.button-controls,
769752
#menu-item-url-wrap,

src/wp-admin/css/themes.css

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -524,14 +524,6 @@
524524
-webkit-overflow-scrolling: touch;
525525
}
526526

527-
.theme-overlay .theme-wrap:after {
528-
content: ".";
529-
display: block;
530-
height: 0;
531-
clear: both;
532-
visibility: hidden;
533-
}
534-
535527
body.folded .theme-overlay .theme-wrap {
536528
left: 70px;
537529
}
@@ -545,13 +537,6 @@ body.folded .theme-overlay .theme-wrap {
545537
overflow: auto;
546538
padding: 2% 4%;
547539
}
548-
.theme-overlay .theme-about:after {
549-
content: ".";
550-
display: block;
551-
height: 0;
552-
clear: both;
553-
visibility: hidden;
554-
}
555540

556541
.theme-overlay .theme-actions {
557542
position: absolute;

src/wp-admin/css/widgets.css

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -230,14 +230,6 @@ div#widgets-left .inactive-sidebar .widgets-sortables {
230230

231231
/* Widgets Right */
232232

233-
div#widgets-right:after {
234-
content: ".";
235-
display: block;
236-
height: 0;
237-
clear: both;
238-
visibility: hidden;
239-
}
240-
241233
div#widgets-right .sidebars-column-1,
242234
div#widgets-right .sidebars-column-2 {
243235
max-width: 450px;

src/wp-admin/customize.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@
127127
</a>
128128
</div>
129129

130-
<div id="widgets-right"><!-- For Widget Customizer, many widgets try to look for instances under div#widgets-right, so we have to add that ID to a container div in the Customizer for compat -->
130+
<div id="widgets-right" class="wp-clearfix"><!-- For Widget Customizer, many widgets try to look for instances under div#widgets-right, so we have to add that ID to a container div in the Customizer for compat -->
131131
<div class="wp-full-overlay-sidebar-content" tabindex="-1">
132132
<div id="customize-info" class="accordion-section customize-info">
133133
<div class="accordion-section-title">

src/wp-admin/includes/class-walker-nav-menu-edit.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ public function start_el( &$output, $item, $depth = 0, $args = array(), $id = 0
150150
</div>
151151
</div>
152152

153-
<div class="menu-item-settings" id="menu-item-settings-<?php echo $item_id; ?>">
153+
<div class="menu-item-settings wp-clearfix" id="menu-item-settings-<?php echo $item_id; ?>">
154154
<?php if ( 'custom' == $item->type ) : ?>
155155
<p class="field-url description description-wide">
156156
<label for="edit-menu-item-url-<?php echo $item_id; ?>">

src/wp-admin/includes/class-wp-posts-list-table.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1405,7 +1405,7 @@ public function inline_edit() {
14051405
if ( !$bulk && $can_publish ) :
14061406
?>
14071407

1408-
<div class="inline-edit-group">
1408+
<div class="inline-edit-group wp-clearfix">
14091409
<label class="alignleft">
14101410
<span class="title"><?php _e( 'Password' ); ?></span>
14111411
<span class="input-text-wrap"><input type="text" name="post_password" class="inline-edit-password-input" value="" /></span>
@@ -1537,7 +1537,7 @@ public function inline_edit() {
15371537
<?php if ( post_type_supports( $screen->post_type, 'comments' ) || post_type_supports( $screen->post_type, 'trackbacks' ) ) :
15381538
if ( $bulk ) : ?>
15391539

1540-
<div class="inline-edit-group">
1540+
<div class="inline-edit-group wp-clearfix">
15411541
<?php if ( post_type_supports( $screen->post_type, 'comments' ) ) : ?>
15421542
<label class="alignleft">
15431543
<span class="title"><?php _e( 'Comments' ); ?></span>
@@ -1561,7 +1561,7 @@ public function inline_edit() {
15611561

15621562
<?php else : // $bulk ?>
15631563

1564-
<div class="inline-edit-group">
1564+
<div class="inline-edit-group wp-clearfix">
15651565
<?php if ( post_type_supports( $screen->post_type, 'comments' ) ) : ?>
15661566
<label class="alignleft">
15671567
<input type="checkbox" name="comment_status" value="open" />
@@ -1578,7 +1578,7 @@ public function inline_edit() {
15781578
<?php endif; // $bulk
15791579
endif; // post_type_supports comments or pings ?>
15801580

1581-
<div class="inline-edit-group">
1581+
<div class="inline-edit-group wp-clearfix">
15821582
<label class="inline-edit-status alignleft">
15831583
<span class="title"><?php _e( 'Status' ); ?></span>
15841584
<select name="_status">

src/wp-admin/includes/nav-menu.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -263,17 +263,17 @@ function wp_nav_menu_item_link_meta_box() {
263263
?>
264264
<div class="customlinkdiv" id="customlinkdiv">
265265
<input type="hidden" value="custom" name="menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-type]" />
266-
<p id="menu-item-url-wrap">
266+
<p id="menu-item-url-wrap" class="wp-clearfix">
267267
<label class="howto" for="custom-menu-item-url"><?php _e( 'URL' ); ?></label>
268268
<input id="custom-menu-item-url" name="menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-url]" type="text" class="code menu-item-textbox" value="http://" />
269269
</p>
270270

271-
<p id="menu-item-name-wrap">
271+
<p id="menu-item-name-wrap" class="wp-clearfix">
272272
<label class="howto" for="custom-menu-item-name"><?php _e( 'Link Text' ); ?></label>
273273
<input id="custom-menu-item-name" name="menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-title]" type="text" class="regular-text menu-item-textbox" />
274274
</p>
275275

276-
<p class="button-controls">
276+
<p class="button-controls wp-clearfix">
277277
<span class="add-to-menu">
278278
<input type="submit"<?php wp_nav_menu_disabled_check( $nav_menu_selected_id ); ?> class="button-secondary submit-add-to-menu right" value="<?php esc_attr_e('Add to Menu'); ?>" name="add-custom-menu-item" id="submit-customlinkdiv" />
279279
<span class="spinner"></span>
@@ -540,7 +540,7 @@ function wp_nav_menu_item_post_type_meta_box( $object, $post_type ) {
540540
<?php endif; ?>
541541
</div><!-- /.tabs-panel -->
542542

543-
<p class="button-controls">
543+
<p class="button-controls wp-clearfix">
544544
<span class="list-controls">
545545
<a href="<?php
546546
echo esc_url( add_query_arg(
@@ -731,7 +731,7 @@ function wp_nav_menu_item_taxonomy_meta_box( $object, $taxonomy ) {
731731
</ul>
732732
</div><!-- /.tabs-panel -->
733733

734-
<p class="button-controls">
734+
<p class="button-controls wp-clearfix">
735735
<span class="list-controls">
736736
<a href="<?php
737737
echo esc_url(add_query_arg(

src/wp-admin/includes/theme.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -588,13 +588,13 @@ function customize_themes_print_templates() {
588588
?>
589589
<script type="text/html" id="tmpl-customize-themes-details-view">
590590
<div class="theme-backdrop"></div>
591-
<div class="theme-wrap">
591+
<div class="theme-wrap wp-clearfix">
592592
<div class="theme-header">
593593
<button type="button" class="left dashicons dashicons-no"><span class="screen-reader-text"><?php _e( 'Show previous theme' ); ?></span></button>
594594
<button type="button" class="right dashicons dashicons-no"><span class="screen-reader-text"><?php _e( 'Show next theme' ); ?></span></button>
595595
<button type="button" class="close dashicons dashicons-no"><span class="screen-reader-text"><?php _e( 'Close details dialog' ); ?></span></button>
596596
</div>
597-
<div class="theme-about">
597+
<div class="theme-about wp-clearfix">
598598
<div class="theme-screenshots">
599599
<# if ( data.screenshot[0] ) { #>
600600
<div class="screenshot"><img src="{{ data.screenshot[0] }}" alt="" /></div>

src/wp-admin/nav-menus.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -647,7 +647,7 @@ function wp_nav_menu_max_depth( $classes ) {
647647
<?php } // foreach ?>
648648
</tbody>
649649
</table>
650-
<p class="button-controls"><?php submit_button( __( 'Save Changes' ), 'primary left', 'nav-menu-locations', false ); ?></p>
650+
<p class="button-controls wp-clearfix"><?php submit_button( __( 'Save Changes' ), 'primary left', 'nav-menu-locations', false ); ?></p>
651651
<?php wp_nonce_field( 'save-menu-locations' ); ?>
652652
<input type="hidden" name="menu" id="nav-menu-meta-object-id" value="<?php echo esc_attr( $nav_menu_selected_id ); ?>" />
653653
</form>
@@ -714,7 +714,7 @@ function wp_nav_menu_max_depth( $classes ) {
714714
</form>
715715
<?php endif; ?>
716716
</div><!-- /manage-menus -->
717-
<div id="nav-menus-frame">
717+
<div id="nav-menus-frame" class="wp-clearfix">
718718
<div id="menu-settings-column" class="metabox-holder<?php if ( isset( $_GET['menu'] ) && '0' == $_GET['menu'] ) { echo ' metabox-holder-disabled'; } ?>">
719719

720720
<div class="clear"></div>
@@ -748,7 +748,7 @@ function wp_nav_menu_max_depth( $classes ) {
748748
<input type="hidden" name="action" value="update" />
749749
<input type="hidden" name="menu" id="menu" value="<?php echo esc_attr( $nav_menu_selected_id ); ?>" />
750750
<div id="nav-menu-header">
751-
<div class="major-publishing-actions">
751+
<div class="major-publishing-actions wp-clearfix">
752752
<label class="menu-name-label" for="menu-name"><?php _e( 'Menu Name' ); ?></label>
753753
<input name="menu-name" id="menu-name" type="text" class="menu-name regular-text menu-item-textbox" <?php echo $menu_name_val . $menu_name_aria_desc; ?> />
754754
<div class="publishing-action">
@@ -757,7 +757,7 @@ function wp_nav_menu_max_depth( $classes ) {
757757
</div><!-- END .major-publishing-actions -->
758758
</div><!-- END .nav-menu-header -->
759759
<div id="post-body">
760-
<div id="post-body-content">
760+
<div id="post-body-content" class="wp-clearfix">
761761
<?php if ( ! $add_new_screen ) : ?>
762762
<h3><?php _e( 'Menu Structure' ); ?></h3>
763763
<?php $starter_copy = ( $one_theme_location_no_menus ) ? __( 'Edit your default menu by adding or removing items. Drag each item into the order you prefer. Click Create Menu to save your changes.' ) : __( 'Drag each item into the order you prefer. Click the arrow on the right of the item to reveal additional configuration options.' ); ?>
@@ -822,7 +822,7 @@ function wp_nav_menu_max_depth( $classes ) {
822822
</div><!-- /#post-body-content -->
823823
</div><!-- /#post-body -->
824824
<div id="nav-menu-footer">
825-
<div class="major-publishing-actions">
825+
<div class="major-publishing-actions wp-clearfix">
826826
<?php if ( 0 != $menu_count && ! $add_new_screen ) : ?>
827827
<span class="delete-action">
828828
<a class="submitdelete deletion menu-delete" href="<?php echo esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'delete', 'menu' => $nav_menu_selected_id ), admin_url( 'nav-menus.php' ) ), 'delete-nav_menu-' . $nav_menu_selected_id) ); ?>"><?php _e('Delete Menu'); ?></a>

0 commit comments

Comments
 (0)