From ab65a5e803f88f76d0eb701b5ae7c62945164c05 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn?= Date: Thu, 21 Jan 2021 00:12:03 +0100 Subject: [PATCH] adding --- README.md | 58 ------------------- ...ucketController.php => FileController.php} | 12 ++-- app/Http/Controllers/BucketController.php | 51 +++++++++++++++- public/js/bootstrap.js | 4 +- public/js/bucket-single.js | 1 + public/js/bucket.js | 4 +- public/js/home.js | 2 +- public/mix-manifest.json | 1 + public/spritemap.js | 2 +- .../js/components/bucket/filemanager.riot | 56 ++++++++++++++++++ .../js/components/filemanager/actions.riot | 0 .../js/components/filemanager/directory.riot | 0 resources/js/components/filemanager/file.riot | 21 +++++++ .../components/filemanager/filemanager.riot | 32 ++++++++++ resources/js/views/bucket-single.js | 10 ++++ resources/views/bucket/single.blade.php | 8 +-- webpack.mix.js | 1 + 17 files changed, 189 insertions(+), 74 deletions(-) rename app/Http/Controllers/Api/{BucketController.php => FileController.php} (64%) create mode 100644 public/js/bucket-single.js create mode 100644 resources/js/components/bucket/filemanager.riot create mode 100644 resources/js/components/filemanager/actions.riot create mode 100644 resources/js/components/filemanager/directory.riot create mode 100644 resources/js/components/filemanager/file.riot create mode 100644 resources/js/components/filemanager/filemanager.riot create mode 100644 resources/js/views/bucket-single.js diff --git a/README.md b/README.md index 2f7ddcc..a983967 100644 --- a/README.md +++ b/README.md @@ -1,61 +1,3 @@ -

-

-Build Status -Total Downloads -Latest Stable Version -License -

