Changeset 55974
- Timestamp:
- 06/22/2023 12:30:41 AM (13 months ago)
- Location:
- trunk/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/js/_enqueues/admin/user-profile.js
r53122 r55974 53 53 54 54 // Focus the password field. 55 $( $pass1 ).trigger( 'focus' ); 55 if ( 'mailserver_pass' !== $pass1.prop('id' ) ) { 56 $( $pass1 ).trigger( 'focus' ); 57 } 56 58 } 57 59 … … 172 174 $cancelButton; 173 175 174 $pass1Row = $( '.user-pass1-wrap, .user-pass-wrap, . reset-pass-submit' );176 $pass1Row = $( '.user-pass1-wrap, .user-pass-wrap, .reset-pass-submit' ); 175 177 176 178 // Hide the confirm password field when JavaScript support is enabled. … … 189 191 } ); 190 192 191 $pass1 = $('#pass1 ');193 $pass1 = $('#pass1'); 192 194 if ( $pass1.length ) { 193 195 bindPass1(); … … 315 317 316 318 function showOrHideWeakPasswordCheckbox() { 317 var passStrength = $('#pass-strength-result')[0]; 318 319 if ( passStrength.className ) { 320 $pass1.addClass( passStrength.className ); 321 if ( $( passStrength ).is( '.short, .bad' ) ) { 322 if ( ! $weakCheckbox.prop( 'checked' ) ) { 323 $submitButtons.prop( 'disabled', true ); 319 var passStrengthResult = $('#pass-strength-result'); 320 321 if ( passStrengthResult.length ) { 322 var passStrength = passStrengthResult[0]; 323 324 if ( passStrength.className ) { 325 $pass1.addClass( passStrength.className ); 326 if ( $( passStrength ).is( '.short, .bad' ) ) { 327 if ( ! $weakCheckbox.prop( 'checked' ) ) { 328 $submitButtons.prop( 'disabled', true ); 329 } 330 $weakRow.show(); 331 } else { 332 if ( $( passStrength ).is( '.empty' ) ) { 333 $submitButtons.prop( 'disabled', true ); 334 $weakCheckbox.prop( 'checked', false ); 335 } else { 336 $submitButtons.prop( 'disabled', false ); 337 } 338 $weakRow.hide(); 324 339 } 325 $weakRow.show();326 } else {327 if ( $( passStrength ).is( '.empty' ) ) {328 $submitButtons.prop( 'disabled', true );329 $weakCheckbox.prop( 'checked', false );330 } else {331 $submitButtons.prop( 'disabled', false );332 }333 $weakRow.hide();334 340 } 335 341 } -
trunk/src/wp-admin/css/forms.css
r55689 r55974 552 552 .wp-pwd { 553 553 margin-top: 1em; 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 554 602 } 555 603 -
trunk/src/wp-admin/options-writing.php
r55904 r55974 54 54 '<p>' . __( '<a href="https://wordpress.org/support/forums/">Support forums</a>' ) . '</p>' 55 55 ); 56 57 56 58 57 59 require_once ABSPATH . 'wp-admin/admin-header.php'; … … 169 171 <td><input name="mailserver_login" type="text" id="mailserver_login" value="<?php form_option( 'mailserver_login' ); ?>" class="regular-text ltr" /></td> 170 172 </tr> 171 <tr> 172 <th scope="row"><label for="mailserver_pass"><?php _e( 'Password' ); ?></label></th> 173 <td> 174 <input name="mailserver_pass" type="text" id="mailserver_pass" value="<?php form_option( 'mailserver_pass' ); ?>" class="regular-text ltr" /> 175 </td> 173 <tr class="mailserver-pass-wrap"> 174 <th scope="row"> 175 <label for="mailserver_pass"> 176 <?php _e( 'Password' ); ?> 177 </label> 178 </th> 179 <td> 180 <input type="hidden" value=" " /><!-- #24364 workaround --> 181 <span class="wp-pwd"> 182 <input type="text" name="mailserver_pass" id="mailserver_pass" class="regular-text ltr" autocomplete="off" data-reveal="1" data-pw="<?php echo esc_attr( get_option( 'mailserver_pass' ) ); ?>" /> 183 <button type="button" class="button wp-hide-pw hide-if-no-js" data-toggle="0" data-start-masked="1" aria-label="<?php esc_attr_e( 'Hide password' ); ?>"> 184 <span class="dashicons dashicons-visibility" aria-hidden="true"></span> 185 </button> 186 </span> 187 </td> 176 188 </tr> 177 189 <tr>
Note: See TracChangeset
for help on using the changeset viewer.