28 lines
2.9 MiB
JavaScript
28 lines
2.9 MiB
JavaScript
|
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).luckysheet=t()}(this,(function(){"use strict";var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function t(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function a(e,t,a){return e(a={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==t&&a.path)}},a.exports),a.exports}var n=function(e){return e&&e.Math==Math&&e},l=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof e&&e)||Function("return this")(),o=function(e){try{return!!e()}catch(e){return!0}},s=!o((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),u={}.propertyIsEnumerable,d=Object.getOwnPropertyDescriptor,h={f:d&&!u.call({1:2},1)?function(e){var t=d(this,e);return!!t&&t.enumerable}:u},m=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}},p={}.toString,f=function(e){return p.call(e).slice(8,-1)},g="".split,v=o((function(){return!Object("z").propertyIsEnumerable(0)}))?function(e){return"String"==f(e)?g.call(e,""):Object(e)}:Object,y=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e},b=function(e){return v(y(e))},k=function(e){return"object"==typeof e?null!==e:"function"==typeof e},x=function(e,t){if(!k(e))return e;var a,r;if(t&&"function"==typeof(a=e.toString)&&!k(r=a.call(e)))return r;if("function"==typeof(a=e.valueOf)&&!k(r=a.call(e)))return r;if(!t&&"function"==typeof(a=e.toString)&&!k(r=a.call(e)))return r;throw TypeError("Can't convert object to primitive value")},w={}.hasOwnProperty,_=function(e,t){return w.call(e,t)},C=l.document,T=k(C)&&k(C.createElement),A=function(e){return T?C.createElement(e):{}},S=!s&&!o((function(){return 7!=Object.defineProperty(A("div"),"a",{get:function(){return 7}}).a})),I=Object.getOwnPropertyDescriptor,R={f:s?I:function(e,t){if(e=b(e),t=x(t,!0),S)try{return I(e,t)}catch(e){}if(_(e,t))return m(!h.f.call(e,t),e[t])}},q=function(e){if(!k(e))throw TypeError(String(e)+" is not an object");return e},D=Object.defineProperty,F={f:s?D:function(e,t,a){if(q(e),t=x(t,!0),q(a),S)try{return D(e,t,a)}catch(e){}if("get"in a||"set"in a)throw TypeError("Accessors not supported");return"value"in a&&(e[t]=a.value),e}},E=s?function(e,t,a){return F.f(e,t,m(1,a))}:function(e,t,a){return e[t]=a,e},M=function(e,t){try{E(l,e,t)}catch(a){l[e]=t}return t},N=l["__core-js_shared__"]||M("__core-js_shared__",{}),P=Function.toString;"function"!=typeof N.inspectSource&&(N.inspectSource=function(e){return P.call(e)});var z,L,O,B=N.inspectSource,V=l.WeakMap,H="function"==typeof V&&/native code/.test(B(V)),U=a((function(e){(e.exports=function(e,t){return N[e]||(N[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.6.5",mode:"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})})),j=0,G=Math.random(),W=function(e){return"Symbol("+String(void 0===e?"":e)+")_"+(++j+G).toString(36)},Y=U("keys"),X=function(e){return Y[e]||(Y[e]=W(e))},K={},Z=l.WeakMap;if(H){var Q=new Z,J=Q.get,ee=Q.has,te=Q.set;z=function(e,t){return te.call(Q,e,t),t},L=function(e){return J.call(Q,e)||{}},O=function(e){return ee.call(Q,e)}}else{var ae=X("state");K[ae]=!0,z=function(e,t){return E(e,ae,t),t},L=function(e){return _(e,ae)?e[ae]:{}},O=function(e){return _(e,ae)}}var re={set:z,get:L,has:O,enforce:function(e){return O(e)?L(e):z(e,{})},getterFor:function(e){return function(t){var a;if(!k(t)||(a=L(t)).type!==e)throw TypeError("Incompatible receiver, "+e+" required");return a}}},ne=a((function(e){var t=re.get,a=re.enforce,r=String(String).split("String");(e.exports=function(e,t,n,i){var o=!!i&&!!i.unsafe,s=!!i&&!!i.enumerable,c=!!i&&!!i.noTargetGet;"function"==typeof n&&("string"!=typeof t||_(n,"n
|
||
|
/*! @preserve
|
||
|
* numeral.js
|
||
|
* version : 2.0.6
|
||
|
* author : Adam Draper
|
||
|
* license : MIT
|
||
|
* http://adamwdraper.github.com/Numeral-js/
|
||
|
*/
|
||
|
!function(e,a){t.exports?t.exports=a():e.numeral=a()}(e,(function(){var e,t,a,r,n,l={},i={},o={currentLocale:"en",zeroFormat:null,nullFormat:null,defaultFormat:"0,0",scalePercentBy100:!0},s={currentLocale:o.currentLocale,zeroFormat:o.zeroFormat,nullFormat:o.nullFormat,defaultFormat:o.defaultFormat,scalePercentBy100:o.scalePercentBy100};function c(e,t){this._input=e,this._value=t}return(e=function(a){var r,n,i,o;if(e.isNumeral(a))r=a.value();else if(0===a||void 0===a)r=0;else if(null===a||t.isNaN(a))r=null;else if("string"==typeof a)if(s.zeroFormat&&a===s.zeroFormat)r=0;else if(s.nullFormat&&a===s.nullFormat||!a.replace(/[^0-9]+/g,"").length)r=null;else{for(n in l)if((o="function"==typeof l[n].regexps.unformat?l[n].regexps.unformat():l[n].regexps.unformat)&&a.match(o)){i=l[n].unformat;break}r=(i=i||e._.stringToNumber)(a)}else r=Number(a)||null;return new c(a,r)}).version="2.0.6",e.isNumeral=function(e){return e instanceof c},e._=t={numberToFormat:function(t,a,r){var n,l,o,s,c,u,d,h,m=i[e.options.currentLocale],p=!1,f=!1,g="",v="",y=!1;if(t=t||0,o=Math.abs(t),e._.includes(a,"(")?(p=!0,a=a.replace(/[\(|\)]/g,"")):(e._.includes(a,"+")||e._.includes(a,"-"))&&(u=e._.includes(a,"+")?a.indexOf("+"):t<0?a.indexOf("-"):-1,a=a.replace(/[\+|\-]/g,"")),e._.includes(a,"a")&&(l=!!(l=a.match(/a(k|m|b|t)?/))&&l[1],e._.includes(a," a")&&(g=" "),a=a.replace(new RegExp(g+"a[kmbt]?"),""),o>=1e12&&!l||"t"===l?(g+=m.abbreviations.trillion,t/=1e12):o<1e12&&o>=1e9&&!l||"b"===l?(g+=m.abbreviations.billion,t/=1e9):o<1e9&&o>=1e6&&!l||"m"===l?(g+=m.abbreviations.million,t/=1e6):(o<1e6&&o>=1e3&&!l||"k"===l)&&(g+=m.abbreviations.thousand,t/=1e3)),e._.includes(a,"[.]")&&(f=!0,a=a.replace("[.]",".")),s=t.toString().split(".")[0],c=a.split(".")[1],d=a.indexOf(","),n=(a.split(".")[0].split(",")[0].match(/0/g)||[]).length,c?(e._.includes(c,"[")?(c=(c=c.replace("]","")).split("["),v=e._.toFixed(t,c[0].length+c[1].length,r,c[1].length)):v=e._.toFixed(t,c.length,r),s=v.split(".")[0],v=e._.includes(v,".")?m.delimiters.decimal+v.split(".")[1]:"",f&&0===Number(v.slice(1))&&(v="")):s=e._.toFixed(t,0,r),g&&!l&&Number(s)>=1e3&&g!==m.abbreviations.trillion)switch(s=String(Number(s)/1e3),g){case m.abbreviations.thousand:g=m.abbreviations.million;break;case m.abbreviations.million:g=m.abbreviations.billion;break;case m.abbreviations.billion:g=m.abbreviations.trillion}if(e._.includes(s,"-")&&(s=s.slice(1),y=!0),s.length<n)for(var b=n-s.length;b>0;b--)s="0"+s;return d>-1&&(s=s.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1"+m.delimiters.thousands)),0===a.indexOf(".")&&(s=""),h=s+v+(g||""),p?h=(p&&y?"(":"")+h+(p&&y?")":""):u>=0?h=0===u?(y?"-":"+")+h:h+(y?"-":"+"):y&&(h="-"+h),h},stringToNumber:function(e){var t,a,r,n=i[s.currentLocale],l=e,o={thousand:3,million:6,billion:9,trillion:12};if(s.zeroFormat&&e===s.zeroFormat)a=0;else if(s.nullFormat&&e===s.nullFormat||!e.replace(/[^0-9]+/g,"").length)a=null;else{for(t in a=1,"."!==n.delimiters.decimal&&(e=e.replace(/\./g,"").replace(n.delimiters.decimal,".")),o)if(r=new RegExp("[^a-zA-Z]"+n.abbreviations[t]+"(?:\\)|(\\"+n.currency.symbol+")?(?:\\))?)?$"),l.match(r)){a*=Math.pow(10,o[t]);break}a*=(e.split("-").length+Math.min(e.split("(").length-1,e.split(")").length-1))%2?1:-1,e=e.replace(/[^0-9\.]+/g,""),a*=Number(e)}return a},isNaN:function(e){return"number"==typeof e&&isNaN(e)},includes:function(e,t){return-1!==e.indexOf(t)},insert:function(e,t,a){return e.slice(0,a)+t+e.slice(a)},reduce:function(e,t){if(null===this)throw new TypeError("Array.prototype.reduce called on null or undefined");if("function"!=typeof t)throw new TypeError(t+" is not a function");var a,r=Object(e),n=r.length>>>0,l=0;if(3===arguments.length)a=arguments[2];else{for(;l<n&&!(l in r);)l++;if(l>=n)throw new TypeError("Reduce of empty array with no initial value");a=r[l++]}for(;l<n;l++)l in r&&(a=t(a,r[l],l,r));return a},multiplier:function(e){var t=e.toString().split(".");return t.length<2?1:Math.pow(10,t[1].length)},correctionFactor:function(){var e=Array.prototype.slice.call(arguments);return e.reduce((function(e,a){var r=t.multiplier(a);return e>r?
|
||
|
/* flatpickr v4.6.6, @license MIT */
|
||
|
e.exports=function(){
|
||
|
/*! *****************************************************************************
|
||
|
Copyright (c) Microsoft Corporation.
|
||
|
|
||
|
Permission to use, copy, modify, and/or distribute this software for any
|
||
|
purpose with or without fee is hereby granted.
|
||
|
|
||
|
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
||
|
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
||
|
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
||
|
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
||
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||
|
PERFORMANCE OF THIS SOFTWARE.
|
||
|
***************************************************************************** */
|
||
|
var e=function(){return(e=Object.assign||function(e){for(var t,a=1,r=arguments.length;a<r;a++)for(var n in t=arguments[a])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}).apply(this,arguments)};function t(){for(var e=0,t=0,a=arguments.length;t<a;t++)e+=arguments[t].length;var r=Array(e),n=0;for(t=0;t<a;t++)for(var l=arguments[t],i=0,o=l.length;i<o;i++,n++)r[n]=l[i];return r}var a=["onChange","onClose","onDayCreate","onDestroy","onKeyDown","onMonthChange","onOpen","onParseConfig","onReady","onValueUpdate","onYearChange","onPreCalendarPosition"],r={_disable:[],_enable:[],allowInput:!1,allowInvalidPreload:!1,altFormat:"F j, Y",altInput:!1,altInputClass:"form-control input",animate:"object"==typeof window&&-1===window.navigator.userAgent.indexOf("MSIE"),ariaDateFormat:"F j, Y",autoFillDefaultTime:!0,clickOpens:!0,closeOnSelect:!0,conjunction:", ",dateFormat:"Y-m-d",defaultHour:12,defaultMinute:0,defaultSeconds:0,disable:[],disableMobile:!1,enable:[],enableSeconds:!1,enableTime:!1,errorHandler:function(e){return"undefined"!=typeof console&&console.warn(e)},getWeek:function(e){var t=new Date(e.getTime());t.setHours(0,0,0,0),t.setDate(t.getDate()+3-(t.getDay()+6)%7);var a=new Date(t.getFullYear(),0,4);return 1+Math.round(((t.getTime()-a.getTime())/864e5-3+(a.getDay()+6)%7)/7)},hourIncrement:1,ignoredFocusElements:[],inline:!1,locale:"default",minuteIncrement:5,mode:"single",monthSelectorType:"dropdown",nextArrow:"<svg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 17 17'><g></g><path d='M13.207 8.472l-7.854 7.854-0.707-0.707 7.146-7.146-7.146-7.148 0.707-0.707 7.854 7.854z' /></svg>",noCalendar:!1,now:new Date,onChange:[],onClose:[],onDayCreate:[],onDestroy:[],onKeyDown:[],onMonthChange:[],onOpen:[],onParseConfig:[],onReady:[],onValueUpdate:[],onYearChange:[],onPreCalendarPosition:[],plugins:[],position:"auto",positionElement:void 0,prevArrow:"<svg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 17 17'><g></g><path d='M5.207 8.471l7.146 7.147-0.707 0.707-7.853-7.854 7.854-7.853 0.707 0.707-7.147 7.146z' /></svg>",shorthandCurrentMonth:!1,showMonths:1,static:!1,time_24hr:!1,weekNumbers:!1,wrap:!1},n={weekdays:{shorthand:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],longhand:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},months:{shorthand:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],longhand:["January","February","March","April","May","June","July","August","September","October","November","December"]},daysInMonth:[31,28,31,30,31,30,31,31,30,31,30,31],firstDayOfWeek:0,ordinal:function(e){var t=e%100;if(t>3&&t<21)return"th";switch(t%10){case 1:return"st";case 2:return"nd";case 3:return"rd";default:return"th"}},rangeSeparator:" to ",weekAbbreviation:"Wk",scrollTitle:"Scroll to increment",toggleTitle:"Click to toggle",amPM:["AM","PM"],yearAriaLabel:"Year",monthAriaLabel:"Month",hourAriaLabel:"Hour",minuteAriaLabel:"Minute",time_24hr:!1},l=function(e,t){return void 0===t&&(t=2),("000"+e).slice(-1*t)},i=function(e){return!0===e?1:0};function o(e,t,a){var r;return void 0===a&&(a=!1),function(){var n=this,l=arguments;null!==r&&clearTimeout(r),r=window.setTimeout((function(){r=null,a||e.apply(n,l)}),t),a&&!r&&e.apply(n,l)}}var s=function(e){return e instanceof Array?e:[e]};function c(e,t,a){if(!0===a)return e.classList.add(t);e.classList.remove(t)}function u(e,t,a){var r=window.document.createElement(e);return t=t||"",a=a||"",r.className=t,void 0!==a&&(r.textContent=a),r}function d(e){for(;e.firstChild;)e.removeChild(e.firstChild)}function h(e,t){var a=u("div","numInputWrapper"),r=u("input","numInput "+e),n=u("span","arrowUp"),l=u("span","arrowDown");if(-1===navigator.userAgent.indexOf("MSIE 9.0")?r.type="number":(r.type="text",r.pattern="\\d*"),void 0!==t)for(var i in t)r.setAttribute(i,t[i]);return a.appendChild(r),a.appendChild(n),a.appendChild(l),a}function m(e){try{return"function"==typeof e.composedPath?e.composedPath()[0]:e.target}catch(t){return
|
||
|
//# sourceMappingURL=luckysheet.umd.js.map
|