From 048ac7df673e93f6c0f4def012779f27a9dc7946 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Fri, 21 Jul 2017 18:13:45 +0000 Subject: [PATCH] Widgets: Improve theme styling compatibility for Custom HTML widget by adding container with `textwidget` class. The same styling from the Text widget should apply to the Custom HTML widget since users are expected to copy HTML from the (legacy) Text widget into the latter. Amends [40893]. See #40907. Fixes #41392. Built from https://develop.svn.wordpress.org/trunk@41115 git-svn-id: http://core.svn.wordpress.org/trunk@40955 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/version.php | 2 +- wp-includes/widgets/class-wp-widget-custom-html.php | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/wp-includes/version.php b/wp-includes/version.php index fbb352f9f9..bfb7c292cc 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.9-alpha-41114'; +$wp_version = '4.9-alpha-41115'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. diff --git a/wp-includes/widgets/class-wp-widget-custom-html.php b/wp-includes/widgets/class-wp-widget-custom-html.php index 5de618285f..7447415185 100644 --- a/wp-includes/widgets/class-wp-widget-custom-html.php +++ b/wp-includes/widgets/class-wp-widget-custom-html.php @@ -79,7 +79,9 @@ class WP_Widget_Custom_HTML extends WP_Widget { if ( ! empty( $title ) ) { echo $args['before_title'] . $title . $args['after_title']; } + echo '
'; // The textwidget class is for theme styling compatibility. echo $content; + echo '
'; echo $args['after_widget']; }