Initial Commit
This commit is contained in:
413
assets/js/lib/accounting.js
Normal file
413
assets/js/lib/accounting.js
Normal file
@ -0,0 +1,413 @@
|
||||
/*!
|
||||
* accounting.js v0.4.2
|
||||
* Copyright 2014 Open Exchange Rates
|
||||
*
|
||||
* Freely distributable under the MIT license.
|
||||
* Portions of accounting.js are inspired or borrowed from underscore.js
|
||||
*
|
||||
* Full details and documentation:
|
||||
* http://openexchangerates.github.io/accounting.js/
|
||||
*/
|
||||
|
||||
(function(root, undefined) {
|
||||
|
||||
/* --- Setup --- */
|
||||
|
||||
// Create the local library object, to be exported or referenced globally later
|
||||
var lib = {};
|
||||
|
||||
// Current version
|
||||
lib.version = '0.4.1';
|
||||
|
||||
|
||||
/* --- Exposed settings --- */
|
||||
|
||||
// The library's settings configuration object. Contains default parameters for
|
||||
// currency and number formatting
|
||||
lib.settings = {
|
||||
currency: {
|
||||
symbol : "$", // default currency symbol is '$'
|
||||
format : "%s%v", // controls output: %s = symbol, %v = value (can be object, see docs)
|
||||
decimal : ".", // decimal point separator
|
||||
thousand : ",", // thousands separator
|
||||
precision : 2, // decimal places
|
||||
grouping : 3 // digit grouping (not implemented yet)
|
||||
},
|
||||
number: {
|
||||
precision : 0, // default precision on numbers is 0
|
||||
grouping : 3, // digit grouping (not implemented yet)
|
||||
thousand : ",",
|
||||
decimal : "."
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/* --- Internal Helper Methods --- */
|
||||
|
||||
// Store reference to possibly-available ECMAScript 5 methods for later
|
||||
var nativeMap = Array.prototype.map,
|
||||
nativeIsArray = Array.isArray,
|
||||
toString = Object.prototype.toString;
|
||||
|
||||
/**
|
||||
* Tests whether supplied parameter is a string
|
||||
* from underscore.js
|
||||
*/
|
||||
function isString(obj) {
|
||||
return !!(obj === '' || (obj && obj.charCodeAt && obj.substr));
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests whether supplied parameter is a string
|
||||
* from underscore.js, delegates to ECMA5's native Array.isArray
|
||||
*/
|
||||
function isArray(obj) {
|
||||
return nativeIsArray ? nativeIsArray(obj) : toString.call(obj) === '[object Array]';
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests whether supplied parameter is a true object
|
||||
*/
|
||||
function isObject(obj) {
|
||||
return obj && toString.call(obj) === '[object Object]';
|
||||
}
|
||||
|
||||
/**
|
||||
* Extends an object with a defaults object, similar to underscore's _.defaults
|
||||
*
|
||||
* Used for abstracting parameter handling from API methods
|
||||
*/
|
||||
function defaults(object, defs) {
|
||||
var key;
|
||||
object = object || {};
|
||||
defs = defs || {};
|
||||
// Iterate over object non-prototype properties:
|
||||
for (key in defs) {
|
||||
if (defs.hasOwnProperty(key)) {
|
||||
// Replace values with defaults only if undefined (allow empty/zero values):
|
||||
if (object[key] == null) object[key] = defs[key];
|
||||
}
|
||||
}
|
||||
return object;
|
||||
}
|
||||
|
||||
/**
|
||||
* Implementation of `Array.map()` for iteration loops
|
||||
*
|
||||
* Returns a new Array as a result of calling `iterator` on each array value.
|
||||
* Defers to native Array.map if available
|
||||
*/
|
||||
function map(obj, iterator, context) {
|
||||
var results = [], i, j;
|
||||
|
||||
if (!obj) return results;
|
||||
|
||||
// Use native .map method if it exists:
|
||||
if (nativeMap && obj.map === nativeMap) return obj.map(iterator, context);
|
||||
|
||||
// Fallback for native .map:
|
||||
for (i = 0, j = obj.length; i < j; i++ ) {
|
||||
results[i] = iterator.call(context, obj[i], i, obj);
|
||||
}
|
||||
return results;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check and normalise the value of precision (must be positive integer)
|
||||
*/
|
||||
function checkPrecision(val, base) {
|
||||
val = Math.round(Math.abs(val));
|
||||
return isNaN(val)? base : val;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Parses a format string or object and returns format obj for use in rendering
|
||||
*
|
||||
* `format` is either a string with the default (positive) format, or object
|
||||
* containing `pos` (required), `neg` and `zero` values (or a function returning
|
||||
* either a string or object)
|
||||
*
|
||||
* Either string or format.pos must contain "%v" (value) to be valid
|
||||
*/
|
||||
function checkCurrencyFormat(format) {
|
||||
var defaults = lib.settings.currency.format;
|
||||
|
||||
// Allow function as format parameter (should return string or object):
|
||||
if ( typeof format === "function" ) format = format();
|
||||
|
||||
// Format can be a string, in which case `value` ("%v") must be present:
|
||||
if ( isString( format ) && format.match("%v") ) {
|
||||
|
||||
// Create and return positive, negative and zero formats:
|
||||
return {
|
||||
pos : format,
|
||||
neg : format.replace("-", "").replace("%v", "-%v"),
|
||||
zero : format
|
||||
};
|
||||
|
||||
// If no format, or object is missing valid positive value, use defaults:
|
||||
} else if ( !format || !format.pos || !format.pos.match("%v") ) {
|
||||
|
||||
// If defaults is a string, casts it to an object for faster checking next time:
|
||||
return ( !isString( defaults ) ) ? defaults : lib.settings.currency.format = {
|
||||
pos : defaults,
|
||||
neg : defaults.replace("%v", "-%v"),
|
||||
zero : defaults
|
||||
};
|
||||
|
||||
}
|
||||
// Otherwise, assume format was fine:
|
||||
return format;
|
||||
}
|
||||
|
||||
|
||||
/* --- API Methods --- */
|
||||
|
||||
/**
|
||||
* Takes a string/array of strings, removes all formatting/cruft and returns the raw float value
|
||||
* Alias: `accounting.parse(string)`
|
||||
*
|
||||
* Decimal must be included in the regular expression to match floats (defaults to
|
||||
* accounting.settings.number.decimal), so if the number uses a non-standard decimal
|
||||
* separator, provide it as the second argument.
|
||||
*
|
||||
* Also matches bracketed negatives (eg. "$ (1.99)" => -1.99)
|
||||
*
|
||||
* Doesn't throw any errors (`NaN`s become 0) but this may change in future
|
||||
*/
|
||||
var unformat = lib.unformat = lib.parse = function(value, decimal) {
|
||||
// Recursively unformat arrays:
|
||||
if (isArray(value)) {
|
||||
return map(value, function(val) {
|
||||
return unformat(val, decimal);
|
||||
});
|
||||
}
|
||||
|
||||
// Fails silently (need decent errors):
|
||||
value = value || 0;
|
||||
|
||||
// Return the value as-is if it's already a number:
|
||||
if (typeof value === "number") return value;
|
||||
|
||||
// Default decimal point comes from settings, but could be set to eg. "," in opts:
|
||||
decimal = decimal || lib.settings.number.decimal;
|
||||
|
||||
// Build regex to strip out everything except digits, decimal point and minus sign:
|
||||
var regex = new RegExp("[^0-9-" + decimal + "]", ["g"]),
|
||||
unformatted = parseFloat(
|
||||
("" + value)
|
||||
.replace(/\((.*)\)/, "-$1") // replace bracketed values with negatives
|
||||
.replace(regex, '') // strip out any cruft
|
||||
.replace(decimal, '.') // make sure decimal point is standard
|
||||
);
|
||||
|
||||
// This will fail silently which may cause trouble, let's wait and see:
|
||||
return !isNaN(unformatted) ? unformatted : 0;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Implementation of toFixed() that treats floats more like decimals
|
||||
*
|
||||
* Fixes binary rounding issues (eg. (0.615).toFixed(2) === "0.61") that present
|
||||
* problems for accounting- and finance-related software.
|
||||
*/
|
||||
var toFixed = lib.toFixed = function(value, precision) {
|
||||
precision = checkPrecision(precision, lib.settings.number.precision);
|
||||
var power = Math.pow(10, precision);
|
||||
|
||||
// Multiply up by precision, round accurately, then divide and use native toFixed():
|
||||
return (Math.round(lib.unformat(value) * power) / power).toFixed(precision);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Format a number, with comma-separated thousands and custom precision/decimal places
|
||||
* Alias: `accounting.format()`
|
||||
*
|
||||
* Localise by overriding the precision and thousand / decimal separators
|
||||
* 2nd parameter `precision` can be an object matching `settings.number`
|
||||
*/
|
||||
var formatNumber = lib.formatNumber = lib.format = function(number, precision, thousand, decimal) {
|
||||
// Resursively format arrays:
|
||||
if (isArray(number)) {
|
||||
return map(number, function(val) {
|
||||
return formatNumber(val, precision, thousand, decimal);
|
||||
});
|
||||
}
|
||||
|
||||
// Clean up number:
|
||||
number = unformat(number);
|
||||
|
||||
// Build options object from second param (if object) or all params, extending defaults:
|
||||
var opts = defaults(
|
||||
(isObject(precision) ? precision : {
|
||||
precision : precision,
|
||||
thousand : thousand,
|
||||
decimal : decimal
|
||||
}),
|
||||
lib.settings.number
|
||||
),
|
||||
|
||||
// Clean up precision
|
||||
usePrecision = checkPrecision(opts.precision),
|
||||
|
||||
// Do some calc:
|
||||
negative = number < 0 ? "-" : "",
|
||||
base = parseInt(toFixed(Math.abs(number || 0), usePrecision), 10) + "",
|
||||
mod = base.length > 3 ? base.length % 3 : 0;
|
||||
|
||||
// Format the number:
|
||||
return negative + (mod ? base.substr(0, mod) + opts.thousand : "") + base.substr(mod).replace(/(\d{3})(?=\d)/g, "$1" + opts.thousand) + (usePrecision ? opts.decimal + toFixed(Math.abs(number), usePrecision).split('.')[1] : "");
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Format a number into currency
|
||||
*
|
||||
* Usage: accounting.formatMoney(number, symbol, precision, thousandsSep, decimalSep, format)
|
||||
* defaults: (0, "$", 2, ",", ".", "%s%v")
|
||||
*
|
||||
* Localise by overriding the symbol, precision, thousand / decimal separators and format
|
||||
* Second param can be an object matching `settings.currency` which is the easiest way.
|
||||
*
|
||||
* To do: tidy up the parameters
|
||||
*/
|
||||
var formatMoney = lib.formatMoney = function(number, symbol, precision, thousand, decimal, format) {
|
||||
// Resursively format arrays:
|
||||
if (isArray(number)) {
|
||||
return map(number, function(val){
|
||||
return formatMoney(val, symbol, precision, thousand, decimal, format);
|
||||
});
|
||||
}
|
||||
|
||||
// Clean up number:
|
||||
number = unformat(number);
|
||||
|
||||
// Build options object from second param (if object) or all params, extending defaults:
|
||||
var opts = defaults(
|
||||
(isObject(symbol) ? symbol : {
|
||||
symbol : symbol,
|
||||
precision : precision,
|
||||
thousand : thousand,
|
||||
decimal : decimal,
|
||||
format : format
|
||||
}),
|
||||
lib.settings.currency
|
||||
),
|
||||
|
||||
// Check format (returns object with pos, neg and zero):
|
||||
formats = checkCurrencyFormat(opts.format),
|
||||
|
||||
// Choose which format to use for this value:
|
||||
useFormat = number > 0 ? formats.pos : number < 0 ? formats.neg : formats.zero;
|
||||
|
||||
// Return with currency symbol added:
|
||||
return useFormat.replace('%s', opts.symbol).replace('%v', formatNumber(Math.abs(number), checkPrecision(opts.precision), opts.thousand, opts.decimal));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Format a list of numbers into an accounting column, padding with whitespace
|
||||
* to line up currency symbols, thousand separators and decimals places
|
||||
*
|
||||
* List should be an array of numbers
|
||||
* Second parameter can be an object containing keys that match the params
|
||||
*
|
||||
* Returns array of accouting-formatted number strings of same length
|
||||
*
|
||||
* NB: `white-space:pre` CSS rule is required on the list container to prevent
|
||||
* browsers from collapsing the whitespace in the output strings.
|
||||
*/
|
||||
lib.formatColumn = function(list, symbol, precision, thousand, decimal, format) {
|
||||
if (!list) return [];
|
||||
|
||||
// Build options object from second param (if object) or all params, extending defaults:
|
||||
var opts = defaults(
|
||||
(isObject(symbol) ? symbol : {
|
||||
symbol : symbol,
|
||||
precision : precision,
|
||||
thousand : thousand,
|
||||
decimal : decimal,
|
||||
format : format
|
||||
}),
|
||||
lib.settings.currency
|
||||
),
|
||||
|
||||
// Check format (returns object with pos, neg and zero), only need pos for now:
|
||||
formats = checkCurrencyFormat(opts.format),
|
||||
|
||||
// Whether to pad at start of string or after currency symbol:
|
||||
padAfterSymbol = formats.pos.indexOf("%s") < formats.pos.indexOf("%v") ? true : false,
|
||||
|
||||
// Store value for the length of the longest string in the column:
|
||||
maxLength = 0,
|
||||
|
||||
// Format the list according to options, store the length of the longest string:
|
||||
formatted = map(list, function(val, i) {
|
||||
if (isArray(val)) {
|
||||
// Recursively format columns if list is a multi-dimensional array:
|
||||
return lib.formatColumn(val, opts);
|
||||
} else {
|
||||
// Clean up the value
|
||||
val = unformat(val);
|
||||
|
||||
// Choose which format to use for this value (pos, neg or zero):
|
||||
var useFormat = val > 0 ? formats.pos : val < 0 ? formats.neg : formats.zero,
|
||||
|
||||
// Format this value, push into formatted list and save the length:
|
||||
fVal = useFormat.replace('%s', opts.symbol).replace('%v', formatNumber(Math.abs(val), checkPrecision(opts.precision), opts.thousand, opts.decimal));
|
||||
|
||||
if (fVal.length > maxLength) maxLength = fVal.length;
|
||||
return fVal;
|
||||
}
|
||||
});
|
||||
|
||||
// Pad each number in the list and send back the column of numbers:
|
||||
return map(formatted, function(val, i) {
|
||||
// Only if this is a string (not a nested array, which would have already been padded):
|
||||
if (isString(val) && val.length < maxLength) {
|
||||
// Depending on symbol position, pad after symbol or at index 0:
|
||||
return padAfterSymbol ? val.replace(opts.symbol, opts.symbol+(new Array(maxLength - val.length + 1).join(" "))) : (new Array(maxLength - val.length + 1).join(" ")) + val;
|
||||
}
|
||||
return val;
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
/* --- Module Definition --- */
|
||||
|
||||
// Export accounting for CommonJS. If being loaded as an AMD module, define it as such.
|
||||
// Otherwise, just add `accounting` to the global object
|
||||
if (typeof exports !== 'undefined') {
|
||||
if (typeof module !== 'undefined' && module.exports) {
|
||||
exports = module.exports = lib;
|
||||
}
|
||||
exports.accounting = lib;
|
||||
} else if (typeof define === 'function' && define.amd) {
|
||||
// Return the library as an AMD module:
|
||||
define([], function() {
|
||||
return lib;
|
||||
});
|
||||
} else {
|
||||
// Use accounting.noConflict to restore `accounting` back to its original value.
|
||||
// Returns a reference to the library's `accounting` object;
|
||||
// e.g. `var numbers = accounting.noConflict();`
|
||||
lib.noConflict = (function(oldAccounting) {
|
||||
return function() {
|
||||
// Reset the value of the root's `accounting` variable:
|
||||
root.accounting = oldAccounting;
|
||||
// Delete the noConflict method:
|
||||
lib.noConflict = undefined;
|
||||
// Return reference to the library to re-assign it:
|
||||
return lib;
|
||||
};
|
||||
})(root.accounting);
|
||||
|
||||
// Declare `fx` on the root (global/window) object:
|
||||
root['accounting'] = lib;
|
||||
}
|
||||
|
||||
// Root will be `window` in browser or `global` on the server:
|
||||
}(this));
|
11
assets/js/lib/accounting.min.js
vendored
Normal file
11
assets/js/lib/accounting.min.js
vendored
Normal file
@ -0,0 +1,11 @@
|
||||
/*!
|
||||
* accounting.js v0.4.2
|
||||
* Copyright 2014 Open Exchange Rates
|
||||
*
|
||||
* Freely distributable under the MIT license.
|
||||
* Portions of accounting.js are inspired or borrowed from underscore.js
|
||||
*
|
||||
* Full details and documentation:
|
||||
* http://openexchangerates.github.io/accounting.js/
|
||||
*/
|
||||
!function(n,r){var e={version:"0.4.1",settings:{currency:{symbol:"$",format:"%s%v",decimal:".",thousand:",",precision:2,grouping:3},number:{precision:0,grouping:3,thousand:",",decimal:"."}}},t=Array.prototype.map,o=Array.isArray,a=Object.prototype.toString;function i(n){return!!(""===n||n&&n.charCodeAt&&n.substr)}function u(n){return o?o(n):"[object Array]"===a.call(n)}function c(n){return n&&"[object Object]"===a.call(n)}function s(n,r){var e;for(e in n=n||{},r=r||{})r.hasOwnProperty(e)&&null==n[e]&&(n[e]=r[e]);return n}function f(n,r,e){var o,a,i=[];if(!n)return i;if(t&&n.map===t)return n.map(r,e);for(o=0,a=n.length;o<a;o++)i[o]=r.call(e,n[o],o,n);return i}function p(n,r){return n=Math.round(Math.abs(n)),isNaN(n)?r:n}function l(n){var r=e.settings.currency.format;return"function"==typeof n&&(n=n()),i(n)&&n.match("%v")?{pos:n,neg:n.replace("-","").replace("%v","-%v"),zero:n}:n&&n.pos&&n.pos.match("%v")?n:i(r)?e.settings.currency.format={pos:r,neg:r.replace("%v","-%v"),zero:r}:r}var m,d=e.unformat=e.parse=function(n,r){if(u(n))return f(n,(function(n){return d(n,r)}));if("number"==typeof(n=n||0))return n;r=r||e.settings.number.decimal;var t=new RegExp("[^0-9-"+r+"]",["g"]),o=parseFloat((""+n).replace(/\((.*)\)/,"-$1").replace(t,"").replace(r,"."));return isNaN(o)?0:o},g=e.toFixed=function(n,r){r=p(r,e.settings.number.precision);var t=Math.pow(10,r);return(Math.round(e.unformat(n)*t)/t).toFixed(r)},h=e.formatNumber=e.format=function(n,r,t,o){if(u(n))return f(n,(function(n){return h(n,r,t,o)}));n=d(n);var a=s(c(r)?r:{precision:r,thousand:t,decimal:o},e.settings.number),i=p(a.precision),l=n<0?"-":"",m=parseInt(g(Math.abs(n||0),i),10)+"",y=m.length>3?m.length%3:0;return l+(y?m.substr(0,y)+a.thousand:"")+m.substr(y).replace(/(\d{3})(?=\d)/g,"$1"+a.thousand)+(i?a.decimal+g(Math.abs(n),i).split(".")[1]:"")},y=e.formatMoney=function(n,r,t,o,a,i){if(u(n))return f(n,(function(n){return y(n,r,t,o,a,i)}));n=d(n);var m=s(c(r)?r:{symbol:r,precision:t,thousand:o,decimal:a,format:i},e.settings.currency),g=l(m.format);return(n>0?g.pos:n<0?g.neg:g.zero).replace("%s",m.symbol).replace("%v",h(Math.abs(n),p(m.precision),m.thousand,m.decimal))};e.formatColumn=function(n,r,t,o,a,m){if(!n)return[];var g=s(c(r)?r:{symbol:r,precision:t,thousand:o,decimal:a,format:m},e.settings.currency),y=l(g.format),b=y.pos.indexOf("%s")<y.pos.indexOf("%v"),v=0,x=f(n,(function(n,r){if(u(n))return e.formatColumn(n,g);var t=((n=d(n))>0?y.pos:n<0?y.neg:y.zero).replace("%s",g.symbol).replace("%v",h(Math.abs(n),p(g.precision),g.thousand,g.decimal));return t.length>v&&(v=t.length),t}));return f(x,(function(n,r){return i(n)&&n.length<v?b?n.replace(g.symbol,g.symbol+new Array(v-n.length+1).join(" ")):new Array(v-n.length+1).join(" ")+n:n}))},"undefined"!=typeof exports?("undefined"!=typeof module&&module.exports&&(exports=module.exports=e),exports.accounting=e):"function"==typeof define&&define.amd?define([],(function(){return e})):(e.noConflict=(m=n.accounting,function(){return n.accounting=m,e.noConflict=void 0,e}),n.accounting=e)}(this);
|
6
assets/js/lib/apexcharts.js
Normal file
6
assets/js/lib/apexcharts.js
Normal file
File diff suppressed because one or more lines are too long
6
assets/js/lib/apexcharts.min.js
vendored
Normal file
6
assets/js/lib/apexcharts.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
206
assets/js/lib/detectincognito.js
Normal file
206
assets/js/lib/detectincognito.js
Normal file
@ -0,0 +1,206 @@
|
||||
/**
|
||||
*
|
||||
* detectIncognito v22.01.x - (c) 2022 Joe Rutkowski <Joe@dreggle.com> (https://github.com/Joe12387/detectIncognito)
|
||||
*
|
||||
* Incognito & Private Browsing detection
|
||||
*
|
||||
* Support: Safari for iOS -- 8 to 15
|
||||
* Safari for macOS <= 15
|
||||
* Chrome/Chromium -- 50 to 96
|
||||
* Edge -- 15 - 18; 79 to 96
|
||||
* Firefox -- 44 to 95
|
||||
* MSIE >= 10
|
||||
*
|
||||
**/
|
||||
var detectIncognito = function (callback) {
|
||||
var browserName = "Unknown";
|
||||
|
||||
function __callback(isPrivate) {
|
||||
callback({
|
||||
isPrivate: isPrivate,
|
||||
browserName: browserName
|
||||
});
|
||||
}
|
||||
|
||||
function identifyChromium() {
|
||||
var ua = navigator.userAgent;
|
||||
if (ua.match(/Chrome/)) {
|
||||
if (ua.match(/Edg/)) {
|
||||
return "Edge"
|
||||
} else if (navigator.brave !== undefined) {
|
||||
return "Brave";
|
||||
} else if (navigator.opr !== undefined) {
|
||||
return "Opera";
|
||||
}
|
||||
return "Chrome";
|
||||
} else {
|
||||
return "Chromium";
|
||||
}
|
||||
}
|
||||
|
||||
function assertEvalToString(value) {
|
||||
return value === eval.toString().length;
|
||||
}
|
||||
|
||||
function isSafari() {
|
||||
var v = navigator.vendor;
|
||||
return v !== undefined && v.indexOf("Apple") === 0 && assertEvalToString(37);
|
||||
}
|
||||
|
||||
function isChrome() {
|
||||
var v = navigator.vendor;
|
||||
return v !== undefined && v.indexOf("Google") === 0 && assertEvalToString(33);
|
||||
}
|
||||
|
||||
function isFirefox() {
|
||||
return document.documentElement !== undefined && document.documentElement.style.MozAppearance !== undefined && assertEvalToString(37);
|
||||
}
|
||||
|
||||
function isMSIE() {
|
||||
return navigator.msSaveBlob !== undefined && assertEvalToString(39);
|
||||
}
|
||||
|
||||
/**
|
||||
* Safari (Safari for iOS & macOS)
|
||||
**/
|
||||
|
||||
function macOS_safari14() {
|
||||
try {
|
||||
window.safari.pushNotification.requestPermission("https://example.com", "private", {}, (function () { }));
|
||||
} catch (e) {
|
||||
return __callback(!new RegExp("gesture").test(e));
|
||||
}
|
||||
return __callback(false);
|
||||
}
|
||||
|
||||
function iOS_safari14() {
|
||||
var tripped = false;
|
||||
var iframe = document.createElement("iframe");
|
||||
iframe.style.display = "none";
|
||||
document.body.appendChild(iframe);
|
||||
|
||||
iframe.contentWindow.applicationCache.addEventListener("error", function () {
|
||||
tripped = true;
|
||||
return __callback(true);
|
||||
});
|
||||
|
||||
setTimeout(function () {
|
||||
if (!tripped) {
|
||||
__callback(false);
|
||||
}
|
||||
}, 100);
|
||||
}
|
||||
|
||||
function oldSafariTest() {
|
||||
var openDB = window.openDatabase;
|
||||
var storage = window.localStorage;
|
||||
try {
|
||||
openDB(null, null, null, null);
|
||||
} catch (e) {
|
||||
return __callback(true);
|
||||
}
|
||||
try {
|
||||
storage.setItem("test", "1");
|
||||
storage.removeItem("test");
|
||||
} catch (e) {
|
||||
return __callback(true);
|
||||
}
|
||||
return __callback(false);
|
||||
}
|
||||
|
||||
function safariPrivateTest() {
|
||||
var w = window;
|
||||
if (navigator.maxTouchPoints !== undefined) {
|
||||
if (w.safari !== undefined && w.DeviceMotionEvent === undefined) {
|
||||
browserName = "Safari for macOS";
|
||||
macOS_safari14();
|
||||
} else if (w.DeviceMotionEvent !== undefined) {
|
||||
browserName = "Safari for iOS";
|
||||
iOS_safari14();
|
||||
} else {
|
||||
throw new Error("detectIncognito Could not identify this version of Safari");
|
||||
}
|
||||
} else {
|
||||
oldSafariTest();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Chrome
|
||||
**/
|
||||
|
||||
function getQuotaLimit() {
|
||||
var w = window;
|
||||
if (w.performance !== undefined && w.performance.memory !== undefined && w.performance.memory.jsHeapSizeLimit !== undefined) {
|
||||
return performance.memory.jsHeapSizeLimit;
|
||||
}
|
||||
return 1073741824;
|
||||
}
|
||||
|
||||
// >= 76
|
||||
function storageQuotaChromePrivateTest() {
|
||||
navigator.webkitTemporaryStorage.queryUsageAndQuota(
|
||||
function (usage, quota) {
|
||||
__callback(quota < getQuotaLimit());
|
||||
},
|
||||
function (e) {
|
||||
throw new Error("detectIncognito somehow failed to query storage quota: " + e.message);
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
// 50 to 75
|
||||
function oldChromePrivateTest() {
|
||||
var fs = window.webkitRequestFileSystem;
|
||||
var success = function () {
|
||||
__callback(false);
|
||||
};
|
||||
var error = function () {
|
||||
__callback(true);
|
||||
};
|
||||
fs(0, 1, success, error);
|
||||
}
|
||||
|
||||
function chromePrivateTest() {
|
||||
if (Promise !== undefined && Promise.allSettled !== undefined) {
|
||||
storageQuotaChromePrivateTest();
|
||||
} else {
|
||||
oldChromePrivateTest();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Firefox
|
||||
**/
|
||||
|
||||
function firefoxPrivateTest() {
|
||||
__callback(navigator.serviceWorker === undefined);
|
||||
}
|
||||
|
||||
/**
|
||||
* MSIE
|
||||
**/
|
||||
|
||||
function msiePrivateTest() {
|
||||
__callback(window.indexedDB === undefined);
|
||||
}
|
||||
|
||||
function main() {
|
||||
if (isSafari()) {
|
||||
safariPrivateTest();
|
||||
} else if (isChrome()) {
|
||||
browserName = identifyChromium();
|
||||
chromePrivateTest();
|
||||
} else if (isFirefox()) {
|
||||
browserName = "Firefox";
|
||||
firefoxPrivateTest();
|
||||
} else if (isMSIE()) {
|
||||
browserName = "Internet Explorer";
|
||||
msiePrivateTest();
|
||||
} else {
|
||||
throw new Error("detectIncognito cannot determine the browser");
|
||||
}
|
||||
}
|
||||
|
||||
main();
|
||||
};
|
1
assets/js/lib/detectincognito.min.js
vendored
Normal file
1
assets/js/lib/detectincognito.min.js
vendored
Normal file
@ -0,0 +1 @@
|
||||
var detectIncognito=function(e){var o="Unknown";function n(n){e({isPrivate:n,browserName:o})}function t(e){return e===eval.toString().length}function i(){var e,t,i=window;if(void 0!==navigator.maxTouchPoints)if(void 0!==i.safari&&void 0===i.DeviceMotionEvent)o="Safari for macOS",function(){try{window.safari.pushNotification.requestPermission("https://example.com","private",{},(function(){}))}catch(e){return n(!new RegExp("gesture").test(e))}n(!1)}();else{if(void 0===i.DeviceMotionEvent)throw new Error("detectIncognito Could not identify this version of Safari");o="Safari for iOS",e=!1,(t=document.createElement("iframe")).style.display="none",document.body.appendChild(t),t.contentWindow.applicationCache.addEventListener("error",(function(){return e=!0,n(!0)})),setTimeout((function(){e||n(!1)}),100)}else!function(){var e=window.openDatabase,o=window.localStorage;try{e(null,null,null,null)}catch(e){return n(!0)}try{o.setItem("test","1"),o.removeItem("test")}catch(e){return n(!0)}n(!1)}()}function r(){navigator.webkitTemporaryStorage.queryUsageAndQuota((function(e,o){var t;n(o<(void 0!==(t=window).performance&&void 0!==t.performance.memory&&void 0!==t.performance.memory.jsHeapSizeLimit?performance.memory.jsHeapSizeLimit:1073741824))}),(function(e){throw new Error("detectIncognito somehow failed to query storage quota: "+e.message)}))}function a(){void 0!==Promise&&void 0!==Promise.allSettled?r():(0,window.webkitRequestFileSystem)(0,1,(function(){n(!1)}),(function(){n(!0)}))}!function(){if(void 0!==(r=navigator.vendor)&&0===r.indexOf("Apple")&&t(37))i();else if(function(){var e=navigator.vendor;return void 0!==e&&0===e.indexOf("Google")&&t(33)}())e=navigator.userAgent,o=e.match(/Chrome/)?e.match(/Edg/)?"Edge":void 0!==navigator.brave?"Brave":void 0!==navigator.opr?"Opera":"Chrome":"Chromium",a();else if(void 0!==document.documentElement&&void 0!==document.documentElement.style.MozAppearance&&t(37))o="Firefox",n(void 0===navigator.serviceWorker);else{if(void 0===navigator.msSaveBlob||!t(39))throw new Error("detectIncognito cannot determine the browser");o="Internet Explorer",n(void 0===window.indexedDB)}var e,r}()};
|
10
assets/js/lib/es6-promise.auto.min.js
vendored
Normal file
10
assets/js/lib/es6-promise.auto.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
2610
assets/js/lib/flatpicker.js
Normal file
2610
assets/js/lib/flatpicker.js
Normal file
File diff suppressed because it is too large
Load Diff
16
assets/js/lib/flatpicker.min.js
vendored
Normal file
16
assets/js/lib/flatpicker.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
622
assets/js/lib/jquery.blockUI.js
Normal file
622
assets/js/lib/jquery.blockUI.js
Normal file
@ -0,0 +1,622 @@
|
||||
/*!
|
||||
* jQuery blockUI plugin
|
||||
* Version 2.70.0-2014.11.23
|
||||
* Requires jQuery v1.7 or later
|
||||
*
|
||||
* This was heavily modified to make use of the new jQuery apis and remove deprecated code.
|
||||
*
|
||||
* Examples at: http://malsup.com/jquery/block/
|
||||
* Copyright (c) 2007-2013 M. Alsup
|
||||
* Dual licensed under the MIT and GPL licenses:
|
||||
* http://www.opensource.org/licenses/mit-license.php
|
||||
* http://www.gnu.org/licenses/gpl.html
|
||||
*
|
||||
* Thanks to Amir-Hossein Sobhi for some excellent contributions!
|
||||
*/
|
||||
|
||||
;(function() {
|
||||
/*jshint eqeqeq:false curly:false latedef:false */
|
||||
"use strict";
|
||||
|
||||
function setup($) {
|
||||
$.fn._fadeIn = $.fn.fadeIn;
|
||||
|
||||
var noOp = $.noop || function() {};
|
||||
|
||||
// this bit is to ensure we don't call setExpression when we shouldn't (with extra muscle to handle
|
||||
// confusing userAgent strings on Vista)
|
||||
var msie = /MSIE/.test(navigator.userAgent);
|
||||
var ie6 = /MSIE 6.0/.test(navigator.userAgent) && ! /MSIE 8.0/.test(navigator.userAgent);
|
||||
var mode = document.documentMode || 0;
|
||||
var setExpr = typeof document.createElement('div').style.setExpression === "function";
|
||||
|
||||
// global $ methods for blocking/unblocking the entire page
|
||||
$.blockUI = function(opts) { install(window, opts); };
|
||||
$.unblockUI = function(opts) { remove(window, opts); };
|
||||
|
||||
// convenience method for quick growl-like notifications (http://www.google.com/search?q=growl)
|
||||
$.growlUI = function(title, message, timeout, onClose) {
|
||||
var $m = $('<div class="growlUI"></div>');
|
||||
if (title) $m.append('<h1>'+title+'</h1>');
|
||||
if (message) $m.append('<h2>'+message+'</h2>');
|
||||
if (timeout === undefined) timeout = 3000;
|
||||
|
||||
// Added by konapun: Set timeout to 30 seconds if this growl is moused over, like normal toast notifications
|
||||
var callBlock = function(opts) {
|
||||
opts = opts || {};
|
||||
|
||||
$.blockUI({
|
||||
message: $m,
|
||||
fadeIn : typeof opts.fadeIn !== 'undefined' ? opts.fadeIn : 700,
|
||||
fadeOut: typeof opts.fadeOut !== 'undefined' ? opts.fadeOut : 1000,
|
||||
timeout: typeof opts.timeout !== 'undefined' ? opts.timeout : timeout,
|
||||
centerY: false,
|
||||
showOverlay: false,
|
||||
onUnblock: onClose,
|
||||
css: $.blockUI.defaults.growlCSS
|
||||
});
|
||||
};
|
||||
|
||||
callBlock();
|
||||
var nonmousedOpacity = $m.css('opacity');
|
||||
$m.mouseover(function() {
|
||||
callBlock({
|
||||
fadeIn: 0,
|
||||
timeout: 30000
|
||||
});
|
||||
|
||||
var displayBlock = $('.blockMsg');
|
||||
displayBlock.stop(); // cancel fadeout if it has started
|
||||
displayBlock.fadeTo(300, 1); // make it easier to read the message by removing transparency
|
||||
}).mouseout(function() {
|
||||
$('.blockMsg').fadeOut(1000);
|
||||
});
|
||||
// End konapun additions
|
||||
};
|
||||
|
||||
// plugin method for blocking element content
|
||||
$.fn.wu_block = function(opts) {
|
||||
if ( this[0] === window ) {
|
||||
$.blockUI( opts );
|
||||
return this;
|
||||
}
|
||||
var fullOpts = $.extend({}, $.blockUI.defaults, opts || {});
|
||||
this.each(function() {
|
||||
var $el = $(this);
|
||||
if (fullOpts.ignoreIfBlocked && $el.data('blockUI.isBlocked'))
|
||||
return;
|
||||
$el.wu_unblock({ fadeOut: 0 });
|
||||
});
|
||||
|
||||
return this.each(function() {
|
||||
if ($.css(this,'position') == 'static') {
|
||||
this.style.position = 'relative';
|
||||
$(this).data('blockUI.static', true);
|
||||
}
|
||||
this.style.zoom = 1; // force 'hasLayout' in ie
|
||||
install(this, opts);
|
||||
});
|
||||
};
|
||||
|
||||
// plugin method for unblocking element content
|
||||
$.fn.wu_unblock = function(opts) {
|
||||
if ( this[0] === window ) {
|
||||
$.unblockUI( opts );
|
||||
return this;
|
||||
}
|
||||
return this.each(function() {
|
||||
remove(this, opts);
|
||||
});
|
||||
};
|
||||
|
||||
$.blockUI.version = 2.70; // 2nd generation blocking at no extra cost!
|
||||
|
||||
// override these in your code to change the default behavior and style
|
||||
$.blockUI.defaults = {
|
||||
// message displayed when blocking (use null for no message)
|
||||
message: '<h1>Please wait...</h1>',
|
||||
|
||||
title: null, // title string; only used when theme == true
|
||||
draggable: true, // only used when theme == true (requires jquery-ui.js to be loaded)
|
||||
|
||||
theme: false, // set to true to use with jQuery UI themes
|
||||
|
||||
// styles for the message when blocking; if you wish to disable
|
||||
// these and use an external stylesheet then do this in your code:
|
||||
// $.blockUI.defaults.css = {};
|
||||
css: {
|
||||
padding: 0,
|
||||
margin: 0,
|
||||
width: '30%',
|
||||
top: '40%',
|
||||
left: '35%',
|
||||
textAlign: 'center',
|
||||
color: '#000',
|
||||
border: '3px solid #aaa',
|
||||
backgroundColor:'#fff',
|
||||
cursor: 'wait'
|
||||
},
|
||||
|
||||
// minimal style set used when themes are used
|
||||
themedCSS: {
|
||||
width: '30%',
|
||||
top: '40%',
|
||||
left: '35%'
|
||||
},
|
||||
|
||||
// styles for the overlay
|
||||
overlayCSS: {
|
||||
backgroundColor: '#000',
|
||||
opacity: 0.6,
|
||||
cursor: 'wait'
|
||||
},
|
||||
|
||||
// style to replace wait cursor before unblocking to correct issue
|
||||
// of lingering wait cursor
|
||||
cursorReset: 'default',
|
||||
|
||||
// styles applied when using $.growlUI
|
||||
growlCSS: {
|
||||
width: '350px',
|
||||
top: '10px',
|
||||
left: '',
|
||||
right: '10px',
|
||||
border: 'none',
|
||||
padding: '5px',
|
||||
opacity: 0.6,
|
||||
cursor: 'default',
|
||||
color: '#fff',
|
||||
backgroundColor: '#000',
|
||||
'-webkit-border-radius':'10px',
|
||||
'-moz-border-radius': '10px',
|
||||
'border-radius': '10px'
|
||||
},
|
||||
|
||||
// IE issues: 'about:blank' fails on HTTPS and javascript:false is s-l-o-w
|
||||
// (hat tip to Jorge H. N. de Vasconcelos)
|
||||
/*jshint scripturl:true */
|
||||
iframeSrc: /^https/i.test(window.location.href || '') ? 'javascript:false' : 'about:blank',
|
||||
|
||||
// force usage of iframe in non-IE browsers (handy for blocking applets)
|
||||
forceIframe: false,
|
||||
|
||||
// z-index for the blocking overlay
|
||||
baseZ: 1000,
|
||||
|
||||
// set these to true to have the message automatically centered
|
||||
centerX: true, // <-- only effects element blocking (page block controlled via css above)
|
||||
centerY: true,
|
||||
|
||||
// allow body element to be stetched in ie6; this makes blocking look better
|
||||
// on "short" pages. disable if you wish to prevent changes to the body height
|
||||
allowBodyStretch: true,
|
||||
|
||||
// enable if you want key and mouse events to be disabled for content that is blocked
|
||||
bindEvents: true,
|
||||
|
||||
// be default blockUI will supress tab navigation from leaving blocking content
|
||||
// (if bindEvents is true)
|
||||
constrainTabKey: true,
|
||||
|
||||
// fadeIn time in millis; set to 0 to disable fadeIn on block
|
||||
fadeIn: 200,
|
||||
|
||||
// fadeOut time in millis; set to 0 to disable fadeOut on unblock
|
||||
fadeOut: 400,
|
||||
|
||||
// time in millis to wait before auto-unblocking; set to 0 to disable auto-unblock
|
||||
timeout: 0,
|
||||
|
||||
// disable if you don't want to show the overlay
|
||||
showOverlay: true,
|
||||
|
||||
// if true, focus will be placed in the first available input field when
|
||||
// page blocking
|
||||
focusInput: true,
|
||||
|
||||
// elements that can receive focus
|
||||
focusableElements: ':input:enabled:visible',
|
||||
|
||||
// suppresses the use of overlay styles on FF/Linux (due to performance issues with opacity)
|
||||
// no longer needed in 2012
|
||||
// applyPlatformOpacityRules: true,
|
||||
|
||||
// callback method invoked when fadeIn has completed and blocking message is visible
|
||||
onBlock: null,
|
||||
|
||||
// callback method invoked when unblocking has completed; the callback is
|
||||
// passed the element that has been unblocked (which is the window object for page
|
||||
// blocks) and the options that were passed to the unblock call:
|
||||
// onUnblock(element, options)
|
||||
onUnblock: null,
|
||||
|
||||
// callback method invoked when the overlay area is clicked.
|
||||
// setting this will turn the cursor to a pointer, otherwise cursor defined in overlayCss will be used.
|
||||
onOverlayClick: null,
|
||||
|
||||
// don't ask; if you really must know: http://groups.google.com/group/jquery-en/browse_thread/thread/36640a8730503595/2f6a79a77a78e493#2f6a79a77a78e493
|
||||
quirksmodeOffsetHack: 4,
|
||||
|
||||
// class name of the message block
|
||||
blockMsgClass: 'blockMsg',
|
||||
|
||||
// if it is already blocked, then ignore it (don't unblock and reblock)
|
||||
ignoreIfBlocked: false
|
||||
};
|
||||
|
||||
// private data and functions follow...
|
||||
|
||||
var pageBlock = null;
|
||||
var pageBlockEls = [];
|
||||
|
||||
function install(el, opts) {
|
||||
var css, themedCSS;
|
||||
var full = (el == window);
|
||||
var msg = (opts && opts.message !== undefined ? opts.message : undefined);
|
||||
opts = $.extend({}, $.blockUI.defaults, opts || {});
|
||||
|
||||
if (opts.ignoreIfBlocked && $(el).data('blockUI.isBlocked'))
|
||||
return;
|
||||
|
||||
opts.overlayCSS = $.extend({}, $.blockUI.defaults.overlayCSS, opts.overlayCSS || {});
|
||||
css = $.extend({}, $.blockUI.defaults.css, opts.css || {});
|
||||
if (opts.onOverlayClick)
|
||||
opts.overlayCSS.cursor = 'pointer';
|
||||
|
||||
themedCSS = $.extend({}, $.blockUI.defaults.themedCSS, opts.themedCSS || {});
|
||||
msg = msg === undefined ? opts.message : msg;
|
||||
|
||||
// remove the current block (if there is one)
|
||||
if (full && pageBlock)
|
||||
remove(window, {fadeOut:0});
|
||||
|
||||
// if an existing element is being used as the blocking content then we capture
|
||||
// its current place in the DOM (and current display style) so we can restore
|
||||
// it when we unblock
|
||||
if (msg && typeof msg != 'string' && (msg.parentNode || msg.jquery)) {
|
||||
var node = msg.jquery ? msg[0] : msg;
|
||||
var data = {};
|
||||
$(el).data('blockUI.history', data);
|
||||
data.el = node;
|
||||
data.parent = node.parentNode;
|
||||
data.display = node.style.display;
|
||||
data.position = node.style.position;
|
||||
if (data.parent)
|
||||
data.parent.removeChild(node);
|
||||
}
|
||||
|
||||
$(el).data('blockUI.onUnblock', opts.onUnblock);
|
||||
var z = opts.baseZ;
|
||||
|
||||
// blockUI uses 3 layers for blocking, for simplicity they are all used on every platform;
|
||||
// layer1 is the iframe layer which is used to supress bleed through of underlying content
|
||||
// layer2 is the overlay layer which has opacity and a wait cursor (by default)
|
||||
// layer3 is the message content that is displayed while blocking
|
||||
var lyr1, lyr2, lyr3, s;
|
||||
if (msie || opts.forceIframe)
|
||||
lyr1 = $('<iframe class="wu_blockUI" style="z-index:'+ (z++) +';display:none;border:none;margin:0;padding:0;position:absolute;width:100%;height:100%;top:0;left:0" src="'+opts.iframeSrc+'"></iframe>');
|
||||
else
|
||||
lyr1 = $('<div class="wu_blockUI" style="display:none"></div>');
|
||||
|
||||
if (opts.theme)
|
||||
lyr2 = $('<div class="wu_blockUI blockOverlay ui-widget-overlay" style="z-index:'+ (z++) +';display:none"></div>');
|
||||
else
|
||||
lyr2 = $('<div class="wu_blockUI blockOverlay" style="z-index:'+ (z++) +';display:none;border:none;margin:0;padding:0;width:100%;height:100%;top:0;left:0"></div>');
|
||||
|
||||
if (opts.theme && full) {
|
||||
s = '<div class="wu_blockUI ' + opts.blockMsgClass + ' blockPage ui-dialog ui-widget ui-corner-all" style="z-index:'+(z+10)+';display:none;position:fixed">';
|
||||
if ( opts.title ) {
|
||||
s += '<div class="ui-widget-header ui-dialog-titlebar ui-corner-all blockTitle">'+(opts.title || ' ')+'</div>';
|
||||
}
|
||||
s += '<div class="ui-widget-content ui-dialog-content"></div>';
|
||||
s += '</div>';
|
||||
}
|
||||
else if (opts.theme) {
|
||||
s = '<div class="wu_blockUI ' + opts.blockMsgClass + ' blockElement ui-dialog ui-widget ui-corner-all" style="z-index:'+(z+10)+';display:none;position:absolute">';
|
||||
if ( opts.title ) {
|
||||
s += '<div class="ui-widget-header ui-dialog-titlebar ui-corner-all blockTitle">'+(opts.title || ' ')+'</div>';
|
||||
}
|
||||
s += '<div class="ui-widget-content ui-dialog-content"></div>';
|
||||
s += '</div>';
|
||||
}
|
||||
else if (full) {
|
||||
s = '<div class="wu_blockUI ' + opts.blockMsgClass + ' blockPage" style="z-index:'+(z+10)+';display:none;position:fixed"></div>';
|
||||
}
|
||||
else {
|
||||
s = '<div class="wu_blockUI ' + opts.blockMsgClass + ' blockElement" style="z-index:'+(z+10)+';display:none;position:absolute"></div>';
|
||||
}
|
||||
lyr3 = $(s);
|
||||
|
||||
// if we have a message, style it
|
||||
if (msg) {
|
||||
if (opts.theme) {
|
||||
lyr3.css(themedCSS);
|
||||
lyr3.addClass('ui-widget-content');
|
||||
}
|
||||
else
|
||||
lyr3.css(css);
|
||||
}
|
||||
|
||||
// style the overlay
|
||||
if (!opts.theme /*&& (!opts.applyPlatformOpacityRules)*/)
|
||||
lyr2.css(opts.overlayCSS);
|
||||
lyr2.css('position', full ? 'fixed' : 'absolute');
|
||||
|
||||
// make iframe layer transparent in IE
|
||||
if (msie || opts.forceIframe)
|
||||
lyr1.css('opacity',0.0);
|
||||
|
||||
//$([lyr1[0],lyr2[0],lyr3[0]]).appendTo(full ? 'body' : el);
|
||||
var layers = [lyr1,lyr2,lyr3], $par = full ? $('body') : $(el);
|
||||
$.each(layers, function() {
|
||||
this.appendTo($par);
|
||||
});
|
||||
|
||||
if (opts.theme && opts.draggable && $.fn.draggable) {
|
||||
lyr3.draggable({
|
||||
handle: '.ui-dialog-titlebar',
|
||||
cancel: 'li'
|
||||
});
|
||||
}
|
||||
|
||||
// ie7 must use absolute positioning in quirks mode and to account for activex issues (when scrolling)
|
||||
var expr = setExpr && (!$.support.boxModel || $('object,embed', full ? null : el).length > 0);
|
||||
if (ie6 || expr) {
|
||||
// give body 100% height
|
||||
if (full && opts.allowBodyStretch && $.support.boxModel)
|
||||
$('html,body').css('height','100%');
|
||||
|
||||
// fix ie6 issue when blocked element has a border width
|
||||
if ((ie6 || !$.support.boxModel) && !full) {
|
||||
var t = sz(el,'borderTopWidth'), l = sz(el,'borderLeftWidth');
|
||||
var fixT = t ? '(0 - '+t+')' : 0;
|
||||
var fixL = l ? '(0 - '+l+')' : 0;
|
||||
}
|
||||
|
||||
// simulate fixed position
|
||||
$.each(layers, function(i,o) {
|
||||
var s = o[0].style;
|
||||
s.position = 'absolute';
|
||||
if (i < 2) {
|
||||
if (full)
|
||||
s.setExpression('height','Math.max(document.body.scrollHeight, document.body.offsetHeight) - (jQuery.support.boxModel?0:'+opts.quirksmodeOffsetHack+') + "px"');
|
||||
else
|
||||
s.setExpression('height','this.parentNode.offsetHeight + "px"');
|
||||
if (full)
|
||||
s.setExpression('width','jQuery.support.boxModel && document.documentElement.clientWidth || document.body.clientWidth + "px"');
|
||||
else
|
||||
s.setExpression('width','this.parentNode.offsetWidth + "px"');
|
||||
if (fixL) s.setExpression('left', fixL);
|
||||
if (fixT) s.setExpression('top', fixT);
|
||||
}
|
||||
else if (opts.centerY) {
|
||||
if (full) s.setExpression('top','(document.documentElement.clientHeight || document.body.clientHeight) / 2 - (this.offsetHeight / 2) + (blah = document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop) + "px"');
|
||||
s.marginTop = 0;
|
||||
}
|
||||
else if (!opts.centerY && full) {
|
||||
var top = (opts.css && opts.css.top) ? parseInt(opts.css.top, 10) : 0;
|
||||
var expression = '((document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop) + '+top+') + "px"';
|
||||
s.setExpression('top',expression);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
// show the message
|
||||
if (msg) {
|
||||
if (opts.theme)
|
||||
lyr3.find('.ui-widget-content').append(msg);
|
||||
else
|
||||
lyr3.append(msg);
|
||||
if (msg.jquery || msg.nodeType)
|
||||
$(msg).show();
|
||||
}
|
||||
|
||||
if ((msie || opts.forceIframe) && opts.showOverlay)
|
||||
lyr1.show(); // opacity is zero
|
||||
if (opts.fadeIn) {
|
||||
var cb = opts.onBlock ? opts.onBlock : noOp;
|
||||
var cb1 = (opts.showOverlay && !msg) ? cb : noOp;
|
||||
var cb2 = msg ? cb : noOp;
|
||||
if (opts.showOverlay)
|
||||
lyr2._fadeIn(opts.fadeIn, cb1);
|
||||
if (msg)
|
||||
lyr3._fadeIn(opts.fadeIn, cb2);
|
||||
}
|
||||
else {
|
||||
if (opts.showOverlay)
|
||||
lyr2.show();
|
||||
if (msg)
|
||||
lyr3.show();
|
||||
if (opts.onBlock)
|
||||
opts.onBlock.bind(lyr3)();
|
||||
}
|
||||
|
||||
// bind key and mouse events
|
||||
bind(1, el, opts);
|
||||
|
||||
if (full) {
|
||||
pageBlock = lyr3[0];
|
||||
pageBlockEls = $(opts.focusableElements,pageBlock);
|
||||
if (opts.focusInput)
|
||||
setTimeout(focus, 20);
|
||||
}
|
||||
else
|
||||
center(lyr3[0], opts.centerX, opts.centerY);
|
||||
|
||||
if (opts.timeout) {
|
||||
// auto-unblock
|
||||
var to = setTimeout(function() {
|
||||
if (full)
|
||||
$.unblockUI(opts);
|
||||
else
|
||||
$(el).wu_unblock(opts);
|
||||
}, opts.timeout);
|
||||
$(el).data('blockUI.timeout', to);
|
||||
}
|
||||
}
|
||||
|
||||
// remove the block
|
||||
function remove(el, opts) {
|
||||
var count;
|
||||
var full = (el == window);
|
||||
var $el = $(el);
|
||||
var data = $el.data('blockUI.history');
|
||||
var to = $el.data('blockUI.timeout');
|
||||
if (to) {
|
||||
clearTimeout(to);
|
||||
$el.removeData('blockUI.timeout');
|
||||
}
|
||||
opts = $.extend({}, $.blockUI.defaults, opts || {});
|
||||
bind(0, el, opts); // unbind events
|
||||
|
||||
if (opts.onUnblock === null) {
|
||||
opts.onUnblock = $el.data('blockUI.onUnblock');
|
||||
$el.removeData('blockUI.onUnblock');
|
||||
}
|
||||
|
||||
var els;
|
||||
if (full) // crazy selector to handle odd field errors in ie6/7
|
||||
els = $('body').children().filter('.wu_blockUI').add('body > .wu_blockUI');
|
||||
else
|
||||
els = $el.find('> .wu_blockUI');
|
||||
|
||||
// fix cursor issue
|
||||
if ( opts.cursorReset ) {
|
||||
if ( els.length > 1 )
|
||||
els[1].style.cursor = opts.cursorReset;
|
||||
if ( els.length > 2 )
|
||||
els[2].style.cursor = opts.cursorReset;
|
||||
}
|
||||
|
||||
if (full)
|
||||
pageBlock = pageBlockEls = null;
|
||||
|
||||
if (opts.fadeOut) {
|
||||
count = els.length;
|
||||
els.stop().fadeOut(opts.fadeOut, function() {
|
||||
if ( --count === 0)
|
||||
reset(els,data,opts,el);
|
||||
});
|
||||
}
|
||||
else
|
||||
reset(els, data, opts, el);
|
||||
}
|
||||
|
||||
// move blocking element back into the DOM where it started
|
||||
function reset(els,data,opts,el) {
|
||||
var $el = $(el);
|
||||
if ( $el.data('blockUI.isBlocked') )
|
||||
return;
|
||||
|
||||
els.each(function(i,o) {
|
||||
// remove via DOM calls so we don't lose event handlers
|
||||
if (this.parentNode)
|
||||
this.parentNode.removeChild(this);
|
||||
});
|
||||
|
||||
if (data && data.el) {
|
||||
data.el.style.display = data.display;
|
||||
data.el.style.position = data.position;
|
||||
data.el.style.cursor = 'default'; // #59
|
||||
if (data.parent)
|
||||
data.parent.appendChild(data.el);
|
||||
$el.removeData('blockUI.history');
|
||||
}
|
||||
|
||||
if ($el.data('blockUI.static')) {
|
||||
$el.css('position', 'static'); // #22
|
||||
}
|
||||
|
||||
if (typeof opts.onUnblock == 'function')
|
||||
opts.onUnblock(el,opts);
|
||||
|
||||
// fix issue in Safari 6 where block artifacts remain until reflow
|
||||
var body = $(document.body), w = body.width(), cssW = body[0].style.width;
|
||||
body.width(w-1).width(w);
|
||||
body[0].style.width = cssW;
|
||||
}
|
||||
|
||||
// bind/unbind the handler
|
||||
function bind(b, el, opts) {
|
||||
var full = el == window, $el = $(el);
|
||||
|
||||
// don't bother unbinding if there is nothing to unbind
|
||||
if (!b && (full && !pageBlock || !full && !$el.data('blockUI.isBlocked')))
|
||||
return;
|
||||
|
||||
$el.data('blockUI.isBlocked', b);
|
||||
|
||||
// don't bind events when overlay is not in use or if bindEvents is false
|
||||
if (!full || !opts.bindEvents || (b && !opts.showOverlay))
|
||||
return;
|
||||
|
||||
// bind anchors and inputs for mouse and key events
|
||||
var events = 'mousedown mouseup keydown keypress keyup touchstart touchend touchmove';
|
||||
if (b)
|
||||
$(document).bind(events, opts, handler);
|
||||
else
|
||||
$(document).unbind(events, handler);
|
||||
|
||||
// former impl...
|
||||
// var $e = $('a,:input');
|
||||
// b ? $e.bind(events, opts, handler) : $e.unbind(events, handler);
|
||||
}
|
||||
|
||||
// event handler to suppress keyboard/mouse events when blocking
|
||||
function handler(e) {
|
||||
// allow tab navigation (conditionally)
|
||||
if (e.type === 'keydown' && e.keyCode && e.keyCode == 9) {
|
||||
if (pageBlock && e.data.constrainTabKey) {
|
||||
var els = pageBlockEls;
|
||||
var fwd = !e.shiftKey && e.target === els[els.length-1];
|
||||
var back = e.shiftKey && e.target === els[0];
|
||||
if (fwd || back) {
|
||||
setTimeout(function(){focus(back);},10);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
var opts = e.data;
|
||||
var target = $(e.target);
|
||||
if (target.hasClass('blockOverlay') && opts.onOverlayClick)
|
||||
opts.onOverlayClick(e);
|
||||
|
||||
// allow events within the message content
|
||||
if (target.parents('div.' + opts.blockMsgClass).length > 0)
|
||||
return true;
|
||||
|
||||
// allow events for content that is not being blocked
|
||||
return target.parents().children().filter('div.wu_blockUI').length === 0;
|
||||
}
|
||||
|
||||
function focus(back) {
|
||||
if (!pageBlockEls)
|
||||
return;
|
||||
var e = pageBlockEls[back===true ? pageBlockEls.length-1 : 0];
|
||||
if (e)
|
||||
e.focus();
|
||||
}
|
||||
|
||||
function center(el, x, y) {
|
||||
var p = el.parentNode, s = el.style;
|
||||
var l = ((p.offsetWidth - el.offsetWidth)/2) - sz(p,'borderLeftWidth');
|
||||
var t = ((p.offsetHeight - el.offsetHeight)/2) - sz(p,'borderTopWidth');
|
||||
if (x) s.left = l > 0 ? (l+'px') : '0';
|
||||
if (y) s.top = t > 0 ? (t+'px') : '0';
|
||||
}
|
||||
|
||||
function sz(el, p) {
|
||||
return parseInt($.css(el,p),10)||0;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
/*global define:true */
|
||||
if (typeof define === 'function' && define.amd && define.amd.jQuery) {
|
||||
define(['jquery'], setup);
|
||||
} else {
|
||||
setup(jQuery);
|
||||
}
|
||||
|
||||
})();
|
16
assets/js/lib/jquery.blockUI.min.js
vendored
Normal file
16
assets/js/lib/jquery.blockUI.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1211
assets/js/lib/jquery.fonticonpicker.js
Normal file
1211
assets/js/lib/jquery.fonticonpicker.js
Normal file
File diff suppressed because it is too large
Load Diff
13
assets/js/lib/jquery.fonticonpicker.min.js
vendored
Normal file
13
assets/js/lib/jquery.fonticonpicker.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1058
assets/js/lib/mousetrap.js
Normal file
1058
assets/js/lib/mousetrap.js
Normal file
File diff suppressed because it is too large
Load Diff
1
assets/js/lib/mousetrap.min.js
vendored
Normal file
1
assets/js/lib/mousetrap.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
3891
assets/js/lib/selectize.js
Normal file
3891
assets/js/lib/selectize.js
Normal file
File diff suppressed because it is too large
Load Diff
1
assets/js/lib/selectize.min.js
vendored
Normal file
1
assets/js/lib/selectize.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
9406
assets/js/lib/shepherd.js
Normal file
9406
assets/js/lib/shepherd.js
Normal file
File diff suppressed because it is too large
Load Diff
55
assets/js/lib/shepherd.min.js
vendored
Normal file
55
assets/js/lib/shepherd.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
3064
assets/js/lib/sweetalert2.all.js
Normal file
3064
assets/js/lib/sweetalert2.all.js
Normal file
File diff suppressed because one or more lines are too long
5
assets/js/lib/sweetalert2.all.min.js
vendored
Normal file
5
assets/js/lib/sweetalert2.all.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
194
assets/js/lib/tiptip.js
Normal file
194
assets/js/lib/tiptip.js
Normal file
@ -0,0 +1,194 @@
|
||||
/*
|
||||
* TipTip
|
||||
* Copyright 2010 Drew Wilson
|
||||
* www.drewwilson.com
|
||||
* code.drewwilson.com/entry/tiptip-jquery-plugin
|
||||
*
|
||||
* Version 1.3 - Updated: Mar. 23, 2010
|
||||
*
|
||||
* This Plug-In will create a custom tooltip to replace the default
|
||||
* browser tooltip. It is extremely lightweight and very smart in
|
||||
* that it detects the edges of the browser window and will make sure
|
||||
* the tooltip stays within the current window size. As a result the
|
||||
* tooltip will adjust itself to be displayed above, below, to the left
|
||||
* or to the right depending on what is necessary to stay within the
|
||||
* browser window. It is completely customizable as well via CSS.
|
||||
*
|
||||
* This TipTip jQuery plug-in is dual licensed under the MIT and GPL licenses:
|
||||
* http://www.opensource.org/licenses/mit-license.php
|
||||
* http://www.gnu.org/licenses/gpl.html
|
||||
*/
|
||||
|
||||
(function($){
|
||||
$.fn.tipTip = function(options) {
|
||||
var defaults = {
|
||||
activation: "hover",
|
||||
keepAlive: false,
|
||||
maxWidth: "200px",
|
||||
edgeOffset: 10,
|
||||
defaultPosition: "bottom",
|
||||
delay: 400,
|
||||
fadeIn: 200,
|
||||
fadeOut: 200,
|
||||
attribute: "title",
|
||||
content: false, // HTML or String to fill TipTIp with
|
||||
enter: function(){},
|
||||
exit: function(){}
|
||||
};
|
||||
var opts = $.extend(defaults, options);
|
||||
|
||||
// Setup tip tip elements and render them to the DOM
|
||||
if($("#tiptip_holder").length <= 0){
|
||||
var tiptip_holder = $('<div id="tiptip_holder" style="max-width:'+ opts.maxWidth +';"></div>');
|
||||
var tiptip_content = $('<div id="tiptip_content"></div>');
|
||||
var tiptip_arrow = $('<div id="tiptip_arrow"></div>');
|
||||
$("body").append(tiptip_holder.html(tiptip_content).prepend(tiptip_arrow.html('<div id="tiptip_arrow_inner"></div>')));
|
||||
} else {
|
||||
var tiptip_holder = $("#tiptip_holder");
|
||||
var tiptip_content = $("#tiptip_content");
|
||||
var tiptip_arrow = $("#tiptip_arrow");
|
||||
}
|
||||
|
||||
return this.each(function(){
|
||||
var org_elem = $(this);
|
||||
if(opts.content){
|
||||
var org_title = opts.content;
|
||||
} else {
|
||||
var org_title = org_elem.attr(opts.attribute);
|
||||
}
|
||||
if(org_title != ""){
|
||||
if(!opts.content){
|
||||
// org_elem.removeAttr(opts.attribute); //remove original Attribute
|
||||
org_elem.attr('data-' + opts.attribute, org_title); //saves a backup
|
||||
}
|
||||
var timeout = false;
|
||||
|
||||
if(opts.activation == "hover"){
|
||||
org_elem.hover(function(){
|
||||
active_tiptip();
|
||||
}, function(){
|
||||
if(!opts.keepAlive){
|
||||
deactive_tiptip();
|
||||
}
|
||||
});
|
||||
if(opts.keepAlive){
|
||||
tiptip_holder.hover(function(){}, function(){
|
||||
deactive_tiptip();
|
||||
});
|
||||
}
|
||||
} else if(opts.activation == "focus"){
|
||||
org_elem.focus(function(){
|
||||
active_tiptip();
|
||||
}).blur(function(){
|
||||
deactive_tiptip();
|
||||
});
|
||||
} else if(opts.activation == "click"){
|
||||
org_elem.click(function(){
|
||||
active_tiptip();
|
||||
return false;
|
||||
}).hover(function(){},function(){
|
||||
if(!opts.keepAlive){
|
||||
deactive_tiptip();
|
||||
}
|
||||
});
|
||||
if(opts.keepAlive){
|
||||
tiptip_holder.hover(function(){}, function(){
|
||||
deactive_tiptip();
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
function active_tiptip(){
|
||||
opts.enter.call(this);
|
||||
tiptip_content.html(org_title);
|
||||
tiptip_holder.hide().removeAttr("class").css("margin","0");
|
||||
tiptip_arrow.removeAttr("style");
|
||||
|
||||
var top = parseInt(org_elem.offset()['top']);
|
||||
var left = parseInt(org_elem.offset()['left']);
|
||||
var org_width = parseInt(org_elem.outerWidth());
|
||||
var org_height = parseInt(org_elem.outerHeight());
|
||||
var tip_w = tiptip_holder.outerWidth();
|
||||
var tip_h = tiptip_holder.outerHeight();
|
||||
var w_compare = Math.round((org_width - tip_w) / 2);
|
||||
var h_compare = Math.round((org_height - tip_h) / 2);
|
||||
var marg_left = Math.round(left + w_compare);
|
||||
var marg_top = Math.round(top + org_height + opts.edgeOffset);
|
||||
var t_class = "";
|
||||
var arrow_top = "";
|
||||
var arrow_left = Math.round(tip_w - 12) / 2;
|
||||
|
||||
if(opts.defaultPosition == "bottom"){
|
||||
t_class = "_bottom";
|
||||
} else if(opts.defaultPosition == "top"){
|
||||
t_class = "_top";
|
||||
} else if(opts.defaultPosition == "left"){
|
||||
t_class = "_left";
|
||||
} else if(opts.defaultPosition == "right"){
|
||||
t_class = "_right";
|
||||
}
|
||||
|
||||
var right_compare = (w_compare + left) < parseInt($(window).scrollLeft());
|
||||
var left_compare = (tip_w + left) > parseInt($(window).width());
|
||||
|
||||
if((right_compare && w_compare < 0) || (t_class == "_right" && !left_compare) || (t_class == "_left" && left < (tip_w + opts.edgeOffset + 5))){
|
||||
t_class = "_right";
|
||||
arrow_top = Math.round(tip_h - 13) / 2;
|
||||
arrow_left = -12;
|
||||
marg_left = Math.round(left + org_width + opts.edgeOffset);
|
||||
marg_top = Math.round(top + h_compare);
|
||||
} else if((left_compare && w_compare < 0) || (t_class == "_left" && !right_compare)){
|
||||
t_class = "_left";
|
||||
arrow_top = Math.round(tip_h - 13) / 2;
|
||||
arrow_left = Math.round(tip_w);
|
||||
marg_left = Math.round(left - (tip_w + opts.edgeOffset + 5));
|
||||
marg_top = Math.round(top + h_compare);
|
||||
}
|
||||
|
||||
var top_compare = (top + org_height + opts.edgeOffset + tip_h + 8) > parseInt($(window).height() + $(window).scrollTop());
|
||||
var bottom_compare = ((top + org_height) - (opts.edgeOffset + tip_h + 8)) < 0;
|
||||
|
||||
if(top_compare || (t_class == "_bottom" && top_compare) || (t_class == "_top" && !bottom_compare)){
|
||||
if(t_class == "_top" || t_class == "_bottom"){
|
||||
t_class = "_top";
|
||||
} else {
|
||||
t_class = t_class+"_top";
|
||||
}
|
||||
arrow_top = tip_h;
|
||||
marg_top = Math.round(top - (tip_h + 5 + opts.edgeOffset));
|
||||
} else if(bottom_compare | (t_class == "_top" && bottom_compare) || (t_class == "_bottom" && !top_compare)){
|
||||
if(t_class == "_top" || t_class == "_bottom"){
|
||||
t_class = "_bottom";
|
||||
} else {
|
||||
t_class = t_class+"_bottom";
|
||||
}
|
||||
arrow_top = -12;
|
||||
marg_top = Math.round(top + org_height + opts.edgeOffset);
|
||||
}
|
||||
|
||||
if(t_class == "_right_top" || t_class == "_left_top"){
|
||||
marg_top = marg_top + 5;
|
||||
} else if(t_class == "_right_bottom" || t_class == "_left_bottom"){
|
||||
marg_top = marg_top - 5;
|
||||
}
|
||||
if(t_class == "_left_top" || t_class == "_left_bottom"){
|
||||
marg_left = marg_left + 5;
|
||||
}
|
||||
tiptip_arrow.css({"margin-left": arrow_left+"px", "margin-top": arrow_top+"px"});
|
||||
tiptip_holder.css({"margin-left": marg_left+"px", "margin-top": marg_top+"px"}).attr("class","tip"+t_class);
|
||||
|
||||
if (timeout){ clearTimeout(timeout); }
|
||||
timeout = setTimeout(function(){ tiptip_holder.stop(true,true).fadeIn(opts.fadeIn); }, opts.delay);
|
||||
}
|
||||
|
||||
function deactive_tiptip(){
|
||||
opts.exit.call(this);
|
||||
if (timeout){ clearTimeout(timeout); }
|
||||
tiptip_holder.fadeOut(opts.fadeOut);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
})(jQuery);
|
||||
|
||||
|
1
assets/js/lib/tiptip.min.js
vendored
Normal file
1
assets/js/lib/tiptip.min.js
vendored
Normal file
@ -0,0 +1 @@
|
||||
!function(t){t.fn.tipTip=function(e){var o=t.extend({activation:"hover",keepAlive:!1,maxWidth:"200px",edgeOffset:10,defaultPosition:"bottom",delay:400,fadeIn:200,fadeOut:200,attribute:"title",content:!1,enter:function(){},exit:function(){}},e);if(t("#tiptip_holder").length<=0){var i=t('<div id="tiptip_holder" style="max-width:'+o.maxWidth+';"></div>'),n=t('<div id="tiptip_content"></div>'),r=t('<div id="tiptip_arrow"></div>');t("body").append(i.html(n).prepend(r.html('<div id="tiptip_arrow_inner"></div>')))}else i=t("#tiptip_holder"),n=t("#tiptip_content"),r=t("#tiptip_arrow");return this.each((function(){var e=t(this);if(o.content)var a=o.content;else a=e.attr(o.attribute);if(""!=a){o.content||e.attr("data-"+o.attribute,a);var f=!1;function d(){o.enter.call(this),n.html(a),i.hide().removeAttr("class").css("margin","0"),r.removeAttr("style");var d=parseInt(e.offset().top),u=parseInt(e.offset().left),p=parseInt(e.outerWidth()),l=parseInt(e.outerHeight()),h=i.outerWidth(),c=i.outerHeight(),s=Math.round((p-h)/2),_=Math.round((l-c)/2),v=Math.round(u+s),m=Math.round(d+l+o.edgeOffset),g="",b="",M=Math.round(h-12)/2;"bottom"==o.defaultPosition?g="_bottom":"top"==o.defaultPosition?g="_top":"left"==o.defaultPosition?g="_left":"right"==o.defaultPosition&&(g="_right");var w=s+u<parseInt(t(window).scrollLeft()),O=h+u>parseInt(t(window).width());w&&s<0||"_right"==g&&!O||"_left"==g&&u<h+o.edgeOffset+5?(g="_right",b=Math.round(c-13)/2,M=-12,v=Math.round(u+p+o.edgeOffset),m=Math.round(d+_)):(O&&s<0||"_left"==g&&!w)&&(g="_left",b=Math.round(c-13)/2,M=Math.round(h),v=Math.round(u-(h+o.edgeOffset+5)),m=Math.round(d+_));var x=d+l+o.edgeOffset+c+8>parseInt(t(window).height()+t(window).scrollTop()),I=d+l-(o.edgeOffset+c+8)<0;x||"_bottom"==g&&x||"_top"==g&&!I?("_top"==g||"_bottom"==g?g="_top":g+="_top",b=c,m=Math.round(d-(c+5+o.edgeOffset))):(I|("_top"==g&&I)||"_bottom"==g&&!x)&&("_top"==g||"_bottom"==g?g="_bottom":g+="_bottom",b=-12,m=Math.round(d+l+o.edgeOffset)),"_right_top"==g||"_left_top"==g?m+=5:"_right_bottom"!=g&&"_left_bottom"!=g||(m-=5),"_left_top"!=g&&"_left_bottom"!=g||(v+=5),r.css({"margin-left":M+"px","margin-top":b+"px"}),i.css({"margin-left":v+"px","margin-top":m+"px"}).attr("class","tip"+g),f&&clearTimeout(f),f=setTimeout((function(){i.stop(!0,!0).fadeIn(o.fadeIn)}),o.delay)}function u(){o.exit.call(this),f&&clearTimeout(f),i.fadeOut(o.fadeOut)}"hover"==o.activation?(e.hover((function(){d()}),(function(){o.keepAlive||u()})),o.keepAlive&&i.hover((function(){}),(function(){u()}))):"focus"==o.activation?e.focus((function(){d()})).blur((function(){u()})):"click"==o.activation&&(e.click((function(){return d(),!1})).hover((function(){}),(function(){o.keepAlive||u()})),o.keepAlive&&i.hover((function(){}),(function(){u()})))}}))}}(jQuery);
|
1
assets/js/lib/v-money.js
Normal file
1
assets/js/lib/v-money.js
Normal file
@ -0,0 +1 @@
|
||||
(function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.VMoney=t():e.VMoney=t()})(this,function(){return function(e){function t(r){if(n[r])return n[r].exports;var i=n[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,t),i.l=!0,i.exports}var n={};return t.m=e,t.c=n,t.i=function(e){return e},t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p=".",t(t.s=9)}([function(e,t,n){"use strict";t.a={prefix:"",suffix:"",thousands:",",decimal:".",precision:2}},function(e,t,n){"use strict";var r=n(2),i=n(5),u=n(0);t.a=function(e,t){if(t.value){var o=n.i(i.a)(u.a,t.value);if("INPUT"!==e.tagName.toLocaleUpperCase()){var a=e.getElementsByTagName("input");1!==a.length||(e=a[0])}e.oninput=function(){var t=e.value.length-e.selectionEnd;e.value=n.i(r.a)(e.value,o),t=Math.max(t,o.suffix.length),t=e.value.length-t,t=Math.max(t,o.prefix.length+1),n.i(r.b)(e,t),e.dispatchEvent(n.i(r.c)("change"))},e.onfocus=function(){n.i(r.b)(e,e.value.length-o.suffix.length)},e.oninput(),e.dispatchEvent(n.i(r.c)("input"))}}},function(e,t,n){"use strict";function r(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.a;"number"==typeof e&&(e=e.toFixed(o(t.precision)));var n=e.indexOf("-")>=0?"-":"",r=u(e),i=c(r,t.precision),a=d(i).split("."),p=a[0],l=a[1];return p=f(p,t.thousands),t.prefix+n+s(p,l,t.decimal)+t.suffix}function i(e,t){var n=e.indexOf("-")>=0?-1:1,r=u(e),i=c(r,t);return parseFloat(i)*n}function u(e){return d(e).replace(/\D+/g,"")||"0"}function o(e){return a(0,e,20)}function a(e,t,n){return Math.max(e,Math.min(t,n))}function c(e,t){var n=Math.pow(10,t);return(parseFloat(e)/n).toFixed(o(t))}function f(e,t){return e.replace(/(\d)(?=(?:\d{3})+\b)/gm,"$1"+t)}function s(e,t,n){return t?e+n+t:e}function d(e){return e?e.toString():""}function p(e,t){var n=function(){e.setSelectionRange(t,t)};e===document.activeElement&&(n(),setTimeout(n,1))}function l(e){var t=document.createEvent("Event");return t.initEvent(e,!0,!0),t}var m=n(0);n.d(t,"a",function(){return r}),n.d(t,"d",function(){return i}),n.d(t,"b",function(){return p}),n.d(t,"c",function(){return l})},function(e,t,n){"use strict";function r(e,t){t&&Object.keys(t).map(function(e){a.a[e]=t[e]}),e.directive("money",o.a),e.component("money",u.a)}Object.defineProperty(t,"__esModule",{value:!0});var i=n(6),u=n.n(i),o=n(1),a=n(0);n.d(t,"Money",function(){return u.a}),n.d(t,"VMoney",function(){return o.a}),n.d(t,"options",function(){return a.a}),n.d(t,"VERSION",function(){return c});var c="0.8.1";t.default=r,"undefined"!=typeof window&&window.Vue&&window.Vue.use(r)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(1),i=n(0),u=n(2);t.default={name:"Money",props:{value:{required:!0,type:[Number,String],default:0},masked:{type:Boolean,default:!1},precision:{type:Number,default:function(){return i.a.precision}},decimal:{type:String,default:function(){return i.a.decimal}},thousands:{type:String,default:function(){return i.a.thousands}},prefix:{type:String,default:function(){return i.a.prefix}},suffix:{type:String,default:function(){return i.a.suffix}}},directives:{money:r.a},data:function(){return{formattedValue:""}},watch:{value:{immediate:!0,handler:function(e,t){var r=n.i(u.a)(e,this.$props);r!==this.formattedValue&&(this.formattedValue=r)}}},methods:{change:function(e){this.$emit("input",this.masked?e.target.value:n.i(u.d)(e.target.value,this.precision))}}}},function(e,t,n){"use strict";t.a=function(e,t){return e=e||{},t=t||{},Object.keys(e).concat(Object.keys(t)).reduce(function(n,r){return n[r]=void 0===t[r]?e[r]:t[r],n},{})}},function(e,t,n){var r=n(7)(n(4),n(8),null,null);e.exports=r.exports},function(e,t){e.exports=function(e,t,n,r){var i,u=e=e||{},o=typeof e.default;"object"!==o&&"function"!==o||(i=e,u=e.default);var a="function"==typeof u?u.options:u;if(t&&(a.render=t.render,a.staticRenderFns=t.staticRenderFns),n&&(a._scopeId=n),r){var c=a.computed||(a.computed={});Object.keys(r).forEach(function(e){var t=r[e];c[e]=function(){return t}})}return{esModule:i,exports:u,options:a}}},function(e,t){e.exports={render:function(){var e=this,t=e.$createElement;return(e._self._c||t)("input",{directives:[{name:"money",rawName:"v-money",value:{precision:e.precision,decimal:e.decimal,thousands:e.thousands,prefix:e.prefix,suffix:e.suffix},expression:"{precision, decimal, thousands, prefix, suffix}"}],staticClass:"v-money",attrs:{type:"tel"},domProps:{value:e.formattedValue},on:{change:e.change}})},staticRenderFns:[]}},function(e,t,n){e.exports=n(3)}])});
|
1
assets/js/lib/v-money.min.js
vendored
Normal file
1
assets/js/lib/v-money.min.js
vendored
Normal file
@ -0,0 +1 @@
|
||||
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.VMoney=t():e.VMoney=t()}(this,(function(){return function(e){function t(r){if(n[r])return n[r].exports;var i=n[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,t),i.l=!0,i.exports}var n={};return t.m=e,t.c=n,t.i=function(e){return e},t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p=".",t(t.s=9)}([function(e,t,n){"use strict";t.a={prefix:"",suffix:"",thousands:",",decimal:".",precision:2}},function(e,t,n){"use strict";var r=n(2),i=n(5),u=n(0);t.a=function(e,t){if(t.value){var o=n.i(i.a)(u.a,t.value);if("INPUT"!==e.tagName.toLocaleUpperCase()){var a=e.getElementsByTagName("input");1!==a.length||(e=a[0])}e.oninput=function(){var t=e.value.length-e.selectionEnd;e.value=n.i(r.a)(e.value,o),t=Math.max(t,o.suffix.length),t=e.value.length-t,t=Math.max(t,o.prefix.length+1),n.i(r.b)(e,t),e.dispatchEvent(n.i(r.c)("change"))},e.onfocus=function(){n.i(r.b)(e,e.value.length-o.suffix.length)},e.oninput(),e.dispatchEvent(n.i(r.c)("input"))}}},function(e,t,n){"use strict";function r(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:l.a;"number"==typeof e&&(e=e.toFixed(o(t.precision)));var n=e.indexOf("-")>=0?"-":"",r=u(e),i=a(r,t.precision),d=s(i).split("."),p=d[0],m=d[1];return p=c(p,t.thousands),t.prefix+n+f(p,m,t.decimal)+t.suffix}function i(e,t){var n=e.indexOf("-")>=0?-1:1,r=a(u(e),t);return parseFloat(r)*n}function u(e){return s(e).replace(/\D+/g,"")||"0"}function o(e){return function(e,t,n){return Math.max(e,Math.min(t,n))}(0,e,20)}function a(e,t){var n=Math.pow(10,t);return(parseFloat(e)/n).toFixed(o(t))}function c(e,t){return e.replace(/(\d)(?=(?:\d{3})+\b)/gm,"$1"+t)}function f(e,t,n){return t?e+n+t:e}function s(e){return e?e.toString():""}function d(e,t){var n=function(){e.setSelectionRange(t,t)};e===document.activeElement&&(n(),setTimeout(n,1))}function p(e){var t=document.createEvent("Event");return t.initEvent(e,!0,!0),t}var l=n(0);n.d(t,"a",(function(){return r})),n.d(t,"d",(function(){return i})),n.d(t,"b",(function(){return d})),n.d(t,"c",(function(){return p}))},function(e,t,n){"use strict";function r(e,t){t&&Object.keys(t).map((function(e){a.a[e]=t[e]})),e.directive("money",o.a),e.component("money",u.a)}Object.defineProperty(t,"__esModule",{value:!0});var i=n(6),u=n.n(i),o=n(1),a=n(0);n.d(t,"Money",(function(){return u.a})),n.d(t,"VMoney",(function(){return o.a})),n.d(t,"options",(function(){return a.a})),n.d(t,"VERSION",(function(){return c}));var c="0.8.1";t.default=r,"undefined"!=typeof window&&window.Vue&&window.Vue.use(r)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(1),i=n(0),u=n(2);t.default={name:"Money",props:{value:{required:!0,type:[Number,String],default:0},masked:{type:Boolean,default:!1},precision:{type:Number,default:function(){return i.a.precision}},decimal:{type:String,default:function(){return i.a.decimal}},thousands:{type:String,default:function(){return i.a.thousands}},prefix:{type:String,default:function(){return i.a.prefix}},suffix:{type:String,default:function(){return i.a.suffix}}},directives:{money:r.a},data:function(){return{formattedValue:""}},watch:{value:{immediate:!0,handler:function(e,t){var r=n.i(u.a)(e,this.$props);r!==this.formattedValue&&(this.formattedValue=r)}}},methods:{change:function(e){this.$emit("input",this.masked?e.target.value:n.i(u.d)(e.target.value,this.precision))}}}},function(e,t,n){"use strict";t.a=function(e,t){return e=e||{},t=t||{},Object.keys(e).concat(Object.keys(t)).reduce((function(n,r){return n[r]=void 0===t[r]?e[r]:t[r],n}),{})}},function(e,t,n){var r=n(7)(n(4),n(8),null,null);e.exports=r.exports},function(e,t){e.exports=function(e,t,n,r){var i,u=e=e||{},o=typeof e.default;"object"!==o&&"function"!==o||(i=e,u=e.default);var a="function"==typeof u?u.options:u;if(t&&(a.render=t.render,a.staticRenderFns=t.staticRenderFns),n&&(a._scopeId=n),r){var c=a.computed||(a.computed={});Object.keys(r).forEach((function(e){var t=r[e];c[e]=function(){return t}}))}return{esModule:i,exports:u,options:a}}},function(e,t){e.exports={render:function(){var e=this,t=e.$createElement;return(e._self._c||t)("input",{directives:[{name:"money",rawName:"v-money",value:{precision:e.precision,decimal:e.decimal,thousands:e.thousands,prefix:e.prefix,suffix:e.suffix},expression:"{precision, decimal, thousands, prefix, suffix}"}],staticClass:"v-money",attrs:{type:"tel"},domProps:{value:e.formattedValue},on:{change:e.change}})},staticRenderFns:[]}},function(e,t,n){e.exports=n(3)}])}));
|
263
assets/js/lib/vue-apexcharts.js
Normal file
263
assets/js/lib/vue-apexcharts.js
Normal file
@ -0,0 +1,263 @@
|
||||
(function (global, factory) {
|
||||
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('apexcharts')) :
|
||||
typeof define === 'function' && define.amd ? define(['apexcharts'], factory) :
|
||||
(global.VueApexCharts = factory(global.ApexCharts));
|
||||
}(this, (function (ApexCharts) { 'use strict';
|
||||
|
||||
ApexCharts = ApexCharts && ApexCharts.hasOwnProperty('default') ? ApexCharts['default'] : ApexCharts;
|
||||
|
||||
function _typeof(obj) {
|
||||
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
|
||||
_typeof = function (obj) {
|
||||
return typeof obj;
|
||||
};
|
||||
} else {
|
||||
_typeof = function (obj) {
|
||||
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
||||
};
|
||||
}
|
||||
|
||||
return _typeof(obj);
|
||||
}
|
||||
|
||||
function _defineProperty(obj, key, value) {
|
||||
if (key in obj) {
|
||||
Object.defineProperty(obj, key, {
|
||||
value: value,
|
||||
enumerable: true,
|
||||
configurable: true,
|
||||
writable: true
|
||||
});
|
||||
} else {
|
||||
obj[key] = value;
|
||||
}
|
||||
|
||||
return obj;
|
||||
}
|
||||
|
||||
var ApexChartsComponent = {
|
||||
props: {
|
||||
options: {
|
||||
type: Object
|
||||
},
|
||||
type: {
|
||||
type: String
|
||||
},
|
||||
series: {
|
||||
type: Array,
|
||||
required: true,
|
||||
default: function _default() {
|
||||
return [];
|
||||
}
|
||||
},
|
||||
width: {
|
||||
default: "100%"
|
||||
},
|
||||
height: {
|
||||
default: "auto"
|
||||
}
|
||||
},
|
||||
data: function data() {
|
||||
return {
|
||||
chart: null
|
||||
};
|
||||
},
|
||||
beforeMount: function beforeMount() {
|
||||
window.ApexCharts = ApexCharts;
|
||||
},
|
||||
mounted: function mounted() {
|
||||
this.init();
|
||||
},
|
||||
created: function created() {
|
||||
var _this = this;
|
||||
|
||||
this.$watch("options", function (options) {
|
||||
if (!_this.chart && options) {
|
||||
_this.init();
|
||||
} else {
|
||||
_this.chart.updateOptions(_this.options);
|
||||
}
|
||||
});
|
||||
this.$watch("series", function (series) {
|
||||
if (!_this.chart && series) {
|
||||
_this.init();
|
||||
} else {
|
||||
_this.chart.updateSeries(_this.series);
|
||||
}
|
||||
});
|
||||
var watched = ["type", "width", "height"];
|
||||
watched.forEach(function (prop) {
|
||||
_this.$watch(prop, function () {
|
||||
_this.refresh();
|
||||
});
|
||||
});
|
||||
},
|
||||
beforeDestroy: function beforeDestroy() {
|
||||
if (!this.chart) {
|
||||
return;
|
||||
}
|
||||
|
||||
this.destroy();
|
||||
},
|
||||
render: function render(createElement) {
|
||||
return createElement("div");
|
||||
},
|
||||
methods: {
|
||||
init: function init() {
|
||||
var _this2 = this;
|
||||
|
||||
var newOptions = {
|
||||
chart: {
|
||||
type: this.type || this.options.chart.type || "line",
|
||||
height: this.height,
|
||||
width: this.width,
|
||||
events: {}
|
||||
},
|
||||
series: this.series
|
||||
};
|
||||
Object.keys(this.$listeners).forEach(function (evt) {
|
||||
newOptions.chart.events[evt] = _this2.$listeners[evt];
|
||||
});
|
||||
var config = this.extend(this.options, newOptions);
|
||||
this.chart = new ApexCharts(this.$el, config);
|
||||
return this.chart.render();
|
||||
},
|
||||
isObject: function isObject(item) {
|
||||
return item && _typeof(item) === "object" && !Array.isArray(item) && item != null;
|
||||
},
|
||||
extend: function extend(target, source) {
|
||||
var _this3 = this;
|
||||
|
||||
if (typeof Object.assign !== "function") {
|
||||
(function () {
|
||||
Object.assign = function (target) {
|
||||
// We must check against these specific cases.
|
||||
if (target === undefined || target === null) {
|
||||
throw new TypeError("Cannot convert undefined or null to object");
|
||||
}
|
||||
|
||||
var output = Object(target);
|
||||
|
||||
for (var index = 1; index < arguments.length; index++) {
|
||||
var _source = arguments[index];
|
||||
|
||||
if (_source !== undefined && _source !== null) {
|
||||
for (var nextKey in _source) {
|
||||
if (_source.hasOwnProperty(nextKey)) {
|
||||
output[nextKey] = _source[nextKey];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return output;
|
||||
};
|
||||
})();
|
||||
}
|
||||
|
||||
var output = Object.assign({}, target);
|
||||
|
||||
if (this.isObject(target) && this.isObject(source)) {
|
||||
Object.keys(source).forEach(function (key) {
|
||||
if (_this3.isObject(source[key])) {
|
||||
if (!(key in target)) {
|
||||
Object.assign(output, _defineProperty({}, key, source[key]));
|
||||
} else {
|
||||
output[key] = _this3.extend(target[key], source[key]);
|
||||
}
|
||||
} else {
|
||||
Object.assign(output, _defineProperty({}, key, source[key]));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
return output;
|
||||
},
|
||||
refresh: function refresh() {
|
||||
this.destroy();
|
||||
return this.init();
|
||||
},
|
||||
destroy: function destroy() {
|
||||
this.chart.destroy();
|
||||
},
|
||||
updateSeries: function updateSeries(newSeries, animate) {
|
||||
return this.chart.updateSeries(newSeries, animate);
|
||||
},
|
||||
updateOptions: function updateOptions(newOptions, redrawPaths, animate, updateSyncedCharts) {
|
||||
return this.chart.updateOptions(newOptions, redrawPaths, animate, updateSyncedCharts);
|
||||
},
|
||||
toggleSeries: function toggleSeries(seriesName) {
|
||||
return this.chart.toggleSeries(seriesName);
|
||||
},
|
||||
showSeries: function showSeries(seriesName) {
|
||||
this.chart.showSeries(seriesName);
|
||||
},
|
||||
hideSeries: function hideSeries(seriesName) {
|
||||
this.chart.hideSeries(seriesName);
|
||||
},
|
||||
appendSeries: function appendSeries(newSeries, animate) {
|
||||
return this.chart.appendSeries(newSeries, animate);
|
||||
},
|
||||
resetSeries: function resetSeries() {
|
||||
this.chart.resetSeries();
|
||||
},
|
||||
zoomX: function zoomX(min, max) {
|
||||
this.chart.zoomX(min, max);
|
||||
},
|
||||
toggleDataPointSelection: function toggleDataPointSelection(seriesIndex, dataPointIndex) {
|
||||
this.chart.toggleDataPointSelection(seriesIndex, dataPointIndex);
|
||||
},
|
||||
appendData: function appendData(newData) {
|
||||
return this.chart.appendData(newData);
|
||||
},
|
||||
addText: function addText(options) {
|
||||
this.chart.addText(options);
|
||||
},
|
||||
addImage: function addImage(options) {
|
||||
this.chart.addImage(options);
|
||||
},
|
||||
addShape: function addShape(options) {
|
||||
this.chart.addShape(options);
|
||||
},
|
||||
dataURI: function dataURI() {
|
||||
return this.chart.dataURI();
|
||||
},
|
||||
setLocale: function setLocale(localeName) {
|
||||
return this.chart.setLocale(localeName);
|
||||
},
|
||||
addXaxisAnnotation: function addXaxisAnnotation(options, pushToMemory) {
|
||||
this.chart.addXaxisAnnotation(options, pushToMemory);
|
||||
},
|
||||
addYaxisAnnotation: function addYaxisAnnotation(options, pushToMemory) {
|
||||
this.chart.addYaxisAnnotation(options, pushToMemory);
|
||||
},
|
||||
addPointAnnotation: function addPointAnnotation(options, pushToMemory) {
|
||||
this.chart.addPointAnnotation(options, pushToMemory);
|
||||
},
|
||||
removeAnnotation: function removeAnnotation(id, options) {
|
||||
this.chart.removeAnnotation(id, options);
|
||||
},
|
||||
clearAnnotations: function clearAnnotations() {
|
||||
this.chart.clearAnnotations();
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
var VueApexCharts = ApexChartsComponent;
|
||||
window.ApexCharts = ApexCharts;
|
||||
|
||||
VueApexCharts.install = function (Vue) {
|
||||
//adding a global method or property
|
||||
Vue.ApexCharts = ApexCharts;
|
||||
window.ApexCharts = ApexCharts; // add the instance method
|
||||
|
||||
Object.defineProperty(Vue.prototype, '$apexcharts', {
|
||||
get: function get() {
|
||||
return ApexCharts;
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
return VueApexCharts;
|
||||
|
||||
})));
|
1
assets/js/lib/vue-apexcharts.min.js
vendored
Normal file
1
assets/js/lib/vue-apexcharts.min.js
vendored
Normal file
@ -0,0 +1 @@
|
||||
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("apexcharts")):"function"==typeof define&&define.amd?define(["apexcharts"],e):t.VueApexCharts=e(t.ApexCharts)}(this,(function(t){"use strict";function e(t){return(e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function n(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}t=t&&t.hasOwnProperty("default")?t.default:t;var i={props:{options:{type:Object},type:{type:String},series:{type:Array,required:!0,default:function(){return[]}},width:{default:"100%"},height:{default:"auto"}},data:function(){return{chart:null}},beforeMount:function(){window.ApexCharts=t},mounted:function(){this.init()},created:function(){var t=this;this.$watch("options",(function(e){!t.chart&&e?t.init():t.chart.updateOptions(t.options)})),this.$watch("series",(function(e){!t.chart&&e?t.init():t.chart.updateSeries(t.series)}));["type","width","height"].forEach((function(e){t.$watch(e,(function(){t.refresh()}))}))},beforeDestroy:function(){this.chart&&this.destroy()},render:function(t){return t("div")},methods:{init:function(){var e=this,n={chart:{type:this.type||this.options.chart.type||"line",height:this.height,width:this.width,events:{}},series:this.series};Object.keys(this.$listeners).forEach((function(t){n.chart.events[t]=e.$listeners[t]}));var i=this.extend(this.options,n);return this.chart=new t(this.$el,i),this.chart.render()},isObject:function(t){return t&&"object"===e(t)&&!Array.isArray(t)&&null!=t},extend:function(t,e){var i=this;"function"!=typeof Object.assign&&(Object.assign=function(t){if(null==t)throw new TypeError("Cannot convert undefined or null to object");for(var e=Object(t),n=1;n<arguments.length;n++){var i=arguments[n];if(null!=i)for(var r in i)i.hasOwnProperty(r)&&(e[r]=i[r])}return e});var r=Object.assign({},t);return this.isObject(t)&&this.isObject(e)&&Object.keys(e).forEach((function(o){i.isObject(e[o])&&o in t?r[o]=i.extend(t[o],e[o]):Object.assign(r,n({},o,e[o]))})),r},refresh:function(){return this.destroy(),this.init()},destroy:function(){this.chart.destroy()},updateSeries:function(t,e){return this.chart.updateSeries(t,e)},updateOptions:function(t,e,n,i){return this.chart.updateOptions(t,e,n,i)},toggleSeries:function(t){return this.chart.toggleSeries(t)},showSeries:function(t){this.chart.showSeries(t)},hideSeries:function(t){this.chart.hideSeries(t)},appendSeries:function(t,e){return this.chart.appendSeries(t,e)},resetSeries:function(){this.chart.resetSeries()},zoomX:function(t,e){this.chart.zoomX(t,e)},toggleDataPointSelection:function(t,e){this.chart.toggleDataPointSelection(t,e)},appendData:function(t){return this.chart.appendData(t)},addText:function(t){this.chart.addText(t)},addImage:function(t){this.chart.addImage(t)},addShape:function(t){this.chart.addShape(t)},dataURI:function(){return this.chart.dataURI()},setLocale:function(t){return this.chart.setLocale(t)},addXaxisAnnotation:function(t,e){this.chart.addXaxisAnnotation(t,e)},addYaxisAnnotation:function(t,e){this.chart.addYaxisAnnotation(t,e)},addPointAnnotation:function(t,e){this.chart.addPointAnnotation(t,e)},removeAnnotation:function(t,e){this.chart.removeAnnotation(t,e)},clearAnnotations:function(){this.chart.clearAnnotations()}}};return window.ApexCharts=t,i.install=function(e){e.ApexCharts=t,window.ApexCharts=t,Object.defineProperty(e.prototype,"$apexcharts",{get:function(){return t}})},i}));
|
1
assets/js/lib/vue-the-mask.js
Normal file
1
assets/js/lib/vue-the-mask.js
Normal file
@ -0,0 +1 @@
|
||||
(function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.VueTheMask=t():e.VueTheMask=t()})(this,function(){return function(e){function t(r){if(n[r])return n[r].exports;var a=n[r]={i:r,l:!1,exports:{}};return e[r].call(a.exports,a,a.exports,t),a.l=!0,a.exports}var n={};return t.m=e,t.c=n,t.i=function(e){return e},t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p=".",t(t.s=10)}([function(e,t){e.exports={"#":{pattern:/\d/},X:{pattern:/[0-9a-zA-Z]/},S:{pattern:/[a-zA-Z]/},A:{pattern:/[a-zA-Z]/,transform:function(e){return e.toLocaleUpperCase()}},a:{pattern:/[a-zA-Z]/,transform:function(e){return e.toLocaleLowerCase()}},"!":{escape:!0}}},function(e,t,n){"use strict";function r(e){var t=document.createEvent("Event");return t.initEvent(e,!0,!0),t}var a=n(2),o=n(0),i=n.n(o);t.a=function(e,t){var o=t.value;if((Array.isArray(o)||"string"==typeof o)&&(o={mask:o,tokens:i.a}),"INPUT"!==e.tagName.toLocaleUpperCase()){var u=e.getElementsByTagName("input");if(1!==u.length)throw new Error("v-mask directive requires 1 input, found "+u.length);e=u[0]}e.oninput=function(t){if(t.isTrusted){var i=e.selectionEnd,u=e.value[i-1];for(e.value=n.i(a.a)(e.value,o.mask,!0,o.tokens);i<e.value.length&&e.value.charAt(i-1)!==u;)i++;e===document.activeElement&&(e.setSelectionRange(i,i),setTimeout(function(){e.setSelectionRange(i,i)},0)),e.dispatchEvent(r("input"))}};var s=n.i(a.a)(e.value,o.mask,!0,o.tokens);s!==e.value&&(e.value=s,e.dispatchEvent(r("input")))}},function(e,t,n){"use strict";var r=n(6),a=n(5);t.a=function(e,t){var o=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments[3];return Array.isArray(t)?n.i(a.a)(r.a,t,i)(e,t,o,i):n.i(r.a)(e,t,o,i)}},function(e,t,n){"use strict";function r(e){e.component(s.a.name,s.a),e.directive("mask",i.a)}Object.defineProperty(t,"__esModule",{value:!0});var a=n(0),o=n.n(a),i=n(1),u=n(7),s=n.n(u);n.d(t,"TheMask",function(){return s.a}),n.d(t,"mask",function(){return i.a}),n.d(t,"tokens",function(){return o.a}),n.d(t,"version",function(){return c});var c="0.11.1";t.default=r,"undefined"!=typeof window&&window.Vue&&window.Vue.use(r)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(1),a=n(0),o=n.n(a),i=n(2);t.default={name:"TheMask",props:{value:[String,Number],mask:{type:[String,Array],required:!0},masked:{type:Boolean,default:!1},tokens:{type:Object,default:function(){return o.a}}},directives:{mask:r.a},data:function(){return{lastValue:null,display:this.value}},watch:{value:function(e){e!==this.lastValue&&(this.display=e)},masked:function(){this.refresh(this.display)}},computed:{config:function(){return{mask:this.mask,tokens:this.tokens,masked:this.masked}}},methods:{onInput:function(e){e.isTrusted||this.refresh(e.target.value)},refresh:function(e){this.display=e;var e=n.i(i.a)(e,this.mask,this.masked,this.tokens);e!==this.lastValue&&(this.lastValue=e,this.$emit("input",e))}}}},function(e,t,n){"use strict";function r(e,t,n){return t=t.sort(function(e,t){return e.length-t.length}),function(r,a){for(var o=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=0;i<t.length;){var u=t[i];i++;var s=t[i];if(!(s&&e(r,s,!0,n).length>u.length))return e(r,u,o,n)}return""}}t.a=r},function(e,t,n){"use strict";function r(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=arguments[3];e=e||"",t=t||"";for(var a=0,o=0,i="";a<t.length&&o<e.length;){var u=t[a],s=r[u],c=e[o];s&&!s.escape?(s.pattern.test(c)&&(i+=s.transform?s.transform(c):c,a++),o++):(s&&s.escape&&(a++,u=t[a]),n&&(i+=u),c===u&&o++,a++)}for(var f="";a<t.length&&n;){var u=t[a];if(r[u]){f="";break}f+=u,a++}return i+f}t.a=r},function(e,t,n){var r=n(8)(n(4),n(9),null,null);e.exports=r.exports},function(e,t){e.exports=function(e,t,n,r){var a,o=e=e||{},i=typeof e.default;"object"!==i&&"function"!==i||(a=e,o=e.default);var u="function"==typeof o?o.options:o;if(t&&(u.render=t.render,u.staticRenderFns=t.staticRenderFns),n&&(u._scopeId=n),r){var s=u.computed||(u.computed={});Object.keys(r).forEach(function(e){var t=r[e];s[e]=function(){return t}})}return{esModule:a,exports:o,options:u}}},function(e,t){e.exports={render:function(){var e=this,t=e.$createElement;return(e._self._c||t)("input",{directives:[{name:"mask",rawName:"v-mask",value:e.config,expression:"config"}],attrs:{type:"text"},domProps:{value:e.display},on:{input:e.onInput}})},staticRenderFns:[]}},function(e,t,n){e.exports=n(3)}])});
|
1
assets/js/lib/vue-the-mask.min.js
vendored
Normal file
1
assets/js/lib/vue-the-mask.min.js
vendored
Normal file
@ -0,0 +1 @@
|
||||
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.VueTheMask=t():e.VueTheMask=t()}(this,(function(){return function(e){function t(r){if(n[r])return n[r].exports;var a=n[r]={i:r,l:!1,exports:{}};return e[r].call(a.exports,a,a.exports,t),a.l=!0,a.exports}var n={};return t.m=e,t.c=n,t.i=function(e){return e},t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p=".",t(t.s=10)}([function(e,t){e.exports={"#":{pattern:/\d/},X:{pattern:/[0-9a-zA-Z]/},S:{pattern:/[a-zA-Z]/},A:{pattern:/[a-zA-Z]/,transform:function(e){return e.toLocaleUpperCase()}},a:{pattern:/[a-zA-Z]/,transform:function(e){return e.toLocaleLowerCase()}},"!":{escape:!0}}},function(e,t,n){"use strict";function r(e){var t=document.createEvent("Event");return t.initEvent(e,!0,!0),t}var a=n(2),o=n(0),i=n.n(o);t.a=function(e,t){var o=t.value;if((Array.isArray(o)||"string"==typeof o)&&(o={mask:o,tokens:i.a}),"INPUT"!==e.tagName.toLocaleUpperCase()){var u=e.getElementsByTagName("input");if(1!==u.length)throw new Error("v-mask directive requires 1 input, found "+u.length);e=u[0]}e.oninput=function(t){if(t.isTrusted){var i=e.selectionEnd,u=e.value[i-1];for(e.value=n.i(a.a)(e.value,o.mask,!0,o.tokens);i<e.value.length&&e.value.charAt(i-1)!==u;)i++;e===document.activeElement&&(e.setSelectionRange(i,i),setTimeout((function(){e.setSelectionRange(i,i)}),0)),e.dispatchEvent(r("input"))}};var s=n.i(a.a)(e.value,o.mask,!0,o.tokens);s!==e.value&&(e.value=s,e.dispatchEvent(r("input")))}},function(e,t,n){"use strict";var r=n(6),a=n(5);t.a=function(e,t){var o=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments[3];return Array.isArray(t)?n.i(a.a)(r.a,t,i)(e,t,o,i):n.i(r.a)(e,t,o,i)}},function(e,t,n){"use strict";function r(e){e.component(s.a.name,s.a),e.directive("mask",i.a)}Object.defineProperty(t,"__esModule",{value:!0});var a=n(0),o=n.n(a),i=n(1),u=n(7),s=n.n(u);n.d(t,"TheMask",(function(){return s.a})),n.d(t,"mask",(function(){return i.a})),n.d(t,"tokens",(function(){return o.a})),n.d(t,"version",(function(){return c}));var c="0.11.1";t.default=r,"undefined"!=typeof window&&window.Vue&&window.Vue.use(r)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(1),a=n(0),o=n.n(a),i=n(2);t.default={name:"TheMask",props:{value:[String,Number],mask:{type:[String,Array],required:!0},masked:{type:Boolean,default:!1},tokens:{type:Object,default:function(){return o.a}}},directives:{mask:r.a},data:function(){return{lastValue:null,display:this.value}},watch:{value:function(e){e!==this.lastValue&&(this.display=e)},masked:function(){this.refresh(this.display)}},computed:{config:function(){return{mask:this.mask,tokens:this.tokens,masked:this.masked}}},methods:{onInput:function(e){e.isTrusted||this.refresh(e.target.value)},refresh:function(e){this.display=e,(e=n.i(i.a)(e,this.mask,this.masked,this.tokens))!==this.lastValue&&(this.lastValue=e,this.$emit("input",e))}}}},function(e,t,n){"use strict";t.a=function(e,t,n){return t=t.sort((function(e,t){return e.length-t.length})),function(r,a){for(var o=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=0;i<t.length;){var u=t[i];i++;var s=t[i];if(!(s&&e(r,s,!0,n).length>u.length))return e(r,u,o,n)}return""}}},function(e,t,n){"use strict";t.a=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=arguments[3];e=e||"",t=t||"";for(var a=0,o=0,i="";a<t.length&&o<e.length;){var u=r[f=t[a]],s=e[o];u&&!u.escape?(u.pattern.test(s)&&(i+=u.transform?u.transform(s):s,a++),o++):(u&&u.escape&&(f=t[++a]),n&&(i+=f),s===f&&o++,a++)}for(var c="";a<t.length&&n;){var f;if(r[f=t[a]]){c="";break}c+=f,a++}return i+c}},function(e,t,n){var r=n(8)(n(4),n(9),null,null);e.exports=r.exports},function(e,t){e.exports=function(e,t,n,r){var a,o=e=e||{},i=typeof e.default;"object"!==i&&"function"!==i||(a=e,o=e.default);var u="function"==typeof o?o.options:o;if(t&&(u.render=t.render,u.staticRenderFns=t.staticRenderFns),n&&(u._scopeId=n),r){var s=u.computed||(u.computed={});Object.keys(r).forEach((function(e){var t=r[e];s[e]=function(){return t}}))}return{esModule:a,exports:o,options:u}}},function(e,t){e.exports={render:function(){var e=this,t=e.$createElement;return(e._self._c||t)("input",{directives:[{name:"mask",rawName:"v-mask",value:e.config,expression:"config"}],attrs:{type:"text"},domProps:{value:e.display},on:{input:e.onInput}})},staticRenderFns:[]}},function(e,t,n){e.exports=n(3)}])}));
|
8949
assets/js/lib/vue.js
Normal file
8949
assets/js/lib/vue.js
Normal file
File diff suppressed because it is too large
Load Diff
6
assets/js/lib/vue.min.js
vendored
Normal file
6
assets/js/lib/vue.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user