initial commit
This commit is contained in:
@@ -0,0 +1,75 @@
|
||||
/**
|
||||
* Created by Pensare Software.
|
||||
* User: Theo Weijmer
|
||||
* Date: 05/12/2017
|
||||
* Time: 11:17
|
||||
*/
|
||||
var pp = {};
|
||||
$( function () {
|
||||
|
||||
pp.loginModel = {
|
||||
|
||||
username: ko.observable( '' ),
|
||||
password: ko.observable( '' ),
|
||||
|
||||
login: function () {
|
||||
pp.loginService.login();
|
||||
}
|
||||
}
|
||||
|
||||
ko.applyBindings( pp.loginModel, document.getElementById( "login-user" ) );
|
||||
|
||||
} );
|
||||
|
||||
pp.loginService = {
|
||||
|
||||
login: function () {
|
||||
var ds = pp.loginDataservice;
|
||||
var self = pp.loginService;
|
||||
var vm = pp.loginModel;
|
||||
|
||||
self.validateInput( function ( data ) {
|
||||
if ( !data ) return self.notifyWrongPassword();
|
||||
|
||||
ds.login( submitDATA, function ( data ) {
|
||||
if ( data ) return location.reload();
|
||||
} );
|
||||
} );
|
||||
|
||||
},
|
||||
|
||||
validateInput: function ( callback ) {
|
||||
var vm = pp.loginModel;
|
||||
|
||||
if ( vm.username().length < 2 ) return callback( false );
|
||||
if ( vm.password().length < 6 ) return callback( false );
|
||||
|
||||
var submitDATA = {
|
||||
username: vm.username(),
|
||||
password: vm.password
|
||||
}
|
||||
|
||||
return callback( submitDATA );
|
||||
},
|
||||
|
||||
notifyWrongPassword: function () {
|
||||
notifyMe( {
|
||||
title : 'Login fout',
|
||||
message: 'Gebruikersnaam / wachtwoord komen niet overeen',
|
||||
alert : true
|
||||
} );
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
pp.loginDataservice = {
|
||||
|
||||
login: function ( submitDATA, callback ) {
|
||||
$.post( 'index.php/login/', submitDATA, function ( data ) {
|
||||
callback( data );
|
||||
} );
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
|
||||
@@ -0,0 +1,66 @@
|
||||
/**
|
||||
* Created by Pensare Software.
|
||||
* User: Theo Weijmer
|
||||
* Date: 13/12/2017
|
||||
* Time: 17:08
|
||||
*/
|
||||
|
||||
var notifyMe = function ( options, callback ) {
|
||||
pp.notifyModel.init( options, callback );
|
||||
}
|
||||
|
||||
pp.notifyModel = {
|
||||
|
||||
title : ko.observable( null ),
|
||||
message : ko.observable( null ),
|
||||
notify : ko.observable( false ),
|
||||
alert : ko.observable( false ),
|
||||
noText : ko.observable( null ),
|
||||
yesText : ko.observable( null ),
|
||||
closeText: ko.observable( null ),
|
||||
callback : null,
|
||||
|
||||
init: function ( options, callback ) {
|
||||
var vm = pp.notifyModel;
|
||||
|
||||
vm.callback = callback;
|
||||
|
||||
vm.setOptions( options );
|
||||
|
||||
$( "#notify-me" ).modal( 'show' );
|
||||
},
|
||||
|
||||
setOptions: function ( options ) {
|
||||
var vm = pp.notifyModel;
|
||||
|
||||
vm.title( options.title || '' );
|
||||
vm.message( options.message || '' );
|
||||
vm.notify( options.notify || false );
|
||||
vm.alert( options.alert || false );
|
||||
vm.noText( options.noText || 'Nee' );
|
||||
vm.yesText( options.yesText || 'Ja' );
|
||||
vm.closeText( options.closeText || 'ok' );
|
||||
},
|
||||
|
||||
closeNo: function () {
|
||||
if ( typeof( pp.notifyModel.callback ) == 'function' ) callback( false );
|
||||
},
|
||||
|
||||
closeYes: function () {
|
||||
if ( typeof( pp.notifyModel.callback ) == 'function' ) callback( true );
|
||||
},
|
||||
|
||||
closeOk: function () {
|
||||
if ( typeof( pp.notifyModel.callback ) == 'function' ) callback();
|
||||
},
|
||||
|
||||
close: function () {
|
||||
if ( typeof( pp.notifyModel.callback ) == 'function' ) callback();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
ko.applyBindings( pp.notifyModel, document.getElementById( "notify-me" ) );
|
||||
|
||||
|
||||
+63
@@ -0,0 +1,63 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Base', ['exports', 'jquery', 'Component', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Component'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Component, global.Plugin);
|
||||
global.Base = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Component2, _Plugin) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Component3 = babelHelpers.interopRequireDefault(_Component2);
|
||||
|
||||
var Base = function (_Component) {
|
||||
babelHelpers.inherits(Base, _Component);
|
||||
|
||||
function Base() {
|
||||
babelHelpers.classCallCheck(this, Base);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Base.__proto__ || Object.getPrototypeOf(Base)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Base, [{
|
||||
key: 'initializePlugins',
|
||||
value: function initializePlugins() {
|
||||
var context = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
|
||||
|
||||
(0, _jquery2.default)('[data-plugin]', context || this.$el).each(function () {
|
||||
var $this = (0, _jquery2.default)(this),
|
||||
name = $this.data('plugin'),
|
||||
plugin = (0, _Plugin.pluginFactory)(name, $this, $this.data());
|
||||
|
||||
if (plugin) {
|
||||
plugin.initialize();
|
||||
}
|
||||
});
|
||||
}
|
||||
}, {
|
||||
key: 'initializePluginAPIs',
|
||||
value: function initializePluginAPIs() {
|
||||
var context = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : document;
|
||||
|
||||
var apis = (0, _Plugin.getPluginAPI)();
|
||||
|
||||
for (var name in apis) {
|
||||
(0, _Plugin.getPluginAPI)(name)('[data-plugin=' + name + ']', context);
|
||||
}
|
||||
}
|
||||
}]);
|
||||
return Base;
|
||||
}(_Component3.default);
|
||||
|
||||
exports.default = Base;
|
||||
});
|
||||
+78
@@ -0,0 +1,78 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Component', ['exports', 'jquery'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery);
|
||||
global.Component = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
if (typeof Object.assign === 'undefined') {
|
||||
Object.assign = _jquery2.default.extend;
|
||||
}
|
||||
var Component = function () {
|
||||
function Component() {
|
||||
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
||||
babelHelpers.classCallCheck(this, Component);
|
||||
|
||||
this.$el = options.$el ? options.$el : (0, _jquery2.default)(document);
|
||||
this.el = this.$el[0];
|
||||
delete options.$el;
|
||||
|
||||
this.options = options;
|
||||
|
||||
this.isProcessed = false;
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Component, [{
|
||||
key: 'initialize',
|
||||
value: function initialize() {
|
||||
// Initialize the Component
|
||||
}
|
||||
}, {
|
||||
key: 'process',
|
||||
value: function process() {
|
||||
// Bind the Event on the Component
|
||||
}
|
||||
}, {
|
||||
key: 'run',
|
||||
value: function run() {
|
||||
// run Component
|
||||
if (!this.isProcessed) {
|
||||
this.initialize();
|
||||
this.process();
|
||||
}
|
||||
|
||||
this.isProcessed = true;
|
||||
}
|
||||
}, {
|
||||
key: 'triggerResize',
|
||||
value: function triggerResize() {
|
||||
if (document.createEvent) {
|
||||
var ev = document.createEvent('Event');
|
||||
ev.initEvent('resize', true, true);
|
||||
window.dispatchEvent(ev);
|
||||
} else {
|
||||
element = document.documentElement;
|
||||
var event = document.createEventObject();
|
||||
element.fireEvent('onresize', event);
|
||||
}
|
||||
}
|
||||
}]);
|
||||
return Component;
|
||||
}();
|
||||
|
||||
exports.default = Component;
|
||||
});
|
||||
+85
@@ -0,0 +1,85 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Config', ['exports'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports);
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports);
|
||||
global.Config = mod.exports;
|
||||
}
|
||||
})(this, function (exports) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
var values = {
|
||||
fontFamily: 'Noto Sans, sans-serif',
|
||||
primaryColor: 'blue',
|
||||
assets: '../assets'
|
||||
};
|
||||
|
||||
function get() {
|
||||
var data = values;
|
||||
var callback = function callback(data, name) {
|
||||
return data[name];
|
||||
};
|
||||
|
||||
for (var _len = arguments.length, names = Array(_len), _key = 0; _key < _len; _key++) {
|
||||
names[_key] = arguments[_key];
|
||||
}
|
||||
|
||||
for (var i = 0; i < names.length; i++) {
|
||||
var name = names[i];
|
||||
|
||||
data = callback(data, name);
|
||||
}
|
||||
|
||||
return data;
|
||||
}
|
||||
|
||||
function set(name, value) {
|
||||
if (typeof name === 'string' && typeof value !== 'undefined') {
|
||||
values[name] = value;
|
||||
} else if ((typeof name === 'undefined' ? 'undefined' : babelHelpers.typeof(name)) === 'object') {
|
||||
values = $.extend(true, {}, values, name);
|
||||
}
|
||||
}
|
||||
|
||||
function getColor(name, level) {
|
||||
if (name === 'primary') {
|
||||
name = get('primaryColor');
|
||||
if (!name) {
|
||||
name = 'red';
|
||||
}
|
||||
}
|
||||
|
||||
if (typeof values.colors === 'undefined') {
|
||||
return null;
|
||||
}
|
||||
|
||||
if (typeof values.colors[name] !== 'undefined') {
|
||||
if (level && typeof values.colors[name][level] !== 'undefined') {
|
||||
return values.colors[name][level];
|
||||
}
|
||||
|
||||
if (typeof level === 'undefined') {
|
||||
return values.colors[name];
|
||||
}
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
function colors(name, level) {
|
||||
return getColor(name, level);
|
||||
}
|
||||
|
||||
exports.get = get;
|
||||
exports.set = set;
|
||||
exports.getColor = getColor;
|
||||
exports.colors = colors;
|
||||
});
|
||||
Vendored
+125
@@ -0,0 +1,125 @@
|
||||
/*!
|
||||
* Knockout JavaScript library v3.4.2
|
||||
* (c) The Knockout.js team - http://knockoutjs.com/
|
||||
* License: MIT (http://www.opensource.org/licenses/mit-license.php)
|
||||
*/
|
||||
|
||||
(function() {(function(n){var x=this||(0,eval)("this"),t=x.document,M=x.navigator,u=x.jQuery,H=x.JSON;(function(n){"function"===typeof define&&define.amd?define(["exports","require"],n):"object"===typeof exports&&"object"===typeof module?n(module.exports||exports):n(x.ko={})})(function(N,O){function J(a,c){return null===a||typeof a in R?a===c:!1}function S(b,c){var d;return function(){d||(d=a.a.setTimeout(function(){d=n;b()},c))}}function T(b,c){var d;return function(){clearTimeout(d);d=a.a.setTimeout(b,c)}}function U(a,
|
||||
c){c&&c!==E?"beforeChange"===c?this.Ob(a):this.Ja(a,c):this.Pb(a)}function V(a,c){null!==c&&c.k&&c.k()}function W(a,c){var d=this.Mc,e=d[s];e.T||(this.ob&&this.Oa[c]?(d.Sb(c,a,this.Oa[c]),this.Oa[c]=null,--this.ob):e.s[c]||d.Sb(c,a,e.t?{$:a}:d.yc(a)),a.Ha&&a.Hc())}function K(b,c,d,e){a.d[b]={init:function(b,g,h,l,m){var k,r;a.m(function(){var q=g(),p=a.a.c(q),p=!d!==!p,A=!r;if(A||c||p!==k)A&&a.xa.Ca()&&(r=a.a.wa(a.f.childNodes(b),!0)),p?(A||a.f.fa(b,a.a.wa(r)),a.hb(e?e(m,q):m,b)):a.f.za(b),k=p},null,
|
||||
{i:b});return{controlsDescendantBindings:!0}}};a.h.va[b]=!1;a.f.aa[b]=!0}var a="undefined"!==typeof N?N:{};a.b=function(b,c){for(var d=b.split("."),e=a,f=0;f<d.length-1;f++)e=e[d[f]];e[d[d.length-1]]=c};a.H=function(a,c,d){a[c]=d};a.version="3.4.2";a.b("version",a.version);a.options={deferUpdates:!1,useOnlyNativeEvents:!1};a.a=function(){function b(a,b){for(var c in a)a.hasOwnProperty(c)&&b(c,a[c])}function c(a,b){if(b)for(var c in b)b.hasOwnProperty(c)&&(a[c]=b[c]);return a}function d(a,b){a.__proto__=
|
||||
b;return a}function e(b,c,d,e){var m=b[c].match(r)||[];a.a.r(d.match(r),function(b){a.a.ra(m,b,e)});b[c]=m.join(" ")}var f={__proto__:[]}instanceof Array,g="function"===typeof Symbol,h={},l={};h[M&&/Firefox\/2/i.test(M.userAgent)?"KeyboardEvent":"UIEvents"]=["keyup","keydown","keypress"];h.MouseEvents="click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave".split(" ");b(h,function(a,b){if(b.length)for(var c=0,d=b.length;c<d;c++)l[b[c]]=a});var m={propertychange:!0},k=
|
||||
t&&function(){for(var a=3,b=t.createElement("div"),c=b.getElementsByTagName("i");b.innerHTML="\x3c!--[if gt IE "+ ++a+"]><i></i><![endif]--\x3e",c[0];);return 4<a?a:n}(),r=/\S+/g;return{gc:["authenticity_token",/^__RequestVerificationToken(_.*)?$/],r:function(a,b){for(var c=0,d=a.length;c<d;c++)b(a[c],c)},o:function(a,b){if("function"==typeof Array.prototype.indexOf)return Array.prototype.indexOf.call(a,b);for(var c=0,d=a.length;c<d;c++)if(a[c]===b)return c;return-1},Vb:function(a,b,c){for(var d=
|
||||
0,e=a.length;d<e;d++)if(b.call(c,a[d],d))return a[d];return null},Na:function(b,c){var d=a.a.o(b,c);0<d?b.splice(d,1):0===d&&b.shift()},Wb:function(b){b=b||[];for(var c=[],d=0,e=b.length;d<e;d++)0>a.a.o(c,b[d])&&c.push(b[d]);return c},ib:function(a,b){a=a||[];for(var c=[],d=0,e=a.length;d<e;d++)c.push(b(a[d],d));return c},Ma:function(a,b){a=a||[];for(var c=[],d=0,e=a.length;d<e;d++)b(a[d],d)&&c.push(a[d]);return c},ta:function(a,b){if(b instanceof Array)a.push.apply(a,b);else for(var c=0,d=b.length;c<
|
||||
d;c++)a.push(b[c]);return a},ra:function(b,c,d){var e=a.a.o(a.a.Bb(b),c);0>e?d&&b.push(c):d||b.splice(e,1)},la:f,extend:c,$a:d,ab:f?d:c,D:b,Ea:function(a,b){if(!a)return a;var c={},d;for(d in a)a.hasOwnProperty(d)&&(c[d]=b(a[d],d,a));return c},rb:function(b){for(;b.firstChild;)a.removeNode(b.firstChild)},nc:function(b){b=a.a.W(b);for(var c=(b[0]&&b[0].ownerDocument||t).createElement("div"),d=0,e=b.length;d<e;d++)c.appendChild(a.ba(b[d]));return c},wa:function(b,c){for(var d=0,e=b.length,m=[];d<e;d++){var k=
|
||||
b[d].cloneNode(!0);m.push(c?a.ba(k):k)}return m},fa:function(b,c){a.a.rb(b);if(c)for(var d=0,e=c.length;d<e;d++)b.appendChild(c[d])},uc:function(b,c){var d=b.nodeType?[b]:b;if(0<d.length){for(var e=d[0],m=e.parentNode,k=0,f=c.length;k<f;k++)m.insertBefore(c[k],e);k=0;for(f=d.length;k<f;k++)a.removeNode(d[k])}},Ba:function(a,b){if(a.length){for(b=8===b.nodeType&&b.parentNode||b;a.length&&a[0].parentNode!==b;)a.splice(0,1);for(;1<a.length&&a[a.length-1].parentNode!==b;)a.length--;if(1<a.length){var c=
|
||||
a[0],d=a[a.length-1];for(a.length=0;c!==d;)a.push(c),c=c.nextSibling;a.push(d)}}return a},wc:function(a,b){7>k?a.setAttribute("selected",b):a.selected=b},cb:function(a){return null===a||a===n?"":a.trim?a.trim():a.toString().replace(/^[\s\xa0]+|[\s\xa0]+$/g,"")},sd:function(a,b){a=a||"";return b.length>a.length?!1:a.substring(0,b.length)===b},Rc:function(a,b){if(a===b)return!0;if(11===a.nodeType)return!1;if(b.contains)return b.contains(3===a.nodeType?a.parentNode:a);if(b.compareDocumentPosition)return 16==
|
||||
(b.compareDocumentPosition(a)&16);for(;a&&a!=b;)a=a.parentNode;return!!a},qb:function(b){return a.a.Rc(b,b.ownerDocument.documentElement)},Tb:function(b){return!!a.a.Vb(b,a.a.qb)},A:function(a){return a&&a.tagName&&a.tagName.toLowerCase()},Zb:function(b){return a.onError?function(){try{return b.apply(this,arguments)}catch(c){throw a.onError&&a.onError(c),c;}}:b},setTimeout:function(b,c){return setTimeout(a.a.Zb(b),c)},dc:function(b){setTimeout(function(){a.onError&&a.onError(b);throw b;},0)},q:function(b,
|
||||
c,d){var e=a.a.Zb(d);d=k&&m[c];if(a.options.useOnlyNativeEvents||d||!u)if(d||"function"!=typeof b.addEventListener)if("undefined"!=typeof b.attachEvent){var f=function(a){e.call(b,a)},l="on"+c;b.attachEvent(l,f);a.a.G.qa(b,function(){b.detachEvent(l,f)})}else throw Error("Browser doesn't support addEventListener or attachEvent");else b.addEventListener(c,e,!1);else u(b).bind(c,e)},Fa:function(b,c){if(!b||!b.nodeType)throw Error("element must be a DOM node when calling triggerEvent");var d;"input"===
|
||||
a.a.A(b)&&b.type&&"click"==c.toLowerCase()?(d=b.type,d="checkbox"==d||"radio"==d):d=!1;if(a.options.useOnlyNativeEvents||!u||d)if("function"==typeof t.createEvent)if("function"==typeof b.dispatchEvent)d=t.createEvent(l[c]||"HTMLEvents"),d.initEvent(c,!0,!0,x,0,0,0,0,0,!1,!1,!1,!1,0,b),b.dispatchEvent(d);else throw Error("The supplied element doesn't support dispatchEvent");else if(d&&b.click)b.click();else if("undefined"!=typeof b.fireEvent)b.fireEvent("on"+c);else throw Error("Browser doesn't support triggering events");
|
||||
else u(b).trigger(c)},c:function(b){return a.I(b)?b():b},Bb:function(b){return a.I(b)?b.p():b},fb:function(b,c,d){var k;c&&("object"===typeof b.classList?(k=b.classList[d?"add":"remove"],a.a.r(c.match(r),function(a){k.call(b.classList,a)})):"string"===typeof b.className.baseVal?e(b.className,"baseVal",c,d):e(b,"className",c,d))},bb:function(b,c){var d=a.a.c(c);if(null===d||d===n)d="";var e=a.f.firstChild(b);!e||3!=e.nodeType||a.f.nextSibling(e)?a.f.fa(b,[b.ownerDocument.createTextNode(d)]):e.data=
|
||||
d;a.a.Wc(b)},vc:function(a,b){a.name=b;if(7>=k)try{a.mergeAttributes(t.createElement("<input name='"+a.name+"'/>"),!1)}catch(c){}},Wc:function(a){9<=k&&(a=1==a.nodeType?a:a.parentNode,a.style&&(a.style.zoom=a.style.zoom))},Sc:function(a){if(k){var b=a.style.width;a.style.width=0;a.style.width=b}},nd:function(b,c){b=a.a.c(b);c=a.a.c(c);for(var d=[],e=b;e<=c;e++)d.push(e);return d},W:function(a){for(var b=[],c=0,d=a.length;c<d;c++)b.push(a[c]);return b},bc:function(a){return g?Symbol(a):a},xd:6===k,
|
||||
yd:7===k,C:k,ic:function(b,c){for(var d=a.a.W(b.getElementsByTagName("input")).concat(a.a.W(b.getElementsByTagName("textarea"))),e="string"==typeof c?function(a){return a.name===c}:function(a){return c.test(a.name)},k=[],m=d.length-1;0<=m;m--)e(d[m])&&k.push(d[m]);return k},kd:function(b){return"string"==typeof b&&(b=a.a.cb(b))?H&&H.parse?H.parse(b):(new Function("return "+b))():null},Gb:function(b,c,d){if(!H||!H.stringify)throw Error("Cannot find JSON.stringify(). Some browsers (e.g., IE < 8) don't support it natively, but you can overcome this by adding a script reference to json2.js, downloadable from http://www.json.org/json2.js");
|
||||
return H.stringify(a.a.c(b),c,d)},ld:function(c,d,e){e=e||{};var k=e.params||{},m=e.includeFields||this.gc,f=c;if("object"==typeof c&&"form"===a.a.A(c))for(var f=c.action,l=m.length-1;0<=l;l--)for(var g=a.a.ic(c,m[l]),h=g.length-1;0<=h;h--)k[g[h].name]=g[h].value;d=a.a.c(d);var r=t.createElement("form");r.style.display="none";r.action=f;r.method="post";for(var n in d)c=t.createElement("input"),c.type="hidden",c.name=n,c.value=a.a.Gb(a.a.c(d[n])),r.appendChild(c);b(k,function(a,b){var c=t.createElement("input");
|
||||
c.type="hidden";c.name=a;c.value=b;r.appendChild(c)});t.body.appendChild(r);e.submitter?e.submitter(r):r.submit();setTimeout(function(){r.parentNode.removeChild(r)},0)}}}();a.b("utils",a.a);a.b("utils.arrayForEach",a.a.r);a.b("utils.arrayFirst",a.a.Vb);a.b("utils.arrayFilter",a.a.Ma);a.b("utils.arrayGetDistinctValues",a.a.Wb);a.b("utils.arrayIndexOf",a.a.o);a.b("utils.arrayMap",a.a.ib);a.b("utils.arrayPushAll",a.a.ta);a.b("utils.arrayRemoveItem",a.a.Na);a.b("utils.extend",a.a.extend);a.b("utils.fieldsIncludedWithJsonPost",
|
||||
a.a.gc);a.b("utils.getFormFields",a.a.ic);a.b("utils.peekObservable",a.a.Bb);a.b("utils.postJson",a.a.ld);a.b("utils.parseJson",a.a.kd);a.b("utils.registerEventHandler",a.a.q);a.b("utils.stringifyJson",a.a.Gb);a.b("utils.range",a.a.nd);a.b("utils.toggleDomNodeCssClass",a.a.fb);a.b("utils.triggerEvent",a.a.Fa);a.b("utils.unwrapObservable",a.a.c);a.b("utils.objectForEach",a.a.D);a.b("utils.addOrRemoveItem",a.a.ra);a.b("utils.setTextContent",a.a.bb);a.b("unwrap",a.a.c);Function.prototype.bind||(Function.prototype.bind=
|
||||
function(a){var c=this;if(1===arguments.length)return function(){return c.apply(a,arguments)};var d=Array.prototype.slice.call(arguments,1);return function(){var e=d.slice(0);e.push.apply(e,arguments);return c.apply(a,e)}});a.a.e=new function(){function a(b,g){var h=b[d];if(!h||"null"===h||!e[h]){if(!g)return n;h=b[d]="ko"+c++;e[h]={}}return e[h]}var c=0,d="__ko__"+(new Date).getTime(),e={};return{get:function(c,d){var e=a(c,!1);return e===n?n:e[d]},set:function(c,d,e){if(e!==n||a(c,!1)!==n)a(c,!0)[d]=
|
||||
e},clear:function(a){var b=a[d];return b?(delete e[b],a[d]=null,!0):!1},J:function(){return c++ +d}}};a.b("utils.domData",a.a.e);a.b("utils.domData.clear",a.a.e.clear);a.a.G=new function(){function b(b,c){var e=a.a.e.get(b,d);e===n&&c&&(e=[],a.a.e.set(b,d,e));return e}function c(d){var e=b(d,!1);if(e)for(var e=e.slice(0),l=0;l<e.length;l++)e[l](d);a.a.e.clear(d);a.a.G.cleanExternalData(d);if(f[d.nodeType])for(e=d.firstChild;d=e;)e=d.nextSibling,8===d.nodeType&&c(d)}var d=a.a.e.J(),e={1:!0,8:!0,9:!0},
|
||||
f={1:!0,9:!0};return{qa:function(a,c){if("function"!=typeof c)throw Error("Callback must be a function");b(a,!0).push(c)},tc:function(c,e){var f=b(c,!1);f&&(a.a.Na(f,e),0==f.length&&a.a.e.set(c,d,n))},ba:function(b){if(e[b.nodeType]&&(c(b),f[b.nodeType])){var d=[];a.a.ta(d,b.getElementsByTagName("*"));for(var l=0,m=d.length;l<m;l++)c(d[l])}return b},removeNode:function(b){a.ba(b);b.parentNode&&b.parentNode.removeChild(b)},cleanExternalData:function(a){u&&"function"==typeof u.cleanData&&u.cleanData([a])}}};
|
||||
a.ba=a.a.G.ba;a.removeNode=a.a.G.removeNode;a.b("cleanNode",a.ba);a.b("removeNode",a.removeNode);a.b("utils.domNodeDisposal",a.a.G);a.b("utils.domNodeDisposal.addDisposeCallback",a.a.G.qa);a.b("utils.domNodeDisposal.removeDisposeCallback",a.a.G.tc);(function(){var b=[0,"",""],c=[1,"<table>","</table>"],d=[3,"<table><tbody><tr>","</tr></tbody></table>"],e=[1,"<select multiple='multiple'>","</select>"],f={thead:c,tbody:c,tfoot:c,tr:[2,"<table><tbody>","</tbody></table>"],td:d,th:d,option:e,optgroup:e},
|
||||
g=8>=a.a.C;a.a.na=function(c,d){var e;if(u)if(u.parseHTML)e=u.parseHTML(c,d)||[];else{if((e=u.clean([c],d))&&e[0]){for(var k=e[0];k.parentNode&&11!==k.parentNode.nodeType;)k=k.parentNode;k.parentNode&&k.parentNode.removeChild(k)}}else{(e=d)||(e=t);var k=e.parentWindow||e.defaultView||x,r=a.a.cb(c).toLowerCase(),q=e.createElement("div"),p;p=(r=r.match(/^<([a-z]+)[ >]/))&&f[r[1]]||b;r=p[0];p="ignored<div>"+p[1]+c+p[2]+"</div>";"function"==typeof k.innerShiv?q.appendChild(k.innerShiv(p)):(g&&e.appendChild(q),
|
||||
q.innerHTML=p,g&&q.parentNode.removeChild(q));for(;r--;)q=q.lastChild;e=a.a.W(q.lastChild.childNodes)}return e};a.a.Eb=function(b,c){a.a.rb(b);c=a.a.c(c);if(null!==c&&c!==n)if("string"!=typeof c&&(c=c.toString()),u)u(b).html(c);else for(var d=a.a.na(c,b.ownerDocument),e=0;e<d.length;e++)b.appendChild(d[e])}})();a.b("utils.parseHtmlFragment",a.a.na);a.b("utils.setHtml",a.a.Eb);a.N=function(){function b(c,e){if(c)if(8==c.nodeType){var f=a.N.pc(c.nodeValue);null!=f&&e.push({Qc:c,hd:f})}else if(1==c.nodeType)for(var f=
|
||||
0,g=c.childNodes,h=g.length;f<h;f++)b(g[f],e)}var c={};return{yb:function(a){if("function"!=typeof a)throw Error("You can only pass a function to ko.memoization.memoize()");var b=(4294967296*(1+Math.random())|0).toString(16).substring(1)+(4294967296*(1+Math.random())|0).toString(16).substring(1);c[b]=a;return"\x3c!--[ko_memo:"+b+"]--\x3e"},Bc:function(a,b){var f=c[a];if(f===n)throw Error("Couldn't find any memo with ID "+a+". Perhaps it's already been unmemoized.");try{return f.apply(null,b||[]),
|
||||
!0}finally{delete c[a]}},Cc:function(c,e){var f=[];b(c,f);for(var g=0,h=f.length;g<h;g++){var l=f[g].Qc,m=[l];e&&a.a.ta(m,e);a.N.Bc(f[g].hd,m);l.nodeValue="";l.parentNode&&l.parentNode.removeChild(l)}},pc:function(a){return(a=a.match(/^\[ko_memo\:(.*?)\]$/))?a[1]:null}}}();a.b("memoization",a.N);a.b("memoization.memoize",a.N.yb);a.b("memoization.unmemoize",a.N.Bc);a.b("memoization.parseMemoText",a.N.pc);a.b("memoization.unmemoizeDomNodeAndDescendants",a.N.Cc);a.Z=function(){function b(){if(e)for(var b=
|
||||
e,c=0,m;g<e;)if(m=d[g++]){if(g>b){if(5E3<=++c){g=e;a.a.dc(Error("'Too much recursion' after processing "+c+" task groups."));break}b=e}try{m()}catch(k){a.a.dc(k)}}}function c(){b();g=e=d.length=0}var d=[],e=0,f=1,g=0;return{scheduler:x.MutationObserver?function(a){var b=t.createElement("div");(new MutationObserver(a)).observe(b,{attributes:!0});return function(){b.classList.toggle("foo")}}(c):t&&"onreadystatechange"in t.createElement("script")?function(a){var b=t.createElement("script");b.onreadystatechange=
|
||||
function(){b.onreadystatechange=null;t.documentElement.removeChild(b);b=null;a()};t.documentElement.appendChild(b)}:function(a){setTimeout(a,0)},Za:function(b){e||a.Z.scheduler(c);d[e++]=b;return f++},cancel:function(a){a-=f-e;a>=g&&a<e&&(d[a]=null)},resetForTesting:function(){var a=e-g;g=e=d.length=0;return a},rd:b}}();a.b("tasks",a.Z);a.b("tasks.schedule",a.Z.Za);a.b("tasks.runEarly",a.Z.rd);a.Aa={throttle:function(b,c){b.throttleEvaluation=c;var d=null;return a.B({read:b,write:function(e){clearTimeout(d);
|
||||
d=a.a.setTimeout(function(){b(e)},c)}})},rateLimit:function(a,c){var d,e,f;"number"==typeof c?d=c:(d=c.timeout,e=c.method);a.gb=!1;f="notifyWhenChangesStop"==e?T:S;a.Wa(function(a){return f(a,d)})},deferred:function(b,c){if(!0!==c)throw Error("The 'deferred' extender only accepts the value 'true', because it is not supported to turn deferral off once enabled.");b.gb||(b.gb=!0,b.Wa(function(c){var e,f=!1;return function(){if(!f){a.Z.cancel(e);e=a.Z.Za(c);try{f=!0,b.notifySubscribers(n,"dirty")}finally{f=
|
||||
!1}}}}))},notify:function(a,c){a.equalityComparer="always"==c?null:J}};var R={undefined:1,"boolean":1,number:1,string:1};a.b("extenders",a.Aa);a.zc=function(b,c,d){this.$=b;this.jb=c;this.Pc=d;this.T=!1;a.H(this,"dispose",this.k)};a.zc.prototype.k=function(){this.T=!0;this.Pc()};a.K=function(){a.a.ab(this,D);D.ub(this)};var E="change",D={ub:function(a){a.F={change:[]};a.Qb=1},Y:function(b,c,d){var e=this;d=d||E;var f=new a.zc(e,c?b.bind(c):b,function(){a.a.Na(e.F[d],f);e.Ka&&e.Ka(d)});e.ua&&e.ua(d);
|
||||
e.F[d]||(e.F[d]=[]);e.F[d].push(f);return f},notifySubscribers:function(b,c){c=c||E;c===E&&this.Kb();if(this.Ra(c)){var d=c===E&&this.Fc||this.F[c].slice(0);try{a.l.Xb();for(var e=0,f;f=d[e];++e)f.T||f.jb(b)}finally{a.l.end()}}},Pa:function(){return this.Qb},Zc:function(a){return this.Pa()!==a},Kb:function(){++this.Qb},Wa:function(b){var c=this,d=a.I(c),e,f,g,h;c.Ja||(c.Ja=c.notifySubscribers,c.notifySubscribers=U);var l=b(function(){c.Ha=!1;d&&h===c&&(h=c.Mb?c.Mb():c());var a=f||c.Ua(g,h);f=e=!1;
|
||||
a&&c.Ja(g=h)});c.Pb=function(a){c.Fc=c.F[E].slice(0);c.Ha=e=!0;h=a;l()};c.Ob=function(a){e||(g=a,c.Ja(a,"beforeChange"))};c.Hc=function(){c.Ua(g,c.p(!0))&&(f=!0)}},Ra:function(a){return this.F[a]&&this.F[a].length},Xc:function(b){if(b)return this.F[b]&&this.F[b].length||0;var c=0;a.a.D(this.F,function(a,b){"dirty"!==a&&(c+=b.length)});return c},Ua:function(a,c){return!this.equalityComparer||!this.equalityComparer(a,c)},extend:function(b){var c=this;b&&a.a.D(b,function(b,e){var f=a.Aa[b];"function"==
|
||||
typeof f&&(c=f(c,e)||c)});return c}};a.H(D,"subscribe",D.Y);a.H(D,"extend",D.extend);a.H(D,"getSubscriptionsCount",D.Xc);a.a.la&&a.a.$a(D,Function.prototype);a.K.fn=D;a.lc=function(a){return null!=a&&"function"==typeof a.Y&&"function"==typeof a.notifySubscribers};a.b("subscribable",a.K);a.b("isSubscribable",a.lc);a.xa=a.l=function(){function b(a){d.push(e);e=a}function c(){e=d.pop()}var d=[],e,f=0;return{Xb:b,end:c,sc:function(b){if(e){if(!a.lc(b))throw Error("Only subscribable things can act as dependencies");
|
||||
e.jb.call(e.Lc,b,b.Gc||(b.Gc=++f))}},w:function(a,d,e){try{return b(),a.apply(d,e||[])}finally{c()}},Ca:function(){if(e)return e.m.Ca()},Va:function(){if(e)return e.Va}}}();a.b("computedContext",a.xa);a.b("computedContext.getDependenciesCount",a.xa.Ca);a.b("computedContext.isInitial",a.xa.Va);a.b("ignoreDependencies",a.wd=a.l.w);var F=a.a.bc("_latestValue");a.O=function(b){function c(){if(0<arguments.length)return c.Ua(c[F],arguments[0])&&(c.ia(),c[F]=arguments[0],c.ha()),this;a.l.sc(c);return c[F]}
|
||||
c[F]=b;a.a.la||a.a.extend(c,a.K.fn);a.K.fn.ub(c);a.a.ab(c,B);a.options.deferUpdates&&a.Aa.deferred(c,!0);return c};var B={equalityComparer:J,p:function(){return this[F]},ha:function(){this.notifySubscribers(this[F])},ia:function(){this.notifySubscribers(this[F],"beforeChange")}};a.a.la&&a.a.$a(B,a.K.fn);var I=a.O.md="__ko_proto__";B[I]=a.O;a.Qa=function(b,c){return null===b||b===n||b[I]===n?!1:b[I]===c?!0:a.Qa(b[I],c)};a.I=function(b){return a.Qa(b,a.O)};a.Da=function(b){return"function"==typeof b&&
|
||||
b[I]===a.O||"function"==typeof b&&b[I]===a.B&&b.$c?!0:!1};a.b("observable",a.O);a.b("isObservable",a.I);a.b("isWriteableObservable",a.Da);a.b("isWritableObservable",a.Da);a.b("observable.fn",B);a.H(B,"peek",B.p);a.H(B,"valueHasMutated",B.ha);a.H(B,"valueWillMutate",B.ia);a.ma=function(b){b=b||[];if("object"!=typeof b||!("length"in b))throw Error("The argument passed when initializing an observable array must be an array, or null, or undefined.");b=a.O(b);a.a.ab(b,a.ma.fn);return b.extend({trackArrayChanges:!0})};
|
||||
a.ma.fn={remove:function(b){for(var c=this.p(),d=[],e="function"!=typeof b||a.I(b)?function(a){return a===b}:b,f=0;f<c.length;f++){var g=c[f];e(g)&&(0===d.length&&this.ia(),d.push(g),c.splice(f,1),f--)}d.length&&this.ha();return d},removeAll:function(b){if(b===n){var c=this.p(),d=c.slice(0);this.ia();c.splice(0,c.length);this.ha();return d}return b?this.remove(function(c){return 0<=a.a.o(b,c)}):[]},destroy:function(b){var c=this.p(),d="function"!=typeof b||a.I(b)?function(a){return a===b}:b;this.ia();
|
||||
for(var e=c.length-1;0<=e;e--)d(c[e])&&(c[e]._destroy=!0);this.ha()},destroyAll:function(b){return b===n?this.destroy(function(){return!0}):b?this.destroy(function(c){return 0<=a.a.o(b,c)}):[]},indexOf:function(b){var c=this();return a.a.o(c,b)},replace:function(a,c){var d=this.indexOf(a);0<=d&&(this.ia(),this.p()[d]=c,this.ha())}};a.a.la&&a.a.$a(a.ma.fn,a.O.fn);a.a.r("pop push reverse shift sort splice unshift".split(" "),function(b){a.ma.fn[b]=function(){var a=this.p();this.ia();this.Yb(a,b,arguments);
|
||||
var d=a[b].apply(a,arguments);this.ha();return d===a?this:d}});a.a.r(["slice"],function(b){a.ma.fn[b]=function(){var a=this();return a[b].apply(a,arguments)}});a.b("observableArray",a.ma);a.Aa.trackArrayChanges=function(b,c){function d(){if(!e){e=!0;l=b.notifySubscribers;b.notifySubscribers=function(a,b){b&&b!==E||++h;return l.apply(this,arguments)};var c=[].concat(b.p()||[]);f=null;g=b.Y(function(d){d=[].concat(d||[]);if(b.Ra("arrayChange")){var e;if(!f||1<h)f=a.a.lb(c,d,b.kb);e=f}c=d;f=null;h=0;
|
||||
e&&e.length&&b.notifySubscribers(e,"arrayChange")})}}b.kb={};c&&"object"==typeof c&&a.a.extend(b.kb,c);b.kb.sparse=!0;if(!b.Yb){var e=!1,f=null,g,h=0,l,m=b.ua,k=b.Ka;b.ua=function(a){m&&m.call(b,a);"arrayChange"===a&&d()};b.Ka=function(a){k&&k.call(b,a);"arrayChange"!==a||b.Ra("arrayChange")||(l&&(b.notifySubscribers=l,l=n),g.k(),e=!1)};b.Yb=function(b,c,d){function k(a,b,c){return m[m.length]={status:a,value:b,index:c}}if(e&&!h){var m=[],l=b.length,g=d.length,G=0;switch(c){case "push":G=l;case "unshift":for(c=
|
||||
0;c<g;c++)k("added",d[c],G+c);break;case "pop":G=l-1;case "shift":l&&k("deleted",b[G],G);break;case "splice":c=Math.min(Math.max(0,0>d[0]?l+d[0]:d[0]),l);for(var l=1===g?l:Math.min(c+(d[1]||0),l),g=c+g-2,G=Math.max(l,g),n=[],s=[],w=2;c<G;++c,++w)c<l&&s.push(k("deleted",b[c],c)),c<g&&n.push(k("added",d[w],c));a.a.hc(s,n);break;default:return}f=m}}}};var s=a.a.bc("_state");a.m=a.B=function(b,c,d){function e(){if(0<arguments.length){if("function"===typeof f)f.apply(g.sb,arguments);else throw Error("Cannot write a value to a ko.computed unless you specify a 'write' option. If you wish to read the current value, don't pass any parameters.");
|
||||
return this}a.l.sc(e);(g.V||g.t&&e.Sa())&&e.U();return g.M}"object"===typeof b?d=b:(d=d||{},b&&(d.read=b));if("function"!=typeof d.read)throw Error("Pass a function that returns the value of the ko.computed");var f=d.write,g={M:n,da:!0,V:!0,Ta:!1,Hb:!1,T:!1,Ya:!1,t:!1,od:d.read,sb:c||d.owner,i:d.disposeWhenNodeIsRemoved||d.i||null,ya:d.disposeWhen||d.ya,pb:null,s:{},L:0,fc:null};e[s]=g;e.$c="function"===typeof f;a.a.la||a.a.extend(e,a.K.fn);a.K.fn.ub(e);a.a.ab(e,z);d.pure?(g.Ya=!0,g.t=!0,a.a.extend(e,
|
||||
Y)):d.deferEvaluation&&a.a.extend(e,Z);a.options.deferUpdates&&a.Aa.deferred(e,!0);g.i&&(g.Hb=!0,g.i.nodeType||(g.i=null));g.t||d.deferEvaluation||e.U();g.i&&e.ca()&&a.a.G.qa(g.i,g.pb=function(){e.k()});return e};var z={equalityComparer:J,Ca:function(){return this[s].L},Sb:function(a,c,d){if(this[s].Ya&&c===this)throw Error("A 'pure' computed must not be called recursively");this[s].s[a]=d;d.Ia=this[s].L++;d.pa=c.Pa()},Sa:function(){var a,c,d=this[s].s;for(a in d)if(d.hasOwnProperty(a)&&(c=d[a],this.oa&&
|
||||
c.$.Ha||c.$.Zc(c.pa)))return!0},gd:function(){this.oa&&!this[s].Ta&&this.oa(!1)},ca:function(){var a=this[s];return a.V||0<a.L},qd:function(){this.Ha?this[s].V&&(this[s].da=!0):this.ec()},yc:function(a){if(a.gb&&!this[s].i){var c=a.Y(this.gd,this,"dirty"),d=a.Y(this.qd,this);return{$:a,k:function(){c.k();d.k()}}}return a.Y(this.ec,this)},ec:function(){var b=this,c=b.throttleEvaluation;c&&0<=c?(clearTimeout(this[s].fc),this[s].fc=a.a.setTimeout(function(){b.U(!0)},c)):b.oa?b.oa(!0):b.U(!0)},U:function(b){var c=
|
||||
this[s],d=c.ya,e=!1;if(!c.Ta&&!c.T){if(c.i&&!a.a.qb(c.i)||d&&d()){if(!c.Hb){this.k();return}}else c.Hb=!1;c.Ta=!0;try{e=this.Vc(b)}finally{c.Ta=!1}c.L||this.k();return e}},Vc:function(b){var c=this[s],d=!1,e=c.Ya?n:!c.L,f={Mc:this,Oa:c.s,ob:c.L};a.l.Xb({Lc:f,jb:W,m:this,Va:e});c.s={};c.L=0;f=this.Uc(c,f);this.Ua(c.M,f)&&(c.t||this.notifySubscribers(c.M,"beforeChange"),c.M=f,c.t?this.Kb():b&&this.notifySubscribers(c.M),d=!0);e&&this.notifySubscribers(c.M,"awake");return d},Uc:function(b,c){try{var d=
|
||||
b.od;return b.sb?d.call(b.sb):d()}finally{a.l.end(),c.ob&&!b.t&&a.a.D(c.Oa,V),b.da=b.V=!1}},p:function(a){var c=this[s];(c.V&&(a||!c.L)||c.t&&this.Sa())&&this.U();return c.M},Wa:function(b){a.K.fn.Wa.call(this,b);this.Mb=function(){this[s].da?this.U():this[s].V=!1;return this[s].M};this.oa=function(a){this.Ob(this[s].M);this[s].V=!0;a&&(this[s].da=!0);this.Pb(this)}},k:function(){var b=this[s];!b.t&&b.s&&a.a.D(b.s,function(a,b){b.k&&b.k()});b.i&&b.pb&&a.a.G.tc(b.i,b.pb);b.s=null;b.L=0;b.T=!0;b.da=
|
||||
!1;b.V=!1;b.t=!1;b.i=null}},Y={ua:function(b){var c=this,d=c[s];if(!d.T&&d.t&&"change"==b){d.t=!1;if(d.da||c.Sa())d.s=null,d.L=0,c.U()&&c.Kb();else{var e=[];a.a.D(d.s,function(a,b){e[b.Ia]=a});a.a.r(e,function(a,b){var e=d.s[a],l=c.yc(e.$);l.Ia=b;l.pa=e.pa;d.s[a]=l})}d.T||c.notifySubscribers(d.M,"awake")}},Ka:function(b){var c=this[s];c.T||"change"!=b||this.Ra("change")||(a.a.D(c.s,function(a,b){b.k&&(c.s[a]={$:b.$,Ia:b.Ia,pa:b.pa},b.k())}),c.t=!0,this.notifySubscribers(n,"asleep"))},Pa:function(){var b=
|
||||
this[s];b.t&&(b.da||this.Sa())&&this.U();return a.K.fn.Pa.call(this)}},Z={ua:function(a){"change"!=a&&"beforeChange"!=a||this.p()}};a.a.la&&a.a.$a(z,a.K.fn);var P=a.O.md;a.m[P]=a.O;z[P]=a.m;a.bd=function(b){return a.Qa(b,a.m)};a.cd=function(b){return a.Qa(b,a.m)&&b[s]&&b[s].Ya};a.b("computed",a.m);a.b("dependentObservable",a.m);a.b("isComputed",a.bd);a.b("isPureComputed",a.cd);a.b("computed.fn",z);a.H(z,"peek",z.p);a.H(z,"dispose",z.k);a.H(z,"isActive",z.ca);a.H(z,"getDependenciesCount",z.Ca);a.rc=
|
||||
function(b,c){if("function"===typeof b)return a.m(b,c,{pure:!0});b=a.a.extend({},b);b.pure=!0;return a.m(b,c)};a.b("pureComputed",a.rc);(function(){function b(a,f,g){g=g||new d;a=f(a);if("object"!=typeof a||null===a||a===n||a instanceof RegExp||a instanceof Date||a instanceof String||a instanceof Number||a instanceof Boolean)return a;var h=a instanceof Array?[]:{};g.save(a,h);c(a,function(c){var d=f(a[c]);switch(typeof d){case "boolean":case "number":case "string":case "function":h[c]=d;break;case "object":case "undefined":var k=
|
||||
g.get(d);h[c]=k!==n?k:b(d,f,g)}});return h}function c(a,b){if(a instanceof Array){for(var c=0;c<a.length;c++)b(c);"function"==typeof a.toJSON&&b("toJSON")}else for(c in a)b(c)}function d(){this.keys=[];this.Lb=[]}a.Ac=function(c){if(0==arguments.length)throw Error("When calling ko.toJS, pass the object you want to convert.");return b(c,function(b){for(var c=0;a.I(b)&&10>c;c++)b=b();return b})};a.toJSON=function(b,c,d){b=a.Ac(b);return a.a.Gb(b,c,d)};d.prototype={save:function(b,c){var d=a.a.o(this.keys,
|
||||
b);0<=d?this.Lb[d]=c:(this.keys.push(b),this.Lb.push(c))},get:function(b){b=a.a.o(this.keys,b);return 0<=b?this.Lb[b]:n}}})();a.b("toJS",a.Ac);a.b("toJSON",a.toJSON);(function(){a.j={u:function(b){switch(a.a.A(b)){case "option":return!0===b.__ko__hasDomDataOptionValue__?a.a.e.get(b,a.d.options.zb):7>=a.a.C?b.getAttributeNode("value")&&b.getAttributeNode("value").specified?b.value:b.text:b.value;case "select":return 0<=b.selectedIndex?a.j.u(b.options[b.selectedIndex]):n;default:return b.value}},ja:function(b,
|
||||
c,d){switch(a.a.A(b)){case "option":switch(typeof c){case "string":a.a.e.set(b,a.d.options.zb,n);"__ko__hasDomDataOptionValue__"in b&&delete b.__ko__hasDomDataOptionValue__;b.value=c;break;default:a.a.e.set(b,a.d.options.zb,c),b.__ko__hasDomDataOptionValue__=!0,b.value="number"===typeof c?c:""}break;case "select":if(""===c||null===c)c=n;for(var e=-1,f=0,g=b.options.length,h;f<g;++f)if(h=a.j.u(b.options[f]),h==c||""==h&&c===n){e=f;break}if(d||0<=e||c===n&&1<b.size)b.selectedIndex=e;break;default:if(null===
|
||||
c||c===n)c="";b.value=c}}}})();a.b("selectExtensions",a.j);a.b("selectExtensions.readValue",a.j.u);a.b("selectExtensions.writeValue",a.j.ja);a.h=function(){function b(b){b=a.a.cb(b);123===b.charCodeAt(0)&&(b=b.slice(1,-1));var c=[],d=b.match(e),r,h=[],p=0;if(d){d.push(",");for(var A=0,y;y=d[A];++A){var v=y.charCodeAt(0);if(44===v){if(0>=p){c.push(r&&h.length?{key:r,value:h.join("")}:{unknown:r||h.join("")});r=p=0;h=[];continue}}else if(58===v){if(!p&&!r&&1===h.length){r=h.pop();continue}}else 47===
|
||||
v&&A&&1<y.length?(v=d[A-1].match(f))&&!g[v[0]]&&(b=b.substr(b.indexOf(y)+1),d=b.match(e),d.push(","),A=-1,y="/"):40===v||123===v||91===v?++p:41===v||125===v||93===v?--p:r||h.length||34!==v&&39!==v||(y=y.slice(1,-1));h.push(y)}}return c}var c=["true","false","null","undefined"],d=/^(?:[$_a-z][$\w]*|(.+)(\.\s*[$_a-z][$\w]*|\[.+\]))$/i,e=RegExp("\"(?:[^\"\\\\]|\\\\.)*\"|'(?:[^'\\\\]|\\\\.)*'|/(?:[^/\\\\]|\\\\.)*/w*|[^\\s:,/][^,\"'{}()/:[\\]]*[^\\s,\"'{}()/:[\\]]|[^\\s]","g"),f=/[\])"'A-Za-z0-9_$]+$/,
|
||||
g={"in":1,"return":1,"typeof":1},h={};return{va:[],ga:h,Ab:b,Xa:function(e,m){function k(b,e){var m;if(!A){var l=a.getBindingHandler(b);if(l&&l.preprocess&&!(e=l.preprocess(e,b,k)))return;if(l=h[b])m=e,0<=a.a.o(c,m)?m=!1:(l=m.match(d),m=null===l?!1:l[1]?"Object("+l[1]+")"+l[2]:m),l=m;l&&g.push("'"+b+"':function(_z){"+m+"=_z}")}p&&(e="function(){return "+e+" }");f.push("'"+b+"':"+e)}m=m||{};var f=[],g=[],p=m.valueAccessors,A=m.bindingParams,y="string"===typeof e?b(e):e;a.a.r(y,function(a){k(a.key||
|
||||
a.unknown,a.value)});g.length&&k("_ko_property_writers","{"+g.join(",")+" }");return f.join(",")},fd:function(a,b){for(var c=0;c<a.length;c++)if(a[c].key==b)return!0;return!1},Ga:function(b,c,d,e,f){if(b&&a.I(b))!a.Da(b)||f&&b.p()===e||b(e);else if((b=c.get("_ko_property_writers"))&&b[d])b[d](e)}}}();a.b("expressionRewriting",a.h);a.b("expressionRewriting.bindingRewriteValidators",a.h.va);a.b("expressionRewriting.parseObjectLiteral",a.h.Ab);a.b("expressionRewriting.preProcessBindings",a.h.Xa);a.b("expressionRewriting._twoWayBindings",
|
||||
a.h.ga);a.b("jsonExpressionRewriting",a.h);a.b("jsonExpressionRewriting.insertPropertyAccessorsIntoJson",a.h.Xa);(function(){function b(a){return 8==a.nodeType&&g.test(f?a.text:a.nodeValue)}function c(a){return 8==a.nodeType&&h.test(f?a.text:a.nodeValue)}function d(a,d){for(var e=a,f=1,l=[];e=e.nextSibling;){if(c(e)&&(f--,0===f))return l;l.push(e);b(e)&&f++}if(!d)throw Error("Cannot find closing comment tag to match: "+a.nodeValue);return null}function e(a,b){var c=d(a,b);return c?0<c.length?c[c.length-
|
||||
1].nextSibling:a.nextSibling:null}var f=t&&"\x3c!--test--\x3e"===t.createComment("test").text,g=f?/^\x3c!--\s*ko(?:\s+([\s\S]+))?\s*--\x3e$/:/^\s*ko(?:\s+([\s\S]+))?\s*$/,h=f?/^\x3c!--\s*\/ko\s*--\x3e$/:/^\s*\/ko\s*$/,l={ul:!0,ol:!0};a.f={aa:{},childNodes:function(a){return b(a)?d(a):a.childNodes},za:function(c){if(b(c)){c=a.f.childNodes(c);for(var d=0,e=c.length;d<e;d++)a.removeNode(c[d])}else a.a.rb(c)},fa:function(c,d){if(b(c)){a.f.za(c);for(var e=c.nextSibling,f=0,l=d.length;f<l;f++)e.parentNode.insertBefore(d[f],
|
||||
e)}else a.a.fa(c,d)},qc:function(a,c){b(a)?a.parentNode.insertBefore(c,a.nextSibling):a.firstChild?a.insertBefore(c,a.firstChild):a.appendChild(c)},kc:function(c,d,e){e?b(c)?c.parentNode.insertBefore(d,e.nextSibling):e.nextSibling?c.insertBefore(d,e.nextSibling):c.appendChild(d):a.f.qc(c,d)},firstChild:function(a){return b(a)?!a.nextSibling||c(a.nextSibling)?null:a.nextSibling:a.firstChild},nextSibling:function(a){b(a)&&(a=e(a));return a.nextSibling&&c(a.nextSibling)?null:a.nextSibling},Yc:b,vd:function(a){return(a=
|
||||
(f?a.text:a.nodeValue).match(g))?a[1]:null},oc:function(d){if(l[a.a.A(d)]){var k=d.firstChild;if(k){do if(1===k.nodeType){var f;f=k.firstChild;var g=null;if(f){do if(g)g.push(f);else if(b(f)){var h=e(f,!0);h?f=h:g=[f]}else c(f)&&(g=[f]);while(f=f.nextSibling)}if(f=g)for(g=k.nextSibling,h=0;h<f.length;h++)g?d.insertBefore(f[h],g):d.appendChild(f[h])}while(k=k.nextSibling)}}}}})();a.b("virtualElements",a.f);a.b("virtualElements.allowedBindings",a.f.aa);a.b("virtualElements.emptyNode",a.f.za);a.b("virtualElements.insertAfter",
|
||||
a.f.kc);a.b("virtualElements.prepend",a.f.qc);a.b("virtualElements.setDomNodeChildren",a.f.fa);(function(){a.S=function(){this.Kc={}};a.a.extend(a.S.prototype,{nodeHasBindings:function(b){switch(b.nodeType){case 1:return null!=b.getAttribute("data-bind")||a.g.getComponentNameForNode(b);case 8:return a.f.Yc(b);default:return!1}},getBindings:function(b,c){var d=this.getBindingsString(b,c),d=d?this.parseBindingsString(d,c,b):null;return a.g.Rb(d,b,c,!1)},getBindingAccessors:function(b,c){var d=this.getBindingsString(b,
|
||||
c),d=d?this.parseBindingsString(d,c,b,{valueAccessors:!0}):null;return a.g.Rb(d,b,c,!0)},getBindingsString:function(b){switch(b.nodeType){case 1:return b.getAttribute("data-bind");case 8:return a.f.vd(b);default:return null}},parseBindingsString:function(b,c,d,e){try{var f=this.Kc,g=b+(e&&e.valueAccessors||""),h;if(!(h=f[g])){var l,m="with($context){with($data||{}){return{"+a.h.Xa(b,e)+"}}}";l=new Function("$context","$element",m);h=f[g]=l}return h(c,d)}catch(k){throw k.message="Unable to parse bindings.\nBindings value: "+
|
||||
b+"\nMessage: "+k.message,k;}}});a.S.instance=new a.S})();a.b("bindingProvider",a.S);(function(){function b(a){return function(){return a}}function c(a){return a()}function d(b){return a.a.Ea(a.l.w(b),function(a,c){return function(){return b()[c]}})}function e(c,e,k){return"function"===typeof c?d(c.bind(null,e,k)):a.a.Ea(c,b)}function f(a,b){return d(this.getBindings.bind(this,a,b))}function g(b,c,d){var e,k=a.f.firstChild(c),f=a.S.instance,m=f.preprocessNode;if(m){for(;e=k;)k=a.f.nextSibling(e),
|
||||
m.call(f,e);k=a.f.firstChild(c)}for(;e=k;)k=a.f.nextSibling(e),h(b,e,d)}function h(b,c,d){var e=!0,k=1===c.nodeType;k&&a.f.oc(c);if(k&&d||a.S.instance.nodeHasBindings(c))e=m(c,null,b,d).shouldBindDescendants;e&&!r[a.a.A(c)]&&g(b,c,!k)}function l(b){var c=[],d={},e=[];a.a.D(b,function X(k){if(!d[k]){var f=a.getBindingHandler(k);f&&(f.after&&(e.push(k),a.a.r(f.after,function(c){if(b[c]){if(-1!==a.a.o(e,c))throw Error("Cannot combine the following bindings, because they have a cyclic dependency: "+e.join(", "));
|
||||
X(c)}}),e.length--),c.push({key:k,jc:f}));d[k]=!0}});return c}function m(b,d,e,k){var m=a.a.e.get(b,q);if(!d){if(m)throw Error("You cannot apply bindings multiple times to the same element.");a.a.e.set(b,q,!0)}!m&&k&&a.xc(b,e);var g;if(d&&"function"!==typeof d)g=d;else{var h=a.S.instance,r=h.getBindingAccessors||f,p=a.B(function(){(g=d?d(e,b):r.call(h,b,e))&&e.Q&&e.Q();return g},null,{i:b});g&&p.ca()||(p=null)}var s;if(g){var t=p?function(a){return function(){return c(p()[a])}}:function(a){return g[a]},
|
||||
u=function(){return a.a.Ea(p?p():g,c)};u.get=function(a){return g[a]&&c(t(a))};u.has=function(a){return a in g};k=l(g);a.a.r(k,function(c){var d=c.jc.init,k=c.jc.update,f=c.key;if(8===b.nodeType&&!a.f.aa[f])throw Error("The binding '"+f+"' cannot be used with virtual elements");try{"function"==typeof d&&a.l.w(function(){var a=d(b,t(f),u,e.$data,e);if(a&&a.controlsDescendantBindings){if(s!==n)throw Error("Multiple bindings ("+s+" and "+f+") are trying to control descendant bindings of the same element. You cannot use these bindings together on the same element.");
|
||||
s=f}}),"function"==typeof k&&a.B(function(){k(b,t(f),u,e.$data,e)},null,{i:b})}catch(m){throw m.message='Unable to process binding "'+f+": "+g[f]+'"\nMessage: '+m.message,m;}})}return{shouldBindDescendants:s===n}}function k(b){return b&&b instanceof a.R?b:new a.R(b)}a.d={};var r={script:!0,textarea:!0,template:!0};a.getBindingHandler=function(b){return a.d[b]};a.R=function(b,c,d,e,k){function f(){var k=g?b():b,m=a.a.c(k);c?(c.Q&&c.Q(),a.a.extend(l,c),l.Q=r):(l.$parents=[],l.$root=m,l.ko=a);l.$rawData=
|
||||
k;l.$data=m;d&&(l[d]=m);e&&e(l,c,m);return l.$data}function m(){return h&&!a.a.Tb(h)}var l=this,g="function"==typeof b&&!a.I(b),h,r;k&&k.exportDependencies?f():(r=a.B(f,null,{ya:m,i:!0}),r.ca()&&(l.Q=r,r.equalityComparer=null,h=[],r.Dc=function(b){h.push(b);a.a.G.qa(b,function(b){a.a.Na(h,b);h.length||(r.k(),l.Q=r=n)})}))};a.R.prototype.createChildContext=function(b,c,d,e){return new a.R(b,this,c,function(a,b){a.$parentContext=b;a.$parent=b.$data;a.$parents=(b.$parents||[]).slice(0);a.$parents.unshift(a.$parent);
|
||||
d&&d(a)},e)};a.R.prototype.extend=function(b){return new a.R(this.Q||this.$data,this,null,function(c,d){c.$rawData=d.$rawData;a.a.extend(c,"function"==typeof b?b():b)})};a.R.prototype.ac=function(a,b){return this.createChildContext(a,b,null,{exportDependencies:!0})};var q=a.a.e.J(),p=a.a.e.J();a.xc=function(b,c){if(2==arguments.length)a.a.e.set(b,p,c),c.Q&&c.Q.Dc(b);else return a.a.e.get(b,p)};a.La=function(b,c,d){1===b.nodeType&&a.f.oc(b);return m(b,c,k(d),!0)};a.Ic=function(b,c,d){d=k(d);return a.La(b,
|
||||
e(c,d,b),d)};a.hb=function(a,b){1!==b.nodeType&&8!==b.nodeType||g(k(a),b,!0)};a.Ub=function(a,b){!u&&x.jQuery&&(u=x.jQuery);if(b&&1!==b.nodeType&&8!==b.nodeType)throw Error("ko.applyBindings: first parameter should be your view model; second parameter should be a DOM node");b=b||x.document.body;h(k(a),b,!0)};a.nb=function(b){switch(b.nodeType){case 1:case 8:var c=a.xc(b);if(c)return c;if(b.parentNode)return a.nb(b.parentNode)}return n};a.Oc=function(b){return(b=a.nb(b))?b.$data:n};a.b("bindingHandlers",
|
||||
a.d);a.b("applyBindings",a.Ub);a.b("applyBindingsToDescendants",a.hb);a.b("applyBindingAccessorsToNode",a.La);a.b("applyBindingsToNode",a.Ic);a.b("contextFor",a.nb);a.b("dataFor",a.Oc)})();(function(b){function c(c,e){var m=f.hasOwnProperty(c)?f[c]:b,k;m?m.Y(e):(m=f[c]=new a.K,m.Y(e),d(c,function(b,d){var e=!(!d||!d.synchronous);g[c]={definition:b,dd:e};delete f[c];k||e?m.notifySubscribers(b):a.Z.Za(function(){m.notifySubscribers(b)})}),k=!0)}function d(a,b){e("getConfig",[a],function(c){c?e("loadComponent",
|
||||
[a,c],function(a){b(a,c)}):b(null,null)})}function e(c,d,f,k){k||(k=a.g.loaders.slice(0));var g=k.shift();if(g){var q=g[c];if(q){var p=!1;if(q.apply(g,d.concat(function(a){p?f(null):null!==a?f(a):e(c,d,f,k)}))!==b&&(p=!0,!g.suppressLoaderExceptions))throw Error("Component loaders must supply values by invoking the callback, not by returning values synchronously.");}else e(c,d,f,k)}else f(null)}var f={},g={};a.g={get:function(d,e){var f=g.hasOwnProperty(d)?g[d]:b;f?f.dd?a.l.w(function(){e(f.definition)}):
|
||||
a.Z.Za(function(){e(f.definition)}):c(d,e)},$b:function(a){delete g[a]},Nb:e};a.g.loaders=[];a.b("components",a.g);a.b("components.get",a.g.get);a.b("components.clearCachedDefinition",a.g.$b)})();(function(){function b(b,c,d,e){function g(){0===--y&&e(h)}var h={},y=2,v=d.template;d=d.viewModel;v?f(c,v,function(c){a.g.Nb("loadTemplate",[b,c],function(a){h.template=a;g()})}):g();d?f(c,d,function(c){a.g.Nb("loadViewModel",[b,c],function(a){h[l]=a;g()})}):g()}function c(a,b,d){if("function"===typeof b)d(function(a){return new b(a)});
|
||||
else if("function"===typeof b[l])d(b[l]);else if("instance"in b){var e=b.instance;d(function(){return e})}else"viewModel"in b?c(a,b.viewModel,d):a("Unknown viewModel value: "+b)}function d(b){switch(a.a.A(b)){case "script":return a.a.na(b.text);case "textarea":return a.a.na(b.value);case "template":if(e(b.content))return a.a.wa(b.content.childNodes)}return a.a.wa(b.childNodes)}function e(a){return x.DocumentFragment?a instanceof DocumentFragment:a&&11===a.nodeType}function f(a,b,c){"string"===typeof b.require?
|
||||
O||x.require?(O||x.require)([b.require],c):a("Uses require, but no AMD loader is present"):c(b)}function g(a){return function(b){throw Error("Component '"+a+"': "+b);}}var h={};a.g.register=function(b,c){if(!c)throw Error("Invalid configuration for "+b);if(a.g.wb(b))throw Error("Component "+b+" is already registered");h[b]=c};a.g.wb=function(a){return h.hasOwnProperty(a)};a.g.ud=function(b){delete h[b];a.g.$b(b)};a.g.cc={getConfig:function(a,b){b(h.hasOwnProperty(a)?h[a]:null)},loadComponent:function(a,
|
||||
c,d){var e=g(a);f(e,c,function(c){b(a,e,c,d)})},loadTemplate:function(b,c,f){b=g(b);if("string"===typeof c)f(a.a.na(c));else if(c instanceof Array)f(c);else if(e(c))f(a.a.W(c.childNodes));else if(c.element)if(c=c.element,x.HTMLElement?c instanceof HTMLElement:c&&c.tagName&&1===c.nodeType)f(d(c));else if("string"===typeof c){var l=t.getElementById(c);l?f(d(l)):b("Cannot find element with ID "+c)}else b("Unknown element type: "+c);else b("Unknown template value: "+c)},loadViewModel:function(a,b,d){c(g(a),
|
||||
b,d)}};var l="createViewModel";a.b("components.register",a.g.register);a.b("components.isRegistered",a.g.wb);a.b("components.unregister",a.g.ud);a.b("components.defaultLoader",a.g.cc);a.g.loaders.push(a.g.cc);a.g.Ec=h})();(function(){function b(b,e){var f=b.getAttribute("params");if(f){var f=c.parseBindingsString(f,e,b,{valueAccessors:!0,bindingParams:!0}),f=a.a.Ea(f,function(c){return a.m(c,null,{i:b})}),g=a.a.Ea(f,function(c){var e=c.p();return c.ca()?a.m({read:function(){return a.a.c(c())},write:a.Da(e)&&
|
||||
function(a){c()(a)},i:b}):e});g.hasOwnProperty("$raw")||(g.$raw=f);return g}return{$raw:{}}}a.g.getComponentNameForNode=function(b){var c=a.a.A(b);if(a.g.wb(c)&&(-1!=c.indexOf("-")||"[object HTMLUnknownElement]"==""+b||8>=a.a.C&&b.tagName===c))return c};a.g.Rb=function(c,e,f,g){if(1===e.nodeType){var h=a.g.getComponentNameForNode(e);if(h){c=c||{};if(c.component)throw Error('Cannot use the "component" binding on a custom element matching a component');var l={name:h,params:b(e,f)};c.component=g?function(){return l}:
|
||||
l}}return c};var c=new a.S;9>a.a.C&&(a.g.register=function(a){return function(b){t.createElement(b);return a.apply(this,arguments)}}(a.g.register),t.createDocumentFragment=function(b){return function(){var c=b(),f=a.g.Ec,g;for(g in f)f.hasOwnProperty(g)&&c.createElement(g);return c}}(t.createDocumentFragment))})();(function(b){function c(b,c,d){c=c.template;if(!c)throw Error("Component '"+b+"' has no template");b=a.a.wa(c);a.f.fa(d,b)}function d(a,b,c,d){var e=a.createViewModel;return e?e.call(a,
|
||||
d,{element:b,templateNodes:c}):d}var e=0;a.d.component={init:function(f,g,h,l,m){function k(){var a=r&&r.dispose;"function"===typeof a&&a.call(r);q=r=null}var r,q,p=a.a.W(a.f.childNodes(f));a.a.G.qa(f,k);a.m(function(){var l=a.a.c(g()),h,v;"string"===typeof l?h=l:(h=a.a.c(l.name),v=a.a.c(l.params));if(!h)throw Error("No component name specified");var n=q=++e;a.g.get(h,function(e){if(q===n){k();if(!e)throw Error("Unknown component '"+h+"'");c(h,e,f);var l=d(e,f,p,v);e=m.createChildContext(l,b,function(a){a.$component=
|
||||
l;a.$componentTemplateNodes=p});r=l;a.hb(e,f)}})},null,{i:f});return{controlsDescendantBindings:!0}}};a.f.aa.component=!0})();var Q={"class":"className","for":"htmlFor"};a.d.attr={update:function(b,c){var d=a.a.c(c())||{};a.a.D(d,function(c,d){d=a.a.c(d);var g=!1===d||null===d||d===n;g&&b.removeAttribute(c);8>=a.a.C&&c in Q?(c=Q[c],g?b.removeAttribute(c):b[c]=d):g||b.setAttribute(c,d.toString());"name"===c&&a.a.vc(b,g?"":d.toString())})}};(function(){a.d.checked={after:["value","attr"],init:function(b,
|
||||
c,d){function e(){var e=b.checked,f=p?g():e;if(!a.xa.Va()&&(!l||e)){var h=a.l.w(c);if(k){var m=r?h.p():h;q!==f?(e&&(a.a.ra(m,f,!0),a.a.ra(m,q,!1)),q=f):a.a.ra(m,f,e);r&&a.Da(h)&&h(m)}else a.h.Ga(h,d,"checked",f,!0)}}function f(){var d=a.a.c(c());b.checked=k?0<=a.a.o(d,g()):h?d:g()===d}var g=a.rc(function(){return d.has("checkedValue")?a.a.c(d.get("checkedValue")):d.has("value")?a.a.c(d.get("value")):b.value}),h="checkbox"==b.type,l="radio"==b.type;if(h||l){var m=c(),k=h&&a.a.c(m)instanceof Array,
|
||||
r=!(k&&m.push&&m.splice),q=k?g():n,p=l||k;l&&!b.name&&a.d.uniqueName.init(b,function(){return!0});a.m(e,null,{i:b});a.a.q(b,"click",e);a.m(f,null,{i:b});m=n}}};a.h.ga.checked=!0;a.d.checkedValue={update:function(b,c){b.value=a.a.c(c())}}})();a.d.css={update:function(b,c){var d=a.a.c(c());null!==d&&"object"==typeof d?a.a.D(d,function(c,d){d=a.a.c(d);a.a.fb(b,c,d)}):(d=a.a.cb(String(d||"")),a.a.fb(b,b.__ko__cssValue,!1),b.__ko__cssValue=d,a.a.fb(b,d,!0))}};a.d.enable={update:function(b,c){var d=a.a.c(c());
|
||||
d&&b.disabled?b.removeAttribute("disabled"):d||b.disabled||(b.disabled=!0)}};a.d.disable={update:function(b,c){a.d.enable.update(b,function(){return!a.a.c(c())})}};a.d.event={init:function(b,c,d,e,f){var g=c()||{};a.a.D(g,function(g){"string"==typeof g&&a.a.q(b,g,function(b){var m,k=c()[g];if(k){try{var r=a.a.W(arguments);e=f.$data;r.unshift(e);m=k.apply(e,r)}finally{!0!==m&&(b.preventDefault?b.preventDefault():b.returnValue=!1)}!1===d.get(g+"Bubble")&&(b.cancelBubble=!0,b.stopPropagation&&b.stopPropagation())}})})}};
|
||||
a.d.foreach={mc:function(b){return function(){var c=b(),d=a.a.Bb(c);if(!d||"number"==typeof d.length)return{foreach:c,templateEngine:a.X.vb};a.a.c(c);return{foreach:d.data,as:d.as,includeDestroyed:d.includeDestroyed,afterAdd:d.afterAdd,beforeRemove:d.beforeRemove,afterRender:d.afterRender,beforeMove:d.beforeMove,afterMove:d.afterMove,templateEngine:a.X.vb}}},init:function(b,c){return a.d.template.init(b,a.d.foreach.mc(c))},update:function(b,c,d,e,f){return a.d.template.update(b,a.d.foreach.mc(c),
|
||||
d,e,f)}};a.h.va.foreach=!1;a.f.aa.foreach=!0;a.d.hasfocus={init:function(b,c,d){function e(e){b.__ko_hasfocusUpdating=!0;var f=b.ownerDocument;if("activeElement"in f){var g;try{g=f.activeElement}catch(k){g=f.body}e=g===b}f=c();a.h.Ga(f,d,"hasfocus",e,!0);b.__ko_hasfocusLastValue=e;b.__ko_hasfocusUpdating=!1}var f=e.bind(null,!0),g=e.bind(null,!1);a.a.q(b,"focus",f);a.a.q(b,"focusin",f);a.a.q(b,"blur",g);a.a.q(b,"focusout",g)},update:function(b,c){var d=!!a.a.c(c());b.__ko_hasfocusUpdating||b.__ko_hasfocusLastValue===
|
||||
d||(d?b.focus():b.blur(),!d&&b.__ko_hasfocusLastValue&&b.ownerDocument.body.focus(),a.l.w(a.a.Fa,null,[b,d?"focusin":"focusout"]))}};a.h.ga.hasfocus=!0;a.d.hasFocus=a.d.hasfocus;a.h.ga.hasFocus=!0;a.d.html={init:function(){return{controlsDescendantBindings:!0}},update:function(b,c){a.a.Eb(b,c())}};K("if");K("ifnot",!1,!0);K("with",!0,!1,function(a,c){return a.ac(c)});var L={};a.d.options={init:function(b){if("select"!==a.a.A(b))throw Error("options binding applies only to SELECT elements");for(;0<
|
||||
b.length;)b.remove(0);return{controlsDescendantBindings:!0}},update:function(b,c,d){function e(){return a.a.Ma(b.options,function(a){return a.selected})}function f(a,b,c){var d=typeof b;return"function"==d?b(a):"string"==d?a[b]:c}function g(c,e){if(A&&k)a.j.ja(b,a.a.c(d.get("value")),!0);else if(p.length){var f=0<=a.a.o(p,a.j.u(e[0]));a.a.wc(e[0],f);A&&!f&&a.l.w(a.a.Fa,null,[b,"change"])}}var h=b.multiple,l=0!=b.length&&h?b.scrollTop:null,m=a.a.c(c()),k=d.get("valueAllowUnset")&&d.has("value"),r=
|
||||
d.get("optionsIncludeDestroyed");c={};var q,p=[];k||(h?p=a.a.ib(e(),a.j.u):0<=b.selectedIndex&&p.push(a.j.u(b.options[b.selectedIndex])));m&&("undefined"==typeof m.length&&(m=[m]),q=a.a.Ma(m,function(b){return r||b===n||null===b||!a.a.c(b._destroy)}),d.has("optionsCaption")&&(m=a.a.c(d.get("optionsCaption")),null!==m&&m!==n&&q.unshift(L)));var A=!1;c.beforeRemove=function(a){b.removeChild(a)};m=g;d.has("optionsAfterRender")&&"function"==typeof d.get("optionsAfterRender")&&(m=function(b,c){g(0,c);
|
||||
a.l.w(d.get("optionsAfterRender"),null,[c[0],b!==L?b:n])});a.a.Db(b,q,function(c,e,g){g.length&&(p=!k&&g[0].selected?[a.j.u(g[0])]:[],A=!0);e=b.ownerDocument.createElement("option");c===L?(a.a.bb(e,d.get("optionsCaption")),a.j.ja(e,n)):(g=f(c,d.get("optionsValue"),c),a.j.ja(e,a.a.c(g)),c=f(c,d.get("optionsText"),g),a.a.bb(e,c));return[e]},c,m);a.l.w(function(){k?a.j.ja(b,a.a.c(d.get("value")),!0):(h?p.length&&e().length<p.length:p.length&&0<=b.selectedIndex?a.j.u(b.options[b.selectedIndex])!==p[0]:
|
||||
p.length||0<=b.selectedIndex)&&a.a.Fa(b,"change")});a.a.Sc(b);l&&20<Math.abs(l-b.scrollTop)&&(b.scrollTop=l)}};a.d.options.zb=a.a.e.J();a.d.selectedOptions={after:["options","foreach"],init:function(b,c,d){a.a.q(b,"change",function(){var e=c(),f=[];a.a.r(b.getElementsByTagName("option"),function(b){b.selected&&f.push(a.j.u(b))});a.h.Ga(e,d,"selectedOptions",f)})},update:function(b,c){if("select"!=a.a.A(b))throw Error("values binding applies only to SELECT elements");var d=a.a.c(c()),e=b.scrollTop;
|
||||
d&&"number"==typeof d.length&&a.a.r(b.getElementsByTagName("option"),function(b){var c=0<=a.a.o(d,a.j.u(b));b.selected!=c&&a.a.wc(b,c)});b.scrollTop=e}};a.h.ga.selectedOptions=!0;a.d.style={update:function(b,c){var d=a.a.c(c()||{});a.a.D(d,function(c,d){d=a.a.c(d);if(null===d||d===n||!1===d)d="";b.style[c]=d})}};a.d.submit={init:function(b,c,d,e,f){if("function"!=typeof c())throw Error("The value for a submit binding must be a function");a.a.q(b,"submit",function(a){var d,e=c();try{d=e.call(f.$data,
|
||||
b)}finally{!0!==d&&(a.preventDefault?a.preventDefault():a.returnValue=!1)}})}};a.d.text={init:function(){return{controlsDescendantBindings:!0}},update:function(b,c){a.a.bb(b,c())}};a.f.aa.text=!0;(function(){if(x&&x.navigator)var b=function(a){if(a)return parseFloat(a[1])},c=x.opera&&x.opera.version&&parseInt(x.opera.version()),d=x.navigator.userAgent,e=b(d.match(/^(?:(?!chrome).)*version\/([^ ]*) safari/i)),f=b(d.match(/Firefox\/([^ ]*)/));if(10>a.a.C)var g=a.a.e.J(),h=a.a.e.J(),l=function(b){var c=
|
||||
this.activeElement;(c=c&&a.a.e.get(c,h))&&c(b)},m=function(b,c){var d=b.ownerDocument;a.a.e.get(d,g)||(a.a.e.set(d,g,!0),a.a.q(d,"selectionchange",l));a.a.e.set(b,h,c)};a.d.textInput={init:function(b,d,g){function l(c,d){a.a.q(b,c,d)}function h(){var c=a.a.c(d());if(null===c||c===n)c="";u!==n&&c===u?a.a.setTimeout(h,4):b.value!==c&&(s=c,b.value=c)}function y(){t||(u=b.value,t=a.a.setTimeout(v,4))}function v(){clearTimeout(t);u=t=n;var c=b.value;s!==c&&(s=c,a.h.Ga(d(),g,"textInput",c))}var s=b.value,
|
||||
t,u,x=9==a.a.C?y:v;10>a.a.C?(l("propertychange",function(a){"value"===a.propertyName&&x(a)}),8==a.a.C&&(l("keyup",v),l("keydown",v)),8<=a.a.C&&(m(b,x),l("dragend",y))):(l("input",v),5>e&&"textarea"===a.a.A(b)?(l("keydown",y),l("paste",y),l("cut",y)):11>c?l("keydown",y):4>f&&(l("DOMAutoComplete",v),l("dragdrop",v),l("drop",v)));l("change",v);a.m(h,null,{i:b})}};a.h.ga.textInput=!0;a.d.textinput={preprocess:function(a,b,c){c("textInput",a)}}})();a.d.uniqueName={init:function(b,c){if(c()){var d="ko_unique_"+
|
||||
++a.d.uniqueName.Nc;a.a.vc(b,d)}}};a.d.uniqueName.Nc=0;a.d.value={after:["options","foreach"],init:function(b,c,d){if("input"!=b.tagName.toLowerCase()||"checkbox"!=b.type&&"radio"!=b.type){var e=["change"],f=d.get("valueUpdate"),g=!1,h=null;f&&("string"==typeof f&&(f=[f]),a.a.ta(e,f),e=a.a.Wb(e));var l=function(){h=null;g=!1;var e=c(),f=a.j.u(b);a.h.Ga(e,d,"value",f)};!a.a.C||"input"!=b.tagName.toLowerCase()||"text"!=b.type||"off"==b.autocomplete||b.form&&"off"==b.form.autocomplete||-1!=a.a.o(e,"propertychange")||
|
||||
(a.a.q(b,"propertychange",function(){g=!0}),a.a.q(b,"focus",function(){g=!1}),a.a.q(b,"blur",function(){g&&l()}));a.a.r(e,function(c){var d=l;a.a.sd(c,"after")&&(d=function(){h=a.j.u(b);a.a.setTimeout(l,0)},c=c.substring(5));a.a.q(b,c,d)});var m=function(){var e=a.a.c(c()),f=a.j.u(b);if(null!==h&&e===h)a.a.setTimeout(m,0);else if(e!==f)if("select"===a.a.A(b)){var g=d.get("valueAllowUnset"),f=function(){a.j.ja(b,e,g)};f();g||e===a.j.u(b)?a.a.setTimeout(f,0):a.l.w(a.a.Fa,null,[b,"change"])}else a.j.ja(b,
|
||||
e)};a.m(m,null,{i:b})}else a.La(b,{checkedValue:c})},update:function(){}};a.h.ga.value=!0;a.d.visible={update:function(b,c){var d=a.a.c(c()),e="none"!=b.style.display;d&&!e?b.style.display="":!d&&e&&(b.style.display="none")}};(function(b){a.d[b]={init:function(c,d,e,f,g){return a.d.event.init.call(this,c,function(){var a={};a[b]=d();return a},e,f,g)}}})("click");a.P=function(){};a.P.prototype.renderTemplateSource=function(){throw Error("Override renderTemplateSource");};a.P.prototype.createJavaScriptEvaluatorBlock=
|
||||
function(){throw Error("Override createJavaScriptEvaluatorBlock");};a.P.prototype.makeTemplateSource=function(b,c){if("string"==typeof b){c=c||t;var d=c.getElementById(b);if(!d)throw Error("Cannot find template with ID "+b);return new a.v.n(d)}if(1==b.nodeType||8==b.nodeType)return new a.v.sa(b);throw Error("Unknown template type: "+b);};a.P.prototype.renderTemplate=function(a,c,d,e){a=this.makeTemplateSource(a,e);return this.renderTemplateSource(a,c,d,e)};a.P.prototype.isTemplateRewritten=function(a,
|
||||
c){return!1===this.allowTemplateRewriting?!0:this.makeTemplateSource(a,c).data("isRewritten")};a.P.prototype.rewriteTemplate=function(a,c,d){a=this.makeTemplateSource(a,d);c=c(a.text());a.text(c);a.data("isRewritten",!0)};a.b("templateEngine",a.P);a.Ib=function(){function b(b,c,d,h){b=a.h.Ab(b);for(var l=a.h.va,m=0;m<b.length;m++){var k=b[m].key;if(l.hasOwnProperty(k)){var r=l[k];if("function"===typeof r){if(k=r(b[m].value))throw Error(k);}else if(!r)throw Error("This template engine does not support the '"+
|
||||
k+"' binding within its templates");}}d="ko.__tr_ambtns(function($context,$element){return(function(){return{ "+a.h.Xa(b,{valueAccessors:!0})+" } })()},'"+d.toLowerCase()+"')";return h.createJavaScriptEvaluatorBlock(d)+c}var c=/(<([a-z]+\d*)(?:\s+(?!data-bind\s*=\s*)[a-z0-9\-]+(?:=(?:\"[^\"]*\"|\'[^\']*\'|[^>]*))?)*\s+)data-bind\s*=\s*(["'])([\s\S]*?)\3/gi,d=/\x3c!--\s*ko\b\s*([\s\S]*?)\s*--\x3e/g;return{Tc:function(b,c,d){c.isTemplateRewritten(b,d)||c.rewriteTemplate(b,function(b){return a.Ib.jd(b,
|
||||
c)},d)},jd:function(a,f){return a.replace(c,function(a,c,d,e,k){return b(k,c,d,f)}).replace(d,function(a,c){return b(c,"\x3c!-- ko --\x3e","#comment",f)})},Jc:function(b,c){return a.N.yb(function(d,h){var l=d.nextSibling;l&&l.nodeName.toLowerCase()===c&&a.La(l,b,h)})}}}();a.b("__tr_ambtns",a.Ib.Jc);(function(){a.v={};a.v.n=function(b){if(this.n=b){var c=a.a.A(b);this.eb="script"===c?1:"textarea"===c?2:"template"==c&&b.content&&11===b.content.nodeType?3:4}};a.v.n.prototype.text=function(){var b=1===
|
||||
this.eb?"text":2===this.eb?"value":"innerHTML";if(0==arguments.length)return this.n[b];var c=arguments[0];"innerHTML"===b?a.a.Eb(this.n,c):this.n[b]=c};var b=a.a.e.J()+"_";a.v.n.prototype.data=function(c){if(1===arguments.length)return a.a.e.get(this.n,b+c);a.a.e.set(this.n,b+c,arguments[1])};var c=a.a.e.J();a.v.n.prototype.nodes=function(){var b=this.n;if(0==arguments.length)return(a.a.e.get(b,c)||{}).mb||(3===this.eb?b.content:4===this.eb?b:n);a.a.e.set(b,c,{mb:arguments[0]})};a.v.sa=function(a){this.n=
|
||||
a};a.v.sa.prototype=new a.v.n;a.v.sa.prototype.text=function(){if(0==arguments.length){var b=a.a.e.get(this.n,c)||{};b.Jb===n&&b.mb&&(b.Jb=b.mb.innerHTML);return b.Jb}a.a.e.set(this.n,c,{Jb:arguments[0]})};a.b("templateSources",a.v);a.b("templateSources.domElement",a.v.n);a.b("templateSources.anonymousTemplate",a.v.sa)})();(function(){function b(b,c,d){var e;for(c=a.f.nextSibling(c);b&&(e=b)!==c;)b=a.f.nextSibling(e),d(e,b)}function c(c,d){if(c.length){var e=c[0],f=c[c.length-1],g=e.parentNode,h=
|
||||
a.S.instance,n=h.preprocessNode;if(n){b(e,f,function(a,b){var c=a.previousSibling,d=n.call(h,a);d&&(a===e&&(e=d[0]||b),a===f&&(f=d[d.length-1]||c))});c.length=0;if(!e)return;e===f?c.push(e):(c.push(e,f),a.a.Ba(c,g))}b(e,f,function(b){1!==b.nodeType&&8!==b.nodeType||a.Ub(d,b)});b(e,f,function(b){1!==b.nodeType&&8!==b.nodeType||a.N.Cc(b,[d])});a.a.Ba(c,g)}}function d(a){return a.nodeType?a:0<a.length?a[0]:null}function e(b,e,f,h,q){q=q||{};var p=(b&&d(b)||f||{}).ownerDocument,n=q.templateEngine||g;
|
||||
a.Ib.Tc(f,n,p);f=n.renderTemplate(f,h,q,p);if("number"!=typeof f.length||0<f.length&&"number"!=typeof f[0].nodeType)throw Error("Template engine must return an array of DOM nodes");p=!1;switch(e){case "replaceChildren":a.f.fa(b,f);p=!0;break;case "replaceNode":a.a.uc(b,f);p=!0;break;case "ignoreTargetNode":break;default:throw Error("Unknown renderMode: "+e);}p&&(c(f,h),q.afterRender&&a.l.w(q.afterRender,null,[f,h.$data]));return f}function f(b,c,d){return a.I(b)?b():"function"===typeof b?b(c,d):b}
|
||||
var g;a.Fb=function(b){if(b!=n&&!(b instanceof a.P))throw Error("templateEngine must inherit from ko.templateEngine");g=b};a.Cb=function(b,c,k,h,q){k=k||{};if((k.templateEngine||g)==n)throw Error("Set a template engine before calling renderTemplate");q=q||"replaceChildren";if(h){var p=d(h);return a.B(function(){var g=c&&c instanceof a.R?c:new a.R(c,null,null,null,{exportDependencies:!0}),n=f(b,g.$data,g),g=e(h,q,n,g,k);"replaceNode"==q&&(h=g,p=d(h))},null,{ya:function(){return!p||!a.a.qb(p)},i:p&&
|
||||
"replaceNode"==q?p.parentNode:p})}return a.N.yb(function(d){a.Cb(b,c,k,d,"replaceNode")})};a.pd=function(b,d,g,h,q){function p(a,b){c(b,t);g.afterRender&&g.afterRender(b,a);t=null}function s(a,c){t=q.createChildContext(a,g.as,function(a){a.$index=c});var d=f(b,a,t);return e(null,"ignoreTargetNode",d,t,g)}var t;return a.B(function(){var b=a.a.c(d)||[];"undefined"==typeof b.length&&(b=[b]);b=a.a.Ma(b,function(b){return g.includeDestroyed||b===n||null===b||!a.a.c(b._destroy)});a.l.w(a.a.Db,null,[h,b,
|
||||
s,g,p])},null,{i:h})};var h=a.a.e.J();a.d.template={init:function(b,c){var d=a.a.c(c());if("string"==typeof d||d.name)a.f.za(b);else{if("nodes"in d){if(d=d.nodes||[],a.I(d))throw Error('The "nodes" option must be a plain, non-observable array.');}else d=a.f.childNodes(b);d=a.a.nc(d);(new a.v.sa(b)).nodes(d)}return{controlsDescendantBindings:!0}},update:function(b,c,d,e,f){var g=c();c=a.a.c(g);d=!0;e=null;"string"==typeof c?c={}:(g=c.name,"if"in c&&(d=a.a.c(c["if"])),d&&"ifnot"in c&&(d=!a.a.c(c.ifnot)));
|
||||
"foreach"in c?e=a.pd(g||b,d&&c.foreach||[],c,b,f):d?(f="data"in c?f.ac(c.data,c.as):f,e=a.Cb(g||b,f,c,b)):a.f.za(b);f=e;(c=a.a.e.get(b,h))&&"function"==typeof c.k&&c.k();a.a.e.set(b,h,f&&f.ca()?f:n)}};a.h.va.template=function(b){b=a.h.Ab(b);return 1==b.length&&b[0].unknown||a.h.fd(b,"name")?null:"This template engine does not support anonymous templates nested within its templates"};a.f.aa.template=!0})();a.b("setTemplateEngine",a.Fb);a.b("renderTemplate",a.Cb);a.a.hc=function(a,c,d){if(a.length&&
|
||||
c.length){var e,f,g,h,l;for(e=f=0;(!d||e<d)&&(h=a[f]);++f){for(g=0;l=c[g];++g)if(h.value===l.value){h.moved=l.index;l.moved=h.index;c.splice(g,1);e=g=0;break}e+=g}}};a.a.lb=function(){function b(b,d,e,f,g){var h=Math.min,l=Math.max,m=[],k,n=b.length,q,p=d.length,s=p-n||1,t=n+p+1,v,u,x;for(k=0;k<=n;k++)for(u=v,m.push(v=[]),x=h(p,k+s),q=l(0,k-1);q<=x;q++)v[q]=q?k?b[k-1]===d[q-1]?u[q-1]:h(u[q]||t,v[q-1]||t)+1:q+1:k+1;h=[];l=[];s=[];k=n;for(q=p;k||q;)p=m[k][q]-1,q&&p===m[k][q-1]?l.push(h[h.length]={status:e,
|
||||
value:d[--q],index:q}):k&&p===m[k-1][q]?s.push(h[h.length]={status:f,value:b[--k],index:k}):(--q,--k,g.sparse||h.push({status:"retained",value:d[q]}));a.a.hc(s,l,!g.dontLimitMoves&&10*n);return h.reverse()}return function(a,d,e){e="boolean"===typeof e?{dontLimitMoves:e}:e||{};a=a||[];d=d||[];return a.length<d.length?b(a,d,"added","deleted",e):b(d,a,"deleted","added",e)}}();a.b("utils.compareArrays",a.a.lb);(function(){function b(b,c,d,h,l){var m=[],k=a.B(function(){var k=c(d,l,a.a.Ba(m,b))||[];0<
|
||||
m.length&&(a.a.uc(m,k),h&&a.l.w(h,null,[d,k,l]));m.length=0;a.a.ta(m,k)},null,{i:b,ya:function(){return!a.a.Tb(m)}});return{ea:m,B:k.ca()?k:n}}var c=a.a.e.J(),d=a.a.e.J();a.a.Db=function(e,f,g,h,l){function m(b,c){w=q[c];u!==c&&(D[b]=w);w.tb(u++);a.a.Ba(w.ea,e);t.push(w);z.push(w)}function k(b,c){if(b)for(var d=0,e=c.length;d<e;d++)c[d]&&a.a.r(c[d].ea,function(a){b(a,d,c[d].ka)})}f=f||[];h=h||{};var r=a.a.e.get(e,c)===n,q=a.a.e.get(e,c)||[],p=a.a.ib(q,function(a){return a.ka}),s=a.a.lb(p,f,h.dontLimitMoves),
|
||||
t=[],v=0,u=0,x=[],z=[];f=[];for(var D=[],p=[],w,C=0,B,E;B=s[C];C++)switch(E=B.moved,B.status){case "deleted":E===n&&(w=q[v],w.B&&(w.B.k(),w.B=n),a.a.Ba(w.ea,e).length&&(h.beforeRemove&&(t.push(w),z.push(w),w.ka===d?w=null:f[C]=w),w&&x.push.apply(x,w.ea)));v++;break;case "retained":m(C,v++);break;case "added":E!==n?m(C,E):(w={ka:B.value,tb:a.O(u++)},t.push(w),z.push(w),r||(p[C]=w))}a.a.e.set(e,c,t);k(h.beforeMove,D);a.a.r(x,h.beforeRemove?a.ba:a.removeNode);for(var C=0,r=a.f.firstChild(e),F;w=z[C];C++){w.ea||
|
||||
a.a.extend(w,b(e,g,w.ka,l,w.tb));for(v=0;s=w.ea[v];r=s.nextSibling,F=s,v++)s!==r&&a.f.kc(e,s,F);!w.ad&&l&&(l(w.ka,w.ea,w.tb),w.ad=!0)}k(h.beforeRemove,f);for(C=0;C<f.length;++C)f[C]&&(f[C].ka=d);k(h.afterMove,D);k(h.afterAdd,p)}})();a.b("utils.setDomNodeChildrenFromArrayMapping",a.a.Db);a.X=function(){this.allowTemplateRewriting=!1};a.X.prototype=new a.P;a.X.prototype.renderTemplateSource=function(b,c,d,e){if(c=(9>a.a.C?0:b.nodes)?b.nodes():null)return a.a.W(c.cloneNode(!0).childNodes);b=b.text();
|
||||
return a.a.na(b,e)};a.X.vb=new a.X;a.Fb(a.X.vb);a.b("nativeTemplateEngine",a.X);(function(){a.xb=function(){var a=this.ed=function(){if(!u||!u.tmpl)return 0;try{if(0<=u.tmpl.tag.tmpl.open.toString().indexOf("__"))return 2}catch(a){}return 1}();this.renderTemplateSource=function(b,e,f,g){g=g||t;f=f||{};if(2>a)throw Error("Your version of jQuery.tmpl is too old. Please upgrade to jQuery.tmpl 1.0.0pre or later.");var h=b.data("precompiled");h||(h=b.text()||"",h=u.template(null,"{{ko_with $item.koBindingContext}}"+
|
||||
h+"{{/ko_with}}"),b.data("precompiled",h));b=[e.$data];e=u.extend({koBindingContext:e},f.templateOptions);e=u.tmpl(h,b,e);e.appendTo(g.createElement("div"));u.fragments={};return e};this.createJavaScriptEvaluatorBlock=function(a){return"{{ko_code ((function() { return "+a+" })()) }}"};this.addTemplate=function(a,b){t.write("<script type='text/html' id='"+a+"'>"+b+"\x3c/script>")};0<a&&(u.tmpl.tag.ko_code={open:"__.push($1 || '');"},u.tmpl.tag.ko_with={open:"with($1) {",close:"} "})};a.xb.prototype=
|
||||
new a.P;var b=new a.xb;0<b.ed&&a.Fb(b);a.b("jqueryTmplTemplateEngine",a.xb)})()})})();})();
|
||||
|
||||
+173
@@ -0,0 +1,173 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin', ['exports', 'jquery'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery);
|
||||
global.Plugin = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
exports.pluginFactory = exports.getDefaults = exports.getPlugin = exports.getPluginAPI = exports.Plugin = undefined;
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var plugins = {};
|
||||
var apis = {};
|
||||
|
||||
var Plugin = function () {
|
||||
function Plugin($el) {
|
||||
var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
||||
babelHelpers.classCallCheck(this, Plugin);
|
||||
|
||||
this.name = this.getName();
|
||||
this.$el = $el;
|
||||
this.options = options;
|
||||
this.isRendered = false;
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Plugin, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return 'plugin';
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (_jquery2.default.fn[this.name]) {
|
||||
this.$el[this.name](this.options);
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'initialize',
|
||||
value: function initialize() {
|
||||
if (this.isRendered) {
|
||||
return false;
|
||||
}
|
||||
this.render();
|
||||
this.isRendered = true;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}, {
|
||||
key: 'register',
|
||||
value: function register(name, obj) {
|
||||
if (typeof obj === 'undefined') {
|
||||
return;
|
||||
}
|
||||
|
||||
plugins[name] = obj;
|
||||
|
||||
if (typeof obj.api !== 'undefined') {
|
||||
Plugin.registerApi(name, obj);
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'registerApi',
|
||||
value: function registerApi(name, obj) {
|
||||
var api = obj.api();
|
||||
|
||||
if (typeof api === 'string') {
|
||||
var _api = obj.api().split('|');
|
||||
var event = _api[0] + ('.plugin.' + name);
|
||||
var func = _api[1] || 'render';
|
||||
|
||||
var callback = function callback(e) {
|
||||
var $el = (0, _jquery2.default)(this);
|
||||
var plugin = $el.data('pluginInstance');
|
||||
|
||||
if (!plugin) {
|
||||
plugin = new obj($el, _jquery2.default.extend(true, {}, getDefaults(name), $el.data()));
|
||||
plugin.initialize();
|
||||
$el.data('pluginInstance', plugin);
|
||||
}
|
||||
|
||||
plugin[func](e);
|
||||
};
|
||||
|
||||
apis[name] = function (selector, context) {
|
||||
if (context) {
|
||||
(0, _jquery2.default)(context).off(event);
|
||||
(0, _jquery2.default)(context).on(event, selector, callback);
|
||||
} else {
|
||||
(0, _jquery2.default)(selector).on(event, callback);
|
||||
}
|
||||
};
|
||||
} else if (typeof api === 'function') {
|
||||
apis[name] = api;
|
||||
}
|
||||
}
|
||||
}]);
|
||||
return Plugin;
|
||||
}();
|
||||
|
||||
function getPluginAPI(name) {
|
||||
if (typeof name === 'undefined') {
|
||||
return apis;
|
||||
} else {
|
||||
return apis[name];
|
||||
}
|
||||
}
|
||||
|
||||
function getPlugin(name) {
|
||||
if (typeof plugins[name] !== 'undefined') {
|
||||
return plugins[name];
|
||||
} else {
|
||||
console.warn('Plugin:' + name + ' has no warpped class.');
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
function getDefaults(name) {
|
||||
var PluginClass = getPlugin(name);
|
||||
|
||||
if (PluginClass) {
|
||||
return PluginClass.getDefaults();
|
||||
} else {
|
||||
return {};
|
||||
}
|
||||
}
|
||||
|
||||
function pluginFactory(name, $el) {
|
||||
var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
||||
|
||||
var PluginClass = getPlugin(name);
|
||||
|
||||
if (PluginClass && typeof PluginClass.api === 'undefined') {
|
||||
return new PluginClass($el, _jquery2.default.extend(true, {}, getDefaults(name), options));
|
||||
} else if (_jquery2.default.fn[name]) {
|
||||
var plugin = new Plugin($el, options);
|
||||
plugin.getName = function () {
|
||||
return name;
|
||||
};
|
||||
plugin.name = name;
|
||||
return plugin;
|
||||
} else if (typeof PluginClass.api !== 'undefined') {
|
||||
// console.log('Plugin:' + name + ' use api render.');
|
||||
return false;
|
||||
} else {
|
||||
console.warn('Plugin:' + name + ' script is not loaded.');
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
exports.Plugin = Plugin;
|
||||
exports.getPluginAPI = getPluginAPI;
|
||||
exports.getPlugin = getPlugin;
|
||||
exports.getDefaults = getDefaults;
|
||||
exports.pluginFactory = pluginFactory;
|
||||
exports.default = Plugin;
|
||||
});
|
||||
+73
@@ -0,0 +1,73 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/ace-editor', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginAceEditor = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'ace';
|
||||
|
||||
var AceEditor = function (_Plugin) {
|
||||
babelHelpers.inherits(AceEditor, _Plugin);
|
||||
|
||||
function AceEditor() {
|
||||
babelHelpers.classCallCheck(this, AceEditor);
|
||||
return babelHelpers.possibleConstructorReturn(this, (AceEditor.__proto__ || Object.getPrototypeOf(AceEditor)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(AceEditor, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (typeof ace === 'undefined') return;
|
||||
// ace.config.set("themePath", "../theme");
|
||||
ace.config.loadModule('ace/ext/language_tools');
|
||||
|
||||
var $el = this.$el,
|
||||
id = $el.attr('id'),
|
||||
editor = ace.edit(id);
|
||||
|
||||
editor.container.style.opacity = '';
|
||||
if (this.options.mode) {
|
||||
editor.session.setMode('ace/mode/' + this.options.mode);
|
||||
}
|
||||
if (this.options.theme) {
|
||||
editor.setTheme('ace/theme/' + this.options.theme);
|
||||
}
|
||||
|
||||
editor.setOption('maxLines', 40);
|
||||
editor.setAutoScrollEditorIntoView(true);
|
||||
|
||||
ace.config.loadModule('ace/ext/language_tools', function () {
|
||||
editor.setOptions({
|
||||
enableSnippets: true,
|
||||
enableBasicAutocompletion: true
|
||||
});
|
||||
});
|
||||
}
|
||||
}]);
|
||||
return AceEditor;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, AceEditor);
|
||||
|
||||
exports.default = AceEditor;
|
||||
});
|
||||
+168
@@ -0,0 +1,168 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/action-btn', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginActionBtn = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var pluginName = 'actionBtn';
|
||||
var defaults = {
|
||||
trigger: 'click', // click, hover
|
||||
toggleSelector: '.site-action-toggle',
|
||||
listSelector: '.site-action-buttons',
|
||||
activeClass: 'active',
|
||||
onShow: function onShow() {},
|
||||
onHide: function onHide() {}
|
||||
};
|
||||
|
||||
var actionBtn = function () {
|
||||
function actionBtn(element, options) {
|
||||
babelHelpers.classCallCheck(this, actionBtn);
|
||||
|
||||
this.element = element;
|
||||
this.$element = (0, _jquery2.default)(element);
|
||||
|
||||
this.options = _jquery2.default.extend({}, defaults, options, this.$element.data());
|
||||
|
||||
this.init();
|
||||
}
|
||||
|
||||
babelHelpers.createClass(actionBtn, [{
|
||||
key: 'init',
|
||||
value: function init() {
|
||||
this.showed = false;
|
||||
|
||||
this.$toggle = this.$element.find(this.options.toggleSelector);
|
||||
this.$list = this.$element.find(this.options.listSelector);
|
||||
|
||||
var self = this;
|
||||
|
||||
if (this.options.trigger === 'hover') {
|
||||
this.$element.on('mouseenter', this.options.toggleSelector, function () {
|
||||
if (!self.showed) {
|
||||
self.show();
|
||||
}
|
||||
});
|
||||
this.$element.on('mouseleave', this.options.toggleSelector, function () {
|
||||
if (self.showed) {
|
||||
self.hide();
|
||||
}
|
||||
});
|
||||
} else {
|
||||
this.$element.on('click', this.options.toggleSelector, function () {
|
||||
if (self.showed) {
|
||||
self.hide();
|
||||
} else {
|
||||
self.show();
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'show',
|
||||
value: function show() {
|
||||
if (!this.showed) {
|
||||
this.$element.addClass(this.options.activeClass);
|
||||
this.showed = true;
|
||||
|
||||
this.options.onShow.call(this);
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'hide',
|
||||
value: function hide() {
|
||||
if (this.showed) {
|
||||
this.$element.removeClass(this.options.activeClass);
|
||||
this.showed = false;
|
||||
|
||||
this.options.onHide.call(this);
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: '_jQueryInterface',
|
||||
value: function _jQueryInterface(options) {
|
||||
for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
||||
args[_key - 1] = arguments[_key];
|
||||
}
|
||||
|
||||
if (typeof options === 'string') {
|
||||
var method = options;
|
||||
|
||||
if (/^\_/.test(method)) {
|
||||
return false;
|
||||
} else if (/^(get)$/.test(method)) {
|
||||
var api = this.first().data(pluginName);
|
||||
if (api && typeof api[method] === 'function') {
|
||||
return api[method].apply(api, args);
|
||||
}
|
||||
} else {
|
||||
return this.each(function () {
|
||||
var api = _jquery2.default.data(this, pluginName);
|
||||
if (api && typeof api[method] === 'function') {
|
||||
api[method].apply(api, args);
|
||||
}
|
||||
});
|
||||
}
|
||||
} else {
|
||||
return this.each(function () {
|
||||
if (!_jquery2.default.data(this, pluginName)) {
|
||||
_jquery2.default.data(this, pluginName, new actionBtn(this, options));
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}]);
|
||||
return actionBtn;
|
||||
}();
|
||||
|
||||
_jquery2.default.fn[pluginName] = actionBtn._jQueryInterface;
|
||||
_jquery2.default.fn[pluginName].constructor = actionBtn;
|
||||
_jquery2.default.fn[pluginName].noConflict = function () {
|
||||
'use strict';
|
||||
|
||||
_jquery2.default.fn[pluginName] = window.JQUERY_NO_CONFLICT;
|
||||
return actionBtn._jQueryInterface;
|
||||
};
|
||||
|
||||
var ActionBtn = function (_Plugin) {
|
||||
babelHelpers.inherits(ActionBtn, _Plugin);
|
||||
|
||||
function ActionBtn() {
|
||||
babelHelpers.classCallCheck(this, ActionBtn);
|
||||
return babelHelpers.possibleConstructorReturn(this, (ActionBtn.__proto__ || Object.getPrototypeOf(ActionBtn)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(ActionBtn, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return pluginName;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return defaults;
|
||||
}
|
||||
}]);
|
||||
return ActionBtn;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(pluginName, ActionBtn);
|
||||
|
||||
exports.default = ActionBtn;
|
||||
});
|
||||
+138
@@ -0,0 +1,138 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/alertify', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginAlertify = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'alertify';
|
||||
|
||||
var Alertify = function (_Plugin) {
|
||||
babelHelpers.inherits(Alertify, _Plugin);
|
||||
|
||||
function Alertify() {
|
||||
babelHelpers.classCallCheck(this, Alertify);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Alertify.__proto__ || Object.getPrototypeOf(Alertify)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Alertify, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (this.options.labelOk) {
|
||||
this.options.okBtn = this.options.labelOk;
|
||||
}
|
||||
|
||||
if (this.options.labelCancel) {
|
||||
this.options.cancelBtn = this.options.labelCancel;
|
||||
}
|
||||
|
||||
this.$el.data('alertifyWrapApi', this);
|
||||
}
|
||||
}, {
|
||||
key: 'show',
|
||||
value: function show() {
|
||||
if (typeof alertify === 'undefined') return;
|
||||
var options = this.options;
|
||||
if (typeof options.delay !== 'undefined') {
|
||||
alertify.delay(options.delay);
|
||||
}
|
||||
|
||||
if (typeof options.theme !== 'undefined') {
|
||||
alertify.theme(options.theme);
|
||||
}
|
||||
|
||||
if (typeof options.cancelBtn !== 'undefined') {
|
||||
alertify.cancelBtn(options.cancelBtn);
|
||||
}
|
||||
|
||||
if (typeof options.okBtn !== 'undefined') {
|
||||
alertify.okBtn(options.okBtn);
|
||||
}
|
||||
|
||||
if (typeof options.placeholder !== 'undefined') {
|
||||
alertify.delay(options.placeholder);
|
||||
}
|
||||
|
||||
if (typeof options.defaultValue !== 'undefined') {
|
||||
alertify.delay(options.defaultValue);
|
||||
}
|
||||
|
||||
if (typeof options.maxLogItems !== 'undefined') {
|
||||
alertify.delay(options.maxLogItems);
|
||||
}
|
||||
|
||||
if (typeof options.closeLogOnClick !== 'undefined') {
|
||||
alertify.delay(options.closeLogOnClick);
|
||||
}
|
||||
|
||||
switch (options.type) {
|
||||
case 'confirm':
|
||||
alertify.confirm(options.confirmTitle, function () {
|
||||
alertify.success(options.successMessage);
|
||||
}, function () {
|
||||
alertify.error(options.errorMessage);
|
||||
});
|
||||
break;
|
||||
case 'prompt':
|
||||
alertify.prompt(options.promptTitle, function (str, ev) {
|
||||
var message = options.successMessage.replace('%s', str);
|
||||
alertify.success(message);
|
||||
}, function (ev) {
|
||||
alertify.error(options.errorMessage);
|
||||
});
|
||||
break;
|
||||
case 'log':
|
||||
alertify.log(options.logMessage);
|
||||
break;
|
||||
case 'success':
|
||||
alertify.success(options.successMessage);
|
||||
break;
|
||||
case 'error':
|
||||
alertify.error(options.errorMessage);
|
||||
break;
|
||||
default:
|
||||
alertify.alert(options.alertMessage);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
type: 'alert',
|
||||
delay: 5000,
|
||||
theme: 'bootstrap'
|
||||
};
|
||||
}
|
||||
}, {
|
||||
key: 'api',
|
||||
value: function api() {
|
||||
return 'click|show';
|
||||
}
|
||||
}]);
|
||||
return Alertify;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Alertify);
|
||||
|
||||
exports.default = Alertify;
|
||||
});
|
||||
+100
@@ -0,0 +1,100 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/animate-list', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginAnimateList = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'animateList';
|
||||
|
||||
var AnimateList = function (_Plugin) {
|
||||
babelHelpers.inherits(AnimateList, _Plugin);
|
||||
|
||||
function AnimateList() {
|
||||
babelHelpers.classCallCheck(this, AnimateList);
|
||||
return babelHelpers.possibleConstructorReturn(this, (AnimateList.__proto__ || Object.getPrototypeOf(AnimateList)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(AnimateList, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
var $el = this.$el;
|
||||
|
||||
var animatedBox = function () {
|
||||
function animatedBox($el, opts) {
|
||||
babelHelpers.classCallCheck(this, animatedBox);
|
||||
|
||||
this.options = opts;
|
||||
this.$children = $el.find(opts.child);
|
||||
this.$children.addClass('animation-' + opts.animate);
|
||||
this.$children.css('animation-fill-mode', opts.fill);
|
||||
this.$children.css('animation-duration', opts.duration + 'ms');
|
||||
|
||||
var delay = 0,
|
||||
self = this;
|
||||
|
||||
this.$children.each(function () {
|
||||
(0, _jquery2.default)(this).css('animation-delay', delay + 'ms');
|
||||
delay += self.options.delay;
|
||||
});
|
||||
}
|
||||
|
||||
babelHelpers.createClass(animatedBox, [{
|
||||
key: 'run',
|
||||
value: function run(type) {
|
||||
var _this2 = this;
|
||||
|
||||
this.$children.removeClass('animation-' + this.options.animate);
|
||||
if (typeof type !== 'undefined') {
|
||||
this.options.animate = type;
|
||||
}
|
||||
setTimeout(function () {
|
||||
_this2.$children.addClass('animation-' + _this2.options.animate);
|
||||
}, 0);
|
||||
}
|
||||
}]);
|
||||
return animatedBox;
|
||||
}();
|
||||
|
||||
$el.data('animateList', new animatedBox($el, this.options));
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
child: '.panel',
|
||||
duration: 250,
|
||||
delay: 50,
|
||||
animate: 'scale-up',
|
||||
fill: 'backwards'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return AnimateList;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, AnimateList);
|
||||
|
||||
exports.default = AnimateList;
|
||||
});
|
||||
+110
@@ -0,0 +1,110 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/animsition', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginAnimsition = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'animsition';
|
||||
|
||||
var Animsition = function (_Plugin) {
|
||||
babelHelpers.inherits(Animsition, _Plugin);
|
||||
|
||||
function Animsition() {
|
||||
babelHelpers.classCallCheck(this, Animsition);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Animsition.__proto__ || Object.getPrototypeOf(Animsition)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Animsition, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render(callback) {
|
||||
var options = this.options;
|
||||
|
||||
if (options.random) {
|
||||
var li = options.inDefaults.length,
|
||||
lo = options.outDefaults.length;
|
||||
|
||||
var ni = parseInt(li * Math.random(), 0),
|
||||
no = parseInt(lo * Math.random(), 0);
|
||||
|
||||
options.inClass = options.inDefaults[ni];
|
||||
options.outClass = options.outDefaults[no];
|
||||
}
|
||||
|
||||
this.$el.animsition(options);
|
||||
|
||||
(0, _jquery2.default)('.' + options.loadingClass).addClass('loader-' + options.loadingType);
|
||||
|
||||
if (this.$el.animsition('supportCheck', options)) {
|
||||
if (_jquery2.default.isFunction(callback)) {
|
||||
this.$el.one('animsition.end', function () {
|
||||
callback.call();
|
||||
});
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
if (_jquery2.default.isFunction(callback)) {
|
||||
callback.call();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
inClass: 'fade-in',
|
||||
outClass: 'fade-out',
|
||||
inDuration: 800,
|
||||
outDuration: 500,
|
||||
linkElement: '.animsition-link',
|
||||
loading: true,
|
||||
loadingParentElement: 'body',
|
||||
loadingClass: 'loader',
|
||||
loadingType: 'default',
|
||||
timeout: false,
|
||||
timeoutCountdown: 5000,
|
||||
onLoadEvent: true,
|
||||
browser: ['animation-duration', '-webkit-animation-duration'],
|
||||
overlay: false,
|
||||
// random: true,
|
||||
overlayClass: 'animsition-overlay-slide',
|
||||
overlayParentElement: 'body',
|
||||
|
||||
inDefaults: ['fade-in', 'fade-in-up-sm', 'fade-in-up', 'fade-in-up-lg', 'fade-in-down-sm', 'fade-in-down', 'fade-in-down-lg', 'fade-in-left-sm', 'fade-in-left', 'fade-in-left-lg', 'fade-in-right-sm', 'fade-in-right', 'fade-in-right-lg',
|
||||
// 'overlay-slide-in-top', 'overlay-slide-in-bottom', 'overlay-slide-in-left', 'overlay-slide-in-right',
|
||||
'zoom-in-sm', 'zoom-in', 'zoom-in-lg'],
|
||||
outDefaults: ['fade-out', 'fade-out-up-sm', 'fade-out-up', 'fade-out-up-lg', 'fade-out-down-sm', 'fade-out-down', 'fade-out-down-lg', 'fade-out-left-sm', 'fade-out-left', 'fade-out-left-lg', 'fade-out-right-sm', 'fade-out-right', 'fade-out-right-lg',
|
||||
// 'overlay-slide-out-top', 'overlay-slide-out-bottom', 'overlay-slide-out-left', 'overlay-slide-out-right'
|
||||
'zoom-out-sm', 'zoom-out', 'zoom-out-lg']
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Animsition;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Animsition);
|
||||
|
||||
exports.default = Animsition;
|
||||
});
|
||||
+80
@@ -0,0 +1,80 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/asbreadcrumbs', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginAsbreadcrumbs = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'breadcrumb';
|
||||
|
||||
var Breadcrumb = function (_Plugin) {
|
||||
babelHelpers.inherits(Breadcrumb, _Plugin);
|
||||
|
||||
function Breadcrumb() {
|
||||
babelHelpers.classCallCheck(this, Breadcrumb);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Breadcrumb.__proto__ || Object.getPrototypeOf(Breadcrumb)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Breadcrumb, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
var $el = this.$el;
|
||||
$el.asBreadcrumbs(this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
overflow: 'left',
|
||||
namespace: 'breadcrumb',
|
||||
dropdownMenuClass: 'dropdown-menu',
|
||||
dropdownItemClass: 'dropdown-item',
|
||||
toggleIconClass: 'wb-chevron-down-mini',
|
||||
ellipsis: function ellipsis(classes, label) {
|
||||
return '<li class="breadcrumb-item ' + classes.ellipsisClass + '">' + label + '</li>';
|
||||
},
|
||||
dropdown: function dropdown(classes) {
|
||||
var dropdownClass = 'dropdown';
|
||||
var dropdownMenuClass = 'dropdown-menu';
|
||||
|
||||
if (this.options.overflow === 'right') {
|
||||
dropdownMenuClass += ' dropdown-menu-right';
|
||||
}
|
||||
|
||||
return '<li class="breadcrumb-item ' + dropdownClass + ' ' + classes.dropdownClass + '">\n <a href="javascript:void(0);" class="' + classes.toggleClass + '" data-toggle="dropdown">\n <i class="' + classes.toggleIconClass + '"></i>\n </a>\n <div class="' + dropdownMenuClass + ' ' + classes.dropdownMenuClass + '" role="menu"></div>\n </li>';
|
||||
},
|
||||
dropdownItem: function dropdownItem(classes, label, href) {
|
||||
if (!href) {
|
||||
return '<a class="' + classes.dropdownItemClass + ' ' + classes.dropdownItemDisableClass + '" href="#">' + label + '</a>';
|
||||
}
|
||||
return '<a class="' + classes.dropdownItemClass + '" href="' + href + '">' + label + '</a>';
|
||||
}
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Breadcrumb;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Breadcrumb);
|
||||
|
||||
exports.default = Breadcrumb;
|
||||
});
|
||||
+51
@@ -0,0 +1,51 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/ascolorpicker', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginAscolorpicker = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'asColorPicker';
|
||||
|
||||
var AsColorPicker = function (_Plugin) {
|
||||
babelHelpers.inherits(AsColorPicker, _Plugin);
|
||||
|
||||
function AsColorPicker() {
|
||||
babelHelpers.classCallCheck(this, AsColorPicker);
|
||||
return babelHelpers.possibleConstructorReturn(this, (AsColorPicker.__proto__ || Object.getPrototypeOf(AsColorPicker)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(AsColorPicker, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
namespace: 'colorInputUi'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return AsColorPicker;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, AsColorPicker);
|
||||
|
||||
exports.default = AsColorPicker;
|
||||
});
|
||||
+108
@@ -0,0 +1,108 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/aspaginator', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginAspaginator = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'paginator';
|
||||
|
||||
var Paginator = function (_Plugin) {
|
||||
babelHelpers.inherits(Paginator, _Plugin);
|
||||
|
||||
function Paginator() {
|
||||
babelHelpers.classCallCheck(this, Paginator);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Paginator.__proto__ || Object.getPrototypeOf(Paginator)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Paginator, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.asPaginator) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el,
|
||||
total = $el.data('total');
|
||||
|
||||
$el.asPaginator(total, this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
namespace: 'pagination',
|
||||
currentPage: 1,
|
||||
itemsPerPage: 10,
|
||||
disabledClass: 'disabled',
|
||||
activeClass: 'active',
|
||||
|
||||
visibleNum: {
|
||||
0: 3,
|
||||
480: 5
|
||||
},
|
||||
|
||||
tpl: function tpl() {
|
||||
return '{{prev}}{{lists}}{{next}}';
|
||||
},
|
||||
|
||||
|
||||
components: {
|
||||
prev: {
|
||||
tpl: function tpl() {
|
||||
return '<li class="' + this.namespace + '-prev page-item"><a class="page-link" href="javascript:void(0)" aria-label="Prev"><span class="icon wb-chevron-left-mini"></span></a></li>';
|
||||
}
|
||||
},
|
||||
next: {
|
||||
tpl: function tpl() {
|
||||
return '<li class="' + this.namespace + '-next page-item"><a class="page-link" href="javascript:void(0)" aria-label="Next"><span class="icon wb-chevron-right-mini"></span></a></li>';
|
||||
}
|
||||
},
|
||||
lists: {
|
||||
tpl: function tpl() {
|
||||
var lists = '',
|
||||
remainder = this.currentPage >= this.visible ? this.currentPage % this.visible : this.currentPage;
|
||||
remainder = remainder === 0 ? this.visible : remainder;
|
||||
for (var k = 1; k < remainder; k++) {
|
||||
lists += '<li class="' + this.namespace + '-items page-item" data-value="' + (this.currentPage - remainder + k) + '"><a class="page-link" href="javascript:void(0)">' + (this.currentPage - remainder + k) + '</a></li>';
|
||||
}
|
||||
lists += '<li class="' + this.namespace + '-items page-item ' + this.classes.active + '" data-value="' + this.currentPage + '"><a class="page-link" href="javascript:void(0)">' + this.currentPage + '</a></li>';
|
||||
for (var i = this.currentPage + 1, limit = i + this.visible - remainder - 1 > this.totalPages ? this.totalPages : i + this.visible - remainder - 1; i <= limit; i++) {
|
||||
lists += '<li class="' + this.namespace + '-items page-item" data-value="' + i + '"><a class="page-link" href="javascript:void(0)">' + i + '</a></li>';
|
||||
}
|
||||
|
||||
return lists;
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Paginator;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Paginator);
|
||||
|
||||
exports.default = Paginator;
|
||||
});
|
||||
+71
@@ -0,0 +1,71 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/aspieprogress', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginAspieprogress = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'pieProgress';
|
||||
|
||||
var PieProgress = function (_Plugin) {
|
||||
babelHelpers.inherits(PieProgress, _Plugin);
|
||||
|
||||
function PieProgress() {
|
||||
babelHelpers.classCallCheck(this, PieProgress);
|
||||
return babelHelpers.possibleConstructorReturn(this, (PieProgress.__proto__ || Object.getPrototypeOf(PieProgress)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(PieProgress, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.asPieProgress) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el;
|
||||
|
||||
$el.asPieProgress(this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
namespace: 'pie-progress',
|
||||
speed: 30,
|
||||
classes: {
|
||||
svg: 'pie-progress-svg',
|
||||
element: 'pie-progress',
|
||||
number: 'pie-progress-number',
|
||||
content: 'pie-progress-content'
|
||||
}
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return PieProgress;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, PieProgress);
|
||||
|
||||
exports.default = PieProgress;
|
||||
});
|
||||
+99
@@ -0,0 +1,99 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/asprogress', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginAsprogress = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'progress';
|
||||
|
||||
var Progress = function (_Plugin) {
|
||||
babelHelpers.inherits(Progress, _Plugin);
|
||||
|
||||
function Progress() {
|
||||
babelHelpers.classCallCheck(this, Progress);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Progress.__proto__ || Object.getPrototypeOf(Progress)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Progress, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.asProgress) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el;
|
||||
|
||||
$el.asProgress(this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
bootstrap: true,
|
||||
|
||||
onUpdate: function onUpdate(n) {
|
||||
var per = (n - this.min) / (this.max - this.min);
|
||||
if (per < 0.5) {
|
||||
this.$target.addClass('progress-bar-success').removeClass('progress-bar-warning progress-bar-danger');
|
||||
} else if (per >= 0.5 && per < 0.8) {
|
||||
this.$target.addClass('progress-bar-warning').removeClass('progress-bar-success progress-bar-danger');
|
||||
} else {
|
||||
this.$target.addClass('progress-bar-danger').removeClass('progress-bar-success progress-bar-warning');
|
||||
}
|
||||
},
|
||||
labelCallback: function labelCallback(n) {
|
||||
var label = void 0;
|
||||
var labelType = this.$element.data('labeltype');
|
||||
|
||||
if (labelType === 'percentage') {
|
||||
var percentage = this.getPercentage(n);
|
||||
label = percentage + '%';
|
||||
} else if (labelType === 'steps') {
|
||||
var total = this.$element.data('totalsteps');
|
||||
if (!total) {
|
||||
total = 10;
|
||||
}
|
||||
var step = Math.round(total * (n - this.min) / (this.max - this.min));
|
||||
label = step + ' / ' + total;
|
||||
} else {
|
||||
label = n;
|
||||
}
|
||||
|
||||
if (this.$element.parent().hasClass('contextual-progress')) {
|
||||
this.$element.parent().find('.progress-label').html(label);
|
||||
}
|
||||
|
||||
return label;
|
||||
}
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Progress;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Progress);
|
||||
|
||||
exports.default = Progress;
|
||||
});
|
||||
+52
@@ -0,0 +1,52 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/asrange', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginAsrange = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'asRange';
|
||||
|
||||
var AsRange = function (_Plugin) {
|
||||
babelHelpers.inherits(AsRange, _Plugin);
|
||||
|
||||
function AsRange() {
|
||||
babelHelpers.classCallCheck(this, AsRange);
|
||||
return babelHelpers.possibleConstructorReturn(this, (AsRange.__proto__ || Object.getPrototypeOf(AsRange)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(AsRange, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
tip: false,
|
||||
scale: false
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return AsRange;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, AsRange);
|
||||
|
||||
exports.default = AsRange;
|
||||
});
|
||||
+60
@@ -0,0 +1,60 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/asscrollable', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginAsscrollable = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'scrollable';
|
||||
|
||||
var Scrollable = function (_Plugin) {
|
||||
babelHelpers.inherits(Scrollable, _Plugin);
|
||||
|
||||
function Scrollable() {
|
||||
babelHelpers.classCallCheck(this, Scrollable);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Scrollable.__proto__ || Object.getPrototypeOf(Scrollable)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Scrollable, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
var $el = this.$el;
|
||||
|
||||
$el.asScrollable(this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
namespace: 'scrollable',
|
||||
contentSelector: "> [data-role='content']",
|
||||
containerSelector: "> [data-role='container']"
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Scrollable;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Scrollable);
|
||||
|
||||
exports.default = Scrollable;
|
||||
});
|
||||
+180
@@ -0,0 +1,180 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/asselectable', ['exports', 'jquery'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery);
|
||||
global.PluginAsselectable = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var pluginName = 'asSelectable';
|
||||
var defaults = {
|
||||
allSelector: '.selectable-all',
|
||||
itemSelector: '.selectable-item',
|
||||
rowSelector: 'tr',
|
||||
rowSelectable: false,
|
||||
rowActiveClass: 'active',
|
||||
onChange: null
|
||||
};
|
||||
|
||||
var asSelectable = function () {
|
||||
function asSelectable(element, options) {
|
||||
babelHelpers.classCallCheck(this, asSelectable);
|
||||
|
||||
this.element = element;
|
||||
this.$element = (0, _jquery2.default)(element);
|
||||
this.options = _jquery2.default.extend({}, defaults, options, this.$element.data());
|
||||
|
||||
this.init();
|
||||
}
|
||||
|
||||
babelHelpers.createClass(asSelectable, [{
|
||||
key: 'init',
|
||||
value: function init() {
|
||||
var self = this;
|
||||
var options = this.options;
|
||||
|
||||
self.$element.on('change', options.allSelector, function () {
|
||||
var value = (0, _jquery2.default)(this).prop('checked');
|
||||
self.getItems().each(function () {
|
||||
var $one = (0, _jquery2.default)(this);
|
||||
$one.prop('checked', value).trigger('change', [true]);
|
||||
self.selectRow($one, value);
|
||||
});
|
||||
});
|
||||
|
||||
self.$element.on('click', options.itemSelector, function (e) {
|
||||
var $one = (0, _jquery2.default)(this);
|
||||
var value = $one.prop('checked');
|
||||
self.selectRow($one, value);
|
||||
e.stopPropagation();
|
||||
});
|
||||
|
||||
self.$element.on('change', options.itemSelector, function () {
|
||||
var $all = self.$element.find(options.allSelector);
|
||||
var $row = self.getItems();
|
||||
var total = $row.length;
|
||||
var checked = self.getSelected().length;
|
||||
|
||||
if (total === checked) {
|
||||
$all.prop('checked', true);
|
||||
} else {
|
||||
$all.prop('checked', false);
|
||||
}
|
||||
|
||||
self._trigger('change', checked);
|
||||
|
||||
if (typeof options.callback === 'function') {
|
||||
options.callback.call(this);
|
||||
}
|
||||
});
|
||||
|
||||
if (options.rowSelectable) {
|
||||
self.$element.on('click', options.rowSelector, function (e) {
|
||||
if ('checkbox' !== e.target.type && 'button' !== e.target.type && 'a' !== e.target.tagName.toLowerCase() && !(0, _jquery2.default)(e.target).parent('div.checkbox-custom').length) {
|
||||
var $checkbox = (0, _jquery2.default)(options.itemSelector, this);
|
||||
var value = $checkbox.prop('checked');
|
||||
$checkbox.prop('checked', !value);
|
||||
self.selectRow($checkbox, !value);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'selectRow',
|
||||
value: function selectRow(item, value) {
|
||||
if (value) {
|
||||
item.parents(this.options.rowSelector).addClass(this.options.rowActiveClass);
|
||||
} else {
|
||||
item.parents(this.options.rowSelector).removeClass(this.options.rowActiveClass);
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'getItems',
|
||||
value: function getItems() {
|
||||
return this.$element.find(this.options.itemSelector);
|
||||
}
|
||||
}, {
|
||||
key: 'getSelected',
|
||||
value: function getSelected() {
|
||||
return this.getItems().filter(':checked');
|
||||
}
|
||||
}, {
|
||||
key: '_trigger',
|
||||
value: function _trigger(eventType) {
|
||||
var method_arguments = Array.prototype.slice.call(arguments, 1);
|
||||
var data = [this].concat(method_arguments);
|
||||
|
||||
// event
|
||||
this.$element.trigger(pluginName + '::' + eventType, data);
|
||||
|
||||
// callback
|
||||
eventType = eventType.replace(/\b\w+\b/g, function (word) {
|
||||
return word.substring(0, 1).toUpperCase() + word.substring(1);
|
||||
});
|
||||
var onFunction = 'on' + eventType;
|
||||
if (typeof this.options[onFunction] === 'function') {
|
||||
this.options[onFunction].apply(this, method_arguments);
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: '_jQueryInterface',
|
||||
value: function _jQueryInterface(options) {
|
||||
for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
||||
args[_key - 1] = arguments[_key];
|
||||
}
|
||||
|
||||
if (typeof options === 'string') {
|
||||
var method = options;
|
||||
|
||||
if (/^\_/.test(method)) {
|
||||
return false;
|
||||
} else if (/^(get)/.test(method)) {
|
||||
var api = this.first().data(pluginName);
|
||||
|
||||
if (api && typeof api[method] === 'function') {
|
||||
return api[method].apply(api, args);
|
||||
}
|
||||
} else {
|
||||
return this.each(function () {
|
||||
var api = _jquery2.default.data(this, pluginName);
|
||||
if (api && typeof api[method] === 'function') {
|
||||
api[method].apply(api, args);
|
||||
}
|
||||
});
|
||||
}
|
||||
} else {
|
||||
return this.each(function () {
|
||||
if (!_jquery2.default.data(this, pluginName)) {
|
||||
_jquery2.default.data(this, pluginName, new asSelectable(this, options));
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}]);
|
||||
return asSelectable;
|
||||
}();
|
||||
|
||||
_jquery2.default.fn[pluginName] = asSelectable._jQueryInterface;
|
||||
_jquery2.default.fn[pluginName].constructor = asSelectable;
|
||||
_jquery2.default.fn[pluginName].noConflict = function () {
|
||||
'use strict';
|
||||
|
||||
_jquery2.default.fn[pluginName] = window.JQUERY_NO_CONFLICT;
|
||||
return asSelectable._jQueryInterface;
|
||||
};
|
||||
|
||||
exports.default = asSelectable;
|
||||
});
|
||||
+55
@@ -0,0 +1,55 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/asspinner', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginAsspinner = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'asSpinner';
|
||||
|
||||
var AsSpinner = function (_Plugin) {
|
||||
babelHelpers.inherits(AsSpinner, _Plugin);
|
||||
|
||||
function AsSpinner() {
|
||||
babelHelpers.classCallCheck(this, AsSpinner);
|
||||
return babelHelpers.possibleConstructorReturn(this, (AsSpinner.__proto__ || Object.getPrototypeOf(AsSpinner)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(AsSpinner, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
namespace: 'spinnerUi',
|
||||
skin: null,
|
||||
min: '-10',
|
||||
max: 100,
|
||||
mousewheel: true
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return AsSpinner;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, AsSpinner);
|
||||
|
||||
exports.default = AsSpinner;
|
||||
});
|
||||
+103
@@ -0,0 +1,103 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/bootbox', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginBootbox = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'bootbox';
|
||||
|
||||
var Bootbox = function (_Plugin) {
|
||||
babelHelpers.inherits(Bootbox, _Plugin);
|
||||
|
||||
function Bootbox() {
|
||||
babelHelpers.classCallCheck(this, Bootbox);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Bootbox.__proto__ || Object.getPrototypeOf(Bootbox)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Bootbox, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
this.$el.data('bootboxWrapApi', this);
|
||||
}
|
||||
}, {
|
||||
key: 'show',
|
||||
value: function show() {
|
||||
if (typeof bootbox === 'undefined') {
|
||||
return;
|
||||
}
|
||||
|
||||
var options = this.options;
|
||||
|
||||
if (options.classname) {
|
||||
options.className = options.classname;
|
||||
}
|
||||
|
||||
if (options.className) {
|
||||
options.className = options.className + ' modal-simple';
|
||||
}
|
||||
|
||||
if (typeof options.callback === 'string' && _jquery2.default.isFunction(window[options.callback])) {
|
||||
options.callback = window[options.callback];
|
||||
}
|
||||
|
||||
if (options.type) {
|
||||
switch (options.type) {
|
||||
case 'alert':
|
||||
bootbox.alert(options);
|
||||
break;
|
||||
case 'confirm':
|
||||
bootbox.confirm(options);
|
||||
break;
|
||||
case 'prompt':
|
||||
bootbox.prompt(options);
|
||||
break;
|
||||
default:
|
||||
bootbox.dialog(options);
|
||||
}
|
||||
} else {
|
||||
bootbox.dialog(options);
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
message: '',
|
||||
className: 'modal-simple'
|
||||
};
|
||||
}
|
||||
}, {
|
||||
key: 'api',
|
||||
value: function api() {
|
||||
return 'click|show';
|
||||
}
|
||||
}]);
|
||||
return Bootbox;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Bootbox);
|
||||
|
||||
exports.default = Bootbox;
|
||||
});
|
||||
+51
@@ -0,0 +1,51 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/bootstrap-datepicker', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginBootstrapDatepicker = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'datepicker';
|
||||
|
||||
var Datepicker = function (_Plugin) {
|
||||
babelHelpers.inherits(Datepicker, _Plugin);
|
||||
|
||||
function Datepicker() {
|
||||
babelHelpers.classCallCheck(this, Datepicker);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Datepicker.__proto__ || Object.getPrototypeOf(Datepicker)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Datepicker, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
autoclose: true
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Datepicker;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Datepicker);
|
||||
|
||||
exports.default = Datepicker;
|
||||
});
|
||||
+52
@@ -0,0 +1,52 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/bootstrap-maxlength', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginBootstrapMaxlength = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'maxlength';
|
||||
|
||||
var Maxlength = function (_Plugin) {
|
||||
babelHelpers.inherits(Maxlength, _Plugin);
|
||||
|
||||
function Maxlength() {
|
||||
babelHelpers.classCallCheck(this, Maxlength);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Maxlength.__proto__ || Object.getPrototypeOf(Maxlength)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Maxlength, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
warningClass: 'badge badge-warning',
|
||||
limitReachedClass: 'badge badge-danger'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Maxlength;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Maxlength);
|
||||
|
||||
exports.default = Maxlength;
|
||||
});
|
||||
+53
@@ -0,0 +1,53 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/bootstrap-select', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginBootstrapSelect = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'selectpicker';
|
||||
|
||||
var Selectpicker = function (_Plugin) {
|
||||
babelHelpers.inherits(Selectpicker, _Plugin);
|
||||
|
||||
function Selectpicker() {
|
||||
babelHelpers.classCallCheck(this, Selectpicker);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Selectpicker.__proto__ || Object.getPrototypeOf(Selectpicker)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Selectpicker, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
style: 'btn-select',
|
||||
iconBase: 'icon',
|
||||
tickIcon: 'wb-check'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Selectpicker;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Selectpicker);
|
||||
|
||||
exports.default = Selectpicker;
|
||||
});
|
||||
+63
@@ -0,0 +1,63 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/bootstrap-sweetalert', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginBootstrapSweetalert = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'sweetalert';
|
||||
|
||||
var Sweetalert = function (_Plugin) {
|
||||
babelHelpers.inherits(Sweetalert, _Plugin);
|
||||
|
||||
function Sweetalert() {
|
||||
babelHelpers.classCallCheck(this, Sweetalert);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Sweetalert.__proto__ || Object.getPrototypeOf(Sweetalert)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Sweetalert, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
this.$el.data('sweetalertWrapApi', this);
|
||||
}
|
||||
}, {
|
||||
key: 'show',
|
||||
value: function show() {
|
||||
if (typeof swal === 'undefined') {
|
||||
return;
|
||||
}
|
||||
|
||||
swal(this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'api',
|
||||
value: function api() {
|
||||
return 'click|show';
|
||||
}
|
||||
}]);
|
||||
return Sweetalert;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Sweetalert);
|
||||
|
||||
exports.default = Sweetalert;
|
||||
});
|
||||
+51
@@ -0,0 +1,51 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/bootstrap-tagsinput', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginBootstrapTagsinput = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'tagsinput';
|
||||
|
||||
var Tagsinput = function (_Plugin) {
|
||||
babelHelpers.inherits(Tagsinput, _Plugin);
|
||||
|
||||
function Tagsinput() {
|
||||
babelHelpers.classCallCheck(this, Tagsinput);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Tagsinput.__proto__ || Object.getPrototypeOf(Tagsinput)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Tagsinput, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
tagClass: 'badge badge-default'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Tagsinput;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Tagsinput);
|
||||
|
||||
exports.default = Tagsinput;
|
||||
});
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/bootstrap-tokenfield', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginBootstrapTokenfield = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'tokenfield';
|
||||
|
||||
var Tokenfield = function (_Plugin) {
|
||||
babelHelpers.inherits(Tokenfield, _Plugin);
|
||||
|
||||
function Tokenfield() {
|
||||
babelHelpers.classCallCheck(this, Tokenfield);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Tokenfield.__proto__ || Object.getPrototypeOf(Tokenfield)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Tokenfield, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return Tokenfield;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Tokenfield);
|
||||
|
||||
exports.default = Tokenfield;
|
||||
});
|
||||
+54
@@ -0,0 +1,54 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/bootstrap-touchspin', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginBootstrapTouchspin = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'TouchSpin';
|
||||
|
||||
var TouchSpin = function (_Plugin) {
|
||||
babelHelpers.inherits(TouchSpin, _Plugin);
|
||||
|
||||
function TouchSpin() {
|
||||
babelHelpers.classCallCheck(this, TouchSpin);
|
||||
return babelHelpers.possibleConstructorReturn(this, (TouchSpin.__proto__ || Object.getPrototypeOf(TouchSpin)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(TouchSpin, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
verticalupclass: 'wb-plus',
|
||||
verticaldownclass: 'wb-minus',
|
||||
buttondown_class: 'btn btn-outline btn-default',
|
||||
buttonup_class: 'btn btn-outline btn-default'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return TouchSpin;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, TouchSpin);
|
||||
|
||||
exports.default = TouchSpin;
|
||||
});
|
||||
+87
@@ -0,0 +1,87 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/bootstrap-treeview', ['exports', 'jquery', 'Plugin', 'Config'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'), require('Config'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin, global.Config);
|
||||
global.PluginBootstrapTreeview = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2, _Config) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'treeview';
|
||||
|
||||
var Treeview = function (_Plugin) {
|
||||
babelHelpers.inherits(Treeview, _Plugin);
|
||||
|
||||
function Treeview() {
|
||||
babelHelpers.classCallCheck(this, Treeview);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Treeview.__proto__ || Object.getPrototypeOf(Treeview)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Treeview, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.treeview) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el,
|
||||
options = this.options;
|
||||
|
||||
if (typeof options.source === 'string' && _jquery2.default.isFunction(window[options.source])) {
|
||||
options.data = window[options.source]();
|
||||
delete options.source;
|
||||
} else if (_jquery2.default.isFunction(options.souce)) {
|
||||
options.data = options.source();
|
||||
delete options.source;
|
||||
}
|
||||
|
||||
$el.treeview(options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
injectStyle: false,
|
||||
expandIcon: 'icon wb-plus',
|
||||
collapseIcon: 'icon wb-minus',
|
||||
emptyIcon: 'icon',
|
||||
nodeIcon: 'icon wb-folder',
|
||||
showBorder: false,
|
||||
// color: undefined, // "#000000",
|
||||
// backColor: undefined, // "#FFFFFF",
|
||||
borderColor: (0, _Config.colors)('blue-grey', 200),
|
||||
onhoverColor: (0, _Config.colors)('blue-grey', 100),
|
||||
selectedColor: '#ffffff',
|
||||
selectedBackColor: (0, _Config.colors)('primary', 600),
|
||||
|
||||
searchResultColor: (0, _Config.colors)('primary', 600),
|
||||
searchResultBackColor: '#ffffff'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Treeview;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Treeview);
|
||||
|
||||
exports.default = Treeview;
|
||||
});
|
||||
+66
@@ -0,0 +1,66 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/card', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginCard = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'card';
|
||||
|
||||
var Card = function (_Plugin) {
|
||||
babelHelpers.inherits(Card, _Plugin);
|
||||
|
||||
function Card() {
|
||||
babelHelpers.classCallCheck(this, Card);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Card.__proto__ || Object.getPrototypeOf(Card)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Card, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.card) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el,
|
||||
options = this.options;
|
||||
|
||||
if (options.target) {
|
||||
options.container = (0, _jquery2.default)(options.target);
|
||||
}
|
||||
$el.card(options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return Card;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Card);
|
||||
|
||||
exports.default = Card;
|
||||
});
|
||||
+51
@@ -0,0 +1,51 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/clockpicker', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginClockpicker = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'clockpicker';
|
||||
|
||||
var Clockpicker = function (_Plugin) {
|
||||
babelHelpers.inherits(Clockpicker, _Plugin);
|
||||
|
||||
function Clockpicker() {
|
||||
babelHelpers.classCallCheck(this, Clockpicker);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Clockpicker.__proto__ || Object.getPrototypeOf(Clockpicker)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Clockpicker, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
donetext: 'Done'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Clockpicker;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Clockpicker);
|
||||
|
||||
exports.default = Clockpicker;
|
||||
});
|
||||
+107
@@ -0,0 +1,107 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/closeable-tabs', ['exports', 'jquery'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery);
|
||||
global.PluginCloseableTabs = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var pluginName = 'tabClose';
|
||||
var dismiss = '[data-close="tab"]';
|
||||
|
||||
var TabClose = function () {
|
||||
function TabClose(el) {
|
||||
babelHelpers.classCallCheck(this, TabClose);
|
||||
|
||||
(0, _jquery2.default)(el).on('click', dismiss, this.close);
|
||||
}
|
||||
|
||||
babelHelpers.createClass(TabClose, [{
|
||||
key: 'close',
|
||||
value: function close(e) {
|
||||
var $this = (0, _jquery2.default)(this);
|
||||
var $toggle = $this.closest('[data-toggle="tab"]');
|
||||
var selector = $toggle.data('target');
|
||||
var $li = $toggle.parent('li');
|
||||
|
||||
if (!selector) {
|
||||
selector = $toggle.attr('href');
|
||||
selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '');
|
||||
}
|
||||
|
||||
if ($toggle.hasClass('active')) {
|
||||
var $next = $li.siblings().eq(0).children('[data-toggle="tab"]');
|
||||
if ($next.length > 0) {
|
||||
var api = $next.tab().data('bs.tab');
|
||||
api.show();
|
||||
}
|
||||
}
|
||||
|
||||
var $parent = (0, _jquery2.default)(selector);
|
||||
if (e) e.preventDefault();
|
||||
|
||||
$parent.trigger(e = _jquery2.default.Event('close.bs.tab'));
|
||||
|
||||
if (e.isDefaultPrevented()) return;
|
||||
|
||||
$parent.removeClass('in');
|
||||
|
||||
function removeElement() {
|
||||
// detach from parent, fire event then clean up data
|
||||
$parent.detach().trigger('closed.bs.tab').remove();
|
||||
$li.detach().remove();
|
||||
}
|
||||
|
||||
_jquery2.default.support.transition && $parent.hasClass('fade') ? $parent.one('bsTransitionEnd', removeElement).emulateTransitionEnd(TabClose.TRANSITION_DURATION) : removeElement();
|
||||
}
|
||||
}], [{
|
||||
key: '_jQueryInterface',
|
||||
value: function _jQueryInterface(option) {
|
||||
console.log(option);
|
||||
return this.each(function () {
|
||||
var $this = (0, _jquery2.default)(this);
|
||||
var data = $this.data('bs.tab.close');
|
||||
|
||||
if (!data) {
|
||||
$this.data('bs.tab.close', data = new TabClose(this));
|
||||
}
|
||||
if (typeof option == 'string') {
|
||||
data[option].call($this);
|
||||
}
|
||||
});
|
||||
}
|
||||
}]);
|
||||
return TabClose;
|
||||
}();
|
||||
|
||||
TabClose.TRANSITION_DURATION = 150;
|
||||
|
||||
_jquery2.default.fn[pluginName] = TabClose._jQueryInterface;
|
||||
_jquery2.default.fn[pluginName].Constructor = TabClose;
|
||||
_jquery2.default.fn[pluginName].noConflict = function () {
|
||||
'use strict';
|
||||
|
||||
_jquery2.default.fn[pluginName] = window.JQUERY_NO_CONFLICT;
|
||||
return asSelectable._jQueryInterface;
|
||||
};
|
||||
|
||||
// TAB CLOSE DATA-API
|
||||
// ==================
|
||||
|
||||
(0, _jquery2.default)(document).on('click.bs.tab-close.data-api', dismiss, TabClose.prototype.close);
|
||||
|
||||
exports.default = TabClose;
|
||||
});
|
||||
+90
@@ -0,0 +1,90 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/datatables', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginDatatables = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'dataTable';
|
||||
|
||||
var DataTable = function (_Plugin) {
|
||||
babelHelpers.inherits(DataTable, _Plugin);
|
||||
|
||||
function DataTable() {
|
||||
babelHelpers.classCallCheck(this, DataTable);
|
||||
return babelHelpers.possibleConstructorReturn(this, (DataTable.__proto__ || Object.getPrototypeOf(DataTable)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(DataTable, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.dataTable) {
|
||||
return;
|
||||
}
|
||||
|
||||
// if ($.fn.dataTable.TableTools) {
|
||||
// // Set the classes that TableTools uses to something suitable for Bootstrap
|
||||
// $.extend(true, $.fn.dataTable.TableTools.classes, {
|
||||
// container: 'DTTT btn-group btn-group float-left',
|
||||
// buttons: {
|
||||
// normal: 'btn btn-outline btn-default',
|
||||
// disabled: 'disabled'
|
||||
// },
|
||||
// print: {
|
||||
// body: 'site-print DTTT_Print'
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
|
||||
this.$el.dataTable(this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
responsive: true,
|
||||
language: {
|
||||
lengthMenu: '_MENU_',
|
||||
searchPlaceholder: 'Search..',
|
||||
search: "_INPUT_"
|
||||
// ,paginate: {
|
||||
// previous: '<i class="icon wb-chevron-left-mini"></i>',
|
||||
// next: '<i class="icon wb-chevron-right-mini"></i>'
|
||||
// }
|
||||
|
||||
// ,
|
||||
// classes: {
|
||||
// sFilterInput: "form-control form-control-sm",
|
||||
// sLengthSelect: "form-control form-control-sm"
|
||||
// }
|
||||
} };
|
||||
}
|
||||
}]);
|
||||
return DataTable;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, DataTable);
|
||||
|
||||
exports.default = DataTable;
|
||||
});
|
||||
+54
@@ -0,0 +1,54 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/datepair', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginDatepair = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'datepair';
|
||||
|
||||
var Datepair = function (_Plugin) {
|
||||
babelHelpers.inherits(Datepair, _Plugin);
|
||||
|
||||
function Datepair() {
|
||||
babelHelpers.classCallCheck(this, Datepair);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Datepair.__proto__ || Object.getPrototypeOf(Datepair)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Datepair, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
startClass: 'datepair-start',
|
||||
endClass: 'datepair-end',
|
||||
timeClass: 'datepair-time',
|
||||
dateClass: 'datepair-date'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Datepair;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Datepair);
|
||||
|
||||
exports.default = Datepair;
|
||||
});
|
||||
+91
@@ -0,0 +1,91 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/donut', ['exports', 'Plugin', 'Config'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'), require('Config'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin, global.Config);
|
||||
global.PluginDonut = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2, _Config) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'donut';
|
||||
|
||||
var DonutPlugin = function (_Plugin) {
|
||||
babelHelpers.inherits(DonutPlugin, _Plugin);
|
||||
|
||||
function DonutPlugin() {
|
||||
babelHelpers.classCallCheck(this, DonutPlugin);
|
||||
return babelHelpers.possibleConstructorReturn(this, (DonutPlugin.__proto__ || Object.getPrototypeOf(DonutPlugin)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(DonutPlugin, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!Gauge) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el;
|
||||
var $canvas = $el.find('canvas'),
|
||||
$text = $el.find('.donut-label');
|
||||
|
||||
if ($canvas.length === 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
var donut = new Donut($canvas[0]).setOptions(this.options);
|
||||
|
||||
$el.data('donut', donut);
|
||||
|
||||
donut.animationSpeed = 50;
|
||||
donut.maxValue = $el.data('max-value');
|
||||
|
||||
donut.set($el.data('value'));
|
||||
|
||||
if ($text.length > 0) {
|
||||
donut.setTextField($text[0]);
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
lines: 12,
|
||||
angle: 0.3,
|
||||
lineWidth: 0.08,
|
||||
pointer: {
|
||||
length: 0.9,
|
||||
strokeWidth: 0.035,
|
||||
color: (0, _Config.colors)('blue-grey', 400)
|
||||
},
|
||||
limitMax: false, // If true, the pointer will not go past the end of the gauge
|
||||
colorStart: (0, _Config.colors)('blue-grey', 200),
|
||||
colorStop: (0, _Config.colors)('blue-grey', 200),
|
||||
strokeColor: (0, _Config.colors)('primary', 500),
|
||||
generateGradient: true
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return DonutPlugin;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, DonutPlugin);
|
||||
|
||||
exports.default = DonutPlugin;
|
||||
});
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/dropify', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginDropify = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'dropify';
|
||||
|
||||
var Dropify = function (_Plugin) {
|
||||
babelHelpers.inherits(Dropify, _Plugin);
|
||||
|
||||
function Dropify() {
|
||||
babelHelpers.classCallCheck(this, Dropify);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Dropify.__proto__ || Object.getPrototypeOf(Dropify)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Dropify, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return Dropify;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Dropify);
|
||||
|
||||
exports.default = Dropify;
|
||||
});
|
||||
+62
@@ -0,0 +1,62 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/editable-table', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginEditableTable = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'editableTable';
|
||||
|
||||
var EditableTable = function (_Plugin) {
|
||||
babelHelpers.inherits(EditableTable, _Plugin);
|
||||
|
||||
function EditableTable() {
|
||||
babelHelpers.classCallCheck(this, EditableTable);
|
||||
return babelHelpers.possibleConstructorReturn(this, (EditableTable.__proto__ || Object.getPrototypeOf(EditableTable)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(EditableTable, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.editableTableWidget) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el;
|
||||
|
||||
$el.editableTableWidget(this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return EditableTable;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, EditableTable);
|
||||
|
||||
exports.default = EditableTable;
|
||||
});
|
||||
+176
@@ -0,0 +1,176 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/editlist', ['exports', 'jquery', 'bootbox', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('bootbox'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.bootbox, global.Plugin);
|
||||
global.PluginEditlist = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _bootbox, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _bootbox2 = babelHelpers.interopRequireDefault(_bootbox);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var pluginName = 'editlist';
|
||||
var defaults = {};
|
||||
|
||||
var editlist = function () {
|
||||
function editlist(element, options) {
|
||||
babelHelpers.classCallCheck(this, editlist);
|
||||
|
||||
this.element = element;
|
||||
this.$element = (0, _jquery2.default)(element);
|
||||
this.$content = this.$element.find('.list-content');
|
||||
this.$text = this.$element.find('.list-text');
|
||||
this.$editable = this.$element.find('.list-editable');
|
||||
this.$editBtn = this.$element.find('[data-toggle=list-editable]');
|
||||
this.$delBtn = this.$element.find('[data-toggle=list-delete]');
|
||||
this.$closeBtn = this.$element.find('[data-toggle=list-editable-close]');
|
||||
this.$input = this.$element.find('input');
|
||||
this.options = _jquery2.default.extend({}, _Plugin3.default.defaults, options, this.$element.data());
|
||||
this.init();
|
||||
}
|
||||
|
||||
babelHelpers.createClass(editlist, [{
|
||||
key: 'init',
|
||||
value: function init() {
|
||||
this.bind();
|
||||
}
|
||||
}, {
|
||||
key: 'bind',
|
||||
value: function bind() {
|
||||
var self = this;
|
||||
this.$editBtn.on('click', function () {
|
||||
self.enable();
|
||||
});
|
||||
|
||||
this.$closeBtn.on('click', function () {
|
||||
self.disable();
|
||||
});
|
||||
|
||||
this.$delBtn.on('click', function () {
|
||||
if (typeof _bootbox2.default === 'undefined') return;
|
||||
_bootbox2.default.dialog({
|
||||
message: 'Do you want to delete the contact?',
|
||||
buttons: {
|
||||
success: {
|
||||
label: 'Delete',
|
||||
className: 'btn-danger',
|
||||
callback: function callback() {
|
||||
self.$element.remove();
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
this.$input.on('keydown', function (e) {
|
||||
var keycode = e.keyCode ? e.keyCode : e.which;
|
||||
|
||||
if (keycode == 13 || keycode == 27) {
|
||||
if (keycode == 13) {
|
||||
self.$text.html(self.$input.val());
|
||||
} else {
|
||||
self.$input.val(self.$text.text());
|
||||
}
|
||||
|
||||
self.disable();
|
||||
}
|
||||
});
|
||||
}
|
||||
}, {
|
||||
key: 'enable',
|
||||
value: function enable() {
|
||||
this.$content.hide();
|
||||
this.$editable.show();
|
||||
this.$input.focus().select();
|
||||
}
|
||||
}, {
|
||||
key: 'disable',
|
||||
value: function disable() {
|
||||
this.$content.show();
|
||||
this.$editable.hide();
|
||||
}
|
||||
}], [{
|
||||
key: '_jQueryInterface',
|
||||
value: function _jQueryInterface(options) {
|
||||
for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
||||
args[_key - 1] = arguments[_key];
|
||||
}
|
||||
|
||||
if (typeof options === 'string') {
|
||||
var method = options;
|
||||
|
||||
if (/^\_/.test(method)) {
|
||||
return false;
|
||||
} else if (/^(get)$/.test(method)) {
|
||||
var api = this.first().data(pluginName);
|
||||
if (api && typeof api[method] === 'function') {
|
||||
return api[method].apply(api, args);
|
||||
}
|
||||
} else {
|
||||
return this.each(function () {
|
||||
var api = _jquery2.default.data(this, pluginName);
|
||||
if (api && typeof api[method] === 'function') {
|
||||
api[method].apply(api, args);
|
||||
}
|
||||
});
|
||||
}
|
||||
} else {
|
||||
return this.each(function () {
|
||||
if (!_jquery2.default.data(this, pluginName)) {
|
||||
_jquery2.default.data(this, pluginName, new editlist(this, options));
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}]);
|
||||
return editlist;
|
||||
}();
|
||||
|
||||
_jquery2.default.fn[pluginName] = editlist._jQueryInterface;
|
||||
_jquery2.default.fn[pluginName].constructor = editlist;
|
||||
_jquery2.default.fn[pluginName].noConflict = function () {
|
||||
'use strict';
|
||||
|
||||
_jquery2.default.fn[pluginName] = window.JQUERY_NO_CONFLICT;
|
||||
return editlist._jQueryInterface;
|
||||
};
|
||||
|
||||
var Editlist = function (_Plugin) {
|
||||
babelHelpers.inherits(Editlist, _Plugin);
|
||||
|
||||
function Editlist() {
|
||||
babelHelpers.classCallCheck(this, Editlist);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Editlist.__proto__ || Object.getPrototypeOf(Editlist)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Editlist, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return pluginName;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return defaults;
|
||||
}
|
||||
}]);
|
||||
return Editlist;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(pluginName, Editlist);
|
||||
|
||||
exports.default = Editlist;
|
||||
});
|
||||
+95
@@ -0,0 +1,95 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/filterable', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginFilterable = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'filterable';
|
||||
|
||||
var Filterable = function (_Plugin) {
|
||||
babelHelpers.inherits(Filterable, _Plugin);
|
||||
|
||||
function Filterable() {
|
||||
babelHelpers.classCallCheck(this, Filterable);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Filterable.__proto__ || Object.getPrototypeOf(Filterable)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Filterable, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (typeof _jquery2.default.fn.isotope === 'undefined') {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el,
|
||||
options = _jquery2.default.extend(this.options, {
|
||||
filter: '*'
|
||||
});
|
||||
|
||||
this.$el.isotope(options);
|
||||
this.$filters = (0, _jquery2.default)(options.filters);
|
||||
|
||||
var self = this;
|
||||
|
||||
(0, _jquery2.default)('[data-filter]', this.$filters).on('click', function (e) {
|
||||
var $this = (0, _jquery2.default)(this);
|
||||
var $li = $this.parent('li');
|
||||
|
||||
$li.siblings().find('.nav-link.active').each(function () {
|
||||
(0, _jquery2.default)(this).attr('aria-expanded', false).removeClass('active');
|
||||
});
|
||||
|
||||
$this.addClass('active').attr('aria-expanded', true);
|
||||
|
||||
var filter = $this.attr('data-filter');
|
||||
if (filter !== '*') {
|
||||
filter = '[data-type="' + filter + '"]';
|
||||
}
|
||||
self.$el.isotope({
|
||||
filter: filter
|
||||
});
|
||||
|
||||
e.preventDefault();
|
||||
});
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
animationOptions: {
|
||||
duration: 750,
|
||||
easing: 'linear',
|
||||
queue: false
|
||||
}
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Filterable;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Filterable);
|
||||
|
||||
exports.default = Filterable;
|
||||
});
|
||||
+61
@@ -0,0 +1,61 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/floatthead', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginFloatthead = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'floatThead';
|
||||
|
||||
var FloatThead = function (_Plugin) {
|
||||
babelHelpers.inherits(FloatThead, _Plugin);
|
||||
|
||||
function FloatThead() {
|
||||
babelHelpers.classCallCheck(this, FloatThead);
|
||||
return babelHelpers.possibleConstructorReturn(this, (FloatThead.__proto__ || Object.getPrototypeOf(FloatThead)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(FloatThead, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
position: 'auto',
|
||||
top: function top() {
|
||||
var offset = (0, _jquery2.default)('.page').offset();
|
||||
|
||||
return offset.top;
|
||||
},
|
||||
responsiveContainer: function responsiveContainer($table) {
|
||||
return $table.closest('.table-responsive');
|
||||
}
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return FloatThead;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, FloatThead);
|
||||
|
||||
exports.default = FloatThead;
|
||||
});
|
||||
+72
@@ -0,0 +1,72 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/formatter', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginFormatter = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'formatter';
|
||||
|
||||
var Formatter = function (_Plugin) {
|
||||
babelHelpers.inherits(Formatter, _Plugin);
|
||||
|
||||
function Formatter() {
|
||||
babelHelpers.classCallCheck(this, Formatter);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Formatter.__proto__ || Object.getPrototypeOf(Formatter)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Formatter, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.formatter) {
|
||||
return;
|
||||
}
|
||||
|
||||
var browserName = navigator.userAgent.toLowerCase();
|
||||
|
||||
if (/msie/i.test(browserName) && !/opera/.test(browserName)) {} else {}
|
||||
|
||||
var $el = this.$el,
|
||||
options = this.options;
|
||||
|
||||
if (options.pattern) {
|
||||
options.pattern = options.pattern.replace(/\[\[/g, '{{').replace(/\]\]/g, '}}');
|
||||
}
|
||||
$el.formatter(options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
persistent: true
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Formatter;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Formatter);
|
||||
|
||||
exports.default = Formatter;
|
||||
});
|
||||
+91
@@ -0,0 +1,91 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/gauge', ['exports', 'Plugin', 'Config'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'), require('Config'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin, global.Config);
|
||||
global.PluginGauge = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2, _Config) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'gauge';
|
||||
|
||||
var GaugePlugin = function (_Plugin) {
|
||||
babelHelpers.inherits(GaugePlugin, _Plugin);
|
||||
|
||||
function GaugePlugin() {
|
||||
babelHelpers.classCallCheck(this, GaugePlugin);
|
||||
return babelHelpers.possibleConstructorReturn(this, (GaugePlugin.__proto__ || Object.getPrototypeOf(GaugePlugin)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(GaugePlugin, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!Gauge) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el;
|
||||
var $canvas = $el.find('canvas'),
|
||||
$text = $el.find('.gauge-label');
|
||||
|
||||
if ($canvas.length === 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
var gauge = new Gauge($canvas[0]).setOptions(this.options);
|
||||
|
||||
$el.data('gauge', gauge);
|
||||
|
||||
gauge.animationSpeed = 50;
|
||||
gauge.maxValue = $el.data('max-value');
|
||||
|
||||
gauge.set($el.data('value'));
|
||||
|
||||
if ($text.length > 0) {
|
||||
gauge.setTextField($text[0]);
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
lines: 12,
|
||||
angle: 0.2,
|
||||
lineWidth: 0.4,
|
||||
pointer: {
|
||||
length: 0.58,
|
||||
strokeWidth: 0.03,
|
||||
color: (0, _Config.colors)('blue-grey', 400)
|
||||
},
|
||||
limitMax: true,
|
||||
colorStart: (0, _Config.colors)('blue-grey', 200),
|
||||
colorStop: (0, _Config.colors)('blue-grey', 200),
|
||||
strokeColor: (0, _Config.colors)('primary', 500),
|
||||
generateGradient: true
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return GaugePlugin;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, GaugePlugin);
|
||||
|
||||
exports.default = GaugePlugin;
|
||||
});
|
||||
+250
@@ -0,0 +1,250 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/gmaps', ['exports', 'Plugin', 'Config'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'), require('Config'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin, global.Config);
|
||||
global.PluginGmaps = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2, _Config) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'gmaps';
|
||||
|
||||
var GmapsPlugin = function (_Plugin) {
|
||||
babelHelpers.inherits(GmapsPlugin, _Plugin);
|
||||
|
||||
function GmapsPlugin() {
|
||||
babelHelpers.classCallCheck(this, GmapsPlugin);
|
||||
return babelHelpers.possibleConstructorReturn(this, (GmapsPlugin.__proto__ || Object.getPrototypeOf(GmapsPlugin)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(GmapsPlugin, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
styles: [{
|
||||
featureType: 'landscape',
|
||||
elementType: 'all',
|
||||
stylers: [{
|
||||
color: '#ffffff'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'poi',
|
||||
elementType: 'all',
|
||||
stylers: [{
|
||||
color: '#ffffff'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'road',
|
||||
elementType: 'labels.text.fill',
|
||||
stylers: [{
|
||||
color: (0, _Config.colors)('blue-grey', '700')
|
||||
}]
|
||||
}, {
|
||||
featureType: 'administrative',
|
||||
elementType: 'labels.text.fill',
|
||||
stylers: [{
|
||||
color: (0, _Config.colors)('blue-grey', '500')
|
||||
}]
|
||||
}, {
|
||||
featureType: 'road.highway',
|
||||
elementType: 'geometry.fill',
|
||||
stylers: [{
|
||||
color: (0, _Config.colors)('blue-grey', '300')
|
||||
}]
|
||||
}, {
|
||||
featureType: 'road.arterial',
|
||||
elementType: 'geometry.fill',
|
||||
stylers: [{
|
||||
color: '#e0e0e0'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'water',
|
||||
elementType: 'geometry.fill',
|
||||
stylers: [{
|
||||
color: (0, _Config.colors)('blue-grey', '200')
|
||||
}]
|
||||
}, {
|
||||
featureType: 'water',
|
||||
elementType: 'labels.text.fill',
|
||||
stylers: [{
|
||||
color: '#000000'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'poi',
|
||||
elementType: 'labels.text.fill',
|
||||
stylers: [{
|
||||
color: (0, _Config.colors)('blue-grey', '500')
|
||||
}]
|
||||
}, {
|
||||
featureType: 'road',
|
||||
elementType: 'labels.text.stroke',
|
||||
stylers: [{
|
||||
visibility: 'off'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'poi.attraction',
|
||||
elementType: 'labels.text.stroke',
|
||||
stylers: [{
|
||||
visibility: 'off'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'poi',
|
||||
elementType: 'labels.text.stroke',
|
||||
stylers: [{
|
||||
visibility: 'off'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'road.local',
|
||||
elementType: 'all',
|
||||
stylers: [{
|
||||
color: (0, _Config.colors)('blue-grey', '200')
|
||||
}, {
|
||||
weight: 0.5
|
||||
}]
|
||||
}, {
|
||||
featureType: 'road.arterial',
|
||||
elementType: 'geometry',
|
||||
stylers: [{
|
||||
color: (0, _Config.colors)('blue-grey', '300')
|
||||
}]
|
||||
}, {
|
||||
featureType: 'road.arterial',
|
||||
elementType: 'geometry.stroke',
|
||||
stylers: [{
|
||||
visibility: 'off'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'road.highway',
|
||||
elementType: 'geometry.stroke',
|
||||
stylers: [{
|
||||
visibility: 'off'
|
||||
}, {
|
||||
color: '#000000'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'poi',
|
||||
elementType: 'all',
|
||||
stylers: [{
|
||||
visibility: 'off'
|
||||
}, {
|
||||
color: '#000000'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'poi',
|
||||
elementType: 'labels.text',
|
||||
stylers: [{
|
||||
visibility: 'on'
|
||||
}, {
|
||||
color: (0, _Config.colors)('blue-grey', '700')
|
||||
}]
|
||||
}, {
|
||||
featureType: 'road.local',
|
||||
elementType: 'labels.text',
|
||||
stylers: [{
|
||||
color: (0, _Config.colors)('blue-grey', '700')
|
||||
}]
|
||||
}, {
|
||||
featureType: 'transit',
|
||||
elementType: 'all',
|
||||
stylers: [{
|
||||
color: (0, _Config.colors)('blue-grey', '100')
|
||||
}]
|
||||
}, {
|
||||
featureType: 'transit.station',
|
||||
elementType: 'labels.text.fill',
|
||||
stylers: [{
|
||||
color: (0, _Config.colors)('blue-grey', '500')
|
||||
}]
|
||||
}, {
|
||||
featureType: 'road',
|
||||
elementType: 'labels.text.stroke',
|
||||
stylers: [{
|
||||
visibility: 'off'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'road',
|
||||
elementType: 'labels.text.fill',
|
||||
stylers: [{
|
||||
color: (0, _Config.colors)('blue-grey', '600')
|
||||
}]
|
||||
}, {
|
||||
featureType: 'administrative.neighborhood',
|
||||
elementType: 'labels.text',
|
||||
stylers: [{
|
||||
color: (0, _Config.colors)('blue-grey', '700')
|
||||
}]
|
||||
}, {
|
||||
featureType: 'poi',
|
||||
elementType: 'labels.text.stroke',
|
||||
stylers: [{
|
||||
color: '#ffffff'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'road.highway',
|
||||
elementType: 'labels.icon',
|
||||
stylers: [{
|
||||
visibility: 'on'
|
||||
}, {
|
||||
hue: '#ffffff'
|
||||
}, {
|
||||
saturation: -100
|
||||
}, {
|
||||
lightness: 50
|
||||
}]
|
||||
}, {
|
||||
featureType: 'water',
|
||||
elementType: 'labels.text.stroke',
|
||||
stylers: [{
|
||||
visibility: 'on'
|
||||
}, {
|
||||
color: '#ffffff'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'administrative.neighborhood',
|
||||
elementType: 'labels.text.stroke',
|
||||
stylers: [{
|
||||
color: '#ffffff'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'administrative',
|
||||
elementType: 'labels.text.stroke',
|
||||
stylers: [{
|
||||
color: '#ffffff'
|
||||
}]
|
||||
}, {
|
||||
featureType: 'water',
|
||||
elementType: 'labels.text.fill',
|
||||
stylers: [{
|
||||
color: (0, _Config.colors)('blue-grey', '600')
|
||||
}]
|
||||
}]
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return GmapsPlugin;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, GmapsPlugin);
|
||||
|
||||
exports.default = GmapsPlugin;
|
||||
});
|
||||
+65
@@ -0,0 +1,65 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/gridstack', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginGridstack = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'gridstack';
|
||||
|
||||
var Gridstack = function (_Plugin) {
|
||||
babelHelpers.inherits(Gridstack, _Plugin);
|
||||
|
||||
function Gridstack() {
|
||||
babelHelpers.classCallCheck(this, Gridstack);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Gridstack.__proto__ || Object.getPrototypeOf(Gridstack)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Gridstack, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.gridstack) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el;
|
||||
|
||||
$el.gridstack(this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
cellHeight: 80,
|
||||
verticalMargin: 20
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Gridstack;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Gridstack);
|
||||
|
||||
exports.default = Gridstack;
|
||||
});
|
||||
+56
@@ -0,0 +1,56 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/highlight', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginHighlight = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'highlight';
|
||||
|
||||
var Highlight = function (_Plugin) {
|
||||
babelHelpers.inherits(Highlight, _Plugin);
|
||||
|
||||
function Highlight() {
|
||||
babelHelpers.classCallCheck(this, Highlight);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Highlight.__proto__ || Object.getPrototypeOf(Highlight)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Highlight, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
hljs.initHighlightingOnLoad();
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return Highlight;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Highlight);
|
||||
|
||||
exports.default = Highlight;
|
||||
});
|
||||
+63
@@ -0,0 +1,63 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/html5sortable', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginHtml5sortable = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'sortable';
|
||||
|
||||
var Sortable = function (_Plugin) {
|
||||
babelHelpers.inherits(Sortable, _Plugin);
|
||||
|
||||
function Sortable() {
|
||||
babelHelpers.classCallCheck(this, Sortable);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Sortable.__proto__ || Object.getPrototypeOf(Sortable)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Sortable, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
sortable(this.$el.get(0), this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
connectWith: false,
|
||||
placeholder: null,
|
||||
// dragImage can be null or a Element
|
||||
dragImage: null,
|
||||
disableIEFix: false,
|
||||
placeholderClass: 'sortable-placeholder',
|
||||
draggingClass: 'sortable-dragging',
|
||||
hoverClass: false
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Sortable;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Sortable);
|
||||
|
||||
exports.default = Sortable;
|
||||
});
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/icheck', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginIcheck = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'iCheck';
|
||||
|
||||
var ICheck = function (_Plugin) {
|
||||
babelHelpers.inherits(ICheck, _Plugin);
|
||||
|
||||
function ICheck() {
|
||||
babelHelpers.classCallCheck(this, ICheck);
|
||||
return babelHelpers.possibleConstructorReturn(this, (ICheck.__proto__ || Object.getPrototypeOf(ICheck)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(ICheck, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return ICheck;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, ICheck);
|
||||
|
||||
exports.default = ICheck;
|
||||
});
|
||||
+69
@@ -0,0 +1,69 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/input-group-file', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginInputGroupFile = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'inputGroupFile';
|
||||
|
||||
var InputGroupFile = function (_Plugin) {
|
||||
babelHelpers.inherits(InputGroupFile, _Plugin);
|
||||
|
||||
function InputGroupFile() {
|
||||
babelHelpers.classCallCheck(this, InputGroupFile);
|
||||
return babelHelpers.possibleConstructorReturn(this, (InputGroupFile.__proto__ || Object.getPrototypeOf(InputGroupFile)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(InputGroupFile, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
this.$file = this.$el.find('[type=file]');
|
||||
this.$text = this.$el.find('.form-control');
|
||||
}
|
||||
}, {
|
||||
key: 'change',
|
||||
value: function change() {
|
||||
var value = '';
|
||||
_jquery2.default.each(this.$file[0].files, function (i, file) {
|
||||
value += file.name + ', ';
|
||||
});
|
||||
|
||||
value = value.substring(0, value.length - 2);
|
||||
|
||||
this.$text.val(value);
|
||||
}
|
||||
}], [{
|
||||
key: 'api',
|
||||
value: function api() {
|
||||
return 'change|change';
|
||||
}
|
||||
}]);
|
||||
return InputGroupFile;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, InputGroupFile);
|
||||
|
||||
exports.default = InputGroupFile;
|
||||
});
|
||||
+44
@@ -0,0 +1,44 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/ionrangeslider', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginIonrangeslider = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'ionRangeSlider';
|
||||
|
||||
var IonRangeSlider = function (_Plugin) {
|
||||
babelHelpers.inherits(IonRangeSlider, _Plugin);
|
||||
|
||||
function IonRangeSlider() {
|
||||
babelHelpers.classCallCheck(this, IonRangeSlider);
|
||||
return babelHelpers.possibleConstructorReturn(this, (IonRangeSlider.__proto__ || Object.getPrototypeOf(IonRangeSlider)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(IonRangeSlider, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}]);
|
||||
return IonRangeSlider;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, IonRangeSlider);
|
||||
|
||||
exports.default = IonRangeSlider;
|
||||
});
|
||||
+73
@@ -0,0 +1,73 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/isotope', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginIsotope = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'isotope';
|
||||
|
||||
var Isotope = function (_Plugin) {
|
||||
babelHelpers.inherits(Isotope, _Plugin);
|
||||
|
||||
function Isotope() {
|
||||
babelHelpers.classCallCheck(this, Isotope);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Isotope.__proto__ || Object.getPrototypeOf(Isotope)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Isotope, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
var _this2 = this;
|
||||
|
||||
if (typeof _jquery2.default.fn.isotope === 'undefined') {
|
||||
return;
|
||||
}
|
||||
|
||||
var callback = function callback() {
|
||||
var $el = _this2.$el;
|
||||
|
||||
$el.isotope(_this2.options);
|
||||
};
|
||||
if (this !== document) {
|
||||
callback();
|
||||
} else {
|
||||
(0, _jquery2.default)(window).on('load', function () {
|
||||
callback();
|
||||
});
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return Isotope;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Isotope);
|
||||
|
||||
exports.default = Isotope;
|
||||
});
|
||||
+82
@@ -0,0 +1,82 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/jquery-appear', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginJqueryAppear = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'appear';
|
||||
|
||||
var Appear = function (_Plugin) {
|
||||
babelHelpers.inherits(Appear, _Plugin);
|
||||
|
||||
function Appear() {
|
||||
babelHelpers.classCallCheck(this, Appear);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Appear.__proto__ || Object.getPrototypeOf(Appear)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Appear, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'bind',
|
||||
value: function bind() {
|
||||
var _this2 = this;
|
||||
|
||||
this.$el.on('appear', function () {
|
||||
if (_this2.$el.hasClass('appear-no-repeat')) {
|
||||
return;
|
||||
}
|
||||
_this2.$el.removeClass('invisible').addClass('animation-' + _this2.options.animate);
|
||||
|
||||
if (_this2.$el.data('repeat') === false) {
|
||||
_this2.$el.addClass('appear-no-repeat');
|
||||
}
|
||||
});
|
||||
|
||||
(0, _jquery2.default)(document).on('disappear', function () {
|
||||
if (_this2.$el.hasClass('appear-no-repeat')) {
|
||||
return;
|
||||
}
|
||||
|
||||
_this2.$el.addClass('invisible').removeClass('animation-' + _this2.options.animate);
|
||||
});
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.appear) {
|
||||
return;
|
||||
}
|
||||
|
||||
this.$el.appear(this.options);
|
||||
this.$el.not(':appeared').addClass('invisible');
|
||||
|
||||
this.bind();
|
||||
}
|
||||
}]);
|
||||
return Appear;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Appear);
|
||||
|
||||
exports.default = Appear;
|
||||
});
|
||||
+55
@@ -0,0 +1,55 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/jquery-knob', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginJqueryKnob = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'knob';
|
||||
|
||||
var Knob = function (_Plugin) {
|
||||
babelHelpers.inherits(Knob, _Plugin);
|
||||
|
||||
function Knob() {
|
||||
babelHelpers.classCallCheck(this, Knob);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Knob.__proto__ || Object.getPrototypeOf(Knob)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Knob, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
min: -50,
|
||||
max: 50,
|
||||
width: 120,
|
||||
height: 120,
|
||||
thickness: '.1'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Knob;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Knob);
|
||||
|
||||
exports.default = Knob;
|
||||
});
|
||||
+51
@@ -0,0 +1,51 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/jquery-labelauty', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginJqueryLabelauty = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'labelauty';
|
||||
|
||||
var Labelauty = function (_Plugin) {
|
||||
babelHelpers.inherits(Labelauty, _Plugin);
|
||||
|
||||
function Labelauty() {
|
||||
babelHelpers.classCallCheck(this, Labelauty);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Labelauty.__proto__ || Object.getPrototypeOf(Labelauty)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Labelauty, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
same_width: true
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Labelauty;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Labelauty);
|
||||
|
||||
exports.default = Labelauty;
|
||||
});
|
||||
+62
@@ -0,0 +1,62 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/jquery-placeholder', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginJqueryPlaceholder = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'placeholder';
|
||||
|
||||
var Placeholder = function (_Plugin) {
|
||||
babelHelpers.inherits(Placeholder, _Plugin);
|
||||
|
||||
function Placeholder() {
|
||||
babelHelpers.classCallCheck(this, Placeholder);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Placeholder.__proto__ || Object.getPrototypeOf(Placeholder)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Placeholder, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.placeholder) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el;
|
||||
|
||||
$el.placeholder();
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return Placeholder;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Placeholder);
|
||||
|
||||
exports.default = Placeholder;
|
||||
});
|
||||
+82
@@ -0,0 +1,82 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/jquery-strength', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginJqueryStrength = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'strength';
|
||||
|
||||
var Strength = function (_Plugin) {
|
||||
babelHelpers.inherits(Strength, _Plugin);
|
||||
|
||||
function Strength() {
|
||||
babelHelpers.classCallCheck(this, Strength);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Strength.__proto__ || Object.getPrototypeOf(Strength)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Strength, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
showMeter: true,
|
||||
showToggle: false,
|
||||
|
||||
templates: {
|
||||
toggle: '<div class="checkbox-custom checkbox-primary show-password-wrap"><input type="checkbox" class="{toggleClass}" title="Show/Hide Password" id="show_password" /><label for="show_password">Show Password</label></div>',
|
||||
meter: '<div class="{meterClass}">{score}</div>',
|
||||
score: '<div class="{scoreClass}"></div>',
|
||||
main: '<div class="{containerClass}">{input}{meter}{toggle}</div>'
|
||||
},
|
||||
|
||||
classes: {
|
||||
container: 'strength-container',
|
||||
status: 'strength-{status}',
|
||||
input: 'strength-input',
|
||||
toggle: 'strength-toggle',
|
||||
meter: 'strength-meter',
|
||||
score: 'strength-score'
|
||||
},
|
||||
|
||||
scoreLables: {
|
||||
invalid: 'Invalid',
|
||||
weak: 'Weak',
|
||||
good: 'Good',
|
||||
strong: 'Strong'
|
||||
},
|
||||
|
||||
scoreClasses: {
|
||||
invalid: 'strength-invalid',
|
||||
weak: 'strength-weak',
|
||||
good: 'strength-good',
|
||||
strong: 'strength-strong'
|
||||
}
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Strength;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Strength);
|
||||
|
||||
exports.default = Strength;
|
||||
});
|
||||
+75
@@ -0,0 +1,75 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/jquery-wizard', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginJqueryWizard = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'wizard';
|
||||
|
||||
var Wizard = function (_Plugin) {
|
||||
babelHelpers.inherits(Wizard, _Plugin);
|
||||
|
||||
function Wizard() {
|
||||
babelHelpers.classCallCheck(this, Wizard);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Wizard.__proto__ || Object.getPrototypeOf(Wizard)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Wizard, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
step: '.steps .step, .pearls .pearl',
|
||||
templates: {
|
||||
buttons: function buttons() {
|
||||
var options = this.options;
|
||||
return '<div class="wizard-buttons"><a class="btn btn-default btn-outline" href="#' + this.id + '" data-wizard="back" role="button">' + options.buttonLabels.back + '</a><a class="btn btn-primary btn-outline float-right" href="#' + this.id + '" data-wizard="next" role="button">' + options.buttonLabels.next + '</a><a class="btn btn-success btn-outline float-right" href="#' + this.id + '" data-wizard="finish" role="button">' + options.buttonLabels.finish + '</a></div>';
|
||||
}
|
||||
},
|
||||
classes: {
|
||||
step: {
|
||||
done: 'done',
|
||||
error: 'error',
|
||||
active: 'active',
|
||||
disabled: 'disabled',
|
||||
activing: 'activing',
|
||||
loading: 'loading'
|
||||
},
|
||||
pane: {
|
||||
active: 'active',
|
||||
activing: 'activing'
|
||||
},
|
||||
button: {
|
||||
hide: 'hidden-xs-up',
|
||||
disabled: 'disabled'
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Wizard;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Wizard);
|
||||
|
||||
exports.default = Wizard;
|
||||
});
|
||||
+44
@@ -0,0 +1,44 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/jstree', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginJstree = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'jstree';
|
||||
|
||||
var Jstree = function (_Plugin) {
|
||||
babelHelpers.inherits(Jstree, _Plugin);
|
||||
|
||||
function Jstree() {
|
||||
babelHelpers.classCallCheck(this, Jstree);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Jstree.__proto__ || Object.getPrototypeOf(Jstree)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Jstree, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}]);
|
||||
return Jstree;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Jstree);
|
||||
|
||||
exports.default = Jstree;
|
||||
});
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/jt-timepicker', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginJtTimepicker = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'timepicker';
|
||||
|
||||
var Timepicker = function (_Plugin) {
|
||||
babelHelpers.inherits(Timepicker, _Plugin);
|
||||
|
||||
function Timepicker() {
|
||||
babelHelpers.classCallCheck(this, Timepicker);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Timepicker.__proto__ || Object.getPrototypeOf(Timepicker)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Timepicker, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return Timepicker;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Timepicker);
|
||||
|
||||
exports.default = Timepicker;
|
||||
});
|
||||
+79
@@ -0,0 +1,79 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/jvectormap', ['exports', 'Plugin', 'Config'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'), require('Config'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin, global.Config);
|
||||
global.PluginJvectormap = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2, _Config) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'vectorMap';
|
||||
|
||||
var VectorMap = function (_Plugin) {
|
||||
babelHelpers.inherits(VectorMap, _Plugin);
|
||||
|
||||
function VectorMap() {
|
||||
babelHelpers.classCallCheck(this, VectorMap);
|
||||
return babelHelpers.possibleConstructorReturn(this, (VectorMap.__proto__ || Object.getPrototypeOf(VectorMap)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(VectorMap, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
map: 'world_mill',
|
||||
backgroundColor: '#fff',
|
||||
zoomAnimate: true,
|
||||
regionStyle: {
|
||||
initial: {
|
||||
fill: (0, _Config.colors)('primary', 600)
|
||||
},
|
||||
hover: {
|
||||
fill: (0, _Config.colors)('primary', 500)
|
||||
},
|
||||
selected: {
|
||||
fill: (0, _Config.colors)('primary', 800)
|
||||
},
|
||||
selectedHover: {
|
||||
fill: (0, _Config.colors)('primary', 500)
|
||||
}
|
||||
},
|
||||
markerStyle: {
|
||||
initial: {
|
||||
r: 8,
|
||||
fill: (0, _Config.colors)('red', 600),
|
||||
'stroke-width': 0
|
||||
},
|
||||
hover: {
|
||||
r: 12,
|
||||
stroke: (0, _Config.colors)('red', 600),
|
||||
'stroke-width': 0
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return VectorMap;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, VectorMap);
|
||||
|
||||
exports.default = VectorMap;
|
||||
});
|
||||
+75
@@ -0,0 +1,75 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/ladda', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginLadda = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'ladda';
|
||||
|
||||
var LaddaPlugin = function (_Plugin) {
|
||||
babelHelpers.inherits(LaddaPlugin, _Plugin);
|
||||
|
||||
function LaddaPlugin() {
|
||||
babelHelpers.classCallCheck(this, LaddaPlugin);
|
||||
return babelHelpers.possibleConstructorReturn(this, (LaddaPlugin.__proto__ || Object.getPrototypeOf(LaddaPlugin)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(LaddaPlugin, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (typeof Ladda === 'undefined') {
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.options.type === 'progress') {
|
||||
this.options.callback = function (instance) {
|
||||
var progress = 0;
|
||||
var interval = setInterval(function () {
|
||||
progress = Math.min(progress + Math.random() * 0.1, 1);
|
||||
instance.setProgress(progress);
|
||||
|
||||
if (progress === 1) {
|
||||
instance.stop();
|
||||
clearInterval(interval);
|
||||
}
|
||||
}, 200);
|
||||
};
|
||||
}
|
||||
Ladda.bind(this.$el[0], this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
type: 'normal',
|
||||
timeout: 2000
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return LaddaPlugin;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, LaddaPlugin);
|
||||
|
||||
exports.default = LaddaPlugin;
|
||||
});
|
||||
+82
@@ -0,0 +1,82 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/loading-button', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginLoadingButton = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'loadingButton';
|
||||
|
||||
var LoadingButton = function (_Plugin) {
|
||||
babelHelpers.inherits(LoadingButton, _Plugin);
|
||||
|
||||
function LoadingButton() {
|
||||
babelHelpers.classCallCheck(this, LoadingButton);
|
||||
return babelHelpers.possibleConstructorReturn(this, (LoadingButton.__proto__ || Object.getPrototypeOf(LoadingButton)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(LoadingButton, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
this.text = this.$el.text();
|
||||
this.$el.data('loadingButtonApi', this);
|
||||
}
|
||||
}, {
|
||||
key: 'loading',
|
||||
value: function loading() {
|
||||
var $el = this.$el,
|
||||
i = this.options.time,
|
||||
loadingText = this.options.loadingText,
|
||||
opacity = this.options.opacity;
|
||||
|
||||
$el.text(loadingText + '(' + i + ')').css('opacity', opacity);
|
||||
|
||||
var timeout = setInterval(function () {
|
||||
$el.text(loadingText + '(' + --i + ')');
|
||||
if (i === 0) {
|
||||
clearInterval(timeout);
|
||||
$el.text(text).css('opacity', '1');
|
||||
}
|
||||
}, 1000);
|
||||
}
|
||||
}], [{
|
||||
key: 'api',
|
||||
value: function api() {
|
||||
return 'click|loading';
|
||||
}
|
||||
}, {
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
loadingText: 'Loading',
|
||||
time: 20,
|
||||
opacity: '0.6'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return LoadingButton;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, LoadingButton);
|
||||
|
||||
exports.default = LoadingButton;
|
||||
});
|
||||
+55
@@ -0,0 +1,55 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/magnific-popup', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginMagnificPopup = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'magnificPopup';
|
||||
|
||||
var MagnificPopup = function (_Plugin) {
|
||||
babelHelpers.inherits(MagnificPopup, _Plugin);
|
||||
|
||||
function MagnificPopup() {
|
||||
babelHelpers.classCallCheck(this, MagnificPopup);
|
||||
return babelHelpers.possibleConstructorReturn(this, (MagnificPopup.__proto__ || Object.getPrototypeOf(MagnificPopup)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(MagnificPopup, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
type: 'image',
|
||||
closeOnContentClick: true,
|
||||
image: {
|
||||
verticalFit: true
|
||||
}
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return MagnificPopup;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, MagnificPopup);
|
||||
|
||||
exports.default = MagnificPopup;
|
||||
});
|
||||
+69
@@ -0,0 +1,69 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/masonry', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginMasonry = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'masonry';
|
||||
|
||||
var Masonry = function (_Plugin) {
|
||||
babelHelpers.inherits(Masonry, _Plugin);
|
||||
|
||||
function Masonry() {
|
||||
babelHelpers.classCallCheck(this, Masonry);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Masonry.__proto__ || Object.getPrototypeOf(Masonry)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Masonry, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (typeof _jquery2.default.fn.masonry === 'undefined') {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el;
|
||||
if (_jquery2.default.fn.imagesLoaded) {
|
||||
$el.imagesLoaded(function () {
|
||||
$el.masonry(this.options);
|
||||
});
|
||||
} else {
|
||||
$el.masonry(this.options);
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
itemSelector: '.masonry-item'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Masonry;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Masonry);
|
||||
|
||||
exports.default = Masonry;
|
||||
});
|
||||
+67
@@ -0,0 +1,67 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/matchheight', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginMatchheight = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'matchHeight';
|
||||
|
||||
var MatchHeight = function (_Plugin) {
|
||||
babelHelpers.inherits(MatchHeight, _Plugin);
|
||||
|
||||
function MatchHeight() {
|
||||
babelHelpers.classCallCheck(this, MatchHeight);
|
||||
return babelHelpers.possibleConstructorReturn(this, (MatchHeight.__proto__ || Object.getPrototypeOf(MatchHeight)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(MatchHeight, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (typeof _jquery2.default.fn.matchHeight === 'undefined') {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el,
|
||||
matchSelector = $el.data('matchSelector');
|
||||
|
||||
if (matchSelector) {
|
||||
$el.find(matchSelector).matchHeight(this.options);
|
||||
} else {
|
||||
$el.children().matchHeight(this.options);
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return MatchHeight;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, MatchHeight);
|
||||
|
||||
exports.default = MatchHeight;
|
||||
});
|
||||
+132
@@ -0,0 +1,132 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/material', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginMaterial = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'formMaterial';
|
||||
|
||||
function isChar(e) {
|
||||
if (typeof e.which === 'undefined') {
|
||||
return true;
|
||||
} else if (typeof e.which === 'number' && e.which > 0) {
|
||||
return !e.ctrlKey && !e.metaKey && !e.altKey && e.which !== 8 && e.which !== 9;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
var FormMaterial = function (_Plugin) {
|
||||
babelHelpers.inherits(FormMaterial, _Plugin);
|
||||
|
||||
function FormMaterial() {
|
||||
babelHelpers.classCallCheck(this, FormMaterial);
|
||||
return babelHelpers.possibleConstructorReturn(this, (FormMaterial.__proto__ || Object.getPrototypeOf(FormMaterial)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(FormMaterial, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
var $el = this.$el;
|
||||
|
||||
var $control = this.$control = $el.find('.form-control');
|
||||
|
||||
// Add hint label if required
|
||||
if ($control.attr('data-hint')) {
|
||||
$control.after('<div class=hint>' + $control.attr('data-hint') + '</div>');
|
||||
}
|
||||
|
||||
if ($el.hasClass('floating')) {
|
||||
// Add floating label if required
|
||||
if ($control.hasClass('floating-label')) {
|
||||
var placeholder = $control.attr('placeholder');
|
||||
$control.attr('placeholder', null).removeClass('floating-label');
|
||||
$control.after('<div class=floating-label>' + placeholder + '</div>');
|
||||
}
|
||||
|
||||
// Set as empty if is empty
|
||||
if ($control.val() === null || $control.val() === 'undefined' || $control.val() === '') {
|
||||
$control.addClass('empty');
|
||||
}
|
||||
}
|
||||
|
||||
// Support for file input
|
||||
if ($control.next().is('[type=file]')) {
|
||||
$el.addClass('form-material-file');
|
||||
}
|
||||
|
||||
this.$file = $el.find('[type=file]');
|
||||
this.bind();
|
||||
$el.data('formMaterialAPI', this);
|
||||
}
|
||||
}, {
|
||||
key: 'bind',
|
||||
value: function bind() {
|
||||
var _this2 = this;
|
||||
|
||||
var $el = this.$el;
|
||||
var $control = this.$control = $el.find('.form-control');
|
||||
|
||||
$el.on('keydown.site.material paste.site.material', '.form-control', function (e) {
|
||||
if (isChar(e)) {
|
||||
$control.removeClass('empty');
|
||||
}
|
||||
}).on('keyup.site.material change.site.material', '.form-control', function () {
|
||||
if ($control.val() === '' && typeof $control[0].checkValidity !== 'undefined' && $control[0].checkValidity()) {
|
||||
$control.addClass('empty');
|
||||
} else {
|
||||
$control.removeClass('empty');
|
||||
}
|
||||
});
|
||||
|
||||
if (this.$file.length > 0) {
|
||||
this.$file.on('focus', function () {
|
||||
_this2.$el.find('input').addClass('focus');
|
||||
}).on('blur', function () {
|
||||
_this2.$el.find('input').removeClass('focus');
|
||||
}).on('change', function () {
|
||||
var $this = (0, _jquery2.default)(this);
|
||||
var value = '';
|
||||
|
||||
_jquery2.default.each($this[0].files, function (i, file) {
|
||||
value += file.name + ', ';
|
||||
});
|
||||
value = value.substring(0, value.length - 2);
|
||||
if (value) {
|
||||
$this.prev().removeClass('empty');
|
||||
} else {
|
||||
$this.prev().addClass('empty');
|
||||
}
|
||||
$this.prev().val(value);
|
||||
});
|
||||
}
|
||||
}
|
||||
}]);
|
||||
return FormMaterial;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, FormMaterial);
|
||||
|
||||
exports.default = FormMaterial;
|
||||
});
|
||||
+225
@@ -0,0 +1,225 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/menu', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginMenu = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'menu';
|
||||
|
||||
var Menu = function (_Plugin) {
|
||||
babelHelpers.inherits(Menu, _Plugin);
|
||||
|
||||
function Menu() {
|
||||
var _ref;
|
||||
|
||||
babelHelpers.classCallCheck(this, Menu);
|
||||
|
||||
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
|
||||
args[_key] = arguments[_key];
|
||||
}
|
||||
|
||||
var _this = babelHelpers.possibleConstructorReturn(this, (_ref = Menu.__proto__ || Object.getPrototypeOf(Menu)).call.apply(_ref, [this].concat(args)));
|
||||
|
||||
_this.folded = true;
|
||||
_this.foldAlt = true;
|
||||
_this.outerHeight = 0;
|
||||
return _this;
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Menu, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
this.bindEvents();
|
||||
this.$el.data('menuApi', this);
|
||||
}
|
||||
}, {
|
||||
key: 'bindEvents',
|
||||
value: function bindEvents() {
|
||||
var self = this;
|
||||
|
||||
this.$el.on('mouseenter.site.menu', '.site-menu-item', function () {
|
||||
var $item = $(this);
|
||||
if (self.folded === true && $item.is('.has-sub') && $item.parent('.site-menu').length > 0) {
|
||||
var $sub = $item.children('.site-menu-sub');
|
||||
self.position($item, $sub);
|
||||
}
|
||||
$item.addClass('hover');
|
||||
}).on('mouseleave.site.menu', '.site-menu-item', function () {
|
||||
var $item = $(this);
|
||||
if (self.folded === true && $item.is('.has-sub') && $item.parent('.site-menu').length > 0) {
|
||||
$item.children('.site-menu-sub').css('max-height', '');
|
||||
$item.removeClass('open');
|
||||
}
|
||||
$item.removeClass('hover');
|
||||
}).on('deactive.site.menu', '.site-menu-item.active', function (e) {
|
||||
$(this).removeClass('active');
|
||||
|
||||
e.stopPropagation();
|
||||
}).on('active.site.menu', '.site-menu-item', function (e) {
|
||||
$(this).addClass('active');
|
||||
|
||||
e.stopPropagation();
|
||||
}).on('open.site.menu', '.site-menu-item', function (e) {
|
||||
var $item = $(this);
|
||||
|
||||
self.expand($item, function () {
|
||||
$item.addClass('open');
|
||||
});
|
||||
|
||||
if (self.options.accordion) {
|
||||
$item.siblings('.open').trigger('close.site.menu');
|
||||
}
|
||||
|
||||
e.stopPropagation();
|
||||
}).on('close.site.menu', '.site-menu-item.open', function (e) {
|
||||
var $item = $(this);
|
||||
|
||||
self.collapse($item, function () {
|
||||
$item.removeClass('open');
|
||||
});
|
||||
|
||||
e.stopPropagation();
|
||||
}).on('click.site.menu ', '.site-menu-item', function (e) {
|
||||
var $item = $(this);
|
||||
|
||||
if ($item.is('.has-sub') && $(e.target).closest('.site-menu-item').is(this)) {
|
||||
if ($item.is('.open')) {
|
||||
$item.trigger('close.site.menu');
|
||||
} else {
|
||||
$item.trigger('open.site.menu');
|
||||
}
|
||||
} else if (!$item.is('.active')) {
|
||||
$item.siblings('.active').trigger('deactive.site.menu');
|
||||
$item.trigger('active.site.menu');
|
||||
}
|
||||
|
||||
e.stopPropagation();
|
||||
}).on('tap.site.menu', '> .site-menu-item > a', function () {
|
||||
var link = $(this).attr('href');
|
||||
|
||||
if (link) {
|
||||
window.location = link;
|
||||
}
|
||||
}).on('touchend.site.menu', '> .site-menu-item > a', function () {
|
||||
var $item = $(this).parent('.site-menu-item');
|
||||
|
||||
if (self.folded === true) {
|
||||
if ($item.is('.has-sub') && $item.parent('.site-menu').length > 0) {
|
||||
$item.siblings('.hover').removeClass('hover');
|
||||
|
||||
if ($item.is('.hover')) {
|
||||
$item.removeClass('hover');
|
||||
} else {
|
||||
$item.addClass('hover');
|
||||
}
|
||||
}
|
||||
}
|
||||
}).on('scroll.site.menu', '.site-menu-sub', function (e) {
|
||||
e.stopPropagation();
|
||||
});
|
||||
}
|
||||
}, {
|
||||
key: 'collapse',
|
||||
value: function collapse($item, callback) {
|
||||
var self = this;
|
||||
var $sub = $item.children('.site-menu-sub');
|
||||
|
||||
$sub.show().slideUp(this.options.speed, function () {
|
||||
$(this).css('display', '');
|
||||
|
||||
$(this).find('> .site-menu-item').removeClass('is-shown');
|
||||
|
||||
if (callback) {
|
||||
callback();
|
||||
}
|
||||
|
||||
self.$el.trigger('collapsed.site.menu');
|
||||
});
|
||||
}
|
||||
}, {
|
||||
key: 'expand',
|
||||
value: function expand($item, callback) {
|
||||
var self = this;
|
||||
var $sub = $item.children('.site-menu-sub');
|
||||
var $children = $sub.children('.site-menu-item').addClass('is-hidden');
|
||||
|
||||
$sub.hide().slideDown(this.options.speed, function () {
|
||||
$(this).css('display', '');
|
||||
|
||||
if (callback) {
|
||||
callback();
|
||||
}
|
||||
|
||||
self.$el.trigger('expanded.site.menu');
|
||||
});
|
||||
|
||||
setTimeout(function () {
|
||||
$children.addClass('is-shown');
|
||||
$children.removeClass('is-hidden');
|
||||
}, 0);
|
||||
}
|
||||
}, {
|
||||
key: 'refresh',
|
||||
value: function refresh() {
|
||||
this.$el.find('.open').filter(':not(.active)').removeClass('open');
|
||||
}
|
||||
}, {
|
||||
key: 'position',
|
||||
value: function position($item, $dropdown) {
|
||||
var itemHeight = $item.find('> a').outerHeight(),
|
||||
menubarHeight = this.outerHeight,
|
||||
offsetTop = $item.position().top;
|
||||
|
||||
$dropdown.removeClass('site-menu-sub-up').css('max-height', '');
|
||||
|
||||
if (offsetTop > menubarHeight / 2) {
|
||||
$dropdown.addClass('site-menu-sub-up');
|
||||
|
||||
if (this.foldAlt) {
|
||||
offsetTop -= itemHeight;
|
||||
}
|
||||
$dropdown.css('max-height', offsetTop + itemHeight);
|
||||
} else {
|
||||
if (this.foldAlt) {
|
||||
offsetTop += itemHeight;
|
||||
}
|
||||
$dropdown.removeClass('site-menu-sub-up');
|
||||
$dropdown.css('max-height', menubarHeight - offsetTop);
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
speed: 250,
|
||||
accordion: true
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Menu;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Menu);
|
||||
|
||||
exports.default = Menu;
|
||||
});
|
||||
+69
@@ -0,0 +1,69 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/more-button', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginMoreButton = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'moreButton';
|
||||
|
||||
var MoreButton = function (_Plugin) {
|
||||
babelHelpers.inherits(MoreButton, _Plugin);
|
||||
|
||||
function MoreButton() {
|
||||
babelHelpers.classCallCheck(this, MoreButton);
|
||||
return babelHelpers.possibleConstructorReturn(this, (MoreButton.__proto__ || Object.getPrototypeOf(MoreButton)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(MoreButton, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
this.$target = (0, _jquery2.default)(this.options.more);
|
||||
this.$el.data('moreButtonApi', this);
|
||||
}
|
||||
}, {
|
||||
key: 'toggle',
|
||||
value: function toggle() {
|
||||
this.$target.toggle();
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
more: ''
|
||||
};
|
||||
}
|
||||
}, {
|
||||
key: 'api',
|
||||
value: function api() {
|
||||
return 'click|toggle';
|
||||
}
|
||||
}]);
|
||||
return MoreButton;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, MoreButton);
|
||||
|
||||
exports.default = MoreButton;
|
||||
});
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/multi-select', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginMultiSelect = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'multiSelect';
|
||||
|
||||
var MultiSelect = function (_Plugin) {
|
||||
babelHelpers.inherits(MultiSelect, _Plugin);
|
||||
|
||||
function MultiSelect() {
|
||||
babelHelpers.classCallCheck(this, MultiSelect);
|
||||
return babelHelpers.possibleConstructorReturn(this, (MultiSelect.__proto__ || Object.getPrototypeOf(MultiSelect)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(MultiSelect, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return MultiSelect;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, MultiSelect);
|
||||
|
||||
exports.default = MultiSelect;
|
||||
});
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/nestable', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginNestable = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'nestable';
|
||||
|
||||
var Nestable = function (_Plugin) {
|
||||
babelHelpers.inherits(Nestable, _Plugin);
|
||||
|
||||
function Nestable() {
|
||||
babelHelpers.classCallCheck(this, Nestable);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Nestable.__proto__ || Object.getPrototypeOf(Nestable)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Nestable, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return Nestable;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Nestable);
|
||||
|
||||
exports.default = Nestable;
|
||||
});
|
||||
+109
@@ -0,0 +1,109 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/notie-js', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginNotieJs = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'notie';
|
||||
|
||||
var Notie = function (_Plugin) {
|
||||
babelHelpers.inherits(Notie, _Plugin);
|
||||
|
||||
function Notie() {
|
||||
babelHelpers.classCallCheck(this, Notie);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Notie.__proto__ || Object.getPrototypeOf(Notie)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Notie, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
this.$el.data('notieApi', this);
|
||||
}
|
||||
}, {
|
||||
key: 'show',
|
||||
value: function show() {
|
||||
var options = this.options;
|
||||
|
||||
if (options.type !== undefined) {
|
||||
if (options.type === 'confirm') {
|
||||
notie.confirm(options.text, options.yesText, options.noText, function () {
|
||||
notie.alert(1, options.yesMsg, 1.5);
|
||||
}, function () {
|
||||
notie.alert(3, options.noMsg, 1.5);
|
||||
});
|
||||
}
|
||||
|
||||
if (options.type === 'input') {
|
||||
notie.input({
|
||||
type: options.inputType,
|
||||
placeholder: options.placeholder,
|
||||
prefilledValue: options.prefilledvalue
|
||||
}, options.text, options.yesText, options.noText, function (valueInput) {
|
||||
notie.alert(1, 'you entered: ' + valueInput, 1.5);
|
||||
}, function (valueInput) {
|
||||
notie.alert(3, 'You cancelled with this value: ' + valueInput, 2);
|
||||
});
|
||||
}
|
||||
|
||||
if (options.type === 'success') {
|
||||
notie.alert(1, options.text, options.delay);
|
||||
}
|
||||
|
||||
if (options.type === 'warning') {
|
||||
notie.alert(2, options.text, options.delay);
|
||||
}
|
||||
|
||||
if (options.type === 'error') {
|
||||
notie.alert(3, options.text, options.delay);
|
||||
}
|
||||
|
||||
if (options.type === 'info') {
|
||||
notie.alert(4, options.text, options.delay);
|
||||
}
|
||||
|
||||
if (options.animationdelay !== undefined && typeof options.animationdelay === 'number') {
|
||||
notie.setOptions({
|
||||
animationDelay: options.animationDelay
|
||||
});
|
||||
}
|
||||
|
||||
if (options.bgclickdismiss !== undefined && typeof options.bgclickdismiss === 'boolean') {
|
||||
notie.setOptions({
|
||||
backgroundClickDismiss: options.bgclickdismiss
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'api',
|
||||
value: function api() {
|
||||
return 'click|show';
|
||||
}
|
||||
}]);
|
||||
return Notie;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Notie);
|
||||
|
||||
exports.default = Notie;
|
||||
});
|
||||
+64
@@ -0,0 +1,64 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/nprogress', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginNprogress = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'nprogress';
|
||||
|
||||
var Nprogress = function (_Plugin) {
|
||||
babelHelpers.inherits(Nprogress, _Plugin);
|
||||
|
||||
function Nprogress() {
|
||||
babelHelpers.classCallCheck(this, Nprogress);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Nprogress.__proto__ || Object.getPrototypeOf(Nprogress)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Nprogress, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (typeof NProgress === 'undefined') {
|
||||
return;
|
||||
}
|
||||
|
||||
NProgress.configure(this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
minimum: 0.15,
|
||||
trickleRate: 0.07,
|
||||
trickleSpeed: 360,
|
||||
showSpinner: false,
|
||||
template: '<div class="bar" role="bar"></div><div class="spinner" role="spinner"><div class="spinner-icon"></div></div>'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Nprogress;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Nprogress);
|
||||
|
||||
exports.default = Nprogress;
|
||||
});
|
||||
+63
@@ -0,0 +1,63 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/owl-carousel', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginOwlCarousel = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'owlCarousel';
|
||||
|
||||
var OwlCarousel = function (_Plugin) {
|
||||
babelHelpers.inherits(OwlCarousel, _Plugin);
|
||||
|
||||
function OwlCarousel() {
|
||||
babelHelpers.classCallCheck(this, OwlCarousel);
|
||||
return babelHelpers.possibleConstructorReturn(this, (OwlCarousel.__proto__ || Object.getPrototypeOf(OwlCarousel)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(OwlCarousel, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
// autoWidth: true,
|
||||
loop: true,
|
||||
nav: true,
|
||||
dots: false,
|
||||
dotsClass: 'owl-dots owl-dots-fall',
|
||||
responsive: {
|
||||
0: {
|
||||
items: 1
|
||||
},
|
||||
600: {
|
||||
items: 3
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return OwlCarousel;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, OwlCarousel);
|
||||
|
||||
exports.default = OwlCarousel;
|
||||
});
|
||||
+248
@@ -0,0 +1,248 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/panel', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginPanel = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'panel';
|
||||
|
||||
function getPanelAPI($el) {
|
||||
if ($el.length <= 0) return;
|
||||
var api = $el.data('panelAPI');
|
||||
|
||||
if (api) return api;
|
||||
|
||||
api = new Panel($el, _jquery2.default.extend(true, {}, Panel.getDefaults(), $el.data()));
|
||||
api.render();
|
||||
return api;
|
||||
}
|
||||
|
||||
var Panel = function (_Plugin) {
|
||||
babelHelpers.inherits(Panel, _Plugin);
|
||||
|
||||
function Panel() {
|
||||
babelHelpers.classCallCheck(this, Panel);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Panel.__proto__ || Object.getPrototypeOf(Panel)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Panel, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render(context) {
|
||||
var $el = this.$el;
|
||||
|
||||
this.isFullscreen = false;
|
||||
this.isClose = false;
|
||||
this.isCollapse = false;
|
||||
this.isLoading = false;
|
||||
|
||||
this.$panelBody = $el.find('.panel-body');
|
||||
this.$fullscreen = $el.find('[data-toggle="panel-fullscreen"]');
|
||||
this.$collapse = $el.find('[data-toggle="panel-collapse"]');
|
||||
this.$loading = null;
|
||||
if ($el.hasClass('is-collapse')) {
|
||||
this.isCollapse = true;
|
||||
}
|
||||
|
||||
if (typeof this.options.loadCallback === 'string') {
|
||||
this.options.loadCallback = window[this.options.loadCallback];
|
||||
}
|
||||
|
||||
$el.data('panelAPI', this);
|
||||
}
|
||||
}, {
|
||||
key: 'load',
|
||||
value: function load(callback) {
|
||||
var $el = this.$el,
|
||||
type = $el.data('loader-type');
|
||||
if (!type) {
|
||||
type = 'default';
|
||||
}
|
||||
|
||||
callback = callback || this.options.loadCallback;
|
||||
|
||||
this.$loading = (0, _jquery2.default)('<div class="panel-loading">\n <div class="loader loader-' + type + '"></div>\n </div>').appendTo($el);
|
||||
$el.addClass('is-loading');
|
||||
$el.trigger('loading.uikit.panel');
|
||||
this.isLoading = true;
|
||||
|
||||
if (typeof callback === 'function') {
|
||||
callback.call(this);
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'done',
|
||||
value: function done() {
|
||||
if (this.isLoading === true) {
|
||||
this.$loading.remove();
|
||||
this.$el.removeClass('is-loading');
|
||||
this.$el.trigger('loading.done.uikit.panel');
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'toggleContent',
|
||||
value: function toggleContent() {
|
||||
if (this.isCollapse) {
|
||||
this.showContent();
|
||||
} else {
|
||||
this.hideContent();
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'showContent',
|
||||
value: function showContent() {
|
||||
if (this.isCollapse !== false) {
|
||||
this.$el.removeClass('is-collapse');
|
||||
|
||||
if (this.$collapse.hasClass('wb-plus')) {
|
||||
this.$collapse.removeClass('wb-plus').addClass('wb-minus');
|
||||
}
|
||||
|
||||
this.$el.trigger('shown.uikit.panel');
|
||||
|
||||
this.isCollapse = false;
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'hideContent',
|
||||
value: function hideContent() {
|
||||
if (this.isCollapse !== true) {
|
||||
this.$el.addClass('is-collapse');
|
||||
|
||||
if (this.$collapse.hasClass('wb-minus')) {
|
||||
this.$collapse.removeClass('wb-minus').addClass('wb-plus');
|
||||
}
|
||||
|
||||
this.$el.trigger('hidden.uikit.panel');
|
||||
this.isCollapse = true;
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'toggleFullscreen',
|
||||
value: function toggleFullscreen() {
|
||||
if (this.isFullscreen) {
|
||||
this.leaveFullscreen();
|
||||
} else {
|
||||
this.enterFullscreen();
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'enterFullscreen',
|
||||
value: function enterFullscreen() {
|
||||
if (this.isFullscreen !== true) {
|
||||
this.$el.addClass('is-fullscreen');
|
||||
|
||||
if (this.$fullscreen.hasClass('wb-expand')) {
|
||||
this.$fullscreen.removeClass('wb-expand').addClass('wb-contract');
|
||||
}
|
||||
|
||||
this.$el.trigger('enter.fullscreen.uikit.panel');
|
||||
this.isFullscreen = true;
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'leaveFullscreen',
|
||||
value: function leaveFullscreen() {
|
||||
if (this.isFullscreen !== false) {
|
||||
this.$el.removeClass('is-fullscreen');
|
||||
|
||||
if (this.$fullscreen.hasClass('wb-contract')) {
|
||||
this.$fullscreen.removeClass('wb-contract').addClass('wb-expand');
|
||||
}
|
||||
|
||||
this.$el.trigger('leave.fullscreen.uikit.panel');
|
||||
this.isFullscreen = false;
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'toggle',
|
||||
value: function toggle() {
|
||||
if (this.isClose) {
|
||||
this.open();
|
||||
} else {
|
||||
this.close();
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'open',
|
||||
value: function open() {
|
||||
if (this.isClose !== false) {
|
||||
this.$el.removeClass('is-close');
|
||||
this.$el.trigger('open.uikit.panel');
|
||||
|
||||
this.isClose = false;
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'close',
|
||||
value: function close() {
|
||||
if (this.isClose !== true) {
|
||||
this.$el.addClass('is-close');
|
||||
this.$el.trigger('close.uikit.panel');
|
||||
|
||||
this.isClose = true;
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}, {
|
||||
key: 'api',
|
||||
value: function api() {
|
||||
return function () {
|
||||
(0, _jquery2.default)(document).on('click.site.panel', '[data-toggle="panel-fullscreen"]', function (e) {
|
||||
e.preventDefault();
|
||||
var api = getPanelAPI((0, _jquery2.default)(this).closest('.panel'));
|
||||
api.toggleFullscreen();
|
||||
});
|
||||
|
||||
(0, _jquery2.default)(document).on('click.site.panel', '[data-toggle="panel-collapse"]', function (e) {
|
||||
e.preventDefault();
|
||||
var api = getPanelAPI((0, _jquery2.default)(this).closest('.panel'));
|
||||
api.toggleContent();
|
||||
});
|
||||
|
||||
(0, _jquery2.default)(document).on('click.site.panel', '[data-toggle="panel-close"]', function (e) {
|
||||
e.preventDefault();
|
||||
var api = getPanelAPI((0, _jquery2.default)(this).closest('.panel'));
|
||||
api.close();
|
||||
});
|
||||
|
||||
(0, _jquery2.default)(document).on('click.site.panel', '[data-toggle="panel-refresh"]', function (e) {
|
||||
e.preventDefault();
|
||||
var api = getPanelAPI((0, _jquery2.default)(this).closest('.panel'));
|
||||
api.load();
|
||||
});
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Panel;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Panel);
|
||||
|
||||
exports.default = Panel;
|
||||
});
|
||||
+232
@@ -0,0 +1,232 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/peity', ['exports', 'jquery', 'Plugin', 'Config'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'), require('Config'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin, global.Config);
|
||||
global.PluginPeity = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin5, _Config) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
exports.PeityPie = exports.PeityDonut = exports.PeityLine = exports.PeityBar = undefined;
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin6 = babelHelpers.interopRequireDefault(_Plugin5);
|
||||
|
||||
var PeityBar = function (_Plugin) {
|
||||
babelHelpers.inherits(PeityBar, _Plugin);
|
||||
|
||||
function PeityBar() {
|
||||
babelHelpers.classCallCheck(this, PeityBar);
|
||||
return babelHelpers.possibleConstructorReturn(this, (PeityBar.__proto__ || Object.getPrototypeOf(PeityBar)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(PeityBar, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return 'peityBar';
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.peity) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el,
|
||||
options = this.options;
|
||||
|
||||
if (options.skin) {
|
||||
var skinColors = (0, _Config.colors)(options.skin);
|
||||
if (skinColors) {
|
||||
options.fill = [skinColors[400]];
|
||||
}
|
||||
}
|
||||
|
||||
$el.peity('bar', options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
delimiter: ',',
|
||||
fill: [(0, _Config.colors)('primary', 400)],
|
||||
height: 22,
|
||||
max: null,
|
||||
min: 0,
|
||||
padding: 0.1,
|
||||
width: 44
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return PeityBar;
|
||||
}(_Plugin6.default);
|
||||
|
||||
_Plugin6.default.register('peityBar', PeityBar);
|
||||
|
||||
var PeityDonut = function (_Plugin2) {
|
||||
babelHelpers.inherits(PeityDonut, _Plugin2);
|
||||
|
||||
function PeityDonut() {
|
||||
babelHelpers.classCallCheck(this, PeityDonut);
|
||||
return babelHelpers.possibleConstructorReturn(this, (PeityDonut.__proto__ || Object.getPrototypeOf(PeityDonut)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(PeityDonut, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return 'peityDonut';
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.peity) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el,
|
||||
options = this.options;
|
||||
|
||||
if (options.skin) {
|
||||
var skinColors = (0, _Config.colors)(options.skin);
|
||||
if (skinColors) {
|
||||
options.fill = [skinColors[700], skinColors[400], skinColors[200]];
|
||||
}
|
||||
}
|
||||
|
||||
$el.peity('donut', options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
delimiter: null,
|
||||
fill: [(0, _Config.colors)('primary', 700), (0, _Config.colors)('primary', 400), (0, _Config.colors)('primary', 200)],
|
||||
height: null,
|
||||
innerRadius: null,
|
||||
radius: 11,
|
||||
width: null
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return PeityDonut;
|
||||
}(_Plugin6.default);
|
||||
|
||||
_Plugin6.default.register('peityDonut', PeityDonut);
|
||||
|
||||
var PeityLine = function (_Plugin3) {
|
||||
babelHelpers.inherits(PeityLine, _Plugin3);
|
||||
|
||||
function PeityLine() {
|
||||
babelHelpers.classCallCheck(this, PeityLine);
|
||||
return babelHelpers.possibleConstructorReturn(this, (PeityLine.__proto__ || Object.getPrototypeOf(PeityLine)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(PeityLine, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return 'peityLine';
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.peity) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el,
|
||||
options = this.options;
|
||||
|
||||
if (options.skin) {
|
||||
var skinColors = (0, _Config.colors)(options.skin);
|
||||
if (skinColors) {
|
||||
options.fill = [skinColors[200]];
|
||||
options.stroke = skinColors[600];
|
||||
}
|
||||
}
|
||||
|
||||
$el.peity('line', options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
delimiter: ',',
|
||||
fill: [(0, _Config.colors)('primary', 200)],
|
||||
height: 22,
|
||||
max: null,
|
||||
min: 0,
|
||||
stroke: (0, _Config.colors)('primary', 600),
|
||||
strokeWidth: 1,
|
||||
width: 44
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return PeityLine;
|
||||
}(_Plugin6.default);
|
||||
|
||||
_Plugin6.default.register('peityLine', PeityLine);
|
||||
|
||||
var PeityPie = function (_Plugin4) {
|
||||
babelHelpers.inherits(PeityPie, _Plugin4);
|
||||
|
||||
function PeityPie() {
|
||||
babelHelpers.classCallCheck(this, PeityPie);
|
||||
return babelHelpers.possibleConstructorReturn(this, (PeityPie.__proto__ || Object.getPrototypeOf(PeityPie)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(PeityPie, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return 'peityPie';
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.peity) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el,
|
||||
options = this.options;
|
||||
|
||||
if (options.skin) {
|
||||
var skinColors = (0, _Config.colors)(options.skin);
|
||||
if (skinColors) {
|
||||
options.fill = [skinColors[700], skinColors[400], skinColors[200]];
|
||||
}
|
||||
}
|
||||
|
||||
$el.peity('pie', options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
delimiter: null,
|
||||
fill: [(0, _Config.colors)('primary', 700), (0, _Config.colors)('primary', 400), (0, _Config.colors)('primary', 200)],
|
||||
height: null,
|
||||
radius: 11,
|
||||
width: null
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return PeityPie;
|
||||
}(_Plugin6.default);
|
||||
|
||||
_Plugin6.default.register('peityPie', PeityPie);
|
||||
|
||||
exports.PeityBar = PeityBar;
|
||||
exports.PeityLine = PeityLine;
|
||||
exports.PeityDonut = PeityDonut;
|
||||
exports.PeityPie = PeityPie;
|
||||
});
|
||||
+78
@@ -0,0 +1,78 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/plyr', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginPlyr = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'plyr';
|
||||
|
||||
(0, _jquery2.default)(document).ready(function () {
|
||||
var a = new XMLHttpRequest(),
|
||||
d = document,
|
||||
u = 'https://cdn.plyr.io/1.1.5/sprite.svg';
|
||||
var b = d.body;
|
||||
|
||||
// Check for CORS support
|
||||
if ('withCredentials' in a) {
|
||||
a.open('GET', u, true);
|
||||
a.send();
|
||||
a.onload = function () {
|
||||
var c = d.createElement('div');
|
||||
c.style.display = 'none';
|
||||
c.innerHTML = a.responseText;
|
||||
b.insertBefore(c, b.childNodes[0]);
|
||||
};
|
||||
}
|
||||
});
|
||||
|
||||
var Plyr = function (_Plugin) {
|
||||
babelHelpers.inherits(Plyr, _Plugin);
|
||||
|
||||
function Plyr() {
|
||||
babelHelpers.classCallCheck(this, Plyr);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Plyr.__proto__ || Object.getPrototypeOf(Plyr)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Plyr, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (typeof plyr === 'undefined') {
|
||||
return;
|
||||
}
|
||||
plyr.setup(this.$el[0], this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return Plyr;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Plyr);
|
||||
|
||||
exports.default = Plyr;
|
||||
});
|
||||
+75
@@ -0,0 +1,75 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/raty', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginRaty = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'rating';
|
||||
|
||||
var Rating = function (_Plugin) {
|
||||
babelHelpers.inherits(Rating, _Plugin);
|
||||
|
||||
function Rating() {
|
||||
babelHelpers.classCallCheck(this, Rating);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Rating.__proto__ || Object.getPrototypeOf(Rating)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Rating, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.raty) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el;
|
||||
|
||||
if (this.options.hints) {
|
||||
this.options.hints = this.options.hints.split(',');
|
||||
}
|
||||
|
||||
$el.raty(this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
targetKeep: true,
|
||||
icon: 'font',
|
||||
starType: 'i',
|
||||
starOff: 'icon wb-star',
|
||||
starOn: 'icon wb-star orange-600',
|
||||
cancelOff: 'icon wb-minus-circle',
|
||||
cancelOn: 'icon wb-minus-circle orange-600',
|
||||
starHalf: 'icon wb-star-half orange-500'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Rating;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Rating);
|
||||
|
||||
exports.default = Rating;
|
||||
});
|
||||
+191
@@ -0,0 +1,191 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/responsive-tabs', ['exports', 'jquery'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery);
|
||||
global.PluginResponsiveTabs = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var pluginName = 'responsiveHorizontalTabs';
|
||||
|
||||
var defaults = {
|
||||
navSelector: '.nav-tabs',
|
||||
itemSelector: '.nav-item',
|
||||
dropdownSelector: '>.dropdown',
|
||||
dropdownItemSelector: '.dropdown-item',
|
||||
tabSelector: '.tab-pane',
|
||||
activeClassName: 'active'
|
||||
};
|
||||
|
||||
var responsiveHorizontalTabs = function () {
|
||||
function responsiveHorizontalTabs(el, options) {
|
||||
babelHelpers.classCallCheck(this, responsiveHorizontalTabs);
|
||||
|
||||
var $tabs = this.$tabs = (0, _jquery2.default)(el);
|
||||
this.options = options = _jquery2.default.extend(true, {}, defaults, options);
|
||||
|
||||
var $nav = this.$nav = $tabs.find(this.options.navSelector);
|
||||
var $dropdown = this.$dropdown = $nav.find(this.options.dropdownSelector);
|
||||
var $items = this.$items = $nav.find(this.options.itemSelector).filter(function () {
|
||||
return !(0, _jquery2.default)(this).is($dropdown);
|
||||
});
|
||||
|
||||
this.$dropdownItems = $dropdown.find(this.options.dropdownItemSelector);
|
||||
this.$tabPanel = this.$tabs.find(this.options.tabSelector);
|
||||
|
||||
this.breakpoints = [];
|
||||
|
||||
$items.each(function () {
|
||||
(0, _jquery2.default)(this).data('width', (0, _jquery2.default)(this).width());
|
||||
});
|
||||
|
||||
this.init();
|
||||
this.bind();
|
||||
}
|
||||
|
||||
babelHelpers.createClass(responsiveHorizontalTabs, [{
|
||||
key: 'init',
|
||||
value: function init() {
|
||||
if (this.$dropdown.length === 0) return;
|
||||
|
||||
this.$dropdown.show();
|
||||
this.breakpoints = [];
|
||||
|
||||
var length = this.length = this.$items.length;
|
||||
var dropWidth = this.dropWidth = this.$dropdown.width();
|
||||
var total = 0;
|
||||
|
||||
this.flag = length;
|
||||
|
||||
if (length <= 1) {
|
||||
this.$dropdown.hide();
|
||||
return;
|
||||
}
|
||||
|
||||
for (var i = 0; i < length - 2; i++) {
|
||||
if (i === 0) {
|
||||
this.breakpoints.push(this.$items.eq(i).outerWidth() + dropWidth);
|
||||
} else {
|
||||
this.breakpoints.push(this.breakpoints[i - 1] + this.$items.eq(i).width());
|
||||
}
|
||||
}
|
||||
|
||||
for (i = 0; i < length; i++) {
|
||||
total += this.$items.eq(i).outerWidth();
|
||||
}
|
||||
this.breakpoints.push(total);
|
||||
|
||||
this.layout();
|
||||
}
|
||||
}, {
|
||||
key: 'layout',
|
||||
value: function layout() {
|
||||
if (this.breakpoints.length <= 0) return;
|
||||
|
||||
var width = this.$nav.width();
|
||||
var i = 0;
|
||||
var activeClassName = this.options.activeClassName;
|
||||
var active = this.$tabPanel.filter('.' + activeClassName).index();
|
||||
|
||||
for (; i < this.breakpoints.length; i++) {
|
||||
if (this.breakpoints[i] > width) break;
|
||||
}
|
||||
|
||||
if (i === this.flag) return;
|
||||
|
||||
this.$items.children().removeClass(activeClassName);
|
||||
this.$dropdownItems.removeClass(activeClassName);
|
||||
this.$dropdown.children().removeClass(activeClassName);
|
||||
|
||||
if (i === this.breakpoints.length) {
|
||||
this.$dropdown.hide();
|
||||
this.$items.show();
|
||||
this.$items.eq(active).children().addClass(activeClassName);
|
||||
} else {
|
||||
this.$dropdown.show();
|
||||
for (var j = 0; j < this.length; j++) {
|
||||
if (j < i) {
|
||||
this.$items.eq(j).show();
|
||||
this.$dropdownItems.eq(j).hide();
|
||||
} else {
|
||||
this.$items.eq(j).hide();
|
||||
this.$dropdownItems.eq(j).show();
|
||||
}
|
||||
}
|
||||
|
||||
if (active < i) {
|
||||
this.$items.eq(active).children().addClass(activeClassName);
|
||||
} else {
|
||||
this.$dropdown.children().addClass(activeClassName);
|
||||
this.$dropdownItems.eq(active).addClass(activeClassName);
|
||||
}
|
||||
}
|
||||
|
||||
this.flag = i;
|
||||
}
|
||||
}, {
|
||||
key: 'bind',
|
||||
value: function bind() {
|
||||
var self = this;
|
||||
|
||||
(0, _jquery2.default)(window).resize(function () {
|
||||
self.layout();
|
||||
});
|
||||
}
|
||||
}], [{
|
||||
key: '_jQueryInterface',
|
||||
value: function _jQueryInterface(options) {
|
||||
for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
||||
args[_key - 1] = arguments[_key];
|
||||
}
|
||||
|
||||
if (typeof options === 'string') {
|
||||
var method = options;
|
||||
if (/^\_/.test(method)) {
|
||||
return false;
|
||||
} else {
|
||||
return this.each(function () {
|
||||
var api = _jquery2.default.data(this, pluginName);
|
||||
if (api && typeof api[method] === 'function') {
|
||||
api[method].apply(api, args);
|
||||
}
|
||||
});
|
||||
}
|
||||
} else {
|
||||
return this.each(function () {
|
||||
if (!_jquery2.default.data(this, pluginName)) {
|
||||
_jquery2.default.data(this, pluginName, new responsiveHorizontalTabs(this, options));
|
||||
} else {
|
||||
_jquery2.default.data(this, pluginName).init();
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}]);
|
||||
return responsiveHorizontalTabs;
|
||||
}();
|
||||
|
||||
_jquery2.default.fn[pluginName] = responsiveHorizontalTabs._jQueryInterface;
|
||||
_jquery2.default.fn[pluginName].constructor = responsiveHorizontalTabs;
|
||||
_jquery2.default.fn[pluginName].noConflict = function () {
|
||||
'use strict';
|
||||
|
||||
_jquery2.default.fn[pluginName] = window.JQUERY_NO_CONFLICT;
|
||||
return responsiveHorizontalTabs._jQueryInterface;
|
||||
};
|
||||
|
||||
exports.default = responsiveHorizontalTabs;
|
||||
});
|
||||
+51
@@ -0,0 +1,51 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/select2', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginSelect2 = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'select2';
|
||||
|
||||
var Select2 = function (_Plugin) {
|
||||
babelHelpers.inherits(Select2, _Plugin);
|
||||
|
||||
function Select2() {
|
||||
babelHelpers.classCallCheck(this, Select2);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Select2.__proto__ || Object.getPrototypeOf(Select2)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Select2, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
width: 'style'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Select2;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Select2);
|
||||
|
||||
exports.default = Select2;
|
||||
});
|
||||
+69
@@ -0,0 +1,69 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/selectable', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginSelectable = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'selectable';
|
||||
|
||||
var Selectable = function (_Plugin) {
|
||||
babelHelpers.inherits(Selectable, _Plugin);
|
||||
|
||||
function Selectable() {
|
||||
babelHelpers.classCallCheck(this, Selectable);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Selectable.__proto__ || Object.getPrototypeOf(Selectable)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Selectable, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.asSelectable) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el;
|
||||
|
||||
$el.asSelectable(this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
allSelector: '.selectable-all',
|
||||
itemSelector: '.selectable-item',
|
||||
rowSelector: 'tr',
|
||||
rowSelectable: false,
|
||||
rowActiveClass: 'active',
|
||||
onChange: null
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Selectable;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Selectable);
|
||||
|
||||
exports.default = Selectable;
|
||||
});
|
||||
+302
@@ -0,0 +1,302 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/skintools', [], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory();
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory();
|
||||
global.PluginSkintools = mod.exports;
|
||||
}
|
||||
})(this, function () {
|
||||
'use strict';
|
||||
|
||||
if (window.localStorage) {
|
||||
var getLevel = function getLevel(url, tag) {
|
||||
var arr = url.split('/').reverse();
|
||||
var level = void 0;
|
||||
var path = '';
|
||||
|
||||
for (var i = 0; i < arr.length; i++) {
|
||||
if (arr[i] === tag) {
|
||||
level = i;
|
||||
}
|
||||
}
|
||||
|
||||
for (var m = 1; m < level; m++) {
|
||||
path += '../';
|
||||
}
|
||||
|
||||
return path;
|
||||
};
|
||||
|
||||
var layout = 'base';
|
||||
var settingsName = 'remark.' + layout + '.skinTools';
|
||||
var settings = localStorage.getItem(settingsName);
|
||||
|
||||
if (settings) {
|
||||
if (settings[0] === '{') {
|
||||
settings = JSON.parse(settings);
|
||||
}
|
||||
|
||||
if (settings['primary'] && settings['primary'] !== 'primary') {
|
||||
var head = document.head;
|
||||
var link = document.createElement('link');
|
||||
|
||||
link.type = 'text/css';
|
||||
link.rel = 'stylesheet';
|
||||
link.href = getLevel(window.location.pathname, layout) + 'assets/skins/' + settings['primary'] + '.css';
|
||||
link.id = 'skinStyle';
|
||||
|
||||
head.appendChild(link);
|
||||
}
|
||||
|
||||
if (settings['sidebar'] && settings['sidebar'] === 'light') {
|
||||
var menubarFn = setInterval(function () {
|
||||
var menubar = document.getElementsByClassName('site-menubar');
|
||||
if (menubar.length > 0) {
|
||||
clearInterval(menubarFn);
|
||||
menubar[0].className += ' site-menubar-light';
|
||||
}
|
||||
}, 5);
|
||||
}
|
||||
|
||||
var navbarFn = setInterval(function () {
|
||||
var navbar = document.getElementsByClassName('site-navbar');
|
||||
|
||||
if (navbar.length > 0) {
|
||||
clearInterval(navbarFn);
|
||||
if (settings['navbar'] && settings['navbar'] !== 'primary') {
|
||||
navbar[0].className += ' bg-' + settings['navbar'] + '-600';
|
||||
}
|
||||
if (settings['navbarInverse'] && settings['navbarInverse'] !== 'false') {
|
||||
navbar[0].className += ' navbar-inverse';
|
||||
}
|
||||
}
|
||||
}, 5);
|
||||
}
|
||||
|
||||
if (document.addEventListener) {
|
||||
document.addEventListener('DOMContentLoaded', function () {
|
||||
var $body = $(document.body);
|
||||
var $doc = $(document);
|
||||
var $win = $(window);
|
||||
|
||||
var Storage = {
|
||||
set: function set(key, value) {
|
||||
if (!window.localStorage) {
|
||||
return null;
|
||||
}
|
||||
if (!key || !value) {
|
||||
return null;
|
||||
}
|
||||
|
||||
if (Object(value) === value) {
|
||||
value = JSON.stringify(value);
|
||||
}
|
||||
localStorage.setItem(key, value);
|
||||
},
|
||||
get: function get(key) {
|
||||
if (!window.localStorage) {
|
||||
return null;
|
||||
}
|
||||
|
||||
var value = localStorage.getItem(key);
|
||||
|
||||
if (!value) {
|
||||
return null;
|
||||
}
|
||||
|
||||
if (value[0] === '{') {
|
||||
value = JSON.parse(value);
|
||||
}
|
||||
|
||||
return value;
|
||||
}
|
||||
};
|
||||
|
||||
var Skintools = {
|
||||
tpl: '<div class="site-skintools">' + '<div class="site-skintools-inner">' + '<div class="site-skintools-toggle">' + '<i class="icon wb-settings primary-600"></i>' + '</div>' + '<div class="site-skintools-content">' + '<div class="nav-tabs-horizontal">' + '<ul role="tablist" class="nav nav-tabs nav-tabs-line">' + '<li role="presentation" class="nav-item"><a class="nav-link active" role="tab" aria-controls="skintoolsSidebar" href="#skintoolsSidebar" data-toggle="tab" aria-expanded="true">Sidebar</a></li>' + '<li class="nav-item" role="presentation"><a class="nav-link" role="tab" aria-controls="skintoolsNavbar" href="#skintoolsNavbar" data-toggle="tab" aria-expanded="false">Navbar</a></li>' + '<li class="nav-item" role="presentation"><a class="nav-link" role="tab" aria-controls="skintoolsPrimary" href="#skintoolsPrimary" data-toggle="tab" aria-expanded="false">Primary</a></li>' + '</ul>' + '<div class="tab-content">' + '<div role="tabpanel" id="skintoolsSidebar" class="tab-pane active"></div>' + '<div role="tabpanel" id="skintoolsNavbar" class="tab-pane"></div>' + '<div role="tabpanel" id="skintoolsPrimary" class="tab-pane"></div>' + '<button class="btn btn-outline btn-block btn-primary mt-20" id="skintoolsReset" type="button">Reset</button>' + '</div>' + '</div>' + '</div>' + '</div>' + '</div>',
|
||||
skintoolsSidebar: ['dark', 'light'],
|
||||
skintoolsNavbar: ['primary', 'brown', 'cyan', 'green', 'grey', 'indigo', 'orange', 'pink', 'purple', 'red', 'teal', 'yellow'],
|
||||
navbarSkins: 'bg-primary-600 bg-brown-600 bg-cyan-600 bg-green-600 bg-grey-600 bg-indigo-600 bg-orange-600 bg-pink-600 bg-purple-600 bg-red-600 bg-teal-600 bg-yellow-700',
|
||||
skintoolsPrimary: ['primary', 'brown', 'cyan', 'green', 'grey', 'indigo', 'orange', 'pink', 'purple', 'red', 'teal', 'yellow'],
|
||||
storageKey: settingsName,
|
||||
defaultSettings: {
|
||||
'sidebar': 'dark',
|
||||
'navbar': 'primary',
|
||||
'navbarInverse': 'false',
|
||||
'primary': 'primary'
|
||||
},
|
||||
init: function init() {
|
||||
var self = this;
|
||||
|
||||
this.path = getLevel(window.location.pathname, layout);
|
||||
this.overflow = false;
|
||||
|
||||
this.$siteSidebar = $('.site-menubar');
|
||||
this.$siteNavbar = $('.site-navbar');
|
||||
|
||||
this.$container = $(this.tpl);
|
||||
this.$toggle = $('.site-skintools-toggle', this.$container);
|
||||
this.$content = $('.site-skintools-content', this.$container);
|
||||
this.$tabContent = $('.tab-content', this.$container);
|
||||
|
||||
this.$sidebar = $('#skintoolsSidebar', this.$content);
|
||||
this.$navbar = $('#skintoolsNavbar', this.$content);
|
||||
this.$primary = $('#skintoolsPrimary', this.$content);
|
||||
|
||||
this.build(this.$sidebar, this.skintoolsSidebar, 'skintoolsSidebar', 'radio', 'Sidebar Skins');
|
||||
this.build(this.$navbar, ['inverse'], 'skintoolsNavbar', 'checkbox', 'Navbar Type');
|
||||
this.build(this.$navbar, this.skintoolsNavbar, 'skintoolsNavbar', 'radio', 'Navbar Skins');
|
||||
this.build(this.$primary, this.skintoolsPrimary, 'skintoolsPrimary', 'radio', 'Primary Skins');
|
||||
|
||||
this.$container.appendTo($body);
|
||||
|
||||
this.$toggle.on('click', function () {
|
||||
self.$container.toggleClass('is-open');
|
||||
});
|
||||
|
||||
$('#skintoolsSidebar input').on('click', function () {
|
||||
self.sidebarEvents(this);
|
||||
});
|
||||
$('#skintoolsNavbar input').on('click', function () {
|
||||
self.navbarEvents(this);
|
||||
});
|
||||
$('#skintoolsPrimary input').on('click', function () {
|
||||
self.primaryEvents(this);
|
||||
});
|
||||
|
||||
$('#skintoolsReset').on('click', function () {
|
||||
self.reset();
|
||||
});
|
||||
|
||||
this.initLocalStorage();
|
||||
},
|
||||
initLocalStorage: function initLocalStorage() {
|
||||
var self = this;
|
||||
|
||||
this.settings = Storage.get(this.storageKey);
|
||||
|
||||
if (this.settings === null) {
|
||||
this.settings = $.extend(true, {}, this.defaultSettings);
|
||||
|
||||
Storage.set(this.storageKey, this.settings);
|
||||
}
|
||||
|
||||
if (this.settings && $.isPlainObject(this.settings)) {
|
||||
$.each(this.settings, function (n, v) {
|
||||
switch (n) {
|
||||
case 'sidebar':
|
||||
$('input[value="' + v + '"]', self.$sidebar).prop('checked', true);
|
||||
self.sidebarImprove(v);
|
||||
break;
|
||||
case 'navbar':
|
||||
$('input[value="' + v + '"]', self.$navbar).prop('checked', true);
|
||||
self.navbarImprove(v);
|
||||
break;
|
||||
case 'navbarInverse':
|
||||
var flag = v === 'false' ? false : true;
|
||||
$('input[value="inverse"]', self.$navbar).prop('checked', flag);
|
||||
self.navbarImprove('inverse', flag);
|
||||
break;
|
||||
case 'primary':
|
||||
$('input[value="' + v + '"]', self.$primary).prop('checked', true);
|
||||
self.primaryImprove(v);
|
||||
break;
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
updateSetting: function updateSetting(item, value) {
|
||||
this.settings[item] = value;
|
||||
Storage.set(this.storageKey, this.settings);
|
||||
},
|
||||
title: function title(content) {
|
||||
return $('<h4 class="site-skintools-title">' + content + '</h4>');
|
||||
},
|
||||
item: function item(type, name, id, content) {
|
||||
var item = '<div class="' + type + '-custom ' + type + '-' + content + '"><input id="' + id + '" type="' + type + '" name="' + name + '" value="' + content + '"><label for="' + id + '">' + content + '</label></div>';
|
||||
return $(item);
|
||||
},
|
||||
build: function build($wrap, data, name, type, title) {
|
||||
if (title) {
|
||||
this.title(title).appendTo($wrap);
|
||||
}
|
||||
for (var i = 0; i < data.length; i++) {
|
||||
this.item(type, name, name + '-' + data[i], data[i]).appendTo($wrap);
|
||||
}
|
||||
},
|
||||
sidebarEvents: function sidebarEvents(self) {
|
||||
var val = $(self).val();
|
||||
|
||||
this.sidebarImprove(val);
|
||||
this.updateSetting('sidebar', val);
|
||||
},
|
||||
navbarEvents: function navbarEvents(self) {
|
||||
var val = $(self).val();
|
||||
var checked = $(self).prop('checked');
|
||||
|
||||
this.navbarImprove(val, checked);
|
||||
|
||||
if (val === 'inverse') {
|
||||
this.updateSetting('navbarInverse', checked.toString());
|
||||
} else {
|
||||
this.updateSetting('navbar', val);
|
||||
}
|
||||
},
|
||||
primaryEvents: function primaryEvents(self) {
|
||||
var val = $(self).val();
|
||||
|
||||
this.primaryImprove(val);
|
||||
|
||||
this.updateSetting('primary', val);
|
||||
},
|
||||
sidebarImprove: function sidebarImprove(val) {
|
||||
if (val === 'dark') {
|
||||
this.$siteSidebar.removeClass('site-menubar-light');
|
||||
} else if (val === 'light') {
|
||||
this.$siteSidebar.addClass('site-menubar-' + val);
|
||||
}
|
||||
},
|
||||
navbarImprove: function navbarImprove(val, checked) {
|
||||
if (val === 'inverse') {
|
||||
checked ? this.$siteNavbar.addClass('navbar-inverse') : this.$siteNavbar.removeClass('navbar-inverse');
|
||||
} else {
|
||||
var bg = 'bg-' + val + '-600';
|
||||
if (val === 'yellow') {
|
||||
bg = 'bg-yellow-700';
|
||||
}
|
||||
if (val === 'primary') {
|
||||
bg = '';
|
||||
}
|
||||
|
||||
this.$siteNavbar.removeClass(this.navbarSkins).addClass(bg);
|
||||
}
|
||||
},
|
||||
primaryImprove: function primaryImprove(val) {
|
||||
var $link = $('#skinStyle', $('head'));
|
||||
var href = this.path + 'assets/skins/' + val + '.css';
|
||||
if (val === 'primary') {
|
||||
$link.remove();
|
||||
return;
|
||||
}
|
||||
if ($link.length === 0) {
|
||||
$('head').append('<link id="skinStyle" href="' + href + '" rel="stylesheet" type="text/css"/>');
|
||||
} else {
|
||||
$link.attr('href', href);
|
||||
}
|
||||
},
|
||||
reset: function reset() {
|
||||
localStorage.clear();
|
||||
this.initLocalStorage();
|
||||
}
|
||||
};
|
||||
|
||||
Skintools.init();
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
+92
@@ -0,0 +1,92 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/slidepanel', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginSlidepanel = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'slidePanel';
|
||||
|
||||
var SlidePanel = function (_Plugin) {
|
||||
babelHelpers.inherits(SlidePanel, _Plugin);
|
||||
|
||||
function SlidePanel() {
|
||||
babelHelpers.classCallCheck(this, SlidePanel);
|
||||
return babelHelpers.possibleConstructorReturn(this, (SlidePanel.__proto__ || Object.getPrototypeOf(SlidePanel)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(SlidePanel, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (typeof _jquery2.default.slidePanel === 'undefined') {
|
||||
return;
|
||||
}
|
||||
if (!this.options.url) {
|
||||
this.options.url = this.$el.attr('href');
|
||||
this.options.url = this.options.url && this.options.url.replace(/.*(?=#[^\s]*$)/, '');
|
||||
}
|
||||
|
||||
this.$el.data('slidePanelWrapAPI', this);
|
||||
}
|
||||
}, {
|
||||
key: 'show',
|
||||
value: function show() {
|
||||
var options = this.options;
|
||||
|
||||
_jquery2.default.slidePanel.show({
|
||||
url: options.url
|
||||
}, options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
closeSelector: '.slidePanel-close',
|
||||
mouseDragHandler: '.slidePanel-handler',
|
||||
loading: {
|
||||
template: function template(options) {
|
||||
return '<div class="' + options.classes.loading + '">\n <div class="loader loader-default"></div>\n </div>';
|
||||
},
|
||||
showCallback: function showCallback(options) {
|
||||
this.$el.addClass(options.classes.loading + '-show');
|
||||
},
|
||||
hideCallback: function hideCallback(options) {
|
||||
this.$el.removeClass(options.classes.loading + '-show');
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
}, {
|
||||
key: 'api',
|
||||
value: function api() {
|
||||
return 'click|show';
|
||||
}
|
||||
}]);
|
||||
return SlidePanel;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, SlidePanel);
|
||||
|
||||
exports.default = SlidePanel;
|
||||
});
|
||||
+57
@@ -0,0 +1,57 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/sortable', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginSortable = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'sortable';
|
||||
|
||||
var Sortable = function (_Plugin) {
|
||||
babelHelpers.inherits(Sortable, _Plugin);
|
||||
|
||||
function Sortable() {
|
||||
babelHelpers.classCallCheck(this, Sortable);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Sortable.__proto__ || Object.getPrototypeOf(Sortable)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Sortable, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
window.Sortable.create(this.$el.get(0), this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
ghostClass: 'sortable-placeholder',
|
||||
dragClass: 'sortable-dragging'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Sortable;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Sortable);
|
||||
|
||||
exports.default = Sortable;
|
||||
});
|
||||
+140
@@ -0,0 +1,140 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/sticky-header', ['exports', 'jquery'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery);
|
||||
global.PluginStickyHeader = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var pluginName = 'stickyHeader';
|
||||
|
||||
var defaults = {
|
||||
headerSelector: '.header',
|
||||
changeHeaderOn: 100,
|
||||
activeClassName: 'active-sticky-header',
|
||||
min: 50,
|
||||
method: 'toggle'
|
||||
};
|
||||
|
||||
var stickyHeader = function () {
|
||||
function stickyHeader(el, options) {
|
||||
babelHelpers.classCallCheck(this, stickyHeader);
|
||||
|
||||
this.isActive = false;
|
||||
this.init(options);
|
||||
this.bind();
|
||||
}
|
||||
|
||||
babelHelpers.createClass(stickyHeader, [{
|
||||
key: 'init',
|
||||
value: function init(options) {
|
||||
var $el = this.$el.css('transition', 'none');
|
||||
|
||||
var $header = this.$header = $el.find(options.headerSelector).css({
|
||||
position: 'absolute',
|
||||
top: 0,
|
||||
left: 0
|
||||
});
|
||||
|
||||
this.options = _jquery2.default.extend(true, {}, defaults, options, $header.data());
|
||||
this.headerHeight = $header.outerHeight();
|
||||
// this.offsetTop()
|
||||
// $el.css('transition','all .5s linear');
|
||||
// $header.css('transition','all .5s linear');
|
||||
this.$el.css('paddingTop', this.headerHeight);
|
||||
}
|
||||
}, {
|
||||
key: '_toggleActive',
|
||||
value: function _toggleActive() {
|
||||
if (this.isActive) {
|
||||
this.$header.css('height', this.options.min);
|
||||
} else {
|
||||
this.$header.css('height', this.headerHeight);
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'bind',
|
||||
value: function bind() {
|
||||
var self = this;
|
||||
this.$el.on('scroll', function () {
|
||||
if (self.options.method === 'toggle') {
|
||||
if ((0, _jquery2.default)(this).scrollTop() > self.options.changeHeaderOn && !self.isActive) {
|
||||
self.$el.addClass(self.options.activeClassName);
|
||||
self.isActive = true;
|
||||
self.$header.css('height', self.options.min);
|
||||
self.$el.trigger('toggle:sticky', [self, self.isActive]);
|
||||
} else if ((0, _jquery2.default)(this).scrollTop() <= self.options.changeHeaderOn && self.isActive) {
|
||||
self.$el.removeClass(self.options.activeClassName);
|
||||
self.isActive = false;
|
||||
self.$header.css('height', self.headerHeight);
|
||||
self.$el.trigger('toggle:sticky', [self, self.isActive]);
|
||||
}
|
||||
} else if (self.options.method === 'scroll') {
|
||||
var offset = Math.max(self.headerHeight - (0, _jquery2.default)(this).scrollTop(), self.options.min);
|
||||
if (offset === self.headerHeight) {
|
||||
self.$el.removeClass(self.options.activeClassName);
|
||||
} else {
|
||||
self.$el.addClass(self.options.activeClassName);
|
||||
}
|
||||
self.$header.css('height', offset);
|
||||
self.$el.trigger('toggle:sticky', [self]);
|
||||
}
|
||||
});
|
||||
}
|
||||
}], [{
|
||||
key: '_jQueryInterface',
|
||||
value: function _jQueryInterface(options) {
|
||||
for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
||||
args[_key - 1] = arguments[_key];
|
||||
}
|
||||
|
||||
if (typeof options === 'string') {
|
||||
var method = options;
|
||||
if (/^\_/.test(method)) {
|
||||
return false;
|
||||
} else {
|
||||
return this.each(function () {
|
||||
var api = _jquery2.default.data(this, pluginName);
|
||||
if (api && typeof api[method] === 'function') {
|
||||
api[method].apply(api, args);
|
||||
}
|
||||
});
|
||||
}
|
||||
} else {
|
||||
return this.each(function () {
|
||||
if (!_jquery2.default.data(this, pluginName)) {
|
||||
_jquery2.default.data(this, pluginName, new stickyHeader(this, options));
|
||||
} else {
|
||||
_jquery2.default.data(this, pluginName).init(options);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}]);
|
||||
return stickyHeader;
|
||||
}();
|
||||
|
||||
_jquery2.default.fn[pluginName] = stickyHeader._jQueryInterface;
|
||||
_jquery2.default.fn[pluginName].constructor = stickyHeader;
|
||||
_jquery2.default.fn[pluginName].noConflict = function () {
|
||||
'use strict';
|
||||
|
||||
_jquery2.default.fn[pluginName] = window.JQUERY_NO_CONFLICT;
|
||||
return stickyHeader._jQueryInterface;
|
||||
};
|
||||
|
||||
exports.default = stickyHeader;
|
||||
});
|
||||
+51
@@ -0,0 +1,51 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/summernote', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginSummernote = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'summernote';
|
||||
|
||||
var Summernote = function (_Plugin) {
|
||||
babelHelpers.inherits(Summernote, _Plugin);
|
||||
|
||||
function Summernote() {
|
||||
babelHelpers.classCallCheck(this, Summernote);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Summernote.__proto__ || Object.getPrototypeOf(Summernote)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Summernote, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
height: 300
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Summernote;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Summernote);
|
||||
|
||||
exports.default = Summernote;
|
||||
});
|
||||
+59
@@ -0,0 +1,59 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/switchery', ['exports', 'Plugin', 'Config'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'), require('Config'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin, global.Config);
|
||||
global.PluginSwitchery = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2, _Config) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'switchery';
|
||||
|
||||
var SwitcheryPlugin = function (_Plugin) {
|
||||
babelHelpers.inherits(SwitcheryPlugin, _Plugin);
|
||||
|
||||
function SwitcheryPlugin() {
|
||||
babelHelpers.classCallCheck(this, SwitcheryPlugin);
|
||||
return babelHelpers.possibleConstructorReturn(this, (SwitcheryPlugin.__proto__ || Object.getPrototypeOf(SwitcheryPlugin)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(SwitcheryPlugin, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (typeof Switchery === 'undefined') {
|
||||
return;
|
||||
}
|
||||
new Switchery(this.$el[0], this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
color: (0, _Config.colors)('primary', 600)
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return SwitcheryPlugin;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, SwitcheryPlugin);
|
||||
|
||||
exports.default = SwitcheryPlugin;
|
||||
});
|
||||
+75
@@ -0,0 +1,75 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/table', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginTable = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'tableSection';
|
||||
|
||||
var TableSection = function (_Plugin) {
|
||||
babelHelpers.inherits(TableSection, _Plugin);
|
||||
|
||||
function TableSection() {
|
||||
babelHelpers.classCallCheck(this, TableSection);
|
||||
return babelHelpers.possibleConstructorReturn(this, (TableSection.__proto__ || Object.getPrototypeOf(TableSection)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(TableSection, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
this.$el.data('tableApi', this);
|
||||
}
|
||||
}, {
|
||||
key: 'toggle',
|
||||
value: function toggle(e) {
|
||||
var $el = this.$el;
|
||||
if (e.target.type !== 'checkbox' && e.target.type !== 'button' && e.target.tagName.toLowerCase() !== 'a' && !(0, _jquery2.default)(e.target).parent('div.checkbox-custom').length) {
|
||||
if ($el.hasClass('active')) {
|
||||
$el.removeClass('active');
|
||||
} else {
|
||||
$el.siblings('.table-section').removeClass('active');
|
||||
$el.addClass('active');
|
||||
}
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'api',
|
||||
value: function api() {
|
||||
var api = 'click|toggle',
|
||||
touch = typeof document.ontouchstart !== 'undefined';
|
||||
|
||||
if (touch) {
|
||||
api = 'touchstart|toggle';
|
||||
}
|
||||
return api;
|
||||
}
|
||||
}]);
|
||||
return TableSection;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, TableSection);
|
||||
|
||||
exports.default = TableSection;
|
||||
});
|
||||
+62
@@ -0,0 +1,62 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/tablesaw', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginTablesaw = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'tablesaw';
|
||||
|
||||
var Tablesaw = function (_Plugin) {
|
||||
babelHelpers.inherits(Tablesaw, _Plugin);
|
||||
|
||||
function Tablesaw() {
|
||||
babelHelpers.classCallCheck(this, Tablesaw);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Tablesaw.__proto__ || Object.getPrototypeOf(Tablesaw)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Tablesaw, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}, {
|
||||
key: 'api',
|
||||
value: function api() {
|
||||
return function () {
|
||||
if (typeof _jquery2.default.fn.tablesaw === 'undefined') {
|
||||
return;
|
||||
}
|
||||
|
||||
(0, _jquery2.default)(document).trigger("enhance.tablesaw");
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Tablesaw;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Tablesaw);
|
||||
|
||||
exports.default = Tablesaw;
|
||||
});
|
||||
+62
@@ -0,0 +1,62 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/tabs', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginTabs = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'tabs';
|
||||
|
||||
var Tabs = function (_Plugin) {
|
||||
babelHelpers.inherits(Tabs, _Plugin);
|
||||
|
||||
function Tabs() {
|
||||
babelHelpers.classCallCheck(this, Tabs);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Tabs.__proto__ || Object.getPrototypeOf(Tabs)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Tabs, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (this.$el.find('.nav-tabs-horizontal') && _jquery2.default.fn.responsiveHorizontalTabs) {
|
||||
this.type = 'horizontal';
|
||||
this.$el.responsiveHorizontalTabs();
|
||||
} else if (this.$el.find('.nav-tabs-vertical')) {
|
||||
this.type = 'vertical';
|
||||
this.$el.children().matchHeight();
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {};
|
||||
}
|
||||
}]);
|
||||
return Tabs;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Tabs);
|
||||
|
||||
exports.default = Tabs;
|
||||
});
|
||||
+65
@@ -0,0 +1,65 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/tasklist', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginTasklist = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'tasklist';
|
||||
|
||||
var TaskList = function (_Plugin) {
|
||||
babelHelpers.inherits(TaskList, _Plugin);
|
||||
|
||||
function TaskList() {
|
||||
babelHelpers.classCallCheck(this, TaskList);
|
||||
return babelHelpers.possibleConstructorReturn(this, (TaskList.__proto__ || Object.getPrototypeOf(TaskList)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(TaskList, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
this.$el.data('tasklistApi', this);
|
||||
this.$checkbox = this.$el.find('[type="checkbox"]');
|
||||
this.$el.trigger('change.site.task');
|
||||
}
|
||||
}, {
|
||||
key: 'toggle',
|
||||
value: function toggle() {
|
||||
if (this.$checkbox.is(':checked')) {
|
||||
this.$el.addClass('task-done');
|
||||
} else {
|
||||
this.$el.removeClass('task-done');
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'api',
|
||||
value: function api() {
|
||||
return 'change|toggle';
|
||||
}
|
||||
}]);
|
||||
return TaskList;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, TaskList);
|
||||
|
||||
exports.default = TaskList;
|
||||
});
|
||||
+85
@@ -0,0 +1,85 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/toastr', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginToastr = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'toastr';
|
||||
|
||||
var Toastr = function (_Plugin) {
|
||||
babelHelpers.inherits(Toastr, _Plugin);
|
||||
|
||||
function Toastr() {
|
||||
babelHelpers.classCallCheck(this, Toastr);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Toastr.__proto__ || Object.getPrototypeOf(Toastr)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Toastr, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
this.$el.data('toastrWrapApi', this);
|
||||
}
|
||||
}, {
|
||||
key: 'show',
|
||||
value: function show(e) {
|
||||
if (typeof toastr === 'undefined') {
|
||||
return;
|
||||
}
|
||||
|
||||
e.preventDefault();
|
||||
|
||||
var options = this.options;
|
||||
var message = options.message || '';
|
||||
var type = options.type || 'info';
|
||||
var title = options.title || undefined;
|
||||
|
||||
switch (type) {
|
||||
case 'success':
|
||||
toastr.success(message, title, options);
|
||||
break;
|
||||
case 'warning':
|
||||
toastr.warning(message, title, options);
|
||||
break;
|
||||
case 'error':
|
||||
toastr.error(message, title, options);
|
||||
break;
|
||||
case 'info':
|
||||
toastr.info(message, title, options);
|
||||
break;
|
||||
default:
|
||||
toastr.info(message, title, options);
|
||||
}
|
||||
}
|
||||
}], [{
|
||||
key: 'api',
|
||||
value: function api() {
|
||||
return 'click|show';
|
||||
}
|
||||
}]);
|
||||
return Toastr;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Toastr);
|
||||
|
||||
exports.default = Toastr;
|
||||
});
|
||||
+70
@@ -0,0 +1,70 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/toolbar', ['exports', 'jquery', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Plugin);
|
||||
global.PluginToolbar = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'toolbar';
|
||||
|
||||
var Toolbar = function (_Plugin) {
|
||||
babelHelpers.inherits(Toolbar, _Plugin);
|
||||
|
||||
function Toolbar() {
|
||||
babelHelpers.classCallCheck(this, Toolbar);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Toolbar.__proto__ || Object.getPrototypeOf(Toolbar)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Toolbar, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}, {
|
||||
key: 'render',
|
||||
value: function render() {
|
||||
if (!_jquery2.default.fn.toolbar) {
|
||||
return;
|
||||
}
|
||||
|
||||
var $el = this.$el,
|
||||
content = $el.data('toolbar');
|
||||
|
||||
if (content) {
|
||||
this.options.content = content;
|
||||
}
|
||||
|
||||
$el.toolbar(this.options);
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
hideOnClick: true,
|
||||
event: 'hover'
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return Toolbar;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, Toolbar);
|
||||
|
||||
exports.default = Toolbar;
|
||||
});
|
||||
+57
@@ -0,0 +1,57 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Plugin/webui-popover', ['exports', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.Plugin);
|
||||
global.PluginWebuiPopover = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _Plugin2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _Plugin3 = babelHelpers.interopRequireDefault(_Plugin2);
|
||||
|
||||
var NAME = 'webuiPopover';
|
||||
|
||||
var WebuiPopover = function (_Plugin) {
|
||||
babelHelpers.inherits(WebuiPopover, _Plugin);
|
||||
|
||||
function WebuiPopover() {
|
||||
babelHelpers.classCallCheck(this, WebuiPopover);
|
||||
return babelHelpers.possibleConstructorReturn(this, (WebuiPopover.__proto__ || Object.getPrototypeOf(WebuiPopover)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(WebuiPopover, [{
|
||||
key: 'getName',
|
||||
value: function getName() {
|
||||
return NAME;
|
||||
}
|
||||
}], [{
|
||||
key: 'getDefaults',
|
||||
value: function getDefaults() {
|
||||
return {
|
||||
trigger: 'click',
|
||||
width: 320,
|
||||
multi: true,
|
||||
cloaseable: false,
|
||||
style: '',
|
||||
delay: 300,
|
||||
padding: true
|
||||
};
|
||||
}
|
||||
}]);
|
||||
return WebuiPopover;
|
||||
}(_Plugin3.default);
|
||||
|
||||
_Plugin3.default.register(NAME, WebuiPopover);
|
||||
|
||||
exports.default = WebuiPopover;
|
||||
});
|
||||
+155
@@ -0,0 +1,155 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Section/GridMenu', ['exports', 'jquery', 'Component'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Component'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Component);
|
||||
global.SectionGridMenu = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Component2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Component3 = babelHelpers.interopRequireDefault(_Component2);
|
||||
|
||||
var $BODY = (0, _jquery2.default)('body');
|
||||
var $HTML = (0, _jquery2.default)('html');
|
||||
|
||||
var Scrollable = function () {
|
||||
function Scrollable($el) {
|
||||
babelHelpers.classCallCheck(this, Scrollable);
|
||||
|
||||
this.$el = $el;
|
||||
this.api = null;
|
||||
|
||||
this.init();
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Scrollable, [{
|
||||
key: 'init',
|
||||
value: function init() {
|
||||
this.api = this.$el.asScrollable({
|
||||
namespace: 'scrollable',
|
||||
skin: 'scrollable-inverse',
|
||||
direction: 'vertical',
|
||||
contentSelector: '>',
|
||||
containerSelector: '>'
|
||||
}).data('asScrollable');
|
||||
}
|
||||
}, {
|
||||
key: 'update',
|
||||
value: function update() {
|
||||
if (this.api) {
|
||||
this.api.update();
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'enable',
|
||||
value: function enable() {
|
||||
if (!this.api) {
|
||||
this.init();
|
||||
}
|
||||
if (this.api) {
|
||||
this.api.enable();
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'disable',
|
||||
value: function disable() {
|
||||
if (this.api) {
|
||||
this.api.disable();
|
||||
}
|
||||
}
|
||||
}]);
|
||||
return Scrollable;
|
||||
}();
|
||||
|
||||
var GridMenu = function (_Component) {
|
||||
babelHelpers.inherits(GridMenu, _Component);
|
||||
|
||||
function GridMenu() {
|
||||
var _ref;
|
||||
|
||||
babelHelpers.classCallCheck(this, GridMenu);
|
||||
|
||||
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
|
||||
args[_key] = arguments[_key];
|
||||
}
|
||||
|
||||
var _this = babelHelpers.possibleConstructorReturn(this, (_ref = GridMenu.__proto__ || Object.getPrototypeOf(GridMenu)).call.apply(_ref, [this].concat(args)));
|
||||
|
||||
_this.isOpened = false;
|
||||
_this.scrollable = new Scrollable(_this.$el);
|
||||
return _this;
|
||||
}
|
||||
|
||||
babelHelpers.createClass(GridMenu, [{
|
||||
key: 'open',
|
||||
value: function open() {
|
||||
this.animate(function () {
|
||||
this.$el.addClass('active');
|
||||
|
||||
(0, _jquery2.default)('[data-toggle="gridmenu"]').addClass('active').attr('aria-expanded', true);
|
||||
|
||||
$BODY.addClass('site-gridmenu-active');
|
||||
$HTML.addClass('disable-scrolling');
|
||||
}, function () {
|
||||
this.scrollable.enable();
|
||||
});
|
||||
|
||||
this.isOpened = true;
|
||||
}
|
||||
}, {
|
||||
key: 'close',
|
||||
value: function close() {
|
||||
this.animate(function () {
|
||||
this.$el.removeClass('active');
|
||||
|
||||
(0, _jquery2.default)('[data-toggle="gridmenu"]').addClass('active').attr('aria-expanded', true);
|
||||
|
||||
$BODY.removeClass('site-gridmenu-active');
|
||||
$HTML.removeClass('disable-scrolling');
|
||||
}, function () {
|
||||
this.scrollable.disable();
|
||||
});
|
||||
|
||||
this.isOpened = false;
|
||||
}
|
||||
}, {
|
||||
key: 'toggle',
|
||||
value: function toggle(opened) {
|
||||
if (opened) {
|
||||
this.open();
|
||||
} else {
|
||||
this.close();
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'animate',
|
||||
value: function animate(doing, callback) {
|
||||
var _this2 = this;
|
||||
|
||||
doing.call(this);
|
||||
this.$el.trigger('changing.site.gridmenu');
|
||||
|
||||
setTimeout(function () {
|
||||
callback.call(_this2);
|
||||
|
||||
_this2.$el.trigger('changed.site.gridmenu');
|
||||
}, 500);
|
||||
}
|
||||
}]);
|
||||
return GridMenu;
|
||||
}(_Component3.default);
|
||||
|
||||
exports.default = GridMenu;
|
||||
});
|
||||
+368
@@ -0,0 +1,368 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Section/Menubar', ['exports', 'jquery', 'Component'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Component'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Component);
|
||||
global.SectionMenubar = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Component2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Component3 = babelHelpers.interopRequireDefault(_Component2);
|
||||
|
||||
var $BODY = (0, _jquery2.default)('body');
|
||||
var $HTML = (0, _jquery2.default)('html');
|
||||
|
||||
var Scrollable = function () {
|
||||
function Scrollable($el) {
|
||||
babelHelpers.classCallCheck(this, Scrollable);
|
||||
|
||||
this.$el = $el;
|
||||
this.native = false;
|
||||
this.api = null;
|
||||
|
||||
this.init();
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Scrollable, [{
|
||||
key: 'init',
|
||||
value: function init() {
|
||||
if ($BODY.is('.site-menubar-native')) {
|
||||
this.native = true;
|
||||
return;
|
||||
}
|
||||
|
||||
this.api = this.$el.asScrollable({
|
||||
namespace: 'scrollable',
|
||||
skin: 'scrollable-inverse',
|
||||
direction: 'vertical',
|
||||
contentSelector: '>',
|
||||
containerSelector: '>'
|
||||
}).data('asScrollable');
|
||||
}
|
||||
}, {
|
||||
key: 'update',
|
||||
value: function update() {
|
||||
if (this.api) {
|
||||
this.api.update();
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'enable',
|
||||
value: function enable() {
|
||||
if (this.native) {
|
||||
return;
|
||||
}
|
||||
if (!this.api) {
|
||||
this.init();
|
||||
}
|
||||
if (this.api) {
|
||||
this.api.enable();
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'disable',
|
||||
value: function disable() {
|
||||
if (this.api) {
|
||||
this.api.disable();
|
||||
}
|
||||
}
|
||||
}]);
|
||||
return Scrollable;
|
||||
}();
|
||||
|
||||
var Hoverscroll = function () {
|
||||
function Hoverscroll($el) {
|
||||
babelHelpers.classCallCheck(this, Hoverscroll);
|
||||
|
||||
this.$el = $el;
|
||||
this.api = null;
|
||||
|
||||
this.init();
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Hoverscroll, [{
|
||||
key: 'init',
|
||||
value: function init() {
|
||||
this.api = this.$el.asHoverScroll({
|
||||
namespace: 'hoverscorll',
|
||||
direction: 'vertical',
|
||||
list: '.site-menu',
|
||||
item: '> li',
|
||||
exception: '.site-menu-sub',
|
||||
fixed: false,
|
||||
boundary: 100,
|
||||
onEnter: function onEnter() {
|
||||
// $(this).siblings().removeClass('hover'); $(this).addClass('hover');
|
||||
},
|
||||
onLeave: function onLeave() {
|
||||
// $(this).removeClass('hover');
|
||||
}
|
||||
}).data('asHoverScroll');
|
||||
}
|
||||
}, {
|
||||
key: 'update',
|
||||
value: function update() {
|
||||
if (this.api) {
|
||||
this.api.update();
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'enable',
|
||||
value: function enable() {
|
||||
if (!this.api) {
|
||||
this.init();
|
||||
}
|
||||
if (this.api) {
|
||||
this.api.enable();
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'disable',
|
||||
value: function disable() {
|
||||
if (this.api) {
|
||||
this.api.disable();
|
||||
}
|
||||
}
|
||||
}]);
|
||||
return Hoverscroll;
|
||||
}();
|
||||
|
||||
var Menubar = function (_Component) {
|
||||
babelHelpers.inherits(Menubar, _Component);
|
||||
|
||||
function Menubar() {
|
||||
var _ref;
|
||||
|
||||
babelHelpers.classCallCheck(this, Menubar);
|
||||
|
||||
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
|
||||
args[_key] = arguments[_key];
|
||||
}
|
||||
|
||||
var _this = babelHelpers.possibleConstructorReturn(this, (_ref = Menubar.__proto__ || Object.getPrototypeOf(Menubar)).call.apply(_ref, [this].concat(args)));
|
||||
|
||||
_this.top = false;
|
||||
_this.folded = false;
|
||||
_this.foldAlt = false;
|
||||
_this.$menuBody = _this.$el.children('.site-menubar-body');
|
||||
_this.$menu = _this.$el.find('[data-plugin=menu]');
|
||||
|
||||
if ($BODY.data('autoMenubar') === false || $BODY.is('.site-menubar-keep')) {
|
||||
if ($BODY.hasClass('site-menubar-fold')) {
|
||||
_this.auto = 'fold';
|
||||
} else if ($BODY.hasClass('site-menubar-unfold')) {
|
||||
_this.auto = 'unfold';
|
||||
}
|
||||
} else {
|
||||
_this.auto = true;
|
||||
}
|
||||
|
||||
var breakpoint = Breakpoints.current();
|
||||
if (_this.auto === true) {
|
||||
if (breakpoint) {
|
||||
switch (breakpoint.name) {
|
||||
case 'lg':
|
||||
_this.type = 'unfold';
|
||||
break;
|
||||
case 'md':
|
||||
case 'sm':
|
||||
_this.type = 'fold';
|
||||
break;
|
||||
case 'xs':
|
||||
_this.type = 'hide';
|
||||
break;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
switch (_this.auto) {
|
||||
case 'fold':
|
||||
if (breakpoint.name == 'xs') {
|
||||
_this.type = 'hide';
|
||||
} else {
|
||||
_this.type = 'fold';
|
||||
}
|
||||
break;
|
||||
case 'unfold':
|
||||
if (breakpoint.name == 'xs') {
|
||||
_this.type = 'hide';
|
||||
} else {
|
||||
_this.type = 'unfold';
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return _this;
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Menubar, [{
|
||||
key: 'initialize',
|
||||
value: function initialize() {
|
||||
if (this.$menuBody.length > 0) {
|
||||
this.initialized = true;
|
||||
} else {
|
||||
this.initialized = false;
|
||||
return;
|
||||
}
|
||||
|
||||
this.scrollable = new Scrollable(this.$menuBody);
|
||||
this.hoverscroll = new Hoverscroll(this.$menuBody);
|
||||
|
||||
$HTML.removeClass('css-menubar').addClass('js-menubar');
|
||||
|
||||
if ($BODY.is('.site-menubar-top')) {
|
||||
this.top = true;
|
||||
}
|
||||
|
||||
if ($BODY.is('.site-menubar-fold-alt')) {
|
||||
this.foldAlt = true;
|
||||
}
|
||||
|
||||
this.change(this.type);
|
||||
}
|
||||
}, {
|
||||
key: 'process',
|
||||
value: function process() {
|
||||
(0, _jquery2.default)('.site-menu-sub').on('touchstart', function (e) {
|
||||
e.stopPropagation();
|
||||
}).on('ponitstart', function (e) {
|
||||
e.stopPropagation();
|
||||
});
|
||||
}
|
||||
}, {
|
||||
key: 'getMenuApi',
|
||||
value: function getMenuApi() {
|
||||
return this.$menu.data('menuApi');
|
||||
}
|
||||
}, {
|
||||
key: 'setMenuData',
|
||||
value: function setMenuData() {
|
||||
var api = this.getMenuApi();
|
||||
|
||||
if (api) {
|
||||
api.folded = this.folded;
|
||||
api.foldAlt = this.foldAlt;
|
||||
api.outerHeight = this.$el.outerHeight();
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'update',
|
||||
value: function update() {
|
||||
this.scrollable.update();
|
||||
this.hoverscroll.update();
|
||||
}
|
||||
}, {
|
||||
key: 'change',
|
||||
value: function change(type) {
|
||||
if (this.initialized) {
|
||||
this.reset();
|
||||
this[type]();
|
||||
this.setMenuData();
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'animate',
|
||||
value: function animate(doing) {
|
||||
var _this2 = this;
|
||||
|
||||
var callback = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : function () {};
|
||||
|
||||
$BODY.addClass('site-menubar-changing');
|
||||
|
||||
doing.call(this);
|
||||
|
||||
this.$el.trigger('changing.site.menubar');
|
||||
|
||||
var menuApi = this.getMenuApi();
|
||||
if (menuApi) {
|
||||
menuApi.refresh();
|
||||
}
|
||||
|
||||
setTimeout(function () {
|
||||
callback.call(_this2);
|
||||
$BODY.removeClass('site-menubar-changing');
|
||||
_this2.update();
|
||||
_this2.$el.trigger('changed.site.menubar');
|
||||
}, 500);
|
||||
}
|
||||
}, {
|
||||
key: 'reset',
|
||||
value: function reset() {
|
||||
$BODY.removeClass('site-menubar-hide site-menubar-open site-menubar-fold site-menubar-unfold');
|
||||
$HTML.removeClass('disable-scrolling');
|
||||
}
|
||||
}, {
|
||||
key: 'open',
|
||||
value: function open() {
|
||||
this.animate(function () {
|
||||
$BODY.addClass('site-menubar-open site-menubar-unfold');
|
||||
|
||||
$HTML.addClass('disable-scrolling');
|
||||
}, function () {
|
||||
this.scrollable.enable();
|
||||
});
|
||||
|
||||
this.type = 'open';
|
||||
}
|
||||
}, {
|
||||
key: 'hide',
|
||||
value: function hide() {
|
||||
this.hoverscroll.disable();
|
||||
|
||||
this.animate(function () {
|
||||
$BODY.addClass('site-menubar-hide site-menubar-unfold');
|
||||
}, function () {
|
||||
this.scrollable.enable();
|
||||
});
|
||||
|
||||
this.type = 'hide';
|
||||
}
|
||||
}, {
|
||||
key: 'unfold',
|
||||
value: function unfold() {
|
||||
this.hoverscroll.disable();
|
||||
|
||||
this.animate(function () {
|
||||
$BODY.addClass('site-menubar-unfold');
|
||||
this.folded = false;
|
||||
}, function () {
|
||||
this.scrollable.enable();
|
||||
|
||||
this.triggerResize();
|
||||
});
|
||||
|
||||
this.type = 'unfold';
|
||||
}
|
||||
}, {
|
||||
key: 'fold',
|
||||
value: function fold() {
|
||||
this.scrollable.disable();
|
||||
|
||||
this.animate(function () {
|
||||
$BODY.addClass('site-menubar-fold');
|
||||
this.folded = true;
|
||||
}, function () {
|
||||
this.hoverscroll.enable();
|
||||
|
||||
this.triggerResize();
|
||||
});
|
||||
|
||||
this.type = 'fold';
|
||||
}
|
||||
}]);
|
||||
return Menubar;
|
||||
}(_Component3.default);
|
||||
|
||||
exports.default = Menubar;
|
||||
});
|
||||
+106
@@ -0,0 +1,106 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Section/PageAside', ['exports', 'jquery', 'Component'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Component'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Component);
|
||||
global.SectionPageAside = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Component2) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Component3 = babelHelpers.interopRequireDefault(_Component2);
|
||||
|
||||
var $BODY = (0, _jquery2.default)('body');
|
||||
|
||||
var PageAside = function (_Component) {
|
||||
babelHelpers.inherits(PageAside, _Component);
|
||||
|
||||
function PageAside() {
|
||||
var _ref;
|
||||
|
||||
babelHelpers.classCallCheck(this, PageAside);
|
||||
|
||||
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
|
||||
args[_key] = arguments[_key];
|
||||
}
|
||||
|
||||
var _this = babelHelpers.possibleConstructorReturn(this, (_ref = PageAside.__proto__ || Object.getPrototypeOf(PageAside)).call.apply(_ref, [this].concat(args)));
|
||||
|
||||
_this.$scroll = _this.$el.find('.page-aside-scroll');
|
||||
_this.scrollable = _this.$scroll.asScrollable({
|
||||
namespace: 'scrollable',
|
||||
contentSelector: '> [data-role=\'content\']',
|
||||
containerSelector: '> [data-role=\'container\']'
|
||||
}).data('asScrollable');
|
||||
return _this;
|
||||
}
|
||||
|
||||
babelHelpers.createClass(PageAside, [{
|
||||
key: 'process',
|
||||
value: function process() {
|
||||
var _this2 = this;
|
||||
|
||||
if ($BODY.is('.page-aside-fixed') || $BODY.is('.page-aside-scroll')) {
|
||||
this.$el.on('transitionend', function () {
|
||||
_this2.scrollable.update();
|
||||
});
|
||||
}
|
||||
|
||||
Breakpoints.on('change', function () {
|
||||
var current = Breakpoints.current().name;
|
||||
|
||||
if (!$BODY.is('.page-aside-fixed') && !$BODY.is('.page-aside-scroll')) {
|
||||
if (current === 'xs') {
|
||||
_this2.scrollable.enable();
|
||||
_this2.$el.on('transitionend', function () {
|
||||
_this2.scrollable.update();
|
||||
});
|
||||
} else {
|
||||
_this2.$el.off('transitionend');
|
||||
_this2.scrollable.update();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
(0, _jquery2.default)(document).on('click.pageAsideScroll', '.page-aside-switch', function () {
|
||||
var isOpen = _this2.$el.hasClass('open');
|
||||
|
||||
if (isOpen) {
|
||||
_this2.$el.removeClass('open');
|
||||
} else {
|
||||
_this2.scrollable.update();
|
||||
_this2.$el.addClass('open');
|
||||
}
|
||||
});
|
||||
|
||||
(0, _jquery2.default)(document).on('click.pageAsideScroll', '[data-toggle="collapse"]', function (e) {
|
||||
var $trigger = (0, _jquery2.default)(e.target);
|
||||
if (!$trigger.is('[data-toggle="collapse"]')) {
|
||||
$trigger = $trigger.parents('[data-toggle="collapse"]');
|
||||
}
|
||||
var href = void 0;
|
||||
var target = $trigger.attr('data-target') || (href = $trigger.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '');
|
||||
var $target = (0, _jquery2.default)(target);
|
||||
|
||||
if ($target.attr('id') === 'site-navbar-collapse') {
|
||||
_this2.scrollable.update();
|
||||
}
|
||||
});
|
||||
}
|
||||
}]);
|
||||
return PageAside;
|
||||
}(_Component3.default);
|
||||
|
||||
exports.default = PageAside;
|
||||
});
|
||||
+108
@@ -0,0 +1,108 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Section/Sidebar', ['exports', 'jquery', 'Base', 'Plugin'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Base'), require('Plugin'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Base, global.Plugin);
|
||||
global.SectionSidebar = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Base2, _Plugin) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Base3 = babelHelpers.interopRequireDefault(_Base2);
|
||||
|
||||
var Sidebar = function (_Base) {
|
||||
babelHelpers.inherits(Sidebar, _Base);
|
||||
|
||||
function Sidebar() {
|
||||
babelHelpers.classCallCheck(this, Sidebar);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Sidebar.__proto__ || Object.getPrototypeOf(Sidebar)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Sidebar, [{
|
||||
key: 'process',
|
||||
value: function process() {
|
||||
if (typeof _jquery2.default.slidePanel === 'undefined') {
|
||||
return;
|
||||
}
|
||||
var sidebar = this;
|
||||
(0, _jquery2.default)(document).on('click', '[data-toggle="site-sidebar"]', function () {
|
||||
var $this = (0, _jquery2.default)(this);
|
||||
|
||||
var direction = 'right';
|
||||
if ((0, _jquery2.default)('body').hasClass('site-menubar-flipped')) {
|
||||
direction = 'left';
|
||||
}
|
||||
|
||||
var options = _jquery2.default.extend({}, (0, _Plugin.getDefaults)('slidePanel'), {
|
||||
direction: direction,
|
||||
skin: 'site-sidebar',
|
||||
dragTolerance: 80,
|
||||
template: function template(options) {
|
||||
return '<div class="' + options.classes.base + ' ' + options.classes.base + '-' + options.direction + '">\n\t <div class="' + options.classes.content + ' site-sidebar-content"></div>\n\t <div class="slidePanel-handler"></div>\n\t </div>';
|
||||
},
|
||||
afterLoad: function afterLoad() {
|
||||
var self = this;
|
||||
this.$panel.find('.tab-pane').asScrollable({
|
||||
namespace: 'scrollable',
|
||||
contentSelector: '> div',
|
||||
containerSelector: '> div'
|
||||
});
|
||||
|
||||
sidebar.initializePlugins(self.$panel);
|
||||
|
||||
this.$panel.on('shown.bs.tab', function () {
|
||||
self.$panel.find('.tab-pane.active').asScrollable('update');
|
||||
});
|
||||
},
|
||||
beforeShow: function beforeShow() {
|
||||
if (!$this.hasClass('active')) {
|
||||
$this.addClass('active');
|
||||
}
|
||||
},
|
||||
afterHide: function afterHide() {
|
||||
if ($this.hasClass('active')) {
|
||||
$this.removeClass('active');
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
if ($this.hasClass('active')) {
|
||||
_jquery2.default.slidePanel.hide();
|
||||
} else {
|
||||
var url = $this.data('url');
|
||||
if (!url) {
|
||||
url = $this.attr('href');
|
||||
url = url && url.replace(/.*(?=#[^\s]*$)/, '');
|
||||
}
|
||||
|
||||
_jquery2.default.slidePanel.show({
|
||||
url: url
|
||||
}, options);
|
||||
}
|
||||
});
|
||||
|
||||
(0, _jquery2.default)(document).on('click', '[data-toggle="show-chat"]', function () {
|
||||
(0, _jquery2.default)('#conversation').addClass('active');
|
||||
});
|
||||
|
||||
(0, _jquery2.default)(document).on('click', '[data-toggle="close-chat"]', function () {
|
||||
(0, _jquery2.default)('#conversation').removeClass('active');
|
||||
});
|
||||
}
|
||||
}]);
|
||||
return Sidebar;
|
||||
}(_Base3.default);
|
||||
|
||||
exports.default = Sidebar;
|
||||
});
|
||||
+385
@@ -0,0 +1,385 @@
|
||||
(function (global, factory) {
|
||||
if (typeof define === "function" && define.amd) {
|
||||
define('/Site', ['exports', 'jquery', 'Config', 'Base', 'Menubar', 'GridMenu', 'Sidebar', 'PageAside'], factory);
|
||||
} else if (typeof exports !== "undefined") {
|
||||
factory(exports, require('jquery'), require('Config'), require('Base'), require('Menubar'), require('GridMenu'), require('Sidebar'), require('PageAside'));
|
||||
} else {
|
||||
var mod = {
|
||||
exports: {}
|
||||
};
|
||||
factory(mod.exports, global.jQuery, global.Config, global.Base, global.SectionMenubar, global.SectionGridMenu, global.SectionSidebar, global.SectionPageAside);
|
||||
global.Site = mod.exports;
|
||||
}
|
||||
})(this, function (exports, _jquery, _Config, _Base2, _Menubar, _GridMenu, _Sidebar, _PageAside) {
|
||||
'use strict';
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
exports.getInstance = exports.run = exports.Site = undefined;
|
||||
|
||||
var _jquery2 = babelHelpers.interopRequireDefault(_jquery);
|
||||
|
||||
var _Base3 = babelHelpers.interopRequireDefault(_Base2);
|
||||
|
||||
var _Menubar2 = babelHelpers.interopRequireDefault(_Menubar);
|
||||
|
||||
var _GridMenu2 = babelHelpers.interopRequireDefault(_GridMenu);
|
||||
|
||||
var _Sidebar2 = babelHelpers.interopRequireDefault(_Sidebar);
|
||||
|
||||
var _PageAside2 = babelHelpers.interopRequireDefault(_PageAside);
|
||||
|
||||
var DOC = document;
|
||||
var $DOC = (0, _jquery2.default)(document);
|
||||
var $BODY = (0, _jquery2.default)('body');
|
||||
|
||||
var Site = function (_Base) {
|
||||
babelHelpers.inherits(Site, _Base);
|
||||
|
||||
function Site() {
|
||||
babelHelpers.classCallCheck(this, Site);
|
||||
return babelHelpers.possibleConstructorReturn(this, (Site.__proto__ || Object.getPrototypeOf(Site)).apply(this, arguments));
|
||||
}
|
||||
|
||||
babelHelpers.createClass(Site, [{
|
||||
key: 'initialize',
|
||||
value: function initialize() {
|
||||
var _this2 = this;
|
||||
|
||||
this.startLoading();
|
||||
this.initializePluginAPIs();
|
||||
this.initializePlugins();
|
||||
|
||||
this.initComponents();
|
||||
|
||||
setTimeout(function () {
|
||||
_this2.setDefaultState();
|
||||
}, 500);
|
||||
}
|
||||
}, {
|
||||
key: 'process',
|
||||
value: function process() {
|
||||
this.polyfillIEWidth();
|
||||
this.initBootstrap();
|
||||
|
||||
this.setupMenubar();
|
||||
this.setupGridMenu();
|
||||
this.setupFullScreen();
|
||||
this.setupMegaNavbar();
|
||||
this.setupTour();
|
||||
this.setupNavbarCollpase();
|
||||
// Dropdown menu setup ===================
|
||||
this.$el.on('click', '.dropdown-menu-media', function (e) {
|
||||
e.stopPropagation();
|
||||
});
|
||||
}
|
||||
}, {
|
||||
key: '_getDefaultMeunbarType',
|
||||
value: function _getDefaultMeunbarType() {
|
||||
var breakpoint = this.getCurrentBreakpoint(),
|
||||
type = false;
|
||||
|
||||
if ($BODY.data('autoMenubar') === false || $BODY.is('.site-menubar-keep')) {
|
||||
if ($BODY.hasClass('site-menubar-fold')) {
|
||||
type = 'fold';
|
||||
} else if ($BODY.hasClass('site-menubar-unfold')) {
|
||||
type = 'unfold';
|
||||
}
|
||||
}
|
||||
|
||||
switch (breakpoint) {
|
||||
case 'lg':
|
||||
type = type || 'unfold';
|
||||
break;
|
||||
case 'md':
|
||||
case 'sm':
|
||||
type = type || 'fold';
|
||||
break;
|
||||
case 'xs':
|
||||
type = 'hide';
|
||||
break;
|
||||
// no default
|
||||
}
|
||||
return type;
|
||||
}
|
||||
}, {
|
||||
key: 'setDefaultState',
|
||||
value: function setDefaultState() {
|
||||
var defaultState = this.getDefaultState();
|
||||
|
||||
// menubar
|
||||
this.menubar.change(defaultState.menubarType);
|
||||
// gridmenu
|
||||
this.gridmenu.toggle(defaultState.gridmenu);
|
||||
}
|
||||
}, {
|
||||
key: 'getDefaultState',
|
||||
value: function getDefaultState() {
|
||||
var menubarType = this._getDefaultMeunbarType();
|
||||
return {
|
||||
menubarType: menubarType,
|
||||
gridmenu: false
|
||||
};
|
||||
}
|
||||
}, {
|
||||
key: 'menubarType',
|
||||
value: function menubarType(type) {
|
||||
var toggle = function toggle($el) {
|
||||
$el.toggleClass('hided', !(type === 'open'));
|
||||
$el.toggleClass('unfolded', !(type === 'fold'));
|
||||
};
|
||||
|
||||
(0, _jquery2.default)('[data-toggle="menubar"]').each(function () {
|
||||
var $this = (0, _jquery2.default)(this);
|
||||
var $hamburger = (0, _jquery2.default)(this).find('.hamburger');
|
||||
|
||||
if ($hamburger.length > 0) {
|
||||
toggle($hamburger);
|
||||
} else {
|
||||
toggle($this);
|
||||
}
|
||||
});
|
||||
}
|
||||
}, {
|
||||
key: 'initComponents',
|
||||
value: function initComponents() {
|
||||
var callback = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : undefined;
|
||||
|
||||
this.menubar = new _Menubar2.default({
|
||||
$el: (0, _jquery2.default)('.site-menubar')
|
||||
});
|
||||
this.gridmenu = new _GridMenu2.default({
|
||||
$el: (0, _jquery2.default)('.site-gridmenu')
|
||||
});
|
||||
this.sidebar = new _Sidebar2.default();
|
||||
|
||||
var $aside = (0, _jquery2.default)('.page-aside');
|
||||
if ($aside.length > 0) {
|
||||
this.aside = new _PageAside2.default({
|
||||
$el: $aside
|
||||
});
|
||||
this.aside.run();
|
||||
}
|
||||
|
||||
this.menubar.run();
|
||||
this.sidebar.run();
|
||||
}
|
||||
}, {
|
||||
key: 'getCurrentBreakpoint',
|
||||
value: function getCurrentBreakpoint() {
|
||||
var bp = Breakpoints.current();
|
||||
return bp ? bp.name : 'lg';
|
||||
}
|
||||
}, {
|
||||
key: 'initBootstrap',
|
||||
value: function initBootstrap() {
|
||||
// Tooltip setup =============
|
||||
$DOC.tooltip({
|
||||
selector: '[data-tooltip=true]',
|
||||
container: 'body'
|
||||
});
|
||||
|
||||
(0, _jquery2.default)('[data-toggle="tooltip"]').tooltip();
|
||||
(0, _jquery2.default)('[data-toggle="popover"]').popover();
|
||||
}
|
||||
}, {
|
||||
key: 'polyfillIEWidth',
|
||||
value: function polyfillIEWidth() {
|
||||
if (navigator.userAgent.match(/IEMobile\/10\.0/)) {
|
||||
var msViewportStyle = DOC.createElement('style');
|
||||
msViewportStyle.appendChild(DOC.createTextNode('@-ms-viewport{width:auto!important}'));
|
||||
DOC.querySelector('head').appendChild(msViewportStyle);
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'setupFullScreen',
|
||||
value: function setupFullScreen() {
|
||||
if (typeof screenfull !== 'undefined') {
|
||||
$DOC.on('click', '[data-toggle="fullscreen"]', function () {
|
||||
if (screenfull.enabled) {
|
||||
screenfull.toggle();
|
||||
}
|
||||
|
||||
return false;
|
||||
});
|
||||
|
||||
if (screenfull.enabled) {
|
||||
DOC.addEventListener(screenfull.raw.fullscreenchange, function () {
|
||||
(0, _jquery2.default)('[data-toggle="fullscreen"]').toggleClass('active', screenfull.isFullscreen);
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'setupGridMenu',
|
||||
value: function setupGridMenu() {
|
||||
var self = this;
|
||||
|
||||
$DOC.on('click', '[data-toggle="gridmenu"]', function () {
|
||||
var $this = (0, _jquery2.default)(this);
|
||||
var isOpened = self.gridmenu.isOpened;
|
||||
|
||||
if (isOpened) {
|
||||
$this.addClass('active').attr('aria-expanded', true);
|
||||
} else {
|
||||
$this.removeClass('active').attr('aria-expanded', false);
|
||||
}
|
||||
|
||||
self.gridmenu.toggle(!isOpened);
|
||||
});
|
||||
}
|
||||
}, {
|
||||
key: 'setupMegaNavbar',
|
||||
value: function setupMegaNavbar() {
|
||||
$DOC.on('click', '.navbar-mega .dropdown-menu', function (e) {
|
||||
e.stopPropagation();
|
||||
}).on('show.bs.dropdown', function (e) {
|
||||
var $target = (0, _jquery2.default)(e.target);
|
||||
var $trigger = e.relatedTarget ? (0, _jquery2.default)(e.relatedTarget) : $target.children('[data-toggle="dropdown"]');
|
||||
var animation = $trigger.data('animation');
|
||||
|
||||
if (animation) {
|
||||
var $menu = $target.children('.dropdown-menu');
|
||||
$menu.addClass('animation-' + animation).one('webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend', function () {
|
||||
$menu.removeClass('animation-' + animation);
|
||||
});
|
||||
}
|
||||
}).on('shown.bs.dropdown', function (e) {
|
||||
var $menu = (0, _jquery2.default)(e.target).find('.dropdown-menu-media > .list-group');
|
||||
if ($menu.length > 0) {
|
||||
var api = $menu.data('asScrollable');
|
||||
if (api) {
|
||||
api.update();
|
||||
} else {
|
||||
$menu.asScrollable({
|
||||
namespace: 'scrollable',
|
||||
contentSelector: '> [data-role=\'content\']',
|
||||
containerSelector: '> [data-role=\'container\']'
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}, {
|
||||
key: 'setupMenubar',
|
||||
value: function setupMenubar() {
|
||||
var _this3 = this;
|
||||
|
||||
(0, _jquery2.default)(document).on('click', '[data-toggle="menubar"]:visible', function () {
|
||||
var type = _this3.menubar.type;
|
||||
|
||||
switch (type) {
|
||||
case 'fold':
|
||||
type = 'unfold';
|
||||
break;
|
||||
case 'unfold':
|
||||
type = 'fold';
|
||||
break;
|
||||
case 'open':
|
||||
type = 'hide';
|
||||
break;
|
||||
case 'hide':
|
||||
type = 'open';
|
||||
break;
|
||||
// no default
|
||||
}
|
||||
|
||||
_this3.menubar.change(type);
|
||||
_this3.menubarType(type);
|
||||
return false;
|
||||
});
|
||||
|
||||
Breakpoints.on('change', function () {
|
||||
_this3.menubar.type = _this3._getDefaultMeunbarType();
|
||||
_this3.menubar.change(_this3.menubar.type);
|
||||
});
|
||||
}
|
||||
}, {
|
||||
key: 'setupNavbarCollpase',
|
||||
value: function setupNavbarCollpase() {
|
||||
(0, _jquery2.default)(document).on('click', '[data-target=\'#site-navbar-collapse\']', function (e) {
|
||||
var $trigger = (0, _jquery2.default)(this);
|
||||
var isClose = $trigger.hasClass('collapsed');
|
||||
$BODY.addClass('site-navbar-collapsing');
|
||||
$BODY.toggleClass('site-navbar-collapse-show', !isClose);
|
||||
setTimeout(function () {
|
||||
$BODY.removeClass('site-navbar-collapsing');
|
||||
}, 350);
|
||||
});
|
||||
}
|
||||
}, {
|
||||
key: 'startLoading',
|
||||
value: function startLoading() {
|
||||
if (typeof _jquery2.default.fn.animsition === 'undefined') {
|
||||
return false;
|
||||
}
|
||||
|
||||
// let loadingType = 'default';
|
||||
var assets = (0, _Config.get)('assets');
|
||||
$BODY.animsition({
|
||||
inClass: 'fade-in',
|
||||
outClass: 'fade-out',
|
||||
inDuration: 800,
|
||||
outDuration: 500,
|
||||
loading: true,
|
||||
loadingClass: 'loader-overlay',
|
||||
loadingParentElement: 'html',
|
||||
loadingInner: '\n <div class="loader-content">\n <div class="loader-index">\n <div></div>\n <div></div>\n <div></div>\n <div></div>\n <div></div>\n <div></div>\n </div>\n </div>',
|
||||
onLoadEvent: true
|
||||
});
|
||||
}
|
||||
}, {
|
||||
key: 'setupTour',
|
||||
value: function setupTour(flag) {
|
||||
if (typeof this.tour === 'undefined') {
|
||||
if (typeof introJs === 'undefined') {
|
||||
return;
|
||||
}
|
||||
var overflow = (0, _jquery2.default)('body').css('overflow'),
|
||||
self = this,
|
||||
tourOptions = (0, _Config.get)('tour');
|
||||
|
||||
this.tour = introJs();
|
||||
|
||||
this.tour.onbeforechange(function () {
|
||||
(0, _jquery2.default)('body').css('overflow', 'hidden');
|
||||
});
|
||||
|
||||
this.tour.oncomplete(function () {
|
||||
(0, _jquery2.default)('body').css('overflow', overflow);
|
||||
});
|
||||
|
||||
this.tour.onexit(function () {
|
||||
(0, _jquery2.default)('body').css('overflow', overflow);
|
||||
});
|
||||
|
||||
this.tour.setOptions(tourOptions);
|
||||
(0, _jquery2.default)('.site-tour-trigger').on('click', function () {
|
||||
self.tour.start();
|
||||
});
|
||||
}
|
||||
}
|
||||
}]);
|
||||
return Site;
|
||||
}(_Base3.default);
|
||||
|
||||
var instance = null;
|
||||
|
||||
function getInstance() {
|
||||
if (!instance) {
|
||||
instance = new Site();
|
||||
}
|
||||
return instance;
|
||||
}
|
||||
|
||||
function run() {
|
||||
var site = getInstance();
|
||||
site.run();
|
||||
}
|
||||
|
||||
exports.Site = Site;
|
||||
exports.run = run;
|
||||
exports.getInstance = getInstance;
|
||||
exports.default = Site;
|
||||
});
|
||||
+14
File diff suppressed because one or more lines are too long
+5
@@ -0,0 +1,5 @@
|
||||
define("ace/ext/beautify/php_rules",["require","exports","module","ace/token_iterator"],function(e,t,n){"use strict";var r=e("ace/token_iterator").TokenIterator;t.newLines=[{type:"support.php_tag",value:"<?php"},{type:"support.php_tag",value:"<?"},{type:"support.php_tag",value:"?>"},{type:"paren.lparen",value:"{",indent:!0},{type:"paren.rparen",breakBefore:!0,value:"}",indent:!1},{type:"paren.rparen",breakBefore:!0,value:"})",indent:!1,dontBreak:!0},{type:"comment"},{type:"text",value:";"},{type:"text",value:":",context:"php"},{type:"keyword",value:"case",indent:!0,dontBreak:!0},{type:"keyword",value:"default",indent:!0,dontBreak:!0},{type:"keyword",value:"break",indent:!1,dontBreak:!0},{type:"punctuation.doctype.end",value:">"},{type:"meta.tag.punctuation.end",value:">"},{type:"meta.tag.punctuation.begin",value:"<",blockTag:!0,indent:!0,dontBreak:!0},{type:"meta.tag.punctuation.begin",value:"</",indent:!1,breakBefore:!0,dontBreak:!0},{type:"punctuation.operator",value:";"}],t.spaces=[{type:"xml-pe",prepend:!0},{type:"entity.other.attribute-name",prepend:!0},{type:"storage.type",value:"var",append:!0},{type:"storage.type",value:"function",append:!0},{type:"keyword.operator",value:"="},{type:"keyword",value:"as",prepend:!0,append:!0},{type:"keyword",value:"function",append:!0},{type:"support.function",next:/[^\(]/,append:!0},{type:"keyword",value:"or",append:!0,prepend:!0},{type:"keyword",value:"and",append:!0,prepend:!0},{type:"keyword",value:"case",append:!0},{type:"keyword.operator",value:"||",append:!0,prepend:!0},{type:"keyword.operator",value:"&&",append:!0,prepend:!0}],t.singleTags=["!doctype","area","base","br","hr","input","img","link","meta"],t.transform=function(e,n,r){var i=e.getCurrentToken(),s=t.newLines,o=t.spaces,u=t.singleTags,a="",f=0,l=!1,c,h,p={},d,v={},m=!1,g="";while(i!==null){console.log(i);if(!i){i=e.stepForward();continue}i.type=="support.php_tag"&&i.value!="?>"?r="php":i.type=="support.php_tag"&&i.value=="?>"?r="html":i.type=="meta.tag.name.style"&&r!="css"?r="css":i.type=="meta.tag.name.style"&&r=="css"?r="html":i.type=="meta.tag.name.script"&&r!="js"?r="js":i.type=="meta.tag.name.script"&&r=="js"&&(r="html"),v=e.stepForward(),v&&v.type.indexOf("meta.tag.name")==0&&(d=v.value),p.type=="support.php_tag"&&p.value=="<?="&&(l=!0),i.type=="meta.tag.name"&&(i.value=i.value.toLowerCase()),i.type=="text"&&(i.value=i.value.trim());if(!i.value){i=v;continue}g=i.value;for(var y in o)i.type==o[y].type&&(!o[y].value||i.value==o[y].value)&&v&&(!o[y].next||o[y].next.test(v.value))&&(o[y].prepend&&(g=" "+i.value),o[y].append&&(g+=" "));i.type.indexOf("meta.tag.name")==0&&(c=i.value),m=!1;for(y in s)if(i.type==s[y].type&&(!s[y].value||i.value==s[y].value)&&(!s[y].blockTag||u.indexOf(d)===-1)&&(!s[y].context||s[y].context===r)){s[y].indent===!1&&f--;if(s[y].breakBefore&&(!s[y].prev||s[y].prev.test(p.value))){a+="\n",m=!0;for(y=0;y<f;y++)a+=" "}break}if(l===!1)for(y in s)if(p.type==s[y].type&&(!s[y].value||p.value==s[y].value)&&(!s[y].blockTag||u.indexOf(c)===-1)&&(!s[y].context||s[y].context===r)){s[y].indent===!0&&f++;if(!s[y].dontBreak&&!m){a+="\n";for(y=0;y<f;y++)a+=" "}break}a+=g,p.type=="support.php_tag"&&p.value=="?>"&&(l=!1),h=c,p=i,i=v;if(i===null)break}return a}}),define("ace/ext/beautify",["require","exports","module","ace/token_iterator","ace/ext/beautify/php_rules"],function(e,t,n){"use strict";var r=e("ace/token_iterator").TokenIterator,i=e("./beautify/php_rules").transform;t.beautify=function(e){var t=new r(e,0,0),n=t.getCurrentToken(),s=e.$modeId.split("/").pop(),o=i(t,s);e.doc.setValue(o)},t.commands=[{name:"beautify",exec:function(e){t.beautify(e.session)},bindKey:"Ctrl-Shift-B"}]});
|
||||
(function() {
|
||||
window.require(["ace/ext/beautify"], function() {});
|
||||
})();
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user