File manager - Edit - /home/opticamezl/www/newok/plg_system_shortcut.zip
Back
PK ���\g~��$ $ js/shortcut-es5.min.js.gznu �[��� � �W�n�8}�W�|HHXf��>Ŗ�l��$p.��ˢ(�GldRK����}!Y�;m�ؼ$$Gg�g&t���ʦ$�xtZ"i�Ձ��!�9����8�8g%�֎R��_��b�9��K'�6�H�EX�q�T/�e�� [�Ȧ��'�x�C��#�� �x������S�,��f��f�Q,�W{W�(-��K�����<,�\�Z>��g�+��D��y�On҃$ZG�5���,@7��ie�o'�t�IW��p��6ʎyje)O#��y�� �*<|�S�>�%S�(�#�l��;�IaCG�x+F�t��3p�dE� ȧ�~'ok��j��� �(�"Na6�����>��N�s�Z�;����;���az�2%����4�ؓ6�jQ�L��#����R �jK~�c��B��#�9���>��)c�x�6��,}��G |O�(���� �G;i�{iD����̄�4��ڀk��6�5�pWϥ�P�%6a�"ׅ�El#"�2l�NB��xpx�� /�7]JbZ` ��w�J� z����A���}��Cp����U�����OX!��20�"ѩ�P�:9��EQ�Y�.���Hs�Z�2Y+nՌ�_j9��G�)����|mO��k+�����ln��g�O� �LF_��ע*m�����|d6"-��Ip%��za���$��踥0(U��jh�j�8��[O�j_�N�_ǡ�>K5RR'�/���8���-au��.8:=��N~Ȝ�%��m��<��:�;���>��SmA�^� � Ɇ�ë��)tY���i0 H�UD�Z�=�{�0�)�I�"�F���4ސ��"��H�# �@ш}#�I9�Eģ@-I ��TĐ������ 2N�R`"�.Ү�`�X:��X��l�CU�m��]B��1�Vr��F�-�p�<ރ ���/��U��!�����$9�c��e� �ŊO��!S�a.��H��n+"��/�w��i�N�;�)�Mc�&A�8�W5k���:���I�$ۃ���S�n(��}wkgck��xhz^��g5|�(aYYvckѣ/�����jL�}�E�p��� ��j����;����檅&�B6�&�����rj�b���=�Gɻ��j��Z�@��AKG?��?<a;�E(�Ȧ5�l-�}�}g3�^p�¡��1�䄰r|:t� fg'?��ǜ��{� ]�ן�� md�+�h��D�]_�ٟ�_�ds� "F<vtD�Y�S�BEY��]��p�/F�Ś��@c7� PK ���\t�� � � js/shortcut.jsnu �[��� ((document, Joomla) => { if (!Joomla) { throw new Error('Joomla API is not properly initialised'); } /* global hotkeys */ Joomla.addShortcut = (hotkey, callback) => { hotkeys(hotkey, 'joomla', event => { event.preventDefault(); event.stopPropagation(); event.stopImmediatePropagation(); callback.call(); }); }; Joomla.addClickShortcut = (hotkey, selector) => { Joomla.addShortcut(hotkey, () => { const element = document.querySelector(selector); if (element) { element.click(); } }); }; Joomla.addFocusShortcut = (hotkey, selector) => { Joomla.addShortcut(hotkey, () => { const element = document.querySelector(selector); if (element) { element.focus(); } }); }; Joomla.addLinkShortcut = (hotkey, selector) => { Joomla.addShortcut(hotkey, () => { window.location.href = selector; }); }; const setShortcutFilter = () => { hotkeys.filter = event => { const target = event.target || event.srcElement; const { tagName } = target; // Checkboxes should not block a shortcut event if (target.type === 'checkbox') { return true; } // Default hotkeys filter behavior return !(target.isContentEditable || tagName === 'INPUT' || tagName === 'SELECT' || tagName === 'TEXTAREA'); }; }; const startupShortcuts = () => { hotkeys('J', event => { // If we're already in the scope, it's a normal shortkey if (hotkeys.getScope() === 'joomla') { return; } event.preventDefault(); event.stopPropagation(); event.stopImmediatePropagation(); hotkeys.setScope('joomla'); // Leave the scope after x milliseconds setTimeout(() => { hotkeys.setScope(false); }, Joomla.getOptions('plg_system_shortcut.timeout', 2000)); }); }; const addOverviewHint = () => { const mainContainer = document.querySelector('.com_cpanel .container-main'); if (mainContainer) { const containerElement = document.createElement('section'); containerElement.className = 'content pt-4'; containerElement.insertAdjacentHTML('beforeend', Joomla.Text._('PLG_SYSTEM_SHORTCUT_OVERVIEW_HINT')); mainContainer.appendChild(containerElement); } }; const initOverviewModal = options => { const dlItems = new Map(); Object.values(options).forEach(value => { if (!value.shortcut || !value.title) { return; } let titles = []; if (dlItems.has(value.shortcut)) { titles = dlItems.get(value.shortcut); titles.push(value.title); } else { titles = [value.title]; } dlItems.set(value.shortcut, titles); }); let dl = '<dl>'; dlItems.forEach((titles, shortcut) => { dl += '<div>'; dl += '<dt class="d-inline-block"><kbd>J</kbd>'; shortcut.split('+').forEach(key => { dl += ` ${Joomla.Text._('PLG_SYSTEM_SHORTCUT_THEN')} <kbd>${key.trim()}</kbd>`; }); dl += '</dt>'; titles.forEach(title => { dl += `<dd class="d-inline-block ms-1">${title}</dd>`; }); dl += '</div>'; }); dl += '</dl>'; const modal = ` <div class="modal fade" id="shortcutOverviewModal" tabindex="-1" role="dialog" data-bs-backdrop="static" aria-labelledby="shortcutOverviewModalLabel" aria-hidden="true"> <div class="modal-dialog" role="document"> <div class="modal-content"> <div class="modal-header"> <h3 id="shortcutOverviewModalLabel" class="modal-title"> ${Joomla.Text._('PLG_SYSTEM_SHORTCUT_OVERVIEW_TITLE')} </h3> <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="${Joomla.Text._('JCLOSE')}"></button> </div> <div class="modal-body p-3"> <p>${Joomla.Text._('PLG_SYSTEM_SHORTCUT_OVERVIEW_DESC')}</p> <div class="mb-3"> ${dl} </div> </div> </div> </div> </div> `; document.body.insertAdjacentHTML('beforeend', modal); const bootstrapModal = new bootstrap.Modal(document.getElementById('shortcutOverviewModal'), { keyboard: true, backdrop: true }); hotkeys('X', 'joomla', () => bootstrapModal.show()); }; document.addEventListener('DOMContentLoaded', () => { const options = Joomla.getOptions('plg_system_shortcut.shortcuts'); Object.values(options).forEach(value => { if (!value.shortcut || !value.selector) { return; } if (value.selector.startsWith('/') || value.selector.startsWith('http://') || value.selector.startsWith('www.')) { Joomla.addLinkShortcut(value.shortcut, value.selector); } else if (value.selector.includes('input')) { Joomla.addFocusShortcut(value.shortcut, value.selector); } else { Joomla.addClickShortcut(value.shortcut, value.selector); } }); // Show hint and overview on logged in backend only (not login page) if (document.querySelector('nav')) { initOverviewModal(options); addOverviewHint(); } setShortcutFilter(); startupShortcuts(); }); })(document, Joomla); PK ���\Ԇ�� js/shortcut.min.js.gznu �[��� � �V�n7}�W���%���}�� RG�m�Dʥ�K���)rK���{��Œe�y�_�!g�g�R�:�u��6�»iba�t�w��S��F$�.O�0)�+��Y��F-��k9.��Σ�`F!ňZ8��Y����5ICֹ��p��HLR�Е�ޕ�Z�vv�v2��a{��PV�*�?2Z��0��E!�qQ:0 ��N��`@��Y+��.#��_NN�=�P�=m��T[��8YK��+V�g��nH�G� �֜0��_���]c��ޡ�>c8U�-8�6A���,#� y���m�a�"���Y�]�Q���O�/?���w{ݣ�5�~���}GXU�v�(%�$� �׀}�J���e���ۣ��4�H�ϒfuFX���gi �1� �-�7u̮/�()�0��x��� !��p�Xh�m���ҍ��L¥�(��m k�����҃@X�� 2�!��\BeF�"DI��?H�\� ߩ�B���Y��F�XER���������?�A�l�?��08�8^|�~�t�<<>9Ee V�(�1��V��r&��E�$�[a&(0>r�+dA���x�Rn>ox� �E�`"���Z��+{Ke�1�����$t��e�ui|K1Fr�=��b�!#me:��kvԧ2�,��{��C��*���0�5Έjjk��fn��!��M�:���[*y(�FJ^��+��U����r���UI���Nq�zLY�@��XZ��W�!��o+�8�d�oHD��j)^�ފb,"YfW/��/ʰ�;%L2 H�UFV�^܂��0=��$A�k��GF�oH❁�(-��&�(�yh�B�(�ʌ�%I�עiDƀ�gO����ҹ�J��� �Β�#���×T���7���c-_Җ�c~��[�����5Z�b�����٬Y?�ɠ�%�zHd�8�!�O�M�ZOƚN��)�p-��X��n�*#��N�z�ȁt����)����S��l�jZv~Y����o��A�<0䘨yؕq��å[�q��<���\��k��u5wzQ�:����p����(��{d�� �r'�:l�NW/��b�u7�B�g�ض&�bN)cUKDZ�[pO���g�i��Eҭ^�|�\�{�[`ֹk�f���|�?�szo��c����d�������<���t:儽ݙ��=��Sv���4�m� �P��ȧ`vg�'<Y�ҝQ[��hA���2� �R[���*^��Y���`�<