D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
home
/
everqlsh
/
www
/
wp-admin
/
user
/
577040
/
Filename :
sortable.zip
back
Copy
PK L�}\T��E E sortable.cssnu �[��� @charset "UTF-8"; #wp-optimize-wrap .sortable thead th:not(.no-sort) { cursor: pointer; } #wp-optimize-wrap .sortable thead th:not(.no-sort)::after, .sortable thead th:not(.no-sort)::before { transition: color 0.1s ease-in-out; font-size: 1.2em; color: transparent; } #wp-optimize-wrap .sortable thead th:not(.no-sort)::after { margin-left: 3px; content: ""; } #wp-optimize-wrap .sortable thead th:not(.no-sort):hover::after { color: inherit; } #wp-optimize-wrap .sortable thead th:not(.no-sort)[aria-sort=descending]::after { color: inherit; content: "▾"; } #wp-optimize-wrap .sortable thead th:not(.no-sort)[aria-sort=ascending]::after { color: inherit; content: "▴"; } #wp-optimize-wrap .sortable thead th:not(.no-sort).indicator-left::after { content: ""; } #wp-optimize-wrap .sortable thead th:not(.no-sort).indicator-left::before { margin-right: 3px; content: ""; } #wp-optimize-wrap .sortable thead th:not(.no-sort).indicator-left:hover::before { color: inherit; } #wp-optimize-wrap .sortable thead th:not(.no-sort).indicator-left[aria-sort=descending]::before { color: inherit; content: "▾"; } #wp-optimize-wrap .sortable thead th:not(.no-sort).indicator-left[aria-sort=ascending]::before { color: inherit; content: "▴"; } #wp-optimize-wrap .sortable { --th-color: #0074AB; } #wp-optimize-wrap .sortable thead th { color: var(--th-color); font-weight: normal; text-align: left; text-transform: capitalize; vertical-align: baseline; white-space: nowrap; } #wp-optimize-wrap .sortable thead th:last-child { color: inherit; }PK L�}\o��P� � sortable-4-2-2.min.cssnu �[��� @charset "UTF-8";#wp-optimize-wrap .sortable thead th:not(.no-sort){cursor:pointer}#wp-optimize-wrap .sortable thead th:not(.no-sort)::after,.sortable thead th:not(.no-sort)::before{transition:color .1s ease-in-out;font-size:1.2em;color:transparent}#wp-optimize-wrap .sortable thead th:not(.no-sort)::after{margin-left:3px;content:""}#wp-optimize-wrap .sortable thead th:not(.no-sort):hover::after{color:inherit}#wp-optimize-wrap .sortable thead th:not(.no-sort)[aria-sort=descending]::after{color:inherit;content:"▾"}#wp-optimize-wrap .sortable thead th:not(.no-sort)[aria-sort=ascending]::after{color:inherit;content:"▴"}#wp-optimize-wrap .sortable thead th:not(.no-sort).indicator-left::after{content:""}#wp-optimize-wrap .sortable thead th:not(.no-sort).indicator-left::before{margin-right:3px;content:""}#wp-optimize-wrap .sortable thead th:not(.no-sort).indicator-left:hover::before{color:inherit}#wp-optimize-wrap .sortable thead th:not(.no-sort).indicator-left[aria-sort=descending]::before{color:inherit;content:"▾"}#wp-optimize-wrap .sortable thead th:not(.no-sort).indicator-left[aria-sort=ascending]::before{color:inherit;content:"▴"}#wp-optimize-wrap .sortable{--th-color:#0074ab}#wp-optimize-wrap .sortable thead th{color:var(--th-color);font-weight:normal;text-align:left;text-transform:capitalize;vertical-align:baseline;white-space:nowrap}#wp-optimize-wrap .sortable thead th:last-child{color:inherit} /*# sourceMappingURL=sortable-4-2-2.min.css.map */ PK ~\��8� � sortable.jsnu �[��� /** * sortable v3.2.3 * * https://www.npmjs.com/package/sortable-tablesort * https://github.com/tofsjonas/sortable * * Makes html tables sortable, No longer ie9+ 😢 * * Styling is done in css. * * Copyleft 2017 Jonas Earendel * * This is free and unencumbered software released into the public domain. * * Anyone is free to copy, modify, publish, use, compile, sell, or * distribute this software, either in source code form or as a compiled * binary, for any purpose, commercial or non-commercial, and by any * means. * * In jurisdictions that recognize copyright laws, the author or authors * of this software dedicate any and all copyright interest in the * software to the public domain. We make this dedication for the benefit * of the public at large and to the detriment of our heirs and * successors. We intend this dedication to be an overt act of * relinquishment in perpetuity of all present and future rights to this * software under copyright law. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR * OTHER DEALINGS IN THE SOFTWARE. * * For more information, please refer to <http://unlicense.org> * */ document.addEventListener('click', function (e) { try { // allows for elements inside TH function findElementRecursive(element, tag) { return element.nodeName === tag ? element : findElementRecursive(element.parentNode, tag); } var ascending_table_sort_class = 'asc'; var no_sort_class = 'no-sort'; var null_last_class = 'n-last'; var table_class_name = 'sortable'; var alt_sort_1 = e.shiftKey || e.altKey; var element = findElementRecursive(e.target, 'TH'); var tr = element.parentNode; var thead = tr.parentNode; var table = thead.parentNode; function getValue(element) { var _a; var value = alt_sort_1 ? element.dataset.sortAlt : (_a = element.dataset.sort) !== null && _a !== void 0 ? _a : element.textContent; return value; } if (thead.nodeName === 'THEAD' && // sortable only triggered in `thead` table.classList.contains(table_class_name) && !element.classList.contains(no_sort_class) // .no-sort is now core functionality, no longer handled in CSS ) { var column_index_1; var nodes = tr.cells; var tiebreaker_1 = +element.dataset.sortTbr; // Reset thead cells and get column index for (var i = 0; i < nodes.length; i++) { if (nodes[i] === element) { column_index_1 = +element.dataset.sortCol || i; } else { nodes[i].setAttribute('aria-sort', 'none'); } } var direction = 'descending'; if (element.getAttribute('aria-sort') === 'descending' || (table.classList.contains(ascending_table_sort_class) && element.getAttribute('aria-sort') !== 'ascending')) { direction = 'ascending'; } // Update the `th` class accordingly element.setAttribute('aria-sort', direction); var reverse_1 = direction === 'ascending'; var sort_null_last_1 = table.classList.contains(null_last_class); var compare_1 = function (a, b, index) { var x = getValue(b.cells[index]); var y = getValue(a.cells[index]); if (sort_null_last_1) { if (x === '' && y !== '') { return -1; } if (y === '' && x !== '') { return 1; } } var temp = +x - +y; var bool = isNaN(temp) ? x.localeCompare(y) : temp; return reverse_1 ? -bool : bool; }; // loop through all tbodies and sort them for (var i = 0; i < table.tBodies.length; i++) { var org_tbody = table.tBodies[i]; // Put the array rows in an array, so we can sort them... var rows = [].slice.call(org_tbody.rows, 0); // Sort them using Array.prototype.sort() rows.sort(function (a, b) { var bool = compare_1(a, b, column_index_1); return bool === 0 && !isNaN(tiebreaker_1) ? compare_1(a, b, tiebreaker_1) : bool; }); // Make an empty clone var clone_tbody = org_tbody.cloneNode(); // Put the sorted rows inside the clone clone_tbody.append.apply(clone_tbody, rows); // And finally replace the unsorted tbody with the sorted one table.replaceChild(clone_tbody, org_tbody); } } // eslint-disable-next-line no-unused-vars } catch (error) { // console.log(error) } }); PK ~\Γt�| | sortable.min.jsnu �[��� document.addEventListener("click",function(c){try{function h(b,a){return b.nodeName===a?b:h(b.parentNode,a)}var v=c.shiftKey||c.altKey,d=h(c.target,"TH"),m=d.parentNode,n=m.parentNode,g=n.parentNode;function p(b){var a;return v?b.dataset.sortAlt:null!==(a=b.dataset.sort)&&void 0!==a?a:b.textContent}if("THEAD"===n.nodeName&&g.classList.contains("sortable")&&!d.classList.contains("no-sort")){var q,f=m.cells,r=+d.dataset.sortTbr;for(c=0;c<f.length;c++)f[c]===d?q=+d.dataset.sortCol||c:f[c].setAttribute("aria-sort", "none");f="descending";if("descending"===d.getAttribute("aria-sort")||g.classList.contains("asc")&&"ascending"!==d.getAttribute("aria-sort"))f="ascending";d.setAttribute("aria-sort",f);var w="ascending"===f,x=g.classList.contains("n-last"),t=function(b,a,e){a=p(a.cells[e]);b=p(b.cells[e]);if(x){if(""===a&&""!==b)return-1;if(""===b&&""!==a)return 1}e=+a-+b;a=isNaN(e)?a.localeCompare(b):e;return w?-a:a};for(c=0;c<g.tBodies.length;c++){var k=g.tBodies[c],u=[].slice.call(k.rows,0);u.sort(function(b,a){var e= t(b,a,q);return 0!==e||isNaN(r)?e:t(b,a,r)});var l=k.cloneNode();l.append.apply(l,u);g.replaceChild(l,k)}}}catch(h){}}); PK ~\��A> > sortable.a11y.min.jsnu �[��� var enhanceSortableAccessibility=function(g){function h(c){"Enter"===c.key&&c.target.click()}g.forEach(function(c){var k=c.classList.contains("asc")?"ascending":"";c.querySelectorAll("th").forEach(function(a){if(!a.hasAttribute("tabindex")){var e=function(){var d=k,b;void 0===d&&(d="");var l=a.textContent||"element",f=null!==(b=a.getAttribute("aria-sort"))&&void 0!==b?b:"";b="descending";if("descending"===f||d&&"ascending"!==f)b="ascending";d="Click to sort table by ".concat(l," in ").concat(b," order"); a.setAttribute("aria-label",d)};a.setAttribute("tabindex","0");e();a.addEventListener("click",function(){setTimeout(e,50)});a.addEventListener("focus",e);a.addEventListener("keydown",h)}})})};document.addEventListener("DOMContentLoaded",function(){enhanceSortableAccessibility(document.querySelectorAll(".sortable"))}); PK ~\ÿ�Z sortable.a11y.jsnu �[��� /** * This is a "plugin" for the sortable package: * https://www.npmjs.com/package/sortable-tablesort * https://github.com/tofsjonas/sortable * * Enhances the accessibility of class="sortable" tables by adding ARIA attributes and keyboard event listeners. * @param tables - A list of HTML table elements to enhance. */ var enhanceSortableAccessibility = function (tables) { /** * Generates an aria-label attribute for a table header cell based on its content and current sort direction. * @param element - The table header cell to update. * @param default_direction - The default sort direction for the table. */ function updateAriaLabel(element, default_direction) { var _a; if (default_direction === void 0) { default_direction = ''; } // Generate aria-label based on header content var header_text = element.textContent || 'element'; var current_direction = (_a = element.getAttribute('aria-sort')) !== null && _a !== void 0 ? _a : ''; var new_direction = 'descending'; if (current_direction === 'descending' || (default_direction && current_direction !== 'ascending')) { new_direction = 'ascending'; } var aria_label = "Click to sort table by ".concat(header_text, " in ").concat(new_direction, " order"); element.setAttribute('aria-label', aria_label); // element.setAttribute('title', aria_label) REMEMBER TO COMMENT OUT WHEN NOT TESTING!! } /** * Handles keyboard events on table header cells and triggers a click event when the Enter key is pressed. * @param event - The keyboard event to handle. */ function handleKeyDown(event) { if (event.key === 'Enter') { var element = event.target; element.click(); } } // Iterate over each table in the input list tables.forEach(function (table) { var default_direction = table.classList.contains('asc') ? 'ascending' : ''; var headers = table.querySelectorAll('th'); // Iterate over each header cell in the table headers.forEach(function (header) { var element = header; // Skip if the header cell already has a tabindex attribute if (element.hasAttribute('tabindex')) return; var update = function () { updateAriaLabel(element, default_direction); }; // Add tabindex attribute and generate initial aria-label attribute element.setAttribute('tabindex', '0'); update(); // Attach click event listener to update aria-label attribute element.addEventListener('click', function () { // Add a delay to allow the new sort order to be applied setTimeout(update, 50); }); // Attach focus event listener to update aria-label attribute element.addEventListener('focus', update); // Attach keyboard event listener to trigger click event element.addEventListener('keydown', handleKeyDown); }); }); }; // Attach function to DOMContentLoaded event to execute when page is loaded document.addEventListener('DOMContentLoaded', function () { enhanceSortableAccessibility(document.querySelectorAll('.sortable')); }); PK L�}\T��E E sortable.cssnu �[��� PK L�}\o��P� � � sortable-4-2-2.min.cssnu �[��� PK ~\��8� � � sortable.jsnu �[��� PK ~\Γt�| | �! sortable.min.jsnu �[��� PK ~\��A> > ~&