PluginProbe
TablePress – Tables in WordPress made easy / 2.1.7
TablePress – Tables in WordPress made easy v2.1.7
3.3.4 3.3.3 3.3.2 3.3.1 trunk 1.12 1.14 1.9.2 2.0.4 2.1.7 2.1.8 2.2 2.2.1 2.2.2 2.2.3 2.2.4 2.2.5 2.3 2.3.1 2.3.2 2.4 2.4.1 2.4.2 2.4.3 2.4.4 All 44 releases
tablepress / admin / js / build / export.js

export.js in TablePress – Tables in WordPress made easy 2.1.7, at admin/js/build/export.js

1 lines 1.7 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 !function(){"use strict";var e=window.wp.i18n;const t=e=>"#"===e[0]?document.getElementById(e.slice(1)):document.querySelectorAll(e),n=t("#tables-export"),s=t("#tables-export-zip-file");if(window?.navigator?.platform?.includes("Mac")){const n=t("#tables-export-shortcut-description");n&&(n.textContent=(0,e.sprintf)((0,e.__)("You can select multiple tables by holding down the “%1$s” key or the “%2$s” key for ranges.","tablepress"),(0,e._x)("","keyboard shortcut modifier key on a Mac keyboard","tablepress"),(0,e._x)("Shift","keyboard key","tablepress")))}document.querySelector("#tablepress-page form").addEventListener("submit",(function(e){const i=[...n.selectedOptions].map((e=>e.value));0!==i.length?(t("#tables-export-list").value=i.join(),s.disabled=!1):e.preventDefault()}));const i=t("#tables-export-format");i.addEventListener("change",(function(){const e="csv"!==this.value;t("#tables-export-csv-delimiter").disabled=e,t("#tables-export-csv-delimiter-description").style.display=e?"inline":"none"})),i.dispatchEvent(new Event("change"));let o=!1;s.addEventListener("change",(function(){o=this.checked}));const c=t("#tables-export-select-all");n.addEventListener("change",(function(){const e=n.selectedOptions.length>1;s.disabled=e,s.checked=e||o,t("#tables-export-zip-file-description").style.display=e?"inline":"none",c.checked=n.options.length===n.selectedOptions.length})),n.dispatchEvent(new Event("change")),c.addEventListener("change",(function(){[...n.options].forEach((e=>e.selected=this.checked)),n.dispatchEvent(new Event("change"))})),t("#tables-export-reverse-list").addEventListener("change",(function(){[...n.children].forEach((e=>{n.prepend(e)}))}))}();