123456789101112131415 |
- /*!
- * Tabler v1.0.0-beta14 (https://tabler.io)
- * @version 1.0.0-beta14
- * @link https://tabler.io
- * Copyright 2018-2022 The Tabler Authors
- * Copyright 2018-2022 codecalm.net Paweł Kuna
- * Licensed under MIT (https://github.com/tabler/tabler/blob/master/LICENSE)
- */
- var e,t,n="function"==typeof Map?new Map:(e=[],t=[],{has:function(t){return e.indexOf(t)>-1},get:function(n){return t[e.indexOf(n)]},set:function(n,i){-1===e.indexOf(n)&&(e.push(n),t.push(i))},delete:function(n){var i=e.indexOf(n);i>-1&&(e.splice(i,1),t.splice(i,1))}}),o=function(e){return new Event(e,{bubbles:!0})};try{new Event("test")}catch(e){o=function(e){var t=document.createEvent("Event");return t.initEvent(e,!0,!1),t}}function r(e){var t=n.get(e);t&&t.destroy()}function i(e){var t=n.get(e);t&&t.update()}var l=null;"undefined"==typeof window||"function"!=typeof window.getComputedStyle?((l=function(e){return e}).destroy=function(e){return e},l.update=function(e){return e}):((l=function(e,t){return e&&Array.prototype.forEach.call(e.length?e:[e],(function(e){return function(e){if(e&&e.nodeName&&"TEXTAREA"===e.nodeName&&!n.has(e)){var t,i=null,s=null,r=null,a=function(){e.clientWidth!==s&&h()},l=function(t){window.removeEventListener("resize",a,!1),e.removeEventListener("input",h,!1),e.removeEventListener("keyup",h,!1),e.removeEventListener("autosize:destroy",l,!1),e.removeEventListener("autosize:update",h,!1),Object.keys(t).forEach((function(n){e.style[n]=t[n]})),n.delete(e)}.bind(e,{height:e.style.height,resize:e.style.resize,overflowY:e.style.overflowY,overflowX:e.style.overflowX,wordWrap:e.style.wordWrap});e.addEventListener("autosize:destroy",l,!1),"onpropertychange"in e&&"oninput"in e&&e.addEventListener("keyup",h,!1),window.addEventListener("resize",a,!1),e.addEventListener("input",h,!1),e.addEventListener("autosize:update",h,!1),e.style.overflowX="hidden",e.style.wordWrap="break-word",n.set(e,{destroy:l,update:h}),"vertical"===(t=window.getComputedStyle(e,null)).resize?e.style.resize="none":"both"===t.resize&&(e.style.resize="horizontal"),i="content-box"===t.boxSizing?-(parseFloat(t.paddingTop)+parseFloat(t.paddingBottom)):parseFloat(t.borderTopWidth)+parseFloat(t.borderBottomWidth),isNaN(i)&&(i=0),h()}function u(t){var n=e.style.width;e.style.width="0px",e.style.width=n,e.style.overflowY=t}function c(){if(0!==e.scrollHeight){var t=function(e){for(var t=[];e&&e.parentNode&&e.parentNode instanceof Element;)e.parentNode.scrollTop&&t.push({node:e.parentNode,scrollTop:e.parentNode.scrollTop}),e=e.parentNode;return t}(e),n=document.documentElement&&document.documentElement.scrollTop;e.style.height="",e.style.height=e.scrollHeight+i+"px",s=e.clientWidth,t.forEach((function(e){e.node.scrollTop=e.scrollTop})),n&&(document.documentElement.scrollTop=n)}}function h(){c();var t=Math.round(parseFloat(e.style.height)),n=window.getComputedStyle(e,null),i="content-box"===n.boxSizing?Math.round(parseFloat(n.height)):e.offsetHeight;if(i<t?"hidden"===n.overflowY&&(u("scroll"),c(),i="content-box"===n.boxSizing?Math.round(parseFloat(window.getComputedStyle(e,null).height)):e.offsetHeight):"hidden"!==n.overflowY&&(u("hidden"),c(),i="content-box"===n.boxSizing?Math.round(parseFloat(window.getComputedStyle(e,null).height)):e.offsetHeight),r!==i){r=i;var s=o("autosize:resized");try{e.dispatchEvent(s)}catch(e){}}}}(e)})),e}).destroy=function(e){return e&&Array.prototype.forEach.call(e.length?e:[e],r),e},l.update=function(e){return e&&Array.prototype.forEach.call(e.length?e:[e],i),e});var d=l,elements=document.querySelectorAll('[data-bs-toggle="autosize"]');function _typeof(e){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(e)}function _classCallCheck(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _defineProperties(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function _createClass(e,t,n){return t&&_defineProperties(e.prototype,t),n&&_defineProperties(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function _defineProperty(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function _inherits(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&_setPrototypeOf(e,t)}function _getPrototypeOf(e){return _getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},_getPrototypeOf(e)}function _setPrototypeOf(e,t){return _setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},_setPrototypeOf(e,t)}function _isNativeReflectConstruct(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function _objectWithoutPropertiesLoose(e,t){if(null==e)return{};var n,i,s={},r=Object.keys(e);for(i=0;i<r.length;i++)n=r[i],t.indexOf(n)>=0||(s[n]=e[n]);return s}function _objectWithoutProperties(e,t){if(null==e)return{};var n,i,s=_objectWithoutPropertiesLoose(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(i=0;i<r.length;i++)n=r[i],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(s[n]=e[n])}return s}function _assertThisInitialized(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function _possibleConstructorReturn(e,t){if(t&&("object"==typeof t||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return _assertThisInitialized(e)}function _createSuper(e){var t=_isNativeReflectConstruct();return function(){var n,i=_getPrototypeOf(e);if(t){var s=_getPrototypeOf(this).constructor;n=Reflect.construct(i,arguments,s)}else n=i.apply(this,arguments);return _possibleConstructorReturn(this,n)}}function _superPropBase(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=_getPrototypeOf(e)););return e}function _get(){return _get="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var i=_superPropBase(e,t);if(i){var s=Object.getOwnPropertyDescriptor(i,t);return s.get?s.get.call(arguments.length<3?e:n):s.value}},_get.apply(this,arguments)}function set(e,t,n,i){return set="undefined"!=typeof Reflect&&Reflect.set?Reflect.set:function(e,t,n,i){var s,r=_superPropBase(e,t);if(r){if((s=Object.getOwnPropertyDescriptor(r,t)).set)return s.set.call(i,n),!0;if(!s.writable)return!1}if(s=Object.getOwnPropertyDescriptor(i,t)){if(!s.writable)return!1;s.value=n,Object.defineProperty(i,t,s)}else _defineProperty(i,t,n);return!0},set(e,t,n,i)}function _set(e,t,n,i,s){if(!set(e,t,n,i||e)&&s)throw new Error("failed to set property");return n}function _slicedToArray(e,t){return _arrayWithHoles(e)||_iterableToArrayLimit(e,t)||_unsupportedIterableToArray(e,t)||_nonIterableRest()}function _toConsumableArray(e){return _arrayWithoutHoles(e)||_iterableToArray(e)||_unsupportedIterableToArray(e)||_nonIterableSpread()}function _arrayWithoutHoles(e){if(Array.isArray(e))return _arrayLikeToArray(e)}function _arrayWithHoles(e){if(Array.isArray(e))return e}function _iterableToArray(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function _iterableToArrayLimit(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i,s,r=[],o=!0,a=!1;try{for(n=n.call(e);!(o=(i=n.next()).done)&&(r.push(i.value),!t||r.length!==t);o=!0);}catch(e){a=!0,s=e}finally{try{o||null==n.return||n.return()}finally{if(a)throw s}}return r}}function _unsupportedIterableToArray(e,t){if(e){if("string"==typeof e)return _arrayLikeToArray(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?_arrayLikeToArray(e,t):void 0}}function _arrayLikeToArray(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function _nonIterableSpread(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _nonIterableRest(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}elements.length&&elements.forEach((function(e){d(e)}));var ChangeDetails=function(){function e(t){_classCallCheck(this,e),Object.assign(this,{inserted:"",rawInserted:"",skip:!1,tailShift:0},t)}return _createClass(e,[{key:"aggregate",value:function(e){return this.rawInserted+=e.rawInserted,this.skip=this.skip||e.skip,this.inserted+=e.inserted,this.tailShift+=e.tailShift,this}},{key:"offset",get:function(){return this.tailShift+this.inserted.length}}]),e}();function isString(e){return"string"==typeof e||e instanceof String}var DIRECTION={NONE:"NONE",LEFT:"LEFT",FORCE_LEFT:"FORCE_LEFT",RIGHT:"RIGHT",FORCE_RIGHT:"FORCE_RIGHT"};function forceDirection(e){switch(e){case DIRECTION.LEFT:return DIRECTION.FORCE_LEFT;case DIRECTION.RIGHT:return DIRECTION.FORCE_RIGHT;default:return e}}function escapeRegExp(e){return e.replace(/([.*+?^=!:${}()|[\]\/\\])/g,"\\$1")}function normalizePrepare(e){return Array.isArray(e)?e:[e,new ChangeDetails]}function objectIncludes(e,t){if(t===e)return!0;var n,i=Array.isArray(t),s=Array.isArray(e);if(i&&s){if(t.length!=e.length)return!1;for(n=0;n<t.length;n++)if(!objectIncludes(t[n],e[n]))return!1;return!0}if(i!=s)return!1;if(t&&e&&"object"===_typeof(t)&&"object"===_typeof(e)){var r=t instanceof Date,o=e instanceof Date;if(r&&o)return t.getTime()==e.getTime();if(r!=o)return!1;var a=t instanceof RegExp,l=e instanceof RegExp;if(a&&l)return t.toString()==e.toString();if(a!=l)return!1;var u=Object.keys(t);for(n=0;n<u.length;n++)if(!Object.prototype.hasOwnProperty.call(e,u[n]))return!1;for(n=0;n<u.length;n++)if(!objectIncludes(e[u[n]],t[u[n]]))return!1;return!0}return!(!t||!e||"function"!=typeof t||"function"!=typeof e)&&t.toString()===e.toString()}var ActionDetails=function(){function e(t,n,i,s){for(_classCallCheck(this,e),this.value=t,this.cursorPos=n,this.oldValue=i,this.oldSelection=s;this.value.slice(0,this.startChangePos)!==this.oldValue.slice(0,this.startChangePos);)--this.oldSelection.start}return _createClass(e,[{key:"startChangePos",get:function(){return Math.min(this.cursorPos,this.oldSelection.start)}},{key:"insertedCount",get:function(){return this.cursorPos-this.startChangePos}},{key:"inserted",get:function(){return this.value.substr(this.startChangePos,this.insertedCount)}},{key:"removedCount",get:function(){return Math.max(this.oldSelection.end-this.startChangePos||this.oldValue.length-this.value.length,0)}},{key:"removed",get:function(){return this.oldValue.substr(this.startChangePos,this.removedCount)}},{key:"head",get:function(){return this.value.substring(0,this.startChangePos)}},{key:"tail",get:function(){return this.value.substring(this.startChangePos+this.insertedCount)}},{key:"removeDirection",get:function(){return!this.removedCount||this.insertedCount?DIRECTION.NONE:this.oldSelection.end!==this.cursorPos&&this.oldSelection.start!==this.cursorPos||this.oldSelection.end!==this.oldSelection.start?DIRECTION.LEFT:DIRECTION.RIGHT}}]),e}(),ContinuousTailDetails=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2?arguments[2]:void 0;_classCallCheck(this,e),this.value=t,this.from=n,this.stop=i}return _createClass(e,[{key:"toString",value:function(){return this.value}},{key:"extend",value:function(e){this.value+=String(e)}},{key:"appendTo",value:function(e){return e.append(this.toString(),{tail:!0}).aggregate(e._appendPlaceholder())}},{key:"state",get:function(){return{value:this.value,from:this.from,stop:this.stop}},set:function(e){Object.assign(this,e)}},{key:"unshift",value:function(e){if(!this.value.length||null!=e&&this.from>=e)return"";var t=this.value[0];return this.value=this.value.slice(1),t}},{key:"shift",value:function(){if(!this.value.length)return"";var e=this.value[this.value.length-1];return this.value=this.value.slice(0,-1),e}}]),e}();function IMask(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return new IMask.InputMask(e,t)}var Masked=function(){function e(t){_classCallCheck(this,e),this._value="",this._update(Object.assign({},e.DEFAULTS,t)),this.isInitialized=!0}return _createClass(e,[{key:"updateOptions",value:function(e){Object.keys(e).length&&this.withValueRefresh(this._update.bind(this,e))}},{key:"_update",value:function(e){Object.assign(this,e)}},{key:"state",get:function(){return{_value:this.value}},set:function(e){this._value=e._value}},{key:"reset",value:function(){this._value=""}},{key:"value",get:function(){return this._value},set:function(e){this.resolve(e)}},{key:"resolve",value:function(e){return this.reset(),this.append(e,{input:!0},""),this.doCommit(),this.value}},{key:"unmaskedValue",get:function(){return this.value},set:function(e){this.reset(),this.append(e,{},""),this.doCommit()}},{key:"typedValue",get:function(){return this.doParse(this.value)},set:function(e){this.value=this.doFormat(e)}},{key:"rawInputValue",get:function(){return this.extractInput(0,this.value.length,{raw:!0})},set:function(e){this.reset(),this.append(e,{raw:!0},""),this.doCommit()}},{key:"isComplete",get:function(){return!0}},{key:"isFilled",get:function(){return this.isComplete}},{key:"nearestInputPos",value:function(e,t){return e}},{key:"extractInput",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.value.length;return this.value.slice(e,t)}},{key:"extractTail",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.value.length;return new ContinuousTailDetails(this.extractInput(e,t),e)}},{key:"appendTail",value:function(e){return isString(e)&&(e=new ContinuousTailDetails(String(e))),e.appendTo(this)}},{key:"_appendCharRaw",value:function(e){return e?(this._value+=e,new ChangeDetails({inserted:e,rawInserted:e})):new ChangeDetails}},{key:"_appendChar",value:function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=arguments.length>2?arguments[2]:void 0,s=this.state,r=normalizePrepare(this.doPrepare(e,n)),o=_slicedToArray(r,2);if(e=o[0],(t=(t=o[1]).aggregate(this._appendCharRaw(e,n))).inserted){var a,l=!1!==this.doValidate(n);if(l&&null!=i){var u=this.state;!0===this.overwrite&&(a=i.state,i.unshift(this.value.length));var c=this.appendTail(i);(l=c.rawInserted===i.toString())&&c.inserted||"shift"!==this.overwrite||(this.state=u,a=i.state,i.shift(),l=(c=this.appendTail(i)).rawInserted===i.toString()),l&&c.inserted&&(this.state=u)}l||(t=new ChangeDetails,this.state=s,i&&a&&(i.state=a))}return t}},{key:"_appendPlaceholder",value:function(){return new ChangeDetails}},{key:"_appendEager",value:function(){return new ChangeDetails}},{key:"append",value:function(e,t,n){if(!isString(e))throw new Error("value should be string");var i=new ChangeDetails,s=isString(n)?new ContinuousTailDetails(String(n)):n;null!=t&&t.tail&&(t._beforeTailState=this.state);for(var r=0;r<e.length;++r)i.aggregate(this._appendChar(e[r],t,s));return null!=s&&(i.tailShift+=this.appendTail(s).tailShift),this.eager&&null!=t&&t.input&&e&&i.aggregate(this._appendEager()),i}},{key:"remove",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.value.length;return this._value=this.value.slice(0,e)+this.value.slice(t),new ChangeDetails}},{key:"withValueRefresh",value:function(e){if(this._refreshing||!this.isInitialized)return e();this._refreshing=!0;var t=this.rawInputValue,n=this.value,i=e();return this.rawInputValue=t,this.value&&this.value!==n&&0===n.indexOf(this.value)&&this.append(n.slice(this.value.length),{},""),delete this._refreshing,i}},{key:"runIsolated",value:function(e){if(this._isolated||!this.isInitialized)return e(this);this._isolated=!0;var t=this.state,n=e(this);return this.state=t,delete this._isolated,n}},{key:"doPrepare",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.prepare?this.prepare(e,this,t):e}},{key:"doValidate",value:function(e){return(!this.validate||this.validate(this.value,this,e))&&(!this.parent||this.parent.doValidate(e))}},{key:"doCommit",value:function(){this.commit&&this.commit(this.value,this)}},{key:"doFormat",value:function(e){return this.format?this.format(e,this):e}},{key:"doParse",value:function(e){return this.parse?this.parse(e,this):e}},{key:"splice",value:function(e,t,n,i){var s,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{input:!0},o=e+t,a=this.extractTail(o);this.eager&&(i=forceDirection(i),s=this.extractInput(0,o,{raw:!0}));var l=this.nearestInputPos(e,t>1&&0!==e&&!this.eager?DIRECTION.NONE:i),u=new ChangeDetails({tailShift:l-e}).aggregate(this.remove(l));if(this.eager&&i!==DIRECTION.NONE&&s===this.rawInputValue)if(i===DIRECTION.FORCE_LEFT)for(var c;s===this.rawInputValue&&(c=this.value.length);)u.aggregate(new ChangeDetails({tailShift:-1})).aggregate(this.remove(c-1));else i===DIRECTION.FORCE_RIGHT&&a.unshift();return u.aggregate(this.append(n,r,a))}},{key:"maskEquals",value:function(e){return this.mask===e}},{key:"typedValueEquals",value:function(t){var n=this.typedValue;return t===n||e.EMPTY_VALUES.includes(t)&&e.EMPTY_VALUES.includes(n)||this.doFormat(t)===this.doFormat(this.typedValue)}}]),e}();function maskedClass(e){if(null==e)throw new Error("mask property should be defined");return e instanceof RegExp?IMask.MaskedRegExp:isString(e)?IMask.MaskedPattern:e instanceof Date||e===Date?IMask.MaskedDate:e instanceof Number||"number"==typeof e||e===Number?IMask.MaskedNumber:Array.isArray(e)||e===Array?IMask.MaskedDynamic:IMask.Masked&&e.prototype instanceof IMask.Masked?e:e instanceof IMask.Masked?e.constructor:e instanceof Function?IMask.MaskedFunction:(console.warn("Mask not found for mask",e),IMask.Masked)}function createMask(e){if(IMask.Masked&&e instanceof IMask.Masked)return e;var t=(e=Object.assign({},e)).mask;if(IMask.Masked&&t instanceof IMask.Masked)return t;var n=maskedClass(t);if(!n)throw new Error("Masked class is not found for provided mask, appropriate module needs to be import manually before creating mask.");return new n(e)}Masked.DEFAULTS={format:function(e){return e},parse:function(e){return e}},Masked.EMPTY_VALUES=[void 0,null,""],IMask.Masked=Masked,IMask.createMask=createMask;var _excluded$4=["mask"],DEFAULT_INPUT_DEFINITIONS={0:/\d/,a:/[\u0041-\u005A\u0061-\u007A\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/,"*":/./},PatternInputDefinition=function(){function e(t){_classCallCheck(this,e);var n=t.mask,i=_objectWithoutProperties(t,_excluded$4);this.masked=createMask({mask:n}),Object.assign(this,i)}return _createClass(e,[{key:"reset",value:function(){this.isFilled=!1,this.masked.reset()}},{key:"remove",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.value.length;return 0===e&&t>=1?(this.isFilled=!1,this.masked.remove(e,t)):new ChangeDetails}},{key:"value",get:function(){return this.masked.value||(this.isFilled&&!this.isOptional?this.placeholderChar:"")}},{key:"unmaskedValue",get:function(){return this.masked.unmaskedValue}},{key:"isComplete",get:function(){return Boolean(this.masked.value)||this.isOptional}},{key:"_appendChar",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(this.isFilled)return new ChangeDetails;var n=this.masked.state,i=this.masked._appendChar(e,t);return i.inserted&&!1===this.doValidate(t)&&(i.inserted=i.rawInserted="",this.masked.state=n),i.inserted||this.isOptional||this.lazy||t.input||(i.inserted=this.placeholderChar),i.skip=!i.inserted&&!this.isOptional,this.isFilled=Boolean(i.inserted),i}},{key:"append",value:function(){var e;return(e=this.masked).append.apply(e,arguments)}},{key:"_appendPlaceholder",value:function(){var e=new ChangeDetails;return this.isFilled||this.isOptional||(this.isFilled=!0,e.inserted=this.placeholderChar),e}},{key:"_appendEager",value:function(){return new ChangeDetails}},{key:"extractTail",value:function(){var e;return(e=this.masked).extractTail.apply(e,arguments)}},{key:"appendTail",value:function(){var e;return(e=this.masked).appendTail.apply(e,arguments)}},{key:"extractInput",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.value.length,n=arguments.length>2?arguments[2]:void 0;return this.masked.extractInput(e,t,n)}},{key:"nearestInputPos",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:DIRECTION.NONE,n=0,i=this.value.length,s=Math.min(Math.max(e,n),i);switch(t){case DIRECTION.LEFT:case DIRECTION.FORCE_LEFT:return this.isComplete?s:n;case DIRECTION.RIGHT:case DIRECTION.FORCE_RIGHT:return this.isComplete?s:i;case DIRECTION.NONE:default:return s}}},{key:"doValidate",value:function(){var e,t;return(e=this.masked).doValidate.apply(e,arguments)&&(!this.parent||(t=this.parent).doValidate.apply(t,arguments))}},{key:"doCommit",value:function(){this.masked.doCommit()}},{key:"state",get:function(){return{masked:this.masked.state,isFilled:this.isFilled}},set:function(e){this.masked.state=e.masked,this.isFilled=e.isFilled}}]),e}(),PatternFixedDefinition=function(){function e(t){_classCallCheck(this,e),Object.assign(this,t),this._value="",this.isFixed=!0}return _createClass(e,[{key:"value",get:function(){return this._value}},{key:"unmaskedValue",get:function(){return this.isUnmasking?this.value:""}},{key:"reset",value:function(){this._isRawInput=!1,this._value=""}},{key:"remove",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this._value.length;return this._value=this._value.slice(0,e)+this._value.slice(t),this._value||(this._isRawInput=!1),new ChangeDetails}},{key:"nearestInputPos",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:DIRECTION.NONE,n=0,i=this._value.length;switch(t){case DIRECTION.LEFT:case DIRECTION.FORCE_LEFT:return n;case DIRECTION.NONE:case DIRECTION.RIGHT:case DIRECTION.FORCE_RIGHT:default:return i}}},{key:"extractInput",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this._value.length,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return n.raw&&this._isRawInput&&this._value.slice(e,t)||""}},{key:"isComplete",get:function(){return!0}},{key:"isFilled",get:function(){return Boolean(this._value)}},{key:"_appendChar",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=new ChangeDetails;if(this._value)return n;var i=this.char===e,s=i&&(this.isUnmasking||t.input||t.raw)&&(!t.raw||!this.eager)&&!t.tail;return s&&(n.rawInserted=this.char),this._value=n.inserted=this.char,this._isRawInput=s&&(t.raw||t.input),n}},{key:"_appendEager",value:function(){return this._appendChar(this.char,{tail:!0})}},{key:"_appendPlaceholder",value:function(){var e=new ChangeDetails;return this._value||(this._value=e.inserted=this.char),e}},{key:"extractTail",value:function(){return arguments.length>1&&void 0!==arguments[1]||this.value.length,new ContinuousTailDetails("")}},{key:"appendTail",value:function(e){return isString(e)&&(e=new ContinuousTailDetails(String(e))),e.appendTo(this)}},{key:"append",value:function(e,t,n){var i=this._appendChar(e[0],t);return null!=n&&(i.tailShift+=this.appendTail(n).tailShift),i}},{key:"doCommit",value:function(){}},{key:"state",get:function(){return{_value:this._value,_isRawInput:this._isRawInput}},set:function(e){Object.assign(this,e)}}]),e}(),_excluded$3=["chunks"],ChunksTailDetails=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;_classCallCheck(this,e),this.chunks=t,this.from=n}return _createClass(e,[{key:"toString",value:function(){return this.chunks.map(String).join("")}},{key:"extend",value:function(t){if(String(t)){isString(t)&&(t=new ContinuousTailDetails(String(t)));var n=this.chunks[this.chunks.length-1],i=n&&(n.stop===t.stop||null==t.stop)&&t.from===n.from+n.toString().length;if(t instanceof ContinuousTailDetails)i?n.extend(t.toString()):this.chunks.push(t);else if(t instanceof e){if(null==t.stop)for(var s;t.chunks.length&&null==t.chunks[0].stop;)(s=t.chunks.shift()).from+=t.from,this.extend(s);t.toString()&&(t.stop=t.blockIndex,this.chunks.push(t))}}}},{key:"appendTo",value:function(t){if(!(t instanceof IMask.MaskedPattern))return new ContinuousTailDetails(this.toString()).appendTo(t);for(var n=new ChangeDetails,i=0;i<this.chunks.length&&!n.skip;++i){var s=this.chunks[i],r=t._mapPosToBlock(t.value.length),o=s.stop,a=void 0;if(null!=o&&(!r||r.index<=o)&&((s instanceof e||t._stops.indexOf(o)>=0)&&n.aggregate(t._appendPlaceholder(o)),a=s instanceof e&&t._blocks[o]),a){var l=a.appendTail(s);l.skip=!1,n.aggregate(l),t._value+=l.inserted;var u=s.toString().slice(l.rawInserted.length);u&&n.aggregate(t.append(u,{tail:!0}))}else n.aggregate(t.append(s.toString(),{tail:!0}))}return n}},{key:"state",get:function(){return{chunks:this.chunks.map((function(e){return e.state})),from:this.from,stop:this.stop,blockIndex:this.blockIndex}},set:function(t){var n=t.chunks,i=_objectWithoutProperties(t,_excluded$3);Object.assign(this,i),this.chunks=n.map((function(t){var n="chunks"in t?new e:new ContinuousTailDetails;return n.state=t,n}))}},{key:"unshift",value:function(e){if(!this.chunks.length||null!=e&&this.from>=e)return"";for(var t=null!=e?e-this.from:e,n=0;n<this.chunks.length;){var i=this.chunks[n],s=i.unshift(t);if(i.toString()){if(!s)break;++n}else this.chunks.splice(n,1);if(s)return s}return""}},{key:"shift",value:function(){if(!this.chunks.length)return"";for(var e=this.chunks.length-1;0<=e;){var t=this.chunks[e],n=t.shift();if(t.toString()){if(!n)break;--e}else this.chunks.splice(e,1);if(n)return n}return""}}]),e}(),PatternCursor=function(){function e(t,n){_classCallCheck(this,e),this.masked=t,this._log=[];var i=t._mapPosToBlock(n)||(n<0?{index:0,offset:0}:{index:this.masked._blocks.length,offset:0}),s=i.offset,r=i.index;this.offset=s,this.index=r,this.ok=!1}return _createClass(e,[{key:"block",get:function(){return this.masked._blocks[this.index]}},{key:"pos",get:function(){return this.masked._blockStartPos(this.index)+this.offset}},{key:"state",get:function(){return{index:this.index,offset:this.offset,ok:this.ok}},set:function(e){Object.assign(this,e)}},{key:"pushState",value:function(){this._log.push(this.state)}},{key:"popState",value:function(){var e=this._log.pop();return this.state=e,e}},{key:"bindBlock",value:function(){this.block||(this.index<0&&(this.index=0,this.offset=0),this.index>=this.masked._blocks.length&&(this.index=this.masked._blocks.length-1,this.offset=this.block.value.length))}},{key:"_pushLeft",value:function(e){for(this.pushState(),this.bindBlock();0<=this.index;--this.index,this.offset=(null===(t=this.block)||void 0===t?void 0:t.value.length)||0){var t;if(e())return this.ok=!0}return this.ok=!1}},{key:"_pushRight",value:function(e){for(this.pushState(),this.bindBlock();this.index<this.masked._blocks.length;++this.index,this.offset=0)if(e())return this.ok=!0;return this.ok=!1}},{key:"pushLeftBeforeFilled",value:function(){var e=this;return this._pushLeft((function(){if(!e.block.isFixed&&e.block.value)return e.offset=e.block.nearestInputPos(e.offset,DIRECTION.FORCE_LEFT),0!==e.offset||void 0}))}},{key:"pushLeftBeforeInput",value:function(){var e=this;return this._pushLeft((function(){if(!e.block.isFixed)return e.offset=e.block.nearestInputPos(e.offset,DIRECTION.LEFT),!0}))}},{key:"pushLeftBeforeRequired",value:function(){var e=this;return this._pushLeft((function(){if(!(e.block.isFixed||e.block.isOptional&&!e.block.value))return e.offset=e.block.nearestInputPos(e.offset,DIRECTION.LEFT),!0}))}},{key:"pushRightBeforeFilled",value:function(){var e=this;return this._pushRight((function(){if(!e.block.isFixed&&e.block.value)return e.offset=e.block.nearestInputPos(e.offset,DIRECTION.FORCE_RIGHT),e.offset!==e.block.value.length||void 0}))}},{key:"pushRightBeforeInput",value:function(){var e=this;return this._pushRight((function(){if(!e.block.isFixed)return e.offset=e.block.nearestInputPos(e.offset,DIRECTION.NONE),!0}))}},{key:"pushRightBeforeRequired",value:function(){var e=this;return this._pushRight((function(){if(!(e.block.isFixed||e.block.isOptional&&!e.block.value))return e.offset=e.block.nearestInputPos(e.offset,DIRECTION.NONE),!0}))}}]),e}(),MaskedRegExp=function(e){_inherits(n,Masked);var t=_createSuper(n);function n(){return _classCallCheck(this,n),t.apply(this,arguments)}return _createClass(n,[{key:"_update",value:function(e){e.mask&&(e.validate=function(t){return t.search(e.mask)>=0}),_get(_getPrototypeOf(n.prototype),"_update",this).call(this,e)}}]),n}();IMask.MaskedRegExp=MaskedRegExp;var _excluded$2=["_blocks"],MaskedPattern=function(e){_inherits(n,Masked);var t=_createSuper(n);function n(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return _classCallCheck(this,n),e.definitions=Object.assign({},DEFAULT_INPUT_DEFINITIONS,e.definitions),t.call(this,Object.assign({},n.DEFAULTS,e))}return _createClass(n,[{key:"_update",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e.definitions=Object.assign({},this.definitions,e.definitions),_get(_getPrototypeOf(n.prototype),"_update",this).call(this,e),this._rebuildMask()}},{key:"_rebuildMask",value:function(){var e=this,t=this.definitions;this._blocks=[],this._stops=[],this._maskedBlocks={};var i=this.mask;if(i&&t)for(var s=!1,r=!1,o=0;o<i.length;++o){if(this.blocks)if("continue"===function(){var t=i.slice(o),n=Object.keys(e.blocks).filter((function(e){return 0===t.indexOf(e)}));n.sort((function(e,t){return t.length-e.length}));var s=n[0];if(s){var r=createMask(Object.assign({parent:e,lazy:e.lazy,eager:e.eager,placeholderChar:e.placeholderChar,overwrite:e.overwrite},e.blocks[s]));return r&&(e._blocks.push(r),e._maskedBlocks[s]||(e._maskedBlocks[s]=[]),e._maskedBlocks[s].push(e._blocks.length-1)),o+=s.length-1,"continue"}}())continue;var a=i[o],l=a in t;if(a!==n.STOP_CHAR)if("{"!==a&&"}"!==a)if("["!==a&&"]"!==a){if(a===n.ESCAPE_CHAR){if(++o,!(a=i[o]))break;l=!1}var u=l?new PatternInputDefinition({parent:this,lazy:this.lazy,eager:this.eager,placeholderChar:this.placeholderChar,mask:t[a],isOptional:r}):new PatternFixedDefinition({char:a,eager:this.eager,isUnmasking:s});this._blocks.push(u)}else r=!r;else s=!s;else this._stops.push(this._blocks.length)}}},{key:"state",get:function(){return Object.assign({},_get(_getPrototypeOf(n.prototype),"state",this),{_blocks:this._blocks.map((function(e){return e.state}))})},set:function(e){var t=e._blocks,i=_objectWithoutProperties(e,_excluded$2);this._blocks.forEach((function(e,n){return e.state=t[n]})),_set(_getPrototypeOf(n.prototype),"state",i,this,!0)}},{key:"reset",value:function(){_get(_getPrototypeOf(n.prototype),"reset",this).call(this),this._blocks.forEach((function(e){return e.reset()}))}},{key:"isComplete",get:function(){return this._blocks.every((function(e){return e.isComplete}))}},{key:"isFilled",get:function(){return this._blocks.every((function(e){return e.isFilled}))}},{key:"isFixed",get:function(){return this._blocks.every((function(e){return e.isFixed}))}},{key:"isOptional",get:function(){return this._blocks.every((function(e){return e.isOptional}))}},{key:"doCommit",value:function(){this._blocks.forEach((function(e){return e.doCommit()})),_get(_getPrototypeOf(n.prototype),"doCommit",this).call(this)}},{key:"unmaskedValue",get:function(){return this._blocks.reduce((function(e,t){return e+t.unmaskedValue}),"")},set:function(e){_set(_getPrototypeOf(n.prototype),"unmaskedValue",e,this,!0)}},{key:"value",get:function(){return this._blocks.reduce((function(e,t){return e+t.value}),"")},set:function(e){_set(_getPrototypeOf(n.prototype),"value",e,this,!0)}},{key:"appendTail",value:function(e){return _get(_getPrototypeOf(n.prototype),"appendTail",this).call(this,e).aggregate(this._appendPlaceholder())}},{key:"_appendEager",value:function(){var e,t=new ChangeDetails,n=null===(e=this._mapPosToBlock(this.value.length))||void 0===e?void 0:e.index;if(null==n)return t;this._blocks[n].isFilled&&++n;for(var i=n;i<this._blocks.length;++i){var s=this._blocks[i]._appendEager();if(!s.inserted)break;t.aggregate(s)}return t}},{key:"_appendCharRaw",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this._mapPosToBlock(this.value.length),i=new ChangeDetails;if(!n)return i;for(var s=n.index;;++s){var r,o,a=this._blocks[s];if(!a)break;var l=a._appendChar(e,Object.assign({},t,{_beforeTailState:null===(r=t._beforeTailState)||void 0===r||null===(o=r._blocks)||void 0===o?void 0:o[s]})),u=l.skip;if(i.aggregate(l),u||l.rawInserted)break}return i}},{key:"extractTail",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.value.length,i=new ChunksTailDetails;return t===n||this._forEachBlocksInRange(t,n,(function(t,n,s,r){var o=t.extractTail(s,r);o.stop=e._findStopBefore(n),o.from=e._blockStartPos(n),o instanceof ChunksTailDetails&&(o.blockIndex=n),i.extend(o)})),i}},{key:"extractInput",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.value.length,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(e===t)return"";var i="";return this._forEachBlocksInRange(e,t,(function(e,t,s,r){i+=e.extractInput(s,r,n)})),i}},{key:"_findStopBefore",value:function(e){for(var t,n=0;n<this._stops.length;++n){var i=this._stops[n];if(!(i<=e))break;t=i}return t}},{key:"_appendPlaceholder",value:function(e){var t=this,n=new ChangeDetails;if(this.lazy&&null==e)return n;var i=this._mapPosToBlock(this.value.length);if(!i)return n;var s=i.index,r=null!=e?e:this._blocks.length;return this._blocks.slice(s,r).forEach((function(i){if(!i.lazy||null!=e){var s=null!=i._blocks?[i._blocks.length]:[],r=i._appendPlaceholder.apply(i,s);t._value+=r.inserted,n.aggregate(r)}})),n}},{key:"_mapPosToBlock",value:function(e){for(var t="",n=0;n<this._blocks.length;++n){var i=this._blocks[n],s=t.length;if(e<=(t+=i.value).length)return{index:n,offset:e-s}}}},{key:"_blockStartPos",value:function(e){return this._blocks.slice(0,e).reduce((function(e,t){return e+t.value.length}),0)}},{key:"_forEachBlocksInRange",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.value.length,n=arguments.length>2?arguments[2]:void 0,i=this._mapPosToBlock(e);if(i){var s=this._mapPosToBlock(t),r=s&&i.index===s.index,o=i.offset,a=s&&r?s.offset:this._blocks[i.index].value.length;if(n(this._blocks[i.index],i.index,o,a),s&&!r){for(var l=i.index+1;l<s.index;++l)n(this._blocks[l],l,0,this._blocks[l].value.length);n(this._blocks[s.index],s.index,0,s.offset)}}}},{key:"remove",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.value.length,i=_get(_getPrototypeOf(n.prototype),"remove",this).call(this,e,t);return this._forEachBlocksInRange(e,t,(function(e,t,n,s){i.aggregate(e.remove(n,s))})),i}},{key:"nearestInputPos",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:DIRECTION.NONE;if(!this._blocks.length)return 0;var n=new PatternCursor(this,e);if(t===DIRECTION.NONE)return n.pushRightBeforeInput()?n.pos:(n.popState(),n.pushLeftBeforeInput()?n.pos:this.value.length);if(t===DIRECTION.LEFT||t===DIRECTION.FORCE_LEFT){if(t===DIRECTION.LEFT){if(n.pushRightBeforeFilled(),n.ok&&n.pos===e)return e;n.popState()}if(n.pushLeftBeforeInput(),n.pushLeftBeforeRequired(),n.pushLeftBeforeFilled(),t===DIRECTION.LEFT){if(n.pushRightBeforeInput(),n.pushRightBeforeRequired(),n.ok&&n.pos<=e)return n.pos;if(n.popState(),n.ok&&n.pos<=e)return n.pos;n.popState()}return n.ok?n.pos:t===DIRECTION.FORCE_LEFT?0:(n.popState(),n.ok?n.pos:(n.popState(),n.ok?n.pos:0))}return t===DIRECTION.RIGHT||t===DIRECTION.FORCE_RIGHT?(n.pushRightBeforeInput(),n.pushRightBeforeRequired(),n.pushRightBeforeFilled()?n.pos:t===DIRECTION.FORCE_RIGHT?this.value.length:(n.popState(),n.ok?n.pos:(n.popState(),n.ok?n.pos:this.nearestInputPos(e,DIRECTION.LEFT)))):e}},{key:"maskedBlock",value:function(e){return this.maskedBlocks(e)[0]}},{key:"maskedBlocks",value:function(e){var t=this,n=this._maskedBlocks[e];return n?n.map((function(e){return t._blocks[e]})):[]}}]),n}();MaskedPattern.DEFAULTS={lazy:!0,placeholderChar:"_"},MaskedPattern.STOP_CHAR="`",MaskedPattern.ESCAPE_CHAR="\\",MaskedPattern.InputDefinition=PatternInputDefinition,MaskedPattern.FixedDefinition=PatternFixedDefinition,IMask.MaskedPattern=MaskedPattern;var MaskedRange=function(e){_inherits(n,MaskedPattern);var t=_createSuper(n);function n(){return _classCallCheck(this,n),t.apply(this,arguments)}return _createClass(n,[{key:"_matchFrom",get:function(){return this.maxLength-String(this.from).length}},{key:"_update",value:function(e){e=Object.assign({to:this.to||0,from:this.from||0,maxLength:this.maxLength||0},e);var t=String(e.to).length;null!=e.maxLength&&(t=Math.max(t,e.maxLength)),e.maxLength=t;for(var i=String(e.from).padStart(t,"0"),s=String(e.to).padStart(t,"0"),r=0;r<s.length&&s[r]===i[r];)++r;e.mask=s.slice(0,r).replace(/0/g,"\\0")+"0".repeat(t-r),_get(_getPrototypeOf(n.prototype),"_update",this).call(this,e)}},{key:"isComplete",get:function(){return _get(_getPrototypeOf(n.prototype),"isComplete",this)&&Boolean(this.value)}},{key:"boundaries",value:function(e){var t="",n="",i=_slicedToArray(e.match(/^(\D*)(\d*)(\D*)/)||[],3),s=i[1],r=i[2];return r&&(t="0".repeat(s.length)+r,n="9".repeat(s.length)+r),[t=t.padEnd(this.maxLength,"0"),n=n.padEnd(this.maxLength,"9")]}},{key:"doPrepare",value:function(e){var t,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},s=normalizePrepare(_get(_getPrototypeOf(n.prototype),"doPrepare",this).call(this,e.replace(/\D/g,""),i)),r=_slicedToArray(s,2);if(e=r[0],t=r[1],!this.autofix||!e)return e;var o=String(this.from).padStart(this.maxLength,"0"),a=String(this.to).padStart(this.maxLength,"0"),l=this.value+e;if(l.length>this.maxLength)return"";var u=this.boundaries(l),c=_slicedToArray(u,2),h=c[0],d=c[1];return Number(d)<this.from?o[l.length-1]:Number(h)>this.to?"pad"===this.autofix&&l.length<this.maxLength?["",t.aggregate(this.append(o[l.length-1]+e,i))]:a[l.length-1]:e}},{key:"doValidate",value:function(){var e,t=this.value,i=t.search(/[^0]/);if(-1===i&&t.length<=this._matchFrom)return!0;for(var s=this.boundaries(t),r=_slicedToArray(s,2),o=r[0],a=r[1],l=arguments.length,u=new Array(l),c=0;c<l;c++)u[c]=arguments[c];return this.from<=Number(a)&&Number(o)<=this.to&&(e=_get(_getPrototypeOf(n.prototype),"doValidate",this)).call.apply(e,[this].concat(u))}}]),n}();IMask.MaskedRange=MaskedRange;var MaskedDate=function(e){_inherits(n,MaskedPattern);var t=_createSuper(n);function n(e){return _classCallCheck(this,n),t.call(this,Object.assign({},n.DEFAULTS,e))}return _createClass(n,[{key:"_update",value:function(e){e.mask===Date&&delete e.mask,e.pattern&&(e.mask=e.pattern);var t=e.blocks;e.blocks=Object.assign({},n.GET_DEFAULT_BLOCKS()),e.min&&(e.blocks.Y.from=e.min.getFullYear()),e.max&&(e.blocks.Y.to=e.max.getFullYear()),e.min&&e.max&&e.blocks.Y.from===e.blocks.Y.to&&(e.blocks.m.from=e.min.getMonth()+1,e.blocks.m.to=e.max.getMonth()+1,e.blocks.m.from===e.blocks.m.to&&(e.blocks.d.from=e.min.getDate(),e.blocks.d.to=e.max.getDate())),Object.assign(e.blocks,this.blocks,t),Object.keys(e.blocks).forEach((function(t){var n=e.blocks[t];!("autofix"in n)&&"autofix"in e&&(n.autofix=e.autofix)})),_get(_getPrototypeOf(n.prototype),"_update",this).call(this,e)}},{key:"doValidate",value:function(){for(var e,t=this.date,i=arguments.length,s=new Array(i),r=0;r<i;r++)s[r]=arguments[r];return(e=_get(_getPrototypeOf(n.prototype),"doValidate",this)).call.apply(e,[this].concat(s))&&(!this.isComplete||this.isDateExist(this.value)&&null!=t&&(null==this.min||this.min<=t)&&(null==this.max||t<=this.max))}},{key:"isDateExist",value:function(e){return this.format(this.parse(e,this),this).indexOf(e)>=0}},{key:"date",get:function(){return this.typedValue},set:function(e){this.typedValue=e}},{key:"typedValue",get:function(){return this.isComplete?_get(_getPrototypeOf(n.prototype),"typedValue",this):null},set:function(e){_set(_getPrototypeOf(n.prototype),"typedValue",e,this,!0)}},{key:"maskEquals",value:function(e){return e===Date||_get(_getPrototypeOf(n.prototype),"maskEquals",this).call(this,e)}}]),n}();MaskedDate.DEFAULTS={pattern:"d{.}`m{.}`Y",format:function(e){return e?[String(e.getDate()).padStart(2,"0"),String(e.getMonth()+1).padStart(2,"0"),e.getFullYear()].join("."):""},parse:function(e){var t=_slicedToArray(e.split("."),3),n=t[0],i=t[1],s=t[2];return new Date(s,i-1,n)}},MaskedDate.GET_DEFAULT_BLOCKS=function(){return{d:{mask:MaskedRange,from:1,to:31,maxLength:2},m:{mask:MaskedRange,from:1,to:12,maxLength:2},Y:{mask:MaskedRange,from:1900,to:9999}}},IMask.MaskedDate=MaskedDate;var MaskElement=function(){function e(){_classCallCheck(this,e)}return _createClass(e,[{key:"selectionStart",get:function(){var e;try{e=this._unsafeSelectionStart}catch(e){}return null!=e?e:this.value.length}},{key:"selectionEnd",get:function(){var e;try{e=this._unsafeSelectionEnd}catch(e){}return null!=e?e:this.value.length}},{key:"select",value:function(e,t){if(null!=e&&null!=t&&(e!==this.selectionStart||t!==this.selectionEnd))try{this._unsafeSelect(e,t)}catch(e){}}},{key:"_unsafeSelect",value:function(e,t){}},{key:"isActive",get:function(){return!1}},{key:"bindEvents",value:function(e){}},{key:"unbindEvents",value:function(){}}]),e}();IMask.MaskElement=MaskElement;var HTMLMaskElement=function(e){_inherits(n,MaskElement);var t=_createSuper(n);function n(e){var i;return _classCallCheck(this,n),(i=t.call(this)).input=e,i._handlers={},i}return _createClass(n,[{key:"rootElement",get:function(){var e,t,n;return null!==(e=null===(t=(n=this.input).getRootNode)||void 0===t?void 0:t.call(n))&&void 0!==e?e:document}},{key:"isActive",get:function(){return this.input===this.rootElement.activeElement}},{key:"_unsafeSelectionStart",get:function(){return this.input.selectionStart}},{key:"_unsafeSelectionEnd",get:function(){return this.input.selectionEnd}},{key:"_unsafeSelect",value:function(e,t){this.input.setSelectionRange(e,t)}},{key:"value",get:function(){return this.input.value},set:function(e){this.input.value=e}},{key:"bindEvents",value:function(e){var t=this;Object.keys(e).forEach((function(i){return t._toggleEventHandler(n.EVENTS_MAP[i],e[i])}))}},{key:"unbindEvents",value:function(){var e=this;Object.keys(this._handlers).forEach((function(t){return e._toggleEventHandler(t)}))}},{key:"_toggleEventHandler",value:function(e,t){this._handlers[e]&&(this.input.removeEventListener(e,this._handlers[e]),delete this._handlers[e]),t&&(this.input.addEventListener(e,t),this._handlers[e]=t)}}]),n}();HTMLMaskElement.EVENTS_MAP={selectionChange:"keydown",input:"input",drop:"drop",click:"click",focus:"focus",commit:"blur"},IMask.HTMLMaskElement=HTMLMaskElement;var HTMLContenteditableMaskElement=function(e){_inherits(n,HTMLMaskElement);var t=_createSuper(n);function n(){return _classCallCheck(this,n),t.apply(this,arguments)}return _createClass(n,[{key:"_unsafeSelectionStart",get:function(){var e=this.rootElement,t=e.getSelection&&e.getSelection(),n=t&&t.anchorOffset,i=t&&t.focusOffset;return null==i||null==n||n<i?n:i}},{key:"_unsafeSelectionEnd",get:function(){var e=this.rootElement,t=e.getSelection&&e.getSelection(),n=t&&t.anchorOffset,i=t&&t.focusOffset;return null==i||null==n||n>i?n:i}},{key:"_unsafeSelect",value:function(e,t){if(this.rootElement.createRange){var n=this.rootElement.createRange();n.setStart(this.input.firstChild||this.input,e),n.setEnd(this.input.lastChild||this.input,t);var i=this.rootElement,s=i.getSelection&&i.getSelection();s&&(s.removeAllRanges(),s.addRange(n))}}},{key:"value",get:function(){return this.input.textContent},set:function(e){this.input.textContent=e}}]),n}();IMask.HTMLContenteditableMaskElement=HTMLContenteditableMaskElement;var _excluded$1=["mask"],InputMask=function(){function e(t,n){_classCallCheck(this,e),this.el=t instanceof MaskElement?t:t.isContentEditable&&"INPUT"!==t.tagName&&"TEXTAREA"!==t.tagName?new HTMLContenteditableMaskElement(t):new HTMLMaskElement(t),this.masked=createMask(n),this._listeners={},this._value="",this._unmaskedValue="",this._saveSelection=this._saveSelection.bind(this),this._onInput=this._onInput.bind(this),this._onChange=this._onChange.bind(this),this._onDrop=this._onDrop.bind(this),this._onFocus=this._onFocus.bind(this),this._onClick=this._onClick.bind(this),this.alignCursor=this.alignCursor.bind(this),this.alignCursorFriendly=this.alignCursorFriendly.bind(this),this._bindEvents(),this.updateValue(),this._onChange()}return _createClass(e,[{key:"mask",get:function(){return this.masked.mask},set:function(e){if(!this.maskEquals(e))if(e instanceof IMask.Masked||this.masked.constructor!==maskedClass(e)){var t=createMask({mask:e});t.unmaskedValue=this.masked.unmaskedValue,this.masked=t}else this.masked.updateOptions({mask:e})}},{key:"maskEquals",value:function(e){var t;return null==e||(null===(t=this.masked)||void 0===t?void 0:t.maskEquals(e))}},{key:"value",get:function(){return this._value},set:function(e){this.value!==e&&(this.masked.value=e,this.updateControl(),this.alignCursor())}},{key:"unmaskedValue",get:function(){return this._unmaskedValue},set:function(e){this.unmaskedValue!==e&&(this.masked.unmaskedValue=e,this.updateControl(),this.alignCursor())}},{key:"typedValue",get:function(){return this.masked.typedValue},set:function(e){this.masked.typedValueEquals(e)||(this.masked.typedValue=e,this.updateControl(),this.alignCursor())}},{key:"_bindEvents",value:function(){this.el.bindEvents({selectionChange:this._saveSelection,input:this._onInput,drop:this._onDrop,click:this._onClick,focus:this._onFocus,commit:this._onChange})}},{key:"_unbindEvents",value:function(){this.el&&this.el.unbindEvents()}},{key:"_fireEvent",value:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];var s=this._listeners[e];s&&s.forEach((function(e){return e.apply(void 0,n)}))}},{key:"selectionStart",get:function(){return this._cursorChanging?this._changingCursorPos:this.el.selectionStart}},{key:"cursorPos",get:function(){return this._cursorChanging?this._changingCursorPos:this.el.selectionEnd},set:function(e){this.el&&this.el.isActive&&(this.el.select(e,e),this._saveSelection())}},{key:"_saveSelection",value:function(){this.value!==this.el.value&&console.warn("Element value was changed outside of mask. Syncronize mask using `mask.updateValue()` to work properly."),this._selection={start:this.selectionStart,end:this.cursorPos}}},{key:"updateValue",value:function(){this.masked.value=this.el.value,this._value=this.masked.value}},{key:"updateControl",value:function(){var e=this.masked.unmaskedValue,t=this.masked.value,n=this.unmaskedValue!==e||this.value!==t;this._unmaskedValue=e,this._value=t,this.el.value!==t&&(this.el.value=t),n&&this._fireChangeEvents()}},{key:"updateOptions",value:function(e){var t=e.mask,n=_objectWithoutProperties(e,_excluded$1),i=!this.maskEquals(t),s=!objectIncludes(this.masked,n);i&&(this.mask=t),s&&this.masked.updateOptions(n),(i||s)&&this.updateControl()}},{key:"updateCursor",value:function(e){null!=e&&(this.cursorPos=e,this._delayUpdateCursor(e))}},{key:"_delayUpdateCursor",value:function(e){var t=this;this._abortUpdateCursor(),this._changingCursorPos=e,this._cursorChanging=setTimeout((function(){t.el&&(t.cursorPos=t._changingCursorPos,t._abortUpdateCursor())}),10)}},{key:"_fireChangeEvents",value:function(){this._fireEvent("accept",this._inputEvent),this.masked.isComplete&&this._fireEvent("complete",this._inputEvent)}},{key:"_abortUpdateCursor",value:function(){this._cursorChanging&&(clearTimeout(this._cursorChanging),delete this._cursorChanging)}},{key:"alignCursor",value:function(){this.cursorPos=this.masked.nearestInputPos(this.masked.nearestInputPos(this.cursorPos,DIRECTION.LEFT))}},{key:"alignCursorFriendly",value:function(){this.selectionStart===this.cursorPos&&this.alignCursor()}},{key:"on",value:function(e,t){return this._listeners[e]||(this._listeners[e]=[]),this._listeners[e].push(t),this}},{key:"off",value:function(e,t){if(!this._listeners[e])return this;if(!t)return delete this._listeners[e],this;var n=this._listeners[e].indexOf(t);return n>=0&&this._listeners[e].splice(n,1),this}},{key:"_onInput",value:function(e){if(this._inputEvent=e,this._abortUpdateCursor(),!this._selection)return this.updateValue();var t=new ActionDetails(this.el.value,this.cursorPos,this.value,this._selection),n=this.masked.rawInputValue,i=this.masked.splice(t.startChangePos,t.removed.length,t.inserted,t.removeDirection,{input:!0,raw:!0}).offset,s=n===this.masked.rawInputValue?t.removeDirection:DIRECTION.NONE,r=this.masked.nearestInputPos(t.startChangePos+i,s);s!==DIRECTION.NONE&&(r=this.masked.nearestInputPos(r,DIRECTION.NONE)),this.updateControl(),this.updateCursor(r),delete this._inputEvent}},{key:"_onChange",value:function(){this.value!==this.el.value&&this.updateValue(),this.masked.doCommit(),this.updateControl(),this._saveSelection()}},{key:"_onDrop",value:function(e){e.preventDefault(),e.stopPropagation()}},{key:"_onFocus",value:function(e){this.alignCursorFriendly()}},{key:"_onClick",value:function(e){this.alignCursorFriendly()}},{key:"destroy",value:function(){this._unbindEvents(),this._listeners.length=0,delete this.el}}]),e}();IMask.InputMask=InputMask;var MaskedEnum=function(e){_inherits(n,MaskedPattern);var t=_createSuper(n);function n(){return _classCallCheck(this,n),t.apply(this,arguments)}return _createClass(n,[{key:"_update",value:function(e){e.enum&&(e.mask="*".repeat(e.enum[0].length)),_get(_getPrototypeOf(n.prototype),"_update",this).call(this,e)}},{key:"doValidate",value:function(){for(var e,t=this,i=arguments.length,s=new Array(i),r=0;r<i;r++)s[r]=arguments[r];return this.enum.some((function(e){return e.indexOf(t.unmaskedValue)>=0}))&&(e=_get(_getPrototypeOf(n.prototype),"doValidate",this)).call.apply(e,[this].concat(s))}}]),n}();IMask.MaskedEnum=MaskedEnum;var MaskedNumber=function(e){_inherits(n,Masked);var t=_createSuper(n);function n(e){return _classCallCheck(this,n),t.call(this,Object.assign({},n.DEFAULTS,e))}return _createClass(n,[{key:"_update",value:function(e){_get(_getPrototypeOf(n.prototype),"_update",this).call(this,e),this._updateRegExps()}},{key:"_updateRegExps",value:function(){var e="^"+(this.allowNegative?"[+|\\-]?":""),t=(this.scale?"("+escapeRegExp(this.radix)+"\\d{0,"+this.scale+"})?":"")+"$";this._numberRegExpInput=new RegExp(e+"(0|([1-9]+\\d*))?"+t),this._numberRegExp=new RegExp(e+"\\d*"+t),this._mapToRadixRegExp=new RegExp("["+this.mapToRadix.map(escapeRegExp).join("")+"]","g"),this._thousandsSeparatorRegExp=new RegExp(escapeRegExp(this.thousandsSeparator),"g")}},{key:"_removeThousandsSeparators",value:function(e){return e.replace(this._thousandsSeparatorRegExp,"")}},{key:"_insertThousandsSeparators",value:function(e){var t=e.split(this.radix);return t[0]=t[0].replace(/\B(?=(\d{3})+(?!\d))/g,this.thousandsSeparator),t.join(this.radix)}},{key:"doPrepare",value:function(e){var t;e=e.replace(this._mapToRadixRegExp,this.radix);for(var i=this._removeThousandsSeparators(e),s=arguments.length,r=new Array(s>1?s-1:0),o=1;o<s;o++)r[o-1]=arguments[o];var a=normalizePrepare((t=_get(_getPrototypeOf(n.prototype),"doPrepare",this)).call.apply(t,[this,i].concat(r))),l=_slicedToArray(a,2),u=l[0],c=l[1];return e&&!i&&(c.skip=!0),[u,c]}},{key:"_separatorsCount",value:function(e){for(var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=0,i=0;i<e;++i)this._value.indexOf(this.thousandsSeparator,i)===i&&(++n,t&&(e+=this.thousandsSeparator.length));return n}},{key:"_separatorsCountFromSlice",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this._value;return this._separatorsCount(this._removeThousandsSeparators(e).length,!0)}},{key:"extractInput",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.value.length,i=arguments.length>2?arguments[2]:void 0,s=this._adjustRangeWithSeparators(e,t),r=_slicedToArray(s,2);return e=r[0],t=r[1],this._removeThousandsSeparators(_get(_getPrototypeOf(n.prototype),"extractInput",this).call(this,e,t,i))}},{key:"_appendCharRaw",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!this.thousandsSeparator)return _get(_getPrototypeOf(n.prototype),"_appendCharRaw",this).call(this,e,t);var i=t.tail&&t._beforeTailState?t._beforeTailState._value:this._value,s=this._separatorsCountFromSlice(i);this._value=this._removeThousandsSeparators(this.value);var r=_get(_getPrototypeOf(n.prototype),"_appendCharRaw",this).call(this,e,t);this._value=this._insertThousandsSeparators(this._value);var o=t.tail&&t._beforeTailState?t._beforeTailState._value:this._value,a=this._separatorsCountFromSlice(o);return r.tailShift+=(a-s)*this.thousandsSeparator.length,r.skip=!r.rawInserted&&e===this.thousandsSeparator,r}},{key:"_findSeparatorAround",value:function(e){if(this.thousandsSeparator){var t=e-this.thousandsSeparator.length+1,n=this.value.indexOf(this.thousandsSeparator,t);if(n<=e)return n}return-1}},{key:"_adjustRangeWithSeparators",value:function(e,t){var n=this._findSeparatorAround(e);n>=0&&(e=n);var i=this._findSeparatorAround(t);return i>=0&&(t=i+this.thousandsSeparator.length),[e,t]}},{key:"remove",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.value.length,n=this._adjustRangeWithSeparators(e,t),i=_slicedToArray(n,2);e=i[0],t=i[1];var s=this.value.slice(0,e),r=this.value.slice(t),o=this._separatorsCount(s.length);this._value=this._insertThousandsSeparators(this._removeThousandsSeparators(s+r));var a=this._separatorsCountFromSlice(s);return new ChangeDetails({tailShift:(a-o)*this.thousandsSeparator.length})}},{key:"nearestInputPos",value:function(e,t){if(!this.thousandsSeparator)return e;switch(t){case DIRECTION.NONE:case DIRECTION.LEFT:case DIRECTION.FORCE_LEFT:var n=this._findSeparatorAround(e-1);if(n>=0){var i=n+this.thousandsSeparator.length;if(e<i||this.value.length<=i||t===DIRECTION.FORCE_LEFT)return n}break;case DIRECTION.RIGHT:case DIRECTION.FORCE_RIGHT:var s=this._findSeparatorAround(e);if(s>=0)return s+this.thousandsSeparator.length}return e}},{key:"doValidate",value:function(e){var t=(e.input?this._numberRegExpInput:this._numberRegExp).test(this._removeThousandsSeparators(this.value));if(t){var i=this.number;t=t&&!isNaN(i)&&(null==this.min||this.min>=0||this.min<=this.number)&&(null==this.max||this.max<=0||this.number<=this.max)}return t&&_get(_getPrototypeOf(n.prototype),"doValidate",this).call(this,e)}},{key:"doCommit",value:function(){if(this.value){var e=this.number,t=e;null!=this.min&&(t=Math.max(t,this.min)),null!=this.max&&(t=Math.min(t,this.max)),t!==e&&(this.unmaskedValue=String(t));var i=this.value;this.normalizeZeros&&(i=this._normalizeZeros(i)),this.padFractionalZeros&&this.scale>0&&(i=this._padFractionalZeros(i)),this._value=i}_get(_getPrototypeOf(n.prototype),"doCommit",this).call(this)}},{key:"_normalizeZeros",value:function(e){var t=this._removeThousandsSeparators(e).split(this.radix);return t[0]=t[0].replace(/^(\D*)(0*)(\d*)/,(function(e,t,n,i){return t+i})),e.length&&!/\d$/.test(t[0])&&(t[0]=t[0]+"0"),t.length>1&&(t[1]=t[1].replace(/0*$/,""),t[1].length||(t.length=1)),this._insertThousandsSeparators(t.join(this.radix))}},{key:"_padFractionalZeros",value:function(e){if(!e)return e;var t=e.split(this.radix);return t.length<2&&t.push(""),t[1]=t[1].padEnd(this.scale,"0"),t.join(this.radix)}},{key:"unmaskedValue",get:function(){return this._removeThousandsSeparators(this._normalizeZeros(this.value)).replace(this.radix,".")},set:function(e){_set(_getPrototypeOf(n.prototype),"unmaskedValue",e.replace(".",this.radix),this,!0)}},{key:"typedValue",get:function(){return Number(this.unmaskedValue)},set:function(e){_set(_getPrototypeOf(n.prototype),"unmaskedValue",String(e),this,!0)}},{key:"number",get:function(){return this.typedValue},set:function(e){this.typedValue=e}},{key:"allowNegative",get:function(){return this.signed||null!=this.min&&this.min<0||null!=this.max&&this.max<0}},{key:"typedValueEquals",value:function(e){return(_get(_getPrototypeOf(n.prototype),"typedValueEquals",this).call(this,e)||n.EMPTY_VALUES.includes(e)&&n.EMPTY_VALUES.includes(this.typedValue))&&!(0===e&&""===this.value)}}]),n}();MaskedNumber.DEFAULTS={radix:",",thousandsSeparator:"",mapToRadix:["."],scale:2,signed:!1,normalizeZeros:!0,padFractionalZeros:!1},MaskedNumber.EMPTY_VALUES=[].concat(_toConsumableArray(Masked.EMPTY_VALUES),[0]),IMask.MaskedNumber=MaskedNumber;var MaskedFunction=function(e){_inherits(n,Masked);var t=_createSuper(n);function n(){return _classCallCheck(this,n),t.apply(this,arguments)}return _createClass(n,[{key:"_update",value:function(e){e.mask&&(e.validate=e.mask),_get(_getPrototypeOf(n.prototype),"_update",this).call(this,e)}}]),n}();IMask.MaskedFunction=MaskedFunction;var _excluded=["compiledMasks","currentMaskRef","currentMask"],MaskedDynamic=function(e){_inherits(n,Masked);var t=_createSuper(n);function n(e){var i;return _classCallCheck(this,n),(i=t.call(this,Object.assign({},n.DEFAULTS,e))).currentMask=null,i}return _createClass(n,[{key:"_update",value:function(e){_get(_getPrototypeOf(n.prototype),"_update",this).call(this,e),"mask"in e&&(this.compiledMasks=Array.isArray(e.mask)?e.mask.map((function(e){return createMask(e)})):[])}},{key:"_appendCharRaw",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this._applyDispatch(e,t);return this.currentMask&&n.aggregate(this.currentMask._appendChar(e,this.currentMaskFlags(t))),n}},{key:"_applyDispatch",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.tail&&null!=t._beforeTailState?t._beforeTailState._value:this.value,i=this.rawInputValue,s=t.tail&&null!=t._beforeTailState?t._beforeTailState._rawInputValue:i,r=i.slice(s.length),o=this.currentMask,a=new ChangeDetails,l=null==o?void 0:o.state;if(this.currentMask=this.doDispatch(e,Object.assign({},t)),this.currentMask)if(this.currentMask!==o){if(this.currentMask.reset(),s){var u=this.currentMask.append(s,{raw:!0});a.tailShift=u.inserted.length-n.length}r&&(a.tailShift+=this.currentMask.append(r,{raw:!0,tail:!0}).tailShift)}else this.currentMask.state=l;return a}},{key:"_appendPlaceholder",value:function(){var e=this._applyDispatch.apply(this,arguments);return this.currentMask&&e.aggregate(this.currentMask._appendPlaceholder()),e}},{key:"_appendEager",value:function(){var e=this._applyDispatch.apply(this,arguments);return this.currentMask&&e.aggregate(this.currentMask._appendEager()),e}},{key:"currentMaskFlags",value:function(e){var t,n;return Object.assign({},e,{_beforeTailState:(null===(t=e._beforeTailState)||void 0===t?void 0:t.currentMaskRef)===this.currentMask&&(null===(n=e._beforeTailState)||void 0===n?void 0:n.currentMask)||e._beforeTailState})}},{key:"doDispatch",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.dispatch(e,this,t)}},{key:"doValidate",value:function(e){return _get(_getPrototypeOf(n.prototype),"doValidate",this).call(this,e)&&(!this.currentMask||this.currentMask.doValidate(this.currentMaskFlags(e)))}},{key:"doPrepare",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=normalizePrepare(_get(_getPrototypeOf(n.prototype),"doPrepare",this).call(this,e,t)),s=_slicedToArray(i,2),r=s[0],o=s[1];if(this.currentMask){var a,l=normalizePrepare(_get(_getPrototypeOf(n.prototype),"doPrepare",this).call(this,r,this.currentMaskFlags(t))),u=_slicedToArray(l,2);r=u[0],a=u[1],o=o.aggregate(a)}return[r,o]}},{key:"reset",value:function(){var e;null===(e=this.currentMask)||void 0===e||e.reset(),this.compiledMasks.forEach((function(e){return e.reset()}))}},{key:"value",get:function(){return this.currentMask?this.currentMask.value:""},set:function(e){_set(_getPrototypeOf(n.prototype),"value",e,this,!0)}},{key:"unmaskedValue",get:function(){return this.currentMask?this.currentMask.unmaskedValue:""},set:function(e){_set(_getPrototypeOf(n.prototype),"unmaskedValue",e,this,!0)}},{key:"typedValue",get:function(){return this.currentMask?this.currentMask.typedValue:""},set:function(e){var t=String(e);this.currentMask&&(this.currentMask.typedValue=e,t=this.currentMask.unmaskedValue),this.unmaskedValue=t}},{key:"isComplete",get:function(){var e;return Boolean(null===(e=this.currentMask)||void 0===e?void 0:e.isComplete)}},{key:"isFilled",get:function(){var e;return Boolean(null===(e=this.currentMask)||void 0===e?void 0:e.isFilled)}},{key:"remove",value:function(){var e,t=new ChangeDetails;this.currentMask&&t.aggregate((e=this.currentMask).remove.apply(e,arguments)).aggregate(this._applyDispatch());return t}},{key:"state",get:function(){var e;return Object.assign({},_get(_getPrototypeOf(n.prototype),"state",this),{_rawInputValue:this.rawInputValue,compiledMasks:this.compiledMasks.map((function(e){return e.state})),currentMaskRef:this.currentMask,currentMask:null===(e=this.currentMask)||void 0===e?void 0:e.state})},set:function(e){var t=e.compiledMasks,i=e.currentMaskRef,s=e.currentMask,r=_objectWithoutProperties(e,_excluded);this.compiledMasks.forEach((function(e,n){return e.state=t[n]})),null!=i&&(this.currentMask=i,this.currentMask.state=s),_set(_getPrototypeOf(n.prototype),"state",r,this,!0)}},{key:"extractInput",value:function(){var e;return this.currentMask?(e=this.currentMask).extractInput.apply(e,arguments):""}},{key:"extractTail",value:function(){for(var e,t,i=arguments.length,s=new Array(i),r=0;r<i;r++)s[r]=arguments[r];return this.currentMask?(e=this.currentMask).extractTail.apply(e,s):(t=_get(_getPrototypeOf(n.prototype),"extractTail",this)).call.apply(t,[this].concat(s))}},{key:"doCommit",value:function(){this.currentMask&&this.currentMask.doCommit(),_get(_getPrototypeOf(n.prototype),"doCommit",this).call(this)}},{key:"nearestInputPos",value:function(){for(var e,t,i=arguments.length,s=new Array(i),r=0;r<i;r++)s[r]=arguments[r];return this.currentMask?(e=this.currentMask).nearestInputPos.apply(e,s):(t=_get(_getPrototypeOf(n.prototype),"nearestInputPos",this)).call.apply(t,[this].concat(s))}},{key:"overwrite",get:function(){return this.currentMask?this.currentMask.overwrite:_get(_getPrototypeOf(n.prototype),"overwrite",this)},set:function(e){console.warn('"overwrite" option is not available in dynamic mask, use this option in siblings')}},{key:"eager",get:function(){return this.currentMask?this.currentMask.eager:_get(_getPrototypeOf(n.prototype),"eager",this)},set:function(e){console.warn('"eager" option is not available in dynamic mask, use this option in siblings')}},{key:"maskEquals",value:function(e){return Array.isArray(e)&&this.compiledMasks.every((function(t,n){var i;return t.maskEquals(null===(i=e[n])||void 0===i?void 0:i.mask)}))}},{key:"typedValueEquals",value:function(e){var t;return Boolean(null===(t=this.currentMask)||void 0===t?void 0:t.typedValueEquals(e))}}]),n}();MaskedDynamic.DEFAULTS={dispatch:function(e,t,n){if(t.compiledMasks.length){var i=t.rawInputValue,s=t.compiledMasks.map((function(s,r){return s.reset(),s.append(i,{raw:!0}),s.append(e,t.currentMaskFlags(n)),{weight:s.rawInputValue.length,index:r}}));return s.sort((function(e,t){return t.weight-e.weight})),t.compiledMasks[s[0].index]}}},IMask.MaskedDynamic=MaskedDynamic;var PIPE_TYPE={MASKED:"value",UNMASKED:"unmaskedValue",TYPED:"typedValue"};function createPipe(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:PIPE_TYPE.MASKED,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:PIPE_TYPE.MASKED,i=createMask(e);return function(e){return i.runIsolated((function(i){return i[t]=e,i[n]}))}}function pipe(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];return createPipe.apply(void 0,n)(e)}IMask.PIPE_TYPE=PIPE_TYPE,IMask.createPipe=createPipe,IMask.pipe=pipe;try{globalThis.IMask=IMask}catch(e){}var maskElementList=[].slice.call(document.querySelectorAll("[data-mask]"));maskElementList.map((function(e){return new IMask(e,{mask:e.dataset.mask,lazy:"true"===e.dataset["mask-visible"]})}));var top="top",bottom="bottom",right="right",left="left",auto="auto",basePlacements=[top,bottom,right,left],start="start",end="end",clippingParents="clippingParents",viewport="viewport",popper="popper",reference="reference",variationPlacements=basePlacements.reduce((function(e,t){return e.concat([t+"-"+start,t+"-"+end])}),[]),placements=[].concat(basePlacements,[auto]).reduce((function(e,t){return e.concat([t,t+"-"+start,t+"-"+end])}),[]),beforeRead="beforeRead",read="read",afterRead="afterRead",beforeMain="beforeMain",main="main",afterMain="afterMain",beforeWrite="beforeWrite",write="write",afterWrite="afterWrite",modifierPhases=[beforeRead,read,afterRead,beforeMain,main,afterMain,beforeWrite,write,afterWrite];function getNodeName(e){return e?(e.nodeName||"").toLowerCase():null}function getWindow(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function isElement$1(e){return e instanceof getWindow(e).Element||e instanceof Element}function isHTMLElement(e){return e instanceof getWindow(e).HTMLElement||e instanceof HTMLElement}function isShadowRoot(e){return"undefined"!=typeof ShadowRoot&&(e instanceof getWindow(e).ShadowRoot||e instanceof ShadowRoot)}function applyStyles(e){var t=e.state;Object.keys(t.elements).forEach((function(e){var n=t.styles[e]||{},i=t.attributes[e]||{},s=t.elements[e];isHTMLElement(s)&&getNodeName(s)&&(Object.assign(s.style,n),Object.keys(i).forEach((function(e){var t=i[e];!1===t?s.removeAttribute(e):s.setAttribute(e,!0===t?"":t)})))}))}function effect$2(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach((function(e){var i=t.elements[e],s=t.attributes[e]||{},r=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:n[e]).reduce((function(e,t){return e[t]="",e}),{});isHTMLElement(i)&&getNodeName(i)&&(Object.assign(i.style,r),Object.keys(s).forEach((function(e){i.removeAttribute(e)})))}))}}var applyStyles$1={name:"applyStyles",enabled:!0,phase:"write",fn:applyStyles,effect:effect$2,requires:["computeStyles"]};function getBasePlacement(e){return e.split("-")[0]}var max=Math.max,min=Math.min,round=Math.round;function getUAString(){var e=navigator.userAgentData;return null!=e&&e.brands?e.brands.map((function(e){return e.brand+"/"+e.version})).join(" "):navigator.userAgent}function isLayoutViewport(){return!/^((?!chrome|android).)*safari/i.test(getUAString())}function getBoundingClientRect(e,t,n){void 0===t&&(t=!1),void 0===n&&(n=!1);var i=e.getBoundingClientRect(),s=1,r=1;t&&isHTMLElement(e)&&(s=e.offsetWidth>0&&round(i.width)/e.offsetWidth||1,r=e.offsetHeight>0&&round(i.height)/e.offsetHeight||1);var o=(isElement$1(e)?getWindow(e):window).visualViewport,a=!isLayoutViewport()&&n,l=(i.left+(a&&o?o.offsetLeft:0))/s,u=(i.top+(a&&o?o.offsetTop:0))/r,c=i.width/s,h=i.height/r;return{width:c,height:h,top:u,right:l+c,bottom:u+h,left:l,x:l,y:u}}function getLayoutRect(e){var t=getBoundingClientRect(e),n=e.offsetWidth,i=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-i)<=1&&(i=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:i}}function contains(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&isShadowRoot(n)){var i=t;do{if(i&&e.isSameNode(i))return!0;i=i.parentNode||i.host}while(i)}return!1}function getComputedStyle$1(e){return getWindow(e).getComputedStyle(e)}function isTableElement(e){return["table","td","th"].indexOf(getNodeName(e))>=0}function getDocumentElement(e){return((isElement$1(e)?e.ownerDocument:e.document)||window.document).documentElement}function getParentNode(e){return"html"===getNodeName(e)?e:e.assignedSlot||e.parentNode||(isShadowRoot(e)?e.host:null)||getDocumentElement(e)}function getTrueOffsetParent(e){return isHTMLElement(e)&&"fixed"!==getComputedStyle$1(e).position?e.offsetParent:null}function getContainingBlock(e){var t=/firefox/i.test(getUAString());if(/Trident/i.test(getUAString())&&isHTMLElement(e)&&"fixed"===getComputedStyle$1(e).position)return null;var n=getParentNode(e);for(isShadowRoot(n)&&(n=n.host);isHTMLElement(n)&&["html","body"].indexOf(getNodeName(n))<0;){var i=getComputedStyle$1(n);if("none"!==i.transform||"none"!==i.perspective||"paint"===i.contain||-1!==["transform","perspective"].indexOf(i.willChange)||t&&"filter"===i.willChange||t&&i.filter&&"none"!==i.filter)return n;n=n.parentNode}return null}function getOffsetParent(e){for(var t=getWindow(e),n=getTrueOffsetParent(e);n&&isTableElement(n)&&"static"===getComputedStyle$1(n).position;)n=getTrueOffsetParent(n);return n&&("html"===getNodeName(n)||"body"===getNodeName(n)&&"static"===getComputedStyle$1(n).position)?t:n||getContainingBlock(e)||t}function getMainAxisFromPlacement(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function within(e,t,n){return max(e,min(t,n))}function withinMaxClamp(e,t,n){var i=within(e,t,n);return i>n?n:i}function getFreshSideObject(){return{top:0,right:0,bottom:0,left:0}}function mergePaddingObject(e){return Object.assign({},getFreshSideObject(),e)}function expandToHashMap(e,t){return t.reduce((function(t,n){return t[n]=e,t}),{})}var toPaddingObject=function(e,t){return mergePaddingObject("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:expandToHashMap(e,basePlacements))};function arrow(e){var t,n=e.state,i=e.name,s=e.options,r=n.elements.arrow,o=n.modifiersData.popperOffsets,a=getBasePlacement(n.placement),l=getMainAxisFromPlacement(a),u=[left,right].indexOf(a)>=0?"height":"width";if(r&&o){var c=toPaddingObject(s.padding,n),h=getLayoutRect(r),d="y"===l?top:left,p="y"===l?bottom:right,f=n.rects.reference[u]+n.rects.reference[l]-o[l]-n.rects.popper[u],g=o[l]-n.rects.reference[l],_=getOffsetParent(r),E=_?"y"===l?_.clientHeight||0:_.clientWidth||0:0,m=f/2-g/2,v=c[d],y=E-h[u]-c[p],T=E/2-h[u]/2+m,b=within(v,T,y),A=l;n.modifiersData[i]=((t={})[A]=b,t.centerOffset=b-T,t)}}function effect$1(e){var t=e.state,n=e.options.element,i=void 0===n?"[data-popper-arrow]":n;null!=i&&("string"!=typeof i||(i=t.elements.popper.querySelector(i)))&&contains(t.elements.popper,i)&&(t.elements.arrow=i)}var arrow$1={name:"arrow",enabled:!0,phase:"main",fn:arrow,effect:effect$1,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function getVariation(e){return e.split("-")[1]}var unsetSides={top:"auto",right:"auto",bottom:"auto",left:"auto"};function roundOffsetsByDPR(e){var t=e.x,n=e.y,i=window.devicePixelRatio||1;return{x:round(t*i)/i||0,y:round(n*i)/i||0}}function mapToStyles(e){var t,n=e.popper,i=e.popperRect,s=e.placement,r=e.variation,o=e.offsets,a=e.position,l=e.gpuAcceleration,u=e.adaptive,c=e.roundOffsets,h=e.isFixed,d=o.x,p=void 0===d?0:d,f=o.y,g=void 0===f?0:f,_="function"==typeof c?c({x:p,y:g}):{x:p,y:g};p=_.x,g=_.y;var E=o.hasOwnProperty("x"),m=o.hasOwnProperty("y"),v=left,y=top,T=window;if(u){var b=getOffsetParent(n),A="clientHeight",C="clientWidth";if(b===getWindow(n)&&"static"!==getComputedStyle$1(b=getDocumentElement(n)).position&&"absolute"===a&&(A="scrollHeight",C="scrollWidth"),s===top||(s===left||s===right)&&r===end)y=bottom,g-=(h&&b===T&&T.visualViewport?T.visualViewport.height:b[A])-i.height,g*=l?1:-1;if(s===left||(s===top||s===bottom)&&r===end)v=right,p-=(h&&b===T&&T.visualViewport?T.visualViewport.width:b[C])-i.width,p*=l?1:-1}var k,S=Object.assign({position:a},u&&unsetSides),O=!0===c?roundOffsetsByDPR({x:p,y:g}):{x:p,y:g};return p=O.x,g=O.y,l?Object.assign({},S,((k={})[y]=m?"0":"",k[v]=E?"0":"",k.transform=(T.devicePixelRatio||1)<=1?"translate("+p+"px, "+g+"px)":"translate3d("+p+"px, "+g+"px, 0)",k)):Object.assign({},S,((t={})[y]=m?g+"px":"",t[v]=E?p+"px":"",t.transform="",t))}function computeStyles(e){var t=e.state,n=e.options,i=n.gpuAcceleration,s=void 0===i||i,r=n.adaptive,o=void 0===r||r,a=n.roundOffsets,l=void 0===a||a,u={placement:getBasePlacement(t.placement),variation:getVariation(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:s,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,mapToStyles(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:o,roundOffsets:l})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,mapToStyles(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}var computeStyles$1={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:computeStyles,data:{}},passive={passive:!0};function effect(e){var t=e.state,n=e.instance,i=e.options,s=i.scroll,r=void 0===s||s,o=i.resize,a=void 0===o||o,l=getWindow(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return r&&u.forEach((function(e){e.addEventListener("scroll",n.update,passive)})),a&&l.addEventListener("resize",n.update,passive),function(){r&&u.forEach((function(e){e.removeEventListener("scroll",n.update,passive)})),a&&l.removeEventListener("resize",n.update,passive)}}var eventListeners={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:effect,data:{}},hash$1={left:"right",right:"left",bottom:"top",top:"bottom"};function getOppositePlacement(e){return e.replace(/left|right|bottom|top/g,(function(e){return hash$1[e]}))}var hash={start:"end",end:"start"};function getOppositeVariationPlacement(e){return e.replace(/start|end/g,(function(e){return hash[e]}))}function getWindowScroll(e){var t=getWindow(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function getWindowScrollBarX(e){return getBoundingClientRect(getDocumentElement(e)).left+getWindowScroll(e).scrollLeft}function getViewportRect(e,t){var n=getWindow(e),i=getDocumentElement(e),s=n.visualViewport,r=i.clientWidth,o=i.clientHeight,a=0,l=0;if(s){r=s.width,o=s.height;var u=isLayoutViewport();(u||!u&&"fixed"===t)&&(a=s.offsetLeft,l=s.offsetTop)}return{width:r,height:o,x:a+getWindowScrollBarX(e),y:l}}function getDocumentRect(e){var t,n=getDocumentElement(e),i=getWindowScroll(e),s=null==(t=e.ownerDocument)?void 0:t.body,r=max(n.scrollWidth,n.clientWidth,s?s.scrollWidth:0,s?s.clientWidth:0),o=max(n.scrollHeight,n.clientHeight,s?s.scrollHeight:0,s?s.clientHeight:0),a=-i.scrollLeft+getWindowScrollBarX(e),l=-i.scrollTop;return"rtl"===getComputedStyle$1(s||n).direction&&(a+=max(n.clientWidth,s?s.clientWidth:0)-r),{width:r,height:o,x:a,y:l}}function isScrollParent(e){var t=getComputedStyle$1(e),n=t.overflow,i=t.overflowX,s=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+s+i)}function getScrollParent(e){return["html","body","#document"].indexOf(getNodeName(e))>=0?e.ownerDocument.body:isHTMLElement(e)&&isScrollParent(e)?e:getScrollParent(getParentNode(e))}function listScrollParents(e,t){var n;void 0===t&&(t=[]);var i=getScrollParent(e),s=i===(null==(n=e.ownerDocument)?void 0:n.body),r=getWindow(i),o=s?[r].concat(r.visualViewport||[],isScrollParent(i)?i:[]):i,a=t.concat(o);return s?a:a.concat(listScrollParents(getParentNode(o)))}function rectToClientRect(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function getInnerBoundingClientRect(e,t){var n=getBoundingClientRect(e,!1,"fixed"===t);return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function getClientRectFromMixedType(e,t,n){return t===viewport?rectToClientRect(getViewportRect(e,n)):isElement$1(t)?getInnerBoundingClientRect(t,n):rectToClientRect(getDocumentRect(getDocumentElement(e)))}function getClippingParents(e){var t=listScrollParents(getParentNode(e)),n=["absolute","fixed"].indexOf(getComputedStyle$1(e).position)>=0&&isHTMLElement(e)?getOffsetParent(e):e;return isElement$1(n)?t.filter((function(e){return isElement$1(e)&&contains(e,n)&&"body"!==getNodeName(e)})):[]}function getClippingRect(e,t,n,i){var s="clippingParents"===t?getClippingParents(e):[].concat(t),r=[].concat(s,[n]),o=r[0],a=r.reduce((function(t,n){var s=getClientRectFromMixedType(e,n,i);return t.top=max(s.top,t.top),t.right=min(s.right,t.right),t.bottom=min(s.bottom,t.bottom),t.left=max(s.left,t.left),t}),getClientRectFromMixedType(e,o,i));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function computeOffsets(e){var t,n=e.reference,i=e.element,s=e.placement,r=s?getBasePlacement(s):null,o=s?getVariation(s):null,a=n.x+n.width/2-i.width/2,l=n.y+n.height/2-i.height/2;switch(r){case top:t={x:a,y:n.y-i.height};break;case bottom:t={x:a,y:n.y+n.height};break;case right:t={x:n.x+n.width,y:l};break;case left:t={x:n.x-i.width,y:l};break;default:t={x:n.x,y:n.y}}var u=r?getMainAxisFromPlacement(r):null;if(null!=u){var c="y"===u?"height":"width";switch(o){case start:t[u]=t[u]-(n[c]/2-i[c]/2);break;case end:t[u]=t[u]+(n[c]/2-i[c]/2)}}return t}function detectOverflow(e,t){void 0===t&&(t={});var n=t,i=n.placement,s=void 0===i?e.placement:i,r=n.strategy,o=void 0===r?e.strategy:r,a=n.boundary,l=void 0===a?clippingParents:a,u=n.rootBoundary,c=void 0===u?viewport:u,h=n.elementContext,d=void 0===h?popper:h,p=n.altBoundary,f=void 0!==p&&p,g=n.padding,_=void 0===g?0:g,E=mergePaddingObject("number"!=typeof _?_:expandToHashMap(_,basePlacements)),m=d===popper?reference:popper,v=e.rects.popper,y=e.elements[f?m:d],T=getClippingRect(isElement$1(y)?y:y.contextElement||getDocumentElement(e.elements.popper),l,c,o),b=getBoundingClientRect(e.elements.reference),A=computeOffsets({reference:b,element:v,strategy:"absolute",placement:s}),C=rectToClientRect(Object.assign({},v,A)),k=d===popper?C:b,S={top:T.top-k.top+E.top,bottom:k.bottom-T.bottom+E.bottom,left:T.left-k.left+E.left,right:k.right-T.right+E.right},O=e.modifiersData.offset;if(d===popper&&O){var D=O[s];Object.keys(S).forEach((function(e){var t=[right,bottom].indexOf(e)>=0?1:-1,n=[top,bottom].indexOf(e)>=0?"y":"x";S[e]+=D[n]*t}))}return S}function computeAutoPlacement(e,t){void 0===t&&(t={});var n=t,i=n.placement,s=n.boundary,r=n.rootBoundary,o=n.padding,a=n.flipVariations,l=n.allowedAutoPlacements,u=void 0===l?placements:l,c=getVariation(i),h=c?a?variationPlacements:variationPlacements.filter((function(e){return getVariation(e)===c})):basePlacements,d=h.filter((function(e){return u.indexOf(e)>=0}));0===d.length&&(d=h);var p=d.reduce((function(t,n){return t[n]=detectOverflow(e,{placement:n,boundary:s,rootBoundary:r,padding:o})[getBasePlacement(n)],t}),{});return Object.keys(p).sort((function(e,t){return p[e]-p[t]}))}function getExpandedFallbackPlacements(e){if(getBasePlacement(e)===auto)return[];var t=getOppositePlacement(e);return[getOppositeVariationPlacement(e),t,getOppositeVariationPlacement(t)]}function flip(e){var t=e.state,n=e.options,i=e.name;if(!t.modifiersData[i]._skip){for(var s=n.mainAxis,r=void 0===s||s,o=n.altAxis,a=void 0===o||o,l=n.fallbackPlacements,u=n.padding,c=n.boundary,h=n.rootBoundary,d=n.altBoundary,p=n.flipVariations,f=void 0===p||p,g=n.allowedAutoPlacements,_=t.options.placement,E=getBasePlacement(_),m=l||(E===_||!f?[getOppositePlacement(_)]:getExpandedFallbackPlacements(_)),v=[_].concat(m).reduce((function(e,n){return e.concat(getBasePlacement(n)===auto?computeAutoPlacement(t,{placement:n,boundary:c,rootBoundary:h,padding:u,flipVariations:f,allowedAutoPlacements:g}):n)}),[]),y=t.rects.reference,T=t.rects.popper,b=new Map,A=!0,C=v[0],k=0;k<v.length;k++){var S=v[k],O=getBasePlacement(S),D=getVariation(S)===start,w=[top,bottom].indexOf(O)>=0,N=w?"width":"height",I=detectOverflow(t,{placement:S,boundary:c,rootBoundary:h,altBoundary:d,padding:u}),L=w?D?right:left:D?bottom:top;y[N]>T[N]&&(L=getOppositePlacement(L));var M=getOppositePlacement(L),P=[];if(r&&P.push(I[O]<=0),a&&P.push(I[L]<=0,I[M]<=0),P.every((function(e){return e}))){C=S,A=!1;break}b.set(S,P)}if(A)for(var R=function(e){var t=v.find((function(t){var n=b.get(t);if(n)return n.slice(0,e).every((function(e){return e}))}));if(t)return C=t,"break"},F=f?3:1;F>0;F--){if("break"===R(F))break}t.placement!==C&&(t.modifiersData[i]._skip=!0,t.placement=C,t.reset=!0)}}var flip$1={name:"flip",enabled:!0,phase:"main",fn:flip,requiresIfExists:["offset"],data:{_skip:!1}};function getSideOffsets(e,t,n){return void 0===n&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function isAnySideFullyClipped(e){return[top,right,bottom,left].some((function(t){return e[t]>=0}))}function hide(e){var t=e.state,n=e.name,i=t.rects.reference,s=t.rects.popper,r=t.modifiersData.preventOverflow,o=detectOverflow(t,{elementContext:"reference"}),a=detectOverflow(t,{altBoundary:!0}),l=getSideOffsets(o,i),u=getSideOffsets(a,s,r),c=isAnySideFullyClipped(l),h=isAnySideFullyClipped(u);t.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:u,isReferenceHidden:c,hasPopperEscaped:h},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":c,"data-popper-escaped":h})}var hide$1={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:hide};function distanceAndSkiddingToXY(e,t,n){var i=getBasePlacement(e),s=[left,top].indexOf(i)>=0?-1:1,r="function"==typeof n?n(Object.assign({},t,{placement:e})):n,o=r[0],a=r[1];return o=o||0,a=(a||0)*s,[left,right].indexOf(i)>=0?{x:a,y:o}:{x:o,y:a}}function offset(e){var t=e.state,n=e.options,i=e.name,s=n.offset,r=void 0===s?[0,0]:s,o=placements.reduce((function(e,n){return e[n]=distanceAndSkiddingToXY(n,t.rects,r),e}),{}),a=o[t.placement],l=a.x,u=a.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=u),t.modifiersData[i]=o}var offset$1={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:offset};function popperOffsets(e){var t=e.state,n=e.name;t.modifiersData[n]=computeOffsets({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}var popperOffsets$1={name:"popperOffsets",enabled:!0,phase:"read",fn:popperOffsets,data:{}};function getAltAxis(e){return"x"===e?"y":"x"}function preventOverflow(e){var t=e.state,n=e.options,i=e.name,s=n.mainAxis,r=void 0===s||s,o=n.altAxis,a=void 0!==o&&o,l=n.boundary,u=n.rootBoundary,c=n.altBoundary,h=n.padding,d=n.tether,p=void 0===d||d,f=n.tetherOffset,g=void 0===f?0:f,_=detectOverflow(t,{boundary:l,rootBoundary:u,padding:h,altBoundary:c}),E=getBasePlacement(t.placement),m=getVariation(t.placement),v=!m,y=getMainAxisFromPlacement(E),T=getAltAxis(y),b=t.modifiersData.popperOffsets,A=t.rects.reference,C=t.rects.popper,k="function"==typeof g?g(Object.assign({},t.rects,{placement:t.placement})):g,S="number"==typeof k?{mainAxis:k,altAxis:k}:Object.assign({mainAxis:0,altAxis:0},k),O=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(b){if(r){var w,N="y"===y?top:left,I="y"===y?bottom:right,L="y"===y?"height":"width",M=b[y],P=M+_[N],R=M-_[I],F=p?-C[L]/2:0,x=m===start?A[L]:C[L],V=m===start?-C[L]:-A[L],$=t.elements.arrow,H=p&&$?getLayoutRect($):{width:0,height:0},B=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:getFreshSideObject(),j=B[N],W=B[I],U=within(0,A[L],H[L]),K=v?A[L]/2-F-U-j-S.mainAxis:x-U-j-S.mainAxis,Y=v?-A[L]/2+F+U+W+S.mainAxis:V+U+W+S.mainAxis,G=t.elements.arrow&&getOffsetParent(t.elements.arrow),z=G?"y"===y?G.clientTop||0:G.clientLeft||0:0,q=null!=(w=null==O?void 0:O[y])?w:0,X=M+Y-q,Q=within(p?min(P,M+K-q-z):P,M,p?max(R,X):R);b[y]=Q,D[y]=Q-M}if(a){var Z,J="x"===y?top:left,ee="x"===y?bottom:right,te=b[T],ne="y"===T?"height":"width",ie=te+_[J],se=te-_[ee],re=-1!==[top,left].indexOf(E),oe=null!=(Z=null==O?void 0:O[T])?Z:0,ae=re?ie:te-A[ne]-C[ne]-oe+S.altAxis,le=re?te+A[ne]+C[ne]-oe-S.altAxis:se,ue=p&&re?withinMaxClamp(ae,te,le):within(p?ae:ie,te,p?le:se);b[T]=ue,D[T]=ue-te}t.modifiersData[i]=D}}var preventOverflow$1={name:"preventOverflow",enabled:!0,phase:"main",fn:preventOverflow,requiresIfExists:["offset"]};function getHTMLElementScroll(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function getNodeScroll(e){return e!==getWindow(e)&&isHTMLElement(e)?getHTMLElementScroll(e):getWindowScroll(e)}function isElementScaled(e){var t=e.getBoundingClientRect(),n=round(t.width)/e.offsetWidth||1,i=round(t.height)/e.offsetHeight||1;return 1!==n||1!==i}function getCompositeRect(e,t,n){void 0===n&&(n=!1);var i=isHTMLElement(t),s=isHTMLElement(t)&&isElementScaled(t),r=getDocumentElement(t),o=getBoundingClientRect(e,s,n),a={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(i||!i&&!n)&&(("body"!==getNodeName(t)||isScrollParent(r))&&(a=getNodeScroll(t)),isHTMLElement(t)?((l=getBoundingClientRect(t,!0)).x+=t.clientLeft,l.y+=t.clientTop):r&&(l.x=getWindowScrollBarX(r))),{x:o.left+a.scrollLeft-l.x,y:o.top+a.scrollTop-l.y,width:o.width,height:o.height}}function order(e){var t=new Map,n=new Set,i=[];function s(e){n.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!n.has(e)){var i=t.get(e);i&&s(i)}})),i.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){n.has(e.name)||s(e)})),i}function orderModifiers(e){var t=order(e);return modifierPhases.reduce((function(e,n){return e.concat(t.filter((function(e){return e.phase===n})))}),[])}function debounce(e){var t;return function(){return t||(t=new Promise((function(n){Promise.resolve().then((function(){t=void 0,n(e())}))}))),t}}function mergeByName(e){var t=e.reduce((function(e,t){var n=e[t.name];return e[t.name]=n?Object.assign({},n,t,{options:Object.assign({},n.options,t.options),data:Object.assign({},n.data,t.data)}):t,e}),{});return Object.keys(t).map((function(e){return t[e]}))}var DEFAULT_OPTIONS={placement:"bottom",modifiers:[],strategy:"absolute"};function areValidElements(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some((function(e){return!(e&&"function"==typeof e.getBoundingClientRect)}))}function popperGenerator(e){void 0===e&&(e={});var t=e,n=t.defaultModifiers,i=void 0===n?[]:n,s=t.defaultOptions,r=void 0===s?DEFAULT_OPTIONS:s;return function(e,t,n){void 0===n&&(n=r);var s={placement:"bottom",orderedModifiers:[],options:Object.assign({},DEFAULT_OPTIONS,r),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},o=[],a=!1,l={state:s,setOptions:function(n){var a="function"==typeof n?n(s.options):n;u(),s.options=Object.assign({},r,s.options,a),s.scrollParents={reference:isElement$1(e)?listScrollParents(e):e.contextElement?listScrollParents(e.contextElement):[],popper:listScrollParents(t)};var c=orderModifiers(mergeByName([].concat(i,s.options.modifiers)));return s.orderedModifiers=c.filter((function(e){return e.enabled})),s.orderedModifiers.forEach((function(e){var t=e.name,n=e.options,i=void 0===n?{}:n,r=e.effect;if("function"==typeof r){var a=r({state:s,name:t,instance:l,options:i}),u=function(){};o.push(a||u)}})),l.update()},forceUpdate:function(){if(!a){var e=s.elements,t=e.reference,n=e.popper;if(areValidElements(t,n)){s.rects={reference:getCompositeRect(t,getOffsetParent(n),"fixed"===s.options.strategy),popper:getLayoutRect(n)},s.reset=!1,s.placement=s.options.placement,s.orderedModifiers.forEach((function(e){return s.modifiersData[e.name]=Object.assign({},e.data)}));for(var i=0;i<s.orderedModifiers.length;i++)if(!0!==s.reset){var r=s.orderedModifiers[i],o=r.fn,u=r.options,c=void 0===u?{}:u,h=r.name;"function"==typeof o&&(s=o({state:s,options:c,name:h,instance:l})||s)}else s.reset=!1,i=-1}}},update:debounce((function(){return new Promise((function(e){l.forceUpdate(),e(s)}))})),destroy:function(){u(),a=!0}};if(!areValidElements(e,t))return l;function u(){o.forEach((function(e){return e()})),o=[]}return l.setOptions(n).then((function(e){!a&&n.onFirstUpdate&&n.onFirstUpdate(e)})),l}}var createPopper$2=popperGenerator(),defaultModifiers$1=[eventListeners,popperOffsets$1,computeStyles$1,applyStyles$1],createPopper$1=popperGenerator({defaultModifiers:defaultModifiers$1}),defaultModifiers=[eventListeners,popperOffsets$1,computeStyles$1,applyStyles$1,offset$1,flip$1,preventOverflow$1,arrow$1,hide$1],createPopper=popperGenerator({defaultModifiers:defaultModifiers}),Popper=Object.freeze({__proto__:null,popperGenerator:popperGenerator,detectOverflow:detectOverflow,createPopperBase:createPopper$2,createPopper:createPopper,createPopperLite:createPopper$1,top:top,bottom:bottom,right:right,left:left,auto:auto,basePlacements:basePlacements,start:start,end:end,clippingParents:clippingParents,viewport:viewport,popper:popper,reference:reference,variationPlacements:variationPlacements,placements:placements,beforeRead:beforeRead,read:read,afterRead:afterRead,beforeMain:beforeMain,main:main,afterMain:afterMain,beforeWrite:beforeWrite,write:write,afterWrite:afterWrite,modifierPhases:modifierPhases,applyStyles:applyStyles$1,arrow:arrow$1,computeStyles:computeStyles$1,eventListeners:eventListeners,flip:flip$1,hide:hide$1,offset:offset$1,popperOffsets:popperOffsets$1,preventOverflow:preventOverflow$1});
- /*!
- * Bootstrap v5.2.2 (https://getbootstrap.com/)
- * Copyright 2011-2022 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
- * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
- */
- const MAX_UID=1e6,MILLISECONDS_MULTIPLIER=1e3,TRANSITION_END="transitionend",toType=e=>null==e?`${e}`:Object.prototype.toString.call(e).match(/\s([a-z]+)/i)[1].toLowerCase(),getUID=e=>{do{e+=Math.floor(1e6*Math.random())}while(document.getElementById(e));return e},getSelector=e=>{let t=e.getAttribute("data-bs-target");if(!t||"#"===t){let n=e.getAttribute("href");if(!n||!n.includes("#")&&!n.startsWith("."))return null;n.includes("#")&&!n.startsWith("#")&&(n=`#${n.split("#")[1]}`),t=n&&"#"!==n?n.trim():null}return t},getSelectorFromElement=e=>{const t=getSelector(e);return t&&document.querySelector(t)?t:null},getElementFromSelector=e=>{const t=getSelector(e);return t?document.querySelector(t):null},getTransitionDurationFromElement=e=>{if(!e)return 0;let{transitionDuration:t,transitionDelay:n}=window.getComputedStyle(e);const i=Number.parseFloat(t),s=Number.parseFloat(n);return i||s?(t=t.split(",")[0],n=n.split(",")[0],1e3*(Number.parseFloat(t)+Number.parseFloat(n))):0},triggerTransitionEnd=e=>{e.dispatchEvent(new Event(TRANSITION_END))},isElement=e=>!(!e||"object"!=typeof e)&&(void 0!==e.jquery&&(e=e[0]),void 0!==e.nodeType),getElement=e=>isElement(e)?e.jquery?e[0]:e:"string"==typeof e&&e.length>0?document.querySelector(e):null,isVisible=e=>{if(!isElement(e)||0===e.getClientRects().length)return!1;const t="visible"===getComputedStyle(e).getPropertyValue("visibility"),n=e.closest("details:not([open])");if(!n)return t;if(n!==e){const t=e.closest("summary");if(t&&t.parentNode!==n)return!1;if(null===t)return!1}return t},isDisabled=e=>!e||e.nodeType!==Node.ELEMENT_NODE||(!!e.classList.contains("disabled")||(void 0!==e.disabled?e.disabled:e.hasAttribute("disabled")&&"false"!==e.getAttribute("disabled"))),findShadowRoot=e=>{if(!document.documentElement.attachShadow)return null;if("function"==typeof e.getRootNode){const t=e.getRootNode();return t instanceof ShadowRoot?t:null}return e instanceof ShadowRoot?e:e.parentNode?findShadowRoot(e.parentNode):null},noop=()=>{},reflow=e=>{e.offsetHeight},getjQuery=()=>window.jQuery&&!document.body.hasAttribute("data-bs-no-jquery")?window.jQuery:null,DOMContentLoadedCallbacks=[],onDOMContentLoaded=e=>{"loading"===document.readyState?(DOMContentLoadedCallbacks.length||document.addEventListener("DOMContentLoaded",(()=>{for(const e of DOMContentLoadedCallbacks)e()})),DOMContentLoadedCallbacks.push(e)):e()},isRTL=()=>"rtl"===document.documentElement.dir,defineJQueryPlugin=e=>{var t;t=()=>{const t=getjQuery();if(t){const n=e.NAME,i=t.fn[n];t.fn[n]=e.jQueryInterface,t.fn[n].Constructor=e,t.fn[n].noConflict=()=>(t.fn[n]=i,e.jQueryInterface)}},"loading"===document.readyState?(DOMContentLoadedCallbacks.length||document.addEventListener("DOMContentLoaded",(()=>{for(const e of DOMContentLoadedCallbacks)e()})),DOMContentLoadedCallbacks.push(t)):t()},execute=e=>{"function"==typeof e&&e()},executeAfterTransition=(e,t,n=!0)=>{if(!n)return void execute(e);const i=getTransitionDurationFromElement(t)+5;let s=!1;const r=({target:n})=>{n===t&&(s=!0,t.removeEventListener(TRANSITION_END,r),execute(e))};t.addEventListener(TRANSITION_END,r),setTimeout((()=>{s||triggerTransitionEnd(t)}),i)},getNextActiveElement=(e,t,n,i)=>{const s=e.length;let r=e.indexOf(t);return-1===r?!n&&i?e[s-1]:e[0]:(r+=n?1:-1,i&&(r=(r+s)%s),e[Math.max(0,Math.min(r,s-1))])},namespaceRegex=/[^.]*(?=\..*)\.|.*/,stripNameRegex=/\..*/,stripUidRegex=/::\d+$/,eventRegistry={};let uidEvent=1;const customEvents={mouseenter:"mouseover",mouseleave:"mouseout"},nativeEvents=new Set(["click","dblclick","mouseup","mousedown","contextmenu","mousewheel","DOMMouseScroll","mouseover","mouseout","mousemove","selectstart","selectend","keydown","keypress","keyup","orientationchange","touchstart","touchmove","touchend","touchcancel","pointerdown","pointermove","pointerup","pointerleave","pointercancel","gesturestart","gesturechange","gestureend","focus","blur","change","reset","select","submit","focusin","focusout","load","unload","beforeunload","resize","move","DOMContentLoaded","readystatechange","error","abort","scroll"]);function makeEventUid(e,t){return t&&`${t}::${uidEvent++}`||e.uidEvent||uidEvent++}function getElementEvents(e){const t=makeEventUid(e);return e.uidEvent=t,eventRegistry[t]=eventRegistry[t]||{},eventRegistry[t]}function bootstrapHandler(e,t){return function n(i){return hydrateObj(i,{delegateTarget:e}),n.oneOff&&EventHandler.off(e,i.type,t),t.apply(e,[i])}}function bootstrapDelegationHandler(e,t,n){return function i(s){const r=e.querySelectorAll(t);for(let{target:o}=s;o&&o!==this;o=o.parentNode)for(const a of r)if(a===o)return hydrateObj(s,{delegateTarget:o}),i.oneOff&&EventHandler.off(e,s.type,t,n),n.apply(o,[s])}}function findHandler(e,t,n=null){return Object.values(e).find((e=>e.callable===t&&e.delegationSelector===n))}function normalizeParameters(e,t,n){const i="string"==typeof t,s=i?n:t||n;let r=getTypeEvent(e);return nativeEvents.has(r)||(r=e),[i,s,r]}function addHandler(e,t,n,i,s){if("string"!=typeof t||!e)return;let[r,o,a]=normalizeParameters(t,n,i);if(t in customEvents){const e=e=>function(t){if(!t.relatedTarget||t.relatedTarget!==t.delegateTarget&&!t.delegateTarget.contains(t.relatedTarget))return e.call(this,t)};o=e(o)}const l=getElementEvents(e),u=l[a]||(l[a]={}),c=findHandler(u,o,r?n:null);if(c)return void(c.oneOff=c.oneOff&&s);const h=makeEventUid(o,t.replace(namespaceRegex,"")),d=r?bootstrapDelegationHandler(e,n,o):bootstrapHandler(e,o);d.delegationSelector=r?n:null,d.callable=o,d.oneOff=s,d.uidEvent=h,u[h]=d,e.addEventListener(a,d,r)}function removeHandler(e,t,n,i,s){const r=findHandler(t[n],i,s);r&&(e.removeEventListener(n,r,Boolean(s)),delete t[n][r.uidEvent])}function removeNamespacedHandlers(e,t,n,i){const s=t[n]||{};for(const r of Object.keys(s))if(r.includes(i)){const i=s[r];removeHandler(e,t,n,i.callable,i.delegationSelector)}}function getTypeEvent(e){return e=e.replace(stripNameRegex,""),customEvents[e]||e}const EventHandler={on(e,t,n,i){addHandler(e,t,n,i,!1)},one(e,t,n,i){addHandler(e,t,n,i,!0)},off(e,t,n,i){if("string"!=typeof t||!e)return;const[s,r,o]=normalizeParameters(t,n,i),a=o!==t,l=getElementEvents(e),u=l[o]||{},c=t.startsWith(".");if(void 0===r){if(c)for(const n of Object.keys(l))removeNamespacedHandlers(e,l,n,t.slice(1));for(const n of Object.keys(u)){const i=n.replace(stripUidRegex,"");if(!a||t.includes(i)){const t=u[n];removeHandler(e,l,o,t.callable,t.delegationSelector)}}}else{if(!Object.keys(u).length)return;removeHandler(e,l,o,r,s?n:null)}},trigger(e,t,n){if("string"!=typeof t||!e)return null;const i=getjQuery();let s=null,r=!0,o=!0,a=!1;t!==getTypeEvent(t)&&i&&(s=i.Event(t,n),i(e).trigger(s),r=!s.isPropagationStopped(),o=!s.isImmediatePropagationStopped(),a=s.isDefaultPrevented());let l=new Event(t,{bubbles:r,cancelable:!0});return l=hydrateObj(l,n),a&&l.preventDefault(),o&&e.dispatchEvent(l),l.defaultPrevented&&s&&s.preventDefault(),l}};function hydrateObj(e,t){for(const[n,i]of Object.entries(t||{}))try{e[n]=i}catch(t){Object.defineProperty(e,n,{configurable:!0,get:()=>i})}return e}const elementMap=new Map,Data={set(e,t,n){elementMap.has(e)||elementMap.set(e,new Map);const i=elementMap.get(e);i.has(t)||0===i.size?i.set(t,n):console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(i.keys())[0]}.`)},get:(e,t)=>elementMap.has(e)&&elementMap.get(e).get(t)||null,remove(e,t){if(!elementMap.has(e))return;const n=elementMap.get(e);n.delete(t),0===n.size&&elementMap.delete(e)}};function normalizeData(e){if("true"===e)return!0;if("false"===e)return!1;if(e===Number(e).toString())return Number(e);if(""===e||"null"===e)return null;if("string"!=typeof e)return e;try{return JSON.parse(decodeURIComponent(e))}catch(t){return e}}function normalizeDataKey(e){return e.replace(/[A-Z]/g,(e=>`-${e.toLowerCase()}`))}const Manipulator={setDataAttribute(e,t,n){e.setAttribute(`data-bs-${normalizeDataKey(t)}`,n)},removeDataAttribute(e,t){e.removeAttribute(`data-bs-${normalizeDataKey(t)}`)},getDataAttributes(e){if(!e)return{};const t={},n=Object.keys(e.dataset).filter((e=>e.startsWith("bs")&&!e.startsWith("bsConfig")));for(const i of n){let n=i.replace(/^bs/,"");n=n.charAt(0).toLowerCase()+n.slice(1,n.length),t[n]=normalizeData(e.dataset[i])}return t},getDataAttribute:(e,t)=>normalizeData(e.getAttribute(`data-bs-${normalizeDataKey(t)}`))};class Config{static get Default(){return{}}static get DefaultType(){return{}}static get NAME(){throw new Error('You have to implement the static method "NAME", for each component!')}_getConfig(e){return e=this._mergeConfigObj(e),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}_configAfterMerge(e){return e}_mergeConfigObj(e,t){const n=isElement(t)?Manipulator.getDataAttribute(t,"config"):{};return{...this.constructor.Default,..."object"==typeof n?n:{},...isElement(t)?Manipulator.getDataAttributes(t):{},..."object"==typeof e?e:{}}}_typeCheckConfig(e,t=this.constructor.DefaultType){for(const i of Object.keys(t)){const s=t[i],r=e[i],o=isElement(r)?"element":null==(n=r)?`${n}`:Object.prototype.toString.call(n).match(/\s([a-z]+)/i)[1].toLowerCase();if(!new RegExp(s).test(o))throw new TypeError(`${this.constructor.NAME.toUpperCase()}: Option "${i}" provided type "${o}" but expected type "${s}".`)}var n}}const VERSION="5.2.2";class BaseComponent extends Config{constructor(e,t){super(),(e=getElement(e))&&(this._element=e,this._config=this._getConfig(t),Data.set(this._element,this.constructor.DATA_KEY,this))}dispose(){Data.remove(this._element,this.constructor.DATA_KEY),EventHandler.off(this._element,this.constructor.EVENT_KEY);for(const e of Object.getOwnPropertyNames(this))this[e]=null}_queueCallback(e,t,n=!0){executeAfterTransition(e,t,n)}_getConfig(e){return e=this._mergeConfigObj(e,this._element),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}static getInstance(e){return Data.get(getElement(e),this.DATA_KEY)}static getOrCreateInstance(e,t={}){return this.getInstance(e)||new this(e,"object"==typeof t?t:null)}static get VERSION(){return"5.2.2"}static get DATA_KEY(){return`bs.${this.NAME}`}static get EVENT_KEY(){return`.${this.DATA_KEY}`}static eventName(e){return`${e}${this.EVENT_KEY}`}}const enableDismissTrigger=(e,t="hide")=>{const n=`click.dismiss${e.EVENT_KEY}`,i=e.NAME;EventHandler.on(document,n,`[data-bs-dismiss="${i}"]`,(function(n){if(["A","AREA"].includes(this.tagName)&&n.preventDefault(),isDisabled(this))return;const s=getElementFromSelector(this)||this.closest(`.${i}`);e.getOrCreateInstance(s)[t]()}))},NAME$f="alert",DATA_KEY$a="bs.alert",EVENT_KEY$b=".bs.alert",EVENT_CLOSE="close.bs.alert",EVENT_CLOSED="closed.bs.alert",CLASS_NAME_FADE$5="fade",CLASS_NAME_SHOW$8="show";class Alert extends BaseComponent{static get NAME(){return NAME$f}close(){if(EventHandler.trigger(this._element,EVENT_CLOSE).defaultPrevented)return;this._element.classList.remove("show");const e=this._element.classList.contains("fade");this._queueCallback((()=>this._destroyElement()),this._element,e)}_destroyElement(){this._element.remove(),EventHandler.trigger(this._element,EVENT_CLOSED),this.dispose()}static jQueryInterface(e){return this.each((function(){const t=Alert.getOrCreateInstance(this);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}enableDismissTrigger(Alert,"close"),defineJQueryPlugin(Alert);const NAME$e="button",DATA_KEY$9="bs.button",EVENT_KEY$a=".bs.button",DATA_API_KEY$6=".data-api",CLASS_NAME_ACTIVE$3="active",SELECTOR_DATA_TOGGLE$5='[data-bs-toggle="button"]',EVENT_CLICK_DATA_API$6="click.bs.button.data-api";class Button extends BaseComponent{static get NAME(){return NAME$e}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle("active"))}static jQueryInterface(e){return this.each((function(){const t=Button.getOrCreateInstance(this);"toggle"===e&&t[e]()}))}}EventHandler.on(document,EVENT_CLICK_DATA_API$6,SELECTOR_DATA_TOGGLE$5,(e=>{e.preventDefault();const t=e.target.closest(SELECTOR_DATA_TOGGLE$5);Button.getOrCreateInstance(t).toggle()})),defineJQueryPlugin(Button);const SelectorEngine={find:(e,t=document.documentElement)=>[].concat(...Element.prototype.querySelectorAll.call(t,e)),findOne:(e,t=document.documentElement)=>Element.prototype.querySelector.call(t,e),children:(e,t)=>[].concat(...e.children).filter((e=>e.matches(t))),parents(e,t){const n=[];let i=e.parentNode.closest(t);for(;i;)n.push(i),i=i.parentNode.closest(t);return n},prev(e,t){let n=e.previousElementSibling;for(;n;){if(n.matches(t))return[n];n=n.previousElementSibling}return[]},next(e,t){let n=e.nextElementSibling;for(;n;){if(n.matches(t))return[n];n=n.nextElementSibling}return[]},focusableChildren(e){const t=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map((e=>`${e}:not([tabindex^="-"])`)).join(",");return this.find(t,e).filter((e=>!isDisabled(e)&&isVisible(e)))}},NAME$d="swipe",EVENT_KEY$9=".bs.swipe",EVENT_TOUCHSTART="touchstart.bs.swipe",EVENT_TOUCHMOVE="touchmove.bs.swipe",EVENT_TOUCHEND="touchend.bs.swipe",EVENT_POINTERDOWN="pointerdown.bs.swipe",EVENT_POINTERUP="pointerup.bs.swipe",POINTER_TYPE_TOUCH="touch",POINTER_TYPE_PEN="pen",CLASS_NAME_POINTER_EVENT="pointer-event",SWIPE_THRESHOLD=40,Default$c={endCallback:null,leftCallback:null,rightCallback:null},DefaultType$c={endCallback:"(function|null)",leftCallback:"(function|null)",rightCallback:"(function|null)"};class Swipe extends Config{constructor(e,t){super(),this._element=e,e&&Swipe.isSupported()&&(this._config=this._getConfig(t),this._deltaX=0,this._supportPointerEvents=Boolean(window.PointerEvent),this._initEvents())}static get Default(){return Default$c}static get DefaultType(){return DefaultType$c}static get NAME(){return NAME$d}dispose(){EventHandler.off(this._element,".bs.swipe")}_start(e){this._supportPointerEvents?this._eventIsPointerPenTouch(e)&&(this._deltaX=e.clientX):this._deltaX=e.touches[0].clientX}_end(e){this._eventIsPointerPenTouch(e)&&(this._deltaX=e.clientX-this._deltaX),this._handleSwipe(),execute(this._config.endCallback)}_move(e){this._deltaX=e.touches&&e.touches.length>1?0:e.touches[0].clientX-this._deltaX}_handleSwipe(){const e=Math.abs(this._deltaX);if(e<=40)return;const t=e/this._deltaX;this._deltaX=0,t&&execute(t>0?this._config.rightCallback:this._config.leftCallback)}_initEvents(){this._supportPointerEvents?(EventHandler.on(this._element,EVENT_POINTERDOWN,(e=>this._start(e))),EventHandler.on(this._element,EVENT_POINTERUP,(e=>this._end(e))),this._element.classList.add("pointer-event")):(EventHandler.on(this._element,EVENT_TOUCHSTART,(e=>this._start(e))),EventHandler.on(this._element,EVENT_TOUCHMOVE,(e=>this._move(e))),EventHandler.on(this._element,EVENT_TOUCHEND,(e=>this._end(e))))}_eventIsPointerPenTouch(e){return this._supportPointerEvents&&("pen"===e.pointerType||"touch"===e.pointerType)}static isSupported(){return"ontouchstart"in document.documentElement||navigator.maxTouchPoints>0}}const NAME$c="carousel",DATA_KEY$8="bs.carousel",EVENT_KEY$8=".bs.carousel",DATA_API_KEY$5=".data-api",ARROW_LEFT_KEY$1="ArrowLeft",ARROW_RIGHT_KEY$1="ArrowRight",TOUCHEVENT_COMPAT_WAIT=500,ORDER_NEXT="next",ORDER_PREV="prev",DIRECTION_LEFT="left",DIRECTION_RIGHT="right",EVENT_SLIDE="slide.bs.carousel",EVENT_SLID="slid.bs.carousel",EVENT_KEYDOWN$1="keydown.bs.carousel",EVENT_MOUSEENTER$1="mouseenter.bs.carousel",EVENT_MOUSELEAVE$1="mouseleave.bs.carousel",EVENT_DRAG_START="dragstart.bs.carousel",EVENT_LOAD_DATA_API$3="load.bs.carousel.data-api",EVENT_CLICK_DATA_API$5="click.bs.carousel.data-api",CLASS_NAME_CAROUSEL="carousel",CLASS_NAME_ACTIVE$2="active",CLASS_NAME_SLIDE="slide",CLASS_NAME_END="carousel-item-end",CLASS_NAME_START="carousel-item-start",CLASS_NAME_NEXT="carousel-item-next",CLASS_NAME_PREV="carousel-item-prev",SELECTOR_ACTIVE=".active",SELECTOR_ITEM=".carousel-item",SELECTOR_ACTIVE_ITEM=".active.carousel-item",SELECTOR_ITEM_IMG=".carousel-item img",SELECTOR_INDICATORS=".carousel-indicators",SELECTOR_DATA_SLIDE="[data-bs-slide], [data-bs-slide-to]",SELECTOR_DATA_RIDE='[data-bs-ride="carousel"]',KEY_TO_DIRECTION={ArrowLeft:"right",ArrowRight:"left"},Default$b={interval:5e3,keyboard:!0,pause:"hover",ride:!1,touch:!0,wrap:!0},DefaultType$b={interval:"(number|boolean)",keyboard:"boolean",pause:"(string|boolean)",ride:"(boolean|string)",touch:"boolean",wrap:"boolean"};class Carousel extends BaseComponent{constructor(e,t){super(e,t),this._interval=null,this._activeElement=null,this._isSliding=!1,this.touchTimeout=null,this._swipeHelper=null,this._indicatorsElement=SelectorEngine.findOne(SELECTOR_INDICATORS,this._element),this._addEventListeners(),"carousel"===this._config.ride&&this.cycle()}static get Default(){return Default$b}static get DefaultType(){return DefaultType$b}static get NAME(){return NAME$c}next(){this._slide("next")}nextWhenVisible(){!document.hidden&&isVisible(this._element)&&this.next()}prev(){this._slide("prev")}pause(){this._isSliding&&triggerTransitionEnd(this._element),this._clearInterval()}cycle(){this._clearInterval(),this._updateInterval(),this._interval=setInterval((()=>this.nextWhenVisible()),this._config.interval)}_maybeEnableCycle(){this._config.ride&&(this._isSliding?EventHandler.one(this._element,EVENT_SLID,(()=>this.cycle())):this.cycle())}to(e){const t=this._getItems();if(e>t.length-1||e<0)return;if(this._isSliding)return void EventHandler.one(this._element,EVENT_SLID,(()=>this.to(e)));const n=this._getItemIndex(this._getActive());if(n===e)return;const i=e>n?"next":"prev";this._slide(i,t[e])}dispose(){this._swipeHelper&&this._swipeHelper.dispose(),super.dispose()}_configAfterMerge(e){return e.defaultInterval=e.interval,e}_addEventListeners(){this._config.keyboard&&EventHandler.on(this._element,EVENT_KEYDOWN$1,(e=>this._keydown(e))),"hover"===this._config.pause&&(EventHandler.on(this._element,EVENT_MOUSEENTER$1,(()=>this.pause())),EventHandler.on(this._element,EVENT_MOUSELEAVE$1,(()=>this._maybeEnableCycle()))),this._config.touch&&Swipe.isSupported()&&this._addTouchEventListeners()}_addTouchEventListeners(){for(const e of SelectorEngine.find(SELECTOR_ITEM_IMG,this._element))EventHandler.on(e,EVENT_DRAG_START,(e=>e.preventDefault()));const e={leftCallback:()=>this._slide(this._directionToOrder("left")),rightCallback:()=>this._slide(this._directionToOrder("right")),endCallback:()=>{"hover"===this._config.pause&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout((()=>this._maybeEnableCycle()),500+this._config.interval))}};this._swipeHelper=new Swipe(this._element,e)}_keydown(e){if(/input|textarea/i.test(e.target.tagName))return;const t=KEY_TO_DIRECTION[e.key];t&&(e.preventDefault(),this._slide(this._directionToOrder(t)))}_getItemIndex(e){return this._getItems().indexOf(e)}_setActiveIndicatorElement(e){if(!this._indicatorsElement)return;const t=SelectorEngine.findOne(".active",this._indicatorsElement);t.classList.remove("active"),t.removeAttribute("aria-current");const n=SelectorEngine.findOne(`[data-bs-slide-to="${e}"]`,this._indicatorsElement);n&&(n.classList.add("active"),n.setAttribute("aria-current","true"))}_updateInterval(){const e=this._activeElement||this._getActive();if(!e)return;const t=Number.parseInt(e.getAttribute("data-bs-interval"),10);this._config.interval=t||this._config.defaultInterval}_slide(e,t=null){if(this._isSliding)return;const n=this._getActive(),i="next"===e,s=t||getNextActiveElement(this._getItems(),n,i,this._config.wrap);if(s===n)return;const r=this._getItemIndex(s),o=t=>EventHandler.trigger(this._element,t,{relatedTarget:s,direction:this._orderToDirection(e),from:this._getItemIndex(n),to:r});if(o(EVENT_SLIDE).defaultPrevented)return;if(!n||!s)return;const a=Boolean(this._interval);this.pause(),this._isSliding=!0,this._setActiveIndicatorElement(r),this._activeElement=s;const l=i?CLASS_NAME_START:CLASS_NAME_END,u=i?CLASS_NAME_NEXT:CLASS_NAME_PREV;s.classList.add(u),reflow(s),n.classList.add(l),s.classList.add(l);this._queueCallback((()=>{s.classList.remove(l,u),s.classList.add("active"),n.classList.remove("active",u,l),this._isSliding=!1,o(EVENT_SLID)}),n,this._isAnimated()),a&&this.cycle()}_isAnimated(){return this._element.classList.contains("slide")}_getActive(){return SelectorEngine.findOne(SELECTOR_ACTIVE_ITEM,this._element)}_getItems(){return SelectorEngine.find(SELECTOR_ITEM,this._element)}_clearInterval(){this._interval&&(clearInterval(this._interval),this._interval=null)}_directionToOrder(e){return isRTL()?"left"===e?"prev":"next":"left"===e?"next":"prev"}_orderToDirection(e){return isRTL()?"prev"===e?"left":"right":"prev"===e?"right":"left"}static jQueryInterface(e){return this.each((function(){const t=Carousel.getOrCreateInstance(this,e);if("number"!=typeof e){if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}else t.to(e)}))}}EventHandler.on(document,EVENT_CLICK_DATA_API$5,SELECTOR_DATA_SLIDE,(function(e){const t=getElementFromSelector(this);if(!t||!t.classList.contains("carousel"))return;e.preventDefault();const n=Carousel.getOrCreateInstance(t),i=this.getAttribute("data-bs-slide-to");return i?(n.to(i),void n._maybeEnableCycle()):"next"===Manipulator.getDataAttribute(this,"slide")?(n.next(),void n._maybeEnableCycle()):(n.prev(),void n._maybeEnableCycle())})),EventHandler.on(window,EVENT_LOAD_DATA_API$3,(()=>{const e=SelectorEngine.find(SELECTOR_DATA_RIDE);for(const t of e)Carousel.getOrCreateInstance(t)})),defineJQueryPlugin(Carousel);const NAME$b="collapse",DATA_KEY$7="bs.collapse",EVENT_KEY$7=".bs.collapse",DATA_API_KEY$4=".data-api",EVENT_SHOW$6="show.bs.collapse",EVENT_SHOWN$6="shown.bs.collapse",EVENT_HIDE$6="hide.bs.collapse",EVENT_HIDDEN$6="hidden.bs.collapse",EVENT_CLICK_DATA_API$4="click.bs.collapse.data-api",CLASS_NAME_SHOW$7="show",CLASS_NAME_COLLAPSE="collapse",CLASS_NAME_COLLAPSING="collapsing",CLASS_NAME_COLLAPSED="collapsed",CLASS_NAME_DEEPER_CHILDREN=":scope .collapse .collapse",CLASS_NAME_HORIZONTAL="collapse-horizontal",WIDTH="width",HEIGHT="height",SELECTOR_ACTIVES=".collapse.show, .collapse.collapsing",SELECTOR_DATA_TOGGLE$4='[data-bs-toggle="collapse"]',Default$a={parent:null,toggle:!0},DefaultType$a={parent:"(null|element)",toggle:"boolean"};class Collapse extends BaseComponent{constructor(e,t){super(e,t),this._isTransitioning=!1,this._triggerArray=[];const n=SelectorEngine.find(SELECTOR_DATA_TOGGLE$4);for(const e of n){const t=getSelectorFromElement(e),n=SelectorEngine.find(t).filter((e=>e===this._element));null!==t&&n.length&&this._triggerArray.push(e)}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return Default$a}static get DefaultType(){return DefaultType$a}static get NAME(){return NAME$b}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let e=[];if(this._config.parent&&(e=this._getFirstLevelChildren(SELECTOR_ACTIVES).filter((e=>e!==this._element)).map((e=>Collapse.getOrCreateInstance(e,{toggle:!1})))),e.length&&e[0]._isTransitioning)return;if(EventHandler.trigger(this._element,EVENT_SHOW$6).defaultPrevented)return;for(const t of e)t.hide();const t=this._getDimension();this._element.classList.remove("collapse"),this._element.classList.add("collapsing"),this._element.style[t]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;const n=`scroll${t[0].toUpperCase()+t.slice(1)}`;this._queueCallback((()=>{this._isTransitioning=!1,this._element.classList.remove("collapsing"),this._element.classList.add("collapse","show"),this._element.style[t]="",EventHandler.trigger(this._element,EVENT_SHOWN$6)}),this._element,!0),this._element.style[t]=`${this._element[n]}px`}hide(){if(this._isTransitioning||!this._isShown())return;if(EventHandler.trigger(this._element,EVENT_HIDE$6).defaultPrevented)return;const e=this._getDimension();this._element.style[e]=`${this._element.getBoundingClientRect()[e]}px`,reflow(this._element),this._element.classList.add("collapsing"),this._element.classList.remove("collapse","show");for(const e of this._triggerArray){const t=getElementFromSelector(e);t&&!this._isShown(t)&&this._addAriaAndCollapsedClass([e],!1)}this._isTransitioning=!0;this._element.style[e]="",this._queueCallback((()=>{this._isTransitioning=!1,this._element.classList.remove("collapsing"),this._element.classList.add("collapse"),EventHandler.trigger(this._element,EVENT_HIDDEN$6)}),this._element,!0)}_isShown(e=this._element){return e.classList.contains("show")}_configAfterMerge(e){return e.toggle=Boolean(e.toggle),e.parent=getElement(e.parent),e}_getDimension(){return this._element.classList.contains("collapse-horizontal")?WIDTH:HEIGHT}_initializeChildren(){if(!this._config.parent)return;const e=this._getFirstLevelChildren(SELECTOR_DATA_TOGGLE$4);for(const t of e){const e=getElementFromSelector(t);e&&this._addAriaAndCollapsedClass([t],this._isShown(e))}}_getFirstLevelChildren(e){const t=SelectorEngine.find(CLASS_NAME_DEEPER_CHILDREN,this._config.parent);return SelectorEngine.find(e,this._config.parent).filter((e=>!t.includes(e)))}_addAriaAndCollapsedClass(e,t){if(e.length)for(const n of e)n.classList.toggle("collapsed",!t),n.setAttribute("aria-expanded",t)}static jQueryInterface(e){const t={};return"string"==typeof e&&/show|hide/.test(e)&&(t.toggle=!1),this.each((function(){const n=Collapse.getOrCreateInstance(this,t);if("string"==typeof e){if(void 0===n[e])throw new TypeError(`No method named "${e}"`);n[e]()}}))}}EventHandler.on(document,EVENT_CLICK_DATA_API$4,SELECTOR_DATA_TOGGLE$4,(function(e){("A"===e.target.tagName||e.delegateTarget&&"A"===e.delegateTarget.tagName)&&e.preventDefault();const t=getSelectorFromElement(this),n=SelectorEngine.find(t);for(const e of n)Collapse.getOrCreateInstance(e,{toggle:!1}).toggle()})),defineJQueryPlugin(Collapse);const NAME$a="dropdown",DATA_KEY$6="bs.dropdown",EVENT_KEY$6=".bs.dropdown",DATA_API_KEY$3=".data-api",ESCAPE_KEY$2="Escape",TAB_KEY$1="Tab",ARROW_UP_KEY$1="ArrowUp",ARROW_DOWN_KEY$1="ArrowDown",RIGHT_MOUSE_BUTTON=2,EVENT_HIDE$5="hide.bs.dropdown",EVENT_HIDDEN$5="hidden.bs.dropdown",EVENT_SHOW$5="show.bs.dropdown",EVENT_SHOWN$5="shown.bs.dropdown",EVENT_CLICK_DATA_API$3="click.bs.dropdown.data-api",EVENT_KEYDOWN_DATA_API="keydown.bs.dropdown.data-api",EVENT_KEYUP_DATA_API="keyup.bs.dropdown.data-api",CLASS_NAME_SHOW$6="show",CLASS_NAME_DROPUP="dropup",CLASS_NAME_DROPEND="dropend",CLASS_NAME_DROPSTART="dropstart",CLASS_NAME_DROPUP_CENTER="dropup-center",CLASS_NAME_DROPDOWN_CENTER="dropdown-center",SELECTOR_DATA_TOGGLE$3='[data-bs-toggle="dropdown"]:not(.disabled):not(:disabled)',SELECTOR_DATA_TOGGLE_SHOWN=`${SELECTOR_DATA_TOGGLE$3}.show`,SELECTOR_MENU=".dropdown-menu",SELECTOR_NAVBAR=".navbar",SELECTOR_NAVBAR_NAV=".navbar-nav",SELECTOR_VISIBLE_ITEMS=".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)",PLACEMENT_TOP=isRTL()?"top-end":"top-start",PLACEMENT_TOPEND=isRTL()?"top-start":"top-end",PLACEMENT_BOTTOM=isRTL()?"bottom-end":"bottom-start",PLACEMENT_BOTTOMEND=isRTL()?"bottom-start":"bottom-end",PLACEMENT_RIGHT=isRTL()?"left-start":"right-start",PLACEMENT_LEFT=isRTL()?"right-start":"left-start",PLACEMENT_TOPCENTER="top",PLACEMENT_BOTTOMCENTER="bottom",Default$9={autoClose:!0,boundary:"clippingParents",display:"dynamic",offset:[0,2],popperConfig:null,reference:"toggle"},DefaultType$9={autoClose:"(boolean|string)",boundary:"(string|element)",display:"string",offset:"(array|string|function)",popperConfig:"(null|object|function)",reference:"(string|element|object)"};class Dropdown extends BaseComponent{constructor(e,t){super(e,t),this._popper=null,this._parent=this._element.parentNode,this._menu=SelectorEngine.next(this._element,SELECTOR_MENU)[0]||SelectorEngine.prev(this._element,SELECTOR_MENU)[0]||SelectorEngine.findOne(SELECTOR_MENU,this._parent),this._inNavbar=this._detectNavbar()}static get Default(){return Default$9}static get DefaultType(){return DefaultType$9}static get NAME(){return NAME$a}toggle(){return this._isShown()?this.hide():this.show()}show(){if(isDisabled(this._element)||this._isShown())return;const e={relatedTarget:this._element};if(!EventHandler.trigger(this._element,EVENT_SHOW$5,e).defaultPrevented){if(this._createPopper(),"ontouchstart"in document.documentElement&&!this._parent.closest(".navbar-nav"))for(const e of[].concat(...document.body.children))EventHandler.on(e,"mouseover",noop);this._element.focus(),this._element.setAttribute("aria-expanded",!0),this._menu.classList.add("show"),this._element.classList.add("show"),EventHandler.trigger(this._element,EVENT_SHOWN$5,e)}}hide(){if(isDisabled(this._element)||!this._isShown())return;const e={relatedTarget:this._element};this._completeHide(e)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}update(){this._inNavbar=this._detectNavbar(),this._popper&&this._popper.update()}_completeHide(e){if(!EventHandler.trigger(this._element,EVENT_HIDE$5,e).defaultPrevented){if("ontouchstart"in document.documentElement)for(const e of[].concat(...document.body.children))EventHandler.off(e,"mouseover",noop);this._popper&&this._popper.destroy(),this._menu.classList.remove("show"),this._element.classList.remove("show"),this._element.setAttribute("aria-expanded","false"),Manipulator.removeDataAttribute(this._menu,"popper"),EventHandler.trigger(this._element,EVENT_HIDDEN$5,e)}}_getConfig(e){if("object"==typeof(e=super._getConfig(e)).reference&&!isElement(e.reference)&&"function"!=typeof e.reference.getBoundingClientRect)throw new TypeError(`${NAME$a.toUpperCase()}: Option "reference" provided type "object" without a required "getBoundingClientRect" method.`);return e}_createPopper(){if(void 0===Popper)throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org)");let e=this._element;"parent"===this._config.reference?e=this._parent:isElement(this._config.reference)?e=getElement(this._config.reference):"object"==typeof this._config.reference&&(e=this._config.reference);const t=this._getPopperConfig();this._popper=createPopper(e,this._menu,t)}_isShown(){return this._menu.classList.contains("show")}_getPlacement(){const e=this._parent;if(e.classList.contains("dropend"))return PLACEMENT_RIGHT;if(e.classList.contains("dropstart"))return PLACEMENT_LEFT;if(e.classList.contains("dropup-center"))return"top";if(e.classList.contains("dropdown-center"))return"bottom";const t="end"===getComputedStyle(this._menu).getPropertyValue("--bs-position").trim();return e.classList.contains("dropup")?t?PLACEMENT_TOPEND:PLACEMENT_TOP:t?PLACEMENT_BOTTOMEND:PLACEMENT_BOTTOM}_detectNavbar(){return null!==this._element.closest(".navbar")}_getOffset(){const{offset:e}=this._config;return"string"==typeof e?e.split(",").map((e=>Number.parseInt(e,10))):"function"==typeof e?t=>e(t,this._element):e}_getPopperConfig(){const e={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return(this._inNavbar||"static"===this._config.display)&&(Manipulator.setDataAttribute(this._menu,"popper","static"),e.modifiers=[{name:"applyStyles",enabled:!1}]),{...e,..."function"==typeof this._config.popperConfig?this._config.popperConfig(e):this._config.popperConfig}}_selectMenuItem({key:e,target:t}){const n=SelectorEngine.find(SELECTOR_VISIBLE_ITEMS,this._menu).filter((e=>isVisible(e)));n.length&&getNextActiveElement(n,t,e===ARROW_DOWN_KEY$1,!n.includes(t)).focus()}static jQueryInterface(e){return this.each((function(){const t=Dropdown.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}static clearMenus(e){if(2===e.button||"keyup"===e.type&&"Tab"!==e.key)return;const t=SelectorEngine.find(SELECTOR_DATA_TOGGLE_SHOWN);for(const n of t){const t=Dropdown.getInstance(n);if(!t||!1===t._config.autoClose)continue;const i=e.composedPath(),s=i.includes(t._menu);if(i.includes(t._element)||"inside"===t._config.autoClose&&!s||"outside"===t._config.autoClose&&s)continue;if(t._menu.contains(e.target)&&("keyup"===e.type&&"Tab"===e.key||/input|select|option|textarea|form/i.test(e.target.tagName)))continue;const r={relatedTarget:t._element};"click"===e.type&&(r.clickEvent=e),t._completeHide(r)}}static dataApiKeydownHandler(e){const t=/input|textarea/i.test(e.target.tagName),n="Escape"===e.key,i=[ARROW_UP_KEY$1,ARROW_DOWN_KEY$1].includes(e.key);if(!i&&!n)return;if(t&&!n)return;e.preventDefault();const s=this.matches(SELECTOR_DATA_TOGGLE$3)?this:SelectorEngine.prev(this,SELECTOR_DATA_TOGGLE$3)[0]||SelectorEngine.next(this,SELECTOR_DATA_TOGGLE$3)[0]||SelectorEngine.findOne(SELECTOR_DATA_TOGGLE$3,e.delegateTarget.parentNode),r=Dropdown.getOrCreateInstance(s);if(i)return e.stopPropagation(),r.show(),void r._selectMenuItem(e);r._isShown()&&(e.stopPropagation(),r.hide(),s.focus())}}EventHandler.on(document,EVENT_KEYDOWN_DATA_API,SELECTOR_DATA_TOGGLE$3,Dropdown.dataApiKeydownHandler),EventHandler.on(document,EVENT_KEYDOWN_DATA_API,SELECTOR_MENU,Dropdown.dataApiKeydownHandler),EventHandler.on(document,EVENT_CLICK_DATA_API$3,Dropdown.clearMenus),EventHandler.on(document,EVENT_KEYUP_DATA_API,Dropdown.clearMenus),EventHandler.on(document,EVENT_CLICK_DATA_API$3,SELECTOR_DATA_TOGGLE$3,(function(e){e.preventDefault(),Dropdown.getOrCreateInstance(this).toggle()})),defineJQueryPlugin(Dropdown);const SELECTOR_FIXED_CONTENT=".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",SELECTOR_STICKY_CONTENT=".sticky-top",PROPERTY_PADDING="padding-right",PROPERTY_MARGIN="margin-right";class ScrollBarHelper{constructor(){this._element=document.body}getWidth(){const e=document.documentElement.clientWidth;return Math.abs(window.innerWidth-e)}hide(){const e=this.getWidth();this._disableOverFlow(),this._setElementAttributes(this._element,"padding-right",(t=>t+e)),this._setElementAttributes(SELECTOR_FIXED_CONTENT,"padding-right",(t=>t+e)),this._setElementAttributes(".sticky-top","margin-right",(t=>t-e))}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,"padding-right"),this._resetElementAttributes(SELECTOR_FIXED_CONTENT,"padding-right"),this._resetElementAttributes(".sticky-top","margin-right")}isOverflowing(){return this.getWidth()>0}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(e,t,n){const i=this.getWidth();this._applyManipulationCallback(e,(e=>{if(e!==this._element&&window.innerWidth>e.clientWidth+i)return;this._saveInitialAttribute(e,t);const s=window.getComputedStyle(e).getPropertyValue(t);e.style.setProperty(t,`${n(Number.parseFloat(s))}px`)}))}_saveInitialAttribute(e,t){const n=e.style.getPropertyValue(t);n&&Manipulator.setDataAttribute(e,t,n)}_resetElementAttributes(e,t){this._applyManipulationCallback(e,(e=>{const n=Manipulator.getDataAttribute(e,t);null!==n?(Manipulator.removeDataAttribute(e,t),e.style.setProperty(t,n)):e.style.removeProperty(t)}))}_applyManipulationCallback(e,t){if(isElement(e))t(e);else for(const n of SelectorEngine.find(e,this._element))t(n)}}const NAME$9="backdrop",CLASS_NAME_FADE$4="fade",CLASS_NAME_SHOW$5="show",EVENT_MOUSEDOWN="mousedown.bs.backdrop",Default$8={className:"modal-backdrop",clickCallback:null,isAnimated:!1,isVisible:!0,rootElement:"body"},DefaultType$8={className:"string",clickCallback:"(function|null)",isAnimated:"boolean",isVisible:"boolean",rootElement:"(element|string)"};class Backdrop extends Config{constructor(e){super(),this._config=this._getConfig(e),this._isAppended=!1,this._element=null}static get Default(){return Default$8}static get DefaultType(){return DefaultType$8}static get NAME(){return NAME$9}show(e){if(!this._config.isVisible)return void execute(e);this._append();const t=this._getElement();this._config.isAnimated&&reflow(t),t.classList.add("show"),this._emulateAnimation((()=>{execute(e)}))}hide(e){this._config.isVisible?(this._getElement().classList.remove("show"),this._emulateAnimation((()=>{this.dispose(),execute(e)}))):execute(e)}dispose(){this._isAppended&&(EventHandler.off(this._element,EVENT_MOUSEDOWN),this._element.remove(),this._isAppended=!1)}_getElement(){if(!this._element){const e=document.createElement("div");e.className=this._config.className,this._config.isAnimated&&e.classList.add("fade"),this._element=e}return this._element}_configAfterMerge(e){return e.rootElement=getElement(e.rootElement),e}_append(){if(this._isAppended)return;const e=this._getElement();this._config.rootElement.append(e),EventHandler.on(e,EVENT_MOUSEDOWN,(()=>{execute(this._config.clickCallback)})),this._isAppended=!0}_emulateAnimation(e){executeAfterTransition(e,this._getElement(),this._config.isAnimated)}}const NAME$8="focustrap",DATA_KEY$5="bs.focustrap",EVENT_KEY$5=".bs.focustrap",EVENT_FOCUSIN$2="focusin.bs.focustrap",EVENT_KEYDOWN_TAB="keydown.tab.bs.focustrap",TAB_KEY="Tab",TAB_NAV_FORWARD="forward",TAB_NAV_BACKWARD="backward",Default$7={autofocus:!0,trapElement:null},DefaultType$7={autofocus:"boolean",trapElement:"element"};class FocusTrap extends Config{constructor(e){super(),this._config=this._getConfig(e),this._isActive=!1,this._lastTabNavDirection=null}static get Default(){return Default$7}static get DefaultType(){return DefaultType$7}static get NAME(){return NAME$8}activate(){this._isActive||(this._config.autofocus&&this._config.trapElement.focus(),EventHandler.off(document,EVENT_KEY$5),EventHandler.on(document,EVENT_FOCUSIN$2,(e=>this._handleFocusin(e))),EventHandler.on(document,EVENT_KEYDOWN_TAB,(e=>this._handleKeydown(e))),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,EventHandler.off(document,EVENT_KEY$5))}_handleFocusin(e){const{trapElement:t}=this._config;if(e.target===document||e.target===t||t.contains(e.target))return;const n=SelectorEngine.focusableChildren(t);0===n.length?t.focus():"backward"===this._lastTabNavDirection?n[n.length-1].focus():n[0].focus()}_handleKeydown(e){"Tab"===e.key&&(this._lastTabNavDirection=e.shiftKey?"backward":"forward")}}const NAME$7="modal",DATA_KEY$4="bs.modal",EVENT_KEY$4=".bs.modal",DATA_API_KEY$2=".data-api",ESCAPE_KEY$1="Escape",EVENT_HIDE$4="hide.bs.modal",EVENT_HIDE_PREVENTED$1="hidePrevented.bs.modal",EVENT_HIDDEN$4="hidden.bs.modal",EVENT_SHOW$4="show.bs.modal",EVENT_SHOWN$4="shown.bs.modal",EVENT_RESIZE$1="resize.bs.modal",EVENT_CLICK_DISMISS="click.dismiss.bs.modal",EVENT_MOUSEDOWN_DISMISS="mousedown.dismiss.bs.modal",EVENT_KEYDOWN_DISMISS$1="keydown.dismiss.bs.modal",EVENT_CLICK_DATA_API$2="click.bs.modal.data-api",CLASS_NAME_OPEN="modal-open",CLASS_NAME_FADE$3="fade",CLASS_NAME_SHOW$4="show",CLASS_NAME_STATIC="modal-static",OPEN_SELECTOR$1=".modal.show",SELECTOR_DIALOG=".modal-dialog",SELECTOR_MODAL_BODY=".modal-body",SELECTOR_DATA_TOGGLE$2='[data-bs-toggle="modal"]',Default$6={backdrop:!0,focus:!0,keyboard:!0},DefaultType$6={backdrop:"(boolean|string)",focus:"boolean",keyboard:"boolean"};class Modal extends BaseComponent{constructor(e,t){super(e,t),this._dialog=SelectorEngine.findOne(".modal-dialog",this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._isTransitioning=!1,this._scrollBar=new ScrollBarHelper,this._addEventListeners()}static get Default(){return Default$6}static get DefaultType(){return DefaultType$6}static get NAME(){return NAME$7}toggle(e){return this._isShown?this.hide():this.show(e)}show(e){if(this._isShown||this._isTransitioning)return;EventHandler.trigger(this._element,EVENT_SHOW$4,{relatedTarget:e}).defaultPrevented||(this._isShown=!0,this._isTransitioning=!0,this._scrollBar.hide(),document.body.classList.add("modal-open"),this._adjustDialog(),this._backdrop.show((()=>this._showElement(e))))}hide(){if(!this._isShown||this._isTransitioning)return;EventHandler.trigger(this._element,EVENT_HIDE$4).defaultPrevented||(this._isShown=!1,this._isTransitioning=!0,this._focustrap.deactivate(),this._element.classList.remove("show"),this._queueCallback((()=>this._hideModal()),this._element,this._isAnimated()))}dispose(){for(const e of[window,this._dialog])EventHandler.off(e,".bs.modal");this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new Backdrop({isVisible:Boolean(this._config.backdrop),isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new FocusTrap({trapElement:this._element})}_showElement(e){document.body.contains(this._element)||document.body.append(this._element),this._element.style.display="block",this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.scrollTop=0;const t=SelectorEngine.findOne(".modal-body",this._dialog);t&&(t.scrollTop=0),reflow(this._element),this._element.classList.add("show");this._queueCallback((()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,EventHandler.trigger(this._element,EVENT_SHOWN$4,{relatedTarget:e})}),this._dialog,this._isAnimated())}_addEventListeners(){EventHandler.on(this._element,EVENT_KEYDOWN_DISMISS$1,(e=>{if("Escape"===e.key)return this._config.keyboard?(e.preventDefault(),void this.hide()):void this._triggerBackdropTransition()})),EventHandler.on(window,EVENT_RESIZE$1,(()=>{this._isShown&&!this._isTransitioning&&this._adjustDialog()})),EventHandler.on(this._element,EVENT_MOUSEDOWN_DISMISS,(e=>{EventHandler.one(this._element,EVENT_CLICK_DISMISS,(t=>{this._element===e.target&&this._element===t.target&&("static"!==this._config.backdrop?this._config.backdrop&&this.hide():this._triggerBackdropTransition())}))}))}_hideModal(){this._element.style.display="none",this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._isTransitioning=!1,this._backdrop.hide((()=>{document.body.classList.remove("modal-open"),this._resetAdjustments(),this._scrollBar.reset(),EventHandler.trigger(this._element,EVENT_HIDDEN$4)}))}_isAnimated(){return this._element.classList.contains("fade")}_triggerBackdropTransition(){if(EventHandler.trigger(this._element,EVENT_HIDE_PREVENTED$1).defaultPrevented)return;const e=this._element.scrollHeight>document.documentElement.clientHeight,t=this._element.style.overflowY;"hidden"===t||this._element.classList.contains("modal-static")||(e||(this._element.style.overflowY="hidden"),this._element.classList.add("modal-static"),this._queueCallback((()=>{this._element.classList.remove("modal-static"),this._queueCallback((()=>{this._element.style.overflowY=t}),this._dialog)}),this._dialog),this._element.focus())}_adjustDialog(){const e=this._element.scrollHeight>document.documentElement.clientHeight,t=this._scrollBar.getWidth(),n=t>0;if(n&&!e){const e=isRTL()?"paddingLeft":"paddingRight";this._element.style[e]=`${t}px`}if(!n&&e){const e=isRTL()?"paddingRight":"paddingLeft";this._element.style[e]=`${t}px`}}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(e,t){return this.each((function(){const n=Modal.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===n[e])throw new TypeError(`No method named "${e}"`);n[e](t)}}))}}EventHandler.on(document,EVENT_CLICK_DATA_API$2,SELECTOR_DATA_TOGGLE$2,(function(e){const t=getElementFromSelector(this);["A","AREA"].includes(this.tagName)&&e.preventDefault(),EventHandler.one(t,EVENT_SHOW$4,(e=>{e.defaultPrevented||EventHandler.one(t,EVENT_HIDDEN$4,(()=>{isVisible(this)&&this.focus()}))}));const n=SelectorEngine.findOne(".modal.show");n&&Modal.getInstance(n).hide();Modal.getOrCreateInstance(t).toggle(this)})),enableDismissTrigger(Modal),defineJQueryPlugin(Modal);const NAME$6="offcanvas",DATA_KEY$3="bs.offcanvas",EVENT_KEY$3=".bs.offcanvas",DATA_API_KEY$1=".data-api",EVENT_LOAD_DATA_API$2="load.bs.offcanvas.data-api",ESCAPE_KEY="Escape",CLASS_NAME_SHOW$3="show",CLASS_NAME_SHOWING$1="showing",CLASS_NAME_HIDING="hiding",CLASS_NAME_BACKDROP="offcanvas-backdrop",OPEN_SELECTOR=".offcanvas.show",EVENT_SHOW$3="show.bs.offcanvas",EVENT_SHOWN$3="shown.bs.offcanvas",EVENT_HIDE$3="hide.bs.offcanvas",EVENT_HIDE_PREVENTED="hidePrevented.bs.offcanvas",EVENT_HIDDEN$3="hidden.bs.offcanvas",EVENT_RESIZE="resize.bs.offcanvas",EVENT_CLICK_DATA_API$1="click.bs.offcanvas.data-api",EVENT_KEYDOWN_DISMISS="keydown.dismiss.bs.offcanvas",SELECTOR_DATA_TOGGLE$1='[data-bs-toggle="offcanvas"]',Default$5={backdrop:!0,keyboard:!0,scroll:!1},DefaultType$5={backdrop:"(boolean|string)",keyboard:"boolean",scroll:"boolean"};class Offcanvas extends BaseComponent{constructor(e,t){super(e,t),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get Default(){return Default$5}static get DefaultType(){return DefaultType$5}static get NAME(){return NAME$6}toggle(e){return this._isShown?this.hide():this.show(e)}show(e){if(this._isShown)return;if(EventHandler.trigger(this._element,EVENT_SHOW$3,{relatedTarget:e}).defaultPrevented)return;this._isShown=!0,this._backdrop.show(),this._config.scroll||(new ScrollBarHelper).hide(),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add("showing");this._queueCallback((()=>{this._config.scroll&&!this._config.backdrop||this._focustrap.activate(),this._element.classList.add("show"),this._element.classList.remove("showing"),EventHandler.trigger(this._element,EVENT_SHOWN$3,{relatedTarget:e})}),this._element,!0)}hide(){if(!this._isShown)return;if(EventHandler.trigger(this._element,EVENT_HIDE$3).defaultPrevented)return;this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.add("hiding"),this._backdrop.hide();this._queueCallback((()=>{this._element.classList.remove("show","hiding"),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._config.scroll||(new ScrollBarHelper).reset(),EventHandler.trigger(this._element,EVENT_HIDDEN$3)}),this._element,!0)}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_initializeBackDrop(){const e=Boolean(this._config.backdrop);return new Backdrop({className:CLASS_NAME_BACKDROP,isVisible:e,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:e?()=>{"static"!==this._config.backdrop?this.hide():EventHandler.trigger(this._element,EVENT_HIDE_PREVENTED)}:null})}_initializeFocusTrap(){return new FocusTrap({trapElement:this._element})}_addEventListeners(){EventHandler.on(this._element,EVENT_KEYDOWN_DISMISS,(e=>{"Escape"===e.key&&(this._config.keyboard?this.hide():EventHandler.trigger(this._element,EVENT_HIDE_PREVENTED))}))}static jQueryInterface(e){return this.each((function(){const t=Offcanvas.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}EventHandler.on(document,EVENT_CLICK_DATA_API$1,SELECTOR_DATA_TOGGLE$1,(function(e){const t=getElementFromSelector(this);if(["A","AREA"].includes(this.tagName)&&e.preventDefault(),isDisabled(this))return;EventHandler.one(t,EVENT_HIDDEN$3,(()=>{isVisible(this)&&this.focus()}));const n=SelectorEngine.findOne(OPEN_SELECTOR);n&&n!==t&&Offcanvas.getInstance(n).hide();Offcanvas.getOrCreateInstance(t).toggle(this)})),EventHandler.on(window,EVENT_LOAD_DATA_API$2,(()=>{for(const e of SelectorEngine.find(OPEN_SELECTOR))Offcanvas.getOrCreateInstance(e).show()})),EventHandler.on(window,EVENT_RESIZE,(()=>{for(const e of SelectorEngine.find("[aria-modal][class*=show][class*=offcanvas-]"))"fixed"!==getComputedStyle(e).position&&Offcanvas.getOrCreateInstance(e).hide()})),enableDismissTrigger(Offcanvas),defineJQueryPlugin(Offcanvas);const uriAttributes=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),ARIA_ATTRIBUTE_PATTERN=/^aria-[\w-]*$/i,SAFE_URL_PATTERN=/^(?:(?:https?|mailto|ftp|tel|file|sms):|[^#&/:?]*(?:[#/?]|$))/i,DATA_URL_PATTERN=/^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[\d+/a-z]+=*$/i,allowedAttribute=(e,t)=>{const n=e.nodeName.toLowerCase();return t.includes(n)?!uriAttributes.has(n)||Boolean(SAFE_URL_PATTERN.test(e.nodeValue)||DATA_URL_PATTERN.test(e.nodeValue)):t.filter((e=>e instanceof RegExp)).some((e=>e.test(n)))},DefaultAllowlist={"*":["class","dir","id","lang","role",ARIA_ATTRIBUTE_PATTERN],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],div:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","srcset","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]};function sanitizeHtml(e,t,n){if(!e.length)return e;if(n&&"function"==typeof n)return n(e);const i=(new window.DOMParser).parseFromString(e,"text/html"),s=[].concat(...i.body.querySelectorAll("*"));for(const e of s){const n=e.nodeName.toLowerCase();if(!Object.keys(t).includes(n)){e.remove();continue}const i=[].concat(...e.attributes),s=[].concat(t["*"]||[],t[n]||[]);for(const t of i)allowedAttribute(t,s)||e.removeAttribute(t.nodeName)}return i.body.innerHTML}const NAME$5="TemplateFactory",Default$4={allowList:DefaultAllowlist,content:{},extraClass:"",html:!1,sanitize:!0,sanitizeFn:null,template:"<div></div>"},DefaultType$4={allowList:"object",content:"object",extraClass:"(string|function)",html:"boolean",sanitize:"boolean",sanitizeFn:"(null|function)",template:"string"},DefaultContentType={entry:"(string|element|function|null)",selector:"(string|element)"};class TemplateFactory extends Config{constructor(e){super(),this._config=this._getConfig(e)}static get Default(){return Default$4}static get DefaultType(){return DefaultType$4}static get NAME(){return NAME$5}getContent(){return Object.values(this._config.content).map((e=>this._resolvePossibleFunction(e))).filter(Boolean)}hasContent(){return this.getContent().length>0}changeContent(e){return this._checkContent(e),this._config.content={...this._config.content,...e},this}toHtml(){const e=document.createElement("div");e.innerHTML=this._maybeSanitize(this._config.template);for(const[t,n]of Object.entries(this._config.content))this._setContent(e,n,t);const t=e.children[0],n=this._resolvePossibleFunction(this._config.extraClass);return n&&t.classList.add(...n.split(" ")),t}_typeCheckConfig(e){super._typeCheckConfig(e),this._checkContent(e.content)}_checkContent(e){for(const[t,n]of Object.entries(e))super._typeCheckConfig({selector:t,entry:n},DefaultContentType)}_setContent(e,t,n){const i=SelectorEngine.findOne(n,e);i&&((t=this._resolvePossibleFunction(t))?isElement(t)?this._putElementInTemplate(getElement(t),i):this._config.html?i.innerHTML=this._maybeSanitize(t):i.textContent=t:i.remove())}_maybeSanitize(e){return this._config.sanitize?sanitizeHtml(e,this._config.allowList,this._config.sanitizeFn):e}_resolvePossibleFunction(e){return"function"==typeof e?e(this):e}_putElementInTemplate(e,t){if(this._config.html)return t.innerHTML="",void t.append(e);t.textContent=e.textContent}}const NAME$4="tooltip",DISALLOWED_ATTRIBUTES=new Set(["sanitize","allowList","sanitizeFn"]),CLASS_NAME_FADE$2="fade",CLASS_NAME_MODAL="modal",CLASS_NAME_SHOW$2="show",SELECTOR_TOOLTIP_INNER=".tooltip-inner",SELECTOR_MODAL=".modal",EVENT_MODAL_HIDE="hide.bs.modal",TRIGGER_HOVER="hover",TRIGGER_FOCUS="focus",TRIGGER_CLICK="click",TRIGGER_MANUAL="manual",EVENT_HIDE$2="hide",EVENT_HIDDEN$2="hidden",EVENT_SHOW$2="show",EVENT_SHOWN$2="shown",EVENT_INSERTED="inserted",EVENT_CLICK$1="click",EVENT_FOCUSIN$1="focusin",EVENT_FOCUSOUT$1="focusout",EVENT_MOUSEENTER="mouseenter",EVENT_MOUSELEAVE="mouseleave",AttachmentMap={AUTO:"auto",TOP:"top",RIGHT:isRTL()?"left":"right",BOTTOM:"bottom",LEFT:isRTL()?"right":"left"},Default$3={allowList:DefaultAllowlist,animation:!0,boundary:"clippingParents",container:!1,customClass:"",delay:0,fallbackPlacements:["top","right","bottom","left"],html:!1,offset:[0,0],placement:"top",popperConfig:null,sanitize:!0,sanitizeFn:null,selector:!1,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',title:"",trigger:"hover focus"},DefaultType$3={allowList:"object",animation:"boolean",boundary:"(string|element)",container:"(string|element|boolean)",customClass:"(string|function)",delay:"(number|object)",fallbackPlacements:"array",html:"boolean",offset:"(array|string|function)",placement:"(string|function)",popperConfig:"(null|object|function)",sanitize:"boolean",sanitizeFn:"(null|function)",selector:"(string|boolean)",template:"string",title:"(string|element|function)",trigger:"string"};class Tooltip extends BaseComponent{constructor(e,t){if(void 0===Popper)throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");super(e,t),this._isEnabled=!0,this._timeout=0,this._isHovered=null,this._activeTrigger={},this._popper=null,this._templateFactory=null,this._newContent=null,this.tip=null,this._setListeners(),this._config.selector||this._fixTitle()}static get Default(){return Default$3}static get DefaultType(){return DefaultType$3}static get NAME(){return NAME$4}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(){this._isEnabled&&(this._activeTrigger.click=!this._activeTrigger.click,this._isShown()?this._leave():this._enter())}dispose(){clearTimeout(this._timeout),EventHandler.off(this._element.closest(".modal"),"hide.bs.modal",this._hideModalHandler),this.tip&&this.tip.remove(),this._element.getAttribute("data-bs-original-title")&&this._element.setAttribute("title",this._element.getAttribute("data-bs-original-title")),this._disposePopper(),super.dispose()}show(){if("none"===this._element.style.display)throw new Error("Please use show on visible elements");if(!this._isWithContent()||!this._isEnabled)return;const e=EventHandler.trigger(this._element,this.constructor.eventName("show")),t=(findShadowRoot(this._element)||this._element.ownerDocument.documentElement).contains(this._element);if(e.defaultPrevented||!t)return;this.tip&&(this.tip.remove(),this.tip=null);const n=this._getTipElement();this._element.setAttribute("aria-describedby",n.getAttribute("id"));const{container:i}=this._config;if(this._element.ownerDocument.documentElement.contains(this.tip)||(i.append(n),EventHandler.trigger(this._element,this.constructor.eventName("inserted"))),this._popper?this._popper.update():this._popper=this._createPopper(n),n.classList.add("show"),"ontouchstart"in document.documentElement)for(const e of[].concat(...document.body.children))EventHandler.on(e,"mouseover",noop);this._queueCallback((()=>{EventHandler.trigger(this._element,this.constructor.eventName("shown")),!1===this._isHovered&&this._leave(),this._isHovered=!1}),this.tip,this._isAnimated())}hide(){if(!this._isShown())return;if(EventHandler.trigger(this._element,this.constructor.eventName("hide")).defaultPrevented)return;const e=this._getTipElement();if(e.classList.remove("show"),"ontouchstart"in document.documentElement)for(const e of[].concat(...document.body.children))EventHandler.off(e,"mouseover",noop);this._activeTrigger.click=!1,this._activeTrigger.focus=!1,this._activeTrigger.hover=!1,this._isHovered=null;this._queueCallback((()=>{this._isWithActiveTrigger()||(this._isHovered||e.remove(),this._element.removeAttribute("aria-describedby"),EventHandler.trigger(this._element,this.constructor.eventName("hidden")),this._disposePopper())}),this.tip,this._isAnimated())}update(){this._popper&&this._popper.update()}_isWithContent(){return Boolean(this._getTitle())}_getTipElement(){return this.tip||(this.tip=this._createTipElement(this._newContent||this._getContentForTemplate())),this.tip}_createTipElement(e){const t=this._getTemplateFactory(e).toHtml();if(!t)return null;t.classList.remove("fade","show"),t.classList.add(`bs-${this.constructor.NAME}-auto`);const n=getUID(this.constructor.NAME).toString();return t.setAttribute("id",n),this._isAnimated()&&t.classList.add("fade"),t}setContent(e){this._newContent=e,this._isShown()&&(this._disposePopper(),this.show())}_getTemplateFactory(e){return this._templateFactory?this._templateFactory.changeContent(e):this._templateFactory=new TemplateFactory({...this._config,content:e,extraClass:this._resolvePossibleFunction(this._config.customClass)}),this._templateFactory}_getContentForTemplate(){return{".tooltip-inner":this._getTitle()}}_getTitle(){return this._resolvePossibleFunction(this._config.title)||this._element.getAttribute("data-bs-original-title")}_initializeOnDelegatedTarget(e){return this.constructor.getOrCreateInstance(e.delegateTarget,this._getDelegateConfig())}_isAnimated(){return this._config.animation||this.tip&&this.tip.classList.contains("fade")}_isShown(){return this.tip&&this.tip.classList.contains("show")}_createPopper(e){const t="function"==typeof this._config.placement?this._config.placement.call(this,e,this._element):this._config.placement,n=AttachmentMap[t.toUpperCase()];return createPopper(this._element,e,this._getPopperConfig(n))}_getOffset(){const{offset:e}=this._config;return"string"==typeof e?e.split(",").map((e=>Number.parseInt(e,10))):"function"==typeof e?t=>e(t,this._element):e}_resolvePossibleFunction(e){return"function"==typeof e?e.call(this._element):e}_getPopperConfig(e){const t={placement:e,modifiers:[{name:"flip",options:{fallbackPlacements:this._config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"arrow",options:{element:`.${this.constructor.NAME}-arrow`}},{name:"preSetPlacement",enabled:!0,phase:"beforeMain",fn:e=>{this._getTipElement().setAttribute("data-popper-placement",e.state.placement)}}]};return{...t,..."function"==typeof this._config.popperConfig?this._config.popperConfig(t):this._config.popperConfig}}_setListeners(){const e=this._config.trigger.split(" ");for(const t of e)if("click"===t)EventHandler.on(this._element,this.constructor.eventName("click"),this._config.selector,(e=>{this._initializeOnDelegatedTarget(e).toggle()}));else if("manual"!==t){const e="hover"===t?this.constructor.eventName("mouseenter"):this.constructor.eventName("focusin"),n="hover"===t?this.constructor.eventName("mouseleave"):this.constructor.eventName("focusout");EventHandler.on(this._element,e,this._config.selector,(e=>{const t=this._initializeOnDelegatedTarget(e);t._activeTrigger["focusin"===e.type?"focus":"hover"]=!0,t._enter()})),EventHandler.on(this._element,n,this._config.selector,(e=>{const t=this._initializeOnDelegatedTarget(e);t._activeTrigger["focusout"===e.type?"focus":"hover"]=t._element.contains(e.relatedTarget),t._leave()}))}this._hideModalHandler=()=>{this._element&&this.hide()},EventHandler.on(this._element.closest(".modal"),"hide.bs.modal",this._hideModalHandler)}_fixTitle(){const e=this._element.getAttribute("title");e&&(this._element.getAttribute("aria-label")||this._element.textContent.trim()||this._element.setAttribute("aria-label",e),this._element.setAttribute("data-bs-original-title",e),this._element.removeAttribute("title"))}_enter(){this._isShown()||this._isHovered?this._isHovered=!0:(this._isHovered=!0,this._setTimeout((()=>{this._isHovered&&this.show()}),this._config.delay.show))}_leave(){this._isWithActiveTrigger()||(this._isHovered=!1,this._setTimeout((()=>{this._isHovered||this.hide()}),this._config.delay.hide))}_setTimeout(e,t){clearTimeout(this._timeout),this._timeout=setTimeout(e,t)}_isWithActiveTrigger(){return Object.values(this._activeTrigger).includes(!0)}_getConfig(e){const t=Manipulator.getDataAttributes(this._element);for(const e of Object.keys(t))DISALLOWED_ATTRIBUTES.has(e)&&delete t[e];return e={...t,..."object"==typeof e&&e?e:{}},e=this._mergeConfigObj(e),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}_configAfterMerge(e){return e.container=!1===e.container?document.body:getElement(e.container),"number"==typeof e.delay&&(e.delay={show:e.delay,hide:e.delay}),"number"==typeof e.title&&(e.title=e.title.toString()),"number"==typeof e.content&&(e.content=e.content.toString()),e}_getDelegateConfig(){const e={};for(const t in this._config)this.constructor.Default[t]!==this._config[t]&&(e[t]=this._config[t]);return e.selector=!1,e.trigger="manual",e}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null)}static jQueryInterface(e){return this.each((function(){const t=Tooltip.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}}defineJQueryPlugin(Tooltip);const NAME$3="popover",SELECTOR_TITLE=".popover-header",SELECTOR_CONTENT=".popover-body",Default$2={...Tooltip.Default,content:"",offset:[0,8],placement:"right",template:'<div class="popover" role="tooltip"><div class="popover-arrow"></div><h3 class="popover-header"></h3><div class="popover-body"></div></div>',trigger:"click"},DefaultType$2={...Tooltip.DefaultType,content:"(null|string|element|function)"};class Popover extends Tooltip{static get Default(){return Default$2}static get DefaultType(){return DefaultType$2}static get NAME(){return NAME$3}_isWithContent(){return this._getTitle()||this._getContent()}_getContentForTemplate(){return{[SELECTOR_TITLE]:this._getTitle(),".popover-body":this._getContent()}}_getContent(){return this._resolvePossibleFunction(this._config.content)}static jQueryInterface(e){return this.each((function(){const t=Popover.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}}defineJQueryPlugin(Popover);const NAME$2="scrollspy",DATA_KEY$2="bs.scrollspy",EVENT_KEY$2=".bs.scrollspy",DATA_API_KEY=".data-api",EVENT_ACTIVATE="activate.bs.scrollspy",EVENT_CLICK="click.bs.scrollspy",EVENT_LOAD_DATA_API$1="load.bs.scrollspy.data-api",CLASS_NAME_DROPDOWN_ITEM="dropdown-item",CLASS_NAME_ACTIVE$1="active",SELECTOR_DATA_SPY='[data-bs-spy="scroll"]',SELECTOR_TARGET_LINKS="[href]",SELECTOR_NAV_LIST_GROUP=".nav, .list-group",SELECTOR_NAV_LINKS=".nav-link",SELECTOR_NAV_ITEMS=".nav-item",SELECTOR_LIST_ITEMS=".list-group-item",SELECTOR_LINK_ITEMS=".nav-link, .nav-item > .nav-link, .list-group-item",SELECTOR_DROPDOWN=".dropdown",SELECTOR_DROPDOWN_TOGGLE$1=".dropdown-toggle",Default$1={offset:null,rootMargin:"0px 0px -25%",smoothScroll:!1,target:null,threshold:[.1,.5,1]},DefaultType$1={offset:"(number|null)",rootMargin:"string",smoothScroll:"boolean",target:"element",threshold:"array"};class ScrollSpy extends BaseComponent{constructor(e,t){super(e,t),this._targetLinks=new Map,this._observableSections=new Map,this._rootElement="visible"===getComputedStyle(this._element).overflowY?null:this._element,this._activeTarget=null,this._observer=null,this._previousScrollData={visibleEntryTop:0,parentScrollTop:0},this.refresh()}static get Default(){return Default$1}static get DefaultType(){return DefaultType$1}static get NAME(){return NAME$2}refresh(){this._initializeTargetsAndObservables(),this._maybeEnableSmoothScroll(),this._observer?this._observer.disconnect():this._observer=this._getNewObserver();for(const e of this._observableSections.values())this._observer.observe(e)}dispose(){this._observer.disconnect(),super.dispose()}_configAfterMerge(e){return e.target=getElement(e.target)||document.body,e.rootMargin=e.offset?`${e.offset}px 0px -30%`:e.rootMargin,"string"==typeof e.threshold&&(e.threshold=e.threshold.split(",").map((e=>Number.parseFloat(e)))),e}_maybeEnableSmoothScroll(){this._config.smoothScroll&&(EventHandler.off(this._config.target,EVENT_CLICK),EventHandler.on(this._config.target,EVENT_CLICK,"[href]",(e=>{const t=this._observableSections.get(e.target.hash);if(t){e.preventDefault();const n=this._rootElement||window,i=t.offsetTop-this._element.offsetTop;if(n.scrollTo)return void n.scrollTo({top:i,behavior:"smooth"});n.scrollTop=i}})))}_getNewObserver(){const e={root:this._rootElement,threshold:this._config.threshold,rootMargin:this._config.rootMargin};return new IntersectionObserver((e=>this._observerCallback(e)),e)}_observerCallback(e){const t=e=>this._targetLinks.get(`#${e.target.id}`),n=e=>{this._previousScrollData.visibleEntryTop=e.target.offsetTop,this._process(t(e))},i=(this._rootElement||document.documentElement).scrollTop,s=i>=this._previousScrollData.parentScrollTop;this._previousScrollData.parentScrollTop=i;for(const r of e){if(!r.isIntersecting){this._activeTarget=null,this._clearActiveClass(t(r));continue}const e=r.target.offsetTop>=this._previousScrollData.visibleEntryTop;if(s&&e){if(n(r),!i)return}else s||e||n(r)}}_initializeTargetsAndObservables(){this._targetLinks=new Map,this._observableSections=new Map;const e=SelectorEngine.find("[href]",this._config.target);for(const t of e){if(!t.hash||isDisabled(t))continue;const e=SelectorEngine.findOne(t.hash,this._element);isVisible(e)&&(this._targetLinks.set(t.hash,t),this._observableSections.set(t.hash,e))}}_process(e){this._activeTarget!==e&&(this._clearActiveClass(this._config.target),this._activeTarget=e,e.classList.add("active"),this._activateParents(e),EventHandler.trigger(this._element,EVENT_ACTIVATE,{relatedTarget:e}))}_activateParents(e){if(e.classList.contains("dropdown-item"))SelectorEngine.findOne(".dropdown-toggle",e.closest(".dropdown")).classList.add("active");else for(const t of SelectorEngine.parents(e,".nav, .list-group"))for(const e of SelectorEngine.prev(t,SELECTOR_LINK_ITEMS))e.classList.add("active")}_clearActiveClass(e){e.classList.remove("active");const t=SelectorEngine.find("[href].active",e);for(const e of t)e.classList.remove("active")}static jQueryInterface(e){return this.each((function(){const t=ScrollSpy.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}))}}EventHandler.on(window,EVENT_LOAD_DATA_API$1,(()=>{for(const e of SelectorEngine.find(SELECTOR_DATA_SPY))ScrollSpy.getOrCreateInstance(e)})),defineJQueryPlugin(ScrollSpy);const NAME$1="tab",DATA_KEY$1="bs.tab",EVENT_KEY$1=".bs.tab",EVENT_HIDE$1="hide.bs.tab",EVENT_HIDDEN$1="hidden.bs.tab",EVENT_SHOW$1="show.bs.tab",EVENT_SHOWN$1="shown.bs.tab",EVENT_CLICK_DATA_API="click.bs.tab",EVENT_KEYDOWN="keydown.bs.tab",EVENT_LOAD_DATA_API="load.bs.tab",ARROW_LEFT_KEY="ArrowLeft",ARROW_RIGHT_KEY="ArrowRight",ARROW_UP_KEY="ArrowUp",ARROW_DOWN_KEY="ArrowDown",CLASS_NAME_ACTIVE="active",CLASS_NAME_FADE$1="fade",CLASS_NAME_SHOW$1="show",CLASS_DROPDOWN="dropdown",SELECTOR_DROPDOWN_TOGGLE=".dropdown-toggle",SELECTOR_DROPDOWN_MENU=".dropdown-menu",NOT_SELECTOR_DROPDOWN_TOGGLE=":not(.dropdown-toggle)",SELECTOR_TAB_PANEL='.list-group, .nav, [role="tablist"]',SELECTOR_OUTER=".nav-item, .list-group-item",SELECTOR_INNER='.nav-link:not(.dropdown-toggle), .list-group-item:not(.dropdown-toggle), [role="tab"]:not(.dropdown-toggle)',SELECTOR_DATA_TOGGLE='[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',SELECTOR_INNER_ELEM=`${SELECTOR_INNER}, ${SELECTOR_DATA_TOGGLE}`,SELECTOR_DATA_TOGGLE_ACTIVE='.active[data-bs-toggle="tab"], .active[data-bs-toggle="pill"], .active[data-bs-toggle="list"]';class Tab extends BaseComponent{constructor(e){super(e),this._parent=this._element.closest(SELECTOR_TAB_PANEL),this._parent&&(this._setInitialAttributes(this._parent,this._getChildren()),EventHandler.on(this._element,EVENT_KEYDOWN,(e=>this._keydown(e))))}static get NAME(){return"tab"}show(){const e=this._element;if(this._elemIsActive(e))return;const t=this._getActiveElem(),n=t?EventHandler.trigger(t,EVENT_HIDE$1,{relatedTarget:e}):null;EventHandler.trigger(e,EVENT_SHOW$1,{relatedTarget:t}).defaultPrevented||n&&n.defaultPrevented||(this._deactivate(t,e),this._activate(e,t))}_activate(e,t){if(!e)return;e.classList.add("active"),this._activate(getElementFromSelector(e));this._queueCallback((()=>{"tab"===e.getAttribute("role")?(e.removeAttribute("tabindex"),e.setAttribute("aria-selected",!0),this._toggleDropDown(e,!0),EventHandler.trigger(e,EVENT_SHOWN$1,{relatedTarget:t})):e.classList.add("show")}),e,e.classList.contains("fade"))}_deactivate(e,t){if(!e)return;e.classList.remove("active"),e.blur(),this._deactivate(getElementFromSelector(e));this._queueCallback((()=>{"tab"===e.getAttribute("role")?(e.setAttribute("aria-selected",!1),e.setAttribute("tabindex","-1"),this._toggleDropDown(e,!1),EventHandler.trigger(e,EVENT_HIDDEN$1,{relatedTarget:t})):e.classList.remove("show")}),e,e.classList.contains("fade"))}_keydown(e){if(![ARROW_LEFT_KEY,ARROW_RIGHT_KEY,ARROW_UP_KEY,ARROW_DOWN_KEY].includes(e.key))return;e.stopPropagation(),e.preventDefault();const t=[ARROW_RIGHT_KEY,ARROW_DOWN_KEY].includes(e.key),n=getNextActiveElement(this._getChildren().filter((e=>!isDisabled(e))),e.target,t,!0);n&&(n.focus({preventScroll:!0}),Tab.getOrCreateInstance(n).show())}_getChildren(){return SelectorEngine.find(SELECTOR_INNER_ELEM,this._parent)}_getActiveElem(){return this._getChildren().find((e=>this._elemIsActive(e)))||null}_setInitialAttributes(e,t){this._setAttributeIfNotExists(e,"role","tablist");for(const e of t)this._setInitialAttributesOnChild(e)}_setInitialAttributesOnChild(e){e=this._getInnerElement(e);const t=this._elemIsActive(e),n=this._getOuterElement(e);e.setAttribute("aria-selected",t),n!==e&&this._setAttributeIfNotExists(n,"role","presentation"),t||e.setAttribute("tabindex","-1"),this._setAttributeIfNotExists(e,"role","tab"),this._setInitialAttributesOnTargetPanel(e)}_setInitialAttributesOnTargetPanel(e){const t=getElementFromSelector(e);t&&(this._setAttributeIfNotExists(t,"role","tabpanel"),e.id&&this._setAttributeIfNotExists(t,"aria-labelledby",`#${e.id}`))}_toggleDropDown(e,t){const n=this._getOuterElement(e);if(!n.classList.contains("dropdown"))return;const i=(e,i)=>{const s=SelectorEngine.findOne(e,n);s&&s.classList.toggle(i,t)};i(".dropdown-toggle","active"),i(".dropdown-menu","show"),n.setAttribute("aria-expanded",t)}_setAttributeIfNotExists(e,t,n){e.hasAttribute(t)||e.setAttribute(t,n)}_elemIsActive(e){return e.classList.contains("active")}_getInnerElement(e){return e.matches(SELECTOR_INNER_ELEM)?e:SelectorEngine.findOne(SELECTOR_INNER_ELEM,e)}_getOuterElement(e){return e.closest(SELECTOR_OUTER)||e}static jQueryInterface(e){return this.each((function(){const t=Tab.getOrCreateInstance(this);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}))}}EventHandler.on(document,"click.bs.tab",SELECTOR_DATA_TOGGLE,(function(e){["A","AREA"].includes(this.tagName)&&e.preventDefault(),isDisabled(this)||Tab.getOrCreateInstance(this).show()})),EventHandler.on(window,"load.bs.tab",(()=>{for(const e of SelectorEngine.find(SELECTOR_DATA_TOGGLE_ACTIVE))Tab.getOrCreateInstance(e)})),defineJQueryPlugin(Tab);const NAME="toast",DATA_KEY="bs.toast",EVENT_KEY=".bs.toast",EVENT_MOUSEOVER="mouseover.bs.toast",EVENT_MOUSEOUT="mouseout.bs.toast",EVENT_FOCUSIN="focusin.bs.toast",EVENT_FOCUSOUT="focusout.bs.toast",EVENT_HIDE="hide.bs.toast",EVENT_HIDDEN="hidden.bs.toast",EVENT_SHOW="show.bs.toast",EVENT_SHOWN="shown.bs.toast",CLASS_NAME_FADE="fade",CLASS_NAME_HIDE="hide",CLASS_NAME_SHOW="show",CLASS_NAME_SHOWING="showing",DefaultType={animation:"boolean",autohide:"boolean",delay:"number"},Default={animation:!0,autohide:!0,delay:5e3};class Toast extends BaseComponent{constructor(e,t){super(e,t),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get Default(){return Default}static get DefaultType(){return DefaultType}static get NAME(){return NAME}show(){if(EventHandler.trigger(this._element,EVENT_SHOW).defaultPrevented)return;this._clearTimeout(),this._config.animation&&this._element.classList.add("fade");this._element.classList.remove("hide"),reflow(this._element),this._element.classList.add("show","showing"),this._queueCallback((()=>{this._element.classList.remove("showing"),EventHandler.trigger(this._element,EVENT_SHOWN),this._maybeScheduleHide()}),this._element,this._config.animation)}hide(){if(!this.isShown())return;if(EventHandler.trigger(this._element,EVENT_HIDE).defaultPrevented)return;this._element.classList.add("showing"),this._queueCallback((()=>{this._element.classList.add("hide"),this._element.classList.remove("showing","show"),EventHandler.trigger(this._element,EVENT_HIDDEN)}),this._element,this._config.animation)}dispose(){this._clearTimeout(),this.isShown()&&this._element.classList.remove("show"),super.dispose()}isShown(){return this._element.classList.contains("show")}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout((()=>{this.hide()}),this._config.delay)))}_onInteraction(e,t){switch(e.type){case"mouseover":case"mouseout":this._hasMouseInteraction=t;break;case"focusin":case"focusout":this._hasKeyboardInteraction=t}if(t)return void this._clearTimeout();const n=e.relatedTarget;this._element===n||this._element.contains(n)||this._maybeScheduleHide()}_setListeners(){EventHandler.on(this._element,EVENT_MOUSEOVER,(e=>this._onInteraction(e,!0))),EventHandler.on(this._element,EVENT_MOUSEOUT,(e=>this._onInteraction(e,!1))),EventHandler.on(this._element,EVENT_FOCUSIN,(e=>this._onInteraction(e,!0))),EventHandler.on(this._element,EVENT_FOCUSOUT,(e=>this._onInteraction(e,!1)))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(e){return this.each((function(){const t=Toast.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}enableDismissTrigger(Toast),defineJQueryPlugin(Toast);var dropdownTriggerList=[].slice.call(document.querySelectorAll('[data-bs-toggle="dropdown"]'));dropdownTriggerList.map((function(e){var t={boundary:"viewport"===e.getAttribute("data-bs-boundary")?document.querySelector(".btn"):"clippingParents"};return new Dropdown(e,t)}));var tooltipTriggerList=[].slice.call(document.querySelectorAll('[data-bs-toggle="tooltip"]'));tooltipTriggerList.map((function(e){var t,n,i={delay:{show:50,hide:50},html:null!==(t="true"===e.getAttribute("data-bs-html"))&&void 0!==t&&t,placement:null!==(n=e.getAttribute("data-bs-placement"))&&void 0!==n?n:"auto"};return new Tooltip(e,i)}));var popoverTriggerList=[].slice.call(document.querySelectorAll('[data-bs-toggle="popover"]'));popoverTriggerList.map((function(e){var t,n,i={delay:{show:50,hide:50},html:null!==(t="true"===e.getAttribute("data-bs-html"))&&void 0!==t&&t,placement:null!==(n=e.getAttribute("data-bs-placement"))&&void 0!==n?n:"auto"};return new Popover(e,i)}));var switchesTriggerList=[].slice.call(document.querySelectorAll('[data-bs-toggle="switch-icon"]'));switchesTriggerList.map((function(e){e.addEventListener("click",(function(t){t.stopPropagation(),e.classList.toggle("active")}))}));var toastsTriggerList=[].slice.call(document.querySelectorAll('[data-bs-toggle="toast"]'));toastsTriggerList.map((function(e){return new Toast(e)}));
|