Compass-ci
Threads by month
- ----- 2025 -----
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- 1 participants
- 5235 discussions

15 Dec '20
Signed-off-by: Wang Chenglong <18509160991(a)163.com>
---
doc/tutorial.md | 84 ++++++++++++++++++++++++++++++++-----------------
1 file changed, 55 insertions(+), 29 deletions(-)
diff --git a/doc/tutorial.md b/doc/tutorial.md
index e6f8491..88544f4 100644
--- a/doc/tutorial.md
+++ b/doc/tutorial.md
@@ -152,29 +152,34 @@ job yaml ���������������������������������������������[YAML](http://yaml.org/YAM
1. ������������ os ��������� rootfs������ openEuler ���������
- ������ docker ������ rootfs
-
+
1) ������ openEuler ��������������� docker ���������������
-
+
```bash
wget https://repo.openeuler.org/openEuler-20.03-LTS/docker_img/aarch64/openEuler…
- ```
- 2) ������ docker ������
+ ```
+ 2) ������ docker ������
```bash
docker load -i openEuler-docker.aarch64
```
- 3) ������ openEuler ������
+ 3) ������ openEuler ������
```bash
- docker run -id openeuler-20.03-lts
+ docker run -d --name initramfs-docker openeuler-20.03-lts
```
- 4) ������ docker ��� rootfs
+ 4) ������ docker ��� rootfs
```bash
- docker cp -a docker run -d openeuler-20.03-lts:/ openEuler-rootfs
+ docker cp -a initramfs-docker:/ openEuler-rootfs/
```
- - ������ qemu.img(qcow2������)������ rootfs (openEuler������)
+ {compass-ci} ������������������������ '.tar.xz' ��������� docker ������������������ rootfs ������������
+ ```bash
+ ./{compass-ci}/container/docker-rootfs/run openEuler-docker.aarch64.tar.xz /tmp/openeuler-rootfs-20.03
+ ```
- 1) ������ openEule r��������������������� qcow2 ������������
+ - ������ qemu.img(qcow2������)������ rootfs (openEuler������)
+
+ 1) ������ openEuler ��������������������� qcow2 ������������
```bash
wget https://repo.openeuler.org/openEuler-20.03-LTS/virtual_machine_img/aarch64/…
```
@@ -183,45 +188,66 @@ job yaml ���������������������������������������������[YAML](http://yaml.org/YAM
cd {compass-ci}/container/qcow2rootfs
./run openEuler-20.03-LTS.aarch64.qcow2.xz /tmp/openEuler-rootfs
```
+
2. ������rootfs
- 1. ������chroot��������������� rootfs (��������������� root ������)
+ 1. ������ chroot ��������������� rootfs (��������������� root ������)
```bash
chroot openEuler-rootfs
```
2. ���������������������������������������
a. ������ root ������
- b. ������ ssh ������
- c. ������������������
- d. ������������ docker ������ osimage ������������������������
- > 1. ������������������������
- > 2. ��� centos ������������������������rpm���
- > 3. ������ yum ������������
- > 4. ������ docker ������������������
-
- 3. ������ rootfs������������
- ```bash
- cd $rootfs
- find . | coip -o -Hnewc |gzip -9 > $os_name.cgz
- ```
+ b. ��������������� /sbin/init
+ > ���������������systemd������������
+ ```bash
+ ls -l /sbin/init
+ /sbin/init -> ../lib/systemd/systemd
+ ```
+ c. ������������ docker ������ osimage ���������������������
+ > ������ docker ������������������ /.dockerenv
+ d. ������������������
+ > openssh-server (ssh ������������������)
+ > ntpdate (������������)
+ > cifs-utils (cifs���������������������)
+ > nfs-utils (nfs���������������������)
+ > curl (���������url������)
+ ```bash
+ yum -y install openssh-server ntpdate cifs-utils nfs-utils curl
+ ```
+ e. ������������ docker ������ osimage ������������������������
+ > ������ docker ������������������ /.dockerenv
+
+ 3. ������rootfs
+ ```bash
+ cd $rootfs
+ find . | coip -o -Hnewc |gzip -9 > $os_name.cgz
+ ```
+
+ 4. ������������������/������������
+ ������������������ {compass-ci} ��������������������������� ��������� rootfs ������������������������������������������������������/���������������������������
+ ```bash
+ find /lib/modules/* | cpio -o -Hnewc | gzip -9 > /modules-$os_name.cgz
+ find /usr/src/kernels/* | cpio -o -Hnewc | gzip -9 > /headers-$os_name.cgz
+ ```
+
#### FAQ
-1. ������������ ���Unable to mount root fs on unknown-block���
+1. ������������ ���Unable to mount root fs on unknown-block���
- ������������
```bash
[ 0.390437] List of all partitions:
- [ 0.390806] No filesystem could mount root, tried:
+ [ 0.390806] No filesystem could mount root, tried:
[ 0.391489] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)
...
[ 0.399404] Memory Limit: none
[ 0.399749] ---[ end Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0) ]---
```
- ������������
-
+
1������������������������������������������������
2������������������������������������ 644 ���������
-
+
2. ������������������
-
+
- ������������
������������������������������������������������
--
2.23.0
2
4
[error]
Traceback (most recent call last):
5: from /home/lukaiyi/compass-ci/sbin/compare:72:in `<main>'
4: from /home/lukaiyi/compass-ci/lib/compare.rb:66:in `compare_group'
3: from /home/lukaiyi/compass-ci/lib/compare_matrixes.rb:389:in `compare_group_matrices'
2: from /home/lukaiyi/compass-ci/lib/compare_matrixes.rb:389:in `each'
1: from /home/lukaiyi/compass-ci/lib/compare_matrixes.rb:390:in `block in compare_group_matrices'
/home/lukaiyi/compass-ci/lib/compare_matrixes.rb:390:in `+': no implicit conversion of nil into String (TypeError)
[why]
get_matrix_str maybe return nil, if so, the line 390 will raise error like above.
386 def compare_group_matrices(group_matrices, suites_list, options)
387 result_str = ''
388 group_matrices_array = sort_by_matrix_size(group_matrices)
389 group_matrices_array.each do |matrice_kv|
390 result_str += get_matrix_str(matrice_kv[0], matrice_kv[1], suites_list, options)
391 end
392 result_str
393 end
---
lib/compare_matrixes.rb | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/compare_matrixes.rb b/lib/compare_matrixes.rb
index 0e08ec7..e8f52f1 100644
--- a/lib/compare_matrixes.rb
+++ b/lib/compare_matrixes.rb
@@ -402,6 +402,7 @@ def get_matrix_str(matrice_key, matrice_value, suites_list, options)
return compare_matrixes(m_list, suites_list.shift, m_titles, matrice_key, options: options) if options[:no_print]
print compare_matrixes(m_list, suites_list.shift, m_titles, matrice_key, options: options)
+ return ''
end
# big size first
--
2.23.0
2
1
remove h5ai link from upper right corner of result page
Signed-off-by: Lu Weitao <luweitaobe(a)163.com>
---
container/srv-http/root/srv/_h5ai/public/js/scripts.js | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/container/srv-http/root/srv/_h5ai/public/js/scripts.js b/container/srv-http/root/srv/_h5ai/public/js/scripts.js
index f4f2f84..62942b8 100755
--- a/container/srv-http/root/srv/_h5ai/public/js/scripts.js
+++ b/container/srv-http/root/srv/_h5ai/public/js/scripts.js
@@ -1028,7 +1028,7 @@
i = r.dom,
o = "body",
a =
- '<div id="topbar">\n <div id="toolbar"></div>\n <div id="flowbar"></div>\n <a id="backlink" href="https://larsjung.de/h5ai/" title="powered by h5ai - https://larsjung.de/h5ai/">\n <div>powered</div>\n <div>by h5ai</div>\n </a>\n </div>',
+ '<div id="topbar">\n <div id="toolbar"></div>\n <div id="flowbar"></div>\n </a>\n </div>',
s =
'<div id="mainrow">\n <div id="content"></div>\n </div>',
c = function() {
@@ -6274,4 +6274,4 @@
})()
));
},
-]);
\ No newline at end of file
+]);
--
2.23.0
2
3
[Why]
It's inconvenient for read and modify the file
container/srv-http/root/srv/_h5ai/public/js/script.js
because of the file had write as one line
[How]
Use the code formatter prettier format it
Signed-off-by: Lu Weitao <luweitaobe(a)163.com>
---
.../root/srv/_h5ai/public/js/scripts.js | 6282 ++++++++++++++++-
1 file changed, 6277 insertions(+), 5 deletions(-)
diff --git a/container/srv-http/root/srv/_h5ai/public/js/scripts.js b/container/srv-http/root/srv/_h5ai/public/js/scripts.js
index 664fd61..f4f2f84 100755
--- a/container/srv-http/root/srv/_h5ai/public/js/scripts.js
+++ b/container/srv-http/root/srv/_h5ai/public/js/scripts.js
@@ -1,5 +1,6277 @@
-/* h5ai v0.29.2 - https://larsjung.de/h5ai/ */
-!function(e){function t(e,t){if(!t)throw i.className=r,new Error(r+": "+e)}function n(e){return"function"==typeof e}if(!e||e.window!==e||!e.document)throw new Error("no-window");var r="no-browser",i=e.document.documentElement;i.className="",t("console",e.console&&n(e.console.log)),t("assign",e.Object&&n(e.Object.assign)),t("promise",n(e.Promise)),t("xhr",e.XMLHttpRequest)}(this),function(e){function t(r){if(n[r])return n[r].exports;var i=n[r]={exports:{},id:r,loaded:!1};return e[r].call(i.exports,i,i.exports,t),i.loaded=!0,i.exports}var n={};return t.m=e,t.c=n,t.p="",t(0)}([function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";var r=n(2),i=r.dom,o=r.awaitReady,a=n(7),s=i("script[data-module]").attr("data-module"),c={action:"get",setup:!0,options:!0,types:!0};if("index"===s)c.theme=!0,c.langs=!0;else{if("info"!==s)throw new Error("no-main-module: '"+s+"'");c.refresh=!0}a._update(c).then(function(){return o()}).then(function(){return n(9)("./"+s)})},function(e,t,n){"use strict";e.exports=Object.assign({},n(3),n(4),n(5),n(6))},function(e,t){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r=function(e){return void 0!==e&&null!==e},i=function(e,t){return("undefined"==typeof e?"undefined":n(e))===t},o=function(e){return i(e,"string")},a=function(e){return i(e,"function")},s=function(e){return i(e,"number")},c=function(e){return e&&e.hasOwnProperty("length")},u=function(e){return!e||o(e)?[]:(c(e)&&(e=Array.from(e)),Object.keys(e))},l=function(e){return u(e).map(function(t){return e[t]})},f=function(e,t){return u(e).forEach(function(n){return t(e[n],n)})},d=function(e,t){return l(e).filter(t)},p=function(e,t){return l(e).map(t)},h=function(e,t){return l(e).indexOf(t)>=0},g=function(e){return d(e,function(e){return!!e})},m=function(e,t){return!!e&&e instanceof t},v=function(e){return Array.from(e)},b=function(e,t){return t=l(t),d(e,function(e){return t.indexOf(e)<0})},w=function(e,t){return t=l(t),d(e,function(e){return t.indexOf(e)>=0})},y=function(e,t){return e<t?-1:e>t?1:0},x=function(e,t){var n=a(t)?t:function(e){return e[t]},r=function(e,t){return y(n(e),n(t))};return l(e).sort(r)},k=function(e,t){var n=null;return function(){clearTimeout(n),n=setTimeout(e,t)}};e.exports={is:r,isStr:o,isFn:a,isNum:s,hasLength:c,keys:u,values:l,each:f,filter:d,map:p,includes:h,compact:g,isInstanceOf:m,toArray:v,difference:b,intersection:w,cmp:y,sortBy:x,debounce:k}},function(e,t,n){(function(t){"use strict";function r(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}var i=function(){function e(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),o=n(3),a=o.each,s=o.filter,c=o.hasLength,u=o.is,l=o.isStr,f=o.map,d=o.isInstanceOf,p=o.toArray,h=t.window,g=h.document,m=function(){var e=function(e){return g.createElement(e)},t=[[/^<t(head|body|foot)|^<c(ap|olg)/i,e("table")],[/^<col/i,e("colgroup")],[/^<tr/i,e("tbody")],[/^<t[dh]/i,e("tr")]],n=e("div"),r=function(e){var r=!0,o=!1,a=void 0;try{for(var s,c=t[Symbol.iterator]();!(r=(s=c.next()).done);r=!0){var u=s.value,l=i(u,2),f=l[0],d=l[1];if(f.test(e))return d}}catch(e){o=!0,a=e}finally{try{!r&&c.return&&c.return()}finally{if(o)throw a}}return n};return function(e){var t=r(e);t.innerHTML=e;var n=p(t.childNodes);return a(n,function(e){return t.removeChild(e)}),t.innerHTML="",n}}(),v=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g;try{return p(t.querySelectorAll(e))}catch(e){return[]}},b=function(e){return d(e,h.Element)},w=function(e){return d(e,h.Document)},y=function(e){return u(e)&&e.window===e&&w(e.document)},x=function(e){return b(e)||w(e)||y(e)},k=function(e,t,n){return e.addEventListener(t,n)},_=function(e,t,n){return e.removeEventListener(t,n)},C=new Promise(function(e){/^(i|c|loade)/.test(g.readyState)?e():k(g,"DOMContentLoaded",function(){return e()})}),S=function(){return C},A=new Promise(function(e){k(h,"load",function(){return e()})}),T=function(){return A},E=function e(t){if(d(t,e))return t;var n=void 0;return l(t)?(t=t.trim(),n="<"===t[0]?m(t):v(t)):n=x(t)?[t]:c(t)?t:[t],n=s(n,x),Object.assign(Object.create(e.prototype),n,{length:n.length})};E.prototype={constructor:E,each:function(e){return a(this,e),this},map:function(e){return f(this,e)},find:function(e){var t;return E((t=[]).concat.apply(t,r(this.map(function(t){return v(e,t)}))))},on:function(e,t){return this.each(function(n){return k(n,e,t)})},off:function(e,t){return this.each(function(n){return _(n,e,t)})},attr:function(e,t){return void 0===t?this.length?this[0].getAttribute(e):void 0:this.each(function(n){return n.setAttribute(e,t)})},rmAttr:function(e){return this.each(function(t){return t.removeAttribute(e)})},prop:function(e,t){return void 0===t?this.length?this[0][e]:void 0:this.each(function(n){n[e]=t})},rmProp:function(e){return this.each(function(t){return delete t[e]})},val:function(e){return void 0===e?this.length?this[0].value:void 0:this.each(function(t){t.value=e})},html:function(e){return void 0===e?this.map(function(e){return e.innerHTML}).join(""):this.each(function(t){t.innerHTML=e})},text:function(e){return void 0===e?this.map(function(e){return e.textContent}).join(""):this.each(function(t){t.textContent=e})},clr:function(){return this.html("")},rm:function(){return this.each(function(e){var t=e.parentNode;t&&t.removeChild(e)})},rpl:function(e){return this.each(function(t){var n=t.parentNode;n&&n.replaceChild(E(e)[0],t)})},app:function(e){return this.each(function(t){E(e).each(function(e){return t.appendChild(e)})})},appTo:function(e){return E(e).app(this),this},pre:function(e){return this.each(function(t){E(e).each(function(e){var n=t.firstChild;n?t.insertBefore(e,n):t.appendChild(e)})})},preTo:function(e){return E(e).pre(this),this},cls:function(){return arguments.length?(this.each(function(e){e.className=""}),this.addCls.apply(this,arguments)):this.length?p(this[0].classList):[]},hasCls:function(e){return p(this).every(function(t){return t.classList.contains(e)})},addCls:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.each(function(e){var n=!0,r=!1,i=void 0;try{for(var o,a=t[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){var s=o.value;e.classList.add(s)}}catch(e){r=!0,i=e}finally{try{!n&&a.return&&a.return()}finally{if(r)throw i}}})},rmCls:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.each(function(e){var n=!0,r=!1,i=void 0;try{for(var o,a=t[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){var s=o.value;e.classList.remove(s)}}catch(e){r=!0,i=e}finally{try{!n&&a.return&&a.return()}finally{if(r)throw i}}})},tglCls:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.each(function(e){var n=!0,r=!1,i=void 0;try{for(var o,a=t[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){var s=o.value;e.classList.contains(s)?e.classList.remove(s):e.classList.add(s)}}catch(e){r=!0,i=e}finally{try{!n&&a.return&&a.return()}finally{if(r)throw i}}})},parent:function(){return E(this.map(function(e){return e.parentNode}))},children:function(){var e;return E((e=[]).concat.apply(e,r(this.map(function(e){return p(e.children)}))))},hide:function(){return this.addCls("hidden")},show:function(){return this.rmCls("hidden")},isHidden:function(){return this.hasCls("hidden")},css:function(e){return this.each(function(t){return Object.assign(t.style,e)})}},e.exports={awaitReady:S,awaitLoad:T,dom:E}}).call(t,function(){return this}())},function(e,t){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r=/(^([+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?)?$|^0x[0-9a-f]+$|\d+)/gi,i=/(^([\w ]+,?[\w ]+)?[\w ]+,?[\w ]+\d+:\d+(:\d+)?[\w ]?|^\d{1,4}[\/\-]\d{1,4}[\/\-]\d{1,4}|^\w+, \w+ \d+, \d{4})/,o=/^0x[0-9a-f]+$/i,a=/^0/,s=function(e,t){var s=String(e).trim(),c=String(t).trim(),u=s.replace(r,"\0$1\0").replace(/\0$/,"").replace(/^\0/,"").split("\0"),l=c.replace(r,"\0$1\0").replace(/\0$/,"").replace(/^\0/,"").split("\0"),f=parseInt(s.match(o),16)||1!==u.length&&s.match(i)&&Date.parse(s),d=parseInt(c.match(o),16)||f&&c.match(i)&&Date.parse(c)||null;if(d){if(f<d)return-1;if(f>d)return 1}for(var p=0,h=Math.max(u.length,l.length);p<h;p+=1){var g=!(u[p]||"").match(a)&&parseFloat(u[p])||u[p]||0,m=!(l[p]||"").match(a)&&parseFloat(l[p])||l[p]||0;if(isNaN(g)!==isNaN(m))return isNaN(g)?1:-1;if(("undefined"==typeof g?"undefined":n(g))!==("undefined"==typeof m?"undefined":n(m))&&(g=String(g),m=String(m)),g<m)return-1;if(g>m)return 1}return 0};e.exports={naturalCmp:s}},function(e,t){"use strict";var n=function(e){return e.replace(/[\-\[\]{}()*+?.,\\$\^|#\s]/g,"\\$&")},r=function(e,t){return t?"re:"===e.substr(0,3)?e.substr(3):e.trim().split(/\s+/).map(function(e){return e.split("").map(function(e){return n(e)}).join(".*?")}).join("|"):n(e)};e.exports={parsePattern:r}},function(e,t,n){"use strict";var r=n(8),i=r.request,o=e.exports={_update:function(e){return i(e).then(function(e){return Object.assign(o,e)})}}},function(e,t,n){(function(t){"use strict";var r=n(2),i=r.each,o=r.dom,a=t.window.XMLHttpRequest,s=function(e){return new Promise(function(t){var n=new a,r=function(){if(n.readyState===a.DONE)try{t(JSON.parse(n.responseText))}catch(e){t({err:e,txt:n.responseText})}};n.open("POST","?",!0),n.onreadystatechange=r,n.setRequestHeader("Content-Type","application/json;charset=utf-8"),n.send(JSON.stringify(e))})},c=function(e){var t=o('<form method="post" action="?" style="display:none;"/>');i(e,function(e,n){o('<input type="hidden"/>').attr("name",n).attr("value",e).appTo(t)}),t.appTo("body"),t[0].submit(),t.rm()};e.exports={request:s,formRequest:c}}).call(t,function(){return this}())},function(e,t,n){function r(e){return n(i(e))}function i(e){return o[e]||function(){throw new Error("Cannot find module '"+e+"'.")}()}var o={"./index":10,"./index.js":10,"./info":50,"./info.js":50};r.keys=function(){return Object.keys(o)},r.resolve=i,e.exports=r,r.id=9},function(e,t,n){(function(e){"use strict";n(11),n(24),n(25),n(26),n(27),n(29),n(30),n(31),n(32),n(34),n(36),n(37),n(44),n(45),n(46),n(47),n(48),n(49);var t=e.window.document.location.href;n(20).setLocation(t,!0)}).call(t,function(){return this}())},function(e,t,n){"use strict";var r=n(2),i=r.each,o=r.dom,a=n(12),s=n(13),c=n(14),u=n(15),l=n(17),f=n(18),d=Object.assign({modeToggle:!1},c.view),p='<div id="viewmode-settings" class="block"><h1 class="l10n-view">View</h1></div>',h='<div id="viewmode-[MODE]" class="button mode">\n <img src="'+s.image("view-[MODE]")+'" alt="viewmode-[MODE]"/>\n </div>',g='<input id="viewmode-size" type="range" min="0" max="0" value="0">',m='<div id="viewmode-toggle" class="tool">\n <img alt="viewmode"/>\n </div>',v=void 0,b=void 0,w=function(e,t){o("#viewmode-settings .mode").rmCls("active"),o("#viewmode-"+e).addCls("active"),o("#viewmode-size").val(b.indexOf(t)),"next"===d.modeToggle&&(e=v[(v.indexOf(e)+1)%v.length]),o("#viewmode-toggle img").attr("src",s.image("view-"+e))},y=function(){if(!(v.length<2&&b.length<2)){var e=o(p);if(v.length>1&&i(v,function(t){o(h.replace(/\[MODE\]/g,t)).on("click",function(){f.setMode(t)}).appTo(e)}),b.length>1){var t=b.length-1;o(g).attr("max",t).on("input",function(e){return f.setSize(b[e.target.valueAsNumber])}).on("change",function(e){return f.setSize(b[e.target.valueAsNumber])}).appTo(e)}e.appTo(u.$el)}},x=function(){var e=f.getMode(),t=(v.indexOf(e)+1)%v.length,n=v[t];f.setMode(n)},k=function(){d.modeToggle&&v.length>1&&o(m).on("click",x).appTo(l.$toolbar)},_=function(){v=f.getModes(),b=f.getSizes(),y(),k(),w(f.getMode(),f.getSize()),a.sub("view.mode.changed",w)};_()},function(e,t,n){(function(t){"use strict";var r=n(2),i=r.isStr,o=r.isFn,a=r.dom,s={},c=function(e,t){i(e)&&o(t)&&(s[e]||(s[e]=[]),s[e].push(t))},u=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];i(e)&&s[e]&&s[e].forEach(function(t){t.apply(e,n)})};a(t.window).on("resize",function(){return u("resize")}),e.exports={sub:c,pub:u}}).call(t,function(){return this}())},function(e,t,n){"use strict";var r=n(2),i=r.includes,o=n(7),a=n(14),s=a.publicHref+"images/",c=s+"ui/",u=s+"themes/",l=u+"default/",f=["file","folder","folder-page","folder-parent","ar","aud","bin","img","txt","vid","x"],d=function(e){return c+e+".svg"},p=function(e){var t=(e||"").split("-")[0],n=o.theme[e]||o.theme[t];return n?u+n:i(f,e)?l+e+".svg":i(f,t)?l+t+".svg":l+"file.svg"};e.exports={image:d,icon:p}},function(e,t,n){"use strict";var r=n(7);e.exports=Object.assign({},r.options,{publicHref:r.setup.PUBLIC_HREF,rootHref:r.setup.ROOT_HREF})},function(e,t,n){"use strict";var r=n(2),i=r.dom,o=n(13),a=n(14),s=n(16),c=n(17),u=Object.assign({disableSidebar:!1},a.view),l="sidebarIsVisible",f='<div id="sidebar"></div>',d='<div id="sidebar-toggle" class="tool">\n <img alt="sidebar"/>\n </div>',p=function(){var e=i(f).hide(),t=i(d),n=t.find("img"),r=function(r){var i=s.get(l);r&&(i=!i,s.put(l,i)),i?(t.addCls("active"),n.attr("src",o.image("back")),e.show()):(t.rmCls("active"),n.attr("src",o.image("sidebar")),e.hide())};return u.disableSidebar||(e.appTo(c.$mainrow),t.appTo(c.$toolbar).on("click",function(){return r(!0)}),r()),{$el:e}};e.exports=p()},function(e,t){(function(t){"use strict";var n=t.window.localStorage,r="_h5ai",i=function(){try{return JSON.parse(n[r])}catch(e){}return{}},o=function(e){n[r]=JSON.stringify(e)},a=function(e,t){var n=i();n[e]=t,o(n)},s=function(e){return i()[e]};e.exports={put:a,get:s}}).call(t,function(){return this}())},function(e,t,n){"use strict";var r=n(2),i=r.dom,o="body",a='<div id="topbar">\n <div id="toolbar"></div>\n <div id="flowbar"></div>\n <a id="backlink" href="https://larsjung.de/h5ai/" title="powered by h5ai - https://larsjung.de/h5ai/">\n <div>powered</div>\n <div>by h5ai</div>\n </a>\n </div>',s='<div id="mainrow">\n <div id="content"></div>\n </div>',c=function(){var e=i(o).attr("id","root").clr().app(a).app(s);return{$root:e,$topbar:e.find("#topbar"),$toolbar:e.find("#toolbar"),$flowbar:e.find("#flowbar"),$mainrow:e.find("#mainrow"),$content:e.find("#content")}};e.exports=c()},function(e,t,n){"use strict";var r=n(2),i=r.each,o=r.map,a=r.includes,s=r.intersection,c=r.dom,u=n(12),l=n(19),f=n(20),d=n(13),p=n(16),h=n(14),g=n(17),m=["details","grid","icons"],v=[20,40,60,80,100,150,200,250,300,350,400],b=Object.assign({binaryPrefix:!1,hideFolders:!1,hideParentFolder:!1,maxIconSize:40,modes:m,setParentFolderLabels:!1,sizes:v},h.view),w=b.sizes.sort(function(e,t){return e-t}),y=s(b.modes,m),x="view",k='<div id="view">\n <ul id="items" class="clearfix">\n <li class="header">\n <a class="icon"></a>\n <a class="label" href="#"><span class="l10n-name"/></a>\n <a class="date" href="#"><span class="l10n-lastModified"/></a>\n <a class="size" href="#"><span class="l10n-size"/></a>\n </li>\n </ul>\n <div id="view-hint"></div>\n </div>',_='<li class="item">\n <a>\n <span class="icon square"><img/></span>\n <span class="icon landscape"><img/></span>\n <span class="label"></span>\n <span class="date"></span>\n <span class="size"></span>\n </a>\n </li>',C=c(k),S=C.find("#items"),A=C.find("#view-hint"),T=function(e,t,n){return Math.min(n,Math.max(t,e))},E=function(e){var t=T(e,20,80),n=T(e,40,160),r=T(e,80,1e3),i=Math.round(4*r/3),o="!important;",a="#view.view-details.view-size-"+e,s="#view.view-grid.view-size-"+e,c="#view.view-icons.view-size-"+e,u=[a+" .item .label {line-height: "+(t+14)+"px "+o+"}",a+" .item .date {line-height: "+(t+14)+"px "+o+"}",a+" .item .size {line-height: "+(t+14)+"px "+o+"}",a+" .square {width: "+t+"px "+o+" height: "+t+"px "+o+"}",a+" .square img {width: "+t+"px "+o+" height: "+t+"px "+o+"}",a+" .label {margin-left: "+(t+32)+"px "+o+"}",s+" .item .label {line-height: "+n+"px "+o+"}",s+" .square {width: "+n+"px "+o+" height: "+n+"px "+o+"}",s+" .square img {width: "+n+"px "+o+" height: "+n+"px "+o+"}",c+" .item {width: "+i+"px "+o+"}",c+" .landscape {width: "+i+"px "+o+" height: "+r+"px "+o+"}",c+" .landscape img {width: "+r+"px "+o+" height: "+r+"px "+o+"}",c+" .landscape .thumb {width: "+i+"px "+o+"}"];return u.join("\n")},M=function(){var e=o(w,function(e){return E(e)});e.push("#view .icon img {max-width: "+b.maxIconSize+"px; max-height: "+b.maxIconSize+"px;}"),c("<style></style>").text(e.join("\n")).appTo("head")},D=function(e,t){var n=p.get(x);e=e||n&&n.mode,t=t||n&&n.size,e=a(b.modes,e)?e:b.modes[0],t=a(b.sizes,t)?t:b.sizes[0],p.put(x,{mode:e,size:t}),i(y,function(t){t===e?C.addCls("view-"+t):C.rmCls("view-"+t)}),i(w,function(e){e===t?C.addCls("view-size-"+e):C.rmCls("view-size-"+e)}),u.pub("view.mode.changed",e,t)},P=function(){return y},z=function(){return p.get(x).mode},L=function(e){return D(e,null)},$=function(){return w},H=function(){return p.get(x).size},O=function(e){return D(null,e)},B=function(e){var t=e.target._item;u.pub("item.mouseenter",t)},R=function(e){var t=e.target._item;u.pub("item.mouseleave",t)},N=function(e){var t=c(_),n=t.find("a"),r=t.find(".icon img"),i=t.find(".label"),o=t.find(".date"),a=t.find(".size");return t.addCls(e.isFolder()?"folder":"file").on("mouseenter",B).on("mouseleave",R),f.setLink(n,e),i.text(e.label).attr("title",e.label),o.attr("data-time",e.time).text(l.formatDate(e.time)),a.attr("data-bytes",e.size).text(l.formatSize(e.size)),e.icon=d.icon(e.type),e.isFolder()&&!e.isManaged&&(t.addCls("page"),e.icon=d.icon("folder-page")),e.isCurrentParentFolder()&&(e.icon=d.icon("folder-parent"),b.setParentFolderLabels||i.addCls("l10n-parentDirectory"),t.addCls("folder-parent")),r.attr("src",e.icon).attr("alt",e.type),e.$view=t,t[0]._item=e,t},I=function(){var e=S.find(".item").length===S.find(".folder-parent").length;e?A.show():A.hide()},j=function(e){var t=o(S.find(".item"),function(e){return e._item});S.find(".item").rm(),i(e,function(e){return S.app(N(e))}),g.$content[0].scrollLeft=0,g.$content[0].scrollTop=0,I(),u.pub("view.changed",e,t)},F=function(e,t){i(e,function(e){N(e).hide().appTo(S).show()}),i(t,function(e){e.$view.hide().rm()}),I(),u.pub("view.changed",e,t)},q=function(e){A.rmCls().addCls("l10n-"+e),I()},Y=function(e){e||(e=f.getItem());var t=[];e.parent&&!b.hideParentFolder&&t.push(e.parent),i(e.content,function(e){e.isFolder()&&b.hideFolders||t.push(e)}),q("empty"),j(t)},Z=function(e,t,n){var r=[];i(t,function(e){e.isFolder()&&b.hideFolders||r.push(e)}),q("empty"),F(r,n)},U=function(){var e=C[0].offsetWidth;C.rmCls("width-0").rmCls("width-1"),e<320?C.addCls("width-0"):e<480&&C.addCls("width-1")},V=function(){M(),D(),C.appTo(g.$content),A.hide(),l.setDefaultMetric(b.binaryPrefix),u.sub("location.changed",Y),u.sub("location.refreshed",Z),u.sub("resize",U),U()};V(),e.exports={$el:C,setItems:j,changeItems:F,setLocation:Y,setHint:q,getModes:P,getMode:z,setMode:L,getSizes:$,getSize:H,setSize:O}},function(e,t,n){"use strict";var r=n(2),i=r.isNum,o={t:1e3,k:1e3,u:["B","KB","MB","GB","TB","PB","EB","ZB","YB"]},a={t:1024,k:1024,u:["B","KiB","MiB","GiB","TiB","PiB","EiB","ZiB","YiB"]},s=o,c=[[/YYYY/,"Y",4],[/YY/,"Y",2],[/Y/,"Y",0],[/MM/,"M",2],[/M/,"M",0],[/DD/,"D",2],[/D/,"D",0],[/HH/,"H",2],[/H/,"H",0],[/mm/,"m",2],[/m/,"m",0],[/ss/,"s",2],[/s/,"s",0]],u="YYYY-MM-DD HH:mm",l=function(e){s=e?a:o},f=function(e,t){if(t=t||s,!i(e)||e<0)return"";for(var n=0,r=t.u.length-1;e>=t.t&&n<r;)e/=t.k,n+=1;return(n<=1?Math.round(e):e.toFixed(1)).toString()+" "+t.u[n]},d=function(e){u=e},p=function(e,t){var n=String(e);return t&&(n=("000"+n).substr(-t)),n},h=function(e,t){if(!e||!i(e))return"";t=t||u;var n=new Date(e),r={Y:n.getFullYear(),M:n.getMonth()+1,D:n.getDate(),H:n.getHours(),m:n.getMinutes(),s:n.getSeconds()};return c.forEach(function(e){t=t.replace(e[0],p(r[e[1]],e[2]))}),t};e.exports={setDefaultMetric:l,formatSize:f,setDefaultDateFormat:d,formatDate:h}},function(e,t,n){(function(t){"use strict";var r=n(2),i=r.each,o=r.values,a=r.difference,s=n(8),c=s.request,u=n(14),l=n(12),f=n(21),d=t.window,p=d.document,h=Object.assign({fastBrowsing:!0,unmanagedInNewWindow:!0},u.view),g=h.fastBrowsing?d.history:null,m=/^.*:\/\/[^\/]*|[^\/]*$/g,v=[[/\/+/g,"/"],[/ /g,"%20"],[/!/g,"%21"],[/#/g,"%23"],[/\$/g,"%24"],[/&/g,"%26"],[/'/g,"%27"],[/\(/g,"%28"],[/\)/g,"%29"],[/\*/g,"%2A"],[/\+/g,"%2B"],[/\,/g,"%2C"],[/:/g,"%3A"],[/;/g,"%3B"],[/\=/g,"%3D"],[/\?/g,"%3F"],[/@/g,"%40"],[/\[/g,"%5B"],[/\]/g,"%5D"]],b=null,w=function(e){return v.reduce(function(e,t){return e.replace(t[0],t[1])},e)},y=function(e){return e.replace(m,"")},x=function(){var e="/a b",t=p.createElement("a");return t.href=e,y(t.href)===e}(),k=function(e){var t=p.createElement("a"),n=void 0;return t.href=e,n=y(t.href),x&&(n=encodeURIComponent(n).replace(/%2F/gi,"/")),w(n)},_=function(){return p.domain},C=function(){return b},S=function(){return n(22).get(b)},A=function(){return c({action:"get",items:{href:b,what:1}}).then(function(e){var t=n(22),r=t.get(b);if(e){var o={};i(e.items,function(e){var n=t.get(e);o[n.absHref]=!0}),i(r.content,function(e){o[e.absHref]||t.remove(e.absHref)})}return r})},T=function(){var e=S(),t=o(e.content);l.pub("location.beforeRefresh"),A().then(function(){var n=o(e.content),r=a(n,t),i=a(t,n);l.pub("location.refreshed",e,r,i)})},E=function(e,t){l.pub("location.beforeChange"),e=k(e),b!==e&&(b=e,g&&(t?g.replaceState({absHref:b},"",b):g.pushState({absHref:b},"",b)));var n=S();n.isLoaded?(l.pub("location.changed",n),T()):(f.set("loading..."),A().then(function(){n.isLoaded=!0,f.set(),l.pub("location.changed",n)}))},M=function(e,t){e.attr("href",t.absHref),g&&t.isFolder()&&t.isManaged&&e.on("click",function(e){return E(t.absHref),e.preventDefault(),!1}),h.unmanagedInNewWindow&&!t.isManaged&&e.attr("target","_blank")},D=function(e){e.state&&e.state.absHref&&E(e.state.absHref,!0)};d.onpopstate=g?D:null,e.exports={forceEncoding:w,getDomain:_,getAbsHref:C,getItem:S,setLocation:E,refresh:T,setLink:M}}).call(t,function(){return this}())},function(e,t,n){"use strict";var r=n(2),i=r.dom,o=n(17),a=function(){var e=i('<div id="notification"></div>').hide().appTo(o.$root),t=function(t){t?e.html(t).show():e.hide()};return{set:t}};e.exports=a()},function(e,t,n){"use strict";var r=n(2),i=r.keys,o=r.each,a=r.filter,s=r.sortBy,c=r.isStr,u=r.isNum,l=n(8),f=n(20),d=n(14),p=n(23),h=/\/$/,g=/^(.*\/)([^\/]+\/?)$/,m={},v=function(e,t){return c(e)&&e.startsWith(t)},b=function(e){e=e.replace(h,"");try{e=decodeURIComponent(e)}catch(e){}return e},w=function(e){if("/"===e)return{parent:null,name:"/"};var t=g.exec(e);if(!t)return null;var n={parent:t[1],name:t[2]};return n.parent&&!v(n.parent,d.rootHref)&&(n.parent=null),n},y=function(e){if(c(e))e={href:e};else if(!e||!c(e.href))return null;var t=f.forceEncoding(e.href);if(!v(t,d.rootHref))return null;var n=m[t]||_(t);return u(e.time)&&(n.time=e.time),u(e.size)&&(n.size=e.size),e.managed&&(n.isManaged=!0),e.fetched&&(n.isContentFetched=!0),n},x=function e(t){t=f.forceEncoding(t);var n=m[t];n&&(delete m[t],n.parent&&delete n.parent.content[n.absHref],o(n.content,function(t){e(t.absHref)}))},k=function(e){return new Promise(function(t){var n=y(e);n.isContentFetched?t(n):l.request({action:"get",items:{href:n.absHref,what:1}}).then(function(e){e.items&&o(e.items,function(e){y(e)}),t(n)})})},_=function e(t){var n=w(t),r=Object.assign(Object.create(e.prototype),{absHref:t,type:p.getType(t),label:b("/"===t?f.getDomain():n.name),time:null,size:null,parent:null,isManaged:null,content:{}});return m[t]=r,n.parent&&(r.parent=y(n.parent),r.parent.content[r.absHref]=r,i(r.parent.content).length>1&&(r.parent.isContentFetched=!0)),r};_.prototype={constructor:_,isFolder:function(){return h.test(this.absHref)},isCurrentFolder:function(){return this.absHref===f.getAbsHref()},isInCurrentFolder:function(){return!!this.parent&&this.parent.isCurrentFolder()},isCurrentParentFolder:function(){var e=y(f.getAbsHref());return!!e&&this===e.parent},isDomain:function(){return"/"===this.absHref},isRoot:function(){return this.absHref===d.rootHref},isEmpty:function(){return 0===i(this.content).length},fetchContent:function(){return k(this.absHref)},getCrumb:function(){for(var e=this,t=[e];e.parent;)e=e.parent,t.unshift(e);return t},getSubfolders:function(){return s(a(this.content,function(e){return e.isFolder()}),function(e){return e.label.toLowerCase()})},getStats:function(){var e=0,t=0;o(this.content,function(n){n.isFolder()?e+=1:t+=1});for(var n=0,r=this;r.parent;)n+=1,r=r.parent;return{folders:e,files:t,depth:n}}},e.exports={get:y,remove:x}},function(e,t,n){"use strict";var r=n(2),i=r.each,o=r.map,a=n(7),s=/\/$/,c={},u=function(e){return e.replace(/[\-\[\]\/\{\}\(\)\+\?\.\\\^\$]/g,"\\$&")},l=function(e){i(e,function(e,t){var n="^("+o(e,function(e){return"("+u(e).replace(/\*/g,".*")+")"}).join("|")+")$";c[t]=new RegExp(n,"i")})},f=function(e){if(s.test(e))return"folder";var t=e.lastIndexOf("/"),n=t>=0?e.substr(t+1):e,r=void 0;return i(c,function(e,t){c[t].test(n)&&(r=t)}),r?r:"file"};l(Object.assign({},a.types)),e.exports={getType:f}},function(e,t,n){(function(e){"use strict";var t=n(12),r=n(20),i=n(14),o=e.window,a=Object.assign({enabled:!1,interval:5e3},i.autorefresh),s=null,c=function(){r.refresh()},u=function(){o.clearTimeout(s)},l=function(){o.clearTimeout(s),s=o.setTimeout(c,a.interval)},f=function(){a.enabled&&(a.interval=Math.max(1e3,a.interval),t.sub("location.beforeChange",u),t.sub("location.beforeRefresh",u),t.sub("location.changed",l),t.sub("location.refreshed",l))};f()}).call(t,function(){return this}())},function(e,t,n){"use strict";var r=n(2),i=r.each,o=r.dom,a=n(13),s=n(14),c=Object.assign({enabled:!1},s.contextmenu),u='<div id="cm-overlay"></div>',l='<div class="cm-panel"><ul></ul></div>',f='<li class="cm-sep"></li>',d='<li class="cm-entry"><span class="cm-icon"><img/></span><span class="cm-text"></span></li>',p='<li class="cm-label"><span class="cm-text"></span></li>',h=function(e){for(;!e._cmId&&e.parentNode;)e=e.parentNode;return e._cmId},g=function(e){var t=o(u),n=function(n){n.stopPropagation(),n.preventDefault();var r=h(n.target);n.target!==t[0]&&void 0===r||(t.rm(),e(r))};return t.on("contextmenu",n).on("click",n)},m=function(e){var t=o(l),n=t.find("ul"),r=void 0;return i(e,function(e){"-"===e.type?o(f).appTo(n):"l"===e.type?o(p).appTo(n).find(".cm-text").text(e.text):"e"===e.type&&(r=o(d).appTo(n),r[0]._cmId=e.id,r.find(".cm-text").text(e.text),e.icon?r.find(".cm-icon img").attr("src",a.icon(e.icon)):r.find(".cm-icon").addCls("no-icon"))}),t},v=function(e,t,n,r){var i=4;t.css({left:0,top:0,opacity:0}),e.show();var o=e[0].getBoundingClientRect(),a=t[0].getBoundingClientRect(),s=o.left,c=o.top,u=o.width,l=o.height,f=a.width,d=a.height,p=n,h=r;f>u-2*i&&(p=i,f=u-2*i),d>l-2*i&&(h=i,d=l-2*i),p<s+i&&(p=s+i),p+f>s+u-i&&(p=s+u-i-f),h<c+i&&(h=c+i),h+d>c+l-i&&(h=c+l-i-d),t.css({left:p+"px",top:h+"px",width:f+"px",height:d+"px",opacity:1})},b=function(e,t,n,r){var i=g(r),o=m(n);i.hide().app(o).appTo("body"),v(i,o,e,t)},w=function(){if(c.enabled){var e=[{type:"e",id:"e1",text:"testing context menus"},{type:"e",id:"e2",text:"another entry"},{type:"e",id:"e3",text:"one with icon",icon:"folder"},{type:"-"},{type:"e",id:"e4",text:"one with icon",icon:"x"},{type:"e",id:"e5",text:"one with icon",icon:"img"}];o("#view").on("contextmenu",function(t){t.preventDefault(),b(t.pageX,t.pageY,e)})}};w()},function(e,t,n){"use strict";var r=n(2),i=r.each,o=r.dom,a=n(12),s=n(20),c=n(13),u=n(14),l=n(17),f=Object.assign({enabled:!1},u.crumb),d='<div id="crumbbar"></div>',p='<a class="crumb">\n <img class="sep" src="'+c.image("crumb")+'" alt=">"/>\n <span class="label"></span>\n </a>',h='<img class="hint" src="'+c.icon("folder-page")+'" alt="has index page"/>',g=function(e){var t=o(p);return s.setLink(t,e),t.find(".label").text(e.label),e.isCurrentFolder()&&t.addCls("active"),e.isManaged||t.app(o(h)),e._$crumb=t,t[0]._item=e,t},m=function(e){var t=e._$crumb,n=o("#crumbbar");t&&t.parent()[0]===n[0]?(n.children().rmCls("active"),t.addCls("active")):(n.clr(),i(e.getCrumb(),function(e){n.app(g(e))}))},v=function(){f.enabled&&(o(d).appTo(l.$flowbar),a.sub("location.changed",m))};v()},function(e,t,n){"use strict";var r=n(28),i=n(2),o=i.each,a=i.dom,s=n(8),c=n(12),u=n(14),l=Object.assign({enabled:!1},u.custom),f=function(e,t){var n=a("#content-"+t);if(e&&e[t].content){var i=e[t].content;"md"===e[t].type&&(i=r(i)),n.html(i).show()}else n.hide()},d=function(e){s.request({action:"get",custom:e.absHref}).then(function(e){var t=e&&e.custom;o(["header","footer"],function(e){return f(t,e)})})},p=function(){l.enabled&&(a('<div id="content-header"></div>').hide().preTo("#content"),a('<div id="content-footer"></div>').hide().appTo("#content"),c.sub("location.changed",d))};p()},function(e,t,n){(function(t){!function(t){"use strict";function n(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||b.defaults,this.rules=w.normal,this.options.pedantic?this.rules=w.pedantic:this.options.gfm&&(this.options.tables?this.rules=w.tables:this.rules=w.gfm)}function r(e,t){if(this.options=t||b.defaults,this.links=e,this.rules=y.normal,this.renderer=this.options.renderer||new i,this.renderer.options=this.options,!this.links)throw new Error("Tokens array requires a `links` property.");this.options.pedantic?this.rules=y.pedantic:this.options.gfm&&(this.options.breaks?this.rules=y.breaks:this.rules=y.gfm)}function i(e){this.options=e||b.defaults}function o(){}function a(e){this.tokens=[],this.token=null,this.options=e||b.defaults,this.options.renderer=this.options.renderer||new i,this.renderer=this.options.renderer,this.renderer.options=this.options,this.slugger=new s}function s(){this.seen={}}function c(e,t){if(t){if(c.escapeTest.test(e))return e.replace(c.escapeReplace,function(e){return c.replacements[e]})}else if(c.escapeTestNoEncode.test(e))return e.replace(c.escapeReplaceNoEncode,function(e){return c.replacements[e]});return e}function u(e){return e.replace(/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi,function(e,t){return t=t.toLowerCase(),"colon"===t?":":"#"===t.charAt(0)?"x"===t.charAt(1)?String.fromCharCode(parseInt(t.substring(2),16)):String.fromCharCode(+t.substring(1)):""})}function l(e,t){return e=e.source||e,t=t||"",{replace:function(t,n){return n=n.source||n,n=n.replace(/(^|[^\[])\^/g,"$1"),e=e.replace(t,n),this},getRegex:function(){return new RegExp(e,t)}}}function f(e,t,n){if(e){try{var r=decodeURIComponent(u(n)).replace(/[^\w:]/g,"").toLowerCase()}catch(e){return null}if(0===r.indexOf("javascript:")||0===r.indexOf("vbscript:")||0===r.indexOf("data:"))return null}t&&!k.test(n)&&(n=d(t,n));try{n=encodeURI(n).replace(/%25/g,"%")}catch(e){return null}return n}function d(e,t){return x[" "+e]||(/^[^:]+:\/*[^\/]*$/.test(e)?x[" "+e]=e+"/":x[" "+e]=m(e,"/",!0)),e=x[" "+e],"//"===t.slice(0,2)?e.replace(/:[\s\S]*/,":")+t:"/"===t.charAt(0)?e.replace(/(:\/*[^\/]*)[\s\S]*/,"$1")+t:e+t}function p(){}function h(e){for(var t,n,r=1;r<arguments.length;r++){t=arguments[r];for(n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}return e}function g(e,t){var n=e.replace(/\|/g,function(e,t,n){for(var r=!1,i=t;--i>=0&&"\\"===n[i];)r=!r;
-return r?"|":" |"}),r=n.split(/ \|/),i=0;if(r.length>t)r.splice(t);else for(;r.length<t;)r.push("");for(;i<r.length;i++)r[i]=r[i].trim().replace(/\\\|/g,"|");return r}function m(e,t,n){if(0===e.length)return"";for(var r=0;r<e.length;){var i=e.charAt(e.length-r-1);if(i!==t||n){if(i===t||!n)break;r++}else r++}return e.substr(0,e.length-r)}function v(e,t){if(e.indexOf(t[1])===-1)return-1;for(var n=0,r=0;r<e.length;r++)if("\\"===e[r])r++;else if(e[r]===t[0])n++;else if(e[r]===t[1]&&(n--,n<0))return r;return-1}function b(e,t,r){if("undefined"==typeof e||null===e)throw new Error("marked(): input parameter is undefined or null");if("string"!=typeof e)throw new Error("marked(): input parameter is of type "+Object.prototype.toString.call(e)+", string expected");if(r||"function"==typeof t){r||(r=t,t=null),t=h({},b.defaults,t||{});var i,o,s=t.highlight,u=0;try{i=n.lex(e,t)}catch(e){return r(e)}o=i.length;var l=function(e){if(e)return t.highlight=s,r(e);var n;try{n=a.parse(i,t)}catch(t){e=t}return t.highlight=s,e?r(e):r(null,n)};if(!s||s.length<3)return l();if(delete t.highlight,!o)return l();for(;u<i.length;u++)!function(e){return"code"!==e.type?--o||l():s(e.text,e.lang,function(t,n){return t?l(t):null==n||n===e.text?--o||l():(e.text=n,e.escaped=!0,void(--o||l()))})}(i[u])}else try{return t&&(t=h({},b.defaults,t)),a.parse(n.lex(e,t),t)}catch(e){if(e.message+="\nPlease report this to https://github.com/markedjs/marked.",(t||b.defaults).silent)return"<p>An error occurred:</p><pre>"+c(e.message+"",!0)+"</pre>";throw e}}var w={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:p,hr:/^ {0,3}((?:- *){3,}|(?:_ *){3,}|(?:\* *){3,})(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/,nptable:p,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3})(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,html:"^ {0,3}(?:<(script|pre|style)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?\\?>\\n*|<![A-Z][\\s\\S]*?>\\n*|<!\\[CDATA\\[[\\s\\S]*?\\]\\]>\\n*|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:\\n{2,}|$)|<(?!script|pre|style)([a-z][\\w-]*)(?:attribute)*? */?>(?=\\h*\\n)[\\s\\S]*?(?:\\n{2,}|$)|</(?!script|pre|style)[a-z][\\w-]*\\s*>(?=\\h*\\n)[\\s\\S]*?(?:\\n{2,}|$))",def:/^ {0,3}\[(label)\]: *\n? *<?([^\s>]+)>?(?:(?: +\n? *| *\n *)(title))? *(?:\n+|$)/,table:p,lheading:/^([^\n]+)\n *(=|-){2,} *(?:\n+|$)/,paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading| {0,3}>|<\/?(?:tag)(?: +|\n|\/?>)|<(?:script|pre|style|!--))[^\n]+)*)/,text:/^[^\n]+/};w._label=/(?!\s*\])(?:\\[\[\]]|[^\[\]])+/,w._title=/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/,w.def=l(w.def).replace("label",w._label).replace("title",w._title).getRegex(),w.bullet=/(?:[*+-]|\d{1,9}\.)/,w.item=/^( *)(bull) ?[^\n]*(?:\n(?!\1bull ?)[^\n]*)*/,w.item=l(w.item,"gm").replace(/bull/g,w.bullet).getRegex(),w.list=l(w.list).replace(/bull/g,w.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+w.def.source+")").getRegex(),w._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",w._comment=/<!--(?!-?>)[\s\S]*?-->/,w.html=l(w.html,"i").replace("comment",w._comment).replace("tag",w._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),w.paragraph=l(w.paragraph).replace("hr",w.hr).replace("heading",w.heading).replace("lheading",w.lheading).replace("tag",w._tag).getRegex(),w.blockquote=l(w.blockquote).replace("paragraph",w.paragraph).getRegex(),w.normal=h({},w),w.gfm=h({},w.normal,{fences:/^ {0,3}(`{3,}|~{3,})([^`\n]*)\n(?:|([\s\S]*?)\n)(?: {0,3}\1[~`]* *(?:\n+|$)|$)/,paragraph:/^/,heading:/^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/}),w.gfm.paragraph=l(w.paragraph).replace("(?!","(?!"+w.gfm.fences.source.replace("\\1","\\2")+"|"+w.list.source.replace("\\1","\\3")+"|").getRegex(),w.tables=h({},w.gfm,{nptable:/^ *([^|\n ].*\|.*)\n *([-:]+ *\|[-| :]*)(?:\n((?:.*[^>\n ].*(?:\n|$))*)\n*|$)/,table:/^ *\|(.+)\n *\|?( *[-:]+[-| :]*)(?:\n((?: *[^>\n ].*(?:\n|$))*)\n*|$)/}),w.pedantic=h({},w.normal,{html:l("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",w._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/}),n.rules=w,n.lex=function(e,t){var r=new n(t);return r.lex(e)},n.prototype.lex=function(e){return e=e.replace(/\r\n|\r/g,"\n").replace(/\t/g," ").replace(/\u00a0/g," ").replace(/\u2424/g,"\n"),this.token(e,!0)},n.prototype.token=function(e,t){e=e.replace(/^ +$/gm,"");for(var n,r,i,o,a,s,c,u,l,f,d,p,h,v,b,y;e;)if((i=this.rules.newline.exec(e))&&(e=e.substring(i[0].length),i[0].length>1&&this.tokens.push({type:"space"})),i=this.rules.code.exec(e))e=e.substring(i[0].length),i=i[0].replace(/^ {4}/gm,""),this.tokens.push({type:"code",text:this.options.pedantic?i:m(i,"\n")});else if(i=this.rules.fences.exec(e))e=e.substring(i[0].length),this.tokens.push({type:"code",lang:i[2]?i[2].trim():i[2],text:i[3]||""});else if(i=this.rules.heading.exec(e))e=e.substring(i[0].length),this.tokens.push({type:"heading",depth:i[1].length,text:i[2]});else if(t&&(i=this.rules.nptable.exec(e))&&(s={type:"table",header:g(i[1].replace(/^ *| *\| *$/g,"")),align:i[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:i[3]?i[3].replace(/\n$/,"").split("\n"):[]},s.header.length===s.align.length)){for(e=e.substring(i[0].length),d=0;d<s.align.length;d++)/^ *-+: *$/.test(s.align[d])?s.align[d]="right":/^ *:-+: *$/.test(s.align[d])?s.align[d]="center":/^ *:-+ *$/.test(s.align[d])?s.align[d]="left":s.align[d]=null;for(d=0;d<s.cells.length;d++)s.cells[d]=g(s.cells[d],s.header.length);this.tokens.push(s)}else if(i=this.rules.hr.exec(e))e=e.substring(i[0].length),this.tokens.push({type:"hr"});else if(i=this.rules.blockquote.exec(e))e=e.substring(i[0].length),this.tokens.push({type:"blockquote_start"}),i=i[0].replace(/^ *> ?/gm,""),this.token(i,t),this.tokens.push({type:"blockquote_end"});else if(i=this.rules.list.exec(e)){for(e=e.substring(i[0].length),o=i[2],v=o.length>1,c={type:"list_start",ordered:v,start:v?+o:"",loose:!1},this.tokens.push(c),i=i[0].match(this.rules.item),u=[],n=!1,h=i.length,d=0;d<h;d++)s=i[d],f=s.length,s=s.replace(/^ *([*+-]|\d+\.) */,""),~s.indexOf("\n ")&&(f-=s.length,s=this.options.pedantic?s.replace(/^ {1,4}/gm,""):s.replace(new RegExp("^ {1,"+f+"}","gm"),"")),d!==h-1&&(a=w.bullet.exec(i[d+1])[0],(o.length>1?1===a.length:a.length>1||this.options.smartLists&&a!==o)&&(e=i.slice(d+1).join("\n")+e,d=h-1)),r=n||/\n\n(?!\s*$)/.test(s),d!==h-1&&(n="\n"===s.charAt(s.length-1),r||(r=n)),r&&(c.loose=!0),b=/^\[[ xX]\] /.test(s),y=void 0,b&&(y=" "!==s[1],s=s.replace(/^\[[ xX]\] +/,"")),l={type:"list_item_start",task:b,checked:y,loose:r},u.push(l),this.tokens.push(l),this.token(s,!1),this.tokens.push({type:"list_item_end"});if(c.loose)for(h=u.length,d=0;d<h;d++)u[d].loose=!0;this.tokens.push({type:"list_end"})}else if(i=this.rules.html.exec(e))e=e.substring(i[0].length),this.tokens.push({type:this.options.sanitize?"paragraph":"html",pre:!this.options.sanitizer&&("pre"===i[1]||"script"===i[1]||"style"===i[1]),text:i[0]});else if(t&&(i=this.rules.def.exec(e)))e=e.substring(i[0].length),i[3]&&(i[3]=i[3].substring(1,i[3].length-1)),p=i[1].toLowerCase().replace(/\s+/g," "),this.tokens.links[p]||(this.tokens.links[p]={href:i[2],title:i[3]});else if(t&&(i=this.rules.table.exec(e))&&(s={type:"table",header:g(i[1].replace(/^ *| *\| *$/g,"")),align:i[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:i[3]?i[3].replace(/(?: *\| *)?\n$/,"").split("\n"):[]},s.header.length===s.align.length)){for(e=e.substring(i[0].length),d=0;d<s.align.length;d++)/^ *-+: *$/.test(s.align[d])?s.align[d]="right":/^ *:-+: *$/.test(s.align[d])?s.align[d]="center":/^ *:-+ *$/.test(s.align[d])?s.align[d]="left":s.align[d]=null;for(d=0;d<s.cells.length;d++)s.cells[d]=g(s.cells[d].replace(/^ *\| *| *\| *$/g,""),s.header.length);this.tokens.push(s)}else if(i=this.rules.lheading.exec(e))e=e.substring(i[0].length),this.tokens.push({type:"heading",depth:"="===i[2]?1:2,text:i[1]});else if(t&&(i=this.rules.paragraph.exec(e)))e=e.substring(i[0].length),this.tokens.push({type:"paragraph",text:"\n"===i[1].charAt(i[1].length-1)?i[1].slice(0,-1):i[1]});else if(i=this.rules.text.exec(e))e=e.substring(i[0].length),this.tokens.push({type:"text",text:i[0]});else if(e)throw new Error("Infinite loop on byte: "+e.charCodeAt(0));return this.tokens};var y={escape:/^\\([!"#$%&'()*+,\-.\/:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:p,tag:"^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",link:/^!?\[(label)\]\(href(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(?!\s*\])((?:\\[\[\]]?|[^\[\]\\])+)\]/,nolink:/^!?\[(?!\s*\])((?:\[[^\[\]]*\]|\\[\[\]]|[^\[\]])*)\](?:\[\])?/,strong:/^__([^\s_])__(?!_)|^\*\*([^\s*])\*\*(?!\*)|^__([^\s][\s\S]*?[^\s])__(?!_)|^\*\*([^\s][\s\S]*?[^\s])\*\*(?!\*)/,em:/^_([^\s_])_(?!_)|^\*([^\s*"<\[])\*(?!\*)|^_([^\s][\s\S]*?[^\s_])_(?!_|[^\spunctuation])|^_([^\s_][\s\S]*?[^\s])_(?!_|[^\spunctuation])|^\*([^\s"<\[][\s\S]*?[^\s*])\*(?!\*)|^\*([^\s*"<\[][\s\S]*?[^\s])\*(?!\*)/,code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:p,text:/^(`+|[^`])[\s\S]*?(?=[\\<!\[`*]|\b_| {2,}\n|$)/};y._punctuation="!\"#$%&'()*+,\\-./:;<=>?@\\[^_{|}~",y.em=l(y.em).replace(/punctuation/g,y._punctuation).getRegex(),y._escapes=/\\([!"#$%&'()*+,\-.\/:;<=>?@\[\]\\^_`{|}~])/g,y._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,y._email=/[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,y.autolink=l(y.autolink).replace("scheme",y._scheme).replace("email",y._email).getRegex(),y._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,y.tag=l(y.tag).replace("comment",w._comment).replace("attribute",y._attribute).getRegex(),y._label=/(?:\[[^\[\]]*\]|\\[\[\]]?|`[^`]*`|[^\[\]\\])*?/,y._href=/\s*(<(?:\\[<>]?|[^\s<>\\])*>|[^\s\x00-\x1f]*)/,y._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,y.link=l(y.link).replace("label",y._label).replace("href",y._href).replace("title",y._title).getRegex(),y.reflink=l(y.reflink).replace("label",y._label).getRegex(),y.normal=h({},y),y.pedantic=h({},y.normal,{strong:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,em:/^_(?=\S)([\s\S]*?\S)_(?!_)|^\*(?=\S)([\s\S]*?\S)\*(?!\*)/,link:l(/^!?\[(label)\]\((.*?)\)/).replace("label",y._label).getRegex(),reflink:l(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",y._label).getRegex()}),y.gfm=h({},y.normal,{escape:l(y.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_~)]+(?!$))+/,del:/^~+(?=\S)([\s\S]*?\S)~+/,text:l(y.text).replace("]|","~]|").replace("|$","|https?://|ftp://|www\\.|[a-zA-Z0-9.!#$%&'*+/=?^_`{\\|}~-]+@|$").getRegex()}),y.gfm.url=l(y.gfm.url,"i").replace("email",y.gfm._extended_email).getRegex(),y.breaks=h({},y.gfm,{br:l(y.br).replace("{2,}","*").getRegex(),text:l(y.gfm.text).replace("{2,}","*").getRegex()}),r.rules=y,r.output=function(e,t,n){var i=new r(t,n);return i.output(e)},r.prototype.output=function(e){for(var t,n,i,o,a,s,u="";e;)if(a=this.rules.escape.exec(e))e=e.substring(a[0].length),u+=c(a[1]);else if(a=this.rules.tag.exec(e))!this.inLink&&/^<a /i.test(a[0])?this.inLink=!0:this.inLink&&/^<\/a>/i.test(a[0])&&(this.inLink=!1),!this.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(a[0])?this.inRawBlock=!0:this.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(a[0])&&(this.inRawBlock=!1),e=e.substring(a[0].length),u+=this.options.sanitize?this.options.sanitizer?this.options.sanitizer(a[0]):c(a[0]):a[0];else if(a=this.rules.link.exec(e)){var l=v(a[2],"()");if(l>-1){var f=a[2].length-l;a[2]=a[2].substring(0,l),a[0]=a[0].substring(0,a[0].length-f)}e=e.substring(a[0].length),this.inLink=!0,i=a[2],this.options.pedantic?(t=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(i),t?(i=t[1],o=t[3]):o=""):o=a[3]?a[3].slice(1,-1):"",i=i.trim().replace(/^<([\s\S]*)>$/,"$1"),u+=this.outputLink(a,{href:r.escapes(i),title:r.escapes(o)}),this.inLink=!1}else if((a=this.rules.reflink.exec(e))||(a=this.rules.nolink.exec(e))){if(e=e.substring(a[0].length),t=(a[2]||a[1]).replace(/\s+/g," "),t=this.links[t.toLowerCase()],!t||!t.href){u+=a[0].charAt(0),e=a[0].substring(1)+e;continue}this.inLink=!0,u+=this.outputLink(a,t),this.inLink=!1}else if(a=this.rules.strong.exec(e))e=e.substring(a[0].length),u+=this.renderer.strong(this.output(a[4]||a[3]||a[2]||a[1]));else if(a=this.rules.em.exec(e))e=e.substring(a[0].length),u+=this.renderer.em(this.output(a[6]||a[5]||a[4]||a[3]||a[2]||a[1]));else if(a=this.rules.code.exec(e))e=e.substring(a[0].length),u+=this.renderer.codespan(c(a[2].trim(),!0));else if(a=this.rules.br.exec(e))e=e.substring(a[0].length),u+=this.renderer.br();else if(a=this.rules.del.exec(e))e=e.substring(a[0].length),u+=this.renderer.del(this.output(a[1]));else if(a=this.rules.autolink.exec(e))e=e.substring(a[0].length),"@"===a[2]?(n=c(this.mangle(a[1])),i="mailto:"+n):(n=c(a[1]),i=n),u+=this.renderer.link(i,null,n);else if(this.inLink||!(a=this.rules.url.exec(e))){if(a=this.rules.text.exec(e))e=e.substring(a[0].length),u+=this.inRawBlock?this.renderer.text(a[0]):this.renderer.text(c(this.smartypants(a[0])));else if(e)throw new Error("Infinite loop on byte: "+e.charCodeAt(0))}else{if("@"===a[2])n=c(a[0]),i="mailto:"+n;else{do s=a[0],a[0]=this.rules._backpedal.exec(a[0])[0];while(s!==a[0]);n=c(a[0]),i="www."===a[1]?"http://"+n:n}e=e.substring(a[0].length),u+=this.renderer.link(i,null,n)}return u},r.escapes=function(e){return e?e.replace(r.rules._escapes,"$1"):e},r.prototype.outputLink=function(e,t){var n=t.href,r=t.title?c(t.title):null;return"!"!==e[0].charAt(0)?this.renderer.link(n,r,this.output(e[1])):this.renderer.image(n,r,c(e[1]))},r.prototype.smartypants=function(e){return this.options.smartypants?e.replace(/---/g,"—").replace(/--/g,"–").replace(/(^|[-\u2014\/(\[{"\s])'/g,"$1‘").replace(/'/g,"’").replace(/(^|[-\u2014\/(\[{\u2018\s])"/g,"$1“").replace(/"/g,"”").replace(/\.{3}/g,"…"):e},r.prototype.mangle=function(e){if(!this.options.mangle)return e;for(var t,n="",r=e.length,i=0;i<r;i++)t=e.charCodeAt(i),Math.random()>.5&&(t="x"+t.toString(16)),n+="&#"+t+";";return n},i.prototype.code=function(e,t,n){var r=(t||"").match(/\S*/)[0];if(this.options.highlight){var i=this.options.highlight(e,r);null!=i&&i!==e&&(n=!0,e=i)}return r?'<pre><code class="'+this.options.langPrefix+c(r,!0)+'">'+(n?e:c(e,!0))+"</code></pre>\n":"<pre><code>"+(n?e:c(e,!0))+"</code></pre>"},i.prototype.blockquote=function(e){return"<blockquote>\n"+e+"</blockquote>\n"},i.prototype.html=function(e){return e},i.prototype.heading=function(e,t,n,r){return this.options.headerIds?"<h"+t+' id="'+this.options.headerPrefix+r.slug(n)+'">'+e+"</h"+t+">\n":"<h"+t+">"+e+"</h"+t+">\n"},i.prototype.hr=function(){return this.options.xhtml?"<hr/>\n":"<hr>\n"},i.prototype.list=function(e,t,n){var r=t?"ol":"ul",i=t&&1!==n?' start="'+n+'"':"";return"<"+r+i+">\n"+e+"</"+r+">\n"},i.prototype.listitem=function(e){return"<li>"+e+"</li>\n"},i.prototype.checkbox=function(e){return"<input "+(e?'checked="" ':"")+'disabled="" type="checkbox"'+(this.options.xhtml?" /":"")+"> "},i.prototype.paragraph=function(e){return"<p>"+e+"</p>\n"},i.prototype.table=function(e,t){return t&&(t="<tbody>"+t+"</tbody>"),"<table>\n<thead>\n"+e+"</thead>\n"+t+"</table>\n"},i.prototype.tablerow=function(e){return"<tr>\n"+e+"</tr>\n"},i.prototype.tablecell=function(e,t){var n=t.header?"th":"td",r=t.align?"<"+n+' align="'+t.align+'">':"<"+n+">";return r+e+"</"+n+">\n"},i.prototype.strong=function(e){return"<strong>"+e+"</strong>"},i.prototype.em=function(e){return"<em>"+e+"</em>"},i.prototype.codespan=function(e){return"<code>"+e+"</code>"},i.prototype.br=function(){return this.options.xhtml?"<br/>":"<br>"},i.prototype.del=function(e){return"<del>"+e+"</del>"},i.prototype.link=function(e,t,n){if(e=f(this.options.sanitize,this.options.baseUrl,e),null===e)return n;var r='<a href="'+c(e)+'"';return t&&(r+=' title="'+t+'"'),r+=">"+n+"</a>"},i.prototype.image=function(e,t,n){if(e=f(this.options.sanitize,this.options.baseUrl,e),null===e)return n;var r='<img src="'+e+'" alt="'+n+'"';return t&&(r+=' title="'+t+'"'),r+=this.options.xhtml?"/>":">"},i.prototype.text=function(e){return e},o.prototype.strong=o.prototype.em=o.prototype.codespan=o.prototype.del=o.prototype.text=function(e){return e},o.prototype.link=o.prototype.image=function(e,t,n){return""+n},o.prototype.br=function(){return""},a.parse=function(e,t){var n=new a(t);return n.parse(e)},a.prototype.parse=function(e){this.inline=new r(e.links,this.options),this.inlineText=new r(e.links,h({},this.options,{renderer:new o})),this.tokens=e.reverse();for(var t="";this.next();)t+=this.tok();return t},a.prototype.next=function(){return this.token=this.tokens.pop()},a.prototype.peek=function(){return this.tokens[this.tokens.length-1]||0},a.prototype.parseText=function(){for(var e=this.token.text;"text"===this.peek().type;)e+="\n"+this.next().text;return this.inline.output(e)},a.prototype.tok=function(){switch(this.token.type){case"space":return"";case"hr":return this.renderer.hr();case"heading":return this.renderer.heading(this.inline.output(this.token.text),this.token.depth,u(this.inlineText.output(this.token.text)),this.slugger);case"code":return this.renderer.code(this.token.text,this.token.lang,this.token.escaped);case"table":var e,t,n,r,i="",o="";for(n="",e=0;e<this.token.header.length;e++)n+=this.renderer.tablecell(this.inline.output(this.token.header[e]),{header:!0,align:this.token.align[e]});for(i+=this.renderer.tablerow(n),e=0;e<this.token.cells.length;e++){for(t=this.token.cells[e],n="",r=0;r<t.length;r++)n+=this.renderer.tablecell(this.inline.output(t[r]),{header:!1,align:this.token.align[r]});o+=this.renderer.tablerow(n)}return this.renderer.table(i,o);case"blockquote_start":for(o="";"blockquote_end"!==this.next().type;)o+=this.tok();return this.renderer.blockquote(o);case"list_start":o="";for(var a=this.token.ordered,s=this.token.start;"list_end"!==this.next().type;)o+=this.tok();return this.renderer.list(o,a,s);case"list_item_start":o="";var c=this.token.loose;for(this.token.task&&(o+=this.renderer.checkbox(this.token.checked));"list_item_end"!==this.next().type;)o+=c||"text"!==this.token.type?this.tok():this.parseText();return this.renderer.listitem(o);case"html":return this.renderer.html(this.token.text);case"paragraph":return this.renderer.paragraph(this.inline.output(this.token.text));case"text":return this.renderer.paragraph(this.parseText());default:var l='Token with "'+this.token.type+'" type was not found.';if(!this.options.silent)throw new Error(l);console.log(l)}},s.prototype.slug=function(e){var t=e.toLowerCase().trim().replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,.\/:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-");if(this.seen.hasOwnProperty(t)){var n=t;do this.seen[n]++,t=n+"-"+this.seen[n];while(this.seen.hasOwnProperty(t))}return this.seen[t]=0,t},c.escapeTest=/[&<>"']/,c.escapeReplace=/[&<>"']/g,c.replacements={"&":"&","<":"<",">":">",'"':""","'":"'"},c.escapeTestNoEncode=/[<>"']|&(?!#?\w+;)/,c.escapeReplaceNoEncode=/[<>"']|&(?!#?\w+;)/g;var x={},k=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;p.exec=p,b.options=b.setOptions=function(e){return h(b.defaults,e),b},b.getDefaults=function(){return{baseUrl:null,breaks:!1,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:new i,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,tables:!0,xhtml:!1}},b.defaults=b.getDefaults(),b.Parser=a,b.parser=a.parse,b.Renderer=i,b.TextRenderer=o,b.Lexer=n,b.lexer=n.lex,b.InlineLexer=r,b.inlineLexer=r.output,b.Slugger=s,b.parse=b,e.exports=b}(this||("undefined"!=typeof window?window:t))}).call(t,function(){return this}())},function(e,t,n){"use strict";var r=n(2),i=r.each,o=r.dom,a=n(8),s=n(12),c=n(20),u=n(13),l=n(14),f=Object.assign({enabled:!1,type:"php-tar",packageName:"package",alwaysVisible:!1},l.download),d='<div id="download" class="tool">\n <img src="'+u.image("download")+'" alt="download"/>\n </div>',p=[],h=void 0,g=function(e){p=e.slice(0),p.length?h.show():f.alwaysVisible||h.hide()},m=function(){var e=f.type,t=f.packageName,n="shell-zip"===e?"zip":"tar";t||(t=1===p.length?p[0].label:c.getItem().label);var r={action:"download",as:t+"."+n,type:e,baseHref:c.getAbsHref(),hrefs:""};i(p,function(e,t){r["hrefs["+t+"]"]=e.absHref}),a.formRequest(r)},v=function(){f.enabled&&(h=o(d).hide().appTo("#toolbar").on("click",m),f.alwaysVisible&&h.show(),s.sub("selection",g))};v()},function(e,t,n){"use strict";var r=n(2),i=r.filter,o=r.debounce,a=r.parsePattern,s=r.dom,c=n(12),u=n(20),l=n(13),f=n(14),d=n(18),p=Object.assign({enabled:!1,advanced:!1,debounceTime:100,ignorecase:!0},f.filter),h='<div id="filter" class="tool">\n <img src="'+l.image("filter")+'" alt="filter"/>\n <input class="l10n_ph-filter" type="text" value=""/>\n </div>',g=!1,m="",v=void 0,b=void 0,w=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";if(e!==m){if(m=e,!e)return void d.setLocation();v.addCls("pending");var t=new RegExp(e,p.ignorecase?"i":""),n=i(u.getItem().content,function(e){return t.test(e.label)});v.rmCls("pending"),d.setHint("noMatch"),d.setItems(n)}},y=function(){g?(v.addCls("active"),b[0].focus(),w(a(b.val(),p.advanced))):(w(),v.rmCls("active"))},x=function(){g=!g,y()},k=function(){g=!1,b.val(""),y()},_=function(){p.enabled&&(v=s(h).appTo("#toolbar"),b=v.find("input"),v.find("img").on("click",x),b.on("keyup",o(y,p.debounceTime)),c.sub("location.changed",k))};_()},function(e,t,n){(function(e){"use strict";var t=n(2),r=t.map,i=n(12),o=n(14),a=e.window,s=Object.assign({enabled:!1,id:"UA-000000-0"},o["google-analytics-ua"]),c=function(){!function(e,t,n,r,i,o,a){e.GoogleAnalyticsObject=i,e[i]=e[i]||function(){(e[i].q=e[i].q||[]).push(arguments)},e[i].l=1*new Date,o=t.createElement(n),a=t.getElementsByTagName(n)[0],o.async=1,o.src=r,a.parentNode.insertBefore(o,a)}(window,document,"script","//www.google-analytics.com/analytics.js","ga")},u=function(){s.enabled&&(c(),a.ga("create",s.id,"auto"),i.sub("location.changed",function(e){var t=a.location;a.ga("send","pageview",{location:t.protocol+"//"+t.host+e.absHref,title:r(e.getCrumb(),function(e){return e.label}).join(" > ")})}))};u()}).call(t,function(){return this}())},function(e,t,n){(function(e){"use strict";var t=n(33),r=n(2),i=r.isNum,o=r.dom,a=n(12),s=n(19),c=n(13),u=n(14),l=n(16),f=Object.assign({enabled:!1,show:!1,qrcode:!0,qrColor:"#999"},u.info),d='<div id="info">\n <div class="icon"><img/></div>\n <div class="block">\n <div class="label"></div>\n <div class="time"></div>\n <div class="size"></div>\n <div class="content">\n <span class="folders"></span> <span class="l10n-folders"></span>,\n <span class="files"></span> <span class="l10n-files"></span>\n </div>\n </div>\n <div class="qrcode"/>\n </div>',p='<div class="block">\n <h1 class="l10n-info">Info</h1>\n <div id="view-info" class="button view">\n <img src="'+c.image("info-toggle")+'" alt="view-info"/>\n </div>\n </div>',h="ext/info",g=void 0,m=void 0,v=void 0,b=void 0,w=void 0,y=void 0,x=void 0,k=void 0,_=void 0,C=function(){l.get(h)?(o("#view-info").addCls("active"),o("#info").show()):(o("#view-info").rmCls("active"),o("#info").hide())},S=function(n){var r=n.thumbRational||n.icon,o=!!n.thumbRational;if(!n.isCurrentFolder()&&r||(r=c.icon("folder")),g.attr("src",r),o?g.addCls("thumb"):g.rmCls("thumb"),m.text(n.label),i(n.time)?v.text(s.formatDate(n.time)):v.text("."),i(n.size)?(b.text(s.formatSize(n.size)),b.show()):b.hide(),n.isContentFetched){var a=n.getStats();y.text(a.folders),x.text(a.files),w.show()}else w.hide();if(f.qrcode){var u=e.window.location;k.clr().app(t({render:"image",size:200,fill:f.qrFill,back:f.qrBack,text:u.protocol+"//"+u.host+n.absHref,crisp:!0,quiet:1}))}},A=function(e){S(e)},T=function(){S(_)},E=function(e){_=e,S(_)},M=function(){if(f.enabled){var e=o(d).hide().appTo("#mainrow");g=e.find(".icon img"),m=e.find(".label"),v=e.find(".time"),b=e.find(".size"),w=e.find(".content"),y=e.find(".folders"),x=e.find(".files"),k=e.find(".qrcode"),f.qrcode||k.rm(),o(p).appTo("#sidebar").find("#view-info").on("click",function(e){l.put(h,!l.get(h)),C(),a.pub("resize"),e.preventDefault()}),"boolean"!=typeof l.get(h)&&l.put(h,f.show),C(),a.sub("location.changed",E),a.sub("item.mouseenter",A),a.sub("item.mouseleave",T)}};M()}).call(t,function(){return this}())},function(e,t,n){var r,i,o;!function(t,n){e.exports=n()}(this,function(){return function(e){function t(r){if(n[r])return n[r].exports;var i=n[r]={exports:{},id:r,loaded:!1};return e[r].call(i.exports,i,i.exports,t),i.loaded=!0,i.exports}var n={};return t.m=e,t.c=n,t.p="",t(0)}([function(e,t,n){"use strict";var r=n(1),i=r.create_canvas,o=r.canvas_to_img,a=r.dpr,s=n(2),c=n(3),u=n(4);e.exports=function(e){var t=Object.assign({},s,e),n=c(t.text,t.ecLevel,t.minVersion,t.quiet),r=t.ratio||a,l=i(t.size,r),f=l.getContext("2d");return f.scale(r,r),u(n,f,t),"image"===t.render?o(l):l}},function(e,t){"use strict";var n=window,r=n.document,i=n.devicePixelRatio||1,o=function(e){return r.createElement(e)},a=function(e,t){return e.getAttribute(t)},s=function(e,t,n){return e.setAttribute(t,n)},c=function(e,t){var n=o("canvas");return s(n,"width",e*t),s(n,"height",e*t),n.style.width=e+"px",n.style.height=e+"px",n},u=function(e){var t=o("img");return s(t,"crossorigin","anonymous"),s(t,"src",e.toDataURL("image/png")),s(t,"width",a(e,"width")),s(t,"height",a(e,"height")),t.style.width=e.style.width,t.style.height=e.style.height,t};e.exports={create_canvas:c,canvas_to_img:u,dpr:i}},function(e,t){"use strict";e.exports={render:"image",crisp:!0,minVersion:1,ecLevel:"L",size:200,ratio:null,fill:"#333",back:"#fff",text:"no text",rounded:0,quiet:0,mode:"plain",mSize:30,mPosX:50,mPosY:50,label:"no label",fontname:"sans",fontcolor:"#333",image:null}},function(n,a){"use strict";var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c=/code length overflow/i,u=function(){var n=function(){function e(t,n){if("undefined"==typeof t.length)throw new Error(t.length+"/"+n);var r=function(){for(var e=0;e<t.length&&0==t[e];)e+=1;for(var r=new Array(t.length-e+n),i=0;i<t.length-e;i+=1)r[i]=t[i+e];return r}(),i={};return i.getAt=function(e){return r[e]},i.getLength=function(){return r.length},i.multiply=function(t){for(var n=new Array(i.getLength()+t.getLength()-1),r=0;r<i.getLength();r+=1)for(var o=0;o<t.getLength();o+=1)n[r+o]^=a.gexp(a.glog(i.getAt(r))+a.glog(t.getAt(o)));return e(n,0)},i.mod=function(t){if(i.getLength()-t.getLength()<0)return i;for(var n=a.glog(i.getAt(0))-a.glog(t.getAt(0)),r=new Array(i.getLength()),o=0;o<i.getLength();o+=1)r[o]=i.getAt(o);for(var o=0;o<t.getLength();o+=1)r[o]^=a.gexp(a.glog(t.getAt(o))+n);return e(r,0).mod(t)},i}var t=function(t,n){var i=236,a=17,l=t,f=r[n],d=null,p=0,g=null,m=new Array,v={},b=function(e,t){p=4*l+17,d=function(e){for(var t=new Array(e),n=0;n<e;n+=1){t[n]=new Array(e);for(var r=0;r<e;r+=1)t[n][r]=null}return t}(p),w(0,0),w(p-7,0),w(0,p-7),k(),x(),C(e,t),l>=7&&_(e),null==g&&(g=T(l,f,m)),S(g,t)},w=function(e,t){for(var n=-1;n<=7;n+=1)if(!(e+n<=-1||p<=e+n))for(var r=-1;r<=7;r+=1)t+r<=-1||p<=t+r||(0<=n&&n<=6&&(0==r||6==r)||0<=r&&r<=6&&(0==n||6==n)||2<=n&&n<=4&&2<=r&&r<=4?d[e+n][t+r]=!0:d[e+n][t+r]=!1)},y=function(){for(var e=0,t=0,n=0;n<8;n+=1){b(!0,n);var r=o.getLostPoint(v);(0==n||e>r)&&(e=r,t=n)}return t},x=function(){for(var e=8;e<p-8;e+=1)null==d[e][6]&&(d[e][6]=e%2==0);for(var t=8;t<p-8;t+=1)null==d[6][t]&&(d[6][t]=t%2==0)},k=function(){for(var e=o.getPatternPosition(l),t=0;t<e.length;t+=1)for(var n=0;n<e.length;n+=1){var r=e[t],i=e[n];if(null==d[r][i])for(var a=-2;a<=2;a+=1)for(var s=-2;s<=2;s+=1)a==-2||2==a||s==-2||2==s||0==a&&0==s?d[r+a][i+s]=!0:d[r+a][i+s]=!1}},_=function(e){for(var t=o.getBCHTypeNumber(l),n=0;n<18;n+=1){var r=!e&&1==(t>>n&1);d[Math.floor(n/3)][n%3+p-8-3]=r}for(var n=0;n<18;n+=1){var r=!e&&1==(t>>n&1);d[n%3+p-8-3][Math.floor(n/3)]=r}},C=function(e,t){for(var n=f<<3|t,r=o.getBCHTypeInfo(n),i=0;i<15;i+=1){var a=!e&&1==(r>>i&1);i<6?d[i][8]=a:i<8?d[i+1][8]=a:d[p-15+i][8]=a}for(var i=0;i<15;i+=1){var a=!e&&1==(r>>i&1);i<8?d[8][p-i-1]=a:i<9?d[8][15-i-1+1]=a:d[8][15-i-1]=a}d[p-8][8]=!e},S=function(e,t){for(var n=-1,r=p-1,i=7,a=0,s=o.getMaskFunction(t),c=p-1;c>0;c-=2)for(6==c&&(c-=1);;){for(var u=0;u<2;u+=1)if(null==d[r][c-u]){var l=!1;a<e.length&&(l=1==(e[a]>>>i&1));var f=s(r,c-u);f&&(l=!l),d[r][c-u]=l,i-=1,i==-1&&(a+=1,i=7)}if(r+=n,r<0||p<=r){r-=n,n=-n;break}}},A=function(t,n){for(var r=0,i=0,a=0,s=new Array(n.length),c=new Array(n.length),u=0;u<n.length;u+=1){var l=n[u].dataCount,f=n[u].totalCount-l;i=Math.max(i,l),a=Math.max(a,f),s[u]=new Array(l);for(var d=0;d<s[u].length;d+=1)s[u][d]=255&t.getBuffer()[d+r];r+=l;var p=o.getErrorCorrectPolynomial(f),h=e(s[u],p.getLength()-1),g=h.mod(p);c[u]=new Array(p.getLength()-1);for(var d=0;d<c[u].length;d+=1){var m=d+g.getLength()-c[u].length;c[u][d]=m>=0?g.getAt(m):0}}for(var v=0,d=0;d<n.length;d+=1)v+=n[d].totalCount;for(var b=new Array(v),w=0,d=0;d<i;d+=1)for(var u=0;u<n.length;u+=1)d<s[u].length&&(b[w]=s[u][d],w+=1);for(var d=0;d<a;d+=1)for(var u=0;u<n.length;u+=1)d<c[u].length&&(b[w]=c[u][d],w+=1);return b},T=function(e,t,n){for(var r=s.getRSBlocks(e,t),u=c(),l=0;l<n.length;l+=1){var f=n[l];u.put(f.getMode(),4),u.put(f.getLength(),o.getLengthInBits(f.getMode(),e)),f.write(u)}for(var d=0,l=0;l<r.length;l+=1)d+=r[l].dataCount;if(u.getLengthInBits()>8*d)throw new Error("code length overflow. ("+u.getLengthInBits()+">"+8*d+")");for(u.getLengthInBits()+4<=8*d&&u.put(0,4);u.getLengthInBits()%8!=0;)u.putBit(!1);for(;!(u.getLengthInBits()>=8*d)&&(u.put(i,8),!(u.getLengthInBits()>=8*d));)u.put(a,8);return A(u,r)};return v.addData=function(e){var t=u(e);m.push(t),g=null},v.isDark=function(e,t){if(e<0||p<=e||t<0||p<=t)throw new Error(e+","+t);return d[e][t]},v.getModuleCount=function(){return p},v.make=function(){b(!1,y())},v.createTableTag=function(e,t){e=e||2,t="undefined"==typeof t?4*e:t;var n="";n+='<table style="',n+=" border-width: 0px; border-style: none;",n+=" border-collapse: collapse;",n+=" padding: 0px; margin: "+t+"px;",n+='">',n+="<tbody>";for(var r=0;r<v.getModuleCount();r+=1){n+="<tr>";for(var i=0;i<v.getModuleCount();i+=1)n+='<td style="',n+=" border-width: 0px; border-style: none;",n+=" border-collapse: collapse;",n+=" padding: 0px; margin: 0px;",n+=" width: "+e+"px;",n+=" height: "+e+"px;",n+=" background-color: ",n+=v.isDark(r,i)?"#000000":"#ffffff",n+=";",n+='"/>';n+="</tr>"}return n+="</tbody>",n+="</table>"},v.createImgTag=function(e,t){e=e||2,t="undefined"==typeof t?4*e:t;var n=v.getModuleCount()*e+2*t,r=t,i=n-t;return h(n,n,function(t,n){if(r<=t&&t<i&&r<=n&&n<i){var o=Math.floor((t-r)/e),a=Math.floor((n-r)/e);
-return v.isDark(a,o)?0:1}return 1})},v};t.stringToBytes=function(e){for(var t=new Array,n=0;n<e.length;n+=1){var r=e.charCodeAt(n);t.push(255&r)}return t},t.createStringToBytes=function(e,t){var n=function(){for(var n=d(e),r=function(){var e=n.read();if(e==-1)throw new Error;return e},i=0,o={};;){var a=n.read();if(a==-1)break;var s=r(),c=r(),u=r(),l=String.fromCharCode(a<<8|s),f=c<<8|u;o[l]=f,i+=1}if(i!=t)throw new Error(i+" != "+t);return o}(),r="?".charCodeAt(0);return function(e){for(var t=new Array,i=0;i<e.length;i+=1){var o=e.charCodeAt(i);if(o<128)t.push(o);else{var a=n[e.charAt(i)];"number"==typeof a?(255&a)==a?t.push(a):(t.push(a>>>8),t.push(255&a)):t.push(r)}}return t}};var n={MODE_NUMBER:1,MODE_ALPHA_NUM:2,MODE_8BIT_BYTE:4,MODE_KANJI:8},r={L:1,M:0,Q:3,H:2},i={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7},o=function(){var t=[[],[6,18],[6,22],[6,26],[6,30],[6,34],[6,22,38],[6,24,42],[6,26,46],[6,28,50],[6,30,54],[6,32,58],[6,34,62],[6,26,46,66],[6,26,48,70],[6,26,50,74],[6,30,54,78],[6,30,56,82],[6,30,58,86],[6,34,62,90],[6,28,50,72,94],[6,26,50,74,98],[6,30,54,78,102],[6,28,54,80,106],[6,32,58,84,110],[6,30,58,86,114],[6,34,62,90,118],[6,26,50,74,98,122],[6,30,54,78,102,126],[6,26,52,78,104,130],[6,30,56,82,108,134],[6,34,60,86,112,138],[6,30,58,86,114,142],[6,34,62,90,118,146],[6,30,54,78,102,126,150],[6,24,50,76,102,128,154],[6,28,54,80,106,132,158],[6,32,58,84,110,136,162],[6,26,54,82,110,138,166],[6,30,58,86,114,142,170]],r=1335,o=7973,s=21522,c={},u=function(e){for(var t=0;0!=e;)t+=1,e>>>=1;return t};return c.getBCHTypeInfo=function(e){for(var t=e<<10;u(t)-u(r)>=0;)t^=r<<u(t)-u(r);return(e<<10|t)^s},c.getBCHTypeNumber=function(e){for(var t=e<<12;u(t)-u(o)>=0;)t^=o<<u(t)-u(o);return e<<12|t},c.getPatternPosition=function(e){return t[e-1]},c.getMaskFunction=function(e){switch(e){case i.PATTERN000:return function(e,t){return(e+t)%2==0};case i.PATTERN001:return function(e,t){return e%2==0};case i.PATTERN010:return function(e,t){return t%3==0};case i.PATTERN011:return function(e,t){return(e+t)%3==0};case i.PATTERN100:return function(e,t){return(Math.floor(e/2)+Math.floor(t/3))%2==0};case i.PATTERN101:return function(e,t){return e*t%2+e*t%3==0};case i.PATTERN110:return function(e,t){return(e*t%2+e*t%3)%2==0};case i.PATTERN111:return function(e,t){return(e*t%3+(e+t)%2)%2==0};default:throw new Error("bad maskPattern:"+e)}},c.getErrorCorrectPolynomial=function(t){for(var n=e([1],0),r=0;r<t;r+=1)n=n.multiply(e([1,a.gexp(r)],0));return n},c.getLengthInBits=function(e,t){if(1<=t&&t<10)switch(e){case n.MODE_NUMBER:return 10;case n.MODE_ALPHA_NUM:return 9;case n.MODE_8BIT_BYTE:return 8;case n.MODE_KANJI:return 8;default:throw new Error("mode:"+e)}else if(t<27)switch(e){case n.MODE_NUMBER:return 12;case n.MODE_ALPHA_NUM:return 11;case n.MODE_8BIT_BYTE:return 16;case n.MODE_KANJI:return 10;default:throw new Error("mode:"+e)}else{if(!(t<41))throw new Error("type:"+t);switch(e){case n.MODE_NUMBER:return 14;case n.MODE_ALPHA_NUM:return 13;case n.MODE_8BIT_BYTE:return 16;case n.MODE_KANJI:return 12;default:throw new Error("mode:"+e)}}},c.getLostPoint=function(e){for(var t=e.getModuleCount(),n=0,r=0;r<t;r+=1)for(var i=0;i<t;i+=1){for(var o=0,a=e.isDark(r,i),s=-1;s<=1;s+=1)if(!(r+s<0||t<=r+s))for(var c=-1;c<=1;c+=1)i+c<0||t<=i+c||0==s&&0==c||a==e.isDark(r+s,i+c)&&(o+=1);o>5&&(n+=3+o-5)}for(var r=0;r<t-1;r+=1)for(var i=0;i<t-1;i+=1){var u=0;e.isDark(r,i)&&(u+=1),e.isDark(r+1,i)&&(u+=1),e.isDark(r,i+1)&&(u+=1),e.isDark(r+1,i+1)&&(u+=1),0!=u&&4!=u||(n+=3)}for(var r=0;r<t;r+=1)for(var i=0;i<t-6;i+=1)e.isDark(r,i)&&!e.isDark(r,i+1)&&e.isDark(r,i+2)&&e.isDark(r,i+3)&&e.isDark(r,i+4)&&!e.isDark(r,i+5)&&e.isDark(r,i+6)&&(n+=40);for(var i=0;i<t;i+=1)for(var r=0;r<t-6;r+=1)e.isDark(r,i)&&!e.isDark(r+1,i)&&e.isDark(r+2,i)&&e.isDark(r+3,i)&&e.isDark(r+4,i)&&!e.isDark(r+5,i)&&e.isDark(r+6,i)&&(n+=40);for(var l=0,i=0;i<t;i+=1)for(var r=0;r<t;r+=1)e.isDark(r,i)&&(l+=1);var f=Math.abs(100*l/t/t-50)/5;return n+=10*f},c}(),a=function(){for(var e=new Array(256),t=new Array(256),n=0;n<8;n+=1)e[n]=1<<n;for(var n=8;n<256;n+=1)e[n]=e[n-4]^e[n-5]^e[n-6]^e[n-8];for(var n=0;n<255;n+=1)t[e[n]]=n;var r={};return r.glog=function(e){if(e<1)throw new Error("glog("+e+")");return t[e]},r.gexp=function(t){for(;t<0;)t+=255;for(;t>=256;)t-=255;return e[t]},r}(),s=function(){var e=[[1,26,19],[1,26,16],[1,26,13],[1,26,9],[1,44,34],[1,44,28],[1,44,22],[1,44,16],[1,70,55],[1,70,44],[2,35,17],[2,35,13],[1,100,80],[2,50,32],[2,50,24],[4,25,9],[1,134,108],[2,67,43],[2,33,15,2,34,16],[2,33,11,2,34,12],[2,86,68],[4,43,27],[4,43,19],[4,43,15],[2,98,78],[4,49,31],[2,32,14,4,33,15],[4,39,13,1,40,14],[2,121,97],[2,60,38,2,61,39],[4,40,18,2,41,19],[4,40,14,2,41,15],[2,146,116],[3,58,36,2,59,37],[4,36,16,4,37,17],[4,36,12,4,37,13],[2,86,68,2,87,69],[4,69,43,1,70,44],[6,43,19,2,44,20],[6,43,15,2,44,16],[4,101,81],[1,80,50,4,81,51],[4,50,22,4,51,23],[3,36,12,8,37,13],[2,116,92,2,117,93],[6,58,36,2,59,37],[4,46,20,6,47,21],[7,42,14,4,43,15],[4,133,107],[8,59,37,1,60,38],[8,44,20,4,45,21],[12,33,11,4,34,12],[3,145,115,1,146,116],[4,64,40,5,65,41],[11,36,16,5,37,17],[11,36,12,5,37,13],[5,109,87,1,110,88],[5,65,41,5,66,42],[5,54,24,7,55,25],[11,36,12,7,37,13],[5,122,98,1,123,99],[7,73,45,3,74,46],[15,43,19,2,44,20],[3,45,15,13,46,16],[1,135,107,5,136,108],[10,74,46,1,75,47],[1,50,22,15,51,23],[2,42,14,17,43,15],[5,150,120,1,151,121],[9,69,43,4,70,44],[17,50,22,1,51,23],[2,42,14,19,43,15],[3,141,113,4,142,114],[3,70,44,11,71,45],[17,47,21,4,48,22],[9,39,13,16,40,14],[3,135,107,5,136,108],[3,67,41,13,68,42],[15,54,24,5,55,25],[15,43,15,10,44,16],[4,144,116,4,145,117],[17,68,42],[17,50,22,6,51,23],[19,46,16,6,47,17],[2,139,111,7,140,112],[17,74,46],[7,54,24,16,55,25],[34,37,13],[4,151,121,5,152,122],[4,75,47,14,76,48],[11,54,24,14,55,25],[16,45,15,14,46,16],[6,147,117,4,148,118],[6,73,45,14,74,46],[11,54,24,16,55,25],[30,46,16,2,47,17],[8,132,106,4,133,107],[8,75,47,13,76,48],[7,54,24,22,55,25],[22,45,15,13,46,16],[10,142,114,2,143,115],[19,74,46,4,75,47],[28,50,22,6,51,23],[33,46,16,4,47,17],[8,152,122,4,153,123],[22,73,45,3,74,46],[8,53,23,26,54,24],[12,45,15,28,46,16],[3,147,117,10,148,118],[3,73,45,23,74,46],[4,54,24,31,55,25],[11,45,15,31,46,16],[7,146,116,7,147,117],[21,73,45,7,74,46],[1,53,23,37,54,24],[19,45,15,26,46,16],[5,145,115,10,146,116],[19,75,47,10,76,48],[15,54,24,25,55,25],[23,45,15,25,46,16],[13,145,115,3,146,116],[2,74,46,29,75,47],[42,54,24,1,55,25],[23,45,15,28,46,16],[17,145,115],[10,74,46,23,75,47],[10,54,24,35,55,25],[19,45,15,35,46,16],[17,145,115,1,146,116],[14,74,46,21,75,47],[29,54,24,19,55,25],[11,45,15,46,46,16],[13,145,115,6,146,116],[14,74,46,23,75,47],[44,54,24,7,55,25],[59,46,16,1,47,17],[12,151,121,7,152,122],[12,75,47,26,76,48],[39,54,24,14,55,25],[22,45,15,41,46,16],[6,151,121,14,152,122],[6,75,47,34,76,48],[46,54,24,10,55,25],[2,45,15,64,46,16],[17,152,122,4,153,123],[29,74,46,14,75,47],[49,54,24,10,55,25],[24,45,15,46,46,16],[4,152,122,18,153,123],[13,74,46,32,75,47],[48,54,24,14,55,25],[42,45,15,32,46,16],[20,147,117,4,148,118],[40,75,47,7,76,48],[43,54,24,22,55,25],[10,45,15,67,46,16],[19,148,118,6,149,119],[18,75,47,31,76,48],[34,54,24,34,55,25],[20,45,15,61,46,16]],t=function(e,t){var n={};return n.totalCount=e,n.dataCount=t,n},n={},i=function(t,n){switch(n){case r.L:return e[4*(t-1)+0];case r.M:return e[4*(t-1)+1];case r.Q:return e[4*(t-1)+2];case r.H:return e[4*(t-1)+3];default:return}};return n.getRSBlocks=function(e,n){var r=i(e,n);if("undefined"==typeof r)throw new Error("bad rs block @ typeNumber:"+e+"/errorCorrectLevel:"+n);for(var o=r.length/3,a=new Array,s=0;s<o;s+=1)for(var c=r[3*s+0],u=r[3*s+1],l=r[3*s+2],f=0;f<c;f+=1)a.push(t(u,l));return a},n}(),c=function(){var e=new Array,t=0,n={};return n.getBuffer=function(){return e},n.getAt=function(t){var n=Math.floor(t/8);return 1==(e[n]>>>7-t%8&1)},n.put=function(e,t){for(var r=0;r<t;r+=1)n.putBit(1==(e>>>t-r-1&1))},n.getLengthInBits=function(){return t},n.putBit=function(n){var r=Math.floor(t/8);e.length<=r&&e.push(0),n&&(e[r]|=128>>>t%8),t+=1},n},u=function(e){var r=n.MODE_8BIT_BYTE,i=t.stringToBytes(e),o={};return o.getMode=function(){return r},o.getLength=function(e){return i.length},o.write=function(e){for(var t=0;t<i.length;t+=1)e.put(i[t],8)},o},l=function(){var e=new Array,t={};return t.writeByte=function(t){e.push(255&t)},t.writeShort=function(e){t.writeByte(e),t.writeByte(e>>>8)},t.writeBytes=function(e,n,r){n=n||0,r=r||e.length;for(var i=0;i<r;i+=1)t.writeByte(e[i+n])},t.writeString=function(e){for(var n=0;n<e.length;n+=1)t.writeByte(e.charCodeAt(n))},t.toByteArray=function(){return e},t.toString=function(){var t="";t+="[";for(var n=0;n<e.length;n+=1)n>0&&(t+=","),t+=e[n];return t+="]"},t},f=function(){var e=0,t=0,n=0,r="",i={},o=function(e){r+=String.fromCharCode(a(63&e))},a=function(e){if(e<0);else{if(e<26)return 65+e;if(e<52)return 97+(e-26);if(e<62)return 48+(e-52);if(62==e)return 43;if(63==e)return 47}throw new Error("n:"+e)};return i.writeByte=function(r){for(e=e<<8|255&r,t+=8,n+=1;t>=6;)o(e>>>t-6),t-=6},i.flush=function(){if(t>0&&(o(e<<6-t),e=0,t=0),n%3!=0)for(var i=3-n%3,a=0;a<i;a+=1)r+="="},i.toString=function(){return r},i},d=function(e){var t=e,n=0,r=0,i=0,o={};o.read=function(){for(;i<8;){if(n>=t.length){if(0==i)return-1;throw new Error("unexpected end of file./"+i)}var e=t.charAt(n);if(n+=1,"="==e)return i=0,-1;e.match(/^\s$/)||(r=r<<6|a(e.charCodeAt(0)),i+=6)}var o=r>>>i-8&255;return i-=8,o};var a=function(e){if(65<=e&&e<=90)return e-65;if(97<=e&&e<=122)return e-97+26;if(48<=e&&e<=57)return e-48+52;if(43==e)return 62;if(47==e)return 63;throw new Error("c:"+e)};return o},p=function(e,t){var n=e,r=t,i=new Array(e*t),o={};o.setPixel=function(e,t,r){i[t*n+e]=r},o.write=function(e){e.writeString("GIF87a"),e.writeShort(n),e.writeShort(r),e.writeByte(128),e.writeByte(0),e.writeByte(0),e.writeByte(0),e.writeByte(0),e.writeByte(0),e.writeByte(255),e.writeByte(255),e.writeByte(255),e.writeString(","),e.writeShort(0),e.writeShort(0),e.writeShort(n),e.writeShort(r),e.writeByte(0);var t=2,i=s(t);e.writeByte(t);for(var o=0;i.length-o>255;)e.writeByte(255),e.writeBytes(i,o,255),o+=255;e.writeByte(i.length-o),e.writeBytes(i,o,i.length-o),e.writeByte(0),e.writeString(";")};var a=function(e){var t=e,n=0,r=0,i={};return i.write=function(e,i){if(e>>>i!=0)throw new Error("length over");for(;n+i>=8;)t.writeByte(255&(e<<n|r)),i-=8-n,e>>>=8-n,r=0,n=0;r|=e<<n,n+=i},i.flush=function(){n>0&&t.writeByte(r)},i},s=function(e){for(var t=1<<e,n=(1<<e)+1,r=e+1,o=c(),s=0;s<t;s+=1)o.add(String.fromCharCode(s));o.add(String.fromCharCode(t)),o.add(String.fromCharCode(n));var u=l(),f=a(u);f.write(t,r);var d=0,p=String.fromCharCode(i[d]);for(d+=1;d<i.length;){var h=String.fromCharCode(i[d]);d+=1,o.contains(p+h)?p+=h:(f.write(o.indexOf(p),r),o.size()<4095&&(o.size()==1<<r&&(r+=1),o.add(p+h)),p=h)}return f.write(o.indexOf(p),r),f.write(n,r),f.flush(),u.toByteArray()},c=function(){var e={},t=0,n={};return n.add=function(r){if(n.contains(r))throw new Error("dup key:"+r);e[r]=t,t+=1},n.size=function(){return t},n.indexOf=function(t){return e[t]},n.contains=function(t){return"undefined"!=typeof e[t]},n};return o},h=function(e,t,n,r){for(var i=p(e,t),o=0;o<t;o+=1)for(var a=0;a<e;a+=1)i.setPixel(a,o,n(a,o));var s=l();i.write(s);for(var c=f(),u=s.toByteArray(),d=0;d<u.length;d+=1)c.writeByte(u[d]);c.flush();var h="";return h+="<img",h+=' src="',h+="data:image/gif;base64,",h+=c,h+='"',h+=' width="',h+=e,h+='"',h+=' height="',h+=t,h+='"',r&&(h+=' alt="',h+=r,h+='"'),h+="/>"};return t}();return function(n){i=[],r=n,o="function"==typeof r?r.apply(t,i):r,!(void 0!==o&&(e.exports=o))}(function(){return n}),!function(e){e.stringToBytes=function(e){function t(e){for(var t=[],n=0;n<e.length;n++){var r=e.charCodeAt(n);r<128?t.push(r):r<2048?t.push(192|r>>6,128|63&r):r<55296||r>=57344?t.push(224|r>>12,128|r>>6&63,128|63&r):(n++,r=65536+((1023&r)<<10|1023&e.charCodeAt(n)),t.push(240|r>>18,128|r>>12&63,128|r>>6&63,128|63&r))}return t}return t(e)}}(n),n}(),l=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;n=Math.max(1,n);for(var r=n;r<=40;r+=1)try{var i=function(){var n=u(r,t);n.addData(e),n.make();var i=n.getModuleCount(),o=function(e,t){return e>=0&&e<i&&t>=0&&t<i&&n.isDark(e,t)};return{v:{text:e,level:t,version:r,moduleCount:i,isDark:o}}}();if("object"===("undefined"==typeof i?"undefined":s(i)))return i.v}catch(e){if(!(r<40&&c.test(e.message)))throw e}return null},f=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"L",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,i=l(e,t,n);if(i){var o=i.isDark;i.moduleCount+=2*r,i.isDark=function(e,t){return o(e-r,t-r)}}return i};n.exports=f},function(e,t,n){"use strict";var r=n(5),i=n(6),o=function(e,t){e.fillStyle=t.back,e.fillRect(0,0,t.size,t.size)},a=function(e,t,n,r,i,o){e.isDark(i,o)&&t.rect(o*r,i*r,r,r)},s=function(e,t,n){if(e){var i=n.rounded>0&&n.rounded<=100?r:a,o=e.moduleCount,s=n.size/o,c=0;n.crisp&&(s=Math.floor(s),c=Math.floor((n.size-s*o)/2)),t.translate(c,c),t.beginPath();for(var u=0;u<o;u+=1)for(var l=0;l<o;l+=1)i(e,t,n,s,u,l);t.fillStyle=n.fill,t.fill(),t.translate(-c,-c)}},c=function(e,t,n){o(t,n),s(e,t,n),i(t,n)};e.exports=c},function(e,t){"use strict";var n=function(e){return{c:e,m:function(){var e;return(e=this.c).moveTo.apply(e,arguments),this},l:function(){var e;return(e=this.c).lineTo.apply(e,arguments),this},a:function(){var e;return(e=this.c).arcTo.apply(e,arguments),this}}},r=function(e,t,n,r,i,o,a,s,c,u){a?e.m(t+o,n):e.m(t,n),s?e.l(r-o,n).a(r,n,r,i,o):e.l(r,n),c?e.l(r,i-o).a(r,i,t,i,o):e.l(r,i),u?e.l(t+o,i).a(t,i,t,n,o):e.l(t,i),a?e.l(t,n+o).a(t,n,r,n,o):e.l(t,n)},i=function(e,t,n,r,i,o,a,s,c,u){a&&e.m(t+o,n).l(t,n).l(t,n+o).a(t,n,t+o,n,o),s&&e.m(r-o,n).l(r,n).l(r,n+o).a(r,n,r-o,n,o),c&&e.m(r-o,i).l(r,i).l(r,i-o).a(r,i,r-o,i,o),u&&e.m(t+o,i).l(t,i).l(t,i-o).a(t,i,t+o,i,o)},o=function(e,t,o,a,s,c){var u=c*a,l=s*a,f=u+a,d=l+a,p=.005*o.rounded*a,h=e.isDark,g=s-1,m=s+1,v=c-1,b=c+1,w=h(s,c),y=h(g,v),x=h(g,c),k=h(g,b),_=h(s,b),C=h(m,b),S=h(m,c),A=h(m,v),T=h(s,v);t=n(t),w?r(t,u,l,f,d,p,!x&&!T,!x&&!_,!S&&!_,!S&&!T):i(t,u,l,f,d,p,x&&T&&y,x&&_&&k,S&&_&&C,S&&T&&A)};e.exports=o},function(e,t){"use strict";var n=function(e,t){var n=t.size,r="bold "+.01*t.mSize*n+"px "+t.fontname;e.strokeStyle=t.back,e.lineWidth=.01*t.mSize*n*.1,e.fillStyle=t.fontcolor,e.font=r;var i=e.measureText(t.label).width,o=.01*t.mSize,a=i/n,s=(1-a)*t.mPosX*.01,c=(1-o)*t.mPosY*.01,u=s*n,l=c*n+.75*t.mSize*.01*n;e.strokeText(t.label,u,l),e.fillText(t.label,u,l)},r=function(e,t){var n=t.size,r=t.image.naturalWidth||1,i=t.image.naturalHeight||1,o=.01*t.mSize,a=o*r/i,s=(1-a)*t.mPosX*.01,c=(1-o)*t.mPosY*.01,u=s*n,l=c*n,f=a*n,d=o*n;e.draw_image(t.image,u,l,f,d)},i=function(e,t){var i=t.mode;"label"===i?n(e,t):"image"===i&&r(e,t)};e.exports=i}])})},function(e,t,n){(function(e){"use strict";var t=n(2),r=t.each,i=t.isStr,o=t.dom,a=n(8),s=n(12),c=n(19),u=n(35),l=n(14),f=n(16),d=e.window,p=Object.assign({enabled:!1,lang:"en",useBrowserLang:!0},l.l10n),h={isoCode:"en",lang:"english",dateFormat:"YYYY-MM-DD HH:mm",details:"details",download:"download",empty:"empty",files:"files",filter:"filter",folders:"folders",grid:"grid",icons:"icons",language:"Language",lastModified:"Last modified",name:"Name",noMatch:"no match",parentDirectory:"Parent Directory",search:"search",size:"Size",tree:"Tree",view:"View"},g='<div class="block">\n <h1 class="l10n-language">Language</h1>\n <div class="select">\n <select id="langs"/>\n </div>\n </div>',m="<option/>",v="ext/l10n",b={en:Object.assign({},h)},w=b.en,y=function(e){e&&(w=e);var t="selected";o("#langs option").rmAttr(t).rmProp(t),o("#langs ."+w.isoCode).attr(t,"").prop(t,!0),r(w,function(e,t){o(".l10n-"+t).text(e),o(".l10n_ph-"+t).attr("placeholder",e)}),c.setDefaultDateFormat(w.dateFormat),o("#items .item").each(function(e){o(e).find(".date").text(c.formatDate(e._item.time))})},x=function(e){return b[e]?Promise.resolve(b[e]):a.request({action:"get",l10n:[e]}).then(function(t){return b[e]=Object.assign({},h,t.l10n&&t.l10n[e],{isoCode:e}),b[e]})},k=function(e,t,n){var r=f.get(v);if(e[r])t=r;else if(n){var i=d.navigator.language||d.navigator.browserLanguage;i&&(e[i]?t=i:i.length>2&&e[i.substr(0,2)]&&(t=i.substr(0,2)))}e[t]||(t="en"),x(t).then(y)},_=function(e){var t=o(g),n=t.find("select").on("change",function(t){var n=t.target.value;f.put(v,n),k(e,n,!1)});r(e,function(e,t){o(m).attr("value",t).addCls(t).text(t+" - "+(i(e)?e:e.lang)).appTo(n)}),t.appTo("#sidebar")},C=function(){p.enabled&&_(u),s.sub("view.changed",function(){k(u,p.lang,p.useBrowserLang)})};C()}).call(t,function(){return this}())},function(e,t,n){"use strict";var r=n(7),i=r.langs;e.exports=Object.assign({},i)},function(e,t,n){(function(e){"use strict";var t=n(2),r=t.dom,i=t.awaitLoad,o=n(12),a=n(14),s=e.window,c=Object.assign({enabled:!1,baseURL:"not-set",idSite:0},a["piwik-analytics"]),u=function(){if(c.enabled){var e=("https:"===s.location.protocol?"https://":"http://")+c.baseURL+"/",t=[],n=null;r("<script></script>").attr("src",e+"piwik.js").appTo("body"),i().then(function(){if(n=s.Piwik&&s.Piwik.getTracker(e+"piwik.php",c.idSite))for(n.enableLinkTracking();t.length;)n.trackPageView(t.shift())}),o.sub("location.changed",function(e){var r=e.getCrumb().map(function(e){return e.label}).join(" > ");n?n.trackPageView(r):t.push(r)})}};u()}).call(t,function(){return this}())},function(e,t,n){"use strict";n(38),n(39),n(40),n(41),n(43)},function(e,t,n){(function(t){"use strict";var r=n(2),i=r.each,o=r.isFn,a=r.dom,s=r.includes,c=r.compact,u=n(12),l=n(13),f=n(14),d=n(16),p=t.window,h=Object.assign({enabled:!0},f.preview),g='<div id="pv-overlay">\n <div id="pv-container"></div>\n <div id="pv-spinner"><img class="back"/><img class="spinner" src="'+l.image("spinner")+'"/></div>\n <div id="pv-prev-area" class="hof"><img src="'+l.image("preview-prev")+'"/></div>\n <div id="pv-next-area" class="hof"><img src="'+l.image("preview-next")+'"/></div>\n <div id="pv-bottombar" class="clearfix hof">\n <ul id="pv-buttons">\n <li id="pv-bar-close" class="bar-right bar-button"><img src="'+l.image("preview-close")+'"/></li>\n <li id="pv-bar-raw" class="bar-right"><a class="bar-button" target="_blank"><img src="'+l.image("preview-raw")+'"/></a></li>\n <li id="pv-bar-fullscreen" class="bar-right bar-button"><img src="'+l.image("preview-fullscreen")+'"/></li>\n <li id="pv-bar-next" class="bar-right bar-button"><img src="'+l.image("preview-next")+'"/></li>\n <li id="pv-bar-idx" class="bar-right bar-label"></li>\n <li id="pv-bar-prev" class="bar-right bar-button"><img src="'+l.image("preview-prev")+'"/></li>\n </ul>\n </div>\n </div>',m="ext/preview",v=d.get(m)||!1,b=null,w=!1,y=null,x=null,k=function(){var e=a("#pv-container"),t=e[0],n=e.children()[0];if(t&&n){var r=t.offsetWidth,i=t.offsetHeight,o=n.offsetWidth,s=n.offsetHeight;a(n).css({left:.5*(r-o)+"px",top:.5*(i-s)+"px"})}},_=function(){var e=p.document.documentElement,t=e.clientWidth,n=e.clientHeight,r=v?0:20,i=v?0:48;a("#pv-container").css({width:t-2*r+"px",height:n-2*r-i+"px",left:r+"px",top:r+"px"}),a("#pv-spinner").css({left:.5*t+"px",top:.5*n+"px"}),v?(a("#pv-overlay").addCls("fullscreen"),a("#pv-bar-fullscreen").find("img").attr("src",l.image("preview-no-fullscreen"))):(a("#pv-overlay").rmCls("fullscreen"),a("#pv-bar-fullscreen").find("img").attr("src",l.image("preview-fullscreen"))),k(),o(x&&x.adjust)&&x.adjust()},C=function(e,t){a("#pv-bar-idx").text(e+"/"+t).show()},S=function(e){a("#pv-bar-raw").show().find("a").attr("href",e)},A=function(e){a("#pv-buttons .bar-left").rm(),i(e,function(e){a("<li></li>").addCls("bar-left").addCls("bar-label").text(e).appTo("#pv-buttons")})},T=function(){var e=a("#pv-overlay .hof");p.clearTimeout(b),e.show(),v&&(b=p.setTimeout(function(){return e.hide()},2e3))},E=function(){return x&&x.moveIdx(1)},M=function(){return x&&x.moveIdx(-1)},D=function(){v=!v,d.put(m,v),T(),_()},P=function(e){e.stopPropagation(),e.preventDefault()},z=function(e){var t=e.keyCode;27===t?(P(e),$()):8===t||37===t?(P(e),M()):13===t||32===t||39===t?(P(e),E()):70===t&&(P(e),D())},L=function(){A([]),a("#pv-container").clr(),a("#pv-overlay").show(),a(p).on("keydown",z),_()},$=function(){A([]),a("#pv-container").clr(),a("#pv-overlay").hide(),a(p).off("keydown",z)},H=function e(t,n,r){p.clearTimeout(y);var i=a("#pv-spinner");if(!t)return w=!1,void i.hide();if(!w&&r)return void(y=p.setTimeout(function(){return e(!0,n)},r));var o=i.find(".back");n?o.attr("src",n).show():o.hide(),w=!0,i.show()},O=function e(t,n,r,i){var o=Object.assign(Object.create(e.prototype),{items:t,load:r,adjust:i});return o.setIdx(n),o};O.prototype={setIdx:function(e){var t=this;this.idx=(e+this.items.length)%this.items.length,this.item=this.items[this.idx],C(this.idx+1,this.items.length),S(this.item.absHref),A([this.item.label]);var n=this.item;Promise.resolve().then(function(){i(a("#pv-container *"),function(e){"function"==typeof e.unload&&e.unload()}),a("#pv-container").hide().clr(),H(!0,n.thumbSquare||n.icon,200)}).then(function(){return t.load(n)}).then(function(e){n===t.item&&(a("#pv-container").clr().app(e).show(),H(!1),_())})},moveIdx:function(e){this.setIdx(this.idx+e)}};var B=function(e,t,n){var r=function(r){r.$view&&s(e,r.type)&&r.$view.find("a").on("click",function(i){i.preventDefault();var o=c(a("#items .item").map(function(t){var n=t._item;return s(e,n.type)?n:null}));x=O(o,o.indexOf(r),t,n),L()})};u.sub("view.changed",function(e){return i(e,r)})},R=function(){h.enabled&&(a(g).hide().appTo("body").on("keydown",z).on("mousemove",T).on("mousedown",T).on("click",function(e){"pv-overlay"!==e.target.id&&"pv-container"!==e.target.id||$()}).on("mousedown",P).on("mousemove",P).on("keydown",P).on("keypress",P),a("#pv-spinner").hide(),a("#pv-bar-prev, #pv-prev-area").on("click",M),a("#pv-bar-next, #pv-next-area").on("click",E),a("#pv-bar-close").on("click",$),a("#pv-bar-fullscreen").on("click",D),a(p).on("resize",_).on("load",_))};e.exports={setLabels:A,register:B,get item(){return x&&x.item}},R()}).call(t,function(){return this}())},function(e,t,n){"use strict";var r=n(2),i=r.dom,o=n(19),a=n(14),s=n(38),c=Object.assign({enabled:!1,autoplay:!0,types:[]},a["preview-aud"]),u='<audio id="pv-content-aud"/>',l=function(){var e=i("#pv-content-aud")[0];e&&s.setLabels([s.item.label,o.formatDate(1e3*e.duration,"m:ss")])},f=function(e){e.unload=function(){e.src="",e.load()}},d=function(e){return new Promise(function(t){var n=i(u).on("loadedmetadata",function(){return t(n)}).attr("controls","controls");c.autoplay&&n.attr("autoplay","autoplay"),f(n[0]),n.attr("src",e.absHref)})},p=function(){c.enabled&&s.register(c.types,d,l)};p()},function(e,t,n){"use strict";var r=n(2),i=r.dom,o=n(8),a=n(14),s=n(38),c=Object.assign({enabled:!1,size:null,types:[]},a["preview-img"]),u='<img id="pv-content-img"/>',l=function(){var e=i("#pv-content-img")[0];if(e){var t=e.offsetWidth,n=[s.item.label];if(!c.size){var r=e.naturalWidth,o=e.naturalHeight;n.push(String(r)+"x"+String(o)),n.push(String((100*t/r).toFixed(0))+"%")}s.setLabels(n)}},f=function(e){return o.request({action:"get",thumbs:[{type:"img",href:e,width:c.size,height:0}]}).then(function(e){return e&&e.thumbs&&e.thumbs[0]?e.thumbs[0]:null})},d=function(e){return Promise.resolve(e.absHref).then(function(e){return c.size?f(e):e}).then(function(e){return new Promise(function(t){var n=i(u).on("load",function(){return t(n)}).attr("src",e)})})},p=function(){c.enabled&&s.register(c.types,d,l)};p()},function(e,t,n){(function(e){"use strict";var t=n(42),r=n(28),i=n(2),o=i.keys,a=i.dom,s=n(14),c=n(38),u=e.window,l=u.XMLHttpRequest,f=Object.assign({enabled:!1,styles:{}},s["preview-txt"]),d='<pre id="pv-content-txt"></pre>',p='<div id="pv-content-txt"></div>',h=function(){var e=a("#pv-content-txt")[0];if(e){var t=a("#pv-container")[0];e.style.height=t.offsetHeight+"px",c.setLabels([c.item.label,c.item.size+" bytes"])}},g=function(e){return new Promise(function(t,n){var r=new l,i=function(){if(r.readyState===l.DONE)try{t(r.responseText||"")}catch(e){n(String(e))}};r.open("GET",e,!0),r.onreadystatechange=i,r.send()})},m=function(e){return g(e.absHref).catch(function(e){return"[request failed] "+e}).then(function(n){var i=f.styles[e.type];if(1===i)return a(d).text(n);if(2===i)return a(p).html(r(n));if(3===i){var o=a("<code></code>").text(n);return u.setTimeout(function(){t.el(o[0])},n.length<2e4?0:500),a(d).app(o)}return a(p).text(n)})},v=function(){f.enabled&&c.register(o(f.styles),m,h)};v()}).call(t,function(){return this}())},function(e,t,n){!function(t,n){e.exports=n()}(this,function(){var e=".lolight",t="ll-",n="_nam#2196f3}_num#ec407a}_str#43a047}_rex#ef6c00}_pct#666}_key#555;font-weight:bold}_com#aaa;font-style:italic}".replace(/_/g,"."+t).replace(/#/g,"{color:#"),r=/^(a(bstract|lias|nd|rguments|rray|s(m|sert)?|uto)|b(ase|egin|ool(ean)?|reak|yte)|c(ase|atch|har|hecked|lass|lone|ompl|onst|ontinue)|de(bugger|cimal|clare|f(ault|er)?|init|l(egate|ete)?)|do|double|e(cho|ls?if|lse(if)?|nd|nsure|num|vent|x(cept|ec|p(licit|ort)|te(nds|nsion|rn)))|f(allthrough|alse|inal(ly)?|ixed|loat|or(each)?|riend|rom|unc(tion)?)|global|goto|guard|i(f|mp(lements|licit|ort)|n(it|clude(_once)?|line|out|stanceof|t(erface|ernal)?)?|s)|l(ambda|et|ock|ong)|m(odule|utable)|NaN|n(amespace|ative|ext|ew|il|ot|ull)|o(bject|perator|r|ut|verride)|p(ackage|arams|rivate|rotected|rotocol|ublic)|r(aise|e(adonly|do|f|gister|peat|quire(_once)?|scue|strict|try|turn))|s(byte|ealed|elf|hort|igned|izeof|tatic|tring|truct|ubscript|uper|ynchronized|witch)|t(emplate|hen|his|hrows?|ransient|rue|ry|ype(alias|def|id|name|of))|u(n(checked|def(ined)?|ion|less|signed|til)|se|sing)|v(ar|irtual|oid|olatile)|w(char_t|hen|here|hile|ith)|xor|yield)$/,i="com",o="key",a="nam",s="num",c="pct",u="rex",l="spc",f="str",d="unk",p=[[s,/#([0-9a-f]{6}|[0-9a-f]{3})\b/],[i,/(\/\/|#).*?(?=\n|$)/],[i,/\/\*[\s\S]*?\*\//],[i,/<!--[\s\S]*?-->/],[u,/\/(\\\/|[^\n])*?\//],[f,/(['"`])(\\\1|[\s\S])*?\1/],[s,/[+-]?([0-9]*\.?[0-9]+|[0-9]+\.?[0-9]*)([eE][+-]?[0-9]+)?/],[c,/[\\.,:;+\-*\/=<>()[\]{}|?!&(a)~]/],[l,/\s+/],[a,/[\w$]+/],[d,/./]],h=function(e){if("string"!=typeof e)throw new Error("tok: no string");for(var t=[],n=p.length,i=!1;e;)for(var c=0;c<n;c+=1){var f=p[c][1].exec(e);if(f&&0===f.index){var d=p[c][0];if(d!==u||!i){var h=f[0];d===a&&r.test(h)&&(d=o),d===l?h.indexOf("\n")>=0&&(i=!1):i=d===s||d===a,e=e.slice(h.length),t.push([d,h]);break}}}return t},g=function(e,t){if("undefined"!=typeof document)t(document);else if(e)throw new Error("no doc")},m=function(e){g(!0,function(n){var r=h(e.textContent);e.innerHTML="",r.forEach(function(r){var i=n.createElement("span");i.className=t+r[0],i.textContent=r[1],e.appendChild(i)})})},v=function(t){g(!0,function(n){[].forEach.call(n.querySelectorAll(t||e),function(e){m(e)})})};return g(!1,function(e){var t=e.querySelector("head"),r=e.createElement("style");r.textContent=n,t.insertBefore(r,t.firstChild),/^(i|c|loade)/.test(e.readyState)?v():e.addEventListener("DOMContentLoaded",function(){v()})}),v.tok=h,v.el=m,v})},function(e,t,n){"use strict";var r=n(2),i=r.dom,o=n(14),a=n(38),s=Object.assign({enabled:!1,autoplay:!0,types:[]},o["preview-vid"]),c='<video id="pv-content-vid"/>',u=function(){var e=i("#pv-content-vid")[0];if(e){var t=e.offsetWidth,n=e.videoWidth,r=e.videoHeight;a.setLabels([a.item.label,String(n)+"x"+String(r),String((100*t/n).toFixed(0))+"%"])}},l=function(e){e.unload=function(){e.src="",e.load()}},f=function(e){return new Promise(function(t){var n=i(c).on("loadedmetadata",function(){return t(n)}).attr("controls","controls");s.autoplay&&n.attr("autoplay","autoplay"),l(n[0]),n.attr("src",e.absHref)})},d=function(){s.enabled&&a.register(s.types,f,u)};d()},function(e,t,n){"use strict";var r=n(2),i=r.map,o=r.debounce,a=r.parsePattern,s=r.dom,c=n(8),u=n(12),l=n(20),f=n(13),d=n(14),p=n(22),h=n(18),g=Object.assign({enabled:!1,advanced:!1,debounceTime:300,ignorecase:!0},d.search),m='<div id="search" class="tool">\n <img src="'+f.image("search")+'" alt="search"/>\n <input class="l10n_ph-search" type="text" value=""/>\n </div>',v=!1,b="",w=void 0,y=void 0,x=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";if(e!==b){if(b=e,!e)return void h.setLocation();w.addCls("pending"),c.request({action:"get",search:{href:l.getAbsHref(),pattern:e,ignorecase:g.ignorecase}}).then(function(e){w.rmCls("pending"),h.setHint("noMatch"),h.setItems(i(e.search,function(e){return p.get(e)}))})}},k=function(){v?(w.addCls("active"),y[0].focus(),x(a(y.val(),g.advanced))):(x(),w.rmCls("active"))},_=function(){v=!v,k()},C=function(){v=!1,y.val(""),k()},S=function(){g.enabled&&(w=s(m).appTo("#toolbar"),y=w.find("input"),w.find("img").on("click",_),y.on("keyup",o(k,g.debounceTime)),u.sub("location.changed",C))};S()},function(e,t,n){(function(e){"use strict";var t=n(2),r=t.each,i=t.dom,o=n(12),a=n(13),s=n(14),c=e.window.document,u=Object.assign({enabled:!1,clickndrag:!1,checkboxes:!1},s.select),l='<span class="selector">\n <img src="'+a.image("selected")+'" alt="selected"/>\n </span>',f=i(c),d=i("html"),p=i('<div id="selection-rect"></div>'),h=Math.max,g=Math.min,m=Math.abs,v=0,b=0,w=function(){var e=i("#items .item.selected").map(function(e){return e._item});o.pub("selection",e)},y=function(e){var t=i(e);if(!t.length||t.isHidden())return null;var n=t[0].getBoundingClientRect();return{l:n.left,t:n.top,r:n.right,b:n.bottom}},x=function(e,t){return!!e&&!!t&&e.l===t.l&&e.t===t.t&&e.r===t.r&&e.b===t.b},k=function(e){var t=e[0];x(y(t),t&&t._rect)||e.each(function(e){e._rect=y(e)})},_=function(e,t){if(!e||!t)return!1;var n=h(e.l,t.l),r=g(e.r,t.r),i=h(e.t,t.t),o=g(e.b,t.b);return n<=r&&i<=o},C=function(e){var t=i("#content")[0],n=y(t),r=e.pageX-n.l+t.scrollLeft,o=e.pageY-n.t+t.scrollTop;return{x:r,y:o}},S=function(e){var t=C(e),n=t.x,r=t.y,o=g(v,n),a=g(b,r),s=m(v-n),c=m(b-r),u=e.ctrlKey||e.metaKey;if(!(!u&&s<4&&c<4)){u||i("#items .item").rmCls("selected"),d.addCls("drag-select"),p.show().css({left:o+"px",top:a+"px",width:s+"px",height:c+"px"});var l=y(p),f=i("#items .item:not(.folder-parent)");k(f),f.rmCls("selecting").each(function(e){_(l,e._rect)&&i(e).addCls("selecting")})}},A=function e(t){f.off("mousemove",S).off("mouseup",e),S(t),i("#items .item.selecting.selected").rmCls("selecting").rmCls("selected"),i("#items .item.selecting").rmCls("selecting").addCls("selected"),w(),d.rmCls("drag-select"),p.hide(),t.stopPropagation(),t.preventDefault()},T=function(e){if(!(0!==e.button||e.offsetX>=i("#content")[0].offsetWidth-16)){var t=C(e),n=t.x,r=t.y;v=n,b=r,f.on("mousemove",S).on("mouseup",A),S(e),e.preventDefault()}},E=function(e){for(;!e._item&&e.parentNode;)e=e.parentNode;return e._item},M=function(e){E(e.target).$view.tglCls("selected"),w(),e.stopPropagation(),e.preventDefault()},D=function(e){e.$view&&!e.isCurrentParentFolder()&&i(l).on("click",M).appTo(e.$view.find("a"))},P=function(e,t){u.checkboxes&&r(e,D),r(t,function(e){e.$view&&e.$view.rmCls("selected")}),w()},z=function(){u.enabled&&(u.clickndrag||u.checkboxes)&&(o.sub("view.changed",P),u.clickndrag&&(p.hide().appTo("#content"),i("#content").on("mousedown",T).on("drag",function(e){return e.preventDefault()}).on("dragstart",function(e){return e.preventDefault()})))};z()}).call(t,function(){return this}())},function(e,t,n){"use strict";var r=n(2),i=r.each,o=r.toArray,a=r.dom,s=r.cmp,c=r.naturalCmp,u=n(12),l=n(13),f=n(14),d=n(16),p=Object.assign({enabled:!1,column:0,reverse:!1,ignorecase:!0,natural:!1,folders:0},f.sort),h="ext/sort",g='<img src="'+l.image("sort")+'" class="sort" alt="sort order"/>',m=function(e){
-return e.isFolder()?p.folders:1},v={0:"label",1:"time",2:"size"},b={0:"label",1:"date",2:"size"},w=function(e,t,n,r){return function(i,o){var a=i._item,u=o._item,l=m(a)-m(u);if(0!==l)return l;var f=a[e],d=u[e];return(isNaN(f)||isNaN(d))&&(f=String(f),d=String(d),n&&(f=f.toLowerCase(),d=d.toLowerCase())),l=r?c(f,d):s(f,d),t?-l:l}},y=function(e,t){var n=a("#items li.header a"),r=a("#items li.header a."+b[e]),i=w(v[e],t,p.ignorecase,p.natural);d.put(h,{column:e,reverse:t}),n.rmCls("ascending").rmCls("descending"),r.addCls(t?"descending":"ascending"),a(o(a("#items .item:not(.folder-parent)")).sort(i)).appTo("#items")},x=function(){var e=d.get(h),t=e&&e.column||p.column,n=e&&e.reverse||p.reverse;y(t,n)},k=function(){var e=a("#items li.header");i(b,function(t,n){var r="0"===n?"app":"pre";e.find("a."+t)[r](g).on("click",function(e){y(n,a(e.currentTarget).hasCls("ascending")),e.preventDefault()})})},_=function(){p.enabled&&(k(),u.sub("view.changed",x))};_()},function(e,t,n){"use strict";var r=n(2),i=r.each,o=r.map,a=r.includes,s=n(8),c=n(12),u=n(14),l=Object.assign({enabled:!1,img:["img-bmp","img-gif","img-ico","img-jpg","img-png"],mov:["vid-avi","vid-flv","vid-mkv","vid-mov","vid-mp4","vid-mpg","vid-webm"],doc:["x-pdf","x-ps"],delay:1,size:100,exif:!1,chunksize:20},u.thumbnails),f=4/3,d=function(e,t){var n=null;if(a(l.img,t.type))n="img";else if(a(l.mov,t.type))n="mov";else{if(!a(l.doc,t.type))return;n="doc"}t.thumbSquare?t.$view.find(".icon.square img").addCls("thumb").attr("src",t.thumbSquare):e.push({type:n,href:t.absHref,ratio:1,callback:function(e){e&&t.$view&&(t.thumbSquare=e,t.$view.find(".icon.square img").addCls("thumb").attr("src",e))}}),t.thumbRational?t.$view.find(".icon.landscape img").addCls("thumb").attr("src",t.thumbRational):e.push({type:n,href:t.absHref,ratio:f,callback:function(e){e&&t.$view&&(t.thumbRational=e,t.$view.find(".icon.landscape img").addCls("thumb").attr("src",e))}})},p=function(e){var t=o(e,function(e){return{type:e.type,href:e.href,width:Math.round(l.size*e.ratio),height:l.size}});return s.request({action:"get",thumbs:t}).then(function(t){i(e,function(e,n){e.callback(t&&t.thumbs?t.thumbs[n]:null)})})},h=function(e){for(var t=e.length,n=l.chunksize,r=Promise.resolve(),i=function(t){r=r.then(function(){return p(e.slice(t,t+n))})},o=0;o<t;o+=n)i(o)},g=function(e){var t=[];i(e,function(e){return d(t,e)}),h(t)},m=function(e){setTimeout(function(){return g(e)},l.delay)},v=function(){l.enabled&&c.sub("view.changed",m)};v()},function(e,t,n){(function(e){"use strict";var t=n(12),r=n(14),i=e.window.document,o=Object.assign({enabled:!1},r.title),a=function(e){var t=e.getCrumb().map(function(e){return e.label}),n=t.join(" > ");t.length>1&&(n=t[t.length-1]+" - "+n),i.title=n},s=function(){o.enabled&&t.sub("location.changed",a)};s()}).call(t,function(){return this}())},function(e,t,n){"use strict";var r=n(2),i=r.each,o=r.dom,a=r.cmp,s=r.naturalCmp,c=n(12),u=n(20),l=n(13),f=n(14),d=n(16),p=Object.assign({enabled:!1,show:!0,maxSubfolders:50,naturalSort:!1,ignorecase:!0},f.tree),h='<div class="item folder">\n <span class="indicator">\n <img src="'+l.image("tree-indicator")+'"/>\n </span>\n <a>\n <span class="icon"><img src="'+l.icon("folder")+'"/></span>\n <span class="label"></span>\n </a>\n </span>',g='<div class="block">\n <h1 class="l10n-tree">Tree</h1>\n <div id="view-tree" class="button view">\n <img src="'+l.image("tree-toggle")+'" alt="view-tree"/>\n </div>\n </div>',m="ext/tree",v=function(e){for(;!e._item&&e.parentNode;)e=e.parentNode;return e._item},b=function(e){var t=v(e.target);"unknown"===t._treeState?t.fetchContent().then(function(){t._treeState="open",y(t)}):"open"===t._treeState?(t._treeState="closed",t._$tree.rmCls("open").addCls("closed")):"closed"===t._treeState&&(t._treeState="open",t._$tree.rmCls("closed").addCls("open"))},w=function(e,t){var n=e.label,r=t.label;return p.ignorecase&&(n=n.toLowerCase(),r=r.toLowerCase()),p.naturalSort?s(n,r):a(n,r)},y=function e(t){var n=t.getSubfolders(),r=n.length,a=p.maxSubfolders,s=o(h);if(s.find(".indicator").on("click",b),s.find(".label").text(t.label),u.setLink(s.find("a"),t),t.isCurrentFolder()&&s.addCls("active"),t.isManaged||s.find(".icon img").attr("src",l.icon("folder-page")),t._treeState=t._treeState||"none",t.isManaged&&!t.isContentFetched?t._treeState="unknown":r||(t._treeState="none"),s.addCls(t._treeState),r){var c=o('<div class="content"></div>').appTo(s);n.sort(w),i(n.slice(0,a),function(t){return c.app(e(t))}),r>a&&c.app('<div class="summary">… '+(r-a)+" more subfolders</div>")}return t._$tree&&t._$tree.rpl(s),t._$tree=s,s[0]._item=t,s},x=function e(t){return t._treeState="open",t.fetchContent().then(function(){return t.parent?e(t.parent):t})},k=function(){d.get(m)?(o("#view-tree").addCls("active"),o("#tree").show()):(o("#view-tree").rmCls("active"),o("#tree").hide())},_=function(e){x(e).then(function(e){o("#tree").clr().app(y(e)),k()})},C=function(){p.enabled&&(o('<div id="tree"></div>').hide().appTo("#mainrow"),o(g).appTo("#sidebar").find("#view-tree").on("click",function(e){d.put(m,!d.get(m)),k(),c.pub("resize"),e.preventDefault()}),"boolean"!=typeof d.get(m)&&d.put(m,p.show),k(),c.sub("location.changed",_))};C()},function(e,t,n){(function(e){"use strict";var t=n(2),r=t.dom,i=n(7),o=n(8),a=n(13),s='<ul id="tests"></ul>',c='<li class="test">\n <span class="label"></span>\n <span class="result"></span>\n <div class="info"></div>\n </li>',u='<div id="login-wrapper">\n <input id="pass" type="password" placeholder="password"/>\n <span id="login">login</span>\n <span id="logout">logout</span>\n <div id="hint">\n The preset password is the empty string, just click login.\n Change it in \'_h5ai/private/conf/options.json\'.\n </div>\n </div>',l='<div id="support">\n Show your support with a donation!\n <div class="paypal">\n <form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_blank">\n <input type="hidden" name="cmd" value="_s-xclick"/>\n <input type="hidden" name="hosted_button_id" value="8WSPKWT7YBTSQ"/>\n <input type="image" src="'+a.image("paypal")+'" name="submit" alt="PayPal"/>\n </form>\n </div>\n </div>',f=i.setup,d=function(e,t,n,i){var o=r(c).appTo("#tests");o.find(".label").text(e),o.find(".result").addCls(n?"passed":"failed").text(i?i:n?"yes":"no"),o.find(".info").html(t)},p=function(){f.AS_ADMIN&&(r(s).appTo("#content"),d("h5ai version","Only green if this is an official h5ai release",/^\d+\.\d+\.\d+$/.test(f.VERSION),f.VERSION),d("Index file found","Add <code>"+f.INDEX_HREF+"</code> to your index file list",f.INDEX_HREF),d("Options parsable","File <code>options.json</code> is readable and syntax is correct",null!==i.options),d("Types parsable","File <code>types.json</code> is readable and syntax is correct",null!==i.types),d("Server software","Server is one of apache, lighttpd, nginx or cherokee",f.HAS_SERVER,f.SERVER_NAME+" "+f.SERVER_VERSION),d("PHP version","PHP version >= "+f.MIN_PHP_VERSION,!0,f.PHP_VERSION),d("PHP arch","64-bit required to correctly display file/folder sizes > ~2GB","64-bit"===f.PHP_ARCH,f.PHP_ARCH),d("Public Cache directory","Web server has write access",f.HAS_WRITABLE_CACHE_PUB),d("Private Cache directory","Web server has write access",f.HAS_WRITABLE_CACHE_PRV),d("Image thumbs","PHP GD extension with JPEG support available",f.HAS_PHP_JPEG),d("Use EXIF thumbs","PHP EXIF extension available",f.HAS_PHP_EXIF),d("Movie thumbs","Command line program <code>avconv</code> or <code>ffmpeg</code> available",f.HAS_CMD_AVCONV||f.HAS_CMD_FFMPEG),d("PDF thumbs","Command line program <code>convert</code> or <code>gm</code> available",f.HAS_CMD_CONVERT||f.HAS_CMD_GM),d("Shell tar","Command line program <code>tar</code> available",f.HAS_CMD_TAR),d("Shell zip","Command line program <code>zip</code> available",f.HAS_CMD_ZIP),d("Shell du","Command line program <code>du</code> available",f.HAS_CMD_DU))},h=function(){e.window.location.reload()},g=function(){o.request({action:"login",pass:r("#pass").val()}).then(h)},m=function(){o.request({action:"logout"}).then(h)},v=function(e){13===e.which&&g()},b=function(){r(l).appTo("#content")},w=function(){r(u).appTo("#content"),f.AS_ADMIN?(r("#pass").rm(),r("#login").rm(),r("#logout").on("click",m)):(r("#pass").on("keydown",v)[0].focus(),r("#login").on("click",g),r("#logout").rm()),i.options.hasCustomPasshash&&r("#hint").rm()},y=function(){b(),w(),p()};y()}).call(t,function(){return this}())}]);
\ No newline at end of file
+/* h5ai v0.29.2 - https://larsjung.de/h5ai/ */ !(function(e) {
+ function t(e, t) {
+ if (!t) throw ((i.className = r), new Error(r + ": " + e));
+ }
+
+ function n(e) {
+ return "function" == typeof e;
+ }
+ if (!e || e.window !== e || !e.document) throw new Error("no-window");
+ var r = "no-browser",
+ i = e.document.documentElement;
+ (i.className = ""),
+ t("console", e.console && n(e.console.log)),
+ t("assign", e.Object && n(e.Object.assign)),
+ t("promise", n(e.Promise)),
+ t("xhr", e.XMLHttpRequest);
+})(this),
+(function(e) {
+ function t(r) {
+ if (n[r]) return n[r].exports;
+ var i = (n[r] = { exports: {}, id: r, loaded: !1 });
+ return e[r].call(i.exports, i, i.exports, t), (i.loaded = !0), i.exports;
+ }
+ var n = {};
+ return (t.m = e), (t.c = n), (t.p = ""), t(0);
+})([
+ function(e, t, n) {
+ "use strict";
+ n(1);
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.dom,
+ o = r.awaitReady,
+ a = n(7),
+ s = i("script[data-module]").attr("data-module"),
+ c = { action: "get", setup: !0, options: !0, types: !0 };
+ if ("index" === s)(c.theme = !0), (c.langs = !0);
+ else {
+ if ("info" !== s) throw new Error("no-main-module: '" + s + "'");
+ c.refresh = !0;
+ }
+ a._update(c)
+ .then(function() {
+ return o();
+ })
+ .then(function() {
+ return n(9)("./" + s);
+ });
+ },
+ function(e, t, n) {
+ "use strict";
+ e.exports = Object.assign({}, n(3), n(4), n(5), n(6));
+ },
+ function(e, t) {
+ "use strict";
+ var n =
+ "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ?
+
+ function(e) {
+ return typeof e;
+ } :
+ function(e) {
+ return e &&
+ "function" == typeof Symbol &&
+ e.constructor === Symbol &&
+ e !== Symbol.prototype ?
+ "symbol" :
+ typeof e;
+ },
+ r = function(e) {
+ return void 0 !== e && null !== e;
+ },
+ i = function(e, t) {
+ return ("undefined" == typeof e ? "undefined" : n(e)) === t;
+ },
+ o = function(e) {
+ return i(e, "string");
+ },
+ a = function(e) {
+ return i(e, "function");
+ },
+ s = function(e) {
+ return i(e, "number");
+ },
+ c = function(e) {
+ return e && e.hasOwnProperty("length");
+ },
+ u = function(e) {
+ return !e || o(e) ?
+ [] :
+ (c(e) && (e = Array.from(e)), Object.keys(e));
+ },
+ l = function(e) {
+ return u(e).map(function(t) {
+ return e[t];
+ });
+ },
+ f = function(e, t) {
+ return u(e).forEach(function(n) {
+ return t(e[n], n);
+ });
+ },
+ d = function(e, t) {
+ return l(e).filter(t);
+ },
+ p = function(e, t) {
+ return l(e).map(t);
+ },
+ h = function(e, t) {
+ return l(e).indexOf(t) >= 0;
+ },
+ g = function(e) {
+ return d(e, function(e) {
+ return !!e;
+ });
+ },
+ m = function(e, t) {
+ return !!e && e instanceof t;
+ },
+ v = function(e) {
+ return Array.from(e);
+ },
+ b = function(e, t) {
+ return (
+ (t = l(t)),
+ d(e, function(e) {
+ return t.indexOf(e) < 0;
+ })
+ );
+ },
+ w = function(e, t) {
+ return (
+ (t = l(t)),
+ d(e, function(e) {
+ return t.indexOf(e) >= 0;
+ })
+ );
+ },
+ y = function(e, t) {
+ return e < t ? -1 : e > t ? 1 : 0;
+ },
+ x = function(e, t) {
+ var n = a(t) ?
+ t :
+ function(e) {
+ return e[t];
+ },
+ r = function(e, t) {
+ return y(n(e), n(t));
+ };
+ return l(e).sort(r);
+ },
+ k = function(e, t) {
+ var n = null;
+ return function() {
+ clearTimeout(n), (n = setTimeout(e, t));
+ };
+ };
+ e.exports = {
+ is: r,
+ isStr: o,
+ isFn: a,
+ isNum: s,
+ hasLength: c,
+ keys: u,
+ values: l,
+ each: f,
+ filter: d,
+ map: p,
+ includes: h,
+ compact: g,
+ isInstanceOf: m,
+ toArray: v,
+ difference: b,
+ intersection: w,
+ cmp: y,
+ sortBy: x,
+ debounce: k,
+ };
+ },
+ function(e, t, n) {
+ (function(t) {
+ "use strict";
+
+ function r(e) {
+ if (Array.isArray(e)) {
+ for (var t = 0, n = Array(e.length); t < e.length; t++) n[t] = e[t];
+ return n;
+ }
+ return Array.from(e);
+ }
+ var i = (function() {
+ function e(e, t) {
+ var n = [],
+ r = !0,
+ i = !1,
+ o = void 0;
+ try {
+ for (
+ var a, s = e[Symbol.iterator](); !(r = (a = s.next()).done) &&
+ (n.push(a.value), !t || n.length !== t); r = !0
+ );
+ } catch (e) {
+ (i = !0), (o = e);
+ } finally {
+ try {
+ !r && s.return && s.return();
+ } finally {
+ if (i) throw o;
+ }
+ }
+ return n;
+ }
+ return function(t, n) {
+ if (Array.isArray(t)) return t;
+ if (Symbol.iterator in Object(t)) return e(t, n);
+ throw new TypeError(
+ "Invalid attempt to destructure non-iterable instance"
+ );
+ };
+ })(),
+ o = n(3),
+ a = o.each,
+ s = o.filter,
+ c = o.hasLength,
+ u = o.is,
+ l = o.isStr,
+ f = o.map,
+ d = o.isInstanceOf,
+ p = o.toArray,
+ h = t.window,
+ g = h.document,
+ m = (function() {
+ var e = function(e) {
+ return g.createElement(e);
+ },
+ t = [
+ [/^<t(head|body|foot)|^<c(ap|olg)/i, e("table")],
+ [/^<col/i, e("colgroup")],
+ [/^<tr/i, e("tbody")],
+ [/^<t[dh]/i, e("tr")],
+ ],
+ n = e("div"),
+ r = function(e) {
+ var r = !0,
+ o = !1,
+ a = void 0;
+ try {
+ for (
+ var s, c = t[Symbol.iterator](); !(r = (s = c.next()).done); r = !0
+ ) {
+ var u = s.value,
+ l = i(u, 2),
+ f = l[0],
+ d = l[1];
+ if (f.test(e)) return d;
+ }
+ } catch (e) {
+ (o = !0), (a = e);
+ } finally {
+ try {
+ !r && c.return && c.return();
+ } finally {
+ if (o) throw a;
+ }
+ }
+ return n;
+ };
+ return function(e) {
+ var t = r(e);
+ t.innerHTML = e;
+ var n = p(t.childNodes);
+ return (
+ a(n, function(e) {
+ return t.removeChild(e);
+ }),
+ (t.innerHTML = ""),
+ n
+ );
+ };
+ })(),
+ v = function(e) {
+ var t =
+ arguments.length > 1 && void 0 !== arguments[1] ?
+ arguments[1] :
+ g;
+ try {
+ return p(t.querySelectorAll(e));
+ } catch (e) {
+ return [];
+ }
+ },
+ b = function(e) {
+ return d(e, h.Element);
+ },
+ w = function(e) {
+ return d(e, h.Document);
+ },
+ y = function(e) {
+ return u(e) && e.window === e && w(e.document);
+ },
+ x = function(e) {
+ return b(e) || w(e) || y(e);
+ },
+ k = function(e, t, n) {
+ return e.addEventListener(t, n);
+ },
+ _ = function(e, t, n) {
+ return e.removeEventListener(t, n);
+ },
+ C = new Promise(function(e) {
+ /^(i|c|loade)/.test(g.readyState) ?
+ e() :
+ k(g, "DOMContentLoaded", function() {
+ return e();
+ });
+ }),
+ S = function() {
+ return C;
+ },
+ A = new Promise(function(e) {
+ k(h, "load", function() {
+ return e();
+ });
+ }),
+ T = function() {
+ return A;
+ },
+ E = function e(t) {
+ if (d(t, e)) return t;
+ var n = void 0;
+ return (
+ l(t) ?
+ ((t = t.trim()), (n = "<" === t[0] ? m(t) : v(t))) :
+ (n = x(t) ? [t] : c(t) ? t : [t]),
+ (n = s(n, x)),
+ Object.assign(Object.create(e.prototype), n, { length: n.length })
+ );
+ };
+ (E.prototype = {
+ constructor: E,
+ each: function(e) {
+ return a(this, e), this;
+ },
+ map: function(e) {
+ return f(this, e);
+ },
+ find: function(e) {
+ var t;
+ return E(
+ (t = []).concat.apply(
+ t,
+ r(
+ this.map(function(t) {
+ return v(e, t);
+ })
+ )
+ )
+ );
+ },
+ on: function(e, t) {
+ return this.each(function(n) {
+ return k(n, e, t);
+ });
+ },
+ off: function(e, t) {
+ return this.each(function(n) {
+ return _(n, e, t);
+ });
+ },
+ attr: function(e, t) {
+ return void 0 === t ?
+ this.length ?
+ this[0].getAttribute(e) :
+ void 0 :
+ this.each(function(n) {
+ return n.setAttribute(e, t);
+ });
+ },
+ rmAttr: function(e) {
+ return this.each(function(t) {
+ return t.removeAttribute(e);
+ });
+ },
+ prop: function(e, t) {
+ return void 0 === t ?
+ this.length ?
+ this[0][e] :
+ void 0 :
+ this.each(function(n) {
+ n[e] = t;
+ });
+ },
+ rmProp: function(e) {
+ return this.each(function(t) {
+ return delete t[e];
+ });
+ },
+ val: function(e) {
+ return void 0 === e ?
+ this.length ?
+ this[0].value :
+ void 0 :
+ this.each(function(t) {
+ t.value = e;
+ });
+ },
+ html: function(e) {
+ return void 0 === e ?
+ this.map(function(e) {
+ return e.innerHTML;
+ }).join("") :
+ this.each(function(t) {
+ t.innerHTML = e;
+ });
+ },
+ text: function(e) {
+ return void 0 === e ?
+ this.map(function(e) {
+ return e.textContent;
+ }).join("") :
+ this.each(function(t) {
+ t.textContent = e;
+ });
+ },
+ clr: function() {
+ return this.html("");
+ },
+ rm: function() {
+ return this.each(function(e) {
+ var t = e.parentNode;
+ t && t.removeChild(e);
+ });
+ },
+ rpl: function(e) {
+ return this.each(function(t) {
+ var n = t.parentNode;
+ n && n.replaceChild(E(e)[0], t);
+ });
+ },
+ app: function(e) {
+ return this.each(function(t) {
+ E(e).each(function(e) {
+ return t.appendChild(e);
+ });
+ });
+ },
+ appTo: function(e) {
+ return E(e).app(this), this;
+ },
+ pre: function(e) {
+ return this.each(function(t) {
+ E(e).each(function(e) {
+ var n = t.firstChild;
+ n ? t.insertBefore(e, n) : t.appendChild(e);
+ });
+ });
+ },
+ preTo: function(e) {
+ return E(e).pre(this), this;
+ },
+ cls: function() {
+ return arguments.length ?
+ (this.each(function(e) {
+ e.className = "";
+ }),
+ this.addCls.apply(this, arguments)) :
+ this.length ?
+ p(this[0].classList) :
+ [];
+ },
+ hasCls: function(e) {
+ return p(this).every(function(t) {
+ return t.classList.contains(e);
+ });
+ },
+ addCls: function() {
+ for (var e = arguments.length, t = Array(e), n = 0; n < e; n++)
+ t[n] = arguments[n];
+ return this.each(function(e) {
+ var n = !0,
+ r = !1,
+ i = void 0;
+ try {
+ for (
+ var o, a = t[Symbol.iterator](); !(n = (o = a.next()).done); n = !0
+ ) {
+ var s = o.value;
+ e.classList.add(s);
+ }
+ } catch (e) {
+ (r = !0), (i = e);
+ } finally {
+ try {
+ !n && a.return && a.return();
+ } finally {
+ if (r) throw i;
+ }
+ }
+ });
+ },
+ rmCls: function() {
+ for (var e = arguments.length, t = Array(e), n = 0; n < e; n++)
+ t[n] = arguments[n];
+ return this.each(function(e) {
+ var n = !0,
+ r = !1,
+ i = void 0;
+ try {
+ for (
+ var o, a = t[Symbol.iterator](); !(n = (o = a.next()).done); n = !0
+ ) {
+ var s = o.value;
+ e.classList.remove(s);
+ }
+ } catch (e) {
+ (r = !0), (i = e);
+ } finally {
+ try {
+ !n && a.return && a.return();
+ } finally {
+ if (r) throw i;
+ }
+ }
+ });
+ },
+ tglCls: function() {
+ for (var e = arguments.length, t = Array(e), n = 0; n < e; n++)
+ t[n] = arguments[n];
+ return this.each(function(e) {
+ var n = !0,
+ r = !1,
+ i = void 0;
+ try {
+ for (
+ var o, a = t[Symbol.iterator](); !(n = (o = a.next()).done); n = !0
+ ) {
+ var s = o.value;
+ e.classList.contains(s) ?
+ e.classList.remove(s) :
+ e.classList.add(s);
+ }
+ } catch (e) {
+ (r = !0), (i = e);
+ } finally {
+ try {
+ !n && a.return && a.return();
+ } finally {
+ if (r) throw i;
+ }
+ }
+ });
+ },
+ parent: function() {
+ return E(
+ this.map(function(e) {
+ return e.parentNode;
+ })
+ );
+ },
+ children: function() {
+ var e;
+ return E(
+ (e = []).concat.apply(
+ e,
+ r(
+ this.map(function(e) {
+ return p(e.children);
+ })
+ )
+ )
+ );
+ },
+ hide: function() {
+ return this.addCls("hidden");
+ },
+ show: function() {
+ return this.rmCls("hidden");
+ },
+ isHidden: function() {
+ return this.hasCls("hidden");
+ },
+ css: function(e) {
+ return this.each(function(t) {
+ return Object.assign(t.style, e);
+ });
+ },
+ }),
+ (e.exports = { awaitReady: S, awaitLoad: T, dom: E });
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t) {
+ "use strict";
+ var n =
+ "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ?
+
+ function(e) {
+ return typeof e;
+ } :
+ function(e) {
+ return e &&
+ "function" == typeof Symbol &&
+ e.constructor === Symbol &&
+ e !== Symbol.prototype ?
+ "symbol" :
+ typeof e;
+ },
+ r = /(^([+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?)?$|^0x[0-9a-f]+$|\d+)/gi,
+ i = /(^([\w ]+,?[\w ]+)?[\w ]+,?[\w ]+\d+:\d+(:\d+)?[\w ]?|^\d{1,4}[\/\-]\d{1,4}[\/\-]\d{1,4}|^\w+, \w+ \d+, \d{4})/,
+ o = /^0x[0-9a-f]+$/i,
+ a = /^0/,
+ s = function(e, t) {
+ var s = String(e).trim(),
+ c = String(t).trim(),
+ u = s
+ .replace(r, "\0$1\0")
+ .replace(/\0$/, "")
+ .replace(/^\0/, "")
+ .split("\0"),
+ l = c
+ .replace(r, "\0$1\0")
+ .replace(/\0$/, "")
+ .replace(/^\0/, "")
+ .split("\0"),
+ f =
+ parseInt(s.match(o), 16) ||
+ (1 !== u.length && s.match(i) && Date.parse(s)),
+ d =
+ parseInt(c.match(o), 16) ||
+ (f && c.match(i) && Date.parse(c)) ||
+ null;
+ if (d) {
+ if (f < d) return -1;
+ if (f > d) return 1;
+ }
+ for (var p = 0, h = Math.max(u.length, l.length); p < h; p += 1) {
+ var g = (!(u[p] || "").match(a) && parseFloat(u[p])) || u[p] || 0,
+ m = (!(l[p] || "").match(a) && parseFloat(l[p])) || l[p] || 0;
+ if (isNaN(g) !== isNaN(m)) return isNaN(g) ? 1 : -1;
+ if (
+ (("undefined" == typeof g ? "undefined" : n(g)) !==
+ ("undefined" == typeof m ? "undefined" : n(m)) &&
+ ((g = String(g)), (m = String(m))),
+ g < m)
+ )
+ return -1;
+ if (g > m) return 1;
+ }
+ return 0;
+ };
+ e.exports = { naturalCmp: s };
+ },
+ function(e, t) {
+ "use strict";
+ var n = function(e) {
+ return e.replace(/[\-\[\]{}()*+?.,\\$\^|#\s]/g, "\\$&");
+ },
+ r = function(e, t) {
+ return t ?
+ "re:" === e.substr(0, 3) ?
+ e.substr(3) :
+ e
+ .trim()
+ .split(/\s+/)
+ .map(function(e) {
+ return e
+ .split("")
+ .map(function(e) {
+ return n(e);
+ })
+ .join(".*?");
+ })
+ .join("|") :
+ n(e);
+ };
+ e.exports = { parsePattern: r };
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(8),
+ i = r.request,
+ o = (e.exports = {
+ _update: function(e) {
+ return i(e).then(function(e) {
+ return Object.assign(o, e);
+ });
+ },
+ });
+ },
+ function(e, t, n) {
+ (function(t) {
+ "use strict";
+ var r = n(2),
+ i = r.each,
+ o = r.dom,
+ a = t.window.XMLHttpRequest,
+ s = function(e) {
+ return new Promise(function(t) {
+ var n = new a(),
+ r = function() {
+ if (n.readyState === a.DONE)
+ try {
+ t(JSON.parse(n.responseText));
+ } catch (e) {
+ t({ err: e, txt: n.responseText });
+ }
+ };
+ n.open("POST", "?", !0),
+ (n.onreadystatechange = r),
+ n.setRequestHeader(
+ "Content-Type",
+ "application/json;charset=utf-8"
+ ),
+ n.send(JSON.stringify(e));
+ });
+ },
+ c = function(e) {
+ var t = o('<form method="post" action="?" style="display:none;"/>');
+ i(e, function(e, n) {
+ o('<input type="hidden"/>')
+ .attr("name", n)
+ .attr("value", e)
+ .appTo(t);
+ }),
+ t.appTo("body"),
+ t[0].submit(),
+ t.rm();
+ };
+ e.exports = { request: s, formRequest: c };
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ function r(e) {
+ return n(i(e));
+ }
+
+ function i(e) {
+ return (
+ o[e] ||
+ (function() {
+ throw new Error("Cannot find module '" + e + "'.");
+ })()
+ );
+ }
+ var o = {
+ "./index": 10,
+ "./index.js": 10,
+ "./info": 50,
+ "./info.js": 50,
+ };
+ (r.keys = function() {
+ return Object.keys(o);
+ }),
+ (r.resolve = i),
+ (e.exports = r),
+ (r.id = 9);
+ },
+ function(e, t, n) {
+ (function(e) {
+ "use strict";
+ n(11),
+ n(24),
+ n(25),
+ n(26),
+ n(27),
+ n(29),
+ n(30),
+ n(31),
+ n(32),
+ n(34),
+ n(36),
+ n(37),
+ n(44),
+ n(45),
+ n(46),
+ n(47),
+ n(48),
+ n(49);
+ var t = e.window.document.location.href;
+ n(20).setLocation(t, !0);
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.each,
+ o = r.dom,
+ a = n(12),
+ s = n(13),
+ c = n(14),
+ u = n(15),
+ l = n(17),
+ f = n(18),
+ d = Object.assign({ modeToggle: !1 }, c.view),
+ p =
+ '<div id="viewmode-settings" class="block"><h1 class="l10n-view">View</h1></div>',
+ h =
+ '<div id="viewmode-[MODE]" class="button mode">\n <img src="' +
+ s.image("view-[MODE]") +
+ '" alt="viewmode-[MODE]"/>\n </div>',
+ g = '<input id="viewmode-size" type="range" min="0" max="0" value="0">',
+ m =
+ '<div id="viewmode-toggle" class="tool">\n <img alt="viewmode"/>\n </div>',
+ v = void 0,
+ b = void 0,
+ w = function(e, t) {
+ o("#viewmode-settings .mode").rmCls("active"),
+ o("#viewmode-" + e).addCls("active"),
+ o("#viewmode-size").val(b.indexOf(t)),
+ "next" === d.modeToggle && (e = v[(v.indexOf(e) + 1) % v.length]),
+ o("#viewmode-toggle img").attr("src", s.image("view-" + e));
+ },
+ y = function() {
+ if (!(v.length < 2 && b.length < 2)) {
+ var e = o(p);
+ if (
+ (v.length > 1 &&
+ i(v, function(t) {
+ o(h.replace(/\[MODE\]/g, t))
+ .on("click", function() {
+ f.setMode(t);
+ })
+ .appTo(e);
+ }),
+ b.length > 1)
+ ) {
+ var t = b.length - 1;
+ o(g)
+ .attr("max", t)
+ .on("input", function(e) {
+ return f.setSize(b[e.target.valueAsNumber]);
+ })
+ .on("change", function(e) {
+ return f.setSize(b[e.target.valueAsNumber]);
+ })
+ .appTo(e);
+ }
+ e.appTo(u.$el);
+ }
+ },
+ x = function() {
+ var e = f.getMode(),
+ t = (v.indexOf(e) + 1) % v.length,
+ n = v[t];
+ f.setMode(n);
+ },
+ k = function() {
+ d.modeToggle && v.length > 1 && o(m).on("click", x).appTo(l.$toolbar);
+ },
+ _ = function() {
+ (v = f.getModes()),
+ (b = f.getSizes()),
+ y(),
+ k(),
+ w(f.getMode(), f.getSize()),
+ a.sub("view.mode.changed", w);
+ };
+ _();
+ },
+ function(e, t, n) {
+ (function(t) {
+ "use strict";
+ var r = n(2),
+ i = r.isStr,
+ o = r.isFn,
+ a = r.dom,
+ s = {},
+ c = function(e, t) {
+ i(e) && o(t) && (s[e] || (s[e] = []), s[e].push(t));
+ },
+ u = function(e) {
+ for (
+ var t = arguments.length, n = Array(t > 1 ? t - 1 : 0), r = 1; r < t; r++
+ )
+ n[r - 1] = arguments[r];
+ i(e) &&
+ s[e] &&
+ s[e].forEach(function(t) {
+ t.apply(e, n);
+ });
+ };
+ a(t.window).on("resize", function() {
+ return u("resize");
+ }),
+ (e.exports = { sub: c, pub: u });
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.includes,
+ o = n(7),
+ a = n(14),
+ s = a.publicHref + "images/",
+ c = s + "ui/",
+ u = s + "themes/",
+ l = u + "default/",
+ f = [
+ "file",
+ "folder",
+ "folder-page",
+ "folder-parent",
+ "ar",
+ "aud",
+ "bin",
+ "img",
+ "txt",
+ "vid",
+ "x",
+ ],
+ d = function(e) {
+ return c + e + ".svg";
+ },
+ p = function(e) {
+ var t = (e || "").split("-")[0],
+ n = o.theme[e] || o.theme[t];
+ return n ?
+ u + n :
+ i(f, e) ?
+ l + e + ".svg" :
+ i(f, t) ?
+ l + t + ".svg" :
+ l + "file.svg";
+ };
+ e.exports = { image: d, icon: p };
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(7);
+ e.exports = Object.assign({}, r.options, {
+ publicHref: r.setup.PUBLIC_HREF,
+ rootHref: r.setup.ROOT_HREF,
+ });
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.dom,
+ o = n(13),
+ a = n(14),
+ s = n(16),
+ c = n(17),
+ u = Object.assign({ disableSidebar: !1 }, a.view),
+ l = "sidebarIsVisible",
+ f = '<div id="sidebar"></div>',
+ d =
+ '<div id="sidebar-toggle" class="tool">\n <img alt="sidebar"/>\n </div>',
+ p = function() {
+ var e = i(f).hide(),
+ t = i(d),
+ n = t.find("img"),
+ r = function(r) {
+ var i = s.get(l);
+ r && ((i = !i), s.put(l, i)),
+ i ?
+ (t.addCls("active"),
+ n.attr("src", o.image("back")),
+ e.show()) :
+ (t.rmCls("active"),
+ n.attr("src", o.image("sidebar")),
+ e.hide());
+ };
+ return (
+ u.disableSidebar ||
+ (e.appTo(c.$mainrow),
+ t.appTo(c.$toolbar).on("click", function() {
+ return r(!0);
+ }),
+ r()), { $el: e }
+ );
+ };
+ e.exports = p();
+ },
+ function(e, t) {
+ (function(t) {
+ "use strict";
+ var n = t.window.localStorage,
+ r = "_h5ai",
+ i = function() {
+ try {
+ return JSON.parse(n[r]);
+ } catch (e) {}
+ return {};
+ },
+ o = function(e) {
+ n[r] = JSON.stringify(e);
+ },
+ a = function(e, t) {
+ var n = i();
+ (n[e] = t), o(n);
+ },
+ s = function(e) {
+ return i()[e];
+ };
+ e.exports = { put: a, get: s };
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.dom,
+ o = "body",
+ a =
+ '<div id="topbar">\n <div id="toolbar"></div>\n <div id="flowbar"></div>\n <a id="backlink" href="https://larsjung.de/h5ai/" title="powered by h5ai - https://larsjung.de/h5ai/">\n <div>powered</div>\n <div>by h5ai</div>\n </a>\n </div>',
+ s =
+ '<div id="mainrow">\n <div id="content"></div>\n </div>',
+ c = function() {
+ var e = i(o).attr("id", "root").clr().app(a).app(s);
+ return {
+ $root: e,
+ $topbar: e.find("#topbar"),
+ $toolbar: e.find("#toolbar"),
+ $flowbar: e.find("#flowbar"),
+ $mainrow: e.find("#mainrow"),
+ $content: e.find("#content"),
+ };
+ };
+ e.exports = c();
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.each,
+ o = r.map,
+ a = r.includes,
+ s = r.intersection,
+ c = r.dom,
+ u = n(12),
+ l = n(19),
+ f = n(20),
+ d = n(13),
+ p = n(16),
+ h = n(14),
+ g = n(17),
+ m = ["details", "grid", "icons"],
+ v = [20, 40, 60, 80, 100, 150, 200, 250, 300, 350, 400],
+ b = Object.assign({
+ binaryPrefix: !1,
+ hideFolders: !1,
+ hideParentFolder: !1,
+ maxIconSize: 40,
+ modes: m,
+ setParentFolderLabels: !1,
+ sizes: v,
+ },
+ h.view
+ ),
+ w = b.sizes.sort(function(e, t) {
+ return e - t;
+ }),
+ y = s(b.modes, m),
+ x = "view",
+ k =
+ '<div id="view">\n <ul id="items" class="clearfix">\n <li class="header">\n <a class="icon"></a>\n <a class="label" href="#"><span class="l10n-name"/></a>\n <a class="date" href="#"><span class="l10n-lastModified"/></a>\n <a class="size" href="#"><span class="l10n-size"/></a>\n </li>\n </ul>\n <div id="view-hint"></div>\n </div>',
+ _ =
+ '<li class="item">\n <a>\n <span class="icon square"><img/></span>\n <span class="icon landscape"><img/></span>\n <span class="label"></span>\n <span class="date"></span>\n <span class="size"></span>\n </a>\n </li>',
+ C = c(k),
+ S = C.find("#items"),
+ A = C.find("#view-hint"),
+ T = function(e, t, n) {
+ return Math.min(n, Math.max(t, e));
+ },
+ E = function(e) {
+ var t = T(e, 20, 80),
+ n = T(e, 40, 160),
+ r = T(e, 80, 1e3),
+ i = Math.round((4 * r) / 3),
+ o = "!important;",
+ a = "#view.view-details.view-size-" + e,
+ s = "#view.view-grid.view-size-" + e,
+ c = "#view.view-icons.view-size-" + e,
+ u = [
+ a + " .item .label {line-height: " + (t + 14) + "px " + o + "}",
+ a + " .item .date {line-height: " + (t + 14) + "px " + o + "}",
+ a + " .item .size {line-height: " + (t + 14) + "px " + o + "}",
+ a +
+ " .square {width: " +
+ t +
+ "px " +
+ o +
+ " height: " +
+ t +
+ "px " +
+ o +
+ "}",
+ a +
+ " .square img {width: " +
+ t +
+ "px " +
+ o +
+ " height: " +
+ t +
+ "px " +
+ o +
+ "}",
+ a + " .label {margin-left: " + (t + 32) + "px " + o + "}",
+ s + " .item .label {line-height: " + n + "px " + o + "}",
+ s +
+ " .square {width: " +
+ n +
+ "px " +
+ o +
+ " height: " +
+ n +
+ "px " +
+ o +
+ "}",
+ s +
+ " .square img {width: " +
+ n +
+ "px " +
+ o +
+ " height: " +
+ n +
+ "px " +
+ o +
+ "}",
+ c + " .item {width: " + i + "px " + o + "}",
+ c +
+ " .landscape {width: " +
+ i +
+ "px " +
+ o +
+ " height: " +
+ r +
+ "px " +
+ o +
+ "}",
+ c +
+ " .landscape img {width: " +
+ r +
+ "px " +
+ o +
+ " height: " +
+ r +
+ "px " +
+ o +
+ "}",
+ c + " .landscape .thumb {width: " + i + "px " + o + "}",
+ ];
+ return u.join("\n");
+ },
+ M = function() {
+ var e = o(w, function(e) {
+ return E(e);
+ });
+ e.push(
+ "#view .icon img {max-width: " +
+ b.maxIconSize +
+ "px; max-height: " +
+ b.maxIconSize +
+ "px;}"
+ ),
+ c("<style></style>").text(e.join("\n")).appTo("head");
+ },
+ D = function(e, t) {
+ var n = p.get(x);
+ (e = e || (n && n.mode)),
+ (t = t || (n && n.size)),
+ (e = a(b.modes, e) ? e : b.modes[0]),
+ (t = a(b.sizes, t) ? t : b.sizes[0]),
+ p.put(x, { mode: e, size: t }),
+ i(y, function(t) {
+ t === e ? C.addCls("view-" + t) : C.rmCls("view-" + t);
+ }),
+ i(w, function(e) {
+ e === t ? C.addCls("view-size-" + e) : C.rmCls("view-size-" + e);
+ }),
+ u.pub("view.mode.changed", e, t);
+ },
+ P = function() {
+ return y;
+ },
+ z = function() {
+ return p.get(x).mode;
+ },
+ L = function(e) {
+ return D(e, null);
+ },
+ $ = function() {
+ return w;
+ },
+ H = function() {
+ return p.get(x).size;
+ },
+ O = function(e) {
+ return D(null, e);
+ },
+ B = function(e) {
+ var t = e.target._item;
+ u.pub("item.mouseenter", t);
+ },
+ R = function(e) {
+ var t = e.target._item;
+ u.pub("item.mouseleave", t);
+ },
+ N = function(e) {
+ var t = c(_),
+ n = t.find("a"),
+ r = t.find(".icon img"),
+ i = t.find(".label"),
+ o = t.find(".date"),
+ a = t.find(".size");
+ return (
+ t
+ .addCls(e.isFolder() ? "folder" : "file")
+ .on("mouseenter", B)
+ .on("mouseleave", R),
+ f.setLink(n, e),
+ i.text(e.label).attr("title", e.label),
+ o.attr("data-time", e.time).text(l.formatDate(e.time)),
+ a.attr("data-bytes", e.size).text(l.formatSize(e.size)),
+ (e.icon = d.icon(e.type)),
+ e.isFolder() &&
+ !e.isManaged &&
+ (t.addCls("page"), (e.icon = d.icon("folder-page"))),
+ e.isCurrentParentFolder() &&
+ ((e.icon = d.icon("folder-parent")),
+ b.setParentFolderLabels || i.addCls("l10n-parentDirectory"),
+ t.addCls("folder-parent")),
+ r.attr("src", e.icon).attr("alt", e.type),
+ (e.$view = t),
+ (t[0]._item = e),
+ t
+ );
+ },
+ I = function() {
+ var e = S.find(".item").length === S.find(".folder-parent").length;
+ e ? A.show() : A.hide();
+ },
+ j = function(e) {
+ var t = o(S.find(".item"), function(e) {
+ return e._item;
+ });
+ S.find(".item").rm(),
+ i(e, function(e) {
+ return S.app(N(e));
+ }),
+ (g.$content[0].scrollLeft = 0),
+ (g.$content[0].scrollTop = 0),
+ I(),
+ u.pub("view.changed", e, t);
+ },
+ F = function(e, t) {
+ i(e, function(e) {
+ N(e).hide().appTo(S).show();
+ }),
+ i(t, function(e) {
+ e.$view.hide().rm();
+ }),
+ I(),
+ u.pub("view.changed", e, t);
+ },
+ q = function(e) {
+ A.rmCls().addCls("l10n-" + e), I();
+ },
+ Y = function(e) {
+ e || (e = f.getItem());
+ var t = [];
+ e.parent && !b.hideParentFolder && t.push(e.parent),
+ i(e.content, function(e) {
+ (e.isFolder() && b.hideFolders) || t.push(e);
+ }),
+ q("empty"),
+ j(t);
+ },
+ Z = function(e, t, n) {
+ var r = [];
+ i(t, function(e) {
+ (e.isFolder() && b.hideFolders) || r.push(e);
+ }),
+ q("empty"),
+ F(r, n);
+ },
+ U = function() {
+ var e = C[0].offsetWidth;
+ C.rmCls("width-0").rmCls("width-1"),
+ e < 320 ? C.addCls("width-0") : e < 480 && C.addCls("width-1");
+ },
+ V = function() {
+ M(),
+ D(),
+ C.appTo(g.$content),
+ A.hide(),
+ l.setDefaultMetric(b.binaryPrefix),
+ u.sub("location.changed", Y),
+ u.sub("location.refreshed", Z),
+ u.sub("resize", U),
+ U();
+ };
+ V(),
+ (e.exports = {
+ $el: C,
+ setItems: j,
+ changeItems: F,
+ setLocation: Y,
+ setHint: q,
+ getModes: P,
+ getMode: z,
+ setMode: L,
+ getSizes: $,
+ getSize: H,
+ setSize: O,
+ });
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.isNum,
+ o = {
+ t: 1e3,
+ k: 1e3,
+ u: ["B", "KB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB"],
+ },
+ a = {
+ t: 1024,
+ k: 1024,
+ u: ["B", "KiB", "MiB", "GiB", "TiB", "PiB", "EiB", "ZiB", "YiB"],
+ },
+ s = o,
+ c = [
+ [/YYYY/, "Y", 4],
+ [/YY/, "Y", 2],
+ [/Y/, "Y", 0],
+ [/MM/, "M", 2],
+ [/M/, "M", 0],
+ [/DD/, "D", 2],
+ [/D/, "D", 0],
+ [/HH/, "H", 2],
+ [/H/, "H", 0],
+ [/mm/, "m", 2],
+ [/m/, "m", 0],
+ [/ss/, "s", 2],
+ [/s/, "s", 0],
+ ],
+ u = "YYYY-MM-DD HH:mm",
+ l = function(e) {
+ s = e ? a : o;
+ },
+ f = function(e, t) {
+ if (((t = t || s), !i(e) || e < 0)) return "";
+ for (var n = 0, r = t.u.length - 1; e >= t.t && n < r;)
+ (e /= t.k), (n += 1);
+ return (
+ (n <= 1 ? Math.round(e) : e.toFixed(1)).toString() + " " + t.u[n]
+ );
+ },
+ d = function(e) {
+ u = e;
+ },
+ p = function(e, t) {
+ var n = String(e);
+ return t && (n = ("000" + n).substr(-t)), n;
+ },
+ h = function(e, t) {
+ if (!e || !i(e)) return "";
+ t = t || u;
+ var n = new Date(e),
+ r = {
+ Y: n.getFullYear(),
+ M: n.getMonth() + 1,
+ D: n.getDate(),
+ H: n.getHours(),
+ m: n.getMinutes(),
+ s: n.getSeconds(),
+ };
+ return (
+ c.forEach(function(e) {
+ t = t.replace(e[0], p(r[e[1]], e[2]));
+ }),
+ t
+ );
+ };
+ e.exports = {
+ setDefaultMetric: l,
+ formatSize: f,
+ setDefaultDateFormat: d,
+ formatDate: h,
+ };
+ },
+ function(e, t, n) {
+ (function(t) {
+ "use strict";
+ var r = n(2),
+ i = r.each,
+ o = r.values,
+ a = r.difference,
+ s = n(8),
+ c = s.request,
+ u = n(14),
+ l = n(12),
+ f = n(21),
+ d = t.window,
+ p = d.document,
+ h = Object.assign({ fastBrowsing: !0, unmanagedInNewWindow: !0 },
+ u.view
+ ),
+ g = h.fastBrowsing ? d.history : null,
+ m = /^.*:\/\/[^\/]*|[^\/]*$/g,
+ v = [
+ [/\/+/g, "/"],
+ [/ /g, "%20"],
+ [/!/g, "%21"],
+ [/#/g, "%23"],
+ [/\$/g, "%24"],
+ [/&/g, "%26"],
+ [/'/g, "%27"],
+ [/\(/g, "%28"],
+ [/\)/g, "%29"],
+ [/\*/g, "%2A"],
+ [/\+/g, "%2B"],
+ [/\,/g, "%2C"],
+ [/:/g, "%3A"],
+ [/;/g, "%3B"],
+ [/\=/g, "%3D"],
+ [/\?/g, "%3F"],
+ [/@/g, "%40"],
+ [/\[/g, "%5B"],
+ [/\]/g, "%5D"],
+ ],
+ b = null,
+ w = function(e) {
+ return v.reduce(function(e, t) {
+ return e.replace(t[0], t[1]);
+ }, e);
+ },
+ y = function(e) {
+ return e.replace(m, "");
+ },
+ x = (function() {
+ var e = "/a b",
+ t = p.createElement("a");
+ return (t.href = e), y(t.href) === e;
+ })(),
+ k = function(e) {
+ var t = p.createElement("a"),
+ n = void 0;
+ return (
+ (t.href = e),
+ (n = y(t.href)),
+ x && (n = encodeURIComponent(n).replace(/%2F/gi, "/")),
+ w(n)
+ );
+ },
+ _ = function() {
+ return p.domain;
+ },
+ C = function() {
+ return b;
+ },
+ S = function() {
+ return n(22).get(b);
+ },
+ A = function() {
+ return c({ action: "get", items: { href: b, what: 1 } }).then(
+ function(e) {
+ var t = n(22),
+ r = t.get(b);
+ if (e) {
+ var o = {};
+ i(e.items, function(e) {
+ var n = t.get(e);
+ o[n.absHref] = !0;
+ }),
+ i(r.content, function(e) {
+ o[e.absHref] || t.remove(e.absHref);
+ });
+ }
+ return r;
+ }
+ );
+ },
+ T = function() {
+ var e = S(),
+ t = o(e.content);
+ l.pub("location.beforeRefresh"),
+ A().then(function() {
+ var n = o(e.content),
+ r = a(n, t),
+ i = a(t, n);
+ l.pub("location.refreshed", e, r, i);
+ });
+ },
+ E = function(e, t) {
+ l.pub("location.beforeChange"),
+ (e = k(e)),
+ b !== e &&
+ ((b = e),
+ g &&
+ (t ?
+ g.replaceState({ absHref: b }, "", b) :
+ g.pushState({ absHref: b }, "", b)));
+ var n = S();
+ n.isLoaded ?
+ (l.pub("location.changed", n), T()) :
+ (f.set("loading..."),
+ A().then(function() {
+ (n.isLoaded = !0), f.set(), l.pub("location.changed", n);
+ }));
+ },
+ M = function(e, t) {
+ e.attr("href", t.absHref),
+ g &&
+ t.isFolder() &&
+ t.isManaged &&
+ e.on("click", function(e) {
+ return E(t.absHref), e.preventDefault(), !1;
+ }),
+ h.unmanagedInNewWindow &&
+ !t.isManaged &&
+ e.attr("target", "_blank");
+ },
+ D = function(e) {
+ e.state && e.state.absHref && E(e.state.absHref, !0);
+ };
+ (d.onpopstate = g ? D : null),
+ (e.exports = {
+ forceEncoding: w,
+ getDomain: _,
+ getAbsHref: C,
+ getItem: S,
+ setLocation: E,
+ refresh: T,
+ setLink: M,
+ });
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.dom,
+ o = n(17),
+ a = function() {
+ var e = i('<div id="notification"></div>').hide().appTo(o.$root),
+ t = function(t) {
+ t ? e.html(t).show() : e.hide();
+ };
+ return { set: t };
+ };
+ e.exports = a();
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.keys,
+ o = r.each,
+ a = r.filter,
+ s = r.sortBy,
+ c = r.isStr,
+ u = r.isNum,
+ l = n(8),
+ f = n(20),
+ d = n(14),
+ p = n(23),
+ h = /\/$/,
+ g = /^(.*\/)([^\/]+\/?)$/,
+ m = {},
+ v = function(e, t) {
+ return c(e) && e.startsWith(t);
+ },
+ b = function(e) {
+ e = e.replace(h, "");
+ try {
+ e = decodeURIComponent(e);
+ } catch (e) {}
+ return e;
+ },
+ w = function(e) {
+ if ("/" === e) return { parent: null, name: "/" };
+ var t = g.exec(e);
+ if (!t) return null;
+ var n = { parent: t[1], name: t[2] };
+ return n.parent && !v(n.parent, d.rootHref) && (n.parent = null), n;
+ },
+ y = function(e) {
+ if (c(e)) e = { href: e };
+ else if (!e || !c(e.href)) return null;
+ var t = f.forceEncoding(e.href);
+ if (!v(t, d.rootHref)) return null;
+ var n = m[t] || _(t);
+ return (
+ u(e.time) && (n.time = e.time),
+ u(e.size) && (n.size = e.size),
+ e.managed && (n.isManaged = !0),
+ e.fetched && (n.isContentFetched = !0),
+ n
+ );
+ },
+ x = function e(t) {
+ t = f.forceEncoding(t);
+ var n = m[t];
+ n &&
+ (delete m[t],
+ n.parent && delete n.parent.content[n.absHref],
+ o(n.content, function(t) {
+ e(t.absHref);
+ }));
+ },
+ k = function(e) {
+ return new Promise(function(t) {
+ var n = y(e);
+ n.isContentFetched ?
+ t(n) :
+ l
+ .request({
+ action: "get",
+ items: { href: n.absHref, what: 1 },
+ })
+ .then(function(e) {
+ e.items &&
+ o(e.items, function(e) {
+ y(e);
+ }),
+ t(n);
+ });
+ });
+ },
+ _ = function e(t) {
+ var n = w(t),
+ r = Object.assign(Object.create(e.prototype), {
+ absHref: t,
+ type: p.getType(t),
+ label: b("/" === t ? f.getDomain() : n.name),
+ time: null,
+ size: null,
+ parent: null,
+ isManaged: null,
+ content: {},
+ });
+ return (
+ (m[t] = r),
+ n.parent &&
+ ((r.parent = y(n.parent)),
+ (r.parent.content[r.absHref] = r),
+ i(r.parent.content).length > 1 &&
+ (r.parent.isContentFetched = !0)),
+ r
+ );
+ };
+ (_.prototype = {
+ constructor: _,
+ isFolder: function() {
+ return h.test(this.absHref);
+ },
+ isCurrentFolder: function() {
+ return this.absHref === f.getAbsHref();
+ },
+ isInCurrentFolder: function() {
+ return !!this.parent && this.parent.isCurrentFolder();
+ },
+ isCurrentParentFolder: function() {
+ var e = y(f.getAbsHref());
+ return !!e && this === e.parent;
+ },
+ isDomain: function() {
+ return "/" === this.absHref;
+ },
+ isRoot: function() {
+ return this.absHref === d.rootHref;
+ },
+ isEmpty: function() {
+ return 0 === i(this.content).length;
+ },
+ fetchContent: function() {
+ return k(this.absHref);
+ },
+ getCrumb: function() {
+ for (var e = this, t = [e]; e.parent;)(e = e.parent), t.unshift(e);
+ return t;
+ },
+ getSubfolders: function() {
+ return s(
+ a(this.content, function(e) {
+ return e.isFolder();
+ }),
+ function(e) {
+ return e.label.toLowerCase();
+ }
+ );
+ },
+ getStats: function() {
+ var e = 0,
+ t = 0;
+ o(this.content, function(n) {
+ n.isFolder() ? (e += 1) : (t += 1);
+ });
+ for (var n = 0, r = this; r.parent;)(n += 1), (r = r.parent);
+ return { folders: e, files: t, depth: n };
+ },
+ }),
+ (e.exports = { get: y, remove: x });
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.each,
+ o = r.map,
+ a = n(7),
+ s = /\/$/,
+ c = {},
+ u = function(e) {
+ return e.replace(/[\-\[\]\/\{\}\(\)\+\?\.\\\^\$]/g, "\\$&");
+ },
+ l = function(e) {
+ i(e, function(e, t) {
+ var n =
+ "^(" +
+ o(e, function(e) {
+ return "(" + u(e).replace(/\*/g, ".*") + ")";
+ }).join("|") +
+ ")$";
+ c[t] = new RegExp(n, "i");
+ });
+ },
+ f = function(e) {
+ if (s.test(e)) return "folder";
+ var t = e.lastIndexOf("/"),
+ n = t >= 0 ? e.substr(t + 1) : e,
+ r = void 0;
+ return (
+ i(c, function(e, t) {
+ c[t].test(n) && (r = t);
+ }),
+ r ? r : "file"
+ );
+ };
+ l(Object.assign({}, a.types)), (e.exports = { getType: f });
+ },
+ function(e, t, n) {
+ (function(e) {
+ "use strict";
+ var t = n(12),
+ r = n(20),
+ i = n(14),
+ o = e.window,
+ a = Object.assign({ enabled: !1, interval: 5e3 }, i.autorefresh),
+ s = null,
+ c = function() {
+ r.refresh();
+ },
+ u = function() {
+ o.clearTimeout(s);
+ },
+ l = function() {
+ o.clearTimeout(s), (s = o.setTimeout(c, a.interval));
+ },
+ f = function() {
+ a.enabled &&
+ ((a.interval = Math.max(1e3, a.interval)),
+ t.sub("location.beforeChange", u),
+ t.sub("location.beforeRefresh", u),
+ t.sub("location.changed", l),
+ t.sub("location.refreshed", l));
+ };
+ f();
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.each,
+ o = r.dom,
+ a = n(13),
+ s = n(14),
+ c = Object.assign({ enabled: !1 }, s.contextmenu),
+ u = '<div id="cm-overlay"></div>',
+ l = '<div class="cm-panel"><ul></ul></div>',
+ f = '<li class="cm-sep"></li>',
+ d =
+ '<li class="cm-entry"><span class="cm-icon"><img/></span><span class="cm-text"></span></li>',
+ p = '<li class="cm-label"><span class="cm-text"></span></li>',
+ h = function(e) {
+ for (; !e._cmId && e.parentNode;) e = e.parentNode;
+ return e._cmId;
+ },
+ g = function(e) {
+ var t = o(u),
+ n = function(n) {
+ n.stopPropagation(), n.preventDefault();
+ var r = h(n.target);
+ (n.target !== t[0] && void 0 === r) || (t.rm(), e(r));
+ };
+ return t.on("contextmenu", n).on("click", n);
+ },
+ m = function(e) {
+ var t = o(l),
+ n = t.find("ul"),
+ r = void 0;
+ return (
+ i(e, function(e) {
+ "-" === e.type ?
+ o(f).appTo(n) :
+ "l" === e.type ?
+ o(p).appTo(n).find(".cm-text").text(e.text) :
+ "e" === e.type &&
+ ((r = o(d).appTo(n)),
+ (r[0]._cmId = e.id),
+ r.find(".cm-text").text(e.text),
+ e.icon ?
+ r.find(".cm-icon img").attr("src", a.icon(e.icon)) :
+ r.find(".cm-icon").addCls("no-icon"));
+ }),
+ t
+ );
+ },
+ v = function(e, t, n, r) {
+ var i = 4;
+ t.css({ left: 0, top: 0, opacity: 0 }), e.show();
+ var o = e[0].getBoundingClientRect(),
+ a = t[0].getBoundingClientRect(),
+ s = o.left,
+ c = o.top,
+ u = o.width,
+ l = o.height,
+ f = a.width,
+ d = a.height,
+ p = n,
+ h = r;
+ f > u - 2 * i && ((p = i), (f = u - 2 * i)),
+ d > l - 2 * i && ((h = i), (d = l - 2 * i)),
+ p < s + i && (p = s + i),
+ p + f > s + u - i && (p = s + u - i - f),
+ h < c + i && (h = c + i),
+ h + d > c + l - i && (h = c + l - i - d),
+ t.css({
+ left: p + "px",
+ top: h + "px",
+ width: f + "px",
+ height: d + "px",
+ opacity: 1,
+ });
+ },
+ b = function(e, t, n, r) {
+ var i = g(r),
+ o = m(n);
+ i.hide().app(o).appTo("body"), v(i, o, e, t);
+ },
+ w = function() {
+ if (c.enabled) {
+ var e = [
+ { type: "e", id: "e1", text: "testing context menus" },
+ { type: "e", id: "e2", text: "another entry" },
+ { type: "e", id: "e3", text: "one with icon", icon: "folder" },
+ { type: "-" },
+ { type: "e", id: "e4", text: "one with icon", icon: "x" },
+ { type: "e", id: "e5", text: "one with icon", icon: "img" },
+ ];
+ o("#view").on("contextmenu", function(t) {
+ t.preventDefault(), b(t.pageX, t.pageY, e);
+ });
+ }
+ };
+ w();
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.each,
+ o = r.dom,
+ a = n(12),
+ s = n(20),
+ c = n(13),
+ u = n(14),
+ l = n(17),
+ f = Object.assign({ enabled: !1 }, u.crumb),
+ d = '<div id="crumbbar"></div>',
+ p =
+ '<a class="crumb">\n <img class="sep" src="' +
+ c.image("crumb") +
+ '" alt=">"/>\n <span class="label"></span>\n </a>',
+ h =
+ '<img class="hint" src="' +
+ c.icon("folder-page") +
+ '" alt="has index page"/>',
+ g = function(e) {
+ var t = o(p);
+ return (
+ s.setLink(t, e),
+ t.find(".label").text(e.label),
+ e.isCurrentFolder() && t.addCls("active"),
+ e.isManaged || t.app(o(h)),
+ (e._$crumb = t),
+ (t[0]._item = e),
+ t
+ );
+ },
+ m = function(e) {
+ var t = e._$crumb,
+ n = o("#crumbbar");
+ t && t.parent()[0] === n[0] ?
+ (n.children().rmCls("active"), t.addCls("active")) :
+ (n.clr(),
+ i(e.getCrumb(), function(e) {
+ n.app(g(e));
+ }));
+ },
+ v = function() {
+ f.enabled && (o(d).appTo(l.$flowbar), a.sub("location.changed", m));
+ };
+ v();
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(28),
+ i = n(2),
+ o = i.each,
+ a = i.dom,
+ s = n(8),
+ c = n(12),
+ u = n(14),
+ l = Object.assign({ enabled: !1 }, u.custom),
+ f = function(e, t) {
+ var n = a("#content-" + t);
+ if (e && e[t].content) {
+ var i = e[t].content;
+ "md" === e[t].type && (i = r(i)), n.html(i).show();
+ } else n.hide();
+ },
+ d = function(e) {
+ s.request({ action: "get", custom: e.absHref }).then(function(e) {
+ var t = e && e.custom;
+ o(["header", "footer"], function(e) {
+ return f(t, e);
+ });
+ });
+ },
+ p = function() {
+ l.enabled &&
+ (a('<div id="content-header"></div>').hide().preTo("#content"),
+ a('<div id="content-footer"></div>').hide().appTo("#content"),
+ c.sub("location.changed", d));
+ };
+ p();
+ },
+ function(e, t, n) {
+ (function(t) {
+ !(function(t) {
+ "use strict";
+
+ function n(e) {
+ (this.tokens = []),
+ (this.tokens.links = Object.create(null)),
+ (this.options = e || b.defaults),
+ (this.rules = w.normal),
+ this.options.pedantic ?
+ (this.rules = w.pedantic) :
+ this.options.gfm &&
+ (this.options.tables ?
+ (this.rules = w.tables) :
+ (this.rules = w.gfm));
+ }
+
+ function r(e, t) {
+ if (
+ ((this.options = t || b.defaults),
+ (this.links = e),
+ (this.rules = y.normal),
+ (this.renderer = this.options.renderer || new i()),
+ (this.renderer.options = this.options), !this.links)
+ )
+ throw new Error("Tokens array requires a `links` property.");
+ this.options.pedantic ?
+ (this.rules = y.pedantic) :
+ this.options.gfm &&
+ (this.options.breaks ?
+ (this.rules = y.breaks) :
+ (this.rules = y.gfm));
+ }
+
+ function i(e) {
+ this.options = e || b.defaults;
+ }
+
+ function o() {}
+
+ function a(e) {
+ (this.tokens = []),
+ (this.token = null),
+ (this.options = e || b.defaults),
+ (this.options.renderer = this.options.renderer || new i()),
+ (this.renderer = this.options.renderer),
+ (this.renderer.options = this.options),
+ (this.slugger = new s());
+ }
+
+ function s() {
+ this.seen = {};
+ }
+
+ function c(e, t) {
+ if (t) {
+ if (c.escapeTest.test(e))
+ return e.replace(c.escapeReplace, function(e) {
+ return c.replacements[e];
+ });
+ } else if (c.escapeTestNoEncode.test(e))
+ return e.replace(c.escapeReplaceNoEncode, function(e) {
+ return c.replacements[e];
+ });
+ return e;
+ }
+
+ function u(e) {
+ return e.replace(
+ /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi,
+ function(e, t) {
+ return (
+ (t = t.toLowerCase()),
+ "colon" === t ?
+ ":" :
+ "#" === t.charAt(0) ?
+ "x" === t.charAt(1) ?
+ String.fromCharCode(parseInt(t.substring(2), 16)) :
+ String.fromCharCode(+t.substring(1)) :
+ ""
+ );
+ }
+ );
+ }
+
+ function l(e, t) {
+ return (
+ (e = e.source || e),
+ (t = t || ""), {
+ replace: function(t, n) {
+ return (
+ (n = n.source || n),
+ (n = n.replace(/(^|[^\[])\^/g, "$1")),
+ (e = e.replace(t, n)),
+ this
+ );
+ },
+ getRegex: function() {
+ return new RegExp(e, t);
+ },
+ }
+ );
+ }
+
+ function f(e, t, n) {
+ if (e) {
+ try {
+ var r = decodeURIComponent(u(n))
+ .replace(/[^\w:]/g, "")
+ .toLowerCase();
+ } catch (e) {
+ return null;
+ }
+ if (
+ 0 === r.indexOf("javascript:") ||
+ 0 === r.indexOf("vbscript:") ||
+ 0 === r.indexOf("data:")
+ )
+ return null;
+ }
+ t && !k.test(n) && (n = d(t, n));
+ try {
+ n = encodeURI(n).replace(/%25/g, "%");
+ } catch (e) {
+ return null;
+ }
+ return n;
+ }
+
+ function d(e, t) {
+ return (
+ x[" " + e] ||
+ (/^[^:]+:\/*[^\/]*$/.test(e) ?
+ (x[" " + e] = e + "/") :
+ (x[" " + e] = m(e, "/", !0))),
+ (e = x[" " + e]),
+ "//" === t.slice(0, 2) ?
+ e.replace(/:[\s\S]*/, ":") + t :
+ "/" === t.charAt(0) ?
+ e.replace(/(:\/*[^\/]*)[\s\S]*/, "$1") + t :
+ e + t
+ );
+ }
+
+ function p() {}
+
+ function h(e) {
+ for (var t, n, r = 1; r < arguments.length; r++) {
+ t = arguments[r];
+ for (n in t)
+ Object.prototype.hasOwnProperty.call(t, n) && (e[n] = t[n]);
+ }
+ return e;
+ }
+
+ function g(e, t) {
+ var n = e.replace(/\|/g, function(e, t, n) {
+ for (var r = !1, i = t; --i >= 0 && "\\" === n[i];) r = !r;
+ return r ? "|" : " |";
+ }),
+ r = n.split(/ \|/),
+ i = 0;
+ if (r.length > t) r.splice(t);
+ else
+ for (; r.length < t;) r.push("");
+ for (; i < r.length; i++) r[i] = r[i].trim().replace(/\\\|/g, "|");
+ return r;
+ }
+
+ function m(e, t, n) {
+ if (0 === e.length) return "";
+ for (var r = 0; r < e.length;) {
+ var i = e.charAt(e.length - r - 1);
+ if (i !== t || n) {
+ if (i === t || !n) break;
+ r++;
+ } else r++;
+ }
+ return e.substr(0, e.length - r);
+ }
+
+ function v(e, t) {
+ if (e.indexOf(t[1]) === -1) return -1;
+ for (var n = 0, r = 0; r < e.length; r++)
+ if ("\\" === e[r]) r++;
+ else if (e[r] === t[0]) n++;
+ else if (e[r] === t[1] && (n--, n < 0)) return r;
+ return -1;
+ }
+
+ function b(e, t, r) {
+ if ("undefined" == typeof e || null === e)
+ throw new Error("marked(): input parameter is undefined or null");
+ if ("string" != typeof e)
+ throw new Error(
+ "marked(): input parameter is of type " +
+ Object.prototype.toString.call(e) +
+ ", string expected"
+ );
+ if (r || "function" == typeof t) {
+ r || ((r = t), (t = null)), (t = h({}, b.defaults, t || {}));
+ var i,
+ o,
+ s = t.highlight,
+ u = 0;
+ try {
+ i = n.lex(e, t);
+ } catch (e) {
+ return r(e);
+ }
+ o = i.length;
+ var l = function(e) {
+ if (e) return (t.highlight = s), r(e);
+ var n;
+ try {
+ n = a.parse(i, t);
+ } catch (t) {
+ e = t;
+ }
+ return (t.highlight = s), e ? r(e) : r(null, n);
+ };
+ if (!s || s.length < 3) return l();
+ if ((delete t.highlight, !o)) return l();
+ for (; u < i.length; u++)
+ !(function(e) {
+ return "code" !== e.type ?
+ --o || l() :
+ s(e.text, e.lang, function(t, n) {
+ return t ?
+ l(t) :
+ null == n || n === e.text ?
+ --o || l() :
+ ((e.text = n), (e.escaped = !0), void(--o || l()));
+ });
+ })(i[u]);
+ } else
+ try {
+ return t && (t = h({}, b.defaults, t)), a.parse(n.lex(e, t), t);
+ } catch (e) {
+ if (
+ ((e.message +=
+ "\nPlease report this to https://github.com/markedjs/marked."),
+ (t || b.defaults).silent)
+ )
+ return (
+ "<p>An error occurred:</p><pre>" +
+ c(e.message + "", !0) +
+ "</pre>"
+ );
+ throw e;
+ }
+ }
+ var w = {
+ newline: /^\n+/,
+ code: /^( {4}[^\n]+\n*)+/,
+ fences: p,
+ hr: /^ {0,3}((?:- *){3,}|(?:_ *){3,}|(?:\* *){3,})(?:\n+|$)/,
+ heading: /^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/,
+ nptable: p,
+ blockquote: /^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,
+ list: /^( {0,3})(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,
+ html: "^ {0,3}(?:<(script|pre|style)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?\\?>\\n*|<![A-Z][\\s\\S]*?>\\n*|<!\\[CDATA\\[[\\s\\S]*?\\]\\]>\\n*|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:\\n{2,}|$)|<(?!script|pre|style)([a-z][\\w-]*)(?:attribute)*? */?>(?=\\h*\\n)[\\s\\S]*?(?:\\n{2,}|$)|</(?!script|pre|style)[a-z][\\w-]*\\s*>(?=\\h*\\n)[\\s\\S]*?(?:\\n{2,}|$))",
+ def: /^ {0,3}\[(label)\]: *\n? *<?([^\s>]+)>?(?:(?: +\n? *| *\n *)(title))? *(?:\n+|$)/,
+ table: p,
+ lheading: /^([^\n]+)\n *(=|-){2,} *(?:\n+|$)/,
+ paragraph: /^([^\n]+(?:\n(?!hr|heading|lheading| {0,3}>|<\/?(?:tag)(?: +|\n|\/?>)|<(?:script|pre|style|!--))[^\n]+)*)/,
+ text: /^[^\n]+/,
+ };
+ (w._label = /(?!\s*\])(?:\\[\[\]]|[^\[\]])+/),
+ (w._title = /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/),
+ (w.def = l(w.def)
+ .replace("label", w._label)
+ .replace("title", w._title)
+ .getRegex()),
+ (w.bullet = /(?:[*+-]|\d{1,9}\.)/),
+ (w.item = /^( *)(bull) ?[^\n]*(?:\n(?!\1bull ?)[^\n]*)*/),
+ (w.item = l(w.item, "gm").replace(/bull/g, w.bullet).getRegex()),
+ (w.list = l(w.list)
+ .replace(/bull/g, w.bullet)
+ .replace(
+ "hr",
+ "\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))"
+ )
+ .replace("def", "\\n+(?=" + w.def.source + ")")
+ .getRegex()),
+ (w._tag =
+ "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul"),
+ (w._comment = /<!--(?!-?>)[\s\S]*?-->/),
+ (w.html = l(w.html, "i")
+ .replace("comment", w._comment)
+ .replace("tag", w._tag)
+ .replace(
+ "attribute",
+ / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/
+ )
+ .getRegex()),
+ (w.paragraph = l(w.paragraph)
+ .replace("hr", w.hr)
+ .replace("heading", w.heading)
+ .replace("lheading", w.lheading)
+ .replace("tag", w._tag)
+ .getRegex()),
+ (w.blockquote = l(w.blockquote)
+ .replace("paragraph", w.paragraph)
+ .getRegex()),
+ (w.normal = h({}, w)),
+ (w.gfm = h({}, w.normal, {
+ fences: /^ {0,3}(`{3,}|~{3,})([^`\n]*)\n(?:|([\s\S]*?)\n)(?: {0,3}\1[~`]* *(?:\n+|$)|$)/,
+ paragraph: /^/,
+ heading: /^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/,
+ })),
+ (w.gfm.paragraph = l(w.paragraph)
+ .replace(
+ "(?!",
+ "(?!" +
+ w.gfm.fences.source.replace("\\1", "\\2") +
+ "|" +
+ w.list.source.replace("\\1", "\\3") +
+ "|"
+ )
+ .getRegex()),
+ (w.tables = h({}, w.gfm, {
+ nptable: /^ *([^|\n ].*\|.*)\n *([-:]+ *\|[-| :]*)(?:\n((?:.*[^>\n ].*(?:\n|$))*)\n*|$)/,
+ table: /^ *\|(.+)\n *\|?( *[-:]+[-| :]*)(?:\n((?: *[^>\n ].*(?:\n|$))*)\n*|$)/,
+ })),
+ (w.pedantic = h({}, w.normal, {
+ html: l(
+ "^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))"
+ )
+ .replace("comment", w._comment)
+ .replace(
+ /tag/g,
+ "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b"
+ )
+ .getRegex(),
+ def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
+ })),
+ (n.rules = w),
+ (n.lex = function(e, t) {
+ var r = new n(t);
+ return r.lex(e);
+ }),
+ (n.prototype.lex = function(e) {
+ return (
+ (e = e
+ .replace(/\r\n|\r/g, "\n")
+ .replace(/\t/g, " ")
+ .replace(/\u00a0/g, " ")
+ .replace(/\u2424/g, "\n")),
+ this.token(e, !0)
+ );
+ }),
+ (n.prototype.token = function(e, t) {
+ e = e.replace(/^ +$/gm, "");
+ for (var n, r, i, o, a, s, c, u, l, f, d, p, h, v, b, y; e;)
+ if (
+ ((i = this.rules.newline.exec(e)) &&
+ ((e = e.substring(i[0].length)),
+ i[0].length > 1 && this.tokens.push({ type: "space" })),
+ (i = this.rules.code.exec(e)))
+ )
+ (e = e.substring(i[0].length)),
+ (i = i[0].replace(/^ {4}/gm, "")),
+ this.tokens.push({
+ type: "code",
+ text: this.options.pedantic ? i : m(i, "\n"),
+ });
+ else if ((i = this.rules.fences.exec(e)))
+ (e = e.substring(i[0].length)),
+ this.tokens.push({
+ type: "code",
+ lang: i[2] ? i[2].trim() : i[2],
+ text: i[3] || "",
+ });
+ else if ((i = this.rules.heading.exec(e)))
+ (e = e.substring(i[0].length)),
+ this.tokens.push({
+ type: "heading",
+ depth: i[1].length,
+ text: i[2],
+ });
+ else if (
+ t &&
+ (i = this.rules.nptable.exec(e)) &&
+ ((s = {
+ type: "table",
+ header: g(i[1].replace(/^ *| *\| *$/g, "")),
+ align: i[2].replace(/^ *|\| *$/g, "").split(/ *\| */),
+ cells: i[3] ? i[3].replace(/\n$/, "").split("\n") : [],
+ }),
+ s.header.length === s.align.length)
+ ) {
+ for (
+ e = e.substring(i[0].length), d = 0; d < s.align.length; d++
+ )
+ /^ *-+: *$/.test(s.align[d]) ?
+ (s.align[d] = "right") :
+ /^ *:-+: *$/.test(s.align[d]) ?
+ (s.align[d] = "center") :
+ /^ *:-+ *$/.test(s.align[d]) ?
+ (s.align[d] = "left") :
+ (s.align[d] = null);
+ for (d = 0; d < s.cells.length; d++)
+ s.cells[d] = g(s.cells[d], s.header.length);
+ this.tokens.push(s);
+ } else if ((i = this.rules.hr.exec(e)))
+ (e = e.substring(i[0].length)),
+ this.tokens.push({ type: "hr" });
+ else if ((i = this.rules.blockquote.exec(e)))
+ (e = e.substring(i[0].length)),
+ this.tokens.push({ type: "blockquote_start" }),
+ (i = i[0].replace(/^ *> ?/gm, "")),
+ this.token(i, t),
+ this.tokens.push({ type: "blockquote_end" });
+ else if ((i = this.rules.list.exec(e))) {
+ for (
+ e = e.substring(i[0].length),
+ o = i[2],
+ v = o.length > 1,
+ c = {
+ type: "list_start",
+ ordered: v,
+ start: v ? +o : "",
+ loose: !1,
+ },
+ this.tokens.push(c),
+ i = i[0].match(this.rules.item),
+ u = [],
+ n = !1,
+ h = i.length,
+ d = 0; d < h; d++
+ )
+ (s = i[d]),
+ (f = s.length),
+ (s = s.replace(/^ *([*+-]|\d+\.) */, "")), ~s.indexOf("\n ") &&
+ ((f -= s.length),
+ (s = this.options.pedantic ?
+ s.replace(/^ {1,4}/gm, "") :
+ s.replace(
+ new RegExp("^ {1," + f + "}", "gm"),
+ ""
+ ))),
+ d !== h - 1 &&
+ ((a = w.bullet.exec(i[d + 1])[0]),
+ (o.length > 1 ?
+ 1 === a.length :
+ a.length > 1 ||
+ (this.options.smartLists && a !== o)) &&
+ ((e = i.slice(d + 1).join("\n") + e), (d = h - 1))),
+ (r = n || /\n\n(?!\s*$)/.test(s)),
+ d !== h - 1 &&
+ ((n = "\n" === s.charAt(s.length - 1)), r || (r = n)),
+ r && (c.loose = !0),
+ (b = /^\[[ xX]\] /.test(s)),
+ (y = void 0),
+ b &&
+ ((y = " " !== s[1]),
+ (s = s.replace(/^\[[ xX]\] +/, ""))),
+ (l = {
+ type: "list_item_start",
+ task: b,
+ checked: y,
+ loose: r,
+ }),
+ u.push(l),
+ this.tokens.push(l),
+ this.token(s, !1),
+ this.tokens.push({ type: "list_item_end" });
+ if (c.loose)
+ for (h = u.length, d = 0; d < h; d++) u[d].loose = !0;
+ this.tokens.push({ type: "list_end" });
+ } else if ((i = this.rules.html.exec(e)))
+ (e = e.substring(i[0].length)),
+ this.tokens.push({
+ type: this.options.sanitize ? "paragraph" : "html",
+ pre:
+ !this.options.sanitizer &&
+ ("pre" === i[1] ||
+ "script" === i[1] ||
+ "style" === i[1]),
+ text: i[0],
+ });
+ else if (t && (i = this.rules.def.exec(e)))
+ (e = e.substring(i[0].length)),
+ i[3] && (i[3] = i[3].substring(1, i[3].length - 1)),
+ (p = i[1].toLowerCase().replace(/\s+/g, " ")),
+ this.tokens.links[p] ||
+ (this.tokens.links[p] = { href: i[2], title: i[3] });
+ else if (
+ t &&
+ (i = this.rules.table.exec(e)) &&
+ ((s = {
+ type: "table",
+ header: g(i[1].replace(/^ *| *\| *$/g, "")),
+ align: i[2].replace(/^ *|\| *$/g, "").split(/ *\| */),
+ cells: i[3] ?
+ i[3].replace(/(?: *\| *)?\n$/, "").split("\n") :
+ [],
+ }),
+ s.header.length === s.align.length)
+ ) {
+ for (
+ e = e.substring(i[0].length), d = 0; d < s.align.length; d++
+ )
+ /^ *-+: *$/.test(s.align[d]) ?
+ (s.align[d] = "right") :
+ /^ *:-+: *$/.test(s.align[d]) ?
+ (s.align[d] = "center") :
+ /^ *:-+ *$/.test(s.align[d]) ?
+ (s.align[d] = "left") :
+ (s.align[d] = null);
+ for (d = 0; d < s.cells.length; d++)
+ s.cells[d] = g(
+ s.cells[d].replace(/^ *\| *| *\| *$/g, ""),
+ s.header.length
+ );
+ this.tokens.push(s);
+ } else if ((i = this.rules.lheading.exec(e)))
+ (e = e.substring(i[0].length)),
+ this.tokens.push({
+ type: "heading",
+ depth: "=" === i[2] ? 1 : 2,
+ text: i[1],
+ });
+ else if (t && (i = this.rules.paragraph.exec(e)))
+ (e = e.substring(i[0].length)),
+ this.tokens.push({
+ type: "paragraph",
+ text: "\n" === i[1].charAt(i[1].length - 1) ?
+ i[1].slice(0, -1) :
+ i[1],
+ });
+ else if ((i = this.rules.text.exec(e)))
+ (e = e.substring(i[0].length)),
+ this.tokens.push({ type: "text", text: i[0] });
+ else if (e)
+ throw new Error("Infinite loop on byte: " + e.charCodeAt(0));
+ return this.tokens;
+ });
+ var y = {
+ escape: /^\\([!"#$%&'()*+,\-.\/:;<=>?@\[\]\\^_`{|}~])/,
+ autolink: /^<(scheme:[^\s\x00-\x1f<>]*|email)>/,
+ url: p,
+ tag: "^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",
+ link: /^!?\[(label)\]\(href(?:\s+(title))?\s*\)/,
+ reflink: /^!?\[(label)\]\[(?!\s*\])((?:\\[\[\]]?|[^\[\]\\])+)\]/,
+ nolink: /^!?\[(?!\s*\])((?:\[[^\[\]]*\]|\\[\[\]]|[^\[\]])*)\](?:\[\])?/,
+ strong: /^__([^\s_])__(?!_)|^\*\*([^\s*])\*\*(?!\*)|^__([^\s][\s\S]*?[^\s])__(?!_)|^\*\*([^\s][\s\S]*?[^\s])\*\*(?!\*)/,
+ em: /^_([^\s_])_(?!_)|^\*([^\s*"<\[])\*(?!\*)|^_([^\s][\s\S]*?[^\s_])_(?!_|[^\spunctuation])|^_([^\s_][\s\S]*?[^\s])_(?!_|[^\spunctuation])|^\*([^\s"<\[][\s\S]*?[^\s*])\*(?!\*)|^\*([^\s*"<\[][\s\S]*?[^\s])\*(?!\*)/,
+ code: /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,
+ br: /^( {2,}|\\)\n(?!\s*$)/,
+ del: p,
+ text: /^(`+|[^`])[\s\S]*?(?=[\\<!\[`*]|\b_| {2,}\n|$)/,
+ };
+ (y._punctuation = "!\"#$%&'()*+,\\-./:;<=>?@\\[^_{|}~"),
+ (y.em = l(y.em)
+ .replace(/punctuation/g, y._punctuation)
+ .getRegex()),
+ (y._escapes = /\\([!"#$%&'()*+,\-.\/:;<=>?@\[\]\\^_`{|}~])/g),
+ (y._scheme = /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/),
+ (y._email = /[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/),
+ (y.autolink = l(y.autolink)
+ .replace("scheme", y._scheme)
+ .replace("email", y._email)
+ .getRegex()),
+ (y._attribute = /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/),
+ (y.tag = l(y.tag)
+ .replace("comment", w._comment)
+ .replace("attribute", y._attribute)
+ .getRegex()),
+ (y._label = /(?:\[[^\[\]]*\]|\\[\[\]]?|`[^`]*`|[^\[\]\\])*?/),
+ (y._href = /\s*(<(?:\\[<>]?|[^\s<>\\])*>|[^\s\x00-\x1f]*)/),
+ (y._title = /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/),
+ (y.link = l(y.link)
+ .replace("label", y._label)
+ .replace("href", y._href)
+ .replace("title", y._title)
+ .getRegex()),
+ (y.reflink = l(y.reflink).replace("label", y._label).getRegex()),
+ (y.normal = h({}, y)),
+ (y.pedantic = h({}, y.normal, {
+ strong: /^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,
+ em: /^_(?=\S)([\s\S]*?\S)_(?!_)|^\*(?=\S)([\s\S]*?\S)\*(?!\*)/,
+ link: l(/^!?\[(label)\]\((.*?)\)/)
+ .replace("label", y._label)
+ .getRegex(),
+ reflink: l(/^!?\[(label)\]\s*\[([^\]]*)\]/)
+ .replace("label", y._label)
+ .getRegex(),
+ })),
+ (y.gfm = h({}, y.normal, {
+ escape: l(y.escape).replace("])", "~|])").getRegex(),
+ _extended_email: /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,
+ url: /^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,
+ _backpedal: /(?:[^?!.,:;*_~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_~)]+(?!$))+/,
+ del: /^~+(?=\S)([\s\S]*?\S)~+/,
+ text: l(y.text)
+ .replace("]|", "~]|")
+ .replace(
+ "|$",
+ "|https?://|ftp://|www\\.|[a-zA-Z0-9.!#$%&'*+/=?^_`{\\|}~-]+@|$"
+ )
+ .getRegex(),
+ })),
+ (y.gfm.url = l(y.gfm.url, "i")
+ .replace("email", y.gfm._extended_email)
+ .getRegex()),
+ (y.breaks = h({}, y.gfm, {
+ br: l(y.br).replace("{2,}", "*").getRegex(),
+ text: l(y.gfm.text).replace("{2,}", "*").getRegex(),
+ })),
+ (r.rules = y),
+ (r.output = function(e, t, n) {
+ var i = new r(t, n);
+ return i.output(e);
+ }),
+ (r.prototype.output = function(e) {
+ for (var t, n, i, o, a, s, u = ""; e;)
+ if ((a = this.rules.escape.exec(e)))
+ (e = e.substring(a[0].length)), (u += c(a[1]));
+ else if ((a = this.rules.tag.exec(e)))
+ !this.inLink && /^<a /i.test(a[0]) ?
+ (this.inLink = !0) :
+ this.inLink && /^<\/a>/i.test(a[0]) && (this.inLink = !1), !this.inRawBlock &&
+ /^<(pre|code|kbd|script)(\s|>)/i.test(a[0]) ?
+ (this.inRawBlock = !0) :
+ this.inRawBlock &&
+ /^<\/(pre|code|kbd|script)(\s|>)/i.test(a[0]) &&
+ (this.inRawBlock = !1),
+ (e = e.substring(a[0].length)),
+ (u += this.options.sanitize ?
+ this.options.sanitizer ?
+ this.options.sanitizer(a[0]) :
+ c(a[0]) :
+ a[0]);
+ else if ((a = this.rules.link.exec(e))) {
+ var l = v(a[2], "()");
+ if (l > -1) {
+ var f = a[2].length - l;
+ (a[2] = a[2].substring(0, l)),
+ (a[0] = a[0].substring(0, a[0].length - f));
+ }
+ (e = e.substring(a[0].length)),
+ (this.inLink = !0),
+ (i = a[2]),
+ this.options.pedantic ?
+ ((t = /^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(i)),
+ t ? ((i = t[1]), (o = t[3])) : (o = "")) :
+ (o = a[3] ? a[3].slice(1, -1) : ""),
+ (i = i.trim().replace(/^<([\s\S]*)>$/, "$1")),
+ (u += this.outputLink(a, {
+ href: r.escapes(i),
+ title: r.escapes(o),
+ })),
+ (this.inLink = !1);
+ } else if (
+ (a = this.rules.reflink.exec(e)) ||
+ (a = this.rules.nolink.exec(e))
+ ) {
+ if (
+ ((e = e.substring(a[0].length)),
+ (t = (a[2] || a[1]).replace(/\s+/g, " ")),
+ (t = this.links[t.toLowerCase()]), !t || !t.href)
+ ) {
+ (u += a[0].charAt(0)), (e = a[0].substring(1) + e);
+ continue;
+ }
+ (this.inLink = !0),
+ (u += this.outputLink(a, t)),
+ (this.inLink = !1);
+ } else if ((a = this.rules.strong.exec(e)))
+ (e = e.substring(a[0].length)),
+ (u += this.renderer.strong(
+ this.output(a[4] || a[3] || a[2] || a[1])
+ ));
+ else if ((a = this.rules.em.exec(e)))
+ (e = e.substring(a[0].length)),
+ (u += this.renderer.em(
+ this.output(a[6] || a[5] || a[4] || a[3] || a[2] || a[1])
+ ));
+ else if ((a = this.rules.code.exec(e)))
+ (e = e.substring(a[0].length)),
+ (u += this.renderer.codespan(c(a[2].trim(), !0)));
+ else if ((a = this.rules.br.exec(e)))
+ (e = e.substring(a[0].length)), (u += this.renderer.br());
+ else if ((a = this.rules.del.exec(e)))
+ (e = e.substring(a[0].length)),
+ (u += this.renderer.del(this.output(a[1])));
+ else if ((a = this.rules.autolink.exec(e)))
+ (e = e.substring(a[0].length)),
+ "@" === a[2] ?
+ ((n = c(this.mangle(a[1]))), (i = "mailto:" + n)) :
+ ((n = c(a[1])), (i = n)),
+ (u += this.renderer.link(i, null, n));
+ else if (this.inLink || !(a = this.rules.url.exec(e))) {
+ if ((a = this.rules.text.exec(e)))
+ (e = e.substring(a[0].length)),
+ (u += this.inRawBlock ?
+ this.renderer.text(a[0]) :
+ this.renderer.text(c(this.smartypants(a[0]))));
+ else if (e)
+ throw new Error(
+ "Infinite loop on byte: " + e.charCodeAt(0)
+ );
+ } else {
+ if ("@" === a[2])(n = c(a[0])), (i = "mailto:" + n);
+ else {
+ do(s = a[0]), (a[0] = this.rules._backpedal.exec(a[0])[0]);
+ while (s !== a[0]);
+ (n = c(a[0])), (i = "www." === a[1] ? "http://" + n : n);
+ }
+ (e = e.substring(a[0].length)),
+ (u += this.renderer.link(i, null, n));
+ }
+ return u;
+ }),
+ (r.escapes = function(e) {
+ return e ? e.replace(r.rules._escapes, "$1") : e;
+ }),
+ (r.prototype.outputLink = function(e, t) {
+ var n = t.href,
+ r = t.title ? c(t.title) : null;
+ return "!" !== e[0].charAt(0) ?
+ this.renderer.link(n, r, this.output(e[1])) :
+ this.renderer.image(n, r, c(e[1]));
+ }),
+ (r.prototype.smartypants = function(e) {
+ return this.options.smartypants ?
+ e
+ .replace(/---/g, "—")
+ .replace(/--/g, "–")
+ .replace(/(^|[-\u2014\/(\[{"\s])'/g, "$1‘")
+ .replace(/'/g, "’")
+ .replace(/(^|[-\u2014\/(\[{\u2018\s])"/g, "$1“")
+ .replace(/"/g, "”")
+ .replace(/\.{3}/g, "…") :
+ e;
+ }),
+ (r.prototype.mangle = function(e) {
+ if (!this.options.mangle) return e;
+ for (var t, n = "", r = e.length, i = 0; i < r; i++)
+ (t = e.charCodeAt(i)),
+ Math.random() > 0.5 && (t = "x" + t.toString(16)),
+ (n += "&#" + t + ";");
+ return n;
+ }),
+ (i.prototype.code = function(e, t, n) {
+ var r = (t || "").match(/\S*/)[0];
+ if (this.options.highlight) {
+ var i = this.options.highlight(e, r);
+ null != i && i !== e && ((n = !0), (e = i));
+ }
+ return r ?
+ '<pre><code class="' +
+ this.options.langPrefix +
+ c(r, !0) +
+ '">' +
+ (n ? e : c(e, !0)) +
+ "</code></pre>\n" :
+ "<pre><code>" + (n ? e : c(e, !0)) + "</code></pre>";
+ }),
+ (i.prototype.blockquote = function(e) {
+ return "<blockquote>\n" + e + "</blockquote>\n";
+ }),
+ (i.prototype.html = function(e) {
+ return e;
+ }),
+ (i.prototype.heading = function(e, t, n, r) {
+ return this.options.headerIds ?
+ "<h" +
+ t +
+ ' id="' +
+ this.options.headerPrefix +
+ r.slug(n) +
+ '">' +
+ e +
+ "</h" +
+ t +
+ ">\n" :
+ "<h" + t + ">" + e + "</h" + t + ">\n";
+ }),
+ (i.prototype.hr = function() {
+ return this.options.xhtml ? "<hr/>\n" : "<hr>\n";
+ }),
+ (i.prototype.list = function(e, t, n) {
+ var r = t ? "ol" : "ul",
+ i = t && 1 !== n ? ' start="' + n + '"' : "";
+ return "<" + r + i + ">\n" + e + "</" + r + ">\n";
+ }),
+ (i.prototype.listitem = function(e) {
+ return "<li>" + e + "</li>\n";
+ }),
+ (i.prototype.checkbox = function(e) {
+ return (
+ "<input " +
+ (e ? 'checked="" ' : "") +
+ 'disabled="" type="checkbox"' +
+ (this.options.xhtml ? " /" : "") +
+ "> "
+ );
+ }),
+ (i.prototype.paragraph = function(e) {
+ return "<p>" + e + "</p>\n";
+ }),
+ (i.prototype.table = function(e, t) {
+ return (
+ t && (t = "<tbody>" + t + "</tbody>"),
+ "<table>\n<thead>\n" + e + "</thead>\n" + t + "</table>\n"
+ );
+ }),
+ (i.prototype.tablerow = function(e) {
+ return "<tr>\n" + e + "</tr>\n";
+ }),
+ (i.prototype.tablecell = function(e, t) {
+ var n = t.header ? "th" : "td",
+ r = t.align ?
+ "<" + n + ' align="' + t.align + '">' :
+ "<" + n + ">";
+ return r + e + "</" + n + ">\n";
+ }),
+ (i.prototype.strong = function(e) {
+ return "<strong>" + e + "</strong>";
+ }),
+ (i.prototype.em = function(e) {
+ return "<em>" + e + "</em>";
+ }),
+ (i.prototype.codespan = function(e) {
+ return "<code>" + e + "</code>";
+ }),
+ (i.prototype.br = function() {
+ return this.options.xhtml ? "<br/>" : "<br>";
+ }),
+ (i.prototype.del = function(e) {
+ return "<del>" + e + "</del>";
+ }),
+ (i.prototype.link = function(e, t, n) {
+ if (
+ ((e = f(this.options.sanitize, this.options.baseUrl, e)),
+ null === e)
+ )
+ return n;
+ var r = '<a href="' + c(e) + '"';
+ return t && (r += ' title="' + t + '"'), (r += ">" + n + "</a>");
+ }),
+ (i.prototype.image = function(e, t, n) {
+ if (
+ ((e = f(this.options.sanitize, this.options.baseUrl, e)),
+ null === e)
+ )
+ return n;
+ var r = '<img src="' + e + '" alt="' + n + '"';
+ return (
+ t && (r += ' title="' + t + '"'),
+ (r += this.options.xhtml ? "/>" : ">")
+ );
+ }),
+ (i.prototype.text = function(e) {
+ return e;
+ }),
+ (o.prototype.strong = o.prototype.em = o.prototype.codespan = o.prototype.del = o.prototype.text = function(
+ e
+ ) {
+ return e;
+ }),
+ (o.prototype.link = o.prototype.image = function(e, t, n) {
+ return "" + n;
+ }),
+ (o.prototype.br = function() {
+ return "";
+ }),
+ (a.parse = function(e, t) {
+ var n = new a(t);
+ return n.parse(e);
+ }),
+ (a.prototype.parse = function(e) {
+ (this.inline = new r(e.links, this.options)),
+ (this.inlineText = new r(
+ e.links,
+ h({}, this.options, { renderer: new o() })
+ )),
+ (this.tokens = e.reverse());
+ for (var t = ""; this.next();) t += this.tok();
+ return t;
+ }),
+ (a.prototype.next = function() {
+ return (this.token = this.tokens.pop());
+ }),
+ (a.prototype.peek = function() {
+ return this.tokens[this.tokens.length - 1] || 0;
+ }),
+ (a.prototype.parseText = function() {
+ for (var e = this.token.text;
+ "text" === this.peek().type;)
+ e += "\n" + this.next().text;
+ return this.inline.output(e);
+ }),
+ (a.prototype.tok = function() {
+ switch (this.token.type) {
+ case "space":
+ return "";
+ case "hr":
+ return this.renderer.hr();
+ case "heading":
+ return this.renderer.heading(
+ this.inline.output(this.token.text),
+ this.token.depth,
+ u(this.inlineText.output(this.token.text)),
+ this.slugger
+ );
+ case "code":
+ return this.renderer.code(
+ this.token.text,
+ this.token.lang,
+ this.token.escaped
+ );
+ case "table":
+ var e,
+ t,
+ n,
+ r,
+ i = "",
+ o = "";
+ for (n = "", e = 0; e < this.token.header.length; e++)
+ n += this.renderer.tablecell(
+ this.inline.output(this.token.header[e]), { header: !0, align: this.token.align[e] }
+ );
+ for (
+ i += this.renderer.tablerow(n), e = 0; e < this.token.cells.length; e++
+ ) {
+ for (
+ t = this.token.cells[e], n = "", r = 0; r < t.length; r++
+ )
+ n += this.renderer.tablecell(this.inline.output(t[r]), {
+ header: !1,
+ align: this.token.align[r],
+ });
+ o += this.renderer.tablerow(n);
+ }
+ return this.renderer.table(i, o);
+ case "blockquote_start":
+ for (o = "";
+ "blockquote_end" !== this.next().type;)
+ o += this.tok();
+ return this.renderer.blockquote(o);
+ case "list_start":
+ o = "";
+ for (
+ var a = this.token.ordered, s = this.token.start;
+ "list_end" !== this.next().type;
+
+ )
+ o += this.tok();
+ return this.renderer.list(o, a, s);
+ case "list_item_start":
+ o = "";
+ var c = this.token.loose;
+ for (
+ this.token.task &&
+ (o += this.renderer.checkbox(this.token.checked));
+ "list_item_end" !== this.next().type;
+
+ )
+ o +=
+ c || "text" !== this.token.type ?
+ this.tok() :
+ this.parseText();
+ return this.renderer.listitem(o);
+ case "html":
+ return this.renderer.html(this.token.text);
+ case "paragraph":
+ return this.renderer.paragraph(
+ this.inline.output(this.token.text)
+ );
+ case "text":
+ return this.renderer.paragraph(this.parseText());
+ default:
+ var l =
+ 'Token with "' + this.token.type + '" type was not found.';
+ if (!this.options.silent) throw new Error(l);
+ console.log(l);
+ }
+ }),
+ (s.prototype.slug = function(e) {
+ var t = e
+ .toLowerCase()
+ .trim()
+ .replace(
+ /[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,.\/:;<=>?@[\]^`{|}~]/g,
+ ""
+ )
+ .replace(/\s/g, "-");
+ if (this.seen.hasOwnProperty(t)) {
+ var n = t;
+ do this.seen[n]++, (t = n + "-" + this.seen[n]);
+ while (this.seen.hasOwnProperty(t));
+ }
+ return (this.seen[t] = 0), t;
+ }),
+ (c.escapeTest = /[&<>"']/),
+ (c.escapeReplace = /[&<>"']/g),
+ (c.replacements = {
+ "&": "&",
+ "<": "<",
+ ">": ">",
+ '"': """,
+ "'": "'",
+ }),
+ (c.escapeTestNoEncode = /[<>"']|&(?!#?\w+;)/),
+ (c.escapeReplaceNoEncode = /[<>"']|&(?!#?\w+;)/g);
+ var x = {},
+ k = /^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;
+ (p.exec = p),
+ (b.options = b.setOptions = function(e) {
+ return h(b.defaults, e), b;
+ }),
+ (b.getDefaults = function() {
+ return {
+ baseUrl: null,
+ breaks: !1,
+ gfm: !0,
+ headerIds: !0,
+ headerPrefix: "",
+ highlight: null,
+ langPrefix: "language-",
+ mangle: !0,
+ pedantic: !1,
+ renderer: new i(),
+ sanitize: !1,
+ sanitizer: null,
+ silent: !1,
+ smartLists: !1,
+ smartypants: !1,
+ tables: !0,
+ xhtml: !1,
+ };
+ }),
+ (b.defaults = b.getDefaults()),
+ (b.Parser = a),
+ (b.parser = a.parse),
+ (b.Renderer = i),
+ (b.TextRenderer = o),
+ (b.Lexer = n),
+ (b.lexer = n.lex),
+ (b.InlineLexer = r),
+ (b.inlineLexer = r.output),
+ (b.Slugger = s),
+ (b.parse = b),
+ (e.exports = b);
+ })(this || ("undefined" != typeof window ? window : t));
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.each,
+ o = r.dom,
+ a = n(8),
+ s = n(12),
+ c = n(20),
+ u = n(13),
+ l = n(14),
+ f = Object.assign({
+ enabled: !1,
+ type: "php-tar",
+ packageName: "package",
+ alwaysVisible: !1,
+ },
+ l.download
+ ),
+ d =
+ '<div id="download" class="tool">\n <img src="' +
+ u.image("download") +
+ '" alt="download"/>\n </div>',
+ p = [],
+ h = void 0,
+ g = function(e) {
+ (p = e.slice(0)), p.length ? h.show() : f.alwaysVisible || h.hide();
+ },
+ m = function() {
+ var e = f.type,
+ t = f.packageName,
+ n = "shell-zip" === e ? "zip" : "tar";
+ t || (t = 1 === p.length ? p[0].label : c.getItem().label);
+ var r = {
+ action: "download",
+ as: t + "." + n,
+ type: e,
+ baseHref: c.getAbsHref(),
+ hrefs: "",
+ };
+ i(p, function(e, t) {
+ r["hrefs[" + t + "]"] = e.absHref;
+ }),
+ a.formRequest(r);
+ },
+ v = function() {
+ f.enabled &&
+ ((h = o(d).hide().appTo("#toolbar").on("click", m)),
+ f.alwaysVisible && h.show(),
+ s.sub("selection", g));
+ };
+ v();
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.filter,
+ o = r.debounce,
+ a = r.parsePattern,
+ s = r.dom,
+ c = n(12),
+ u = n(20),
+ l = n(13),
+ f = n(14),
+ d = n(18),
+ p = Object.assign({ enabled: !1, advanced: !1, debounceTime: 100, ignorecase: !0 },
+ f.filter
+ ),
+ h =
+ '<div id="filter" class="tool">\n <img src="' +
+ l.image("filter") +
+ '" alt="filter"/>\n <input class="l10n_ph-filter" type="text" value=""/>\n </div>',
+ g = !1,
+ m = "",
+ v = void 0,
+ b = void 0,
+ w = function() {
+ var e =
+ arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "";
+ if (e !== m) {
+ if (((m = e), !e)) return void d.setLocation();
+ v.addCls("pending");
+ var t = new RegExp(e, p.ignorecase ? "i" : ""),
+ n = i(u.getItem().content, function(e) {
+ return t.test(e.label);
+ });
+ v.rmCls("pending"), d.setHint("noMatch"), d.setItems(n);
+ }
+ },
+ y = function() {
+ g
+ ?
+ (v.addCls("active"), b[0].focus(), w(a(b.val(), p.advanced))) :
+ (w(), v.rmCls("active"));
+ },
+ x = function() {
+ (g = !g), y();
+ },
+ k = function() {
+ (g = !1), b.val(""), y();
+ },
+ _ = function() {
+ p.enabled &&
+ ((v = s(h).appTo("#toolbar")),
+ (b = v.find("input")),
+ v.find("img").on("click", x),
+ b.on("keyup", o(y, p.debounceTime)),
+ c.sub("location.changed", k));
+ };
+ _();
+ },
+ function(e, t, n) {
+ (function(e) {
+ "use strict";
+ var t = n(2),
+ r = t.map,
+ i = n(12),
+ o = n(14),
+ a = e.window,
+ s = Object.assign({ enabled: !1, id: "UA-000000-0" },
+ o["google-analytics-ua"]
+ ),
+ c = function() {
+ !(function(e, t, n, r, i, o, a) {
+ (e.GoogleAnalyticsObject = i),
+ (e[i] =
+ e[i] ||
+ function() {
+ (e[i].q = e[i].q || []).push(arguments);
+ }),
+ (e[i].l = 1 * new Date()),
+ (o = t.createElement(n)),
+ (a = t.getElementsByTagName(n)[0]),
+ (o.async = 1),
+ (o.src = r),
+ a.parentNode.insertBefore(o, a);
+ })(
+ window,
+ document,
+ "script",
+ "//www.google-analytics.com/analytics.js",
+ "ga"
+ );
+ },
+ u = function() {
+ s.enabled &&
+ (c(),
+ a.ga("create", s.id, "auto"),
+ i.sub("location.changed", function(e) {
+ var t = a.location;
+ a.ga("send", "pageview", {
+ location: t.protocol + "//" + t.host + e.absHref,
+ title: r(e.getCrumb(), function(e) {
+ return e.label;
+ }).join(" > "),
+ });
+ }));
+ };
+ u();
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ (function(e) {
+ "use strict";
+ var t = n(33),
+ r = n(2),
+ i = r.isNum,
+ o = r.dom,
+ a = n(12),
+ s = n(19),
+ c = n(13),
+ u = n(14),
+ l = n(16),
+ f = Object.assign({ enabled: !1, show: !1, qrcode: !0, qrColor: "#999" },
+ u.info
+ ),
+ d =
+ '<div id="info">\n <div class="icon"><img/></div>\n <div class="block">\n <div class="label"></div>\n <div class="time"></div>\n <div class="size"></div>\n <div class="content">\n <span class="folders"></span> <span class="l10n-folders"></span>,\n <span class="files"></span> <span class="l10n-files"></span>\n </div>\n </div>\n <div class="qrcode"/>\n </div>',
+ p =
+ '<div class="block">\n <h1 class="l10n-info">Info</h1>\n <div id="view-info" class="button view">\n <img src="' +
+ c.image("info-toggle") +
+ '" alt="view-info"/>\n </div>\n </div>',
+ h = "ext/info",
+ g = void 0,
+ m = void 0,
+ v = void 0,
+ b = void 0,
+ w = void 0,
+ y = void 0,
+ x = void 0,
+ k = void 0,
+ _ = void 0,
+ C = function() {
+ l.get(h) ?
+ (o("#view-info").addCls("active"), o("#info").show()) :
+ (o("#view-info").rmCls("active"), o("#info").hide());
+ },
+ S = function(n) {
+ var r = n.thumbRational || n.icon,
+ o = !!n.thumbRational;
+ if (
+ ((!n.isCurrentFolder() && r) || (r = c.icon("folder")),
+ g.attr("src", r),
+ o ? g.addCls("thumb") : g.rmCls("thumb"),
+ m.text(n.label),
+ i(n.time) ? v.text(s.formatDate(n.time)) : v.text("."),
+ i(n.size) ? (b.text(s.formatSize(n.size)), b.show()) : b.hide(),
+ n.isContentFetched)
+ ) {
+ var a = n.getStats();
+ y.text(a.folders), x.text(a.files), w.show();
+ } else w.hide();
+ if (f.qrcode) {
+ var u = e.window.location;
+ k.clr().app(
+ t({
+ render: "image",
+ size: 200,
+ fill: f.qrFill,
+ back: f.qrBack,
+ text: u.protocol + "//" + u.host + n.absHref,
+ crisp: !0,
+ quiet: 1,
+ })
+ );
+ }
+ },
+ A = function(e) {
+ S(e);
+ },
+ T = function() {
+ S(_);
+ },
+ E = function(e) {
+ (_ = e), S(_);
+ },
+ M = function() {
+ if (f.enabled) {
+ var e = o(d).hide().appTo("#mainrow");
+ (g = e.find(".icon img")),
+ (m = e.find(".label")),
+ (v = e.find(".time")),
+ (b = e.find(".size")),
+ (w = e.find(".content")),
+ (y = e.find(".folders")),
+ (x = e.find(".files")),
+ (k = e.find(".qrcode")),
+ f.qrcode || k.rm(),
+ o(p)
+ .appTo("#sidebar")
+ .find("#view-info")
+ .on("click", function(e) {
+ l.put(h, !l.get(h)),
+ C(),
+ a.pub("resize"),
+ e.preventDefault();
+ }),
+ "boolean" != typeof l.get(h) && l.put(h, f.show),
+ C(),
+ a.sub("location.changed", E),
+ a.sub("item.mouseenter", A),
+ a.sub("item.mouseleave", T);
+ }
+ };
+ M();
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ var r, i, o;
+ !(function(t, n) {
+ e.exports = n();
+ })(this, function() {
+ return (function(e) {
+ function t(r) {
+ if (n[r]) return n[r].exports;
+ var i = (n[r] = { exports: {}, id: r, loaded: !1 });
+ return (
+ e[r].call(i.exports, i, i.exports, t), (i.loaded = !0), i.exports
+ );
+ }
+ var n = {};
+ return (t.m = e), (t.c = n), (t.p = ""), t(0);
+ })([
+ function(e, t, n) {
+ "use strict";
+ var r = n(1),
+ i = r.create_canvas,
+ o = r.canvas_to_img,
+ a = r.dpr,
+ s = n(2),
+ c = n(3),
+ u = n(4);
+ e.exports = function(e) {
+ var t = Object.assign({}, s, e),
+ n = c(t.text, t.ecLevel, t.minVersion, t.quiet),
+ r = t.ratio || a,
+ l = i(t.size, r),
+ f = l.getContext("2d");
+ return f.scale(r, r), u(n, f, t), "image" === t.render ? o(l) : l;
+ };
+ },
+ function(e, t) {
+ "use strict";
+ var n = window,
+ r = n.document,
+ i = n.devicePixelRatio || 1,
+ o = function(e) {
+ return r.createElement(e);
+ },
+ a = function(e, t) {
+ return e.getAttribute(t);
+ },
+ s = function(e, t, n) {
+ return e.setAttribute(t, n);
+ },
+ c = function(e, t) {
+ var n = o("canvas");
+ return (
+ s(n, "width", e * t),
+ s(n, "height", e * t),
+ (n.style.width = e + "px"),
+ (n.style.height = e + "px"),
+ n
+ );
+ },
+ u = function(e) {
+ var t = o("img");
+ return (
+ s(t, "crossorigin", "anonymous"),
+ s(t, "src", e.toDataURL("image/png")),
+ s(t, "width", a(e, "width")),
+ s(t, "height", a(e, "height")),
+ (t.style.width = e.style.width),
+ (t.style.height = e.style.height),
+ t
+ );
+ };
+ e.exports = { create_canvas: c, canvas_to_img: u, dpr: i };
+ },
+ function(e, t) {
+ "use strict";
+ e.exports = {
+ render: "image",
+ crisp: !0,
+ minVersion: 1,
+ ecLevel: "L",
+ size: 200,
+ ratio: null,
+ fill: "#333",
+ back: "#fff",
+ text: "no text",
+ rounded: 0,
+ quiet: 0,
+ mode: "plain",
+ mSize: 30,
+ mPosX: 50,
+ mPosY: 50,
+ label: "no label",
+ fontname: "sans",
+ fontcolor: "#333",
+ image: null,
+ };
+ },
+ function(n, a) {
+ "use strict";
+ var s =
+ "function" == typeof Symbol &&
+ "symbol" == typeof Symbol.iterator ?
+
+ function(e) {
+ return typeof e;
+ } :
+ function(e) {
+ return e &&
+ "function" == typeof Symbol &&
+ e.constructor === Symbol &&
+ e !== Symbol.prototype ?
+ "symbol" :
+ typeof e;
+ },
+ c = /code length overflow/i,
+ u = (function() {
+ var n = (function() {
+ function e(t, n) {
+ if ("undefined" == typeof t.length)
+ throw new Error(t.length + "/" + n);
+ var r = (function() {
+ for (var e = 0; e < t.length && 0 == t[e];) e += 1;
+ for (
+ var r = new Array(t.length - e + n), i = 0; i < t.length - e; i += 1
+ )
+ r[i] = t[i + e];
+ return r;
+ })(),
+ i = {};
+ return (
+ (i.getAt = function(e) {
+ return r[e];
+ }),
+ (i.getLength = function() {
+ return r.length;
+ }),
+ (i.multiply = function(t) {
+ for (
+ var n = new Array(i.getLength() + t.getLength() - 1),
+ r = 0; r < i.getLength(); r += 1
+ )
+ for (var o = 0; o < t.getLength(); o += 1)
+ n[r + o] ^= a.gexp(
+ a.glog(i.getAt(r)) + a.glog(t.getAt(o))
+ );
+ return e(n, 0);
+ }),
+ (i.mod = function(t) {
+ if (i.getLength() - t.getLength() < 0) return i;
+ for (
+ var n = a.glog(i.getAt(0)) - a.glog(t.getAt(0)),
+ r = new Array(i.getLength()),
+ o = 0; o < i.getLength(); o += 1
+ )
+ r[o] = i.getAt(o);
+ for (var o = 0; o < t.getLength(); o += 1)
+ r[o] ^= a.gexp(a.glog(t.getAt(o)) + n);
+ return e(r, 0).mod(t);
+ }),
+ i
+ );
+ }
+ var t = function(t, n) {
+ var i = 236,
+ a = 17,
+ l = t,
+ f = r[n],
+ d = null,
+ p = 0,
+ g = null,
+ m = new Array(),
+ v = {},
+ b = function(e, t) {
+ (p = 4 * l + 17),
+ (d = (function(e) {
+ for (var t = new Array(e), n = 0; n < e; n += 1) {
+ t[n] = new Array(e);
+ for (var r = 0; r < e; r += 1) t[n][r] = null;
+ }
+ return t;
+ })(p)),
+ w(0, 0),
+ w(p - 7, 0),
+ w(0, p - 7),
+ k(),
+ x(),
+ C(e, t),
+ l >= 7 && _(e),
+ null == g && (g = T(l, f, m)),
+ S(g, t);
+ },
+ w = function(e, t) {
+ for (var n = -1; n <= 7; n += 1)
+ if (!(e + n <= -1 || p <= e + n))
+ for (var r = -1; r <= 7; r += 1)
+ t + r <= -1 ||
+ p <= t + r ||
+ ((0 <= n && n <= 6 && (0 == r || 6 == r)) ||
+ (0 <= r && r <= 6 && (0 == n || 6 == n)) ||
+ (2 <= n && n <= 4 && 2 <= r && r <= 4) ?
+ (d[e + n][t + r] = !0) :
+ (d[e + n][t + r] = !1));
+ },
+ y = function() {
+ for (var e = 0, t = 0, n = 0; n < 8; n += 1) {
+ b(!0, n);
+ var r = o.getLostPoint(v);
+ (0 == n || e > r) && ((e = r), (t = n));
+ }
+ return t;
+ },
+ x = function() {
+ for (var e = 8; e < p - 8; e += 1)
+ null == d[e][6] && (d[e][6] = e % 2 == 0);
+ for (var t = 8; t < p - 8; t += 1)
+ null == d[6][t] && (d[6][t] = t % 2 == 0);
+ },
+ k = function() {
+ for (
+ var e = o.getPatternPosition(l), t = 0; t < e.length; t += 1
+ )
+ for (var n = 0; n < e.length; n += 1) {
+ var r = e[t],
+ i = e[n];
+ if (null == d[r][i])
+ for (var a = -2; a <= 2; a += 1)
+ for (var s = -2; s <= 2; s += 1)
+ a == -2 ||
+ 2 == a ||
+ s == -2 ||
+ 2 == s ||
+ (0 == a && 0 == s) ?
+ (d[r + a][i + s] = !0) :
+ (d[r + a][i + s] = !1);
+ }
+ },
+ _ = function(e) {
+ for (
+ var t = o.getBCHTypeNumber(l), n = 0; n < 18; n += 1
+ ) {
+ var r = !e && 1 == ((t >> n) & 1);
+ d[Math.floor(n / 3)][(n % 3) + p - 8 - 3] = r;
+ }
+ for (var n = 0; n < 18; n += 1) {
+ var r = !e && 1 == ((t >> n) & 1);
+ d[(n % 3) + p - 8 - 3][Math.floor(n / 3)] = r;
+ }
+ },
+ C = function(e, t) {
+ for (
+ var n = (f << 3) | t, r = o.getBCHTypeInfo(n), i = 0; i < 15; i += 1
+ ) {
+ var a = !e && 1 == ((r >> i) & 1);
+ i < 6 ?
+ (d[i][8] = a) :
+ i < 8 ?
+ (d[i + 1][8] = a) :
+ (d[p - 15 + i][8] = a);
+ }
+ for (var i = 0; i < 15; i += 1) {
+ var a = !e && 1 == ((r >> i) & 1);
+ i < 8 ?
+ (d[8][p - i - 1] = a) :
+ i < 9 ?
+ (d[8][15 - i - 1 + 1] = a) :
+ (d[8][15 - i - 1] = a);
+ }
+ d[p - 8][8] = !e;
+ },
+ S = function(e, t) {
+ for (
+ var n = -1,
+ r = p - 1,
+ i = 7,
+ a = 0,
+ s = o.getMaskFunction(t),
+ c = p - 1; c > 0; c -= 2
+ )
+ for (6 == c && (c -= 1);;) {
+ for (var u = 0; u < 2; u += 1)
+ if (null == d[r][c - u]) {
+ var l = !1;
+ a < e.length && (l = 1 == ((e[a] >>> i) & 1));
+ var f = s(r, c - u);
+ f && (l = !l),
+ (d[r][c - u] = l),
+ (i -= 1),
+ i == -1 && ((a += 1), (i = 7));
+ }
+ if (((r += n), r < 0 || p <= r)) {
+ (r -= n), (n = -n);
+ break;
+ }
+ }
+ },
+ A = function(t, n) {
+ for (
+ var r = 0,
+ i = 0,
+ a = 0,
+ s = new Array(n.length),
+ c = new Array(n.length),
+ u = 0; u < n.length; u += 1
+ ) {
+ var l = n[u].dataCount,
+ f = n[u].totalCount - l;
+ (i = Math.max(i, l)),
+ (a = Math.max(a, f)),
+ (s[u] = new Array(l));
+ for (var d = 0; d < s[u].length; d += 1)
+ s[u][d] = 255 & t.getBuffer()[d + r];
+ r += l;
+ var p = o.getErrorCorrectPolynomial(f),
+ h = e(s[u], p.getLength() - 1),
+ g = h.mod(p);
+ c[u] = new Array(p.getLength() - 1);
+ for (var d = 0; d < c[u].length; d += 1) {
+ var m = d + g.getLength() - c[u].length;
+ c[u][d] = m >= 0 ? g.getAt(m) : 0;
+ }
+ }
+ for (var v = 0, d = 0; d < n.length; d += 1)
+ v += n[d].totalCount;
+ for (var b = new Array(v), w = 0, d = 0; d < i; d += 1)
+ for (var u = 0; u < n.length; u += 1)
+ d < s[u].length && ((b[w] = s[u][d]), (w += 1));
+ for (var d = 0; d < a; d += 1)
+ for (var u = 0; u < n.length; u += 1)
+ d < c[u].length && ((b[w] = c[u][d]), (w += 1));
+ return b;
+ },
+ T = function(e, t, n) {
+ for (
+ var r = s.getRSBlocks(e, t), u = c(), l = 0; l < n.length; l += 1
+ ) {
+ var f = n[l];
+ u.put(f.getMode(), 4),
+ u.put(
+ f.getLength(),
+ o.getLengthInBits(f.getMode(), e)
+ ),
+ f.write(u);
+ }
+ for (var d = 0, l = 0; l < r.length; l += 1)
+ d += r[l].dataCount;
+ if (u.getLengthInBits() > 8 * d)
+ throw new Error(
+ "code length overflow. (" +
+ u.getLengthInBits() +
+ ">" +
+ 8 * d +
+ ")"
+ );
+ for (
+ u.getLengthInBits() + 4 <= 8 * d && u.put(0, 4); u.getLengthInBits() % 8 != 0;
+
+ )
+ u.putBit(!1);
+ for (; !(u.getLengthInBits() >= 8 * d) &&
+ (u.put(i, 8), !(u.getLengthInBits() >= 8 * d));
+
+ )
+ u.put(a, 8);
+ return A(u, r);
+ };
+ return (
+ (v.addData = function(e) {
+ var t = u(e);
+ m.push(t), (g = null);
+ }),
+ (v.isDark = function(e, t) {
+ if (e < 0 || p <= e || t < 0 || p <= t)
+ throw new Error(e + "," + t);
+ return d[e][t];
+ }),
+ (v.getModuleCount = function() {
+ return p;
+ }),
+ (v.make = function() {
+ b(!1, y());
+ }),
+ (v.createTableTag = function(e, t) {
+ (e = e || 2), (t = "undefined" == typeof t ? 4 * e : t);
+ var n = "";
+ (n += '<table style="'),
+ (n += " border-width: 0px; border-style: none;"),
+ (n += " border-collapse: collapse;"),
+ (n += " padding: 0px; margin: " + t + "px;"),
+ (n += '">'),
+ (n += "<tbody>");
+ for (var r = 0; r < v.getModuleCount(); r += 1) {
+ n += "<tr>";
+ for (var i = 0; i < v.getModuleCount(); i += 1)
+ (n += '<td style="'),
+ (n += " border-width: 0px; border-style: none;"),
+ (n += " border-collapse: collapse;"),
+ (n += " padding: 0px; margin: 0px;"),
+ (n += " width: " + e + "px;"),
+ (n += " height: " + e + "px;"),
+ (n += " background-color: "),
+ (n += v.isDark(r, i) ? "#000000" : "#ffffff"),
+ (n += ";"),
+ (n += '"/>');
+ n += "</tr>";
+ }
+ return (n += "</tbody>"), (n += "</table>");
+ }),
+ (v.createImgTag = function(e, t) {
+ (e = e || 2), (t = "undefined" == typeof t ? 4 * e : t);
+ var n = v.getModuleCount() * e + 2 * t,
+ r = t,
+ i = n - t;
+ return h(n, n, function(t, n) {
+ if (r <= t && t < i && r <= n && n < i) {
+ var o = Math.floor((t - r) / e),
+ a = Math.floor((n - r) / e);
+ return v.isDark(a, o) ? 0 : 1;
+ }
+ return 1;
+ });
+ }),
+ v
+ );
+ };
+ (t.stringToBytes = function(e) {
+ for (var t = new Array(), n = 0; n < e.length; n += 1) {
+ var r = e.charCodeAt(n);
+ t.push(255 & r);
+ }
+ return t;
+ }),
+ (t.createStringToBytes = function(e, t) {
+ var n = (function() {
+ for (
+ var n = d(e),
+ r = function() {
+ var e = n.read();
+ if (e == -1) throw new Error();
+ return e;
+ },
+ i = 0,
+ o = {};;
+
+ ) {
+ var a = n.read();
+ if (a == -1) break;
+ var s = r(),
+ c = r(),
+ u = r(),
+ l = String.fromCharCode((a << 8) | s),
+ f = (c << 8) | u;
+ (o[l] = f), (i += 1);
+ }
+ if (i != t) throw new Error(i + " != " + t);
+ return o;
+ })(),
+ r = "?".charCodeAt(0);
+ return function(e) {
+ for (var t = new Array(), i = 0; i < e.length; i += 1) {
+ var o = e.charCodeAt(i);
+ if (o < 128) t.push(o);
+ else {
+ var a = n[e.charAt(i)];
+ "number" == typeof a
+ ?
+ (255 & a) == a ?
+ t.push(a) :
+ (t.push(a >>> 8), t.push(255 & a)) :
+ t.push(r);
+ }
+ }
+ return t;
+ };
+ });
+ var n = {
+ MODE_NUMBER: 1,
+ MODE_ALPHA_NUM: 2,
+ MODE_8BIT_BYTE: 4,
+ MODE_KANJI: 8,
+ },
+ r = { L: 1, M: 0, Q: 3, H: 2 },
+ i = {
+ PATTERN000: 0,
+ PATTERN001: 1,
+ PATTERN010: 2,
+ PATTERN011: 3,
+ PATTERN100: 4,
+ PATTERN101: 5,
+ PATTERN110: 6,
+ PATTERN111: 7,
+ },
+ o = (function() {
+ var t = [
+ [],
+ [6, 18],
+ [6, 22],
+ [6, 26],
+ [6, 30],
+ [6, 34],
+ [6, 22, 38],
+ [6, 24, 42],
+ [6, 26, 46],
+ [6, 28, 50],
+ [6, 30, 54],
+ [6, 32, 58],
+ [6, 34, 62],
+ [6, 26, 46, 66],
+ [6, 26, 48, 70],
+ [6, 26, 50, 74],
+ [6, 30, 54, 78],
+ [6, 30, 56, 82],
+ [6, 30, 58, 86],
+ [6, 34, 62, 90],
+ [6, 28, 50, 72, 94],
+ [6, 26, 50, 74, 98],
+ [6, 30, 54, 78, 102],
+ [6, 28, 54, 80, 106],
+ [6, 32, 58, 84, 110],
+ [6, 30, 58, 86, 114],
+ [6, 34, 62, 90, 118],
+ [6, 26, 50, 74, 98, 122],
+ [6, 30, 54, 78, 102, 126],
+ [6, 26, 52, 78, 104, 130],
+ [6, 30, 56, 82, 108, 134],
+ [6, 34, 60, 86, 112, 138],
+ [6, 30, 58, 86, 114, 142],
+ [6, 34, 62, 90, 118, 146],
+ [6, 30, 54, 78, 102, 126, 150],
+ [6, 24, 50, 76, 102, 128, 154],
+ [6, 28, 54, 80, 106, 132, 158],
+ [6, 32, 58, 84, 110, 136, 162],
+ [6, 26, 54, 82, 110, 138, 166],
+ [6, 30, 58, 86, 114, 142, 170],
+ ],
+ r = 1335,
+ o = 7973,
+ s = 21522,
+ c = {},
+ u = function(e) {
+ for (var t = 0; 0 != e;)(t += 1), (e >>>= 1);
+ return t;
+ };
+ return (
+ (c.getBCHTypeInfo = function(e) {
+ for (var t = e << 10; u(t) - u(r) >= 0;)
+ t ^= r << (u(t) - u(r));
+ return ((e << 10) | t) ^ s;
+ }),
+ (c.getBCHTypeNumber = function(e) {
+ for (var t = e << 12; u(t) - u(o) >= 0;)
+ t ^= o << (u(t) - u(o));
+ return (e << 12) | t;
+ }),
+ (c.getPatternPosition = function(e) {
+ return t[e - 1];
+ }),
+ (c.getMaskFunction = function(e) {
+ switch (e) {
+ case i.PATTERN000:
+ return function(e, t) {
+ return (e + t) % 2 == 0;
+ };
+ case i.PATTERN001:
+ return function(e, t) {
+ return e % 2 == 0;
+ };
+ case i.PATTERN010:
+ return function(e, t) {
+ return t % 3 == 0;
+ };
+ case i.PATTERN011:
+ return function(e, t) {
+ return (e + t) % 3 == 0;
+ };
+ case i.PATTERN100:
+ return function(e, t) {
+ return (
+ (Math.floor(e / 2) + Math.floor(t / 3)) % 2 ==
+ 0
+ );
+ };
+ case i.PATTERN101:
+ return function(e, t) {
+ return ((e * t) % 2) + ((e * t) % 3) == 0;
+ };
+ case i.PATTERN110:
+ return function(e, t) {
+ return (((e * t) % 2) + ((e * t) % 3)) % 2 == 0;
+ };
+ case i.PATTERN111:
+ return function(e, t) {
+ return (((e * t) % 3) + ((e + t) % 2)) % 2 == 0;
+ };
+ default:
+ throw new Error("bad maskPattern:" + e);
+ }
+ }),
+ (c.getErrorCorrectPolynomial = function(t) {
+ for (var n = e([1], 0), r = 0; r < t; r += 1)
+ n = n.multiply(e([1, a.gexp(r)], 0));
+ return n;
+ }),
+ (c.getLengthInBits = function(e, t) {
+ if (1 <= t && t < 10)
+ switch (e) {
+ case n.MODE_NUMBER:
+ return 10;
+ case n.MODE_ALPHA_NUM:
+ return 9;
+ case n.MODE_8BIT_BYTE:
+ return 8;
+ case n.MODE_KANJI:
+ return 8;
+ default:
+ throw new Error("mode:" + e);
+ }
+ else if (t < 27)
+ switch (e) {
+ case n.MODE_NUMBER:
+ return 12;
+ case n.MODE_ALPHA_NUM:
+ return 11;
+ case n.MODE_8BIT_BYTE:
+ return 16;
+ case n.MODE_KANJI:
+ return 10;
+ default:
+ throw new Error("mode:" + e);
+ }
+ else {
+ if (!(t < 41)) throw new Error("type:" + t);
+ switch (e) {
+ case n.MODE_NUMBER:
+ return 14;
+ case n.MODE_ALPHA_NUM:
+ return 13;
+ case n.MODE_8BIT_BYTE:
+ return 16;
+ case n.MODE_KANJI:
+ return 12;
+ default:
+ throw new Error("mode:" + e);
+ }
+ }
+ }),
+ (c.getLostPoint = function(e) {
+ for (
+ var t = e.getModuleCount(), n = 0, r = 0; r < t; r += 1
+ )
+ for (var i = 0; i < t; i += 1) {
+ for (
+ var o = 0, a = e.isDark(r, i), s = -1; s <= 1; s += 1
+ )
+ if (!(r + s < 0 || t <= r + s))
+ for (var c = -1; c <= 1; c += 1)
+ i + c < 0 ||
+ t <= i + c ||
+ (0 == s && 0 == c) ||
+ (a == e.isDark(r + s, i + c) && (o += 1));
+ o > 5 && (n += 3 + o - 5);
+ }
+ for (var r = 0; r < t - 1; r += 1)
+ for (var i = 0; i < t - 1; i += 1) {
+ var u = 0;
+ e.isDark(r, i) && (u += 1),
+ e.isDark(r + 1, i) && (u += 1),
+ e.isDark(r, i + 1) && (u += 1),
+ e.isDark(r + 1, i + 1) && (u += 1),
+ (0 != u && 4 != u) || (n += 3);
+ }
+ for (var r = 0; r < t; r += 1)
+ for (var i = 0; i < t - 6; i += 1)
+ e.isDark(r, i) &&
+ !e.isDark(r, i + 1) &&
+ e.isDark(r, i + 2) &&
+ e.isDark(r, i + 3) &&
+ e.isDark(r, i + 4) &&
+ !e.isDark(r, i + 5) &&
+ e.isDark(r, i + 6) &&
+ (n += 40);
+ for (var i = 0; i < t; i += 1)
+ for (var r = 0; r < t - 6; r += 1)
+ e.isDark(r, i) &&
+ !e.isDark(r + 1, i) &&
+ e.isDark(r + 2, i) &&
+ e.isDark(r + 3, i) &&
+ e.isDark(r + 4, i) &&
+ !e.isDark(r + 5, i) &&
+ e.isDark(r + 6, i) &&
+ (n += 40);
+ for (var l = 0, i = 0; i < t; i += 1)
+ for (var r = 0; r < t; r += 1)
+ e.isDark(r, i) && (l += 1);
+ var f = Math.abs((100 * l) / t / t - 50) / 5;
+ return (n += 10 * f);
+ }),
+ c
+ );
+ })(),
+ a = (function() {
+ for (
+ var e = new Array(256), t = new Array(256), n = 0; n < 8; n += 1
+ )
+ e[n] = 1 << n;
+ for (var n = 8; n < 256; n += 1)
+ e[n] = e[n - 4] ^ e[n - 5] ^ e[n - 6] ^ e[n - 8];
+ for (var n = 0; n < 255; n += 1) t[e[n]] = n;
+ var r = {};
+ return (
+ (r.glog = function(e) {
+ if (e < 1) throw new Error("glog(" + e + ")");
+ return t[e];
+ }),
+ (r.gexp = function(t) {
+ for (; t < 0;) t += 255;
+ for (; t >= 256;) t -= 255;
+ return e[t];
+ }),
+ r
+ );
+ })(),
+ s = (function() {
+ var e = [
+ [1, 26, 19],
+ [1, 26, 16],
+ [1, 26, 13],
+ [1, 26, 9],
+ [1, 44, 34],
+ [1, 44, 28],
+ [1, 44, 22],
+ [1, 44, 16],
+ [1, 70, 55],
+ [1, 70, 44],
+ [2, 35, 17],
+ [2, 35, 13],
+ [1, 100, 80],
+ [2, 50, 32],
+ [2, 50, 24],
+ [4, 25, 9],
+ [1, 134, 108],
+ [2, 67, 43],
+ [2, 33, 15, 2, 34, 16],
+ [2, 33, 11, 2, 34, 12],
+ [2, 86, 68],
+ [4, 43, 27],
+ [4, 43, 19],
+ [4, 43, 15],
+ [2, 98, 78],
+ [4, 49, 31],
+ [2, 32, 14, 4, 33, 15],
+ [4, 39, 13, 1, 40, 14],
+ [2, 121, 97],
+ [2, 60, 38, 2, 61, 39],
+ [4, 40, 18, 2, 41, 19],
+ [4, 40, 14, 2, 41, 15],
+ [2, 146, 116],
+ [3, 58, 36, 2, 59, 37],
+ [4, 36, 16, 4, 37, 17],
+ [4, 36, 12, 4, 37, 13],
+ [2, 86, 68, 2, 87, 69],
+ [4, 69, 43, 1, 70, 44],
+ [6, 43, 19, 2, 44, 20],
+ [6, 43, 15, 2, 44, 16],
+ [4, 101, 81],
+ [1, 80, 50, 4, 81, 51],
+ [4, 50, 22, 4, 51, 23],
+ [3, 36, 12, 8, 37, 13],
+ [2, 116, 92, 2, 117, 93],
+ [6, 58, 36, 2, 59, 37],
+ [4, 46, 20, 6, 47, 21],
+ [7, 42, 14, 4, 43, 15],
+ [4, 133, 107],
+ [8, 59, 37, 1, 60, 38],
+ [8, 44, 20, 4, 45, 21],
+ [12, 33, 11, 4, 34, 12],
+ [3, 145, 115, 1, 146, 116],
+ [4, 64, 40, 5, 65, 41],
+ [11, 36, 16, 5, 37, 17],
+ [11, 36, 12, 5, 37, 13],
+ [5, 109, 87, 1, 110, 88],
+ [5, 65, 41, 5, 66, 42],
+ [5, 54, 24, 7, 55, 25],
+ [11, 36, 12, 7, 37, 13],
+ [5, 122, 98, 1, 123, 99],
+ [7, 73, 45, 3, 74, 46],
+ [15, 43, 19, 2, 44, 20],
+ [3, 45, 15, 13, 46, 16],
+ [1, 135, 107, 5, 136, 108],
+ [10, 74, 46, 1, 75, 47],
+ [1, 50, 22, 15, 51, 23],
+ [2, 42, 14, 17, 43, 15],
+ [5, 150, 120, 1, 151, 121],
+ [9, 69, 43, 4, 70, 44],
+ [17, 50, 22, 1, 51, 23],
+ [2, 42, 14, 19, 43, 15],
+ [3, 141, 113, 4, 142, 114],
+ [3, 70, 44, 11, 71, 45],
+ [17, 47, 21, 4, 48, 22],
+ [9, 39, 13, 16, 40, 14],
+ [3, 135, 107, 5, 136, 108],
+ [3, 67, 41, 13, 68, 42],
+ [15, 54, 24, 5, 55, 25],
+ [15, 43, 15, 10, 44, 16],
+ [4, 144, 116, 4, 145, 117],
+ [17, 68, 42],
+ [17, 50, 22, 6, 51, 23],
+ [19, 46, 16, 6, 47, 17],
+ [2, 139, 111, 7, 140, 112],
+ [17, 74, 46],
+ [7, 54, 24, 16, 55, 25],
+ [34, 37, 13],
+ [4, 151, 121, 5, 152, 122],
+ [4, 75, 47, 14, 76, 48],
+ [11, 54, 24, 14, 55, 25],
+ [16, 45, 15, 14, 46, 16],
+ [6, 147, 117, 4, 148, 118],
+ [6, 73, 45, 14, 74, 46],
+ [11, 54, 24, 16, 55, 25],
+ [30, 46, 16, 2, 47, 17],
+ [8, 132, 106, 4, 133, 107],
+ [8, 75, 47, 13, 76, 48],
+ [7, 54, 24, 22, 55, 25],
+ [22, 45, 15, 13, 46, 16],
+ [10, 142, 114, 2, 143, 115],
+ [19, 74, 46, 4, 75, 47],
+ [28, 50, 22, 6, 51, 23],
+ [33, 46, 16, 4, 47, 17],
+ [8, 152, 122, 4, 153, 123],
+ [22, 73, 45, 3, 74, 46],
+ [8, 53, 23, 26, 54, 24],
+ [12, 45, 15, 28, 46, 16],
+ [3, 147, 117, 10, 148, 118],
+ [3, 73, 45, 23, 74, 46],
+ [4, 54, 24, 31, 55, 25],
+ [11, 45, 15, 31, 46, 16],
+ [7, 146, 116, 7, 147, 117],
+ [21, 73, 45, 7, 74, 46],
+ [1, 53, 23, 37, 54, 24],
+ [19, 45, 15, 26, 46, 16],
+ [5, 145, 115, 10, 146, 116],
+ [19, 75, 47, 10, 76, 48],
+ [15, 54, 24, 25, 55, 25],
+ [23, 45, 15, 25, 46, 16],
+ [13, 145, 115, 3, 146, 116],
+ [2, 74, 46, 29, 75, 47],
+ [42, 54, 24, 1, 55, 25],
+ [23, 45, 15, 28, 46, 16],
+ [17, 145, 115],
+ [10, 74, 46, 23, 75, 47],
+ [10, 54, 24, 35, 55, 25],
+ [19, 45, 15, 35, 46, 16],
+ [17, 145, 115, 1, 146, 116],
+ [14, 74, 46, 21, 75, 47],
+ [29, 54, 24, 19, 55, 25],
+ [11, 45, 15, 46, 46, 16],
+ [13, 145, 115, 6, 146, 116],
+ [14, 74, 46, 23, 75, 47],
+ [44, 54, 24, 7, 55, 25],
+ [59, 46, 16, 1, 47, 17],
+ [12, 151, 121, 7, 152, 122],
+ [12, 75, 47, 26, 76, 48],
+ [39, 54, 24, 14, 55, 25],
+ [22, 45, 15, 41, 46, 16],
+ [6, 151, 121, 14, 152, 122],
+ [6, 75, 47, 34, 76, 48],
+ [46, 54, 24, 10, 55, 25],
+ [2, 45, 15, 64, 46, 16],
+ [17, 152, 122, 4, 153, 123],
+ [29, 74, 46, 14, 75, 47],
+ [49, 54, 24, 10, 55, 25],
+ [24, 45, 15, 46, 46, 16],
+ [4, 152, 122, 18, 153, 123],
+ [13, 74, 46, 32, 75, 47],
+ [48, 54, 24, 14, 55, 25],
+ [42, 45, 15, 32, 46, 16],
+ [20, 147, 117, 4, 148, 118],
+ [40, 75, 47, 7, 76, 48],
+ [43, 54, 24, 22, 55, 25],
+ [10, 45, 15, 67, 46, 16],
+ [19, 148, 118, 6, 149, 119],
+ [18, 75, 47, 31, 76, 48],
+ [34, 54, 24, 34, 55, 25],
+ [20, 45, 15, 61, 46, 16],
+ ],
+ t = function(e, t) {
+ var n = {};
+ return (n.totalCount = e), (n.dataCount = t), n;
+ },
+ n = {},
+ i = function(t, n) {
+ switch (n) {
+ case r.L:
+ return e[4 * (t - 1) + 0];
+ case r.M:
+ return e[4 * (t - 1) + 1];
+ case r.Q:
+ return e[4 * (t - 1) + 2];
+ case r.H:
+ return e[4 * (t - 1) + 3];
+ default:
+ return;
+ }
+ };
+ return (
+ (n.getRSBlocks = function(e, n) {
+ var r = i(e, n);
+ if ("undefined" == typeof r)
+ throw new Error(
+ "bad rs block @ typeNumber:" +
+ e +
+ "/errorCorrectLevel:" +
+ n
+ );
+ for (
+ var o = r.length / 3, a = new Array(), s = 0; s < o; s += 1
+ )
+ for (
+ var c = r[3 * s + 0],
+ u = r[3 * s + 1],
+ l = r[3 * s + 2],
+ f = 0; f < c; f += 1
+ )
+ a.push(t(u, l));
+ return a;
+ }),
+ n
+ );
+ })(),
+ c = function() {
+ var e = new Array(),
+ t = 0,
+ n = {};
+ return (
+ (n.getBuffer = function() {
+ return e;
+ }),
+ (n.getAt = function(t) {
+ var n = Math.floor(t / 8);
+ return 1 == ((e[n] >>> (7 - (t % 8))) & 1);
+ }),
+ (n.put = function(e, t) {
+ for (var r = 0; r < t; r += 1)
+ n.putBit(1 == ((e >>> (t - r - 1)) & 1));
+ }),
+ (n.getLengthInBits = function() {
+ return t;
+ }),
+ (n.putBit = function(n) {
+ var r = Math.floor(t / 8);
+ e.length <= r && e.push(0),
+ n && (e[r] |= 128 >>> t % 8),
+ (t += 1);
+ }),
+ n
+ );
+ },
+ u = function(e) {
+ var r = n.MODE_8BIT_BYTE,
+ i = t.stringToBytes(e),
+ o = {};
+ return (
+ (o.getMode = function() {
+ return r;
+ }),
+ (o.getLength = function(e) {
+ return i.length;
+ }),
+ (o.write = function(e) {
+ for (var t = 0; t < i.length; t += 1) e.put(i[t], 8);
+ }),
+ o
+ );
+ },
+ l = function() {
+ var e = new Array(),
+ t = {};
+ return (
+ (t.writeByte = function(t) {
+ e.push(255 & t);
+ }),
+ (t.writeShort = function(e) {
+ t.writeByte(e), t.writeByte(e >>> 8);
+ }),
+ (t.writeBytes = function(e, n, r) {
+ (n = n || 0), (r = r || e.length);
+ for (var i = 0; i < r; i += 1) t.writeByte(e[i + n]);
+ }),
+ (t.writeString = function(e) {
+ for (var n = 0; n < e.length; n += 1)
+ t.writeByte(e.charCodeAt(n));
+ }),
+ (t.toByteArray = function() {
+ return e;
+ }),
+ (t.toString = function() {
+ var t = "";
+ t += "[";
+ for (var n = 0; n < e.length; n += 1)
+ n > 0 && (t += ","), (t += e[n]);
+ return (t += "]");
+ }),
+ t
+ );
+ },
+ f = function() {
+ var e = 0,
+ t = 0,
+ n = 0,
+ r = "",
+ i = {},
+ o = function(e) {
+ r += String.fromCharCode(a(63 & e));
+ },
+ a = function(e) {
+ if (e < 0);
+ else {
+ if (e < 26) return 65 + e;
+ if (e < 52) return 97 + (e - 26);
+ if (e < 62) return 48 + (e - 52);
+ if (62 == e) return 43;
+ if (63 == e) return 47;
+ }
+ throw new Error("n:" + e);
+ };
+ return (
+ (i.writeByte = function(r) {
+ for (
+ e = (e << 8) | (255 & r), t += 8, n += 1; t >= 6;
+
+ )
+ o(e >>> (t - 6)), (t -= 6);
+ }),
+ (i.flush = function() {
+ if (
+ (t > 0 && (o(e << (6 - t)), (e = 0), (t = 0)),
+ n % 3 != 0)
+ )
+ for (var i = 3 - (n % 3), a = 0; a < i; a += 1)
+ r += "=";
+ }),
+ (i.toString = function() {
+ return r;
+ }),
+ i
+ );
+ },
+ d = function(e) {
+ var t = e,
+ n = 0,
+ r = 0,
+ i = 0,
+ o = {};
+ o.read = function() {
+ for (; i < 8;) {
+ if (n >= t.length) {
+ if (0 == i) return -1;
+ throw new Error("unexpected end of file./" + i);
+ }
+ var e = t.charAt(n);
+ if (((n += 1), "=" == e)) return (i = 0), -1;
+ e.match(/^\s$/) ||
+ ((r = (r << 6) | a(e.charCodeAt(0))), (i += 6));
+ }
+ var o = (r >>> (i - 8)) & 255;
+ return (i -= 8), o;
+ };
+ var a = function(e) {
+ if (65 <= e && e <= 90) return e - 65;
+ if (97 <= e && e <= 122) return e - 97 + 26;
+ if (48 <= e && e <= 57) return e - 48 + 52;
+ if (43 == e) return 62;
+ if (47 == e) return 63;
+ throw new Error("c:" + e);
+ };
+ return o;
+ },
+ p = function(e, t) {
+ var n = e,
+ r = t,
+ i = new Array(e * t),
+ o = {};
+ (o.setPixel = function(e, t, r) {
+ i[t * n + e] = r;
+ }),
+ (o.write = function(e) {
+ e.writeString("GIF87a"),
+ e.writeShort(n),
+ e.writeShort(r),
+ e.writeByte(128),
+ e.writeByte(0),
+ e.writeByte(0),
+ e.writeByte(0),
+ e.writeByte(0),
+ e.writeByte(0),
+ e.writeByte(255),
+ e.writeByte(255),
+ e.writeByte(255),
+ e.writeString(","),
+ e.writeShort(0),
+ e.writeShort(0),
+ e.writeShort(n),
+ e.writeShort(r),
+ e.writeByte(0);
+ var t = 2,
+ i = s(t);
+ e.writeByte(t);
+ for (var o = 0; i.length - o > 255;)
+ e.writeByte(255),
+ e.writeBytes(i, o, 255),
+ (o += 255);
+ e.writeByte(i.length - o),
+ e.writeBytes(i, o, i.length - o),
+ e.writeByte(0),
+ e.writeString(";");
+ });
+ var a = function(e) {
+ var t = e,
+ n = 0,
+ r = 0,
+ i = {};
+ return (
+ (i.write = function(e, i) {
+ if (e >>> i != 0) throw new Error("length over");
+ for (; n + i >= 8;)
+ t.writeByte(255 & ((e << n) | r)),
+ (i -= 8 - n),
+ (e >>>= 8 - n),
+ (r = 0),
+ (n = 0);
+ (r |= e << n), (n += i);
+ }),
+ (i.flush = function() {
+ n > 0 && t.writeByte(r);
+ }),
+ i
+ );
+ },
+ s = function(e) {
+ for (
+ var t = 1 << e,
+ n = (1 << e) + 1,
+ r = e + 1,
+ o = c(),
+ s = 0; s < t; s += 1
+ )
+ o.add(String.fromCharCode(s));
+ o.add(String.fromCharCode(t)),
+ o.add(String.fromCharCode(n));
+ var u = l(),
+ f = a(u);
+ f.write(t, r);
+ var d = 0,
+ p = String.fromCharCode(i[d]);
+ for (d += 1; d < i.length;) {
+ var h = String.fromCharCode(i[d]);
+ (d += 1),
+ o.contains(p + h) ?
+ (p += h) :
+ (f.write(o.indexOf(p), r),
+ o.size() < 4095 &&
+ (o.size() == 1 << r && (r += 1),
+ o.add(p + h)),
+ (p = h));
+ }
+ return (
+ f.write(o.indexOf(p), r),
+ f.write(n, r),
+ f.flush(),
+ u.toByteArray()
+ );
+ },
+ c = function() {
+ var e = {},
+ t = 0,
+ n = {};
+ return (
+ (n.add = function(r) {
+ if (n.contains(r))
+ throw new Error("dup key:" + r);
+ (e[r] = t), (t += 1);
+ }),
+ (n.size = function() {
+ return t;
+ }),
+ (n.indexOf = function(t) {
+ return e[t];
+ }),
+ (n.contains = function(t) {
+ return "undefined" != typeof e[t];
+ }),
+ n
+ );
+ };
+ return o;
+ },
+ h = function(e, t, n, r) {
+ for (var i = p(e, t), o = 0; o < t; o += 1)
+ for (var a = 0; a < e; a += 1)
+ i.setPixel(a, o, n(a, o));
+ var s = l();
+ i.write(s);
+ for (
+ var c = f(), u = s.toByteArray(), d = 0; d < u.length; d += 1
+ )
+ c.writeByte(u[d]);
+ c.flush();
+ var h = "";
+ return (
+ (h += "<img"),
+ (h += ' src="'),
+ (h += "data:image/gif;base64,"),
+ (h += c),
+ (h += '"'),
+ (h += ' width="'),
+ (h += e),
+ (h += '"'),
+ (h += ' height="'),
+ (h += t),
+ (h += '"'),
+ r && ((h += ' alt="'), (h += r), (h += '"')),
+ (h += "/>")
+ );
+ };
+ return t;
+ })();
+ return (
+ (function(n) {
+ (i = []),
+ (r = n),
+ (o = "function" == typeof r ? r.apply(t, i) : r), !(void 0 !== o && (e.exports = o));
+ })(function() {
+ return n;
+ }), !(function(e) {
+ e.stringToBytes = function(e) {
+ function t(e) {
+ for (var t = [], n = 0; n < e.length; n++) {
+ var r = e.charCodeAt(n);
+ r < 128 ?
+ t.push(r) :
+ r < 2048 ?
+ t.push(192 | (r >> 6), 128 | (63 & r)) :
+ r < 55296 || r >= 57344 ?
+ t.push(
+ 224 | (r >> 12),
+ 128 | ((r >> 6) & 63),
+ 128 | (63 & r)
+ ) :
+ (n++,
+ (r =
+ 65536 +
+ (((1023 & r) << 10) |
+ (1023 & e.charCodeAt(n)))),
+ t.push(
+ 240 | (r >> 18),
+ 128 | ((r >> 12) & 63),
+ 128 | ((r >> 6) & 63),
+ 128 | (63 & r)
+ ));
+ }
+ return t;
+ }
+ return t(e);
+ };
+ })(n),
+ n
+ );
+ })(),
+ l = function(e, t) {
+ var n =
+ arguments.length > 2 && void 0 !== arguments[2] ?
+ arguments[2] :
+ 1;
+ n = Math.max(1, n);
+ for (var r = n; r <= 40; r += 1)
+ try {
+ var i = (function() {
+ var n = u(r, t);
+ n.addData(e), n.make();
+ var i = n.getModuleCount(),
+ o = function(e, t) {
+ return (
+ e >= 0 && e < i && t >= 0 && t < i && n.isDark(e, t)
+ );
+ };
+ return {
+ v: {
+ text: e,
+ level: t,
+ version: r,
+ moduleCount: i,
+ isDark: o,
+ },
+ };
+ })();
+ if (
+ "object" ===
+ ("undefined" == typeof i ? "undefined" : s(i))
+ )
+ return i.v;
+ } catch (e) {
+ if (!(r < 40 && c.test(e.message))) throw e;
+ }
+ return null;
+ },
+ f = function() {
+ var e =
+ arguments.length > 0 && void 0 !== arguments[0] ?
+ arguments[0] :
+ "",
+ t =
+ arguments.length > 1 && void 0 !== arguments[1] ?
+ arguments[1] :
+ "L",
+ n =
+ arguments.length > 2 && void 0 !== arguments[2] ?
+ arguments[2] :
+ 1,
+ r =
+ arguments.length > 3 && void 0 !== arguments[3] ?
+ arguments[3] :
+ 0,
+ i = l(e, t, n);
+ if (i) {
+ var o = i.isDark;
+ (i.moduleCount += 2 * r),
+ (i.isDark = function(e, t) {
+ return o(e - r, t - r);
+ });
+ }
+ return i;
+ };
+ n.exports = f;
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(5),
+ i = n(6),
+ o = function(e, t) {
+ (e.fillStyle = t.back), e.fillRect(0, 0, t.size, t.size);
+ },
+ a = function(e, t, n, r, i, o) {
+ e.isDark(i, o) && t.rect(o * r, i * r, r, r);
+ },
+ s = function(e, t, n) {
+ if (e) {
+ var i = n.rounded > 0 && n.rounded <= 100 ? r : a,
+ o = e.moduleCount,
+ s = n.size / o,
+ c = 0;
+ n.crisp &&
+ ((s = Math.floor(s)),
+ (c = Math.floor((n.size - s * o) / 2))),
+ t.translate(c, c),
+ t.beginPath();
+ for (var u = 0; u < o; u += 1)
+ for (var l = 0; l < o; l += 1) i(e, t, n, s, u, l);
+ (t.fillStyle = n.fill), t.fill(), t.translate(-c, -c);
+ }
+ },
+ c = function(e, t, n) {
+ o(t, n), s(e, t, n), i(t, n);
+ };
+ e.exports = c;
+ },
+ function(e, t) {
+ "use strict";
+ var n = function(e) {
+ return {
+ c: e,
+ m: function() {
+ var e;
+ return (e = this.c).moveTo.apply(e, arguments), this;
+ },
+ l: function() {
+ var e;
+ return (e = this.c).lineTo.apply(e, arguments), this;
+ },
+ a: function() {
+ var e;
+ return (e = this.c).arcTo.apply(e, arguments), this;
+ },
+ };
+ },
+ r = function(e, t, n, r, i, o, a, s, c, u) {
+ a ? e.m(t + o, n) : e.m(t, n),
+ s ? e.l(r - o, n).a(r, n, r, i, o) : e.l(r, n),
+ c ? e.l(r, i - o).a(r, i, t, i, o) : e.l(r, i),
+ u ? e.l(t + o, i).a(t, i, t, n, o) : e.l(t, i),
+ a ? e.l(t, n + o).a(t, n, r, n, o) : e.l(t, n);
+ },
+ i = function(e, t, n, r, i, o, a, s, c, u) {
+ a &&
+ e
+ .m(t + o, n)
+ .l(t, n)
+ .l(t, n + o)
+ .a(t, n, t + o, n, o),
+ s &&
+ e
+ .m(r - o, n)
+ .l(r, n)
+ .l(r, n + o)
+ .a(r, n, r - o, n, o),
+ c &&
+ e
+ .m(r - o, i)
+ .l(r, i)
+ .l(r, i - o)
+ .a(r, i, r - o, i, o),
+ u &&
+ e
+ .m(t + o, i)
+ .l(t, i)
+ .l(t, i - o)
+ .a(t, i, t + o, i, o);
+ },
+ o = function(e, t, o, a, s, c) {
+ var u = c * a,
+ l = s * a,
+ f = u + a,
+ d = l + a,
+ p = 0.005 * o.rounded * a,
+ h = e.isDark,
+ g = s - 1,
+ m = s + 1,
+ v = c - 1,
+ b = c + 1,
+ w = h(s, c),
+ y = h(g, v),
+ x = h(g, c),
+ k = h(g, b),
+ _ = h(s, b),
+ C = h(m, b),
+ S = h(m, c),
+ A = h(m, v),
+ T = h(s, v);
+ (t = n(t)),
+ w
+ ?
+ r(
+ t,
+ u,
+ l,
+ f,
+ d,
+ p, !x && !T, !x && !_, !S && !_, !S && !T
+ ) :
+ i(
+ t,
+ u,
+ l,
+ f,
+ d,
+ p,
+ x && T && y,
+ x && _ && k,
+ S && _ && C,
+ S && T && A
+ );
+ };
+ e.exports = o;
+ },
+ function(e, t) {
+ "use strict";
+ var n = function(e, t) {
+ var n = t.size,
+ r = "bold " + 0.01 * t.mSize * n + "px " + t.fontname;
+ (e.strokeStyle = t.back),
+ (e.lineWidth = 0.01 * t.mSize * n * 0.1),
+ (e.fillStyle = t.fontcolor),
+ (e.font = r);
+ var i = e.measureText(t.label).width,
+ o = 0.01 * t.mSize,
+ a = i / n,
+ s = (1 - a) * t.mPosX * 0.01,
+ c = (1 - o) * t.mPosY * 0.01,
+ u = s * n,
+ l = c * n + 0.75 * t.mSize * 0.01 * n;
+ e.strokeText(t.label, u, l), e.fillText(t.label, u, l);
+ },
+ r = function(e, t) {
+ var n = t.size,
+ r = t.image.naturalWidth || 1,
+ i = t.image.naturalHeight || 1,
+ o = 0.01 * t.mSize,
+ a = (o * r) / i,
+ s = (1 - a) * t.mPosX * 0.01,
+ c = (1 - o) * t.mPosY * 0.01,
+ u = s * n,
+ l = c * n,
+ f = a * n,
+ d = o * n;
+ e.draw_image(t.image, u, l, f, d);
+ },
+ i = function(e, t) {
+ var i = t.mode;
+ "label" === i ? n(e, t) : "image" === i && r(e, t);
+ };
+ e.exports = i;
+ },
+ ]);
+ });
+ },
+ function(e, t, n) {
+ (function(e) {
+ "use strict";
+ var t = n(2),
+ r = t.each,
+ i = t.isStr,
+ o = t.dom,
+ a = n(8),
+ s = n(12),
+ c = n(19),
+ u = n(35),
+ l = n(14),
+ f = n(16),
+ d = e.window,
+ p = Object.assign({ enabled: !1, lang: "en", useBrowserLang: !0 },
+ l.l10n
+ ),
+ h = {
+ isoCode: "en",
+ lang: "english",
+ dateFormat: "YYYY-MM-DD HH:mm",
+ details: "details",
+ download: "download",
+ empty: "empty",
+ files: "files",
+ filter: "filter",
+ folders: "folders",
+ grid: "grid",
+ icons: "icons",
+ language: "Language",
+ lastModified: "Last modified",
+ name: "Name",
+ noMatch: "no match",
+ parentDirectory: "Parent Directory",
+ search: "search",
+ size: "Size",
+ tree: "Tree",
+ view: "View",
+ },
+ g =
+ '<div class="block">\n <h1 class="l10n-language">Language</h1>\n <div class="select">\n <select id="langs"/>\n </div>\n </div>',
+ m = "<option/>",
+ v = "ext/l10n",
+ b = { en: Object.assign({}, h) },
+ w = b.en,
+ y = function(e) {
+ e && (w = e);
+ var t = "selected";
+ o("#langs option").rmAttr(t).rmProp(t),
+ o("#langs ." + w.isoCode)
+ .attr(t, "")
+ .prop(t, !0),
+ r(w, function(e, t) {
+ o(".l10n-" + t).text(e),
+ o(".l10n_ph-" + t).attr("placeholder", e);
+ }),
+ c.setDefaultDateFormat(w.dateFormat),
+ o("#items .item").each(function(e) {
+ o(e).find(".date").text(c.formatDate(e._item.time));
+ });
+ },
+ x = function(e) {
+ return b[e] ?
+ Promise.resolve(b[e]) :
+ a.request({ action: "get", l10n: [e] }).then(function(t) {
+ return (
+ (b[e] = Object.assign({}, h, t.l10n && t.l10n[e], {
+ isoCode: e,
+ })),
+ b[e]
+ );
+ });
+ },
+ k = function(e, t, n) {
+ var r = f.get(v);
+ if (e[r]) t = r;
+ else if (n) {
+ var i = d.navigator.language || d.navigator.browserLanguage;
+ i &&
+ (e[i] ?
+ (t = i) :
+ i.length > 2 && e[i.substr(0, 2)] && (t = i.substr(0, 2)));
+ }
+ e[t] || (t = "en"), x(t).then(y);
+ },
+ _ = function(e) {
+ var t = o(g),
+ n = t.find("select").on("change", function(t) {
+ var n = t.target.value;
+ f.put(v, n), k(e, n, !1);
+ });
+ r(e, function(e, t) {
+ o(m)
+ .attr("value", t)
+ .addCls(t)
+ .text(t + " - " + (i(e) ? e : e.lang))
+ .appTo(n);
+ }),
+ t.appTo("#sidebar");
+ },
+ C = function() {
+ p.enabled && _(u),
+ s.sub("view.changed", function() {
+ k(u, p.lang, p.useBrowserLang);
+ });
+ };
+ C();
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(7),
+ i = r.langs;
+ e.exports = Object.assign({}, i);
+ },
+ function(e, t, n) {
+ (function(e) {
+ "use strict";
+ var t = n(2),
+ r = t.dom,
+ i = t.awaitLoad,
+ o = n(12),
+ a = n(14),
+ s = e.window,
+ c = Object.assign({ enabled: !1, baseURL: "not-set", idSite: 0 },
+ a["piwik-analytics"]
+ ),
+ u = function() {
+ if (c.enabled) {
+ var e =
+ ("https:" === s.location.protocol ? "https://" : "http://") +
+ c.baseURL +
+ "/",
+ t = [],
+ n = null;
+ r("<script></script>")
+ .attr("src", e + "piwik.js")
+ .appTo("body"),
+ i().then(function() {
+ if (
+ (n =
+ s.Piwik && s.Piwik.getTracker(e + "piwik.php", c.idSite))
+ )
+ for (n.enableLinkTracking(); t.length;)
+ n.trackPageView(t.shift());
+ }),
+ o.sub("location.changed", function(e) {
+ var r = e
+ .getCrumb()
+ .map(function(e) {
+ return e.label;
+ })
+ .join(" > ");
+ n ? n.trackPageView(r) : t.push(r);
+ });
+ }
+ };
+ u();
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ "use strict";
+ n(38), n(39), n(40), n(41), n(43);
+ },
+ function(e, t, n) {
+ (function(t) {
+ "use strict";
+ var r = n(2),
+ i = r.each,
+ o = r.isFn,
+ a = r.dom,
+ s = r.includes,
+ c = r.compact,
+ u = n(12),
+ l = n(13),
+ f = n(14),
+ d = n(16),
+ p = t.window,
+ h = Object.assign({ enabled: !0 }, f.preview),
+ g =
+ '<div id="pv-overlay">\n <div id="pv-container"></div>\n <div id="pv-spinner"><img class="back"/><img class="spinner" src="' +
+ l.image("spinner") +
+ '"/></div>\n <div id="pv-prev-area" class="hof"><img src="' +
+ l.image("preview-prev") +
+ '"/></div>\n <div id="pv-next-area" class="hof"><img src="' +
+ l.image("preview-next") +
+ '"/></div>\n <div id="pv-bottombar" class="clearfix hof">\n <ul id="pv-buttons">\n <li id="pv-bar-close" class="bar-right bar-button"><img src="' +
+ l.image("preview-close") +
+ '"/></li>\n <li id="pv-bar-raw" class="bar-right"><a class="bar-button" target="_blank"><img src="' +
+ l.image("preview-raw") +
+ '"/></a></li>\n <li id="pv-bar-fullscreen" class="bar-right bar-button"><img src="' +
+ l.image("preview-fullscreen") +
+ '"/></li>\n <li id="pv-bar-next" class="bar-right bar-button"><img src="' +
+ l.image("preview-next") +
+ '"/></li>\n <li id="pv-bar-idx" class="bar-right bar-label"></li>\n <li id="pv-bar-prev" class="bar-right bar-button"><img src="' +
+ l.image("preview-prev") +
+ '"/></li>\n </ul>\n </div>\n </div>',
+ m = "ext/preview",
+ v = d.get(m) || !1,
+ b = null,
+ w = !1,
+ y = null,
+ x = null,
+ k = function() {
+ var e = a("#pv-container"),
+ t = e[0],
+ n = e.children()[0];
+ if (t && n) {
+ var r = t.offsetWidth,
+ i = t.offsetHeight,
+ o = n.offsetWidth,
+ s = n.offsetHeight;
+ a(n).css({
+ left: 0.5 * (r - o) + "px",
+ top: 0.5 * (i - s) + "px",
+ });
+ }
+ },
+ _ = function() {
+ var e = p.document.documentElement,
+ t = e.clientWidth,
+ n = e.clientHeight,
+ r = v ? 0 : 20,
+ i = v ? 0 : 48;
+ a("#pv-container").css({
+ width: t - 2 * r + "px",
+ height: n - 2 * r - i + "px",
+ left: r + "px",
+ top: r + "px",
+ }),
+ a("#pv-spinner").css({
+ left: 0.5 * t + "px",
+ top: 0.5 * n + "px",
+ }),
+ v ?
+ (a("#pv-overlay").addCls("fullscreen"),
+ a("#pv-bar-fullscreen")
+ .find("img")
+ .attr("src", l.image("preview-no-fullscreen"))) :
+ (a("#pv-overlay").rmCls("fullscreen"),
+ a("#pv-bar-fullscreen")
+ .find("img")
+ .attr("src", l.image("preview-fullscreen"))),
+ k(),
+ o(x && x.adjust) && x.adjust();
+ },
+ C = function(e, t) {
+ a("#pv-bar-idx")
+ .text(e + "/" + t)
+ .show();
+ },
+ S = function(e) {
+ a("#pv-bar-raw").show().find("a").attr("href", e);
+ },
+ A = function(e) {
+ a("#pv-buttons .bar-left").rm(),
+ i(e, function(e) {
+ a("<li></li>")
+ .addCls("bar-left")
+ .addCls("bar-label")
+ .text(e)
+ .appTo("#pv-buttons");
+ });
+ },
+ T = function() {
+ var e = a("#pv-overlay .hof");
+ p.clearTimeout(b),
+ e.show(),
+ v &&
+ (b = p.setTimeout(function() {
+ return e.hide();
+ }, 2e3));
+ },
+ E = function() {
+ return x && x.moveIdx(1);
+ },
+ M = function() {
+ return x && x.moveIdx(-1);
+ },
+ D = function() {
+ (v = !v), d.put(m, v), T(), _();
+ },
+ P = function(e) {
+ e.stopPropagation(), e.preventDefault();
+ },
+ z = function(e) {
+ var t = e.keyCode;
+ 27 === t ?
+ (P(e), $()) :
+ 8 === t || 37 === t ?
+ (P(e), M()) :
+ 13 === t || 32 === t || 39 === t ?
+ (P(e), E()) :
+ 70 === t && (P(e), D());
+ },
+ L = function() {
+ A([]),
+ a("#pv-container").clr(),
+ a("#pv-overlay").show(),
+ a(p).on("keydown", z),
+ _();
+ },
+ $ = function() {
+ A([]),
+ a("#pv-container").clr(),
+ a("#pv-overlay").hide(),
+ a(p).off("keydown", z);
+ },
+ H = function e(t, n, r) {
+ p.clearTimeout(y);
+ var i = a("#pv-spinner");
+ if (!t) return (w = !1), void i.hide();
+ if (!w && r)
+ return void(y = p.setTimeout(function() {
+ return e(!0, n);
+ }, r));
+ var o = i.find(".back");
+ n ? o.attr("src", n).show() : o.hide(), (w = !0), i.show();
+ },
+ O = function e(t, n, r, i) {
+ var o = Object.assign(Object.create(e.prototype), {
+ items: t,
+ load: r,
+ adjust: i,
+ });
+ return o.setIdx(n), o;
+ };
+ O.prototype = {
+ setIdx: function(e) {
+ var t = this;
+ (this.idx = (e + this.items.length) % this.items.length),
+ (this.item = this.items[this.idx]),
+ C(this.idx + 1, this.items.length),
+ S(this.item.absHref),
+ A([this.item.label]);
+ var n = this.item;
+ Promise.resolve()
+ .then(function() {
+ i(a("#pv-container *"), function(e) {
+ "function" == typeof e.unload && e.unload();
+ }),
+ a("#pv-container").hide().clr(),
+ H(!0, n.thumbSquare || n.icon, 200);
+ })
+ .then(function() {
+ return t.load(n);
+ })
+ .then(function(e) {
+ n === t.item &&
+ (a("#pv-container").clr().app(e).show(), H(!1), _());
+ });
+ },
+ moveIdx: function(e) {
+ this.setIdx(this.idx + e);
+ },
+ };
+ var B = function(e, t, n) {
+ var r = function(r) {
+ r.$view &&
+ s(e, r.type) &&
+ r.$view.find("a").on("click", function(i) {
+ i.preventDefault();
+ var o = c(
+ a("#items .item").map(function(t) {
+ var n = t._item;
+ return s(e, n.type) ? n : null;
+ })
+ );
+ (x = O(o, o.indexOf(r), t, n)), L();
+ });
+ };
+ u.sub("view.changed", function(e) {
+ return i(e, r);
+ });
+ },
+ R = function() {
+ h.enabled &&
+ (a(g)
+ .hide()
+ .appTo("body")
+ .on("keydown", z)
+ .on("mousemove", T)
+ .on("mousedown", T)
+ .on("click", function(e) {
+ ("pv-overlay" !== e.target.id &&
+ "pv-container" !== e.target.id) ||
+ $();
+ })
+ .on("mousedown", P)
+ .on("mousemove", P)
+ .on("keydown", P)
+ .on("keypress", P),
+ a("#pv-spinner").hide(),
+ a("#pv-bar-prev, #pv-prev-area").on("click", M),
+ a("#pv-bar-next, #pv-next-area").on("click", E),
+ a("#pv-bar-close").on("click", $),
+ a("#pv-bar-fullscreen").on("click", D),
+ a(p).on("resize", _).on("load", _));
+ };
+ (e.exports = {
+ setLabels: A,
+ register: B,
+ get item() {
+ return x && x.item;
+ },
+ }),
+ R();
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.dom,
+ o = n(19),
+ a = n(14),
+ s = n(38),
+ c = Object.assign({ enabled: !1, autoplay: !0, types: [] },
+ a["preview-aud"]
+ ),
+ u = '<audio id="pv-content-aud"/>',
+ l = function() {
+ var e = i("#pv-content-aud")[0];
+ e &&
+ s.setLabels([s.item.label, o.formatDate(1e3 * e.duration, "m:ss")]);
+ },
+ f = function(e) {
+ e.unload = function() {
+ (e.src = ""), e.load();
+ };
+ },
+ d = function(e) {
+ return new Promise(function(t) {
+ var n = i(u)
+ .on("loadedmetadata", function() {
+ return t(n);
+ })
+ .attr("controls", "controls");
+ c.autoplay && n.attr("autoplay", "autoplay"),
+ f(n[0]),
+ n.attr("src", e.absHref);
+ });
+ },
+ p = function() {
+ c.enabled && s.register(c.types, d, l);
+ };
+ p();
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.dom,
+ o = n(8),
+ a = n(14),
+ s = n(38),
+ c = Object.assign({ enabled: !1, size: null, types: [] },
+ a["preview-img"]
+ ),
+ u = '<img id="pv-content-img"/>',
+ l = function() {
+ var e = i("#pv-content-img")[0];
+ if (e) {
+ var t = e.offsetWidth,
+ n = [s.item.label];
+ if (!c.size) {
+ var r = e.naturalWidth,
+ o = e.naturalHeight;
+ n.push(String(r) + "x" + String(o)),
+ n.push(String(((100 * t) / r).toFixed(0)) + "%");
+ }
+ s.setLabels(n);
+ }
+ },
+ f = function(e) {
+ return o
+ .request({
+ action: "get",
+ thumbs: [{ type: "img", href: e, width: c.size, height: 0 }],
+ })
+ .then(function(e) {
+ return e && e.thumbs && e.thumbs[0] ? e.thumbs[0] : null;
+ });
+ },
+ d = function(e) {
+ return Promise.resolve(e.absHref)
+ .then(function(e) {
+ return c.size ? f(e) : e;
+ })
+ .then(function(e) {
+ return new Promise(function(t) {
+ var n = i(u)
+ .on("load", function() {
+ return t(n);
+ })
+ .attr("src", e);
+ });
+ });
+ },
+ p = function() {
+ c.enabled && s.register(c.types, d, l);
+ };
+ p();
+ },
+ function(e, t, n) {
+ (function(e) {
+ "use strict";
+ var t = n(42),
+ r = n(28),
+ i = n(2),
+ o = i.keys,
+ a = i.dom,
+ s = n(14),
+ c = n(38),
+ u = e.window,
+ l = u.XMLHttpRequest,
+ f = Object.assign({ enabled: !1, styles: {} }, s["preview-txt"]),
+ d = '<pre id="pv-content-txt"></pre>',
+ p = '<div id="pv-content-txt"></div>',
+ h = function() {
+ var e = a("#pv-content-txt")[0];
+ if (e) {
+ var t = a("#pv-container")[0];
+ (e.style.height = t.offsetHeight + "px"),
+ c.setLabels([c.item.label, c.item.size + " bytes"]);
+ }
+ },
+ g = function(e) {
+ return new Promise(function(t, n) {
+ var r = new l(),
+ i = function() {
+ if (r.readyState === l.DONE)
+ try {
+ t(r.responseText || "");
+ } catch (e) {
+ n(String(e));
+ }
+ };
+ r.open("GET", e, !0), (r.onreadystatechange = i), r.send();
+ });
+ },
+ m = function(e) {
+ return g(e.absHref)
+ .catch(function(e) {
+ return "[request failed] " + e;
+ })
+ .then(function(n) {
+ var i = f.styles[e.type];
+ if (1 === i) return a(d).text(n);
+ if (2 === i) return a(p).html(r(n));
+ if (3 === i) {
+ var o = a("<code></code>").text(n);
+ return (
+ u.setTimeout(
+ function() {
+ t.el(o[0]);
+ },
+ n.length < 2e4 ? 0 : 500
+ ),
+ a(d).app(o)
+ );
+ }
+ return a(p).text(n);
+ });
+ },
+ v = function() {
+ f.enabled && c.register(o(f.styles), m, h);
+ };
+ v();
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ !(function(t, n) {
+ e.exports = n();
+ })(this, function() {
+ var e = ".lolight",
+ t = "ll-",
+ n = "_nam#2196f3}_num#ec407a}_str#43a047}_rex#ef6c00}_pct#666}_key#555;font-weight:bold}_com#aaa;font-style:italic}"
+ .replace(/_/g, "." + t)
+ .replace(/#/g, "{color:#"),
+ r = /^(a(bstract|lias|nd|rguments|rray|s(m|sert)?|uto)|b(ase|egin|ool(ean)?|reak|yte)|c(ase|atch|har|hecked|lass|lone|ompl|onst|ontinue)|de(bugger|cimal|clare|f(ault|er)?|init|l(egate|ete)?)|do|double|e(cho|ls?if|lse(if)?|nd|nsure|num|vent|x(cept|ec|p(licit|ort)|te(nds|nsion|rn)))|f(allthrough|alse|inal(ly)?|ixed|loat|or(each)?|riend|rom|unc(tion)?)|global|goto|guard|i(f|mp(lements|licit|ort)|n(it|clude(_once)?|line|out|stanceof|t(erface|ernal)?)?|s)|l(ambda|et|ock|ong)|m(odule|utable)|NaN|n(amespace|ative|ext|ew|il|ot|ull)|o(bject|perator|r|ut|verride)|p(ackage|arams|rivate|rotected|rotocol|ublic)|r(aise|e(adonly|do|f|gister|peat|quire(_once)?|scue|strict|try|turn))|s(byte|ealed|elf|hort|igned|izeof|tatic|tring|truct|ubscript|uper|ynchronized|witch)|t(emplate|hen|his|hrows?|ransient|rue|ry|ype(alias|def|id|name|of))|u(n(checked|def(ined)?|ion|less|signed|til)|se|sing)|v(ar|irtual|oid|olatile)|w(char_t|hen|here|hile|ith)|xor|yield)$/,
+ i = "com",
+ o = "key",
+ a = "nam",
+ s = "num",
+ c = "pct",
+ u = "rex",
+ l = "spc",
+ f = "str",
+ d = "unk",
+ p = [
+ [s, /#([0-9a-f]{6}|[0-9a-f]{3})\b/],
+ [i, /(\/\/|#).*?(?=\n|$)/],
+ [i, /\/\*[\s\S]*?\*\//],
+ [i, /<!--[\s\S]*?-->/],
+ [u, /\/(\\\/|[^\n])*?\//],
+ [f, /(['"`])(\\\1|[\s\S])*?\1/],
+ [s, /[+-]?([0-9]*\.?[0-9]+|[0-9]+\.?[0-9]*)([eE][+-]?[0-9]+)?/],
+ [c, /[\\.,:;+\-*\/=<>()[\]{}|?!&@~]/],
+ [l, /\s+/],
+ [a, /[\w$]+/],
+ [d, /./],
+ ],
+ h = function(e) {
+ if ("string" != typeof e) throw new Error("tok: no string");
+ for (var t = [], n = p.length, i = !1; e;)
+ for (var c = 0; c < n; c += 1) {
+ var f = p[c][1].exec(e);
+ if (f && 0 === f.index) {
+ var d = p[c][0];
+ if (d !== u || !i) {
+ var h = f[0];
+ d === a && r.test(h) && (d = o),
+ d === l ?
+ h.indexOf("\n") >= 0 && (i = !1) :
+ (i = d === s || d === a),
+ (e = e.slice(h.length)),
+ t.push([d, h]);
+ break;
+ }
+ }
+ }
+ return t;
+ },
+ g = function(e, t) {
+ if ("undefined" != typeof document) t(document);
+ else if (e) throw new Error("no doc");
+ },
+ m = function(e) {
+ g(!0, function(n) {
+ var r = h(e.textContent);
+ (e.innerHTML = ""),
+ r.forEach(function(r) {
+ var i = n.createElement("span");
+ (i.className = t + r[0]),
+ (i.textContent = r[1]),
+ e.appendChild(i);
+ });
+ });
+ },
+ v = function(t) {
+ g(!0, function(n) {
+ [].forEach.call(n.querySelectorAll(t || e), function(e) {
+ m(e);
+ });
+ });
+ };
+ return (
+ g(!1, function(e) {
+ var t = e.querySelector("head"),
+ r = e.createElement("style");
+ (r.textContent = n),
+ t.insertBefore(r, t.firstChild),
+ /^(i|c|loade)/.test(e.readyState) ?
+ v() :
+ e.addEventListener("DOMContentLoaded", function() {
+ v();
+ });
+ }),
+ (v.tok = h),
+ (v.el = m),
+ v
+ );
+ });
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.dom,
+ o = n(14),
+ a = n(38),
+ s = Object.assign({ enabled: !1, autoplay: !0, types: [] },
+ o["preview-vid"]
+ ),
+ c = '<video id="pv-content-vid"/>',
+ u = function() {
+ var e = i("#pv-content-vid")[0];
+ if (e) {
+ var t = e.offsetWidth,
+ n = e.videoWidth,
+ r = e.videoHeight;
+ a.setLabels([
+ a.item.label,
+ String(n) + "x" + String(r),
+ String(((100 * t) / n).toFixed(0)) + "%",
+ ]);
+ }
+ },
+ l = function(e) {
+ e.unload = function() {
+ (e.src = ""), e.load();
+ };
+ },
+ f = function(e) {
+ return new Promise(function(t) {
+ var n = i(c)
+ .on("loadedmetadata", function() {
+ return t(n);
+ })
+ .attr("controls", "controls");
+ s.autoplay && n.attr("autoplay", "autoplay"),
+ l(n[0]),
+ n.attr("src", e.absHref);
+ });
+ },
+ d = function() {
+ s.enabled && a.register(s.types, f, u);
+ };
+ d();
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.map,
+ o = r.debounce,
+ a = r.parsePattern,
+ s = r.dom,
+ c = n(8),
+ u = n(12),
+ l = n(20),
+ f = n(13),
+ d = n(14),
+ p = n(22),
+ h = n(18),
+ g = Object.assign({ enabled: !1, advanced: !1, debounceTime: 300, ignorecase: !0 },
+ d.search
+ ),
+ m =
+ '<div id="search" class="tool">\n <img src="' +
+ f.image("search") +
+ '" alt="search"/>\n <input class="l10n_ph-search" type="text" value=""/>\n </div>',
+ v = !1,
+ b = "",
+ w = void 0,
+ y = void 0,
+ x = function() {
+ var e =
+ arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "";
+ if (e !== b) {
+ if (((b = e), !e)) return void h.setLocation();
+ w.addCls("pending"),
+ c
+ .request({
+ action: "get",
+ search: {
+ href: l.getAbsHref(),
+ pattern: e,
+ ignorecase: g.ignorecase,
+ },
+ })
+ .then(function(e) {
+ w.rmCls("pending"),
+ h.setHint("noMatch"),
+ h.setItems(
+ i(e.search, function(e) {
+ return p.get(e);
+ })
+ );
+ });
+ }
+ },
+ k = function() {
+ v
+ ?
+ (w.addCls("active"), y[0].focus(), x(a(y.val(), g.advanced))) :
+ (x(), w.rmCls("active"));
+ },
+ _ = function() {
+ (v = !v), k();
+ },
+ C = function() {
+ (v = !1), y.val(""), k();
+ },
+ S = function() {
+ g.enabled &&
+ ((w = s(m).appTo("#toolbar")),
+ (y = w.find("input")),
+ w.find("img").on("click", _),
+ y.on("keyup", o(k, g.debounceTime)),
+ u.sub("location.changed", C));
+ };
+ S();
+ },
+ function(e, t, n) {
+ (function(e) {
+ "use strict";
+ var t = n(2),
+ r = t.each,
+ i = t.dom,
+ o = n(12),
+ a = n(13),
+ s = n(14),
+ c = e.window.document,
+ u = Object.assign({ enabled: !1, clickndrag: !1, checkboxes: !1 },
+ s.select
+ ),
+ l =
+ '<span class="selector">\n <img src="' +
+ a.image("selected") +
+ '" alt="selected"/>\n </span>',
+ f = i(c),
+ d = i("html"),
+ p = i('<div id="selection-rect"></div>'),
+ h = Math.max,
+ g = Math.min,
+ m = Math.abs,
+ v = 0,
+ b = 0,
+ w = function() {
+ var e = i("#items .item.selected").map(function(e) {
+ return e._item;
+ });
+ o.pub("selection", e);
+ },
+ y = function(e) {
+ var t = i(e);
+ if (!t.length || t.isHidden()) return null;
+ var n = t[0].getBoundingClientRect();
+ return { l: n.left, t: n.top, r: n.right, b: n.bottom };
+ },
+ x = function(e, t) {
+ return (!!e &&
+ !!t &&
+ e.l === t.l &&
+ e.t === t.t &&
+ e.r === t.r &&
+ e.b === t.b
+ );
+ },
+ k = function(e) {
+ var t = e[0];
+ x(y(t), t && t._rect) ||
+ e.each(function(e) {
+ e._rect = y(e);
+ });
+ },
+ _ = function(e, t) {
+ if (!e || !t) return !1;
+ var n = h(e.l, t.l),
+ r = g(e.r, t.r),
+ i = h(e.t, t.t),
+ o = g(e.b, t.b);
+ return n <= r && i <= o;
+ },
+ C = function(e) {
+ var t = i("#content")[0],
+ n = y(t),
+ r = e.pageX - n.l + t.scrollLeft,
+ o = e.pageY - n.t + t.scrollTop;
+ return { x: r, y: o };
+ },
+ S = function(e) {
+ var t = C(e),
+ n = t.x,
+ r = t.y,
+ o = g(v, n),
+ a = g(b, r),
+ s = m(v - n),
+ c = m(b - r),
+ u = e.ctrlKey || e.metaKey;
+ if (!(!u && s < 4 && c < 4)) {
+ u || i("#items .item").rmCls("selected"),
+ d.addCls("drag-select"),
+ p
+ .show()
+ .css({
+ left: o + "px",
+ top: a + "px",
+ width: s + "px",
+ height: c + "px",
+ });
+ var l = y(p),
+ f = i("#items .item:not(.folder-parent)");
+ k(f),
+ f.rmCls("selecting").each(function(e) {
+ _(l, e._rect) && i(e).addCls("selecting");
+ });
+ }
+ },
+ A = function e(t) {
+ f.off("mousemove", S).off("mouseup", e),
+ S(t),
+ i("#items .item.selecting.selected")
+ .rmCls("selecting")
+ .rmCls("selected"),
+ i("#items .item.selecting").rmCls("selecting").addCls("selected"),
+ w(),
+ d.rmCls("drag-select"),
+ p.hide(),
+ t.stopPropagation(),
+ t.preventDefault();
+ },
+ T = function(e) {
+ if (!(
+ 0 !== e.button || e.offsetX >= i("#content")[0].offsetWidth - 16
+ )) {
+ var t = C(e),
+ n = t.x,
+ r = t.y;
+ (v = n),
+ (b = r),
+ f.on("mousemove", S).on("mouseup", A),
+ S(e),
+ e.preventDefault();
+ }
+ },
+ E = function(e) {
+ for (; !e._item && e.parentNode;) e = e.parentNode;
+ return e._item;
+ },
+ M = function(e) {
+ E(e.target).$view.tglCls("selected"),
+ w(),
+ e.stopPropagation(),
+ e.preventDefault();
+ },
+ D = function(e) {
+ e.$view &&
+ !e.isCurrentParentFolder() &&
+ i(l).on("click", M).appTo(e.$view.find("a"));
+ },
+ P = function(e, t) {
+ u.checkboxes && r(e, D),
+ r(t, function(e) {
+ e.$view && e.$view.rmCls("selected");
+ }),
+ w();
+ },
+ z = function() {
+ u.enabled &&
+ (u.clickndrag || u.checkboxes) &&
+ (o.sub("view.changed", P),
+ u.clickndrag &&
+ (p.hide().appTo("#content"),
+ i("#content")
+ .on("mousedown", T)
+ .on("drag", function(e) {
+ return e.preventDefault();
+ })
+ .on("dragstart", function(e) {
+ return e.preventDefault();
+ })));
+ };
+ z();
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.each,
+ o = r.toArray,
+ a = r.dom,
+ s = r.cmp,
+ c = r.naturalCmp,
+ u = n(12),
+ l = n(13),
+ f = n(14),
+ d = n(16),
+ p = Object.assign({
+ enabled: !1,
+ column: 0,
+ reverse: !1,
+ ignorecase: !0,
+ natural: !1,
+ folders: 0,
+ },
+ f.sort
+ ),
+ h = "ext/sort",
+ g =
+ '<img src="' + l.image("sort") + '" class="sort" alt="sort order"/>',
+ m = function(e) {
+ return e.isFolder() ? p.folders : 1;
+ },
+ v = { 0: "label", 1: "time", 2: "size" },
+ b = { 0: "label", 1: "date", 2: "size" },
+ w = function(e, t, n, r) {
+ return function(i, o) {
+ var a = i._item,
+ u = o._item,
+ l = m(a) - m(u);
+ if (0 !== l) return l;
+ var f = a[e],
+ d = u[e];
+ return (
+ (isNaN(f) || isNaN(d)) &&
+ ((f = String(f)),
+ (d = String(d)),
+ n && ((f = f.toLowerCase()), (d = d.toLowerCase()))),
+ (l = r ? c(f, d) : s(f, d)),
+ t ? -l : l
+ );
+ };
+ },
+ y = function(e, t) {
+ var n = a("#items li.header a"),
+ r = a("#items li.header a." + b[e]),
+ i = w(v[e], t, p.ignorecase, p.natural);
+ d.put(h, { column: e, reverse: t }),
+ n.rmCls("ascending").rmCls("descending"),
+ r.addCls(t ? "descending" : "ascending"),
+ a(o(a("#items .item:not(.folder-parent)")).sort(i)).appTo("#items");
+ },
+ x = function() {
+ var e = d.get(h),
+ t = (e && e.column) || p.column,
+ n = (e && e.reverse) || p.reverse;
+ y(t, n);
+ },
+ k = function() {
+ var e = a("#items li.header");
+ i(b, function(t, n) {
+ var r = "0" === n ? "app" : "pre";
+ e.find("a." + t)[r](g)
+ .on("click", function(e) {
+ y(n, a(e.currentTarget).hasCls("ascending")),
+ e.preventDefault();
+ });
+ });
+ },
+ _ = function() {
+ p.enabled && (k(), u.sub("view.changed", x));
+ };
+ _();
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.each,
+ o = r.map,
+ a = r.includes,
+ s = n(8),
+ c = n(12),
+ u = n(14),
+ l = Object.assign({
+ enabled: !1,
+ img: ["img-bmp", "img-gif", "img-ico", "img-jpg", "img-png"],
+ mov: [
+ "vid-avi",
+ "vid-flv",
+ "vid-mkv",
+ "vid-mov",
+ "vid-mp4",
+ "vid-mpg",
+ "vid-webm",
+ ],
+ doc: ["x-pdf", "x-ps"],
+ delay: 1,
+ size: 100,
+ exif: !1,
+ chunksize: 20,
+ },
+ u.thumbnails
+ ),
+ f = 4 / 3,
+ d = function(e, t) {
+ var n = null;
+ if (a(l.img, t.type)) n = "img";
+ else if (a(l.mov, t.type)) n = "mov";
+ else {
+ if (!a(l.doc, t.type)) return;
+ n = "doc";
+ }
+ t.thumbSquare ?
+ t.$view
+ .find(".icon.square img")
+ .addCls("thumb")
+ .attr("src", t.thumbSquare) :
+ e.push({
+ type: n,
+ href: t.absHref,
+ ratio: 1,
+ callback: function(e) {
+ e &&
+ t.$view &&
+ ((t.thumbSquare = e),
+ t.$view
+ .find(".icon.square img")
+ .addCls("thumb")
+ .attr("src", e));
+ },
+ }),
+ t.thumbRational ?
+ t.$view
+ .find(".icon.landscape img")
+ .addCls("thumb")
+ .attr("src", t.thumbRational) :
+ e.push({
+ type: n,
+ href: t.absHref,
+ ratio: f,
+ callback: function(e) {
+ e &&
+ t.$view &&
+ ((t.thumbRational = e),
+ t.$view
+ .find(".icon.landscape img")
+ .addCls("thumb")
+ .attr("src", e));
+ },
+ });
+ },
+ p = function(e) {
+ var t = o(e, function(e) {
+ return {
+ type: e.type,
+ href: e.href,
+ width: Math.round(l.size * e.ratio),
+ height: l.size,
+ };
+ });
+ return s.request({ action: "get", thumbs: t }).then(function(t) {
+ i(e, function(e, n) {
+ e.callback(t && t.thumbs ? t.thumbs[n] : null);
+ });
+ });
+ },
+ h = function(e) {
+ for (
+ var t = e.length,
+ n = l.chunksize,
+ r = Promise.resolve(),
+ i = function(t) {
+ r = r.then(function() {
+ return p(e.slice(t, t + n));
+ });
+ },
+ o = 0; o < t; o += n
+ )
+ i(o);
+ },
+ g = function(e) {
+ var t = [];
+ i(e, function(e) {
+ return d(t, e);
+ }),
+ h(t);
+ },
+ m = function(e) {
+ setTimeout(function() {
+ return g(e);
+ }, l.delay);
+ },
+ v = function() {
+ l.enabled && c.sub("view.changed", m);
+ };
+ v();
+ },
+ function(e, t, n) {
+ (function(e) {
+ "use strict";
+ var t = n(12),
+ r = n(14),
+ i = e.window.document,
+ o = Object.assign({ enabled: !1 }, r.title),
+ a = function(e) {
+ var t = e.getCrumb().map(function(e) {
+ return e.label;
+ }),
+ n = t.join(" > ");
+ t.length > 1 && (n = t[t.length - 1] + " - " + n), (i.title = n);
+ },
+ s = function() {
+ o.enabled && t.sub("location.changed", a);
+ };
+ s();
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+ function(e, t, n) {
+ "use strict";
+ var r = n(2),
+ i = r.each,
+ o = r.dom,
+ a = r.cmp,
+ s = r.naturalCmp,
+ c = n(12),
+ u = n(20),
+ l = n(13),
+ f = n(14),
+ d = n(16),
+ p = Object.assign({
+ enabled: !1,
+ show: !0,
+ maxSubfolders: 50,
+ naturalSort: !1,
+ ignorecase: !0,
+ },
+ f.tree
+ ),
+ h =
+ '<div class="item folder">\n <span class="indicator">\n <img src="' +
+ l.image("tree-indicator") +
+ '"/>\n </span>\n <a>\n <span class="icon"><img src="' +
+ l.icon("folder") +
+ '"/></span>\n <span class="label"></span>\n </a>\n </span>',
+ g =
+ '<div class="block">\n <h1 class="l10n-tree">Tree</h1>\n <div id="view-tree" class="button view">\n <img src="' +
+ l.image("tree-toggle") +
+ '" alt="view-tree"/>\n </div>\n </div>',
+ m = "ext/tree",
+ v = function(e) {
+ for (; !e._item && e.parentNode;) e = e.parentNode;
+ return e._item;
+ },
+ b = function(e) {
+ var t = v(e.target);
+ "unknown" === t._treeState ?
+ t.fetchContent().then(function() {
+ (t._treeState = "open"), y(t);
+ }) :
+ "open" === t._treeState ?
+ ((t._treeState = "closed"),
+ t._$tree.rmCls("open").addCls("closed")) :
+ "closed" === t._treeState &&
+ ((t._treeState = "open"),
+ t._$tree.rmCls("closed").addCls("open"));
+ },
+ w = function(e, t) {
+ var n = e.label,
+ r = t.label;
+ return (
+ p.ignorecase && ((n = n.toLowerCase()), (r = r.toLowerCase())),
+ p.naturalSort ? s(n, r) : a(n, r)
+ );
+ },
+ y = function e(t) {
+ var n = t.getSubfolders(),
+ r = n.length,
+ a = p.maxSubfolders,
+ s = o(h);
+ if (
+ (s.find(".indicator").on("click", b),
+ s.find(".label").text(t.label),
+ u.setLink(s.find("a"), t),
+ t.isCurrentFolder() && s.addCls("active"),
+ t.isManaged ||
+ s.find(".icon img").attr("src", l.icon("folder-page")),
+ (t._treeState = t._treeState || "none"),
+ t.isManaged && !t.isContentFetched ?
+ (t._treeState = "unknown") :
+ r || (t._treeState = "none"),
+ s.addCls(t._treeState),
+ r)
+ ) {
+ var c = o('<div class="content"></div>').appTo(s);
+ n.sort(w),
+ i(n.slice(0, a), function(t) {
+ return c.app(e(t));
+ }),
+ r > a &&
+ c.app(
+ '<div class="summary">… ' + (r - a) + " more subfolders</div>"
+ );
+ }
+ return (
+ t._$tree && t._$tree.rpl(s), (t._$tree = s), (s[0]._item = t), s
+ );
+ },
+ x = function e(t) {
+ return (
+ (t._treeState = "open"),
+ t.fetchContent().then(function() {
+ return t.parent ? e(t.parent) : t;
+ })
+ );
+ },
+ k = function() {
+ d.get(m) ?
+ (o("#view-tree").addCls("active"), o("#tree").show()) :
+ (o("#view-tree").rmCls("active"), o("#tree").hide());
+ },
+ _ = function(e) {
+ x(e).then(function(e) {
+ o("#tree").clr().app(y(e)), k();
+ });
+ },
+ C = function() {
+ p.enabled &&
+ (o('<div id="tree"></div>').hide().appTo("#mainrow"),
+ o(g)
+ .appTo("#sidebar")
+ .find("#view-tree")
+ .on("click", function(e) {
+ d.put(m, !d.get(m)), k(), c.pub("resize"), e.preventDefault();
+ }),
+ "boolean" != typeof d.get(m) && d.put(m, p.show),
+ k(),
+ c.sub("location.changed", _));
+ };
+ C();
+ },
+ function(e, t, n) {
+ (function(e) {
+ "use strict";
+ var t = n(2),
+ r = t.dom,
+ i = n(7),
+ o = n(8),
+ a = n(13),
+ s = '<ul id="tests"></ul>',
+ c =
+ '<li class="test">\n <span class="label"></span>\n <span class="result"></span>\n <div class="info"></div>\n </li>',
+ u =
+ '<div id="login-wrapper">\n <input id="pass" type="password" placeholder="password"/>\n <span id="login">login</span>\n <span id="logout">logout</span>\n <div id="hint">\n The preset password is the empty string, just click login.\n Change it in \'_h5ai/private/conf/options.json\'.\n </div>\n </div>',
+ l =
+ '<div id="support">\n Show your support with a donation!\n <div class="paypal">\n <form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_blank">\n <input type="hidden" name="cmd" value="_s-xclick"/>\n <input type="hidden" name="hosted_button_id" value="8WSPKWT7YBTSQ"/>\n <input type="image" src="' +
+ a.image("paypal") +
+ '" name="submit" alt="PayPal"/>\n </form>\n </div>\n </div>',
+ f = i.setup,
+ d = function(e, t, n, i) {
+ var o = r(c).appTo("#tests");
+ o.find(".label").text(e),
+ o
+ .find(".result")
+ .addCls(n ? "passed" : "failed")
+ .text(i ? i : n ? "yes" : "no"),
+ o.find(".info").html(t);
+ },
+ p = function() {
+ f.AS_ADMIN &&
+ (r(s).appTo("#content"),
+ d(
+ "h5ai version",
+ "Only green if this is an official h5ai release",
+ /^\d+\.\d+\.\d+$/.test(f.VERSION),
+ f.VERSION
+ ),
+ d(
+ "Index file found",
+ "Add <code>" + f.INDEX_HREF + "</code> to your index file list",
+ f.INDEX_HREF
+ ),
+ d(
+ "Options parsable",
+ "File <code>options.json</code> is readable and syntax is correct",
+ null !== i.options
+ ),
+ d(
+ "Types parsable",
+ "File <code>types.json</code> is readable and syntax is correct",
+ null !== i.types
+ ),
+ d(
+ "Server software",
+ "Server is one of apache, lighttpd, nginx or cherokee",
+ f.HAS_SERVER,
+ f.SERVER_NAME + " " + f.SERVER_VERSION
+ ),
+ d(
+ "PHP version",
+ "PHP version >= " + f.MIN_PHP_VERSION, !0,
+ f.PHP_VERSION
+ ),
+ d(
+ "PHP arch",
+ "64-bit required to correctly display file/folder sizes > ~2GB",
+ "64-bit" === f.PHP_ARCH,
+ f.PHP_ARCH
+ ),
+ d(
+ "Public Cache directory",
+ "Web server has write access",
+ f.HAS_WRITABLE_CACHE_PUB
+ ),
+ d(
+ "Private Cache directory",
+ "Web server has write access",
+ f.HAS_WRITABLE_CACHE_PRV
+ ),
+ d(
+ "Image thumbs",
+ "PHP GD extension with JPEG support available",
+ f.HAS_PHP_JPEG
+ ),
+ d(
+ "Use EXIF thumbs",
+ "PHP EXIF extension available",
+ f.HAS_PHP_EXIF
+ ),
+ d(
+ "Movie thumbs",
+ "Command line program <code>avconv</code> or <code>ffmpeg</code> available",
+ f.HAS_CMD_AVCONV || f.HAS_CMD_FFMPEG
+ ),
+ d(
+ "PDF thumbs",
+ "Command line program <code>convert</code> or <code>gm</code> available",
+ f.HAS_CMD_CONVERT || f.HAS_CMD_GM
+ ),
+ d(
+ "Shell tar",
+ "Command line program <code>tar</code> available",
+ f.HAS_CMD_TAR
+ ),
+ d(
+ "Shell zip",
+ "Command line program <code>zip</code> available",
+ f.HAS_CMD_ZIP
+ ),
+ d(
+ "Shell du",
+ "Command line program <code>du</code> available",
+ f.HAS_CMD_DU
+ ));
+ },
+ h = function() {
+ e.window.location.reload();
+ },
+ g = function() {
+ o.request({ action: "login", pass: r("#pass").val() }).then(h);
+ },
+ m = function() {
+ o.request({ action: "logout" }).then(h);
+ },
+ v = function(e) {
+ 13 === e.which && g();
+ },
+ b = function() {
+ r(l).appTo("#content");
+ },
+ w = function() {
+ r(u).appTo("#content"),
+ f.AS_ADMIN ?
+ (r("#pass").rm(),
+ r("#login").rm(),
+ r("#logout").on("click", m)) :
+ (r("#pass").on("keydown", v)[0].focus(),
+ r("#login").on("click", g),
+ r("#logout").rm()),
+ i.options.hasCustomPasshash && r("#hint").rm();
+ },
+ y = function() {
+ b(), w(), p();
+ };
+ y();
+ }.call(
+ t,
+ (function() {
+ return this;
+ })()
+ ));
+ },
+]);
\ No newline at end of file
--
2.23.0
2
3
We need to create the access_key in the dir which we want to upload
file, it is hard to handle that.
So we save the upload_dirs in redis, then we can set the field in
scheduler, the result-webdav container will read the value by job id and check the upload dir.
Signed-off-by: Cao Xueliang <caoxl78320(a)163.com>
---
src/lib/job.cr | 23 ++++++++++++++---------
src/scheduler/close_job.cr | 6 ------
src/scheduler/find_job_boot.cr | 10 +++++-----
3 files changed, 19 insertions(+), 20 deletions(-)
diff --git a/src/lib/job.cr b/src/lib/job.cr
index 0083a7d..083a233 100644
--- a/src/lib/job.cr
+++ b/src/lib/job.cr
@@ -88,8 +88,7 @@ class Job
pp_params
submit_date
result_root
- access_key
- access_key_file
+ upload_dirs
lkp_initrd_user
user_lkp_src
kernel_uri
@@ -243,15 +242,21 @@ class Job
def set_result_root
update_tbox_group_from_testbox # id must exists, need update tbox_group
self["result_root"] = File.join("/result/#{suite}/#{submit_date}/#{tbox_group}/#{rootfs}", "#{pp_params}", "#{id}")
-
- # access_key has information based on "result_root"
- # so when set result_root, we need redo set_ to update it
- set_access_key()
+ set_upload_dirs()
end
- private def set_access_key
- self["access_key"] = "#{Random::Secure.hex(10)}-#{id}"
- self["access_key_file"] = File.join("/srv/", "#{result_root}", ".#{access_key}")
+ def set_upload_dirs
+ if @hash["cci-makepkg"]?
+ package_dir = ",/initrd/pkg"
+ elsif @hash["cci-depends"]?
+ package_dir = ",/initrd/deps"
+ elsif @hash["build-pkg"]?
+ package_dir = ",/initrd/build-pkg"
+ else
+ package_dir = ""
+ end
+
+ self["upload_dirs"] = "#{result_root}#{package_dir}"
end
private def set_result_service
diff --git a/src/scheduler/close_job.cr b/src/scheduler/close_job.cr
index 579c2c0..d8f80d7 100644
--- a/src/scheduler/close_job.cr
+++ b/src/scheduler/close_job.cr
@@ -8,8 +8,6 @@ class Sched
job = @redis.get_job(job_id)
- delete_access_key_file(job) if job
-
response = @es.set_job_content(job)
if response["_id"] == nil
# es update fail, raise exception
@@ -27,8 +25,4 @@ class Sched
@log.info(%({"job_id": "#{job_id}", "job_state": "complete"}))
end
-
- def delete_access_key_file(job : Job)
- File.delete(job.access_key_file) if File.exists?(job.access_key_file)
- end
end
diff --git a/src/scheduler/find_job_boot.cr b/src/scheduler/find_job_boot.cr
index 5a11523..6623a5e 100644
--- a/src/scheduler/find_job_boot.cr
+++ b/src/scheduler/find_job_boot.cr
@@ -141,10 +141,6 @@ class Sched
return response
end
- def touch_access_key_file(job : Job)
- FileUtils.touch(job.access_key_file)
- end
-
private def get_boot_ipxe(job : Job)
response = "#!ipxe\n\n"
response += Array(String).from_json(job.initrds_uri).join("\n") + "\n"
@@ -155,8 +151,12 @@ class Sched
return response
end
+ def set_id2upload_dirs(job)
+ @redis.hash_set("sched/id2upload_dirs", job.id, job.upload_dirs)
+ end
+
def boot_content(job : Job | Nil, boot_type : String)
- touch_access_key_file(job) if job
+ set_id2upload_dirs(job) if job
case boot_type
when "ipxe"
--
2.23.0
1
0

[PATCH v1 compass-ci] lib/mail_bisect_result: bisect email use new content
by Cao Xueliang 14 Dec '20
by Cao Xueliang 14 Dec '20
14 Dec '20
1. Add software name and first error message in subject
2. Add gcc version, error messages and job url in mail body
Signed-off-by: Cao Xueliang <caoxl78320(a)163.com>
---
lib/git_bisect.rb | 2 +-
lib/mail_bisect_result.rb | 20 +++++++++-----------
2 files changed, 10 insertions(+), 12 deletions(-)
diff --git a/lib/git_bisect.rb b/lib/git_bisect.rb
index 189edb8..97ad467 100644
--- a/lib/git_bisect.rb
+++ b/lib/git_bisect.rb
@@ -95,7 +95,7 @@ class GitBisect
error_messages = ErrorMessages.new(@build_pkg_dir).obtain_error_messages_by_errorid(@error_id)
return Hash['repo' => @upstream_repo, 'commit' => first_bad_commit,
- 'error_messages' => error_messages.join("\n")]
+ 'error_messages' => error_messages]
end
# first search the good commit in db
diff --git a/lib/mail_bisect_result.rb b/lib/mail_bisect_result.rb
index 5a208c4..c0a2731 100644
--- a/lib/mail_bisect_result.rb
+++ b/lib/mail_bisect_result.rb
@@ -19,23 +19,21 @@ class MailBisectResult
end
def compose_mail
- subject = "[Compass-CI] #{(a)repo}.git: bisect result"
+ subject = "[Compass-CI][#{(a)repo.split('/')[1]}]: #{@error_messages[0]}"
+ job_url = "job url: #{ENV['SRV_HTTP_HOST']}:#{ENV['SRV_HTTP_PORT']}/#{ENV['result_root']}\n" ? ENV['result_root'] : ''
body = <<~BODY
Hi #{(a)git_commit.author_name},
- Bisect completed for
+ git url: #{(a)git_commit.url}
+ git commit: #{@commit_id[0..11]} ("#{(a)git_commit.subject}")
- url: #{(a)git_commit.url}
-
- This is a bisect email from compass-ci. We met some problems when test with new commits.
- Would you help to check what happend?
- After submitting a job we noticed an error response due to the commit:
-
- commit: #{@commit_id[0..11]} ("#{(a)git_commit.subject}")
+ gcc version: 7.3.0
error_messages:
- #{@error_messages}
+ #{(a)error_messages.join("\n")}
- https://gitee.com/openeuler/compass-ci
+ #{job_url}
+ Regards,
+ Compass CI team
BODY
to = 'caoxl(a)crystal.ci'
@hash = { 'to' => to, 'body' => body, 'subject' => subject }
--
2.23.0
1
0

[PATCH v2 lkp-tests] Redirect stderr only for functions that may use lkp-tests customized make
by Lin Jiaxin 14 Dec '20
by Lin Jiaxin 14 Dec '20
14 Dec '20
[Why]
we use makepkg 2>&1 so that many errors are not output to the file stderr now.
Like these:
==> WARNING: Skipping verification of source file PGP signatures.
leptonica-1.79.0.tar.gz ... FAILED
==> ERROR: One or more files did not pass the validity check!
And stats/build-pkg can not analyze them so it ignores them.
[How]
Redirect stderr in functions build(), check(), package() when STDERR_REDIR = y.
Signed-off-by: Lin Jiaxin <ljx.joe(a)qq.com>
---
sbin/makepkg | 18 +++++++++++++++---
tests/build-pkg | 4 ++--
2 files changed, 17 insertions(+), 5 deletions(-)
diff --git a/sbin/makepkg b/sbin/makepkg
index 498b4872..131ae690 100755
--- a/sbin/makepkg
+++ b/sbin/makepkg
@@ -1761,11 +1761,19 @@ run_build() {
[[ -d /usr/lib/ccache/bin ]] && export PATH="/usr/lib/ccache/bin:$PATH"
fi
- run_function_safe "build"
+ if [[ $STDERR_REDIR == y ]];then
+ run_function_safe "build" 2>&1
+ else
+ run_function_safe "build"
+ fi
}
run_check() {
- run_function_safe "check"
+ if [[ $STDERR_REDIR == y ]];then
+ run_function_safe "check" 2>&1
+ else
+ run_function_safe "check"
+ fi
}
run_package() {
@@ -1776,7 +1784,11 @@ run_package() {
pkgfunc="package_$1"
fi
- run_function_safe "$pkgfunc"
+ if [[ $STDERR_REDIR == y ]];then
+ run_function_safe "$pkgfunc" 2>&1
+ else
+ run_function_safe "$pkgfunc"
+ fi
}
build_id() {
diff --git a/tests/build-pkg b/tests/build-pkg
index c6717d48..aafc120e 100755
--- a/tests/build-pkg
+++ b/tests/build-pkg
@@ -125,8 +125,8 @@ build_source_pkg()
[ -n "$PKGBUILD_TAG" ] && replace_source "PKGBUILD-$PKGBUILD_TAG"
cgz_name="$PKG_MNT/${pack_to}/${pkgname}/${upstream_commit}.cgz"
- PACMAN=true BUILDDIR=$TMP CARCH=$os_arch PKGEXT=.cgz CGZDEST="$cgz_name" \
- $LKP_SRC/sbin/makepkg -A --check --skippgpcheck --config $LKP_SRC/etc/makepkg.conf 2>&1
+ PACMAN=true BUILDDIR=$TMP CARCH=$os_arch PKGEXT=.cgz CGZDEST="$cgz_name" STDERR_REDIR=y\
+ $LKP_SRC/sbin/makepkg -A --check --skippgpcheck --config $LKP_SRC/etc/makepkg.conf
[ "$?" == 0 ] || exit 1
create_softlink
--
2.23.0
1
0

[PATCH lkp-tests] Redirect stderr only for functions that may use lkp-tests customized make
by Lin Jiaxin 14 Dec '20
by Lin Jiaxin 14 Dec '20
14 Dec '20
[Why]
we use makepkg 2>&1 so that many errors are not output to the file stderr now.
Like these:
==> WARNING: Skipping verification of source file PGP signatures.
leptonica-1.79.0.tar.gz ... FAILED
==> ERROR: One or more files did not pass the validity check!
And stats/build-pkg can not analyze them so it ignores them.
[How]
Redirect stderr in functions build(), check(), packages() when STDERR_REDIR = y.
Signed-off-by: Lin Jiaxin <ljx.joe(a)qq.com>
---
sbin/makepkg | 18 +++++++++++++++---
tests/build-pkg | 4 ++--
2 files changed, 17 insertions(+), 5 deletions(-)
diff --git a/sbin/makepkg b/sbin/makepkg
index 498b4872..131ae690 100755
--- a/sbin/makepkg
+++ b/sbin/makepkg
@@ -1761,11 +1761,19 @@ run_build() {
[[ -d /usr/lib/ccache/bin ]] && export PATH="/usr/lib/ccache/bin:$PATH"
fi
- run_function_safe "build"
+ if [[ $STDERR_REDIR == y ]];then
+ run_function_safe "build" 2>&1
+ else
+ run_function_safe "build"
+ fi
}
run_check() {
- run_function_safe "check"
+ if [[ $STDERR_REDIR == y ]];then
+ run_function_safe "check" 2>&1
+ else
+ run_function_safe "check"
+ fi
}
run_package() {
@@ -1776,7 +1784,11 @@ run_package() {
pkgfunc="package_$1"
fi
- run_function_safe "$pkgfunc"
+ if [[ $STDERR_REDIR == y ]];then
+ run_function_safe "$pkgfunc" 2>&1
+ else
+ run_function_safe "$pkgfunc"
+ fi
}
build_id() {
diff --git a/tests/build-pkg b/tests/build-pkg
index c6717d48..aafc120e 100755
--- a/tests/build-pkg
+++ b/tests/build-pkg
@@ -125,8 +125,8 @@ build_source_pkg()
[ -n "$PKGBUILD_TAG" ] && replace_source "PKGBUILD-$PKGBUILD_TAG"
cgz_name="$PKG_MNT/${pack_to}/${pkgname}/${upstream_commit}.cgz"
- PACMAN=true BUILDDIR=$TMP CARCH=$os_arch PKGEXT=.cgz CGZDEST="$cgz_name" \
- $LKP_SRC/sbin/makepkg -A --check --skippgpcheck --config $LKP_SRC/etc/makepkg.conf 2>&1
+ PACMAN=true BUILDDIR=$TMP CARCH=$os_arch PKGEXT=.cgz CGZDEST="$cgz_name" STDERR_REDIR=y\
+ $LKP_SRC/sbin/makepkg -A --check --skippgpcheck --config $LKP_SRC/etc/makepkg.conf
[ "$?" == 0 ] || exit 1
create_softlink
--
2.23.0
1
0
The file permission should be consistent with the other file in this
directory
Signed-off-by: Zhang Yu <2134782174(a)qq.com>
---
spec/local_run_spec.rb | 0
1 file changed, 0 insertions(+), 0 deletions(-)
mode change 100755 => 100644 spec/local_run_spec.rb
diff --git a/spec/local_run_spec.rb b/spec/local_run_spec.rb
old mode 100755
new mode 100644
--
2.23.0
1
0

14 Dec '20
[why]
key my_uuid is renamed to my_token
item key my_token will be stored in file:
~/.config/compass-ci/include/lab/${lab}.yaml
to do this change with no sense:
for old user(update account):
keep my_uuid in the default yaml
add my_token to ~/.config/compass-ci/include/lab/${lab}.yaml
my_token has the same value to my_uuid
for new user:
add my_email, my_name to the default yaml
add my_token to ~/.config/compass-ci/include/lab/${lab}.yaml
Signed-off-by: Luan Shengde <shdluan(a)163.com>
---
container/assign-account/get_account_info.rb | 47 ++++++++++++++++----
1 file changed, 38 insertions(+), 9 deletions(-)
diff --git a/container/assign-account/get_account_info.rb b/container/assign-account/get_account_info.rb
index 95bec14..8015a5f 100755
--- a/container/assign-account/get_account_info.rb
+++ b/container/assign-account/get_account_info.rb
@@ -110,7 +110,7 @@ class AccountStorage
jumper_host, jumper_port = read_jumper_info
config_authorized_key(login_name)
- config_default_yaml(login_name)
+ config_yaml(login_name)
permit_login_config(login_name)
if @data.key?('gen_sshkey') && @data['gen_sshkey']
my_jumper_pubkey = generate_ssh_key(login_name)
@@ -127,6 +127,14 @@ class AccountStorage
return jumper_account_info
end
+ def config_yaml(login_name)
+ default_yaml = touch_default_yaml(login_name)
+ config_default_yaml(login_name, default_yaml)
+
+ lab_yaml = touch_lab_yaml(login_name)
+ config_lab_yaml(login_name, lab_yaml)
+ end
+
def permit_login_config(login_name)
if @data.key?('enable_login') && @data['enable_login']
%x(usermod -s /usr/bin/zsh #{login_name})
@@ -151,26 +159,47 @@ class AccountStorage
def touch_default_yaml(login_name)
default_yaml_dir = File.join('/home', login_name, '.config/compass-ci/defaults')
+ # before create the file, the directory need to be exists
FileUtils.mkdir_p default_yaml_dir unless File.exist? default_yaml_dir
default_yaml = File.join(default_yaml_dir, 'account.yaml')
+ # for we need to read the file before we open it
+ # need to firstly create the file
FileUtils.touch default_yaml unless File.exist? default_yaml
default_yaml
end
- def config_default_yaml(login_name)
- default_yaml = touch_default_yaml(login_name)
-
+ def config_default_yaml(login_name, default_yaml)
account_yaml = YAML.load_file(default_yaml) || {}
- # my_email, my_name, my_uuid is required to config default yaml file
+ # my_email, my_name is required to config default yaml file
# they are added along with 'my_ssh_pubkey' when sending assign account request
account_yaml['my_email'] = @data['my_email']
account_yaml['my_name'] = @data['my_name']
- account_yaml['my_uuid'] = @data['my_uuid']
- f = File.new(default_yaml, 'w')
- f.puts account_yaml.to_yaml
- f.close
+ File.open(default_yaml, 'w') do |f|
+ f.puts account_yaml.to_yaml
+ end
+
+ FileUtils.chown_R(login_name, login_name, "/home/#{login_name}/.config")
+ end
+
+ def touch_lab_yaml(login_name)
+ lab_yaml_dir = File.join('/home', login_name, '.config/compass-ci/include/lab')
+ FileUtils.mkdir_p lab_yaml_dir unless File.exist? lab_yaml_dir
+
+ lab_yaml = File.join(lab_yaml_dir, "#{@data['lab']}.yaml")
+ FileUtils.touch lab_yaml unless File.exist? lab_yaml
+ lab_yaml
+ end
+
+ def config_lab_yaml(login_name, lab_yaml)
+ lab_yaml_info = YAML.load_file(lab_yaml) || {}
+ lab_yaml_info['my_token'] = @data['my_token']
+
+ File.open(lab_yaml, 'w') do |f|
+ f.puts lab_yaml_info.to_yaml
+ end
+
FileUtils.chown_R(login_name, login_name, "/home/#{login_name}/.config")
end
--
2.23.0
1
0