@inkeep/cxkit-js 0.5.99 → 0.5.100
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/embed.js +2 -2
- package/package.json +3 -3
package/dist/embed.js
CHANGED
|
@@ -35,7 +35,7 @@ var Inkeep=function(e){"use strict";var t,n,r,a,o=Object.defineProperty,i=(e,t,n
|
|
|
35
35
|
*
|
|
36
36
|
* This source code is licensed under the MIT license found in the
|
|
37
37
|
* LICENSE file in the root directory of this source tree.
|
|
38
|
-
*/function UT(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var $T=Symbol.for("react.transitional.element"),GT=Symbol.for("react.portal"),VT=Symbol.for("react.fragment"),qT=Symbol.for("react.strict_mode"),WT=Symbol.for("react.profiler"),YT=Symbol.for("react.provider"),KT=Symbol.for("react.consumer"),XT=Symbol.for("react.context"),QT=Symbol.for("react.forward_ref"),ZT=Symbol.for("react.suspense"),JT=Symbol.for("react.suspense_list"),eC=Symbol.for("react.memo"),tC=Symbol.for("react.lazy"),nC=Symbol.for("react.scope"),rC=Symbol.for("react.debug_trace_mode"),aC=Symbol.for("react.offscreen"),oC=Symbol.for("react.legacy_hidden"),iC=Symbol.for("react.memo_cache_sentinel"),sC=Symbol.iterator,lC=Array.isArray;function cC(e,t){var n=3&e.length,r=e.length-n,a=t;for(t=0;t<r;){var o=255&e.charCodeAt(t)|(255&e.charCodeAt(++t))<<8|(255&e.charCodeAt(++t))<<16|(255&e.charCodeAt(++t))<<24;++t,a=27492+(65535&(a=5*(65535&(a=(a^=o=461845907*(65535&(o=(o=3432918353*(65535&o)+((3432918353*(o>>>16)&65535)<<16)&4294967295)<<15|o>>>17))+((461845907*(o>>>16)&65535)<<16)&4294967295)<<13|a>>>19))+((5*(a>>>16)&65535)<<16)&4294967295))+((58964+(a>>>16)&65535)<<16)}switch(o=0,n){case 3:o^=(255&e.charCodeAt(t+2))<<16;case 2:o^=(255&e.charCodeAt(t+1))<<8;case 1:a^=461845907*(65535&(o=(o=3432918353*(65535&(o^=255&e.charCodeAt(t)))+((3432918353*(o>>>16)&65535)<<16)&4294967295)<<15|o>>>17))+((461845907*(o>>>16)&65535)<<16)&4294967295}return a^=e.length,a=2246822507*(65535&(a^=a>>>16))+((2246822507*(a>>>16)&65535)<<16)&4294967295,((a=3266489909*(65535&(a^=a>>>13))+((3266489909*(a>>>16)&65535)<<16)&4294967295)^a>>>16)>>>0}var uC=new MessageChannel,dC=[];function pC(e){dC.push(e),uC.port2.postMessage(null)}function hC(e){setTimeout((function(){throw e}))}uC.port1.onmessage=function(){var e=dC.shift();e&&e()};var fC=Promise,mC="function"==typeof queueMicrotask?queueMicrotask:function(e){fC.resolve(null).then(e).catch(hC)},gC=null,yC=0;function bC(e,t){if(0!==t.byteLength)if(2048<t.byteLength)0<yC&&(e.enqueue(new Uint8Array(gC.buffer,0,yC)),gC=new Uint8Array(2048),yC=0),e.enqueue(t);else{var n=gC.length-yC;n<t.byteLength&&(0===n?e.enqueue(gC):(gC.set(t.subarray(0,n),yC),e.enqueue(gC),t=t.subarray(n)),gC=new Uint8Array(2048),yC=0),gC.set(t,yC),yC+=t.byteLength}}function vC(e,t){return bC(e,t),!0}function kC(e){gC&&0<yC&&(e.enqueue(new Uint8Array(gC.buffer,0,yC)),gC=null,yC=0)}var wC=new TextEncoder;function xC(e){return wC.encode(e)}function EC(e){return wC.encode(e)}function _C(e,t){"function"==typeof e.error?e.error(t):e.close()}var SC=Object.assign,TC=Object.prototype.hasOwnProperty,CC=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),AC={},NC={};function IC(e){return!!TC.call(NC,e)||!TC.call(AC,e)&&(CC.test(e)?NC[e]=!0:(AC[e]=!0,!1))}var RC=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" ")),OC=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),PC=/["'&<>]/;function DC(e){if("boolean"==typeof e||"number"==typeof e||"bigint"==typeof e)return""+e;e=""+e;var t=PC.exec(e);if(t){var n,r="",a=0;for(n=t.index;n<e.length;n++){switch(e.charCodeAt(n)){case 34:t=""";break;case 38:t="&";break;case 39:t="'";break;case 60:t="<";break;case 62:t=">";break;default:continue}a!==n&&(r+=e.slice(a,n)),a=n+1,r+=t}e=a!==n?r+e.slice(a,n):r}return e}var LC=/([A-Z])/g,MC=/^ms-/,FC=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function jC(e){return FC.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}var BC=zT.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,zC=HT.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,HC={pending:!1,data:null,method:null,action:null},UC=zC.d;zC.d={f:UC.f,r:UC.r,D:function(e){var t=GR||null;if(t){var n=t.resumableState,r=t.renderState;if("string"==typeof e&&e){var a,o;if(!n.dnsResources.hasOwnProperty(e))n.dnsResources[e]=null,(o=(n=r.headers)&&0<n.remainingCapacity)&&(a="<"+(""+e).replace(SI,TI)+">; rel=dns-prefetch",o=0<=(n.remainingCapacity-=a.length+2)),o?(r.resets.dns[e]=null,n.preconnects&&(n.preconnects+=", "),n.preconnects+=a):(LA(a=[],{href:e,rel:"dns-prefetch"}),r.preconnects.add(a));CO(t)}}else UC.D(e)},C:function(e,t){var n=GR||null;if(n){var r=n.resumableState,a=n.renderState;if("string"==typeof e&&e){var o="use-credentials"===t?"credentials":"string"==typeof t?"anonymous":"default";if(!r.connectResources[o].hasOwnProperty(e)){var i,s;if(r.connectResources[o][e]=null,s=(r=a.headers)&&0<r.remainingCapacity){if(s="<"+(""+e).replace(SI,TI)+">; rel=preconnect","string"==typeof t)s+='; crossorigin="'+(""+t).replace(CI,AI)+'"';i=s,s=0<=(r.remainingCapacity-=i.length+2)}s?(a.resets.connect[o][e]=null,r.preconnects&&(r.preconnects+=", "),r.preconnects+=i):(LA(o=[],{rel:"preconnect",href:e,crossOrigin:t}),a.preconnects.add(o))}CO(n)}}else UC.C(e,t)},L:function(e,t,n){var r=GR||null;if(r){var a=r.resumableState,o=r.renderState;if(t&&e){switch(t){case"image":if(n)var i=n.imageSrcSet,s=n.imageSizes,l=n.fetchPriority;var c,u=i?i+"\n"+(s||""):e;if(a.imageResources.hasOwnProperty(u))return;a.imageResources[u]=$C,(a=o.headers)&&0<a.remainingCapacity&&"high"===l&&(c=_I(e,t,n),0<=(a.remainingCapacity-=c.length+2))?(o.resets.image[u]=$C,a.highImagePreloads&&(a.highImagePreloads+=", "),a.highImagePreloads+=c):(LA(a=[],SC({rel:"preload",href:i?void 0:e,as:t},n)),"high"===l?o.highImagePreloads.add(a):(o.bulkPreloads.add(a),o.preloads.images.set(u,a)));break;case"style":if(a.styleResources.hasOwnProperty(e))return;LA(i=[],SC({rel:"preload",href:e,as:t},n)),a.styleResources[e]=!n||"string"!=typeof n.crossOrigin&&"string"!=typeof n.integrity?$C:[n.crossOrigin,n.integrity],o.preloads.stylesheets.set(e,i),o.bulkPreloads.add(i);break;case"script":if(a.scriptResources.hasOwnProperty(e))return;i=[],o.preloads.scripts.set(e,i),o.bulkPreloads.add(i),LA(i,SC({rel:"preload",href:e,as:t},n)),a.scriptResources[e]=!n||"string"!=typeof n.crossOrigin&&"string"!=typeof n.integrity?$C:[n.crossOrigin,n.integrity];break;default:if(a.unknownResources.hasOwnProperty(t)){if((i=a.unknownResources[t]).hasOwnProperty(e))return}else i={},a.unknownResources[t]=i;if(i[e]=$C,(a=o.headers)&&0<a.remainingCapacity&&"font"===t&&(u=_I(e,t,n),0<=(a.remainingCapacity-=u.length+2)))o.resets.font[e]=$C,a.fontPreloads&&(a.fontPreloads+=", "),a.fontPreloads+=u;else if("font"===(LA(a=[],e=SC({rel:"preload",href:e,as:t},n)),t))o.fontPreloads.add(a);else o.bulkPreloads.add(a)}CO(r)}}else UC.L(e,t,n)},m:function(e,t){var n=GR||null;if(n){var r=n.resumableState,a=n.renderState;if(e){var o=t&&"string"==typeof t.as?t.as:"script";if("script"===o){if(r.moduleScriptResources.hasOwnProperty(e))return;o=[],r.moduleScriptResources[e]=!t||"string"!=typeof t.crossOrigin&&"string"!=typeof t.integrity?$C:[t.crossOrigin,t.integrity],a.preloads.moduleScripts.set(e,o)}else{if(r.moduleUnknownResources.hasOwnProperty(o)){var i=r.unknownResources[o];if(i.hasOwnProperty(e))return}else i={},r.moduleUnknownResources[o]=i;o=[],i[e]=$C}LA(o,SC({rel:"modulepreload",href:e},t)),a.bulkPreloads.add(o),CO(n)}}else UC.m(e,t)},X:function(e,t){var n=GR||null;if(n){var r=n.resumableState,a=n.renderState;if(e){var o=r.scriptResources.hasOwnProperty(e)?r.scriptResources[e]:void 0;null!==o&&(r.scriptResources[e]=null,t=SC({src:e,async:!0},t),o&&(2===o.length&&EI(t,o),e=a.preloads.scripts.get(e))&&(e.length=0),e=[],a.scripts.add(e),zA(e,t),CO(n))}}else UC.X(e,t)},S:function(e,t,n){var r=GR||null;if(r){var a=r.resumableState,o=r.renderState;if(e){t=t||"default";var i=o.styles.get(t),s=a.styleResources.hasOwnProperty(e)?a.styleResources[e]:void 0;null!==s&&(a.styleResources[e]=null,i||(i={precedence:xC(DC(t)),rules:[],hrefs:[],sheets:new Map},o.styles.set(t,i)),t={state:0,props:SC({rel:"stylesheet",href:e,"data-precedence":t},n)},s&&(2===s.length&&EI(t.props,s),(o=o.preloads.stylesheets.get(e))&&0<o.length?o.length=0:t.state=1),i.sheets.set(e,t),CO(r))}}else UC.S(e,t,n)},M:function(e,t){var n=GR||null;if(n){var r=n.resumableState,a=n.renderState;if(e){var o=r.moduleScriptResources.hasOwnProperty(e)?r.moduleScriptResources[e]:void 0;null!==o&&(r.moduleScriptResources[e]=null,t=SC({src:e,type:"module",async:!0},t),o&&(2===o.length&&EI(t,o),e=a.preloads.moduleScripts.get(e))&&(e.length=0),e=[],a.scripts.add(e),zA(e,t),CO(n))}}else UC.M(e,t)}};var $C=[];EC('"></template>');var GC=EC("<script>"),VC=EC("<\/script>"),qC=EC('<script src="'),WC=EC('<script type="module" src="'),YC=EC('" nonce="'),KC=EC('" integrity="'),XC=EC('" crossorigin="'),QC=EC('" async=""><\/script>'),ZC=/(<\/|<)(s)(cript)/gi;function JC(e,t,n,r){return t+("s"===n?"\\u0073":"\\u0053")+r}var eA=EC('<script type="importmap">'),tA=EC("<\/script>");function nA(e,t,n,r,a,o){var i=void 0===t?GC:EC('<script nonce="'+DC(t)+'">'),s=e.idPrefix;n=[];var l=e.bootstrapScriptContent,c=e.bootstrapScripts,u=e.bootstrapModules;if(void 0!==l&&n.push(i,xC((""+l).replace(ZC,JC)),VC),l=[],void 0!==r&&(l.push(eA),l.push(xC((""+JSON.stringify(r)).replace(ZC,JC))),l.push(tA)),r=a?{preconnects:"",fontPreloads:"",highImagePreloads:"",remainingCapacity:2+("number"==typeof o?o:2e3)}:null,a={placeholderPrefix:EC(s+"P:"),segmentPrefix:EC(s+"S:"),boundaryPrefix:EC(s+"B:"),startInlineScript:i,htmlChunks:null,headChunks:null,externalRuntimeScript:null,bootstrapChunks:n,importMapChunks:l,onHeaders:a,headers:r,resets:{font:{},dns:{},connect:{default:{},anonymous:{},credentials:{}},image:{},style:{}},charsetChunks:[],viewportChunks:[],hoistableChunks:[],preconnects:new Set,fontPreloads:new Set,highImagePreloads:new Set,styles:new Map,bootstrapScripts:new Set,scripts:new Set,bulkPreloads:new Set,preloads:{images:new Map,stylesheets:new Map,scripts:new Map,moduleScripts:new Map},nonce:t,hoistableState:null,stylesToHoist:!1},void 0!==c)for(r=0;r<c.length;r++){var d=c[r];s=i=void 0,l={rel:"preload",as:"script",fetchPriority:"low",nonce:t},"string"==typeof d?l.href=o=d:(l.href=o=d.src,l.integrity=s="string"==typeof d.integrity?d.integrity:void 0,l.crossOrigin=i="string"==typeof d||null==d.crossOrigin?void 0:"use-credentials"===d.crossOrigin?"use-credentials":"");var p=o;(d=e).scriptResources[p]=null,d.moduleScriptResources[p]=null,LA(d=[],l),a.bootstrapScripts.add(d),n.push(qC,xC(DC(o))),t&&n.push(YC,xC(DC(t))),"string"==typeof s&&n.push(KC,xC(DC(s))),"string"==typeof i&&n.push(XC,xC(DC(i))),n.push(QC)}if(void 0!==u)for(c=0;c<u.length;c++)i=o=void 0,s={rel:"modulepreload",fetchPriority:"low",nonce:t},"string"==typeof(l=u[c])?s.href=r=l:(s.href=r=l.src,s.integrity=i="string"==typeof l.integrity?l.integrity:void 0,s.crossOrigin=o="string"==typeof l||null==l.crossOrigin?void 0:"use-credentials"===l.crossOrigin?"use-credentials":""),d=r,(l=e).scriptResources[d]=null,l.moduleScriptResources[d]=null,LA(l=[],s),a.bootstrapScripts.add(l),n.push(WC,xC(DC(r))),t&&n.push(YC,xC(DC(t))),"string"==typeof i&&n.push(KC,xC(DC(i))),"string"==typeof o&&n.push(XC,xC(DC(o))),n.push(QC);return a}function rA(e,t,n,r,a){return{idPrefix:void 0===e?"":e,nextFormID:0,streamingFormat:0,bootstrapScriptContent:n,bootstrapScripts:r,bootstrapModules:a,instructions:0,hasBody:!1,hasHtml:!1,unknownResources:{},dnsResources:{},connectResources:{default:{},anonymous:{},credentials:{}},imageResources:{},styleResources:{},scriptResources:{},moduleUnknownResources:{},moduleScriptResources:{}}}function aA(e,t,n){return{insertionMode:e,selectedValue:t,tagScope:n}}function oA(e){return aA("http://www.w3.org/2000/svg"===e?3:"http://www.w3.org/1998/Math/MathML"===e?4:0,null,0)}function iA(e,t,n){switch(t){case"noscript":return aA(2,null,1|e.tagScope);case"select":return aA(2,null!=n.value?n.value:n.defaultValue,e.tagScope);case"svg":return aA(3,null,e.tagScope);case"picture":return aA(2,null,2|e.tagScope);case"math":return aA(4,null,e.tagScope);case"foreignObject":return aA(2,null,e.tagScope);case"table":return aA(5,null,e.tagScope);case"thead":case"tbody":case"tfoot":return aA(6,null,e.tagScope);case"colgroup":return aA(8,null,e.tagScope);case"tr":return aA(7,null,e.tagScope)}return 5<=e.insertionMode?aA(2,null,e.tagScope):0===e.insertionMode?aA("html"===t?1:2,null,e.tagScope):1===e.insertionMode?aA(2,null,e.tagScope):e}var sA=EC("\x3c!-- --\x3e");function lA(e,t,n,r){return""===t?r:(r&&e.push(sA),e.push(xC(DC(t))),!0)}var cA=new Map,uA=EC(' style="'),dA=EC(":"),pA=EC(";");function hA(e,t){if("object"!=typeof t)throw Error(UT(62));var n,r=!0;for(n in t)if(TC.call(t,n)){var a=t[n];if(null!=a&&"boolean"!=typeof a&&""!==a){if(0===n.indexOf("--")){var o=xC(DC(n));a=xC(DC((""+a).trim()))}else void 0===(o=cA.get(n))&&(o=EC(DC(n.replace(LC,"-$1").toLowerCase().replace(MC,"-ms-"))),cA.set(n,o)),a="number"==typeof a?0===a||RC.has(n)?xC(""+a):xC(a+"px"):xC(DC((""+a).trim()));r?(r=!1,e.push(uA,o,dA,a)):e.push(pA,o,dA,a)}}r||e.push(gA)}var fA=EC(" "),mA=EC('="'),gA=EC('"'),yA=EC('=""');function bA(e,t,n){n&&"function"!=typeof n&&"symbol"!=typeof n&&e.push(fA,xC(t),yA)}function vA(e,t,n){"function"!=typeof n&&"symbol"!=typeof n&&"boolean"!=typeof n&&e.push(fA,xC(t),mA,xC(DC(n)),gA)}var kA=EC(DC("javascript:throw new Error('React form unexpectedly submitted.')")),wA=EC('<input type="hidden"');function xA(e,t){this.push(wA),EA(e),vA(this,"name",t),vA(this,"value",e),this.push(AA)}function EA(e){if("string"!=typeof e)throw Error(UT(480))}function _A(e,t){if("function"==typeof t.$$FORM_ACTION){var n=e.nextFormID++;e=e.idPrefix+n;try{var r=t.$$FORM_ACTION(e);if(r){var a=r.data;null!=a&&a.forEach(EA)}return r}catch(o){if("object"==typeof o&&null!==o&&"function"==typeof o.then)throw o}}return null}function SA(e,t,n,r,a,o,i,s){var l=null;if("function"==typeof r){var c=_A(t,r);null!==c?(s=c.name,r=c.action||"",a=c.encType,o=c.method,i=c.target,l=c.data):(e.push(fA,xC("formAction"),mA,kA,gA),i=o=a=r=s=null,OA(t,n))}return null!=s&&TA(e,"name",s),null!=r&&TA(e,"formAction",r),null!=a&&TA(e,"formEncType",a),null!=o&&TA(e,"formMethod",o),null!=i&&TA(e,"formTarget",i),l}function TA(e,t,n){switch(t){case"className":vA(e,"class",n);break;case"tabIndex":vA(e,"tabindex",n);break;case"dir":case"role":case"viewBox":case"width":case"height":vA(e,t,n);break;case"style":hA(e,n);break;case"src":case"href":if(""===n)break;case"action":case"formAction":if(null==n||"function"==typeof n||"symbol"==typeof n||"boolean"==typeof n)break;n=jC(""+n),e.push(fA,xC(t),mA,xC(DC(n)),gA);break;case"defaultValue":case"defaultChecked":case"innerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"ref":break;case"autoFocus":case"multiple":case"muted":bA(e,t.toLowerCase(),n);break;case"xlinkHref":if("function"==typeof n||"symbol"==typeof n||"boolean"==typeof n)break;n=jC(""+n),e.push(fA,xC("xlink:href"),mA,xC(DC(n)),gA);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":"function"!=typeof n&&"symbol"!=typeof n&&e.push(fA,xC(t),mA,xC(DC(n)),gA);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":n&&"function"!=typeof n&&"symbol"!=typeof n&&e.push(fA,xC(t),yA);break;case"capture":case"download":!0===n?e.push(fA,xC(t),yA):!1!==n&&"function"!=typeof n&&"symbol"!=typeof n&&e.push(fA,xC(t),mA,xC(DC(n)),gA);break;case"cols":case"rows":case"size":case"span":"function"!=typeof n&&"symbol"!=typeof n&&!isNaN(n)&&1<=n&&e.push(fA,xC(t),mA,xC(DC(n)),gA);break;case"rowSpan":case"start":"function"==typeof n||"symbol"==typeof n||isNaN(n)||e.push(fA,xC(t),mA,xC(DC(n)),gA);break;case"xlinkActuate":vA(e,"xlink:actuate",n);break;case"xlinkArcrole":vA(e,"xlink:arcrole",n);break;case"xlinkRole":vA(e,"xlink:role",n);break;case"xlinkShow":vA(e,"xlink:show",n);break;case"xlinkTitle":vA(e,"xlink:title",n);break;case"xlinkType":vA(e,"xlink:type",n);break;case"xmlBase":vA(e,"xml:base",n);break;case"xmlLang":vA(e,"xml:lang",n);break;case"xmlSpace":vA(e,"xml:space",n);break;default:if((!(2<t.length)||"o"!==t[0]&&"O"!==t[0]||"n"!==t[1]&&"N"!==t[1])&&IC(t=OC.get(t)||t)){switch(typeof n){case"function":case"symbol":return;case"boolean":var r=t.toLowerCase().slice(0,5);if("data-"!==r&&"aria-"!==r)return}e.push(fA,xC(t),mA,xC(DC(n)),gA)}}}var CA=EC(">"),AA=EC("/>");function NA(e,t,n){if(null!=t){if(null!=n)throw Error(UT(60));if("object"!=typeof t||!("__html"in t))throw Error(UT(61));null!=(t=t.__html)&&e.push(xC(""+t))}}var IA=EC(' selected=""'),RA=EC('addEventListener("submit",function(a){if(!a.defaultPrevented){var c=a.target,d=a.submitter,e=c.action,b=d;if(d){var f=d.getAttribute("formAction");null!=f&&(e=f,b=null)}"javascript:throw new Error(\'React form unexpectedly submitted.\')"===e&&(a.preventDefault(),b?(a=document.createElement("input"),a.name=b.name,a.value=b.value,b.parentNode.insertBefore(a,b),b=new FormData(c),a.parentNode.removeChild(a)):b=new FormData(c),a=c.ownerDocument||c,(a.$$reactFormReplay=a.$$reactFormReplay||[]).push(c,d,b))}});');function OA(e,t){!(16&e.instructions)&&(e.instructions|=16,t.bootstrapChunks.unshift(t.startInlineScript,RA,VC))}var PA=EC("\x3c!--F!--\x3e"),DA=EC("\x3c!--F--\x3e");function LA(e,t){for(var n in e.push(VA("link")),t)if(TC.call(t,n)){var r=t[n];if(null!=r)switch(n){case"children":case"dangerouslySetInnerHTML":throw Error(UT(399,"link"));default:TA(e,n,r)}}return e.push(AA),null}var MA=/(<\/|<)(s)(tyle)/gi;function FA(e,t,n,r){return t+("s"===n?"\\73 ":"\\53 ")+r}function jA(e,t,n){for(var r in e.push(VA(n)),t)if(TC.call(t,r)){var a=t[r];if(null!=a)switch(r){case"children":case"dangerouslySetInnerHTML":throw Error(UT(399,n));default:TA(e,r,a)}}return e.push(AA),null}function BA(e,t){e.push(VA("title"));var n,r=null,a=null;for(n in t)if(TC.call(t,n)){var o=t[n];if(null!=o)switch(n){case"children":r=o;break;case"dangerouslySetInnerHTML":a=o;break;default:TA(e,n,o)}}return e.push(CA),"function"!=typeof(t=Array.isArray(r)?2>r.length?r[0]:null:r)&&"symbol"!=typeof t&&null!=t&&e.push(xC(DC(""+t))),NA(e,a,r),e.push(KA("title")),null}function zA(e,t){e.push(VA("script"));var n,r=null,a=null;for(n in t)if(TC.call(t,n)){var o=t[n];if(null!=o)switch(n){case"children":r=o;break;case"dangerouslySetInnerHTML":a=o;break;default:TA(e,n,o)}}return e.push(CA),NA(e,a,r),"string"==typeof r&&e.push(xC((""+r).replace(ZC,JC))),e.push(KA("script")),null}function HA(e,t,n){e.push(VA(n));var r,a=n=null;for(r in t)if(TC.call(t,r)){var o=t[r];if(null!=o)switch(r){case"children":n=o;break;case"dangerouslySetInnerHTML":a=o;break;default:TA(e,r,o)}}return e.push(CA),NA(e,a,n),"string"==typeof n?(e.push(xC(DC(n))),null):n}var UA=EC("\n"),$A=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,GA=new Map;function VA(e){var t=GA.get(e);if(void 0===t){if(!$A.test(e))throw Error(UT(65,e));t=EC("<"+e),GA.set(e,t)}return t}var qA=EC("<!DOCTYPE html>");function WA(e,t,n,r,a,o,i,s,l){switch(t){case"div":case"span":case"svg":case"path":case"g":case"p":case"li":case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":break;case"a":e.push(VA("a"));var c,u=null,d=null;for(c in n)if(TC.call(n,c)){var p=n[c];if(null!=p)switch(c){case"children":u=p;break;case"dangerouslySetInnerHTML":d=p;break;case"href":""===p?vA(e,"href",""):TA(e,c,p);break;default:TA(e,c,p)}}if(e.push(CA),NA(e,d,u),"string"==typeof u){e.push(xC(DC(u)));var h=null}else h=u;return h;case"select":e.push(VA("select"));var f,m=null,g=null;for(f in n)if(TC.call(n,f)){var y=n[f];if(null!=y)switch(f){case"children":m=y;break;case"dangerouslySetInnerHTML":g=y;break;case"defaultValue":case"value":break;default:TA(e,f,y)}}return e.push(CA),NA(e,g,m),m;case"option":var b=i.selectedValue;e.push(VA("option"));var v,k=null,w=null,x=null,E=null;for(v in n)if(TC.call(n,v)){var _=n[v];if(null!=_)switch(v){case"children":k=_;break;case"selected":x=_;break;case"dangerouslySetInnerHTML":E=_;break;case"value":w=_;default:TA(e,v,_)}}if(null!=b){var S=null!==w?""+w:function(e){var t="";return zT.Children.forEach(e,(function(e){null!=e&&(t+=e)})),t}(k);if(lC(b)){for(var T=0;T<b.length;T++)if(""+b[T]===S){e.push(IA);break}}else""+b===S&&e.push(IA)}else x&&e.push(IA);return e.push(CA),NA(e,E,k),k;case"textarea":e.push(VA("textarea"));var C,A=null,N=null,I=null;for(C in n)if(TC.call(n,C)){var R=n[C];if(null!=R)switch(C){case"children":I=R;break;case"value":A=R;break;case"defaultValue":N=R;break;case"dangerouslySetInnerHTML":throw Error(UT(91));default:TA(e,C,R)}}if(null===A&&null!==N&&(A=N),e.push(CA),null!=I){if(null!=A)throw Error(UT(92));if(lC(I)){if(1<I.length)throw Error(UT(93));A=""+I[0]}A=""+I}return"string"==typeof A&&"\n"===A[0]&&e.push(UA),null!==A&&e.push(xC(DC(""+A))),null;case"input":e.push(VA("input"));var O,P=null,D=null,L=null,M=null,F=null,j=null,B=null,z=null,H=null;for(O in n)if(TC.call(n,O)){var U=n[O];if(null!=U)switch(O){case"children":case"dangerouslySetInnerHTML":throw Error(UT(399,"input"));case"name":P=U;break;case"formAction":D=U;break;case"formEncType":L=U;break;case"formMethod":M=U;break;case"formTarget":F=U;break;case"defaultChecked":H=U;break;case"defaultValue":B=U;break;case"checked":z=U;break;case"value":j=U;break;default:TA(e,O,U)}}var $=SA(e,r,a,D,L,M,F,P);return null!==z?bA(e,"checked",z):null!==H&&bA(e,"checked",H),null!==j?TA(e,"value",j):null!==B&&TA(e,"value",B),e.push(AA),null!=$&&$.forEach(xA,e),null;case"button":e.push(VA("button"));var G,V=null,q=null,W=null,Y=null,K=null,X=null,Q=null;for(G in n)if(TC.call(n,G)){var Z=n[G];if(null!=Z)switch(G){case"children":V=Z;break;case"dangerouslySetInnerHTML":q=Z;break;case"name":W=Z;break;case"formAction":Y=Z;break;case"formEncType":K=Z;break;case"formMethod":X=Z;break;case"formTarget":Q=Z;break;default:TA(e,G,Z)}}var J=SA(e,r,a,Y,K,X,Q,W);if(e.push(CA),null!=J&&J.forEach(xA,e),NA(e,q,V),"string"==typeof V){e.push(xC(DC(V)));var ee=null}else ee=V;return ee;case"form":e.push(VA("form"));var te,ne=null,re=null,ae=null,oe=null,ie=null,se=null;for(te in n)if(TC.call(n,te)){var le=n[te];if(null!=le)switch(te){case"children":ne=le;break;case"dangerouslySetInnerHTML":re=le;break;case"action":ae=le;break;case"encType":oe=le;break;case"method":ie=le;break;case"target":se=le;break;default:TA(e,te,le)}}var ce=null,ue=null;if("function"==typeof ae){var de=_A(r,ae);null!==de?(ae=de.action||"",oe=de.encType,ie=de.method,se=de.target,ce=de.data,ue=de.name):(e.push(fA,xC("action"),mA,kA,gA),se=ie=oe=ae=null,OA(r,a))}if(null!=ae&&TA(e,"action",ae),null!=oe&&TA(e,"encType",oe),null!=ie&&TA(e,"method",ie),null!=se&&TA(e,"target",se),e.push(CA),null!==ue&&(e.push(wA),vA(e,"name",ue),e.push(AA),null!=ce&&ce.forEach(xA,e)),NA(e,re,ne),"string"==typeof ne){e.push(xC(DC(ne)));var pe=null}else pe=ne;return pe;case"menuitem":for(var he in e.push(VA("menuitem")),n)if(TC.call(n,he)){var fe=n[he];if(null!=fe)switch(he){case"children":case"dangerouslySetInnerHTML":throw Error(UT(400));default:TA(e,he,fe)}}return e.push(CA),null;case"object":e.push(VA("object"));var me,ge=null,ye=null;for(me in n)if(TC.call(n,me)){var be=n[me];if(null!=be)switch(me){case"children":ge=be;break;case"dangerouslySetInnerHTML":ye=be;break;case"data":var ve=jC(""+be);if(""===ve)break;e.push(fA,xC("data"),mA,xC(DC(ve)),gA);break;default:TA(e,me,be)}}if(e.push(CA),NA(e,ye,ge),"string"==typeof ge){e.push(xC(DC(ge)));var ke=null}else ke=ge;return ke;case"title":if(3===i.insertionMode||1&i.tagScope||null!=n.itemProp)var we=BA(e,n);else l?we=null:(BA(a.hoistableChunks,n),we=void 0);return we;case"link":var xe=n.rel,Ee=n.href,_e=n.precedence;if(3===i.insertionMode||1&i.tagScope||null!=n.itemProp||"string"!=typeof xe||"string"!=typeof Ee||""===Ee){LA(e,n);var Se=null}else if("stylesheet"===n.rel)if("string"!=typeof _e||null!=n.disabled||n.onLoad||n.onError)Se=LA(e,n);else{var Te=a.styles.get(_e),Ce=r.styleResources.hasOwnProperty(Ee)?r.styleResources[Ee]:void 0;if(null!==Ce){r.styleResources[Ee]=null,Te||(Te={precedence:xC(DC(_e)),rules:[],hrefs:[],sheets:new Map},a.styles.set(_e,Te));var Ae={state:0,props:SC({},n,{"data-precedence":n.precedence,precedence:null})};if(Ce){2===Ce.length&&EI(Ae.props,Ce);var Ne=a.preloads.stylesheets.get(Ee);Ne&&0<Ne.length?Ne.length=0:Ae.state=1}Te.sheets.set(Ee,Ae),o&&o.stylesheets.add(Ae)}else if(Te){var Ie=Te.sheets.get(Ee);Ie&&o&&o.stylesheets.add(Ie)}s&&e.push(sA),Se=null}else n.onLoad||n.onError?Se=LA(e,n):(s&&e.push(sA),Se=l?null:LA(a.hoistableChunks,n));return Se;case"script":var Re=n.async;if("string"!=typeof n.src||!n.src||!Re||"function"==typeof Re||"symbol"==typeof Re||n.onLoad||n.onError||3===i.insertionMode||1&i.tagScope||null!=n.itemProp)var Oe=zA(e,n);else{var Pe=n.src;if("module"===n.type)var De=r.moduleScriptResources,Le=a.preloads.moduleScripts;else De=r.scriptResources,Le=a.preloads.scripts;var Me=De.hasOwnProperty(Pe)?De[Pe]:void 0;if(null!==Me){De[Pe]=null;var Fe=n;if(Me){2===Me.length&&EI(Fe=SC({},n),Me);var je=Le.get(Pe);je&&(je.length=0)}var Be=[];a.scripts.add(Be),zA(Be,Fe)}s&&e.push(sA),Oe=null}return Oe;case"style":var ze=n.precedence,He=n.href;if(3===i.insertionMode||1&i.tagScope||null!=n.itemProp||"string"!=typeof ze||"string"!=typeof He||""===He){e.push(VA("style"));var Ue,$e=null,Ge=null;for(Ue in n)if(TC.call(n,Ue)){var Ve=n[Ue];if(null!=Ve)switch(Ue){case"children":$e=Ve;break;case"dangerouslySetInnerHTML":Ge=Ve;break;default:TA(e,Ue,Ve)}}e.push(CA);var qe=Array.isArray($e)?2>$e.length?$e[0]:null:$e;"function"!=typeof qe&&"symbol"!=typeof qe&&null!=qe&&e.push(xC((""+qe).replace(MA,FA))),NA(e,Ge,$e),e.push(KA("style"));var We=null}else{var Ye=a.styles.get(ze);if(null!==(r.styleResources.hasOwnProperty(He)?r.styleResources[He]:void 0)){r.styleResources[He]=null,Ye?Ye.hrefs.push(xC(DC(He))):(Ye={precedence:xC(DC(ze)),rules:[],hrefs:[xC(DC(He))],sheets:new Map},a.styles.set(ze,Ye));var Ke,Xe=Ye.rules,Qe=null,Ze=null;for(Ke in n)if(TC.call(n,Ke)){var Je=n[Ke];if(null!=Je)switch(Ke){case"children":Qe=Je;break;case"dangerouslySetInnerHTML":Ze=Je}}var et=Array.isArray(Qe)?2>Qe.length?Qe[0]:null:Qe;"function"!=typeof et&&"symbol"!=typeof et&&null!=et&&Xe.push(xC((""+et).replace(MA,FA))),NA(Xe,Ze,Qe)}Ye&&o&&o.styles.add(Ye),s&&e.push(sA),We=void 0}return We;case"meta":if(3===i.insertionMode||1&i.tagScope||null!=n.itemProp)var tt=jA(e,n,"meta");else s&&e.push(sA),tt=l?null:"string"==typeof n.charSet?jA(a.charsetChunks,n,"meta"):"viewport"===n.name?jA(a.viewportChunks,n,"meta"):jA(a.hoistableChunks,n,"meta");return tt;case"listing":case"pre":e.push(VA(t));var nt,rt=null,at=null;for(nt in n)if(TC.call(n,nt)){var ot=n[nt];if(null!=ot)switch(nt){case"children":rt=ot;break;case"dangerouslySetInnerHTML":at=ot;break;default:TA(e,nt,ot)}}if(e.push(CA),null!=at){if(null!=rt)throw Error(UT(60));if("object"!=typeof at||!("__html"in at))throw Error(UT(61));var it=at.__html;null!=it&&("string"==typeof it&&0<it.length&&"\n"===it[0]?e.push(UA,xC(it)):e.push(xC(""+it)))}return"string"==typeof rt&&"\n"===rt[0]&&e.push(UA),rt;case"img":var st=n.src,lt=n.srcSet;if(!("lazy"===n.loading||!st&&!lt||"string"!=typeof st&&null!=st||"string"!=typeof lt&&null!=lt)&&"low"!==n.fetchPriority&&!1==!!(3&i.tagScope)&&("string"!=typeof st||":"!==st[4]||"d"!==st[0]&&"D"!==st[0]||"a"!==st[1]&&"A"!==st[1]||"t"!==st[2]&&"T"!==st[2]||"a"!==st[3]&&"A"!==st[3])&&("string"!=typeof lt||":"!==lt[4]||"d"!==lt[0]&&"D"!==lt[0]||"a"!==lt[1]&&"A"!==lt[1]||"t"!==lt[2]&&"T"!==lt[2]||"a"!==lt[3]&&"A"!==lt[3])){var ct="string"==typeof n.sizes?n.sizes:void 0,ut=lt?lt+"\n"+(ct||""):st,dt=a.preloads.images,pt=dt.get(ut);if(pt)("high"===n.fetchPriority||10>a.highImagePreloads.size)&&(dt.delete(ut),a.highImagePreloads.add(pt));else if(!r.imageResources.hasOwnProperty(ut)){r.imageResources[ut]=$C;var ht,ft=n.crossOrigin,mt="string"==typeof ft?"use-credentials"===ft?ft:"":void 0,gt=a.headers;gt&&0<gt.remainingCapacity&&("high"===n.fetchPriority||500>gt.highImagePreloads.length)&&(ht=_I(st,"image",{imageSrcSet:n.srcSet,imageSizes:n.sizes,crossOrigin:mt,integrity:n.integrity,nonce:n.nonce,type:n.type,fetchPriority:n.fetchPriority,referrerPolicy:n.refererPolicy}),0<=(gt.remainingCapacity-=ht.length+2))?(a.resets.image[ut]=$C,gt.highImagePreloads&&(gt.highImagePreloads+=", "),gt.highImagePreloads+=ht):(LA(pt=[],{rel:"preload",as:"image",href:lt?void 0:st,imageSrcSet:lt,imageSizes:ct,crossOrigin:mt,integrity:n.integrity,type:n.type,fetchPriority:n.fetchPriority,referrerPolicy:n.referrerPolicy}),"high"===n.fetchPriority||10>a.highImagePreloads.size?a.highImagePreloads.add(pt):(a.bulkPreloads.add(pt),dt.set(ut,pt)))}}return jA(e,n,"img");case"base":case"area":case"br":case"col":case"embed":case"hr":case"keygen":case"param":case"source":case"track":case"wbr":return jA(e,n,t);case"head":if(2>i.insertionMode&&null===a.headChunks){a.headChunks=[];var yt=HA(a.headChunks,n,"head")}else yt=HA(e,n,"head");return yt;case"html":if(0===i.insertionMode&&null===a.htmlChunks){a.htmlChunks=[qA];var bt=HA(a.htmlChunks,n,"html")}else bt=HA(e,n,"html");return bt;default:if(-1!==t.indexOf("-")){e.push(VA(t));var vt,kt=null,wt=null;for(vt in n)if(TC.call(n,vt)){var xt=n[vt];if(null!=xt){var Et=vt;switch(vt){case"children":kt=xt;break;case"dangerouslySetInnerHTML":wt=xt;break;case"style":hA(e,xt);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"ref":break;case"className":Et="class";default:if(IC(vt)&&"function"!=typeof xt&&"symbol"!=typeof xt&&!1!==xt){if(!0===xt)xt="";else if("object"==typeof xt)continue;e.push(fA,xC(Et),mA,xC(DC(xt)),gA)}}}}return e.push(CA),NA(e,wt,kt),kt}}return HA(e,n,t)}var YA=new Map;function KA(e){var t=YA.get(e);return void 0===t&&(t=EC("</"+e+">"),YA.set(e,t)),t}function XA(e,t){t=t.bootstrapChunks;for(var n=0;n<t.length-1;n++)bC(e,t[n]);return!(n<t.length)||(n=t[n],t.length=0,vC(e,n))}var QA=EC('<template id="'),ZA=EC('"></template>'),JA=EC("\x3c!--$--\x3e"),eN=EC('\x3c!--$?--\x3e<template id="'),tN=EC('"></template>'),nN=EC("\x3c!--$!--\x3e"),rN=EC("\x3c!--/$--\x3e"),aN=EC("<template"),oN=EC('"'),iN=EC(' data-dgst="');EC(' data-msg="'),EC(' data-stck="'),EC(' data-cstck="');var sN=EC("></template>");function lN(e,t,n){if(bC(e,eN),null===n)throw Error(UT(395));return bC(e,t.boundaryPrefix),bC(e,xC(n.toString(16))),vC(e,tN)}var cN=EC('<div hidden id="'),uN=EC('">'),dN=EC("</div>"),pN=EC('<svg aria-hidden="true" style="display:none" id="'),hN=EC('">'),fN=EC("</svg>"),mN=EC('<math aria-hidden="true" style="display:none" id="'),gN=EC('">'),yN=EC("</math>"),bN=EC('<table hidden id="'),vN=EC('">'),kN=EC("</table>"),wN=EC('<table hidden><tbody id="'),xN=EC('">'),EN=EC("</tbody></table>"),_N=EC('<table hidden><tr id="'),SN=EC('">'),TN=EC("</tr></table>"),CN=EC('<table hidden><colgroup id="'),AN=EC('">'),NN=EC("</colgroup></table>");var IN=EC('$RS=function(a,b){a=document.getElementById(a);b=document.getElementById(b);for(a.parentNode.removeChild(a);a.firstChild;)b.parentNode.insertBefore(a.firstChild,b);b.parentNode.removeChild(b)};$RS("'),RN=EC('$RS("'),ON=EC('","'),PN=EC('")<\/script>');EC('<template data-rsi="" data-sid="'),EC('" data-pid="');var DN=EC('$RC=function(b,c,e){c=document.getElementById(c);c.parentNode.removeChild(c);var a=document.getElementById(b);if(a){b=a.previousSibling;if(e)b.data="$!",a.setAttribute("data-dgst",e);else{e=b.parentNode;a=b.nextSibling;var f=0;do{if(a&&8===a.nodeType){var d=a.data;if("/$"===d)if(0===f)break;else f--;else"$"!==d&&"$?"!==d&&"$!"!==d||f++}d=a.nextSibling;e.removeChild(a);a=d}while(a);for(;c.firstChild;)e.insertBefore(c.firstChild,a);b.data="$"}b._reactRetry&&b._reactRetry()}};$RC("'),LN=EC('$RC("'),MN=EC('$RC=function(b,c,e){c=document.getElementById(c);c.parentNode.removeChild(c);var a=document.getElementById(b);if(a){b=a.previousSibling;if(e)b.data="$!",a.setAttribute("data-dgst",e);else{e=b.parentNode;a=b.nextSibling;var f=0;do{if(a&&8===a.nodeType){var d=a.data;if("/$"===d)if(0===f)break;else f--;else"$"!==d&&"$?"!==d&&"$!"!==d||f++}d=a.nextSibling;e.removeChild(a);a=d}while(a);for(;c.firstChild;)e.insertBefore(c.firstChild,a);b.data="$"}b._reactRetry&&b._reactRetry()}};$RM=new Map;\n$RR=function(t,u,y){function v(n){this._p=null;n()}for(var w=$RC,p=$RM,q=new Map,r=document,g,b,h=r.querySelectorAll("link[data-precedence],style[data-precedence]"),x=[],k=0;b=h[k++];)"not all"===b.getAttribute("media")?x.push(b):("LINK"===b.tagName&&p.set(b.getAttribute("href"),b),q.set(b.dataset.precedence,g=b));b=0;h=[];var l,a;for(k=!0;;){if(k){var e=y[b++];if(!e){k=!1;b=0;continue}var c=!1,m=0;var d=e[m++];if(a=p.get(d)){var f=a._p;c=!0}else{a=r.createElement("link");a.href=\nd;a.rel="stylesheet";for(a.dataset.precedence=l=e[m++];f=e[m++];)a.setAttribute(f,e[m++]);f=a._p=new Promise(function(n,z){a.onload=v.bind(a,n);a.onerror=v.bind(a,z)});p.set(d,a)}d=a.getAttribute("media");!f||d&&!matchMedia(d).matches||h.push(f);if(c)continue}else{a=x[b++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=q.get(l)||g;c===g&&(g=a);q.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=r.head,c.insertBefore(a,c.firstChild))}Promise.all(h).then(w.bind(null,\nt,u,""),w.bind(null,t,u,"Resource failed to load"))};$RR("'),FN=EC('$RM=new Map;\n$RR=function(t,u,y){function v(n){this._p=null;n()}for(var w=$RC,p=$RM,q=new Map,r=document,g,b,h=r.querySelectorAll("link[data-precedence],style[data-precedence]"),x=[],k=0;b=h[k++];)"not all"===b.getAttribute("media")?x.push(b):("LINK"===b.tagName&&p.set(b.getAttribute("href"),b),q.set(b.dataset.precedence,g=b));b=0;h=[];var l,a;for(k=!0;;){if(k){var e=y[b++];if(!e){k=!1;b=0;continue}var c=!1,m=0;var d=e[m++];if(a=p.get(d)){var f=a._p;c=!0}else{a=r.createElement("link");a.href=\nd;a.rel="stylesheet";for(a.dataset.precedence=l=e[m++];f=e[m++];)a.setAttribute(f,e[m++]);f=a._p=new Promise(function(n,z){a.onload=v.bind(a,n);a.onerror=v.bind(a,z)});p.set(d,a)}d=a.getAttribute("media");!f||d&&!matchMedia(d).matches||h.push(f);if(c)continue}else{a=x[b++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=q.get(l)||g;c===g&&(g=a);q.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=r.head,c.insertBefore(a,c.firstChild))}Promise.all(h).then(w.bind(null,\nt,u,""),w.bind(null,t,u,"Resource failed to load"))};$RR("'),jN=EC('$RR("'),BN=EC('","'),zN=EC('",'),HN=EC('"'),UN=EC(")<\/script>");EC('<template data-rci="" data-bid="'),EC('<template data-rri="" data-bid="'),EC('" data-sid="'),EC('" data-sty="');var $N=EC('$RX=function(b,c,d,e,f){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),f&&(a.cstck=f),b._reactRetry&&b._reactRetry())};;$RX("'),GN=EC('$RX("'),VN=EC('"'),qN=EC(","),WN=EC(")<\/script>");EC('<template data-rxi="" data-bid="'),EC('" data-dgst="'),EC('" data-msg="'),EC('" data-stck="'),EC('" data-cstck="');var YN=/[<\u2028\u2029]/g;var KN=/[&><\u2028\u2029]/g;function XN(e){return JSON.stringify(e).replace(KN,(function(e){switch(e){case"&":return"\\u0026";case">":return"\\u003e";case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSObjectForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}))}var QN=EC('<style media="not all" data-precedence="'),ZN=EC('" data-href="'),JN=EC('">'),eI=EC("</style>"),tI=!1,nI=!0;function rI(e){var t=e.rules,n=e.hrefs,r=0;if(n.length){for(bC(this,QN),bC(this,e.precedence),bC(this,ZN);r<n.length-1;r++)bC(this,n[r]),bC(this,dI);for(bC(this,n[r]),bC(this,JN),r=0;r<t.length;r++)bC(this,t[r]);nI=vC(this,eI),tI=!0,t.length=0,n.length=0}}function aI(e){return 2!==e.state&&(tI=!0)}function oI(e,t,n){return tI=!1,nI=!0,t.styles.forEach(rI,e),t.stylesheets.forEach(aI),tI&&(n.stylesToHoist=!0),nI}function iI(e){for(var t=0;t<e.length;t++)bC(this,e[t]);e.length=0}var sI=[];function lI(e){LA(sI,e.props);for(var t=0;t<sI.length;t++)bC(this,sI[t]);sI.length=0,e.state=2}var cI=EC('<style data-precedence="'),uI=EC('" data-href="'),dI=EC(" "),pI=EC('">'),hI=EC("</style>");function fI(e){var t=0<e.sheets.size;e.sheets.forEach(lI,this),e.sheets.clear();var n=e.rules,r=e.hrefs;if(!t||r.length){if(bC(this,cI),bC(this,e.precedence),e=0,r.length){for(bC(this,uI);e<r.length-1;e++)bC(this,r[e]),bC(this,dI);bC(this,r[e])}for(bC(this,pI),e=0;e<n.length;e++)bC(this,n[e]);bC(this,hI),n.length=0,r.length=0}}function mI(e){if(0===e.state){e.state=1;var t=e.props;for(LA(sI,{rel:"preload",as:"style",href:e.props.href,crossOrigin:t.crossOrigin,fetchPriority:t.fetchPriority,integrity:t.integrity,media:t.media,hrefLang:t.hrefLang,referrerPolicy:t.referrerPolicy}),e=0;e<sI.length;e++)bC(this,sI[e]);sI.length=0}}function gI(e){e.sheets.forEach(mI,this),e.sheets.clear()}var yI=EC("["),bI=EC(",["),vI=EC(","),kI=EC("]");function wI(e,t,n){var r=t.toLowerCase();switch(typeof n){case"function":case"symbol":return}switch(t){case"innerHTML":case"dangerouslySetInnerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"style":case"ref":return;case"className":r="class",t=""+n;break;case"hidden":if(!1===n)return;t="";break;case"src":case"href":t=""+(n=jC(n));break;default:if(2<t.length&&("o"===t[0]||"O"===t[0])&&("n"===t[1]||"N"===t[1])||!IC(t))return;t=""+n}bC(e,vI),bC(e,xC(XN(r))),bC(e,vI),bC(e,xC(XN(t)))}function xI(){return{styles:new Set,stylesheets:new Set}}function EI(e,t){null==e.crossOrigin&&(e.crossOrigin=t[0]),null==e.integrity&&(e.integrity=t[1])}function _I(e,t,n){for(var r in t="<"+(e=(""+e).replace(SI,TI))+'>; rel=preload; as="'+(t=(""+t).replace(CI,AI))+'"',n)TC.call(n,r)&&("string"==typeof(e=n[r])&&(t+="; "+r.toLowerCase()+'="'+(""+e).replace(CI,AI)+'"'));return t}var SI=/[<>\r\n]/g;function TI(e){switch(e){case"<":return"%3C";case">":return"%3E";case"\n":return"%0A";case"\r":return"%0D";default:throw Error("escapeLinkHrefForHeaderContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}var CI=/["';,\r\n]/g;function AI(e){switch(e){case'"':return"%22";case"'":return"%27";case";":return"%3B";case",":return"%2C";case"\n":return"%0A";case"\r":return"%0D";default:throw Error("escapeStringForLinkHeaderQuotedParamValueContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}function NI(e){this.styles.add(e)}function II(e){this.stylesheets.add(e)}var RI=Function.prototype.bind,OI=Symbol.for("react.client.reference");function PI(e){if(null==e)return null;if("function"==typeof e)return e.$$typeof===OI?null:e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case VT:return"Fragment";case GT:return"Portal";case WT:return"Profiler";case qT:return"StrictMode";case ZT:return"Suspense";case JT:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case XT:return(e.displayName||"Context")+".Provider";case KT:return(e._context.displayName||"Context")+".Consumer";case QT:var t=e.render;return(e=e.displayName)||(e=""!==(e=t.displayName||t.name||"")?"ForwardRef("+e+")":"ForwardRef"),e;case eC:return null!==(t=e.displayName||null)?t:PI(e.type)||"Memo";case tC:t=e._payload,e=e._init;try{return PI(e(t))}catch(n){}}return null}var DI={},LI=null;function MI(e,t){if(e!==t){e.context._currentValue=e.parentValue,e=e.parent;var n=t.parent;if(null===e){if(null!==n)throw Error(UT(401))}else{if(null===n)throw Error(UT(401));MI(e,n)}t.context._currentValue=t.value}}function FI(e){e.context._currentValue=e.parentValue,null!==(e=e.parent)&&FI(e)}function jI(e){var t=e.parent;null!==t&&jI(t),e.context._currentValue=e.value}function BI(e,t){if(e.context._currentValue=e.parentValue,null===(e=e.parent))throw Error(UT(402));e.depth===t.depth?MI(e,t):BI(e,t)}function zI(e,t){var n=t.parent;if(null===n)throw Error(UT(402));e.depth===n.depth?MI(e,n):zI(e,n),t.context._currentValue=t.value}function HI(e){var t=LI;t!==e&&(null===t?jI(e):null===e?FI(t):t.depth===e.depth?MI(t,e):t.depth>e.depth?BI(t,e):zI(t,e),LI=e)}var UI={isMounted:function(){return!1},enqueueSetState:function(e,t){null!==(e=e._reactInternals).queue&&e.queue.push(t)},enqueueReplaceState:function(e,t){(e=e._reactInternals).replace=!0,e.queue=[t]},enqueueForceUpdate:function(){}},$I={id:1,overflow:""};function GI(e,t,n){var r=e.id;e=e.overflow;var a=32-VI(r)-1;r&=~(1<<a),n+=1;var o=32-VI(t)+a;if(30<o){var i=a-a%5;return o=(r&(1<<i)-1).toString(32),r>>=i,a-=i,{id:1<<32-VI(t)+a|n<<a|r,overflow:o+e}}return{id:1<<o|n<<a|r,overflow:e}}var VI=Math.clz32?Math.clz32:function(e){return 0===(e>>>=0)?32:31-(qI(e)/WI|0)|0},qI=Math.log,WI=Math.LN2;var YI=Error(UT(460));function KI(){}var XI=null;function QI(){if(null===XI)throw Error(UT(459));var e=XI;return XI=null,e}var ZI="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},JI=null,eR=null,tR=null,nR=null,rR=null,aR=null,oR=!1,iR=!1,sR=0,lR=0,cR=-1,uR=0,dR=null,pR=null,hR=0;function fR(){if(null===JI)throw Error(UT(321));return JI}function mR(){if(0<hR)throw Error(UT(312));return{memoizedState:null,queue:null,next:null}}function gR(){return null===aR?null===rR?(oR=!1,rR=aR=mR()):(oR=!0,aR=rR):null===aR.next?(oR=!1,aR=aR.next=mR()):(oR=!0,aR=aR.next),aR}function yR(){var e=dR;return dR=null,e}function bR(){nR=tR=eR=JI=null,iR=!1,rR=null,hR=0,aR=pR=null}function vR(e,t){return"function"==typeof t?t(e):t}function kR(e,t,n){if(JI=fR(),aR=gR(),oR){var r=aR.queue;if(t=r.dispatch,null!==pR&&void 0!==(n=pR.get(r))){pR.delete(r),r=aR.memoizedState;do{r=e(r,n.action),n=n.next}while(null!==n);return aR.memoizedState=r,[r,t]}return[aR.memoizedState,t]}return e=e===vR?"function"==typeof t?t():t:void 0!==n?n(t):t,aR.memoizedState=e,e=(e=aR.queue={last:null,dispatch:null}).dispatch=xR.bind(null,JI,e),[aR.memoizedState,e]}function wR(e,t){if(JI=fR(),t=void 0===t?null:t,null!==(aR=gR())){var n=aR.memoizedState;if(null!==n&&null!==t){var r=n[1];e:if(null===r)r=!1;else{for(var a=0;a<r.length&&a<t.length;a++)if(!ZI(t[a],r[a])){r=!1;break e}r=!0}if(r)return n[0]}}return e=e(),aR.memoizedState=[e,t],e}function xR(e,t,n){if(25<=hR)throw Error(UT(301));if(e===JI)if(iR=!0,e={action:n,next:null},null===pR&&(pR=new Map),void 0===(n=pR.get(t)))pR.set(t,e);else{for(t=n;null!==t.next;)t=t.next;t.next=e}}function ER(){throw Error(UT(394))}function _R(){throw Error(UT(479))}function SR(e,t,n){fR();var r=lR++,a=tR;if("function"==typeof e.$$FORM_ACTION){var o=null,i=nR;a=a.formState;var s=e.$$IS_SIGNATURE_EQUAL;if(null!==a&&"function"==typeof s){var l=a[1];s.call(e,a[2],a[3])&&(l===(o=void 0!==n?"p"+n:"k"+cC(JSON.stringify([i,null,r]),0))&&(cR=r,t=a[0]))}var c=e.bind(null,t);return e=function(e){c(e)},"function"==typeof c.$$FORM_ACTION&&(e.$$FORM_ACTION=function(e){e=c.$$FORM_ACTION(e),void 0!==n&&(n+="",e.action=n);var t=e.data;return t&&(null===o&&(o=void 0!==n?"p"+n:"k"+cC(JSON.stringify([i,null,r]),0)),t.append("$ACTION_KEY",o)),e}),[t,e,!1]}var u=e.bind(null,t);return[t,function(e){u(e)},!1]}function TR(e){var t=uR;return uR+=1,null===dR&&(dR=[]),function(e,t,n){switch(void 0===(n=e[n])?e.push(t):n!==t&&(t.then(KI,KI),t=n),t.status){case"fulfilled":return t.value;case"rejected":throw t.reason;default:switch("string"==typeof t.status?t.then(KI,KI):((e=t).status="pending",e.then((function(e){if("pending"===t.status){var n=t;n.status="fulfilled",n.value=e}}),(function(e){if("pending"===t.status){var n=t;n.status="rejected",n.reason=e}}))),t.status){case"fulfilled":return t.value;case"rejected":throw t.reason}throw XI=t,YI}}(dR,e,t)}function CR(){throw Error(UT(393))}function AR(){}var NR={readContext:function(e){return e._currentValue},use:function(e){if(null!==e&&"object"==typeof e){if("function"==typeof e.then)return TR(e);if(e.$$typeof===XT)return e._currentValue}throw Error(UT(438,String(e)))},useContext:function(e){return fR(),e._currentValue},useMemo:wR,useReducer:kR,useRef:function(e){JI=fR();var t=(aR=gR()).memoizedState;return null===t?(e={current:e},aR.memoizedState=e):t},useState:function(e){return kR(vR,e)},useInsertionEffect:AR,useLayoutEffect:AR,useCallback:function(e,t){return wR((function(){return e}),t)},useImperativeHandle:AR,useEffect:AR,useDebugValue:AR,useDeferredValue:function(e,t){return fR(),void 0!==t?t:e},useTransition:function(){return fR(),[!1,ER]},useId:function(){var e=eR.treeContext,t=e.overflow;e=((e=e.id)&~(1<<32-VI(e)-1)).toString(32)+t;var n=OR;if(null===n)throw Error(UT(404));return t=sR++,e=":"+n.idPrefix+"R"+e,0<t&&(e+="H"+t.toString(32)),e+":"},useSyncExternalStore:function(e,t,n){if(void 0===n)throw Error(UT(407));return n()},useCacheRefresh:function(){return CR},useMemoCache:function(e){for(var t=Array(e),n=0;n<e;n++)t[n]=iC;return t},useHostTransitionStatus:function(){return fR(),HC},useOptimistic:function(e){return fR(),[e,_R]}};NR.useFormState=SR,NR.useActionState=SR;var IR,RR,OR=null,PR={getCacheForType:function(){throw Error(UT(248))}};function DR(e){if(void 0===IR)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);IR=t&&t[1]||"",RR=-1<n.stack.indexOf("\n at")?" (<anonymous>)":-1<n.stack.indexOf("@")?"@unknown:0:0":""}return"\n"+IR+e+RR}var LR=!1;function MR(e,t){if(!e||LR)return"";LR=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(n,[])}catch(a){var r=a}Reflect.construct(e,[],n)}else{try{n.call()}catch(o){r=o}e.call(n.prototype)}}else{try{throw Error()}catch(i){r=i}(n=e())&&"function"==typeof n.catch&&n.catch((function(){}))}}catch(s){if(s&&r&&"string"==typeof s.stack)return[s.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var a=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,"name");a&&a.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var o=r.DetermineComponentFrameRoot(),i=o[0],s=o[1];if(i&&s){var l=i.split("\n"),c=s.split("\n");for(a=r=0;r<l.length&&!l[r].includes("DetermineComponentFrameRoot");)r++;for(;a<c.length&&!c[a].includes("DetermineComponentFrameRoot");)a++;if(r===l.length||a===c.length)for(r=l.length-1,a=c.length-1;1<=r&&0<=a&&l[r]!==c[a];)a--;for(;1<=r&&0<=a;r--,a--)if(l[r]!==c[a]){if(1!==r||1!==a)do{if(r--,0>--a||l[r]!==c[a]){var u="\n"+l[r].replace(" at new "," at ");return e.displayName&&u.includes("<anonymous>")&&(u=u.replace("<anonymous>",e.displayName)),u}}while(1<=r&&0<=a);break}}}finally{LR=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:"")?DR(n):""}function FR(e){if("string"==typeof e)return DR(e);if("function"==typeof e)return e.prototype&&e.prototype.isReactComponent?e=MR(e,!0):MR(e,!1);if("object"==typeof e&&null!==e){switch(e.$$typeof){case QT:return MR(e.render,!1);case eC:return MR(e.type,!1);case tC:var t=e,n=t._payload;t=t._init;try{e=t(n)}catch(r){return DR("Lazy")}return FR(e)}if("string"==typeof e.name)return n=e.env,DR(e.name+(n?" ["+n+"]":""))}switch(e){case JT:return DR("SuspenseList");case ZT:return DR("Suspense")}return""}function jR(e){if("object"==typeof e&&null!==e&&"string"==typeof e.environmentName){var t=e.environmentName;"string"==typeof(e=[e].slice(0))[0]?e.splice(0,1,"%c%s%c "+e[0],"background: #e6e6e6;background: light-dark(rgba(0,0,0,0.1), rgba(255,255,255,0.25));color: #000000;color: light-dark(#000000, #ffffff);border-radius: 2px"," "+t+" ",""):e.splice(0,0,"%c%s%c ","background: #e6e6e6;background: light-dark(rgba(0,0,0,0.1), rgba(255,255,255,0.25));color: #000000;color: light-dark(#000000, #ffffff);border-radius: 2px"," "+t+" ",""),e.unshift(console),(t=RI.apply(console.error,e))()}else console.error(e);return null}function BR(){}function zR(e,t,n,r,a,o,i,s,l,c,u){var d=new Set;this.destination=null,this.flushScheduled=!1,this.resumableState=e,this.renderState=t,this.rootFormatContext=n,this.progressiveChunkSize=void 0===r?12800:r,this.status=10,this.fatalError=null,this.pendingRootTasks=this.allPendingTasks=this.nextSegmentId=0,this.completedRootSegment=null,this.abortableTasks=d,this.pingedTasks=[],this.clientRenderedBoundaries=[],this.completedBoundaries=[],this.partialBoundaries=[],this.trackedPostpones=null,this.onError=void 0===a?jR:a,this.onPostpone=void 0===c?BR:c,this.onAllReady=void 0===o?BR:o,this.onShellReady=void 0===i?BR:i,this.onShellError=void 0===s?BR:s,this.onFatalError=void 0===l?BR:l,this.formState=void 0===u?null:u}function HR(e,t,n,r,a,o,i,s,l,c,u,d){return(n=KR(t=new zR(t,n,r,a,o,i,s,l,c,u,d),0,null,r,!1,!1)).parentFlushed=!0,XR(e=WR(t,null,e,-1,null,n,null,t.abortableTasks,null,r,null,$I,null,!1)),t.pingedTasks.push(e),t}var UR,$R,GR=null;function VR(e,t){e.pingedTasks.push(t),1===e.pingedTasks.length&&(e.flushScheduled=null!==e.destination,null!==e.trackedPostpones||10===e.status?mC((function(){return vO(e)})):pC((function(){return vO(e)})))}function qR(e,t){return{status:0,rootSegmentID:-1,parentFlushed:!1,pendingTasks:0,completedSegments:[],byteSize:0,fallbackAbortableTasks:t,errorDigest:null,contentState:xI(),fallbackState:xI(),trackedContentKeyPath:null,trackedFallbackNode:null}}function WR(e,t,n,r,a,o,i,s,l,c,u,d,p,h){e.allPendingTasks++,null===a?e.pendingRootTasks++:a.pendingTasks++;var f={replay:null,node:n,childIndex:r,ping:function(){return VR(e,f)},blockedBoundary:a,blockedSegment:o,hoistableState:i,abortSet:s,keyPath:l,formatContext:c,context:u,treeContext:d,componentStack:p,thenableState:t,isFallback:h};return s.add(f),f}function YR(e,t,n,r,a,o,i,s,l,c,u,d,p,h){e.allPendingTasks++,null===o?e.pendingRootTasks++:o.pendingTasks++,n.pendingTasks++;var f={replay:n,node:r,childIndex:a,ping:function(){return VR(e,f)},blockedBoundary:o,blockedSegment:null,hoistableState:i,abortSet:s,keyPath:l,formatContext:c,context:u,treeContext:d,componentStack:p,thenableState:t,isFallback:h};return s.add(f),f}function KR(e,t,n,r,a,o){return{status:0,id:-1,index:t,parentFlushed:!1,chunks:[],children:[],parentFormatContext:r,boundary:n,lastPushedText:a,textEmbedded:o}}function XR(e){var t=e.node;if("object"==typeof t&&null!==t&&t.$$typeof===$T)e.componentStack={parent:e.componentStack,type:t.type}}function QR(e){var t={};return e&&Object.defineProperty(t,"componentStack",{configurable:!0,enumerable:!0,get:function(){try{var n="",r=e;do{n+=FR(r.type),r=r.parent}while(r);var a=n}catch(o){a="\nError generating stack: "+o.message+"\n"+o.stack}return Object.defineProperty(t,"componentStack",{value:a}),a}}),t}function ZR(e,t,n){if(null==(t=(e=e.onError)(t,n))||"string"==typeof t)return t}function JR(e,t){var n=e.onShellError,r=e.onFatalError;n(t),r(t),null!==e.destination?(e.status=14,_C(e.destination,t)):(e.status=13,e.fatalError=t)}function eO(e,t,n,r,a,o){var i=t.thenableState;for(t.thenableState=null,JI={},eR=t,tR=e,nR=n,lR=sR=0,cR=-1,uR=0,dR=i,e=r(a,o);iR;)iR=!1,lR=sR=0,cR=-1,uR=0,hR+=1,aR=null,e=r(a,o);return bR(),e}function tO(e,t,n,r,a,o,i){var s=!1;if(0!==o&&null!==e.formState){var l=t.blockedSegment;if(null!==l){s=!0,l=l.chunks;for(var c=0;c<o;c++)c===i?l.push(PA):l.push(DA)}}o=t.keyPath,t.keyPath=n,a?(n=t.treeContext,t.treeContext=GI(n,1,0),uO(e,t,r,-1),t.treeContext=n):s?uO(e,t,r,-1):aO(e,t,r,-1),t.keyPath=o}function nO(e,t,n,r,a,o){if("function"==typeof r)if(r.prototype&&r.prototype.isReactComponent){var i=a;if("ref"in a)for(var s in i={},a)"ref"!==s&&(i[s]=a[s]);var l=r.defaultProps;if(l)for(var c in i===a&&(i=SC({},i,a)),l)void 0===i[c]&&(i[c]=l[c]);a=i,i=DI,"object"==typeof(l=r.contextType)&&null!==l&&(i=l._currentValue);var u=void 0!==(i=new r(a,i)).state?i.state:null;if(i.updater=UI,i.props=a,i.state=u,l={queue:[],replace:!1},i._reactInternals=l,o=r.contextType,i.context="object"==typeof o&&null!==o?o._currentValue:DI,"function"==typeof(o=r.getDerivedStateFromProps)&&(u=null==(o=o(a,u))?u:SC({},u,o),i.state=u),"function"!=typeof r.getDerivedStateFromProps&&"function"!=typeof i.getSnapshotBeforeUpdate&&("function"==typeof i.UNSAFE_componentWillMount||"function"==typeof i.componentWillMount))if(r=i.state,"function"==typeof i.componentWillMount&&i.componentWillMount(),"function"==typeof i.UNSAFE_componentWillMount&&i.UNSAFE_componentWillMount(),r!==i.state&&UI.enqueueReplaceState(i,i.state,null),null!==l.queue&&0<l.queue.length)if(r=l.queue,o=l.replace,l.queue=null,l.replace=!1,o&&1===r.length)i.state=r[0];else{for(l=o?r[0]:i.state,u=!0,o=o?1:0;o<r.length;o++)null!=(c="function"==typeof(c=r[o])?c.call(i,l,a,void 0):c)&&(u?(u=!1,l=SC({},l,c)):SC(l,c));i.state=l}else l.queue=null;if(r=i.render(),12===e.status)throw null;a=t.keyPath,t.keyPath=n,aO(e,t,r,-1),t.keyPath=a}else{if(r=eO(e,t,n,r,a,void 0),12===e.status)throw null;tO(e,t,n,r,0!==sR,lR,cR)}else{if("string"!=typeof r){switch(r){case oC:case rC:case qT:case WT:case VT:return r=t.keyPath,t.keyPath=n,aO(e,t,a.children,-1),void(t.keyPath=r);case aC:return void("hidden"!==a.mode&&(r=t.keyPath,t.keyPath=n,aO(e,t,a.children,-1),t.keyPath=r));case JT:return r=t.keyPath,t.keyPath=n,aO(e,t,a.children,-1),void(t.keyPath=r);case nC:throw Error(UT(343));case ZT:e:if(null!==t.replay){r=t.keyPath,t.keyPath=n,n=a.children;try{uO(e,t,n,-1)}finally{t.keyPath=r}}else{r=t.keyPath;var d=t.blockedBoundary,p=t.hoistableState;o=t.blockedSegment,c=a.fallback,a=a.children;var h=new Set;s=qR(0,h),null!==e.trackedPostpones&&(s.trackedContentKeyPath=n);var f=KR(0,o.chunks.length,s,t.formatContext,!1,!1);o.children.push(f),o.lastPushedText=!1;var m=KR(0,0,null,t.formatContext,!1,!1);if(m.parentFlushed=!0,null!==e.trackedPostpones){l=[(i=[n[0],"Suspense Fallback",n[2]])[1],i[2],[],null],e.trackedPostpones.workingMap.set(i,l),s.trackedFallbackNode=l,t.blockedSegment=f,t.keyPath=i,f.status=6;try{uO(e,t,c,-1),f.lastPushedText&&f.textEmbedded&&f.chunks.push(sA),f.status=1}catch(g){throw f.status=12===e.status?3:4,g}finally{t.blockedSegment=o,t.keyPath=r}XR(t=WR(e,null,a,-1,s,m,s.contentState,t.abortSet,n,t.formatContext,t.context,t.treeContext,t.componentStack,t.isFallback)),e.pingedTasks.push(t)}else{t.blockedBoundary=s,t.hoistableState=s.contentState,t.blockedSegment=m,t.keyPath=n,m.status=6;try{if(uO(e,t,a,-1),m.lastPushedText&&m.textEmbedded&&m.chunks.push(sA),m.status=1,yO(s,m),0===s.pendingTasks&&0===s.status){s.status=1;break e}}catch(y){s.status=4,12===e.status?(m.status=3,i=e.fatalError):(m.status=4,i=y),u=ZR(e,i,l=QR(t.componentStack)),s.errorDigest=u,sO(e,s)}finally{t.blockedBoundary=d,t.hoistableState=p,t.blockedSegment=o,t.keyPath=r}XR(t=WR(e,null,c,-1,d,f,s.fallbackState,h,[n[0],"Suspense Fallback",n[2]],t.formatContext,t.context,t.treeContext,t.componentStack,!0)),e.pingedTasks.push(t)}}return}if("object"==typeof r&&null!==r)switch(r.$$typeof){case QT:if("ref"in a)for(f in i={},a)"ref"!==f&&(i[f]=a[f]);else i=a;return void tO(e,t,n,r=eO(e,t,n,r.render,i,o),0!==sR,lR,cR);case eC:return void nO(e,t,n,r.type,a,o);case YT:case XT:if(l=a.children,i=t.keyPath,a=a.value,u=r._currentValue,r._currentValue=a,LI=r={parent:o=LI,depth:null===o?0:o.depth+1,context:r,parentValue:u,value:a},t.context=r,t.keyPath=n,aO(e,t,l,-1),null===(e=LI))throw Error(UT(403));return e.context._currentValue=e.parentValue,e=LI=e.parent,t.context=e,void(t.keyPath=i);case KT:return r=(a=a.children)(r._context._currentValue),a=t.keyPath,t.keyPath=n,aO(e,t,r,-1),void(t.keyPath=a);case tC:if(r=(i=r._init)(r._payload),12===e.status)throw null;return void nO(e,t,n,r,a,o)}throw Error(UT(130,null==r?r:typeof r,""))}if(null===(i=t.blockedSegment))i=a.children,l=t.formatContext,u=t.keyPath,t.formatContext=iA(l,r,a),t.keyPath=n,uO(e,t,i,-1),t.formatContext=l,t.keyPath=u;else{u=WA(i.chunks,r,a,e.resumableState,e.renderState,t.hoistableState,t.formatContext,i.lastPushedText,t.isFallback),i.lastPushedText=!1,l=t.formatContext,o=t.keyPath,t.formatContext=iA(l,r,a),t.keyPath=n,uO(e,t,u,-1),t.formatContext=l,t.keyPath=o;e:{switch(t=i.chunks,e=e.resumableState,r){case"title":case"style":case"script":case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"input":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":break e;case"body":if(1>=l.insertionMode){e.hasBody=!0;break e}break;case"html":if(0===l.insertionMode){e.hasHtml=!0;break e}}t.push(KA(r))}i.lastPushedText=!1}}}function rO(e,t,n,r,a){var o=t.replay,i=t.blockedBoundary,s=KR(0,0,null,t.formatContext,!1,!1);s.id=n,s.parentFlushed=!0;try{t.replay=null,t.blockedSegment=s,uO(e,t,r,a),s.status=1,null===i?e.completedRootSegment=s:(yO(i,s),i.parentFlushed&&e.partialBoundaries.push(i))}finally{t.replay=o,t.blockedSegment=null}}function aO(e,t,n,r){null!==t.replay&&"number"==typeof t.replay.slots?rO(e,t,t.replay.slots,n,r):(t.node=n,t.childIndex=r,n=t.componentStack,XR(t),oO(e,t),t.componentStack=n)}function oO(e,t){var n=t.node,r=t.childIndex;if(null!==n){if("object"==typeof n){switch(n.$$typeof){case $T:var a=n.type,o=n.key,i=n.props,s=void 0!==(n=i.ref)?n:null,l=PI(a),c=null==o?-1===r?0:r:o;if(o=[t.keyPath,l,c],null!==t.replay)e:{var u=t.replay;for(r=u.nodes,n=0;n<r.length;n++){var d=r[n];if(c===d[1]){if(4===d.length){if(null!==l&&l!==d[0])throw Error(UT(490,d[0],l));var p=d[2];l=d[3],c=t.node,t.replay={nodes:p,slots:l,pendingTasks:1};try{if(nO(e,t,o,a,i,s),1===t.replay.pendingTasks&&0<t.replay.nodes.length)throw Error(UT(488));t.replay.pendingTasks--}catch(k){if("object"==typeof k&&null!==k&&(k===YI||"function"==typeof k.then))throw t.node===c&&(t.replay=u),k;t.replay.pendingTasks--,i=QR(t.componentStack),pO(e,o=t.blockedBoundary,p,l,a=k,i=ZR(e,a,i))}t.replay=u}else{if(a!==ZT)throw Error(UT(490,"Suspense",PI(a)||"Unknown"));t:{u=void 0,a=d[5],s=d[2],l=d[3],c=null===d[4]?[]:d[4][2],d=null===d[4]?null:d[4][3];var h=t.keyPath,f=t.replay,m=t.blockedBoundary,g=t.hoistableState,y=i.children;i=i.fallback;var b=new Set,v=qR(0,b);v.parentFlushed=!0,v.rootSegmentID=a,t.blockedBoundary=v,t.hoistableState=v.contentState,t.keyPath=o,t.replay={nodes:s,slots:l,pendingTasks:1};try{if(uO(e,t,y,-1),1===t.replay.pendingTasks&&0<t.replay.nodes.length)throw Error(UT(488));if(t.replay.pendingTasks--,0===v.pendingTasks&&0===v.status){v.status=1,e.completedBoundaries.push(v);break t}}catch(w){v.status=4,u=ZR(e,w,p=QR(t.componentStack)),v.errorDigest=u,t.replay.pendingTasks--,e.clientRenderedBoundaries.push(v)}finally{t.blockedBoundary=m,t.hoistableState=g,t.replay=f,t.keyPath=h}XR(t=YR(e,null,{nodes:c,slots:d,pendingTasks:0},i,-1,m,v.fallbackState,b,[o[0],"Suspense Fallback",o[2]],t.formatContext,t.context,t.treeContext,t.componentStack,!0)),e.pingedTasks.push(t)}}r.splice(n,1);break e}}}else nO(e,t,o,a,i,s);return;case GT:throw Error(UT(257));case tC:if(n=(p=n._init)(n._payload),12===e.status)throw null;return void aO(e,t,n,r)}if(lC(n))return void iO(e,t,n,r);if(null===n||"object"!=typeof n?p=null:p="function"==typeof(p=sC&&n[sC]||n["@@iterator"])?p:null,p&&(p=p.call(n))){if(!(n=p.next()).done){i=[];do{i.push(n.value),n=p.next()}while(!n.done);iO(e,t,i,r)}return}if("function"==typeof n.then)return t.thenableState=null,aO(e,t,TR(n),r);if(n.$$typeof===XT)return aO(e,t,n._currentValue,r);throw r=Object.prototype.toString.call(n),Error(UT(31,"[object Object]"===r?"object with keys {"+Object.keys(n).join(", ")+"}":r))}"string"==typeof n?null!==(r=t.blockedSegment)&&(r.lastPushedText=lA(r.chunks,n,e.renderState,r.lastPushedText)):"number"!=typeof n&&"bigint"!=typeof n||null!==(r=t.blockedSegment)&&(r.lastPushedText=lA(r.chunks,""+n,e.renderState,r.lastPushedText))}}function iO(e,t,n,r){var a=t.keyPath;if(-1===r||(t.keyPath=[t.keyPath,"Fragment",r],null===t.replay)){if(o=t.treeContext,i=n.length,null!==t.replay&&(null!==(s=t.replay.slots)&&"object"==typeof s)){for(r=0;r<i;r++)l=n[r],t.treeContext=GI(o,i,r),"number"==typeof(c=s[r])?(rO(e,t,c,l,r),delete s[r]):uO(e,t,l,r);return t.treeContext=o,void(t.keyPath=a)}for(s=0;s<i;s++)r=n[s],t.treeContext=GI(o,i,s),uO(e,t,r,s);t.treeContext=o,t.keyPath=a}else{for(var o=t.replay,i=o.nodes,s=0;s<i.length;s++){var l=i[s];if(l[1]===r){r=l[2],l=l[3],t.replay={nodes:r,slots:l,pendingTasks:1};try{if(iO(e,t,n,-1),1===t.replay.pendingTasks&&0<t.replay.nodes.length)throw Error(UT(488));t.replay.pendingTasks--}catch(u){if("object"==typeof u&&null!==u&&(u===YI||"function"==typeof u.then))throw u;t.replay.pendingTasks--,n=QR(t.componentStack);var c=t.blockedBoundary;pO(e,c,r,l,u,n=ZR(e,u,n))}t.replay=o,i.splice(s,1);break}}t.keyPath=a}}function sO(e,t){null!==(e=e.trackedPostpones)&&(null!==(t=t.trackedContentKeyPath)&&(void 0!==(t=e.workingMap.get(t))&&(t.length=4,t[2]=[],t[3]=null)))}function lO(e,t,n){return YR(e,n,t.replay,t.node,t.childIndex,t.blockedBoundary,t.hoistableState,t.abortSet,t.keyPath,t.formatContext,t.context,t.treeContext,t.componentStack,t.isFallback)}function cO(e,t,n){var r=t.blockedSegment,a=KR(0,r.chunks.length,null,t.formatContext,r.lastPushedText,!0);return r.children.push(a),r.lastPushedText=!1,WR(e,n,t.node,t.childIndex,t.blockedBoundary,a,t.hoistableState,t.abortSet,t.keyPath,t.formatContext,t.context,t.treeContext,t.componentStack,t.isFallback)}function uO(e,t,n,r){var a=t.formatContext,o=t.context,i=t.keyPath,s=t.treeContext,l=t.componentStack,c=t.blockedSegment;if(null===c)try{return aO(e,t,n,r)}catch(p){if(bR(),"object"==typeof(n=p===YI?QI():p)&&null!==n){if("function"==typeof n.then)return e=lO(e,t,r=yR()).ping,n.then(e,e),t.formatContext=a,t.context=o,t.keyPath=i,t.treeContext=s,t.componentStack=l,void HI(o);if("Maximum call stack size exceeded"===n.message)return n=lO(e,t,n=yR()),e.pingedTasks.push(n),t.formatContext=a,t.context=o,t.keyPath=i,t.treeContext=s,t.componentStack=l,void HI(o)}}else{var u=c.children.length,d=c.chunks.length;try{return aO(e,t,n,r)}catch(h){if(bR(),c.children.length=u,c.chunks.length=d,"object"==typeof(n=h===YI?QI():h)&&null!==n){if("function"==typeof n.then)return e=cO(e,t,r=yR()).ping,n.then(e,e),t.formatContext=a,t.context=o,t.keyPath=i,t.treeContext=s,t.componentStack=l,void HI(o);if("Maximum call stack size exceeded"===n.message)return n=cO(e,t,n=yR()),e.pingedTasks.push(n),t.formatContext=a,t.context=o,t.keyPath=i,t.treeContext=s,t.componentStack=l,void HI(o)}}}throw t.formatContext=a,t.context=o,t.keyPath=i,t.treeContext=s,HI(o),n}function dO(e){var t=e.blockedBoundary;null!==(e=e.blockedSegment)&&(e.status=3,bO(this,t,e))}function pO(e,t,n,r,a,o){for(var i=0;i<n.length;i++){var s=n[i];if(4===s.length)pO(e,t,s[2],s[3],a,o);else{s=s[5];var l=e,c=o,u=qR(0,new Set);u.parentFlushed=!0,u.rootSegmentID=s,u.status=4,u.errorDigest=c,u.parentFlushed&&l.clientRenderedBoundaries.push(u)}}if(n.length=0,null!==r){if(null===t)throw Error(UT(487));if(4!==t.status&&(t.status=4,t.errorDigest=o,t.parentFlushed&&e.clientRenderedBoundaries.push(t)),"object"==typeof r)for(var d in r)delete r[d]}}function hO(e,t,n){var r=e.blockedBoundary,a=e.blockedSegment;if(null!==a){if(6===a.status)return;a.status=3}if(a=QR(e.componentStack),null===r){if(13!==t.status&&14!==t.status){if(null===(r=e.replay))return ZR(t,n,a),void JR(t,n);r.pendingTasks--,0===r.pendingTasks&&0<r.nodes.length&&(e=ZR(t,n,a),pO(t,null,r.nodes,r.slots,n,e)),t.pendingRootTasks--,0===t.pendingRootTasks&&mO(t)}}else r.pendingTasks--,4!==r.status&&(r.status=4,e=ZR(t,n,a),r.status=4,r.errorDigest=e,sO(t,r),r.parentFlushed&&t.clientRenderedBoundaries.push(r)),r.fallbackAbortableTasks.forEach((function(e){return hO(e,t,n)})),r.fallbackAbortableTasks.clear();t.allPendingTasks--,0===t.allPendingTasks&&gO(t)}function fO(e,t){try{var n=e.renderState,r=n.onHeaders;if(r){var a=n.headers;if(a){n.headers=null;var o=a.preconnects;if(a.fontPreloads&&(o&&(o+=", "),o+=a.fontPreloads),a.highImagePreloads&&(o&&(o+=", "),o+=a.highImagePreloads),!t){var i=n.styles.values(),s=i.next();e:for(;0<a.remainingCapacity&&!s.done;s=i.next())for(var l=s.value.sheets.values(),c=l.next();0<a.remainingCapacity&&!c.done;c=l.next()){var u=c.value,d=u.props,p=d.href,h=u.props,f=_I(h.href,"style",{crossOrigin:h.crossOrigin,integrity:h.integrity,nonce:h.nonce,type:h.type,fetchPriority:h.fetchPriority,referrerPolicy:h.referrerPolicy,media:h.media});if(!(0<=(a.remainingCapacity-=f.length+2)))break e;n.resets.style[p]=$C,o&&(o+=", "),o+=f,n.resets.style[p]="string"==typeof d.crossOrigin||"string"==typeof d.integrity?[d.crossOrigin,d.integrity]:$C}}r(o?{Link:o}:{})}}}catch(m){ZR(e,m,{})}}function mO(e){null===e.trackedPostpones&&fO(e,!0),e.onShellError=BR,(e=e.onShellReady)()}function gO(e){fO(e,null===e.trackedPostpones||(null===e.completedRootSegment||5!==e.completedRootSegment.status)),(e=e.onAllReady)()}function yO(e,t){if(0===t.chunks.length&&1===t.children.length&&null===t.children[0].boundary&&-1===t.children[0].id){var n=t.children[0];n.id=t.id,n.parentFlushed=!0,1===n.status&&yO(e,n)}else e.completedSegments.push(t)}function bO(e,t,n){if(null===t){if(null!==n&&n.parentFlushed){if(null!==e.completedRootSegment)throw Error(UT(389));e.completedRootSegment=n}e.pendingRootTasks--,0===e.pendingRootTasks&&mO(e)}else t.pendingTasks--,4!==t.status&&(0===t.pendingTasks?(0===t.status&&(t.status=1),null!==n&&n.parentFlushed&&1===n.status&&yO(t,n),t.parentFlushed&&e.completedBoundaries.push(t),1===t.status&&(t.fallbackAbortableTasks.forEach(dO,e),t.fallbackAbortableTasks.clear())):null!==n&&n.parentFlushed&&1===n.status&&(yO(t,n),1===t.completedSegments.length&&t.parentFlushed&&e.partialBoundaries.push(t)));e.allPendingTasks--,0===e.allPendingTasks&&gO(e)}function vO(e){if(14!==e.status&&13!==e.status){var t=LI,n=BC.H;BC.H=NR;var r=BC.A;BC.A=PR;var a=GR;GR=e;var o=OR;OR=e.resumableState;try{var i,s=e.pingedTasks;for(i=0;i<s.length;i++){var l=s[i],c=e,u=l.blockedSegment;if(null===u){var d=c;if(0!==l.replay.pendingTasks){HI(l.context);try{if("number"==typeof l.replay.slots?rO(d,l,l.replay.slots,l.node,l.childIndex):oO(d,l),1===l.replay.pendingTasks&&0<l.replay.nodes.length)throw Error(UT(488));l.replay.pendingTasks--,l.abortSet.delete(l),bO(d,l.blockedBoundary,null)}catch(_){bR();var p=_===YI?QI():_;if("object"==typeof p&&null!==p&&"function"==typeof p.then){var h=l.ping;p.then(h,h),l.thenableState=yR()}else{l.replay.pendingTasks--,l.abortSet.delete(l);var f=QR(l.componentStack);c=void 0;var m=d,g=l.blockedBoundary,y=12===d.status?d.fatalError:p;pO(m,g,l.replay.nodes,l.replay.slots,y,c=ZR(m,y,f)),d.pendingRootTasks--,0===d.pendingRootTasks&&mO(d),d.allPendingTasks--,0===d.allPendingTasks&&gO(d)}}}}else if(d=void 0,0===(m=u).status){m.status=6,HI(l.context);var b=m.children.length,v=m.chunks.length;try{oO(c,l),m.lastPushedText&&m.textEmbedded&&m.chunks.push(sA),l.abortSet.delete(l),m.status=1,bO(c,l.blockedBoundary,m)}catch(_){bR(),m.children.length=b,m.chunks.length=v;var k=_===YI?QI():12===c.status?c.fatalError:_;if("object"==typeof k&&null!==k&&"function"==typeof k.then){m.status=0,l.thenableState=yR();var w=l.ping;k.then(w,w)}else{var x=QR(l.componentStack);l.abortSet.delete(l),m.status=4;var E=l.blockedBoundary;d=ZR(c,k,x),null===E?JR(c,k):(E.pendingTasks--,4!==E.status&&(E.status=4,E.errorDigest=d,sO(c,E),E.parentFlushed&&c.clientRenderedBoundaries.push(E))),c.allPendingTasks--,0===c.allPendingTasks&&gO(c)}}}}s.splice(0,i),null!==e.destination&&SO(e,e.destination)}catch(S){ZR(e,S,{}),JR(e,S)}finally{OR=o,BC.H=n,BC.A=r,n===NR&&HI(t),GR=a}}}function kO(e,t,n,r){switch(n.parentFlushed=!0,n.status){case 0:n.id=e.nextSegmentId++;case 5:return r=n.id,n.lastPushedText=!1,n.textEmbedded=!1,e=e.renderState,bC(t,QA),bC(t,e.placeholderPrefix),bC(t,e=xC(r.toString(16))),vC(t,ZA);case 1:n.status=2;var a=!0,o=n.chunks,i=0;n=n.children;for(var s=0;s<n.length;s++){for(a=n[s];i<a.index;i++)bC(t,o[i]);a=wO(e,t,a,r)}for(;i<o.length-1;i++)bC(t,o[i]);return i<o.length&&(a=vC(t,o[i])),a;default:throw Error(UT(390))}}function wO(e,t,n,r){var a=n.boundary;if(null===a)return kO(e,t,n,r);if(a.parentFlushed=!0,4===a.status)a=a.errorDigest,vC(t,nN),bC(t,aN),a&&(bC(t,iN),bC(t,xC(DC(a))),bC(t,oN)),vC(t,sN),kO(e,t,n,r);else if(1!==a.status)0===a.status&&(a.rootSegmentID=e.nextSegmentId++),0<a.completedSegments.length&&e.partialBoundaries.push(a),lN(t,e.renderState,a.rootSegmentID),r&&((a=a.fallbackState).styles.forEach(NI,r),a.stylesheets.forEach(II,r)),kO(e,t,n,r);else if(a.byteSize>e.progressiveChunkSize)a.rootSegmentID=e.nextSegmentId++,e.completedBoundaries.push(a),lN(t,e.renderState,a.rootSegmentID),kO(e,t,n,r);else{if(r&&((n=a.contentState).styles.forEach(NI,r),n.stylesheets.forEach(II,r)),vC(t,JA),1!==(n=a.completedSegments).length)throw Error(UT(391));wO(e,t,n[0],r)}return vC(t,rN)}function xO(e,t,n,r){return function(e,t,n,r){switch(n.insertionMode){case 0:case 1:case 2:return bC(e,cN),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,uN);case 3:return bC(e,pN),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,hN);case 4:return bC(e,mN),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,gN);case 5:return bC(e,bN),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,vN);case 6:return bC(e,wN),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,xN);case 7:return bC(e,_N),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,SN);case 8:return bC(e,CN),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,AN);default:throw Error(UT(397))}}(t,e.renderState,n.parentFormatContext,n.id),wO(e,t,n,r),function(e,t){switch(t.insertionMode){case 0:case 1:case 2:return vC(e,dN);case 3:return vC(e,fN);case 4:return vC(e,yN);case 5:return vC(e,kN);case 6:return vC(e,EN);case 7:return vC(e,TN);case 8:return vC(e,NN);default:throw Error(UT(397))}}(t,n.parentFormatContext)}function EO(e,t,n){for(var r=n.completedSegments,a=0;a<r.length;a++)_O(e,t,n,r[a]);r.length=0,oI(t,n.contentState,e.renderState),r=e.resumableState,e=e.renderState,a=n.rootSegmentID,n=n.contentState;var o=e.stylesToHoist;return e.stylesToHoist=!1,bC(t,e.startInlineScript),o?2&r.instructions?8&r.instructions?bC(t,jN):(r.instructions|=8,bC(t,FN)):(r.instructions|=10,bC(t,MN)):2&r.instructions?bC(t,LN):(r.instructions|=2,bC(t,DN)),r=xC(a.toString(16)),bC(t,e.boundaryPrefix),bC(t,r),bC(t,BN),bC(t,e.segmentPrefix),bC(t,r),o?(bC(t,zN),function(e,t){bC(e,yI);var n=yI;t.stylesheets.forEach((function(t){if(2!==t.state)if(3===t.state)bC(e,n),bC(e,xC(XN(""+t.props.href))),bC(e,kI),n=bI;else{bC(e,n);var r=t.props["data-precedence"],a=t.props,o=jC(""+t.props.href);for(var i in bC(e,xC(XN(o))),r=""+r,bC(e,vI),bC(e,xC(XN(r))),a)if(TC.call(a,i)&&null!=(r=a[i]))switch(i){case"href":case"rel":case"precedence":case"data-precedence":break;case"children":case"dangerouslySetInnerHTML":throw Error(UT(399,"link"));default:wI(e,i,r)}bC(e,kI),n=bI,t.state=3}})),bC(e,kI)}(t,n)):bC(t,HN),n=vC(t,UN),XA(t,e)&&n}function _O(e,t,n,r){if(2===r.status)return!0;var a=n.contentState,o=r.id;if(-1===o){if(-1===(r.id=n.rootSegmentID))throw Error(UT(392));return xO(e,t,r,a)}return o===n.rootSegmentID?xO(e,t,r,a):(xO(e,t,r,a),n=e.resumableState,bC(t,(e=e.renderState).startInlineScript),1&n.instructions?bC(t,RN):(n.instructions|=1,bC(t,IN)),bC(t,e.segmentPrefix),bC(t,o=xC(o.toString(16))),bC(t,ON),bC(t,e.placeholderPrefix),bC(t,o),t=vC(t,PN))}function SO(e,t){gC=new Uint8Array(2048),yC=0;try{if(!(0<e.pendingRootTasks)){var n,r=e.completedRootSegment;if(null!==r){if(5===r.status)return;var a,o=e.renderState,i=o.htmlChunks,s=o.headChunks;if(i){for(a=0;a<i.length;a++)bC(t,i[a]);if(s)for(a=0;a<s.length;a++)bC(t,s[a]);else bC(t,VA("head")),bC(t,CA)}else if(s)for(a=0;a<s.length;a++)bC(t,s[a]);var l=o.charsetChunks;for(a=0;a<l.length;a++)bC(t,l[a]);l.length=0,o.preconnects.forEach(iI,t),o.preconnects.clear();var c=o.viewportChunks;for(a=0;a<c.length;a++)bC(t,c[a]);c.length=0,o.fontPreloads.forEach(iI,t),o.fontPreloads.clear(),o.highImagePreloads.forEach(iI,t),o.highImagePreloads.clear(),o.styles.forEach(fI,t);var u=o.importMapChunks;for(a=0;a<u.length;a++)bC(t,u[a]);u.length=0,o.bootstrapScripts.forEach(iI,t),o.scripts.forEach(iI,t),o.scripts.clear(),o.bulkPreloads.forEach(iI,t),o.bulkPreloads.clear();var d=o.hoistableChunks;for(a=0;a<d.length;a++)bC(t,d[a]);d.length=0,i&&null===s&&bC(t,KA("head")),wO(e,t,r,null),e.completedRootSegment=null,XA(t,e.renderState)}var p=e.renderState;r=0;var h=p.viewportChunks;for(r=0;r<h.length;r++)bC(t,h[r]);h.length=0,p.preconnects.forEach(iI,t),p.preconnects.clear(),p.fontPreloads.forEach(iI,t),p.fontPreloads.clear(),p.highImagePreloads.forEach(iI,t),p.highImagePreloads.clear(),p.styles.forEach(gI,t),p.scripts.forEach(iI,t),p.scripts.clear(),p.bulkPreloads.forEach(iI,t),p.bulkPreloads.clear();var f=p.hoistableChunks;for(r=0;r<f.length;r++)bC(t,f[r]);f.length=0;var m=e.clientRenderedBoundaries;for(n=0;n<m.length;n++){var g=m[n];p=t;var y=e.resumableState,b=e.renderState,v=g.rootSegmentID,k=g.errorDigest;bC(p,b.startInlineScript),4&y.instructions?bC(p,GN):(y.instructions|=4,bC(p,$N)),bC(p,b.boundaryPrefix),bC(p,xC(v.toString(16))),bC(p,VN),k&&(bC(p,qN),bC(p,xC((A=k||"",JSON.stringify(A).replace(YN,(function(e){switch(e){case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSStringsForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}))))));var w=vC(p,WN);if(!w)return e.destination=null,n++,void m.splice(0,n)}m.splice(0,n);var x=e.completedBoundaries;for(n=0;n<x.length;n++)if(!EO(e,t,x[n]))return e.destination=null,n++,void x.splice(0,n);x.splice(0,n),kC(t),gC=new Uint8Array(2048),yC=0;var E=e.partialBoundaries;for(n=0;n<E.length;n++){var _=E[n];e:{m=e,g=t;var S=_.completedSegments;for(w=0;w<S.length;w++)if(!_O(m,g,_,S[w])){w++,S.splice(0,w);var T=!1;break e}S.splice(0,w),T=oI(g,_.contentState,m.renderState)}if(!T)return e.destination=null,n++,void E.splice(0,n)}E.splice(0,n);var C=e.completedBoundaries;for(n=0;n<C.length;n++)if(!EO(e,t,C[n]))return e.destination=null,n++,void C.splice(0,n);C.splice(0,n)}}finally{0===e.allPendingTasks&&0===e.pingedTasks.length&&0===e.clientRenderedBoundaries.length&&0===e.completedBoundaries.length?(e.flushScheduled=!1,(n=e.resumableState).hasBody&&bC(t,KA("body")),n.hasHtml&&bC(t,KA("html")),kC(t),e.status=14,t.close(),e.destination=null):kC(t)}var A}function TO(e){e.flushScheduled=null!==e.destination,mC((function(){return vO(e)})),pC((function(){10===e.status&&(e.status=11),null===e.trackedPostpones&&fO(e,0===e.pendingRootTasks)}))}function CO(e){!1===e.flushScheduled&&0===e.pingedTasks.length&&null!==e.destination&&(e.flushScheduled=!0,pC((function(){var t=e.destination;t?SO(e,t):e.flushScheduled=!1})))}function AO(e,t){if(13===e.status)e.status=14,_C(t,e.fatalError);else if(14!==e.status&&null===e.destination){e.destination=t;try{SO(e,t)}catch(n){ZR(e,n,{}),JR(e,n)}}}function NO(e,t){11!==e.status&&10!==e.status||(e.status=12);try{var n=e.abortableTasks;if(0<n.size){var r=void 0===t?Error(UT(432)):"object"==typeof t&&null!==t&&"function"==typeof t.then?Error(UT(530)):t;e.fatalError=r,n.forEach((function(t){return hO(t,e,r)})),n.clear()}null!==e.destination&&SO(e,e.destination)}catch(a){ZR(e,a,{}),JR(e,a)}}function IO(){var e=zT.version;if("19.0.0"!==e)throw Error(UT(527,e,"19.0.0"))}IO(),IO(),BT.prerender=function(e,t){return new Promise((function(n,r){var a,o=t?t.onHeaders:void 0;o&&(a=function(e){o(new Headers(e))});var i=rA(t?t.identifierPrefix:void 0,t&&t.unstable_externalRuntimeSrc,t?t.bootstrapScriptContent:void 0,t?t.bootstrapScripts:void 0,t?t.bootstrapModules:void 0),s=function(e,t,n,r,a,o,i,s,l,c,u){return(e=HR(e,t,n,r,a,o,i,s,l,c,u,void 0)).trackedPostpones={workingMap:new Map,rootNodes:[],rootSlots:null},e}(e,i,nA(i,void 0,t?t.unstable_externalRuntimeSrc:void 0,t?t.importMap:void 0,a,t?t.maxHeadersLength:void 0),oA(t?t.namespaceURI:void 0),t?t.progressiveChunkSize:void 0,t?t.onError:void 0,(function(){var e={prelude:new ReadableStream({type:"bytes",pull:function(e){AO(s,e)},cancel:function(e){s.destination=null,NO(s,e)}},{highWaterMark:0})};n(e)}),void 0,void 0,r,t?t.onPostpone:void 0);if(t&&t.signal){var l=t.signal;if(l.aborted)NO(s,l.reason);else{var c=function(){NO(s,l.reason),l.removeEventListener("abort",c)};l.addEventListener("abort",c)}}TO(s)}))},BT.renderToReadableStream=function(e,t){return new Promise((function(n,r){var a,o,i,s=new Promise((function(e,t){o=e,a=t})),l=t?t.onHeaders:void 0;l&&(i=function(e){l(new Headers(e))});var c=rA(t?t.identifierPrefix:void 0,t&&t.unstable_externalRuntimeSrc,t?t.bootstrapScriptContent:void 0,t?t.bootstrapScripts:void 0,t?t.bootstrapModules:void 0),u=HR(e,c,nA(c,t?t.nonce:void 0,t?t.unstable_externalRuntimeSrc:void 0,t?t.importMap:void 0,i,t?t.maxHeadersLength:void 0),oA(t?t.namespaceURI:void 0),t?t.progressiveChunkSize:void 0,t?t.onError:void 0,o,(function(){var e=new ReadableStream({type:"bytes",pull:function(e){AO(u,e)},cancel:function(e){u.destination=null,NO(u,e)}},{highWaterMark:0});e.allReady=s,n(e)}),(function(e){s.catch((function(){})),r(e)}),a,t?t.onPostpone:void 0,t?t.formState:void 0);if(t&&t.signal){var d=t.signal;if(d.aborted)NO(u,d.reason);else{var p=function(){NO(u,d.reason),d.removeEventListener("abort",p)};d.addEventListener("abort",p)}}TO(u)}))},BT.version="19.0.0",$R=BT,(UR=Xx).version;var RO=UR.renderToString;function OO({children:e="",...t}){let n="";return X.isValidElement(e)?n=RO(e):"string"==typeof e&&(n=e),Wh.jsx("template",{...t,dangerouslySetInnerHTML:{__html:n}})}function PO({root:e,children:t=null}){return se.createPortal(t,e)}function DO(e){return K.forwardRef((({mode:t="open",delegatesFocus:n=!1,styleSheets:r=[],ssr:a=!1,children:o=null,...i},s)=>{const l=function(e){const t=K.useRef(null==e?void 0:e.current);return K.useEffect((()=>{e&&(e.current=t.current)}),[e]),t}(s),[c,u]=K.useState(null),d=`node_${t}${n}`;return K.useLayoutEffect((()=>{if(l.current)try{if("function"==typeof s&&s(l.current),a){const{shadowRoot:e}=l.current;return void u(e)}const e=l.current.attachShadow({mode:t,delegatesFocus:n});r.length>0&&(e.adoptedStyleSheets=r),u(e)}catch(e){!function({error:e,styleSheets:t,root:n}){if("NotSupportedError"!==(null==e?void 0:e.name))throw e;t.length>0&&n&&(n.adoptedStyleSheets=t)}({error:e,styleSheets:r,root:c})}}),[s,l,r]),Wh.jsx(e.tag,{ref:l,...i,children:(c||a)&&Wh.jsx(Kx.Provider,{value:c,children:a?Wh.jsx(OO,{shadowroot:t,shadowrootmode:t,children:e.render({root:c,ssr:a,children:o})}):Wh.jsx(PO,{root:c,children:e.render({root:c,ssr:a,children:o})})})},d)}))}UR.renderToStaticMarkup,$R.renderToReadableStream,$R.resume&&$R.resume;const LO=new Map;const MO=function(e={},t="core",n=({children:e})=>e){return new Proxy(e,{get:function(e,r){const a=Yx.decamelize(r,{separator:"-"}),o=`${t}-${a}`;if(!LO.has(o)){const e=DO({tag:a,render:n});LO.set(o,e)}return LO.get(o)}})}();var FO=(null==globalThis?void 0:globalThis.document)?K.useLayoutEffect:()=>{},jO=Q[" useId ".trim().toString()]||(()=>{}),BO=0;function zO(e){const[t,n]=K.useState(jO());return FO((()=>{n((e=>e??String(BO++)))}),[e]),t?`radix-${t}`:""}const HO=K.createContext(void 0),UO=()=>K.useContext(HO);function $O({wrapperStyles:e={},children:t,customStyles:n,styles:r}){const[a,o]=K.useState(null),[i,s]=K.useState(null),l=K.useMemo((()=>({shadowHost:a,rootElement:i})),[a,i]),c=zO(),u=MO.div;return Wh.jsxs(u,{id:`inkeep-shadow${c}`,ref:e=>{e&&o(e)},style:e,children:[Wh.jsx("style",{type:"text/css",dangerouslySetInnerHTML:{__html:`${r}`}}),n,Wh.jsx("div",{id:"inkeep-widget-root",ref:e=>{e&&s(e)},style:e,children:Wh.jsx(HO.Provider,{value:l,children:a&&i&&t})})]})}const GO=e=>UO()?e.children:Wh.jsx($O,{...e}),VO="ChatButton",qO="CustomTrigger",WO="SearchBar",YO="EmbeddedChat",KO="EmbeddedSearch",XO="EmbeddedSearchAndChat",QO="IntelligentForm",ZO="SidebarChat",JO={prefix:"ikp",aiChatSettings:{model:"inkeep-qa-expert",placeholder:"How do I get started?",aiAssistantName:void 0,shouldOpenLinksInNewTab:!0,disclaimerSettings:{isEnabled:!1,label:"Usage policy"},isShareButtonVisible:!1,isViewOnly:!1,exampleQuestionsLabel:"Example questions",exampleQuestions:[],isFirstExampleQuestionHighlighted:!0,isCopyChatButtonVisible:!1,getHelpOptions:[],workflowsHeader:"Workflows",workflows:[],toolbarButtonLabels:{clear:"Clear",share:"Share",getHelp:"Get help",stop:"Stop",copyChat:"Copy"},prompts:[]},baseSettings:Ix,searchSettings:{shouldOpenLinksInNewTab:!1,maxResults:40,defaultQuery:"",debounceTimeMs:0,tabs:["All","Publications","PDFs","GitHub","Forums","Discord","Slack","StackOverflow"],placeholder:"Search for anything...",view:"single-pane"},componentType:YO},eP=K.createContext(JO),tP=({children:e,value:t})=>{const n=UO(),r=(e,t,n)=>["baseSettings","searchSettings","aiChatSettings"].includes(n)&&!t?e:t,a={baseSettings:n??{}},o=K.useMemo((()=>{const e=function(e,t,...n){return n.reduce(((t,n)=>Oh(t,n,e)),t)}(r,JO,a,t??{});return e.baseSettings.apiKey||console.warn("Inkeep API key is missing."),e}),[t]);return Wh.jsx(eP.Provider,{value:o,children:e})},nP=()=>{const e=K.useContext(eP);if(!e)throw new Error("useInkeepConfig must be used within a ConfigProvider");return e},rP="conversationId",aP=K.createContext(null),oP=({children:e})=>{const t=function(){const[e,t]=K.useState(void 0),{aiChatSettings:n}=nP(),{shareChatUrlBasePath:r}=n;return K.useEffect((()=>{if(!r||"undefined"==typeof window)return;const e=e=>e.endsWith("/")?e.slice(0,-1):e,n=()=>{const{origin:n,pathname:a,search:o}=window.location,i=new URL(r),s=e(a),l=e(i.pathname);if(n===i.origin&&s===l){const e=new URLSearchParams(o).get(rP);e&&t(e)}};n();const a=()=>n();return window.addEventListener("popstate",a),()=>{window.removeEventListener("popstate",a)}}),[r]),e}(),{aiChatSettings:n}=nP(),r=n.chatId||t,[a,o]=K.useState(r);K.useEffect((()=>{o(r)}),[r]);const i={id:"",messages:[]},[s,l]=K.useState(i),c=()=>{l(i),o(void 0)},u=K.useMemo((()=>({conversation:s,setConversation:l,chatId:a,isSharedChat:!!t,resetConversation:c,setExternalChatId:o})),[s,a,t]);return Wh.jsx(aP.Provider,{value:u,children:e})},iP=()=>{const e=K.useContext(aP);if(!e)throw new Error("useInkeepConversation must be used within an InkeepConversationProvider");return e};async function sP(e,t,n,r){try{const a=`${r}/conversations`,o={id:e||void 0,type:"openai",...t},i=await fetch(a,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${n}`},body:JSON.stringify(o)});if(!i.ok){const e=await i.text();throw new Error(`Failed to log conversation: ${e}`)}return i.json()}catch(a){console.warn("Error in logConversation:",a)}}const lP="inkeepUsagePreferences",cP={defaultView:null,inkeepChatSessionId:null},uP={hasSwitchModeButtonJiggled:!1,userId:null,...cP},dP={set(e,t,n,r=365){try{if("cookie"===e){const e=new Date;void 0===n?(e.setTime(e.getTime()-1),document.cookie=`${lP}_${t}=; expires=${e.toUTCString()}; path=/`):(e.setTime(e.getTime()+24*r*60*60*1e3),document.cookie=`${lP}_${t}=${n}; expires=${e.toUTCString()}; path=/`)}else"undefined"!=typeof sessionStorage&&sessionStorage.setItem(`${lP}_${t}`,n?JSON.stringify(n):"")}catch(a){return null}},get(e,t){if("cookie"===e){const e=`${lP}_${t}=`,n=document.cookie.split(";");for(const t of n){const n=t.trim();if(n.startsWith(e))return n.substring(e.length)}return null}try{if("undefined"!=typeof sessionStorage){const e=sessionStorage.getItem(`${lP}_${t}`);return e?JSON.parse(e):null}}catch(n){return null}return null}},pP=()=>{const e=(()=>{try{if("undefined"==typeof localStorage)return!1;const e="__df709c5b-6651-43dc-94e7-d8dc899bf4e8__";return localStorage.setItem(e,"test_value"),localStorage.removeItem(e),!0}catch{return!1}})(),t=(()=>{if("undefined"==typeof document)return!1;document.cookie="testcookie=true; Path=/; Max-Age=1000";const e=document.cookie.includes("testcookie=true");return document.cookie="testcookie=; Path=/; Max-Age=-1000",e})();return e&&t},hP=K.createContext(void 0),fP=({children:e})=>{const{baseSettings:{userProperties:t,privacyPreferences:n}}=nP(),{optOutAllAnalytics:r,optOutAnalyticalCookies:a}=n,{browserStorage:o,setBrowserStorage:i}=(()=>{const{baseSettings:e,componentType:t}=nP(),{optOutAllAnalytics:n,optOutFunctionalCookies:r}=e.privacyPreferences,a=n||r||!pP()?"sessionStorage":"cookie",o=`${e.apiKey}-${t}`,i=e=>e in cP?`${e}-${o}`:e,s=Object.keys(uP).reduce(((e,t)=>{const n=i(t),r=dP.get(a,n);return{...e,[t]:r}}),{...uP}),[l,c]=K.useState(s);return K.useEffect((()=>{if(r)for(const e of Object.keys(uP)){const t=i(e);dP.set("cookie",t,null,-1)}}),[r]),{browserStorage:l,setBrowserStorage:(e,t,n=365)=>{const r=i(e);dP.set(a,r,t,n),c((n=>({...n,[e]:t})))}}})(),s=K.useMemo((()=>pP()),[]),l=K.useMemo((()=>!r&&!a&&s),[r,a,s]),c=K.useMemo((()=>{const e=r?"ANONYMOUS":t.id?"ID_PROVIDED":l?"COOKIED":"ANONYMOUS",n=r?void 0:t.id||l&&o.userId||Zh();return{identificationType:e,...r?{}:t,id:n}}),[t,r,l,o.userId]);return K.useEffect((()=>{i("userId",l?c.id:void 0)}),[l,c.id]),Wh.jsx(hP.Provider,{value:{userProperties:c},children:e})},mP=()=>{const e=K.useContext(hP);if(!e)throw new Error("useUser must be used within a UserProvider");return e};const gP=K.createContext(void 0),yP=({children:e})=>{const{baseSettings:t,componentType:n}=nP(),{apiKey:r,analyticsApiBaseUrl:a,tags:o,privacyPreferences:i,env:s,analyticsProperties:l}=t,{userProperties:c}=mP(),u=K.useMemo((()=>({widgetLibraryVersion:"0.5.99",componentType:n,tags:o})),[n,o]),d=!i.optOutAllAnalytics&&"development"!==s,p={logEvent:K.useCallback((async e=>{var n,o;const i={...u,...e.properties,...l},s={eventName:e.eventName,properties:i,userProperties:c},p=["modal_opened","modal_closed"].includes(e.eventName);if(d&&!p){if("conversation"in i&&!(null==(n=i.conversation)?void 0:n.id))return;!async function(e,t,n){try{const r=`${n}/events`,a={...e,type:e.eventName};if("searchQuery"in e.properties)a.entityType="search",a.searchQuery=e.properties.searchQuery;else if("messageId"in e.properties)a.entityType="message",a.messageId=e.properties.messageId;else{if(a.entityType="conversation",!e.properties.conversation)return;a.conversationId=e.properties.conversation.id}const o=await fetch(r,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${t}`},body:JSON.stringify(a)});if(!o.ok){const e=await o.text();throw new Error(`Failed to log event: ${e}`)}}catch(r){console.warn("Error in logEvent:",r)}}(s,r,a)}null==(o=t.onEvent)||o.call(t,s)}),[d,t,r,a,c,u,l])};return Wh.jsx(gP.Provider,{value:p,children:e})},bP=()=>{const e=K.useContext(gP);if(!e)throw new Error("useBaseEvents must be used within a BaseEventsProvider");return e},vP=K.createContext(void 0),kP=({children:e})=>{const{baseSettings:t,aiChatSettings:n}=nP(),{apiKey:r,analyticsApiBaseUrl:a,tags:o,privacyPreferences:{optOutAllAnalytics:i},env:s,analyticsProperties:l}=t,{conversationVisibility:c}=n,{userProperties:u}=mP(),{logEvent:d}=bP(),{conversation:p,setConversation:h,chatId:f,isSharedChat:m,setExternalChatId:g}=iP(),y=K.useRef(p),b=K.useRef(m?f:void 0);K.useEffect((()=>{y.current=p}),[p]),K.useEffect((()=>{b.current=m?f:void 0}),[f,m]);const v=K.useCallback((async e=>{const t=y.current;b.current&&(t.id="",g(void 0),b.current=void 0);const n=!i&&"development"!==s;let d=Object.assign({},t,{messages:e});if(n){const n=await sP(t.id,{messages:e,tags:o,userProperties:u,properties:l,visibility:c},r,a);n&&(d=n)}else d.id="conv_"+Zh(16);return d}),[a,r,o,u,i,s,l,g,c]),k={logEvent:K.useCallback((async(e,t)=>{let n=y.current;if(t){const e=y.current.messages||[];(t.length!==e.length||t.some(((t,n)=>{var r;return t.id!==(null==(r=e[n])?void 0:r.id)})))&&(n=await v(t),h(n),y.current=n)}const r={...e,properties:{conversation:n,...e.properties}};d(r)}),[d,v,i,s,l]),logConversation:v};return Wh.jsx(vP.Provider,{value:k,children:e})},wP=()=>{const e=K.useContext(vP);if(!e)throw new Error("useChatEvents must be used within a ChatEventsProvider");return e};function xP(e){const{displayName:t,goals:n,informationToCollect:r,guidance:a,botPersona:o,context:i}=e,s=SP({title:"Guidance",content:[EP(a)],note:o,depth:2}),l=_P(null==r?void 0:r.filter((e=>e.required)).map((e=>e.description))),c=_P(null==r?void 0:r.filter((e=>!e.required)).map((e=>e.description))),u=SP({title:"Required",content:[l],note:"IMPORTANT: This information is REQUIRED for this workflow. If not provided in the conversation, prompt the user to provide it and don't otherwise answer their question.",depth:3}),d=SP({title:"Optional",content:[c],depth:3}),p=SP({title:"Information to collect",content:[u,d],note:"This is information that should be collected from the user.",depth:2}),h=SP({title:"Context",content:[_P(i)],depth:2}),f=SP({title:"Workflow Name",content:[t],depth:2}),m=SP({title:"Goals",content:[EP(n)],depth:2});return SP({title:"Workflow",content:["I am a user being guided through a “workflow” defined by the organization that provides this chat experience.","**IMPORTANT: Follow the instructions outlined in this workflow. Follow the instructions in the workflow configuration below. Do not answer questions unrelated to the workflow.**",f,m,h,p,s],depth:1})}function EP(e){if(IP(e))return e.filter((e=>null!=e)).map(((e,t)=>`${t+1}. ${e}`)).join("\n")}function _P(e){if(IP(e))return e.filter((e=>null!=e)).map((e=>`- ${e}`)).join("\n")}function SP({title:e,content:t,note:n,depth:r=2}){const a=NP(t);if(!a&&!n)return;const o=`${"#".repeat(r)} ${e}\n`,i=NP([n,a]);return i?`${o}${i}\n`:void 0}function TP(e){if(!e)return;if(!IP(e))return;const t=e.map(((e,t)=>function({attachment:e,index:t}){const{title:n,content:r,contentType:a,context:o}=e,{contentInputLabel:i,type:s}=a,l=function(e){if("CODE"===(null==e?void 0:e.type))return e.language||"";return}(a),c=function(e,t){return t?`\`\`\`${t}\n${e}\n\`\`\``:e}(r,l),u=IP(o)?["\nAdditional Context:",NP(o)]:[],d=[`#### ATTACHMENT #${t+1}`,`Title: ${n}`,`Label: ${i}`,`Type: ${s}`,"Content:",c,...u].join("\n");return d}({attachment:e,index:t})));return NP(t)}function CP(e){return SP({title:"User-provided Attachments",content:["The user has provided the following attachments to their message:",TP(e)],depth:1})}function AP(e){if(!e.supportedInputs)return e;const t={...e};return t.supportedInputs=e.supportedInputs.map((e=>{const t={...e};return"MODAL"===t.type&&(t.workflowModalProps=void 0),t})),t}function NP(e){if(IP(e))return e.filter((e=>null!=e)).join("\n")}function IP(e){return Array.isArray(e)&&e.length>0}const RP=()=>{const e="undefined"==typeof window?new URL(""):new URL(window.location.href),t=new URLSearchParams(e.search);if(t.has(rP)){t.delete(rP);const n=t.toString(),r=n?`${e.origin}${e.pathname}?${n}`:`${e.origin}${e.pathname}`;"undefined"!=typeof window&&window.history.pushState({},"",r)}};var OP=e=>"checkbox"===e.type,PP=e=>e instanceof Date,DP=e=>null==e;const LP=e=>"object"==typeof e;var MP=e=>!DP(e)&&!Array.isArray(e)&&LP(e)&&!PP(e),FP=e=>MP(e)&&e.target?OP(e.target)?e.target.checked:e.target.value:e,jP=(e,t)=>e.has((e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e)(t)),BP="undefined"!=typeof window&&void 0!==window.HTMLElement&&"undefined"!=typeof document;function zP(e){let t;const n=Array.isArray(e),r="undefined"!=typeof FileList&&e instanceof FileList;if(e instanceof Date)t=new Date(e);else if(e instanceof Set)t=new Set(e);else{if(BP&&(e instanceof Blob||r)||!n&&!MP(e))return e;if(t=n?[]:{},n||(e=>{const t=e.constructor&&e.constructor.prototype;return MP(t)&&t.hasOwnProperty("isPrototypeOf")})(e))for(const n in e)e.hasOwnProperty(n)&&(t[n]=zP(e[n]));else t=e}return t}var HP=e=>Array.isArray(e)?e.filter(Boolean):[],UP=e=>void 0===e,$P=(e,t,n)=>{if(!t||!MP(e))return n;const r=HP(t.split(/[,[\].]+?/)).reduce(((e,t)=>DP(e)?e:e[t]),e);return UP(r)||r===e?UP(e[t])?n:e[t]:r},GP=e=>"boolean"==typeof e,VP=e=>/^\w*$/.test(e),qP=e=>HP(e.replace(/["|']|\]/g,"").split(/\.|\[/)),WP=(e,t,n)=>{let r=-1;const a=VP(t)?[t]:qP(t),o=a.length,i=o-1;for(;++r<o;){const t=a[r];let o=n;if(r!==i){const n=e[t];o=MP(n)||Array.isArray(n)?n:isNaN(+a[r+1])?{}:[]}if("__proto__"===t||"constructor"===t||"prototype"===t)return;e[t]=o,e=e[t]}return e};const YP="blur",KP="focusout",XP="change",QP="onBlur",ZP="onChange",JP="onSubmit",eD="onTouched",tD="all",nD="max",rD="min",aD="maxLength",oD="minLength",iD="pattern",sD="required",lD="validate",cD=X.createContext(null),uD=()=>X.useContext(cD);var dD=(e,t,n,r=!0)=>{const a={defaultValues:t._defaultValues};for(const o in e)Object.defineProperty(a,o,{get:()=>{const a=o;return t._proxyFormState[a]!==tD&&(t._proxyFormState[a]=!r||tD),n&&(n[a]=!0),e[a]}});return a},pD=e=>MP(e)&&!Object.keys(e).length,hD=(e,t,n,r)=>{n(e);const{name:a,...o}=e;return pD(o)||Object.keys(o).length>=Object.keys(t).length||Object.keys(o).find((e=>t[e]===(!r||tD)))},fD=e=>Array.isArray(e)?e:[e],mD=(e,t,n)=>!e||!t||e===t||fD(e).some((e=>e&&(n?e===t:e.startsWith(t)||t.startsWith(e))));function gD(e){const t=X.useRef(e);t.current=e,X.useEffect((()=>{const n=!e.disabled&&t.current.subject&&t.current.subject.subscribe({next:t.current.next});return()=>{n&&n.unsubscribe()}}),[e.disabled])}var yD=e=>"string"==typeof e,bD=(e,t,n,r,a)=>yD(e)?(r&&t.watch.add(e),$P(n,e,a)):Array.isArray(e)?e.map((e=>(r&&t.watch.add(e),$P(n,e)))):(r&&(t.watchAll=!0),n);function vD(e){const t=uD(),{name:n,disabled:r,control:a=t.control,shouldUnregister:o}=e,i=jP(a._names.array,n),s=function(e){const t=uD(),{control:n=t.control,name:r,defaultValue:a,disabled:o,exact:i}=e||{},s=X.useRef(r);s.current=r,gD({disabled:o,subject:n._subjects.values,next:e=>{mD(s.current,e.name,i)&&c(zP(bD(s.current,n._names,e.values||n._formValues,!1,a)))}});const[l,c]=X.useState(n._getWatch(r,a));return X.useEffect((()=>n._removeUnmounted())),l}({control:a,name:n,defaultValue:$P(a._formValues,n,$P(a._defaultValues,n,e.defaultValue)),exact:!0}),l=function(e){const t=uD(),{control:n=t.control,disabled:r,name:a,exact:o}=e||{},[i,s]=X.useState(n._formState),l=X.useRef(!0),c=X.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1}),u=X.useRef(a);return u.current=a,gD({disabled:r,next:e=>l.current&&mD(u.current,e.name,o)&&hD(e,c.current,n._updateFormState)&&s({...n._formState,...e}),subject:n._subjects.state}),X.useEffect((()=>(l.current=!0,c.current.isValid&&n._updateValid(!0),()=>{l.current=!1})),[n]),X.useMemo((()=>dD(i,n,c.current,!1)),[i,n])}({control:a,name:n,exact:!0}),c=X.useRef(a.register(n,{...e.rules,value:s,...GP(e.disabled)?{disabled:e.disabled}:{}})),u=X.useMemo((()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!$P(l.errors,n)},isDirty:{enumerable:!0,get:()=>!!$P(l.dirtyFields,n)},isTouched:{enumerable:!0,get:()=>!!$P(l.touchedFields,n)},isValidating:{enumerable:!0,get:()=>!!$P(l.validatingFields,n)},error:{enumerable:!0,get:()=>$P(l.errors,n)}})),[l,n]),d=X.useMemo((()=>({name:n,value:s,...GP(r)||l.disabled?{disabled:l.disabled||r}:{},onChange:e=>c.current.onChange({target:{value:FP(e),name:n},type:XP}),onBlur:()=>c.current.onBlur({target:{value:$P(a._formValues,n),name:n},type:YP}),ref:e=>{const t=$P(a._fields,n);t&&e&&(t._f.ref={focus:()=>e.focus(),select:()=>e.select(),setCustomValidity:t=>e.setCustomValidity(t),reportValidity:()=>e.reportValidity()})}})),[n,a._formValues,r,l.disabled,s,a._fields]);return X.useEffect((()=>{const e=a._options.shouldUnregister||o,t=(e,t)=>{const n=$P(a._fields,e);n&&n._f&&(n._f.mount=t)};if(t(n,!0),e){const e=zP($P(a._options.defaultValues,n));WP(a._defaultValues,n,e),UP($P(a._formValues,n))&&WP(a._formValues,n,e)}return!i&&a.register(n),()=>{(i?e&&!a._state.action:e)?a.unregister(n):t(n,!1)}}),[n,a,i,o]),X.useEffect((()=>{a._updateDisabledField({disabled:r,fields:a._fields,name:n})}),[r,n,a]),X.useMemo((()=>({field:d,formState:l,fieldState:u})),[d,l,u])}const kD=e=>e.render(vD(e));var wD=(e,t,n,r,a)=>t?{...n[e],types:{...n[e]&&n[e].types?n[e].types:{},[r]:a||!0}}:{},xD=e=>({isOnSubmit:!e||e===JP,isOnBlur:e===QP,isOnChange:e===ZP,isOnAll:e===tD,isOnTouch:e===eD}),ED=(e,t,n)=>!n&&(t.watchAll||t.watch.has(e)||[...t.watch].some((t=>e.startsWith(t)&&/^\.\w+/.test(e.slice(t.length)))));const _D=(e,t,n,r)=>{for(const a of n||Object.keys(e)){const n=$P(e,a);if(n){const{_f:e,...o}=n;if(e){if(e.refs&&e.refs[0]&&t(e.refs[0],a)&&!r)return!0;if(e.ref&&t(e.ref,e.name)&&!r)return!0;if(_D(o,t))break}else if(MP(o)&&_D(o,t))break}}};var SD=(e,t,n)=>{const r=fD($P(e,n));return WP(r,"root",t[n]),WP(e,n,r),e},TD=e=>"file"===e.type,CD=e=>"function"==typeof e,AD=e=>{if(!BP)return!1;const t=e?e.ownerDocument:0;return e instanceof(t&&t.defaultView?t.defaultView.HTMLElement:HTMLElement)},ND=e=>yD(e),ID=e=>"radio"===e.type,RD=e=>e instanceof RegExp;const OD={value:!1,isValid:!1},PD={value:!0,isValid:!0};var DD=e=>{if(Array.isArray(e)){if(e.length>1){const t=e.filter((e=>e&&e.checked&&!e.disabled)).map((e=>e.value));return{value:t,isValid:!!t.length}}return e[0].checked&&!e[0].disabled?e[0].attributes&&!UP(e[0].attributes.value)?UP(e[0].value)||""===e[0].value?PD:{value:e[0].value,isValid:!0}:PD:OD}return OD};const LD={isValid:!1,value:null};var MD=e=>Array.isArray(e)?e.reduce(((e,t)=>t&&t.checked&&!t.disabled?{isValid:!0,value:t.value}:e),LD):LD;function FD(e,t,n="validate"){if(ND(e)||Array.isArray(e)&&e.every(ND)||GP(e)&&!e)return{type:n,message:ND(e)?e:"",ref:t}}var jD=e=>MP(e)&&!RD(e)?e:{value:e,message:""},BD=async(e,t,n,r,a,o)=>{const{ref:i,refs:s,required:l,maxLength:c,minLength:u,min:d,max:p,pattern:h,validate:f,name:m,valueAsNumber:g,mount:y}=e._f,b=$P(n,m);if(!y||t.has(m))return{};const v=s?s[0]:i,k=e=>{a&&v.reportValidity&&(v.setCustomValidity(GP(e)?"":e||""),v.reportValidity())},w={},x=ID(i),E=OP(i),_=x||E,S=(g||TD(i))&&UP(i.value)&&UP(b)||AD(i)&&""===i.value||""===b||Array.isArray(b)&&!b.length,T=wD.bind(null,m,r,w),C=(e,t,n,r=aD,a=oD)=>{const o=e?t:n;w[m]={type:e?r:a,message:o,ref:i,...T(e?r:a,o)}};if(o?!Array.isArray(b)||!b.length:l&&(!_&&(S||DP(b))||GP(b)&&!b||E&&!DD(s).isValid||x&&!MD(s).isValid)){const{value:e,message:t}=ND(l)?{value:!!l,message:l}:jD(l);if(e&&(w[m]={type:sD,message:t,ref:v,...T(sD,t)},!r))return k(t),w}if(!(S||DP(d)&&DP(p))){let e,t;const n=jD(p),a=jD(d);if(DP(b)||isNaN(b)){const r=i.valueAsDate||new Date(b),o=e=>new Date((new Date).toDateString()+" "+e),s="time"==i.type,l="week"==i.type;yD(n.value)&&b&&(e=s?o(b)>o(n.value):l?b>n.value:r>new Date(n.value)),yD(a.value)&&b&&(t=s?o(b)<o(a.value):l?b<a.value:r<new Date(a.value))}else{const r=i.valueAsNumber||(b?+b:b);DP(n.value)||(e=r>n.value),DP(a.value)||(t=r<a.value)}if((e||t)&&(C(!!e,n.message,a.message,nD,rD),!r))return k(w[m].message),w}if((c||u)&&!S&&(yD(b)||o&&Array.isArray(b))){const e=jD(c),t=jD(u),n=!DP(e.value)&&b.length>+e.value,a=!DP(t.value)&&b.length<+t.value;if((n||a)&&(C(n,e.message,t.message),!r))return k(w[m].message),w}if(h&&!S&&yD(b)){const{value:e,message:t}=jD(h);if(RD(e)&&!b.match(e)&&(w[m]={type:iD,message:t,ref:i,...T(iD,t)},!r))return k(t),w}if(f)if(CD(f)){const e=FD(await f(b,n),v);if(e&&(w[m]={...e,...T(lD,e.message)},!r))return k(e.message),w}else if(MP(f)){let e={};for(const t in f){if(!pD(e)&&!r)break;const a=FD(await f[t](b,n),v,t);a&&(e={...a,...T(t,a.message)},k(a.message),r&&(w[m]=e))}if(!pD(e)&&(w[m]={ref:v,...e},!r))return w}return k(!0),w};function zD(e,t){const n=Array.isArray(t)?t:VP(t)?[t]:qP(t),r=1===n.length?e:function(e,t){const n=t.slice(0,-1).length;let r=0;for(;r<n;)e=UP(e)?r++:e[t[r++]];return e}(e,n),a=n.length-1,o=n[a];return r&&delete r[o],0!==a&&(MP(r)&&pD(r)||Array.isArray(r)&&function(e){for(const t in e)if(e.hasOwnProperty(t)&&!UP(e[t]))return!1;return!0}(r))&&zD(e,n.slice(0,-1)),e}var HD=()=>{let e=[];return{get observers(){return e},next:t=>{for(const n of e)n.next&&n.next(t)},subscribe:t=>(e.push(t),{unsubscribe:()=>{e=e.filter((e=>e!==t))}}),unsubscribe:()=>{e=[]}}},UD=e=>DP(e)||!LP(e);function $D(e,t){if(UD(e)||UD(t))return e===t;if(PP(e)&&PP(t))return e.getTime()===t.getTime();const n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(const a of n){const n=e[a];if(!r.includes(a))return!1;if("ref"!==a){const e=t[a];if(PP(n)&&PP(e)||MP(n)&&MP(e)||Array.isArray(n)&&Array.isArray(e)?!$D(n,e):n!==e)return!1}}return!0}var GD=e=>"select-multiple"===e.type,VD=e=>AD(e)&&e.isConnected,qD=e=>{for(const t in e)if(CD(e[t]))return!0;return!1};function WD(e,t={}){const n=Array.isArray(e);if(MP(e)||n)for(const r in e)Array.isArray(e[r])||MP(e[r])&&!qD(e[r])?(t[r]=Array.isArray(e[r])?[]:{},WD(e[r],t[r])):DP(e[r])||(t[r]=!0);return t}function YD(e,t,n){const r=Array.isArray(e);if(MP(e)||r)for(const a in e)Array.isArray(e[a])||MP(e[a])&&!qD(e[a])?UP(t)||UD(n[a])?n[a]=Array.isArray(e[a])?WD(e[a],[]):{...WD(e[a])}:YD(e[a],DP(t)?{}:t[a],n[a]):n[a]=!$D(e[a],t[a]);return n}var KD=(e,t)=>YD(e,t,WD(t)),XD=(e,{valueAsNumber:t,valueAsDate:n,setValueAs:r})=>UP(e)?e:t?""===e?NaN:e?+e:e:n&&yD(e)?new Date(e):r?r(e):e;function QD(e){const t=e.ref;return TD(t)?t.files:ID(t)?MD(e.refs).value:GD(t)?[...t.selectedOptions].map((({value:e})=>e)):OP(t)?DD(e.refs).value:XD(UP(t.value)?e.ref.value:t.value,e)}var ZD=e=>UP(e)?e:RD(e)?e.source:MP(e)?RD(e.value)?e.value.source:e.value:e;const JD="AsyncFunction";function eL(e,t,n){const r=$P(e,n);if(r||VP(n))return{error:r,name:n};const a=n.split(".");for(;a.length;){const r=a.join("."),o=$P(t,r),i=$P(e,r);if(o&&!Array.isArray(o)&&n!==r)return{name:n};if(i&&i.type)return{name:r,error:i};a.pop()}return{name:n}}const tL={mode:JP,reValidateMode:ZP,shouldFocusError:!0};function nL(e={}){let t,n={...tL,...e},r={submitCount:0,isDirty:!1,isLoading:CD(n.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:n.errors||{},disabled:n.disabled||!1},a={},o=(MP(n.defaultValues)||MP(n.values))&&zP(n.defaultValues||n.values)||{},i=n.shouldUnregister?{}:zP(o),s={action:!1,mount:!1,watch:!1},l={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set},c=0;const u={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1},d={values:HD(),array:HD(),state:HD()},p=xD(n.mode),h=xD(n.reValidateMode),f=n.criteriaMode===tD,m=async e=>{if(!n.disabled&&(u.isValid||e)){const e=n.resolver?pD((await k()).errors):await w(a,!0);e!==r.isValid&&d.state.next({isValid:e})}},g=(e,t)=>{n.disabled||!u.isValidating&&!u.validatingFields||((e||Array.from(l.mount)).forEach((e=>{e&&(t?WP(r.validatingFields,e,t):zD(r.validatingFields,e))})),d.state.next({validatingFields:r.validatingFields,isValidating:!pD(r.validatingFields)}))},y=(e,t,n,r)=>{const l=$P(a,e);if(l){const a=$P(i,e,UP(n)?$P(o,e):n);UP(a)||r&&r.defaultChecked||t?WP(i,e,t?a:QD(l._f)):_(e,a),s.mount&&m()}},b=(e,t,i,s,l)=>{let c=!1,p=!1;const h={name:e};if(!n.disabled){const n=!!($P(a,e)&&$P(a,e)._f&&$P(a,e)._f.disabled);if(!i||s){u.isDirty&&(p=r.isDirty,r.isDirty=h.isDirty=x(),c=p!==h.isDirty);const a=n||$D($P(o,e),t);p=!(n||!$P(r.dirtyFields,e)),a||n?zD(r.dirtyFields,e):WP(r.dirtyFields,e,!0),h.dirtyFields=r.dirtyFields,c=c||u.dirtyFields&&p!==!a}if(i){const t=$P(r.touchedFields,e);t||(WP(r.touchedFields,e,i),h.touchedFields=r.touchedFields,c=c||u.touchedFields&&t!==i)}c&&l&&d.state.next(h)}return c?h:{}},v=(e,a,o,i)=>{const s=$P(r.errors,e),l=u.isValid&&GP(a)&&r.isValid!==a;var p;if(n.delayError&&o?(p=()=>((e,t)=>{WP(r.errors,e,t),d.state.next({errors:r.errors})})(e,o),t=e=>{clearTimeout(c),c=setTimeout(p,e)},t(n.delayError)):(clearTimeout(c),t=null,o?WP(r.errors,e,o):zD(r.errors,e)),(o?!$D(s,o):s)||!pD(i)||l){const t={...i,...l&&GP(a)?{isValid:a}:{},errors:r.errors,name:e};r={...r,...t},d.state.next(t)}},k=async e=>{g(e,!0);const t=await n.resolver(i,n.context,((e,t,n,r)=>{const a={};for(const o of e){const e=$P(t,o);e&&WP(a,o,e._f)}return{criteriaMode:n,names:[...e],fields:a,shouldUseNativeValidation:r}})(e||l.mount,a,n.criteriaMode,n.shouldUseNativeValidation));return g(e),t},w=async(e,t,a={valid:!0})=>{for(const s in e){const c=e[s];if(c){const{_f:e,...d}=c;if(e){const d=l.array.has(e.name),p=c._f&&(!!(o=c._f)&&!!o.validate&&!!(CD(o.validate)&&o.validate.constructor.name===JD||MP(o.validate)&&Object.values(o.validate).find((e=>e.constructor.name===JD))));p&&u.validatingFields&&g([s],!0);const h=await BD(c,l.disabled,i,f,n.shouldUseNativeValidation&&!t,d);if(p&&u.validatingFields&&g([s]),h[e.name]&&(a.valid=!1,t))break;!t&&($P(h,e.name)?d?SD(r.errors,h,e.name):WP(r.errors,e.name,h[e.name]):zD(r.errors,e.name))}!pD(d)&&await w(d,t,a)}}var o;return a.valid},x=(e,t)=>!n.disabled&&(e&&t&&WP(i,e,t),!$D(I(),o)),E=(e,t,n)=>bD(e,l,{...s.mount?i:UP(t)?o:yD(e)?{[e]:t}:t},n,t),_=(e,t,n={})=>{const r=$P(a,e);let o=t;if(r){const n=r._f;n&&(!n.disabled&&WP(i,e,XD(t,n)),o=AD(n.ref)&&DP(t)?"":t,GD(n.ref)?[...n.ref.options].forEach((e=>e.selected=o.includes(e.value))):n.refs?OP(n.ref)?n.refs.length>1?n.refs.forEach((e=>(!e.defaultChecked||!e.disabled)&&(e.checked=Array.isArray(o)?!!o.find((t=>t===e.value)):o===e.value))):n.refs[0]&&(n.refs[0].checked=!!o):n.refs.forEach((e=>e.checked=e.value===o)):TD(n.ref)?n.ref.value="":(n.ref.value=o,n.ref.type||d.values.next({name:e,values:{...i}})))}(n.shouldDirty||n.shouldTouch)&&b(e,o,n.shouldTouch,n.shouldDirty,!0),n.shouldValidate&&N(e)},S=(e,t,n)=>{for(const r in t){const o=t[r],i=`${e}.${r}`,s=$P(a,i);(l.array.has(e)||MP(o)||s&&!s._f)&&!PP(o)?S(i,o,n):_(i,o,n)}},T=(e,t,n={})=>{const c=$P(a,e),p=l.array.has(e),h=zP(t);WP(i,e,h),p?(d.array.next({name:e,values:{...i}}),(u.isDirty||u.dirtyFields)&&n.shouldDirty&&d.state.next({name:e,dirtyFields:KD(o,i),isDirty:x(e,h)})):!c||c._f||DP(h)?_(e,h,n):S(e,h,n),ED(e,l)&&d.state.next({...r}),d.values.next({name:s.mount?e:void 0,values:{...i}})},C=async e=>{s.mount=!0;const o=e.target;let c=o.name,y=!0;const x=$P(a,c),E=e=>{y=Number.isNaN(e)||PP(e)&&isNaN(e.getTime())||$D(e,$P(i,c,e))};if(x){let s,S;const T=o.type?QD(x._f):FP(e),C=e.type===YP||e.type===KP,A=!((_=x._f).mount&&(_.required||_.min||_.max||_.maxLength||_.minLength||_.pattern||_.validate)||n.resolver||$P(r.errors,c)||x._f.deps)||((e,t,n,r,a)=>!a.isOnAll&&(!n&&a.isOnTouch?!(t||e):(n?r.isOnBlur:a.isOnBlur)?!e:!(n?r.isOnChange:a.isOnChange)||e))(C,$P(r.touchedFields,c),r.isSubmitted,h,p),I=ED(c,l,C);WP(i,c,T),C?(x._f.onBlur&&x._f.onBlur(e),t&&t(0)):x._f.onChange&&x._f.onChange(e);const R=b(c,T,C,!1),O=!pD(R)||I;if(!C&&d.values.next({name:c,type:e.type,values:{...i}}),A)return u.isValid&&("onBlur"===n.mode&&C?m():C||m()),O&&d.state.next({name:c,...I?{}:R});if(!C&&I&&d.state.next({...r}),n.resolver){const{errors:e}=await k([c]);if(E(T),y){const t=eL(r.errors,a,c),n=eL(e,a,t.name||c);s=n.error,c=n.name,S=pD(e)}}else g([c],!0),s=(await BD(x,l.disabled,i,f,n.shouldUseNativeValidation))[c],g([c]),E(T),y&&(s?S=!1:u.isValid&&(S=await w(a,!0)));y&&(x._f.deps&&N(x._f.deps),v(c,S,s,R))}var _},A=(e,t)=>{if($P(r.errors,t)&&e.focus)return e.focus(),1},N=async(e,t={})=>{let o,i;const s=fD(e);if(n.resolver){const t=await(async e=>{const{errors:t}=await k(e);if(e)for(const n of e){const e=$P(t,n);e?WP(r.errors,n,e):zD(r.errors,n)}else r.errors=t;return t})(UP(e)?e:s);o=pD(t),i=e?!s.some((e=>$P(t,e))):o}else e?(i=(await Promise.all(s.map((async e=>{const t=$P(a,e);return await w(t&&t._f?{[e]:t}:t)})))).every(Boolean),(i||r.isValid)&&m()):i=o=await w(a);return d.state.next({...!yD(e)||u.isValid&&o!==r.isValid?{}:{name:e},...n.resolver||!e?{isValid:o}:{},errors:r.errors}),t.shouldFocus&&!i&&_D(a,A,e?s:l.mount),i},I=e=>{const t={...s.mount?i:o};return UP(e)?t:yD(e)?$P(t,e):e.map((e=>$P(t,e)))},R=(e,t)=>({invalid:!!$P((t||r).errors,e),isDirty:!!$P((t||r).dirtyFields,e),error:$P((t||r).errors,e),isValidating:!!$P(r.validatingFields,e),isTouched:!!$P((t||r).touchedFields,e)}),O=(e,t,n)=>{const o=($P(a,e,{_f:{}})._f||{}).ref,i=$P(r.errors,e)||{},{ref:s,message:l,type:c,...u}=i;WP(r.errors,e,{...u,...t,ref:o}),d.state.next({name:e,errors:r.errors,isValid:!1}),n&&n.shouldFocus&&o&&o.focus&&o.focus()},P=(e,t={})=>{for(const s of e?fD(e):l.mount)l.mount.delete(s),l.array.delete(s),t.keepValue||(zD(a,s),zD(i,s)),!t.keepError&&zD(r.errors,s),!t.keepDirty&&zD(r.dirtyFields,s),!t.keepTouched&&zD(r.touchedFields,s),!t.keepIsValidating&&zD(r.validatingFields,s),!n.shouldUnregister&&!t.keepDefaultValue&&zD(o,s);d.values.next({values:{...i}}),d.state.next({...r,...t.keepDirty?{isDirty:x()}:{}}),!t.keepIsValid&&m()},D=({disabled:e,name:t,field:n,fields:r})=>{(GP(e)&&s.mount||e||l.disabled.has(t))&&(e?l.disabled.add(t):l.disabled.delete(t),b(t,QD(n?n._f:$P(r,t)._f),!1,!1,!0))},L=(e,t={})=>{let r=$P(a,e);const i=GP(t.disabled)||GP(n.disabled);return WP(a,e,{...r||{},_f:{...r&&r._f?r._f:{ref:{name:e}},name:e,mount:!0,...t}}),l.mount.add(e),r?D({field:r,disabled:GP(t.disabled)?t.disabled:n.disabled,name:e}):y(e,!0,t.value),{...i?{disabled:t.disabled||n.disabled}:{},...n.progressive?{required:!!t.required,min:ZD(t.min),max:ZD(t.max),minLength:ZD(t.minLength),maxLength:ZD(t.maxLength),pattern:ZD(t.pattern)}:{},name:e,onChange:C,onBlur:C,ref:i=>{if(i){L(e,t),r=$P(a,e);const n=UP(i.value)&&i.querySelectorAll&&i.querySelectorAll("input,select,textarea")[0]||i,s=(e=>ID(e)||OP(e))(n),l=r._f.refs||[];if(s?l.find((e=>e===n)):n===r._f.ref)return;WP(a,e,{_f:{...r._f,...s?{refs:[...l.filter(VD),n,...Array.isArray($P(o,e))?[{}]:[]],ref:{type:n.type,name:e}}:{ref:n}}}),y(e,!1,void 0,n)}else r=$P(a,e,{}),r._f&&(r._f.mount=!1),(n.shouldUnregister||t.shouldUnregister)&&(!jP(l.array,e)||!s.action)&&l.unMount.add(e)}}},M=()=>n.shouldFocusError&&_D(a,A,l.mount),F=(e,t)=>async o=>{let s;o&&(o.preventDefault&&o.preventDefault(),o.persist&&o.persist());let c=zP(i);if(l.disabled.size)for(const e of l.disabled)WP(c,e,void 0);if(d.state.next({isSubmitting:!0}),n.resolver){const{errors:e,values:t}=await k();r.errors=e,c=t}else await w(a);if(zD(r.errors,"root"),pD(r.errors)){d.state.next({errors:{}});try{await e(c,o)}catch(u){s=u}}else t&&await t({...r.errors},o),M(),setTimeout(M);if(d.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:pD(r.errors)&&!s,submitCount:r.submitCount+1,errors:r.errors}),s)throw s},j=(e,t={})=>{const c=e?zP(e):o,p=zP(c),h=pD(e),f=h?o:p;if(t.keepDefaultValues||(o=c),!t.keepValues){if(t.keepDirtyValues){const e=new Set([...l.mount,...Object.keys(KD(o,i))]);for(const t of Array.from(e))$P(r.dirtyFields,t)?WP(f,t,$P(i,t)):T(t,$P(f,t))}else{if(BP&&UP(e))for(const e of l.mount){const t=$P(a,e);if(t&&t._f){const e=Array.isArray(t._f.refs)?t._f.refs[0]:t._f.ref;if(AD(e)){const t=e.closest("form");if(t){t.reset();break}}}}a={}}i=n.shouldUnregister?t.keepDefaultValues?zP(o):{}:zP(f),d.array.next({values:{...f}}),d.values.next({values:{...f}})}l={mount:t.keepDirtyValues?l.mount:new Set,unMount:new Set,array:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:""},s.mount=!u.isValid||!!t.keepIsValid||!!t.keepDirtyValues,s.watch=!!n.shouldUnregister,d.state.next({submitCount:t.keepSubmitCount?r.submitCount:0,isDirty:!h&&(t.keepDirty?r.isDirty:!(!t.keepDefaultValues||$D(e,o))),isSubmitted:!!t.keepIsSubmitted&&r.isSubmitted,dirtyFields:h?{}:t.keepDirtyValues?t.keepDefaultValues&&i?KD(o,i):r.dirtyFields:t.keepDefaultValues&&e?KD(o,e):t.keepDirty?r.dirtyFields:{},touchedFields:t.keepTouched?r.touchedFields:{},errors:t.keepErrors?r.errors:{},isSubmitSuccessful:!!t.keepIsSubmitSuccessful&&r.isSubmitSuccessful,isSubmitting:!1})},B=(e,t)=>j(CD(e)?e(i):e,t);return{control:{register:L,unregister:P,getFieldState:R,handleSubmit:F,setError:O,_executeSchema:k,_getWatch:E,_getDirty:x,_updateValid:m,_removeUnmounted:()=>{for(const e of l.unMount){const t=$P(a,e);t&&(t._f.refs?t._f.refs.every((e=>!VD(e))):!VD(t._f.ref))&&P(e)}l.unMount=new Set},_updateFieldArray:(e,t=[],l,c,p=!0,h=!0)=>{if(c&&l&&!n.disabled){if(s.action=!0,h&&Array.isArray($P(a,e))){const t=l($P(a,e),c.argA,c.argB);p&&WP(a,e,t)}if(h&&Array.isArray($P(r.errors,e))){const t=l($P(r.errors,e),c.argA,c.argB);p&&WP(r.errors,e,t),((e,t)=>{!HP($P(e,t)).length&&zD(e,t)})(r.errors,e)}if(u.touchedFields&&h&&Array.isArray($P(r.touchedFields,e))){const t=l($P(r.touchedFields,e),c.argA,c.argB);p&&WP(r.touchedFields,e,t)}u.dirtyFields&&(r.dirtyFields=KD(o,i)),d.state.next({name:e,isDirty:x(e,t),dirtyFields:r.dirtyFields,errors:r.errors,isValid:r.isValid})}else WP(i,e,t)},_updateDisabledField:D,_getFieldArray:e=>HP($P(s.mount?i:o,e,n.shouldUnregister?$P(o,e,[]):[])),_reset:j,_resetDefaultValues:()=>CD(n.defaultValues)&&n.defaultValues().then((e=>{B(e,n.resetOptions),d.state.next({isLoading:!1})})),_updateFormState:e=>{r={...r,...e}},_disableForm:e=>{GP(e)&&(d.state.next({disabled:e}),_D(a,((t,n)=>{const r=$P(a,n);r&&(t.disabled=r._f.disabled||e,Array.isArray(r._f.refs)&&r._f.refs.forEach((t=>{t.disabled=r._f.disabled||e})))}),0,!1))},_subjects:d,_proxyFormState:u,_setErrors:e=>{r.errors=e,d.state.next({errors:r.errors,isValid:!1})},get _fields(){return a},get _formValues(){return i},get _state(){return s},set _state(e){s=e},get _defaultValues(){return o},get _names(){return l},set _names(e){l=e},get _formState(){return r},set _formState(e){r=e},get _options(){return n},set _options(e){n={...n,...e}}},trigger:N,register:L,handleSubmit:F,watch:(e,t)=>CD(e)?d.values.subscribe({next:n=>e(E(void 0,t),n)}):E(e,t,!0),setValue:T,getValues:I,reset:B,resetField:(e,t={})=>{$P(a,e)&&(UP(t.defaultValue)?T(e,zP($P(o,e))):(T(e,t.defaultValue),WP(o,e,zP(t.defaultValue))),t.keepTouched||zD(r.touchedFields,e),t.keepDirty||(zD(r.dirtyFields,e),r.isDirty=t.defaultValue?x(e,zP($P(o,e))):x()),t.keepError||(zD(r.errors,e),u.isValid&&m()),d.state.next({...r}))},clearErrors:e=>{e&&fD(e).forEach((e=>zD(r.errors,e))),d.state.next({errors:e?r.errors:{}})},unregister:P,setError:O,setFocus:(e,t={})=>{const n=$P(a,e),r=n&&n._f;if(r){const e=r.refs?r.refs[0]:r.ref;e.focus&&(e.focus(),t.shouldSelect&&CD(e.select)&&e.select())}},getFieldState:R}}function rL(e={}){const t=X.useRef(void 0),n=X.useRef(void 0),[r,a]=X.useState({isDirty:!1,isValidating:!1,isLoading:CD(e.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1,defaultValues:CD(e.defaultValues)?void 0:e.defaultValues});t.current||(t.current={...nL(e),formState:r});const o=t.current.control;return o._options=e,gD({subject:o._subjects.state,next:e=>{hD(e,o._proxyFormState,o._updateFormState,!0)&&a({...o._formState})}}),X.useEffect((()=>o._disableForm(e.disabled)),[o,e.disabled]),X.useEffect((()=>{if(o._proxyFormState.isDirty){const e=o._getDirty();e!==r.isDirty&&o._subjects.state.next({isDirty:e})}}),[o,r.isDirty]),X.useEffect((()=>{e.values&&!$D(e.values,n.current)?(o._reset(e.values,o._options.resetOptions),n.current=e.values,a((e=>({...e})))):o._resetDefaultValues()}),[e.values,o]),X.useEffect((()=>{e.errors&&o._setErrors(e.errors)}),[e.errors,o]),X.useEffect((()=>{o._state.mount||(o._updateValid(),o._state.mount=!0),o._state.watch&&(o._state.watch=!1,o._subjects.state.next({...o._formState})),o._removeUnmounted()})),X.useEffect((()=>{e.shouldUnregister&&o._subjects.values.next({values:o._getWatch()})}),[e.shouldUnregister,o]),t.current.formState=dD(r,o),t.current}const aL=K.createContext(void 0),oL=({children:e,modal:t})=>Wh.jsx(aL.Provider,{value:t,children:e}),iL=()=>K.useContext(aL),sL={text:"",email:"",checkbox:!1,textarea:"",file:void 0,select:""};function lL(e){return e?null==e?void 0:e.reduce(((e,t)=>("defaultValue"in t&&t.defaultValue?e[t.name]=t.defaultValue:t.inputType&&(e[t.name]=sL[t.inputType]),e)),{}):{}}const cL=K.createContext(void 0);const uL=({children:e})=>{const t=function(){var e;const[t,n]=K.useState(null),[r,a]=K.useState(null),[o,i]=K.useState(!1),{conversation:s}=iP(),l=iL(),{logEvent:c}=wP(),u=()=>{var e;n(null),a(null),i(!1),"close_modal"===(null==(e=null==t?void 0:t.buttons.close)?void 0:e.action)&&(null==l||l.setOpen(!1))},d=K.useMemo((()=>null==t?void 0:t.fields.map((e=>{const t={...e};return"_type"in e&&"include_chat_session"===e._type&&(t.inputType="checkbox",s.id?(t.isHidden=e.isHidden,t.isRequired=e.isRequired):(t.isHidden=!0,t.isRequired=!1)),t}))),[null==t?void 0:t.fields,s.id]),p=null==d?void 0:d.find((e=>"_type"in e&&"include_chat_session"===e._type)),h=K.useMemo((()=>lL(d)),[d]),{control:f,handleSubmit:m,formState:{errors:g,isSubmitting:y},setError:b,reset:v}=rL({defaultValues:h});K.useEffect((()=>{h&&v(h)}),[v,h]);const k=m((async e=>{const n=s.id&&p&&e[p.name]?s:null;try{await(null==t?void 0:t.buttons.submit.onSubmit({values:e,conversation:n})),r&&c({eventName:"user_escalation_indicated",properties:{escalationType:"support_form",getHelpOptionName:r.name,conversation:n||s}}),i(!0),(null==t?void 0:t.successView)||u()}catch(a){b("root.serverError",{message:a instanceof Error?a.message:"Something went wrong."})}})),w=null==(e=null==g?void 0:g.root)?void 0:e.serverError;return{form:t,openForm:(e,t)=>{n(e),a(t||null)},closeForm:u,handleSubmit:k,isSuccess:o,isSubmitting:y,formError:w,fields:d,errors:g,control:f,defaultValues:h}}();return Wh.jsx(cL.Provider,{value:t,children:e})},dL=()=>{const e=K.useContext(cL);if(!e)throw new Error("useChatForm must be used within a ChatFormProvider");return e},pL=K.createContext(void 0),hL=({children:e,widget:t})=>Wh.jsx(pL.Provider,{value:t,children:e}),fL=()=>K.useContext(pL),mL=e=>{const[t,n]=K.useState(!1);return K.useEffect((()=>{const t=window.matchMedia(e);n(t.matches);const r=e=>n(e.matches);return t.addEventListener("change",r),()=>t.removeEventListener("change",r)}),[e]),t},gL=new TextEncoder;async function yL(e,t){return n=await async function(e,t){return crypto.subtle.digest(e.toUpperCase(),"string"==typeof t?gL.encode(t):new Uint8Array(t))}(e,t),[...new Uint8Array(n)].map((e=>e.toString(16).padStart(2,"0"))).join("");var n}const bL={getSolution:async()=>{},prefetchSolution:()=>{},invalidateSolution:()=>{}},vL=async e=>{try{const t=await fetch(e,{method:"GET"});if(!t.ok)throw new Error(`Failed to fetch challenge: ${t.statusText}`);const n=await t.json(),{challenge:r,algorithm:a,salt:o,maxnumber:i}=n,{promise:s}=await function(e,t,n="SHA-256",r=1e6,a=0){const o=new AbortController,i=Date.now();return{promise:(async()=>{for(let s=a;s<=r;s+=1){if(o.signal.aborted)return null;if(await yL(n,t+s)===e)return{number:s,took:Date.now()-i}}return null})(),controller:o}}(r,o,a,i),l=await s||void 0;if(!l)throw new Error("Challenge not solved");return{number:l.number,...n}}catch(t){console.warn("Error solving captcha:",t)}},kL={type:"function",function:{name:"provideLinks",description:"Provides links",parameters:{type:"object",properties:{links:{anyOf:[{type:"array",items:{type:"object",properties:{label:{type:["string","null"]},url:{type:"string"},title:{type:["string","null"]},description:{type:["string","null"]},type:{anyOf:[{anyOf:[{type:"string",enum:["documentation","site","discourse_post","github_issue","github_discussion","stackoverflow_question","discord_forum_post","discord_message","custom_question_answer"]},{type:"string"}]},{type:"null"}]},breadcrumbs:{anyOf:[{type:"array",items:{type:"string"}},{type:"null"}]}},required:["url"],additionalProperties:!0}},{type:"null"}]},text:{type:"string"}},required:["text"],additionalProperties:!1,$schema:"http://json-schema.org/draft-07/schema#"},function:e=>e,parse:JSON.parse}},wL=e=>{if("string"==typeof e)try{return JSON.parse(e)}catch(X4){return e}return e},xL=(...e)=>(...t)=>{for(const n of e)null==n||n(...t)},EL=e=>"string"==typeof e;function _L(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").replace(/([A-Z])([A-Z][a-z])/g,"$1-$2").replace(/__/g,"__").toLowerCase()}const SL=e=>e?"":void 0;function TL(e){const t=e.split(" "),n=t[0]??"",r=t.length>1?t[t.length-1]:"";return n&&r?`${n.charAt(0)}${r.charAt(0)}`:n.charAt(0)}function CL(e,t){return"function"==typeof e?e(t):e}const AL=e=>"string"==typeof e.content?e.content:e.content[0].text,NL=()=>{const{chatId:e,isSharedChat:t,setConversation:n,conversation:r,resetConversation:a}=iP(),{baseSettings:o,aiChatSettings:i}=nP(),{aiApiBaseUrl:s,shouldBypassCaptcha:l,filters:c}=o,u=iL(),{getSolution:d,prefetchSolution:p,invalidateSolution:h}=(({fetchUrl:e,shouldBypassCaptcha:t=!1,shouldMakeInitialRequest:n=!0})=>{if(t)return bL;const r=K.useRef(null),a=K.useCallback((()=>{r.current||(r.current=vL(e))}),[e]),o=K.useCallback((async()=>{let t=await r.current;return t||(r.current=vL(e),t=await r.current),r.current=null,t}),[e]),i=K.useCallback((()=>{r.current=null}),[]);return K.useEffect((()=>{n&&a()}),[a,n]),{getSolution:o,prefetchSolution:a,invalidateSolution:i}})({fetchUrl:`${s}/v1/challenge`,shouldBypassCaptcha:l,shouldMakeInitialRequest:!u||u.isOpen}),f=new fb({baseURL:`${s}/v1`,apiKey:o.apiKey??"",dangerouslyAllowBrowser:!0}),{onInputMessageChange:m,getTools:g,prompts:y,model:b,filters:v,onToolCall:k}=i,[w,x]=K.useState(""),E=K.useRef(null);K.useEffect((()=>{null==m||m(w)}),[w]);const[_,S]=K.useState([]),[T,C]=K.useState(!1),[A,N]=K.useState(!1),[I,R]=K.useState(null),[O,P]=K.useState(null),[D,L]=K.useState([]),[M,F]=K.useState({}),j=K.useRef([]),B=K.useRef(null),{logEvent:z}=wP(),H=null==y?void 0:y.map(((e,t)=>({id:`system-${Date.now().toString()}-${Zh(4)}-${t}`,role:"system",content:e}))),[U,$]=K.useState(!!e);K.useEffect((()=>{if(e){const{apiKey:t,analyticsApiBaseUrl:r}=o;(async function(e,t,n){try{const r=`${n}/conversations/${e}`,a=await fetch(r,{headers:{"Content-Type":"application/json",Authorization:`Bearer ${t}`}});if(!a.ok){const e=await a.text();throw new Error(`Failed to get conversation: ${e}`)}return a.json()}catch(I){console.warn("Error in getConversation:",I)}})(e,t,r).then((e=>{if(e){z({eventName:"shared_chat_loaded",properties:{conversation:e}}),$(!1),n({...e});const t=e.messages.map((e=>({...e,content:wL(e.content)})));S(t),j.current=t}}))}}),[e]);const G=e=>{R(e),S((t=>{const n=[...t],r=n[n.length-1];return r&&(r.content=(e=>{switch(e.code){case 400:return e.message;case 403:return`There seems to be a configuration error. Please contact ${o.organizationDisplayName??"Administrator"}`;default:return"Hmm.. \n\nIt seems I might be having some issues right now. Please clear the chat and try again."}})(e)),n})),C(!1),N(!1),h(),p()},V=!w.trim()&&!D.length||T,q=async(n=w)=>{if(V&&(!n||0===n.trim().length))return;C(!0);const a=O?2===_.length:0===_.length,o=function(e,t,n){if(!e)return;const r=n?xP(e):"",a=CP(t),o={workflow:AP(e),attachments:t};return{context:NP([r,a]),attributes:o}}(O,D,a);let i;const s=CP(D);i=D.length&&s?[{type:"text",text:s}]:n;const u={id:`${Date.now().toString()}-${Zh(4)}-1`,role:"user",content:i,metadata:o},h=[..._.length?[]:H,u];if(t&&e){RP();const e=j.current.map(((e,t)=>({id:`${e.id}-${Zh(6)}-${t}`,role:e.role,..."assistant"===e.role?{links:e.links??[]}:{},content:e.content,metadata:e.metadata,tool_calls:e.tool_calls})));S([...e,...h]),j.current=[...e,...h]}else S((e=>[...e,...h])),j.current=[...j.current,...h];L([]),x(""),z({eventName:"user_message_submitted",properties:{}},j.current);const m=[kL,...(null==g?void 0:g({conversation:r}))||[]];try{const e={model:b,messages:j.current,stream:!0,tools:m,tool_choice:"auto"},t=await d(),n=t?btoa(JSON.stringify(t)):null,a=c||v?JSON.stringify({...c,...v}):void 0,o={};!l&&n&&(o["X-INKEEP-CHALLENGE-SOLUTION"]=n),a&&(o["inkeep-filters"]=a);const i=f.beta.chat.completions.stream(e,Object.keys(o).length>0?{headers:o}:void 0),s={id:`${Date.now().toString()}-${Zh(4)}-2`,role:"assistant",content:"",links:[],tool_calls:[]};S((e=>[...e,s])),i.on("content",((e,t)=>{N(!0),s.content=t,S((e=>{const t=[...e],n=t.findIndex((e=>e.id===s.id));return-1===n?[...t,s]:(t[n]={...s},t)}))})),i.on("tool_calls.function.arguments.done",(async e=>{var t,n,a,o;const{name:l,arguments:c}=e,u=null==m?void 0:m.find((e=>e.function.name===l));if(!u)return;const d=("parse"in u.function?u.function.parse:JSON.parse)(c),p=null==(n=(t=u.function).function)?void 0:n.call(t,d,i),h=(null==(a=u.renderMessageButtons)?void 0:a.call(u,{args:d,execution:p}))??[];"provideLinks"===l?s.links=d.links??[]:F((e=>({...e,[s.id]:[...e[s.id]??[],...h]}))),null==(o=s.tool_calls)||o.push({id:"call_"+Zh(24),type:"function",function:{name:l,arguments:c}}),S((e=>{const t=[...e],n=t.findIndex((e=>e.id===s.id));return t[n]={...s},t})),null==k||k(e,{conversation:{...r,messages:[...j.current,s]}})})),i.on("error",G),i.finalChatCompletion().then((async()=>{j.current=[...j.current,s],B.current=null,C(!1),N(!1),p(),await z({eventName:"assistant_message_received",properties:{}},j.current),z({eventName:"assistant_answer_displayed",properties:{}})})).catch((e=>{e instanceof Of||console.warn(e)})),B.current=i.controller}catch(y){G(y),C(!1),N(!1)}},W=()=>{R(null),S([]),j.current=[],a(),F({}),L([]),RP(),P(null),h(),p(),z({eventName:"chat_clear_button_clicked",properties:{conversation:r}})},{openForm:Y}=dL(),X=fL();K.useImperativeHandle(i.chatFunctionsRef,(()=>({submitMessage:q,updateInputMessage(e){x(e)},clearChat:W,openForm:e=>{null==X||X.setView("chat"),Y(e)},focusInput:()=>{var e;null==(e=E.current)||e.focus()}})));const Q=mL("(max-width: 768px)");return{messages:_,input:w,isLoading:T,isStreaming:A,isLoadingConversation:U,error:I,isSubmitDisabled:V,handleInputChange:e=>{const t=e.target.value;x(t)},handleInputKeyDown:e=>{"Enter"!==e.key||e.shiftKey||V||e.nativeEvent.isComposing||(e.preventDefault(),q())},handleSubmit:q,stop:()=>{B.current&&(B.current.abort(),B.current=null),C(!1),N(!1),p()},clear:W,handleWorkflow:e=>{P(e);const{initialReplyMessage:t,displayName:n}=e,r={id:_.length.toString()+Zh(4),role:"user",content:n},a={id:(_.length+1).toString()+Zh(4),role:"assistant",content:t,links:[]},o=[{id:`system-${Date.now().toString()}-${Zh(4)}-${e.id}`,role:"system",content:`Company has asked user to follow this guided workflow:\n${xP(e)}`},...H,r,a];S(o),L([])},selectedWorkflow:O,messageAttachments:D,setMessageAttachments:L,addAttachment:e=>{L((t=>[...t,e]))},messageButtons:M,isEmpty:0===_.length,inputRef:E,isMobile:Q}};const IL=K.createContext(void 0);function RL(){const{baseSettings:e}=nP(),{apiKey:t,analyticsApiBaseUrl:n,analyticsProperties:r}=e,[a,o]=K.useState(null),[i,s]=K.useState({}),{conversation:l}=iP(),{messages:c,selectedWorkflow:u}=$j(),{userProperties:d}=mP(),{logEvent:p}=wP(),h=K.useCallback((async(e,a,o=[])=>{const i=await async function(e){try{const{type:t,messageId:n,reasons:r=[],apiKey:a,apiUrl:o,userProperties:i,properties:s}=e,l=`${o}/feedback`,c={type:t,messageId:n,createdAt:(new Date).toISOString(),userProperties:i,properties:s};"negative"===t&&(c.reasons=r);const u=await fetch(l,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${a}`},body:JSON.stringify(c)});if(!u.ok){const e=await u.text();throw new Error(`Failed to send feedback: ${e}`)}return u.json()}catch(t){console.warn("Error in submitFeedback:",t)}}({type:a,messageId:e,reasons:o,apiKey:t,apiUrl:n,userProperties:d,properties:r});i&&s((t=>({...t,[e]:{type:i.type,reasons:i.reasons}})));const h=c.findIndex((t=>t.id===e)),f=c[h],m={conversationId:l.id,question:AL(c[h-1]),answer:AL(f),messageId:e,reasons:o,workflowId:null==u?void 0:u.id};p({eventName:"positive"===a?"assistant_positive_feedback_submitted":"assistant_negative_feedback_submitted",properties:m}),"negative"===a&&p({eventName:"user_escalation_indicated",properties:{escalationType:"downvote",conversation:l}})}),[c,l]);return{feedback:i,currentFeedback:a,setCurrentFeedback:o,submitPositiveFeedback:K.useCallback((async e=>{h(e,"positive")}),[h]),submitNegativeFeedback:K.useCallback((async(e,t)=>{const n=function(e){const t=[];for(const n in e){"on"===e[n]&&t.push({label:n,details:e[`${n}:description`]||""})}return t.length>0?t:[]}(t);h(e,"negative",n)}),[h])}}const OL=({children:e})=>{const t=RL();return Wh.jsx(IL.Provider,{value:t,children:e})},PL=()=>{const e=K.useContext(IL);if(!e)throw new Error("useFeedback must be used within a FeedbackProvider");return e};function DL(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}function LL(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function ML(...e){return t=>{let n=!1;const r=e.map((e=>{const r=LL(e,t);return n||"function"!=typeof r||(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():LL(e[t],null)}}}}function FL(...e){return K.useCallback(ML(...e),e)}function jL(e,t=[]){let n=[];const r=()=>{const t=n.map((e=>K.createContext(e)));return function(n){const r=(null==n?void 0:n[e])||t;return K.useMemo((()=>({[`__scope${e}`]:{...n,[e]:r}})),[n,r])}};return r.scopeName=e,[function(t,r){const a=K.createContext(r),o=n.length;n=[...n,r];const i=t=>{var n;const{scope:r,children:i,...s}=t,l=(null==(n=null==r?void 0:r[e])?void 0:n[o])||a,c=K.useMemo((()=>s),Object.values(s));return Wh.jsx(l.Provider,{value:c,children:i})};return i.displayName=t+"Provider",[i,function(n,i){var s;const l=(null==(s=null==i?void 0:i[e])?void 0:s[o])||a,c=K.useContext(l);if(c)return c;if(void 0!==r)return r;throw new Error(`\`${n}\` must be used within \`${t}\``)}]},BL(r,...t)]}function BL(...e){const t=e[0];if(1===e.length)return t;const n=()=>{const n=e.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(e){const r=n.reduce(((t,{useScope:n,scopeName:r})=>({...t,...n(e)[`__scope${r}`]})),{});return K.useMemo((()=>({[`__scope${t.scopeName}`]:r})),[r])}};return n.scopeName=t.scopeName,n}var zL=K.forwardRef(((e,t)=>{const{children:n,...r}=e,a=K.Children.toArray(n),o=a.find($L);if(o){const e=o.props.children,n=a.map((t=>t===o?K.Children.count(e)>1?K.Children.only(null):K.isValidElement(e)?e.props.children:null:t));return Wh.jsx(HL,{...r,ref:t,children:K.isValidElement(e)?K.cloneElement(e,void 0,n):null})}return Wh.jsx(HL,{...r,ref:t,children:n})}));zL.displayName="Slot";var HL=K.forwardRef(((e,t)=>{const{children:n,...r}=e;if(K.isValidElement(n)){const e=function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;if(a)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a)return e.props.ref;return e.props.ref||e.ref}(n);return K.cloneElement(n,{...GL(r,n.props),ref:t?ML(t,e):e})}return K.Children.count(n)>1?K.Children.only(null):null}));HL.displayName="SlotClone";var UL=({children:e})=>Wh.jsx(Wh.Fragment,{children:e});function $L(e){return K.isValidElement(e)&&e.type===UL}function GL(e,t){const n={...t};for(const r in t){const a=e[r],o=t[r];/^on[A-Z]/.test(r)?a&&o?n[r]=(...e)=>{o(...e),a(...e)}:a&&(n[r]=a):"style"===r?n[r]={...a,...o}:"className"===r&&(n[r]=[a,o].filter(Boolean).join(" "))}return{...e,...n}}var VL=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce(((e,t)=>{const n=K.forwardRef(((e,n)=>{const{asChild:r,...a}=e,o=r?zL:t;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),Wh.jsx(o,{...a,ref:n})}));return n.displayName=`Primitive.${t}`,{...e,[t]:n}}),{});function qL(e){const t=K.useRef(e);return K.useEffect((()=>{t.current=e})),K.useMemo((()=>(...e)=>{var n;return null==(n=t.current)?void 0:n.call(t,...e)}),[])}function WL(e,t=(null==globalThis?void 0:globalThis.document)){const n=qL(e);K.useEffect((()=>{const e=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",e,{capture:!0}),()=>t.removeEventListener("keydown",e,{capture:!0})}),[n,t])}var YL,KL="dismissableLayer.update",XL="dismissableLayer.pointerDownOutside",QL="dismissableLayer.focusOutside",ZL=K.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),JL=K.forwardRef(((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:a,onFocusOutside:o,onInteractOutside:i,onDismiss:s,...l}=e,c=K.useContext(ZL),[u,d]=K.useState(null),p=(null==u?void 0:u.ownerDocument)??(null==globalThis?void 0:globalThis.document),[,h]=K.useState({}),f=FL(t,(e=>d(e))),m=Array.from(c.layers),[g]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),y=m.indexOf(g),b=u?m.indexOf(u):-1,v=c.layersWithOutsidePointerEventsDisabled.size>0,k=b>=y,w=function(e,t=(null==globalThis?void 0:globalThis.document)){const n=qL(e),r=K.useRef(!1),a=K.useRef((()=>{}));return K.useEffect((()=>{const e=e=>{if(e.target&&!r.current){let r=function(){nM(XL,n,o,{discrete:!0})};const o={originalEvent:e};"touch"===e.pointerType?(t.removeEventListener("click",a.current),a.current=r,t.addEventListener("click",a.current,{once:!0})):r()}else t.removeEventListener("click",a.current);r.current=!1},o=window.setTimeout((()=>{t.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(o),t.removeEventListener("pointerdown",e),t.removeEventListener("click",a.current)}}),[t,n]),{onPointerDownCapture:()=>r.current=!0}}((e=>{const t=e.target,n=[...c.branches].some((e=>e.contains(t)));k&&!n&&(null==a||a(e),null==i||i(e),e.defaultPrevented||null==s||s())}),p),x=function(e,t=(null==globalThis?void 0:globalThis.document)){const n=qL(e),r=K.useRef(!1);return K.useEffect((()=>{const e=e=>{if(e.target&&!r.current){nM(QL,n,{originalEvent:e},{discrete:!1})}};return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)}),[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}((e=>{const t=e.target;[...c.branches].some((e=>e.contains(t)))||(null==o||o(e),null==i||i(e),e.defaultPrevented||null==s||s())}),p);return WL((e=>{b===c.layers.size-1&&(null==r||r(e),!e.defaultPrevented&&s&&(e.preventDefault(),s()))}),p),K.useEffect((()=>{if(u)return n&&(0===c.layersWithOutsidePointerEventsDisabled.size&&(YL=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(u)),c.layers.add(u),tM(),()=>{n&&1===c.layersWithOutsidePointerEventsDisabled.size&&(p.body.style.pointerEvents=YL)}}),[u,p,n,c]),K.useEffect((()=>()=>{u&&(c.layers.delete(u),c.layersWithOutsidePointerEventsDisabled.delete(u),tM())}),[u,c]),K.useEffect((()=>{const e=()=>h({});return document.addEventListener(KL,e),()=>document.removeEventListener(KL,e)}),[]),Wh.jsx(VL.div,{...l,ref:f,style:{pointerEvents:v?k?"auto":"none":void 0,...e.style},onFocusCapture:DL(e.onFocusCapture,x.onFocusCapture),onBlurCapture:DL(e.onBlurCapture,x.onBlurCapture),onPointerDownCapture:DL(e.onPointerDownCapture,w.onPointerDownCapture)})}));JL.displayName="DismissableLayer";var eM=K.forwardRef(((e,t)=>{const n=K.useContext(ZL),r=K.useRef(null),a=FL(t,r);return K.useEffect((()=>{const e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}}),[n.branches]),Wh.jsx(VL.div,{...e,ref:a})}));function tM(){const e=new CustomEvent(KL);document.dispatchEvent(e)}function nM(e,t,n,{discrete:r}){const a=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&a.addEventListener(e,t,{once:!0}),r?function(e,t){e&&se.flushSync((()=>e.dispatchEvent(t)))}(a,o):a.dispatchEvent(o)}eM.displayName="DismissableLayerBranch";var rM=Boolean(null==globalThis?void 0:globalThis.document)?K.useLayoutEffect:()=>{},aM=Q["useId".toString()]||(()=>{}),oM=0;function iM(e){const[t,n]=K.useState(aM());return rM((()=>{n((e=>e??String(oM++)))}),[e]),e||(t?`radix-${t}`:"")}const sM=["top","right","bottom","left"],lM=Math.min,cM=Math.max,uM=Math.round,dM=Math.floor,pM=e=>({x:e,y:e}),hM={left:"right",right:"left",bottom:"top",top:"bottom"},fM={start:"end",end:"start"};function mM(e,t,n){return cM(e,lM(t,n))}function gM(e,t){return"function"==typeof e?e(t):e}function yM(e){return e.split("-")[0]}function bM(e){return e.split("-")[1]}function vM(e){return"x"===e?"y":"x"}function kM(e){return"y"===e?"height":"width"}function wM(e){return["top","bottom"].includes(yM(e))?"y":"x"}function xM(e){return vM(wM(e))}function EM(e){return e.replace(/start|end/g,(e=>fM[e]))}function _M(e){return e.replace(/left|right|bottom|top/g,(e=>hM[e]))}function SM(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}function TM(e){const{x:t,y:n,width:r,height:a}=e;return{width:r,height:a,top:n,left:t,right:t+r,bottom:n+a,x:t,y:n}}function CM(e,t,n){let{reference:r,floating:a}=e;const o=wM(t),i=xM(t),s=kM(i),l=yM(t),c="y"===o,u=r.x+r.width/2-a.width/2,d=r.y+r.height/2-a.height/2,p=r[s]/2-a[s]/2;let h;switch(l){case"top":h={x:u,y:r.y-a.height};break;case"bottom":h={x:u,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:d};break;case"left":h={x:r.x-a.width,y:d};break;default:h={x:r.x,y:r.y}}switch(bM(t)){case"start":h[i]-=p*(n&&c?-1:1);break;case"end":h[i]+=p*(n&&c?-1:1)}return h}async function AM(e,t){var n;void 0===t&&(t={});const{x:r,y:a,platform:o,rects:i,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:p=!1,padding:h=0}=gM(t,e),f=SM(h),m=s[p?"floating"===d?"reference":"floating":d],g=TM(await o.getClippingRect({element:null==(n=await(null==o.isElement?void 0:o.isElement(m)))||n?m:m.contextElement||await(null==o.getDocumentElement?void 0:o.getDocumentElement(s.floating)),boundary:c,rootBoundary:u,strategy:l})),y="floating"===d?{x:r,y:a,width:i.floating.width,height:i.floating.height}:i.reference,b=await(null==o.getOffsetParent?void 0:o.getOffsetParent(s.floating)),v=await(null==o.isElement?void 0:o.isElement(b))&&await(null==o.getScale?void 0:o.getScale(b))||{x:1,y:1},k=TM(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:y,offsetParent:b,strategy:l}):y);return{top:(g.top-k.top+f.top)/v.y,bottom:(k.bottom-g.bottom+f.bottom)/v.y,left:(g.left-k.left+f.left)/v.x,right:(k.right-g.right+f.right)/v.x}}function NM(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function IM(e){return sM.some((t=>e[t]>=0))}function RM(){return"undefined"!=typeof window}function OM(e){return LM(e)?(e.nodeName||"").toLowerCase():"#document"}function PM(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function DM(e){var t;return null==(t=(LM(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function LM(e){return!!RM()&&(e instanceof Node||e instanceof PM(e).Node)}function MM(e){return!!RM()&&(e instanceof Element||e instanceof PM(e).Element)}function FM(e){return!!RM()&&(e instanceof HTMLElement||e instanceof PM(e).HTMLElement)}function jM(e){return!(!RM()||"undefined"==typeof ShadowRoot)&&(e instanceof ShadowRoot||e instanceof PM(e).ShadowRoot)}function BM(e){const{overflow:t,overflowX:n,overflowY:r,display:a}=VM(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(a)}function zM(e){return["table","td","th"].includes(OM(e))}function HM(e){return[":popover-open",":modal"].some((t=>{try{return e.matches(t)}catch(X4){return!1}}))}function UM(e){const t=$M(),n=MM(e)?VM(e):e;return["transform","translate","scale","rotate","perspective"].some((e=>!!n[e]&&"none"!==n[e]))||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||["transform","translate","scale","rotate","perspective","filter"].some((e=>(n.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(n.contain||"").includes(e)))}function $M(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function GM(e){return["html","body","#document"].includes(OM(e))}function VM(e){return PM(e).getComputedStyle(e)}function qM(e){return MM(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function WM(e){if("html"===OM(e))return e;const t=e.assignedSlot||e.parentNode||jM(e)&&e.host||DM(e);return jM(t)?t.host:t}function YM(e){const t=WM(e);return GM(t)?e.ownerDocument?e.ownerDocument.body:e.body:FM(t)&&BM(t)?t:YM(t)}function KM(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);const a=YM(e),o=a===(null==(r=e.ownerDocument)?void 0:r.body),i=PM(a);if(o){const e=XM(i);return t.concat(i,i.visualViewport||[],BM(a)?a:[],e&&n?KM(e):[])}return t.concat(a,KM(a,[],n))}function XM(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function QM(e){const t=VM(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const a=FM(e),o=a?e.offsetWidth:n,i=a?e.offsetHeight:r,s=uM(n)!==o||uM(r)!==i;return s&&(n=o,r=i),{width:n,height:r,$:s}}function ZM(e){return MM(e)?e:e.contextElement}function JM(e){const t=ZM(e);if(!FM(t))return pM(1);const n=t.getBoundingClientRect(),{width:r,height:a,$:o}=QM(t);let i=(o?uM(n.width):n.width)/r,s=(o?uM(n.height):n.height)/a;return i&&Number.isFinite(i)||(i=1),s&&Number.isFinite(s)||(s=1),{x:i,y:s}}const eF=pM(0);function tF(e){const t=PM(e);return $M()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:eF}function nF(e,t,n,r){void 0===t&&(t=!1),void 0===n&&(n=!1);const a=e.getBoundingClientRect(),o=ZM(e);let i=pM(1);t&&(r?MM(r)&&(i=JM(r)):i=JM(e));const s=function(e,t,n){return void 0===t&&(t=!1),!(!n||t&&n!==PM(e))&&t}(o,n,r)?tF(o):pM(0);let l=(a.left+s.x)/i.x,c=(a.top+s.y)/i.y,u=a.width/i.x,d=a.height/i.y;if(o){const e=PM(o),t=r&&MM(r)?PM(r):r;let n=e,a=XM(n);for(;a&&r&&t!==n;){const e=JM(a),t=a.getBoundingClientRect(),r=VM(a),o=t.left+(a.clientLeft+parseFloat(r.paddingLeft))*e.x,i=t.top+(a.clientTop+parseFloat(r.paddingTop))*e.y;l*=e.x,c*=e.y,u*=e.x,d*=e.y,l+=o,c+=i,n=PM(a),a=XM(n)}}return TM({width:u,height:d,x:l,y:c})}function rF(e,t){const n=qM(e).scrollLeft;return t?t.left+n:nF(DM(e)).left+n}function aF(e,t,n){void 0===n&&(n=!1);const r=e.getBoundingClientRect();return{x:r.left+t.scrollLeft-(n?0:rF(e,r)),y:r.top+t.scrollTop}}function oF(e,t,n){let r;if("viewport"===t)r=function(e,t){const n=PM(e),r=DM(e),a=n.visualViewport;let o=r.clientWidth,i=r.clientHeight,s=0,l=0;if(a){o=a.width,i=a.height;const e=$M();(!e||e&&"fixed"===t)&&(s=a.offsetLeft,l=a.offsetTop)}return{width:o,height:i,x:s,y:l}}(e,n);else if("document"===t)r=function(e){const t=DM(e),n=qM(e),r=e.ownerDocument.body,a=cM(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=cM(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+rF(e);const s=-n.scrollTop;return"rtl"===VM(r).direction&&(i+=cM(t.clientWidth,r.clientWidth)-a),{width:a,height:o,x:i,y:s}}(DM(e));else if(MM(t))r=function(e,t){const n=nF(e,!0,"fixed"===t),r=n.top+e.clientTop,a=n.left+e.clientLeft,o=FM(e)?JM(e):pM(1);return{width:e.clientWidth*o.x,height:e.clientHeight*o.y,x:a*o.x,y:r*o.y}}(t,n);else{const n=tF(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return TM(r)}function iF(e,t){const n=WM(e);return!(n===t||!MM(n)||GM(n))&&("fixed"===VM(n).position||iF(n,t))}function sF(e,t,n){const r=FM(t),a=DM(t),o="fixed"===n,i=nF(e,!0,o,t);let s={scrollLeft:0,scrollTop:0};const l=pM(0);if(r||!r&&!o)if(("body"!==OM(t)||BM(a))&&(s=qM(t)),r){const e=nF(t,!0,o,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}else a&&(l.x=rF(a));const c=!a||r||o?pM(0):aF(a,s);return{x:i.left+s.scrollLeft-l.x-c.x,y:i.top+s.scrollTop-l.y-c.y,width:i.width,height:i.height}}function lF(e){return"static"===VM(e).position}function cF(e,t){if(!FM(e)||"fixed"===VM(e).position)return null;if(t)return t(e);let n=e.offsetParent;return DM(e)===n&&(n=n.ownerDocument.body),n}function uF(e,t){const n=PM(e);if(HM(e))return n;if(!FM(e)){let t=WM(e);for(;t&&!GM(t);){if(MM(t)&&!lF(t))return t;t=WM(t)}return n}let r=cF(e,t);for(;r&&zM(r)&&lF(r);)r=cF(r,t);return r&&GM(r)&&lF(r)&&!UM(r)?n:r||function(e){let t=WM(e);for(;FM(t)&&!GM(t);){if(UM(t))return t;if(HM(t))return null;t=WM(t)}return null}(e)||n}const dF={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:r,strategy:a}=e;const o="fixed"===a,i=DM(r),s=!!t&&HM(t.floating);if(r===i||s&&o)return n;let l={scrollLeft:0,scrollTop:0},c=pM(1);const u=pM(0),d=FM(r);if((d||!d&&!o)&&(("body"!==OM(r)||BM(i))&&(l=qM(r)),FM(r))){const e=nF(r);c=JM(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}const p=!i||d||o?pM(0):aF(i,l,!0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-l.scrollLeft*c.x+u.x+p.x,y:n.y*c.y-l.scrollTop*c.y+u.y+p.y}},getDocumentElement:DM,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:a}=e;const o=[..."clippingAncestors"===n?HM(t)?[]:function(e,t){const n=t.get(e);if(n)return n;let r=KM(e,[],!1).filter((e=>MM(e)&&"body"!==OM(e))),a=null;const o="fixed"===VM(e).position;let i=o?WM(e):e;for(;MM(i)&&!GM(i);){const t=VM(i),n=UM(i);n||"fixed"!==t.position||(a=null),(o?!n&&!a:!n&&"static"===t.position&&a&&["absolute","fixed"].includes(a.position)||BM(i)&&!n&&iF(e,i))?r=r.filter((e=>e!==i)):a=t,i=WM(i)}return t.set(e,r),r}(t,this._c):[].concat(n),r],i=o[0],s=o.reduce(((e,n)=>{const r=oF(t,n,a);return e.top=cM(r.top,e.top),e.right=lM(r.right,e.right),e.bottom=lM(r.bottom,e.bottom),e.left=cM(r.left,e.left),e}),oF(t,i,a));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:uF,getElementRects:async function(e){const t=this.getOffsetParent||uF,n=this.getDimensions,r=await n(e.floating);return{reference:sF(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:n}=QM(e);return{width:t,height:n}},getScale:JM,isElement:MM,isRTL:function(e){return"rtl"===VM(e).direction}};function pF(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function hF(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:a=!0,ancestorResize:o=!0,elementResize:i="function"==typeof ResizeObserver,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:l=!1}=r,c=ZM(e),u=a||o?[...c?KM(c):[],...KM(t)]:[];u.forEach((e=>{a&&e.addEventListener("scroll",n,{passive:!0}),o&&e.addEventListener("resize",n)}));const d=c&&s?function(e,t){let n,r=null;const a=DM(e);function o(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return function i(s,l){void 0===s&&(s=!1),void 0===l&&(l=1),o();const c=e.getBoundingClientRect(),{left:u,top:d,width:p,height:h}=c;if(s||t(),!p||!h)return;const f={rootMargin:-dM(d)+"px "+-dM(a.clientWidth-(u+p))+"px "+-dM(a.clientHeight-(d+h))+"px "+-dM(u)+"px",threshold:cM(0,lM(1,l))||1};let m=!0;function g(t){const r=t[0].intersectionRatio;if(r!==l){if(!m)return i();r?i(!1,r):n=setTimeout((()=>{i(!1,1e-7)}),1e3)}1!==r||pF(c,e.getBoundingClientRect())||i(),m=!1}try{r=new IntersectionObserver(g,{...f,root:a.ownerDocument})}catch(X4){r=new IntersectionObserver(g,f)}r.observe(e)}(!0),o}(c,n):null;let p,h=-1,f=null;i&&(f=new ResizeObserver((e=>{let[r]=e;r&&r.target===c&&f&&(f.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame((()=>{var e;null==(e=f)||e.observe(t)}))),n()})),c&&!l&&f.observe(c),f.observe(t));let m=l?nF(e):null;return l&&function t(){const r=nF(e);m&&!pF(m,r)&&n();m=r,p=requestAnimationFrame(t)}(),n(),()=>{var e;u.forEach((e=>{a&&e.removeEventListener("scroll",n),o&&e.removeEventListener("resize",n)})),null==d||d(),null==(e=f)||e.disconnect(),f=null,l&&cancelAnimationFrame(p)}}const fF=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:a,y:o,placement:i,middlewareData:s}=t,l=await async function(e,t){const{placement:n,platform:r,elements:a}=e,o=await(null==r.isRTL?void 0:r.isRTL(a.floating)),i=yM(n),s=bM(n),l="y"===wM(n),c=["left","top"].includes(i)?-1:1,u=o&&l?-1:1,d=gM(t,e);let{mainAxis:p,crossAxis:h,alignmentAxis:f}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&"number"==typeof f&&(h="end"===s?-1*f:f),l?{x:h*u,y:p*c}:{x:p*c,y:h*u}}(t,e);return i===(null==(n=s.offset)?void 0:n.placement)&&null!=(r=s.arrow)&&r.alignmentOffset?{}:{x:a+l.x,y:o+l.y,data:{...l,placement:i}}}}},mF=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:a}=t,{mainAxis:o=!0,crossAxis:i=!1,limiter:s={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=gM(e,t),c={x:n,y:r},u=await AM(t,l),d=wM(yM(a)),p=vM(d);let h=c[p],f=c[d];if(o){const e="y"===p?"bottom":"right";h=mM(h+u["y"===p?"top":"left"],h,h-u[e])}if(i){const e="y"===d?"bottom":"right";f=mM(f+u["y"===d?"top":"left"],f,f-u[e])}const m=s.fn({...t,[p]:h,[d]:f});return{...m,data:{x:m.x-n,y:m.y-r,enabled:{[p]:o,[d]:i}}}}}},gF=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:a,middlewareData:o,rects:i,initialPlacement:s,platform:l,elements:c}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:p,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:f="none",flipAlignment:m=!0,...g}=gM(e,t);if(null!=(n=o.arrow)&&n.alignmentOffset)return{};const y=yM(a),b=wM(s),v=yM(s)===s,k=await(null==l.isRTL?void 0:l.isRTL(c.floating)),w=p||(v||!m?[_M(s)]:function(e){const t=_M(e);return[EM(e),t,EM(t)]}(s)),x="none"!==f;!p&&x&&w.push(...function(e,t,n,r){const a=bM(e);let o=function(e,t,n){const r=["left","right"],a=["right","left"],o=["top","bottom"],i=["bottom","top"];switch(e){case"top":case"bottom":return n?t?a:r:t?r:a;case"left":case"right":return t?o:i;default:return[]}}(yM(e),"start"===n,r);return a&&(o=o.map((e=>e+"-"+a)),t&&(o=o.concat(o.map(EM)))),o}(s,m,f,k));const E=[s,...w],_=await AM(t,g),S=[];let T=(null==(r=o.flip)?void 0:r.overflows)||[];if(u&&S.push(_[y]),d){const e=function(e,t,n){void 0===n&&(n=!1);const r=bM(e),a=xM(e),o=kM(a);let i="x"===a?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[o]>t.floating[o]&&(i=_M(i)),[i,_M(i)]}(a,i,k);S.push(_[e[0]],_[e[1]])}if(T=[...T,{placement:a,overflows:S}],!S.every((e=>e<=0))){var C,A;const e=((null==(C=o.flip)?void 0:C.index)||0)+1,t=E[e];if(t)return{data:{index:e,overflows:T},reset:{placement:t}};let n=null==(A=T.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:A.placement;if(!n)switch(h){case"bestFit":{var N;const e=null==(N=T.filter((e=>{if(x){const t=wM(e.placement);return t===b||"y"===t}return!0})).map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:N[0];e&&(n=e);break}case"initialPlacement":n=s}if(a!==n)return{reset:{placement:n}}}return{}}}},yF=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:a,rects:o,platform:i,elements:s}=t,{apply:l=()=>{},...c}=gM(e,t),u=await AM(t,c),d=yM(a),p=bM(a),h="y"===wM(a),{width:f,height:m}=o.floating;let g,y;"top"===d||"bottom"===d?(g=d,y=p===(await(null==i.isRTL?void 0:i.isRTL(s.floating))?"start":"end")?"left":"right"):(y=d,g="end"===p?"top":"bottom");const b=m-u.top-u.bottom,v=f-u.left-u.right,k=lM(m-u[g],b),w=lM(f-u[y],v),x=!t.middlewareData.shift;let E=k,_=w;if(null!=(n=t.middlewareData.shift)&&n.enabled.x&&(_=v),null!=(r=t.middlewareData.shift)&&r.enabled.y&&(E=b),x&&!p){const e=cM(u.left,0),t=cM(u.right,0),n=cM(u.top,0),r=cM(u.bottom,0);h?_=f-2*(0!==e||0!==t?e+t:cM(u.left,u.right)):E=m-2*(0!==n||0!==r?n+r:cM(u.top,u.bottom))}await l({...t,availableWidth:_,availableHeight:E});const S=await i.getDimensions(s.floating);return f!==S.width||m!==S.height?{reset:{rects:!0}}:{}}}},bF=function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...a}=gM(e,t);switch(r){case"referenceHidden":{const e=NM(await AM(t,{...a,elementContext:"reference"}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:IM(e)}}}case"escaped":{const e=NM(await AM(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:IM(e)}}}default:return{}}}}},vF=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:a,rects:o,platform:i,elements:s,middlewareData:l}=t,{element:c,padding:u=0}=gM(e,t)||{};if(null==c)return{};const d=SM(u),p={x:n,y:r},h=xM(a),f=kM(h),m=await i.getDimensions(c),g="y"===h,y=g?"top":"left",b=g?"bottom":"right",v=g?"clientHeight":"clientWidth",k=o.reference[f]+o.reference[h]-p[h]-o.floating[f],w=p[h]-o.reference[h],x=await(null==i.getOffsetParent?void 0:i.getOffsetParent(c));let E=x?x[v]:0;E&&await(null==i.isElement?void 0:i.isElement(x))||(E=s.floating[v]||o.floating[f]);const _=k/2-w/2,S=E/2-m[f]/2-1,T=lM(d[y],S),C=lM(d[b],S),A=T,N=E-m[f]-C,I=E/2-m[f]/2+_,R=mM(A,I,N),O=!l.arrow&&null!=bM(a)&&I!==R&&o.reference[f]/2-(I<A?T:C)-m[f]/2<0,P=O?I<A?I-A:I-N:0;return{[h]:p[h]+P,data:{[h]:R,centerOffset:I-R-P,...O&&{alignmentOffset:P}},reset:O}}}),kF=function(e){return void 0===e&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:a,rects:o,middlewareData:i}=t,{offset:s=0,mainAxis:l=!0,crossAxis:c=!0}=gM(e,t),u={x:n,y:r},d=wM(a),p=vM(d);let h=u[p],f=u[d];const m=gM(s,t),g="number"==typeof m?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(l){const e="y"===p?"height":"width",t=o.reference[p]-o.floating[e]+g.mainAxis,n=o.reference[p]+o.reference[e]-g.mainAxis;h<t?h=t:h>n&&(h=n)}if(c){var y,b;const e="y"===p?"width":"height",t=["top","left"].includes(yM(a)),n=o.reference[d]-o.floating[e]+(t&&(null==(y=i.offset)?void 0:y[d])||0)+(t?0:g.crossAxis),r=o.reference[d]+o.reference[e]+(t?0:(null==(b=i.offset)?void 0:b[d])||0)-(t?g.crossAxis:0);f<n?f=n:f>r&&(f=r)}return{[p]:h,[d]:f}}}},wF=(e,t,n)=>{const r=new Map,a={platform:dF,...n},o={...a.platform,_c:r};return(async(e,t,n)=>{const{placement:r="bottom",strategy:a="absolute",middleware:o=[],platform:i}=n,s=o.filter(Boolean),l=await(null==i.isRTL?void 0:i.isRTL(t));let c=await i.getElementRects({reference:e,floating:t,strategy:a}),{x:u,y:d}=CM(c,r,l),p=r,h={},f=0;for(let m=0;m<s.length;m++){const{name:n,fn:o}=s[m],{x:g,y:y,data:b,reset:v}=await o({x:u,y:d,initialPlacement:r,placement:p,strategy:a,middlewareData:h,rects:c,platform:i,elements:{reference:e,floating:t}});u=null!=g?g:u,d=null!=y?y:d,h={...h,[n]:{...h[n],...b}},v&&f<=50&&(f++,"object"==typeof v&&(v.placement&&(p=v.placement),v.rects&&(c=!0===v.rects?await i.getElementRects({reference:e,floating:t,strategy:a}):v.rects),({x:u,y:d}=CM(c,p,l))),m=-1)}return{x:u,y:d,placement:p,strategy:a,middlewareData:h}})(e,t,{...a,platform:o})};var xF="undefined"!=typeof document?K.useLayoutEffect:K.useEffect;function EF(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let n,r,a;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;0!=r--;)if(!EF(e[r],t[r]))return!1;return!0}if(a=Object.keys(e),n=a.length,n!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!{}.hasOwnProperty.call(t,a[r]))return!1;for(r=n;0!=r--;){const n=a[r];if(("_owner"!==n||!e.$$typeof)&&!EF(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function _F(e){if("undefined"==typeof window)return 1;return(e.ownerDocument.defaultView||window).devicePixelRatio||1}function SF(e,t){const n=_F(e);return Math.round(t*n)/n}function TF(e){const t=K.useRef(e);return xF((()=>{t.current=e})),t}function CF(e){void 0===e&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:a,elements:{reference:o,floating:i}={},transform:s=!0,whileElementsMounted:l,open:c}=e,[u,d]=K.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,h]=K.useState(r);EF(p,r)||h(r);const[f,m]=K.useState(null),[g,y]=K.useState(null),b=K.useCallback((e=>{e!==x.current&&(x.current=e,m(e))}),[]),v=K.useCallback((e=>{e!==E.current&&(E.current=e,y(e))}),[]),k=o||f,w=i||g,x=K.useRef(null),E=K.useRef(null),_=K.useRef(u),S=null!=l,T=TF(l),C=TF(a),A=TF(c),N=K.useCallback((()=>{if(!x.current||!E.current)return;const e={placement:t,strategy:n,middleware:p};C.current&&(e.platform=C.current),wF(x.current,E.current,e).then((e=>{const t={...e,isPositioned:!1!==A.current};I.current&&!EF(_.current,t)&&(_.current=t,se.flushSync((()=>{d(t)})))}))}),[p,t,n,C,A]);xF((()=>{!1===c&&_.current.isPositioned&&(_.current.isPositioned=!1,d((e=>({...e,isPositioned:!1}))))}),[c]);const I=K.useRef(!1);xF((()=>(I.current=!0,()=>{I.current=!1})),[]),xF((()=>{if(k&&(x.current=k),w&&(E.current=w),k&&w){if(T.current)return T.current(k,w,N);N()}}),[k,w,N,T,S]);const R=K.useMemo((()=>({reference:x,floating:E,setReference:b,setFloating:v})),[b,v]),O=K.useMemo((()=>({reference:k,floating:w})),[k,w]),P=K.useMemo((()=>{const e={position:n,left:0,top:0};if(!O.floating)return e;const t=SF(O.floating,u.x),r=SF(O.floating,u.y);return s?{...e,transform:"translate("+t+"px, "+r+"px)",..._F(O.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}}),[n,s,O.floating,u.x,u.y]);return K.useMemo((()=>({...u,update:N,refs:R,elements:O,floatingStyles:P})),[u,N,R,O,P])}const AF=e=>({name:"arrow",options:e,fn(t){const{element:n,padding:r}="function"==typeof e?e(t):e;return n&&(a=n,{}.hasOwnProperty.call(a,"current"))?null!=n.current?vF({element:n.current,padding:r}).fn(t):{}:n?vF({element:n,padding:r}).fn(t):{};var a}}),NF=(e,t)=>({...fF(e),options:[e,t]}),IF=(e,t)=>({...mF(e),options:[e,t]}),RF=(e,t)=>({...kF(e),options:[e,t]}),OF=(e,t)=>({...gF(e),options:[e,t]}),PF=(e,t)=>({...yF(e),options:[e,t]}),DF=(e,t)=>({...bF(e),options:[e,t]}),LF=(e,t)=>({...AF(e),options:[e,t]});var MF=K.forwardRef(((e,t)=>{const{children:n,width:r=10,height:a=5,...o}=e;return Wh.jsx(VL.svg,{...o,ref:t,width:r,height:a,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:Wh.jsx("polygon",{points:"0,0 30,0 15,10"})})}));MF.displayName="Arrow";var FF=MF;function jF(e){const[t,n]=K.useState(void 0);return rM((()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const t=new ResizeObserver((t=>{if(!Array.isArray(t))return;if(!t.length)return;const r=t[0];let a,o;if("borderBoxSize"in r){const e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;a=t.inlineSize,o=t.blockSize}else a=e.offsetWidth,o=e.offsetHeight;n({width:a,height:o})}));return t.observe(e,{box:"border-box"}),()=>t.unobserve(e)}n(void 0)}),[e]),t}var BF="Popper",[zF,HF]=jL(BF),[UF,$F]=zF(BF),GF=e=>{const{__scopePopper:t,children:n}=e,[r,a]=K.useState(null);return Wh.jsx(UF,{scope:t,anchor:r,onAnchorChange:a,children:n})};GF.displayName=BF;var VF="PopperAnchor",qF=K.forwardRef(((e,t)=>{const{__scopePopper:n,virtualRef:r,...a}=e,o=$F(VF,n),i=K.useRef(null),s=FL(t,i);return K.useEffect((()=>{o.onAnchorChange((null==r?void 0:r.current)||i.current)})),r?null:Wh.jsx(VL.div,{...a,ref:s})}));qF.displayName=VF;var WF="PopperContent",[YF,KF]=zF(WF),XF=K.forwardRef(((e,t)=>{var n,r,a,o,i,s;const{__scopePopper:l,side:c="bottom",sideOffset:u=0,align:d="center",alignOffset:p=0,arrowPadding:h=0,avoidCollisions:f=!0,collisionBoundary:m=[],collisionPadding:g=0,sticky:y="partial",hideWhenDetached:b=!1,updatePositionStrategy:v="optimized",onPlaced:k,...w}=e,x=$F(WF,l),[E,_]=K.useState(null),S=FL(t,(e=>_(e))),[T,C]=K.useState(null),A=jF(T),N=(null==A?void 0:A.width)??0,I=(null==A?void 0:A.height)??0,R=c+("center"!==d?"-"+d:""),O="number"==typeof g?g:{top:0,right:0,bottom:0,left:0,...g},P=Array.isArray(m)?m:[m],D=P.length>0,L={padding:O,boundary:P.filter(ej),altBoundary:D},{refs:M,floatingStyles:F,placement:j,isPositioned:B,middlewareData:z}=CF({strategy:"fixed",placement:R,whileElementsMounted:(...e)=>hF(...e,{animationFrame:"always"===v}),elements:{reference:x.anchor},middleware:[NF({mainAxis:u+I,alignmentAxis:p}),f&&IF({mainAxis:!0,crossAxis:!1,limiter:"partial"===y?RF():void 0,...L}),f&&OF({...L}),PF({...L,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{const{width:a,height:o}=t.reference,i=e.floating.style;i.setProperty("--radix-popper-available-width",`${n}px`),i.setProperty("--radix-popper-available-height",`${r}px`),i.setProperty("--radix-popper-anchor-width",`${a}px`),i.setProperty("--radix-popper-anchor-height",`${o}px`)}}),T&&LF({element:T,padding:h}),tj({arrowWidth:N,arrowHeight:I}),b&&DF({strategy:"referenceHidden",...L})]}),[H,U]=nj(j),$=qL(k);rM((()=>{B&&(null==$||$())}),[B,$]);const G=null==(n=z.arrow)?void 0:n.x,V=null==(r=z.arrow)?void 0:r.y,q=0!==(null==(a=z.arrow)?void 0:a.centerOffset),[W,Y]=K.useState();return rM((()=>{E&&Y(window.getComputedStyle(E).zIndex)}),[E]),Wh.jsx("div",{ref:M.setFloating,"data-radix-popper-content-wrapper":"",style:{...F,transform:B?F.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:W,"--radix-popper-transform-origin":[null==(o=z.transformOrigin)?void 0:o.x,null==(i=z.transformOrigin)?void 0:i.y].join(" "),...(null==(s=z.hide)?void 0:s.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:Wh.jsx(YF,{scope:l,placedSide:H,onArrowChange:C,arrowX:G,arrowY:V,shouldHideArrow:q,children:Wh.jsx(VL.div,{"data-side":H,"data-align":U,...w,ref:S,style:{...w.style,animation:B?void 0:"none"}})})})}));XF.displayName=WF;var QF="PopperArrow",ZF={top:"bottom",right:"left",bottom:"top",left:"right"},JF=K.forwardRef((function(e,t){const{__scopePopper:n,...r}=e,a=KF(QF,n),o=ZF[a.placedSide];return Wh.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:Wh.jsx(FF,{...r,ref:t,style:{...r.style,display:"block"}})})}));function ej(e){return null!==e}JF.displayName=QF;var tj=e=>({name:"transformOrigin",options:e,fn(t){var n,r,a;const{placement:o,rects:i,middlewareData:s}=t,l=0!==(null==(n=s.arrow)?void 0:n.centerOffset),c=l?0:e.arrowWidth,u=l?0:e.arrowHeight,[d,p]=nj(o),h={start:"0%",center:"50%",end:"100%"}[p],f=((null==(r=s.arrow)?void 0:r.x)??0)+c/2,m=((null==(a=s.arrow)?void 0:a.y)??0)+u/2;let g="",y="";return"bottom"===d?(g=l?h:`${f}px`,y=-u+"px"):"top"===d?(g=l?h:`${f}px`,y=`${i.floating.height+u}px`):"right"===d?(g=-u+"px",y=l?h:`${m}px`):"left"===d&&(g=`${i.floating.width+u}px`,y=l?h:`${m}px`),{data:{x:g,y:y}}}});function nj(e){const[t,n="center"]=e.split("-");return[t,n]}var rj=GF,aj=qF,oj=XF,ij=JF;var sj=e=>{const{present:t,children:n}=e,r=function(e){const[t,n]=K.useState(),r=K.useRef({}),a=K.useRef(e),o=K.useRef("none"),i=e?"mounted":"unmounted",[s,l]=function(e,t){return K.useReducer(((e,n)=>t[e][n]??e),e)}(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return K.useEffect((()=>{const e=lj(r.current);o.current="mounted"===s?e:"none"}),[s]),rM((()=>{const t=r.current,n=a.current;if(n!==e){const r=o.current,i=lj(t);if(e)l("MOUNT");else if("none"===i||"none"===(null==t?void 0:t.display))l("UNMOUNT");else{l(n&&r!==i?"ANIMATION_OUT":"UNMOUNT")}a.current=e}}),[e,l]),rM((()=>{if(t){let e;const n=t.ownerDocument.defaultView??window,i=o=>{const i=lj(r.current).includes(o.animationName);if(o.target===t&&i&&(l("ANIMATION_END"),!a.current)){const r=t.style.animationFillMode;t.style.animationFillMode="forwards",e=n.setTimeout((()=>{"forwards"===t.style.animationFillMode&&(t.style.animationFillMode=r)}))}},s=e=>{e.target===t&&(o.current=lj(r.current))};return t.addEventListener("animationstart",s),t.addEventListener("animationcancel",i),t.addEventListener("animationend",i),()=>{n.clearTimeout(e),t.removeEventListener("animationstart",s),t.removeEventListener("animationcancel",i),t.removeEventListener("animationend",i)}}l("ANIMATION_END")}),[t,l]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:K.useCallback((e=>{e&&(r.current=getComputedStyle(e)),n(e)}),[])}}(t),a="function"==typeof n?n({present:r.isPresent}):K.Children.only(n),o=FL(r.ref,function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;if(a)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a)return e.props.ref;return e.props.ref||e.ref}(a));return"function"==typeof n||r.isPresent?K.cloneElement(a,{ref:o}):null};function lj(e){return(null==e?void 0:e.animationName)||"none"}function cj({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,a]=function({defaultProp:e,onChange:t}){const n=K.useState(e),[r]=n,a=K.useRef(r),o=qL(t);return K.useEffect((()=>{a.current!==r&&(o(r),a.current=r)}),[r,a,o]),n}({defaultProp:t,onChange:n}),o=void 0!==e,i=o?e:r,s=qL(n);return[i,K.useCallback((t=>{if(o){const n="function"==typeof t?t(e):t;n!==e&&s(n)}else a(t)}),[o,e,a,s])]}sj.displayName="Presence";var uj=K.forwardRef(((e,t)=>Wh.jsx(VL.span,{...e,ref:t,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}})));uj.displayName="VisuallyHidden";var dj=uj,[pj,hj]=jL("Tooltip",[HF]),fj=HF(),mj="TooltipProvider",gj=700,yj="tooltip.open",[bj,vj]=pj(mj),kj=e=>{const{__scopeTooltip:t,delayDuration:n=gj,skipDelayDuration:r=300,disableHoverableContent:a=!1,children:o}=e,[i,s]=K.useState(!0),l=K.useRef(!1),c=K.useRef(0);return K.useEffect((()=>{const e=c.current;return()=>window.clearTimeout(e)}),[]),Wh.jsx(bj,{scope:t,isOpenDelayed:i,delayDuration:n,onOpen:K.useCallback((()=>{window.clearTimeout(c.current),s(!1)}),[]),onClose:K.useCallback((()=>{window.clearTimeout(c.current),c.current=window.setTimeout((()=>s(!0)),r)}),[r]),isPointerInTransitRef:l,onPointerInTransitChange:K.useCallback((e=>{l.current=e}),[]),disableHoverableContent:a,children:o})};kj.displayName=mj;var wj="Tooltip",[xj,Ej]=pj(wj),_j=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:a=!1,onOpenChange:o,disableHoverableContent:i,delayDuration:s}=e,l=vj(wj,e.__scopeTooltip),c=fj(t),[u,d]=K.useState(null),p=iM(),h=K.useRef(0),f=i??l.disableHoverableContent,m=s??l.delayDuration,g=K.useRef(!1),[y=!1,b]=cj({prop:r,defaultProp:a,onChange:e=>{e?(l.onOpen(),document.dispatchEvent(new CustomEvent(yj))):l.onClose(),null==o||o(e)}}),v=K.useMemo((()=>y?g.current?"delayed-open":"instant-open":"closed"),[y]),k=K.useCallback((()=>{window.clearTimeout(h.current),h.current=0,g.current=!1,b(!0)}),[b]),w=K.useCallback((()=>{window.clearTimeout(h.current),h.current=0,b(!1)}),[b]),x=K.useCallback((()=>{window.clearTimeout(h.current),h.current=window.setTimeout((()=>{g.current=!0,b(!0),h.current=0}),m)}),[m,b]);return K.useEffect((()=>()=>{h.current&&(window.clearTimeout(h.current),h.current=0)}),[]),Wh.jsx(rj,{...c,children:Wh.jsx(xj,{scope:t,contentId:p,open:y,stateAttribute:v,trigger:u,onTriggerChange:d,onTriggerEnter:K.useCallback((()=>{l.isOpenDelayed?x():k()}),[l.isOpenDelayed,x,k]),onTriggerLeave:K.useCallback((()=>{f?w():(window.clearTimeout(h.current),h.current=0)}),[w,f]),onOpen:k,onClose:w,disableHoverableContent:f,children:n})})};_j.displayName=wj;var Sj="TooltipTrigger",Tj=K.forwardRef(((e,t)=>{const{__scopeTooltip:n,...r}=e,a=Ej(Sj,n),o=vj(Sj,n),i=fj(n),s=FL(t,K.useRef(null),a.onTriggerChange),l=K.useRef(!1),c=K.useRef(!1),u=K.useCallback((()=>l.current=!1),[]);return K.useEffect((()=>()=>document.removeEventListener("pointerup",u)),[u]),Wh.jsx(aj,{asChild:!0,...i,children:Wh.jsx(VL.button,{"aria-describedby":a.open?a.contentId:void 0,"data-state":a.stateAttribute,...r,ref:s,onPointerMove:DL(e.onPointerMove,(e=>{"touch"!==e.pointerType&&(c.current||o.isPointerInTransitRef.current||(a.onTriggerEnter(),c.current=!0))})),onPointerLeave:DL(e.onPointerLeave,(()=>{a.onTriggerLeave(),c.current=!1})),onPointerDown:DL(e.onPointerDown,(()=>{l.current=!0,document.addEventListener("pointerup",u,{once:!0})})),onFocus:DL(e.onFocus,(()=>{l.current||a.onOpen()})),onBlur:DL(e.onBlur,a.onClose),onClick:DL(e.onClick,a.onClose)})})}));Tj.displayName=Sj;var[Cj,Aj]=pj("TooltipPortal",{forceMount:void 0}),Nj="TooltipContent",Ij=K.forwardRef(((e,t)=>{const n=Aj(Nj,e.__scopeTooltip),{forceMount:r=n.forceMount,side:a="top",...o}=e,i=Ej(Nj,e.__scopeTooltip);return Wh.jsx(sj,{present:r||i.open,children:i.disableHoverableContent?Wh.jsx(Dj,{side:a,...o,ref:t}):Wh.jsx(Rj,{side:a,...o,ref:t})})})),Rj=K.forwardRef(((e,t)=>{const n=Ej(Nj,e.__scopeTooltip),r=vj(Nj,e.__scopeTooltip),a=K.useRef(null),o=FL(t,a),[i,s]=K.useState(null),{trigger:l,onClose:c}=n,u=a.current,{onPointerInTransitChange:d}=r,p=K.useCallback((()=>{s(null),d(!1)}),[d]),h=K.useCallback(((e,t)=>{const n=e.currentTarget,r={x:e.clientX,y:e.clientY},a=function(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n})}return r}(r,function(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),a=Math.abs(t.right-e.x),o=Math.abs(t.left-e.x);switch(Math.min(n,r,a,o)){case o:return"left";case a:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}(r,n.getBoundingClientRect())),o=function(e){const t=e.slice();return t.sort(((e,t)=>e.x<t.x?-1:e.x>t.x?1:e.y<t.y?-1:e.y>t.y?1:0)),function(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const n=e[r];for(;t.length>=2;){const e=t[t.length-1],r=t[t.length-2];if(!((e.x-r.x)*(n.y-r.y)>=(e.y-r.y)*(n.x-r.x)))break;t.pop()}t.push(n)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const t=e[r];for(;n.length>=2;){const e=n[n.length-1],r=n[n.length-2];if(!((e.x-r.x)*(t.y-r.y)>=(e.y-r.y)*(t.x-r.x)))break;n.pop()}n.push(t)}return n.pop(),1===t.length&&1===n.length&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}(t)}([...a,...function(e){const{top:t,right:n,bottom:r,left:a}=e;return[{x:a,y:t},{x:n,y:t},{x:n,y:r},{x:a,y:r}]}(t.getBoundingClientRect())]);s(o),d(!0)}),[d]);return K.useEffect((()=>()=>p()),[p]),K.useEffect((()=>{if(l&&u){const e=e=>h(e,u),t=e=>h(e,l);return l.addEventListener("pointerleave",e),u.addEventListener("pointerleave",t),()=>{l.removeEventListener("pointerleave",e),u.removeEventListener("pointerleave",t)}}}),[l,u,h,p]),K.useEffect((()=>{if(i){const e=e=>{const t=e.target,n={x:e.clientX,y:e.clientY},r=(null==l?void 0:l.contains(t))||(null==u?void 0:u.contains(t)),a=!function(e,t){const{x:n,y:r}=e;let a=!1;for(let o=0,i=t.length-1;o<t.length;i=o++){const e=t[o].x,s=t[o].y,l=t[i].x,c=t[i].y;s>r!=c>r&&n<(l-e)*(r-s)/(c-s)+e&&(a=!a)}return a}(n,i);r?p():a&&(p(),c())};return document.addEventListener("pointermove",e),()=>document.removeEventListener("pointermove",e)}}),[l,u,i,c,p]),Wh.jsx(Dj,{...e,ref:o})})),[Oj,Pj]=pj(wj,{isInside:!1}),Dj=K.forwardRef(((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":a,onEscapeKeyDown:o,onPointerDownOutside:i,...s}=e,l=Ej(Nj,n),c=fj(n),{onClose:u}=l;return K.useEffect((()=>(document.addEventListener(yj,u),()=>document.removeEventListener(yj,u))),[u]),K.useEffect((()=>{if(l.trigger){const e=e=>{const t=e.target;(null==t?void 0:t.contains(l.trigger))&&u()};return window.addEventListener("scroll",e,{capture:!0}),()=>window.removeEventListener("scroll",e,{capture:!0})}}),[l.trigger,u]),Wh.jsx(JL,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:i,onFocusOutside:e=>e.preventDefault(),onDismiss:u,children:Wh.jsxs(oj,{"data-state":l.stateAttribute,...c,...s,ref:t,style:{...s.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[Wh.jsx(UL,{children:r}),Wh.jsx(Oj,{scope:n,isInside:!0,children:Wh.jsx(dj,{id:l.contentId,role:"tooltip",children:a||r})})]})})}));Ij.displayName=Nj;var Lj="TooltipArrow",Mj=K.forwardRef(((e,t)=>{const{__scopeTooltip:n,...r}=e,a=fj(n);return Pj(Lj,n).isInside?null:Wh.jsx(ij,{...a,...r,ref:t})}));Mj.displayName=Lj;var Fj=kj,jj=Tj,Bj=Ij,zj=Mj;const Hj=K.createContext(void 0),Uj=({children:e,...t})=>{const n=NL();return Wh.jsx(Hj.Provider,{value:{...n,...t},children:Wh.jsx(OL,{children:Wh.jsx(Fj,{children:e})})})},$j=()=>{const e=K.useContext(Hj);if(!e)throw new Error("useChat must be used within a ChatProvider");return e},Gj=K.createContext(void 0);function Vj({children:e}){const t=function(){var e;const[t,n]=K.useState(null),{value:r,setTrue:a,setFalse:o}=Qh(!1),[i,s]=K.useState({title:"",content:""}),[l,c]=K.useState({title:void 0,content:void 0}),{addAttachment:u}=$j(),d={data:i,errors:l,labels:{title:(null==(e=null==t?void 0:t.workflowModalProps)?void 0:e.titleInputLabel)||"Title",content:(null==t?void 0:t.contentType.contentInputLabel)||"Content"},validate(){const e={};return i.title.trim()||(e.title=`${d.labels.title} is required`),i.content.trim()||(e.content=`${d.labels.content} is required`),e},onChange(e){const{name:t,value:n}=e.target;s((e=>({...e,[t]:n})))},onSubmit(e){if(e.preventDefault(),!(null==t?void 0:t.contentType))return;const n=d.validate();if(Object.values(n).some((e=>!!e)))return void c(n);const r={...i,id:Zh(),contentType:t.contentType};u(r),o(),s({title:"",content:""}),c({title:void 0,content:void 0})}};return{selectedInput:t,selectInput:n,isOpen:r,onOpen:a,onClose:o,form:d}}();return Wh.jsx(Gj.Provider,{value:t,children:e})}const qj=()=>{const e=K.useContext(Gj);if(!e)throw new Error("useAttachmentsBar must be used within a AttachmentsBarProvider");return e},Wj=K.createContext(void 0),Yj=({children:e,name:t})=>{const n=K.useRef(null);return Wh.jsx(Wj.Provider,{value:{name:t,focusItem:n},children:e})},Kj=()=>{const e=K.useContext(Wj);if(!e)throw new Error("useFeedbackItem must be used within a FeedbackItemProvider");return e},Xj=K.createContext(void 0),Qj=({children:e,field:t,fieldProps:n,autoFocus:r})=>{const{errors:a}=dL(),o=a[t.name];return Wh.jsx(Xj.Provider,{value:{field:t,fieldProps:n,error:o,autoFocus:r},children:e})},Zj=()=>{const e=K.useContext(Xj);if(!e)throw new Error("useFormField must be used within a FormFieldProvider");return e},Jj=K.createContext(void 0);const eB=({children:e,value:t})=>Wh.jsx(Jj.Provider,{value:t,children:e}),tB=K.createContext(void 0),nB=({children:e,componentStyles:t})=>Wh.jsx(tB.Provider,{value:{componentStyles:t},children:e}),rB=K.createContext(void 0);function aB({children:e}){const[t,n]=X.useState(null),{value:r,setTrue:a,setFalse:o}=Qh(!1);return Wh.jsx(rB.Provider,{value:{selectedItem:t,selectItem:n,isOpen:r,onOpen:a,onClose:o},children:e})}const oB=()=>{const e=K.useContext(rB);if(!e)throw new Error("useMessageAttachments must be used within a MessageAttachmentsProvider");return e},iB=K.createContext(void 0),sB=({children:e,message:t})=>Wh.jsx(iB.Provider,{value:{message:t},children:e}),lB=()=>{const e=K.useContext(iB);if(!e)throw new Error("useMessage must be used within a MessageProvider");return e},cB=["light","dark"],uB="(prefers-color-scheme: dark)",dB="undefined"==typeof window,pB=K.createContext(void 0),hB={setColorMode:e=>{},colorModes:[]};function fB(e,t){const n=K.useContext(pB)??hB;return"dark"===(n.forcedColorMode??n.resolvedColorMode)?t:e}const mB=e=>(K.useContext(pB),Wh.jsx(yB,{...e})),gB=["light","dark"],yB=({forcedColorMode:e,disableTransitionOnChange:t=!1,enableSystem:n=!1,enableColorScheme:r=!0,storageKey:a="inkeep-colorMode",colorModes:o=gB,defaultColorMode:i=(n?"system":"light"),attribute:s="data-theme",value:l,children:c,nonce:u,shadowHostId:d,rootId:p})=>{const[h,f]=K.useState((()=>vB(a,i))),[m,g]=K.useState((()=>vB(a))),y=l?Object.values(l):o,b=K.useCallback((e=>{var a;let o=e;if(!o)return;"system"===e&&n&&(o=wB());const c=l?l[o]:o,u=t?kB():null,h=d&&p&&(null==(a=document.getElementById(d))?void 0:a.shadowRoot),f=h?h.getElementById(p)??document.documentElement:document.documentElement;if("class"===s?(f.classList.remove(...y),c&&f.classList.add(c)):c?f.setAttribute(s,c):f.removeAttribute(s),r){const e=cB.includes(i)?i:null,t=cB.includes(o)?o:e;f.style.colorScheme=t}null==u||u()}),[]),v=K.useCallback((e=>{f(e);try{localStorage.setItem(a,e)}catch(X4){}}),[e]),k=K.useCallback((t=>{const r=wB(t);g(r),"system"===h&&n&&!e&&b("system")}),[h,e]);K.useEffect((()=>{const e=window.matchMedia(uB);return e.addListener(k),k(e),()=>e.removeListener(k)}),[k]),K.useEffect((()=>{const e=e=>{if(e.key!==a)return;const t=e.newValue||i;v(t)};return window.addEventListener("storage",e),()=>window.removeEventListener("storage",e)}),[v]),K.useEffect((()=>{b(e??h)}),[e,h]);const w=K.useMemo((()=>({colorMode:h,setColorMode:v,forcedColorMode:e,resolvedColorMode:"system"===h?m:h,colorModes:n?[...o,"system"]:o,systemColorMode:n?m:void 0})),[h,v,e,m,n,o]);return Wh.jsxs(pB.Provider,{value:w,children:[Wh.jsx(bB,{forcedColorMode:e,disableTransitionOnChange:t,enableSystem:n,enableColorScheme:r,storageKey:a,colorModes:o,defaultColorMode:i,attribute:s,value:l,children:c,attrs:y,nonce:u,shadowHostId:d,rootId:p}),c]})},bB=K.memo((({forcedColorMode:e,storageKey:t,attribute:n,enableSystem:r,enableColorScheme:a,defaultColorMode:o,value:i,attrs:s,nonce:l,shadowHostId:c,rootId:u})=>{const d="system"===o,p=(()=>{const e=c&&u?`document.getElementById('${c}').shadowRoot.getElementById('${u}')`:"document.documentElement";if("class"===n){return`var d=${e},c=d.classList;${`c.remove(${s.map((e=>`'${e}'`)).join(",")})`};`}return`var d=${e},n='${n}',s='setAttribute';`})(),h=(()=>{if(!a)return"";return(cB.includes(o)?o:null)?`if(e==='light'||e==='dark'||!e)d.style.colorScheme=e||'${o}'`:"if(e==='light'||e==='dark')d.style.colorScheme=e"})(),f=(e,t=!1,r=!0)=>{const o=i?i[e]:e,s=t?`${e}|| ''`:`'${o}'`;let l="";return a&&r&&!t&&cB.includes(e)&&(l+=`d.style.colorScheme = '${e}';`),"class"===n?l+=t||o?`c.add(${s})`:"null":o&&(l+=`d[s](n,${s})`),l},m=e?`!function(){${p}${f(e)}}()`:r?`!function(){try{${p}var e=localStorage.getItem('${t}');if('system'===e||(!e&&${d})){var t='${uB}',m=window.matchMedia(t);if(m.media!==t||m.matches){${f("dark")}}else{${f("light")}}}else if(e){${i?`var x=${JSON.stringify(i)};`:""}${f(i?"x[e]":"e",!0)}}${d?"":`else{${f(o,!1,!1)}}`}${h}}catch(e){}}()`:`!function(){try{${p}var e=localStorage.getItem('${t}');if(e){${i?`var x=${JSON.stringify(i)};`:""}${f(i?"x[e]":"e",!0)}}else{${f(o,!1,!1)};}${h}}catch(t){}}();`;return Wh.jsx("script",{nonce:l,dangerouslySetInnerHTML:{__html:m}})}),(()=>!0)),vB=(e,t)=>{if(dB)return;let n;try{n=localStorage.getItem(e)||void 0}catch(X4){}return n||t},kB=()=>{const e=document.createElement("style");return e.appendChild(document.createTextNode("*{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}")),document.head.appendChild(e),()=>{window.getComputedStyle(document.body),setTimeout((()=>{document.head.removeChild(e)}),1)}},wB=e=>{e||(e=window.matchMedia(uB));return e.matches?"dark":"light"};var xB=Object.prototype.hasOwnProperty;function EB(e,t,n){for(n of e.keys())if(_B(n,t))return n}function _B(e,t){var n,r,a;if(e===t)return!0;if(e&&t&&(n=e.constructor)===t.constructor){if(n===Date)return e.getTime()===t.getTime();if(n===RegExp)return e.toString()===t.toString();if(n===Array){if((r=e.length)===t.length)for(;r--&&_B(e[r],t[r]););return-1===r}if(n===Set){if(e.size!==t.size)return!1;for(r of e){if((a=r)&&"object"==typeof a&&!(a=EB(t,a)))return!1;if(!t.has(a))return!1}return!0}if(n===Map){if(e.size!==t.size)return!1;for(r of e){if((a=r[0])&&"object"==typeof a&&!(a=EB(t,a)))return!1;if(!_B(r[1],t.get(a)))return!1}return!0}if(n===ArrayBuffer)e=new Uint8Array(e),t=new Uint8Array(t);else if(n===DataView){if((r=e.byteLength)===t.byteLength)for(;r--&&e.getInt8(r)===t.getInt8(r););return-1===r}if(ArrayBuffer.isView(e)){if((r=e.byteLength)===t.byteLength)for(;r--&&e[r]===t[r];);return-1===r}if(!n||"object"==typeof e){for(n in r=0,e){if(xB.call(e,n)&&++r&&!xB.call(t,n))return!1;if(!(n in t)||!_B(e[n],t[n]))return!1}return Object.keys(t).length===r}}return e!=e&&t!=t}function SB(){const{baseSettings:e}=nP(),[t,n]=K.useState([]),r=function(e){const t=K.useRef(void 0);_B(t.current,e)||(t.current=e);return t.current}(e.theme.styles),{customStyles:a,linksCount:o}=K.useMemo((()=>{if(!r||!Array.isArray(r))return{customStyles:null,loaded:!0};const{links:e,styleSheets:t}=r.reduce(((e,t)=>("link"===t.type?e.links.push(t):"style"===t.type&&e.styleSheets.push(t),e)),{links:[],styleSheets:[]}),a=t.map((e=>Wh.jsx("style",{type:"text/css",dangerouslySetInnerHTML:{__html:e.value}},e.key??ef("link_")))),o=e.map((e=>{const t=e.key??ef("stylesheet_");return Wh.jsx("link",{id:t,rel:"stylesheet",type:"text/css",href:e.value,onLoad:()=>{n((t=>[...new Set([...t,e.value])]))}},t)}));return{customStyles:Wh.jsxs(Wh.Fragment,{children:[o,a]}),linksCount:e.length}}),[r]);return{customStyles:a,loaded:t.length>=(o??0)}}const TB=({children:e})=>{const{baseSettings:t}=nP(),{theme:n,primaryBrandColor:r,shadowHost:a,rootElement:o,colorMode:i}=t,{primaryColors:s,varsClassName:l}=n,{disableLoadingDefaultFont:c,fontFamily:u,fontSize:d,zIndex:p}=n,h=Cx(s,r),f=function(e){const t={};for(const[n,r]of Object.entries(e)){const e=Nx[n]||n,a=(n,r=[])=>{for(const[o,i]of Object.entries(n)){const n=[...r,o];if("object"==typeof i&&null!==i)a(i,n);else{const r=n.map((e=>e.replace(/([A-Z])/g,"-$1").toLowerCase())).join("-");t[`--ikp-${e}-${r}`]=i}}};a(r)}return t}({colors:Ph(n.colors,h),fontFamily:u,fontSize:d,zIndex:p}),{customStyles:m,loaded:g}=SB(),{sync:y,forcedColorMode:b,...v}=i??{},[k,w]=K.useState(),x=K.useRef(null);return K.useEffect((()=>{var e,t;if(!(null==y?void 0:y.target))return;const n="string"==typeof y.target?document.querySelector(y.target):y.target;if(!n)return;function r(e,t){return t.reduce(((t,n)=>({...t,[n]:e.getAttribute(n)})),{})}const a=new MutationObserver((()=>{var e,t;const a=r(n,y.attributes),o=(null==(e=y.isDarkMode)?void 0:e.call(y,a))?"dark":"light";null==(t=y.onChange)||t.call(y,o),w(o)}));a.observe(n,{attributes:!0,attributeFilter:y.attributes,childList:!1,subtree:!1}),x.current=a;const o=(null==(e=y.isDarkMode)?void 0:e.call(y,r(n,null==y?void 0:y.attributes)))?"dark":"light";return null==(t=y.onChange)||t.call(y,o),w(o),()=>a.disconnect()}),[y]),Wh.jsxs(Wh.Fragment,{children:[!c&&Wh.jsx("style",{type:"text/css",dangerouslySetInnerHTML:{__html:"\n @import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;900&display=swap');\n "}}),m,g&&Wh.jsx(mB,{forcedColorMode:b??k,...v,shadowHostId:null==a?void 0:a.id,rootId:null==o?void 0:o.id,children:Wh.jsx("div",{className:l,style:{display:"contents",...f},children:e})})]})};function CB(e){const{children:t,config:n,componentType:r}=e;return Wh.jsx(tP,{value:{...n,componentType:r},children:Wh.jsx(TB,{children:Wh.jsx(fP,{children:Wh.jsx(yP,{children:t})})})})}const AB=K.createContext(void 0),NB=({children:e,source:t})=>Wh.jsx(AB.Provider,{value:{source:t},children:e}),IB=()=>{const e=K.useContext(AB);if(!e)throw new Error("useSourceItem must be used within a SourceItemProvider");return e};function RB(e){const t=K.useRef(e);return K.useEffect((()=>{t.current=e})),K.useMemo((()=>(...e)=>{var n;return null==(n=t.current)?void 0:n.call(t,...e)}),[])}function OB({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,a]=function({defaultProp:e,onChange:t}){const n=K.useState(e),[r]=n,a=K.useRef(r),o=RB(t);return K.useEffect((()=>{a.current!==r&&(o(r),a.current=r)}),[r,a,o]),n}({defaultProp:t,onChange:n}),o=void 0!==e,i=o?e:r,s=RB(n);return[i,K.useCallback((t=>{if(o){const n="function"==typeof t?t(e):t;n!==e&&s(n)}else a(t)}),[o,e,a,s])]}const PB=K.createContext(void 0),DB=({children:e,value:t})=>Wh.jsx(PB.Provider,{value:t,children:e}),LB=()=>{const e=K.useContext(PB);if(!e)throw new Error("useSidebarChat must be used within a SidebarChatProvider");return e};function MB(e,t){var n;const{prefix:r}=nP(),a=K.useContext(tB),o=function(e,t){return!!(null==t?void 0:t.componentStyles)&&e in t.componentStyles}(e,a);return[t,o?null==(n=null==a?void 0:a.componentStyles)?void 0:n[e]:void 0,`${r}-${_L(e)}`].filter(Boolean).join(" ")}function FB(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function jB(...e){return t=>{let n=!1;const r=e.map((e=>{const r=FB(e,t);return n||"function"!=typeof r||(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():FB(e[t],null)}}}}function BB(...e){return K.useCallback(jB(...e),e)}const zB=(...e)=>e.map((e=>{var t;return null==(t=null==e?void 0:e.trim)?void 0:t.call(e)})).filter(Boolean).join(" "),HB=/((?:--)?(?:\w+-?)+)\s*:\s*([^;]*)/g,UB=e=>{const t={};let n;for(;n=HB.exec(e);)t[n[1]]=n[2];return t},$B=(e,t)=>{if(EL(e)){if(EL(t))return`${e};${t}`;e=UB(e)}else EL(t)&&(t=UB(t));return Object.assign({},e??{},t??{})};function GB(...e){let t={};for(let n of e){for(let e in t)e.startsWith("on")&&"function"==typeof t[e]&&"function"==typeof n[e]?t[e]=xL(n[e],t[e]):t[e]="className"!==e&&"class"!==e?"style"!==e?void 0!==n[e]?n[e]:t[e]:$B(t[e],n[e]):zB(t[e],n[e]);for(let e in n)void 0===t[e]&&(t[e]=n[e])}return t}const VB=(e,t)=>{const n=K.memo(K.forwardRef(((n,r)=>{const{_id:a,className:o,children:i,...s}=t,{asChild:l,children:c,...u}=n,d=c||i,p=GB(s,u,{className:MB(a,o),"data-part":_L(a)});if(!l)return K.createElement(e,{...p,ref:r},d);const h=K.Children.only(d);if(!K.isValidElement(h))return null;const f=function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;return a?e.ref:(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a?e.props.ref:e.props.ref||e.ref)}(h);return K.cloneElement(h,{...GB(p,h.props),ref:r?jB(r,f):f})})));return n.displayName=e.displayName||e.name,n},qB=new Proxy(VB,{apply(e,t,n){const r=n[0],a=n[1];return VB(r,a)}});function WB(){return WB=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},WB.apply(null,arguments)}function YB(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}var KB=K.useLayoutEffect,XB=function(e,t){"function"!=typeof e?e.current=t:e(t)},QB={"min-height":"0","max-height":"none",height:"0",visibility:"hidden",overflow:"hidden",position:"absolute","z-index":"-1000",top:"0",right:"0",display:"block"},ZB=function(e){Object.keys(QB).forEach((function(t){e.style.setProperty(t,QB[t],"important")}))},JB=null,ez=function(e,t){var n=e.scrollHeight;return"border-box"===t.sizingStyle.boxSizing?n+t.borderSize:n-t.paddingSize};var tz=function(){},nz=["borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","boxSizing","fontFamily","fontSize","fontStyle","fontWeight","letterSpacing","lineHeight","paddingBottom","paddingLeft","paddingRight","paddingTop","tabSize","textIndent","textRendering","textTransform","width","wordBreak","wordSpacing","scrollbarGutter"],rz=!!document.documentElement.currentStyle,az=function(e){var t=window.getComputedStyle(e);if(null===t)return null;var n,r=(n=t,nz.reduce((function(e,t){return e[t]=n[t],e}),{})),a=r.boxSizing;return""===a?null:(rz&&"border-box"===a&&(r.width=parseFloat(r.width)+parseFloat(r.borderRightWidth)+parseFloat(r.borderLeftWidth)+parseFloat(r.paddingRight)+parseFloat(r.paddingLeft)+"px"),{sizingStyle:r,paddingSize:parseFloat(r.paddingBottom)+parseFloat(r.paddingTop),borderSize:parseFloat(r.borderBottomWidth)+parseFloat(r.borderTopWidth)})};function oz(e,t,n){var r,a,o=(r=n,a=X.useRef(r),KB((function(){a.current=r})),a);K.useLayoutEffect((function(){var n=function(e){return o.current(e)};if(e)return e.addEventListener(t,n),function(){return e.removeEventListener(t,n)}}),[])}var iz=["cacheMeasurements","maxRows","minRows","onChange","onHeightChange"],sz=function(e,t){var n=e.cacheMeasurements,r=e.maxRows,a=e.minRows,o=e.onChange,i=void 0===o?tz:o,s=e.onHeightChange,l=void 0===s?tz:s,c=YB(e,iz),u=void 0!==c.value,d=K.useRef(null),p=function(e,t){var n=X.useRef();return X.useCallback((function(r){e.current=r,n.current&&XB(n.current,null),n.current=t,t&&XB(t,r)}),[t])}(d,t),h=K.useRef(0),f=K.useRef(),m=function(){var e=d.current,t=n&&f.current?f.current:az(e);if(t){f.current=t;var o=function(e,t,n,r){void 0===n&&(n=1),void 0===r&&(r=1/0),JB||((JB=document.createElement("textarea")).setAttribute("tabindex","-1"),JB.setAttribute("aria-hidden","true"),ZB(JB)),null===JB.parentNode&&document.body.appendChild(JB);var a=e.paddingSize,o=e.borderSize,i=e.sizingStyle,s=i.boxSizing;Object.keys(i).forEach((function(e){var t=e;JB.style[t]=i[t]})),ZB(JB),JB.value=t;var l=ez(JB,e);JB.value=t,l=ez(JB,e),JB.value="x";var c=JB.scrollHeight-a,u=c*n;"border-box"===s&&(u=u+a+o),l=Math.max(u,l);var d=c*r;return"border-box"===s&&(d=d+a+o),[l=Math.min(d,l),c]}(t,e.value||e.placeholder||"x",a,r),i=o[0],s=o[1];h.current!==i&&(h.current=i,e.style.setProperty("height",i+"px","important"),l(i,{rowHeight:s}))}};return K.useLayoutEffect(m),function(e,t){oz(document.body,"reset",(function(n){e.current.form===n.target&&t(n)}))}(d,(function(){if(!u){var e=d.current,t=e.value;requestAnimationFrame((function(){t!==e.value&&m()}))}})),oz(window,"resize",m),function(e){oz(document.fonts,"loadingdone",e)}(m),K.createElement("textarea",WB({},c,{onChange:function(e){u||m(),i(e)},ref:p}))},lz=K.forwardRef(sz),cz="Avatar",[uz,dz]=jL(cz),[pz,hz]=uz(cz),fz=K.forwardRef(((e,t)=>{const{__scopeAvatar:n,...r}=e,[a,o]=K.useState("idle");return Wh.jsx(pz,{scope:n,imageLoadingStatus:a,onImageLoadingStatusChange:o,children:Wh.jsx(VL.span,{...r,ref:t})})}));fz.displayName=cz;var mz="AvatarImage",gz=K.forwardRef(((e,t)=>{const{__scopeAvatar:n,src:r,onLoadingStatusChange:a=()=>{},...o}=e,i=hz(mz,n),s=function(e,t){const[n,r]=K.useState("idle");return rM((()=>{if(!e)return void r("error");let n=!0;const a=new window.Image,o=e=>()=>{n&&r(e)};return r("loading"),a.onload=o("loaded"),a.onerror=o("error"),a.src=e,t&&(a.referrerPolicy=t),()=>{n=!1}}),[e,t]),n}(r,o.referrerPolicy),l=qL((e=>{a(e),i.onImageLoadingStatusChange(e)}));return rM((()=>{"idle"!==s&&l(s)}),[s,l]),"loaded"===s?Wh.jsx(VL.img,{...o,ref:t,src:r}):null}));gz.displayName=mz;var yz="AvatarFallback",bz=K.forwardRef(((e,t)=>{const{__scopeAvatar:n,delayMs:r,...a}=e,o=hz(yz,n),[i,s]=K.useState(void 0===r);return K.useEffect((()=>{if(void 0!==r){const e=window.setTimeout((()=>s(!0)),r);return()=>window.clearTimeout(e)}}),[r]),i&&"loaded"!==o.imageLoadingStatus?Wh.jsx(VL.span,{...a,ref:t}):null}));bz.displayName=yz;var vz=fz,kz=gz,wz=bz;var xz="Checkbox",[Ez,_z]=jL(xz),[Sz,Tz]=Ez(xz),Cz=K.forwardRef(((e,t)=>{const{__scopeCheckbox:n,name:r,checked:a,defaultChecked:o,required:i,disabled:s,value:l="on",onCheckedChange:c,form:u,...d}=e,[p,h]=K.useState(null),f=FL(t,(e=>h(e))),m=K.useRef(!1),g=!p||(u||!!p.closest("form")),[y=!1,b]=cj({prop:a,defaultProp:o,onChange:c}),v=K.useRef(y);return K.useEffect((()=>{const e=null==p?void 0:p.form;if(e){const t=()=>b(v.current);return e.addEventListener("reset",t),()=>e.removeEventListener("reset",t)}}),[p,b]),Wh.jsxs(Sz,{scope:n,state:y,disabled:s,children:[Wh.jsx(VL.button,{type:"button",role:"checkbox","aria-checked":Rz(y)?"mixed":y,"aria-required":i,"data-state":Oz(y),"data-disabled":s?"":void 0,disabled:s,value:l,...d,ref:f,onKeyDown:DL(e.onKeyDown,(e=>{"Enter"===e.key&&e.preventDefault()})),onClick:DL(e.onClick,(e=>{b((e=>!!Rz(e)||!e)),g&&(m.current=e.isPropagationStopped(),m.current||e.stopPropagation())}))}),g&&Wh.jsx(Iz,{control:p,bubbles:!m.current,name:r,value:l,checked:y,required:i,disabled:s,form:u,style:{transform:"translateX(-100%)"},defaultChecked:!Rz(o)&&o})]})}));Cz.displayName=xz;var Az="CheckboxIndicator",Nz=K.forwardRef(((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...a}=e,o=Tz(Az,n);return Wh.jsx(sj,{present:r||Rz(o.state)||!0===o.state,children:Wh.jsx(VL.span,{"data-state":Oz(o.state),"data-disabled":o.disabled?"":void 0,...a,ref:t,style:{pointerEvents:"none",...e.style}})})}));Nz.displayName=Az;var Iz=e=>{const{control:t,checked:n,bubbles:r=!0,defaultChecked:a,...o}=e,i=K.useRef(null),s=function(e){const t=K.useRef({value:e,previous:e});return K.useMemo((()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous)),[e])}(n),l=jF(t);K.useEffect((()=>{const e=i.current,t=window.HTMLInputElement.prototype,a=Object.getOwnPropertyDescriptor(t,"checked").set;if(s!==n&&a){const t=new Event("click",{bubbles:r});e.indeterminate=Rz(n),a.call(e,!Rz(n)&&n),e.dispatchEvent(t)}}),[s,n,r]);const c=K.useRef(!Rz(n)&&n);return Wh.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:a??c.current,...o,tabIndex:-1,ref:i,style:{...e.style,...l,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function Rz(e){return"indeterminate"===e}function Oz(e){return Rz(e)?"indeterminate":e?"checked":"unchecked"}var Pz=Cz,Dz=Nz,Lz=K.forwardRef(((e,t)=>{const{children:n,...r}=e,a=K.Children.toArray(n),o=a.find(jz);if(o){const e=o.props.children,n=a.map((t=>t===o?K.Children.count(e)>1?K.Children.only(null):K.isValidElement(e)?e.props.children:null:t));return Wh.jsx(Mz,{...r,ref:t,children:K.isValidElement(e)?K.cloneElement(e,void 0,n):null})}return Wh.jsx(Mz,{...r,ref:t,children:n})}));Lz.displayName="Slot";var Mz=K.forwardRef(((e,t)=>{const{children:n,...r}=e;if(K.isValidElement(n)){const e=function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;if(a)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a)return e.props.ref;return e.props.ref||e.ref}(n),a=function(e,t){const n={...t};for(const r in t){const a=e[r],o=t[r];/^on[A-Z]/.test(r)?a&&o?n[r]=(...e)=>{o(...e),a(...e)}:a&&(n[r]=a):"style"===r?n[r]={...a,...o}:"className"===r&&(n[r]=[a,o].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props);return n.type!==K.Fragment&&(a.ref=t?ML(t,e):e),K.cloneElement(n,a)}return K.Children.count(n)>1?K.Children.only(null):null}));Mz.displayName="SlotClone";var Fz=({children:e})=>Wh.jsx(Wh.Fragment,{children:e});function jz(e){return K.isValidElement(e)&&e.type===Fz}var Bz=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce(((e,t)=>{const n=K.forwardRef(((e,n)=>{const{asChild:r,...a}=e,o=r?Lz:t;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),Wh.jsx(o,{...a,ref:n})}));return n.displayName=`Primitive.${t}`,{...e,[t]:n}}),{});var zz,Hz="dismissableLayer.update",Uz="dismissableLayer.pointerDownOutside",$z="dismissableLayer.focusOutside",Gz=K.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Vz=K.forwardRef(((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:a,onFocusOutside:o,onInteractOutside:i,onDismiss:s,...l}=e,c=K.useContext(Gz),[u,d]=K.useState(null),p=(null==u?void 0:u.ownerDocument)??(null==globalThis?void 0:globalThis.document),[,h]=K.useState({}),f=FL(t,(e=>d(e))),m=Array.from(c.layers),[g]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),y=m.indexOf(g),b=u?m.indexOf(u):-1,v=c.layersWithOutsidePointerEventsDisabled.size>0,k=b>=y,w=function(e,t=(null==globalThis?void 0:globalThis.document)){const n=qL(e),r=K.useRef(!1),a=K.useRef((()=>{}));return K.useEffect((()=>{const e=e=>{if(e.target&&!r.current){let r=function(){Yz(Uz,n,o,{discrete:!0})};const o={originalEvent:e};"touch"===e.pointerType?(t.removeEventListener("click",a.current),a.current=r,t.addEventListener("click",a.current,{once:!0})):r()}else t.removeEventListener("click",a.current);r.current=!1},o=window.setTimeout((()=>{t.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(o),t.removeEventListener("pointerdown",e),t.removeEventListener("click",a.current)}}),[t,n]),{onPointerDownCapture:()=>r.current=!0}}((e=>{const t=e.target,n=[...c.branches].some((e=>e.contains(t)));k&&!n&&(null==a||a(e),null==i||i(e),e.defaultPrevented||null==s||s())}),p),x=function(e,t=(null==globalThis?void 0:globalThis.document)){const n=qL(e),r=K.useRef(!1);return K.useEffect((()=>{const e=e=>{if(e.target&&!r.current){Yz($z,n,{originalEvent:e},{discrete:!1})}};return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)}),[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}((e=>{const t=e.target;[...c.branches].some((e=>e.contains(t)))||(null==o||o(e),null==i||i(e),e.defaultPrevented||null==s||s())}),p);return WL((e=>{b===c.layers.size-1&&(null==r||r(e),!e.defaultPrevented&&s&&(e.preventDefault(),s()))}),p),K.useEffect((()=>{if(u)return n&&(0===c.layersWithOutsidePointerEventsDisabled.size&&(zz=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(u)),c.layers.add(u),Wz(),()=>{n&&1===c.layersWithOutsidePointerEventsDisabled.size&&(p.body.style.pointerEvents=zz)}}),[u,p,n,c]),K.useEffect((()=>()=>{u&&(c.layers.delete(u),c.layersWithOutsidePointerEventsDisabled.delete(u),Wz())}),[u,c]),K.useEffect((()=>{const e=()=>h({});return document.addEventListener(Hz,e),()=>document.removeEventListener(Hz,e)}),[]),Wh.jsx(Bz.div,{...l,ref:f,style:{pointerEvents:v?k?"auto":"none":void 0,...e.style},onFocusCapture:DL(e.onFocusCapture,x.onFocusCapture),onBlurCapture:DL(e.onBlurCapture,x.onBlurCapture),onPointerDownCapture:DL(e.onPointerDownCapture,w.onPointerDownCapture)})}));Vz.displayName="DismissableLayer";var qz=K.forwardRef(((e,t)=>{const n=K.useContext(Gz),r=K.useRef(null),a=FL(t,r);return K.useEffect((()=>{const e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}}),[n.branches]),Wh.jsx(Bz.div,{...e,ref:a})}));function Wz(){const e=new CustomEvent(Hz);document.dispatchEvent(e)}function Yz(e,t,n,{discrete:r}){const a=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&a.addEventListener(e,t,{once:!0}),r?function(e,t){e&&se.flushSync((()=>e.dispatchEvent(t)))}(a,o):a.dispatchEvent(o)}qz.displayName="DismissableLayerBranch";var Kz=0;function Xz(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var Qz="focusScope.autoFocusOnMount",Zz="focusScope.autoFocusOnUnmount",Jz={bubbles:!1,cancelable:!0},eH=K.forwardRef(((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:a,onUnmountAutoFocus:o,...i}=e,[s,l]=K.useState(null),c=qL(a),u=qL(o),d=K.useRef(null),p=FL(t,(e=>l(e))),h=K.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;K.useEffect((()=>{if(r){let e=function(e){if(h.paused||!s)return;const t=e.target;s.contains(t)?d.current=t:aH(d.current,{select:!0})},t=function(e){if(h.paused||!s)return;const t=e.relatedTarget;null!==t&&(s.contains(t)||aH(d.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(const t of e)t.removedNodes.length>0&&aH(s)};document.addEventListener("focusin",e),document.addEventListener("focusout",t);const r=new MutationObserver(n);return s&&r.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),r.disconnect()}}}),[r,s,h.paused]),K.useEffect((()=>{if(s){oH.add(h);const t=document.activeElement;if(!s.contains(t)){const n=new CustomEvent(Qz,Jz);s.addEventListener(Qz,c),s.dispatchEvent(n),n.defaultPrevented||(!function(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(aH(r,{select:t}),document.activeElement!==n)return}((e=tH(s),e.filter((e=>"A"!==e.tagName))),{select:!0}),document.activeElement===t&&aH(s))}return()=>{s.removeEventListener(Qz,c),setTimeout((()=>{const e=new CustomEvent(Zz,Jz);s.addEventListener(Zz,u),s.dispatchEvent(e),e.defaultPrevented||aH(t??document.body,{select:!0}),s.removeEventListener(Zz,u),oH.remove(h)}),0)}}var e}),[s,c,u,h]);const f=K.useCallback((e=>{if(!n&&!r)return;if(h.paused)return;const t="Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey,a=document.activeElement;if(t&&a){const t=e.currentTarget,[r,o]=function(e){const t=tH(e),n=nH(t,e),r=nH(t.reverse(),e);return[n,r]}(t);r&&o?e.shiftKey||a!==o?e.shiftKey&&a===r&&(e.preventDefault(),n&&aH(o,{select:!0})):(e.preventDefault(),n&&aH(r,{select:!0})):a===t&&e.preventDefault()}}),[n,r,h.paused]);return Wh.jsx(Bz.div,{tabIndex:-1,...i,ref:p,onKeyDown:f})}));function tH(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{const t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function nH(e,t){for(const n of e)if(!rH(n,{upTo:t}))return n}function rH(e,{upTo:t}){if("hidden"===getComputedStyle(e).visibility)return!0;for(;e;){if(void 0!==t&&e===t)return!1;if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}function aH(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&function(e){return e instanceof HTMLInputElement&&"select"in e}(e)&&t&&e.select()}}eH.displayName="FocusScope";var oH=function(){let e=[];return{add(t){const n=e[0];t!==n&&(null==n||n.pause()),e=iH(e,t),e.unshift(t)},remove(t){var n;e=iH(e,t),null==(n=e[0])||n.resume()}}}();function iH(e,t){const n=[...e],r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}var sH=K.forwardRef(((e,t)=>{const{children:n,width:r=10,height:a=5,...o}=e;return Wh.jsx(Bz.svg,{...o,ref:t,width:r,height:a,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:Wh.jsx("polygon",{points:"0,0 30,0 15,10"})})}));sH.displayName="Arrow";var lH=sH,cH="Popper",[uH,dH]=jL(cH),[pH,hH]=uH(cH),fH=e=>{const{__scopePopper:t,children:n}=e,[r,a]=K.useState(null);return Wh.jsx(pH,{scope:t,anchor:r,onAnchorChange:a,children:n})};fH.displayName=cH;var mH="PopperAnchor",gH=K.forwardRef(((e,t)=>{const{__scopePopper:n,virtualRef:r,...a}=e,o=hH(mH,n),i=K.useRef(null),s=FL(t,i);return K.useEffect((()=>{o.onAnchorChange((null==r?void 0:r.current)||i.current)})),r?null:Wh.jsx(Bz.div,{...a,ref:s})}));gH.displayName=mH;var yH="PopperContent",[bH,vH]=uH(yH),kH=K.forwardRef(((e,t)=>{var n,r,a,o,i,s;const{__scopePopper:l,side:c="bottom",sideOffset:u=0,align:d="center",alignOffset:p=0,arrowPadding:h=0,avoidCollisions:f=!0,collisionBoundary:m=[],collisionPadding:g=0,sticky:y="partial",hideWhenDetached:b=!1,updatePositionStrategy:v="optimized",onPlaced:k,...w}=e,x=hH(yH,l),[E,_]=K.useState(null),S=FL(t,(e=>_(e))),[T,C]=K.useState(null),A=jF(T),N=(null==A?void 0:A.width)??0,I=(null==A?void 0:A.height)??0,R=c+("center"!==d?"-"+d:""),O="number"==typeof g?g:{top:0,right:0,bottom:0,left:0,...g},P=Array.isArray(m)?m:[m],D=P.length>0,L={padding:O,boundary:P.filter(_H),altBoundary:D},{refs:M,floatingStyles:F,placement:j,isPositioned:B,middlewareData:z}=CF({strategy:"fixed",placement:R,whileElementsMounted:(...e)=>hF(...e,{animationFrame:"always"===v}),elements:{reference:x.anchor},middleware:[NF({mainAxis:u+I,alignmentAxis:p}),f&&IF({mainAxis:!0,crossAxis:!1,limiter:"partial"===y?RF():void 0,...L}),f&&OF({...L}),PF({...L,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{const{width:a,height:o}=t.reference,i=e.floating.style;i.setProperty("--radix-popper-available-width",`${n}px`),i.setProperty("--radix-popper-available-height",`${r}px`),i.setProperty("--radix-popper-anchor-width",`${a}px`),i.setProperty("--radix-popper-anchor-height",`${o}px`)}}),T&&LF({element:T,padding:h}),SH({arrowWidth:N,arrowHeight:I}),b&&DF({strategy:"referenceHidden",...L})]}),[H,U]=TH(j),$=qL(k);rM((()=>{B&&(null==$||$())}),[B,$]);const G=null==(n=z.arrow)?void 0:n.x,V=null==(r=z.arrow)?void 0:r.y,q=0!==(null==(a=z.arrow)?void 0:a.centerOffset),[W,Y]=K.useState();return rM((()=>{E&&Y(window.getComputedStyle(E).zIndex)}),[E]),Wh.jsx("div",{ref:M.setFloating,"data-radix-popper-content-wrapper":"",style:{...F,transform:B?F.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:W,"--radix-popper-transform-origin":[null==(o=z.transformOrigin)?void 0:o.x,null==(i=z.transformOrigin)?void 0:i.y].join(" "),...(null==(s=z.hide)?void 0:s.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:Wh.jsx(bH,{scope:l,placedSide:H,onArrowChange:C,arrowX:G,arrowY:V,shouldHideArrow:q,children:Wh.jsx(Bz.div,{"data-side":H,"data-align":U,...w,ref:S,style:{...w.style,animation:B?void 0:"none"}})})})}));kH.displayName=yH;var wH="PopperArrow",xH={top:"bottom",right:"left",bottom:"top",left:"right"},EH=K.forwardRef((function(e,t){const{__scopePopper:n,...r}=e,a=vH(wH,n),o=xH[a.placedSide];return Wh.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:Wh.jsx(lH,{...r,ref:t,style:{...r.style,display:"block"}})})}));function _H(e){return null!==e}EH.displayName=wH;var SH=e=>({name:"transformOrigin",options:e,fn(t){var n,r,a;const{placement:o,rects:i,middlewareData:s}=t,l=0!==(null==(n=s.arrow)?void 0:n.centerOffset),c=l?0:e.arrowWidth,u=l?0:e.arrowHeight,[d,p]=TH(o),h={start:"0%",center:"50%",end:"100%"}[p],f=((null==(r=s.arrow)?void 0:r.x)??0)+c/2,m=((null==(a=s.arrow)?void 0:a.y)??0)+u/2;let g="",y="";return"bottom"===d?(g=l?h:`${f}px`,y=-u+"px"):"top"===d?(g=l?h:`${f}px`,y=`${i.floating.height+u}px`):"right"===d?(g=-u+"px",y=l?h:`${m}px`):"left"===d&&(g=`${i.floating.width+u}px`,y=l?h:`${m}px`),{data:{x:g,y:y}}}});function TH(e){const[t,n="center"]=e.split("-");return[t,n]}var CH=fH,AH=gH,NH=kH,IH=EH,RH=new WeakMap,OH=new WeakMap,PH={},DH=0,LH=function(e){return e&&(e.host||LH(e.parentNode))},MH=function(e,t,n,r){var a=function(e,t){return t.map((function(t){if(e.contains(t))return t;var n=LH(t);return n&&e.contains(n)?n:(console.error("aria-hidden",t,"in not contained inside",e,". Doing nothing"),null)})).filter((function(e){return Boolean(e)}))}(t,Array.isArray(e)?e:[e]);PH[n]||(PH[n]=new WeakMap);var o=PH[n],i=[],s=new Set,l=new Set(a),c=function(e){e&&!s.has(e)&&(s.add(e),c(e.parentNode))};a.forEach(c);var u=function(e){e&&!l.has(e)&&Array.prototype.forEach.call(e.children,(function(e){if(s.has(e))u(e);else try{var t=e.getAttribute(r),a=null!==t&&"false"!==t,l=(RH.get(e)||0)+1,c=(o.get(e)||0)+1;RH.set(e,l),o.set(e,c),i.push(e),1===l&&a&&OH.set(e,!0),1===c&&e.setAttribute(n,"true"),a||e.setAttribute(r,"true")}catch(X4){console.error("aria-hidden: cannot operate on ",e,X4)}}))};return u(t),s.clear(),DH++,function(){i.forEach((function(e){var t=RH.get(e)-1,a=o.get(e)-1;RH.set(e,t),o.set(e,a),t||(OH.has(e)||e.removeAttribute(r),OH.delete(e)),a||e.removeAttribute(n)})),--DH||(RH=new WeakMap,RH=new WeakMap,OH=new WeakMap,PH={})}},FH=function(e,t,n){void 0===n&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),a=function(e){return"undefined"==typeof document?null:(Array.isArray(e)?e[0]:e).ownerDocument.body}(e);return a?(r.push.apply(r,Array.from(a.querySelectorAll("[aria-live]"))),MH(r,a,n,"aria-hidden")):function(){return null}},jH=function(){return jH=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e},jH.apply(this,arguments)};function BH(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var a=0;for(r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]])}return n}function zH(e,t,n){if(n||2===arguments.length)for(var r,a=0,o=t.length;a<o;a++)!r&&a in t||(r||(r=Array.prototype.slice.call(t,0,a)),r[a]=t[a]);return e.concat(r||Array.prototype.slice.call(t))}"function"==typeof SuppressedError&&SuppressedError;var HH="right-scroll-bar-position",UH="width-before-scroll-bar";function $H(e,t){return"function"==typeof e?e(t):e&&(e.current=t),e}var GH="undefined"!=typeof window?K.useLayoutEffect:K.useEffect,VH=new WeakMap;function qH(e,t){var n,r,a,o=(n=null,r=function(t){return e.forEach((function(e){return $H(e,t)}))},(a=K.useState((function(){return{value:n,callback:r,facade:{get current(){return a.value},set current(e){var t=a.value;t!==e&&(a.value=e,a.callback(e,t))}}}}))[0]).callback=r,a.facade);return GH((function(){var t=VH.get(o);if(t){var n=new Set(t),r=new Set(e),a=o.current;n.forEach((function(e){r.has(e)||$H(e,null)})),r.forEach((function(e){n.has(e)||$H(e,a)}))}VH.set(o,e)}),[e]),o}function WH(e){return e}var YH=function(e){var t=e.sideCar,n=BH(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return K.createElement(r,jH({},n))};YH.isSideCarExport=!0;var KH=function(e){void 0===e&&(e={});var t=function(e,t){void 0===t&&(t=WH);var n=[],r=!1;return{read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(e){var a=t(e,r);return n.push(a),function(){n=n.filter((function(e){return e!==a}))}},assignSyncMedium:function(e){for(r=!0;n.length;){var t=n;n=[],t.forEach(e)}n={push:function(t){return e(t)},filter:function(){return n}}},assignMedium:function(e){r=!0;var t=[];if(n.length){var a=n;n=[],a.forEach(e),t=n}var o=function(){var n=t;t=[],n.forEach(e)},i=function(){return Promise.resolve().then(o)};i(),n={push:function(e){t.push(e),i()},filter:function(e){return t=t.filter(e),n}}}}}(null);return t.options=jH({async:!0,ssr:!1},e),t}(),XH=function(){},QH=K.forwardRef((function(e,t){var n=K.useRef(null),r=K.useState({onScrollCapture:XH,onWheelCapture:XH,onTouchMoveCapture:XH}),a=r[0],o=r[1],i=e.forwardProps,s=e.children,l=e.className,c=e.removeScrollBar,u=e.enabled,d=e.shards,p=e.sideCar,h=e.noRelative,f=e.noIsolation,m=e.inert,g=e.allowPinchZoom,y=e.as,b=void 0===y?"div":y,v=e.gapMode,k=BH(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),w=p,x=qH([n,t]),E=jH(jH({},k),a);return K.createElement(K.Fragment,null,u&&K.createElement(w,{sideCar:KH,removeScrollBar:c,shards:d,noRelative:h,noIsolation:f,inert:m,setCallbacks:o,allowPinchZoom:!!g,lockRef:n,gapMode:v}),i?K.cloneElement(K.Children.only(s),jH(jH({},E),{ref:x})):K.createElement(b,jH({},E,{className:l,ref:x}),s))}));QH.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},QH.classNames={fullWidth:UH,zeroRight:HH};function ZH(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=function(){if("undefined"!=typeof __webpack_nonce__)return __webpack_nonce__}();return t&&e.setAttribute("nonce",t),e}var JH=function(){var e=0,t=null;return{add:function(n){var r,a;0==e&&(t=ZH())&&(a=n,(r=t).styleSheet?r.styleSheet.cssText=a:r.appendChild(document.createTextNode(a)),function(e){(document.head||document.getElementsByTagName("head")[0]).appendChild(e)}(t)),e++},remove:function(){! --e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},eU=function(){var e,t=(e=JH(),function(t,n){K.useEffect((function(){return e.add(t),function(){e.remove()}}),[t&&n])});return function(e){var n=e.styles,r=e.dynamic;return t(n,r),null}},tU={left:0,top:0,right:0,gap:0},nU=function(e){return parseInt(e||"",10)||0},rU=function(e){if(void 0===e&&(e="margin"),"undefined"==typeof window)return tU;var t=function(e){var t=window.getComputedStyle(document.body),n=t["padding"===e?"paddingLeft":"marginLeft"],r=t["padding"===e?"paddingTop":"marginTop"],a=t["padding"===e?"paddingRight":"marginRight"];return[nU(n),nU(r),nU(a)]}(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},aU=eU(),oU="data-scroll-locked",iU=function(e,t,n,r){var a=e.left,o=e.top,i=e.right,s=e.gap;return void 0===n&&(n="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(r,";\n padding-right: ").concat(s,"px ").concat(r,";\n }\n body[").concat(oU,"] {\n overflow: hidden ").concat(r,";\n overscroll-behavior: contain;\n ").concat([t&&"position: relative ".concat(r,";"),"margin"===n&&"\n padding-left: ".concat(a,"px;\n padding-top: ").concat(o,"px;\n padding-right: ").concat(i,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(s,"px ").concat(r,";\n "),"padding"===n&&"padding-right: ".concat(s,"px ").concat(r,";")].filter(Boolean).join(""),"\n }\n \n .").concat(HH," {\n right: ").concat(s,"px ").concat(r,";\n }\n \n .").concat(UH," {\n margin-right: ").concat(s,"px ").concat(r,";\n }\n \n .").concat(HH," .").concat(HH," {\n right: 0 ").concat(r,";\n }\n \n .").concat(UH," .").concat(UH," {\n margin-right: 0 ").concat(r,";\n }\n \n body[").concat(oU,"] {\n ").concat("--removed-body-scroll-bar-size",": ").concat(s,"px;\n }\n")},sU=function(){var e=parseInt(document.body.getAttribute(oU)||"0",10);return isFinite(e)?e:0},lU=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,a=void 0===r?"margin":r;K.useEffect((function(){return document.body.setAttribute(oU,(sU()+1).toString()),function(){var e=sU()-1;e<=0?document.body.removeAttribute(oU):document.body.setAttribute(oU,e.toString())}}),[]);var o=K.useMemo((function(){return rU(a)}),[a]);return K.createElement(aU,{styles:iU(o,!t,a,n?"":"!important")})},cU=!1;if("undefined"!=typeof window)try{var uU=Object.defineProperty({},"passive",{get:function(){return cU=!0,!0}});window.addEventListener("test",uU,uU),window.removeEventListener("test",uU,uU)}catch(xbe){cU=!1}var dU=!!cU&&{passive:!1},pU=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return"hidden"!==n[t]&&!(n.overflowY===n.overflowX&&!function(e){return"TEXTAREA"===e.tagName}(e)&&"visible"===n[t])},hU=function(e,t){var n=t.ownerDocument,r=t;do{if("undefined"!=typeof ShadowRoot&&r instanceof ShadowRoot&&(r=r.host),fU(e,r)){var a=mU(e,r);if(a[1]>a[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},fU=function(e,t){return"v"===e?function(e){return pU(e,"overflowY")}(t):function(e){return pU(e,"overflowX")}(t)},mU=function(e,t){return"v"===e?[(n=t).scrollTop,n.scrollHeight,n.clientHeight]:function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]}(t);var n},gU=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},yU=function(e){return[e.deltaX,e.deltaY]},bU=function(e){return e&&"current"in e?e.current:e},vU=function(e){return"\n .block-interactivity-".concat(e," {pointer-events: none;}\n .allow-interactivity-").concat(e," {pointer-events: all;}\n")},kU=0,wU=[];function xU(e){for(var t=null;null!==e;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const EU=(_U=function(e){var t=K.useRef([]),n=K.useRef([0,0]),r=K.useRef(),a=K.useState(kU++)[0],o=K.useState(eU)[0],i=K.useRef(e);K.useEffect((function(){i.current=e}),[e]),K.useEffect((function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(a));var t=zH([e.lockRef.current],(e.shards||[]).map(bU),!0).filter(Boolean);return t.forEach((function(e){return e.classList.add("allow-interactivity-".concat(a))})),function(){document.body.classList.remove("block-interactivity-".concat(a)),t.forEach((function(e){return e.classList.remove("allow-interactivity-".concat(a))}))}}}),[e.inert,e.lockRef.current,e.shards]);var s=K.useCallback((function(e,t){if("touches"in e&&2===e.touches.length||"wheel"===e.type&&e.ctrlKey)return!i.current.allowPinchZoom;var a,o=gU(e),s=n.current,l="deltaX"in e?e.deltaX:s[0]-o[0],c="deltaY"in e?e.deltaY:s[1]-o[1],u=e.target,d=Math.abs(l)>Math.abs(c)?"h":"v";if("touches"in e&&"h"===d&&"range"===u.type)return!1;var p=hU(d,u);if(!p)return!0;if(p?a=d:(a="v"===d?"h":"v",p=hU(d,u)),!p)return!1;if(!r.current&&"changedTouches"in e&&(l||c)&&(r.current=a),!a)return!0;var h=r.current||a;return function(e,t,n,r){var a=function(e,t){return"h"===e&&"rtl"===t?-1:1}(e,window.getComputedStyle(t).direction),o=a*r,i=n.target,s=t.contains(i),l=!1,c=o>0,u=0,d=0;do{if(!i)break;var p=mU(e,i),h=p[0],f=p[1]-p[2]-a*h;(h||f)&&fU(e,i)&&(u+=f,d+=h);var m=i.parentNode;i=m&&m.nodeType===Node.DOCUMENT_FRAGMENT_NODE?m.host:m}while(!s&&i!==document.body||s&&(t.contains(i)||t===i));return(c&&Math.abs(u)<1||!c&&Math.abs(d)<1)&&(l=!0),l}(h,t,e,"h"===h?l:c)}),[]),l=K.useCallback((function(e){var n=e;if(wU.length&&wU[wU.length-1]===o){var r="deltaY"in n?yU(n):gU(n),a=t.current.filter((function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&(t=e.delta,a=r,t[0]===a[0]&&t[1]===a[1]);var t,a}))[0];if(a&&a.should)n.cancelable&&n.preventDefault();else if(!a){var l=(i.current.shards||[]).map(bU).filter(Boolean).filter((function(e){return e.contains(n.target)}));(l.length>0?s(n,l[0]):!i.current.noIsolation)&&n.cancelable&&n.preventDefault()}}}),[]),c=K.useCallback((function(e,n,r,a){var o={name:e,delta:n,target:r,should:a,shadowParent:xU(r)};t.current.push(o),setTimeout((function(){t.current=t.current.filter((function(e){return e!==o}))}),1)}),[]),u=K.useCallback((function(e){n.current=gU(e),r.current=void 0}),[]),d=K.useCallback((function(t){c(t.type,yU(t),t.target,s(t,e.lockRef.current))}),[]),p=K.useCallback((function(t){c(t.type,gU(t),t.target,s(t,e.lockRef.current))}),[]);K.useEffect((function(){return wU.push(o),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:p}),document.addEventListener("wheel",l,dU),document.addEventListener("touchmove",l,dU),document.addEventListener("touchstart",u,dU),function(){wU=wU.filter((function(e){return e!==o})),document.removeEventListener("wheel",l,dU),document.removeEventListener("touchmove",l,dU),document.removeEventListener("touchstart",u,dU)}}),[]);var h=e.removeScrollBar,f=e.inert;return K.createElement(K.Fragment,null,f?K.createElement(o,{styles:vU(a)}):null,h?K.createElement(lU,{noRelative:e.noRelative,gapMode:e.gapMode}):null)},KH.useMedium(_U),YH);var _U,SU=K.forwardRef((function(e,t){return K.createElement(QH,jH({},e,{ref:t,sideCar:EU}))}));SU.classNames=QH.classNames;var TU="Popover",[CU,AU]=jL(TU,[dH]),NU=dH(),[IU,RU]=CU(TU),OU=e=>{const{__scopePopover:t,children:n,open:r,defaultOpen:a,onOpenChange:o,modal:i=!1}=e,s=NU(t),l=K.useRef(null),[c,u]=K.useState(!1),[d=!1,p]=cj({prop:r,defaultProp:a,onChange:o});return Wh.jsx(CH,{...s,children:Wh.jsx(IU,{scope:t,contentId:iM(),triggerRef:l,open:d,onOpenChange:p,onOpenToggle:K.useCallback((()=>p((e=>!e))),[p]),hasCustomAnchor:c,onCustomAnchorAdd:K.useCallback((()=>u(!0)),[]),onCustomAnchorRemove:K.useCallback((()=>u(!1)),[]),modal:i,children:n})})};OU.displayName=TU;var PU="PopoverAnchor",DU=K.forwardRef(((e,t)=>{const{__scopePopover:n,...r}=e,a=RU(PU,n),o=NU(n),{onCustomAnchorAdd:i,onCustomAnchorRemove:s}=a;return K.useEffect((()=>(i(),()=>s())),[i,s]),Wh.jsx(AH,{...o,...r,ref:t})}));DU.displayName=PU;var LU="PopoverTrigger",MU=K.forwardRef(((e,t)=>{const{__scopePopover:n,...r}=e,a=RU(LU,n),o=NU(n),i=FL(t,a.triggerRef),s=Wh.jsx(Bz.button,{type:"button","aria-haspopup":"dialog","aria-expanded":a.open,"aria-controls":a.contentId,"data-state":WU(a.open),...r,ref:i,onClick:DL(e.onClick,a.onOpenToggle)});return a.hasCustomAnchor?s:Wh.jsx(AH,{asChild:!0,...o,children:s})}));MU.displayName=LU;var[FU,jU]=CU("PopoverPortal",{forceMount:void 0}),BU="PopoverContent",zU=K.forwardRef(((e,t)=>{const n=jU(BU,e.__scopePopover),{forceMount:r=n.forceMount,...a}=e,o=RU(BU,e.__scopePopover);return Wh.jsx(sj,{present:r||o.open,children:o.modal?Wh.jsx(HU,{...a,ref:t}):Wh.jsx(UU,{...a,ref:t})})}));zU.displayName=BU;var HU=K.forwardRef(((e,t)=>{const n=RU(BU,e.__scopePopover),r=K.useRef(null),a=FL(t,r),o=K.useRef(!1);return K.useEffect((()=>{const e=r.current;if(e)return FH(e)}),[]),Wh.jsx(SU,{as:Lz,allowPinchZoom:!0,children:Wh.jsx($U,{...e,ref:a,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:DL(e.onCloseAutoFocus,(e=>{var t;e.preventDefault(),o.current||null==(t=n.triggerRef.current)||t.focus()})),onPointerDownOutside:DL(e.onPointerDownOutside,(e=>{const t=e.detail.originalEvent,n=0===t.button&&!0===t.ctrlKey,r=2===t.button||n;o.current=r}),{checkForDefaultPrevented:!1}),onFocusOutside:DL(e.onFocusOutside,(e=>e.preventDefault()),{checkForDefaultPrevented:!1})})})})),UU=K.forwardRef(((e,t)=>{const n=RU(BU,e.__scopePopover),r=K.useRef(!1),a=K.useRef(!1);return Wh.jsx($U,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{var o,i;null==(o=e.onCloseAutoFocus)||o.call(e,t),t.defaultPrevented||(r.current||null==(i=n.triggerRef.current)||i.focus(),t.preventDefault()),r.current=!1,a.current=!1},onInteractOutside:t=>{var o,i;null==(o=e.onInteractOutside)||o.call(e,t),t.defaultPrevented||(r.current=!0,"pointerdown"===t.detail.originalEvent.type&&(a.current=!0));const s=t.target;(null==(i=n.triggerRef.current)?void 0:i.contains(s))&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&a.current&&t.preventDefault()}})})),$U=K.forwardRef(((e,t)=>{const{__scopePopover:n,trapFocus:r,onOpenAutoFocus:a,onCloseAutoFocus:o,disableOutsidePointerEvents:i,onEscapeKeyDown:s,onPointerDownOutside:l,onFocusOutside:c,onInteractOutside:u,...d}=e,p=RU(BU,n),h=NU(n);return K.useEffect((()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Xz()),document.body.insertAdjacentElement("beforeend",e[1]??Xz()),Kz++,()=>{1===Kz&&document.querySelectorAll("[data-radix-focus-guard]").forEach((e=>e.remove())),Kz--}}),[]),Wh.jsx(eH,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:a,onUnmountAutoFocus:o,children:Wh.jsx(Vz,{asChild:!0,disableOutsidePointerEvents:i,onInteractOutside:u,onEscapeKeyDown:s,onPointerDownOutside:l,onFocusOutside:c,onDismiss:()=>p.onOpenChange(!1),children:Wh.jsx(NH,{"data-state":WU(p.open),role:"dialog",id:p.contentId,...h,...d,ref:t,style:{...d.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})})),GU="PopoverClose",VU=K.forwardRef(((e,t)=>{const{__scopePopover:n,...r}=e,a=RU(GU,n);return Wh.jsx(Bz.button,{type:"button",...r,ref:t,onClick:DL(e.onClick,(()=>a.onOpenChange(!1)))})}));VU.displayName=GU;var qU=K.forwardRef(((e,t)=>{const{__scopePopover:n,...r}=e,a=NU(n);return Wh.jsx(IH,{...a,...r,ref:t})}));function WU(e){return e?"open":"closed"}qU.displayName="PopoverArrow";var YU=OU,KU=MU,XU=zU,QU=qU,ZU=K.createContext(void 0);var JU="ScrollArea",[e$,t$]=jL(JU),[n$,r$]=e$(JU),a$=K.forwardRef(((e,t)=>{const{__scopeScrollArea:n,type:r="hover",dir:a,scrollHideDelay:o=600,...i}=e,[s,l]=K.useState(null),[c,u]=K.useState(null),[d,p]=K.useState(null),[h,f]=K.useState(null),[m,g]=K.useState(null),[y,b]=K.useState(0),[v,k]=K.useState(0),[w,x]=K.useState(!1),[E,_]=K.useState(!1),S=FL(t,(e=>l(e))),T=function(e){const t=K.useContext(ZU);return e||t||"ltr"}(a);return Wh.jsx(n$,{scope:n,type:r,dir:T,scrollHideDelay:o,scrollArea:s,viewport:c,onViewportChange:u,content:d,onContentChange:p,scrollbarX:h,onScrollbarXChange:f,scrollbarXEnabled:w,onScrollbarXEnabledChange:x,scrollbarY:m,onScrollbarYChange:g,scrollbarYEnabled:E,onScrollbarYEnabledChange:_,onCornerWidthChange:b,onCornerHeightChange:k,children:Wh.jsx(VL.div,{dir:T,...i,ref:S,style:{position:"relative","--radix-scroll-area-corner-width":y+"px","--radix-scroll-area-corner-height":v+"px",...e.style}})})}));a$.displayName=JU;var o$="ScrollAreaViewport",i$=K.forwardRef(((e,t)=>{const{__scopeScrollArea:n,children:r,nonce:a,...o}=e,i=r$(o$,n),s=FL(t,K.useRef(null),i.onViewportChange);return Wh.jsxs(Wh.Fragment,{children:[Wh.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"},nonce:a}),Wh.jsx(VL.div,{"data-radix-scroll-area-viewport":"",...o,ref:s,style:{overflowX:i.scrollbarXEnabled?"scroll":"hidden",overflowY:i.scrollbarYEnabled?"scroll":"hidden",...e.style},children:Wh.jsx("div",{ref:i.onContentChange,style:{minWidth:"100%",display:"table"},children:r})})]})}));i$.displayName=o$;var s$="ScrollAreaScrollbar",l$=K.forwardRef(((e,t)=>{const{forceMount:n,...r}=e,a=r$(s$,e.__scopeScrollArea),{onScrollbarXEnabledChange:o,onScrollbarYEnabledChange:i}=a,s="horizontal"===e.orientation;return K.useEffect((()=>(s?o(!0):i(!0),()=>{s?o(!1):i(!1)})),[s,o,i]),"hover"===a.type?Wh.jsx(c$,{...r,ref:t,forceMount:n}):"scroll"===a.type?Wh.jsx(u$,{...r,ref:t,forceMount:n}):"auto"===a.type?Wh.jsx(d$,{...r,ref:t,forceMount:n}):"always"===a.type?Wh.jsx(p$,{...r,ref:t}):null}));l$.displayName=s$;var c$=K.forwardRef(((e,t)=>{const{forceMount:n,...r}=e,a=r$(s$,e.__scopeScrollArea),[o,i]=K.useState(!1);return K.useEffect((()=>{const e=a.scrollArea;let t=0;if(e){const n=()=>{window.clearTimeout(t),i(!0)},r=()=>{t=window.setTimeout((()=>i(!1)),a.scrollHideDelay)};return e.addEventListener("pointerenter",n),e.addEventListener("pointerleave",r),()=>{window.clearTimeout(t),e.removeEventListener("pointerenter",n),e.removeEventListener("pointerleave",r)}}}),[a.scrollArea,a.scrollHideDelay]),Wh.jsx(sj,{present:n||o,children:Wh.jsx(d$,{"data-state":o?"visible":"hidden",...r,ref:t})})})),u$=K.forwardRef(((e,t)=>{const{forceMount:n,...r}=e,a=r$(s$,e.__scopeScrollArea),o="horizontal"===e.orientation,i=R$((()=>l("SCROLL_END")),100),[s,l]=(c="hidden",u={hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}},K.useReducer(((e,t)=>u[e][t]??e),c));var c,u;return K.useEffect((()=>{if("idle"===s){const e=window.setTimeout((()=>l("HIDE")),a.scrollHideDelay);return()=>window.clearTimeout(e)}}),[s,a.scrollHideDelay,l]),K.useEffect((()=>{const e=a.viewport,t=o?"scrollLeft":"scrollTop";if(e){let n=e[t];const r=()=>{const r=e[t];n!==r&&(l("SCROLL"),i()),n=r};return e.addEventListener("scroll",r),()=>e.removeEventListener("scroll",r)}}),[a.viewport,o,l,i]),Wh.jsx(sj,{present:n||"hidden"!==s,children:Wh.jsx(p$,{"data-state":"hidden"===s?"hidden":"visible",...r,ref:t,onPointerEnter:DL(e.onPointerEnter,(()=>l("POINTER_ENTER"))),onPointerLeave:DL(e.onPointerLeave,(()=>l("POINTER_LEAVE")))})})})),d$=K.forwardRef(((e,t)=>{const n=r$(s$,e.__scopeScrollArea),{forceMount:r,...a}=e,[o,i]=K.useState(!1),s="horizontal"===e.orientation,l=R$((()=>{if(n.viewport){const e=n.viewport.offsetWidth<n.viewport.scrollWidth,t=n.viewport.offsetHeight<n.viewport.scrollHeight;i(s?e:t)}}),10);return O$(n.viewport,l),O$(n.content,l),Wh.jsx(sj,{present:r||o,children:Wh.jsx(p$,{"data-state":o?"visible":"hidden",...a,ref:t})})})),p$=K.forwardRef(((e,t)=>{const{orientation:n="vertical",...r}=e,a=r$(s$,e.__scopeScrollArea),o=K.useRef(null),i=K.useRef(0),[s,l]=K.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),c=S$(s.viewport,s.content),u={...r,sizes:s,onSizesChange:l,hasThumb:Boolean(c>0&&c<1),onThumbChange:e=>o.current=e,onThumbPointerUp:()=>i.current=0,onThumbPointerDown:e=>i.current=e};function d(e,t){return function(e,t,n,r="ltr"){const a=T$(n),o=a/2,i=t||o,s=a-i,l=n.scrollbar.paddingStart+i,c=n.scrollbar.size-n.scrollbar.paddingEnd-s,u=n.content-n.viewport,d="ltr"===r?[0,u]:[-1*u,0];return A$([l,c],d)(e)}(e,i.current,s,t)}return"horizontal"===n?Wh.jsx(h$,{...u,ref:t,onThumbPositionChange:()=>{if(a.viewport&&o.current){const e=C$(a.viewport.scrollLeft,s,a.dir);o.current.style.transform=`translate3d(${e}px, 0, 0)`}},onWheelScroll:e=>{a.viewport&&(a.viewport.scrollLeft=e)},onDragScroll:e=>{a.viewport&&(a.viewport.scrollLeft=d(e,a.dir))}}):"vertical"===n?Wh.jsx(f$,{...u,ref:t,onThumbPositionChange:()=>{if(a.viewport&&o.current){const e=C$(a.viewport.scrollTop,s);o.current.style.transform=`translate3d(0, ${e}px, 0)`}},onWheelScroll:e=>{a.viewport&&(a.viewport.scrollTop=e)},onDragScroll:e=>{a.viewport&&(a.viewport.scrollTop=d(e))}}):null})),h$=K.forwardRef(((e,t)=>{const{sizes:n,onSizesChange:r,...a}=e,o=r$(s$,e.__scopeScrollArea),[i,s]=K.useState(),l=K.useRef(null),c=FL(t,l,o.onScrollbarXChange);return K.useEffect((()=>{l.current&&s(getComputedStyle(l.current))}),[l]),Wh.jsx(y$,{"data-orientation":"horizontal",...a,ref:c,sizes:n,style:{bottom:0,left:"rtl"===o.dir?"var(--radix-scroll-area-corner-width)":0,right:"ltr"===o.dir?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":T$(n)+"px",...e.style},onThumbPointerDown:t=>e.onThumbPointerDown(t.x),onDragScroll:t=>e.onDragScroll(t.x),onWheelScroll:(t,n)=>{if(o.viewport){const r=o.viewport.scrollLeft+t.deltaX;e.onWheelScroll(r),N$(r,n)&&t.preventDefault()}},onResize:()=>{l.current&&o.viewport&&i&&r({content:o.viewport.scrollWidth,viewport:o.viewport.offsetWidth,scrollbar:{size:l.current.clientWidth,paddingStart:_$(i.paddingLeft),paddingEnd:_$(i.paddingRight)}})}})})),f$=K.forwardRef(((e,t)=>{const{sizes:n,onSizesChange:r,...a}=e,o=r$(s$,e.__scopeScrollArea),[i,s]=K.useState(),l=K.useRef(null),c=FL(t,l,o.onScrollbarYChange);return K.useEffect((()=>{l.current&&s(getComputedStyle(l.current))}),[l]),Wh.jsx(y$,{"data-orientation":"vertical",...a,ref:c,sizes:n,style:{top:0,right:"ltr"===o.dir?0:void 0,left:"rtl"===o.dir?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":T$(n)+"px",...e.style},onThumbPointerDown:t=>e.onThumbPointerDown(t.y),onDragScroll:t=>e.onDragScroll(t.y),onWheelScroll:(t,n)=>{if(o.viewport){const r=o.viewport.scrollTop+t.deltaY;e.onWheelScroll(r),N$(r,n)&&t.preventDefault()}},onResize:()=>{l.current&&o.viewport&&i&&r({content:o.viewport.scrollHeight,viewport:o.viewport.offsetHeight,scrollbar:{size:l.current.clientHeight,paddingStart:_$(i.paddingTop),paddingEnd:_$(i.paddingBottom)}})}})})),[m$,g$]=e$(s$),y$=K.forwardRef(((e,t)=>{const{__scopeScrollArea:n,sizes:r,hasThumb:a,onThumbChange:o,onThumbPointerUp:i,onThumbPointerDown:s,onThumbPositionChange:l,onDragScroll:c,onWheelScroll:u,onResize:d,...p}=e,h=r$(s$,n),[f,m]=K.useState(null),g=FL(t,(e=>m(e))),y=K.useRef(null),b=K.useRef(""),v=h.viewport,k=r.content-r.viewport,w=qL(u),x=qL(l),E=R$(d,10);function _(e){if(y.current){const t=e.clientX-y.current.left,n=e.clientY-y.current.top;c({x:t,y:n})}}return K.useEffect((()=>{const e=e=>{const t=e.target;(null==f?void 0:f.contains(t))&&w(e,k)};return document.addEventListener("wheel",e,{passive:!1}),()=>document.removeEventListener("wheel",e,{passive:!1})}),[v,f,k,w]),K.useEffect(x,[r,x]),O$(f,E),O$(h.content,E),Wh.jsx(m$,{scope:n,scrollbar:f,hasThumb:a,onThumbChange:qL(o),onThumbPointerUp:qL(i),onThumbPositionChange:x,onThumbPointerDown:qL(s),children:Wh.jsx(VL.div,{...p,ref:g,style:{position:"absolute",...p.style},onPointerDown:DL(e.onPointerDown,(e=>{if(0===e.button){e.target.setPointerCapture(e.pointerId),y.current=f.getBoundingClientRect(),b.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",h.viewport&&(h.viewport.style.scrollBehavior="auto"),_(e)}})),onPointerMove:DL(e.onPointerMove,_),onPointerUp:DL(e.onPointerUp,(e=>{const t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),document.body.style.webkitUserSelect=b.current,h.viewport&&(h.viewport.style.scrollBehavior=""),y.current=null}))})})})),b$="ScrollAreaThumb",v$=K.forwardRef(((e,t)=>{const{forceMount:n,...r}=e,a=g$(b$,e.__scopeScrollArea);return Wh.jsx(sj,{present:n||a.hasThumb,children:Wh.jsx(k$,{ref:t,...r})})})),k$=K.forwardRef(((e,t)=>{const{__scopeScrollArea:n,style:r,...a}=e,o=r$(b$,n),i=g$(b$,n),{onThumbPositionChange:s}=i,l=FL(t,(e=>i.onThumbChange(e))),c=K.useRef(void 0),u=R$((()=>{c.current&&(c.current(),c.current=void 0)}),100);return K.useEffect((()=>{const e=o.viewport;if(e){const t=()=>{if(u(),!c.current){const t=I$(e,s);c.current=t,s()}};return s(),e.addEventListener("scroll",t),()=>e.removeEventListener("scroll",t)}}),[o.viewport,u,s]),Wh.jsx(VL.div,{"data-state":i.hasThumb?"visible":"hidden",...a,ref:l,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...r},onPointerDownCapture:DL(e.onPointerDownCapture,(e=>{const t=e.target.getBoundingClientRect(),n=e.clientX-t.left,r=e.clientY-t.top;i.onThumbPointerDown({x:n,y:r})})),onPointerUp:DL(e.onPointerUp,i.onThumbPointerUp)})}));v$.displayName=b$;var w$="ScrollAreaCorner",x$=K.forwardRef(((e,t)=>{const n=r$(w$,e.__scopeScrollArea),r=Boolean(n.scrollbarX&&n.scrollbarY);return"scroll"!==n.type&&r?Wh.jsx(E$,{...e,ref:t}):null}));x$.displayName=w$;var E$=K.forwardRef(((e,t)=>{const{__scopeScrollArea:n,...r}=e,a=r$(w$,n),[o,i]=K.useState(0),[s,l]=K.useState(0),c=Boolean(o&&s);return O$(a.scrollbarX,(()=>{var e;const t=(null==(e=a.scrollbarX)?void 0:e.offsetHeight)||0;a.onCornerHeightChange(t),l(t)})),O$(a.scrollbarY,(()=>{var e;const t=(null==(e=a.scrollbarY)?void 0:e.offsetWidth)||0;a.onCornerWidthChange(t),i(t)})),c?Wh.jsx(VL.div,{...r,ref:t,style:{width:o,height:s,position:"absolute",right:"ltr"===a.dir?0:void 0,left:"rtl"===a.dir?0:void 0,bottom:0,...e.style}}):null}));function _$(e){return e?parseInt(e,10):0}function S$(e,t){const n=e/t;return isNaN(n)?0:n}function T$(e){const t=S$(e.viewport,e.content),n=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,r=(e.scrollbar.size-n)*t;return Math.max(r,18)}function C$(e,t,n="ltr"){const r=T$(t),a=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,o=t.scrollbar.size-a,i=t.content-t.viewport,s=o-r,l=function(e,[t,n]){return Math.min(n,Math.max(t,e))}(e,"ltr"===n?[0,i]:[-1*i,0]);return A$([0,i],[0,s])(l)}function A$(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}function N$(e,t){return e>0&&e<t}var I$=(e,t=()=>{})=>{let n={left:e.scrollLeft,top:e.scrollTop},r=0;return function a(){const o={left:e.scrollLeft,top:e.scrollTop},i=n.left!==o.left,s=n.top!==o.top;(i||s)&&t(),n=o,r=window.requestAnimationFrame(a)}(),()=>window.cancelAnimationFrame(r)};function R$(e,t){const n=qL(e),r=K.useRef(0);return K.useEffect((()=>()=>window.clearTimeout(r.current)),[]),K.useCallback((()=>{window.clearTimeout(r.current),r.current=window.setTimeout(n,t)}),[n,t])}function O$(e,t){const n=qL(t);rM((()=>{let t=0;if(e){const r=new ResizeObserver((()=>{cancelAnimationFrame(t),t=window.requestAnimationFrame(n)}));return r.observe(e),()=>{window.cancelAnimationFrame(t),r.unobserve(e)}}}),[e,n])}var P$=a$,D$=i$,L$=x$;function M$(e,[t,n]){return Math.min(n,Math.max(t,e))}function F$(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}function j$(e,t=[]){let n=[];const r=()=>{const t=n.map((e=>K.createContext(e)));return function(n){const r=(null==n?void 0:n[e])||t;return K.useMemo((()=>({[`__scope${e}`]:{...n,[e]:r}})),[n,r])}};return r.scopeName=e,[function(t,r){const a=K.createContext(r),o=n.length;n=[...n,r];const i=t=>{var n;const{scope:r,children:i,...s}=t,l=(null==(n=null==r?void 0:r[e])?void 0:n[o])||a,c=K.useMemo((()=>s),Object.values(s));return Wh.jsx(l.Provider,{value:c,children:i})};return i.displayName=t+"Provider",[i,function(n,i){var s;const l=(null==(s=null==i?void 0:i[e])?void 0:s[o])||a,c=K.useContext(l);if(c)return c;if(void 0!==r)return r;throw new Error(`\`${n}\` must be used within \`${t}\``)}]},B$(r,...t)]}function B$(...e){const t=e[0];if(1===e.length)return t;const n=()=>{const n=e.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(e){const r=n.reduce(((t,{useScope:n,scopeName:r})=>({...t,...n(e)[`__scope${r}`]})),{});return K.useMemo((()=>({[`__scope${t.scopeName}`]:r})),[r])}};return n.scopeName=t.scopeName,n}function z$(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function H$(...e){return t=>{let n=!1;const r=e.map((e=>{const r=z$(e,t);return n||"function"!=typeof r||(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():z$(e[t],null)}}}}function U$(...e){return K.useCallback(H$(...e),e)}function $$(e){const t=G$(e),n=K.forwardRef(((e,n)=>{const{children:r,...a}=e,o=K.Children.toArray(r),i=o.find(q$);if(i){const e=i.props.children,r=o.map((t=>t===i?K.Children.count(e)>1?K.Children.only(null):K.isValidElement(e)?e.props.children:null:t));return Wh.jsx(t,{...a,ref:n,children:K.isValidElement(e)?K.cloneElement(e,void 0,r):null})}return Wh.jsx(t,{...a,ref:n,children:r})}));return n.displayName=`${e}.Slot`,n}function G$(e){const t=K.forwardRef(((e,t)=>{const{children:n,...r}=e;if(K.isValidElement(n)){const e=function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;if(a)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a)return e.props.ref;return e.props.ref||e.ref}(n),a=function(e,t){const n={...t};for(const r in t){const a=e[r],o=t[r];/^on[A-Z]/.test(r)?a&&o?n[r]=(...e)=>{const t=o(...e);return a(...e),t}:a&&(n[r]=a):"style"===r?n[r]={...a,...o}:"className"===r&&(n[r]=[a,o].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props);return n.type!==K.Fragment&&(a.ref=t?H$(t,e):e),K.cloneElement(n,a)}return K.Children.count(n)>1?K.Children.only(null):null}));return t.displayName=`${e}.SlotClone`,t}var V$=Symbol("radix.slottable");function q$(e){return K.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===V$}var W$=K.createContext(void 0);function Y$(e){const t=K.useContext(W$);return e||t||"ltr"}function K$(e){const t=Q$(e),n=K.forwardRef(((e,n)=>{const{children:r,...a}=e,o=K.Children.toArray(r),i=o.find(J$);if(i){const e=i.props.children,r=o.map((t=>t===i?K.Children.count(e)>1?K.Children.only(null):K.isValidElement(e)?e.props.children:null:t));return Wh.jsx(t,{...a,ref:n,children:K.isValidElement(e)?K.cloneElement(e,void 0,r):null})}return Wh.jsx(t,{...a,ref:n,children:r})}));return n.displayName=`${e}.Slot`,n}var X$=K$("Slot");function Q$(e){const t=K.forwardRef(((e,t)=>{const{children:n,...r}=e;if(K.isValidElement(n)){const e=function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;if(a)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a)return e.props.ref;return e.props.ref||e.ref}(n),a=function(e,t){const n={...t};for(const r in t){const a=e[r],o=t[r];/^on[A-Z]/.test(r)?a&&o?n[r]=(...e)=>{o(...e),a(...e)}:a&&(n[r]=a):"style"===r?n[r]={...a,...o}:"className"===r&&(n[r]=[a,o].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props);return n.type!==K.Fragment&&(a.ref=t?H$(t,e):e),K.cloneElement(n,a)}return K.Children.count(n)>1?K.Children.only(null):null}));return t.displayName=`${e}.SlotClone`,t}var Z$=Symbol("radix.slottable");function J$(e){return K.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===Z$}var eG=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce(((e,t)=>{const n=K$(`Primitive.${t}`),r=K.forwardRef(((e,r)=>{const{asChild:a,...o}=e,i=a?n:t;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),Wh.jsx(i,{...o,ref:r})}));return r.displayName=`Primitive.${t}`,{...e,[t]:r}}),{});var tG,nG="dismissableLayer.update",rG="dismissableLayer.pointerDownOutside",aG="dismissableLayer.focusOutside",oG=K.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),iG=K.forwardRef(((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:a,onFocusOutside:o,onInteractOutside:i,onDismiss:s,...l}=e,c=K.useContext(oG),[u,d]=K.useState(null),p=(null==u?void 0:u.ownerDocument)??(null==globalThis?void 0:globalThis.document),[,h]=K.useState({}),f=U$(t,(e=>d(e))),m=Array.from(c.layers),[g]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),y=m.indexOf(g),b=u?m.indexOf(u):-1,v=c.layersWithOutsidePointerEventsDisabled.size>0,k=b>=y,w=function(e,t=(null==globalThis?void 0:globalThis.document)){const n=RB(e),r=K.useRef(!1),a=K.useRef((()=>{}));return K.useEffect((()=>{const e=e=>{if(e.target&&!r.current){let r=function(){cG(rG,n,o,{discrete:!0})};const o={originalEvent:e};"touch"===e.pointerType?(t.removeEventListener("click",a.current),a.current=r,t.addEventListener("click",a.current,{once:!0})):r()}else t.removeEventListener("click",a.current);r.current=!1},o=window.setTimeout((()=>{t.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(o),t.removeEventListener("pointerdown",e),t.removeEventListener("click",a.current)}}),[t,n]),{onPointerDownCapture:()=>r.current=!0}}((e=>{const t=e.target,n=[...c.branches].some((e=>e.contains(t)));k&&!n&&(null==a||a(e),null==i||i(e),e.defaultPrevented||null==s||s())}),p),x=function(e,t=(null==globalThis?void 0:globalThis.document)){const n=RB(e),r=K.useRef(!1);return K.useEffect((()=>{const e=e=>{if(e.target&&!r.current){cG(aG,n,{originalEvent:e},{discrete:!1})}};return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)}),[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}((e=>{const t=e.target;[...c.branches].some((e=>e.contains(t)))||(null==o||o(e),null==i||i(e),e.defaultPrevented||null==s||s())}),p);return function(e,t=(null==globalThis?void 0:globalThis.document)){const n=RB(e);K.useEffect((()=>{const e=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",e,{capture:!0}),()=>t.removeEventListener("keydown",e,{capture:!0})}),[n,t])}((e=>{b===c.layers.size-1&&(null==r||r(e),!e.defaultPrevented&&s&&(e.preventDefault(),s()))}),p),K.useEffect((()=>{if(u)return n&&(0===c.layersWithOutsidePointerEventsDisabled.size&&(tG=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(u)),c.layers.add(u),lG(),()=>{n&&1===c.layersWithOutsidePointerEventsDisabled.size&&(p.body.style.pointerEvents=tG)}}),[u,p,n,c]),K.useEffect((()=>()=>{u&&(c.layers.delete(u),c.layersWithOutsidePointerEventsDisabled.delete(u),lG())}),[u,c]),K.useEffect((()=>{const e=()=>h({});return document.addEventListener(nG,e),()=>document.removeEventListener(nG,e)}),[]),Wh.jsx(eG.div,{...l,ref:f,style:{pointerEvents:v?k?"auto":"none":void 0,...e.style},onFocusCapture:F$(e.onFocusCapture,x.onFocusCapture),onBlurCapture:F$(e.onBlurCapture,x.onBlurCapture),onPointerDownCapture:F$(e.onPointerDownCapture,w.onPointerDownCapture)})}));iG.displayName="DismissableLayer";var sG=K.forwardRef(((e,t)=>{const n=K.useContext(oG),r=K.useRef(null),a=U$(t,r);return K.useEffect((()=>{const e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}}),[n.branches]),Wh.jsx(eG.div,{...e,ref:a})}));function lG(){const e=new CustomEvent(nG);document.dispatchEvent(e)}function cG(e,t,n,{discrete:r}){const a=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&a.addEventListener(e,t,{once:!0}),r?function(e,t){e&&se.flushSync((()=>e.dispatchEvent(t)))}(a,o):a.dispatchEvent(o)}sG.displayName="DismissableLayerBranch";var uG=0;function dG(){K.useEffect((()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??pG()),document.body.insertAdjacentElement("beforeend",e[1]??pG()),uG++,()=>{1===uG&&document.querySelectorAll("[data-radix-focus-guard]").forEach((e=>e.remove())),uG--}}),[])}function pG(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var hG="focusScope.autoFocusOnMount",fG="focusScope.autoFocusOnUnmount",mG={bubbles:!1,cancelable:!0},gG=K.forwardRef(((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:a,onUnmountAutoFocus:o,...i}=e,[s,l]=K.useState(null),c=RB(a),u=RB(o),d=K.useRef(null),p=U$(t,(e=>l(e))),h=K.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;K.useEffect((()=>{if(r){let e=function(e){if(h.paused||!s)return;const t=e.target;s.contains(t)?d.current=t:kG(d.current,{select:!0})},t=function(e){if(h.paused||!s)return;const t=e.relatedTarget;null!==t&&(s.contains(t)||kG(d.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(const t of e)t.removedNodes.length>0&&kG(s)};document.addEventListener("focusin",e),document.addEventListener("focusout",t);const r=new MutationObserver(n);return s&&r.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),r.disconnect()}}}),[r,s,h.paused]),K.useEffect((()=>{if(s){wG.add(h);const t=document.activeElement;if(!s.contains(t)){const n=new CustomEvent(hG,mG);s.addEventListener(hG,c),s.dispatchEvent(n),n.defaultPrevented||(!function(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(kG(r,{select:t}),document.activeElement!==n)return}((e=yG(s),e.filter((e=>"A"!==e.tagName))),{select:!0}),document.activeElement===t&&kG(s))}return()=>{s.removeEventListener(hG,c),setTimeout((()=>{const e=new CustomEvent(fG,mG);s.addEventListener(fG,u),s.dispatchEvent(e),e.defaultPrevented||kG(t??document.body,{select:!0}),s.removeEventListener(fG,u),wG.remove(h)}),0)}}var e}),[s,c,u,h]);const f=K.useCallback((e=>{if(!n&&!r)return;if(h.paused)return;const t="Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey,a=document.activeElement;if(t&&a){const t=e.currentTarget,[r,o]=function(e){const t=yG(e),n=bG(t,e),r=bG(t.reverse(),e);return[n,r]}(t);r&&o?e.shiftKey||a!==o?e.shiftKey&&a===r&&(e.preventDefault(),n&&kG(o,{select:!0})):(e.preventDefault(),n&&kG(r,{select:!0})):a===t&&e.preventDefault()}}),[n,r,h.paused]);return Wh.jsx(eG.div,{tabIndex:-1,...i,ref:p,onKeyDown:f})}));function yG(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{const t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function bG(e,t){for(const n of e)if(!vG(n,{upTo:t}))return n}function vG(e,{upTo:t}){if("hidden"===getComputedStyle(e).visibility)return!0;for(;e;){if(void 0!==t&&e===t)return!1;if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}function kG(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&function(e){return e instanceof HTMLInputElement&&"select"in e}(e)&&t&&e.select()}}gG.displayName="FocusScope";var wG=function(){let e=[];return{add(t){const n=e[0];t!==n&&(null==n||n.pause()),e=xG(e,t),e.unshift(t)},remove(t){var n;e=xG(e,t),null==(n=e[0])||n.resume()}}}();function xG(e,t){const n=[...e],r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}var EG=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce(((e,t)=>{const n=$$(`Primitive.${t}`),r=K.forwardRef(((e,r)=>{const{asChild:a,...o}=e,i=a?n:t;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),Wh.jsx(i,{...o,ref:r})}));return r.displayName=`Primitive.${t}`,{...e,[t]:r}}),{}),_G=K.forwardRef(((e,t)=>{const{children:n,width:r=10,height:a=5,...o}=e;return Wh.jsx(EG.svg,{...o,ref:t,width:r,height:a,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:Wh.jsx("polygon",{points:"0,0 30,0 15,10"})})}));_G.displayName="Arrow";var SG=_G;var TG="Popper",[CG,AG]=j$(TG),[NG,IG]=CG(TG),RG=e=>{const{__scopePopper:t,children:n}=e,[r,a]=K.useState(null);return Wh.jsx(NG,{scope:t,anchor:r,onAnchorChange:a,children:n})};RG.displayName=TG;var OG="PopperAnchor",PG=K.forwardRef(((e,t)=>{const{__scopePopper:n,virtualRef:r,...a}=e,o=IG(OG,n),i=K.useRef(null),s=U$(t,i);return K.useEffect((()=>{o.onAnchorChange((null==r?void 0:r.current)||i.current)})),r?null:Wh.jsx(EG.div,{...a,ref:s})}));PG.displayName=OG;var DG="PopperContent",[LG,MG]=CG(DG),FG=K.forwardRef(((e,t)=>{var n,r,a,o,i,s;const{__scopePopper:l,side:c="bottom",sideOffset:u=0,align:d="center",alignOffset:p=0,arrowPadding:h=0,avoidCollisions:f=!0,collisionBoundary:m=[],collisionPadding:g=0,sticky:y="partial",hideWhenDetached:b=!1,updatePositionStrategy:v="optimized",onPlaced:k,...w}=e,x=IG(DG,l),[E,_]=K.useState(null),S=U$(t,(e=>_(e))),[T,C]=K.useState(null),A=function(e){const[t,n]=K.useState(void 0);return FO((()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const t=new ResizeObserver((t=>{if(!Array.isArray(t))return;if(!t.length)return;const r=t[0];let a,o;if("borderBoxSize"in r){const e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;a=t.inlineSize,o=t.blockSize}else a=e.offsetWidth,o=e.offsetHeight;n({width:a,height:o})}));return t.observe(e,{box:"border-box"}),()=>t.unobserve(e)}n(void 0)}),[e]),t}(T),N=(null==A?void 0:A.width)??0,I=(null==A?void 0:A.height)??0,R=c+("center"!==d?"-"+d:""),O="number"==typeof g?g:{top:0,right:0,bottom:0,left:0,...g},P=Array.isArray(m)?m:[m],D=P.length>0,L={padding:O,boundary:P.filter(HG),altBoundary:D},{refs:M,floatingStyles:F,placement:j,isPositioned:B,middlewareData:z}=CF({strategy:"fixed",placement:R,whileElementsMounted:(...e)=>hF(...e,{animationFrame:"always"===v}),elements:{reference:x.anchor},middleware:[NF({mainAxis:u+I,alignmentAxis:p}),f&&IF({mainAxis:!0,crossAxis:!1,limiter:"partial"===y?RF():void 0,...L}),f&&OF({...L}),PF({...L,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{const{width:a,height:o}=t.reference,i=e.floating.style;i.setProperty("--radix-popper-available-width",`${n}px`),i.setProperty("--radix-popper-available-height",`${r}px`),i.setProperty("--radix-popper-anchor-width",`${a}px`),i.setProperty("--radix-popper-anchor-height",`${o}px`)}}),T&&LF({element:T,padding:h}),UG({arrowWidth:N,arrowHeight:I}),b&&DF({strategy:"referenceHidden",...L})]}),[H,U]=$G(j),$=RB(k);FO((()=>{B&&(null==$||$())}),[B,$]);const G=null==(n=z.arrow)?void 0:n.x,V=null==(r=z.arrow)?void 0:r.y,q=0!==(null==(a=z.arrow)?void 0:a.centerOffset),[W,Y]=K.useState();return FO((()=>{E&&Y(window.getComputedStyle(E).zIndex)}),[E]),Wh.jsx("div",{ref:M.setFloating,"data-radix-popper-content-wrapper":"",style:{...F,transform:B?F.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:W,"--radix-popper-transform-origin":[null==(o=z.transformOrigin)?void 0:o.x,null==(i=z.transformOrigin)?void 0:i.y].join(" "),...(null==(s=z.hide)?void 0:s.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:Wh.jsx(LG,{scope:l,placedSide:H,onArrowChange:C,arrowX:G,arrowY:V,shouldHideArrow:q,children:Wh.jsx(EG.div,{"data-side":H,"data-align":U,...w,ref:S,style:{...w.style,animation:B?void 0:"none"}})})})}));FG.displayName=DG;var jG="PopperArrow",BG={top:"bottom",right:"left",bottom:"top",left:"right"},zG=K.forwardRef((function(e,t){const{__scopePopper:n,...r}=e,a=MG(jG,n),o=BG[a.placedSide];return Wh.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:Wh.jsx(SG,{...r,ref:t,style:{...r.style,display:"block"}})})}));function HG(e){return null!==e}zG.displayName=jG;var UG=e=>({name:"transformOrigin",options:e,fn(t){var n,r,a;const{placement:o,rects:i,middlewareData:s}=t,l=0!==(null==(n=s.arrow)?void 0:n.centerOffset),c=l?0:e.arrowWidth,u=l?0:e.arrowHeight,[d,p]=$G(o),h={start:"0%",center:"50%",end:"100%"}[p],f=((null==(r=s.arrow)?void 0:r.x)??0)+c/2,m=((null==(a=s.arrow)?void 0:a.y)??0)+u/2;let g="",y="";return"bottom"===d?(g=l?h:`${f}px`,y=-u+"px"):"top"===d?(g=l?h:`${f}px`,y=`${i.floating.height+u}px`):"right"===d?(g=-u+"px",y=l?h:`${m}px`):"left"===d&&(g=`${i.floating.width+u}px`,y=l?h:`${m}px`),{data:{x:g,y:y}}}});function $G(e){const[t,n="center"]=e.split("-");return[t,n]}var GG=RG,VG=PG,qG=FG,WG=zG,YG=K.forwardRef(((e,t)=>{var n;const{container:r,...a}=e,[o,i]=K.useState(!1);FO((()=>i(!0)),[]);const s=r||o&&(null==(n=null==globalThis?void 0:globalThis.document)?void 0:n.body);return s?le.createPortal(Wh.jsx(eG.div,{...a,ref:t}),s):null}));YG.displayName="Portal";const KG=[" ","Enter","ArrowUp","ArrowDown"],XG=[" ","Enter"],QG="Select",[ZG,JG,eV]=function(e){const t=e+"CollectionProvider",[n,r]=j$(t),[a,o]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=e=>{const{scope:t,children:n}=e,r=X.useRef(null),o=X.useRef(new Map).current;return Wh.jsx(a,{scope:t,itemMap:o,collectionRef:r,children:n})};i.displayName=t;const s=e+"CollectionSlot",l=$$(s),c=X.forwardRef(((e,t)=>{const{scope:n,children:r}=e,a=U$(t,o(s,n).collectionRef);return Wh.jsx(l,{ref:a,children:r})}));c.displayName=s;const u=e+"CollectionItemSlot",d="data-radix-collection-item",p=$$(u),h=X.forwardRef(((e,t)=>{const{scope:n,children:r,...a}=e,i=X.useRef(null),s=U$(t,i),l=o(u,n);return X.useEffect((()=>(l.itemMap.set(i,{ref:i,...a}),()=>{l.itemMap.delete(i)}))),Wh.jsx(p,{[d]:"",ref:s,children:r})}));return h.displayName=u,[{Provider:i,Slot:c,ItemSlot:h},function(t){const n=o(e+"CollectionConsumer",t);return X.useCallback((()=>{const e=n.collectionRef.current;if(!e)return[];const t=Array.from(e.querySelectorAll(`[${d}]`));return Array.from(n.itemMap.values()).sort(((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current)))}),[n.collectionRef,n.itemMap])},r]}(QG),[tV,nV]=j$(QG,[eV,AG]),rV=AG(),[aV,oV]=tV(QG),[iV,sV]=tV(QG),lV=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:a,onOpenChange:o,value:i,defaultValue:s,onValueChange:l,dir:c,disabled:u,required:d}=e,p=rV(t),[h,f]=K.useState(null),[m,g]=K.useState(null),[y,b]=K.useState(!1),v=Y$(c),[k,w]=OB({prop:r,defaultProp:a??!1,onChange:o}),[x,E]=OB({prop:i,defaultProp:s,onChange:l}),_=K.useRef(null),[S,T]=K.useState(new Set);return Wh.jsx(GG,{...p,children:Wh.jsx(aV,{required:d,scope:t,trigger:h,onTriggerChange:f,valueNode:m,onValueNodeChange:g,valueNodeHasChildren:y,onValueNodeHasChildrenChange:b,contentId:zO(),value:x,onValueChange:E,open:!!k,onOpenChange:w,dir:v,triggerPointerDownPosRef:_,disabled:u,children:Wh.jsx(ZG.Provider,{scope:t,children:Wh.jsx(iV,{scope:e.__scopeSelect,onNativeOptionAdd:K.useCallback((e=>{T((t=>new Set(t).add(e)))}),[]),onNativeOptionRemove:K.useCallback((e=>{T((t=>{const n=new Set(t);return n.delete(e),n}))}),[]),children:n})})})})};lV.displayName=QG;const cV="SelectTrigger",uV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...a}=e,o=rV(n),i=oV(cV,n),s=i.disabled||r,l=U$(t,i.onTriggerChange),c=JG(n),u=K.useRef("touch"),[d,p,h]=XV((e=>{const t=c().filter((e=>!e.disabled)),n=t.find((e=>e.value===i.value)),r=QV(t,e,n);void 0!==r&&i.onValueChange(r.value)})),f=e=>{s||(i.onOpenChange(!0),h()),e&&(i.triggerPointerDownPosRef.current={x:Math.round(e.pageX),y:Math.round(e.pageY)})};return Wh.jsx(VG,{asChild:!0,...o,children:Wh.jsx(eG.button,{type:"button",role:"combobox","aria-controls":i.contentId,"aria-expanded":i.open,"aria-required":i.required,"aria-autocomplete":"none",dir:i.dir,"data-state":i.open?"open":"closed",disabled:s,"data-disabled":s?"":void 0,"data-placeholder":KV(i.value)?"":void 0,...a,ref:l,onClick:F$(a.onClick,(e=>{e.currentTarget.focus(),"mouse"!==u.current&&f(e)})),onPointerDown:F$(a.onPointerDown,(e=>{u.current=e.pointerType;const t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),0===e.button&&!1===e.ctrlKey&&"mouse"===e.pointerType&&(f(e),e.preventDefault())})),onKeyDown:F$(a.onKeyDown,(e=>{const t=""!==d.current;e.ctrlKey||e.altKey||e.metaKey||1!==e.key.length||p(e.key),t&&" "===e.key||KG.includes(e.key)&&(f(),e.preventDefault())}))})})}));uV.displayName=cV;const dV="SelectValue",pV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,className:r,style:a,children:o,placeholder:i="",...s}=e,l=oV(dV,n),{onValueNodeHasChildrenChange:c}=l,u=void 0!==o,d=U$(t,l.onValueNodeChange);return FO((()=>{c(u)}),[c,u]),Wh.jsx(eG.span,{...s,ref:d,style:{pointerEvents:"none"},children:KV(l.value)?Wh.jsx(Wh.Fragment,{children:i}):o})}));pV.displayName=dV;const hV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,children:r,...a}=e;return Wh.jsx(eG.span,{"aria-hidden":!0,...a,ref:t,children:r||"▼"})}));hV.displayName="SelectIcon";const fV="SelectContent",mV=K.forwardRef(((e,t)=>{const n=oV(fV,e.__scopeSelect),[r,a]=K.useState();if(FO((()=>{a(new DocumentFragment)}),[]),!n.open){const t=r;return t?se.createPortal(Wh.jsx(yV,{scope:e.__scopeSelect,children:Wh.jsx(ZG.Slot,{scope:e.__scopeSelect,children:Wh.jsx("div",{children:e.children})})}),t):null}return Wh.jsx(kV,{...e,ref:t})}));mV.displayName=fV;const gV=10,[yV,bV]=tV(fV),vV=K$("SelectContent.RemoveScroll"),kV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:a,onEscapeKeyDown:o,onPointerDownOutside:i,side:s,sideOffset:l,align:c,alignOffset:u,arrowPadding:d,collisionBoundary:p,collisionPadding:h,sticky:f,hideWhenDetached:m,avoidCollisions:g,...y}=e,b=oV(fV,n),[v,k]=K.useState(null),[w,x]=K.useState(null),E=U$(t,(e=>k(e))),[_,S]=K.useState(null),[T,C]=K.useState(null),A=JG(n),[N,I]=K.useState(!1),R=K.useRef(!1);K.useEffect((()=>{if(v)return FH(v)}),[v]),dG();const O=K.useCallback((e=>{const[t,...n]=A().map((e=>e.ref.current)),[r]=n.slice(-1),a=document.activeElement;for(const o of e){if(o===a)return;if(null==o||o.scrollIntoView({block:"nearest"}),o===t&&w&&(w.scrollTop=0),o===r&&w&&(w.scrollTop=w.scrollHeight),null==o||o.focus(),document.activeElement!==a)return}}),[A,w]),P=K.useCallback((()=>O([_,v])),[O,_,v]);K.useEffect((()=>{N&&P()}),[N,P]);const{onOpenChange:D,triggerPointerDownPosRef:L}=b;K.useEffect((()=>{if(v){let e={x:0,y:0};const t=t=>{var n,r;e={x:Math.abs(Math.round(t.pageX)-((null==(n=L.current)?void 0:n.x)??0)),y:Math.abs(Math.round(t.pageY)-((null==(r=L.current)?void 0:r.y)??0))}},n=n=>{e.x<=10&&e.y<=10?n.preventDefault():v.contains(n.target)||D(!1),document.removeEventListener("pointermove",t),L.current=null};return null!==L.current&&(document.addEventListener("pointermove",t),document.addEventListener("pointerup",n,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",t),document.removeEventListener("pointerup",n,{capture:!0})}}}),[v,D,L]),K.useEffect((()=>{const e=()=>D(!1);return window.addEventListener("blur",e),window.addEventListener("resize",e),()=>{window.removeEventListener("blur",e),window.removeEventListener("resize",e)}}),[D]);const[M,F]=XV((e=>{const t=A().filter((e=>!e.disabled)),n=t.find((e=>e.ref.current===document.activeElement)),r=QV(t,e,n);r&&setTimeout((()=>r.ref.current.focus()))})),j=K.useCallback(((e,t,n)=>{const r=!R.current&&!n;(void 0!==b.value&&b.value===t||r)&&(S(e),r&&(R.current=!0))}),[b.value]),B=K.useCallback((()=>null==v?void 0:v.focus()),[v]),z=K.useCallback(((e,t,n)=>{const r=!R.current&&!n;(void 0!==b.value&&b.value===t||r)&&C(e)}),[b.value]),H="popper"===r?xV:wV,U=H===xV?{side:s,sideOffset:l,align:c,alignOffset:u,arrowPadding:d,collisionBoundary:p,collisionPadding:h,sticky:f,hideWhenDetached:m,avoidCollisions:g}:{};return Wh.jsx(yV,{scope:n,content:v,viewport:w,onViewportChange:x,itemRefCallback:j,selectedItem:_,onItemLeave:B,itemTextRefCallback:z,focusSelectedItem:P,selectedItemText:T,position:r,isPositioned:N,searchRef:M,children:Wh.jsx(SU,{as:vV,allowPinchZoom:!0,removeScrollBar:!1,children:Wh.jsx(gG,{asChild:!0,trapped:b.open,onMountAutoFocus:e=>{e.preventDefault()},onUnmountAutoFocus:F$(a,(e=>{var t;null==(t=b.trigger)||t.focus({preventScroll:!0}),e.preventDefault()})),children:Wh.jsx(iG,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:o,onPointerDownOutside:i,onFocusOutside:e=>e.preventDefault(),onDismiss:()=>b.onOpenChange(!1),children:Wh.jsx(H,{role:"listbox",id:b.contentId,"data-state":b.open?"open":"closed",dir:b.dir,onContextMenu:e=>e.preventDefault(),...y,...U,onPlaced:()=>I(!0),ref:E,style:{display:"flex",flexDirection:"column",outline:"none",...y.style},onKeyDown:F$(y.onKeyDown,(e=>{const t=e.ctrlKey||e.altKey||e.metaKey;if("Tab"===e.key&&e.preventDefault(),t||1!==e.key.length||F(e.key),["ArrowUp","ArrowDown","Home","End"].includes(e.key)){let t=A().filter((e=>!e.disabled)).map((e=>e.ref.current));if(["ArrowUp","End"].includes(e.key)&&(t=t.slice().reverse()),["ArrowUp","ArrowDown"].includes(e.key)){const n=e.target,r=t.indexOf(n);t=t.slice(r+1)}setTimeout((()=>O(t))),e.preventDefault()}}))})})})})})}));kV.displayName="SelectContentImpl";const wV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,onPlaced:r,...a}=e,o=oV(fV,n),i=bV(fV,n),[s,l]=K.useState(null),[c,u]=K.useState(null),d=U$(t,(e=>u(e))),p=JG(n),h=K.useRef(!1),f=K.useRef(!0),{viewport:m,selectedItem:g,selectedItemText:y,focusSelectedItem:b}=i,v=K.useCallback((()=>{if(o.trigger&&o.valueNode&&s&&c&&m&&g&&y){const e=o.trigger.getBoundingClientRect(),t=c.getBoundingClientRect(),n=o.valueNode.getBoundingClientRect(),a=y.getBoundingClientRect();if("rtl"!==o.dir){const r=a.left-t.left,o=n.left-r,i=e.left-o,l=e.width+i,c=Math.max(l,t.width),u=window.innerWidth-gV,d=M$(o,[gV,Math.max(gV,u-c)]);s.style.minWidth=l+"px",s.style.left=d+"px"}else{const r=t.right-a.right,o=window.innerWidth-n.right-r,i=window.innerWidth-e.right-o,l=e.width+i,c=Math.max(l,t.width),u=window.innerWidth-gV,d=M$(o,[gV,Math.max(gV,u-c)]);s.style.minWidth=l+"px",s.style.right=d+"px"}const i=p(),l=window.innerHeight-2*gV,u=m.scrollHeight,d=window.getComputedStyle(c),f=Number.parseInt(d.borderTopWidth,10),b=Number.parseInt(d.paddingTop,10),v=Number.parseInt(d.borderBottomWidth,10),k=f+b+u+Number.parseInt(d.paddingBottom,10)+v,w=Math.min(5*g.offsetHeight,k),x=window.getComputedStyle(m),E=Number.parseInt(x.paddingTop,10),_=Number.parseInt(x.paddingBottom,10),S=e.top+e.height/2-gV,T=l-S,C=g.offsetHeight/2,A=f+b+(g.offsetTop+C),N=k-A;if(A<=S){const e=i.length>0&&g===i[i.length-1].ref.current;s.style.bottom="0px";const t=c.clientHeight-m.offsetTop-m.offsetHeight,n=A+Math.max(T,C+(e?_:0)+t+v);s.style.height=n+"px"}else{const e=i.length>0&&g===i[0].ref.current;s.style.top="0px";const t=Math.max(S,f+m.offsetTop+(e?E:0)+C)+N;s.style.height=t+"px",m.scrollTop=A-S+m.offsetTop}s.style.margin=`${gV}px 0`,s.style.minHeight=w+"px",s.style.maxHeight=l+"px",null==r||r(),requestAnimationFrame((()=>h.current=!0))}}),[p,o.trigger,o.valueNode,s,c,m,g,y,o.dir,r]);FO((()=>v()),[v]);const[k,w]=K.useState();FO((()=>{c&&w(window.getComputedStyle(c).zIndex)}),[c]);const x=K.useCallback((e=>{e&&!0===f.current&&(v(),null==b||b(),f.current=!1)}),[v,b]);return Wh.jsx(EV,{scope:n,contentWrapper:s,shouldExpandOnScrollRef:h,onScrollButtonChange:x,children:Wh.jsx("div",{ref:l,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:k},children:Wh.jsx(eG.div,{...a,ref:d,style:{boxSizing:"border-box",maxHeight:"100%",...a.style}})})})}));wV.displayName="SelectItemAlignedPosition";const xV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:a=gV,...o}=e,i=rV(n);return Wh.jsx(qG,{...i,...o,ref:t,align:r,collisionPadding:a,style:{boxSizing:"border-box",...o.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})}));xV.displayName="SelectPopperPosition";const[EV,_V]=tV(fV,{}),SV="SelectViewport",TV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,nonce:r,...a}=e,o=bV(SV,n),i=_V(SV,n),s=U$(t,o.onViewportChange),l=K.useRef(0);return Wh.jsxs(Wh.Fragment,{children:[Wh.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:r}),Wh.jsx(ZG.Slot,{scope:n,children:Wh.jsx(eG.div,{"data-radix-select-viewport":"",role:"presentation",...a,ref:s,style:{position:"relative",flex:1,overflow:"hidden auto",...a.style},onScroll:F$(a.onScroll,(e=>{const t=e.currentTarget,{contentWrapper:n,shouldExpandOnScrollRef:r}=i;if((null==r?void 0:r.current)&&n){const e=Math.abs(l.current-t.scrollTop);if(e>0){const r=window.innerHeight-2*gV,a=Number.parseFloat(n.style.minHeight),o=Number.parseFloat(n.style.height),i=Math.max(a,o);if(i<r){const a=i+e,o=Math.min(r,a),s=a-o;n.style.height=o+"px","0px"===n.style.bottom&&(t.scrollTop=s>0?s:0,n.style.justifyContent="flex-end")}}}l.current=t.scrollTop}))})})]})}));TV.displayName=SV;const CV="SelectGroup",[AV,NV]=tV(CV),IV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e,a=zO();return Wh.jsx(AV,{scope:n,id:a,children:Wh.jsx(eG.div,{role:"group","aria-labelledby":a,...r,ref:t})})}));IV.displayName=CV;const RV="SelectLabel",OV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e,a=NV(RV,n);return Wh.jsx(eG.div,{id:a.id,...r,ref:t})}));OV.displayName=RV;const PV="SelectItem",[DV,LV]=tV(PV),MV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,value:r,disabled:a=!1,textValue:o,...i}=e,s=oV(PV,n),l=bV(PV,n),c=s.value===r,[u,d]=K.useState(o??""),[p,h]=K.useState(!1),f=U$(t,(e=>{var t;return null==(t=l.itemRefCallback)?void 0:t.call(l,e,r,a)})),m=zO(),g=K.useRef("touch"),y=()=>{a||(s.onValueChange(r),s.onOpenChange(!1))};if(""===r)throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return Wh.jsx(DV,{scope:n,value:r,disabled:a,textId:m,isSelected:c,onItemTextChange:K.useCallback((e=>{d((t=>t||((null==e?void 0:e.textContent)??"").trim()))}),[]),children:Wh.jsx(ZG.ItemSlot,{scope:n,value:r,disabled:a,textValue:u,children:Wh.jsx(eG.div,{role:"option","aria-labelledby":m,"data-highlighted":p?"":void 0,"aria-selected":c&&p,"data-state":c?"checked":"unchecked","aria-disabled":a||void 0,"data-disabled":a?"":void 0,tabIndex:a?void 0:-1,...i,ref:f,onFocus:F$(i.onFocus,(()=>h(!0))),onBlur:F$(i.onBlur,(()=>h(!1))),onClick:F$(i.onClick,(()=>{"mouse"!==g.current&&y()})),onPointerUp:F$(i.onPointerUp,(()=>{"mouse"===g.current&&y()})),onPointerDown:F$(i.onPointerDown,(e=>{g.current=e.pointerType})),onPointerMove:F$(i.onPointerMove,(e=>{var t;g.current=e.pointerType,a?null==(t=l.onItemLeave)||t.call(l):"mouse"===g.current&&e.currentTarget.focus({preventScroll:!0})})),onPointerLeave:F$(i.onPointerLeave,(e=>{var t;e.currentTarget===document.activeElement&&(null==(t=l.onItemLeave)||t.call(l))})),onKeyDown:F$(i.onKeyDown,(e=>{var t;""!==(null==(t=l.searchRef)?void 0:t.current)&&" "===e.key||(XG.includes(e.key)&&y()," "===e.key&&e.preventDefault())}))})})})}));MV.displayName=PV;const FV="SelectItemText",jV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,className:r,style:a,...o}=e,i=oV(FV,n),s=bV(FV,n),l=LV(FV,n),c=sV(FV,n),[u,d]=K.useState(null),p=U$(t,(e=>d(e)),l.onItemTextChange,(e=>{var t;return null==(t=s.itemTextRefCallback)?void 0:t.call(s,e,l.value,l.disabled)})),h=null==u?void 0:u.textContent,f=K.useMemo((()=>Wh.jsx("option",{value:l.value,disabled:l.disabled,children:h},l.value)),[l.disabled,l.value,h]),{onNativeOptionAdd:m,onNativeOptionRemove:g}=c;return FO((()=>(m(f),()=>g(f))),[m,g,f]),Wh.jsxs(Wh.Fragment,{children:[Wh.jsx(eG.span,{id:l.textId,...o,ref:p}),l.isSelected&&i.valueNode&&!i.valueNodeHasChildren?se.createPortal(o.children,i.valueNode):null]})}));jV.displayName=FV;const BV="SelectItemIndicator",zV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e;return LV(BV,n).isSelected?Wh.jsx(eG.span,{"aria-hidden":!0,...r,ref:t}):null}));zV.displayName=BV;const HV="SelectScrollUpButton",UV=K.forwardRef(((e,t)=>{const n=bV(HV,e.__scopeSelect),r=_V(HV,e.__scopeSelect),[a,o]=K.useState(!1),i=U$(t,r.onScrollButtonChange);return FO((()=>{if(n.viewport&&n.isPositioned){let e=function(){const e=t.scrollTop>0;o(e)};const t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[n.viewport,n.isPositioned]),a?Wh.jsx(VV,{...e,ref:i,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop-t.offsetHeight)}}):null}));UV.displayName=HV;const $V="SelectScrollDownButton",GV=K.forwardRef(((e,t)=>{const n=bV($V,e.__scopeSelect),r=_V($V,e.__scopeSelect),[a,o]=K.useState(!1),i=U$(t,r.onScrollButtonChange);return FO((()=>{if(n.viewport&&n.isPositioned){let e=function(){const e=t.scrollHeight-t.clientHeight,n=Math.ceil(t.scrollTop)<e;o(n)};const t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[n.viewport,n.isPositioned]),a?Wh.jsx(VV,{...e,ref:i,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop+t.offsetHeight)}}):null}));GV.displayName=$V;const VV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...a}=e,o=bV("SelectScrollButton",n),i=K.useRef(null),s=JG(n),l=K.useCallback((()=>{null!==i.current&&(window.clearInterval(i.current),i.current=null)}),[]);return K.useEffect((()=>()=>l()),[l]),FO((()=>{var e;const t=s().find((e=>e.ref.current===document.activeElement));null==(e=null==t?void 0:t.ref.current)||e.scrollIntoView({block:"nearest"})}),[s]),Wh.jsx(eG.div,{"aria-hidden":!0,...a,ref:t,style:{flexShrink:0,...a.style},onPointerDown:F$(a.onPointerDown,(()=>{null===i.current&&(i.current=window.setInterval(r,50))})),onPointerMove:F$(a.onPointerMove,(()=>{var e;null==(e=o.onItemLeave)||e.call(o),null===i.current&&(i.current=window.setInterval(r,50))})),onPointerLeave:F$(a.onPointerLeave,(()=>{l()}))})})),qV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e;return Wh.jsx(eG.div,{"aria-hidden":!0,...r,ref:t})}));qV.displayName="SelectSeparator";const WV="SelectArrow",YV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e,a=rV(n),o=oV(WV,n),i=bV(WV,n);return o.open&&"popper"===i.position?Wh.jsx(WG,{...a,...r,ref:t}):null}));function KV(e){return""===e||void 0===e}function XV(e){const t=RB(e),n=K.useRef(""),r=K.useRef(0),a=K.useCallback((e=>{const a=n.current+e;t(a),function e(t){n.current=t,window.clearTimeout(r.current),""!==t&&(r.current=window.setTimeout((()=>e("")),1e3))}(a)}),[t]),o=K.useCallback((()=>{n.current="",window.clearTimeout(r.current)}),[]);return K.useEffect((()=>()=>window.clearTimeout(r.current)),[]),[n,a,o]}function QV(e,t,n){const r=t.length>1&&Array.from(t).every((e=>e===t[0]))?t[0]:t,a=n?e.indexOf(n):-1;let o=(i=e,s=Math.max(a,0),i.map(((e,t)=>i[(s+t)%i.length])));var i,s;1===r.length&&(o=o.filter((e=>e!==n)));const l=o.find((e=>e.textValue.toLowerCase().startsWith(r.toLowerCase())));return l!==n?l:void 0}YV.displayName=WV;const ZV=lV,JV=uV,eq=pV,tq=hV,nq=mV,rq=TV,aq=MV,oq=jV,iq=zV;var sq=e=>"object"==typeof e&&null!==e,lq=e=>sq(e)&&1===e.nodeType&&"string"==typeof e.nodeName,cq=e=>sq(e)&&9===e.nodeType,uq=/(textarea|select)/;function dq(e){if(null==e||!lq(e))return!1;try{return(e=>lq(e)&&"input"===e.localName)(e)&&null!=e.selectionStart||uq.test(e.localName)||e.isContentEditable||"true"===e.getAttribute("contenteditable")||""===e.getAttribute("contenteditable")}catch{return!1}}function pq(e){return cq(e)?e:(e=>sq(e)&&e===e.window)(e)?e.document:(null==e?void 0:e.ownerDocument)??document}function hq(e){const t=function(e){var t,n,r;return(null==(t=e.composedPath)?void 0:t.call(e))??(null==(r=null==(n=e.nativeEvent)?void 0:n.composedPath)?void 0:r.call(n))}(e);return(null==t?void 0:t[0])??e.target}var fq=(e,t,n,r)=>{const a="function"==typeof e?e():e;return null==a||a.addEventListener(t,n,r),()=>{null==a||a.removeEventListener(t,n,r)}},mq=e=>lq(e)&&"IFRAME"===e.tagName,gq="input:not([type='hidden']):not([disabled]), select:not([disabled]), textarea:not([disabled]), a[href], button:not([disabled]), [tabindex], iframe, object, embed, area[href], audio[controls], video[controls], [contenteditable]:not([contenteditable='false']), details > summary:first-of-type",yq=(e,t=!1)=>{if(!e)return[];const n=Array.from(e.querySelectorAll(gq));(1==t||"if-empty"==t&&0===n.length)&&lq(e)&&bq(e)&&n.unshift(e);const r=n.filter(bq);return r.forEach(((e,t)=>{if(mq(e)&&e.contentDocument){const n=e.contentDocument.body;r.splice(t,1,...yq(n))}})),r};function bq(e){return!(!e||e.closest("[inert]"))&&(e.matches(gq)&&(!!lq(t=e)&&(t.offsetWidth>0||t.offsetHeight>0||t.getClientRects().length>0)));var t}function vq(e,t){if(!e)return[];const n=Array.from(e.querySelectorAll(gq)).filter(kq);return n.forEach(((e,t)=>{if(mq(e)&&e.contentDocument){const r=vq(e.contentDocument.body);n.splice(t,1,...r)}})),n.length,n}function kq(e){return null!=e&&e.tabIndex>0||bq(e)&&!(e=>parseInt(e.getAttribute("tabindex")||"0",10)<0)(e)}function wq(e){return e.tabIndex<0&&(/^(audio|video|details)$/.test(e.localName)||dq(e))&&(t=e,Number.isNaN(parseInt(t.getAttribute("tabindex")||"0",10)))?0:e.tabIndex;var t}var xq=Object.defineProperty,Eq=(e,t,n)=>((e,t,n)=>t in e?xq(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n)(e,"symbol"!=typeof t?t+"":t,n),_q={activateTrap(e,t){if(e.length>0){const n=e[e.length-1];n!==t&&n.pause()}const n=e.indexOf(t);-1===n||e.splice(n,1),e.push(t)},deactivateTrap(e,t){const n=e.indexOf(t);-1!==n&&e.splice(n,1),e.length>0&&e[e.length-1].unpause()}},Sq=[],Tq=class{constructor(e,t){Eq(this,"trapStack"),Eq(this,"config"),Eq(this,"doc"),Eq(this,"state",{containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,delayInitialFocusTimer:void 0,recentNavEvent:void 0}),Eq(this,"listenerCleanups",[]),Eq(this,"handleFocus",(e=>{const t=hq(e),n=this.findContainerIndex(t,e)>=0;if(n||cq(t))n&&(this.state.mostRecentlyFocusedNode=t);else{let t;e.stopImmediatePropagation();let n=!0;if(this.state.mostRecentlyFocusedNode)if(wq(this.state.mostRecentlyFocusedNode)>0){const e=this.findContainerIndex(this.state.mostRecentlyFocusedNode),{tabbableNodes:r}=this.state.containerGroups[e];if(r.length>0){const e=r.findIndex((e=>e===this.state.mostRecentlyFocusedNode));e>=0&&(this.config.isKeyForward(this.state.recentNavEvent)?e+1<r.length&&(t=r[e+1],n=!1):e-1>=0&&(t=r[e-1],n=!1))}}else this.state.containerGroups.some((e=>e.tabbableNodes.some((e=>wq(e)>0))))||(n=!1);else n=!1;n&&(t=this.findNextNavNode({target:this.state.mostRecentlyFocusedNode,isBackward:this.config.isKeyBackward(this.state.recentNavEvent)})),t?this.tryFocus(t):this.tryFocus(this.state.mostRecentlyFocusedNode||this.getInitialFocusNode())}this.state.recentNavEvent=void 0})),Eq(this,"handlePointerDown",(e=>{const t=hq(e);this.findContainerIndex(t,e)>=0||(Aq(this.config.clickOutsideDeactivates,e)?this.deactivate({returnFocus:this.config.returnFocusOnDeactivate}):Aq(this.config.allowOutsideClick,e)||e.preventDefault())})),Eq(this,"handleClick",(e=>{const t=hq(e);this.findContainerIndex(t,e)>=0||Aq(this.config.clickOutsideDeactivates,e)||Aq(this.config.allowOutsideClick,e)||(e.preventDefault(),e.stopImmediatePropagation())})),Eq(this,"handleTabKey",(e=>{if(this.config.isKeyForward(e)||this.config.isKeyBackward(e)){this.state.recentNavEvent=e;const t=this.config.isKeyBackward(e),n=this.findNextNavNode({event:e,isBackward:t});if(!n)return;Cq(e)&&e.preventDefault(),this.tryFocus(n)}})),Eq(this,"handleEscapeKey",(e=>{Nq(e)&&!1!==Aq(this.config.escapeDeactivates,e)&&(e.preventDefault(),this.deactivate())})),Eq(this,"_mutationObserver"),Eq(this,"setupMutationObserver",(()=>{const e=this.doc.defaultView||window;this._mutationObserver=new e.MutationObserver((e=>{e.some((e=>Array.from(e.removedNodes).some((e=>e===this.state.mostRecentlyFocusedNode))))&&this.tryFocus(this.getInitialFocusNode())}))})),Eq(this,"updateObservedNodes",(()=>{var e;null==(e=this._mutationObserver)||e.disconnect(),this.state.active&&!this.state.paused&&this.state.containers.map((e=>{var t;null==(t=this._mutationObserver)||t.observe(e,{subtree:!0,childList:!0})}))})),Eq(this,"getInitialFocusNode",(()=>{let e=this.getNodeForOption("initialFocus",{hasFallback:!0});if(!1===e)return!1;if(void 0===e||e&&!bq(e))if(this.findContainerIndex(this.doc.activeElement)>=0)e=this.doc.activeElement;else{const t=this.state.tabbableGroups[0];e=t&&t.firstTabbableNode||this.getNodeForOption("fallbackFocus")}else null===e&&(e=this.getNodeForOption("fallbackFocus"));if(!e)throw new Error("Your focus-trap needs to have at least one focusable element");return e.isConnected||(e=this.getNodeForOption("fallbackFocus")),e})),Eq(this,"tryFocus",(e=>{!1!==e&&e!==function(e){let t=e.activeElement;for(;null==t?void 0:t.shadowRoot;){const e=t.shadowRoot.activeElement;if(e===t)break;t=e}return t}(this.doc)&&(e&&e.focus?(e.focus({preventScroll:!!this.config.preventScroll}),this.state.mostRecentlyFocusedNode=e,Rq(e)&&e.select()):this.tryFocus(this.getInitialFocusNode()))})),Eq(this,"deactivate",(e=>{if(!this.state.active)return this;const t={onDeactivate:this.config.onDeactivate,onPostDeactivate:this.config.onPostDeactivate,checkCanReturnFocus:this.config.checkCanReturnFocus,...e};clearTimeout(this.state.delayInitialFocusTimer),this.state.delayInitialFocusTimer=void 0,this.removeListeners(),this.state.active=!1,this.state.paused=!1,this.updateObservedNodes(),_q.deactivateTrap(this.trapStack,this);const n=this.getOption(t,"onDeactivate"),r=this.getOption(t,"onPostDeactivate"),a=this.getOption(t,"checkCanReturnFocus"),o=this.getOption(t,"returnFocus","returnFocusOnDeactivate");null==n||n();const i=()=>{Iq((()=>{if(o){const e=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);this.tryFocus(e)}null==r||r()}))};if(o&&a){return a(this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation)).then(i,i),this}return i(),this})),Eq(this,"pause",(e=>{if(this.state.paused||!this.state.active)return this;const t=this.getOption(e,"onPause"),n=this.getOption(e,"onPostPause");return this.state.paused=!0,null==t||t(),this.removeListeners(),this.updateObservedNodes(),null==n||n(),this})),Eq(this,"unpause",(e=>{if(!this.state.paused||!this.state.active)return this;const t=this.getOption(e,"onUnpause"),n=this.getOption(e,"onPostUnpause");return this.state.paused=!1,null==t||t(),this.updateTabbableNodes(),this.addListeners(),this.updateObservedNodes(),null==n||n(),this})),Eq(this,"updateContainerElements",(e=>(this.state.containers=Array.isArray(e)?e.filter(Boolean):[e].filter(Boolean),this.state.active&&this.updateTabbableNodes(),this.updateObservedNodes(),this))),Eq(this,"getReturnFocusNode",(e=>{const t=this.getNodeForOption("setReturnFocus",{params:[e]});return t||!1!==t&&e})),Eq(this,"getOption",((e,t,n)=>e&&void 0!==e[t]?e[t]:this.config[n||t])),Eq(this,"getNodeForOption",((e,{hasFallback:t=!1,params:n=[]}={})=>{let r=this.config[e];if("function"==typeof r&&(r=r(...n)),!0===r&&(r=void 0),!r){if(void 0===r||!1===r)return r;throw new Error(`\`${e}\` was specified but was not a node, or did not return a node`)}let a=r;if("string"==typeof r){try{a=this.doc.querySelector(r)}catch(xbe){throw new Error(`\`${e}\` appears to be an invalid selector; error="${xbe.message}"`)}if(!a&&!t)throw new Error(`\`${e}\` as selector refers to no known node`)}return a})),Eq(this,"findNextNavNode",(e=>{const{event:t,isBackward:n=!1}=e,r=e.target||hq(t);this.updateTabbableNodes();let a=null;if(this.state.tabbableGroups.length>0){const e=this.findContainerIndex(r,t),o=e>=0?this.state.containerGroups[e]:void 0;if(e<0)a=n?this.state.tabbableGroups[this.state.tabbableGroups.length-1].lastTabbableNode:this.state.tabbableGroups[0].firstTabbableNode;else if(n){let n=this.state.tabbableGroups.findIndex((({firstTabbableNode:e})=>r===e));if(n<0&&((null==o?void 0:o.container)===r||bq(r)&&!kq(r)&&!(null==o?void 0:o.nextTabbableNode(r,!1)))&&(n=e),n>=0){const e=0===n?this.state.tabbableGroups.length-1:n-1,t=this.state.tabbableGroups[e];a=wq(r)>=0?t.lastTabbableNode:t.lastDomTabbableNode}else Cq(t)||(a=null==o?void 0:o.nextTabbableNode(r,!1))}else{let n=this.state.tabbableGroups.findIndex((({lastTabbableNode:e})=>r===e));if(n<0&&((null==o?void 0:o.container)===r||bq(r)&&!kq(r)&&!(null==o?void 0:o.nextTabbableNode(r)))&&(n=e),n>=0){const e=n===this.state.tabbableGroups.length-1?0:n+1,t=this.state.tabbableGroups[e];a=wq(r)>=0?t.firstTabbableNode:t.firstDomTabbableNode}else Cq(t)||(a=null==o?void 0:o.nextTabbableNode(r))}}else a=this.getNodeForOption("fallbackFocus");return a})),this.trapStack=t.trapStack||Sq;const n={returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,isKeyForward:e=>Cq(e)&&!e.shiftKey,isKeyBackward:e=>Cq(e)&&e.shiftKey,...t};this.doc=n.document||pq(Array.isArray(e)?e[0]:e),this.config=n,this.updateContainerElements(e),this.setupMutationObserver()}get active(){return this.state.active}get paused(){return this.state.paused}findContainerIndex(e,t){const n="function"==typeof(null==t?void 0:t.composedPath)?t.composedPath():void 0;return this.state.containerGroups.findIndex((({container:t,tabbableNodes:r})=>t.contains(e)||(null==n?void 0:n.includes(t))||r.find((t=>t===e))))}updateTabbableNodes(){if(this.state.containerGroups=this.state.containers.map((e=>{const t=vq(e),n=yq(e),r=t.length>0?t[0]:void 0,a=t.length>0?t[t.length-1]:void 0,o=n.find((e=>kq(e))),i=n.slice().reverse().find((e=>kq(e))),s=!!t.find((e=>wq(e)>0));return{container:e,tabbableNodes:t,focusableNodes:n,posTabIndexesFound:s,firstTabbableNode:r,lastTabbableNode:a,firstDomTabbableNode:o,lastDomTabbableNode:i,nextTabbableNode:function(e,r=!0){const a=t.indexOf(e);return a<0?r?n.slice(n.indexOf(e)+1).find((e=>kq(e))):n.slice(0,n.indexOf(e)).reverse().find((e=>kq(e))):t[a+(r?1:-1)]}}})),this.state.tabbableGroups=this.state.containerGroups.filter((e=>e.tabbableNodes.length>0)),this.state.tabbableGroups.length<=0&&!this.getNodeForOption("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times");if(this.state.containerGroups.find((e=>e.posTabIndexesFound))&&this.state.containerGroups.length>1)throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.")}addListeners(){if(this.state.active)return _q.activateTrap(this.trapStack,this),this.state.delayInitialFocusTimer=this.config.delayInitialFocus?Iq((()=>{this.tryFocus(this.getInitialFocusNode())})):this.tryFocus(this.getInitialFocusNode()),this.listenerCleanups.push(fq(this.doc,"focusin",this.handleFocus,!0),fq(this.doc,"mousedown",this.handlePointerDown,{capture:!0,passive:!1}),fq(this.doc,"touchstart",this.handlePointerDown,{capture:!0,passive:!1}),fq(this.doc,"click",this.handleClick,{capture:!0,passive:!1}),fq(this.doc,"keydown",this.handleTabKey,{capture:!0,passive:!1}),fq(this.doc,"keydown",this.handleEscapeKey)),this}removeListeners(){if(this.state.active)return this.listenerCleanups.forEach((e=>e())),this.listenerCleanups=[],this}activate(e){if(this.state.active)return this;const t=this.getOption(e,"onActivate"),n=this.getOption(e,"onPostActivate"),r=this.getOption(e,"checkCanFocusTrap");r||this.updateTabbableNodes(),this.state.active=!0,this.state.paused=!1,this.state.nodeFocusedBeforeActivation=this.doc.activeElement||null,null==t||t();const a=()=>{r&&this.updateTabbableNodes(),this.addListeners(),this.updateObservedNodes(),null==n||n()};return r?(r(this.state.containers.concat()).then(a,a),this):(a(),this)}},Cq=e=>"Tab"===e.key,Aq=(e,...t)=>"function"==typeof e?e(...t):e,Nq=e=>!e.isComposing&&"Escape"===e.key,Iq=e=>setTimeout(e,0),Rq=e=>"input"===e.localName&&"select"in e&&"function"==typeof e.select;function Oq(e,t={}){let n;const r=function(e){let t;const n=globalThis.requestAnimationFrame((()=>{t=e()}));return()=>{globalThis.cancelAnimationFrame(n),null==t||t()}}((()=>{const r="function"==typeof e?e():e;if(r){n=new Tq(r,{escapeDeactivates:!1,allowOutsideClick:!0,preventScroll:!0,returnFocusOnDeactivate:!0,delayInitialFocus:!1,fallbackFocus:r,...t,document:pq(r)});try{n.activate()}catch{}}}));return function(){null==n||n.deactivate(),r()}}var Pq=e=>{const{present:t,children:n}=e,r=function(e){const[t,n]=K.useState(),r=K.useRef({}),a=K.useRef(e),o=K.useRef("none"),i=e?"mounted":"unmounted",[s,l]=function(e,t){return K.useReducer(((e,n)=>t[e][n]??e),e)}(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return K.useEffect((()=>{const e=Dq(r.current);o.current="mounted"===s?e:"none"}),[s]),FO((()=>{const t=r.current,n=a.current;if(n!==e){const r=o.current,i=Dq(t);if(e)l("MOUNT");else if("none"===i||"none"===(null==t?void 0:t.display))l("UNMOUNT");else{l(n&&r!==i?"ANIMATION_OUT":"UNMOUNT")}a.current=e}}),[e,l]),FO((()=>{if(t){let e;const n=t.ownerDocument.defaultView??window,i=o=>{const i=Dq(r.current).includes(o.animationName);if(o.target===t&&i&&(l("ANIMATION_END"),!a.current)){const r=t.style.animationFillMode;t.style.animationFillMode="forwards",e=n.setTimeout((()=>{"forwards"===t.style.animationFillMode&&(t.style.animationFillMode=r)}))}},s=e=>{e.target===t&&(o.current=Dq(r.current))};return t.addEventListener("animationstart",s),t.addEventListener("animationcancel",i),t.addEventListener("animationend",i),()=>{n.clearTimeout(e),t.removeEventListener("animationstart",s),t.removeEventListener("animationcancel",i),t.removeEventListener("animationend",i)}}l("ANIMATION_END")}),[t,l]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:K.useCallback((e=>{e&&(r.current=getComputedStyle(e)),n(e)}),[])}}(t),a="function"==typeof n?n({present:r.isPresent}):K.Children.only(n),o=U$(r.ref,function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;if(a)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a)return e.props.ref;return e.props.ref||e.ref}(a));return"function"==typeof n||r.isPresent?K.cloneElement(a,{ref:o}):null};function Dq(e){return(null==e?void 0:e.animationName)||"none"}Pq.displayName="Presence";const Lq="Dialog",[Mq,Fq]=j$(Lq),[jq,Bq]=Mq(Lq),zq=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:a,onOpenChange:o,modal:i=!0}=e,s=K.useRef(null),l=K.useRef(null),[c=!1,u]=OB({prop:r,defaultProp:a,onChange:o});return Wh.jsx(jq,{scope:t,triggerRef:s,contentRef:l,contentId:zO(),titleId:zO(),descriptionId:zO(),open:c,onOpenChange:u,onOpenToggle:K.useCallback((()=>u((e=>!e))),[u]),modal:i,children:n})};zq.displayName=Lq;const Hq="DialogTrigger",Uq=K.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,a=Bq(Hq,n),o=U$(t,a.triggerRef);return Wh.jsx(eG.button,{type:"button","aria-haspopup":"dialog","aria-expanded":a.open,"aria-controls":a.contentId,"data-state":sW(a.open),...r,ref:o,onClick:F$(e.onClick,a.onOpenToggle)})}));Uq.displayName=Hq;const $q="DialogPortal",[Gq,Vq]=Mq($q,{forceMount:void 0}),qq=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:a}=e,o=Bq($q,t);return Wh.jsx(Gq,{scope:t,forceMount:n,children:K.Children.map(r,(e=>Wh.jsx(Pq,{present:n||o.open,children:Wh.jsx(YG,{asChild:!0,container:a,children:e})})))})};qq.displayName=$q;const Wq="DialogOverlay",Yq=K.forwardRef(((e,t)=>{const n=Vq(Wq,e.__scopeDialog),{forceMount:r=n.forceMount,...a}=e,o=Bq(Wq,e.__scopeDialog);return o.modal?Wh.jsx(Pq,{present:r||o.open,children:Wh.jsx(Kq,{...a,ref:t})}):null}));Yq.displayName=Wq;const Kq=K.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,a=Bq(Wq,n);return Wh.jsx(SU,{as:X$,allowPinchZoom:!0,shards:[a.contentRef],gapMode:"padding",removeScrollBar:!0,children:Wh.jsx(eG.div,{"data-state":sW(a.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})})),Xq="DialogContent",Qq=K.forwardRef(((e,t)=>{const n=Vq(Xq,e.__scopeDialog),{forceMount:r=n.forceMount,...a}=e,o=Bq(Xq,e.__scopeDialog);return Wh.jsx(Pq,{present:r||o.open,children:o.modal?Wh.jsx(Zq,{...a,ref:t}):Wh.jsx(Jq,{...a,ref:t})})}));Qq.displayName=Xq;const Zq=K.forwardRef(((e,t)=>{const n=Bq(Xq,e.__scopeDialog),r=K.useRef(null),a=U$(t,n.contentRef,r);return K.useEffect((()=>{const e=r.current;if(e)return FH(e)}),[]),Wh.jsx(eW,{...e,ref:a,trapFocus:n.open,disableOutsidePointerEvents:!0,onPointerDownOutside:F$(e.onPointerDownOutside,(e=>{const t=e.detail.originalEvent,n=0===t.button&&!0===t.ctrlKey;(2===t.button||n)&&e.preventDefault()})),onFocusOutside:F$(e.onFocusOutside,(e=>e.preventDefault()))})})),Jq=K.forwardRef(((e,t)=>{const n=Bq(Xq,e.__scopeDialog),r=K.useRef(!1),a=K.useRef(!1);return Wh.jsx(eW,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onInteractOutside:t=>{var o,i;null==(o=e.onInteractOutside)||o.call(e,t),t.defaultPrevented||(r.current=!0,"pointerdown"===t.detail.originalEvent.type&&(a.current=!0));const s=t.target;(null==(i=n.triggerRef.current)?void 0:i.contains(s))&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&a.current&&t.preventDefault()}})})),eW=K.forwardRef(((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:a,onCloseAutoFocus:o,...i}=e,s=Bq(Xq,n),l=K.useRef(null),c=U$(t,l);return dG(),K.useEffect((()=>{if(r)return Oq(l.current,{preventScroll:!0,onActivate:a,onDeactivate:o,initialFocus:!1})}),[]),Wh.jsx(iG,{role:"dialog",id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":sW(s.open),...i,ref:c,onDismiss:()=>s.onOpenChange(!1)})})),tW="DialogTitle",nW=K.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,a=Bq(tW,n);return Wh.jsx(eG.h2,{id:a.titleId,...r,ref:t})}));nW.displayName=tW;const rW="DialogDescription",aW=K.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,a=Bq(rW,n);return Wh.jsx(eG.p,{id:a.descriptionId,...r,ref:t})}));aW.displayName=rW;const oW="DialogClose",iW=K.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,a=Bq(oW,n);return Wh.jsx(eG.button,{type:"button",...r,ref:t,onClick:F$(e.onClick,(()=>a.onOpenChange(!1)))})}));function sW(e){return e?"open":"closed"}iW.displayName=oW;const lW=zq,cW=qq,uW=Yq,dW=Qq,pW=nW,hW=iW,fW=K.forwardRef(((e,t)=>{const n=K.useId();return Wh.jsxs("svg",{viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",height:"100%",width:"100%",ref:t,...e,children:[Wh.jsx("title",{children:"AI Avatar"}),Wh.jsx("path",{d:"M9.937 15.5002C9.84772 15.1542 9.66734 14.8384 9.41462 14.5856C9.1619 14.3329 8.84607 14.1525 8.5 14.0632L2.365 12.4812C2.26033 12.4515 2.16821 12.3885 2.10261 12.3017C2.03702 12.2149 2.00153 12.1091 2.00153 12.0002C2.00153 11.8914 2.03702 11.7856 2.10261 11.6988C2.16821 11.612 2.26033 11.549 2.365 11.5192L8.5 9.93625C8.84595 9.84706 9.16169 9.66682 9.4144 9.41429C9.66711 9.16175 9.84757 8.84614 9.937 8.50025L11.519 2.36525C11.5484 2.26017 11.6114 2.16759 11.6983 2.10164C11.7853 2.0357 11.8914 2 12.0005 2C12.1096 2 12.2157 2.0357 12.3027 2.10164C12.3896 2.16759 12.4526 2.26017 12.482 2.36525L14.063 8.50025C14.1523 8.84632 14.3327 9.16215 14.5854 9.41487C14.8381 9.66759 15.1539 9.84797 15.5 9.93725L21.635 11.5182C21.7405 11.5473 21.8335 11.6103 21.8998 11.6973C21.9661 11.7844 22.0021 11.8908 22.0021 12.0002C22.0021 12.1097 21.9661 12.2161 21.8998 12.3032C21.8335 12.3902 21.7405 12.4531 21.635 12.4822L15.5 14.0632C15.1539 14.1525 14.8381 14.3329 14.5854 14.5856C14.3327 14.8384 14.1523 15.1542 14.063 15.5002L12.481 21.6353C12.4516 21.7403 12.3886 21.8329 12.3017 21.8989C12.2147 21.9648 12.1086 22.0005 11.9995 22.0005C11.8904 22.0005 11.7843 21.9648 11.6973 21.8989C11.6104 21.8329 11.5474 21.7403 11.518 21.6353L9.937 15.5002Z",stroke:`url(#${n}-stroke1)`,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),Wh.jsx("path",{d:"M18.9838 5.37522C18.9615 5.28871 18.9164 5.20975 18.8532 5.14657C18.79 5.08339 18.7111 5.0383 18.6246 5.01598L17.0909 4.62049C17.0647 4.61306 17.0417 4.5973 17.0253 4.5756C17.0089 4.5539 17 4.52744 17 4.50024C17 4.47304 17.0089 4.44659 17.0253 4.42488C17.0417 4.40318 17.0647 4.38742 17.0909 4.38L18.6246 3.98426C18.7111 3.96196 18.79 3.9169 18.8532 3.85377C18.9163 3.79064 18.9615 3.71174 18.9838 3.62527L19.3793 2.09155C19.3867 2.06528 19.4024 2.04214 19.4241 2.02565C19.4459 2.00917 19.4724 2.00024 19.4997 2.00024C19.527 2.00024 19.5535 2.00917 19.5752 2.02565C19.597 2.04214 19.6127 2.06528 19.6201 2.09155L20.0153 3.62527C20.0376 3.71178 20.0827 3.79074 20.1459 3.85391C20.2091 3.91709 20.288 3.96219 20.3745 3.98451L21.9082 4.37975C21.9346 4.38702 21.9579 4.40275 21.9744 4.42452C21.991 4.44628 22 4.47288 22 4.50024C22 4.5276 21.991 4.55421 21.9744 4.57597C21.9579 4.59774 21.9346 4.61347 21.9082 4.62074L20.3745 5.01598C20.288 5.0383 20.2091 5.08339 20.1459 5.14657C20.0827 5.20975 20.0376 5.28871 20.0153 5.37522L19.6198 6.90893C19.6124 6.9352 19.5967 6.95835 19.575 6.97483C19.5532 6.99132 19.5267 7.00024 19.4994 7.00024C19.4721 7.00024 19.4456 6.99132 19.4239 6.97483C19.4022 6.95835 19.3864 6.9352 19.3791 6.90893L18.9838 5.37522Z",stroke:`url(#${n}-stroke2)`,strokeLinecap:"round",strokeLinejoin:"round"}),Wh.jsx("path",{d:"M3.98382 20.3752C3.9615 20.2887 3.9164 20.2098 3.85322 20.1466C3.79005 20.0834 3.71109 20.0383 3.62458 20.016L2.09087 19.6205C2.0647 19.6131 2.04167 19.5973 2.02527 19.5756C2.00887 19.5539 2 19.5274 2 19.5002C2 19.473 2.00887 19.4466 2.02527 19.4249C2.04167 19.4032 2.0647 19.3874 2.09087 19.38L3.62458 18.9843C3.71106 18.962 3.78999 18.9169 3.85317 18.8538C3.91635 18.7906 3.96146 18.7117 3.98382 18.6253L4.37931 17.0916C4.38666 17.0653 4.4024 17.0421 4.42414 17.0257C4.44587 17.0092 4.4724 17.0002 4.49968 17.0002C4.52696 17.0002 4.55349 17.0092 4.57522 17.0257C4.59695 17.0421 4.6127 17.0653 4.62005 17.0916L5.01529 18.6253C5.03761 18.7118 5.0827 18.7907 5.14588 18.8539C5.20906 18.9171 5.28801 18.9622 5.37453 18.9845L6.90824 19.3797C6.93461 19.387 6.95787 19.4027 6.97445 19.4245C6.99102 19.4463 7 19.4729 7 19.5002C7 19.5276 6.99102 19.5542 6.97445 19.576C6.95787 19.5977 6.93461 19.6135 6.90824 19.6207L5.37453 20.016C5.28801 20.0383 5.20906 20.0834 5.14588 20.1466C5.0827 20.2098 5.03761 20.2887 5.01529 20.3752L4.6198 21.9089C4.61245 21.9352 4.5967 21.9583 4.57497 21.9748C4.55324 21.9913 4.52671 22.0002 4.49943 22.0002C4.47215 22.0002 4.44562 21.9913 4.42389 21.9748C4.40215 21.9583 4.38641 21.9352 4.37906 21.9089L3.98382 20.3752Z",stroke:`url(#${n}-stroke3)`,strokeLinecap:"round",strokeLinejoin:"round"}),Wh.jsxs("defs",{children:[Wh.jsxs("linearGradient",{id:`${n}-stroke1`,x1:"0.149625",y1:"0.148102",x2:"23.8539",y2:"23.8524",gradientUnits:"userSpaceOnUse",children:[Wh.jsx("stop",{offset:"0.287444",stopColor:"var(--start-color)"}),Wh.jsx("stop",{offset:"0.728693",stopColor:"var(--end-color)"})]}),Wh.jsxs("linearGradient",{id:`${n}-stroke2`,x1:"16.537",y1:"1.53728",x2:"22.463",y2:"7.46321",gradientUnits:"userSpaceOnUse",children:[Wh.jsx("stop",{offset:"0.287444",stopColor:"var(--start-color)"}),Wh.jsx("stop",{offset:"0.728693",stopColor:"var(--end-color)"})]}),Wh.jsxs("linearGradient",{id:`${n}-stroke3`,x1:"1.53704",y1:"16.5373",x2:"7.46296",y2:"22.4632",gradientUnits:"userSpaceOnUse",children:[Wh.jsx("stop",{offset:"0.287444",stopColor:"var(--start-color)"}),Wh.jsx("stop",{offset:"0.728693",stopColor:"var(--end-color)"})]})]})]})})),mW=K.forwardRef(((e,t)=>Wh.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",height:"32px",viewBox:"0 96 960 960",width:"32px",ref:t,...e,children:[Wh.jsx("title",{children:"User Avatar"}),Wh.jsx("path",{d:"M222 801q63-40 124.5-60.5T480 720q72 0 134 20.5T739 801q44-54 62.5-109T820 576q0-145-97.5-242.5T480 236q-145 0-242.5 97.5T140 576q0 61 19 116t63 109Zm257.814-195Q422 606 382.5 566.314q-39.5-39.686-39.5-97.5t39.686-97.314q39.686-39.5 97.5-39.5t97.314 39.686q39.5 39.686 39.5 97.5T577.314 566.5q-39.686 39.5-97.5 39.5Zm-.219 370q-83.146 0-156.275-31.5t-127.225-86Q142 804 111 731.159 80 658.319 80 575.5q0-82.819 31.5-155.659Q143 347 197.5 293t127.341-85.5Q397.681 176 480.5 176q82.819 0 155.659 31.5Q709 239 763 293t85.5 127Q880 493 880 575.734q0 82.734-31.5 155.5T763 858.5q-54 54.5-127.129 86T479.595 976Z",fill:"currentColor"})]})));function gW(e,t){return(gW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}
|
|
38
|
+
*/function UT(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var $T=Symbol.for("react.transitional.element"),GT=Symbol.for("react.portal"),VT=Symbol.for("react.fragment"),qT=Symbol.for("react.strict_mode"),WT=Symbol.for("react.profiler"),YT=Symbol.for("react.provider"),KT=Symbol.for("react.consumer"),XT=Symbol.for("react.context"),QT=Symbol.for("react.forward_ref"),ZT=Symbol.for("react.suspense"),JT=Symbol.for("react.suspense_list"),eC=Symbol.for("react.memo"),tC=Symbol.for("react.lazy"),nC=Symbol.for("react.scope"),rC=Symbol.for("react.debug_trace_mode"),aC=Symbol.for("react.offscreen"),oC=Symbol.for("react.legacy_hidden"),iC=Symbol.for("react.memo_cache_sentinel"),sC=Symbol.iterator,lC=Array.isArray;function cC(e,t){var n=3&e.length,r=e.length-n,a=t;for(t=0;t<r;){var o=255&e.charCodeAt(t)|(255&e.charCodeAt(++t))<<8|(255&e.charCodeAt(++t))<<16|(255&e.charCodeAt(++t))<<24;++t,a=27492+(65535&(a=5*(65535&(a=(a^=o=461845907*(65535&(o=(o=3432918353*(65535&o)+((3432918353*(o>>>16)&65535)<<16)&4294967295)<<15|o>>>17))+((461845907*(o>>>16)&65535)<<16)&4294967295)<<13|a>>>19))+((5*(a>>>16)&65535)<<16)&4294967295))+((58964+(a>>>16)&65535)<<16)}switch(o=0,n){case 3:o^=(255&e.charCodeAt(t+2))<<16;case 2:o^=(255&e.charCodeAt(t+1))<<8;case 1:a^=461845907*(65535&(o=(o=3432918353*(65535&(o^=255&e.charCodeAt(t)))+((3432918353*(o>>>16)&65535)<<16)&4294967295)<<15|o>>>17))+((461845907*(o>>>16)&65535)<<16)&4294967295}return a^=e.length,a=2246822507*(65535&(a^=a>>>16))+((2246822507*(a>>>16)&65535)<<16)&4294967295,((a=3266489909*(65535&(a^=a>>>13))+((3266489909*(a>>>16)&65535)<<16)&4294967295)^a>>>16)>>>0}var uC=new MessageChannel,dC=[];function pC(e){dC.push(e),uC.port2.postMessage(null)}function hC(e){setTimeout((function(){throw e}))}uC.port1.onmessage=function(){var e=dC.shift();e&&e()};var fC=Promise,mC="function"==typeof queueMicrotask?queueMicrotask:function(e){fC.resolve(null).then(e).catch(hC)},gC=null,yC=0;function bC(e,t){if(0!==t.byteLength)if(2048<t.byteLength)0<yC&&(e.enqueue(new Uint8Array(gC.buffer,0,yC)),gC=new Uint8Array(2048),yC=0),e.enqueue(t);else{var n=gC.length-yC;n<t.byteLength&&(0===n?e.enqueue(gC):(gC.set(t.subarray(0,n),yC),e.enqueue(gC),t=t.subarray(n)),gC=new Uint8Array(2048),yC=0),gC.set(t,yC),yC+=t.byteLength}}function vC(e,t){return bC(e,t),!0}function kC(e){gC&&0<yC&&(e.enqueue(new Uint8Array(gC.buffer,0,yC)),gC=null,yC=0)}var wC=new TextEncoder;function xC(e){return wC.encode(e)}function EC(e){return wC.encode(e)}function _C(e,t){"function"==typeof e.error?e.error(t):e.close()}var SC=Object.assign,TC=Object.prototype.hasOwnProperty,CC=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),AC={},NC={};function IC(e){return!!TC.call(NC,e)||!TC.call(AC,e)&&(CC.test(e)?NC[e]=!0:(AC[e]=!0,!1))}var RC=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" ")),OC=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),PC=/["'&<>]/;function DC(e){if("boolean"==typeof e||"number"==typeof e||"bigint"==typeof e)return""+e;e=""+e;var t=PC.exec(e);if(t){var n,r="",a=0;for(n=t.index;n<e.length;n++){switch(e.charCodeAt(n)){case 34:t=""";break;case 38:t="&";break;case 39:t="'";break;case 60:t="<";break;case 62:t=">";break;default:continue}a!==n&&(r+=e.slice(a,n)),a=n+1,r+=t}e=a!==n?r+e.slice(a,n):r}return e}var LC=/([A-Z])/g,MC=/^ms-/,FC=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function jC(e){return FC.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}var BC=zT.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,zC=HT.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,HC={pending:!1,data:null,method:null,action:null},UC=zC.d;zC.d={f:UC.f,r:UC.r,D:function(e){var t=GR||null;if(t){var n=t.resumableState,r=t.renderState;if("string"==typeof e&&e){var a,o;if(!n.dnsResources.hasOwnProperty(e))n.dnsResources[e]=null,(o=(n=r.headers)&&0<n.remainingCapacity)&&(a="<"+(""+e).replace(SI,TI)+">; rel=dns-prefetch",o=0<=(n.remainingCapacity-=a.length+2)),o?(r.resets.dns[e]=null,n.preconnects&&(n.preconnects+=", "),n.preconnects+=a):(LA(a=[],{href:e,rel:"dns-prefetch"}),r.preconnects.add(a));CO(t)}}else UC.D(e)},C:function(e,t){var n=GR||null;if(n){var r=n.resumableState,a=n.renderState;if("string"==typeof e&&e){var o="use-credentials"===t?"credentials":"string"==typeof t?"anonymous":"default";if(!r.connectResources[o].hasOwnProperty(e)){var i,s;if(r.connectResources[o][e]=null,s=(r=a.headers)&&0<r.remainingCapacity){if(s="<"+(""+e).replace(SI,TI)+">; rel=preconnect","string"==typeof t)s+='; crossorigin="'+(""+t).replace(CI,AI)+'"';i=s,s=0<=(r.remainingCapacity-=i.length+2)}s?(a.resets.connect[o][e]=null,r.preconnects&&(r.preconnects+=", "),r.preconnects+=i):(LA(o=[],{rel:"preconnect",href:e,crossOrigin:t}),a.preconnects.add(o))}CO(n)}}else UC.C(e,t)},L:function(e,t,n){var r=GR||null;if(r){var a=r.resumableState,o=r.renderState;if(t&&e){switch(t){case"image":if(n)var i=n.imageSrcSet,s=n.imageSizes,l=n.fetchPriority;var c,u=i?i+"\n"+(s||""):e;if(a.imageResources.hasOwnProperty(u))return;a.imageResources[u]=$C,(a=o.headers)&&0<a.remainingCapacity&&"high"===l&&(c=_I(e,t,n),0<=(a.remainingCapacity-=c.length+2))?(o.resets.image[u]=$C,a.highImagePreloads&&(a.highImagePreloads+=", "),a.highImagePreloads+=c):(LA(a=[],SC({rel:"preload",href:i?void 0:e,as:t},n)),"high"===l?o.highImagePreloads.add(a):(o.bulkPreloads.add(a),o.preloads.images.set(u,a)));break;case"style":if(a.styleResources.hasOwnProperty(e))return;LA(i=[],SC({rel:"preload",href:e,as:t},n)),a.styleResources[e]=!n||"string"!=typeof n.crossOrigin&&"string"!=typeof n.integrity?$C:[n.crossOrigin,n.integrity],o.preloads.stylesheets.set(e,i),o.bulkPreloads.add(i);break;case"script":if(a.scriptResources.hasOwnProperty(e))return;i=[],o.preloads.scripts.set(e,i),o.bulkPreloads.add(i),LA(i,SC({rel:"preload",href:e,as:t},n)),a.scriptResources[e]=!n||"string"!=typeof n.crossOrigin&&"string"!=typeof n.integrity?$C:[n.crossOrigin,n.integrity];break;default:if(a.unknownResources.hasOwnProperty(t)){if((i=a.unknownResources[t]).hasOwnProperty(e))return}else i={},a.unknownResources[t]=i;if(i[e]=$C,(a=o.headers)&&0<a.remainingCapacity&&"font"===t&&(u=_I(e,t,n),0<=(a.remainingCapacity-=u.length+2)))o.resets.font[e]=$C,a.fontPreloads&&(a.fontPreloads+=", "),a.fontPreloads+=u;else if("font"===(LA(a=[],e=SC({rel:"preload",href:e,as:t},n)),t))o.fontPreloads.add(a);else o.bulkPreloads.add(a)}CO(r)}}else UC.L(e,t,n)},m:function(e,t){var n=GR||null;if(n){var r=n.resumableState,a=n.renderState;if(e){var o=t&&"string"==typeof t.as?t.as:"script";if("script"===o){if(r.moduleScriptResources.hasOwnProperty(e))return;o=[],r.moduleScriptResources[e]=!t||"string"!=typeof t.crossOrigin&&"string"!=typeof t.integrity?$C:[t.crossOrigin,t.integrity],a.preloads.moduleScripts.set(e,o)}else{if(r.moduleUnknownResources.hasOwnProperty(o)){var i=r.unknownResources[o];if(i.hasOwnProperty(e))return}else i={},r.moduleUnknownResources[o]=i;o=[],i[e]=$C}LA(o,SC({rel:"modulepreload",href:e},t)),a.bulkPreloads.add(o),CO(n)}}else UC.m(e,t)},X:function(e,t){var n=GR||null;if(n){var r=n.resumableState,a=n.renderState;if(e){var o=r.scriptResources.hasOwnProperty(e)?r.scriptResources[e]:void 0;null!==o&&(r.scriptResources[e]=null,t=SC({src:e,async:!0},t),o&&(2===o.length&&EI(t,o),e=a.preloads.scripts.get(e))&&(e.length=0),e=[],a.scripts.add(e),zA(e,t),CO(n))}}else UC.X(e,t)},S:function(e,t,n){var r=GR||null;if(r){var a=r.resumableState,o=r.renderState;if(e){t=t||"default";var i=o.styles.get(t),s=a.styleResources.hasOwnProperty(e)?a.styleResources[e]:void 0;null!==s&&(a.styleResources[e]=null,i||(i={precedence:xC(DC(t)),rules:[],hrefs:[],sheets:new Map},o.styles.set(t,i)),t={state:0,props:SC({rel:"stylesheet",href:e,"data-precedence":t},n)},s&&(2===s.length&&EI(t.props,s),(o=o.preloads.stylesheets.get(e))&&0<o.length?o.length=0:t.state=1),i.sheets.set(e,t),CO(r))}}else UC.S(e,t,n)},M:function(e,t){var n=GR||null;if(n){var r=n.resumableState,a=n.renderState;if(e){var o=r.moduleScriptResources.hasOwnProperty(e)?r.moduleScriptResources[e]:void 0;null!==o&&(r.moduleScriptResources[e]=null,t=SC({src:e,type:"module",async:!0},t),o&&(2===o.length&&EI(t,o),e=a.preloads.moduleScripts.get(e))&&(e.length=0),e=[],a.scripts.add(e),zA(e,t),CO(n))}}else UC.M(e,t)}};var $C=[];EC('"></template>');var GC=EC("<script>"),VC=EC("<\/script>"),qC=EC('<script src="'),WC=EC('<script type="module" src="'),YC=EC('" nonce="'),KC=EC('" integrity="'),XC=EC('" crossorigin="'),QC=EC('" async=""><\/script>'),ZC=/(<\/|<)(s)(cript)/gi;function JC(e,t,n,r){return t+("s"===n?"\\u0073":"\\u0053")+r}var eA=EC('<script type="importmap">'),tA=EC("<\/script>");function nA(e,t,n,r,a,o){var i=void 0===t?GC:EC('<script nonce="'+DC(t)+'">'),s=e.idPrefix;n=[];var l=e.bootstrapScriptContent,c=e.bootstrapScripts,u=e.bootstrapModules;if(void 0!==l&&n.push(i,xC((""+l).replace(ZC,JC)),VC),l=[],void 0!==r&&(l.push(eA),l.push(xC((""+JSON.stringify(r)).replace(ZC,JC))),l.push(tA)),r=a?{preconnects:"",fontPreloads:"",highImagePreloads:"",remainingCapacity:2+("number"==typeof o?o:2e3)}:null,a={placeholderPrefix:EC(s+"P:"),segmentPrefix:EC(s+"S:"),boundaryPrefix:EC(s+"B:"),startInlineScript:i,htmlChunks:null,headChunks:null,externalRuntimeScript:null,bootstrapChunks:n,importMapChunks:l,onHeaders:a,headers:r,resets:{font:{},dns:{},connect:{default:{},anonymous:{},credentials:{}},image:{},style:{}},charsetChunks:[],viewportChunks:[],hoistableChunks:[],preconnects:new Set,fontPreloads:new Set,highImagePreloads:new Set,styles:new Map,bootstrapScripts:new Set,scripts:new Set,bulkPreloads:new Set,preloads:{images:new Map,stylesheets:new Map,scripts:new Map,moduleScripts:new Map},nonce:t,hoistableState:null,stylesToHoist:!1},void 0!==c)for(r=0;r<c.length;r++){var d=c[r];s=i=void 0,l={rel:"preload",as:"script",fetchPriority:"low",nonce:t},"string"==typeof d?l.href=o=d:(l.href=o=d.src,l.integrity=s="string"==typeof d.integrity?d.integrity:void 0,l.crossOrigin=i="string"==typeof d||null==d.crossOrigin?void 0:"use-credentials"===d.crossOrigin?"use-credentials":"");var p=o;(d=e).scriptResources[p]=null,d.moduleScriptResources[p]=null,LA(d=[],l),a.bootstrapScripts.add(d),n.push(qC,xC(DC(o))),t&&n.push(YC,xC(DC(t))),"string"==typeof s&&n.push(KC,xC(DC(s))),"string"==typeof i&&n.push(XC,xC(DC(i))),n.push(QC)}if(void 0!==u)for(c=0;c<u.length;c++)i=o=void 0,s={rel:"modulepreload",fetchPriority:"low",nonce:t},"string"==typeof(l=u[c])?s.href=r=l:(s.href=r=l.src,s.integrity=i="string"==typeof l.integrity?l.integrity:void 0,s.crossOrigin=o="string"==typeof l||null==l.crossOrigin?void 0:"use-credentials"===l.crossOrigin?"use-credentials":""),d=r,(l=e).scriptResources[d]=null,l.moduleScriptResources[d]=null,LA(l=[],s),a.bootstrapScripts.add(l),n.push(WC,xC(DC(r))),t&&n.push(YC,xC(DC(t))),"string"==typeof i&&n.push(KC,xC(DC(i))),"string"==typeof o&&n.push(XC,xC(DC(o))),n.push(QC);return a}function rA(e,t,n,r,a){return{idPrefix:void 0===e?"":e,nextFormID:0,streamingFormat:0,bootstrapScriptContent:n,bootstrapScripts:r,bootstrapModules:a,instructions:0,hasBody:!1,hasHtml:!1,unknownResources:{},dnsResources:{},connectResources:{default:{},anonymous:{},credentials:{}},imageResources:{},styleResources:{},scriptResources:{},moduleUnknownResources:{},moduleScriptResources:{}}}function aA(e,t,n){return{insertionMode:e,selectedValue:t,tagScope:n}}function oA(e){return aA("http://www.w3.org/2000/svg"===e?3:"http://www.w3.org/1998/Math/MathML"===e?4:0,null,0)}function iA(e,t,n){switch(t){case"noscript":return aA(2,null,1|e.tagScope);case"select":return aA(2,null!=n.value?n.value:n.defaultValue,e.tagScope);case"svg":return aA(3,null,e.tagScope);case"picture":return aA(2,null,2|e.tagScope);case"math":return aA(4,null,e.tagScope);case"foreignObject":return aA(2,null,e.tagScope);case"table":return aA(5,null,e.tagScope);case"thead":case"tbody":case"tfoot":return aA(6,null,e.tagScope);case"colgroup":return aA(8,null,e.tagScope);case"tr":return aA(7,null,e.tagScope)}return 5<=e.insertionMode?aA(2,null,e.tagScope):0===e.insertionMode?aA("html"===t?1:2,null,e.tagScope):1===e.insertionMode?aA(2,null,e.tagScope):e}var sA=EC("\x3c!-- --\x3e");function lA(e,t,n,r){return""===t?r:(r&&e.push(sA),e.push(xC(DC(t))),!0)}var cA=new Map,uA=EC(' style="'),dA=EC(":"),pA=EC(";");function hA(e,t){if("object"!=typeof t)throw Error(UT(62));var n,r=!0;for(n in t)if(TC.call(t,n)){var a=t[n];if(null!=a&&"boolean"!=typeof a&&""!==a){if(0===n.indexOf("--")){var o=xC(DC(n));a=xC(DC((""+a).trim()))}else void 0===(o=cA.get(n))&&(o=EC(DC(n.replace(LC,"-$1").toLowerCase().replace(MC,"-ms-"))),cA.set(n,o)),a="number"==typeof a?0===a||RC.has(n)?xC(""+a):xC(a+"px"):xC(DC((""+a).trim()));r?(r=!1,e.push(uA,o,dA,a)):e.push(pA,o,dA,a)}}r||e.push(gA)}var fA=EC(" "),mA=EC('="'),gA=EC('"'),yA=EC('=""');function bA(e,t,n){n&&"function"!=typeof n&&"symbol"!=typeof n&&e.push(fA,xC(t),yA)}function vA(e,t,n){"function"!=typeof n&&"symbol"!=typeof n&&"boolean"!=typeof n&&e.push(fA,xC(t),mA,xC(DC(n)),gA)}var kA=EC(DC("javascript:throw new Error('React form unexpectedly submitted.')")),wA=EC('<input type="hidden"');function xA(e,t){this.push(wA),EA(e),vA(this,"name",t),vA(this,"value",e),this.push(AA)}function EA(e){if("string"!=typeof e)throw Error(UT(480))}function _A(e,t){if("function"==typeof t.$$FORM_ACTION){var n=e.nextFormID++;e=e.idPrefix+n;try{var r=t.$$FORM_ACTION(e);if(r){var a=r.data;null!=a&&a.forEach(EA)}return r}catch(o){if("object"==typeof o&&null!==o&&"function"==typeof o.then)throw o}}return null}function SA(e,t,n,r,a,o,i,s){var l=null;if("function"==typeof r){var c=_A(t,r);null!==c?(s=c.name,r=c.action||"",a=c.encType,o=c.method,i=c.target,l=c.data):(e.push(fA,xC("formAction"),mA,kA,gA),i=o=a=r=s=null,OA(t,n))}return null!=s&&TA(e,"name",s),null!=r&&TA(e,"formAction",r),null!=a&&TA(e,"formEncType",a),null!=o&&TA(e,"formMethod",o),null!=i&&TA(e,"formTarget",i),l}function TA(e,t,n){switch(t){case"className":vA(e,"class",n);break;case"tabIndex":vA(e,"tabindex",n);break;case"dir":case"role":case"viewBox":case"width":case"height":vA(e,t,n);break;case"style":hA(e,n);break;case"src":case"href":if(""===n)break;case"action":case"formAction":if(null==n||"function"==typeof n||"symbol"==typeof n||"boolean"==typeof n)break;n=jC(""+n),e.push(fA,xC(t),mA,xC(DC(n)),gA);break;case"defaultValue":case"defaultChecked":case"innerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"ref":break;case"autoFocus":case"multiple":case"muted":bA(e,t.toLowerCase(),n);break;case"xlinkHref":if("function"==typeof n||"symbol"==typeof n||"boolean"==typeof n)break;n=jC(""+n),e.push(fA,xC("xlink:href"),mA,xC(DC(n)),gA);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":"function"!=typeof n&&"symbol"!=typeof n&&e.push(fA,xC(t),mA,xC(DC(n)),gA);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":n&&"function"!=typeof n&&"symbol"!=typeof n&&e.push(fA,xC(t),yA);break;case"capture":case"download":!0===n?e.push(fA,xC(t),yA):!1!==n&&"function"!=typeof n&&"symbol"!=typeof n&&e.push(fA,xC(t),mA,xC(DC(n)),gA);break;case"cols":case"rows":case"size":case"span":"function"!=typeof n&&"symbol"!=typeof n&&!isNaN(n)&&1<=n&&e.push(fA,xC(t),mA,xC(DC(n)),gA);break;case"rowSpan":case"start":"function"==typeof n||"symbol"==typeof n||isNaN(n)||e.push(fA,xC(t),mA,xC(DC(n)),gA);break;case"xlinkActuate":vA(e,"xlink:actuate",n);break;case"xlinkArcrole":vA(e,"xlink:arcrole",n);break;case"xlinkRole":vA(e,"xlink:role",n);break;case"xlinkShow":vA(e,"xlink:show",n);break;case"xlinkTitle":vA(e,"xlink:title",n);break;case"xlinkType":vA(e,"xlink:type",n);break;case"xmlBase":vA(e,"xml:base",n);break;case"xmlLang":vA(e,"xml:lang",n);break;case"xmlSpace":vA(e,"xml:space",n);break;default:if((!(2<t.length)||"o"!==t[0]&&"O"!==t[0]||"n"!==t[1]&&"N"!==t[1])&&IC(t=OC.get(t)||t)){switch(typeof n){case"function":case"symbol":return;case"boolean":var r=t.toLowerCase().slice(0,5);if("data-"!==r&&"aria-"!==r)return}e.push(fA,xC(t),mA,xC(DC(n)),gA)}}}var CA=EC(">"),AA=EC("/>");function NA(e,t,n){if(null!=t){if(null!=n)throw Error(UT(60));if("object"!=typeof t||!("__html"in t))throw Error(UT(61));null!=(t=t.__html)&&e.push(xC(""+t))}}var IA=EC(' selected=""'),RA=EC('addEventListener("submit",function(a){if(!a.defaultPrevented){var c=a.target,d=a.submitter,e=c.action,b=d;if(d){var f=d.getAttribute("formAction");null!=f&&(e=f,b=null)}"javascript:throw new Error(\'React form unexpectedly submitted.\')"===e&&(a.preventDefault(),b?(a=document.createElement("input"),a.name=b.name,a.value=b.value,b.parentNode.insertBefore(a,b),b=new FormData(c),a.parentNode.removeChild(a)):b=new FormData(c),a=c.ownerDocument||c,(a.$$reactFormReplay=a.$$reactFormReplay||[]).push(c,d,b))}});');function OA(e,t){!(16&e.instructions)&&(e.instructions|=16,t.bootstrapChunks.unshift(t.startInlineScript,RA,VC))}var PA=EC("\x3c!--F!--\x3e"),DA=EC("\x3c!--F--\x3e");function LA(e,t){for(var n in e.push(VA("link")),t)if(TC.call(t,n)){var r=t[n];if(null!=r)switch(n){case"children":case"dangerouslySetInnerHTML":throw Error(UT(399,"link"));default:TA(e,n,r)}}return e.push(AA),null}var MA=/(<\/|<)(s)(tyle)/gi;function FA(e,t,n,r){return t+("s"===n?"\\73 ":"\\53 ")+r}function jA(e,t,n){for(var r in e.push(VA(n)),t)if(TC.call(t,r)){var a=t[r];if(null!=a)switch(r){case"children":case"dangerouslySetInnerHTML":throw Error(UT(399,n));default:TA(e,r,a)}}return e.push(AA),null}function BA(e,t){e.push(VA("title"));var n,r=null,a=null;for(n in t)if(TC.call(t,n)){var o=t[n];if(null!=o)switch(n){case"children":r=o;break;case"dangerouslySetInnerHTML":a=o;break;default:TA(e,n,o)}}return e.push(CA),"function"!=typeof(t=Array.isArray(r)?2>r.length?r[0]:null:r)&&"symbol"!=typeof t&&null!=t&&e.push(xC(DC(""+t))),NA(e,a,r),e.push(KA("title")),null}function zA(e,t){e.push(VA("script"));var n,r=null,a=null;for(n in t)if(TC.call(t,n)){var o=t[n];if(null!=o)switch(n){case"children":r=o;break;case"dangerouslySetInnerHTML":a=o;break;default:TA(e,n,o)}}return e.push(CA),NA(e,a,r),"string"==typeof r&&e.push(xC((""+r).replace(ZC,JC))),e.push(KA("script")),null}function HA(e,t,n){e.push(VA(n));var r,a=n=null;for(r in t)if(TC.call(t,r)){var o=t[r];if(null!=o)switch(r){case"children":n=o;break;case"dangerouslySetInnerHTML":a=o;break;default:TA(e,r,o)}}return e.push(CA),NA(e,a,n),"string"==typeof n?(e.push(xC(DC(n))),null):n}var UA=EC("\n"),$A=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,GA=new Map;function VA(e){var t=GA.get(e);if(void 0===t){if(!$A.test(e))throw Error(UT(65,e));t=EC("<"+e),GA.set(e,t)}return t}var qA=EC("<!DOCTYPE html>");function WA(e,t,n,r,a,o,i,s,l){switch(t){case"div":case"span":case"svg":case"path":case"g":case"p":case"li":case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":break;case"a":e.push(VA("a"));var c,u=null,d=null;for(c in n)if(TC.call(n,c)){var p=n[c];if(null!=p)switch(c){case"children":u=p;break;case"dangerouslySetInnerHTML":d=p;break;case"href":""===p?vA(e,"href",""):TA(e,c,p);break;default:TA(e,c,p)}}if(e.push(CA),NA(e,d,u),"string"==typeof u){e.push(xC(DC(u)));var h=null}else h=u;return h;case"select":e.push(VA("select"));var f,m=null,g=null;for(f in n)if(TC.call(n,f)){var y=n[f];if(null!=y)switch(f){case"children":m=y;break;case"dangerouslySetInnerHTML":g=y;break;case"defaultValue":case"value":break;default:TA(e,f,y)}}return e.push(CA),NA(e,g,m),m;case"option":var b=i.selectedValue;e.push(VA("option"));var v,k=null,w=null,x=null,E=null;for(v in n)if(TC.call(n,v)){var _=n[v];if(null!=_)switch(v){case"children":k=_;break;case"selected":x=_;break;case"dangerouslySetInnerHTML":E=_;break;case"value":w=_;default:TA(e,v,_)}}if(null!=b){var S=null!==w?""+w:function(e){var t="";return zT.Children.forEach(e,(function(e){null!=e&&(t+=e)})),t}(k);if(lC(b)){for(var T=0;T<b.length;T++)if(""+b[T]===S){e.push(IA);break}}else""+b===S&&e.push(IA)}else x&&e.push(IA);return e.push(CA),NA(e,E,k),k;case"textarea":e.push(VA("textarea"));var C,A=null,N=null,I=null;for(C in n)if(TC.call(n,C)){var R=n[C];if(null!=R)switch(C){case"children":I=R;break;case"value":A=R;break;case"defaultValue":N=R;break;case"dangerouslySetInnerHTML":throw Error(UT(91));default:TA(e,C,R)}}if(null===A&&null!==N&&(A=N),e.push(CA),null!=I){if(null!=A)throw Error(UT(92));if(lC(I)){if(1<I.length)throw Error(UT(93));A=""+I[0]}A=""+I}return"string"==typeof A&&"\n"===A[0]&&e.push(UA),null!==A&&e.push(xC(DC(""+A))),null;case"input":e.push(VA("input"));var O,P=null,D=null,L=null,M=null,F=null,j=null,B=null,z=null,H=null;for(O in n)if(TC.call(n,O)){var U=n[O];if(null!=U)switch(O){case"children":case"dangerouslySetInnerHTML":throw Error(UT(399,"input"));case"name":P=U;break;case"formAction":D=U;break;case"formEncType":L=U;break;case"formMethod":M=U;break;case"formTarget":F=U;break;case"defaultChecked":H=U;break;case"defaultValue":B=U;break;case"checked":z=U;break;case"value":j=U;break;default:TA(e,O,U)}}var $=SA(e,r,a,D,L,M,F,P);return null!==z?bA(e,"checked",z):null!==H&&bA(e,"checked",H),null!==j?TA(e,"value",j):null!==B&&TA(e,"value",B),e.push(AA),null!=$&&$.forEach(xA,e),null;case"button":e.push(VA("button"));var G,V=null,q=null,W=null,Y=null,K=null,X=null,Q=null;for(G in n)if(TC.call(n,G)){var Z=n[G];if(null!=Z)switch(G){case"children":V=Z;break;case"dangerouslySetInnerHTML":q=Z;break;case"name":W=Z;break;case"formAction":Y=Z;break;case"formEncType":K=Z;break;case"formMethod":X=Z;break;case"formTarget":Q=Z;break;default:TA(e,G,Z)}}var J=SA(e,r,a,Y,K,X,Q,W);if(e.push(CA),null!=J&&J.forEach(xA,e),NA(e,q,V),"string"==typeof V){e.push(xC(DC(V)));var ee=null}else ee=V;return ee;case"form":e.push(VA("form"));var te,ne=null,re=null,ae=null,oe=null,ie=null,se=null;for(te in n)if(TC.call(n,te)){var le=n[te];if(null!=le)switch(te){case"children":ne=le;break;case"dangerouslySetInnerHTML":re=le;break;case"action":ae=le;break;case"encType":oe=le;break;case"method":ie=le;break;case"target":se=le;break;default:TA(e,te,le)}}var ce=null,ue=null;if("function"==typeof ae){var de=_A(r,ae);null!==de?(ae=de.action||"",oe=de.encType,ie=de.method,se=de.target,ce=de.data,ue=de.name):(e.push(fA,xC("action"),mA,kA,gA),se=ie=oe=ae=null,OA(r,a))}if(null!=ae&&TA(e,"action",ae),null!=oe&&TA(e,"encType",oe),null!=ie&&TA(e,"method",ie),null!=se&&TA(e,"target",se),e.push(CA),null!==ue&&(e.push(wA),vA(e,"name",ue),e.push(AA),null!=ce&&ce.forEach(xA,e)),NA(e,re,ne),"string"==typeof ne){e.push(xC(DC(ne)));var pe=null}else pe=ne;return pe;case"menuitem":for(var he in e.push(VA("menuitem")),n)if(TC.call(n,he)){var fe=n[he];if(null!=fe)switch(he){case"children":case"dangerouslySetInnerHTML":throw Error(UT(400));default:TA(e,he,fe)}}return e.push(CA),null;case"object":e.push(VA("object"));var me,ge=null,ye=null;for(me in n)if(TC.call(n,me)){var be=n[me];if(null!=be)switch(me){case"children":ge=be;break;case"dangerouslySetInnerHTML":ye=be;break;case"data":var ve=jC(""+be);if(""===ve)break;e.push(fA,xC("data"),mA,xC(DC(ve)),gA);break;default:TA(e,me,be)}}if(e.push(CA),NA(e,ye,ge),"string"==typeof ge){e.push(xC(DC(ge)));var ke=null}else ke=ge;return ke;case"title":if(3===i.insertionMode||1&i.tagScope||null!=n.itemProp)var we=BA(e,n);else l?we=null:(BA(a.hoistableChunks,n),we=void 0);return we;case"link":var xe=n.rel,Ee=n.href,_e=n.precedence;if(3===i.insertionMode||1&i.tagScope||null!=n.itemProp||"string"!=typeof xe||"string"!=typeof Ee||""===Ee){LA(e,n);var Se=null}else if("stylesheet"===n.rel)if("string"!=typeof _e||null!=n.disabled||n.onLoad||n.onError)Se=LA(e,n);else{var Te=a.styles.get(_e),Ce=r.styleResources.hasOwnProperty(Ee)?r.styleResources[Ee]:void 0;if(null!==Ce){r.styleResources[Ee]=null,Te||(Te={precedence:xC(DC(_e)),rules:[],hrefs:[],sheets:new Map},a.styles.set(_e,Te));var Ae={state:0,props:SC({},n,{"data-precedence":n.precedence,precedence:null})};if(Ce){2===Ce.length&&EI(Ae.props,Ce);var Ne=a.preloads.stylesheets.get(Ee);Ne&&0<Ne.length?Ne.length=0:Ae.state=1}Te.sheets.set(Ee,Ae),o&&o.stylesheets.add(Ae)}else if(Te){var Ie=Te.sheets.get(Ee);Ie&&o&&o.stylesheets.add(Ie)}s&&e.push(sA),Se=null}else n.onLoad||n.onError?Se=LA(e,n):(s&&e.push(sA),Se=l?null:LA(a.hoistableChunks,n));return Se;case"script":var Re=n.async;if("string"!=typeof n.src||!n.src||!Re||"function"==typeof Re||"symbol"==typeof Re||n.onLoad||n.onError||3===i.insertionMode||1&i.tagScope||null!=n.itemProp)var Oe=zA(e,n);else{var Pe=n.src;if("module"===n.type)var De=r.moduleScriptResources,Le=a.preloads.moduleScripts;else De=r.scriptResources,Le=a.preloads.scripts;var Me=De.hasOwnProperty(Pe)?De[Pe]:void 0;if(null!==Me){De[Pe]=null;var Fe=n;if(Me){2===Me.length&&EI(Fe=SC({},n),Me);var je=Le.get(Pe);je&&(je.length=0)}var Be=[];a.scripts.add(Be),zA(Be,Fe)}s&&e.push(sA),Oe=null}return Oe;case"style":var ze=n.precedence,He=n.href;if(3===i.insertionMode||1&i.tagScope||null!=n.itemProp||"string"!=typeof ze||"string"!=typeof He||""===He){e.push(VA("style"));var Ue,$e=null,Ge=null;for(Ue in n)if(TC.call(n,Ue)){var Ve=n[Ue];if(null!=Ve)switch(Ue){case"children":$e=Ve;break;case"dangerouslySetInnerHTML":Ge=Ve;break;default:TA(e,Ue,Ve)}}e.push(CA);var qe=Array.isArray($e)?2>$e.length?$e[0]:null:$e;"function"!=typeof qe&&"symbol"!=typeof qe&&null!=qe&&e.push(xC((""+qe).replace(MA,FA))),NA(e,Ge,$e),e.push(KA("style"));var We=null}else{var Ye=a.styles.get(ze);if(null!==(r.styleResources.hasOwnProperty(He)?r.styleResources[He]:void 0)){r.styleResources[He]=null,Ye?Ye.hrefs.push(xC(DC(He))):(Ye={precedence:xC(DC(ze)),rules:[],hrefs:[xC(DC(He))],sheets:new Map},a.styles.set(ze,Ye));var Ke,Xe=Ye.rules,Qe=null,Ze=null;for(Ke in n)if(TC.call(n,Ke)){var Je=n[Ke];if(null!=Je)switch(Ke){case"children":Qe=Je;break;case"dangerouslySetInnerHTML":Ze=Je}}var et=Array.isArray(Qe)?2>Qe.length?Qe[0]:null:Qe;"function"!=typeof et&&"symbol"!=typeof et&&null!=et&&Xe.push(xC((""+et).replace(MA,FA))),NA(Xe,Ze,Qe)}Ye&&o&&o.styles.add(Ye),s&&e.push(sA),We=void 0}return We;case"meta":if(3===i.insertionMode||1&i.tagScope||null!=n.itemProp)var tt=jA(e,n,"meta");else s&&e.push(sA),tt=l?null:"string"==typeof n.charSet?jA(a.charsetChunks,n,"meta"):"viewport"===n.name?jA(a.viewportChunks,n,"meta"):jA(a.hoistableChunks,n,"meta");return tt;case"listing":case"pre":e.push(VA(t));var nt,rt=null,at=null;for(nt in n)if(TC.call(n,nt)){var ot=n[nt];if(null!=ot)switch(nt){case"children":rt=ot;break;case"dangerouslySetInnerHTML":at=ot;break;default:TA(e,nt,ot)}}if(e.push(CA),null!=at){if(null!=rt)throw Error(UT(60));if("object"!=typeof at||!("__html"in at))throw Error(UT(61));var it=at.__html;null!=it&&("string"==typeof it&&0<it.length&&"\n"===it[0]?e.push(UA,xC(it)):e.push(xC(""+it)))}return"string"==typeof rt&&"\n"===rt[0]&&e.push(UA),rt;case"img":var st=n.src,lt=n.srcSet;if(!("lazy"===n.loading||!st&&!lt||"string"!=typeof st&&null!=st||"string"!=typeof lt&&null!=lt)&&"low"!==n.fetchPriority&&!1==!!(3&i.tagScope)&&("string"!=typeof st||":"!==st[4]||"d"!==st[0]&&"D"!==st[0]||"a"!==st[1]&&"A"!==st[1]||"t"!==st[2]&&"T"!==st[2]||"a"!==st[3]&&"A"!==st[3])&&("string"!=typeof lt||":"!==lt[4]||"d"!==lt[0]&&"D"!==lt[0]||"a"!==lt[1]&&"A"!==lt[1]||"t"!==lt[2]&&"T"!==lt[2]||"a"!==lt[3]&&"A"!==lt[3])){var ct="string"==typeof n.sizes?n.sizes:void 0,ut=lt?lt+"\n"+(ct||""):st,dt=a.preloads.images,pt=dt.get(ut);if(pt)("high"===n.fetchPriority||10>a.highImagePreloads.size)&&(dt.delete(ut),a.highImagePreloads.add(pt));else if(!r.imageResources.hasOwnProperty(ut)){r.imageResources[ut]=$C;var ht,ft=n.crossOrigin,mt="string"==typeof ft?"use-credentials"===ft?ft:"":void 0,gt=a.headers;gt&&0<gt.remainingCapacity&&("high"===n.fetchPriority||500>gt.highImagePreloads.length)&&(ht=_I(st,"image",{imageSrcSet:n.srcSet,imageSizes:n.sizes,crossOrigin:mt,integrity:n.integrity,nonce:n.nonce,type:n.type,fetchPriority:n.fetchPriority,referrerPolicy:n.refererPolicy}),0<=(gt.remainingCapacity-=ht.length+2))?(a.resets.image[ut]=$C,gt.highImagePreloads&&(gt.highImagePreloads+=", "),gt.highImagePreloads+=ht):(LA(pt=[],{rel:"preload",as:"image",href:lt?void 0:st,imageSrcSet:lt,imageSizes:ct,crossOrigin:mt,integrity:n.integrity,type:n.type,fetchPriority:n.fetchPriority,referrerPolicy:n.referrerPolicy}),"high"===n.fetchPriority||10>a.highImagePreloads.size?a.highImagePreloads.add(pt):(a.bulkPreloads.add(pt),dt.set(ut,pt)))}}return jA(e,n,"img");case"base":case"area":case"br":case"col":case"embed":case"hr":case"keygen":case"param":case"source":case"track":case"wbr":return jA(e,n,t);case"head":if(2>i.insertionMode&&null===a.headChunks){a.headChunks=[];var yt=HA(a.headChunks,n,"head")}else yt=HA(e,n,"head");return yt;case"html":if(0===i.insertionMode&&null===a.htmlChunks){a.htmlChunks=[qA];var bt=HA(a.htmlChunks,n,"html")}else bt=HA(e,n,"html");return bt;default:if(-1!==t.indexOf("-")){e.push(VA(t));var vt,kt=null,wt=null;for(vt in n)if(TC.call(n,vt)){var xt=n[vt];if(null!=xt){var Et=vt;switch(vt){case"children":kt=xt;break;case"dangerouslySetInnerHTML":wt=xt;break;case"style":hA(e,xt);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"ref":break;case"className":Et="class";default:if(IC(vt)&&"function"!=typeof xt&&"symbol"!=typeof xt&&!1!==xt){if(!0===xt)xt="";else if("object"==typeof xt)continue;e.push(fA,xC(Et),mA,xC(DC(xt)),gA)}}}}return e.push(CA),NA(e,wt,kt),kt}}return HA(e,n,t)}var YA=new Map;function KA(e){var t=YA.get(e);return void 0===t&&(t=EC("</"+e+">"),YA.set(e,t)),t}function XA(e,t){t=t.bootstrapChunks;for(var n=0;n<t.length-1;n++)bC(e,t[n]);return!(n<t.length)||(n=t[n],t.length=0,vC(e,n))}var QA=EC('<template id="'),ZA=EC('"></template>'),JA=EC("\x3c!--$--\x3e"),eN=EC('\x3c!--$?--\x3e<template id="'),tN=EC('"></template>'),nN=EC("\x3c!--$!--\x3e"),rN=EC("\x3c!--/$--\x3e"),aN=EC("<template"),oN=EC('"'),iN=EC(' data-dgst="');EC(' data-msg="'),EC(' data-stck="'),EC(' data-cstck="');var sN=EC("></template>");function lN(e,t,n){if(bC(e,eN),null===n)throw Error(UT(395));return bC(e,t.boundaryPrefix),bC(e,xC(n.toString(16))),vC(e,tN)}var cN=EC('<div hidden id="'),uN=EC('">'),dN=EC("</div>"),pN=EC('<svg aria-hidden="true" style="display:none" id="'),hN=EC('">'),fN=EC("</svg>"),mN=EC('<math aria-hidden="true" style="display:none" id="'),gN=EC('">'),yN=EC("</math>"),bN=EC('<table hidden id="'),vN=EC('">'),kN=EC("</table>"),wN=EC('<table hidden><tbody id="'),xN=EC('">'),EN=EC("</tbody></table>"),_N=EC('<table hidden><tr id="'),SN=EC('">'),TN=EC("</tr></table>"),CN=EC('<table hidden><colgroup id="'),AN=EC('">'),NN=EC("</colgroup></table>");var IN=EC('$RS=function(a,b){a=document.getElementById(a);b=document.getElementById(b);for(a.parentNode.removeChild(a);a.firstChild;)b.parentNode.insertBefore(a.firstChild,b);b.parentNode.removeChild(b)};$RS("'),RN=EC('$RS("'),ON=EC('","'),PN=EC('")<\/script>');EC('<template data-rsi="" data-sid="'),EC('" data-pid="');var DN=EC('$RC=function(b,c,e){c=document.getElementById(c);c.parentNode.removeChild(c);var a=document.getElementById(b);if(a){b=a.previousSibling;if(e)b.data="$!",a.setAttribute("data-dgst",e);else{e=b.parentNode;a=b.nextSibling;var f=0;do{if(a&&8===a.nodeType){var d=a.data;if("/$"===d)if(0===f)break;else f--;else"$"!==d&&"$?"!==d&&"$!"!==d||f++}d=a.nextSibling;e.removeChild(a);a=d}while(a);for(;c.firstChild;)e.insertBefore(c.firstChild,a);b.data="$"}b._reactRetry&&b._reactRetry()}};$RC("'),LN=EC('$RC("'),MN=EC('$RC=function(b,c,e){c=document.getElementById(c);c.parentNode.removeChild(c);var a=document.getElementById(b);if(a){b=a.previousSibling;if(e)b.data="$!",a.setAttribute("data-dgst",e);else{e=b.parentNode;a=b.nextSibling;var f=0;do{if(a&&8===a.nodeType){var d=a.data;if("/$"===d)if(0===f)break;else f--;else"$"!==d&&"$?"!==d&&"$!"!==d||f++}d=a.nextSibling;e.removeChild(a);a=d}while(a);for(;c.firstChild;)e.insertBefore(c.firstChild,a);b.data="$"}b._reactRetry&&b._reactRetry()}};$RM=new Map;\n$RR=function(t,u,y){function v(n){this._p=null;n()}for(var w=$RC,p=$RM,q=new Map,r=document,g,b,h=r.querySelectorAll("link[data-precedence],style[data-precedence]"),x=[],k=0;b=h[k++];)"not all"===b.getAttribute("media")?x.push(b):("LINK"===b.tagName&&p.set(b.getAttribute("href"),b),q.set(b.dataset.precedence,g=b));b=0;h=[];var l,a;for(k=!0;;){if(k){var e=y[b++];if(!e){k=!1;b=0;continue}var c=!1,m=0;var d=e[m++];if(a=p.get(d)){var f=a._p;c=!0}else{a=r.createElement("link");a.href=\nd;a.rel="stylesheet";for(a.dataset.precedence=l=e[m++];f=e[m++];)a.setAttribute(f,e[m++]);f=a._p=new Promise(function(n,z){a.onload=v.bind(a,n);a.onerror=v.bind(a,z)});p.set(d,a)}d=a.getAttribute("media");!f||d&&!matchMedia(d).matches||h.push(f);if(c)continue}else{a=x[b++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=q.get(l)||g;c===g&&(g=a);q.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=r.head,c.insertBefore(a,c.firstChild))}Promise.all(h).then(w.bind(null,\nt,u,""),w.bind(null,t,u,"Resource failed to load"))};$RR("'),FN=EC('$RM=new Map;\n$RR=function(t,u,y){function v(n){this._p=null;n()}for(var w=$RC,p=$RM,q=new Map,r=document,g,b,h=r.querySelectorAll("link[data-precedence],style[data-precedence]"),x=[],k=0;b=h[k++];)"not all"===b.getAttribute("media")?x.push(b):("LINK"===b.tagName&&p.set(b.getAttribute("href"),b),q.set(b.dataset.precedence,g=b));b=0;h=[];var l,a;for(k=!0;;){if(k){var e=y[b++];if(!e){k=!1;b=0;continue}var c=!1,m=0;var d=e[m++];if(a=p.get(d)){var f=a._p;c=!0}else{a=r.createElement("link");a.href=\nd;a.rel="stylesheet";for(a.dataset.precedence=l=e[m++];f=e[m++];)a.setAttribute(f,e[m++]);f=a._p=new Promise(function(n,z){a.onload=v.bind(a,n);a.onerror=v.bind(a,z)});p.set(d,a)}d=a.getAttribute("media");!f||d&&!matchMedia(d).matches||h.push(f);if(c)continue}else{a=x[b++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=q.get(l)||g;c===g&&(g=a);q.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=r.head,c.insertBefore(a,c.firstChild))}Promise.all(h).then(w.bind(null,\nt,u,""),w.bind(null,t,u,"Resource failed to load"))};$RR("'),jN=EC('$RR("'),BN=EC('","'),zN=EC('",'),HN=EC('"'),UN=EC(")<\/script>");EC('<template data-rci="" data-bid="'),EC('<template data-rri="" data-bid="'),EC('" data-sid="'),EC('" data-sty="');var $N=EC('$RX=function(b,c,d,e,f){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),f&&(a.cstck=f),b._reactRetry&&b._reactRetry())};;$RX("'),GN=EC('$RX("'),VN=EC('"'),qN=EC(","),WN=EC(")<\/script>");EC('<template data-rxi="" data-bid="'),EC('" data-dgst="'),EC('" data-msg="'),EC('" data-stck="'),EC('" data-cstck="');var YN=/[<\u2028\u2029]/g;var KN=/[&><\u2028\u2029]/g;function XN(e){return JSON.stringify(e).replace(KN,(function(e){switch(e){case"&":return"\\u0026";case">":return"\\u003e";case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSObjectForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}))}var QN=EC('<style media="not all" data-precedence="'),ZN=EC('" data-href="'),JN=EC('">'),eI=EC("</style>"),tI=!1,nI=!0;function rI(e){var t=e.rules,n=e.hrefs,r=0;if(n.length){for(bC(this,QN),bC(this,e.precedence),bC(this,ZN);r<n.length-1;r++)bC(this,n[r]),bC(this,dI);for(bC(this,n[r]),bC(this,JN),r=0;r<t.length;r++)bC(this,t[r]);nI=vC(this,eI),tI=!0,t.length=0,n.length=0}}function aI(e){return 2!==e.state&&(tI=!0)}function oI(e,t,n){return tI=!1,nI=!0,t.styles.forEach(rI,e),t.stylesheets.forEach(aI),tI&&(n.stylesToHoist=!0),nI}function iI(e){for(var t=0;t<e.length;t++)bC(this,e[t]);e.length=0}var sI=[];function lI(e){LA(sI,e.props);for(var t=0;t<sI.length;t++)bC(this,sI[t]);sI.length=0,e.state=2}var cI=EC('<style data-precedence="'),uI=EC('" data-href="'),dI=EC(" "),pI=EC('">'),hI=EC("</style>");function fI(e){var t=0<e.sheets.size;e.sheets.forEach(lI,this),e.sheets.clear();var n=e.rules,r=e.hrefs;if(!t||r.length){if(bC(this,cI),bC(this,e.precedence),e=0,r.length){for(bC(this,uI);e<r.length-1;e++)bC(this,r[e]),bC(this,dI);bC(this,r[e])}for(bC(this,pI),e=0;e<n.length;e++)bC(this,n[e]);bC(this,hI),n.length=0,r.length=0}}function mI(e){if(0===e.state){e.state=1;var t=e.props;for(LA(sI,{rel:"preload",as:"style",href:e.props.href,crossOrigin:t.crossOrigin,fetchPriority:t.fetchPriority,integrity:t.integrity,media:t.media,hrefLang:t.hrefLang,referrerPolicy:t.referrerPolicy}),e=0;e<sI.length;e++)bC(this,sI[e]);sI.length=0}}function gI(e){e.sheets.forEach(mI,this),e.sheets.clear()}var yI=EC("["),bI=EC(",["),vI=EC(","),kI=EC("]");function wI(e,t,n){var r=t.toLowerCase();switch(typeof n){case"function":case"symbol":return}switch(t){case"innerHTML":case"dangerouslySetInnerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"style":case"ref":return;case"className":r="class",t=""+n;break;case"hidden":if(!1===n)return;t="";break;case"src":case"href":t=""+(n=jC(n));break;default:if(2<t.length&&("o"===t[0]||"O"===t[0])&&("n"===t[1]||"N"===t[1])||!IC(t))return;t=""+n}bC(e,vI),bC(e,xC(XN(r))),bC(e,vI),bC(e,xC(XN(t)))}function xI(){return{styles:new Set,stylesheets:new Set}}function EI(e,t){null==e.crossOrigin&&(e.crossOrigin=t[0]),null==e.integrity&&(e.integrity=t[1])}function _I(e,t,n){for(var r in t="<"+(e=(""+e).replace(SI,TI))+'>; rel=preload; as="'+(t=(""+t).replace(CI,AI))+'"',n)TC.call(n,r)&&("string"==typeof(e=n[r])&&(t+="; "+r.toLowerCase()+'="'+(""+e).replace(CI,AI)+'"'));return t}var SI=/[<>\r\n]/g;function TI(e){switch(e){case"<":return"%3C";case">":return"%3E";case"\n":return"%0A";case"\r":return"%0D";default:throw Error("escapeLinkHrefForHeaderContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}var CI=/["';,\r\n]/g;function AI(e){switch(e){case'"':return"%22";case"'":return"%27";case";":return"%3B";case",":return"%2C";case"\n":return"%0A";case"\r":return"%0D";default:throw Error("escapeStringForLinkHeaderQuotedParamValueContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}function NI(e){this.styles.add(e)}function II(e){this.stylesheets.add(e)}var RI=Function.prototype.bind,OI=Symbol.for("react.client.reference");function PI(e){if(null==e)return null;if("function"==typeof e)return e.$$typeof===OI?null:e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case VT:return"Fragment";case GT:return"Portal";case WT:return"Profiler";case qT:return"StrictMode";case ZT:return"Suspense";case JT:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case XT:return(e.displayName||"Context")+".Provider";case KT:return(e._context.displayName||"Context")+".Consumer";case QT:var t=e.render;return(e=e.displayName)||(e=""!==(e=t.displayName||t.name||"")?"ForwardRef("+e+")":"ForwardRef"),e;case eC:return null!==(t=e.displayName||null)?t:PI(e.type)||"Memo";case tC:t=e._payload,e=e._init;try{return PI(e(t))}catch(n){}}return null}var DI={},LI=null;function MI(e,t){if(e!==t){e.context._currentValue=e.parentValue,e=e.parent;var n=t.parent;if(null===e){if(null!==n)throw Error(UT(401))}else{if(null===n)throw Error(UT(401));MI(e,n)}t.context._currentValue=t.value}}function FI(e){e.context._currentValue=e.parentValue,null!==(e=e.parent)&&FI(e)}function jI(e){var t=e.parent;null!==t&&jI(t),e.context._currentValue=e.value}function BI(e,t){if(e.context._currentValue=e.parentValue,null===(e=e.parent))throw Error(UT(402));e.depth===t.depth?MI(e,t):BI(e,t)}function zI(e,t){var n=t.parent;if(null===n)throw Error(UT(402));e.depth===n.depth?MI(e,n):zI(e,n),t.context._currentValue=t.value}function HI(e){var t=LI;t!==e&&(null===t?jI(e):null===e?FI(t):t.depth===e.depth?MI(t,e):t.depth>e.depth?BI(t,e):zI(t,e),LI=e)}var UI={isMounted:function(){return!1},enqueueSetState:function(e,t){null!==(e=e._reactInternals).queue&&e.queue.push(t)},enqueueReplaceState:function(e,t){(e=e._reactInternals).replace=!0,e.queue=[t]},enqueueForceUpdate:function(){}},$I={id:1,overflow:""};function GI(e,t,n){var r=e.id;e=e.overflow;var a=32-VI(r)-1;r&=~(1<<a),n+=1;var o=32-VI(t)+a;if(30<o){var i=a-a%5;return o=(r&(1<<i)-1).toString(32),r>>=i,a-=i,{id:1<<32-VI(t)+a|n<<a|r,overflow:o+e}}return{id:1<<o|n<<a|r,overflow:e}}var VI=Math.clz32?Math.clz32:function(e){return 0===(e>>>=0)?32:31-(qI(e)/WI|0)|0},qI=Math.log,WI=Math.LN2;var YI=Error(UT(460));function KI(){}var XI=null;function QI(){if(null===XI)throw Error(UT(459));var e=XI;return XI=null,e}var ZI="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},JI=null,eR=null,tR=null,nR=null,rR=null,aR=null,oR=!1,iR=!1,sR=0,lR=0,cR=-1,uR=0,dR=null,pR=null,hR=0;function fR(){if(null===JI)throw Error(UT(321));return JI}function mR(){if(0<hR)throw Error(UT(312));return{memoizedState:null,queue:null,next:null}}function gR(){return null===aR?null===rR?(oR=!1,rR=aR=mR()):(oR=!0,aR=rR):null===aR.next?(oR=!1,aR=aR.next=mR()):(oR=!0,aR=aR.next),aR}function yR(){var e=dR;return dR=null,e}function bR(){nR=tR=eR=JI=null,iR=!1,rR=null,hR=0,aR=pR=null}function vR(e,t){return"function"==typeof t?t(e):t}function kR(e,t,n){if(JI=fR(),aR=gR(),oR){var r=aR.queue;if(t=r.dispatch,null!==pR&&void 0!==(n=pR.get(r))){pR.delete(r),r=aR.memoizedState;do{r=e(r,n.action),n=n.next}while(null!==n);return aR.memoizedState=r,[r,t]}return[aR.memoizedState,t]}return e=e===vR?"function"==typeof t?t():t:void 0!==n?n(t):t,aR.memoizedState=e,e=(e=aR.queue={last:null,dispatch:null}).dispatch=xR.bind(null,JI,e),[aR.memoizedState,e]}function wR(e,t){if(JI=fR(),t=void 0===t?null:t,null!==(aR=gR())){var n=aR.memoizedState;if(null!==n&&null!==t){var r=n[1];e:if(null===r)r=!1;else{for(var a=0;a<r.length&&a<t.length;a++)if(!ZI(t[a],r[a])){r=!1;break e}r=!0}if(r)return n[0]}}return e=e(),aR.memoizedState=[e,t],e}function xR(e,t,n){if(25<=hR)throw Error(UT(301));if(e===JI)if(iR=!0,e={action:n,next:null},null===pR&&(pR=new Map),void 0===(n=pR.get(t)))pR.set(t,e);else{for(t=n;null!==t.next;)t=t.next;t.next=e}}function ER(){throw Error(UT(394))}function _R(){throw Error(UT(479))}function SR(e,t,n){fR();var r=lR++,a=tR;if("function"==typeof e.$$FORM_ACTION){var o=null,i=nR;a=a.formState;var s=e.$$IS_SIGNATURE_EQUAL;if(null!==a&&"function"==typeof s){var l=a[1];s.call(e,a[2],a[3])&&(l===(o=void 0!==n?"p"+n:"k"+cC(JSON.stringify([i,null,r]),0))&&(cR=r,t=a[0]))}var c=e.bind(null,t);return e=function(e){c(e)},"function"==typeof c.$$FORM_ACTION&&(e.$$FORM_ACTION=function(e){e=c.$$FORM_ACTION(e),void 0!==n&&(n+="",e.action=n);var t=e.data;return t&&(null===o&&(o=void 0!==n?"p"+n:"k"+cC(JSON.stringify([i,null,r]),0)),t.append("$ACTION_KEY",o)),e}),[t,e,!1]}var u=e.bind(null,t);return[t,function(e){u(e)},!1]}function TR(e){var t=uR;return uR+=1,null===dR&&(dR=[]),function(e,t,n){switch(void 0===(n=e[n])?e.push(t):n!==t&&(t.then(KI,KI),t=n),t.status){case"fulfilled":return t.value;case"rejected":throw t.reason;default:switch("string"==typeof t.status?t.then(KI,KI):((e=t).status="pending",e.then((function(e){if("pending"===t.status){var n=t;n.status="fulfilled",n.value=e}}),(function(e){if("pending"===t.status){var n=t;n.status="rejected",n.reason=e}}))),t.status){case"fulfilled":return t.value;case"rejected":throw t.reason}throw XI=t,YI}}(dR,e,t)}function CR(){throw Error(UT(393))}function AR(){}var NR={readContext:function(e){return e._currentValue},use:function(e){if(null!==e&&"object"==typeof e){if("function"==typeof e.then)return TR(e);if(e.$$typeof===XT)return e._currentValue}throw Error(UT(438,String(e)))},useContext:function(e){return fR(),e._currentValue},useMemo:wR,useReducer:kR,useRef:function(e){JI=fR();var t=(aR=gR()).memoizedState;return null===t?(e={current:e},aR.memoizedState=e):t},useState:function(e){return kR(vR,e)},useInsertionEffect:AR,useLayoutEffect:AR,useCallback:function(e,t){return wR((function(){return e}),t)},useImperativeHandle:AR,useEffect:AR,useDebugValue:AR,useDeferredValue:function(e,t){return fR(),void 0!==t?t:e},useTransition:function(){return fR(),[!1,ER]},useId:function(){var e=eR.treeContext,t=e.overflow;e=((e=e.id)&~(1<<32-VI(e)-1)).toString(32)+t;var n=OR;if(null===n)throw Error(UT(404));return t=sR++,e=":"+n.idPrefix+"R"+e,0<t&&(e+="H"+t.toString(32)),e+":"},useSyncExternalStore:function(e,t,n){if(void 0===n)throw Error(UT(407));return n()},useCacheRefresh:function(){return CR},useMemoCache:function(e){for(var t=Array(e),n=0;n<e;n++)t[n]=iC;return t},useHostTransitionStatus:function(){return fR(),HC},useOptimistic:function(e){return fR(),[e,_R]}};NR.useFormState=SR,NR.useActionState=SR;var IR,RR,OR=null,PR={getCacheForType:function(){throw Error(UT(248))}};function DR(e){if(void 0===IR)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);IR=t&&t[1]||"",RR=-1<n.stack.indexOf("\n at")?" (<anonymous>)":-1<n.stack.indexOf("@")?"@unknown:0:0":""}return"\n"+IR+e+RR}var LR=!1;function MR(e,t){if(!e||LR)return"";LR=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(n,[])}catch(a){var r=a}Reflect.construct(e,[],n)}else{try{n.call()}catch(o){r=o}e.call(n.prototype)}}else{try{throw Error()}catch(i){r=i}(n=e())&&"function"==typeof n.catch&&n.catch((function(){}))}}catch(s){if(s&&r&&"string"==typeof s.stack)return[s.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var a=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,"name");a&&a.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var o=r.DetermineComponentFrameRoot(),i=o[0],s=o[1];if(i&&s){var l=i.split("\n"),c=s.split("\n");for(a=r=0;r<l.length&&!l[r].includes("DetermineComponentFrameRoot");)r++;for(;a<c.length&&!c[a].includes("DetermineComponentFrameRoot");)a++;if(r===l.length||a===c.length)for(r=l.length-1,a=c.length-1;1<=r&&0<=a&&l[r]!==c[a];)a--;for(;1<=r&&0<=a;r--,a--)if(l[r]!==c[a]){if(1!==r||1!==a)do{if(r--,0>--a||l[r]!==c[a]){var u="\n"+l[r].replace(" at new "," at ");return e.displayName&&u.includes("<anonymous>")&&(u=u.replace("<anonymous>",e.displayName)),u}}while(1<=r&&0<=a);break}}}finally{LR=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:"")?DR(n):""}function FR(e){if("string"==typeof e)return DR(e);if("function"==typeof e)return e.prototype&&e.prototype.isReactComponent?e=MR(e,!0):MR(e,!1);if("object"==typeof e&&null!==e){switch(e.$$typeof){case QT:return MR(e.render,!1);case eC:return MR(e.type,!1);case tC:var t=e,n=t._payload;t=t._init;try{e=t(n)}catch(r){return DR("Lazy")}return FR(e)}if("string"==typeof e.name)return n=e.env,DR(e.name+(n?" ["+n+"]":""))}switch(e){case JT:return DR("SuspenseList");case ZT:return DR("Suspense")}return""}function jR(e){if("object"==typeof e&&null!==e&&"string"==typeof e.environmentName){var t=e.environmentName;"string"==typeof(e=[e].slice(0))[0]?e.splice(0,1,"%c%s%c "+e[0],"background: #e6e6e6;background: light-dark(rgba(0,0,0,0.1), rgba(255,255,255,0.25));color: #000000;color: light-dark(#000000, #ffffff);border-radius: 2px"," "+t+" ",""):e.splice(0,0,"%c%s%c ","background: #e6e6e6;background: light-dark(rgba(0,0,0,0.1), rgba(255,255,255,0.25));color: #000000;color: light-dark(#000000, #ffffff);border-radius: 2px"," "+t+" ",""),e.unshift(console),(t=RI.apply(console.error,e))()}else console.error(e);return null}function BR(){}function zR(e,t,n,r,a,o,i,s,l,c,u){var d=new Set;this.destination=null,this.flushScheduled=!1,this.resumableState=e,this.renderState=t,this.rootFormatContext=n,this.progressiveChunkSize=void 0===r?12800:r,this.status=10,this.fatalError=null,this.pendingRootTasks=this.allPendingTasks=this.nextSegmentId=0,this.completedRootSegment=null,this.abortableTasks=d,this.pingedTasks=[],this.clientRenderedBoundaries=[],this.completedBoundaries=[],this.partialBoundaries=[],this.trackedPostpones=null,this.onError=void 0===a?jR:a,this.onPostpone=void 0===c?BR:c,this.onAllReady=void 0===o?BR:o,this.onShellReady=void 0===i?BR:i,this.onShellError=void 0===s?BR:s,this.onFatalError=void 0===l?BR:l,this.formState=void 0===u?null:u}function HR(e,t,n,r,a,o,i,s,l,c,u,d){return(n=KR(t=new zR(t,n,r,a,o,i,s,l,c,u,d),0,null,r,!1,!1)).parentFlushed=!0,XR(e=WR(t,null,e,-1,null,n,null,t.abortableTasks,null,r,null,$I,null,!1)),t.pingedTasks.push(e),t}var UR,$R,GR=null;function VR(e,t){e.pingedTasks.push(t),1===e.pingedTasks.length&&(e.flushScheduled=null!==e.destination,null!==e.trackedPostpones||10===e.status?mC((function(){return vO(e)})):pC((function(){return vO(e)})))}function qR(e,t){return{status:0,rootSegmentID:-1,parentFlushed:!1,pendingTasks:0,completedSegments:[],byteSize:0,fallbackAbortableTasks:t,errorDigest:null,contentState:xI(),fallbackState:xI(),trackedContentKeyPath:null,trackedFallbackNode:null}}function WR(e,t,n,r,a,o,i,s,l,c,u,d,p,h){e.allPendingTasks++,null===a?e.pendingRootTasks++:a.pendingTasks++;var f={replay:null,node:n,childIndex:r,ping:function(){return VR(e,f)},blockedBoundary:a,blockedSegment:o,hoistableState:i,abortSet:s,keyPath:l,formatContext:c,context:u,treeContext:d,componentStack:p,thenableState:t,isFallback:h};return s.add(f),f}function YR(e,t,n,r,a,o,i,s,l,c,u,d,p,h){e.allPendingTasks++,null===o?e.pendingRootTasks++:o.pendingTasks++,n.pendingTasks++;var f={replay:n,node:r,childIndex:a,ping:function(){return VR(e,f)},blockedBoundary:o,blockedSegment:null,hoistableState:i,abortSet:s,keyPath:l,formatContext:c,context:u,treeContext:d,componentStack:p,thenableState:t,isFallback:h};return s.add(f),f}function KR(e,t,n,r,a,o){return{status:0,id:-1,index:t,parentFlushed:!1,chunks:[],children:[],parentFormatContext:r,boundary:n,lastPushedText:a,textEmbedded:o}}function XR(e){var t=e.node;if("object"==typeof t&&null!==t&&t.$$typeof===$T)e.componentStack={parent:e.componentStack,type:t.type}}function QR(e){var t={};return e&&Object.defineProperty(t,"componentStack",{configurable:!0,enumerable:!0,get:function(){try{var n="",r=e;do{n+=FR(r.type),r=r.parent}while(r);var a=n}catch(o){a="\nError generating stack: "+o.message+"\n"+o.stack}return Object.defineProperty(t,"componentStack",{value:a}),a}}),t}function ZR(e,t,n){if(null==(t=(e=e.onError)(t,n))||"string"==typeof t)return t}function JR(e,t){var n=e.onShellError,r=e.onFatalError;n(t),r(t),null!==e.destination?(e.status=14,_C(e.destination,t)):(e.status=13,e.fatalError=t)}function eO(e,t,n,r,a,o){var i=t.thenableState;for(t.thenableState=null,JI={},eR=t,tR=e,nR=n,lR=sR=0,cR=-1,uR=0,dR=i,e=r(a,o);iR;)iR=!1,lR=sR=0,cR=-1,uR=0,hR+=1,aR=null,e=r(a,o);return bR(),e}function tO(e,t,n,r,a,o,i){var s=!1;if(0!==o&&null!==e.formState){var l=t.blockedSegment;if(null!==l){s=!0,l=l.chunks;for(var c=0;c<o;c++)c===i?l.push(PA):l.push(DA)}}o=t.keyPath,t.keyPath=n,a?(n=t.treeContext,t.treeContext=GI(n,1,0),uO(e,t,r,-1),t.treeContext=n):s?uO(e,t,r,-1):aO(e,t,r,-1),t.keyPath=o}function nO(e,t,n,r,a,o){if("function"==typeof r)if(r.prototype&&r.prototype.isReactComponent){var i=a;if("ref"in a)for(var s in i={},a)"ref"!==s&&(i[s]=a[s]);var l=r.defaultProps;if(l)for(var c in i===a&&(i=SC({},i,a)),l)void 0===i[c]&&(i[c]=l[c]);a=i,i=DI,"object"==typeof(l=r.contextType)&&null!==l&&(i=l._currentValue);var u=void 0!==(i=new r(a,i)).state?i.state:null;if(i.updater=UI,i.props=a,i.state=u,l={queue:[],replace:!1},i._reactInternals=l,o=r.contextType,i.context="object"==typeof o&&null!==o?o._currentValue:DI,"function"==typeof(o=r.getDerivedStateFromProps)&&(u=null==(o=o(a,u))?u:SC({},u,o),i.state=u),"function"!=typeof r.getDerivedStateFromProps&&"function"!=typeof i.getSnapshotBeforeUpdate&&("function"==typeof i.UNSAFE_componentWillMount||"function"==typeof i.componentWillMount))if(r=i.state,"function"==typeof i.componentWillMount&&i.componentWillMount(),"function"==typeof i.UNSAFE_componentWillMount&&i.UNSAFE_componentWillMount(),r!==i.state&&UI.enqueueReplaceState(i,i.state,null),null!==l.queue&&0<l.queue.length)if(r=l.queue,o=l.replace,l.queue=null,l.replace=!1,o&&1===r.length)i.state=r[0];else{for(l=o?r[0]:i.state,u=!0,o=o?1:0;o<r.length;o++)null!=(c="function"==typeof(c=r[o])?c.call(i,l,a,void 0):c)&&(u?(u=!1,l=SC({},l,c)):SC(l,c));i.state=l}else l.queue=null;if(r=i.render(),12===e.status)throw null;a=t.keyPath,t.keyPath=n,aO(e,t,r,-1),t.keyPath=a}else{if(r=eO(e,t,n,r,a,void 0),12===e.status)throw null;tO(e,t,n,r,0!==sR,lR,cR)}else{if("string"!=typeof r){switch(r){case oC:case rC:case qT:case WT:case VT:return r=t.keyPath,t.keyPath=n,aO(e,t,a.children,-1),void(t.keyPath=r);case aC:return void("hidden"!==a.mode&&(r=t.keyPath,t.keyPath=n,aO(e,t,a.children,-1),t.keyPath=r));case JT:return r=t.keyPath,t.keyPath=n,aO(e,t,a.children,-1),void(t.keyPath=r);case nC:throw Error(UT(343));case ZT:e:if(null!==t.replay){r=t.keyPath,t.keyPath=n,n=a.children;try{uO(e,t,n,-1)}finally{t.keyPath=r}}else{r=t.keyPath;var d=t.blockedBoundary,p=t.hoistableState;o=t.blockedSegment,c=a.fallback,a=a.children;var h=new Set;s=qR(0,h),null!==e.trackedPostpones&&(s.trackedContentKeyPath=n);var f=KR(0,o.chunks.length,s,t.formatContext,!1,!1);o.children.push(f),o.lastPushedText=!1;var m=KR(0,0,null,t.formatContext,!1,!1);if(m.parentFlushed=!0,null!==e.trackedPostpones){l=[(i=[n[0],"Suspense Fallback",n[2]])[1],i[2],[],null],e.trackedPostpones.workingMap.set(i,l),s.trackedFallbackNode=l,t.blockedSegment=f,t.keyPath=i,f.status=6;try{uO(e,t,c,-1),f.lastPushedText&&f.textEmbedded&&f.chunks.push(sA),f.status=1}catch(g){throw f.status=12===e.status?3:4,g}finally{t.blockedSegment=o,t.keyPath=r}XR(t=WR(e,null,a,-1,s,m,s.contentState,t.abortSet,n,t.formatContext,t.context,t.treeContext,t.componentStack,t.isFallback)),e.pingedTasks.push(t)}else{t.blockedBoundary=s,t.hoistableState=s.contentState,t.blockedSegment=m,t.keyPath=n,m.status=6;try{if(uO(e,t,a,-1),m.lastPushedText&&m.textEmbedded&&m.chunks.push(sA),m.status=1,yO(s,m),0===s.pendingTasks&&0===s.status){s.status=1;break e}}catch(y){s.status=4,12===e.status?(m.status=3,i=e.fatalError):(m.status=4,i=y),u=ZR(e,i,l=QR(t.componentStack)),s.errorDigest=u,sO(e,s)}finally{t.blockedBoundary=d,t.hoistableState=p,t.blockedSegment=o,t.keyPath=r}XR(t=WR(e,null,c,-1,d,f,s.fallbackState,h,[n[0],"Suspense Fallback",n[2]],t.formatContext,t.context,t.treeContext,t.componentStack,!0)),e.pingedTasks.push(t)}}return}if("object"==typeof r&&null!==r)switch(r.$$typeof){case QT:if("ref"in a)for(f in i={},a)"ref"!==f&&(i[f]=a[f]);else i=a;return void tO(e,t,n,r=eO(e,t,n,r.render,i,o),0!==sR,lR,cR);case eC:return void nO(e,t,n,r.type,a,o);case YT:case XT:if(l=a.children,i=t.keyPath,a=a.value,u=r._currentValue,r._currentValue=a,LI=r={parent:o=LI,depth:null===o?0:o.depth+1,context:r,parentValue:u,value:a},t.context=r,t.keyPath=n,aO(e,t,l,-1),null===(e=LI))throw Error(UT(403));return e.context._currentValue=e.parentValue,e=LI=e.parent,t.context=e,void(t.keyPath=i);case KT:return r=(a=a.children)(r._context._currentValue),a=t.keyPath,t.keyPath=n,aO(e,t,r,-1),void(t.keyPath=a);case tC:if(r=(i=r._init)(r._payload),12===e.status)throw null;return void nO(e,t,n,r,a,o)}throw Error(UT(130,null==r?r:typeof r,""))}if(null===(i=t.blockedSegment))i=a.children,l=t.formatContext,u=t.keyPath,t.formatContext=iA(l,r,a),t.keyPath=n,uO(e,t,i,-1),t.formatContext=l,t.keyPath=u;else{u=WA(i.chunks,r,a,e.resumableState,e.renderState,t.hoistableState,t.formatContext,i.lastPushedText,t.isFallback),i.lastPushedText=!1,l=t.formatContext,o=t.keyPath,t.formatContext=iA(l,r,a),t.keyPath=n,uO(e,t,u,-1),t.formatContext=l,t.keyPath=o;e:{switch(t=i.chunks,e=e.resumableState,r){case"title":case"style":case"script":case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"input":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":break e;case"body":if(1>=l.insertionMode){e.hasBody=!0;break e}break;case"html":if(0===l.insertionMode){e.hasHtml=!0;break e}}t.push(KA(r))}i.lastPushedText=!1}}}function rO(e,t,n,r,a){var o=t.replay,i=t.blockedBoundary,s=KR(0,0,null,t.formatContext,!1,!1);s.id=n,s.parentFlushed=!0;try{t.replay=null,t.blockedSegment=s,uO(e,t,r,a),s.status=1,null===i?e.completedRootSegment=s:(yO(i,s),i.parentFlushed&&e.partialBoundaries.push(i))}finally{t.replay=o,t.blockedSegment=null}}function aO(e,t,n,r){null!==t.replay&&"number"==typeof t.replay.slots?rO(e,t,t.replay.slots,n,r):(t.node=n,t.childIndex=r,n=t.componentStack,XR(t),oO(e,t),t.componentStack=n)}function oO(e,t){var n=t.node,r=t.childIndex;if(null!==n){if("object"==typeof n){switch(n.$$typeof){case $T:var a=n.type,o=n.key,i=n.props,s=void 0!==(n=i.ref)?n:null,l=PI(a),c=null==o?-1===r?0:r:o;if(o=[t.keyPath,l,c],null!==t.replay)e:{var u=t.replay;for(r=u.nodes,n=0;n<r.length;n++){var d=r[n];if(c===d[1]){if(4===d.length){if(null!==l&&l!==d[0])throw Error(UT(490,d[0],l));var p=d[2];l=d[3],c=t.node,t.replay={nodes:p,slots:l,pendingTasks:1};try{if(nO(e,t,o,a,i,s),1===t.replay.pendingTasks&&0<t.replay.nodes.length)throw Error(UT(488));t.replay.pendingTasks--}catch(k){if("object"==typeof k&&null!==k&&(k===YI||"function"==typeof k.then))throw t.node===c&&(t.replay=u),k;t.replay.pendingTasks--,i=QR(t.componentStack),pO(e,o=t.blockedBoundary,p,l,a=k,i=ZR(e,a,i))}t.replay=u}else{if(a!==ZT)throw Error(UT(490,"Suspense",PI(a)||"Unknown"));t:{u=void 0,a=d[5],s=d[2],l=d[3],c=null===d[4]?[]:d[4][2],d=null===d[4]?null:d[4][3];var h=t.keyPath,f=t.replay,m=t.blockedBoundary,g=t.hoistableState,y=i.children;i=i.fallback;var b=new Set,v=qR(0,b);v.parentFlushed=!0,v.rootSegmentID=a,t.blockedBoundary=v,t.hoistableState=v.contentState,t.keyPath=o,t.replay={nodes:s,slots:l,pendingTasks:1};try{if(uO(e,t,y,-1),1===t.replay.pendingTasks&&0<t.replay.nodes.length)throw Error(UT(488));if(t.replay.pendingTasks--,0===v.pendingTasks&&0===v.status){v.status=1,e.completedBoundaries.push(v);break t}}catch(w){v.status=4,u=ZR(e,w,p=QR(t.componentStack)),v.errorDigest=u,t.replay.pendingTasks--,e.clientRenderedBoundaries.push(v)}finally{t.blockedBoundary=m,t.hoistableState=g,t.replay=f,t.keyPath=h}XR(t=YR(e,null,{nodes:c,slots:d,pendingTasks:0},i,-1,m,v.fallbackState,b,[o[0],"Suspense Fallback",o[2]],t.formatContext,t.context,t.treeContext,t.componentStack,!0)),e.pingedTasks.push(t)}}r.splice(n,1);break e}}}else nO(e,t,o,a,i,s);return;case GT:throw Error(UT(257));case tC:if(n=(p=n._init)(n._payload),12===e.status)throw null;return void aO(e,t,n,r)}if(lC(n))return void iO(e,t,n,r);if(null===n||"object"!=typeof n?p=null:p="function"==typeof(p=sC&&n[sC]||n["@@iterator"])?p:null,p&&(p=p.call(n))){if(!(n=p.next()).done){i=[];do{i.push(n.value),n=p.next()}while(!n.done);iO(e,t,i,r)}return}if("function"==typeof n.then)return t.thenableState=null,aO(e,t,TR(n),r);if(n.$$typeof===XT)return aO(e,t,n._currentValue,r);throw r=Object.prototype.toString.call(n),Error(UT(31,"[object Object]"===r?"object with keys {"+Object.keys(n).join(", ")+"}":r))}"string"==typeof n?null!==(r=t.blockedSegment)&&(r.lastPushedText=lA(r.chunks,n,e.renderState,r.lastPushedText)):"number"!=typeof n&&"bigint"!=typeof n||null!==(r=t.blockedSegment)&&(r.lastPushedText=lA(r.chunks,""+n,e.renderState,r.lastPushedText))}}function iO(e,t,n,r){var a=t.keyPath;if(-1===r||(t.keyPath=[t.keyPath,"Fragment",r],null===t.replay)){if(o=t.treeContext,i=n.length,null!==t.replay&&(null!==(s=t.replay.slots)&&"object"==typeof s)){for(r=0;r<i;r++)l=n[r],t.treeContext=GI(o,i,r),"number"==typeof(c=s[r])?(rO(e,t,c,l,r),delete s[r]):uO(e,t,l,r);return t.treeContext=o,void(t.keyPath=a)}for(s=0;s<i;s++)r=n[s],t.treeContext=GI(o,i,s),uO(e,t,r,s);t.treeContext=o,t.keyPath=a}else{for(var o=t.replay,i=o.nodes,s=0;s<i.length;s++){var l=i[s];if(l[1]===r){r=l[2],l=l[3],t.replay={nodes:r,slots:l,pendingTasks:1};try{if(iO(e,t,n,-1),1===t.replay.pendingTasks&&0<t.replay.nodes.length)throw Error(UT(488));t.replay.pendingTasks--}catch(u){if("object"==typeof u&&null!==u&&(u===YI||"function"==typeof u.then))throw u;t.replay.pendingTasks--,n=QR(t.componentStack);var c=t.blockedBoundary;pO(e,c,r,l,u,n=ZR(e,u,n))}t.replay=o,i.splice(s,1);break}}t.keyPath=a}}function sO(e,t){null!==(e=e.trackedPostpones)&&(null!==(t=t.trackedContentKeyPath)&&(void 0!==(t=e.workingMap.get(t))&&(t.length=4,t[2]=[],t[3]=null)))}function lO(e,t,n){return YR(e,n,t.replay,t.node,t.childIndex,t.blockedBoundary,t.hoistableState,t.abortSet,t.keyPath,t.formatContext,t.context,t.treeContext,t.componentStack,t.isFallback)}function cO(e,t,n){var r=t.blockedSegment,a=KR(0,r.chunks.length,null,t.formatContext,r.lastPushedText,!0);return r.children.push(a),r.lastPushedText=!1,WR(e,n,t.node,t.childIndex,t.blockedBoundary,a,t.hoistableState,t.abortSet,t.keyPath,t.formatContext,t.context,t.treeContext,t.componentStack,t.isFallback)}function uO(e,t,n,r){var a=t.formatContext,o=t.context,i=t.keyPath,s=t.treeContext,l=t.componentStack,c=t.blockedSegment;if(null===c)try{return aO(e,t,n,r)}catch(p){if(bR(),"object"==typeof(n=p===YI?QI():p)&&null!==n){if("function"==typeof n.then)return e=lO(e,t,r=yR()).ping,n.then(e,e),t.formatContext=a,t.context=o,t.keyPath=i,t.treeContext=s,t.componentStack=l,void HI(o);if("Maximum call stack size exceeded"===n.message)return n=lO(e,t,n=yR()),e.pingedTasks.push(n),t.formatContext=a,t.context=o,t.keyPath=i,t.treeContext=s,t.componentStack=l,void HI(o)}}else{var u=c.children.length,d=c.chunks.length;try{return aO(e,t,n,r)}catch(h){if(bR(),c.children.length=u,c.chunks.length=d,"object"==typeof(n=h===YI?QI():h)&&null!==n){if("function"==typeof n.then)return e=cO(e,t,r=yR()).ping,n.then(e,e),t.formatContext=a,t.context=o,t.keyPath=i,t.treeContext=s,t.componentStack=l,void HI(o);if("Maximum call stack size exceeded"===n.message)return n=cO(e,t,n=yR()),e.pingedTasks.push(n),t.formatContext=a,t.context=o,t.keyPath=i,t.treeContext=s,t.componentStack=l,void HI(o)}}}throw t.formatContext=a,t.context=o,t.keyPath=i,t.treeContext=s,HI(o),n}function dO(e){var t=e.blockedBoundary;null!==(e=e.blockedSegment)&&(e.status=3,bO(this,t,e))}function pO(e,t,n,r,a,o){for(var i=0;i<n.length;i++){var s=n[i];if(4===s.length)pO(e,t,s[2],s[3],a,o);else{s=s[5];var l=e,c=o,u=qR(0,new Set);u.parentFlushed=!0,u.rootSegmentID=s,u.status=4,u.errorDigest=c,u.parentFlushed&&l.clientRenderedBoundaries.push(u)}}if(n.length=0,null!==r){if(null===t)throw Error(UT(487));if(4!==t.status&&(t.status=4,t.errorDigest=o,t.parentFlushed&&e.clientRenderedBoundaries.push(t)),"object"==typeof r)for(var d in r)delete r[d]}}function hO(e,t,n){var r=e.blockedBoundary,a=e.blockedSegment;if(null!==a){if(6===a.status)return;a.status=3}if(a=QR(e.componentStack),null===r){if(13!==t.status&&14!==t.status){if(null===(r=e.replay))return ZR(t,n,a),void JR(t,n);r.pendingTasks--,0===r.pendingTasks&&0<r.nodes.length&&(e=ZR(t,n,a),pO(t,null,r.nodes,r.slots,n,e)),t.pendingRootTasks--,0===t.pendingRootTasks&&mO(t)}}else r.pendingTasks--,4!==r.status&&(r.status=4,e=ZR(t,n,a),r.status=4,r.errorDigest=e,sO(t,r),r.parentFlushed&&t.clientRenderedBoundaries.push(r)),r.fallbackAbortableTasks.forEach((function(e){return hO(e,t,n)})),r.fallbackAbortableTasks.clear();t.allPendingTasks--,0===t.allPendingTasks&&gO(t)}function fO(e,t){try{var n=e.renderState,r=n.onHeaders;if(r){var a=n.headers;if(a){n.headers=null;var o=a.preconnects;if(a.fontPreloads&&(o&&(o+=", "),o+=a.fontPreloads),a.highImagePreloads&&(o&&(o+=", "),o+=a.highImagePreloads),!t){var i=n.styles.values(),s=i.next();e:for(;0<a.remainingCapacity&&!s.done;s=i.next())for(var l=s.value.sheets.values(),c=l.next();0<a.remainingCapacity&&!c.done;c=l.next()){var u=c.value,d=u.props,p=d.href,h=u.props,f=_I(h.href,"style",{crossOrigin:h.crossOrigin,integrity:h.integrity,nonce:h.nonce,type:h.type,fetchPriority:h.fetchPriority,referrerPolicy:h.referrerPolicy,media:h.media});if(!(0<=(a.remainingCapacity-=f.length+2)))break e;n.resets.style[p]=$C,o&&(o+=", "),o+=f,n.resets.style[p]="string"==typeof d.crossOrigin||"string"==typeof d.integrity?[d.crossOrigin,d.integrity]:$C}}r(o?{Link:o}:{})}}}catch(m){ZR(e,m,{})}}function mO(e){null===e.trackedPostpones&&fO(e,!0),e.onShellError=BR,(e=e.onShellReady)()}function gO(e){fO(e,null===e.trackedPostpones||(null===e.completedRootSegment||5!==e.completedRootSegment.status)),(e=e.onAllReady)()}function yO(e,t){if(0===t.chunks.length&&1===t.children.length&&null===t.children[0].boundary&&-1===t.children[0].id){var n=t.children[0];n.id=t.id,n.parentFlushed=!0,1===n.status&&yO(e,n)}else e.completedSegments.push(t)}function bO(e,t,n){if(null===t){if(null!==n&&n.parentFlushed){if(null!==e.completedRootSegment)throw Error(UT(389));e.completedRootSegment=n}e.pendingRootTasks--,0===e.pendingRootTasks&&mO(e)}else t.pendingTasks--,4!==t.status&&(0===t.pendingTasks?(0===t.status&&(t.status=1),null!==n&&n.parentFlushed&&1===n.status&&yO(t,n),t.parentFlushed&&e.completedBoundaries.push(t),1===t.status&&(t.fallbackAbortableTasks.forEach(dO,e),t.fallbackAbortableTasks.clear())):null!==n&&n.parentFlushed&&1===n.status&&(yO(t,n),1===t.completedSegments.length&&t.parentFlushed&&e.partialBoundaries.push(t)));e.allPendingTasks--,0===e.allPendingTasks&&gO(e)}function vO(e){if(14!==e.status&&13!==e.status){var t=LI,n=BC.H;BC.H=NR;var r=BC.A;BC.A=PR;var a=GR;GR=e;var o=OR;OR=e.resumableState;try{var i,s=e.pingedTasks;for(i=0;i<s.length;i++){var l=s[i],c=e,u=l.blockedSegment;if(null===u){var d=c;if(0!==l.replay.pendingTasks){HI(l.context);try{if("number"==typeof l.replay.slots?rO(d,l,l.replay.slots,l.node,l.childIndex):oO(d,l),1===l.replay.pendingTasks&&0<l.replay.nodes.length)throw Error(UT(488));l.replay.pendingTasks--,l.abortSet.delete(l),bO(d,l.blockedBoundary,null)}catch(_){bR();var p=_===YI?QI():_;if("object"==typeof p&&null!==p&&"function"==typeof p.then){var h=l.ping;p.then(h,h),l.thenableState=yR()}else{l.replay.pendingTasks--,l.abortSet.delete(l);var f=QR(l.componentStack);c=void 0;var m=d,g=l.blockedBoundary,y=12===d.status?d.fatalError:p;pO(m,g,l.replay.nodes,l.replay.slots,y,c=ZR(m,y,f)),d.pendingRootTasks--,0===d.pendingRootTasks&&mO(d),d.allPendingTasks--,0===d.allPendingTasks&&gO(d)}}}}else if(d=void 0,0===(m=u).status){m.status=6,HI(l.context);var b=m.children.length,v=m.chunks.length;try{oO(c,l),m.lastPushedText&&m.textEmbedded&&m.chunks.push(sA),l.abortSet.delete(l),m.status=1,bO(c,l.blockedBoundary,m)}catch(_){bR(),m.children.length=b,m.chunks.length=v;var k=_===YI?QI():12===c.status?c.fatalError:_;if("object"==typeof k&&null!==k&&"function"==typeof k.then){m.status=0,l.thenableState=yR();var w=l.ping;k.then(w,w)}else{var x=QR(l.componentStack);l.abortSet.delete(l),m.status=4;var E=l.blockedBoundary;d=ZR(c,k,x),null===E?JR(c,k):(E.pendingTasks--,4!==E.status&&(E.status=4,E.errorDigest=d,sO(c,E),E.parentFlushed&&c.clientRenderedBoundaries.push(E))),c.allPendingTasks--,0===c.allPendingTasks&&gO(c)}}}}s.splice(0,i),null!==e.destination&&SO(e,e.destination)}catch(S){ZR(e,S,{}),JR(e,S)}finally{OR=o,BC.H=n,BC.A=r,n===NR&&HI(t),GR=a}}}function kO(e,t,n,r){switch(n.parentFlushed=!0,n.status){case 0:n.id=e.nextSegmentId++;case 5:return r=n.id,n.lastPushedText=!1,n.textEmbedded=!1,e=e.renderState,bC(t,QA),bC(t,e.placeholderPrefix),bC(t,e=xC(r.toString(16))),vC(t,ZA);case 1:n.status=2;var a=!0,o=n.chunks,i=0;n=n.children;for(var s=0;s<n.length;s++){for(a=n[s];i<a.index;i++)bC(t,o[i]);a=wO(e,t,a,r)}for(;i<o.length-1;i++)bC(t,o[i]);return i<o.length&&(a=vC(t,o[i])),a;default:throw Error(UT(390))}}function wO(e,t,n,r){var a=n.boundary;if(null===a)return kO(e,t,n,r);if(a.parentFlushed=!0,4===a.status)a=a.errorDigest,vC(t,nN),bC(t,aN),a&&(bC(t,iN),bC(t,xC(DC(a))),bC(t,oN)),vC(t,sN),kO(e,t,n,r);else if(1!==a.status)0===a.status&&(a.rootSegmentID=e.nextSegmentId++),0<a.completedSegments.length&&e.partialBoundaries.push(a),lN(t,e.renderState,a.rootSegmentID),r&&((a=a.fallbackState).styles.forEach(NI,r),a.stylesheets.forEach(II,r)),kO(e,t,n,r);else if(a.byteSize>e.progressiveChunkSize)a.rootSegmentID=e.nextSegmentId++,e.completedBoundaries.push(a),lN(t,e.renderState,a.rootSegmentID),kO(e,t,n,r);else{if(r&&((n=a.contentState).styles.forEach(NI,r),n.stylesheets.forEach(II,r)),vC(t,JA),1!==(n=a.completedSegments).length)throw Error(UT(391));wO(e,t,n[0],r)}return vC(t,rN)}function xO(e,t,n,r){return function(e,t,n,r){switch(n.insertionMode){case 0:case 1:case 2:return bC(e,cN),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,uN);case 3:return bC(e,pN),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,hN);case 4:return bC(e,mN),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,gN);case 5:return bC(e,bN),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,vN);case 6:return bC(e,wN),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,xN);case 7:return bC(e,_N),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,SN);case 8:return bC(e,CN),bC(e,t.segmentPrefix),bC(e,xC(r.toString(16))),vC(e,AN);default:throw Error(UT(397))}}(t,e.renderState,n.parentFormatContext,n.id),wO(e,t,n,r),function(e,t){switch(t.insertionMode){case 0:case 1:case 2:return vC(e,dN);case 3:return vC(e,fN);case 4:return vC(e,yN);case 5:return vC(e,kN);case 6:return vC(e,EN);case 7:return vC(e,TN);case 8:return vC(e,NN);default:throw Error(UT(397))}}(t,n.parentFormatContext)}function EO(e,t,n){for(var r=n.completedSegments,a=0;a<r.length;a++)_O(e,t,n,r[a]);r.length=0,oI(t,n.contentState,e.renderState),r=e.resumableState,e=e.renderState,a=n.rootSegmentID,n=n.contentState;var o=e.stylesToHoist;return e.stylesToHoist=!1,bC(t,e.startInlineScript),o?2&r.instructions?8&r.instructions?bC(t,jN):(r.instructions|=8,bC(t,FN)):(r.instructions|=10,bC(t,MN)):2&r.instructions?bC(t,LN):(r.instructions|=2,bC(t,DN)),r=xC(a.toString(16)),bC(t,e.boundaryPrefix),bC(t,r),bC(t,BN),bC(t,e.segmentPrefix),bC(t,r),o?(bC(t,zN),function(e,t){bC(e,yI);var n=yI;t.stylesheets.forEach((function(t){if(2!==t.state)if(3===t.state)bC(e,n),bC(e,xC(XN(""+t.props.href))),bC(e,kI),n=bI;else{bC(e,n);var r=t.props["data-precedence"],a=t.props,o=jC(""+t.props.href);for(var i in bC(e,xC(XN(o))),r=""+r,bC(e,vI),bC(e,xC(XN(r))),a)if(TC.call(a,i)&&null!=(r=a[i]))switch(i){case"href":case"rel":case"precedence":case"data-precedence":break;case"children":case"dangerouslySetInnerHTML":throw Error(UT(399,"link"));default:wI(e,i,r)}bC(e,kI),n=bI,t.state=3}})),bC(e,kI)}(t,n)):bC(t,HN),n=vC(t,UN),XA(t,e)&&n}function _O(e,t,n,r){if(2===r.status)return!0;var a=n.contentState,o=r.id;if(-1===o){if(-1===(r.id=n.rootSegmentID))throw Error(UT(392));return xO(e,t,r,a)}return o===n.rootSegmentID?xO(e,t,r,a):(xO(e,t,r,a),n=e.resumableState,bC(t,(e=e.renderState).startInlineScript),1&n.instructions?bC(t,RN):(n.instructions|=1,bC(t,IN)),bC(t,e.segmentPrefix),bC(t,o=xC(o.toString(16))),bC(t,ON),bC(t,e.placeholderPrefix),bC(t,o),t=vC(t,PN))}function SO(e,t){gC=new Uint8Array(2048),yC=0;try{if(!(0<e.pendingRootTasks)){var n,r=e.completedRootSegment;if(null!==r){if(5===r.status)return;var a,o=e.renderState,i=o.htmlChunks,s=o.headChunks;if(i){for(a=0;a<i.length;a++)bC(t,i[a]);if(s)for(a=0;a<s.length;a++)bC(t,s[a]);else bC(t,VA("head")),bC(t,CA)}else if(s)for(a=0;a<s.length;a++)bC(t,s[a]);var l=o.charsetChunks;for(a=0;a<l.length;a++)bC(t,l[a]);l.length=0,o.preconnects.forEach(iI,t),o.preconnects.clear();var c=o.viewportChunks;for(a=0;a<c.length;a++)bC(t,c[a]);c.length=0,o.fontPreloads.forEach(iI,t),o.fontPreloads.clear(),o.highImagePreloads.forEach(iI,t),o.highImagePreloads.clear(),o.styles.forEach(fI,t);var u=o.importMapChunks;for(a=0;a<u.length;a++)bC(t,u[a]);u.length=0,o.bootstrapScripts.forEach(iI,t),o.scripts.forEach(iI,t),o.scripts.clear(),o.bulkPreloads.forEach(iI,t),o.bulkPreloads.clear();var d=o.hoistableChunks;for(a=0;a<d.length;a++)bC(t,d[a]);d.length=0,i&&null===s&&bC(t,KA("head")),wO(e,t,r,null),e.completedRootSegment=null,XA(t,e.renderState)}var p=e.renderState;r=0;var h=p.viewportChunks;for(r=0;r<h.length;r++)bC(t,h[r]);h.length=0,p.preconnects.forEach(iI,t),p.preconnects.clear(),p.fontPreloads.forEach(iI,t),p.fontPreloads.clear(),p.highImagePreloads.forEach(iI,t),p.highImagePreloads.clear(),p.styles.forEach(gI,t),p.scripts.forEach(iI,t),p.scripts.clear(),p.bulkPreloads.forEach(iI,t),p.bulkPreloads.clear();var f=p.hoistableChunks;for(r=0;r<f.length;r++)bC(t,f[r]);f.length=0;var m=e.clientRenderedBoundaries;for(n=0;n<m.length;n++){var g=m[n];p=t;var y=e.resumableState,b=e.renderState,v=g.rootSegmentID,k=g.errorDigest;bC(p,b.startInlineScript),4&y.instructions?bC(p,GN):(y.instructions|=4,bC(p,$N)),bC(p,b.boundaryPrefix),bC(p,xC(v.toString(16))),bC(p,VN),k&&(bC(p,qN),bC(p,xC((A=k||"",JSON.stringify(A).replace(YN,(function(e){switch(e){case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSStringsForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}))))));var w=vC(p,WN);if(!w)return e.destination=null,n++,void m.splice(0,n)}m.splice(0,n);var x=e.completedBoundaries;for(n=0;n<x.length;n++)if(!EO(e,t,x[n]))return e.destination=null,n++,void x.splice(0,n);x.splice(0,n),kC(t),gC=new Uint8Array(2048),yC=0;var E=e.partialBoundaries;for(n=0;n<E.length;n++){var _=E[n];e:{m=e,g=t;var S=_.completedSegments;for(w=0;w<S.length;w++)if(!_O(m,g,_,S[w])){w++,S.splice(0,w);var T=!1;break e}S.splice(0,w),T=oI(g,_.contentState,m.renderState)}if(!T)return e.destination=null,n++,void E.splice(0,n)}E.splice(0,n);var C=e.completedBoundaries;for(n=0;n<C.length;n++)if(!EO(e,t,C[n]))return e.destination=null,n++,void C.splice(0,n);C.splice(0,n)}}finally{0===e.allPendingTasks&&0===e.pingedTasks.length&&0===e.clientRenderedBoundaries.length&&0===e.completedBoundaries.length?(e.flushScheduled=!1,(n=e.resumableState).hasBody&&bC(t,KA("body")),n.hasHtml&&bC(t,KA("html")),kC(t),e.status=14,t.close(),e.destination=null):kC(t)}var A}function TO(e){e.flushScheduled=null!==e.destination,mC((function(){return vO(e)})),pC((function(){10===e.status&&(e.status=11),null===e.trackedPostpones&&fO(e,0===e.pendingRootTasks)}))}function CO(e){!1===e.flushScheduled&&0===e.pingedTasks.length&&null!==e.destination&&(e.flushScheduled=!0,pC((function(){var t=e.destination;t?SO(e,t):e.flushScheduled=!1})))}function AO(e,t){if(13===e.status)e.status=14,_C(t,e.fatalError);else if(14!==e.status&&null===e.destination){e.destination=t;try{SO(e,t)}catch(n){ZR(e,n,{}),JR(e,n)}}}function NO(e,t){11!==e.status&&10!==e.status||(e.status=12);try{var n=e.abortableTasks;if(0<n.size){var r=void 0===t?Error(UT(432)):"object"==typeof t&&null!==t&&"function"==typeof t.then?Error(UT(530)):t;e.fatalError=r,n.forEach((function(t){return hO(t,e,r)})),n.clear()}null!==e.destination&&SO(e,e.destination)}catch(a){ZR(e,a,{}),JR(e,a)}}function IO(){var e=zT.version;if("19.0.0"!==e)throw Error(UT(527,e,"19.0.0"))}IO(),IO(),BT.prerender=function(e,t){return new Promise((function(n,r){var a,o=t?t.onHeaders:void 0;o&&(a=function(e){o(new Headers(e))});var i=rA(t?t.identifierPrefix:void 0,t&&t.unstable_externalRuntimeSrc,t?t.bootstrapScriptContent:void 0,t?t.bootstrapScripts:void 0,t?t.bootstrapModules:void 0),s=function(e,t,n,r,a,o,i,s,l,c,u){return(e=HR(e,t,n,r,a,o,i,s,l,c,u,void 0)).trackedPostpones={workingMap:new Map,rootNodes:[],rootSlots:null},e}(e,i,nA(i,void 0,t?t.unstable_externalRuntimeSrc:void 0,t?t.importMap:void 0,a,t?t.maxHeadersLength:void 0),oA(t?t.namespaceURI:void 0),t?t.progressiveChunkSize:void 0,t?t.onError:void 0,(function(){var e={prelude:new ReadableStream({type:"bytes",pull:function(e){AO(s,e)},cancel:function(e){s.destination=null,NO(s,e)}},{highWaterMark:0})};n(e)}),void 0,void 0,r,t?t.onPostpone:void 0);if(t&&t.signal){var l=t.signal;if(l.aborted)NO(s,l.reason);else{var c=function(){NO(s,l.reason),l.removeEventListener("abort",c)};l.addEventListener("abort",c)}}TO(s)}))},BT.renderToReadableStream=function(e,t){return new Promise((function(n,r){var a,o,i,s=new Promise((function(e,t){o=e,a=t})),l=t?t.onHeaders:void 0;l&&(i=function(e){l(new Headers(e))});var c=rA(t?t.identifierPrefix:void 0,t&&t.unstable_externalRuntimeSrc,t?t.bootstrapScriptContent:void 0,t?t.bootstrapScripts:void 0,t?t.bootstrapModules:void 0),u=HR(e,c,nA(c,t?t.nonce:void 0,t?t.unstable_externalRuntimeSrc:void 0,t?t.importMap:void 0,i,t?t.maxHeadersLength:void 0),oA(t?t.namespaceURI:void 0),t?t.progressiveChunkSize:void 0,t?t.onError:void 0,o,(function(){var e=new ReadableStream({type:"bytes",pull:function(e){AO(u,e)},cancel:function(e){u.destination=null,NO(u,e)}},{highWaterMark:0});e.allReady=s,n(e)}),(function(e){s.catch((function(){})),r(e)}),a,t?t.onPostpone:void 0,t?t.formState:void 0);if(t&&t.signal){var d=t.signal;if(d.aborted)NO(u,d.reason);else{var p=function(){NO(u,d.reason),d.removeEventListener("abort",p)};d.addEventListener("abort",p)}}TO(u)}))},BT.version="19.0.0",$R=BT,(UR=Xx).version;var RO=UR.renderToString;function OO({children:e="",...t}){let n="";return X.isValidElement(e)?n=RO(e):"string"==typeof e&&(n=e),Wh.jsx("template",{...t,dangerouslySetInnerHTML:{__html:n}})}function PO({root:e,children:t=null}){return se.createPortal(t,e)}function DO(e){return K.forwardRef((({mode:t="open",delegatesFocus:n=!1,styleSheets:r=[],ssr:a=!1,children:o=null,...i},s)=>{const l=function(e){const t=K.useRef(null==e?void 0:e.current);return K.useEffect((()=>{e&&(e.current=t.current)}),[e]),t}(s),[c,u]=K.useState(null),d=`node_${t}${n}`;return K.useLayoutEffect((()=>{if(l.current)try{if("function"==typeof s&&s(l.current),a){const{shadowRoot:e}=l.current;return void u(e)}const e=l.current.attachShadow({mode:t,delegatesFocus:n});r.length>0&&(e.adoptedStyleSheets=r),u(e)}catch(e){!function({error:e,styleSheets:t,root:n}){if("NotSupportedError"!==(null==e?void 0:e.name))throw e;t.length>0&&n&&(n.adoptedStyleSheets=t)}({error:e,styleSheets:r,root:c})}}),[s,l,r]),Wh.jsx(e.tag,{ref:l,...i,children:(c||a)&&Wh.jsx(Kx.Provider,{value:c,children:a?Wh.jsx(OO,{shadowroot:t,shadowrootmode:t,children:e.render({root:c,ssr:a,children:o})}):Wh.jsx(PO,{root:c,children:e.render({root:c,ssr:a,children:o})})})},d)}))}UR.renderToStaticMarkup,$R.renderToReadableStream,$R.resume&&$R.resume;const LO=new Map;const MO=function(e={},t="core",n=({children:e})=>e){return new Proxy(e,{get:function(e,r){const a=Yx.decamelize(r,{separator:"-"}),o=`${t}-${a}`;if(!LO.has(o)){const e=DO({tag:a,render:n});LO.set(o,e)}return LO.get(o)}})}();var FO=(null==globalThis?void 0:globalThis.document)?K.useLayoutEffect:()=>{},jO=Q[" useId ".trim().toString()]||(()=>{}),BO=0;function zO(e){const[t,n]=K.useState(jO());return FO((()=>{n((e=>e??String(BO++)))}),[e]),t?`radix-${t}`:""}const HO=K.createContext(void 0),UO=()=>K.useContext(HO);function $O({wrapperStyles:e={},children:t,customStyles:n,styles:r}){const[a,o]=K.useState(null),[i,s]=K.useState(null),l=K.useMemo((()=>({shadowHost:a,rootElement:i})),[a,i]),c=zO(),u=MO.div;return Wh.jsxs(u,{id:`inkeep-shadow${c}`,ref:e=>{e&&o(e)},style:e,children:[Wh.jsx("style",{type:"text/css",dangerouslySetInnerHTML:{__html:`${r}`}}),n,Wh.jsx("div",{id:"inkeep-widget-root",ref:e=>{e&&s(e)},style:e,children:Wh.jsx(HO.Provider,{value:l,children:a&&i&&t})})]})}const GO=e=>UO()?e.children:Wh.jsx($O,{...e}),VO="ChatButton",qO="CustomTrigger",WO="SearchBar",YO="EmbeddedChat",KO="EmbeddedSearch",XO="EmbeddedSearchAndChat",QO="IntelligentForm",ZO="SidebarChat",JO={prefix:"ikp",aiChatSettings:{model:"inkeep-qa-expert",placeholder:"How do I get started?",aiAssistantName:void 0,shouldOpenLinksInNewTab:!0,disclaimerSettings:{isEnabled:!1,label:"Usage policy"},isShareButtonVisible:!1,isViewOnly:!1,exampleQuestionsLabel:"Example questions",exampleQuestions:[],isFirstExampleQuestionHighlighted:!0,isCopyChatButtonVisible:!1,getHelpOptions:[],workflowsHeader:"Workflows",workflows:[],toolbarButtonLabels:{clear:"Clear",share:"Share",getHelp:"Get help",stop:"Stop",copyChat:"Copy"},prompts:[]},baseSettings:Ix,searchSettings:{shouldOpenLinksInNewTab:!1,maxResults:40,defaultQuery:"",debounceTimeMs:0,tabs:["All","Publications","PDFs","GitHub","Forums","Discord","Slack","StackOverflow"],placeholder:"Search for anything...",view:"single-pane"},componentType:YO},eP=K.createContext(JO),tP=({children:e,value:t})=>{const n=UO(),r=(e,t,n)=>["baseSettings","searchSettings","aiChatSettings"].includes(n)&&!t?e:t,a={baseSettings:n??{}},o=K.useMemo((()=>{const e=function(e,t,...n){return n.reduce(((t,n)=>Oh(t,n,e)),t)}(r,JO,a,t??{});return e.baseSettings.apiKey||console.warn("Inkeep API key is missing."),e}),[t]);return Wh.jsx(eP.Provider,{value:o,children:e})},nP=()=>{const e=K.useContext(eP);if(!e)throw new Error("useInkeepConfig must be used within a ConfigProvider");return e},rP="conversationId",aP=K.createContext(null),oP=({children:e})=>{const t=function(){const[e,t]=K.useState(void 0),{aiChatSettings:n}=nP(),{shareChatUrlBasePath:r}=n;return K.useEffect((()=>{if(!r||"undefined"==typeof window)return;const e=e=>e.endsWith("/")?e.slice(0,-1):e,n=()=>{const{origin:n,pathname:a,search:o}=window.location,i=new URL(r),s=e(a),l=e(i.pathname);if(n===i.origin&&s===l){const e=new URLSearchParams(o).get(rP);e&&t(e)}};n();const a=()=>n();return window.addEventListener("popstate",a),()=>{window.removeEventListener("popstate",a)}}),[r]),e}(),{aiChatSettings:n}=nP(),r=n.chatId||t,[a,o]=K.useState(r);K.useEffect((()=>{o(r)}),[r]);const i={id:"",messages:[]},[s,l]=K.useState(i),c=()=>{l(i),o(void 0)},u=K.useMemo((()=>({conversation:s,setConversation:l,chatId:a,isSharedChat:!!t,resetConversation:c,setExternalChatId:o})),[s,a,t]);return Wh.jsx(aP.Provider,{value:u,children:e})},iP=()=>{const e=K.useContext(aP);if(!e)throw new Error("useInkeepConversation must be used within an InkeepConversationProvider");return e};async function sP(e,t,n,r){try{const a=`${r}/conversations`,o={id:e||void 0,type:"openai",...t},i=await fetch(a,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${n}`},body:JSON.stringify(o)});if(!i.ok){const e=await i.text();throw new Error(`Failed to log conversation: ${e}`)}return i.json()}catch(a){console.warn("Error in logConversation:",a)}}const lP="inkeepUsagePreferences",cP={defaultView:null,inkeepChatSessionId:null},uP={hasSwitchModeButtonJiggled:!1,userId:null,...cP},dP={set(e,t,n,r=365){try{if("cookie"===e){const e=new Date;void 0===n?(e.setTime(e.getTime()-1),document.cookie=`${lP}_${t}=; expires=${e.toUTCString()}; path=/`):(e.setTime(e.getTime()+24*r*60*60*1e3),document.cookie=`${lP}_${t}=${n}; expires=${e.toUTCString()}; path=/`)}else"undefined"!=typeof sessionStorage&&sessionStorage.setItem(`${lP}_${t}`,n?JSON.stringify(n):"")}catch(a){return null}},get(e,t){if("cookie"===e){const e=`${lP}_${t}=`,n=document.cookie.split(";");for(const t of n){const n=t.trim();if(n.startsWith(e))return n.substring(e.length)}return null}try{if("undefined"!=typeof sessionStorage){const e=sessionStorage.getItem(`${lP}_${t}`);return e?JSON.parse(e):null}}catch(n){return null}return null}},pP=()=>{const e=(()=>{try{if("undefined"==typeof localStorage)return!1;const e="__df709c5b-6651-43dc-94e7-d8dc899bf4e8__";return localStorage.setItem(e,"test_value"),localStorage.removeItem(e),!0}catch{return!1}})(),t=(()=>{if("undefined"==typeof document)return!1;document.cookie="testcookie=true; Path=/; Max-Age=1000";const e=document.cookie.includes("testcookie=true");return document.cookie="testcookie=; Path=/; Max-Age=-1000",e})();return e&&t},hP=K.createContext(void 0),fP=({children:e})=>{const{baseSettings:{userProperties:t,privacyPreferences:n}}=nP(),{optOutAllAnalytics:r,optOutAnalyticalCookies:a}=n,{browserStorage:o,setBrowserStorage:i}=(()=>{const{baseSettings:e,componentType:t}=nP(),{optOutAllAnalytics:n,optOutFunctionalCookies:r}=e.privacyPreferences,a=n||r||!pP()?"sessionStorage":"cookie",o=`${e.apiKey}-${t}`,i=e=>e in cP?`${e}-${o}`:e,s=Object.keys(uP).reduce(((e,t)=>{const n=i(t),r=dP.get(a,n);return{...e,[t]:r}}),{...uP}),[l,c]=K.useState(s);return K.useEffect((()=>{if(r)for(const e of Object.keys(uP)){const t=i(e);dP.set("cookie",t,null,-1)}}),[r]),{browserStorage:l,setBrowserStorage:(e,t,n=365)=>{const r=i(e);dP.set(a,r,t,n),c((n=>({...n,[e]:t})))}}})(),s=K.useMemo((()=>pP()),[]),l=K.useMemo((()=>!r&&!a&&s),[r,a,s]),c=K.useMemo((()=>{const e=r?"ANONYMOUS":t.id?"ID_PROVIDED":l?"COOKIED":"ANONYMOUS",n=r?void 0:t.id||l&&o.userId||Zh();return{identificationType:e,...r?{}:t,id:n}}),[t,r,l,o.userId]);return K.useEffect((()=>{i("userId",l?c.id:void 0)}),[l,c.id]),Wh.jsx(hP.Provider,{value:{userProperties:c},children:e})},mP=()=>{const e=K.useContext(hP);if(!e)throw new Error("useUser must be used within a UserProvider");return e};const gP=K.createContext(void 0),yP=({children:e})=>{const{baseSettings:t,componentType:n}=nP(),{apiKey:r,analyticsApiBaseUrl:a,tags:o,privacyPreferences:i,env:s,analyticsProperties:l}=t,{userProperties:c}=mP(),u=K.useMemo((()=>({widgetLibraryVersion:"0.5.100",componentType:n,tags:o})),[n,o]),d=!i.optOutAllAnalytics&&"development"!==s,p={logEvent:K.useCallback((async e=>{var n,o;const i={...u,...e.properties,...l},s={eventName:e.eventName,properties:i,userProperties:c},p=["modal_opened","modal_closed"].includes(e.eventName);if(d&&!p){if("conversation"in i&&!(null==(n=i.conversation)?void 0:n.id))return;!async function(e,t,n){try{const r=`${n}/events`,a={...e,type:e.eventName};if("searchQuery"in e.properties)a.entityType="search",a.searchQuery=e.properties.searchQuery;else if("messageId"in e.properties)a.entityType="message",a.messageId=e.properties.messageId;else{if(a.entityType="conversation",!e.properties.conversation)return;a.conversationId=e.properties.conversation.id}const o=await fetch(r,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${t}`},body:JSON.stringify(a)});if(!o.ok){const e=await o.text();throw new Error(`Failed to log event: ${e}`)}}catch(r){console.warn("Error in logEvent:",r)}}(s,r,a)}null==(o=t.onEvent)||o.call(t,s)}),[d,t,r,a,c,u,l])};return Wh.jsx(gP.Provider,{value:p,children:e})},bP=()=>{const e=K.useContext(gP);if(!e)throw new Error("useBaseEvents must be used within a BaseEventsProvider");return e},vP=K.createContext(void 0),kP=({children:e})=>{const{baseSettings:t,aiChatSettings:n}=nP(),{apiKey:r,analyticsApiBaseUrl:a,tags:o,privacyPreferences:{optOutAllAnalytics:i},env:s,analyticsProperties:l}=t,{conversationVisibility:c}=n,{userProperties:u}=mP(),{logEvent:d}=bP(),{conversation:p,setConversation:h,chatId:f,isSharedChat:m,setExternalChatId:g}=iP(),y=K.useRef(p),b=K.useRef(m?f:void 0);K.useEffect((()=>{y.current=p}),[p]),K.useEffect((()=>{b.current=m?f:void 0}),[f,m]);const v=K.useCallback((async e=>{const t=y.current;b.current&&(t.id="",g(void 0),b.current=void 0);const n=!i&&"development"!==s;let d=Object.assign({},t,{messages:e});if(n){const n=await sP(t.id,{messages:e,tags:o,userProperties:u,properties:l,visibility:c},r,a);n&&(d=n)}else d.id="conv_"+Zh(16);return d}),[a,r,o,u,i,s,l,g,c]),k={logEvent:K.useCallback((async(e,t)=>{let n=y.current;if(t){const e=y.current.messages||[];(t.length!==e.length||t.some(((t,n)=>{var r;return t.id!==(null==(r=e[n])?void 0:r.id)})))&&(n=await v(t),h(n),y.current=n)}const r={...e,properties:{conversation:n,...e.properties}};d(r)}),[d,v,i,s,l]),logConversation:v};return Wh.jsx(vP.Provider,{value:k,children:e})},wP=()=>{const e=K.useContext(vP);if(!e)throw new Error("useChatEvents must be used within a ChatEventsProvider");return e};function xP(e){const{displayName:t,goals:n,informationToCollect:r,guidance:a,botPersona:o,context:i}=e,s=SP({title:"Guidance",content:[EP(a)],note:o,depth:2}),l=_P(null==r?void 0:r.filter((e=>e.required)).map((e=>e.description))),c=_P(null==r?void 0:r.filter((e=>!e.required)).map((e=>e.description))),u=SP({title:"Required",content:[l],note:"IMPORTANT: This information is REQUIRED for this workflow. If not provided in the conversation, prompt the user to provide it and don't otherwise answer their question.",depth:3}),d=SP({title:"Optional",content:[c],depth:3}),p=SP({title:"Information to collect",content:[u,d],note:"This is information that should be collected from the user.",depth:2}),h=SP({title:"Context",content:[_P(i)],depth:2}),f=SP({title:"Workflow Name",content:[t],depth:2}),m=SP({title:"Goals",content:[EP(n)],depth:2});return SP({title:"Workflow",content:["I am a user being guided through a “workflow” defined by the organization that provides this chat experience.","**IMPORTANT: Follow the instructions outlined in this workflow. Follow the instructions in the workflow configuration below. Do not answer questions unrelated to the workflow.**",f,m,h,p,s],depth:1})}function EP(e){if(IP(e))return e.filter((e=>null!=e)).map(((e,t)=>`${t+1}. ${e}`)).join("\n")}function _P(e){if(IP(e))return e.filter((e=>null!=e)).map((e=>`- ${e}`)).join("\n")}function SP({title:e,content:t,note:n,depth:r=2}){const a=NP(t);if(!a&&!n)return;const o=`${"#".repeat(r)} ${e}\n`,i=NP([n,a]);return i?`${o}${i}\n`:void 0}function TP(e){if(!e)return;if(!IP(e))return;const t=e.map(((e,t)=>function({attachment:e,index:t}){const{title:n,content:r,contentType:a,context:o}=e,{contentInputLabel:i,type:s}=a,l=function(e){if("CODE"===(null==e?void 0:e.type))return e.language||"";return}(a),c=function(e,t){return t?`\`\`\`${t}\n${e}\n\`\`\``:e}(r,l),u=IP(o)?["\nAdditional Context:",NP(o)]:[],d=[`#### ATTACHMENT #${t+1}`,`Title: ${n}`,`Label: ${i}`,`Type: ${s}`,"Content:",c,...u].join("\n");return d}({attachment:e,index:t})));return NP(t)}function CP(e){return SP({title:"User-provided Attachments",content:["The user has provided the following attachments to their message:",TP(e)],depth:1})}function AP(e){if(!e.supportedInputs)return e;const t={...e};return t.supportedInputs=e.supportedInputs.map((e=>{const t={...e};return"MODAL"===t.type&&(t.workflowModalProps=void 0),t})),t}function NP(e){if(IP(e))return e.filter((e=>null!=e)).join("\n")}function IP(e){return Array.isArray(e)&&e.length>0}const RP=()=>{const e="undefined"==typeof window?new URL(""):new URL(window.location.href),t=new URLSearchParams(e.search);if(t.has(rP)){t.delete(rP);const n=t.toString(),r=n?`${e.origin}${e.pathname}?${n}`:`${e.origin}${e.pathname}`;"undefined"!=typeof window&&window.history.pushState({},"",r)}};var OP=e=>"checkbox"===e.type,PP=e=>e instanceof Date,DP=e=>null==e;const LP=e=>"object"==typeof e;var MP=e=>!DP(e)&&!Array.isArray(e)&&LP(e)&&!PP(e),FP=e=>MP(e)&&e.target?OP(e.target)?e.target.checked:e.target.value:e,jP=(e,t)=>e.has((e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e)(t)),BP="undefined"!=typeof window&&void 0!==window.HTMLElement&&"undefined"!=typeof document;function zP(e){let t;const n=Array.isArray(e),r="undefined"!=typeof FileList&&e instanceof FileList;if(e instanceof Date)t=new Date(e);else if(e instanceof Set)t=new Set(e);else{if(BP&&(e instanceof Blob||r)||!n&&!MP(e))return e;if(t=n?[]:{},n||(e=>{const t=e.constructor&&e.constructor.prototype;return MP(t)&&t.hasOwnProperty("isPrototypeOf")})(e))for(const n in e)e.hasOwnProperty(n)&&(t[n]=zP(e[n]));else t=e}return t}var HP=e=>Array.isArray(e)?e.filter(Boolean):[],UP=e=>void 0===e,$P=(e,t,n)=>{if(!t||!MP(e))return n;const r=HP(t.split(/[,[\].]+?/)).reduce(((e,t)=>DP(e)?e:e[t]),e);return UP(r)||r===e?UP(e[t])?n:e[t]:r},GP=e=>"boolean"==typeof e,VP=e=>/^\w*$/.test(e),qP=e=>HP(e.replace(/["|']|\]/g,"").split(/\.|\[/)),WP=(e,t,n)=>{let r=-1;const a=VP(t)?[t]:qP(t),o=a.length,i=o-1;for(;++r<o;){const t=a[r];let o=n;if(r!==i){const n=e[t];o=MP(n)||Array.isArray(n)?n:isNaN(+a[r+1])?{}:[]}if("__proto__"===t||"constructor"===t||"prototype"===t)return;e[t]=o,e=e[t]}return e};const YP="blur",KP="focusout",XP="change",QP="onBlur",ZP="onChange",JP="onSubmit",eD="onTouched",tD="all",nD="max",rD="min",aD="maxLength",oD="minLength",iD="pattern",sD="required",lD="validate",cD=X.createContext(null),uD=()=>X.useContext(cD);var dD=(e,t,n,r=!0)=>{const a={defaultValues:t._defaultValues};for(const o in e)Object.defineProperty(a,o,{get:()=>{const a=o;return t._proxyFormState[a]!==tD&&(t._proxyFormState[a]=!r||tD),n&&(n[a]=!0),e[a]}});return a},pD=e=>MP(e)&&!Object.keys(e).length,hD=(e,t,n,r)=>{n(e);const{name:a,...o}=e;return pD(o)||Object.keys(o).length>=Object.keys(t).length||Object.keys(o).find((e=>t[e]===(!r||tD)))},fD=e=>Array.isArray(e)?e:[e],mD=(e,t,n)=>!e||!t||e===t||fD(e).some((e=>e&&(n?e===t:e.startsWith(t)||t.startsWith(e))));function gD(e){const t=X.useRef(e);t.current=e,X.useEffect((()=>{const n=!e.disabled&&t.current.subject&&t.current.subject.subscribe({next:t.current.next});return()=>{n&&n.unsubscribe()}}),[e.disabled])}var yD=e=>"string"==typeof e,bD=(e,t,n,r,a)=>yD(e)?(r&&t.watch.add(e),$P(n,e,a)):Array.isArray(e)?e.map((e=>(r&&t.watch.add(e),$P(n,e)))):(r&&(t.watchAll=!0),n);function vD(e){const t=uD(),{name:n,disabled:r,control:a=t.control,shouldUnregister:o}=e,i=jP(a._names.array,n),s=function(e){const t=uD(),{control:n=t.control,name:r,defaultValue:a,disabled:o,exact:i}=e||{},s=X.useRef(r);s.current=r,gD({disabled:o,subject:n._subjects.values,next:e=>{mD(s.current,e.name,i)&&c(zP(bD(s.current,n._names,e.values||n._formValues,!1,a)))}});const[l,c]=X.useState(n._getWatch(r,a));return X.useEffect((()=>n._removeUnmounted())),l}({control:a,name:n,defaultValue:$P(a._formValues,n,$P(a._defaultValues,n,e.defaultValue)),exact:!0}),l=function(e){const t=uD(),{control:n=t.control,disabled:r,name:a,exact:o}=e||{},[i,s]=X.useState(n._formState),l=X.useRef(!0),c=X.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1}),u=X.useRef(a);return u.current=a,gD({disabled:r,next:e=>l.current&&mD(u.current,e.name,o)&&hD(e,c.current,n._updateFormState)&&s({...n._formState,...e}),subject:n._subjects.state}),X.useEffect((()=>(l.current=!0,c.current.isValid&&n._updateValid(!0),()=>{l.current=!1})),[n]),X.useMemo((()=>dD(i,n,c.current,!1)),[i,n])}({control:a,name:n,exact:!0}),c=X.useRef(a.register(n,{...e.rules,value:s,...GP(e.disabled)?{disabled:e.disabled}:{}})),u=X.useMemo((()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!$P(l.errors,n)},isDirty:{enumerable:!0,get:()=>!!$P(l.dirtyFields,n)},isTouched:{enumerable:!0,get:()=>!!$P(l.touchedFields,n)},isValidating:{enumerable:!0,get:()=>!!$P(l.validatingFields,n)},error:{enumerable:!0,get:()=>$P(l.errors,n)}})),[l,n]),d=X.useMemo((()=>({name:n,value:s,...GP(r)||l.disabled?{disabled:l.disabled||r}:{},onChange:e=>c.current.onChange({target:{value:FP(e),name:n},type:XP}),onBlur:()=>c.current.onBlur({target:{value:$P(a._formValues,n),name:n},type:YP}),ref:e=>{const t=$P(a._fields,n);t&&e&&(t._f.ref={focus:()=>e.focus(),select:()=>e.select(),setCustomValidity:t=>e.setCustomValidity(t),reportValidity:()=>e.reportValidity()})}})),[n,a._formValues,r,l.disabled,s,a._fields]);return X.useEffect((()=>{const e=a._options.shouldUnregister||o,t=(e,t)=>{const n=$P(a._fields,e);n&&n._f&&(n._f.mount=t)};if(t(n,!0),e){const e=zP($P(a._options.defaultValues,n));WP(a._defaultValues,n,e),UP($P(a._formValues,n))&&WP(a._formValues,n,e)}return!i&&a.register(n),()=>{(i?e&&!a._state.action:e)?a.unregister(n):t(n,!1)}}),[n,a,i,o]),X.useEffect((()=>{a._updateDisabledField({disabled:r,fields:a._fields,name:n})}),[r,n,a]),X.useMemo((()=>({field:d,formState:l,fieldState:u})),[d,l,u])}const kD=e=>e.render(vD(e));var wD=(e,t,n,r,a)=>t?{...n[e],types:{...n[e]&&n[e].types?n[e].types:{},[r]:a||!0}}:{},xD=e=>({isOnSubmit:!e||e===JP,isOnBlur:e===QP,isOnChange:e===ZP,isOnAll:e===tD,isOnTouch:e===eD}),ED=(e,t,n)=>!n&&(t.watchAll||t.watch.has(e)||[...t.watch].some((t=>e.startsWith(t)&&/^\.\w+/.test(e.slice(t.length)))));const _D=(e,t,n,r)=>{for(const a of n||Object.keys(e)){const n=$P(e,a);if(n){const{_f:e,...o}=n;if(e){if(e.refs&&e.refs[0]&&t(e.refs[0],a)&&!r)return!0;if(e.ref&&t(e.ref,e.name)&&!r)return!0;if(_D(o,t))break}else if(MP(o)&&_D(o,t))break}}};var SD=(e,t,n)=>{const r=fD($P(e,n));return WP(r,"root",t[n]),WP(e,n,r),e},TD=e=>"file"===e.type,CD=e=>"function"==typeof e,AD=e=>{if(!BP)return!1;const t=e?e.ownerDocument:0;return e instanceof(t&&t.defaultView?t.defaultView.HTMLElement:HTMLElement)},ND=e=>yD(e),ID=e=>"radio"===e.type,RD=e=>e instanceof RegExp;const OD={value:!1,isValid:!1},PD={value:!0,isValid:!0};var DD=e=>{if(Array.isArray(e)){if(e.length>1){const t=e.filter((e=>e&&e.checked&&!e.disabled)).map((e=>e.value));return{value:t,isValid:!!t.length}}return e[0].checked&&!e[0].disabled?e[0].attributes&&!UP(e[0].attributes.value)?UP(e[0].value)||""===e[0].value?PD:{value:e[0].value,isValid:!0}:PD:OD}return OD};const LD={isValid:!1,value:null};var MD=e=>Array.isArray(e)?e.reduce(((e,t)=>t&&t.checked&&!t.disabled?{isValid:!0,value:t.value}:e),LD):LD;function FD(e,t,n="validate"){if(ND(e)||Array.isArray(e)&&e.every(ND)||GP(e)&&!e)return{type:n,message:ND(e)?e:"",ref:t}}var jD=e=>MP(e)&&!RD(e)?e:{value:e,message:""},BD=async(e,t,n,r,a,o)=>{const{ref:i,refs:s,required:l,maxLength:c,minLength:u,min:d,max:p,pattern:h,validate:f,name:m,valueAsNumber:g,mount:y}=e._f,b=$P(n,m);if(!y||t.has(m))return{};const v=s?s[0]:i,k=e=>{a&&v.reportValidity&&(v.setCustomValidity(GP(e)?"":e||""),v.reportValidity())},w={},x=ID(i),E=OP(i),_=x||E,S=(g||TD(i))&&UP(i.value)&&UP(b)||AD(i)&&""===i.value||""===b||Array.isArray(b)&&!b.length,T=wD.bind(null,m,r,w),C=(e,t,n,r=aD,a=oD)=>{const o=e?t:n;w[m]={type:e?r:a,message:o,ref:i,...T(e?r:a,o)}};if(o?!Array.isArray(b)||!b.length:l&&(!_&&(S||DP(b))||GP(b)&&!b||E&&!DD(s).isValid||x&&!MD(s).isValid)){const{value:e,message:t}=ND(l)?{value:!!l,message:l}:jD(l);if(e&&(w[m]={type:sD,message:t,ref:v,...T(sD,t)},!r))return k(t),w}if(!(S||DP(d)&&DP(p))){let e,t;const n=jD(p),a=jD(d);if(DP(b)||isNaN(b)){const r=i.valueAsDate||new Date(b),o=e=>new Date((new Date).toDateString()+" "+e),s="time"==i.type,l="week"==i.type;yD(n.value)&&b&&(e=s?o(b)>o(n.value):l?b>n.value:r>new Date(n.value)),yD(a.value)&&b&&(t=s?o(b)<o(a.value):l?b<a.value:r<new Date(a.value))}else{const r=i.valueAsNumber||(b?+b:b);DP(n.value)||(e=r>n.value),DP(a.value)||(t=r<a.value)}if((e||t)&&(C(!!e,n.message,a.message,nD,rD),!r))return k(w[m].message),w}if((c||u)&&!S&&(yD(b)||o&&Array.isArray(b))){const e=jD(c),t=jD(u),n=!DP(e.value)&&b.length>+e.value,a=!DP(t.value)&&b.length<+t.value;if((n||a)&&(C(n,e.message,t.message),!r))return k(w[m].message),w}if(h&&!S&&yD(b)){const{value:e,message:t}=jD(h);if(RD(e)&&!b.match(e)&&(w[m]={type:iD,message:t,ref:i,...T(iD,t)},!r))return k(t),w}if(f)if(CD(f)){const e=FD(await f(b,n),v);if(e&&(w[m]={...e,...T(lD,e.message)},!r))return k(e.message),w}else if(MP(f)){let e={};for(const t in f){if(!pD(e)&&!r)break;const a=FD(await f[t](b,n),v,t);a&&(e={...a,...T(t,a.message)},k(a.message),r&&(w[m]=e))}if(!pD(e)&&(w[m]={ref:v,...e},!r))return w}return k(!0),w};function zD(e,t){const n=Array.isArray(t)?t:VP(t)?[t]:qP(t),r=1===n.length?e:function(e,t){const n=t.slice(0,-1).length;let r=0;for(;r<n;)e=UP(e)?r++:e[t[r++]];return e}(e,n),a=n.length-1,o=n[a];return r&&delete r[o],0!==a&&(MP(r)&&pD(r)||Array.isArray(r)&&function(e){for(const t in e)if(e.hasOwnProperty(t)&&!UP(e[t]))return!1;return!0}(r))&&zD(e,n.slice(0,-1)),e}var HD=()=>{let e=[];return{get observers(){return e},next:t=>{for(const n of e)n.next&&n.next(t)},subscribe:t=>(e.push(t),{unsubscribe:()=>{e=e.filter((e=>e!==t))}}),unsubscribe:()=>{e=[]}}},UD=e=>DP(e)||!LP(e);function $D(e,t){if(UD(e)||UD(t))return e===t;if(PP(e)&&PP(t))return e.getTime()===t.getTime();const n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(const a of n){const n=e[a];if(!r.includes(a))return!1;if("ref"!==a){const e=t[a];if(PP(n)&&PP(e)||MP(n)&&MP(e)||Array.isArray(n)&&Array.isArray(e)?!$D(n,e):n!==e)return!1}}return!0}var GD=e=>"select-multiple"===e.type,VD=e=>AD(e)&&e.isConnected,qD=e=>{for(const t in e)if(CD(e[t]))return!0;return!1};function WD(e,t={}){const n=Array.isArray(e);if(MP(e)||n)for(const r in e)Array.isArray(e[r])||MP(e[r])&&!qD(e[r])?(t[r]=Array.isArray(e[r])?[]:{},WD(e[r],t[r])):DP(e[r])||(t[r]=!0);return t}function YD(e,t,n){const r=Array.isArray(e);if(MP(e)||r)for(const a in e)Array.isArray(e[a])||MP(e[a])&&!qD(e[a])?UP(t)||UD(n[a])?n[a]=Array.isArray(e[a])?WD(e[a],[]):{...WD(e[a])}:YD(e[a],DP(t)?{}:t[a],n[a]):n[a]=!$D(e[a],t[a]);return n}var KD=(e,t)=>YD(e,t,WD(t)),XD=(e,{valueAsNumber:t,valueAsDate:n,setValueAs:r})=>UP(e)?e:t?""===e?NaN:e?+e:e:n&&yD(e)?new Date(e):r?r(e):e;function QD(e){const t=e.ref;return TD(t)?t.files:ID(t)?MD(e.refs).value:GD(t)?[...t.selectedOptions].map((({value:e})=>e)):OP(t)?DD(e.refs).value:XD(UP(t.value)?e.ref.value:t.value,e)}var ZD=e=>UP(e)?e:RD(e)?e.source:MP(e)?RD(e.value)?e.value.source:e.value:e;const JD="AsyncFunction";function eL(e,t,n){const r=$P(e,n);if(r||VP(n))return{error:r,name:n};const a=n.split(".");for(;a.length;){const r=a.join("."),o=$P(t,r),i=$P(e,r);if(o&&!Array.isArray(o)&&n!==r)return{name:n};if(i&&i.type)return{name:r,error:i};a.pop()}return{name:n}}const tL={mode:JP,reValidateMode:ZP,shouldFocusError:!0};function nL(e={}){let t,n={...tL,...e},r={submitCount:0,isDirty:!1,isLoading:CD(n.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:n.errors||{},disabled:n.disabled||!1},a={},o=(MP(n.defaultValues)||MP(n.values))&&zP(n.defaultValues||n.values)||{},i=n.shouldUnregister?{}:zP(o),s={action:!1,mount:!1,watch:!1},l={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set},c=0;const u={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1},d={values:HD(),array:HD(),state:HD()},p=xD(n.mode),h=xD(n.reValidateMode),f=n.criteriaMode===tD,m=async e=>{if(!n.disabled&&(u.isValid||e)){const e=n.resolver?pD((await k()).errors):await w(a,!0);e!==r.isValid&&d.state.next({isValid:e})}},g=(e,t)=>{n.disabled||!u.isValidating&&!u.validatingFields||((e||Array.from(l.mount)).forEach((e=>{e&&(t?WP(r.validatingFields,e,t):zD(r.validatingFields,e))})),d.state.next({validatingFields:r.validatingFields,isValidating:!pD(r.validatingFields)}))},y=(e,t,n,r)=>{const l=$P(a,e);if(l){const a=$P(i,e,UP(n)?$P(o,e):n);UP(a)||r&&r.defaultChecked||t?WP(i,e,t?a:QD(l._f)):_(e,a),s.mount&&m()}},b=(e,t,i,s,l)=>{let c=!1,p=!1;const h={name:e};if(!n.disabled){const n=!!($P(a,e)&&$P(a,e)._f&&$P(a,e)._f.disabled);if(!i||s){u.isDirty&&(p=r.isDirty,r.isDirty=h.isDirty=x(),c=p!==h.isDirty);const a=n||$D($P(o,e),t);p=!(n||!$P(r.dirtyFields,e)),a||n?zD(r.dirtyFields,e):WP(r.dirtyFields,e,!0),h.dirtyFields=r.dirtyFields,c=c||u.dirtyFields&&p!==!a}if(i){const t=$P(r.touchedFields,e);t||(WP(r.touchedFields,e,i),h.touchedFields=r.touchedFields,c=c||u.touchedFields&&t!==i)}c&&l&&d.state.next(h)}return c?h:{}},v=(e,a,o,i)=>{const s=$P(r.errors,e),l=u.isValid&&GP(a)&&r.isValid!==a;var p;if(n.delayError&&o?(p=()=>((e,t)=>{WP(r.errors,e,t),d.state.next({errors:r.errors})})(e,o),t=e=>{clearTimeout(c),c=setTimeout(p,e)},t(n.delayError)):(clearTimeout(c),t=null,o?WP(r.errors,e,o):zD(r.errors,e)),(o?!$D(s,o):s)||!pD(i)||l){const t={...i,...l&&GP(a)?{isValid:a}:{},errors:r.errors,name:e};r={...r,...t},d.state.next(t)}},k=async e=>{g(e,!0);const t=await n.resolver(i,n.context,((e,t,n,r)=>{const a={};for(const o of e){const e=$P(t,o);e&&WP(a,o,e._f)}return{criteriaMode:n,names:[...e],fields:a,shouldUseNativeValidation:r}})(e||l.mount,a,n.criteriaMode,n.shouldUseNativeValidation));return g(e),t},w=async(e,t,a={valid:!0})=>{for(const s in e){const c=e[s];if(c){const{_f:e,...d}=c;if(e){const d=l.array.has(e.name),p=c._f&&(!!(o=c._f)&&!!o.validate&&!!(CD(o.validate)&&o.validate.constructor.name===JD||MP(o.validate)&&Object.values(o.validate).find((e=>e.constructor.name===JD))));p&&u.validatingFields&&g([s],!0);const h=await BD(c,l.disabled,i,f,n.shouldUseNativeValidation&&!t,d);if(p&&u.validatingFields&&g([s]),h[e.name]&&(a.valid=!1,t))break;!t&&($P(h,e.name)?d?SD(r.errors,h,e.name):WP(r.errors,e.name,h[e.name]):zD(r.errors,e.name))}!pD(d)&&await w(d,t,a)}}var o;return a.valid},x=(e,t)=>!n.disabled&&(e&&t&&WP(i,e,t),!$D(I(),o)),E=(e,t,n)=>bD(e,l,{...s.mount?i:UP(t)?o:yD(e)?{[e]:t}:t},n,t),_=(e,t,n={})=>{const r=$P(a,e);let o=t;if(r){const n=r._f;n&&(!n.disabled&&WP(i,e,XD(t,n)),o=AD(n.ref)&&DP(t)?"":t,GD(n.ref)?[...n.ref.options].forEach((e=>e.selected=o.includes(e.value))):n.refs?OP(n.ref)?n.refs.length>1?n.refs.forEach((e=>(!e.defaultChecked||!e.disabled)&&(e.checked=Array.isArray(o)?!!o.find((t=>t===e.value)):o===e.value))):n.refs[0]&&(n.refs[0].checked=!!o):n.refs.forEach((e=>e.checked=e.value===o)):TD(n.ref)?n.ref.value="":(n.ref.value=o,n.ref.type||d.values.next({name:e,values:{...i}})))}(n.shouldDirty||n.shouldTouch)&&b(e,o,n.shouldTouch,n.shouldDirty,!0),n.shouldValidate&&N(e)},S=(e,t,n)=>{for(const r in t){const o=t[r],i=`${e}.${r}`,s=$P(a,i);(l.array.has(e)||MP(o)||s&&!s._f)&&!PP(o)?S(i,o,n):_(i,o,n)}},T=(e,t,n={})=>{const c=$P(a,e),p=l.array.has(e),h=zP(t);WP(i,e,h),p?(d.array.next({name:e,values:{...i}}),(u.isDirty||u.dirtyFields)&&n.shouldDirty&&d.state.next({name:e,dirtyFields:KD(o,i),isDirty:x(e,h)})):!c||c._f||DP(h)?_(e,h,n):S(e,h,n),ED(e,l)&&d.state.next({...r}),d.values.next({name:s.mount?e:void 0,values:{...i}})},C=async e=>{s.mount=!0;const o=e.target;let c=o.name,y=!0;const x=$P(a,c),E=e=>{y=Number.isNaN(e)||PP(e)&&isNaN(e.getTime())||$D(e,$P(i,c,e))};if(x){let s,S;const T=o.type?QD(x._f):FP(e),C=e.type===YP||e.type===KP,A=!((_=x._f).mount&&(_.required||_.min||_.max||_.maxLength||_.minLength||_.pattern||_.validate)||n.resolver||$P(r.errors,c)||x._f.deps)||((e,t,n,r,a)=>!a.isOnAll&&(!n&&a.isOnTouch?!(t||e):(n?r.isOnBlur:a.isOnBlur)?!e:!(n?r.isOnChange:a.isOnChange)||e))(C,$P(r.touchedFields,c),r.isSubmitted,h,p),I=ED(c,l,C);WP(i,c,T),C?(x._f.onBlur&&x._f.onBlur(e),t&&t(0)):x._f.onChange&&x._f.onChange(e);const R=b(c,T,C,!1),O=!pD(R)||I;if(!C&&d.values.next({name:c,type:e.type,values:{...i}}),A)return u.isValid&&("onBlur"===n.mode&&C?m():C||m()),O&&d.state.next({name:c,...I?{}:R});if(!C&&I&&d.state.next({...r}),n.resolver){const{errors:e}=await k([c]);if(E(T),y){const t=eL(r.errors,a,c),n=eL(e,a,t.name||c);s=n.error,c=n.name,S=pD(e)}}else g([c],!0),s=(await BD(x,l.disabled,i,f,n.shouldUseNativeValidation))[c],g([c]),E(T),y&&(s?S=!1:u.isValid&&(S=await w(a,!0)));y&&(x._f.deps&&N(x._f.deps),v(c,S,s,R))}var _},A=(e,t)=>{if($P(r.errors,t)&&e.focus)return e.focus(),1},N=async(e,t={})=>{let o,i;const s=fD(e);if(n.resolver){const t=await(async e=>{const{errors:t}=await k(e);if(e)for(const n of e){const e=$P(t,n);e?WP(r.errors,n,e):zD(r.errors,n)}else r.errors=t;return t})(UP(e)?e:s);o=pD(t),i=e?!s.some((e=>$P(t,e))):o}else e?(i=(await Promise.all(s.map((async e=>{const t=$P(a,e);return await w(t&&t._f?{[e]:t}:t)})))).every(Boolean),(i||r.isValid)&&m()):i=o=await w(a);return d.state.next({...!yD(e)||u.isValid&&o!==r.isValid?{}:{name:e},...n.resolver||!e?{isValid:o}:{},errors:r.errors}),t.shouldFocus&&!i&&_D(a,A,e?s:l.mount),i},I=e=>{const t={...s.mount?i:o};return UP(e)?t:yD(e)?$P(t,e):e.map((e=>$P(t,e)))},R=(e,t)=>({invalid:!!$P((t||r).errors,e),isDirty:!!$P((t||r).dirtyFields,e),error:$P((t||r).errors,e),isValidating:!!$P(r.validatingFields,e),isTouched:!!$P((t||r).touchedFields,e)}),O=(e,t,n)=>{const o=($P(a,e,{_f:{}})._f||{}).ref,i=$P(r.errors,e)||{},{ref:s,message:l,type:c,...u}=i;WP(r.errors,e,{...u,...t,ref:o}),d.state.next({name:e,errors:r.errors,isValid:!1}),n&&n.shouldFocus&&o&&o.focus&&o.focus()},P=(e,t={})=>{for(const s of e?fD(e):l.mount)l.mount.delete(s),l.array.delete(s),t.keepValue||(zD(a,s),zD(i,s)),!t.keepError&&zD(r.errors,s),!t.keepDirty&&zD(r.dirtyFields,s),!t.keepTouched&&zD(r.touchedFields,s),!t.keepIsValidating&&zD(r.validatingFields,s),!n.shouldUnregister&&!t.keepDefaultValue&&zD(o,s);d.values.next({values:{...i}}),d.state.next({...r,...t.keepDirty?{isDirty:x()}:{}}),!t.keepIsValid&&m()},D=({disabled:e,name:t,field:n,fields:r})=>{(GP(e)&&s.mount||e||l.disabled.has(t))&&(e?l.disabled.add(t):l.disabled.delete(t),b(t,QD(n?n._f:$P(r,t)._f),!1,!1,!0))},L=(e,t={})=>{let r=$P(a,e);const i=GP(t.disabled)||GP(n.disabled);return WP(a,e,{...r||{},_f:{...r&&r._f?r._f:{ref:{name:e}},name:e,mount:!0,...t}}),l.mount.add(e),r?D({field:r,disabled:GP(t.disabled)?t.disabled:n.disabled,name:e}):y(e,!0,t.value),{...i?{disabled:t.disabled||n.disabled}:{},...n.progressive?{required:!!t.required,min:ZD(t.min),max:ZD(t.max),minLength:ZD(t.minLength),maxLength:ZD(t.maxLength),pattern:ZD(t.pattern)}:{},name:e,onChange:C,onBlur:C,ref:i=>{if(i){L(e,t),r=$P(a,e);const n=UP(i.value)&&i.querySelectorAll&&i.querySelectorAll("input,select,textarea")[0]||i,s=(e=>ID(e)||OP(e))(n),l=r._f.refs||[];if(s?l.find((e=>e===n)):n===r._f.ref)return;WP(a,e,{_f:{...r._f,...s?{refs:[...l.filter(VD),n,...Array.isArray($P(o,e))?[{}]:[]],ref:{type:n.type,name:e}}:{ref:n}}}),y(e,!1,void 0,n)}else r=$P(a,e,{}),r._f&&(r._f.mount=!1),(n.shouldUnregister||t.shouldUnregister)&&(!jP(l.array,e)||!s.action)&&l.unMount.add(e)}}},M=()=>n.shouldFocusError&&_D(a,A,l.mount),F=(e,t)=>async o=>{let s;o&&(o.preventDefault&&o.preventDefault(),o.persist&&o.persist());let c=zP(i);if(l.disabled.size)for(const e of l.disabled)WP(c,e,void 0);if(d.state.next({isSubmitting:!0}),n.resolver){const{errors:e,values:t}=await k();r.errors=e,c=t}else await w(a);if(zD(r.errors,"root"),pD(r.errors)){d.state.next({errors:{}});try{await e(c,o)}catch(u){s=u}}else t&&await t({...r.errors},o),M(),setTimeout(M);if(d.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:pD(r.errors)&&!s,submitCount:r.submitCount+1,errors:r.errors}),s)throw s},j=(e,t={})=>{const c=e?zP(e):o,p=zP(c),h=pD(e),f=h?o:p;if(t.keepDefaultValues||(o=c),!t.keepValues){if(t.keepDirtyValues){const e=new Set([...l.mount,...Object.keys(KD(o,i))]);for(const t of Array.from(e))$P(r.dirtyFields,t)?WP(f,t,$P(i,t)):T(t,$P(f,t))}else{if(BP&&UP(e))for(const e of l.mount){const t=$P(a,e);if(t&&t._f){const e=Array.isArray(t._f.refs)?t._f.refs[0]:t._f.ref;if(AD(e)){const t=e.closest("form");if(t){t.reset();break}}}}a={}}i=n.shouldUnregister?t.keepDefaultValues?zP(o):{}:zP(f),d.array.next({values:{...f}}),d.values.next({values:{...f}})}l={mount:t.keepDirtyValues?l.mount:new Set,unMount:new Set,array:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:""},s.mount=!u.isValid||!!t.keepIsValid||!!t.keepDirtyValues,s.watch=!!n.shouldUnregister,d.state.next({submitCount:t.keepSubmitCount?r.submitCount:0,isDirty:!h&&(t.keepDirty?r.isDirty:!(!t.keepDefaultValues||$D(e,o))),isSubmitted:!!t.keepIsSubmitted&&r.isSubmitted,dirtyFields:h?{}:t.keepDirtyValues?t.keepDefaultValues&&i?KD(o,i):r.dirtyFields:t.keepDefaultValues&&e?KD(o,e):t.keepDirty?r.dirtyFields:{},touchedFields:t.keepTouched?r.touchedFields:{},errors:t.keepErrors?r.errors:{},isSubmitSuccessful:!!t.keepIsSubmitSuccessful&&r.isSubmitSuccessful,isSubmitting:!1})},B=(e,t)=>j(CD(e)?e(i):e,t);return{control:{register:L,unregister:P,getFieldState:R,handleSubmit:F,setError:O,_executeSchema:k,_getWatch:E,_getDirty:x,_updateValid:m,_removeUnmounted:()=>{for(const e of l.unMount){const t=$P(a,e);t&&(t._f.refs?t._f.refs.every((e=>!VD(e))):!VD(t._f.ref))&&P(e)}l.unMount=new Set},_updateFieldArray:(e,t=[],l,c,p=!0,h=!0)=>{if(c&&l&&!n.disabled){if(s.action=!0,h&&Array.isArray($P(a,e))){const t=l($P(a,e),c.argA,c.argB);p&&WP(a,e,t)}if(h&&Array.isArray($P(r.errors,e))){const t=l($P(r.errors,e),c.argA,c.argB);p&&WP(r.errors,e,t),((e,t)=>{!HP($P(e,t)).length&&zD(e,t)})(r.errors,e)}if(u.touchedFields&&h&&Array.isArray($P(r.touchedFields,e))){const t=l($P(r.touchedFields,e),c.argA,c.argB);p&&WP(r.touchedFields,e,t)}u.dirtyFields&&(r.dirtyFields=KD(o,i)),d.state.next({name:e,isDirty:x(e,t),dirtyFields:r.dirtyFields,errors:r.errors,isValid:r.isValid})}else WP(i,e,t)},_updateDisabledField:D,_getFieldArray:e=>HP($P(s.mount?i:o,e,n.shouldUnregister?$P(o,e,[]):[])),_reset:j,_resetDefaultValues:()=>CD(n.defaultValues)&&n.defaultValues().then((e=>{B(e,n.resetOptions),d.state.next({isLoading:!1})})),_updateFormState:e=>{r={...r,...e}},_disableForm:e=>{GP(e)&&(d.state.next({disabled:e}),_D(a,((t,n)=>{const r=$P(a,n);r&&(t.disabled=r._f.disabled||e,Array.isArray(r._f.refs)&&r._f.refs.forEach((t=>{t.disabled=r._f.disabled||e})))}),0,!1))},_subjects:d,_proxyFormState:u,_setErrors:e=>{r.errors=e,d.state.next({errors:r.errors,isValid:!1})},get _fields(){return a},get _formValues(){return i},get _state(){return s},set _state(e){s=e},get _defaultValues(){return o},get _names(){return l},set _names(e){l=e},get _formState(){return r},set _formState(e){r=e},get _options(){return n},set _options(e){n={...n,...e}}},trigger:N,register:L,handleSubmit:F,watch:(e,t)=>CD(e)?d.values.subscribe({next:n=>e(E(void 0,t),n)}):E(e,t,!0),setValue:T,getValues:I,reset:B,resetField:(e,t={})=>{$P(a,e)&&(UP(t.defaultValue)?T(e,zP($P(o,e))):(T(e,t.defaultValue),WP(o,e,zP(t.defaultValue))),t.keepTouched||zD(r.touchedFields,e),t.keepDirty||(zD(r.dirtyFields,e),r.isDirty=t.defaultValue?x(e,zP($P(o,e))):x()),t.keepError||(zD(r.errors,e),u.isValid&&m()),d.state.next({...r}))},clearErrors:e=>{e&&fD(e).forEach((e=>zD(r.errors,e))),d.state.next({errors:e?r.errors:{}})},unregister:P,setError:O,setFocus:(e,t={})=>{const n=$P(a,e),r=n&&n._f;if(r){const e=r.refs?r.refs[0]:r.ref;e.focus&&(e.focus(),t.shouldSelect&&CD(e.select)&&e.select())}},getFieldState:R}}function rL(e={}){const t=X.useRef(void 0),n=X.useRef(void 0),[r,a]=X.useState({isDirty:!1,isValidating:!1,isLoading:CD(e.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1,defaultValues:CD(e.defaultValues)?void 0:e.defaultValues});t.current||(t.current={...nL(e),formState:r});const o=t.current.control;return o._options=e,gD({subject:o._subjects.state,next:e=>{hD(e,o._proxyFormState,o._updateFormState,!0)&&a({...o._formState})}}),X.useEffect((()=>o._disableForm(e.disabled)),[o,e.disabled]),X.useEffect((()=>{if(o._proxyFormState.isDirty){const e=o._getDirty();e!==r.isDirty&&o._subjects.state.next({isDirty:e})}}),[o,r.isDirty]),X.useEffect((()=>{e.values&&!$D(e.values,n.current)?(o._reset(e.values,o._options.resetOptions),n.current=e.values,a((e=>({...e})))):o._resetDefaultValues()}),[e.values,o]),X.useEffect((()=>{e.errors&&o._setErrors(e.errors)}),[e.errors,o]),X.useEffect((()=>{o._state.mount||(o._updateValid(),o._state.mount=!0),o._state.watch&&(o._state.watch=!1,o._subjects.state.next({...o._formState})),o._removeUnmounted()})),X.useEffect((()=>{e.shouldUnregister&&o._subjects.values.next({values:o._getWatch()})}),[e.shouldUnregister,o]),t.current.formState=dD(r,o),t.current}const aL=K.createContext(void 0),oL=({children:e,modal:t})=>Wh.jsx(aL.Provider,{value:t,children:e}),iL=()=>K.useContext(aL),sL={text:"",email:"",checkbox:!1,textarea:"",file:void 0,select:""};function lL(e){return e?null==e?void 0:e.reduce(((e,t)=>("defaultValue"in t&&t.defaultValue?e[t.name]=t.defaultValue:t.inputType&&(e[t.name]=sL[t.inputType]),e)),{}):{}}const cL=K.createContext(void 0);const uL=({children:e})=>{const t=function(){var e;const[t,n]=K.useState(null),[r,a]=K.useState(null),[o,i]=K.useState(!1),{conversation:s}=iP(),l=iL(),{logEvent:c}=wP(),u=()=>{var e;n(null),a(null),i(!1),"close_modal"===(null==(e=null==t?void 0:t.buttons.close)?void 0:e.action)&&(null==l||l.setOpen(!1))},d=K.useMemo((()=>null==t?void 0:t.fields.map((e=>{const t={...e};return"_type"in e&&"include_chat_session"===e._type&&(t.inputType="checkbox",s.id?(t.isHidden=e.isHidden,t.isRequired=e.isRequired):(t.isHidden=!0,t.isRequired=!1)),t}))),[null==t?void 0:t.fields,s.id]),p=null==d?void 0:d.find((e=>"_type"in e&&"include_chat_session"===e._type)),h=K.useMemo((()=>lL(d)),[d]),{control:f,handleSubmit:m,formState:{errors:g,isSubmitting:y},setError:b,reset:v}=rL({defaultValues:h});K.useEffect((()=>{h&&v(h)}),[v,h]);const k=m((async e=>{const n=s.id&&p&&e[p.name]?s:null;try{await(null==t?void 0:t.buttons.submit.onSubmit({values:e,conversation:n})),r&&c({eventName:"user_escalation_indicated",properties:{escalationType:"support_form",getHelpOptionName:r.name,conversation:n||s}}),i(!0),(null==t?void 0:t.successView)||u()}catch(a){b("root.serverError",{message:a instanceof Error?a.message:"Something went wrong."})}})),w=null==(e=null==g?void 0:g.root)?void 0:e.serverError;return{form:t,openForm:(e,t)=>{n(e),a(t||null)},closeForm:u,handleSubmit:k,isSuccess:o,isSubmitting:y,formError:w,fields:d,errors:g,control:f,defaultValues:h}}();return Wh.jsx(cL.Provider,{value:t,children:e})},dL=()=>{const e=K.useContext(cL);if(!e)throw new Error("useChatForm must be used within a ChatFormProvider");return e},pL=K.createContext(void 0),hL=({children:e,widget:t})=>Wh.jsx(pL.Provider,{value:t,children:e}),fL=()=>K.useContext(pL),mL=e=>{const[t,n]=K.useState(!1);return K.useEffect((()=>{const t=window.matchMedia(e);n(t.matches);const r=e=>n(e.matches);return t.addEventListener("change",r),()=>t.removeEventListener("change",r)}),[e]),t},gL=new TextEncoder;async function yL(e,t){return n=await async function(e,t){return crypto.subtle.digest(e.toUpperCase(),"string"==typeof t?gL.encode(t):new Uint8Array(t))}(e,t),[...new Uint8Array(n)].map((e=>e.toString(16).padStart(2,"0"))).join("");var n}const bL={getSolution:async()=>{},prefetchSolution:()=>{},invalidateSolution:()=>{}},vL=async e=>{try{const t=await fetch(e,{method:"GET"});if(!t.ok)throw new Error(`Failed to fetch challenge: ${t.statusText}`);const n=await t.json(),{challenge:r,algorithm:a,salt:o,maxnumber:i}=n,{promise:s}=await function(e,t,n="SHA-256",r=1e6,a=0){const o=new AbortController,i=Date.now();return{promise:(async()=>{for(let s=a;s<=r;s+=1){if(o.signal.aborted)return null;if(await yL(n,t+s)===e)return{number:s,took:Date.now()-i}}return null})(),controller:o}}(r,o,a,i),l=await s||void 0;if(!l)throw new Error("Challenge not solved");return{number:l.number,...n}}catch(t){console.warn("Error solving captcha:",t)}},kL={type:"function",function:{name:"provideLinks",description:"Provides links",parameters:{type:"object",properties:{links:{anyOf:[{type:"array",items:{type:"object",properties:{label:{type:["string","null"]},url:{type:"string"},title:{type:["string","null"]},description:{type:["string","null"]},type:{anyOf:[{anyOf:[{type:"string",enum:["documentation","site","discourse_post","github_issue","github_discussion","stackoverflow_question","discord_forum_post","discord_message","custom_question_answer"]},{type:"string"}]},{type:"null"}]},breadcrumbs:{anyOf:[{type:"array",items:{type:"string"}},{type:"null"}]}},required:["url"],additionalProperties:!0}},{type:"null"}]},text:{type:"string"}},required:["text"],additionalProperties:!1,$schema:"http://json-schema.org/draft-07/schema#"},function:e=>e,parse:JSON.parse}},wL=e=>{if("string"==typeof e)try{return JSON.parse(e)}catch(X4){return e}return e},xL=(...e)=>(...t)=>{for(const n of e)null==n||n(...t)},EL=e=>"string"==typeof e;function _L(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").replace(/([A-Z])([A-Z][a-z])/g,"$1-$2").replace(/__/g,"__").toLowerCase()}const SL=e=>e?"":void 0;function TL(e){const t=e.split(" "),n=t[0]??"",r=t.length>1?t[t.length-1]:"";return n&&r?`${n.charAt(0)}${r.charAt(0)}`:n.charAt(0)}function CL(e,t){return"function"==typeof e?e(t):e}const AL=e=>"string"==typeof e.content?e.content:e.content[0].text,NL=()=>{const{chatId:e,isSharedChat:t,setConversation:n,conversation:r,resetConversation:a}=iP(),{baseSettings:o,aiChatSettings:i}=nP(),{aiApiBaseUrl:s,shouldBypassCaptcha:l,filters:c}=o,u=iL(),{getSolution:d,prefetchSolution:p,invalidateSolution:h}=(({fetchUrl:e,shouldBypassCaptcha:t=!1,shouldMakeInitialRequest:n=!0})=>{if(t)return bL;const r=K.useRef(null),a=K.useCallback((()=>{r.current||(r.current=vL(e))}),[e]),o=K.useCallback((async()=>{let t=await r.current;return t||(r.current=vL(e),t=await r.current),r.current=null,t}),[e]),i=K.useCallback((()=>{r.current=null}),[]);return K.useEffect((()=>{n&&a()}),[a,n]),{getSolution:o,prefetchSolution:a,invalidateSolution:i}})({fetchUrl:`${s}/v1/challenge`,shouldBypassCaptcha:l,shouldMakeInitialRequest:!u||u.isOpen}),f=new fb({baseURL:`${s}/v1`,apiKey:o.apiKey??"",dangerouslyAllowBrowser:!0}),{onInputMessageChange:m,getTools:g,prompts:y,model:b,filters:v,onToolCall:k}=i,[w,x]=K.useState(""),E=K.useRef(null);K.useEffect((()=>{null==m||m(w)}),[w]);const[_,S]=K.useState([]),[T,C]=K.useState(!1),[A,N]=K.useState(!1),[I,R]=K.useState(null),[O,P]=K.useState(null),[D,L]=K.useState([]),[M,F]=K.useState({}),j=K.useRef([]),B=K.useRef(null),{logEvent:z}=wP(),H=null==y?void 0:y.map(((e,t)=>({id:`system-${Date.now().toString()}-${Zh(4)}-${t}`,role:"system",content:e}))),[U,$]=K.useState(!!e);K.useEffect((()=>{if(e){const{apiKey:t,analyticsApiBaseUrl:r}=o;(async function(e,t,n){try{const r=`${n}/conversations/${e}`,a=await fetch(r,{headers:{"Content-Type":"application/json",Authorization:`Bearer ${t}`}});if(!a.ok){const e=await a.text();throw new Error(`Failed to get conversation: ${e}`)}return a.json()}catch(I){console.warn("Error in getConversation:",I)}})(e,t,r).then((e=>{if(e){z({eventName:"shared_chat_loaded",properties:{conversation:e}}),$(!1),n({...e});const t=e.messages.map((e=>({...e,content:wL(e.content)})));S(t),j.current=t}}))}}),[e]);const G=e=>{R(e),S((t=>{const n=[...t],r=n[n.length-1];return r&&(r.content=(e=>{switch(e.code){case 400:return e.message;case 403:return`There seems to be a configuration error. Please contact ${o.organizationDisplayName??"Administrator"}`;default:return"Hmm.. \n\nIt seems I might be having some issues right now. Please clear the chat and try again."}})(e)),n})),C(!1),N(!1),h(),p()},V=!w.trim()&&!D.length||T,q=async(n=w)=>{if(V&&(!n||0===n.trim().length))return;C(!0);const a=O?2===_.length:0===_.length,o=function(e,t,n){if(!e)return;const r=n?xP(e):"",a=CP(t),o={workflow:AP(e),attachments:t};return{context:NP([r,a]),attributes:o}}(O,D,a);let i;const s=CP(D);i=D.length&&s?[{type:"text",text:s}]:n;const u={id:`${Date.now().toString()}-${Zh(4)}-1`,role:"user",content:i,metadata:o},h=[..._.length?[]:H,u];if(t&&e){RP();const e=j.current.map(((e,t)=>({id:`${e.id}-${Zh(6)}-${t}`,role:e.role,..."assistant"===e.role?{links:e.links??[]}:{},content:e.content,metadata:e.metadata,tool_calls:e.tool_calls})));S([...e,...h]),j.current=[...e,...h]}else S((e=>[...e,...h])),j.current=[...j.current,...h];L([]),x(""),z({eventName:"user_message_submitted",properties:{}},j.current);const m=[kL,...(null==g?void 0:g({conversation:r}))||[]];try{const e={model:b,messages:j.current,stream:!0,tools:m,tool_choice:"auto"},t=await d(),n=t?btoa(JSON.stringify(t)):null,a=c||v?JSON.stringify({...c,...v}):void 0,o={};!l&&n&&(o["X-INKEEP-CHALLENGE-SOLUTION"]=n),a&&(o["inkeep-filters"]=a);const i=f.beta.chat.completions.stream(e,Object.keys(o).length>0?{headers:o}:void 0),s={id:`${Date.now().toString()}-${Zh(4)}-2`,role:"assistant",content:"",links:[],tool_calls:[]};S((e=>[...e,s])),i.on("content",((e,t)=>{N(!0),s.content=t,S((e=>{const t=[...e],n=t.findIndex((e=>e.id===s.id));return-1===n?[...t,s]:(t[n]={...s},t)}))})),i.on("tool_calls.function.arguments.done",(async e=>{var t,n,a,o;const{name:l,arguments:c}=e,u=null==m?void 0:m.find((e=>e.function.name===l));if(!u)return;const d=("parse"in u.function?u.function.parse:JSON.parse)(c),p=null==(n=(t=u.function).function)?void 0:n.call(t,d,i),h=(null==(a=u.renderMessageButtons)?void 0:a.call(u,{args:d,execution:p}))??[];"provideLinks"===l?s.links=d.links??[]:F((e=>({...e,[s.id]:[...e[s.id]??[],...h]}))),null==(o=s.tool_calls)||o.push({id:"call_"+Zh(24),type:"function",function:{name:l,arguments:c}}),S((e=>{const t=[...e],n=t.findIndex((e=>e.id===s.id));return t[n]={...s},t})),null==k||k(e,{conversation:{...r,messages:[...j.current,s]}})})),i.on("error",G),i.finalChatCompletion().then((async()=>{j.current=[...j.current,s],B.current=null,C(!1),N(!1),p(),await z({eventName:"assistant_message_received",properties:{}},j.current),z({eventName:"assistant_answer_displayed",properties:{}})})).catch((e=>{e instanceof Of||console.warn(e)})),B.current=i.controller}catch(y){G(y),C(!1),N(!1)}},W=()=>{R(null),S([]),j.current=[],a(),F({}),L([]),RP(),P(null),h(),p(),z({eventName:"chat_clear_button_clicked",properties:{conversation:r}})},{openForm:Y}=dL(),X=fL();K.useImperativeHandle(i.chatFunctionsRef,(()=>({submitMessage:q,updateInputMessage(e){x(e)},clearChat:W,openForm:e=>{null==X||X.setView("chat"),Y(e)},focusInput:()=>{var e;null==(e=E.current)||e.focus()}})));const Q=mL("(max-width: 768px)");return{messages:_,input:w,isLoading:T,isStreaming:A,isLoadingConversation:U,error:I,isSubmitDisabled:V,handleInputChange:e=>{const t=e.target.value;x(t)},handleInputKeyDown:e=>{"Enter"!==e.key||e.shiftKey||V||e.nativeEvent.isComposing||(e.preventDefault(),q())},handleSubmit:q,stop:()=>{B.current&&(B.current.abort(),B.current=null),C(!1),N(!1),p()},clear:W,handleWorkflow:e=>{P(e);const{initialReplyMessage:t,displayName:n}=e,r={id:_.length.toString()+Zh(4),role:"user",content:n},a={id:(_.length+1).toString()+Zh(4),role:"assistant",content:t,links:[]},o=[{id:`system-${Date.now().toString()}-${Zh(4)}-${e.id}`,role:"system",content:`Company has asked user to follow this guided workflow:\n${xP(e)}`},...H,r,a];S(o),L([])},selectedWorkflow:O,messageAttachments:D,setMessageAttachments:L,addAttachment:e=>{L((t=>[...t,e]))},messageButtons:M,isEmpty:0===_.length,inputRef:E,isMobile:Q}};const IL=K.createContext(void 0);function RL(){const{baseSettings:e}=nP(),{apiKey:t,analyticsApiBaseUrl:n,analyticsProperties:r}=e,[a,o]=K.useState(null),[i,s]=K.useState({}),{conversation:l}=iP(),{messages:c,selectedWorkflow:u}=$j(),{userProperties:d}=mP(),{logEvent:p}=wP(),h=K.useCallback((async(e,a,o=[])=>{const i=await async function(e){try{const{type:t,messageId:n,reasons:r=[],apiKey:a,apiUrl:o,userProperties:i,properties:s}=e,l=`${o}/feedback`,c={type:t,messageId:n,createdAt:(new Date).toISOString(),userProperties:i,properties:s};"negative"===t&&(c.reasons=r);const u=await fetch(l,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${a}`},body:JSON.stringify(c)});if(!u.ok){const e=await u.text();throw new Error(`Failed to send feedback: ${e}`)}return u.json()}catch(t){console.warn("Error in submitFeedback:",t)}}({type:a,messageId:e,reasons:o,apiKey:t,apiUrl:n,userProperties:d,properties:r});i&&s((t=>({...t,[e]:{type:i.type,reasons:i.reasons}})));const h=c.findIndex((t=>t.id===e)),f=c[h],m={conversationId:l.id,question:AL(c[h-1]),answer:AL(f),messageId:e,reasons:o,workflowId:null==u?void 0:u.id};p({eventName:"positive"===a?"assistant_positive_feedback_submitted":"assistant_negative_feedback_submitted",properties:m}),"negative"===a&&p({eventName:"user_escalation_indicated",properties:{escalationType:"downvote",conversation:l}})}),[c,l]);return{feedback:i,currentFeedback:a,setCurrentFeedback:o,submitPositiveFeedback:K.useCallback((async e=>{h(e,"positive")}),[h]),submitNegativeFeedback:K.useCallback((async(e,t)=>{const n=function(e){const t=[];for(const n in e){"on"===e[n]&&t.push({label:n,details:e[`${n}:description`]||""})}return t.length>0?t:[]}(t);h(e,"negative",n)}),[h])}}const OL=({children:e})=>{const t=RL();return Wh.jsx(IL.Provider,{value:t,children:e})},PL=()=>{const e=K.useContext(IL);if(!e)throw new Error("useFeedback must be used within a FeedbackProvider");return e};function DL(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}function LL(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function ML(...e){return t=>{let n=!1;const r=e.map((e=>{const r=LL(e,t);return n||"function"!=typeof r||(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():LL(e[t],null)}}}}function FL(...e){return K.useCallback(ML(...e),e)}function jL(e,t=[]){let n=[];const r=()=>{const t=n.map((e=>K.createContext(e)));return function(n){const r=(null==n?void 0:n[e])||t;return K.useMemo((()=>({[`__scope${e}`]:{...n,[e]:r}})),[n,r])}};return r.scopeName=e,[function(t,r){const a=K.createContext(r),o=n.length;n=[...n,r];const i=t=>{var n;const{scope:r,children:i,...s}=t,l=(null==(n=null==r?void 0:r[e])?void 0:n[o])||a,c=K.useMemo((()=>s),Object.values(s));return Wh.jsx(l.Provider,{value:c,children:i})};return i.displayName=t+"Provider",[i,function(n,i){var s;const l=(null==(s=null==i?void 0:i[e])?void 0:s[o])||a,c=K.useContext(l);if(c)return c;if(void 0!==r)return r;throw new Error(`\`${n}\` must be used within \`${t}\``)}]},BL(r,...t)]}function BL(...e){const t=e[0];if(1===e.length)return t;const n=()=>{const n=e.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(e){const r=n.reduce(((t,{useScope:n,scopeName:r})=>({...t,...n(e)[`__scope${r}`]})),{});return K.useMemo((()=>({[`__scope${t.scopeName}`]:r})),[r])}};return n.scopeName=t.scopeName,n}var zL=K.forwardRef(((e,t)=>{const{children:n,...r}=e,a=K.Children.toArray(n),o=a.find($L);if(o){const e=o.props.children,n=a.map((t=>t===o?K.Children.count(e)>1?K.Children.only(null):K.isValidElement(e)?e.props.children:null:t));return Wh.jsx(HL,{...r,ref:t,children:K.isValidElement(e)?K.cloneElement(e,void 0,n):null})}return Wh.jsx(HL,{...r,ref:t,children:n})}));zL.displayName="Slot";var HL=K.forwardRef(((e,t)=>{const{children:n,...r}=e;if(K.isValidElement(n)){const e=function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;if(a)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a)return e.props.ref;return e.props.ref||e.ref}(n);return K.cloneElement(n,{...GL(r,n.props),ref:t?ML(t,e):e})}return K.Children.count(n)>1?K.Children.only(null):null}));HL.displayName="SlotClone";var UL=({children:e})=>Wh.jsx(Wh.Fragment,{children:e});function $L(e){return K.isValidElement(e)&&e.type===UL}function GL(e,t){const n={...t};for(const r in t){const a=e[r],o=t[r];/^on[A-Z]/.test(r)?a&&o?n[r]=(...e)=>{o(...e),a(...e)}:a&&(n[r]=a):"style"===r?n[r]={...a,...o}:"className"===r&&(n[r]=[a,o].filter(Boolean).join(" "))}return{...e,...n}}var VL=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce(((e,t)=>{const n=K.forwardRef(((e,n)=>{const{asChild:r,...a}=e,o=r?zL:t;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),Wh.jsx(o,{...a,ref:n})}));return n.displayName=`Primitive.${t}`,{...e,[t]:n}}),{});function qL(e){const t=K.useRef(e);return K.useEffect((()=>{t.current=e})),K.useMemo((()=>(...e)=>{var n;return null==(n=t.current)?void 0:n.call(t,...e)}),[])}function WL(e,t=(null==globalThis?void 0:globalThis.document)){const n=qL(e);K.useEffect((()=>{const e=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",e,{capture:!0}),()=>t.removeEventListener("keydown",e,{capture:!0})}),[n,t])}var YL,KL="dismissableLayer.update",XL="dismissableLayer.pointerDownOutside",QL="dismissableLayer.focusOutside",ZL=K.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),JL=K.forwardRef(((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:a,onFocusOutside:o,onInteractOutside:i,onDismiss:s,...l}=e,c=K.useContext(ZL),[u,d]=K.useState(null),p=(null==u?void 0:u.ownerDocument)??(null==globalThis?void 0:globalThis.document),[,h]=K.useState({}),f=FL(t,(e=>d(e))),m=Array.from(c.layers),[g]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),y=m.indexOf(g),b=u?m.indexOf(u):-1,v=c.layersWithOutsidePointerEventsDisabled.size>0,k=b>=y,w=function(e,t=(null==globalThis?void 0:globalThis.document)){const n=qL(e),r=K.useRef(!1),a=K.useRef((()=>{}));return K.useEffect((()=>{const e=e=>{if(e.target&&!r.current){let r=function(){nM(XL,n,o,{discrete:!0})};const o={originalEvent:e};"touch"===e.pointerType?(t.removeEventListener("click",a.current),a.current=r,t.addEventListener("click",a.current,{once:!0})):r()}else t.removeEventListener("click",a.current);r.current=!1},o=window.setTimeout((()=>{t.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(o),t.removeEventListener("pointerdown",e),t.removeEventListener("click",a.current)}}),[t,n]),{onPointerDownCapture:()=>r.current=!0}}((e=>{const t=e.target,n=[...c.branches].some((e=>e.contains(t)));k&&!n&&(null==a||a(e),null==i||i(e),e.defaultPrevented||null==s||s())}),p),x=function(e,t=(null==globalThis?void 0:globalThis.document)){const n=qL(e),r=K.useRef(!1);return K.useEffect((()=>{const e=e=>{if(e.target&&!r.current){nM(QL,n,{originalEvent:e},{discrete:!1})}};return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)}),[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}((e=>{const t=e.target;[...c.branches].some((e=>e.contains(t)))||(null==o||o(e),null==i||i(e),e.defaultPrevented||null==s||s())}),p);return WL((e=>{b===c.layers.size-1&&(null==r||r(e),!e.defaultPrevented&&s&&(e.preventDefault(),s()))}),p),K.useEffect((()=>{if(u)return n&&(0===c.layersWithOutsidePointerEventsDisabled.size&&(YL=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(u)),c.layers.add(u),tM(),()=>{n&&1===c.layersWithOutsidePointerEventsDisabled.size&&(p.body.style.pointerEvents=YL)}}),[u,p,n,c]),K.useEffect((()=>()=>{u&&(c.layers.delete(u),c.layersWithOutsidePointerEventsDisabled.delete(u),tM())}),[u,c]),K.useEffect((()=>{const e=()=>h({});return document.addEventListener(KL,e),()=>document.removeEventListener(KL,e)}),[]),Wh.jsx(VL.div,{...l,ref:f,style:{pointerEvents:v?k?"auto":"none":void 0,...e.style},onFocusCapture:DL(e.onFocusCapture,x.onFocusCapture),onBlurCapture:DL(e.onBlurCapture,x.onBlurCapture),onPointerDownCapture:DL(e.onPointerDownCapture,w.onPointerDownCapture)})}));JL.displayName="DismissableLayer";var eM=K.forwardRef(((e,t)=>{const n=K.useContext(ZL),r=K.useRef(null),a=FL(t,r);return K.useEffect((()=>{const e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}}),[n.branches]),Wh.jsx(VL.div,{...e,ref:a})}));function tM(){const e=new CustomEvent(KL);document.dispatchEvent(e)}function nM(e,t,n,{discrete:r}){const a=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&a.addEventListener(e,t,{once:!0}),r?function(e,t){e&&se.flushSync((()=>e.dispatchEvent(t)))}(a,o):a.dispatchEvent(o)}eM.displayName="DismissableLayerBranch";var rM=Boolean(null==globalThis?void 0:globalThis.document)?K.useLayoutEffect:()=>{},aM=Q["useId".toString()]||(()=>{}),oM=0;function iM(e){const[t,n]=K.useState(aM());return rM((()=>{n((e=>e??String(oM++)))}),[e]),e||(t?`radix-${t}`:"")}const sM=["top","right","bottom","left"],lM=Math.min,cM=Math.max,uM=Math.round,dM=Math.floor,pM=e=>({x:e,y:e}),hM={left:"right",right:"left",bottom:"top",top:"bottom"},fM={start:"end",end:"start"};function mM(e,t,n){return cM(e,lM(t,n))}function gM(e,t){return"function"==typeof e?e(t):e}function yM(e){return e.split("-")[0]}function bM(e){return e.split("-")[1]}function vM(e){return"x"===e?"y":"x"}function kM(e){return"y"===e?"height":"width"}function wM(e){return["top","bottom"].includes(yM(e))?"y":"x"}function xM(e){return vM(wM(e))}function EM(e){return e.replace(/start|end/g,(e=>fM[e]))}function _M(e){return e.replace(/left|right|bottom|top/g,(e=>hM[e]))}function SM(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}function TM(e){const{x:t,y:n,width:r,height:a}=e;return{width:r,height:a,top:n,left:t,right:t+r,bottom:n+a,x:t,y:n}}function CM(e,t,n){let{reference:r,floating:a}=e;const o=wM(t),i=xM(t),s=kM(i),l=yM(t),c="y"===o,u=r.x+r.width/2-a.width/2,d=r.y+r.height/2-a.height/2,p=r[s]/2-a[s]/2;let h;switch(l){case"top":h={x:u,y:r.y-a.height};break;case"bottom":h={x:u,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:d};break;case"left":h={x:r.x-a.width,y:d};break;default:h={x:r.x,y:r.y}}switch(bM(t)){case"start":h[i]-=p*(n&&c?-1:1);break;case"end":h[i]+=p*(n&&c?-1:1)}return h}async function AM(e,t){var n;void 0===t&&(t={});const{x:r,y:a,platform:o,rects:i,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:p=!1,padding:h=0}=gM(t,e),f=SM(h),m=s[p?"floating"===d?"reference":"floating":d],g=TM(await o.getClippingRect({element:null==(n=await(null==o.isElement?void 0:o.isElement(m)))||n?m:m.contextElement||await(null==o.getDocumentElement?void 0:o.getDocumentElement(s.floating)),boundary:c,rootBoundary:u,strategy:l})),y="floating"===d?{x:r,y:a,width:i.floating.width,height:i.floating.height}:i.reference,b=await(null==o.getOffsetParent?void 0:o.getOffsetParent(s.floating)),v=await(null==o.isElement?void 0:o.isElement(b))&&await(null==o.getScale?void 0:o.getScale(b))||{x:1,y:1},k=TM(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:y,offsetParent:b,strategy:l}):y);return{top:(g.top-k.top+f.top)/v.y,bottom:(k.bottom-g.bottom+f.bottom)/v.y,left:(g.left-k.left+f.left)/v.x,right:(k.right-g.right+f.right)/v.x}}function NM(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function IM(e){return sM.some((t=>e[t]>=0))}function RM(){return"undefined"!=typeof window}function OM(e){return LM(e)?(e.nodeName||"").toLowerCase():"#document"}function PM(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function DM(e){var t;return null==(t=(LM(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function LM(e){return!!RM()&&(e instanceof Node||e instanceof PM(e).Node)}function MM(e){return!!RM()&&(e instanceof Element||e instanceof PM(e).Element)}function FM(e){return!!RM()&&(e instanceof HTMLElement||e instanceof PM(e).HTMLElement)}function jM(e){return!(!RM()||"undefined"==typeof ShadowRoot)&&(e instanceof ShadowRoot||e instanceof PM(e).ShadowRoot)}function BM(e){const{overflow:t,overflowX:n,overflowY:r,display:a}=VM(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(a)}function zM(e){return["table","td","th"].includes(OM(e))}function HM(e){return[":popover-open",":modal"].some((t=>{try{return e.matches(t)}catch(X4){return!1}}))}function UM(e){const t=$M(),n=MM(e)?VM(e):e;return["transform","translate","scale","rotate","perspective"].some((e=>!!n[e]&&"none"!==n[e]))||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||["transform","translate","scale","rotate","perspective","filter"].some((e=>(n.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(n.contain||"").includes(e)))}function $M(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function GM(e){return["html","body","#document"].includes(OM(e))}function VM(e){return PM(e).getComputedStyle(e)}function qM(e){return MM(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function WM(e){if("html"===OM(e))return e;const t=e.assignedSlot||e.parentNode||jM(e)&&e.host||DM(e);return jM(t)?t.host:t}function YM(e){const t=WM(e);return GM(t)?e.ownerDocument?e.ownerDocument.body:e.body:FM(t)&&BM(t)?t:YM(t)}function KM(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);const a=YM(e),o=a===(null==(r=e.ownerDocument)?void 0:r.body),i=PM(a);if(o){const e=XM(i);return t.concat(i,i.visualViewport||[],BM(a)?a:[],e&&n?KM(e):[])}return t.concat(a,KM(a,[],n))}function XM(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function QM(e){const t=VM(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const a=FM(e),o=a?e.offsetWidth:n,i=a?e.offsetHeight:r,s=uM(n)!==o||uM(r)!==i;return s&&(n=o,r=i),{width:n,height:r,$:s}}function ZM(e){return MM(e)?e:e.contextElement}function JM(e){const t=ZM(e);if(!FM(t))return pM(1);const n=t.getBoundingClientRect(),{width:r,height:a,$:o}=QM(t);let i=(o?uM(n.width):n.width)/r,s=(o?uM(n.height):n.height)/a;return i&&Number.isFinite(i)||(i=1),s&&Number.isFinite(s)||(s=1),{x:i,y:s}}const eF=pM(0);function tF(e){const t=PM(e);return $M()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:eF}function nF(e,t,n,r){void 0===t&&(t=!1),void 0===n&&(n=!1);const a=e.getBoundingClientRect(),o=ZM(e);let i=pM(1);t&&(r?MM(r)&&(i=JM(r)):i=JM(e));const s=function(e,t,n){return void 0===t&&(t=!1),!(!n||t&&n!==PM(e))&&t}(o,n,r)?tF(o):pM(0);let l=(a.left+s.x)/i.x,c=(a.top+s.y)/i.y,u=a.width/i.x,d=a.height/i.y;if(o){const e=PM(o),t=r&&MM(r)?PM(r):r;let n=e,a=XM(n);for(;a&&r&&t!==n;){const e=JM(a),t=a.getBoundingClientRect(),r=VM(a),o=t.left+(a.clientLeft+parseFloat(r.paddingLeft))*e.x,i=t.top+(a.clientTop+parseFloat(r.paddingTop))*e.y;l*=e.x,c*=e.y,u*=e.x,d*=e.y,l+=o,c+=i,n=PM(a),a=XM(n)}}return TM({width:u,height:d,x:l,y:c})}function rF(e,t){const n=qM(e).scrollLeft;return t?t.left+n:nF(DM(e)).left+n}function aF(e,t,n){void 0===n&&(n=!1);const r=e.getBoundingClientRect();return{x:r.left+t.scrollLeft-(n?0:rF(e,r)),y:r.top+t.scrollTop}}function oF(e,t,n){let r;if("viewport"===t)r=function(e,t){const n=PM(e),r=DM(e),a=n.visualViewport;let o=r.clientWidth,i=r.clientHeight,s=0,l=0;if(a){o=a.width,i=a.height;const e=$M();(!e||e&&"fixed"===t)&&(s=a.offsetLeft,l=a.offsetTop)}return{width:o,height:i,x:s,y:l}}(e,n);else if("document"===t)r=function(e){const t=DM(e),n=qM(e),r=e.ownerDocument.body,a=cM(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=cM(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+rF(e);const s=-n.scrollTop;return"rtl"===VM(r).direction&&(i+=cM(t.clientWidth,r.clientWidth)-a),{width:a,height:o,x:i,y:s}}(DM(e));else if(MM(t))r=function(e,t){const n=nF(e,!0,"fixed"===t),r=n.top+e.clientTop,a=n.left+e.clientLeft,o=FM(e)?JM(e):pM(1);return{width:e.clientWidth*o.x,height:e.clientHeight*o.y,x:a*o.x,y:r*o.y}}(t,n);else{const n=tF(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return TM(r)}function iF(e,t){const n=WM(e);return!(n===t||!MM(n)||GM(n))&&("fixed"===VM(n).position||iF(n,t))}function sF(e,t,n){const r=FM(t),a=DM(t),o="fixed"===n,i=nF(e,!0,o,t);let s={scrollLeft:0,scrollTop:0};const l=pM(0);if(r||!r&&!o)if(("body"!==OM(t)||BM(a))&&(s=qM(t)),r){const e=nF(t,!0,o,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}else a&&(l.x=rF(a));const c=!a||r||o?pM(0):aF(a,s);return{x:i.left+s.scrollLeft-l.x-c.x,y:i.top+s.scrollTop-l.y-c.y,width:i.width,height:i.height}}function lF(e){return"static"===VM(e).position}function cF(e,t){if(!FM(e)||"fixed"===VM(e).position)return null;if(t)return t(e);let n=e.offsetParent;return DM(e)===n&&(n=n.ownerDocument.body),n}function uF(e,t){const n=PM(e);if(HM(e))return n;if(!FM(e)){let t=WM(e);for(;t&&!GM(t);){if(MM(t)&&!lF(t))return t;t=WM(t)}return n}let r=cF(e,t);for(;r&&zM(r)&&lF(r);)r=cF(r,t);return r&&GM(r)&&lF(r)&&!UM(r)?n:r||function(e){let t=WM(e);for(;FM(t)&&!GM(t);){if(UM(t))return t;if(HM(t))return null;t=WM(t)}return null}(e)||n}const dF={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:r,strategy:a}=e;const o="fixed"===a,i=DM(r),s=!!t&&HM(t.floating);if(r===i||s&&o)return n;let l={scrollLeft:0,scrollTop:0},c=pM(1);const u=pM(0),d=FM(r);if((d||!d&&!o)&&(("body"!==OM(r)||BM(i))&&(l=qM(r)),FM(r))){const e=nF(r);c=JM(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}const p=!i||d||o?pM(0):aF(i,l,!0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-l.scrollLeft*c.x+u.x+p.x,y:n.y*c.y-l.scrollTop*c.y+u.y+p.y}},getDocumentElement:DM,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:a}=e;const o=[..."clippingAncestors"===n?HM(t)?[]:function(e,t){const n=t.get(e);if(n)return n;let r=KM(e,[],!1).filter((e=>MM(e)&&"body"!==OM(e))),a=null;const o="fixed"===VM(e).position;let i=o?WM(e):e;for(;MM(i)&&!GM(i);){const t=VM(i),n=UM(i);n||"fixed"!==t.position||(a=null),(o?!n&&!a:!n&&"static"===t.position&&a&&["absolute","fixed"].includes(a.position)||BM(i)&&!n&&iF(e,i))?r=r.filter((e=>e!==i)):a=t,i=WM(i)}return t.set(e,r),r}(t,this._c):[].concat(n),r],i=o[0],s=o.reduce(((e,n)=>{const r=oF(t,n,a);return e.top=cM(r.top,e.top),e.right=lM(r.right,e.right),e.bottom=lM(r.bottom,e.bottom),e.left=cM(r.left,e.left),e}),oF(t,i,a));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:uF,getElementRects:async function(e){const t=this.getOffsetParent||uF,n=this.getDimensions,r=await n(e.floating);return{reference:sF(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:n}=QM(e);return{width:t,height:n}},getScale:JM,isElement:MM,isRTL:function(e){return"rtl"===VM(e).direction}};function pF(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function hF(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:a=!0,ancestorResize:o=!0,elementResize:i="function"==typeof ResizeObserver,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:l=!1}=r,c=ZM(e),u=a||o?[...c?KM(c):[],...KM(t)]:[];u.forEach((e=>{a&&e.addEventListener("scroll",n,{passive:!0}),o&&e.addEventListener("resize",n)}));const d=c&&s?function(e,t){let n,r=null;const a=DM(e);function o(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return function i(s,l){void 0===s&&(s=!1),void 0===l&&(l=1),o();const c=e.getBoundingClientRect(),{left:u,top:d,width:p,height:h}=c;if(s||t(),!p||!h)return;const f={rootMargin:-dM(d)+"px "+-dM(a.clientWidth-(u+p))+"px "+-dM(a.clientHeight-(d+h))+"px "+-dM(u)+"px",threshold:cM(0,lM(1,l))||1};let m=!0;function g(t){const r=t[0].intersectionRatio;if(r!==l){if(!m)return i();r?i(!1,r):n=setTimeout((()=>{i(!1,1e-7)}),1e3)}1!==r||pF(c,e.getBoundingClientRect())||i(),m=!1}try{r=new IntersectionObserver(g,{...f,root:a.ownerDocument})}catch(X4){r=new IntersectionObserver(g,f)}r.observe(e)}(!0),o}(c,n):null;let p,h=-1,f=null;i&&(f=new ResizeObserver((e=>{let[r]=e;r&&r.target===c&&f&&(f.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame((()=>{var e;null==(e=f)||e.observe(t)}))),n()})),c&&!l&&f.observe(c),f.observe(t));let m=l?nF(e):null;return l&&function t(){const r=nF(e);m&&!pF(m,r)&&n();m=r,p=requestAnimationFrame(t)}(),n(),()=>{var e;u.forEach((e=>{a&&e.removeEventListener("scroll",n),o&&e.removeEventListener("resize",n)})),null==d||d(),null==(e=f)||e.disconnect(),f=null,l&&cancelAnimationFrame(p)}}const fF=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:a,y:o,placement:i,middlewareData:s}=t,l=await async function(e,t){const{placement:n,platform:r,elements:a}=e,o=await(null==r.isRTL?void 0:r.isRTL(a.floating)),i=yM(n),s=bM(n),l="y"===wM(n),c=["left","top"].includes(i)?-1:1,u=o&&l?-1:1,d=gM(t,e);let{mainAxis:p,crossAxis:h,alignmentAxis:f}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&"number"==typeof f&&(h="end"===s?-1*f:f),l?{x:h*u,y:p*c}:{x:p*c,y:h*u}}(t,e);return i===(null==(n=s.offset)?void 0:n.placement)&&null!=(r=s.arrow)&&r.alignmentOffset?{}:{x:a+l.x,y:o+l.y,data:{...l,placement:i}}}}},mF=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:a}=t,{mainAxis:o=!0,crossAxis:i=!1,limiter:s={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=gM(e,t),c={x:n,y:r},u=await AM(t,l),d=wM(yM(a)),p=vM(d);let h=c[p],f=c[d];if(o){const e="y"===p?"bottom":"right";h=mM(h+u["y"===p?"top":"left"],h,h-u[e])}if(i){const e="y"===d?"bottom":"right";f=mM(f+u["y"===d?"top":"left"],f,f-u[e])}const m=s.fn({...t,[p]:h,[d]:f});return{...m,data:{x:m.x-n,y:m.y-r,enabled:{[p]:o,[d]:i}}}}}},gF=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:a,middlewareData:o,rects:i,initialPlacement:s,platform:l,elements:c}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:p,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:f="none",flipAlignment:m=!0,...g}=gM(e,t);if(null!=(n=o.arrow)&&n.alignmentOffset)return{};const y=yM(a),b=wM(s),v=yM(s)===s,k=await(null==l.isRTL?void 0:l.isRTL(c.floating)),w=p||(v||!m?[_M(s)]:function(e){const t=_M(e);return[EM(e),t,EM(t)]}(s)),x="none"!==f;!p&&x&&w.push(...function(e,t,n,r){const a=bM(e);let o=function(e,t,n){const r=["left","right"],a=["right","left"],o=["top","bottom"],i=["bottom","top"];switch(e){case"top":case"bottom":return n?t?a:r:t?r:a;case"left":case"right":return t?o:i;default:return[]}}(yM(e),"start"===n,r);return a&&(o=o.map((e=>e+"-"+a)),t&&(o=o.concat(o.map(EM)))),o}(s,m,f,k));const E=[s,...w],_=await AM(t,g),S=[];let T=(null==(r=o.flip)?void 0:r.overflows)||[];if(u&&S.push(_[y]),d){const e=function(e,t,n){void 0===n&&(n=!1);const r=bM(e),a=xM(e),o=kM(a);let i="x"===a?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[o]>t.floating[o]&&(i=_M(i)),[i,_M(i)]}(a,i,k);S.push(_[e[0]],_[e[1]])}if(T=[...T,{placement:a,overflows:S}],!S.every((e=>e<=0))){var C,A;const e=((null==(C=o.flip)?void 0:C.index)||0)+1,t=E[e];if(t)return{data:{index:e,overflows:T},reset:{placement:t}};let n=null==(A=T.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:A.placement;if(!n)switch(h){case"bestFit":{var N;const e=null==(N=T.filter((e=>{if(x){const t=wM(e.placement);return t===b||"y"===t}return!0})).map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:N[0];e&&(n=e);break}case"initialPlacement":n=s}if(a!==n)return{reset:{placement:n}}}return{}}}},yF=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:a,rects:o,platform:i,elements:s}=t,{apply:l=()=>{},...c}=gM(e,t),u=await AM(t,c),d=yM(a),p=bM(a),h="y"===wM(a),{width:f,height:m}=o.floating;let g,y;"top"===d||"bottom"===d?(g=d,y=p===(await(null==i.isRTL?void 0:i.isRTL(s.floating))?"start":"end")?"left":"right"):(y=d,g="end"===p?"top":"bottom");const b=m-u.top-u.bottom,v=f-u.left-u.right,k=lM(m-u[g],b),w=lM(f-u[y],v),x=!t.middlewareData.shift;let E=k,_=w;if(null!=(n=t.middlewareData.shift)&&n.enabled.x&&(_=v),null!=(r=t.middlewareData.shift)&&r.enabled.y&&(E=b),x&&!p){const e=cM(u.left,0),t=cM(u.right,0),n=cM(u.top,0),r=cM(u.bottom,0);h?_=f-2*(0!==e||0!==t?e+t:cM(u.left,u.right)):E=m-2*(0!==n||0!==r?n+r:cM(u.top,u.bottom))}await l({...t,availableWidth:_,availableHeight:E});const S=await i.getDimensions(s.floating);return f!==S.width||m!==S.height?{reset:{rects:!0}}:{}}}},bF=function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...a}=gM(e,t);switch(r){case"referenceHidden":{const e=NM(await AM(t,{...a,elementContext:"reference"}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:IM(e)}}}case"escaped":{const e=NM(await AM(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:IM(e)}}}default:return{}}}}},vF=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:a,rects:o,platform:i,elements:s,middlewareData:l}=t,{element:c,padding:u=0}=gM(e,t)||{};if(null==c)return{};const d=SM(u),p={x:n,y:r},h=xM(a),f=kM(h),m=await i.getDimensions(c),g="y"===h,y=g?"top":"left",b=g?"bottom":"right",v=g?"clientHeight":"clientWidth",k=o.reference[f]+o.reference[h]-p[h]-o.floating[f],w=p[h]-o.reference[h],x=await(null==i.getOffsetParent?void 0:i.getOffsetParent(c));let E=x?x[v]:0;E&&await(null==i.isElement?void 0:i.isElement(x))||(E=s.floating[v]||o.floating[f]);const _=k/2-w/2,S=E/2-m[f]/2-1,T=lM(d[y],S),C=lM(d[b],S),A=T,N=E-m[f]-C,I=E/2-m[f]/2+_,R=mM(A,I,N),O=!l.arrow&&null!=bM(a)&&I!==R&&o.reference[f]/2-(I<A?T:C)-m[f]/2<0,P=O?I<A?I-A:I-N:0;return{[h]:p[h]+P,data:{[h]:R,centerOffset:I-R-P,...O&&{alignmentOffset:P}},reset:O}}}),kF=function(e){return void 0===e&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:a,rects:o,middlewareData:i}=t,{offset:s=0,mainAxis:l=!0,crossAxis:c=!0}=gM(e,t),u={x:n,y:r},d=wM(a),p=vM(d);let h=u[p],f=u[d];const m=gM(s,t),g="number"==typeof m?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(l){const e="y"===p?"height":"width",t=o.reference[p]-o.floating[e]+g.mainAxis,n=o.reference[p]+o.reference[e]-g.mainAxis;h<t?h=t:h>n&&(h=n)}if(c){var y,b;const e="y"===p?"width":"height",t=["top","left"].includes(yM(a)),n=o.reference[d]-o.floating[e]+(t&&(null==(y=i.offset)?void 0:y[d])||0)+(t?0:g.crossAxis),r=o.reference[d]+o.reference[e]+(t?0:(null==(b=i.offset)?void 0:b[d])||0)-(t?g.crossAxis:0);f<n?f=n:f>r&&(f=r)}return{[p]:h,[d]:f}}}},wF=(e,t,n)=>{const r=new Map,a={platform:dF,...n},o={...a.platform,_c:r};return(async(e,t,n)=>{const{placement:r="bottom",strategy:a="absolute",middleware:o=[],platform:i}=n,s=o.filter(Boolean),l=await(null==i.isRTL?void 0:i.isRTL(t));let c=await i.getElementRects({reference:e,floating:t,strategy:a}),{x:u,y:d}=CM(c,r,l),p=r,h={},f=0;for(let m=0;m<s.length;m++){const{name:n,fn:o}=s[m],{x:g,y:y,data:b,reset:v}=await o({x:u,y:d,initialPlacement:r,placement:p,strategy:a,middlewareData:h,rects:c,platform:i,elements:{reference:e,floating:t}});u=null!=g?g:u,d=null!=y?y:d,h={...h,[n]:{...h[n],...b}},v&&f<=50&&(f++,"object"==typeof v&&(v.placement&&(p=v.placement),v.rects&&(c=!0===v.rects?await i.getElementRects({reference:e,floating:t,strategy:a}):v.rects),({x:u,y:d}=CM(c,p,l))),m=-1)}return{x:u,y:d,placement:p,strategy:a,middlewareData:h}})(e,t,{...a,platform:o})};var xF="undefined"!=typeof document?K.useLayoutEffect:K.useEffect;function EF(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let n,r,a;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;0!=r--;)if(!EF(e[r],t[r]))return!1;return!0}if(a=Object.keys(e),n=a.length,n!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!{}.hasOwnProperty.call(t,a[r]))return!1;for(r=n;0!=r--;){const n=a[r];if(("_owner"!==n||!e.$$typeof)&&!EF(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function _F(e){if("undefined"==typeof window)return 1;return(e.ownerDocument.defaultView||window).devicePixelRatio||1}function SF(e,t){const n=_F(e);return Math.round(t*n)/n}function TF(e){const t=K.useRef(e);return xF((()=>{t.current=e})),t}function CF(e){void 0===e&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:a,elements:{reference:o,floating:i}={},transform:s=!0,whileElementsMounted:l,open:c}=e,[u,d]=K.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,h]=K.useState(r);EF(p,r)||h(r);const[f,m]=K.useState(null),[g,y]=K.useState(null),b=K.useCallback((e=>{e!==x.current&&(x.current=e,m(e))}),[]),v=K.useCallback((e=>{e!==E.current&&(E.current=e,y(e))}),[]),k=o||f,w=i||g,x=K.useRef(null),E=K.useRef(null),_=K.useRef(u),S=null!=l,T=TF(l),C=TF(a),A=TF(c),N=K.useCallback((()=>{if(!x.current||!E.current)return;const e={placement:t,strategy:n,middleware:p};C.current&&(e.platform=C.current),wF(x.current,E.current,e).then((e=>{const t={...e,isPositioned:!1!==A.current};I.current&&!EF(_.current,t)&&(_.current=t,se.flushSync((()=>{d(t)})))}))}),[p,t,n,C,A]);xF((()=>{!1===c&&_.current.isPositioned&&(_.current.isPositioned=!1,d((e=>({...e,isPositioned:!1}))))}),[c]);const I=K.useRef(!1);xF((()=>(I.current=!0,()=>{I.current=!1})),[]),xF((()=>{if(k&&(x.current=k),w&&(E.current=w),k&&w){if(T.current)return T.current(k,w,N);N()}}),[k,w,N,T,S]);const R=K.useMemo((()=>({reference:x,floating:E,setReference:b,setFloating:v})),[b,v]),O=K.useMemo((()=>({reference:k,floating:w})),[k,w]),P=K.useMemo((()=>{const e={position:n,left:0,top:0};if(!O.floating)return e;const t=SF(O.floating,u.x),r=SF(O.floating,u.y);return s?{...e,transform:"translate("+t+"px, "+r+"px)",..._F(O.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}}),[n,s,O.floating,u.x,u.y]);return K.useMemo((()=>({...u,update:N,refs:R,elements:O,floatingStyles:P})),[u,N,R,O,P])}const AF=e=>({name:"arrow",options:e,fn(t){const{element:n,padding:r}="function"==typeof e?e(t):e;return n&&(a=n,{}.hasOwnProperty.call(a,"current"))?null!=n.current?vF({element:n.current,padding:r}).fn(t):{}:n?vF({element:n,padding:r}).fn(t):{};var a}}),NF=(e,t)=>({...fF(e),options:[e,t]}),IF=(e,t)=>({...mF(e),options:[e,t]}),RF=(e,t)=>({...kF(e),options:[e,t]}),OF=(e,t)=>({...gF(e),options:[e,t]}),PF=(e,t)=>({...yF(e),options:[e,t]}),DF=(e,t)=>({...bF(e),options:[e,t]}),LF=(e,t)=>({...AF(e),options:[e,t]});var MF=K.forwardRef(((e,t)=>{const{children:n,width:r=10,height:a=5,...o}=e;return Wh.jsx(VL.svg,{...o,ref:t,width:r,height:a,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:Wh.jsx("polygon",{points:"0,0 30,0 15,10"})})}));MF.displayName="Arrow";var FF=MF;function jF(e){const[t,n]=K.useState(void 0);return rM((()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const t=new ResizeObserver((t=>{if(!Array.isArray(t))return;if(!t.length)return;const r=t[0];let a,o;if("borderBoxSize"in r){const e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;a=t.inlineSize,o=t.blockSize}else a=e.offsetWidth,o=e.offsetHeight;n({width:a,height:o})}));return t.observe(e,{box:"border-box"}),()=>t.unobserve(e)}n(void 0)}),[e]),t}var BF="Popper",[zF,HF]=jL(BF),[UF,$F]=zF(BF),GF=e=>{const{__scopePopper:t,children:n}=e,[r,a]=K.useState(null);return Wh.jsx(UF,{scope:t,anchor:r,onAnchorChange:a,children:n})};GF.displayName=BF;var VF="PopperAnchor",qF=K.forwardRef(((e,t)=>{const{__scopePopper:n,virtualRef:r,...a}=e,o=$F(VF,n),i=K.useRef(null),s=FL(t,i);return K.useEffect((()=>{o.onAnchorChange((null==r?void 0:r.current)||i.current)})),r?null:Wh.jsx(VL.div,{...a,ref:s})}));qF.displayName=VF;var WF="PopperContent",[YF,KF]=zF(WF),XF=K.forwardRef(((e,t)=>{var n,r,a,o,i,s;const{__scopePopper:l,side:c="bottom",sideOffset:u=0,align:d="center",alignOffset:p=0,arrowPadding:h=0,avoidCollisions:f=!0,collisionBoundary:m=[],collisionPadding:g=0,sticky:y="partial",hideWhenDetached:b=!1,updatePositionStrategy:v="optimized",onPlaced:k,...w}=e,x=$F(WF,l),[E,_]=K.useState(null),S=FL(t,(e=>_(e))),[T,C]=K.useState(null),A=jF(T),N=(null==A?void 0:A.width)??0,I=(null==A?void 0:A.height)??0,R=c+("center"!==d?"-"+d:""),O="number"==typeof g?g:{top:0,right:0,bottom:0,left:0,...g},P=Array.isArray(m)?m:[m],D=P.length>0,L={padding:O,boundary:P.filter(ej),altBoundary:D},{refs:M,floatingStyles:F,placement:j,isPositioned:B,middlewareData:z}=CF({strategy:"fixed",placement:R,whileElementsMounted:(...e)=>hF(...e,{animationFrame:"always"===v}),elements:{reference:x.anchor},middleware:[NF({mainAxis:u+I,alignmentAxis:p}),f&&IF({mainAxis:!0,crossAxis:!1,limiter:"partial"===y?RF():void 0,...L}),f&&OF({...L}),PF({...L,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{const{width:a,height:o}=t.reference,i=e.floating.style;i.setProperty("--radix-popper-available-width",`${n}px`),i.setProperty("--radix-popper-available-height",`${r}px`),i.setProperty("--radix-popper-anchor-width",`${a}px`),i.setProperty("--radix-popper-anchor-height",`${o}px`)}}),T&&LF({element:T,padding:h}),tj({arrowWidth:N,arrowHeight:I}),b&&DF({strategy:"referenceHidden",...L})]}),[H,U]=nj(j),$=qL(k);rM((()=>{B&&(null==$||$())}),[B,$]);const G=null==(n=z.arrow)?void 0:n.x,V=null==(r=z.arrow)?void 0:r.y,q=0!==(null==(a=z.arrow)?void 0:a.centerOffset),[W,Y]=K.useState();return rM((()=>{E&&Y(window.getComputedStyle(E).zIndex)}),[E]),Wh.jsx("div",{ref:M.setFloating,"data-radix-popper-content-wrapper":"",style:{...F,transform:B?F.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:W,"--radix-popper-transform-origin":[null==(o=z.transformOrigin)?void 0:o.x,null==(i=z.transformOrigin)?void 0:i.y].join(" "),...(null==(s=z.hide)?void 0:s.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:Wh.jsx(YF,{scope:l,placedSide:H,onArrowChange:C,arrowX:G,arrowY:V,shouldHideArrow:q,children:Wh.jsx(VL.div,{"data-side":H,"data-align":U,...w,ref:S,style:{...w.style,animation:B?void 0:"none"}})})})}));XF.displayName=WF;var QF="PopperArrow",ZF={top:"bottom",right:"left",bottom:"top",left:"right"},JF=K.forwardRef((function(e,t){const{__scopePopper:n,...r}=e,a=KF(QF,n),o=ZF[a.placedSide];return Wh.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:Wh.jsx(FF,{...r,ref:t,style:{...r.style,display:"block"}})})}));function ej(e){return null!==e}JF.displayName=QF;var tj=e=>({name:"transformOrigin",options:e,fn(t){var n,r,a;const{placement:o,rects:i,middlewareData:s}=t,l=0!==(null==(n=s.arrow)?void 0:n.centerOffset),c=l?0:e.arrowWidth,u=l?0:e.arrowHeight,[d,p]=nj(o),h={start:"0%",center:"50%",end:"100%"}[p],f=((null==(r=s.arrow)?void 0:r.x)??0)+c/2,m=((null==(a=s.arrow)?void 0:a.y)??0)+u/2;let g="",y="";return"bottom"===d?(g=l?h:`${f}px`,y=-u+"px"):"top"===d?(g=l?h:`${f}px`,y=`${i.floating.height+u}px`):"right"===d?(g=-u+"px",y=l?h:`${m}px`):"left"===d&&(g=`${i.floating.width+u}px`,y=l?h:`${m}px`),{data:{x:g,y:y}}}});function nj(e){const[t,n="center"]=e.split("-");return[t,n]}var rj=GF,aj=qF,oj=XF,ij=JF;var sj=e=>{const{present:t,children:n}=e,r=function(e){const[t,n]=K.useState(),r=K.useRef({}),a=K.useRef(e),o=K.useRef("none"),i=e?"mounted":"unmounted",[s,l]=function(e,t){return K.useReducer(((e,n)=>t[e][n]??e),e)}(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return K.useEffect((()=>{const e=lj(r.current);o.current="mounted"===s?e:"none"}),[s]),rM((()=>{const t=r.current,n=a.current;if(n!==e){const r=o.current,i=lj(t);if(e)l("MOUNT");else if("none"===i||"none"===(null==t?void 0:t.display))l("UNMOUNT");else{l(n&&r!==i?"ANIMATION_OUT":"UNMOUNT")}a.current=e}}),[e,l]),rM((()=>{if(t){let e;const n=t.ownerDocument.defaultView??window,i=o=>{const i=lj(r.current).includes(o.animationName);if(o.target===t&&i&&(l("ANIMATION_END"),!a.current)){const r=t.style.animationFillMode;t.style.animationFillMode="forwards",e=n.setTimeout((()=>{"forwards"===t.style.animationFillMode&&(t.style.animationFillMode=r)}))}},s=e=>{e.target===t&&(o.current=lj(r.current))};return t.addEventListener("animationstart",s),t.addEventListener("animationcancel",i),t.addEventListener("animationend",i),()=>{n.clearTimeout(e),t.removeEventListener("animationstart",s),t.removeEventListener("animationcancel",i),t.removeEventListener("animationend",i)}}l("ANIMATION_END")}),[t,l]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:K.useCallback((e=>{e&&(r.current=getComputedStyle(e)),n(e)}),[])}}(t),a="function"==typeof n?n({present:r.isPresent}):K.Children.only(n),o=FL(r.ref,function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;if(a)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a)return e.props.ref;return e.props.ref||e.ref}(a));return"function"==typeof n||r.isPresent?K.cloneElement(a,{ref:o}):null};function lj(e){return(null==e?void 0:e.animationName)||"none"}function cj({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,a]=function({defaultProp:e,onChange:t}){const n=K.useState(e),[r]=n,a=K.useRef(r),o=qL(t);return K.useEffect((()=>{a.current!==r&&(o(r),a.current=r)}),[r,a,o]),n}({defaultProp:t,onChange:n}),o=void 0!==e,i=o?e:r,s=qL(n);return[i,K.useCallback((t=>{if(o){const n="function"==typeof t?t(e):t;n!==e&&s(n)}else a(t)}),[o,e,a,s])]}sj.displayName="Presence";var uj=K.forwardRef(((e,t)=>Wh.jsx(VL.span,{...e,ref:t,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}})));uj.displayName="VisuallyHidden";var dj=uj,[pj,hj]=jL("Tooltip",[HF]),fj=HF(),mj="TooltipProvider",gj=700,yj="tooltip.open",[bj,vj]=pj(mj),kj=e=>{const{__scopeTooltip:t,delayDuration:n=gj,skipDelayDuration:r=300,disableHoverableContent:a=!1,children:o}=e,[i,s]=K.useState(!0),l=K.useRef(!1),c=K.useRef(0);return K.useEffect((()=>{const e=c.current;return()=>window.clearTimeout(e)}),[]),Wh.jsx(bj,{scope:t,isOpenDelayed:i,delayDuration:n,onOpen:K.useCallback((()=>{window.clearTimeout(c.current),s(!1)}),[]),onClose:K.useCallback((()=>{window.clearTimeout(c.current),c.current=window.setTimeout((()=>s(!0)),r)}),[r]),isPointerInTransitRef:l,onPointerInTransitChange:K.useCallback((e=>{l.current=e}),[]),disableHoverableContent:a,children:o})};kj.displayName=mj;var wj="Tooltip",[xj,Ej]=pj(wj),_j=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:a=!1,onOpenChange:o,disableHoverableContent:i,delayDuration:s}=e,l=vj(wj,e.__scopeTooltip),c=fj(t),[u,d]=K.useState(null),p=iM(),h=K.useRef(0),f=i??l.disableHoverableContent,m=s??l.delayDuration,g=K.useRef(!1),[y=!1,b]=cj({prop:r,defaultProp:a,onChange:e=>{e?(l.onOpen(),document.dispatchEvent(new CustomEvent(yj))):l.onClose(),null==o||o(e)}}),v=K.useMemo((()=>y?g.current?"delayed-open":"instant-open":"closed"),[y]),k=K.useCallback((()=>{window.clearTimeout(h.current),h.current=0,g.current=!1,b(!0)}),[b]),w=K.useCallback((()=>{window.clearTimeout(h.current),h.current=0,b(!1)}),[b]),x=K.useCallback((()=>{window.clearTimeout(h.current),h.current=window.setTimeout((()=>{g.current=!0,b(!0),h.current=0}),m)}),[m,b]);return K.useEffect((()=>()=>{h.current&&(window.clearTimeout(h.current),h.current=0)}),[]),Wh.jsx(rj,{...c,children:Wh.jsx(xj,{scope:t,contentId:p,open:y,stateAttribute:v,trigger:u,onTriggerChange:d,onTriggerEnter:K.useCallback((()=>{l.isOpenDelayed?x():k()}),[l.isOpenDelayed,x,k]),onTriggerLeave:K.useCallback((()=>{f?w():(window.clearTimeout(h.current),h.current=0)}),[w,f]),onOpen:k,onClose:w,disableHoverableContent:f,children:n})})};_j.displayName=wj;var Sj="TooltipTrigger",Tj=K.forwardRef(((e,t)=>{const{__scopeTooltip:n,...r}=e,a=Ej(Sj,n),o=vj(Sj,n),i=fj(n),s=FL(t,K.useRef(null),a.onTriggerChange),l=K.useRef(!1),c=K.useRef(!1),u=K.useCallback((()=>l.current=!1),[]);return K.useEffect((()=>()=>document.removeEventListener("pointerup",u)),[u]),Wh.jsx(aj,{asChild:!0,...i,children:Wh.jsx(VL.button,{"aria-describedby":a.open?a.contentId:void 0,"data-state":a.stateAttribute,...r,ref:s,onPointerMove:DL(e.onPointerMove,(e=>{"touch"!==e.pointerType&&(c.current||o.isPointerInTransitRef.current||(a.onTriggerEnter(),c.current=!0))})),onPointerLeave:DL(e.onPointerLeave,(()=>{a.onTriggerLeave(),c.current=!1})),onPointerDown:DL(e.onPointerDown,(()=>{l.current=!0,document.addEventListener("pointerup",u,{once:!0})})),onFocus:DL(e.onFocus,(()=>{l.current||a.onOpen()})),onBlur:DL(e.onBlur,a.onClose),onClick:DL(e.onClick,a.onClose)})})}));Tj.displayName=Sj;var[Cj,Aj]=pj("TooltipPortal",{forceMount:void 0}),Nj="TooltipContent",Ij=K.forwardRef(((e,t)=>{const n=Aj(Nj,e.__scopeTooltip),{forceMount:r=n.forceMount,side:a="top",...o}=e,i=Ej(Nj,e.__scopeTooltip);return Wh.jsx(sj,{present:r||i.open,children:i.disableHoverableContent?Wh.jsx(Dj,{side:a,...o,ref:t}):Wh.jsx(Rj,{side:a,...o,ref:t})})})),Rj=K.forwardRef(((e,t)=>{const n=Ej(Nj,e.__scopeTooltip),r=vj(Nj,e.__scopeTooltip),a=K.useRef(null),o=FL(t,a),[i,s]=K.useState(null),{trigger:l,onClose:c}=n,u=a.current,{onPointerInTransitChange:d}=r,p=K.useCallback((()=>{s(null),d(!1)}),[d]),h=K.useCallback(((e,t)=>{const n=e.currentTarget,r={x:e.clientX,y:e.clientY},a=function(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n})}return r}(r,function(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),a=Math.abs(t.right-e.x),o=Math.abs(t.left-e.x);switch(Math.min(n,r,a,o)){case o:return"left";case a:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}(r,n.getBoundingClientRect())),o=function(e){const t=e.slice();return t.sort(((e,t)=>e.x<t.x?-1:e.x>t.x?1:e.y<t.y?-1:e.y>t.y?1:0)),function(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const n=e[r];for(;t.length>=2;){const e=t[t.length-1],r=t[t.length-2];if(!((e.x-r.x)*(n.y-r.y)>=(e.y-r.y)*(n.x-r.x)))break;t.pop()}t.push(n)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const t=e[r];for(;n.length>=2;){const e=n[n.length-1],r=n[n.length-2];if(!((e.x-r.x)*(t.y-r.y)>=(e.y-r.y)*(t.x-r.x)))break;n.pop()}n.push(t)}return n.pop(),1===t.length&&1===n.length&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}(t)}([...a,...function(e){const{top:t,right:n,bottom:r,left:a}=e;return[{x:a,y:t},{x:n,y:t},{x:n,y:r},{x:a,y:r}]}(t.getBoundingClientRect())]);s(o),d(!0)}),[d]);return K.useEffect((()=>()=>p()),[p]),K.useEffect((()=>{if(l&&u){const e=e=>h(e,u),t=e=>h(e,l);return l.addEventListener("pointerleave",e),u.addEventListener("pointerleave",t),()=>{l.removeEventListener("pointerleave",e),u.removeEventListener("pointerleave",t)}}}),[l,u,h,p]),K.useEffect((()=>{if(i){const e=e=>{const t=e.target,n={x:e.clientX,y:e.clientY},r=(null==l?void 0:l.contains(t))||(null==u?void 0:u.contains(t)),a=!function(e,t){const{x:n,y:r}=e;let a=!1;for(let o=0,i=t.length-1;o<t.length;i=o++){const e=t[o].x,s=t[o].y,l=t[i].x,c=t[i].y;s>r!=c>r&&n<(l-e)*(r-s)/(c-s)+e&&(a=!a)}return a}(n,i);r?p():a&&(p(),c())};return document.addEventListener("pointermove",e),()=>document.removeEventListener("pointermove",e)}}),[l,u,i,c,p]),Wh.jsx(Dj,{...e,ref:o})})),[Oj,Pj]=pj(wj,{isInside:!1}),Dj=K.forwardRef(((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":a,onEscapeKeyDown:o,onPointerDownOutside:i,...s}=e,l=Ej(Nj,n),c=fj(n),{onClose:u}=l;return K.useEffect((()=>(document.addEventListener(yj,u),()=>document.removeEventListener(yj,u))),[u]),K.useEffect((()=>{if(l.trigger){const e=e=>{const t=e.target;(null==t?void 0:t.contains(l.trigger))&&u()};return window.addEventListener("scroll",e,{capture:!0}),()=>window.removeEventListener("scroll",e,{capture:!0})}}),[l.trigger,u]),Wh.jsx(JL,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:i,onFocusOutside:e=>e.preventDefault(),onDismiss:u,children:Wh.jsxs(oj,{"data-state":l.stateAttribute,...c,...s,ref:t,style:{...s.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[Wh.jsx(UL,{children:r}),Wh.jsx(Oj,{scope:n,isInside:!0,children:Wh.jsx(dj,{id:l.contentId,role:"tooltip",children:a||r})})]})})}));Ij.displayName=Nj;var Lj="TooltipArrow",Mj=K.forwardRef(((e,t)=>{const{__scopeTooltip:n,...r}=e,a=fj(n);return Pj(Lj,n).isInside?null:Wh.jsx(ij,{...a,...r,ref:t})}));Mj.displayName=Lj;var Fj=kj,jj=Tj,Bj=Ij,zj=Mj;const Hj=K.createContext(void 0),Uj=({children:e,...t})=>{const n=NL();return Wh.jsx(Hj.Provider,{value:{...n,...t},children:Wh.jsx(OL,{children:Wh.jsx(Fj,{children:e})})})},$j=()=>{const e=K.useContext(Hj);if(!e)throw new Error("useChat must be used within a ChatProvider");return e},Gj=K.createContext(void 0);function Vj({children:e}){const t=function(){var e;const[t,n]=K.useState(null),{value:r,setTrue:a,setFalse:o}=Qh(!1),[i,s]=K.useState({title:"",content:""}),[l,c]=K.useState({title:void 0,content:void 0}),{addAttachment:u}=$j(),d={data:i,errors:l,labels:{title:(null==(e=null==t?void 0:t.workflowModalProps)?void 0:e.titleInputLabel)||"Title",content:(null==t?void 0:t.contentType.contentInputLabel)||"Content"},validate(){const e={};return i.title.trim()||(e.title=`${d.labels.title} is required`),i.content.trim()||(e.content=`${d.labels.content} is required`),e},onChange(e){const{name:t,value:n}=e.target;s((e=>({...e,[t]:n})))},onSubmit(e){if(e.preventDefault(),!(null==t?void 0:t.contentType))return;const n=d.validate();if(Object.values(n).some((e=>!!e)))return void c(n);const r={...i,id:Zh(),contentType:t.contentType};u(r),o(),s({title:"",content:""}),c({title:void 0,content:void 0})}};return{selectedInput:t,selectInput:n,isOpen:r,onOpen:a,onClose:o,form:d}}();return Wh.jsx(Gj.Provider,{value:t,children:e})}const qj=()=>{const e=K.useContext(Gj);if(!e)throw new Error("useAttachmentsBar must be used within a AttachmentsBarProvider");return e},Wj=K.createContext(void 0),Yj=({children:e,name:t})=>{const n=K.useRef(null);return Wh.jsx(Wj.Provider,{value:{name:t,focusItem:n},children:e})},Kj=()=>{const e=K.useContext(Wj);if(!e)throw new Error("useFeedbackItem must be used within a FeedbackItemProvider");return e},Xj=K.createContext(void 0),Qj=({children:e,field:t,fieldProps:n,autoFocus:r})=>{const{errors:a}=dL(),o=a[t.name];return Wh.jsx(Xj.Provider,{value:{field:t,fieldProps:n,error:o,autoFocus:r},children:e})},Zj=()=>{const e=K.useContext(Xj);if(!e)throw new Error("useFormField must be used within a FormFieldProvider");return e},Jj=K.createContext(void 0);const eB=({children:e,value:t})=>Wh.jsx(Jj.Provider,{value:t,children:e}),tB=K.createContext(void 0),nB=({children:e,componentStyles:t})=>Wh.jsx(tB.Provider,{value:{componentStyles:t},children:e}),rB=K.createContext(void 0);function aB({children:e}){const[t,n]=X.useState(null),{value:r,setTrue:a,setFalse:o}=Qh(!1);return Wh.jsx(rB.Provider,{value:{selectedItem:t,selectItem:n,isOpen:r,onOpen:a,onClose:o},children:e})}const oB=()=>{const e=K.useContext(rB);if(!e)throw new Error("useMessageAttachments must be used within a MessageAttachmentsProvider");return e},iB=K.createContext(void 0),sB=({children:e,message:t})=>Wh.jsx(iB.Provider,{value:{message:t},children:e}),lB=()=>{const e=K.useContext(iB);if(!e)throw new Error("useMessage must be used within a MessageProvider");return e},cB=["light","dark"],uB="(prefers-color-scheme: dark)",dB="undefined"==typeof window,pB=K.createContext(void 0),hB={setColorMode:e=>{},colorModes:[]};function fB(e,t){const n=K.useContext(pB)??hB;return"dark"===(n.forcedColorMode??n.resolvedColorMode)?t:e}const mB=e=>(K.useContext(pB),Wh.jsx(yB,{...e})),gB=["light","dark"],yB=({forcedColorMode:e,disableTransitionOnChange:t=!1,enableSystem:n=!1,enableColorScheme:r=!0,storageKey:a="inkeep-colorMode",colorModes:o=gB,defaultColorMode:i=(n?"system":"light"),attribute:s="data-theme",value:l,children:c,nonce:u,shadowHostId:d,rootId:p})=>{const[h,f]=K.useState((()=>vB(a,i))),[m,g]=K.useState((()=>vB(a))),y=l?Object.values(l):o,b=K.useCallback((e=>{var a;let o=e;if(!o)return;"system"===e&&n&&(o=wB());const c=l?l[o]:o,u=t?kB():null,h=d&&p&&(null==(a=document.getElementById(d))?void 0:a.shadowRoot),f=h?h.getElementById(p)??document.documentElement:document.documentElement;if("class"===s?(f.classList.remove(...y),c&&f.classList.add(c)):c?f.setAttribute(s,c):f.removeAttribute(s),r){const e=cB.includes(i)?i:null,t=cB.includes(o)?o:e;f.style.colorScheme=t}null==u||u()}),[]),v=K.useCallback((e=>{f(e);try{localStorage.setItem(a,e)}catch(X4){}}),[e]),k=K.useCallback((t=>{const r=wB(t);g(r),"system"===h&&n&&!e&&b("system")}),[h,e]);K.useEffect((()=>{const e=window.matchMedia(uB);return e.addListener(k),k(e),()=>e.removeListener(k)}),[k]),K.useEffect((()=>{const e=e=>{if(e.key!==a)return;const t=e.newValue||i;v(t)};return window.addEventListener("storage",e),()=>window.removeEventListener("storage",e)}),[v]),K.useEffect((()=>{b(e??h)}),[e,h]);const w=K.useMemo((()=>({colorMode:h,setColorMode:v,forcedColorMode:e,resolvedColorMode:"system"===h?m:h,colorModes:n?[...o,"system"]:o,systemColorMode:n?m:void 0})),[h,v,e,m,n,o]);return Wh.jsxs(pB.Provider,{value:w,children:[Wh.jsx(bB,{forcedColorMode:e,disableTransitionOnChange:t,enableSystem:n,enableColorScheme:r,storageKey:a,colorModes:o,defaultColorMode:i,attribute:s,value:l,children:c,attrs:y,nonce:u,shadowHostId:d,rootId:p}),c]})},bB=K.memo((({forcedColorMode:e,storageKey:t,attribute:n,enableSystem:r,enableColorScheme:a,defaultColorMode:o,value:i,attrs:s,nonce:l,shadowHostId:c,rootId:u})=>{const d="system"===o,p=(()=>{const e=c&&u?`document.getElementById('${c}').shadowRoot.getElementById('${u}')`:"document.documentElement";if("class"===n){return`var d=${e},c=d.classList;${`c.remove(${s.map((e=>`'${e}'`)).join(",")})`};`}return`var d=${e},n='${n}',s='setAttribute';`})(),h=(()=>{if(!a)return"";return(cB.includes(o)?o:null)?`if(e==='light'||e==='dark'||!e)d.style.colorScheme=e||'${o}'`:"if(e==='light'||e==='dark')d.style.colorScheme=e"})(),f=(e,t=!1,r=!0)=>{const o=i?i[e]:e,s=t?`${e}|| ''`:`'${o}'`;let l="";return a&&r&&!t&&cB.includes(e)&&(l+=`d.style.colorScheme = '${e}';`),"class"===n?l+=t||o?`c.add(${s})`:"null":o&&(l+=`d[s](n,${s})`),l},m=e?`!function(){${p}${f(e)}}()`:r?`!function(){try{${p}var e=localStorage.getItem('${t}');if('system'===e||(!e&&${d})){var t='${uB}',m=window.matchMedia(t);if(m.media!==t||m.matches){${f("dark")}}else{${f("light")}}}else if(e){${i?`var x=${JSON.stringify(i)};`:""}${f(i?"x[e]":"e",!0)}}${d?"":`else{${f(o,!1,!1)}}`}${h}}catch(e){}}()`:`!function(){try{${p}var e=localStorage.getItem('${t}');if(e){${i?`var x=${JSON.stringify(i)};`:""}${f(i?"x[e]":"e",!0)}}else{${f(o,!1,!1)};}${h}}catch(t){}}();`;return Wh.jsx("script",{nonce:l,dangerouslySetInnerHTML:{__html:m}})}),(()=>!0)),vB=(e,t)=>{if(dB)return;let n;try{n=localStorage.getItem(e)||void 0}catch(X4){}return n||t},kB=()=>{const e=document.createElement("style");return e.appendChild(document.createTextNode("*{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}")),document.head.appendChild(e),()=>{window.getComputedStyle(document.body),setTimeout((()=>{document.head.removeChild(e)}),1)}},wB=e=>{e||(e=window.matchMedia(uB));return e.matches?"dark":"light"};var xB=Object.prototype.hasOwnProperty;function EB(e,t,n){for(n of e.keys())if(_B(n,t))return n}function _B(e,t){var n,r,a;if(e===t)return!0;if(e&&t&&(n=e.constructor)===t.constructor){if(n===Date)return e.getTime()===t.getTime();if(n===RegExp)return e.toString()===t.toString();if(n===Array){if((r=e.length)===t.length)for(;r--&&_B(e[r],t[r]););return-1===r}if(n===Set){if(e.size!==t.size)return!1;for(r of e){if((a=r)&&"object"==typeof a&&!(a=EB(t,a)))return!1;if(!t.has(a))return!1}return!0}if(n===Map){if(e.size!==t.size)return!1;for(r of e){if((a=r[0])&&"object"==typeof a&&!(a=EB(t,a)))return!1;if(!_B(r[1],t.get(a)))return!1}return!0}if(n===ArrayBuffer)e=new Uint8Array(e),t=new Uint8Array(t);else if(n===DataView){if((r=e.byteLength)===t.byteLength)for(;r--&&e.getInt8(r)===t.getInt8(r););return-1===r}if(ArrayBuffer.isView(e)){if((r=e.byteLength)===t.byteLength)for(;r--&&e[r]===t[r];);return-1===r}if(!n||"object"==typeof e){for(n in r=0,e){if(xB.call(e,n)&&++r&&!xB.call(t,n))return!1;if(!(n in t)||!_B(e[n],t[n]))return!1}return Object.keys(t).length===r}}return e!=e&&t!=t}function SB(){const{baseSettings:e}=nP(),[t,n]=K.useState([]),r=function(e){const t=K.useRef(void 0);_B(t.current,e)||(t.current=e);return t.current}(e.theme.styles),{customStyles:a,linksCount:o}=K.useMemo((()=>{if(!r||!Array.isArray(r))return{customStyles:null,loaded:!0};const{links:e,styleSheets:t}=r.reduce(((e,t)=>("link"===t.type?e.links.push(t):"style"===t.type&&e.styleSheets.push(t),e)),{links:[],styleSheets:[]}),a=t.map((e=>Wh.jsx("style",{type:"text/css",dangerouslySetInnerHTML:{__html:e.value}},e.key??ef("link_")))),o=e.map((e=>{const t=e.key??ef("stylesheet_");return Wh.jsx("link",{id:t,rel:"stylesheet",type:"text/css",href:e.value,onLoad:()=>{n((t=>[...new Set([...t,e.value])]))}},t)}));return{customStyles:Wh.jsxs(Wh.Fragment,{children:[o,a]}),linksCount:e.length}}),[r]);return{customStyles:a,loaded:t.length>=(o??0)}}const TB=({children:e})=>{const{baseSettings:t}=nP(),{theme:n,primaryBrandColor:r,shadowHost:a,rootElement:o,colorMode:i}=t,{primaryColors:s,varsClassName:l}=n,{disableLoadingDefaultFont:c,fontFamily:u,fontSize:d,zIndex:p}=n,h=Cx(s,r),f=function(e){const t={};for(const[n,r]of Object.entries(e)){const e=Nx[n]||n,a=(n,r=[])=>{for(const[o,i]of Object.entries(n)){const n=[...r,o];if("object"==typeof i&&null!==i)a(i,n);else{const r=n.map((e=>e.replace(/([A-Z])/g,"-$1").toLowerCase())).join("-");t[`--ikp-${e}-${r}`]=i}}};a(r)}return t}({colors:Ph(n.colors,h),fontFamily:u,fontSize:d,zIndex:p}),{customStyles:m,loaded:g}=SB(),{sync:y,forcedColorMode:b,...v}=i??{},[k,w]=K.useState(),x=K.useRef(null);return K.useEffect((()=>{var e,t;if(!(null==y?void 0:y.target))return;const n="string"==typeof y.target?document.querySelector(y.target):y.target;if(!n)return;function r(e,t){return t.reduce(((t,n)=>({...t,[n]:e.getAttribute(n)})),{})}const a=new MutationObserver((()=>{var e,t;const a=r(n,y.attributes),o=(null==(e=y.isDarkMode)?void 0:e.call(y,a))?"dark":"light";null==(t=y.onChange)||t.call(y,o),w(o)}));a.observe(n,{attributes:!0,attributeFilter:y.attributes,childList:!1,subtree:!1}),x.current=a;const o=(null==(e=y.isDarkMode)?void 0:e.call(y,r(n,null==y?void 0:y.attributes)))?"dark":"light";return null==(t=y.onChange)||t.call(y,o),w(o),()=>a.disconnect()}),[y]),Wh.jsxs(Wh.Fragment,{children:[!c&&Wh.jsx("style",{type:"text/css",dangerouslySetInnerHTML:{__html:"\n @import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;900&display=swap');\n "}}),m,g&&Wh.jsx(mB,{forcedColorMode:b??k,...v,shadowHostId:null==a?void 0:a.id,rootId:null==o?void 0:o.id,children:Wh.jsx("div",{className:l,style:{display:"contents",...f},children:e})})]})};function CB(e){const{children:t,config:n,componentType:r}=e;return Wh.jsx(tP,{value:{...n,componentType:r},children:Wh.jsx(TB,{children:Wh.jsx(fP,{children:Wh.jsx(yP,{children:t})})})})}const AB=K.createContext(void 0),NB=({children:e,source:t})=>Wh.jsx(AB.Provider,{value:{source:t},children:e}),IB=()=>{const e=K.useContext(AB);if(!e)throw new Error("useSourceItem must be used within a SourceItemProvider");return e};function RB(e){const t=K.useRef(e);return K.useEffect((()=>{t.current=e})),K.useMemo((()=>(...e)=>{var n;return null==(n=t.current)?void 0:n.call(t,...e)}),[])}function OB({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,a]=function({defaultProp:e,onChange:t}){const n=K.useState(e),[r]=n,a=K.useRef(r),o=RB(t);return K.useEffect((()=>{a.current!==r&&(o(r),a.current=r)}),[r,a,o]),n}({defaultProp:t,onChange:n}),o=void 0!==e,i=o?e:r,s=RB(n);return[i,K.useCallback((t=>{if(o){const n="function"==typeof t?t(e):t;n!==e&&s(n)}else a(t)}),[o,e,a,s])]}const PB=K.createContext(void 0),DB=({children:e,value:t})=>Wh.jsx(PB.Provider,{value:t,children:e}),LB=()=>{const e=K.useContext(PB);if(!e)throw new Error("useSidebarChat must be used within a SidebarChatProvider");return e};function MB(e,t){var n;const{prefix:r}=nP(),a=K.useContext(tB),o=function(e,t){return!!(null==t?void 0:t.componentStyles)&&e in t.componentStyles}(e,a);return[t,o?null==(n=null==a?void 0:a.componentStyles)?void 0:n[e]:void 0,`${r}-${_L(e)}`].filter(Boolean).join(" ")}function FB(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function jB(...e){return t=>{let n=!1;const r=e.map((e=>{const r=FB(e,t);return n||"function"!=typeof r||(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():FB(e[t],null)}}}}function BB(...e){return K.useCallback(jB(...e),e)}const zB=(...e)=>e.map((e=>{var t;return null==(t=null==e?void 0:e.trim)?void 0:t.call(e)})).filter(Boolean).join(" "),HB=/((?:--)?(?:\w+-?)+)\s*:\s*([^;]*)/g,UB=e=>{const t={};let n;for(;n=HB.exec(e);)t[n[1]]=n[2];return t},$B=(e,t)=>{if(EL(e)){if(EL(t))return`${e};${t}`;e=UB(e)}else EL(t)&&(t=UB(t));return Object.assign({},e??{},t??{})};function GB(...e){let t={};for(let n of e){for(let e in t)e.startsWith("on")&&"function"==typeof t[e]&&"function"==typeof n[e]?t[e]=xL(n[e],t[e]):t[e]="className"!==e&&"class"!==e?"style"!==e?void 0!==n[e]?n[e]:t[e]:$B(t[e],n[e]):zB(t[e],n[e]);for(let e in n)void 0===t[e]&&(t[e]=n[e])}return t}const VB=(e,t)=>{const n=K.memo(K.forwardRef(((n,r)=>{const{_id:a,className:o,children:i,...s}=t,{asChild:l,children:c,...u}=n,d=c||i,p=GB(s,u,{className:MB(a,o),"data-part":_L(a)});if(!l)return K.createElement(e,{...p,ref:r},d);const h=K.Children.only(d);if(!K.isValidElement(h))return null;const f=function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;return a?e.ref:(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a?e.props.ref:e.props.ref||e.ref)}(h);return K.cloneElement(h,{...GB(p,h.props),ref:r?jB(r,f):f})})));return n.displayName=e.displayName||e.name,n},qB=new Proxy(VB,{apply(e,t,n){const r=n[0],a=n[1];return VB(r,a)}});function WB(){return WB=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},WB.apply(null,arguments)}function YB(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}var KB=K.useLayoutEffect,XB=function(e,t){"function"!=typeof e?e.current=t:e(t)},QB={"min-height":"0","max-height":"none",height:"0",visibility:"hidden",overflow:"hidden",position:"absolute","z-index":"-1000",top:"0",right:"0",display:"block"},ZB=function(e){Object.keys(QB).forEach((function(t){e.style.setProperty(t,QB[t],"important")}))},JB=null,ez=function(e,t){var n=e.scrollHeight;return"border-box"===t.sizingStyle.boxSizing?n+t.borderSize:n-t.paddingSize};var tz=function(){},nz=["borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","boxSizing","fontFamily","fontSize","fontStyle","fontWeight","letterSpacing","lineHeight","paddingBottom","paddingLeft","paddingRight","paddingTop","tabSize","textIndent","textRendering","textTransform","width","wordBreak","wordSpacing","scrollbarGutter"],rz=!!document.documentElement.currentStyle,az=function(e){var t=window.getComputedStyle(e);if(null===t)return null;var n,r=(n=t,nz.reduce((function(e,t){return e[t]=n[t],e}),{})),a=r.boxSizing;return""===a?null:(rz&&"border-box"===a&&(r.width=parseFloat(r.width)+parseFloat(r.borderRightWidth)+parseFloat(r.borderLeftWidth)+parseFloat(r.paddingRight)+parseFloat(r.paddingLeft)+"px"),{sizingStyle:r,paddingSize:parseFloat(r.paddingBottom)+parseFloat(r.paddingTop),borderSize:parseFloat(r.borderBottomWidth)+parseFloat(r.borderTopWidth)})};function oz(e,t,n){var r,a,o=(r=n,a=X.useRef(r),KB((function(){a.current=r})),a);K.useLayoutEffect((function(){var n=function(e){return o.current(e)};if(e)return e.addEventListener(t,n),function(){return e.removeEventListener(t,n)}}),[])}var iz=["cacheMeasurements","maxRows","minRows","onChange","onHeightChange"],sz=function(e,t){var n=e.cacheMeasurements,r=e.maxRows,a=e.minRows,o=e.onChange,i=void 0===o?tz:o,s=e.onHeightChange,l=void 0===s?tz:s,c=YB(e,iz),u=void 0!==c.value,d=K.useRef(null),p=function(e,t){var n=X.useRef();return X.useCallback((function(r){e.current=r,n.current&&XB(n.current,null),n.current=t,t&&XB(t,r)}),[t])}(d,t),h=K.useRef(0),f=K.useRef(),m=function(){var e=d.current,t=n&&f.current?f.current:az(e);if(t){f.current=t;var o=function(e,t,n,r){void 0===n&&(n=1),void 0===r&&(r=1/0),JB||((JB=document.createElement("textarea")).setAttribute("tabindex","-1"),JB.setAttribute("aria-hidden","true"),ZB(JB)),null===JB.parentNode&&document.body.appendChild(JB);var a=e.paddingSize,o=e.borderSize,i=e.sizingStyle,s=i.boxSizing;Object.keys(i).forEach((function(e){var t=e;JB.style[t]=i[t]})),ZB(JB),JB.value=t;var l=ez(JB,e);JB.value=t,l=ez(JB,e),JB.value="x";var c=JB.scrollHeight-a,u=c*n;"border-box"===s&&(u=u+a+o),l=Math.max(u,l);var d=c*r;return"border-box"===s&&(d=d+a+o),[l=Math.min(d,l),c]}(t,e.value||e.placeholder||"x",a,r),i=o[0],s=o[1];h.current!==i&&(h.current=i,e.style.setProperty("height",i+"px","important"),l(i,{rowHeight:s}))}};return K.useLayoutEffect(m),function(e,t){oz(document.body,"reset",(function(n){e.current.form===n.target&&t(n)}))}(d,(function(){if(!u){var e=d.current,t=e.value;requestAnimationFrame((function(){t!==e.value&&m()}))}})),oz(window,"resize",m),function(e){oz(document.fonts,"loadingdone",e)}(m),K.createElement("textarea",WB({},c,{onChange:function(e){u||m(),i(e)},ref:p}))},lz=K.forwardRef(sz),cz="Avatar",[uz,dz]=jL(cz),[pz,hz]=uz(cz),fz=K.forwardRef(((e,t)=>{const{__scopeAvatar:n,...r}=e,[a,o]=K.useState("idle");return Wh.jsx(pz,{scope:n,imageLoadingStatus:a,onImageLoadingStatusChange:o,children:Wh.jsx(VL.span,{...r,ref:t})})}));fz.displayName=cz;var mz="AvatarImage",gz=K.forwardRef(((e,t)=>{const{__scopeAvatar:n,src:r,onLoadingStatusChange:a=()=>{},...o}=e,i=hz(mz,n),s=function(e,t){const[n,r]=K.useState("idle");return rM((()=>{if(!e)return void r("error");let n=!0;const a=new window.Image,o=e=>()=>{n&&r(e)};return r("loading"),a.onload=o("loaded"),a.onerror=o("error"),a.src=e,t&&(a.referrerPolicy=t),()=>{n=!1}}),[e,t]),n}(r,o.referrerPolicy),l=qL((e=>{a(e),i.onImageLoadingStatusChange(e)}));return rM((()=>{"idle"!==s&&l(s)}),[s,l]),"loaded"===s?Wh.jsx(VL.img,{...o,ref:t,src:r}):null}));gz.displayName=mz;var yz="AvatarFallback",bz=K.forwardRef(((e,t)=>{const{__scopeAvatar:n,delayMs:r,...a}=e,o=hz(yz,n),[i,s]=K.useState(void 0===r);return K.useEffect((()=>{if(void 0!==r){const e=window.setTimeout((()=>s(!0)),r);return()=>window.clearTimeout(e)}}),[r]),i&&"loaded"!==o.imageLoadingStatus?Wh.jsx(VL.span,{...a,ref:t}):null}));bz.displayName=yz;var vz=fz,kz=gz,wz=bz;var xz="Checkbox",[Ez,_z]=jL(xz),[Sz,Tz]=Ez(xz),Cz=K.forwardRef(((e,t)=>{const{__scopeCheckbox:n,name:r,checked:a,defaultChecked:o,required:i,disabled:s,value:l="on",onCheckedChange:c,form:u,...d}=e,[p,h]=K.useState(null),f=FL(t,(e=>h(e))),m=K.useRef(!1),g=!p||(u||!!p.closest("form")),[y=!1,b]=cj({prop:a,defaultProp:o,onChange:c}),v=K.useRef(y);return K.useEffect((()=>{const e=null==p?void 0:p.form;if(e){const t=()=>b(v.current);return e.addEventListener("reset",t),()=>e.removeEventListener("reset",t)}}),[p,b]),Wh.jsxs(Sz,{scope:n,state:y,disabled:s,children:[Wh.jsx(VL.button,{type:"button",role:"checkbox","aria-checked":Rz(y)?"mixed":y,"aria-required":i,"data-state":Oz(y),"data-disabled":s?"":void 0,disabled:s,value:l,...d,ref:f,onKeyDown:DL(e.onKeyDown,(e=>{"Enter"===e.key&&e.preventDefault()})),onClick:DL(e.onClick,(e=>{b((e=>!!Rz(e)||!e)),g&&(m.current=e.isPropagationStopped(),m.current||e.stopPropagation())}))}),g&&Wh.jsx(Iz,{control:p,bubbles:!m.current,name:r,value:l,checked:y,required:i,disabled:s,form:u,style:{transform:"translateX(-100%)"},defaultChecked:!Rz(o)&&o})]})}));Cz.displayName=xz;var Az="CheckboxIndicator",Nz=K.forwardRef(((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...a}=e,o=Tz(Az,n);return Wh.jsx(sj,{present:r||Rz(o.state)||!0===o.state,children:Wh.jsx(VL.span,{"data-state":Oz(o.state),"data-disabled":o.disabled?"":void 0,...a,ref:t,style:{pointerEvents:"none",...e.style}})})}));Nz.displayName=Az;var Iz=e=>{const{control:t,checked:n,bubbles:r=!0,defaultChecked:a,...o}=e,i=K.useRef(null),s=function(e){const t=K.useRef({value:e,previous:e});return K.useMemo((()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous)),[e])}(n),l=jF(t);K.useEffect((()=>{const e=i.current,t=window.HTMLInputElement.prototype,a=Object.getOwnPropertyDescriptor(t,"checked").set;if(s!==n&&a){const t=new Event("click",{bubbles:r});e.indeterminate=Rz(n),a.call(e,!Rz(n)&&n),e.dispatchEvent(t)}}),[s,n,r]);const c=K.useRef(!Rz(n)&&n);return Wh.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:a??c.current,...o,tabIndex:-1,ref:i,style:{...e.style,...l,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function Rz(e){return"indeterminate"===e}function Oz(e){return Rz(e)?"indeterminate":e?"checked":"unchecked"}var Pz=Cz,Dz=Nz,Lz=K.forwardRef(((e,t)=>{const{children:n,...r}=e,a=K.Children.toArray(n),o=a.find(jz);if(o){const e=o.props.children,n=a.map((t=>t===o?K.Children.count(e)>1?K.Children.only(null):K.isValidElement(e)?e.props.children:null:t));return Wh.jsx(Mz,{...r,ref:t,children:K.isValidElement(e)?K.cloneElement(e,void 0,n):null})}return Wh.jsx(Mz,{...r,ref:t,children:n})}));Lz.displayName="Slot";var Mz=K.forwardRef(((e,t)=>{const{children:n,...r}=e;if(K.isValidElement(n)){const e=function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;if(a)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a)return e.props.ref;return e.props.ref||e.ref}(n),a=function(e,t){const n={...t};for(const r in t){const a=e[r],o=t[r];/^on[A-Z]/.test(r)?a&&o?n[r]=(...e)=>{o(...e),a(...e)}:a&&(n[r]=a):"style"===r?n[r]={...a,...o}:"className"===r&&(n[r]=[a,o].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props);return n.type!==K.Fragment&&(a.ref=t?ML(t,e):e),K.cloneElement(n,a)}return K.Children.count(n)>1?K.Children.only(null):null}));Mz.displayName="SlotClone";var Fz=({children:e})=>Wh.jsx(Wh.Fragment,{children:e});function jz(e){return K.isValidElement(e)&&e.type===Fz}var Bz=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce(((e,t)=>{const n=K.forwardRef(((e,n)=>{const{asChild:r,...a}=e,o=r?Lz:t;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),Wh.jsx(o,{...a,ref:n})}));return n.displayName=`Primitive.${t}`,{...e,[t]:n}}),{});var zz,Hz="dismissableLayer.update",Uz="dismissableLayer.pointerDownOutside",$z="dismissableLayer.focusOutside",Gz=K.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Vz=K.forwardRef(((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:a,onFocusOutside:o,onInteractOutside:i,onDismiss:s,...l}=e,c=K.useContext(Gz),[u,d]=K.useState(null),p=(null==u?void 0:u.ownerDocument)??(null==globalThis?void 0:globalThis.document),[,h]=K.useState({}),f=FL(t,(e=>d(e))),m=Array.from(c.layers),[g]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),y=m.indexOf(g),b=u?m.indexOf(u):-1,v=c.layersWithOutsidePointerEventsDisabled.size>0,k=b>=y,w=function(e,t=(null==globalThis?void 0:globalThis.document)){const n=qL(e),r=K.useRef(!1),a=K.useRef((()=>{}));return K.useEffect((()=>{const e=e=>{if(e.target&&!r.current){let r=function(){Yz(Uz,n,o,{discrete:!0})};const o={originalEvent:e};"touch"===e.pointerType?(t.removeEventListener("click",a.current),a.current=r,t.addEventListener("click",a.current,{once:!0})):r()}else t.removeEventListener("click",a.current);r.current=!1},o=window.setTimeout((()=>{t.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(o),t.removeEventListener("pointerdown",e),t.removeEventListener("click",a.current)}}),[t,n]),{onPointerDownCapture:()=>r.current=!0}}((e=>{const t=e.target,n=[...c.branches].some((e=>e.contains(t)));k&&!n&&(null==a||a(e),null==i||i(e),e.defaultPrevented||null==s||s())}),p),x=function(e,t=(null==globalThis?void 0:globalThis.document)){const n=qL(e),r=K.useRef(!1);return K.useEffect((()=>{const e=e=>{if(e.target&&!r.current){Yz($z,n,{originalEvent:e},{discrete:!1})}};return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)}),[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}((e=>{const t=e.target;[...c.branches].some((e=>e.contains(t)))||(null==o||o(e),null==i||i(e),e.defaultPrevented||null==s||s())}),p);return WL((e=>{b===c.layers.size-1&&(null==r||r(e),!e.defaultPrevented&&s&&(e.preventDefault(),s()))}),p),K.useEffect((()=>{if(u)return n&&(0===c.layersWithOutsidePointerEventsDisabled.size&&(zz=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(u)),c.layers.add(u),Wz(),()=>{n&&1===c.layersWithOutsidePointerEventsDisabled.size&&(p.body.style.pointerEvents=zz)}}),[u,p,n,c]),K.useEffect((()=>()=>{u&&(c.layers.delete(u),c.layersWithOutsidePointerEventsDisabled.delete(u),Wz())}),[u,c]),K.useEffect((()=>{const e=()=>h({});return document.addEventListener(Hz,e),()=>document.removeEventListener(Hz,e)}),[]),Wh.jsx(Bz.div,{...l,ref:f,style:{pointerEvents:v?k?"auto":"none":void 0,...e.style},onFocusCapture:DL(e.onFocusCapture,x.onFocusCapture),onBlurCapture:DL(e.onBlurCapture,x.onBlurCapture),onPointerDownCapture:DL(e.onPointerDownCapture,w.onPointerDownCapture)})}));Vz.displayName="DismissableLayer";var qz=K.forwardRef(((e,t)=>{const n=K.useContext(Gz),r=K.useRef(null),a=FL(t,r);return K.useEffect((()=>{const e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}}),[n.branches]),Wh.jsx(Bz.div,{...e,ref:a})}));function Wz(){const e=new CustomEvent(Hz);document.dispatchEvent(e)}function Yz(e,t,n,{discrete:r}){const a=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&a.addEventListener(e,t,{once:!0}),r?function(e,t){e&&se.flushSync((()=>e.dispatchEvent(t)))}(a,o):a.dispatchEvent(o)}qz.displayName="DismissableLayerBranch";var Kz=0;function Xz(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var Qz="focusScope.autoFocusOnMount",Zz="focusScope.autoFocusOnUnmount",Jz={bubbles:!1,cancelable:!0},eH=K.forwardRef(((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:a,onUnmountAutoFocus:o,...i}=e,[s,l]=K.useState(null),c=qL(a),u=qL(o),d=K.useRef(null),p=FL(t,(e=>l(e))),h=K.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;K.useEffect((()=>{if(r){let e=function(e){if(h.paused||!s)return;const t=e.target;s.contains(t)?d.current=t:aH(d.current,{select:!0})},t=function(e){if(h.paused||!s)return;const t=e.relatedTarget;null!==t&&(s.contains(t)||aH(d.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(const t of e)t.removedNodes.length>0&&aH(s)};document.addEventListener("focusin",e),document.addEventListener("focusout",t);const r=new MutationObserver(n);return s&&r.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),r.disconnect()}}}),[r,s,h.paused]),K.useEffect((()=>{if(s){oH.add(h);const t=document.activeElement;if(!s.contains(t)){const n=new CustomEvent(Qz,Jz);s.addEventListener(Qz,c),s.dispatchEvent(n),n.defaultPrevented||(!function(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(aH(r,{select:t}),document.activeElement!==n)return}((e=tH(s),e.filter((e=>"A"!==e.tagName))),{select:!0}),document.activeElement===t&&aH(s))}return()=>{s.removeEventListener(Qz,c),setTimeout((()=>{const e=new CustomEvent(Zz,Jz);s.addEventListener(Zz,u),s.dispatchEvent(e),e.defaultPrevented||aH(t??document.body,{select:!0}),s.removeEventListener(Zz,u),oH.remove(h)}),0)}}var e}),[s,c,u,h]);const f=K.useCallback((e=>{if(!n&&!r)return;if(h.paused)return;const t="Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey,a=document.activeElement;if(t&&a){const t=e.currentTarget,[r,o]=function(e){const t=tH(e),n=nH(t,e),r=nH(t.reverse(),e);return[n,r]}(t);r&&o?e.shiftKey||a!==o?e.shiftKey&&a===r&&(e.preventDefault(),n&&aH(o,{select:!0})):(e.preventDefault(),n&&aH(r,{select:!0})):a===t&&e.preventDefault()}}),[n,r,h.paused]);return Wh.jsx(Bz.div,{tabIndex:-1,...i,ref:p,onKeyDown:f})}));function tH(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{const t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function nH(e,t){for(const n of e)if(!rH(n,{upTo:t}))return n}function rH(e,{upTo:t}){if("hidden"===getComputedStyle(e).visibility)return!0;for(;e;){if(void 0!==t&&e===t)return!1;if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}function aH(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&function(e){return e instanceof HTMLInputElement&&"select"in e}(e)&&t&&e.select()}}eH.displayName="FocusScope";var oH=function(){let e=[];return{add(t){const n=e[0];t!==n&&(null==n||n.pause()),e=iH(e,t),e.unshift(t)},remove(t){var n;e=iH(e,t),null==(n=e[0])||n.resume()}}}();function iH(e,t){const n=[...e],r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}var sH=K.forwardRef(((e,t)=>{const{children:n,width:r=10,height:a=5,...o}=e;return Wh.jsx(Bz.svg,{...o,ref:t,width:r,height:a,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:Wh.jsx("polygon",{points:"0,0 30,0 15,10"})})}));sH.displayName="Arrow";var lH=sH,cH="Popper",[uH,dH]=jL(cH),[pH,hH]=uH(cH),fH=e=>{const{__scopePopper:t,children:n}=e,[r,a]=K.useState(null);return Wh.jsx(pH,{scope:t,anchor:r,onAnchorChange:a,children:n})};fH.displayName=cH;var mH="PopperAnchor",gH=K.forwardRef(((e,t)=>{const{__scopePopper:n,virtualRef:r,...a}=e,o=hH(mH,n),i=K.useRef(null),s=FL(t,i);return K.useEffect((()=>{o.onAnchorChange((null==r?void 0:r.current)||i.current)})),r?null:Wh.jsx(Bz.div,{...a,ref:s})}));gH.displayName=mH;var yH="PopperContent",[bH,vH]=uH(yH),kH=K.forwardRef(((e,t)=>{var n,r,a,o,i,s;const{__scopePopper:l,side:c="bottom",sideOffset:u=0,align:d="center",alignOffset:p=0,arrowPadding:h=0,avoidCollisions:f=!0,collisionBoundary:m=[],collisionPadding:g=0,sticky:y="partial",hideWhenDetached:b=!1,updatePositionStrategy:v="optimized",onPlaced:k,...w}=e,x=hH(yH,l),[E,_]=K.useState(null),S=FL(t,(e=>_(e))),[T,C]=K.useState(null),A=jF(T),N=(null==A?void 0:A.width)??0,I=(null==A?void 0:A.height)??0,R=c+("center"!==d?"-"+d:""),O="number"==typeof g?g:{top:0,right:0,bottom:0,left:0,...g},P=Array.isArray(m)?m:[m],D=P.length>0,L={padding:O,boundary:P.filter(_H),altBoundary:D},{refs:M,floatingStyles:F,placement:j,isPositioned:B,middlewareData:z}=CF({strategy:"fixed",placement:R,whileElementsMounted:(...e)=>hF(...e,{animationFrame:"always"===v}),elements:{reference:x.anchor},middleware:[NF({mainAxis:u+I,alignmentAxis:p}),f&&IF({mainAxis:!0,crossAxis:!1,limiter:"partial"===y?RF():void 0,...L}),f&&OF({...L}),PF({...L,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{const{width:a,height:o}=t.reference,i=e.floating.style;i.setProperty("--radix-popper-available-width",`${n}px`),i.setProperty("--radix-popper-available-height",`${r}px`),i.setProperty("--radix-popper-anchor-width",`${a}px`),i.setProperty("--radix-popper-anchor-height",`${o}px`)}}),T&&LF({element:T,padding:h}),SH({arrowWidth:N,arrowHeight:I}),b&&DF({strategy:"referenceHidden",...L})]}),[H,U]=TH(j),$=qL(k);rM((()=>{B&&(null==$||$())}),[B,$]);const G=null==(n=z.arrow)?void 0:n.x,V=null==(r=z.arrow)?void 0:r.y,q=0!==(null==(a=z.arrow)?void 0:a.centerOffset),[W,Y]=K.useState();return rM((()=>{E&&Y(window.getComputedStyle(E).zIndex)}),[E]),Wh.jsx("div",{ref:M.setFloating,"data-radix-popper-content-wrapper":"",style:{...F,transform:B?F.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:W,"--radix-popper-transform-origin":[null==(o=z.transformOrigin)?void 0:o.x,null==(i=z.transformOrigin)?void 0:i.y].join(" "),...(null==(s=z.hide)?void 0:s.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:Wh.jsx(bH,{scope:l,placedSide:H,onArrowChange:C,arrowX:G,arrowY:V,shouldHideArrow:q,children:Wh.jsx(Bz.div,{"data-side":H,"data-align":U,...w,ref:S,style:{...w.style,animation:B?void 0:"none"}})})})}));kH.displayName=yH;var wH="PopperArrow",xH={top:"bottom",right:"left",bottom:"top",left:"right"},EH=K.forwardRef((function(e,t){const{__scopePopper:n,...r}=e,a=vH(wH,n),o=xH[a.placedSide];return Wh.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:Wh.jsx(lH,{...r,ref:t,style:{...r.style,display:"block"}})})}));function _H(e){return null!==e}EH.displayName=wH;var SH=e=>({name:"transformOrigin",options:e,fn(t){var n,r,a;const{placement:o,rects:i,middlewareData:s}=t,l=0!==(null==(n=s.arrow)?void 0:n.centerOffset),c=l?0:e.arrowWidth,u=l?0:e.arrowHeight,[d,p]=TH(o),h={start:"0%",center:"50%",end:"100%"}[p],f=((null==(r=s.arrow)?void 0:r.x)??0)+c/2,m=((null==(a=s.arrow)?void 0:a.y)??0)+u/2;let g="",y="";return"bottom"===d?(g=l?h:`${f}px`,y=-u+"px"):"top"===d?(g=l?h:`${f}px`,y=`${i.floating.height+u}px`):"right"===d?(g=-u+"px",y=l?h:`${m}px`):"left"===d&&(g=`${i.floating.width+u}px`,y=l?h:`${m}px`),{data:{x:g,y:y}}}});function TH(e){const[t,n="center"]=e.split("-");return[t,n]}var CH=fH,AH=gH,NH=kH,IH=EH,RH=new WeakMap,OH=new WeakMap,PH={},DH=0,LH=function(e){return e&&(e.host||LH(e.parentNode))},MH=function(e,t,n,r){var a=function(e,t){return t.map((function(t){if(e.contains(t))return t;var n=LH(t);return n&&e.contains(n)?n:(console.error("aria-hidden",t,"in not contained inside",e,". Doing nothing"),null)})).filter((function(e){return Boolean(e)}))}(t,Array.isArray(e)?e:[e]);PH[n]||(PH[n]=new WeakMap);var o=PH[n],i=[],s=new Set,l=new Set(a),c=function(e){e&&!s.has(e)&&(s.add(e),c(e.parentNode))};a.forEach(c);var u=function(e){e&&!l.has(e)&&Array.prototype.forEach.call(e.children,(function(e){if(s.has(e))u(e);else try{var t=e.getAttribute(r),a=null!==t&&"false"!==t,l=(RH.get(e)||0)+1,c=(o.get(e)||0)+1;RH.set(e,l),o.set(e,c),i.push(e),1===l&&a&&OH.set(e,!0),1===c&&e.setAttribute(n,"true"),a||e.setAttribute(r,"true")}catch(X4){console.error("aria-hidden: cannot operate on ",e,X4)}}))};return u(t),s.clear(),DH++,function(){i.forEach((function(e){var t=RH.get(e)-1,a=o.get(e)-1;RH.set(e,t),o.set(e,a),t||(OH.has(e)||e.removeAttribute(r),OH.delete(e)),a||e.removeAttribute(n)})),--DH||(RH=new WeakMap,RH=new WeakMap,OH=new WeakMap,PH={})}},FH=function(e,t,n){void 0===n&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),a=function(e){return"undefined"==typeof document?null:(Array.isArray(e)?e[0]:e).ownerDocument.body}(e);return a?(r.push.apply(r,Array.from(a.querySelectorAll("[aria-live]"))),MH(r,a,n,"aria-hidden")):function(){return null}},jH=function(){return jH=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e},jH.apply(this,arguments)};function BH(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var a=0;for(r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]])}return n}function zH(e,t,n){if(n||2===arguments.length)for(var r,a=0,o=t.length;a<o;a++)!r&&a in t||(r||(r=Array.prototype.slice.call(t,0,a)),r[a]=t[a]);return e.concat(r||Array.prototype.slice.call(t))}"function"==typeof SuppressedError&&SuppressedError;var HH="right-scroll-bar-position",UH="width-before-scroll-bar";function $H(e,t){return"function"==typeof e?e(t):e&&(e.current=t),e}var GH="undefined"!=typeof window?K.useLayoutEffect:K.useEffect,VH=new WeakMap;function qH(e,t){var n,r,a,o=(n=null,r=function(t){return e.forEach((function(e){return $H(e,t)}))},(a=K.useState((function(){return{value:n,callback:r,facade:{get current(){return a.value},set current(e){var t=a.value;t!==e&&(a.value=e,a.callback(e,t))}}}}))[0]).callback=r,a.facade);return GH((function(){var t=VH.get(o);if(t){var n=new Set(t),r=new Set(e),a=o.current;n.forEach((function(e){r.has(e)||$H(e,null)})),r.forEach((function(e){n.has(e)||$H(e,a)}))}VH.set(o,e)}),[e]),o}function WH(e){return e}var YH=function(e){var t=e.sideCar,n=BH(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return K.createElement(r,jH({},n))};YH.isSideCarExport=!0;var KH=function(e){void 0===e&&(e={});var t=function(e,t){void 0===t&&(t=WH);var n=[],r=!1;return{read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(e){var a=t(e,r);return n.push(a),function(){n=n.filter((function(e){return e!==a}))}},assignSyncMedium:function(e){for(r=!0;n.length;){var t=n;n=[],t.forEach(e)}n={push:function(t){return e(t)},filter:function(){return n}}},assignMedium:function(e){r=!0;var t=[];if(n.length){var a=n;n=[],a.forEach(e),t=n}var o=function(){var n=t;t=[],n.forEach(e)},i=function(){return Promise.resolve().then(o)};i(),n={push:function(e){t.push(e),i()},filter:function(e){return t=t.filter(e),n}}}}}(null);return t.options=jH({async:!0,ssr:!1},e),t}(),XH=function(){},QH=K.forwardRef((function(e,t){var n=K.useRef(null),r=K.useState({onScrollCapture:XH,onWheelCapture:XH,onTouchMoveCapture:XH}),a=r[0],o=r[1],i=e.forwardProps,s=e.children,l=e.className,c=e.removeScrollBar,u=e.enabled,d=e.shards,p=e.sideCar,h=e.noRelative,f=e.noIsolation,m=e.inert,g=e.allowPinchZoom,y=e.as,b=void 0===y?"div":y,v=e.gapMode,k=BH(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),w=p,x=qH([n,t]),E=jH(jH({},k),a);return K.createElement(K.Fragment,null,u&&K.createElement(w,{sideCar:KH,removeScrollBar:c,shards:d,noRelative:h,noIsolation:f,inert:m,setCallbacks:o,allowPinchZoom:!!g,lockRef:n,gapMode:v}),i?K.cloneElement(K.Children.only(s),jH(jH({},E),{ref:x})):K.createElement(b,jH({},E,{className:l,ref:x}),s))}));QH.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},QH.classNames={fullWidth:UH,zeroRight:HH};function ZH(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=function(){if("undefined"!=typeof __webpack_nonce__)return __webpack_nonce__}();return t&&e.setAttribute("nonce",t),e}var JH=function(){var e=0,t=null;return{add:function(n){var r,a;0==e&&(t=ZH())&&(a=n,(r=t).styleSheet?r.styleSheet.cssText=a:r.appendChild(document.createTextNode(a)),function(e){(document.head||document.getElementsByTagName("head")[0]).appendChild(e)}(t)),e++},remove:function(){! --e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},eU=function(){var e,t=(e=JH(),function(t,n){K.useEffect((function(){return e.add(t),function(){e.remove()}}),[t&&n])});return function(e){var n=e.styles,r=e.dynamic;return t(n,r),null}},tU={left:0,top:0,right:0,gap:0},nU=function(e){return parseInt(e||"",10)||0},rU=function(e){if(void 0===e&&(e="margin"),"undefined"==typeof window)return tU;var t=function(e){var t=window.getComputedStyle(document.body),n=t["padding"===e?"paddingLeft":"marginLeft"],r=t["padding"===e?"paddingTop":"marginTop"],a=t["padding"===e?"paddingRight":"marginRight"];return[nU(n),nU(r),nU(a)]}(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},aU=eU(),oU="data-scroll-locked",iU=function(e,t,n,r){var a=e.left,o=e.top,i=e.right,s=e.gap;return void 0===n&&(n="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(r,";\n padding-right: ").concat(s,"px ").concat(r,";\n }\n body[").concat(oU,"] {\n overflow: hidden ").concat(r,";\n overscroll-behavior: contain;\n ").concat([t&&"position: relative ".concat(r,";"),"margin"===n&&"\n padding-left: ".concat(a,"px;\n padding-top: ").concat(o,"px;\n padding-right: ").concat(i,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(s,"px ").concat(r,";\n "),"padding"===n&&"padding-right: ".concat(s,"px ").concat(r,";")].filter(Boolean).join(""),"\n }\n \n .").concat(HH," {\n right: ").concat(s,"px ").concat(r,";\n }\n \n .").concat(UH," {\n margin-right: ").concat(s,"px ").concat(r,";\n }\n \n .").concat(HH," .").concat(HH," {\n right: 0 ").concat(r,";\n }\n \n .").concat(UH," .").concat(UH," {\n margin-right: 0 ").concat(r,";\n }\n \n body[").concat(oU,"] {\n ").concat("--removed-body-scroll-bar-size",": ").concat(s,"px;\n }\n")},sU=function(){var e=parseInt(document.body.getAttribute(oU)||"0",10);return isFinite(e)?e:0},lU=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,a=void 0===r?"margin":r;K.useEffect((function(){return document.body.setAttribute(oU,(sU()+1).toString()),function(){var e=sU()-1;e<=0?document.body.removeAttribute(oU):document.body.setAttribute(oU,e.toString())}}),[]);var o=K.useMemo((function(){return rU(a)}),[a]);return K.createElement(aU,{styles:iU(o,!t,a,n?"":"!important")})},cU=!1;if("undefined"!=typeof window)try{var uU=Object.defineProperty({},"passive",{get:function(){return cU=!0,!0}});window.addEventListener("test",uU,uU),window.removeEventListener("test",uU,uU)}catch(xbe){cU=!1}var dU=!!cU&&{passive:!1},pU=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return"hidden"!==n[t]&&!(n.overflowY===n.overflowX&&!function(e){return"TEXTAREA"===e.tagName}(e)&&"visible"===n[t])},hU=function(e,t){var n=t.ownerDocument,r=t;do{if("undefined"!=typeof ShadowRoot&&r instanceof ShadowRoot&&(r=r.host),fU(e,r)){var a=mU(e,r);if(a[1]>a[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},fU=function(e,t){return"v"===e?function(e){return pU(e,"overflowY")}(t):function(e){return pU(e,"overflowX")}(t)},mU=function(e,t){return"v"===e?[(n=t).scrollTop,n.scrollHeight,n.clientHeight]:function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]}(t);var n},gU=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},yU=function(e){return[e.deltaX,e.deltaY]},bU=function(e){return e&&"current"in e?e.current:e},vU=function(e){return"\n .block-interactivity-".concat(e," {pointer-events: none;}\n .allow-interactivity-").concat(e," {pointer-events: all;}\n")},kU=0,wU=[];function xU(e){for(var t=null;null!==e;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const EU=(_U=function(e){var t=K.useRef([]),n=K.useRef([0,0]),r=K.useRef(),a=K.useState(kU++)[0],o=K.useState(eU)[0],i=K.useRef(e);K.useEffect((function(){i.current=e}),[e]),K.useEffect((function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(a));var t=zH([e.lockRef.current],(e.shards||[]).map(bU),!0).filter(Boolean);return t.forEach((function(e){return e.classList.add("allow-interactivity-".concat(a))})),function(){document.body.classList.remove("block-interactivity-".concat(a)),t.forEach((function(e){return e.classList.remove("allow-interactivity-".concat(a))}))}}}),[e.inert,e.lockRef.current,e.shards]);var s=K.useCallback((function(e,t){if("touches"in e&&2===e.touches.length||"wheel"===e.type&&e.ctrlKey)return!i.current.allowPinchZoom;var a,o=gU(e),s=n.current,l="deltaX"in e?e.deltaX:s[0]-o[0],c="deltaY"in e?e.deltaY:s[1]-o[1],u=e.target,d=Math.abs(l)>Math.abs(c)?"h":"v";if("touches"in e&&"h"===d&&"range"===u.type)return!1;var p=hU(d,u);if(!p)return!0;if(p?a=d:(a="v"===d?"h":"v",p=hU(d,u)),!p)return!1;if(!r.current&&"changedTouches"in e&&(l||c)&&(r.current=a),!a)return!0;var h=r.current||a;return function(e,t,n,r){var a=function(e,t){return"h"===e&&"rtl"===t?-1:1}(e,window.getComputedStyle(t).direction),o=a*r,i=n.target,s=t.contains(i),l=!1,c=o>0,u=0,d=0;do{if(!i)break;var p=mU(e,i),h=p[0],f=p[1]-p[2]-a*h;(h||f)&&fU(e,i)&&(u+=f,d+=h);var m=i.parentNode;i=m&&m.nodeType===Node.DOCUMENT_FRAGMENT_NODE?m.host:m}while(!s&&i!==document.body||s&&(t.contains(i)||t===i));return(c&&Math.abs(u)<1||!c&&Math.abs(d)<1)&&(l=!0),l}(h,t,e,"h"===h?l:c)}),[]),l=K.useCallback((function(e){var n=e;if(wU.length&&wU[wU.length-1]===o){var r="deltaY"in n?yU(n):gU(n),a=t.current.filter((function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&(t=e.delta,a=r,t[0]===a[0]&&t[1]===a[1]);var t,a}))[0];if(a&&a.should)n.cancelable&&n.preventDefault();else if(!a){var l=(i.current.shards||[]).map(bU).filter(Boolean).filter((function(e){return e.contains(n.target)}));(l.length>0?s(n,l[0]):!i.current.noIsolation)&&n.cancelable&&n.preventDefault()}}}),[]),c=K.useCallback((function(e,n,r,a){var o={name:e,delta:n,target:r,should:a,shadowParent:xU(r)};t.current.push(o),setTimeout((function(){t.current=t.current.filter((function(e){return e!==o}))}),1)}),[]),u=K.useCallback((function(e){n.current=gU(e),r.current=void 0}),[]),d=K.useCallback((function(t){c(t.type,yU(t),t.target,s(t,e.lockRef.current))}),[]),p=K.useCallback((function(t){c(t.type,gU(t),t.target,s(t,e.lockRef.current))}),[]);K.useEffect((function(){return wU.push(o),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:p}),document.addEventListener("wheel",l,dU),document.addEventListener("touchmove",l,dU),document.addEventListener("touchstart",u,dU),function(){wU=wU.filter((function(e){return e!==o})),document.removeEventListener("wheel",l,dU),document.removeEventListener("touchmove",l,dU),document.removeEventListener("touchstart",u,dU)}}),[]);var h=e.removeScrollBar,f=e.inert;return K.createElement(K.Fragment,null,f?K.createElement(o,{styles:vU(a)}):null,h?K.createElement(lU,{noRelative:e.noRelative,gapMode:e.gapMode}):null)},KH.useMedium(_U),YH);var _U,SU=K.forwardRef((function(e,t){return K.createElement(QH,jH({},e,{ref:t,sideCar:EU}))}));SU.classNames=QH.classNames;var TU="Popover",[CU,AU]=jL(TU,[dH]),NU=dH(),[IU,RU]=CU(TU),OU=e=>{const{__scopePopover:t,children:n,open:r,defaultOpen:a,onOpenChange:o,modal:i=!1}=e,s=NU(t),l=K.useRef(null),[c,u]=K.useState(!1),[d=!1,p]=cj({prop:r,defaultProp:a,onChange:o});return Wh.jsx(CH,{...s,children:Wh.jsx(IU,{scope:t,contentId:iM(),triggerRef:l,open:d,onOpenChange:p,onOpenToggle:K.useCallback((()=>p((e=>!e))),[p]),hasCustomAnchor:c,onCustomAnchorAdd:K.useCallback((()=>u(!0)),[]),onCustomAnchorRemove:K.useCallback((()=>u(!1)),[]),modal:i,children:n})})};OU.displayName=TU;var PU="PopoverAnchor",DU=K.forwardRef(((e,t)=>{const{__scopePopover:n,...r}=e,a=RU(PU,n),o=NU(n),{onCustomAnchorAdd:i,onCustomAnchorRemove:s}=a;return K.useEffect((()=>(i(),()=>s())),[i,s]),Wh.jsx(AH,{...o,...r,ref:t})}));DU.displayName=PU;var LU="PopoverTrigger",MU=K.forwardRef(((e,t)=>{const{__scopePopover:n,...r}=e,a=RU(LU,n),o=NU(n),i=FL(t,a.triggerRef),s=Wh.jsx(Bz.button,{type:"button","aria-haspopup":"dialog","aria-expanded":a.open,"aria-controls":a.contentId,"data-state":WU(a.open),...r,ref:i,onClick:DL(e.onClick,a.onOpenToggle)});return a.hasCustomAnchor?s:Wh.jsx(AH,{asChild:!0,...o,children:s})}));MU.displayName=LU;var[FU,jU]=CU("PopoverPortal",{forceMount:void 0}),BU="PopoverContent",zU=K.forwardRef(((e,t)=>{const n=jU(BU,e.__scopePopover),{forceMount:r=n.forceMount,...a}=e,o=RU(BU,e.__scopePopover);return Wh.jsx(sj,{present:r||o.open,children:o.modal?Wh.jsx(HU,{...a,ref:t}):Wh.jsx(UU,{...a,ref:t})})}));zU.displayName=BU;var HU=K.forwardRef(((e,t)=>{const n=RU(BU,e.__scopePopover),r=K.useRef(null),a=FL(t,r),o=K.useRef(!1);return K.useEffect((()=>{const e=r.current;if(e)return FH(e)}),[]),Wh.jsx(SU,{as:Lz,allowPinchZoom:!0,children:Wh.jsx($U,{...e,ref:a,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:DL(e.onCloseAutoFocus,(e=>{var t;e.preventDefault(),o.current||null==(t=n.triggerRef.current)||t.focus()})),onPointerDownOutside:DL(e.onPointerDownOutside,(e=>{const t=e.detail.originalEvent,n=0===t.button&&!0===t.ctrlKey,r=2===t.button||n;o.current=r}),{checkForDefaultPrevented:!1}),onFocusOutside:DL(e.onFocusOutside,(e=>e.preventDefault()),{checkForDefaultPrevented:!1})})})})),UU=K.forwardRef(((e,t)=>{const n=RU(BU,e.__scopePopover),r=K.useRef(!1),a=K.useRef(!1);return Wh.jsx($U,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{var o,i;null==(o=e.onCloseAutoFocus)||o.call(e,t),t.defaultPrevented||(r.current||null==(i=n.triggerRef.current)||i.focus(),t.preventDefault()),r.current=!1,a.current=!1},onInteractOutside:t=>{var o,i;null==(o=e.onInteractOutside)||o.call(e,t),t.defaultPrevented||(r.current=!0,"pointerdown"===t.detail.originalEvent.type&&(a.current=!0));const s=t.target;(null==(i=n.triggerRef.current)?void 0:i.contains(s))&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&a.current&&t.preventDefault()}})})),$U=K.forwardRef(((e,t)=>{const{__scopePopover:n,trapFocus:r,onOpenAutoFocus:a,onCloseAutoFocus:o,disableOutsidePointerEvents:i,onEscapeKeyDown:s,onPointerDownOutside:l,onFocusOutside:c,onInteractOutside:u,...d}=e,p=RU(BU,n),h=NU(n);return K.useEffect((()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Xz()),document.body.insertAdjacentElement("beforeend",e[1]??Xz()),Kz++,()=>{1===Kz&&document.querySelectorAll("[data-radix-focus-guard]").forEach((e=>e.remove())),Kz--}}),[]),Wh.jsx(eH,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:a,onUnmountAutoFocus:o,children:Wh.jsx(Vz,{asChild:!0,disableOutsidePointerEvents:i,onInteractOutside:u,onEscapeKeyDown:s,onPointerDownOutside:l,onFocusOutside:c,onDismiss:()=>p.onOpenChange(!1),children:Wh.jsx(NH,{"data-state":WU(p.open),role:"dialog",id:p.contentId,...h,...d,ref:t,style:{...d.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})})),GU="PopoverClose",VU=K.forwardRef(((e,t)=>{const{__scopePopover:n,...r}=e,a=RU(GU,n);return Wh.jsx(Bz.button,{type:"button",...r,ref:t,onClick:DL(e.onClick,(()=>a.onOpenChange(!1)))})}));VU.displayName=GU;var qU=K.forwardRef(((e,t)=>{const{__scopePopover:n,...r}=e,a=NU(n);return Wh.jsx(IH,{...a,...r,ref:t})}));function WU(e){return e?"open":"closed"}qU.displayName="PopoverArrow";var YU=OU,KU=MU,XU=zU,QU=qU,ZU=K.createContext(void 0);var JU="ScrollArea",[e$,t$]=jL(JU),[n$,r$]=e$(JU),a$=K.forwardRef(((e,t)=>{const{__scopeScrollArea:n,type:r="hover",dir:a,scrollHideDelay:o=600,...i}=e,[s,l]=K.useState(null),[c,u]=K.useState(null),[d,p]=K.useState(null),[h,f]=K.useState(null),[m,g]=K.useState(null),[y,b]=K.useState(0),[v,k]=K.useState(0),[w,x]=K.useState(!1),[E,_]=K.useState(!1),S=FL(t,(e=>l(e))),T=function(e){const t=K.useContext(ZU);return e||t||"ltr"}(a);return Wh.jsx(n$,{scope:n,type:r,dir:T,scrollHideDelay:o,scrollArea:s,viewport:c,onViewportChange:u,content:d,onContentChange:p,scrollbarX:h,onScrollbarXChange:f,scrollbarXEnabled:w,onScrollbarXEnabledChange:x,scrollbarY:m,onScrollbarYChange:g,scrollbarYEnabled:E,onScrollbarYEnabledChange:_,onCornerWidthChange:b,onCornerHeightChange:k,children:Wh.jsx(VL.div,{dir:T,...i,ref:S,style:{position:"relative","--radix-scroll-area-corner-width":y+"px","--radix-scroll-area-corner-height":v+"px",...e.style}})})}));a$.displayName=JU;var o$="ScrollAreaViewport",i$=K.forwardRef(((e,t)=>{const{__scopeScrollArea:n,children:r,nonce:a,...o}=e,i=r$(o$,n),s=FL(t,K.useRef(null),i.onViewportChange);return Wh.jsxs(Wh.Fragment,{children:[Wh.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"},nonce:a}),Wh.jsx(VL.div,{"data-radix-scroll-area-viewport":"",...o,ref:s,style:{overflowX:i.scrollbarXEnabled?"scroll":"hidden",overflowY:i.scrollbarYEnabled?"scroll":"hidden",...e.style},children:Wh.jsx("div",{ref:i.onContentChange,style:{minWidth:"100%",display:"table"},children:r})})]})}));i$.displayName=o$;var s$="ScrollAreaScrollbar",l$=K.forwardRef(((e,t)=>{const{forceMount:n,...r}=e,a=r$(s$,e.__scopeScrollArea),{onScrollbarXEnabledChange:o,onScrollbarYEnabledChange:i}=a,s="horizontal"===e.orientation;return K.useEffect((()=>(s?o(!0):i(!0),()=>{s?o(!1):i(!1)})),[s,o,i]),"hover"===a.type?Wh.jsx(c$,{...r,ref:t,forceMount:n}):"scroll"===a.type?Wh.jsx(u$,{...r,ref:t,forceMount:n}):"auto"===a.type?Wh.jsx(d$,{...r,ref:t,forceMount:n}):"always"===a.type?Wh.jsx(p$,{...r,ref:t}):null}));l$.displayName=s$;var c$=K.forwardRef(((e,t)=>{const{forceMount:n,...r}=e,a=r$(s$,e.__scopeScrollArea),[o,i]=K.useState(!1);return K.useEffect((()=>{const e=a.scrollArea;let t=0;if(e){const n=()=>{window.clearTimeout(t),i(!0)},r=()=>{t=window.setTimeout((()=>i(!1)),a.scrollHideDelay)};return e.addEventListener("pointerenter",n),e.addEventListener("pointerleave",r),()=>{window.clearTimeout(t),e.removeEventListener("pointerenter",n),e.removeEventListener("pointerleave",r)}}}),[a.scrollArea,a.scrollHideDelay]),Wh.jsx(sj,{present:n||o,children:Wh.jsx(d$,{"data-state":o?"visible":"hidden",...r,ref:t})})})),u$=K.forwardRef(((e,t)=>{const{forceMount:n,...r}=e,a=r$(s$,e.__scopeScrollArea),o="horizontal"===e.orientation,i=R$((()=>l("SCROLL_END")),100),[s,l]=(c="hidden",u={hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}},K.useReducer(((e,t)=>u[e][t]??e),c));var c,u;return K.useEffect((()=>{if("idle"===s){const e=window.setTimeout((()=>l("HIDE")),a.scrollHideDelay);return()=>window.clearTimeout(e)}}),[s,a.scrollHideDelay,l]),K.useEffect((()=>{const e=a.viewport,t=o?"scrollLeft":"scrollTop";if(e){let n=e[t];const r=()=>{const r=e[t];n!==r&&(l("SCROLL"),i()),n=r};return e.addEventListener("scroll",r),()=>e.removeEventListener("scroll",r)}}),[a.viewport,o,l,i]),Wh.jsx(sj,{present:n||"hidden"!==s,children:Wh.jsx(p$,{"data-state":"hidden"===s?"hidden":"visible",...r,ref:t,onPointerEnter:DL(e.onPointerEnter,(()=>l("POINTER_ENTER"))),onPointerLeave:DL(e.onPointerLeave,(()=>l("POINTER_LEAVE")))})})})),d$=K.forwardRef(((e,t)=>{const n=r$(s$,e.__scopeScrollArea),{forceMount:r,...a}=e,[o,i]=K.useState(!1),s="horizontal"===e.orientation,l=R$((()=>{if(n.viewport){const e=n.viewport.offsetWidth<n.viewport.scrollWidth,t=n.viewport.offsetHeight<n.viewport.scrollHeight;i(s?e:t)}}),10);return O$(n.viewport,l),O$(n.content,l),Wh.jsx(sj,{present:r||o,children:Wh.jsx(p$,{"data-state":o?"visible":"hidden",...a,ref:t})})})),p$=K.forwardRef(((e,t)=>{const{orientation:n="vertical",...r}=e,a=r$(s$,e.__scopeScrollArea),o=K.useRef(null),i=K.useRef(0),[s,l]=K.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),c=S$(s.viewport,s.content),u={...r,sizes:s,onSizesChange:l,hasThumb:Boolean(c>0&&c<1),onThumbChange:e=>o.current=e,onThumbPointerUp:()=>i.current=0,onThumbPointerDown:e=>i.current=e};function d(e,t){return function(e,t,n,r="ltr"){const a=T$(n),o=a/2,i=t||o,s=a-i,l=n.scrollbar.paddingStart+i,c=n.scrollbar.size-n.scrollbar.paddingEnd-s,u=n.content-n.viewport,d="ltr"===r?[0,u]:[-1*u,0];return A$([l,c],d)(e)}(e,i.current,s,t)}return"horizontal"===n?Wh.jsx(h$,{...u,ref:t,onThumbPositionChange:()=>{if(a.viewport&&o.current){const e=C$(a.viewport.scrollLeft,s,a.dir);o.current.style.transform=`translate3d(${e}px, 0, 0)`}},onWheelScroll:e=>{a.viewport&&(a.viewport.scrollLeft=e)},onDragScroll:e=>{a.viewport&&(a.viewport.scrollLeft=d(e,a.dir))}}):"vertical"===n?Wh.jsx(f$,{...u,ref:t,onThumbPositionChange:()=>{if(a.viewport&&o.current){const e=C$(a.viewport.scrollTop,s);o.current.style.transform=`translate3d(0, ${e}px, 0)`}},onWheelScroll:e=>{a.viewport&&(a.viewport.scrollTop=e)},onDragScroll:e=>{a.viewport&&(a.viewport.scrollTop=d(e))}}):null})),h$=K.forwardRef(((e,t)=>{const{sizes:n,onSizesChange:r,...a}=e,o=r$(s$,e.__scopeScrollArea),[i,s]=K.useState(),l=K.useRef(null),c=FL(t,l,o.onScrollbarXChange);return K.useEffect((()=>{l.current&&s(getComputedStyle(l.current))}),[l]),Wh.jsx(y$,{"data-orientation":"horizontal",...a,ref:c,sizes:n,style:{bottom:0,left:"rtl"===o.dir?"var(--radix-scroll-area-corner-width)":0,right:"ltr"===o.dir?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":T$(n)+"px",...e.style},onThumbPointerDown:t=>e.onThumbPointerDown(t.x),onDragScroll:t=>e.onDragScroll(t.x),onWheelScroll:(t,n)=>{if(o.viewport){const r=o.viewport.scrollLeft+t.deltaX;e.onWheelScroll(r),N$(r,n)&&t.preventDefault()}},onResize:()=>{l.current&&o.viewport&&i&&r({content:o.viewport.scrollWidth,viewport:o.viewport.offsetWidth,scrollbar:{size:l.current.clientWidth,paddingStart:_$(i.paddingLeft),paddingEnd:_$(i.paddingRight)}})}})})),f$=K.forwardRef(((e,t)=>{const{sizes:n,onSizesChange:r,...a}=e,o=r$(s$,e.__scopeScrollArea),[i,s]=K.useState(),l=K.useRef(null),c=FL(t,l,o.onScrollbarYChange);return K.useEffect((()=>{l.current&&s(getComputedStyle(l.current))}),[l]),Wh.jsx(y$,{"data-orientation":"vertical",...a,ref:c,sizes:n,style:{top:0,right:"ltr"===o.dir?0:void 0,left:"rtl"===o.dir?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":T$(n)+"px",...e.style},onThumbPointerDown:t=>e.onThumbPointerDown(t.y),onDragScroll:t=>e.onDragScroll(t.y),onWheelScroll:(t,n)=>{if(o.viewport){const r=o.viewport.scrollTop+t.deltaY;e.onWheelScroll(r),N$(r,n)&&t.preventDefault()}},onResize:()=>{l.current&&o.viewport&&i&&r({content:o.viewport.scrollHeight,viewport:o.viewport.offsetHeight,scrollbar:{size:l.current.clientHeight,paddingStart:_$(i.paddingTop),paddingEnd:_$(i.paddingBottom)}})}})})),[m$,g$]=e$(s$),y$=K.forwardRef(((e,t)=>{const{__scopeScrollArea:n,sizes:r,hasThumb:a,onThumbChange:o,onThumbPointerUp:i,onThumbPointerDown:s,onThumbPositionChange:l,onDragScroll:c,onWheelScroll:u,onResize:d,...p}=e,h=r$(s$,n),[f,m]=K.useState(null),g=FL(t,(e=>m(e))),y=K.useRef(null),b=K.useRef(""),v=h.viewport,k=r.content-r.viewport,w=qL(u),x=qL(l),E=R$(d,10);function _(e){if(y.current){const t=e.clientX-y.current.left,n=e.clientY-y.current.top;c({x:t,y:n})}}return K.useEffect((()=>{const e=e=>{const t=e.target;(null==f?void 0:f.contains(t))&&w(e,k)};return document.addEventListener("wheel",e,{passive:!1}),()=>document.removeEventListener("wheel",e,{passive:!1})}),[v,f,k,w]),K.useEffect(x,[r,x]),O$(f,E),O$(h.content,E),Wh.jsx(m$,{scope:n,scrollbar:f,hasThumb:a,onThumbChange:qL(o),onThumbPointerUp:qL(i),onThumbPositionChange:x,onThumbPointerDown:qL(s),children:Wh.jsx(VL.div,{...p,ref:g,style:{position:"absolute",...p.style},onPointerDown:DL(e.onPointerDown,(e=>{if(0===e.button){e.target.setPointerCapture(e.pointerId),y.current=f.getBoundingClientRect(),b.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",h.viewport&&(h.viewport.style.scrollBehavior="auto"),_(e)}})),onPointerMove:DL(e.onPointerMove,_),onPointerUp:DL(e.onPointerUp,(e=>{const t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),document.body.style.webkitUserSelect=b.current,h.viewport&&(h.viewport.style.scrollBehavior=""),y.current=null}))})})})),b$="ScrollAreaThumb",v$=K.forwardRef(((e,t)=>{const{forceMount:n,...r}=e,a=g$(b$,e.__scopeScrollArea);return Wh.jsx(sj,{present:n||a.hasThumb,children:Wh.jsx(k$,{ref:t,...r})})})),k$=K.forwardRef(((e,t)=>{const{__scopeScrollArea:n,style:r,...a}=e,o=r$(b$,n),i=g$(b$,n),{onThumbPositionChange:s}=i,l=FL(t,(e=>i.onThumbChange(e))),c=K.useRef(void 0),u=R$((()=>{c.current&&(c.current(),c.current=void 0)}),100);return K.useEffect((()=>{const e=o.viewport;if(e){const t=()=>{if(u(),!c.current){const t=I$(e,s);c.current=t,s()}};return s(),e.addEventListener("scroll",t),()=>e.removeEventListener("scroll",t)}}),[o.viewport,u,s]),Wh.jsx(VL.div,{"data-state":i.hasThumb?"visible":"hidden",...a,ref:l,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...r},onPointerDownCapture:DL(e.onPointerDownCapture,(e=>{const t=e.target.getBoundingClientRect(),n=e.clientX-t.left,r=e.clientY-t.top;i.onThumbPointerDown({x:n,y:r})})),onPointerUp:DL(e.onPointerUp,i.onThumbPointerUp)})}));v$.displayName=b$;var w$="ScrollAreaCorner",x$=K.forwardRef(((e,t)=>{const n=r$(w$,e.__scopeScrollArea),r=Boolean(n.scrollbarX&&n.scrollbarY);return"scroll"!==n.type&&r?Wh.jsx(E$,{...e,ref:t}):null}));x$.displayName=w$;var E$=K.forwardRef(((e,t)=>{const{__scopeScrollArea:n,...r}=e,a=r$(w$,n),[o,i]=K.useState(0),[s,l]=K.useState(0),c=Boolean(o&&s);return O$(a.scrollbarX,(()=>{var e;const t=(null==(e=a.scrollbarX)?void 0:e.offsetHeight)||0;a.onCornerHeightChange(t),l(t)})),O$(a.scrollbarY,(()=>{var e;const t=(null==(e=a.scrollbarY)?void 0:e.offsetWidth)||0;a.onCornerWidthChange(t),i(t)})),c?Wh.jsx(VL.div,{...r,ref:t,style:{width:o,height:s,position:"absolute",right:"ltr"===a.dir?0:void 0,left:"rtl"===a.dir?0:void 0,bottom:0,...e.style}}):null}));function _$(e){return e?parseInt(e,10):0}function S$(e,t){const n=e/t;return isNaN(n)?0:n}function T$(e){const t=S$(e.viewport,e.content),n=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,r=(e.scrollbar.size-n)*t;return Math.max(r,18)}function C$(e,t,n="ltr"){const r=T$(t),a=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,o=t.scrollbar.size-a,i=t.content-t.viewport,s=o-r,l=function(e,[t,n]){return Math.min(n,Math.max(t,e))}(e,"ltr"===n?[0,i]:[-1*i,0]);return A$([0,i],[0,s])(l)}function A$(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}function N$(e,t){return e>0&&e<t}var I$=(e,t=()=>{})=>{let n={left:e.scrollLeft,top:e.scrollTop},r=0;return function a(){const o={left:e.scrollLeft,top:e.scrollTop},i=n.left!==o.left,s=n.top!==o.top;(i||s)&&t(),n=o,r=window.requestAnimationFrame(a)}(),()=>window.cancelAnimationFrame(r)};function R$(e,t){const n=qL(e),r=K.useRef(0);return K.useEffect((()=>()=>window.clearTimeout(r.current)),[]),K.useCallback((()=>{window.clearTimeout(r.current),r.current=window.setTimeout(n,t)}),[n,t])}function O$(e,t){const n=qL(t);rM((()=>{let t=0;if(e){const r=new ResizeObserver((()=>{cancelAnimationFrame(t),t=window.requestAnimationFrame(n)}));return r.observe(e),()=>{window.cancelAnimationFrame(t),r.unobserve(e)}}}),[e,n])}var P$=a$,D$=i$,L$=x$;function M$(e,[t,n]){return Math.min(n,Math.max(t,e))}function F$(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}function j$(e,t=[]){let n=[];const r=()=>{const t=n.map((e=>K.createContext(e)));return function(n){const r=(null==n?void 0:n[e])||t;return K.useMemo((()=>({[`__scope${e}`]:{...n,[e]:r}})),[n,r])}};return r.scopeName=e,[function(t,r){const a=K.createContext(r),o=n.length;n=[...n,r];const i=t=>{var n;const{scope:r,children:i,...s}=t,l=(null==(n=null==r?void 0:r[e])?void 0:n[o])||a,c=K.useMemo((()=>s),Object.values(s));return Wh.jsx(l.Provider,{value:c,children:i})};return i.displayName=t+"Provider",[i,function(n,i){var s;const l=(null==(s=null==i?void 0:i[e])?void 0:s[o])||a,c=K.useContext(l);if(c)return c;if(void 0!==r)return r;throw new Error(`\`${n}\` must be used within \`${t}\``)}]},B$(r,...t)]}function B$(...e){const t=e[0];if(1===e.length)return t;const n=()=>{const n=e.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(e){const r=n.reduce(((t,{useScope:n,scopeName:r})=>({...t,...n(e)[`__scope${r}`]})),{});return K.useMemo((()=>({[`__scope${t.scopeName}`]:r})),[r])}};return n.scopeName=t.scopeName,n}function z$(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function H$(...e){return t=>{let n=!1;const r=e.map((e=>{const r=z$(e,t);return n||"function"!=typeof r||(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():z$(e[t],null)}}}}function U$(...e){return K.useCallback(H$(...e),e)}function $$(e){const t=G$(e),n=K.forwardRef(((e,n)=>{const{children:r,...a}=e,o=K.Children.toArray(r),i=o.find(q$);if(i){const e=i.props.children,r=o.map((t=>t===i?K.Children.count(e)>1?K.Children.only(null):K.isValidElement(e)?e.props.children:null:t));return Wh.jsx(t,{...a,ref:n,children:K.isValidElement(e)?K.cloneElement(e,void 0,r):null})}return Wh.jsx(t,{...a,ref:n,children:r})}));return n.displayName=`${e}.Slot`,n}function G$(e){const t=K.forwardRef(((e,t)=>{const{children:n,...r}=e;if(K.isValidElement(n)){const e=function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;if(a)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a)return e.props.ref;return e.props.ref||e.ref}(n),a=function(e,t){const n={...t};for(const r in t){const a=e[r],o=t[r];/^on[A-Z]/.test(r)?a&&o?n[r]=(...e)=>{const t=o(...e);return a(...e),t}:a&&(n[r]=a):"style"===r?n[r]={...a,...o}:"className"===r&&(n[r]=[a,o].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props);return n.type!==K.Fragment&&(a.ref=t?H$(t,e):e),K.cloneElement(n,a)}return K.Children.count(n)>1?K.Children.only(null):null}));return t.displayName=`${e}.SlotClone`,t}var V$=Symbol("radix.slottable");function q$(e){return K.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===V$}var W$=K.createContext(void 0);function Y$(e){const t=K.useContext(W$);return e||t||"ltr"}function K$(e){const t=Q$(e),n=K.forwardRef(((e,n)=>{const{children:r,...a}=e,o=K.Children.toArray(r),i=o.find(J$);if(i){const e=i.props.children,r=o.map((t=>t===i?K.Children.count(e)>1?K.Children.only(null):K.isValidElement(e)?e.props.children:null:t));return Wh.jsx(t,{...a,ref:n,children:K.isValidElement(e)?K.cloneElement(e,void 0,r):null})}return Wh.jsx(t,{...a,ref:n,children:r})}));return n.displayName=`${e}.Slot`,n}var X$=K$("Slot");function Q$(e){const t=K.forwardRef(((e,t)=>{const{children:n,...r}=e;if(K.isValidElement(n)){const e=function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;if(a)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a)return e.props.ref;return e.props.ref||e.ref}(n),a=function(e,t){const n={...t};for(const r in t){const a=e[r],o=t[r];/^on[A-Z]/.test(r)?a&&o?n[r]=(...e)=>{o(...e),a(...e)}:a&&(n[r]=a):"style"===r?n[r]={...a,...o}:"className"===r&&(n[r]=[a,o].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props);return n.type!==K.Fragment&&(a.ref=t?H$(t,e):e),K.cloneElement(n,a)}return K.Children.count(n)>1?K.Children.only(null):null}));return t.displayName=`${e}.SlotClone`,t}var Z$=Symbol("radix.slottable");function J$(e){return K.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===Z$}var eG=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce(((e,t)=>{const n=K$(`Primitive.${t}`),r=K.forwardRef(((e,r)=>{const{asChild:a,...o}=e,i=a?n:t;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),Wh.jsx(i,{...o,ref:r})}));return r.displayName=`Primitive.${t}`,{...e,[t]:r}}),{});var tG,nG="dismissableLayer.update",rG="dismissableLayer.pointerDownOutside",aG="dismissableLayer.focusOutside",oG=K.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),iG=K.forwardRef(((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:a,onFocusOutside:o,onInteractOutside:i,onDismiss:s,...l}=e,c=K.useContext(oG),[u,d]=K.useState(null),p=(null==u?void 0:u.ownerDocument)??(null==globalThis?void 0:globalThis.document),[,h]=K.useState({}),f=U$(t,(e=>d(e))),m=Array.from(c.layers),[g]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),y=m.indexOf(g),b=u?m.indexOf(u):-1,v=c.layersWithOutsidePointerEventsDisabled.size>0,k=b>=y,w=function(e,t=(null==globalThis?void 0:globalThis.document)){const n=RB(e),r=K.useRef(!1),a=K.useRef((()=>{}));return K.useEffect((()=>{const e=e=>{if(e.target&&!r.current){let r=function(){cG(rG,n,o,{discrete:!0})};const o={originalEvent:e};"touch"===e.pointerType?(t.removeEventListener("click",a.current),a.current=r,t.addEventListener("click",a.current,{once:!0})):r()}else t.removeEventListener("click",a.current);r.current=!1},o=window.setTimeout((()=>{t.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(o),t.removeEventListener("pointerdown",e),t.removeEventListener("click",a.current)}}),[t,n]),{onPointerDownCapture:()=>r.current=!0}}((e=>{const t=e.target,n=[...c.branches].some((e=>e.contains(t)));k&&!n&&(null==a||a(e),null==i||i(e),e.defaultPrevented||null==s||s())}),p),x=function(e,t=(null==globalThis?void 0:globalThis.document)){const n=RB(e),r=K.useRef(!1);return K.useEffect((()=>{const e=e=>{if(e.target&&!r.current){cG(aG,n,{originalEvent:e},{discrete:!1})}};return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)}),[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}((e=>{const t=e.target;[...c.branches].some((e=>e.contains(t)))||(null==o||o(e),null==i||i(e),e.defaultPrevented||null==s||s())}),p);return function(e,t=(null==globalThis?void 0:globalThis.document)){const n=RB(e);K.useEffect((()=>{const e=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",e,{capture:!0}),()=>t.removeEventListener("keydown",e,{capture:!0})}),[n,t])}((e=>{b===c.layers.size-1&&(null==r||r(e),!e.defaultPrevented&&s&&(e.preventDefault(),s()))}),p),K.useEffect((()=>{if(u)return n&&(0===c.layersWithOutsidePointerEventsDisabled.size&&(tG=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(u)),c.layers.add(u),lG(),()=>{n&&1===c.layersWithOutsidePointerEventsDisabled.size&&(p.body.style.pointerEvents=tG)}}),[u,p,n,c]),K.useEffect((()=>()=>{u&&(c.layers.delete(u),c.layersWithOutsidePointerEventsDisabled.delete(u),lG())}),[u,c]),K.useEffect((()=>{const e=()=>h({});return document.addEventListener(nG,e),()=>document.removeEventListener(nG,e)}),[]),Wh.jsx(eG.div,{...l,ref:f,style:{pointerEvents:v?k?"auto":"none":void 0,...e.style},onFocusCapture:F$(e.onFocusCapture,x.onFocusCapture),onBlurCapture:F$(e.onBlurCapture,x.onBlurCapture),onPointerDownCapture:F$(e.onPointerDownCapture,w.onPointerDownCapture)})}));iG.displayName="DismissableLayer";var sG=K.forwardRef(((e,t)=>{const n=K.useContext(oG),r=K.useRef(null),a=U$(t,r);return K.useEffect((()=>{const e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}}),[n.branches]),Wh.jsx(eG.div,{...e,ref:a})}));function lG(){const e=new CustomEvent(nG);document.dispatchEvent(e)}function cG(e,t,n,{discrete:r}){const a=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&a.addEventListener(e,t,{once:!0}),r?function(e,t){e&&se.flushSync((()=>e.dispatchEvent(t)))}(a,o):a.dispatchEvent(o)}sG.displayName="DismissableLayerBranch";var uG=0;function dG(){K.useEffect((()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??pG()),document.body.insertAdjacentElement("beforeend",e[1]??pG()),uG++,()=>{1===uG&&document.querySelectorAll("[data-radix-focus-guard]").forEach((e=>e.remove())),uG--}}),[])}function pG(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var hG="focusScope.autoFocusOnMount",fG="focusScope.autoFocusOnUnmount",mG={bubbles:!1,cancelable:!0},gG=K.forwardRef(((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:a,onUnmountAutoFocus:o,...i}=e,[s,l]=K.useState(null),c=RB(a),u=RB(o),d=K.useRef(null),p=U$(t,(e=>l(e))),h=K.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;K.useEffect((()=>{if(r){let e=function(e){if(h.paused||!s)return;const t=e.target;s.contains(t)?d.current=t:kG(d.current,{select:!0})},t=function(e){if(h.paused||!s)return;const t=e.relatedTarget;null!==t&&(s.contains(t)||kG(d.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(const t of e)t.removedNodes.length>0&&kG(s)};document.addEventListener("focusin",e),document.addEventListener("focusout",t);const r=new MutationObserver(n);return s&&r.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),r.disconnect()}}}),[r,s,h.paused]),K.useEffect((()=>{if(s){wG.add(h);const t=document.activeElement;if(!s.contains(t)){const n=new CustomEvent(hG,mG);s.addEventListener(hG,c),s.dispatchEvent(n),n.defaultPrevented||(!function(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(kG(r,{select:t}),document.activeElement!==n)return}((e=yG(s),e.filter((e=>"A"!==e.tagName))),{select:!0}),document.activeElement===t&&kG(s))}return()=>{s.removeEventListener(hG,c),setTimeout((()=>{const e=new CustomEvent(fG,mG);s.addEventListener(fG,u),s.dispatchEvent(e),e.defaultPrevented||kG(t??document.body,{select:!0}),s.removeEventListener(fG,u),wG.remove(h)}),0)}}var e}),[s,c,u,h]);const f=K.useCallback((e=>{if(!n&&!r)return;if(h.paused)return;const t="Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey,a=document.activeElement;if(t&&a){const t=e.currentTarget,[r,o]=function(e){const t=yG(e),n=bG(t,e),r=bG(t.reverse(),e);return[n,r]}(t);r&&o?e.shiftKey||a!==o?e.shiftKey&&a===r&&(e.preventDefault(),n&&kG(o,{select:!0})):(e.preventDefault(),n&&kG(r,{select:!0})):a===t&&e.preventDefault()}}),[n,r,h.paused]);return Wh.jsx(eG.div,{tabIndex:-1,...i,ref:p,onKeyDown:f})}));function yG(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{const t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function bG(e,t){for(const n of e)if(!vG(n,{upTo:t}))return n}function vG(e,{upTo:t}){if("hidden"===getComputedStyle(e).visibility)return!0;for(;e;){if(void 0!==t&&e===t)return!1;if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}function kG(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&function(e){return e instanceof HTMLInputElement&&"select"in e}(e)&&t&&e.select()}}gG.displayName="FocusScope";var wG=function(){let e=[];return{add(t){const n=e[0];t!==n&&(null==n||n.pause()),e=xG(e,t),e.unshift(t)},remove(t){var n;e=xG(e,t),null==(n=e[0])||n.resume()}}}();function xG(e,t){const n=[...e],r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}var EG=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce(((e,t)=>{const n=$$(`Primitive.${t}`),r=K.forwardRef(((e,r)=>{const{asChild:a,...o}=e,i=a?n:t;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),Wh.jsx(i,{...o,ref:r})}));return r.displayName=`Primitive.${t}`,{...e,[t]:r}}),{}),_G=K.forwardRef(((e,t)=>{const{children:n,width:r=10,height:a=5,...o}=e;return Wh.jsx(EG.svg,{...o,ref:t,width:r,height:a,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:Wh.jsx("polygon",{points:"0,0 30,0 15,10"})})}));_G.displayName="Arrow";var SG=_G;var TG="Popper",[CG,AG]=j$(TG),[NG,IG]=CG(TG),RG=e=>{const{__scopePopper:t,children:n}=e,[r,a]=K.useState(null);return Wh.jsx(NG,{scope:t,anchor:r,onAnchorChange:a,children:n})};RG.displayName=TG;var OG="PopperAnchor",PG=K.forwardRef(((e,t)=>{const{__scopePopper:n,virtualRef:r,...a}=e,o=IG(OG,n),i=K.useRef(null),s=U$(t,i);return K.useEffect((()=>{o.onAnchorChange((null==r?void 0:r.current)||i.current)})),r?null:Wh.jsx(EG.div,{...a,ref:s})}));PG.displayName=OG;var DG="PopperContent",[LG,MG]=CG(DG),FG=K.forwardRef(((e,t)=>{var n,r,a,o,i,s;const{__scopePopper:l,side:c="bottom",sideOffset:u=0,align:d="center",alignOffset:p=0,arrowPadding:h=0,avoidCollisions:f=!0,collisionBoundary:m=[],collisionPadding:g=0,sticky:y="partial",hideWhenDetached:b=!1,updatePositionStrategy:v="optimized",onPlaced:k,...w}=e,x=IG(DG,l),[E,_]=K.useState(null),S=U$(t,(e=>_(e))),[T,C]=K.useState(null),A=function(e){const[t,n]=K.useState(void 0);return FO((()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const t=new ResizeObserver((t=>{if(!Array.isArray(t))return;if(!t.length)return;const r=t[0];let a,o;if("borderBoxSize"in r){const e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;a=t.inlineSize,o=t.blockSize}else a=e.offsetWidth,o=e.offsetHeight;n({width:a,height:o})}));return t.observe(e,{box:"border-box"}),()=>t.unobserve(e)}n(void 0)}),[e]),t}(T),N=(null==A?void 0:A.width)??0,I=(null==A?void 0:A.height)??0,R=c+("center"!==d?"-"+d:""),O="number"==typeof g?g:{top:0,right:0,bottom:0,left:0,...g},P=Array.isArray(m)?m:[m],D=P.length>0,L={padding:O,boundary:P.filter(HG),altBoundary:D},{refs:M,floatingStyles:F,placement:j,isPositioned:B,middlewareData:z}=CF({strategy:"fixed",placement:R,whileElementsMounted:(...e)=>hF(...e,{animationFrame:"always"===v}),elements:{reference:x.anchor},middleware:[NF({mainAxis:u+I,alignmentAxis:p}),f&&IF({mainAxis:!0,crossAxis:!1,limiter:"partial"===y?RF():void 0,...L}),f&&OF({...L}),PF({...L,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{const{width:a,height:o}=t.reference,i=e.floating.style;i.setProperty("--radix-popper-available-width",`${n}px`),i.setProperty("--radix-popper-available-height",`${r}px`),i.setProperty("--radix-popper-anchor-width",`${a}px`),i.setProperty("--radix-popper-anchor-height",`${o}px`)}}),T&&LF({element:T,padding:h}),UG({arrowWidth:N,arrowHeight:I}),b&&DF({strategy:"referenceHidden",...L})]}),[H,U]=$G(j),$=RB(k);FO((()=>{B&&(null==$||$())}),[B,$]);const G=null==(n=z.arrow)?void 0:n.x,V=null==(r=z.arrow)?void 0:r.y,q=0!==(null==(a=z.arrow)?void 0:a.centerOffset),[W,Y]=K.useState();return FO((()=>{E&&Y(window.getComputedStyle(E).zIndex)}),[E]),Wh.jsx("div",{ref:M.setFloating,"data-radix-popper-content-wrapper":"",style:{...F,transform:B?F.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:W,"--radix-popper-transform-origin":[null==(o=z.transformOrigin)?void 0:o.x,null==(i=z.transformOrigin)?void 0:i.y].join(" "),...(null==(s=z.hide)?void 0:s.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:Wh.jsx(LG,{scope:l,placedSide:H,onArrowChange:C,arrowX:G,arrowY:V,shouldHideArrow:q,children:Wh.jsx(EG.div,{"data-side":H,"data-align":U,...w,ref:S,style:{...w.style,animation:B?void 0:"none"}})})})}));FG.displayName=DG;var jG="PopperArrow",BG={top:"bottom",right:"left",bottom:"top",left:"right"},zG=K.forwardRef((function(e,t){const{__scopePopper:n,...r}=e,a=MG(jG,n),o=BG[a.placedSide];return Wh.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:Wh.jsx(SG,{...r,ref:t,style:{...r.style,display:"block"}})})}));function HG(e){return null!==e}zG.displayName=jG;var UG=e=>({name:"transformOrigin",options:e,fn(t){var n,r,a;const{placement:o,rects:i,middlewareData:s}=t,l=0!==(null==(n=s.arrow)?void 0:n.centerOffset),c=l?0:e.arrowWidth,u=l?0:e.arrowHeight,[d,p]=$G(o),h={start:"0%",center:"50%",end:"100%"}[p],f=((null==(r=s.arrow)?void 0:r.x)??0)+c/2,m=((null==(a=s.arrow)?void 0:a.y)??0)+u/2;let g="",y="";return"bottom"===d?(g=l?h:`${f}px`,y=-u+"px"):"top"===d?(g=l?h:`${f}px`,y=`${i.floating.height+u}px`):"right"===d?(g=-u+"px",y=l?h:`${m}px`):"left"===d&&(g=`${i.floating.width+u}px`,y=l?h:`${m}px`),{data:{x:g,y:y}}}});function $G(e){const[t,n="center"]=e.split("-");return[t,n]}var GG=RG,VG=PG,qG=FG,WG=zG,YG=K.forwardRef(((e,t)=>{var n;const{container:r,...a}=e,[o,i]=K.useState(!1);FO((()=>i(!0)),[]);const s=r||o&&(null==(n=null==globalThis?void 0:globalThis.document)?void 0:n.body);return s?le.createPortal(Wh.jsx(eG.div,{...a,ref:t}),s):null}));YG.displayName="Portal";const KG=[" ","Enter","ArrowUp","ArrowDown"],XG=[" ","Enter"],QG="Select",[ZG,JG,eV]=function(e){const t=e+"CollectionProvider",[n,r]=j$(t),[a,o]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=e=>{const{scope:t,children:n}=e,r=X.useRef(null),o=X.useRef(new Map).current;return Wh.jsx(a,{scope:t,itemMap:o,collectionRef:r,children:n})};i.displayName=t;const s=e+"CollectionSlot",l=$$(s),c=X.forwardRef(((e,t)=>{const{scope:n,children:r}=e,a=U$(t,o(s,n).collectionRef);return Wh.jsx(l,{ref:a,children:r})}));c.displayName=s;const u=e+"CollectionItemSlot",d="data-radix-collection-item",p=$$(u),h=X.forwardRef(((e,t)=>{const{scope:n,children:r,...a}=e,i=X.useRef(null),s=U$(t,i),l=o(u,n);return X.useEffect((()=>(l.itemMap.set(i,{ref:i,...a}),()=>{l.itemMap.delete(i)}))),Wh.jsx(p,{[d]:"",ref:s,children:r})}));return h.displayName=u,[{Provider:i,Slot:c,ItemSlot:h},function(t){const n=o(e+"CollectionConsumer",t);return X.useCallback((()=>{const e=n.collectionRef.current;if(!e)return[];const t=Array.from(e.querySelectorAll(`[${d}]`));return Array.from(n.itemMap.values()).sort(((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current)))}),[n.collectionRef,n.itemMap])},r]}(QG),[tV,nV]=j$(QG,[eV,AG]),rV=AG(),[aV,oV]=tV(QG),[iV,sV]=tV(QG),lV=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:a,onOpenChange:o,value:i,defaultValue:s,onValueChange:l,dir:c,disabled:u,required:d}=e,p=rV(t),[h,f]=K.useState(null),[m,g]=K.useState(null),[y,b]=K.useState(!1),v=Y$(c),[k,w]=OB({prop:r,defaultProp:a??!1,onChange:o}),[x,E]=OB({prop:i,defaultProp:s,onChange:l}),_=K.useRef(null),[S,T]=K.useState(new Set);return Wh.jsx(GG,{...p,children:Wh.jsx(aV,{required:d,scope:t,trigger:h,onTriggerChange:f,valueNode:m,onValueNodeChange:g,valueNodeHasChildren:y,onValueNodeHasChildrenChange:b,contentId:zO(),value:x,onValueChange:E,open:!!k,onOpenChange:w,dir:v,triggerPointerDownPosRef:_,disabled:u,children:Wh.jsx(ZG.Provider,{scope:t,children:Wh.jsx(iV,{scope:e.__scopeSelect,onNativeOptionAdd:K.useCallback((e=>{T((t=>new Set(t).add(e)))}),[]),onNativeOptionRemove:K.useCallback((e=>{T((t=>{const n=new Set(t);return n.delete(e),n}))}),[]),children:n})})})})};lV.displayName=QG;const cV="SelectTrigger",uV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...a}=e,o=rV(n),i=oV(cV,n),s=i.disabled||r,l=U$(t,i.onTriggerChange),c=JG(n),u=K.useRef("touch"),[d,p,h]=XV((e=>{const t=c().filter((e=>!e.disabled)),n=t.find((e=>e.value===i.value)),r=QV(t,e,n);void 0!==r&&i.onValueChange(r.value)})),f=e=>{s||(i.onOpenChange(!0),h()),e&&(i.triggerPointerDownPosRef.current={x:Math.round(e.pageX),y:Math.round(e.pageY)})};return Wh.jsx(VG,{asChild:!0,...o,children:Wh.jsx(eG.button,{type:"button",role:"combobox","aria-controls":i.contentId,"aria-expanded":i.open,"aria-required":i.required,"aria-autocomplete":"none",dir:i.dir,"data-state":i.open?"open":"closed",disabled:s,"data-disabled":s?"":void 0,"data-placeholder":KV(i.value)?"":void 0,...a,ref:l,onClick:F$(a.onClick,(e=>{e.currentTarget.focus(),"mouse"!==u.current&&f(e)})),onPointerDown:F$(a.onPointerDown,(e=>{u.current=e.pointerType;const t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),0===e.button&&!1===e.ctrlKey&&"mouse"===e.pointerType&&(f(e),e.preventDefault())})),onKeyDown:F$(a.onKeyDown,(e=>{const t=""!==d.current;e.ctrlKey||e.altKey||e.metaKey||1!==e.key.length||p(e.key),t&&" "===e.key||KG.includes(e.key)&&(f(),e.preventDefault())}))})})}));uV.displayName=cV;const dV="SelectValue",pV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,className:r,style:a,children:o,placeholder:i="",...s}=e,l=oV(dV,n),{onValueNodeHasChildrenChange:c}=l,u=void 0!==o,d=U$(t,l.onValueNodeChange);return FO((()=>{c(u)}),[c,u]),Wh.jsx(eG.span,{...s,ref:d,style:{pointerEvents:"none"},children:KV(l.value)?Wh.jsx(Wh.Fragment,{children:i}):o})}));pV.displayName=dV;const hV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,children:r,...a}=e;return Wh.jsx(eG.span,{"aria-hidden":!0,...a,ref:t,children:r||"▼"})}));hV.displayName="SelectIcon";const fV="SelectContent",mV=K.forwardRef(((e,t)=>{const n=oV(fV,e.__scopeSelect),[r,a]=K.useState();if(FO((()=>{a(new DocumentFragment)}),[]),!n.open){const t=r;return t?se.createPortal(Wh.jsx(yV,{scope:e.__scopeSelect,children:Wh.jsx(ZG.Slot,{scope:e.__scopeSelect,children:Wh.jsx("div",{children:e.children})})}),t):null}return Wh.jsx(kV,{...e,ref:t})}));mV.displayName=fV;const gV=10,[yV,bV]=tV(fV),vV=K$("SelectContent.RemoveScroll"),kV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:a,onEscapeKeyDown:o,onPointerDownOutside:i,side:s,sideOffset:l,align:c,alignOffset:u,arrowPadding:d,collisionBoundary:p,collisionPadding:h,sticky:f,hideWhenDetached:m,avoidCollisions:g,...y}=e,b=oV(fV,n),[v,k]=K.useState(null),[w,x]=K.useState(null),E=U$(t,(e=>k(e))),[_,S]=K.useState(null),[T,C]=K.useState(null),A=JG(n),[N,I]=K.useState(!1),R=K.useRef(!1);K.useEffect((()=>{if(v)return FH(v)}),[v]),dG();const O=K.useCallback((e=>{const[t,...n]=A().map((e=>e.ref.current)),[r]=n.slice(-1),a=document.activeElement;for(const o of e){if(o===a)return;if(null==o||o.scrollIntoView({block:"nearest"}),o===t&&w&&(w.scrollTop=0),o===r&&w&&(w.scrollTop=w.scrollHeight),null==o||o.focus(),document.activeElement!==a)return}}),[A,w]),P=K.useCallback((()=>O([_,v])),[O,_,v]);K.useEffect((()=>{N&&P()}),[N,P]);const{onOpenChange:D,triggerPointerDownPosRef:L}=b;K.useEffect((()=>{if(v){let e={x:0,y:0};const t=t=>{var n,r;e={x:Math.abs(Math.round(t.pageX)-((null==(n=L.current)?void 0:n.x)??0)),y:Math.abs(Math.round(t.pageY)-((null==(r=L.current)?void 0:r.y)??0))}},n=n=>{e.x<=10&&e.y<=10?n.preventDefault():v.contains(n.target)||D(!1),document.removeEventListener("pointermove",t),L.current=null};return null!==L.current&&(document.addEventListener("pointermove",t),document.addEventListener("pointerup",n,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",t),document.removeEventListener("pointerup",n,{capture:!0})}}}),[v,D,L]),K.useEffect((()=>{const e=()=>D(!1);return window.addEventListener("blur",e),window.addEventListener("resize",e),()=>{window.removeEventListener("blur",e),window.removeEventListener("resize",e)}}),[D]);const[M,F]=XV((e=>{const t=A().filter((e=>!e.disabled)),n=t.find((e=>e.ref.current===document.activeElement)),r=QV(t,e,n);r&&setTimeout((()=>r.ref.current.focus()))})),j=K.useCallback(((e,t,n)=>{const r=!R.current&&!n;(void 0!==b.value&&b.value===t||r)&&(S(e),r&&(R.current=!0))}),[b.value]),B=K.useCallback((()=>null==v?void 0:v.focus()),[v]),z=K.useCallback(((e,t,n)=>{const r=!R.current&&!n;(void 0!==b.value&&b.value===t||r)&&C(e)}),[b.value]),H="popper"===r?xV:wV,U=H===xV?{side:s,sideOffset:l,align:c,alignOffset:u,arrowPadding:d,collisionBoundary:p,collisionPadding:h,sticky:f,hideWhenDetached:m,avoidCollisions:g}:{};return Wh.jsx(yV,{scope:n,content:v,viewport:w,onViewportChange:x,itemRefCallback:j,selectedItem:_,onItemLeave:B,itemTextRefCallback:z,focusSelectedItem:P,selectedItemText:T,position:r,isPositioned:N,searchRef:M,children:Wh.jsx(SU,{as:vV,allowPinchZoom:!0,removeScrollBar:!1,children:Wh.jsx(gG,{asChild:!0,trapped:b.open,onMountAutoFocus:e=>{e.preventDefault()},onUnmountAutoFocus:F$(a,(e=>{var t;null==(t=b.trigger)||t.focus({preventScroll:!0}),e.preventDefault()})),children:Wh.jsx(iG,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:o,onPointerDownOutside:i,onFocusOutside:e=>e.preventDefault(),onDismiss:()=>b.onOpenChange(!1),children:Wh.jsx(H,{role:"listbox",id:b.contentId,"data-state":b.open?"open":"closed",dir:b.dir,onContextMenu:e=>e.preventDefault(),...y,...U,onPlaced:()=>I(!0),ref:E,style:{display:"flex",flexDirection:"column",outline:"none",...y.style},onKeyDown:F$(y.onKeyDown,(e=>{const t=e.ctrlKey||e.altKey||e.metaKey;if("Tab"===e.key&&e.preventDefault(),t||1!==e.key.length||F(e.key),["ArrowUp","ArrowDown","Home","End"].includes(e.key)){let t=A().filter((e=>!e.disabled)).map((e=>e.ref.current));if(["ArrowUp","End"].includes(e.key)&&(t=t.slice().reverse()),["ArrowUp","ArrowDown"].includes(e.key)){const n=e.target,r=t.indexOf(n);t=t.slice(r+1)}setTimeout((()=>O(t))),e.preventDefault()}}))})})})})})}));kV.displayName="SelectContentImpl";const wV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,onPlaced:r,...a}=e,o=oV(fV,n),i=bV(fV,n),[s,l]=K.useState(null),[c,u]=K.useState(null),d=U$(t,(e=>u(e))),p=JG(n),h=K.useRef(!1),f=K.useRef(!0),{viewport:m,selectedItem:g,selectedItemText:y,focusSelectedItem:b}=i,v=K.useCallback((()=>{if(o.trigger&&o.valueNode&&s&&c&&m&&g&&y){const e=o.trigger.getBoundingClientRect(),t=c.getBoundingClientRect(),n=o.valueNode.getBoundingClientRect(),a=y.getBoundingClientRect();if("rtl"!==o.dir){const r=a.left-t.left,o=n.left-r,i=e.left-o,l=e.width+i,c=Math.max(l,t.width),u=window.innerWidth-gV,d=M$(o,[gV,Math.max(gV,u-c)]);s.style.minWidth=l+"px",s.style.left=d+"px"}else{const r=t.right-a.right,o=window.innerWidth-n.right-r,i=window.innerWidth-e.right-o,l=e.width+i,c=Math.max(l,t.width),u=window.innerWidth-gV,d=M$(o,[gV,Math.max(gV,u-c)]);s.style.minWidth=l+"px",s.style.right=d+"px"}const i=p(),l=window.innerHeight-2*gV,u=m.scrollHeight,d=window.getComputedStyle(c),f=Number.parseInt(d.borderTopWidth,10),b=Number.parseInt(d.paddingTop,10),v=Number.parseInt(d.borderBottomWidth,10),k=f+b+u+Number.parseInt(d.paddingBottom,10)+v,w=Math.min(5*g.offsetHeight,k),x=window.getComputedStyle(m),E=Number.parseInt(x.paddingTop,10),_=Number.parseInt(x.paddingBottom,10),S=e.top+e.height/2-gV,T=l-S,C=g.offsetHeight/2,A=f+b+(g.offsetTop+C),N=k-A;if(A<=S){const e=i.length>0&&g===i[i.length-1].ref.current;s.style.bottom="0px";const t=c.clientHeight-m.offsetTop-m.offsetHeight,n=A+Math.max(T,C+(e?_:0)+t+v);s.style.height=n+"px"}else{const e=i.length>0&&g===i[0].ref.current;s.style.top="0px";const t=Math.max(S,f+m.offsetTop+(e?E:0)+C)+N;s.style.height=t+"px",m.scrollTop=A-S+m.offsetTop}s.style.margin=`${gV}px 0`,s.style.minHeight=w+"px",s.style.maxHeight=l+"px",null==r||r(),requestAnimationFrame((()=>h.current=!0))}}),[p,o.trigger,o.valueNode,s,c,m,g,y,o.dir,r]);FO((()=>v()),[v]);const[k,w]=K.useState();FO((()=>{c&&w(window.getComputedStyle(c).zIndex)}),[c]);const x=K.useCallback((e=>{e&&!0===f.current&&(v(),null==b||b(),f.current=!1)}),[v,b]);return Wh.jsx(EV,{scope:n,contentWrapper:s,shouldExpandOnScrollRef:h,onScrollButtonChange:x,children:Wh.jsx("div",{ref:l,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:k},children:Wh.jsx(eG.div,{...a,ref:d,style:{boxSizing:"border-box",maxHeight:"100%",...a.style}})})})}));wV.displayName="SelectItemAlignedPosition";const xV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:a=gV,...o}=e,i=rV(n);return Wh.jsx(qG,{...i,...o,ref:t,align:r,collisionPadding:a,style:{boxSizing:"border-box",...o.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})}));xV.displayName="SelectPopperPosition";const[EV,_V]=tV(fV,{}),SV="SelectViewport",TV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,nonce:r,...a}=e,o=bV(SV,n),i=_V(SV,n),s=U$(t,o.onViewportChange),l=K.useRef(0);return Wh.jsxs(Wh.Fragment,{children:[Wh.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:r}),Wh.jsx(ZG.Slot,{scope:n,children:Wh.jsx(eG.div,{"data-radix-select-viewport":"",role:"presentation",...a,ref:s,style:{position:"relative",flex:1,overflow:"hidden auto",...a.style},onScroll:F$(a.onScroll,(e=>{const t=e.currentTarget,{contentWrapper:n,shouldExpandOnScrollRef:r}=i;if((null==r?void 0:r.current)&&n){const e=Math.abs(l.current-t.scrollTop);if(e>0){const r=window.innerHeight-2*gV,a=Number.parseFloat(n.style.minHeight),o=Number.parseFloat(n.style.height),i=Math.max(a,o);if(i<r){const a=i+e,o=Math.min(r,a),s=a-o;n.style.height=o+"px","0px"===n.style.bottom&&(t.scrollTop=s>0?s:0,n.style.justifyContent="flex-end")}}}l.current=t.scrollTop}))})})]})}));TV.displayName=SV;const CV="SelectGroup",[AV,NV]=tV(CV),IV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e,a=zO();return Wh.jsx(AV,{scope:n,id:a,children:Wh.jsx(eG.div,{role:"group","aria-labelledby":a,...r,ref:t})})}));IV.displayName=CV;const RV="SelectLabel",OV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e,a=NV(RV,n);return Wh.jsx(eG.div,{id:a.id,...r,ref:t})}));OV.displayName=RV;const PV="SelectItem",[DV,LV]=tV(PV),MV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,value:r,disabled:a=!1,textValue:o,...i}=e,s=oV(PV,n),l=bV(PV,n),c=s.value===r,[u,d]=K.useState(o??""),[p,h]=K.useState(!1),f=U$(t,(e=>{var t;return null==(t=l.itemRefCallback)?void 0:t.call(l,e,r,a)})),m=zO(),g=K.useRef("touch"),y=()=>{a||(s.onValueChange(r),s.onOpenChange(!1))};if(""===r)throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return Wh.jsx(DV,{scope:n,value:r,disabled:a,textId:m,isSelected:c,onItemTextChange:K.useCallback((e=>{d((t=>t||((null==e?void 0:e.textContent)??"").trim()))}),[]),children:Wh.jsx(ZG.ItemSlot,{scope:n,value:r,disabled:a,textValue:u,children:Wh.jsx(eG.div,{role:"option","aria-labelledby":m,"data-highlighted":p?"":void 0,"aria-selected":c&&p,"data-state":c?"checked":"unchecked","aria-disabled":a||void 0,"data-disabled":a?"":void 0,tabIndex:a?void 0:-1,...i,ref:f,onFocus:F$(i.onFocus,(()=>h(!0))),onBlur:F$(i.onBlur,(()=>h(!1))),onClick:F$(i.onClick,(()=>{"mouse"!==g.current&&y()})),onPointerUp:F$(i.onPointerUp,(()=>{"mouse"===g.current&&y()})),onPointerDown:F$(i.onPointerDown,(e=>{g.current=e.pointerType})),onPointerMove:F$(i.onPointerMove,(e=>{var t;g.current=e.pointerType,a?null==(t=l.onItemLeave)||t.call(l):"mouse"===g.current&&e.currentTarget.focus({preventScroll:!0})})),onPointerLeave:F$(i.onPointerLeave,(e=>{var t;e.currentTarget===document.activeElement&&(null==(t=l.onItemLeave)||t.call(l))})),onKeyDown:F$(i.onKeyDown,(e=>{var t;""!==(null==(t=l.searchRef)?void 0:t.current)&&" "===e.key||(XG.includes(e.key)&&y()," "===e.key&&e.preventDefault())}))})})})}));MV.displayName=PV;const FV="SelectItemText",jV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,className:r,style:a,...o}=e,i=oV(FV,n),s=bV(FV,n),l=LV(FV,n),c=sV(FV,n),[u,d]=K.useState(null),p=U$(t,(e=>d(e)),l.onItemTextChange,(e=>{var t;return null==(t=s.itemTextRefCallback)?void 0:t.call(s,e,l.value,l.disabled)})),h=null==u?void 0:u.textContent,f=K.useMemo((()=>Wh.jsx("option",{value:l.value,disabled:l.disabled,children:h},l.value)),[l.disabled,l.value,h]),{onNativeOptionAdd:m,onNativeOptionRemove:g}=c;return FO((()=>(m(f),()=>g(f))),[m,g,f]),Wh.jsxs(Wh.Fragment,{children:[Wh.jsx(eG.span,{id:l.textId,...o,ref:p}),l.isSelected&&i.valueNode&&!i.valueNodeHasChildren?se.createPortal(o.children,i.valueNode):null]})}));jV.displayName=FV;const BV="SelectItemIndicator",zV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e;return LV(BV,n).isSelected?Wh.jsx(eG.span,{"aria-hidden":!0,...r,ref:t}):null}));zV.displayName=BV;const HV="SelectScrollUpButton",UV=K.forwardRef(((e,t)=>{const n=bV(HV,e.__scopeSelect),r=_V(HV,e.__scopeSelect),[a,o]=K.useState(!1),i=U$(t,r.onScrollButtonChange);return FO((()=>{if(n.viewport&&n.isPositioned){let e=function(){const e=t.scrollTop>0;o(e)};const t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[n.viewport,n.isPositioned]),a?Wh.jsx(VV,{...e,ref:i,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop-t.offsetHeight)}}):null}));UV.displayName=HV;const $V="SelectScrollDownButton",GV=K.forwardRef(((e,t)=>{const n=bV($V,e.__scopeSelect),r=_V($V,e.__scopeSelect),[a,o]=K.useState(!1),i=U$(t,r.onScrollButtonChange);return FO((()=>{if(n.viewport&&n.isPositioned){let e=function(){const e=t.scrollHeight-t.clientHeight,n=Math.ceil(t.scrollTop)<e;o(n)};const t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[n.viewport,n.isPositioned]),a?Wh.jsx(VV,{...e,ref:i,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop+t.offsetHeight)}}):null}));GV.displayName=$V;const VV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...a}=e,o=bV("SelectScrollButton",n),i=K.useRef(null),s=JG(n),l=K.useCallback((()=>{null!==i.current&&(window.clearInterval(i.current),i.current=null)}),[]);return K.useEffect((()=>()=>l()),[l]),FO((()=>{var e;const t=s().find((e=>e.ref.current===document.activeElement));null==(e=null==t?void 0:t.ref.current)||e.scrollIntoView({block:"nearest"})}),[s]),Wh.jsx(eG.div,{"aria-hidden":!0,...a,ref:t,style:{flexShrink:0,...a.style},onPointerDown:F$(a.onPointerDown,(()=>{null===i.current&&(i.current=window.setInterval(r,50))})),onPointerMove:F$(a.onPointerMove,(()=>{var e;null==(e=o.onItemLeave)||e.call(o),null===i.current&&(i.current=window.setInterval(r,50))})),onPointerLeave:F$(a.onPointerLeave,(()=>{l()}))})})),qV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e;return Wh.jsx(eG.div,{"aria-hidden":!0,...r,ref:t})}));qV.displayName="SelectSeparator";const WV="SelectArrow",YV=K.forwardRef(((e,t)=>{const{__scopeSelect:n,...r}=e,a=rV(n),o=oV(WV,n),i=bV(WV,n);return o.open&&"popper"===i.position?Wh.jsx(WG,{...a,...r,ref:t}):null}));function KV(e){return""===e||void 0===e}function XV(e){const t=RB(e),n=K.useRef(""),r=K.useRef(0),a=K.useCallback((e=>{const a=n.current+e;t(a),function e(t){n.current=t,window.clearTimeout(r.current),""!==t&&(r.current=window.setTimeout((()=>e("")),1e3))}(a)}),[t]),o=K.useCallback((()=>{n.current="",window.clearTimeout(r.current)}),[]);return K.useEffect((()=>()=>window.clearTimeout(r.current)),[]),[n,a,o]}function QV(e,t,n){const r=t.length>1&&Array.from(t).every((e=>e===t[0]))?t[0]:t,a=n?e.indexOf(n):-1;let o=(i=e,s=Math.max(a,0),i.map(((e,t)=>i[(s+t)%i.length])));var i,s;1===r.length&&(o=o.filter((e=>e!==n)));const l=o.find((e=>e.textValue.toLowerCase().startsWith(r.toLowerCase())));return l!==n?l:void 0}YV.displayName=WV;const ZV=lV,JV=uV,eq=pV,tq=hV,nq=mV,rq=TV,aq=MV,oq=jV,iq=zV;var sq=e=>"object"==typeof e&&null!==e,lq=e=>sq(e)&&1===e.nodeType&&"string"==typeof e.nodeName,cq=e=>sq(e)&&9===e.nodeType,uq=/(textarea|select)/;function dq(e){if(null==e||!lq(e))return!1;try{return(e=>lq(e)&&"input"===e.localName)(e)&&null!=e.selectionStart||uq.test(e.localName)||e.isContentEditable||"true"===e.getAttribute("contenteditable")||""===e.getAttribute("contenteditable")}catch{return!1}}function pq(e){return cq(e)?e:(e=>sq(e)&&e===e.window)(e)?e.document:(null==e?void 0:e.ownerDocument)??document}function hq(e){const t=function(e){var t,n,r;return(null==(t=e.composedPath)?void 0:t.call(e))??(null==(r=null==(n=e.nativeEvent)?void 0:n.composedPath)?void 0:r.call(n))}(e);return(null==t?void 0:t[0])??e.target}var fq=(e,t,n,r)=>{const a="function"==typeof e?e():e;return null==a||a.addEventListener(t,n,r),()=>{null==a||a.removeEventListener(t,n,r)}},mq=e=>lq(e)&&"IFRAME"===e.tagName,gq="input:not([type='hidden']):not([disabled]), select:not([disabled]), textarea:not([disabled]), a[href], button:not([disabled]), [tabindex], iframe, object, embed, area[href], audio[controls], video[controls], [contenteditable]:not([contenteditable='false']), details > summary:first-of-type",yq=(e,t=!1)=>{if(!e)return[];const n=Array.from(e.querySelectorAll(gq));(1==t||"if-empty"==t&&0===n.length)&&lq(e)&&bq(e)&&n.unshift(e);const r=n.filter(bq);return r.forEach(((e,t)=>{if(mq(e)&&e.contentDocument){const n=e.contentDocument.body;r.splice(t,1,...yq(n))}})),r};function bq(e){return!(!e||e.closest("[inert]"))&&(e.matches(gq)&&(!!lq(t=e)&&(t.offsetWidth>0||t.offsetHeight>0||t.getClientRects().length>0)));var t}function vq(e,t){if(!e)return[];const n=Array.from(e.querySelectorAll(gq)).filter(kq);return n.forEach(((e,t)=>{if(mq(e)&&e.contentDocument){const r=vq(e.contentDocument.body);n.splice(t,1,...r)}})),n.length,n}function kq(e){return null!=e&&e.tabIndex>0||bq(e)&&!(e=>parseInt(e.getAttribute("tabindex")||"0",10)<0)(e)}function wq(e){return e.tabIndex<0&&(/^(audio|video|details)$/.test(e.localName)||dq(e))&&(t=e,Number.isNaN(parseInt(t.getAttribute("tabindex")||"0",10)))?0:e.tabIndex;var t}var xq=Object.defineProperty,Eq=(e,t,n)=>((e,t,n)=>t in e?xq(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n)(e,"symbol"!=typeof t?t+"":t,n),_q={activateTrap(e,t){if(e.length>0){const n=e[e.length-1];n!==t&&n.pause()}const n=e.indexOf(t);-1===n||e.splice(n,1),e.push(t)},deactivateTrap(e,t){const n=e.indexOf(t);-1!==n&&e.splice(n,1),e.length>0&&e[e.length-1].unpause()}},Sq=[],Tq=class{constructor(e,t){Eq(this,"trapStack"),Eq(this,"config"),Eq(this,"doc"),Eq(this,"state",{containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,delayInitialFocusTimer:void 0,recentNavEvent:void 0}),Eq(this,"listenerCleanups",[]),Eq(this,"handleFocus",(e=>{const t=hq(e),n=this.findContainerIndex(t,e)>=0;if(n||cq(t))n&&(this.state.mostRecentlyFocusedNode=t);else{let t;e.stopImmediatePropagation();let n=!0;if(this.state.mostRecentlyFocusedNode)if(wq(this.state.mostRecentlyFocusedNode)>0){const e=this.findContainerIndex(this.state.mostRecentlyFocusedNode),{tabbableNodes:r}=this.state.containerGroups[e];if(r.length>0){const e=r.findIndex((e=>e===this.state.mostRecentlyFocusedNode));e>=0&&(this.config.isKeyForward(this.state.recentNavEvent)?e+1<r.length&&(t=r[e+1],n=!1):e-1>=0&&(t=r[e-1],n=!1))}}else this.state.containerGroups.some((e=>e.tabbableNodes.some((e=>wq(e)>0))))||(n=!1);else n=!1;n&&(t=this.findNextNavNode({target:this.state.mostRecentlyFocusedNode,isBackward:this.config.isKeyBackward(this.state.recentNavEvent)})),t?this.tryFocus(t):this.tryFocus(this.state.mostRecentlyFocusedNode||this.getInitialFocusNode())}this.state.recentNavEvent=void 0})),Eq(this,"handlePointerDown",(e=>{const t=hq(e);this.findContainerIndex(t,e)>=0||(Aq(this.config.clickOutsideDeactivates,e)?this.deactivate({returnFocus:this.config.returnFocusOnDeactivate}):Aq(this.config.allowOutsideClick,e)||e.preventDefault())})),Eq(this,"handleClick",(e=>{const t=hq(e);this.findContainerIndex(t,e)>=0||Aq(this.config.clickOutsideDeactivates,e)||Aq(this.config.allowOutsideClick,e)||(e.preventDefault(),e.stopImmediatePropagation())})),Eq(this,"handleTabKey",(e=>{if(this.config.isKeyForward(e)||this.config.isKeyBackward(e)){this.state.recentNavEvent=e;const t=this.config.isKeyBackward(e),n=this.findNextNavNode({event:e,isBackward:t});if(!n)return;Cq(e)&&e.preventDefault(),this.tryFocus(n)}})),Eq(this,"handleEscapeKey",(e=>{Nq(e)&&!1!==Aq(this.config.escapeDeactivates,e)&&(e.preventDefault(),this.deactivate())})),Eq(this,"_mutationObserver"),Eq(this,"setupMutationObserver",(()=>{const e=this.doc.defaultView||window;this._mutationObserver=new e.MutationObserver((e=>{e.some((e=>Array.from(e.removedNodes).some((e=>e===this.state.mostRecentlyFocusedNode))))&&this.tryFocus(this.getInitialFocusNode())}))})),Eq(this,"updateObservedNodes",(()=>{var e;null==(e=this._mutationObserver)||e.disconnect(),this.state.active&&!this.state.paused&&this.state.containers.map((e=>{var t;null==(t=this._mutationObserver)||t.observe(e,{subtree:!0,childList:!0})}))})),Eq(this,"getInitialFocusNode",(()=>{let e=this.getNodeForOption("initialFocus",{hasFallback:!0});if(!1===e)return!1;if(void 0===e||e&&!bq(e))if(this.findContainerIndex(this.doc.activeElement)>=0)e=this.doc.activeElement;else{const t=this.state.tabbableGroups[0];e=t&&t.firstTabbableNode||this.getNodeForOption("fallbackFocus")}else null===e&&(e=this.getNodeForOption("fallbackFocus"));if(!e)throw new Error("Your focus-trap needs to have at least one focusable element");return e.isConnected||(e=this.getNodeForOption("fallbackFocus")),e})),Eq(this,"tryFocus",(e=>{!1!==e&&e!==function(e){let t=e.activeElement;for(;null==t?void 0:t.shadowRoot;){const e=t.shadowRoot.activeElement;if(e===t)break;t=e}return t}(this.doc)&&(e&&e.focus?(e.focus({preventScroll:!!this.config.preventScroll}),this.state.mostRecentlyFocusedNode=e,Rq(e)&&e.select()):this.tryFocus(this.getInitialFocusNode()))})),Eq(this,"deactivate",(e=>{if(!this.state.active)return this;const t={onDeactivate:this.config.onDeactivate,onPostDeactivate:this.config.onPostDeactivate,checkCanReturnFocus:this.config.checkCanReturnFocus,...e};clearTimeout(this.state.delayInitialFocusTimer),this.state.delayInitialFocusTimer=void 0,this.removeListeners(),this.state.active=!1,this.state.paused=!1,this.updateObservedNodes(),_q.deactivateTrap(this.trapStack,this);const n=this.getOption(t,"onDeactivate"),r=this.getOption(t,"onPostDeactivate"),a=this.getOption(t,"checkCanReturnFocus"),o=this.getOption(t,"returnFocus","returnFocusOnDeactivate");null==n||n();const i=()=>{Iq((()=>{if(o){const e=this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation);this.tryFocus(e)}null==r||r()}))};if(o&&a){return a(this.getReturnFocusNode(this.state.nodeFocusedBeforeActivation)).then(i,i),this}return i(),this})),Eq(this,"pause",(e=>{if(this.state.paused||!this.state.active)return this;const t=this.getOption(e,"onPause"),n=this.getOption(e,"onPostPause");return this.state.paused=!0,null==t||t(),this.removeListeners(),this.updateObservedNodes(),null==n||n(),this})),Eq(this,"unpause",(e=>{if(!this.state.paused||!this.state.active)return this;const t=this.getOption(e,"onUnpause"),n=this.getOption(e,"onPostUnpause");return this.state.paused=!1,null==t||t(),this.updateTabbableNodes(),this.addListeners(),this.updateObservedNodes(),null==n||n(),this})),Eq(this,"updateContainerElements",(e=>(this.state.containers=Array.isArray(e)?e.filter(Boolean):[e].filter(Boolean),this.state.active&&this.updateTabbableNodes(),this.updateObservedNodes(),this))),Eq(this,"getReturnFocusNode",(e=>{const t=this.getNodeForOption("setReturnFocus",{params:[e]});return t||!1!==t&&e})),Eq(this,"getOption",((e,t,n)=>e&&void 0!==e[t]?e[t]:this.config[n||t])),Eq(this,"getNodeForOption",((e,{hasFallback:t=!1,params:n=[]}={})=>{let r=this.config[e];if("function"==typeof r&&(r=r(...n)),!0===r&&(r=void 0),!r){if(void 0===r||!1===r)return r;throw new Error(`\`${e}\` was specified but was not a node, or did not return a node`)}let a=r;if("string"==typeof r){try{a=this.doc.querySelector(r)}catch(xbe){throw new Error(`\`${e}\` appears to be an invalid selector; error="${xbe.message}"`)}if(!a&&!t)throw new Error(`\`${e}\` as selector refers to no known node`)}return a})),Eq(this,"findNextNavNode",(e=>{const{event:t,isBackward:n=!1}=e,r=e.target||hq(t);this.updateTabbableNodes();let a=null;if(this.state.tabbableGroups.length>0){const e=this.findContainerIndex(r,t),o=e>=0?this.state.containerGroups[e]:void 0;if(e<0)a=n?this.state.tabbableGroups[this.state.tabbableGroups.length-1].lastTabbableNode:this.state.tabbableGroups[0].firstTabbableNode;else if(n){let n=this.state.tabbableGroups.findIndex((({firstTabbableNode:e})=>r===e));if(n<0&&((null==o?void 0:o.container)===r||bq(r)&&!kq(r)&&!(null==o?void 0:o.nextTabbableNode(r,!1)))&&(n=e),n>=0){const e=0===n?this.state.tabbableGroups.length-1:n-1,t=this.state.tabbableGroups[e];a=wq(r)>=0?t.lastTabbableNode:t.lastDomTabbableNode}else Cq(t)||(a=null==o?void 0:o.nextTabbableNode(r,!1))}else{let n=this.state.tabbableGroups.findIndex((({lastTabbableNode:e})=>r===e));if(n<0&&((null==o?void 0:o.container)===r||bq(r)&&!kq(r)&&!(null==o?void 0:o.nextTabbableNode(r)))&&(n=e),n>=0){const e=n===this.state.tabbableGroups.length-1?0:n+1,t=this.state.tabbableGroups[e];a=wq(r)>=0?t.firstTabbableNode:t.firstDomTabbableNode}else Cq(t)||(a=null==o?void 0:o.nextTabbableNode(r))}}else a=this.getNodeForOption("fallbackFocus");return a})),this.trapStack=t.trapStack||Sq;const n={returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,isKeyForward:e=>Cq(e)&&!e.shiftKey,isKeyBackward:e=>Cq(e)&&e.shiftKey,...t};this.doc=n.document||pq(Array.isArray(e)?e[0]:e),this.config=n,this.updateContainerElements(e),this.setupMutationObserver()}get active(){return this.state.active}get paused(){return this.state.paused}findContainerIndex(e,t){const n="function"==typeof(null==t?void 0:t.composedPath)?t.composedPath():void 0;return this.state.containerGroups.findIndex((({container:t,tabbableNodes:r})=>t.contains(e)||(null==n?void 0:n.includes(t))||r.find((t=>t===e))))}updateTabbableNodes(){if(this.state.containerGroups=this.state.containers.map((e=>{const t=vq(e),n=yq(e),r=t.length>0?t[0]:void 0,a=t.length>0?t[t.length-1]:void 0,o=n.find((e=>kq(e))),i=n.slice().reverse().find((e=>kq(e))),s=!!t.find((e=>wq(e)>0));return{container:e,tabbableNodes:t,focusableNodes:n,posTabIndexesFound:s,firstTabbableNode:r,lastTabbableNode:a,firstDomTabbableNode:o,lastDomTabbableNode:i,nextTabbableNode:function(e,r=!0){const a=t.indexOf(e);return a<0?r?n.slice(n.indexOf(e)+1).find((e=>kq(e))):n.slice(0,n.indexOf(e)).reverse().find((e=>kq(e))):t[a+(r?1:-1)]}}})),this.state.tabbableGroups=this.state.containerGroups.filter((e=>e.tabbableNodes.length>0)),this.state.tabbableGroups.length<=0&&!this.getNodeForOption("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times");if(this.state.containerGroups.find((e=>e.posTabIndexesFound))&&this.state.containerGroups.length>1)throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.")}addListeners(){if(this.state.active)return _q.activateTrap(this.trapStack,this),this.state.delayInitialFocusTimer=this.config.delayInitialFocus?Iq((()=>{this.tryFocus(this.getInitialFocusNode())})):this.tryFocus(this.getInitialFocusNode()),this.listenerCleanups.push(fq(this.doc,"focusin",this.handleFocus,!0),fq(this.doc,"mousedown",this.handlePointerDown,{capture:!0,passive:!1}),fq(this.doc,"touchstart",this.handlePointerDown,{capture:!0,passive:!1}),fq(this.doc,"click",this.handleClick,{capture:!0,passive:!1}),fq(this.doc,"keydown",this.handleTabKey,{capture:!0,passive:!1}),fq(this.doc,"keydown",this.handleEscapeKey)),this}removeListeners(){if(this.state.active)return this.listenerCleanups.forEach((e=>e())),this.listenerCleanups=[],this}activate(e){if(this.state.active)return this;const t=this.getOption(e,"onActivate"),n=this.getOption(e,"onPostActivate"),r=this.getOption(e,"checkCanFocusTrap");r||this.updateTabbableNodes(),this.state.active=!0,this.state.paused=!1,this.state.nodeFocusedBeforeActivation=this.doc.activeElement||null,null==t||t();const a=()=>{r&&this.updateTabbableNodes(),this.addListeners(),this.updateObservedNodes(),null==n||n()};return r?(r(this.state.containers.concat()).then(a,a),this):(a(),this)}},Cq=e=>"Tab"===e.key,Aq=(e,...t)=>"function"==typeof e?e(...t):e,Nq=e=>!e.isComposing&&"Escape"===e.key,Iq=e=>setTimeout(e,0),Rq=e=>"input"===e.localName&&"select"in e&&"function"==typeof e.select;function Oq(e,t={}){let n;const r=function(e){let t;const n=globalThis.requestAnimationFrame((()=>{t=e()}));return()=>{globalThis.cancelAnimationFrame(n),null==t||t()}}((()=>{const r="function"==typeof e?e():e;if(r){n=new Tq(r,{escapeDeactivates:!1,allowOutsideClick:!0,preventScroll:!0,returnFocusOnDeactivate:!0,delayInitialFocus:!1,fallbackFocus:r,...t,document:pq(r)});try{n.activate()}catch{}}}));return function(){null==n||n.deactivate(),r()}}var Pq=e=>{const{present:t,children:n}=e,r=function(e){const[t,n]=K.useState(),r=K.useRef({}),a=K.useRef(e),o=K.useRef("none"),i=e?"mounted":"unmounted",[s,l]=function(e,t){return K.useReducer(((e,n)=>t[e][n]??e),e)}(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return K.useEffect((()=>{const e=Dq(r.current);o.current="mounted"===s?e:"none"}),[s]),FO((()=>{const t=r.current,n=a.current;if(n!==e){const r=o.current,i=Dq(t);if(e)l("MOUNT");else if("none"===i||"none"===(null==t?void 0:t.display))l("UNMOUNT");else{l(n&&r!==i?"ANIMATION_OUT":"UNMOUNT")}a.current=e}}),[e,l]),FO((()=>{if(t){let e;const n=t.ownerDocument.defaultView??window,i=o=>{const i=Dq(r.current).includes(o.animationName);if(o.target===t&&i&&(l("ANIMATION_END"),!a.current)){const r=t.style.animationFillMode;t.style.animationFillMode="forwards",e=n.setTimeout((()=>{"forwards"===t.style.animationFillMode&&(t.style.animationFillMode=r)}))}},s=e=>{e.target===t&&(o.current=Dq(r.current))};return t.addEventListener("animationstart",s),t.addEventListener("animationcancel",i),t.addEventListener("animationend",i),()=>{n.clearTimeout(e),t.removeEventListener("animationstart",s),t.removeEventListener("animationcancel",i),t.removeEventListener("animationend",i)}}l("ANIMATION_END")}),[t,l]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:K.useCallback((e=>{e&&(r.current=getComputedStyle(e)),n(e)}),[])}}(t),a="function"==typeof n?n({present:r.isPresent}):K.Children.only(n),o=U$(r.ref,function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,a=r&&"isReactWarning"in r&&r.isReactWarning;if(a)return e.ref;if(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get,a=r&&"isReactWarning"in r&&r.isReactWarning,a)return e.props.ref;return e.props.ref||e.ref}(a));return"function"==typeof n||r.isPresent?K.cloneElement(a,{ref:o}):null};function Dq(e){return(null==e?void 0:e.animationName)||"none"}Pq.displayName="Presence";const Lq="Dialog",[Mq,Fq]=j$(Lq),[jq,Bq]=Mq(Lq),zq=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:a,onOpenChange:o,modal:i=!0}=e,s=K.useRef(null),l=K.useRef(null),[c=!1,u]=OB({prop:r,defaultProp:a,onChange:o});return Wh.jsx(jq,{scope:t,triggerRef:s,contentRef:l,contentId:zO(),titleId:zO(),descriptionId:zO(),open:c,onOpenChange:u,onOpenToggle:K.useCallback((()=>u((e=>!e))),[u]),modal:i,children:n})};zq.displayName=Lq;const Hq="DialogTrigger",Uq=K.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,a=Bq(Hq,n),o=U$(t,a.triggerRef);return Wh.jsx(eG.button,{type:"button","aria-haspopup":"dialog","aria-expanded":a.open,"aria-controls":a.contentId,"data-state":sW(a.open),...r,ref:o,onClick:F$(e.onClick,a.onOpenToggle)})}));Uq.displayName=Hq;const $q="DialogPortal",[Gq,Vq]=Mq($q,{forceMount:void 0}),qq=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:a}=e,o=Bq($q,t);return Wh.jsx(Gq,{scope:t,forceMount:n,children:K.Children.map(r,(e=>Wh.jsx(Pq,{present:n||o.open,children:Wh.jsx(YG,{asChild:!0,container:a,children:e})})))})};qq.displayName=$q;const Wq="DialogOverlay",Yq=K.forwardRef(((e,t)=>{const n=Vq(Wq,e.__scopeDialog),{forceMount:r=n.forceMount,...a}=e,o=Bq(Wq,e.__scopeDialog);return o.modal?Wh.jsx(Pq,{present:r||o.open,children:Wh.jsx(Kq,{...a,ref:t})}):null}));Yq.displayName=Wq;const Kq=K.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,a=Bq(Wq,n);return Wh.jsx(SU,{as:X$,allowPinchZoom:!0,shards:[a.contentRef],gapMode:"padding",removeScrollBar:!0,children:Wh.jsx(eG.div,{"data-state":sW(a.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})})),Xq="DialogContent",Qq=K.forwardRef(((e,t)=>{const n=Vq(Xq,e.__scopeDialog),{forceMount:r=n.forceMount,...a}=e,o=Bq(Xq,e.__scopeDialog);return Wh.jsx(Pq,{present:r||o.open,children:o.modal?Wh.jsx(Zq,{...a,ref:t}):Wh.jsx(Jq,{...a,ref:t})})}));Qq.displayName=Xq;const Zq=K.forwardRef(((e,t)=>{const n=Bq(Xq,e.__scopeDialog),r=K.useRef(null),a=U$(t,n.contentRef,r);return K.useEffect((()=>{const e=r.current;if(e)return FH(e)}),[]),Wh.jsx(eW,{...e,ref:a,trapFocus:n.open,disableOutsidePointerEvents:!0,onPointerDownOutside:F$(e.onPointerDownOutside,(e=>{const t=e.detail.originalEvent,n=0===t.button&&!0===t.ctrlKey;(2===t.button||n)&&e.preventDefault()})),onFocusOutside:F$(e.onFocusOutside,(e=>e.preventDefault()))})})),Jq=K.forwardRef(((e,t)=>{const n=Bq(Xq,e.__scopeDialog),r=K.useRef(!1),a=K.useRef(!1);return Wh.jsx(eW,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onInteractOutside:t=>{var o,i;null==(o=e.onInteractOutside)||o.call(e,t),t.defaultPrevented||(r.current=!0,"pointerdown"===t.detail.originalEvent.type&&(a.current=!0));const s=t.target;(null==(i=n.triggerRef.current)?void 0:i.contains(s))&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&a.current&&t.preventDefault()}})})),eW=K.forwardRef(((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:a,onCloseAutoFocus:o,...i}=e,s=Bq(Xq,n),l=K.useRef(null),c=U$(t,l);return dG(),K.useEffect((()=>{if(r)return Oq(l.current,{preventScroll:!0,onActivate:a,onDeactivate:o,initialFocus:!1})}),[]),Wh.jsx(iG,{role:"dialog",id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":sW(s.open),...i,ref:c,onDismiss:()=>s.onOpenChange(!1)})})),tW="DialogTitle",nW=K.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,a=Bq(tW,n);return Wh.jsx(eG.h2,{id:a.titleId,...r,ref:t})}));nW.displayName=tW;const rW="DialogDescription",aW=K.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,a=Bq(rW,n);return Wh.jsx(eG.p,{id:a.descriptionId,...r,ref:t})}));aW.displayName=rW;const oW="DialogClose",iW=K.forwardRef(((e,t)=>{const{__scopeDialog:n,...r}=e,a=Bq(oW,n);return Wh.jsx(eG.button,{type:"button",...r,ref:t,onClick:F$(e.onClick,(()=>a.onOpenChange(!1)))})}));function sW(e){return e?"open":"closed"}iW.displayName=oW;const lW=zq,cW=qq,uW=Yq,dW=Qq,pW=nW,hW=iW,fW=K.forwardRef(((e,t)=>{const n=K.useId();return Wh.jsxs("svg",{viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",height:"100%",width:"100%",ref:t,...e,children:[Wh.jsx("title",{children:"AI Avatar"}),Wh.jsx("path",{d:"M9.937 15.5002C9.84772 15.1542 9.66734 14.8384 9.41462 14.5856C9.1619 14.3329 8.84607 14.1525 8.5 14.0632L2.365 12.4812C2.26033 12.4515 2.16821 12.3885 2.10261 12.3017C2.03702 12.2149 2.00153 12.1091 2.00153 12.0002C2.00153 11.8914 2.03702 11.7856 2.10261 11.6988C2.16821 11.612 2.26033 11.549 2.365 11.5192L8.5 9.93625C8.84595 9.84706 9.16169 9.66682 9.4144 9.41429C9.66711 9.16175 9.84757 8.84614 9.937 8.50025L11.519 2.36525C11.5484 2.26017 11.6114 2.16759 11.6983 2.10164C11.7853 2.0357 11.8914 2 12.0005 2C12.1096 2 12.2157 2.0357 12.3027 2.10164C12.3896 2.16759 12.4526 2.26017 12.482 2.36525L14.063 8.50025C14.1523 8.84632 14.3327 9.16215 14.5854 9.41487C14.8381 9.66759 15.1539 9.84797 15.5 9.93725L21.635 11.5182C21.7405 11.5473 21.8335 11.6103 21.8998 11.6973C21.9661 11.7844 22.0021 11.8908 22.0021 12.0002C22.0021 12.1097 21.9661 12.2161 21.8998 12.3032C21.8335 12.3902 21.7405 12.4531 21.635 12.4822L15.5 14.0632C15.1539 14.1525 14.8381 14.3329 14.5854 14.5856C14.3327 14.8384 14.1523 15.1542 14.063 15.5002L12.481 21.6353C12.4516 21.7403 12.3886 21.8329 12.3017 21.8989C12.2147 21.9648 12.1086 22.0005 11.9995 22.0005C11.8904 22.0005 11.7843 21.9648 11.6973 21.8989C11.6104 21.8329 11.5474 21.7403 11.518 21.6353L9.937 15.5002Z",stroke:`url(#${n}-stroke1)`,strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),Wh.jsx("path",{d:"M18.9838 5.37522C18.9615 5.28871 18.9164 5.20975 18.8532 5.14657C18.79 5.08339 18.7111 5.0383 18.6246 5.01598L17.0909 4.62049C17.0647 4.61306 17.0417 4.5973 17.0253 4.5756C17.0089 4.5539 17 4.52744 17 4.50024C17 4.47304 17.0089 4.44659 17.0253 4.42488C17.0417 4.40318 17.0647 4.38742 17.0909 4.38L18.6246 3.98426C18.7111 3.96196 18.79 3.9169 18.8532 3.85377C18.9163 3.79064 18.9615 3.71174 18.9838 3.62527L19.3793 2.09155C19.3867 2.06528 19.4024 2.04214 19.4241 2.02565C19.4459 2.00917 19.4724 2.00024 19.4997 2.00024C19.527 2.00024 19.5535 2.00917 19.5752 2.02565C19.597 2.04214 19.6127 2.06528 19.6201 2.09155L20.0153 3.62527C20.0376 3.71178 20.0827 3.79074 20.1459 3.85391C20.2091 3.91709 20.288 3.96219 20.3745 3.98451L21.9082 4.37975C21.9346 4.38702 21.9579 4.40275 21.9744 4.42452C21.991 4.44628 22 4.47288 22 4.50024C22 4.5276 21.991 4.55421 21.9744 4.57597C21.9579 4.59774 21.9346 4.61347 21.9082 4.62074L20.3745 5.01598C20.288 5.0383 20.2091 5.08339 20.1459 5.14657C20.0827 5.20975 20.0376 5.28871 20.0153 5.37522L19.6198 6.90893C19.6124 6.9352 19.5967 6.95835 19.575 6.97483C19.5532 6.99132 19.5267 7.00024 19.4994 7.00024C19.4721 7.00024 19.4456 6.99132 19.4239 6.97483C19.4022 6.95835 19.3864 6.9352 19.3791 6.90893L18.9838 5.37522Z",stroke:`url(#${n}-stroke2)`,strokeLinecap:"round",strokeLinejoin:"round"}),Wh.jsx("path",{d:"M3.98382 20.3752C3.9615 20.2887 3.9164 20.2098 3.85322 20.1466C3.79005 20.0834 3.71109 20.0383 3.62458 20.016L2.09087 19.6205C2.0647 19.6131 2.04167 19.5973 2.02527 19.5756C2.00887 19.5539 2 19.5274 2 19.5002C2 19.473 2.00887 19.4466 2.02527 19.4249C2.04167 19.4032 2.0647 19.3874 2.09087 19.38L3.62458 18.9843C3.71106 18.962 3.78999 18.9169 3.85317 18.8538C3.91635 18.7906 3.96146 18.7117 3.98382 18.6253L4.37931 17.0916C4.38666 17.0653 4.4024 17.0421 4.42414 17.0257C4.44587 17.0092 4.4724 17.0002 4.49968 17.0002C4.52696 17.0002 4.55349 17.0092 4.57522 17.0257C4.59695 17.0421 4.6127 17.0653 4.62005 17.0916L5.01529 18.6253C5.03761 18.7118 5.0827 18.7907 5.14588 18.8539C5.20906 18.9171 5.28801 18.9622 5.37453 18.9845L6.90824 19.3797C6.93461 19.387 6.95787 19.4027 6.97445 19.4245C6.99102 19.4463 7 19.4729 7 19.5002C7 19.5276 6.99102 19.5542 6.97445 19.576C6.95787 19.5977 6.93461 19.6135 6.90824 19.6207L5.37453 20.016C5.28801 20.0383 5.20906 20.0834 5.14588 20.1466C5.0827 20.2098 5.03761 20.2887 5.01529 20.3752L4.6198 21.9089C4.61245 21.9352 4.5967 21.9583 4.57497 21.9748C4.55324 21.9913 4.52671 22.0002 4.49943 22.0002C4.47215 22.0002 4.44562 21.9913 4.42389 21.9748C4.40215 21.9583 4.38641 21.9352 4.37906 21.9089L3.98382 20.3752Z",stroke:`url(#${n}-stroke3)`,strokeLinecap:"round",strokeLinejoin:"round"}),Wh.jsxs("defs",{children:[Wh.jsxs("linearGradient",{id:`${n}-stroke1`,x1:"0.149625",y1:"0.148102",x2:"23.8539",y2:"23.8524",gradientUnits:"userSpaceOnUse",children:[Wh.jsx("stop",{offset:"0.287444",stopColor:"var(--start-color)"}),Wh.jsx("stop",{offset:"0.728693",stopColor:"var(--end-color)"})]}),Wh.jsxs("linearGradient",{id:`${n}-stroke2`,x1:"16.537",y1:"1.53728",x2:"22.463",y2:"7.46321",gradientUnits:"userSpaceOnUse",children:[Wh.jsx("stop",{offset:"0.287444",stopColor:"var(--start-color)"}),Wh.jsx("stop",{offset:"0.728693",stopColor:"var(--end-color)"})]}),Wh.jsxs("linearGradient",{id:`${n}-stroke3`,x1:"1.53704",y1:"16.5373",x2:"7.46296",y2:"22.4632",gradientUnits:"userSpaceOnUse",children:[Wh.jsx("stop",{offset:"0.287444",stopColor:"var(--start-color)"}),Wh.jsx("stop",{offset:"0.728693",stopColor:"var(--end-color)"})]})]})]})})),mW=K.forwardRef(((e,t)=>Wh.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",height:"32px",viewBox:"0 96 960 960",width:"32px",ref:t,...e,children:[Wh.jsx("title",{children:"User Avatar"}),Wh.jsx("path",{d:"M222 801q63-40 124.5-60.5T480 720q72 0 134 20.5T739 801q44-54 62.5-109T820 576q0-145-97.5-242.5T480 236q-145 0-242.5 97.5T140 576q0 61 19 116t63 109Zm257.814-195Q422 606 382.5 566.314q-39.5-39.686-39.5-97.5t39.686-97.314q39.686-39.5 97.5-39.5t97.314 39.686q39.5 39.686 39.5 97.5T577.314 566.5q-39.686 39.5-97.5 39.5Zm-.219 370q-83.146 0-156.275-31.5t-127.225-86Q142 804 111 731.159 80 658.319 80 575.5q0-82.819 31.5-155.659Q143 347 197.5 293t127.341-85.5Q397.681 176 480.5 176q82.819 0 155.659 31.5Q709 239 763 293t85.5 127Q880 493 880 575.734q0 82.734-31.5 155.5T763 858.5q-54 54.5-127.129 86T479.595 976Z",fill:"currentColor"})]})));function gW(e,t){return(gW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}
|
|
39
39
|
/*!
|
|
40
40
|
* content-type
|
|
41
41
|
* Copyright(c) 2015 Douglas Christopher Wilson
|
|
@@ -79,4 +79,4 @@ var ZW={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24
|
|
|
79
79
|
* @namespace
|
|
80
80
|
* @public
|
|
81
81
|
*)
|
|
82
|
-
*/;function W6(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}let Y6={async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null};function K6(e){Y6=e}const X6={exec:()=>null};function Q6(e,t=""){let n="string"==typeof e?e:e.source;const r={replace:(e,t)=>{let a="string"==typeof t?t:t.source;return a=a.replace(Z6.caret,"$1"),n=n.replace(e,a),r},getRegex:()=>new RegExp(n,t)};return r}const Z6={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>new RegExp(`^( {0,3}${e})((?:[\t ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ \t][^\\n]*)?(?:\\n|$))`),hrRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,"i")},J6=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,e8=/(?:[*+-]|\d{1,9}[.)])/,t8=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,n8=Q6(t8).replace(/bull/g,e8).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),r8=Q6(t8).replace(/bull/g,e8).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),a8=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,o8=/(?!\s*\])(?:\\.|[^\[\]\\])+/,i8=Q6(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",o8).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),s8=Q6(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,e8).getRegex(),l8="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",c8=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,u8=Q6("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$))","i").replace("comment",c8).replace("tag",l8).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),d8=Q6(a8).replace("hr",J6).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",l8).getRegex(),p8={blockquote:Q6(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",d8).getRegex(),code:/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,def:i8,fences:/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,hr:J6,html:u8,lheading:n8,list:s8,newline:/^(?:[ \t]*(?:\n|$))+/,paragraph:d8,table:X6,text:/^[^\n]+/},h8=Q6("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",J6).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3}\t)[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",l8).getRegex(),f8={...p8,lheading:r8,table:h8,paragraph:Q6(a8).replace("hr",J6).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",h8).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",l8).getRegex()},m8={...p8,html:Q6("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",c8).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:X6,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Q6(a8).replace("hr",J6).replace("heading"," *#{1,6} *[^\n]").replace("lheading",n8).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},g8=/^( {2,}|\\)\n(?!\s*$)/,y8=/[\p{P}\p{S}]/u,b8=/[\s\p{P}\p{S}]/u,v8=/[^\s\p{P}\p{S}]/u,k8=Q6(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,b8).getRegex(),w8=/(?!~)[\p{P}\p{S}]/u,x8=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,E8=Q6(x8,"u").replace(/punct/g,y8).getRegex(),_8=Q6(x8,"u").replace(/punct/g,w8).getRegex(),S8="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",T8=Q6(S8,"gu").replace(/notPunctSpace/g,v8).replace(/punctSpace/g,b8).replace(/punct/g,y8).getRegex(),C8=Q6(S8,"gu").replace(/notPunctSpace/g,/(?:[^\s\p{P}\p{S}]|~)/u).replace(/punctSpace/g,/(?!~)[\s\p{P}\p{S}]/u).replace(/punct/g,w8).getRegex(),A8=Q6("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,v8).replace(/punctSpace/g,b8).replace(/punct/g,y8).getRegex(),N8=Q6(/\\(punct)/,"gu").replace(/punct/g,y8).getRegex(),I8=Q6(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),R8=Q6(c8).replace("(?:--\x3e|$)","--\x3e").getRegex(),O8=Q6("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",R8).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),P8=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,D8=Q6(/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/).replace("label",P8).replace("href",/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),L8=Q6(/^!?\[(label)\]\[(ref)\]/).replace("label",P8).replace("ref",o8).getRegex(),M8=Q6(/^!?\[(ref)\](?:\[\])?/).replace("ref",o8).getRegex(),F8={_backpedal:X6,anyPunctuation:N8,autolink:I8,blockSkip:/\[[^[\]]*?\]\((?:\\.|[^\\\(\)]|\((?:\\.|[^\\\(\)])*\))*\)|`[^`]*?`|<[^<>]*?>/g,br:g8,code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,del:X6,emStrongLDelim:E8,emStrongRDelimAst:T8,emStrongRDelimUnd:A8,escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,link:D8,nolink:M8,punctuation:k8,reflink:L8,reflinkSearch:Q6("reflink|nolink(?!\\()","g").replace("reflink",L8).replace("nolink",M8).getRegex(),tag:O8,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,url:X6},j8={...F8,link:Q6(/^!?\[(label)\]\((.*?)\)/).replace("label",P8).getRegex(),reflink:Q6(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",P8).getRegex()},B8={...F8,emStrongRDelimAst:C8,emStrongLDelim:_8,url:Q6(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,"i").replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\.|[^\\])*?(?:\\.|[^\s~\\]))\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/},z8={...B8,br:Q6(g8).replace("{2,}","*").getRegex(),text:Q6(B8.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},H8={normal:p8,gfm:f8,pedantic:m8},U8={normal:F8,gfm:B8,breaks:z8,pedantic:j8},$8={"&":"&","<":"<",">":">",'"':""","'":"'"},G8=e=>$8[e];function V8(e,t){if(t){if(Z6.escapeTest.test(e))return e.replace(Z6.escapeReplace,G8)}else if(Z6.escapeTestNoEncode.test(e))return e.replace(Z6.escapeReplaceNoEncode,G8);return e}function q8(e){try{e=encodeURI(e).replace(Z6.percentDecode,"%")}catch{return null}return e}function W8(e,t){var n;const r=e.replace(Z6.findPipe,((e,t,n)=>{let r=!1,a=t;for(;--a>=0&&"\\"===n[a];)r=!r;return r?"|":" |"})).split(Z6.splitPipe);let a=0;if(r[0].trim()||r.shift(),r.length>0&&!(null==(n=r.at(-1))?void 0:n.trim())&&r.pop(),t)if(r.length>t)r.splice(t);else for(;r.length<t;)r.push("");for(;a<r.length;a++)r[a]=r[a].trim().replace(Z6.slashPipe,"|");return r}function Y8(e,t,n){const r=e.length;if(0===r)return"";let a=0;for(;a<r;){if(e.charAt(r-a-1)!==t)break;a++}return e.slice(0,r-a)}function K8(e,t,n,r,a){const o=t.href,i=t.title||null,s=e[1].replace(a.other.outputLinkReplace,"$1");if("!"!==e[0].charAt(0)){r.state.inLink=!0;const e={type:"link",raw:n,href:o,title:i,text:s,tokens:r.inlineTokens(s)};return r.state.inLink=!1,e}return{type:"image",raw:n,href:o,title:i,text:s}}class X8{constructor(e){i(this,"options"),i(this,"rules"),i(this,"lexer"),this.options=e||Y6}space(e){const t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:"space",raw:t[0]}}code(e){const t=this.rules.block.code.exec(e);if(t){const e=t[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:t[0],codeBlockStyle:"indented",text:this.options.pedantic?e:Y8(e,"\n")}}}fences(e){const t=this.rules.block.fences.exec(e);if(t){const e=t[0],n=function(e,t,n){const r=e.match(n.other.indentCodeCompensation);if(null===r)return t;const a=r[1];return t.split("\n").map((e=>{const t=e.match(n.other.beginningSpace);if(null===t)return e;const[r]=t;return r.length>=a.length?e.slice(a.length):e})).join("\n")}(e,t[3]||"",this.rules);return{type:"code",raw:e,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):t[2],text:n}}}heading(e){const t=this.rules.block.heading.exec(e);if(t){let e=t[2].trim();if(this.rules.other.endingHash.test(e)){const t=Y8(e,"#");this.options.pedantic?e=t.trim():t&&!this.rules.other.endingSpaceChar.test(t)||(e=t.trim())}return{type:"heading",raw:t[0],depth:t[1].length,text:e,tokens:this.lexer.inline(e)}}}hr(e){const t=this.rules.block.hr.exec(e);if(t)return{type:"hr",raw:Y8(t[0],"\n")}}blockquote(e){const t=this.rules.block.blockquote.exec(e);if(t){let e=Y8(t[0],"\n").split("\n"),n="",r="";const a=[];for(;e.length>0;){let t=!1;const o=[];let i;for(i=0;i<e.length;i++)if(this.rules.other.blockquoteStart.test(e[i]))o.push(e[i]),t=!0;else{if(t)break;o.push(e[i])}e=e.slice(i);const s=o.join("\n"),l=s.replace(this.rules.other.blockquoteSetextReplace,"\n $1").replace(this.rules.other.blockquoteSetextReplace2,"");n=n?`${n}\n${s}`:s,r=r?`${r}\n${l}`:l;const c=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(l,a,!0),this.lexer.state.top=c,0===e.length)break;const u=a.at(-1);if("code"===(null==u?void 0:u.type))break;if("blockquote"===(null==u?void 0:u.type)){const t=u,o=t.raw+"\n"+e.join("\n"),i=this.blockquote(o);a[a.length-1]=i,n=n.substring(0,n.length-t.raw.length)+i.raw,r=r.substring(0,r.length-t.text.length)+i.text;break}if("list"!==(null==u?void 0:u.type));else{const t=u,o=t.raw+"\n"+e.join("\n"),i=this.list(o);a[a.length-1]=i,n=n.substring(0,n.length-u.raw.length)+i.raw,r=r.substring(0,r.length-t.raw.length)+i.raw,e=o.substring(a.at(-1).raw.length).split("\n")}}return{type:"blockquote",raw:n,tokens:a,text:r}}}list(e){let t=this.rules.block.list.exec(e);if(t){let n=t[1].trim();const r=n.length>1,a={type:"list",raw:"",ordered:r,start:r?+n.slice(0,-1):"",loose:!1,items:[]};n=r?`\\d{1,9}\\${n.slice(-1)}`:`\\${n}`,this.options.pedantic&&(n=r?n:"[*+-]");const o=this.rules.other.listItemRegex(n);let i=!1;for(;e;){let n=!1,r="",s="";if(!(t=o.exec(e)))break;if(this.rules.block.hr.test(e))break;r=t[0],e=e.substring(r.length);let l=t[2].split("\n",1)[0].replace(this.rules.other.listReplaceTabs,(e=>" ".repeat(3*e.length))),c=e.split("\n",1)[0],u=!l.trim(),d=0;if(this.options.pedantic?(d=2,s=l.trimStart()):u?d=t[1].length+1:(d=t[2].search(this.rules.other.nonSpaceChar),d=d>4?1:d,s=l.slice(d),d+=t[1].length),u&&this.rules.other.blankLine.test(c)&&(r+=c+"\n",e=e.substring(c.length+1),n=!0),!n){const t=this.rules.other.nextBulletRegex(d),n=this.rules.other.hrRegex(d),a=this.rules.other.fencesBeginRegex(d),o=this.rules.other.headingBeginRegex(d),i=this.rules.other.htmlBeginRegex(d);for(;e;){const p=e.split("\n",1)[0];let h;if(c=p,this.options.pedantic?(c=c.replace(this.rules.other.listReplaceNesting," "),h=c):h=c.replace(this.rules.other.tabCharGlobal," "),a.test(c))break;if(o.test(c))break;if(i.test(c))break;if(t.test(c))break;if(n.test(c))break;if(h.search(this.rules.other.nonSpaceChar)>=d||!c.trim())s+="\n"+h.slice(d);else{if(u)break;if(l.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4)break;if(a.test(l))break;if(o.test(l))break;if(n.test(l))break;s+="\n"+c}u||c.trim()||(u=!0),r+=p+"\n",e=e.substring(p.length+1),l=h.slice(d)}}a.loose||(i?a.loose=!0:this.rules.other.doubleBlankLine.test(r)&&(i=!0));let p,h=null;this.options.gfm&&(h=this.rules.other.listIsTask.exec(s),h&&(p="[ ] "!==h[0],s=s.replace(this.rules.other.listReplaceTask,""))),a.items.push({type:"list_item",raw:r,task:!!h,checked:p,loose:!1,text:s,tokens:[]}),a.raw+=r}const s=a.items.at(-1);if(!s)return;s.raw=s.raw.trimEnd(),s.text=s.text.trimEnd(),a.raw=a.raw.trimEnd();for(let e=0;e<a.items.length;e++)if(this.lexer.state.top=!1,a.items[e].tokens=this.lexer.blockTokens(a.items[e].text,[]),!a.loose){const t=a.items[e].tokens.filter((e=>"space"===e.type)),n=t.length>0&&t.some((e=>this.rules.other.anyLine.test(e.raw)));a.loose=n}if(a.loose)for(let e=0;e<a.items.length;e++)a.items[e].loose=!0;return a}}html(e){const t=this.rules.block.html.exec(e);if(t){return{type:"html",block:!0,raw:t[0],pre:"pre"===t[1]||"script"===t[1]||"style"===t[1],text:t[0]}}}def(e){const t=this.rules.block.def.exec(e);if(t){const e=t[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),n=t[2]?t[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",r=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):t[3];return{type:"def",tag:e,raw:t[0],href:n,title:r}}}table(e){var t;const n=this.rules.block.table.exec(e);if(!n)return;if(!this.rules.other.tableDelimiter.test(n[2]))return;const r=W8(n[1]),a=n[2].replace(this.rules.other.tableAlignChars,"").split("|"),o=(null==(t=n[3])?void 0:t.trim())?n[3].replace(this.rules.other.tableRowBlankLine,"").split("\n"):[],i={type:"table",raw:n[0],header:[],align:[],rows:[]};if(r.length===a.length){for(const e of a)this.rules.other.tableAlignRight.test(e)?i.align.push("right"):this.rules.other.tableAlignCenter.test(e)?i.align.push("center"):this.rules.other.tableAlignLeft.test(e)?i.align.push("left"):i.align.push(null);for(let e=0;e<r.length;e++)i.header.push({text:r[e],tokens:this.lexer.inline(r[e]),header:!0,align:i.align[e]});for(const e of o)i.rows.push(W8(e,i.header.length).map(((e,t)=>({text:e,tokens:this.lexer.inline(e),header:!1,align:i.align[t]}))));return i}}lheading(e){const t=this.rules.block.lheading.exec(e);if(t)return{type:"heading",raw:t[0],depth:"="===t[2].charAt(0)?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){const t=this.rules.block.paragraph.exec(e);if(t){const e="\n"===t[1].charAt(t[1].length-1)?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:e,tokens:this.lexer.inline(e)}}}text(e){const t=this.rules.block.text.exec(e);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){const t=this.rules.inline.escape.exec(e);if(t)return{type:"escape",raw:t[0],text:t[1]}}tag(e){const t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){const t=this.rules.inline.link.exec(e);if(t){const e=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(e)){if(!this.rules.other.endAngleBracket.test(e))return;const t=Y8(e.slice(0,-1),"\\");if((e.length-t.length)%2==0)return}else{const e=function(e,t){if(-1===e.indexOf(t[1]))return-1;let n=0;for(let r=0;r<e.length;r++)if("\\"===e[r])r++;else if(e[r]===t[0])n++;else if(e[r]===t[1]&&(n--,n<0))return r;return n>0?-2:-1}(t[2],"()");if(-2===e)return;if(e>-1){const n=(0===t[0].indexOf("!")?5:4)+t[1].length+e;t[2]=t[2].substring(0,e),t[0]=t[0].substring(0,n).trim(),t[3]=""}}let n=t[2],r="";if(this.options.pedantic){const e=this.rules.other.pedanticHrefTitle.exec(n);e&&(n=e[1],r=e[3])}else r=t[3]?t[3].slice(1,-1):"";return n=n.trim(),this.rules.other.startAngleBracket.test(n)&&(n=this.options.pedantic&&!this.rules.other.endAngleBracket.test(e)?n.slice(1):n.slice(1,-1)),K8(t,{href:n?n.replace(this.rules.inline.anyPunctuation,"$1"):n,title:r?r.replace(this.rules.inline.anyPunctuation,"$1"):r},t[0],this.lexer,this.rules)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){const e=t[(n[2]||n[1]).replace(this.rules.other.multipleSpaceGlobal," ").toLowerCase()];if(!e){const e=n[0].charAt(0);return{type:"text",raw:e,text:e}}return K8(n,e,n[0],this.lexer,this.rules)}}emStrong(e,t,n=""){let r=this.rules.inline.emStrongLDelim.exec(e);if(!r)return;if(r[3]&&n.match(this.rules.other.unicodeAlphaNumeric))return;if(!(r[1]||r[2]||"")||!n||this.rules.inline.punctuation.exec(n)){const n=[...r[0]].length-1;let a,o,i=n,s=0;const l="*"===r[0][0]?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(l.lastIndex=0,t=t.slice(-1*e.length+n);null!=(r=l.exec(t));){if(a=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!a)continue;if(o=[...a].length,r[3]||r[4]){i+=o;continue}if((r[5]||r[6])&&n%3&&!((n+o)%3)){s+=o;continue}if(i-=o,i>0)continue;o=Math.min(o,o+i+s);const t=[...r[0]][0].length,l=e.slice(0,n+r.index+t+o);if(Math.min(n,o)%2){const e=l.slice(1,-1);return{type:"em",raw:l,text:e,tokens:this.lexer.inlineTokens(e)}}const c=l.slice(2,-2);return{type:"strong",raw:l,text:c,tokens:this.lexer.inlineTokens(c)}}}}codespan(e){const t=this.rules.inline.code.exec(e);if(t){let e=t[2].replace(this.rules.other.newLineCharGlobal," ");const n=this.rules.other.nonSpaceChar.test(e),r=this.rules.other.startingSpaceChar.test(e)&&this.rules.other.endingSpaceChar.test(e);return n&&r&&(e=e.substring(1,e.length-1)),{type:"codespan",raw:t[0],text:e}}}br(e){const t=this.rules.inline.br.exec(e);if(t)return{type:"br",raw:t[0]}}del(e){const t=this.rules.inline.del.exec(e);if(t)return{type:"del",raw:t[0],text:t[2],tokens:this.lexer.inlineTokens(t[2])}}autolink(e){const t=this.rules.inline.autolink.exec(e);if(t){let e,n;return"@"===t[2]?(e=t[1],n="mailto:"+e):(e=t[1],n=e),{type:"link",raw:t[0],text:e,href:n,tokens:[{type:"text",raw:e,text:e}]}}}url(e){var t;let n;if(n=this.rules.inline.url.exec(e)){let e,r;if("@"===n[2])e=n[0],r="mailto:"+e;else{let a;do{a=n[0],n[0]=(null==(t=this.rules.inline._backpedal.exec(n[0]))?void 0:t[0])??""}while(a!==n[0]);e=n[0],r="www."===n[1]?"http://"+n[0]:n[0]}return{type:"link",raw:n[0],text:e,href:r,tokens:[{type:"text",raw:e,text:e}]}}}inlineText(e){const t=this.rules.inline.text.exec(e);if(t){const e=this.lexer.state.inRawBlock;return{type:"text",raw:t[0],text:t[0],escaped:e}}}}class Q8{constructor(e){i(this,"tokens"),i(this,"options"),i(this,"state"),i(this,"tokenizer"),i(this,"inlineQueue"),this.tokens=[],this.tokens.links=Object.create(null),this.options=e||Y6,this.options.tokenizer=this.options.tokenizer||new X8,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};const t={other:Z6,block:H8.normal,inline:U8.normal};this.options.pedantic?(t.block=H8.pedantic,t.inline=U8.pedantic):this.options.gfm&&(t.block=H8.gfm,this.options.breaks?t.inline=U8.breaks:t.inline=U8.gfm),this.tokenizer.rules=t}static get rules(){return{block:H8,inline:U8}}static lex(e,t){return new Q8(t).lex(e)}static lexInline(e,t){return new Q8(t).inlineTokens(e)}lex(e){e=e.replace(Z6.carriageReturn,"\n"),this.blockTokens(e,this.tokens);for(let t=0;t<this.inlineQueue.length;t++){const e=this.inlineQueue[t];this.inlineTokens(e.src,e.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(e,t=[],n=!1){var r,a,o;for(this.options.pedantic&&(e=e.replace(Z6.tabCharGlobal," ").replace(Z6.spaceLine,""));e;){let i;if(null==(a=null==(r=this.options.extensions)?void 0:r.block)?void 0:a.some((n=>!!(i=n.call({lexer:this},e,t))&&(e=e.substring(i.raw.length),t.push(i),!0))))continue;if(i=this.tokenizer.space(e)){e=e.substring(i.raw.length);const n=t.at(-1);1===i.raw.length&&void 0!==n?n.raw+="\n":t.push(i);continue}if(i=this.tokenizer.code(e)){e=e.substring(i.raw.length);const n=t.at(-1);"paragraph"===(null==n?void 0:n.type)||"text"===(null==n?void 0:n.type)?(n.raw+="\n"+i.raw,n.text+="\n"+i.text,this.inlineQueue.at(-1).src=n.text):t.push(i);continue}if(i=this.tokenizer.fences(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.heading(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.hr(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.blockquote(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.list(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.html(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.def(e)){e=e.substring(i.raw.length);const n=t.at(-1);"paragraph"===(null==n?void 0:n.type)||"text"===(null==n?void 0:n.type)?(n.raw+="\n"+i.raw,n.text+="\n"+i.raw,this.inlineQueue.at(-1).src=n.text):this.tokens.links[i.tag]||(this.tokens.links[i.tag]={href:i.href,title:i.title});continue}if(i=this.tokenizer.table(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.lheading(e)){e=e.substring(i.raw.length),t.push(i);continue}let s=e;if(null==(o=this.options.extensions)?void 0:o.startBlock){let t=1/0;const n=e.slice(1);let r;this.options.extensions.startBlock.forEach((e=>{r=e.call({lexer:this},n),"number"==typeof r&&r>=0&&(t=Math.min(t,r))})),t<1/0&&t>=0&&(s=e.substring(0,t+1))}if(this.state.top&&(i=this.tokenizer.paragraph(s))){const r=t.at(-1);n&&"paragraph"===(null==r?void 0:r.type)?(r.raw+="\n"+i.raw,r.text+="\n"+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=r.text):t.push(i),n=s.length!==e.length,e=e.substring(i.raw.length)}else if(i=this.tokenizer.text(e)){e=e.substring(i.raw.length);const n=t.at(-1);"text"===(null==n?void 0:n.type)?(n.raw+="\n"+i.raw,n.text+="\n"+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=n.text):t.push(i)}else if(e){const t="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw new Error(t)}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}inlineTokens(e,t=[]){var n,r,a;let o=e,i=null;if(this.tokens.links){const e=Object.keys(this.tokens.links);if(e.length>0)for(;null!=(i=this.tokenizer.rules.inline.reflinkSearch.exec(o));)e.includes(i[0].slice(i[0].lastIndexOf("[")+1,-1))&&(o=o.slice(0,i.index)+"["+"a".repeat(i[0].length-2)+"]"+o.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(i=this.tokenizer.rules.inline.anyPunctuation.exec(o));)o=o.slice(0,i.index)+"++"+o.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;null!=(i=this.tokenizer.rules.inline.blockSkip.exec(o));)o=o.slice(0,i.index)+"["+"a".repeat(i[0].length-2)+"]"+o.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);let s=!1,l="";for(;e;){let i;if(s||(l=""),s=!1,null==(r=null==(n=this.options.extensions)?void 0:n.inline)?void 0:r.some((n=>!!(i=n.call({lexer:this},e,t))&&(e=e.substring(i.raw.length),t.push(i),!0))))continue;if(i=this.tokenizer.escape(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.tag(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.link(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(i.raw.length);const n=t.at(-1);"text"===i.type&&"text"===(null==n?void 0:n.type)?(n.raw+=i.raw,n.text+=i.text):t.push(i);continue}if(i=this.tokenizer.emStrong(e,o,l)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.codespan(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.br(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.del(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.autolink(e)){e=e.substring(i.raw.length),t.push(i);continue}if(!this.state.inLink&&(i=this.tokenizer.url(e))){e=e.substring(i.raw.length),t.push(i);continue}let c=e;if(null==(a=this.options.extensions)?void 0:a.startInline){let t=1/0;const n=e.slice(1);let r;this.options.extensions.startInline.forEach((e=>{r=e.call({lexer:this},n),"number"==typeof r&&r>=0&&(t=Math.min(t,r))})),t<1/0&&t>=0&&(c=e.substring(0,t+1))}if(i=this.tokenizer.inlineText(c)){e=e.substring(i.raw.length),"_"!==i.raw.slice(-1)&&(l=i.raw.slice(-1)),s=!0;const n=t.at(-1);"text"===(null==n?void 0:n.type)?(n.raw+=i.raw,n.text+=i.text):t.push(i)}else if(e){const t="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw new Error(t)}}return t}}class Z8{constructor(e){i(this,"options"),i(this,"parser"),this.options=e||Y6}space(e){return""}code({text:e,lang:t,escaped:n}){var r;const a=null==(r=(t||"").match(Z6.notSpaceStart))?void 0:r[0],o=e.replace(Z6.endingNewline,"")+"\n";return a?'<pre><code class="language-'+V8(a)+'">'+(n?o:V8(o,!0))+"</code></pre>\n":"<pre><code>"+(n?o:V8(o,!0))+"</code></pre>\n"}blockquote({tokens:e}){return`<blockquote>\n${this.parser.parse(e)}</blockquote>\n`}html({text:e}){return e}heading({tokens:e,depth:t}){return`<h${t}>${this.parser.parseInline(e)}</h${t}>\n`}hr(e){return"<hr>\n"}list(e){const t=e.ordered,n=e.start;let r="";for(let o=0;o<e.items.length;o++){const t=e.items[o];r+=this.listitem(t)}const a=t?"ol":"ul";return"<"+a+(t&&1!==n?' start="'+n+'"':"")+">\n"+r+"</"+a+">\n"}listitem(e){var t;let n="";if(e.task){const r=this.checkbox({checked:!!e.checked});e.loose?"paragraph"===(null==(t=e.tokens[0])?void 0:t.type)?(e.tokens[0].text=r+" "+e.tokens[0].text,e.tokens[0].tokens&&e.tokens[0].tokens.length>0&&"text"===e.tokens[0].tokens[0].type&&(e.tokens[0].tokens[0].text=r+" "+V8(e.tokens[0].tokens[0].text),e.tokens[0].tokens[0].escaped=!0)):e.tokens.unshift({type:"text",raw:r+" ",text:r+" ",escaped:!0}):n+=r+" "}return n+=this.parser.parse(e.tokens,!!e.loose),`<li>${n}</li>\n`}checkbox({checked:e}){return"<input "+(e?'checked="" ':"")+'disabled="" type="checkbox">'}paragraph({tokens:e}){return`<p>${this.parser.parseInline(e)}</p>\n`}table(e){let t="",n="";for(let a=0;a<e.header.length;a++)n+=this.tablecell(e.header[a]);t+=this.tablerow({text:n});let r="";for(let a=0;a<e.rows.length;a++){const t=e.rows[a];n="";for(let e=0;e<t.length;e++)n+=this.tablecell(t[e]);r+=this.tablerow({text:n})}return r&&(r=`<tbody>${r}</tbody>`),"<table>\n<thead>\n"+t+"</thead>\n"+r+"</table>\n"}tablerow({text:e}){return`<tr>\n${e}</tr>\n`}tablecell(e){const t=this.parser.parseInline(e.tokens),n=e.header?"th":"td";return(e.align?`<${n} align="${e.align}">`:`<${n}>`)+t+`</${n}>\n`}strong({tokens:e}){return`<strong>${this.parser.parseInline(e)}</strong>`}em({tokens:e}){return`<em>${this.parser.parseInline(e)}</em>`}codespan({text:e}){return`<code>${V8(e,!0)}</code>`}br(e){return"<br>"}del({tokens:e}){return`<del>${this.parser.parseInline(e)}</del>`}link({href:e,title:t,tokens:n}){const r=this.parser.parseInline(n),a=q8(e);if(null===a)return r;let o='<a href="'+(e=a)+'"';return t&&(o+=' title="'+V8(t)+'"'),o+=">"+r+"</a>",o}image({href:e,title:t,text:n}){const r=q8(e);if(null===r)return V8(n);let a=`<img src="${e=r}" alt="${n}"`;return t&&(a+=` title="${V8(t)}"`),a+=">",a}text(e){return"tokens"in e&&e.tokens?this.parser.parseInline(e.tokens):"escaped"in e&&e.escaped?e.text:V8(e.text)}}class J8{strong({text:e}){return e}em({text:e}){return e}codespan({text:e}){return e}del({text:e}){return e}html({text:e}){return e}text({text:e}){return e}link({text:e}){return""+e}image({text:e}){return""+e}br(){return""}}class e9{constructor(e){i(this,"options"),i(this,"renderer"),i(this,"textRenderer"),this.options=e||Y6,this.options.renderer=this.options.renderer||new Z8,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new J8}static parse(e,t){return new e9(t).parse(e)}static parseInline(e,t){return new e9(t).parseInline(e)}parse(e,t=!0){var n,r;let a="";for(let o=0;o<e.length;o++){const i=e[o];if(null==(r=null==(n=this.options.extensions)?void 0:n.renderers)?void 0:r[i.type]){const e=i,t=this.options.extensions.renderers[e.type].call({parser:this},e);if(!1!==t||!["space","hr","heading","code","table","blockquote","list","html","paragraph","text"].includes(e.type)){a+=t||"";continue}}const s=i;switch(s.type){case"space":a+=this.renderer.space(s);continue;case"hr":a+=this.renderer.hr(s);continue;case"heading":a+=this.renderer.heading(s);continue;case"code":a+=this.renderer.code(s);continue;case"table":a+=this.renderer.table(s);continue;case"blockquote":a+=this.renderer.blockquote(s);continue;case"list":a+=this.renderer.list(s);continue;case"html":a+=this.renderer.html(s);continue;case"paragraph":a+=this.renderer.paragraph(s);continue;case"text":{let n=s,r=this.renderer.text(n);for(;o+1<e.length&&"text"===e[o+1].type;)n=e[++o],r+="\n"+this.renderer.text(n);a+=t?this.renderer.paragraph({type:"paragraph",raw:r,text:r,tokens:[{type:"text",raw:r,text:r,escaped:!0}]}):r;continue}default:{const e='Token with "'+s.type+'" type was not found.';if(this.options.silent)return console.error(e),"";throw new Error(e)}}}return a}parseInline(e,t=this.renderer){var n,r;let a="";for(let o=0;o<e.length;o++){const i=e[o];if(null==(r=null==(n=this.options.extensions)?void 0:n.renderers)?void 0:r[i.type]){const e=this.options.extensions.renderers[i.type].call({parser:this},i);if(!1!==e||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(i.type)){a+=e||"";continue}}const s=i;switch(s.type){case"escape":case"text":a+=t.text(s);break;case"html":a+=t.html(s);break;case"link":a+=t.link(s);break;case"image":a+=t.image(s);break;case"strong":a+=t.strong(s);break;case"em":a+=t.em(s);break;case"codespan":a+=t.codespan(s);break;case"br":a+=t.br(s);break;case"del":a+=t.del(s);break;default:{const e='Token with "'+s.type+'" type was not found.';if(this.options.silent)return console.error(e),"";throw new Error(e)}}}return a}}class t9{constructor(e){i(this,"options"),i(this,"block"),this.options=e||Y6}preprocess(e){return e}postprocess(e){return e}processAllTokens(e){return e}provideLexer(){return this.block?Q8.lex:Q8.lexInline}provideParser(){return this.block?e9.parse:e9.parseInline}}i(t9,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens"]));const n9=new class{constructor(...e){i(this,"defaults",{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}),i(this,"options",this.setOptions),i(this,"parse",this.parseMarkdown(!0)),i(this,"parseInline",this.parseMarkdown(!1)),i(this,"Parser",e9),i(this,"Renderer",Z8),i(this,"TextRenderer",J8),i(this,"Lexer",Q8),i(this,"Tokenizer",X8),i(this,"Hooks",t9),this.use(...e)}walkTokens(e,t){var n,r;let a=[];for(const o of e)switch(a=a.concat(t.call(this,o)),o.type){case"table":{const e=o;for(const n of e.header)a=a.concat(this.walkTokens(n.tokens,t));for(const n of e.rows)for(const e of n)a=a.concat(this.walkTokens(e.tokens,t));break}case"list":{const e=o;a=a.concat(this.walkTokens(e.items,t));break}default:{const e=o;(null==(r=null==(n=this.defaults.extensions)?void 0:n.childTokens)?void 0:r[e.type])?this.defaults.extensions.childTokens[e.type].forEach((n=>{const r=e[n].flat(1/0);a=a.concat(this.walkTokens(r,t))})):e.tokens&&(a=a.concat(this.walkTokens(e.tokens,t)))}}return a}use(...e){const t=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach((e=>{const n={...e};if(n.async=this.defaults.async||n.async||!1,e.extensions&&(e.extensions.forEach((e=>{if(!e.name)throw new Error("extension name required");if("renderer"in e){const n=t.renderers[e.name];t.renderers[e.name]=n?function(...t){let r=e.renderer.apply(this,t);return!1===r&&(r=n.apply(this,t)),r}:e.renderer}if("tokenizer"in e){if(!e.level||"block"!==e.level&&"inline"!==e.level)throw new Error("extension level must be 'block' or 'inline'");const n=t[e.level];n?n.unshift(e.tokenizer):t[e.level]=[e.tokenizer],e.start&&("block"===e.level?t.startBlock?t.startBlock.push(e.start):t.startBlock=[e.start]:"inline"===e.level&&(t.startInline?t.startInline.push(e.start):t.startInline=[e.start]))}"childTokens"in e&&e.childTokens&&(t.childTokens[e.name]=e.childTokens)})),n.extensions=t),e.renderer){const t=this.defaults.renderer||new Z8(this.defaults);for(const n in e.renderer){if(!(n in t))throw new Error(`renderer '${n}' does not exist`);if(["options","parser"].includes(n))continue;const r=n,a=e.renderer[r],o=t[r];t[r]=(...e)=>{let n=a.apply(t,e);return!1===n&&(n=o.apply(t,e)),n||""}}n.renderer=t}if(e.tokenizer){const t=this.defaults.tokenizer||new X8(this.defaults);for(const n in e.tokenizer){if(!(n in t))throw new Error(`tokenizer '${n}' does not exist`);if(["options","rules","lexer"].includes(n))continue;const r=n,a=e.tokenizer[r],o=t[r];t[r]=(...e)=>{let n=a.apply(t,e);return!1===n&&(n=o.apply(t,e)),n}}n.tokenizer=t}if(e.hooks){const t=this.defaults.hooks||new t9;for(const n in e.hooks){if(!(n in t))throw new Error(`hook '${n}' does not exist`);if(["options","block"].includes(n))continue;const r=n,a=e.hooks[r],o=t[r];t9.passThroughHooks.has(n)?t[r]=e=>{if(this.defaults.async)return Promise.resolve(a.call(t,e)).then((e=>o.call(t,e)));const n=a.call(t,e);return o.call(t,n)}:t[r]=(...e)=>{let n=a.apply(t,e);return!1===n&&(n=o.apply(t,e)),n}}n.hooks=t}if(e.walkTokens){const t=this.defaults.walkTokens,r=e.walkTokens;n.walkTokens=function(e){let n=[];return n.push(r.call(this,e)),t&&(n=n.concat(t.call(this,e))),n}}this.defaults={...this.defaults,...n}})),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return Q8.lex(e,t??this.defaults)}parser(e,t){return e9.parse(e,t??this.defaults)}parseMarkdown(e){return(t,n)=>{const r={...n},a={...this.defaults,...r},o=this.onError(!!a.silent,!!a.async);if(!0===this.defaults.async&&!1===r.async)return o(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(null==t)return o(new Error("marked(): input parameter is undefined or null"));if("string"!=typeof t)return o(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected"));a.hooks&&(a.hooks.options=a,a.hooks.block=e);const i=a.hooks?a.hooks.provideLexer():e?Q8.lex:Q8.lexInline,s=a.hooks?a.hooks.provideParser():e?e9.parse:e9.parseInline;if(a.async)return Promise.resolve(a.hooks?a.hooks.preprocess(t):t).then((e=>i(e,a))).then((e=>a.hooks?a.hooks.processAllTokens(e):e)).then((e=>a.walkTokens?Promise.all(this.walkTokens(e,a.walkTokens)).then((()=>e)):e)).then((e=>s(e,a))).then((e=>a.hooks?a.hooks.postprocess(e):e)).catch(o);try{a.hooks&&(t=a.hooks.preprocess(t));let e=i(t,a);a.hooks&&(e=a.hooks.processAllTokens(e)),a.walkTokens&&this.walkTokens(e,a.walkTokens);let n=s(e,a);return a.hooks&&(n=a.hooks.postprocess(n)),n}catch(X4){return o(X4)}}}onError(e,t){return n=>{if(n.message+="\nPlease report this to https://github.com/markedjs/marked.",e){const e="<p>An error occurred:</p><pre>"+V8(n.message+"",!0)+"</pre>";return t?Promise.resolve(e):e}if(t)return Promise.reject(n);throw n}}};function r9(e,t){return n9.parse(e,t)}function a9(){const[e,t]=K.useState(!1);return[e,K.useCallback((async e=>{if(!(null==navigator?void 0:navigator.clipboard))return console.warn("Clipboard not supported"),!1;try{const n=await r9.parse(e),r={"text/plain":new Blob([e],{type:"text/plain"}),"text/html":new Blob([n],{type:"text/html"})};return await navigator.clipboard.write([new ClipboardItem(r)]),t(!0),setTimeout((()=>{t(!1)}),1e3),!0}catch(n){return console.warn("Copy failed",n),t(!1),!1}}),[])]}r9.options=r9.setOptions=function(e){return n9.setOptions(e),r9.defaults=n9.defaults,K6(r9.defaults),r9},r9.getDefaults=W6,r9.defaults=Y6,r9.use=function(...e){return n9.use(...e),r9.defaults=n9.defaults,K6(r9.defaults),r9},r9.walkTokens=function(e,t){return n9.walkTokens(e,t)},r9.parseInline=n9.parseInline,r9.Parser=e9,r9.parser=e9.parse,r9.Renderer=Z8,r9.TextRenderer=J8,r9.Lexer=Q8,r9.lexer=Q8.lex,r9.Tokenizer=X8,r9.Hooks=t9,r9.parse=r9,r9.options,r9.setOptions,r9.use,r9.walkTokens,r9.parseInline,e9.parse,Q8.lex;const o9=qB("h1",{_id:"markdownH1"}),i9=qB("h2",{_id:"markdownH2"}),s9=qB("p",{_id:"markdownP"}),l9=qB("li",{_id:"markdownLi"}),c9=qB("ul",{_id:"markdownUl"}),u9=qB("ol",{_id:"markdownOl"}),d9=qB(zY,{_id:"markdownLink"}),p9=qB("sup",{_id:"markdownSourceLink"}),h9=qB("table",{_id:"markdownTable"}),f9=qB("th",{_id:"markdownTh"}),m9=qB("td",{_id:"markdownTd"}),g9=qB("code",{_id:"markdownCode"}),y9=qB("div",{_id:"codeblockContainer"}),b9=qB("div",{_id:"codeblockHeader"}),v9=qB("span",{_id:"codeblockHeaderLanguage"}),k9=qB("button",{_id:"codeblockCopyButton",type:"button"}),w9=qB("div",{_id:"codeblockHighlighterWrapper"}),x9=qB("div",{_id:"codeblockHighlighter"}),E9=qB("code",{_id:"codeblockCode"}),_9=qB("input",{_id:"markdownInput"}),S9=y6.oneLight,T9=y6.vsDark,C9=({className:e="",children:t,onCopy:n})=>{var r;const a=e.replace(/^language-/,""),o=String(t).replace(/\n$/,""),[i,s]=a9(),{baseSettings:l}=nP(),c=null==(r=l.theme)?void 0:r.syntaxHighlighter,{lightTheme:u=S9,darkTheme:d=T9}=c??{},p=fB(u,d);return Wh.jsxs(y9,{children:[Wh.jsxs(b9,{children:[Wh.jsx(v9,{children:a}),Wh.jsx(k9,{"aria-label":"Copy to clipboard",onClick:()=>{s(o),null==n||n(a,o)},"data-copied":SL(i),children:Wh.jsx(jY,{iconKey:i?"codeCopied":"codeCopy"})})]}),Wh.jsx(w9,{children:Wh.jsx(q6,{theme:p,code:o,language:a,prism:l.prism,children:({className:e,tokens:t,getLineProps:n,getTokenProps:r,style:a})=>Wh.jsx(x9,{className:e,children:Wh.jsx(E9,{style:a,children:t.map(((e,t)=>Wh.jsx("div",{...n({line:e}),children:e.map(((e,t)=>Wh.jsx("span",{...r({token:e})},t)))},t)))})})})})]})};function A9(){return e=>{KZ(e,"element",((e,t,n)=>{"code"===e.tagName&&(n&&"pre"===n.tagName?e.properties.inline=!1:e.properties.inline=!0)}))}}const N9=({children:e,componentStyles:t,shouldOpenLinksInNewTab:n,onLinkClick:r,onCodeCopy:a,...o})=>{if(!e)return null;const i={h1:({children:e})=>Wh.jsx(o9,{children:e}),h2:({children:e})=>Wh.jsx(i9,{children:e}),p:({children:e})=>Wh.jsx(s9,{children:e}),li:({children:e})=>Wh.jsx(l9,{children:e}),ul:({children:e})=>Wh.jsx(c9,{children:e}),input:({type:e,checked:t,disabled:n,readOnly:r,required:a,value:o})=>Wh.jsx(_9,{type:e,checked:t,disabled:n,readOnly:r,required:a,value:o}),ol:({children:e,node:t})=>{var n;const r=null==(n=null==t?void 0:t.properties)?void 0:n.start,a="number"==typeof r?r:void 0;return Wh.jsx(u9,{style:{"--start":(null==r?void 0:r.toString())??"0"},start:a,children:e})},a:({children:e,href:t})=>{const a=X.Children.toArray(e),o=a[0],i="string"==typeof o&&/^\(\d+\)$/.test(o)&&1===a.length,s=i?o.match(/\d+/):e,l=Wh.jsx(d9,{isExternal:n,href:t,onClick:()=>{null==r||r(t,null==s?void 0:s.toString())},children:s});return i?Wh.jsx(p9,{children:l}):l},img:({src:e,alt:t})=>``,table:({children:e})=>Wh.jsx(h9,{children:e}),th:({children:e,isHeader:t})=>t?Wh.jsx(f9,{children:e}):Wh.jsx(m9,{children:e}),pre:({children:e})=>Wh.jsx("pre",{children:e}),code:({children:e,inline:t,className:n})=>t?Wh.jsx(g9,{children:e}):Wh.jsx(C9,{className:n,onCopy:a,children:e})},s=Wh.jsx(UJ,{remarkPlugins:[V4],rehypePlugins:[e3,A9],components:i,disallowedElements:I9,children:e.toString(),...o});return Wh.jsx(nB,{componentStyles:t,children:s})},I9=["script","iframe","frame","embed","meta","base","form","style","object"];function R9(){return Wh.jsxs("svg",{viewBox:"0 0 12 10",style:{width:"1.2em",fill:"none",strokeWidth:2,stroke:"currentColor",strokeDasharray:16},children:[Wh.jsx("title",{children:"Checkbox Icon"}),Wh.jsx("polyline",{points:"1.5 6 4.5 9 10.5 1"})]})}function O9(e){return Wh.jsxs("svg",{viewBox:"0 0 32 33",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:[Wh.jsx("title",{children:"Tag Line Logo Icon"}),Wh.jsx("path",{d:"M7.2413 7.9244C6.85545 7.9244 6.49892 8.13025 6.30599 8.4644L1.99827 15.9256C1.80535 16.2597 1.80535 16.6714 1.99827 17.0056L6.30599 24.4668C6.49892 24.8009 6.85545 25.0068 7.2413 25.0068L15.8567 25.0068C16.2426 25.0068 16.5991 24.8009 16.792 24.4668L21.0998 17.0056C21.2927 16.6714 21.2927 16.2597 21.0998 15.9256L16.792 8.4644C16.5991 8.13025 16.2426 7.9244 15.8567 7.9244L7.2413 7.9244Z",stroke:"currentColor",strokeWidth:"1.75"}),Wh.jsx("path",{d:"M24.8143 7.76209C27.3966 8.42659 27.1023 9.89204 28.1732 12.8728C28.8603 14.7852 32.182 17.1565 29.1465 21.766C28.2406 23.1417 25.3276 24.7738 23.2199 25.2265C18.5764 26.2085 15.8404 23.98 13.4131 20.3057C11.592 17.5265 12.2355 13.5253 14.9976 11.5606C17.6151 9.70372 21.4197 6.82238 24.8143 7.76209Z",stroke:"currentColor",strokeWidth:"1.75"})]})}const P9=e=>{const{logEvent:t}=wP(),{conversation:n}=iP(),{openForm:r}=dL(),a=iL();return{handleAction:t=>{var o;if("open_form"===e.action.type){null==(o=null==t?void 0:t.onOpenForm)||o.call(t);const n="name"in e?e:void 0;null==r||r(e.action.formSettings,n)}else"invoke_callback"===e.action.type&&(e.action.callback({conversation:n}),e.action.shouldCloseModal&&(null==a||a.setOpen(!1)))},logHelpAction:()=>{"name"in e&&(t({eventName:"get_help_option_clicked",properties:{getHelpOption:e,conversation:n}}),"open_form"!==e.action.type&&t({eventName:"user_escalation_indicated",properties:{escalationType:"get_help_option",getHelpOption:e,conversation:n}}))}}},D9=e=>{const t=/<em>(.*?)<\/em>/gs;let n;const r=[];let a=0;for(;null!==(n=t.exec(e));){const[t,o]=n;n.index>a&&r.push(e.slice(a,n.index)),r.push({content:o,highlighted:!0}),a=n.index+t.length}return a<e.length&&r.push(e.slice(a)),r};function L9(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}function M9(e){return e.toLowerCase().replace(/(^\w+:|^)\/\//,"").replace(/^www\./,"").replace(/\/$/,"").startsWith("github.com")}function F9(e,t){const n=["API","Docs","Documentation","Blogs",t],r=["\\|","-",":"],a=new RegExp(`^\\s*(${n.join("|")})(\\.\\w+)?\\s*(${r.join("|")})\\s*`,"gi"),o=new RegExp(`\\s*(${r.join("|")})\\s*(${n.join("|")})\\s*$`,"gi");return e.replace(a,"").replace(o,"").trim()}const j9={js:".js",db:"DB",sql:"SQL"};function B9(e){return Object.entries(j9).reduce(((e,[t,n])=>{const r=new RegExp(`([a-zA-Z0-9])${t}(?!\\w)`,"g");return e.replace(r,((e,t)=>t+n))}),e)}const z9=["API","AWS","GCP","SQL","CSS","JS","JDK","SDK","JRE","IDE","XML","GUI","CLI","AI","ML","DL","IoT","TCP","UDP","IP","FTP","RAM","ROM","SSD","HDD","VPS","VPN","OS","UI","UX","DB","OOP","CRM","ERP","POS","CAD","BI","CMS","SEO","SEM","PPC","B2B","B2C","SMB","ROI","KPI","CTA","CPC","CPM","CDN","MVC","FAQ","LMS","RPA","QA","QC","CRO","SVN","GIT","DOM","DNS","ISP","URL","URN","URI","SIP","NFC","LTE","OSI","RAS","DRM","DOS","WWW","LAN","WAN","SAN","NAS","NLP","OCR","IBM","HP","SAP","JWT","SSH","SSL","TLS","POP","NTP","BGP","ARP","2FA","MFA","RDP","VNC","SCP","PKI","XSS","DoS","CSV","HL7","SOP","PHP","JSP","NET","VBA","iOS","GNU","CPU","GPU","NIC","USB","VGA","AES","RSA","DES","ECC","WEP","WPA","IDS","IPS","PM","HR","TCO","BPM","SLA","SOW","AR","VR","XR","3D","2D","4D","iOS","OpenAPI","SSO"],H9=["a","an","the","and","as","but","or","nor","at","by","in","of","on","per","to","up","via","vs","with","is","it","for","are","not","out","off","yet","so","be","if","has","its","we","our","any","all","how","her","his","their","was","were"],U9=["BaaS","SaaS","PaaS","IaaS","HTML","JSON","HTTPS","HTTP","SMTP","DBMS","RDBMS","REST","SOAP","MVVM","VoIP","RFID","WYSIWYG","WLAN","OIDC","SAML","LDAP","IPSec","OAuth","OpenID","SFTP","IMAP","RTSP","DHCP","XMPP","SNMP","ICMP","IGMP","RARP","PPTP","L2TP","IPv4","IPv6","TOTP","HMAC","TFTP","CORS","CSRF","DDOS","YAML","MQTT","AMQP","HDLC","EDIFACT","DICOM","MATLAB","UNIX","HDMI","WiFi","WPA2","DDoS","ipadOS","watchOS","macOS","JavaScript","TypeScript","SSO","IDP","RBAC"];function $9(e){return`\\b${e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}\\b`}function G9(e,t,n,r=!1){return r&&new RegExp(`^${n}\\b`,"i").test(e)?e:e.replace(new RegExp(n,"gi"),t)}const V9=(e,t)=>{var n;if("documentation"!==e.type)return[];const r=null==t?void 0:t.organizationDisplayName;return((null==(n=e.breadcrumbs)?void 0:n.length)?e.breadcrumbs:function(e){try{const t=new URL(e);return t.pathname.split("/").filter((e=>e.length>0)).slice(0,-1).map(q9)}catch(t){return console.error("Invalid URL:",t),[]}}(e.url)).map((e=>{let t=e;return r&&(t=function(e,t){if(!function(e){const t=e.split(" ");for(const n of t)if(n[0]!==n[0].toUpperCase()||n.slice(1)!==n.slice(1).toLowerCase())return!1;return!0}(t))return e;const n=`(?<![@/])\\b${t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}\\b`;return new RegExp(`^${n}\\b`,"i").test(e)?e:e.replace(new RegExp(n,"gi"),t)}(e,r),t=F9(t,r)),t=B9(t),t=function(e){let t=e;return t=H9.reduce(((e,t)=>G9(e,t,$9(t),!0)),t),t=U9.reduce(((e,t)=>G9(e,t,$9(t))),t),t=z9.reduce(((e,t)=>G9(e,t,$9(t))),t),t}(t),t}))??[]},q9=e=>e.split(/[-_]/).map((e=>e.charAt(0).toUpperCase()+e.slice(1).toLowerCase())).join(" ");const W9=(e,t)=>{var n;if("chatSourceItem"===t)return e.description??void 0;const r=e.breadcrumbs??[],a=r.length>0?r[r.length-1]:void 0,o=e.title||(null==(n=null==a?void 0:a.props)?void 0:n.str);return function(e,t){if(!e)return;if(!t)return e;const n=t.trim(),r=[n,`<em>${n}</em>`].find((t=>e.startsWith(t)));return r?e.slice(r.length).trim():e}(e.description,o)},Y9=e=>{let t="LuBookOpen";"documentation"===e.type&&"book"===e.contentType?t="IoBookOutline":"documentation"===e.type&&"pdf"===e.contentType?t="FaFilePdf":"github_issue"===e.type||M9(e.url)?t="FaGithub":"documentation"===e.type&&"site"===e.contentType?t="LuGlobe":"discourse"===e.type?t="FaDiscourse":"discord"===e.type?t="FaDiscord":"slack_message"===e.type?t="FaSlack":"stackoverflow"===e.type&&(t="FaStackOverflow");return{builtIn:t}},K9=(e,t)=>{let n=e.title;if(!n)return"";const r=null==t?void 0:t.organizationDisplayName;return n=B9(n),r&&(n=F9(n,r)),n},X9=(e,t,n)=>{const{transformSource:r,...a}=n,o=V9(e,n),i=((e,t)=>{var n,r,a;const o=[];"documentation"===e.type&&"book"===e.contentType?o.push("Publications"):"documentation"===e.type&&"pdf"===e.contentType&&o.push("PDFs"),("github_issue"===e.type||M9(e.url))&&o.push("GitHub"),"discourse"===e.type&&o.push("Forums"),"discord"===e.type&&o.push("Discord"),"slack_message"===e.type&&o.push("Slack"),"stackoverflow"===e.type&&o.push("StackOverflow");const i=[],s=null==(n=null==t?void 0:t.tabs)?void 0:n.map((e=>"string"==typeof e?e:e[0]));for(const l of o)(null==s?void 0:s.includes(l))&&(l===(null==(r=e.breadcrumbs)?void 0:r[0])?i.push([l,{breadcrumbs:null==(a=e.breadcrumbs)?void 0:a.slice(1)}]):i.push(l));return i})(e,n),s=(null==r?void 0:r({...e,breadcrumbs:o,tabs:i},t,a))??{};return{id:(null==s?void 0:s.id)??e.id,title:(null==s?void 0:s.title)??K9(e,n),description:(null==s?void 0:s.description)??W9(e,t),breadcrumbs:(null==s?void 0:s.breadcrumbs)??o,icon:(null==s?void 0:s.icon)??Y9(e),tabs:(null==s?void 0:s.tabs)??i,url:(null==s?void 0:s.url)??e.url,tag:(null==s?void 0:s.tag)??e.tag,type:(null==s?void 0:s.type)??e.type,shouldOpenInNewTab:(null==s?void 0:s.shouldOpenInNewTab)??void 0,appendToUrl:(null==s?void 0:s.appendToUrl)??void 0}};const Q9=K.createContext(void 0),Z9=({children:e,open:t,setOpen:n})=>Wh.jsx(Q9.Provider,{value:{open:t,setOpen:n},children:e}),J9=()=>{const e=K.useContext(Q9);if(!e)throw new Error("useHoverPopover must be used within a HoverPopoverProvider");return e},e7=(e,t,n)=>{const r=iL(),a=fL();K.useEffect((()=>{if(!n||r&&!r.isOpen)return;requestAnimationFrame((()=>{(null==t?void 0:t.current)&&((null==a?void 0:a.view)&&a.view!==e||(t.current.focus(),t.current.selectionStart=t.current.value.length))}))}),[n,t,r,null==a?void 0:a.view,e])},t7=qB("div",{_id:"aiChatWrapper"}),n7=K.forwardRef(((e,t)=>{const{...n}=e,{isHidden:r,isMobile:a}=$j(),[o,i]=function(){const e=K.useRef(null),[t,n]=K.useState({width:0,height:0});return K.useEffect((()=>{if(!e.current)return;const t=new ResizeObserver((([e])=>{const{width:t,height:r}=e.contentRect;n({width:t,height:r})}));return t.observe(e.current),()=>{t.disconnect()}}),[e]),[e,t]}(),s=BB(t,o),l=!(null==i?void 0:i.width)||i.width>580,c=iL();return Wh.jsx(t7,{ref:s,"data-widget-md":SL(l),"data-hidden":SL(r),"data-in-modal":SL(!!c),"data-mobile":SL(a),...n})})),r7=qB("div",{_id:"aiChatConversationLoading"}),a7=e=>{const{isLoadingConversation:t}=$j();return t?Wh.jsx(r7,{children:Wh.jsx("span",{children:"Loading..."}),...e}):null},o7=qB("div",{_id:"aiChatRoot"}),i7=e=>{const{isLoadingConversation:t,isHidden:n}=$j(),{form:r}=dL();return t||r?null:Wh.jsx(o7,{"data-hidden":SL(n),...e})},s7=qB("div",{_id:"aiChatHeader"}),l7=qB("div",{_id:"aiChatHeader__Toolbar"}),c7=qB("div",{_id:"aiChatHeader__ToolbarHeaderWrapper"}),u7=qB("div",{_id:"aiChatHeader__ToolbarHeader"}),d7=K.memo((e=>{const{aiChatSettings:t}=nP(),n=`Ask ${t.aiAssistantName||"AI"}`;return Wh.jsx(u7,{...e,children:n})})),p7=qB("div",{_id:"aiChatContent"}),h7=qB(P$,{_id:"aiChatContentScrollArea"}),f7=qB(D$,{_id:"aiChatContentScrollArea__Viewport"}),m7=K.forwardRef((({children:e,...t},n)=>{const{containerRef:r}=function(e={}){const{threshold:t=150,interactionTimeout:n=150}=e,r=K.useRef(null),a=K.useRef(!0),o=K.useRef(!1),i=K.useCallback((()=>{const e=r.current;return!!e&&e.scrollHeight-e.clientHeight-e.scrollTop<t}),[t]),s=K.useCallback(((e=!1)=>{const t=r.current;t&&!o.current&&t.scrollTo({top:t.scrollHeight,behavior:e?"smooth":"auto"})}),[]);return K.useEffect((()=>{const e=r.current;if(!e)return;let t;const s=()=>{o.current=!0,a.current=i(),window.clearTimeout(t),t=window.setTimeout((()=>{o.current=!1}),n)};return e.addEventListener("scroll",s,{passive:!0}),()=>{e.removeEventListener("scroll",s),window.clearTimeout(t)}}),[i,n]),K.useEffect((()=>{const e=r.current;if(!e)return;const t=new MutationObserver((e=>{e.some((e=>"childList"===e.type||"characterData"===e.type||"attributes"===e.type&&"style"===e.attributeName))&&a.current&&s(!0)}));return t.observe(e,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["style"],characterData:!0}),()=>t.disconnect()}),[s]),K.useEffect((()=>{r.current&&s()}),[s]),{containerRef:r,scrollToBottom:s,isNearBottom:i}}(),a=BB(n,r);return Wh.jsx(f7,{ref:a,children:Wh.jsx("div",{"data-part":"grid",style:{display:"grid"},children:e}),...t})})),g7=qB(l$,{_id:"aiChatContentScrollArea__Scrollbar"}),y7=qB(v$,{_id:"aiChatContentScrollArea__Thumb"}),b7=qB(L$,{_id:"aiChatContentScrollArea__Corner"}),v7=qB("div",{_id:"aiChatMessages"}),k7=e=>{const t=$j(),{children:n,...r}=e;return Wh.jsx(v7,{children:CL(n,t),...r})},w7=qB("div",{_id:"aiChatDisclaimer"}),x7=K.memo((e=>{var t;const{aiChatSettings:n}=nP(),[r,a]=K.useState(!1),o=function(e,t){const[n,r]=K.useState(e);return K.useEffect((()=>{const n=setTimeout((()=>{r(e)}),t);return()=>{clearTimeout(n)}}),[e,t]),n}(r,100);return(null==(t=n.disclaimerSettings)?void 0:t.isEnabled)?Wh.jsx(Z9,{open:r,setOpen:a,children:Wh.jsx(YU,{open:o,onOpenChange:a,children:Wh.jsx(w7,{...e})})}):null})),E7=qB("span",{_id:"aiChatDisclaimerLabel"}),_7=K.memo((e=>{const{aiChatSettings:t}=nP(),n=t.disclaimerSettings;return Wh.jsx(E7,{children:null==n?void 0:n.label,...e})})),S7=qB(KU,{_id:"aiChatDisclaimerTrigger",children:Wh.jsx(jY,{iconKey:"info"})}),T7=K.memo((e=>{const{setOpen:t}=J9();return Wh.jsx(S7,{onMouseEnter:()=>t(!0),onMouseLeave:()=>t(!1),...e})})),C7=qB(XU,{_id:"aiChatDisclaimerContent"}),A7=e=>{const{setOpen:t}=J9();return Wh.jsx(C7,{onMouseEnter:()=>t(!0),onMouseLeave:()=>t(!1),side:"top",sideOffset:8,align:"end",alignOffset:-10,...e})},N7=qB(N9,{_id:"aiChatDisclaimerText"}),I7=K.memo((e=>{const{aiChatSettings:t}=nP(),n=t.aiAssistantName,r=t.disclaimerSettings,a=(null==r?void 0:r.tooltip)||`Information provided by ${n||"this AI assistant"} is not guaranteed to be accurate or comprehensive.`;return Wh.jsx(N7,{shouldOpenLinksInNewTab:!0,children:a,...e})})),R7=qB(QU,{_id:"aiChatDisclaimerArrow"}),O7=qB("div",{_id:"aiChatExampleQuestions"}),P7=e=>{var t;const{aiChatSettings:n}=nP(),{messages:r}=$j();return!(null==(t=n.exampleQuestions)?void 0:t.length)||r.length?null:Wh.jsx(O7,{...e})},D7=qB("h3",{_id:"aiChatExampleQuestionsLabel"}),L7=K.memo((e=>{const{aiChatSettings:t}=nP();return Wh.jsx(D7,{children:t.exampleQuestionsLabel,...e})})),M7=qB("div",{_id:"aiChatExampleQuestionsList"}),F7=K.memo((e=>{const{aiChatSettings:t}=nP(),n=t.exampleQuestions,{children:r,...a}=e;return Wh.jsx(M7,{children:CL(r,n),...a})})),j7=qB("div",{_id:"aiChatExampleQuestion"}),B7=K.forwardRef(((e,t)=>{const{aiChatSettings:n}=nP(),r=n.isFirstExampleQuestionHighlighted;return Wh.jsx(j7,{ref:t,"data-highlight":SL(r),...e})})),z7=qB("button",{_id:"aiChatExampleQuestionButton"}),H7=e=>{const{question:t,onClick:n,...r}=e,{handleSubmit:a}=$j();return Wh.jsx(z7,{onClick:L9(n,(()=>a(t))),children:t,...r})};qB("div",{_id:"aiChatWorkflows"});const U7=qB("h3",{_id:"aiChatWorkflowsLabel"});K.memo((e=>{const{aiChatSettings:t}=nP();return Wh.jsx(U7,{children:t.workflowsHeader,...e})}));const $7=qB("div",{_id:"aiChatWorkflowsList"});K.memo((e=>{const{aiChatSettings:t}=nP(),n=t.workflows,{children:r,...a}=e;return Wh.jsx($7,{children:CL(r,n),...a})})),qB("button",{_id:"aiChatWorkflow"});const G7=qB("div",{_id:"aiChatMessageWrapper"}),V7=e=>{const{message:t,...n}=e;return"system"===t.role?null:Wh.jsx(sB,{message:t,children:Wh.jsx(G7,{"data-role":t.role,...n})})},q7=K.memo((e=>{const{message:t,...n}=e,{aiChatSettings:r,baseSettings:a}=nP(),o=r.aiAssistantName,i=o?`Hi, I'm ${o}!`:"Hi!",s=r.chatSubjectName??a.organizationDisplayName,l=`${i} \n\n I'm an AI assistant trained on documentation, help articles, and other content.`,c=s?`\n\n Ask me anything about \`${s}\`.`:"\n\n Let me know how I can help.",u={content:r.introMessage??`${l}${c}`,id:"__intro__",...t,role:"assistant",links:[]};return Wh.jsx(V7,{message:u,...n})})),W7=qB("div",{_id:"aiChatMessageHeader"}),Y7=e=>{const{message:t}=lB();return Wh.jsx(W7,{"data-role":t.role,...e})},K7=qB("div",{_id:"aiChatMessageLoading"}),X7=e=>{var t;const{isLoading:n,isStreaming:r,messages:a}=$j(),{message:o}=lB();return(null==(t=a.at(-1))?void 0:t.id)===(null==o?void 0:o.id)&&"assistant"===o.role&&n&&!r?Wh.jsx(K7,{children:"Thinking...",...e}):null},Q7=qB("div",{_id:"aiChatMessageAvatar"}),Z7=e=>{const{message:t}=lB();return Wh.jsx(Q7,{"data-role":t.role,...e})},J7=qB(vz,{_id:"aiChatMessageAvatarContent"}),eee=e=>{const{message:t}=lB(),{baseSettings:n}=nP();return Wh.jsx(J7,{"data-username":SL("user"===t.role&&!!n.userProperties.name),"data-role":t.role,...e})},tee=qB(wz,{_id:"aiChatMessageAvatarFallback"}),nee=K.memo((e=>{const{baseSettings:t}=nP(),{message:n}=lB();return t.userProperties.name?Wh.jsx(tee,{"data-role":n.role,children:TL(t.userProperties.name),...e}):null})),ree=qB(kz,{_id:"aiChatMessageAvatarImage"}),aee=K.memo((e=>{const{onLoadingStatusChange:t,...n}=e,{aiChatSettings:r,baseSettings:{userProperties:a}}=nP(),{message:o}=lB(),{aiAssistantAvatar:i}=r??{},s="string"==typeof i?i:null==i?void 0:i.light,l=fB(s,("string"==typeof i?i:null==i?void 0:i.dark)??s),[c,u]=K.useState(l);K.useEffect((()=>{u(l)}),[l]);return"user"===o.role?a.name?null:r.userAvatar?Wh.jsx(ree,{"data-type":"image",alt:"User avatar","data-role":o.role,src:r.userAvatar,...e}):Wh.jsx(mW,{"data-type":"icon","data-role":o.role,...e}):c?Wh.jsx(ree,{src:c,alt:"AI assistant avatar","data-type":"image","data-role":o.role,onLoadingStatusChange:L9(t,(e=>{"error"===e&&u(null)})),...n}):Wh.jsx(fW,{"data-type":"icon","data-role":o.role,...e})})),oee=qB("span",{_id:"aiChatMessageName"}),iee=e=>{const{message:t}=lB();return Wh.jsx(oee,{"data-role":t.role,children:"user"===t.role?"You":"AI assistant",...e})},see=qB("div",{_id:"aiChatMessageContentWrapper"}),lee=e=>{const{message:t}=lB(),{messageButtons:n}=$j(),r=n[t.id]||[];return Wh.jsx(see,{"data-role":t.role,"data-has-message-buttons":SL(!!r.length),...e})},cee=qB("div",{_id:"aiChatMessageContent"}),uee=e=>{const{message:t}=lB();return Wh.jsx(cee,{"data-role":t.role,...e})},dee=qB("div",{_id:"aiChatMessageAttachments"}),pee=qB("div",{_id:"aiChatMessageAttachments__List"}),hee=e=>{var t,n;const{children:r,...a}=e,{message:o}=lB(),i=null==(n=null==(t=o.metadata)?void 0:t.attributes)?void 0:n.attachments;return i?Wh.jsx(pee,{children:CL(r,i),...a}):null},fee=qB("div",{_id:"aiChatMessageAttachments__Item"}),mee=e=>{const{attachment:t,onClick:n,...r}=e,{selectItem:a,onOpen:o}=oB();return Wh.jsx(Kh,{attachment:t,children:Wh.jsx(fee,{onClick:L9(n,(()=>{a(t),o()})),...r})})},gee=qB(MY,{_id:"aiChatMessageAttachments__ItemIcon"}),yee=e=>{var t;const{attachment:n}=Xh(),r=null==(t=n.contentType)?void 0:t.attachmentIcon;return r?Wh.jsx(gee,{iconSettings:r,...e}):null},bee=qB("span",{_id:"aiChatMessageAttachments__ItemTitle"}),vee=e=>{const{attachment:t}=Xh();return Wh.jsx(bee,{children:t.title,...e})},kee=qB(lW,{_id:"aiChatMessageAttachmentsPreview"}),wee=qB(uW,{_id:"aiChatMessageAttachmentsPreview__Overlay"}),xee=qB(dW,{_id:"aiChatMessageAttachmentsPreview__Content","aria-describedby":void 0}),Eee=qB(pW,{_id:"aiChatMessageAttachmentsPreview__Header"}),_ee=e=>{const{selectedItem:t}=oB();return Wh.jsx(Eee,{children:(null==t?void 0:t.title)||"Attachment",...e})},See=qB(hW,{_id:"aiChatMessageAttachmentsPreview__Close",children:Wh.jsx(jY,{iconKey:"close"})}),Tee=qB("p",{_id:"aiChatMessageAttachmentsPreview__Body"}),Cee=e=>{const{selectedItem:t}=oB();return Wh.jsx(Tee,{children:null==t?void 0:t.content,...e})},Aee=qB("div",{_id:"aiChatMessage"}),Nee=e=>{const{aiChatSettings:t}=nP(),{componentStyles:n,...r}=e,{message:a}=lB(),{logEvent:o}=wP(),i=AL(a),{conversation:s}=iP();return"user"===a.role?Wh.jsx(Aee,{"data-role":a.role,children:i,...r}):Wh.jsx(Aee,{"data-role":a.role,...r,children:Wh.jsx(N9,{children:i,componentStyles:n,shouldOpenLinksInNewTab:t.shouldOpenLinksInNewTab,onLinkClick:(e,t)=>{o({eventName:"assistant_message_inline_link_opened",properties:{title:null==t?void 0:t.toString(),url:e}})},onCodeCopy:(e,t)=>{o({eventName:"assistant_code_block_copied",properties:{conversation:s,language:e,code:t}})}})})},Iee=qB("div",{_id:"aiChatMessageToolbar"}),Ree=e=>{var t;const{isLoading:n,messages:r}=$j(),{message:a}=lB();return(null==(t=r.at(-1))?void 0:t.id)===(null==a?void 0:a.id)&&n||"user"===a.role?null:Wh.jsx(Iee,{...e})},Oee=qB("div",{_id:"aiChatMessageToolActions"}),Pee=e=>{const{children:t,...n}=e,{message:r}=lB(),{messageButtons:a}=$j(),o=a[r.id]||[];return Wh.jsx(Oee,{children:CL(t,o),...n})},Dee=qB("a",{_id:"aiChatMessageToolAction"}),Lee=qB("button",{_id:"aiChatMessageToolAction"}),Mee=e=>{const{onClick:t,action:n,...r}=e,{handleAction:a}=P9(n),{logEvent:o}=wP(),{conversation:i}=iP(),s=()=>{a(),o({eventName:"user_escalation_indicated",properties:{escalationType:"contact_us",conversation:i}})},l=n.label||"Contact Support",c=Wh.jsxs(Wh.Fragment,{children:[n.icon&&Wh.jsx(MY,{iconSettings:n.icon}),l]});return"open_link"===n.action.type?Wh.jsx(Dee,{href:n.action.url,target:"_blank",rel:"noopener","data-type":n.action.type,onClick:L9(t,s),children:c,...r}):Wh.jsx(Lee,{"data-type":n.action.type,onClick:L9(t,s),children:c,...r})},Fee=qB("button",{_id:"aiChatMessageAction"}),jee=e=>{var t,n,r;const{action:a,onClick:o,className:i,...s}=e,{conversation:l}=iP(),{message:c}=lB(),{isStreaming:u,messages:d}=$j(),[p,h]=a9(),{feedback:f,submitPositiveFeedback:m,setCurrentFeedback:g,currentFeedback:y}=PL(),{logEvent:b}=wP(),[v,k]=function(){const[e,t]=K.useState(!1);return[e,K.useCallback((async()=>(t(!0),setTimeout((()=>{t(!1)}),1e3),!0)),[])]}(),{baseSettings:{privacyPreferences:w}}=nP(),{optOutAllAnalytics:x}=w,E=(null==(t=d.at(-1))?void 0:t.id)===(null==c?void 0:c.id),_="assistant"===c.role;if(E&&u||!_||{copy:!1,upvote:x,downvote:x}[a])return null;const S={copy(){h(AL(c)),b({eventName:"assistant_message_copied",properties:{conversation:l}})},upvote(){m(c.id).then((()=>{k()}))},downvote(){g(c.id)}},T={copy:Wh.jsx(jY,{iconKey:p?"messageCopied":"messageCopy"}),upvote:Wh.jsx(jY,{iconKey:v?"messageCopied":"thumbsUp"}),downvote:Wh.jsx(jY,{iconKey:"thumbsDown"})},C={copy:{"data-copied":SL(p)},upvote:{"data-upvoted":SL("positive"===(null==(n=f[c.id])?void 0:n.type))},downvote:{"data-downvoted":SL("negative"===(null==(r=f[c.id])?void 0:r.type)),"data-state":null===y?"closed":"open"}};return Wh.jsx(Fee,{"data-action":a,...C[a],children:T[a],"aria-label":{copy:"Copy Message",upvote:"Upvote Message",downvote:"Downvote Message"}[a],className:`${i} ${a}`,onClick:L9(o,S[a]),...s})},Bee=qB("div",{_id:"aiChatMessageSources"}),zee=qB("div",{_id:"aiChatMessageSources__Header"}),Hee=e=>Wh.jsx(zee,{children:"Sources",...e}),Uee=qB("div",{_id:"aiChatMessageSources__List"}),$ee=e=>{const{message:t}=lB(),{children:n,...r}=e,{baseSettings:{transformSource:a,organizationDisplayName:o},aiChatSettings:{shouldOpenLinksInNewTab:i},searchSettings:{tabs:s}}=nP();if("assistant"!==t.role)return null;const l=t.links.map((e=>{const t=X9(e,"chatSourceItem",{organizationDisplayName:o,tabs:s,transformSource:a}),n=void 0!==t.shouldOpenInNewTab?t.shouldOpenInNewTab:i;return{...t,isExternal:n}}));return Wh.jsx(Uee,{children:CL(n,l),...r})},Gee=qB(zY,{_id:"aiChatMessageSourceItem"}),Vee=e=>{var t;const{source:n,onClick:r,...a}=e,{logEvent:o}=wP(),{conversation:i}=iP();return Wh.jsx(NB,{source:n,children:Wh.jsx(Gee,{"data-type":n.type,appendToUrl:n.appendToUrl,isExternal:n.isExternal,"data-breadcrumbs":!!(null==(t=n.breadcrumbs)?void 0:t.length),onClick:L9(r,(()=>{o({eventName:"assistant_source_item_clicked",properties:{conversation:i,link:n}})})),...a})})},qee=qB("div",{_id:"aiChatMessageSourceItem__Breadcrumbs"}),Wee=e=>{var t;const{source:n}=IB();return(null==(t=n.breadcrumbs)?void 0:t.length)?Wh.jsx(qee,{"data-type":n.type,...e}):null},Yee=qB(jY,{_id:"aiChatMessageSourceItem__BreadcrumbIcon",iconKey:"breadcrumbSeparator"}),Kee=qB(MY,{_id:"aiChatMessageSourceItem__Icon"}),Xee=e=>{const{source:t}=IB();return Wh.jsx(Kee,{iconSettings:t.icon,"data-type":t.type,...e})},Qee=qB("span",{_id:"aiChatMessageSourceItem__Title"}),Zee=e=>{const{source:t}=IB();return Wh.jsx(Qee,{"data-type":t.type,children:t.title,...e})},Jee=qB("span",{_id:"aiChatMessageSourceItem__Tag"}),ete=e=>{const{source:t}=IB();return Wh.jsx(Jee,{"data-type":t.type,...e})},tte=qB("span",{_id:"aiChatMessageSourceItem__Description"}),nte=e=>{const{source:t}=IB(),{children:n,...r}=e,a=K.useMemo((()=>t.description?D9(t.description):[]),[t.description]);return a.length?Wh.jsx(tte,{"data-type":t.type,children:CL(n,a),...r}):null},rte=qB("span",{_id:"aiChatMessageSourceItem__DescriptionPart"}),ate=e=>{const{part:t,...n}=e,{source:r}=IB();return"string"==typeof t?t:Wh.jsx(rte,{"data-type":r.type,children:t.content,"data-highlighted":SL(t.highlighted),...n})},ote=qB(jY,{_id:"aiChatMessageSourceItem__Indicator"}),ite=e=>{const{source:t}=IB();return Wh.jsx(ote,{iconKey:t.isExternal?"openLinkInNewTab":"openLinkInSameTab",...e})},ste=qB("div",{_id:"aiChatFooter"}),lte=qB("div",{_id:"aiChatInput__Fieldset"}),cte=qB("div",{_id:"aiChatInput__Group"}),ute=qB("textarea",{_id:"aiChatInput"}),dte=K.forwardRef((({onChange:e,onKeyDown:t,...n},r)=>{const{handleInputChange:a,handleInputKeyDown:o,input:i,error:s,shouldAutoFocusInput:l,inputRef:c}=$j(),{aiChatSettings:u}=nP(),d=BB(r,c);return e7("chat",c,l),Wh.jsx(ute,{asChild:!0,ref:d,maxLength:99999,placeholder:u.placeholder,value:i,onChange:L9(e,a),onKeyDown:L9(t,o),disabled:!!s||u.isViewOnly,...n,children:Wh.jsx(lz,{})})})),pte=qB("button",{_id:"aiChatInput__SendButton"}),hte=e=>{const{handleSubmit:t,isSubmitDisabled:n,error:r}=$j(),{aiChatSettings:a}=nP(),{onClick:o,...i}=e;return Wh.jsx(pte,{onClick:L9(o,(()=>t())),"aria-label":"Send message",disabled:n||!!r||a.isViewOnly,...i})},fte=qB(jY,{_id:"aiChatInput__SendButtonIcon",iconKey:"chatSubmit"}),mte=qB("div",{_id:"aiChatAttachmentsBar"}),gte=e=>{var t;const{selectedWorkflow:n}=$j();return n&&(null==(t=n.supportedInputs)?void 0:t.length)?Wh.jsx(Vj,{children:Wh.jsx(mte,{...e})}):null},yte=qB("div",{_id:"aiChatAttachmentsBar__List"}),bte=e=>{const{children:t,...n}=e,{messageAttachments:r}=$j();return Wh.jsx(yte,{children:CL(t,r),...n})},vte=qB("div",{_id:"aiChatAttachmentsBar__Attachment"}),kte=e=>{const{attachment:t,...n}=e;return Wh.jsx(Kh,{attachment:t,children:Wh.jsx(vte,{...n})})},wte=qB(MY,{_id:"aiChatAttachmentsBar__AttachmentIcon"}),xte=e=>{var t;const{attachment:n}=Xh(),r=null==(t=n.contentType)?void 0:t.attachmentIcon;return r?Wh.jsx(wte,{iconSettings:r,...e}):null},Ete=qB("span",{_id:"aiChatAttachmentsBar__AttachmentTitle"}),_te=e=>{const{attachment:t}=Xh();return Wh.jsx(Ete,{children:t.title,...e})},Ste=qB("button",{_id:"aiChatAttachmentsBar__AttachmentDelete"}),Tte=e=>{const{onClick:t,...n}=e,{attachment:r}=Xh(),{setMessageAttachments:a}=$j();return Wh.jsx(Ste,{"aria-label":"Remove attachment",children:Wh.jsx(jY,{iconKey:"close"}),onClick:L9(t,(()=>{a((e=>e.filter((e=>e.id!==r.id))))})),...n})},Cte=qB("div",{_id:"aiChatAttachmentsBar__Actions"}),Ate=qB(_j,{_id:"aiChatAttachmentsBar__InfoTip",delayDuration:0}),Nte=qB(jj,{_id:"aiChatAttachmentsBar__InfoTipIcon",children:Wh.jsx(jY,{iconKey:"info"})}),Ite=qB(zj,{_id:"aiChatAttachmentsBar__InfoTipArrow"}),Rte=qB(Bj,{_id:"aiChatAttachmentsBar__InfoTipText",side:"bottom",sideOffset:3,align:"center",children:Wh.jsxs(Wh.Fragment,{children:[Wh.jsx(Ite,{}),"Attachments will be kept in context for the entire conversation."]})}),Ote=qB("div",{_id:"aiChatAttachmentsBar__Inputs"}),Pte=e=>{const{children:t,...n}=e,{selectedWorkflow:r}=$j();return(null==r?void 0:r.supportedInputs)?Wh.jsx(Ote,{children:CL(t,r.supportedInputs),...n}):null},Dte=qB("button",{_id:"aiChatAttachmentsBar__Input"}),Lte=e=>{const{input:t,onClick:n,...r}=e,{selectedWorkflow:a,messageAttachments:o,setMessageAttachments:i}=$j(),{selectInput:s,onOpen:l}=qj();return Wh.jsx(Dte,{children:t.displayName,onClick:L9(n,(()=>{if("FUNCTIONAL_MULTI_ATTACHMENT"===t.type){if(!a)return;return t.onInvoke(a,t,i,[...o])}s(t),l()})),...r})},Mte=qB(lW,{_id:"aiChatAttachmentsBar__Modal"}),Fte=qB(uW,{_id:"aiChatAttachmentsBar__ModalOverlay"}),jte=qB(dW,{_id:"aiChatAttachmentsBar__ModalContent","aria-describedby":void 0}),Bte=qB("div",{_id:"aiChatAttachmentsBar__ModalHeader"}),zte=qB(pW,{_id:"aiChatAttachmentsBar__ModalHeading"}),Hte=e=>{const{selectedInput:t}=qj(),n=`Add ${null==t?void 0:t.displayName}`;return Wh.jsx(zte,{children:n,...e})},Ute=qB("span",{_id:"aiChatAttachmentsBar__ModalDescription"}),$te=e=>{var t;const{selectedInput:n}=qj(),r=null==(t=null==n?void 0:n.workflowModalProps)?void 0:t.modalHelpText;return r?Wh.jsx(Ute,{children:r,...e}):null},Gte=qB("div",{_id:"aiChatAttachmentsBar__ModalHelp"}),Vte=qB(hW,{_id:"aiChatAttachmentsBar__ModalClose",children:Wh.jsx(jY,{iconKey:"close"})}),qte=qB("div",{_id:"aiChatAttachmentsBar__ModalBody"}),Wte=qB("form",{_id:"aiChatAttachmentsBar__Form"}),Yte=e=>{const{onSubmit:t,...n}=e,{form:r}=qj();return Wh.jsx(Wte,{onSubmit:L9(t,r.onSubmit),...n})},Kte=qB("div",{_id:"aiChatAttachmentsBar__FormTitle",role:"group"}),Xte=qB("label",{_id:"aiChatAttachmentsBar__FormTitleLabel"}),Qte=e=>{const{form:t,selectedInput:n}=qj();return Wh.jsx(Xte,{htmlFor:`${null==n?void 0:n.id}-title`,children:t.labels.title,...e})},Zte=qB("input",{_id:"aiChatAttachmentsBar__FormTitleInput"}),Jte=e=>{const{onChange:t,...n}=e,{form:r,selectedInput:a}=qj();return Wh.jsx(Zte,{name:"title",value:r.data.title,id:`${null==a?void 0:a.id}-title`,"data-invalid":SL(!!r.errors.title),"aria-invalid":!!r.errors.title,onChange:L9(t,r.onChange),...n})},ene=qB("span",{_id:"aiChatAttachmentsBar__FormTitleError"}),tne=e=>{const{form:t}=qj();return t.errors.title?Wh.jsx(ene,{"aria-live":"polite",children:t.errors.title,...e}):null},nne=qB("div",{_id:"aiChatAttachmentsBar__FormTitle",role:"group"}),rne=qB("label",{_id:"aiChatAttachmentsBar__FormContentLabel"}),ane=e=>{const{form:t,selectedInput:n}=qj();return Wh.jsx(rne,{htmlFor:`${null==n?void 0:n.id}-content`,children:t.labels.content,...e})},one=qB("textarea",{_id:"aiChatAttachmentsBar__FormTitleInput"}),ine=e=>{const{onChange:t,...n}=e,{form:r,selectedInput:a}=qj();return Wh.jsx(one,{asChild:!0,rows:4,name:"content",value:r.data.content,id:`${null==a?void 0:a.id}-content`,"data-invalid":SL(!!r.errors.content),"aria-invalid":!!r.errors.content,onChange:L9(t,r.onChange),...n,children:Wh.jsx(lz,{maxRows:10})})},sne=qB("span",{_id:"aiChatAttachmentsBar__FormContentError"}),lne=e=>{const{form:t}=qj();return t.errors.content?Wh.jsx(sne,{"aria-live":"polite",children:t.errors.content,...e}):null},cne=qB("button",{_id:"aiChatAttachmentsBar__FormSubmitButton",children:"Upload",type:"submit"}),une=qB("div",{_id:"aiChatActionBar"}),dne=qB("div",{_id:"aiChat__ChatActions"}),pne=qB("div",{_id:"aiChatTagline__Container"}),hne=qB("span",{_id:"aiChatTagline__Text",children:"Powered by"}),fne=qB(O9,{_id:"aiChatTagline__Logo"}),mne=qB("a",{_id:"aiChatTagline__BrandName",children:"inkeep",href:"https://www.inkeep.com/",target:"_blank",rel:"noopener noreferrer"}),gne=qB(jj,{_id:"aiChat__ChatAction"}),yne=e=>{const{action:t,onClick:n,className:r,...a}=e,{clear:o,stop:i,isLoading:s,messages:l,selectedWorkflow:c}=$j(),{conversation:u}=iP(),{aiChatSettings:d,baseSettings:p}=nP(),{logEvent:h}=wP(),[f,m]=a9(),[g,y]=a9();if({help:!1,copy:0===l.length||!d.isCopyChatButtonVisible||s,share:0===l.length||!d.isShareButtonVisible||!u.id||!!c||s,clear:0===l.length||d.isViewOnly||s,stop:!s}[t])return null;const b={help:()=>{},copy:()=>{const e=l.map((e=>{var t,n;const r=`**${"assistant"===e.role?"AI Assistant":"User"}**`,a=AL(e),o=TP(null==(n=null==(t=e.metadata)?void 0:t.attributes)?void 0:n.attachments);return`${r}\n\n${a}${o?`\n\n**Attachments**\n\n${o}`:""}`})).join("\n\n---\n\n");m(e)},share:async()=>{const e={visibility:"public",tags:[],userProperties:{},messages:u.messages.map((e=>({...e,createdAt:void 0,updatedAt:void 0,id:Date.now().toString()+e.id,conversationId:void 0})))},{apiKey:t,analyticsApiBaseUrl:n}=p,r=await sP("",e,t,n);if(r){const e=`${d.shareChatUrlBasePath}?${rP}=${null==r?void 0:r.id}`;y(e),h({eventName:"chat_share_button_clicked",properties:{sharedConversationId:null==r?void 0:r.id,originalConversationId:u.id,sharedChatUrl:e,conversation:r}})}},clear:o,stop:i},v={copy:f,share:g};return Wh.jsx(_j,{delayDuration:0,open:v[t],children:Wh.jsx(gne,{"data-type":t,"data-copied":SL(f||g),className:`${r} ${t}`,children:Wh.jsx(vne,{action:t}),onClick:L9(n,b[t]),...a})})},bne=qB("span",{_id:"aiChat__ChatActionLabel"}),vne=e=>{const{action:t,...n}=e,{aiChatSettings:r}=nP(),a=r.toolbarButtonLabels??{},o={help:a.getHelp??"Get Help",copy:a.copyChat??"Copy",share:a.share??"Share",clear:a.clear??"Clear",stop:a.stop??"Stop"};return Wh.jsx(bne,{children:o[t],...n})},kne=qB(Ij,{_id:"aiChat__ChatActionFeeback"}),wne=e=>{const{action:t,children:n,...r}=e;return Wh.jsxs(kne,{sideOffset:5,...r,children:[Wh.jsx(zj,{}),n||{copy:"Copied!",share:"Link copied!"}[t]]})},xne=qB(YU,{_id:"aiChatHelpActions"}),Ene=qB(yne,{_id:"aiChatHelpAction",action:"help"}),_ne=qB("a",{_id:"aiChatHelpAction",target:"_blank",rel:"noreferrer"}),Sne=e=>{const{action:t,onClick:n,...r}=e,{handleAction:a,logHelpAction:o}=P9(t),i=t.action.type,s={"aria-label":t.name,"data-name":t.name,children:t.name,onClick:L9(n,(()=>{a(),o()})),...r};return"open_link"===i?Wh.jsx(_ne,{href:t.action.url,...s}):Wh.jsx(Ene,{...s})},Tne=qB(KU,{_id:"aiChatHelpActions__Trigger"}),Cne=K.memo((e=>{var t;const{aiChatSettings:n}=nP();return Wh.jsx(yne,{action:"help",...e,asChild:!0,children:Wh.jsx(Tne,{children:(null==(t=n.toolbarButtonLabels)?void 0:t.getHelp)??"Get Help"})})})),Ane=qB(XU,{_id:"aiChatHelpActions__Menu"}),Nne=e=>Wh.jsx(Ane,{side:"top",sideOffset:8,align:"center",alignOffset:-10,...e}),Ine=qB(QU,{_id:"aiChatHelpActions__MenuArrow"}),Rne=e=>{const{action:t,onClick:n,...r}=e,{handleAction:a,logHelpAction:o}=P9(t),{setOpen:i}=(()=>{const e=K.useContext(Jj);if(!e)throw new Error("useHelpMenu must be used within a HelpMenuProvider");return e})(),s=t.action.type,l=qB("open_link"===s?"a":"button",{_id:"aiChatHelpActions__MenuItem",children:t.name,"aria-label":t.name,"data-name":t.name,"data-type":t.action.type,..."open_link"===s&&{href:t.action.url,target:"_blank",rel:"noopener"},onClick:L9(n,(()=>{a({onOpenForm:()=>i(!1)}),o()}))});return Wh.jsx(l,{...r})},One=qB(MY,{_id:"aiChatHelpActions_MenuItemIcon"}),Pne=e=>{const{action:t,...n}=e;return t.icon?Wh.jsx(One,{iconSettings:t.icon,...n}):null},Dne=qB(lW,{_id:"aiChatFeedbackModal"}),Lne=qB(uW,{_id:"aiChatFeedbackModal__Overlay"}),Mne=qB(dW,{_id:"aiChatFeedbackModal__Content","aria-describedby":void 0}),Fne=qB(pW,{_id:"aiChatFeedbackModal__Header",children:"Help improve my answers!"}),jne=qB(hW,{_id:"aiChatFeedbackModal__Close",children:Wh.jsx(jY,{iconKey:"close"})}),Bne=qB("div",{_id:"aiChatFeedbackModal__Body"}),zne=qB("form",{_id:"aiChatFeedbackForm"}),Hne=e=>{const{onSubmit:t,...n}=e,{submitNegativeFeedback:r,currentFeedback:a,setCurrentFeedback:o}=PL();return Wh.jsx(zne,{onSubmit:L9(t,(e=>{e.preventDefault();const t=e.target,n=new FormData(t),i=Object.fromEntries(n.entries());a&&(r(a,i),o(null))})),...n})},Une=qB("div",{_id:"aiChatFeedbackItem"}),$ne=e=>{const{name:t,...n}=e;return Wh.jsx(Yj,{name:t,children:Wh.jsx(Une,{...n})})},Gne=qB(Pz,{_id:"aiChatFeedbackItem__Checkbox"}),Vne=e=>{const{name:t,focusItem:n}=Kj(),{onCheckedChange:r,...a}=e;return Wh.jsx(Gne,{id:`feedback-${t}`,name:t,onCheckedChange:L9(r,(e=>{var t;e&&(null==(t=null==n?void 0:n.current)||t.focus())})),...a})},qne=qB(Dz,{_id:"aiChatFeedbackItem__CheckboxIndicator",children:Wh.jsx(R9,{})}),Wne=qB("label",{_id:"aiChatFeedbackItem__Label"}),Yne=e=>{const{name:t}=Kj();return Wh.jsx(Wne,{htmlFor:`feedback-${t}`,children:{unrelated_response:"Didn't answer my question",inaccurate_statement:"Inaccurate statement",inaccurate_code_snippet:"Inaccurate code snippet",irrelevant_citations:"Irrelevant citations"}[t],...e})},Kne=qB("textarea",{_id:"aiChatFeedbackItem__Description",placeholder:"Please describe"}),Xne=e=>{const{name:t,focusItem:n}=Kj();return Wh.jsx(Kne,{ref:n,name:`${t}:description`,...e})},Qne=qB("button",{_id:"aiChatFeedbackForm__SubmitButton",children:"Submit",type:"submit"}),Zne=qB("div",{_id:"aiChatForm__Wrapper"}),Jne=e=>{const{form:t}=dL();return t?Wh.jsx(Zne,{...e}):null},ere=qB("form",{_id:"aiChatForm"}),tre=e=>{const{onSubmit:t,...n}=e,{handleSubmit:r,isSuccess:a}=dL();return a?null:Wh.jsx(ere,{onSubmit:L9(t,r),...n})},nre=qB("button",{_id:"aiChatForm__Close",children:Wh.jsx(jY,{iconKey:"close"})}),rre=e=>{const{onClick:t,...n}=e,{closeForm:r}=dL();return Wh.jsx(nre,{onClick:L9(t,r),...n})},are=qB("div",{_id:"aiChatForm__Header"}),ore=qB("h2",{_id:"aiChatForm__Heading"}),ire=e=>{const{form:t}=dL();return(null==t?void 0:t.heading)?Wh.jsx(ore,{children:t.heading,...e}):null},sre=qB(N9,{_id:"aiChatForm__Description"}),lre=e=>{const{form:t}=dL();return(null==t?void 0:t.description)?Wh.jsx(sre,{children:t.description,...e}):null},cre=qB("div",{_id:"aiChatForm__Content"}),ure=e=>{const{children:t,...n}=e,{fields:r=[]}=dL();return Wh.jsx(cre,{children:CL(t,r),...n})},dre=qB("div",{_id:"aiChatForm__Field"}),pre=e=>{const{field:t,autoFocus:n,...r}=e,{control:a,errors:o}=dL();return Wh.jsx(kD,{name:t.name,control:a,rules:{required:t.isRequired?`${t.label} is required.`:void 0},render:({field:e})=>{const a=void 0!==e.value||"file"===t.inputType;return Wh.jsx(Qj,{"data-invalid":SL(!!o[t.name]),field:t,fieldProps:e,autoFocus:n,children:a&&Wh.jsx(dre,{"data-input-type":t.inputType,"data-hidden":SL(t.isHidden),...r})})}})},hre=qB("label",{_id:"aiChatForm__FieldLabel"}),fre=e=>{const{field:t}=Zj();return Wh.jsx(hre,{"data-required":SL(t.isRequired),htmlFor:t.name,children:t.label,...e})},mre=qB("input",{_id:"aiChatForm__FieldText",type:"text"}),gre=e=>{const{field:t,error:n,fieldProps:{onChange:r,onBlur:a,...o},autoFocus:i}=Zj(),{onChange:s,onBlur:l,...c}=e;return Wh.jsx(mre,{id:t.name,autoFocus:i,placeholder:"placeholder"in t?t.placeholder:void 0,"data-invalid":SL(!!n),onChange:L9(s,r),onBlur:L9(l,a),...o,...c})},yre=qB(gre,{_id:"aiChatForm__FieldEmail",type:"email"}),bre=qB("input",{_id:"aiChatForm__FieldFile",type:"file",multiple:!0}),vre=e=>{const{field:t,error:n,fieldProps:{value:r,onChange:a,onBlur:o,...i},autoFocus:s}=Zj(),{onChange:l,onBlur:c,...u}=e;return Wh.jsx(bre,{id:t.name,autoFocus:s,"data-value":r,"data-invalid":SL(!!n),...u,...i,onChange:L9(l,(e=>{const t=e.target.files;a(t)})),onBlur:L9(c,o)})},kre=qB(gre,{_id:"aiChatForm__FieldTextArea",type:"textarea",asChild:!0,children:Wh.jsx(lz,{maxRows:8})}),wre=qB(Pz,{_id:"aiChatForm__FieldCheckbox"}),xre=e=>{const{field:t,error:n,fieldProps:r,autoFocus:a}=Zj(),{onCheckedChange:o,...i}=e;return Wh.jsx(wre,{id:t.name,name:t.name,autoFocus:a,"data-invalid":SL(!!n),checked:r.value,onCheckedChange:L9(o,r.onChange),...i})},Ere=qB(Dz,{_id:"aiChatForm__FieldCheckboxIndicator",children:Wh.jsx(R9,{})}),_re=qB(ZV,{_id:"aiChatForm__FieldSelect"}),Sre=qB(JV,{_id:"aiChatForm__FieldSelect__Trigger"}),Tre=qB(eq,{_id:"aiChatForm__FieldSelect__Value"}),Cre=qB(tq,{_id:"aiChatForm__FieldSelect__Icon",asChild:!0,children:Wh.jsx(MY,{iconSettings:{builtIn:"LuChevronDown"}})}),Are=qB(nq,{_id:"aiChatForm__FieldSelect__Content",position:"popper"}),Nre=qB(rq,{_id:"aiChatForm__FieldSelect__Viewport"}),Ire=qB(aq,{_id:"aiChatForm__FieldSelect__Item"}),Rre=qB(oq,{_id:"aiChatForm__FieldSelect__ItemText"}),Ore=qB(iq,{_id:"aiChatForm__FieldSelect__ItemIndicator",asChild:!0,children:Wh.jsx(MY,{iconSettings:{builtIn:"LuCheck"}})}),Pre=qB("span",{_id:"aiChatForm__FieldError"}),Dre=e=>{var t;const{error:n}=Zj();return n?Wh.jsx(Pre,{children:null==(t=n.message)?void 0:t.toString(),...e}):null},Lre=qB("span",{_id:"aiChatForm__Error"}),Mre=e=>{const{formError:t}=dL();return t?Wh.jsx(Lre,{children:t.message,...e}):null},Fre=qB("div",{_id:"aiChatForm__Footer"}),jre=qB("button",{_id:"aiChatForm__Cancel",children:"Cancel",type:"button"}),Bre=e=>{const{onClick:t,...n}=e,{closeForm:r}=dL();return Wh.jsx(jre,{onClick:L9(t,r),...n})},zre=qB("button",{_id:"aiChatForm__Submit",children:"Submit",type:"submit"}),Hre=e=>{const{onClick:t,...n}=e,{isSubmitting:r,form:a}=dL(),o=(null==a?void 0:a.buttons.submit.label)||"Submit";return Wh.jsx(zre,{disabled:r,...n,children:o})},Ure=qB("div",{_id:"aiChatForm__Success"}),$re=e=>{const{isSuccess:t}=dL();return t?Wh.jsx(Ure,{...e}):null},Gre=qB("h2",{_id:"aiChatForm__SuccessHeading"}),Vre=e=>{var t;const{form:n}=dL();return Wh.jsx(Gre,{children:null==(t=null==n?void 0:n.successView)?void 0:t.heading,...e})},qre=qB(N9,{_id:"aiChatForm__SuccessMessage"}),Wre=qB("button",{_id:"aiChatForm__SuccessButton"}),Yre=e=>{var t;const{onClick:n,...r}=e,{form:a,closeForm:o}=dL(),i=null==(t=null==a?void 0:a.successView)?void 0:t.doneButton;if(!i)return null;const s=i.icon&&Wh.jsx(MY,{iconSettings:i.icon}),l=i.label;return Wh.jsx(Wre,{onClick:L9(n,o),children:Wh.jsxs(Wh.Fragment,{children:[s,l]}),...r})},Kre=e=>{const{triggerSelector:t,onTriggerClick:n}=e;K.useEffect((()=>{const e=e=>{var r;const a=e.target;(null==(r=null==a?void 0:a.matches)?void 0:r.call(a,t))&&(null==n||n())};return document.addEventListener("click",e),()=>{document.removeEventListener("click",e)}}),[t,n])};var Xre=()=>{},Qre=e=>"object"==typeof e&&null!==e,Zre=e=>Qre(e)&&9===e.nodeType,Jre=e=>(e=>Qre(e)&&void 0!==e.nodeType)(e)&&11===e.nodeType&&"host"in e;function eae(e){return Zre(e)?e:(e=>Qre(e)&&e===e.window)(e)?e.document:(null==e?void 0:e.ownerDocument)??document}function tae(e){var t;return Jre(e)?tae(e.host):Zre(e)?e.defaultView??window:(e=>Qre(e)&&1===e.nodeType&&"string"==typeof e.nodeName)(e)?(null==(t=e.ownerDocument)?void 0:t.defaultView)??window:window}var nae=new WeakMap;function rae(e){let t;const n=globalThis.requestAnimationFrame((()=>{t=e()}));return()=>{globalThis.cancelAnimationFrame(n),null==t||t()}}var aae=e=>"function"==typeof e;Function.prototype.toString.call(Object);var oae=e=>e();function iae(e){if(!sae(e)||void 0===e)return e;const t=Reflect.ownKeys(e).filter((e=>"string"==typeof e)),n={};for(const r of t){const t=e[r];void 0!==t&&(n[r]=iae(t))}return n}var sae=e=>e&&"object"==typeof e&&e.constructor===Object;function lae(...e){1===e.length?e[0]:e[1],2!==e.length||e[0]}var cae=(e=>(e.NotStarted="Not Started",e.Started="Started",e.Stopped="Stopped",e))(cae||{}),uae="__init__";var dae,pae={props:({props:e})=>({...e,present:!!e.present}),initialState:({prop:e})=>e("present")?"mounted":"unmounted",refs:()=>({node:null,styles:null}),context:({bindable:e})=>({unmountAnimationName:e((()=>({defaultValue:null}))),prevAnimationName:e((()=>({defaultValue:null}))),present:e((()=>({defaultValue:!1}))),initial:e((()=>({sync:!0,defaultValue:!1})))}),exit:["clearInitial","cleanupNode"],watch({track:e,action:t,prop:n}){e([()=>n("present")],(()=>{t(["setInitial","syncPresence"])}))},on:{"NODE.SET":{actions:["setNode","setStyles"]}},states:{mounted:{on:{UNMOUNT:{target:"unmounted",actions:["clearPrevAnimationName","invokeOnExitComplete"]},"UNMOUNT.SUSPEND":{target:"unmountSuspended"}}},unmountSuspended:{effects:["trackAnimationEvents"],on:{MOUNT:{target:"mounted",actions:["setPrevAnimationName"]},UNMOUNT:{target:"unmounted",actions:["clearPrevAnimationName","invokeOnExitComplete"]}}},unmounted:{on:{MOUNT:{target:"mounted",actions:["setPrevAnimationName"]}}}},implementations:{actions:{setInitial:({context:e})=>{e.get("initial")||queueMicrotask((()=>{e.set("initial",!0)}))},clearInitial:({context:e})=>{e.set("initial",!1)},cleanupNode:({refs:e})=>{e.set("node",null),e.set("styles",null)},invokeOnExitComplete:({prop:e})=>{var t;null==(t=e("onExitComplete"))||t()},setNode:({refs:e,event:t})=>{e.set("node",t.node)},setStyles:({refs:e,event:t})=>{var n;e.set("styles",(n=t.node,nae.has(n)||nae.set(n,tae(n).getComputedStyle(n)),nae.get(n)))},syncPresence:({context:e,refs:t,send:n,prop:r})=>{const a=r("present");if(a)return n({type:"MOUNT",src:"presence.changed"});const o=t.get("node");if(!a&&"hidden"===(null==o?void 0:o.ownerDocument.visibilityState))return n({type:"UNMOUNT",src:"visibilitychange"});rae((()=>{var r,a;const o=hae(t.get("styles"));e.set("unmountAnimationName",o),"none"===o||o===e.get("prevAnimationName")||"none"===(null==(r=t.get("styles"))?void 0:r.display)||"0s"===(null==(a=t.get("styles"))?void 0:a.animationDuration)?n({type:"UNMOUNT",src:"presence.changed"}):n({type:"UNMOUNT.SUSPEND"})}))},setPrevAnimationName:({context:e,refs:t})=>{rae((()=>{e.set("prevAnimationName",hae(t.get("styles")))}))},clearPrevAnimationName:({context:e})=>{e.set("prevAnimationName",null)}},effects:{trackAnimationEvents:({context:e,refs:t,send:n})=>{const r=t.get("node");if(!r)return;const a=n=>{var a,o;((null==(o=null==(a=n.composedPath)?void 0:a.call(n))?void 0:o[0])??n.target)===r&&e.set("prevAnimationName",hae(t.get("styles")))},o=a=>{const o=hae(t.get("styles")),i=function(e){const t=function(e){var t,n,r;return(null==(t=e.composedPath)?void 0:t.call(e))??(null==(r=null==(n=e.nativeEvent)?void 0:n.composedPath)?void 0:r.call(n))}(e);return(null==t?void 0:t[0])??e.target}(a);i===r&&o===e.get("unmountAnimationName")&&n({type:"UNMOUNT",src:"animationend"})};r.addEventListener("animationstart",a),r.addEventListener("animationcancel",o),r.addEventListener("animationend",o);const i=function(e,t){if(!e)return Xre;const n=Object.keys(t).reduce(((t,n)=>(t[n]=e.style.getPropertyValue(n),t)),{});return Object.assign(e.style,t),()=>{Object.assign(e.style,n),0===e.style.length&&e.removeAttribute("style")}}(r,{animationFillMode:"forwards"});return()=>{r.removeEventListener("animationstart",a),r.removeEventListener("animationcancel",o),r.removeEventListener("animationend",o),function(e){const t=new Set;function n(e){const n=globalThis.requestAnimationFrame(e);t.add((()=>globalThis.cancelAnimationFrame(n)))}n((()=>n(e)))}((()=>i()))}}}}};function hae(e){return(null==e?void 0:e.animationName)||"none"}dae=["onExitComplete","present","immediate"],Array.from(new Set(dae));var fae=void 0!==globalThis.document?K.useLayoutEffect:K.useEffect;function mae(e){const t=e().value??e().defaultValue,n=e().isEqual??Object.is,[r]=K.useState(t),[a,o]=K.useState(r),i=void 0!==e().value,s=K.useRef(a);s.current=i?e().value:a;const l=K.useRef(s.current);fae((()=>{l.current=s.current}),[a,e().value]);return{initial:r,ref:s,get:function(){return i?e().value:a},set(t){(e().sync?se.flushSync:oae)((()=>(t=>{var r,a;const s=l.current,c=aae(t)?t(s):t;e().debug&&console.log(`[bindable > ${e().debug}] setValue`,{next:c,prev:s}),i||o(c),n(c,s)||null==(a=(r=e()).onChange)||a.call(r,c,s)})(t)))},invoke(t,n){var r,a;null==(a=(r=e()).onChange)||a.call(r,t,n)},hash(t){var n,r;return(null==(r=(n=e()).hash)?void 0:r.call(n,t))??String(t)}}}mae.cleanup=e=>{K.useEffect((()=>e),[])},mae.ref=e=>{const t=K.useRef(e);return{get:()=>t.current,set:e=>{t.current=e}}};var gae,yae=(e,t)=>{const n=K.useRef(!1),r=K.useRef(!1);K.useEffect((()=>{if(n.current&&r.current)return t();r.current=!0}),[...(e??[]).map((e=>"function"==typeof e?e():e))]),K.useEffect((()=>(n.current=!0,()=>{n.current=!1})),[])};function bae(e,t={}){var n,r,a,o;const i=K.useMemo((()=>{const{id:e,ids:n,getRootNode:r}=t;return function(e){const t=()=>{var t;return(null==(t=e.getRootNode)?void 0:t.call(e))??document},n=()=>eae(t()),r=()=>function(e){let t=e.activeElement;for(;null==t?void 0:t.shadowRoot;){const e=t.shadowRoot.activeElement;if(e===t)break;t=e}return t}(t());return{...e,getRootNode:t,getDoc:n,getWin:()=>n().defaultView??window,getActiveElement:r,isActiveElement:e=>e===r(),getById:e=>t().getElementById(e)}}({id:e,ids:n,getRootNode:r})}),[t]),s=(...t)=>{e.debug&&console.log(...t)},l=function(e){const t=vae(e);return function(e){return t.current[e]}}((null==(n=e.props)?void 0:n.call(e,{props:iae(t),scope:i}))??t),c=vae(null==(r=e.context)?void 0:r.call(e,{prop:l,bindable:mae,scope:i,flush:kae,getContext:()=>u,getComputed:()=>E,getRefs:()=>y})),u={get(e){var t;return null==(t=c.current)?void 0:t[e].ref.current},set(e,t){var n;null==(n=c.current)||n[e].set(t)},initial(e){var t;return null==(t=c.current)?void 0:t[e].initial},hash(e){var t,n;const r=null==(t=c.current)?void 0:t[e].get();return null==(n=c.current)?void 0:n[e].hash(r)}},d=K.useRef(new Map),p=K.useRef(null),h=K.useRef(null),f=K.useRef({type:""}),m=()=>({...f.current,current:()=>f.current,previous:()=>h.current}),g=()=>({..._,matches:(...e)=>e.includes(_.ref.current),hasTag(t){var n,r;return!!(null==(r=null==(n=e.states[_.ref.current])?void 0:n.tags)?void 0:r.includes(t))}}),y=function(e){const t=K.useRef(e);return{get:e=>t.current[e],set(e,n){t.current[e]=n}}}((null==(a=e.refs)?void 0:a.call(e,{prop:l,context:u}))??{}),b=()=>({state:g(),context:u,event:m(),prop:l,send:C,action:v,guard:k,track:yae,refs:y,computed:E,flush:kae,scope:i,choose:x}),v=t=>{const n=aae(t)?t(b()):t;if(!n)return;const r=n.map((t=>{var n,r;const a=null==(r=null==(n=e.implementations)?void 0:n.actions)?void 0:r[t];return a||lae(`[zag-js] No implementation found for action "${JSON.stringify(t)}"`),a}));for(const e of r)null==e||e(b())},k=t=>{var n,r;return aae(t)?t(b()):null==(r=null==(n=e.implementations)?void 0:n.guards)?void 0:r[t](b())},w=t=>{const n=aae(t)?t(b()):t;if(!n)return;const r=n.map((t=>{var n,r;const a=null==(r=null==(n=e.implementations)?void 0:n.effects)?void 0:r[t];return a||lae(`[zag-js] No implementation found for effect "${JSON.stringify(t)}"`),a})),a=[];for(const e of r){const t=null==e?void 0:e(b());t&&a.push(t)}return()=>a.forEach((e=>null==e?void 0:e()))},x=e=>{return(t=e,t?Array.isArray(t)?t:[t]:[]).find((e=>{let t=!e.guard;return(e=>"string"==typeof e)(e.guard)?t=!!k(e.guard):aae(e.guard)&&(t=e.guard(b())),t}));var t},E=t=>{!function(e,t){if(null==e)throw new Error(t())}(e.computed,(()=>"[zag-js] No computed object found on machine"));return(0,e.computed[t])({context:u,event:m(),prop:l,refs:y,scope:i,computed:E})},_=mae((()=>({defaultValue:e.initialState({prop:l}),onChange(t,n){var r,a,o,i;if(n){const e=d.current.get(n);null==e||e(),d.current.delete(n)}n&&v(null==(r=e.states[n])?void 0:r.exit),v(null==(a=p.current)?void 0:a.actions);const s=w(null==(o=e.states[t])?void 0:o.effects);if(s&&d.current.set(t,s),n===uae){v(e.entry);const t=w(e.effects);t&&d.current.set(uae,t)}v(null==(i=e.states[t])?void 0:i.entry)}}))),S=K.useRef(void 0),T=K.useRef(cae.NotStarted);fae((()=>{queueMicrotask((()=>{const e=T.current===cae.Started;T.current=cae.Started,s(e?"rehydrating...":"initializing...");const t=S.current??_.initial;_.invoke(t,e?_.get():uae)}));const t=d.current,n=_.ref.current;return()=>{s("unmounting..."),S.current=n,T.current=cae.Stopped,t.forEach((e=>null==e?void 0:e())),d.current=new Map,p.current=null,queueMicrotask((()=>{v(e.exit)}))}}),[]);const C=t=>{queueMicrotask((()=>{var n,r;if(T.current!==cae.Started)return;h.current=f.current,f.current=t,s("send",t);let a="ref"in _?_.ref.current:_.get();const o=(null==(n=e.states[a].on)?void 0:n[t.type])??(null==(r=e.on)?void 0:r[t.type]),i=x(o);if(!i)return;p.current=i;const l=i.target??a;s("transition",i);const c=l!==a;c?se.flushSync((()=>_.set(l))):i.reenter&&!c?_.invoke(a,a):v(i.actions??[])}))};return null==(o=e.watch)||o.call(e,b()),{state:g(),send:C,context:u,prop:l,scope:i,refs:y,computed:E,event:m(),getStatus:()=>T.current}}function vae(e){const t=K.useRef(e);return t.current=e,t}function kae(e){queueMicrotask((()=>{se.flushSync((()=>e()))}))}gae=e=>e,new Proxy({},{get:(e,t)=>"style"===t?e=>gae({style:e}).style:gae});const wae=K.forwardRef(((e,t)=>{const{unmountOnExit:n=!1,present:r,onExitComplete:a,children:o,...i}=e,s=function(e){const{state:t,send:n,context:r}=e,a=t.matches("mounted","unmountSuspended");return{skip:!r.get("initial"),present:a,setNode(e){e&&n({type:"NODE.SET",node:e})},unmount(){n({type:"UNMOUNT"})}}}(bae(pae,{present:r,onExitComplete:a}));return!s.present&&n?null:Wh.jsx("div",{hidden:!s.present,"data-state":s.skip?void 0:r?"open":"closed",ref:e=>{s.setNode(e),"function"==typeof t?t(e):t&&(t.current=e)},...i,children:o})}));const xae=qB(wae,{_id:"sidebarChat__Root"}),Eae=({triggerSelector:e})=>{const{isOpen:t,setOpen:n}=LB();return Kre({triggerSelector:e,onTriggerClick:()=>n(!t)}),null},_ae=["position","triggerSelector","minWidth","maxWidth","defaultWidth","defaultOpen","autoCloseThreshold","isOpen","onOpenChange"],Sae=K.forwardRef(((e,t)=>{const[n,r]=function(e,t){const n={},r={...e};for(const a of t)a in e&&(n[a]=e[a],delete r[a]);return[n,r]}(e,_ae),a=(({position:e="right",minWidth:t=250,maxWidth:n=600,defaultWidth:r=420,defaultOpen:a=!1,autoCloseThreshold:o=.7,isOpen:i,onOpenChange:s})=>{const[l,c]=K.useState(Math.min(r,Math.floor((t+n)/2))),[u=a,d]=OB({prop:i,defaultProp:i,onChange:s});return{width:l,setWidth:c,position:e,minWidth:t,maxWidth:n,autoCloseThreshold:o,setOpen:d,isOpen:u}})(n);return Wh.jsxs(DB,{value:a,children:[Wh.jsx(Eae,{triggerSelector:n.triggerSelector||"[data-inkeep-sidebar-chat-trigger]"}),Wh.jsx(xae,{ref:t,present:a.isOpen,"data-sidebar":"","data-position":a.position,"data-open":SL(a.isOpen),style:{"--width":`${a.width}px`},...r})]})})),Tae=qB("div",{_id:"sidebarChat__Resizer"}),Cae=K.forwardRef(((e,t)=>{const{position:n}=LB(),{onMouseDown:r,resizerRef:a}=(()=>{const{width:e,setWidth:t,position:n,minWidth:r,maxWidth:a,autoCloseThreshold:o,setOpen:i}=LB(),s=K.useRef(null),l=K.useRef(!1),c=K.useRef(0),u=K.useRef(0),d=r*o;K.useEffect((()=>{const e=e=>{if(!l.current)return;const o=e.clientX-c.current,s="right"===n?-o:o,p=u.current+s;if(p<d)return void i(!1);const h=Math.max(r,Math.min(a,p));t(h)},o=()=>{l.current=!1,document.body.style.cursor="",document.body.style.userSelect=""};return window.addEventListener("mousemove",e),window.addEventListener("mouseup",o),()=>{window.removeEventListener("mousemove",e),window.removeEventListener("mouseup",o)}}),[t,n,r,a,d,i]);const p=K.useCallback((t=>{l.current=!0,c.current=t.clientX,u.current=e,document.body.style.cursor="ew-resize",document.body.style.userSelect="none",t.preventDefault()}),[e]);return{onMouseDown:p,resizerRef:s}})();return Wh.jsx(Tae,{ref:e=>{"function"==typeof t?t(e):t&&(t.current=e),a.current=e},"data-position":n,onMouseDown:r,...e})})),Aae=qB("div",{_id:"sidebarChat__Header"}),Nae=K.forwardRef(((e,t)=>Wh.jsx(Aae,{ref:t,...e}))),Iae=qB("button",{_id:"sidebarChat__CloseButton",children:Wh.jsx(MY,{iconSettings:{builtIn:"IoCloseOutline"}})}),Rae=K.forwardRef(((e,t)=>{const{setOpen:n}=LB();return Wh.jsx(Iae,{ref:t,onClick:()=>{n(!1)},...e})}));var Oae=.999,Pae=/[\\\/_+.#"@\[\(\{&]/,Dae=/[\\\/_+.#"@\[\(\{&]/g,Lae=/[\s-]/,Mae=/[\s-]/g;function Fae(e,t,n,r,a,o,i){if(o===t.length)return a===e.length?1:.99;var s=`${a},${o}`;if(void 0!==i[s])return i[s];for(var l,c,u,d,p=r.charAt(o),h=n.indexOf(p,a),f=0;h>=0;)(l=Fae(e,t,n,r,h+1,o+1,i))>f&&(h===a?l*=1:Pae.test(e.charAt(h-1))?(l*=.8,(u=e.slice(a,h-1).match(Dae))&&a>0&&(l*=Math.pow(Oae,u.length))):Lae.test(e.charAt(h-1))?(l*=.9,(d=e.slice(a,h-1).match(Mae))&&a>0&&(l*=Math.pow(Oae,d.length))):(l*=.17,a>0&&(l*=Math.pow(Oae,h-a))),e.charAt(h)!==t.charAt(o)&&(l*=.9999)),(l<.1&&n.charAt(h-1)===r.charAt(o+1)||r.charAt(o+1)===r.charAt(o)&&n.charAt(h-1)!==r.charAt(o))&&.1*(c=Fae(e,t,n,r,h+1,o+2,i))>l&&(l=.1*c),l>f&&(f=l),h=n.indexOf(p,h+1);return i[s]=f,f}function jae(e){return e.toLowerCase().replace(Mae," ")}function Bae(e,t,n){return Fae(e=n&&n.length>0?""+(e+" "+n.join(" ")):e,t,jae(e),jae(t),0,0,{})}var zae={exports:{}},Hae={},Uae=K;var $ae="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},Gae=Uae.useState,Vae=Uae.useEffect,qae=Uae.useLayoutEffect,Wae=Uae.useDebugValue;function Yae(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!$ae(e,n)}catch(r){return!0}}var Kae="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var n=t(),r=Gae({inst:{value:n,getSnapshot:t}}),a=r[0].inst,o=r[1];return qae((function(){a.value=n,a.getSnapshot=t,Yae(a)&&o({inst:a})}),[e,n,t]),Vae((function(){return Yae(a)&&o({inst:a}),e((function(){Yae(a)&&o({inst:a})}))}),[e]),Wae(n),n};Hae.useSyncExternalStore=void 0!==Uae.useSyncExternalStore?Uae.useSyncExternalStore:Kae,zae.exports=Hae;var Xae=zae.exports;const Qae="__ask_ai__",Zae='[cmdk-group=""]',Jae='[cmdk-group-items=""]',eoe='[cmdk-item=""]',toe=`${eoe}:not([aria-disabled="true"])`,noe="cmdk-item-select",roe="data-value",aoe=(e,t,n)=>Bae(e,t,n??[]),ooe=K.createContext(void 0),ioe=()=>K.useContext(ooe),soe=K.createContext(void 0),loe=()=>K.useContext(soe),coe=K.createContext(void 0),uoe=K.forwardRef(((e,t)=>{const n=_oe((()=>new Set)),r=_oe((()=>new Map)),a=_oe((()=>new Map)),o=_oe((()=>new Set)),i=xoe(e),{label:s,children:l,value:c,onValueChange:u,filter:d,shouldFilter:p,loop:h,disablePointerSelection:f=!1,vimBindings:m=!0,defaultSearch:g,...y}=e,b=_oe((()=>({search:g??"",value:e.value??e.defaultValue??"",selectedItemId:void 0,filtered:{count:0,items:new Map,groups:new Set}}))),v=zO(),k=zO(),w=zO(),x=K.useRef(null),E=Aoe();Eoe((()=>{if(void 0!==c){const e=c.trim();b.current.value=e,S.emit()}}),[c]),Eoe((()=>{E(6,R)}),[]);const _=UO(),S=K.useMemo((()=>({subscribe:e=>(o.current.add(e),()=>o.current.delete(e)),snapshot:()=>b.current,setState:(e,t,n)=>{var r,a,o,s,l;if(!Object.is(b.current[e],t)){if(b.current[e]=t,"search"===e)I(),A(),E(1,N);else if("value"===e){const e=null==(a=null==(r=null==_?void 0:_.shadowHost)?void 0:r.shadowRoot)?void 0:a.activeElement;if((null==e?void 0:e.hasAttribute("cmdk-input"))||E(1,(()=>{const e=O();null==e||e.focus()})),E(7,(()=>{var e;b.current.selectedItemId=null==(e=O())?void 0:e.id,S.emit()})),n||E(5,R),void 0!==(null==(o=i.current)?void 0:o.value)){const e=t??"";return void(null==(l=(s=i.current).onValueChange)||l.call(s,e))}}S.emit()}},emit:()=>{o.current.forEach((e=>e()))}})),[]),T=K.useMemo((()=>({value:(e,t,n)=>{var r;t!==(null==(r=a.current.get(e))?void 0:r.value)&&(a.current.set(e,{value:t,keywords:n}),b.current.filtered.items.set(e,C(t,n)),E(2,(()=>{A(),S.emit()})))},item:(e,t)=>{var o,i;return n.current.add(e),t&&(r.current.has(t)?null==(i=null==(o=r.current)?void 0:o.get(t))||i.add(e):r.current.set(t,new Set([e]))),E(3,(()=>{I(),A(),b.current.value||N(),S.emit()})),()=>{a.current.delete(e),n.current.delete(e),b.current.filtered.items.delete(e);const t=O();E(4,(()=>{I(),(null==t?void 0:t.getAttribute("id"))===e&&N(),S.emit()}))}},group:e=>(r.current.has(e)||r.current.set(e,new Set),()=>{a.current.delete(e),r.current.delete(e)}),filter:()=>!!i.current.shouldFilter,label:s||e["aria-label"]||"",getDisablePointerSelection:()=>!!i.current.disablePointerSelection,listId:v,inputId:w,labelId:k,listInnerRef:x})),[]);function C(e,t){var n;const r=(null==(n=i.current)?void 0:n.filter)??aoe;return e?null==r?void 0:r(e,b.current.search,t):0}function A(){if(!b.current.search||!1===i.current.shouldFilter)return;const e=b.current.filtered.items,t=[];b.current.filtered.groups.forEach((n=>{const a=r.current.get(n);let o=0;a.forEach((t=>{const n=e.get(t);o=Math.max(n,o)})),t.push([n,o])}));const n=x.current;P().sort(((t,n)=>{const r=t.getAttribute("id"),a=n.getAttribute("id");return(e.get(a)??0)-(e.get(r)??0)})).forEach((e=>{const t=e.closest(Jae);if(t){const n=e.parentElement===t?e:e.closest(`${Jae} > *`);n&&t.appendChild(n)}else{const t=e.parentElement===n?e:e.closest(`${Jae} > *`);t&&(null==n||n.appendChild(t))}})),t.sort(((e,t)=>t[1]-e[1])).forEach((e=>{var t,n;const r=null==(t=x.current)?void 0:t.querySelector(`${Zae}[${roe}="${encodeURIComponent(e[0])}"]`);null==(n=null==r?void 0:r.parentElement)||n.appendChild(r)}))}function N(){const e=P().find((e=>"true"!==e.getAttribute("aria-disabled")&&e.getAttribute("data-value")!==Qae)),t=null==e?void 0:e.getAttribute(roe);S.setState("value",t||void 0)}function I(){var e,t;if(!b.current.search||!1===i.current.shouldFilter)return void(b.current.filtered.count=n.current.size);b.current.filtered.groups=new Set;let o=0;for(const r of n.current){const n=C((null==(e=a.current.get(r))?void 0:e.value)??"",(null==(t=a.current.get(r))?void 0:t.keywords)??[]);b.current.filtered.items.set(r,n),n>0&&o++}for(const[n,a]of r.current)for(const e of a){const t=b.current.filtered.items.get(e);if(t&&t>0){b.current.filtered.groups.add(n);break}}b.current.filtered.count=o}function R(){var e,t,n;const r=O();r&&((null==(e=r.parentElement)?void 0:e.firstChild)===r&&(null==(n=null==(t=r.closest(Zae))?void 0:t.querySelector('[cmdk-group-heading=""]'))||n.scrollIntoView({block:"nearest"})),r.scrollIntoView({block:"nearest"}))}function O(){var e;return null==(e=x.current)?void 0:e.querySelector(`${eoe}[aria-selected="true"]`)}function P(){var e;return Array.from((null==(e=x.current)?void 0:e.querySelectorAll(toe))||[])}function D(e){const t=P()[e];t&&S.setState("value",t.getAttribute(roe))}function L(e){var t;const n=O(),r=P(),a=r.findIndex((e=>e===n));let o=r[a+e];(null==(t=i.current)?void 0:t.loop)&&(o=a+e<0?r[r.length-1]:a+e===r.length?r[0]:r[a+e]),o&&S.setState("value",o.getAttribute(roe))}function M(e){const t=O();let n,r=null==t?void 0:t.closest(Zae);for(;r&&!n;)r=e>0?koe(r,Zae):woe(r,Zae),n=null==r?void 0:r.querySelector(toe);n?S.setState("value",n.getAttribute(roe)):L(e)}const F=e=>{e.preventDefault(),e.metaKey?D(P().length-1):e.altKey?M(1):L(1)},j=e=>{e.preventDefault(),e.metaKey?D(0):e.altKey?M(-1):L(-1)},B=fL();return Wh.jsxs(eG.div,{ref:t,tabIndex:-1,...y,"cmdk-root":"",onKeyDown:e=>{var t;if("search"===(null==B?void 0:B.view)&&(null==(t=y.onKeyDown)||t.call(y,e),!e.defaultPrevented))switch(e.key){case"n":case"j":m&&e.ctrlKey&&F(e);break;case"ArrowDown":F(e);break;case"p":case"k":m&&e.ctrlKey&&j(e);break;case"ArrowUp":j(e);break;case"Enter":if(!e.nativeEvent.isComposing&&229!==e.keyCode){e.preventDefault();const t=O();if(t){const e=new Event(noe);t.dispatchEvent(e)}}}},style:{display:"contents"},children:[Wh.jsx("label",{"cmdk-label":"",htmlFor:T.inputId,id:T.labelId,style:Ioe,children:s}),Noe(e,(e=>Wh.jsx(soe.Provider,{value:S,children:Wh.jsx(ooe.Provider,{value:T,children:e})})))]})})),doe=K.forwardRef(((e,t)=>{var n;const{id:r}=e,a=K.useRef(null),o=K.useContext(coe),i=ioe(),s=xoe(e),l=(null==(n=s.current)?void 0:n.forceMount)??(null==o?void 0:o.forceMount);Eoe((()=>{if(!l)return i.item(r,null==o?void 0:o.id)}),[l]);const c=Coe(r,a,[e.value,e.children,a],e.keywords),u=loe(),d=Toe((e=>e.value&&e.value===c.current)),p=Toe((e=>!!l||(!1===i.filter()||(!e.search||e.filtered.items.get(r)>0))));K.useEffect((()=>{const t=a.current;if(!t||e.disabled)return;const n=()=>f("keyboard");return t.addEventListener(noe,n),()=>t.removeEventListener(noe,n)}),[p,e.onSelect,e.disabled]);const h=K.useCallback((()=>{u.setState("value",c.current,!0)}),[u,c]),f=K.useCallback(((e="click")=>{var t,n;h(),null==(n=(t=s.current).onSelect)||n.call(t,{value:c.current,trigger:e})}),[h,s,c]);if(!p)return null;const{disabled:m,value:g,onSelect:y,forceMount:b,keywords:v,onClick:k,...w}=e,x=K.useMemo((()=>Soe([a,t])),[a,t]),E=L9(k,f);return Wh.jsx(eG.div,{ref:x,...w,id:r,"cmdk-item":"",role:"option","aria-disabled":Boolean(m),"aria-selected":Boolean(d),"data-disabled":Boolean(m),"data-selected":Boolean(d),onPointerMove:m||i.getDisablePointerSelection()?void 0:h,onClick:m?void 0:E,onFocus:m?void 0:h,children:e.children})})),poe=K.forwardRef(((e,t)=>{const{heading:n,children:r,forceMount:a,...o}=e,i=zO(),s=K.useRef(null),l=K.useRef(null),c=zO(),u=ioe(),d=Toe((e=>!!a||(!1===u.filter()||(!e.search||e.filtered.groups.has(i)))));Eoe((()=>u.group(i)),[]),Coe(i,s,[e.value,e.heading,l]);const p=K.useMemo((()=>({id:i,forceMount:a})),[a]);return Wh.jsxs(eG.div,{ref:Soe([s,t]),...o,"cmdk-group":"",role:"presentation",hidden:!d||void 0,children:[n&&Wh.jsx("div",{ref:l,"cmdk-group-heading":"","aria-hidden":!0,id:c,children:n}),Noe(e,(e=>Wh.jsx("div",{"cmdk-group-items":"",role:"group","aria-labelledby":n?c:void 0,children:Wh.jsx(coe.Provider,{value:p,children:e})})))]})})),hoe=K.forwardRef(((e,t)=>{const{alwaysRender:n,...r}=e,a=K.useRef(null),o=Toe((e=>!e.search));return n||o?Wh.jsx(eG.div,{ref:Soe([a,t]),...r,"cmdk-separator":"",role:"separator"}):null})),foe=K.forwardRef(((e,t)=>{const{onValueChange:n,...r}=e,a=null!=e.value,o=loe(),i=Toe((e=>e.search)),s=ioe();return K.useEffect((()=>{null!=e.value&&o.setState("search",e.value)}),[e.value]),Wh.jsx(eG.input,{ref:t,...r,"cmdk-input":"",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list",role:"combobox","aria-expanded":!0,"aria-controls":s.listId,"aria-labelledby":s.labelId,id:s.inputId,type:"text",value:a?e.value:i,onChange:e=>{a||o.setState("search",e.target.value),null==n||n(e.target.value)}})})),moe=K.forwardRef(((e,t)=>{const{children:n,label:r="Suggestions",...a}=e,o=K.useRef(null),i=K.useRef(null),s=ioe();return K.useEffect((()=>{if(i.current&&o.current){const e=i.current,t=o.current;let n;const r=new ResizeObserver((()=>{n=requestAnimationFrame((()=>{const n=e.offsetHeight;t.style.setProperty("--cmdk-list-height",n.toFixed(1)+"px")}))}));return r.observe(e),()=>{cancelAnimationFrame(n),r.unobserve(e)}}}),[]),Wh.jsx(eG.div,{ref:Soe([o,t]),...a,"cmdk-list":"",tabIndex:-1,"aria-label":r,id:s.listId,children:Noe(e,(e=>Wh.jsx("div",{ref:Soe([i,s.listInnerRef]),"cmdk-list-sizer":"",children:e})))})})),goe=K.forwardRef(((e,t)=>{const{open:n,onOpenChange:r,overlayClassName:a,contentClassName:o,container:i,...s}=e;return Wh.jsx(lW,{open:n,onOpenChange:r,children:Wh.jsxs(cW,{container:i,children:[Wh.jsx(uW,{"cmdk-overlay":"",className:a}),Wh.jsx(dW,{"aria-label":e.label,"cmdk-dialog":"",className:o,children:Wh.jsx(uoe,{ref:t,...s})})]})})})),yoe=K.forwardRef(((e,t)=>Toe((e=>0===e.filtered.count))?Wh.jsx(eG.div,{ref:t,...e,"cmdk-empty":"",role:"presentation"}):null)),boe=K.forwardRef(((e,t)=>{const{progress:n,children:r,label:a="Loading...",...o}=e;return Wh.jsx(eG.div,{ref:t,...o,"cmdk-loading":"",role:"progressbar","aria-valuenow":n,"aria-valuemin":0,"aria-valuemax":100,"aria-label":a,children:Noe(e,(e=>Wh.jsx("div",{"aria-hidden":!0,children:e})))})})),voe=Object.assign(uoe,{List:moe,Item:doe,Input:foe,Group:poe,Separator:hoe,Dialog:goe,Empty:yoe,Loading:boe});function koe(e,t){let n=e.nextElementSibling;for(;n;){if(n.matches(t))return n;n=n.nextElementSibling}}function woe(e,t){let n=e.previousElementSibling;for(;n;){if(n.matches(t))return n;n=n.previousElementSibling}}function xoe(e){const t=K.useRef(e);return Eoe((()=>{t.current=e})),t}const Eoe="undefined"==typeof window?K.useEffect:K.useLayoutEffect;function _oe(e){const t=K.useRef(void 0);return void 0===t.current&&(t.current=e()),t}function Soe(e){return t=>{e.forEach((e=>{"function"==typeof e?e(t):null!=e&&(e.current=t)}))}}function Toe(e){const t=loe(),n=()=>e(t.snapshot());return Xae.useSyncExternalStore(t.subscribe,n,n)}function Coe(e,t,n,r=[]){const a=K.useRef(void 0),o=ioe();return Eoe((()=>{var i;const s=(()=>{var e;for(const t of n){if("string"==typeof t)return t.trim();if("object"==typeof t&&"current"in t)return t.current?null==(e=t.current.textContent)?void 0:e.trim():a.current}})(),l=r.map((e=>e.trim()));o.value(e,s,l),null==(i=t.current)||i.setAttribute(roe,s),a.current=s})),a}const Aoe=()=>{const[e,t]=K.useState(),n=_oe((()=>new Map));return Eoe((()=>{n.current.forEach((e=>e())),n.current=new Map}),[e]),(e,r)=>{n.current.set(e,r),t({})}};function Noe({asChild:e,children:t},n){return e&&K.isValidElement(t)?K.cloneElement(function(e){const t=e.type;return"function"==typeof t?t(e.props):"render"in t?t.render(e.props):e}(t),{ref:t.ref},n(t.props.children)):n(t)}const Ioe={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"},Roe=e=>{var t,n,r;switch(e.rootRecord.__typename){case"DocumentationRecord":{const a=Poe((null==(n=null==(t=e.pathHeadings)?void 0:t.at(-1))?void 0:n.content)||""),o=Poe((null==(r=e.content)?void 0:r.content)||"");return e.preview||o||a}case"GitHubIssueRecord":case"StackOverflowRecord":case"DiscourseRecord":return e.rootRecord.body;default:return e.preview}},Ooe=e=>{switch(e.rootRecord.__typename){case"StackOverflowRecord":return e.rootRecord.markedAsCorrectAnswer?"Resolved":void 0;case"GitHubIssueRecord":return"CLOSED"===e.rootRecord.state?"Closed":void 0}},Poe=e=>e.replace(/(https?:\/\/\S+)/g,(e=>{const t=e.split("/");return t.length>3?`...${t.slice(-2).join("/")}`:e})),Doe=e=>{switch(e){case"DocumentationRecord":return"documentation";case"GitHubIssueRecord":return"github_issue";case"DiscourseRecord":return"discourse";case"DiscordRecord":return"discord";case"StackOverflowRecord":return"stackoverflow";case"SlackEntry":return"slack_message";default:return"site"}};const Loe=()=>{const{searchSettings:e}=nP(),{tabs:t,searchFunctionsRef:n}=e,[r,a]=K.useState(!1),o=K.useRef(null),[i,s]=K.useState(!1),l=(null==t?void 0:t.length)?"string"==typeof t[0]?t[0]:t[0][0]:"All",[c,u]=K.useState(l),[d,p]=K.useState([]),h=(e=>{const{baseSettings:{transformSource:t,organizationDisplayName:n},searchSettings:{tabs:r,shouldOpenLinksInNewTab:a}}=nP();return K.useMemo((()=>{var o;const i=r.length>0?r:["All"],s={},l=new Set,c=i.map((e=>"string"==typeof e?e:e[0]));for(const e of c)s[e]=[];for(const u of e){const e=u.url||"";if(l.has(e))continue;l.add(e);const o=X9({title:u.title,url:e,description:Roe(u),type:Doe(u.rootRecord.__typename),tag:Ooe(u),breadcrumbs:u.rootRecord.pathBreadcrumbs??[],contentType:u.rootRecord.contentType},"searchResultItem",{organizationDisplayName:n,tabs:r,transformSource:t}),i={...o,id:u.id,isExternal:void 0!==o.shouldOpenInNewTab?o.shouldOpenInNewTab:a},d=i.tabs||[];for(const t of d){const e="string"==typeof t?t:t[0];c.includes(e)?s[e].push(i):console.warn(`Tab "${e}" found in item but not configured in tabs`)}c.includes("All")&&s.All.push(i)}for(const e of Object.keys(s)){const t=i.find((t=>"string"==typeof t?t===e:t[0]===e)),n="object"==typeof t&&!0===(null==(o=t[1])?void 0:o.isAlwaysVisible);0!==s[e].length||n||delete s[e]}return s}),[e,t,n,r,a])})(d),{disableTransition:f,disabled:m}=function(){const[e,t]=K.useState(!1);K.useEffect((()=>{if(e){const e=setTimeout((()=>t(!1)),0);return()=>clearTimeout(e)}}),[e]);const n=K.useCallback((()=>t(!0)),[]);return{disabled:e,disableTransition:n}}(),g=loe();return K.useImperativeHandle(n,(()=>({updateQuery(e){g.setState("search",e)},focusInput:()=>{var e;null==(e=o.current)||e.focus()}}))),{results:h,resultsList:d,setResultsList:p,hasContent:r&&(d.length>0||i),loading:i,setLoading:s,defaultTab:l,tab:c,setTab:u,disableTransition:f,transitionsDisabled:m,inputRef:o,showSearchResults:r,setShowSearchResults:a}},Moe=K.createContext(void 0),Foe=({children:e})=>{const{logEvent:t}=bP();return Wh.jsx(Moe.Provider,{value:{logEvent:t},children:e})},joe=()=>{const e=K.useContext(Moe);if(!e)throw new Error("useSearchEvents must be used within a SearchEventsProvider");return e},Boe=K.createContext(void 0),zoe=e=>{const{searchSettings:{defaultQuery:t}}=nP();return Wh.jsx(Foe,{children:Wh.jsx(voe,{shouldFilter:!1,loop:!1,defaultSearch:t,children:Wh.jsx(Hoe,{...e})})})},Hoe=({children:e,...t})=>{const n=Loe();return Wh.jsx(Boe.Provider,{value:{...n,...t},children:e})},Uoe=()=>{const e=K.useContext(Boe);if(!e)throw new Error("useSearch must be used within a SearchProvider");return e};var $oe="rovingFocusGroup.onEntryFocus",Goe={bubbles:!1,cancelable:!0},Voe="RovingFocusGroup",[qoe,Woe,Yoe]=function(e){const t=e+"CollectionProvider",[n,r]=j$(t),[a,o]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=e=>{const{scope:t,children:n}=e,r=X.useRef(null),o=X.useRef(new Map).current;return Wh.jsx(a,{scope:t,itemMap:o,collectionRef:r,children:n})};i.displayName=t;const s=e+"CollectionSlot",l=K$(s),c=X.forwardRef(((e,t)=>{const{scope:n,children:r}=e,a=U$(t,o(s,n).collectionRef);return Wh.jsx(l,{ref:a,children:r})}));c.displayName=s;const u=e+"CollectionItemSlot",d="data-radix-collection-item",p=K$(u),h=X.forwardRef(((e,t)=>{const{scope:n,children:r,...a}=e,i=X.useRef(null),s=U$(t,i),l=o(u,n);return X.useEffect((()=>(l.itemMap.set(i,{ref:i,...a}),()=>{l.itemMap.delete(i)}))),Wh.jsx(p,{[d]:"",ref:s,children:r})}));return h.displayName=u,[{Provider:i,Slot:c,ItemSlot:h},function(t){const n=o(e+"CollectionConsumer",t),r=X.useCallback((()=>{const e=n.collectionRef.current;if(!e)return[];const t=Array.from(e.querySelectorAll(`[${d}]`)),r=Array.from(n.itemMap.values()).sort(((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current)));return r}),[n.collectionRef,n.itemMap]);return r},r]}(Voe),[Koe,Xoe]=j$(Voe,[Yoe]),[Qoe,Zoe]=Koe(Voe),Joe=K.forwardRef(((e,t)=>Wh.jsx(qoe.Provider,{scope:e.__scopeRovingFocusGroup,children:Wh.jsx(qoe.Slot,{scope:e.__scopeRovingFocusGroup,children:Wh.jsx(eie,{...e,ref:t})})})));Joe.displayName=Voe;var eie=K.forwardRef(((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:a=!1,dir:o,currentTabStopId:i,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:l,onEntryFocus:c,preventScrollOnEntryFocus:u=!1,...d}=e,p=K.useRef(null),h=U$(t,p),f=Y$(o),[m=null,g]=OB({prop:i,defaultProp:s,onChange:l}),[y,b]=K.useState(!1),v=RB(c),k=Woe(n),w=K.useRef(!1),[x,E]=K.useState(0);return K.useEffect((()=>{const e=p.current;if(e)return e.addEventListener($oe,v),()=>e.removeEventListener($oe,v)}),[v]),Wh.jsx(Qoe,{scope:n,orientation:r,dir:f,loop:a,currentTabStopId:m,onItemFocus:K.useCallback((e=>g(e)),[g]),onItemShiftTab:K.useCallback((()=>b(!0)),[]),onFocusableItemAdd:K.useCallback((()=>E((e=>e+1))),[]),onFocusableItemRemove:K.useCallback((()=>E((e=>e-1))),[]),children:Wh.jsx(eG.div,{tabIndex:y||0===x?-1:0,"data-orientation":r,...d,ref:h,style:{outline:"none",...e.style},onMouseDown:F$(e.onMouseDown,(()=>{w.current=!0})),onFocus:F$(e.onFocus,(e=>{const t=!w.current;if(e.target===e.currentTarget&&t&&!y){const t=new CustomEvent($oe,Goe);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){const e=k().filter((e=>e.focusable));aie([e.find((e=>e.active)),e.find((e=>e.id===m)),...e].filter(Boolean).map((e=>e.ref.current)),u)}}w.current=!1})),onBlur:F$(e.onBlur,(()=>b(!1)))})})})),tie="RovingFocusGroupItem",nie=K.forwardRef(((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:a=!1,tabStopId:o,...i}=e,s=zO(),l=o||s,c=Zoe(tie,n),u=c.currentTabStopId===l,d=Woe(n),{onFocusableItemAdd:p,onFocusableItemRemove:h}=c;return K.useEffect((()=>{if(r)return p(),()=>h()}),[r,p,h]),Wh.jsx(qoe.ItemSlot,{scope:n,id:l,focusable:r,active:a,children:Wh.jsx(eG.span,{tabIndex:u?0:-1,"data-orientation":c.orientation,...i,ref:t,onMouseDown:F$(e.onMouseDown,(e=>{r?c.onItemFocus(l):e.preventDefault()})),onFocus:F$(e.onFocus,(()=>c.onItemFocus(l))),onKeyDown:F$(e.onKeyDown,(e=>{if("Tab"===e.key&&e.shiftKey)return void c.onItemShiftTab();if(e.target!==e.currentTarget)return;const t=function(e,t,n){const r=function(e,t){return"rtl"!==t?e:"ArrowLeft"===e?"ArrowRight":"ArrowRight"===e?"ArrowLeft":e}(e.key,n);return"vertical"===t&&["ArrowLeft","ArrowRight"].includes(r)||"horizontal"===t&&["ArrowUp","ArrowDown"].includes(r)?void 0:rie[r]}(e,c.orientation,c.dir);if(void 0!==t){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let a=d().filter((e=>e.focusable)).map((e=>e.ref.current));if("last"===t)a.reverse();else if("prev"===t||"next"===t){"prev"===t&&a.reverse();const o=a.indexOf(e.currentTarget);a=c.loop?(r=o+1,(n=a).map(((e,t)=>n[(r+t)%n.length]))):a.slice(o+1)}setTimeout((()=>aie(a)))}var n,r}))})})}));nie.displayName=tie;var rie={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function aie(e,t=!1){const n=document.activeElement;for(const r of e){if(r===n)return;if(r.focus({preventScroll:t}),document.activeElement!==n)return}}var oie=Joe,iie=nie,sie="Tabs",[lie,cie]=j$(sie,[Xoe]),uie=Xoe(),[die,pie]=lie(sie),hie=K.forwardRef(((e,t)=>{const{__scopeTabs:n,value:r,onValueChange:a,defaultValue:o,orientation:i="horizontal",dir:s,activationMode:l="automatic",...c}=e,u=Y$(s),[d,p]=OB({prop:r,onChange:a,defaultProp:o});return Wh.jsx(die,{scope:n,baseId:zO(),value:d,onValueChange:p,orientation:i,dir:u,activationMode:l,children:Wh.jsx(eG.div,{dir:u,"data-orientation":i,...c,ref:t})})}));hie.displayName=sie;var fie="TabsList",mie=K.forwardRef(((e,t)=>{const{__scopeTabs:n,loop:r=!0,...a}=e,o=pie(fie,n),i=uie(n);return Wh.jsx(oie,{asChild:!0,...i,orientation:o.orientation,dir:o.dir,loop:r,children:Wh.jsx(eG.div,{role:"tablist","aria-orientation":o.orientation,...a,ref:t})})}));mie.displayName=fie;var gie="TabsTrigger",yie=K.forwardRef(((e,t)=>{const{__scopeTabs:n,value:r,disabled:a=!1,...o}=e,i=pie(gie,n),s=uie(n),l=kie(i.baseId,r),c=wie(i.baseId,r),u=r===i.value;return Wh.jsx(iie,{asChild:!0,...s,focusable:!a,active:u,children:Wh.jsx(eG.button,{type:"button",role:"tab","aria-selected":u,"aria-controls":c,"data-state":u?"active":"inactive","data-disabled":a?"":void 0,disabled:a,id:l,...o,ref:t,onMouseDown:F$(e.onMouseDown,(e=>{a||0!==e.button||!1!==e.ctrlKey?e.preventDefault():i.onValueChange(r)})),onKeyDown:F$(e.onKeyDown,(e=>{[" ","Enter"].includes(e.key)&&i.onValueChange(r)})),onFocus:F$(e.onFocus,(()=>{const e="manual"!==i.activationMode;u||a||!e||i.onValueChange(r)}))})})}));yie.displayName=gie;var bie="TabsContent",vie=K.forwardRef(((e,t)=>{const{__scopeTabs:n,value:r,forceMount:a,children:o,...i}=e,s=pie(bie,n),l=kie(s.baseId,r),c=wie(s.baseId,r),u=r===s.value,d=K.useRef(u);return K.useEffect((()=>{const e=requestAnimationFrame((()=>d.current=!1));return()=>cancelAnimationFrame(e)}),[]),Wh.jsx(Pq,{present:a||u,children:({present:n})=>Wh.jsx(eG.div,{"data-state":u?"active":"inactive","data-orientation":s.orientation,role:"tabpanel","aria-labelledby":l,hidden:!n,id:c,tabIndex:0,...i,ref:t,style:{...e.style,animationDuration:d.current?"0s":void 0},children:n&&o})})}));function kie(e,t){return`${e}-trigger-${t}`}function wie(e,t){return`${e}-content-${t}`}vie.displayName=bie;var xie=hie,Eie=mie,_ie=yie,Sie=vie;const Tie=()=>{const{setResultsList:e,setLoading:t,showSearchResults:n,setShowSearchResults:r}=Uoe(),{baseSettings:a,searchSettings:o}=nP(),{apiKey:i,aiApiBaseUrl:s,userAuthToken:l,filters:c}=a,{maxResults:u,debounceTimeMs:d,onQueryChange:p,filters:h}=o,{logEvent:f}=joe(),m=K.useRef({}),g=K.useRef(null),y=K.useRef(null),b=`${s}/graphql`,v=K.useMemo((()=>({Authorization:`Bearer ${i}`,"Content-Type":"application/json",...l?{"User-Token":l}:{}})),[i,l]),k=K.useCallback((async n=>{const r=new AbortController;g.current=r;try{const t=await async function(e,t,n,r,a){var o;try{const i=await fetch(e,{method:"POST",headers:{"Content-Type":"application/json",...r},signal:a,body:JSON.stringify({query:t,variables:n})});if(!i.ok)throw new Error(`Network response was not OK (status: ${i.status})`);const s=await i.json();if(null==(o=s.errors)?void 0:o.length)throw new Error(s.errors[0].message);return s.data}catch(i){if(i instanceof Error&&"AbortError"===i.name)throw i;throw console.warn("Error in graphqlRequest:",i),i}}(b,"query GetSearchResults($searchInput: SearchInput!) {\n search(searchInput: $searchInput) {\n searchHits {\n id\n hitOnRoot\n url\n title\n preview\n\n ... on DocumentationHit {\n rootRecord {\n __typename\n id\n title\n url\n preview\n ... on DocumentationRecord {\n pathBreadcrumbs\n contentType\n topLevelHeadings {\n anchor\n url\n content\n }\n }\n }\n pathHeadings {\n anchor\n content\n }\n content {\n anchor\n content\n }\n }\n\n ... on StackOverflowHit {\n rootRecord {\n __typename\n id\n title\n url\n preview\n ... on StackOverflowRecord {\n body\n createdAt\n\n markedAsCorrectAnswer {\n url\n score\n content\n }\n }\n }\n }\n\n ... on GitHubIssueHit {\n rootRecord {\n __typename\n id\n title\n url\n preview\n ... on GitHubIssueRecord {\n createdAt\n body\n state\n }\n }\n }\n\n ... on DiscourseHit {\n rootRecord {\n __typename\n id\n title\n url\n preview\n ... on DiscourseRecord {\n createdAt\n body\n }\n }\n }\n }\n searchQuery\n }\n}\n",{searchInput:n},v,r.signal),a=null==t?void 0:t.search.searchHits;m.current[n.searchQuery]=a,e(a)}catch(xbe){if("AbortError"===xbe.name)return}finally{t(!1)}}),[b,v]),w=K.useCallback((e=>{const t=m.current[e.searchQuery];f({eventName:"search_query_response_received",properties:{searchQuery:e.searchQuery,totalResults:null==t?void 0:t.length}})}),[]),x=()=>{g.current&&(g.current.abort(),t(!1))},E=K.useCallback((n=>{if(y.current&&window.clearTimeout(y.current),!n.searchQuery)return x(),void e([]);y.current=window.setTimeout((()=>{x(),f({eventName:"search_query_submitted",properties:{searchQuery:n.searchQuery}}),m.current[n.searchQuery]?(e(m.current[n.searchQuery]),w(n)):(t(!0),k(n).then((()=>{w(n)})))}),d)}),[d,k]),_=Toe((e=>e.search)),S=K.useMemo((()=>({searchQuery:_,filters:{...c,...h,limit:u}})),[_,u,c,h]),T=K.useRef(null);K.useEffect((()=>{const e=()=>{null!==T.current&&(window.clearTimeout(T.current),T.current=null)},t=Boolean(_);return t&&!n?(e(),T.current=window.setTimeout((()=>{r(!0)}),400)):!t&&n&&(e(),r(!1)),e}),[_,n,r]),K.useEffect((()=>{null==p||p(S.searchQuery),E(S)}),[E,S])};function Cie(e,t,n){try{const r=new URL(e);return r.searchParams.set(n,t),r.toString()}catch{return e}}const Aie=qB("div",{_id:"aiSearchWrapper"}),Nie=e=>{const{searchSettings:{view:t}}=nP(),{isHidden:n,hasContent:r}=Uoe(),a=mL("(max-width: 768px)"),o=iL();return Wh.jsx(Aie,{"data-hidden":SL(n),"data-has-content":SL(r),"data-in-modal":SL(!!o),"data-mobile":SL(a),"data-view":t,"data-dual-pane-search-expanded":SL(r&&"dual-pane"===t&&!n),...e})},Iie=qB("div",{_id:"aiSearchRoot"}),Rie=e=>{const{isHidden:t}=Uoe(),n=mL("(max-width: 768px)");return Wh.jsx(Iie,{"data-hidden":SL(t),"data-mobile":SL(n),...e})},Oie=qB(voe.List,{_id:"aiSearchContent"}),Pie=K.forwardRef(((e,t)=>{const n=Toe((e=>e.value));return Wh.jsx(Oie,{"aria-activedescendant":`aiSearchResults__Item-${n}`,...e,ref:t})})),Die=qB("div",{_id:"aiSearchInputGroup"}),Lie=qB(jY,{_id:"aiSearchInputIcon",iconKey:"search"}),Mie=qB(voe.Input,{_id:"aiSearchInput"}),Fie=K.forwardRef((({onInput:e,...t},n)=>{const{inputRef:r,shouldAutoFocusInput:a}=Uoe(),o=Toe((e=>e.value)),i=mL("(max-width: 768px)"),{searchSettings:s}=nP(),l=K.useMemo((()=>s.placeholder||(i?"Search...":"Search for anything...")),[s.placeholder,i]),c=BB(n,r);return e7("search",r,a),Tie(),Wh.jsx(Mie,{ref:c,placeholder:l,"aria-activedescendant":`aiSearchResults__Item-${o}`,...t})})),jie=qB(MY,{_id:"aiSearchLoading",iconSettings:{builtIn:"LuLoaderCircle"}}),Bie=e=>{const{loading:t}=Uoe();return t?Wh.jsx(jie,{...e}):null},zie=qB(voe.Item,{_id:"aiAskAITrigger",value:Qae}),Hie=e=>{var t,n;const{results:r,tab:a}=Uoe(),o=loe(),i=(null==(n=null==(t=r[a])?void 0:t[0])?void 0:n.id)??"NONE";return Wh.jsx(zie,{...e,id:`aiSearchResults__Item-${Qae}`,tabIndex:0,onPointerLeave:()=>o.setState("value",i,!0)})},Uie=qB("img",{_id:"aiAskAITrigger__Icon"}),$ie=e=>{const{aiChatSettings:t}=nP(),{aiAssistantAvatar:n}=t??{},r="string"==typeof n?n:null==n?void 0:n.light,a=fB(r,("string"==typeof n?n:null==n?void 0:n.dark)??r),[o,i]=K.useState(a);K.useEffect((()=>{i(a)}),[a]);return Wh.jsx(Uie,{asChild:!0,...e,children:o?Wh.jsx("img",{src:o,alt:"AI Avatar","data-type":"image",onError:L9((()=>{i(null)})),...e}):Wh.jsx(fW,{"data-type":"icon",...e})})},Gie=qB("span",{_id:"aiAskAITrigger__Label"}),Vie=qB("span",{_id:"aiAskAITrigger__Query"}),qie=qB(jY,{_id:"aiAskAITrigger__Indicator",iconKey:"openLinkInSameTab"}),Wie=qB("span",{_id:"aiAskAITrigger__IndicatorText"}),Yie=qB(xie,{_id:"aiSearchResults"}),Kie=e=>{const{searchSettings:{view:t}}=nP(),{tab:n,setTab:r,hasContent:a,isHidden:o,disableTransition:i,results:s,defaultTab:l}=Uoe(),c=loe(),u=K.useCallback((e=>{var t;i(),r(e);const n=s[e][0]?null==(t=s[e][0])?void 0:t.id:void 0;c.setState("value",n,!0)}),[s,i]);return K.useEffect((()=>{var e,t;let a=n in s?n:Object.keys(s)[0];if(!(null==(e=s[a])?void 0:e.length)){const e=Object.keys(s).find((e=>{var t;return null==(t=s[e])?void 0:t.length}));a=e||l}if(!a)return;r(a);const o=null==(t=s[a])?void 0:t[0];o&&c.setState("value",o.id,!0)}),[s]),Wh.jsx(Yie,{value:n,onValueChange:u,"data-has-content":SL(a),"data-dual-pane-search-expanded":SL(a&&"dual-pane"===t&&!o),...e})},Xie=qB("div",{_id:"aiSearchResults__Loading"}),Qie=e=>{const{loading:t,resultsList:n}=Uoe();return!t||n.length>0?null:Wh.jsx(Xie,{...e})},Zie=qB(voe.Empty,{_id:"aiSearchResults__Empty"}),Jie=e=>{var t;const n=Toe((e=>e.search)),{loading:r,results:a,tab:o}=Uoe(),i=null==(t=a[o])?void 0:t.length;return r||!n||i?null:Wh.jsx(Zie,{children:"No results found.",...e})},ese=qB(Eie,{_id:"aiSearchResults__TabList"}),tse=e=>{const{children:t,...n}=e,{searchSettings:{tabs:r}}=nP(),{results:a,loading:o,resultsList:i}=Uoe();if(o&&0===i.length)return null;const s=Object.keys(a);return r.length&&s.length?Wh.jsx(ese,{tabIndex:-1,children:CL(t,s),...n}):null},nse=qB(_ie,{_id:"aiSearchResults__Tab"}),rse=K.forwardRef(((e,t)=>{const n=K.useRef(null),r=BB(t,n),{tab:a,onClick:o,...i}=e,{results:s,tab:l,inputRef:c}=Uoe(),u=s[a].length,d=a===l,p=UO();return K.useEffect((()=>{var e,t,r;if(d){const a=null==(t=null==(e=null==p?void 0:p.shadowHost)?void 0:e.shadowRoot)?void 0:t.activeElement;(null==a?void 0:a.hasAttribute("ikp-tab"))&&(null==(r=n.current)||r.focus())}}),[d]),Wh.jsx(nse,{ref:r,"ikp-tab":"",tabIndex:d?0:-1,value:a,children:`${a} (${u})`,onClick:L9(o,(()=>{var e;null==(e=c.current)||e.focus()})),...i})})),ase=qB("div",{_id:"aiSearchResults__Content"}),ose=qB(P$,{_id:"aiSearchResults__ScrollArea"}),ise=e=>{const{loading:t,resultsList:n}=Uoe();return t&&0===n.length?null:Wh.jsx(ose,{tabIndex:-1,...e})},sse=qB(D$,{_id:"aiSearchResults__ScrollAreaViewport"}),lse=K.forwardRef((({children:e,...t},n)=>{const r=function(){const e=K.useRef(null),t=K.useCallback((()=>{const t=e.current;t&&(0===t.scrollTop?t.setAttribute("data-scroll-top",""):t.removeAttribute("data-scroll-top"),t.scrollTop+t.clientHeight>=t.scrollHeight-1?t.setAttribute("data-scroll-bottom",""):t.removeAttribute("data-scroll-bottom"))}),[]);return K.useEffect((()=>{const n=e.current;if(n)return t(),n.addEventListener("scroll",t),window.addEventListener("resize",t),()=>{n.removeEventListener("scroll",t),window.removeEventListener("resize",t)}}),[t]),e}(),a=BB(n,r),{tab:o}=Uoe();return K.useEffect((()=>{var e;o&&(null==(e=r.current)||e.scrollTo({top:0,behavior:"auto"}))}),[o]),Wh.jsx(sse,{ref:a,tabIndex:-1,children:Wh.jsx("div",{tabIndex:-1,style:{display:"grid"},children:e}),...t})})),cse=qB(l$,{_id:"aiSearchResults__ScrollAreaScrollbar"}),use=qB(v$,{_id:"aiSearchResults__ScrollAreaThumb"}),dse=qB(L$,{_id:"aiSearchResults__ScrollAreaCorner"}),pse=qB(Sie,{_id:"aiSearchResults__List"}),hse=e=>{const{children:t,...n}=e,{results:r,tab:a}=Uoe(),o=r[a]??[];return Wh.jsx(pse,{value:a,"data-has-results":SL(o.length>0),"aria-label":"Search results",children:CL(t,o),tabIndex:-1,...n})},fse=qB(voe.Item,{_id:"aiSearchResults__Item",asChild:!0}),mse=K.forwardRef((({item:e,onClick:t,onSelect:n,children:r,...a},o)=>{var i;const{searchSettings:{shouldOpenLinksInNewTab:s,view:l,searchQueryParamKey:c}}=nP(),{logEvent:u}=joe(),d=Toe((e=>e.search)),{transitionsDisabled:p}=Uoe(),h=Toe((e=>e.value)),f=K.useRef(null),m=iL(),g=BB(o,f),y=K.useCallback((e=>{var t;"keyboard"===e.trigger&&(null==(t=f.current)||t.click())}),[]),b=K.useCallback((t=>{u({eventName:"search_result_clicked",properties:{searchQuery:d,title:e.title,url:e.url}});const n=t.metaKey||t.ctrlKey,r=void 0!==e.shouldOpenInNewTab?e.shouldOpenInNewTab:s;n||r?t.preventDefault():null==m||m.setOpen(!1)}),[u,d,e.title,e.url,e.shouldOpenInNewTab,s,m]),v=K.useMemo((()=>void 0!==e.shouldOpenInNewTab?e.shouldOpenInNewTab:s),[e.shouldOpenInNewTab,s]),k=h===e.id,w=k||("NONE"===h||h===Qae),x=K.useCallback((t=>{const n=t.metaKey||t.ctrlKey,r=void 0!==e.shouldOpenInNewTab?e.shouldOpenInNewTab:s;if(n||r){t.preventDefault();const n=c?Cie(e.url,d,c):e.url;n&&window.open(n,"_blank","noopener")}else null==m||m.setOpen(!1)}),[e.url,e.shouldOpenInNewTab,s,c,d,m]),E=K.useMemo((()=>({href:c?Cie(e.url,d,c):e.url,isExternal:v,appendToUrl:e.appendToUrl,children:r,id:`aiSearchResults__Item-${e.id}`,onClick:x})),[e.url,v,e.appendToUrl,r,e.id,c,d,x]);return Wh.jsx(NB,{source:{...e,isExternal:v},children:Wh.jsx(fse,{ref:g,value:e.id,"data-type":e.type,"data-breadcrumbs":!!(null==(i=e.breadcrumbs)?void 0:i.length),"data-disable-transitions":SL(p),"data-view":l,onSelect:L9(n,y),onClick:L9(t,b),"data-selected":SL(k),tabIndex:w?0:-1,...a,children:Wh.jsx(zY,{...E})})})})),gse=qB("div",{_id:"aiSearchResults__ItemBreadcrumbs"}),yse=e=>{var t,n,r,a;const{source:o}=IB(),{tab:i}=Uoe();if(!(null==(t=o.breadcrumbs)?void 0:t.length))return null;const{children:s,...l}=e,c=(null==(a=null==(r=null==(n=o.tabs)?void 0:n.find((e=>"string"!=typeof e&&e[0]===i)))?void 0:r[1])?void 0:a.breadcrumbs)??o.breadcrumbs??[];return Wh.jsx(gse,{"aria-hidden":"true",children:CL(s,c),...l})},bse=qB(jY,{_id:"aiSearchResults__ItemBreadcrumbIcon",iconKey:"breadcrumbSeparator"}),vse=qB(MY,{_id:"aiSearchResults__ItemIcon"}),kse=e=>{const{source:t}=IB();return Wh.jsx(vse,{iconSettings:t.icon,"data-type":t.type,...e})},wse=qB("span",{_id:"aiSearchResults__ItemTitle"}),xse=e=>{const{source:t}=IB();return Wh.jsx(wse,{"data-type":t.type,children:t.title,...e})},Ese=qB("span",{_id:"aiSearchResults__ItemTag"}),_se=e=>{const{source:t}=IB();return Wh.jsx(Ese,{"data-type":t.type,children:t.tag,...e})},Sse=qB("span",{_id:"aiSearchResults__ItemDescription"}),Tse=e=>{const{source:t}=IB(),{children:n,...r}=e,a=K.useMemo((()=>t.description?D9(t.description):[]),[t.description]);return a.length?Wh.jsx(Sse,{"data-type":t.type,"aria-hidden":"true",children:CL(n,a),...r}):null},Cse=qB("span",{_id:"aiSearchResults__ItemDescriptionPart"}),Ase=e=>{const{part:t,...n}=e,{source:r}=IB();return"string"==typeof t?t:Wh.jsx(Cse,{"data-type":r.type,children:t.content,"data-highlighted":SL(t.highlighted),...n})},Nse=qB(jY,{_id:"aiSearchResults__ItemIndicator"}),Ise=e=>{const{source:t}=IB(),{searchSettings:{view:n}}=nP();return Wh.jsx(Nse,{iconKey:t.isExternal?"openLinkInNewTab":"openLinkInSameTab","data-view":n,...e})},Rse=qB("div",{_id:"aiSearchResults__ItemPreview","aria-hidden":!0}),Ose=e=>{const{searchSettings:{view:t,shouldOpenLinksInNewTab:n}}=nP(),{results:r,tab:a}=Uoe(),o=Toe((e=>e.value)),i=r[a]??[],s=K.useRef(null),l=K.useMemo((()=>{if(o===Qae)return s.current;const e=i.find((e=>e.id===o));return s.current=e??null,e}),[o]);if("dual-pane"!==t||o===Qae)return null;if(!l)return null;const c=void 0!==l.shouldOpenInNewTab?l.shouldOpenInNewTab:n;return Wh.jsx(NB,{source:{...l,isExternal:c},children:Wh.jsx(Rse,{...e})})},Pse=qB("div",{_id:"aiSearchResults__ItemPreview__Header"}),Dse=qB(zY,{_id:"aiSearchResults__ItemPreview__Heading"}),Lse=e=>{const{source:t}=IB();return Wh.jsx(Dse,{href:t.url,isExternal:t.isExternal,appendToUrl:t.appendToUrl,"data-type":t.type,...e})},Mse=qB("span",{_id:"aiSearchResults__ItemPreview__Title"}),Fse=e=>{const{source:t}=IB();return Wh.jsx(Mse,{children:t.title,...e})},jse=qB(jY,{_id:"aiSearchResults__ItemPreview__Title__LinkIcon",iconKey:"openLinkInNewTab"}),Bse=e=>{const{source:t}=IB();return Wh.jsx(jse,{iconKey:t.isExternal?"openLinkInNewTab":"openLinkInSameTab",...e})},zse=qB(yse,{_id:"aiSearchResults__ItemPreview__Breadcrumbs"}),Hse=qB(bse,{_id:"aiSearchResults__ItemPreview__BreadcrumbIcon"}),Use=qB(N9,{_id:"aiSearchResults__ItemPreview__Body"}),$se=e=>{const{source:t}=IB(),{resultsList:n}=Uoe(),r=n.find((e=>e.id===t.id)),{searchSettings:{shouldOpenLinksInNewTab:a}}=nP();return r?Wh.jsx(Use,{shouldOpenLinksInNewTab:a,children:r.preview,...e}):null},Gse=qB("div",{_id:"aiSearchResults__ItemPreview__Outline"}),Vse=e=>{const{source:t}=IB(),{resultsList:n}=Uoe(),r=n.find((e=>e.id===t.id)),a=null==r?void 0:r.rootRecord.topLevelHeadings;return(null==a?void 0:a.length)?Wh.jsx(Gse,{...e}):null},qse=qB("span",{_id:"aiSearchResults__ItemPreview__Outline__Title",children:"On this page"}),Wse=qB("ul",{_id:"aiSearchResults__ItemPreview__Outline__List"}),Yse=e=>{const{source:t}=IB(),{resultsList:n}=Uoe(),r=n.find((e=>e.id===t.id)),a=null==r?void 0:r.rootRecord.topLevelHeadings;if(!(null==a?void 0:a.length))return null;const o=a.map((e=>{var t,n,a;const o=(null==e?void 0:e.anchor)&&(null==e?void 0:e.anchor)===(null==(t=null==r?void 0:r.content)?void 0:t.anchor),i=(null==e?void 0:e.anchor)===(null==(a=null==(n=null==r?void 0:r.pathHeadings)?void 0:n[0])?void 0:a.anchor);return{...e,isMatch:o||i}})),{children:i,...s}=e;return Wh.jsx(Wse,{children:CL(i,o),...s})},Kse=qB(zY,{_id:"aiSearchResults__ItemPreview__Outline__Item"}),Xse=e=>{const{searchSettings:{shouldOpenLinksInNewTab:t}}=nP();return Wh.jsx(Kse,{isExternal:t,...e})},Qse=qB(jY,{_id:"aiSearchResults__ItemPreview__Outline__ItemIcon",iconKey:"newLine"}),Zse=qB("span",{_id:"aiSearchResults__ItemPreview__Outline__ItemText"}),Jse=e=>Wh.jsx(Zse,{...e}),ele=qB(MY,{_id:"aiSearchResults__ItemPreview__Outline__ItemLinkIcon",iconSettings:{builtIn:"LuLink"}}),tle=qB("div",{_id:"aiSearchFooter"}),nle=e=>{const{hasContent:t}=Uoe();return Wh.jsx(tle,{"data-has-results":SL(t),...e})},rle=qB("div",{_id:"aiSearchTagline__Container"}),ale=qB("span",{_id:"aiSearchTagline__Text",children:"Powered by"}),ole=qB(O9,{_id:"aiSearchTagline__Logo"}),ile=qB("a",{_id:"aiSearchTagline__BrandName",children:"inkeep",href:"https://www.inkeep.com/",target:"_blank",rel:"noopener noreferrer"}),sle=qB(lW,{_id:"modal"}),lle=qB(uW,{_id:"modal__Overlay"}),cle=qB(dW,{_id:"modal__Content","aria-describedby":void 0}),ule=e=>{const t=mL("(max-width: 768px)");return Wh.jsx(cle,{"data-mobile":SL(t),tabIndex:-1,...e})},dle=qB(hW,{_id:"modal__Close",children:Wh.jsx(jY,{iconKey:"close"})}),ple=e=>iL()?Wh.jsx(dle,{...e}):null,hle={type:"object",properties:{aiAnnotations:{type:"object",properties:{answerConfidence:{anyOf:[{type:"string",const:"very_confident",description:"Very confident"},{type:"string",const:"somewhat_confident",description:"Somewhat confident"},{type:"string",const:"not_confident",description:"Not confident"},{type:"string",const:"no_sources",description:"No Sources"},{type:"string",const:"other",description:"Other"}]}},required:["answerConfidence"],additionalProperties:!0}},required:["aiAnnotations"],additionalProperties:!1},fle=async(e,t,n)=>{var r,a,o,i;const s=await t.chat.completions.create({model:"inkeep-qa-expert",messages:e,tools:[{type:"function",function:{name:"provideAIAnnotations",description:"Provides AI confidence levels for the response",parameters:hle}},{type:"function",function:{name:"provideRecordsConsidered",description:"Provides records considered in generating the response",parameters:{type:"object"}}}],tool_choice:"auto"},n?{headers:n}:void 0),l=null==(a=null==(r=s.choices[0])?void 0:r.message)?void 0:a.content;let c,u;const d=(null==(i=null==(o=s.choices[0])?void 0:o.message)?void 0:i.tool_calls)||[];for(const p of d){if("provideAIAnnotations"===p.function.name){c=JSON.parse(p.function.arguments).aiAnnotations}if("provideRecordsConsidered"===p.function.name){u=JSON.parse(p.function.arguments).recordsConsidered??[]}}return{answer:l||null,aiAnnotations:c,recordsConsidered:u,messages:e}},mle=async(e,t,n)=>{var r,a,o;const i=JSON.stringify(e.primaryFieldValues,null,2),s=JSON.stringify(e.fieldsToGenerate,null,2),l=await t.chat.completions.create({model:"inkeep-base-expert",messages:[{role:"system",content:'You are a helpful assistant that suggests form field values based on context. You will receive form field information including field names, descriptions, input types, and available options for select fields.\n\nFor each field, consider its description, input type, and available options (for select fields).\n\nYou must respond with a JSON object where keys are the field names and values match the expected input type and length for that field.\n\n<context>\n You are quickly suggesting form field values on behalf of an end-user. Think of yourself as the user filling out this form - keep suggestions simple, direct, and user-centric.\n\n You will receive:\n - Field metadata (names, descriptions, types)\n - For dropdown/select fields, their valid choice options\n - Initial form field values as context\n</context>\n\n<guidance>\n <rule>\n <name>Field Value Suggestions</name>\n <actions>\n <action>\n Return a JSON object where:\n - Keys are field names\n - Values must match field type requirements:\n - Text fields: Plain text strings\n - Dropdown/select fields: ONLY values from provided options list\n - Number fields: Valid numbers\n - Boolean fields: true/false\n\n <good_example> \n ✅ Example (fields will vary based on actual form configuration):\n {\n "issueType": "bug", // from options: ["bug", "feature", "question"]\n "severity": "high", // from options: ["low", "medium", "high"]\n "shortDescription": "Cannot log in to dashboard"\n }\n </good_example>\n\n <bad_example>\n ❌ Bad Example (using same illustrative fields):\n {\n "issueType": "not sure but maybe bug?", // invalid: not from options list\n "severity": "very very high", // invalid: not from options list\n "shortDescription": null // invalid: should be string\n }\n </bad_example>\n \n Note: The actual field names, types and valid options will be provided in the form configuration. \n Above examples are only illustrative of the expected format and validation rules.\n </action>\n </actions>\n </rule>\n\n <global_prohibitions>\n <never>Include explanations or comments in the JSON</never>\n <never>Suggest multiple values for a single field</never>\n <never>Return values not from the provided options for dropdown/select fields</never>\n <never>Skip required fields</never>\n <never>Add fields not present in the input metadata</never>\n <never>Overthink suggestions - keep them straightforward</never>\n </global_prohibitions>\n'},{role:"user",content:`Based on these primary field values:\n${i}\n\nSuggest values for these additional fields:\n${s}`}],stream:!0,response_format:{type:"json_object"}},n?{headers:n}:void 0);let c="";for await(const u of l){const e=null==(o=null==(a=null==(r=u.choices)?void 0:r[0])?void 0:a.delta)?void 0:o.content;e&&(c+=e)}return{suggestedValues:c?JSON.parse(c):{}}},gle=async(e,t)=>{if(t)return;const n=await vL(`${e}/v1/challenge`);return n?{"X-INKEEP-CHALLENGE-SOLUTION":btoa(JSON.stringify(n))}:void 0},yle=e=>{var t;const{formSettings:n}=e,{baseSettings:r}=nP(),{conversation:a}=iP(),{logEvent:o}=wP(),{aiApiBaseUrl:i,shouldBypassCaptcha:s}=r,l=K.useMemo((()=>new fb({baseURL:`${i}/v1`,apiKey:r.apiKey,dangerouslyAllowBrowser:!0})),[r.apiKey,i]),[c,u]=K.useState(!1),[d,p]=K.useState(!1),[h,f]=K.useState(!1),[m,g]=K.useState({}),y=K.useMemo((()=>{const{primary:e,secondary:t}=n;return lL([...e.fields,...t.fields])}),[n]),{control:b,handleSubmit:v,formState:{errors:k,isSubmitting:w,isSubmitSuccessful:x},reset:E,trigger:_,setValue:S,setError:T}=rL({defaultValues:y});K.useEffect((()=>{y&&E(y)}),[E,y]);const C=v((async e=>{try{await n.buttons.submit.onSubmit({values:e,conversation:a}),o({eventName:"intelligent_form_submitted",properties:{conversation:a,values:e}})}catch(t){T("root.serverError",{message:t instanceof Error?t.message:"Something went wrong."})}})),A=null==(t=null==k?void 0:k.root)?void 0:t.serverError;return{formSettings:n,control:b,errors:k,isSubmitSuccessful:x,isSubmitting:w,handleSubmit:C,loading:c,formError:A,submittedPrimaryForm:d,handleSubmitPrimaryForm:async()=>{var e;const t=n.primary.fields.map((e=>e.name));if(!(await _(t)))return;p(!0),u(!0);const r=b._formValues,a=n.primary.fields.reduce(((e,t)=>(e[t.name]=r[t.name],e)),{}),c=n.secondary.fields.filter((e=>!1!==e.shouldPrefillWithAI)),d=(e=>{const t=JSON.stringify(e,null,2);return[{id:`${Date.now()}1`,role:"system",content:'\n <context>\n You are evaluating a support form submission to determine if an immediate solution can be provided. Your response is final and non-conversational - the user cannot respond or ask follow-ups. You must either provide a complete solution or explain why one cannot be provided.\n </context>\n <guidance>\n <rule>\n <name>High Confidence Response</name>\n <conditions>\n <and>\n <condition>Form provides clear, specific problem description</condition>\n <condition>Authoritative information exists for this exact issue</condition>\n <condition>Complete solution can be provided from available information</condition>\n <condition>Solution requires no clarification or follow-up</condition>\n </and>\n </conditions>\n <actions>\n <action>\n Provide complete solution in this format:\n 1. State identified problem\n 2. List solution steps\n 3. Include any necessary implementation details\n\n <good_example>\n "To resolve [...paraphrased problem...], try [...solution steps]."\n </good_example>\n\n <bad_example>\n "I think this might be related to [problem]. Would you like me to explain more about...? If you could clarify [X], I could better assist..."\n </bad_example>\n\n <guidance>\n <should>Use only information from form fields</should>\n <should>State solution directly and completely</should>\n <should>Include all necessary steps</should>\n <should>Maintain professional, instructional tone</should>\n </guidance>\n </action>\n </actions>\n </rule>\n <rule>\n <name>Low Confidence Response</name>\n <conditions>\n <or>\n <condition>Problem description is unclear/ambiguous</condition>\n <condition>Authoritative information is missing</condition>\n <condition>Solution would require additional details</condition>\n <condition>Cannot provide complete confidence in solution</condition>\n </or>\n </conditions>\n <actions>\n <action>\n Provide single-sentence explanation focusing on specific information gap.\n\n <good_example>\n "The information sources don\'t cover [specific detail[s]]"\n </good_example>\n\n <bad_example>\n "I\'m not entirely sure about this, but here are some possibilities... Could you provide more details about [X]? Have you tried [Y]? It might also help if..."\n </bad_example>\n\n <guidance>\n <should>State only the primary information gap</should>\n <should>Keep explanation BRIEF and specific</should>\n <should>Focus on what\'s missing, not what\'s known</should>\n </guidance>\n </action>\n </actions>\n </rule>\n <global_prohibitions>\n <never>Ask questions or request clarification</never>\n <never>Use conditional phrases ("would you like", "do you need")</never>\n <never>Suggest contacting support</never>\n <never>Provide partial or uncertain solutions</never>\n <never>Offer multiple possible solutions</never>\n <never>Speculate beyond available information</never>\n </global_prohibitions>\n </guidance>\n '},{id:`${Date.now()}2`,role:"user",content:`${t}`}]})(a);o({eventName:"intelligent_form_primary_section_submitted",properties:{}},d);try{const t=await gle(i,s),n=await gle(i,s),[r,u]=await Promise.all([fle(d,l,t),mle({primaryFieldValues:a,fieldsToGenerate:c},l,n)]);if(u.suggestedValues)for(const[e,a]of Object.entries(u.suggestedValues))S(e,a);const p=null==(e=r.aiAnnotations)?void 0:e.answerConfidence,h=p&&["very_confident","somewhat_confident"].includes(p),m=r.recordsConsidered&&r.recordsConsidered.length>0;h&&m&&r.answer?(g({answer:r.answer,answerConfidence:p,recordsConsidered:r.recordsConsidered}),o({eventName:"intelligent_form_ai_response_provided",properties:{recordsConsidered:r.recordsConsidered}},[...d,{id:Date.now().toString(),role:"assistant",content:r.answer,links:[]}])):(f(!0),g({answer:null,recordsConsidered:r.recordsConsidered,suggestedValues:u.suggestedValues}))}catch(h){console.error(h),f(!0)}finally{u(!1)}},aiResponse:m,showSecondaryFields:h,setShowSecondaryFields:f}},ble=K.createContext(void 0),vle=({children:e,formSettings:t})=>{const n=yle({formSettings:t});return Wh.jsx(ble.Provider,{value:n,children:e})},kle=e=>Wh.jsx(oP,{children:Wh.jsx(kP,{children:Wh.jsx(vle,{...e})})}),wle=()=>{const e=K.useContext(ble);if(!e)throw new Error("useIntelligentForm must be used within a IntelligentFormProvider");return e},xle=K.createContext(void 0),Ele=({children:e,field:t,fieldProps:n,autoFocus:r})=>{const{errors:a}=wle(),o=a[t.name];return Wh.jsx(xle.Provider,{value:{field:t,fieldProps:n,error:o,autoFocus:r},children:e})},_le=()=>{const e=K.useContext(xle);if(!e)throw new Error("useIntelligentFormField must be used within a IntelligentFormFieldProvider");return e},Sle=qB("form",{_id:"intelligentForm__Root"}),Tle=e=>{const{onSubmit:t,...n}=e,{handleSubmit:r}=wle();return Wh.jsx(Sle,{onSubmit:L9(t,r),...n})},Cle=qB("h2",{_id:"intelligentForm__Heading",children:"Contact Support"}),Ale=qB("div",{_id:"intelligentForm__Content"}),Nle=qB(P$,{_id:"intelligentForm__Content__ScrollArea"}),Ile=qB(D$,{_id:"intelligentForm__Content__ScrollAreaViewport"}),Rle=e=>{const{children:t,...n}=e;return Wh.jsx(Ile,{children:Wh.jsx("div",{"data-part":"grid",style:{display:"grid"},children:t}),...n})},Ole=qB(l$,{_id:"intelligentForm__Content__ScrollAreaScrollbar"}),Ple=qB(v$,{_id:"intelligentForm__Content__ScrollAreaThumb"}),Dle=qB(L$,{_id:"intelligentForm__Content__ScrollAreaCorner"}),Lle=qB("div",{_id:"intelligentForm__Success"}),Mle=e=>{const{children:t,...n}=e,{isSubmitSuccessful:r}=wle();return r?Wh.jsx(Lle,{...n,children:t}):null},Fle=qB(MY,{_id:"intelligentForm__SuccessIcon"}),jle=e=>{const{formSettings:{successView:t}}=wle();return Wh.jsx(Fle,{iconSettings:t.icon??{builtIn:"LuCircleCheck"},...e})},Ble=qB("h2",{_id:"intelligentForm__SuccessHeading"}),zle=e=>{const{formSettings:{successView:t}}=wle();return Wh.jsx(Ble,{children:t.heading,...e})},Hle=qB("p",{_id:"intelligentForm__SuccessMessage"}),Ule=e=>{const{formSettings:{successView:t}}=wle();return Wh.jsx(Hle,{children:t.message,...e})},$le=qB("div",{_id:"intelligentForm__PrimaryForm"}),Gle=qB("div",{_id:"intelligentForm__PrimaryFormFields"}),Vle=qB("p",{_id:"intelligentForm__PrimaryForm__Description"}),qle=e=>{const{formSettings:{primary:t}}=wle();return t.description?Wh.jsx(Vle,{children:t.description,...e}):null},Wle=e=>{const{children:t,...n}=e,{formSettings:{primary:r}}=wle();return Wh.jsx(Gle,{children:CL(t,r.fields),...n})},Yle=qB("button",{_id:"intelligentForm__PrimaryFormSubmit",type:"button",children:"Next"}),Kle=e=>{const{onClick:t,...n}=e,{submittedPrimaryForm:r,handleSubmitPrimaryForm:a}=wle();return Wh.jsx(Yle,{"data-submitted":SL(r),onClick:L9(t,a),...n})},Xle=qB("div",{_id:"intelligentForm__Field"}),Qle=e=>{const{field:t,autoFocus:n,...r}=e,{control:a,errors:o}=wle();return Wh.jsx(kD,{name:t.name,control:a,rules:{required:t.isRequired?`${t.label} is required.`:void 0},render:({field:e})=>{const a=void 0!==e.value||"file"===t.inputType;return Wh.jsx(Ele,{"data-invalid":SL(!!o[t.name]),field:t,fieldProps:e,autoFocus:n,children:a&&Wh.jsx(Xle,{"data-input-type":t.inputType,"data-hidden":SL(t.isHidden),...r})})}})},Zle=qB("label",{_id:"intelligentForm__FieldLabel"}),Jle=e=>{const{field:t}=_le();return Wh.jsx(Zle,{"data-required":SL(t.isRequired),htmlFor:t.name,children:t.label,...e})},ece=qB("input",{_id:"intelligentForm__FieldText",type:"text"}),tce=K.forwardRef(((e,t)=>{const{field:n,error:r,fieldProps:{onChange:a,onBlur:o,ref:i,...s},autoFocus:l}=_le(),c=BB(t,i);return Wh.jsx(ece,{asChild:"textarea"===n.inputType,ref:c,id:n.name,autoFocus:l,placeholder:"placeholder"in n?n.placeholder:void 0,"data-invalid":SL(!!r),onChange:L9(e.onChange,a),onBlur:L9(e.onBlur,o),...s,...e,children:"textarea"===n.inputType?Wh.jsx(lz,{minRows:3,maxRows:10}):null})})),nce=qB(tce,{_id:"intelligentForm__FieldEmail",type:"email"}),rce=qB("input",{_id:"intelligentForm__FieldFile",type:"file",multiple:!0}),ace=e=>{const{field:t,error:n,fieldProps:{value:r,onChange:a,onBlur:o,...i},autoFocus:s}=_le(),{onChange:l,onBlur:c,...u}=e;return Wh.jsx(rce,{id:t.name,autoFocus:s,"data-value":r,"data-invalid":SL(!!n),...u,...i,onChange:L9(l,(e=>{const t=e.target.files;a(t)})),onBlur:L9(c,o)})},oce=qB(tce,{_id:"intelligentForm__FieldTextArea",type:"textarea",asChild:!0,children:Wh.jsx(lz,{rows:1,maxRows:8})}),ice=qB(Pz,{_id:"intelligentForm__FieldCheckbox"}),sce=e=>{const{field:t,error:n,fieldProps:r,autoFocus:a}=_le(),{onCheckedChange:o,...i}=e;return Wh.jsx(ice,{id:t.name,name:t.name,autoFocus:a,"data-invalid":SL(!!n),checked:r.value,onCheckedChange:L9(o,r.onChange),...i})},lce=qB(Dz,{_id:"intelligentForm__FieldCheckboxIndicator",children:Wh.jsx(R9,{})}),cce=qB(ZV,{_id:"intelligentForm__FieldSelect"}),uce=qB(JV,{_id:"intelligentForm__FieldSelect__Trigger"}),dce=qB(eq,{_id:"intelligentForm__FieldSelect__Value"}),pce=qB(tq,{_id:"intelligentForm__FieldSelect__Icon",asChild:!0,children:Wh.jsx(MY,{iconSettings:{builtIn:"LuChevronDown"}})}),hce=qB(nq,{_id:"intelligentForm__FieldSelect__Content",position:"popper"}),fce=qB(rq,{_id:"intelligentForm__FieldSelect__Viewport"}),mce=qB(aq,{_id:"intelligentForm__FieldSelect__Item"}),gce=qB(oq,{_id:"intelligentForm__FieldSelect__ItemText"}),yce=qB(iq,{_id:"intelligentForm__FieldSelect__ItemIndicator",asChild:!0,children:Wh.jsx(MY,{iconSettings:{builtIn:"LuCheck"}})}),bce=qB("span",{_id:"intelligentForm__FieldError"}),vce=e=>{var t;const{error:n}=_le();return n?Wh.jsx(bce,{children:null==(t=n.message)?void 0:t.toString(),...e}):null},kce=qB("div",{_id:"intelligentForm__BotHeading"}),wce=qB(MY,{_id:"intelligentForm__BotHeading__Icon",iconSettings:{builtIn:"LuSparkles"}}),xce=qB("div",{_id:"intelligentForm__BotHeading__Name"}),Ece=e=>{const{baseSettings:t}=nP(),{organizationDisplayName:n}=t??{},{formSettings:{aiAssistantName:r}}=wle();return Wh.jsx(xce,{children:r??n,...e})},_ce=qB("div",{_id:"intelligentForm__Loading"}),Sce=K.forwardRef((({...e},t)=>{const{loading:n}=wle(),r=K.useRef(null),a=BB(t,r);return K.useEffect((()=>{n&&r.current&&r.current.scrollIntoView({behavior:"smooth",block:"nearest",inline:"nearest"})}),[n]),n?Wh.jsx(_ce,{ref:a,...e}):null})),Tce=qB("div",{_id:"intelligentForm__ConfidentResponse"}),Cce=K.forwardRef((({...e},t)=>{const{aiResponse:n,loading:r}=wle(),a=K.useRef(null),o=BB(t,a);return K.useEffect((()=>{!r&&n.answerConfidence&&a.current&&a.current.scrollIntoView({behavior:"smooth",block:"nearest",inline:"nearest"})}),[r,n.answerConfidence]),n.answerConfidence?Wh.jsx(Tce,{ref:o,...e}):null})),Ace=qB(N9,{_id:"intelligentForm__ConfidentAnswer"}),Nce=e=>{const{aiResponse:t}=wle();return Wh.jsx(Ace,{shouldOpenLinksInNewTab:!0,children:t.answer,...e})},Ice=qB("button",{_id:"intelligentForm__ConfidentResponseButton",type:"button"}),Rce=e=>{const{onClick:t,...n}=e,{showSecondaryFields:r,setShowSecondaryFields:a}=wle();return Wh.jsx(Ice,{"data-escalated":SL(r),onClick:L9(t,(()=>{a(!0)})),...n})},Oce=qB(MY,{_id:"intelligentForm__ConfidentResponseButton__Icon",iconSettings:{builtIn:"LuUser"}}),Pce=qB("span",{_id:"intelligentForm__ConfidentResponseButton__Label",children:"Escalate to human"}),Dce=qB("div",{_id:"intelligentForm__SecondaryForm"}),Lce=K.forwardRef((({...e},t)=>{const{showSecondaryFields:n}=wle(),r=K.useRef(null),a=BB(t,r);return K.useEffect((()=>{n&&r.current&&r.current.scrollIntoView({behavior:"smooth",block:"nearest",inline:"nearest"})}),[n]),n?Wh.jsx(Dce,{ref:a,...e}):null})),Mce=qB("p",{_id:"intelligentForm__SecondaryForm__Description"}),Fce=e=>{const{formSettings:{secondary:t},aiResponse:{answerConfidence:n}}=wle();if(!t.description)return null;const r="string"==typeof t.description?t.description:n?t.description.confident:t.description.default;return Wh.jsx(Mce,{children:r,...e})},jce=qB("div",{_id:"intelligentForm__SecondaryFormFields"}),Bce=e=>{const{children:t,...n}=e,{formSettings:{secondary:r}}=wle();return Wh.jsx(jce,{children:CL(t,r.fields),...n})},zce=qB("button",{_id:"intelligentForm__SecondaryFormSubmit",type:"submit",children:"Submit"}),Hce=e=>{const{formSettings:t}=wle(),{label:n}=t.buttons.submit;return Wh.jsx(zce,{children:n??"Submit",...e})},Uce=qB("span",{_id:"intelligentForm__Error"}),$ce=e=>{const{formError:t}=wle();return t?Wh.jsx(Uce,{children:t.message,...e}):null},Gce=qB("div",{_id:"intelligentForm__Sources"}),Vce=qB("p",{_id:"intelligentForm__SourcesCaption",children:"Here are the sources I considered:"}),qce=qB("div",{_id:"intelligentForm__SourcesList"}),Wce=e=>{const{children:t,...n}=e,{baseSettings:{transformSource:r,organizationDisplayName:a}}=nP(),{aiResponse:{recordsConsidered:o}}=wle();if(!o)return null;const i=o.reduce(((e,t)=>{const n=X9(t,"intelligentFormSource",{organizationDisplayName:a,transformSource:r});return e.some((e=>e.url===n.url))||e.push(n),e}),[]);return Wh.jsx(qce,{children:CL(t,i),...n})},Yce=qB(zY,{_id:"intelligentForm__Source"}),Kce=e=>{const{source:t,...n}=e;return Wh.jsx(NB,{source:{...t,isExternal:!!t.shouldOpenInNewTab},children:Wh.jsx(Yce,{"data-type":t.type,appendToUrl:t.appendToUrl,href:t.url,isExternal:!1!==t.shouldOpenInNewTab,...n})})},Xce=qB(MY,{_id:"intelligentForm__SourceIcon"}),Qce=e=>{const{source:t}=IB();return Wh.jsx(Xce,{iconSettings:t.icon,"data-type":t.type,...e})},Zce=qB("span",{_id:"intelligentForm__SourceTitle"}),Jce=e=>{const{source:t}=IB();return Wh.jsx(Zce,{"data-type":t.type,children:t.title,...e})},eue=qB("div",{_id:"chatButton__Container"}),tue=qB("button",{_id:"chatButton__Button"}),nue=qB("div",{_id:"chatButton__Text"}),rue=qB(vz,{_id:"chatButton__AvatarContent"}),aue=qB(kz,{_id:"chatButton__AvatarImage"}),oue=K.memo((e=>{const{onLoadingStatusChange:t,avatar:n,...r}=e,{aiChatSettings:a}=nP(),{aiAssistantAvatar:o}=a??{},i="string"==typeof n?n:fB(null==n?void 0:n.light,null==n?void 0:n.dark),s="string"==typeof o?o:null==o?void 0:o.dark,[l,c]=K.useState(i??s);K.useEffect((()=>{c(i??s)}),[i,s]);return l?Wh.jsx(aue,{src:l,alt:"Chat avatar","data-type":"image",onLoadingStatusChange:L9(t,(e=>{"error"===e&&c(null)})),...r}):Wh.jsx(fW,{"data-type":"icon",...e})})),iue=qB("div",{_id:"searchBar__Container"}),sue=qB("button",{_id:"searchBar__Button",type:"button"}),lue=qB("div",{_id:"searchBar__ContentWrapper"}),cue=qB("div",{_id:"searchBar__Text"}),uue=e=>{const{searchSettings:{placeholder:t}}=nP();return Wh.jsx(cue,{...e,children:t})},due=qB(jY,{_id:"searchBar__Icon",iconKey:"search"}),pue=qB("kbd",{_id:"searchBar__KbdWrapper"}),hue=qB("kbd",{_id:"searchBar__KbdShortcutKey"}),fue=e=>{const{shortcutKey:t,...n}=e;return Wh.jsx(hue,{...n,children:null==t?void 0:t.toUpperCase()})},mue=()=>{var e,t;if("undefined"==typeof window)return!1;const n=null==(t=null==(e=window.navigator)?void 0:e.userAgent)?void 0:t.toLowerCase();return n.includes("macintosh")||n.includes("mac os x")},gue=qB("kbd",{_id:"searchBar__Ctrl",children:"Ctrl"}),yue=qB(jY,{_id:"searchBar__CmdIcon",iconKey:"command"}),bue=e=>{const{shortcutKey:t,...n}=e;return Wh.jsx(Wh.Fragment,{children:t?mue()?Wh.jsx(yue,{...n}):Wh.jsx(gue,{...n}):null})};const vue={width:void 0,height:void 0};function kue(e){const{ref:t,box:n="content-box"}=e,[{width:r,height:a},o]=K.useState(vue),i=function(){const e=K.useRef(!1);return K.useEffect((()=>(e.current=!0,()=>{e.current=!1})),[]),K.useCallback((()=>e.current),[])}(),s=K.useRef({...vue}),l=K.useRef(void 0);return l.current=e.onResize,K.useEffect((()=>{if(!t.current)return;if("undefined"==typeof window||!("ResizeObserver"in window))return;const e=new ResizeObserver((([e])=>{const t="border-box"===n?"borderBoxSize":"device-pixel-content-box"===n?"devicePixelContentBoxSize":"contentBoxSize",r=wue(e,t,"inlineSize"),a=wue(e,t,"blockSize");if(s.current.width!==r||s.current.height!==a){const e={width:r,height:a};s.current.width=r,s.current.height=a,l.current?l.current(e):i()&&o(e)}}));return e.observe(t.current,{box:n}),()=>{e.disconnect()}}),[n,t,i]),{width:r,height:a}}function wue(e,t,n){return e[t]?Array.isArray(e[t])?e[t][0][n]:e[t][n]:"contentBoxSize"===t?e.contentRect["inlineSize"===n?"width":"height"]:void 0}const xue="undefined"!=typeof document?K.useLayoutEffect:K.useEffect;function Eue(e){const{children:t,target:n,tag:r,host:a}=e,o=K.useRef(null),i=K.useRef(null),[,s]=K.useReducer((e=>e+1),0);xue((()=>{if(!o.current)return;const e=o.current.ownerDocument,t=a??e.body;return i.current=e.createElement(r??"inkeep-portal"),t.appendChild(i.current),s(),()=>{i.current&&t.removeChild(i.current)}}),[]);const l=(null==n?void 0:n.current)??i.current;return l?se.createPortal(t,l):K.createElement("span",{ref:o})}const _ue=({children:e,...t})=>{const{baseSettings:n}=nP(),{rootElement:r}=n;return Wh.jsx(Eue,{host:r,...t,children:Wh.jsx(TB,{children:e})})},Sue=K.createContext(null),Tue={didCatch:!1,error:null};let Cue=class extends K.Component{constructor(e){super(e),this.resetErrorBoundary=this.resetErrorBoundary.bind(this),this.state=Tue}static getDerivedStateFromError(e){return{didCatch:!0,error:e}}resetErrorBoundary(){const{error:e}=this.state;if(null!==e){for(var t,n,r=arguments.length,a=new Array(r),o=0;o<r;o++)a[o]=arguments[o];null===(t=(n=this.props).onReset)||void 0===t||t.call(n,{args:a,reason:"imperative-api"}),this.setState(Tue)}}componentDidCatch(e,t){var n,r;null===(n=(r=this.props).onError)||void 0===n||n.call(r,e,t)}componentDidUpdate(e,t){const{didCatch:n}=this.state,{resetKeys:r}=this.props;var a,o;n&&null!==t.error&&function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return e.length!==t.length||e.some(((e,n)=>!Object.is(e,t[n])))}(e.resetKeys,r)&&(null===(a=(o=this.props).onReset)||void 0===a||a.call(o,{next:r,prev:e.resetKeys,reason:"keys"}),this.setState(Tue))}render(){const{children:e,fallbackRender:t,FallbackComponent:n,fallback:r}=this.props,{didCatch:a,error:o}=this.state;let i=e;if(a){const e={error:o,resetErrorBoundary:this.resetErrorBoundary};if("function"==typeof t)i=t(e);else if(n)i=K.createElement(n,e);else{if(void 0===r)throw o;i=r}}return K.createElement(Sue.Provider,{value:{didCatch:a,error:o,resetErrorBoundary:this.resetErrorBoundary}},i)}};const Aue=()=>null,Nue=({children:e})=>Wh.jsx(Cue,{FallbackComponent:Aue,onError:(e,t)=>{console.warn(e),console.warn(t)},children:e}),Iue=e=>"boolean"==typeof e?`${e}`:0===e?"0":e,Rue=W4,Oue=(e,t)=>n=>{var r;if(null==(null==t?void 0:t.variants))return Rue(e,null==n?void 0:n.class,null==n?void 0:n.className);const{variants:a,defaultVariants:o}=t,i=Object.keys(a).map((e=>{const t=null==n?void 0:n[e],r=null==o?void 0:o[e];if(null===t)return null;const i=Iue(t)||Iue(r);return a[e][i]})),s=n&&Object.entries(n).reduce(((e,t)=>{let[n,r]=t;return void 0===r||(e[n]=r),e}),{}),l=null==t||null===(r=t.compoundVariants)||void 0===r?void 0:r.reduce(((e,t)=>{let{class:n,className:r,...a}=t;return Object.entries(a).every((e=>{let[t,n]=e;return Array.isArray(n)?n.includes({...o,...s}[t]):{...o,...s}[t]===n}))?[...e,n,r]:e}),[]);return Rue(e,i,l,null==n?void 0:n.class,null==n?void 0:n.className)},Pue=Oue(["max-h-screen max-w-screen relative","grow-[5] mx-auto justify-self-center text-left"],{variants:{size:{default:["grow-0 justify-self-center self-center","m-auto max-h-[100vw] max-w-screen","md:w-[min(600px,100%)] md:h-[min(760px,100%)]","lg:w-[min(640px,100%)] lg:h-[min(800px,100%)]","2xl:w-[min(760px,100%)] 2xl:h-[min(900px,100%)]"],expand:["w-full h-full"],"shrink-vertically":["w-full h-auto self-start max-h-full"],"full-viewport":["fixed top-0 left-0 w-screen h-screen z-dropdown"]},variant:{"container-with-shadow":"shadow-[0_25px_50px_-12px_rgba(0,0,0,0.25)] dark:shadow-[none]","no-shadow":"shadow-[none]"}},defaultVariants:{size:"default",variant:"container-with-shadow"}}),Due=Oue(["inline-flex","items-center","justify-center","align-middle","select-none","relative","whitespace-nowrap","appearance-none","rounded-md","leading-[1.2]","transition-all","duration-300","cursor-pointer","font-semibold","focus:outline-none","focus:z-base","focus-visible:ring","focus-visible:ring-gray-500","dark:focus-visible:ring-white-alpha-900","focus-visible:ring-2","disabled:opacity-40","disabled:cursor-not-allowed","disabled:shadow-none"],{variants:{variant:{solid:["bg-gray-100 dark:bg-white-alpha-100","text-gray-800 dark:text-white-alpha-950","hover:bg-gray-200 dark:hover:bg-white-alpha-200","hover:disabled:bg-gray-100 dark:hover:disabled:bg-white-alpha-100","active:bg-gray-300 dark:active:bg-white-alpha-400"],iconButton:["px-1 text-gray-500 text-md","hover:text-inkeep-primary-strong","dark:text-gray-dark-200","dark:hover:text-inkeep-expanded-primary-300"],ghost:["text-gray-800 dark:text-white-alpha-950","hover:bg-gray-100 dark:hover:bg-white-alpha-100","active:bg-gray-200 dark:active:bg-white-alpha-200"],outline:["border dark:border-white-alpha-200","text-gray-600 dark:text-gray-200","hover:bg-gray-50 dark:hover:bg-white-alpha-100","active:bg-gray-50 dark:active:bg-white-alpha-100"]},size:{sm:"h-8 min-w-8 text-sm px-3",md:"h-10 min-w-10 text-md px-4",xs:"h-6 min-w-6 text-xs px-2"},preset:{neutralFilled:["bg-gray-1000 text-white hover:bg-gray-900 active:bg-gray-900","dark:bg-inkeep-expanded-primary-300 dark:text-gray-dark-950","dark:hover:bg-inkeep-expanded-primary-200","dark:active:bg-inkeep-expanded-primary-200"]}},defaultVariants:{size:"md"}}),Lue=Oue("",{variants:{slot:{root:["flex items-center pl-2","text-xs rounded-md h-6","bg-gray-300 dark:bg-white-alpha-200","min-w-0 w-fit"],icon:["mr-[0.5em]","text-gray-600 dark:text-white-alpha-600"],title:["overflow-hidden whitespace-nowrap text-ellipsis inline-block"],delete:[Due({variant:"iconButton",size:"md"}),"h-4 px-1 min-w-[unset]","text-gray-600 dark:text-white-alpha-600","hover:bg-transparent hover:text-gray-700","dark:hover:text-white-alpha-500","[&_svg]:w-4 [&_svg]:h-4"]}}}),Mue=Oue("",{variants:{slot:{root:["peer h-4 w-4 shrink-0 rounded-xs","border-2 border-inherit cursor-pointer","disabled:opacity-50","data-[state=checked]:bg-gray-1000","dark:data-[state=checked]:bg-white-alpha-950","data-[state=checked]:border-gray-1000","dark:data-[state=checked]:border-white-alpha-950","text-white data-[state=checked]:text-white","dark:data-[state=checked]:text-gray-1000"],indicator:["flex items-center justify-center","text-current animate-checkbox-check"]}}}),Fue=Oue(["transition-all data-[disable-transitions]:transition-none","duration-100 ease-in-out"],{variants:{slot:{root:["group w-full overflow-hidden border rounded-lg","text-inkeep-primary-text-bold selected:text-inkeep-primary-strong","focus:outline-inkeep-expanded-primary-700 dark:focus:outline-inkeep-expanded-primary-300","dark:text-white-alpha-950 dark:selected:text-inkeep-expanded-primary-300","bg-white selected:bg-inkeep-primary-light-subtle","dark:bg-transparent dark:selected:bg-white-alpha-200","border-gray-200 selected:border-inkeep-primary-medium-subtle","dark:border-white-alpha-200","dark:selected:border-inkeep-expanded-primary-300","py-2 px-4 grid gap-x-2 gap-y-1",'[grid-template:"breadcrumbs_breadcrumbs_breadcrumbs_indicator""icon_title_tag_indicator""description_description_description_indicator"/auto_auto_1fr_auto]',"items-center",'md:data-[view=dual-pane]:[grid-template:"breadcrumbs_breadcrumbs_breadcrumbs""icon_title_tag""description_description_description"/auto_auto_1fr]'],breadcrumbs:["[grid-area:breadcrumbs]","whitespace-nowrap line-clamp-1","flex items-center text-gray-600","dark:text-white-alpha-600 text-xs truncate inline-block"],breadcrumbsIcon:"last-of-type:hidden text-xs mb-0.5 mx-[5px]",icon:["[grid-area:icon]","text-gray-500","group-selected:text-inkeep-primary-text-subtle","dark:text-gray-dark-300 dark:group-selected:text-gray-dark-100"],title:["[grid-area:title]","text-gray-800 dark:text-white-alpha-950","group-selected:text-inkeep-primary-text-bold","dark:group-selected:text-white","font-medium line-clamp-1","whitespace-nowrap text-ellipsis inline-block"],tag:["[grid-area:tag] w-fit justify-self-end","text-xs px-1 uppercase rounded-sm align-middle","font-bold inline-block whitespace-nowrap",'data-[type^="github"]:text-purple-500','data-[type="stackoverflow"]:text-green-500',"shadow-[inset_0_0_0_1px_currentColor]"],description:["[grid-area:description]","text-1sm line-clamp-1","text-gray-700 dark:text-white-alpha-700"],descriptionPart:["data-[highlighted]:font-semibold","data-[highlighted]:text-inkeep-primary-text-subtle","dark:data-[highlighted]:text-gray-dark-50"],indicator:["[grid-area:indicator]","self-center justify-self-end","opacity-0 group-selected:opacity-100","transition-opacity duration-100 ease-in-out ml-auto","md:data-[view=dual-pane]:hidden"]}}}),jue=Oue("size-4 inline-block leading-[1em] shrink-0 text-current align-middle"),Bue=Oue(["w-full min-w-0 outline-none relative","appearance-none [transition-property:common]","[transition-duration:0.02s]","disabled:opacity-40 disabled:cursor-not-allowed","[--focus-border-color:theme(colors.blue.500)]","[--error-border-color:theme(colors.red.500)]","dark:[--focus-border-color:theme(colors.blue.300)]","dark:[--error-border-color:theme(colors.red.300)]"],{variants:{variant:{outline:["border border-inherit bg-inherit","focus:[&:not([data-invalid])]:border-[--focus-border-color]","focus:[&:not([data-invalid])]:shadow-[0_0_0_1px_var(--focus-border-color)]","data-[invalid]:border-[--error-border-color]","data-[invalid]:shadow-[0_0_0_1px_var(--error-border-color)]"]},size:{md:"p-4 h-10 text-md rounded-md",sm:"px-3 py-2 text-sm rounded-md"}}}),zue=Oue(["transition-[common] ease-out duration-[180]","cursor-pointer text-decoration-none break-words","outline-none focus-visible:ring-2 focus-visible:ring-offset-2","focus-visible:ring-gray-500","dark:focus-visible:ring-white-alpha-900 dark:focus-visible:ring-offset-gray-950","hover:underline"]),Hue=Oue("tracking-tight font-semibold",{variants:{size:{lg:"text-xl",md:"text-md"}},defaultVariants:{size:"md"}}),Uue=Oue("text-2sm ms-[1em] break-words pb-3 pl-7 relative [&_li]:mb-1",{variants:{style:{ordered:"list-decimal [counter-increment:item]",unordered:"list-[initial]"}}}),$ue=Oue("",{variants:{slot:{root:"w-full border-collapse [font-variant-numeric:lining-nums_tabular-nums]",th:["font-heading font-bold uppercase tracking-wider text-start","data-[is-numeric=true]:text-end","border-b border-gray-100 dark:border-gray-700","text-gray-600 dark:text-gray-400","px-6 py-3 leading-4 text-xs"],td:["text-start data-[is-numeric=true]:text-end","border-b border-gray-100 dark:border-gray-700","px-6 py-4 leading-5"]},size:{md:""}}}),Gue=Oue(["ml-[3px] cursor-pointer","[&_a]:bg-inkeep-primary-light","[&_a]:px-1","[&_a]:py-[1px]","[&_a]:rounded-sm","[&_a]:no-underline","[&_a]:text-inkeep-primary-text-subtle","[&_a]:hover:text-inkeep-primary-text-bold","[&_a]:font-semibold","[&_a]:dark:bg-inkeep-primary-text-subtle","[&_a]:dark:hover:text-inkeep-expanded-primary-200","[&_a]:hover:no-underline"]),Vue=Oue(["bg-inkeep-primary-medium text-inkeep-primary-text-color-on-primary","[overflow-wrap:anywhere] min-w-0 py-[.2rem] my-[.1rem]","px-[.4rem] rounded-[6px] [font-size:85%!important]","font-semibold inline-block","font-mono "]),que=Oue("",{variants:{slot:{container:"overflow-y-auto mb-3",header:["flex items-center justify-between","bg-gray-50 dark:bg-gray-dark-800","text-gray-600 dark:text-gray-400","mb-0 leading-[1.25] px-2 text-xs","transition-all duration-200 ease-in-out","rounded-[6px_6px_0_0]"],copyButton:["px-0 bg-inherit text-inherit","hover:text-gray-800 dark:text-white-alpha-700 dark:hover:text-white-alpha-950","dark:hover:bg-transparent h-8 w-8 min-h-8 min-w-8 text-sm","data-[copied]:text-inkeep-primary-medium"],highlighter:["text-1sm overflow-x-auto","rounded-[0_0_6px_6px]","p-[1em] whitespace-pre","m-[0px_0px_0.5em]","bg-gray-50 dark:bg-gray-dark-900","[scrollbar-width:thin]","[--scrollbar-color:var(--color-gray-300)]","dark:[--scrollbar-color:var(--color-gray-dark-600)]","[scrollbar-color:var(--scrollbar-color)_transparent]"]}}}),Wue=Oue("",{variants:{slot:{overlay:["fixed inset-0","bg-overlay-light dark:bg-overlay-dark","data-[state=closed]:hidden","data-[state=open]:animate-[fade-in_0.15s_ease-out]","backdrop-blur-sm overflow-y-auto","place-items-center grid z-overlay"],content:["fixed","top-[5%]","left-1/2","translate-x-[-50%]","z-overlay","flex flex-col","w-full","duration-200","text-inherit rounded-md","bg-white shadow-lg dark:bg-gray-dark-950 dark:shadow-none","focus-visible:outline-none","focus:outline-none","data-[state=closed]:hidden","data-[state=closed]:animate-fade-out","data-[state=open]:animate-[fade-in_0.15s_ease-out]","data-[mobile]:inset-0","data-[mobile]:h-[unset]","data-[mobile]:w-[unset]","data-[mobile]:transform-none","data-[mobile]:rounded-none","[&[data-mobile]>div]:h-full","[&[data-mobile]>div]:max-h-dvh","[&[data-mobile]>div]:max-h-[unset]"],header:["px-6 py-4 text-xl font-semibold flex-0 flex flex-col"],close:[Due({variant:"ghost",size:"md"}),"w-8 h-8 min-w-0","text-lg text-gray-500 dark:text-white-alpha-500","absolute top-2 right-3"],body:["px-6 py-2 flex-1"]}}}),Yue=Oue("",{variants:{slot:{content:["flex flex-col bg-white dark:bg-gray-dark-800","rounded-md z-popover","shadow-md relative","data-[state=open]:animate-fade-in","data-[state=closed]:animate-fade-out","focus:outline-none"],arrow:"fill-white dark:fill-gray-dark-800"}}}),Kue=Oue("",{variants:{section:{wrapper:"w-full flex flex-col grow-[5] overflow-hidden justify-between max-h-full",header:"relative max-h-full",content:"w-full flex flex-col overflow-hidden p-0 grow-[2]",footer:"justify-self-end flex-shrink-0"}}}),Xue=Oue("",{variants:{slot:{trigger:[Bue({size:"md",variant:"outline"}),"px-4 py-0 flex items-center justify-between"],content:["relative z-dropdown max-h-96 min-w-[8rem]","overflow-hidden rounded-md border","bg-white dark:bg-gray-dark-950 shadow-md","data-[state=open]:animate-fade-in data-[state=closed]:animate-fade-out","data-[side=bottom]:translate-y-1.5","data-[side=left]:-translate-x-1.5","data-[side=right]:translate-x-1.5","data-[side=top]:-translate-y-1.5"],viewport:["p-1 h-[var(--radix-select-trigger-height)]","w-full min-w-[var(--radix-select-trigger-width)]"],item:["hover:bg-gray-100 dark:hover:bg-gray-dark-800","focus:bg-gray-100 dark:focus:bg-gray-dark-800","relative flex w-full text-md cursor-pointer py-1.5","select-none outline-none pl-2 pr-8 rounded-md items-center ","data-[disabled]:pointer-events-none data-[disabled]:opacity-50"],itemIndicator:["absolute right-2 flex h-3.5 w-3.5","items-center justify-center"]}}}),Que=Oue(["h-5 opacity-70 rounded-sm shadow-none","bg-clip-padding cursor-default pointer-events-none","before:invisible after:invisible *:invisible","animate-skeleton-bg-fade select-none","[--start-color:theme(colors.gray.50)]","[--end-color:theme(colors.gray.300)]","dark:[--start-color:theme(colors.gray-dark.800)]","dark:[--end-color:theme(colors.gray-dark.600)]","bg-[--start-color] border-[--end-color]"]),Zue=e=>{const t=nde(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:e=>{const n=e.split("-");return""===n[0]&&1!==n.length&&n.shift(),Jue(n,t)||tde(e)},getConflictingClassGroupIds:(e,t)=>{const a=n[e]||[];return t&&r[e]?[...a,...r[e]]:a}}},Jue=(e,t)=>{var n;if(0===e.length)return t.classGroupId;const r=e[0],a=t.nextPart.get(r),o=a?Jue(e.slice(1),a):void 0;if(o)return o;if(0===t.validators.length)return;const i=e.join("-");return null==(n=t.validators.find((({validator:e})=>e(i))))?void 0:n.classGroupId},ede=/^\[(.+)\]$/,tde=e=>{if(ede.test(e)){const t=ede.exec(e)[1],n=null==t?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},nde=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return ide(Object.entries(e.classGroups),n).forEach((([e,n])=>{rde(n,r,e,t)})),r},rde=(e,t,n,r)=>{e.forEach((e=>{if("string"!=typeof e){if("function"==typeof e)return ode(e)?void rde(e(r),t,n,r):void t.validators.push({validator:e,classGroupId:n});Object.entries(e).forEach((([e,a])=>{rde(a,ade(t,e),n,r)}))}else{(""===e?t:ade(t,e)).classGroupId=n}}))},ade=(e,t)=>{let n=e;return t.split("-").forEach((e=>{n.nextPart.has(e)||n.nextPart.set(e,{nextPart:new Map,validators:[]}),n=n.nextPart.get(e)})),n},ode=e=>e.isThemeGetter,ide=(e,t)=>t?e.map((([e,n])=>[e,n.map((e=>"string"==typeof e?t+e:"object"==typeof e?Object.fromEntries(Object.entries(e).map((([e,n])=>[t+e,n]))):e))])):e,sde=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const a=(a,o)=>{n.set(a,o),t++,t>e&&(t=0,r=n,n=new Map)};return{get(e){let t=n.get(e);return void 0!==t?t:void 0!==(t=r.get(e))?(a(e,t),t):void 0},set(e,t){n.has(e)?n.set(e,t):a(e,t)}}},lde=e=>{const{separator:t,experimentalParseClassName:n}=e,r=1===t.length,a=t[0],o=t.length,i=e=>{const n=[];let i,s=0,l=0;for(let d=0;d<e.length;d++){let c=e[d];if(0===s){if(c===a&&(r||e.slice(d,d+o)===t)){n.push(e.slice(l,d)),l=d+o;continue}if("/"===c){i=d;continue}}"["===c?s++:"]"===c&&s--}const c=0===n.length?e:e.substring(l),u=c.startsWith("!");return{modifiers:n,hasImportantModifier:u,baseClassName:u?c.substring(1):c,maybePostfixModifierPosition:i&&i>l?i-l:void 0}};return n?e=>n({className:e,parseClassName:i}):i},cde=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach((e=>{"["===e[0]?(t.push(...n.sort(),e),n=[]):n.push(e)})),t.push(...n.sort()),t},ude=/\s+/;function dde(){let e,t,n=0,r="";for(;n<arguments.length;)(e=arguments[n++])&&(t=pde(e))&&(r&&(r+=" "),r+=t);return r}const pde=e=>{if("string"==typeof e)return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=pde(e[r]))&&(n&&(n+=" "),n+=t);return n};function hde(e,...t){let n,r,a,o=function(s){const l=t.reduce(((e,t)=>t(e)),e());return n=(e=>({cache:sde(e.cacheSize),parseClassName:lde(e),...Zue(e)}))(l),r=n.cache.get,a=n.cache.set,o=i,i(s)};function i(e){const t=r(e);if(t)return t;const o=((e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:a}=t,o=[],i=e.trim().split(ude);let s="";for(let l=i.length-1;l>=0;l-=1){const e=i[l],{modifiers:t,hasImportantModifier:c,baseClassName:u,maybePostfixModifierPosition:d}=n(e);let p=Boolean(d),h=r(p?u.substring(0,d):u);if(!h){if(!p){s=e+(s.length>0?" "+s:s);continue}if(h=r(u),!h){s=e+(s.length>0?" "+s:s);continue}p=!1}const f=cde(t).join(":"),m=c?f+"!":f,g=m+h;if(o.includes(g))continue;o.push(g);const y=a(h,p);for(let n=0;n<y.length;++n){const e=y[n];o.push(m+e)}s=e+(s.length>0?" "+s:s)}return s})(e,n);return a(e,o),o}return function(){return o(dde.apply(null,arguments))}}const fde=e=>{const t=t=>t[e]||[];return t.isThemeGetter=!0,t},mde=/^\[(?:([a-z-]+):)?(.+)\]$/i,gde=/^\d+\/\d+$/,yde=new Set(["px","full","screen"]),bde=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,vde=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,kde=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,wde=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,xde=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Ede=e=>Sde(e)||yde.has(e)||gde.test(e),_de=e=>jde(e,"length",Bde),Sde=e=>Boolean(e)&&!Number.isNaN(Number(e)),Tde=e=>jde(e,"number",Sde),Cde=e=>Boolean(e)&&Number.isInteger(Number(e)),Ade=e=>e.endsWith("%")&&Sde(e.slice(0,-1)),Nde=e=>mde.test(e),Ide=e=>bde.test(e),Rde=new Set(["length","size","percentage"]),Ode=e=>jde(e,Rde,zde),Pde=e=>jde(e,"position",zde),Dde=new Set(["image","url"]),Lde=e=>jde(e,Dde,Ude),Mde=e=>jde(e,"",Hde),Fde=()=>!0,jde=(e,t,n)=>{const r=mde.exec(e);return!!r&&(r[1]?"string"==typeof t?r[1]===t:t.has(r[1]):n(r[2]))},Bde=e=>vde.test(e)&&!kde.test(e),zde=()=>!1,Hde=e=>wde.test(e),Ude=e=>xde.test(e),$de=hde((()=>{const e=fde("colors"),t=fde("spacing"),n=fde("blur"),r=fde("brightness"),a=fde("borderColor"),o=fde("borderRadius"),i=fde("borderSpacing"),s=fde("borderWidth"),l=fde("contrast"),c=fde("grayscale"),u=fde("hueRotate"),d=fde("invert"),p=fde("gap"),h=fde("gradientColorStops"),f=fde("gradientColorStopPositions"),m=fde("inset"),g=fde("margin"),y=fde("opacity"),b=fde("padding"),v=fde("saturate"),k=fde("scale"),w=fde("sepia"),x=fde("skew"),E=fde("space"),_=fde("translate"),S=()=>["auto",Nde,t],T=()=>[Nde,t],C=()=>["",Ede,_de],A=()=>["auto",Sde,Nde],N=()=>["","0",Nde],I=()=>[Sde,Nde];return{cacheSize:500,separator:":",theme:{colors:[Fde],spacing:[Ede,_de],blur:["none","",Ide,Nde],brightness:I(),borderColor:[e],borderRadius:["none","","full",Ide,Nde],borderSpacing:T(),borderWidth:C(),contrast:I(),grayscale:N(),hueRotate:I(),invert:N(),gap:T(),gradientColorStops:[e],gradientColorStopPositions:[Ade,_de],inset:S(),margin:S(),opacity:I(),padding:T(),saturate:I(),scale:I(),sepia:N(),skew:I(),space:T(),translate:T()},classGroups:{aspect:[{aspect:["auto","square","video",Nde]}],container:["container"],columns:[{columns:[Ide]}],"break-after":[{"break-after":["auto","avoid","all","avoid-page","page","left","right","column"]}],"break-before":[{"break-before":["auto","avoid","all","avoid-page","page","left","right","column"]}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top",Nde]}],overflow:[{overflow:["auto","hidden","clip","visible","scroll"]}],"overflow-x":[{"overflow-x":["auto","hidden","clip","visible","scroll"]}],"overflow-y":[{"overflow-y":["auto","hidden","clip","visible","scroll"]}],overscroll:[{overscroll:["auto","contain","none"]}],"overscroll-x":[{"overscroll-x":["auto","contain","none"]}],"overscroll-y":[{"overscroll-y":["auto","contain","none"]}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[m]}],"inset-x":[{"inset-x":[m]}],"inset-y":[{"inset-y":[m]}],start:[{start:[m]}],end:[{end:[m]}],top:[{top:[m]}],right:[{right:[m]}],bottom:[{bottom:[m]}],left:[{left:[m]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Cde,Nde]}],basis:[{basis:S()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Nde]}],grow:[{grow:N()}],shrink:[{shrink:N()}],order:[{order:["first","last","none",Cde,Nde]}],"grid-cols":[{"grid-cols":[Fde]}],"col-start-end":[{col:["auto",{span:["full",Cde,Nde]},Nde]}],"col-start":[{"col-start":A()}],"col-end":[{"col-end":A()}],"grid-rows":[{"grid-rows":[Fde]}],"row-start-end":[{row:["auto",{span:[Cde,Nde]},Nde]}],"row-start":[{"row-start":A()}],"row-end":[{"row-end":A()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",Nde]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",Nde]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal","start","end","center","between","around","evenly","stretch"]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal","start","end","center","between","around","evenly","stretch","baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":["start","end","center","between","around","evenly","stretch","baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[b]}],px:[{px:[b]}],py:[{py:[b]}],ps:[{ps:[b]}],pe:[{pe:[b]}],pt:[{pt:[b]}],pr:[{pr:[b]}],pb:[{pb:[b]}],pl:[{pl:[b]}],m:[{m:[g]}],mx:[{mx:[g]}],my:[{my:[g]}],ms:[{ms:[g]}],me:[{me:[g]}],mt:[{mt:[g]}],mr:[{mr:[g]}],mb:[{mb:[g]}],ml:[{ml:[g]}],"space-x":[{"space-x":[E]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[E]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Nde,t]}],"min-w":[{"min-w":[Nde,t,"min","max","fit"]}],"max-w":[{"max-w":[Nde,t,"none","full","min","max","fit","prose",{screen:[Ide]},Ide]}],h:[{h:[Nde,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Nde,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Nde,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Nde,t,"auto","min","max","fit"]}],"font-size":[{text:["base",Ide,_de]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Tde]}],"font-family":[{font:[Fde]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",Nde]}],"line-clamp":[{"line-clamp":["none",Sde,Tde]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Ede,Nde]}],"list-image":[{"list-image":["none",Nde]}],"list-style-type":[{list:["none","disc","decimal",Nde]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[y]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[y]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:["solid","dashed","dotted","double","none","wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Ede,_de]}],"underline-offset":[{"underline-offset":["auto",Ede,Nde]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:T()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Nde]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Nde]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[y]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top",Pde]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",Ode]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},Lde]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[f]}],"gradient-via-pos":[{via:[f]}],"gradient-to-pos":[{to:[f]}],"gradient-from":[{from:[h]}],"gradient-via":[{via:[h]}],"gradient-to":[{to:[h]}],rounded:[{rounded:[o]}],"rounded-s":[{"rounded-s":[o]}],"rounded-e":[{"rounded-e":[o]}],"rounded-t":[{"rounded-t":[o]}],"rounded-r":[{"rounded-r":[o]}],"rounded-b":[{"rounded-b":[o]}],"rounded-l":[{"rounded-l":[o]}],"rounded-ss":[{"rounded-ss":[o]}],"rounded-se":[{"rounded-se":[o]}],"rounded-ee":[{"rounded-ee":[o]}],"rounded-es":[{"rounded-es":[o]}],"rounded-tl":[{"rounded-tl":[o]}],"rounded-tr":[{"rounded-tr":[o]}],"rounded-br":[{"rounded-br":[o]}],"rounded-bl":[{"rounded-bl":[o]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[y]}],"border-style":[{border:["solid","dashed","dotted","double","none","hidden"]}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[y]}],"divide-style":[{divide:["solid","dashed","dotted","double","none"]}],"border-color":[{border:[a]}],"border-color-x":[{"border-x":[a]}],"border-color-y":[{"border-y":[a]}],"border-color-s":[{"border-s":[a]}],"border-color-e":[{"border-e":[a]}],"border-color-t":[{"border-t":[a]}],"border-color-r":[{"border-r":[a]}],"border-color-b":[{"border-b":[a]}],"border-color-l":[{"border-l":[a]}],"divide-color":[{divide:[a]}],"outline-style":[{outline:["","solid","dashed","dotted","double","none"]}],"outline-offset":[{"outline-offset":[Ede,Nde]}],"outline-w":[{outline:[Ede,_de]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:C()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[y]}],"ring-offset-w":[{"ring-offset":[Ede,_de]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Ide,Mde]}],"shadow-color":[{shadow:[Fde]}],opacity:[{opacity:[y]}],"mix-blend":[{"mix-blend":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"]}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",Ide,Nde]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[u]}],invert:[{invert:[d]}],saturate:[{saturate:[v]}],sepia:[{sepia:[w]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[u]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[y]}],"backdrop-saturate":[{"backdrop-saturate":[v]}],"backdrop-sepia":[{"backdrop-sepia":[w]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[i]}],"border-spacing-x":[{"border-spacing-x":[i]}],"border-spacing-y":[{"border-spacing-y":[i]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Nde]}],duration:[{duration:I()}],ease:[{ease:["linear","in","out","in-out",Nde]}],delay:[{delay:I()}],animate:[{animate:["none","spin","ping","pulse","bounce",Nde]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[k]}],"scale-x":[{"scale-x":[k]}],"scale-y":[{"scale-y":[k]}],rotate:[{rotate:[Cde,Nde]}],"translate-x":[{"translate-x":[_]}],"translate-y":[{"translate-y":[_]}],"skew-x":[{"skew-x":[x]}],"skew-y":[{"skew-y":[x]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Nde]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Nde]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":T()}],"scroll-mx":[{"scroll-mx":T()}],"scroll-my":[{"scroll-my":T()}],"scroll-ms":[{"scroll-ms":T()}],"scroll-me":[{"scroll-me":T()}],"scroll-mt":[{"scroll-mt":T()}],"scroll-mr":[{"scroll-mr":T()}],"scroll-mb":[{"scroll-mb":T()}],"scroll-ml":[{"scroll-ml":T()}],"scroll-p":[{"scroll-p":T()}],"scroll-px":[{"scroll-px":T()}],"scroll-py":[{"scroll-py":T()}],"scroll-ps":[{"scroll-ps":T()}],"scroll-pe":[{"scroll-pe":T()}],"scroll-pt":[{"scroll-pt":T()}],"scroll-pr":[{"scroll-pr":T()}],"scroll-pb":[{"scroll-pb":T()}],"scroll-pl":[{"scroll-pl":T()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Nde]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Ede,_de,Tde]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}}));function Gde(...e){return $de(W4(e))}const Vde=e=>e?"":void 0,qde=Oue("",{variants:{slot:{root:["bg-gray-50 dark:bg-transparent","border border-transparent dark:border-gray-dark-700","rounded-md p-0.5 flex items-center !ml-auto"],button:[Gde(Due({size:"xs"}),"group","rounded data-[active]:shadow","bg-transparent data-[active]:bg-white","text-gray-600 data-[active]:text-gray-800","dark:text-white-alpha-600 dark:data-[active]:text-white-alpha-950","dark:data-[active]:bg-gray-dark-700 dark:shadow-none","hover:text-gray-800 hover:dark:text-white-alpha-950")],icon:["mr-1 text-gray-500 data-[active]:text-gray-600","dark:text-white-alpha-500 dark:data-[active]:text-white-alpha-600","group-hover:text-gray-600 dark:group-hover:text-white-alpha-600"]}}}),Wde={markdownH1:Gde(Hue({size:"lg"}),"mb-3"),markdownH2:Gde(Hue({size:"md"}),"mb-2"),markdownP:Gde("mb-3 break-words whitespace-pre-wrap","[&+ol,&+li]:mt-0"),markdownLi:Gde("[&_a]:break-words [&_a]:inline"),markdownUl:Uue({style:"unordered"}),markdownOl:Gde(Uue({style:"ordered"}),"[inset-inline-start:var(--start,0px)]","[counter-reset:item_calc(var(--start,0)_-_1)]"),markdownLink:Gde(zue(),"text-inkeep-primary-stronger hover:text-inkeep-primary-strong","dark:text-inkeep-expanded-primary-100 dark:hover:text-inkeep-expanded-primary-300"),markdownSourceLink:Gue(),markdownTable:$ue({slot:"root"}),markdownTh:$ue({slot:"th"}),markdownTd:$ue({slot:"td"}),markdownCode:Vue(),codeblockContainer:que({slot:"container"}),codeblockHeader:que({slot:"header"}),codeblockCopyButton:Gde(Due({}),que({slot:"copyButton"})),codeblockHighlighterWrapper:Gde(),codeblockHighlighter:que({slot:"highlighter"}),codeblockCode:"font-mono",markdownInput:Gde("mr-1")},Yde=["Thinking","Looking for content","Analyzing"];function Kde(){const[e,t]=K.useState(0);return K.useEffect((()=>{const e=setInterval((()=>{t((t=>t+1<Yde.length?t+1:(clearInterval(e),t)))}),3500);return()=>clearInterval(e)}),[]),Wh.jsxs("div",{className:"flex items-center space-x-2 font-medium text-sm text-gray-700 dark:text-gray-dark-300","aria-live":"polite",children:[Wh.jsx("span",{className:"animate-shimmer bg-[linear-gradient(to_bottom_right,_var(--ikp-color-gray-700),_var(--ikp-color-gray-400))] dark:bg-[linear-gradient(to_bottom_right,_var(--ikp-color-gray-dark-300),_var(--ikp-color-gray-dark-100))] bg-clip-text text-transparent",children:Yde[e]}),Wh.jsx("div",{className:"flex space-x-1",children:[0,1,2].map((e=>Wh.jsx("span",{className:"animate-bounce-dot opacity-30",style:{animationDelay:.2*e+"s"},children:"."},e)))})]})}const Xde=()=>Array.from({length:3}).map(((e,t)=>{const n=t%2==0;return Wh.jsxs("div",{className:Gde("flex items-center flex-row-reverse","data-[even]:flex-row","[--end-color:theme(colors.white-alpha.100)]","dark:[--start-color:theme(colors.gray.300)]","dark:[--end-color:theme(colors.white-alpha.300)]"),"data-even":Vde(n),children:[Wh.jsx("div",{"data-even":Vde(n),className:Gde(Que(),"h-12 w-12 rounded-full","data-[even]:mr-4 ml-4 data-[even]:ml-0")}),Wh.jsxs("div",{"data-even":Vde(n),className:"flex flex-col gap-2 items-end data-[even]:items-start",children:[Wh.jsx("div",{"data-even":Vde(n),className:Gde(Que(),"h-4 rounded-lg w-60")}),Wh.jsx("div",{"data-even":Vde(n),className:Gde(Que(),"h-4 rounded-lg w-56")})]})]},t)})),Qde=e=>Wh.jsx(oP,{children:Wh.jsx(kP,{children:Wh.jsx(uL,{children:Wh.jsx(Uj,{...e})})})}),Zde=K.forwardRef((({className:e,size:t,variant:n,...r},a)=>Wh.jsx(n7,{ref:a,className:Gde(Pue({size:t,variant:n}),"data-[hidden]:hidden rounded-md flex","bg-white dark:bg-gray-dark-950","data-[composite]:w-full","max-h-[min(85vh,850px)]","[[data-sidebar]_&]:m-[unset] [[data-sidebar]_&]:mt-auto","[[data-sidebar]_&]:h-full [[data-sidebar]_&]:w-full","[[data-sidebar]_&]:max-h-[unset]",e),...r}))),Jde=({className:e,...t})=>Wh.jsx(a7,{className:Gde("flex flex-col items-center justify-center h-full gap-12 flex-1 p-8",e),children:Wh.jsx(Xde,{}),...t}),epe=({className:e,...t})=>Wh.jsx(i7,{className:Gde(Kue({section:"wrapper"}),"rounded-[inherit] font-body",e),...t}),tpe=({className:e,...t})=>Wh.jsx(s7,{className:Gde(Kue({section:"header"}),"flex items-center","bg-white dark:bg-gray-dark-950","data-[show-toolbar]:after:absolute","data-[show-toolbar]:after:left-0","data-[show-toolbar]:after:top-full","data-[show-toolbar]:after:h-[1rem]","data-[show-toolbar]:after:w-full","data-[show-toolbar]:after:text-white","data-[show-toolbar]:after:dark:text-gray-dark-950","data-[show-toolbar]:after:bg-[linear-gradient(currentColor,_transparent)]","data-[show-toolbar]:after:z-start",e),...t}),npe=({className:e,...t})=>Wh.jsx(l7,{className:Gde("flex items-center gap-3 w-full","px-5 py-2 pt-4 justify-between *:m-0",e),...t}),rpe=({className:e,...t})=>Wh.jsx(c7,{className:Gde("flex items-center gap-1.5",e),...t}),ape=({className:e,...t})=>Wh.jsx(d7,{className:Gde("text-gray-600 dark:text-gray-dark-100 text-sm",e),...t}),ope=({className:e,...t})=>Wh.jsx(p7,{className:Gde(Kue({section:"content"}),"justify-end",e),...t}),ipe=({className:e,...t})=>Wh.jsx(h7,{className:Gde("overflow-hidden",e),...t}),spe=K.forwardRef((({className:e,...t},n)=>Wh.jsx(m7,{ref:n,className:Gde("h-full w-full rounded-[inherit]",e),...t}))),lpe=({className:e,...t})=>Wh.jsx(g7,{className:Gde("flex select-none touch-none p-0.5","transition-colors duration-[160ms] ease-in-out","w-2.5 border-l border-l-transparent",e),...t}),cpe=({className:e,...t})=>Wh.jsx(y7,{className:Gde("relative flex-1 rounded-full","bg-gray-300 dark:bg-white-alpha-200",e),...t}),upe=b7,dpe=({className:e,...t})=>Wh.jsx(x7,{className:Gde("ml-auto text-sm flex items-center gap-1",e),...t}),ppe=({className:e,...t})=>Wh.jsx(_7,{className:Gde("text-gray-700 dark:text-gray-dark-100",e),...t}),hpe=({className:e,...t})=>Wh.jsx(T7,{className:Gde("cursor-pointer text-gray-700 dark:text-gray-dark-100","focus-visible:ring-gray-500 dark:focus-visible:ring-white-alpha-900 focus-visible:ring-2 focus:outline-none",e),...t}),fpe=({className:e,...t})=>Wh.jsx(A7,{className:Gde(Yue({slot:"content"}),"px-4 py-2 font-normal","w-[250px] sm:w-[420px]",e),...t}),mpe=I7,gpe=({className:e,...t})=>Wh.jsx(R7,{className:Gde(Yue({slot:"arrow"}),e),...t}),ype=({className:e,...t})=>Wh.jsx(P7,{className:Gde("mt-4 flex flex-col gap-2",e),...t}),bpe=({className:e,...t})=>Wh.jsx(L7,{className:Gde("text-2xs uppercase font-semibold tracking-widest","text-gray-600 dark:text-white-alpha-500",e),...t}),vpe=({className:e,...t})=>Wh.jsx(F7,{className:Gde("flex flex-col","ikp-md:flex-row","flex-wrap gap-2",e),...t}),kpe=K.forwardRef((({className:e,style:t,...n},r)=>{const a=K.useRef(null),o=jB(r,a),{width:i=0,height:s=0}=kue({ref:a,box:"border-box"}),l=Math.max(s,i);return Wh.jsx(B7,{ref:o,style:{"--before-size":`${l+100}px`,...t},className:Gde("flex items-center justify-center relative z-base","min-h-9 rounded-md overflow-hidden","before:absolute before:z-hide","before:bg-gray-300 dark:before:bg-gray-dark-950","before:bg-no-repeat before:[background-position:0_0]","before:[background-size:cover] before:m-auto","before:w-[--before-size] before:h-[--before-size]","data-[highlight]:first:before:[background-image:conic-gradient(transparent,theme(colors.inkeep-expanded-primary.600),transparent_30%)]","dark:data-[highlight]:first:before:[background-image:conic-gradient(transparent,theme(colors.inkeep-expanded-primary.300),transparent_30%)]","data-[highlight]:first:before:animate-[spin_4s_linear_infinite]","after:absolute after:z-base after:top-[1px] after:left-[1px]","after:w-[calc(100%-2px)] after:h-[calc(100%-2px)]","after:rounded-[5px] after:bg-white dark:after:bg-gray-dark-950",e),...n})})),wpe=({className:e,...t})=>Wh.jsx(H7,{className:Gde(Due({size:"sm"}),"text-sm font-normal h-auto w-full py-2 z-start","whitespace-normal text-center leading-[unset]","border border-solid","text-gray-800 dark:text-white-alpha-950","border-white-alpha-200","[&:where(:hover,:focus)]:bg-slate-400/5","dark:[&:where(:hover,:focus)]:bg-white-alpha-100 focus:z-start",e),...t}),xpe=({className:e,...t})=>Wh.jsx(k7,{className:Gde("flex flex-col w-full min-w-0 min-h-0 text-2sm relative",e),...t}),Epe=Oue(["flex relative w-full overflow-hidden py-8","px-5","flex-col ikp-md:flex-row","min-w-0 grow-[2] data-[role=user]:grow-0","[&:not(:last-child)]:after:absolute","[&:not(:last-child)]:after:border-b","[&:not(:last-child)]:after:bottom-0","[&:not(:last-child)]:after:inset-x-6","ikp-md:[&:not(:last-child)]:after:inset-x-8"]),_pe=({className:e,...t})=>Wh.jsx(V7,{className:Gde(Epe(),e),...t}),Spe=({className:e,...t})=>Wh.jsx(q7,{className:Gde(Epe(),e),...t}),Tpe=({className:e,...t})=>Wh.jsx(Y7,{className:Gde("flex justify-start overflow-hidden shrink-0 select-none","flex-row ikp-md:flex-col","items-center ikp-md:items-start","ikp-md:pl-3","ikp-md:pr-6","mb-6 ikp-md:mb-0",e),...t}),Cpe=({className:e,...t})=>Wh.jsx(X7,{className:Gde("flex items-center gap-3 h-12 w-full",e),children:Wh.jsx(Kde,{}),...t}),Ape=({className:e,...t})=>Wh.jsx(Z7,{className:Gde("flex items-center justify-center rounded-full","h-auto ikp-md:h-12",e),...t}),Npe=({className:e,...t})=>Wh.jsx(eee,{className:Gde("relative flex h-8 w-8 shrink-0 overflow-hidden","data-[username]:bg-inkeep-primary-lighter","dark:data-[username]:bg-inkeep-expanded-primary-300","text-inkeep-primary-stronger font-semibold ","data-[role=user]:hidden ikp-md:flex","justify-center items-center",e),...t}),Ipe=({className:e,...t})=>Wh.jsx(nee,{className:Gde("hidden data-[role=user]:block",e),...t}),Rpe=({className:e,...t})=>Wh.jsx(aee,{className:Gde("data-[type=icon]:data-[role=user]:text-inkeep-primary-medium","dark:data-[type=icon]:data-[role=user]:text-inkeep-expanded-primary-300","data-[type=icon]:data-[role=assistant]:[--start-color:theme(colors.inkeep-expanded-primary.300)]","data-[type=icon]:data-[role=assistant]:[--end-color:theme(colors.inkeep-expanded-primary.700)]","dark:data-[type=icon]:data-[role=assistant]:[--start-color:theme(colors.inkeep-expanded-primary.50)]","dark:data-[type=icon]:data-[role=assistant]:[--end-color:theme(colors.inkeep-expanded-primary.300)]",e),...t}),Ope=({className:e,...t})=>Wh.jsx(iee,{className:Gde("px-3 py-1 ml-4 data-[role=user]:ml-0","text-sm rounded-full","bg-inkeep-primary-lighter data-[role=user]:bg-gray-50","text-inkeep-primary-stronger dark:text-inkeep-expanded-primary-300","data-[role=user]:text-gray-700 dark:data-[role=user]:text-white-alpha-700","dark:bg-gray-dark-700","ikp-md:hidden",e),...t}),Ppe=({className:e,...t})=>Wh.jsx(lee,{className:Gde("overflow-hidden flex flex-col","justify-start grow-2 w-full","data-[role=user]:justify-end","data-[role=user]:shrink-2","data-[role=user]:grow-0","ikp-md:pr-3",e),...t}),Dpe=({className:e,...t})=>Wh.jsx(uee,{className:Gde("text-2sm flex-wrap break-words min-w-0 shrink-1 max-w-full",e),...t}),Lpe=e=>{var t,n;const{message:r}=lB(),a=null==(n=null==(t=r.metadata)?void 0:t.attributes)?void 0:n.attachments;return"user"===r.role&&(null==a?void 0:a.length)?Wh.jsx(aB,{children:Wh.jsx(dee,{...e})}):null},Mpe=({className:e,...t})=>Wh.jsx(hee,{className:Gde("flex flex-wrap gap-2",e),...t}),Fpe=({className:e,...t})=>Wh.jsx(mee,{className:Gde(Due({variant:"ghost"}),Lue({slot:"root"}),"font-normal px-2",e),...t}),jpe=({className:e,...t})=>Wh.jsx(yee,{className:Gde(Lue({slot:"icon"}),e),...t}),Bpe=({className:e,...t})=>Wh.jsx(vee,{className:Gde(Lue({slot:"title"}),e),...t}),zpe=e=>{const{onOpenChange:t,...n}=e,{selectItem:r,isOpen:a,onClose:o,selectedItem:i}=oB();return Wh.jsx(kee,{open:a&&null!==i,onOpenChange:L9(t,(e=>{e||(o(),r(null))})),...n})},Hpe=({className:e,...t})=>Wh.jsx(wee,{className:Gde(Wue({slot:"overlay"}),e),...t}),Upe=({className:e,...t})=>Wh.jsx(xee,{className:Gde(Wue({slot:"content"}),"my-6 md:my-12 top-0 left-[unset] transform-none relative","p-8 md:p-10 max-w-2xl",e),...t}),$pe=({className:e,...t})=>Wh.jsx(_ee,{className:Gde(Wue({slot:"header"}),"px-0 pt-0 pb-8 flex flex-col gap-6","font-semibold",e),...t}),Gpe=({className:e,...t})=>Wh.jsx(See,{className:Gde(Wue({slot:"close"}),e),...t}),Vpe=({className:e,...t})=>Wh.jsx(Cee,{className:Gde(Wue({slot:"body"}),"p-0",e),...t}),qpe=({className:e,componentStyles:t,...n})=>Wh.jsx(Nee,{className:Gde("data-[role=user]:whitespace-pre-wrap mb-3 max-w-full",e),componentStyles:Ph(Wde,t??{}),...n}),Wpe=({className:e,...t})=>Wh.jsx(Ree,{className:Gde("flex items-center mt-2 mb-3",e),...t}),Ype=({className:e,...t})=>Wh.jsx(Pee,{className:Gde("mr-auto flex items-center gap-2",e),...t}),Kpe=({className:e,...t})=>Wh.jsx(Mee,{className:Gde(Due({size:"xs",variant:"outline"}),"text-xs h-[30px] text-gray-700 dark:text-gray-200 gap-1",e),...t}),Xpe=({className:e,...t})=>Wh.jsx(jee,{className:Gde(Due({variant:"iconButton",size:"sm"}),"data-[upvoted]:text-inkeep-primary-medium","data-[downvoted]:text-inkeep-primary-medium","data-[upvoted]:dark:text-inkeep-expanded-primary-300","data-[downvoted]:dark:text-inkeep-expanded-primary-300","dark:hover:text-inkeep-expanded-primary-300 px-2 text-md",e),...t}),Qpe=e=>{var t;const{message:n}=lB();return"assistant"===n.role&&(null==(t=n.links)?void 0:t.length)?Wh.jsx(Bee,{...e}):null},Zpe=({className:e,...t})=>Wh.jsx(Hee,{className:Gde("block text-xs font-medium my-2 text-gray-700 dark:text-gray-dark-300",e),...t}),Jpe=({className:e,...t})=>Wh.jsx($ee,{className:Gde("w-full relative flex flex-col gap-3 py-[1px]",e),...t}),ehe=({className:e,...t})=>Wh.jsx(Vee,{className:Gde(Fue({slot:"root"}),e),...t}),the=({className:e,...t})=>Wh.jsx(Wee,{className:Gde(Fue({slot:"breadcrumbs"}),e),...t}),nhe=({className:e,...t})=>Wh.jsx(Yee,{className:Gde(Fue({slot:"breadcrumbsIcon"}),e),...t}),rhe=({className:e,...t})=>Wh.jsx(Xee,{className:Gde(Fue({slot:"icon"}),e),...t}),ahe=({className:e,...t})=>Wh.jsx(Zee,{className:Gde(Fue({slot:"title"}),e),...t}),ohe=({className:e,...t})=>Wh.jsx(ete,{className:Gde(Fue({slot:"tag"}),e),...t}),ihe=({className:e,...t})=>Wh.jsx(nte,{className:Gde(Fue({slot:"description"}),e),...t}),she=({className:e,...t})=>Wh.jsx(ate,{className:Gde(Fue({slot:"descriptionPart"}),e),...t}),lhe=({className:e,...t})=>Wh.jsx(ite,{className:Gde(Fue({slot:"indicator"}),e),...t}),che=({className:e,...t})=>Wh.jsx(ste,{className:Gde("bg-white dark:bg-gray-dark-950 pt-6 pb-4","px-5 relative","before:absolute before:block before:top-0 before:left-0","before:pointer-events-none before:w-full before:h-3","before:bg-[linear-gradient(transparent,_white)] dark:before:bg-[linear-gradient(transparent,_var(--ikp-color-gray-dark-950))]","before:-translate-y-full",e),...t}),uhe=({className:e,...t})=>Wh.jsx(lte,{className:Gde("relative flex flex-col w-full p-2","rounded-lg items-stretch shadow-md dark:shadow-none","bg-gray-50 dark:bg-white-alpha-50",e),...t}),dhe=({className:e,...t})=>Wh.jsx(cte,{className:Gde("flex",e),...t}),phe=K.forwardRef((({className:e,...t},n)=>Wh.jsx(dte,{ref:n,className:Gde("min-h-[unset] overflow-hidden w-full resize-none","placeholder:text-gray-500 dark:placeholder:text-gray-dark-200","border-none outline-none shadow-none bg-transparent","px-3 py-2 ml-1 mr-2 max-h-[200px] overflow-y-auto disabled:cursor-not-allowed",e),...t}))),hhe=({className:e,...t})=>Wh.jsx(hte,{className:Gde(Due({}),"bg-transparent relative size-10 rounded-lg transition-all ease-linear","text-inkeep-primary-medium dark:text-inkeep-expanded-primary-500","active:bg-gray-300 dark:active:bg-white-alpha-100","hover:bg-gray-200 hover:text-inkeep-primary-strong","dark:hover:bg-white-alpha-100 dark:hover:text-inkeep-expanded-primary-300","disabled:text-gray-500 dark:disabled:text-white-alpha-200","disabled:cursor-not-allowed hover:disabled:[background:none] active:disabled:[background:none]",e),...t}),fhe=({className:e,...t})=>Wh.jsx(fte,{className:Gde(jue(),"text-inherit rotate-[-30deg]",e),...t}),mhe=({className:e,...t})=>Wh.jsx(gte,{className:Gde("flex items-center justify-between","flex-wrap gap-2 px-1 pt-2 pb-1",e),...t}),ghe=({className:e,...t})=>Wh.jsx(bte,{className:Gde("flex items-center gap-2 flex-wrap px-3 min-w-0",e),...t}),yhe=({className:e,...t})=>Wh.jsx(kte,{className:Gde(Lue({slot:"root"}),e),...t}),bhe=({className:e,...t})=>Wh.jsx(xte,{className:Gde(Lue({slot:"icon"}),e),...t}),vhe=({className:e,...t})=>Wh.jsx(_te,{className:Gde(Lue({slot:"title"}),e),...t}),khe=({className:e,...t})=>Wh.jsx(Tte,{className:Gde(Lue({slot:"delete"}),e),...t}),whe=({className:e,...t})=>Wh.jsx(Cte,{className:Gde("flex items-center justify-between","gap-2 flex-wrap px-3",e),...t}),xhe=Ate,Ehe=({className:e,...t})=>Wh.jsx(Nte,{className:Gde("cursor-pointer text-sm text-gray-600","dark:text-white-alpha-600",e),...t}),_he=({className:e,...t})=>Wh.jsx(Rte,{className:Gde("bg-white text-gray-800 fill-white","dark:bg-gray-dark-800 dark:text-white-alpha-950 dark:fill-gray-dark-800","shadow-[0_8px_30px_rgba(0,0,0,0.12)] z-dropdown","px-3 py-2 rounded-md text-sm font-normal max-w-[200px]",e),...t}),She=({className:e,...t})=>Wh.jsx(Pte,{className:Gde("contents",e),...t}),The=({className:e,...t})=>Wh.jsx(Lte,{className:Gde(Due({variant:"outline",size:"xs"}),"light:text-gray-700 gap-1",e),...t}),Che=e=>{const{onOpenChange:t,...n}=e,{selectInput:r,isOpen:a,onClose:o,selectedInput:i}=qj();return Wh.jsx(Mte,{open:a&&null!==i,onOpenChange:L9(t,(e=>{e||(o(),r(null))})),...n})},Ahe=({className:e,...t})=>Wh.jsx(Fte,{className:Gde(Wue({slot:"overlay"}),e),...t}),Nhe=({className:e,...t})=>Wh.jsx(jte,{className:Gde(Wue({slot:"content"}),"my-6 md:my-12 top-0 left-[unset] transform-none relative","p-8 md:p-10 max-w-2xl",e),...t}),Ihe=({className:e,...t})=>Wh.jsx(Bte,{className:Gde(Wue({slot:"header"}),"px-0 pt-0 pb-8 gap-y-2","font-semibold",e),...t}),Rhe=({className:e,...t})=>Wh.jsx(Hte,{className:Gde("w-full semibold",e),...t}),Ohe=({className:e,...t})=>Wh.jsx($te,{className:Gde("text-gray-700 dark:text-white-alpha-700","text-sm font-normal w-full",e),...t}),Phe=e=>{var t;const{children:n,...r}=e,{selectedInput:a}=qj(),o=null==(t=null==a?void 0:a.workflowModalProps)?void 0:t.modalHelpElement;return o?Wh.jsx(Gte,{asChild:!n,children:n||o,...r}):null},Dhe=({className:e,...t})=>Wh.jsx(Vte,{className:Gde(Wue({slot:"close"}),e),...t}),Lhe=({className:e,...t})=>Wh.jsx(qte,{className:Gde(Wue({slot:"body"}),"p-0",e),...t}),Mhe=({className:e,...t})=>Wh.jsx(Yte,{className:Gde("flex flex-col gap-8",e),...t}),Fhe=({className:e,...t})=>Wh.jsx(Kte,{className:Gde("flex flex-col gap-2",e),...t}),jhe=({className:e,...t})=>Wh.jsx(Qte,{className:Gde("text-sm font-medium text-gray-700 dark:text-white-alpha-700",e),...t}),Bhe=({className:e,...t})=>Wh.jsx(Jte,{className:Gde("h-10 px-4 rounded-md border","focus:outline-none focus:[--shadow-color:theme(colors.blue.500)]","data-[invalid]:[--shadow-color:theme(colors.red.500)]","shadow-[0_0_0_2px_var(--shadow-color)]",e),...t}),zhe=({className:e,...t})=>Wh.jsx(tne,{className:Gde("text-sm text-red-500",e),...t}),Hhe=({className:e,...t})=>Wh.jsx(nne,{className:Gde("flex flex-col gap-2",e),...t}),Uhe=({className:e,...t})=>Wh.jsx(ane,{className:Gde("text-sm font-medium text-gray-700 dark:text-white-alpha-700",e),...t}),$he=({className:e,...t})=>Wh.jsx(ine,{className:Gde(Bue({size:"md",variant:"outline"}),"min-h-20 px-4 py-2",e),...t}),Ghe=({className:e,...t})=>Wh.jsx(lne,{className:Gde("text-sm text-red-500",e),...t}),Vhe=({className:e,...t})=>Wh.jsx(cne,{className:Gde(Due({preset:"neutralFilled"}),"ml-auto",e),...t}),qhe=({className:e,...t})=>Wh.jsx(une,{className:Gde("mt-4 flex items-start justify-between flex-wrap-reverse gap-2.5",e),...t}),Whe=({className:e,...t})=>Wh.jsx(dne,{className:Gde("flex items-center gap-2.5 flex-wrap",e),...t}),Yhe=({className:e,...t})=>Wh.jsx(pne,{className:Gde("flex items-center whitespace-nowrap",e),...t}),Khe=({className:e,...t})=>Wh.jsx(hne,{className:Gde("text-xs md:text-sm text-gray-500 dark:text-white-alpha-600",e),...t}),Xhe=({className:e,...t})=>Wh.jsx(fne,{className:Gde("text-gray-500 dark:text-white-alpha-600","w-5 ml-1.5 mr-0.5",e),...t}),Qhe=({className:e,...t})=>Wh.jsx(mne,{className:Gde(zue(),"inline-flex text-xs md:text-sm text-gray-500","dark:text-white-alpha-600 font-medium",e),...t}),Zhe=Gde(Due({size:"xs",variant:"outline"}),"text-gray-700 dark:text-white-alpha-700"),Jhe=({className:e,...t})=>Wh.jsx(yne,{className:Gde(Zhe,e),...t}),efe=({className:e,...t})=>Wh.jsx(vne,{className:Gde("cursor-pointer",e),...t}),tfe=({className:e,...t})=>Wh.jsx(wne,{className:Gde("bg-white text-gray-800 fill-white","dark:bg-gray-dark-800 dark:text-white-alpha-900 dark:fill-gray-dark-800","shadow-[0_8px_30px_rgba(0,0,0,0.12)]","px-2 py-3 rounded-md text-sm font-normal",e),...t}),nfe=e=>{const{children:t,...n}=e,{aiChatSettings:r}=nP(),{getHelpOptions:a}=r;if(!a||0===(a??[]).length)return null;const{_pinned:o,_unpinned:i}=a.reduce(((e,t)=>{const n=t.isPinnedToToolbar?"_pinned":"_unpinned";return{...e,[n]:[...e[n],t]}}),{_pinned:[],_unpinned:[]}),s=1===i.length?[...o,i[0]]:o,l=1===i.length?[]:i,c=function(){const[e,t]=K.useState(!1);return{open:e,setOpen:t}}();return Wh.jsx(eB,{value:c,children:Wh.jsx(xne,{open:c.open,onOpenChange:c.setOpen,children:CL(t,{pinned:s,unpinned:l}),...n})})},rfe=({className:e,...t})=>Wh.jsx(Sne,{className:Gde(Zhe,e),...t}),afe=({className:e,...t})=>Wh.jsx(Cne,{className:Gde(Zhe,e),...t}),ofe=({className:e,...t})=>Wh.jsx(Nne,{className:Gde(Yue({slot:"content"}),"gap-3 px-3 py-4 ","w-[254px] text-sm font-normal",e),...t}),ife=({className:e,...t})=>Wh.jsx(Ine,{className:Gde(Yue({slot:"arrow"}),e),...t}),sfe=({className:e,...t})=>Wh.jsx(Rne,{className:Gde("flex items-center cursor-pointer hover:underline",e),...t}),lfe=({className:e,...t})=>Wh.jsx(Pne,{className:Gde("mr-2 text-inkeep-primary-medium",e),...t}),cfe=e=>{const{onOpenChange:t,...n}=e,{currentFeedback:r,setCurrentFeedback:a}=PL();return Wh.jsx(Dne,{open:null!==r,onOpenChange:L9(t,(()=>a(null))),...n})},ufe=({className:e,...t})=>Wh.jsx(Lne,{className:Gde(Wue({slot:"overlay"}),e),...t}),dfe=({className:e,...t})=>Wh.jsx(Mne,{className:Gde(Wue({slot:"content"}),"my-6 md:my-12 top-0 left-[unset] transform-none relative","p-8 md:p-10 max-w-[480px]",e),...t}),pfe=({className:e,...t})=>Wh.jsx(Fne,{className:Gde(Wue({slot:"header"}),"px-0 pt-0 pb-8","font-semibold",e),...t}),hfe=({className:e,...t})=>Wh.jsx(jne,{className:Gde(Wue({slot:"close"}),e),...t}),ffe=({className:e,...t})=>Wh.jsx(Bne,{className:Gde(Wue({slot:"body"}),"p-0",e),...t}),mfe=({className:e,...t})=>Wh.jsx(Hne,{className:Gde("flex flex-col gap-8",e),...t}),gfe=({className:e,...t})=>Wh.jsx($ne,{className:Gde("flex flex-wrap items-center","gap-[1rem_0.5rem]",e),...t}),yfe=({className:e,...t})=>Wh.jsx(Vne,{className:Gde(Mue({slot:"root"}),e),...t}),bfe=({className:e,...t})=>Wh.jsx(qne,{className:Gde(Mue({slot:"indicator"}),e),...t}),vfe=({className:e,...t})=>Wh.jsx(Yne,{className:Gde("select-none cursor-pointer font-medium text-sm","text-gray-700 dark:text-white-alpha-700",e),...t}),kfe=({className:e,...t})=>Wh.jsx(Xne,{className:Gde("flex-[0_0_100%]","min-h-20 py-2 border rounded-md","px-4",e),...t}),wfe=({className:e,...t})=>Wh.jsx(Qne,{className:Gde(Due({preset:"neutralFilled"}),"ml-auto",e),...t}),xfe=({className:e,...t})=>Wh.jsx(Jne,{className:Gde("w-full overflow-y-auto",e),...t}),Efe=({className:e,...t})=>Wh.jsx(tre,{className:Gde(Kue({section:"content"}),"relative pt-4 pb-8 gap-8","items-start justify-center w-full","px-6 ikp-md:px-10 ikp-md:pb-14",e),...t}),_fe=({className:e,...t})=>Wh.jsx(rre,{className:Gde(Due({variant:"ghost"}),"absolute right-1 top-1","text-xl text-gray-500 dark:text-white-alpha-500 w-10 h-10 z-modal",e),...t}),Sfe=({className:e,...t})=>Wh.jsx(are,{className:Gde("mt-12 flex flex-col gap-6",e),...t}),Tfe=({className:e,...t})=>Wh.jsx(ire,{className:Gde("font-semibold text-xl leading-5",e),...t}),Cfe=({className:e,...t})=>Wh.jsx(lre,{className:Gde("text-gray-700 dark:text-white-alpha-700 text-sm",e),...t}),Afe=({className:e,...t})=>Wh.jsx(ure,{className:Gde("w-full",e),...t}),Nfe=({className:e,...t})=>Wh.jsx(pre,{className:Gde("mb-8 flex flex-col gap-2 data-[hidden]:hidden","data-[input-type=checkbox]:flex-row data-[input-type=checkbox]:items-center",e),...t}),Ife=({className:e,...t})=>Wh.jsx(fre,{className:Gde("font-medium text-sm text-gray-700","dark:text-white-alpha-700 ","font-medium relative","data-[required]:after:absolute",'data-[required]:after:[content:"*"]',"data-[required]:after:ml-1","data-[required]:after:mt-0","data-[required]:after:text-red-500","dark:data-[required]:after:text-red-300",e),...t}),Rfe=({className:e,...t})=>Wh.jsx(gre,{className:Gde(Bue({size:"md",variant:"outline"}),e),...t}),Ofe=({className:e,...t})=>Wh.jsx(yre,{className:Gde(Bue({size:"md",variant:"outline"}),e),...t}),Pfe=({className:e,...t})=>Wh.jsx(vre,{className:Gde(Bue({size:"md",variant:"outline"}),"text-sm pl-2 file:h-full file:cursor-pointer py-0","file:bg-transparent file:border-none file:font-medium","file:text-sm file:text-gray-700 dark:file:text-white-alpha-700",e),...t}),Dfe=({className:e,...t})=>Wh.jsx(kre,{className:Gde(Bue({size:"md",variant:"outline"}),"min-h-20 px-4 py-2",e),...t}),Lfe=({className:e,...t})=>Wh.jsx(xre,{className:Gde(Mue({slot:"root"}),e),...t}),Mfe=({className:e,...t})=>Wh.jsx(Ere,{className:Gde(Mue({slot:"indicator"}),e),...t}),Ffe=e=>{const{field:t,error:n,fieldProps:r}=Zj(),{onValueChange:a,...o}=e;return Wh.jsx(_re,{name:t.name,"data-invalid":SL(!!n),value:r.value,onValueChange:L9(a,r.onChange),...o})},jfe=({className:e,...t})=>Wh.jsx(Sre,{className:Gde(Xue({slot:"trigger"}),e),...t}),Bfe=e=>{const{field:t}=Zj();return Wh.jsx(Tre,{placeholder:"placeholder"in t?t.placeholder:void 0,...e})},zfe=({className:e,...t})=>Wh.jsx(Cre,{className:Gde("h-4 w-4 opacity-45",e),...t}),Hfe=({className:e,...t})=>Wh.jsx(Are,{className:Gde(Xue({slot:"content"}),e),...t}),Ufe=({className:e,...t})=>Wh.jsx(Nre,{className:Gde(Xue({slot:"viewport"}),e),...t}),$fe=({className:e,...t})=>Wh.jsx(Ire,{className:Gde(Xue({slot:"item"}),e),...t}),Gfe=Rre,Vfe=({className:e,...t})=>Wh.jsx(Ore,{className:Gde(Xue({slot:"itemIndicator"}),e),...t}),qfe=({className:e,...t})=>Wh.jsx(Dre,{className:Gde("text-sm flex items-center text-red-500 dark:text-red-300",e),...t}),Wfe=({className:e,...t})=>Wh.jsx(Mre,{className:Gde("text-red-500 dark:text-red-300",e),...t}),Yfe=({className:e,...t})=>Wh.jsx(Fre,{className:Gde("flex items-center justify-end gap-6 w-full",e),...t}),Kfe=({className:e,...t})=>Wh.jsx(Bre,{className:Gde(Due({variant:"outline"}),e),...t}),Xfe=({className:e,...t})=>Wh.jsx(Hre,{className:Gde(Due({preset:"neutralFilled"}),e),...t}),Qfe=({className:e,...t})=>Wh.jsx($re,{className:Gde("flex flex-col items-center justify-center h-auto","m-auto px-6 py-8 ikp-md:py-14 ikp-md:px-10",e),...t}),Zfe=({className:e,...t})=>Wh.jsx(Vre,{className:Gde("mb-6 font-bold tracking-tight","text-3xl md:text-4xl leading-6 md:leading-5",e),...t}),Jfe=e=>{var t;const{form:n}=dL();return Wh.jsx(qre,{children:null==(t=null==n?void 0:n.successView)?void 0:t.message,...e})},eme=({className:e,...t})=>Wh.jsx(Yre,{className:Gde(Due({preset:"neutralFilled"}),"w-full mt-12 gap-2 shrink-0",e),...t}),tme=({className:e,...t})=>Wh.jsx(Sae,{...t,className:Gde("w-[--width] h-full relative bg-white dark:bg-gray-dark-950","data-[position=left]:pr-1 data-[position=left]:border-r data-[position=left]:mr-1","data-[position=right]:pl-1 data-[position=right]:border-l data-[position=right]:ml-1","data-[state=open]:data-[position=left]:animate-sidebar-in-left","data-[state=open]:data-[position=right]:animate-sidebar-in-right","data-[state=closed]:data-[position=left]:animate-sidebar-out-left","data-[state=closed]:data-[position=right]:animate-sidebar-out-right",e)}),nme=({className:e,...t})=>Wh.jsx(Cae,{className:Gde("px-1 bg-transparent opacity-0 hover:opacity-100","cursor-ew-resize","absolute top-0 bottom-0 z-[1]",'[[data-position="left"]>&]:-right-1','[[data-position="right"]>&]:-left-1','after:content-[""] after:absolute after:top-0 after:bottom-0 after:w-0.5 after:bg-inkeep-primary-medium dark:after:bg-inkeep-primary-light [[data-position="right"]>&]:after:right-1 [[data-position="left"]>&]:after:left-1',"data-[state=closed]:opacity-0 data-[state=closed]:pointer-events-none","data-[state=open]:pointer-events-auto","transition-opacity duration-200",e),...t}),rme=({className:e,...t})=>Wh.jsx(Nae,{className:Gde(Kue({section:"header"}),"w-full flex flex-row items-center px-3 py-1.5","bg-white dark:bg-gray-dark-950","after:absolute","after:left-0","after:top-full","after:h-3","after:w-full","after:text-white","after:dark:text-gray-dark-950","after:bg-[linear-gradient(currentColor,_transparent)]","after:z-start",e),...t}),ame=({className:e,...t})=>Wh.jsx(Rae,{className:Gde(Due({variant:"ghost",size:"xs"}),"relative inset-[unset] w-6 ml-auto text-lg text-gray-500 dark:text-white-alpha-500 px-0",e),...t});function ome(){const{searchSettings:{tabs:e}}=nP();return Wh.jsxs("div",{className:"flex flex-col h-full",children:[Wh.jsxs("div",{className:Gde("h-[calc(100%-24px)]"),children:[Wh.jsx("div",{className:"flex px-5 py-1 gap-3 data-[hidden]:hidden","data-hidden":Vde(0===e.length),children:Array.from({length:2}).map(((e,t)=>Wh.jsx("div",{className:Gde(Que(),"h-[27.88px] w-16 rounded-full")},t)))}),Wh.jsxs("div",{className:"flex px-5 py-1 gap-5 h-full",children:[Wh.jsx("div",{className:"flex flex-col flex-1 [[data-view=dual-pane]_&]:flex-[0_0_44%]",children:Array.from({length:4}).map(((e,t)=>Wh.jsx("div",{className:"flex items-center pb-2.5 w-full",children:Wh.jsx("div",{className:Gde(Que(),"h-20 rounded-lg grow-[1]")})},t)))}),Wh.jsx("div",{className:Gde(Que(),"h-full w-full rounded-md","hidden [[data-view=dual-pane]_&]:block")})]})]}),Wh.jsx("div",{className:"flex pt-1 pb-3 px-5 justify-self-end",children:Wh.jsx("div",{className:Gde(Que(),"h-[24px] w-40 rounded-md")})})]})}const ime=e=>Wh.jsx(zoe,{...e}),sme=({className:e,...t})=>Wh.jsx(Nie,{className:Gde("data-[hidden]:hidden rounded-md flex","bg-white dark:bg-gray-dark-950",e),...t}),lme=({className:e,...t})=>Wh.jsx(Rie,{className:Gde("data-[hidden]:hidden flex flex-col w-full","[--footer-height:theme(spacing.9)]","data-[mobile]:[--input-height:theme(spacing.20)]","[--ask-ai-trigger-height:0px]","[[data-show-ask-ai-card]_&]:[--ask-ai-trigger-height:theme(spacing.11)]",e),...t}),cme=Pie,ume=({className:e,...t})=>Wh.jsx(Die,{className:Gde("flex items-center w-full px-5 pt-3 pb-3 gap-3","[[data-mobile]_&]:max-h-[var(--input-height)]",e),...t}),dme=({className:e,...t})=>Wh.jsx(Lie,{className:Gde("min-w-5 w-5 text-xl","text-gray-500 dark:text-white-alpha-600",e),...t}),pme=({className:e,...t})=>Wh.jsx(Fie,{className:Gde("min-h-[38px] overflow-hidden w-full resize-none","py-1.5 max-h-[10vh] placeholder:text-gray-500","w-full dark:placeholder:text-gray-dark-200","border-none outline-none shadow-none bg-transparent",e),...t}),hme=({className:e,...t})=>Wh.jsx(Bie,{className:Gde("min-w-5 w-5 text-xl","text-gray-500 dark:text-white-alpha-600","animate-spin",e),...t}),fme=({className:e,...t})=>Wh.jsx(Hie,{className:Gde(Fue({slot:"root"}),"mx-5 w-[calc(100%_-_theme(spacing.10))]","mb-4 h-11 cursor-pointer","h-[var(--ask-ai-trigger-height)]","grid-template-[none] flex items-center",e),...t}),mme=({className:e,...t})=>Wh.jsx($ie,{className:Gde("[grid-area:icon] h-5 w-5 flex-shrink-0","[--start-color:theme(colors.inkeep-expanded-primary.300)]","[--end-color:theme(colors.inkeep-expanded-primary.700)]","dark:[--start-color:theme(colors.inkeep-expanded-primary.50)]","dark:[--end-color:theme(colors.inkeep-expanded-primary.300)]",e),...t}),gme=({className:e,...t})=>Wh.jsx(Gie,{className:Gde(Fue({slot:"title"}),"font-medium text-gray-700",e),...t}),yme=({className:e,...t})=>Wh.jsx(Vie,{className:Gde("font-semibold !bg-clip-text text-transparent ml-2","animate-shine [background:linear-gradient(270deg,theme(colors.inkeep-primary.stronger-light),transparent)_-200%_50%_/_25%_100%_no-repeat,theme(colors.inkeep-expanded-primary.800)] ","dark:[background:linear-gradient(270deg,theme(colors.inkeep-expanded-primary.100),transparent)_-200%_50%_/_25%_100%_no-repeat,theme(colors.inkeep-expanded-primary.400)]",e),...t}),bme=({className:e,...t})=>Wh.jsx(qie,{className:Gde(Fue({slot:"indicator"}),"ml-1 opacity-100 text-inkeep-primary-stronger-light group-selected:text-inkeep-primary-strong dark:text-gray-dark-300 dark:group-selected:text-inkeep-expanded-primary-300 ",e),...t}),vme=({className:e,...t})=>Wh.jsx(Wie,{className:Gde("text-xs flex-shrink-0 ml-auto","group-selected:text-inkeep-primary-strong dark:text-gray-dark-300 dark:group-selected:text-inkeep-expanded-primary-300","text-inkeep-primary-medium-subtle bg-gray-500 bg-clip-text dark:bg-white-alpha-800",e),...t}),kme=({className:e,...t})=>Wh.jsx(Kie,{className:Gde(Kue({section:"content"}),"h-0 max-h-full","data-[has-content]:h-[min(calc(85vh_-_72px),calc(850px_-_72px_-_275px))]","md:data-[dual-pane-search-expanded]:h-[min(calc(85vh_-_72px),calc(900px_-_72px_-_135px))]","[[data-mobile]_&]:h-[calc(100vh-var(--input-height)-var(--footer-height)-var(--ask-ai-trigger-height))]","transition-all duration-300 ease-in-out data-[has-content]:pb-2",e),...t}),wme=({className:e,...t})=>Wh.jsx(Qie,{className:Gde("group mb-1 relative transition-all w-full h-full",e),children:Wh.jsx(ome,{}),...t}),xme=({className:e,...t})=>Wh.jsx(Jie,{className:Gde("flex w-full h-full","overflow-hidden relative grow-[2]","items-center justify-center text-gray-600","dark:text-gray-dark-400 mt-8",e),...t}),Eme=({className:e,...t})=>Wh.jsx(tse,{className:Gde("shrink-0 max-w-full","flex gap-3 px-5 pb-2 pt-0","overflow-x-auto [scrollbar-width:thin]",e),...t}),_me=({className:e,...t})=>Wh.jsx(rse,{className:Gde("px-3 text-1sm font-medium rounded-full shrink-0","py-1 transition-all duration-200 leading-snug","border border-gray-300 dark:border-gray-dark-500","hover:bg-gray-50 dark:hover:bg-white-alpha-50","data-[state=active]:bg-inkeep-primary-light-subtle","hover:data-[state=active]:bg-inkeep-primary-light-subtle","data-[state=active]:text-inkeep-expanded-primary-900","data-[state=active]:border-inkeep-primary-medium-subtle","dark:data-[state=active]:bg-white-alpha-100","dark:hover:data-[state=active]:bg-white-alpha-100","dark:data-[state=active]:text-inkeep-expanded-primary-300","dark:data-[state=active]:border-inkeep-expanded-primary-300","focus:outline-inkeep-expanded-primary-700 dark:focus:outline-inkeep-expanded-primary-300",e),...t}),Sme=({className:e,...t})=>Wh.jsx(ase,{className:Gde("flex overflow-hidden h-full",e),...t}),Tme=({className:e,...t})=>Wh.jsx(ise,{className:Gde("overflow-hidden h-full first:w-full","first:[[data-view=dual-pane]_&]:flex-1 md:first:[[data-view=dual-pane]_&]:flex-[0_0_44%]",'befter:content-[""] befter:absolute befter:inset-x-0',"befter:h-10 befter:pointer-events-none","befter:transition-opacity befter:duration-300","befter:ease-in-out ","before:top-0 after:bottom-0","before:bg-[linear-gradient(white,_transparent)] after:bg-[linear-gradient(transparent,_white)] ","dark:before:bg-[linear-gradient(var(--ikp-color-gray-dark-950),_transparent)] dark:after:bg-[linear-gradient(transparent,_var(--ikp-color-gray-dark-950))]","has-[[data-scroll-top]]:before:opacity-0","has-[[data-scroll-bottom]]:after:opacity-0",e),...t}),Cme=({className:e,...t})=>Wh.jsx(lse,{className:Gde("h-full w-full rounded-[inherit]",e),...t}),Ame=({className:e,...t})=>Wh.jsx(cse,{className:Gde("flex select-none touch-none p-0.5","transition-colors duration-[160ms] ease-in-out","w-2.5 border-l border-l-transparent",e),...t}),Nme=({className:e,...t})=>Wh.jsx(use,{className:Gde("relative flex-1 rounded-full","bg-gray-300 dark:bg-white-alpha-200",e),...t}),Ime=dse,Rme=({className:e,...t})=>Wh.jsx(hse,{className:Gde("w-full flex flex-col","items-center gap-2.5 h-full shrink-0","px-5 py-1 content-center -my-[1px]",e),...t}),Ome=({className:e,...t})=>Wh.jsx(mse,{className:Gde(Fue({slot:"root"}),e),...t}),Pme=({className:e,...t})=>Wh.jsx(yse,{className:Gde(Fue({slot:"breadcrumbs"}),e),...t}),Dme=({className:e,...t})=>Wh.jsx(bse,{className:Gde(Fue({slot:"breadcrumbsIcon"}),e),...t}),Lme=({className:e,...t})=>Wh.jsx(kse,{className:Gde(Fue({slot:"icon"}),e),...t}),Mme=({className:e,...t})=>Wh.jsx(xse,{className:Gde(Fue({slot:"title"}),e),...t}),Fme=({className:e,...t})=>Wh.jsx(_se,{className:Gde(Fue({slot:"tag"}),e),...t}),jme=({className:e,...t})=>Wh.jsx(Tse,{className:Gde(Fue({slot:"description"}),e),...t}),Bme=({className:e,...t})=>Wh.jsx(Ase,{className:Gde(Fue({slot:"descriptionPart"}),e),...t}),zme=({className:e,...t})=>Wh.jsx(Ise,{className:Gde(Fue({slot:"indicator"}),e),...t}),Hme=({className:e,...t})=>Wh.jsx(Ose,{className:Gde("flex-1 min-w-0 break-words pt-3 pb-4 pr-10 pl-5","hidden md:flex flex-col gap-6",e),...t}),Ume=({className:e,...t})=>Wh.jsx(Pse,{className:Gde("flex flex-col gap-5",e),...t}),$me=({className:e,...t})=>Wh.jsx(Lse,{className:Gde("inline-block",e),...t}),Gme=({className:e,...t})=>Wh.jsx(Fse,{className:Gde("text-3xl leading-snug tracking-tight","font-semibold hover:text-inkeep-primary-stronger","dark:hover:text-inkeep-expanded-primary-100",e),...t}),Vme=({className:e,...t})=>Wh.jsx(Bse,{className:Gde("inline-block ml-2 mb-2 tracking-tight text-gray-500 dark:text-white-alpha-500",e),...t}),qme=({className:e,...t})=>Wh.jsx(zse,{className:Gde(Fue({slot:"breadcrumbs"}),"!line-clamp-none whitespace-normal text-gray-500 dark:text-gray-dark-200 text-sm",e),...t}),Wme=({className:e,...t})=>Wh.jsx(Hse,{className:Gde(Fue({slot:"breadcrumbsIcon"}),e),...t}),Yme=({className:e,componentStyles:t,...n})=>Wh.jsx($se,{className:Gde("max-w-full text-gray-700 dark:text-gray-dark-100 [&_em]:font-bold [&_em]:not-italic",e),componentStyles:Ph(Wde,t??{}),...n}),Kme=({className:e,...t})=>Wh.jsx(Vse,{className:Gde("flex flex-col gap-3",e),...t}),Xme=({className:e,...t})=>Wh.jsx(qse,{className:Gde("text-xs uppercase font-semibold tracking-widest","text-gray-500 dark:text-white-alpha-500",e),...t}),Qme=({className:e,...t})=>Wh.jsx(Yse,{className:Gde("flex flex-col gap-4",e),...t}),Zme=({className:e,...t})=>Wh.jsx(Xse,{className:Gde("flex items-center gap-1 text-gray-600 dark:text-white-alpha-600 font-medium ",""+(t.href?"cursor-pointer hover:text-gray-800 dark:hover:text-white-alpha-800 dark:data-[is-match]:hover:text-inkeep-expanded-primary-200 data-[is-match]:hover:text-inkeep-expanded-primary-800 ":""),"data-[is-match]:text-inkeep-expanded-primary-700","dark:data-[is-match]:text-inkeep-expanded-primary-300",e),...t}),Jme=({className:e,...t})=>Wh.jsx(Qse,{className:Gde(e),...t}),ege=({className:e,...t})=>Wh.jsx(Jse,{className:Gde(e),...t}),tge=({className:e,...t})=>Wh.jsx(ele,{className:Gde("h-3 !min-h-0 !min-w-0",e),...t}),nge=({className:e,...t})=>Wh.jsx(nle,{className:Gde("justify-self-end","px-5 pt-1 pb-3","[[data-mobile]_&]:py-0","[[data-mobile]_&]:items-center","[[data-mobile]_&]:h-[var(--footer-height)]","hidden data-[has-results]:flex",e),...t}),rge=({className:e,...t})=>Wh.jsx(rle,{className:Gde("flex items-center whitespace-nowrap",e),...t}),age=({className:e,...t})=>Wh.jsx(ale,{className:Gde("text-xs md:text-sm text-gray-500 dark:text-white-alpha-600",e),...t}),oge=({className:e,...t})=>Wh.jsx(ole,{className:Gde("text-gray-500 dark:text-white-alpha-600","w-5 ml-1.5 mr-0.5",e),...t}),ige=({className:e,...t})=>Wh.jsx(ile,{className:Gde(zue(),"inline-flex text-xs md:text-sm text-gray-500","dark:text-white-alpha-600 font-medium",e),...t}),sge=e=>{const{onOpenChange:t,config:n,...r}=e,a=(e=>{const{isOpen:t,onOpenChange:n,defaultOpen:r=!1,shortcutKey:a,triggerSelector:o="[data-inkeep-modal-trigger]"}=e??{},{logEvent:i}=bP(),[s=r,l]=OB({prop:t,defaultProp:t,onChange:n});Kre({triggerSelector:o,onTriggerClick:()=>l(!s)});const c=K.useRef(!0);return K.useEffect((()=>{c.current?c.current=!1:i({eventName:s?"modal_opened":"modal_closed",properties:{}})}),[s]),K.useEffect((()=>{const e=e=>{a&&(e.metaKey||e.ctrlKey)&&e.key.toLowerCase()===a.toLowerCase()&&(e.preventDefault(),e.stopPropagation(),l(!0)),"Escape"===e.key&&t&&(e.preventDefault(),l(!1))};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)}),[a,l,t]),{isOpen:s,setOpen:l,shortcutKey:a}})(n);return Wh.jsx(oL,{modal:a,children:Wh.jsx(sle,{open:a.isOpen,onOpenChange:L9(t,(e=>a.setOpen(e))),...r})})},lge=({className:e,...t})=>Wh.jsx(lle,{className:Gde(Wue({slot:"overlay"}),e),...t}),cge=({className:e,...t})=>Wh.jsx(ule,{className:Gde(Wue({slot:"content"}),"w-[min(90vw,720px)]","has-[[data-dual-pane-search-expanded]]:w-[min(90vw,1000px)] transition-width duration-300",e),...t}),uge=({className:e,...t})=>Wh.jsx(ple,{className:Gde(Wue({slot:"close"}),Due({variant:"ghost",size:"xs"}),"relative inset-[unset] w-6 ml-auto text-lg text-gray-500 dark:text-white-alpha-500 px-0","md:hidden",e),...t}),dge=({className:e,...t})=>Wh.jsx(eue,{className:Gde("fixed right-6 bottom-6 z-50 mr-[var(--removed-body-scroll-bar-size)]",e),...t}),pge=({className:e,...t})=>Wh.jsx(tue,{className:Gde("bg-inkeep-primary-text-bold dark:bg-gray-dark-600 rounded-full px-[18px] py-3 text-white font-medium flex items-center space-x-2 shadow-2xl dark:shadow-none transition-transform ease-in-out hover:scale-110",e),...t}),hge=({className:e,...t})=>Wh.jsx(nue,{className:Gde("flex items-center",e),...t}),fge=({className:e,...t})=>Wh.jsx(oue,{className:Gde("data-[type=icon]:[--start-color:theme(colors.inkeep-expanded-primary.50)]","data-[type=icon]:[--end-color:theme(colors.inkeep-expanded-primary.300)]","h-6 w-6",e),...t}),mge=({className:e,...t})=>Wh.jsx(rue,{className:Gde("",e),...t}),gge=({className:e,...t})=>Wh.jsx(iue,{className:Gde("md:min-w-[min(320px,100%)] w-full h-full min-h-9",e),...t}),yge=({className:e,...t})=>Wh.jsx(sue,{className:Gde("rounded-md border px-3 min-w-0 min-h-9 flex items-center justify-between gap-2 h-full w-full hover:border-gray-300 dark:hover:border-white-alpha-300 transition-colors",e),...t}),bge=({className:e,...t})=>Wh.jsx(lue,{className:Gde("flex items-center gap-2 min-w-0",e),...t}),vge=({className:e,...t})=>Wh.jsx(uue,{className:Gde("text-md text-gray-500 dark:text-white-alpha-600",e),...t}),kge=({className:e,...t})=>Wh.jsx(due,{className:Gde("text-gray-500 dark:text-white-alpha-600 text-xl",e),...t}),wge=({className:e,...t})=>Wh.jsx(pue,{className:Gde("text-sm text-gray-400 dark:text-white-alpha-500 font-bold flex items-center gap-0.5",e),...t}),xge=({className:e,...t})=>Wh.jsx(bue,{className:Gde("",e),...t}),Ege=({className:e,...t})=>Wh.jsx(fue,{className:Gde("",e),...t}),_ge=e=>Wh.jsx(kle,{...e}),Sge=({className:e,...t})=>Wh.jsx(Tle,{className:Gde("max-w-full border divide-y","rounded-xl shadow h-full max-h-full","bg-white dark:bg-gray-dark-950","flex flex-col",e),...t}),Tge=({className:e,...t})=>Wh.jsx(Cle,{className:Gde("px-5 py-4 font-medium shrink-0",e),...t}),Cge=({className:e,...t})=>Wh.jsx(Ale,{className:Gde("flex-1 overflow-hidden",e),...t}),Age=({className:e,...t})=>Wh.jsx(Nle,{className:Gde("h-full",e),...t}),Nge=({className:e,...t})=>Wh.jsx(Rle,{className:Gde("h-full w-full rounded-[inherit] px-5","[&_[data-part=grid]]:px-1","[&_[data-part=grid]]:divide-y",e),...t}),Ige=({className:e,...t})=>Wh.jsx(Ole,{className:Gde("flex select-none touch-none p-0.5","transition-colors duration-[160ms] ease-in-out","w-2.5 border-l border-l-transparent",e),...t}),Rge=({className:e,...t})=>Wh.jsx(Ple,{className:Gde("relative flex-1 rounded-full","bg-gray-300 dark:bg-white-alpha-200",e),...t}),Oge=Dle,Pge=({className:e,...t})=>Wh.jsx(Mle,{className:Gde("flex flex-col items-center","justify-center mx-1 pt-12 pb-6",e),...t}),Dge=({className:e,...t})=>Wh.jsx(jle,{className:Gde("w-6 h-6 text-green-500 mb-5",e),...t}),Lge=({className:e,...t})=>Wh.jsx(zle,{className:Gde("text-xl font-semibold","mb-3 tracking-tight",e),...t}),Mge=({className:e,...t})=>Wh.jsx(Ule,{className:Gde("text-gray-800 dark:text-white-alpha-950",e),...t}),Fge=({className:e,...t})=>Wh.jsx($le,{className:Gde("w-full flex flex-col py-6",e),...t}),jge=({className:e,...t})=>Wh.jsx(qle,{className:Gde("text-gray-700 dark:text-white-alpha-700 text-sm",e),...t}),Bge=({className:e,...t})=>Wh.jsx(Wle,{className:Gde("w-full gap-8",e),...t}),zge=({className:e,...t})=>Wh.jsx(Kle,{className:Gde(Due({preset:"neutralFilled",size:"sm"}),"ml-auto data-[loading]:cursor-wait","data-[submitted]:hidden",e),...t}),Hge=({className:e,...t})=>Wh.jsx(Qle,{className:Gde("mb-8 flex flex-col gap-2 data-[hidden]:hidden","data-[input-type=checkbox]:flex-row data-[input-type=checkbox]:items-center",e),...t}),Uge=({className:e,...t})=>Wh.jsx(Jle,{className:Gde("font-medium text-sm text-gray-700","dark:text-white-alpha-700 ","font-medium relative","data-[required]:after:absolute",'data-[required]:after:[content:"*"]',"data-[required]:after:ml-1","data-[required]:after:mt-0","data-[required]:after:text-red-500","dark:data-[required]:after:text-red-300",e),...t}),$ge=({className:e,...t})=>Wh.jsx(tce,{className:Gde(Bue({size:"sm",variant:"outline"}),e),...t}),Gge=({className:e,...t})=>Wh.jsx(nce,{className:Gde(Bue({size:"sm",variant:"outline"}),e),...t}),Vge=({className:e,...t})=>Wh.jsx(ace,{className:Gde(Bue({size:"sm",variant:"outline"}),"text-sm pl-2 file:h-full file:cursor-pointer py-0","file:bg-transparent file:border-none file:font-medium","file:text-sm file:text-gray-700 dark:file:text-white-alpha-700",e),...t}),qge=({className:e,...t})=>Wh.jsx(oce,{className:Gde(Bue({size:"sm",variant:"outline"}),"min-h-20 px-4 py-2",e),...t}),Wge=({className:e,...t})=>Wh.jsx(sce,{className:Gde(Mue({slot:"root"}),e),...t}),Yge=({className:e,...t})=>Wh.jsx(lce,{className:Gde(Mue({slot:"indicator"}),e),...t}),Kge=e=>{const{field:t,error:n,fieldProps:r}=_le(),{onValueChange:a,...o}=e;return Wh.jsx(cce,{name:t.name,"data-invalid":SL(!!n),value:r.value,onValueChange:L9(a,r.onChange),...o})},Xge=({className:e,...t})=>Wh.jsx(uce,{className:Gde(Xue({slot:"trigger"}),"text-sm",e),...t}),Qge=e=>{const{field:t}=_le();return Wh.jsx(dce,{placeholder:"placeholder"in t?t.placeholder:void 0,...e})},Zge=({className:e,...t})=>Wh.jsx(pce,{className:Gde("h-4 w-4 opacity-45",e),...t}),Jge=({className:e,...t})=>Wh.jsx(hce,{className:Gde(Xue({slot:"content"}),e),...t}),eye=({className:e,...t})=>Wh.jsx(fce,{className:Gde(Xue({slot:"viewport"}),e),...t}),tye=({className:e,...t})=>Wh.jsx(mce,{className:Gde(Xue({slot:"item"}),"text-sm",e),...t}),nye=gce,rye=({className:e,...t})=>Wh.jsx(yce,{className:Gde(Xue({slot:"itemIndicator"}),e),...t}),aye=({className:e,...t})=>Wh.jsx(vce,{className:Gde("text-sm flex items-center text-red-500 dark:text-red-300",e),...t}),oye=({className:e,...t})=>Wh.jsx(kce,{className:Gde("flex items-center gap-2",e),...t}),iye=({className:e,...t})=>Wh.jsx(wce,{className:Gde("border","bg-[linear-gradient(to_top,_var(--ikp-color-gray-100),_transparent)] dark:bg-[linear-gradient(to_top,_var(--ikp-color-gray-dark-600),_transparent)]","p-1 rounded-md","w-6 h-6 text-gray-600 dark:text-white-alpha-700",e),...t}),sye=({className:e,...t})=>Wh.jsx(Ece,{className:Gde("text-gray-800 dark:text-white-alpha-950 text-sm font-semibold",e),...t}),lye=({className:e,...t})=>Wh.jsx(Sce,{className:Gde("py-6 flex flex-wrap","gap-x-3 gap-y-6","[&>:first-child]:basis-full text-sm",e),...t}),cye=({className:e,...t})=>Wh.jsx(Cce,{className:Gde("w-full flex flex-col py-6 gap-6 min-w-0 text-sm",e),...t}),uye=({className:e,componentStyles:t,...n})=>Wh.jsx(Nce,{className:Gde("max-w-full ",e),componentStyles:Ph(Wde,t??{}),...n}),dye=({className:e,...t})=>Wh.jsx(Rce,{className:Gde(Due({preset:"neutralFilled",size:"sm"}),"ml-auto gap-2 data-[escalated]:hidden",e),...t}),pye=({className:e,...t})=>Wh.jsx(Oce,{className:Gde("",e),...t}),hye=Pce,fye=({className:e,...t})=>Wh.jsx(Lce,{className:Gde("w-full flex flex-col py-6 gap-6",e),...t}),mye=({className:e,...t})=>Wh.jsx(Fce,{className:Gde("text-gray-700 dark:text-white-alpha-700 text-sm",e),...t}),gye=({className:e,...t})=>Wh.jsx(Bce,{className:Gde("w-full gap-8",e),...t}),yye=({className:e,...t})=>Wh.jsx(Hce,{className:Gde(Due({preset:"neutralFilled",size:"sm"}),"ml-auto data-[loading]:cursor-wait","data-[submitted]:hidden",e),...t}),bye=({className:e,...t})=>Wh.jsx($ce,{className:Gde("text-red-500 dark:text-red-300",e),...t}),vye=({className:e,...t})=>Wh.jsx(Gce,{className:Gde("w-full flex flex-col gap-6",e),...t}),kye=({className:e,...t})=>Wh.jsx(Vce,{className:Gde("text-gray-700 dark:text-white-alpha-700 text-sm",e),...t}),wye=({className:e,...t})=>Wh.jsx(Wce,{className:Gde("w-full flex flex-wrap gap-2 items-center",e),...t}),xye=({className:e,...t})=>Wh.jsx(Kce,{className:Gde(Due({size:"xs",variant:"outline"}),"text-gray-600 dark:text-white-alpha-700 gap-1",e),...t}),Eye=({className:e,...t})=>Wh.jsx(Qce,{className:Gde("",e),...t}),_ye=({className:e,...t})=>Wh.jsx(Jce,{className:Gde("line-clamp-1",e),...t}),Sye=e=>Wh.jsx(GO,{styles:'*, ::before, ::after {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n --tw-contain-size: ;\n --tw-contain-layout: ;\n --tw-contain-paint: ;\n --tw-contain-style: ;\n}\n\n::backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n --tw-contain-size: ;\n --tw-contain-layout: ;\n --tw-contain-paint: ;\n --tw-contain-style: ;\n}/*\n! tailwindcss v3.4.17 | MIT License | https://tailwindcss.com\n*//*\n1. Prevent padding and border from affecting element width. (https://github.com/mozdevs/cssremedy/issues/4)\n2. Allow adding a border to an element by just adding a border-width. (https://github.com/tailwindcss/tailwindcss/pull/116)\n*/\n\n*,\n::before,\n::after {\n box-sizing: border-box; /* 1 */\n border-width: 0; /* 2 */\n border-style: solid; /* 2 */\n border-color: var(--ikp-color-gray-200); /* 2 */\n}\n\n::before,\n::after {\n --tw-content: \'\';\n}\n\n/*\n1. Use a consistent sensible line-height in all browsers.\n2. Prevent adjustments of font size after orientation changes in iOS.\n3. Use a more readable tab size.\n4. Use the user\'s configured `sans` font-family by default.\n5. Use the user\'s configured `sans` font-feature-settings by default.\n6. Use the user\'s configured `sans` font-variation-settings by default.\n7. Disable tap highlights on iOS\n*/\n\nhtml,\n:host {\n line-height: 1.5; /* 1 */\n -webkit-text-size-adjust: 100%; /* 2 */\n -moz-tab-size: 4; /* 3 */\n -o-tab-size: 4;\n tab-size: 4; /* 3 */\n font-family: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; /* 4 */\n font-feature-settings: normal; /* 5 */\n font-variation-settings: normal; /* 6 */\n -webkit-tap-highlight-color: transparent; /* 7 */\n}\n\n/*\n1. Remove the margin in all browsers.\n2. Inherit line-height from `html` so users can set them as a class directly on the `html` element.\n*/\n\nbody {\n margin: 0; /* 1 */\n line-height: inherit; /* 2 */\n}\n\n/*\n1. Add the correct height in Firefox.\n2. Correct the inheritance of border color in Firefox. (https://bugzilla.mozilla.org/show_bug.cgi?id=190655)\n3. Ensure horizontal rules are visible by default.\n*/\n\nhr {\n height: 0; /* 1 */\n color: inherit; /* 2 */\n border-top-width: 1px; /* 3 */\n}\n\n/*\nAdd the correct text decoration in Chrome, Edge, and Safari.\n*/\n\nabbr:where([title]) {\n -webkit-text-decoration: underline dotted;\n text-decoration: underline dotted;\n}\n\n/*\nRemove the default font size and weight for headings.\n*/\n\nh1,\nh2,\nh3,\nh4,\nh5,\nh6 {\n font-size: inherit;\n font-weight: inherit;\n}\n\n/*\nReset links to optimize for opt-in styling instead of opt-out.\n*/\n\na {\n color: inherit;\n text-decoration: inherit;\n}\n\n/*\nAdd the correct font weight in Edge and Safari.\n*/\n\nb,\nstrong {\n font-weight: bolder;\n}\n\n/*\n1. Use the user\'s configured `mono` font-family by default.\n2. Use the user\'s configured `mono` font-feature-settings by default.\n3. Use the user\'s configured `mono` font-variation-settings by default.\n4. Correct the odd `em` font sizing in all browsers.\n*/\n\ncode,\nkbd,\nsamp,\npre {\n font-family: var(--ikp-font-family-mono); /* 1 */\n font-feature-settings: normal; /* 2 */\n font-variation-settings: normal; /* 3 */\n font-size: 1em; /* 4 */\n}\n\n/*\nAdd the correct font size in all browsers.\n*/\n\nsmall {\n font-size: 80%;\n}\n\n/*\nPrevent `sub` and `sup` elements from affecting the line height in all browsers.\n*/\n\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\n/*\n1. Remove text indentation from table contents in Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=999088, https://bugs.webkit.org/show_bug.cgi?id=201297)\n2. Correct table border color inheritance in all Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=935729, https://bugs.webkit.org/show_bug.cgi?id=195016)\n3. Remove gaps between table borders by default.\n*/\n\ntable {\n text-indent: 0; /* 1 */\n border-color: inherit; /* 2 */\n border-collapse: collapse; /* 3 */\n}\n\n/*\n1. Change the font styles in all browsers.\n2. Remove the margin in Firefox and Safari.\n3. Remove default padding in all browsers.\n*/\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: inherit; /* 1 */\n font-feature-settings: inherit; /* 1 */\n font-variation-settings: inherit; /* 1 */\n font-size: 100%; /* 1 */\n font-weight: inherit; /* 1 */\n line-height: inherit; /* 1 */\n letter-spacing: inherit; /* 1 */\n color: inherit; /* 1 */\n margin: 0; /* 2 */\n padding: 0; /* 3 */\n}\n\n/*\nRemove the inheritance of text transform in Edge and Firefox.\n*/\n\nbutton,\nselect {\n text-transform: none;\n}\n\n/*\n1. Correct the inability to style clickable types in iOS and Safari.\n2. Remove default button styles.\n*/\n\nbutton,\ninput:where([type=\'button\']),\ninput:where([type=\'reset\']),\ninput:where([type=\'submit\']) {\n -webkit-appearance: button; /* 1 */\n background-color: transparent; /* 2 */\n background-image: none; /* 2 */\n}\n\n/*\nUse the modern Firefox focus style for all focusable elements.\n*/\n\n:-moz-focusring {\n outline: auto;\n}\n\n/*\nRemove the additional `:invalid` styles in Firefox. (https://github.com/mozilla/gecko-dev/blob/2f9eacd9d3d995c937b4251a5557d95d494c9be1/layout/style/res/forms.css#L728-L737)\n*/\n\n:-moz-ui-invalid {\n box-shadow: none;\n}\n\n/*\nAdd the correct vertical alignment in Chrome and Firefox.\n*/\n\nprogress {\n vertical-align: baseline;\n}\n\n/*\nCorrect the cursor style of increment and decrement buttons in Safari.\n*/\n\n::-webkit-inner-spin-button,\n::-webkit-outer-spin-button {\n height: auto;\n}\n\n/*\n1. Correct the odd appearance in Chrome and Safari.\n2. Correct the outline style in Safari.\n*/\n\n[type=\'search\'] {\n -webkit-appearance: textfield; /* 1 */\n outline-offset: -2px; /* 2 */\n}\n\n/*\nRemove the inner padding in Chrome and Safari on macOS.\n*/\n\n::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n/*\n1. Correct the inability to style clickable types in iOS and Safari.\n2. Change font properties to `inherit` in Safari.\n*/\n\n::-webkit-file-upload-button {\n -webkit-appearance: button; /* 1 */\n font: inherit; /* 2 */\n}\n\n/*\nAdd the correct display in Chrome and Safari.\n*/\n\nsummary {\n display: list-item;\n}\n\n/*\nRemoves the default spacing and border for appropriate elements.\n*/\n\nblockquote,\ndl,\ndd,\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\nhr,\nfigure,\np,\npre {\n margin: 0;\n}\n\nfieldset {\n margin: 0;\n padding: 0;\n}\n\nlegend {\n padding: 0;\n}\n\nol,\nul,\nmenu {\n list-style: none;\n margin: 0;\n padding: 0;\n}\n\n/*\nReset default styling for dialogs.\n*/\ndialog {\n padding: 0;\n}\n\n/*\nPrevent resizing textareas horizontally by default.\n*/\n\ntextarea {\n resize: vertical;\n}\n\n/*\n1. Reset the default placeholder opacity in Firefox. (https://github.com/tailwindlabs/tailwindcss/issues/3300)\n2. Set the default placeholder color to the user\'s configured gray 400 color.\n*/\n\ninput::-moz-placeholder, textarea::-moz-placeholder {\n opacity: 1; /* 1 */\n color: var(--ikp-color-gray-400); /* 2 */\n}\n\ninput::placeholder,\ntextarea::placeholder {\n opacity: 1; /* 1 */\n color: var(--ikp-color-gray-400); /* 2 */\n}\n\n/*\nSet the default cursor for buttons.\n*/\n\nbutton,\n[role="button"] {\n cursor: pointer;\n}\n\n/*\nMake sure disabled buttons don\'t get the pointer cursor.\n*/\n:disabled {\n cursor: default;\n}\n\n/*\n1. Make replaced elements `display: block` by default. (https://github.com/mozdevs/cssremedy/issues/14)\n2. Add `vertical-align: middle` to align replaced elements more sensibly by default. (https://github.com/jensimmons/cssremedy/issues/14#issuecomment-634934210)\n This can trigger a poorly considered lint error in some tools but is included by design.\n*/\n\nimg,\nsvg,\nvideo,\ncanvas,\naudio,\niframe,\nembed,\nobject {\n display: block; /* 1 */\n vertical-align: middle; /* 2 */\n}\n\n/*\nConstrain images and videos to the parent width and preserve their intrinsic aspect ratio. (https://github.com/mozdevs/cssremedy/issues/14)\n*/\n\nimg,\nvideo {\n max-width: 100%;\n height: auto;\n}\n\n/* Make elements with the HTML hidden attribute stay hidden by default */\n[hidden]:where(:not([hidden="until-found"])) {\n display: none;\n}\n.container {\n width: 100%;\n}\n@media (min-width: 640px) {\n\n .container {\n max-width: 640px;\n }\n}\n@media (min-width: 768px) {\n\n .container {\n max-width: 768px;\n }\n}\n@media (min-width: 1024px) {\n\n .container {\n max-width: 1024px;\n }\n}\n@media (min-width: 1280px) {\n\n .container {\n max-width: 1280px;\n }\n}\n@media (min-width: 1536px) {\n\n .container {\n max-width: 1536px;\n }\n}\n.pointer-events-none {\n pointer-events: none;\n}\n.fixed {\n position: fixed;\n}\n.absolute {\n position: absolute;\n}\n.relative {\n position: relative;\n}\n.inset-0 {\n inset: 0px;\n}\n.inset-\\[unset\\] {\n inset: unset;\n}\n.bottom-0 {\n bottom: 0px;\n}\n.bottom-6 {\n bottom: 1.5rem;\n}\n.left-0 {\n left: 0px;\n}\n.left-1\\/2 {\n left: 50%;\n}\n.left-\\[unset\\] {\n left: unset;\n}\n.right-1 {\n right: 0.25rem;\n}\n.right-2 {\n right: 0.5rem;\n}\n.right-3 {\n right: 0.75rem;\n}\n.right-6 {\n right: 1.5rem;\n}\n.top-0 {\n top: 0px;\n}\n.top-1 {\n top: 0.25rem;\n}\n.top-1\\/2 {\n top: 50%;\n}\n.top-2 {\n top: 0.5rem;\n}\n.top-\\[5\\%\\] {\n top: 5%;\n}\n.z-50 {\n z-index: 50;\n}\n.z-\\[1\\] {\n z-index: 1;\n}\n.z-base {\n z-index: var(--ikp-z-index-base);\n}\n.z-dropdown {\n z-index: var(--ikp-z-index-dropdown);\n}\n.z-modal {\n z-index: var(--ikp-z-index-modal);\n}\n.z-overlay {\n z-index: var(--ikp-z-index-overlay);\n}\n.z-popover {\n z-index: var(--ikp-z-index-popover);\n}\n.z-start {\n z-index: var(--ikp-z-index-start);\n}\n.m-\\[0px_0px_0\\.5em\\] {\n margin: 0px 0px 0.5em;\n}\n.m-auto {\n margin: auto;\n}\n.-my-\\[1px\\] {\n margin-top: -1px;\n margin-bottom: -1px;\n}\n.mx-1 {\n margin-left: 0.25rem;\n margin-right: 0.25rem;\n}\n.mx-5 {\n margin-left: 1.25rem;\n margin-right: 1.25rem;\n}\n.mx-\\[5px\\] {\n margin-left: 5px;\n margin-right: 5px;\n}\n.mx-auto {\n margin-left: auto;\n margin-right: auto;\n}\n.my-2 {\n margin-top: 0.5rem;\n margin-bottom: 0.5rem;\n}\n.my-6 {\n margin-top: 1.5rem;\n margin-bottom: 1.5rem;\n}\n.my-\\[\\.1rem\\] {\n margin-top: .1rem;\n margin-bottom: .1rem;\n}\n.\\!ml-auto {\n margin-left: auto !important;\n}\n.mb-0 {\n margin-bottom: 0px;\n}\n.mb-0\\.5 {\n margin-bottom: 0.125rem;\n}\n.mb-1 {\n margin-bottom: 0.25rem;\n}\n.mb-2 {\n margin-bottom: 0.5rem;\n}\n.mb-3 {\n margin-bottom: 0.75rem;\n}\n.mb-4 {\n margin-bottom: 1rem;\n}\n.mb-5 {\n margin-bottom: 1.25rem;\n}\n.mb-6 {\n margin-bottom: 1.5rem;\n}\n.mb-8 {\n margin-bottom: 2rem;\n}\n.ml-1 {\n margin-left: 0.25rem;\n}\n.ml-1\\.5 {\n margin-left: 0.375rem;\n}\n.ml-2 {\n margin-left: 0.5rem;\n}\n.ml-4 {\n margin-left: 1rem;\n}\n.ml-\\[3px\\] {\n margin-left: 3px;\n}\n.ml-auto {\n margin-left: auto;\n}\n.mr-0\\.5 {\n margin-right: 0.125rem;\n}\n.mr-1 {\n margin-right: 0.25rem;\n}\n.mr-2 {\n margin-right: 0.5rem;\n}\n.mr-\\[0\\.5em\\] {\n margin-right: 0.5em;\n}\n.mr-\\[var\\(--removed-body-scroll-bar-size\\)\\] {\n margin-right: var(--removed-body-scroll-bar-size);\n}\n.mr-auto {\n margin-right: auto;\n}\n.ms-\\[1em\\] {\n margin-inline-start: 1em;\n}\n.mt-12 {\n margin-top: 3rem;\n}\n.mt-2 {\n margin-top: 0.5rem;\n}\n.mt-4 {\n margin-top: 1rem;\n}\n.mt-8 {\n margin-top: 2rem;\n}\n.line-clamp-1 {\n overflow: hidden;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 1;\n}\n.\\!line-clamp-none {\n overflow: visible !important;\n display: block !important;\n -webkit-box-orient: horizontal !important;\n -webkit-line-clamp: none !important;\n}\n.block {\n display: block;\n}\n.inline-block {\n display: inline-block;\n}\n.flex {\n display: flex;\n}\n.inline-flex {\n display: inline-flex;\n}\n.table {\n display: table;\n}\n.grid {\n display: grid;\n}\n.contents {\n display: contents;\n}\n.hidden {\n display: none;\n}\n.size-10 {\n width: 2.5rem;\n height: 2.5rem;\n}\n.size-4 {\n width: 1rem;\n height: 1rem;\n}\n.h-0 {\n height: 0px;\n}\n.h-10 {\n height: 2.5rem;\n}\n.h-11 {\n height: 2.75rem;\n}\n.h-12 {\n height: 3rem;\n}\n.h-20 {\n height: 5rem;\n}\n.h-3 {\n height: 0.75rem;\n}\n.h-3\\.5 {\n height: 0.875rem;\n}\n.h-4 {\n height: 1rem;\n}\n.h-5 {\n height: 1.25rem;\n}\n.h-6 {\n height: 1.5rem;\n}\n.h-8 {\n height: 2rem;\n}\n.h-\\[24px\\] {\n height: 24px;\n}\n.h-\\[27\\.88px\\] {\n height: 27.88px;\n}\n.h-\\[30px\\] {\n height: 30px;\n}\n.h-\\[calc\\(100\\%-24px\\)\\] {\n height: calc(100% - 24px);\n}\n.h-\\[var\\(--ask-ai-trigger-height\\)\\] {\n height: var(--ask-ai-trigger-height);\n}\n.h-\\[var\\(--radix-select-trigger-height\\)\\] {\n height: var(--radix-select-trigger-height);\n}\n.h-auto {\n height: auto;\n}\n.h-full {\n height: 100%;\n}\n.h-screen {\n height: 100vh;\n}\n.max-h-96 {\n max-height: 24rem;\n}\n.max-h-\\[100vw\\] {\n max-height: 100vw;\n}\n.max-h-\\[10vh\\] {\n max-height: 10vh;\n}\n.max-h-\\[200px\\] {\n max-height: 200px;\n}\n.max-h-\\[min\\(85vh\\2c 850px\\)\\] {\n max-height: min(85vh,850px);\n}\n.max-h-full {\n max-height: 100%;\n}\n.max-h-screen {\n max-height: 100vh;\n}\n.\\!min-h-0 {\n min-height: 0px !important;\n}\n.min-h-0 {\n min-height: 0px;\n}\n.min-h-20 {\n min-height: 5rem;\n}\n.min-h-8 {\n min-height: 2rem;\n}\n.min-h-9 {\n min-height: 2.25rem;\n}\n.min-h-\\[38px\\] {\n min-height: 38px;\n}\n.min-h-\\[unset\\] {\n min-height: unset;\n}\n.w-10 {\n width: 2.5rem;\n}\n.w-12 {\n width: 3rem;\n}\n.w-16 {\n width: 4rem;\n}\n.w-2\\.5 {\n width: 0.625rem;\n}\n.w-3\\.5 {\n width: 0.875rem;\n}\n.w-4 {\n width: 1rem;\n}\n.w-40 {\n width: 10rem;\n}\n.w-5 {\n width: 1.25rem;\n}\n.w-56 {\n width: 14rem;\n}\n.w-6 {\n width: 1.5rem;\n}\n.w-60 {\n width: 15rem;\n}\n.w-8 {\n width: 2rem;\n}\n.w-\\[--width\\] {\n width: var(--width);\n}\n.w-\\[250px\\] {\n width: 250px;\n}\n.w-\\[254px\\] {\n width: 254px;\n}\n.w-\\[calc\\(100\\%_-_theme\\(spacing\\.10\\)\\)\\] {\n width: calc(100% - 2.5rem);\n}\n.w-\\[min\\(90vw\\2c 720px\\)\\] {\n width: min(90vw,720px);\n}\n.w-fit {\n width: -moz-fit-content;\n width: fit-content;\n}\n.w-full {\n width: 100%;\n}\n.w-screen {\n width: 100vw;\n}\n.\\!min-w-0 {\n min-width: 0px !important;\n}\n.min-w-0 {\n min-width: 0px;\n}\n.min-w-10 {\n min-width: 2.5rem;\n}\n.min-w-5 {\n min-width: 1.25rem;\n}\n.min-w-6 {\n min-width: 1.5rem;\n}\n.min-w-8 {\n min-width: 2rem;\n}\n.min-w-\\[8rem\\] {\n min-width: 8rem;\n}\n.min-w-\\[unset\\] {\n min-width: unset;\n}\n.min-w-\\[var\\(--radix-select-trigger-width\\)\\] {\n min-width: var(--radix-select-trigger-width);\n}\n.max-w-2xl {\n max-width: 42rem;\n}\n.max-w-\\[200px\\] {\n max-width: 200px;\n}\n.max-w-\\[480px\\] {\n max-width: 480px;\n}\n.max-w-full {\n max-width: 100%;\n}\n.max-w-lg {\n max-width: 32rem;\n}\n.flex-1 {\n flex: 1 1 0%;\n}\n.flex-\\[0_0_100\\%\\] {\n flex: 0 0 100%;\n}\n.flex-shrink-0 {\n flex-shrink: 0;\n}\n.shrink-0 {\n flex-shrink: 0;\n}\n.grow-0 {\n flex-grow: 0;\n}\n.grow-\\[1\\] {\n flex-grow: 1;\n}\n.grow-\\[2\\] {\n flex-grow: 2;\n}\n.grow-\\[5\\] {\n flex-grow: 5;\n}\n.border-collapse {\n border-collapse: collapse;\n}\n.-translate-x-1\\/2 {\n --tw-translate-x: -50%;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n.-translate-y-1\\/2 {\n --tw-translate-y: -50%;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n.translate-x-\\[-50\\%\\] {\n --tw-translate-x: -50%;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n.rotate-\\[-30deg\\] {\n --tw-rotate: -30deg;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n.transform-none {\n transform: none;\n}\n@keyframes bounce-dot {\n\n 0%, 100% {\n transform: translateY(0);\n opacity: 0.3;\n }\n\n 50% {\n transform: translateY(-5px);\n opacity: 1;\n }\n}\n.animate-bounce-dot {\n animation: bounce-dot 1.5s infinite ease-in-out;\n}\n@keyframes checkbox-check {\n\n from {\n opacity: 0;\n stroke-dashoffset: 16;\n transform: scale(0.95);\n }\n\n to {\n opacity: 1;\n stroke-dashoffset: 0;\n transform: scale(1);\n }\n}\n.animate-checkbox-check {\n animation: checkbox-check 200ms linear;\n}\n@keyframes shimmer {\n\n 0% {\n background-size: 200% 200%;\n background-position: 100% 0;\n }\n\n 100% {\n background-size: 200% 200%;\n background-position: -100% 0;\n }\n}\n.animate-shimmer {\n animation: shimmer 3.5s cubic-bezier(0.4, 0, 0.6, 1) infinite;\n}\n@keyframes shine {\n\n 0% {\n background-position: -200% 0%;\n }\n\n 100% {\n background-position: 200% 0%;\n }\n}\n.animate-shine {\n animation: shine 2.5s linear infinite;\n}\n@keyframes skeleton-bg-fade {\n\n from {\n border-color: var(--start-color);\n background: var(--start-color);\n }\n\n to {\n border-color: var(--end-color);\n background: var(--end-color);\n }\n}\n.animate-skeleton-bg-fade {\n animation: 0.8s linear infinite alternate skeleton-bg-fade;\n}\n@keyframes spin {\n\n to {\n transform: rotate(360deg);\n }\n}\n.animate-spin {\n animation: spin 1s linear infinite;\n}\n.cursor-default {\n cursor: default;\n}\n.cursor-ew-resize {\n cursor: ew-resize;\n}\n.cursor-pointer {\n cursor: pointer;\n}\n.touch-none {\n touch-action: none;\n}\n.select-none {\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n}\n.resize-none {\n resize: none;\n}\n.list-\\[initial\\] {\n list-style-type: initial;\n}\n.list-decimal {\n list-style-type: decimal;\n}\n.appearance-none {\n -webkit-appearance: none;\n -moz-appearance: none;\n appearance: none;\n}\n.flex-row {\n flex-direction: row;\n}\n.flex-row-reverse {\n flex-direction: row-reverse;\n}\n.flex-col {\n flex-direction: column;\n}\n.flex-wrap {\n flex-wrap: wrap;\n}\n.flex-wrap-reverse {\n flex-wrap: wrap-reverse;\n}\n.place-items-center {\n place-items: center;\n}\n.content-center {\n align-content: center;\n}\n.items-start {\n align-items: flex-start;\n}\n.items-end {\n align-items: flex-end;\n}\n.items-center {\n align-items: center;\n}\n.items-stretch {\n align-items: stretch;\n}\n.justify-start {\n justify-content: flex-start;\n}\n.justify-end {\n justify-content: flex-end;\n}\n.justify-center {\n justify-content: center;\n}\n.justify-between {\n justify-content: space-between;\n}\n.gap-0\\.5 {\n gap: 0.125rem;\n}\n.gap-1 {\n gap: 0.25rem;\n}\n.gap-1\\.5 {\n gap: 0.375rem;\n}\n.gap-12 {\n gap: 3rem;\n}\n.gap-2 {\n gap: 0.5rem;\n}\n.gap-2\\.5 {\n gap: 0.625rem;\n}\n.gap-3 {\n gap: 0.75rem;\n}\n.gap-4 {\n gap: 1rem;\n}\n.gap-5 {\n gap: 1.25rem;\n}\n.gap-6 {\n gap: 1.5rem;\n}\n.gap-8 {\n gap: 2rem;\n}\n.gap-\\[1rem_0\\.5rem\\] {\n gap: 1rem 0.5rem;\n}\n.gap-x-2 {\n -moz-column-gap: 0.5rem;\n column-gap: 0.5rem;\n}\n.gap-x-3 {\n -moz-column-gap: 0.75rem;\n column-gap: 0.75rem;\n}\n.gap-y-1 {\n row-gap: 0.25rem;\n}\n.gap-y-2 {\n row-gap: 0.5rem;\n}\n.gap-y-6 {\n row-gap: 1.5rem;\n}\n.space-x-1 > :not([hidden]) ~ :not([hidden]) {\n --tw-space-x-reverse: 0;\n margin-right: calc(0.25rem * var(--tw-space-x-reverse));\n margin-left: calc(0.25rem * calc(1 - var(--tw-space-x-reverse)));\n}\n.space-x-2 > :not([hidden]) ~ :not([hidden]) {\n --tw-space-x-reverse: 0;\n margin-right: calc(0.5rem * var(--tw-space-x-reverse));\n margin-left: calc(0.5rem * calc(1 - var(--tw-space-x-reverse)));\n}\n.divide-y > :not([hidden]) ~ :not([hidden]) {\n --tw-divide-y-reverse: 0;\n border-top-width: calc(1px * calc(1 - var(--tw-divide-y-reverse)));\n border-bottom-width: calc(1px * var(--tw-divide-y-reverse));\n}\n.self-start {\n align-self: flex-start;\n}\n.self-center {\n align-self: center;\n}\n.justify-self-end {\n justify-self: end;\n}\n.justify-self-center {\n justify-self: center;\n}\n.overflow-hidden {\n overflow: hidden;\n}\n.overflow-x-auto {\n overflow-x: auto;\n}\n.overflow-y-auto {\n overflow-y: auto;\n}\n.truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.text-ellipsis {\n text-overflow: ellipsis;\n}\n.whitespace-normal {\n white-space: normal;\n}\n.whitespace-nowrap {\n white-space: nowrap;\n}\n.whitespace-pre {\n white-space: pre;\n}\n.whitespace-pre-wrap {\n white-space: pre-wrap;\n}\n.break-words {\n overflow-wrap: break-word;\n}\n.rounded {\n border-radius: 0.25rem;\n}\n.rounded-\\[0_0_6px_6px\\] {\n border-radius: 0 0 6px 6px;\n}\n.rounded-\\[6px\\] {\n border-radius: 6px;\n}\n.rounded-\\[6px_6px_0_0\\] {\n border-radius: 6px 6px 0 0;\n}\n.rounded-\\[inherit\\] {\n border-radius: inherit;\n}\n.rounded-full {\n border-radius: 9999px;\n}\n.rounded-lg {\n border-radius: 0.5rem;\n}\n.rounded-md {\n border-radius: 0.375rem;\n}\n.rounded-sm {\n border-radius: 0.125rem;\n}\n.rounded-xl {\n border-radius: 0.75rem;\n}\n.border {\n border-width: 1px;\n}\n.border-2 {\n border-width: 2px;\n}\n.border-b {\n border-bottom-width: 1px;\n}\n.border-l {\n border-left-width: 1px;\n}\n.border-solid {\n border-style: solid;\n}\n.border-none {\n border-style: none;\n}\n.border-\\[--end-color\\] {\n border-color: var(--end-color);\n}\n.border-gray-100 {\n border-color: var(--ikp-color-gray-100);\n}\n.border-gray-200 {\n border-color: var(--ikp-color-gray-200);\n}\n.border-gray-300 {\n border-color: var(--ikp-color-gray-300);\n}\n.border-inherit {\n border-color: inherit;\n}\n.border-inkeep-expanded-primary-200 {\n border-color: var(--ikp-color-inkeep-expanded-primary-200);\n}\n.border-transparent {\n border-color: transparent;\n}\n.border-white-alpha-200 {\n border-color: var(--ikp-color-white-alpha-200);\n}\n.border-l-transparent {\n border-left-color: transparent;\n}\n.bg-\\[--start-color\\] {\n background-color: var(--start-color);\n}\n.bg-gray-100 {\n background-color: var(--ikp-color-gray-100);\n}\n.bg-gray-1000 {\n background-color: var(--ikp-color-gray-1000);\n}\n.bg-gray-300 {\n background-color: var(--ikp-color-gray-300);\n}\n.bg-gray-50 {\n background-color: var(--ikp-color-gray-50);\n}\n.bg-gray-500 {\n background-color: var(--ikp-color-gray-500);\n}\n.bg-inherit {\n background-color: inherit;\n}\n.bg-inkeep-primary-lighter {\n background-color: var(--ikp-color-inkeep-primary-lighter);\n}\n.bg-inkeep-primary-medium {\n background-color: var(--ikp-color-inkeep-primary-medium);\n}\n.bg-inkeep-primary-text-bold {\n background-color: var(--ikp-color-inkeep-primary-text-bold);\n}\n.bg-overlay-light {\n background-color: var(--ikp-color-overlay-light);\n}\n.bg-transparent {\n background-color: transparent;\n}\n.bg-white {\n --tw-bg-opacity: 1;\n background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));\n}\n.bg-\\[linear-gradient\\(to_bottom_right\\2c _var\\(--ikp-color-gray-700\\)\\2c _var\\(--ikp-color-gray-400\\)\\)\\] {\n background-image: linear-gradient(to bottom right, var(--ikp-color-gray-700), var(--ikp-color-gray-400));\n}\n.bg-\\[linear-gradient\\(to_top\\2c _var\\(--ikp-color-gray-100\\)\\2c _transparent\\)\\] {\n background-image: linear-gradient(to top, var(--ikp-color-gray-100), transparent);\n}\n.bg-clip-padding {\n background-clip: padding-box;\n}\n.\\!bg-clip-text {\n -webkit-background-clip: text !important;\n background-clip: text !important;\n}\n.bg-clip-text {\n -webkit-background-clip: text;\n background-clip: text;\n}\n.fill-white {\n fill: #fff;\n}\n.p-0 {\n padding: 0px;\n}\n.p-0\\.5 {\n padding: 0.125rem;\n}\n.p-1 {\n padding: 0.25rem;\n}\n.p-2 {\n padding: 0.5rem;\n}\n.p-4 {\n padding: 1rem;\n}\n.p-8 {\n padding: 2rem;\n}\n.p-\\[1em\\] {\n padding: 1em;\n}\n.px-0 {\n padding-left: 0px;\n padding-right: 0px;\n}\n.px-1 {\n padding-left: 0.25rem;\n padding-right: 0.25rem;\n}\n.px-2 {\n padding-left: 0.5rem;\n padding-right: 0.5rem;\n}\n.px-3 {\n padding-left: 0.75rem;\n padding-right: 0.75rem;\n}\n.px-4 {\n padding-left: 1rem;\n padding-right: 1rem;\n}\n.px-5 {\n padding-left: 1.25rem;\n padding-right: 1.25rem;\n}\n.px-6 {\n padding-left: 1.5rem;\n padding-right: 1.5rem;\n}\n.px-\\[\\.4rem\\] {\n padding-left: .4rem;\n padding-right: .4rem;\n}\n.px-\\[18px\\] {\n padding-left: 18px;\n padding-right: 18px;\n}\n.py-0 {\n padding-top: 0px;\n padding-bottom: 0px;\n}\n.py-1 {\n padding-top: 0.25rem;\n padding-bottom: 0.25rem;\n}\n.py-1\\.5 {\n padding-top: 0.375rem;\n padding-bottom: 0.375rem;\n}\n.py-2 {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n}\n.py-3 {\n padding-top: 0.75rem;\n padding-bottom: 0.75rem;\n}\n.py-4 {\n padding-top: 1rem;\n padding-bottom: 1rem;\n}\n.py-6 {\n padding-top: 1.5rem;\n padding-bottom: 1.5rem;\n}\n.py-8 {\n padding-top: 2rem;\n padding-bottom: 2rem;\n}\n.py-\\[\\.2rem\\] {\n padding-top: .2rem;\n padding-bottom: .2rem;\n}\n.py-\\[1px\\] {\n padding-top: 1px;\n padding-bottom: 1px;\n}\n.pb-1 {\n padding-bottom: 0.25rem;\n}\n.pb-2 {\n padding-bottom: 0.5rem;\n}\n.pb-2\\.5 {\n padding-bottom: 0.625rem;\n}\n.pb-3 {\n padding-bottom: 0.75rem;\n}\n.pb-4 {\n padding-bottom: 1rem;\n}\n.pb-6 {\n padding-bottom: 1.5rem;\n}\n.pb-8 {\n padding-bottom: 2rem;\n}\n.pl-2 {\n padding-left: 0.5rem;\n}\n.pl-5 {\n padding-left: 1.25rem;\n}\n.pl-7 {\n padding-left: 1.75rem;\n}\n.pr-10 {\n padding-right: 2.5rem;\n}\n.pr-8 {\n padding-right: 2rem;\n}\n.pt-0 {\n padding-top: 0px;\n}\n.pt-1 {\n padding-top: 0.25rem;\n}\n.pt-12 {\n padding-top: 3rem;\n}\n.pt-2 {\n padding-top: 0.5rem;\n}\n.pt-3 {\n padding-top: 0.75rem;\n}\n.pt-4 {\n padding-top: 1rem;\n}\n.pt-6 {\n padding-top: 1.5rem;\n}\n.text-left {\n text-align: left;\n}\n.text-center {\n text-align: center;\n}\n.text-start {\n text-align: start;\n}\n.align-middle {\n vertical-align: middle;\n}\n.font-body {\n font-family: var(--ikp-font-family-body);\n}\n.font-heading {\n font-family: var(--ikp-font-family-heading);\n}\n.font-mono {\n font-family: var(--ikp-font-family-mono);\n}\n.text-1sm {\n font-size: var(--ikp-font-size-1sm);\n}\n.text-2sm {\n font-size: var(--ikp-font-size-2sm);\n}\n.text-2xs {\n font-size: var(--ikp-font-size-2xs);\n}\n.text-3xl {\n font-size: var(--ikp-font-size-3xl);\n}\n.text-lg {\n font-size: var(--ikp-font-size-lg);\n}\n.text-md {\n font-size: var(--ikp-font-size-md);\n}\n.text-sm {\n font-size: var(--ikp-font-size-sm);\n}\n.text-xl {\n font-size: var(--ikp-font-size-xl);\n}\n.text-xs {\n font-size: var(--ikp-font-size-xs);\n}\n.font-bold {\n font-weight: 700;\n}\n.font-medium {\n font-weight: 500;\n}\n.font-normal {\n font-weight: 400;\n}\n.font-semibold {\n font-weight: 600;\n}\n.uppercase {\n text-transform: uppercase;\n}\n.leading-4 {\n line-height: 1rem;\n}\n.leading-5 {\n line-height: 1.25rem;\n}\n.leading-6 {\n line-height: 1.5rem;\n}\n.leading-\\[1\\.25\\] {\n line-height: 1.25;\n}\n.leading-\\[1\\.2\\] {\n line-height: 1.2;\n}\n.leading-\\[1em\\] {\n line-height: 1em;\n}\n.leading-\\[unset\\] {\n line-height: unset;\n}\n.leading-snug {\n line-height: 1.375;\n}\n.tracking-tight {\n letter-spacing: -0.025em;\n}\n.tracking-wider {\n letter-spacing: 0.05em;\n}\n.tracking-widest {\n letter-spacing: 0.1em;\n}\n.text-current {\n color: currentColor;\n}\n.text-gray-400 {\n color: var(--ikp-color-gray-400);\n}\n.text-gray-500 {\n color: var(--ikp-color-gray-500);\n}\n.text-gray-600 {\n color: var(--ikp-color-gray-600);\n}\n.text-gray-700 {\n color: var(--ikp-color-gray-700);\n}\n.text-gray-800 {\n color: var(--ikp-color-gray-800);\n}\n.text-green-500 {\n --tw-text-opacity: 1;\n color: rgb(34 197 94 / var(--tw-text-opacity, 1));\n}\n.text-inherit {\n color: inherit;\n}\n.text-inkeep-primary-medium {\n color: var(--ikp-color-inkeep-primary-medium);\n}\n.text-inkeep-primary-medium-subtle {\n color: var(--ikp-color-inkeep-primary-medium-subtle);\n}\n.text-inkeep-primary-strong {\n color: var(--ikp-color-inkeep-primary-strong);\n}\n.text-inkeep-primary-stronger {\n color: var(--ikp-color-inkeep-primary-stronger);\n}\n.text-inkeep-primary-stronger-light {\n color: var(--ikp-color-inkeep-primary-stronger-light);\n}\n.text-inkeep-primary-text-bold {\n color: var(--ikp-color-inkeep-primary-text-bold);\n}\n.text-inkeep-primary-text-color-on-primary {\n color: var(--ikp-color-inkeep-primary-text-color-on-primary);\n}\n.text-purple-500 {\n --tw-text-opacity: 1;\n color: rgb(168 85 247 / var(--tw-text-opacity, 1));\n}\n.text-red-500 {\n --tw-text-opacity: 1;\n color: rgb(239 68 68 / var(--tw-text-opacity, 1));\n}\n.text-transparent {\n color: transparent;\n}\n.text-white {\n --tw-text-opacity: 1;\n color: rgb(255 255 255 / var(--tw-text-opacity, 1));\n}\n.opacity-0 {\n opacity: 0;\n}\n.opacity-100 {\n opacity: 1;\n}\n.opacity-30 {\n opacity: 0.3;\n}\n.opacity-45 {\n opacity: 0.45;\n}\n.opacity-70 {\n opacity: 0.7;\n}\n.shadow {\n --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);\n --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-2xl {\n --tw-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.25);\n --tw-shadow-colored: 0 25px 50px -12px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-\\[0_0_0_2px_var\\(--shadow-color\\)\\] {\n --tw-shadow: 0 0 0 2px var(--shadow-color);\n --tw-shadow-colored: 0 0 0 2px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-\\[0_25px_50px_-12px_rgba\\(0\\2c 0\\2c 0\\2c 0\\.25\\)\\] {\n --tw-shadow: 0 25px 50px -12px rgba(0,0,0,0.25);\n --tw-shadow-colored: 0 25px 50px -12px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-\\[0_8px_30px_rgba\\(0\\2c 0\\2c 0\\2c 0\\.12\\)\\] {\n --tw-shadow: 0 8px 30px rgba(0,0,0,0.12);\n --tw-shadow-colored: 0 8px 30px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-\\[inset_0_0_0_1px_currentColor\\] {\n --tw-shadow: inset 0 0 0 1px currentColor;\n --tw-shadow-colored: inset 0 0 0 1px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-lg {\n --tw-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);\n --tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-md {\n --tw-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);\n --tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-none {\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-\\[none\\] {\n --tw-shadow-color: none;\n --tw-shadow: var(--tw-shadow-colored);\n}\n.outline-none {\n outline: 2px solid transparent;\n outline-offset: 2px;\n}\n.outline {\n outline-style: solid;\n}\n.backdrop-blur-sm {\n --tw-backdrop-blur: blur(4px);\n -webkit-backdrop-filter: var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);\n backdrop-filter: var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);\n}\n.transition-\\[common\\] {\n transition-property: common;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n.transition-all {\n transition-property: all;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n.transition-colors {\n transition-property: color, background-color, border-color, text-decoration-color, fill, stroke;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n.transition-opacity {\n transition-property: opacity;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n.transition-transform {\n transition-property: transform;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n.duration-100 {\n transition-duration: 100ms;\n}\n.duration-200 {\n transition-duration: 200ms;\n}\n.duration-300 {\n transition-duration: 300ms;\n}\n.duration-\\[160ms\\] {\n transition-duration: 160ms;\n}\n.duration-\\[180\\] {\n transition-duration: 180;\n}\n.ease-in-out {\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n}\n.ease-linear {\n transition-timing-function: linear;\n}\n.ease-out {\n transition-timing-function: cubic-bezier(0, 0, 0.2, 1);\n}\n.\\[--ask-ai-trigger-height\\:0px\\] {\n --ask-ai-trigger-height: 0px;\n}\n.\\[--end-color\\:theme\\(colors\\.gray\\.300\\)\\] {\n --end-color: var(--ikp-color-gray-300);\n}\n.\\[--end-color\\:theme\\(colors\\.inkeep-expanded-primary\\.700\\)\\] {\n --end-color: var(--ikp-color-inkeep-expanded-primary-700);\n}\n.\\[--end-color\\:theme\\(colors\\.white-alpha\\.100\\)\\] {\n --end-color: var(--ikp-color-white-alpha-100);\n}\n.\\[--error-border-color\\:theme\\(colors\\.red\\.500\\)\\] {\n --error-border-color: #ef4444;\n}\n.\\[--focus-border-color\\:theme\\(colors\\.blue\\.500\\)\\] {\n --focus-border-color: #3b82f6;\n}\n.\\[--footer-height\\:theme\\(spacing\\.9\\)\\] {\n --footer-height: 2.25rem;\n}\n.\\[--scrollbar-color\\:var\\(--color-gray-300\\)\\] {\n --scrollbar-color: var(--color-gray-300);\n}\n.\\[--start-color\\:theme\\(colors\\.gray\\.50\\)\\] {\n --start-color: var(--ikp-color-gray-50);\n}\n.\\[--start-color\\:theme\\(colors\\.inkeep-expanded-primary\\.300\\)\\] {\n --start-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n.\\[background\\:linear-gradient\\(270deg\\2c theme\\(colors\\.inkeep-primary\\.stronger-light\\)\\2c transparent\\)_-200\\%_50\\%_\\/_25\\%_100\\%_no-repeat\\2c theme\\(colors\\.inkeep-expanded-primary\\.800\\)\\] {\n background: linear-gradient(270deg,var(--ikp-color-inkeep-primary-stronger-light),transparent) -200% 50% / 25% 100% no-repeat,var(--ikp-color-inkeep-expanded-primary-800);\n}\n.\\[counter-increment\\:item\\] {\n counter-increment: item;\n}\n.\\[counter-reset\\:item_calc\\(var\\(--start\\2c 0\\)_-_1\\)\\] {\n counter-reset: item calc(var(--start,0) - 1);\n}\n.\\[font-size\\:85\\%\\!important\\] {\n font-size: 85% !important;\n}\n.\\[font-variant-numeric\\:lining-nums_tabular-nums\\] {\n font-variant-numeric: lining-nums tabular-nums;\n}\n.\\[grid-area\\:breadcrumbs\\] {\n grid-area: breadcrumbs;\n}\n.\\[grid-area\\:description\\] {\n grid-area: description;\n}\n.\\[grid-area\\:icon\\] {\n grid-area: icon;\n}\n.\\[grid-area\\:indicator\\] {\n grid-area: indicator;\n}\n.\\[grid-area\\:tag\\] {\n grid-area: tag;\n}\n.\\[grid-area\\:title\\] {\n grid-area: title;\n}\n.\\[grid-template\\:\\"breadcrumbs_breadcrumbs_breadcrumbs_indicator\\"\\"icon_title_tag_indicator\\"\\"description_description_description_indicator\\"\\/auto_auto_1fr_auto\\] {\n grid-template: "breadcrumbs breadcrumbs breadcrumbs indicator""icon title tag indicator""description description description indicator"/auto auto 1fr auto;\n}\n.\\[inset-inline-start\\:var\\(--start\\2c 0px\\)\\] {\n inset-inline-start: var(--start,0px);\n}\n.\\[overflow-wrap\\:anywhere\\] {\n overflow-wrap: anywhere;\n}\n.\\[scrollbar-color\\:var\\(--scrollbar-color\\)_transparent\\] {\n scrollbar-color: var(--scrollbar-color) transparent;\n}\n.\\[scrollbar-width\\:thin\\] {\n scrollbar-width: thin;\n}\n.\\[transition-duration\\:0\\.02s\\] {\n transition-duration: 0.02s;\n}\n.\\[transition-property\\:common\\] {\n transition-property: common;\n}\n\n:where(.inkeep-widget-vars) {\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n font-family: var(--ikp-font-family-body);\n font-size: var(--ikp-font-size-md);\n line-height: 1.5;\n color: var(--ikp-color-gray-800);\n}\n\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) {\n color: var(--ikp-color-white-alpha-950);\n}\n\n:where(.inkeep-widget-vars) *,\n:where(.inkeep-widget-vars) *::before,\n:where(.inkeep-widget-vars) *::after {\n border-color: var(--ikp-color-gray-200);\n}\n\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) *,\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) *::before,\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) *::after {\n border-color: var(--ikp-color-white-alpha-200);\n}\n\n:where(.inkeep-widget-vars) input::-moz-placeholder, :where(.inkeep-widget-vars) textarea::-moz-placeholder {\n color: var(--ikp-color-gray-500);\n}\n\n:where(.inkeep-widget-vars) input::placeholder,\n:where(.inkeep-widget-vars) textarea::placeholder {\n color: var(--ikp-color-gray-500);\n}\n\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) input::-moz-placeholder, [data-theme=\'dark\'] :where(.inkeep-widget-vars) textarea::-moz-placeholder {\n color: var(--ikp-color-white-alpha-500);\n}\n\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) input::placeholder,\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) textarea::placeholder {\n color: var(--ikp-color-white-alpha-500);\n}\n\n:where(.inkeep-widget-vars) [data-part=\'icon\'][data-type=\'built-in\'] {\n display: inline-block;\n min-height: 1em;\n min-width: 1em;\n flex-shrink: 0;\n vertical-align: middle;\n line-height: 1em;\n}\n\nsvg[data-part=\'icon\'][data-type=\'custom\'] {\n /* we don\'t want the wrapper divs to affect layout / positioning of icon */\n display: contents;\n}\n\nsvg[data-part=\'icon\'][data-type=\'custom\'] div {\n display: contents;\n}\n\nimg[data-part=\'icon\'][data-type=\'custom\'] {\n display: inline-block;\n min-height: 1em;\n min-width: 1em;\n}\n\n.\\*\\:invisible > * {\n visibility: hidden;\n}\n\n.\\*\\:m-0 > * {\n margin: 0px;\n}\n\n.file\\:h-full::file-selector-button {\n height: 100%;\n}\n\n.file\\:cursor-pointer::file-selector-button {\n cursor: pointer;\n}\n\n.file\\:border-none::file-selector-button {\n border-style: none;\n}\n\n.file\\:bg-transparent::file-selector-button {\n background-color: transparent;\n}\n\n.file\\:text-sm::file-selector-button {\n font-size: var(--ikp-font-size-sm);\n}\n\n.file\\:font-medium::file-selector-button {\n font-weight: 500;\n}\n\n.file\\:text-gray-700::file-selector-button {\n color: var(--ikp-color-gray-700);\n}\n\n.placeholder\\:text-gray-500::-moz-placeholder {\n color: var(--ikp-color-gray-500);\n}\n\n.placeholder\\:text-gray-500::placeholder {\n color: var(--ikp-color-gray-500);\n}\n\n.before\\:pointer-events-none::before {\n content: var(--tw-content);\n pointer-events: none;\n}\n\n.before\\:invisible::before {\n content: var(--tw-content);\n visibility: hidden;\n}\n\n.before\\:absolute::before {\n content: var(--tw-content);\n position: absolute;\n}\n\n.before\\:left-0::before {\n content: var(--tw-content);\n left: 0px;\n}\n\n.before\\:top-0::before {\n content: var(--tw-content);\n top: 0px;\n}\n\n.before\\:z-hide::before {\n content: var(--tw-content);\n z-index: var(--ikp-z-index-hide);\n}\n\n.before\\:m-auto::before {\n content: var(--tw-content);\n margin: auto;\n}\n\n.before\\:block::before {\n content: var(--tw-content);\n display: block;\n}\n\n.before\\:h-3::before {\n content: var(--tw-content);\n height: 0.75rem;\n}\n\n.before\\:h-\\[--before-size\\]::before {\n content: var(--tw-content);\n height: var(--before-size);\n}\n\n.before\\:w-\\[--before-size\\]::before {\n content: var(--tw-content);\n width: var(--before-size);\n}\n\n.before\\:w-full::before {\n content: var(--tw-content);\n width: 100%;\n}\n\n.before\\:-translate-y-full::before {\n content: var(--tw-content);\n --tw-translate-y: -100%;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.before\\:bg-gray-300::before {\n content: var(--tw-content);\n background-color: var(--ikp-color-gray-300);\n}\n\n.before\\:bg-\\[linear-gradient\\(transparent\\2c _white\\)\\]::before {\n content: var(--tw-content);\n background-image: linear-gradient(transparent, white);\n}\n\n.before\\:bg-\\[linear-gradient\\(white\\2c _transparent\\)\\]::before {\n content: var(--tw-content);\n background-image: linear-gradient(white, transparent);\n}\n\n.before\\:bg-no-repeat::before {\n content: var(--tw-content);\n background-repeat: no-repeat;\n}\n\n.before\\:\\[background-position\\:0_0\\]::before {\n content: var(--tw-content);\n background-position: 0 0;\n}\n\n.before\\:\\[background-size\\:cover\\]::before {\n content: var(--tw-content);\n background-size: cover;\n}\n\n.after\\:invisible::after {\n content: var(--tw-content);\n visibility: hidden;\n}\n\n.after\\:absolute::after {\n content: var(--tw-content);\n position: absolute;\n}\n\n.after\\:bottom-0::after {\n content: var(--tw-content);\n bottom: 0px;\n}\n\n.after\\:left-0::after {\n content: var(--tw-content);\n left: 0px;\n}\n\n.after\\:left-\\[1px\\]::after {\n content: var(--tw-content);\n left: 1px;\n}\n\n.after\\:top-0::after {\n content: var(--tw-content);\n top: 0px;\n}\n\n.after\\:top-\\[1px\\]::after {\n content: var(--tw-content);\n top: 1px;\n}\n\n.after\\:top-full::after {\n content: var(--tw-content);\n top: 100%;\n}\n\n.after\\:z-base::after {\n content: var(--tw-content);\n z-index: var(--ikp-z-index-base);\n}\n\n.after\\:z-start::after {\n content: var(--tw-content);\n z-index: var(--ikp-z-index-start);\n}\n\n.after\\:h-3::after {\n content: var(--tw-content);\n height: 0.75rem;\n}\n\n.after\\:h-\\[calc\\(100\\%-2px\\)\\]::after {\n content: var(--tw-content);\n height: calc(100% - 2px);\n}\n\n.after\\:w-0\\.5::after {\n content: var(--tw-content);\n width: 0.125rem;\n}\n\n.after\\:w-\\[calc\\(100\\%-2px\\)\\]::after {\n content: var(--tw-content);\n width: calc(100% - 2px);\n}\n\n.after\\:w-full::after {\n content: var(--tw-content);\n width: 100%;\n}\n\n.after\\:rounded-\\[5px\\]::after {\n content: var(--tw-content);\n border-radius: 5px;\n}\n\n.after\\:bg-inkeep-primary-medium::after {\n content: var(--tw-content);\n background-color: var(--ikp-color-inkeep-primary-medium);\n}\n\n.after\\:bg-white::after {\n content: var(--tw-content);\n --tw-bg-opacity: 1;\n background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));\n}\n\n.after\\:bg-\\[linear-gradient\\(currentColor\\2c _transparent\\)\\]::after {\n content: var(--tw-content);\n background-image: linear-gradient(currentColor, transparent);\n}\n\n.after\\:bg-\\[linear-gradient\\(transparent\\2c _white\\)\\]::after {\n content: var(--tw-content);\n background-image: linear-gradient(transparent, white);\n}\n\n.after\\:text-white::after {\n content: var(--tw-content);\n --tw-text-opacity: 1;\n color: rgb(255 255 255 / var(--tw-text-opacity, 1));\n}\n\n.after\\:content-\\[\\"\\"\\]::after {\n --tw-content: "";\n content: var(--tw-content);\n}\n\n.first\\:w-full:first-child {\n width: 100%;\n}\n\n.last-of-type\\:hidden:last-of-type {\n display: none;\n}\n\n.focus\\:z-base:focus {\n z-index: var(--ikp-z-index-base);\n}\n\n.focus\\:z-start:focus {\n z-index: var(--ikp-z-index-start);\n}\n\n.focus\\:bg-gray-100:focus {\n background-color: var(--ikp-color-gray-100);\n}\n\n.focus\\:outline-none:focus {\n outline: 2px solid transparent;\n outline-offset: 2px;\n}\n\n.focus\\:outline-inkeep-expanded-primary-700:focus {\n outline-color: var(--ikp-color-inkeep-expanded-primary-700);\n}\n\n.focus\\:\\[--shadow-color\\:theme\\(colors\\.blue\\.500\\)\\]:focus {\n --shadow-color: #3b82f6;\n}\n\n.focus-visible\\:outline-none:focus-visible {\n outline: 2px solid transparent;\n outline-offset: 2px;\n}\n\n.focus-visible\\:ring:focus-visible {\n --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);\n --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color);\n box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000);\n}\n\n.focus-visible\\:ring-2:focus-visible {\n --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);\n --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);\n box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000);\n}\n\n.focus-visible\\:ring-gray-500:focus-visible {\n --tw-ring-color: var(--ikp-color-gray-500);\n}\n\n.focus-visible\\:ring-offset-2:focus-visible {\n --tw-ring-offset-width: 2px;\n}\n\n.active\\:bg-gray-200:active {\n background-color: var(--ikp-color-gray-200);\n}\n\n.active\\:bg-gray-300:active {\n background-color: var(--ikp-color-gray-300);\n}\n\n.active\\:bg-gray-50:active {\n background-color: var(--ikp-color-gray-50);\n}\n\n.active\\:bg-gray-900:active {\n background-color: var(--ikp-color-gray-900);\n}\n\n.disabled\\:cursor-not-allowed:disabled {\n cursor: not-allowed;\n}\n\n.disabled\\:text-gray-500:disabled {\n color: var(--ikp-color-gray-500);\n}\n\n.disabled\\:opacity-40:disabled {\n opacity: 0.4;\n}\n\n.disabled\\:opacity-50:disabled {\n opacity: 0.5;\n}\n\n.disabled\\:shadow-none:disabled {\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n.active\\:disabled\\:\\[background\\:none\\]:disabled:active {\n background: none;\n}\n\n.group:hover .group-hover\\:text-gray-600 {\n color: var(--ikp-color-gray-600);\n}\n\n.has-\\[\\[data-dual-pane-search-expanded\\]\\]\\:w-\\[min\\(90vw\\2c 1000px\\)\\]:has([data-dual-pane-search-expanded]) {\n width: min(90vw,1000px);\n}\n\n.has-\\[\\[data-scroll-top\\]\\]\\:before\\:opacity-0:has([data-scroll-top])::before {\n content: var(--tw-content);\n opacity: 0;\n}\n\n.has-\\[\\[data-scroll-bottom\\]\\]\\:after\\:opacity-0:has([data-scroll-bottom])::after {\n content: var(--tw-content);\n opacity: 0;\n}\n\n.data-\\[disabled\\]\\:pointer-events-none[data-disabled] {\n pointer-events: none;\n}\n\n.data-\\[state\\=closed\\]\\:pointer-events-none[data-state="closed"] {\n pointer-events: none;\n}\n\n.data-\\[state\\=open\\]\\:pointer-events-auto[data-state="open"] {\n pointer-events: auto;\n}\n\n.data-\\[mobile\\]\\:inset-0[data-mobile] {\n inset: 0px;\n}\n\n.data-\\[even\\]\\:ml-0[data-even] {\n margin-left: 0px;\n}\n\n.data-\\[even\\]\\:mr-4[data-even] {\n margin-right: 1rem;\n}\n\n.data-\\[position\\=left\\]\\:mr-1[data-position="left"] {\n margin-right: 0.25rem;\n}\n\n.data-\\[position\\=right\\]\\:ml-1[data-position="right"] {\n margin-left: 0.25rem;\n}\n\n.data-\\[role\\=user\\]\\:ml-0[data-role="user"] {\n margin-left: 0px;\n}\n\n.data-\\[role\\=user\\]\\:block[data-role="user"] {\n display: block;\n}\n\n.data-\\[has-results\\]\\:flex[data-has-results] {\n display: flex;\n}\n\n.data-\\[escalated\\]\\:hidden[data-escalated] {\n display: none;\n}\n\n.data-\\[hidden\\]\\:hidden[data-hidden] {\n display: none;\n}\n\n.data-\\[role\\=user\\]\\:hidden[data-role="user"] {\n display: none;\n}\n\n.data-\\[state\\=closed\\]\\:hidden[data-state="closed"] {\n display: none;\n}\n\n.data-\\[submitted\\]\\:hidden[data-submitted] {\n display: none;\n}\n\n.data-\\[has-content\\]\\:h-\\[min\\(calc\\(85vh_-_72px\\)\\2c calc\\(850px_-_72px_-_275px\\)\\)\\][data-has-content] {\n height: min(calc(85vh - 72px),calc(850px - 72px - 275px));\n}\n\n.data-\\[mobile\\]\\:h-\\[unset\\][data-mobile] {\n height: unset;\n}\n\n.data-\\[composite\\]\\:w-full[data-composite] {\n width: 100%;\n}\n\n.data-\\[mobile\\]\\:w-\\[unset\\][data-mobile] {\n width: unset;\n}\n\n.data-\\[role\\=user\\]\\:grow-0[data-role="user"] {\n flex-grow: 0;\n}\n\n.data-\\[side\\=bottom\\]\\:translate-y-1\\.5[data-side="bottom"] {\n --tw-translate-y: 0.375rem;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.data-\\[side\\=left\\]\\:-translate-x-1\\.5[data-side="left"] {\n --tw-translate-x: -0.375rem;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.data-\\[side\\=right\\]\\:translate-x-1\\.5[data-side="right"] {\n --tw-translate-x: 0.375rem;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.data-\\[side\\=top\\]\\:-translate-y-1\\.5[data-side="top"] {\n --tw-translate-y: -0.375rem;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.data-\\[mobile\\]\\:transform-none[data-mobile] {\n transform: none;\n}\n\n@keyframes fade-out {\n\n 0% {\n opacity: 1;\n }\n\n 100% {\n opacity: 0;\n }\n}\n\n.data-\\[state\\=closed\\]\\:animate-fade-out[data-state="closed"] {\n animation: fade-out 0.2s ease-out;\n}\n\n@keyframes slide-out-left {\n\n 0% {\n transform: translateX(0%);\n }\n\n 100% {\n transform: translateX(-100%);\n }\n}\n\n.data-\\[state\\=closed\\]\\:data-\\[position\\=left\\]\\:animate-sidebar-out-left[data-position="left"][data-state="closed"] {\n animation: slide-out-left 200ms cubic-bezier(0.3, 0.0, 0.8, 0.15);\n}\n\n@keyframes slide-out-right {\n\n 0% {\n transform: translateX(0%);\n }\n\n 100% {\n transform: translateX(100%);\n }\n}\n\n.data-\\[state\\=closed\\]\\:data-\\[position\\=right\\]\\:animate-sidebar-out-right[data-position="right"][data-state="closed"] {\n animation: slide-out-right 200ms cubic-bezier(0.3, 0.0, 0.8, 0.15);\n}\n\n@keyframes fade-in {\n\n 0% {\n opacity: 0;\n }\n\n 100% {\n opacity: 1;\n }\n}\n\n.data-\\[state\\=open\\]\\:animate-\\[fade-in_0\\.15s_ease-out\\][data-state="open"] {\n animation: fade-in 0.15s ease-out;\n}\n\n@keyframes fade-in {\n\n 0% {\n opacity: 0;\n }\n\n 100% {\n opacity: 1;\n }\n}\n\n.data-\\[state\\=open\\]\\:animate-fade-in[data-state="open"] {\n animation: fade-in 0.25s ease-out;\n}\n\n@keyframes slide-in-left {\n\n 0% {\n transform: translateX(-100%);\n }\n\n 100% {\n transform: translateX(0%);\n }\n}\n\n.data-\\[state\\=open\\]\\:data-\\[position\\=left\\]\\:animate-sidebar-in-left[data-position="left"][data-state="open"] {\n animation: slide-in-left 400ms cubic-bezier(0.05, 0.7, 0.1, 1.0);\n}\n\n@keyframes slide-in-right {\n\n 0% {\n transform: translateX(100%);\n }\n\n 100% {\n transform: translateX(0%);\n }\n}\n\n.data-\\[state\\=open\\]\\:data-\\[position\\=right\\]\\:animate-sidebar-in-right[data-position="right"][data-state="open"] {\n animation: slide-in-right 400ms cubic-bezier(0.05, 0.7, 0.1, 1.0);\n}\n\n.data-\\[loading\\]\\:cursor-wait[data-loading] {\n cursor: wait;\n}\n\n.data-\\[even\\]\\:flex-row[data-even] {\n flex-direction: row;\n}\n\n.data-\\[input-type\\=checkbox\\]\\:flex-row[data-input-type="checkbox"] {\n flex-direction: row;\n}\n\n.data-\\[even\\]\\:items-start[data-even] {\n align-items: flex-start;\n}\n\n.data-\\[input-type\\=checkbox\\]\\:items-center[data-input-type="checkbox"] {\n align-items: center;\n}\n\n.data-\\[role\\=user\\]\\:justify-end[data-role="user"] {\n justify-content: flex-end;\n}\n\n.data-\\[role\\=user\\]\\:whitespace-pre-wrap[data-role="user"] {\n white-space: pre-wrap;\n}\n\n.data-\\[mobile\\]\\:rounded-none[data-mobile] {\n border-radius: 0px;\n}\n\n.data-\\[position\\=left\\]\\:border-r[data-position="left"] {\n border-right-width: 1px;\n}\n\n.data-\\[position\\=right\\]\\:border-l[data-position="right"] {\n border-left-width: 1px;\n}\n\n.data-\\[invalid\\]\\:border-\\[--error-border-color\\][data-invalid] {\n border-color: var(--error-border-color);\n}\n\n.data-\\[state\\=active\\]\\:border-inkeep-primary-medium-subtle[data-state="active"] {\n border-color: var(--ikp-color-inkeep-primary-medium-subtle);\n}\n\n.data-\\[state\\=checked\\]\\:border-gray-1000[data-state="checked"] {\n border-color: var(--ikp-color-gray-1000);\n}\n\n.data-\\[active\\]\\:bg-white[data-active] {\n --tw-bg-opacity: 1;\n background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));\n}\n\n.data-\\[role\\=user\\]\\:bg-gray-50[data-role="user"] {\n background-color: var(--ikp-color-gray-50);\n}\n\n.data-\\[state\\=active\\]\\:bg-inkeep-primary-light-subtle[data-state="active"] {\n background-color: var(--ikp-color-inkeep-primary-light-subtle);\n}\n\n.data-\\[state\\=checked\\]\\:bg-gray-1000[data-state="checked"] {\n background-color: var(--ikp-color-gray-1000);\n}\n\n.data-\\[username\\]\\:bg-inkeep-primary-lighter[data-username] {\n background-color: var(--ikp-color-inkeep-primary-lighter);\n}\n\n.data-\\[has-content\\]\\:pb-2[data-has-content] {\n padding-bottom: 0.5rem;\n}\n\n.data-\\[position\\=left\\]\\:pr-1[data-position="left"] {\n padding-right: 0.25rem;\n}\n\n.data-\\[position\\=right\\]\\:pl-1[data-position="right"] {\n padding-left: 0.25rem;\n}\n\n.data-\\[is-numeric\\=true\\]\\:text-end[data-is-numeric="true"] {\n text-align: end;\n}\n\n.data-\\[highlighted\\]\\:font-semibold[data-highlighted] {\n font-weight: 600;\n}\n\n.data-\\[active\\]\\:text-gray-600[data-active] {\n color: var(--ikp-color-gray-600);\n}\n\n.data-\\[active\\]\\:text-gray-800[data-active] {\n color: var(--ikp-color-gray-800);\n}\n\n.data-\\[copied\\]\\:text-inkeep-primary-medium[data-copied] {\n color: var(--ikp-color-inkeep-primary-medium);\n}\n\n.data-\\[downvoted\\]\\:text-inkeep-primary-medium[data-downvoted] {\n color: var(--ikp-color-inkeep-primary-medium);\n}\n\n.data-\\[highlighted\\]\\:text-inkeep-primary-text-subtle[data-highlighted] {\n color: var(--ikp-color-inkeep-primary-text-subtle);\n}\n\n.data-\\[is-match\\]\\:text-inkeep-expanded-primary-700[data-is-match] {\n color: var(--ikp-color-inkeep-expanded-primary-700);\n}\n\n.data-\\[role\\=user\\]\\:text-gray-700[data-role="user"] {\n color: var(--ikp-color-gray-700);\n}\n\n.data-\\[state\\=active\\]\\:text-inkeep-expanded-primary-900[data-state="active"] {\n color: var(--ikp-color-inkeep-expanded-primary-900);\n}\n\n.data-\\[state\\=checked\\]\\:text-white[data-state="checked"] {\n --tw-text-opacity: 1;\n color: rgb(255 255 255 / var(--tw-text-opacity, 1));\n}\n\n.data-\\[type\\=\\"stackoverflow\\"\\]\\:text-green-500[data-type="stackoverflow"] {\n --tw-text-opacity: 1;\n color: rgb(34 197 94 / var(--tw-text-opacity, 1));\n}\n\n.data-\\[type\\=icon\\]\\:data-\\[role\\=user\\]\\:text-inkeep-primary-medium[data-role="user"][data-type="icon"] {\n color: var(--ikp-color-inkeep-primary-medium);\n}\n\n.data-\\[type\\^\\=\\"github\\"\\]\\:text-purple-500[data-type^="github"] {\n --tw-text-opacity: 1;\n color: rgb(168 85 247 / var(--tw-text-opacity, 1));\n}\n\n.data-\\[upvoted\\]\\:text-inkeep-primary-medium[data-upvoted] {\n color: var(--ikp-color-inkeep-primary-medium);\n}\n\n.data-\\[disabled\\]\\:opacity-50[data-disabled] {\n opacity: 0.5;\n}\n\n.data-\\[state\\=closed\\]\\:opacity-0[data-state="closed"] {\n opacity: 0;\n}\n\n.data-\\[active\\]\\:shadow[data-active] {\n --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);\n --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n.data-\\[invalid\\]\\:shadow-\\[0_0_0_1px_var\\(--error-border-color\\)\\][data-invalid] {\n --tw-shadow: 0 0 0 1px var(--error-border-color);\n --tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n.data-\\[disable-transitions\\]\\:transition-none[data-disable-transitions] {\n transition-property: none;\n}\n\n.data-\\[type\\=icon\\]\\:\\[--end-color\\:theme\\(colors\\.inkeep-expanded-primary\\.300\\)\\][data-type="icon"] {\n --end-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.data-\\[type\\=icon\\]\\:data-\\[role\\=assistant\\]\\:\\[--end-color\\:theme\\(colors\\.inkeep-expanded-primary\\.700\\)\\][data-role="assistant"][data-type="icon"] {\n --end-color: var(--ikp-color-inkeep-expanded-primary-700);\n}\n\n.data-\\[mobile\\]\\:\\[--input-height\\:theme\\(spacing\\.20\\)\\][data-mobile] {\n --input-height: 5rem;\n}\n\n.data-\\[invalid\\]\\:\\[--shadow-color\\:theme\\(colors\\.red\\.500\\)\\][data-invalid] {\n --shadow-color: #ef4444;\n}\n\n.data-\\[type\\=icon\\]\\:data-\\[role\\=assistant\\]\\:\\[--start-color\\:theme\\(colors\\.inkeep-expanded-primary\\.300\\)\\][data-role="assistant"][data-type="icon"] {\n --start-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.data-\\[type\\=icon\\]\\:\\[--start-color\\:theme\\(colors\\.inkeep-expanded-primary\\.50\\)\\][data-type="icon"] {\n --start-color: var(--ikp-color-inkeep-expanded-primary-50);\n}\n\n.data-\\[required\\]\\:after\\:absolute[data-required]::after {\n content: var(--tw-content);\n position: absolute;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:absolute[data-show-toolbar]::after {\n content: var(--tw-content);\n position: absolute;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:left-0[data-show-toolbar]::after {\n content: var(--tw-content);\n left: 0px;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:top-full[data-show-toolbar]::after {\n content: var(--tw-content);\n top: 100%;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:z-start[data-show-toolbar]::after {\n content: var(--tw-content);\n z-index: var(--ikp-z-index-start);\n}\n\n.data-\\[required\\]\\:after\\:ml-1[data-required]::after {\n content: var(--tw-content);\n margin-left: 0.25rem;\n}\n\n.data-\\[required\\]\\:after\\:mt-0[data-required]::after {\n content: var(--tw-content);\n margin-top: 0px;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:h-\\[1rem\\][data-show-toolbar]::after {\n content: var(--tw-content);\n height: 1rem;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:w-full[data-show-toolbar]::after {\n content: var(--tw-content);\n width: 100%;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:bg-\\[linear-gradient\\(currentColor\\2c _transparent\\)\\][data-show-toolbar]::after {\n content: var(--tw-content);\n background-image: linear-gradient(currentColor, transparent);\n}\n\n.data-\\[required\\]\\:after\\:text-red-500[data-required]::after {\n content: var(--tw-content);\n --tw-text-opacity: 1;\n color: rgb(239 68 68 / var(--tw-text-opacity, 1));\n}\n\n.data-\\[show-toolbar\\]\\:after\\:text-white[data-show-toolbar]::after {\n content: var(--tw-content);\n --tw-text-opacity: 1;\n color: rgb(255 255 255 / var(--tw-text-opacity, 1));\n}\n\n.data-\\[required\\]\\:after\\:\\[content\\:\\"\\*\\"\\][data-required]::after {\n content: "*";\n}\n\n@keyframes spin {\n\n to {\n content: var(--tw-content);\n transform: rotate(360deg);\n }\n}\n\n.data-\\[highlight\\]\\:first\\:before\\:animate-\\[spin_4s_linear_infinite\\]:first-child[data-highlight]::before {\n content: var(--tw-content);\n animation: spin 4s linear infinite;\n}\n\n.data-\\[highlight\\]\\:first\\:before\\:\\[background-image\\:conic-gradient\\(transparent\\2c theme\\(colors\\.inkeep-expanded-primary\\.600\\)\\2c transparent_30\\%\\)\\]:first-child[data-highlight]::before {\n content: var(--tw-content);\n background-image: conic-gradient(transparent,var(--ikp-color-inkeep-expanded-primary-600),transparent 30%);\n}\n\n:not(.dark) .light\\:text-gray-700 {\n color: var(--ikp-color-gray-700);\n}\n\n[data-widget-md] .ikp-md\\:mb-0 {\n margin-bottom: 0px;\n}\n\n[data-widget-md] .ikp-md\\:flex {\n display: flex;\n}\n\n[data-widget-md] .ikp-md\\:hidden {\n display: none;\n}\n\n[data-widget-md] .ikp-md\\:h-12 {\n height: 3rem;\n}\n\n[data-widget-md] .ikp-md\\:flex-row {\n flex-direction: row;\n}\n\n[data-widget-md] .ikp-md\\:flex-col {\n flex-direction: column;\n}\n\n[data-widget-md] .ikp-md\\:items-start {\n align-items: flex-start;\n}\n\n[data-widget-md] .ikp-md\\:px-10 {\n padding-left: 2.5rem;\n padding-right: 2.5rem;\n}\n\n[data-widget-md] .ikp-md\\:py-14 {\n padding-top: 3.5rem;\n padding-bottom: 3.5rem;\n}\n\n[data-widget-md] .ikp-md\\:pb-14 {\n padding-bottom: 3.5rem;\n}\n\n[data-widget-md] .ikp-md\\:pl-3 {\n padding-left: 0.75rem;\n}\n\n[data-widget-md] .ikp-md\\:pr-3 {\n padding-right: 0.75rem;\n}\n\n[data-widget-md] .ikp-md\\:pr-6 {\n padding-right: 1.5rem;\n}\n\n.hover\\:scale-110:hover:not(:disabled) {\n --tw-scale-x: 1.1;\n --tw-scale-y: 1.1;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.hover\\:border-gray-300:hover:not(:disabled) {\n border-color: var(--ikp-color-gray-300);\n}\n\n.hover\\:bg-gray-100:hover:not(:disabled) {\n background-color: var(--ikp-color-gray-100);\n}\n\n.hover\\:bg-gray-200:hover:not(:disabled) {\n background-color: var(--ikp-color-gray-200);\n}\n\n.hover\\:bg-gray-50:hover:not(:disabled) {\n background-color: var(--ikp-color-gray-50);\n}\n\n.hover\\:bg-gray-900:hover:not(:disabled) {\n background-color: var(--ikp-color-gray-900);\n}\n\n.hover\\:bg-inkeep-primary-light-subtle:hover:not(:disabled) {\n background-color: var(--ikp-color-inkeep-primary-light-subtle);\n}\n\n.hover\\:bg-transparent:hover:not(:disabled) {\n background-color: transparent;\n}\n\n.hover\\:text-gray-700:hover:not(:disabled) {\n color: var(--ikp-color-gray-700);\n}\n\n.hover\\:text-gray-800:hover:not(:disabled) {\n color: var(--ikp-color-gray-800);\n}\n\n.hover\\:text-inkeep-primary-strong:hover:not(:disabled) {\n color: var(--ikp-color-inkeep-primary-strong);\n}\n\n.hover\\:text-inkeep-primary-stronger:hover:not(:disabled) {\n color: var(--ikp-color-inkeep-primary-stronger);\n}\n\n.hover\\:underline:hover:not(:disabled) {\n text-decoration-line: underline;\n}\n\n.hover\\:opacity-100:hover:not(:disabled) {\n opacity: 1;\n}\n\n.hover\\:disabled\\:bg-gray-100:disabled:hover:not(:disabled) {\n background-color: var(--ikp-color-gray-100);\n}\n\n.hover\\:disabled\\:\\[background\\:none\\]:disabled:hover:not(:disabled) {\n background: none;\n}\n\n.hover\\:data-\\[state\\=active\\]\\:bg-inkeep-primary-light-subtle[data-state="active"]:hover:not(:disabled) {\n background-color: var(--ikp-color-inkeep-primary-light-subtle);\n}\n\n.data-\\[is-match\\]\\:hover\\:text-inkeep-expanded-primary-800:hover:not(:disabled)[data-is-match] {\n color: var(--ikp-color-inkeep-expanded-primary-800);\n}\n\n.befter\\:pointer-events-none::before {\n pointer-events: none;\n}\n\n.befter\\:absolute::before {\n position: absolute;\n}\n\n.befter\\:inset-x-0::before {\n left: 0px;\n right: 0px;\n}\n\n.befter\\:h-10::before {\n height: 2.5rem;\n}\n\n.befter\\:transition-opacity::before {\n transition-property: opacity;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n\n.befter\\:duration-300::before {\n transition-duration: 300ms;\n}\n\n.befter\\:ease-in-out::before {\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n}\n\n.befter\\:content-\\[\\"\\"\\]::before {\n --tw-content: "";\n content: var(--tw-content);\n}\n\n.befter\\:pointer-events-none::after {\n pointer-events: none;\n}\n\n.befter\\:absolute::after {\n position: absolute;\n}\n\n.befter\\:inset-x-0::after {\n left: 0px;\n right: 0px;\n}\n\n.befter\\:h-10::after {\n height: 2.5rem;\n}\n\n.befter\\:transition-opacity::after {\n transition-property: opacity;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n\n.befter\\:duration-300::after {\n transition-duration: 300ms;\n}\n\n.befter\\:ease-in-out::after {\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n}\n\n.befter\\:content-\\[\\"\\"\\]::after {\n --tw-content: "";\n content: var(--tw-content);\n}\n\n.selected\\:border-inkeep-primary-medium-subtle[data-selected="true"] {\n border-color: var(--ikp-color-inkeep-primary-medium-subtle);\n}\n\n.selected\\:bg-inkeep-primary-light-subtle[data-selected="true"] {\n background-color: var(--ikp-color-inkeep-primary-light-subtle);\n}\n\n.selected\\:text-inkeep-primary-strong[data-selected="true"] {\n color: var(--ikp-color-inkeep-primary-strong);\n}\n\n.selected\\:border-inkeep-primary-medium-subtle:hover {\n border-color: var(--ikp-color-inkeep-primary-medium-subtle);\n}\n\n.selected\\:bg-inkeep-primary-light-subtle:hover {\n background-color: var(--ikp-color-inkeep-primary-light-subtle);\n}\n\n.selected\\:text-inkeep-primary-strong:hover {\n color: var(--ikp-color-inkeep-primary-strong);\n}\n\n.group[data-selected="true"] .group-selected\\:text-inkeep-primary-strong {\n color: var(--ikp-color-inkeep-primary-strong);\n}\n\n.group[data-selected="true"] .group-selected\\:text-inkeep-primary-text-bold {\n color: var(--ikp-color-inkeep-primary-text-bold);\n}\n\n.group[data-selected="true"] .group-selected\\:text-inkeep-primary-text-subtle {\n color: var(--ikp-color-inkeep-primary-text-subtle);\n}\n\n.group[data-selected="true"] .group-selected\\:opacity-100 {\n opacity: 1;\n}\n\n.group:hover .group-selected\\:text-inkeep-primary-strong {\n color: var(--ikp-color-inkeep-primary-strong);\n}\n\n.group:hover .group-selected\\:text-inkeep-primary-text-bold {\n color: var(--ikp-color-inkeep-primary-text-bold);\n}\n\n.group:hover .group-selected\\:text-inkeep-primary-text-subtle {\n color: var(--ikp-color-inkeep-primary-text-subtle);\n}\n\n.group:hover .group-selected\\:opacity-100 {\n opacity: 1;\n}\n\n.dark\\:border-gray-700:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-gray-700);\n}\n\n.dark\\:border-gray-dark-500:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-gray-dark-500);\n}\n\n.dark\\:border-gray-dark-700:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-gray-dark-700);\n}\n\n.dark\\:border-inkeep-expanded-primary-200:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-inkeep-expanded-primary-200);\n}\n\n.dark\\:border-white-alpha-200:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-white-alpha-200);\n}\n\n.dark\\:bg-gray-dark-600:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-600);\n}\n\n.dark\\:bg-gray-dark-700:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-700);\n}\n\n.dark\\:bg-gray-dark-800:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-800);\n}\n\n.dark\\:bg-gray-dark-900:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-900);\n}\n\n.dark\\:bg-gray-dark-950:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-950);\n}\n\n.dark\\:bg-inkeep-expanded-primary-300:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:bg-overlay-dark:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-overlay-dark);\n}\n\n.dark\\:bg-transparent:is([data-theme="dark"] *) {\n background-color: transparent;\n}\n\n.dark\\:bg-white-alpha-100:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.dark\\:bg-white-alpha-200:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-200);\n}\n\n.dark\\:bg-white-alpha-50:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-50);\n}\n\n.dark\\:bg-white-alpha-800:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-800);\n}\n\n.dark\\:bg-\\[linear-gradient\\(to_bottom_right\\2c _var\\(--ikp-color-gray-dark-300\\)\\2c _var\\(--ikp-color-gray-dark-100\\)\\)\\]:is([data-theme="dark"] *) {\n background-image: linear-gradient(to bottom right, var(--ikp-color-gray-dark-300), var(--ikp-color-gray-dark-100));\n}\n\n.dark\\:bg-\\[linear-gradient\\(to_top\\2c _var\\(--ikp-color-gray-dark-600\\)\\2c _transparent\\)\\]:is([data-theme="dark"] *) {\n background-image: linear-gradient(to top, var(--ikp-color-gray-dark-600), transparent);\n}\n\n.dark\\:fill-gray-dark-800:is([data-theme="dark"] *) {\n fill: var(--ikp-color-gray-dark-800);\n}\n\n.dark\\:text-gray-200:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-200);\n}\n\n.dark\\:text-gray-400:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-400);\n}\n\n.dark\\:text-gray-dark-100:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-100);\n}\n\n.dark\\:text-gray-dark-200:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-200);\n}\n\n.dark\\:text-gray-dark-300:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-300);\n}\n\n.dark\\:text-gray-dark-400:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-400);\n}\n\n.dark\\:text-gray-dark-950:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-950);\n}\n\n.dark\\:text-inkeep-expanded-primary-100:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-100);\n}\n\n.dark\\:text-inkeep-expanded-primary-300:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:text-inkeep-expanded-primary-500:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-500);\n}\n\n.dark\\:text-red-300:is([data-theme="dark"] *) {\n --tw-text-opacity: 1;\n color: rgb(252 165 165 / var(--tw-text-opacity, 1));\n}\n\n.dark\\:text-white-alpha-500:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-500);\n}\n\n.dark\\:text-white-alpha-600:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-600);\n}\n\n.dark\\:text-white-alpha-700:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-700);\n}\n\n.dark\\:text-white-alpha-900:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-900);\n}\n\n.dark\\:text-white-alpha-950:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-950);\n}\n\n.dark\\:shadow-none:is([data-theme="dark"] *) {\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n.dark\\:shadow-\\[none\\]:is([data-theme="dark"] *) {\n --tw-shadow-color: none;\n --tw-shadow: var(--tw-shadow-colored);\n}\n\n.dark\\:\\[--end-color\\:theme\\(colors\\.gray-dark\\.600\\)\\]:is([data-theme="dark"] *) {\n --end-color: var(--ikp-color-gray-dark-600);\n}\n\n.dark\\:\\[--end-color\\:theme\\(colors\\.inkeep-expanded-primary\\.300\\)\\]:is([data-theme="dark"] *) {\n --end-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:\\[--end-color\\:theme\\(colors\\.white-alpha\\.300\\)\\]:is([data-theme="dark"] *) {\n --end-color: var(--ikp-color-white-alpha-300);\n}\n\n.dark\\:\\[--error-border-color\\:theme\\(colors\\.red\\.300\\)\\]:is([data-theme="dark"] *) {\n --error-border-color: #fca5a5;\n}\n\n.dark\\:\\[--focus-border-color\\:theme\\(colors\\.blue\\.300\\)\\]:is([data-theme="dark"] *) {\n --focus-border-color: #93c5fd;\n}\n\n.dark\\:\\[--scrollbar-color\\:var\\(--color-gray-dark-600\\)\\]:is([data-theme="dark"] *) {\n --scrollbar-color: var(--color-gray-dark-600);\n}\n\n.dark\\:\\[--start-color\\:theme\\(colors\\.gray-dark\\.800\\)\\]:is([data-theme="dark"] *) {\n --start-color: var(--ikp-color-gray-dark-800);\n}\n\n.dark\\:\\[--start-color\\:theme\\(colors\\.gray\\.300\\)\\]:is([data-theme="dark"] *) {\n --start-color: var(--ikp-color-gray-300);\n}\n\n.dark\\:\\[--start-color\\:theme\\(colors\\.inkeep-expanded-primary\\.50\\)\\]:is([data-theme="dark"] *) {\n --start-color: var(--ikp-color-inkeep-expanded-primary-50);\n}\n\n.dark\\:\\[background\\:linear-gradient\\(270deg\\2c theme\\(colors\\.inkeep-expanded-primary\\.100\\)\\2c transparent\\)_-200\\%_50\\%_\\/_25\\%_100\\%_no-repeat\\2c theme\\(colors\\.inkeep-expanded-primary\\.400\\)\\]:is([data-theme="dark"] *) {\n background: linear-gradient(270deg,var(--ikp-color-inkeep-expanded-primary-100),transparent) -200% 50% / 25% 100% no-repeat,var(--ikp-color-inkeep-expanded-primary-400);\n}\n\n.dark\\:file\\:text-white-alpha-700:is([data-theme="dark"] *)::file-selector-button {\n color: var(--ikp-color-white-alpha-700);\n}\n\n.dark\\:placeholder\\:text-gray-dark-200:is([data-theme="dark"] *)::-moz-placeholder {\n color: var(--ikp-color-gray-dark-200);\n}\n\n.dark\\:placeholder\\:text-gray-dark-200:is([data-theme="dark"] *)::placeholder {\n color: var(--ikp-color-gray-dark-200);\n}\n\n.dark\\:before\\:bg-gray-dark-950:is([data-theme="dark"] *)::before {\n content: var(--tw-content);\n background-color: var(--ikp-color-gray-dark-950);\n}\n\n.dark\\:before\\:bg-\\[linear-gradient\\(transparent\\2c _var\\(--ikp-color-gray-dark-950\\)\\)\\]:is([data-theme="dark"] *)::before {\n content: var(--tw-content);\n background-image: linear-gradient(transparent, var(--ikp-color-gray-dark-950));\n}\n\n.dark\\:before\\:bg-\\[linear-gradient\\(var\\(--ikp-color-gray-dark-950\\)\\2c _transparent\\)\\]:is([data-theme="dark"] *)::before {\n content: var(--tw-content);\n background-image: linear-gradient(var(--ikp-color-gray-dark-950), transparent);\n}\n\n.dark\\:after\\:bg-gray-dark-950:is([data-theme="dark"] *)::after {\n content: var(--tw-content);\n background-color: var(--ikp-color-gray-dark-950);\n}\n\n.dark\\:after\\:bg-inkeep-primary-light:is([data-theme="dark"] *)::after {\n content: var(--tw-content);\n background-color: var(--ikp-color-inkeep-primary-light);\n}\n\n.dark\\:after\\:bg-\\[linear-gradient\\(transparent\\2c _var\\(--ikp-color-gray-dark-950\\)\\)\\]:is([data-theme="dark"] *)::after {\n content: var(--tw-content);\n background-image: linear-gradient(transparent, var(--ikp-color-gray-dark-950));\n}\n\n.after\\:dark\\:text-gray-dark-950:is([data-theme="dark"] *)::after {\n content: var(--tw-content);\n color: var(--ikp-color-gray-dark-950);\n}\n\n.dark\\:focus\\:bg-gray-dark-800:focus:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-800);\n}\n\n.dark\\:focus\\:outline-inkeep-expanded-primary-300:focus:is([data-theme="dark"] *) {\n outline-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:focus-visible\\:ring-white-alpha-900:focus-visible:is([data-theme="dark"] *) {\n --tw-ring-color: var(--ikp-color-white-alpha-900);\n}\n\n.dark\\:focus-visible\\:ring-offset-gray-950:focus-visible:is([data-theme="dark"] *) {\n --tw-ring-offset-color: var(--ikp-color-gray-950);\n}\n\n.dark\\:active\\:bg-inkeep-expanded-primary-200:active:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-inkeep-expanded-primary-200);\n}\n\n.dark\\:active\\:bg-white-alpha-100:active:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.dark\\:active\\:bg-white-alpha-200:active:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-200);\n}\n\n.dark\\:active\\:bg-white-alpha-400:active:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-400);\n}\n\n.dark\\:disabled\\:text-white-alpha-200:disabled:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-200);\n}\n\n.group:hover .dark\\:group-hover\\:text-white-alpha-600:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-600);\n}\n\n.dark\\:data-\\[state\\=active\\]\\:border-inkeep-expanded-primary-300[data-state="active"]:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:data-\\[state\\=checked\\]\\:border-white-alpha-950[data-state="checked"]:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-white-alpha-950);\n}\n\n.dark\\:data-\\[active\\]\\:bg-gray-dark-700[data-active]:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-700);\n}\n\n.dark\\:data-\\[state\\=active\\]\\:bg-white-alpha-100[data-state="active"]:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.dark\\:data-\\[state\\=checked\\]\\:bg-white-alpha-950[data-state="checked"]:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-950);\n}\n\n.dark\\:data-\\[username\\]\\:bg-inkeep-expanded-primary-300[data-username]:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:data-\\[active\\]\\:text-white-alpha-600[data-active]:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-600);\n}\n\n.dark\\:data-\\[active\\]\\:text-white-alpha-950[data-active]:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-950);\n}\n\n.dark\\:data-\\[highlighted\\]\\:text-gray-dark-50[data-highlighted]:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-50);\n}\n\n.dark\\:data-\\[is-match\\]\\:text-inkeep-expanded-primary-300[data-is-match]:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:data-\\[role\\=user\\]\\:text-white-alpha-700[data-role="user"]:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-700);\n}\n\n.dark\\:data-\\[state\\=active\\]\\:text-inkeep-expanded-primary-300[data-state="active"]:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:data-\\[state\\=checked\\]\\:text-gray-1000[data-state="checked"]:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-1000);\n}\n\n.dark\\:data-\\[type\\=icon\\]\\:data-\\[role\\=user\\]\\:text-inkeep-expanded-primary-300[data-role="user"][data-type="icon"]:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.data-\\[downvoted\\]\\:dark\\:text-inkeep-expanded-primary-300:is([data-theme="dark"] *)[data-downvoted] {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.data-\\[upvoted\\]\\:dark\\:text-inkeep-expanded-primary-300:is([data-theme="dark"] *)[data-upvoted] {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:data-\\[type\\=icon\\]\\:data-\\[role\\=assistant\\]\\:\\[--end-color\\:theme\\(colors\\.inkeep-expanded-primary\\.300\\)\\][data-role="assistant"][data-type="icon"]:is([data-theme="dark"] *) {\n --end-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:data-\\[type\\=icon\\]\\:data-\\[role\\=assistant\\]\\:\\[--start-color\\:theme\\(colors\\.inkeep-expanded-primary\\.50\\)\\][data-role="assistant"][data-type="icon"]:is([data-theme="dark"] *) {\n --start-color: var(--ikp-color-inkeep-expanded-primary-50);\n}\n\n.dark\\:data-\\[required\\]\\:after\\:text-red-300[data-required]:is([data-theme="dark"] *)::after {\n content: var(--tw-content);\n --tw-text-opacity: 1;\n color: rgb(252 165 165 / var(--tw-text-opacity, 1));\n}\n\n.data-\\[show-toolbar\\]\\:after\\:dark\\:text-gray-dark-950:is([data-theme="dark"] *)[data-show-toolbar]::after {\n content: var(--tw-content);\n color: var(--ikp-color-gray-dark-950);\n}\n\n.dark\\:data-\\[highlight\\]\\:first\\:before\\:\\[background-image\\:conic-gradient\\(transparent\\2c theme\\(colors\\.inkeep-expanded-primary\\.300\\)\\2c transparent_30\\%\\)\\]:first-child[data-highlight]:is([data-theme="dark"] *)::before {\n content: var(--tw-content);\n background-image: conic-gradient(transparent,var(--ikp-color-inkeep-expanded-primary-300),transparent 30%);\n}\n\n.dark\\:hover\\:border-white-alpha-300:hover:not(:disabled):is([data-theme="dark"] *) {\n border-color: var(--ikp-color-white-alpha-300);\n}\n\n.dark\\:hover\\:bg-gray-dark-800:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-800);\n}\n\n.dark\\:hover\\:bg-inkeep-expanded-primary-200:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-inkeep-expanded-primary-200);\n}\n\n.dark\\:hover\\:bg-transparent:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: transparent;\n}\n\n.dark\\:hover\\:bg-white-alpha-100:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.dark\\:hover\\:bg-white-alpha-200:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-200);\n}\n\n.dark\\:hover\\:bg-white-alpha-50:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-50);\n}\n\n.dark\\:hover\\:text-inkeep-expanded-primary-100:hover:not(:disabled):is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-100);\n}\n\n.dark\\:hover\\:text-inkeep-expanded-primary-300:hover:not(:disabled):is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:hover\\:text-white-alpha-500:hover:not(:disabled):is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-500);\n}\n\n.dark\\:hover\\:text-white-alpha-800:hover:not(:disabled):is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-800);\n}\n\n.dark\\:hover\\:text-white-alpha-950:hover:not(:disabled):is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-950);\n}\n\n.hover\\:dark\\:text-white-alpha-950:is([data-theme="dark"] *):hover:not(:disabled) {\n color: var(--ikp-color-white-alpha-950);\n}\n\n.dark\\:hover\\:disabled\\:bg-white-alpha-100:disabled:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.dark\\:hover\\:data-\\[state\\=active\\]\\:bg-white-alpha-100[data-state="active"]:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.dark\\:data-\\[is-match\\]\\:hover\\:text-inkeep-expanded-primary-200:hover:not(:disabled)[data-is-match]:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-200);\n}\n\n.dark\\:selected\\:border-inkeep-expanded-primary-300[data-selected="true"]:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:selected\\:bg-white-alpha-200[data-selected="true"]:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-200);\n}\n\n.dark\\:selected\\:text-inkeep-expanded-primary-300[data-selected="true"]:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:selected\\:border-inkeep-expanded-primary-300:hover:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:selected\\:bg-white-alpha-200:hover:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-200);\n}\n\n.dark\\:selected\\:text-inkeep-expanded-primary-300:hover:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.group[data-selected="true"] .dark\\:group-selected\\:text-gray-dark-100:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-100);\n}\n\n.group[data-selected="true"] .dark\\:group-selected\\:text-inkeep-expanded-primary-300:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.group[data-selected="true"] .dark\\:group-selected\\:text-white:is([data-theme="dark"] *) {\n --tw-text-opacity: 1;\n color: rgb(255 255 255 / var(--tw-text-opacity, 1));\n}\n\n.group:hover .dark\\:group-selected\\:text-gray-dark-100:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-100);\n}\n\n.group:hover .dark\\:group-selected\\:text-inkeep-expanded-primary-300:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.group:hover .dark\\:group-selected\\:text-white:is([data-theme="dark"] *) {\n --tw-text-opacity: 1;\n color: rgb(255 255 255 / var(--tw-text-opacity, 1));\n}\n\n@media (min-width: 640px) {\n\n .sm\\:w-\\[420px\\] {\n width: 420px;\n }\n}\n\n@media (min-width: 768px) {\n\n .md\\:my-12 {\n margin-top: 3rem;\n margin-bottom: 3rem;\n }\n\n .md\\:flex {\n display: flex;\n }\n\n .md\\:hidden {\n display: none;\n }\n\n .md\\:h-\\[min\\(760px\\2c 100\\%\\)\\] {\n height: min(760px,100%);\n }\n\n .md\\:w-\\[min\\(600px\\2c 100\\%\\)\\] {\n width: min(600px,100%);\n }\n\n .md\\:min-w-\\[min\\(320px\\2c 100\\%\\)\\] {\n min-width: min(320px,100%);\n }\n\n .md\\:p-10 {\n padding: 2.5rem;\n }\n\n .md\\:text-4xl {\n font-size: var(--ikp-font-size-4xl);\n }\n\n .md\\:text-sm {\n font-size: var(--ikp-font-size-sm);\n }\n\n .md\\:leading-5 {\n line-height: 1.25rem;\n }\n\n .md\\:data-\\[view\\=dual-pane\\]\\:hidden[data-view="dual-pane"] {\n display: none;\n }\n\n .md\\:data-\\[dual-pane-search-expanded\\]\\:h-\\[min\\(calc\\(85vh_-_72px\\)\\2c calc\\(900px_-_72px_-_135px\\)\\)\\][data-dual-pane-search-expanded] {\n height: min(calc(85vh - 72px),calc(900px - 72px - 135px));\n }\n\n .md\\:data-\\[view\\=dual-pane\\]\\:\\[grid-template\\:\\"breadcrumbs_breadcrumbs_breadcrumbs\\"\\"icon_title_tag\\"\\"description_description_description\\"\\/auto_auto_1fr\\][data-view="dual-pane"] {\n grid-template: "breadcrumbs breadcrumbs breadcrumbs""icon title tag""description description description"/auto auto 1fr;\n }\n}\n\n@media (min-width: 1024px) {\n\n .lg\\:h-\\[min\\(800px\\2c 100\\%\\)\\] {\n height: min(800px,100%);\n }\n\n .lg\\:w-\\[min\\(640px\\2c 100\\%\\)\\] {\n width: min(640px,100%);\n }\n}\n\n@media (min-width: 1536px) {\n\n .\\32xl\\:h-\\[min\\(900px\\2c 100\\%\\)\\] {\n height: min(900px,100%);\n }\n\n .\\32xl\\:w-\\[min\\(760px\\2c 100\\%\\)\\] {\n width: min(760px,100%);\n }\n}\n\n.\\[\\&\\:not\\(\\:last-child\\)\\]\\:after\\:absolute:not(:last-child)::after {\n content: var(--tw-content);\n position: absolute;\n}\n\n.\\[\\&\\:not\\(\\:last-child\\)\\]\\:after\\:inset-x-6:not(:last-child)::after {\n content: var(--tw-content);\n left: 1.5rem;\n right: 1.5rem;\n}\n\n.\\[\\&\\:not\\(\\:last-child\\)\\]\\:after\\:bottom-0:not(:last-child)::after {\n content: var(--tw-content);\n bottom: 0px;\n}\n\n.\\[\\&\\:not\\(\\:last-child\\)\\]\\:after\\:border-b:not(:last-child)::after {\n content: var(--tw-content);\n border-bottom-width: 1px;\n}\n\n[data-widget-md] .ikp-md\\:\\[\\&\\:not\\(\\:last-child\\)\\]\\:after\\:inset-x-8:not(:last-child)::after {\n content: var(--tw-content);\n left: 2rem;\n right: 2rem;\n}\n\n.focus\\:\\[\\&\\:not\\(\\[data-invalid\\]\\)\\]\\:border-\\[--focus-border-color\\]:not([data-invalid]):focus {\n border-color: var(--focus-border-color);\n}\n\n.focus\\:\\[\\&\\:not\\(\\[data-invalid\\]\\)\\]\\:shadow-\\[0_0_0_1px_var\\(--focus-border-color\\)\\]:not([data-invalid]):focus {\n --tw-shadow: 0 0 0 1px var(--focus-border-color);\n --tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n.\\[\\&\\:where\\(\\:hover\\2c \\:focus\\)\\]\\:bg-slate-400\\/5:where(:hover,:focus) {\n background-color: rgb(148 163 184 / 0.05);\n}\n\n.dark\\:\\[\\&\\:where\\(\\:hover\\2c \\:focus\\)\\]\\:bg-white-alpha-100:where(:hover,:focus):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.\\[\\&\\>\\:first-child\\]\\:basis-full>:first-child {\n flex-basis: 100%;\n}\n\n.\\[\\&\\[data-mobile\\]\\>div\\]\\:h-full[data-mobile]>div {\n height: 100%;\n}\n\n.\\[\\&\\[data-mobile\\]\\>div\\]\\:max-h-\\[unset\\][data-mobile]>div {\n max-height: unset;\n}\n\n.\\[\\&\\[data-mobile\\]\\>div\\]\\:max-h-dvh[data-mobile]>div {\n max-height: 100dvh;\n}\n\n.\\[\\&_\\[data-part\\=grid\\]\\]\\:divide-y [data-part=grid] > :not([hidden]) ~ :not([hidden]) {\n --tw-divide-y-reverse: 0;\n border-top-width: calc(1px * calc(1 - var(--tw-divide-y-reverse)));\n border-bottom-width: calc(1px * var(--tw-divide-y-reverse));\n}\n\n.\\[\\&_\\[data-part\\=grid\\]\\]\\:px-1 [data-part=grid] {\n padding-left: 0.25rem;\n padding-right: 0.25rem;\n}\n\n.\\[\\&_a\\]\\:inline a {\n display: inline;\n}\n\n.\\[\\&_a\\]\\:break-words a {\n overflow-wrap: break-word;\n}\n\n.\\[\\&_a\\]\\:rounded-sm a {\n border-radius: 0.125rem;\n}\n\n.\\[\\&_a\\]\\:bg-inkeep-primary-light a {\n background-color: var(--ikp-color-inkeep-primary-light);\n}\n\n.\\[\\&_a\\]\\:px-1 a {\n padding-left: 0.25rem;\n padding-right: 0.25rem;\n}\n\n.\\[\\&_a\\]\\:py-\\[1px\\] a {\n padding-top: 1px;\n padding-bottom: 1px;\n}\n\n.\\[\\&_a\\]\\:font-semibold a {\n font-weight: 600;\n}\n\n.\\[\\&_a\\]\\:text-inkeep-primary-text-subtle a {\n color: var(--ikp-color-inkeep-primary-text-subtle);\n}\n\n.\\[\\&_a\\]\\:no-underline a {\n text-decoration-line: none;\n}\n\n.\\[\\&_a\\]\\:hover\\:text-inkeep-primary-text-bold:hover:not(:disabled) a {\n color: var(--ikp-color-inkeep-primary-text-bold);\n}\n\n.\\[\\&_a\\]\\:hover\\:no-underline:hover:not(:disabled) a {\n text-decoration-line: none;\n}\n\n.\\[\\&_a\\]\\:dark\\:bg-inkeep-primary-text-subtle:is([data-theme="dark"] *) a {\n background-color: var(--ikp-color-inkeep-primary-text-subtle);\n}\n\n.\\[\\&_a\\]\\:dark\\:hover\\:text-inkeep-expanded-primary-200:hover:not(:disabled):is([data-theme="dark"] *) a {\n color: var(--ikp-color-inkeep-expanded-primary-200);\n}\n\n.\\[\\&_em\\]\\:font-bold em {\n font-weight: 700;\n}\n\n.\\[\\&_em\\]\\:not-italic em {\n font-style: normal;\n}\n\n.\\[\\&_li\\]\\:mb-1 li {\n margin-bottom: 0.25rem;\n}\n\n.\\[\\&_svg\\]\\:h-4 svg {\n height: 1rem;\n}\n\n.\\[\\&_svg\\]\\:w-4 svg {\n width: 1rem;\n}\n\n[data-mobile] .\\[\\[data-mobile\\]_\\&\\]\\:h-\\[calc\\(100vh-var\\(--input-height\\)-var\\(--footer-height\\)-var\\(--ask-ai-trigger-height\\)\\)\\] {\n height: calc(100vh - var(--input-height) - var(--footer-height) - var(--ask-ai-trigger-height));\n}\n\n[data-mobile] .\\[\\[data-mobile\\]_\\&\\]\\:h-\\[var\\(--footer-height\\)\\] {\n height: var(--footer-height);\n}\n\n[data-mobile] .\\[\\[data-mobile\\]_\\&\\]\\:max-h-\\[var\\(--input-height\\)\\] {\n max-height: var(--input-height);\n}\n\n[data-mobile] .\\[\\[data-mobile\\]_\\&\\]\\:items-center {\n align-items: center;\n}\n\n[data-mobile] .\\[\\[data-mobile\\]_\\&\\]\\:py-0 {\n padding-top: 0px;\n padding-bottom: 0px;\n}\n\n[data-position="left"]>.\\[\\[data-position\\=\\"left\\"\\]\\>\\&\\]\\:-right-1 {\n right: -0.25rem;\n}\n\n[data-position="left"]>.\\[\\[data-position\\=\\"left\\"\\]\\>\\&\\]\\:after\\:left-1::after {\n content: var(--tw-content);\n left: 0.25rem;\n}\n\n[data-position="right"]>.\\[\\[data-position\\=\\"right\\"\\]\\>\\&\\]\\:-left-1 {\n left: -0.25rem;\n}\n\n[data-position="right"]>.\\[\\[data-position\\=\\"right\\"\\]\\>\\&\\]\\:after\\:right-1::after {\n content: var(--tw-content);\n right: 0.25rem;\n}\n\n[data-show-ask-ai-card] .\\[\\[data-show-ask-ai-card\\]_\\&\\]\\:\\[--ask-ai-trigger-height\\:theme\\(spacing\\.11\\)\\] {\n --ask-ai-trigger-height: 2.75rem;\n}\n\n[data-sidebar] .\\[\\[data-sidebar\\]_\\&\\]\\:m-\\[unset\\] {\n margin: unset;\n}\n\n[data-sidebar] .\\[\\[data-sidebar\\]_\\&\\]\\:mt-auto {\n margin-top: auto;\n}\n\n[data-sidebar] .\\[\\[data-sidebar\\]_\\&\\]\\:h-full {\n height: 100%;\n}\n\n[data-sidebar] .\\[\\[data-sidebar\\]_\\&\\]\\:max-h-\\[unset\\] {\n max-height: unset;\n}\n\n[data-sidebar] .\\[\\[data-sidebar\\]_\\&\\]\\:w-full {\n width: 100%;\n}\n\n[data-view=dual-pane] .\\[\\[data-view\\=dual-pane\\]_\\&\\]\\:block {\n display: block;\n}\n\n[data-view=dual-pane] .\\[\\[data-view\\=dual-pane\\]_\\&\\]\\:flex-\\[0_0_44\\%\\] {\n flex: 0 0 44%;\n}\n\n[data-view=dual-pane] .first\\:\\[\\[data-view\\=dual-pane\\]_\\&\\]\\:flex-1:first-child {\n flex: 1 1 0%;\n}\n\n@media (min-width: 768px) {\n\n [data-view=dual-pane] .md\\:first\\:\\[\\[data-view\\=dual-pane\\]_\\&\\]\\:flex-\\[0_0_44\\%\\]:first-child {\n flex: 0 0 44%;\n }\n}\n',...e}),Tye=qB("div",{_id:"view_toggle"}),Cye=qB("button",{_id:"view_toggle_button",className:qde({slot:"button"})}),Aye=qB(jY,{_id:"view_toggle_icon"});function Nye(e){const{handleToggle:t}=Iye(e);return Wh.jsxs(Tye,{className:qde({slot:"root"}),children:[Wh.jsxs(Cye,{onClick:()=>t("search"),"data-active":SL("search"===e.view),children:[Wh.jsx(Aye,{"data-active":SL("search"===e.view),iconKey:"switchToSearch",className:qde({slot:"icon"})}),e.searchLabel||"Search"]}),Wh.jsxs(Cye,{onClick:()=>t("chat"),"data-active":SL("chat"===e.view),children:[Wh.jsx(Aye,{"data-active":SL("chat"===e.view),iconKey:"switchToChat",className:qde({slot:"icon"})}),e.askAILabel||"Ask AI"]})]})}function Iye(e){const{onToggleView:t,query:n}=e;return{handleToggle:(e,r)=>{null==t||t({view:e,query:n,autoSubmit:r})}}}function Rye(e){const{componentType:t,children:n,modalSettings:r,...a}=e;return Wh.jsx(Nue,{children:Wh.jsx(Eue,{children:Wh.jsx(Sye,{children:Wh.jsx(CB,{config:{...a},componentType:t,children:Wh.jsx(sge,{config:r,children:n})})})})})}function Oye(e){return Wh.jsx(lge,{children:Wh.jsx(cge,{children:e.children})})}function Pye(e){const{children:t,onToggleView:n,isHidden:r,shouldAutoFocusInput:a=!n}=e;return Wh.jsx(Qde,{isHidden:r,shouldAutoFocusInput:a,children:t})}function Dye(e){return Wh.jsx(Pye,{...e,children:Wh.jsx(Lye,{...e})})}function Lye(e){const{onToggleView:t,variant:n,header:r=Mye}=e,a=iL(),o=fL(),i=a&&!o?Oye:K.Fragment;return Wh.jsx(i,{children:Wh.jsxs(Zde,{variant:n??(t?"no-shadow":"container-with-shadow"),"data-composite":SL(!!e.onToggleView||(null==a?void 0:a.isOpen)),children:[Wh.jsx(Jde,{}),Wh.jsxs(epe,{children:[Wh.jsx(r,{...e}),Wh.jsx(Fye,{}),Wh.jsx(Gye,{})]}),Wh.jsx(Wye,{}),Wh.jsx(Yye,{})]})})}function Mye(e){const{onToggleView:t,askAILabel:n,searchLabel:r}=e,a=!!t;return Wh.jsx(tpe,{"data-show-toolbar":SL(a),children:a?Wh.jsxs(npe,{children:[Wh.jsxs(rpe,{children:[Wh.jsx(ape,{}),Wh.jsxs(dpe,{children:[Wh.jsx(hpe,{}),Wh.jsxs(fpe,{side:"bottom",align:"start",children:[Wh.jsx(mpe,{}),Wh.jsx(gpe,{})]})]})]}),Wh.jsx(Nye,{onToggleView:t,askAILabel:n,searchLabel:r,view:"chat"}),Wh.jsx(uge,{})]}):Wh.jsx(uge,{})})}function Fye(){return Wh.jsx(ope,{children:Wh.jsxs(ipe,{children:[Wh.jsx(spe,{children:Wh.jsx(jye,{})}),Wh.jsx(lpe,{children:Wh.jsx(cpe,{})}),Wh.jsx(upe,{})]})})}function jye(){return Wh.jsx(xpe,{children:({messages:e})=>Wh.jsxs(Wh.Fragment,{children:[Wh.jsx(Bye,{}),e.map((e=>Wh.jsxs(_pe,{message:e,children:[Wh.jsx(zye,{}),Wh.jsx(Cpe,{}),Wh.jsxs(Ppe,{children:[Wh.jsx(Dpe,{children:Wh.jsx(qpe,{})}),Wh.jsx(Hye,{}),Wh.jsx(Uye,{}),Wh.jsx($ye,{})]})]},e.id)))]})})}function Bye(){return Wh.jsxs(Spe,{children:[Wh.jsxs(Tpe,{children:[Wh.jsx(Ape,{children:Wh.jsxs(Npe,{children:[Wh.jsx(Ipe,{}),Wh.jsx(Rpe,{})]})}),Wh.jsx(Ope,{})]}),Wh.jsxs(Ppe,{children:[Wh.jsx(Dpe,{children:Wh.jsx(qpe,{})}),Wh.jsxs(dpe,{children:[Wh.jsx(ppe,{}),Wh.jsx(hpe,{}),Wh.jsxs(fpe,{children:[Wh.jsx(mpe,{}),Wh.jsx(gpe,{})]})]}),Wh.jsxs(ype,{children:[Wh.jsx(bpe,{}),Wh.jsx(vpe,{children:e=>e.map((e=>Wh.jsx(kpe,{children:Wh.jsx(wpe,{question:e})},e)))})]})]})]})}function zye(){return Wh.jsxs(Tpe,{children:[Wh.jsx(Ape,{children:Wh.jsxs(Npe,{children:[Wh.jsx(Ipe,{}),Wh.jsx(Rpe,{})]})}),Wh.jsx(Ope,{})]})}function Hye(){return Wh.jsxs(Lpe,{children:[Wh.jsx(Mpe,{children:e=>e.map((e=>Wh.jsxs(Fpe,{attachment:e,children:[Wh.jsx(jpe,{}),Wh.jsx(Bpe,{})]},e.id)))}),Wh.jsx(zpe,{children:Wh.jsx(_ue,{children:Wh.jsx(Hpe,{children:Wh.jsxs(Upe,{children:[Wh.jsx($pe,{}),Wh.jsx(Gpe,{}),Wh.jsx(Vpe,{})]})})})})]})}function Uye(){return Wh.jsxs(Wpe,{children:[Wh.jsx(Ype,{children:e=>e.map(((e,t)=>Wh.jsx(Kpe,{action:e},`action-${t}`)))}),Wh.jsx(Xpe,{action:"copy"}),Wh.jsx(Xpe,{action:"upvote"}),Wh.jsx(Xpe,{action:"downvote"})]})}function $ye(){return Wh.jsxs(Qpe,{children:[Wh.jsx(Zpe,{}),Wh.jsx(Jpe,{children:e=>e.map(((e,t)=>{var n;return Wh.jsxs(ehe,{href:e.url,source:e,children:[Wh.jsx(the,{children:null==(n=e.breadcrumbs)?void 0:n.map((e=>Wh.jsxs(K.Fragment,{children:[e,Wh.jsx(nhe,{})]},e)))}),Wh.jsx(rhe,{}),Wh.jsx(ahe,{}),Wh.jsx(ohe,{}),Wh.jsx(ihe,{children:e=>e.map(((e,t)=>Wh.jsx(she,{part:e},`part-${t}`)))}),Wh.jsx(lhe,{})]},t)}))})]})}function Gye(){return Wh.jsxs(che,{children:[Wh.jsx(Vye,{}),Wh.jsx(qye,{})]})}function Vye(){return Wh.jsxs(uhe,{children:[Wh.jsxs(dhe,{children:[Wh.jsx(phe,{}),Wh.jsx(hhe,{children:Wh.jsx(fhe,{})})]}),Wh.jsxs(mhe,{children:[Wh.jsx(ghe,{children:e=>e.map((e=>Wh.jsxs(yhe,{attachment:e,children:[Wh.jsx(bhe,{}),Wh.jsx(vhe,{}),Wh.jsx(khe,{})]},e.id)))}),Wh.jsxs(whe,{children:[Wh.jsxs(xhe,{children:[Wh.jsx(Ehe,{}),Wh.jsx(_he,{})]}),Wh.jsx(She,{children:e=>e.map((e=>Wh.jsx(The,{input:e,children:e.displayName},e.id)))})]}),Wh.jsx(_ue,{children:Wh.jsx(Che,{children:Wh.jsx(Ahe,{children:Wh.jsxs(Nhe,{children:[Wh.jsxs(Ihe,{children:[Wh.jsx(Rhe,{}),Wh.jsx(Ohe,{}),Wh.jsx(Phe,{})]}),Wh.jsx(Dhe,{}),Wh.jsx(Lhe,{children:Wh.jsxs(Mhe,{children:[Wh.jsxs(Fhe,{children:[Wh.jsx(jhe,{}),Wh.jsx(Bhe,{}),Wh.jsx(zhe,{})]}),Wh.jsxs(Hhe,{children:[Wh.jsx(Uhe,{}),Wh.jsx($he,{}),Wh.jsx(Ghe,{})]}),Wh.jsx(Vhe,{})]})})]})})})})]})]})}function qye(){return Wh.jsxs(qhe,{children:[Wh.jsxs(Yhe,{children:[Wh.jsx(Khe,{}),Wh.jsx(Xhe,{}),Wh.jsx(Qhe,{})]}),Wh.jsxs(Whe,{children:[Wh.jsx(nfe,{children:({pinned:e,unpinned:t})=>Wh.jsxs(Wh.Fragment,{children:[e.map((e=>Wh.jsx(rfe,{action:e},e.name))),t.length>0&&Wh.jsx(afe,{}),Wh.jsxs(ofe,{children:[Wh.jsx(ife,{}),t.map((e=>Wh.jsxs(sfe,{action:e,children:[Wh.jsx(lfe,{action:e}),e.name]},e.name)))]})]})}),Wh.jsxs(Jhe,{action:"copy",children:[Wh.jsx(efe,{action:"copy"}),Wh.jsx(tfe,{action:"copy"})]}),Wh.jsxs(Jhe,{action:"share",children:[Wh.jsx(efe,{action:"share"}),Wh.jsx(tfe,{action:"share"})]}),Wh.jsx(Jhe,{action:"clear"}),Wh.jsx(Jhe,{action:"stop"})]})]})}function Wye(){return Wh.jsx(_ue,{children:Wh.jsx(cfe,{children:Wh.jsx(ufe,{children:Wh.jsxs(dfe,{children:[Wh.jsx(pfe,{}),Wh.jsx(hfe,{}),Wh.jsx(ffe,{children:Wh.jsxs(mfe,{children:[Wh.jsxs(gfe,{name:"unrelated_response",children:[Wh.jsx(yfe,{children:Wh.jsx(bfe,{})}),Wh.jsx(vfe,{}),Wh.jsx(kfe,{})]}),Wh.jsxs(gfe,{name:"inaccurate_statement",children:[Wh.jsx(yfe,{children:Wh.jsx(bfe,{})}),Wh.jsx(vfe,{}),Wh.jsx(kfe,{})]}),Wh.jsxs(gfe,{name:"inaccurate_code_snippet",children:[Wh.jsx(yfe,{children:Wh.jsx(bfe,{})}),Wh.jsx(vfe,{}),Wh.jsx(kfe,{})]}),Wh.jsxs(gfe,{name:"irrelevant_citations",children:[Wh.jsx(yfe,{children:Wh.jsx(bfe,{})}),Wh.jsx(vfe,{})]}),Wh.jsx(wfe,{})]})})]})})})})}function Yye(){return Wh.jsxs(xfe,{children:[Wh.jsx(_fe,{}),Wh.jsxs(Efe,{children:[Wh.jsxs(Sfe,{children:[Wh.jsx(Tfe,{}),Wh.jsx(Cfe,{})]}),Wh.jsx(Afe,{children:e=>Wh.jsxs(Wh.Fragment,{children:[e.map(((e,t)=>Wh.jsxs(Nfe,{field:e,autoFocus:0===t,children:[Wh.jsx(Ife,{}),"text"===e.inputType&&Wh.jsx(Rfe,{}),"email"===e.inputType&&Wh.jsx(Ofe,{}),"file"===e.inputType&&Wh.jsx(Pfe,{}),"textarea"===e.inputType&&Wh.jsx(Dfe,{}),"checkbox"===e.inputType&&Wh.jsx(Lfe,{children:Wh.jsx(Mfe,{})}),"select"===e.inputType&&Wh.jsxs(Ffe,{children:[Wh.jsxs(jfe,{children:[Wh.jsx(Bfe,{}),Wh.jsx(zfe,{})]}),Wh.jsx(Hfe,{children:Wh.jsx(Ufe,{children:e.items.map((e=>Wh.jsxs($fe,{value:e.value,children:[Wh.jsx(Gfe,{children:e.label}),Wh.jsx(Vfe,{})]},e.value)))})})]}),Wh.jsx(qfe,{})]},e.name))),Wh.jsx(Wfe,{})]})}),Wh.jsxs(Yfe,{children:[Wh.jsx(Kfe,{}),Wh.jsx(Xfe,{})]})]}),Wh.jsxs(Qfe,{children:[Wh.jsx(Zfe,{}),Wh.jsx(Jfe,{}),Wh.jsx(eme,{})]})]})}function Kye(){return Wh.jsx(rme,{children:Wh.jsx(ame,{})})}function Xye(e){const{children:t,onToggleView:n,isHidden:r,shouldAutoFocusInput:a=!n}=e;return Wh.jsx(ime,{isHidden:r,shouldAutoFocusInput:a,children:t})}function Qye(e){return Wh.jsx(Xye,{...e,children:Wh.jsx(Zye,{...e})})}function Zye(e){const{searchSettings:{view:t}}=nP(),{onToggleView:n,shouldShowAskAICard:r=!!n&&"dual-pane"!==t}=e,a=iL(),o=fL(),i=a&&!o?Oye:K.Fragment;return Wh.jsx(i,{children:Wh.jsx(sme,{"data-show-ask-ai-card":SL(r),"data-composite":SL(!!n||(null==a?void 0:a.isOpen)),children:Wh.jsxs(lme,{children:[Wh.jsx(Jye,{...e}),Wh.jsxs(cme,{children:[Wh.jsx(ebe,{askAICardLabel:e.askAICardLabel,askAILabel:e.askAILabel,onToggleView:e.onToggleView,shouldShowAskAICard:r}),Wh.jsx(tbe,{})]}),Wh.jsx(abe,{})]})})})}function Jye(e){const{onToggleView:t,askAILabel:n,searchLabel:r}=e,a=Toe((e=>e.search)),{loading:o}=Uoe();return Wh.jsxs(ume,{children:[!o&&Wh.jsx(dme,{}),Wh.jsx(hme,{}),Wh.jsx(pme,{}),t&&Wh.jsx(Nye,{onToggleView:t,query:a,askAILabel:n,searchLabel:r,view:"search"}),Wh.jsx(uge,{})]})}function ebe(e){const{askAILabel:t,onToggleView:n,shouldShowAskAICard:r,askAICardLabel:a}=e,o=Toe((e=>e.search)),{handleToggle:i}=Iye({onToggleView:n,query:o});return r?Wh.jsxs(fme,{onSelect:()=>i("chat",!0),children:[Wh.jsx(mme,{}),Wh.jsxs(gme,{children:[a||t||"Ask AI",o&&Wh.jsx(yme,{children:`${o}`})]}),Wh.jsx(vme,{children:"Start conversation"}),Wh.jsx(bme,{})]}):null}function tbe(){return Wh.jsxs(kme,{children:[Wh.jsx(wme,{}),Wh.jsx(Eme,{children:e=>e.map((e=>Wh.jsx(_me,{tab:e},e)))}),Wh.jsx(xme,{}),Wh.jsxs(Sme,{children:[Wh.jsx(nbe,{}),Wh.jsx(rbe,{})]})]})}function nbe(){return Wh.jsxs(Tme,{children:[Wh.jsx(Cme,{children:Wh.jsx(Rme,{children:e=>e.map((e=>Wh.jsxs(Ome,{item:e,children:[Wh.jsx(Pme,{children:e=>e.map(((e,t)=>Wh.jsxs(K.Fragment,{children:[e,Wh.jsx(Dme,{})]},`${e}-${t}`)))}),Wh.jsx(Lme,{}),Wh.jsx(Mme,{}),Wh.jsx(Fme,{}),Wh.jsx(jme,{children:e=>e.map(((e,t)=>Wh.jsx(Bme,{part:e},`part-${t}`)))}),Wh.jsx(zme,{})]},e.id)))})}),Wh.jsx(Ame,{children:Wh.jsx(Nme,{})}),Wh.jsx(Ime,{})]})}function rbe(){return Wh.jsxs(Tme,{children:[Wh.jsx(Cme,{children:Wh.jsxs(Hme,{children:[Wh.jsxs(Ume,{children:[Wh.jsxs($me,{children:[Wh.jsx(Gme,{}),Wh.jsx(Vme,{})]}),Wh.jsx(qme,{children:e=>e.map(((e,t)=>Wh.jsxs(K.Fragment,{children:[e,Wh.jsx(Wme,{})]},`${e}-${t}`)))})]}),Wh.jsx(Yme,{}),Wh.jsxs(Kme,{children:[Wh.jsx(Xme,{}),Wh.jsx(Qme,{children:e=>e.map(((e,t)=>Wh.jsxs(Zme,{href:e.url??void 0,"data-is-match":SL(e.isMatch),children:[Wh.jsx(Jme,{}),Wh.jsx(ege,{children:e.content}),e.url&&Wh.jsx(tge,{})]},`${e.anchor}-${t}`)))})]})]})}),Wh.jsx(Ame,{children:Wh.jsx(Nme,{})}),Wh.jsx(Ime,{})]})}function abe(){return Wh.jsx(nge,{children:Wh.jsxs(rge,{children:[Wh.jsx(age,{}),Wh.jsx(oge,{}),Wh.jsx(ige,{})]})})}function obe(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function ibe(...e){return t=>{for(const n of e)obe(n,t)}}function sbe(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}function lbe(e){const{defaultView:t="search",aiChatSettings:n,baseSettings:r,searchSettings:a,shouldAutoFocusInput:o=!0,onToggleView:i,ref:s,...l}=e,c=K.useRef(null),u=ibe(c,null==n?void 0:n.chatFunctionsRef),d=K.useRef(null),p=ibe(d,null==a?void 0:a.searchFunctionsRef),h={...n,chatFunctionsRef:u},f={...a,searchFunctionsRef:p},[m,g]=K.useState(t);K.useImperativeHandle(s,(()=>({setView:g}))),K.useEffect((()=>{var e,t;"chat"===m?null==(e=c.current)||e.focusInput():null==(t=d.current)||t.focusInput()}),[m]);return{config:{baseSettings:r,aiChatSettings:h,searchSettings:f},defaultView:t,view:m,setView:g,onToggleView:e=>{var t;e.autoSubmit&&e.query&&(null==(t=c.current)||t.submitMessage(e.query)),null==i||i(e),g(e.view)},shouldAutoFocusInput:o,...l}}function cbe(e){const{view:t,setView:n,shouldShowAskAICard:r,onToggleView:a,shouldAutoFocusInput:o,searchLabel:i,askAILabel:s,askAICardLabel:l}=e,c=iL()?Oye:K.Fragment,u={onToggleView:a,shouldShowAskAICard:r,shouldAutoFocusInput:o,searchLabel:i,askAILabel:s,askAICardLabel:l},d={isHidden:"chat"===t,...u},p={isHidden:"search"===t,...u};return Wh.jsx(hL,{widget:{setView:n,view:t},children:Wh.jsx(Xye,{...d,children:Wh.jsx(Pye,{...p,children:Wh.jsxs(c,{children:[Wh.jsx(Zye,{...d}),Wh.jsx(Lye,{...p})]})})})})}function ube({label:e="Ask AI",avatar:t,onOpenChange:n}){return Wh.jsx(dge,{children:Wh.jsxs(pge,{onClick:e=>{2!==e.button&&n((e=>!e))},children:[Wh.jsx(hge,{children:e}),Wh.jsx(mge,{children:Wh.jsx(fge,{avatar:t})})]})})}function dbe({onOpenChange:e,modalSettings:t}){return Wh.jsx(gge,{children:Wh.jsxs(yge,{onClick:t=>{2!==t.button&&e((e=>!e))},children:[Wh.jsxs(bge,{children:[Wh.jsx(kge,{}),Wh.jsx(vge,{})]}),Wh.jsxs(wge,{children:[Wh.jsx(xge,{shortcutKey:null==t?void 0:t.shortcutKey}),Wh.jsx(Ege,{shortcutKey:null==t?void 0:t.shortcutKey})]})]})})}function pbe(e){const{formSettings:t}=e;return Wh.jsx(_ge,{formSettings:t,children:Wh.jsxs(Sge,{children:[Wh.jsx(Tge,{}),Wh.jsx(Cge,{children:Wh.jsxs(Age,{children:[Wh.jsxs(Nge,{children:[Wh.jsx(hbe,{}),Wh.jsx(fbe,{}),Wh.jsx(gbe,{}),Wh.jsx(ybe,{}),Wh.jsx(bbe,{})]}),Wh.jsx(Ige,{children:Wh.jsx(Rge,{})}),Wh.jsx(Oge,{})]})})]})})}function hbe(){return Wh.jsxs(Pge,{children:[Wh.jsx(Dge,{}),Wh.jsx(Lge,{}),Wh.jsx(Mge,{})]})}function fbe(){const{isSubmitSuccessful:e}=wle();return e?null:Wh.jsxs(Fge,{children:[Wh.jsx(jge,{}),Wh.jsx(Bge,{children:e=>e.map((e=>Wh.jsx(vbe,{field:e},e.name)))}),Wh.jsx(zge,{})]})}function mbe(){return Wh.jsxs(oye,{children:[Wh.jsx(iye,{}),Wh.jsx(sye,{})]})}function gbe(){return Wh.jsxs(lye,{children:[Wh.jsx(mbe,{}),Wh.jsx(Kde,{})]})}function ybe(){const{isSubmitSuccessful:e}=wle();return e?null:Wh.jsxs(cye,{children:[Wh.jsx(mbe,{}),Wh.jsxs(vye,{children:[Wh.jsx(kye,{}),Wh.jsx(wye,{children:e=>e.map((e=>Wh.jsxs(xye,{source:e,children:[Wh.jsx(Eye,{}),Wh.jsx(_ye,{})]},e.url)))})]}),Wh.jsx(uye,{}),Wh.jsxs(dye,{children:[Wh.jsx(pye,{}),Wh.jsx(hye,{})]})]})}function bbe(){const{aiResponse:e}=wle(),{isSubmitSuccessful:t}=wle();return t?null:Wh.jsxs(fye,{children:[Wh.jsx(mbe,{}),!e.answerConfidence&&Wh.jsxs(vye,{children:[Wh.jsx(kye,{children:"I wasn't able to find a direct answer to your question, but here's some helpful sources:"}),Wh.jsx(wye,{children:e=>e.map((e=>Wh.jsxs(xye,{source:e,children:[Wh.jsx(Eye,{}),Wh.jsx(_ye,{})]},e.url)))})]}),Wh.jsx(mye,{}),Wh.jsx(gye,{children:e=>e.map((e=>Wh.jsx(vbe,{field:e},e.name)))}),Wh.jsx(bye,{}),Wh.jsx(yye,{})]})}function vbe(e){const{field:t}=e;return Wh.jsxs(Hge,{field:t,children:[Wh.jsx(Uge,{}),"text"===t.inputType&&Wh.jsx($ge,{}),"email"===t.inputType&&Wh.jsx(Gge,{}),"file"===t.inputType&&Wh.jsx(Vge,{}),"textarea"===t.inputType&&Wh.jsx(qge,{}),"checkbox"===t.inputType&&Wh.jsx(Wge,{children:Wh.jsx(Yge,{})}),"select"===t.inputType&&Wh.jsxs(Kge,{children:[Wh.jsxs(Xge,{children:[Wh.jsx(Qge,{}),Wh.jsx(Zge,{})]}),Wh.jsx(Jge,{children:Wh.jsx(eye,{children:t.items.map((e=>Wh.jsxs(tye,{value:e.value,children:[Wh.jsx(nye,{children:e.label}),Wh.jsx(rye,{})]},e.value)))})})]}),Wh.jsx(aye,{})]},t.name)}const kbe={EmbeddedChat:function(e){const{baseSettings:t,aiChatSettings:n}=e;return Wh.jsx(Nue,{children:Wh.jsx(Sye,{wrapperStyles:{height:"inherit",width:"inherit"},children:Wh.jsx(CB,{config:{baseSettings:t,aiChatSettings:n},componentType:YO,children:Wh.jsx(Dye,{...e})})})})},EmbeddedSearch:function(e){const{baseSettings:t,searchSettings:n}=e;return Wh.jsx(Nue,{children:Wh.jsx(Sye,{children:Wh.jsx(CB,{config:{baseSettings:t,searchSettings:n},componentType:KO,children:Wh.jsx(Qye,{...e})})})})},EmbeddedSearchAndChat:function(e){const{config:t,...n}=lbe(e);return Wh.jsx(Nue,{children:Wh.jsx(Sye,{wrapperStyles:{height:"inherit",width:"inherit"},children:Wh.jsx(CB,{config:t,componentType:XO,children:Wh.jsx(cbe,{...n})})})})},ModalChat:function(e){const{modalSettings:t,baseSettings:n,aiChatSettings:r,...a}=e;return Wh.jsx(Rye,{componentType:qO,modalSettings:t,baseSettings:n,aiChatSettings:r,children:Wh.jsx(Dye,{...a})})},ModalSearch:function(e){const{modalSettings:t,baseSettings:n,searchSettings:r,...a}=e;return Wh.jsx(Rye,{componentType:qO,modalSettings:t,baseSettings:n,searchSettings:r,children:Wh.jsx(Qye,{shouldAutoFocusInput:!0,...a})})},ModalSearchAndChat:function(e){const{modalSettings:t,...n}=e,{config:r,...a}=lbe(n),o=sbe(null==t?void 0:t.onOpenChange,(t=>{e.forceDefaultView&&!t&&a.setView(e.defaultView??"search")})),i={...t,onOpenChange:o};return Wh.jsx(Rye,{...r,modalSettings:i,componentType:qO,children:Wh.jsx(cbe,{...a})})},IntelligentForm:function(e){const{baseSettings:t}=e;return Wh.jsx(Nue,{children:Wh.jsx(Sye,{wrapperStyles:{height:"inherit",width:"inherit"},children:Wh.jsx(CB,{config:{baseSettings:t},componentType:QO,children:Wh.jsx(pbe,{...e})})})})},ChatButton:function(e){const{modalSettings:t,label:n,defaultView:r="chat",canToggleView:a=!0,avatar:o,...i}=e,s={...i,shouldShowAskAICard:!!a&&e.shouldShowAskAICard},{config:l,...c}=lbe({...s,defaultView:r}),[u=!1,d]=OB({prop:null==t?void 0:t.isOpen,defaultProp:!1,onChange:sbe(null==t?void 0:t.onOpenChange,(n=>{void 0===(null==t?void 0:t.isOpen)&&(e.forceDefaultView&&!n&&c.setView(r??"search"),d(!!n))}))}),p={...t,isOpen:u,onOpenChange:d};return Wh.jsxs(Wh.Fragment,{children:[Wh.jsx(Nue,{children:Wh.jsx(Sye,{wrapperStyles:{display:"contents"},children:Wh.jsx(CB,{config:l,componentType:VO,children:Wh.jsx(ube,{label:n,avatar:o,onOpenChange:d})})})}),Wh.jsx(Rye,{...l,componentType:VO,modalSettings:p,children:a?Wh.jsx(cbe,{...c}):Wh.jsx(Dye,{...i})})]})},SearchBar:function(e){const{modalSettings:t,defaultView:n="search",canToggleView:r=!0,...a}=e,o={...a,shouldShowAskAICard:!!r&&e.shouldShowAskAICard},{config:i,...s}=lbe({...o,defaultView:n}),[l=!1,c]=OB({prop:null==t?void 0:t.isOpen,defaultProp:!1,onChange:sbe(null==t?void 0:t.onOpenChange,(r=>{void 0===(null==t?void 0:t.isOpen)&&(e.forceDefaultView&&!r&&s.setView(n),c(!!r))}))}),u={shortcutKey:"k",...t,isOpen:l,onOpenChange:c};return Wh.jsxs(Wh.Fragment,{children:[Wh.jsx(Nue,{children:Wh.jsx(Sye,{wrapperStyles:{display:"contents"},children:Wh.jsx(CB,{config:i,componentType:WO,children:Wh.jsx(dbe,{onOpenChange:c,modalSettings:u})})})}),Wh.jsx(Rye,{...i,modalSettings:u,componentType:WO,children:r?Wh.jsx(cbe,{...s}):Wh.jsx(Qye,{...o})})]})},SidebarChat:function(e){const{baseSettings:t,aiChatSettings:n,shouldAutoFocusInput:r,...a}=e;return Wh.jsx(Nue,{children:Wh.jsx(Sye,{wrapperStyles:{height:"inherit",width:"inherit",overflowX:"hidden"},children:Wh.jsx(CB,{config:{baseSettings:t,aiChatSettings:n},componentType:ZO,children:Wh.jsxs(tme,{...a,children:[Wh.jsx(nme,{}),Wh.jsx(Dye,{variant:"no-shadow",shouldAutoFocusInput:r,header:Kye})]})})})})}};function wbe(){window.Inkeep=Object.entries(kbe).reduce(((e,[t,n])=>(e[t]=function(e,t){const n=new Map;return function(r,a){let o,i;if("string"==typeof r)i=r,o=a;else{if(!Bh.includes(t))throw new Error(`You must provide a target selector to render the ${t} component`);const e=document.createElement("div");e.style.position="absolute",document.body.appendChild(e);const n=`inkeep-widget-${jh()}`;i=`#${e.id||n}`,e.id=i.slice(1),o=r}const s=document.querySelector(i);if(!s)return void console.error(`Target ${i} not found.`);let l=n.get(i);l||(l={root:Ch.createRoot(s),props:o,container:s,chatFunctionsRef:K.createRef(),searchFunctionsRef:K.createRef(),ref:K.createRef()},n.set(i,l)),l.props=Ph(o,{aiChatSettings:{chatFunctionsRef:l.chatFunctionsRef},searchSettings:{searchFunctionsRef:l.searchFunctionsRef}},{ref:l.ref}),l.container=s;try{l.root.render(K.createElement(e,l.props))}catch(d){console.error(`Error rendering component ${e.name}:`,d)}const c={update:t=>{const r=n.get(i);if(r){r.props=Ph(r.props??{},t??{});try{r.root.render(K.createElement(e,r.props))}catch(d){console.error(`Error rendering component ${e.name} during update:`,d)}}else console.error(`Component at ${i} is not mounted.`)},unmount(){const e=n.get(i);e&&e.container?(e.root.unmount(),e.container.innerHTML=""):console.error(`Component at ${i} is not mounted.`)},remount(){const t=n.get(i);if(t&&t.container){t.root=Ch.createRoot(t.container);try{t.root.render(K.createElement(e,t.props))}catch(d){console.error(`Error remounting component ${e.name}:`,d)}}else console.error(`Component at ${i} cannot be remounted.`)}},u=zh[t];if("both"===u){const e=Hh(i,"chatFunctionsRef",n),t=Hh(i,"searchFunctionsRef",n);return new Proxy(c,{get(r,a){var o;if("chat"===a)return e;if("search"===a)return t;if(a in r)return r[a];const s=n.get(i),l=null==(o=null==s?void 0:s.ref.current)?void 0:o[a];return"function"==typeof l?l.bind(null==s?void 0:s.ref.current):void 0}})}return"chat"===u?new Proxy(c,{get(e,t){var r;if(t in e)return e[t];const a=n.get(i),o=null==(r=null==a?void 0:a.chatFunctionsRef.current)?void 0:r[t];return"function"==typeof o?o.bind(null==a?void 0:a.chatFunctionsRef.current):void 0}}):"search"===u?new Proxy(c,{get(e,t){var r;if(t in e)return e[t];const a=n.get(i),o=null==(r=null==a?void 0:a.searchFunctionsRef.current)?void 0:r[t];return"function"==typeof o?o.bind(null==a?void 0:a.searchFunctionsRef.current):void 0}}):c}}(n,t),e)),{})}return"undefined"!=typeof window&&wbe(),e.initInkeep=wbe,Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),e}({});
|
|
82
|
+
*/;function W6(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}let Y6={async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null};function K6(e){Y6=e}const X6={exec:()=>null};function Q6(e,t=""){let n="string"==typeof e?e:e.source;const r={replace:(e,t)=>{let a="string"==typeof t?t:t.source;return a=a.replace(Z6.caret,"$1"),n=n.replace(e,a),r},getRegex:()=>new RegExp(n,t)};return r}const Z6={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>new RegExp(`^( {0,3}${e})((?:[\t ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ \t][^\\n]*)?(?:\\n|$))`),hrRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,"i")},J6=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,e8=/(?:[*+-]|\d{1,9}[.)])/,t8=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,n8=Q6(t8).replace(/bull/g,e8).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),r8=Q6(t8).replace(/bull/g,e8).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),a8=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,o8=/(?!\s*\])(?:\\.|[^\[\]\\])+/,i8=Q6(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",o8).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),s8=Q6(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,e8).getRegex(),l8="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",c8=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,u8=Q6("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$))","i").replace("comment",c8).replace("tag",l8).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),d8=Q6(a8).replace("hr",J6).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",l8).getRegex(),p8={blockquote:Q6(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",d8).getRegex(),code:/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,def:i8,fences:/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,hr:J6,html:u8,lheading:n8,list:s8,newline:/^(?:[ \t]*(?:\n|$))+/,paragraph:d8,table:X6,text:/^[^\n]+/},h8=Q6("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",J6).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3}\t)[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",l8).getRegex(),f8={...p8,lheading:r8,table:h8,paragraph:Q6(a8).replace("hr",J6).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",h8).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",l8).getRegex()},m8={...p8,html:Q6("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",c8).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:X6,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Q6(a8).replace("hr",J6).replace("heading"," *#{1,6} *[^\n]").replace("lheading",n8).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},g8=/^( {2,}|\\)\n(?!\s*$)/,y8=/[\p{P}\p{S}]/u,b8=/[\s\p{P}\p{S}]/u,v8=/[^\s\p{P}\p{S}]/u,k8=Q6(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,b8).getRegex(),w8=/(?!~)[\p{P}\p{S}]/u,x8=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,E8=Q6(x8,"u").replace(/punct/g,y8).getRegex(),_8=Q6(x8,"u").replace(/punct/g,w8).getRegex(),S8="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",T8=Q6(S8,"gu").replace(/notPunctSpace/g,v8).replace(/punctSpace/g,b8).replace(/punct/g,y8).getRegex(),C8=Q6(S8,"gu").replace(/notPunctSpace/g,/(?:[^\s\p{P}\p{S}]|~)/u).replace(/punctSpace/g,/(?!~)[\s\p{P}\p{S}]/u).replace(/punct/g,w8).getRegex(),A8=Q6("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,v8).replace(/punctSpace/g,b8).replace(/punct/g,y8).getRegex(),N8=Q6(/\\(punct)/,"gu").replace(/punct/g,y8).getRegex(),I8=Q6(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),R8=Q6(c8).replace("(?:--\x3e|$)","--\x3e").getRegex(),O8=Q6("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",R8).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),P8=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,D8=Q6(/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/).replace("label",P8).replace("href",/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),L8=Q6(/^!?\[(label)\]\[(ref)\]/).replace("label",P8).replace("ref",o8).getRegex(),M8=Q6(/^!?\[(ref)\](?:\[\])?/).replace("ref",o8).getRegex(),F8={_backpedal:X6,anyPunctuation:N8,autolink:I8,blockSkip:/\[[^[\]]*?\]\((?:\\.|[^\\\(\)]|\((?:\\.|[^\\\(\)])*\))*\)|`[^`]*?`|<[^<>]*?>/g,br:g8,code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,del:X6,emStrongLDelim:E8,emStrongRDelimAst:T8,emStrongRDelimUnd:A8,escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,link:D8,nolink:M8,punctuation:k8,reflink:L8,reflinkSearch:Q6("reflink|nolink(?!\\()","g").replace("reflink",L8).replace("nolink",M8).getRegex(),tag:O8,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,url:X6},j8={...F8,link:Q6(/^!?\[(label)\]\((.*?)\)/).replace("label",P8).getRegex(),reflink:Q6(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",P8).getRegex()},B8={...F8,emStrongRDelimAst:C8,emStrongLDelim:_8,url:Q6(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,"i").replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\.|[^\\])*?(?:\\.|[^\s~\\]))\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/},z8={...B8,br:Q6(g8).replace("{2,}","*").getRegex(),text:Q6(B8.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},H8={normal:p8,gfm:f8,pedantic:m8},U8={normal:F8,gfm:B8,breaks:z8,pedantic:j8},$8={"&":"&","<":"<",">":">",'"':""","'":"'"},G8=e=>$8[e];function V8(e,t){if(t){if(Z6.escapeTest.test(e))return e.replace(Z6.escapeReplace,G8)}else if(Z6.escapeTestNoEncode.test(e))return e.replace(Z6.escapeReplaceNoEncode,G8);return e}function q8(e){try{e=encodeURI(e).replace(Z6.percentDecode,"%")}catch{return null}return e}function W8(e,t){var n;const r=e.replace(Z6.findPipe,((e,t,n)=>{let r=!1,a=t;for(;--a>=0&&"\\"===n[a];)r=!r;return r?"|":" |"})).split(Z6.splitPipe);let a=0;if(r[0].trim()||r.shift(),r.length>0&&!(null==(n=r.at(-1))?void 0:n.trim())&&r.pop(),t)if(r.length>t)r.splice(t);else for(;r.length<t;)r.push("");for(;a<r.length;a++)r[a]=r[a].trim().replace(Z6.slashPipe,"|");return r}function Y8(e,t,n){const r=e.length;if(0===r)return"";let a=0;for(;a<r;){if(e.charAt(r-a-1)!==t)break;a++}return e.slice(0,r-a)}function K8(e,t,n,r,a){const o=t.href,i=t.title||null,s=e[1].replace(a.other.outputLinkReplace,"$1");if("!"!==e[0].charAt(0)){r.state.inLink=!0;const e={type:"link",raw:n,href:o,title:i,text:s,tokens:r.inlineTokens(s)};return r.state.inLink=!1,e}return{type:"image",raw:n,href:o,title:i,text:s}}class X8{constructor(e){i(this,"options"),i(this,"rules"),i(this,"lexer"),this.options=e||Y6}space(e){const t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:"space",raw:t[0]}}code(e){const t=this.rules.block.code.exec(e);if(t){const e=t[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:t[0],codeBlockStyle:"indented",text:this.options.pedantic?e:Y8(e,"\n")}}}fences(e){const t=this.rules.block.fences.exec(e);if(t){const e=t[0],n=function(e,t,n){const r=e.match(n.other.indentCodeCompensation);if(null===r)return t;const a=r[1];return t.split("\n").map((e=>{const t=e.match(n.other.beginningSpace);if(null===t)return e;const[r]=t;return r.length>=a.length?e.slice(a.length):e})).join("\n")}(e,t[3]||"",this.rules);return{type:"code",raw:e,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):t[2],text:n}}}heading(e){const t=this.rules.block.heading.exec(e);if(t){let e=t[2].trim();if(this.rules.other.endingHash.test(e)){const t=Y8(e,"#");this.options.pedantic?e=t.trim():t&&!this.rules.other.endingSpaceChar.test(t)||(e=t.trim())}return{type:"heading",raw:t[0],depth:t[1].length,text:e,tokens:this.lexer.inline(e)}}}hr(e){const t=this.rules.block.hr.exec(e);if(t)return{type:"hr",raw:Y8(t[0],"\n")}}blockquote(e){const t=this.rules.block.blockquote.exec(e);if(t){let e=Y8(t[0],"\n").split("\n"),n="",r="";const a=[];for(;e.length>0;){let t=!1;const o=[];let i;for(i=0;i<e.length;i++)if(this.rules.other.blockquoteStart.test(e[i]))o.push(e[i]),t=!0;else{if(t)break;o.push(e[i])}e=e.slice(i);const s=o.join("\n"),l=s.replace(this.rules.other.blockquoteSetextReplace,"\n $1").replace(this.rules.other.blockquoteSetextReplace2,"");n=n?`${n}\n${s}`:s,r=r?`${r}\n${l}`:l;const c=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(l,a,!0),this.lexer.state.top=c,0===e.length)break;const u=a.at(-1);if("code"===(null==u?void 0:u.type))break;if("blockquote"===(null==u?void 0:u.type)){const t=u,o=t.raw+"\n"+e.join("\n"),i=this.blockquote(o);a[a.length-1]=i,n=n.substring(0,n.length-t.raw.length)+i.raw,r=r.substring(0,r.length-t.text.length)+i.text;break}if("list"!==(null==u?void 0:u.type));else{const t=u,o=t.raw+"\n"+e.join("\n"),i=this.list(o);a[a.length-1]=i,n=n.substring(0,n.length-u.raw.length)+i.raw,r=r.substring(0,r.length-t.raw.length)+i.raw,e=o.substring(a.at(-1).raw.length).split("\n")}}return{type:"blockquote",raw:n,tokens:a,text:r}}}list(e){let t=this.rules.block.list.exec(e);if(t){let n=t[1].trim();const r=n.length>1,a={type:"list",raw:"",ordered:r,start:r?+n.slice(0,-1):"",loose:!1,items:[]};n=r?`\\d{1,9}\\${n.slice(-1)}`:`\\${n}`,this.options.pedantic&&(n=r?n:"[*+-]");const o=this.rules.other.listItemRegex(n);let i=!1;for(;e;){let n=!1,r="",s="";if(!(t=o.exec(e)))break;if(this.rules.block.hr.test(e))break;r=t[0],e=e.substring(r.length);let l=t[2].split("\n",1)[0].replace(this.rules.other.listReplaceTabs,(e=>" ".repeat(3*e.length))),c=e.split("\n",1)[0],u=!l.trim(),d=0;if(this.options.pedantic?(d=2,s=l.trimStart()):u?d=t[1].length+1:(d=t[2].search(this.rules.other.nonSpaceChar),d=d>4?1:d,s=l.slice(d),d+=t[1].length),u&&this.rules.other.blankLine.test(c)&&(r+=c+"\n",e=e.substring(c.length+1),n=!0),!n){const t=this.rules.other.nextBulletRegex(d),n=this.rules.other.hrRegex(d),a=this.rules.other.fencesBeginRegex(d),o=this.rules.other.headingBeginRegex(d),i=this.rules.other.htmlBeginRegex(d);for(;e;){const p=e.split("\n",1)[0];let h;if(c=p,this.options.pedantic?(c=c.replace(this.rules.other.listReplaceNesting," "),h=c):h=c.replace(this.rules.other.tabCharGlobal," "),a.test(c))break;if(o.test(c))break;if(i.test(c))break;if(t.test(c))break;if(n.test(c))break;if(h.search(this.rules.other.nonSpaceChar)>=d||!c.trim())s+="\n"+h.slice(d);else{if(u)break;if(l.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4)break;if(a.test(l))break;if(o.test(l))break;if(n.test(l))break;s+="\n"+c}u||c.trim()||(u=!0),r+=p+"\n",e=e.substring(p.length+1),l=h.slice(d)}}a.loose||(i?a.loose=!0:this.rules.other.doubleBlankLine.test(r)&&(i=!0));let p,h=null;this.options.gfm&&(h=this.rules.other.listIsTask.exec(s),h&&(p="[ ] "!==h[0],s=s.replace(this.rules.other.listReplaceTask,""))),a.items.push({type:"list_item",raw:r,task:!!h,checked:p,loose:!1,text:s,tokens:[]}),a.raw+=r}const s=a.items.at(-1);if(!s)return;s.raw=s.raw.trimEnd(),s.text=s.text.trimEnd(),a.raw=a.raw.trimEnd();for(let e=0;e<a.items.length;e++)if(this.lexer.state.top=!1,a.items[e].tokens=this.lexer.blockTokens(a.items[e].text,[]),!a.loose){const t=a.items[e].tokens.filter((e=>"space"===e.type)),n=t.length>0&&t.some((e=>this.rules.other.anyLine.test(e.raw)));a.loose=n}if(a.loose)for(let e=0;e<a.items.length;e++)a.items[e].loose=!0;return a}}html(e){const t=this.rules.block.html.exec(e);if(t){return{type:"html",block:!0,raw:t[0],pre:"pre"===t[1]||"script"===t[1]||"style"===t[1],text:t[0]}}}def(e){const t=this.rules.block.def.exec(e);if(t){const e=t[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),n=t[2]?t[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",r=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):t[3];return{type:"def",tag:e,raw:t[0],href:n,title:r}}}table(e){var t;const n=this.rules.block.table.exec(e);if(!n)return;if(!this.rules.other.tableDelimiter.test(n[2]))return;const r=W8(n[1]),a=n[2].replace(this.rules.other.tableAlignChars,"").split("|"),o=(null==(t=n[3])?void 0:t.trim())?n[3].replace(this.rules.other.tableRowBlankLine,"").split("\n"):[],i={type:"table",raw:n[0],header:[],align:[],rows:[]};if(r.length===a.length){for(const e of a)this.rules.other.tableAlignRight.test(e)?i.align.push("right"):this.rules.other.tableAlignCenter.test(e)?i.align.push("center"):this.rules.other.tableAlignLeft.test(e)?i.align.push("left"):i.align.push(null);for(let e=0;e<r.length;e++)i.header.push({text:r[e],tokens:this.lexer.inline(r[e]),header:!0,align:i.align[e]});for(const e of o)i.rows.push(W8(e,i.header.length).map(((e,t)=>({text:e,tokens:this.lexer.inline(e),header:!1,align:i.align[t]}))));return i}}lheading(e){const t=this.rules.block.lheading.exec(e);if(t)return{type:"heading",raw:t[0],depth:"="===t[2].charAt(0)?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){const t=this.rules.block.paragraph.exec(e);if(t){const e="\n"===t[1].charAt(t[1].length-1)?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:e,tokens:this.lexer.inline(e)}}}text(e){const t=this.rules.block.text.exec(e);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){const t=this.rules.inline.escape.exec(e);if(t)return{type:"escape",raw:t[0],text:t[1]}}tag(e){const t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){const t=this.rules.inline.link.exec(e);if(t){const e=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(e)){if(!this.rules.other.endAngleBracket.test(e))return;const t=Y8(e.slice(0,-1),"\\");if((e.length-t.length)%2==0)return}else{const e=function(e,t){if(-1===e.indexOf(t[1]))return-1;let n=0;for(let r=0;r<e.length;r++)if("\\"===e[r])r++;else if(e[r]===t[0])n++;else if(e[r]===t[1]&&(n--,n<0))return r;return n>0?-2:-1}(t[2],"()");if(-2===e)return;if(e>-1){const n=(0===t[0].indexOf("!")?5:4)+t[1].length+e;t[2]=t[2].substring(0,e),t[0]=t[0].substring(0,n).trim(),t[3]=""}}let n=t[2],r="";if(this.options.pedantic){const e=this.rules.other.pedanticHrefTitle.exec(n);e&&(n=e[1],r=e[3])}else r=t[3]?t[3].slice(1,-1):"";return n=n.trim(),this.rules.other.startAngleBracket.test(n)&&(n=this.options.pedantic&&!this.rules.other.endAngleBracket.test(e)?n.slice(1):n.slice(1,-1)),K8(t,{href:n?n.replace(this.rules.inline.anyPunctuation,"$1"):n,title:r?r.replace(this.rules.inline.anyPunctuation,"$1"):r},t[0],this.lexer,this.rules)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){const e=t[(n[2]||n[1]).replace(this.rules.other.multipleSpaceGlobal," ").toLowerCase()];if(!e){const e=n[0].charAt(0);return{type:"text",raw:e,text:e}}return K8(n,e,n[0],this.lexer,this.rules)}}emStrong(e,t,n=""){let r=this.rules.inline.emStrongLDelim.exec(e);if(!r)return;if(r[3]&&n.match(this.rules.other.unicodeAlphaNumeric))return;if(!(r[1]||r[2]||"")||!n||this.rules.inline.punctuation.exec(n)){const n=[...r[0]].length-1;let a,o,i=n,s=0;const l="*"===r[0][0]?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(l.lastIndex=0,t=t.slice(-1*e.length+n);null!=(r=l.exec(t));){if(a=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!a)continue;if(o=[...a].length,r[3]||r[4]){i+=o;continue}if((r[5]||r[6])&&n%3&&!((n+o)%3)){s+=o;continue}if(i-=o,i>0)continue;o=Math.min(o,o+i+s);const t=[...r[0]][0].length,l=e.slice(0,n+r.index+t+o);if(Math.min(n,o)%2){const e=l.slice(1,-1);return{type:"em",raw:l,text:e,tokens:this.lexer.inlineTokens(e)}}const c=l.slice(2,-2);return{type:"strong",raw:l,text:c,tokens:this.lexer.inlineTokens(c)}}}}codespan(e){const t=this.rules.inline.code.exec(e);if(t){let e=t[2].replace(this.rules.other.newLineCharGlobal," ");const n=this.rules.other.nonSpaceChar.test(e),r=this.rules.other.startingSpaceChar.test(e)&&this.rules.other.endingSpaceChar.test(e);return n&&r&&(e=e.substring(1,e.length-1)),{type:"codespan",raw:t[0],text:e}}}br(e){const t=this.rules.inline.br.exec(e);if(t)return{type:"br",raw:t[0]}}del(e){const t=this.rules.inline.del.exec(e);if(t)return{type:"del",raw:t[0],text:t[2],tokens:this.lexer.inlineTokens(t[2])}}autolink(e){const t=this.rules.inline.autolink.exec(e);if(t){let e,n;return"@"===t[2]?(e=t[1],n="mailto:"+e):(e=t[1],n=e),{type:"link",raw:t[0],text:e,href:n,tokens:[{type:"text",raw:e,text:e}]}}}url(e){var t;let n;if(n=this.rules.inline.url.exec(e)){let e,r;if("@"===n[2])e=n[0],r="mailto:"+e;else{let a;do{a=n[0],n[0]=(null==(t=this.rules.inline._backpedal.exec(n[0]))?void 0:t[0])??""}while(a!==n[0]);e=n[0],r="www."===n[1]?"http://"+n[0]:n[0]}return{type:"link",raw:n[0],text:e,href:r,tokens:[{type:"text",raw:e,text:e}]}}}inlineText(e){const t=this.rules.inline.text.exec(e);if(t){const e=this.lexer.state.inRawBlock;return{type:"text",raw:t[0],text:t[0],escaped:e}}}}class Q8{constructor(e){i(this,"tokens"),i(this,"options"),i(this,"state"),i(this,"tokenizer"),i(this,"inlineQueue"),this.tokens=[],this.tokens.links=Object.create(null),this.options=e||Y6,this.options.tokenizer=this.options.tokenizer||new X8,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};const t={other:Z6,block:H8.normal,inline:U8.normal};this.options.pedantic?(t.block=H8.pedantic,t.inline=U8.pedantic):this.options.gfm&&(t.block=H8.gfm,this.options.breaks?t.inline=U8.breaks:t.inline=U8.gfm),this.tokenizer.rules=t}static get rules(){return{block:H8,inline:U8}}static lex(e,t){return new Q8(t).lex(e)}static lexInline(e,t){return new Q8(t).inlineTokens(e)}lex(e){e=e.replace(Z6.carriageReturn,"\n"),this.blockTokens(e,this.tokens);for(let t=0;t<this.inlineQueue.length;t++){const e=this.inlineQueue[t];this.inlineTokens(e.src,e.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(e,t=[],n=!1){var r,a,o;for(this.options.pedantic&&(e=e.replace(Z6.tabCharGlobal," ").replace(Z6.spaceLine,""));e;){let i;if(null==(a=null==(r=this.options.extensions)?void 0:r.block)?void 0:a.some((n=>!!(i=n.call({lexer:this},e,t))&&(e=e.substring(i.raw.length),t.push(i),!0))))continue;if(i=this.tokenizer.space(e)){e=e.substring(i.raw.length);const n=t.at(-1);1===i.raw.length&&void 0!==n?n.raw+="\n":t.push(i);continue}if(i=this.tokenizer.code(e)){e=e.substring(i.raw.length);const n=t.at(-1);"paragraph"===(null==n?void 0:n.type)||"text"===(null==n?void 0:n.type)?(n.raw+="\n"+i.raw,n.text+="\n"+i.text,this.inlineQueue.at(-1).src=n.text):t.push(i);continue}if(i=this.tokenizer.fences(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.heading(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.hr(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.blockquote(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.list(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.html(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.def(e)){e=e.substring(i.raw.length);const n=t.at(-1);"paragraph"===(null==n?void 0:n.type)||"text"===(null==n?void 0:n.type)?(n.raw+="\n"+i.raw,n.text+="\n"+i.raw,this.inlineQueue.at(-1).src=n.text):this.tokens.links[i.tag]||(this.tokens.links[i.tag]={href:i.href,title:i.title});continue}if(i=this.tokenizer.table(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.lheading(e)){e=e.substring(i.raw.length),t.push(i);continue}let s=e;if(null==(o=this.options.extensions)?void 0:o.startBlock){let t=1/0;const n=e.slice(1);let r;this.options.extensions.startBlock.forEach((e=>{r=e.call({lexer:this},n),"number"==typeof r&&r>=0&&(t=Math.min(t,r))})),t<1/0&&t>=0&&(s=e.substring(0,t+1))}if(this.state.top&&(i=this.tokenizer.paragraph(s))){const r=t.at(-1);n&&"paragraph"===(null==r?void 0:r.type)?(r.raw+="\n"+i.raw,r.text+="\n"+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=r.text):t.push(i),n=s.length!==e.length,e=e.substring(i.raw.length)}else if(i=this.tokenizer.text(e)){e=e.substring(i.raw.length);const n=t.at(-1);"text"===(null==n?void 0:n.type)?(n.raw+="\n"+i.raw,n.text+="\n"+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=n.text):t.push(i)}else if(e){const t="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw new Error(t)}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}inlineTokens(e,t=[]){var n,r,a;let o=e,i=null;if(this.tokens.links){const e=Object.keys(this.tokens.links);if(e.length>0)for(;null!=(i=this.tokenizer.rules.inline.reflinkSearch.exec(o));)e.includes(i[0].slice(i[0].lastIndexOf("[")+1,-1))&&(o=o.slice(0,i.index)+"["+"a".repeat(i[0].length-2)+"]"+o.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(i=this.tokenizer.rules.inline.anyPunctuation.exec(o));)o=o.slice(0,i.index)+"++"+o.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;null!=(i=this.tokenizer.rules.inline.blockSkip.exec(o));)o=o.slice(0,i.index)+"["+"a".repeat(i[0].length-2)+"]"+o.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);let s=!1,l="";for(;e;){let i;if(s||(l=""),s=!1,null==(r=null==(n=this.options.extensions)?void 0:n.inline)?void 0:r.some((n=>!!(i=n.call({lexer:this},e,t))&&(e=e.substring(i.raw.length),t.push(i),!0))))continue;if(i=this.tokenizer.escape(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.tag(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.link(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(i.raw.length);const n=t.at(-1);"text"===i.type&&"text"===(null==n?void 0:n.type)?(n.raw+=i.raw,n.text+=i.text):t.push(i);continue}if(i=this.tokenizer.emStrong(e,o,l)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.codespan(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.br(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.del(e)){e=e.substring(i.raw.length),t.push(i);continue}if(i=this.tokenizer.autolink(e)){e=e.substring(i.raw.length),t.push(i);continue}if(!this.state.inLink&&(i=this.tokenizer.url(e))){e=e.substring(i.raw.length),t.push(i);continue}let c=e;if(null==(a=this.options.extensions)?void 0:a.startInline){let t=1/0;const n=e.slice(1);let r;this.options.extensions.startInline.forEach((e=>{r=e.call({lexer:this},n),"number"==typeof r&&r>=0&&(t=Math.min(t,r))})),t<1/0&&t>=0&&(c=e.substring(0,t+1))}if(i=this.tokenizer.inlineText(c)){e=e.substring(i.raw.length),"_"!==i.raw.slice(-1)&&(l=i.raw.slice(-1)),s=!0;const n=t.at(-1);"text"===(null==n?void 0:n.type)?(n.raw+=i.raw,n.text+=i.text):t.push(i)}else if(e){const t="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw new Error(t)}}return t}}class Z8{constructor(e){i(this,"options"),i(this,"parser"),this.options=e||Y6}space(e){return""}code({text:e,lang:t,escaped:n}){var r;const a=null==(r=(t||"").match(Z6.notSpaceStart))?void 0:r[0],o=e.replace(Z6.endingNewline,"")+"\n";return a?'<pre><code class="language-'+V8(a)+'">'+(n?o:V8(o,!0))+"</code></pre>\n":"<pre><code>"+(n?o:V8(o,!0))+"</code></pre>\n"}blockquote({tokens:e}){return`<blockquote>\n${this.parser.parse(e)}</blockquote>\n`}html({text:e}){return e}heading({tokens:e,depth:t}){return`<h${t}>${this.parser.parseInline(e)}</h${t}>\n`}hr(e){return"<hr>\n"}list(e){const t=e.ordered,n=e.start;let r="";for(let o=0;o<e.items.length;o++){const t=e.items[o];r+=this.listitem(t)}const a=t?"ol":"ul";return"<"+a+(t&&1!==n?' start="'+n+'"':"")+">\n"+r+"</"+a+">\n"}listitem(e){var t;let n="";if(e.task){const r=this.checkbox({checked:!!e.checked});e.loose?"paragraph"===(null==(t=e.tokens[0])?void 0:t.type)?(e.tokens[0].text=r+" "+e.tokens[0].text,e.tokens[0].tokens&&e.tokens[0].tokens.length>0&&"text"===e.tokens[0].tokens[0].type&&(e.tokens[0].tokens[0].text=r+" "+V8(e.tokens[0].tokens[0].text),e.tokens[0].tokens[0].escaped=!0)):e.tokens.unshift({type:"text",raw:r+" ",text:r+" ",escaped:!0}):n+=r+" "}return n+=this.parser.parse(e.tokens,!!e.loose),`<li>${n}</li>\n`}checkbox({checked:e}){return"<input "+(e?'checked="" ':"")+'disabled="" type="checkbox">'}paragraph({tokens:e}){return`<p>${this.parser.parseInline(e)}</p>\n`}table(e){let t="",n="";for(let a=0;a<e.header.length;a++)n+=this.tablecell(e.header[a]);t+=this.tablerow({text:n});let r="";for(let a=0;a<e.rows.length;a++){const t=e.rows[a];n="";for(let e=0;e<t.length;e++)n+=this.tablecell(t[e]);r+=this.tablerow({text:n})}return r&&(r=`<tbody>${r}</tbody>`),"<table>\n<thead>\n"+t+"</thead>\n"+r+"</table>\n"}tablerow({text:e}){return`<tr>\n${e}</tr>\n`}tablecell(e){const t=this.parser.parseInline(e.tokens),n=e.header?"th":"td";return(e.align?`<${n} align="${e.align}">`:`<${n}>`)+t+`</${n}>\n`}strong({tokens:e}){return`<strong>${this.parser.parseInline(e)}</strong>`}em({tokens:e}){return`<em>${this.parser.parseInline(e)}</em>`}codespan({text:e}){return`<code>${V8(e,!0)}</code>`}br(e){return"<br>"}del({tokens:e}){return`<del>${this.parser.parseInline(e)}</del>`}link({href:e,title:t,tokens:n}){const r=this.parser.parseInline(n),a=q8(e);if(null===a)return r;let o='<a href="'+(e=a)+'"';return t&&(o+=' title="'+V8(t)+'"'),o+=">"+r+"</a>",o}image({href:e,title:t,text:n}){const r=q8(e);if(null===r)return V8(n);let a=`<img src="${e=r}" alt="${n}"`;return t&&(a+=` title="${V8(t)}"`),a+=">",a}text(e){return"tokens"in e&&e.tokens?this.parser.parseInline(e.tokens):"escaped"in e&&e.escaped?e.text:V8(e.text)}}class J8{strong({text:e}){return e}em({text:e}){return e}codespan({text:e}){return e}del({text:e}){return e}html({text:e}){return e}text({text:e}){return e}link({text:e}){return""+e}image({text:e}){return""+e}br(){return""}}class e9{constructor(e){i(this,"options"),i(this,"renderer"),i(this,"textRenderer"),this.options=e||Y6,this.options.renderer=this.options.renderer||new Z8,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new J8}static parse(e,t){return new e9(t).parse(e)}static parseInline(e,t){return new e9(t).parseInline(e)}parse(e,t=!0){var n,r;let a="";for(let o=0;o<e.length;o++){const i=e[o];if(null==(r=null==(n=this.options.extensions)?void 0:n.renderers)?void 0:r[i.type]){const e=i,t=this.options.extensions.renderers[e.type].call({parser:this},e);if(!1!==t||!["space","hr","heading","code","table","blockquote","list","html","paragraph","text"].includes(e.type)){a+=t||"";continue}}const s=i;switch(s.type){case"space":a+=this.renderer.space(s);continue;case"hr":a+=this.renderer.hr(s);continue;case"heading":a+=this.renderer.heading(s);continue;case"code":a+=this.renderer.code(s);continue;case"table":a+=this.renderer.table(s);continue;case"blockquote":a+=this.renderer.blockquote(s);continue;case"list":a+=this.renderer.list(s);continue;case"html":a+=this.renderer.html(s);continue;case"paragraph":a+=this.renderer.paragraph(s);continue;case"text":{let n=s,r=this.renderer.text(n);for(;o+1<e.length&&"text"===e[o+1].type;)n=e[++o],r+="\n"+this.renderer.text(n);a+=t?this.renderer.paragraph({type:"paragraph",raw:r,text:r,tokens:[{type:"text",raw:r,text:r,escaped:!0}]}):r;continue}default:{const e='Token with "'+s.type+'" type was not found.';if(this.options.silent)return console.error(e),"";throw new Error(e)}}}return a}parseInline(e,t=this.renderer){var n,r;let a="";for(let o=0;o<e.length;o++){const i=e[o];if(null==(r=null==(n=this.options.extensions)?void 0:n.renderers)?void 0:r[i.type]){const e=this.options.extensions.renderers[i.type].call({parser:this},i);if(!1!==e||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(i.type)){a+=e||"";continue}}const s=i;switch(s.type){case"escape":case"text":a+=t.text(s);break;case"html":a+=t.html(s);break;case"link":a+=t.link(s);break;case"image":a+=t.image(s);break;case"strong":a+=t.strong(s);break;case"em":a+=t.em(s);break;case"codespan":a+=t.codespan(s);break;case"br":a+=t.br(s);break;case"del":a+=t.del(s);break;default:{const e='Token with "'+s.type+'" type was not found.';if(this.options.silent)return console.error(e),"";throw new Error(e)}}}return a}}class t9{constructor(e){i(this,"options"),i(this,"block"),this.options=e||Y6}preprocess(e){return e}postprocess(e){return e}processAllTokens(e){return e}provideLexer(){return this.block?Q8.lex:Q8.lexInline}provideParser(){return this.block?e9.parse:e9.parseInline}}i(t9,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens"]));const n9=new class{constructor(...e){i(this,"defaults",{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}),i(this,"options",this.setOptions),i(this,"parse",this.parseMarkdown(!0)),i(this,"parseInline",this.parseMarkdown(!1)),i(this,"Parser",e9),i(this,"Renderer",Z8),i(this,"TextRenderer",J8),i(this,"Lexer",Q8),i(this,"Tokenizer",X8),i(this,"Hooks",t9),this.use(...e)}walkTokens(e,t){var n,r;let a=[];for(const o of e)switch(a=a.concat(t.call(this,o)),o.type){case"table":{const e=o;for(const n of e.header)a=a.concat(this.walkTokens(n.tokens,t));for(const n of e.rows)for(const e of n)a=a.concat(this.walkTokens(e.tokens,t));break}case"list":{const e=o;a=a.concat(this.walkTokens(e.items,t));break}default:{const e=o;(null==(r=null==(n=this.defaults.extensions)?void 0:n.childTokens)?void 0:r[e.type])?this.defaults.extensions.childTokens[e.type].forEach((n=>{const r=e[n].flat(1/0);a=a.concat(this.walkTokens(r,t))})):e.tokens&&(a=a.concat(this.walkTokens(e.tokens,t)))}}return a}use(...e){const t=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach((e=>{const n={...e};if(n.async=this.defaults.async||n.async||!1,e.extensions&&(e.extensions.forEach((e=>{if(!e.name)throw new Error("extension name required");if("renderer"in e){const n=t.renderers[e.name];t.renderers[e.name]=n?function(...t){let r=e.renderer.apply(this,t);return!1===r&&(r=n.apply(this,t)),r}:e.renderer}if("tokenizer"in e){if(!e.level||"block"!==e.level&&"inline"!==e.level)throw new Error("extension level must be 'block' or 'inline'");const n=t[e.level];n?n.unshift(e.tokenizer):t[e.level]=[e.tokenizer],e.start&&("block"===e.level?t.startBlock?t.startBlock.push(e.start):t.startBlock=[e.start]:"inline"===e.level&&(t.startInline?t.startInline.push(e.start):t.startInline=[e.start]))}"childTokens"in e&&e.childTokens&&(t.childTokens[e.name]=e.childTokens)})),n.extensions=t),e.renderer){const t=this.defaults.renderer||new Z8(this.defaults);for(const n in e.renderer){if(!(n in t))throw new Error(`renderer '${n}' does not exist`);if(["options","parser"].includes(n))continue;const r=n,a=e.renderer[r],o=t[r];t[r]=(...e)=>{let n=a.apply(t,e);return!1===n&&(n=o.apply(t,e)),n||""}}n.renderer=t}if(e.tokenizer){const t=this.defaults.tokenizer||new X8(this.defaults);for(const n in e.tokenizer){if(!(n in t))throw new Error(`tokenizer '${n}' does not exist`);if(["options","rules","lexer"].includes(n))continue;const r=n,a=e.tokenizer[r],o=t[r];t[r]=(...e)=>{let n=a.apply(t,e);return!1===n&&(n=o.apply(t,e)),n}}n.tokenizer=t}if(e.hooks){const t=this.defaults.hooks||new t9;for(const n in e.hooks){if(!(n in t))throw new Error(`hook '${n}' does not exist`);if(["options","block"].includes(n))continue;const r=n,a=e.hooks[r],o=t[r];t9.passThroughHooks.has(n)?t[r]=e=>{if(this.defaults.async)return Promise.resolve(a.call(t,e)).then((e=>o.call(t,e)));const n=a.call(t,e);return o.call(t,n)}:t[r]=(...e)=>{let n=a.apply(t,e);return!1===n&&(n=o.apply(t,e)),n}}n.hooks=t}if(e.walkTokens){const t=this.defaults.walkTokens,r=e.walkTokens;n.walkTokens=function(e){let n=[];return n.push(r.call(this,e)),t&&(n=n.concat(t.call(this,e))),n}}this.defaults={...this.defaults,...n}})),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return Q8.lex(e,t??this.defaults)}parser(e,t){return e9.parse(e,t??this.defaults)}parseMarkdown(e){return(t,n)=>{const r={...n},a={...this.defaults,...r},o=this.onError(!!a.silent,!!a.async);if(!0===this.defaults.async&&!1===r.async)return o(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(null==t)return o(new Error("marked(): input parameter is undefined or null"));if("string"!=typeof t)return o(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected"));a.hooks&&(a.hooks.options=a,a.hooks.block=e);const i=a.hooks?a.hooks.provideLexer():e?Q8.lex:Q8.lexInline,s=a.hooks?a.hooks.provideParser():e?e9.parse:e9.parseInline;if(a.async)return Promise.resolve(a.hooks?a.hooks.preprocess(t):t).then((e=>i(e,a))).then((e=>a.hooks?a.hooks.processAllTokens(e):e)).then((e=>a.walkTokens?Promise.all(this.walkTokens(e,a.walkTokens)).then((()=>e)):e)).then((e=>s(e,a))).then((e=>a.hooks?a.hooks.postprocess(e):e)).catch(o);try{a.hooks&&(t=a.hooks.preprocess(t));let e=i(t,a);a.hooks&&(e=a.hooks.processAllTokens(e)),a.walkTokens&&this.walkTokens(e,a.walkTokens);let n=s(e,a);return a.hooks&&(n=a.hooks.postprocess(n)),n}catch(X4){return o(X4)}}}onError(e,t){return n=>{if(n.message+="\nPlease report this to https://github.com/markedjs/marked.",e){const e="<p>An error occurred:</p><pre>"+V8(n.message+"",!0)+"</pre>";return t?Promise.resolve(e):e}if(t)return Promise.reject(n);throw n}}};function r9(e,t){return n9.parse(e,t)}function a9(){const[e,t]=K.useState(!1);return[e,K.useCallback((async e=>{if(!(null==navigator?void 0:navigator.clipboard))return console.warn("Clipboard not supported"),!1;try{const n=await r9.parse(e),r={"text/plain":new Blob([e],{type:"text/plain"}),"text/html":new Blob([n],{type:"text/html"})};return await navigator.clipboard.write([new ClipboardItem(r)]),t(!0),setTimeout((()=>{t(!1)}),1e3),!0}catch(n){return console.warn("Copy failed",n),t(!1),!1}}),[])]}r9.options=r9.setOptions=function(e){return n9.setOptions(e),r9.defaults=n9.defaults,K6(r9.defaults),r9},r9.getDefaults=W6,r9.defaults=Y6,r9.use=function(...e){return n9.use(...e),r9.defaults=n9.defaults,K6(r9.defaults),r9},r9.walkTokens=function(e,t){return n9.walkTokens(e,t)},r9.parseInline=n9.parseInline,r9.Parser=e9,r9.parser=e9.parse,r9.Renderer=Z8,r9.TextRenderer=J8,r9.Lexer=Q8,r9.lexer=Q8.lex,r9.Tokenizer=X8,r9.Hooks=t9,r9.parse=r9,r9.options,r9.setOptions,r9.use,r9.walkTokens,r9.parseInline,e9.parse,Q8.lex;const o9=qB("h1",{_id:"markdownH1"}),i9=qB("h2",{_id:"markdownH2"}),s9=qB("p",{_id:"markdownP"}),l9=qB("li",{_id:"markdownLi"}),c9=qB("ul",{_id:"markdownUl"}),u9=qB("ol",{_id:"markdownOl"}),d9=qB(zY,{_id:"markdownLink"}),p9=qB("sup",{_id:"markdownSourceLink"}),h9=qB("table",{_id:"markdownTable"}),f9=qB("th",{_id:"markdownTh"}),m9=qB("td",{_id:"markdownTd"}),g9=qB("code",{_id:"markdownCode"}),y9=qB("div",{_id:"codeblockContainer"}),b9=qB("div",{_id:"codeblockHeader"}),v9=qB("span",{_id:"codeblockHeaderLanguage"}),k9=qB("button",{_id:"codeblockCopyButton",type:"button"}),w9=qB("div",{_id:"codeblockHighlighterWrapper"}),x9=qB("div",{_id:"codeblockHighlighter"}),E9=qB("code",{_id:"codeblockCode"}),_9=qB("input",{_id:"markdownInput"}),S9=y6.oneLight,T9=y6.vsDark,C9=({className:e="",children:t,onCopy:n})=>{var r;const a=e.replace(/^language-/,""),o=String(t).replace(/\n$/,""),[i,s]=a9(),{baseSettings:l}=nP(),c=null==(r=l.theme)?void 0:r.syntaxHighlighter,{lightTheme:u=S9,darkTheme:d=T9}=c??{},p=fB(u,d);return Wh.jsxs(y9,{children:[Wh.jsxs(b9,{children:[Wh.jsx(v9,{children:a}),Wh.jsx(k9,{"aria-label":"Copy to clipboard",onClick:()=>{s(o),null==n||n(a,o)},"data-copied":SL(i),children:Wh.jsx(jY,{iconKey:i?"codeCopied":"codeCopy"})})]}),Wh.jsx(w9,{children:Wh.jsx(q6,{theme:p,code:o,language:a,prism:l.prism,children:({className:e,tokens:t,getLineProps:n,getTokenProps:r,style:a})=>Wh.jsx(x9,{className:e,children:Wh.jsx(E9,{style:a,children:t.map(((e,t)=>Wh.jsx("div",{...n({line:e}),children:e.map(((e,t)=>Wh.jsx("span",{...r({token:e})},t)))},t)))})})})})]})};function A9(){return e=>{KZ(e,"element",((e,t,n)=>{"code"===e.tagName&&(n&&"pre"===n.tagName?e.properties.inline=!1:e.properties.inline=!0)}))}}const N9=({children:e,componentStyles:t,shouldOpenLinksInNewTab:n,onLinkClick:r,onCodeCopy:a,...o})=>{if(!e)return null;const i={h1:({children:e})=>Wh.jsx(o9,{children:e}),h2:({children:e})=>Wh.jsx(i9,{children:e}),p:({children:e})=>Wh.jsx(s9,{children:e}),li:({children:e})=>Wh.jsx(l9,{children:e}),ul:({children:e})=>Wh.jsx(c9,{children:e}),input:({type:e,checked:t,disabled:n,readOnly:r,required:a,value:o})=>Wh.jsx(_9,{type:e,checked:t,disabled:n,readOnly:r,required:a,value:o}),ol:({children:e,node:t})=>{var n;const r=null==(n=null==t?void 0:t.properties)?void 0:n.start,a="number"==typeof r?r:void 0;return Wh.jsx(u9,{style:{"--start":(null==r?void 0:r.toString())??"0"},start:a,children:e})},a:({children:e,href:t})=>{const a=X.Children.toArray(e),o=a[0],i="string"==typeof o&&/^\(\d+\)$/.test(o)&&1===a.length,s=i?o.match(/\d+/):e,l=Wh.jsx(d9,{isExternal:n,href:t,onClick:()=>{null==r||r(t,null==s?void 0:s.toString())},children:s});return i?Wh.jsx(p9,{children:l}):l},img:({src:e,alt:t})=>``,table:({children:e})=>Wh.jsx(h9,{children:e}),th:({children:e,isHeader:t})=>t?Wh.jsx(f9,{children:e}):Wh.jsx(m9,{children:e}),pre:({children:e})=>Wh.jsx("pre",{children:e}),code:({children:e,inline:t,className:n})=>t?Wh.jsx(g9,{children:e}):Wh.jsx(C9,{className:n,onCopy:a,children:e})},s=Wh.jsx(UJ,{remarkPlugins:[V4],rehypePlugins:[e3,A9],components:i,disallowedElements:I9,children:e.toString(),...o});return Wh.jsx(nB,{componentStyles:t,children:s})},I9=["script","iframe","frame","embed","meta","base","form","style","object"];function R9(){return Wh.jsxs("svg",{viewBox:"0 0 12 10",style:{width:"1.2em",fill:"none",strokeWidth:2,stroke:"currentColor",strokeDasharray:16},children:[Wh.jsx("title",{children:"Checkbox Icon"}),Wh.jsx("polyline",{points:"1.5 6 4.5 9 10.5 1"})]})}function O9(e){return Wh.jsxs("svg",{viewBox:"0 0 32 33",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:[Wh.jsx("title",{children:"Tag Line Logo Icon"}),Wh.jsx("path",{d:"M7.2413 7.9244C6.85545 7.9244 6.49892 8.13025 6.30599 8.4644L1.99827 15.9256C1.80535 16.2597 1.80535 16.6714 1.99827 17.0056L6.30599 24.4668C6.49892 24.8009 6.85545 25.0068 7.2413 25.0068L15.8567 25.0068C16.2426 25.0068 16.5991 24.8009 16.792 24.4668L21.0998 17.0056C21.2927 16.6714 21.2927 16.2597 21.0998 15.9256L16.792 8.4644C16.5991 8.13025 16.2426 7.9244 15.8567 7.9244L7.2413 7.9244Z",stroke:"currentColor",strokeWidth:"1.75"}),Wh.jsx("path",{d:"M24.8143 7.76209C27.3966 8.42659 27.1023 9.89204 28.1732 12.8728C28.8603 14.7852 32.182 17.1565 29.1465 21.766C28.2406 23.1417 25.3276 24.7738 23.2199 25.2265C18.5764 26.2085 15.8404 23.98 13.4131 20.3057C11.592 17.5265 12.2355 13.5253 14.9976 11.5606C17.6151 9.70372 21.4197 6.82238 24.8143 7.76209Z",stroke:"currentColor",strokeWidth:"1.75"})]})}const P9=e=>{const{logEvent:t}=wP(),{conversation:n}=iP(),{openForm:r}=dL(),a=iL();return{handleAction:t=>{var o;if("open_form"===e.action.type){null==(o=null==t?void 0:t.onOpenForm)||o.call(t);const n="name"in e?e:void 0;null==r||r(e.action.formSettings,n)}else"invoke_callback"===e.action.type&&(e.action.callback({conversation:n}),e.action.shouldCloseModal&&(null==a||a.setOpen(!1)))},logHelpAction:()=>{"name"in e&&(t({eventName:"get_help_option_clicked",properties:{getHelpOption:e,conversation:n}}),"open_form"!==e.action.type&&t({eventName:"user_escalation_indicated",properties:{escalationType:"get_help_option",getHelpOption:e,conversation:n}}))}}},D9=e=>{const t=/<em>(.*?)<\/em>/gs;let n;const r=[];let a=0;for(;null!==(n=t.exec(e));){const[t,o]=n;n.index>a&&r.push(e.slice(a,n.index)),r.push({content:o,highlighted:!0}),a=n.index+t.length}return a<e.length&&r.push(e.slice(a)),r};function L9(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}function M9(e){return e.toLowerCase().replace(/(^\w+:|^)\/\//,"").replace(/^www\./,"").replace(/\/$/,"").startsWith("github.com")}function F9(e,t){const n=["API","Docs","Documentation","Blogs",t],r=["\\|","-",":"],a=new RegExp(`^\\s*(${n.join("|")})(\\.\\w+)?\\s*(${r.join("|")})\\s*`,"gi"),o=new RegExp(`\\s*(${r.join("|")})\\s*(${n.join("|")})\\s*$`,"gi");return e.replace(a,"").replace(o,"").trim()}const j9={js:".js",db:"DB",sql:"SQL"};function B9(e){return Object.entries(j9).reduce(((e,[t,n])=>{const r=new RegExp(`([a-zA-Z0-9])${t}(?!\\w)`,"g");return e.replace(r,((e,t)=>t+n))}),e)}const z9=["API","AWS","GCP","SQL","CSS","JS","JDK","SDK","JRE","IDE","XML","GUI","CLI","AI","ML","DL","IoT","TCP","UDP","IP","FTP","RAM","ROM","SSD","HDD","VPS","VPN","OS","UI","UX","DB","OOP","CRM","ERP","POS","CAD","BI","CMS","SEO","SEM","PPC","B2B","B2C","SMB","ROI","KPI","CTA","CPC","CPM","CDN","MVC","FAQ","LMS","RPA","QA","QC","CRO","SVN","GIT","DOM","DNS","ISP","URL","URN","URI","SIP","NFC","LTE","OSI","RAS","DRM","DOS","WWW","LAN","WAN","SAN","NAS","NLP","OCR","IBM","HP","SAP","JWT","SSH","SSL","TLS","POP","NTP","BGP","ARP","2FA","MFA","RDP","VNC","SCP","PKI","XSS","DoS","CSV","HL7","SOP","PHP","JSP","NET","VBA","iOS","GNU","CPU","GPU","NIC","USB","VGA","AES","RSA","DES","ECC","WEP","WPA","IDS","IPS","PM","HR","TCO","BPM","SLA","SOW","AR","VR","XR","3D","2D","4D","iOS","OpenAPI","SSO"],H9=["a","an","the","and","as","but","or","nor","at","by","in","of","on","per","to","up","via","vs","with","is","it","for","are","not","out","off","yet","so","be","if","has","its","we","our","any","all","how","her","his","their","was","were"],U9=["BaaS","SaaS","PaaS","IaaS","HTML","JSON","HTTPS","HTTP","SMTP","DBMS","RDBMS","REST","SOAP","MVVM","VoIP","RFID","WYSIWYG","WLAN","OIDC","SAML","LDAP","IPSec","OAuth","OpenID","SFTP","IMAP","RTSP","DHCP","XMPP","SNMP","ICMP","IGMP","RARP","PPTP","L2TP","IPv4","IPv6","TOTP","HMAC","TFTP","CORS","CSRF","DDOS","YAML","MQTT","AMQP","HDLC","EDIFACT","DICOM","MATLAB","UNIX","HDMI","WiFi","WPA2","DDoS","ipadOS","watchOS","macOS","JavaScript","TypeScript","SSO","IDP","RBAC"];function $9(e){return`\\b${e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}\\b`}function G9(e,t,n,r=!1){return r&&new RegExp(`^${n}\\b`,"i").test(e)?e:e.replace(new RegExp(n,"gi"),t)}const V9=(e,t)=>{var n;if("documentation"!==e.type)return[];const r=null==t?void 0:t.organizationDisplayName;return((null==(n=e.breadcrumbs)?void 0:n.length)?e.breadcrumbs:function(e){try{const t=new URL(e);return t.pathname.split("/").filter((e=>e.length>0)).slice(0,-1).map(q9)}catch(t){return console.error("Invalid URL:",t),[]}}(e.url)).map((e=>{let t=e;return r&&(t=function(e,t){if(!function(e){const t=e.split(" ");for(const n of t)if(n[0]!==n[0].toUpperCase()||n.slice(1)!==n.slice(1).toLowerCase())return!1;return!0}(t))return e;const n=`(?<![@/])\\b${t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}\\b`;return new RegExp(`^${n}\\b`,"i").test(e)?e:e.replace(new RegExp(n,"gi"),t)}(e,r),t=F9(t,r)),t=B9(t),t=function(e){let t=e;return t=H9.reduce(((e,t)=>G9(e,t,$9(t),!0)),t),t=U9.reduce(((e,t)=>G9(e,t,$9(t))),t),t=z9.reduce(((e,t)=>G9(e,t,$9(t))),t),t}(t),t}))??[]},q9=e=>e.split(/[-_]/).map((e=>e.charAt(0).toUpperCase()+e.slice(1).toLowerCase())).join(" ");const W9=(e,t)=>{var n;if("chatSourceItem"===t)return e.description??void 0;const r=e.breadcrumbs??[],a=r.length>0?r[r.length-1]:void 0,o=e.title||(null==(n=null==a?void 0:a.props)?void 0:n.str);return function(e,t){if(!e)return;if(!t)return e;const n=t.trim(),r=[n,`<em>${n}</em>`].find((t=>e.startsWith(t)));return r?e.slice(r.length).trim():e}(e.description,o)},Y9=e=>{let t="LuBookOpen";"documentation"===e.type&&"book"===e.contentType?t="IoBookOutline":"documentation"===e.type&&"pdf"===e.contentType?t="FaFilePdf":"github_issue"===e.type||M9(e.url)?t="FaGithub":"documentation"===e.type&&"site"===e.contentType?t="LuGlobe":"discourse"===e.type?t="FaDiscourse":"discord"===e.type?t="FaDiscord":"slack_message"===e.type?t="FaSlack":"stackoverflow"===e.type&&(t="FaStackOverflow");return{builtIn:t}},K9=(e,t)=>{let n=e.title;if(!n)return"";const r=null==t?void 0:t.organizationDisplayName;return n=B9(n),r&&(n=F9(n,r)),n},X9=(e,t,n)=>{const{transformSource:r,...a}=n,o=V9(e,n),i=((e,t)=>{var n,r,a;const o=[];"documentation"===e.type&&"book"===e.contentType?o.push("Publications"):"documentation"===e.type&&"pdf"===e.contentType&&o.push("PDFs"),("github_issue"===e.type||M9(e.url))&&o.push("GitHub"),"discourse"===e.type&&o.push("Forums"),"discord"===e.type&&o.push("Discord"),"slack_message"===e.type&&o.push("Slack"),"stackoverflow"===e.type&&o.push("StackOverflow");const i=[],s=null==(n=null==t?void 0:t.tabs)?void 0:n.map((e=>"string"==typeof e?e:e[0]));for(const l of o)(null==s?void 0:s.includes(l))&&(l===(null==(r=e.breadcrumbs)?void 0:r[0])?i.push([l,{breadcrumbs:null==(a=e.breadcrumbs)?void 0:a.slice(1)}]):i.push(l));return i})(e,n),s=(null==r?void 0:r({...e,breadcrumbs:o,tabs:i},t,a))??{};return{id:(null==s?void 0:s.id)??e.id,title:(null==s?void 0:s.title)??K9(e,n),description:(null==s?void 0:s.description)??W9(e,t),breadcrumbs:(null==s?void 0:s.breadcrumbs)??o,icon:(null==s?void 0:s.icon)??Y9(e),tabs:(null==s?void 0:s.tabs)??i,url:(null==s?void 0:s.url)??e.url,tag:(null==s?void 0:s.tag)??e.tag,type:(null==s?void 0:s.type)??e.type,shouldOpenInNewTab:(null==s?void 0:s.shouldOpenInNewTab)??void 0,appendToUrl:(null==s?void 0:s.appendToUrl)??void 0}};const Q9=K.createContext(void 0),Z9=({children:e,open:t,setOpen:n})=>Wh.jsx(Q9.Provider,{value:{open:t,setOpen:n},children:e}),J9=()=>{const e=K.useContext(Q9);if(!e)throw new Error("useHoverPopover must be used within a HoverPopoverProvider");return e},e7=(e,t,n)=>{const r=iL(),a=fL();K.useEffect((()=>{if(!n||r&&!r.isOpen)return;requestAnimationFrame((()=>{(null==t?void 0:t.current)&&((null==a?void 0:a.view)&&a.view!==e||(t.current.focus(),t.current.selectionStart=t.current.value.length))}))}),[n,t,r,null==a?void 0:a.view,e])},t7=qB("div",{_id:"aiChatWrapper"}),n7=K.forwardRef(((e,t)=>{const{...n}=e,{isHidden:r,isMobile:a}=$j(),[o,i]=function(){const e=K.useRef(null),[t,n]=K.useState({width:0,height:0});return K.useEffect((()=>{if(!e.current)return;const t=new ResizeObserver((([e])=>{const{width:t,height:r}=e.contentRect;n({width:t,height:r})}));return t.observe(e.current),()=>{t.disconnect()}}),[e]),[e,t]}(),s=BB(t,o),l=!(null==i?void 0:i.width)||i.width>580,c=iL();return Wh.jsx(t7,{ref:s,"data-widget-md":SL(l),"data-hidden":SL(r),"data-in-modal":SL(!!c),"data-mobile":SL(a),...n})})),r7=qB("div",{_id:"aiChatConversationLoading"}),a7=e=>{const{isLoadingConversation:t}=$j();return t?Wh.jsx(r7,{children:Wh.jsx("span",{children:"Loading..."}),...e}):null},o7=qB("div",{_id:"aiChatRoot"}),i7=e=>{const{isLoadingConversation:t,isHidden:n}=$j(),{form:r}=dL();return t||r?null:Wh.jsx(o7,{"data-hidden":SL(n),...e})},s7=qB("div",{_id:"aiChatHeader"}),l7=qB("div",{_id:"aiChatHeader__Toolbar"}),c7=qB("div",{_id:"aiChatHeader__ToolbarHeaderWrapper"}),u7=qB("div",{_id:"aiChatHeader__ToolbarHeader"}),d7=K.memo((e=>{const{aiChatSettings:t}=nP(),n=`Ask ${t.aiAssistantName||"AI"}`;return Wh.jsx(u7,{...e,children:n})})),p7=qB("div",{_id:"aiChatContent"}),h7=qB(P$,{_id:"aiChatContentScrollArea"}),f7=qB(D$,{_id:"aiChatContentScrollArea__Viewport"}),m7=K.forwardRef((({children:e,...t},n)=>{const{containerRef:r}=function(e={}){const{threshold:t=150,interactionTimeout:n=150}=e,r=K.useRef(null),a=K.useRef(!0),o=K.useRef(!1),i=K.useCallback((()=>{const e=r.current;return!!e&&e.scrollHeight-e.clientHeight-e.scrollTop<t}),[t]),s=K.useCallback(((e=!1)=>{const t=r.current;t&&!o.current&&t.scrollTo({top:t.scrollHeight,behavior:e?"smooth":"auto"})}),[]);return K.useEffect((()=>{const e=r.current;if(!e)return;let t;const s=()=>{o.current=!0,a.current=i(),window.clearTimeout(t),t=window.setTimeout((()=>{o.current=!1}),n)};return e.addEventListener("scroll",s,{passive:!0}),()=>{e.removeEventListener("scroll",s),window.clearTimeout(t)}}),[i,n]),K.useEffect((()=>{const e=r.current;if(!e)return;const t=new MutationObserver((e=>{e.some((e=>"childList"===e.type||"characterData"===e.type||"attributes"===e.type&&"style"===e.attributeName))&&a.current&&s(!0)}));return t.observe(e,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["style"],characterData:!0}),()=>t.disconnect()}),[s]),K.useEffect((()=>{r.current&&s()}),[s]),{containerRef:r,scrollToBottom:s,isNearBottom:i}}(),a=BB(n,r);return Wh.jsx(f7,{ref:a,children:Wh.jsx("div",{"data-part":"grid",style:{display:"grid"},children:e}),...t})})),g7=qB(l$,{_id:"aiChatContentScrollArea__Scrollbar"}),y7=qB(v$,{_id:"aiChatContentScrollArea__Thumb"}),b7=qB(L$,{_id:"aiChatContentScrollArea__Corner"}),v7=qB("div",{_id:"aiChatMessages"}),k7=e=>{const t=$j(),{children:n,...r}=e;return Wh.jsx(v7,{children:CL(n,t),...r})},w7=qB("div",{_id:"aiChatDisclaimer"}),x7=K.memo((e=>{var t;const{aiChatSettings:n}=nP(),[r,a]=K.useState(!1),o=function(e,t){const[n,r]=K.useState(e);return K.useEffect((()=>{const n=setTimeout((()=>{r(e)}),t);return()=>{clearTimeout(n)}}),[e,t]),n}(r,100);return(null==(t=n.disclaimerSettings)?void 0:t.isEnabled)?Wh.jsx(Z9,{open:r,setOpen:a,children:Wh.jsx(YU,{open:o,onOpenChange:a,children:Wh.jsx(w7,{...e})})}):null})),E7=qB("span",{_id:"aiChatDisclaimerLabel"}),_7=K.memo((e=>{const{aiChatSettings:t}=nP(),n=t.disclaimerSettings;return Wh.jsx(E7,{children:null==n?void 0:n.label,...e})})),S7=qB(KU,{_id:"aiChatDisclaimerTrigger",children:Wh.jsx(jY,{iconKey:"info"})}),T7=K.memo((e=>{const{setOpen:t}=J9();return Wh.jsx(S7,{onMouseEnter:()=>t(!0),onMouseLeave:()=>t(!1),...e})})),C7=qB(XU,{_id:"aiChatDisclaimerContent"}),A7=e=>{const{setOpen:t}=J9();return Wh.jsx(C7,{onMouseEnter:()=>t(!0),onMouseLeave:()=>t(!1),side:"top",sideOffset:8,align:"end",alignOffset:-10,...e})},N7=qB(N9,{_id:"aiChatDisclaimerText"}),I7=K.memo((e=>{const{aiChatSettings:t}=nP(),n=t.aiAssistantName,r=t.disclaimerSettings,a=(null==r?void 0:r.tooltip)||`Information provided by ${n||"this AI assistant"} is not guaranteed to be accurate or comprehensive.`;return Wh.jsx(N7,{shouldOpenLinksInNewTab:!0,children:a,...e})})),R7=qB(QU,{_id:"aiChatDisclaimerArrow"}),O7=qB("div",{_id:"aiChatExampleQuestions"}),P7=e=>{var t;const{aiChatSettings:n}=nP(),{messages:r}=$j();return!(null==(t=n.exampleQuestions)?void 0:t.length)||r.length?null:Wh.jsx(O7,{...e})},D7=qB("h3",{_id:"aiChatExampleQuestionsLabel"}),L7=K.memo((e=>{const{aiChatSettings:t}=nP();return Wh.jsx(D7,{children:t.exampleQuestionsLabel,...e})})),M7=qB("div",{_id:"aiChatExampleQuestionsList"}),F7=K.memo((e=>{const{aiChatSettings:t}=nP(),n=t.exampleQuestions,{children:r,...a}=e;return Wh.jsx(M7,{children:CL(r,n),...a})})),j7=qB("div",{_id:"aiChatExampleQuestion"}),B7=K.forwardRef(((e,t)=>{const{aiChatSettings:n}=nP(),r=n.isFirstExampleQuestionHighlighted;return Wh.jsx(j7,{ref:t,"data-highlight":SL(r),...e})})),z7=qB("button",{_id:"aiChatExampleQuestionButton"}),H7=e=>{const{question:t,onClick:n,...r}=e,{handleSubmit:a}=$j();return Wh.jsx(z7,{onClick:L9(n,(()=>a(t))),children:t,...r})};qB("div",{_id:"aiChatWorkflows"});const U7=qB("h3",{_id:"aiChatWorkflowsLabel"});K.memo((e=>{const{aiChatSettings:t}=nP();return Wh.jsx(U7,{children:t.workflowsHeader,...e})}));const $7=qB("div",{_id:"aiChatWorkflowsList"});K.memo((e=>{const{aiChatSettings:t}=nP(),n=t.workflows,{children:r,...a}=e;return Wh.jsx($7,{children:CL(r,n),...a})})),qB("button",{_id:"aiChatWorkflow"});const G7=qB("div",{_id:"aiChatMessageWrapper"}),V7=e=>{const{message:t,...n}=e;return"system"===t.role?null:Wh.jsx(sB,{message:t,children:Wh.jsx(G7,{"data-role":t.role,...n})})},q7=K.memo((e=>{const{message:t,...n}=e,{aiChatSettings:r,baseSettings:a}=nP(),o=r.aiAssistantName,i=o?`Hi, I'm ${o}!`:"Hi!",s=r.chatSubjectName??a.organizationDisplayName,l=`${i} \n\n I'm an AI assistant trained on documentation, help articles, and other content.`,c=s?`\n\n Ask me anything about \`${s}\`.`:"\n\n Let me know how I can help.",u={content:r.introMessage??`${l}${c}`,id:"__intro__",...t,role:"assistant",links:[]};return Wh.jsx(V7,{message:u,...n})})),W7=qB("div",{_id:"aiChatMessageHeader"}),Y7=e=>{const{message:t}=lB();return Wh.jsx(W7,{"data-role":t.role,...e})},K7=qB("div",{_id:"aiChatMessageLoading"}),X7=e=>{var t;const{isLoading:n,isStreaming:r,messages:a}=$j(),{message:o}=lB();return(null==(t=a.at(-1))?void 0:t.id)===(null==o?void 0:o.id)&&"assistant"===o.role&&n&&!r?Wh.jsx(K7,{children:"Thinking...",...e}):null},Q7=qB("div",{_id:"aiChatMessageAvatar"}),Z7=e=>{const{message:t}=lB();return Wh.jsx(Q7,{"data-role":t.role,...e})},J7=qB(vz,{_id:"aiChatMessageAvatarContent"}),eee=e=>{const{message:t}=lB(),{baseSettings:n}=nP();return Wh.jsx(J7,{"data-username":SL("user"===t.role&&!!n.userProperties.name),"data-role":t.role,...e})},tee=qB(wz,{_id:"aiChatMessageAvatarFallback"}),nee=K.memo((e=>{const{baseSettings:t}=nP(),{message:n}=lB();return t.userProperties.name?Wh.jsx(tee,{"data-role":n.role,children:TL(t.userProperties.name),...e}):null})),ree=qB(kz,{_id:"aiChatMessageAvatarImage"}),aee=K.memo((e=>{const{onLoadingStatusChange:t,...n}=e,{aiChatSettings:r,baseSettings:{userProperties:a}}=nP(),{message:o}=lB(),{aiAssistantAvatar:i}=r??{},s="string"==typeof i?i:null==i?void 0:i.light,l=fB(s,("string"==typeof i?i:null==i?void 0:i.dark)??s),[c,u]=K.useState(l);K.useEffect((()=>{u(l)}),[l]);return"user"===o.role?a.name?null:r.userAvatar?Wh.jsx(ree,{"data-type":"image",alt:"User avatar","data-role":o.role,src:r.userAvatar,...e}):Wh.jsx(mW,{"data-type":"icon","data-role":o.role,...e}):c?Wh.jsx(ree,{src:c,alt:"AI assistant avatar","data-type":"image","data-role":o.role,onLoadingStatusChange:L9(t,(e=>{"error"===e&&u(null)})),...n}):Wh.jsx(fW,{"data-type":"icon","data-role":o.role,...e})})),oee=qB("span",{_id:"aiChatMessageName"}),iee=e=>{const{message:t}=lB();return Wh.jsx(oee,{"data-role":t.role,children:"user"===t.role?"You":"AI assistant",...e})},see=qB("div",{_id:"aiChatMessageContentWrapper"}),lee=e=>{const{message:t}=lB(),{messageButtons:n}=$j(),r=n[t.id]||[];return Wh.jsx(see,{"data-role":t.role,"data-has-message-buttons":SL(!!r.length),...e})},cee=qB("div",{_id:"aiChatMessageContent"}),uee=e=>{const{message:t}=lB();return Wh.jsx(cee,{"data-role":t.role,...e})},dee=qB("div",{_id:"aiChatMessageAttachments"}),pee=qB("div",{_id:"aiChatMessageAttachments__List"}),hee=e=>{var t,n;const{children:r,...a}=e,{message:o}=lB(),i=null==(n=null==(t=o.metadata)?void 0:t.attributes)?void 0:n.attachments;return i?Wh.jsx(pee,{children:CL(r,i),...a}):null},fee=qB("div",{_id:"aiChatMessageAttachments__Item"}),mee=e=>{const{attachment:t,onClick:n,...r}=e,{selectItem:a,onOpen:o}=oB();return Wh.jsx(Kh,{attachment:t,children:Wh.jsx(fee,{onClick:L9(n,(()=>{a(t),o()})),...r})})},gee=qB(MY,{_id:"aiChatMessageAttachments__ItemIcon"}),yee=e=>{var t;const{attachment:n}=Xh(),r=null==(t=n.contentType)?void 0:t.attachmentIcon;return r?Wh.jsx(gee,{iconSettings:r,...e}):null},bee=qB("span",{_id:"aiChatMessageAttachments__ItemTitle"}),vee=e=>{const{attachment:t}=Xh();return Wh.jsx(bee,{children:t.title,...e})},kee=qB(lW,{_id:"aiChatMessageAttachmentsPreview"}),wee=qB(uW,{_id:"aiChatMessageAttachmentsPreview__Overlay"}),xee=qB(dW,{_id:"aiChatMessageAttachmentsPreview__Content","aria-describedby":void 0}),Eee=qB(pW,{_id:"aiChatMessageAttachmentsPreview__Header"}),_ee=e=>{const{selectedItem:t}=oB();return Wh.jsx(Eee,{children:(null==t?void 0:t.title)||"Attachment",...e})},See=qB(hW,{_id:"aiChatMessageAttachmentsPreview__Close",children:Wh.jsx(jY,{iconKey:"close"})}),Tee=qB("p",{_id:"aiChatMessageAttachmentsPreview__Body"}),Cee=e=>{const{selectedItem:t}=oB();return Wh.jsx(Tee,{children:null==t?void 0:t.content,...e})},Aee=qB("div",{_id:"aiChatMessage"}),Nee=e=>{const{aiChatSettings:t}=nP(),{componentStyles:n,...r}=e,{message:a}=lB(),{logEvent:o}=wP(),i=AL(a),{conversation:s}=iP();return"user"===a.role?Wh.jsx(Aee,{"data-role":a.role,children:i,...r}):Wh.jsx(Aee,{"data-role":a.role,...r,children:Wh.jsx(N9,{children:i,componentStyles:n,shouldOpenLinksInNewTab:t.shouldOpenLinksInNewTab,onLinkClick:(e,t)=>{o({eventName:"assistant_message_inline_link_opened",properties:{title:null==t?void 0:t.toString(),url:e}})},onCodeCopy:(e,t)=>{o({eventName:"assistant_code_block_copied",properties:{conversation:s,language:e,code:t}})}})})},Iee=qB("div",{_id:"aiChatMessageToolbar"}),Ree=e=>{var t;const{isLoading:n,messages:r}=$j(),{message:a}=lB();return(null==(t=r.at(-1))?void 0:t.id)===(null==a?void 0:a.id)&&n||"user"===a.role?null:Wh.jsx(Iee,{...e})},Oee=qB("div",{_id:"aiChatMessageToolActions"}),Pee=e=>{const{children:t,...n}=e,{message:r}=lB(),{messageButtons:a}=$j(),o=a[r.id]||[];return Wh.jsx(Oee,{children:CL(t,o),...n})},Dee=qB("a",{_id:"aiChatMessageToolAction"}),Lee=qB("button",{_id:"aiChatMessageToolAction"}),Mee=e=>{const{onClick:t,action:n,...r}=e,{handleAction:a}=P9(n),{logEvent:o}=wP(),{conversation:i}=iP(),s=()=>{a(),o({eventName:"user_escalation_indicated",properties:{escalationType:"contact_us",conversation:i}})},l=n.label||"Contact Support",c=Wh.jsxs(Wh.Fragment,{children:[n.icon&&Wh.jsx(MY,{iconSettings:n.icon}),l]});return"open_link"===n.action.type?Wh.jsx(Dee,{href:n.action.url,target:"_blank",rel:"noopener","data-type":n.action.type,onClick:L9(t,s),children:c,...r}):Wh.jsx(Lee,{"data-type":n.action.type,onClick:L9(t,s),children:c,...r})},Fee=qB("button",{_id:"aiChatMessageAction"}),jee=e=>{var t,n,r;const{action:a,onClick:o,className:i,...s}=e,{conversation:l}=iP(),{message:c}=lB(),{isStreaming:u,messages:d}=$j(),[p,h]=a9(),{feedback:f,submitPositiveFeedback:m,setCurrentFeedback:g,currentFeedback:y}=PL(),{logEvent:b}=wP(),[v,k]=function(){const[e,t]=K.useState(!1);return[e,K.useCallback((async()=>(t(!0),setTimeout((()=>{t(!1)}),1e3),!0)),[])]}(),{baseSettings:{privacyPreferences:w}}=nP(),{optOutAllAnalytics:x}=w,E=(null==(t=d.at(-1))?void 0:t.id)===(null==c?void 0:c.id),_="assistant"===c.role;if(E&&u||!_||{copy:!1,upvote:x,downvote:x}[a])return null;const S={copy(){h(AL(c)),b({eventName:"assistant_message_copied",properties:{conversation:l}})},upvote(){m(c.id).then((()=>{k()}))},downvote(){g(c.id)}},T={copy:Wh.jsx(jY,{iconKey:p?"messageCopied":"messageCopy"}),upvote:Wh.jsx(jY,{iconKey:v?"messageCopied":"thumbsUp"}),downvote:Wh.jsx(jY,{iconKey:"thumbsDown"})},C={copy:{"data-copied":SL(p)},upvote:{"data-upvoted":SL("positive"===(null==(n=f[c.id])?void 0:n.type))},downvote:{"data-downvoted":SL("negative"===(null==(r=f[c.id])?void 0:r.type)),"data-state":null===y?"closed":"open"}};return Wh.jsx(Fee,{"data-action":a,...C[a],children:T[a],"aria-label":{copy:"Copy Message",upvote:"Upvote Message",downvote:"Downvote Message"}[a],className:`${i} ${a}`,onClick:L9(o,S[a]),...s})},Bee=qB("div",{_id:"aiChatMessageSources"}),zee=qB("div",{_id:"aiChatMessageSources__Header"}),Hee=e=>Wh.jsx(zee,{children:"Sources",...e}),Uee=qB("div",{_id:"aiChatMessageSources__List"}),$ee=e=>{const{message:t}=lB(),{children:n,...r}=e,{baseSettings:{transformSource:a,organizationDisplayName:o},aiChatSettings:{shouldOpenLinksInNewTab:i},searchSettings:{tabs:s}}=nP();if("assistant"!==t.role)return null;const l=t.links.map((e=>{const t=X9(e,"chatSourceItem",{organizationDisplayName:o,tabs:s,transformSource:a}),n=void 0!==t.shouldOpenInNewTab?t.shouldOpenInNewTab:i;return{...t,isExternal:n}}));return Wh.jsx(Uee,{children:CL(n,l),...r})},Gee=qB(zY,{_id:"aiChatMessageSourceItem"}),Vee=e=>{var t;const{source:n,onClick:r,...a}=e,{logEvent:o}=wP(),{conversation:i}=iP();return Wh.jsx(NB,{source:n,children:Wh.jsx(Gee,{"data-type":n.type,appendToUrl:n.appendToUrl,isExternal:n.isExternal,"data-breadcrumbs":!!(null==(t=n.breadcrumbs)?void 0:t.length),onClick:L9(r,(()=>{o({eventName:"assistant_source_item_clicked",properties:{conversation:i,link:n}})})),...a})})},qee=qB("div",{_id:"aiChatMessageSourceItem__Breadcrumbs"}),Wee=e=>{var t;const{source:n}=IB();return(null==(t=n.breadcrumbs)?void 0:t.length)?Wh.jsx(qee,{"data-type":n.type,...e}):null},Yee=qB(jY,{_id:"aiChatMessageSourceItem__BreadcrumbIcon",iconKey:"breadcrumbSeparator"}),Kee=qB(MY,{_id:"aiChatMessageSourceItem__Icon"}),Xee=e=>{const{source:t}=IB();return Wh.jsx(Kee,{iconSettings:t.icon,"data-type":t.type,...e})},Qee=qB("span",{_id:"aiChatMessageSourceItem__Title"}),Zee=e=>{const{source:t}=IB();return Wh.jsx(Qee,{"data-type":t.type,children:t.title,...e})},Jee=qB("span",{_id:"aiChatMessageSourceItem__Tag"}),ete=e=>{const{source:t}=IB();return Wh.jsx(Jee,{"data-type":t.type,...e})},tte=qB("span",{_id:"aiChatMessageSourceItem__Description"}),nte=e=>{const{source:t}=IB(),{children:n,...r}=e,a=K.useMemo((()=>t.description?D9(t.description):[]),[t.description]);return a.length?Wh.jsx(tte,{"data-type":t.type,children:CL(n,a),...r}):null},rte=qB("span",{_id:"aiChatMessageSourceItem__DescriptionPart"}),ate=e=>{const{part:t,...n}=e,{source:r}=IB();return"string"==typeof t?t:Wh.jsx(rte,{"data-type":r.type,children:t.content,"data-highlighted":SL(t.highlighted),...n})},ote=qB(jY,{_id:"aiChatMessageSourceItem__Indicator"}),ite=e=>{const{source:t}=IB();return Wh.jsx(ote,{iconKey:t.isExternal?"openLinkInNewTab":"openLinkInSameTab",...e})},ste=qB("div",{_id:"aiChatFooter"}),lte=qB("div",{_id:"aiChatInput__Fieldset"}),cte=qB("div",{_id:"aiChatInput__Group"}),ute=qB("textarea",{_id:"aiChatInput"}),dte=K.forwardRef((({onChange:e,onKeyDown:t,...n},r)=>{const{handleInputChange:a,handleInputKeyDown:o,input:i,error:s,shouldAutoFocusInput:l,inputRef:c}=$j(),{aiChatSettings:u}=nP(),d=BB(r,c);return e7("chat",c,l),Wh.jsx(ute,{asChild:!0,ref:d,maxLength:99999,placeholder:u.placeholder,value:i,onChange:L9(e,a),onKeyDown:L9(t,o),disabled:!!s||u.isViewOnly,...n,children:Wh.jsx(lz,{})})})),pte=qB("button",{_id:"aiChatInput__SendButton"}),hte=e=>{const{handleSubmit:t,isSubmitDisabled:n,error:r}=$j(),{aiChatSettings:a}=nP(),{onClick:o,...i}=e;return Wh.jsx(pte,{onClick:L9(o,(()=>t())),"aria-label":"Send message",disabled:n||!!r||a.isViewOnly,...i})},fte=qB(jY,{_id:"aiChatInput__SendButtonIcon",iconKey:"chatSubmit"}),mte=qB("div",{_id:"aiChatAttachmentsBar"}),gte=e=>{var t;const{selectedWorkflow:n}=$j();return n&&(null==(t=n.supportedInputs)?void 0:t.length)?Wh.jsx(Vj,{children:Wh.jsx(mte,{...e})}):null},yte=qB("div",{_id:"aiChatAttachmentsBar__List"}),bte=e=>{const{children:t,...n}=e,{messageAttachments:r}=$j();return Wh.jsx(yte,{children:CL(t,r),...n})},vte=qB("div",{_id:"aiChatAttachmentsBar__Attachment"}),kte=e=>{const{attachment:t,...n}=e;return Wh.jsx(Kh,{attachment:t,children:Wh.jsx(vte,{...n})})},wte=qB(MY,{_id:"aiChatAttachmentsBar__AttachmentIcon"}),xte=e=>{var t;const{attachment:n}=Xh(),r=null==(t=n.contentType)?void 0:t.attachmentIcon;return r?Wh.jsx(wte,{iconSettings:r,...e}):null},Ete=qB("span",{_id:"aiChatAttachmentsBar__AttachmentTitle"}),_te=e=>{const{attachment:t}=Xh();return Wh.jsx(Ete,{children:t.title,...e})},Ste=qB("button",{_id:"aiChatAttachmentsBar__AttachmentDelete"}),Tte=e=>{const{onClick:t,...n}=e,{attachment:r}=Xh(),{setMessageAttachments:a}=$j();return Wh.jsx(Ste,{"aria-label":"Remove attachment",children:Wh.jsx(jY,{iconKey:"close"}),onClick:L9(t,(()=>{a((e=>e.filter((e=>e.id!==r.id))))})),...n})},Cte=qB("div",{_id:"aiChatAttachmentsBar__Actions"}),Ate=qB(_j,{_id:"aiChatAttachmentsBar__InfoTip",delayDuration:0}),Nte=qB(jj,{_id:"aiChatAttachmentsBar__InfoTipIcon",children:Wh.jsx(jY,{iconKey:"info"})}),Ite=qB(zj,{_id:"aiChatAttachmentsBar__InfoTipArrow"}),Rte=qB(Bj,{_id:"aiChatAttachmentsBar__InfoTipText",side:"bottom",sideOffset:3,align:"center",children:Wh.jsxs(Wh.Fragment,{children:[Wh.jsx(Ite,{}),"Attachments will be kept in context for the entire conversation."]})}),Ote=qB("div",{_id:"aiChatAttachmentsBar__Inputs"}),Pte=e=>{const{children:t,...n}=e,{selectedWorkflow:r}=$j();return(null==r?void 0:r.supportedInputs)?Wh.jsx(Ote,{children:CL(t,r.supportedInputs),...n}):null},Dte=qB("button",{_id:"aiChatAttachmentsBar__Input"}),Lte=e=>{const{input:t,onClick:n,...r}=e,{selectedWorkflow:a,messageAttachments:o,setMessageAttachments:i}=$j(),{selectInput:s,onOpen:l}=qj();return Wh.jsx(Dte,{children:t.displayName,onClick:L9(n,(()=>{if("FUNCTIONAL_MULTI_ATTACHMENT"===t.type){if(!a)return;return t.onInvoke(a,t,i,[...o])}s(t),l()})),...r})},Mte=qB(lW,{_id:"aiChatAttachmentsBar__Modal"}),Fte=qB(uW,{_id:"aiChatAttachmentsBar__ModalOverlay"}),jte=qB(dW,{_id:"aiChatAttachmentsBar__ModalContent","aria-describedby":void 0}),Bte=qB("div",{_id:"aiChatAttachmentsBar__ModalHeader"}),zte=qB(pW,{_id:"aiChatAttachmentsBar__ModalHeading"}),Hte=e=>{const{selectedInput:t}=qj(),n=`Add ${null==t?void 0:t.displayName}`;return Wh.jsx(zte,{children:n,...e})},Ute=qB("span",{_id:"aiChatAttachmentsBar__ModalDescription"}),$te=e=>{var t;const{selectedInput:n}=qj(),r=null==(t=null==n?void 0:n.workflowModalProps)?void 0:t.modalHelpText;return r?Wh.jsx(Ute,{children:r,...e}):null},Gte=qB("div",{_id:"aiChatAttachmentsBar__ModalHelp"}),Vte=qB(hW,{_id:"aiChatAttachmentsBar__ModalClose",children:Wh.jsx(jY,{iconKey:"close"})}),qte=qB("div",{_id:"aiChatAttachmentsBar__ModalBody"}),Wte=qB("form",{_id:"aiChatAttachmentsBar__Form"}),Yte=e=>{const{onSubmit:t,...n}=e,{form:r}=qj();return Wh.jsx(Wte,{onSubmit:L9(t,r.onSubmit),...n})},Kte=qB("div",{_id:"aiChatAttachmentsBar__FormTitle",role:"group"}),Xte=qB("label",{_id:"aiChatAttachmentsBar__FormTitleLabel"}),Qte=e=>{const{form:t,selectedInput:n}=qj();return Wh.jsx(Xte,{htmlFor:`${null==n?void 0:n.id}-title`,children:t.labels.title,...e})},Zte=qB("input",{_id:"aiChatAttachmentsBar__FormTitleInput"}),Jte=e=>{const{onChange:t,...n}=e,{form:r,selectedInput:a}=qj();return Wh.jsx(Zte,{name:"title",value:r.data.title,id:`${null==a?void 0:a.id}-title`,"data-invalid":SL(!!r.errors.title),"aria-invalid":!!r.errors.title,onChange:L9(t,r.onChange),...n})},ene=qB("span",{_id:"aiChatAttachmentsBar__FormTitleError"}),tne=e=>{const{form:t}=qj();return t.errors.title?Wh.jsx(ene,{"aria-live":"polite",children:t.errors.title,...e}):null},nne=qB("div",{_id:"aiChatAttachmentsBar__FormTitle",role:"group"}),rne=qB("label",{_id:"aiChatAttachmentsBar__FormContentLabel"}),ane=e=>{const{form:t,selectedInput:n}=qj();return Wh.jsx(rne,{htmlFor:`${null==n?void 0:n.id}-content`,children:t.labels.content,...e})},one=qB("textarea",{_id:"aiChatAttachmentsBar__FormTitleInput"}),ine=e=>{const{onChange:t,...n}=e,{form:r,selectedInput:a}=qj();return Wh.jsx(one,{asChild:!0,rows:4,name:"content",value:r.data.content,id:`${null==a?void 0:a.id}-content`,"data-invalid":SL(!!r.errors.content),"aria-invalid":!!r.errors.content,onChange:L9(t,r.onChange),...n,children:Wh.jsx(lz,{maxRows:10})})},sne=qB("span",{_id:"aiChatAttachmentsBar__FormContentError"}),lne=e=>{const{form:t}=qj();return t.errors.content?Wh.jsx(sne,{"aria-live":"polite",children:t.errors.content,...e}):null},cne=qB("button",{_id:"aiChatAttachmentsBar__FormSubmitButton",children:"Upload",type:"submit"}),une=qB("div",{_id:"aiChatActionBar"}),dne=qB("div",{_id:"aiChat__ChatActions"}),pne=qB("div",{_id:"aiChatTagline__Container"}),hne=qB("span",{_id:"aiChatTagline__Text",children:"Powered by"}),fne=qB(O9,{_id:"aiChatTagline__Logo"}),mne=qB("a",{_id:"aiChatTagline__BrandName",children:"inkeep",href:"https://www.inkeep.com/",target:"_blank",rel:"noopener noreferrer"}),gne=qB(jj,{_id:"aiChat__ChatAction"}),yne=e=>{const{action:t,onClick:n,className:r,...a}=e,{clear:o,stop:i,isLoading:s,messages:l,selectedWorkflow:c}=$j(),{conversation:u}=iP(),{aiChatSettings:d,baseSettings:p}=nP(),{logEvent:h}=wP(),[f,m]=a9(),[g,y]=a9();if({help:!1,copy:0===l.length||!d.isCopyChatButtonVisible||s,share:0===l.length||!d.isShareButtonVisible||!u.id||!!c||s,clear:0===l.length||d.isViewOnly||s,stop:!s}[t])return null;const b={help:()=>{},copy:()=>{const e=l.map((e=>{var t,n;const r=`**${"assistant"===e.role?"AI Assistant":"User"}**`,a=AL(e),o=TP(null==(n=null==(t=e.metadata)?void 0:t.attributes)?void 0:n.attachments);return`${r}\n\n${a}${o?`\n\n**Attachments**\n\n${o}`:""}`})).join("\n\n---\n\n");m(e)},share:async()=>{const e={visibility:"public",tags:[],userProperties:{},messages:u.messages.map((e=>({...e,createdAt:void 0,updatedAt:void 0,id:Date.now().toString()+e.id,conversationId:void 0})))},{apiKey:t,analyticsApiBaseUrl:n}=p,r=await sP("",e,t,n);if(r){const e=`${d.shareChatUrlBasePath}?${rP}=${null==r?void 0:r.id}`;y(e),h({eventName:"chat_share_button_clicked",properties:{sharedConversationId:null==r?void 0:r.id,originalConversationId:u.id,sharedChatUrl:e,conversation:r}})}},clear:o,stop:i},v={copy:f,share:g};return Wh.jsx(_j,{delayDuration:0,open:v[t],children:Wh.jsx(gne,{"data-type":t,"data-copied":SL(f||g),className:`${r} ${t}`,children:Wh.jsx(vne,{action:t}),onClick:L9(n,b[t]),...a})})},bne=qB("span",{_id:"aiChat__ChatActionLabel"}),vne=e=>{const{action:t,...n}=e,{aiChatSettings:r}=nP(),a=r.toolbarButtonLabels??{},o={help:a.getHelp??"Get Help",copy:a.copyChat??"Copy",share:a.share??"Share",clear:a.clear??"Clear",stop:a.stop??"Stop"};return Wh.jsx(bne,{children:o[t],...n})},kne=qB(Ij,{_id:"aiChat__ChatActionFeeback"}),wne=e=>{const{action:t,children:n,...r}=e;return Wh.jsxs(kne,{sideOffset:5,...r,children:[Wh.jsx(zj,{}),n||{copy:"Copied!",share:"Link copied!"}[t]]})},xne=qB(YU,{_id:"aiChatHelpActions"}),Ene=qB(yne,{_id:"aiChatHelpAction",action:"help"}),_ne=qB("a",{_id:"aiChatHelpAction",target:"_blank",rel:"noreferrer"}),Sne=e=>{const{action:t,onClick:n,...r}=e,{handleAction:a,logHelpAction:o}=P9(t),i=t.action.type,s={"aria-label":t.name,"data-name":t.name,children:t.name,onClick:L9(n,(()=>{a(),o()})),...r};return"open_link"===i?Wh.jsx(_ne,{href:t.action.url,...s}):Wh.jsx(Ene,{...s})},Tne=qB(KU,{_id:"aiChatHelpActions__Trigger"}),Cne=K.memo((e=>{var t;const{aiChatSettings:n}=nP();return Wh.jsx(yne,{action:"help",...e,asChild:!0,children:Wh.jsx(Tne,{children:(null==(t=n.toolbarButtonLabels)?void 0:t.getHelp)??"Get Help"})})})),Ane=qB(XU,{_id:"aiChatHelpActions__Menu"}),Nne=e=>Wh.jsx(Ane,{side:"top",sideOffset:8,align:"center",alignOffset:-10,...e}),Ine=qB(QU,{_id:"aiChatHelpActions__MenuArrow"}),Rne=e=>{const{action:t,onClick:n,...r}=e,{handleAction:a,logHelpAction:o}=P9(t),{setOpen:i}=(()=>{const e=K.useContext(Jj);if(!e)throw new Error("useHelpMenu must be used within a HelpMenuProvider");return e})(),s=t.action.type,l=qB("open_link"===s?"a":"button",{_id:"aiChatHelpActions__MenuItem",children:t.name,"aria-label":t.name,"data-name":t.name,"data-type":t.action.type,..."open_link"===s&&{href:t.action.url,target:"_blank",rel:"noopener"},onClick:L9(n,(()=>{a({onOpenForm:()=>i(!1)}),o()}))});return Wh.jsx(l,{...r})},One=qB(MY,{_id:"aiChatHelpActions_MenuItemIcon"}),Pne=e=>{const{action:t,...n}=e;return t.icon?Wh.jsx(One,{iconSettings:t.icon,...n}):null},Dne=qB(lW,{_id:"aiChatFeedbackModal"}),Lne=qB(uW,{_id:"aiChatFeedbackModal__Overlay"}),Mne=qB(dW,{_id:"aiChatFeedbackModal__Content","aria-describedby":void 0}),Fne=qB(pW,{_id:"aiChatFeedbackModal__Header",children:"Help improve my answers!"}),jne=qB(hW,{_id:"aiChatFeedbackModal__Close",children:Wh.jsx(jY,{iconKey:"close"})}),Bne=qB("div",{_id:"aiChatFeedbackModal__Body"}),zne=qB("form",{_id:"aiChatFeedbackForm"}),Hne=e=>{const{onSubmit:t,...n}=e,{submitNegativeFeedback:r,currentFeedback:a,setCurrentFeedback:o}=PL();return Wh.jsx(zne,{onSubmit:L9(t,(e=>{e.preventDefault();const t=e.target,n=new FormData(t),i=Object.fromEntries(n.entries());a&&(r(a,i),o(null))})),...n})},Une=qB("div",{_id:"aiChatFeedbackItem"}),$ne=e=>{const{name:t,...n}=e;return Wh.jsx(Yj,{name:t,children:Wh.jsx(Une,{...n})})},Gne=qB(Pz,{_id:"aiChatFeedbackItem__Checkbox"}),Vne=e=>{const{name:t,focusItem:n}=Kj(),{onCheckedChange:r,...a}=e;return Wh.jsx(Gne,{id:`feedback-${t}`,name:t,onCheckedChange:L9(r,(e=>{var t;e&&(null==(t=null==n?void 0:n.current)||t.focus())})),...a})},qne=qB(Dz,{_id:"aiChatFeedbackItem__CheckboxIndicator",children:Wh.jsx(R9,{})}),Wne=qB("label",{_id:"aiChatFeedbackItem__Label"}),Yne=e=>{const{name:t}=Kj();return Wh.jsx(Wne,{htmlFor:`feedback-${t}`,children:{unrelated_response:"Didn't answer my question",inaccurate_statement:"Inaccurate statement",inaccurate_code_snippet:"Inaccurate code snippet",irrelevant_citations:"Irrelevant citations"}[t],...e})},Kne=qB("textarea",{_id:"aiChatFeedbackItem__Description",placeholder:"Please describe"}),Xne=e=>{const{name:t,focusItem:n}=Kj();return Wh.jsx(Kne,{ref:n,name:`${t}:description`,...e})},Qne=qB("button",{_id:"aiChatFeedbackForm__SubmitButton",children:"Submit",type:"submit"}),Zne=qB("div",{_id:"aiChatForm__Wrapper"}),Jne=e=>{const{form:t}=dL();return t?Wh.jsx(Zne,{...e}):null},ere=qB("form",{_id:"aiChatForm"}),tre=e=>{const{onSubmit:t,...n}=e,{handleSubmit:r,isSuccess:a}=dL();return a?null:Wh.jsx(ere,{onSubmit:L9(t,r),...n})},nre=qB("button",{_id:"aiChatForm__Close",children:Wh.jsx(jY,{iconKey:"close"})}),rre=e=>{const{onClick:t,...n}=e,{closeForm:r}=dL();return Wh.jsx(nre,{onClick:L9(t,r),...n})},are=qB("div",{_id:"aiChatForm__Header"}),ore=qB("h2",{_id:"aiChatForm__Heading"}),ire=e=>{const{form:t}=dL();return(null==t?void 0:t.heading)?Wh.jsx(ore,{children:t.heading,...e}):null},sre=qB(N9,{_id:"aiChatForm__Description"}),lre=e=>{const{form:t}=dL();return(null==t?void 0:t.description)?Wh.jsx(sre,{children:t.description,...e}):null},cre=qB("div",{_id:"aiChatForm__Content"}),ure=e=>{const{children:t,...n}=e,{fields:r=[]}=dL();return Wh.jsx(cre,{children:CL(t,r),...n})},dre=qB("div",{_id:"aiChatForm__Field"}),pre=e=>{const{field:t,autoFocus:n,...r}=e,{control:a,errors:o}=dL();return Wh.jsx(kD,{name:t.name,control:a,rules:{required:t.isRequired?`${t.label} is required.`:void 0},render:({field:e})=>{const a=void 0!==e.value||"file"===t.inputType;return Wh.jsx(Qj,{"data-invalid":SL(!!o[t.name]),field:t,fieldProps:e,autoFocus:n,children:a&&Wh.jsx(dre,{"data-input-type":t.inputType,"data-hidden":SL(t.isHidden),...r})})}})},hre=qB("label",{_id:"aiChatForm__FieldLabel"}),fre=e=>{const{field:t}=Zj();return Wh.jsx(hre,{"data-required":SL(t.isRequired),htmlFor:t.name,children:t.label,...e})},mre=qB("input",{_id:"aiChatForm__FieldText",type:"text"}),gre=e=>{const{field:t,error:n,fieldProps:{onChange:r,onBlur:a,...o},autoFocus:i}=Zj(),{onChange:s,onBlur:l,...c}=e;return Wh.jsx(mre,{id:t.name,autoFocus:i,placeholder:"placeholder"in t?t.placeholder:void 0,"data-invalid":SL(!!n),onChange:L9(s,r),onBlur:L9(l,a),...o,...c})},yre=qB(gre,{_id:"aiChatForm__FieldEmail",type:"email"}),bre=qB("input",{_id:"aiChatForm__FieldFile",type:"file",multiple:!0}),vre=e=>{const{field:t,error:n,fieldProps:{value:r,onChange:a,onBlur:o,...i},autoFocus:s}=Zj(),{onChange:l,onBlur:c,...u}=e;return Wh.jsx(bre,{id:t.name,autoFocus:s,"data-value":r,"data-invalid":SL(!!n),...u,...i,onChange:L9(l,(e=>{const t=e.target.files;a(t)})),onBlur:L9(c,o)})},kre=qB(gre,{_id:"aiChatForm__FieldTextArea",type:"textarea",asChild:!0,children:Wh.jsx(lz,{maxRows:8})}),wre=qB(Pz,{_id:"aiChatForm__FieldCheckbox"}),xre=e=>{const{field:t,error:n,fieldProps:r,autoFocus:a}=Zj(),{onCheckedChange:o,...i}=e;return Wh.jsx(wre,{id:t.name,name:t.name,autoFocus:a,"data-invalid":SL(!!n),checked:r.value,onCheckedChange:L9(o,r.onChange),...i})},Ere=qB(Dz,{_id:"aiChatForm__FieldCheckboxIndicator",children:Wh.jsx(R9,{})}),_re=qB(ZV,{_id:"aiChatForm__FieldSelect"}),Sre=qB(JV,{_id:"aiChatForm__FieldSelect__Trigger"}),Tre=qB(eq,{_id:"aiChatForm__FieldSelect__Value"}),Cre=qB(tq,{_id:"aiChatForm__FieldSelect__Icon",asChild:!0,children:Wh.jsx(MY,{iconSettings:{builtIn:"LuChevronDown"}})}),Are=qB(nq,{_id:"aiChatForm__FieldSelect__Content",position:"popper"}),Nre=qB(rq,{_id:"aiChatForm__FieldSelect__Viewport"}),Ire=qB(aq,{_id:"aiChatForm__FieldSelect__Item"}),Rre=qB(oq,{_id:"aiChatForm__FieldSelect__ItemText"}),Ore=qB(iq,{_id:"aiChatForm__FieldSelect__ItemIndicator",asChild:!0,children:Wh.jsx(MY,{iconSettings:{builtIn:"LuCheck"}})}),Pre=qB("span",{_id:"aiChatForm__FieldError"}),Dre=e=>{var t;const{error:n}=Zj();return n?Wh.jsx(Pre,{children:null==(t=n.message)?void 0:t.toString(),...e}):null},Lre=qB("span",{_id:"aiChatForm__Error"}),Mre=e=>{const{formError:t}=dL();return t?Wh.jsx(Lre,{children:t.message,...e}):null},Fre=qB("div",{_id:"aiChatForm__Footer"}),jre=qB("button",{_id:"aiChatForm__Cancel",children:"Cancel",type:"button"}),Bre=e=>{const{onClick:t,...n}=e,{closeForm:r}=dL();return Wh.jsx(jre,{onClick:L9(t,r),...n})},zre=qB("button",{_id:"aiChatForm__Submit",children:"Submit",type:"submit"}),Hre=e=>{const{onClick:t,...n}=e,{isSubmitting:r,form:a}=dL(),o=(null==a?void 0:a.buttons.submit.label)||"Submit";return Wh.jsx(zre,{disabled:r,...n,children:o})},Ure=qB("div",{_id:"aiChatForm__Success"}),$re=e=>{const{isSuccess:t}=dL();return t?Wh.jsx(Ure,{...e}):null},Gre=qB("h2",{_id:"aiChatForm__SuccessHeading"}),Vre=e=>{var t;const{form:n}=dL();return Wh.jsx(Gre,{children:null==(t=null==n?void 0:n.successView)?void 0:t.heading,...e})},qre=qB(N9,{_id:"aiChatForm__SuccessMessage"}),Wre=qB("button",{_id:"aiChatForm__SuccessButton"}),Yre=e=>{var t;const{onClick:n,...r}=e,{form:a,closeForm:o}=dL(),i=null==(t=null==a?void 0:a.successView)?void 0:t.doneButton;if(!i)return null;const s=i.icon&&Wh.jsx(MY,{iconSettings:i.icon}),l=i.label;return Wh.jsx(Wre,{onClick:L9(n,o),children:Wh.jsxs(Wh.Fragment,{children:[s,l]}),...r})},Kre=e=>{const{triggerSelector:t,onTriggerClick:n}=e;K.useEffect((()=>{const e=e=>{var r;const a=e.target;(null==(r=null==a?void 0:a.matches)?void 0:r.call(a,t))&&(null==n||n())};return document.addEventListener("click",e),()=>{document.removeEventListener("click",e)}}),[t,n])};var Xre=()=>{},Qre=e=>"object"==typeof e&&null!==e,Zre=e=>Qre(e)&&9===e.nodeType,Jre=e=>(e=>Qre(e)&&void 0!==e.nodeType)(e)&&11===e.nodeType&&"host"in e;function eae(e){return Zre(e)?e:(e=>Qre(e)&&e===e.window)(e)?e.document:(null==e?void 0:e.ownerDocument)??document}function tae(e){var t;return Jre(e)?tae(e.host):Zre(e)?e.defaultView??window:(e=>Qre(e)&&1===e.nodeType&&"string"==typeof e.nodeName)(e)?(null==(t=e.ownerDocument)?void 0:t.defaultView)??window:window}var nae=new WeakMap;function rae(e){let t;const n=globalThis.requestAnimationFrame((()=>{t=e()}));return()=>{globalThis.cancelAnimationFrame(n),null==t||t()}}var aae=e=>"function"==typeof e;Function.prototype.toString.call(Object);var oae=e=>e();function iae(e){if(!sae(e)||void 0===e)return e;const t=Reflect.ownKeys(e).filter((e=>"string"==typeof e)),n={};for(const r of t){const t=e[r];void 0!==t&&(n[r]=iae(t))}return n}var sae=e=>e&&"object"==typeof e&&e.constructor===Object;function lae(...e){1===e.length?e[0]:e[1],2!==e.length||e[0]}var cae=(e=>(e.NotStarted="Not Started",e.Started="Started",e.Stopped="Stopped",e))(cae||{}),uae="__init__";var dae,pae={props:({props:e})=>({...e,present:!!e.present}),initialState:({prop:e})=>e("present")?"mounted":"unmounted",refs:()=>({node:null,styles:null}),context:({bindable:e})=>({unmountAnimationName:e((()=>({defaultValue:null}))),prevAnimationName:e((()=>({defaultValue:null}))),present:e((()=>({defaultValue:!1}))),initial:e((()=>({sync:!0,defaultValue:!1})))}),exit:["clearInitial","cleanupNode"],watch({track:e,action:t,prop:n}){e([()=>n("present")],(()=>{t(["setInitial","syncPresence"])}))},on:{"NODE.SET":{actions:["setNode","setStyles"]}},states:{mounted:{on:{UNMOUNT:{target:"unmounted",actions:["clearPrevAnimationName","invokeOnExitComplete"]},"UNMOUNT.SUSPEND":{target:"unmountSuspended"}}},unmountSuspended:{effects:["trackAnimationEvents"],on:{MOUNT:{target:"mounted",actions:["setPrevAnimationName"]},UNMOUNT:{target:"unmounted",actions:["clearPrevAnimationName","invokeOnExitComplete"]}}},unmounted:{on:{MOUNT:{target:"mounted",actions:["setPrevAnimationName"]}}}},implementations:{actions:{setInitial:({context:e})=>{e.get("initial")||queueMicrotask((()=>{e.set("initial",!0)}))},clearInitial:({context:e})=>{e.set("initial",!1)},cleanupNode:({refs:e})=>{e.set("node",null),e.set("styles",null)},invokeOnExitComplete:({prop:e})=>{var t;null==(t=e("onExitComplete"))||t()},setNode:({refs:e,event:t})=>{e.set("node",t.node)},setStyles:({refs:e,event:t})=>{var n;e.set("styles",(n=t.node,nae.has(n)||nae.set(n,tae(n).getComputedStyle(n)),nae.get(n)))},syncPresence:({context:e,refs:t,send:n,prop:r})=>{const a=r("present");if(a)return n({type:"MOUNT",src:"presence.changed"});const o=t.get("node");if(!a&&"hidden"===(null==o?void 0:o.ownerDocument.visibilityState))return n({type:"UNMOUNT",src:"visibilitychange"});rae((()=>{var r,a;const o=hae(t.get("styles"));e.set("unmountAnimationName",o),"none"===o||o===e.get("prevAnimationName")||"none"===(null==(r=t.get("styles"))?void 0:r.display)||"0s"===(null==(a=t.get("styles"))?void 0:a.animationDuration)?n({type:"UNMOUNT",src:"presence.changed"}):n({type:"UNMOUNT.SUSPEND"})}))},setPrevAnimationName:({context:e,refs:t})=>{rae((()=>{e.set("prevAnimationName",hae(t.get("styles")))}))},clearPrevAnimationName:({context:e})=>{e.set("prevAnimationName",null)}},effects:{trackAnimationEvents:({context:e,refs:t,send:n})=>{const r=t.get("node");if(!r)return;const a=n=>{var a,o;((null==(o=null==(a=n.composedPath)?void 0:a.call(n))?void 0:o[0])??n.target)===r&&e.set("prevAnimationName",hae(t.get("styles")))},o=a=>{const o=hae(t.get("styles")),i=function(e){const t=function(e){var t,n,r;return(null==(t=e.composedPath)?void 0:t.call(e))??(null==(r=null==(n=e.nativeEvent)?void 0:n.composedPath)?void 0:r.call(n))}(e);return(null==t?void 0:t[0])??e.target}(a);i===r&&o===e.get("unmountAnimationName")&&n({type:"UNMOUNT",src:"animationend"})};r.addEventListener("animationstart",a),r.addEventListener("animationcancel",o),r.addEventListener("animationend",o);const i=function(e,t){if(!e)return Xre;const n=Object.keys(t).reduce(((t,n)=>(t[n]=e.style.getPropertyValue(n),t)),{});return Object.assign(e.style,t),()=>{Object.assign(e.style,n),0===e.style.length&&e.removeAttribute("style")}}(r,{animationFillMode:"forwards"});return()=>{r.removeEventListener("animationstart",a),r.removeEventListener("animationcancel",o),r.removeEventListener("animationend",o),function(e){const t=new Set;function n(e){const n=globalThis.requestAnimationFrame(e);t.add((()=>globalThis.cancelAnimationFrame(n)))}n((()=>n(e)))}((()=>i()))}}}}};function hae(e){return(null==e?void 0:e.animationName)||"none"}dae=["onExitComplete","present","immediate"],Array.from(new Set(dae));var fae=void 0!==globalThis.document?K.useLayoutEffect:K.useEffect;function mae(e){const t=e().value??e().defaultValue,n=e().isEqual??Object.is,[r]=K.useState(t),[a,o]=K.useState(r),i=void 0!==e().value,s=K.useRef(a);s.current=i?e().value:a;const l=K.useRef(s.current);fae((()=>{l.current=s.current}),[a,e().value]);return{initial:r,ref:s,get:function(){return i?e().value:a},set(t){(e().sync?se.flushSync:oae)((()=>(t=>{var r,a;const s=l.current,c=aae(t)?t(s):t;e().debug&&console.log(`[bindable > ${e().debug}] setValue`,{next:c,prev:s}),i||o(c),n(c,s)||null==(a=(r=e()).onChange)||a.call(r,c,s)})(t)))},invoke(t,n){var r,a;null==(a=(r=e()).onChange)||a.call(r,t,n)},hash(t){var n,r;return(null==(r=(n=e()).hash)?void 0:r.call(n,t))??String(t)}}}mae.cleanup=e=>{K.useEffect((()=>e),[])},mae.ref=e=>{const t=K.useRef(e);return{get:()=>t.current,set:e=>{t.current=e}}};var gae,yae=(e,t)=>{const n=K.useRef(!1),r=K.useRef(!1);K.useEffect((()=>{if(n.current&&r.current)return t();r.current=!0}),[...(e??[]).map((e=>"function"==typeof e?e():e))]),K.useEffect((()=>(n.current=!0,()=>{n.current=!1})),[])};function bae(e,t={}){var n,r,a,o;const i=K.useMemo((()=>{const{id:e,ids:n,getRootNode:r}=t;return function(e){const t=()=>{var t;return(null==(t=e.getRootNode)?void 0:t.call(e))??document},n=()=>eae(t()),r=()=>function(e){let t=e.activeElement;for(;null==t?void 0:t.shadowRoot;){const e=t.shadowRoot.activeElement;if(e===t)break;t=e}return t}(t());return{...e,getRootNode:t,getDoc:n,getWin:()=>n().defaultView??window,getActiveElement:r,isActiveElement:e=>e===r(),getById:e=>t().getElementById(e)}}({id:e,ids:n,getRootNode:r})}),[t]),s=(...t)=>{e.debug&&console.log(...t)},l=function(e){const t=vae(e);return function(e){return t.current[e]}}((null==(n=e.props)?void 0:n.call(e,{props:iae(t),scope:i}))??t),c=vae(null==(r=e.context)?void 0:r.call(e,{prop:l,bindable:mae,scope:i,flush:kae,getContext:()=>u,getComputed:()=>E,getRefs:()=>y})),u={get(e){var t;return null==(t=c.current)?void 0:t[e].ref.current},set(e,t){var n;null==(n=c.current)||n[e].set(t)},initial(e){var t;return null==(t=c.current)?void 0:t[e].initial},hash(e){var t,n;const r=null==(t=c.current)?void 0:t[e].get();return null==(n=c.current)?void 0:n[e].hash(r)}},d=K.useRef(new Map),p=K.useRef(null),h=K.useRef(null),f=K.useRef({type:""}),m=()=>({...f.current,current:()=>f.current,previous:()=>h.current}),g=()=>({..._,matches:(...e)=>e.includes(_.ref.current),hasTag(t){var n,r;return!!(null==(r=null==(n=e.states[_.ref.current])?void 0:n.tags)?void 0:r.includes(t))}}),y=function(e){const t=K.useRef(e);return{get:e=>t.current[e],set(e,n){t.current[e]=n}}}((null==(a=e.refs)?void 0:a.call(e,{prop:l,context:u}))??{}),b=()=>({state:g(),context:u,event:m(),prop:l,send:C,action:v,guard:k,track:yae,refs:y,computed:E,flush:kae,scope:i,choose:x}),v=t=>{const n=aae(t)?t(b()):t;if(!n)return;const r=n.map((t=>{var n,r;const a=null==(r=null==(n=e.implementations)?void 0:n.actions)?void 0:r[t];return a||lae(`[zag-js] No implementation found for action "${JSON.stringify(t)}"`),a}));for(const e of r)null==e||e(b())},k=t=>{var n,r;return aae(t)?t(b()):null==(r=null==(n=e.implementations)?void 0:n.guards)?void 0:r[t](b())},w=t=>{const n=aae(t)?t(b()):t;if(!n)return;const r=n.map((t=>{var n,r;const a=null==(r=null==(n=e.implementations)?void 0:n.effects)?void 0:r[t];return a||lae(`[zag-js] No implementation found for effect "${JSON.stringify(t)}"`),a})),a=[];for(const e of r){const t=null==e?void 0:e(b());t&&a.push(t)}return()=>a.forEach((e=>null==e?void 0:e()))},x=e=>{return(t=e,t?Array.isArray(t)?t:[t]:[]).find((e=>{let t=!e.guard;return(e=>"string"==typeof e)(e.guard)?t=!!k(e.guard):aae(e.guard)&&(t=e.guard(b())),t}));var t},E=t=>{!function(e,t){if(null==e)throw new Error(t())}(e.computed,(()=>"[zag-js] No computed object found on machine"));return(0,e.computed[t])({context:u,event:m(),prop:l,refs:y,scope:i,computed:E})},_=mae((()=>({defaultValue:e.initialState({prop:l}),onChange(t,n){var r,a,o,i;if(n){const e=d.current.get(n);null==e||e(),d.current.delete(n)}n&&v(null==(r=e.states[n])?void 0:r.exit),v(null==(a=p.current)?void 0:a.actions);const s=w(null==(o=e.states[t])?void 0:o.effects);if(s&&d.current.set(t,s),n===uae){v(e.entry);const t=w(e.effects);t&&d.current.set(uae,t)}v(null==(i=e.states[t])?void 0:i.entry)}}))),S=K.useRef(void 0),T=K.useRef(cae.NotStarted);fae((()=>{queueMicrotask((()=>{const e=T.current===cae.Started;T.current=cae.Started,s(e?"rehydrating...":"initializing...");const t=S.current??_.initial;_.invoke(t,e?_.get():uae)}));const t=d.current,n=_.ref.current;return()=>{s("unmounting..."),S.current=n,T.current=cae.Stopped,t.forEach((e=>null==e?void 0:e())),d.current=new Map,p.current=null,queueMicrotask((()=>{v(e.exit)}))}}),[]);const C=t=>{queueMicrotask((()=>{var n,r;if(T.current!==cae.Started)return;h.current=f.current,f.current=t,s("send",t);let a="ref"in _?_.ref.current:_.get();const o=(null==(n=e.states[a].on)?void 0:n[t.type])??(null==(r=e.on)?void 0:r[t.type]),i=x(o);if(!i)return;p.current=i;const l=i.target??a;s("transition",i);const c=l!==a;c?se.flushSync((()=>_.set(l))):i.reenter&&!c?_.invoke(a,a):v(i.actions??[])}))};return null==(o=e.watch)||o.call(e,b()),{state:g(),send:C,context:u,prop:l,scope:i,refs:y,computed:E,event:m(),getStatus:()=>T.current}}function vae(e){const t=K.useRef(e);return t.current=e,t}function kae(e){queueMicrotask((()=>{se.flushSync((()=>e()))}))}gae=e=>e,new Proxy({},{get:(e,t)=>"style"===t?e=>gae({style:e}).style:gae});const wae=K.forwardRef(((e,t)=>{const{unmountOnExit:n=!1,present:r,onExitComplete:a,children:o,...i}=e,s=function(e){const{state:t,send:n,context:r}=e,a=t.matches("mounted","unmountSuspended");return{skip:!r.get("initial"),present:a,setNode(e){e&&n({type:"NODE.SET",node:e})},unmount(){n({type:"UNMOUNT"})}}}(bae(pae,{present:r,onExitComplete:a}));return!s.present&&n?null:Wh.jsx("div",{hidden:!s.present,"data-state":s.skip?void 0:r?"open":"closed",ref:e=>{s.setNode(e),"function"==typeof t?t(e):t&&(t.current=e)},...i,children:o})}));const xae=qB(wae,{_id:"sidebarChat__Root"}),Eae=({triggerSelector:e})=>{const{isOpen:t,setOpen:n}=LB();return Kre({triggerSelector:e,onTriggerClick:()=>n(!t)}),null},_ae=["position","triggerSelector","minWidth","maxWidth","defaultWidth","defaultOpen","autoCloseThreshold","isOpen","onOpenChange"],Sae=K.forwardRef(((e,t)=>{const[n,r]=function(e,t){const n={},r={...e};for(const a of t)a in e&&(n[a]=e[a],delete r[a]);return[n,r]}(e,_ae),a=(({position:e="right",minWidth:t=250,maxWidth:n=600,defaultWidth:r=420,defaultOpen:a=!1,autoCloseThreshold:o=.7,isOpen:i,onOpenChange:s})=>{const[l,c]=K.useState(Math.min(r,Math.floor((t+n)/2))),[u=a,d]=OB({prop:i,defaultProp:i,onChange:s});return{width:l,setWidth:c,position:e,minWidth:t,maxWidth:n,autoCloseThreshold:o,setOpen:d,isOpen:u}})(n);return Wh.jsxs(DB,{value:a,children:[Wh.jsx(Eae,{triggerSelector:n.triggerSelector||"[data-inkeep-sidebar-chat-trigger]"}),Wh.jsx(xae,{ref:t,present:a.isOpen,"data-sidebar":"","data-position":a.position,"data-open":SL(a.isOpen),style:{"--width":`${a.width}px`},...r})]})})),Tae=qB("div",{_id:"sidebarChat__Resizer"}),Cae=K.forwardRef(((e,t)=>{const{position:n}=LB(),{onMouseDown:r,resizerRef:a}=(()=>{const{width:e,setWidth:t,position:n,minWidth:r,maxWidth:a,autoCloseThreshold:o,setOpen:i}=LB(),s=K.useRef(null),l=K.useRef(!1),c=K.useRef(0),u=K.useRef(0),d=r*o;K.useEffect((()=>{const e=e=>{if(!l.current)return;const o=e.clientX-c.current,s="right"===n?-o:o,p=u.current+s;if(p<d)return void i(!1);const h=Math.max(r,Math.min(a,p));t(h)},o=()=>{l.current=!1,document.body.style.cursor="",document.body.style.userSelect=""};return window.addEventListener("mousemove",e),window.addEventListener("mouseup",o),()=>{window.removeEventListener("mousemove",e),window.removeEventListener("mouseup",o)}}),[t,n,r,a,d,i]);const p=K.useCallback((t=>{l.current=!0,c.current=t.clientX,u.current=e,document.body.style.cursor="ew-resize",document.body.style.userSelect="none",t.preventDefault()}),[e]);return{onMouseDown:p,resizerRef:s}})();return Wh.jsx(Tae,{ref:e=>{"function"==typeof t?t(e):t&&(t.current=e),a.current=e},"data-position":n,onMouseDown:r,...e})})),Aae=qB("div",{_id:"sidebarChat__Header"}),Nae=K.forwardRef(((e,t)=>Wh.jsx(Aae,{ref:t,...e}))),Iae=qB("button",{_id:"sidebarChat__CloseButton",children:Wh.jsx(MY,{iconSettings:{builtIn:"IoCloseOutline"}})}),Rae=K.forwardRef(((e,t)=>{const{setOpen:n}=LB();return Wh.jsx(Iae,{ref:t,onClick:()=>{n(!1)},...e})}));var Oae=.999,Pae=/[\\\/_+.#"@\[\(\{&]/,Dae=/[\\\/_+.#"@\[\(\{&]/g,Lae=/[\s-]/,Mae=/[\s-]/g;function Fae(e,t,n,r,a,o,i){if(o===t.length)return a===e.length?1:.99;var s=`${a},${o}`;if(void 0!==i[s])return i[s];for(var l,c,u,d,p=r.charAt(o),h=n.indexOf(p,a),f=0;h>=0;)(l=Fae(e,t,n,r,h+1,o+1,i))>f&&(h===a?l*=1:Pae.test(e.charAt(h-1))?(l*=.8,(u=e.slice(a,h-1).match(Dae))&&a>0&&(l*=Math.pow(Oae,u.length))):Lae.test(e.charAt(h-1))?(l*=.9,(d=e.slice(a,h-1).match(Mae))&&a>0&&(l*=Math.pow(Oae,d.length))):(l*=.17,a>0&&(l*=Math.pow(Oae,h-a))),e.charAt(h)!==t.charAt(o)&&(l*=.9999)),(l<.1&&n.charAt(h-1)===r.charAt(o+1)||r.charAt(o+1)===r.charAt(o)&&n.charAt(h-1)!==r.charAt(o))&&.1*(c=Fae(e,t,n,r,h+1,o+2,i))>l&&(l=.1*c),l>f&&(f=l),h=n.indexOf(p,h+1);return i[s]=f,f}function jae(e){return e.toLowerCase().replace(Mae," ")}function Bae(e,t,n){return Fae(e=n&&n.length>0?""+(e+" "+n.join(" ")):e,t,jae(e),jae(t),0,0,{})}var zae={exports:{}},Hae={},Uae=K;var $ae="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},Gae=Uae.useState,Vae=Uae.useEffect,qae=Uae.useLayoutEffect,Wae=Uae.useDebugValue;function Yae(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!$ae(e,n)}catch(r){return!0}}var Kae="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var n=t(),r=Gae({inst:{value:n,getSnapshot:t}}),a=r[0].inst,o=r[1];return qae((function(){a.value=n,a.getSnapshot=t,Yae(a)&&o({inst:a})}),[e,n,t]),Vae((function(){return Yae(a)&&o({inst:a}),e((function(){Yae(a)&&o({inst:a})}))}),[e]),Wae(n),n};Hae.useSyncExternalStore=void 0!==Uae.useSyncExternalStore?Uae.useSyncExternalStore:Kae,zae.exports=Hae;var Xae=zae.exports;const Qae="__ask_ai__",Zae='[cmdk-group=""]',Jae='[cmdk-group-items=""]',eoe='[cmdk-item=""]',toe=`${eoe}:not([aria-disabled="true"])`,noe="cmdk-item-select",roe="data-value",aoe=(e,t,n)=>Bae(e,t,n??[]),ooe=K.createContext(void 0),ioe=()=>K.useContext(ooe),soe=K.createContext(void 0),loe=()=>K.useContext(soe),coe=K.createContext(void 0),uoe=K.forwardRef(((e,t)=>{const n=_oe((()=>new Set)),r=_oe((()=>new Map)),a=_oe((()=>new Map)),o=_oe((()=>new Set)),i=xoe(e),{label:s,children:l,value:c,onValueChange:u,filter:d,shouldFilter:p,loop:h,disablePointerSelection:f=!1,vimBindings:m=!0,defaultSearch:g,...y}=e,b=_oe((()=>({search:g??"",value:e.value??e.defaultValue??"",selectedItemId:void 0,filtered:{count:0,items:new Map,groups:new Set}}))),v=zO(),k=zO(),w=zO(),x=K.useRef(null),E=Aoe();Eoe((()=>{if(void 0!==c){const e=c.trim();b.current.value=e,S.emit()}}),[c]),Eoe((()=>{E(6,R)}),[]);const _=UO(),S=K.useMemo((()=>({subscribe:e=>(o.current.add(e),()=>o.current.delete(e)),snapshot:()=>b.current,setState:(e,t,n)=>{var r,a,o,s,l;if(!Object.is(b.current[e],t)){if(b.current[e]=t,"search"===e)I(),A(),E(1,N);else if("value"===e){const e=null==(a=null==(r=null==_?void 0:_.shadowHost)?void 0:r.shadowRoot)?void 0:a.activeElement;if((null==e?void 0:e.hasAttribute("cmdk-input"))||E(1,(()=>{const e=O();null==e||e.focus()})),E(7,(()=>{var e;b.current.selectedItemId=null==(e=O())?void 0:e.id,S.emit()})),n||E(5,R),void 0!==(null==(o=i.current)?void 0:o.value)){const e=t??"";return void(null==(l=(s=i.current).onValueChange)||l.call(s,e))}}S.emit()}},emit:()=>{o.current.forEach((e=>e()))}})),[]),T=K.useMemo((()=>({value:(e,t,n)=>{var r;t!==(null==(r=a.current.get(e))?void 0:r.value)&&(a.current.set(e,{value:t,keywords:n}),b.current.filtered.items.set(e,C(t,n)),E(2,(()=>{A(),S.emit()})))},item:(e,t)=>{var o,i;return n.current.add(e),t&&(r.current.has(t)?null==(i=null==(o=r.current)?void 0:o.get(t))||i.add(e):r.current.set(t,new Set([e]))),E(3,(()=>{I(),A(),b.current.value||N(),S.emit()})),()=>{a.current.delete(e),n.current.delete(e),b.current.filtered.items.delete(e);const t=O();E(4,(()=>{I(),(null==t?void 0:t.getAttribute("id"))===e&&N(),S.emit()}))}},group:e=>(r.current.has(e)||r.current.set(e,new Set),()=>{a.current.delete(e),r.current.delete(e)}),filter:()=>!!i.current.shouldFilter,label:s||e["aria-label"]||"",getDisablePointerSelection:()=>!!i.current.disablePointerSelection,listId:v,inputId:w,labelId:k,listInnerRef:x})),[]);function C(e,t){var n;const r=(null==(n=i.current)?void 0:n.filter)??aoe;return e?null==r?void 0:r(e,b.current.search,t):0}function A(){if(!b.current.search||!1===i.current.shouldFilter)return;const e=b.current.filtered.items,t=[];b.current.filtered.groups.forEach((n=>{const a=r.current.get(n);let o=0;a.forEach((t=>{const n=e.get(t);o=Math.max(n,o)})),t.push([n,o])}));const n=x.current;P().sort(((t,n)=>{const r=t.getAttribute("id"),a=n.getAttribute("id");return(e.get(a)??0)-(e.get(r)??0)})).forEach((e=>{const t=e.closest(Jae);if(t){const n=e.parentElement===t?e:e.closest(`${Jae} > *`);n&&t.appendChild(n)}else{const t=e.parentElement===n?e:e.closest(`${Jae} > *`);t&&(null==n||n.appendChild(t))}})),t.sort(((e,t)=>t[1]-e[1])).forEach((e=>{var t,n;const r=null==(t=x.current)?void 0:t.querySelector(`${Zae}[${roe}="${encodeURIComponent(e[0])}"]`);null==(n=null==r?void 0:r.parentElement)||n.appendChild(r)}))}function N(){const e=P().find((e=>"true"!==e.getAttribute("aria-disabled")&&e.getAttribute("data-value")!==Qae)),t=null==e?void 0:e.getAttribute(roe);S.setState("value",t||void 0)}function I(){var e,t;if(!b.current.search||!1===i.current.shouldFilter)return void(b.current.filtered.count=n.current.size);b.current.filtered.groups=new Set;let o=0;for(const r of n.current){const n=C((null==(e=a.current.get(r))?void 0:e.value)??"",(null==(t=a.current.get(r))?void 0:t.keywords)??[]);b.current.filtered.items.set(r,n),n>0&&o++}for(const[n,a]of r.current)for(const e of a){const t=b.current.filtered.items.get(e);if(t&&t>0){b.current.filtered.groups.add(n);break}}b.current.filtered.count=o}function R(){var e,t,n;const r=O();r&&((null==(e=r.parentElement)?void 0:e.firstChild)===r&&(null==(n=null==(t=r.closest(Zae))?void 0:t.querySelector('[cmdk-group-heading=""]'))||n.scrollIntoView({block:"nearest"})),r.scrollIntoView({block:"nearest"}))}function O(){var e;return null==(e=x.current)?void 0:e.querySelector(`${eoe}[aria-selected="true"]`)}function P(){var e;return Array.from((null==(e=x.current)?void 0:e.querySelectorAll(toe))||[])}function D(e){const t=P()[e];t&&S.setState("value",t.getAttribute(roe))}function L(e){var t;const n=O(),r=P(),a=r.findIndex((e=>e===n));let o=r[a+e];(null==(t=i.current)?void 0:t.loop)&&(o=a+e<0?r[r.length-1]:a+e===r.length?r[0]:r[a+e]),o&&S.setState("value",o.getAttribute(roe))}function M(e){const t=O();let n,r=null==t?void 0:t.closest(Zae);for(;r&&!n;)r=e>0?koe(r,Zae):woe(r,Zae),n=null==r?void 0:r.querySelector(toe);n?S.setState("value",n.getAttribute(roe)):L(e)}const F=e=>{e.preventDefault(),e.metaKey?D(P().length-1):e.altKey?M(1):L(1)},j=e=>{e.preventDefault(),e.metaKey?D(0):e.altKey?M(-1):L(-1)},B=fL();return Wh.jsxs(eG.div,{ref:t,tabIndex:-1,...y,"cmdk-root":"",onKeyDown:e=>{var t;if("search"===(null==B?void 0:B.view)&&(null==(t=y.onKeyDown)||t.call(y,e),!e.defaultPrevented))switch(e.key){case"n":case"j":m&&e.ctrlKey&&F(e);break;case"ArrowDown":F(e);break;case"p":case"k":m&&e.ctrlKey&&j(e);break;case"ArrowUp":j(e);break;case"Enter":if(!e.nativeEvent.isComposing&&229!==e.keyCode){e.preventDefault();const t=O();if(t){const e=new Event(noe);t.dispatchEvent(e)}}}},style:{display:"contents"},children:[Wh.jsx("label",{"cmdk-label":"",htmlFor:T.inputId,id:T.labelId,style:Ioe,children:s}),Noe(e,(e=>Wh.jsx(soe.Provider,{value:S,children:Wh.jsx(ooe.Provider,{value:T,children:e})})))]})})),doe=K.forwardRef(((e,t)=>{var n;const{id:r}=e,a=K.useRef(null),o=K.useContext(coe),i=ioe(),s=xoe(e),l=(null==(n=s.current)?void 0:n.forceMount)??(null==o?void 0:o.forceMount);Eoe((()=>{if(!l)return i.item(r,null==o?void 0:o.id)}),[l]);const c=Coe(r,a,[e.value,e.children,a],e.keywords),u=loe(),d=Toe((e=>e.value&&e.value===c.current)),p=Toe((e=>!!l||(!1===i.filter()||(!e.search||e.filtered.items.get(r)>0))));K.useEffect((()=>{const t=a.current;if(!t||e.disabled)return;const n=()=>f("keyboard");return t.addEventListener(noe,n),()=>t.removeEventListener(noe,n)}),[p,e.onSelect,e.disabled]);const h=K.useCallback((()=>{u.setState("value",c.current,!0)}),[u,c]),f=K.useCallback(((e="click")=>{var t,n;h(),null==(n=(t=s.current).onSelect)||n.call(t,{value:c.current,trigger:e})}),[h,s,c]);if(!p)return null;const{disabled:m,value:g,onSelect:y,forceMount:b,keywords:v,onClick:k,...w}=e,x=K.useMemo((()=>Soe([a,t])),[a,t]),E=L9(k,f);return Wh.jsx(eG.div,{ref:x,...w,id:r,"cmdk-item":"",role:"option","aria-disabled":Boolean(m),"aria-selected":Boolean(d),"data-disabled":Boolean(m),"data-selected":Boolean(d),onPointerMove:m||i.getDisablePointerSelection()?void 0:h,onClick:m?void 0:E,onFocus:m?void 0:h,children:e.children})})),poe=K.forwardRef(((e,t)=>{const{heading:n,children:r,forceMount:a,...o}=e,i=zO(),s=K.useRef(null),l=K.useRef(null),c=zO(),u=ioe(),d=Toe((e=>!!a||(!1===u.filter()||(!e.search||e.filtered.groups.has(i)))));Eoe((()=>u.group(i)),[]),Coe(i,s,[e.value,e.heading,l]);const p=K.useMemo((()=>({id:i,forceMount:a})),[a]);return Wh.jsxs(eG.div,{ref:Soe([s,t]),...o,"cmdk-group":"",role:"presentation",hidden:!d||void 0,children:[n&&Wh.jsx("div",{ref:l,"cmdk-group-heading":"","aria-hidden":!0,id:c,children:n}),Noe(e,(e=>Wh.jsx("div",{"cmdk-group-items":"",role:"group","aria-labelledby":n?c:void 0,children:Wh.jsx(coe.Provider,{value:p,children:e})})))]})})),hoe=K.forwardRef(((e,t)=>{const{alwaysRender:n,...r}=e,a=K.useRef(null),o=Toe((e=>!e.search));return n||o?Wh.jsx(eG.div,{ref:Soe([a,t]),...r,"cmdk-separator":"",role:"separator"}):null})),foe=K.forwardRef(((e,t)=>{const{onValueChange:n,...r}=e,a=null!=e.value,o=loe(),i=Toe((e=>e.search)),s=ioe();return K.useEffect((()=>{null!=e.value&&o.setState("search",e.value)}),[e.value]),Wh.jsx(eG.input,{ref:t,...r,"cmdk-input":"",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list",role:"combobox","aria-expanded":!0,"aria-controls":s.listId,"aria-labelledby":s.labelId,id:s.inputId,type:"text",value:a?e.value:i,onChange:e=>{a||o.setState("search",e.target.value),null==n||n(e.target.value)}})})),moe=K.forwardRef(((e,t)=>{const{children:n,label:r="Suggestions",...a}=e,o=K.useRef(null),i=K.useRef(null),s=ioe();return K.useEffect((()=>{if(i.current&&o.current){const e=i.current,t=o.current;let n;const r=new ResizeObserver((()=>{n=requestAnimationFrame((()=>{const n=e.offsetHeight;t.style.setProperty("--cmdk-list-height",n.toFixed(1)+"px")}))}));return r.observe(e),()=>{cancelAnimationFrame(n),r.unobserve(e)}}}),[]),Wh.jsx(eG.div,{ref:Soe([o,t]),...a,"cmdk-list":"",tabIndex:-1,"aria-label":r,id:s.listId,children:Noe(e,(e=>Wh.jsx("div",{ref:Soe([i,s.listInnerRef]),"cmdk-list-sizer":"",children:e})))})})),goe=K.forwardRef(((e,t)=>{const{open:n,onOpenChange:r,overlayClassName:a,contentClassName:o,container:i,...s}=e;return Wh.jsx(lW,{open:n,onOpenChange:r,children:Wh.jsxs(cW,{container:i,children:[Wh.jsx(uW,{"cmdk-overlay":"",className:a}),Wh.jsx(dW,{"aria-label":e.label,"cmdk-dialog":"",className:o,children:Wh.jsx(uoe,{ref:t,...s})})]})})})),yoe=K.forwardRef(((e,t)=>Toe((e=>0===e.filtered.count))?Wh.jsx(eG.div,{ref:t,...e,"cmdk-empty":"",role:"presentation"}):null)),boe=K.forwardRef(((e,t)=>{const{progress:n,children:r,label:a="Loading...",...o}=e;return Wh.jsx(eG.div,{ref:t,...o,"cmdk-loading":"",role:"progressbar","aria-valuenow":n,"aria-valuemin":0,"aria-valuemax":100,"aria-label":a,children:Noe(e,(e=>Wh.jsx("div",{"aria-hidden":!0,children:e})))})})),voe=Object.assign(uoe,{List:moe,Item:doe,Input:foe,Group:poe,Separator:hoe,Dialog:goe,Empty:yoe,Loading:boe});function koe(e,t){let n=e.nextElementSibling;for(;n;){if(n.matches(t))return n;n=n.nextElementSibling}}function woe(e,t){let n=e.previousElementSibling;for(;n;){if(n.matches(t))return n;n=n.previousElementSibling}}function xoe(e){const t=K.useRef(e);return Eoe((()=>{t.current=e})),t}const Eoe="undefined"==typeof window?K.useEffect:K.useLayoutEffect;function _oe(e){const t=K.useRef(void 0);return void 0===t.current&&(t.current=e()),t}function Soe(e){return t=>{e.forEach((e=>{"function"==typeof e?e(t):null!=e&&(e.current=t)}))}}function Toe(e){const t=loe(),n=()=>e(t.snapshot());return Xae.useSyncExternalStore(t.subscribe,n,n)}function Coe(e,t,n,r=[]){const a=K.useRef(void 0),o=ioe();return Eoe((()=>{var i;const s=(()=>{var e;for(const t of n){if("string"==typeof t)return t.trim();if("object"==typeof t&&"current"in t)return t.current?null==(e=t.current.textContent)?void 0:e.trim():a.current}})(),l=r.map((e=>e.trim()));o.value(e,s,l),null==(i=t.current)||i.setAttribute(roe,s),a.current=s})),a}const Aoe=()=>{const[e,t]=K.useState(),n=_oe((()=>new Map));return Eoe((()=>{n.current.forEach((e=>e())),n.current=new Map}),[e]),(e,r)=>{n.current.set(e,r),t({})}};function Noe({asChild:e,children:t},n){return e&&K.isValidElement(t)?K.cloneElement(function(e){const t=e.type;return"function"==typeof t?t(e.props):"render"in t?t.render(e.props):e}(t),{ref:t.ref},n(t.props.children)):n(t)}const Ioe={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"},Roe=e=>{var t,n,r;switch(e.rootRecord.__typename){case"DocumentationRecord":{const a=Poe((null==(n=null==(t=e.pathHeadings)?void 0:t.at(-1))?void 0:n.content)||""),o=Poe((null==(r=e.content)?void 0:r.content)||"");return e.preview||o||a}case"GitHubIssueRecord":case"StackOverflowRecord":case"DiscourseRecord":return e.rootRecord.body;default:return e.preview}},Ooe=e=>{switch(e.rootRecord.__typename){case"StackOverflowRecord":return e.rootRecord.markedAsCorrectAnswer?"Resolved":void 0;case"GitHubIssueRecord":return"CLOSED"===e.rootRecord.state?"Closed":void 0}},Poe=e=>e.replace(/(https?:\/\/\S+)/g,(e=>{const t=e.split("/");return t.length>3?`...${t.slice(-2).join("/")}`:e})),Doe=e=>{switch(e){case"DocumentationRecord":return"documentation";case"GitHubIssueRecord":return"github_issue";case"DiscourseRecord":return"discourse";case"DiscordRecord":return"discord";case"StackOverflowRecord":return"stackoverflow";case"SlackEntry":return"slack_message";default:return"site"}};const Loe=()=>{const{searchSettings:e}=nP(),{tabs:t,searchFunctionsRef:n}=e,[r,a]=K.useState(!1),o=K.useRef(null),[i,s]=K.useState(!1),l=(null==t?void 0:t.length)?"string"==typeof t[0]?t[0]:t[0][0]:"All",[c,u]=K.useState(l),[d,p]=K.useState([]),h=(e=>{const{baseSettings:{transformSource:t,organizationDisplayName:n},searchSettings:{tabs:r,shouldOpenLinksInNewTab:a}}=nP();return K.useMemo((()=>{var o;const i=r.length>0?r:["All"],s={},l=new Set,c=i.map((e=>"string"==typeof e?e:e[0]));for(const e of c)s[e]=[];for(const u of e){const e=u.url||"";if(l.has(e))continue;l.add(e);const o=X9({title:u.title,url:e,description:Roe(u),type:Doe(u.rootRecord.__typename),tag:Ooe(u),breadcrumbs:u.rootRecord.pathBreadcrumbs??[],contentType:u.rootRecord.contentType},"searchResultItem",{organizationDisplayName:n,tabs:r,transformSource:t}),i={...o,id:u.id,isExternal:void 0!==o.shouldOpenInNewTab?o.shouldOpenInNewTab:a},d=i.tabs||[];for(const t of d){const e="string"==typeof t?t:t[0];c.includes(e)?s[e].push(i):console.warn(`Tab "${e}" found in item but not configured in tabs`)}c.includes("All")&&s.All.push(i)}for(const e of Object.keys(s)){const t=i.find((t=>"string"==typeof t?t===e:t[0]===e)),n="object"==typeof t&&!0===(null==(o=t[1])?void 0:o.isAlwaysVisible);0!==s[e].length||n||delete s[e]}return s}),[e,t,n,r,a])})(d),{disableTransition:f,disabled:m}=function(){const[e,t]=K.useState(!1);K.useEffect((()=>{if(e){const e=setTimeout((()=>t(!1)),0);return()=>clearTimeout(e)}}),[e]);const n=K.useCallback((()=>t(!0)),[]);return{disabled:e,disableTransition:n}}(),g=loe();return K.useImperativeHandle(n,(()=>({updateQuery(e){g.setState("search",e)},focusInput:()=>{var e;null==(e=o.current)||e.focus()}}))),{results:h,resultsList:d,setResultsList:p,hasContent:r&&(d.length>0||i),loading:i,setLoading:s,defaultTab:l,tab:c,setTab:u,disableTransition:f,transitionsDisabled:m,inputRef:o,showSearchResults:r,setShowSearchResults:a}},Moe=K.createContext(void 0),Foe=({children:e})=>{const{logEvent:t}=bP();return Wh.jsx(Moe.Provider,{value:{logEvent:t},children:e})},joe=()=>{const e=K.useContext(Moe);if(!e)throw new Error("useSearchEvents must be used within a SearchEventsProvider");return e},Boe=K.createContext(void 0),zoe=e=>{const{searchSettings:{defaultQuery:t}}=nP();return Wh.jsx(Foe,{children:Wh.jsx(voe,{shouldFilter:!1,loop:!1,defaultSearch:t,children:Wh.jsx(Hoe,{...e})})})},Hoe=({children:e,...t})=>{const n=Loe();return Wh.jsx(Boe.Provider,{value:{...n,...t},children:e})},Uoe=()=>{const e=K.useContext(Boe);if(!e)throw new Error("useSearch must be used within a SearchProvider");return e};var $oe="rovingFocusGroup.onEntryFocus",Goe={bubbles:!1,cancelable:!0},Voe="RovingFocusGroup",[qoe,Woe,Yoe]=function(e){const t=e+"CollectionProvider",[n,r]=j$(t),[a,o]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=e=>{const{scope:t,children:n}=e,r=X.useRef(null),o=X.useRef(new Map).current;return Wh.jsx(a,{scope:t,itemMap:o,collectionRef:r,children:n})};i.displayName=t;const s=e+"CollectionSlot",l=K$(s),c=X.forwardRef(((e,t)=>{const{scope:n,children:r}=e,a=U$(t,o(s,n).collectionRef);return Wh.jsx(l,{ref:a,children:r})}));c.displayName=s;const u=e+"CollectionItemSlot",d="data-radix-collection-item",p=K$(u),h=X.forwardRef(((e,t)=>{const{scope:n,children:r,...a}=e,i=X.useRef(null),s=U$(t,i),l=o(u,n);return X.useEffect((()=>(l.itemMap.set(i,{ref:i,...a}),()=>{l.itemMap.delete(i)}))),Wh.jsx(p,{[d]:"",ref:s,children:r})}));return h.displayName=u,[{Provider:i,Slot:c,ItemSlot:h},function(t){const n=o(e+"CollectionConsumer",t),r=X.useCallback((()=>{const e=n.collectionRef.current;if(!e)return[];const t=Array.from(e.querySelectorAll(`[${d}]`)),r=Array.from(n.itemMap.values()).sort(((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current)));return r}),[n.collectionRef,n.itemMap]);return r},r]}(Voe),[Koe,Xoe]=j$(Voe,[Yoe]),[Qoe,Zoe]=Koe(Voe),Joe=K.forwardRef(((e,t)=>Wh.jsx(qoe.Provider,{scope:e.__scopeRovingFocusGroup,children:Wh.jsx(qoe.Slot,{scope:e.__scopeRovingFocusGroup,children:Wh.jsx(eie,{...e,ref:t})})})));Joe.displayName=Voe;var eie=K.forwardRef(((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:a=!1,dir:o,currentTabStopId:i,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:l,onEntryFocus:c,preventScrollOnEntryFocus:u=!1,...d}=e,p=K.useRef(null),h=U$(t,p),f=Y$(o),[m=null,g]=OB({prop:i,defaultProp:s,onChange:l}),[y,b]=K.useState(!1),v=RB(c),k=Woe(n),w=K.useRef(!1),[x,E]=K.useState(0);return K.useEffect((()=>{const e=p.current;if(e)return e.addEventListener($oe,v),()=>e.removeEventListener($oe,v)}),[v]),Wh.jsx(Qoe,{scope:n,orientation:r,dir:f,loop:a,currentTabStopId:m,onItemFocus:K.useCallback((e=>g(e)),[g]),onItemShiftTab:K.useCallback((()=>b(!0)),[]),onFocusableItemAdd:K.useCallback((()=>E((e=>e+1))),[]),onFocusableItemRemove:K.useCallback((()=>E((e=>e-1))),[]),children:Wh.jsx(eG.div,{tabIndex:y||0===x?-1:0,"data-orientation":r,...d,ref:h,style:{outline:"none",...e.style},onMouseDown:F$(e.onMouseDown,(()=>{w.current=!0})),onFocus:F$(e.onFocus,(e=>{const t=!w.current;if(e.target===e.currentTarget&&t&&!y){const t=new CustomEvent($oe,Goe);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){const e=k().filter((e=>e.focusable));aie([e.find((e=>e.active)),e.find((e=>e.id===m)),...e].filter(Boolean).map((e=>e.ref.current)),u)}}w.current=!1})),onBlur:F$(e.onBlur,(()=>b(!1)))})})})),tie="RovingFocusGroupItem",nie=K.forwardRef(((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:a=!1,tabStopId:o,...i}=e,s=zO(),l=o||s,c=Zoe(tie,n),u=c.currentTabStopId===l,d=Woe(n),{onFocusableItemAdd:p,onFocusableItemRemove:h}=c;return K.useEffect((()=>{if(r)return p(),()=>h()}),[r,p,h]),Wh.jsx(qoe.ItemSlot,{scope:n,id:l,focusable:r,active:a,children:Wh.jsx(eG.span,{tabIndex:u?0:-1,"data-orientation":c.orientation,...i,ref:t,onMouseDown:F$(e.onMouseDown,(e=>{r?c.onItemFocus(l):e.preventDefault()})),onFocus:F$(e.onFocus,(()=>c.onItemFocus(l))),onKeyDown:F$(e.onKeyDown,(e=>{if("Tab"===e.key&&e.shiftKey)return void c.onItemShiftTab();if(e.target!==e.currentTarget)return;const t=function(e,t,n){const r=function(e,t){return"rtl"!==t?e:"ArrowLeft"===e?"ArrowRight":"ArrowRight"===e?"ArrowLeft":e}(e.key,n);return"vertical"===t&&["ArrowLeft","ArrowRight"].includes(r)||"horizontal"===t&&["ArrowUp","ArrowDown"].includes(r)?void 0:rie[r]}(e,c.orientation,c.dir);if(void 0!==t){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let a=d().filter((e=>e.focusable)).map((e=>e.ref.current));if("last"===t)a.reverse();else if("prev"===t||"next"===t){"prev"===t&&a.reverse();const o=a.indexOf(e.currentTarget);a=c.loop?(r=o+1,(n=a).map(((e,t)=>n[(r+t)%n.length]))):a.slice(o+1)}setTimeout((()=>aie(a)))}var n,r}))})})}));nie.displayName=tie;var rie={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function aie(e,t=!1){const n=document.activeElement;for(const r of e){if(r===n)return;if(r.focus({preventScroll:t}),document.activeElement!==n)return}}var oie=Joe,iie=nie,sie="Tabs",[lie,cie]=j$(sie,[Xoe]),uie=Xoe(),[die,pie]=lie(sie),hie=K.forwardRef(((e,t)=>{const{__scopeTabs:n,value:r,onValueChange:a,defaultValue:o,orientation:i="horizontal",dir:s,activationMode:l="automatic",...c}=e,u=Y$(s),[d,p]=OB({prop:r,onChange:a,defaultProp:o});return Wh.jsx(die,{scope:n,baseId:zO(),value:d,onValueChange:p,orientation:i,dir:u,activationMode:l,children:Wh.jsx(eG.div,{dir:u,"data-orientation":i,...c,ref:t})})}));hie.displayName=sie;var fie="TabsList",mie=K.forwardRef(((e,t)=>{const{__scopeTabs:n,loop:r=!0,...a}=e,o=pie(fie,n),i=uie(n);return Wh.jsx(oie,{asChild:!0,...i,orientation:o.orientation,dir:o.dir,loop:r,children:Wh.jsx(eG.div,{role:"tablist","aria-orientation":o.orientation,...a,ref:t})})}));mie.displayName=fie;var gie="TabsTrigger",yie=K.forwardRef(((e,t)=>{const{__scopeTabs:n,value:r,disabled:a=!1,...o}=e,i=pie(gie,n),s=uie(n),l=kie(i.baseId,r),c=wie(i.baseId,r),u=r===i.value;return Wh.jsx(iie,{asChild:!0,...s,focusable:!a,active:u,children:Wh.jsx(eG.button,{type:"button",role:"tab","aria-selected":u,"aria-controls":c,"data-state":u?"active":"inactive","data-disabled":a?"":void 0,disabled:a,id:l,...o,ref:t,onMouseDown:F$(e.onMouseDown,(e=>{a||0!==e.button||!1!==e.ctrlKey?e.preventDefault():i.onValueChange(r)})),onKeyDown:F$(e.onKeyDown,(e=>{[" ","Enter"].includes(e.key)&&i.onValueChange(r)})),onFocus:F$(e.onFocus,(()=>{const e="manual"!==i.activationMode;u||a||!e||i.onValueChange(r)}))})})}));yie.displayName=gie;var bie="TabsContent",vie=K.forwardRef(((e,t)=>{const{__scopeTabs:n,value:r,forceMount:a,children:o,...i}=e,s=pie(bie,n),l=kie(s.baseId,r),c=wie(s.baseId,r),u=r===s.value,d=K.useRef(u);return K.useEffect((()=>{const e=requestAnimationFrame((()=>d.current=!1));return()=>cancelAnimationFrame(e)}),[]),Wh.jsx(Pq,{present:a||u,children:({present:n})=>Wh.jsx(eG.div,{"data-state":u?"active":"inactive","data-orientation":s.orientation,role:"tabpanel","aria-labelledby":l,hidden:!n,id:c,tabIndex:0,...i,ref:t,style:{...e.style,animationDuration:d.current?"0s":void 0},children:n&&o})})}));function kie(e,t){return`${e}-trigger-${t}`}function wie(e,t){return`${e}-content-${t}`}vie.displayName=bie;var xie=hie,Eie=mie,_ie=yie,Sie=vie;const Tie=()=>{const{setResultsList:e,setLoading:t,showSearchResults:n,setShowSearchResults:r}=Uoe(),{baseSettings:a,searchSettings:o}=nP(),{apiKey:i,aiApiBaseUrl:s,userAuthToken:l,filters:c}=a,{maxResults:u,debounceTimeMs:d,onQueryChange:p,filters:h}=o,{logEvent:f}=joe(),m=K.useRef({}),g=K.useRef(null),y=K.useRef(null),b=`${s}/graphql`,v=K.useMemo((()=>({Authorization:`Bearer ${i}`,"Content-Type":"application/json",...l?{"User-Token":l}:{}})),[i,l]),k=K.useCallback((async n=>{const r=new AbortController;g.current=r;try{const t=await async function(e,t,n,r,a){var o;try{const i=await fetch(e,{method:"POST",headers:{"Content-Type":"application/json",...r},signal:a,body:JSON.stringify({query:t,variables:n})});if(!i.ok)throw new Error(`Network response was not OK (status: ${i.status})`);const s=await i.json();if(null==(o=s.errors)?void 0:o.length)throw new Error(s.errors[0].message);return s.data}catch(i){if(i instanceof Error&&"AbortError"===i.name)throw i;throw console.warn("Error in graphqlRequest:",i),i}}(b,"query GetSearchResults($searchInput: SearchInput!) {\n search(searchInput: $searchInput) {\n searchHits {\n id\n hitOnRoot\n url\n title\n preview\n\n ... on DocumentationHit {\n rootRecord {\n __typename\n id\n title\n url\n preview\n ... on DocumentationRecord {\n pathBreadcrumbs\n contentType\n topLevelHeadings {\n anchor\n url\n content\n }\n }\n }\n pathHeadings {\n anchor\n content\n }\n content {\n anchor\n content\n }\n }\n\n ... on StackOverflowHit {\n rootRecord {\n __typename\n id\n title\n url\n preview\n ... on StackOverflowRecord {\n body\n createdAt\n\n markedAsCorrectAnswer {\n url\n score\n content\n }\n }\n }\n }\n\n ... on GitHubIssueHit {\n rootRecord {\n __typename\n id\n title\n url\n preview\n ... on GitHubIssueRecord {\n createdAt\n body\n state\n }\n }\n }\n\n ... on DiscourseHit {\n rootRecord {\n __typename\n id\n title\n url\n preview\n ... on DiscourseRecord {\n createdAt\n body\n }\n }\n }\n }\n searchQuery\n }\n}\n",{searchInput:n},v,r.signal),a=null==t?void 0:t.search.searchHits;m.current[n.searchQuery]=a,e(a)}catch(xbe){if("AbortError"===xbe.name)return}finally{t(!1)}}),[b,v]),w=K.useCallback((e=>{const t=m.current[e.searchQuery];f({eventName:"search_query_response_received",properties:{searchQuery:e.searchQuery,totalResults:null==t?void 0:t.length}})}),[]),x=()=>{g.current&&(g.current.abort(),t(!1))},E=K.useCallback((n=>{if(y.current&&window.clearTimeout(y.current),!n.searchQuery)return x(),void e([]);y.current=window.setTimeout((()=>{x(),f({eventName:"search_query_submitted",properties:{searchQuery:n.searchQuery}}),m.current[n.searchQuery]?(e(m.current[n.searchQuery]),w(n)):(t(!0),k(n).then((()=>{w(n)})))}),d)}),[d,k]),_=Toe((e=>e.search)),S=K.useMemo((()=>({searchQuery:_,filters:{...c,...h,limit:u}})),[_,u,c,h]),T=K.useRef(null);K.useEffect((()=>{const e=()=>{null!==T.current&&(window.clearTimeout(T.current),T.current=null)},t=Boolean(_);return t&&!n?(e(),T.current=window.setTimeout((()=>{r(!0)}),250)):!t&&n&&(e(),r(!1)),e}),[_,n,r]),K.useEffect((()=>{null==p||p(S.searchQuery),E(S)}),[E,S])};function Cie(e,t,n){try{const r=new URL(e);return r.searchParams.set(n,t),r.toString()}catch{return e}}const Aie=qB("div",{_id:"aiSearchWrapper"}),Nie=e=>{const{searchSettings:{view:t}}=nP(),{isHidden:n,hasContent:r}=Uoe(),a=mL("(max-width: 768px)"),o=iL();return Wh.jsx(Aie,{"data-hidden":SL(n),"data-has-content":SL(r),"data-in-modal":SL(!!o),"data-mobile":SL(a),"data-view":t,"data-dual-pane-search-expanded":SL(r&&"dual-pane"===t&&!n),...e})},Iie=qB("div",{_id:"aiSearchRoot"}),Rie=e=>{const{isHidden:t}=Uoe(),n=mL("(max-width: 768px)");return Wh.jsx(Iie,{"data-hidden":SL(t),"data-mobile":SL(n),...e})},Oie=qB(voe.List,{_id:"aiSearchContent"}),Pie=K.forwardRef(((e,t)=>{const n=Toe((e=>e.value));return Wh.jsx(Oie,{"aria-activedescendant":`aiSearchResults__Item-${n}`,...e,ref:t})})),Die=qB("div",{_id:"aiSearchInputGroup"}),Lie=qB(jY,{_id:"aiSearchInputIcon",iconKey:"search"}),Mie=qB(voe.Input,{_id:"aiSearchInput"}),Fie=K.forwardRef((({onInput:e,...t},n)=>{const{inputRef:r,shouldAutoFocusInput:a}=Uoe(),o=Toe((e=>e.value)),i=mL("(max-width: 768px)"),{searchSettings:s}=nP(),l=K.useMemo((()=>s.placeholder||(i?"Search...":"Search for anything...")),[s.placeholder,i]),c=BB(n,r);return e7("search",r,a),Tie(),Wh.jsx(Mie,{ref:c,placeholder:l,"aria-activedescendant":`aiSearchResults__Item-${o}`,...t})})),jie=qB(MY,{_id:"aiSearchLoading",iconSettings:{builtIn:"LuLoaderCircle"}}),Bie=e=>{const{loading:t}=Uoe();return t?Wh.jsx(jie,{...e}):null},zie=qB(voe.Item,{_id:"aiAskAITrigger",value:Qae}),Hie=e=>{var t,n;const{results:r,tab:a}=Uoe(),o=loe(),i=(null==(n=null==(t=r[a])?void 0:t[0])?void 0:n.id)??"NONE";return Wh.jsx(zie,{...e,id:`aiSearchResults__Item-${Qae}`,tabIndex:0,onPointerLeave:()=>o.setState("value",i,!0)})},Uie=qB("img",{_id:"aiAskAITrigger__Icon"}),$ie=e=>{const{aiChatSettings:t}=nP(),{aiAssistantAvatar:n}=t??{},r="string"==typeof n?n:null==n?void 0:n.light,a=fB(r,("string"==typeof n?n:null==n?void 0:n.dark)??r),[o,i]=K.useState(a);K.useEffect((()=>{i(a)}),[a]);return Wh.jsx(Uie,{asChild:!0,...e,children:o?Wh.jsx("img",{src:o,alt:"AI Avatar","data-type":"image",onError:L9((()=>{i(null)})),...e}):Wh.jsx(fW,{"data-type":"icon",...e})})},Gie=qB("span",{_id:"aiAskAITrigger__Label"}),Vie=qB("span",{_id:"aiAskAITrigger__Query"}),qie=qB(jY,{_id:"aiAskAITrigger__Indicator",iconKey:"openLinkInSameTab"}),Wie=qB("span",{_id:"aiAskAITrigger__IndicatorText"}),Yie=qB(xie,{_id:"aiSearchResults"}),Kie=e=>{const{searchSettings:{view:t}}=nP(),{tab:n,setTab:r,hasContent:a,isHidden:o,disableTransition:i,results:s,defaultTab:l}=Uoe(),c=loe(),u=K.useCallback((e=>{var t;i(),r(e);const n=s[e][0]?null==(t=s[e][0])?void 0:t.id:void 0;c.setState("value",n,!0)}),[s,i]);return K.useEffect((()=>{var e,t;let a=n in s?n:Object.keys(s)[0];if(!(null==(e=s[a])?void 0:e.length)){const e=Object.keys(s).find((e=>{var t;return null==(t=s[e])?void 0:t.length}));a=e||l}if(!a)return;r(a);const o=null==(t=s[a])?void 0:t[0];o&&c.setState("value",o.id,!0)}),[s]),Wh.jsx(Yie,{value:n,onValueChange:u,"data-has-content":SL(a),"data-dual-pane-search-expanded":SL(a&&"dual-pane"===t&&!o),...e})},Xie=qB("div",{_id:"aiSearchResults__Loading"}),Qie=e=>{const{loading:t,resultsList:n}=Uoe();return!t||n.length>0?null:Wh.jsx(Xie,{...e})},Zie=qB(voe.Empty,{_id:"aiSearchResults__Empty"}),Jie=e=>{var t;const n=Toe((e=>e.search)),{loading:r,results:a,tab:o}=Uoe(),i=null==(t=a[o])?void 0:t.length;return r||!n||i?null:Wh.jsx(Zie,{children:"No results found.",...e})},ese=qB(Eie,{_id:"aiSearchResults__TabList"}),tse=e=>{const{children:t,...n}=e,{searchSettings:{tabs:r}}=nP(),{results:a,loading:o,resultsList:i}=Uoe();if(o&&0===i.length)return null;const s=Object.keys(a);return r.length&&s.length?Wh.jsx(ese,{tabIndex:-1,children:CL(t,s),...n}):null},nse=qB(_ie,{_id:"aiSearchResults__Tab"}),rse=K.forwardRef(((e,t)=>{const n=K.useRef(null),r=BB(t,n),{tab:a,onClick:o,...i}=e,{results:s,tab:l,inputRef:c}=Uoe(),u=s[a].length,d=a===l,p=UO();return K.useEffect((()=>{var e,t,r;if(d){const a=null==(t=null==(e=null==p?void 0:p.shadowHost)?void 0:e.shadowRoot)?void 0:t.activeElement;(null==a?void 0:a.hasAttribute("ikp-tab"))&&(null==(r=n.current)||r.focus())}}),[d]),Wh.jsx(nse,{ref:r,"ikp-tab":"",tabIndex:d?0:-1,value:a,children:`${a} (${u})`,onClick:L9(o,(()=>{var e;null==(e=c.current)||e.focus()})),...i})})),ase=qB("div",{_id:"aiSearchResults__Content"}),ose=qB(P$,{_id:"aiSearchResults__ScrollArea"}),ise=e=>{const{loading:t,resultsList:n}=Uoe();return t&&0===n.length?null:Wh.jsx(ose,{tabIndex:-1,...e})},sse=qB(D$,{_id:"aiSearchResults__ScrollAreaViewport"}),lse=K.forwardRef((({children:e,...t},n)=>{const r=function(){const e=K.useRef(null),t=K.useCallback((()=>{const t=e.current;t&&(0===t.scrollTop?t.setAttribute("data-scroll-top",""):t.removeAttribute("data-scroll-top"),t.scrollTop+t.clientHeight>=t.scrollHeight-1?t.setAttribute("data-scroll-bottom",""):t.removeAttribute("data-scroll-bottom"))}),[]);return K.useEffect((()=>{const n=e.current;if(n)return t(),n.addEventListener("scroll",t),window.addEventListener("resize",t),()=>{n.removeEventListener("scroll",t),window.removeEventListener("resize",t)}}),[t]),e}(),a=BB(n,r),{tab:o}=Uoe();return K.useEffect((()=>{var e;o&&(null==(e=r.current)||e.scrollTo({top:0,behavior:"auto"}))}),[o]),Wh.jsx(sse,{ref:a,tabIndex:-1,children:Wh.jsx("div",{tabIndex:-1,style:{display:"grid"},children:e}),...t})})),cse=qB(l$,{_id:"aiSearchResults__ScrollAreaScrollbar"}),use=qB(v$,{_id:"aiSearchResults__ScrollAreaThumb"}),dse=qB(L$,{_id:"aiSearchResults__ScrollAreaCorner"}),pse=qB(Sie,{_id:"aiSearchResults__List"}),hse=e=>{const{children:t,...n}=e,{results:r,tab:a}=Uoe(),o=r[a]??[];return Wh.jsx(pse,{value:a,"data-has-results":SL(o.length>0),"aria-label":"Search results",children:CL(t,o),tabIndex:-1,...n})},fse=qB(voe.Item,{_id:"aiSearchResults__Item",asChild:!0}),mse=K.forwardRef((({item:e,onClick:t,onSelect:n,children:r,...a},o)=>{var i;const{searchSettings:{shouldOpenLinksInNewTab:s,view:l,searchQueryParamKey:c}}=nP(),{logEvent:u}=joe(),d=Toe((e=>e.search)),{transitionsDisabled:p}=Uoe(),h=Toe((e=>e.value)),f=K.useRef(null),m=iL(),g=BB(o,f),y=K.useCallback((e=>{var t;"keyboard"===e.trigger&&(null==(t=f.current)||t.click())}),[]),b=K.useCallback((t=>{u({eventName:"search_result_clicked",properties:{searchQuery:d,title:e.title,url:e.url}});const n=t.metaKey||t.ctrlKey,r=void 0!==e.shouldOpenInNewTab?e.shouldOpenInNewTab:s;n||r?t.preventDefault():null==m||m.setOpen(!1)}),[u,d,e.title,e.url,e.shouldOpenInNewTab,s,m]),v=K.useMemo((()=>void 0!==e.shouldOpenInNewTab?e.shouldOpenInNewTab:s),[e.shouldOpenInNewTab,s]),k=h===e.id,w=k||("NONE"===h||h===Qae),x=K.useCallback((t=>{const n=t.metaKey||t.ctrlKey,r=void 0!==e.shouldOpenInNewTab?e.shouldOpenInNewTab:s;if(n||r){t.preventDefault();const n=c?Cie(e.url,d,c):e.url;n&&window.open(n,"_blank","noopener")}else null==m||m.setOpen(!1)}),[e.url,e.shouldOpenInNewTab,s,c,d,m]),E=K.useMemo((()=>({href:c?Cie(e.url,d,c):e.url,isExternal:v,appendToUrl:e.appendToUrl,children:r,id:`aiSearchResults__Item-${e.id}`,onClick:x})),[e.url,v,e.appendToUrl,r,e.id,c,d,x]);return Wh.jsx(NB,{source:{...e,isExternal:v},children:Wh.jsx(fse,{ref:g,value:e.id,"data-type":e.type,"data-breadcrumbs":!!(null==(i=e.breadcrumbs)?void 0:i.length),"data-disable-transitions":SL(p),"data-view":l,onSelect:L9(n,y),onClick:L9(t,b),"data-selected":SL(k),tabIndex:w?0:-1,...a,children:Wh.jsx(zY,{...E})})})})),gse=qB("div",{_id:"aiSearchResults__ItemBreadcrumbs"}),yse=e=>{var t,n,r,a;const{source:o}=IB(),{tab:i}=Uoe();if(!(null==(t=o.breadcrumbs)?void 0:t.length))return null;const{children:s,...l}=e,c=(null==(a=null==(r=null==(n=o.tabs)?void 0:n.find((e=>"string"!=typeof e&&e[0]===i)))?void 0:r[1])?void 0:a.breadcrumbs)??o.breadcrumbs??[];return Wh.jsx(gse,{"aria-hidden":"true",children:CL(s,c),...l})},bse=qB(jY,{_id:"aiSearchResults__ItemBreadcrumbIcon",iconKey:"breadcrumbSeparator"}),vse=qB(MY,{_id:"aiSearchResults__ItemIcon"}),kse=e=>{const{source:t}=IB();return Wh.jsx(vse,{iconSettings:t.icon,"data-type":t.type,...e})},wse=qB("span",{_id:"aiSearchResults__ItemTitle"}),xse=e=>{const{source:t}=IB();return Wh.jsx(wse,{"data-type":t.type,children:t.title,...e})},Ese=qB("span",{_id:"aiSearchResults__ItemTag"}),_se=e=>{const{source:t}=IB();return Wh.jsx(Ese,{"data-type":t.type,children:t.tag,...e})},Sse=qB("span",{_id:"aiSearchResults__ItemDescription"}),Tse=e=>{const{source:t}=IB(),{children:n,...r}=e,a=K.useMemo((()=>t.description?D9(t.description):[]),[t.description]);return a.length?Wh.jsx(Sse,{"data-type":t.type,"aria-hidden":"true",children:CL(n,a),...r}):null},Cse=qB("span",{_id:"aiSearchResults__ItemDescriptionPart"}),Ase=e=>{const{part:t,...n}=e,{source:r}=IB();return"string"==typeof t?t:Wh.jsx(Cse,{"data-type":r.type,children:t.content,"data-highlighted":SL(t.highlighted),...n})},Nse=qB(jY,{_id:"aiSearchResults__ItemIndicator"}),Ise=e=>{const{source:t}=IB(),{searchSettings:{view:n}}=nP();return Wh.jsx(Nse,{iconKey:t.isExternal?"openLinkInNewTab":"openLinkInSameTab","data-view":n,...e})},Rse=qB("div",{_id:"aiSearchResults__ItemPreview","aria-hidden":!0}),Ose=e=>{const{searchSettings:{view:t,shouldOpenLinksInNewTab:n}}=nP(),{results:r,tab:a}=Uoe(),o=Toe((e=>e.value)),i=r[a]??[],s=K.useRef(null),l=K.useMemo((()=>{if(o===Qae)return s.current;const e=i.find((e=>e.id===o));return s.current=e??null,e}),[o]);if("dual-pane"!==t||o===Qae)return null;if(!l)return null;const c=void 0!==l.shouldOpenInNewTab?l.shouldOpenInNewTab:n;return Wh.jsx(NB,{source:{...l,isExternal:c},children:Wh.jsx(Rse,{...e})})},Pse=qB("div",{_id:"aiSearchResults__ItemPreview__Header"}),Dse=qB(zY,{_id:"aiSearchResults__ItemPreview__Heading"}),Lse=e=>{const{source:t}=IB();return Wh.jsx(Dse,{href:t.url,isExternal:t.isExternal,appendToUrl:t.appendToUrl,"data-type":t.type,...e})},Mse=qB("span",{_id:"aiSearchResults__ItemPreview__Title"}),Fse=e=>{const{source:t}=IB();return Wh.jsx(Mse,{children:t.title,...e})},jse=qB(jY,{_id:"aiSearchResults__ItemPreview__Title__LinkIcon",iconKey:"openLinkInNewTab"}),Bse=e=>{const{source:t}=IB();return Wh.jsx(jse,{iconKey:t.isExternal?"openLinkInNewTab":"openLinkInSameTab",...e})},zse=qB(yse,{_id:"aiSearchResults__ItemPreview__Breadcrumbs"}),Hse=qB(bse,{_id:"aiSearchResults__ItemPreview__BreadcrumbIcon"}),Use=qB(N9,{_id:"aiSearchResults__ItemPreview__Body"}),$se=e=>{const{source:t}=IB(),{resultsList:n}=Uoe(),r=n.find((e=>e.id===t.id)),{searchSettings:{shouldOpenLinksInNewTab:a}}=nP();return r?Wh.jsx(Use,{shouldOpenLinksInNewTab:a,children:r.preview,...e}):null},Gse=qB("div",{_id:"aiSearchResults__ItemPreview__Outline"}),Vse=e=>{const{source:t}=IB(),{resultsList:n}=Uoe(),r=n.find((e=>e.id===t.id)),a=null==r?void 0:r.rootRecord.topLevelHeadings;return(null==a?void 0:a.length)?Wh.jsx(Gse,{...e}):null},qse=qB("span",{_id:"aiSearchResults__ItemPreview__Outline__Title",children:"On this page"}),Wse=qB("ul",{_id:"aiSearchResults__ItemPreview__Outline__List"}),Yse=e=>{const{source:t}=IB(),{resultsList:n}=Uoe(),r=n.find((e=>e.id===t.id)),a=null==r?void 0:r.rootRecord.topLevelHeadings;if(!(null==a?void 0:a.length))return null;const o=a.map((e=>{var t,n,a;const o=(null==e?void 0:e.anchor)&&(null==e?void 0:e.anchor)===(null==(t=null==r?void 0:r.content)?void 0:t.anchor),i=(null==e?void 0:e.anchor)===(null==(a=null==(n=null==r?void 0:r.pathHeadings)?void 0:n[0])?void 0:a.anchor);return{...e,isMatch:o||i}})),{children:i,...s}=e;return Wh.jsx(Wse,{children:CL(i,o),...s})},Kse=qB(zY,{_id:"aiSearchResults__ItemPreview__Outline__Item"}),Xse=e=>{const{searchSettings:{shouldOpenLinksInNewTab:t}}=nP();return Wh.jsx(Kse,{isExternal:t,...e})},Qse=qB(jY,{_id:"aiSearchResults__ItemPreview__Outline__ItemIcon",iconKey:"newLine"}),Zse=qB("span",{_id:"aiSearchResults__ItemPreview__Outline__ItemText"}),Jse=e=>Wh.jsx(Zse,{...e}),ele=qB(MY,{_id:"aiSearchResults__ItemPreview__Outline__ItemLinkIcon",iconSettings:{builtIn:"LuLink"}}),tle=qB("div",{_id:"aiSearchFooter"}),nle=e=>{const{hasContent:t}=Uoe();return Wh.jsx(tle,{"data-has-results":SL(t),...e})},rle=qB("div",{_id:"aiSearchTagline__Container"}),ale=qB("span",{_id:"aiSearchTagline__Text",children:"Powered by"}),ole=qB(O9,{_id:"aiSearchTagline__Logo"}),ile=qB("a",{_id:"aiSearchTagline__BrandName",children:"inkeep",href:"https://www.inkeep.com/",target:"_blank",rel:"noopener noreferrer"}),sle=qB(lW,{_id:"modal"}),lle=qB(uW,{_id:"modal__Overlay"}),cle=qB(dW,{_id:"modal__Content","aria-describedby":void 0}),ule=e=>{const t=mL("(max-width: 768px)");return Wh.jsx(cle,{"data-mobile":SL(t),tabIndex:-1,...e})},dle=qB(hW,{_id:"modal__Close",children:Wh.jsx(jY,{iconKey:"close"})}),ple=e=>iL()?Wh.jsx(dle,{...e}):null,hle={type:"object",properties:{aiAnnotations:{type:"object",properties:{answerConfidence:{anyOf:[{type:"string",const:"very_confident",description:"Very confident"},{type:"string",const:"somewhat_confident",description:"Somewhat confident"},{type:"string",const:"not_confident",description:"Not confident"},{type:"string",const:"no_sources",description:"No Sources"},{type:"string",const:"other",description:"Other"}]}},required:["answerConfidence"],additionalProperties:!0}},required:["aiAnnotations"],additionalProperties:!1},fle=async(e,t,n)=>{var r,a,o,i;const s=await t.chat.completions.create({model:"inkeep-qa-expert",messages:e,tools:[{type:"function",function:{name:"provideAIAnnotations",description:"Provides AI confidence levels for the response",parameters:hle}},{type:"function",function:{name:"provideRecordsConsidered",description:"Provides records considered in generating the response",parameters:{type:"object"}}}],tool_choice:"auto"},n?{headers:n}:void 0),l=null==(a=null==(r=s.choices[0])?void 0:r.message)?void 0:a.content;let c,u;const d=(null==(i=null==(o=s.choices[0])?void 0:o.message)?void 0:i.tool_calls)||[];for(const p of d){if("provideAIAnnotations"===p.function.name){c=JSON.parse(p.function.arguments).aiAnnotations}if("provideRecordsConsidered"===p.function.name){u=JSON.parse(p.function.arguments).recordsConsidered??[]}}return{answer:l||null,aiAnnotations:c,recordsConsidered:u,messages:e}},mle=async(e,t,n)=>{var r,a,o;const i=JSON.stringify(e.primaryFieldValues,null,2),s=JSON.stringify(e.fieldsToGenerate,null,2),l=await t.chat.completions.create({model:"inkeep-base-expert",messages:[{role:"system",content:'You are a helpful assistant that suggests form field values based on context. You will receive form field information including field names, descriptions, input types, and available options for select fields.\n\nFor each field, consider its description, input type, and available options (for select fields).\n\nYou must respond with a JSON object where keys are the field names and values match the expected input type and length for that field.\n\n<context>\n You are quickly suggesting form field values on behalf of an end-user. Think of yourself as the user filling out this form - keep suggestions simple, direct, and user-centric.\n\n You will receive:\n - Field metadata (names, descriptions, types)\n - For dropdown/select fields, their valid choice options\n - Initial form field values as context\n</context>\n\n<guidance>\n <rule>\n <name>Field Value Suggestions</name>\n <actions>\n <action>\n Return a JSON object where:\n - Keys are field names\n - Values must match field type requirements:\n - Text fields: Plain text strings\n - Dropdown/select fields: ONLY values from provided options list\n - Number fields: Valid numbers\n - Boolean fields: true/false\n\n <good_example> \n ✅ Example (fields will vary based on actual form configuration):\n {\n "issueType": "bug", // from options: ["bug", "feature", "question"]\n "severity": "high", // from options: ["low", "medium", "high"]\n "shortDescription": "Cannot log in to dashboard"\n }\n </good_example>\n\n <bad_example>\n ❌ Bad Example (using same illustrative fields):\n {\n "issueType": "not sure but maybe bug?", // invalid: not from options list\n "severity": "very very high", // invalid: not from options list\n "shortDescription": null // invalid: should be string\n }\n </bad_example>\n \n Note: The actual field names, types and valid options will be provided in the form configuration. \n Above examples are only illustrative of the expected format and validation rules.\n </action>\n </actions>\n </rule>\n\n <global_prohibitions>\n <never>Include explanations or comments in the JSON</never>\n <never>Suggest multiple values for a single field</never>\n <never>Return values not from the provided options for dropdown/select fields</never>\n <never>Skip required fields</never>\n <never>Add fields not present in the input metadata</never>\n <never>Overthink suggestions - keep them straightforward</never>\n </global_prohibitions>\n'},{role:"user",content:`Based on these primary field values:\n${i}\n\nSuggest values for these additional fields:\n${s}`}],stream:!0,response_format:{type:"json_object"}},n?{headers:n}:void 0);let c="";for await(const u of l){const e=null==(o=null==(a=null==(r=u.choices)?void 0:r[0])?void 0:a.delta)?void 0:o.content;e&&(c+=e)}return{suggestedValues:c?JSON.parse(c):{}}},gle=async(e,t)=>{if(t)return;const n=await vL(`${e}/v1/challenge`);return n?{"X-INKEEP-CHALLENGE-SOLUTION":btoa(JSON.stringify(n))}:void 0},yle=e=>{var t;const{formSettings:n}=e,{baseSettings:r}=nP(),{conversation:a}=iP(),{logEvent:o}=wP(),{aiApiBaseUrl:i,shouldBypassCaptcha:s}=r,l=K.useMemo((()=>new fb({baseURL:`${i}/v1`,apiKey:r.apiKey,dangerouslyAllowBrowser:!0})),[r.apiKey,i]),[c,u]=K.useState(!1),[d,p]=K.useState(!1),[h,f]=K.useState(!1),[m,g]=K.useState({}),y=K.useMemo((()=>{const{primary:e,secondary:t}=n;return lL([...e.fields,...t.fields])}),[n]),{control:b,handleSubmit:v,formState:{errors:k,isSubmitting:w,isSubmitSuccessful:x},reset:E,trigger:_,setValue:S,setError:T}=rL({defaultValues:y});K.useEffect((()=>{y&&E(y)}),[E,y]);const C=v((async e=>{try{await n.buttons.submit.onSubmit({values:e,conversation:a}),o({eventName:"intelligent_form_submitted",properties:{conversation:a,values:e}})}catch(t){T("root.serverError",{message:t instanceof Error?t.message:"Something went wrong."})}})),A=null==(t=null==k?void 0:k.root)?void 0:t.serverError;return{formSettings:n,control:b,errors:k,isSubmitSuccessful:x,isSubmitting:w,handleSubmit:C,loading:c,formError:A,submittedPrimaryForm:d,handleSubmitPrimaryForm:async()=>{var e;const t=n.primary.fields.map((e=>e.name));if(!(await _(t)))return;p(!0),u(!0);const r=b._formValues,a=n.primary.fields.reduce(((e,t)=>(e[t.name]=r[t.name],e)),{}),c=n.secondary.fields.filter((e=>!1!==e.shouldPrefillWithAI)),d=(e=>{const t=JSON.stringify(e,null,2);return[{id:`${Date.now()}1`,role:"system",content:'\n <context>\n You are evaluating a support form submission to determine if an immediate solution can be provided. Your response is final and non-conversational - the user cannot respond or ask follow-ups. You must either provide a complete solution or explain why one cannot be provided.\n </context>\n <guidance>\n <rule>\n <name>High Confidence Response</name>\n <conditions>\n <and>\n <condition>Form provides clear, specific problem description</condition>\n <condition>Authoritative information exists for this exact issue</condition>\n <condition>Complete solution can be provided from available information</condition>\n <condition>Solution requires no clarification or follow-up</condition>\n </and>\n </conditions>\n <actions>\n <action>\n Provide complete solution in this format:\n 1. State identified problem\n 2. List solution steps\n 3. Include any necessary implementation details\n\n <good_example>\n "To resolve [...paraphrased problem...], try [...solution steps]."\n </good_example>\n\n <bad_example>\n "I think this might be related to [problem]. Would you like me to explain more about...? If you could clarify [X], I could better assist..."\n </bad_example>\n\n <guidance>\n <should>Use only information from form fields</should>\n <should>State solution directly and completely</should>\n <should>Include all necessary steps</should>\n <should>Maintain professional, instructional tone</should>\n </guidance>\n </action>\n </actions>\n </rule>\n <rule>\n <name>Low Confidence Response</name>\n <conditions>\n <or>\n <condition>Problem description is unclear/ambiguous</condition>\n <condition>Authoritative information is missing</condition>\n <condition>Solution would require additional details</condition>\n <condition>Cannot provide complete confidence in solution</condition>\n </or>\n </conditions>\n <actions>\n <action>\n Provide single-sentence explanation focusing on specific information gap.\n\n <good_example>\n "The information sources don\'t cover [specific detail[s]]"\n </good_example>\n\n <bad_example>\n "I\'m not entirely sure about this, but here are some possibilities... Could you provide more details about [X]? Have you tried [Y]? It might also help if..."\n </bad_example>\n\n <guidance>\n <should>State only the primary information gap</should>\n <should>Keep explanation BRIEF and specific</should>\n <should>Focus on what\'s missing, not what\'s known</should>\n </guidance>\n </action>\n </actions>\n </rule>\n <global_prohibitions>\n <never>Ask questions or request clarification</never>\n <never>Use conditional phrases ("would you like", "do you need")</never>\n <never>Suggest contacting support</never>\n <never>Provide partial or uncertain solutions</never>\n <never>Offer multiple possible solutions</never>\n <never>Speculate beyond available information</never>\n </global_prohibitions>\n </guidance>\n '},{id:`${Date.now()}2`,role:"user",content:`${t}`}]})(a);o({eventName:"intelligent_form_primary_section_submitted",properties:{}},d);try{const t=await gle(i,s),n=await gle(i,s),[r,u]=await Promise.all([fle(d,l,t),mle({primaryFieldValues:a,fieldsToGenerate:c},l,n)]);if(u.suggestedValues)for(const[e,a]of Object.entries(u.suggestedValues))S(e,a);const p=null==(e=r.aiAnnotations)?void 0:e.answerConfidence,h=p&&["very_confident","somewhat_confident"].includes(p),m=r.recordsConsidered&&r.recordsConsidered.length>0;h&&m&&r.answer?(g({answer:r.answer,answerConfidence:p,recordsConsidered:r.recordsConsidered}),o({eventName:"intelligent_form_ai_response_provided",properties:{recordsConsidered:r.recordsConsidered}},[...d,{id:Date.now().toString(),role:"assistant",content:r.answer,links:[]}])):(f(!0),g({answer:null,recordsConsidered:r.recordsConsidered,suggestedValues:u.suggestedValues}))}catch(h){console.error(h),f(!0)}finally{u(!1)}},aiResponse:m,showSecondaryFields:h,setShowSecondaryFields:f}},ble=K.createContext(void 0),vle=({children:e,formSettings:t})=>{const n=yle({formSettings:t});return Wh.jsx(ble.Provider,{value:n,children:e})},kle=e=>Wh.jsx(oP,{children:Wh.jsx(kP,{children:Wh.jsx(vle,{...e})})}),wle=()=>{const e=K.useContext(ble);if(!e)throw new Error("useIntelligentForm must be used within a IntelligentFormProvider");return e},xle=K.createContext(void 0),Ele=({children:e,field:t,fieldProps:n,autoFocus:r})=>{const{errors:a}=wle(),o=a[t.name];return Wh.jsx(xle.Provider,{value:{field:t,fieldProps:n,error:o,autoFocus:r},children:e})},_le=()=>{const e=K.useContext(xle);if(!e)throw new Error("useIntelligentFormField must be used within a IntelligentFormFieldProvider");return e},Sle=qB("form",{_id:"intelligentForm__Root"}),Tle=e=>{const{onSubmit:t,...n}=e,{handleSubmit:r}=wle();return Wh.jsx(Sle,{onSubmit:L9(t,r),...n})},Cle=qB("h2",{_id:"intelligentForm__Heading",children:"Contact Support"}),Ale=qB("div",{_id:"intelligentForm__Content"}),Nle=qB(P$,{_id:"intelligentForm__Content__ScrollArea"}),Ile=qB(D$,{_id:"intelligentForm__Content__ScrollAreaViewport"}),Rle=e=>{const{children:t,...n}=e;return Wh.jsx(Ile,{children:Wh.jsx("div",{"data-part":"grid",style:{display:"grid"},children:t}),...n})},Ole=qB(l$,{_id:"intelligentForm__Content__ScrollAreaScrollbar"}),Ple=qB(v$,{_id:"intelligentForm__Content__ScrollAreaThumb"}),Dle=qB(L$,{_id:"intelligentForm__Content__ScrollAreaCorner"}),Lle=qB("div",{_id:"intelligentForm__Success"}),Mle=e=>{const{children:t,...n}=e,{isSubmitSuccessful:r}=wle();return r?Wh.jsx(Lle,{...n,children:t}):null},Fle=qB(MY,{_id:"intelligentForm__SuccessIcon"}),jle=e=>{const{formSettings:{successView:t}}=wle();return Wh.jsx(Fle,{iconSettings:t.icon??{builtIn:"LuCircleCheck"},...e})},Ble=qB("h2",{_id:"intelligentForm__SuccessHeading"}),zle=e=>{const{formSettings:{successView:t}}=wle();return Wh.jsx(Ble,{children:t.heading,...e})},Hle=qB("p",{_id:"intelligentForm__SuccessMessage"}),Ule=e=>{const{formSettings:{successView:t}}=wle();return Wh.jsx(Hle,{children:t.message,...e})},$le=qB("div",{_id:"intelligentForm__PrimaryForm"}),Gle=qB("div",{_id:"intelligentForm__PrimaryFormFields"}),Vle=qB("p",{_id:"intelligentForm__PrimaryForm__Description"}),qle=e=>{const{formSettings:{primary:t}}=wle();return t.description?Wh.jsx(Vle,{children:t.description,...e}):null},Wle=e=>{const{children:t,...n}=e,{formSettings:{primary:r}}=wle();return Wh.jsx(Gle,{children:CL(t,r.fields),...n})},Yle=qB("button",{_id:"intelligentForm__PrimaryFormSubmit",type:"button",children:"Next"}),Kle=e=>{const{onClick:t,...n}=e,{submittedPrimaryForm:r,handleSubmitPrimaryForm:a}=wle();return Wh.jsx(Yle,{"data-submitted":SL(r),onClick:L9(t,a),...n})},Xle=qB("div",{_id:"intelligentForm__Field"}),Qle=e=>{const{field:t,autoFocus:n,...r}=e,{control:a,errors:o}=wle();return Wh.jsx(kD,{name:t.name,control:a,rules:{required:t.isRequired?`${t.label} is required.`:void 0},render:({field:e})=>{const a=void 0!==e.value||"file"===t.inputType;return Wh.jsx(Ele,{"data-invalid":SL(!!o[t.name]),field:t,fieldProps:e,autoFocus:n,children:a&&Wh.jsx(Xle,{"data-input-type":t.inputType,"data-hidden":SL(t.isHidden),...r})})}})},Zle=qB("label",{_id:"intelligentForm__FieldLabel"}),Jle=e=>{const{field:t}=_le();return Wh.jsx(Zle,{"data-required":SL(t.isRequired),htmlFor:t.name,children:t.label,...e})},ece=qB("input",{_id:"intelligentForm__FieldText",type:"text"}),tce=K.forwardRef(((e,t)=>{const{field:n,error:r,fieldProps:{onChange:a,onBlur:o,ref:i,...s},autoFocus:l}=_le(),c=BB(t,i);return Wh.jsx(ece,{asChild:"textarea"===n.inputType,ref:c,id:n.name,autoFocus:l,placeholder:"placeholder"in n?n.placeholder:void 0,"data-invalid":SL(!!r),onChange:L9(e.onChange,a),onBlur:L9(e.onBlur,o),...s,...e,children:"textarea"===n.inputType?Wh.jsx(lz,{minRows:3,maxRows:10}):null})})),nce=qB(tce,{_id:"intelligentForm__FieldEmail",type:"email"}),rce=qB("input",{_id:"intelligentForm__FieldFile",type:"file",multiple:!0}),ace=e=>{const{field:t,error:n,fieldProps:{value:r,onChange:a,onBlur:o,...i},autoFocus:s}=_le(),{onChange:l,onBlur:c,...u}=e;return Wh.jsx(rce,{id:t.name,autoFocus:s,"data-value":r,"data-invalid":SL(!!n),...u,...i,onChange:L9(l,(e=>{const t=e.target.files;a(t)})),onBlur:L9(c,o)})},oce=qB(tce,{_id:"intelligentForm__FieldTextArea",type:"textarea",asChild:!0,children:Wh.jsx(lz,{rows:1,maxRows:8})}),ice=qB(Pz,{_id:"intelligentForm__FieldCheckbox"}),sce=e=>{const{field:t,error:n,fieldProps:r,autoFocus:a}=_le(),{onCheckedChange:o,...i}=e;return Wh.jsx(ice,{id:t.name,name:t.name,autoFocus:a,"data-invalid":SL(!!n),checked:r.value,onCheckedChange:L9(o,r.onChange),...i})},lce=qB(Dz,{_id:"intelligentForm__FieldCheckboxIndicator",children:Wh.jsx(R9,{})}),cce=qB(ZV,{_id:"intelligentForm__FieldSelect"}),uce=qB(JV,{_id:"intelligentForm__FieldSelect__Trigger"}),dce=qB(eq,{_id:"intelligentForm__FieldSelect__Value"}),pce=qB(tq,{_id:"intelligentForm__FieldSelect__Icon",asChild:!0,children:Wh.jsx(MY,{iconSettings:{builtIn:"LuChevronDown"}})}),hce=qB(nq,{_id:"intelligentForm__FieldSelect__Content",position:"popper"}),fce=qB(rq,{_id:"intelligentForm__FieldSelect__Viewport"}),mce=qB(aq,{_id:"intelligentForm__FieldSelect__Item"}),gce=qB(oq,{_id:"intelligentForm__FieldSelect__ItemText"}),yce=qB(iq,{_id:"intelligentForm__FieldSelect__ItemIndicator",asChild:!0,children:Wh.jsx(MY,{iconSettings:{builtIn:"LuCheck"}})}),bce=qB("span",{_id:"intelligentForm__FieldError"}),vce=e=>{var t;const{error:n}=_le();return n?Wh.jsx(bce,{children:null==(t=n.message)?void 0:t.toString(),...e}):null},kce=qB("div",{_id:"intelligentForm__BotHeading"}),wce=qB(MY,{_id:"intelligentForm__BotHeading__Icon",iconSettings:{builtIn:"LuSparkles"}}),xce=qB("div",{_id:"intelligentForm__BotHeading__Name"}),Ece=e=>{const{baseSettings:t}=nP(),{organizationDisplayName:n}=t??{},{formSettings:{aiAssistantName:r}}=wle();return Wh.jsx(xce,{children:r??n,...e})},_ce=qB("div",{_id:"intelligentForm__Loading"}),Sce=K.forwardRef((({...e},t)=>{const{loading:n}=wle(),r=K.useRef(null),a=BB(t,r);return K.useEffect((()=>{n&&r.current&&r.current.scrollIntoView({behavior:"smooth",block:"nearest",inline:"nearest"})}),[n]),n?Wh.jsx(_ce,{ref:a,...e}):null})),Tce=qB("div",{_id:"intelligentForm__ConfidentResponse"}),Cce=K.forwardRef((({...e},t)=>{const{aiResponse:n,loading:r}=wle(),a=K.useRef(null),o=BB(t,a);return K.useEffect((()=>{!r&&n.answerConfidence&&a.current&&a.current.scrollIntoView({behavior:"smooth",block:"nearest",inline:"nearest"})}),[r,n.answerConfidence]),n.answerConfidence?Wh.jsx(Tce,{ref:o,...e}):null})),Ace=qB(N9,{_id:"intelligentForm__ConfidentAnswer"}),Nce=e=>{const{aiResponse:t}=wle();return Wh.jsx(Ace,{shouldOpenLinksInNewTab:!0,children:t.answer,...e})},Ice=qB("button",{_id:"intelligentForm__ConfidentResponseButton",type:"button"}),Rce=e=>{const{onClick:t,...n}=e,{showSecondaryFields:r,setShowSecondaryFields:a}=wle();return Wh.jsx(Ice,{"data-escalated":SL(r),onClick:L9(t,(()=>{a(!0)})),...n})},Oce=qB(MY,{_id:"intelligentForm__ConfidentResponseButton__Icon",iconSettings:{builtIn:"LuUser"}}),Pce=qB("span",{_id:"intelligentForm__ConfidentResponseButton__Label",children:"Escalate to human"}),Dce=qB("div",{_id:"intelligentForm__SecondaryForm"}),Lce=K.forwardRef((({...e},t)=>{const{showSecondaryFields:n}=wle(),r=K.useRef(null),a=BB(t,r);return K.useEffect((()=>{n&&r.current&&r.current.scrollIntoView({behavior:"smooth",block:"nearest",inline:"nearest"})}),[n]),n?Wh.jsx(Dce,{ref:a,...e}):null})),Mce=qB("p",{_id:"intelligentForm__SecondaryForm__Description"}),Fce=e=>{const{formSettings:{secondary:t},aiResponse:{answerConfidence:n}}=wle();if(!t.description)return null;const r="string"==typeof t.description?t.description:n?t.description.confident:t.description.default;return Wh.jsx(Mce,{children:r,...e})},jce=qB("div",{_id:"intelligentForm__SecondaryFormFields"}),Bce=e=>{const{children:t,...n}=e,{formSettings:{secondary:r}}=wle();return Wh.jsx(jce,{children:CL(t,r.fields),...n})},zce=qB("button",{_id:"intelligentForm__SecondaryFormSubmit",type:"submit",children:"Submit"}),Hce=e=>{const{formSettings:t}=wle(),{label:n}=t.buttons.submit;return Wh.jsx(zce,{children:n??"Submit",...e})},Uce=qB("span",{_id:"intelligentForm__Error"}),$ce=e=>{const{formError:t}=wle();return t?Wh.jsx(Uce,{children:t.message,...e}):null},Gce=qB("div",{_id:"intelligentForm__Sources"}),Vce=qB("p",{_id:"intelligentForm__SourcesCaption",children:"Here are the sources I considered:"}),qce=qB("div",{_id:"intelligentForm__SourcesList"}),Wce=e=>{const{children:t,...n}=e,{baseSettings:{transformSource:r,organizationDisplayName:a}}=nP(),{aiResponse:{recordsConsidered:o}}=wle();if(!o)return null;const i=o.reduce(((e,t)=>{const n=X9(t,"intelligentFormSource",{organizationDisplayName:a,transformSource:r});return e.some((e=>e.url===n.url))||e.push(n),e}),[]);return Wh.jsx(qce,{children:CL(t,i),...n})},Yce=qB(zY,{_id:"intelligentForm__Source"}),Kce=e=>{const{source:t,...n}=e;return Wh.jsx(NB,{source:{...t,isExternal:!!t.shouldOpenInNewTab},children:Wh.jsx(Yce,{"data-type":t.type,appendToUrl:t.appendToUrl,href:t.url,isExternal:!1!==t.shouldOpenInNewTab,...n})})},Xce=qB(MY,{_id:"intelligentForm__SourceIcon"}),Qce=e=>{const{source:t}=IB();return Wh.jsx(Xce,{iconSettings:t.icon,"data-type":t.type,...e})},Zce=qB("span",{_id:"intelligentForm__SourceTitle"}),Jce=e=>{const{source:t}=IB();return Wh.jsx(Zce,{"data-type":t.type,children:t.title,...e})},eue=qB("div",{_id:"chatButton__Container"}),tue=qB("button",{_id:"chatButton__Button"}),nue=qB("div",{_id:"chatButton__Text"}),rue=qB(vz,{_id:"chatButton__AvatarContent"}),aue=qB(kz,{_id:"chatButton__AvatarImage"}),oue=K.memo((e=>{const{onLoadingStatusChange:t,avatar:n,...r}=e,{aiChatSettings:a}=nP(),{aiAssistantAvatar:o}=a??{},i="string"==typeof n?n:fB(null==n?void 0:n.light,null==n?void 0:n.dark),s="string"==typeof o?o:null==o?void 0:o.dark,[l,c]=K.useState(i??s);K.useEffect((()=>{c(i??s)}),[i,s]);return l?Wh.jsx(aue,{src:l,alt:"Chat avatar","data-type":"image",onLoadingStatusChange:L9(t,(e=>{"error"===e&&c(null)})),...r}):Wh.jsx(fW,{"data-type":"icon",...e})})),iue=qB("div",{_id:"searchBar__Container"}),sue=qB("button",{_id:"searchBar__Button",type:"button"}),lue=qB("div",{_id:"searchBar__ContentWrapper"}),cue=qB("div",{_id:"searchBar__Text"}),uue=e=>{const{searchSettings:{placeholder:t}}=nP();return Wh.jsx(cue,{...e,children:t})},due=qB(jY,{_id:"searchBar__Icon",iconKey:"search"}),pue=qB("kbd",{_id:"searchBar__KbdWrapper"}),hue=qB("kbd",{_id:"searchBar__KbdShortcutKey"}),fue=e=>{const{shortcutKey:t,...n}=e;return Wh.jsx(hue,{...n,children:null==t?void 0:t.toUpperCase()})},mue=()=>{var e,t;if("undefined"==typeof window)return!1;const n=null==(t=null==(e=window.navigator)?void 0:e.userAgent)?void 0:t.toLowerCase();return n.includes("macintosh")||n.includes("mac os x")},gue=qB("kbd",{_id:"searchBar__Ctrl",children:"Ctrl"}),yue=qB(jY,{_id:"searchBar__CmdIcon",iconKey:"command"}),bue=e=>{const{shortcutKey:t,...n}=e;return Wh.jsx(Wh.Fragment,{children:t?mue()?Wh.jsx(yue,{...n}):Wh.jsx(gue,{...n}):null})};const vue={width:void 0,height:void 0};function kue(e){const{ref:t,box:n="content-box"}=e,[{width:r,height:a},o]=K.useState(vue),i=function(){const e=K.useRef(!1);return K.useEffect((()=>(e.current=!0,()=>{e.current=!1})),[]),K.useCallback((()=>e.current),[])}(),s=K.useRef({...vue}),l=K.useRef(void 0);return l.current=e.onResize,K.useEffect((()=>{if(!t.current)return;if("undefined"==typeof window||!("ResizeObserver"in window))return;const e=new ResizeObserver((([e])=>{const t="border-box"===n?"borderBoxSize":"device-pixel-content-box"===n?"devicePixelContentBoxSize":"contentBoxSize",r=wue(e,t,"inlineSize"),a=wue(e,t,"blockSize");if(s.current.width!==r||s.current.height!==a){const e={width:r,height:a};s.current.width=r,s.current.height=a,l.current?l.current(e):i()&&o(e)}}));return e.observe(t.current,{box:n}),()=>{e.disconnect()}}),[n,t,i]),{width:r,height:a}}function wue(e,t,n){return e[t]?Array.isArray(e[t])?e[t][0][n]:e[t][n]:"contentBoxSize"===t?e.contentRect["inlineSize"===n?"width":"height"]:void 0}const xue="undefined"!=typeof document?K.useLayoutEffect:K.useEffect;function Eue(e){const{children:t,target:n,tag:r,host:a}=e,o=K.useRef(null),i=K.useRef(null),[,s]=K.useReducer((e=>e+1),0);xue((()=>{if(!o.current)return;const e=o.current.ownerDocument,t=a??e.body;return i.current=e.createElement(r??"inkeep-portal"),t.appendChild(i.current),s(),()=>{i.current&&t.removeChild(i.current)}}),[]);const l=(null==n?void 0:n.current)??i.current;return l?se.createPortal(t,l):K.createElement("span",{ref:o})}const _ue=({children:e,...t})=>{const{baseSettings:n}=nP(),{rootElement:r}=n;return Wh.jsx(Eue,{host:r,...t,children:Wh.jsx(TB,{children:e})})},Sue=K.createContext(null),Tue={didCatch:!1,error:null};let Cue=class extends K.Component{constructor(e){super(e),this.resetErrorBoundary=this.resetErrorBoundary.bind(this),this.state=Tue}static getDerivedStateFromError(e){return{didCatch:!0,error:e}}resetErrorBoundary(){const{error:e}=this.state;if(null!==e){for(var t,n,r=arguments.length,a=new Array(r),o=0;o<r;o++)a[o]=arguments[o];null===(t=(n=this.props).onReset)||void 0===t||t.call(n,{args:a,reason:"imperative-api"}),this.setState(Tue)}}componentDidCatch(e,t){var n,r;null===(n=(r=this.props).onError)||void 0===n||n.call(r,e,t)}componentDidUpdate(e,t){const{didCatch:n}=this.state,{resetKeys:r}=this.props;var a,o;n&&null!==t.error&&function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return e.length!==t.length||e.some(((e,n)=>!Object.is(e,t[n])))}(e.resetKeys,r)&&(null===(a=(o=this.props).onReset)||void 0===a||a.call(o,{next:r,prev:e.resetKeys,reason:"keys"}),this.setState(Tue))}render(){const{children:e,fallbackRender:t,FallbackComponent:n,fallback:r}=this.props,{didCatch:a,error:o}=this.state;let i=e;if(a){const e={error:o,resetErrorBoundary:this.resetErrorBoundary};if("function"==typeof t)i=t(e);else if(n)i=K.createElement(n,e);else{if(void 0===r)throw o;i=r}}return K.createElement(Sue.Provider,{value:{didCatch:a,error:o,resetErrorBoundary:this.resetErrorBoundary}},i)}};const Aue=()=>null,Nue=({children:e})=>Wh.jsx(Cue,{FallbackComponent:Aue,onError:(e,t)=>{console.warn(e),console.warn(t)},children:e}),Iue=e=>"boolean"==typeof e?`${e}`:0===e?"0":e,Rue=W4,Oue=(e,t)=>n=>{var r;if(null==(null==t?void 0:t.variants))return Rue(e,null==n?void 0:n.class,null==n?void 0:n.className);const{variants:a,defaultVariants:o}=t,i=Object.keys(a).map((e=>{const t=null==n?void 0:n[e],r=null==o?void 0:o[e];if(null===t)return null;const i=Iue(t)||Iue(r);return a[e][i]})),s=n&&Object.entries(n).reduce(((e,t)=>{let[n,r]=t;return void 0===r||(e[n]=r),e}),{}),l=null==t||null===(r=t.compoundVariants)||void 0===r?void 0:r.reduce(((e,t)=>{let{class:n,className:r,...a}=t;return Object.entries(a).every((e=>{let[t,n]=e;return Array.isArray(n)?n.includes({...o,...s}[t]):{...o,...s}[t]===n}))?[...e,n,r]:e}),[]);return Rue(e,i,l,null==n?void 0:n.class,null==n?void 0:n.className)},Pue=Oue(["max-h-screen max-w-screen relative","grow-[5] mx-auto justify-self-center text-left"],{variants:{size:{default:["grow-0 justify-self-center self-center","m-auto max-h-[100vw] max-w-screen","md:w-[min(600px,100%)] md:h-[min(760px,100%)]","lg:w-[min(640px,100%)] lg:h-[min(800px,100%)]","2xl:w-[min(760px,100%)] 2xl:h-[min(900px,100%)]"],expand:["w-full h-full"],"shrink-vertically":["w-full h-auto self-start max-h-full"],"full-viewport":["fixed top-0 left-0 w-screen h-screen z-dropdown"]},variant:{"container-with-shadow":"shadow-[0_25px_50px_-12px_rgba(0,0,0,0.25)] dark:shadow-[none]","no-shadow":"shadow-[none]"}},defaultVariants:{size:"default",variant:"container-with-shadow"}}),Due=Oue(["inline-flex","items-center","justify-center","align-middle","select-none","relative","whitespace-nowrap","appearance-none","rounded-md","leading-[1.2]","transition-all","duration-300","cursor-pointer","font-semibold","focus:outline-none","focus:z-base","focus-visible:ring","focus-visible:ring-gray-500","dark:focus-visible:ring-white-alpha-900","focus-visible:ring-2","disabled:opacity-40","disabled:cursor-not-allowed","disabled:shadow-none"],{variants:{variant:{solid:["bg-gray-100 dark:bg-white-alpha-100","text-gray-800 dark:text-white-alpha-950","hover:bg-gray-200 dark:hover:bg-white-alpha-200","hover:disabled:bg-gray-100 dark:hover:disabled:bg-white-alpha-100","active:bg-gray-300 dark:active:bg-white-alpha-400"],iconButton:["px-1 text-gray-500 text-md","hover:text-inkeep-primary-strong","dark:text-gray-dark-200","dark:hover:text-inkeep-expanded-primary-300"],ghost:["text-gray-800 dark:text-white-alpha-950","hover:bg-gray-100 dark:hover:bg-white-alpha-100","active:bg-gray-200 dark:active:bg-white-alpha-200"],outline:["border dark:border-white-alpha-200","text-gray-600 dark:text-gray-200","hover:bg-gray-50 dark:hover:bg-white-alpha-100","active:bg-gray-50 dark:active:bg-white-alpha-100"]},size:{sm:"h-8 min-w-8 text-sm px-3",md:"h-10 min-w-10 text-md px-4",xs:"h-6 min-w-6 text-xs px-2"},preset:{neutralFilled:["bg-gray-1000 text-white hover:bg-gray-900 active:bg-gray-900","dark:bg-inkeep-expanded-primary-300 dark:text-gray-dark-950","dark:hover:bg-inkeep-expanded-primary-200","dark:active:bg-inkeep-expanded-primary-200"]}},defaultVariants:{size:"md"}}),Lue=Oue("",{variants:{slot:{root:["flex items-center pl-2","text-xs rounded-md h-6","bg-gray-300 dark:bg-white-alpha-200","min-w-0 w-fit"],icon:["mr-[0.5em]","text-gray-600 dark:text-white-alpha-600"],title:["overflow-hidden whitespace-nowrap text-ellipsis inline-block"],delete:[Due({variant:"iconButton",size:"md"}),"h-4 px-1 min-w-[unset]","text-gray-600 dark:text-white-alpha-600","hover:bg-transparent hover:text-gray-700","dark:hover:text-white-alpha-500","[&_svg]:w-4 [&_svg]:h-4"]}}}),Mue=Oue("",{variants:{slot:{root:["peer h-4 w-4 shrink-0 rounded-xs","border-2 border-inherit cursor-pointer","disabled:opacity-50","data-[state=checked]:bg-gray-1000","dark:data-[state=checked]:bg-white-alpha-950","data-[state=checked]:border-gray-1000","dark:data-[state=checked]:border-white-alpha-950","text-white data-[state=checked]:text-white","dark:data-[state=checked]:text-gray-1000"],indicator:["flex items-center justify-center","text-current animate-checkbox-check"]}}}),Fue=Oue(["transition-all data-[disable-transitions]:transition-none","duration-100 ease-in-out"],{variants:{slot:{root:["group w-full overflow-hidden border rounded-lg","text-inkeep-primary-text-bold selected:text-inkeep-primary-strong","focus:outline-inkeep-expanded-primary-700 dark:focus:outline-inkeep-expanded-primary-300","dark:text-white-alpha-950 dark:selected:text-inkeep-expanded-primary-300","bg-white selected:bg-inkeep-primary-light-subtle","dark:bg-transparent dark:selected:bg-white-alpha-200","border-gray-200 selected:border-inkeep-primary-medium-subtle","dark:border-white-alpha-200","dark:selected:border-inkeep-expanded-primary-300","py-2 px-4 grid gap-x-2 gap-y-1",'[grid-template:"breadcrumbs_breadcrumbs_breadcrumbs_indicator""icon_title_tag_indicator""description_description_description_indicator"/auto_auto_1fr_auto]',"items-center",'md:data-[view=dual-pane]:[grid-template:"breadcrumbs_breadcrumbs_breadcrumbs""icon_title_tag""description_description_description"/auto_auto_1fr]'],breadcrumbs:["[grid-area:breadcrumbs]","whitespace-nowrap line-clamp-1","flex items-center text-gray-600","dark:text-white-alpha-600 text-xs truncate inline-block"],breadcrumbsIcon:"last-of-type:hidden text-xs mb-0.5 mx-[5px]",icon:["[grid-area:icon]","text-gray-500","group-selected:text-inkeep-primary-text-subtle","dark:text-gray-dark-300 dark:group-selected:text-gray-dark-100"],title:["[grid-area:title]","text-gray-800 dark:text-white-alpha-950","group-selected:text-inkeep-primary-text-bold","dark:group-selected:text-white","font-medium line-clamp-1","whitespace-nowrap text-ellipsis inline-block"],tag:["[grid-area:tag] w-fit justify-self-end","text-xs px-1 uppercase rounded-sm align-middle","font-bold inline-block whitespace-nowrap",'data-[type^="github"]:text-purple-500','data-[type="stackoverflow"]:text-green-500',"shadow-[inset_0_0_0_1px_currentColor]"],description:["[grid-area:description]","text-1sm line-clamp-1","text-gray-700 dark:text-white-alpha-700"],descriptionPart:["data-[highlighted]:font-semibold","data-[highlighted]:text-inkeep-primary-text-subtle","dark:data-[highlighted]:text-gray-dark-50"],indicator:["[grid-area:indicator]","self-center justify-self-end","opacity-0 group-selected:opacity-100","transition-opacity duration-100 ease-in-out ml-auto","md:data-[view=dual-pane]:hidden"]}}}),jue=Oue("size-4 inline-block leading-[1em] shrink-0 text-current align-middle"),Bue=Oue(["w-full min-w-0 outline-none relative","appearance-none [transition-property:common]","[transition-duration:0.02s]","disabled:opacity-40 disabled:cursor-not-allowed","[--focus-border-color:theme(colors.blue.500)]","[--error-border-color:theme(colors.red.500)]","dark:[--focus-border-color:theme(colors.blue.300)]","dark:[--error-border-color:theme(colors.red.300)]"],{variants:{variant:{outline:["border border-inherit bg-inherit","focus:[&:not([data-invalid])]:border-[--focus-border-color]","focus:[&:not([data-invalid])]:shadow-[0_0_0_1px_var(--focus-border-color)]","data-[invalid]:border-[--error-border-color]","data-[invalid]:shadow-[0_0_0_1px_var(--error-border-color)]"]},size:{md:"p-4 h-10 text-md rounded-md",sm:"px-3 py-2 text-sm rounded-md"}}}),zue=Oue(["transition-[common] ease-out duration-[180]","cursor-pointer text-decoration-none break-words","outline-none focus-visible:ring-2 focus-visible:ring-offset-2","focus-visible:ring-gray-500","dark:focus-visible:ring-white-alpha-900 dark:focus-visible:ring-offset-gray-950","hover:underline"]),Hue=Oue("tracking-tight font-semibold",{variants:{size:{lg:"text-xl",md:"text-md"}},defaultVariants:{size:"md"}}),Uue=Oue("text-2sm ms-[1em] break-words pb-3 pl-7 relative [&_li]:mb-1",{variants:{style:{ordered:"list-decimal [counter-increment:item]",unordered:"list-[initial]"}}}),$ue=Oue("",{variants:{slot:{root:"w-full border-collapse [font-variant-numeric:lining-nums_tabular-nums]",th:["font-heading font-bold uppercase tracking-wider text-start","data-[is-numeric=true]:text-end","border-b border-gray-100 dark:border-gray-700","text-gray-600 dark:text-gray-400","px-6 py-3 leading-4 text-xs"],td:["text-start data-[is-numeric=true]:text-end","border-b border-gray-100 dark:border-gray-700","px-6 py-4 leading-5"]},size:{md:""}}}),Gue=Oue(["ml-[3px] cursor-pointer","[&_a]:bg-inkeep-primary-light","[&_a]:px-1","[&_a]:py-[1px]","[&_a]:rounded-sm","[&_a]:no-underline","[&_a]:text-inkeep-primary-text-subtle","[&_a]:hover:text-inkeep-primary-text-bold","[&_a]:font-semibold","[&_a]:dark:bg-inkeep-primary-text-subtle","[&_a]:dark:hover:text-inkeep-expanded-primary-200","[&_a]:hover:no-underline"]),Vue=Oue(["bg-inkeep-primary-medium text-inkeep-primary-text-color-on-primary","[overflow-wrap:anywhere] min-w-0 py-[.2rem] my-[.1rem]","px-[.4rem] rounded-[6px] [font-size:85%!important]","font-semibold inline-block","font-mono "]),que=Oue("",{variants:{slot:{container:"overflow-y-auto mb-3",header:["flex items-center justify-between","bg-gray-50 dark:bg-gray-dark-800","text-gray-600 dark:text-gray-400","mb-0 leading-[1.25] px-2 text-xs","transition-all duration-200 ease-in-out","rounded-[6px_6px_0_0]"],copyButton:["px-0 bg-inherit text-inherit","hover:text-gray-800 dark:text-white-alpha-700 dark:hover:text-white-alpha-950","dark:hover:bg-transparent h-8 w-8 min-h-8 min-w-8 text-sm","data-[copied]:text-inkeep-primary-medium"],highlighter:["text-1sm overflow-x-auto","rounded-[0_0_6px_6px]","p-[1em] whitespace-pre","m-[0px_0px_0.5em]","bg-gray-50 dark:bg-gray-dark-900","[scrollbar-width:thin]","[--scrollbar-color:var(--color-gray-300)]","dark:[--scrollbar-color:var(--color-gray-dark-600)]","[scrollbar-color:var(--scrollbar-color)_transparent]"]}}}),Wue=Oue("",{variants:{slot:{overlay:["fixed inset-0","bg-overlay-light dark:bg-overlay-dark","data-[state=closed]:hidden","data-[state=open]:animate-[fade-in_0.15s_ease-out]","backdrop-blur-sm overflow-y-auto","place-items-center grid z-overlay"],content:["fixed","top-[5%]","left-1/2","translate-x-[-50%]","z-overlay","flex flex-col","w-full","duration-200","text-inherit rounded-md","bg-white shadow-lg dark:bg-gray-dark-950 dark:shadow-none","focus-visible:outline-none","focus:outline-none","data-[state=closed]:hidden","data-[state=closed]:animate-fade-out","data-[state=open]:animate-[fade-in_0.15s_ease-out]","data-[mobile]:inset-0","data-[mobile]:h-[unset]","data-[mobile]:w-[unset]","data-[mobile]:transform-none","data-[mobile]:rounded-none","[&[data-mobile]>div]:h-full","[&[data-mobile]>div]:max-h-dvh","[&[data-mobile]>div]:max-h-[unset]"],header:["px-6 py-4 text-xl font-semibold flex-0 flex flex-col"],close:[Due({variant:"ghost",size:"md"}),"w-8 h-8 min-w-0","text-lg text-gray-500 dark:text-white-alpha-500","absolute top-2 right-3"],body:["px-6 py-2 flex-1"]}}}),Yue=Oue("",{variants:{slot:{content:["flex flex-col bg-white dark:bg-gray-dark-800","rounded-md z-popover","shadow-md relative","data-[state=open]:animate-fade-in","data-[state=closed]:animate-fade-out","focus:outline-none"],arrow:"fill-white dark:fill-gray-dark-800"}}}),Kue=Oue("",{variants:{section:{wrapper:"w-full flex flex-col grow-[5] overflow-hidden justify-between max-h-full",header:"relative max-h-full",content:"w-full flex flex-col overflow-hidden p-0 grow-[2]",footer:"justify-self-end flex-shrink-0"}}}),Xue=Oue("",{variants:{slot:{trigger:[Bue({size:"md",variant:"outline"}),"px-4 py-0 flex items-center justify-between"],content:["relative z-dropdown max-h-96 min-w-[8rem]","overflow-hidden rounded-md border","bg-white dark:bg-gray-dark-950 shadow-md","data-[state=open]:animate-fade-in data-[state=closed]:animate-fade-out","data-[side=bottom]:translate-y-1.5","data-[side=left]:-translate-x-1.5","data-[side=right]:translate-x-1.5","data-[side=top]:-translate-y-1.5"],viewport:["p-1 h-[var(--radix-select-trigger-height)]","w-full min-w-[var(--radix-select-trigger-width)]"],item:["hover:bg-gray-100 dark:hover:bg-gray-dark-800","focus:bg-gray-100 dark:focus:bg-gray-dark-800","relative flex w-full text-md cursor-pointer py-1.5","select-none outline-none pl-2 pr-8 rounded-md items-center ","data-[disabled]:pointer-events-none data-[disabled]:opacity-50"],itemIndicator:["absolute right-2 flex h-3.5 w-3.5","items-center justify-center"]}}}),Que=Oue(["h-5 opacity-70 rounded-sm shadow-none","bg-clip-padding cursor-default pointer-events-none","before:invisible after:invisible *:invisible","animate-skeleton-bg-fade select-none","[--start-color:theme(colors.gray.50)]","[--end-color:theme(colors.gray.300)]","dark:[--start-color:theme(colors.gray-dark.800)]","dark:[--end-color:theme(colors.gray-dark.600)]","bg-[--start-color] border-[--end-color]"]),Zue=e=>{const t=nde(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:e=>{const n=e.split("-");return""===n[0]&&1!==n.length&&n.shift(),Jue(n,t)||tde(e)},getConflictingClassGroupIds:(e,t)=>{const a=n[e]||[];return t&&r[e]?[...a,...r[e]]:a}}},Jue=(e,t)=>{var n;if(0===e.length)return t.classGroupId;const r=e[0],a=t.nextPart.get(r),o=a?Jue(e.slice(1),a):void 0;if(o)return o;if(0===t.validators.length)return;const i=e.join("-");return null==(n=t.validators.find((({validator:e})=>e(i))))?void 0:n.classGroupId},ede=/^\[(.+)\]$/,tde=e=>{if(ede.test(e)){const t=ede.exec(e)[1],n=null==t?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},nde=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return ide(Object.entries(e.classGroups),n).forEach((([e,n])=>{rde(n,r,e,t)})),r},rde=(e,t,n,r)=>{e.forEach((e=>{if("string"!=typeof e){if("function"==typeof e)return ode(e)?void rde(e(r),t,n,r):void t.validators.push({validator:e,classGroupId:n});Object.entries(e).forEach((([e,a])=>{rde(a,ade(t,e),n,r)}))}else{(""===e?t:ade(t,e)).classGroupId=n}}))},ade=(e,t)=>{let n=e;return t.split("-").forEach((e=>{n.nextPart.has(e)||n.nextPart.set(e,{nextPart:new Map,validators:[]}),n=n.nextPart.get(e)})),n},ode=e=>e.isThemeGetter,ide=(e,t)=>t?e.map((([e,n])=>[e,n.map((e=>"string"==typeof e?t+e:"object"==typeof e?Object.fromEntries(Object.entries(e).map((([e,n])=>[t+e,n]))):e))])):e,sde=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const a=(a,o)=>{n.set(a,o),t++,t>e&&(t=0,r=n,n=new Map)};return{get(e){let t=n.get(e);return void 0!==t?t:void 0!==(t=r.get(e))?(a(e,t),t):void 0},set(e,t){n.has(e)?n.set(e,t):a(e,t)}}},lde=e=>{const{separator:t,experimentalParseClassName:n}=e,r=1===t.length,a=t[0],o=t.length,i=e=>{const n=[];let i,s=0,l=0;for(let d=0;d<e.length;d++){let c=e[d];if(0===s){if(c===a&&(r||e.slice(d,d+o)===t)){n.push(e.slice(l,d)),l=d+o;continue}if("/"===c){i=d;continue}}"["===c?s++:"]"===c&&s--}const c=0===n.length?e:e.substring(l),u=c.startsWith("!");return{modifiers:n,hasImportantModifier:u,baseClassName:u?c.substring(1):c,maybePostfixModifierPosition:i&&i>l?i-l:void 0}};return n?e=>n({className:e,parseClassName:i}):i},cde=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach((e=>{"["===e[0]?(t.push(...n.sort(),e),n=[]):n.push(e)})),t.push(...n.sort()),t},ude=/\s+/;function dde(){let e,t,n=0,r="";for(;n<arguments.length;)(e=arguments[n++])&&(t=pde(e))&&(r&&(r+=" "),r+=t);return r}const pde=e=>{if("string"==typeof e)return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=pde(e[r]))&&(n&&(n+=" "),n+=t);return n};function hde(e,...t){let n,r,a,o=function(s){const l=t.reduce(((e,t)=>t(e)),e());return n=(e=>({cache:sde(e.cacheSize),parseClassName:lde(e),...Zue(e)}))(l),r=n.cache.get,a=n.cache.set,o=i,i(s)};function i(e){const t=r(e);if(t)return t;const o=((e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:a}=t,o=[],i=e.trim().split(ude);let s="";for(let l=i.length-1;l>=0;l-=1){const e=i[l],{modifiers:t,hasImportantModifier:c,baseClassName:u,maybePostfixModifierPosition:d}=n(e);let p=Boolean(d),h=r(p?u.substring(0,d):u);if(!h){if(!p){s=e+(s.length>0?" "+s:s);continue}if(h=r(u),!h){s=e+(s.length>0?" "+s:s);continue}p=!1}const f=cde(t).join(":"),m=c?f+"!":f,g=m+h;if(o.includes(g))continue;o.push(g);const y=a(h,p);for(let n=0;n<y.length;++n){const e=y[n];o.push(m+e)}s=e+(s.length>0?" "+s:s)}return s})(e,n);return a(e,o),o}return function(){return o(dde.apply(null,arguments))}}const fde=e=>{const t=t=>t[e]||[];return t.isThemeGetter=!0,t},mde=/^\[(?:([a-z-]+):)?(.+)\]$/i,gde=/^\d+\/\d+$/,yde=new Set(["px","full","screen"]),bde=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,vde=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,kde=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,wde=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,xde=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Ede=e=>Sde(e)||yde.has(e)||gde.test(e),_de=e=>jde(e,"length",Bde),Sde=e=>Boolean(e)&&!Number.isNaN(Number(e)),Tde=e=>jde(e,"number",Sde),Cde=e=>Boolean(e)&&Number.isInteger(Number(e)),Ade=e=>e.endsWith("%")&&Sde(e.slice(0,-1)),Nde=e=>mde.test(e),Ide=e=>bde.test(e),Rde=new Set(["length","size","percentage"]),Ode=e=>jde(e,Rde,zde),Pde=e=>jde(e,"position",zde),Dde=new Set(["image","url"]),Lde=e=>jde(e,Dde,Ude),Mde=e=>jde(e,"",Hde),Fde=()=>!0,jde=(e,t,n)=>{const r=mde.exec(e);return!!r&&(r[1]?"string"==typeof t?r[1]===t:t.has(r[1]):n(r[2]))},Bde=e=>vde.test(e)&&!kde.test(e),zde=()=>!1,Hde=e=>wde.test(e),Ude=e=>xde.test(e),$de=hde((()=>{const e=fde("colors"),t=fde("spacing"),n=fde("blur"),r=fde("brightness"),a=fde("borderColor"),o=fde("borderRadius"),i=fde("borderSpacing"),s=fde("borderWidth"),l=fde("contrast"),c=fde("grayscale"),u=fde("hueRotate"),d=fde("invert"),p=fde("gap"),h=fde("gradientColorStops"),f=fde("gradientColorStopPositions"),m=fde("inset"),g=fde("margin"),y=fde("opacity"),b=fde("padding"),v=fde("saturate"),k=fde("scale"),w=fde("sepia"),x=fde("skew"),E=fde("space"),_=fde("translate"),S=()=>["auto",Nde,t],T=()=>[Nde,t],C=()=>["",Ede,_de],A=()=>["auto",Sde,Nde],N=()=>["","0",Nde],I=()=>[Sde,Nde];return{cacheSize:500,separator:":",theme:{colors:[Fde],spacing:[Ede,_de],blur:["none","",Ide,Nde],brightness:I(),borderColor:[e],borderRadius:["none","","full",Ide,Nde],borderSpacing:T(),borderWidth:C(),contrast:I(),grayscale:N(),hueRotate:I(),invert:N(),gap:T(),gradientColorStops:[e],gradientColorStopPositions:[Ade,_de],inset:S(),margin:S(),opacity:I(),padding:T(),saturate:I(),scale:I(),sepia:N(),skew:I(),space:T(),translate:T()},classGroups:{aspect:[{aspect:["auto","square","video",Nde]}],container:["container"],columns:[{columns:[Ide]}],"break-after":[{"break-after":["auto","avoid","all","avoid-page","page","left","right","column"]}],"break-before":[{"break-before":["auto","avoid","all","avoid-page","page","left","right","column"]}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top",Nde]}],overflow:[{overflow:["auto","hidden","clip","visible","scroll"]}],"overflow-x":[{"overflow-x":["auto","hidden","clip","visible","scroll"]}],"overflow-y":[{"overflow-y":["auto","hidden","clip","visible","scroll"]}],overscroll:[{overscroll:["auto","contain","none"]}],"overscroll-x":[{"overscroll-x":["auto","contain","none"]}],"overscroll-y":[{"overscroll-y":["auto","contain","none"]}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[m]}],"inset-x":[{"inset-x":[m]}],"inset-y":[{"inset-y":[m]}],start:[{start:[m]}],end:[{end:[m]}],top:[{top:[m]}],right:[{right:[m]}],bottom:[{bottom:[m]}],left:[{left:[m]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Cde,Nde]}],basis:[{basis:S()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Nde]}],grow:[{grow:N()}],shrink:[{shrink:N()}],order:[{order:["first","last","none",Cde,Nde]}],"grid-cols":[{"grid-cols":[Fde]}],"col-start-end":[{col:["auto",{span:["full",Cde,Nde]},Nde]}],"col-start":[{"col-start":A()}],"col-end":[{"col-end":A()}],"grid-rows":[{"grid-rows":[Fde]}],"row-start-end":[{row:["auto",{span:[Cde,Nde]},Nde]}],"row-start":[{"row-start":A()}],"row-end":[{"row-end":A()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",Nde]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",Nde]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal","start","end","center","between","around","evenly","stretch"]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal","start","end","center","between","around","evenly","stretch","baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":["start","end","center","between","around","evenly","stretch","baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[b]}],px:[{px:[b]}],py:[{py:[b]}],ps:[{ps:[b]}],pe:[{pe:[b]}],pt:[{pt:[b]}],pr:[{pr:[b]}],pb:[{pb:[b]}],pl:[{pl:[b]}],m:[{m:[g]}],mx:[{mx:[g]}],my:[{my:[g]}],ms:[{ms:[g]}],me:[{me:[g]}],mt:[{mt:[g]}],mr:[{mr:[g]}],mb:[{mb:[g]}],ml:[{ml:[g]}],"space-x":[{"space-x":[E]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[E]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Nde,t]}],"min-w":[{"min-w":[Nde,t,"min","max","fit"]}],"max-w":[{"max-w":[Nde,t,"none","full","min","max","fit","prose",{screen:[Ide]},Ide]}],h:[{h:[Nde,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Nde,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Nde,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Nde,t,"auto","min","max","fit"]}],"font-size":[{text:["base",Ide,_de]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Tde]}],"font-family":[{font:[Fde]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",Nde]}],"line-clamp":[{"line-clamp":["none",Sde,Tde]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Ede,Nde]}],"list-image":[{"list-image":["none",Nde]}],"list-style-type":[{list:["none","disc","decimal",Nde]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[y]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[y]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:["solid","dashed","dotted","double","none","wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Ede,_de]}],"underline-offset":[{"underline-offset":["auto",Ede,Nde]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:T()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Nde]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Nde]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[y]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top",Pde]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",Ode]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},Lde]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[f]}],"gradient-via-pos":[{via:[f]}],"gradient-to-pos":[{to:[f]}],"gradient-from":[{from:[h]}],"gradient-via":[{via:[h]}],"gradient-to":[{to:[h]}],rounded:[{rounded:[o]}],"rounded-s":[{"rounded-s":[o]}],"rounded-e":[{"rounded-e":[o]}],"rounded-t":[{"rounded-t":[o]}],"rounded-r":[{"rounded-r":[o]}],"rounded-b":[{"rounded-b":[o]}],"rounded-l":[{"rounded-l":[o]}],"rounded-ss":[{"rounded-ss":[o]}],"rounded-se":[{"rounded-se":[o]}],"rounded-ee":[{"rounded-ee":[o]}],"rounded-es":[{"rounded-es":[o]}],"rounded-tl":[{"rounded-tl":[o]}],"rounded-tr":[{"rounded-tr":[o]}],"rounded-br":[{"rounded-br":[o]}],"rounded-bl":[{"rounded-bl":[o]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[y]}],"border-style":[{border:["solid","dashed","dotted","double","none","hidden"]}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[y]}],"divide-style":[{divide:["solid","dashed","dotted","double","none"]}],"border-color":[{border:[a]}],"border-color-x":[{"border-x":[a]}],"border-color-y":[{"border-y":[a]}],"border-color-s":[{"border-s":[a]}],"border-color-e":[{"border-e":[a]}],"border-color-t":[{"border-t":[a]}],"border-color-r":[{"border-r":[a]}],"border-color-b":[{"border-b":[a]}],"border-color-l":[{"border-l":[a]}],"divide-color":[{divide:[a]}],"outline-style":[{outline:["","solid","dashed","dotted","double","none"]}],"outline-offset":[{"outline-offset":[Ede,Nde]}],"outline-w":[{outline:[Ede,_de]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:C()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[y]}],"ring-offset-w":[{"ring-offset":[Ede,_de]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Ide,Mde]}],"shadow-color":[{shadow:[Fde]}],opacity:[{opacity:[y]}],"mix-blend":[{"mix-blend":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"]}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",Ide,Nde]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[u]}],invert:[{invert:[d]}],saturate:[{saturate:[v]}],sepia:[{sepia:[w]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[u]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[y]}],"backdrop-saturate":[{"backdrop-saturate":[v]}],"backdrop-sepia":[{"backdrop-sepia":[w]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[i]}],"border-spacing-x":[{"border-spacing-x":[i]}],"border-spacing-y":[{"border-spacing-y":[i]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Nde]}],duration:[{duration:I()}],ease:[{ease:["linear","in","out","in-out",Nde]}],delay:[{delay:I()}],animate:[{animate:["none","spin","ping","pulse","bounce",Nde]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[k]}],"scale-x":[{"scale-x":[k]}],"scale-y":[{"scale-y":[k]}],rotate:[{rotate:[Cde,Nde]}],"translate-x":[{"translate-x":[_]}],"translate-y":[{"translate-y":[_]}],"skew-x":[{"skew-x":[x]}],"skew-y":[{"skew-y":[x]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Nde]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Nde]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":T()}],"scroll-mx":[{"scroll-mx":T()}],"scroll-my":[{"scroll-my":T()}],"scroll-ms":[{"scroll-ms":T()}],"scroll-me":[{"scroll-me":T()}],"scroll-mt":[{"scroll-mt":T()}],"scroll-mr":[{"scroll-mr":T()}],"scroll-mb":[{"scroll-mb":T()}],"scroll-ml":[{"scroll-ml":T()}],"scroll-p":[{"scroll-p":T()}],"scroll-px":[{"scroll-px":T()}],"scroll-py":[{"scroll-py":T()}],"scroll-ps":[{"scroll-ps":T()}],"scroll-pe":[{"scroll-pe":T()}],"scroll-pt":[{"scroll-pt":T()}],"scroll-pr":[{"scroll-pr":T()}],"scroll-pb":[{"scroll-pb":T()}],"scroll-pl":[{"scroll-pl":T()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Nde]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Ede,_de,Tde]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}}));function Gde(...e){return $de(W4(e))}const Vde=e=>e?"":void 0,qde=Oue("",{variants:{slot:{root:["bg-gray-50 dark:bg-transparent","border border-transparent dark:border-gray-dark-700","rounded-md p-0.5 flex items-center !ml-auto"],button:[Gde(Due({size:"xs"}),"group","rounded data-[active]:shadow","bg-transparent data-[active]:bg-white","text-gray-600 data-[active]:text-gray-800","dark:text-white-alpha-600 dark:data-[active]:text-white-alpha-950","dark:data-[active]:bg-gray-dark-700 dark:shadow-none","hover:text-gray-800 hover:dark:text-white-alpha-950")],icon:["mr-1 text-gray-500 data-[active]:text-gray-600","dark:text-white-alpha-500 dark:data-[active]:text-white-alpha-600","group-hover:text-gray-600 dark:group-hover:text-white-alpha-600"]}}}),Wde={markdownH1:Gde(Hue({size:"lg"}),"mb-3"),markdownH2:Gde(Hue({size:"md"}),"mb-2"),markdownP:Gde("mb-3 break-words whitespace-pre-wrap","[&+ol,&+li]:mt-0"),markdownLi:Gde("[&_a]:break-words [&_a]:inline"),markdownUl:Uue({style:"unordered"}),markdownOl:Gde(Uue({style:"ordered"}),"[inset-inline-start:var(--start,0px)]","[counter-reset:item_calc(var(--start,0)_-_1)]"),markdownLink:Gde(zue(),"text-inkeep-primary-stronger hover:text-inkeep-primary-strong","dark:text-inkeep-expanded-primary-100 dark:hover:text-inkeep-expanded-primary-300"),markdownSourceLink:Gue(),markdownTable:$ue({slot:"root"}),markdownTh:$ue({slot:"th"}),markdownTd:$ue({slot:"td"}),markdownCode:Vue(),codeblockContainer:que({slot:"container"}),codeblockHeader:que({slot:"header"}),codeblockCopyButton:Gde(Due({}),que({slot:"copyButton"})),codeblockHighlighterWrapper:Gde(),codeblockHighlighter:que({slot:"highlighter"}),codeblockCode:"font-mono",markdownInput:Gde("mr-1")},Yde=["Thinking","Looking for content","Analyzing"];function Kde(){const[e,t]=K.useState(0);return K.useEffect((()=>{const e=setInterval((()=>{t((t=>t+1<Yde.length?t+1:(clearInterval(e),t)))}),3500);return()=>clearInterval(e)}),[]),Wh.jsxs("div",{className:"flex items-center space-x-2 font-medium text-sm text-gray-700 dark:text-gray-dark-300","aria-live":"polite",children:[Wh.jsx("span",{className:"animate-shimmer bg-[linear-gradient(to_bottom_right,_var(--ikp-color-gray-700),_var(--ikp-color-gray-400))] dark:bg-[linear-gradient(to_bottom_right,_var(--ikp-color-gray-dark-300),_var(--ikp-color-gray-dark-100))] bg-clip-text text-transparent",children:Yde[e]}),Wh.jsx("div",{className:"flex space-x-1",children:[0,1,2].map((e=>Wh.jsx("span",{className:"animate-bounce-dot opacity-30",style:{animationDelay:.2*e+"s"},children:"."},e)))})]})}const Xde=()=>Array.from({length:3}).map(((e,t)=>{const n=t%2==0;return Wh.jsxs("div",{className:Gde("flex items-center flex-row-reverse","data-[even]:flex-row","[--end-color:theme(colors.white-alpha.100)]","dark:[--start-color:theme(colors.gray.300)]","dark:[--end-color:theme(colors.white-alpha.300)]"),"data-even":Vde(n),children:[Wh.jsx("div",{"data-even":Vde(n),className:Gde(Que(),"h-12 w-12 rounded-full","data-[even]:mr-4 ml-4 data-[even]:ml-0")}),Wh.jsxs("div",{"data-even":Vde(n),className:"flex flex-col gap-2 items-end data-[even]:items-start",children:[Wh.jsx("div",{"data-even":Vde(n),className:Gde(Que(),"h-4 rounded-lg w-60")}),Wh.jsx("div",{"data-even":Vde(n),className:Gde(Que(),"h-4 rounded-lg w-56")})]})]},t)})),Qde=e=>Wh.jsx(oP,{children:Wh.jsx(kP,{children:Wh.jsx(uL,{children:Wh.jsx(Uj,{...e})})})}),Zde=K.forwardRef((({className:e,size:t,variant:n,...r},a)=>Wh.jsx(n7,{ref:a,className:Gde(Pue({size:t,variant:n}),"data-[hidden]:hidden rounded-md flex","bg-white dark:bg-gray-dark-950","data-[composite]:w-full","max-h-[min(85vh,850px)]","[[data-sidebar]_&]:m-[unset] [[data-sidebar]_&]:mt-auto","[[data-sidebar]_&]:h-full [[data-sidebar]_&]:w-full","[[data-sidebar]_&]:max-h-[unset]",e),...r}))),Jde=({className:e,...t})=>Wh.jsx(a7,{className:Gde("flex flex-col items-center justify-center h-full gap-12 flex-1 p-8",e),children:Wh.jsx(Xde,{}),...t}),epe=({className:e,...t})=>Wh.jsx(i7,{className:Gde(Kue({section:"wrapper"}),"rounded-[inherit] font-body",e),...t}),tpe=({className:e,...t})=>Wh.jsx(s7,{className:Gde(Kue({section:"header"}),"flex items-center","bg-white dark:bg-gray-dark-950","data-[show-toolbar]:after:absolute","data-[show-toolbar]:after:left-0","data-[show-toolbar]:after:top-full","data-[show-toolbar]:after:h-[1rem]","data-[show-toolbar]:after:w-full","data-[show-toolbar]:after:text-white","data-[show-toolbar]:after:dark:text-gray-dark-950","data-[show-toolbar]:after:bg-[linear-gradient(currentColor,_transparent)]","data-[show-toolbar]:after:z-start",e),...t}),npe=({className:e,...t})=>Wh.jsx(l7,{className:Gde("flex items-center gap-3 w-full","px-5 py-2 pt-4 justify-between *:m-0",e),...t}),rpe=({className:e,...t})=>Wh.jsx(c7,{className:Gde("flex items-center gap-1.5",e),...t}),ape=({className:e,...t})=>Wh.jsx(d7,{className:Gde("text-gray-600 dark:text-gray-dark-100 text-sm",e),...t}),ope=({className:e,...t})=>Wh.jsx(p7,{className:Gde(Kue({section:"content"}),"justify-end",e),...t}),ipe=({className:e,...t})=>Wh.jsx(h7,{className:Gde("overflow-hidden",e),...t}),spe=K.forwardRef((({className:e,...t},n)=>Wh.jsx(m7,{ref:n,className:Gde("h-full w-full rounded-[inherit]",e),...t}))),lpe=({className:e,...t})=>Wh.jsx(g7,{className:Gde("flex select-none touch-none p-0.5","transition-colors duration-[160ms] ease-in-out","w-2.5 border-l border-l-transparent",e),...t}),cpe=({className:e,...t})=>Wh.jsx(y7,{className:Gde("relative flex-1 rounded-full","bg-gray-300 dark:bg-white-alpha-200",e),...t}),upe=b7,dpe=({className:e,...t})=>Wh.jsx(x7,{className:Gde("ml-auto text-sm flex items-center gap-1",e),...t}),ppe=({className:e,...t})=>Wh.jsx(_7,{className:Gde("text-gray-700 dark:text-gray-dark-100",e),...t}),hpe=({className:e,...t})=>Wh.jsx(T7,{className:Gde("cursor-pointer text-gray-700 dark:text-gray-dark-100","focus-visible:ring-gray-500 dark:focus-visible:ring-white-alpha-900 focus-visible:ring-2 focus:outline-none",e),...t}),fpe=({className:e,...t})=>Wh.jsx(A7,{className:Gde(Yue({slot:"content"}),"px-4 py-2 font-normal","w-[250px] sm:w-[420px]",e),...t}),mpe=I7,gpe=({className:e,...t})=>Wh.jsx(R7,{className:Gde(Yue({slot:"arrow"}),e),...t}),ype=({className:e,...t})=>Wh.jsx(P7,{className:Gde("mt-4 flex flex-col gap-2",e),...t}),bpe=({className:e,...t})=>Wh.jsx(L7,{className:Gde("text-2xs uppercase font-semibold tracking-widest","text-gray-600 dark:text-white-alpha-500",e),...t}),vpe=({className:e,...t})=>Wh.jsx(F7,{className:Gde("flex flex-col","ikp-md:flex-row","flex-wrap gap-2",e),...t}),kpe=K.forwardRef((({className:e,style:t,...n},r)=>{const a=K.useRef(null),o=jB(r,a),{width:i=0,height:s=0}=kue({ref:a,box:"border-box"}),l=Math.max(s,i);return Wh.jsx(B7,{ref:o,style:{"--before-size":`${l+100}px`,...t},className:Gde("flex items-center justify-center relative z-base","min-h-9 rounded-md overflow-hidden","before:absolute before:z-hide","before:bg-gray-300 dark:before:bg-gray-dark-950","before:bg-no-repeat before:[background-position:0_0]","before:[background-size:cover] before:m-auto","before:w-[--before-size] before:h-[--before-size]","data-[highlight]:first:before:[background-image:conic-gradient(transparent,theme(colors.inkeep-expanded-primary.600),transparent_30%)]","dark:data-[highlight]:first:before:[background-image:conic-gradient(transparent,theme(colors.inkeep-expanded-primary.300),transparent_30%)]","data-[highlight]:first:before:animate-[spin_4s_linear_infinite]","after:absolute after:z-base after:top-[1px] after:left-[1px]","after:w-[calc(100%-2px)] after:h-[calc(100%-2px)]","after:rounded-[5px] after:bg-white dark:after:bg-gray-dark-950",e),...n})})),wpe=({className:e,...t})=>Wh.jsx(H7,{className:Gde(Due({size:"sm"}),"text-sm font-normal h-auto w-full py-2 z-start","whitespace-normal text-center leading-[unset]","border border-solid","text-gray-800 dark:text-white-alpha-950","border-white-alpha-200","[&:where(:hover,:focus)]:bg-slate-400/5","dark:[&:where(:hover,:focus)]:bg-white-alpha-100 focus:z-start",e),...t}),xpe=({className:e,...t})=>Wh.jsx(k7,{className:Gde("flex flex-col w-full min-w-0 min-h-0 text-2sm relative",e),...t}),Epe=Oue(["flex relative w-full overflow-hidden py-8","px-5","flex-col ikp-md:flex-row","min-w-0 grow-[2] data-[role=user]:grow-0","[&:not(:last-child)]:after:absolute","[&:not(:last-child)]:after:border-b","[&:not(:last-child)]:after:bottom-0","[&:not(:last-child)]:after:inset-x-6","ikp-md:[&:not(:last-child)]:after:inset-x-8"]),_pe=({className:e,...t})=>Wh.jsx(V7,{className:Gde(Epe(),e),...t}),Spe=({className:e,...t})=>Wh.jsx(q7,{className:Gde(Epe(),e),...t}),Tpe=({className:e,...t})=>Wh.jsx(Y7,{className:Gde("flex justify-start overflow-hidden shrink-0 select-none","flex-row ikp-md:flex-col","items-center ikp-md:items-start","ikp-md:pl-3","ikp-md:pr-6","mb-6 ikp-md:mb-0",e),...t}),Cpe=({className:e,...t})=>Wh.jsx(X7,{className:Gde("flex items-center gap-3 h-12 w-full",e),children:Wh.jsx(Kde,{}),...t}),Ape=({className:e,...t})=>Wh.jsx(Z7,{className:Gde("flex items-center justify-center rounded-full","h-auto ikp-md:h-12",e),...t}),Npe=({className:e,...t})=>Wh.jsx(eee,{className:Gde("relative flex h-8 w-8 shrink-0 overflow-hidden","data-[username]:bg-inkeep-primary-lighter","dark:data-[username]:bg-inkeep-expanded-primary-300","text-inkeep-primary-stronger font-semibold ","data-[role=user]:hidden ikp-md:flex","justify-center items-center",e),...t}),Ipe=({className:e,...t})=>Wh.jsx(nee,{className:Gde("hidden data-[role=user]:block",e),...t}),Rpe=({className:e,...t})=>Wh.jsx(aee,{className:Gde("data-[type=icon]:data-[role=user]:text-inkeep-primary-medium","dark:data-[type=icon]:data-[role=user]:text-inkeep-expanded-primary-300","data-[type=icon]:data-[role=assistant]:[--start-color:theme(colors.inkeep-expanded-primary.300)]","data-[type=icon]:data-[role=assistant]:[--end-color:theme(colors.inkeep-expanded-primary.700)]","dark:data-[type=icon]:data-[role=assistant]:[--start-color:theme(colors.inkeep-expanded-primary.50)]","dark:data-[type=icon]:data-[role=assistant]:[--end-color:theme(colors.inkeep-expanded-primary.300)]",e),...t}),Ope=({className:e,...t})=>Wh.jsx(iee,{className:Gde("px-3 py-1 ml-4 data-[role=user]:ml-0","text-sm rounded-full","bg-inkeep-primary-lighter data-[role=user]:bg-gray-50","text-inkeep-primary-stronger dark:text-inkeep-expanded-primary-300","data-[role=user]:text-gray-700 dark:data-[role=user]:text-white-alpha-700","dark:bg-gray-dark-700","ikp-md:hidden",e),...t}),Ppe=({className:e,...t})=>Wh.jsx(lee,{className:Gde("overflow-hidden flex flex-col","justify-start grow-2 w-full","data-[role=user]:justify-end","data-[role=user]:shrink-2","data-[role=user]:grow-0","ikp-md:pr-3",e),...t}),Dpe=({className:e,...t})=>Wh.jsx(uee,{className:Gde("text-2sm flex-wrap break-words min-w-0 shrink-1 max-w-full",e),...t}),Lpe=e=>{var t,n;const{message:r}=lB(),a=null==(n=null==(t=r.metadata)?void 0:t.attributes)?void 0:n.attachments;return"user"===r.role&&(null==a?void 0:a.length)?Wh.jsx(aB,{children:Wh.jsx(dee,{...e})}):null},Mpe=({className:e,...t})=>Wh.jsx(hee,{className:Gde("flex flex-wrap gap-2",e),...t}),Fpe=({className:e,...t})=>Wh.jsx(mee,{className:Gde(Due({variant:"ghost"}),Lue({slot:"root"}),"font-normal px-2",e),...t}),jpe=({className:e,...t})=>Wh.jsx(yee,{className:Gde(Lue({slot:"icon"}),e),...t}),Bpe=({className:e,...t})=>Wh.jsx(vee,{className:Gde(Lue({slot:"title"}),e),...t}),zpe=e=>{const{onOpenChange:t,...n}=e,{selectItem:r,isOpen:a,onClose:o,selectedItem:i}=oB();return Wh.jsx(kee,{open:a&&null!==i,onOpenChange:L9(t,(e=>{e||(o(),r(null))})),...n})},Hpe=({className:e,...t})=>Wh.jsx(wee,{className:Gde(Wue({slot:"overlay"}),e),...t}),Upe=({className:e,...t})=>Wh.jsx(xee,{className:Gde(Wue({slot:"content"}),"my-6 md:my-12 top-0 left-[unset] transform-none relative","p-8 md:p-10 max-w-2xl",e),...t}),$pe=({className:e,...t})=>Wh.jsx(_ee,{className:Gde(Wue({slot:"header"}),"px-0 pt-0 pb-8 flex flex-col gap-6","font-semibold",e),...t}),Gpe=({className:e,...t})=>Wh.jsx(See,{className:Gde(Wue({slot:"close"}),e),...t}),Vpe=({className:e,...t})=>Wh.jsx(Cee,{className:Gde(Wue({slot:"body"}),"p-0",e),...t}),qpe=({className:e,componentStyles:t,...n})=>Wh.jsx(Nee,{className:Gde("data-[role=user]:whitespace-pre-wrap mb-3 max-w-full",e),componentStyles:Ph(Wde,t??{}),...n}),Wpe=({className:e,...t})=>Wh.jsx(Ree,{className:Gde("flex items-center mt-2 mb-3",e),...t}),Ype=({className:e,...t})=>Wh.jsx(Pee,{className:Gde("mr-auto flex items-center gap-2",e),...t}),Kpe=({className:e,...t})=>Wh.jsx(Mee,{className:Gde(Due({size:"xs",variant:"outline"}),"text-xs h-[30px] text-gray-700 dark:text-gray-200 gap-1",e),...t}),Xpe=({className:e,...t})=>Wh.jsx(jee,{className:Gde(Due({variant:"iconButton",size:"sm"}),"data-[upvoted]:text-inkeep-primary-medium","data-[downvoted]:text-inkeep-primary-medium","data-[upvoted]:dark:text-inkeep-expanded-primary-300","data-[downvoted]:dark:text-inkeep-expanded-primary-300","dark:hover:text-inkeep-expanded-primary-300 px-2 text-md",e),...t}),Qpe=e=>{var t;const{message:n}=lB();return"assistant"===n.role&&(null==(t=n.links)?void 0:t.length)?Wh.jsx(Bee,{...e}):null},Zpe=({className:e,...t})=>Wh.jsx(Hee,{className:Gde("block text-xs font-medium my-2 text-gray-700 dark:text-gray-dark-300",e),...t}),Jpe=({className:e,...t})=>Wh.jsx($ee,{className:Gde("w-full relative flex flex-col gap-3 py-[1px]",e),...t}),ehe=({className:e,...t})=>Wh.jsx(Vee,{className:Gde(Fue({slot:"root"}),e),...t}),the=({className:e,...t})=>Wh.jsx(Wee,{className:Gde(Fue({slot:"breadcrumbs"}),e),...t}),nhe=({className:e,...t})=>Wh.jsx(Yee,{className:Gde(Fue({slot:"breadcrumbsIcon"}),e),...t}),rhe=({className:e,...t})=>Wh.jsx(Xee,{className:Gde(Fue({slot:"icon"}),e),...t}),ahe=({className:e,...t})=>Wh.jsx(Zee,{className:Gde(Fue({slot:"title"}),e),...t}),ohe=({className:e,...t})=>Wh.jsx(ete,{className:Gde(Fue({slot:"tag"}),e),...t}),ihe=({className:e,...t})=>Wh.jsx(nte,{className:Gde(Fue({slot:"description"}),e),...t}),she=({className:e,...t})=>Wh.jsx(ate,{className:Gde(Fue({slot:"descriptionPart"}),e),...t}),lhe=({className:e,...t})=>Wh.jsx(ite,{className:Gde(Fue({slot:"indicator"}),e),...t}),che=({className:e,...t})=>Wh.jsx(ste,{className:Gde("bg-white dark:bg-gray-dark-950 pt-6 pb-4","px-5 relative","before:absolute before:block before:top-0 before:left-0","before:pointer-events-none before:w-full before:h-3","before:bg-[linear-gradient(transparent,_white)] dark:before:bg-[linear-gradient(transparent,_var(--ikp-color-gray-dark-950))]","before:-translate-y-full",e),...t}),uhe=({className:e,...t})=>Wh.jsx(lte,{className:Gde("relative flex flex-col w-full p-2","rounded-lg items-stretch shadow-md dark:shadow-none","bg-gray-50 dark:bg-white-alpha-50",e),...t}),dhe=({className:e,...t})=>Wh.jsx(cte,{className:Gde("flex",e),...t}),phe=K.forwardRef((({className:e,...t},n)=>Wh.jsx(dte,{ref:n,className:Gde("min-h-[unset] overflow-hidden w-full resize-none","placeholder:text-gray-500 dark:placeholder:text-gray-dark-200","border-none outline-none shadow-none bg-transparent","px-3 py-2 ml-1 mr-2 max-h-[200px] overflow-y-auto disabled:cursor-not-allowed",e),...t}))),hhe=({className:e,...t})=>Wh.jsx(hte,{className:Gde(Due({}),"bg-transparent relative size-10 rounded-lg transition-all ease-linear","text-inkeep-primary-medium dark:text-inkeep-expanded-primary-500","active:bg-gray-300 dark:active:bg-white-alpha-100","hover:bg-gray-200 hover:text-inkeep-primary-strong","dark:hover:bg-white-alpha-100 dark:hover:text-inkeep-expanded-primary-300","disabled:text-gray-500 dark:disabled:text-white-alpha-200","disabled:cursor-not-allowed hover:disabled:[background:none] active:disabled:[background:none]",e),...t}),fhe=({className:e,...t})=>Wh.jsx(fte,{className:Gde(jue(),"text-inherit rotate-[-30deg]",e),...t}),mhe=({className:e,...t})=>Wh.jsx(gte,{className:Gde("flex items-center justify-between","flex-wrap gap-2 px-1 pt-2 pb-1",e),...t}),ghe=({className:e,...t})=>Wh.jsx(bte,{className:Gde("flex items-center gap-2 flex-wrap px-3 min-w-0",e),...t}),yhe=({className:e,...t})=>Wh.jsx(kte,{className:Gde(Lue({slot:"root"}),e),...t}),bhe=({className:e,...t})=>Wh.jsx(xte,{className:Gde(Lue({slot:"icon"}),e),...t}),vhe=({className:e,...t})=>Wh.jsx(_te,{className:Gde(Lue({slot:"title"}),e),...t}),khe=({className:e,...t})=>Wh.jsx(Tte,{className:Gde(Lue({slot:"delete"}),e),...t}),whe=({className:e,...t})=>Wh.jsx(Cte,{className:Gde("flex items-center justify-between","gap-2 flex-wrap px-3",e),...t}),xhe=Ate,Ehe=({className:e,...t})=>Wh.jsx(Nte,{className:Gde("cursor-pointer text-sm text-gray-600","dark:text-white-alpha-600",e),...t}),_he=({className:e,...t})=>Wh.jsx(Rte,{className:Gde("bg-white text-gray-800 fill-white","dark:bg-gray-dark-800 dark:text-white-alpha-950 dark:fill-gray-dark-800","shadow-[0_8px_30px_rgba(0,0,0,0.12)] z-dropdown","px-3 py-2 rounded-md text-sm font-normal max-w-[200px]",e),...t}),She=({className:e,...t})=>Wh.jsx(Pte,{className:Gde("contents",e),...t}),The=({className:e,...t})=>Wh.jsx(Lte,{className:Gde(Due({variant:"outline",size:"xs"}),"light:text-gray-700 gap-1",e),...t}),Che=e=>{const{onOpenChange:t,...n}=e,{selectInput:r,isOpen:a,onClose:o,selectedInput:i}=qj();return Wh.jsx(Mte,{open:a&&null!==i,onOpenChange:L9(t,(e=>{e||(o(),r(null))})),...n})},Ahe=({className:e,...t})=>Wh.jsx(Fte,{className:Gde(Wue({slot:"overlay"}),e),...t}),Nhe=({className:e,...t})=>Wh.jsx(jte,{className:Gde(Wue({slot:"content"}),"my-6 md:my-12 top-0 left-[unset] transform-none relative","p-8 md:p-10 max-w-2xl",e),...t}),Ihe=({className:e,...t})=>Wh.jsx(Bte,{className:Gde(Wue({slot:"header"}),"px-0 pt-0 pb-8 gap-y-2","font-semibold",e),...t}),Rhe=({className:e,...t})=>Wh.jsx(Hte,{className:Gde("w-full semibold",e),...t}),Ohe=({className:e,...t})=>Wh.jsx($te,{className:Gde("text-gray-700 dark:text-white-alpha-700","text-sm font-normal w-full",e),...t}),Phe=e=>{var t;const{children:n,...r}=e,{selectedInput:a}=qj(),o=null==(t=null==a?void 0:a.workflowModalProps)?void 0:t.modalHelpElement;return o?Wh.jsx(Gte,{asChild:!n,children:n||o,...r}):null},Dhe=({className:e,...t})=>Wh.jsx(Vte,{className:Gde(Wue({slot:"close"}),e),...t}),Lhe=({className:e,...t})=>Wh.jsx(qte,{className:Gde(Wue({slot:"body"}),"p-0",e),...t}),Mhe=({className:e,...t})=>Wh.jsx(Yte,{className:Gde("flex flex-col gap-8",e),...t}),Fhe=({className:e,...t})=>Wh.jsx(Kte,{className:Gde("flex flex-col gap-2",e),...t}),jhe=({className:e,...t})=>Wh.jsx(Qte,{className:Gde("text-sm font-medium text-gray-700 dark:text-white-alpha-700",e),...t}),Bhe=({className:e,...t})=>Wh.jsx(Jte,{className:Gde("h-10 px-4 rounded-md border","focus:outline-none focus:[--shadow-color:theme(colors.blue.500)]","data-[invalid]:[--shadow-color:theme(colors.red.500)]","shadow-[0_0_0_2px_var(--shadow-color)]",e),...t}),zhe=({className:e,...t})=>Wh.jsx(tne,{className:Gde("text-sm text-red-500",e),...t}),Hhe=({className:e,...t})=>Wh.jsx(nne,{className:Gde("flex flex-col gap-2",e),...t}),Uhe=({className:e,...t})=>Wh.jsx(ane,{className:Gde("text-sm font-medium text-gray-700 dark:text-white-alpha-700",e),...t}),$he=({className:e,...t})=>Wh.jsx(ine,{className:Gde(Bue({size:"md",variant:"outline"}),"min-h-20 px-4 py-2",e),...t}),Ghe=({className:e,...t})=>Wh.jsx(lne,{className:Gde("text-sm text-red-500",e),...t}),Vhe=({className:e,...t})=>Wh.jsx(cne,{className:Gde(Due({preset:"neutralFilled"}),"ml-auto",e),...t}),qhe=({className:e,...t})=>Wh.jsx(une,{className:Gde("mt-4 flex items-start justify-between flex-wrap-reverse gap-2.5",e),...t}),Whe=({className:e,...t})=>Wh.jsx(dne,{className:Gde("flex items-center gap-2.5 flex-wrap",e),...t}),Yhe=({className:e,...t})=>Wh.jsx(pne,{className:Gde("flex items-center whitespace-nowrap",e),...t}),Khe=({className:e,...t})=>Wh.jsx(hne,{className:Gde("text-xs md:text-sm text-gray-500 dark:text-white-alpha-600",e),...t}),Xhe=({className:e,...t})=>Wh.jsx(fne,{className:Gde("text-gray-500 dark:text-white-alpha-600","w-5 ml-1.5 mr-0.5",e),...t}),Qhe=({className:e,...t})=>Wh.jsx(mne,{className:Gde(zue(),"inline-flex text-xs md:text-sm text-gray-500","dark:text-white-alpha-600 font-medium",e),...t}),Zhe=Gde(Due({size:"xs",variant:"outline"}),"text-gray-700 dark:text-white-alpha-700"),Jhe=({className:e,...t})=>Wh.jsx(yne,{className:Gde(Zhe,e),...t}),efe=({className:e,...t})=>Wh.jsx(vne,{className:Gde("cursor-pointer",e),...t}),tfe=({className:e,...t})=>Wh.jsx(wne,{className:Gde("bg-white text-gray-800 fill-white","dark:bg-gray-dark-800 dark:text-white-alpha-900 dark:fill-gray-dark-800","shadow-[0_8px_30px_rgba(0,0,0,0.12)]","px-2 py-3 rounded-md text-sm font-normal",e),...t}),nfe=e=>{const{children:t,...n}=e,{aiChatSettings:r}=nP(),{getHelpOptions:a}=r;if(!a||0===(a??[]).length)return null;const{_pinned:o,_unpinned:i}=a.reduce(((e,t)=>{const n=t.isPinnedToToolbar?"_pinned":"_unpinned";return{...e,[n]:[...e[n],t]}}),{_pinned:[],_unpinned:[]}),s=1===i.length?[...o,i[0]]:o,l=1===i.length?[]:i,c=function(){const[e,t]=K.useState(!1);return{open:e,setOpen:t}}();return Wh.jsx(eB,{value:c,children:Wh.jsx(xne,{open:c.open,onOpenChange:c.setOpen,children:CL(t,{pinned:s,unpinned:l}),...n})})},rfe=({className:e,...t})=>Wh.jsx(Sne,{className:Gde(Zhe,e),...t}),afe=({className:e,...t})=>Wh.jsx(Cne,{className:Gde(Zhe,e),...t}),ofe=({className:e,...t})=>Wh.jsx(Nne,{className:Gde(Yue({slot:"content"}),"gap-3 px-3 py-4 ","w-[254px] text-sm font-normal",e),...t}),ife=({className:e,...t})=>Wh.jsx(Ine,{className:Gde(Yue({slot:"arrow"}),e),...t}),sfe=({className:e,...t})=>Wh.jsx(Rne,{className:Gde("flex items-center cursor-pointer hover:underline",e),...t}),lfe=({className:e,...t})=>Wh.jsx(Pne,{className:Gde("mr-2 text-inkeep-primary-medium",e),...t}),cfe=e=>{const{onOpenChange:t,...n}=e,{currentFeedback:r,setCurrentFeedback:a}=PL();return Wh.jsx(Dne,{open:null!==r,onOpenChange:L9(t,(()=>a(null))),...n})},ufe=({className:e,...t})=>Wh.jsx(Lne,{className:Gde(Wue({slot:"overlay"}),e),...t}),dfe=({className:e,...t})=>Wh.jsx(Mne,{className:Gde(Wue({slot:"content"}),"my-6 md:my-12 top-0 left-[unset] transform-none relative","p-8 md:p-10 max-w-[480px]",e),...t}),pfe=({className:e,...t})=>Wh.jsx(Fne,{className:Gde(Wue({slot:"header"}),"px-0 pt-0 pb-8","font-semibold",e),...t}),hfe=({className:e,...t})=>Wh.jsx(jne,{className:Gde(Wue({slot:"close"}),e),...t}),ffe=({className:e,...t})=>Wh.jsx(Bne,{className:Gde(Wue({slot:"body"}),"p-0",e),...t}),mfe=({className:e,...t})=>Wh.jsx(Hne,{className:Gde("flex flex-col gap-8",e),...t}),gfe=({className:e,...t})=>Wh.jsx($ne,{className:Gde("flex flex-wrap items-center","gap-[1rem_0.5rem]",e),...t}),yfe=({className:e,...t})=>Wh.jsx(Vne,{className:Gde(Mue({slot:"root"}),e),...t}),bfe=({className:e,...t})=>Wh.jsx(qne,{className:Gde(Mue({slot:"indicator"}),e),...t}),vfe=({className:e,...t})=>Wh.jsx(Yne,{className:Gde("select-none cursor-pointer font-medium text-sm","text-gray-700 dark:text-white-alpha-700",e),...t}),kfe=({className:e,...t})=>Wh.jsx(Xne,{className:Gde("flex-[0_0_100%]","min-h-20 py-2 border rounded-md","px-4",e),...t}),wfe=({className:e,...t})=>Wh.jsx(Qne,{className:Gde(Due({preset:"neutralFilled"}),"ml-auto",e),...t}),xfe=({className:e,...t})=>Wh.jsx(Jne,{className:Gde("w-full overflow-y-auto",e),...t}),Efe=({className:e,...t})=>Wh.jsx(tre,{className:Gde(Kue({section:"content"}),"relative pt-4 pb-8 gap-8","items-start justify-center w-full","px-6 ikp-md:px-10 ikp-md:pb-14",e),...t}),_fe=({className:e,...t})=>Wh.jsx(rre,{className:Gde(Due({variant:"ghost"}),"absolute right-1 top-1","text-xl text-gray-500 dark:text-white-alpha-500 w-10 h-10 z-modal",e),...t}),Sfe=({className:e,...t})=>Wh.jsx(are,{className:Gde("mt-12 flex flex-col gap-6",e),...t}),Tfe=({className:e,...t})=>Wh.jsx(ire,{className:Gde("font-semibold text-xl leading-5",e),...t}),Cfe=({className:e,...t})=>Wh.jsx(lre,{className:Gde("text-gray-700 dark:text-white-alpha-700 text-sm",e),...t}),Afe=({className:e,...t})=>Wh.jsx(ure,{className:Gde("w-full",e),...t}),Nfe=({className:e,...t})=>Wh.jsx(pre,{className:Gde("mb-8 flex flex-col gap-2 data-[hidden]:hidden","data-[input-type=checkbox]:flex-row data-[input-type=checkbox]:items-center",e),...t}),Ife=({className:e,...t})=>Wh.jsx(fre,{className:Gde("font-medium text-sm text-gray-700","dark:text-white-alpha-700 ","font-medium relative","data-[required]:after:absolute",'data-[required]:after:[content:"*"]',"data-[required]:after:ml-1","data-[required]:after:mt-0","data-[required]:after:text-red-500","dark:data-[required]:after:text-red-300",e),...t}),Rfe=({className:e,...t})=>Wh.jsx(gre,{className:Gde(Bue({size:"md",variant:"outline"}),e),...t}),Ofe=({className:e,...t})=>Wh.jsx(yre,{className:Gde(Bue({size:"md",variant:"outline"}),e),...t}),Pfe=({className:e,...t})=>Wh.jsx(vre,{className:Gde(Bue({size:"md",variant:"outline"}),"text-sm pl-2 file:h-full file:cursor-pointer py-0","file:bg-transparent file:border-none file:font-medium","file:text-sm file:text-gray-700 dark:file:text-white-alpha-700",e),...t}),Dfe=({className:e,...t})=>Wh.jsx(kre,{className:Gde(Bue({size:"md",variant:"outline"}),"min-h-20 px-4 py-2",e),...t}),Lfe=({className:e,...t})=>Wh.jsx(xre,{className:Gde(Mue({slot:"root"}),e),...t}),Mfe=({className:e,...t})=>Wh.jsx(Ere,{className:Gde(Mue({slot:"indicator"}),e),...t}),Ffe=e=>{const{field:t,error:n,fieldProps:r}=Zj(),{onValueChange:a,...o}=e;return Wh.jsx(_re,{name:t.name,"data-invalid":SL(!!n),value:r.value,onValueChange:L9(a,r.onChange),...o})},jfe=({className:e,...t})=>Wh.jsx(Sre,{className:Gde(Xue({slot:"trigger"}),e),...t}),Bfe=e=>{const{field:t}=Zj();return Wh.jsx(Tre,{placeholder:"placeholder"in t?t.placeholder:void 0,...e})},zfe=({className:e,...t})=>Wh.jsx(Cre,{className:Gde("h-4 w-4 opacity-45",e),...t}),Hfe=({className:e,...t})=>Wh.jsx(Are,{className:Gde(Xue({slot:"content"}),e),...t}),Ufe=({className:e,...t})=>Wh.jsx(Nre,{className:Gde(Xue({slot:"viewport"}),e),...t}),$fe=({className:e,...t})=>Wh.jsx(Ire,{className:Gde(Xue({slot:"item"}),e),...t}),Gfe=Rre,Vfe=({className:e,...t})=>Wh.jsx(Ore,{className:Gde(Xue({slot:"itemIndicator"}),e),...t}),qfe=({className:e,...t})=>Wh.jsx(Dre,{className:Gde("text-sm flex items-center text-red-500 dark:text-red-300",e),...t}),Wfe=({className:e,...t})=>Wh.jsx(Mre,{className:Gde("text-red-500 dark:text-red-300",e),...t}),Yfe=({className:e,...t})=>Wh.jsx(Fre,{className:Gde("flex items-center justify-end gap-6 w-full",e),...t}),Kfe=({className:e,...t})=>Wh.jsx(Bre,{className:Gde(Due({variant:"outline"}),e),...t}),Xfe=({className:e,...t})=>Wh.jsx(Hre,{className:Gde(Due({preset:"neutralFilled"}),e),...t}),Qfe=({className:e,...t})=>Wh.jsx($re,{className:Gde("flex flex-col items-center justify-center h-auto","m-auto px-6 py-8 ikp-md:py-14 ikp-md:px-10",e),...t}),Zfe=({className:e,...t})=>Wh.jsx(Vre,{className:Gde("mb-6 font-bold tracking-tight","text-3xl md:text-4xl leading-6 md:leading-5",e),...t}),Jfe=e=>{var t;const{form:n}=dL();return Wh.jsx(qre,{children:null==(t=null==n?void 0:n.successView)?void 0:t.message,...e})},eme=({className:e,...t})=>Wh.jsx(Yre,{className:Gde(Due({preset:"neutralFilled"}),"w-full mt-12 gap-2 shrink-0",e),...t}),tme=({className:e,...t})=>Wh.jsx(Sae,{...t,className:Gde("w-[--width] h-full relative bg-white dark:bg-gray-dark-950","data-[position=left]:pr-1 data-[position=left]:border-r data-[position=left]:mr-1","data-[position=right]:pl-1 data-[position=right]:border-l data-[position=right]:ml-1","data-[state=open]:data-[position=left]:animate-sidebar-in-left","data-[state=open]:data-[position=right]:animate-sidebar-in-right","data-[state=closed]:data-[position=left]:animate-sidebar-out-left","data-[state=closed]:data-[position=right]:animate-sidebar-out-right",e)}),nme=({className:e,...t})=>Wh.jsx(Cae,{className:Gde("px-1 bg-transparent opacity-0 hover:opacity-100","cursor-ew-resize","absolute top-0 bottom-0 z-[1]",'[[data-position="left"]>&]:-right-1','[[data-position="right"]>&]:-left-1','after:content-[""] after:absolute after:top-0 after:bottom-0 after:w-0.5 after:bg-inkeep-primary-medium dark:after:bg-inkeep-primary-light [[data-position="right"]>&]:after:right-1 [[data-position="left"]>&]:after:left-1',"data-[state=closed]:opacity-0 data-[state=closed]:pointer-events-none","data-[state=open]:pointer-events-auto","transition-opacity duration-200",e),...t}),rme=({className:e,...t})=>Wh.jsx(Nae,{className:Gde(Kue({section:"header"}),"w-full flex flex-row items-center px-3 py-1.5","bg-white dark:bg-gray-dark-950","after:absolute","after:left-0","after:top-full","after:h-3","after:w-full","after:text-white","after:dark:text-gray-dark-950","after:bg-[linear-gradient(currentColor,_transparent)]","after:z-start",e),...t}),ame=({className:e,...t})=>Wh.jsx(Rae,{className:Gde(Due({variant:"ghost",size:"xs"}),"relative inset-[unset] w-6 ml-auto text-lg text-gray-500 dark:text-white-alpha-500 px-0",e),...t});function ome(){const{searchSettings:{tabs:e}}=nP();return Wh.jsxs("div",{className:"flex flex-col h-full",children:[Wh.jsxs("div",{className:Gde("h-[calc(100%-24px)]"),children:[Wh.jsx("div",{className:"flex px-5 py-1 gap-3 data-[hidden]:hidden","data-hidden":Vde(0===e.length),children:Array.from({length:2}).map(((e,t)=>Wh.jsx("div",{className:Gde(Que(),"h-[27.88px] w-16 rounded-full")},t)))}),Wh.jsxs("div",{className:"flex px-5 py-1 gap-5 h-full",children:[Wh.jsx("div",{className:"flex flex-col flex-1 [[data-view=dual-pane]_&]:flex-[0_0_44%]",children:Array.from({length:4}).map(((e,t)=>Wh.jsx("div",{className:"flex items-center pb-2.5 w-full",children:Wh.jsx("div",{className:Gde(Que(),"h-20 rounded-lg grow-[1]")})},t)))}),Wh.jsx("div",{className:Gde(Que(),"h-full w-full rounded-md","hidden [[data-view=dual-pane]_&]:block")})]})]}),Wh.jsx("div",{className:"flex pt-1 pb-3 px-5 justify-self-end",children:Wh.jsx("div",{className:Gde(Que(),"h-[24px] w-40 rounded-md")})})]})}const ime=e=>Wh.jsx(zoe,{...e}),sme=({className:e,...t})=>Wh.jsx(Nie,{className:Gde("data-[hidden]:hidden rounded-md flex","bg-white dark:bg-gray-dark-950",e),...t}),lme=({className:e,...t})=>Wh.jsx(Rie,{className:Gde("data-[hidden]:hidden flex flex-col w-full","[--footer-height:theme(spacing.9)]","data-[mobile]:[--input-height:theme(spacing.20)]","[--ask-ai-trigger-height:0px]","[[data-show-ask-ai-card]_&]:[--ask-ai-trigger-height:theme(spacing.11)]",e),...t}),cme=Pie,ume=({className:e,...t})=>Wh.jsx(Die,{className:Gde("flex items-center w-full px-5 pt-3 pb-3 gap-3","[[data-mobile]_&]:max-h-[var(--input-height)]",e),...t}),dme=({className:e,...t})=>Wh.jsx(Lie,{className:Gde("min-w-5 w-5 text-xl","text-gray-500 dark:text-white-alpha-600",e),...t}),pme=({className:e,...t})=>Wh.jsx(Fie,{className:Gde("min-h-[38px] overflow-hidden w-full resize-none","py-1.5 max-h-[10vh] placeholder:text-gray-500","w-full dark:placeholder:text-gray-dark-200","border-none outline-none shadow-none bg-transparent",e),...t}),hme=({className:e,...t})=>Wh.jsx(Bie,{className:Gde("min-w-5 w-5 text-xl","text-gray-500 dark:text-white-alpha-600","animate-spin",e),...t}),fme=({className:e,...t})=>Wh.jsx(Hie,{className:Gde(Fue({slot:"root"}),"mx-5 w-[calc(100%_-_theme(spacing.10))]","mb-4 h-11 cursor-pointer","h-[var(--ask-ai-trigger-height)]","grid-template-[none] flex items-center",e),...t}),mme=({className:e,...t})=>Wh.jsx($ie,{className:Gde("[grid-area:icon] h-5 w-5 flex-shrink-0","[--start-color:theme(colors.inkeep-expanded-primary.300)]","[--end-color:theme(colors.inkeep-expanded-primary.700)]","dark:[--start-color:theme(colors.inkeep-expanded-primary.50)]","dark:[--end-color:theme(colors.inkeep-expanded-primary.300)]",e),...t}),gme=({className:e,...t})=>Wh.jsx(Gie,{className:Gde(Fue({slot:"title"}),"font-medium text-gray-700",e),...t}),yme=({className:e,...t})=>Wh.jsx(Vie,{className:Gde("font-semibold !bg-clip-text text-transparent ml-2","animate-shine [background:linear-gradient(270deg,theme(colors.inkeep-primary.stronger-light),transparent)_-200%_50%_/_25%_100%_no-repeat,theme(colors.inkeep-expanded-primary.800)] ","dark:[background:linear-gradient(270deg,theme(colors.inkeep-expanded-primary.100),transparent)_-200%_50%_/_25%_100%_no-repeat,theme(colors.inkeep-expanded-primary.400)]",e),...t}),bme=({className:e,...t})=>Wh.jsx(qie,{className:Gde(Fue({slot:"indicator"}),"ml-1 opacity-100 text-inkeep-primary-stronger-light group-selected:text-inkeep-primary-strong dark:text-gray-dark-300 dark:group-selected:text-inkeep-expanded-primary-300 ",e),...t}),vme=({className:e,...t})=>Wh.jsx(Wie,{className:Gde("text-xs flex-shrink-0 ml-auto","group-selected:text-inkeep-primary-strong dark:text-gray-dark-300 dark:group-selected:text-inkeep-expanded-primary-300","text-inkeep-primary-medium-subtle bg-gray-500 bg-clip-text dark:bg-white-alpha-800",e),...t}),kme=({className:e,...t})=>Wh.jsx(Kie,{className:Gde(Kue({section:"content"}),"h-0 max-h-full","data-[has-content]:h-[min(calc(85vh_-_72px),calc(850px_-_72px_-_275px))]","md:data-[dual-pane-search-expanded]:h-[min(calc(85vh_-_72px),calc(900px_-_72px_-_135px))]","[[data-mobile]_&]:h-[calc(100vh-var(--input-height)-var(--footer-height)-var(--ask-ai-trigger-height))]","transition-all duration-250 ease-out data-[has-content]:pb-2",e),...t}),wme=({className:e,...t})=>Wh.jsx(Qie,{className:Gde("group mb-1 relative transition-all w-full h-full",e),children:Wh.jsx(ome,{}),...t}),xme=({className:e,...t})=>Wh.jsx(Jie,{className:Gde("flex w-full h-full","overflow-hidden relative grow-[2]","items-center justify-center text-gray-600","dark:text-gray-dark-400 mt-8",e),...t}),Eme=({className:e,...t})=>Wh.jsx(tse,{className:Gde("shrink-0 max-w-full","flex gap-3 px-5 pb-2 pt-0","overflow-x-auto [scrollbar-width:thin]",e),...t}),_me=({className:e,...t})=>Wh.jsx(rse,{className:Gde("px-3 text-1sm font-medium rounded-full shrink-0","py-1 transition-all duration-200 leading-snug","border border-gray-300 dark:border-gray-dark-500","hover:bg-gray-50 dark:hover:bg-white-alpha-50","data-[state=active]:bg-inkeep-primary-light-subtle","hover:data-[state=active]:bg-inkeep-primary-light-subtle","data-[state=active]:text-inkeep-expanded-primary-900","data-[state=active]:border-inkeep-primary-medium-subtle","dark:data-[state=active]:bg-white-alpha-100","dark:hover:data-[state=active]:bg-white-alpha-100","dark:data-[state=active]:text-inkeep-expanded-primary-300","dark:data-[state=active]:border-inkeep-expanded-primary-300","focus:outline-inkeep-expanded-primary-700 dark:focus:outline-inkeep-expanded-primary-300",e),...t}),Sme=({className:e,...t})=>Wh.jsx(ase,{className:Gde("flex overflow-hidden h-full",e),...t}),Tme=({className:e,...t})=>Wh.jsx(ise,{className:Gde("overflow-hidden h-full first:w-full","first:[[data-view=dual-pane]_&]:flex-1 md:first:[[data-view=dual-pane]_&]:flex-[0_0_44%]",'befter:content-[""] befter:absolute befter:inset-x-0',"befter:h-10 befter:pointer-events-none","befter:transition-opacity befter:duration-300","befter:ease-in-out ","before:top-0 after:bottom-0","before:bg-[linear-gradient(white,_transparent)] after:bg-[linear-gradient(transparent,_white)] ","dark:before:bg-[linear-gradient(var(--ikp-color-gray-dark-950),_transparent)] dark:after:bg-[linear-gradient(transparent,_var(--ikp-color-gray-dark-950))]","has-[[data-scroll-top]]:before:opacity-0","has-[[data-scroll-bottom]]:after:opacity-0",e),...t}),Cme=({className:e,...t})=>Wh.jsx(lse,{className:Gde("h-full w-full rounded-[inherit]",e),...t}),Ame=({className:e,...t})=>Wh.jsx(cse,{className:Gde("flex select-none touch-none p-0.5","transition-colors duration-[160ms] ease-in-out","w-2.5 border-l border-l-transparent",e),...t}),Nme=({className:e,...t})=>Wh.jsx(use,{className:Gde("relative flex-1 rounded-full","bg-gray-300 dark:bg-white-alpha-200",e),...t}),Ime=dse,Rme=({className:e,...t})=>Wh.jsx(hse,{className:Gde("w-full flex flex-col","items-center gap-2.5 h-full shrink-0","px-5 py-1 content-center -my-[1px]",e),...t}),Ome=({className:e,...t})=>Wh.jsx(mse,{className:Gde(Fue({slot:"root"}),e),...t}),Pme=({className:e,...t})=>Wh.jsx(yse,{className:Gde(Fue({slot:"breadcrumbs"}),e),...t}),Dme=({className:e,...t})=>Wh.jsx(bse,{className:Gde(Fue({slot:"breadcrumbsIcon"}),e),...t}),Lme=({className:e,...t})=>Wh.jsx(kse,{className:Gde(Fue({slot:"icon"}),e),...t}),Mme=({className:e,...t})=>Wh.jsx(xse,{className:Gde(Fue({slot:"title"}),e),...t}),Fme=({className:e,...t})=>Wh.jsx(_se,{className:Gde(Fue({slot:"tag"}),e),...t}),jme=({className:e,...t})=>Wh.jsx(Tse,{className:Gde(Fue({slot:"description"}),e),...t}),Bme=({className:e,...t})=>Wh.jsx(Ase,{className:Gde(Fue({slot:"descriptionPart"}),e),...t}),zme=({className:e,...t})=>Wh.jsx(Ise,{className:Gde(Fue({slot:"indicator"}),e),...t}),Hme=({className:e,...t})=>Wh.jsx(Ose,{className:Gde("flex-1 min-w-0 break-words pt-3 pb-4 pr-10 pl-5","hidden md:flex flex-col gap-6",e),...t}),Ume=({className:e,...t})=>Wh.jsx(Pse,{className:Gde("flex flex-col gap-5",e),...t}),$me=({className:e,...t})=>Wh.jsx(Lse,{className:Gde("inline-block",e),...t}),Gme=({className:e,...t})=>Wh.jsx(Fse,{className:Gde("text-3xl leading-snug tracking-tight","font-semibold hover:text-inkeep-primary-stronger","dark:hover:text-inkeep-expanded-primary-100",e),...t}),Vme=({className:e,...t})=>Wh.jsx(Bse,{className:Gde("inline-block ml-2 mb-2 tracking-tight text-gray-500 dark:text-white-alpha-500",e),...t}),qme=({className:e,...t})=>Wh.jsx(zse,{className:Gde(Fue({slot:"breadcrumbs"}),"!line-clamp-none whitespace-normal text-gray-500 dark:text-gray-dark-200 text-sm",e),...t}),Wme=({className:e,...t})=>Wh.jsx(Hse,{className:Gde(Fue({slot:"breadcrumbsIcon"}),e),...t}),Yme=({className:e,componentStyles:t,...n})=>Wh.jsx($se,{className:Gde("max-w-full text-gray-700 dark:text-gray-dark-100 [&_em]:font-bold [&_em]:not-italic",e),componentStyles:Ph(Wde,t??{}),...n}),Kme=({className:e,...t})=>Wh.jsx(Vse,{className:Gde("flex flex-col gap-3",e),...t}),Xme=({className:e,...t})=>Wh.jsx(qse,{className:Gde("text-xs uppercase font-semibold tracking-widest","text-gray-500 dark:text-white-alpha-500",e),...t}),Qme=({className:e,...t})=>Wh.jsx(Yse,{className:Gde("flex flex-col gap-4",e),...t}),Zme=({className:e,...t})=>Wh.jsx(Xse,{className:Gde("flex items-center gap-1 text-gray-600 dark:text-white-alpha-600 font-medium ",""+(t.href?"cursor-pointer hover:text-gray-800 dark:hover:text-white-alpha-800 dark:data-[is-match]:hover:text-inkeep-expanded-primary-200 data-[is-match]:hover:text-inkeep-expanded-primary-800 ":""),"data-[is-match]:text-inkeep-expanded-primary-700","dark:data-[is-match]:text-inkeep-expanded-primary-300",e),...t}),Jme=({className:e,...t})=>Wh.jsx(Qse,{className:Gde(e),...t}),ege=({className:e,...t})=>Wh.jsx(Jse,{className:Gde(e),...t}),tge=({className:e,...t})=>Wh.jsx(ele,{className:Gde("h-3 !min-h-0 !min-w-0",e),...t}),nge=({className:e,...t})=>Wh.jsx(nle,{className:Gde("justify-self-end","px-5 pt-1 pb-3","[[data-mobile]_&]:py-0","[[data-mobile]_&]:items-center","[[data-mobile]_&]:h-[var(--footer-height)]","hidden data-[has-results]:flex",e),...t}),rge=({className:e,...t})=>Wh.jsx(rle,{className:Gde("flex items-center whitespace-nowrap",e),...t}),age=({className:e,...t})=>Wh.jsx(ale,{className:Gde("text-xs md:text-sm text-gray-500 dark:text-white-alpha-600",e),...t}),oge=({className:e,...t})=>Wh.jsx(ole,{className:Gde("text-gray-500 dark:text-white-alpha-600","w-5 ml-1.5 mr-0.5",e),...t}),ige=({className:e,...t})=>Wh.jsx(ile,{className:Gde(zue(),"inline-flex text-xs md:text-sm text-gray-500","dark:text-white-alpha-600 font-medium",e),...t}),sge=e=>{const{onOpenChange:t,config:n,...r}=e,a=(e=>{const{isOpen:t,onOpenChange:n,defaultOpen:r=!1,shortcutKey:a,triggerSelector:o="[data-inkeep-modal-trigger]"}=e??{},{logEvent:i}=bP(),[s=r,l]=OB({prop:t,defaultProp:t,onChange:n});Kre({triggerSelector:o,onTriggerClick:()=>l(!s)});const c=K.useRef(!0);return K.useEffect((()=>{c.current?c.current=!1:i({eventName:s?"modal_opened":"modal_closed",properties:{}})}),[s]),K.useEffect((()=>{const e=e=>{a&&(e.metaKey||e.ctrlKey)&&e.key.toLowerCase()===a.toLowerCase()&&(e.preventDefault(),e.stopPropagation(),l(!0)),"Escape"===e.key&&t&&(e.preventDefault(),l(!1))};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)}),[a,l,t]),{isOpen:s,setOpen:l,shortcutKey:a}})(n);return Wh.jsx(oL,{modal:a,children:Wh.jsx(sle,{open:a.isOpen,onOpenChange:L9(t,(e=>a.setOpen(e))),...r})})},lge=({className:e,...t})=>Wh.jsx(lle,{className:Gde(Wue({slot:"overlay"}),e),...t}),cge=({className:e,...t})=>Wh.jsx(ule,{className:Gde(Wue({slot:"content"}),"w-[min(90vw,720px)]","has-[[data-dual-pane-search-expanded]]:w-[min(90vw,1000px)] transition-width duration-300",e),...t}),uge=({className:e,...t})=>Wh.jsx(ple,{className:Gde(Wue({slot:"close"}),Due({variant:"ghost",size:"xs"}),"relative inset-[unset] w-6 ml-auto text-lg text-gray-500 dark:text-white-alpha-500 px-0","md:hidden",e),...t}),dge=({className:e,...t})=>Wh.jsx(eue,{className:Gde("fixed right-6 bottom-6 z-50 mr-[var(--removed-body-scroll-bar-size)]",e),...t}),pge=({className:e,...t})=>Wh.jsx(tue,{className:Gde("bg-inkeep-primary-text-bold dark:bg-gray-dark-600 rounded-full px-[18px] py-3 text-white font-medium flex items-center space-x-2 shadow-2xl dark:shadow-none transition-transform ease-in-out hover:scale-110",e),...t}),hge=({className:e,...t})=>Wh.jsx(nue,{className:Gde("flex items-center",e),...t}),fge=({className:e,...t})=>Wh.jsx(oue,{className:Gde("data-[type=icon]:[--start-color:theme(colors.inkeep-expanded-primary.50)]","data-[type=icon]:[--end-color:theme(colors.inkeep-expanded-primary.300)]","h-6 w-6",e),...t}),mge=({className:e,...t})=>Wh.jsx(rue,{className:Gde("",e),...t}),gge=({className:e,...t})=>Wh.jsx(iue,{className:Gde("md:min-w-[min(320px,100%)] w-full h-full min-h-9",e),...t}),yge=({className:e,...t})=>Wh.jsx(sue,{className:Gde("rounded-md border px-3 min-w-0 min-h-9 flex items-center justify-between gap-2 h-full w-full hover:border-gray-300 dark:hover:border-white-alpha-300 transition-colors",e),...t}),bge=({className:e,...t})=>Wh.jsx(lue,{className:Gde("flex items-center gap-2 min-w-0",e),...t}),vge=({className:e,...t})=>Wh.jsx(uue,{className:Gde("text-md text-gray-500 dark:text-white-alpha-600",e),...t}),kge=({className:e,...t})=>Wh.jsx(due,{className:Gde("text-gray-500 dark:text-white-alpha-600 text-xl",e),...t}),wge=({className:e,...t})=>Wh.jsx(pue,{className:Gde("text-sm text-gray-400 dark:text-white-alpha-500 font-bold flex items-center gap-0.5",e),...t}),xge=({className:e,...t})=>Wh.jsx(bue,{className:Gde("",e),...t}),Ege=({className:e,...t})=>Wh.jsx(fue,{className:Gde("",e),...t}),_ge=e=>Wh.jsx(kle,{...e}),Sge=({className:e,...t})=>Wh.jsx(Tle,{className:Gde("max-w-full border divide-y","rounded-xl shadow h-full max-h-full","bg-white dark:bg-gray-dark-950","flex flex-col",e),...t}),Tge=({className:e,...t})=>Wh.jsx(Cle,{className:Gde("px-5 py-4 font-medium shrink-0",e),...t}),Cge=({className:e,...t})=>Wh.jsx(Ale,{className:Gde("flex-1 overflow-hidden",e),...t}),Age=({className:e,...t})=>Wh.jsx(Nle,{className:Gde("h-full",e),...t}),Nge=({className:e,...t})=>Wh.jsx(Rle,{className:Gde("h-full w-full rounded-[inherit] px-5","[&_[data-part=grid]]:px-1","[&_[data-part=grid]]:divide-y",e),...t}),Ige=({className:e,...t})=>Wh.jsx(Ole,{className:Gde("flex select-none touch-none p-0.5","transition-colors duration-[160ms] ease-in-out","w-2.5 border-l border-l-transparent",e),...t}),Rge=({className:e,...t})=>Wh.jsx(Ple,{className:Gde("relative flex-1 rounded-full","bg-gray-300 dark:bg-white-alpha-200",e),...t}),Oge=Dle,Pge=({className:e,...t})=>Wh.jsx(Mle,{className:Gde("flex flex-col items-center","justify-center mx-1 pt-12 pb-6",e),...t}),Dge=({className:e,...t})=>Wh.jsx(jle,{className:Gde("w-6 h-6 text-green-500 mb-5",e),...t}),Lge=({className:e,...t})=>Wh.jsx(zle,{className:Gde("text-xl font-semibold","mb-3 tracking-tight",e),...t}),Mge=({className:e,...t})=>Wh.jsx(Ule,{className:Gde("text-gray-800 dark:text-white-alpha-950",e),...t}),Fge=({className:e,...t})=>Wh.jsx($le,{className:Gde("w-full flex flex-col py-6",e),...t}),jge=({className:e,...t})=>Wh.jsx(qle,{className:Gde("text-gray-700 dark:text-white-alpha-700 text-sm",e),...t}),Bge=({className:e,...t})=>Wh.jsx(Wle,{className:Gde("w-full gap-8",e),...t}),zge=({className:e,...t})=>Wh.jsx(Kle,{className:Gde(Due({preset:"neutralFilled",size:"sm"}),"ml-auto data-[loading]:cursor-wait","data-[submitted]:hidden",e),...t}),Hge=({className:e,...t})=>Wh.jsx(Qle,{className:Gde("mb-8 flex flex-col gap-2 data-[hidden]:hidden","data-[input-type=checkbox]:flex-row data-[input-type=checkbox]:items-center",e),...t}),Uge=({className:e,...t})=>Wh.jsx(Jle,{className:Gde("font-medium text-sm text-gray-700","dark:text-white-alpha-700 ","font-medium relative","data-[required]:after:absolute",'data-[required]:after:[content:"*"]',"data-[required]:after:ml-1","data-[required]:after:mt-0","data-[required]:after:text-red-500","dark:data-[required]:after:text-red-300",e),...t}),$ge=({className:e,...t})=>Wh.jsx(tce,{className:Gde(Bue({size:"sm",variant:"outline"}),e),...t}),Gge=({className:e,...t})=>Wh.jsx(nce,{className:Gde(Bue({size:"sm",variant:"outline"}),e),...t}),Vge=({className:e,...t})=>Wh.jsx(ace,{className:Gde(Bue({size:"sm",variant:"outline"}),"text-sm pl-2 file:h-full file:cursor-pointer py-0","file:bg-transparent file:border-none file:font-medium","file:text-sm file:text-gray-700 dark:file:text-white-alpha-700",e),...t}),qge=({className:e,...t})=>Wh.jsx(oce,{className:Gde(Bue({size:"sm",variant:"outline"}),"min-h-20 px-4 py-2",e),...t}),Wge=({className:e,...t})=>Wh.jsx(sce,{className:Gde(Mue({slot:"root"}),e),...t}),Yge=({className:e,...t})=>Wh.jsx(lce,{className:Gde(Mue({slot:"indicator"}),e),...t}),Kge=e=>{const{field:t,error:n,fieldProps:r}=_le(),{onValueChange:a,...o}=e;return Wh.jsx(cce,{name:t.name,"data-invalid":SL(!!n),value:r.value,onValueChange:L9(a,r.onChange),...o})},Xge=({className:e,...t})=>Wh.jsx(uce,{className:Gde(Xue({slot:"trigger"}),"text-sm",e),...t}),Qge=e=>{const{field:t}=_le();return Wh.jsx(dce,{placeholder:"placeholder"in t?t.placeholder:void 0,...e})},Zge=({className:e,...t})=>Wh.jsx(pce,{className:Gde("h-4 w-4 opacity-45",e),...t}),Jge=({className:e,...t})=>Wh.jsx(hce,{className:Gde(Xue({slot:"content"}),e),...t}),eye=({className:e,...t})=>Wh.jsx(fce,{className:Gde(Xue({slot:"viewport"}),e),...t}),tye=({className:e,...t})=>Wh.jsx(mce,{className:Gde(Xue({slot:"item"}),"text-sm",e),...t}),nye=gce,rye=({className:e,...t})=>Wh.jsx(yce,{className:Gde(Xue({slot:"itemIndicator"}),e),...t}),aye=({className:e,...t})=>Wh.jsx(vce,{className:Gde("text-sm flex items-center text-red-500 dark:text-red-300",e),...t}),oye=({className:e,...t})=>Wh.jsx(kce,{className:Gde("flex items-center gap-2",e),...t}),iye=({className:e,...t})=>Wh.jsx(wce,{className:Gde("border","bg-[linear-gradient(to_top,_var(--ikp-color-gray-100),_transparent)] dark:bg-[linear-gradient(to_top,_var(--ikp-color-gray-dark-600),_transparent)]","p-1 rounded-md","w-6 h-6 text-gray-600 dark:text-white-alpha-700",e),...t}),sye=({className:e,...t})=>Wh.jsx(Ece,{className:Gde("text-gray-800 dark:text-white-alpha-950 text-sm font-semibold",e),...t}),lye=({className:e,...t})=>Wh.jsx(Sce,{className:Gde("py-6 flex flex-wrap","gap-x-3 gap-y-6","[&>:first-child]:basis-full text-sm",e),...t}),cye=({className:e,...t})=>Wh.jsx(Cce,{className:Gde("w-full flex flex-col py-6 gap-6 min-w-0 text-sm",e),...t}),uye=({className:e,componentStyles:t,...n})=>Wh.jsx(Nce,{className:Gde("max-w-full ",e),componentStyles:Ph(Wde,t??{}),...n}),dye=({className:e,...t})=>Wh.jsx(Rce,{className:Gde(Due({preset:"neutralFilled",size:"sm"}),"ml-auto gap-2 data-[escalated]:hidden",e),...t}),pye=({className:e,...t})=>Wh.jsx(Oce,{className:Gde("",e),...t}),hye=Pce,fye=({className:e,...t})=>Wh.jsx(Lce,{className:Gde("w-full flex flex-col py-6 gap-6",e),...t}),mye=({className:e,...t})=>Wh.jsx(Fce,{className:Gde("text-gray-700 dark:text-white-alpha-700 text-sm",e),...t}),gye=({className:e,...t})=>Wh.jsx(Bce,{className:Gde("w-full gap-8",e),...t}),yye=({className:e,...t})=>Wh.jsx(Hce,{className:Gde(Due({preset:"neutralFilled",size:"sm"}),"ml-auto data-[loading]:cursor-wait","data-[submitted]:hidden",e),...t}),bye=({className:e,...t})=>Wh.jsx($ce,{className:Gde("text-red-500 dark:text-red-300",e),...t}),vye=({className:e,...t})=>Wh.jsx(Gce,{className:Gde("w-full flex flex-col gap-6",e),...t}),kye=({className:e,...t})=>Wh.jsx(Vce,{className:Gde("text-gray-700 dark:text-white-alpha-700 text-sm",e),...t}),wye=({className:e,...t})=>Wh.jsx(Wce,{className:Gde("w-full flex flex-wrap gap-2 items-center",e),...t}),xye=({className:e,...t})=>Wh.jsx(Kce,{className:Gde(Due({size:"xs",variant:"outline"}),"text-gray-600 dark:text-white-alpha-700 gap-1",e),...t}),Eye=({className:e,...t})=>Wh.jsx(Qce,{className:Gde("",e),...t}),_ye=({className:e,...t})=>Wh.jsx(Jce,{className:Gde("line-clamp-1",e),...t}),Sye=e=>Wh.jsx(GO,{styles:'*, ::before, ::after {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n --tw-contain-size: ;\n --tw-contain-layout: ;\n --tw-contain-paint: ;\n --tw-contain-style: ;\n}\n\n::backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n --tw-contain-size: ;\n --tw-contain-layout: ;\n --tw-contain-paint: ;\n --tw-contain-style: ;\n}/*\n! tailwindcss v3.4.17 | MIT License | https://tailwindcss.com\n*//*\n1. Prevent padding and border from affecting element width. (https://github.com/mozdevs/cssremedy/issues/4)\n2. Allow adding a border to an element by just adding a border-width. (https://github.com/tailwindcss/tailwindcss/pull/116)\n*/\n\n*,\n::before,\n::after {\n box-sizing: border-box; /* 1 */\n border-width: 0; /* 2 */\n border-style: solid; /* 2 */\n border-color: var(--ikp-color-gray-200); /* 2 */\n}\n\n::before,\n::after {\n --tw-content: \'\';\n}\n\n/*\n1. Use a consistent sensible line-height in all browsers.\n2. Prevent adjustments of font size after orientation changes in iOS.\n3. Use a more readable tab size.\n4. Use the user\'s configured `sans` font-family by default.\n5. Use the user\'s configured `sans` font-feature-settings by default.\n6. Use the user\'s configured `sans` font-variation-settings by default.\n7. Disable tap highlights on iOS\n*/\n\nhtml,\n:host {\n line-height: 1.5; /* 1 */\n -webkit-text-size-adjust: 100%; /* 2 */\n -moz-tab-size: 4; /* 3 */\n -o-tab-size: 4;\n tab-size: 4; /* 3 */\n font-family: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; /* 4 */\n font-feature-settings: normal; /* 5 */\n font-variation-settings: normal; /* 6 */\n -webkit-tap-highlight-color: transparent; /* 7 */\n}\n\n/*\n1. Remove the margin in all browsers.\n2. Inherit line-height from `html` so users can set them as a class directly on the `html` element.\n*/\n\nbody {\n margin: 0; /* 1 */\n line-height: inherit; /* 2 */\n}\n\n/*\n1. Add the correct height in Firefox.\n2. Correct the inheritance of border color in Firefox. (https://bugzilla.mozilla.org/show_bug.cgi?id=190655)\n3. Ensure horizontal rules are visible by default.\n*/\n\nhr {\n height: 0; /* 1 */\n color: inherit; /* 2 */\n border-top-width: 1px; /* 3 */\n}\n\n/*\nAdd the correct text decoration in Chrome, Edge, and Safari.\n*/\n\nabbr:where([title]) {\n -webkit-text-decoration: underline dotted;\n text-decoration: underline dotted;\n}\n\n/*\nRemove the default font size and weight for headings.\n*/\n\nh1,\nh2,\nh3,\nh4,\nh5,\nh6 {\n font-size: inherit;\n font-weight: inherit;\n}\n\n/*\nReset links to optimize for opt-in styling instead of opt-out.\n*/\n\na {\n color: inherit;\n text-decoration: inherit;\n}\n\n/*\nAdd the correct font weight in Edge and Safari.\n*/\n\nb,\nstrong {\n font-weight: bolder;\n}\n\n/*\n1. Use the user\'s configured `mono` font-family by default.\n2. Use the user\'s configured `mono` font-feature-settings by default.\n3. Use the user\'s configured `mono` font-variation-settings by default.\n4. Correct the odd `em` font sizing in all browsers.\n*/\n\ncode,\nkbd,\nsamp,\npre {\n font-family: var(--ikp-font-family-mono); /* 1 */\n font-feature-settings: normal; /* 2 */\n font-variation-settings: normal; /* 3 */\n font-size: 1em; /* 4 */\n}\n\n/*\nAdd the correct font size in all browsers.\n*/\n\nsmall {\n font-size: 80%;\n}\n\n/*\nPrevent `sub` and `sup` elements from affecting the line height in all browsers.\n*/\n\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\n/*\n1. Remove text indentation from table contents in Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=999088, https://bugs.webkit.org/show_bug.cgi?id=201297)\n2. Correct table border color inheritance in all Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=935729, https://bugs.webkit.org/show_bug.cgi?id=195016)\n3. Remove gaps between table borders by default.\n*/\n\ntable {\n text-indent: 0; /* 1 */\n border-color: inherit; /* 2 */\n border-collapse: collapse; /* 3 */\n}\n\n/*\n1. Change the font styles in all browsers.\n2. Remove the margin in Firefox and Safari.\n3. Remove default padding in all browsers.\n*/\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: inherit; /* 1 */\n font-feature-settings: inherit; /* 1 */\n font-variation-settings: inherit; /* 1 */\n font-size: 100%; /* 1 */\n font-weight: inherit; /* 1 */\n line-height: inherit; /* 1 */\n letter-spacing: inherit; /* 1 */\n color: inherit; /* 1 */\n margin: 0; /* 2 */\n padding: 0; /* 3 */\n}\n\n/*\nRemove the inheritance of text transform in Edge and Firefox.\n*/\n\nbutton,\nselect {\n text-transform: none;\n}\n\n/*\n1. Correct the inability to style clickable types in iOS and Safari.\n2. Remove default button styles.\n*/\n\nbutton,\ninput:where([type=\'button\']),\ninput:where([type=\'reset\']),\ninput:where([type=\'submit\']) {\n -webkit-appearance: button; /* 1 */\n background-color: transparent; /* 2 */\n background-image: none; /* 2 */\n}\n\n/*\nUse the modern Firefox focus style for all focusable elements.\n*/\n\n:-moz-focusring {\n outline: auto;\n}\n\n/*\nRemove the additional `:invalid` styles in Firefox. (https://github.com/mozilla/gecko-dev/blob/2f9eacd9d3d995c937b4251a5557d95d494c9be1/layout/style/res/forms.css#L728-L737)\n*/\n\n:-moz-ui-invalid {\n box-shadow: none;\n}\n\n/*\nAdd the correct vertical alignment in Chrome and Firefox.\n*/\n\nprogress {\n vertical-align: baseline;\n}\n\n/*\nCorrect the cursor style of increment and decrement buttons in Safari.\n*/\n\n::-webkit-inner-spin-button,\n::-webkit-outer-spin-button {\n height: auto;\n}\n\n/*\n1. Correct the odd appearance in Chrome and Safari.\n2. Correct the outline style in Safari.\n*/\n\n[type=\'search\'] {\n -webkit-appearance: textfield; /* 1 */\n outline-offset: -2px; /* 2 */\n}\n\n/*\nRemove the inner padding in Chrome and Safari on macOS.\n*/\n\n::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n/*\n1. Correct the inability to style clickable types in iOS and Safari.\n2. Change font properties to `inherit` in Safari.\n*/\n\n::-webkit-file-upload-button {\n -webkit-appearance: button; /* 1 */\n font: inherit; /* 2 */\n}\n\n/*\nAdd the correct display in Chrome and Safari.\n*/\n\nsummary {\n display: list-item;\n}\n\n/*\nRemoves the default spacing and border for appropriate elements.\n*/\n\nblockquote,\ndl,\ndd,\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\nhr,\nfigure,\np,\npre {\n margin: 0;\n}\n\nfieldset {\n margin: 0;\n padding: 0;\n}\n\nlegend {\n padding: 0;\n}\n\nol,\nul,\nmenu {\n list-style: none;\n margin: 0;\n padding: 0;\n}\n\n/*\nReset default styling for dialogs.\n*/\ndialog {\n padding: 0;\n}\n\n/*\nPrevent resizing textareas horizontally by default.\n*/\n\ntextarea {\n resize: vertical;\n}\n\n/*\n1. Reset the default placeholder opacity in Firefox. (https://github.com/tailwindlabs/tailwindcss/issues/3300)\n2. Set the default placeholder color to the user\'s configured gray 400 color.\n*/\n\ninput::-moz-placeholder, textarea::-moz-placeholder {\n opacity: 1; /* 1 */\n color: var(--ikp-color-gray-400); /* 2 */\n}\n\ninput::placeholder,\ntextarea::placeholder {\n opacity: 1; /* 1 */\n color: var(--ikp-color-gray-400); /* 2 */\n}\n\n/*\nSet the default cursor for buttons.\n*/\n\nbutton,\n[role="button"] {\n cursor: pointer;\n}\n\n/*\nMake sure disabled buttons don\'t get the pointer cursor.\n*/\n:disabled {\n cursor: default;\n}\n\n/*\n1. Make replaced elements `display: block` by default. (https://github.com/mozdevs/cssremedy/issues/14)\n2. Add `vertical-align: middle` to align replaced elements more sensibly by default. (https://github.com/jensimmons/cssremedy/issues/14#issuecomment-634934210)\n This can trigger a poorly considered lint error in some tools but is included by design.\n*/\n\nimg,\nsvg,\nvideo,\ncanvas,\naudio,\niframe,\nembed,\nobject {\n display: block; /* 1 */\n vertical-align: middle; /* 2 */\n}\n\n/*\nConstrain images and videos to the parent width and preserve their intrinsic aspect ratio. (https://github.com/mozdevs/cssremedy/issues/14)\n*/\n\nimg,\nvideo {\n max-width: 100%;\n height: auto;\n}\n\n/* Make elements with the HTML hidden attribute stay hidden by default */\n[hidden]:where(:not([hidden="until-found"])) {\n display: none;\n}\n.container {\n width: 100%;\n}\n@media (min-width: 640px) {\n\n .container {\n max-width: 640px;\n }\n}\n@media (min-width: 768px) {\n\n .container {\n max-width: 768px;\n }\n}\n@media (min-width: 1024px) {\n\n .container {\n max-width: 1024px;\n }\n}\n@media (min-width: 1280px) {\n\n .container {\n max-width: 1280px;\n }\n}\n@media (min-width: 1536px) {\n\n .container {\n max-width: 1536px;\n }\n}\n.pointer-events-none {\n pointer-events: none;\n}\n.fixed {\n position: fixed;\n}\n.absolute {\n position: absolute;\n}\n.relative {\n position: relative;\n}\n.inset-0 {\n inset: 0px;\n}\n.inset-\\[unset\\] {\n inset: unset;\n}\n.bottom-0 {\n bottom: 0px;\n}\n.bottom-6 {\n bottom: 1.5rem;\n}\n.left-0 {\n left: 0px;\n}\n.left-1\\/2 {\n left: 50%;\n}\n.left-\\[unset\\] {\n left: unset;\n}\n.right-1 {\n right: 0.25rem;\n}\n.right-2 {\n right: 0.5rem;\n}\n.right-3 {\n right: 0.75rem;\n}\n.right-6 {\n right: 1.5rem;\n}\n.top-0 {\n top: 0px;\n}\n.top-1 {\n top: 0.25rem;\n}\n.top-1\\/2 {\n top: 50%;\n}\n.top-2 {\n top: 0.5rem;\n}\n.top-\\[5\\%\\] {\n top: 5%;\n}\n.z-50 {\n z-index: 50;\n}\n.z-\\[1\\] {\n z-index: 1;\n}\n.z-base {\n z-index: var(--ikp-z-index-base);\n}\n.z-dropdown {\n z-index: var(--ikp-z-index-dropdown);\n}\n.z-modal {\n z-index: var(--ikp-z-index-modal);\n}\n.z-overlay {\n z-index: var(--ikp-z-index-overlay);\n}\n.z-popover {\n z-index: var(--ikp-z-index-popover);\n}\n.z-start {\n z-index: var(--ikp-z-index-start);\n}\n.m-\\[0px_0px_0\\.5em\\] {\n margin: 0px 0px 0.5em;\n}\n.m-auto {\n margin: auto;\n}\n.-my-\\[1px\\] {\n margin-top: -1px;\n margin-bottom: -1px;\n}\n.mx-1 {\n margin-left: 0.25rem;\n margin-right: 0.25rem;\n}\n.mx-5 {\n margin-left: 1.25rem;\n margin-right: 1.25rem;\n}\n.mx-\\[5px\\] {\n margin-left: 5px;\n margin-right: 5px;\n}\n.mx-auto {\n margin-left: auto;\n margin-right: auto;\n}\n.my-2 {\n margin-top: 0.5rem;\n margin-bottom: 0.5rem;\n}\n.my-6 {\n margin-top: 1.5rem;\n margin-bottom: 1.5rem;\n}\n.my-\\[\\.1rem\\] {\n margin-top: .1rem;\n margin-bottom: .1rem;\n}\n.\\!ml-auto {\n margin-left: auto !important;\n}\n.mb-0 {\n margin-bottom: 0px;\n}\n.mb-0\\.5 {\n margin-bottom: 0.125rem;\n}\n.mb-1 {\n margin-bottom: 0.25rem;\n}\n.mb-2 {\n margin-bottom: 0.5rem;\n}\n.mb-3 {\n margin-bottom: 0.75rem;\n}\n.mb-4 {\n margin-bottom: 1rem;\n}\n.mb-5 {\n margin-bottom: 1.25rem;\n}\n.mb-6 {\n margin-bottom: 1.5rem;\n}\n.mb-8 {\n margin-bottom: 2rem;\n}\n.ml-1 {\n margin-left: 0.25rem;\n}\n.ml-1\\.5 {\n margin-left: 0.375rem;\n}\n.ml-2 {\n margin-left: 0.5rem;\n}\n.ml-4 {\n margin-left: 1rem;\n}\n.ml-\\[3px\\] {\n margin-left: 3px;\n}\n.ml-auto {\n margin-left: auto;\n}\n.mr-0\\.5 {\n margin-right: 0.125rem;\n}\n.mr-1 {\n margin-right: 0.25rem;\n}\n.mr-2 {\n margin-right: 0.5rem;\n}\n.mr-\\[0\\.5em\\] {\n margin-right: 0.5em;\n}\n.mr-\\[var\\(--removed-body-scroll-bar-size\\)\\] {\n margin-right: var(--removed-body-scroll-bar-size);\n}\n.mr-auto {\n margin-right: auto;\n}\n.ms-\\[1em\\] {\n margin-inline-start: 1em;\n}\n.mt-12 {\n margin-top: 3rem;\n}\n.mt-2 {\n margin-top: 0.5rem;\n}\n.mt-4 {\n margin-top: 1rem;\n}\n.mt-8 {\n margin-top: 2rem;\n}\n.line-clamp-1 {\n overflow: hidden;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 1;\n}\n.\\!line-clamp-none {\n overflow: visible !important;\n display: block !important;\n -webkit-box-orient: horizontal !important;\n -webkit-line-clamp: none !important;\n}\n.block {\n display: block;\n}\n.inline-block {\n display: inline-block;\n}\n.flex {\n display: flex;\n}\n.inline-flex {\n display: inline-flex;\n}\n.table {\n display: table;\n}\n.grid {\n display: grid;\n}\n.contents {\n display: contents;\n}\n.hidden {\n display: none;\n}\n.size-10 {\n width: 2.5rem;\n height: 2.5rem;\n}\n.size-4 {\n width: 1rem;\n height: 1rem;\n}\n.h-0 {\n height: 0px;\n}\n.h-10 {\n height: 2.5rem;\n}\n.h-11 {\n height: 2.75rem;\n}\n.h-12 {\n height: 3rem;\n}\n.h-20 {\n height: 5rem;\n}\n.h-3 {\n height: 0.75rem;\n}\n.h-3\\.5 {\n height: 0.875rem;\n}\n.h-4 {\n height: 1rem;\n}\n.h-5 {\n height: 1.25rem;\n}\n.h-6 {\n height: 1.5rem;\n}\n.h-8 {\n height: 2rem;\n}\n.h-\\[24px\\] {\n height: 24px;\n}\n.h-\\[27\\.88px\\] {\n height: 27.88px;\n}\n.h-\\[30px\\] {\n height: 30px;\n}\n.h-\\[calc\\(100\\%-24px\\)\\] {\n height: calc(100% - 24px);\n}\n.h-\\[var\\(--ask-ai-trigger-height\\)\\] {\n height: var(--ask-ai-trigger-height);\n}\n.h-\\[var\\(--radix-select-trigger-height\\)\\] {\n height: var(--radix-select-trigger-height);\n}\n.h-auto {\n height: auto;\n}\n.h-full {\n height: 100%;\n}\n.h-screen {\n height: 100vh;\n}\n.max-h-96 {\n max-height: 24rem;\n}\n.max-h-\\[100vw\\] {\n max-height: 100vw;\n}\n.max-h-\\[10vh\\] {\n max-height: 10vh;\n}\n.max-h-\\[200px\\] {\n max-height: 200px;\n}\n.max-h-\\[min\\(85vh\\2c 850px\\)\\] {\n max-height: min(85vh,850px);\n}\n.max-h-full {\n max-height: 100%;\n}\n.max-h-screen {\n max-height: 100vh;\n}\n.\\!min-h-0 {\n min-height: 0px !important;\n}\n.min-h-0 {\n min-height: 0px;\n}\n.min-h-20 {\n min-height: 5rem;\n}\n.min-h-8 {\n min-height: 2rem;\n}\n.min-h-9 {\n min-height: 2.25rem;\n}\n.min-h-\\[38px\\] {\n min-height: 38px;\n}\n.min-h-\\[unset\\] {\n min-height: unset;\n}\n.w-10 {\n width: 2.5rem;\n}\n.w-12 {\n width: 3rem;\n}\n.w-16 {\n width: 4rem;\n}\n.w-2\\.5 {\n width: 0.625rem;\n}\n.w-3\\.5 {\n width: 0.875rem;\n}\n.w-4 {\n width: 1rem;\n}\n.w-40 {\n width: 10rem;\n}\n.w-5 {\n width: 1.25rem;\n}\n.w-56 {\n width: 14rem;\n}\n.w-6 {\n width: 1.5rem;\n}\n.w-60 {\n width: 15rem;\n}\n.w-8 {\n width: 2rem;\n}\n.w-\\[--width\\] {\n width: var(--width);\n}\n.w-\\[250px\\] {\n width: 250px;\n}\n.w-\\[254px\\] {\n width: 254px;\n}\n.w-\\[calc\\(100\\%_-_theme\\(spacing\\.10\\)\\)\\] {\n width: calc(100% - 2.5rem);\n}\n.w-\\[min\\(90vw\\2c 720px\\)\\] {\n width: min(90vw,720px);\n}\n.w-fit {\n width: -moz-fit-content;\n width: fit-content;\n}\n.w-full {\n width: 100%;\n}\n.w-screen {\n width: 100vw;\n}\n.\\!min-w-0 {\n min-width: 0px !important;\n}\n.min-w-0 {\n min-width: 0px;\n}\n.min-w-10 {\n min-width: 2.5rem;\n}\n.min-w-5 {\n min-width: 1.25rem;\n}\n.min-w-6 {\n min-width: 1.5rem;\n}\n.min-w-8 {\n min-width: 2rem;\n}\n.min-w-\\[8rem\\] {\n min-width: 8rem;\n}\n.min-w-\\[unset\\] {\n min-width: unset;\n}\n.min-w-\\[var\\(--radix-select-trigger-width\\)\\] {\n min-width: var(--radix-select-trigger-width);\n}\n.max-w-2xl {\n max-width: 42rem;\n}\n.max-w-\\[200px\\] {\n max-width: 200px;\n}\n.max-w-\\[480px\\] {\n max-width: 480px;\n}\n.max-w-full {\n max-width: 100%;\n}\n.max-w-lg {\n max-width: 32rem;\n}\n.flex-1 {\n flex: 1 1 0%;\n}\n.flex-\\[0_0_100\\%\\] {\n flex: 0 0 100%;\n}\n.flex-shrink-0 {\n flex-shrink: 0;\n}\n.shrink-0 {\n flex-shrink: 0;\n}\n.grow-0 {\n flex-grow: 0;\n}\n.grow-\\[1\\] {\n flex-grow: 1;\n}\n.grow-\\[2\\] {\n flex-grow: 2;\n}\n.grow-\\[5\\] {\n flex-grow: 5;\n}\n.border-collapse {\n border-collapse: collapse;\n}\n.-translate-x-1\\/2 {\n --tw-translate-x: -50%;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n.-translate-y-1\\/2 {\n --tw-translate-y: -50%;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n.translate-x-\\[-50\\%\\] {\n --tw-translate-x: -50%;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n.rotate-\\[-30deg\\] {\n --tw-rotate: -30deg;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n.transform-none {\n transform: none;\n}\n@keyframes bounce-dot {\n\n 0%, 100% {\n transform: translateY(0);\n opacity: 0.3;\n }\n\n 50% {\n transform: translateY(-5px);\n opacity: 1;\n }\n}\n.animate-bounce-dot {\n animation: bounce-dot 1.5s infinite ease-in-out;\n}\n@keyframes checkbox-check {\n\n from {\n opacity: 0;\n stroke-dashoffset: 16;\n transform: scale(0.95);\n }\n\n to {\n opacity: 1;\n stroke-dashoffset: 0;\n transform: scale(1);\n }\n}\n.animate-checkbox-check {\n animation: checkbox-check 200ms linear;\n}\n@keyframes shimmer {\n\n 0% {\n background-size: 200% 200%;\n background-position: 100% 0;\n }\n\n 100% {\n background-size: 200% 200%;\n background-position: -100% 0;\n }\n}\n.animate-shimmer {\n animation: shimmer 3.5s cubic-bezier(0.4, 0, 0.6, 1) infinite;\n}\n@keyframes shine {\n\n 0% {\n background-position: -200% 0%;\n }\n\n 100% {\n background-position: 200% 0%;\n }\n}\n.animate-shine {\n animation: shine 2.5s linear infinite;\n}\n@keyframes skeleton-bg-fade {\n\n from {\n border-color: var(--start-color);\n background: var(--start-color);\n }\n\n to {\n border-color: var(--end-color);\n background: var(--end-color);\n }\n}\n.animate-skeleton-bg-fade {\n animation: 0.8s linear infinite alternate skeleton-bg-fade;\n}\n@keyframes spin {\n\n to {\n transform: rotate(360deg);\n }\n}\n.animate-spin {\n animation: spin 1s linear infinite;\n}\n.cursor-default {\n cursor: default;\n}\n.cursor-ew-resize {\n cursor: ew-resize;\n}\n.cursor-pointer {\n cursor: pointer;\n}\n.touch-none {\n touch-action: none;\n}\n.select-none {\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n}\n.resize-none {\n resize: none;\n}\n.list-\\[initial\\] {\n list-style-type: initial;\n}\n.list-decimal {\n list-style-type: decimal;\n}\n.appearance-none {\n -webkit-appearance: none;\n -moz-appearance: none;\n appearance: none;\n}\n.flex-row {\n flex-direction: row;\n}\n.flex-row-reverse {\n flex-direction: row-reverse;\n}\n.flex-col {\n flex-direction: column;\n}\n.flex-wrap {\n flex-wrap: wrap;\n}\n.flex-wrap-reverse {\n flex-wrap: wrap-reverse;\n}\n.place-items-center {\n place-items: center;\n}\n.content-center {\n align-content: center;\n}\n.items-start {\n align-items: flex-start;\n}\n.items-end {\n align-items: flex-end;\n}\n.items-center {\n align-items: center;\n}\n.items-stretch {\n align-items: stretch;\n}\n.justify-start {\n justify-content: flex-start;\n}\n.justify-end {\n justify-content: flex-end;\n}\n.justify-center {\n justify-content: center;\n}\n.justify-between {\n justify-content: space-between;\n}\n.gap-0\\.5 {\n gap: 0.125rem;\n}\n.gap-1 {\n gap: 0.25rem;\n}\n.gap-1\\.5 {\n gap: 0.375rem;\n}\n.gap-12 {\n gap: 3rem;\n}\n.gap-2 {\n gap: 0.5rem;\n}\n.gap-2\\.5 {\n gap: 0.625rem;\n}\n.gap-3 {\n gap: 0.75rem;\n}\n.gap-4 {\n gap: 1rem;\n}\n.gap-5 {\n gap: 1.25rem;\n}\n.gap-6 {\n gap: 1.5rem;\n}\n.gap-8 {\n gap: 2rem;\n}\n.gap-\\[1rem_0\\.5rem\\] {\n gap: 1rem 0.5rem;\n}\n.gap-x-2 {\n -moz-column-gap: 0.5rem;\n column-gap: 0.5rem;\n}\n.gap-x-3 {\n -moz-column-gap: 0.75rem;\n column-gap: 0.75rem;\n}\n.gap-y-1 {\n row-gap: 0.25rem;\n}\n.gap-y-2 {\n row-gap: 0.5rem;\n}\n.gap-y-6 {\n row-gap: 1.5rem;\n}\n.space-x-1 > :not([hidden]) ~ :not([hidden]) {\n --tw-space-x-reverse: 0;\n margin-right: calc(0.25rem * var(--tw-space-x-reverse));\n margin-left: calc(0.25rem * calc(1 - var(--tw-space-x-reverse)));\n}\n.space-x-2 > :not([hidden]) ~ :not([hidden]) {\n --tw-space-x-reverse: 0;\n margin-right: calc(0.5rem * var(--tw-space-x-reverse));\n margin-left: calc(0.5rem * calc(1 - var(--tw-space-x-reverse)));\n}\n.divide-y > :not([hidden]) ~ :not([hidden]) {\n --tw-divide-y-reverse: 0;\n border-top-width: calc(1px * calc(1 - var(--tw-divide-y-reverse)));\n border-bottom-width: calc(1px * var(--tw-divide-y-reverse));\n}\n.self-start {\n align-self: flex-start;\n}\n.self-center {\n align-self: center;\n}\n.justify-self-end {\n justify-self: end;\n}\n.justify-self-center {\n justify-self: center;\n}\n.overflow-hidden {\n overflow: hidden;\n}\n.overflow-x-auto {\n overflow-x: auto;\n}\n.overflow-y-auto {\n overflow-y: auto;\n}\n.truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.text-ellipsis {\n text-overflow: ellipsis;\n}\n.whitespace-normal {\n white-space: normal;\n}\n.whitespace-nowrap {\n white-space: nowrap;\n}\n.whitespace-pre {\n white-space: pre;\n}\n.whitespace-pre-wrap {\n white-space: pre-wrap;\n}\n.break-words {\n overflow-wrap: break-word;\n}\n.rounded {\n border-radius: 0.25rem;\n}\n.rounded-\\[0_0_6px_6px\\] {\n border-radius: 0 0 6px 6px;\n}\n.rounded-\\[6px\\] {\n border-radius: 6px;\n}\n.rounded-\\[6px_6px_0_0\\] {\n border-radius: 6px 6px 0 0;\n}\n.rounded-\\[inherit\\] {\n border-radius: inherit;\n}\n.rounded-full {\n border-radius: 9999px;\n}\n.rounded-lg {\n border-radius: 0.5rem;\n}\n.rounded-md {\n border-radius: 0.375rem;\n}\n.rounded-sm {\n border-radius: 0.125rem;\n}\n.rounded-xl {\n border-radius: 0.75rem;\n}\n.border {\n border-width: 1px;\n}\n.border-2 {\n border-width: 2px;\n}\n.border-b {\n border-bottom-width: 1px;\n}\n.border-l {\n border-left-width: 1px;\n}\n.border-solid {\n border-style: solid;\n}\n.border-none {\n border-style: none;\n}\n.border-\\[--end-color\\] {\n border-color: var(--end-color);\n}\n.border-gray-100 {\n border-color: var(--ikp-color-gray-100);\n}\n.border-gray-200 {\n border-color: var(--ikp-color-gray-200);\n}\n.border-gray-300 {\n border-color: var(--ikp-color-gray-300);\n}\n.border-inherit {\n border-color: inherit;\n}\n.border-inkeep-expanded-primary-200 {\n border-color: var(--ikp-color-inkeep-expanded-primary-200);\n}\n.border-transparent {\n border-color: transparent;\n}\n.border-white-alpha-200 {\n border-color: var(--ikp-color-white-alpha-200);\n}\n.border-l-transparent {\n border-left-color: transparent;\n}\n.bg-\\[--start-color\\] {\n background-color: var(--start-color);\n}\n.bg-gray-100 {\n background-color: var(--ikp-color-gray-100);\n}\n.bg-gray-1000 {\n background-color: var(--ikp-color-gray-1000);\n}\n.bg-gray-300 {\n background-color: var(--ikp-color-gray-300);\n}\n.bg-gray-50 {\n background-color: var(--ikp-color-gray-50);\n}\n.bg-gray-500 {\n background-color: var(--ikp-color-gray-500);\n}\n.bg-inherit {\n background-color: inherit;\n}\n.bg-inkeep-primary-lighter {\n background-color: var(--ikp-color-inkeep-primary-lighter);\n}\n.bg-inkeep-primary-medium {\n background-color: var(--ikp-color-inkeep-primary-medium);\n}\n.bg-inkeep-primary-text-bold {\n background-color: var(--ikp-color-inkeep-primary-text-bold);\n}\n.bg-overlay-light {\n background-color: var(--ikp-color-overlay-light);\n}\n.bg-transparent {\n background-color: transparent;\n}\n.bg-white {\n --tw-bg-opacity: 1;\n background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));\n}\n.bg-\\[linear-gradient\\(to_bottom_right\\2c _var\\(--ikp-color-gray-700\\)\\2c _var\\(--ikp-color-gray-400\\)\\)\\] {\n background-image: linear-gradient(to bottom right, var(--ikp-color-gray-700), var(--ikp-color-gray-400));\n}\n.bg-\\[linear-gradient\\(to_top\\2c _var\\(--ikp-color-gray-100\\)\\2c _transparent\\)\\] {\n background-image: linear-gradient(to top, var(--ikp-color-gray-100), transparent);\n}\n.bg-clip-padding {\n background-clip: padding-box;\n}\n.\\!bg-clip-text {\n -webkit-background-clip: text !important;\n background-clip: text !important;\n}\n.bg-clip-text {\n -webkit-background-clip: text;\n background-clip: text;\n}\n.fill-white {\n fill: #fff;\n}\n.p-0 {\n padding: 0px;\n}\n.p-0\\.5 {\n padding: 0.125rem;\n}\n.p-1 {\n padding: 0.25rem;\n}\n.p-2 {\n padding: 0.5rem;\n}\n.p-4 {\n padding: 1rem;\n}\n.p-8 {\n padding: 2rem;\n}\n.p-\\[1em\\] {\n padding: 1em;\n}\n.px-0 {\n padding-left: 0px;\n padding-right: 0px;\n}\n.px-1 {\n padding-left: 0.25rem;\n padding-right: 0.25rem;\n}\n.px-2 {\n padding-left: 0.5rem;\n padding-right: 0.5rem;\n}\n.px-3 {\n padding-left: 0.75rem;\n padding-right: 0.75rem;\n}\n.px-4 {\n padding-left: 1rem;\n padding-right: 1rem;\n}\n.px-5 {\n padding-left: 1.25rem;\n padding-right: 1.25rem;\n}\n.px-6 {\n padding-left: 1.5rem;\n padding-right: 1.5rem;\n}\n.px-\\[\\.4rem\\] {\n padding-left: .4rem;\n padding-right: .4rem;\n}\n.px-\\[18px\\] {\n padding-left: 18px;\n padding-right: 18px;\n}\n.py-0 {\n padding-top: 0px;\n padding-bottom: 0px;\n}\n.py-1 {\n padding-top: 0.25rem;\n padding-bottom: 0.25rem;\n}\n.py-1\\.5 {\n padding-top: 0.375rem;\n padding-bottom: 0.375rem;\n}\n.py-2 {\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n}\n.py-3 {\n padding-top: 0.75rem;\n padding-bottom: 0.75rem;\n}\n.py-4 {\n padding-top: 1rem;\n padding-bottom: 1rem;\n}\n.py-6 {\n padding-top: 1.5rem;\n padding-bottom: 1.5rem;\n}\n.py-8 {\n padding-top: 2rem;\n padding-bottom: 2rem;\n}\n.py-\\[\\.2rem\\] {\n padding-top: .2rem;\n padding-bottom: .2rem;\n}\n.py-\\[1px\\] {\n padding-top: 1px;\n padding-bottom: 1px;\n}\n.pb-1 {\n padding-bottom: 0.25rem;\n}\n.pb-2 {\n padding-bottom: 0.5rem;\n}\n.pb-2\\.5 {\n padding-bottom: 0.625rem;\n}\n.pb-3 {\n padding-bottom: 0.75rem;\n}\n.pb-4 {\n padding-bottom: 1rem;\n}\n.pb-6 {\n padding-bottom: 1.5rem;\n}\n.pb-8 {\n padding-bottom: 2rem;\n}\n.pl-2 {\n padding-left: 0.5rem;\n}\n.pl-5 {\n padding-left: 1.25rem;\n}\n.pl-7 {\n padding-left: 1.75rem;\n}\n.pr-10 {\n padding-right: 2.5rem;\n}\n.pr-8 {\n padding-right: 2rem;\n}\n.pt-0 {\n padding-top: 0px;\n}\n.pt-1 {\n padding-top: 0.25rem;\n}\n.pt-12 {\n padding-top: 3rem;\n}\n.pt-2 {\n padding-top: 0.5rem;\n}\n.pt-3 {\n padding-top: 0.75rem;\n}\n.pt-4 {\n padding-top: 1rem;\n}\n.pt-6 {\n padding-top: 1.5rem;\n}\n.text-left {\n text-align: left;\n}\n.text-center {\n text-align: center;\n}\n.text-start {\n text-align: start;\n}\n.align-middle {\n vertical-align: middle;\n}\n.font-body {\n font-family: var(--ikp-font-family-body);\n}\n.font-heading {\n font-family: var(--ikp-font-family-heading);\n}\n.font-mono {\n font-family: var(--ikp-font-family-mono);\n}\n.text-1sm {\n font-size: var(--ikp-font-size-1sm);\n}\n.text-2sm {\n font-size: var(--ikp-font-size-2sm);\n}\n.text-2xs {\n font-size: var(--ikp-font-size-2xs);\n}\n.text-3xl {\n font-size: var(--ikp-font-size-3xl);\n}\n.text-lg {\n font-size: var(--ikp-font-size-lg);\n}\n.text-md {\n font-size: var(--ikp-font-size-md);\n}\n.text-sm {\n font-size: var(--ikp-font-size-sm);\n}\n.text-xl {\n font-size: var(--ikp-font-size-xl);\n}\n.text-xs {\n font-size: var(--ikp-font-size-xs);\n}\n.font-bold {\n font-weight: 700;\n}\n.font-medium {\n font-weight: 500;\n}\n.font-normal {\n font-weight: 400;\n}\n.font-semibold {\n font-weight: 600;\n}\n.uppercase {\n text-transform: uppercase;\n}\n.leading-4 {\n line-height: 1rem;\n}\n.leading-5 {\n line-height: 1.25rem;\n}\n.leading-6 {\n line-height: 1.5rem;\n}\n.leading-\\[1\\.25\\] {\n line-height: 1.25;\n}\n.leading-\\[1\\.2\\] {\n line-height: 1.2;\n}\n.leading-\\[1em\\] {\n line-height: 1em;\n}\n.leading-\\[unset\\] {\n line-height: unset;\n}\n.leading-snug {\n line-height: 1.375;\n}\n.tracking-tight {\n letter-spacing: -0.025em;\n}\n.tracking-wider {\n letter-spacing: 0.05em;\n}\n.tracking-widest {\n letter-spacing: 0.1em;\n}\n.text-current {\n color: currentColor;\n}\n.text-gray-400 {\n color: var(--ikp-color-gray-400);\n}\n.text-gray-500 {\n color: var(--ikp-color-gray-500);\n}\n.text-gray-600 {\n color: var(--ikp-color-gray-600);\n}\n.text-gray-700 {\n color: var(--ikp-color-gray-700);\n}\n.text-gray-800 {\n color: var(--ikp-color-gray-800);\n}\n.text-green-500 {\n --tw-text-opacity: 1;\n color: rgb(34 197 94 / var(--tw-text-opacity, 1));\n}\n.text-inherit {\n color: inherit;\n}\n.text-inkeep-primary-medium {\n color: var(--ikp-color-inkeep-primary-medium);\n}\n.text-inkeep-primary-medium-subtle {\n color: var(--ikp-color-inkeep-primary-medium-subtle);\n}\n.text-inkeep-primary-strong {\n color: var(--ikp-color-inkeep-primary-strong);\n}\n.text-inkeep-primary-stronger {\n color: var(--ikp-color-inkeep-primary-stronger);\n}\n.text-inkeep-primary-stronger-light {\n color: var(--ikp-color-inkeep-primary-stronger-light);\n}\n.text-inkeep-primary-text-bold {\n color: var(--ikp-color-inkeep-primary-text-bold);\n}\n.text-inkeep-primary-text-color-on-primary {\n color: var(--ikp-color-inkeep-primary-text-color-on-primary);\n}\n.text-purple-500 {\n --tw-text-opacity: 1;\n color: rgb(168 85 247 / var(--tw-text-opacity, 1));\n}\n.text-red-500 {\n --tw-text-opacity: 1;\n color: rgb(239 68 68 / var(--tw-text-opacity, 1));\n}\n.text-transparent {\n color: transparent;\n}\n.text-white {\n --tw-text-opacity: 1;\n color: rgb(255 255 255 / var(--tw-text-opacity, 1));\n}\n.opacity-0 {\n opacity: 0;\n}\n.opacity-100 {\n opacity: 1;\n}\n.opacity-30 {\n opacity: 0.3;\n}\n.opacity-45 {\n opacity: 0.45;\n}\n.opacity-70 {\n opacity: 0.7;\n}\n.shadow {\n --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);\n --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-2xl {\n --tw-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.25);\n --tw-shadow-colored: 0 25px 50px -12px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-\\[0_0_0_2px_var\\(--shadow-color\\)\\] {\n --tw-shadow: 0 0 0 2px var(--shadow-color);\n --tw-shadow-colored: 0 0 0 2px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-\\[0_25px_50px_-12px_rgba\\(0\\2c 0\\2c 0\\2c 0\\.25\\)\\] {\n --tw-shadow: 0 25px 50px -12px rgba(0,0,0,0.25);\n --tw-shadow-colored: 0 25px 50px -12px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-\\[0_8px_30px_rgba\\(0\\2c 0\\2c 0\\2c 0\\.12\\)\\] {\n --tw-shadow: 0 8px 30px rgba(0,0,0,0.12);\n --tw-shadow-colored: 0 8px 30px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-\\[inset_0_0_0_1px_currentColor\\] {\n --tw-shadow: inset 0 0 0 1px currentColor;\n --tw-shadow-colored: inset 0 0 0 1px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-lg {\n --tw-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);\n --tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-md {\n --tw-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);\n --tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-none {\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n.shadow-\\[none\\] {\n --tw-shadow-color: none;\n --tw-shadow: var(--tw-shadow-colored);\n}\n.outline-none {\n outline: 2px solid transparent;\n outline-offset: 2px;\n}\n.outline {\n outline-style: solid;\n}\n.backdrop-blur-sm {\n --tw-backdrop-blur: blur(4px);\n -webkit-backdrop-filter: var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);\n backdrop-filter: var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);\n}\n.transition-\\[common\\] {\n transition-property: common;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n.transition-all {\n transition-property: all;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n.transition-colors {\n transition-property: color, background-color, border-color, text-decoration-color, fill, stroke;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n.transition-opacity {\n transition-property: opacity;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n.transition-transform {\n transition-property: transform;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n.duration-100 {\n transition-duration: 100ms;\n}\n.duration-200 {\n transition-duration: 200ms;\n}\n.duration-300 {\n transition-duration: 300ms;\n}\n.duration-\\[160ms\\] {\n transition-duration: 160ms;\n}\n.duration-\\[180\\] {\n transition-duration: 180;\n}\n.ease-in-out {\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n}\n.ease-linear {\n transition-timing-function: linear;\n}\n.ease-out {\n transition-timing-function: cubic-bezier(0, 0, 0.2, 1);\n}\n.\\[--ask-ai-trigger-height\\:0px\\] {\n --ask-ai-trigger-height: 0px;\n}\n.\\[--end-color\\:theme\\(colors\\.gray\\.300\\)\\] {\n --end-color: var(--ikp-color-gray-300);\n}\n.\\[--end-color\\:theme\\(colors\\.inkeep-expanded-primary\\.700\\)\\] {\n --end-color: var(--ikp-color-inkeep-expanded-primary-700);\n}\n.\\[--end-color\\:theme\\(colors\\.white-alpha\\.100\\)\\] {\n --end-color: var(--ikp-color-white-alpha-100);\n}\n.\\[--error-border-color\\:theme\\(colors\\.red\\.500\\)\\] {\n --error-border-color: #ef4444;\n}\n.\\[--focus-border-color\\:theme\\(colors\\.blue\\.500\\)\\] {\n --focus-border-color: #3b82f6;\n}\n.\\[--footer-height\\:theme\\(spacing\\.9\\)\\] {\n --footer-height: 2.25rem;\n}\n.\\[--scrollbar-color\\:var\\(--color-gray-300\\)\\] {\n --scrollbar-color: var(--color-gray-300);\n}\n.\\[--start-color\\:theme\\(colors\\.gray\\.50\\)\\] {\n --start-color: var(--ikp-color-gray-50);\n}\n.\\[--start-color\\:theme\\(colors\\.inkeep-expanded-primary\\.300\\)\\] {\n --start-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n.\\[background\\:linear-gradient\\(270deg\\2c theme\\(colors\\.inkeep-primary\\.stronger-light\\)\\2c transparent\\)_-200\\%_50\\%_\\/_25\\%_100\\%_no-repeat\\2c theme\\(colors\\.inkeep-expanded-primary\\.800\\)\\] {\n background: linear-gradient(270deg,var(--ikp-color-inkeep-primary-stronger-light),transparent) -200% 50% / 25% 100% no-repeat,var(--ikp-color-inkeep-expanded-primary-800);\n}\n.\\[counter-increment\\:item\\] {\n counter-increment: item;\n}\n.\\[counter-reset\\:item_calc\\(var\\(--start\\2c 0\\)_-_1\\)\\] {\n counter-reset: item calc(var(--start,0) - 1);\n}\n.\\[font-size\\:85\\%\\!important\\] {\n font-size: 85% !important;\n}\n.\\[font-variant-numeric\\:lining-nums_tabular-nums\\] {\n font-variant-numeric: lining-nums tabular-nums;\n}\n.\\[grid-area\\:breadcrumbs\\] {\n grid-area: breadcrumbs;\n}\n.\\[grid-area\\:description\\] {\n grid-area: description;\n}\n.\\[grid-area\\:icon\\] {\n grid-area: icon;\n}\n.\\[grid-area\\:indicator\\] {\n grid-area: indicator;\n}\n.\\[grid-area\\:tag\\] {\n grid-area: tag;\n}\n.\\[grid-area\\:title\\] {\n grid-area: title;\n}\n.\\[grid-template\\:\\"breadcrumbs_breadcrumbs_breadcrumbs_indicator\\"\\"icon_title_tag_indicator\\"\\"description_description_description_indicator\\"\\/auto_auto_1fr_auto\\] {\n grid-template: "breadcrumbs breadcrumbs breadcrumbs indicator""icon title tag indicator""description description description indicator"/auto auto 1fr auto;\n}\n.\\[inset-inline-start\\:var\\(--start\\2c 0px\\)\\] {\n inset-inline-start: var(--start,0px);\n}\n.\\[overflow-wrap\\:anywhere\\] {\n overflow-wrap: anywhere;\n}\n.\\[scrollbar-color\\:var\\(--scrollbar-color\\)_transparent\\] {\n scrollbar-color: var(--scrollbar-color) transparent;\n}\n.\\[scrollbar-width\\:thin\\] {\n scrollbar-width: thin;\n}\n.\\[transition-duration\\:0\\.02s\\] {\n transition-duration: 0.02s;\n}\n.\\[transition-property\\:common\\] {\n transition-property: common;\n}\n\n:where(.inkeep-widget-vars) {\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n font-family: var(--ikp-font-family-body);\n font-size: var(--ikp-font-size-md);\n line-height: 1.5;\n color: var(--ikp-color-gray-800);\n}\n\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) {\n color: var(--ikp-color-white-alpha-950);\n}\n\n:where(.inkeep-widget-vars) *,\n:where(.inkeep-widget-vars) *::before,\n:where(.inkeep-widget-vars) *::after {\n border-color: var(--ikp-color-gray-200);\n}\n\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) *,\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) *::before,\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) *::after {\n border-color: var(--ikp-color-white-alpha-200);\n}\n\n:where(.inkeep-widget-vars) input::-moz-placeholder, :where(.inkeep-widget-vars) textarea::-moz-placeholder {\n color: var(--ikp-color-gray-500);\n}\n\n:where(.inkeep-widget-vars) input::placeholder,\n:where(.inkeep-widget-vars) textarea::placeholder {\n color: var(--ikp-color-gray-500);\n}\n\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) input::-moz-placeholder, [data-theme=\'dark\'] :where(.inkeep-widget-vars) textarea::-moz-placeholder {\n color: var(--ikp-color-white-alpha-500);\n}\n\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) input::placeholder,\n[data-theme=\'dark\'] :where(.inkeep-widget-vars) textarea::placeholder {\n color: var(--ikp-color-white-alpha-500);\n}\n\n:where(.inkeep-widget-vars) [data-part=\'icon\'][data-type=\'built-in\'] {\n display: inline-block;\n min-height: 1em;\n min-width: 1em;\n flex-shrink: 0;\n vertical-align: middle;\n line-height: 1em;\n}\n\nsvg[data-part=\'icon\'][data-type=\'custom\'] {\n /* we don\'t want the wrapper divs to affect layout / positioning of icon */\n display: contents;\n}\n\nsvg[data-part=\'icon\'][data-type=\'custom\'] div {\n display: contents;\n}\n\nimg[data-part=\'icon\'][data-type=\'custom\'] {\n display: inline-block;\n min-height: 1em;\n min-width: 1em;\n}\n\n.\\*\\:invisible > * {\n visibility: hidden;\n}\n\n.\\*\\:m-0 > * {\n margin: 0px;\n}\n\n.file\\:h-full::file-selector-button {\n height: 100%;\n}\n\n.file\\:cursor-pointer::file-selector-button {\n cursor: pointer;\n}\n\n.file\\:border-none::file-selector-button {\n border-style: none;\n}\n\n.file\\:bg-transparent::file-selector-button {\n background-color: transparent;\n}\n\n.file\\:text-sm::file-selector-button {\n font-size: var(--ikp-font-size-sm);\n}\n\n.file\\:font-medium::file-selector-button {\n font-weight: 500;\n}\n\n.file\\:text-gray-700::file-selector-button {\n color: var(--ikp-color-gray-700);\n}\n\n.placeholder\\:text-gray-500::-moz-placeholder {\n color: var(--ikp-color-gray-500);\n}\n\n.placeholder\\:text-gray-500::placeholder {\n color: var(--ikp-color-gray-500);\n}\n\n.before\\:pointer-events-none::before {\n content: var(--tw-content);\n pointer-events: none;\n}\n\n.before\\:invisible::before {\n content: var(--tw-content);\n visibility: hidden;\n}\n\n.before\\:absolute::before {\n content: var(--tw-content);\n position: absolute;\n}\n\n.before\\:left-0::before {\n content: var(--tw-content);\n left: 0px;\n}\n\n.before\\:top-0::before {\n content: var(--tw-content);\n top: 0px;\n}\n\n.before\\:z-hide::before {\n content: var(--tw-content);\n z-index: var(--ikp-z-index-hide);\n}\n\n.before\\:m-auto::before {\n content: var(--tw-content);\n margin: auto;\n}\n\n.before\\:block::before {\n content: var(--tw-content);\n display: block;\n}\n\n.before\\:h-3::before {\n content: var(--tw-content);\n height: 0.75rem;\n}\n\n.before\\:h-\\[--before-size\\]::before {\n content: var(--tw-content);\n height: var(--before-size);\n}\n\n.before\\:w-\\[--before-size\\]::before {\n content: var(--tw-content);\n width: var(--before-size);\n}\n\n.before\\:w-full::before {\n content: var(--tw-content);\n width: 100%;\n}\n\n.before\\:-translate-y-full::before {\n content: var(--tw-content);\n --tw-translate-y: -100%;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.before\\:bg-gray-300::before {\n content: var(--tw-content);\n background-color: var(--ikp-color-gray-300);\n}\n\n.before\\:bg-\\[linear-gradient\\(transparent\\2c _white\\)\\]::before {\n content: var(--tw-content);\n background-image: linear-gradient(transparent, white);\n}\n\n.before\\:bg-\\[linear-gradient\\(white\\2c _transparent\\)\\]::before {\n content: var(--tw-content);\n background-image: linear-gradient(white, transparent);\n}\n\n.before\\:bg-no-repeat::before {\n content: var(--tw-content);\n background-repeat: no-repeat;\n}\n\n.before\\:\\[background-position\\:0_0\\]::before {\n content: var(--tw-content);\n background-position: 0 0;\n}\n\n.before\\:\\[background-size\\:cover\\]::before {\n content: var(--tw-content);\n background-size: cover;\n}\n\n.after\\:invisible::after {\n content: var(--tw-content);\n visibility: hidden;\n}\n\n.after\\:absolute::after {\n content: var(--tw-content);\n position: absolute;\n}\n\n.after\\:bottom-0::after {\n content: var(--tw-content);\n bottom: 0px;\n}\n\n.after\\:left-0::after {\n content: var(--tw-content);\n left: 0px;\n}\n\n.after\\:left-\\[1px\\]::after {\n content: var(--tw-content);\n left: 1px;\n}\n\n.after\\:top-0::after {\n content: var(--tw-content);\n top: 0px;\n}\n\n.after\\:top-\\[1px\\]::after {\n content: var(--tw-content);\n top: 1px;\n}\n\n.after\\:top-full::after {\n content: var(--tw-content);\n top: 100%;\n}\n\n.after\\:z-base::after {\n content: var(--tw-content);\n z-index: var(--ikp-z-index-base);\n}\n\n.after\\:z-start::after {\n content: var(--tw-content);\n z-index: var(--ikp-z-index-start);\n}\n\n.after\\:h-3::after {\n content: var(--tw-content);\n height: 0.75rem;\n}\n\n.after\\:h-\\[calc\\(100\\%-2px\\)\\]::after {\n content: var(--tw-content);\n height: calc(100% - 2px);\n}\n\n.after\\:w-0\\.5::after {\n content: var(--tw-content);\n width: 0.125rem;\n}\n\n.after\\:w-\\[calc\\(100\\%-2px\\)\\]::after {\n content: var(--tw-content);\n width: calc(100% - 2px);\n}\n\n.after\\:w-full::after {\n content: var(--tw-content);\n width: 100%;\n}\n\n.after\\:rounded-\\[5px\\]::after {\n content: var(--tw-content);\n border-radius: 5px;\n}\n\n.after\\:bg-inkeep-primary-medium::after {\n content: var(--tw-content);\n background-color: var(--ikp-color-inkeep-primary-medium);\n}\n\n.after\\:bg-white::after {\n content: var(--tw-content);\n --tw-bg-opacity: 1;\n background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));\n}\n\n.after\\:bg-\\[linear-gradient\\(currentColor\\2c _transparent\\)\\]::after {\n content: var(--tw-content);\n background-image: linear-gradient(currentColor, transparent);\n}\n\n.after\\:bg-\\[linear-gradient\\(transparent\\2c _white\\)\\]::after {\n content: var(--tw-content);\n background-image: linear-gradient(transparent, white);\n}\n\n.after\\:text-white::after {\n content: var(--tw-content);\n --tw-text-opacity: 1;\n color: rgb(255 255 255 / var(--tw-text-opacity, 1));\n}\n\n.after\\:content-\\[\\"\\"\\]::after {\n --tw-content: "";\n content: var(--tw-content);\n}\n\n.first\\:w-full:first-child {\n width: 100%;\n}\n\n.last-of-type\\:hidden:last-of-type {\n display: none;\n}\n\n.focus\\:z-base:focus {\n z-index: var(--ikp-z-index-base);\n}\n\n.focus\\:z-start:focus {\n z-index: var(--ikp-z-index-start);\n}\n\n.focus\\:bg-gray-100:focus {\n background-color: var(--ikp-color-gray-100);\n}\n\n.focus\\:outline-none:focus {\n outline: 2px solid transparent;\n outline-offset: 2px;\n}\n\n.focus\\:outline-inkeep-expanded-primary-700:focus {\n outline-color: var(--ikp-color-inkeep-expanded-primary-700);\n}\n\n.focus\\:\\[--shadow-color\\:theme\\(colors\\.blue\\.500\\)\\]:focus {\n --shadow-color: #3b82f6;\n}\n\n.focus-visible\\:outline-none:focus-visible {\n outline: 2px solid transparent;\n outline-offset: 2px;\n}\n\n.focus-visible\\:ring:focus-visible {\n --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);\n --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color);\n box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000);\n}\n\n.focus-visible\\:ring-2:focus-visible {\n --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);\n --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);\n box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000);\n}\n\n.focus-visible\\:ring-gray-500:focus-visible {\n --tw-ring-color: var(--ikp-color-gray-500);\n}\n\n.focus-visible\\:ring-offset-2:focus-visible {\n --tw-ring-offset-width: 2px;\n}\n\n.active\\:bg-gray-200:active {\n background-color: var(--ikp-color-gray-200);\n}\n\n.active\\:bg-gray-300:active {\n background-color: var(--ikp-color-gray-300);\n}\n\n.active\\:bg-gray-50:active {\n background-color: var(--ikp-color-gray-50);\n}\n\n.active\\:bg-gray-900:active {\n background-color: var(--ikp-color-gray-900);\n}\n\n.disabled\\:cursor-not-allowed:disabled {\n cursor: not-allowed;\n}\n\n.disabled\\:text-gray-500:disabled {\n color: var(--ikp-color-gray-500);\n}\n\n.disabled\\:opacity-40:disabled {\n opacity: 0.4;\n}\n\n.disabled\\:opacity-50:disabled {\n opacity: 0.5;\n}\n\n.disabled\\:shadow-none:disabled {\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n.active\\:disabled\\:\\[background\\:none\\]:disabled:active {\n background: none;\n}\n\n.group:hover .group-hover\\:text-gray-600 {\n color: var(--ikp-color-gray-600);\n}\n\n.has-\\[\\[data-dual-pane-search-expanded\\]\\]\\:w-\\[min\\(90vw\\2c 1000px\\)\\]:has([data-dual-pane-search-expanded]) {\n width: min(90vw,1000px);\n}\n\n.has-\\[\\[data-scroll-top\\]\\]\\:before\\:opacity-0:has([data-scroll-top])::before {\n content: var(--tw-content);\n opacity: 0;\n}\n\n.has-\\[\\[data-scroll-bottom\\]\\]\\:after\\:opacity-0:has([data-scroll-bottom])::after {\n content: var(--tw-content);\n opacity: 0;\n}\n\n.data-\\[disabled\\]\\:pointer-events-none[data-disabled] {\n pointer-events: none;\n}\n\n.data-\\[state\\=closed\\]\\:pointer-events-none[data-state="closed"] {\n pointer-events: none;\n}\n\n.data-\\[state\\=open\\]\\:pointer-events-auto[data-state="open"] {\n pointer-events: auto;\n}\n\n.data-\\[mobile\\]\\:inset-0[data-mobile] {\n inset: 0px;\n}\n\n.data-\\[even\\]\\:ml-0[data-even] {\n margin-left: 0px;\n}\n\n.data-\\[even\\]\\:mr-4[data-even] {\n margin-right: 1rem;\n}\n\n.data-\\[position\\=left\\]\\:mr-1[data-position="left"] {\n margin-right: 0.25rem;\n}\n\n.data-\\[position\\=right\\]\\:ml-1[data-position="right"] {\n margin-left: 0.25rem;\n}\n\n.data-\\[role\\=user\\]\\:ml-0[data-role="user"] {\n margin-left: 0px;\n}\n\n.data-\\[role\\=user\\]\\:block[data-role="user"] {\n display: block;\n}\n\n.data-\\[has-results\\]\\:flex[data-has-results] {\n display: flex;\n}\n\n.data-\\[escalated\\]\\:hidden[data-escalated] {\n display: none;\n}\n\n.data-\\[hidden\\]\\:hidden[data-hidden] {\n display: none;\n}\n\n.data-\\[role\\=user\\]\\:hidden[data-role="user"] {\n display: none;\n}\n\n.data-\\[state\\=closed\\]\\:hidden[data-state="closed"] {\n display: none;\n}\n\n.data-\\[submitted\\]\\:hidden[data-submitted] {\n display: none;\n}\n\n.data-\\[has-content\\]\\:h-\\[min\\(calc\\(85vh_-_72px\\)\\2c calc\\(850px_-_72px_-_275px\\)\\)\\][data-has-content] {\n height: min(calc(85vh - 72px),calc(850px - 72px - 275px));\n}\n\n.data-\\[mobile\\]\\:h-\\[unset\\][data-mobile] {\n height: unset;\n}\n\n.data-\\[composite\\]\\:w-full[data-composite] {\n width: 100%;\n}\n\n.data-\\[mobile\\]\\:w-\\[unset\\][data-mobile] {\n width: unset;\n}\n\n.data-\\[role\\=user\\]\\:grow-0[data-role="user"] {\n flex-grow: 0;\n}\n\n.data-\\[side\\=bottom\\]\\:translate-y-1\\.5[data-side="bottom"] {\n --tw-translate-y: 0.375rem;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.data-\\[side\\=left\\]\\:-translate-x-1\\.5[data-side="left"] {\n --tw-translate-x: -0.375rem;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.data-\\[side\\=right\\]\\:translate-x-1\\.5[data-side="right"] {\n --tw-translate-x: 0.375rem;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.data-\\[side\\=top\\]\\:-translate-y-1\\.5[data-side="top"] {\n --tw-translate-y: -0.375rem;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.data-\\[mobile\\]\\:transform-none[data-mobile] {\n transform: none;\n}\n\n@keyframes fade-out {\n\n 0% {\n opacity: 1;\n }\n\n 100% {\n opacity: 0;\n }\n}\n\n.data-\\[state\\=closed\\]\\:animate-fade-out[data-state="closed"] {\n animation: fade-out 0.2s ease-out;\n}\n\n@keyframes slide-out-left {\n\n 0% {\n transform: translateX(0%);\n }\n\n 100% {\n transform: translateX(-100%);\n }\n}\n\n.data-\\[state\\=closed\\]\\:data-\\[position\\=left\\]\\:animate-sidebar-out-left[data-position="left"][data-state="closed"] {\n animation: slide-out-left 200ms cubic-bezier(0.3, 0.0, 0.8, 0.15);\n}\n\n@keyframes slide-out-right {\n\n 0% {\n transform: translateX(0%);\n }\n\n 100% {\n transform: translateX(100%);\n }\n}\n\n.data-\\[state\\=closed\\]\\:data-\\[position\\=right\\]\\:animate-sidebar-out-right[data-position="right"][data-state="closed"] {\n animation: slide-out-right 200ms cubic-bezier(0.3, 0.0, 0.8, 0.15);\n}\n\n@keyframes fade-in {\n\n 0% {\n opacity: 0;\n }\n\n 100% {\n opacity: 1;\n }\n}\n\n.data-\\[state\\=open\\]\\:animate-\\[fade-in_0\\.15s_ease-out\\][data-state="open"] {\n animation: fade-in 0.15s ease-out;\n}\n\n@keyframes fade-in {\n\n 0% {\n opacity: 0;\n }\n\n 100% {\n opacity: 1;\n }\n}\n\n.data-\\[state\\=open\\]\\:animate-fade-in[data-state="open"] {\n animation: fade-in 0.25s ease-out;\n}\n\n@keyframes slide-in-left {\n\n 0% {\n transform: translateX(-100%);\n }\n\n 100% {\n transform: translateX(0%);\n }\n}\n\n.data-\\[state\\=open\\]\\:data-\\[position\\=left\\]\\:animate-sidebar-in-left[data-position="left"][data-state="open"] {\n animation: slide-in-left 400ms cubic-bezier(0.05, 0.7, 0.1, 1.0);\n}\n\n@keyframes slide-in-right {\n\n 0% {\n transform: translateX(100%);\n }\n\n 100% {\n transform: translateX(0%);\n }\n}\n\n.data-\\[state\\=open\\]\\:data-\\[position\\=right\\]\\:animate-sidebar-in-right[data-position="right"][data-state="open"] {\n animation: slide-in-right 400ms cubic-bezier(0.05, 0.7, 0.1, 1.0);\n}\n\n.data-\\[loading\\]\\:cursor-wait[data-loading] {\n cursor: wait;\n}\n\n.data-\\[even\\]\\:flex-row[data-even] {\n flex-direction: row;\n}\n\n.data-\\[input-type\\=checkbox\\]\\:flex-row[data-input-type="checkbox"] {\n flex-direction: row;\n}\n\n.data-\\[even\\]\\:items-start[data-even] {\n align-items: flex-start;\n}\n\n.data-\\[input-type\\=checkbox\\]\\:items-center[data-input-type="checkbox"] {\n align-items: center;\n}\n\n.data-\\[role\\=user\\]\\:justify-end[data-role="user"] {\n justify-content: flex-end;\n}\n\n.data-\\[role\\=user\\]\\:whitespace-pre-wrap[data-role="user"] {\n white-space: pre-wrap;\n}\n\n.data-\\[mobile\\]\\:rounded-none[data-mobile] {\n border-radius: 0px;\n}\n\n.data-\\[position\\=left\\]\\:border-r[data-position="left"] {\n border-right-width: 1px;\n}\n\n.data-\\[position\\=right\\]\\:border-l[data-position="right"] {\n border-left-width: 1px;\n}\n\n.data-\\[invalid\\]\\:border-\\[--error-border-color\\][data-invalid] {\n border-color: var(--error-border-color);\n}\n\n.data-\\[state\\=active\\]\\:border-inkeep-primary-medium-subtle[data-state="active"] {\n border-color: var(--ikp-color-inkeep-primary-medium-subtle);\n}\n\n.data-\\[state\\=checked\\]\\:border-gray-1000[data-state="checked"] {\n border-color: var(--ikp-color-gray-1000);\n}\n\n.data-\\[active\\]\\:bg-white[data-active] {\n --tw-bg-opacity: 1;\n background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));\n}\n\n.data-\\[role\\=user\\]\\:bg-gray-50[data-role="user"] {\n background-color: var(--ikp-color-gray-50);\n}\n\n.data-\\[state\\=active\\]\\:bg-inkeep-primary-light-subtle[data-state="active"] {\n background-color: var(--ikp-color-inkeep-primary-light-subtle);\n}\n\n.data-\\[state\\=checked\\]\\:bg-gray-1000[data-state="checked"] {\n background-color: var(--ikp-color-gray-1000);\n}\n\n.data-\\[username\\]\\:bg-inkeep-primary-lighter[data-username] {\n background-color: var(--ikp-color-inkeep-primary-lighter);\n}\n\n.data-\\[has-content\\]\\:pb-2[data-has-content] {\n padding-bottom: 0.5rem;\n}\n\n.data-\\[position\\=left\\]\\:pr-1[data-position="left"] {\n padding-right: 0.25rem;\n}\n\n.data-\\[position\\=right\\]\\:pl-1[data-position="right"] {\n padding-left: 0.25rem;\n}\n\n.data-\\[is-numeric\\=true\\]\\:text-end[data-is-numeric="true"] {\n text-align: end;\n}\n\n.data-\\[highlighted\\]\\:font-semibold[data-highlighted] {\n font-weight: 600;\n}\n\n.data-\\[active\\]\\:text-gray-600[data-active] {\n color: var(--ikp-color-gray-600);\n}\n\n.data-\\[active\\]\\:text-gray-800[data-active] {\n color: var(--ikp-color-gray-800);\n}\n\n.data-\\[copied\\]\\:text-inkeep-primary-medium[data-copied] {\n color: var(--ikp-color-inkeep-primary-medium);\n}\n\n.data-\\[downvoted\\]\\:text-inkeep-primary-medium[data-downvoted] {\n color: var(--ikp-color-inkeep-primary-medium);\n}\n\n.data-\\[highlighted\\]\\:text-inkeep-primary-text-subtle[data-highlighted] {\n color: var(--ikp-color-inkeep-primary-text-subtle);\n}\n\n.data-\\[is-match\\]\\:text-inkeep-expanded-primary-700[data-is-match] {\n color: var(--ikp-color-inkeep-expanded-primary-700);\n}\n\n.data-\\[role\\=user\\]\\:text-gray-700[data-role="user"] {\n color: var(--ikp-color-gray-700);\n}\n\n.data-\\[state\\=active\\]\\:text-inkeep-expanded-primary-900[data-state="active"] {\n color: var(--ikp-color-inkeep-expanded-primary-900);\n}\n\n.data-\\[state\\=checked\\]\\:text-white[data-state="checked"] {\n --tw-text-opacity: 1;\n color: rgb(255 255 255 / var(--tw-text-opacity, 1));\n}\n\n.data-\\[type\\=\\"stackoverflow\\"\\]\\:text-green-500[data-type="stackoverflow"] {\n --tw-text-opacity: 1;\n color: rgb(34 197 94 / var(--tw-text-opacity, 1));\n}\n\n.data-\\[type\\=icon\\]\\:data-\\[role\\=user\\]\\:text-inkeep-primary-medium[data-role="user"][data-type="icon"] {\n color: var(--ikp-color-inkeep-primary-medium);\n}\n\n.data-\\[type\\^\\=\\"github\\"\\]\\:text-purple-500[data-type^="github"] {\n --tw-text-opacity: 1;\n color: rgb(168 85 247 / var(--tw-text-opacity, 1));\n}\n\n.data-\\[upvoted\\]\\:text-inkeep-primary-medium[data-upvoted] {\n color: var(--ikp-color-inkeep-primary-medium);\n}\n\n.data-\\[disabled\\]\\:opacity-50[data-disabled] {\n opacity: 0.5;\n}\n\n.data-\\[state\\=closed\\]\\:opacity-0[data-state="closed"] {\n opacity: 0;\n}\n\n.data-\\[active\\]\\:shadow[data-active] {\n --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);\n --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n.data-\\[invalid\\]\\:shadow-\\[0_0_0_1px_var\\(--error-border-color\\)\\][data-invalid] {\n --tw-shadow: 0 0 0 1px var(--error-border-color);\n --tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n.data-\\[disable-transitions\\]\\:transition-none[data-disable-transitions] {\n transition-property: none;\n}\n\n.data-\\[type\\=icon\\]\\:\\[--end-color\\:theme\\(colors\\.inkeep-expanded-primary\\.300\\)\\][data-type="icon"] {\n --end-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.data-\\[type\\=icon\\]\\:data-\\[role\\=assistant\\]\\:\\[--end-color\\:theme\\(colors\\.inkeep-expanded-primary\\.700\\)\\][data-role="assistant"][data-type="icon"] {\n --end-color: var(--ikp-color-inkeep-expanded-primary-700);\n}\n\n.data-\\[mobile\\]\\:\\[--input-height\\:theme\\(spacing\\.20\\)\\][data-mobile] {\n --input-height: 5rem;\n}\n\n.data-\\[invalid\\]\\:\\[--shadow-color\\:theme\\(colors\\.red\\.500\\)\\][data-invalid] {\n --shadow-color: #ef4444;\n}\n\n.data-\\[type\\=icon\\]\\:data-\\[role\\=assistant\\]\\:\\[--start-color\\:theme\\(colors\\.inkeep-expanded-primary\\.300\\)\\][data-role="assistant"][data-type="icon"] {\n --start-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.data-\\[type\\=icon\\]\\:\\[--start-color\\:theme\\(colors\\.inkeep-expanded-primary\\.50\\)\\][data-type="icon"] {\n --start-color: var(--ikp-color-inkeep-expanded-primary-50);\n}\n\n.data-\\[required\\]\\:after\\:absolute[data-required]::after {\n content: var(--tw-content);\n position: absolute;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:absolute[data-show-toolbar]::after {\n content: var(--tw-content);\n position: absolute;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:left-0[data-show-toolbar]::after {\n content: var(--tw-content);\n left: 0px;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:top-full[data-show-toolbar]::after {\n content: var(--tw-content);\n top: 100%;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:z-start[data-show-toolbar]::after {\n content: var(--tw-content);\n z-index: var(--ikp-z-index-start);\n}\n\n.data-\\[required\\]\\:after\\:ml-1[data-required]::after {\n content: var(--tw-content);\n margin-left: 0.25rem;\n}\n\n.data-\\[required\\]\\:after\\:mt-0[data-required]::after {\n content: var(--tw-content);\n margin-top: 0px;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:h-\\[1rem\\][data-show-toolbar]::after {\n content: var(--tw-content);\n height: 1rem;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:w-full[data-show-toolbar]::after {\n content: var(--tw-content);\n width: 100%;\n}\n\n.data-\\[show-toolbar\\]\\:after\\:bg-\\[linear-gradient\\(currentColor\\2c _transparent\\)\\][data-show-toolbar]::after {\n content: var(--tw-content);\n background-image: linear-gradient(currentColor, transparent);\n}\n\n.data-\\[required\\]\\:after\\:text-red-500[data-required]::after {\n content: var(--tw-content);\n --tw-text-opacity: 1;\n color: rgb(239 68 68 / var(--tw-text-opacity, 1));\n}\n\n.data-\\[show-toolbar\\]\\:after\\:text-white[data-show-toolbar]::after {\n content: var(--tw-content);\n --tw-text-opacity: 1;\n color: rgb(255 255 255 / var(--tw-text-opacity, 1));\n}\n\n.data-\\[required\\]\\:after\\:\\[content\\:\\"\\*\\"\\][data-required]::after {\n content: "*";\n}\n\n@keyframes spin {\n\n to {\n content: var(--tw-content);\n transform: rotate(360deg);\n }\n}\n\n.data-\\[highlight\\]\\:first\\:before\\:animate-\\[spin_4s_linear_infinite\\]:first-child[data-highlight]::before {\n content: var(--tw-content);\n animation: spin 4s linear infinite;\n}\n\n.data-\\[highlight\\]\\:first\\:before\\:\\[background-image\\:conic-gradient\\(transparent\\2c theme\\(colors\\.inkeep-expanded-primary\\.600\\)\\2c transparent_30\\%\\)\\]:first-child[data-highlight]::before {\n content: var(--tw-content);\n background-image: conic-gradient(transparent,var(--ikp-color-inkeep-expanded-primary-600),transparent 30%);\n}\n\n:not(.dark) .light\\:text-gray-700 {\n color: var(--ikp-color-gray-700);\n}\n\n[data-widget-md] .ikp-md\\:mb-0 {\n margin-bottom: 0px;\n}\n\n[data-widget-md] .ikp-md\\:flex {\n display: flex;\n}\n\n[data-widget-md] .ikp-md\\:hidden {\n display: none;\n}\n\n[data-widget-md] .ikp-md\\:h-12 {\n height: 3rem;\n}\n\n[data-widget-md] .ikp-md\\:flex-row {\n flex-direction: row;\n}\n\n[data-widget-md] .ikp-md\\:flex-col {\n flex-direction: column;\n}\n\n[data-widget-md] .ikp-md\\:items-start {\n align-items: flex-start;\n}\n\n[data-widget-md] .ikp-md\\:px-10 {\n padding-left: 2.5rem;\n padding-right: 2.5rem;\n}\n\n[data-widget-md] .ikp-md\\:py-14 {\n padding-top: 3.5rem;\n padding-bottom: 3.5rem;\n}\n\n[data-widget-md] .ikp-md\\:pb-14 {\n padding-bottom: 3.5rem;\n}\n\n[data-widget-md] .ikp-md\\:pl-3 {\n padding-left: 0.75rem;\n}\n\n[data-widget-md] .ikp-md\\:pr-3 {\n padding-right: 0.75rem;\n}\n\n[data-widget-md] .ikp-md\\:pr-6 {\n padding-right: 1.5rem;\n}\n\n.hover\\:scale-110:hover:not(:disabled) {\n --tw-scale-x: 1.1;\n --tw-scale-y: 1.1;\n transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));\n}\n\n.hover\\:border-gray-300:hover:not(:disabled) {\n border-color: var(--ikp-color-gray-300);\n}\n\n.hover\\:bg-gray-100:hover:not(:disabled) {\n background-color: var(--ikp-color-gray-100);\n}\n\n.hover\\:bg-gray-200:hover:not(:disabled) {\n background-color: var(--ikp-color-gray-200);\n}\n\n.hover\\:bg-gray-50:hover:not(:disabled) {\n background-color: var(--ikp-color-gray-50);\n}\n\n.hover\\:bg-gray-900:hover:not(:disabled) {\n background-color: var(--ikp-color-gray-900);\n}\n\n.hover\\:bg-inkeep-primary-light-subtle:hover:not(:disabled) {\n background-color: var(--ikp-color-inkeep-primary-light-subtle);\n}\n\n.hover\\:bg-transparent:hover:not(:disabled) {\n background-color: transparent;\n}\n\n.hover\\:text-gray-700:hover:not(:disabled) {\n color: var(--ikp-color-gray-700);\n}\n\n.hover\\:text-gray-800:hover:not(:disabled) {\n color: var(--ikp-color-gray-800);\n}\n\n.hover\\:text-inkeep-primary-strong:hover:not(:disabled) {\n color: var(--ikp-color-inkeep-primary-strong);\n}\n\n.hover\\:text-inkeep-primary-stronger:hover:not(:disabled) {\n color: var(--ikp-color-inkeep-primary-stronger);\n}\n\n.hover\\:underline:hover:not(:disabled) {\n text-decoration-line: underline;\n}\n\n.hover\\:opacity-100:hover:not(:disabled) {\n opacity: 1;\n}\n\n.hover\\:disabled\\:bg-gray-100:disabled:hover:not(:disabled) {\n background-color: var(--ikp-color-gray-100);\n}\n\n.hover\\:disabled\\:\\[background\\:none\\]:disabled:hover:not(:disabled) {\n background: none;\n}\n\n.hover\\:data-\\[state\\=active\\]\\:bg-inkeep-primary-light-subtle[data-state="active"]:hover:not(:disabled) {\n background-color: var(--ikp-color-inkeep-primary-light-subtle);\n}\n\n.data-\\[is-match\\]\\:hover\\:text-inkeep-expanded-primary-800:hover:not(:disabled)[data-is-match] {\n color: var(--ikp-color-inkeep-expanded-primary-800);\n}\n\n.befter\\:pointer-events-none::before {\n pointer-events: none;\n}\n\n.befter\\:absolute::before {\n position: absolute;\n}\n\n.befter\\:inset-x-0::before {\n left: 0px;\n right: 0px;\n}\n\n.befter\\:h-10::before {\n height: 2.5rem;\n}\n\n.befter\\:transition-opacity::before {\n transition-property: opacity;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n\n.befter\\:duration-300::before {\n transition-duration: 300ms;\n}\n\n.befter\\:ease-in-out::before {\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n}\n\n.befter\\:content-\\[\\"\\"\\]::before {\n --tw-content: "";\n content: var(--tw-content);\n}\n\n.befter\\:pointer-events-none::after {\n pointer-events: none;\n}\n\n.befter\\:absolute::after {\n position: absolute;\n}\n\n.befter\\:inset-x-0::after {\n left: 0px;\n right: 0px;\n}\n\n.befter\\:h-10::after {\n height: 2.5rem;\n}\n\n.befter\\:transition-opacity::after {\n transition-property: opacity;\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-duration: 150ms;\n}\n\n.befter\\:duration-300::after {\n transition-duration: 300ms;\n}\n\n.befter\\:ease-in-out::after {\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n}\n\n.befter\\:content-\\[\\"\\"\\]::after {\n --tw-content: "";\n content: var(--tw-content);\n}\n\n.selected\\:border-inkeep-primary-medium-subtle[data-selected="true"] {\n border-color: var(--ikp-color-inkeep-primary-medium-subtle);\n}\n\n.selected\\:bg-inkeep-primary-light-subtle[data-selected="true"] {\n background-color: var(--ikp-color-inkeep-primary-light-subtle);\n}\n\n.selected\\:text-inkeep-primary-strong[data-selected="true"] {\n color: var(--ikp-color-inkeep-primary-strong);\n}\n\n.selected\\:border-inkeep-primary-medium-subtle:hover {\n border-color: var(--ikp-color-inkeep-primary-medium-subtle);\n}\n\n.selected\\:bg-inkeep-primary-light-subtle:hover {\n background-color: var(--ikp-color-inkeep-primary-light-subtle);\n}\n\n.selected\\:text-inkeep-primary-strong:hover {\n color: var(--ikp-color-inkeep-primary-strong);\n}\n\n.group[data-selected="true"] .group-selected\\:text-inkeep-primary-strong {\n color: var(--ikp-color-inkeep-primary-strong);\n}\n\n.group[data-selected="true"] .group-selected\\:text-inkeep-primary-text-bold {\n color: var(--ikp-color-inkeep-primary-text-bold);\n}\n\n.group[data-selected="true"] .group-selected\\:text-inkeep-primary-text-subtle {\n color: var(--ikp-color-inkeep-primary-text-subtle);\n}\n\n.group[data-selected="true"] .group-selected\\:opacity-100 {\n opacity: 1;\n}\n\n.group:hover .group-selected\\:text-inkeep-primary-strong {\n color: var(--ikp-color-inkeep-primary-strong);\n}\n\n.group:hover .group-selected\\:text-inkeep-primary-text-bold {\n color: var(--ikp-color-inkeep-primary-text-bold);\n}\n\n.group:hover .group-selected\\:text-inkeep-primary-text-subtle {\n color: var(--ikp-color-inkeep-primary-text-subtle);\n}\n\n.group:hover .group-selected\\:opacity-100 {\n opacity: 1;\n}\n\n.dark\\:border-gray-700:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-gray-700);\n}\n\n.dark\\:border-gray-dark-500:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-gray-dark-500);\n}\n\n.dark\\:border-gray-dark-700:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-gray-dark-700);\n}\n\n.dark\\:border-inkeep-expanded-primary-200:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-inkeep-expanded-primary-200);\n}\n\n.dark\\:border-white-alpha-200:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-white-alpha-200);\n}\n\n.dark\\:bg-gray-dark-600:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-600);\n}\n\n.dark\\:bg-gray-dark-700:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-700);\n}\n\n.dark\\:bg-gray-dark-800:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-800);\n}\n\n.dark\\:bg-gray-dark-900:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-900);\n}\n\n.dark\\:bg-gray-dark-950:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-950);\n}\n\n.dark\\:bg-inkeep-expanded-primary-300:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:bg-overlay-dark:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-overlay-dark);\n}\n\n.dark\\:bg-transparent:is([data-theme="dark"] *) {\n background-color: transparent;\n}\n\n.dark\\:bg-white-alpha-100:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.dark\\:bg-white-alpha-200:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-200);\n}\n\n.dark\\:bg-white-alpha-50:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-50);\n}\n\n.dark\\:bg-white-alpha-800:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-800);\n}\n\n.dark\\:bg-\\[linear-gradient\\(to_bottom_right\\2c _var\\(--ikp-color-gray-dark-300\\)\\2c _var\\(--ikp-color-gray-dark-100\\)\\)\\]:is([data-theme="dark"] *) {\n background-image: linear-gradient(to bottom right, var(--ikp-color-gray-dark-300), var(--ikp-color-gray-dark-100));\n}\n\n.dark\\:bg-\\[linear-gradient\\(to_top\\2c _var\\(--ikp-color-gray-dark-600\\)\\2c _transparent\\)\\]:is([data-theme="dark"] *) {\n background-image: linear-gradient(to top, var(--ikp-color-gray-dark-600), transparent);\n}\n\n.dark\\:fill-gray-dark-800:is([data-theme="dark"] *) {\n fill: var(--ikp-color-gray-dark-800);\n}\n\n.dark\\:text-gray-200:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-200);\n}\n\n.dark\\:text-gray-400:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-400);\n}\n\n.dark\\:text-gray-dark-100:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-100);\n}\n\n.dark\\:text-gray-dark-200:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-200);\n}\n\n.dark\\:text-gray-dark-300:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-300);\n}\n\n.dark\\:text-gray-dark-400:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-400);\n}\n\n.dark\\:text-gray-dark-950:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-950);\n}\n\n.dark\\:text-inkeep-expanded-primary-100:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-100);\n}\n\n.dark\\:text-inkeep-expanded-primary-300:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:text-inkeep-expanded-primary-500:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-500);\n}\n\n.dark\\:text-red-300:is([data-theme="dark"] *) {\n --tw-text-opacity: 1;\n color: rgb(252 165 165 / var(--tw-text-opacity, 1));\n}\n\n.dark\\:text-white-alpha-500:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-500);\n}\n\n.dark\\:text-white-alpha-600:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-600);\n}\n\n.dark\\:text-white-alpha-700:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-700);\n}\n\n.dark\\:text-white-alpha-900:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-900);\n}\n\n.dark\\:text-white-alpha-950:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-950);\n}\n\n.dark\\:shadow-none:is([data-theme="dark"] *) {\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n.dark\\:shadow-\\[none\\]:is([data-theme="dark"] *) {\n --tw-shadow-color: none;\n --tw-shadow: var(--tw-shadow-colored);\n}\n\n.dark\\:\\[--end-color\\:theme\\(colors\\.gray-dark\\.600\\)\\]:is([data-theme="dark"] *) {\n --end-color: var(--ikp-color-gray-dark-600);\n}\n\n.dark\\:\\[--end-color\\:theme\\(colors\\.inkeep-expanded-primary\\.300\\)\\]:is([data-theme="dark"] *) {\n --end-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:\\[--end-color\\:theme\\(colors\\.white-alpha\\.300\\)\\]:is([data-theme="dark"] *) {\n --end-color: var(--ikp-color-white-alpha-300);\n}\n\n.dark\\:\\[--error-border-color\\:theme\\(colors\\.red\\.300\\)\\]:is([data-theme="dark"] *) {\n --error-border-color: #fca5a5;\n}\n\n.dark\\:\\[--focus-border-color\\:theme\\(colors\\.blue\\.300\\)\\]:is([data-theme="dark"] *) {\n --focus-border-color: #93c5fd;\n}\n\n.dark\\:\\[--scrollbar-color\\:var\\(--color-gray-dark-600\\)\\]:is([data-theme="dark"] *) {\n --scrollbar-color: var(--color-gray-dark-600);\n}\n\n.dark\\:\\[--start-color\\:theme\\(colors\\.gray-dark\\.800\\)\\]:is([data-theme="dark"] *) {\n --start-color: var(--ikp-color-gray-dark-800);\n}\n\n.dark\\:\\[--start-color\\:theme\\(colors\\.gray\\.300\\)\\]:is([data-theme="dark"] *) {\n --start-color: var(--ikp-color-gray-300);\n}\n\n.dark\\:\\[--start-color\\:theme\\(colors\\.inkeep-expanded-primary\\.50\\)\\]:is([data-theme="dark"] *) {\n --start-color: var(--ikp-color-inkeep-expanded-primary-50);\n}\n\n.dark\\:\\[background\\:linear-gradient\\(270deg\\2c theme\\(colors\\.inkeep-expanded-primary\\.100\\)\\2c transparent\\)_-200\\%_50\\%_\\/_25\\%_100\\%_no-repeat\\2c theme\\(colors\\.inkeep-expanded-primary\\.400\\)\\]:is([data-theme="dark"] *) {\n background: linear-gradient(270deg,var(--ikp-color-inkeep-expanded-primary-100),transparent) -200% 50% / 25% 100% no-repeat,var(--ikp-color-inkeep-expanded-primary-400);\n}\n\n.dark\\:file\\:text-white-alpha-700:is([data-theme="dark"] *)::file-selector-button {\n color: var(--ikp-color-white-alpha-700);\n}\n\n.dark\\:placeholder\\:text-gray-dark-200:is([data-theme="dark"] *)::-moz-placeholder {\n color: var(--ikp-color-gray-dark-200);\n}\n\n.dark\\:placeholder\\:text-gray-dark-200:is([data-theme="dark"] *)::placeholder {\n color: var(--ikp-color-gray-dark-200);\n}\n\n.dark\\:before\\:bg-gray-dark-950:is([data-theme="dark"] *)::before {\n content: var(--tw-content);\n background-color: var(--ikp-color-gray-dark-950);\n}\n\n.dark\\:before\\:bg-\\[linear-gradient\\(transparent\\2c _var\\(--ikp-color-gray-dark-950\\)\\)\\]:is([data-theme="dark"] *)::before {\n content: var(--tw-content);\n background-image: linear-gradient(transparent, var(--ikp-color-gray-dark-950));\n}\n\n.dark\\:before\\:bg-\\[linear-gradient\\(var\\(--ikp-color-gray-dark-950\\)\\2c _transparent\\)\\]:is([data-theme="dark"] *)::before {\n content: var(--tw-content);\n background-image: linear-gradient(var(--ikp-color-gray-dark-950), transparent);\n}\n\n.dark\\:after\\:bg-gray-dark-950:is([data-theme="dark"] *)::after {\n content: var(--tw-content);\n background-color: var(--ikp-color-gray-dark-950);\n}\n\n.dark\\:after\\:bg-inkeep-primary-light:is([data-theme="dark"] *)::after {\n content: var(--tw-content);\n background-color: var(--ikp-color-inkeep-primary-light);\n}\n\n.dark\\:after\\:bg-\\[linear-gradient\\(transparent\\2c _var\\(--ikp-color-gray-dark-950\\)\\)\\]:is([data-theme="dark"] *)::after {\n content: var(--tw-content);\n background-image: linear-gradient(transparent, var(--ikp-color-gray-dark-950));\n}\n\n.after\\:dark\\:text-gray-dark-950:is([data-theme="dark"] *)::after {\n content: var(--tw-content);\n color: var(--ikp-color-gray-dark-950);\n}\n\n.dark\\:focus\\:bg-gray-dark-800:focus:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-800);\n}\n\n.dark\\:focus\\:outline-inkeep-expanded-primary-300:focus:is([data-theme="dark"] *) {\n outline-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:focus-visible\\:ring-white-alpha-900:focus-visible:is([data-theme="dark"] *) {\n --tw-ring-color: var(--ikp-color-white-alpha-900);\n}\n\n.dark\\:focus-visible\\:ring-offset-gray-950:focus-visible:is([data-theme="dark"] *) {\n --tw-ring-offset-color: var(--ikp-color-gray-950);\n}\n\n.dark\\:active\\:bg-inkeep-expanded-primary-200:active:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-inkeep-expanded-primary-200);\n}\n\n.dark\\:active\\:bg-white-alpha-100:active:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.dark\\:active\\:bg-white-alpha-200:active:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-200);\n}\n\n.dark\\:active\\:bg-white-alpha-400:active:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-400);\n}\n\n.dark\\:disabled\\:text-white-alpha-200:disabled:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-200);\n}\n\n.group:hover .dark\\:group-hover\\:text-white-alpha-600:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-600);\n}\n\n.dark\\:data-\\[state\\=active\\]\\:border-inkeep-expanded-primary-300[data-state="active"]:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:data-\\[state\\=checked\\]\\:border-white-alpha-950[data-state="checked"]:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-white-alpha-950);\n}\n\n.dark\\:data-\\[active\\]\\:bg-gray-dark-700[data-active]:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-700);\n}\n\n.dark\\:data-\\[state\\=active\\]\\:bg-white-alpha-100[data-state="active"]:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.dark\\:data-\\[state\\=checked\\]\\:bg-white-alpha-950[data-state="checked"]:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-950);\n}\n\n.dark\\:data-\\[username\\]\\:bg-inkeep-expanded-primary-300[data-username]:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:data-\\[active\\]\\:text-white-alpha-600[data-active]:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-600);\n}\n\n.dark\\:data-\\[active\\]\\:text-white-alpha-950[data-active]:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-950);\n}\n\n.dark\\:data-\\[highlighted\\]\\:text-gray-dark-50[data-highlighted]:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-50);\n}\n\n.dark\\:data-\\[is-match\\]\\:text-inkeep-expanded-primary-300[data-is-match]:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:data-\\[role\\=user\\]\\:text-white-alpha-700[data-role="user"]:is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-700);\n}\n\n.dark\\:data-\\[state\\=active\\]\\:text-inkeep-expanded-primary-300[data-state="active"]:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:data-\\[state\\=checked\\]\\:text-gray-1000[data-state="checked"]:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-1000);\n}\n\n.dark\\:data-\\[type\\=icon\\]\\:data-\\[role\\=user\\]\\:text-inkeep-expanded-primary-300[data-role="user"][data-type="icon"]:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.data-\\[downvoted\\]\\:dark\\:text-inkeep-expanded-primary-300:is([data-theme="dark"] *)[data-downvoted] {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.data-\\[upvoted\\]\\:dark\\:text-inkeep-expanded-primary-300:is([data-theme="dark"] *)[data-upvoted] {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:data-\\[type\\=icon\\]\\:data-\\[role\\=assistant\\]\\:\\[--end-color\\:theme\\(colors\\.inkeep-expanded-primary\\.300\\)\\][data-role="assistant"][data-type="icon"]:is([data-theme="dark"] *) {\n --end-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:data-\\[type\\=icon\\]\\:data-\\[role\\=assistant\\]\\:\\[--start-color\\:theme\\(colors\\.inkeep-expanded-primary\\.50\\)\\][data-role="assistant"][data-type="icon"]:is([data-theme="dark"] *) {\n --start-color: var(--ikp-color-inkeep-expanded-primary-50);\n}\n\n.dark\\:data-\\[required\\]\\:after\\:text-red-300[data-required]:is([data-theme="dark"] *)::after {\n content: var(--tw-content);\n --tw-text-opacity: 1;\n color: rgb(252 165 165 / var(--tw-text-opacity, 1));\n}\n\n.data-\\[show-toolbar\\]\\:after\\:dark\\:text-gray-dark-950:is([data-theme="dark"] *)[data-show-toolbar]::after {\n content: var(--tw-content);\n color: var(--ikp-color-gray-dark-950);\n}\n\n.dark\\:data-\\[highlight\\]\\:first\\:before\\:\\[background-image\\:conic-gradient\\(transparent\\2c theme\\(colors\\.inkeep-expanded-primary\\.300\\)\\2c transparent_30\\%\\)\\]:first-child[data-highlight]:is([data-theme="dark"] *)::before {\n content: var(--tw-content);\n background-image: conic-gradient(transparent,var(--ikp-color-inkeep-expanded-primary-300),transparent 30%);\n}\n\n.dark\\:hover\\:border-white-alpha-300:hover:not(:disabled):is([data-theme="dark"] *) {\n border-color: var(--ikp-color-white-alpha-300);\n}\n\n.dark\\:hover\\:bg-gray-dark-800:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-gray-dark-800);\n}\n\n.dark\\:hover\\:bg-inkeep-expanded-primary-200:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-inkeep-expanded-primary-200);\n}\n\n.dark\\:hover\\:bg-transparent:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: transparent;\n}\n\n.dark\\:hover\\:bg-white-alpha-100:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.dark\\:hover\\:bg-white-alpha-200:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-200);\n}\n\n.dark\\:hover\\:bg-white-alpha-50:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-50);\n}\n\n.dark\\:hover\\:text-inkeep-expanded-primary-100:hover:not(:disabled):is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-100);\n}\n\n.dark\\:hover\\:text-inkeep-expanded-primary-300:hover:not(:disabled):is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:hover\\:text-white-alpha-500:hover:not(:disabled):is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-500);\n}\n\n.dark\\:hover\\:text-white-alpha-800:hover:not(:disabled):is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-800);\n}\n\n.dark\\:hover\\:text-white-alpha-950:hover:not(:disabled):is([data-theme="dark"] *) {\n color: var(--ikp-color-white-alpha-950);\n}\n\n.hover\\:dark\\:text-white-alpha-950:is([data-theme="dark"] *):hover:not(:disabled) {\n color: var(--ikp-color-white-alpha-950);\n}\n\n.dark\\:hover\\:disabled\\:bg-white-alpha-100:disabled:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.dark\\:hover\\:data-\\[state\\=active\\]\\:bg-white-alpha-100[data-state="active"]:hover:not(:disabled):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.dark\\:data-\\[is-match\\]\\:hover\\:text-inkeep-expanded-primary-200:hover:not(:disabled)[data-is-match]:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-200);\n}\n\n.dark\\:selected\\:border-inkeep-expanded-primary-300[data-selected="true"]:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:selected\\:bg-white-alpha-200[data-selected="true"]:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-200);\n}\n\n.dark\\:selected\\:text-inkeep-expanded-primary-300[data-selected="true"]:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:selected\\:border-inkeep-expanded-primary-300:hover:is([data-theme="dark"] *) {\n border-color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.dark\\:selected\\:bg-white-alpha-200:hover:is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-200);\n}\n\n.dark\\:selected\\:text-inkeep-expanded-primary-300:hover:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.group[data-selected="true"] .dark\\:group-selected\\:text-gray-dark-100:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-100);\n}\n\n.group[data-selected="true"] .dark\\:group-selected\\:text-inkeep-expanded-primary-300:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.group[data-selected="true"] .dark\\:group-selected\\:text-white:is([data-theme="dark"] *) {\n --tw-text-opacity: 1;\n color: rgb(255 255 255 / var(--tw-text-opacity, 1));\n}\n\n.group:hover .dark\\:group-selected\\:text-gray-dark-100:is([data-theme="dark"] *) {\n color: var(--ikp-color-gray-dark-100);\n}\n\n.group:hover .dark\\:group-selected\\:text-inkeep-expanded-primary-300:is([data-theme="dark"] *) {\n color: var(--ikp-color-inkeep-expanded-primary-300);\n}\n\n.group:hover .dark\\:group-selected\\:text-white:is([data-theme="dark"] *) {\n --tw-text-opacity: 1;\n color: rgb(255 255 255 / var(--tw-text-opacity, 1));\n}\n\n@media (min-width: 640px) {\n\n .sm\\:w-\\[420px\\] {\n width: 420px;\n }\n}\n\n@media (min-width: 768px) {\n\n .md\\:my-12 {\n margin-top: 3rem;\n margin-bottom: 3rem;\n }\n\n .md\\:flex {\n display: flex;\n }\n\n .md\\:hidden {\n display: none;\n }\n\n .md\\:h-\\[min\\(760px\\2c 100\\%\\)\\] {\n height: min(760px,100%);\n }\n\n .md\\:w-\\[min\\(600px\\2c 100\\%\\)\\] {\n width: min(600px,100%);\n }\n\n .md\\:min-w-\\[min\\(320px\\2c 100\\%\\)\\] {\n min-width: min(320px,100%);\n }\n\n .md\\:p-10 {\n padding: 2.5rem;\n }\n\n .md\\:text-4xl {\n font-size: var(--ikp-font-size-4xl);\n }\n\n .md\\:text-sm {\n font-size: var(--ikp-font-size-sm);\n }\n\n .md\\:leading-5 {\n line-height: 1.25rem;\n }\n\n .md\\:data-\\[view\\=dual-pane\\]\\:hidden[data-view="dual-pane"] {\n display: none;\n }\n\n .md\\:data-\\[dual-pane-search-expanded\\]\\:h-\\[min\\(calc\\(85vh_-_72px\\)\\2c calc\\(900px_-_72px_-_135px\\)\\)\\][data-dual-pane-search-expanded] {\n height: min(calc(85vh - 72px),calc(900px - 72px - 135px));\n }\n\n .md\\:data-\\[view\\=dual-pane\\]\\:\\[grid-template\\:\\"breadcrumbs_breadcrumbs_breadcrumbs\\"\\"icon_title_tag\\"\\"description_description_description\\"\\/auto_auto_1fr\\][data-view="dual-pane"] {\n grid-template: "breadcrumbs breadcrumbs breadcrumbs""icon title tag""description description description"/auto auto 1fr;\n }\n}\n\n@media (min-width: 1024px) {\n\n .lg\\:h-\\[min\\(800px\\2c 100\\%\\)\\] {\n height: min(800px,100%);\n }\n\n .lg\\:w-\\[min\\(640px\\2c 100\\%\\)\\] {\n width: min(640px,100%);\n }\n}\n\n@media (min-width: 1536px) {\n\n .\\32xl\\:h-\\[min\\(900px\\2c 100\\%\\)\\] {\n height: min(900px,100%);\n }\n\n .\\32xl\\:w-\\[min\\(760px\\2c 100\\%\\)\\] {\n width: min(760px,100%);\n }\n}\n\n.\\[\\&\\:not\\(\\:last-child\\)\\]\\:after\\:absolute:not(:last-child)::after {\n content: var(--tw-content);\n position: absolute;\n}\n\n.\\[\\&\\:not\\(\\:last-child\\)\\]\\:after\\:inset-x-6:not(:last-child)::after {\n content: var(--tw-content);\n left: 1.5rem;\n right: 1.5rem;\n}\n\n.\\[\\&\\:not\\(\\:last-child\\)\\]\\:after\\:bottom-0:not(:last-child)::after {\n content: var(--tw-content);\n bottom: 0px;\n}\n\n.\\[\\&\\:not\\(\\:last-child\\)\\]\\:after\\:border-b:not(:last-child)::after {\n content: var(--tw-content);\n border-bottom-width: 1px;\n}\n\n[data-widget-md] .ikp-md\\:\\[\\&\\:not\\(\\:last-child\\)\\]\\:after\\:inset-x-8:not(:last-child)::after {\n content: var(--tw-content);\n left: 2rem;\n right: 2rem;\n}\n\n.focus\\:\\[\\&\\:not\\(\\[data-invalid\\]\\)\\]\\:border-\\[--focus-border-color\\]:not([data-invalid]):focus {\n border-color: var(--focus-border-color);\n}\n\n.focus\\:\\[\\&\\:not\\(\\[data-invalid\\]\\)\\]\\:shadow-\\[0_0_0_1px_var\\(--focus-border-color\\)\\]:not([data-invalid]):focus {\n --tw-shadow: 0 0 0 1px var(--focus-border-color);\n --tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n.\\[\\&\\:where\\(\\:hover\\2c \\:focus\\)\\]\\:bg-slate-400\\/5:where(:hover,:focus) {\n background-color: rgb(148 163 184 / 0.05);\n}\n\n.dark\\:\\[\\&\\:where\\(\\:hover\\2c \\:focus\\)\\]\\:bg-white-alpha-100:where(:hover,:focus):is([data-theme="dark"] *) {\n background-color: var(--ikp-color-white-alpha-100);\n}\n\n.\\[\\&\\>\\:first-child\\]\\:basis-full>:first-child {\n flex-basis: 100%;\n}\n\n.\\[\\&\\[data-mobile\\]\\>div\\]\\:h-full[data-mobile]>div {\n height: 100%;\n}\n\n.\\[\\&\\[data-mobile\\]\\>div\\]\\:max-h-\\[unset\\][data-mobile]>div {\n max-height: unset;\n}\n\n.\\[\\&\\[data-mobile\\]\\>div\\]\\:max-h-dvh[data-mobile]>div {\n max-height: 100dvh;\n}\n\n.\\[\\&_\\[data-part\\=grid\\]\\]\\:divide-y [data-part=grid] > :not([hidden]) ~ :not([hidden]) {\n --tw-divide-y-reverse: 0;\n border-top-width: calc(1px * calc(1 - var(--tw-divide-y-reverse)));\n border-bottom-width: calc(1px * var(--tw-divide-y-reverse));\n}\n\n.\\[\\&_\\[data-part\\=grid\\]\\]\\:px-1 [data-part=grid] {\n padding-left: 0.25rem;\n padding-right: 0.25rem;\n}\n\n.\\[\\&_a\\]\\:inline a {\n display: inline;\n}\n\n.\\[\\&_a\\]\\:break-words a {\n overflow-wrap: break-word;\n}\n\n.\\[\\&_a\\]\\:rounded-sm a {\n border-radius: 0.125rem;\n}\n\n.\\[\\&_a\\]\\:bg-inkeep-primary-light a {\n background-color: var(--ikp-color-inkeep-primary-light);\n}\n\n.\\[\\&_a\\]\\:px-1 a {\n padding-left: 0.25rem;\n padding-right: 0.25rem;\n}\n\n.\\[\\&_a\\]\\:py-\\[1px\\] a {\n padding-top: 1px;\n padding-bottom: 1px;\n}\n\n.\\[\\&_a\\]\\:font-semibold a {\n font-weight: 600;\n}\n\n.\\[\\&_a\\]\\:text-inkeep-primary-text-subtle a {\n color: var(--ikp-color-inkeep-primary-text-subtle);\n}\n\n.\\[\\&_a\\]\\:no-underline a {\n text-decoration-line: none;\n}\n\n.\\[\\&_a\\]\\:hover\\:text-inkeep-primary-text-bold:hover:not(:disabled) a {\n color: var(--ikp-color-inkeep-primary-text-bold);\n}\n\n.\\[\\&_a\\]\\:hover\\:no-underline:hover:not(:disabled) a {\n text-decoration-line: none;\n}\n\n.\\[\\&_a\\]\\:dark\\:bg-inkeep-primary-text-subtle:is([data-theme="dark"] *) a {\n background-color: var(--ikp-color-inkeep-primary-text-subtle);\n}\n\n.\\[\\&_a\\]\\:dark\\:hover\\:text-inkeep-expanded-primary-200:hover:not(:disabled):is([data-theme="dark"] *) a {\n color: var(--ikp-color-inkeep-expanded-primary-200);\n}\n\n.\\[\\&_em\\]\\:font-bold em {\n font-weight: 700;\n}\n\n.\\[\\&_em\\]\\:not-italic em {\n font-style: normal;\n}\n\n.\\[\\&_li\\]\\:mb-1 li {\n margin-bottom: 0.25rem;\n}\n\n.\\[\\&_svg\\]\\:h-4 svg {\n height: 1rem;\n}\n\n.\\[\\&_svg\\]\\:w-4 svg {\n width: 1rem;\n}\n\n[data-mobile] .\\[\\[data-mobile\\]_\\&\\]\\:h-\\[calc\\(100vh-var\\(--input-height\\)-var\\(--footer-height\\)-var\\(--ask-ai-trigger-height\\)\\)\\] {\n height: calc(100vh - var(--input-height) - var(--footer-height) - var(--ask-ai-trigger-height));\n}\n\n[data-mobile] .\\[\\[data-mobile\\]_\\&\\]\\:h-\\[var\\(--footer-height\\)\\] {\n height: var(--footer-height);\n}\n\n[data-mobile] .\\[\\[data-mobile\\]_\\&\\]\\:max-h-\\[var\\(--input-height\\)\\] {\n max-height: var(--input-height);\n}\n\n[data-mobile] .\\[\\[data-mobile\\]_\\&\\]\\:items-center {\n align-items: center;\n}\n\n[data-mobile] .\\[\\[data-mobile\\]_\\&\\]\\:py-0 {\n padding-top: 0px;\n padding-bottom: 0px;\n}\n\n[data-position="left"]>.\\[\\[data-position\\=\\"left\\"\\]\\>\\&\\]\\:-right-1 {\n right: -0.25rem;\n}\n\n[data-position="left"]>.\\[\\[data-position\\=\\"left\\"\\]\\>\\&\\]\\:after\\:left-1::after {\n content: var(--tw-content);\n left: 0.25rem;\n}\n\n[data-position="right"]>.\\[\\[data-position\\=\\"right\\"\\]\\>\\&\\]\\:-left-1 {\n left: -0.25rem;\n}\n\n[data-position="right"]>.\\[\\[data-position\\=\\"right\\"\\]\\>\\&\\]\\:after\\:right-1::after {\n content: var(--tw-content);\n right: 0.25rem;\n}\n\n[data-show-ask-ai-card] .\\[\\[data-show-ask-ai-card\\]_\\&\\]\\:\\[--ask-ai-trigger-height\\:theme\\(spacing\\.11\\)\\] {\n --ask-ai-trigger-height: 2.75rem;\n}\n\n[data-sidebar] .\\[\\[data-sidebar\\]_\\&\\]\\:m-\\[unset\\] {\n margin: unset;\n}\n\n[data-sidebar] .\\[\\[data-sidebar\\]_\\&\\]\\:mt-auto {\n margin-top: auto;\n}\n\n[data-sidebar] .\\[\\[data-sidebar\\]_\\&\\]\\:h-full {\n height: 100%;\n}\n\n[data-sidebar] .\\[\\[data-sidebar\\]_\\&\\]\\:max-h-\\[unset\\] {\n max-height: unset;\n}\n\n[data-sidebar] .\\[\\[data-sidebar\\]_\\&\\]\\:w-full {\n width: 100%;\n}\n\n[data-view=dual-pane] .\\[\\[data-view\\=dual-pane\\]_\\&\\]\\:block {\n display: block;\n}\n\n[data-view=dual-pane] .\\[\\[data-view\\=dual-pane\\]_\\&\\]\\:flex-\\[0_0_44\\%\\] {\n flex: 0 0 44%;\n}\n\n[data-view=dual-pane] .first\\:\\[\\[data-view\\=dual-pane\\]_\\&\\]\\:flex-1:first-child {\n flex: 1 1 0%;\n}\n\n@media (min-width: 768px) {\n\n [data-view=dual-pane] .md\\:first\\:\\[\\[data-view\\=dual-pane\\]_\\&\\]\\:flex-\\[0_0_44\\%\\]:first-child {\n flex: 0 0 44%;\n }\n}\n',...e}),Tye=qB("div",{_id:"view_toggle"}),Cye=qB("button",{_id:"view_toggle_button",className:qde({slot:"button"})}),Aye=qB(jY,{_id:"view_toggle_icon"});function Nye(e){const{handleToggle:t}=Iye(e);return Wh.jsxs(Tye,{className:qde({slot:"root"}),children:[Wh.jsxs(Cye,{onClick:()=>t("search"),"data-active":SL("search"===e.view),children:[Wh.jsx(Aye,{"data-active":SL("search"===e.view),iconKey:"switchToSearch",className:qde({slot:"icon"})}),e.searchLabel||"Search"]}),Wh.jsxs(Cye,{onClick:()=>t("chat"),"data-active":SL("chat"===e.view),children:[Wh.jsx(Aye,{"data-active":SL("chat"===e.view),iconKey:"switchToChat",className:qde({slot:"icon"})}),e.askAILabel||"Ask AI"]})]})}function Iye(e){const{onToggleView:t,query:n}=e;return{handleToggle:(e,r)=>{null==t||t({view:e,query:n,autoSubmit:r})}}}function Rye(e){const{componentType:t,children:n,modalSettings:r,...a}=e;return Wh.jsx(Nue,{children:Wh.jsx(Eue,{children:Wh.jsx(Sye,{children:Wh.jsx(CB,{config:{...a},componentType:t,children:Wh.jsx(sge,{config:r,children:n})})})})})}function Oye(e){return Wh.jsx(lge,{children:Wh.jsx(cge,{children:e.children})})}function Pye(e){const{children:t,onToggleView:n,isHidden:r,shouldAutoFocusInput:a=!n}=e;return Wh.jsx(Qde,{isHidden:r,shouldAutoFocusInput:a,children:t})}function Dye(e){return Wh.jsx(Pye,{...e,children:Wh.jsx(Lye,{...e})})}function Lye(e){const{onToggleView:t,variant:n,header:r=Mye}=e,a=iL(),o=fL(),i=a&&!o?Oye:K.Fragment;return Wh.jsx(i,{children:Wh.jsxs(Zde,{variant:n??(t?"no-shadow":"container-with-shadow"),"data-composite":SL(!!e.onToggleView||(null==a?void 0:a.isOpen)),children:[Wh.jsx(Jde,{}),Wh.jsxs(epe,{children:[Wh.jsx(r,{...e}),Wh.jsx(Fye,{}),Wh.jsx(Gye,{})]}),Wh.jsx(Wye,{}),Wh.jsx(Yye,{})]})})}function Mye(e){const{onToggleView:t,askAILabel:n,searchLabel:r}=e,a=!!t;return Wh.jsx(tpe,{"data-show-toolbar":SL(a),children:a?Wh.jsxs(npe,{children:[Wh.jsxs(rpe,{children:[Wh.jsx(ape,{}),Wh.jsxs(dpe,{children:[Wh.jsx(hpe,{}),Wh.jsxs(fpe,{side:"bottom",align:"start",children:[Wh.jsx(mpe,{}),Wh.jsx(gpe,{})]})]})]}),Wh.jsx(Nye,{onToggleView:t,askAILabel:n,searchLabel:r,view:"chat"}),Wh.jsx(uge,{})]}):Wh.jsx(uge,{})})}function Fye(){return Wh.jsx(ope,{children:Wh.jsxs(ipe,{children:[Wh.jsx(spe,{children:Wh.jsx(jye,{})}),Wh.jsx(lpe,{children:Wh.jsx(cpe,{})}),Wh.jsx(upe,{})]})})}function jye(){return Wh.jsx(xpe,{children:({messages:e})=>Wh.jsxs(Wh.Fragment,{children:[Wh.jsx(Bye,{}),e.map((e=>Wh.jsxs(_pe,{message:e,children:[Wh.jsx(zye,{}),Wh.jsx(Cpe,{}),Wh.jsxs(Ppe,{children:[Wh.jsx(Dpe,{children:Wh.jsx(qpe,{})}),Wh.jsx(Hye,{}),Wh.jsx(Uye,{}),Wh.jsx($ye,{})]})]},e.id)))]})})}function Bye(){return Wh.jsxs(Spe,{children:[Wh.jsxs(Tpe,{children:[Wh.jsx(Ape,{children:Wh.jsxs(Npe,{children:[Wh.jsx(Ipe,{}),Wh.jsx(Rpe,{})]})}),Wh.jsx(Ope,{})]}),Wh.jsxs(Ppe,{children:[Wh.jsx(Dpe,{children:Wh.jsx(qpe,{})}),Wh.jsxs(dpe,{children:[Wh.jsx(ppe,{}),Wh.jsx(hpe,{}),Wh.jsxs(fpe,{children:[Wh.jsx(mpe,{}),Wh.jsx(gpe,{})]})]}),Wh.jsxs(ype,{children:[Wh.jsx(bpe,{}),Wh.jsx(vpe,{children:e=>e.map((e=>Wh.jsx(kpe,{children:Wh.jsx(wpe,{question:e})},e)))})]})]})]})}function zye(){return Wh.jsxs(Tpe,{children:[Wh.jsx(Ape,{children:Wh.jsxs(Npe,{children:[Wh.jsx(Ipe,{}),Wh.jsx(Rpe,{})]})}),Wh.jsx(Ope,{})]})}function Hye(){return Wh.jsxs(Lpe,{children:[Wh.jsx(Mpe,{children:e=>e.map((e=>Wh.jsxs(Fpe,{attachment:e,children:[Wh.jsx(jpe,{}),Wh.jsx(Bpe,{})]},e.id)))}),Wh.jsx(zpe,{children:Wh.jsx(_ue,{children:Wh.jsx(Hpe,{children:Wh.jsxs(Upe,{children:[Wh.jsx($pe,{}),Wh.jsx(Gpe,{}),Wh.jsx(Vpe,{})]})})})})]})}function Uye(){return Wh.jsxs(Wpe,{children:[Wh.jsx(Ype,{children:e=>e.map(((e,t)=>Wh.jsx(Kpe,{action:e},`action-${t}`)))}),Wh.jsx(Xpe,{action:"copy"}),Wh.jsx(Xpe,{action:"upvote"}),Wh.jsx(Xpe,{action:"downvote"})]})}function $ye(){return Wh.jsxs(Qpe,{children:[Wh.jsx(Zpe,{}),Wh.jsx(Jpe,{children:e=>e.map(((e,t)=>{var n;return Wh.jsxs(ehe,{href:e.url,source:e,children:[Wh.jsx(the,{children:null==(n=e.breadcrumbs)?void 0:n.map((e=>Wh.jsxs(K.Fragment,{children:[e,Wh.jsx(nhe,{})]},e)))}),Wh.jsx(rhe,{}),Wh.jsx(ahe,{}),Wh.jsx(ohe,{}),Wh.jsx(ihe,{children:e=>e.map(((e,t)=>Wh.jsx(she,{part:e},`part-${t}`)))}),Wh.jsx(lhe,{})]},t)}))})]})}function Gye(){return Wh.jsxs(che,{children:[Wh.jsx(Vye,{}),Wh.jsx(qye,{})]})}function Vye(){return Wh.jsxs(uhe,{children:[Wh.jsxs(dhe,{children:[Wh.jsx(phe,{}),Wh.jsx(hhe,{children:Wh.jsx(fhe,{})})]}),Wh.jsxs(mhe,{children:[Wh.jsx(ghe,{children:e=>e.map((e=>Wh.jsxs(yhe,{attachment:e,children:[Wh.jsx(bhe,{}),Wh.jsx(vhe,{}),Wh.jsx(khe,{})]},e.id)))}),Wh.jsxs(whe,{children:[Wh.jsxs(xhe,{children:[Wh.jsx(Ehe,{}),Wh.jsx(_he,{})]}),Wh.jsx(She,{children:e=>e.map((e=>Wh.jsx(The,{input:e,children:e.displayName},e.id)))})]}),Wh.jsx(_ue,{children:Wh.jsx(Che,{children:Wh.jsx(Ahe,{children:Wh.jsxs(Nhe,{children:[Wh.jsxs(Ihe,{children:[Wh.jsx(Rhe,{}),Wh.jsx(Ohe,{}),Wh.jsx(Phe,{})]}),Wh.jsx(Dhe,{}),Wh.jsx(Lhe,{children:Wh.jsxs(Mhe,{children:[Wh.jsxs(Fhe,{children:[Wh.jsx(jhe,{}),Wh.jsx(Bhe,{}),Wh.jsx(zhe,{})]}),Wh.jsxs(Hhe,{children:[Wh.jsx(Uhe,{}),Wh.jsx($he,{}),Wh.jsx(Ghe,{})]}),Wh.jsx(Vhe,{})]})})]})})})})]})]})}function qye(){return Wh.jsxs(qhe,{children:[Wh.jsxs(Yhe,{children:[Wh.jsx(Khe,{}),Wh.jsx(Xhe,{}),Wh.jsx(Qhe,{})]}),Wh.jsxs(Whe,{children:[Wh.jsx(nfe,{children:({pinned:e,unpinned:t})=>Wh.jsxs(Wh.Fragment,{children:[e.map((e=>Wh.jsx(rfe,{action:e},e.name))),t.length>0&&Wh.jsx(afe,{}),Wh.jsxs(ofe,{children:[Wh.jsx(ife,{}),t.map((e=>Wh.jsxs(sfe,{action:e,children:[Wh.jsx(lfe,{action:e}),e.name]},e.name)))]})]})}),Wh.jsxs(Jhe,{action:"copy",children:[Wh.jsx(efe,{action:"copy"}),Wh.jsx(tfe,{action:"copy"})]}),Wh.jsxs(Jhe,{action:"share",children:[Wh.jsx(efe,{action:"share"}),Wh.jsx(tfe,{action:"share"})]}),Wh.jsx(Jhe,{action:"clear"}),Wh.jsx(Jhe,{action:"stop"})]})]})}function Wye(){return Wh.jsx(_ue,{children:Wh.jsx(cfe,{children:Wh.jsx(ufe,{children:Wh.jsxs(dfe,{children:[Wh.jsx(pfe,{}),Wh.jsx(hfe,{}),Wh.jsx(ffe,{children:Wh.jsxs(mfe,{children:[Wh.jsxs(gfe,{name:"unrelated_response",children:[Wh.jsx(yfe,{children:Wh.jsx(bfe,{})}),Wh.jsx(vfe,{}),Wh.jsx(kfe,{})]}),Wh.jsxs(gfe,{name:"inaccurate_statement",children:[Wh.jsx(yfe,{children:Wh.jsx(bfe,{})}),Wh.jsx(vfe,{}),Wh.jsx(kfe,{})]}),Wh.jsxs(gfe,{name:"inaccurate_code_snippet",children:[Wh.jsx(yfe,{children:Wh.jsx(bfe,{})}),Wh.jsx(vfe,{}),Wh.jsx(kfe,{})]}),Wh.jsxs(gfe,{name:"irrelevant_citations",children:[Wh.jsx(yfe,{children:Wh.jsx(bfe,{})}),Wh.jsx(vfe,{})]}),Wh.jsx(wfe,{})]})})]})})})})}function Yye(){return Wh.jsxs(xfe,{children:[Wh.jsx(_fe,{}),Wh.jsxs(Efe,{children:[Wh.jsxs(Sfe,{children:[Wh.jsx(Tfe,{}),Wh.jsx(Cfe,{})]}),Wh.jsx(Afe,{children:e=>Wh.jsxs(Wh.Fragment,{children:[e.map(((e,t)=>Wh.jsxs(Nfe,{field:e,autoFocus:0===t,children:[Wh.jsx(Ife,{}),"text"===e.inputType&&Wh.jsx(Rfe,{}),"email"===e.inputType&&Wh.jsx(Ofe,{}),"file"===e.inputType&&Wh.jsx(Pfe,{}),"textarea"===e.inputType&&Wh.jsx(Dfe,{}),"checkbox"===e.inputType&&Wh.jsx(Lfe,{children:Wh.jsx(Mfe,{})}),"select"===e.inputType&&Wh.jsxs(Ffe,{children:[Wh.jsxs(jfe,{children:[Wh.jsx(Bfe,{}),Wh.jsx(zfe,{})]}),Wh.jsx(Hfe,{children:Wh.jsx(Ufe,{children:e.items.map((e=>Wh.jsxs($fe,{value:e.value,children:[Wh.jsx(Gfe,{children:e.label}),Wh.jsx(Vfe,{})]},e.value)))})})]}),Wh.jsx(qfe,{})]},e.name))),Wh.jsx(Wfe,{})]})}),Wh.jsxs(Yfe,{children:[Wh.jsx(Kfe,{}),Wh.jsx(Xfe,{})]})]}),Wh.jsxs(Qfe,{children:[Wh.jsx(Zfe,{}),Wh.jsx(Jfe,{}),Wh.jsx(eme,{})]})]})}function Kye(){return Wh.jsx(rme,{children:Wh.jsx(ame,{})})}function Xye(e){const{children:t,onToggleView:n,isHidden:r,shouldAutoFocusInput:a=!n}=e;return Wh.jsx(ime,{isHidden:r,shouldAutoFocusInput:a,children:t})}function Qye(e){return Wh.jsx(Xye,{...e,children:Wh.jsx(Zye,{...e})})}function Zye(e){const{searchSettings:{view:t}}=nP(),{onToggleView:n,shouldShowAskAICard:r=!!n&&"dual-pane"!==t}=e,a=iL(),o=fL(),i=a&&!o?Oye:K.Fragment;return Wh.jsx(i,{children:Wh.jsx(sme,{"data-show-ask-ai-card":SL(r),"data-composite":SL(!!n||(null==a?void 0:a.isOpen)),children:Wh.jsxs(lme,{children:[Wh.jsx(Jye,{...e}),Wh.jsxs(cme,{children:[Wh.jsx(ebe,{askAICardLabel:e.askAICardLabel,askAILabel:e.askAILabel,onToggleView:e.onToggleView,shouldShowAskAICard:r}),Wh.jsx(tbe,{})]}),Wh.jsx(abe,{})]})})})}function Jye(e){const{onToggleView:t,askAILabel:n,searchLabel:r}=e,a=Toe((e=>e.search)),{loading:o}=Uoe();return Wh.jsxs(ume,{children:[!o&&Wh.jsx(dme,{}),Wh.jsx(hme,{}),Wh.jsx(pme,{}),t&&Wh.jsx(Nye,{onToggleView:t,query:a,askAILabel:n,searchLabel:r,view:"search"}),Wh.jsx(uge,{})]})}function ebe(e){const{askAILabel:t,onToggleView:n,shouldShowAskAICard:r,askAICardLabel:a}=e,o=Toe((e=>e.search)),{handleToggle:i}=Iye({onToggleView:n,query:o});return r?Wh.jsxs(fme,{onSelect:()=>i("chat",!0),children:[Wh.jsx(mme,{}),Wh.jsxs(gme,{children:[a||t||"Ask AI",o&&Wh.jsx(yme,{children:`${o}`})]}),Wh.jsx(vme,{children:"Start conversation"}),Wh.jsx(bme,{})]}):null}function tbe(){return Wh.jsxs(kme,{children:[Wh.jsx(wme,{}),Wh.jsx(Eme,{children:e=>e.map((e=>Wh.jsx(_me,{tab:e},e)))}),Wh.jsx(xme,{}),Wh.jsxs(Sme,{children:[Wh.jsx(nbe,{}),Wh.jsx(rbe,{})]})]})}function nbe(){return Wh.jsxs(Tme,{children:[Wh.jsx(Cme,{children:Wh.jsx(Rme,{children:e=>e.map((e=>Wh.jsxs(Ome,{item:e,children:[Wh.jsx(Pme,{children:e=>e.map(((e,t)=>Wh.jsxs(K.Fragment,{children:[e,Wh.jsx(Dme,{})]},`${e}-${t}`)))}),Wh.jsx(Lme,{}),Wh.jsx(Mme,{}),Wh.jsx(Fme,{}),Wh.jsx(jme,{children:e=>e.map(((e,t)=>Wh.jsx(Bme,{part:e},`part-${t}`)))}),Wh.jsx(zme,{})]},e.id)))})}),Wh.jsx(Ame,{children:Wh.jsx(Nme,{})}),Wh.jsx(Ime,{})]})}function rbe(){return Wh.jsxs(Tme,{children:[Wh.jsx(Cme,{children:Wh.jsxs(Hme,{children:[Wh.jsxs(Ume,{children:[Wh.jsxs($me,{children:[Wh.jsx(Gme,{}),Wh.jsx(Vme,{})]}),Wh.jsx(qme,{children:e=>e.map(((e,t)=>Wh.jsxs(K.Fragment,{children:[e,Wh.jsx(Wme,{})]},`${e}-${t}`)))})]}),Wh.jsx(Yme,{}),Wh.jsxs(Kme,{children:[Wh.jsx(Xme,{}),Wh.jsx(Qme,{children:e=>e.map(((e,t)=>Wh.jsxs(Zme,{href:e.url??void 0,"data-is-match":SL(e.isMatch),children:[Wh.jsx(Jme,{}),Wh.jsx(ege,{children:e.content}),e.url&&Wh.jsx(tge,{})]},`${e.anchor}-${t}`)))})]})]})}),Wh.jsx(Ame,{children:Wh.jsx(Nme,{})}),Wh.jsx(Ime,{})]})}function abe(){return Wh.jsx(nge,{children:Wh.jsxs(rge,{children:[Wh.jsx(age,{}),Wh.jsx(oge,{}),Wh.jsx(ige,{})]})})}function obe(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}function ibe(...e){return t=>{for(const n of e)obe(n,t)}}function sbe(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}function lbe(e){const{defaultView:t="search",aiChatSettings:n,baseSettings:r,searchSettings:a,shouldAutoFocusInput:o=!0,onToggleView:i,ref:s,...l}=e,c=K.useRef(null),u=ibe(c,null==n?void 0:n.chatFunctionsRef),d=K.useRef(null),p=ibe(d,null==a?void 0:a.searchFunctionsRef),h={...n,chatFunctionsRef:u},f={...a,searchFunctionsRef:p},[m,g]=K.useState(t);K.useImperativeHandle(s,(()=>({setView:g}))),K.useEffect((()=>{var e,t;"chat"===m?null==(e=c.current)||e.focusInput():null==(t=d.current)||t.focusInput()}),[m]);return{config:{baseSettings:r,aiChatSettings:h,searchSettings:f},defaultView:t,view:m,setView:g,onToggleView:e=>{var t;e.autoSubmit&&e.query&&(null==(t=c.current)||t.submitMessage(e.query)),null==i||i(e),g(e.view)},shouldAutoFocusInput:o,...l}}function cbe(e){const{view:t,setView:n,shouldShowAskAICard:r,onToggleView:a,shouldAutoFocusInput:o,searchLabel:i,askAILabel:s,askAICardLabel:l}=e,c=iL()?Oye:K.Fragment,u={onToggleView:a,shouldShowAskAICard:r,shouldAutoFocusInput:o,searchLabel:i,askAILabel:s,askAICardLabel:l},d={isHidden:"chat"===t,...u},p={isHidden:"search"===t,...u};return Wh.jsx(hL,{widget:{setView:n,view:t},children:Wh.jsx(Xye,{...d,children:Wh.jsx(Pye,{...p,children:Wh.jsxs(c,{children:[Wh.jsx(Zye,{...d}),Wh.jsx(Lye,{...p})]})})})})}function ube({label:e="Ask AI",avatar:t,onOpenChange:n}){return Wh.jsx(dge,{children:Wh.jsxs(pge,{onClick:e=>{2!==e.button&&n((e=>!e))},children:[Wh.jsx(hge,{children:e}),Wh.jsx(mge,{children:Wh.jsx(fge,{avatar:t})})]})})}function dbe({onOpenChange:e,modalSettings:t}){return Wh.jsx(gge,{children:Wh.jsxs(yge,{onClick:t=>{2!==t.button&&e((e=>!e))},children:[Wh.jsxs(bge,{children:[Wh.jsx(kge,{}),Wh.jsx(vge,{})]}),Wh.jsxs(wge,{children:[Wh.jsx(xge,{shortcutKey:null==t?void 0:t.shortcutKey}),Wh.jsx(Ege,{shortcutKey:null==t?void 0:t.shortcutKey})]})]})})}function pbe(e){const{formSettings:t}=e;return Wh.jsx(_ge,{formSettings:t,children:Wh.jsxs(Sge,{children:[Wh.jsx(Tge,{}),Wh.jsx(Cge,{children:Wh.jsxs(Age,{children:[Wh.jsxs(Nge,{children:[Wh.jsx(hbe,{}),Wh.jsx(fbe,{}),Wh.jsx(gbe,{}),Wh.jsx(ybe,{}),Wh.jsx(bbe,{})]}),Wh.jsx(Ige,{children:Wh.jsx(Rge,{})}),Wh.jsx(Oge,{})]})})]})})}function hbe(){return Wh.jsxs(Pge,{children:[Wh.jsx(Dge,{}),Wh.jsx(Lge,{}),Wh.jsx(Mge,{})]})}function fbe(){const{isSubmitSuccessful:e}=wle();return e?null:Wh.jsxs(Fge,{children:[Wh.jsx(jge,{}),Wh.jsx(Bge,{children:e=>e.map((e=>Wh.jsx(vbe,{field:e},e.name)))}),Wh.jsx(zge,{})]})}function mbe(){return Wh.jsxs(oye,{children:[Wh.jsx(iye,{}),Wh.jsx(sye,{})]})}function gbe(){return Wh.jsxs(lye,{children:[Wh.jsx(mbe,{}),Wh.jsx(Kde,{})]})}function ybe(){const{isSubmitSuccessful:e}=wle();return e?null:Wh.jsxs(cye,{children:[Wh.jsx(mbe,{}),Wh.jsxs(vye,{children:[Wh.jsx(kye,{}),Wh.jsx(wye,{children:e=>e.map((e=>Wh.jsxs(xye,{source:e,children:[Wh.jsx(Eye,{}),Wh.jsx(_ye,{})]},e.url)))})]}),Wh.jsx(uye,{}),Wh.jsxs(dye,{children:[Wh.jsx(pye,{}),Wh.jsx(hye,{})]})]})}function bbe(){const{aiResponse:e}=wle(),{isSubmitSuccessful:t}=wle();return t?null:Wh.jsxs(fye,{children:[Wh.jsx(mbe,{}),!e.answerConfidence&&Wh.jsxs(vye,{children:[Wh.jsx(kye,{children:"I wasn't able to find a direct answer to your question, but here's some helpful sources:"}),Wh.jsx(wye,{children:e=>e.map((e=>Wh.jsxs(xye,{source:e,children:[Wh.jsx(Eye,{}),Wh.jsx(_ye,{})]},e.url)))})]}),Wh.jsx(mye,{}),Wh.jsx(gye,{children:e=>e.map((e=>Wh.jsx(vbe,{field:e},e.name)))}),Wh.jsx(bye,{}),Wh.jsx(yye,{})]})}function vbe(e){const{field:t}=e;return Wh.jsxs(Hge,{field:t,children:[Wh.jsx(Uge,{}),"text"===t.inputType&&Wh.jsx($ge,{}),"email"===t.inputType&&Wh.jsx(Gge,{}),"file"===t.inputType&&Wh.jsx(Vge,{}),"textarea"===t.inputType&&Wh.jsx(qge,{}),"checkbox"===t.inputType&&Wh.jsx(Wge,{children:Wh.jsx(Yge,{})}),"select"===t.inputType&&Wh.jsxs(Kge,{children:[Wh.jsxs(Xge,{children:[Wh.jsx(Qge,{}),Wh.jsx(Zge,{})]}),Wh.jsx(Jge,{children:Wh.jsx(eye,{children:t.items.map((e=>Wh.jsxs(tye,{value:e.value,children:[Wh.jsx(nye,{children:e.label}),Wh.jsx(rye,{})]},e.value)))})})]}),Wh.jsx(aye,{})]},t.name)}const kbe={EmbeddedChat:function(e){const{baseSettings:t,aiChatSettings:n}=e;return Wh.jsx(Nue,{children:Wh.jsx(Sye,{wrapperStyles:{height:"inherit",width:"inherit"},children:Wh.jsx(CB,{config:{baseSettings:t,aiChatSettings:n},componentType:YO,children:Wh.jsx(Dye,{...e})})})})},EmbeddedSearch:function(e){const{baseSettings:t,searchSettings:n}=e;return Wh.jsx(Nue,{children:Wh.jsx(Sye,{children:Wh.jsx(CB,{config:{baseSettings:t,searchSettings:n},componentType:KO,children:Wh.jsx(Qye,{...e})})})})},EmbeddedSearchAndChat:function(e){const{config:t,...n}=lbe(e);return Wh.jsx(Nue,{children:Wh.jsx(Sye,{wrapperStyles:{height:"inherit",width:"inherit"},children:Wh.jsx(CB,{config:t,componentType:XO,children:Wh.jsx(cbe,{...n})})})})},ModalChat:function(e){const{modalSettings:t,baseSettings:n,aiChatSettings:r,...a}=e;return Wh.jsx(Rye,{componentType:qO,modalSettings:t,baseSettings:n,aiChatSettings:r,children:Wh.jsx(Dye,{...a})})},ModalSearch:function(e){const{modalSettings:t,baseSettings:n,searchSettings:r,...a}=e;return Wh.jsx(Rye,{componentType:qO,modalSettings:t,baseSettings:n,searchSettings:r,children:Wh.jsx(Qye,{shouldAutoFocusInput:!0,...a})})},ModalSearchAndChat:function(e){const{modalSettings:t,...n}=e,{config:r,...a}=lbe(n),o=sbe(null==t?void 0:t.onOpenChange,(t=>{e.forceDefaultView&&!t&&a.setView(e.defaultView??"search")})),i={...t,onOpenChange:o};return Wh.jsx(Rye,{...r,modalSettings:i,componentType:qO,children:Wh.jsx(cbe,{...a})})},IntelligentForm:function(e){const{baseSettings:t}=e;return Wh.jsx(Nue,{children:Wh.jsx(Sye,{wrapperStyles:{height:"inherit",width:"inherit"},children:Wh.jsx(CB,{config:{baseSettings:t},componentType:QO,children:Wh.jsx(pbe,{...e})})})})},ChatButton:function(e){const{modalSettings:t,label:n,defaultView:r="chat",canToggleView:a=!0,avatar:o,...i}=e,s={...i,shouldShowAskAICard:!!a&&e.shouldShowAskAICard},{config:l,...c}=lbe({...s,defaultView:r}),[u=!1,d]=OB({prop:null==t?void 0:t.isOpen,defaultProp:!1,onChange:sbe(null==t?void 0:t.onOpenChange,(n=>{void 0===(null==t?void 0:t.isOpen)&&(e.forceDefaultView&&!n&&c.setView(r??"search"),d(!!n))}))}),p={...t,isOpen:u,onOpenChange:d};return Wh.jsxs(Wh.Fragment,{children:[Wh.jsx(Nue,{children:Wh.jsx(Sye,{wrapperStyles:{display:"contents"},children:Wh.jsx(CB,{config:l,componentType:VO,children:Wh.jsx(ube,{label:n,avatar:o,onOpenChange:d})})})}),Wh.jsx(Rye,{...l,componentType:VO,modalSettings:p,children:a?Wh.jsx(cbe,{...c}):Wh.jsx(Dye,{...i})})]})},SearchBar:function(e){const{modalSettings:t,defaultView:n="search",canToggleView:r=!0,...a}=e,o={...a,shouldShowAskAICard:!!r&&e.shouldShowAskAICard},{config:i,...s}=lbe({...o,defaultView:n}),[l=!1,c]=OB({prop:null==t?void 0:t.isOpen,defaultProp:!1,onChange:sbe(null==t?void 0:t.onOpenChange,(r=>{void 0===(null==t?void 0:t.isOpen)&&(e.forceDefaultView&&!r&&s.setView(n),c(!!r))}))}),u={shortcutKey:"k",...t,isOpen:l,onOpenChange:c};return Wh.jsxs(Wh.Fragment,{children:[Wh.jsx(Nue,{children:Wh.jsx(Sye,{wrapperStyles:{display:"contents"},children:Wh.jsx(CB,{config:i,componentType:WO,children:Wh.jsx(dbe,{onOpenChange:c,modalSettings:u})})})}),Wh.jsx(Rye,{...i,modalSettings:u,componentType:WO,children:r?Wh.jsx(cbe,{...s}):Wh.jsx(Qye,{...o})})]})},SidebarChat:function(e){const{baseSettings:t,aiChatSettings:n,shouldAutoFocusInput:r,...a}=e;return Wh.jsx(Nue,{children:Wh.jsx(Sye,{wrapperStyles:{height:"inherit",width:"inherit",overflowX:"hidden"},children:Wh.jsx(CB,{config:{baseSettings:t,aiChatSettings:n},componentType:ZO,children:Wh.jsxs(tme,{...a,children:[Wh.jsx(nme,{}),Wh.jsx(Dye,{variant:"no-shadow",shouldAutoFocusInput:r,header:Kye})]})})})})}};function wbe(){window.Inkeep=Object.entries(kbe).reduce(((e,[t,n])=>(e[t]=function(e,t){const n=new Map;return function(r,a){let o,i;if("string"==typeof r)i=r,o=a;else{if(!Bh.includes(t))throw new Error(`You must provide a target selector to render the ${t} component`);const e=document.createElement("div");e.style.position="absolute",document.body.appendChild(e);const n=`inkeep-widget-${jh()}`;i=`#${e.id||n}`,e.id=i.slice(1),o=r}const s=document.querySelector(i);if(!s)return void console.error(`Target ${i} not found.`);let l=n.get(i);l||(l={root:Ch.createRoot(s),props:o,container:s,chatFunctionsRef:K.createRef(),searchFunctionsRef:K.createRef(),ref:K.createRef()},n.set(i,l)),l.props=Ph(o,{aiChatSettings:{chatFunctionsRef:l.chatFunctionsRef},searchSettings:{searchFunctionsRef:l.searchFunctionsRef}},{ref:l.ref}),l.container=s;try{l.root.render(K.createElement(e,l.props))}catch(d){console.error(`Error rendering component ${e.name}:`,d)}const c={update:t=>{const r=n.get(i);if(r){r.props=Ph(r.props??{},t??{});try{r.root.render(K.createElement(e,r.props))}catch(d){console.error(`Error rendering component ${e.name} during update:`,d)}}else console.error(`Component at ${i} is not mounted.`)},unmount(){const e=n.get(i);e&&e.container?(e.root.unmount(),e.container.innerHTML=""):console.error(`Component at ${i} is not mounted.`)},remount(){const t=n.get(i);if(t&&t.container){t.root=Ch.createRoot(t.container);try{t.root.render(K.createElement(e,t.props))}catch(d){console.error(`Error remounting component ${e.name}:`,d)}}else console.error(`Component at ${i} cannot be remounted.`)}},u=zh[t];if("both"===u){const e=Hh(i,"chatFunctionsRef",n),t=Hh(i,"searchFunctionsRef",n);return new Proxy(c,{get(r,a){var o;if("chat"===a)return e;if("search"===a)return t;if(a in r)return r[a];const s=n.get(i),l=null==(o=null==s?void 0:s.ref.current)?void 0:o[a];return"function"==typeof l?l.bind(null==s?void 0:s.ref.current):void 0}})}return"chat"===u?new Proxy(c,{get(e,t){var r;if(t in e)return e[t];const a=n.get(i),o=null==(r=null==a?void 0:a.chatFunctionsRef.current)?void 0:r[t];return"function"==typeof o?o.bind(null==a?void 0:a.chatFunctionsRef.current):void 0}}):"search"===u?new Proxy(c,{get(e,t){var r;if(t in e)return e[t];const a=n.get(i),o=null==(r=null==a?void 0:a.searchFunctionsRef.current)?void 0:r[t];return"function"==typeof o?o.bind(null==a?void 0:a.searchFunctionsRef.current):void 0}}):c}}(n,t),e)),{})}return"undefined"!=typeof window&&wbe(),e.initInkeep=wbe,Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),e}({});
|