Twenty Twenty-One: Convert inline ESLint comments to JSHint.

WordPress Core currently uses JSHint instead of ESlint.

See #51526.
Built from https://develop.svn.wordpress.org/trunk@49575


git-svn-id: http://core.svn.wordpress.org/trunk@49313 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
desrosj 2020-11-12 18:48:08 +00:00
parent 967d29d83d
commit ee888ad547
4 changed files with 5 additions and 5 deletions

View File

@ -5,7 +5,7 @@
* *
* @return {number} - Returns the luminance, number between 0 and 255. * @return {number} - Returns the luminance, number between 0 and 255.
*/ */
function twentytwentyoneGetHexLum( hex ) { // eslint-disable-line no-unused-vars function twentytwentyoneGetHexLum( hex ) { // jshint ignore:line
var rgb = twentytwentyoneGetRgbFromHex( hex ); var rgb = twentytwentyoneGetRgbFromHex( hex );
return Math.round( ( 0.2126 * rgb.r ) + ( 0.7152 * rgb.g ) + ( 0.0722 * rgb.b ) ); return Math.round( ( 0.2126 * rgb.r ) + ( 0.7152 * rgb.g ) + ( 0.0722 * rgb.b ) );
} }

View File

@ -1,4 +1,4 @@
function toggleDarkMode() { // eslint-disable-line no-unused-vars function toggleDarkMode() { // jshint ignore:line
var toggler = document.getElementById( 'dark-mode-toggler' ); var toggler = document.getElementById( 'dark-mode-toggler' );
if ( 'false' === toggler.getAttribute( 'aria-pressed' ) ) { if ( 'false' === toggler.getAttribute( 'aria-pressed' ) ) {

View File

@ -58,7 +58,7 @@ function twentytwentyoneSubmenuPosition( li ) {
* *
* @param {Element} el - The element. * @param {Element} el - The element.
*/ */
function twentytwentyoneExpandSubMenu( el ) { // eslint-disable-line no-unused-vars function twentytwentyoneExpandSubMenu( el ) { // jshint ignore:line
// Close other expanded items. // Close other expanded items.
el.closest( 'nav' ).querySelectorAll( '.sub-menu-toggle' ).forEach( function( button ) { el.closest( 'nav' ).querySelectorAll( '.sub-menu-toggle' ).forEach( function( button ) {
if ( button !== el ) { if ( button !== el ) {
@ -114,7 +114,7 @@ function twentytwentyoneExpandSubMenu( el ) { // eslint-disable-line no-unused-v
tabKey = event.keyCode === 9; tabKey = event.keyCode === 9;
shiftKey = event.shiftKey; shiftKey = event.shiftKey;
escKey = event.keyCode === 27; escKey = event.keyCode === 27;
activeEl = document.activeElement; // eslint-disable-line @wordpress/no-global-active-element activeEl = document.activeElement;
lastEl = elements[ elements.length - 1 ]; lastEl = elements[ elements.length - 1 ];
firstEl = elements[0]; firstEl = elements[0];

View File

@ -13,7 +13,7 @@
* *
* @global string $wp_version * @global string $wp_version
*/ */
$wp_version = '5.6-beta3-49574'; $wp_version = '5.6-beta3-49575';
/** /**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.