Skip to content

Commit

Permalink
Alternate version of 51786
Browse files Browse the repository at this point in the history
  • Loading branch information
joedolson committed Sep 27, 2024
1 parent a51f2e4 commit 8dd2aa7
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 8 deletions.
19 changes: 12 additions & 7 deletions src/wp-admin/css/login.css
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,10 @@ p {
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.login form h1 {
margin-bottom: 10px;
}

.login form.shake {
animation: shake 0.2s cubic-bezier(.19,.49,.38,.79) both;
animation-iteration-count: 3;
Expand Down Expand Up @@ -224,7 +228,7 @@ p {
margin: 1.1em 0;
}

.login h1.admin-email__heading {
.login .admin-email__heading {
border-bottom: 1px #f0f0f1 solid;
color: #50575e;
font-weight: normal;
Expand Down Expand Up @@ -269,11 +273,12 @@ p {
vertical-align: baseline;
}

.login h1 {
text-align: center;
#loginform h1 {
text-align: left;
font-size: 20px;
}

.login h1 a {
.login .logo a {
background-image: url(../images/w-logo-blue.png?ver=20131202);
background-image: none, url(../images/wordpress-logo.svg?ver=20131107);
background-size: 84px;
Expand Down Expand Up @@ -323,13 +328,13 @@ p {

.login #nav a:hover,
.login #backtoblog a:hover,
.login h1 a:hover {
.login .logo a:hover {
color: #135e96;
}

.login #nav a:focus,
.login #backtoblog a:focus,
.login h1 a:focus {
.login .logo a:focus {
color: #043959;
}

Expand Down Expand Up @@ -390,7 +395,7 @@ body.interim-login {
margin: 5px auto 20px;
}

.interim-login.login h1 a {
.interim-login.login .logo a {
width: auto;
}

Expand Down
8 changes: 7 additions & 1 deletion src/wp-login.php
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ function login_header( $title = null, $message = '', $wp_error = null ) {
?>
</head>
<body class="login no-js <?php echo esc_attr( implode( ' ', $classes ) ); ?>">
<main>
<?php
wp_print_inline_script_tag( "document.body.className = document.body.className.replace('no-js','js');" );
?>
Expand All @@ -213,7 +214,7 @@ function login_header( $title = null, $message = '', $wp_error = null ) {

?>
<div id="login">
<h1><a href="<?php echo esc_url( $login_header_url ); ?>"><?php echo $login_header_text; ?></a></h1>
<h1 role="presentation" class="logo"><a href="<?php echo esc_url( $login_header_url ); ?>"><?php echo $login_header_text; ?></a></h1>
<?php
/**
* Filters the message to display above the login form.
Expand Down Expand Up @@ -441,6 +442,7 @@ function login_footer( $input_id = '' ) {
do_action( 'login_footer' );

?>
</main>
</body>
</html>
<?php
Expand Down Expand Up @@ -887,6 +889,7 @@ function wp_login_viewport_meta() {
?>

<form name="lostpasswordform" id="lostpasswordform" action="<?php echo esc_url( network_site_url( 'wp-login.php?action=lostpassword', 'login_post' ) ); ?>" method="post">
<h1 class="screen-reader-text"><?php _e( 'Lost Password' ); ?></h1>
<p>
<label for="user_login"><?php _e( 'Username or Email Address' ); ?></label>
<input type="text" name="user_login" id="user_login" class="input" value="<?php echo esc_attr( $user_login ); ?>" size="20" autocapitalize="off" autocomplete="username" required="required" />
Expand Down Expand Up @@ -1025,6 +1028,7 @@ function wp_login_viewport_meta() {
?>
<form name="resetpassform" id="resetpassform" action="<?php echo esc_url( network_site_url( 'wp-login.php?action=resetpass', 'login_post' ) ); ?>" method="post" autocomplete="off">
<input type="hidden" id="user_login" value="<?php echo esc_attr( $rp_login ); ?>" autocomplete="off" />
<h1 class="screen-reader-text"><?php _e( 'Reset Password' ); ?></h1>

<div class="user-pass1-wrap">
<p>
Expand Down Expand Up @@ -1158,6 +1162,7 @@ function wp_login_viewport_meta() {

?>
<form name="registerform" id="registerform" action="<?php echo esc_url( site_url( 'wp-login.php?action=register', 'login_post' ) ); ?>" method="post" novalidate="novalidate">
<h1 class="screen-reader-text"><?php _e( 'Register' ); ?></h1>
<p>
<label for="user_login"><?php _e( 'Username' ); ?></label>
<input type="text" name="user_login" id="user_login" class="input" value="<?php echo esc_attr( $user_login ); ?>" size="20" autocapitalize="off" autocomplete="username" required="required" />
Expand Down Expand Up @@ -1502,6 +1507,7 @@ function wp_login_viewport_meta() {
?>

<form name="loginform" id="loginform" action="<?php echo esc_url( site_url( 'wp-login.php', 'login_post' ) ); ?>" method="post">
<h1 class="screen-reader-text"><?php _e( 'Log in' ); ?></h1>
<p>
<label for="user_login"><?php _e( 'Username or Email Address' ); ?></label>
<input type="text" name="log" id="user_login"<?php echo $aria_describedby; ?> class="input" value="<?php echo esc_attr( $user_login ); ?>" size="20" autocapitalize="off" autocomplete="username" required="required" />
Expand Down

0 comments on commit 8dd2aa7

Please sign in to comment.