/*! For license information please see index.js.LICENSE.txt */
!function(){var e={92868:function(e,t,n){var r,o=o||function(e){"use strict";if("undefined"==typeof navigator||!/MSIE [1-9]\./.test(navigator.userAgent)){var t=e.document,n=function(){return e.URL||e.webkitURL||e},r=t.createElementNS("http://www.w3.org/1999/xhtml","a"),o="download"in r,i=/Version\/[\d\.]+.*Safari/.test(navigator.userAgent),a=e.webkitRequestFileSystem,c=e.requestFileSystem||a||e.mozRequestFileSystem,u=function(t){(e.setImmediate||e.setTimeout)((function(){throw t}),0)},f="application/octet-stream",l=0,d=function(e){setTimeout((function(){"string"==typeof e?n().revokeObjectURL(e):e.remove()}),4e4)},s=function(e,t,n){for(var r=(t=[].concat(t)).length;r--;){var o=e["on"+t[r]];if("function"==typeof o)try{o.call(e,n||e)}catch(e){u(e)}}},p=function(e){return/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(e.type)?new Blob(["\ufeff",e],{type:e.type}):e},v=function(t,u,v){v||(t=p(t));var w,y,m,g=this,S=t.type,b=!1,h=function(){s(g,"writestart progress write writeend".split(" "))},O=function(){if(y&&i&&"undefined"!=typeof FileReader){var r=new FileReader;return r.onloadend=function(){var e=r.result;y.location.href="data:attachment/file"+e.slice(e.search(/[,;]/)),g.readyState=g.DONE,h()},r.readAsDataURL(t),void(g.readyState=g.INIT)}!b&&w||(w=n().createObjectURL(t)),y?y.location.href=w:void 0===e.open(w,"_blank")&&i&&(e.location.href=w),g.readyState=g.DONE,h(),d(w)},R=function(e){return function(){if(g.readyState!==g.DONE)return e.apply(this,arguments)}},E={create:!0,exclusive:!1};if(g.readyState=g.INIT,u||(u="download"),o)return w=n().createObjectURL(t),void setTimeout((function(){var e,t;r.href=w,r.download=u,e=r,t=new MouseEvent("click"),e.dispatchEvent(t),h(),d(w),g.readyState=g.DONE}));e.chrome&&S&&S!==f&&(m=t.slice||t.webkitSlice,t=m.call(t,0,t.size,f),b=!0),a&&"download"!==u&&(u+=".download"),(S===f||a)&&(y=e),c?(l+=t.size,c(e.TEMPORARY,l,R((function(e){e.root.getDirectory("saved",E,R((function(e){var n=function(){e.getFile(u,E,R((function(e){e.createWriter(R((function(n){n.onwriteend=function(t){y.location.href=e.toURL(),g.readyState=g.DONE,s(g,"writeend",t),d(e)},n.onerror=function(){var e=n.error;e.code!==e.ABORT_ERR&&O()},"writestart progress write abort".split(" ").forEach((function(e){n["on"+e]=g["on"+e]})),n.write(t),g.abort=function(){n.abort(),g.readyState=g.DONE},g.readyState=g.WRITING})),O)})),O)};e.getFile(u,{create:!1},R((function(e){e.remove(),n()})),R((function(e){e.code===e.NOT_FOUND_ERR?n():O()})))})),O)})),O)):O()},w=v.prototype;return"undefined"!=typeof navigator&&navigator.msSaveOrOpenBlob?function(e,t,n){return n||(e=p(e)),navigator.msSaveOrOpenBlob(e,t||"download")}:(w.abort=function(){var e=this;e.readyState=e.DONE,s(e,"abort")},w.readyState=w.INIT=0,w.WRITING=1,w.DONE=2,w.error=w.onwritestart=w.onprogress=w.onwrite=w.onabort=w.onerror=w.onwriteend=null,function(e,t,n){return new v(e,t,n)})}}("undefined"!=typeof self&&self||"undefined"!=typeof window&&window||this.content);e.exports?e.exports.saveAs=o:null!==n.amdD&&null!==n.amdO&&(void 0===(r=function(){return o}.apply(t,[]))||(e.exports=r))}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r].call(i.exports,i,i.exports,n),i.exports}n.amdD=function(){throw new Error("define cannot be used indirect")},n.amdO={},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,{a:t}),t},n.d=function(e,t){for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};!function(){"use strict";n.r(r),n.d(r,{downloadCSVFile:function(){return l},generateCSVDataFromTable:function(){return u},generateCSVFileName:function(){return f}});var e=window.moment,t=n.n(e),o=n(92868);function i(e){let t=e.toString();return["=","+","-","@"].includes(t.charAt(0))?t='"\t'+t+'"':t.match(/[,"\s]/)&&(t='"'+t.replace(/"/g,'""')+'"'),t}function a(e){return Array.isArray(e)?e.map((e=>i(e.label))).join(","):[]}function c(e){return Array.isArray(e)?e.map((e=>e.map((e=>void 0===e.value||null===e.value?"":i(e.value))).join(","))).join("\n"):[]}function u(e,t){return[a(e),c(t)].filter((e=>e.length)).join("\n")}function f(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const r=[e.toLowerCase().replace(/[^a-z0-9]/g,"-"),t()().format("YYYY-MM-DD"),Object.keys(n).map((e=>e.toLowerCase().replace(/[^a-z0-9]/g,"-")+"-"+decodeURIComponent(n[e]).toLowerCase().replace(/[^a-z0-9]/g,"-"))).join("_")].filter((e=>e.length));return r.join("_")+".csv"}function l(e,t){const n=new Blob([t],{type:"text/csv;charset=utf-8"});(0,o.saveAs)(n,e)}}(),(window.wc=window.wc||{}).csvExport=r}();