filesafe/dist/js/album.js.map

1 line
1.7 KiB
Plaintext

{"version":3,"sources":["album.js"],"names":["const","lsKeys","page","lazyLoad","window","addEventListener","files","document","querySelectorAll","i","length","sizeElem","querySelector","str","dataset","value","innerHTML","replace","getPrettyBytes","parseInt","dateElem","getPrettyDate","Date","LazyLoad"],"mappings":"AAGAA,IAAMC,OAAS,CAAA,EAETC,KAAO,CACXC,SAAU,MAGZC,OAAOC,iBAAiB,oBAAkB,WAIxC,IAHAL,IAAMM,EAAQC,SAASC,iBAAiB,oBAG/BC,EAAI,EAAGA,EAAIH,EAAMI,OAAQD,IAAK,CACrCT,IAAMW,EAAWL,EAAMG,GAAGG,cAAc,uBACxC,GAAID,EAAU,CACZX,IAAMa,EAAMF,EAASG,QAAQC,OAASJ,EAASK,UAAUC,QAAQ,SAAU,IAC3EN,EAASK,UAAYd,KAAKgB,eAAeC,SAASN,GACpD,CAEAb,IAAMoB,EAAWd,EAAMG,GAAGG,cAAc,uBACxC,GAAIQ,EAAU,CACZpB,IAAMa,EAAMO,EAASN,QAAQC,MAC7BK,EAASJ,UAAYd,KAAKmB,cAAc,IAAIC,KAAqB,IAAhBH,SAASN,IAC5D,CACF,CAEAX,KAAKC,SAAW,IAAIoB,QACtB","file":"album.js","sourcesContent":["/* global LazyLoad */\n\n// eslint-disable-next-line no-unused-vars\nconst lsKeys = {}\n\nconst page = {\n lazyLoad: null\n}\n\nwindow.addEventListener('DOMContentLoaded', () => {\n const files = document.querySelectorAll('.image-container')\n\n // Prettify individual file's data rows\n for (let i = 0; i < files.length; i++) {\n const sizeElem = files[i].querySelector('.details .file-size')\n if (sizeElem) {\n const str = sizeElem.dataset.value || sizeElem.innerHTML.replace(/\\s*B$/i, '')\n sizeElem.innerHTML = page.getPrettyBytes(parseInt(str))\n }\n\n const dateElem = files[i].querySelector('.details .file-date')\n if (dateElem) {\n const str = dateElem.dataset.value\n dateElem.innerHTML = page.getPrettyDate(new Date(parseInt(str) * 1000))\n }\n }\n\n page.lazyLoad = new LazyLoad()\n})\n"]}