mat-date 1.7.55 → 1.7.57
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/DateUtil.js +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/dist/DateUtil.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const a0_0x10f28a={};a0_0x10f28a['value']=!![],Object['defineProperty'](exports,'__esModule',a0_0x10f28a),exports['MDateUtil']=void 0x0;const a0_0x1fad9b=(_0x274dad,_0x2d26e3=0x2)=>_0x274dad['toString']()['padStart'](_0x2d26e3,'0');function a0_0x21229f(_0xac492b,_0x25ec8a){try{return _0xac492b();}catch(_0x4e2cb8){if(_0x25ec8a)return _0x25ec8a;throw new Error('UNKNOWN');}}function a0_0x9a0b81(_0x2382cf){try{if(_0x2382cf instanceof Date)return _0x2382cf['getTime']();if(typeof _0x2382cf==='number')return _0x2382cf;if(typeof _0x2382cf==='string')return new Date(_0x2382cf)['getTime']();if(_0x2382cf instanceof a0_0x40aa95)return _0x2382cf['toTime']();if(_0x2382cf['idkey']==='mdateutil')return _0x2382cf['toTime']();return 0x0;}catch(_0x4979fb){throw new Error('ERROR');}}function a0_0x13a906(_0x50eb05){function _0x31a919(_0x1a500){const _0x37c0dd={};return _0x37c0dd['weekday']=_0x1a500,a0_0x21229f(()=>new Intl['DateTimeFormat'](_0x50eb05['localCode'],_0x37c0dd)['format'](a0_0x9a0b81(_0x50eb05)),'');}function _0x50bd64(){return _0x31a919('long');}function _0x18f3f3(){return _0x31a919('short');}function _0x42426a(){return _0x31a919('narrow');}const _0x5b2918={};return _0x5b2918['ln']=_0x50bd64,_0x5b2918['sh']=_0x18f3f3,_0x5b2918['nr']=_0x42426a,_0x5b2918;}function a0_0x2ee2d9(_0x4bbfca,_0x2c454e,_0x13969a,_0x29ee39){const _0x49d4e2=a0_0x9a0b81(_0x4bbfca),_0x212b05=a0_0x9a0b81(_0x2c454e),_0x48f55c=a0_0x9a0b81(_0x13969a),_0x5c44d1=a0_0x9a0b81(_0x29ee39);return _0x48f55c<=_0x49d4e2&&_0x5c44d1>=_0x49d4e2&&_0x5c44d1<=_0x212b05||_0x48f55c>=_0x49d4e2&&_0x48f55c<=_0x212b05&&_0x5c44d1>=_0x212b05||_0x48f55c>=_0x49d4e2&&_0x48f55c<=_0x212b05&&_0x5c44d1<=_0x212b05||_0x48f55c<=_0x49d4e2&&_0x5c44d1>=_0x212b05;}function a0_0x3b3bbd(_0x395999){let _0x258a96=undefined,_0x5e6766=undefined,_0x2fc952=undefined,_0x49ba94=undefined;try{const _0x2c2c44=(_0x395999||'')['match'](/\w{2}:\w{2}(:\w{2})?\b/g)[0x0]['split'](':');_0x258a96=_0x2c2c44['length']>=0x1?Number(_0x2c2c44[0x0]):undefined,_0x5e6766=_0x2c2c44['length']>=0x2?Number(_0x2c2c44[0x1]):undefined,_0x2fc952=_0x2c2c44['length']>=0x3?Number(_0x2c2c44[0x2]):undefined;}catch(_0x5cc880){}try{let _0x832a61=_0x395999||'',_0x47930c=/\.\d{3}/g,_0x3f6703=_0x832a61['match'](_0x47930c)[0x0]['split']('.')['filter'](_0x42e182=>Boolean(_0x42e182));_0x49ba94=_0x3f6703['length']>=0x1?Number(_0x3f6703[0x0]):undefined;}catch(_0xec16ff){}const _0x46724e={};return _0x46724e['h']=_0x258a96,_0x46724e['m']=_0x5e6766,_0x46724e['s']=_0x2fc952,_0x46724e['ms']=_0x49ba94,_0x46724e;}class a0_0x40aa95{['val']=new Date();static ['glCode']=undefined;['code']=undefined;['dyfrmt']=a0_0x13a906(this);get['localCode'](){return this['code'];}static['new'](){return new a0_0x40aa95()['setCode'](a0_0x40aa95['glCode']);}static['setCode'](_0x1224f3){return a0_0x40aa95['glCode']=_0x1224f3,this;}static['seperator'](){return a0_0x21229f(()=>new Date()['toLocaleDateString'](a0_0x40aa95['glCode'])['replace'](/\d/g,'')['split']('')[0x0]);}['cpy'](){return a0_0x21229f(()=>a0_0x40aa95['new']()['setTime'](this['toTime']()));}['setCode'](_0x200ff6){return this['code']=_0x200ff6,this;}['seperator'](){return a0_0x21229f(()=>new Date()['toLocaleDateString'](this['code'])['replace'](/\d/g,'')['split']('')[0x0]);}['zone'](){return a0_0x21229f(()=>{return Intl['DateTimeFormat']()?.['resolvedOptions']()?.['timeZone'];},null);}['zones'](_0x5578d4=this['code']){return a0_0x21229f(()=>{return new Intl['Locale'](_0x5578d4)?.['timeZones']||[];},null);}['region'](_0x540da3=this['code']){return a0_0x21229f(()=>{return new Intl['Locale'](_0x540da3)['region'];},null);}['year'](){return this['val']['getFullYear']();}['month'](){return this['val']['getMonth']()+0x1;}['monthUtc'](){return this['val']['getMonth']();}['day'](){return this['val']['getDate']();}['hours'](){return this['val']['getHours']();}['min'](){return this['val']['getMinutes']();}['sec'](){return this['val']['getSeconds']();}['msec'](){return this['val']['getMilliseconds']();}['dayOfWeek'](){const _0x3fe2c4=this['val']['getDay']();return _0x3fe2c4?_0x3fe2c4:0x7;}['dayOfWeekUtc'](){return this['val']['getDay']();}['setYear'](_0x4ace63){return this['val']['setFullYear'](_0x4ace63),this;}['setMonth'](_0xbc4f05){return this['val']['setMonth'](_0xbc4f05-0x1),this;}['setMonthUtc'](_0x275397){return this['val']['setMonth'](_0x275397),this;}['setDay'](_0x51cff3){return this['val']['setDate'](_0x51cff3),this;}['setHour'](_0xa5b9ea){return this['val']['setHours'](_0xa5b9ea),this;}['startOfHours'](){return this['setHour'](0x0),this['setMin'](0x0),this['setSeconds'](0x0),this['setMilliseconds'](0x0),this;}['endOfHours'](){return this['setHour'](0x17),this['setMin'](0x3b),this['setSeconds'](0x3b),this['setMilliseconds'](0x3e7),this;}['setMin'](_0x475173){return this['val']['setMinutes'](_0x475173),this;}['startOfMin'](){return this['setSeconds'](0x0),this['setMilliseconds'](0x0),this;}['endOfMin'](){return this['setSeconds'](0x3b),this['setMilliseconds'](0x3e7),this;}['setSeconds'](_0x341051){return this['val']['setSeconds'](_0x341051),this;}['startOfSeconds'](){return this['setMilliseconds'](0x0),this;}['endOfSeconds'](){return this['setMilliseconds'](0x3e7),this;}['setMilliseconds'](_0x1a0f65){return this['val']['setMilliseconds'](_0x1a0f65),this;}['startOfMilliseconds'](){return this['setMilliseconds'](0x0),this;}['endOfMilliseconds'](){return this['setMilliseconds'](0x3e7),this;}['setIsoDate'](_0x395ca2){return this['val']=new Date(_0x395ca2),this;}['setTime'](_0x4b9f7b){return this['val']=new Date(_0x4b9f7b),this;}['setDate'](_0x136a65){return this['val']=new Date(_0x136a65),this;}['setDateInputValue'](_0x4c7bdd){return this['val']=new Date(_0x4c7bdd?.['replace']('T','\x20')),this;}['setVal'](_0x50de8e){return a0_0x21229f(()=>{return a0_0x40aa95['new']()['setTime'](a0_0x9a0b81(_0x50de8e));});}['toIsoDate'](){return this['val']['toISOString']();}['toTime'](){return this['val']['getTime']();}['toDate'](){return this['val'];}['toDateMounthInput'](){return this['year']()+'-'+a0_0x1fad9b(this['month']());}['toDateInput'](){return this['year']()+'-'+a0_0x1fad9b(this['month']())+'-'+a0_0x1fad9b(this['day']());}['toTimeInput'](_0x1ccfeb=!![]){const _0xb97b71=[];return _0xb97b71['push'](a0_0x1fad9b(this['hours']())),_0xb97b71['push'](a0_0x1fad9b(this['min']())),_0x1ccfeb&&_0xb97b71['push'](a0_0x1fad9b(this['sec']())),_0xb97b71['join'](':');}['toDateTimeInput'](_0x878085=!![]){return this['toDateInput']()+'T'+this['toTimeInput'](_0x878085);}['strDate'](){const _0x5b682b={};return _0x5b682b['month']='2-digit',_0x5b682b['day']='2-digit',_0x5b682b['year']='numeric',this['val']['toLocaleDateString'](this['code'],_0x5b682b);}['strDateLocal'](_0x51bb72){return this['val']['toLocaleDateString'](this['code'],_0x51bb72);}['strTime'](){return a0_0x1fad9b(this['hours']())+':'+a0_0x1fad9b(this['min']())+':'+a0_0x1fad9b(this['sec']());}['strTimeLocale'](_0x2a9319){return this['val']['toLocaleTimeString'](this['code'],_0x2a9319);}['strHHmm'](){return a0_0x1fad9b(this['hours']())+':'+a0_0x1fad9b(this['min']());}['str'](){return this['strDate']()+'\x20'+this['strTime']();}['strLocal'](_0x1a7306){return this['val']['toLocaleString'](this['code'],_0x1a7306);}['strYears'](){return this['val']['getFullYear']()['toString']();}['strMounth'](){return a0_0x1fad9b(this['month'](),0x2);}['strDay'](){return a0_0x1fad9b(this['day'](),0x2);}['strHour'](){return a0_0x1fad9b(this['hours'](),0x2);}['strMin'](){return a0_0x1fad9b(this['min'](),0x2);}['strSec'](){return a0_0x1fad9b(this['sec'](),0x2);}['strMsec'](){return a0_0x1fad9b(this['msec'](),0x2);}['strDayStr'](){return{'ln':()=>this['dyfrmt']['ln'](),'sh':()=>this['dyfrmt']['sh'](),'nr':()=>this['dyfrmt']['nr']()};}['addDay'](_0x24f433){return this['val']=new Date(this['val']['setHours'](this['val']['getHours']()+_0x24f433*0x18)),this;}['addHours'](_0xe73abc){return this['val']=new Date(this['val']['setHours'](this['val']['getHours']()+_0xe73abc)),this;}['addMins'](_0x2806b4){return this['val']=new Date(this['val']['setMinutes'](this['val']['getMinutes']()+_0x2806b4)),this;}['startOfDay'](){return this['startOfHours'](),this;}['cpyByStartOfDay'](){return this['cpy']()['startOfDay']();}['endOfDay'](){return this['endOfHours'](),this;}['cpyByEndOfDay'](){return this['cpy']()['endOfDay']();}['startOfWeek'](){return this['addDay'](-this['dayOfWeek']()+0x1);}['cpyStartOfWeek'](){return this['cpy']()['addDay'](-this['dayOfWeek']()+0x1);}['endOfWeek'](){return this['startOfWeek']()['addDay'](0x6);}['cpyEndOfWeek'](){return this['cpyStartOfWeek']()['addDay'](0x6);}['startOfMonth'](){return this['setDay'](0x1),this['startOfDay'](),this;}['cpyByStartOfMonth'](){return this['cpy']()['startOfMonth']();}['endOfMonth'](){return this['setDate'](this['val'])['startOfMonth']()['setMonth'](this['month']()+0x1)['startOfMonth']()['addDay'](-0x1)['endOfDay'](),this;}['cpyByEndOfMonth'](){return this['cpy']()['endOfMonth']();}['eq'](_0x3f223a){return a0_0x21229f(()=>{return this['cpy']()['toTime']()===a0_0x9a0b81(_0x3f223a);});}['gt'](_0x485fa5){return a0_0x21229f(()=>{return this['cpy']()['toTime']()>a0_0x9a0b81(_0x485fa5);});}['gte'](_0x110c08){return a0_0x21229f(()=>{return this['cpy']()['toTime']()>=a0_0x9a0b81(_0x110c08);});}['lt'](_0x2bfb2d){return a0_0x21229f(()=>{return this['cpy']()['toTime']()<a0_0x9a0b81(_0x2bfb2d);});}['lte'](_0x372317){return a0_0x21229f(()=>{return this['cpy']()['toTime']()<=a0_0x9a0b81(_0x372317);});}['btw'](_0x191b57,_0x5beaf0){return a0_0x21229f(()=>{const _0x48b0a0=a0_0x9a0b81(_0x191b57),_0x3a55ef=a0_0x9a0b81(_0x5beaf0),_0x1325fb=this['cpy']()['toTime']();return _0x48b0a0<_0x1325fb&&_0x1325fb<_0x3a55ef;});}['btweq'](_0x40081d,_0x225d82){return a0_0x21229f(()=>{const _0x8c4bb5=a0_0x9a0b81(_0x40081d),_0xc18a90=a0_0x9a0b81(_0x225d82),_0x25fee4=this['cpy']()['toTime']();return _0x8c4bb5<=_0x25fee4&&_0x25fee4<=_0xc18a90;});}['btwEqStart'](_0x210471,_0x7c3679){return a0_0x21229f(()=>{const _0x436b5d=a0_0x9a0b81(_0x210471),_0x378b13=a0_0x9a0b81(_0x7c3679),_0xc5c3ee=this['cpy']()['toTime']();return _0x436b5d<=_0xc5c3ee&&_0xc5c3ee<_0x378b13;});}['btwEqEnd'](_0x1a2176,_0x32a3c5){return a0_0x21229f(()=>{const _0x506047=a0_0x9a0b81(_0x1a2176),_0x192b29=a0_0x9a0b81(_0x32a3c5),_0x388c2a=this['cpy']()['toTime']();return _0x506047<_0x388c2a&&_0x388c2a<=_0x192b29;});}static['diffDays'](_0x4d80f4,_0x9fc2b8,_0x5375ad){return a0_0x21229f(()=>{const _0x1660e8=a0_0x9a0b81(_0x4d80f4),_0x34f348=a0_0x9a0b81(_0x9fc2b8);return _0x5375ad?Math['abs'](_0x1660e8-_0x34f348)/0x36ee80/0x18:(_0x1660e8-_0x34f348)/0x36ee80/0x18;});}static['diffHours'](_0x231f7e,_0x2c8ccb,_0x32fd54){return a0_0x21229f(()=>{const _0x57a55f=a0_0x9a0b81(_0x231f7e),_0x237bb2=a0_0x9a0b81(_0x2c8ccb);return _0x32fd54?Math['abs'](_0x57a55f-_0x237bb2)/0x36ee80:(_0x57a55f-_0x237bb2)/0x36ee80;});}static['diffMins'](_0x27fe5c,_0x26fa59,_0x4343c2){return a0_0x21229f(()=>{const _0x444484=a0_0x9a0b81(_0x27fe5c),_0x48ca92=a0_0x9a0b81(_0x26fa59);return _0x4343c2?Math['abs'](_0x444484-_0x48ca92)/0x3e8/0x3c:(_0x444484-_0x48ca92)/0x3e8/0x3c;});}static['diffSecs'](_0x4d10bb,_0x5246d4,_0x1c6f9f){return a0_0x21229f(()=>{const _0x263f9d=a0_0x9a0b81(_0x4d10bb),_0x1a20f5=a0_0x9a0b81(_0x5246d4);return _0x1c6f9f?Math['abs'](_0x263f9d-_0x1a20f5)/0x3e8:(_0x263f9d-_0x1a20f5)/0x3e8;});}static['s1'](_0x44672e,_0x149761,_0x2450e9,_0x1b522b){return a0_0x21229f(()=>a0_0x2ee2d9(_0x44672e,_0x149761,_0x2450e9,_0x1b522b));}static['divideTime'](_0x20493c){return a0_0x21229f(()=>a0_0x3b3bbd(_0x20493c));}}exports['MDateUtil']=a0_0x40aa95;const a0_0x4fb14c={};a0_0x4fb14c['value']='mdateutil',a0_0x4fb14c['writable']=![],a0_0x4fb14c['enumerable']=!![],a0_0x4fb14c['configurable']=![],Object['defineProperty'](a0_0x40aa95['prototype'],'idkey',a0_0x4fb14c);
|
|
1
|
+
'use strict';const a0_0x293aa6={};a0_0x293aa6['value']=!![],Object['defineProperty'](exports,'__esModule',a0_0x293aa6),exports['MDateUtil']=void 0x0;const a0_0x4986cd=(_0x245584,_0x5576c4=0x2)=>_0x245584['toString']()['padStart'](_0x5576c4,'0');function a0_0x57bbf0(_0x125aa3,_0x246f18){try{return _0x125aa3();}catch(_0xc17a11){if(_0x246f18)return _0x246f18;throw new Error('UNKNOWN');}}function a0_0x23a3f3(_0x3e3abd){try{if(_0x3e3abd instanceof Date)return _0x3e3abd['getTime']();if(typeof _0x3e3abd==='number')return _0x3e3abd;if(typeof _0x3e3abd==='string')return new Date(_0x3e3abd)['getTime']();if(_0x3e3abd instanceof a0_0x596399)return _0x3e3abd['toTime']();if(_0x3e3abd['idkey']==='mdateutil')return _0x3e3abd['toTime']();return 0x0;}catch(_0x21be4f){throw new Error('ERROR');}}function a0_0x2ed3e3(_0x5ec5c3){function _0x107827(_0x531a40){const _0x231fe4={};return _0x231fe4['weekday']=_0x531a40,a0_0x57bbf0(()=>new Intl['DateTimeFormat'](_0x5ec5c3['localCode'],_0x231fe4)['format'](a0_0x23a3f3(_0x5ec5c3)),'');}function _0x3bc1d1(){return _0x107827('long');}function _0x36aeb5(){return _0x107827('short');}function _0x250ac0(){return _0x107827('narrow');}const _0x2f5e62={};return _0x2f5e62['ln']=_0x3bc1d1,_0x2f5e62['sh']=_0x36aeb5,_0x2f5e62['nr']=_0x250ac0,_0x2f5e62;}function a0_0x5febf6(_0x26abdb,_0x532f3d,_0x32c66c,_0x3d1c69){const _0x1e776a=a0_0x23a3f3(_0x26abdb),_0x47ec64=a0_0x23a3f3(_0x532f3d),_0xdf2d4=a0_0x23a3f3(_0x32c66c),_0x4ab43b=a0_0x23a3f3(_0x3d1c69);return _0xdf2d4<=_0x1e776a&&_0x4ab43b>=_0x1e776a&&_0x4ab43b<=_0x47ec64||_0xdf2d4>=_0x1e776a&&_0xdf2d4<=_0x47ec64&&_0x4ab43b>=_0x47ec64||_0xdf2d4>=_0x1e776a&&_0xdf2d4<=_0x47ec64&&_0x4ab43b<=_0x47ec64||_0xdf2d4<=_0x1e776a&&_0x4ab43b>=_0x47ec64;}function a0_0x23c807(_0xd20671){let _0xd1d18c=undefined,_0x30f713=undefined,_0x3d3805=undefined,_0x3f3f29=undefined;try{const _0x5eb48c=(_0xd20671||'')['match'](/\w{2}:\w{2}(:\w{2})?\b/g)[0x0]['split'](':');_0xd1d18c=_0x5eb48c['length']>=0x1?Number(_0x5eb48c[0x0]):undefined,_0x30f713=_0x5eb48c['length']>=0x2?Number(_0x5eb48c[0x1]):undefined,_0x3d3805=_0x5eb48c['length']>=0x3?Number(_0x5eb48c[0x2]):undefined;}catch(_0x148429){}try{let _0x20f592=_0xd20671||'',_0x49fbac=/\.\d{3}/g,_0x34a08a=_0x20f592['match'](_0x49fbac)[0x0]['split']('.')['filter'](_0x3269bd=>Boolean(_0x3269bd));_0x3f3f29=_0x34a08a['length']>=0x1?Number(_0x34a08a[0x0]):undefined;}catch(_0x156a4c){}const _0x4bca04={};return _0x4bca04['h']=_0xd1d18c,_0x4bca04['m']=_0x30f713,_0x4bca04['s']=_0x3d3805,_0x4bca04['ms']=_0x3f3f29,_0x4bca04;}class a0_0x596399{['val']=new Date();static ['glCode']=undefined;['code']=undefined;['dyfrmt']=a0_0x2ed3e3(this);get['localCode'](){return this['code'];}static['new'](){return new a0_0x596399()['setCode'](a0_0x596399['glCode']);}static['setCode'](_0xf18a7f){return a0_0x596399['glCode']=_0xf18a7f,this;}static['seperator'](){return a0_0x57bbf0(()=>new Date()['toLocaleDateString'](a0_0x596399['glCode'])['replace'](/\d/g,'')['split']('')[0x0]);}['cpy'](){return a0_0x57bbf0(()=>a0_0x596399['new']()['setTime'](this['toTime']()));}['setCode'](_0x113e79){return this['code']=_0x113e79,this;}['seperator'](){return a0_0x57bbf0(()=>new Date()['toLocaleDateString'](this['code'])['replace'](/\d/g,'')['split']('')[0x0]);}['zone'](){return a0_0x57bbf0(()=>{return Intl['DateTimeFormat']()?.['resolvedOptions']()?.['timeZone'];},null);}['zones'](_0x31326e=this['code']){return a0_0x57bbf0(()=>{return new Intl['Locale'](_0x31326e)?.['timeZones']||[];},null);}['region'](_0x3b1621=this['code']){return a0_0x57bbf0(()=>{return new Intl['Locale'](_0x3b1621)['region'];},null);}['year'](){return this['val']['getFullYear']();}['month'](){return this['val']['getMonth']()+0x1;}['monthUtc'](){return this['val']['getMonth']();}['day'](){return this['val']['getDate']();}['hours'](){return this['val']['getHours']();}['min'](){return this['val']['getMinutes']();}['sec'](){return this['val']['getSeconds']();}['msec'](){return this['val']['getMilliseconds']();}['dayOfWeek'](){const _0x238dce=this['val']['getDay']();return _0x238dce?_0x238dce:0x7;}['dayOfWeekUtc'](){return this['val']['getDay']();}['setYear'](_0x188e1d){return this['val']['setFullYear'](_0x188e1d),this;}['setMonth'](_0xf68df8){return this['val']['setMonth'](_0xf68df8-0x1),this;}['setMonthUtc'](_0x16dd41){return this['val']['setMonth'](_0x16dd41),this;}['setDay'](_0x1c159c){return this['val']['setDate'](_0x1c159c),this;}['setHour'](_0x1551e3){return this['val']['setHours'](_0x1551e3),this;}['startOfHours'](){return this['setMin'](0x0),this['setSeconds'](0x0),this['setMilliseconds'](0x0),this;}['endOfHours'](){return this['setMin'](0x3b),this['setSeconds'](0x3b),this['setMilliseconds'](0x3e7),this;}['setMin'](_0x20f6c2){return this['val']['setMinutes'](_0x20f6c2),this;}['startOfMin'](){return this['setSeconds'](0x0),this['setMilliseconds'](0x0),this;}['endOfMin'](){return this['setSeconds'](0x3b),this['setMilliseconds'](0x3e7),this;}['setSeconds'](_0x346852){return this['val']['setSeconds'](_0x346852),this;}['startOfSeconds'](){return this['setMilliseconds'](0x0),this;}['endOfSeconds'](){return this['setMilliseconds'](0x3e7),this;}['setMilliseconds'](_0xa174e5){return this['val']['setMilliseconds'](_0xa174e5),this;}['startOfMilliseconds'](){return this['setMilliseconds'](0x0),this;}['endOfMilliseconds'](){return this['setMilliseconds'](0x3e7),this;}['setIsoDate'](_0x36b1d4){return this['val']=new Date(_0x36b1d4),this;}['setTime'](_0x3c7f2c){return this['val']=new Date(_0x3c7f2c),this;}['setDate'](_0x5abdd9){return this['val']=new Date(_0x5abdd9),this;}['setDateInputValue'](_0x546667){return this['val']=new Date(_0x546667?.['replace']('T','\x20')),this;}['setVal'](_0x5ee64b){return a0_0x57bbf0(()=>{return a0_0x596399['new']()['setTime'](a0_0x23a3f3(_0x5ee64b));});}['toIsoDate'](){return this['val']['toISOString']();}['toTime'](){return this['val']['getTime']();}['toDate'](){return this['val'];}['toDateMounthInput'](){return this['year']()+'-'+a0_0x4986cd(this['month']());}['toDateInput'](){return this['year']()+'-'+a0_0x4986cd(this['month']())+'-'+a0_0x4986cd(this['day']());}['toTimeInput'](_0x11277d=!![]){const _0x30e827=[];return _0x30e827['push'](a0_0x4986cd(this['hours']())),_0x30e827['push'](a0_0x4986cd(this['min']())),_0x11277d&&_0x30e827['push'](a0_0x4986cd(this['sec']())),_0x30e827['join'](':');}['toDateTimeInput'](_0x44e02d=!![]){return this['toDateInput']()+'T'+this['toTimeInput'](_0x44e02d);}['strDate'](){const _0x2216ae={};return _0x2216ae['month']='2-digit',_0x2216ae['day']='2-digit',_0x2216ae['year']='numeric',this['val']['toLocaleDateString'](this['code'],_0x2216ae);}['strDateLocal'](_0x1e7a71){return this['val']['toLocaleDateString'](this['code'],_0x1e7a71);}['strTime'](){return a0_0x4986cd(this['hours']())+':'+a0_0x4986cd(this['min']())+':'+a0_0x4986cd(this['sec']());}['strTimeLocale'](_0x3fea8e){return this['val']['toLocaleTimeString'](this['code'],_0x3fea8e);}['strHHmm'](){return a0_0x4986cd(this['hours']())+':'+a0_0x4986cd(this['min']());}['str'](){return this['strDate']()+'\x20'+this['strTime']();}['strLocal'](_0x1d88f4){return this['val']['toLocaleString'](this['code'],_0x1d88f4);}['strYears'](){return this['val']['getFullYear']()['toString']();}['strMounth'](){return a0_0x4986cd(this['month'](),0x2);}['strDay'](){return a0_0x4986cd(this['day'](),0x2);}['strHour'](){return a0_0x4986cd(this['hours'](),0x2);}['strMin'](){return a0_0x4986cd(this['min'](),0x2);}['strSec'](){return a0_0x4986cd(this['sec'](),0x2);}['strMsec'](){return a0_0x4986cd(this['msec'](),0x2);}['strDayStr'](){return{'ln':()=>this['dyfrmt']['ln'](),'sh':()=>this['dyfrmt']['sh'](),'nr':()=>this['dyfrmt']['nr']()};}['addDay'](_0x3373fe){return this['val']=new Date(this['val']['setHours'](this['val']['getHours']()+_0x3373fe*0x18)),this;}['addHours'](_0x2ee0ac){return this['val']=new Date(this['val']['setHours'](this['val']['getHours']()+_0x2ee0ac)),this;}['addMins'](_0x5f2fc0){return this['val']=new Date(this['val']['setMinutes'](this['val']['getMinutes']()+_0x5f2fc0)),this;}['startOfDay'](){return this['setHour'](0x0),this['startOfHours'](),this;}['cpyByStartOfDay'](){return this['cpy']()['startOfDay']();}['endOfDay'](){return this['setHour'](0x17),this['endOfHours'](),this;}['cpyByEndOfDay'](){return this['cpy']()['endOfDay']();}['startOfWeek'](){return this['addDay'](-this['dayOfWeek']()+0x1);}['cpyStartOfWeek'](){return this['cpy']()['addDay'](-this['dayOfWeek']()+0x1);}['endOfWeek'](){return this['startOfWeek']()['addDay'](0x6);}['cpyEndOfWeek'](){return this['cpyStartOfWeek']()['addDay'](0x6);}['startOfMonth'](){return this['setDay'](0x1),this['startOfDay'](),this;}['cpyByStartOfMonth'](){return this['cpy']()['startOfMonth']();}['endOfMonth'](){return this['setDate'](this['val'])['startOfMonth']()['setMonth'](this['month']()+0x1)['startOfMonth']()['addDay'](-0x1)['endOfDay'](),this;}['cpyByEndOfMonth'](){return this['cpy']()['endOfMonth']();}['eq'](_0x501d05){return a0_0x57bbf0(()=>{return this['cpy']()['toTime']()===a0_0x23a3f3(_0x501d05);});}['gt'](_0x42e881){return a0_0x57bbf0(()=>{return this['cpy']()['toTime']()>a0_0x23a3f3(_0x42e881);});}['gte'](_0x1338f7){return a0_0x57bbf0(()=>{return this['cpy']()['toTime']()>=a0_0x23a3f3(_0x1338f7);});}['lt'](_0x4e9d1b){return a0_0x57bbf0(()=>{return this['cpy']()['toTime']()<a0_0x23a3f3(_0x4e9d1b);});}['lte'](_0xfbab6a){return a0_0x57bbf0(()=>{return this['cpy']()['toTime']()<=a0_0x23a3f3(_0xfbab6a);});}['btw'](_0x52fed3,_0x3382d9){return a0_0x57bbf0(()=>{const _0x59e9a1=a0_0x23a3f3(_0x52fed3),_0x22cb04=a0_0x23a3f3(_0x3382d9),_0x2da795=this['cpy']()['toTime']();return _0x59e9a1<_0x2da795&&_0x2da795<_0x22cb04;});}['btweq'](_0x585891,_0x4cac62){return a0_0x57bbf0(()=>{const _0x38d501=a0_0x23a3f3(_0x585891),_0x5c1c2b=a0_0x23a3f3(_0x4cac62),_0x33d3cf=this['cpy']()['toTime']();return _0x38d501<=_0x33d3cf&&_0x33d3cf<=_0x5c1c2b;});}['btwEqStart'](_0x25c9cf,_0x2d4128){return a0_0x57bbf0(()=>{const _0x1f19f3=a0_0x23a3f3(_0x25c9cf),_0x2f6656=a0_0x23a3f3(_0x2d4128),_0x5929e9=this['cpy']()['toTime']();return _0x1f19f3<=_0x5929e9&&_0x5929e9<_0x2f6656;});}['btwEqEnd'](_0x24f58e,_0x560fcd){return a0_0x57bbf0(()=>{const _0x2a6dc9=a0_0x23a3f3(_0x24f58e),_0x401d04=a0_0x23a3f3(_0x560fcd),_0x3b315c=this['cpy']()['toTime']();return _0x2a6dc9<_0x3b315c&&_0x3b315c<=_0x401d04;});}static['diffDays'](_0x5981e0,_0x349532,_0x4c073){return a0_0x57bbf0(()=>{const _0x5c660a=a0_0x23a3f3(_0x5981e0),_0x481adb=a0_0x23a3f3(_0x349532);return _0x4c073?Math['abs'](_0x5c660a-_0x481adb)/0x36ee80/0x18:(_0x5c660a-_0x481adb)/0x36ee80/0x18;});}static['diffHours'](_0x2d020e,_0x45e1c4,_0x252d0f){return a0_0x57bbf0(()=>{const _0x928a09=a0_0x23a3f3(_0x2d020e),_0x5286c0=a0_0x23a3f3(_0x45e1c4);return _0x252d0f?Math['abs'](_0x928a09-_0x5286c0)/0x36ee80:(_0x928a09-_0x5286c0)/0x36ee80;});}static['diffMins'](_0x4fd28c,_0x46f195,_0x1a6b98){return a0_0x57bbf0(()=>{const _0x1cf393=a0_0x23a3f3(_0x4fd28c),_0x3388e3=a0_0x23a3f3(_0x46f195);return _0x1a6b98?Math['abs'](_0x1cf393-_0x3388e3)/0x3e8/0x3c:(_0x1cf393-_0x3388e3)/0x3e8/0x3c;});}static['diffSecs'](_0x2f907e,_0xa882eb,_0x330a0b){return a0_0x57bbf0(()=>{const _0x1d2b9b=a0_0x23a3f3(_0x2f907e),_0x5683fa=a0_0x23a3f3(_0xa882eb);return _0x330a0b?Math['abs'](_0x1d2b9b-_0x5683fa)/0x3e8:(_0x1d2b9b-_0x5683fa)/0x3e8;});}static['s1'](_0x29c900,_0x580d8e,_0x54d8a4,_0x4adf1b){return a0_0x57bbf0(()=>a0_0x5febf6(_0x29c900,_0x580d8e,_0x54d8a4,_0x4adf1b));}static['divideTime'](_0x2a6b04){return a0_0x57bbf0(()=>a0_0x23c807(_0x2a6b04));}}exports['MDateUtil']=a0_0x596399;const a0_0x5f2fdc={};a0_0x5f2fdc['value']='mdateutil',a0_0x5f2fdc['writable']=![],a0_0x5f2fdc['enumerable']=!![],a0_0x5f2fdc['configurable']=![],Object['defineProperty'](a0_0x596399['prototype'],'idkey',a0_0x5f2fdc);
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';var a0_0x1bff0e=this&&this['__createBinding']||(Object['create']?function(_0x1c9820,_0xdddfc3,_0x495c65,_0x3188b1){if(_0x3188b1===undefined)_0x3188b1=_0x495c65;var _0x4736cc=Object['getOwnPropertyDescriptor'](_0xdddfc3,_0x495c65);if(!_0x4736cc||('get'in _0x4736cc?!_0xdddfc3['__esModule']:_0x4736cc['writable']||_0x4736cc['configurable'])){var _0x42fe29={};_0x42fe29['enumerable']=!![],_0x42fe29['get']=function(){return _0xdddfc3[_0x495c65];},_0x4736cc=_0x42fe29;}Object['defineProperty'](_0x1c9820,_0x3188b1,_0x4736cc);}:function(_0x59855d,_0x39371e,_0x2831ab,_0x2f1ae2){if(_0x2f1ae2===undefined)_0x2f1ae2=_0x2831ab;_0x59855d[_0x2f1ae2]=_0x39371e[_0x2831ab];}),a0_0x5ae73b=this&&this['__exportStar']||function(_0xf87aec,_0x35cb4e){for(var _0x3d5a8b in _0xf87aec)if(_0x3d5a8b!=='default'&&!Object['prototype']['hasOwnProperty']['call'](_0x35cb4e,_0x3d5a8b))a0_0x1bff0e(_0x35cb4e,_0xf87aec,_0x3d5a8b);},a0_0x557af6={};a0_0x557af6['value']=!![],Object['defineProperty'](exports,'__esModule',a0_0x557af6),a0_0x5ae73b(require('./DateUtil'),exports);
|