sep-yui 0.1.119 → 0.1.120
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/sep-yui.es.ts +2 -4
- package/dist/sep-yui.umd.ts +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/sep-yui.es.ts
CHANGED
|
@@ -59937,9 +59937,7 @@ const iDe = ["data-testid"], rDe = /* @__PURE__ */ ne({
|
|
|
59937
59937
|
disabled: { type: Boolean },
|
|
59938
59938
|
dataTestid: { default: "BaseFilter" }
|
|
59939
59939
|
}, {
|
|
59940
|
-
modelValue: {
|
|
59941
|
-
default: []
|
|
59942
|
-
},
|
|
59940
|
+
modelValue: {},
|
|
59943
59941
|
modelModifiers: {}
|
|
59944
59942
|
}),
|
|
59945
59943
|
emits: /* @__PURE__ */ Oi(["change", "unmount-open", "unmount-search", "unmount-search-enter", "unmount-pagination"], ["update:modelValue"]),
|
|
@@ -60132,7 +60130,7 @@ const iDe = ["data-testid"], rDe = /* @__PURE__ */ ne({
|
|
|
60132
60130
|
_: 1
|
|
60133
60131
|
}, 8, ["is-opened", "class", "data-testid"]));
|
|
60134
60132
|
}
|
|
60135
|
-
}), _M = /* @__PURE__ */ Se(gDe, [["__scopeId", "data-v-
|
|
60133
|
+
}), _M = /* @__PURE__ */ Se(gDe, [["__scopeId", "data-v-5f2b456d"]]), vDe = ["data-testid"], yDe = /* @__PURE__ */ ne({
|
|
60136
60134
|
name: "Range",
|
|
60137
60135
|
__name: "Range",
|
|
60138
60136
|
props: /* @__PURE__ */ Oi({
|
package/dist/sep-yui.umd.ts
CHANGED
|
@@ -1295,7 +1295,7 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
1295
1295
|
* Copyright 2021 Hyunje Jun, MDBootstrap and Contributors
|
|
1296
1296
|
* Licensed under MIT
|
|
1297
1297
|
*/function Ri(e){return getComputedStyle(e)}function Cn(e,t){for(var n in t){var i=t[n];typeof i=="number"&&(i=i+"px"),e.style[n]=i}return e}function Vd(e){var t=document.createElement("div");return t.className=e,t}var f4=typeof Element<"u"&&(Element.prototype.matches||Element.prototype.webkitMatchesSelector||Element.prototype.mozMatchesSelector||Element.prototype.msMatchesSelector);function $r(e,t){if(!f4)throw new Error("No element matching method supported");return f4.call(e,t)}function Yo(e){e.remove?e.remove():e.parentNode&&e.parentNode.removeChild(e)}function h4(e,t){return Array.prototype.filter.call(e.children,function(n){return $r(n,t)})}var vt={main:"ps",rtl:"ps__rtl",element:{thumb:function(e){return"ps__thumb-"+e},rail:function(e){return"ps__rail-"+e},consuming:"ps__child--consume"},state:{focus:"ps--focus",clicking:"ps--clicking",active:function(e){return"ps--active-"+e},scrolling:function(e){return"ps--scrolling-"+e}}},m4={x:null,y:null};function p4(e,t){var n=e.element.classList,i=vt.state.scrolling(t);n.contains(i)?clearTimeout(m4[t]):n.add(i)}function g4(e,t){m4[t]=setTimeout(function(){return e.isAlive&&e.element.classList.remove(vt.state.scrolling(t))},e.settings.scrollingThreshold)}function a8e(e,t){p4(e,t),g4(e,t)}var vl=function(t){this.element=t,this.handlers={}},y4={isEmpty:{configurable:!0}};vl.prototype.bind=function(t,n){typeof this.handlers[t]>"u"&&(this.handlers[t]=[]),this.handlers[t].push(n),this.element.addEventListener(t,n,!1)},vl.prototype.unbind=function(t,n){var i=this;this.handlers[t]=this.handlers[t].filter(function(r){return n&&r!==n?!0:(i.element.removeEventListener(t,r,!1),!1)})},vl.prototype.unbindAll=function(){for(var t in this.handlers)this.unbind(t)},y4.isEmpty.get=function(){var e=this;return Object.keys(this.handlers).every(function(t){return e.handlers[t].length===0})},Object.defineProperties(vl.prototype,y4);var Xo=function(){this.eventElements=[]};Xo.prototype.eventElement=function(t){var n=this.eventElements.filter(function(i){return i.element===t})[0];return n||(n=new vl(t),this.eventElements.push(n)),n},Xo.prototype.bind=function(t,n,i){this.eventElement(t).bind(n,i)},Xo.prototype.unbind=function(t,n,i){var r=this.eventElement(t);r.unbind(n,i),r.isEmpty&&this.eventElements.splice(this.eventElements.indexOf(r),1)},Xo.prototype.unbindAll=function(){this.eventElements.forEach(function(t){return t.unbindAll()}),this.eventElements=[]},Xo.prototype.once=function(t,n,i){var r=this.eventElement(t),a=function(o){r.unbind(n,a),i(o)};r.bind(n,a)};function Fd(e){if(typeof window.CustomEvent=="function")return new CustomEvent(e);var t=document.createEvent("CustomEvent");return t.initCustomEvent(e,!1,!1,void 0),t}function Ud(e,t,n,i,r){i===void 0&&(i=!0),r===void 0&&(r=!1);var a;if(t==="top")a=["contentHeight","containerHeight","scrollTop","y","up","down"];else if(t==="left")a=["contentWidth","containerWidth","scrollLeft","x","left","right"];else throw new Error("A proper axis should be provided");o8e(e,n,a,i,r)}function o8e(e,t,n,i,r){var a=n[0],o=n[1],s=n[2],u=n[3],c=n[4],f=n[5];i===void 0&&(i=!0),r===void 0&&(r=!1);var h=e.element;e.reach[u]=null,h[s]<1&&(e.reach[u]="start"),h[s]>e[a]-e[o]-1&&(e.reach[u]="end"),t&&(h.dispatchEvent(Fd("ps-scroll-"+u)),t<0?h.dispatchEvent(Fd("ps-scroll-"+c)):t>0&&h.dispatchEvent(Fd("ps-scroll-"+f)),i&&a8e(e,u)),e.reach[u]&&(t||r)&&h.dispatchEvent(Fd("ps-"+u+"-reach-"+e.reach[u]))}function st(e){return parseInt(e,10)||0}function s8e(e){return $r(e,"input,[contenteditable]")||$r(e,"select,[contenteditable]")||$r(e,"textarea,[contenteditable]")||$r(e,"button,[contenteditable]")}function l8e(e){var t=Ri(e);return st(t.width)+st(t.paddingLeft)+st(t.paddingRight)+st(t.borderLeftWidth)+st(t.borderRightWidth)}var qo={isWebKit:typeof document<"u"&&"WebkitAppearance"in document.documentElement.style,supportsTouch:typeof window<"u"&&("ontouchstart"in window||"maxTouchPoints"in window.navigator&&window.navigator.maxTouchPoints>0||window.DocumentTouch&&document instanceof window.DocumentTouch),supportsIePointer:typeof navigator<"u"&&navigator.msMaxTouchPoints,isChrome:typeof navigator<"u"&&/Chrome/i.test(navigator&&navigator.userAgent)};function rr(e){var t=e.element,n=Math.floor(t.scrollTop),i=t.getBoundingClientRect();e.containerWidth=Math.round(i.width),e.containerHeight=Math.round(i.height),e.contentWidth=t.scrollWidth,e.contentHeight=t.scrollHeight,t.contains(e.scrollbarXRail)||(h4(t,vt.element.rail("x")).forEach(function(r){return Yo(r)}),t.appendChild(e.scrollbarXRail)),t.contains(e.scrollbarYRail)||(h4(t,vt.element.rail("y")).forEach(function(r){return Yo(r)}),t.appendChild(e.scrollbarYRail)),!e.settings.suppressScrollX&&e.containerWidth+e.settings.scrollXMarginOffset<e.contentWidth?(e.scrollbarXActive=!0,e.railXWidth=e.containerWidth-e.railXMarginWidth,e.railXRatio=e.containerWidth/e.railXWidth,e.scrollbarXWidth=b4(e,st(e.railXWidth*e.containerWidth/e.contentWidth)),e.scrollbarXLeft=st((e.negativeScrollAdjustment+t.scrollLeft)*(e.railXWidth-e.scrollbarXWidth)/(e.contentWidth-e.containerWidth))):e.scrollbarXActive=!1,!e.settings.suppressScrollY&&e.containerHeight+e.settings.scrollYMarginOffset<e.contentHeight?(e.scrollbarYActive=!0,e.railYHeight=e.containerHeight-e.railYMarginHeight,e.railYRatio=e.containerHeight/e.railYHeight,e.scrollbarYHeight=b4(e,st(e.railYHeight*e.containerHeight/e.contentHeight)),e.scrollbarYTop=st(n*(e.railYHeight-e.scrollbarYHeight)/(e.contentHeight-e.containerHeight))):e.scrollbarYActive=!1,e.scrollbarXLeft>=e.railXWidth-e.scrollbarXWidth&&(e.scrollbarXLeft=e.railXWidth-e.scrollbarXWidth),e.scrollbarYTop>=e.railYHeight-e.scrollbarYHeight&&(e.scrollbarYTop=e.railYHeight-e.scrollbarYHeight),u8e(t,e),e.scrollbarXActive?t.classList.add(vt.state.active("x")):(t.classList.remove(vt.state.active("x")),e.scrollbarXWidth=0,e.scrollbarXLeft=0,t.scrollLeft=e.isRtl===!0?e.contentWidth:0),e.scrollbarYActive?t.classList.add(vt.state.active("y")):(t.classList.remove(vt.state.active("y")),e.scrollbarYHeight=0,e.scrollbarYTop=0,t.scrollTop=0)}function b4(e,t){return e.settings.minScrollbarLength&&(t=Math.max(t,e.settings.minScrollbarLength)),e.settings.maxScrollbarLength&&(t=Math.min(t,e.settings.maxScrollbarLength)),t}function u8e(e,t){var n={width:t.railXWidth},i=Math.floor(e.scrollTop);t.isRtl?n.left=t.negativeScrollAdjustment+e.scrollLeft+t.containerWidth-t.contentWidth:n.left=e.scrollLeft,t.isScrollbarXUsingBottom?n.bottom=t.scrollbarXBottom-i:n.top=t.scrollbarXTop+i,Cn(t.scrollbarXRail,n);var r={top:i,height:t.railYHeight};t.isScrollbarYUsingRight?t.isRtl?r.right=t.contentWidth-(t.negativeScrollAdjustment+e.scrollLeft)-t.scrollbarYRight-t.scrollbarYOuterWidth-9:r.right=t.scrollbarYRight-e.scrollLeft:t.isRtl?r.left=t.negativeScrollAdjustment+e.scrollLeft+t.containerWidth*2-t.contentWidth-t.scrollbarYLeft-t.scrollbarYOuterWidth:r.left=t.scrollbarYLeft+e.scrollLeft,Cn(t.scrollbarYRail,r),Cn(t.scrollbarX,{left:t.scrollbarXLeft,width:t.scrollbarXWidth-t.railBorderXWidth}),Cn(t.scrollbarY,{top:t.scrollbarYTop,height:t.scrollbarYHeight-t.railBorderYWidth})}function d8e(e){e.element,e.event.bind(e.scrollbarY,"mousedown",function(t){return t.stopPropagation()}),e.event.bind(e.scrollbarYRail,"mousedown",function(t){var n=t.pageY-window.pageYOffset-e.scrollbarYRail.getBoundingClientRect().top,i=n>e.scrollbarYTop?1:-1;e.element.scrollTop+=i*e.containerHeight,rr(e),t.stopPropagation()}),e.event.bind(e.scrollbarX,"mousedown",function(t){return t.stopPropagation()}),e.event.bind(e.scrollbarXRail,"mousedown",function(t){var n=t.pageX-window.pageXOffset-e.scrollbarXRail.getBoundingClientRect().left,i=n>e.scrollbarXLeft?1:-1;e.element.scrollLeft+=i*e.containerWidth,rr(e),t.stopPropagation()})}function c8e(e){w4(e,["containerWidth","contentWidth","pageX","railXWidth","scrollbarX","scrollbarXWidth","scrollLeft","x","scrollbarXRail"]),w4(e,["containerHeight","contentHeight","pageY","railYHeight","scrollbarY","scrollbarYHeight","scrollTop","y","scrollbarYRail"])}function w4(e,t){var n=t[0],i=t[1],r=t[2],a=t[3],o=t[4],s=t[5],u=t[6],c=t[7],f=t[8],h=e.element,g=null,p=null,y=null;function v(M){M.touches&&M.touches[0]&&(M[r]=M.touches[0].pageY),h[u]=g+y*(M[r]-p),p4(e,c),rr(e),M.stopPropagation(),M.type.startsWith("touch")&&M.changedTouches.length>1&&M.preventDefault()}function k(){g4(e,c),e[f].classList.remove(vt.state.clicking),e.event.unbind(e.ownerDocument,"mousemove",v)}function w(M,x){g=h[u],x&&M.touches&&(M[r]=M.touches[0].pageY),p=M[r],y=(e[i]-e[n])/(e[a]-e[s]),x?e.event.bind(e.ownerDocument,"touchmove",v):(e.event.bind(e.ownerDocument,"mousemove",v),e.event.once(e.ownerDocument,"mouseup",k),M.preventDefault()),e[f].classList.add(vt.state.clicking),M.stopPropagation()}e.event.bind(e[o],"mousedown",function(M){w(M)}),e.event.bind(e[o],"touchstart",function(M){w(M,!0)})}function f8e(e){var t=e.element,n=function(){return $r(t,":hover")},i=function(){return $r(e.scrollbarX,":focus")||$r(e.scrollbarY,":focus")};function r(a,o){var s=Math.floor(t.scrollTop);if(a===0){if(!e.scrollbarYActive)return!1;if(s===0&&o>0||s>=e.contentHeight-e.containerHeight&&o<0)return!e.settings.wheelPropagation}var u=t.scrollLeft;if(o===0){if(!e.scrollbarXActive)return!1;if(u===0&&a<0||u>=e.contentWidth-e.containerWidth&&a>0)return!e.settings.wheelPropagation}return!0}e.event.bind(e.ownerDocument,"keydown",function(a){if(!(a.isDefaultPrevented&&a.isDefaultPrevented()||a.defaultPrevented)&&!(!n()&&!i())){var o=document.activeElement?document.activeElement:e.ownerDocument.activeElement;if(o){if(o.tagName==="IFRAME")o=o.contentDocument.activeElement;else for(;o.shadowRoot;)o=o.shadowRoot.activeElement;if(s8e(o))return}var s=0,u=0;switch(a.which){case 37:a.metaKey?s=-e.contentWidth:a.altKey?s=-e.containerWidth:s=-30;break;case 38:a.metaKey?u=e.contentHeight:a.altKey?u=e.containerHeight:u=30;break;case 39:a.metaKey?s=e.contentWidth:a.altKey?s=e.containerWidth:s=30;break;case 40:a.metaKey?u=-e.contentHeight:a.altKey?u=-e.containerHeight:u=-30;break;case 32:a.shiftKey?u=e.containerHeight:u=-e.containerHeight;break;case 33:u=e.containerHeight;break;case 34:u=-e.containerHeight;break;case 36:u=e.contentHeight;break;case 35:u=-e.contentHeight;break;default:return}e.settings.suppressScrollX&&s!==0||e.settings.suppressScrollY&&u!==0||(t.scrollTop-=u,t.scrollLeft+=s,rr(e),r(s,u)&&a.preventDefault())}})}function h8e(e){var t=e.element;function n(o,s){var u=Math.floor(t.scrollTop),c=t.scrollTop===0,f=u+t.offsetHeight===t.scrollHeight,h=t.scrollLeft===0,g=t.scrollLeft+t.offsetWidth===t.scrollWidth,p;return Math.abs(s)>Math.abs(o)?p=c||f:p=h||g,p?!e.settings.wheelPropagation:!0}function i(o){var s=o.deltaX,u=-1*o.deltaY;return(typeof s>"u"||typeof u>"u")&&(s=-1*o.wheelDeltaX/6,u=o.wheelDeltaY/6),o.deltaMode&&o.deltaMode===1&&(s*=10,u*=10),s!==s&&u!==u&&(s=0,u=o.wheelDelta),o.shiftKey?[-u,-s]:[s,u]}function r(o,s,u){if(!qo.isWebKit&&t.querySelector("select:focus"))return!0;if(!t.contains(o))return!1;for(var c=o;c&&c!==t;){if(c.classList.contains(vt.element.consuming))return!0;var f=Ri(c);if(u&&f.overflowY.match(/(scroll|auto)/)){var h=c.scrollHeight-c.clientHeight;if(h>0&&(c.scrollTop>0&&u<0||c.scrollTop<h&&u>0))return!0}if(s&&f.overflowX.match(/(scroll|auto)/)){var g=c.scrollWidth-c.clientWidth;if(g>0&&(c.scrollLeft>0&&s<0||c.scrollLeft<g&&s>0))return!0}c=c.parentNode}return!1}function a(o){var s=i(o),u=s[0],c=s[1];if(!r(o.target,u,c)){var f=!1;e.settings.useBothWheelAxes?e.scrollbarYActive&&!e.scrollbarXActive?(c?t.scrollTop-=c*e.settings.wheelSpeed:t.scrollTop+=u*e.settings.wheelSpeed,f=!0):e.scrollbarXActive&&!e.scrollbarYActive&&(u?t.scrollLeft+=u*e.settings.wheelSpeed:t.scrollLeft-=c*e.settings.wheelSpeed,f=!0):(t.scrollTop-=c*e.settings.wheelSpeed,t.scrollLeft+=u*e.settings.wheelSpeed),rr(e),f=f||n(u,c),f&&!o.ctrlKey&&(o.stopPropagation(),o.preventDefault())}}typeof window.onwheel<"u"?e.event.bind(t,"wheel",a):typeof window.onmousewheel<"u"&&e.event.bind(t,"mousewheel",a)}function m8e(e){if(!qo.supportsTouch&&!qo.supportsIePointer)return;var t=e.element;function n(y,v){var k=Math.floor(t.scrollTop),w=t.scrollLeft,M=Math.abs(y),x=Math.abs(v);if(x>M){if(v<0&&k===e.contentHeight-e.containerHeight||v>0&&k===0)return window.scrollY===0&&v>0&&qo.isChrome}else if(M>x&&(y<0&&w===e.contentWidth-e.containerWidth||y>0&&w===0))return!0;return!0}function i(y,v){t.scrollTop-=v,t.scrollLeft-=y,rr(e)}var r={},a=0,o={},s=null;function u(y){return y.targetTouches?y.targetTouches[0]:y}function c(y){return y.pointerType&&y.pointerType==="pen"&&y.buttons===0?!1:!!(y.targetTouches&&y.targetTouches.length===1||y.pointerType&&y.pointerType!=="mouse"&&y.pointerType!==y.MSPOINTER_TYPE_MOUSE)}function f(y){if(c(y)){var v=u(y);r.pageX=v.pageX,r.pageY=v.pageY,a=new Date().getTime(),s!==null&&clearInterval(s)}}function h(y,v,k){if(!t.contains(y))return!1;for(var w=y;w&&w!==t;){if(w.classList.contains(vt.element.consuming))return!0;var M=Ri(w);if(k&&M.overflowY.match(/(scroll|auto)/)){var x=w.scrollHeight-w.clientHeight;if(x>0&&(w.scrollTop>0&&k<0||w.scrollTop<x&&k>0))return!0}if(v&&M.overflowX.match(/(scroll|auto)/)){var S=w.scrollWidth-w.clientWidth;if(S>0&&(w.scrollLeft>0&&v<0||w.scrollLeft<S&&v>0))return!0}w=w.parentNode}return!1}function g(y){if(c(y)){var v=u(y),k={pageX:v.pageX,pageY:v.pageY},w=k.pageX-r.pageX,M=k.pageY-r.pageY;if(h(y.target,w,M))return;i(w,M),r=k;var x=new Date().getTime(),S=x-a;S>0&&(o.x=w/S,o.y=M/S,a=x),n(w,M)&&y.preventDefault()}}function p(){e.settings.swipeEasing&&(clearInterval(s),s=setInterval(function(){if(e.isInitialized){clearInterval(s);return}if(!o.x&&!o.y){clearInterval(s);return}if(Math.abs(o.x)<.01&&Math.abs(o.y)<.01){clearInterval(s);return}if(!e.element){clearInterval(s);return}i(o.x*30,o.y*30),o.x*=.8,o.y*=.8},10))}qo.supportsTouch?(e.event.bind(t,"touchstart",f),e.event.bind(t,"touchmove",g),e.event.bind(t,"touchend",p)):qo.supportsIePointer&&(window.PointerEvent?(e.event.bind(t,"pointerdown",f),e.event.bind(t,"pointermove",g),e.event.bind(t,"pointerup",p)):window.MSPointerEvent&&(e.event.bind(t,"MSPointerDown",f),e.event.bind(t,"MSPointerMove",g),e.event.bind(t,"MSPointerUp",p)))}var p8e=function(){return{handlers:["click-rail","drag-thumb","keyboard","wheel","touch"],maxScrollbarLength:null,minScrollbarLength:null,scrollingThreshold:1e3,scrollXMarginOffset:0,scrollYMarginOffset:0,suppressScrollX:!1,suppressScrollY:!1,swipeEasing:!0,useBothWheelAxes:!1,wheelPropagation:!0,wheelSpeed:1}},g8e={"click-rail":d8e,"drag-thumb":c8e,keyboard:f8e,wheel:h8e,touch:m8e},kl=function(t,n){var i=this;if(n===void 0&&(n={}),typeof t=="string"&&(t=document.querySelector(t)),!t||!t.nodeName)throw new Error("no element is specified to initialize PerfectScrollbar");this.element=t,t.classList.add(vt.main),this.settings=p8e();for(var r in n)this.settings[r]=n[r];this.containerWidth=null,this.containerHeight=null,this.contentWidth=null,this.contentHeight=null;var a=function(){return t.classList.add(vt.state.focus)},o=function(){return t.classList.remove(vt.state.focus)};this.isRtl=Ri(t).direction==="rtl",this.isRtl===!0&&t.classList.add(vt.rtl),this.isNegativeScroll=function(){var c=t.scrollLeft,f=null;return t.scrollLeft=-1,f=t.scrollLeft<0,t.scrollLeft=c,f}(),this.negativeScrollAdjustment=this.isNegativeScroll?t.scrollWidth-t.clientWidth:0,this.event=new Xo,this.ownerDocument=t.ownerDocument||document,this.scrollbarXRail=Vd(vt.element.rail("x")),t.appendChild(this.scrollbarXRail),this.scrollbarX=Vd(vt.element.thumb("x")),this.scrollbarXRail.appendChild(this.scrollbarX),this.scrollbarX.setAttribute("tabindex",0),this.event.bind(this.scrollbarX,"focus",a),this.event.bind(this.scrollbarX,"blur",o),this.scrollbarXActive=null,this.scrollbarXWidth=null,this.scrollbarXLeft=null;var s=Ri(this.scrollbarXRail);this.scrollbarXBottom=parseInt(s.bottom,10),isNaN(this.scrollbarXBottom)?(this.isScrollbarXUsingBottom=!1,this.scrollbarXTop=st(s.top)):this.isScrollbarXUsingBottom=!0,this.railBorderXWidth=st(s.borderLeftWidth)+st(s.borderRightWidth),Cn(this.scrollbarXRail,{display:"block"}),this.railXMarginWidth=st(s.marginLeft)+st(s.marginRight),Cn(this.scrollbarXRail,{display:""}),this.railXWidth=null,this.railXRatio=null,this.scrollbarYRail=Vd(vt.element.rail("y")),t.appendChild(this.scrollbarYRail),this.scrollbarY=Vd(vt.element.thumb("y")),this.scrollbarYRail.appendChild(this.scrollbarY),this.scrollbarY.setAttribute("tabindex",0),this.event.bind(this.scrollbarY,"focus",a),this.event.bind(this.scrollbarY,"blur",o),this.scrollbarYActive=null,this.scrollbarYHeight=null,this.scrollbarYTop=null;var u=Ri(this.scrollbarYRail);this.scrollbarYRight=parseInt(u.right,10),isNaN(this.scrollbarYRight)?(this.isScrollbarYUsingRight=!1,this.scrollbarYLeft=st(u.left)):this.isScrollbarYUsingRight=!0,this.scrollbarYOuterWidth=this.isRtl?l8e(this.scrollbarY):null,this.railBorderYWidth=st(u.borderTopWidth)+st(u.borderBottomWidth),Cn(this.scrollbarYRail,{display:"block"}),this.railYMarginHeight=st(u.marginTop)+st(u.marginBottom),Cn(this.scrollbarYRail,{display:""}),this.railYHeight=null,this.railYRatio=null,this.reach={x:t.scrollLeft<=0?"start":t.scrollLeft>=this.contentWidth-this.containerWidth?"end":null,y:t.scrollTop<=0?"start":t.scrollTop>=this.contentHeight-this.containerHeight?"end":null},this.isAlive=!0,this.settings.handlers.forEach(function(c){return g8e[c](i)}),this.lastScrollTop=Math.floor(t.scrollTop),this.lastScrollLeft=t.scrollLeft,this.event.bind(this.element,"scroll",function(c){return i.onScroll(c)}),rr(this)};kl.prototype.update=function(){this.isAlive&&(this.negativeScrollAdjustment=this.isNegativeScroll?this.element.scrollWidth-this.element.clientWidth:0,Cn(this.scrollbarXRail,{display:"block"}),Cn(this.scrollbarYRail,{display:"block"}),this.railXMarginWidth=st(Ri(this.scrollbarXRail).marginLeft)+st(Ri(this.scrollbarXRail).marginRight),this.railYMarginHeight=st(Ri(this.scrollbarYRail).marginTop)+st(Ri(this.scrollbarYRail).marginBottom),Cn(this.scrollbarXRail,{display:"none"}),Cn(this.scrollbarYRail,{display:"none"}),rr(this),Ud(this,"top",0,!1,!0),Ud(this,"left",0,!1,!0),Cn(this.scrollbarXRail,{display:""}),Cn(this.scrollbarYRail,{display:""}))},kl.prototype.onScroll=function(t){this.isAlive&&(rr(this),Ud(this,"top",this.element.scrollTop-this.lastScrollTop),Ud(this,"left",this.element.scrollLeft-this.lastScrollLeft),this.lastScrollTop=Math.floor(this.element.scrollTop),this.lastScrollLeft=this.element.scrollLeft)},kl.prototype.destroy=function(){this.isAlive&&(this.event.unbindAll(),Yo(this.scrollbarX),Yo(this.scrollbarY),Yo(this.scrollbarXRail),Yo(this.scrollbarYRail),this.removePsClasses(),this.element=null,this.scrollbarX=null,this.scrollbarY=null,this.scrollbarXRail=null,this.scrollbarYRail=null,this.isAlive=!1)},kl.prototype.removePsClasses=function(){this.element.className=this.element.className.split(" ").filter(function(t){return!t.match(/^ps([-_].+|)$/)}).join(" ")};const y8e=l.defineComponent({__name:"PerfectScrollbar",props:{tag:{default:"div"},options:{default:()=>({})}},emits:["scroll","ps-scroll-y","ps-scroll-x","ps-scroll-up","ps-scroll-down","ps-scroll-left","ps-scroll-right","ps-y-reach-start","ps-y-reach-end","ps-x-reach-start","ps-x-reach-end"],setup(e,{expose:t,emit:n}){const i=e,r=n,a=l.ref(null),o=l.ref(null);l.watch(()=>i.options,()=>{u(),s()},{deep:!0}),l.onMounted(()=>{a.value&&s()}),l.onBeforeUnmount(()=>{u()});function s(){a.value&&(o.value=new kl(a.value,i.options),h())}function u(){o.value&&(h(!1),o.value.destroy(),o.value=null)}const c={scroll:f("scroll"),"ps-scroll-y":f("ps-scroll-y"),"ps-scroll-x":f("ps-scroll-x"),"ps-scroll-up":f("ps-scroll-up"),"ps-scroll-down":f("ps-scroll-down"),"ps-scroll-left":f("ps-scroll-left"),"ps-scroll-right":f("ps-scroll-right"),"ps-y-reach-start":f("ps-y-reach-start"),"ps-y-reach-end":f("ps-y-reach-end"),"ps-x-reach-start":f("ps-x-reach-start"),"ps-x-reach-end":f("ps-x-reach-end")};function f(g){return function(p){r(g,p)}}function h(g=!0){var p;(p=o.value)!=null&&p.element&&Object.entries(c).forEach(([y,v])=>{var k,w;g?(k=o.value)==null||k.element.addEventListener(y,v):(w=o.value)==null||w.element.removeEventListener(y,v)})}return t({ps:o}),(g,p)=>(l.openBlock(),l.createBlock(l.resolveDynamicComponent(g.tag),{ref_key:"scrollbar",ref:a,class:"ps"},{default:l.withCtx(()=>[l.renderSlot(g.$slots,"default")]),_:3},512))}}),b8e=["data-testid"],A1=l.defineComponent({__name:"Scrollbar",props:{options:{},tag:{},class:{},style:{},thrumbStyle:{},railStyle:{},dataTestid:{default:"ScrollBar"}},emits:["scroll","ps-scroll-y","ps-scroll-x","ps-scroll-up","ps-scroll-down","ps-scroll-left","ps-scroll-right","ps-y-reach-start","ps-y-reach-end","ps-x-reach-start","ps-x-reach-end"],setup(e,{expose:t,emit:n}){const i=e,r=l.ref(null),a=n,o=h=>{a("scroll",h)},s={attributes:!0,attributeFilter:["style"]},u=(h,g)=>p=>{for(const y of p)y.type==="attributes"&&y.attributeName==="style"&&h.style.right!==g&&(h.style.right=g)},c=()=>{var w,M,x,S,_,j,T,I,L,N,z,H,X,re,ee,q,Z,ue,De,rt,xt,Qt,Rt,qe;if(!r.value)return;const h=r.value.querySelector(".ps__thumb-y"),g=r.value.querySelector(".ps__thumb-x"),p=r.value.querySelector(".ps__rail-y"),y=r.value.querySelector(".ps__rail-x");h.style.background=((M=(w=i.thrumbStyle)==null?void 0:w.y)==null?void 0:M.background)||"#77a6ff",h.style.width=((S=(x=i.thrumbStyle)==null?void 0:x.y)==null?void 0:S.width)||"6px",h.style.right="0px",g.style.background=((j=(_=i.thrumbStyle)==null?void 0:_.x)==null?void 0:j.background)||"#77a6ff",g.style.width=((I=(T=i.thrumbStyle)==null?void 0:T.x)==null?void 0:I.width)||"6px",g.style.right="0px",p.style.background=((N=(L=i.railStyle)==null?void 0:L.y)==null?void 0:N.background)||"#F5F5F5",p.style.width=((H=(z=i.thrumbStyle)==null?void 0:z.y)==null?void 0:H.width)||"6px",p.style.right=((re=(X=i.railStyle)==null?void 0:X.y)==null?void 0:re.right)||"0px",y.style.background=((q=(ee=i.railStyle)==null?void 0:ee.x)==null?void 0:q.background)||"#F5F5F5",y.style.width=((ue=(Z=i.thrumbStyle)==null?void 0:Z.x)==null?void 0:ue.width)||"6px",y.style.right=((rt=(De=i.railStyle)==null?void 0:De.x)==null?void 0:rt.right)||"0px";const v=new MutationObserver(u(p,((Qt=(xt=i.railStyle)==null?void 0:xt.y)==null?void 0:Qt.right)||"0px")),k=new MutationObserver(u(y,((qe=(Rt=i.railStyle)==null?void 0:Rt.x)==null?void 0:qe.right)||"0px"));v.observe(p,s),k.observe(y,s)};return l.watch(()=>i,()=>{c()},{immediate:!0}),t({scrollToTop:()=>{r.value&&(r.value.children[0].scrollTop=0)}}),l.onMounted(()=>{c()}),(h,g)=>(l.openBlock(),l.createElementBlock("div",{ref_key:"scrollbar",ref:r,"data-testid":i.dataTestid},[l.createVNode(l.unref(y8e),{onScroll:o,options:i.options,tag:i.tag,class:l.normalizeClass(i.class),style:l.normalizeStyle(i.style),"data-testid":`${i.dataTestid}-Scroll`,ref_key:"scrollbar",ref:r},{default:l.withCtx(()=>[l.renderSlot(h.$slots,"default")]),_:3},8,["options","tag","class","style","data-testid"])],8,b8e))}});function Pt(e,t=document.documentElement){for(const[n,i]of Object.entries(e))t.style.setProperty(n,String(i))}const w8e=()=>{const e=l.ref(0),t=l.ref([]),n=l.ref(null),i=u=>{t.value.push(u),a(u),o()},r=()=>{t.value.pop(),s(),t.value.length?a(t.value[t.value.length-1]):n.value=null},a=u=>{n.value=u},o=()=>{e.value+=1},s=()=>{e.value>0&&(e.value-=1)};return{countOpenedModal:e,openedModals:t,lastOpenedModal:n,addOpenedModal:i,reduceOpenedModal:r,setLastOpenedModal:a,incrementCountModal:o,decrementCountModal:s}},v8e=["data-testid"],k8e=["data-testid"],M8e=me(l.defineComponent({__name:"Modal",props:{open:{type:Boolean},position:{default:"right"},width:{},height:{},dataTestid:{default:"Modal"}},emits:["close","unmounted"],setup(e,{expose:t,emit:n}){const{lastOpenedModal:i,addOpenedModal:r,reduceOpenedModal:a}=w8e(),o=e,s=l.ref(null),u=l.useAttrs(),c=l.ref(!1),f=l.computed(()=>({width:o.width,height:o.height})),h=n;let g=0;const p=()=>{g=Date.now(),s.value&&(o.open?(s.value.showModal(),r(s.value)):y())},y=()=>{Date.now()-g<300||(a(),h("close"))},v=()=>{var S;(S=s.value)==null||S.close(),document.documentElement.focus(),M()},k=S=>{S.key==="Escape"&&i.value===s.value&&y()},w=()=>{if(document.querySelectorAll(".modal-yui-kit").length===1)return window.innerWidth-document.documentElement.clientWidth;{const _=document.body.style.paddingRight;return Number(_.replace(/\D/g,""))||0}},M=()=>{document.querySelectorAll(".modal-yui-kit").length===0&&Pt({overflow:"","padding-right":""},document.body)},x=S=>{S.target===s.value&&y()};return t({closeDialog:v}),l.onMounted(()=>{l.watchEffect(()=>{o.open!==c.value&&(p(),c.value=o.open)}),s.value&&s.value.addEventListener("cancel",_=>{_.preventDefault()});const S=w();Pt({overflow:"hidden","padding-right":`${S}px`},document.body),document.addEventListener("keydown",k)}),l.onUnmounted(()=>{M(),document.removeEventListener("keydown",k),h("unmounted")}),(S,_)=>(l.openBlock(),l.createElementBlock("dialog",l.mergeProps({ref_key:"dialog",ref:s},l.unref(u),{class:["modal-yui-kit",`modal-yui-kit_${o.position}`],"data-testid":o.dataTestid,onClick:l.withModifiers(x,["self","left"])}),[l.createElementVNode("div",{class:"modal-yui-kit__modal-content",style:l.normalizeStyle(f.value),"data-testid":`${o.dataTestid}-ModalContent`},[l.renderSlot(S.$slots,"default",{},void 0,!0)],12,k8e)],16,v8e))}}),[["__scopeId","data-v-14e41eb3"]]);var Yd=(e=>(e.right="right",e.fade="fade",e))(Yd||{});const C8e=l.defineComponent({__name:"ModalAnimated",props:{animateType:{default:Yd.right},open:{type:Boolean},position:{default:"right"},width:{},height:{},dataTestid:{default:"Modal"}},emits:["close","unmounted","end-animation"],setup(e,{emit:t}){const n=e,i=t,r=l.computed(()=>{switch(n.animateType){case Yd.fade:return"fade";case Yd.right:return"modal";default:return"modal"}}),a=l.ref(null),o=l.reactive({function:()=>{}}),s=()=>{h()},u=()=>{i("unmounted")},c=()=>{h()},f=()=>{o.function(),i("end-animation")},h=()=>{var p;a.value&&(o.function=(p=a.value)==null?void 0:p.closeDialog)},g=()=>{h(),i("close")};return(p,y)=>(l.openBlock(),l.createBlock(l.Transition,{name:r.value,onAfterLeave:f,onBeforeLeave:c,onAfterEnter:s},{default:l.withCtx(()=>[n.open?(l.openBlock(),l.createBlock(M8e,{key:0,ref_key:"modalRef",ref:a,open:n.open,position:n.position,width:n.width,height:n.height,"data-testid":n.dataTestid,onClose:g,onUnmounted:u},{default:l.withCtx(()=>[l.renderSlot(p.$slots,"default",{},void 0,!0)]),_:3},8,["open","position","width","height","data-testid"])):l.createCommentVNode("",!0)]),_:3},8,["name"]))}}),Xd=me(C8e,[["__scopeId","data-v-b1e40efb"]]);var qd=(e=>(e.small="small",e.medium="medium",e.big="big",e))(qd||{}),v4=(e=>(e.circled="circled",e.rounded="rounded",e))(v4||{});const x8e=["data-testid","checked","disabled"],S8e=l.defineComponent({__name:"Checkbox",props:{size:{default:qd.medium},circular:{default:v4.rounded},checked:{type:Boolean},modelValue:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},dataTestid:{default:"Checkbox"}},emits:["change","update:modelValue"],setup(e,{emit:t}){const n=e,i=t,r=l.reactive({isChecked:n.modelValue});l.watchEffect(()=>{r.isChecked=n.modelValue});const a=()=>{r.isChecked=!r.isChecked,i("change",r.isChecked),i("update:modelValue",r.isChecked)};return(o,s)=>(l.openBlock(),l.createElementBlock("input",{type:"checkbox",class:l.normalizeClass(`checkbox-yui-kit checkbox-yui-kit_${n.size} checkbox-yui-kit_${n.circular}`),"data-testid":`${n.dataTestid}`,tabindex:"0",onChange:a,checked:r.isChecked,disabled:n.disabled,onKeyup:l.withKeys(a,["enter"])},null,42,x8e))}}),N1=me(S8e,[["__scopeId","data-v-5b8c9f76"]]);var Ba=(e=>(e.profile="profile",e.theme="theme",e.options="options",e.exit="exit",e.help="help",e))(Ba||{});const _8e=["data-testid"],T8e=["src","alt"],P8e=["src"],E8e={key:2,class:"avatar-yui-kit__text"},Gd=me(l.defineComponent({__name:"Avatar",props:{initials:{},url:{},isIcon:{type:Boolean},alt:{},defaultImage:{},dataTestid:{}},setup(e){const t=e,n=l.ref(!1);l.watch(()=>t.url,()=>{n.value=!1});const i=()=>t.initials?t.initials.charAt(0):"";return(r,a)=>(l.openBlock(),l.createElementBlock("div",{"data-testid":t.dataTestid,class:"avatar-yui-kit"},[t.url&&!n.value?(l.openBlock(),l.createElementBlock("img",{key:0,src:t.url,alt:t.alt,class:"avatar-yui-kit__image",onError:a[0]||(a[0]=o=>n.value=!0)},null,40,T8e)):t.defaultImage?(l.openBlock(),l.createElementBlock("img",{key:1,src:t.defaultImage,class:"avatar-yui-kit__image"},null,8,P8e)):(l.openBlock(),l.createElementBlock("div",E8e,l.toDisplayString(i()),1))],8,_8e))}}),[["__scopeId","data-v-15c61fb6"]]),A8e=["data-testid"],N8e={class:"menu-yui-kit__wrapper"},D8e={class:"menu-yui-kit__names"},j8e={class:"menu-yui-kit__name"},I8e={class:"menu-yui-kit__role"},W8e={key:0,class:"menu-yui-kit__list"},O8e={class:"list-yui-kit"},z8e=["data-testid"],L8e=["data-testid"],$8e=["data-testid"],H8e=["data-testid"],R8e=["data-testid"],B8e=["data-type"],D1=me(l.defineComponent({__name:"UserMenu",props:{closeAfterClick:{type:Boolean},user:{},languages:{},isBlackTheme:{type:Boolean},dataTestid:{default:"UserMenu"}},emits:["click","themeChange","languageSwitch"],setup(e,{emit:t}){const n=e,i=l.reactive({isShow:!1,option:"",isBlackTheme:n.isBlackTheme??!1}),r=t,a=l.computed(()=>({"menu-yui-kit__heading":!0,"active-yui-kit":i.isShow})),o=l.computed(()=>i.isBlackTheme?ce.dark:ce.light),s=l.ref(null),u=y=>{s.value&&!s.value.contains(y.target)&&(i.isShow=!1)};l.onMounted(()=>{document.addEventListener("click",u)}),l.onBeforeUnmount(()=>{document.removeEventListener("click",u)});const c=y=>{y!==void 0?(i.option=y,r("click",y),n.closeAfterClick&&(i.isShow=!1)):console.error("Option type is undefined")},f=l.computed(()=>i.isShow?ce.chevronUp:ce.chevronDown),h=()=>{i.isShow=!i.isShow},g=y=>{n.closeAfterClick&&(i.isShow=!1),r("themeChange",y),i.isBlackTheme=y},p=y=>{n.closeAfterClick&&(i.isShow=!1),r("languageSwitch",y)};return(y,v)=>{var k,w,M;return l.openBlock(),l.createElementBlock("div",{class:"menu-yui-kit",ref_key:"menuRef",ref:s,"data-testid":n.dataTestid},[l.createElementVNode("div",N8e,[l.createVNode(Gd,{class:"menu-yui-kit__avatar",url:n.user.avatar,alt:"user-avatar","data-testid":`${n.dataTestid}-Avatar`},null,8,["url","data-testid"]),l.createElementVNode("div",{class:l.normalizeClass(a.value),onClick:h},[l.createElementVNode("div",D8e,[l.createElementVNode("p",j8e,l.toDisplayString(n.user.name),1),l.createElementVNode("p",I8e,l.toDisplayString(n.user.role),1)]),l.createVNode(St,{type:l.unref(nt).ghost,class:"menu-yui-kit__button","data-testid":`${n.dataTestid}-Toggle`},{default:l.withCtx(()=>[l.createVNode(ye,{class:"menu-yui-kit__button-icon",name:f.value},null,8,["name"])]),_:1},8,["type","data-testid"])],2)]),i.isShow?(l.openBlock(),l.createElementBlock("div",W8e,[l.createElementVNode("ul",O8e,[l.createElementVNode("li",{class:"list-yui-kit__item",onClick:v[0]||(v[0]=x=>c(l.unref(Ba).profile)),"data-testid":`${n.dataTestid}-Profile-Item`},[l.createVNode(ye,{name:l.unref(ce).profile},null,8,["name"]),v[5]||(v[5]=l.createElementVNode("span",{class:"list-yui-kit__item-text"},"Профиль",-1))],8,z8e),l.createElementVNode("li",{class:"list-yui-kit__item","data-testid":`${n.dataTestid}-Theme-Item`},[l.createVNode(ye,{name:o.value},null,8,["name"]),l.createElementVNode("span",{class:"list-yui-kit__item-text",onClick:v[1]||(v[1]=x=>c(l.unref(Ba).theme))},"Темная тема"),l.createVNode(Bd,{type:l.unref(Uo).small,onChange:g,checked:i.isBlackTheme,"data-testid":`${n.dataTestid}-Theme-Toggle`},null,8,["type","checked","data-testid"])],8,L8e),l.createElementVNode("li",{class:"list-yui-kit__item",onClick:v[2]||(v[2]=x=>c(l.unref(Ba).options)),"data-testid":`${n.dataTestid}-Settings-Item`},[l.createVNode(ye,{name:l.unref(ce).settings},null,8,["name"]),v[6]||(v[6]=l.createElementVNode("span",{class:"list-yui-kit__item-text"},"Настройки",-1))],8,$8e),l.createElementVNode("li",{class:"list-yui-kit__item",onClick:v[3]||(v[3]=x=>c(l.unref(Ba).exit)),"data-testid":`${n.dataTestid}-Exit-Item`},[l.createVNode(ye,{name:l.unref(ce).exit},null,8,["name"]),v[7]||(v[7]=l.createElementVNode("span",{class:"list-yui-kit__item-text"},"Выход",-1))],8,H8e),l.createElementVNode("li",{class:"list-yui-kit__item",onClick:v[4]||(v[4]=x=>c(l.unref(Ba).help)),"data-testid":`${n.dataTestid}-Help-Item`},[l.createVNode(ye,{name:l.unref(ce).help},null,8,["name"]),l.createElementVNode("span",{class:"list-yui-kit__item-text","data-type":l.unref(Ba).help},"Помощь",8,B8e)],8,R8e)]),(k=n.languages)!=null&&k.items?(l.openBlock(),l.createBlock(Pu,{key:0,items:(w=n.languages)==null?void 0:w.items,defaultValue:(M=n.languages)==null?void 0:M.defaultValue,onChange:p,"data-testid":`${n.dataTestid}-Language-Switch`},null,8,["items","defaultValue","data-testid"])):l.createCommentVNode("",!0)])):l.createCommentVNode("",!0)],8,A8e)}}}),[["__scopeId","data-v-92ca4d70"]]);var Kd=(e=>(e.default="default",e.minor="minor",e))(Kd||{});const V8e=["data-testid"],F8e=["data-testid"],U8e=["data-testid"],Y8e=["data-testid","placeholder","required","maxlength","readonly"],X8e=l.defineComponent({__name:"Textarea",props:{placeholder:{},inputMessage:{},required:{type:Boolean,default:!1},maxlength:{},modelValue:{default:""},readonly:{type:Boolean,default:!1},type:{default:Kd.default},modelModifiers:{default:()=>({})},dataTestid:{default:"Textarea"}},emits:["update:modelValue"],setup(e,{emit:t}){const n=e,i=t,r=l.reactive({isPressed:!1,inputElement:n.modelValue}),a=l.computed(()=>[{pressed:r.isPressed,readonly:n.readonly,[n.type]:!0}]),o=()=>{i("update:modelValue",r.inputElement)},s=()=>{n.readonly||(r.isPressed=!0)},u=()=>{r.isPressed=!1};return l.watch(()=>n.modelValue,c=>{r.inputElement=c}),(c,f)=>(l.openBlock(),l.createElementBlock("fieldset",{class:l.normalizeClass(["input-yui-kit",a.value]),onFocusout:u,"data-testid":n.dataTestid},[n.inputMessage?(l.openBlock(),l.createElementBlock("legend",{key:0,class:"input-yui-kit__legend","data-testid":`${n.dataTestid}-Legend`},[l.createTextVNode(l.toDisplayString(n.inputMessage)+" ",1),n.required?(l.openBlock(),l.createElementBlock("sup",{key:0,class:"input-yui-kit__star","data-testid":`${n.dataTestid}-Legend-Star`},"*",8,U8e)):l.createCommentVNode("",!0)],8,F8e)):l.createCommentVNode("",!0),l.withDirectives(l.createElementVNode("textarea",{"onUpdate:modelValue":f[0]||(f[0]=h=>r.inputElement=h),onFocus:s,onInput:o,"data-testid":`${n.dataTestid}-Textarea`,class:"input-yui-kit__input",placeholder:n.placeholder,required:n.required,maxlength:n.maxlength,readonly:n.readonly},null,40,Y8e),[[l.vModelText,r.inputElement]])],42,V8e))}}),j1=me(X8e,[["__scopeId","data-v-ac7acfbd"]]);var k4=(e=>(e.img="img",e.pdf="pdf",e.docx="docx",e))(k4||{});const q8e=["data-testid"],G8e=["data-testid"],K8e=["src","alt","data-testid"],Q8e=["data-testid"],J8e=["data-testid"],Z8e=["data-testid"],I1=me(l.defineComponent({__name:"Picture",props:{type:{},alt:{},url:{},caption:{},dataTestid:{default:"Picture"}},setup(e){const t=e;return(n,i)=>(l.openBlock(),l.createElementBlock("figure",{class:"picture-yui-kit","data-testid":t.dataTestid},[t.type==l.unref(k4).img?(l.openBlock(),l.createElementBlock(l.Fragment,{key:0},[l.createElementVNode("picture",{class:"picture-yui-kit__picture","data-testid":`${t.dataTestid}-Picture`},[l.createElementVNode("img",{class:"picture-yui-kit__picture__image",src:t.url,alt:t.alt,"data-testid":`${t.dataTestid}-Picture-Img`},null,8,K8e)],8,G8e),l.createElementVNode("figcaption",{class:"picture-yui-kit__picture__caption","data-testid":`${t.dataTestid}-Caption`},l.toDisplayString(t.caption),9,Q8e)],64)):(l.openBlock(),l.createElementBlock("div",{key:1,class:"picture-yui-kit__caption","data-testid":`${t.dataTestid}-Caption-Box`},[l.createElementVNode("h4",{class:"picture-yui-kit__caption__title","data-testid":`${t.dataTestid}-Caption-Title`},l.toDisplayString(t.caption),9,Z8e)],8,J8e))],8,q8e))}}),[["__scopeId","data-v-6a079c40"]]);var M4=(e=>(e.success="success",e.warning="warning",e.error="error",e.info="info",e))(M4||{}),C4=(e=>(e.success="Успешно",e.warning="Предупреждение",e.error="Ошибка",e.info="Уведомление",e))(C4||{}),x4=(e=>(e[e.success=ce.checkbox]="success",e[e.warning=ce.alertTriangle]="warning",e[e.error=ce.exitCircle]="error",e[e.info=ce.info]="info",e))(x4||{});const e7e=["id","data-testid"],t7e=["data-testid"],n7e=["data-testid"],i7e=["data-testid"],r7e=["data-testid"],a7e=l.defineComponent({__name:"Notification",props:{type:{default:M4.info},title:{},pushKey:{},description:{default:""},timeout:{default:3},showPopover:{type:Boolean,default:!0},dataTestid:{default:"Notification"}},emits:["close"],setup(e,{expose:t,emit:n}){const i=e,r=n,a=l.ref(null);K(a,"toggle",()=>{i.timeout>0&&setTimeout(()=>{var c;return(c=a.value)==null?void 0:c.hidePopover()},i.timeout*1e3)});const o=()=>(r("close"),"hide"),s=()=>{var c;(c=a.value)==null||c.showPopover()},u=l.reactive({message:{icon:x4[i.type],title:i.title||C4[i.type],description:i.description}});return l.onMounted(()=>{var c;i.showPopover&&((c=a.value)==null||c.showPopover())}),t({showPopover:s}),(c,f)=>(l.openBlock(),l.createElementBlock("div",{popover:"manual",id:i.pushKey.toString(),class:l.normalizeClass(`push-notification-yui-kit push-notification-yui-kit_${i.type}`),"data-testid":i.dataTestid,ref_key:"popover",ref:a},[l.createElementVNode("div",{class:"notification-yui-kit","data-testid":`${i.dataTestid}-Notification`},[l.createElementVNode("div",{class:"notification-yui-kit__block","data-testid":`${i.dataTestid}-Notification-Block`},[l.createVNode(ye,{name:u.message.icon,class:"notification-yui-kit__block-icon","data-testid":`${i.dataTestid}-Notification-Icon`},null,8,["name","data-testid"]),l.createElementVNode("h4",{class:"notification-yui-kit__block-title","data-testid":`${i.dataTestid}-Notification-Title`},l.toDisplayString(u.message.title),9,i7e),l.createElementVNode("span",{class:"notification-yui-kit__block-text","data-testid":`${i.dataTestid}-Notification-Description`},l.toDisplayString(u.message.description),9,r7e)],8,n7e),l.createVNode(St,{class:"notification-yui-kit__exit",type:l.unref(nt).ghost,popovertarget:i.pushKey.toString(),popovertargetaction:o,"data-testid":`${i.dataTestid}-Notification-Button`},{default:l.withCtx(()=>[l.createVNode(ye,{name:l.unref(ce).crossSmall,"data-testid":`${i.dataTestid}-Notification-Icon`},null,8,["name","data-testid"])]),_:1},8,["type","popovertarget","data-testid"])],8,t7e)],10,e7e))}}),W1=me(a7e,[["__scopeId","data-v-42a4a42d"]]),O1=l.defineComponent({__name:"CopyIcon",props:{content:{default:""},dataTestid:{default:"CopyIcon"}},setup(e){const t=e,n=()=>{const i=t.content,r=document.createElement("textarea");r.value=i;const a=document.querySelectorAll("dialog[open]"),o=a.length?a[a.length-1]:null;o?o.append(r):document.body.append(r),r.select(),r.setSelectionRange(0,99999),document.execCommand("copy"),r.remove()};return(i,r)=>(l.openBlock(),l.createBlock(ye,{class:"copy-icon-yui-kit",name:l.unref(ce).copy,"data-testid":t.dataTestid,onClick:n},null,8,["name","data-testid"]))}}),o7e=["data-testid"],s7e=["data-testid"],l7e=["data-testid"],u7e=["data-testid"],d7e=["data-testid"],z1=me(l.defineComponent({__name:"Loader",props:{title:{default:"Загрузка..."},dataTestid:{default:"Loader"}},setup(e){const t=e;return(n,i)=>(l.openBlock(),l.createElementBlock("div",{class:"loader","data-testid":t.dataTestid},[l.createElementVNode("div",{class:"loader__area","data-testid":`${t.dataTestid}-Area`},[l.createElementVNode("div",{class:"loader__circle loader__circle--light-blue","data-testid":`${t.dataTestid}-Loader-LightBlue1`},null,8,l7e),l.createElementVNode("div",{class:"loader__circle loader__circle--blue","data-testid":`${t.dataTestid}-Loader-LightBlue2`},null,8,u7e)],8,s7e),t.title?(l.openBlock(),l.createElementBlock("span",{key:0,class:"loader__span","data-testid":`${t.dataTestid}-Loader-Title`},l.toDisplayString(t.title),9,d7e)):l.createCommentVNode("",!0)],8,o7e))}}),[["__scopeId","data-v-f57f6084"]]),c7e=["data-testid"],f7e=["data-testid"],h7e=["data-testid"],m7e=["data-testid"],p7e=["data-testid"],g7e=["data-testid"],y7e=["data-testid"],b7e=["data-testid"],w7e=["data-testid"],v7e=["data-testid"],k7e=["data-testid"],M7e=["data-testid"],C7e=["data-testid"],x7e=["data-testid"],S7e=l.defineComponent({__name:"FilterTag",props:{title:{},iconName:{default:ce.filter},options:{default:()=>[]},selectedValues:{default:()=>[]},multiply:{type:Boolean,default:!0},maxShowCount:{default:5},showClearButton:{type:Boolean,default:!1},disallowNull:{type:Boolean,default:!1},dataTestid:{default:"FilterTag"}},emits:["change"],setup(e,{emit:t}){const n=e,i=l.reactive({isShow:!1,options:[]}),r=t,a=l.computed(()=>({"filter-yui-kit__wrapper":!0,"active-yui-kit":i.isShow})),o=()=>i.isShow=!i.isShow,s=()=>{i.isShow=!1},u=l.computed(()=>i.options.filter(p=>p.chose)),c=l.computed(()=>i.options.filter(p=>!p.chose)),f=p=>{n.disallowNull&&p.chose||(p.chose=!p.chose,n.multiply||(i.options=i.options.map(y=>({...y,chose:p.value===y.value&&p.chose}))),i.options.every(y=>y.chose)&&(i.options=i.options.map(y=>({...y,chose:!1}))),r("change",u.value.map(y=>y.value)),i.isShow=!1)},h=()=>{i.options=i.options.map(p=>({...p,chose:!1})),i.isShow=!1,r("change",[])},g=()=>{i.options=n.options.map(p=>({...p,chose:n.selectedValues.includes(p.value)})),i.options.every(p=>p.chose)&&(i.options=i.options.map(p=>({...p,chose:!1})))};return l.watch(()=>[n.options,n.selectedValues],g),l.watch(()=>n.selectedValues,g),l.onMounted(g),(p,y)=>l.withDirectives((l.openBlock(),l.createElementBlock("div",{class:"filter-yui-kit","data-testid":n.dataTestid},[l.createElementVNode("div",{class:l.normalizeClass(a.value),onClick:o,"data-testid":`${n.dataTestid}-Wrapper`},[n.iconName?(l.openBlock(),l.createBlock(ye,{key:0,name:n.iconName,"data-testid":`${n.dataTestid}-Icon`},null,8,["name","data-testid"])):l.createCommentVNode("",!0),n.title?(l.openBlock(),l.createElementBlock("span",{key:1,"data-testid":`${n.dataTestid}-Title`},l.toDisplayString(n.title),9,h7e)):l.createCommentVNode("",!0),!u.value.length&&!n.disallowNull?(l.openBlock(),l.createBlock(Ft,{key:2,disabled:"",text:"Все","data-testid":`${n.dataTestid}-Badges-All`},null,8,["data-testid"])):(l.openBlock(!0),l.createElementBlock(l.Fragment,{key:3},l.renderList(u.value.filter((v,k)=>k<n.maxShowCount),(v,k)=>(l.openBlock(),l.createBlock(Ft,{key:v.value,type:v.type,disabled:"","data-testid":`${n.dataTestid}-Badges${k}`,text:v.label},null,8,["type","data-testid","text"]))),128)),n.maxShowCount<u.value.length?(l.openBlock(),l.createElementBlock("div",{key:4,class:"filter-yui-kit__counter","data-testid":`${n.dataTestid}-MaxShowCount-Counter`},[l.createTextVNode(" +"+l.toDisplayString(u.value.length-n.maxShowCount)+" ",1),l.createElementVNode("div",{class:"filter-yui-kit__counter-content","data-testid":`${n.dataTestid}-MaxShowCount-Content`},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(u.value.filter((v,k)=>k>=n.maxShowCount),(v,k)=>(l.openBlock(),l.createBlock(Ft,{key:v.value,type:v.type,disabled:"",text:v.label,"data-testid":`${n.dataTestid}-MaxShow-Badges${k}`},null,8,["type","text","data-testid"]))),128))],8,p7e)],8,m7e)):l.createCommentVNode("",!0),n.showClearButton&&u.value.length>0?(l.openBlock(),l.createElementBlock("button",{key:5,type:"button",class:"filter-yui-kit__close",onClick:l.withModifiers(h,["stop"]),"data-testid":`${n.dataTestid}-Filter-CloseButton`},[l.createVNode(ye,{name:l.unref(ce).crossSmall,"data-testid":`${n.dataTestid}-CloseButton-Icon`},null,8,["name","data-testid"])],8,g7e)):l.createCommentVNode("",!0)],10,f7e),i.isShow?(l.openBlock(),l.createElementBlock("div",{key:0,class:"filter-yui-kit__select-wrapper","data-testid":`${n.dataTestid}-Select-Wrapper`},[l.createElementVNode("ul",{class:"filter-yui-kit__select-list selected-yui-kit","data-testid":`${n.dataTestid}-Select-List`},[u.value.length?l.createCommentVNode("",!0):(l.openBlock(),l.createElementBlock("li",{key:0,class:"filter-yui-kit__select-item","data-testid":`${n.dataTestid}-Select-Item`},[l.createVNode(Ft,{disabled:"",text:"Все","data-testid":`${n.dataTestid}-Select-Badges`},null,8,["data-testid"])],8,w7e)),(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(u.value,(v,k)=>(l.openBlock(),l.createElementBlock("li",{class:"filter-yui-kit__select-item",key:v.value,"data-testid":`${n.dataTestid}-Select-Item${k}`},[l.createVNode(Ft,{disabled:!0,choosed:!n.disallowNull&&v.chose,type:v.type,onClick:w=>f(v),text:v.label,"data-testid":`${n.dataTestid}-Select-Badges${k}`},null,8,["choosed","type","onClick","text","data-testid"])],8,v7e))),128))],8,b7e),l.createElementVNode("div",{class:"filter-yui-kit__select__divider","data-testid":`${n.dataTestid}-Select-Divider`},null,8,k7e),i.isShow?(l.openBlock(),l.createElementBlock("ul",{key:0,class:"filter-yui-kit__select-list","data-testid":`${n.dataTestid}-Select-List`},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(c.value,(v,k)=>(l.openBlock(),l.createElementBlock("li",{class:"filter-yui-kit__select-item",key:v.value,"data-testid":`${n.dataTestid}-Select-List${k}`},[l.createVNode(Ft,{disabled:!0,choosed:!1,type:v.type,text:v.label,"data-testid":`${n.dataTestid}-Select-Badges${k}`,onClick:w=>f(v)},null,8,["type","text","data-testid","onClick"])],8,C7e))),128)),e.disallowNull?l.createCommentVNode("",!0):(l.openBlock(),l.createElementBlock("li",{key:0,class:"filter-yui-kit__select-item","data-testid":`${n.dataTestid}-Select-Item`},[u.value.length?(l.openBlock(),l.createBlock(Ft,{key:0,disabled:"","data-testid":`${n.dataTestid}-Select-Badges`,text:"Все",onClick:h},null,8,["data-testid"])):l.createCommentVNode("",!0)],8,x7e))],8,M7e)):l.createCommentVNode("",!0)],8,y7e)):l.createCommentVNode("",!0)],8,c7e)),[[l.unref(Ls),s,void 0,{bubble:!0}]])}}),L1=me(S7e,[["__scopeId","data-v-9a93bcc4"]]),_7e=["data-testid"],T7e=["data-testid"],P7e=["data-testid"],E7e=["data-testid"],$1=me(l.defineComponent({__name:"CircularProgress",props:{percent:{},dataTestid:{default:"CircularProgress"}},setup(e){const t=e,n=()=>{const i=Math.min(Math.max(t.percent,0),100),r=i/100*360;if(i<=25)return`polygon(50% 50%, 50% 0%, calc(50% + 50% * cos(${r-90}deg)) 0,calc(50% + 50% * cos(${r-90}deg)) calc(50% + 50% * sin(${r-90}deg)), 50% 50%)`;if(i<=50)return`polygon(50% 50%, 50% 0%, 100% 0%, 100% calc(50% + 50% * sin(${r-90}deg)), calc(50% + 50% * cos(${r-90}deg)) calc(50% + 50% * sin(${r-90}deg)), 50% 50%)`;if(i<=75)return`polygon(50% 50%, 50% 0%, 100% 0%, 100% 100%,
|
|
1298
|
-
calc(50% + 50% * cos(${r-90}deg)) 100%, calc(50% + 50% * cos(${r-90}deg)) calc(50% + 50% * sin(${r-90}deg)), 50% 50%)`;if(i<=100)return`polygon(50% 50%, 50% 0%, 100% 0%, 100% 100%,0% 100%, 0% calc(50% + 50% * sin(${r-90}deg)), 50% 50%)`};return(i,r)=>t.percent<100?(l.openBlock(),l.createElementBlock("div",{key:0,class:"pie-chart","data-testid":`${t.dataTestid}-PieChart`},[l.createElementVNode("div",{class:"pie-chart-border",style:l.normalizeStyle({"border-color":t.percent<50?"#ef9b8f":"#ffcc00"}),"data-testid":`${t.dataTestid}-PieChart-Border`},[l.createElementVNode("div",{class:"sector",style:l.normalizeStyle({clipPath:n(),"background-color":t.percent<50?"#ef9b8f":"#ffcc00"}),"data-testid":`${t.dataTestid}-PieChart-Sector`},null,12,P7e)],12,T7e)],8,_7e)):(l.openBlock(),l.createElementBlock("svg",{key:1,width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","data-testid":`${t.dataTestid}-Icon`,xmlns:"http://www.w3.org/2000/svg"},[...r[0]||(r[0]=[l.createElementVNode("path",{d:"M8 1C4.136 1 1 4.136 1 8C1 11.864 4.136 15 8 15C11.864 15 15 11.864 15 8C15 4.136 11.864 1 8 1ZM8 13.6C4.906 13.6 2.4 11.094 2.4 8C2.4 4.906 4.906 2.4 8 2.4C11.094 2.4 13.6 4.906 13.6 8C13.6 11.094 11.094 13.6 8 13.6Z",fill:"#3BC648"},null,-1),l.createElementVNode("circle",{cx:"8",cy:"8",r:"4",transform:"rotate(-180 8 8)",fill:"#3BC648"},null,-1),l.createElementVNode("path",{d:"M10 6L7.5 9.83935L6 8.5",stroke:"white","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])],8,E7e))}}),[["__scopeId","data-v-e50e4774"]]),A7e=["data-testid","aria-label"],N7e=["data-testid"],Ml=me(l.defineComponent({name:"Tooltip",__name:"Tooltip",props:{hint:{},isShow:{type:Boolean,default:!1},isCanShow:{type:Boolean,default:!0},position:{default:"bottom-center"},size:{default:"small"},type:{default:"black"},hintGap:{},hintClass:{default:""},dataTestid:{default:"Tooltip"}},setup(e){const t=e,n=l.ref(null),i=l.ref(null),r=l.computed(()=>[{"tooltip-yui-kit__hint_show":t.isShow||o.isShow,"tooltip-yui-kit__hint_bottom-center":t.position==="bottom-center","tooltip-yui-kit__hint_bottom-left":t.position==="bottom-left","tooltip-yui-kit__hint_bottom-right":t.position==="bottom-right","tooltip-yui-kit__hint_top-center":t.position==="top-center","tooltip-yui-kit__hint_top-left":t.position==="top-left","tooltip-yui-kit__hint_top-right":t.position==="top-right","tooltip-yui-kit__hint_left-top":t.position==="left-top","tooltip-yui-kit__hint_left-center":t.position==="left-center","tooltip-yui-kit__hint_left-bottom":t.position==="left-bottom","tooltip-yui-kit__hint_right-top":t.position==="right-top","tooltip-yui-kit__hint_right-center":t.position==="right-center","tooltip-yui-kit__hint_right-bottom":t.position==="right-bottom","tooltip-yui-kit__hint_small":t.size==="small","tooltip-yui-kit__hint_medium":t.size==="medium","tooltip-yui-kit__hint_large":t.size==="large","tooltip-yui-kit__hint_black":t.type==="black","tooltip-yui-kit__hint_blue":t.type==="blue","tooltip-yui-kit__hint_white":t.type==="white",[t.hintClass]:!0}]),a=l.computed(()=>{var M;const w=(M=n.value)==null?void 0:M.closest("dialog");return w||"body"}),o=l.reactive({isShow:!1}),s=()=>{g()},u=()=>{p()},c=()=>{f()},f=()=>{requestAnimationFrame(()=>{if(!n.value||!i.value||!o.isShow&&!t.isShow)return;const w={"--hint-top":"0","--hint-left":"0","--hint-width":"0","--hint-height":"0","--tooltip-width":"0","--tooltip-height":"0","--hint-visibility":"visible"},M=n.value.getBoundingClientRect(),x=i.value.getBoundingClientRect(),S=window.pageYOffset||document.documentElement.scrollTop,_=window.pageXOffset||document.documentElement.scrollLeft;let j=M.top+S,T=M.left+_;const I=n.value.closest("dialog");if(I){const X=I.getBoundingClientRect();j=M.top-X.top,T=M.left-X.left;const re=I.scrollTop,ee=I.scrollLeft;j+=re,T+=ee}const L=M.width,N=M.height,z=x.width,H=x.height;w["--hint-top"]=`${j}px`,w["--hint-left"]=`${T}px`,w["--tooltip-width"]=`${L}px`,w["--tooltip-height"]=`${N}px`,w["--hint-width"]=`${z}px`,w["--hint-height"]=`${H}px`,i.value&&Pt(w,i.value)})},h=()=>{requestAnimationFrame(()=>{!i.value||t.hintGap===void 0||Pt({"--tooltip-hint-gap":t.hintGap},i.value)})};l.watch(()=>t.hintGap,h,{immediate:!0});const g=()=>{o.isShow=!0},p=()=>{o.isShow=!1},y=new MutationObserver(()=>{f()}),v=new ResizeObserver(()=>{var w;(o.isShow||t.isShow)&&!((w=n.value)!=null&&w.matches(":hover"))?p():f()}),k=w=>{y.observe(w,{childList:!0,attributes:!0,characterData:!0}),v.observe(w)};return l.onMounted(()=>{f(),i.value&&k(i.value),n.value&&k(n.value),window.addEventListener("scroll",f,!0),window.addEventListener("resize",f)}),l.onUnmounted(()=>{v.disconnect(),y.disconnect(),window.removeEventListener("scroll",f,!0),window.removeEventListener("resize",f)}),(w,M)=>(l.openBlock(),l.createElementBlock("div",{ref_key:"tooltipRef",ref:n,class:"tooltip-yui-kit","data-testid":t.dataTestid,"aria-label":e.hint,onMouseenter:s,onMouseleave:u},[l.renderSlot(w.$slots,"default",{},void 0,!0),e.isCanShow?(l.openBlock(),l.createBlock(l.Teleport,{key:0,to:a.value},[l.createVNode(l.Transition,{name:"hint-animate",onEnter:c},{default:l.withCtx(()=>[e.isShow||o.isShow?(l.openBlock(),l.createElementBlock("div",{key:0,ref_key:"hintRef",ref:i,"data-testid":t.dataTestid,class:l.normalizeClass(["tooltip-yui-kit__hint",r.value])},l.toDisplayString(e.hint),11,N7e)):l.createCommentVNode("",!0)]),_:1})],8,["to"])):l.createCommentVNode("",!0)],40,A7e))}}),[["__scopeId","data-v-2f1a6d22"]]),D7e=["data-testid"],j7e=["data-testid"],I7e=["data-testid"],W7e=["onClick","data-testid"],O7e=l.defineComponent({__name:"Popover",props:{isShow:{type:Boolean},iconName:{default:ce.moreVertical},options:{default:()=>[]},tooltip:{default:""},tooltipPosition:{default:"top-left"},dataTestid:{default:"Popover"}},emits:["close"],setup(e,{emit:t}){const n=e,i=t,r=l.reactive({isShow:!1}),a=l.computed(()=>{var I;const T=(I=c.value)==null?void 0:I.closest("dialog");return T||"body"}),o=CSS.supports("top","anchor(bottom)"),s=l.useId(),u=l.computed(()=>`--anchor-popover-${s}`),c=l.ref(null),f=l.ref(null),h=l.ref(null),g=l.computed(()=>({"popover-yui-kit__wrapper":!0,"active-yui-kit":r.isShow,"empty-yui-kit":n.options.length===0})),p=()=>r.isShow=!r.isShow,y=()=>{r.isShow=!1,i("close")},v=T=>{T.function(),y()},k=()=>{requestAnimationFrame(()=>{if(!c.value||!f.value||!r.isShow)return;const T={},I=c.value.getBoundingClientRect(),L=window.pageYOffset||document.documentElement.scrollTop,N=window.pageXOffset||document.documentElement.scrollLeft;let z=I.bottom+L,H=I.left+N;const X=c.value.closest("dialog");if(X){const ee=X.getBoundingClientRect();z=I.top-ee.top,H=I.left-ee.left;const q=X.scrollTop,Z=X.scrollLeft;z+=q,H+=Z,z+=10}z+=10,T["--popover-top"]=`${z}px`,o||(T["--popover-left"]=`${H}px`),Pt(T,f.value),(()=>{if(!f.value)return;const ee=f.value.getBoundingClientRect();ee.right>window.innerWidth&&(o?T["--popover-right"]="anchor(right) ":T["--popover-right"]=`${I.right-ee.width}px`)})(),T["--popover-right"]&&(T.left="auto",Pt(T,f.value))})},w=T=>{const I=T.getBoundingClientRect(),L=document.elementFromPoint(I.left,I.top),N=document.elementFromPoint(I.right,I.bottom);!(L&&T.contains(L))&&!(N&&T.contains(N))&&y()},M=new IntersectionObserver(T=>{T.forEach(I=>{I.isIntersecting||y()})}),x=()=>{c.value&&f.value&&(window.addEventListener("scroll",k,!0),window.addEventListener("resize",k))},S=()=>{c.value&&f.value&&(window.removeEventListener("scroll",k,!0),window.removeEventListener("resize",k))},_=()=>{c.value&&window.addEventListener("scroll",w.bind(null,c.value),!0)},j=()=>{c.value&&window.removeEventListener("scroll",w.bind(null,c.value),!0)};return l.watch(()=>n.isShow,()=>r.isShow=n.isShow),l.watch(()=>r.isShow,()=>{r.isShow?(k(),_()):j(),!o&&(r.isShow?x():S())}),l.onMounted(()=>{c.value&&Pt({"anchor-name":`${u.value}`},c.value),f.value&&Pt({"position-anchor":`${u.value}`},f.value),h.value&&M.observe(h.value),o&&k()}),l.onUnmounted(()=>{M.disconnect(),j(),o||S()}),(T,I)=>(l.openBlock(),l.createBlock(Ml,{hint:n.tooltip,size:"small",type:"black",position:n.tooltipPosition,"data-testid":n.dataTestid,"is-can-show":!!n.tooltip&&!r.isShow&&n.options.length>0},{default:l.withCtx(()=>[l.withDirectives((l.openBlock(),l.createElementBlock("div",{class:"popover-yui-kit",ref_key:"popover",ref:h,"data-testid":`${n.dataTestid}-Popover`},[l.createElementVNode("div",{ref_key:"reference",ref:c,class:l.normalizeClass(g.value),"data-testid":`${n.dataTestid}-PopoverShow`,onClick:p},[l.createVNode(ye,{class:"popover-yui-kit__icon",name:n.iconName,width:16,height:16,"data-testid":`${n.dataTestid}-PopoverShow-Icon`},null,8,["name","data-testid"])],10,j7e),(l.openBlock(),l.createBlock(l.Teleport,{to:a.value},[l.createVNode(l.Transition,{name:"popover-animate"},{default:l.withCtx(()=>{var L;return[(L=n.options)!=null&&L.length?l.withDirectives((l.openBlock(),l.createElementBlock("div",{key:0,class:"popover-yui-kit__options",ref_key:"floating",ref:f,"data-testid":`${n.dataTestid}-PopoverShow-Options`},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(n.options,(N,z)=>(l.openBlock(),l.createElementBlock("div",{class:"popover-yui-kit__options__item",style:l.normalizeStyle(N.style),key:z,onClick:l.withModifiers(H=>v(N),["stop"]),"data-testid":`${n.dataTestid}-Item${z}`},l.toDisplayString(N.value),13,W7e))),128))],8,I7e)),[[l.vShow,r.isShow]]):l.createCommentVNode("",!0)]}),_:1})],8,["to"]))],8,D7e)),[[l.unref(Ls),y,void 0,{bubble:!0}]])]),_:1},8,["hint","position","data-testid","is-can-show"]))}}),H1=me(O7e,[["__scopeId","data-v-e1e1118a"]]),z7e=["colspan","rowspan","data-testid"],Go=me(l.defineComponent({name:"TableTh",__name:"TableTh",props:{colspan:{default:1},rowspan:{default:1},dataTestid:{default:"DataHeader"}},setup(e){const t=e;return(n,i)=>(l.openBlock(),l.createElementBlock("th",{colspan:e.colspan,rowspan:e.rowspan,"data-testid":t.dataTestid,class:"table-th"},[l.renderSlot(n.$slots,"default",{},void 0,!0)],8,z7e))}}),[["__scopeId","data-v-39ad1e7b"]]),L7e=["data-testid"],Cl=me(l.defineComponent({name:"HeadTableRow",__name:"HeadTableRow",props:{dataTestid:{default:"TableRow"}},setup(e){const t=e;return(n,i)=>(l.openBlock(),l.createElementBlock("tr",{class:"head-table-row","data-testid":t.dataTestid},[l.renderSlot(n.$slots,"default",{},void 0,!0)],8,L7e))}}),[["__scopeId","data-v-b2f1516a"]]),S4=(e,t,n,i)=>{const r=l.ref(!1),a=l.ref(100);let o=0,s=0;const u=l.computed(()=>[{"scroll-wrapper__track_hide":a.value===100,"scroll-wrapper__track_drag":r.value}]),c=l.computed(()=>a.value<100),f=()=>{if(e.value){const w=e.value.clientWidth,M=e.value.scrollWidth;return w>=M?100:w/M*100}return 100},h=()=>{if(!e.value||!t.value||!n.value||!i.value)return;const{scrollLeft:w,scrollWidth:M,clientWidth:x}=e.value,S=M-x;if(S<=0)return;const _=w/S,j=i.value.clientWidth,T=n.value.clientWidth,I=j-T,L=_*I;requestAnimationFrame(()=>{t.value&&Pt({"--scroll-bar-left-position":`${L}px`},t.value)})},g=w=>{!e.value||!t.value||(r.value=!0,o=w.clientX,s=e.value.scrollLeft,document.addEventListener("pointermove",p),document.addEventListener("pointerup",y,!0))},p=w=>{if(r.value&&e.value&&n.value){const M=w.clientX-o,x=(e.value.scrollWidth-e.value.clientWidth)/(e.value.clientWidth-n.value.clientWidth);e.value.scrollLeft=s+M*x,h()}},y=()=>{r.value=!1,document.removeEventListener("pointermove",p),document.removeEventListener("pointerup",y,!0)};return{onDrag:p,onTrackClick:w=>{if(e.value&&n.value){const M=w.currentTarget.getBoundingClientRect(),x=w.clientX-M.left,S=n.value.clientWidth,_=M.width;let j=(x-S/2)*((e.value.scrollWidth-e.value.clientWidth)/(_-S));j=Math.max(0,Math.min(j,e.value.scrollWidth-e.value.clientWidth)),e.value.scrollLeft=j,h()}},startDrag:g,getPercentHorizontalView:f,changeBarPosition:h,isDragging:r,scrollHorizontalWidthPercent:a,setHorizontalBarWidth:()=>{if(!e.value||!t.value)return;const w=f();a.value=w,Pt({"--scroll-horizontal-bar-width":`${w}%`},t.value)},horizontalTrackClass:u,isExistHorizontalTrack:c}},_4=(e,t,n,i)=>{const r=l.ref(!1),a=l.ref(100);let o=0,s=0;const u=l.computed(()=>[{"scroll-wrapper__track_hide":a.value===100,"scroll-wrapper__track_drag":r.value}]),c=l.computed(()=>a.value<100),f=()=>{if(e.value){const w=e.value.clientHeight,M=e.value.scrollHeight;if(w>=M)return 100;if(w<M)return w/M*100}return 100},h=()=>{if(!e.value||!t.value||!n.value||!i.value)return;const{scrollTop:w,scrollHeight:M,clientHeight:x}=e.value,S=M-x;if(S<=0)return;const _=w/S,j=i.value.clientHeight,T=n.value.clientHeight,I=j-T,L=_*I;requestAnimationFrame(()=>{t.value&&Pt({"--scroll-bar-top-postion":`${L}px`},t.value)})},g=w=>{!e.value||!t.value||(r.value=!0,o=w.clientY,s=e.value.scrollTop,document.addEventListener("pointermove",p),document.addEventListener("pointerup",y))},p=w=>{if(r.value&&e.value&&n.value){const M=w.clientY-o,x=(e.value.scrollHeight-e.value.clientHeight)/(e.value.clientHeight-n.value.clientHeight);e.value.scrollTop=s+M*x,h()}},y=()=>{r.value=!1,document.removeEventListener("pointermove",p),document.removeEventListener("pointerup",y)};return{onDrag:p,onTrackClick:w=>{if(e.value&&n.value){const M=w.currentTarget.getBoundingClientRect(),x=w.clientY-M.top,S=n.value.clientHeight,_=M.height;let j=(x-S/2)*((e.value.scrollHeight-e.value.clientHeight)/(_-S));j=Math.max(0,Math.min(j,e.value.scrollHeight-e.value.clientHeight)),e.value.scrollTop=j,h()}},startDrag:g,getProcentVerticalView:f,changeBarPosition:h,isDragging:r,scrollVerticalHeightProcent:a,setVerticalBarHeight:()=>{if(!e.value||!t.value)return;const w=f();a.value=w,Pt({"--scroll-vertical-bar-height":`${w}%`},t.value)},verticalTrackClass:u,isExistVerticalTrack:c}},$7e={class:"scroll-wrapper__vertical-wrapper"},H7e={class:"scroll-wrapper__horizont-wrapper"},xl=me(l.defineComponent({name:"ScrollWrapper",__name:"ScrollWrapper",props:{isShowVerticalScroll:{type:Boolean,default:!1},isShowHorizontalScroll:{type:Boolean,default:!1}},emits:["unmount-scroll","unmount-paginate","on-mounted"],setup(e,{expose:t,emit:n}){const i=n,r=l.ref(null),a=l.ref(null),o=l.ref(null),s=l.ref(null),u=l.ref(null),c=l.ref(null),{onTrackClick:f,startDrag:h,changeBarPosition:g,setVerticalBarHeight:p,verticalTrackClass:y,isExistVerticalTrack:v}=_4(r,a,s,o),{changeBarPosition:k,startDrag:w,onTrackClick:M,setHorizontalBarWidth:x,horizontalTrackClass:S,isExistHorizontalTrack:_}=S4(r,a,c,u),j=q=>{g(),k(),i("unmount-scroll",q)},T=()=>{requestAnimationFrame(()=>{I(),L()})},I=()=>{if(!r.value||!a.value)return;const q=getComputedStyle(a.value),Z=a.value.style.minHeight||q.minHeight,ue=a.value.style.maxHeight||q.maxHeight,De=a.value.style.height;Pt({"--scroll-wrapper-height":`${De}`,"--scroll-wrapper-max-height":`${ue}`,"--scroll-wrapper-min-height":`${Z}`},a.value)},L=()=>{p(),x(),g(),k()},N=()=>{r.value&&r.value.addEventListener("scroll",j)},z=()=>{r.value&&(r.value.scrollTop=0)},H=()=>{r.value&&(r.value.scrollHeight<=r.value.clientHeight?i("unmount-paginate",!0):i("unmount-paginate",!1))},X=new MutationObserver(()=>{T(),H()}),re=new ResizeObserver(()=>{T(),H()}),ee=q=>{X.observe(q,{childList:!0,subtree:!0,attributes:!0}),re.observe(q)};return t({scrollToTop:z,setHeightSlot:I}),l.onMounted(()=>{T(),N(),a.value&&ee(a.value),o.value&&ee(o.value),window.addEventListener("resize",T),i("on-mounted")}),l.onUnmounted(()=>{window.removeEventListener("resize",T)}),(q,Z)=>(l.openBlock(),l.createElementBlock("div",{ref_key:"scrollWrapperRef",ref:a,class:"scroll-wrapper"},[l.createElementVNode("div",$7e,[l.createElementVNode("div",H7e,[l.createElementVNode("div",{ref_key:"slotRef",ref:r,class:"scroll-wrapper__slot"},[l.renderSlot(q.$slots,"default",{},void 0,!0)],512),l.unref(_)||e.isShowHorizontalScroll?(l.openBlock(),l.createElementBlock("div",{key:0,ref_key:"horizontTrackRef",ref:u,class:l.normalizeClass(["scroll-wrapper__track scroll-wrapper__track_horizont",l.unref(S)]),onClick:Z[1]||(Z[1]=l.withModifiers((...ue)=>l.unref(M)&&l.unref(M)(...ue),["self","prevent","left"]))},[l.createElementVNode("div",{ref_key:"horizontBarRef",ref:c,class:"scroll-wrapper__bar",onPointerdown:Z[0]||(Z[0]=l.withModifiers((...ue)=>l.unref(w)&&l.unref(w)(...ue),["prevent","left"]))},null,544)],2)):l.createCommentVNode("",!0)]),l.unref(v)||e.isShowVerticalScroll?(l.openBlock(),l.createElementBlock("div",{key:0,ref_key:"verticalTrackRef",ref:o,class:l.normalizeClass(["scroll-wrapper__track scroll-wrapper__track_vertical",l.unref(y)]),onClick:Z[3]||(Z[3]=l.withModifiers((...ue)=>l.unref(f)&&l.unref(f)(...ue),["self","prevent","left"]))},[l.createElementVNode("div",{ref_key:"verticalBarRef",ref:s,class:"scroll-wrapper__bar",onPointerdown:Z[2]||(Z[2]=l.withModifiers((...ue)=>l.unref(h)&&l.unref(h)(...ue),["prevent","left"]))},null,544)],2)):l.createCommentVNode("",!0)])],512))}}),[["__scopeId","data-v-b5d4825a"]]),R7e=["id","data-testid"],B7e=["id","data-testid"],V7e=["id","data-testid"],R1=me(l.defineComponent({name:"TableNew",__name:"Table",props:{tableId:{},search:{},tbodyId:{},theadId:{},columnCount:{},dataTestid:{default:"Table"},isShowVerticalScroll:{type:Boolean,default:!1},isShowHorizontalScroll:{type:Boolean,default:!1}},emits:["unmount-scroll","unmount-paginate"],setup(e,{expose:t,emit:n}){var x;const i=e,r=n,a=l.reactive({headHeight:0,maxColumnCount:0}),o=l.ref(null),s=l.ref(null),u=l.ref(null),c=l.ref(null),f=l.ref(null),h=S=>{r("unmount-scroll",S)},g=S=>r("unmount-paginate",S),p=()=>{if(!o.value||!f.value)return;const S=o.value.querySelector("thead");if(!S)return;const _=S.getBoundingClientRect().height;a.headHeight=_,Pt({"--scroll-track-margin-top":`${_}px`},f.value.$el)},y=()=>{f.value&&f.value.scrollToTop()},v=()=>{if(f.value&&c.value){const S=getComputedStyle(f.value.$el),_=Number(S.minHeight.replace(/\D/g,""));if(_&&_>0)return;Pt({"min-height":`${a.headHeight+108}px`},f.value.$el)}},k=()=>{let S=1;if(s.value){for(let _=0;_<s.value.children.length;_++)S=Math.max(s.value.children[_].children.length,S);a.maxColumnCount=S}},w=new MutationObserver(()=>{k()}),M=new ResizeObserver(()=>{p()});return t({scrollToTop:y,setHeightSlot:(x=f.value)==null?void 0:x.setHeightSlot,tbodyRef:u,tableRef:o,theadRef:s}),l.onMounted(()=>{p(),k(),window.addEventListener("resize",p),o.value&&M.observe(o.value),s.value&&w.observe(s.value,{childList:!0,subtree:!0}),v()}),(S,_)=>(l.openBlock(),l.createBlock(xl,{ref_key:"scrollWrapperRef",ref:f,class:"table",onUnmountScroll:h,onUnmountPaginate:g,"is-show-vertical-scroll":i.isShowVerticalScroll,"is-show-horizontal-scroll":i.isShowHorizontalScroll,"data-testid":`${i.dataTestid}-ScrollWrapper`},{default:l.withCtx(()=>[l.createElementVNode("table",{ref_key:"tableRef",ref:o,id:i.tableId,class:"table__table","data-testid":`${i.dataTestid}`},[l.renderSlot(S.$slots,"default",{},()=>{var j;return[l.createElementVNode("colgroup",null,[l.renderSlot(S.$slots,"colspan",{},void 0,!0)]),S.$slots.head?(l.openBlock(),l.createElementBlock("thead",{key:0,ref_key:"theadRef",ref:s,id:i.theadId,class:"table__head","data-testid":`${i.dataTestid}-Thead`},[l.renderSlot(S.$slots,"head",{},void 0,!0),S.$slots.search?(l.openBlock(),l.createBlock(Cl,{key:0,class:"table__search-tr",id:(j=i.search)==null?void 0:j.rowId,ref_key:"searchRowRef",ref:c,"data-testid":`${i.dataTestid}-Search-Row`},{default:l.withCtx(()=>{var T;return[l.createVNode(Go,{colspan:i.columnCount||a.maxColumnCount,class:"table__search-th",id:(T=i.search)==null?void 0:T.headId,"data-testid":`${i.dataTestid}-SearchRow-Search`},{default:l.withCtx(()=>[l.renderSlot(S.$slots,"search",{},void 0,!0)]),_:3},8,["colspan","id","data-testid"])]}),_:3},8,["id","data-testid"])):l.createCommentVNode("",!0)],8,B7e)):l.createCommentVNode("",!0),l.renderSlot(S.$slots,"body-group",{},()=>[S.$slots.body?(l.openBlock(),l.createElementBlock("tbody",{key:0,id:i.tbodyId,ref_key:"tbodyRef",ref:u,class:"table__body","data-testid":`${i.dataTestid}-Tbody`},[l.renderSlot(S.$slots,"body",{},void 0,!0)],8,V7e)):l.createCommentVNode("",!0)],!0)]},!0)],8,R7e)]),_:3},8,["is-show-vertical-scroll","is-show-horizontal-scroll","data-testid"]))}}),[["__scopeId","data-v-d2ee85b8"]]),F7e=["data-testid"],Qd=me(l.defineComponent({name:"TableRow",__name:"TableRow",props:{type:{default:"default"},dataTestid:{}},setup(e){const t=e,n=l.computed(()=>[{"table-row_active":t.type==="selected"}]);return(i,r)=>(l.openBlock(),l.createElementBlock("tr",{class:l.normalizeClass(["table-row",n.value]),"data-testid":t.dataTestid},[l.renderSlot(i.$slots,"default",{},void 0,!0)],10,F7e))}}),[["__scopeId","data-v-2bcd1a53"]]),U7e=["rowspan","colspan","data-testid"],Jd=l.defineComponent({name:"TableTd",__name:"TableTd",props:{colspan:{default:1},rowspan:{default:1},dataTestid:{default:"DataCell"}},setup(e){const t=e;return(n,i)=>(l.openBlock(),l.createElementBlock("td",{rowspan:e.rowspan,colspan:e.colspan,class:"table-td","data-testid":t.dataTestid},[l.renderSlot(n.$slots,"default")],8,U7e))}}),B1=me(l.defineComponent({name:"SectionTableRow",__name:"SectionTableRow",props:{colspan:{},dataTestid:{default:"SectionTableRow"}},setup(e){const t=e;return(n,i)=>(l.openBlock(),l.createBlock(Qd,{class:"section-table-row","data-testid":t.dataTestid},{default:l.withCtx(()=>[l.createVNode(Jd,{colspan:e.colspan,class:"section-table-row__td","data-testid":`${t.dataTestid}-DataCell`},{default:l.withCtx(()=>[l.renderSlot(n.$slots,"default",{},void 0,!0)]),_:3},8,["colspan","data-testid"])]),_:3},8,["data-testid"]))}}),[["__scopeId","data-v-43e9ed3e"]]);var V1=(e=>(e.top="top",e.bottom="bottom",e))(V1||{});const Y7e=["data-testid"],X7e=l.defineComponent({__name:"PopoverHover",props:{position:{default:V1.bottom},dataTestid:{default:"PopoverHover"}},setup(e){const t=e,n=l.computed(()=>({"popover-hover-yui-kit":!0,"popover_hover-yui-kit_top":t.position==V1.top}));return(i,r)=>(l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass(n.value),"data-testid":t.dataTestid},[l.renderSlot(i.$slots,"default",{},void 0,!0)],10,Y7e))}}),F1=me(X7e,[["__scopeId","data-v-e6548269"]]),q7e=["disabled","name","value","data-testid"],U1=me(l.defineComponent({name:"Radio",__name:"Radio",props:l.mergeModels({name:{},value:{},disabled:{type:Boolean,default:!1},dataTestid:{default:"Radio"}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,n=l.useModel(e,"modelValue");return(i,r)=>l.withDirectives((l.openBlock(),l.createElementBlock("input",{"onUpdate:modelValue":r[0]||(r[0]=a=>n.value=a),type:"radio",disabled:e.disabled,name:e.name,value:e.value,class:"radio","data-testid":t.dataTestid},null,8,q7e)),[[l.vModelRadio,n.value]])}}),[["__scopeId","data-v-d73c922e"]]),G7e=["data-testid"],K7e=["data-testid"],T4=me(l.defineComponent({name:"ChoosenMiniOptions",__name:"ChoosenMiniOptions",props:{options:{},dataTestid:{default:"ChoosenMiniOptions"}},emits:["remove"],setup(e,{emit:t}){const n=e,i=t,r=a=>{i("remove",a)};return(a,o)=>(l.openBlock(),l.createElementBlock("div",{class:"choosen-mini-options","data-testid":n.dataTestid},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(e.options,(s,u)=>(l.openBlock(),l.createElementBlock("div",{key:s.key,class:"choosen-mini-options__option","data-testid":`${n.dataTestid}-Option-Item${u}`},[l.createVNode(Ft,{"data-testid":`${n.dataTestid}-Badge${u}`,type:l.unref(tt).blue,text:l.unref(Lh)(s)?s.hint:s.value,class:"choosen-mini-options__badges",disabled:""},null,8,["data-testid","type","text"]),l.createVNode(ye,{"data-testid":`${n.dataTestid}-Icon${u}`,name:l.unref(ce).crossLarge,width:10,height:10,class:"choosen-mini-options__cross",onClick:c=>r(s.key)},null,8,["data-testid","name","onClick"])],8,K7e))),128))],8,G7e))}}),[["__scopeId","data-v-65ba1506"]]),Q7e=["data-testid"],J7e=["data-testid"],Z7e=["data-testid"],eCe=["data-testid"],tCe=["data-testid"],nCe=["data-testid"],Y1=me(l.defineComponent({name:"BaseFilter",__name:"BaseFilter",props:l.mergeModels({options:{},title:{},isSearch:{type:Boolean,default:!1},isPosibleToClear:{type:Boolean,default:!1},isShowMiniOptions:{type:Boolean,default:!1},isOpened:{type:Boolean,default:!1},tooltipPosition:{default:"top-center"},onUnmountPagination:{},defaultOption:{default:"Выберите значение"},class:{},disabled:{type:Boolean},dataTestid:{default:"BaseFilter"}},{modelValue:{default:[]},modelModifiers:{}}),emits:l.mergeModels(["change","unmount-open","unmount-search","unmount-search-enter","unmount-pagination"],["update:modelValue"]),setup(e,{emit:t}){const n=e,i=l.reactive({isHovered:!1}),r=t,a=l.ref(null),o=l.ref(null),s=l.useModel(e,"modelValue"),u=l.ref(n.isOpened);l.watch(u,()=>r("unmount-open",u.value)),l.watch(()=>n.isOpened,()=>{u.value=n.isOpened}),l.watch(()=>n.onUnmountPagination,()=>{L()});const c=l.ref(""),f=l.computed(()=>{let N=[];return c.value?(Hs(n.options)?N=n.options.filter(z=>{var H;return z.value.toLowerCase().includes(c.value.toLowerCase())||((H=z==null?void 0:z.hint)==null?void 0:H.toLowerCase().includes(c.value.toLowerCase()))}):N=n.options.filter(z=>z.value.toLowerCase().includes(c.value.toLowerCase())),N):(Hs(n.options),N=n.options,N)}),h=l.computed(()=>{var z;return((z=n.options.find(H=>Hi.isArray(s.value)?s.value.includes(H.key):H.key===String(s.value)))==null?void 0:z.value)||n.defaultOption}),g=l.computed(()=>n.options.filter(N=>Hi.isArray(s.value)?s.value.includes(N.key)&&N.value!==h.value:N.key===String(s.value))),p=l.computed(()=>n.options.filter(N=>Hi.isArray(s.value)?s.value.includes(N.key)&&N.value===h.value:N.key===String(s.value))),y=l.computed(()=>{var H,X,re;const N=n.options;let z;return Hi.isArray(s.value)?Hs(N)?z=(H=N.find(ee=>ee.value===h.value))==null?void 0:H.hint:z=(X=N.find(ee=>ee.value===h.value))==null?void 0:X.value:z=(re=N.find(ee=>ee.key===String(s.value)))==null?void 0:re.value,z||""}),v=()=>{i.isHovered=!0},k=()=>{i.isHovered=!1},w=l.computed(()=>{var N;return Hs(n.options)?i.isHovered&&!!y.value:((N=a.value)==null?void 0:N.isSpanOverflow)||!1}),M=l.computed(()=>Hi.isArray(s.value)?n.isPosibleToClear&&s.value.length>0:n.isPosibleToClear&&s.value),x=l.computed(()=>Hi.isArray(s.value)&&s.value.length>1),S=l.computed(()=>Hi.isArray(s.value)?s.value.length:null),_=async N=>{if(Hi.isArray(s.value))s.value.includes(N)?s.value=s.value.filter(z=>z!==N):s.value=[...s.value,N];else{let z=n.options.find(H=>H.key===N);!z&&Hs(n.options)&&(z=n.options.find(H=>H.hint===N)),s.value=(z==null?void 0:z.key)||"",u.value=!1}await l.nextTick(),r("change",String(s.value))},j=N=>{u.value=N},T=async()=>{Hi.isArray(s.value)?s.value=[]:s.value="",await l.nextTick(),r("change",s.value)},I=new IntersectionObserver(N=>{N.forEach(z=>{z.isIntersecting&&r("unmount-pagination")})}),L=()=>{o.value&&n.onUnmountPagination&&(I.unobserve(o.value),I.observe(o.value))};return l.onMounted(()=>{L()}),l.onUnmounted(()=>{I.disconnect()}),(N,z)=>(l.openBlock(),l.createBlock(vo,{onChange:j,"is-opened":u.value,class:l.normalizeClass(n.class),"header-classes":"filter__header","options-classes":"filter__options","data-testid":n.dataTestid},{header:l.withCtx(()=>[l.createElementVNode("span",{class:l.normalizeClass(["filter__header-title",{"filter__header-title__active":u.value}]),"data-testid":`${n.dataTestid}-Title`},l.toDisplayString(e.title),11,Q7e),l.createVNode(Ml,{position:e.tooltipPosition,type:"blue","is-can-show":w.value&&!(x.value&&e.isShowMiniOptions),hint:y.value,"hint-gap":28,class:"filter__header-tooltip","data-testid":`${n.dataTestid}-Tooltip`},{default:l.withCtx(()=>[l.createVNode(Ft,{ref_key:"badgesRef",ref:a,type:h.value===n.defaultOption?l.unref(tt).default:l.unref(tt).blue,class:"filter__options-badge","data-testid":`${n.dataTestid}-Badge`,text:h.value,onMouseenter:v,onMouseleave:k,disabled:""},null,8,["type","data-testid","text"]),x.value&&e.isShowMiniOptions?(l.openBlock(),l.createElementBlock("div",{key:0,class:"filter__values","data-testid":`${n.dataTestid}-Filter-Value`},[l.createVNode(T4,{"data-testid":`${n.dataTestid}-Filter-Value-MiniOptions`,onClick:z[0]||(z[0]=l.withModifiers(()=>{},["stop"])),options:p.value,onRemove:_},null,8,["data-testid","options"])],8,J7e)):l.createCommentVNode("",!0)]),_:1},8,["position","is-can-show","hint","data-testid"]),S.value&&S.value>1?(l.openBlock(),l.createElementBlock("span",{key:0,class:"filter__count","data-testid":`${n.dataTestid}-Filter-Count`},[l.createTextVNode(" +"+l.toDisplayString(S.value-1)+" ",1),x.value?(l.openBlock(),l.createElementBlock("div",{key:0,class:"filter__values","data-testid":`${n.dataTestid}-Filter-Values`},[l.createVNode(T4,{onClick:z[1]||(z[1]=l.withModifiers(()=>{},["stop"])),options:g.value,onRemove:_,"data-testid":`${n.dataTestid}-MiniOptions`},null,8,["options","data-testid"])],8,eCe)):l.createCommentVNode("",!0)],8,Z7e)):l.createCommentVNode("",!0),M.value?(l.openBlock(),l.createElementBlock("span",{key:1,class:"filter__cross",onClick:l.withModifiers(T,["stop"]),"data-testid":`${n.dataTestid}-Filter-Cross`},[l.createVNode(ye,{name:l.unref(ce).crossLarge,width:16,height:16},null,8,["name"])],8,tCe)):l.createCommentVNode("",!0)]),options:l.withCtx(()=>[e.isSearch?(l.openBlock(),l.createBlock(yl,{key:0,modelValue:c.value,"onUpdate:modelValue":z[2]||(z[2]=H=>c.value=H),"show-history":!1,"data-testid":`${n.dataTestid}-Search`,onInput:z[3]||(z[3]=H=>N.$emit("unmount-search",H)),onEnter:z[4]||(z[4]=H=>N.$emit("unmount-search-enter",H))},null,8,["modelValue","data-testid"])):l.createCommentVNode("",!0),l.createVNode($h,{"data-testid":`${n.dataTestid}-Options`,class:"filter__options-option",options:f.value,"default-option":h.value,onChange:_},{default:l.withCtx(()=>[l.createElementVNode("li",{class:"filter__options-underline","data-testid":`${n.dataTestid}-Underline`},[...z[5]||(z[5]=[l.createElementVNode("hr",{class:"filter__options-underline-hr"},null,-1)])],8,nCe)]),_:1},8,["data-testid","options","default-option"]),l.withDirectives(l.createElementVNode("div",{ref_key:"lastOptionRef",ref:o,class:"filter__last-option"},null,512),[[l.vShow,e.onUnmountPagination]])]),_:1},8,["is-opened","class","data-testid"]))}}),[["__scopeId","data-v-a3d3018c"]]),iCe=["data-testid"],Zd=me(l.defineComponent({name:"Range",__name:"Range",props:l.mergeModels({min:{default:0},max:{default:100},step:{default:1},disabled:{type:Boolean,default:!1},dataTestid:{default:"Range"}},{modelValue:{default:0},modelModifiers:{}}),emits:l.mergeModels(["unmount-change","unmount-input"],["update:modelValue"]),setup(e,{emit:t}){const n=e,i=t,r=l.useModel(e,"modelValue"),a=l.ref(null);l.watch(r,()=>{s()});const o=()=>(r.value-n.min)/(n.max-n.min)*100,s=()=>{requestAnimationFrame(()=>{a.value&&Pt({"--progress":o()+"%"},a.value)})},u=f=>{const h=f.target;h&&i("unmount-change",Number(h.value))},c=f=>{const h=f.target;h&&i("unmount-change",Number(h.value))};return l.onMounted(()=>{s()}),(f,h)=>l.withDirectives((l.openBlock(),l.createElementBlock("input",l.mergeProps({ref_key:"input",ref:a,type:"range"},n,{class:"range","onUpdate:modelValue":h[0]||(h[0]=g=>r.value=g),onChange:u,onInput:c,"data-testid":n.dataTestid}),null,16,iCe)),[[l.vModelText,r.value]])}}),[["__scopeId","data-v-765973ae"]]),rCe=["id","data-testid"],aCe=["data-testid"],oCe=["data-testid"],X1=me(l.defineComponent({name:"TableNew",__name:"TableNew",props:{tableId:{},search:{},tbodyId:{},theadId:{},columnCount:{},dataTestid:{default:"Table"},isShowVerticalScroll:{type:Boolean,default:!1},isShowHorizontalScroll:{type:Boolean,default:!1}},emits:["unmount-scroll","unmount-paginate"],setup(e,{expose:t,emit:n}){var M;const i=e,r=n,a=l.reactive({headHeight:0,maxColumnCount:0}),o=l.ref(null),s=l.ref(null),u=l.ref(null),c=l.ref(null),f=l.ref(null),h=x=>{r("unmount-scroll",x)},g=()=>{if(!o.value||!f.value)return;const x=o.value.querySelector("thead");if(!x)return;const S=x.getBoundingClientRect().height;a.headHeight=S,Pt({"--scroll-track-margin-top":`${S}px`},f.value.$el)},p=()=>{f.value&&f.value.scrollToTop()},y=()=>{if(f.value&&c.value){const x=getComputedStyle(f.value.$el),S=Number(x.minHeight.replace(/\D/g,""));if(S&&S>0)return;Pt({"min-height":`${a.headHeight+108}px`},f.value.$el)}},v=()=>{let x=1;if(s.value){for(let S=0;S<s.value.children.length;S++)x=Math.max(s.value.children[S].children.length,x);a.maxColumnCount=x}},k=new MutationObserver(()=>{v()}),w=new ResizeObserver(()=>{g()});return t({scrollToTop:p,setHeightSlot:(M=f.value)==null?void 0:M.setHeightSlot,tbodyRef:u,tableRef:o,theadRef:s}),l.onMounted(()=>{g(),v(),window.addEventListener("resize",g),o.value&&w.observe(o.value),s.value&&k.observe(s.value,{childList:!0,subtree:!0}),y()}),(x,S)=>(l.openBlock(),l.createBlock(xl,{ref_key:"scrollWrapperRef",ref:f,class:"table",onUnmountScroll:h,"is-show-vertical-scroll":i.isShowVerticalScroll,"is-show-horizontal-scroll":i.isShowHorizontalScroll,"data-testid":`${i.dataTestid}-ScrollWrapper`},{default:l.withCtx(()=>[l.createElementVNode("table",{ref_key:"tableRef",ref:o,id:i.tableId,class:"table__table","data-testid":`${i.dataTestid}`},[l.renderSlot(x.$slots,"default",{},()=>[l.createElementVNode("colgroup",null,[l.renderSlot(x.$slots,"colspan",{},void 0,!0)]),x.$slots.head?(l.openBlock(),l.createElementBlock("thead",{key:0,ref_key:"theadRef",ref:s,class:"table__head","data-testid":`${i.dataTestid}-Thead`},[l.renderSlot(x.$slots,"head",{},void 0,!0),x.$slots.search?(l.openBlock(),l.createBlock(Cl,{key:0,class:"table__search-tr",ref_key:"searchRowRef",ref:c,"data-testid":`${i.dataTestid}-Search-Row`},{default:l.withCtx(()=>[l.createVNode(Go,{colspan:a.maxColumnCount,class:"table__search-th","data-testid":`${i.dataTestid}-SearchRow-Search`},{default:l.withCtx(()=>[l.renderSlot(x.$slots,"search",{},void 0,!0)]),_:3},8,["colspan","data-testid"])]),_:3},8,["data-testid"])):l.createCommentVNode("",!0)],8,aCe)):l.createCommentVNode("",!0),l.renderSlot(x.$slots,"body-group",{},()=>[x.$slots.body?(l.openBlock(),l.createElementBlock("tbody",{key:0,ref_key:"tbodyRef",ref:u,class:"table__body","data-testid":`${i.dataTestid}-Tbody`},[l.renderSlot(x.$slots,"body",{},void 0,!0)],8,oCe)):l.createCommentVNode("",!0)],!0)],!0)],8,rCe)]),_:3},8,["is-show-vertical-scroll","is-show-horizontal-scroll","data-testid"]))}}),[["__scopeId","data-v-4951b36e"]]),sCe=["data-testid"],q1=me(l.defineComponent({name:"TableRow",__name:"TableRowNew",props:{type:{default:"default"},dataTestid:{}},setup(e){const t=e,n=l.computed(()=>[{"table-row_active":t.type==="selected"}]);return(i,r)=>(l.openBlock(),l.createElementBlock("tr",{class:l.normalizeClass(["table-row",n.value]),"data-testid":t.dataTestid},[l.renderSlot(i.$slots,"default",{},void 0,!0)],10,sCe))}}),[["__scopeId","data-v-b142a9a4"]]),lCe=["data-testid"],ec=me(l.defineComponent({name:"HeadTableRow",__name:"HeadTableRowNew",props:{dataTestid:{default:"TableRow"}},setup(e){const t=e;return(n,i)=>(l.openBlock(),l.createElementBlock("tr",{class:"head-table-row","data-testid":t.dataTestid},[l.renderSlot(n.$slots,"default",{},void 0,!0)],8,lCe))}}),[["__scopeId","data-v-1cac20aa"]]),uCe={class:"scroll-wrapper__vertical-wrapper"},dCe={class:"scroll-wrapper__horizont-wrapper"},cCe=me(l.defineComponent({name:"ScrollWrapper",__name:"ScrollWrapperNew",props:{isShowVerticalScroll:{type:Boolean,default:!1},isShowHorizontalScroll:{type:Boolean,default:!1}},emits:["unmount-scroll","unmount-paginate","on-mounted"],setup(e,{expose:t,emit:n}){const i=n,r=l.ref(null),a=l.ref(null),o=l.ref(null),s=l.ref(null),u=l.ref(null),c=l.ref(null),{onTrackClick:f,startDrag:h,changeBarPosition:g,setVerticalBarHeight:p,verticalTrackClass:y,isExistVerticalTrack:v}=_4(r,a,s,o),{changeBarPosition:k,startDrag:w,onTrackClick:M,setHorizontalBarWidth:x,horizontalTrackClass:S,isExistHorizontalTrack:_}=S4(r,a,c,u),j=ee=>{g(),k(),i("unmount-scroll",ee)},T=()=>{requestAnimationFrame(()=>{I(),L()})},I=()=>{if(!r.value||!a.value)return;const ee=getComputedStyle(a.value),q=a.value.style.minHeight||ee.minHeight,Z=a.value.style.maxHeight||ee.maxHeight,ue=a.value.style.height;Pt({"--scroll-wrapper-height":`${ue}`,"--scroll-wrapper-max-height":`${Z}`,"--scroll-wrapper-min-height":`${q}`},a.value)},L=()=>{p(),x(),g(),k()},N=()=>{r.value&&r.value.addEventListener("scroll",j)},z=()=>{r.value&&(r.value.scrollTop=0)},H=new MutationObserver(()=>{T()}),X=new ResizeObserver(()=>{T()}),re=ee=>{H.observe(ee,{childList:!0,subtree:!0,attributes:!0}),X.observe(ee)};return t({scrollToTop:z,setHeightSlot:I}),l.onMounted(()=>{T(),N(),a.value&&re(a.value),o.value&&re(o.value),window.addEventListener("resize",T),i("on-mounted")}),l.onUnmounted(()=>{window.removeEventListener("resize",T)}),(ee,q)=>(l.openBlock(),l.createElementBlock("div",{ref_key:"scrollWrapperRef",ref:a,class:"scroll-wrapper"},[l.createElementVNode("div",uCe,[l.createElementVNode("div",dCe,[l.createElementVNode("div",{ref_key:"slotRef",ref:r,class:"scroll-wrapper__slot"},[l.renderSlot(ee.$slots,"default",{},void 0,!0)],512),l.unref(_)||e.isShowHorizontalScroll?(l.openBlock(),l.createElementBlock("div",{key:0,ref_key:"horizontTrackRef",ref:u,class:l.normalizeClass(["scroll-wrapper__track scroll-wrapper__track_horizont",l.unref(S)]),onClick:q[1]||(q[1]=l.withModifiers((...Z)=>l.unref(M)&&l.unref(M)(...Z),["prevent","left"]))},[l.createElementVNode("div",{ref_key:"horizontBarRef",ref:c,class:"scroll-wrapper__bar",onMousedown:q[0]||(q[0]=l.withModifiers((...Z)=>l.unref(w)&&l.unref(w)(...Z),["prevent","left"]))},null,544)],2)):l.createCommentVNode("",!0)]),l.unref(v)||e.isShowVerticalScroll?(l.openBlock(),l.createElementBlock("div",{key:0,ref_key:"verticalTrackRef",ref:o,class:l.normalizeClass(["scroll-wrapper__track scroll-wrapper__track_vertical",l.unref(y)]),onClick:q[3]||(q[3]=l.withModifiers((...Z)=>l.unref(f)&&l.unref(f)(...Z),["prevent","left"]))},[l.createElementVNode("div",{ref_key:"verticalBarRef",ref:s,class:"scroll-wrapper__bar",onMousedown:q[2]||(q[2]=l.withModifiers((...Z)=>l.unref(h)&&l.unref(h)(...Z),["prevent","left"]))},null,544)],2)):l.createCommentVNode("",!0)])],512))}}),[["__scopeId","data-v-b541879b"]]),fCe=["data-testid"],hCe=["data-testid"],mCe=["data-testid"],G1=me(l.defineComponent({name:"TableSimple",__name:"TableSimple",props:{dataTestid:{default:"TableSimple"}},setup(e,{expose:t}){const n=e,i=l.ref(null),r=l.ref(null),a=l.ref(null),o=l.ref(null),s=l.computed(()=>{let u=1;if(r.value)for(let c=0;c<r.value.children.length;c++)u=Math.max(r.value.children[c].children.length,u);return u});return t({tbodyRef:a,tableRef:i,theadRef:r}),(u,c)=>(l.openBlock(),l.createElementBlock("table",{ref_key:"tableRef",ref:i,class:"simple-table-yui-kit","data-testid":`${n.dataTestid}`},[l.renderSlot(u.$slots,"default",{},()=>[l.renderSlot(u.$slots,"colspan",{},void 0,!0),u.$slots.head?(l.openBlock(),l.createElementBlock("thead",{key:0,ref_key:"theadRef",ref:r,class:"simple-table-yui-kit__head","data-testid":`${n.dataTestid}-Thead`},[l.renderSlot(u.$slots,"head",{},void 0,!0),u.$slots.search?(l.openBlock(),l.createBlock(ec,{key:0,class:"table-new-yui-kit__search",ref_key:"searchRowRef",ref:o,"data-testid":`${n.dataTestid}-Search-Row`},{default:l.withCtx(()=>[l.createVNode(Go,{colspan:s.value,class:"table-new-yui-kit__th","data-testid":`${n.dataTestid}-SearchRow-Search`},{default:l.withCtx(()=>[l.renderSlot(u.$slots,"search",{},void 0,!0)]),_:3},8,["colspan","data-testid"])]),_:3},8,["data-testid"])):l.createCommentVNode("",!0)],8,hCe)):l.createCommentVNode("",!0),l.renderSlot(u.$slots,"body-group",{},()=>[u.$slots.body?(l.openBlock(),l.createElementBlock("tbody",{key:0,ref_key:"tbodyRef",ref:a,class:"simple-table-yui-kit__body","data-testid":`${n.dataTestid}-Tbody`},[l.renderSlot(u.$slots,"body",{},void 0,!0)],8,mCe)):l.createCommentVNode("",!0)],!0)],!0)],8,fCe))}}),[["__scopeId","data-v-834ebe10"]]),pCe=["data-testid"],gCe=["data-testid"],yCe=["onClick","data-testid"],bCe=["data-testid"],K1=me(l.defineComponent({name:"Tabs",__name:"Tabs",props:{tabCount:{},dataTestid:{default:"Tabs"}},emits:["unmount-tab"],setup(e,{emit:t}){const n=e,i=t,r=l.reactive({activeTab:1}),a=s=>Array.from({length:s},(u,c)=>c+1),o=s=>{r.activeTab=s,i("unmount-tab",s)};return(s,u)=>(l.openBlock(),l.createElementBlock("div",{"data-testid":n.dataTestid,class:"tabs"},[l.createElementVNode("nav",{class:"tabs__navigation","data-testid":`${n.dataTestid}-Navigation`},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(a(n.tabCount),c=>(l.openBlock(),l.createElementBlock("button",{key:c,onClick:f=>o(c),class:l.normalizeClass(["tabs__navigation-button",{active:r.activeTab===c}]),"data-testid":`${n.dataTestid}-Navigation-Button`},[l.renderSlot(s.$slots,`header${c}`,{},void 0,!0)],10,yCe))),128))],8,gCe),(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(a(n.tabCount),c=>(l.openBlock(),l.createElementBlock(l.Fragment,{key:c},[r.activeTab===c?(l.openBlock(),l.createElementBlock("article",{key:0,"data-testid":`${n.dataTestid}-Content`,class:"tabs__navigation-content"},[l.renderSlot(s.$slots,`tab${c}`,{},void 0,!0)],8,bCe)):l.createCommentVNode("",!0)],64))),128))],8,pCe))}}),[["__scopeId","data-v-eb8ab4da"]]);function Lt(e){this.content=e}Lt.prototype={constructor:Lt,find:function(e){for(var t=0;t<this.content.length;t+=2)if(this.content[t]===e)return t;return-1},get:function(e){var t=this.find(e);return t==-1?void 0:this.content[t+1]},update:function(e,t,n){var i=n&&n!=e?this.remove(n):this,r=i.find(e),a=i.content.slice();return r==-1?a.push(n||e,t):(a[r+1]=t,n&&(a[r]=n)),new Lt(a)},remove:function(e){var t=this.find(e);if(t==-1)return this;var n=this.content.slice();return n.splice(t,2),new Lt(n)},addToStart:function(e,t){return new Lt([e,t].concat(this.remove(e).content))},addToEnd:function(e,t){var n=this.remove(e).content.slice();return n.push(e,t),new Lt(n)},addBefore:function(e,t,n){var i=this.remove(t),r=i.content.slice(),a=i.find(e);return r.splice(a==-1?r.length:a,0,t,n),new Lt(r)},forEach:function(e){for(var t=0;t<this.content.length;t+=2)e(this.content[t],this.content[t+1])},prepend:function(e){return e=Lt.from(e),e.size?new Lt(e.content.concat(this.subtract(e).content)):this},append:function(e){return e=Lt.from(e),e.size?new Lt(this.subtract(e).content.concat(e.content)):this},subtract:function(e){var t=this;e=Lt.from(e);for(var n=0;n<e.content.length;n+=2)t=t.remove(e.content[n]);return t},toObject:function(){var e={};return this.forEach(function(t,n){e[t]=n}),e},get size(){return this.content.length>>1}},Lt.from=function(e){if(e instanceof Lt)return e;var t=[];if(e)for(var n in e)t.push(n,e[n]);return new Lt(t)};function P4(e,t,n){for(let i=0;;i++){if(i==e.childCount||i==t.childCount)return e.childCount==t.childCount?null:n;let r=e.child(i),a=t.child(i);if(r==a){n+=r.nodeSize;continue}if(!r.sameMarkup(a))return n;if(r.isText&&r.text!=a.text){for(let o=0;r.text[o]==a.text[o];o++)n++;return n}if(r.content.size||a.content.size){let o=P4(r.content,a.content,n+1);if(o!=null)return o}n+=r.nodeSize}}function E4(e,t,n,i){for(let r=e.childCount,a=t.childCount;;){if(r==0||a==0)return r==a?null:{a:n,b:i};let o=e.child(--r),s=t.child(--a),u=o.nodeSize;if(o==s){n-=u,i-=u;continue}if(!o.sameMarkup(s))return{a:n,b:i};if(o.isText&&o.text!=s.text){let c=0,f=Math.min(o.text.length,s.text.length);for(;c<f&&o.text[o.text.length-c-1]==s.text[s.text.length-c-1];)c++,n--,i--;return{a:n,b:i}}if(o.content.size||s.content.size){let c=E4(o.content,s.content,n-1,i-1);if(c)return c}n-=u,i-=u}}class ne{constructor(t,n){if(this.content=t,this.size=n||0,n==null)for(let i=0;i<t.length;i++)this.size+=t[i].nodeSize}nodesBetween(t,n,i,r=0,a){for(let o=0,s=0;s<n;o++){let u=this.content[o],c=s+u.nodeSize;if(c>t&&i(u,r+s,a||null,o)!==!1&&u.content.size){let f=s+1;u.nodesBetween(Math.max(0,t-f),Math.min(u.content.size,n-f),i,r+f)}s=c}}descendants(t){this.nodesBetween(0,this.size,t)}textBetween(t,n,i,r){let a="",o=!0;return this.nodesBetween(t,n,(s,u)=>{let c=s.isText?s.text.slice(Math.max(t,u)-u,n-u):s.isLeaf?r?typeof r=="function"?r(s):r:s.type.spec.leafText?s.type.spec.leafText(s):"":"";s.isBlock&&(s.isLeaf&&c||s.isTextblock)&&i&&(o?o=!1:a+=i),a+=c},0),a}append(t){if(!t.size)return this;if(!this.size)return t;let n=this.lastChild,i=t.firstChild,r=this.content.slice(),a=0;for(n.isText&&n.sameMarkup(i)&&(r[r.length-1]=n.withText(n.text+i.text),a=1);a<t.content.length;a++)r.push(t.content[a]);return new ne(r,this.size+t.size)}cut(t,n=this.size){if(t==0&&n==this.size)return this;let i=[],r=0;if(n>t)for(let a=0,o=0;o<n;a++){let s=this.content[a],u=o+s.nodeSize;u>t&&((o<t||u>n)&&(s.isText?s=s.cut(Math.max(0,t-o),Math.min(s.text.length,n-o)):s=s.cut(Math.max(0,t-o-1),Math.min(s.content.size,n-o-1))),i.push(s),r+=s.nodeSize),o=u}return new ne(i,r)}cutByIndex(t,n){return t==n?ne.empty:t==0&&n==this.content.length?this:new ne(this.content.slice(t,n))}replaceChild(t,n){let i=this.content[t];if(i==n)return this;let r=this.content.slice(),a=this.size+n.nodeSize-i.nodeSize;return r[t]=n,new ne(r,a)}addToStart(t){return new ne([t].concat(this.content),this.size+t.nodeSize)}addToEnd(t){return new ne(this.content.concat(t),this.size+t.nodeSize)}eq(t){if(this.content.length!=t.content.length)return!1;for(let n=0;n<this.content.length;n++)if(!this.content[n].eq(t.content[n]))return!1;return!0}get firstChild(){return this.content.length?this.content[0]:null}get lastChild(){return this.content.length?this.content[this.content.length-1]:null}get childCount(){return this.content.length}child(t){let n=this.content[t];if(!n)throw new RangeError("Index "+t+" out of range for "+this);return n}maybeChild(t){return this.content[t]||null}forEach(t){for(let n=0,i=0;n<this.content.length;n++){let r=this.content[n];t(r,i,n),i+=r.nodeSize}}findDiffStart(t,n=0){return P4(this,t,n)}findDiffEnd(t,n=this.size,i=t.size){return E4(this,t,n,i)}findIndex(t){if(t==0)return tc(0,t);if(t==this.size)return tc(this.content.length,t);if(t>this.size||t<0)throw new RangeError(`Position ${t} outside of fragment (${this})`);for(let n=0,i=0;;n++){let r=this.child(n),a=i+r.nodeSize;if(a>=t)return a==t?tc(n+1,a):tc(n,i);i=a}}toString(){return"<"+this.toStringInner()+">"}toStringInner(){return this.content.join(", ")}toJSON(){return this.content.length?this.content.map(t=>t.toJSON()):null}static fromJSON(t,n){if(!n)return ne.empty;if(!Array.isArray(n))throw new RangeError("Invalid input for Fragment.fromJSON");return new ne(n.map(t.nodeFromJSON))}static fromArray(t){if(!t.length)return ne.empty;let n,i=0;for(let r=0;r<t.length;r++){let a=t[r];i+=a.nodeSize,r&&a.isText&&t[r-1].sameMarkup(a)?(n||(n=t.slice(0,r)),n[n.length-1]=a.withText(n[n.length-1].text+a.text)):n&&n.push(a)}return new ne(n||t,i)}static from(t){if(!t)return ne.empty;if(t instanceof ne)return t;if(Array.isArray(t))return this.fromArray(t);if(t.attrs)return new ne([t],t.nodeSize);throw new RangeError("Can not convert "+t+" to a Fragment"+(t.nodesBetween?" (looks like multiple versions of prosemirror-model were loaded)":""))}}ne.empty=new ne([],0);const Q1={index:0,offset:0};function tc(e,t){return Q1.index=e,Q1.offset=t,Q1}function nc(e,t){if(e===t)return!0;if(!(e&&typeof e=="object")||!(t&&typeof t=="object"))return!1;let n=Array.isArray(e);if(Array.isArray(t)!=n)return!1;if(n){if(e.length!=t.length)return!1;for(let i=0;i<e.length;i++)if(!nc(e[i],t[i]))return!1}else{for(let i in e)if(!(i in t)||!nc(e[i],t[i]))return!1;for(let i in t)if(!(i in e))return!1}return!0}let Ge=class wy{constructor(t,n){this.type=t,this.attrs=n}addToSet(t){let n,i=!1;for(let r=0;r<t.length;r++){let a=t[r];if(this.eq(a))return t;if(this.type.excludes(a.type))n||(n=t.slice(0,r));else{if(a.type.excludes(this.type))return t;!i&&a.type.rank>this.type.rank&&(n||(n=t.slice(0,r)),n.push(this),i=!0),n&&n.push(a)}}return n||(n=t.slice()),i||n.push(this),n}removeFromSet(t){for(let n=0;n<t.length;n++)if(this.eq(t[n]))return t.slice(0,n).concat(t.slice(n+1));return t}isInSet(t){for(let n=0;n<t.length;n++)if(this.eq(t[n]))return!0;return!1}eq(t){return this==t||this.type==t.type&&nc(this.attrs,t.attrs)}toJSON(){let t={type:this.type.name};for(let n in this.attrs){t.attrs=this.attrs;break}return t}static fromJSON(t,n){if(!n)throw new RangeError("Invalid input for Mark.fromJSON");let i=t.marks[n.type];if(!i)throw new RangeError(`There is no mark type ${n.type} in this schema`);let r=i.create(n.attrs);return i.checkAttrs(r.attrs),r}static sameSet(t,n){if(t==n)return!0;if(t.length!=n.length)return!1;for(let i=0;i<t.length;i++)if(!t[i].eq(n[i]))return!1;return!0}static setFrom(t){if(!t||Array.isArray(t)&&t.length==0)return wy.none;if(t instanceof wy)return[t];let n=t.slice();return n.sort((i,r)=>i.type.rank-r.type.rank),n}};Ge.none=[];class ic extends Error{}class le{constructor(t,n,i){this.content=t,this.openStart=n,this.openEnd=i}get size(){return this.content.size-this.openStart-this.openEnd}insertAt(t,n){let i=N4(this.content,t+this.openStart,n);return i&&new le(i,this.openStart,this.openEnd)}removeBetween(t,n){return new le(A4(this.content,t+this.openStart,n+this.openStart),this.openStart,this.openEnd)}eq(t){return this.content.eq(t.content)&&this.openStart==t.openStart&&this.openEnd==t.openEnd}toString(){return this.content+"("+this.openStart+","+this.openEnd+")"}toJSON(){if(!this.content.size)return null;let t={content:this.content.toJSON()};return this.openStart>0&&(t.openStart=this.openStart),this.openEnd>0&&(t.openEnd=this.openEnd),t}static fromJSON(t,n){if(!n)return le.empty;let i=n.openStart||0,r=n.openEnd||0;if(typeof i!="number"||typeof r!="number")throw new RangeError("Invalid input for Slice.fromJSON");return new le(ne.fromJSON(t,n.content),i,r)}static maxOpen(t,n=!0){let i=0,r=0;for(let a=t.firstChild;a&&!a.isLeaf&&(n||!a.type.spec.isolating);a=a.firstChild)i++;for(let a=t.lastChild;a&&!a.isLeaf&&(n||!a.type.spec.isolating);a=a.lastChild)r++;return new le(t,i,r)}}le.empty=new le(ne.empty,0,0);function A4(e,t,n){let{index:i,offset:r}=e.findIndex(t),a=e.maybeChild(i),{index:o,offset:s}=e.findIndex(n);if(r==t||a.isText){if(s!=n&&!e.child(o).isText)throw new RangeError("Removing non-flat range");return e.cut(0,t).append(e.cut(n))}if(i!=o)throw new RangeError("Removing non-flat range");return e.replaceChild(i,a.copy(A4(a.content,t-r-1,n-r-1)))}function N4(e,t,n,i){let{index:r,offset:a}=e.findIndex(t),o=e.maybeChild(r);if(a==t||o.isText)return i&&!i.canReplace(r,r,n)?null:e.cut(0,t).append(n).append(e.cut(t));let s=N4(o.content,t-a-1,n,o);return s&&e.replaceChild(r,o.copy(s))}function wCe(e,t,n){if(n.openStart>e.depth)throw new ic("Inserted content deeper than insertion position");if(e.depth-n.openStart!=t.depth-n.openEnd)throw new ic("Inconsistent open depths");return D4(e,t,n,0)}function D4(e,t,n,i){let r=e.index(i),a=e.node(i);if(r==t.index(i)&&i<e.depth-n.openStart){let o=D4(e,t,n,i+1);return a.copy(a.content.replaceChild(r,o))}else if(n.content.size)if(!n.openStart&&!n.openEnd&&e.depth==i&&t.depth==i){let o=e.parent,s=o.content;return Fa(o,s.cut(0,e.parentOffset).append(n.content).append(s.cut(t.parentOffset)))}else{let{start:o,end:s}=vCe(n,e);return Fa(a,I4(e,o,s,t,i))}else return Fa(a,rc(e,t,i))}function j4(e,t){if(!t.type.compatibleContent(e.type))throw new ic("Cannot join "+t.type.name+" onto "+e.type.name)}function J1(e,t,n){let i=e.node(n);return j4(i,t.node(n)),i}function Va(e,t){let n=t.length-1;n>=0&&e.isText&&e.sameMarkup(t[n])?t[n]=e.withText(t[n].text+e.text):t.push(e)}function Sl(e,t,n,i){let r=(t||e).node(n),a=0,o=t?t.index(n):r.childCount;e&&(a=e.index(n),e.depth>n?a++:e.textOffset&&(Va(e.nodeAfter,i),a++));for(let s=a;s<o;s++)Va(r.child(s),i);t&&t.depth==n&&t.textOffset&&Va(t.nodeBefore,i)}function Fa(e,t){return e.type.checkContent(t),e.copy(t)}function I4(e,t,n,i,r){let a=e.depth>r&&J1(e,t,r+1),o=i.depth>r&&J1(n,i,r+1),s=[];return Sl(null,e,r,s),a&&o&&t.index(r)==n.index(r)?(j4(a,o),Va(Fa(a,I4(e,t,n,i,r+1)),s)):(a&&Va(Fa(a,rc(e,t,r+1)),s),Sl(t,n,r,s),o&&Va(Fa(o,rc(n,i,r+1)),s)),Sl(i,null,r,s),new ne(s)}function rc(e,t,n){let i=[];if(Sl(null,e,n,i),e.depth>n){let r=J1(e,t,n+1);Va(Fa(r,rc(e,t,n+1)),i)}return Sl(t,null,n,i),new ne(i)}function vCe(e,t){let n=t.depth-e.openStart,r=t.node(n).copy(e.content);for(let a=n-1;a>=0;a--)r=t.node(a).copy(ne.from(r));return{start:r.resolveNoCache(e.openStart+n),end:r.resolveNoCache(r.content.size-e.openEnd-n)}}class _l{constructor(t,n,i){this.pos=t,this.path=n,this.parentOffset=i,this.depth=n.length/3-1}resolveDepth(t){return t==null?this.depth:t<0?this.depth+t:t}get parent(){return this.node(this.depth)}get doc(){return this.node(0)}node(t){return this.path[this.resolveDepth(t)*3]}index(t){return this.path[this.resolveDepth(t)*3+1]}indexAfter(t){return t=this.resolveDepth(t),this.index(t)+(t==this.depth&&!this.textOffset?0:1)}start(t){return t=this.resolveDepth(t),t==0?0:this.path[t*3-1]+1}end(t){return t=this.resolveDepth(t),this.start(t)+this.node(t).content.size}before(t){if(t=this.resolveDepth(t),!t)throw new RangeError("There is no position before the top-level node");return t==this.depth+1?this.pos:this.path[t*3-1]}after(t){if(t=this.resolveDepth(t),!t)throw new RangeError("There is no position after the top-level node");return t==this.depth+1?this.pos:this.path[t*3-1]+this.path[t*3].nodeSize}get textOffset(){return this.pos-this.path[this.path.length-1]}get nodeAfter(){let t=this.parent,n=this.index(this.depth);if(n==t.childCount)return null;let i=this.pos-this.path[this.path.length-1],r=t.child(n);return i?t.child(n).cut(i):r}get nodeBefore(){let t=this.index(this.depth),n=this.pos-this.path[this.path.length-1];return n?this.parent.child(t).cut(0,n):t==0?null:this.parent.child(t-1)}posAtIndex(t,n){n=this.resolveDepth(n);let i=this.path[n*3],r=n==0?0:this.path[n*3-1]+1;for(let a=0;a<t;a++)r+=i.child(a).nodeSize;return r}marks(){let t=this.parent,n=this.index();if(t.content.size==0)return Ge.none;if(this.textOffset)return t.child(n).marks;let i=t.maybeChild(n-1),r=t.maybeChild(n);if(!i){let s=i;i=r,r=s}let a=i.marks;for(var o=0;o<a.length;o++)a[o].type.spec.inclusive===!1&&(!r||!a[o].isInSet(r.marks))&&(a=a[o--].removeFromSet(a));return a}marksAcross(t){let n=this.parent.maybeChild(this.index());if(!n||!n.isInline)return null;let i=n.marks,r=t.parent.maybeChild(t.index());for(var a=0;a<i.length;a++)i[a].type.spec.inclusive===!1&&(!r||!i[a].isInSet(r.marks))&&(i=i[a--].removeFromSet(i));return i}sharedDepth(t){for(let n=this.depth;n>0;n--)if(this.start(n)<=t&&this.end(n)>=t)return n;return 0}blockRange(t=this,n){if(t.pos<this.pos)return t.blockRange(this);for(let i=this.depth-(this.parent.inlineContent||this.pos==t.pos?1:0);i>=0;i--)if(t.pos<=this.end(i)&&(!n||n(this.node(i))))return new ac(this,t,i);return null}sameParent(t){return this.pos-this.parentOffset==t.pos-t.parentOffset}max(t){return t.pos>this.pos?t:this}min(t){return t.pos<this.pos?t:this}toString(){let t="";for(let n=1;n<=this.depth;n++)t+=(t?"/":"")+this.node(n).type.name+"_"+this.index(n-1);return t+":"+this.parentOffset}static resolve(t,n){if(!(n>=0&&n<=t.content.size))throw new RangeError("Position "+n+" out of range");let i=[],r=0,a=n;for(let o=t;;){let{index:s,offset:u}=o.content.findIndex(a),c=a-u;if(i.push(o,s,r+u),!c||(o=o.child(s),o.isText))break;a=c-1,r+=u+1}return new _l(n,i,a)}static resolveCached(t,n){let i=W4.get(t);if(i)for(let a=0;a<i.elts.length;a++){let o=i.elts[a];if(o.pos==n)return o}else W4.set(t,i=new kCe);let r=i.elts[i.i]=_l.resolve(t,n);return i.i=(i.i+1)%MCe,r}}class kCe{constructor(){this.elts=[],this.i=0}}const MCe=12,W4=new WeakMap;class ac{constructor(t,n,i){this.$from=t,this.$to=n,this.depth=i}get start(){return this.$from.before(this.depth+1)}get end(){return this.$to.after(this.depth+1)}get parent(){return this.$from.node(this.depth)}get startIndex(){return this.$from.index(this.depth)}get endIndex(){return this.$to.indexAfter(this.depth)}}const CCe=Object.create(null);let Hr=class vy{constructor(t,n,i,r=Ge.none){this.type=t,this.attrs=n,this.marks=r,this.content=i||ne.empty}get children(){return this.content.content}get nodeSize(){return this.isLeaf?1:2+this.content.size}get childCount(){return this.content.childCount}child(t){return this.content.child(t)}maybeChild(t){return this.content.maybeChild(t)}forEach(t){this.content.forEach(t)}nodesBetween(t,n,i,r=0){this.content.nodesBetween(t,n,i,r,this)}descendants(t){this.nodesBetween(0,this.content.size,t)}get textContent(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,"")}textBetween(t,n,i,r){return this.content.textBetween(t,n,i,r)}get firstChild(){return this.content.firstChild}get lastChild(){return this.content.lastChild}eq(t){return this==t||this.sameMarkup(t)&&this.content.eq(t.content)}sameMarkup(t){return this.hasMarkup(t.type,t.attrs,t.marks)}hasMarkup(t,n,i){return this.type==t&&nc(this.attrs,n||t.defaultAttrs||CCe)&&Ge.sameSet(this.marks,i||Ge.none)}copy(t=null){return t==this.content?this:new vy(this.type,this.attrs,t,this.marks)}mark(t){return t==this.marks?this:new vy(this.type,this.attrs,this.content,t)}cut(t,n=this.content.size){return t==0&&n==this.content.size?this:this.copy(this.content.cut(t,n))}slice(t,n=this.content.size,i=!1){if(t==n)return le.empty;let r=this.resolve(t),a=this.resolve(n),o=i?0:r.sharedDepth(n),s=r.start(o),c=r.node(o).content.cut(r.pos-s,a.pos-s);return new le(c,r.depth-o,a.depth-o)}replace(t,n,i){return wCe(this.resolve(t),this.resolve(n),i)}nodeAt(t){for(let n=this;;){let{index:i,offset:r}=n.content.findIndex(t);if(n=n.maybeChild(i),!n)return null;if(r==t||n.isText)return n;t-=r+1}}childAfter(t){let{index:n,offset:i}=this.content.findIndex(t);return{node:this.content.maybeChild(n),index:n,offset:i}}childBefore(t){if(t==0)return{node:null,index:0,offset:0};let{index:n,offset:i}=this.content.findIndex(t);if(i<t)return{node:this.content.child(n),index:n,offset:i};let r=this.content.child(n-1);return{node:r,index:n-1,offset:i-r.nodeSize}}resolve(t){return _l.resolveCached(this,t)}resolveNoCache(t){return _l.resolve(this,t)}rangeHasMark(t,n,i){let r=!1;return n>t&&this.nodesBetween(t,n,a=>(i.isInSet(a.marks)&&(r=!0),!r)),r}get isBlock(){return this.type.isBlock}get isTextblock(){return this.type.isTextblock}get inlineContent(){return this.type.inlineContent}get isInline(){return this.type.isInline}get isText(){return this.type.isText}get isLeaf(){return this.type.isLeaf}get isAtom(){return this.type.isAtom}toString(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);let t=this.type.name;return this.content.size&&(t+="("+this.content.toStringInner()+")"),O4(this.marks,t)}contentMatchAt(t){let n=this.type.contentMatch.matchFragment(this.content,0,t);if(!n)throw new Error("Called contentMatchAt on a node with invalid content");return n}canReplace(t,n,i=ne.empty,r=0,a=i.childCount){let o=this.contentMatchAt(t).matchFragment(i,r,a),s=o&&o.matchFragment(this.content,n);if(!s||!s.validEnd)return!1;for(let u=r;u<a;u++)if(!this.type.allowsMarks(i.child(u).marks))return!1;return!0}canReplaceWith(t,n,i,r){if(r&&!this.type.allowsMarks(r))return!1;let a=this.contentMatchAt(t).matchType(i),o=a&&a.matchFragment(this.content,n);return o?o.validEnd:!1}canAppend(t){return t.content.size?this.canReplace(this.childCount,this.childCount,t.content):this.type.compatibleContent(t.type)}check(){this.type.checkContent(this.content),this.type.checkAttrs(this.attrs);let t=Ge.none;for(let n=0;n<this.marks.length;n++){let i=this.marks[n];i.type.checkAttrs(i.attrs),t=i.addToSet(t)}if(!Ge.sameSet(t,this.marks))throw new RangeError(`Invalid collection of marks for node ${this.type.name}: ${this.marks.map(n=>n.type.name)}`);this.content.forEach(n=>n.check())}toJSON(){let t={type:this.type.name};for(let n in this.attrs){t.attrs=this.attrs;break}return this.content.size&&(t.content=this.content.toJSON()),this.marks.length&&(t.marks=this.marks.map(n=>n.toJSON())),t}static fromJSON(t,n){if(!n)throw new RangeError("Invalid input for Node.fromJSON");let i;if(n.marks){if(!Array.isArray(n.marks))throw new RangeError("Invalid mark data for Node.fromJSON");i=n.marks.map(t.markFromJSON)}if(n.type=="text"){if(typeof n.text!="string")throw new RangeError("Invalid text node in JSON");return t.text(n.text,i)}let r=ne.fromJSON(t,n.content),a=t.nodeType(n.type).create(n.attrs,r,i);return a.type.checkAttrs(a.attrs),a}};Hr.prototype.text=void 0;class oc extends Hr{constructor(t,n,i,r){if(super(t,n,null,r),!i)throw new RangeError("Empty text nodes are not allowed");this.text=i}toString(){return this.type.spec.toDebugString?this.type.spec.toDebugString(this):O4(this.marks,JSON.stringify(this.text))}get textContent(){return this.text}textBetween(t,n){return this.text.slice(t,n)}get nodeSize(){return this.text.length}mark(t){return t==this.marks?this:new oc(this.type,this.attrs,this.text,t)}withText(t){return t==this.text?this:new oc(this.type,this.attrs,t,this.marks)}cut(t=0,n=this.text.length){return t==0&&n==this.text.length?this:this.withText(this.text.slice(t,n))}eq(t){return this.sameMarkup(t)&&this.text==t.text}toJSON(){let t=super.toJSON();return t.text=this.text,t}}function O4(e,t){for(let n=e.length-1;n>=0;n--)t=e[n].type.name+"("+t+")";return t}class Ua{constructor(t){this.validEnd=t,this.next=[],this.wrapCache=[]}static parse(t,n){let i=new xCe(t,n);if(i.next==null)return Ua.empty;let r=z4(i);i.next&&i.err("Unexpected trailing text");let a=NCe(ACe(r));return DCe(a,i),a}matchType(t){for(let n=0;n<this.next.length;n++)if(this.next[n].type==t)return this.next[n].next;return null}matchFragment(t,n=0,i=t.childCount){let r=this;for(let a=n;r&&a<i;a++)r=r.matchType(t.child(a).type);return r}get inlineContent(){return this.next.length!=0&&this.next[0].type.isInline}get defaultType(){for(let t=0;t<this.next.length;t++){let{type:n}=this.next[t];if(!(n.isText||n.hasRequiredAttrs()))return n}return null}compatible(t){for(let n=0;n<this.next.length;n++)for(let i=0;i<t.next.length;i++)if(this.next[n].type==t.next[i].type)return!0;return!1}fillBefore(t,n=!1,i=0){let r=[this];function a(o,s){let u=o.matchFragment(t,i);if(u&&(!n||u.validEnd))return ne.from(s.map(c=>c.createAndFill()));for(let c=0;c<o.next.length;c++){let{type:f,next:h}=o.next[c];if(!(f.isText||f.hasRequiredAttrs())&&r.indexOf(h)==-1){r.push(h);let g=a(h,s.concat(f));if(g)return g}}return null}return a(this,[])}findWrapping(t){for(let i=0;i<this.wrapCache.length;i+=2)if(this.wrapCache[i]==t)return this.wrapCache[i+1];let n=this.computeWrapping(t);return this.wrapCache.push(t,n),n}computeWrapping(t){let n=Object.create(null),i=[{match:this,type:null,via:null}];for(;i.length;){let r=i.shift(),a=r.match;if(a.matchType(t)){let o=[];for(let s=r;s.type;s=s.via)o.push(s.type);return o.reverse()}for(let o=0;o<a.next.length;o++){let{type:s,next:u}=a.next[o];!s.isLeaf&&!s.hasRequiredAttrs()&&!(s.name in n)&&(!r.type||u.validEnd)&&(i.push({match:s.contentMatch,type:s,via:r}),n[s.name]=!0)}}return null}get edgeCount(){return this.next.length}edge(t){if(t>=this.next.length)throw new RangeError(`There's no ${t}th edge in this content match`);return this.next[t]}toString(){let t=[];function n(i){t.push(i);for(let r=0;r<i.next.length;r++)t.indexOf(i.next[r].next)==-1&&n(i.next[r].next)}return n(this),t.map((i,r)=>{let a=r+(i.validEnd?"*":" ")+" ";for(let o=0;o<i.next.length;o++)a+=(o?", ":"")+i.next[o].type.name+"->"+t.indexOf(i.next[o].next);return a}).join(`
|
|
1298
|
+
calc(50% + 50% * cos(${r-90}deg)) 100%, calc(50% + 50% * cos(${r-90}deg)) calc(50% + 50% * sin(${r-90}deg)), 50% 50%)`;if(i<=100)return`polygon(50% 50%, 50% 0%, 100% 0%, 100% 100%,0% 100%, 0% calc(50% + 50% * sin(${r-90}deg)), 50% 50%)`};return(i,r)=>t.percent<100?(l.openBlock(),l.createElementBlock("div",{key:0,class:"pie-chart","data-testid":`${t.dataTestid}-PieChart`},[l.createElementVNode("div",{class:"pie-chart-border",style:l.normalizeStyle({"border-color":t.percent<50?"#ef9b8f":"#ffcc00"}),"data-testid":`${t.dataTestid}-PieChart-Border`},[l.createElementVNode("div",{class:"sector",style:l.normalizeStyle({clipPath:n(),"background-color":t.percent<50?"#ef9b8f":"#ffcc00"}),"data-testid":`${t.dataTestid}-PieChart-Sector`},null,12,P7e)],12,T7e)],8,_7e)):(l.openBlock(),l.createElementBlock("svg",{key:1,width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","data-testid":`${t.dataTestid}-Icon`,xmlns:"http://www.w3.org/2000/svg"},[...r[0]||(r[0]=[l.createElementVNode("path",{d:"M8 1C4.136 1 1 4.136 1 8C1 11.864 4.136 15 8 15C11.864 15 15 11.864 15 8C15 4.136 11.864 1 8 1ZM8 13.6C4.906 13.6 2.4 11.094 2.4 8C2.4 4.906 4.906 2.4 8 2.4C11.094 2.4 13.6 4.906 13.6 8C13.6 11.094 11.094 13.6 8 13.6Z",fill:"#3BC648"},null,-1),l.createElementVNode("circle",{cx:"8",cy:"8",r:"4",transform:"rotate(-180 8 8)",fill:"#3BC648"},null,-1),l.createElementVNode("path",{d:"M10 6L7.5 9.83935L6 8.5",stroke:"white","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])],8,E7e))}}),[["__scopeId","data-v-e50e4774"]]),A7e=["data-testid","aria-label"],N7e=["data-testid"],Ml=me(l.defineComponent({name:"Tooltip",__name:"Tooltip",props:{hint:{},isShow:{type:Boolean,default:!1},isCanShow:{type:Boolean,default:!0},position:{default:"bottom-center"},size:{default:"small"},type:{default:"black"},hintGap:{},hintClass:{default:""},dataTestid:{default:"Tooltip"}},setup(e){const t=e,n=l.ref(null),i=l.ref(null),r=l.computed(()=>[{"tooltip-yui-kit__hint_show":t.isShow||o.isShow,"tooltip-yui-kit__hint_bottom-center":t.position==="bottom-center","tooltip-yui-kit__hint_bottom-left":t.position==="bottom-left","tooltip-yui-kit__hint_bottom-right":t.position==="bottom-right","tooltip-yui-kit__hint_top-center":t.position==="top-center","tooltip-yui-kit__hint_top-left":t.position==="top-left","tooltip-yui-kit__hint_top-right":t.position==="top-right","tooltip-yui-kit__hint_left-top":t.position==="left-top","tooltip-yui-kit__hint_left-center":t.position==="left-center","tooltip-yui-kit__hint_left-bottom":t.position==="left-bottom","tooltip-yui-kit__hint_right-top":t.position==="right-top","tooltip-yui-kit__hint_right-center":t.position==="right-center","tooltip-yui-kit__hint_right-bottom":t.position==="right-bottom","tooltip-yui-kit__hint_small":t.size==="small","tooltip-yui-kit__hint_medium":t.size==="medium","tooltip-yui-kit__hint_large":t.size==="large","tooltip-yui-kit__hint_black":t.type==="black","tooltip-yui-kit__hint_blue":t.type==="blue","tooltip-yui-kit__hint_white":t.type==="white",[t.hintClass]:!0}]),a=l.computed(()=>{var M;const w=(M=n.value)==null?void 0:M.closest("dialog");return w||"body"}),o=l.reactive({isShow:!1}),s=()=>{g()},u=()=>{p()},c=()=>{f()},f=()=>{requestAnimationFrame(()=>{if(!n.value||!i.value||!o.isShow&&!t.isShow)return;const w={"--hint-top":"0","--hint-left":"0","--hint-width":"0","--hint-height":"0","--tooltip-width":"0","--tooltip-height":"0","--hint-visibility":"visible"},M=n.value.getBoundingClientRect(),x=i.value.getBoundingClientRect(),S=window.pageYOffset||document.documentElement.scrollTop,_=window.pageXOffset||document.documentElement.scrollLeft;let j=M.top+S,T=M.left+_;const I=n.value.closest("dialog");if(I){const X=I.getBoundingClientRect();j=M.top-X.top,T=M.left-X.left;const re=I.scrollTop,ee=I.scrollLeft;j+=re,T+=ee}const L=M.width,N=M.height,z=x.width,H=x.height;w["--hint-top"]=`${j}px`,w["--hint-left"]=`${T}px`,w["--tooltip-width"]=`${L}px`,w["--tooltip-height"]=`${N}px`,w["--hint-width"]=`${z}px`,w["--hint-height"]=`${H}px`,i.value&&Pt(w,i.value)})},h=()=>{requestAnimationFrame(()=>{!i.value||t.hintGap===void 0||Pt({"--tooltip-hint-gap":t.hintGap},i.value)})};l.watch(()=>t.hintGap,h,{immediate:!0});const g=()=>{o.isShow=!0},p=()=>{o.isShow=!1},y=new MutationObserver(()=>{f()}),v=new ResizeObserver(()=>{var w;(o.isShow||t.isShow)&&!((w=n.value)!=null&&w.matches(":hover"))?p():f()}),k=w=>{y.observe(w,{childList:!0,attributes:!0,characterData:!0}),v.observe(w)};return l.onMounted(()=>{f(),i.value&&k(i.value),n.value&&k(n.value),window.addEventListener("scroll",f,!0),window.addEventListener("resize",f)}),l.onUnmounted(()=>{v.disconnect(),y.disconnect(),window.removeEventListener("scroll",f,!0),window.removeEventListener("resize",f)}),(w,M)=>(l.openBlock(),l.createElementBlock("div",{ref_key:"tooltipRef",ref:n,class:"tooltip-yui-kit","data-testid":t.dataTestid,"aria-label":e.hint,onMouseenter:s,onMouseleave:u},[l.renderSlot(w.$slots,"default",{},void 0,!0),e.isCanShow?(l.openBlock(),l.createBlock(l.Teleport,{key:0,to:a.value},[l.createVNode(l.Transition,{name:"hint-animate",onEnter:c},{default:l.withCtx(()=>[e.isShow||o.isShow?(l.openBlock(),l.createElementBlock("div",{key:0,ref_key:"hintRef",ref:i,"data-testid":t.dataTestid,class:l.normalizeClass(["tooltip-yui-kit__hint",r.value])},l.toDisplayString(e.hint),11,N7e)):l.createCommentVNode("",!0)]),_:1})],8,["to"])):l.createCommentVNode("",!0)],40,A7e))}}),[["__scopeId","data-v-2f1a6d22"]]),D7e=["data-testid"],j7e=["data-testid"],I7e=["data-testid"],W7e=["onClick","data-testid"],O7e=l.defineComponent({__name:"Popover",props:{isShow:{type:Boolean},iconName:{default:ce.moreVertical},options:{default:()=>[]},tooltip:{default:""},tooltipPosition:{default:"top-left"},dataTestid:{default:"Popover"}},emits:["close"],setup(e,{emit:t}){const n=e,i=t,r=l.reactive({isShow:!1}),a=l.computed(()=>{var I;const T=(I=c.value)==null?void 0:I.closest("dialog");return T||"body"}),o=CSS.supports("top","anchor(bottom)"),s=l.useId(),u=l.computed(()=>`--anchor-popover-${s}`),c=l.ref(null),f=l.ref(null),h=l.ref(null),g=l.computed(()=>({"popover-yui-kit__wrapper":!0,"active-yui-kit":r.isShow,"empty-yui-kit":n.options.length===0})),p=()=>r.isShow=!r.isShow,y=()=>{r.isShow=!1,i("close")},v=T=>{T.function(),y()},k=()=>{requestAnimationFrame(()=>{if(!c.value||!f.value||!r.isShow)return;const T={},I=c.value.getBoundingClientRect(),L=window.pageYOffset||document.documentElement.scrollTop,N=window.pageXOffset||document.documentElement.scrollLeft;let z=I.bottom+L,H=I.left+N;const X=c.value.closest("dialog");if(X){const ee=X.getBoundingClientRect();z=I.top-ee.top,H=I.left-ee.left;const q=X.scrollTop,Z=X.scrollLeft;z+=q,H+=Z,z+=10}z+=10,T["--popover-top"]=`${z}px`,o||(T["--popover-left"]=`${H}px`),Pt(T,f.value),(()=>{if(!f.value)return;const ee=f.value.getBoundingClientRect();ee.right>window.innerWidth&&(o?T["--popover-right"]="anchor(right) ":T["--popover-right"]=`${I.right-ee.width}px`)})(),T["--popover-right"]&&(T.left="auto",Pt(T,f.value))})},w=T=>{const I=T.getBoundingClientRect(),L=document.elementFromPoint(I.left,I.top),N=document.elementFromPoint(I.right,I.bottom);!(L&&T.contains(L))&&!(N&&T.contains(N))&&y()},M=new IntersectionObserver(T=>{T.forEach(I=>{I.isIntersecting||y()})}),x=()=>{c.value&&f.value&&(window.addEventListener("scroll",k,!0),window.addEventListener("resize",k))},S=()=>{c.value&&f.value&&(window.removeEventListener("scroll",k,!0),window.removeEventListener("resize",k))},_=()=>{c.value&&window.addEventListener("scroll",w.bind(null,c.value),!0)},j=()=>{c.value&&window.removeEventListener("scroll",w.bind(null,c.value),!0)};return l.watch(()=>n.isShow,()=>r.isShow=n.isShow),l.watch(()=>r.isShow,()=>{r.isShow?(k(),_()):j(),!o&&(r.isShow?x():S())}),l.onMounted(()=>{c.value&&Pt({"anchor-name":`${u.value}`},c.value),f.value&&Pt({"position-anchor":`${u.value}`},f.value),h.value&&M.observe(h.value),o&&k()}),l.onUnmounted(()=>{M.disconnect(),j(),o||S()}),(T,I)=>(l.openBlock(),l.createBlock(Ml,{hint:n.tooltip,size:"small",type:"black",position:n.tooltipPosition,"data-testid":n.dataTestid,"is-can-show":!!n.tooltip&&!r.isShow&&n.options.length>0},{default:l.withCtx(()=>[l.withDirectives((l.openBlock(),l.createElementBlock("div",{class:"popover-yui-kit",ref_key:"popover",ref:h,"data-testid":`${n.dataTestid}-Popover`},[l.createElementVNode("div",{ref_key:"reference",ref:c,class:l.normalizeClass(g.value),"data-testid":`${n.dataTestid}-PopoverShow`,onClick:p},[l.createVNode(ye,{class:"popover-yui-kit__icon",name:n.iconName,width:16,height:16,"data-testid":`${n.dataTestid}-PopoverShow-Icon`},null,8,["name","data-testid"])],10,j7e),(l.openBlock(),l.createBlock(l.Teleport,{to:a.value},[l.createVNode(l.Transition,{name:"popover-animate"},{default:l.withCtx(()=>{var L;return[(L=n.options)!=null&&L.length?l.withDirectives((l.openBlock(),l.createElementBlock("div",{key:0,class:"popover-yui-kit__options",ref_key:"floating",ref:f,"data-testid":`${n.dataTestid}-PopoverShow-Options`},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(n.options,(N,z)=>(l.openBlock(),l.createElementBlock("div",{class:"popover-yui-kit__options__item",style:l.normalizeStyle(N.style),key:z,onClick:l.withModifiers(H=>v(N),["stop"]),"data-testid":`${n.dataTestid}-Item${z}`},l.toDisplayString(N.value),13,W7e))),128))],8,I7e)),[[l.vShow,r.isShow]]):l.createCommentVNode("",!0)]}),_:1})],8,["to"]))],8,D7e)),[[l.unref(Ls),y,void 0,{bubble:!0}]])]),_:1},8,["hint","position","data-testid","is-can-show"]))}}),H1=me(O7e,[["__scopeId","data-v-e1e1118a"]]),z7e=["colspan","rowspan","data-testid"],Go=me(l.defineComponent({name:"TableTh",__name:"TableTh",props:{colspan:{default:1},rowspan:{default:1},dataTestid:{default:"DataHeader"}},setup(e){const t=e;return(n,i)=>(l.openBlock(),l.createElementBlock("th",{colspan:e.colspan,rowspan:e.rowspan,"data-testid":t.dataTestid,class:"table-th"},[l.renderSlot(n.$slots,"default",{},void 0,!0)],8,z7e))}}),[["__scopeId","data-v-39ad1e7b"]]),L7e=["data-testid"],Cl=me(l.defineComponent({name:"HeadTableRow",__name:"HeadTableRow",props:{dataTestid:{default:"TableRow"}},setup(e){const t=e;return(n,i)=>(l.openBlock(),l.createElementBlock("tr",{class:"head-table-row","data-testid":t.dataTestid},[l.renderSlot(n.$slots,"default",{},void 0,!0)],8,L7e))}}),[["__scopeId","data-v-b2f1516a"]]),S4=(e,t,n,i)=>{const r=l.ref(!1),a=l.ref(100);let o=0,s=0;const u=l.computed(()=>[{"scroll-wrapper__track_hide":a.value===100,"scroll-wrapper__track_drag":r.value}]),c=l.computed(()=>a.value<100),f=()=>{if(e.value){const w=e.value.clientWidth,M=e.value.scrollWidth;return w>=M?100:w/M*100}return 100},h=()=>{if(!e.value||!t.value||!n.value||!i.value)return;const{scrollLeft:w,scrollWidth:M,clientWidth:x}=e.value,S=M-x;if(S<=0)return;const _=w/S,j=i.value.clientWidth,T=n.value.clientWidth,I=j-T,L=_*I;requestAnimationFrame(()=>{t.value&&Pt({"--scroll-bar-left-position":`${L}px`},t.value)})},g=w=>{!e.value||!t.value||(r.value=!0,o=w.clientX,s=e.value.scrollLeft,document.addEventListener("pointermove",p),document.addEventListener("pointerup",y,!0))},p=w=>{if(r.value&&e.value&&n.value){const M=w.clientX-o,x=(e.value.scrollWidth-e.value.clientWidth)/(e.value.clientWidth-n.value.clientWidth);e.value.scrollLeft=s+M*x,h()}},y=()=>{r.value=!1,document.removeEventListener("pointermove",p),document.removeEventListener("pointerup",y,!0)};return{onDrag:p,onTrackClick:w=>{if(e.value&&n.value){const M=w.currentTarget.getBoundingClientRect(),x=w.clientX-M.left,S=n.value.clientWidth,_=M.width;let j=(x-S/2)*((e.value.scrollWidth-e.value.clientWidth)/(_-S));j=Math.max(0,Math.min(j,e.value.scrollWidth-e.value.clientWidth)),e.value.scrollLeft=j,h()}},startDrag:g,getPercentHorizontalView:f,changeBarPosition:h,isDragging:r,scrollHorizontalWidthPercent:a,setHorizontalBarWidth:()=>{if(!e.value||!t.value)return;const w=f();a.value=w,Pt({"--scroll-horizontal-bar-width":`${w}%`},t.value)},horizontalTrackClass:u,isExistHorizontalTrack:c}},_4=(e,t,n,i)=>{const r=l.ref(!1),a=l.ref(100);let o=0,s=0;const u=l.computed(()=>[{"scroll-wrapper__track_hide":a.value===100,"scroll-wrapper__track_drag":r.value}]),c=l.computed(()=>a.value<100),f=()=>{if(e.value){const w=e.value.clientHeight,M=e.value.scrollHeight;if(w>=M)return 100;if(w<M)return w/M*100}return 100},h=()=>{if(!e.value||!t.value||!n.value||!i.value)return;const{scrollTop:w,scrollHeight:M,clientHeight:x}=e.value,S=M-x;if(S<=0)return;const _=w/S,j=i.value.clientHeight,T=n.value.clientHeight,I=j-T,L=_*I;requestAnimationFrame(()=>{t.value&&Pt({"--scroll-bar-top-postion":`${L}px`},t.value)})},g=w=>{!e.value||!t.value||(r.value=!0,o=w.clientY,s=e.value.scrollTop,document.addEventListener("pointermove",p),document.addEventListener("pointerup",y))},p=w=>{if(r.value&&e.value&&n.value){const M=w.clientY-o,x=(e.value.scrollHeight-e.value.clientHeight)/(e.value.clientHeight-n.value.clientHeight);e.value.scrollTop=s+M*x,h()}},y=()=>{r.value=!1,document.removeEventListener("pointermove",p),document.removeEventListener("pointerup",y)};return{onDrag:p,onTrackClick:w=>{if(e.value&&n.value){const M=w.currentTarget.getBoundingClientRect(),x=w.clientY-M.top,S=n.value.clientHeight,_=M.height;let j=(x-S/2)*((e.value.scrollHeight-e.value.clientHeight)/(_-S));j=Math.max(0,Math.min(j,e.value.scrollHeight-e.value.clientHeight)),e.value.scrollTop=j,h()}},startDrag:g,getProcentVerticalView:f,changeBarPosition:h,isDragging:r,scrollVerticalHeightProcent:a,setVerticalBarHeight:()=>{if(!e.value||!t.value)return;const w=f();a.value=w,Pt({"--scroll-vertical-bar-height":`${w}%`},t.value)},verticalTrackClass:u,isExistVerticalTrack:c}},$7e={class:"scroll-wrapper__vertical-wrapper"},H7e={class:"scroll-wrapper__horizont-wrapper"},xl=me(l.defineComponent({name:"ScrollWrapper",__name:"ScrollWrapper",props:{isShowVerticalScroll:{type:Boolean,default:!1},isShowHorizontalScroll:{type:Boolean,default:!1}},emits:["unmount-scroll","unmount-paginate","on-mounted"],setup(e,{expose:t,emit:n}){const i=n,r=l.ref(null),a=l.ref(null),o=l.ref(null),s=l.ref(null),u=l.ref(null),c=l.ref(null),{onTrackClick:f,startDrag:h,changeBarPosition:g,setVerticalBarHeight:p,verticalTrackClass:y,isExistVerticalTrack:v}=_4(r,a,s,o),{changeBarPosition:k,startDrag:w,onTrackClick:M,setHorizontalBarWidth:x,horizontalTrackClass:S,isExistHorizontalTrack:_}=S4(r,a,c,u),j=q=>{g(),k(),i("unmount-scroll",q)},T=()=>{requestAnimationFrame(()=>{I(),L()})},I=()=>{if(!r.value||!a.value)return;const q=getComputedStyle(a.value),Z=a.value.style.minHeight||q.minHeight,ue=a.value.style.maxHeight||q.maxHeight,De=a.value.style.height;Pt({"--scroll-wrapper-height":`${De}`,"--scroll-wrapper-max-height":`${ue}`,"--scroll-wrapper-min-height":`${Z}`},a.value)},L=()=>{p(),x(),g(),k()},N=()=>{r.value&&r.value.addEventListener("scroll",j)},z=()=>{r.value&&(r.value.scrollTop=0)},H=()=>{r.value&&(r.value.scrollHeight<=r.value.clientHeight?i("unmount-paginate",!0):i("unmount-paginate",!1))},X=new MutationObserver(()=>{T(),H()}),re=new ResizeObserver(()=>{T(),H()}),ee=q=>{X.observe(q,{childList:!0,subtree:!0,attributes:!0}),re.observe(q)};return t({scrollToTop:z,setHeightSlot:I}),l.onMounted(()=>{T(),N(),a.value&&ee(a.value),o.value&&ee(o.value),window.addEventListener("resize",T),i("on-mounted")}),l.onUnmounted(()=>{window.removeEventListener("resize",T)}),(q,Z)=>(l.openBlock(),l.createElementBlock("div",{ref_key:"scrollWrapperRef",ref:a,class:"scroll-wrapper"},[l.createElementVNode("div",$7e,[l.createElementVNode("div",H7e,[l.createElementVNode("div",{ref_key:"slotRef",ref:r,class:"scroll-wrapper__slot"},[l.renderSlot(q.$slots,"default",{},void 0,!0)],512),l.unref(_)||e.isShowHorizontalScroll?(l.openBlock(),l.createElementBlock("div",{key:0,ref_key:"horizontTrackRef",ref:u,class:l.normalizeClass(["scroll-wrapper__track scroll-wrapper__track_horizont",l.unref(S)]),onClick:Z[1]||(Z[1]=l.withModifiers((...ue)=>l.unref(M)&&l.unref(M)(...ue),["self","prevent","left"]))},[l.createElementVNode("div",{ref_key:"horizontBarRef",ref:c,class:"scroll-wrapper__bar",onPointerdown:Z[0]||(Z[0]=l.withModifiers((...ue)=>l.unref(w)&&l.unref(w)(...ue),["prevent","left"]))},null,544)],2)):l.createCommentVNode("",!0)]),l.unref(v)||e.isShowVerticalScroll?(l.openBlock(),l.createElementBlock("div",{key:0,ref_key:"verticalTrackRef",ref:o,class:l.normalizeClass(["scroll-wrapper__track scroll-wrapper__track_vertical",l.unref(y)]),onClick:Z[3]||(Z[3]=l.withModifiers((...ue)=>l.unref(f)&&l.unref(f)(...ue),["self","prevent","left"]))},[l.createElementVNode("div",{ref_key:"verticalBarRef",ref:s,class:"scroll-wrapper__bar",onPointerdown:Z[2]||(Z[2]=l.withModifiers((...ue)=>l.unref(h)&&l.unref(h)(...ue),["prevent","left"]))},null,544)],2)):l.createCommentVNode("",!0)])],512))}}),[["__scopeId","data-v-b5d4825a"]]),R7e=["id","data-testid"],B7e=["id","data-testid"],V7e=["id","data-testid"],R1=me(l.defineComponent({name:"TableNew",__name:"Table",props:{tableId:{},search:{},tbodyId:{},theadId:{},columnCount:{},dataTestid:{default:"Table"},isShowVerticalScroll:{type:Boolean,default:!1},isShowHorizontalScroll:{type:Boolean,default:!1}},emits:["unmount-scroll","unmount-paginate"],setup(e,{expose:t,emit:n}){var x;const i=e,r=n,a=l.reactive({headHeight:0,maxColumnCount:0}),o=l.ref(null),s=l.ref(null),u=l.ref(null),c=l.ref(null),f=l.ref(null),h=S=>{r("unmount-scroll",S)},g=S=>r("unmount-paginate",S),p=()=>{if(!o.value||!f.value)return;const S=o.value.querySelector("thead");if(!S)return;const _=S.getBoundingClientRect().height;a.headHeight=_,Pt({"--scroll-track-margin-top":`${_}px`},f.value.$el)},y=()=>{f.value&&f.value.scrollToTop()},v=()=>{if(f.value&&c.value){const S=getComputedStyle(f.value.$el),_=Number(S.minHeight.replace(/\D/g,""));if(_&&_>0)return;Pt({"min-height":`${a.headHeight+108}px`},f.value.$el)}},k=()=>{let S=1;if(s.value){for(let _=0;_<s.value.children.length;_++)S=Math.max(s.value.children[_].children.length,S);a.maxColumnCount=S}},w=new MutationObserver(()=>{k()}),M=new ResizeObserver(()=>{p()});return t({scrollToTop:y,setHeightSlot:(x=f.value)==null?void 0:x.setHeightSlot,tbodyRef:u,tableRef:o,theadRef:s}),l.onMounted(()=>{p(),k(),window.addEventListener("resize",p),o.value&&M.observe(o.value),s.value&&w.observe(s.value,{childList:!0,subtree:!0}),v()}),(S,_)=>(l.openBlock(),l.createBlock(xl,{ref_key:"scrollWrapperRef",ref:f,class:"table",onUnmountScroll:h,onUnmountPaginate:g,"is-show-vertical-scroll":i.isShowVerticalScroll,"is-show-horizontal-scroll":i.isShowHorizontalScroll,"data-testid":`${i.dataTestid}-ScrollWrapper`},{default:l.withCtx(()=>[l.createElementVNode("table",{ref_key:"tableRef",ref:o,id:i.tableId,class:"table__table","data-testid":`${i.dataTestid}`},[l.renderSlot(S.$slots,"default",{},()=>{var j;return[l.createElementVNode("colgroup",null,[l.renderSlot(S.$slots,"colspan",{},void 0,!0)]),S.$slots.head?(l.openBlock(),l.createElementBlock("thead",{key:0,ref_key:"theadRef",ref:s,id:i.theadId,class:"table__head","data-testid":`${i.dataTestid}-Thead`},[l.renderSlot(S.$slots,"head",{},void 0,!0),S.$slots.search?(l.openBlock(),l.createBlock(Cl,{key:0,class:"table__search-tr",id:(j=i.search)==null?void 0:j.rowId,ref_key:"searchRowRef",ref:c,"data-testid":`${i.dataTestid}-Search-Row`},{default:l.withCtx(()=>{var T;return[l.createVNode(Go,{colspan:i.columnCount||a.maxColumnCount,class:"table__search-th",id:(T=i.search)==null?void 0:T.headId,"data-testid":`${i.dataTestid}-SearchRow-Search`},{default:l.withCtx(()=>[l.renderSlot(S.$slots,"search",{},void 0,!0)]),_:3},8,["colspan","id","data-testid"])]}),_:3},8,["id","data-testid"])):l.createCommentVNode("",!0)],8,B7e)):l.createCommentVNode("",!0),l.renderSlot(S.$slots,"body-group",{},()=>[S.$slots.body?(l.openBlock(),l.createElementBlock("tbody",{key:0,id:i.tbodyId,ref_key:"tbodyRef",ref:u,class:"table__body","data-testid":`${i.dataTestid}-Tbody`},[l.renderSlot(S.$slots,"body",{},void 0,!0)],8,V7e)):l.createCommentVNode("",!0)],!0)]},!0)],8,R7e)]),_:3},8,["is-show-vertical-scroll","is-show-horizontal-scroll","data-testid"]))}}),[["__scopeId","data-v-d2ee85b8"]]),F7e=["data-testid"],Qd=me(l.defineComponent({name:"TableRow",__name:"TableRow",props:{type:{default:"default"},dataTestid:{}},setup(e){const t=e,n=l.computed(()=>[{"table-row_active":t.type==="selected"}]);return(i,r)=>(l.openBlock(),l.createElementBlock("tr",{class:l.normalizeClass(["table-row",n.value]),"data-testid":t.dataTestid},[l.renderSlot(i.$slots,"default",{},void 0,!0)],10,F7e))}}),[["__scopeId","data-v-2bcd1a53"]]),U7e=["rowspan","colspan","data-testid"],Jd=l.defineComponent({name:"TableTd",__name:"TableTd",props:{colspan:{default:1},rowspan:{default:1},dataTestid:{default:"DataCell"}},setup(e){const t=e;return(n,i)=>(l.openBlock(),l.createElementBlock("td",{rowspan:e.rowspan,colspan:e.colspan,class:"table-td","data-testid":t.dataTestid},[l.renderSlot(n.$slots,"default")],8,U7e))}}),B1=me(l.defineComponent({name:"SectionTableRow",__name:"SectionTableRow",props:{colspan:{},dataTestid:{default:"SectionTableRow"}},setup(e){const t=e;return(n,i)=>(l.openBlock(),l.createBlock(Qd,{class:"section-table-row","data-testid":t.dataTestid},{default:l.withCtx(()=>[l.createVNode(Jd,{colspan:e.colspan,class:"section-table-row__td","data-testid":`${t.dataTestid}-DataCell`},{default:l.withCtx(()=>[l.renderSlot(n.$slots,"default",{},void 0,!0)]),_:3},8,["colspan","data-testid"])]),_:3},8,["data-testid"]))}}),[["__scopeId","data-v-43e9ed3e"]]);var V1=(e=>(e.top="top",e.bottom="bottom",e))(V1||{});const Y7e=["data-testid"],X7e=l.defineComponent({__name:"PopoverHover",props:{position:{default:V1.bottom},dataTestid:{default:"PopoverHover"}},setup(e){const t=e,n=l.computed(()=>({"popover-hover-yui-kit":!0,"popover_hover-yui-kit_top":t.position==V1.top}));return(i,r)=>(l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass(n.value),"data-testid":t.dataTestid},[l.renderSlot(i.$slots,"default",{},void 0,!0)],10,Y7e))}}),F1=me(X7e,[["__scopeId","data-v-e6548269"]]),q7e=["disabled","name","value","data-testid"],U1=me(l.defineComponent({name:"Radio",__name:"Radio",props:l.mergeModels({name:{},value:{},disabled:{type:Boolean,default:!1},dataTestid:{default:"Radio"}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=e,n=l.useModel(e,"modelValue");return(i,r)=>l.withDirectives((l.openBlock(),l.createElementBlock("input",{"onUpdate:modelValue":r[0]||(r[0]=a=>n.value=a),type:"radio",disabled:e.disabled,name:e.name,value:e.value,class:"radio","data-testid":t.dataTestid},null,8,q7e)),[[l.vModelRadio,n.value]])}}),[["__scopeId","data-v-d73c922e"]]),G7e=["data-testid"],K7e=["data-testid"],T4=me(l.defineComponent({name:"ChoosenMiniOptions",__name:"ChoosenMiniOptions",props:{options:{},dataTestid:{default:"ChoosenMiniOptions"}},emits:["remove"],setup(e,{emit:t}){const n=e,i=t,r=a=>{i("remove",a)};return(a,o)=>(l.openBlock(),l.createElementBlock("div",{class:"choosen-mini-options","data-testid":n.dataTestid},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(e.options,(s,u)=>(l.openBlock(),l.createElementBlock("div",{key:s.key,class:"choosen-mini-options__option","data-testid":`${n.dataTestid}-Option-Item${u}`},[l.createVNode(Ft,{"data-testid":`${n.dataTestid}-Badge${u}`,type:l.unref(tt).blue,text:l.unref(Lh)(s)?s.hint:s.value,class:"choosen-mini-options__badges",disabled:""},null,8,["data-testid","type","text"]),l.createVNode(ye,{"data-testid":`${n.dataTestid}-Icon${u}`,name:l.unref(ce).crossLarge,width:10,height:10,class:"choosen-mini-options__cross",onClick:c=>r(s.key)},null,8,["data-testid","name","onClick"])],8,K7e))),128))],8,G7e))}}),[["__scopeId","data-v-65ba1506"]]),Q7e=["data-testid"],J7e=["data-testid"],Z7e=["data-testid"],eCe=["data-testid"],tCe=["data-testid"],nCe=["data-testid"],Y1=me(l.defineComponent({name:"BaseFilter",__name:"BaseFilter",props:l.mergeModels({options:{},title:{},isSearch:{type:Boolean,default:!1},isPosibleToClear:{type:Boolean,default:!1},isShowMiniOptions:{type:Boolean,default:!1},isOpened:{type:Boolean,default:!1},tooltipPosition:{default:"top-center"},onUnmountPagination:{},defaultOption:{default:"Выберите значение"},class:{},disabled:{type:Boolean},dataTestid:{default:"BaseFilter"}},{modelValue:{},modelModifiers:{}}),emits:l.mergeModels(["change","unmount-open","unmount-search","unmount-search-enter","unmount-pagination"],["update:modelValue"]),setup(e,{emit:t}){const n=e,i=l.reactive({isHovered:!1}),r=t,a=l.ref(null),o=l.ref(null),s=l.useModel(e,"modelValue"),u=l.ref(n.isOpened);l.watch(u,()=>r("unmount-open",u.value)),l.watch(()=>n.isOpened,()=>{u.value=n.isOpened}),l.watch(()=>n.onUnmountPagination,()=>{L()});const c=l.ref(""),f=l.computed(()=>{let N=[];return c.value?(Hs(n.options)?N=n.options.filter(z=>{var H;return z.value.toLowerCase().includes(c.value.toLowerCase())||((H=z==null?void 0:z.hint)==null?void 0:H.toLowerCase().includes(c.value.toLowerCase()))}):N=n.options.filter(z=>z.value.toLowerCase().includes(c.value.toLowerCase())),N):(Hs(n.options),N=n.options,N)}),h=l.computed(()=>{var z;return((z=n.options.find(H=>Hi.isArray(s.value)?s.value.includes(H.key):H.key===String(s.value)))==null?void 0:z.value)||n.defaultOption}),g=l.computed(()=>n.options.filter(N=>Hi.isArray(s.value)?s.value.includes(N.key)&&N.value!==h.value:N.key===String(s.value))),p=l.computed(()=>n.options.filter(N=>Hi.isArray(s.value)?s.value.includes(N.key)&&N.value===h.value:N.key===String(s.value))),y=l.computed(()=>{var H,X,re;const N=n.options;let z;return Hi.isArray(s.value)?Hs(N)?z=(H=N.find(ee=>ee.value===h.value))==null?void 0:H.hint:z=(X=N.find(ee=>ee.value===h.value))==null?void 0:X.value:z=(re=N.find(ee=>ee.key===String(s.value)))==null?void 0:re.value,z||""}),v=()=>{i.isHovered=!0},k=()=>{i.isHovered=!1},w=l.computed(()=>{var N;return Hs(n.options)?i.isHovered&&!!y.value:((N=a.value)==null?void 0:N.isSpanOverflow)||!1}),M=l.computed(()=>Hi.isArray(s.value)?n.isPosibleToClear&&s.value.length>0:n.isPosibleToClear&&s.value),x=l.computed(()=>Hi.isArray(s.value)&&s.value.length>1),S=l.computed(()=>Hi.isArray(s.value)?s.value.length:null),_=async N=>{if(Hi.isArray(s.value))s.value.includes(N)?s.value=s.value.filter(z=>z!==N):s.value=[...s.value,N];else{let z=n.options.find(H=>H.key===N);!z&&Hs(n.options)&&(z=n.options.find(H=>H.hint===N)),s.value=(z==null?void 0:z.key)||"",u.value=!1}await l.nextTick(),r("change",String(s.value))},j=N=>{u.value=N},T=async()=>{Hi.isArray(s.value)?s.value=[]:s.value="",await l.nextTick(),r("change",s.value)},I=new IntersectionObserver(N=>{N.forEach(z=>{z.isIntersecting&&r("unmount-pagination")})}),L=()=>{o.value&&n.onUnmountPagination&&(I.unobserve(o.value),I.observe(o.value))};return l.onMounted(()=>{L()}),l.onUnmounted(()=>{I.disconnect()}),(N,z)=>(l.openBlock(),l.createBlock(vo,{onChange:j,"is-opened":u.value,class:l.normalizeClass(n.class),"header-classes":"filter__header","options-classes":"filter__options","data-testid":n.dataTestid},{header:l.withCtx(()=>[l.createElementVNode("span",{class:l.normalizeClass(["filter__header-title",{"filter__header-title__active":u.value}]),"data-testid":`${n.dataTestid}-Title`},l.toDisplayString(e.title),11,Q7e),l.createVNode(Ml,{position:e.tooltipPosition,type:"blue","is-can-show":w.value&&!(x.value&&e.isShowMiniOptions),hint:y.value,"hint-gap":28,class:"filter__header-tooltip","data-testid":`${n.dataTestid}-Tooltip`},{default:l.withCtx(()=>[l.createVNode(Ft,{ref_key:"badgesRef",ref:a,type:h.value===n.defaultOption?l.unref(tt).default:l.unref(tt).blue,class:"filter__options-badge","data-testid":`${n.dataTestid}-Badge`,text:h.value,onMouseenter:v,onMouseleave:k,disabled:""},null,8,["type","data-testid","text"]),x.value&&e.isShowMiniOptions?(l.openBlock(),l.createElementBlock("div",{key:0,class:"filter__values","data-testid":`${n.dataTestid}-Filter-Value`},[l.createVNode(T4,{"data-testid":`${n.dataTestid}-Filter-Value-MiniOptions`,onClick:z[0]||(z[0]=l.withModifiers(()=>{},["stop"])),options:p.value,onRemove:_},null,8,["data-testid","options"])],8,J7e)):l.createCommentVNode("",!0)]),_:1},8,["position","is-can-show","hint","data-testid"]),S.value&&S.value>1?(l.openBlock(),l.createElementBlock("span",{key:0,class:"filter__count","data-testid":`${n.dataTestid}-Filter-Count`},[l.createTextVNode(" +"+l.toDisplayString(S.value-1)+" ",1),x.value?(l.openBlock(),l.createElementBlock("div",{key:0,class:"filter__values","data-testid":`${n.dataTestid}-Filter-Values`},[l.createVNode(T4,{onClick:z[1]||(z[1]=l.withModifiers(()=>{},["stop"])),options:g.value,onRemove:_,"data-testid":`${n.dataTestid}-MiniOptions`},null,8,["options","data-testid"])],8,eCe)):l.createCommentVNode("",!0)],8,Z7e)):l.createCommentVNode("",!0),M.value?(l.openBlock(),l.createElementBlock("span",{key:1,class:"filter__cross",onClick:l.withModifiers(T,["stop"]),"data-testid":`${n.dataTestid}-Filter-Cross`},[l.createVNode(ye,{name:l.unref(ce).crossLarge,width:16,height:16},null,8,["name"])],8,tCe)):l.createCommentVNode("",!0)]),options:l.withCtx(()=>[e.isSearch?(l.openBlock(),l.createBlock(yl,{key:0,modelValue:c.value,"onUpdate:modelValue":z[2]||(z[2]=H=>c.value=H),"show-history":!1,"data-testid":`${n.dataTestid}-Search`,onInput:z[3]||(z[3]=H=>N.$emit("unmount-search",H)),onEnter:z[4]||(z[4]=H=>N.$emit("unmount-search-enter",H))},null,8,["modelValue","data-testid"])):l.createCommentVNode("",!0),l.createVNode($h,{"data-testid":`${n.dataTestid}-Options`,class:"filter__options-option",options:f.value,"default-option":h.value,onChange:_},{default:l.withCtx(()=>[l.createElementVNode("li",{class:"filter__options-underline","data-testid":`${n.dataTestid}-Underline`},[...z[5]||(z[5]=[l.createElementVNode("hr",{class:"filter__options-underline-hr"},null,-1)])],8,nCe)]),_:1},8,["data-testid","options","default-option"]),l.withDirectives(l.createElementVNode("div",{ref_key:"lastOptionRef",ref:o,class:"filter__last-option"},null,512),[[l.vShow,e.onUnmountPagination]])]),_:1},8,["is-opened","class","data-testid"]))}}),[["__scopeId","data-v-5f2b456d"]]),iCe=["data-testid"],Zd=me(l.defineComponent({name:"Range",__name:"Range",props:l.mergeModels({min:{default:0},max:{default:100},step:{default:1},disabled:{type:Boolean,default:!1},dataTestid:{default:"Range"}},{modelValue:{default:0},modelModifiers:{}}),emits:l.mergeModels(["unmount-change","unmount-input"],["update:modelValue"]),setup(e,{emit:t}){const n=e,i=t,r=l.useModel(e,"modelValue"),a=l.ref(null);l.watch(r,()=>{s()});const o=()=>(r.value-n.min)/(n.max-n.min)*100,s=()=>{requestAnimationFrame(()=>{a.value&&Pt({"--progress":o()+"%"},a.value)})},u=f=>{const h=f.target;h&&i("unmount-change",Number(h.value))},c=f=>{const h=f.target;h&&i("unmount-change",Number(h.value))};return l.onMounted(()=>{s()}),(f,h)=>l.withDirectives((l.openBlock(),l.createElementBlock("input",l.mergeProps({ref_key:"input",ref:a,type:"range"},n,{class:"range","onUpdate:modelValue":h[0]||(h[0]=g=>r.value=g),onChange:u,onInput:c,"data-testid":n.dataTestid}),null,16,iCe)),[[l.vModelText,r.value]])}}),[["__scopeId","data-v-765973ae"]]),rCe=["id","data-testid"],aCe=["data-testid"],oCe=["data-testid"],X1=me(l.defineComponent({name:"TableNew",__name:"TableNew",props:{tableId:{},search:{},tbodyId:{},theadId:{},columnCount:{},dataTestid:{default:"Table"},isShowVerticalScroll:{type:Boolean,default:!1},isShowHorizontalScroll:{type:Boolean,default:!1}},emits:["unmount-scroll","unmount-paginate"],setup(e,{expose:t,emit:n}){var M;const i=e,r=n,a=l.reactive({headHeight:0,maxColumnCount:0}),o=l.ref(null),s=l.ref(null),u=l.ref(null),c=l.ref(null),f=l.ref(null),h=x=>{r("unmount-scroll",x)},g=()=>{if(!o.value||!f.value)return;const x=o.value.querySelector("thead");if(!x)return;const S=x.getBoundingClientRect().height;a.headHeight=S,Pt({"--scroll-track-margin-top":`${S}px`},f.value.$el)},p=()=>{f.value&&f.value.scrollToTop()},y=()=>{if(f.value&&c.value){const x=getComputedStyle(f.value.$el),S=Number(x.minHeight.replace(/\D/g,""));if(S&&S>0)return;Pt({"min-height":`${a.headHeight+108}px`},f.value.$el)}},v=()=>{let x=1;if(s.value){for(let S=0;S<s.value.children.length;S++)x=Math.max(s.value.children[S].children.length,x);a.maxColumnCount=x}},k=new MutationObserver(()=>{v()}),w=new ResizeObserver(()=>{g()});return t({scrollToTop:p,setHeightSlot:(M=f.value)==null?void 0:M.setHeightSlot,tbodyRef:u,tableRef:o,theadRef:s}),l.onMounted(()=>{g(),v(),window.addEventListener("resize",g),o.value&&w.observe(o.value),s.value&&k.observe(s.value,{childList:!0,subtree:!0}),y()}),(x,S)=>(l.openBlock(),l.createBlock(xl,{ref_key:"scrollWrapperRef",ref:f,class:"table",onUnmountScroll:h,"is-show-vertical-scroll":i.isShowVerticalScroll,"is-show-horizontal-scroll":i.isShowHorizontalScroll,"data-testid":`${i.dataTestid}-ScrollWrapper`},{default:l.withCtx(()=>[l.createElementVNode("table",{ref_key:"tableRef",ref:o,id:i.tableId,class:"table__table","data-testid":`${i.dataTestid}`},[l.renderSlot(x.$slots,"default",{},()=>[l.createElementVNode("colgroup",null,[l.renderSlot(x.$slots,"colspan",{},void 0,!0)]),x.$slots.head?(l.openBlock(),l.createElementBlock("thead",{key:0,ref_key:"theadRef",ref:s,class:"table__head","data-testid":`${i.dataTestid}-Thead`},[l.renderSlot(x.$slots,"head",{},void 0,!0),x.$slots.search?(l.openBlock(),l.createBlock(Cl,{key:0,class:"table__search-tr",ref_key:"searchRowRef",ref:c,"data-testid":`${i.dataTestid}-Search-Row`},{default:l.withCtx(()=>[l.createVNode(Go,{colspan:a.maxColumnCount,class:"table__search-th","data-testid":`${i.dataTestid}-SearchRow-Search`},{default:l.withCtx(()=>[l.renderSlot(x.$slots,"search",{},void 0,!0)]),_:3},8,["colspan","data-testid"])]),_:3},8,["data-testid"])):l.createCommentVNode("",!0)],8,aCe)):l.createCommentVNode("",!0),l.renderSlot(x.$slots,"body-group",{},()=>[x.$slots.body?(l.openBlock(),l.createElementBlock("tbody",{key:0,ref_key:"tbodyRef",ref:u,class:"table__body","data-testid":`${i.dataTestid}-Tbody`},[l.renderSlot(x.$slots,"body",{},void 0,!0)],8,oCe)):l.createCommentVNode("",!0)],!0)],!0)],8,rCe)]),_:3},8,["is-show-vertical-scroll","is-show-horizontal-scroll","data-testid"]))}}),[["__scopeId","data-v-4951b36e"]]),sCe=["data-testid"],q1=me(l.defineComponent({name:"TableRow",__name:"TableRowNew",props:{type:{default:"default"},dataTestid:{}},setup(e){const t=e,n=l.computed(()=>[{"table-row_active":t.type==="selected"}]);return(i,r)=>(l.openBlock(),l.createElementBlock("tr",{class:l.normalizeClass(["table-row",n.value]),"data-testid":t.dataTestid},[l.renderSlot(i.$slots,"default",{},void 0,!0)],10,sCe))}}),[["__scopeId","data-v-b142a9a4"]]),lCe=["data-testid"],ec=me(l.defineComponent({name:"HeadTableRow",__name:"HeadTableRowNew",props:{dataTestid:{default:"TableRow"}},setup(e){const t=e;return(n,i)=>(l.openBlock(),l.createElementBlock("tr",{class:"head-table-row","data-testid":t.dataTestid},[l.renderSlot(n.$slots,"default",{},void 0,!0)],8,lCe))}}),[["__scopeId","data-v-1cac20aa"]]),uCe={class:"scroll-wrapper__vertical-wrapper"},dCe={class:"scroll-wrapper__horizont-wrapper"},cCe=me(l.defineComponent({name:"ScrollWrapper",__name:"ScrollWrapperNew",props:{isShowVerticalScroll:{type:Boolean,default:!1},isShowHorizontalScroll:{type:Boolean,default:!1}},emits:["unmount-scroll","unmount-paginate","on-mounted"],setup(e,{expose:t,emit:n}){const i=n,r=l.ref(null),a=l.ref(null),o=l.ref(null),s=l.ref(null),u=l.ref(null),c=l.ref(null),{onTrackClick:f,startDrag:h,changeBarPosition:g,setVerticalBarHeight:p,verticalTrackClass:y,isExistVerticalTrack:v}=_4(r,a,s,o),{changeBarPosition:k,startDrag:w,onTrackClick:M,setHorizontalBarWidth:x,horizontalTrackClass:S,isExistHorizontalTrack:_}=S4(r,a,c,u),j=ee=>{g(),k(),i("unmount-scroll",ee)},T=()=>{requestAnimationFrame(()=>{I(),L()})},I=()=>{if(!r.value||!a.value)return;const ee=getComputedStyle(a.value),q=a.value.style.minHeight||ee.minHeight,Z=a.value.style.maxHeight||ee.maxHeight,ue=a.value.style.height;Pt({"--scroll-wrapper-height":`${ue}`,"--scroll-wrapper-max-height":`${Z}`,"--scroll-wrapper-min-height":`${q}`},a.value)},L=()=>{p(),x(),g(),k()},N=()=>{r.value&&r.value.addEventListener("scroll",j)},z=()=>{r.value&&(r.value.scrollTop=0)},H=new MutationObserver(()=>{T()}),X=new ResizeObserver(()=>{T()}),re=ee=>{H.observe(ee,{childList:!0,subtree:!0,attributes:!0}),X.observe(ee)};return t({scrollToTop:z,setHeightSlot:I}),l.onMounted(()=>{T(),N(),a.value&&re(a.value),o.value&&re(o.value),window.addEventListener("resize",T),i("on-mounted")}),l.onUnmounted(()=>{window.removeEventListener("resize",T)}),(ee,q)=>(l.openBlock(),l.createElementBlock("div",{ref_key:"scrollWrapperRef",ref:a,class:"scroll-wrapper"},[l.createElementVNode("div",uCe,[l.createElementVNode("div",dCe,[l.createElementVNode("div",{ref_key:"slotRef",ref:r,class:"scroll-wrapper__slot"},[l.renderSlot(ee.$slots,"default",{},void 0,!0)],512),l.unref(_)||e.isShowHorizontalScroll?(l.openBlock(),l.createElementBlock("div",{key:0,ref_key:"horizontTrackRef",ref:u,class:l.normalizeClass(["scroll-wrapper__track scroll-wrapper__track_horizont",l.unref(S)]),onClick:q[1]||(q[1]=l.withModifiers((...Z)=>l.unref(M)&&l.unref(M)(...Z),["prevent","left"]))},[l.createElementVNode("div",{ref_key:"horizontBarRef",ref:c,class:"scroll-wrapper__bar",onMousedown:q[0]||(q[0]=l.withModifiers((...Z)=>l.unref(w)&&l.unref(w)(...Z),["prevent","left"]))},null,544)],2)):l.createCommentVNode("",!0)]),l.unref(v)||e.isShowVerticalScroll?(l.openBlock(),l.createElementBlock("div",{key:0,ref_key:"verticalTrackRef",ref:o,class:l.normalizeClass(["scroll-wrapper__track scroll-wrapper__track_vertical",l.unref(y)]),onClick:q[3]||(q[3]=l.withModifiers((...Z)=>l.unref(f)&&l.unref(f)(...Z),["prevent","left"]))},[l.createElementVNode("div",{ref_key:"verticalBarRef",ref:s,class:"scroll-wrapper__bar",onMousedown:q[2]||(q[2]=l.withModifiers((...Z)=>l.unref(h)&&l.unref(h)(...Z),["prevent","left"]))},null,544)],2)):l.createCommentVNode("",!0)])],512))}}),[["__scopeId","data-v-b541879b"]]),fCe=["data-testid"],hCe=["data-testid"],mCe=["data-testid"],G1=me(l.defineComponent({name:"TableSimple",__name:"TableSimple",props:{dataTestid:{default:"TableSimple"}},setup(e,{expose:t}){const n=e,i=l.ref(null),r=l.ref(null),a=l.ref(null),o=l.ref(null),s=l.computed(()=>{let u=1;if(r.value)for(let c=0;c<r.value.children.length;c++)u=Math.max(r.value.children[c].children.length,u);return u});return t({tbodyRef:a,tableRef:i,theadRef:r}),(u,c)=>(l.openBlock(),l.createElementBlock("table",{ref_key:"tableRef",ref:i,class:"simple-table-yui-kit","data-testid":`${n.dataTestid}`},[l.renderSlot(u.$slots,"default",{},()=>[l.renderSlot(u.$slots,"colspan",{},void 0,!0),u.$slots.head?(l.openBlock(),l.createElementBlock("thead",{key:0,ref_key:"theadRef",ref:r,class:"simple-table-yui-kit__head","data-testid":`${n.dataTestid}-Thead`},[l.renderSlot(u.$slots,"head",{},void 0,!0),u.$slots.search?(l.openBlock(),l.createBlock(ec,{key:0,class:"table-new-yui-kit__search",ref_key:"searchRowRef",ref:o,"data-testid":`${n.dataTestid}-Search-Row`},{default:l.withCtx(()=>[l.createVNode(Go,{colspan:s.value,class:"table-new-yui-kit__th","data-testid":`${n.dataTestid}-SearchRow-Search`},{default:l.withCtx(()=>[l.renderSlot(u.$slots,"search",{},void 0,!0)]),_:3},8,["colspan","data-testid"])]),_:3},8,["data-testid"])):l.createCommentVNode("",!0)],8,hCe)):l.createCommentVNode("",!0),l.renderSlot(u.$slots,"body-group",{},()=>[u.$slots.body?(l.openBlock(),l.createElementBlock("tbody",{key:0,ref_key:"tbodyRef",ref:a,class:"simple-table-yui-kit__body","data-testid":`${n.dataTestid}-Tbody`},[l.renderSlot(u.$slots,"body",{},void 0,!0)],8,mCe)):l.createCommentVNode("",!0)],!0)],!0)],8,fCe))}}),[["__scopeId","data-v-834ebe10"]]),pCe=["data-testid"],gCe=["data-testid"],yCe=["onClick","data-testid"],bCe=["data-testid"],K1=me(l.defineComponent({name:"Tabs",__name:"Tabs",props:{tabCount:{},dataTestid:{default:"Tabs"}},emits:["unmount-tab"],setup(e,{emit:t}){const n=e,i=t,r=l.reactive({activeTab:1}),a=s=>Array.from({length:s},(u,c)=>c+1),o=s=>{r.activeTab=s,i("unmount-tab",s)};return(s,u)=>(l.openBlock(),l.createElementBlock("div",{"data-testid":n.dataTestid,class:"tabs"},[l.createElementVNode("nav",{class:"tabs__navigation","data-testid":`${n.dataTestid}-Navigation`},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(a(n.tabCount),c=>(l.openBlock(),l.createElementBlock("button",{key:c,onClick:f=>o(c),class:l.normalizeClass(["tabs__navigation-button",{active:r.activeTab===c}]),"data-testid":`${n.dataTestid}-Navigation-Button`},[l.renderSlot(s.$slots,`header${c}`,{},void 0,!0)],10,yCe))),128))],8,gCe),(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(a(n.tabCount),c=>(l.openBlock(),l.createElementBlock(l.Fragment,{key:c},[r.activeTab===c?(l.openBlock(),l.createElementBlock("article",{key:0,"data-testid":`${n.dataTestid}-Content`,class:"tabs__navigation-content"},[l.renderSlot(s.$slots,`tab${c}`,{},void 0,!0)],8,bCe)):l.createCommentVNode("",!0)],64))),128))],8,pCe))}}),[["__scopeId","data-v-eb8ab4da"]]);function Lt(e){this.content=e}Lt.prototype={constructor:Lt,find:function(e){for(var t=0;t<this.content.length;t+=2)if(this.content[t]===e)return t;return-1},get:function(e){var t=this.find(e);return t==-1?void 0:this.content[t+1]},update:function(e,t,n){var i=n&&n!=e?this.remove(n):this,r=i.find(e),a=i.content.slice();return r==-1?a.push(n||e,t):(a[r+1]=t,n&&(a[r]=n)),new Lt(a)},remove:function(e){var t=this.find(e);if(t==-1)return this;var n=this.content.slice();return n.splice(t,2),new Lt(n)},addToStart:function(e,t){return new Lt([e,t].concat(this.remove(e).content))},addToEnd:function(e,t){var n=this.remove(e).content.slice();return n.push(e,t),new Lt(n)},addBefore:function(e,t,n){var i=this.remove(t),r=i.content.slice(),a=i.find(e);return r.splice(a==-1?r.length:a,0,t,n),new Lt(r)},forEach:function(e){for(var t=0;t<this.content.length;t+=2)e(this.content[t],this.content[t+1])},prepend:function(e){return e=Lt.from(e),e.size?new Lt(e.content.concat(this.subtract(e).content)):this},append:function(e){return e=Lt.from(e),e.size?new Lt(this.subtract(e).content.concat(e.content)):this},subtract:function(e){var t=this;e=Lt.from(e);for(var n=0;n<e.content.length;n+=2)t=t.remove(e.content[n]);return t},toObject:function(){var e={};return this.forEach(function(t,n){e[t]=n}),e},get size(){return this.content.length>>1}},Lt.from=function(e){if(e instanceof Lt)return e;var t=[];if(e)for(var n in e)t.push(n,e[n]);return new Lt(t)};function P4(e,t,n){for(let i=0;;i++){if(i==e.childCount||i==t.childCount)return e.childCount==t.childCount?null:n;let r=e.child(i),a=t.child(i);if(r==a){n+=r.nodeSize;continue}if(!r.sameMarkup(a))return n;if(r.isText&&r.text!=a.text){for(let o=0;r.text[o]==a.text[o];o++)n++;return n}if(r.content.size||a.content.size){let o=P4(r.content,a.content,n+1);if(o!=null)return o}n+=r.nodeSize}}function E4(e,t,n,i){for(let r=e.childCount,a=t.childCount;;){if(r==0||a==0)return r==a?null:{a:n,b:i};let o=e.child(--r),s=t.child(--a),u=o.nodeSize;if(o==s){n-=u,i-=u;continue}if(!o.sameMarkup(s))return{a:n,b:i};if(o.isText&&o.text!=s.text){let c=0,f=Math.min(o.text.length,s.text.length);for(;c<f&&o.text[o.text.length-c-1]==s.text[s.text.length-c-1];)c++,n--,i--;return{a:n,b:i}}if(o.content.size||s.content.size){let c=E4(o.content,s.content,n-1,i-1);if(c)return c}n-=u,i-=u}}class ne{constructor(t,n){if(this.content=t,this.size=n||0,n==null)for(let i=0;i<t.length;i++)this.size+=t[i].nodeSize}nodesBetween(t,n,i,r=0,a){for(let o=0,s=0;s<n;o++){let u=this.content[o],c=s+u.nodeSize;if(c>t&&i(u,r+s,a||null,o)!==!1&&u.content.size){let f=s+1;u.nodesBetween(Math.max(0,t-f),Math.min(u.content.size,n-f),i,r+f)}s=c}}descendants(t){this.nodesBetween(0,this.size,t)}textBetween(t,n,i,r){let a="",o=!0;return this.nodesBetween(t,n,(s,u)=>{let c=s.isText?s.text.slice(Math.max(t,u)-u,n-u):s.isLeaf?r?typeof r=="function"?r(s):r:s.type.spec.leafText?s.type.spec.leafText(s):"":"";s.isBlock&&(s.isLeaf&&c||s.isTextblock)&&i&&(o?o=!1:a+=i),a+=c},0),a}append(t){if(!t.size)return this;if(!this.size)return t;let n=this.lastChild,i=t.firstChild,r=this.content.slice(),a=0;for(n.isText&&n.sameMarkup(i)&&(r[r.length-1]=n.withText(n.text+i.text),a=1);a<t.content.length;a++)r.push(t.content[a]);return new ne(r,this.size+t.size)}cut(t,n=this.size){if(t==0&&n==this.size)return this;let i=[],r=0;if(n>t)for(let a=0,o=0;o<n;a++){let s=this.content[a],u=o+s.nodeSize;u>t&&((o<t||u>n)&&(s.isText?s=s.cut(Math.max(0,t-o),Math.min(s.text.length,n-o)):s=s.cut(Math.max(0,t-o-1),Math.min(s.content.size,n-o-1))),i.push(s),r+=s.nodeSize),o=u}return new ne(i,r)}cutByIndex(t,n){return t==n?ne.empty:t==0&&n==this.content.length?this:new ne(this.content.slice(t,n))}replaceChild(t,n){let i=this.content[t];if(i==n)return this;let r=this.content.slice(),a=this.size+n.nodeSize-i.nodeSize;return r[t]=n,new ne(r,a)}addToStart(t){return new ne([t].concat(this.content),this.size+t.nodeSize)}addToEnd(t){return new ne(this.content.concat(t),this.size+t.nodeSize)}eq(t){if(this.content.length!=t.content.length)return!1;for(let n=0;n<this.content.length;n++)if(!this.content[n].eq(t.content[n]))return!1;return!0}get firstChild(){return this.content.length?this.content[0]:null}get lastChild(){return this.content.length?this.content[this.content.length-1]:null}get childCount(){return this.content.length}child(t){let n=this.content[t];if(!n)throw new RangeError("Index "+t+" out of range for "+this);return n}maybeChild(t){return this.content[t]||null}forEach(t){for(let n=0,i=0;n<this.content.length;n++){let r=this.content[n];t(r,i,n),i+=r.nodeSize}}findDiffStart(t,n=0){return P4(this,t,n)}findDiffEnd(t,n=this.size,i=t.size){return E4(this,t,n,i)}findIndex(t){if(t==0)return tc(0,t);if(t==this.size)return tc(this.content.length,t);if(t>this.size||t<0)throw new RangeError(`Position ${t} outside of fragment (${this})`);for(let n=0,i=0;;n++){let r=this.child(n),a=i+r.nodeSize;if(a>=t)return a==t?tc(n+1,a):tc(n,i);i=a}}toString(){return"<"+this.toStringInner()+">"}toStringInner(){return this.content.join(", ")}toJSON(){return this.content.length?this.content.map(t=>t.toJSON()):null}static fromJSON(t,n){if(!n)return ne.empty;if(!Array.isArray(n))throw new RangeError("Invalid input for Fragment.fromJSON");return new ne(n.map(t.nodeFromJSON))}static fromArray(t){if(!t.length)return ne.empty;let n,i=0;for(let r=0;r<t.length;r++){let a=t[r];i+=a.nodeSize,r&&a.isText&&t[r-1].sameMarkup(a)?(n||(n=t.slice(0,r)),n[n.length-1]=a.withText(n[n.length-1].text+a.text)):n&&n.push(a)}return new ne(n||t,i)}static from(t){if(!t)return ne.empty;if(t instanceof ne)return t;if(Array.isArray(t))return this.fromArray(t);if(t.attrs)return new ne([t],t.nodeSize);throw new RangeError("Can not convert "+t+" to a Fragment"+(t.nodesBetween?" (looks like multiple versions of prosemirror-model were loaded)":""))}}ne.empty=new ne([],0);const Q1={index:0,offset:0};function tc(e,t){return Q1.index=e,Q1.offset=t,Q1}function nc(e,t){if(e===t)return!0;if(!(e&&typeof e=="object")||!(t&&typeof t=="object"))return!1;let n=Array.isArray(e);if(Array.isArray(t)!=n)return!1;if(n){if(e.length!=t.length)return!1;for(let i=0;i<e.length;i++)if(!nc(e[i],t[i]))return!1}else{for(let i in e)if(!(i in t)||!nc(e[i],t[i]))return!1;for(let i in t)if(!(i in e))return!1}return!0}let Ge=class wy{constructor(t,n){this.type=t,this.attrs=n}addToSet(t){let n,i=!1;for(let r=0;r<t.length;r++){let a=t[r];if(this.eq(a))return t;if(this.type.excludes(a.type))n||(n=t.slice(0,r));else{if(a.type.excludes(this.type))return t;!i&&a.type.rank>this.type.rank&&(n||(n=t.slice(0,r)),n.push(this),i=!0),n&&n.push(a)}}return n||(n=t.slice()),i||n.push(this),n}removeFromSet(t){for(let n=0;n<t.length;n++)if(this.eq(t[n]))return t.slice(0,n).concat(t.slice(n+1));return t}isInSet(t){for(let n=0;n<t.length;n++)if(this.eq(t[n]))return!0;return!1}eq(t){return this==t||this.type==t.type&&nc(this.attrs,t.attrs)}toJSON(){let t={type:this.type.name};for(let n in this.attrs){t.attrs=this.attrs;break}return t}static fromJSON(t,n){if(!n)throw new RangeError("Invalid input for Mark.fromJSON");let i=t.marks[n.type];if(!i)throw new RangeError(`There is no mark type ${n.type} in this schema`);let r=i.create(n.attrs);return i.checkAttrs(r.attrs),r}static sameSet(t,n){if(t==n)return!0;if(t.length!=n.length)return!1;for(let i=0;i<t.length;i++)if(!t[i].eq(n[i]))return!1;return!0}static setFrom(t){if(!t||Array.isArray(t)&&t.length==0)return wy.none;if(t instanceof wy)return[t];let n=t.slice();return n.sort((i,r)=>i.type.rank-r.type.rank),n}};Ge.none=[];class ic extends Error{}class le{constructor(t,n,i){this.content=t,this.openStart=n,this.openEnd=i}get size(){return this.content.size-this.openStart-this.openEnd}insertAt(t,n){let i=N4(this.content,t+this.openStart,n);return i&&new le(i,this.openStart,this.openEnd)}removeBetween(t,n){return new le(A4(this.content,t+this.openStart,n+this.openStart),this.openStart,this.openEnd)}eq(t){return this.content.eq(t.content)&&this.openStart==t.openStart&&this.openEnd==t.openEnd}toString(){return this.content+"("+this.openStart+","+this.openEnd+")"}toJSON(){if(!this.content.size)return null;let t={content:this.content.toJSON()};return this.openStart>0&&(t.openStart=this.openStart),this.openEnd>0&&(t.openEnd=this.openEnd),t}static fromJSON(t,n){if(!n)return le.empty;let i=n.openStart||0,r=n.openEnd||0;if(typeof i!="number"||typeof r!="number")throw new RangeError("Invalid input for Slice.fromJSON");return new le(ne.fromJSON(t,n.content),i,r)}static maxOpen(t,n=!0){let i=0,r=0;for(let a=t.firstChild;a&&!a.isLeaf&&(n||!a.type.spec.isolating);a=a.firstChild)i++;for(let a=t.lastChild;a&&!a.isLeaf&&(n||!a.type.spec.isolating);a=a.lastChild)r++;return new le(t,i,r)}}le.empty=new le(ne.empty,0,0);function A4(e,t,n){let{index:i,offset:r}=e.findIndex(t),a=e.maybeChild(i),{index:o,offset:s}=e.findIndex(n);if(r==t||a.isText){if(s!=n&&!e.child(o).isText)throw new RangeError("Removing non-flat range");return e.cut(0,t).append(e.cut(n))}if(i!=o)throw new RangeError("Removing non-flat range");return e.replaceChild(i,a.copy(A4(a.content,t-r-1,n-r-1)))}function N4(e,t,n,i){let{index:r,offset:a}=e.findIndex(t),o=e.maybeChild(r);if(a==t||o.isText)return i&&!i.canReplace(r,r,n)?null:e.cut(0,t).append(n).append(e.cut(t));let s=N4(o.content,t-a-1,n,o);return s&&e.replaceChild(r,o.copy(s))}function wCe(e,t,n){if(n.openStart>e.depth)throw new ic("Inserted content deeper than insertion position");if(e.depth-n.openStart!=t.depth-n.openEnd)throw new ic("Inconsistent open depths");return D4(e,t,n,0)}function D4(e,t,n,i){let r=e.index(i),a=e.node(i);if(r==t.index(i)&&i<e.depth-n.openStart){let o=D4(e,t,n,i+1);return a.copy(a.content.replaceChild(r,o))}else if(n.content.size)if(!n.openStart&&!n.openEnd&&e.depth==i&&t.depth==i){let o=e.parent,s=o.content;return Fa(o,s.cut(0,e.parentOffset).append(n.content).append(s.cut(t.parentOffset)))}else{let{start:o,end:s}=vCe(n,e);return Fa(a,I4(e,o,s,t,i))}else return Fa(a,rc(e,t,i))}function j4(e,t){if(!t.type.compatibleContent(e.type))throw new ic("Cannot join "+t.type.name+" onto "+e.type.name)}function J1(e,t,n){let i=e.node(n);return j4(i,t.node(n)),i}function Va(e,t){let n=t.length-1;n>=0&&e.isText&&e.sameMarkup(t[n])?t[n]=e.withText(t[n].text+e.text):t.push(e)}function Sl(e,t,n,i){let r=(t||e).node(n),a=0,o=t?t.index(n):r.childCount;e&&(a=e.index(n),e.depth>n?a++:e.textOffset&&(Va(e.nodeAfter,i),a++));for(let s=a;s<o;s++)Va(r.child(s),i);t&&t.depth==n&&t.textOffset&&Va(t.nodeBefore,i)}function Fa(e,t){return e.type.checkContent(t),e.copy(t)}function I4(e,t,n,i,r){let a=e.depth>r&&J1(e,t,r+1),o=i.depth>r&&J1(n,i,r+1),s=[];return Sl(null,e,r,s),a&&o&&t.index(r)==n.index(r)?(j4(a,o),Va(Fa(a,I4(e,t,n,i,r+1)),s)):(a&&Va(Fa(a,rc(e,t,r+1)),s),Sl(t,n,r,s),o&&Va(Fa(o,rc(n,i,r+1)),s)),Sl(i,null,r,s),new ne(s)}function rc(e,t,n){let i=[];if(Sl(null,e,n,i),e.depth>n){let r=J1(e,t,n+1);Va(Fa(r,rc(e,t,n+1)),i)}return Sl(t,null,n,i),new ne(i)}function vCe(e,t){let n=t.depth-e.openStart,r=t.node(n).copy(e.content);for(let a=n-1;a>=0;a--)r=t.node(a).copy(ne.from(r));return{start:r.resolveNoCache(e.openStart+n),end:r.resolveNoCache(r.content.size-e.openEnd-n)}}class _l{constructor(t,n,i){this.pos=t,this.path=n,this.parentOffset=i,this.depth=n.length/3-1}resolveDepth(t){return t==null?this.depth:t<0?this.depth+t:t}get parent(){return this.node(this.depth)}get doc(){return this.node(0)}node(t){return this.path[this.resolveDepth(t)*3]}index(t){return this.path[this.resolveDepth(t)*3+1]}indexAfter(t){return t=this.resolveDepth(t),this.index(t)+(t==this.depth&&!this.textOffset?0:1)}start(t){return t=this.resolveDepth(t),t==0?0:this.path[t*3-1]+1}end(t){return t=this.resolveDepth(t),this.start(t)+this.node(t).content.size}before(t){if(t=this.resolveDepth(t),!t)throw new RangeError("There is no position before the top-level node");return t==this.depth+1?this.pos:this.path[t*3-1]}after(t){if(t=this.resolveDepth(t),!t)throw new RangeError("There is no position after the top-level node");return t==this.depth+1?this.pos:this.path[t*3-1]+this.path[t*3].nodeSize}get textOffset(){return this.pos-this.path[this.path.length-1]}get nodeAfter(){let t=this.parent,n=this.index(this.depth);if(n==t.childCount)return null;let i=this.pos-this.path[this.path.length-1],r=t.child(n);return i?t.child(n).cut(i):r}get nodeBefore(){let t=this.index(this.depth),n=this.pos-this.path[this.path.length-1];return n?this.parent.child(t).cut(0,n):t==0?null:this.parent.child(t-1)}posAtIndex(t,n){n=this.resolveDepth(n);let i=this.path[n*3],r=n==0?0:this.path[n*3-1]+1;for(let a=0;a<t;a++)r+=i.child(a).nodeSize;return r}marks(){let t=this.parent,n=this.index();if(t.content.size==0)return Ge.none;if(this.textOffset)return t.child(n).marks;let i=t.maybeChild(n-1),r=t.maybeChild(n);if(!i){let s=i;i=r,r=s}let a=i.marks;for(var o=0;o<a.length;o++)a[o].type.spec.inclusive===!1&&(!r||!a[o].isInSet(r.marks))&&(a=a[o--].removeFromSet(a));return a}marksAcross(t){let n=this.parent.maybeChild(this.index());if(!n||!n.isInline)return null;let i=n.marks,r=t.parent.maybeChild(t.index());for(var a=0;a<i.length;a++)i[a].type.spec.inclusive===!1&&(!r||!i[a].isInSet(r.marks))&&(i=i[a--].removeFromSet(i));return i}sharedDepth(t){for(let n=this.depth;n>0;n--)if(this.start(n)<=t&&this.end(n)>=t)return n;return 0}blockRange(t=this,n){if(t.pos<this.pos)return t.blockRange(this);for(let i=this.depth-(this.parent.inlineContent||this.pos==t.pos?1:0);i>=0;i--)if(t.pos<=this.end(i)&&(!n||n(this.node(i))))return new ac(this,t,i);return null}sameParent(t){return this.pos-this.parentOffset==t.pos-t.parentOffset}max(t){return t.pos>this.pos?t:this}min(t){return t.pos<this.pos?t:this}toString(){let t="";for(let n=1;n<=this.depth;n++)t+=(t?"/":"")+this.node(n).type.name+"_"+this.index(n-1);return t+":"+this.parentOffset}static resolve(t,n){if(!(n>=0&&n<=t.content.size))throw new RangeError("Position "+n+" out of range");let i=[],r=0,a=n;for(let o=t;;){let{index:s,offset:u}=o.content.findIndex(a),c=a-u;if(i.push(o,s,r+u),!c||(o=o.child(s),o.isText))break;a=c-1,r+=u+1}return new _l(n,i,a)}static resolveCached(t,n){let i=W4.get(t);if(i)for(let a=0;a<i.elts.length;a++){let o=i.elts[a];if(o.pos==n)return o}else W4.set(t,i=new kCe);let r=i.elts[i.i]=_l.resolve(t,n);return i.i=(i.i+1)%MCe,r}}class kCe{constructor(){this.elts=[],this.i=0}}const MCe=12,W4=new WeakMap;class ac{constructor(t,n,i){this.$from=t,this.$to=n,this.depth=i}get start(){return this.$from.before(this.depth+1)}get end(){return this.$to.after(this.depth+1)}get parent(){return this.$from.node(this.depth)}get startIndex(){return this.$from.index(this.depth)}get endIndex(){return this.$to.indexAfter(this.depth)}}const CCe=Object.create(null);let Hr=class vy{constructor(t,n,i,r=Ge.none){this.type=t,this.attrs=n,this.marks=r,this.content=i||ne.empty}get children(){return this.content.content}get nodeSize(){return this.isLeaf?1:2+this.content.size}get childCount(){return this.content.childCount}child(t){return this.content.child(t)}maybeChild(t){return this.content.maybeChild(t)}forEach(t){this.content.forEach(t)}nodesBetween(t,n,i,r=0){this.content.nodesBetween(t,n,i,r,this)}descendants(t){this.nodesBetween(0,this.content.size,t)}get textContent(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,"")}textBetween(t,n,i,r){return this.content.textBetween(t,n,i,r)}get firstChild(){return this.content.firstChild}get lastChild(){return this.content.lastChild}eq(t){return this==t||this.sameMarkup(t)&&this.content.eq(t.content)}sameMarkup(t){return this.hasMarkup(t.type,t.attrs,t.marks)}hasMarkup(t,n,i){return this.type==t&&nc(this.attrs,n||t.defaultAttrs||CCe)&&Ge.sameSet(this.marks,i||Ge.none)}copy(t=null){return t==this.content?this:new vy(this.type,this.attrs,t,this.marks)}mark(t){return t==this.marks?this:new vy(this.type,this.attrs,this.content,t)}cut(t,n=this.content.size){return t==0&&n==this.content.size?this:this.copy(this.content.cut(t,n))}slice(t,n=this.content.size,i=!1){if(t==n)return le.empty;let r=this.resolve(t),a=this.resolve(n),o=i?0:r.sharedDepth(n),s=r.start(o),c=r.node(o).content.cut(r.pos-s,a.pos-s);return new le(c,r.depth-o,a.depth-o)}replace(t,n,i){return wCe(this.resolve(t),this.resolve(n),i)}nodeAt(t){for(let n=this;;){let{index:i,offset:r}=n.content.findIndex(t);if(n=n.maybeChild(i),!n)return null;if(r==t||n.isText)return n;t-=r+1}}childAfter(t){let{index:n,offset:i}=this.content.findIndex(t);return{node:this.content.maybeChild(n),index:n,offset:i}}childBefore(t){if(t==0)return{node:null,index:0,offset:0};let{index:n,offset:i}=this.content.findIndex(t);if(i<t)return{node:this.content.child(n),index:n,offset:i};let r=this.content.child(n-1);return{node:r,index:n-1,offset:i-r.nodeSize}}resolve(t){return _l.resolveCached(this,t)}resolveNoCache(t){return _l.resolve(this,t)}rangeHasMark(t,n,i){let r=!1;return n>t&&this.nodesBetween(t,n,a=>(i.isInSet(a.marks)&&(r=!0),!r)),r}get isBlock(){return this.type.isBlock}get isTextblock(){return this.type.isTextblock}get inlineContent(){return this.type.inlineContent}get isInline(){return this.type.isInline}get isText(){return this.type.isText}get isLeaf(){return this.type.isLeaf}get isAtom(){return this.type.isAtom}toString(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);let t=this.type.name;return this.content.size&&(t+="("+this.content.toStringInner()+")"),O4(this.marks,t)}contentMatchAt(t){let n=this.type.contentMatch.matchFragment(this.content,0,t);if(!n)throw new Error("Called contentMatchAt on a node with invalid content");return n}canReplace(t,n,i=ne.empty,r=0,a=i.childCount){let o=this.contentMatchAt(t).matchFragment(i,r,a),s=o&&o.matchFragment(this.content,n);if(!s||!s.validEnd)return!1;for(let u=r;u<a;u++)if(!this.type.allowsMarks(i.child(u).marks))return!1;return!0}canReplaceWith(t,n,i,r){if(r&&!this.type.allowsMarks(r))return!1;let a=this.contentMatchAt(t).matchType(i),o=a&&a.matchFragment(this.content,n);return o?o.validEnd:!1}canAppend(t){return t.content.size?this.canReplace(this.childCount,this.childCount,t.content):this.type.compatibleContent(t.type)}check(){this.type.checkContent(this.content),this.type.checkAttrs(this.attrs);let t=Ge.none;for(let n=0;n<this.marks.length;n++){let i=this.marks[n];i.type.checkAttrs(i.attrs),t=i.addToSet(t)}if(!Ge.sameSet(t,this.marks))throw new RangeError(`Invalid collection of marks for node ${this.type.name}: ${this.marks.map(n=>n.type.name)}`);this.content.forEach(n=>n.check())}toJSON(){let t={type:this.type.name};for(let n in this.attrs){t.attrs=this.attrs;break}return this.content.size&&(t.content=this.content.toJSON()),this.marks.length&&(t.marks=this.marks.map(n=>n.toJSON())),t}static fromJSON(t,n){if(!n)throw new RangeError("Invalid input for Node.fromJSON");let i;if(n.marks){if(!Array.isArray(n.marks))throw new RangeError("Invalid mark data for Node.fromJSON");i=n.marks.map(t.markFromJSON)}if(n.type=="text"){if(typeof n.text!="string")throw new RangeError("Invalid text node in JSON");return t.text(n.text,i)}let r=ne.fromJSON(t,n.content),a=t.nodeType(n.type).create(n.attrs,r,i);return a.type.checkAttrs(a.attrs),a}};Hr.prototype.text=void 0;class oc extends Hr{constructor(t,n,i,r){if(super(t,n,null,r),!i)throw new RangeError("Empty text nodes are not allowed");this.text=i}toString(){return this.type.spec.toDebugString?this.type.spec.toDebugString(this):O4(this.marks,JSON.stringify(this.text))}get textContent(){return this.text}textBetween(t,n){return this.text.slice(t,n)}get nodeSize(){return this.text.length}mark(t){return t==this.marks?this:new oc(this.type,this.attrs,this.text,t)}withText(t){return t==this.text?this:new oc(this.type,this.attrs,t,this.marks)}cut(t=0,n=this.text.length){return t==0&&n==this.text.length?this:this.withText(this.text.slice(t,n))}eq(t){return this.sameMarkup(t)&&this.text==t.text}toJSON(){let t=super.toJSON();return t.text=this.text,t}}function O4(e,t){for(let n=e.length-1;n>=0;n--)t=e[n].type.name+"("+t+")";return t}class Ua{constructor(t){this.validEnd=t,this.next=[],this.wrapCache=[]}static parse(t,n){let i=new xCe(t,n);if(i.next==null)return Ua.empty;let r=z4(i);i.next&&i.err("Unexpected trailing text");let a=NCe(ACe(r));return DCe(a,i),a}matchType(t){for(let n=0;n<this.next.length;n++)if(this.next[n].type==t)return this.next[n].next;return null}matchFragment(t,n=0,i=t.childCount){let r=this;for(let a=n;r&&a<i;a++)r=r.matchType(t.child(a).type);return r}get inlineContent(){return this.next.length!=0&&this.next[0].type.isInline}get defaultType(){for(let t=0;t<this.next.length;t++){let{type:n}=this.next[t];if(!(n.isText||n.hasRequiredAttrs()))return n}return null}compatible(t){for(let n=0;n<this.next.length;n++)for(let i=0;i<t.next.length;i++)if(this.next[n].type==t.next[i].type)return!0;return!1}fillBefore(t,n=!1,i=0){let r=[this];function a(o,s){let u=o.matchFragment(t,i);if(u&&(!n||u.validEnd))return ne.from(s.map(c=>c.createAndFill()));for(let c=0;c<o.next.length;c++){let{type:f,next:h}=o.next[c];if(!(f.isText||f.hasRequiredAttrs())&&r.indexOf(h)==-1){r.push(h);let g=a(h,s.concat(f));if(g)return g}}return null}return a(this,[])}findWrapping(t){for(let i=0;i<this.wrapCache.length;i+=2)if(this.wrapCache[i]==t)return this.wrapCache[i+1];let n=this.computeWrapping(t);return this.wrapCache.push(t,n),n}computeWrapping(t){let n=Object.create(null),i=[{match:this,type:null,via:null}];for(;i.length;){let r=i.shift(),a=r.match;if(a.matchType(t)){let o=[];for(let s=r;s.type;s=s.via)o.push(s.type);return o.reverse()}for(let o=0;o<a.next.length;o++){let{type:s,next:u}=a.next[o];!s.isLeaf&&!s.hasRequiredAttrs()&&!(s.name in n)&&(!r.type||u.validEnd)&&(i.push({match:s.contentMatch,type:s,via:r}),n[s.name]=!0)}}return null}get edgeCount(){return this.next.length}edge(t){if(t>=this.next.length)throw new RangeError(`There's no ${t}th edge in this content match`);return this.next[t]}toString(){let t=[];function n(i){t.push(i);for(let r=0;r<i.next.length;r++)t.indexOf(i.next[r].next)==-1&&n(i.next[r].next)}return n(this),t.map((i,r)=>{let a=r+(i.validEnd?"*":" ")+" ";for(let o=0;o<i.next.length;o++)a+=(o?", ":"")+i.next[o].type.name+"->"+t.indexOf(i.next[o].next);return a}).join(`
|
|
1299
1299
|
`)}}Ua.empty=new Ua(!0);class xCe{constructor(t,n){this.string=t,this.nodeTypes=n,this.inline=null,this.pos=0,this.tokens=t.split(/\s*(?=\b|\W|$)/),this.tokens[this.tokens.length-1]==""&&this.tokens.pop(),this.tokens[0]==""&&this.tokens.shift()}get next(){return this.tokens[this.pos]}eat(t){return this.next==t&&(this.pos++||!0)}err(t){throw new SyntaxError(t+" (in content expression '"+this.string+"')")}}function z4(e){let t=[];do t.push(SCe(e));while(e.eat("|"));return t.length==1?t[0]:{type:"choice",exprs:t}}function SCe(e){let t=[];do t.push(_Ce(e));while(e.next&&e.next!=")"&&e.next!="|");return t.length==1?t[0]:{type:"seq",exprs:t}}function _Ce(e){let t=ECe(e);for(;;)if(e.eat("+"))t={type:"plus",expr:t};else if(e.eat("*"))t={type:"star",expr:t};else if(e.eat("?"))t={type:"opt",expr:t};else if(e.eat("{"))t=TCe(e,t);else break;return t}function L4(e){/\D/.test(e.next)&&e.err("Expected number, got '"+e.next+"'");let t=Number(e.next);return e.pos++,t}function TCe(e,t){let n=L4(e),i=n;return e.eat(",")&&(e.next!="}"?i=L4(e):i=-1),e.eat("}")||e.err("Unclosed braced range"),{type:"range",min:n,max:i,expr:t}}function PCe(e,t){let n=e.nodeTypes,i=n[t];if(i)return[i];let r=[];for(let a in n){let o=n[a];o.isInGroup(t)&&r.push(o)}return r.length==0&&e.err("No node type or group '"+t+"' found"),r}function ECe(e){if(e.eat("(")){let t=z4(e);return e.eat(")")||e.err("Missing closing paren"),t}else if(/\W/.test(e.next))e.err("Unexpected token '"+e.next+"'");else{let t=PCe(e,e.next).map(n=>(e.inline==null?e.inline=n.isInline:e.inline!=n.isInline&&e.err("Mixing inline and block content"),{type:"name",value:n}));return e.pos++,t.length==1?t[0]:{type:"choice",exprs:t}}}function ACe(e){let t=[[]];return r(a(e,0),n()),t;function n(){return t.push([])-1}function i(o,s,u){let c={term:u,to:s};return t[o].push(c),c}function r(o,s){o.forEach(u=>u.to=s)}function a(o,s){if(o.type=="choice")return o.exprs.reduce((u,c)=>u.concat(a(c,s)),[]);if(o.type=="seq")for(let u=0;;u++){let c=a(o.exprs[u],s);if(u==o.exprs.length-1)return c;r(c,s=n())}else if(o.type=="star"){let u=n();return i(s,u),r(a(o.expr,u),u),[i(u)]}else if(o.type=="plus"){let u=n();return r(a(o.expr,s),u),r(a(o.expr,u),u),[i(u)]}else{if(o.type=="opt")return[i(s)].concat(a(o.expr,s));if(o.type=="range"){let u=s;for(let c=0;c<o.min;c++){let f=n();r(a(o.expr,u),f),u=f}if(o.max==-1)r(a(o.expr,u),u);else for(let c=o.min;c<o.max;c++){let f=n();i(u,f),r(a(o.expr,u),f),u=f}return[i(u)]}else{if(o.type=="name")return[i(s,void 0,o.value)];throw new Error("Unknown expr type")}}}}function $4(e,t){return t-e}function H4(e,t){let n=[];return i(t),n.sort($4);function i(r){let a=e[r];if(a.length==1&&!a[0].term)return i(a[0].to);n.push(r);for(let o=0;o<a.length;o++){let{term:s,to:u}=a[o];!s&&n.indexOf(u)==-1&&i(u)}}}function NCe(e){let t=Object.create(null);return n(H4(e,0));function n(i){let r=[];i.forEach(o=>{e[o].forEach(({term:s,to:u})=>{if(!s)return;let c;for(let f=0;f<r.length;f++)r[f][0]==s&&(c=r[f][1]);H4(e,u).forEach(f=>{c||r.push([s,c=[]]),c.indexOf(f)==-1&&c.push(f)})})});let a=t[i.join(",")]=new Ua(i.indexOf(e.length-1)>-1);for(let o=0;o<r.length;o++){let s=r[o][1].sort($4);a.next.push({type:r[o][0],next:t[s.join(",")]||n(s)})}return a}}function DCe(e,t){for(let n=0,i=[e];n<i.length;n++){let r=i[n],a=!r.validEnd,o=[];for(let s=0;s<r.next.length;s++){let{type:u,next:c}=r.next[s];o.push(u.name),a&&!(u.isText||u.hasRequiredAttrs())&&(a=!1),i.indexOf(c)==-1&&i.push(c)}a&&t.err("Only non-generatable nodes ("+o.join(", ")+") in a required position (see https://prosemirror.net/docs/guide/#generatable)")}}function R4(e){let t=Object.create(null);for(let n in e){let i=e[n];if(!i.hasDefault)return null;t[n]=i.default}return t}function B4(e,t){let n=Object.create(null);for(let i in e){let r=t&&t[i];if(r===void 0){let a=e[i];if(a.hasDefault)r=a.default;else throw new RangeError("No value supplied for attribute "+i)}n[i]=r}return n}function V4(e,t,n,i){for(let r in t)if(!(r in e))throw new RangeError(`Unsupported attribute ${r} for ${n} of type ${r}`);for(let r in e){let a=e[r];a.validate&&a.validate(t[r])}}function F4(e,t){let n=Object.create(null);if(t)for(let i in t)n[i]=new ICe(e,i,t[i]);return n}let U4=class C8{constructor(t,n,i){this.name=t,this.schema=n,this.spec=i,this.markSet=null,this.groups=i.group?i.group.split(" "):[],this.attrs=F4(t,i.attrs),this.defaultAttrs=R4(this.attrs),this.contentMatch=null,this.inlineContent=null,this.isBlock=!(i.inline||t=="text"),this.isText=t=="text"}get isInline(){return!this.isBlock}get isTextblock(){return this.isBlock&&this.inlineContent}get isLeaf(){return this.contentMatch==Ua.empty}get isAtom(){return this.isLeaf||!!this.spec.atom}isInGroup(t){return this.groups.indexOf(t)>-1}get whitespace(){return this.spec.whitespace||(this.spec.code?"pre":"normal")}hasRequiredAttrs(){for(let t in this.attrs)if(this.attrs[t].isRequired)return!0;return!1}compatibleContent(t){return this==t||this.contentMatch.compatible(t.contentMatch)}computeAttrs(t){return!t&&this.defaultAttrs?this.defaultAttrs:B4(this.attrs,t)}create(t=null,n,i){if(this.isText)throw new Error("NodeType.create can't construct text nodes");return new Hr(this,this.computeAttrs(t),ne.from(n),Ge.setFrom(i))}createChecked(t=null,n,i){return n=ne.from(n),this.checkContent(n),new Hr(this,this.computeAttrs(t),n,Ge.setFrom(i))}createAndFill(t=null,n,i){if(t=this.computeAttrs(t),n=ne.from(n),n.size){let o=this.contentMatch.fillBefore(n);if(!o)return null;n=o.append(n)}let r=this.contentMatch.matchFragment(n),a=r&&r.fillBefore(ne.empty,!0);return a?new Hr(this,t,n.append(a),Ge.setFrom(i)):null}validContent(t){let n=this.contentMatch.matchFragment(t);if(!n||!n.validEnd)return!1;for(let i=0;i<t.childCount;i++)if(!this.allowsMarks(t.child(i).marks))return!1;return!0}checkContent(t){if(!this.validContent(t))throw new RangeError(`Invalid content for node ${this.name}: ${t.toString().slice(0,50)}`)}checkAttrs(t){V4(this.attrs,t,"node",this.name)}allowsMarkType(t){return this.markSet==null||this.markSet.indexOf(t)>-1}allowsMarks(t){if(this.markSet==null)return!0;for(let n=0;n<t.length;n++)if(!this.allowsMarkType(t[n].type))return!1;return!0}allowedMarks(t){if(this.markSet==null)return t;let n;for(let i=0;i<t.length;i++)this.allowsMarkType(t[i].type)?n&&n.push(t[i]):n||(n=t.slice(0,i));return n?n.length?n:Ge.none:t}static compile(t,n){let i=Object.create(null);t.forEach((a,o)=>i[a]=new C8(a,n,o));let r=n.spec.topNode||"doc";if(!i[r])throw new RangeError("Schema is missing its top node type ('"+r+"')");if(!i.text)throw new RangeError("Every schema needs a 'text' type");for(let a in i.text.attrs)throw new RangeError("The text node type should not have attributes");return i}};function jCe(e,t,n){let i=n.split("|");return r=>{let a=r===null?"null":typeof r;if(i.indexOf(a)<0)throw new RangeError(`Expected value of type ${i} for attribute ${t} on type ${e}, got ${a}`)}}class ICe{constructor(t,n,i){this.hasDefault=Object.prototype.hasOwnProperty.call(i,"default"),this.default=i.default,this.validate=typeof i.validate=="string"?jCe(t,n,i.validate):i.validate}get isRequired(){return!this.hasDefault}}class sc{constructor(t,n,i,r){this.name=t,this.rank=n,this.schema=i,this.spec=r,this.attrs=F4(t,r.attrs),this.excluded=null;let a=R4(this.attrs);this.instance=a?new Ge(this,a):null}create(t=null){return!t&&this.instance?this.instance:new Ge(this,B4(this.attrs,t))}static compile(t,n){let i=Object.create(null),r=0;return t.forEach((a,o)=>i[a]=new sc(a,r++,n,o)),i}removeFromSet(t){for(var n=0;n<t.length;n++)t[n].type==this&&(t=t.slice(0,n).concat(t.slice(n+1)),n--);return t}isInSet(t){for(let n=0;n<t.length;n++)if(t[n].type==this)return t[n]}checkAttrs(t){V4(this.attrs,t,"mark",this.name)}excludes(t){return this.excluded.indexOf(t)>-1}}class Y4{constructor(t){this.linebreakReplacement=null,this.cached=Object.create(null);let n=this.spec={};for(let r in t)n[r]=t[r];n.nodes=Lt.from(t.nodes),n.marks=Lt.from(t.marks||{}),this.nodes=U4.compile(this.spec.nodes,this),this.marks=sc.compile(this.spec.marks,this);let i=Object.create(null);for(let r in this.nodes){if(r in this.marks)throw new RangeError(r+" can not be both a node and a mark");let a=this.nodes[r],o=a.spec.content||"",s=a.spec.marks;if(a.contentMatch=i[o]||(i[o]=Ua.parse(o,this.nodes)),a.inlineContent=a.contentMatch.inlineContent,a.spec.linebreakReplacement){if(this.linebreakReplacement)throw new RangeError("Multiple linebreak nodes defined");if(!a.isInline||!a.isLeaf)throw new RangeError("Linebreak replacement nodes must be inline leaf nodes");this.linebreakReplacement=a}a.markSet=s=="_"?null:s?X4(this,s.split(" ")):s==""||!a.inlineContent?[]:null}for(let r in this.marks){let a=this.marks[r],o=a.spec.excludes;a.excluded=o==null?[a]:o==""?[]:X4(this,o.split(" "))}this.nodeFromJSON=r=>Hr.fromJSON(this,r),this.markFromJSON=r=>Ge.fromJSON(this,r),this.topNodeType=this.nodes[this.spec.topNode||"doc"],this.cached.wrappings=Object.create(null)}node(t,n=null,i,r){if(typeof t=="string")t=this.nodeType(t);else if(t instanceof U4){if(t.schema!=this)throw new RangeError("Node type from different schema used ("+t.name+")")}else throw new RangeError("Invalid node type: "+t);return t.createChecked(n,i,r)}text(t,n){let i=this.nodes.text;return new oc(i,i.defaultAttrs,t,Ge.setFrom(n))}mark(t,n){return typeof t=="string"&&(t=this.marks[t]),t.create(n)}nodeType(t){let n=this.nodes[t];if(!n)throw new RangeError("Unknown node type: "+t);return n}}function X4(e,t){let n=[];for(let i=0;i<t.length;i++){let r=t[i],a=e.marks[r],o=a;if(a)n.push(a);else for(let s in e.marks){let u=e.marks[s];(r=="_"||u.spec.group&&u.spec.group.split(" ").indexOf(r)>-1)&&n.push(o=u)}if(!o)throw new SyntaxError("Unknown mark type: '"+t[i]+"'")}return n}function WCe(e){return e.tag!=null}function OCe(e){return e.style!=null}class Rr{constructor(t,n){this.schema=t,this.rules=n,this.tags=[],this.styles=[];let i=this.matchedStyles=[];n.forEach(r=>{if(WCe(r))this.tags.push(r);else if(OCe(r)){let a=/[^=]*/.exec(r.style)[0];i.indexOf(a)<0&&i.push(a),this.styles.push(r)}}),this.normalizeLists=!this.tags.some(r=>{if(!/^(ul|ol)\b/.test(r.tag)||!r.node)return!1;let a=t.nodes[r.node];return a.contentMatch.matchType(a)})}parse(t,n={}){let i=new Q4(this,n,!1);return i.addAll(t,Ge.none,n.from,n.to),i.finish()}parseSlice(t,n={}){let i=new Q4(this,n,!0);return i.addAll(t,Ge.none,n.from,n.to),le.maxOpen(i.finish())}matchTag(t,n,i){for(let r=i?this.tags.indexOf(i)+1:0;r<this.tags.length;r++){let a=this.tags[r];if($Ce(t,a.tag)&&(a.namespace===void 0||t.namespaceURI==a.namespace)&&(!a.context||n.matchesContext(a.context))){if(a.getAttrs){let o=a.getAttrs(t);if(o===!1)continue;a.attrs=o||void 0}return a}}}matchStyle(t,n,i,r){for(let a=r?this.styles.indexOf(r)+1:0;a<this.styles.length;a++){let o=this.styles[a],s=o.style;if(!(s.indexOf(t)!=0||o.context&&!i.matchesContext(o.context)||s.length>t.length&&(s.charCodeAt(t.length)!=61||s.slice(t.length+1)!=n))){if(o.getAttrs){let u=o.getAttrs(n);if(u===!1)continue;o.attrs=u||void 0}return o}}}static schemaRules(t){let n=[];function i(r){let a=r.priority==null?50:r.priority,o=0;for(;o<n.length;o++){let s=n[o];if((s.priority==null?50:s.priority)<a)break}n.splice(o,0,r)}for(let r in t.marks){let a=t.marks[r].spec.parseDOM;a&&a.forEach(o=>{i(o=J4(o)),o.mark||o.ignore||o.clearMark||(o.mark=r)})}for(let r in t.nodes){let a=t.nodes[r].spec.parseDOM;a&&a.forEach(o=>{i(o=J4(o)),o.node||o.ignore||o.mark||(o.node=r)})}return n}static fromSchema(t){return t.cached.domParser||(t.cached.domParser=new Rr(t,Rr.schemaRules(t)))}}const q4={address:!0,article:!0,aside:!0,blockquote:!0,canvas:!0,dd:!0,div:!0,dl:!0,fieldset:!0,figcaption:!0,figure:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,li:!0,noscript:!0,ol:!0,output:!0,p:!0,pre:!0,section:!0,table:!0,tfoot:!0,ul:!0},zCe={head:!0,noscript:!0,object:!0,script:!0,style:!0,title:!0},G4={ol:!0,ul:!0},Tl=1,Z1=2,Pl=4;function K4(e,t,n){return t!=null?(t?Tl:0)|(t==="full"?Z1:0):e&&e.whitespace=="pre"?Tl|Z1:n&~Pl}class lc{constructor(t,n,i,r,a,o){this.type=t,this.attrs=n,this.marks=i,this.solid=r,this.options=o,this.content=[],this.activeMarks=Ge.none,this.match=a||(o&Pl?null:t.contentMatch)}findWrapping(t){if(!this.match){if(!this.type)return[];let n=this.type.contentMatch.fillBefore(ne.from(t));if(n)this.match=this.type.contentMatch.matchFragment(n);else{let i=this.type.contentMatch,r;return(r=i.findWrapping(t.type))?(this.match=i,r):null}}return this.match.findWrapping(t.type)}finish(t){if(!(this.options&Tl)){let i=this.content[this.content.length-1],r;if(i&&i.isText&&(r=/[ \t\r\n\u000c]+$/.exec(i.text))){let a=i;i.text.length==r[0].length?this.content.pop():this.content[this.content.length-1]=a.withText(a.text.slice(0,a.text.length-r[0].length))}}let n=ne.from(this.content);return!t&&this.match&&(n=n.append(this.match.fillBefore(ne.empty,!0))),this.type?this.type.create(this.attrs,n,this.marks):n}inlineContext(t){return this.type?this.type.inlineContent:this.content.length?this.content[0].isInline:t.parentNode&&!q4.hasOwnProperty(t.parentNode.nodeName.toLowerCase())}}class Q4{constructor(t,n,i){this.parser=t,this.options=n,this.isOpen=i,this.open=0,this.localPreserveWS=!1;let r=n.topNode,a,o=K4(null,n.preserveWhitespace,0)|(i?Pl:0);r?a=new lc(r.type,r.attrs,Ge.none,!0,n.topMatch||r.type.contentMatch,o):i?a=new lc(null,null,Ge.none,!0,null,o):a=new lc(t.schema.topNodeType,null,Ge.none,!0,null,o),this.nodes=[a],this.find=n.findPositions,this.needsBlock=!1}get top(){return this.nodes[this.open]}addDOM(t,n){t.nodeType==3?this.addTextNode(t,n):t.nodeType==1&&this.addElement(t,n)}addTextNode(t,n){let i=t.nodeValue,r=this.top,a=r.options&Z1?"full":this.localPreserveWS||(r.options&Tl)>0;if(a==="full"||r.inlineContext(t)||/[^ \t\r\n\u000c]/.test(i)){if(a)a!=="full"?i=i.replace(/\r?\n|\r/g," "):i=i.replace(/\r\n?/g,`
|
|
1300
1300
|
`);else if(i=i.replace(/[ \t\r\n\u000c]+/g," "),/^[ \t\r\n\u000c]/.test(i)&&this.open==this.nodes.length-1){let o=r.content[r.content.length-1],s=t.previousSibling;(!o||s&&s.nodeName=="BR"||o.isText&&/[ \t\r\n\u000c]$/.test(o.text))&&(i=i.slice(1))}i&&this.insertNode(this.parser.schema.text(i),n,!/\S/.test(i)),this.findInText(t)}else this.findInside(t)}addElement(t,n,i){let r=this.localPreserveWS,a=this.top;(t.tagName=="PRE"||/pre/.test(t.style&&t.style.whiteSpace))&&(this.localPreserveWS=!0);let o=t.nodeName.toLowerCase(),s;G4.hasOwnProperty(o)&&this.parser.normalizeLists&&LCe(t);let u=this.options.ruleFromNode&&this.options.ruleFromNode(t)||(s=this.parser.matchTag(t,this,i));e:if(u?u.ignore:zCe.hasOwnProperty(o))this.findInside(t),this.ignoreFallback(t,n);else if(!u||u.skip||u.closeParent){u&&u.closeParent?this.open=Math.max(0,this.open-1):u&&u.skip.nodeType&&(t=u.skip);let c,f=this.needsBlock;if(q4.hasOwnProperty(o))a.content.length&&a.content[0].isInline&&this.open&&(this.open--,a=this.top),c=!0,a.type||(this.needsBlock=!0);else if(!t.firstChild){this.leafFallback(t,n);break e}let h=u&&u.skip?n:this.readStyles(t,n);h&&this.addAll(t,h),c&&this.sync(a),this.needsBlock=f}else{let c=this.readStyles(t,n);c&&this.addElementByRule(t,u,c,u.consuming===!1?s:void 0)}this.localPreserveWS=r}leafFallback(t,n){t.nodeName=="BR"&&this.top.type&&this.top.type.inlineContent&&this.addTextNode(t.ownerDocument.createTextNode(`
|
|
1301
1301
|
`),n)}ignoreFallback(t,n){t.nodeName=="BR"&&(!this.top.type||!this.top.type.inlineContent)&&this.findPlace(this.parser.schema.text("-"),n,!0)}readStyles(t,n){let i=t.style;if(i&&i.length)for(let r=0;r<this.parser.matchedStyles.length;r++){let a=this.parser.matchedStyles[r],o=i.getPropertyValue(a);if(o)for(let s=void 0;;){let u=this.parser.matchStyle(a,o,this,s);if(!u)break;if(u.ignore)return null;if(u.clearMark?n=n.filter(c=>!u.clearMark(c)):n=n.concat(this.parser.schema.marks[u.mark].create(u.attrs)),u.consuming===!1)s=u;else break}}return n}addElementByRule(t,n,i,r){let a,o;if(n.node)if(o=this.parser.schema.nodes[n.node],o.isLeaf)this.insertNode(o.create(n.attrs),i,t.nodeName=="BR")||this.leafFallback(t,i);else{let u=this.enter(o,n.attrs||null,i,n.preserveWhitespace);u&&(a=!0,i=u)}else{let u=this.parser.schema.marks[n.mark];i=i.concat(u.create(n.attrs))}let s=this.top;if(o&&o.isLeaf)this.findInside(t);else if(r)this.addElement(t,i,r);else if(n.getContent)this.findInside(t),n.getContent(t,this.parser.schema).forEach(u=>this.insertNode(u,i,!1));else{let u=t;typeof n.contentElement=="string"?u=t.querySelector(n.contentElement):typeof n.contentElement=="function"?u=n.contentElement(t):n.contentElement&&(u=n.contentElement),this.findAround(t,u,!0),this.addAll(u,i),this.findAround(t,u,!1)}a&&this.sync(s)&&this.open--}addAll(t,n,i,r){let a=i||0;for(let o=i?t.childNodes[i]:t.firstChild,s=r==null?null:t.childNodes[r];o!=s;o=o.nextSibling,++a)this.findAtPoint(t,a),this.addDOM(o,n);this.findAtPoint(t,a)}findPlace(t,n,i){let r,a;for(let o=this.open,s=0;o>=0;o--){let u=this.nodes[o],c=u.findWrapping(t);if(c&&(!r||r.length>c.length+s)&&(r=c,a=u,!c.length))break;if(u.solid){if(i)break;s+=2}}if(!r)return null;this.sync(a);for(let o=0;o<r.length;o++)n=this.enterInner(r[o],null,n,!1);return n}insertNode(t,n,i){if(t.isInline&&this.needsBlock&&!this.top.type){let a=this.textblockFromContext();a&&(n=this.enterInner(a,null,n))}let r=this.findPlace(t,n,i);if(r){this.closeExtra();let a=this.top;a.match&&(a.match=a.match.matchType(t.type));let o=Ge.none;for(let s of r.concat(t.marks))(a.type?a.type.allowsMarkType(s.type):Z4(s.type,t.type))&&(o=s.addToSet(o));return a.content.push(t.mark(o)),!0}return!1}enter(t,n,i,r){let a=this.findPlace(t.create(n),i,!1);return a&&(a=this.enterInner(t,n,i,!0,r)),a}enterInner(t,n,i,r=!1,a){this.closeExtra();let o=this.top;o.match=o.match&&o.match.matchType(t);let s=K4(t,a,o.options);o.options&Pl&&o.content.length==0&&(s|=Pl);let u=Ge.none;return i=i.filter(c=>(o.type?o.type.allowsMarkType(c.type):Z4(c.type,t))?(u=c.addToSet(u),!1):!0),this.nodes.push(new lc(t,n,u,r,null,s)),this.open++,i}closeExtra(t=!1){let n=this.nodes.length-1;if(n>this.open){for(;n>this.open;n--)this.nodes[n-1].content.push(this.nodes[n].finish(t));this.nodes.length=this.open+1}}finish(){return this.open=0,this.closeExtra(this.isOpen),this.nodes[0].finish(!!(this.isOpen||this.options.topOpen))}sync(t){for(let n=this.open;n>=0;n--){if(this.nodes[n]==t)return this.open=n,!0;this.localPreserveWS&&(this.nodes[n].options|=Tl)}return!1}get currentPos(){this.closeExtra();let t=0;for(let n=this.open;n>=0;n--){let i=this.nodes[n].content;for(let r=i.length-1;r>=0;r--)t+=i[r].nodeSize;n&&t++}return t}findAtPoint(t,n){if(this.find)for(let i=0;i<this.find.length;i++)this.find[i].node==t&&this.find[i].offset==n&&(this.find[i].pos=this.currentPos)}findInside(t){if(this.find)for(let n=0;n<this.find.length;n++)this.find[n].pos==null&&t.nodeType==1&&t.contains(this.find[n].node)&&(this.find[n].pos=this.currentPos)}findAround(t,n,i){if(t!=n&&this.find)for(let r=0;r<this.find.length;r++)this.find[r].pos==null&&t.nodeType==1&&t.contains(this.find[r].node)&&n.compareDocumentPosition(this.find[r].node)&(i?2:4)&&(this.find[r].pos=this.currentPos)}findInText(t){if(this.find)for(let n=0;n<this.find.length;n++)this.find[n].node==t&&(this.find[n].pos=this.currentPos-(t.nodeValue.length-this.find[n].offset))}matchesContext(t){if(t.indexOf("|")>-1)return t.split(/\s*\|\s*/).some(this.matchesContext,this);let n=t.split("/"),i=this.options.context,r=!this.isOpen&&(!i||i.parent.type==this.nodes[0].type),a=-(i?i.depth+1:0)+(r?0:1),o=(s,u)=>{for(;s>=0;s--){let c=n[s];if(c==""){if(s==n.length-1||s==0)continue;for(;u>=a;u--)if(o(s-1,u))return!0;return!1}else{let f=u>0||u==0&&r?this.nodes[u].type:i&&u>=a?i.node(u-a).type:null;if(!f||f.name!=c&&!f.isInGroup(c))return!1;u--}}return!0};return o(n.length-1,this.open)}textblockFromContext(){let t=this.options.context;if(t)for(let n=t.depth;n>=0;n--){let i=t.node(n).contentMatchAt(t.indexAfter(n)).defaultType;if(i&&i.isTextblock&&i.defaultAttrs)return i}for(let n in this.parser.schema.nodes){let i=this.parser.schema.nodes[n];if(i.isTextblock&&i.defaultAttrs)return i}}}function LCe(e){for(let t=e.firstChild,n=null;t;t=t.nextSibling){let i=t.nodeType==1?t.nodeName.toLowerCase():null;i&&G4.hasOwnProperty(i)&&n?(n.appendChild(t),t=n):i=="li"?n=t:i&&(n=null)}}function $Ce(e,t){return(e.matches||e.msMatchesSelector||e.webkitMatchesSelector||e.mozMatchesSelector).call(e,t)}function J4(e){let t={};for(let n in e)t[n]=e[n];return t}function Z4(e,t){let n=t.schema.nodes;for(let i in n){let r=n[i];if(!r.allowsMarkType(e))continue;let a=[],o=s=>{a.push(s);for(let u=0;u<s.edgeCount;u++){let{type:c,next:f}=s.edge(u);if(c==t||a.indexOf(f)<0&&o(f))return!0}};if(o(r.contentMatch))return!0}}class Ya{constructor(t,n){this.nodes=t,this.marks=n}serializeFragment(t,n={},i){i||(i=ep(n).createDocumentFragment());let r=i,a=[];return t.forEach(o=>{if(a.length||o.marks.length){let s=0,u=0;for(;s<a.length&&u<o.marks.length;){let c=o.marks[u];if(!this.marks[c.type.name]){u++;continue}if(!c.eq(a[s][0])||c.type.spec.spanning===!1)break;s++,u++}for(;s<a.length;)r=a.pop()[1];for(;u<o.marks.length;){let c=o.marks[u++],f=this.serializeMark(c,o.isInline,n);f&&(a.push([c,r]),r.appendChild(f.dom),r=f.contentDOM||f.dom)}}r.appendChild(this.serializeNodeInner(o,n))}),i}serializeNodeInner(t,n){let{dom:i,contentDOM:r}=uc(ep(n),this.nodes[t.type.name](t),null,t.attrs);if(r){if(t.isLeaf)throw new RangeError("Content hole not allowed in a leaf node spec");this.serializeFragment(t.content,n,r)}return i}serializeNode(t,n={}){let i=this.serializeNodeInner(t,n);for(let r=t.marks.length-1;r>=0;r--){let a=this.serializeMark(t.marks[r],t.isInline,n);a&&((a.contentDOM||a.dom).appendChild(i),i=a.dom)}return i}serializeMark(t,n,i={}){let r=this.marks[t.type.name];return r&&uc(ep(i),r(t,n),null,t.attrs)}static renderSpec(t,n,i=null,r){return uc(t,n,i,r)}static fromSchema(t){return t.cached.domSerializer||(t.cached.domSerializer=new Ya(this.nodesFromSchema(t),this.marksFromSchema(t)))}static nodesFromSchema(t){let n=e3(t.nodes);return n.text||(n.text=i=>i.text),n}static marksFromSchema(t){return e3(t.marks)}}function e3(e){let t={};for(let n in e){let i=e[n].spec.toDOM;i&&(t[n]=i)}return t}function ep(e){return e.document||window.document}const t3=new WeakMap;function HCe(e){let t=t3.get(e);return t===void 0&&t3.set(e,t=RCe(e)),t}function RCe(e){let t=null;function n(i){if(i&&typeof i=="object")if(Array.isArray(i))if(typeof i[0]=="string")t||(t=[]),t.push(i);else for(let r=0;r<i.length;r++)n(i[r]);else for(let r in i)n(i[r])}return n(e),t}function uc(e,t,n,i){if(typeof t=="string")return{dom:e.createTextNode(t)};if(t.nodeType!=null)return{dom:t};if(t.dom&&t.dom.nodeType!=null)return t;let r=t[0],a;if(typeof r!="string")throw new RangeError("Invalid array passed to renderSpec");if(i&&(a=HCe(i))&&a.indexOf(t)>-1)throw new RangeError("Using an array from an attribute object as a DOM spec. This may be an attempted cross site scripting attack.");let o=r.indexOf(" ");o>0&&(n=r.slice(0,o),r=r.slice(o+1));let s,u=n?e.createElementNS(n,r):e.createElement(r),c=t[1],f=1;if(c&&typeof c=="object"&&c.nodeType==null&&!Array.isArray(c)){f=2;for(let h in c)if(c[h]!=null){let g=h.indexOf(" ");g>0?u.setAttributeNS(h.slice(0,g),h.slice(g+1),c[h]):h=="style"&&u.style?u.style.cssText=c[h]:u.setAttribute(h,c[h])}}for(let h=f;h<t.length;h++){let g=t[h];if(g===0){if(h<t.length-1||h>f)throw new RangeError("Content hole must be the only child of its parent node");return{dom:u,contentDOM:u}}else{let{dom:p,contentDOM:y}=uc(e,g,n,i);if(u.appendChild(p),y){if(s)throw new RangeError("Multiple content holes");s=y}}}return{dom:u,contentDOM:s}}const n3=65535,i3=Math.pow(2,16);function BCe(e,t){return e+t*i3}function r3(e){return e&n3}function VCe(e){return(e-(e&n3))/i3}const a3=1,o3=2,dc=4,s3=8;class tp{constructor(t,n,i){this.pos=t,this.delInfo=n,this.recover=i}get deleted(){return(this.delInfo&s3)>0}get deletedBefore(){return(this.delInfo&(a3|dc))>0}get deletedAfter(){return(this.delInfo&(o3|dc))>0}get deletedAcross(){return(this.delInfo&dc)>0}}class On{constructor(t,n=!1){if(this.ranges=t,this.inverted=n,!t.length&&On.empty)return On.empty}recover(t){let n=0,i=r3(t);if(!this.inverted)for(let r=0;r<i;r++)n+=this.ranges[r*3+2]-this.ranges[r*3+1];return this.ranges[i*3]+n+VCe(t)}mapResult(t,n=1){return this._map(t,n,!1)}map(t,n=1){return this._map(t,n,!0)}_map(t,n,i){let r=0,a=this.inverted?2:1,o=this.inverted?1:2;for(let s=0;s<this.ranges.length;s+=3){let u=this.ranges[s]-(this.inverted?r:0);if(u>t)break;let c=this.ranges[s+a],f=this.ranges[s+o],h=u+c;if(t<=h){let g=c?t==u?-1:t==h?1:n:n,p=u+r+(g<0?0:f);if(i)return p;let y=t==(n<0?u:h)?null:BCe(s/3,t-u),v=t==u?o3:t==h?a3:dc;return(n<0?t!=u:t!=h)&&(v|=s3),new tp(p,v,y)}r+=f-c}return i?t+r:new tp(t+r,0,null)}touches(t,n){let i=0,r=r3(n),a=this.inverted?2:1,o=this.inverted?1:2;for(let s=0;s<this.ranges.length;s+=3){let u=this.ranges[s]-(this.inverted?i:0);if(u>t)break;let c=this.ranges[s+a],f=u+c;if(t<=f&&s==r*3)return!0;i+=this.ranges[s+o]-c}return!1}forEach(t){let n=this.inverted?2:1,i=this.inverted?1:2;for(let r=0,a=0;r<this.ranges.length;r+=3){let o=this.ranges[r],s=o-(this.inverted?a:0),u=o+(this.inverted?0:a),c=this.ranges[r+n],f=this.ranges[r+i];t(s,s+c,u,u+f),a+=f-c}}invert(){return new On(this.ranges,!this.inverted)}toString(){return(this.inverted?"-":"")+JSON.stringify(this.ranges)}static offset(t){return t==0?On.empty:new On(t<0?[0,-t,0]:[0,0,t])}}On.empty=new On([]);class El{constructor(t,n,i=0,r=t?t.length:0){this.mirror=n,this.from=i,this.to=r,this._maps=t||[],this.ownData=!(t||n)}get maps(){return this._maps}slice(t=0,n=this.maps.length){return new El(this._maps,this.mirror,t,n)}appendMap(t,n){this.ownData||(this._maps=this._maps.slice(),this.mirror=this.mirror&&this.mirror.slice(),this.ownData=!0),this.to=this._maps.push(t),n!=null&&this.setMirror(this._maps.length-1,n)}appendMapping(t){for(let n=0,i=this._maps.length;n<t._maps.length;n++){let r=t.getMirror(n);this.appendMap(t._maps[n],r!=null&&r<n?i+r:void 0)}}getMirror(t){if(this.mirror){for(let n=0;n<this.mirror.length;n++)if(this.mirror[n]==t)return this.mirror[n+(n%2?-1:1)]}}setMirror(t,n){this.mirror||(this.mirror=[]),this.mirror.push(t,n)}appendMappingInverted(t){for(let n=t.maps.length-1,i=this._maps.length+t._maps.length;n>=0;n--){let r=t.getMirror(n);this.appendMap(t._maps[n].invert(),r!=null&&r>n?i-r-1:void 0)}}invert(){let t=new El;return t.appendMappingInverted(this),t}map(t,n=1){if(this.mirror)return this._map(t,n,!0);for(let i=this.from;i<this.to;i++)t=this._maps[i].map(t,n);return t}mapResult(t,n=1){return this._map(t,n,!1)}_map(t,n,i){let r=0;for(let a=this.from;a<this.to;a++){let o=this._maps[a],s=o.mapResult(t,n);if(s.recover!=null){let u=this.getMirror(a);if(u!=null&&u>a&&u<this.to){a=u,t=this._maps[u].recover(s.recover);continue}}r|=s.delInfo,t=s.pos}return i?t:new tp(t,r,null)}}const np=Object.create(null);class qt{getMap(){return On.empty}merge(t){return null}static fromJSON(t,n){if(!n||!n.stepType)throw new RangeError("Invalid input for Step.fromJSON");let i=np[n.stepType];if(!i)throw new RangeError(`No step type ${n.stepType} defined`);return i.fromJSON(t,n)}static jsonID(t,n){if(t in np)throw new RangeError("Duplicate use of step JSON ID "+t);return np[t]=n,n.prototype.jsonID=t,n}}class kt{constructor(t,n){this.doc=t,this.failed=n}static ok(t){return new kt(t,null)}static fail(t){return new kt(null,t)}static fromReplace(t,n,i,r){try{return kt.ok(t.replace(n,i,r))}catch(a){if(a instanceof ic)return kt.fail(a.message);throw a}}}function ip(e,t,n){let i=[];for(let r=0;r<e.childCount;r++){let a=e.child(r);a.content.size&&(a=a.copy(ip(a.content,t,a))),a.isInline&&(a=t(a,n,r)),i.push(a)}return ne.fromArray(i)}class Br extends qt{constructor(t,n,i){super(),this.from=t,this.to=n,this.mark=i}apply(t){let n=t.slice(this.from,this.to),i=t.resolve(this.from),r=i.node(i.sharedDepth(this.to)),a=new le(ip(n.content,(o,s)=>!o.isAtom||!s.type.allowsMarkType(this.mark.type)?o:o.mark(this.mark.addToSet(o.marks)),r),n.openStart,n.openEnd);return kt.fromReplace(t,this.from,this.to,a)}invert(){return new xi(this.from,this.to,this.mark)}map(t){let n=t.mapResult(this.from,1),i=t.mapResult(this.to,-1);return n.deleted&&i.deleted||n.pos>=i.pos?null:new Br(n.pos,i.pos,this.mark)}merge(t){return t instanceof Br&&t.mark.eq(this.mark)&&this.from<=t.to&&this.to>=t.from?new Br(Math.min(this.from,t.from),Math.max(this.to,t.to),this.mark):null}toJSON(){return{stepType:"addMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(t,n){if(typeof n.from!="number"||typeof n.to!="number")throw new RangeError("Invalid input for AddMarkStep.fromJSON");return new Br(n.from,n.to,t.markFromJSON(n.mark))}}qt.jsonID("addMark",Br);class xi extends qt{constructor(t,n,i){super(),this.from=t,this.to=n,this.mark=i}apply(t){let n=t.slice(this.from,this.to),i=new le(ip(n.content,r=>r.mark(this.mark.removeFromSet(r.marks)),t),n.openStart,n.openEnd);return kt.fromReplace(t,this.from,this.to,i)}invert(){return new Br(this.from,this.to,this.mark)}map(t){let n=t.mapResult(this.from,1),i=t.mapResult(this.to,-1);return n.deleted&&i.deleted||n.pos>=i.pos?null:new xi(n.pos,i.pos,this.mark)}merge(t){return t instanceof xi&&t.mark.eq(this.mark)&&this.from<=t.to&&this.to>=t.from?new xi(Math.min(this.from,t.from),Math.max(this.to,t.to),this.mark):null}toJSON(){return{stepType:"removeMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(t,n){if(typeof n.from!="number"||typeof n.to!="number")throw new RangeError("Invalid input for RemoveMarkStep.fromJSON");return new xi(n.from,n.to,t.markFromJSON(n.mark))}}qt.jsonID("removeMark",xi);class Vr extends qt{constructor(t,n){super(),this.pos=t,this.mark=n}apply(t){let n=t.nodeAt(this.pos);if(!n)return kt.fail("No node at mark step's position");let i=n.type.create(n.attrs,null,this.mark.addToSet(n.marks));return kt.fromReplace(t,this.pos,this.pos+1,new le(ne.from(i),0,n.isLeaf?0:1))}invert(t){let n=t.nodeAt(this.pos);if(n){let i=this.mark.addToSet(n.marks);if(i.length==n.marks.length){for(let r=0;r<n.marks.length;r++)if(!n.marks[r].isInSet(i))return new Vr(this.pos,n.marks[r]);return new Vr(this.pos,this.mark)}}return new Xa(this.pos,this.mark)}map(t){let n=t.mapResult(this.pos,1);return n.deletedAfter?null:new Vr(n.pos,this.mark)}toJSON(){return{stepType:"addNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(t,n){if(typeof n.pos!="number")throw new RangeError("Invalid input for AddNodeMarkStep.fromJSON");return new Vr(n.pos,t.markFromJSON(n.mark))}}qt.jsonID("addNodeMark",Vr);class Xa extends qt{constructor(t,n){super(),this.pos=t,this.mark=n}apply(t){let n=t.nodeAt(this.pos);if(!n)return kt.fail("No node at mark step's position");let i=n.type.create(n.attrs,null,this.mark.removeFromSet(n.marks));return kt.fromReplace(t,this.pos,this.pos+1,new le(ne.from(i),0,n.isLeaf?0:1))}invert(t){let n=t.nodeAt(this.pos);return!n||!this.mark.isInSet(n.marks)?this:new Vr(this.pos,this.mark)}map(t){let n=t.mapResult(this.pos,1);return n.deletedAfter?null:new Xa(n.pos,this.mark)}toJSON(){return{stepType:"removeNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(t,n){if(typeof n.pos!="number")throw new RangeError("Invalid input for RemoveNodeMarkStep.fromJSON");return new Xa(n.pos,t.markFromJSON(n.mark))}}qt.jsonID("removeNodeMark",Xa);class jt extends qt{constructor(t,n,i,r=!1){super(),this.from=t,this.to=n,this.slice=i,this.structure=r}apply(t){return this.structure&&rp(t,this.from,this.to)?kt.fail("Structure replace would overwrite content"):kt.fromReplace(t,this.from,this.to,this.slice)}getMap(){return new On([this.from,this.to-this.from,this.slice.size])}invert(t){return new jt(this.from,this.from+this.slice.size,t.slice(this.from,this.to))}map(t){let n=t.mapResult(this.from,1),i=t.mapResult(this.to,-1);return n.deletedAcross&&i.deletedAcross?null:new jt(n.pos,Math.max(n.pos,i.pos),this.slice,this.structure)}merge(t){if(!(t instanceof jt)||t.structure||this.structure)return null;if(this.from+this.slice.size==t.from&&!this.slice.openEnd&&!t.slice.openStart){let n=this.slice.size+t.slice.size==0?le.empty:new le(this.slice.content.append(t.slice.content),this.slice.openStart,t.slice.openEnd);return new jt(this.from,this.to+(t.to-t.from),n,this.structure)}else if(t.to==this.from&&!this.slice.openStart&&!t.slice.openEnd){let n=this.slice.size+t.slice.size==0?le.empty:new le(t.slice.content.append(this.slice.content),t.slice.openStart,this.slice.openEnd);return new jt(t.from,this.to,n,this.structure)}else return null}toJSON(){let t={stepType:"replace",from:this.from,to:this.to};return this.slice.size&&(t.slice=this.slice.toJSON()),this.structure&&(t.structure=!0),t}static fromJSON(t,n){if(typeof n.from!="number"||typeof n.to!="number")throw new RangeError("Invalid input for ReplaceStep.fromJSON");return new jt(n.from,n.to,le.fromJSON(t,n.slice),!!n.structure)}}qt.jsonID("replace",jt);class It extends qt{constructor(t,n,i,r,a,o,s=!1){super(),this.from=t,this.to=n,this.gapFrom=i,this.gapTo=r,this.slice=a,this.insert=o,this.structure=s}apply(t){if(this.structure&&(rp(t,this.from,this.gapFrom)||rp(t,this.gapTo,this.to)))return kt.fail("Structure gap-replace would overwrite content");let n=t.slice(this.gapFrom,this.gapTo);if(n.openStart||n.openEnd)return kt.fail("Gap is not a flat range");let i=this.slice.insertAt(this.insert,n.content);return i?kt.fromReplace(t,this.from,this.to,i):kt.fail("Content does not fit in gap")}getMap(){return new On([this.from,this.gapFrom-this.from,this.insert,this.gapTo,this.to-this.gapTo,this.slice.size-this.insert])}invert(t){let n=this.gapTo-this.gapFrom;return new It(this.from,this.from+this.slice.size+n,this.from+this.insert,this.from+this.insert+n,t.slice(this.from,this.to).removeBetween(this.gapFrom-this.from,this.gapTo-this.from),this.gapFrom-this.from,this.structure)}map(t){let n=t.mapResult(this.from,1),i=t.mapResult(this.to,-1),r=this.from==this.gapFrom?n.pos:t.map(this.gapFrom,-1),a=this.to==this.gapTo?i.pos:t.map(this.gapTo,1);return n.deletedAcross&&i.deletedAcross||r<n.pos||a>i.pos?null:new It(n.pos,i.pos,r,a,this.slice,this.insert,this.structure)}toJSON(){let t={stepType:"replaceAround",from:this.from,to:this.to,gapFrom:this.gapFrom,gapTo:this.gapTo,insert:this.insert};return this.slice.size&&(t.slice=this.slice.toJSON()),this.structure&&(t.structure=!0),t}static fromJSON(t,n){if(typeof n.from!="number"||typeof n.to!="number"||typeof n.gapFrom!="number"||typeof n.gapTo!="number"||typeof n.insert!="number")throw new RangeError("Invalid input for ReplaceAroundStep.fromJSON");return new It(n.from,n.to,n.gapFrom,n.gapTo,le.fromJSON(t,n.slice),n.insert,!!n.structure)}}qt.jsonID("replaceAround",It);function rp(e,t,n){let i=e.resolve(t),r=n-t,a=i.depth;for(;r>0&&a>0&&i.indexAfter(a)==i.node(a).childCount;)a--,r--;if(r>0){let o=i.node(a).maybeChild(i.indexAfter(a));for(;r>0;){if(!o||o.isLeaf)return!0;o=o.firstChild,r--}}return!1}function FCe(e,t,n,i){let r=[],a=[],o,s;e.doc.nodesBetween(t,n,(u,c,f)=>{if(!u.isInline)return;let h=u.marks;if(!i.isInSet(h)&&f.type.allowsMarkType(i.type)){let g=Math.max(c,t),p=Math.min(c+u.nodeSize,n),y=i.addToSet(h);for(let v=0;v<h.length;v++)h[v].isInSet(y)||(o&&o.to==g&&o.mark.eq(h[v])?o.to=p:r.push(o=new xi(g,p,h[v])));s&&s.to==g?s.to=p:a.push(s=new Br(g,p,i))}}),r.forEach(u=>e.step(u)),a.forEach(u=>e.step(u))}function UCe(e,t,n,i){let r=[],a=0;e.doc.nodesBetween(t,n,(o,s)=>{if(!o.isInline)return;a++;let u=null;if(i instanceof sc){let c=o.marks,f;for(;f=i.isInSet(c);)(u||(u=[])).push(f),c=f.removeFromSet(c)}else i?i.isInSet(o.marks)&&(u=[i]):u=o.marks;if(u&&u.length){let c=Math.min(s+o.nodeSize,n);for(let f=0;f<u.length;f++){let h=u[f],g;for(let p=0;p<r.length;p++){let y=r[p];y.step==a-1&&h.eq(r[p].style)&&(g=y)}g?(g.to=c,g.step=a):r.push({style:h,from:Math.max(s,t),to:c,step:a})}}}),r.forEach(o=>e.step(new xi(o.from,o.to,o.style)))}function ap(e,t,n,i=n.contentMatch,r=!0){let a=e.doc.nodeAt(t),o=[],s=t+1;for(let u=0;u<a.childCount;u++){let c=a.child(u),f=s+c.nodeSize,h=i.matchType(c.type);if(!h)o.push(new jt(s,f,le.empty));else{i=h;for(let g=0;g<c.marks.length;g++)n.allowsMarkType(c.marks[g].type)||e.step(new xi(s,f,c.marks[g]));if(r&&c.isText&&n.whitespace!="pre"){let g,p=/\r?\n|\r/g,y;for(;g=p.exec(c.text);)y||(y=new le(ne.from(n.schema.text(" ",n.allowedMarks(c.marks))),0,0)),o.push(new jt(s+g.index,s+g.index+g[0].length,y))}}s=f}if(!i.validEnd){let u=i.fillBefore(ne.empty,!0);e.replace(s,s,new le(u,0,0))}for(let u=o.length-1;u>=0;u--)e.step(o[u])}function YCe(e,t,n){return(t==0||e.canReplace(t,e.childCount))&&(n==e.childCount||e.canReplace(0,n))}function Ko(e){let n=e.parent.content.cutByIndex(e.startIndex,e.endIndex);for(let i=e.depth;;--i){let r=e.$from.node(i),a=e.$from.index(i),o=e.$to.indexAfter(i);if(i<e.depth&&r.canReplace(a,o,n))return i;if(i==0||r.type.spec.isolating||!YCe(r,a,o))break}return null}function XCe(e,t,n){let{$from:i,$to:r,depth:a}=t,o=i.before(a+1),s=r.after(a+1),u=o,c=s,f=ne.empty,h=0;for(let y=a,v=!1;y>n;y--)v||i.index(y)>0?(v=!0,f=ne.from(i.node(y).copy(f)),h++):u--;let g=ne.empty,p=0;for(let y=a,v=!1;y>n;y--)v||r.after(y+1)<r.end(y)?(v=!0,g=ne.from(r.node(y).copy(g)),p++):c++;e.step(new It(u,c,o,s,new le(f.append(g),h,p),f.size-h,!0))}function op(e,t,n=null,i=e){let r=qCe(e,t),a=r&&GCe(i,t);return a?r.map(l3).concat({type:t,attrs:n}).concat(a.map(l3)):null}function l3(e){return{type:e,attrs:null}}function qCe(e,t){let{parent:n,startIndex:i,endIndex:r}=e,a=n.contentMatchAt(i).findWrapping(t);if(!a)return null;let o=a.length?a[0]:t;return n.canReplaceWith(i,r,o)?a:null}function GCe(e,t){let{parent:n,startIndex:i,endIndex:r}=e,a=n.child(i),o=t.contentMatch.findWrapping(a.type);if(!o)return null;let u=(o.length?o[o.length-1]:t).contentMatch;for(let c=i;u&&c<r;c++)u=u.matchType(n.child(c).type);return!u||!u.validEnd?null:o}function KCe(e,t,n){let i=ne.empty;for(let o=n.length-1;o>=0;o--){if(i.size){let s=n[o].type.contentMatch.matchFragment(i);if(!s||!s.validEnd)throw new RangeError("Wrapper type given to Transform.wrap does not form valid content of its parent wrapper")}i=ne.from(n[o].type.create(n[o].attrs,i))}let r=t.start,a=t.end;e.step(new It(r,a,r,a,new le(i,0,0),n.length,!0))}function QCe(e,t,n,i,r){if(!i.isTextblock)throw new RangeError("Type given to setBlockType should be a textblock");let a=e.steps.length;e.doc.nodesBetween(t,n,(o,s)=>{let u=typeof r=="function"?r(o):r;if(o.isTextblock&&!o.hasMarkup(i,u)&&JCe(e.doc,e.mapping.slice(a).map(s),i)){let c=null;if(i.schema.linebreakReplacement){let p=i.whitespace=="pre",y=!!i.contentMatch.matchType(i.schema.linebreakReplacement);p&&!y?c=!1:!p&&y&&(c=!0)}c===!1&&d3(e,o,s,a),ap(e,e.mapping.slice(a).map(s,1),i,void 0,c===null);let f=e.mapping.slice(a),h=f.map(s,1),g=f.map(s+o.nodeSize,1);return e.step(new It(h,g,h+1,g-1,new le(ne.from(i.create(u,null,o.marks)),0,0),1,!0)),c===!0&&u3(e,o,s,a),!1}})}function u3(e,t,n,i){t.forEach((r,a)=>{if(r.isText){let o,s=/\r?\n|\r/g;for(;o=s.exec(r.text);){let u=e.mapping.slice(i).map(n+1+a+o.index);e.replaceWith(u,u+1,t.type.schema.linebreakReplacement.create())}}})}function d3(e,t,n,i){t.forEach((r,a)=>{if(r.type==r.type.schema.linebreakReplacement){let o=e.mapping.slice(i).map(n+1+a);e.replaceWith(o,o+1,t.type.schema.text(`
|