- -## About Laravel - -Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable and creative experience to be truly fulfilling. Laravel takes the pain out of development by easing common tasks used in many web projects, such as: - -- [Simple, fast routing engine](https://laravel.com/docs/routing). -- [Powerful dependency injection container](https://laravel.com/docs/container). -- Multiple back-ends for [session](https://laravel.com/docs/session) and [cache](https://laravel.com/docs/cache) storage. -- Expressive, intuitive [database ORM](https://laravel.com/docs/eloquent). -- Database agnostic [schema migrations](https://laravel.com/docs/migrations). -- [Robust background job processing](https://laravel.com/docs/queues). -- [Real-time event broadcasting](https://laravel.com/docs/broadcasting). - -Laravel is accessible, powerful, and provides tools required for large, robust applications. - -## Learning Laravel - -Laravel has the most extensive and thorough [documentation](https://laravel.com/docs) and video tutorial library of all modern web application frameworks, making it a breeze to get started with the framework. - -If you don't feel like reading, [Laracasts](https://laracasts.com) can help. Laracasts contains over 1500 video tutorials on a range of topics including Laravel, modern PHP, unit testing, and JavaScript. Boost your skills by digging into our comprehensive video library. - -## Laravel Sponsors - -We would like to extend our thanks to the following sponsors for funding Laravel development. If you are interested in becoming a sponsor, please visit the Laravel [Patreon page](https://patreon.com/taylorotwell). - -### Premium Partners - -- **[Vehikl](https://vehikl.com/)** -- **[Tighten Co.](https://tighten.co)** -- **[Kirschbaum Development Group](https://kirschbaumdevelopment.com)** -- **[64 Robots](https://64robots.com)** -- **[Cubet Techno Labs](https://cubettech.com)** -- **[Cyber-Duck](https://cyber-duck.co.uk)** -- **[Many](https://www.many.co.uk)** -- **[Webdock, Fast VPS Hosting](https://www.webdock.io/en)** -- **[DevSquad](https://devsquad.com)** -- **[OP.GG](https://op.gg)** - -## Contributing - -Thank you for considering contributing to the Laravel framework! The contribution guide can be found in the [Laravel documentation](https://laravel.com/docs/contributions). - -## Code of Conduct - -In order to ensure that the Laravel community is welcoming to all, please review and abide by the [Code of Conduct](https://laravel.com/docs/contributions#code-of-conduct). - -## Security Vulnerabilities - -If you discover a security vulnerability within Laravel, please send an e-mail to Taylor Otwell via [taylor@laravel.com](mailto:taylor@laravel.com). All security vulnerabilities will be promptly addressed. - -## License The Laravel framework is open-sourced software licensed under the [MIT license](https://opensource.org/licenses/MIT). diff --git a/app/Http/Controllers/Api/BucketController.php b/app/Http/Controllers/Api/FileController.php similarity index 64% rename from app/Http/Controllers/Api/BucketController.php rename to app/Http/Controllers/Api/FileController.php index cb20b86..78a4a18 100644 --- a/app/Http/Controllers/Api/BucketController.php +++ b/app/Http/Controllers/Api/FileController.php @@ -7,17 +7,21 @@ use Illuminate\Foundation\Bus\DispatchesJobs; use Illuminate\Foundation\Validation\ValidatesRequests; use Illuminate\Routing\Controller as BaseController; -class BucketController extends BaseController +class FileController extends BaseController { use AuthorizesRequests, DispatchesJobs, ValidatesRequests; /** * - * @return [type] [description] + * @return object * */ - public function store() + public function index() { - + $files = scandir($dir); + + return response()->json([ + 'files' => $files + ]); } } diff --git a/app/Http/Controllers/BucketController.php b/app/Http/Controllers/BucketController.php index 189c1ef..3ddee74 100644 --- a/app/Http/Controllers/BucketController.php +++ b/app/Http/Controllers/BucketController.php @@ -13,15 +13,62 @@ class BucketController extends BaseController { use AuthorizesRequests, DispatchesJobs, ValidatesRequests; + private function formatBytes($size, $precision = 1) + { + if ($size === 0) { + return '0 bytes'; + } + + $base = log($size, 1024); + $suffixes = array('bytes', 'kB', 'MB', 'G', 'T'); + + return round(pow(1024, $base - floor($base)), $precision).' '.$suffixes[floor($base)]; + } + /** * * * @return * */ - public function single() + public function single($id) { - return view('bucket.single'); + $results = []; + + // create bucket + $bucket = Bucket::find($id); + + $files = scandir($bucket->path); + + foreach($files as $file) { + + if ($file === '.' || $file === '..') { + continue; + } + + $meta = stat($bucket->path.'/'.$file); + + $size = ($meta['size'] / 1000); + + if (($meta['size'] / 1000) < 1000) { + $size = ($meta['size'] / 1000); + } + + $results[] = [ + 'filename' => $file, + 'is_file' => is_file($bucket->path.'/'.$file), + 'meta' => [ + 'size' => $this->formatBytes($meta['size']), + 'updated_at' => \Carbon\Carbon::parse($meta['mtime'])->format('d.m.Y h:m:i') + ] + ]; + + } + + return view('bucket.single', [ + 'bucket' => $bucket, + 'files' => $results + ]); } /** diff --git a/public/js/bootstrap.js b/public/js/bootstrap.js index bf077a2..fb144e6 100644 --- a/public/js/bootstrap.js +++ b/public/js/bootstrap.js @@ -1,3 +1,3 @@ -!function(t){var e={};function n(r){if(e[r])return e[r].exports;var o=e[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)n.d(r,o,function(e){return t[e]}.bind(null,o));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="/",n(n.s=12)}([function(t,e,n){"use strict";var r=n(2),o=Object.prototype.toString;function i(t){return"[object Array]"===o.call(t)}function s(t){return void 0===t}function u(t){return null!==t&&"object"==typeof t}function a(t){if("[object Object]"!==o.call(t))return!1;var e=Object.getPrototypeOf(t);return null===e||e===Object.prototype}function c(t){return"[object Function]"===o.call(t)}function f(t,e){if(null!=t)if("object"!=typeof t&&(t=[t]),i(t))for(var n=0,r=t.length;n=200&&t<300}};a.headers={common:{Accept:"application/json, text/plain, */*"}},r.forEach(["delete","get","head"],(function(t){a.headers[t]={}})),r.forEach(["post","put","patch"],(function(t){a.headers[t]=r.merge(i)})),t.exports=a}).call(this,n(20))},function(t,e,n){"use strict";var r=n(0),o=n(22),i=n(24),s=n(3),u=n(25),a=n(28),c=n(29),f=n(7);t.exports=function(t){return new Promise((function(e,n){var l=t.data,p=t.headers;r.isFormData(l)&&delete p["Content-Type"];var d=new XMLHttpRequest;if(t.auth){var h=t.auth.username||"",m=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";p.Authorization="Basic "+btoa(h+":"+m)}var g=u(t.baseURL,t.url);if(d.open(t.method.toUpperCase(),s(g,t.params,t.paramsSerializer),!0),d.timeout=t.timeout,d.onreadystatechange=function(){if(d&&4===d.readyState&&(0!==d.status||d.responseURL&&0===d.responseURL.indexOf("file:"))){var r="getAllResponseHeaders"in d?a(d.getAllResponseHeaders()):null,i={data:t.responseType&&"text"!==t.responseType?d.response:d.responseText,status:d.status,statusText:d.statusText,headers:r,config:t,request:d};o(e,n,i),d=null}},d.onabort=function(){d&&(n(f("Request aborted",t,"ECONNABORTED",d)),d=null)},d.onerror=function(){n(f("Network Error",t,null,d)),d=null},d.ontimeout=function(){var e="timeout of "+t.timeout+"ms exceeded";t.timeoutErrorMessage&&(e=t.timeoutErrorMessage),n(f(e,t,"ECONNABORTED",d)),d=null},r.isStandardBrowserEnv()){var b=(t.withCredentials||c(g))&&t.xsrfCookieName?i.read(t.xsrfCookieName):void 0;b&&(p[t.xsrfHeaderName]=b)}if("setRequestHeader"in d&&r.forEach(p,(function(t,e){void 0===l&&"content-type"===e.toLowerCase()?delete p[e]:d.setRequestHeader(e,t)})),r.isUndefined(t.withCredentials)||(d.withCredentials=!!t.withCredentials),t.responseType)try{d.responseType=t.responseType}catch(e){if("json"!==t.responseType)throw e}"function"==typeof t.onDownloadProgress&&d.addEventListener("progress",t.onDownloadProgress),"function"==typeof t.onUploadProgress&&d.upload&&d.upload.addEventListener("progress",t.onUploadProgress),t.cancelToken&&t.cancelToken.promise.then((function(t){d&&(d.abort(),n(t),d=null)})),l||(l=null),d.send(l)}))}},function(t,e,n){"use strict";var r=n(23);t.exports=function(t,e,n,o,i){var s=new Error(t);return r(s,e,n,o,i)}},function(t,e,n){"use strict";var r=n(0);t.exports=function(t,e){e=e||{};var n={},o=["url","method","data"],i=["headers","auth","proxy","params"],s=["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","timeoutMessage","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","decompress","maxContentLength","maxBodyLength","maxRedirects","transport","httpAgent","httpsAgent","cancelToken","socketPath","responseEncoding"],u=["validateStatus"];function a(t,e){return r.isPlainObject(t)&&r.isPlainObject(e)?r.merge(t,e):r.isPlainObject(e)?r.merge({},e):r.isArray(e)?e.slice():e}function c(o){r.isUndefined(e[o])?r.isUndefined(t[o])||(n[o]=a(void 0,t[o])):n[o]=a(t[o],e[o])}r.forEach(o,(function(t){r.isUndefined(e[t])||(n[t]=a(void 0,e[t]))})),r.forEach(i,c),r.forEach(s,(function(o){r.isUndefined(e[o])?r.isUndefined(t[o])||(n[o]=a(void 0,t[o])):n[o]=a(void 0,e[o])})),r.forEach(u,(function(r){r in e?n[r]=a(t[r],e[r]):r in t&&(n[r]=a(void 0,t[r]))}));var f=o.concat(i).concat(s).concat(u),l=Object.keys(t).concat(Object.keys(e)).filter((function(t){return-1===f.indexOf(t)}));return r.forEach(l,c),n}},function(t,e,n){"use strict";function r(t){this.message=t}r.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},r.prototype.__CANCEL__=!0,t.exports=r},,,function(t,e,n){n(13),t.exports=n(39)},function(t,e,n){window.axios=n(14),window.riot=n(33)},function(t,e,n){t.exports=n(15)},function(t,e,n){"use strict";var r=n(0),o=n(2),i=n(16),s=n(8);function u(t){var e=new i(t),n=o(i.prototype.request,e);return r.extend(n,i.prototype,e),r.extend(n,e),n}var a=u(n(5));a.Axios=i,a.create=function(t){return u(s(a.defaults,t))},a.Cancel=n(9),a.CancelToken=n(30),a.isCancel=n(4),a.all=function(t){return Promise.all(t)},a.spread=n(31),a.isAxiosError=n(32),t.exports=a,t.exports.default=a},function(t,e,n){"use strict";var r=n(0),o=n(3),i=n(17),s=n(18),u=n(8);function a(t){this.defaults=t,this.interceptors={request:new i,response:new i}}a.prototype.request=function(t){"string"==typeof t?(t=arguments[1]||{}).url=arguments[0]:t=t||{},(t=u(this.defaults,t)).method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var e=[s,void 0],n=Promise.resolve(t);for(this.interceptors.request.forEach((function(t){e.unshift(t.fulfilled,t.rejected)})),this.interceptors.response.forEach((function(t){e.push(t.fulfilled,t.rejected)}));e.length;)n=n.then(e.shift(),e.shift());return n},a.prototype.getUri=function(t){return t=u(this.defaults,t),o(t.url,t.params,t.paramsSerializer).replace(/^\?/,"")},r.forEach(["delete","get","head","options"],(function(t){a.prototype[t]=function(e,n){return this.request(u(n||{},{method:t,url:e,data:(n||{}).data}))}})),r.forEach(["post","put","patch"],(function(t){a.prototype[t]=function(e,n,r){return this.request(u(r||{},{method:t,url:e,data:n}))}})),t.exports=a},function(t,e,n){"use strict";var r=n(0);function o(){this.handlers=[]}o.prototype.use=function(t,e){return this.handlers.push({fulfilled:t,rejected:e}),this.handlers.length-1},o.prototype.eject=function(t){this.handlers[t]&&(this.handlers[t]=null)},o.prototype.forEach=function(t){r.forEach(this.handlers,(function(e){null!==e&&t(e)}))},t.exports=o},function(t,e,n){"use strict";var r=n(0),o=n(19),i=n(4),s=n(5);function u(t){t.cancelToken&&t.cancelToken.throwIfRequested()}t.exports=function(t){return u(t),t.headers=t.headers||{},t.data=o(t.data,t.headers,t.transformRequest),t.headers=r.merge(t.headers.common||{},t.headers[t.method]||{},t.headers),r.forEach(["delete","get","head","post","put","patch","common"],(function(e){delete t.headers[e]})),(t.adapter||s.adapter)(t).then((function(e){return u(t),e.data=o(e.data,e.headers,t.transformResponse),e}),(function(e){return i(e)||(u(t),e&&e.response&&(e.response.data=o(e.response.data,e.response.headers,t.transformResponse))),Promise.reject(e)}))}},function(t,e,n){"use strict";var r=n(0);t.exports=function(t,e,n){return r.forEach(n,(function(n){t=n(t,e)})),t}},function(t,e){var n,r,o=t.exports={};function i(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function u(t){if(n===setTimeout)return setTimeout(t,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(t){n=i}try{r="function"==typeof clearTimeout?clearTimeout:s}catch(t){r=s}}();var a,c=[],f=!1,l=-1;function p(){f&&a&&(f=!1,a.length?c=a.concat(c):l=-1,c.length&&d())}function d(){if(!f){var t=u(p);f=!0;for(var e=c.length;e;){for(a=c,c=[];++l1)for(var n=1;n=0)return;s[e]="set-cookie"===e?(s[e]?s[e]:[]).concat([n]):s[e]?s[e]+", "+n:n}})),s):s}},function(t,e,n){"use strict";var r=n(0);t.exports=r.isStandardBrowserEnv()?function(){var t,e=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function o(t){var r=t;return e&&(n.setAttribute("href",r),r=n.href),n.setAttribute("href",r),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:"/"===n.pathname.charAt(0)?n.pathname:"/"+n.pathname}}return t=o(window.location.href),function(e){var n=r.isString(e)?o(e):e;return n.protocol===t.protocol&&n.host===t.host}}():function(){return!0}},function(t,e,n){"use strict";var r=n(9);function o(t){if("function"!=typeof t)throw new TypeError("executor must be a function.");var e;this.promise=new Promise((function(t){e=t}));var n=this;t((function(t){n.reason||(n.reason=new r(t),e(n.reason))}))}o.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},o.source=function(){var t;return{token:new o((function(e){t=e})),cancel:t}},t.exports=o},function(t,e,n){"use strict";t.exports=function(t){return function(e){return t.apply(null,e)}}},function(t,e,n){"use strict";t.exports=function(t){return"object"==typeof t&&!0===t.isAxiosError}},function(t,e,n){"use strict";function r(t){return t.replace(/-(\w)/g,(t,e)=>e.toUpperCase())}function o(t){Array.from(t).forEach(i)}n.r(e),n.d(e,"__",(function(){return It})),n.d(e,"component",(function(){return Lt})),n.d(e,"install",(function(){return Rt})),n.d(e,"mount",(function(){return Ut})),n.d(e,"pure",(function(){return Dt})),n.d(e,"register",(function(){return _t})),n.d(e,"uninstall",(function(){return Bt})),n.d(e,"unmount",(function(){return Pt})),n.d(e,"unregister",(function(){return Ct})),n.d(e,"version",(function(){return kt}));const i=t=>t&&t.parentNode&&t.parentNode.removeChild(t),s=(t,e)=>e&&e.parentNode&&e.parentNode.insertBefore(t,e);var u={EACH:0,IF:1,SIMPLE:2,TAG:3,SLOT:4};var a={ATTRIBUTE:0,EVENT:1,TEXT:2,VALUE:3};function c(t,e){return typeof t===e}function f(t){const e=t.ownerSVGElement;return!!e||null===e}function l(t){return!h(t.content)}function p(t){return c(t,"function")}function d(t){return!h(t)&&c(t,"object")}function h(t){return null==t}const m=Symbol("unmount"),g={nodes:[],mount(t,e){return this.update(t,e)},update(t,e){const{placeholder:n,nodes:r,childrenMap:o}=this,u=t===m?null:this.evaluate(t),a=u?Array.from(u):[],{newChildrenMap:c,batches:f,futureNodes:l}=(n.parentNode,function(t,e,n,r){const{condition:o,template:i,childrenMap:s,itemName:u,getKey:a,indexName:c,root:f,isTemplateTag:l}=r,p=new Map,d=[],h=[];return t.forEach((t,r)=>{const m=function(t,e){let{itemName:n,indexName:r,index:o,item:i}=e;t[n]=i,r&&(t[r]=o);return t}(Object.create(e),{itemName:u,indexName:c,index:r,item:t}),g=a?a(m):r,b=s.get(g);if(function(t,e){return!!t&&!1===Boolean(t(e))}(o,m))return;const v=b?b.template:i.clone(),y=b?v.el:f.cloneNode(),O=!b,E=l&&O?function(t){const e=t.dom.cloneNode(!0);return{avoidDOMInjection:!0,fragment:e,children:Array.from(e.childNodes)}}(v):{};if(O?d.push(()=>v.mount(y,m,n,E)):d.push(()=>v.update(m,n)),l){const t=E.children||v.children;h.push(...t)}else h.push(y);s.delete(g),p.set(g,{template:v,context:m,index:r})}),{newChildrenMap:p,batches:d,futureNodes:h}}(a,t,e,this));return((t,e,n,r,o)=>{const u=n.length;let a=e.length,c=u,f=0,l=0,p=null;for(;ft-l){const o=r(e[f],0);for(;l{if(r<0){const n=t.pop();if(n){const{template:t,context:r}=n;t.unmount(r,e,null)}}return n}}(Array.from(o.values()),e),n),f.forEach(t=>t()),this.childrenMap=c,this.nodes=l,this},unmount(t,e){return this.update(m,e),this}};const b={mount(t,e){return this.update(t,e)},update(t,e){const n=!!this.evaluate(t),r=!this.value&&n,o=this.value&&!n,i=()=>{const n=this.node.cloneNode();s(n,this.placeholder),this.template=this.template.clone(),this.template.mount(n,t,e)};switch(!0){case r:i();break;case o:this.unmount(t);break;default:n&&this.template.update(t,e)}return this.value=n,this},unmount(t,e){return this.template.unmount(t,e,!0),this}};function v(t){throw new Error(t)}function y(t){return t.reduce((t,e)=>{const{value:n,type:o}=e;switch(!0){case!e.name&&0===o:return Object.assign({},t,n);case 3===o:t.value=e.value;break;default:t[r(e.name)]=e.value}return t},{})}const O="undefined"==typeof Element?{}:Element.prototype,E=function(t){const e=new Map,n=n=>(e.has(n)||e.set(n,t.call(this,n)))&&e.get(n);return n.cache=e,n}(t=>O.hasOwnProperty(t));function T(t,e,n,r){let{name:o}=e;if(!o)return r&&function(t,e,n){const r=e?Object.keys(e):[];Object.keys(n).filter(t=>!r.includes(t)).forEach(e=>t.removeAttribute(e))}(t,n,r),void(n&&function(t,e){Object.entries(e).forEach(e=>{let[n,r]=e;return T(t,{name:n},r)})}(t,n));!E(o)&&(function(t){return c(t,"boolean")}(n)||d(n)||p(n))&&(t[o]=n),t[function(t){return h(t)||!1===t||""===t||d(t)||p(t)?"removeAttribute":"setAttribute"}(n)](o,function(t,e){return!0===e?t:e}(o,n))}const w=/^on/,x={handleEvent(t){this[t.type](t)}},N=new WeakMap;function j(t){return h(t)?"":t}const S=(t,e)=>{const n=t.childNodes[e];if(n.nodeType===Node.COMMENT_NODE){const e=document.createTextNode("");return t.replaceChild(e,n),e}return n};var A={0:T,1:function(t,e,n){let{name:r}=e;const o=r.replace(w,""),i=N.get(t)||(t=>{const e=Object.create(x);return N.set(t,e),e})(t),[s,u]=(t=>Array.isArray(t)?t:[t,!1])(n),a=i[o],c=s&&!a;a&&!s&&t.removeEventListener(o,i),c&&t.addEventListener(o,i,u),i[o]=s},2:function(t,e,n){t.data=j(n)},3:function(t,e,n){t.value=j(n)}};const M={mount(t){return this.value=this.evaluate(t),_(this,this.value),this},update(t){const e=this.evaluate(t);return this.value!==e&&(_(this,e),this.value=e),this},unmount(){return 1===this.type&&_(this,null),this}};function _(t,e){return A[t.type](t.node,t,e,t.value)}function C(t,e){return Object.assign({},M,e,{node:2===e.type?S(t,e.childNodeIndex):t})}const U=new Map,P=Symbol("riot-component"),R=new Set,B="mount",L="update",D="unmount",k=Symbol.for("pure"),I=Symbol("parent"),Y=Symbol("attributes"),q=Symbol("template");var K=Object.freeze({__proto__:null,COMPONENTS_IMPLEMENTATION_MAP:U,DOM_COMPONENT_INSTANCE_PROPERTY:P,PLUGINS_SET:R,IS_DIRECTIVE:"is",VALUE_ATTRIBUTE:"value",MOUNT_METHOD_KEY:B,UPDATE_METHOD_KEY:L,UNMOUNT_METHOD_KEY:D,SHOULD_UPDATE_KEY:"shouldUpdate",ON_BEFORE_MOUNT_KEY:"onBeforeMount",ON_MOUNTED_KEY:"onMounted",ON_BEFORE_UPDATE_KEY:"onBeforeUpdate",ON_UPDATED_KEY:"onUpdated",ON_BEFORE_UNMOUNT_KEY:"onBeforeUnmount",ON_UNMOUNTED_KEY:"onUnmounted",PROPS_KEY:"props",STATE_KEY:"state",SLOTS_KEY:"slots",ROOT_KEY:"root",IS_PURE_SYMBOL:k,PARENT_KEY_SYMBOL:I,ATTRIBUTES_KEY_SYMBOL:Y,TEMPLATE_KEY_SYMBOL:q});const z=(t,e)=>t[I]||e,F={attributes:[],getTemplateScope(t,e){return function(t,e,n){if(!t||!t.length)return n;const r=t.map(t=>Object.assign({},t,{value:t.evaluate(e)}));return Object.assign(Object.create(n||null),y(r))}(this.attributes,t,e)},mount(t,e){const n=!!t.slots&&t.slots.find(t=>{let{id:e}=t;return e===this.name}),{parentNode:r}=this.node,o=z(t,e);return this.template=n&&Q(n.html,n.bindings).createDOM(r),this.template&&(this.template.mount(this.node,this.getTemplateScope(t,o),o),this.template.children=Array.from(this.node.childNodes),function t(e){const n=e&&e.firstChild;if(!n)return;s(n,e),t(e)}(this.node)),i(this.node),this},update(t,e){if(this.template){const n=z(t,e);this.template.update(this.getTemplateScope(t,n),n)}return this},unmount(t,e,n){return this.template&&this.template.unmount(this.getTemplateScope(t,e),null,n),this}};function H(t){return t.reduce((t,e)=>{let{bindings:n}=e;return t.concat(n)},[])}const $={mount(t){return this.update(t)},update(t,e){const n=this.evaluate(t);return n===this.name?this.tag.update(t):(this.unmount(t,e,!0),this.name=n,this.tag=function(t,e,n){return void 0===e&&(e=[]),void 0===n&&(n=[]),t?t({slots:e,attributes:n}):Q(function(t){return t.reduce((t,e)=>t+e.html,"")}(e),[...H(e),{expressions:n.map(t=>Object.assign({type:0},t))}])}(this.getComponent(n),this.slots,this.attributes),this.tag.mount(this.node,t)),this},unmount(t,e,n){return this.tag&&this.tag.unmount(n),this}};var V={1:function(t,e){let{evaluate:n,template:r}=e;const o=document.createTextNode("");return s(o,t),i(t),Object.assign({},b,{node:t,evaluate:n,placeholder:o,template:r.createDOM(t)})},2:function(t,e){let{expressions:n}=e;return Object.assign({},(r=n.map(e=>C(t,e)),["mount","update","unmount"].reduce((t,e)=>Object.assign({},t,{[e]:t=>r.map(n=>n[e](t))&&o}),{})));var r,o},0:function(t,e){let{evaluate:n,condition:r,itemName:o,indexName:u,getKey:a,template:c}=e;const f=document.createTextNode(""),p=t.cloneNode();return s(f,t),i(t),Object.assign({},g,{childrenMap:new Map,node:t,root:p,condition:r,evaluate:n,isTemplateTag:l(p),template:c.createDOM(t),getKey:a,indexName:u,itemName:o,placeholder:f})},3:function(t,e){let{evaluate:n,getComponent:r,slots:o,attributes:i}=e;return Object.assign({},$,{node:t,evaluate:n,slots:o,attributes:i,getComponent:r})},4:function(t,e){let{name:n,attributes:r}=e;return Object.assign({},F,{attributes:r,node:t,name:n})}};function X(t,e){return t.map(t=>2===t.type?Object.assign({},t,{childNodeIndex:t.childNodeIndex+e}):t)}function G(t,e,n){const{selector:r,type:o,redundantAttribute:i,expressions:s}=e,u=r?t.querySelector(r):t;i&&u.removeAttribute(i);const a=s||[];return(V[o]||V[2])(u,Object.assign({},e,{expressions:n&&!r?X(a,n):a}))}function J(t,e){return f(t)?function(t,e){return e.ownerDocument.importNode((new window.DOMParser).parseFromString(`${t}`,"application/xml").documentElement,!0)}(e,t):function(t,e){const n=l(e)?e:document.createElement("template");return n.innerHTML=t,n.content}(e,t)}function W(t,e){switch(!0){case f(t):!function t(e,n){e.firstChild&&(n.appendChild(e.firstChild),t(e,n))}(e,t);break;case l(t):t.parentNode.replaceChild(e,t);break;default:t.appendChild(e)}}const Z=Object.freeze({createDOM(t){return this.dom=this.dom||function(t,e){return e&&("string"==typeof e?J(t,e):e)}(t,this.html),this},mount(t,e,n,r){if(void 0===r&&(r={}),!t)throw new Error("Please provide DOM node to mount properly your template");this.el&&this.unmount(e);const{fragment:o,children:i,avoidDOMInjection:s}=r,{parentNode:u}=i?i[0]:t,a=l(t),c=a?Math.max(Array.from(u.childNodes).indexOf(t),0):null;return this.isTemplateTag=a,this.createDOM(t),this.dom&&(this.fragment=o||this.dom.cloneNode(!0)),this.el=this.isTemplateTag?u:t,this.children=this.isTemplateTag?i||Array.from(this.fragment.childNodes):null,!s&&this.fragment&&W(t,this.fragment),this.bindings=this.bindingsData.map(t=>G(this.el,t,c)),this.bindings.forEach(t=>t.mount(e,n)),this},update(t,e){return this.bindings.forEach(n=>n.update(t,e)),this},unmount(t,e,n){if(this.el){switch(this.bindings.forEach(r=>r.unmount(t,e,n)),!0){case this.children&&null!==n:o(this.children);break;case!0===n:i(this.el);break;case null!==n:o(this.el.childNodes)}this.el=null}return this},clone(){return Object.assign({},this,{el:null})}});function Q(t,e){return void 0===e&&(e=[]),Object.assign({},Z,{html:t,bindingsData:e})}var tt=Object.freeze({__proto__:null,template:Q,createBinding:G,createExpression:C,bindingTypes:u,expressionTypes:a});function et(){return this}function nt(t){return p(t)?t.prototype&&t.prototype.constructor?new t:t():t}function rt(t,e,n,r){return void 0===r&&(r={}),Object.defineProperty(t,e,Object.assign({value:n,enumerable:!1,writable:!1,configurable:!0},r)),t}function ot(t,e,n){return Object.entries(e).forEach(e=>{let[r,o]=e;rt(t,r,o,n)}),t}function it(t,e){return Object.entries(e).forEach(e=>{let[n,r]=e;t[n]||(t[n]=r)}),t}function st(t){return Array.isArray(t)?t:/^\[object (HTMLCollection|NodeList|Object)\]$/.test(Object.prototype.toString.call(t))&&"number"==typeof t.length?Array.from(t):[t]}function ut(t,e){return st("string"==typeof t?(e||document).querySelectorAll(t):t)}const at=t=>1===t.length?t[0]:t;function ct(t,e,n){const r="object"==typeof e?e:{[e]:n},o=Object.keys(r);return st(t).forEach(t=>{o.forEach(e=>t.setAttribute(e,r[e]))}),t}function ft(t,e){return function(t,e,n){const r="string"==typeof e?[e]:e;return at(st(t).map(t=>at(r.map(e=>t[n](e)))))}(t,e,"getAttribute")}const lt=new Map,pt=()=>dt||(ct(dt=ut("style[riot]")[0]||document.createElement("style"),"type","text/css"),dt.parentNode||document.head.appendChild(dt),dt);var dt,ht={CSS_BY_NAME:lt,add(t,e){return lt.has(t)||(lt.set(t,e),this.inject()),this},inject(){return pt().innerHTML=[...lt.values()].join("\n"),this},remove(t){return lt.has(t)&&(lt.delete(t),this.inject()),this}};function mt(t){return ft(t,"is")||t.tagName.toLowerCase()}const gt=Object.freeze({$(t){return ut(t,this.root)[0]},$$(t){return ut(t,this.root)}}),bt=Object.freeze({[B]:et,[L]:et,[D]:et}),vt=Object.freeze({shouldUpdate:et,onBeforeMount:et,onMounted:et,onBeforeUpdate:et,onUpdated:et,onBeforeUnmount:et,onUnmounted:et}),yt=Object.assign({},bt,{clone:et,createDOM:et});function Ot(t,e){return void 0===e&&(e={}),Object.assign({},function(t){return Array.from(t.attributes).reduce((t,e)=>(t[r(e.name)]=e.value,t),{})}(t),nt(e))}const Et=(t,e)=>t[P]=e;function Tt(t){return[B,L,D].reduce((e,n)=>(e[n]=t(n),e),{})}function wt(t){let{css:e,template:n,exports:r,name:o}=t;const i=n?function(t,e){return t(Q,a,u,t=>e[t]||U.get(t))}(n,r?function(t){void 0===t&&(t={});return Object.entries(nt(t)).reduce((t,e)=>{let[n,r]=e; +!function(t){var e={};function n(r){if(e[r])return e[r].exports;var o=e[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)n.d(r,o,function(e){return t[e]}.bind(null,o));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="/",n(n.s=31)}([function(t,e,n){"use strict";var r=n(1),o=Object.prototype.toString;function i(t){return"[object Array]"===o.call(t)}function s(t){return void 0===t}function u(t){return null!==t&&"object"==typeof t}function a(t){if("[object Object]"!==o.call(t))return!1;var e=Object.getPrototypeOf(t);return null===e||e===Object.prototype}function c(t){return"[object Function]"===o.call(t)}function f(t,e){if(null!=t)if("object"!=typeof t&&(t=[t]),i(t))for(var n=0,r=t.length;n=200&&t<300}};a.headers={common:{Accept:"application/json, text/plain, */*"}},r.forEach(["delete","get","head"],(function(t){a.headers[t]={}})),r.forEach(["post","put","patch"],(function(t){a.headers[t]=r.merge(i)})),t.exports=a}).call(this,n(15))},function(t,e,n){"use strict";var r=n(0),o=n(17),i=n(19),s=n(2),u=n(20),a=n(23),c=n(24),f=n(6);t.exports=function(t){return new Promise((function(e,n){var l=t.data,p=t.headers;r.isFormData(l)&&delete p["Content-Type"];var d=new XMLHttpRequest;if(t.auth){var h=t.auth.username||"",m=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";p.Authorization="Basic "+btoa(h+":"+m)}var g=u(t.baseURL,t.url);if(d.open(t.method.toUpperCase(),s(g,t.params,t.paramsSerializer),!0),d.timeout=t.timeout,d.onreadystatechange=function(){if(d&&4===d.readyState&&(0!==d.status||d.responseURL&&0===d.responseURL.indexOf("file:"))){var r="getAllResponseHeaders"in d?a(d.getAllResponseHeaders()):null,i={data:t.responseType&&"text"!==t.responseType?d.response:d.responseText,status:d.status,statusText:d.statusText,headers:r,config:t,request:d};o(e,n,i),d=null}},d.onabort=function(){d&&(n(f("Request aborted",t,"ECONNABORTED",d)),d=null)},d.onerror=function(){n(f("Network Error",t,null,d)),d=null},d.ontimeout=function(){var e="timeout of "+t.timeout+"ms exceeded";t.timeoutErrorMessage&&(e=t.timeoutErrorMessage),n(f(e,t,"ECONNABORTED",d)),d=null},r.isStandardBrowserEnv()){var b=(t.withCredentials||c(g))&&t.xsrfCookieName?i.read(t.xsrfCookieName):void 0;b&&(p[t.xsrfHeaderName]=b)}if("setRequestHeader"in d&&r.forEach(p,(function(t,e){void 0===l&&"content-type"===e.toLowerCase()?delete p[e]:d.setRequestHeader(e,t)})),r.isUndefined(t.withCredentials)||(d.withCredentials=!!t.withCredentials),t.responseType)try{d.responseType=t.responseType}catch(e){if("json"!==t.responseType)throw e}"function"==typeof t.onDownloadProgress&&d.addEventListener("progress",t.onDownloadProgress),"function"==typeof t.onUploadProgress&&d.upload&&d.upload.addEventListener("progress",t.onUploadProgress),t.cancelToken&&t.cancelToken.promise.then((function(t){d&&(d.abort(),n(t),d=null)})),l||(l=null),d.send(l)}))}},function(t,e,n){"use strict";var r=n(18);t.exports=function(t,e,n,o,i){var s=new Error(t);return r(s,e,n,o,i)}},function(t,e,n){"use strict";var r=n(0);t.exports=function(t,e){e=e||{};var n={},o=["url","method","data"],i=["headers","auth","proxy","params"],s=["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","timeoutMessage","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","decompress","maxContentLength","maxBodyLength","maxRedirects","transport","httpAgent","httpsAgent","cancelToken","socketPath","responseEncoding"],u=["validateStatus"];function a(t,e){return r.isPlainObject(t)&&r.isPlainObject(e)?r.merge(t,e):r.isPlainObject(e)?r.merge({},e):r.isArray(e)?e.slice():e}function c(o){r.isUndefined(e[o])?r.isUndefined(t[o])||(n[o]=a(void 0,t[o])):n[o]=a(t[o],e[o])}r.forEach(o,(function(t){r.isUndefined(e[t])||(n[t]=a(void 0,e[t]))})),r.forEach(i,c),r.forEach(s,(function(o){r.isUndefined(e[o])?r.isUndefined(t[o])||(n[o]=a(void 0,t[o])):n[o]=a(void 0,e[o])})),r.forEach(u,(function(r){r in e?n[r]=a(t[r],e[r]):r in t&&(n[r]=a(void 0,t[r]))}));var f=o.concat(i).concat(s).concat(u),l=Object.keys(t).concat(Object.keys(e)).filter((function(t){return-1===f.indexOf(t)}));return r.forEach(l,c),n}},function(t,e,n){"use strict";function r(t){this.message=t}r.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},r.prototype.__CANCEL__=!0,t.exports=r},function(t,e,n){t.exports=n(10)},function(t,e,n){"use strict";var r=n(0),o=n(1),i=n(11),s=n(7);function u(t){var e=new i(t),n=o(i.prototype.request,e);return r.extend(n,i.prototype,e),r.extend(n,e),n}var a=u(n(4));a.Axios=i,a.create=function(t){return u(s(a.defaults,t))},a.Cancel=n(8),a.CancelToken=n(25),a.isCancel=n(3),a.all=function(t){return Promise.all(t)},a.spread=n(26),a.isAxiosError=n(27),t.exports=a,t.exports.default=a},function(t,e,n){"use strict";var r=n(0),o=n(2),i=n(12),s=n(13),u=n(7);function a(t){this.defaults=t,this.interceptors={request:new i,response:new i}}a.prototype.request=function(t){"string"==typeof t?(t=arguments[1]||{}).url=arguments[0]:t=t||{},(t=u(this.defaults,t)).method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var e=[s,void 0],n=Promise.resolve(t);for(this.interceptors.request.forEach((function(t){e.unshift(t.fulfilled,t.rejected)})),this.interceptors.response.forEach((function(t){e.push(t.fulfilled,t.rejected)}));e.length;)n=n.then(e.shift(),e.shift());return n},a.prototype.getUri=function(t){return t=u(this.defaults,t),o(t.url,t.params,t.paramsSerializer).replace(/^\?/,"")},r.forEach(["delete","get","head","options"],(function(t){a.prototype[t]=function(e,n){return this.request(u(n||{},{method:t,url:e,data:(n||{}).data}))}})),r.forEach(["post","put","patch"],(function(t){a.prototype[t]=function(e,n,r){return this.request(u(r||{},{method:t,url:e,data:n}))}})),t.exports=a},function(t,e,n){"use strict";var r=n(0);function o(){this.handlers=[]}o.prototype.use=function(t,e){return this.handlers.push({fulfilled:t,rejected:e}),this.handlers.length-1},o.prototype.eject=function(t){this.handlers[t]&&(this.handlers[t]=null)},o.prototype.forEach=function(t){r.forEach(this.handlers,(function(e){null!==e&&t(e)}))},t.exports=o},function(t,e,n){"use strict";var r=n(0),o=n(14),i=n(3),s=n(4);function u(t){t.cancelToken&&t.cancelToken.throwIfRequested()}t.exports=function(t){return u(t),t.headers=t.headers||{},t.data=o(t.data,t.headers,t.transformRequest),t.headers=r.merge(t.headers.common||{},t.headers[t.method]||{},t.headers),r.forEach(["delete","get","head","post","put","patch","common"],(function(e){delete t.headers[e]})),(t.adapter||s.adapter)(t).then((function(e){return u(t),e.data=o(e.data,e.headers,t.transformResponse),e}),(function(e){return i(e)||(u(t),e&&e.response&&(e.response.data=o(e.response.data,e.response.headers,t.transformResponse))),Promise.reject(e)}))}},function(t,e,n){"use strict";var r=n(0);t.exports=function(t,e,n){return r.forEach(n,(function(n){t=n(t,e)})),t}},function(t,e){var n,r,o=t.exports={};function i(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function u(t){if(n===setTimeout)return setTimeout(t,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(t){n=i}try{r="function"==typeof clearTimeout?clearTimeout:s}catch(t){r=s}}();var a,c=[],f=!1,l=-1;function p(){f&&a&&(f=!1,a.length?c=a.concat(c):l=-1,c.length&&d())}function d(){if(!f){var t=u(p);f=!0;for(var e=c.length;e;){for(a=c,c=[];++l1)for(var n=1;n=0)return;s[e]="set-cookie"===e?(s[e]?s[e]:[]).concat([n]):s[e]?s[e]+", "+n:n}})),s):s}},function(t,e,n){"use strict";var r=n(0);t.exports=r.isStandardBrowserEnv()?function(){var t,e=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function o(t){var r=t;return e&&(n.setAttribute("href",r),r=n.href),n.setAttribute("href",r),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:"/"===n.pathname.charAt(0)?n.pathname:"/"+n.pathname}}return t=o(window.location.href),function(e){var n=r.isString(e)?o(e):e;return n.protocol===t.protocol&&n.host===t.host}}():function(){return!0}},function(t,e,n){"use strict";var r=n(8);function o(t){if("function"!=typeof t)throw new TypeError("executor must be a function.");var e;this.promise=new Promise((function(t){e=t}));var n=this;t((function(t){n.reason||(n.reason=new r(t),e(n.reason))}))}o.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},o.source=function(){var t;return{token:new o((function(e){t=e})),cancel:t}},t.exports=o},function(t,e,n){"use strict";t.exports=function(t){return function(e){return t.apply(null,e)}}},function(t,e,n){"use strict";t.exports=function(t){return"object"==typeof t&&!0===t.isAxiosError}},,,,function(t,e,n){n(32),t.exports=n(41)},function(t,e,n){window.axios=n(9),window.riot=n(33)},function(t,e,n){"use strict";function r(t){return t.replace(/-(\w)/g,(t,e)=>e.toUpperCase())}function o(t){Array.from(t).forEach(i)}n.r(e),n.d(e,"__",(function(){return It})),n.d(e,"component",(function(){return Lt})),n.d(e,"install",(function(){return Rt})),n.d(e,"mount",(function(){return Ut})),n.d(e,"pure",(function(){return Dt})),n.d(e,"register",(function(){return _t})),n.d(e,"uninstall",(function(){return Bt})),n.d(e,"unmount",(function(){return Pt})),n.d(e,"unregister",(function(){return Ct})),n.d(e,"version",(function(){return kt}));const i=t=>t&&t.parentNode&&t.parentNode.removeChild(t),s=(t,e)=>e&&e.parentNode&&e.parentNode.insertBefore(t,e);var u={EACH:0,IF:1,SIMPLE:2,TAG:3,SLOT:4};var a={ATTRIBUTE:0,EVENT:1,TEXT:2,VALUE:3};function c(t,e){return typeof t===e}function f(t){const e=t.ownerSVGElement;return!!e||null===e}function l(t){return!h(t.content)}function p(t){return c(t,"function")}function d(t){return!h(t)&&c(t,"object")}function h(t){return null==t}const m=Symbol("unmount"),g={nodes:[],mount(t,e){return this.update(t,e)},update(t,e){const{placeholder:n,nodes:r,childrenMap:o}=this,u=t===m?null:this.evaluate(t),a=u?Array.from(u):[],{newChildrenMap:c,batches:f,futureNodes:l}=(n.parentNode,function(t,e,n,r){const{condition:o,template:i,childrenMap:s,itemName:u,getKey:a,indexName:c,root:f,isTemplateTag:l}=r,p=new Map,d=[],h=[];return t.forEach((t,r)=>{const m=function(t,e){let{itemName:n,indexName:r,index:o,item:i}=e;t[n]=i,r&&(t[r]=o);return t}(Object.create(e),{itemName:u,indexName:c,index:r,item:t}),g=a?a(m):r,b=s.get(g);if(function(t,e){return!!t&&!1===Boolean(t(e))}(o,m))return;const v=b?b.template:i.clone(),y=b?v.el:f.cloneNode(),O=!b,E=l&&O?function(t){const e=t.dom.cloneNode(!0);return{avoidDOMInjection:!0,fragment:e,children:Array.from(e.childNodes)}}(v):{};if(O?d.push(()=>v.mount(y,m,n,E)):d.push(()=>v.update(m,n)),l){const t=E.children||v.children;h.push(...t)}else h.push(y);s.delete(g),p.set(g,{template:v,context:m,index:r})}),{newChildrenMap:p,batches:d,futureNodes:h}}(a,t,e,this));return((t,e,n,r,o)=>{const u=n.length;let a=e.length,c=u,f=0,l=0,p=null;for(;ft-l){const o=r(e[f],0);for(;l{if(r<0){const n=t.pop();if(n){const{template:t,context:r}=n;t.unmount(r,e,null)}}return n}}(Array.from(o.values()),e),n),f.forEach(t=>t()),this.childrenMap=c,this.nodes=l,this},unmount(t,e){return this.update(m,e),this}};const b={mount(t,e){return this.update(t,e)},update(t,e){const n=!!this.evaluate(t),r=!this.value&&n,o=this.value&&!n,i=()=>{const n=this.node.cloneNode();s(n,this.placeholder),this.template=this.template.clone(),this.template.mount(n,t,e)};switch(!0){case r:i();break;case o:this.unmount(t);break;default:n&&this.template.update(t,e)}return this.value=n,this},unmount(t,e){return this.template.unmount(t,e,!0),this}};function v(t){throw new Error(t)}function y(t){return t.reduce((t,e)=>{const{value:n,type:o}=e;switch(!0){case!e.name&&0===o:return Object.assign({},t,n);case 3===o:t.value=e.value;break;default:t[r(e.name)]=e.value}return t},{})}const O="undefined"==typeof Element?{}:Element.prototype,E=function(t){const e=new Map,n=n=>(e.has(n)||e.set(n,t.call(this,n)))&&e.get(n);return n.cache=e,n}(t=>O.hasOwnProperty(t));function T(t,e,n,r){let{name:o}=e;if(!o)return r&&function(t,e,n){const r=e?Object.keys(e):[];Object.keys(n).filter(t=>!r.includes(t)).forEach(e=>t.removeAttribute(e))}(t,n,r),void(n&&function(t,e){Object.entries(e).forEach(e=>{let[n,r]=e;return T(t,{name:n},r)})}(t,n));!E(o)&&(function(t){return c(t,"boolean")}(n)||d(n)||p(n))&&(t[o]=n),t[function(t){return h(t)||!1===t||""===t||d(t)||p(t)?"removeAttribute":"setAttribute"}(n)](o,function(t,e){return!0===e?t:e}(o,n))}const w=/^on/,x={handleEvent(t){this[t.type](t)}},N=new WeakMap;function j(t){return h(t)?"":t}const S=(t,e)=>{const n=t.childNodes[e];if(n.nodeType===Node.COMMENT_NODE){const e=document.createTextNode("");return t.replaceChild(e,n),e}return n};var A={0:T,1:function(t,e,n){let{name:r}=e;const o=r.replace(w,""),i=N.get(t)||(t=>{const e=Object.create(x);return N.set(t,e),e})(t),[s,u]=(t=>Array.isArray(t)?t:[t,!1])(n),a=i[o],c=s&&!a;a&&!s&&t.removeEventListener(o,i),c&&t.addEventListener(o,i,u),i[o]=s},2:function(t,e,n){t.data=j(n)},3:function(t,e,n){t.value=j(n)}};const M={mount(t){return this.value=this.evaluate(t),_(this,this.value),this},update(t){const e=this.evaluate(t);return this.value!==e&&(_(this,e),this.value=e),this},unmount(){return 1===this.type&&_(this,null),this}};function _(t,e){return A[t.type](t.node,t,e,t.value)}function C(t,e){return Object.assign({},M,e,{node:2===e.type?S(t,e.childNodeIndex):t})}const U=new Map,P=Symbol("riot-component"),R=new Set,B="mount",L="update",D="unmount",k=Symbol.for("pure"),I=Symbol("parent"),Y=Symbol("attributes"),q=Symbol("template");var K=Object.freeze({__proto__:null,COMPONENTS_IMPLEMENTATION_MAP:U,DOM_COMPONENT_INSTANCE_PROPERTY:P,PLUGINS_SET:R,IS_DIRECTIVE:"is",VALUE_ATTRIBUTE:"value",MOUNT_METHOD_KEY:B,UPDATE_METHOD_KEY:L,UNMOUNT_METHOD_KEY:D,SHOULD_UPDATE_KEY:"shouldUpdate",ON_BEFORE_MOUNT_KEY:"onBeforeMount",ON_MOUNTED_KEY:"onMounted",ON_BEFORE_UPDATE_KEY:"onBeforeUpdate",ON_UPDATED_KEY:"onUpdated",ON_BEFORE_UNMOUNT_KEY:"onBeforeUnmount",ON_UNMOUNTED_KEY:"onUnmounted",PROPS_KEY:"props",STATE_KEY:"state",SLOTS_KEY:"slots",ROOT_KEY:"root",IS_PURE_SYMBOL:k,PARENT_KEY_SYMBOL:I,ATTRIBUTES_KEY_SYMBOL:Y,TEMPLATE_KEY_SYMBOL:q});const z=(t,e)=>t[I]||e,F={attributes:[],getTemplateScope(t,e){return function(t,e,n){if(!t||!t.length)return n;const r=t.map(t=>Object.assign({},t,{value:t.evaluate(e)}));return Object.assign(Object.create(n||null),y(r))}(this.attributes,t,e)},mount(t,e){const n=!!t.slots&&t.slots.find(t=>{let{id:e}=t;return e===this.name}),{parentNode:r}=this.node,o=z(t,e);return this.template=n&&Q(n.html,n.bindings).createDOM(r),this.template&&(this.template.mount(this.node,this.getTemplateScope(t,o),o),this.template.children=Array.from(this.node.childNodes),function t(e){const n=e&&e.firstChild;if(!n)return;s(n,e),t(e)}(this.node)),i(this.node),this},update(t,e){if(this.template){const n=z(t,e);this.template.update(this.getTemplateScope(t,n),n)}return this},unmount(t,e,n){return this.template&&this.template.unmount(this.getTemplateScope(t,e),null,n),this}};function H(t){return t.reduce((t,e)=>{let{bindings:n}=e;return t.concat(n)},[])}const $={mount(t){return this.update(t)},update(t,e){const n=this.evaluate(t);return n===this.name?this.tag.update(t):(this.unmount(t,e,!0),this.name=n,this.tag=function(t,e,n){return void 0===e&&(e=[]),void 0===n&&(n=[]),t?t({slots:e,attributes:n}):Q(function(t){return t.reduce((t,e)=>t+e.html,"")}(e),[...H(e),{expressions:n.map(t=>Object.assign({type:0},t))}])}(this.getComponent(n),this.slots,this.attributes),this.tag.mount(this.node,t)),this},unmount(t,e,n){return this.tag&&this.tag.unmount(n),this}};var V={1:function(t,e){let{evaluate:n,template:r}=e;const o=document.createTextNode("");return s(o,t),i(t),Object.assign({},b,{node:t,evaluate:n,placeholder:o,template:r.createDOM(t)})},2:function(t,e){let{expressions:n}=e;return Object.assign({},(r=n.map(e=>C(t,e)),["mount","update","unmount"].reduce((t,e)=>Object.assign({},t,{[e]:t=>r.map(n=>n[e](t))&&o}),{})));var r,o},0:function(t,e){let{evaluate:n,condition:r,itemName:o,indexName:u,getKey:a,template:c}=e;const f=document.createTextNode(""),p=t.cloneNode();return s(f,t),i(t),Object.assign({},g,{childrenMap:new Map,node:t,root:p,condition:r,evaluate:n,isTemplateTag:l(p),template:c.createDOM(t),getKey:a,indexName:u,itemName:o,placeholder:f})},3:function(t,e){let{evaluate:n,getComponent:r,slots:o,attributes:i}=e;return Object.assign({},$,{node:t,evaluate:n,slots:o,attributes:i,getComponent:r})},4:function(t,e){let{name:n,attributes:r}=e;return Object.assign({},F,{attributes:r,node:t,name:n})}};function X(t,e){return t.map(t=>2===t.type?Object.assign({},t,{childNodeIndex:t.childNodeIndex+e}):t)}function G(t,e,n){const{selector:r,type:o,redundantAttribute:i,expressions:s}=e,u=r?t.querySelector(r):t;i&&u.removeAttribute(i);const a=s||[];return(V[o]||V[2])(u,Object.assign({},e,{expressions:n&&!r?X(a,n):a}))}function J(t,e){return f(t)?function(t,e){return e.ownerDocument.importNode((new window.DOMParser).parseFromString(`${t}`,"application/xml").documentElement,!0)}(e,t):function(t,e){const n=l(e)?e:document.createElement("template");return n.innerHTML=t,n.content}(e,t)}function W(t,e){switch(!0){case f(t):!function t(e,n){e.firstChild&&(n.appendChild(e.firstChild),t(e,n))}(e,t);break;case l(t):t.parentNode.replaceChild(e,t);break;default:t.appendChild(e)}}const Z=Object.freeze({createDOM(t){return this.dom=this.dom||function(t,e){return e&&("string"==typeof e?J(t,e):e)}(t,this.html),this},mount(t,e,n,r){if(void 0===r&&(r={}),!t)throw new Error("Please provide DOM node to mount properly your template");this.el&&this.unmount(e);const{fragment:o,children:i,avoidDOMInjection:s}=r,{parentNode:u}=i?i[0]:t,a=l(t),c=a?Math.max(Array.from(u.childNodes).indexOf(t),0):null;return this.isTemplateTag=a,this.createDOM(t),this.dom&&(this.fragment=o||this.dom.cloneNode(!0)),this.el=this.isTemplateTag?u:t,this.children=this.isTemplateTag?i||Array.from(this.fragment.childNodes):null,!s&&this.fragment&&W(t,this.fragment),this.bindings=this.bindingsData.map(t=>G(this.el,t,c)),this.bindings.forEach(t=>t.mount(e,n)),this},update(t,e){return this.bindings.forEach(n=>n.update(t,e)),this},unmount(t,e,n){if(this.el){switch(this.bindings.forEach(r=>r.unmount(t,e,n)),!0){case this.children&&null!==n:o(this.children);break;case!0===n:i(this.el);break;case null!==n:o(this.el.childNodes)}this.el=null}return this},clone(){return Object.assign({},this,{el:null})}});function Q(t,e){return void 0===e&&(e=[]),Object.assign({},Z,{html:t,bindingsData:e})}var tt=Object.freeze({__proto__:null,template:Q,createBinding:G,createExpression:C,bindingTypes:u,expressionTypes:a});function et(){return this}function nt(t){return p(t)?t.prototype&&t.prototype.constructor?new t:t():t}function rt(t,e,n,r){return void 0===r&&(r={}),Object.defineProperty(t,e,Object.assign({value:n,enumerable:!1,writable:!1,configurable:!0},r)),t}function ot(t,e,n){return Object.entries(e).forEach(e=>{let[r,o]=e;rt(t,r,o,n)}),t}function it(t,e){return Object.entries(e).forEach(e=>{let[n,r]=e;t[n]||(t[n]=r)}),t}function st(t){return Array.isArray(t)?t:/^\[object (HTMLCollection|NodeList|Object)\]$/.test(Object.prototype.toString.call(t))&&"number"==typeof t.length?Array.from(t):[t]}function ut(t,e){return st("string"==typeof t?(e||document).querySelectorAll(t):t)}const at=t=>1===t.length?t[0]:t;function ct(t,e,n){const r="object"==typeof e?e:{[e]:n},o=Object.keys(r);return st(t).forEach(t=>{o.forEach(e=>t.setAttribute(e,r[e]))}),t}function ft(t,e){return function(t,e,n){const r="string"==typeof e?[e]:e;return at(st(t).map(t=>at(r.map(e=>t[n](e)))))}(t,e,"getAttribute")}const lt=new Map,pt=()=>dt||(ct(dt=ut("style[riot]")[0]||document.createElement("style"),"type","text/css"),dt.parentNode||document.head.appendChild(dt),dt);var dt,ht={CSS_BY_NAME:lt,add(t,e){return lt.has(t)||(lt.set(t,e),this.inject()),this},inject(){return pt().innerHTML=[...lt.values()].join("\n"),this},remove(t){return lt.has(t)&&(lt.delete(t),this.inject()),this}};function mt(t){return ft(t,"is")||t.tagName.toLowerCase()}const gt=Object.freeze({$(t){return ut(t,this.root)[0]},$$(t){return ut(t,this.root)}}),bt=Object.freeze({[B]:et,[L]:et,[D]:et}),vt=Object.freeze({shouldUpdate:et,onBeforeMount:et,onMounted:et,onBeforeUpdate:et,onUpdated:et,onBeforeUnmount:et,onUnmounted:et}),yt=Object.assign({},bt,{clone:et,createDOM:et});function Ot(t,e){return void 0===e&&(e={}),Object.assign({},function(t){return Array.from(t.attributes).reduce((t,e)=>(t[r(e.name)]=e.value,t),{})}(t),nt(e))}const Et=(t,e)=>t[P]=e;function Tt(t){return[B,L,D].reduce((e,n)=>(e[n]=t(n),e),{})}function wt(t){let{css:e,template:n,exports:r,name:o}=t;const i=n?function(t,e){return t(Q,a,u,t=>e[t]||U.get(t))}(n,r?function(t){void 0===t&&(t={});return Object.entries(nt(t)).reduce((t,e)=>{let[n,r]=e; /* Riot v5.1.1, @license MIT */ -var o;return t[(o=n,o.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase())]=wt(r),t},{})}(r.components):{}):yt;return t=>{let{slots:s,attributes:u,props:a}=t;if(r&&r[k])return function(t,e){let{slots:n,attributes:r,props:o,css:i,template:s}=e;s&&v("Pure components can not have html"),i&&v("Pure components do not have css");const u=it(t({slots:n,attributes:r,props:o}),bt);return Tt(t=>function(){for(var e=arguments.length,n=new Array(e),r=0;rf.mount(t,n,e),update:(t,e)=>f.update(e,t),unmount:t=>f.unmount(t)}}}function xt(t){let{css:e,template:n,componentAPI:r,name:o}=t;return e&&o&&ht.add(o,e),function t(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;oe(t)||t,t)}(ot(Object.create(t),{mount(e,i,s){return void 0===i&&(i={}),this[Y]=function(t,e){void 0===e&&(e=[]);const n=e.map(e=>C(t,e)),r={};return Object.assign(r,Object.assign({expressions:n},Tt(t=>e=>(n.forEach(n=>n[t](e)),r))))}(e,r).mount(s),rt(this,"props",Object.freeze(Object.assign({},Ot(e,o),y(this[Y].expressions)))),this.state=Nt(this.state,i),this[q]=this.template.createDOM(e).clone(),Et(e,this),t.name&&function(t,e){mt(t)!==e&&ct(t,"is",e)}(e,t.name),rt(this,"root",e),rt(this,"slots",n),this.onBeforeMount(this.props,this.state),this[I]=s,this[q].mount(e,this,s),this.onMounted(this.props,this.state),this},update(t,e){void 0===t&&(t={}),e&&(this[I]=e,this[Y].update(e));const n=y(this[Y].expressions);if(!1!==this.shouldUpdate(n,this.props))return rt(this,"props",Object.freeze(Object.assign({},this.props,n))),this.state=Nt(this.state,t),this.onBeforeUpdate(this.props,this.state),this[q].update(this,this[I]),this.onUpdated(this.props,this.state),this},unmount(t){return this.onBeforeUnmount(this.props,this.state),this[Y].unmount(),this[q].unmount(this,this[I],null===t?null:!t),this.onUnmounted(this.props,this.state),this}})),Object.keys(t).filter(e=>p(t[e])).forEach(t=>{i[t]=i[t].bind(i)}),i;var i}const{DOM_COMPONENT_INSTANCE_PROPERTY:St,COMPONENTS_IMPLEMENTATION_MAP:At,PLUGINS_SET:Mt}=K;function _t(t,e){let{css:n,template:r,exports:o}=e;return At.has(t)&&v(`The component "${t}" was already registered`),At.set(t,wt({name:t,css:n,template:r,exports:o})),At}function Ct(t){return At.has(t)||v(`The component "${t}" was never registered`),At.delete(t),ht.remove(t),At}function Ut(t,e,n){return ut(t).map(t=>function(t,e,n){const r=n||mt(t);return U.has(r)||v(`The component named "${r}" was never registered`),U.get(r)({props:e}).mount(t)}(t,e,n))}function Pt(t,e){return ut(t).map(t=>(t[St]&&t[St].unmount(e),t))}function Rt(t){return p(t)||v("Plugins must be of type function"),Mt.has(t)&&v("This plugin was already installed"),Mt.add(t),Mt}function Bt(t){return Mt.has(t)||v("This plugin was never installed"),Mt.delete(t),Mt}function Lt(t){return function(e,n,r){let{slots:o,attributes:i,parentScope:s}=void 0===r?{}:r;return function(){for(var t=arguments.length,e=new Array(t),n=0;nfunction(){return t(e(...arguments))})}(t=>t.mount(e,s),t=>t({props:n,slots:o,attributes:i}),wt)(t)}}function Dt(t){return p(t)||v('riot.pure accepts only arguments of type "function"'),t[k]=!0,t}const kt="v5.1.1",It={cssManager:ht,DOMBindings:tt,createComponent:wt,defineComponent:xt,globals:K}},,,,,,function(t,e){}]); \ No newline at end of file +var o;return t[(o=n,o.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase())]=wt(r),t},{})}(r.components):{}):yt;return t=>{let{slots:s,attributes:u,props:a}=t;if(r&&r[k])return function(t,e){let{slots:n,attributes:r,props:o,css:i,template:s}=e;s&&v("Pure components can not have html"),i&&v("Pure components do not have css");const u=it(t({slots:n,attributes:r,props:o}),bt);return Tt(t=>function(){for(var e=arguments.length,n=new Array(e),r=0;rf.mount(t,n,e),update:(t,e)=>f.update(e,t),unmount:t=>f.unmount(t)}}}function xt(t){let{css:e,template:n,componentAPI:r,name:o}=t;return e&&o&&ht.add(o,e),function t(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;oe(t)||t,t)}(ot(Object.create(t),{mount(e,i,s){return void 0===i&&(i={}),this[Y]=function(t,e){void 0===e&&(e=[]);const n=e.map(e=>C(t,e)),r={};return Object.assign(r,Object.assign({expressions:n},Tt(t=>e=>(n.forEach(n=>n[t](e)),r))))}(e,r).mount(s),rt(this,"props",Object.freeze(Object.assign({},Ot(e,o),y(this[Y].expressions)))),this.state=Nt(this.state,i),this[q]=this.template.createDOM(e).clone(),Et(e,this),t.name&&function(t,e){mt(t)!==e&&ct(t,"is",e)}(e,t.name),rt(this,"root",e),rt(this,"slots",n),this.onBeforeMount(this.props,this.state),this[I]=s,this[q].mount(e,this,s),this.onMounted(this.props,this.state),this},update(t,e){void 0===t&&(t={}),e&&(this[I]=e,this[Y].update(e));const n=y(this[Y].expressions);if(!1!==this.shouldUpdate(n,this.props))return rt(this,"props",Object.freeze(Object.assign({},this.props,n))),this.state=Nt(this.state,t),this.onBeforeUpdate(this.props,this.state),this[q].update(this,this[I]),this.onUpdated(this.props,this.state),this},unmount(t){return this.onBeforeUnmount(this.props,this.state),this[Y].unmount(),this[q].unmount(this,this[I],null===t?null:!t),this.onUnmounted(this.props,this.state),this}})),Object.keys(t).filter(e=>p(t[e])).forEach(t=>{i[t]=i[t].bind(i)}),i;var i}const{DOM_COMPONENT_INSTANCE_PROPERTY:St,COMPONENTS_IMPLEMENTATION_MAP:At,PLUGINS_SET:Mt}=K;function _t(t,e){let{css:n,template:r,exports:o}=e;return At.has(t)&&v(`The component "${t}" was already registered`),At.set(t,wt({name:t,css:n,template:r,exports:o})),At}function Ct(t){return At.has(t)||v(`The component "${t}" was never registered`),At.delete(t),ht.remove(t),At}function Ut(t,e,n){return ut(t).map(t=>function(t,e,n){const r=n||mt(t);return U.has(r)||v(`The component named "${r}" was never registered`),U.get(r)({props:e}).mount(t)}(t,e,n))}function Pt(t,e){return ut(t).map(t=>(t[St]&&t[St].unmount(e),t))}function Rt(t){return p(t)||v("Plugins must be of type function"),Mt.has(t)&&v("This plugin was already installed"),Mt.add(t),Mt}function Bt(t){return Mt.has(t)||v("This plugin was never installed"),Mt.delete(t),Mt}function Lt(t){return function(e,n,r){let{slots:o,attributes:i,parentScope:s}=void 0===r?{}:r;return function(){for(var t=arguments.length,e=new Array(t),n=0;nfunction(){return t(e(...arguments))})}(t=>t.mount(e,s),t=>t({props:n,slots:o,attributes:i}),wt)(t)}}function Dt(t){return p(t)||v('riot.pure accepts only arguments of type "function"'),t[k]=!0,t}const kt="v5.1.1",It={cssManager:ht,DOMBindings:tt,createComponent:wt,defineComponent:xt,globals:K}},,,,,,,,function(t,e){}]); \ No newline at end of file diff --git a/public/js/bucket-single.js b/public/js/bucket-single.js new file mode 100644 index 0000000..4c297e8 --- /dev/null +++ b/public/js/bucket-single.js @@ -0,0 +1 @@ +!function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="/",n(n.s=37)}([function(e,t,n){"use strict";var r=n(1),o=Object.prototype.toString;function i(e){return"[object Array]"===o.call(e)}function s(e){return void 0===e}function a(e){return null!==e&&"object"==typeof e}function u(e){if("[object Object]"!==o.call(e))return!1;var t=Object.getPrototypeOf(e);return null===t||t===Object.prototype}function c(e){return"[object Function]"===o.call(e)}function f(e,t){if(null!=e)if("object"!=typeof e&&(e=[e]),i(e))for(var n=0,r=e.length;n=200&&e<300}};u.headers={common:{Accept:"application/json, text/plain, */*"}},r.forEach(["delete","get","head"],(function(e){u.headers[e]={}})),r.forEach(["post","put","patch"],(function(e){u.headers[e]=r.merge(i)})),e.exports=u}).call(this,n(15))},function(e,t,n){"use strict";var r=n(0),o=n(17),i=n(19),s=n(2),a=n(20),u=n(23),c=n(24),f=n(6);e.exports=function(e){return new Promise((function(t,n){var l=e.data,p=e.headers;r.isFormData(l)&&delete p["Content-Type"];var d=new XMLHttpRequest;if(e.auth){var h=e.auth.username||"",m=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";p.Authorization="Basic "+btoa(h+":"+m)}var v=a(e.baseURL,e.url);if(d.open(e.method.toUpperCase(),s(v,e.params,e.paramsSerializer),!0),d.timeout=e.timeout,d.onreadystatechange=function(){if(d&&4===d.readyState&&(0!==d.status||d.responseURL&&0===d.responseURL.indexOf("file:"))){var r="getAllResponseHeaders"in d?u(d.getAllResponseHeaders()):null,i={data:e.responseType&&"text"!==e.responseType?d.response:d.responseText,status:d.status,statusText:d.statusText,headers:r,config:e,request:d};o(t,n,i),d=null}},d.onabort=function(){d&&(n(f("Request aborted",e,"ECONNABORTED",d)),d=null)},d.onerror=function(){n(f("Network Error",e,null,d)),d=null},d.ontimeout=function(){var t="timeout of "+e.timeout+"ms exceeded";e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),n(f(t,e,"ECONNABORTED",d)),d=null},r.isStandardBrowserEnv()){var y=(e.withCredentials||c(v))&&e.xsrfCookieName?i.read(e.xsrfCookieName):void 0;y&&(p[e.xsrfHeaderName]=y)}if("setRequestHeader"in d&&r.forEach(p,(function(e,t){void 0===l&&"content-type"===t.toLowerCase()?delete p[t]:d.setRequestHeader(t,e)})),r.isUndefined(e.withCredentials)||(d.withCredentials=!!e.withCredentials),e.responseType)try{d.responseType=e.responseType}catch(t){if("json"!==e.responseType)throw t}"function"==typeof e.onDownloadProgress&&d.addEventListener("progress",e.onDownloadProgress),"function"==typeof e.onUploadProgress&&d.upload&&d.upload.addEventListener("progress",e.onUploadProgress),e.cancelToken&&e.cancelToken.promise.then((function(e){d&&(d.abort(),n(e),d=null)})),l||(l=null),d.send(l)}))}},function(e,t,n){"use strict";var r=n(18);e.exports=function(e,t,n,o,i){var s=new Error(e);return r(s,t,n,o,i)}},function(e,t,n){"use strict";var r=n(0);e.exports=function(e,t){t=t||{};var n={},o=["url","method","data"],i=["headers","auth","proxy","params"],s=["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","timeoutMessage","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","decompress","maxContentLength","maxBodyLength","maxRedirects","transport","httpAgent","httpsAgent","cancelToken","socketPath","responseEncoding"],a=["validateStatus"];function u(e,t){return r.isPlainObject(e)&&r.isPlainObject(t)?r.merge(e,t):r.isPlainObject(t)?r.merge({},t):r.isArray(t)?t.slice():t}function c(o){r.isUndefined(t[o])?r.isUndefined(e[o])||(n[o]=u(void 0,e[o])):n[o]=u(e[o],t[o])}r.forEach(o,(function(e){r.isUndefined(t[e])||(n[e]=u(void 0,t[e]))})),r.forEach(i,c),r.forEach(s,(function(o){r.isUndefined(t[o])?r.isUndefined(e[o])||(n[o]=u(void 0,e[o])):n[o]=u(void 0,t[o])})),r.forEach(a,(function(r){r in t?n[r]=u(e[r],t[r]):r in e&&(n[r]=u(void 0,e[r]))}));var f=o.concat(i).concat(s).concat(a),l=Object.keys(e).concat(Object.keys(t)).filter((function(e){return-1===f.indexOf(e)}));return r.forEach(l,c),n}},function(e,t,n){"use strict";function r(e){this.message=e}r.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},r.prototype.__CANCEL__=!0,e.exports=r},function(e,t,n){e.exports=n(10)},function(e,t,n){"use strict";var r=n(0),o=n(1),i=n(11),s=n(7);function a(e){var t=new i(e),n=o(i.prototype.request,t);return r.extend(n,i.prototype,t),r.extend(n,t),n}var u=a(n(4));u.Axios=i,u.create=function(e){return a(s(u.defaults,e))},u.Cancel=n(8),u.CancelToken=n(25),u.isCancel=n(3),u.all=function(e){return Promise.all(e)},u.spread=n(26),u.isAxiosError=n(27),e.exports=u,e.exports.default=u},function(e,t,n){"use strict";var r=n(0),o=n(2),i=n(12),s=n(13),a=n(7);function u(e){this.defaults=e,this.interceptors={request:new i,response:new i}}u.prototype.request=function(e){"string"==typeof e?(e=arguments[1]||{}).url=arguments[0]:e=e||{},(e=a(this.defaults,e)).method?e.method=e.method.toLowerCase():this.defaults.method?e.method=this.defaults.method.toLowerCase():e.method="get";var t=[s,void 0],n=Promise.resolve(e);for(this.interceptors.request.forEach((function(e){t.unshift(e.fulfilled,e.rejected)})),this.interceptors.response.forEach((function(e){t.push(e.fulfilled,e.rejected)}));t.length;)n=n.then(t.shift(),t.shift());return n},u.prototype.getUri=function(e){return e=a(this.defaults,e),o(e.url,e.params,e.paramsSerializer).replace(/^\?/,"")},r.forEach(["delete","get","head","options"],(function(e){u.prototype[e]=function(t,n){return this.request(a(n||{},{method:e,url:t,data:(n||{}).data}))}})),r.forEach(["post","put","patch"],(function(e){u.prototype[e]=function(t,n,r){return this.request(a(r||{},{method:e,url:t,data:n}))}})),e.exports=u},function(e,t,n){"use strict";var r=n(0);function o(){this.handlers=[]}o.prototype.use=function(e,t){return this.handlers.push({fulfilled:e,rejected:t}),this.handlers.length-1},o.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},o.prototype.forEach=function(e){r.forEach(this.handlers,(function(t){null!==t&&e(t)}))},e.exports=o},function(e,t,n){"use strict";var r=n(0),o=n(14),i=n(3),s=n(4);function a(e){e.cancelToken&&e.cancelToken.throwIfRequested()}e.exports=function(e){return a(e),e.headers=e.headers||{},e.data=o(e.data,e.headers,e.transformRequest),e.headers=r.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),r.forEach(["delete","get","head","post","put","patch","common"],(function(t){delete e.headers[t]})),(e.adapter||s.adapter)(e).then((function(t){return a(e),t.data=o(t.data,t.headers,e.transformResponse),t}),(function(t){return i(t)||(a(e),t&&t.response&&(t.response.data=o(t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)}))}},function(e,t,n){"use strict";var r=n(0);e.exports=function(e,t,n){return r.forEach(n,(function(n){e=n(e,t)})),e}},function(e,t){var n,r,o=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function a(e){if(n===setTimeout)return setTimeout(e,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(e){n=i}try{r="function"==typeof clearTimeout?clearTimeout:s}catch(e){r=s}}();var u,c=[],f=!1,l=-1;function p(){f&&u&&(f=!1,u.length?c=u.concat(c):l=-1,c.length&&d())}function d(){if(!f){var e=a(p);f=!0;for(var t=c.length;t;){for(u=c,c=[];++l1)for(var n=1;n=0)return;s[t]="set-cookie"===t?(s[t]?s[t]:[]).concat([n]):s[t]?s[t]+", "+n:n}})),s):s}},function(e,t,n){"use strict";var r=n(0);e.exports=r.isStandardBrowserEnv()?function(){var e,t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function o(e){var r=e;return t&&(n.setAttribute("href",r),r=n.href),n.setAttribute("href",r),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:"/"===n.pathname.charAt(0)?n.pathname:"/"+n.pathname}}return e=o(window.location.href),function(t){var n=r.isString(t)?o(t):t;return n.protocol===e.protocol&&n.host===e.host}}():function(){return!0}},function(e,t,n){"use strict";var r=n(8);function o(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise((function(e){t=e}));var n=this;e((function(e){n.reason||(n.reason=new r(e),t(n.reason))}))}o.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},o.source=function(){var e;return{token:new o((function(t){e=t})),cancel:e}},e.exports=o},function(e,t,n){"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}},function(e,t,n){"use strict";e.exports=function(e){return"object"==typeof e&&!0===e.isAxiosError}},,,,,,,,,,function(e,t,n){e.exports=n(40)},,,function(e,t,n){"use strict";n.r(t);n(9);riot.register("urban-filemanager-file",{css:null,exports:{},template:function(e,t,n,r){return e('
',[{redundantAttribute:"expr21",selector:"[expr21]",expressions:[{type:t.EVENT,name:"onchange",evaluate:function(e){return t=>{e.props.handleMarked(t,e)}}}]},{redundantAttribute:"expr22",selector:"[expr22]",expressions:[{type:t.TEXT,childNodeIndex:0,evaluate:function(e){return[e.props.file.filename].join("")}},{type:t.EVENT,name:"onclick",evaluate:function(e){return t=>{e.props.handleClick(t,e)}}}]},{redundantAttribute:"expr23",selector:"[expr23]",expressions:[{type:t.TEXT,childNodeIndex:0,evaluate:function(e){return[e.props.file.meta.size,"\n ",e.props.file.meta.updated_at].join("")}},{type:t.EVENT,name:"onclick",evaluate:function(e){return t=>{e.props.handleClick(t,e)}}}]}])},name:"urban-filemanager-file"});var r={css:null,exports:{handleClick(){console.log("ddd")},handleMarked(){console.log("ddd")}},template:function(e,t,n,r){return e('
',[{type:n.EACH,getKey:null,condition:null,template:e('',[{type:n.IF,evaluate:function(e){return e.file.is_file},redundantAttribute:"expr18",selector:"[expr18]",template:e(null,[{type:n.TAG,getComponent:r,evaluate:function(e){return"urban-filemanager-file"},slots:[],attributes:[{type:t.ATTRIBUTE,name:"file",evaluate:function(e){return e.file}},{type:t.ATTRIBUTE,name:"handleClick",evaluate:function(e){return e.handleClick}},{type:t.ATTRIBUTE,name:"handleMarked",evaluate:function(e){return e.handleMarked}}]}])}]),redundantAttribute:"expr17",selector:"[expr17]",itemName:"file",indexName:null,evaluate:function(e){return e.props.files}}])},name:"urban-filemanager"};riot.register("urban-filemanager",r)}]); \ No newline at end of file diff --git a/public/js/bucket.js b/public/js/bucket.js index 84babb4..a0188ae 100644 --- a/public/js/bucket.js +++ b/public/js/bucket.js @@ -1,4 +1,4 @@ -!function(e){var t={};function r(n){if(t[n])return t[n].exports;var i=t[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)r.d(n,i,function(t){return e[t]}.bind(null,i));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="/",r(r.s=35)}({1:function(e,t,r){(function(e){ +!function(e){var t={};function r(n){if(t[n])return t[n].exports;var i=t[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)r.d(n,i,function(t){return e[t]}.bind(null,i));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="/",r(r.s=35)}({28:function(e,t,r){(function(e){ /*! * validate.js 0.13.1 * @@ -7,4 +7,4 @@ * For all details and documentation: * http://validatejs.org/ */ -(function(e,t,n){"use strict";var i=function(e,t,r){r=a.extend({},a.options,r);var n=a.runValidations(e,t,r);if(n.some((function(e){return a.isPromise(e.error)})))throw new Error("Use validate.async if you want support for promises");return i.processValidationResults(n,r)},a=i;a.extend=function(e){return[].slice.call(arguments,1).forEach((function(t){for(var r in t)e[r]=t[r]})),e},a.extend(i,{version:{major:0,minor:13,patch:1,metadata:null,toString:function(){var e=a.format("%{major}.%{minor}.%{patch}",a.version);return a.isEmpty(a.version.metadata)||(e+="+"+a.version.metadata),e}},Promise:"undefined"!=typeof Promise?Promise:null,EMPTY_STRING_REGEXP:/^\s*$/,runValidations:function(e,t,r){var n,i,s,o,u,l,c,f=[];for(n in(a.isDomElement(e)||a.isJqueryElement(e))&&(e=a.collectFormValues(e)),t)for(i in s=a.getDeepObjectValue(e,n),o=a.result(t[n],s,e,n,r,t)){if(!(u=a.validators[i]))throw c=a.format("Unknown validator %{name}",{name:i}),new Error(c);l=o[i],(l=a.result(l,s,e,n,r,t))&&f.push({attribute:n,value:s,validator:i,globalOptions:r,attributes:e,options:l,error:u.call(u,s,l,n,e,r)})}return f},processValidationResults:function(e,t){e=a.pruneEmptyErrors(e,t),e=a.expandMultipleErrors(e,t),e=a.convertErrorMessages(e,t);var r=t.format||"grouped";if("function"!=typeof a.formatters[r])throw new Error(a.format("Unknown format %{format}",t));return e=a.formatters[r](e),a.isEmpty(e)?void 0:e},async:function(e,t,r){var n=(r=a.extend({},a.async.options,r)).wrapErrors||function(e){return e};!1!==r.cleanAttributes&&(e=a.cleanAttributes(e,t));var i=a.runValidations(e,t,r);return new a.Promise((function(s,o){a.waitForResults(i).then((function(){var u=a.processValidationResults(i,r);u?o(new n(u,r,e,t)):s(e)}),(function(e){o(e)}))}))},single:function(e,t,r){return r=a.extend({},a.single.options,r,{format:"flat",fullMessages:!1}),a({single:e},{single:t},r)},waitForResults:function(e){return e.reduce((function(e,t){return a.isPromise(t.error)?e.then((function(){return t.error.then((function(e){t.error=e||null}))})):e}),new a.Promise((function(e){e()})))},result:function(e){var t=[].slice.call(arguments,1);return"function"==typeof e&&(e=e.apply(null,t)),e},isNumber:function(e){return"number"==typeof e&&!isNaN(e)},isFunction:function(e){return"function"==typeof e},isInteger:function(e){return a.isNumber(e)&&e%1==0},isBoolean:function(e){return"boolean"==typeof e},isObject:function(e){return e===Object(e)},isDate:function(e){return e instanceof Date},isDefined:function(e){return null!=e},isPromise:function(e){return!!e&&a.isFunction(e.then)},isJqueryElement:function(e){return e&&a.isString(e.jquery)},isDomElement:function(e){return!!e&&(!(!e.querySelectorAll||!e.querySelector)&&(!(!a.isObject(document)||e!==document)||("object"==typeof HTMLElement?e instanceof HTMLElement:e&&"object"==typeof e&&null!==e&&1===e.nodeType&&"string"==typeof e.nodeName)))},isEmpty:function(e){var t;if(!a.isDefined(e))return!0;if(a.isFunction(e))return!1;if(a.isString(e))return a.EMPTY_STRING_REGEXP.test(e);if(a.isArray(e))return 0===e.length;if(a.isDate(e))return!1;if(a.isObject(e)){for(t in e)return!1;return!0}return!1},format:a.extend((function(e,t){return a.isString(e)?e.replace(a.format.FORMAT_REGEXP,(function(e,r,n){return"%"===r?"%{"+n+"}":String(t[n])})):e}),{FORMAT_REGEXP:/(%?)%\{([^\}]+)\}/g}),prettify:function(e){return a.isNumber(e)?100*e%1==0?""+e:parseFloat(Math.round(100*e)/100).toFixed(2):a.isArray(e)?e.map((function(e){return a.prettify(e)})).join(", "):a.isObject(e)?a.isDefined(e.toString)?e.toString():JSON.stringify(e):(e=""+e).replace(/([^\s])\.([^\s])/g,"$1 $2").replace(/\\+/g,"").replace(/[_-]/g," ").replace(/([a-z])([A-Z])/g,(function(e,t,r){return t+" "+r.toLowerCase()})).toLowerCase()},stringifyValue:function(e,t){return(t&&t.prettify||a.prettify)(e)},isString:function(e){return"string"==typeof e},isArray:function(e){return"[object Array]"==={}.toString.call(e)},isHash:function(e){return a.isObject(e)&&!a.isArray(e)&&!a.isFunction(e)},contains:function(e,t){return!!a.isDefined(e)&&(a.isArray(e)?-1!==e.indexOf(t):t in e)},unique:function(e){return a.isArray(e)?e.filter((function(e,t,r){return r.indexOf(e)==t})):e},forEachKeyInKeypath:function(e,t,r){if(a.isString(t)){var n,i="",s=!1;for(n=0;ns&&(n=t.tooLong||this.tooLong||"is too long (maximum is %{count} characters)",u.push(a.format(n,{count:s}))),u.length>0?t.message||u:void 0):t.message||this.notValid||"has an incorrect length"}},numericality:function(e,t,r,n,i){if(a.isDefined(e)){var s,o,u=[],l={greaterThan:function(e,t){return e>t},greaterThanOrEqualTo:function(e,t){return e>=t},equalTo:function(e,t){return e===t},lessThan:function(e,t){return es&&(r=t.tooLate||t.message||this.tooLate||"must be no later than %{date}",r=a.format(r,{date:this.format(s,t),value:this.format(e,t)}),n.push(r)),n.length?a.unique(n):void 0)}}),{parse:null,format:null}),date:function(e,t){return t=a.extend({},t,{dateOnly:!0}),a.validators.datetime.call(a.validators.datetime,e,t)},format:function(e,t){(a.isString(t)||t instanceof RegExp)&&(t={pattern:t});var r,n=(t=a.extend({},this.options,t)).message||this.message||"is invalid",i=t.pattern;if(a.isDefined(e))return a.isString(e)?(a.isString(i)&&(i=new RegExp(t.pattern,t.flags)),(r=i.exec(e))&&r[0].length==e.length?void 0:n):n},inclusion:function(e,t){if(a.isDefined(e)&&(a.isArray(t)&&(t={within:t}),t=a.extend({},this.options,t),!a.contains(t.within,e))){var r=t.message||this.message||"^%{value} is not included in the list";return a.format(r,{value:e})}},exclusion:function(e,t){if(a.isDefined(e)&&(a.isArray(t)&&(t={within:t}),t=a.extend({},this.options,t),a.contains(t.within,e))){var r=t.message||this.message||"^%{value} is restricted";return a.isString(t.within[e])&&(e=t.within[e]),a.format(r,{value:e})}},email:a.extend((function(e,t){var r=(t=a.extend({},this.options,t)).message||this.message||"is not a valid email";if(a.isDefined(e))return a.isString(e)&&this.PATTERN.exec(e)?void 0:r}),{PATTERN:/^(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])*")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)\])$/i}),equality:function(e,t,r,n,i){if(a.isDefined(e)){a.isString(t)&&(t={attribute:t});var s=(t=a.extend({},this.options,t)).message||this.message||"is not equal to %{attribute}";if(a.isEmpty(t.attribute)||!a.isString(t.attribute))throw new Error("The attribute must be a non empty string");var o=a.getDeepObjectValue(n,t.attribute),u=t.comparator||function(e,t){return e===t},l=t.prettify||i&&i.prettify||a.prettify;return u(e,o,t,r,n)?void 0:a.format(s,{attribute:l(t.attribute)})}},url:function(e,t){if(a.isDefined(e)){var r=(t=a.extend({},this.options,t)).message||this.message||"is not a valid url",n=t.schemes||this.schemes||["http","https"],i=t.allowLocal||this.allowLocal||!1,s=t.allowDataUrl||this.allowDataUrl||!1;if(!a.isString(e))return r;var o="^(?:(?:"+n.join("|")+")://)(?:\\S+(?::\\S*)?@)?(?:",u="(?:\\.(?:[a-z\\u00a1-\\uffff]{2,}))";if(i?u+="?":o+="(?!(?:10|127)(?:\\.\\d{1,3}){3})(?!(?:169\\.254|192\\.168)(?:\\.\\d{1,3}){2})(?!172\\.(?:1[6-9]|2\\d|3[0-1])(?:\\.\\d{1,3}){2})",o+="(?:[1-9]\\d?|1\\d\\d|2[01]\\d|22[0-3])(?:\\.(?:1?\\d{1,2}|2[0-4]\\d|25[0-5])){2}(?:\\.(?:[1-9]\\d?|1\\d\\d|2[0-4]\\d|25[0-4]))|(?:(?:[a-z\\u00a1-\\uffff0-9]-*)*[a-z\\u00a1-\\uffff0-9]+)(?:\\.(?:[a-z\\u00a1-\\uffff0-9]-*)*[a-z\\u00a1-\\uffff0-9]+)*"+u+")(?::\\d{2,5})?(?:[/?#]\\S*)?$",s){o="(?:"+o+")|(?:^data:(?:\\w+\\/[-+.\\w]+(?:;[\\w=]+)*)?(?:;base64)?,[A-Za-z0-9-_.!~\\*'();\\/?:@&=+$,%]*$)"}return new RegExp(o,"i").exec(e)?void 0:r}},type:a.extend((function(e,t,r,n,i){if(a.isString(t)&&(t={type:t}),a.isDefined(e)){var s,o=a.extend({},this.options,t),u=o.type;if(!a.isDefined(u))throw new Error("No type was specified");if(s=a.isFunction(u)?u:this.types[u],!a.isFunction(s))throw new Error("validate.validators.type.types."+u+" must be a function.");if(!s(e,o,r,n,i)){var l=t.message||this.messages[u]||this.message||o.message||(a.isFunction(u)?"must be of the correct type":"must be of type %{type}");return a.isFunction(l)&&(l=l(e,t,r,n,i)),a.format(l,{attribute:a.prettify(r),type:u})}}}),{types:{object:function(e){return a.isObject(e)&&!a.isArray(e)},array:a.isArray,integer:a.isInteger,number:a.isNumber,string:a.isString,date:a.isDate,boolean:a.isBoolean},messages:{}})},i.formatters={detailed:function(e){return e},flat:a.flattenErrorsToArray,grouped:function(e){var t;for(t in e=a.groupErrorsByAttribute(e))e[t]=a.flattenErrorsToArray(e[t]);return e},constraint:function(e){var t;for(t in e=a.groupErrorsByAttribute(e))e[t]=e[t].map((function(e){return e.validator})).sort();return e}},i.exposeModule(i,this,e,t,r(10))}).call(this,t,e,r(10))}).call(this,r(36)(e))},10:function(e,t){e.exports=function(){throw new Error("define cannot be used indirect")}},11:function(e,t){var r=/^(?:submit|button|image|reset|file)$/i,n=/^(?:input|select|textarea|keygen)/i,i=/(\[[^\[\]]*\])/g;function a(e,t,r){if(t.match(i)){!function e(t,r,n){if(0===r.length)return t=n;var i=r.shift(),a=i.match(/^\[(.+?)\]$/);if("[]"===i)return t=t||[],Array.isArray(t)?t.push(e(null,r,n)):(t._values=t._values||[],t._values.push(e(null,r,n))),t;if(a){var s=a[1],o=+s;isNaN(o)?(t=t||{})[s]=e(t[s],r,n):(t=t||[])[o]=e(t[o],r,n)}else t[i]=e(t[i],r,n);return t}(e,function(e){var t=[],r=new RegExp(i),n=/^([^\[\]]*)/.exec(e);for(n[1]&&t.push(n[1]);null!==(n=r.exec(e));)t.push(n[1]);return t}(t),r)}else{var n=e[t];n?(Array.isArray(n)||(e[t]=[n]),e[t].push(r)):e[t]=r}return e}function s(e,t,r){return r=r.replace(/(\r)?\n/g,"\r\n"),r=(r=encodeURIComponent(r)).replace(/%20/g,"+"),e+(e?"&":"")+encodeURIComponent(t)+"="+r}e.exports=function(e,t){"object"!=typeof t?t={hash:!!t}:void 0===t.hash&&(t.hash=!0);for(var i=t.hash?{}:"",o=t.serializer||(t.hash?a:s),u=e&&e.elements?e.elements:[],l=Object.create(null),c=0;c0?t.errors=e.errors:t.errors=[]}},template:function(e,t,r,n){return e('
',[{type:r.IF,evaluate:function(e){return e.state.errors.length>0},redundantAttribute:"expr17",selector:"[expr17]",template:e('
',[{type:r.EACH,getKey:null,condition:null,template:e(" ",[{expressions:[{type:t.TEXT,childNodeIndex:0,evaluate:function(e){return e.error}}]}]),redundantAttribute:"expr18",selector:"[expr18]",itemName:"error",indexName:null,evaluate:function(e){return e.state.errors}}])}])},name:"field-error"};riot.register("field-error",u);var l={css:null,exports:{onBeforeMount(e,t){t.validator=new o({name:{presence:!0,length:{maximum:255}},description:{length:{maximum:255}}},this);const r=document.querySelector("meta[name='csrf-token']");r&&(t.csrfToken=r.getAttribute("content"))},getClasses(e,t){const r=[t],n=this.state.validator.errors(e);return n&&n.length>0&&r.push("is-danger"),r.join(" ")}},template:function(e,t,r,n){return e('

