Skip to content

Commit e6908ac

Browse files
committed
Settings: Widen time/day input fields on General Settings page, and move the preview onto the next line.
Props desrosj, afercia. Fixes #41603. git-svn-id: https://develop.svn.wordpress.org/trunk@41857 602fd350-edb4-49c9-b593-d223f7449a82
1 parent b0cfcbb commit e6908ac

2 files changed

Lines changed: 7 additions & 5 deletions

File tree

src/wp-admin/css/forms.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1340,7 +1340,7 @@ table.form-table td .updated p {
13401340
}
13411341

13421342
.options-general-php input[type="text"].small-text {
1343-
max-width: 60px;
1343+
max-width: 6.25em;
13441344
margin: 0;
13451345
}
13461346
}

src/wp-admin/options-general.php

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -307,8 +307,9 @@
307307
echo '/> <span class="date-time-text date-time-custom-text">' . __( 'Custom:' ) . '<span class="screen-reader-text"> ' . __( 'enter a custom date format in the following field' ) . '</span></span></label>' .
308308
'<label for="date_format_custom" class="screen-reader-text">' . __( 'Custom date format:' ) . '</label>' .
309309
'<input type="text" name="date_format_custom" id="date_format_custom" value="' . esc_attr( get_option( 'date_format' ) ) . '" class="small-text" />' .
310-
'<span class="screen-reader-text">' . __( 'example:' ) . ' </span> <span class="example">' . date_i18n( get_option( 'date_format' ) ) . '</span>' .
311-
"<span class='spinner'></span>\n";
310+
'<br />' .
311+
'<p><strong>' . __( 'Preview:' ) . '</strong> <span class="example">' . date_i18n( get_option( 'date_format' ) ) . '</span>' .
312+
"<span class='spinner'></span>\n" . '</p>';
312313
?>
313314
</fieldset>
314315
</td>
@@ -343,8 +344,9 @@
343344
echo '/> <span class="date-time-text date-time-custom-text">' . __( 'Custom:' ) . '<span class="screen-reader-text"> ' . __( 'enter a custom time format in the following field' ) . '</span></span></label>' .
344345
'<label for="time_format_custom" class="screen-reader-text">' . __( 'Custom time format:' ) . '</label>' .
345346
'<input type="text" name="time_format_custom" id="time_format_custom" value="' . esc_attr( get_option( 'time_format' ) ) . '" class="small-text" />' .
346-
'<span class="screen-reader-text">' . __( 'example:' ) . ' </span> <span class="example">' . date_i18n( get_option( 'time_format' ) ) . '</span>' .
347-
"<span class='spinner'></span>\n";
347+
'<br />' .
348+
'<p><strong>' . __( 'Preview:' ) . '</strong> <span class="example">' . date_i18n( get_option( 'time_format' ) ) . '</span>' .
349+
"<span class='spinner'></span>\n" . '</p>';
348350

349351
echo "\t<p class='date-time-doc'>" . __('<a href="https://codex.wordpress.org/Formatting_Date_and_Time">Documentation on date and time formatting</a>.') . "</p>\n";
350352
?>

0 commit comments

Comments
 (0)