mirror of
https://github.com/Joxit/docker-registry-ui.git
synced 2025-04-28 16:09:54 +03:00
5 lines
No EOL
51 KiB
JavaScript
5 lines
No EOL
51 KiB
JavaScript
/* Riot v3.7.4, @license MIT */
|
|
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t(e.riot={})}(this,function(e){"use strict";function t(e,t){return[].slice.call((t||document).querySelectorAll(e))}function n(e,t){return(t||document).querySelector(e)}function r(){return document.createDocumentFragment()}function i(){return document.createTextNode("")}function o(e){var t=e.ownerSVGElement;return!!t||null===t}function a(e){return"svg"===e?document.createElementNS(ze,e):document.createElement(e)}function s(e,t,n){if(n){var r=e.ownerDocument.importNode((new DOMParser).parseFromString('<svg xmlns="'+ze+'">'+t+"</svg>","application/xml").documentElement,!0);e.appendChild(r)}else e.innerHTML=t}function u(e,t){e.style.display=t?"":"none",e.hidden=!t}function l(e,t){e.removeAttribute(t)}function c(e){return Object.keys(e).reduce(function(t,n){return t+" "+n+": "+e[n]+";"},"")}function f(e,t){return e.getAttribute(t)}function p(e,t,n){var r=Fe.exec(t);r&&r[1]?e.setAttributeNS(Be,r[1],n):e.setAttribute(t,n)}function d(e,t,n){e.insertBefore(t,n.parentNode&&n)}function h(e,t){if(e)for(var n;n=Ze.exec(e);)t(n[1].toLowerCase(),n[2]||n[3]||n[4])}function g(e,t,n){if(e){var r,i=t(e,n);if(!1===i)return;for(e=e.firstChild;e;)r=e.nextSibling,g(e,t,i),e=r}}function m(e){return Qe.test(e)}function v(e){return typeof e===Ue}function y(e){return e&&typeof e===He}function _(e){return typeof e===Ve}function x(e){return typeof e===$e}function b(e){return w(e)||""===e}function w(e){return _(e)||null===e}function N(e){return Array.isArray(e)||e instanceof Array}function O(e,t){var n=lt(e,t);return _(e[t])||n&&n.writable}function C(e,t){for(var n=e?e.length:0,r=0;r<n;r++)t(e[r],r);return e}function E(e,t){return-1!==e.indexOf(t)}function j(e){return e.replace(/-(\w)/g,function(e,t){return t.toUpperCase()})}function T(e,t){return e.slice(0,t.length)===t}function A(e,t,n,r){return Object.defineProperty(e,t,L({value:n,enumerable:!1,writable:!1,configurable:!0},r)),e}function L(e){for(var t,n=1,r=arguments,i=r.length;n<i;n++)if(t=r[n])for(var o in t)O(e,o)&&(e[o]=t[o]);return e}function k(e,t,n){var r=this.__.parent,i=this.__.item;if(!i)for(;r&&!i;)i=r.__.item,r=r.__.parent;if(O(n,"currentTarget")&&(n.currentTarget=e),O(n,"target")&&(n.target=n.srcElement),O(n,"which")&&(n.which=n.charCode||n.keyCode),n.item=i,t.call(this,n),ft.autoUpdate&&!n.preventUpdate){var o=ce(this);o.isMounted&&o.update()}}function M(e,t,n,r){var i,o=k.bind(r,n,t);n[e]=null,i=e.replace(We,""),E(r.__.listeners,n)||r.__.listeners.push(n),n[Re]||(n[Re]={}),n[Re][e]&&n.removeEventListener(i,n[Re][e]),n[Re][e]=o,n.addEventListener(i,o,!1)}function S(e,t,n){var r,o=e.tag||e.dom._tag,a=(o?o.__:{}).head,s="VIRTUAL"===e.dom.tagName;o&&e.tagName===n?o.update():(o&&(s&&(r=i(),a.parentNode.insertBefore(r,a)),o.unmount(!0)),x(n)&&(e.impl=Oe[n],e.impl&&(e.tag=o=le(e.impl,{root:e.dom,parent:t,tagName:n},e.dom.innerHTML,t),C(e.attrs,function(e){return p(o.root,e.name,e.value)}),e.tagName=n,o.mount(),s&&me(o,r||o.root),t.__.onUnmount=function(){var e=o.opts.dataIs;he(o.parent.tags,e,o),he(o.__.parent.tags,e,o),o.unmount()})))}function I(e){return e?(e=e.replace(je,""),Ge[e]&&(e=Ge[e]),e):null}function P(e){if(!this.root||!f(this.root,"virtualized")){var t,n=e.dom,r=I(e.attr),i=E([Se,Ie],r),o=e.root&&"VIRTUAL"===e.root.tagName,a=this.__.isAnonymous,s=n&&(e.parent||n.parentNode),d="style"===r,h="class"===r;if(e._riot_id)e.__.wasCreated?e.update():(e.mount(),o&&me(e,e.root));else{if(e.update)return e.update();var g=i&&!a?ye.call(this):this,m=!b(t=ot(e.expr,g)),_=y(t);if(_&&(h?t=ot(JSON.stringify(t),this):d&&(t=c(t))),!e.attr||e.wasParsedOnce&&m&&!1!==t||l(n,f(n,e.attr)?e.attr:r),e.bool&&(t=!!t&&r),e.isRtag)return S(e,this,t);if((!e.wasParsedOnce||e.value!==t)&&(e.value=t,e.wasParsedOnce=!0,!_||h||d||i)){if(m||(t=""),!r)return t+="",void(s&&(e.parent=s,"TEXTAREA"===s.tagName?(s.value=t,Je||(n.nodeValue=t)):n.nodeValue=t));v(t)?M(r,t,n,this):i?u(n,r===Ie?!t:t):(e.bool&&(n[r]=t),"value"===r&&n.value!==t?n.value=t:m&&!1!==t&&p(n,r,t),d&&n.hidden&&u(n,!1))}}}}function R(e){C(e,P.bind(this))}function $(e,t,n,r){var i=r?Object.create(r):{};return i[e.key]=t,e.pos&&(i[e.pos]=n),i}function H(e,t){for(var n=t.length,r=e.length;n>r;)n--,V.apply(t[n],[t,n])}function V(e,t){e.splice(t,1),this.unmount(),he(this.parent,this,this.__.tagName,!0)}function U(e){var t=this;C(Object.keys(this.tags),function(n){ue.apply(t.tags[n],[n,e])})}function B(e,t,n){n?_e.apply(this,[e,t]):d(e,this.root,t.root)}function z(e,t,n){n?ve.apply(this,[e,t]):d(e,this.root,t.root)}function F(e,t){t?ve.call(this,e):e.appendChild(this.root)}function D(e,t,n,r){return e?r?ot(e,n):t[e]:t}function K(e,t,n){var o,a=typeof f(e,Me)!==$e||l(e,Me),s=f(e,Pe),u=!!s&&ot.hasExpr(s),c=pe(e),p=Oe[c],d=e.parentNode,h=i(),g=se(e),m=f(e,Le),v=[],y=e.innerHTML,_=!Oe[c],b="VIRTUAL"===e.tagName,w=[];return l(e,ke),l(e,Pe),n=ot.loopKeys(n),n.isLoop=!0,m&&l(e,Le),d.insertBefore(h,e),d.removeChild(e),n.update=function(){n.value=ot(n.val,t);var i=n.value,l=r(),f=!N(i)&&!x(i),d=h.parentNode,O=[];d&&(f?i=(o=i||!1)?Object.keys(i).map(function(e){return $(n,i[e],e)}):[]:o=!1,m&&(i=i.filter(function(e,r){return n.key&&!f?!!ot(m,$(n,e,r,t)):!!ot(m,L(Object.create(t),e))})),C(i,function(r,f){var h=!o&&n.key?$(n,r,f):r,m=D(s,r,h,u),x=a&&typeof r===He&&!o,N=w.indexOf(m),C=-1===N,j=!C&&x?N:f,T=v[j],A=f>=w.length,L=x&&C||!x&&!T;L?((T=ae(p,{parent:t,isLoop:!0,isAnonymous:_,tagName:c,root:e.cloneNode(_),item:h,index:f},y)).mount(),A?F.apply(T,[l||d,b]):z.apply(T,[d,v[f],b]),A||w.splice(f,0,h),v.splice(f,0,T),g&&de(t.tags,c,T,!0)):j!==f&&x&&((s||E(i,w[j]))&&(B.apply(T,[d,v[f],b]),v.splice(f,0,v.splice(j,1)[0]),w.splice(f,0,w.splice(j,1)[0])),n.pos&&(T[n.pos]=f),!g&&T.tags&&U.call(T,f)),T.__.item=h,T.__.index=f,T.__.parent=t,O[f]=m,L||T.update(h)}),H(i,v),w=O.slice(),d.insertBefore(l,h))},n.unmount=function(){C(v,function(e){e.unmount()})},n}function q(e,t){var n=this,r=[];return g(e,function(i){var o,a,s=i.nodeType;if((t||i!==e)&&(3===s&&"STYLE"!==i.parentNode.tagName&&ot.hasExpr(i.nodeValue)&&r.push({dom:i,expr:i.nodeValue}),1===s)){var u="VIRTUAL"===i.tagName;if(o=f(i,ke))return u&&p(i,"loopVirtual",!0),r.push(K(i,n,o)),!1;if(o=f(i,Le))return r.push(Object.create(pt).init(i,n,o)),!1;if((o=f(i,Ae))&&ot.hasExpr(o))return r.push({isRtag:!0,expr:o,dom:i,attrs:[].slice.call(i.attributes)}),!1;if(a=se(i),u&&(f(i,"virtualized")&&i.parentElement.removeChild(i),a||f(i,"virtualized")||f(i,"loopVirtual")||(a={tmpl:i.outerHTML})),a&&(i!==e||t)){if(!u||f(i,Ae))return r.push(le(a,{root:i,parent:n},i.innerHTML,n)),!1;p(i,"virtualized",!0);var l=ae({tmpl:i.outerHTML},{root:i,parent:n},i.innerHTML);r.push(l)}W.apply(n,[i,i.attributes,function(e,t){t&&r.push(t)}])}}),r}function W(e,t,n){var r=this;C(t,function(t){if(!t)return!1;var i,o=t.name,a=m(o);E(Te,o)&&e.tagName.toLowerCase()!==Ce?i=Object.create(dt).init(e,r,o,t.value):ot.hasExpr(t.value)&&(i={dom:e,expr:t.value,attr:o,bool:a}),n(t,i)})}function Z(e,t,r){var i="o"===r[0],o=i?"select>":"table>";if(e.innerHTML="<"+o+t.trim()+"</"+o,o=e.firstChild,i)o.selectedIndex=-1;else{var a=yt[r];a&&1===o.childElementCount&&(o=n(a,o))}return o}function G(e,t){if(!ht.test(e))return e;var n={};return t=t&&t.replace(mt,function(e,t,r){return n[t]=n[t]||r,""}).trim(),e.replace(vt,function(e,t,r){return n[t]||r||""}).replace(gt,function(e,n){return t||n||""})}function Q(e,t,n){var r=e&&e.match(/^\s*<([-\w]+)/),i=r&&r[1].toLowerCase(),o=a(n?bt:xt);return e=G(e,t),_t.test(i)?o=Z(o,e,i):s(o,e,n),o}function J(e,t){var n=this,r=n.name,i=n.tmpl,o=n.css,a=n.attrs,s=n.onCreate;return Oe[r]||(X(r,i,o,a,s),Oe[r].class=this.constructor),ge(e,r,t,this),o&&nt.inject(),this}function X(e,t,n,r,i){return v(r)&&(i=r,/^[\w-]+\s?=/.test(n)?(r=n,n=""):r=""),n&&(v(n)?i=n:nt.add(n)),e=e.toLowerCase(),Oe[e]={name:e,tmpl:t,attrs:r,fn:i},e}function Y(e,t,n,r,i){return n&&nt.add(n,e),Oe[e]={name:e,tmpl:t,attrs:r,fn:i},e}function ee(e,n,r){function i(e){if(e.tagName){var t,o=f(e,Ae);n&&o!==n&&(o=n,p(e,Ae,n)),(t=ge(e,o||e.tagName.toLowerCase(),r))&&s.push(t)}else e.length&&C(e,i)}var o,a,s=[];if(nt.inject(),y(n)&&(r=n,n=0),o=x(e)?(e="*"===e?a=xe():e+xe(e.split(/, */)))?t(e):[]:e,"*"===n){if(n=a||xe(),o.tagName)o=t(n,o);else{var u=[];C(o,function(e){return u.push(t(n,e))}),o=u}n=0}return i(o),s}function te(e,t,n){if(y(e))te("__"+Ot+++"__",e,!0);else{var r=n?Nt:wt;if(!t){if(_(r[e]))throw new Error("Unregistered mixin: "+e);return r[e]}r[e]=v(t)?L(t.prototype,r[e]||{})&&t:L(r[e]||{},t)}}function ne(){return C(Ne,function(e){return e.update()})}function re(e){Oe[e]=null}function ie(e,t,n,r,i){if(!e||!n){var o=e?ye.call(this):t||this;C(i,function(e){e.expr&&P.call(o,e.expr),r[j(e.name).replace(je,"")]=e.expr?e.expr.value:e.value})}}function oe(e){var t=this.__.isAnonymous;A(this,"isMounted",e),t||(e?this.trigger("mount"):(this.trigger("unmount"),this.off("*"),this.__.wasCreated=!1))}function ae(e,t,n){void 0===e&&(e={}),void 0===t&&(t={});var r,i=t.context||{},a=L({},t.opts),u=t.parent,c=t.isLoop,f=!!t.isAnonymous,d=ft.skipAnonymousTags&&f,g=t.item,m=t.index,y=[],_=[],b=[],w=t.root,N=t.tagName||pe(w),O="virtual"===N,j=!O&&!e.tmpl;return d||at(i),e.name&&w._tag&&w._tag.unmount(!0),A(i,"isMounted",!1),A(i,"__",{isAnonymous:f,instAttrs:y,innerHTML:n,tagName:N,index:m,isLoop:c,isInline:j,listeners:[],virts:[],wasCreated:!1,tail:null,head:null,parent:null,item:null}),A(i,"_riot_id",ut()),A(i,"root",w),L(i,{opts:a},g),A(i,"parent",u||null),A(i,"tags",{}),A(i,"refs",{}),j||c&&f?r=w:(O||(w.innerHTML=""),r=Q(e.tmpl,n,o(w))),A(i,"update",function(e){var t={},n=i.isMounted&&!d;return f&&u&&L(i,u),L(i,e),ie.apply(i,[c,u,f,t,y]),n&&i.isMounted&&v(i.shouldUpdate)&&!i.shouldUpdate(e,t)?i:(L(a,t),n&&i.trigger("update",e),R.call(i,b),n&&i.trigger("updated"),i)}),A(i,"mixin",function(){return C(arguments,function(e){var t,n,r=[],o=["init","__proto__"];e=x(e)?te(e):e,t=v(e)?new e:e;var s=Object.getPrototypeOf(t);do{r=r.concat(Object.getOwnPropertyNames(n||t))}while(n=Object.getPrototypeOf(n||t));C(r,function(e){if(!E(o,e)){var n=lt(t,e)||lt(s,e),r=n&&(n.get||n.set);!i.hasOwnProperty(e)&&r?Object.defineProperty(i,e,n):i[e]=v(t[e])?t[e].bind(i):t[e]}}),t.init&&t.init.bind(i)(a)}),i}),A(i,"mount",function(){w._tag=i,W.apply(u,[w,w.attributes,function(e,t){!f&&dt.isPrototypeOf(t)&&(t.tag=i),e.expr=t,y.push(e)}]),h(e.attrs,function(e,t){_.push({name:e,value:t})}),W.apply(i,[w,_,function(e,t){t?b.push(t):p(w,e.name,e.value)}]),ie.apply(i,[c,u,f,a,y]);var t=te(Ee);if(t&&!d)for(var n in t)t.hasOwnProperty(n)&&i.mixin(t[n]);if(e.fn&&e.fn.call(i,a),d||i.trigger("before-mount"),C(q.apply(i,[r,f]),function(e){return b.push(e)}),i.update(g),!f&&!j)for(;r.firstChild;)w.appendChild(r.firstChild);if(A(i,"root",w),!d&&i.parent){var o=ce(i.parent);o.one(o.isMounted?"updated":"mount",function(){oe.call(i,!0)})}else oe.call(i,!0);return i.__.wasCreated=!0,i}),A(i,"unmount",function(t){var n=i.root,r=n.parentNode,o=Ne.indexOf(i);if(d||i.trigger("before-unmount"),h(e.attrs,function(e){T(e,je)&&(e=e.slice(je.length)),l(w,e)}),i.__.listeners.forEach(function(e){Object.keys(e[Re]).forEach(function(t){e.removeEventListener(t,e[Re][t])})}),-1!==o&&Ne.splice(o,1),u&&!f){var a=ce(u);O?Object.keys(i.tags).forEach(function(e){return he(a.tags,e,i.tags[e])}):he(a.tags,N,i)}return i.__.virts&&C(i.__.virts,function(e){e.parentNode&&e.parentNode.removeChild(e)}),fe(b),C(y,function(e){return e.expr&&e.expr.unmount&&e.expr.unmount()}),t?s(n,""):r&&r.removeChild(n),i.__.onUnmount&&i.__.onUnmount(),i.isMounted||oe.call(i,!0),oe.call(i,!1),delete i.root._tag,i}),i}function se(e){return e.tagName&&Oe[f(e,Ae)||f(e,Ae)||e.tagName.toLowerCase()]}function ue(e,t){var n,r=this.parent;r&&(N(n=r.tags[e])?n.splice(t,0,n.splice(n.indexOf(this),1)[0]):de(r.tags,e,this))}function le(e,t,n,r){var i=ae(e,t,n),o=t.tagName||pe(t.root,!0),a=ce(r);return A(i,"parent",a),i.__.parent=r,de(a.tags,o,i),a!==r&&de(r.tags,o,i),i}function ce(e){for(var t=e;t.__.isAnonymous&&t.parent;)t=t.parent;return t}function fe(e){C(e,function(e){e.unmount?e.unmount(!0):e.tagName?e.tag.unmount(!0):e.unmount&&e.unmount()})}function pe(e,t){var n=se(e),r=!t&&f(e,Ae);return r&&!ot.hasExpr(r)?r:n?n.name:e.tagName.toLowerCase()}function de(e,t,n,r,i){var o=e[t],a=N(o),s=!_(i);if(!o||o!==n)if(!o&&r)e[t]=[n];else if(o)if(a){var u=o.indexOf(n);if(u===i)return;-1!==u&&o.splice(u,1),s?o.splice(i,0,n):o.push(n)}else e[t]=[o,n];else e[t]=n}function he(e,t,n,r){if(N(e[t])){var i=e[t].indexOf(n);-1!==i&&e[t].splice(i,1),e[t].length?1!==e[t].length||r||(e[t]=e[t][0]):delete e[t]}else e[t]===n&&delete e[t]}function ge(e,t,n,r){var i,o=Oe[t],a=Oe[t].class,s=r||(a?Object.create(a.prototype):{}),u=e._innerHTML=e._innerHTML||e.innerHTML,l=L({root:e,opts:n,context:s},{parent:n?n.parent:null});return o&&e&&(i=ae(o,l,u)),i&&i.mount&&(i.mount(!0),E(Ne,i)||Ne.push(i)),i}function me(e,t){var n=r();ve.call(e,n),t.parentNode.replaceChild(n,t)}function ve(e,t){var n,o,a=this,s=i(),u=i(),l=r();for(this.root.insertBefore(s,this.root.firstChild),this.root.appendChild(u),this.__.head=o=s,this.__.tail=u;o;)n=o.nextSibling,l.appendChild(o),a.__.virts.push(o),o=n;t?e.insertBefore(l,t.__.head):e.appendChild(l)}function ye(){return this.parent?L(Object.create(this),this.parent):this}function _e(e,t){for(var n,i=this,o=this.__.head,a=r();o;)if(n=o.nextSibling,a.appendChild(o),(o=n)===i.__.tail){a.appendChild(o),e.insertBefore(a,t.__.head);break}}function xe(e){if(!e){var t=Object.keys(Oe);return t+xe(t)}return e.filter(function(e){return!/[^-\w]/.test(e)}).reduce(function(e,t){var n=t.trim().toLowerCase();return e+",["+Ae+'="'+n+'"]'},"")}var be,we,Ne=[],Oe={},Ce="yield",Ee="__global_mixin",je="riot-",Te=["ref","data-ref"],Ae="data-is",Le="if",ke="each",Me="no-reorder",Se="show",Ie="hide",Pe="key",Re="__riot-events__",$e="string",He="object",Ve="undefined",Ue="function",Be="http://www.w3.org/1999/xlink",ze="http://www.w3.org/2000/svg",Fe=/^xlink:(\w+)/,De=typeof window===Ve?void 0:window,Ke=/^(?:t(?:body|head|foot|[rhd])|caption|col(?:group)?|opt(?:ion|group))$/,qe=/^(?:t(?:body|head|foot|[rhd])|caption|col(?:group)?)$/,We=/^on/,Ze=/([-\w]+) ?= ?(?:"([^"]*)|'([^']*)|({[^}]*}))/g,Ge={viewbox:"viewBox",preserveaspectratio:"preserveAspectRatio"},Qe=/^(?:disabled|checked|readonly|required|allowfullscreen|auto(?:focus|play)|compact|controls|default|formnovalidate|hidden|ismap|itemscope|loop|multiple|muted|no(?:resize|shade|validate|wrap)?|open|reversed|seamless|selected|sortable|truespeed|typemustmatch)$/,Je=0|(De&&De.document||{}).documentMode,Xe=Object.freeze({$$:t,$:n,createFrag:r,createDOMPlaceholder:i,isSvg:o,mkEl:a,setInnerHTML:s,toggleVisibility:u,remAttr:l,styleObjectToString:c,getAttr:f,setAttr:p,safeInsert:d,walkAttrs:h,walkNodes:g}),Ye={},et=[],tt=!1;De&&(be=function(){var e=a("style"),t=n("style[type=riot]");return p(e,"type","text/css"),t?(t.id&&(e.id=t.id),t.parentNode.replaceChild(e,t)):document.head.appendChild(e),e}(),we=be.styleSheet);var nt={styleNode:be,add:function(e,t){t?Ye[t]=e:et.push(e),tt=!0},inject:function(){if(De&&tt){tt=!1;var e=Object.keys(Ye).map(function(e){return Ye[e]}).concat(et).join("\n");we?we.cssText=e:be.innerHTML=e}}},rt=function(){function e(e,t){for(;--t>=0&&/\s/.test(e[t]););return t}var t="[{(,;:?=|&!^~>%*/",n=["case","default","do","else","in","instanceof","prefix","return","typeof","void","yield"],r=n.reduce(function(e,t){return e+t.slice(-1)},""),i=/^\/(?=[^*>/])[^[/\\]*(?:(?:\\.|\[(?:\\.|[^\]\\]*)*\])[^[\\/]*)*?\/[gimuy]*/,o=/[$\w]/;return function(a,s){var u=/.*/g,l=u.lastIndex=s++,c=u.exec(a)[0].match(i);if(c){var f=l+c[0].length,p=a[l=e(a,l)];if(l<0||~t.indexOf(p))return f;if("."===p)"."===a[l-1]&&(s=f);else if("+"===p||"-"===p)(a[--l]!==p||(l=e(a,l))<0||!o.test(a[l]))&&(s=f);else if(~r.indexOf(p)){for(var d=l+1;--l>=0&&o.test(a[l]););~n.indexOf(a.slice(l+1,d))&&(s=f)}}return s}}(),it=function(e){function t(e){return e}function n(e,t){return t||(t=_),new RegExp(e.source.replace(/{/g,t[2]).replace(/}/g,t[3]),e.global?u:"")}function r(e){if(e===m)return v;var t=e.split(" ");if(2!==t.length||p.test(e))throw new Error('Unsupported brackets "'+e+'"');return t=t.concat(e.replace(d,"\\").split(" ")),t[4]=n(t[1].length>1?/{[\S\s]*?}/:v[4],t),t[5]=n(e.length>3?/\\({|})/g:v[5],t),t[6]=n(v[6],t),t[7]=RegExp("\\\\("+t[3]+")|([[({])|("+t[3]+")|"+h,u),t[8]=e,t}function i(e){return e instanceof RegExp?a(e):_[e]}function o(e){(e||(e=m))!==_[8]&&(_=r(e),a=e===m?t:n,_[9]=a(v[9])),y=e}var a,s,u="g",l=/\/\*[^*]*\*+(?:[^*\/][^*]*\*+)*\//g,c=/"[^"\\]*(?:\\[\S\s][^"\\]*)*"|'[^'\\]*(?:\\[\S\s][^'\\]*)*'|`[^`\\]*(?:\\[\S\s][^`\\]*)*`/g,f=c.source+"|"+/(?:\breturn\s+|(?:[$\w\)\]]|\+\+|--)\s*(\/)(?![*\/]))/.source+"|"+/\/(?=[^*\/])[^[\/\\]*(?:(?:\[(?:\\.|[^\]\\]*)*\]|\\.)[^[\/\\]*)*?([^<]\/)[gim]*/.source,p=RegExp("[\\x00-\\x1F<>a-zA-Z0-9'\",;\\\\]"),d=/(?=[[\]()*+?.^$|])/g,h=c.source+"|"+/(\/)(?![*\/])/.source,g={"(":RegExp("([()])|"+h,u),"[":RegExp("([[\\]])|"+h,u),"{":RegExp("([{}])|"+h,u)},m="{ }",v=["{","}","{","}",/{[^}]*}/,/\\([{}])/g,/\\({)|{/g,RegExp("\\\\(})|([[({])|(})|"+h,u),m,/^\s*{\^?\s*([$\w]+)(?:\s*,\s*(\S+))?\s+in\s+(\S.*)\s*}/,/(^|[^\\]){=[\S\s]*?}/],y=void 0,_=[];return i.split=function(e,t,n){function r(e){h&&(e=h+e,h=""),t||a?f.push(e&&e.replace(n[5],"$1")):f.push(e)}function i(n,r,i){return i&&(r=rt(e,n)),t&&r>n+2&&(l="⁗"+d.length+"~",d.push(e.slice(n,r)),h+=e.slice(s,n)+l,s=r),r}n||(n=_);var o,a,s,u,l,c,f=[],p=n[6],d=[],h="";for(a=s=p.lastIndex=0;o=p.exec(e);){if(c=p.lastIndex,u=o.index,a){if(o[2]){var m=o[2],v=g[m],y=1;for(v.lastIndex=c;o=v.exec(e);)if(o[1]){if(o[1]===m)++y;else if(!--y)break}else v.lastIndex=i(o.index,v.lastIndex,o[2]);p.lastIndex=y?e.length:v.lastIndex;continue}if(!o[3]){p.lastIndex=i(u,c,o[4]);continue}}o[1]||(r(e.slice(s,u)),s=p.lastIndex,(p=n[6+(a^=1)]).lastIndex=s)}return e&&s<e.length&&r(e.slice(s)),f.qblocks=d,f},i.hasExpr=function(e){return _[4].test(e)},i.loopKeys=function(e){var t=e.match(_[9]);return t?{key:t[1],pos:t[2],val:_[0]+t[3].trim()+_[1]}:{val:e.trim()}},i.array=function(e){return e?r(e):_},Object.defineProperty(i,"settings",{set:function(e){var t;t=(e=e||{}).brackets,Object.defineProperty(e,"brackets",{set:o,get:function(){return y},enumerable:!0}),s=e,o(t)},get:function(){return s}}),i.settings="undefined"!=typeof riot&&riot.settings||{},i.set=o,i.skipRegex=rt,i.R_STRINGS=c,i.R_MLCOMMS=l,i.S_QBLOCKS=f,i.S_QBLOCK2=h,i}(),ot=function(){function e(e,r){return e?(a[e]||(a[e]=n(e))).call(r,t.bind({data:r,tmpl:e})):e}function t(t,n){t.riotData={tagName:n&&n.__&&n.__.tagName,_riot_id:n&&n._riot_id},e.errorHandler?e.errorHandler(t):"undefined"!=typeof console&&"function"==typeof console.error&&(console.error(t.message),console.log("<%s> %s",t.riotData.tagName||"Unknown tag",this.tmpl),console.log(this.data))}function n(e){var t=r(e);return"try{return "!==t.slice(0,11)&&(t="return "+t),new Function("E",t+";")}function r(e){var t,n=it.split(e.replace(s,'"'),1),r=n.qblocks;if(n.length>2||n[0]){var o,a,l=[];for(o=a=0;o<n.length;++o)(t=n[o])&&(t=1&o?i(t,1,r):'"'+t.replace(/\\/g,"\\\\").replace(/\r\n?|\n/g,"\\n").replace(/"/g,'\\"')+'"')&&(l[a++]=t);t=a<2?l[0]:"["+l.join(",")+'].join("")'}else t=i(n[1],0,r);return r.length&&(t=t.replace(u,function(e,t){return r[t].replace(/\r/g,"\\r").replace(/\n/g,"\\n")})),t}function i(e,t,n){if(e=e.replace(/\s+/g," ").trim().replace(/\ ?([[\({},?\.:])\ ?/g,"$1")){for(var r,i=[],a=0;e&&(r=e.match(l))&&!r.index;){var s,u,f=/,|([[{(])|$/g;for(e=RegExp.rightContext,s=r[2]?n[r[2]].slice(1,-1).trim().replace(/\s+/g," "):r[1];u=(r=f.exec(e))[1];)!function(t,n){var r,i=1,o=c[t];for(o.lastIndex=n.lastIndex;r=o.exec(e);)if(r[0]===t)++i;else if(!--i)break;n.lastIndex=i?e.length:o.lastIndex}(u,f);u=e.slice(0,r.index),e=RegExp.rightContext,i[a++]=o(u,1,s)}e=a?a>1?"["+i.join(",")+'].join(" ").trim()':i[0]:o(e,t)}return e}function o(e,t,n){var r;return e=e.replace(p,function(e,t,n,i,o){return n&&(i=r?0:i+e.length,"this"!==n&&"global"!==n&&"window"!==n?(e=t+'("'+n+f+n,i&&(r="."===(o=o[i])||"("===o||"["===o)):i&&(r=!d.test(o.slice(i)))),e}),r&&(e="try{return "+e+"}catch(e){E(e,this)}"),n?e=(r?"function(){"+e+"}.call(this)":"("+e+")")+'?"'+n+'":""':t&&(e="function(v){"+(r?e.replace("return ","v="):"v=("+e+")")+';return v||v===0?v:""}.call(this)'),e}var a={};e.hasExpr=it.hasExpr,e.loopKeys=it.loopKeys,e.clearCache=function(){a={}},e.errorHandler=null;var s=/\u2057/g,u=/\u2057(\d+)~/g,l=/^(?:(-?[_A-Za-z\xA0-\xFF][-\w\xA0-\xFF]*)|\u2057(\d+)~):/,c={"(":/[()]/g,"[":/[[\]]/g,"{":/[{}]/g},f='"in this?this:'+("object"!=typeof window?"global":"window")+").",p=/[,{][\$\w]+(?=:)|(^ *|[^$\w\.{])(?!(?:typeof|true|false|null|undefined|in|instanceof|is(?:Finite|NaN)|void|NaN|new|Date|RegExp|Math)(?![$\w]))([$_A-Za-z][$\w]*)/g,d=/^(?=(\.[$\w]+))\1(?:[^.[(]|$)/;return e.version=it.version="v3.0.8",e}(),at=function(e){e=e||{};var t={},n=Array.prototype.slice;return Object.defineProperties(e,{on:{value:function(n,r){return"function"==typeof r&&(t[n]=t[n]||[]).push(r),e},enumerable:!1,writable:!1,configurable:!1},off:{value:function(n,r){if("*"!=n||r)if(r)for(var i,o=t[n],a=0;i=o&&o[a];++a)i==r&&o.splice(a--,1);else delete t[n];else t={};return e},enumerable:!1,writable:!1,configurable:!1},one:{value:function(t,n){function r(){e.off(t,r),n.apply(e,arguments)}return e.on(t,r)},enumerable:!1,writable:!1,configurable:!1},trigger:{value:function(r){var i,o,a,s=arguments,u=arguments.length-1,l=new Array(u);for(a=0;a<u;a++)l[a]=s[a+1];for(i=n.call(t[r]||[],0),a=0;o=i[a];++a)o.apply(e,l);return t["*"]&&"*"!=r&&e.trigger.apply(e,["*",r].concat(l)),e},enumerable:!1,writable:!1,configurable:!1}}),e},st=Object.freeze({isBoolAttr:m,isFunction:v,isObject:y,isUndefined:_,isString:x,isBlank:b,isNil:w,isArray:N,isWritable:O}),ut=function(){var e=-1;return function(){return++e}}(),lt=function(e,t){return Object.getOwnPropertyDescriptor(e,t)},ct=Object.freeze({each:C,contains:E,toCamel:j,startsWith:T,defineProperty:A,uid:ut,getPropDescriptor:lt,extend:L}),ft=L(Object.create(it.settings),{skipAnonymousTags:!0,autoUpdate:!0}),pt={init:function(e,t,n){l(e,Le),this.tag=t,this.expr=n,this.stub=i(),this.pristine=e;var r=e.parentNode;return r.insertBefore(this.stub,e),r.removeChild(e),this},update:function(){this.value=ot(this.expr,this.tag),this.value&&!this.current?(this.current=this.pristine.cloneNode(!0),this.stub.parentNode.insertBefore(this.current,this.stub),this.expressions=q.apply(this.tag,[this.current,!0])):!this.value&&this.current&&(fe(this.expressions),this.current._tag?this.current._tag.unmount():this.current.parentNode&&this.current.parentNode.removeChild(this.current),this.current=null,this.expressions=[]),this.value&&R.call(this.tag,this.expressions)},unmount:function(){fe(this.expressions||[])}},dt={init:function(e,t,n,r){return this.dom=e,this.attr=n,this.rawValue=r,this.parent=t,this.hasExp=ot.hasExpr(r),this},update:function(){var e=this.value,t=this.parent&&ce(this.parent),n=this.dom.__ref||this.tag||this.dom;this.value=this.hasExp?ot(this.rawValue,this.parent):this.rawValue,!b(e)&&t&&he(t.refs,e,n),!b(this.value)&&x(this.value)?(t&&de(t.refs,this.value,n,null,this.parent.__.index),this.value!==e&&p(this.dom,this.attr,this.value)):l(this.dom,this.attr),this.dom.__ref||(this.dom.__ref=n)},unmount:function(){var e=this.tag||this.dom,t=this.parent&&ce(this.parent);!b(this.value)&&t&&he(t.refs,this.value,e)}},ht=/<yield\b/i,gt=/<yield\s*(?:\/>|>([\S\s]*?)<\/yield\s*>|>)/gi,mt=/<yield\s+to=['"]([^'">]*)['"]\s*>([\S\s]*?)<\/yield\s*>/gi,vt=/<yield\s+from=['"]?([-\w]+)['"]?\s*(?:\/>|>([\S\s]*?)<\/yield\s*>)/gi,yt={tr:"tbody",th:"tr",td:"tr",col:"colgroup"},_t=Je&&Je<10?Ke:qe,xt="div",bt="svg",wt={},Nt=wt[Ee]={},Ot=0,Ct=Object.freeze({Tag:J,tag:X,tag2:Y,mount:ee,mixin:te,update:ne,unregister:re,version:"v3.7.4"}),Et=Object.freeze({getTag:se,moveChildTag:ue,initChildTag:le,getImmediateCustomParentTag:ce,unmountAll:fe,getTagName:pe,arrayishAdd:de,arrayishRemove:he,mountTo:ge,makeReplaceVirtual:me,makeVirtual:ve,inheritParentProps:ye,moveVirtual:_e,selectTags:xe}),jt=ft,Tt={tmpl:ot,brackets:it,styleManager:nt,vdom:Ne,styleNode:nt.styleNode,dom:Xe,check:st,misc:ct,tags:Et},At=J,Lt=X,kt=Y,Mt=ee,St=te,It=ne,Pt=re,Rt=at,$t=L({},Ct,{observable:at,settings:jt,util:Tt});e.settings=jt,e.util=Tt,e.Tag=At,e.tag=Lt,e.tag2=kt,e.mount=Mt,e.mixin=St,e.update=It,e.unregister=Pt,e.version="v3.7.4",e.observable=Rt,e.default=$t,Object.defineProperty(e,"__esModule",{value:!0})});
|
|
|
|
var route=function(){"use strict";var e=function(e){e=e||{};var t={},r=Array.prototype.slice;Object.defineProperties(e,{on:{value:function(r,n){if(typeof n=="function"){(t[r]=t[r]||[]).push(n)}return e},enumerable:false,writable:false,configurable:false},off:{value:function(r,n){if(r=="*"&&!n){t={}}else{if(n){var i=t[r];for(var a=0,f;f=i&&i[a];++a){if(f==n){i.splice(a--,1)}}}else{delete t[r]}}return e},enumerable:false,writable:false,configurable:false},one:{value:function(t,r){function n(){e.off(t,n);r.apply(e,arguments)}return e.on(t,n)},enumerable:false,writable:false,configurable:false},trigger:{value:function(n){var i=arguments;var a=arguments.length-1,f=new Array(a),u,o,c;for(c=0;c<a;c++){f[c]=i[c+1]}u=r.call(t[n]||[],0);for(c=0;o=u[c];++c){o.apply(e,f)}if(t["*"]&&n!="*"){e.trigger.apply(e,["*",n].concat(f))}return e},enumerable:false,writable:false,configurable:false}});return e};var t=/^.+?\/\/+[^/]+/;var r="EventListener";var n="remove"+r;var i="add"+r;var a="hasAttribute";var f="popstate";var u="hashchange";var o="trigger";var c=3;var l=typeof window!="undefined"&&window;var s=typeof document!="undefined"&&document;var v=l&&history;var h=l&&(v.location||l.location);var p=P.prototype;var d=s&&s.ontouchstart?"touchstart":"click";var m=e();var y=false;var b=false;var g;var w;var $;var A;var S;var x=[];var K=0;function N(e){return e.split(/[/?#]/)}function O(e,t){var r=t.replace(/\?/g,"\\?").replace(/\*/g,"([^/?#]+?)").replace(/\.\./,".*");var n=new RegExp("^"+r+"$");var i=e.match(n);if(i){return i.slice(1)}}function T(e,t){var r;return function(){clearTimeout(r);r=setTimeout(e,t)}}function E(e){g=T(L,1);l[i](f,g);l[i](u,g);s[i](d,R);if(e){L(true)}}function P(){this.$=[];e(this);m.on("stop",this.s.bind(this));m.on("emit",this.e.bind(this))}function j(e){return e.replace(/^\/|\/$/,"")}function k(e){return typeof e=="string"}function q(e){return(e||h.href).replace(t,"")}function D(e){return w[0]==="#"?(e||h.href||"").split(w)[1]||"":(h?q(e):e||"").replace(w,"")}function L(e){var t=K===0;if(c<=K){return}K++;x.push(function(){var t=D();if(e||t!==$){m[o]("emit",t);$=t}});if(t){var r;while(r=x.shift()){r()}K=0}}function R(e){if(e.which!==1||e.metaKey||e.ctrlKey||e.shiftKey||e.defaultPrevented){return}var r=e.target;while(r&&r.nodeName!=="A"){r=r.parentNode}if(!r||r.nodeName!=="A"||r[a]("download")||!r[a]("href")||r.target&&r.target!=="_self"||r.href.indexOf(h.href.match(t)[0])===-1){return}if(r.href!==h.href&&(r.href.split("#")[0]===h.href.split("#")[0]||w[0]!=="#"&&q(r.href).indexOf(w)!==0||w[0]==="#"&&r.href.split(w)[0]!==h.href.split(w)[0]||!_(D(r.href),r.title||s.title))){return}e.preventDefault()}function _(e,t,r){if(!v){return m[o]("emit",D(e))}e=w+j(e);t=t||s.title;r?v.replaceState(null,t,e):v.pushState(null,t,e);s.title=t;b=false;L();return b}p.m=function(e,t,r){if(k(e)&&(!t||k(t))){_(e,t,r||false)}else if(t){this.r(e,t)}else{this.r("@",e)}};p.s=function(){this.off("*");this.$=[]};p.e=function(e){this.$.concat("@").some(function(t){var r=(t==="@"?A:S)(j(e),j(t));if(typeof r!="undefined"){this[o].apply(null,[t].concat(r));return b=true}},this)};p.r=function(e,t){if(e!=="@"){e="/"+j(e);this.$.push(e)}this.on(e,t)};var z=new P;var B=z.m.bind(z);B.create=function(){var e=new P;var t=e.m.bind(e);t.stop=e.s.bind(e);return t};B.base=function(e){w=e||"#";$=D()};B.exec=function(){L(true)};B.parser=function(e,t){if(!e&&!t){A=N;S=O}if(e){A=e}if(t){S=t}};B.query=function(){var e={};var t=h.href||$;t.replace(/[?&](.+?)=([^&]*)/g,function(t,r,n){e[r]=n});return e};B.stop=function(){if(y){if(l){l[n](f,g);l[n](u,g);s[n](d,R)}m[o]("stop");y=false}};B.start=function(e){if(!y){if(l){if(document.readyState==="interactive"||document.readyState==="complete"){E(e)}else{document.onreadystatechange=function(){if(document.readyState==="interactive"){setTimeout(function(){E(e)},1)}}}}y=true}};B.base();B.parser();return B}();
|
|
!function(t){function e(n){if(i[n])return i[n].exports;var o=i[n]={i:n,l:!1,exports:{}};return t[n].call(o.exports,o,o.exports,e),o.l=!0,o.exports}var i={};e.m=t,e.c=i,e.i=function(t){return t},e.d=function(t,i,n){e.o(t,i)||Object.defineProperty(t,i,{configurable:!1,enumerable:!0,get:n})},e.n=function(t){var i=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(i,"a",i),i},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=38)}([function(t,e,i){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a=function(){function t(){n(this,t)}return t.prototype.receiveBound=function(){this.container||console.error("Yor class must contain a container. It is DOM Element. Define please this.container property.");var t,e,i,n=this.container&&this.container.ownerDocument;return t=n.documentElement,"undefined"!==o(this.container.getBoundingClientRect)&&(i=this.container.getBoundingClientRect()),e=this.getWindow(n),this.mix(i,{size:Math.max(i.width,i.height),offsetTop:i.top+e.pageYOffset-t.clientTop,offsetLeft:i.left+e.pageXOffset-t.clientLeft})},t.prototype.isWindow=function(t){return null!==t&&t===t.window},t.prototype.getWindow=function(t){return this.isWindow(t)?t:9===t.nodeType&&t.defaultView},t.prototype.mix=function(t,e){for(var i in t)i in e||(e[i]=t[i]);return e},t}();e.default=a,riot.mixin("Bound",a)},function(t,e,i){"use strict";riot.tag2("material-button",'<material-waves onclick="{click}" onmousedown="{launch}" center="{opts.wavesCenter}" rounded="{opts.rounded}" opacity="{opts.wavesOpacity}" color="{opts.wavesColor}" duration="{opts[\'waves-duration\']}" ref="material-waves"></material-waves> <div class="content"><yield></yield></div>',"","",function(t){var e=this;this.dynamicAttributes=["disabled"],this.disabled=t.disabled||!1,this.launch=function(t){e.disabled||e.refs["material-waves"].trigger("launch",t)},this.on("mount",function(){e.refs["material-waves"].on("wavestart",function(t){e.trigger("wavestart",t)}),e.refs["material-waves"].on("waveend",function(){e.trigger("waveend")})}),this.click=function(){t.link&&(window.location.href=t.link),e.trigger("click")},this.mixin("dynamicAttributes")})},function(t,e,i){"use strict";riot.tag2("material-card",'<div class="title" if="{titleExist}"> <content select=".material-card-title"></content> </div> <yield></yield>',"","",function(t){var e=this;this.titleExist=!1,this.on("mount",function(){e.update({titleExist:!!e.root.querySelector(".material-card-title")})}),this.mixin("content")})},function(t,e,i){"use strict";riot.tag2("material-checkbox",'<div class="{checkbox:true,checked:checked}" onclick="{toggle}"> <div class="checkmark"></div> </div> <div class="label" onclick="{toggle}"><yield></yield></div> <input type="hidden" ref="{opts.ref}" riot-value="{checked}">',"","",function(t){var e=this;this.checked=t.checked||!1,this.disabled=t.disabled||!1,this.toggle=function(){if(e.disabled)return!1;e.update({checked:!e.checked}),e.trigger("toggle",e.checked)}})},function(module,exports,__webpack_require__){"use strict";riot.tag2("material-combo",'<material-input ref="input"></material-input> <material-dropdown-list selected="{opts.selected}" ref="dropdown"></material-dropdown-list> <input type="hidden" riot-value="{value}" ref="{opts.ref || \'combo\'}"> <div ref="options" hidden> <yield></yield> </div>',"","",function(opts){var _this=this;this.items=[],this.title=null;var lastValue=this.value,valueChanged=function(){_this.value!==lastValue&&(lastValue=_this.value,_this.root.dispatchEvent(new CustomEvent("change",{value:_this.value})))};if(this.getOptions=function(){Array.prototype.forEach.call(_this.refs.options.children,function(t,e){if("option"==t.tagName.toLowerCase()){var i={title:t.innerHTML,value:t.getAttribute("value")};_this.items.push(i),null!=t.getAttribute("isSelected")&&(_this.refs.dropdown.update({selected:e}),_this.update({value:i.value||i.title}),valueChanged(),_this.title=i.title)}}),_this.refs.dropdown.update({items:_this.items}),_this.refs.dropdown.selected&&_this.update({hValue:_this.refs.dropdown.items[_this.refs.dropdown.selected].value||_this.refs.dropdown.items[_this.refs.dropdown.selected].title}),_this.update({isParsed:!0}),valueChanged()},opts.items)try{this.items=eval(opts.items)||[],this.items.length&&this.refs.dropdown.update({items:this.items})}catch(t){console.error("Something wrong with your items. For details look at it - "+t)}this.on("mount",function(){_this.getOptions(),_this.refs.dropdown.on("selectChanged",function(t){_this.update({value:_this.refs.dropdown.items[t].value||_this.refs.dropdown.items[t].title}),valueChanged(),_this.refs.input.update({value:_this.refs.dropdown.items[t].title}),setTimeout(function(){_this.refs.dropdown.update({items:_this.items})},200)}),_this.refs.input.on("valueChanged",function(t){_this.refs.dropdown.update({items:_this.filter("items",{title:t})})}),_this.refs.input.on("focusChanged",function(t){_this.refs.input.value==(opts.defaulttext||"Choose item")&&t&&_this.refs.input.update({value:""}),""!=_this.refs.input.value||t||_this.refs.input.update({value:opts.defaulttext||"Choose item"}),t&&_this.refs.dropdown.open()}),_this.refs.dropdown.root.style.top=_this.refs.input.root.getBoundingClientRect().height+"px",_this.refs.input.update({value:_this.title||opts.defaulttext||"Choose item"})}),this.mixin("collection")})},function(module,exports,__webpack_require__){"use strict";riot.tag2("material-dropdown-list",'<ul class="{dropdown-content:true,opening:opening}" if="{opened}"> <li each="{item,key in items}" class="{selected:parent.selected==key}"> <span if="{!item.link}" onclick="{parent.select}">{item.title}</span> <a if="{item.link}" href="{item.link}" onclick="{parent.select}" title="{item.title}">{item.title}</a> </li> </ul> <div ref="overlay" if="{opts.extraclose && opened}" onclick="{close}" class="material-dropdown-list-overlay"></div>',"","",function(opts){var _this=this;if(this.opened=!1,opts.items){try{this.items=eval(opts.items)||[]}catch(t){console.error("Something wrong with your items. For details look at it - "+t)}this.update({items:this.items})}opts.selected&&this.update({selected:opts.selected}),this.select=function(t){return _this.update({selected:t.item.key}),_this.close(),_this.trigger("selectChanged",t.item.key,t.item.item),!0},this.open=function(){_this.update({opened:!0,opening:!0}),_this.opts.extraclose&&document.body.appendChild(_this.refs.overlay),setTimeout(function(){_this.update({opening:!1})},0)},this.close=function(){_this.update({opening:!0}),setTimeout(function(){_this.update({opened:!1})},200)}})},function(t,e,i){"use strict";riot.tag2("material-dropdown",'<div ref="dropdown" class="{dropdown:true,opening:opening} {opts.animation || \'top\'}" if="{opened}"> <yield></yield> </div>',"","",function(t){var e=this;this.opened=t.opened||!1,this.open=function(){e.update({opened:!0,opening:!0}),setTimeout(function(){e.update({opening:!1})},0)},this.close=function(){e.update({opening:!0}),setTimeout(function(){e.update({opened:!1})},200)}})},function(t,e,i){"use strict";riot.tag2("material-footer",'<content select=".material-footer-sections"></content> <div class="mini-footer"> <content select=".material-footer-logo"></content> <content select=".material-footer-link-list"></content> </div> <yield></yeild>',"","",function(t){this.mixin("content")})},function(t,e,i){"use strict";riot.tag2("material-input",'<div class="label-placeholder"></div> <div class="{input-content:true,not-empty:value,error:error}"> <label for="input" ref="label" if="{opts.label}">{opts.label}</label> <input type="{opts.type||\'text\'}" disabled="{disabled}" placeholder="{opts.placeholder}" onkeyup="{changeValue}" riot-value="{value}" autocomplete="off" ref="{opts.ref||\'default-input\'}" required="{required}"> <div class="iconWrapper" ref="iconWrapper" if="{opts.icon}"> <material-button ref="iconButton" center="true" waves-center="true" waves-color="{opts[\'waves-color\']||\'#fff\'}" rounded="true" onclick="{iconClickHandler}" waves-opacity="{opts[\'waves-opacity\']||\'0.6\'}" waves-duration="{opts[\'waves-duration\']||\'600\'}"> <yield></yield> </material-button> </div> </div> <div class="{underline:true,focused:focused,error:error}"> <div class="unfocused-line"></div> <div class="focused-line"></div> </div>',"","",function(t){var e=this;if(this.opts=t,this.required="",this.name=t.ref||"input",this.notSupportedTypes=["date","color","datetime","month","range","time"],-1!=this.notSupportedTypes.indexOf(t.type))throw new Error("Sorry but we do not support "+t.type+" type yet!");this.update({showIcon:!1}),this.on("mount",function(){e.update({value:t.value||"",disabled:t.disabled||!1,required:t.required||!1}),e.n=t.ref||"default-input",e.refs[e.n].addEventListener("focus",e.changeFocus),e.refs[e.n].addEventListener("blur",e.changeFocus)}),this.changeFocus=function(i){if(e.disabled)return!1;e.update({focused:e.refs[e.n]==document.activeElement}),e.trigger("focusChanged",e.focused,i),t.focuschanged&&"function"==typeof t.focuschanged&&t.focuschanged(e.focused)},this.changeValue=function(i){e.update({value:e.refs[e.n].value}),e.trigger("valueChanged",e.refs[e.n].value,i),t.valuechanged&&"function"==typeof t.valuechanged&&t.valuechanged(e.refs[e.n].value)},this.iconClickHandler=function(t){e.opts.iconclicked&&"function"==typeof e.opts.iconclicked&&e.opts.iconclicked.call(e,t),e.trigger("iconclicked",t)},this.on("update",function(t){t&&void 0!=t.value&&e.validationType&&e.isValid(e.validate(t.value))}),this.isValid=function(t){e.update({error:!t})},this.mixin("validate")})},function(t,e,i){"use strict";riot.tag2("material-navbar",'<div class="nav-wrapper"> <yield></yield> </div>',"",'role="toolbar"',function(t){})},function(t,e,i){"use strict";riot.tag2("material-pane",'<material-navbar riot-style="height:{opts.materialNavbarHeight || \'60px\'};line-height: {opts.materialNavbarHeight || \'60px\'};background-color:{opts.materialNavbarColor || \'#ccc\'}"> <content select=".material-pane-left-bar"></content> <content select=".material-pane-title"></content> <content select=".material-pane-right-bar"></content> </material-navbar> <div class="content"> <content select=".material-pane-content"></content> <yield></yield> </div>',"","",function(t){this.mixin("content")})},function(t,e,i){"use strict";riot.tag2("material-popup",'<div ref="popup" class="{popup:true,opening:opening} {opts.animation || \'top\'}" if="{opened}"> <div class="content"> <content select=".material-popup-title"></content> <yield></yield> </div> <div select=".material-popup-action"></div> </div> <div class="overlay" onclick="{close}" if="{opened}"></div>',"","",function(t){var e=this;this.opened=t.opened||!1,this.on("mount",function(){document.body.appendChild(e.root)}),this.open=function(){e.update({opened:!0,opening:!0}),setTimeout(function(){e.update({opening:!1})},0)},this.close=function(){e.update({opening:!0}),setTimeout(function(){e.update({opened:!1})},200)},this.mixin("content")})},function(t,e,i){"use strict";riot.tag2("material-snackbar",'<div class="{toast:true,error:toast.isError,opening:toast.opening}" onclick="{parent.removeToastByClick}" each="{toast,key in toasts}"> {toast.message} </div>',"","",function(t){var e=this;this.toasts=[],this.intervals={},this.addToast=function(i,n){var o=e.toastID=Math.random().toString(36).substring(7);e.toasts.push(Object.assign(i,{opening:!0,_id:o})),e.update({toasts:e.toasts}),setTimeout(function(){e.toasts[e.findToastKeyByID(o)].opening=!1,e.update({toasts:e.toasts})},50),e.intervals[o]=setTimeout(function(){e.removeToast(o)},t.duration||n||5e3)},this.removeToastAfterDurationEnding=function(t){e.removeToast(t)},this.findToastKeyByID=function(t){var i=null;return e.toasts.forEach(function(e,n){e._id==t&&(i=n)}),i},this.removeToastByClick=function(t){var i=t.item.toast._id;clearInterval(e.intervals[i]),e.removeToast(i)},this.removeToast=function(t){null!=e.findToastKeyByID(t)&&(e.toasts[e.findToastKeyByID(t)].opening=!0,e.update({toasts:e.toasts}),setTimeout(function(){e.toasts.splice(e.findToastKeyByID(t),1),e.update({toasts:e.toasts})},200))}})},function(t,e,i){"use strict";riot.tag2("material-spinner",'<svg class="loader-circular" height="50" width="50"> <circle class="loader-path" cx="25" cy="25.2" r="19.9" fill="none" stroke-width="{opts.strokewidth||3}" stroke-miterlimit="10"></circle> </svg>',"","",function(t){})},function(module,exports,__webpack_require__){"use strict";riot.tag2("material-tabs",'<material-button each="{tab,k in tabs}" onclick="{parent.onChangeTab}" class="{selected:parent.selected==k}" waves-opacity="{parent.opts.wavesOpacity}" waves-duration="{parent.opts.wavesDuration}" waves-center="{parent.opts.wavesCenter}" waves-color="{parent.opts.wavesColor}"> <div class="text" title="{tab.title}">{parent.opts.cut ? parent.cut(tab.title) : tab.title}</div> </material-button> <div class="line-wrapper" if="{opts.useline}"> <div class="line" ref="line"></div> </div> <yield></yield>',"","",function(opts){var _this=this;if(this.selected=0,this.tabs=[],opts.tabs){var tabs=[];try{tabs=opts.tabs?eval(opts.tabs):[],this.tabs=tabs}catch(t){}}this.on("mount",function(){_this.setWidth(),_this.setLinePosition()}),this.setWidth=function(){[].forEach.call(_this.root.querySelectorAll("material-button"),function(t){t.style.width=_this.refs.line.style.width=(100/_this.tabs.length).toFixed(2)+"%"})},this.onChangeTab=function(t){var e=_this.tabs.indexOf(t.item.tab);_this.changeTab(e)},this.changeTab=function(t){_this.update({selected:t}),_this.setLinePosition(),_this.trigger("tabChanged",_this.tabs[t],t),opts.tabchanged&&"function"==typeof opts.tabchanged&&opts.tabchanged(_this.tabs[t],t)},this.setLinePosition=function(){_this.refs.line.style.left=(100/_this.tabs.length).toFixed(2)*_this.selected+"%"},this.cut=function(t){return t.length>opts.cut?t.substr(0,opts.cut)+"...":t}})},function(t,e,i){"use strict";riot.tag2("material-textarea",'<div class="label-placeholder"></div> <div class="{textarea-content:true,not-empty:value,error:error}"> <label for="textarea" ref="label" if="{opts.label}">{opts.label}</label> <div class="mirror" ref="mirror"></div> <div class="textarea-container"> <textarea disabled="{disabled}" onkeyup="{changeValue}" ref="{opts.ref||\'default-textarea\'}"></textarea> </div> </div> <div class="{underline:true,focused:focused,error:error}"> <div class="unfocused-line"></div> <div class="focused-line"></div> </div>',"","",function(t){var e=this;this.opts=t,this.disabled=t.disabled||!1,this.on("mount",function(){t.maxRows&&(e.refs.mirror.style.maxHeight=t.maxRows*e.refs[e.n].getBoundingClientRect().height+"px"),e.n=t.ref||"default-textarea",e.value=t.value||"",e.refs.mirror.innerHTML=e.format(e.value),e.refs[e.n].value=e.value,e.refs[e.n].scrollTop=e.refs[e.n].scrollHeight,e.refs[e.n].addEventListener("focus",e.changeFocus),e.refs[e.n].addEventListener("blur",e.changeFocus),e.refs[e.n].addEventListener("input",e.inputHandler),e.update({value:e.value})}),this.changeFocus=function(t){if(e.disabled)return!1;var i=e.refs[e.n]==document.activeElement;e.update({focused:i}),e.trigger("focusChanged",i)},this.inputHandler=function(t){var i=e.refs[e.n].value;e.refs.mirror.innerHTML=e.format(i),e.update({value:i})},this.changeValue=function(i){e.trigger("valueChanged",e.refs[e.n].value,i),t.valuechanged&&"function"==typeof t.valuechanged&&t.valuechanged(e.refs[e.n].value)},this.isValid=function(t){e.update({error:!t})},this.format=function(t){return t.replace(/\n/g,"<br/> ")},this.on("update",function(t){t&&void 0!=t.value&&e.validationType&&e.isValid(e.validate(t.value))}),this.mixin("validate")})},function(t,e,i){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}var s=i(0),r=function(t){return t&&t.__esModule?t:{default:t}}(s);riot.tag2("material-waves",'<div id="waves" ref="waves"></div>',"","",function(t){var e=this,i=function(t){function e(i,a,s){n(this,e);var r=o(this,t.call(this));return i||console.error("You should set container to the wave!"),r.container=i,r.maxOpacity=a.opacity||.6,r.duration=a.duration||750,r.color=a.color||"#fff",r.center=a.center||!1,r.event=s,r.containerBound=r.receiveBound(),r.maxScale=r.containerBound.size/100*10,r.created=Date.now(),r.start={},r.createNode(),r.waveIn(),r}return a(e,t),e.prototype.createNode=function(){this.wave=document.createElement("div"),this.wave.classList.add("wave"),this.container.appendChild(this.wave)},e.prototype.waveIn=function(){var t=this;this.center&&!this.event&&console.error("Setup at least mouse event... Or just set center attribute"),this.start.x=this.center?this.containerBound.height/2:this.event.pageY-this.containerBound.offsetTop,this.start.y=this.center?this.containerBound.width/2:this.event.pageX-this.containerBound.offsetLeft;var e=-1!==window.navigator.userAgent.indexOf("Trident");setTimeout(function(){return t.setStyles(t.maxOpacity)},e?50:0)},e.prototype.waveOut=function(t){var e=this,i=Date.now()-this.created,n=Math.round(this.duration/2)-i,o=n>0?n:0;setTimeout(function(){e.setStyles(0),setTimeout(function(){e.wave.parentNode===e.container&&(e.container.removeChild(e.wave),t())},e.duration)},o)},e.prototype.setStyles=function(t){this.wave.setAttribute("style",this.convertStyle({top:this.start.x+"px",left:this.start.y+"px",transform:"scale("+this.maxScale+")","transition-duration":this.duration+"ms","transition-timing-function":"cubic-bezier(0.250, 0.460, 0.450, 0.940)",background:this.color,opacity:t}))},e.prototype.convertStyle=function(t){var e="";return Object.keys(t).forEach(function(i){t.hasOwnProperty(i)&&(e+=i+":"+t[i]+";")}),e},e}(r.default);this._waves=[],this._events=[],this.on("launch",function(n){var o=new i(e.refs.waves,t,n);e._waves.push(o),e.trigger("wavestart",o),e.parent&&e.parent.opts&&e.parent.opts.wavestart&&e.parent.opts.wavestart(o),e._events.length||(e._events.push(n.target.addEventListener("mouseup",function(){return e.trigger("hold")})),e._events.push(n.target.addEventListener("mouseleave",function(){return e.trigger("hold")})))}),this.on("hold",function(){e._waves[e._waves.length-1]&&e._waves[e._waves.length-1].waveOut(e.waveOut),e._waves[e._waves.length-1]&&e._waves.slice(e._waves.length-1,1)}),this.waveOut=function(){e.trigger("waveend"),e.parent&&e.parent.opts&&e.parent.opts.waveend&&e.parent.opts.waveend()}})},function(t,e,i){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var o=function(){function t(){n(this,t)}return t.prototype.filter=function(t,e){return this[t].filter(function(t){var i=!1;return Object.keys(e).forEach(function(n){var o=e[n],a=new RegExp(""+o,"i");i=a.test(t[n])}),i})},t.prototype.find=function(t,e){var i={},n=0;return t.forEach(function(t){Object.keys(e).forEach(function(o){var a=e[o];t[o]==a&&(i.e=t,i.k=n)}),n++}),i},t}();e.default=o,riot.mixin("collection",o)},function(t,e,i){"use strict";var n={init:function(){var t=this;this.on("mount",function(){[].forEach.call(t.root.querySelectorAll("content"),function(e){var i=e.getAttribute("select");[].forEach.call(t.root.querySelectorAll(i),function(t){e.parentNode.insertBefore(t,e.nextSibling)}),e.parentNode.removeChild(e)})})}};riot.mixin("content",n)},function(t,e,i){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var o=function(){function t(){n(this,t)}return t.prototype.init=function(){var t=this;this.on("update",function(e){e&&t.dynamicAttributes&&t.dynamicAttributes.forEach(function(i){void 0!=e[i]&&t.root.setAttribute(i,e[i])})})},t}();e.default=o,riot.mixin("dynamicAttributes",o)},function(t,e,i){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var o=function(){function t(){n(this,t)}return t.prototype.findTag=function(t,e){var i=null;return t.forEach(function(t){t.root.getAttribute("name").toLowerCase()!=e.toLowerCase()&&t.root.tagName.toLowerCase()!=e.toLowerCase()&&t.root.getAttribute("ref").toLowerCase()!=e.toLowerCase()||(i=t)}),i},t.prototype.turnHyphensOptsToCamelCase=function(t){for(var e in t)if(/-/.test(e)){var i=e.replace(/-([a-z])/g,function(t){return t[1].toUpperCase()});t[i]=t[e],delete t[e]}},t}();e.default=o,riot.findTag=o.findTag,riot.mixin("helpers",o)},function(module,exports,__webpack_require__){"use strict";function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(exports,"__esModule",{value:!0});var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}(),ValidateMixin=function(){function ValidateMixin(){_classCallCheck(this,ValidateMixin)}return ValidateMixin.prototype.init=function init(){if(this.opts||console.debug("Sorry, but for using validate mixin you should add following code in your component: this.opts = opts;"),this.opts&&this.opts.valid){if(this.validationType="function"==typeof this[this.opts.valid]?"Function":"Regexp","Regexp"===this.validationType)try{this.validationRegexp=eval(this.opts.valid)}catch(t){throw new Error("Something wrong with your regular expression!. Checkout --- "+t)}"Function"===this.validationType&&(this.validationFunction=this[this.opts.valid]||!1)}else this.opts&&-1!=Object.keys(this.base).indexOf(this.opts.type)&&(this.validationType="Type")},ValidateMixin.prototype.validate=function(t){return this.validationType?this["validateBy"+this.validationType](t):null},ValidateMixin.prototype.validateByFunction=function(t){if(this.validationFunction)return this.validationFunction(t)},ValidateMixin.prototype.validateByRegexp=function(t){if(this.validationRegexp)return this.validationRegexp.test(t)},ValidateMixin.prototype.validateByType=function(t){return this.base[this.opts.type].test(t)},_createClass(ValidateMixin,[{key:"base",get:function(){return{email:/^(([\w\.\-_]+)@[\w\-\_]+(\.\w+){1,}|)$/i,number:/^(\d+|)$/i,tel:/^((\+|\d)?([\d\-\(\)\#])|)+$/i,url:/([--:\w?@%&+~#=]*\.[a-z]{2,4}\/{0,2})((?:[?&](?:\w+)=(?:\w+))+|[--:\w?@%&+~#=]+)?/i}}}]),ValidateMixin}();exports.default=ValidateMixin,riot.mixin("validate",ValidateMixin)},function(t,e){},function(t,e){},function(t,e){},function(t,e){},function(t,e){},function(t,e){},function(t,e){},function(t,e){},function(t,e){},function(t,e){},function(t,e){},function(t,e){},function(t,e){},function(t,e){},function(t,e){},function(t,e){},function(t,e,i){"use strict";i(0),i(17),i(18),i(19),i(20),i(21),i(1),i(2),i(3),i(4),i(6),i(5),i(8),i(9),i(10),i(11),i(12),i(13),i(14),i(15),i(16),i(7),i(22),i(23),i(24),i(25),i(27),i(26),i(29),i(30),i(31),i(32),i(33),i(34),i(35),i(36),i(37),i(28)}]); |