Changeset 48270
- Timestamp:
- 07/01/2020 08:36:32 PM (5 years ago)
- Location:
- trunk/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/js/_enqueues/admin/user-profile.js
r48121 r48270 3 3 */ 4 4 5 /* global ajaxurl, pwsL10n , userProfileL10n*/5 /* global ajaxurl, pwsL10n */ 6 6 (function($) { 7 7 var updateLock = false, 8 8 __ = wp.i18n.__, 9 9 $pass1Row, 10 10 $pass1, … … 40 40 41 41 // Once zxcvbn loads, passwords strength is known. 42 $( '#pw-weak-text-label' ). html( userProfileL10n.warnWeak);42 $( '#pw-weak-text-label' ).text( __( 'Confirm use of weak password' ) ); 43 43 } 44 44 … … 65 65 $toggleButton 66 66 .attr({ 67 'aria-label': show ? userProfileL10n.ariaShow : userProfileL10n.ariaHide67 'aria-label': show ? __( 'Show password' ) : __( 'Hide password' ) 68 68 }) 69 69 .find( '.text' ) 70 .text( show ? userProfileL10n.show : userProfileL10n.hide)70 .text( show ? __( 'Show' ) : __( 'Hide' ) ) 71 71 .end() 72 72 .find( '.dashicons' ) … … 403 403 $( window ).on( 'beforeunload', function () { 404 404 if ( true === updateLock ) { 405 return userProfileL10n.warn;405 return __( 'Your new password has not been saved.' ); 406 406 } 407 407 } ); -
trunk/src/wp-includes/script-loader.php
r48268 r48270 1066 1066 1067 1067 $scripts->add( 'user-profile', "/wp-admin/js/user-profile$suffix.js", array( 'jquery', 'password-strength-meter', 'wp-util' ), false, 1 ); 1068 did_action( 'init' ) && $scripts->localize( 1069 'user-profile', 1070 'userProfileL10n', 1071 array( 1072 'warn' => __( 'Your new password has not been saved.' ), 1073 'warnWeak' => __( 'Confirm use of weak password' ), 1074 'show' => __( 'Show' ), 1075 'hide' => __( 'Hide' ), 1076 'cancel' => __( 'Cancel' ), 1077 'ariaShow' => esc_attr__( 'Show password' ), 1078 'ariaHide' => esc_attr__( 'Hide password' ), 1079 ) 1080 ); 1068 $scripts->set_translations( 'user-profile' ); 1081 1069 1082 1070 $scripts->add( 'language-chooser', "/wp-admin/js/language-chooser$suffix.js", array( 'jquery' ), false, 1 );
Note: See TracChangeset
for help on using the changeset viewer.