Ticket #22965: 22965.diff

File 22965.diff, 2.1 KB (added by helen, 5 months ago)
Line 
1Index: wp-includes/default-widgets.php
2===================================================================
3--- wp-includes/default-widgets.php     (revision 23195)
4+++ wp-includes/default-widgets.php     (working copy)
5@@ -723,7 +723,7 @@
6                <input class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" value="<?php echo $title; ?>" /></p>
7 
8                <p><label for="<?php echo $this->get_field_id('number'); ?>"><?php _e('Number of comments to show:'); ?></label>
9-               <input id="<?php echo $this->get_field_id('number'); ?>" name="<?php echo $this->get_field_name('number'); ?>" type="text" value="<?php echo $number; ?>" size="3" /></p>
10+               <input class="tiny-text" id="<?php echo $this->get_field_id('number'); ?>" name="<?php echo $this->get_field_name('number'); ?>" type="number" step="1" min="1" value="<?php echo $number; ?>" size="3" /></p>
11 <?php
12        }
13 }
14Index: wp-admin/includes/dashboard.php
15===================================================================
16--- wp-admin/includes/dashboard.php     (revision 23195)
17+++ wp-admin/includes/dashboard.php     (working copy)
18@@ -766,7 +766,7 @@
19        $number = isset( $widget_options['dashboard_recent_comments']['items'] ) ? (int) $widget_options['dashboard_recent_comments']['items'] : '';
20 
21        echo '<p><label for="comments-number">' . __('Number of comments to show:') . '</label>';
22-       echo '<input id="comments-number" name="widget-recent-comments[items]" type="text" value="' . $number . '" size="3" /></p>';
23+       echo ' <input class="small-text" id="comments-number" name="widget-recent-comments[items]" type="number" step="1" min="1" value="' . $number . '" size="3" /></p>';
24 }
25 
26 function wp_dashboard_incoming_links() {
27Index: wp-admin/css/wp-admin.css
28===================================================================
29--- wp-admin/css/wp-admin.css   (revision 23195)
30+++ wp-admin/css/wp-admin.css   (working copy)
31@@ -886,6 +886,14 @@
32        width: 60px;
33 }
34 
35+input.tiny-text {
36+       width: 35px;
37+}
38+
39+input[type="number"].tiny-text {
40+       width: 45px;
41+}
42+
43 #doaction,
44 #doaction2,
45 #post-query-submit {