\n path for storage files, if empty default path will be used\n

\n everyone can see bucket, files and download them\n
',[{type:r.IF,evaluate:function(e){return e.state.csrfToken},redundantAttribute:"expr2",selector:"[expr2]",template:e(null,[{expressions:[{type:t.ATTRIBUTE,name:"value",evaluate:function(e){return e.state.csrfToken}}]}])},{redundantAttribute:"expr3",selector:"[expr3]",expressions:[{type:t.ATTRIBUTE,name:"class",evaluate:function(e){return e.getClasses("name","input")}},{type:t.VALUE,evaluate:function(e){return e.props.name}},{type:t.EVENT,name:"onkeyup",evaluate:function(e){return t=>{e.state.validator.handle(t,"name")}}}]},{type:r.TAG,getComponent:n,evaluate:function(e){return"field-error"},slots:[],attributes:[{type:t.ATTRIBUTE,name:"errors",evaluate:function(e){return e.state.validator.errors("name")}}],redundantAttribute:"expr4",selector:"[expr4]"},{redundantAttribute:"expr5",selector:"[expr5]",expressions:[{type:t.ATTRIBUTE,name:"class",evaluate:function(e){return e.getClasses("description","textarea")}},{type:t.VALUE,evaluate:function(e){return e.props.description}},{type:t.EVENT,name:"onkeyup",evaluate:function(e){return t=>{e.state.validator.handle(t,"description")}}}]},{type:r.TAG,getComponent:n,evaluate:function(e){return"field-error"},slots:[],attributes:[{type:t.ATTRIBUTE,name:"errors",evaluate:function(e){return e.state.validator.errors("description")}}],redundantAttribute:"expr6",selector:"[expr6]"},{redundantAttribute:"expr7",selector:"[expr7]",expressions:[{type:t.ATTRIBUTE,name:"class",evaluate:function(e){return e.getClasses("path","input")}},{type:t.VALUE,evaluate:function(e){return e.props.path}},{type:t.EVENT,name:"onkeyup",evaluate:function(e){return t=>{e.state.validator.handle(t,"path")}}}]},{type:r.TAG,getComponent:n,evaluate:function(e){return"field-error"},slots:[],attributes:[{type:t.ATTRIBUTE,name:"errors",evaluate:function(e){return e.state.validator.errors("path")}}],redundantAttribute:"expr8",selector:"[expr8]"},{redundantAttribute:"expr9",selector:"[expr9]",expressions:[{type:t.ATTRIBUTE,name:"checked",evaluate:function(e){return e.props.public}}]},{redundantAttribute:"expr10",selector:"[expr10]",expressions:[{type:t.ATTRIBUTE,name:"disabled",evaluate:function(e){return e.state.validator.errors().length>0}}]}])},name:"urban-bucket-form"};riot.register("urban-bucket-form",l)}}); \ No newline at end of file +(function(e,t,n){"use strict";var i=function(e,t,r){r=a.extend({},a.options,r);var n=a.runValidations(e,t,r);if(n.some((function(e){return a.isPromise(e.error)})))throw new Error("Use validate.async if you want support for promises");return i.processValidationResults(n,r)},a=i;a.extend=function(e){return[].slice.call(arguments,1).forEach((function(t){for(var r in t)e[r]=t[r]})),e},a.extend(i,{version:{major:0,minor:13,patch:1,metadata:null,toString:function(){var e=a.format("%{major}.%{minor}.%{patch}",a.version);return a.isEmpty(a.version.metadata)||(e+="+"+a.version.metadata),e}},Promise:"undefined"!=typeof Promise?Promise:null,EMPTY_STRING_REGEXP:/^\s*$/,runValidations:function(e,t,r){var n,i,s,o,u,l,c,f=[];for(n in(a.isDomElement(e)||a.isJqueryElement(e))&&(e=a.collectFormValues(e)),t)for(i in s=a.getDeepObjectValue(e,n),o=a.result(t[n],s,e,n,r,t)){if(!(u=a.validators[i]))throw c=a.format("Unknown validator %{name}",{name:i}),new Error(c);l=o[i],(l=a.result(l,s,e,n,r,t))&&f.push({attribute:n,value:s,validator:i,globalOptions:r,attributes:e,options:l,error:u.call(u,s,l,n,e,r)})}return f},processValidationResults:function(e,t){e=a.pruneEmptyErrors(e,t),e=a.expandMultipleErrors(e,t),e=a.convertErrorMessages(e,t);var r=t.format||"grouped";if("function"!=typeof a.formatters[r])throw new Error(a.format("Unknown format %{format}",t));return e=a.formatters[r](e),a.isEmpty(e)?void 0:e},async:function(e,t,r){var n=(r=a.extend({},a.async.options,r)).wrapErrors||function(e){return e};!1!==r.cleanAttributes&&(e=a.cleanAttributes(e,t));var i=a.runValidations(e,t,r);return new a.Promise((function(s,o){a.waitForResults(i).then((function(){var u=a.processValidationResults(i,r);u?o(new n(u,r,e,t)):s(e)}),(function(e){o(e)}))}))},single:function(e,t,r){return r=a.extend({},a.single.options,r,{format:"flat",fullMessages:!1}),a({single:e},{single:t},r)},waitForResults:function(e){return e.reduce((function(e,t){return a.isPromise(t.error)?e.then((function(){return t.error.then((function(e){t.error=e||null}))})):e}),new a.Promise((function(e){e()})))},result:function(e){var t=[].slice.call(arguments,1);return"function"==typeof e&&(e=e.apply(null,t)),e},isNumber:function(e){return"number"==typeof e&&!isNaN(e)},isFunction:function(e){return"function"==typeof e},isInteger:function(e){return a.isNumber(e)&&e%1==0},isBoolean:function(e){return"boolean"==typeof e},isObject:function(e){return e===Object(e)},isDate:function(e){return e instanceof Date},isDefined:function(e){return null!=e},isPromise:function(e){return!!e&&a.isFunction(e.then)},isJqueryElement:function(e){return e&&a.isString(e.jquery)},isDomElement:function(e){return!!e&&(!(!e.querySelectorAll||!e.querySelector)&&(!(!a.isObject(document)||e!==document)||("object"==typeof HTMLElement?e instanceof HTMLElement:e&&"object"==typeof e&&null!==e&&1===e.nodeType&&"string"==typeof e.nodeName)))},isEmpty:function(e){var t;if(!a.isDefined(e))return!0;if(a.isFunction(e))return!1;if(a.isString(e))return a.EMPTY_STRING_REGEXP.test(e);if(a.isArray(e))return 0===e.length;if(a.isDate(e))return!1;if(a.isObject(e)){for(t in e)return!1;return!0}return!1},format:a.extend((function(e,t){return a.isString(e)?e.replace(a.format.FORMAT_REGEXP,(function(e,r,n){return"%"===r?"%{"+n+"}":String(t[n])})):e}),{FORMAT_REGEXP:/(%?)%\{([^\}]+)\}/g}),prettify:function(e){return a.isNumber(e)?100*e%1==0?""+e:parseFloat(Math.round(100*e)/100).toFixed(2):a.isArray(e)?e.map((function(e){return a.prettify(e)})).join(", "):a.isObject(e)?a.isDefined(e.toString)?e.toString():JSON.stringify(e):(e=""+e).replace(/([^\s])\.([^\s])/g,"$1 $2").replace(/\\+/g,"").replace(/[_-]/g," ").replace(/([a-z])([A-Z])/g,(function(e,t,r){return t+" "+r.toLowerCase()})).toLowerCase()},stringifyValue:function(e,t){return(t&&t.prettify||a.prettify)(e)},isString:function(e){return"string"==typeof e},isArray:function(e){return"[object Array]"==={}.toString.call(e)},isHash:function(e){return a.isObject(e)&&!a.isArray(e)&&!a.isFunction(e)},contains:function(e,t){return!!a.isDefined(e)&&(a.isArray(e)?-1!==e.indexOf(t):t in e)},unique:function(e){return a.isArray(e)?e.filter((function(e,t,r){return r.indexOf(e)==t})):e},forEachKeyInKeypath:function(e,t,r){if(a.isString(t)){var n,i="",s=!1;for(n=0;ns&&(n=t.tooLong||this.tooLong||"is too long (maximum is %{count} characters)",u.push(a.format(n,{count:s}))),u.length>0?t.message||u:void 0):t.message||this.notValid||"has an incorrect length"}},numericality:function(e,t,r,n,i){if(a.isDefined(e)){var s,o,u=[],l={greaterThan:function(e,t){return e>t},greaterThanOrEqualTo:function(e,t){return e>=t},equalTo:function(e,t){return e===t},lessThan:function(e,t){return es&&(r=t.tooLate||t.message||this.tooLate||"must be no later than %{date}",r=a.format(r,{date:this.format(s,t),value:this.format(e,t)}),n.push(r)),n.length?a.unique(n):void 0)}}),{parse:null,format:null}),date:function(e,t){return t=a.extend({},t,{dateOnly:!0}),a.validators.datetime.call(a.validators.datetime,e,t)},format:function(e,t){(a.isString(t)||t instanceof RegExp)&&(t={pattern:t});var r,n=(t=a.extend({},this.options,t)).message||this.message||"is invalid",i=t.pattern;if(a.isDefined(e))return a.isString(e)?(a.isString(i)&&(i=new RegExp(t.pattern,t.flags)),(r=i.exec(e))&&r[0].length==e.length?void 0:n):n},inclusion:function(e,t){if(a.isDefined(e)&&(a.isArray(t)&&(t={within:t}),t=a.extend({},this.options,t),!a.contains(t.within,e))){var r=t.message||this.message||"^%{value} is not included in the list";return a.format(r,{value:e})}},exclusion:function(e,t){if(a.isDefined(e)&&(a.isArray(t)&&(t={within:t}),t=a.extend({},this.options,t),a.contains(t.within,e))){var r=t.message||this.message||"^%{value} is restricted";return a.isString(t.within[e])&&(e=t.within[e]),a.format(r,{value:e})}},email:a.extend((function(e,t){var r=(t=a.extend({},this.options,t)).message||this.message||"is not a valid email";if(a.isDefined(e))return a.isString(e)&&this.PATTERN.exec(e)?void 0:r}),{PATTERN:/^(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])*")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)\])$/i}),equality:function(e,t,r,n,i){if(a.isDefined(e)){a.isString(t)&&(t={attribute:t});var s=(t=a.extend({},this.options,t)).message||this.message||"is not equal to %{attribute}";if(a.isEmpty(t.attribute)||!a.isString(t.attribute))throw new Error("The attribute must be a non empty string");var o=a.getDeepObjectValue(n,t.attribute),u=t.comparator||function(e,t){return e===t},l=t.prettify||i&&i.prettify||a.prettify;return u(e,o,t,r,n)?void 0:a.format(s,{attribute:l(t.attribute)})}},url:function(e,t){if(a.isDefined(e)){var r=(t=a.extend({},this.options,t)).message||this.message||"is not a valid url",n=t.schemes||this.schemes||["http","https"],i=t.allowLocal||this.allowLocal||!1,s=t.allowDataUrl||this.allowDataUrl||!1;if(!a.isString(e))return r;var o="^(?:(?:"+n.join("|")+")://)(?:\\S+(?::\\S*)?@)?(?:",u="(?:\\.(?:[a-z\\u00a1-\\uffff]{2,}))";if(i?u+="?":o+="(?!(?:10|127)(?:\\.\\d{1,3}){3})(?!(?:169\\.254|192\\.168)(?:\\.\\d{1,3}){2})(?!172\\.(?:1[6-9]|2\\d|3[0-1])(?:\\.\\d{1,3}){2})",o+="(?:[1-9]\\d?|1\\d\\d|2[01]\\d|22[0-3])(?:\\.(?:1?\\d{1,2}|2[0-4]\\d|25[0-5])){2}(?:\\.(?:[1-9]\\d?|1\\d\\d|2[0-4]\\d|25[0-4]))|(?:(?:[a-z\\u00a1-\\uffff0-9]-*)*[a-z\\u00a1-\\uffff0-9]+)(?:\\.(?:[a-z\\u00a1-\\uffff0-9]-*)*[a-z\\u00a1-\\uffff0-9]+)*"+u+")(?::\\d{2,5})?(?:[/?#]\\S*)?$",s){o="(?:"+o+")|(?:^data:(?:\\w+\\/[-+.\\w]+(?:;[\\w=]+)*)?(?:;base64)?,[A-Za-z0-9-_.!~\\*'();\\/?:@&=+$,%]*$)"}return new RegExp(o,"i").exec(e)?void 0:r}},type:a.extend((function(e,t,r,n,i){if(a.isString(t)&&(t={type:t}),a.isDefined(e)){var s,o=a.extend({},this.options,t),u=o.type;if(!a.isDefined(u))throw new Error("No type was specified");if(s=a.isFunction(u)?u:this.types[u],!a.isFunction(s))throw new Error("validate.validators.type.types."+u+" must be a function.");if(!s(e,o,r,n,i)){var l=t.message||this.messages[u]||this.message||o.message||(a.isFunction(u)?"must be of the correct type":"must be of type %{type}");return a.isFunction(l)&&(l=l(e,t,r,n,i)),a.format(l,{attribute:a.prettify(r),type:u})}}}),{types:{object:function(e){return a.isObject(e)&&!a.isArray(e)},array:a.isArray,integer:a.isInteger,number:a.isNumber,string:a.isString,date:a.isDate,boolean:a.isBoolean},messages:{}})},i.formatters={detailed:function(e){return e},flat:a.flattenErrorsToArray,grouped:function(e){var t;for(t in e=a.groupErrorsByAttribute(e))e[t]=a.flattenErrorsToArray(e[t]);return e},constraint:function(e){var t;for(t in e=a.groupErrorsByAttribute(e))e[t]=e[t].map((function(e){return e.validator})).sort();return e}},i.exposeModule(i,this,e,t,r(29))}).call(this,t,e,r(29))}).call(this,r(36)(e))},29:function(e,t){e.exports=function(){throw new Error("define cannot be used indirect")}},30:function(e,t){var r=/^(?:submit|button|image|reset|file)$/i,n=/^(?:input|select|textarea|keygen)/i,i=/(\[[^\[\]]*\])/g;function a(e,t,r){if(t.match(i)){!function e(t,r,n){if(0===r.length)return t=n;var i=r.shift(),a=i.match(/^\[(.+?)\]$/);if("[]"===i)return t=t||[],Array.isArray(t)?t.push(e(null,r,n)):(t._values=t._values||[],t._values.push(e(null,r,n))),t;if(a){var s=a[1],o=+s;isNaN(o)?(t=t||{})[s]=e(t[s],r,n):(t=t||[])[o]=e(t[o],r,n)}else t[i]=e(t[i],r,n);return t}(e,function(e){var t=[],r=new RegExp(i),n=/^([^\[\]]*)/.exec(e);for(n[1]&&t.push(n[1]);null!==(n=r.exec(e));)t.push(n[1]);return t}(t),r)}else{var n=e[t];n?(Array.isArray(n)||(e[t]=[n]),e[t].push(r)):e[t]=r}return e}function s(e,t,r){return r=r.replace(/(\r)?\n/g,"\r\n"),r=(r=encodeURIComponent(r)).replace(/%20/g,"+"),e+(e?"&":"")+encodeURIComponent(t)+"="+r}e.exports=function(e,t){"object"!=typeof t?t={hash:!!t}:void 0===t.hash&&(t.hash=!0);for(var i=t.hash?{}:"",o=t.serializer||(t.hash?a:s),u=e&&e.elements?e.elements:[],l=Object.create(null),c=0;c0?t.errors=e.errors:t.errors=[]}},template:function(e,t,r,n){return e('
',[{type:r.IF,evaluate:function(e){return e.state.errors.length>0},redundantAttribute:"expr19",selector:"[expr19]",template:e('
',[{type:r.EACH,getKey:null,condition:null,template:e(" ",[{expressions:[{type:t.TEXT,childNodeIndex:0,evaluate:function(e){return e.error}}]}]),redundantAttribute:"expr20",selector:"[expr20]",itemName:"error",indexName:null,evaluate:function(e){return e.state.errors}}])}])},name:"field-error"};riot.register("field-error",u);var l={css:null,exports:{onBeforeMount(e,t){t.validator=new o({name:{presence:!0,length:{maximum:255}},description:{length:{maximum:255}}},this);const r=document.querySelector("meta[name='csrf-token']");r&&(t.csrfToken=r.getAttribute("content"))},getClasses(e,t){const r=[t],n=this.state.validator.errors(e);return n&&n.length>0&&r.push("is-danger"),r.join(" ")}},template:function(e,t,r,n){return e('

\n path for storage files, if empty default path will be used\n

\n everyone can see bucket, files and download them\n
',[{type:r.IF,evaluate:function(e){return e.state.csrfToken},redundantAttribute:"expr8",selector:"[expr8]",template:e(null,[{expressions:[{type:t.ATTRIBUTE,name:"value",evaluate:function(e){return e.state.csrfToken}}]}])},{redundantAttribute:"expr9",selector:"[expr9]",expressions:[{type:t.ATTRIBUTE,name:"class",evaluate:function(e){return e.getClasses("name","input")}},{type:t.VALUE,evaluate:function(e){return e.props.name}},{type:t.EVENT,name:"onkeyup",evaluate:function(e){return t=>{e.state.validator.handle(t,"name")}}}]},{type:r.TAG,getComponent:n,evaluate:function(e){return"field-error"},slots:[],attributes:[{type:t.ATTRIBUTE,name:"errors",evaluate:function(e){return e.state.validator.errors("name")}}],redundantAttribute:"expr10",selector:"[expr10]"},{redundantAttribute:"expr11",selector:"[expr11]",expressions:[{type:t.ATTRIBUTE,name:"class",evaluate:function(e){return e.getClasses("description","textarea")}},{type:t.VALUE,evaluate:function(e){return e.props.description}},{type:t.EVENT,name:"onkeyup",evaluate:function(e){return t=>{e.state.validator.handle(t,"description")}}}]},{type:r.TAG,getComponent:n,evaluate:function(e){return"field-error"},slots:[],attributes:[{type:t.ATTRIBUTE,name:"errors",evaluate:function(e){return e.state.validator.errors("description")}}],redundantAttribute:"expr12",selector:"[expr12]"},{redundantAttribute:"expr13",selector:"[expr13]",expressions:[{type:t.ATTRIBUTE,name:"class",evaluate:function(e){return e.getClasses("path","input")}},{type:t.VALUE,evaluate:function(e){return e.props.path}},{type:t.EVENT,name:"onkeyup",evaluate:function(e){return t=>{e.state.validator.handle(t,"path")}}}]},{type:r.TAG,getComponent:n,evaluate:function(e){return"field-error"},slots:[],attributes:[{type:t.ATTRIBUTE,name:"errors",evaluate:function(e){return e.state.validator.errors("path")}}],redundantAttribute:"expr14",selector:"[expr14]"},{redundantAttribute:"expr15",selector:"[expr15]",expressions:[{type:t.ATTRIBUTE,name:"checked",evaluate:function(e){return e.props.public}}]},{redundantAttribute:"expr16",selector:"[expr16]",expressions:[{type:t.ATTRIBUTE,name:"disabled",evaluate:function(e){return e.state.validator.errors().length>0}}]}])},name:"urban-bucket-form"};riot.register("urban-bucket-form",l)}}); \ No newline at end of file diff --git a/public/js/home.js b/public/js/home.js index 002a52c..d58b1d0 100644 --- a/public/js/home.js +++ b/public/js/home.js @@ -1 +1 @@ -!function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}n.m=e,n.c=t,n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(i,r,function(t){return e[t]}.bind(null,r));return i},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="/",n(n.s=34)}({34:function(e,t,n){e.exports=n(37)},37:function(e,t,n){"use strict";n.r(t);var i={css:null,exports:{handleClick(){}},template:function(e,t,n,i){return e('
',[{type:n.EACH,getKey:null,condition:null,template:e('',[{redundantAttribute:"expr12",selector:"[expr12]",expressions:[{type:t.ATTRIBUTE,name:"href",evaluate:function(e){return["/bucket/",e.bucket.id].join("")}}]},{redundantAttribute:"expr13",selector:"[expr13]",expressions:[{type:t.TEXT,childNodeIndex:0,evaluate:function(e){return[e.bucket.name].join("")}}]},{type:n.IF,evaluate:function(e){return e.bucket.tags&&e.bucket.tags.length>0},redundantAttribute:"expr14",selector:"[expr14]",template:e('',[{type:n.EACH,getKey:null,condition:null,template:e(" ",[{expressions:[{type:t.TEXT,childNodeIndex:0,evaluate:function(e){return e.tag}}]}]),redundantAttribute:"expr15",selector:"[expr15]",itemName:"tag",indexName:null,evaluate:function(e){return e.bucket.tags}}])}]),redundantAttribute:"expr11",selector:"[expr11]",itemName:"bucket",indexName:null,evaluate:function(e){return e.props.buckets}},{redundantAttribute:"expr16",selector:"[expr16]",expressions:[{type:t.EVENT,name:"onclick",evaluate:function(e){return e.handleClick}}]}])},name:"buckets"},r={css:null,exports:{state:{items:[],index:0},onBeforeMount(){this.content=this.root.innerHTML,this.root.innerHTML=""},onMounted(e,t){const n=this.$(".tabs");t.wrapper=document.createElement("div"),t.wrapper.innerHTML=this.content,n.after(t.wrapper);for(let e=0;e
',[{type:n.EACH,getKey:null,condition:null,template:e(' ',[{expressions:[{type:t.ATTRIBUTE,name:"class",evaluate:function(e){return e.getCurrentClass(e.index)}},{type:t.EVENT,name:"onclick",evaluate:function(e){return()=>e.handleClick(e.event,e.index)}}]},{redundantAttribute:"expr1",selector:"[expr1]",expressions:[{type:t.TEXT,childNodeIndex:0,evaluate:function(e){return e.item}}]}]),redundantAttribute:"expr0",selector:"[expr0]",itemName:"item",indexName:"index",evaluate:function(e){return e.state.items}}])},name:"urban-accordion"};riot.register("buckets",i),riot.register("urban-login-email",{css:null,exports:{},template:function(e,t,n,i){return e('',[])},name:"urban-login-email"}),riot.register("urban-login-password",{css:null,exports:{},template:function(e,t,n,i){return e('',[])},name:"urban-login-password"}),riot.register("urban-accordion",r),riot.mount("urban-accordion"),riot.mount("urban-login-email"),riot.mount("urban-login-password"),riot.mount("urban-form-validator")}}); \ No newline at end of file +!function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}n.m=e,n.c=t,n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(i,r,function(t){return e[t]}.bind(null,r));return i},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="/",n(n.s=34)}({34:function(e,t,n){e.exports=n(38)},38:function(e,t,n){"use strict";n.r(t);var i={css:null,exports:{handleClick(){}},template:function(e,t,n,i){return e('
',[{type:n.EACH,getKey:null,condition:null,template:e('',[{redundantAttribute:"expr3",selector:"[expr3]",expressions:[{type:t.ATTRIBUTE,name:"href",evaluate:function(e){return["/bucket/",e.bucket.id].join("")}}]},{redundantAttribute:"expr4",selector:"[expr4]",expressions:[{type:t.TEXT,childNodeIndex:0,evaluate:function(e){return[e.bucket.name].join("")}}]},{type:n.IF,evaluate:function(e){return e.bucket.tags&&e.bucket.tags.length>0},redundantAttribute:"expr5",selector:"[expr5]",template:e('',[{type:n.EACH,getKey:null,condition:null,template:e(" ",[{expressions:[{type:t.TEXT,childNodeIndex:0,evaluate:function(e){return e.tag}}]}]),redundantAttribute:"expr6",selector:"[expr6]",itemName:"tag",indexName:null,evaluate:function(e){return e.bucket.tags}}])}]),redundantAttribute:"expr2",selector:"[expr2]",itemName:"bucket",indexName:null,evaluate:function(e){return e.props.buckets}},{redundantAttribute:"expr7",selector:"[expr7]",expressions:[{type:t.EVENT,name:"onclick",evaluate:function(e){return e.handleClick}}]}])},name:"buckets"},r={css:null,exports:{state:{items:[],index:0},onBeforeMount(){this.content=this.root.innerHTML,this.root.innerHTML=""},onMounted(e,t){const n=this.$(".tabs");t.wrapper=document.createElement("div"),t.wrapper.innerHTML=this.content,n.after(t.wrapper);for(let e=0;e
',[{type:n.EACH,getKey:null,condition:null,template:e(' ',[{expressions:[{type:t.ATTRIBUTE,name:"class",evaluate:function(e){return e.getCurrentClass(e.index)}},{type:t.EVENT,name:"onclick",evaluate:function(e){return()=>e.handleClick(e.event,e.index)}}]},{redundantAttribute:"expr1",selector:"[expr1]",expressions:[{type:t.TEXT,childNodeIndex:0,evaluate:function(e){return e.item}}]}]),redundantAttribute:"expr0",selector:"[expr0]",itemName:"item",indexName:"index",evaluate:function(e){return e.state.items}}])},name:"urban-accordion"};riot.register("buckets",i),riot.register("urban-login-email",{css:null,exports:{},template:function(e,t,n,i){return e('',[])},name:"urban-login-email"}),riot.register("urban-login-password",{css:null,exports:{},template:function(e,t,n,i){return e('',[])},name:"urban-login-password"}),riot.register("urban-accordion",r),riot.mount("urban-accordion"),riot.mount("urban-login-email"),riot.mount("urban-login-password"),riot.mount("urban-form-validator")}}); \ No newline at end of file diff --git a/public/mix-manifest.json b/public/mix-manifest.json index be2fd3c..29d49eb 100644 --- a/public/mix-manifest.json +++ b/public/mix-manifest.json @@ -2,6 +2,7 @@ "/js/bootstrap.js": "/js/bootstrap.js", "/css/bootstrap.css": "/css/bootstrap.css", "/js/bucket.js": "/js/bucket.js", + "/js/bucket-single.js": "/js/bucket-single.js", "/js/home.js": "/js/home.js", "/spritemap.js": "/spritemap.js", "/symbol-defs.svg": "/symbol-defs.svg" diff --git a/public/spritemap.js b/public/spritemap.js index e1ee7ad..005a304 100644 --- a/public/spritemap.js +++ b/public/spritemap.js @@ -1 +1 @@ -(window.webpackJsonp=window.webpackJsonp||[]).push([[3],{null:function(n,w){}}]); \ No newline at end of file +(window.webpackJsonp=window.webpackJsonp||[]).push([[4],{null:function(n,w){}}]); \ No newline at end of file diff --git a/resources/js/components/bucket/filemanager.riot b/resources/js/components/bucket/filemanager.riot new file mode 100644 index 0000000..40637d9 --- /dev/null +++ b/resources/js/components/bucket/filemanager.riot @@ -0,0 +1,56 @@ + +
+
+
+ + +
+ +
+
+ { file } +
+
+ +
+
+ + delete + + + download + +
+
+
+
+ +
\ No newline at end of file diff --git a/resources/js/components/filemanager/actions.riot b/resources/js/components/filemanager/actions.riot new file mode 100644 index 0000000..e69de29 diff --git a/resources/js/components/filemanager/directory.riot b/resources/js/components/filemanager/directory.riot new file mode 100644 index 0000000..e69de29 diff --git a/resources/js/components/filemanager/file.riot b/resources/js/components/filemanager/file.riot new file mode 100644 index 0000000..5786e47 --- /dev/null +++ b/resources/js/components/filemanager/file.riot @@ -0,0 +1,21 @@ + +
+
{ props.handleMarked(event, this) } }> + +
+
{ props.handleClick(event, this) } }> + { props.file.filename } +
+
{ props.handleClick(event, this) } }> + { props.file.meta.size } + { props.file.meta.updated_at } +
+
+ +
\ No newline at end of file diff --git a/resources/js/components/filemanager/filemanager.riot b/resources/js/components/filemanager/filemanager.riot new file mode 100644 index 0000000..32aab73 --- /dev/null +++ b/resources/js/components/filemanager/filemanager.riot @@ -0,0 +1,32 @@ + +
+
+
+ +
+
+
+ +
\ No newline at end of file diff --git a/resources/js/views/bucket-single.js b/resources/js/views/bucket-single.js new file mode 100644 index 0000000..56769fa --- /dev/null +++ b/resources/js/views/bucket-single.js @@ -0,0 +1,10 @@ +import Filemanager from './../components/filemanager/filemanager.riot' + +/** + * Bucket + * + * + */ + +// register components +riot.register('urban-filemanager', Filemanager) \ No newline at end of file diff --git a/resources/views/bucket/single.blade.php b/resources/views/bucket/single.blade.php index 01f4e44..61e7561 100644 --- a/resources/views/bucket/single.blade.php +++ b/resources/views/bucket/single.blade.php @@ -7,15 +7,15 @@ @section('main')

- Create Bucket + {{ $bucket->name }}

- +
@push('scripts') - + @endpush @endsection \ No newline at end of file diff --git a/webpack.mix.js b/webpack.mix.js index 00af8d2..8783223 100644 --- a/webpack.mix.js +++ b/webpack.mix.js @@ -46,6 +46,7 @@ mix .js('resources/js/bootstrap.js', 'public/js') .js('resources/js/views/home.js', 'public/js') .js('resources/js/views/bucket.js', 'public/js') + .js('resources/js/views/bucket-single.js', 'public/js') .sass('resources/scss/bootstrap.scss', 'public/css') .options({ terser: {