@deephaven/embed-widget 1.7.2-beta.3 → 1.7.2-beta.4

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.
Files changed (39) hide show
  1. package/build/assets/{App-BBiEAxwe.js → App-Bxfd4Qnm.js} +2 -2
  2. package/build/assets/{App-BBiEAxwe.js.map → App-Bxfd4Qnm.js.map} +1 -1
  3. package/build/assets/{Chart-as_K_vLO.js → Chart-CEIAQIRJ.js} +2 -2
  4. package/build/assets/{Chart-as_K_vLO.js.map → Chart-CEIAQIRJ.js.map} +1 -1
  5. package/build/assets/{IrisGrid-yQrU5wCO.js → IrisGrid-10FJOsPW.js} +5 -5
  6. package/build/assets/IrisGrid-10FJOsPW.js.map +1 -0
  7. package/build/assets/IrisGridThemeProvider-CH_zuco9.js +12 -0
  8. package/build/assets/IrisGridThemeProvider-CH_zuco9.js.map +1 -0
  9. package/build/assets/{LocalWorkspaceStorage-C0Ew7KXR.js → LocalWorkspaceStorage-CaCzxYFf.js} +2 -2
  10. package/build/assets/{LocalWorkspaceStorage-C0Ew7KXR.js.map → LocalWorkspaceStorage-CaCzxYFf.js.map} +1 -1
  11. package/build/assets/LogPanel-2k7dsKfX.js +20 -0
  12. package/build/assets/LogPanel-2k7dsKfX.js.map +1 -0
  13. package/build/assets/{MarkdownEditor-BeWpL2KU.js → MarkdownEditor-CzPFy3O8.js} +2 -2
  14. package/build/assets/{MarkdownEditor-BeWpL2KU.js.map → MarkdownEditor-CzPFy3O8.js.map} +1 -1
  15. package/build/assets/{MarkdownNotebook-hck10PUa.js → MarkdownNotebook-BUxWjchY.js} +2 -2
  16. package/build/assets/{MarkdownNotebook-hck10PUa.js.map → MarkdownNotebook-BUxWjchY.js.map} +1 -1
  17. package/build/assets/Plot-D1qLr0Y6.js +2 -0
  18. package/build/assets/{Plot-MkKLoacS.js.map → Plot-D1qLr0Y6.js.map} +1 -1
  19. package/build/assets/{Plotly-Cy2HnY94.js → Plotly-BXm-6Lb8.js} +2 -2
  20. package/build/assets/{Plotly-Cy2HnY94.js.map → Plotly-BXm-6Lb8.js.map} +1 -1
  21. package/build/assets/{index-DuOsttR6.js → index-B8cBuBmD.js} +11 -11
  22. package/build/assets/index-B8cBuBmD.js.map +1 -0
  23. package/build/assets/{index-DfdMWwUx.js → index-CDtpRL6c.js} +4 -4
  24. package/build/assets/{index-DfdMWwUx.js.map → index-CDtpRL6c.js.map} +1 -1
  25. package/build/assets/{index-DE3gXqa5.js → index-Cq054aM4.js} +19 -19
  26. package/build/assets/index-Cq054aM4.js.map +1 -0
  27. package/build/assets/plotly-CwtgfxLB.js +7 -0
  28. package/build/assets/{plotly-DcwjB6YO.js.map → plotly-CwtgfxLB.js.map} +1 -1
  29. package/build/index.html +1 -1
  30. package/package.json +17 -17
  31. package/build/assets/IrisGrid-yQrU5wCO.js.map +0 -1
  32. package/build/assets/IrisGridThemeProvider-DgZBNU8i.js +0 -12
  33. package/build/assets/IrisGridThemeProvider-DgZBNU8i.js.map +0 -1
  34. package/build/assets/LogPanel-IIvpOJvm.js +0 -20
  35. package/build/assets/LogPanel-IIvpOJvm.js.map +0 -1
  36. package/build/assets/Plot-MkKLoacS.js +0 -2
  37. package/build/assets/index-DE3gXqa5.js.map +0 -1
  38. package/build/assets/index-DuOsttR6.js.map +0 -1
  39. package/build/assets/plotly-DcwjB6YO.js +0 -7
@@ -1,6 +1,6 @@
1
- import{r as c,J as U,P as Co,D as u,Q as To,S as Xe,T as jo,U as Io,V as ko,W as _o,C as Bt,X as Do,H as N,Y as Wt,Z as Kr,a0 as Ro,a1 as Lo,a2 as Ao,a3 as Fo,a4 as vt,a5 as No,a6 as zr,a7 as Qe,a8 as Le,I as Y,a9 as qr,aa as Xr,ab as Ht,ac as Qr,ad as Jr,ae as bt,af as Mo,ag as Ie,ah as Zr,G as ei,ai as ti,aj as $o,ak as Uo,al as Bo,am as ni,an as Wo,ao as Ho,ap as Vo,aq as Go,ar as Yo,as as Ko,at as zo,au as qo,av as Xo,aw as Qo,ax as Jo,ay as Zo,az as es,aA as ts,aB as ns,aC as rs,aD as is,aE as as,aF as os,aG as ss,aH as ls,aI as us,aJ as cs,aK as ds,aL as ri,aM as ps,aN as fs,aO as hs,aP as ms,aQ as gs,aR as ys,aS as vs,aT as bs,aU as Ps,aV as xs,aW as ws,aX as Os,aY as Ss,aZ as Es,a_ as Cs,a$ as Ts,b0 as js,b1 as Is,b2 as ks,b3 as _s,b4 as Ds,b5 as Rs,O as Ls,b6 as As,b7 as Fs,b8 as Ns,b9 as Ms,ba as $s,bb as Us,bc as Pt,L as Bs,N as Ws,bd as Hs,be as Vs,bf as bn,bg as Gs,bh as Ys,bi as Ks,bj as zs,R as qs,bk as Xs,bl as Qs,bm as ii,bn as Js,bo as Zs}from"./vendor-BDYqMH3-.js";import{i as ai,b as Vt,p as oi,a as W,r as si,M as li,c as ui,g as Gt,v as ci,d as Yt,e as Kt,f as Je,h as el,j as tl,k as nl,l as rl,m as il,n as di,o as al,q as ol,s as sl,t as pi,u as Ze,w as ll,T as xt,C as ul,D as cl,x as dl,y as pl,z as fl,A as hl,B as ml,E as gl,L as ge,F as yl,G as fi,N as vl,P as bl,S as Pl,H as xl,I as wl,J as Ol,K as Sl,W as El,O as Cl,Q as Tl,R as jl,U as Il,V as kl,X as _l,Y as Dl,Z as Rl,_ as Ll,$ as Al,a0 as Fl,a1 as Nl,a2 as Ml,a3 as $l,a4 as Ul,a5 as Bl,a6 as Wl,a7 as Hl,a8 as Vl,a9 as Gl,aa as Yl,ab as Kl,ac as zt,ad as zl,ae as et,af as qt,ag as ql,ah as hi,ai as Xl,aj as Ql,ak as Jl,al as Zl,am as eu,an as tu}from"./index-DE3gXqa5.js";import{e as tt,C as mi,g as nu,a as Ae,F as ru,f as iu,h as au,d as ou,U as nt,i as gi,j as yi,D as Pn,k as su,l as lu,c as uu,S as cu}from"./LocalWorkspaceStorage-C0Ew7KXR.js";import{A as n0,p as r0,q as i0,G as a0,L as o0,m as s0,t as l0,s as u0,o as c0,n as d0,r as p0,u as f0,b as h0}from"./LocalWorkspaceStorage-C0Ew7KXR.js";import{k as du,l as pu,m as fu,n as ke,o as hu,p as mu,q as gu,t as yu,v as rt,w as ne,x as vu,T as Fe,P as it,C as ue,y as me,z as vi,A as Ge,D as bi,r as fe,M as V,K,R as xn,I as wt,B as G,F as Ot,G as at,E as Pi,H as Xt,J as ot,L as xi,N as bu,c as Pu,O as xu,Q as wi,U as Oi,S as wu,V as Ou,W as Su,X as Si,Y as Eu,Z as Cu,_ as Tu,$ as Ei,a0 as ju,a1 as Iu,a2 as ku,a3 as Ci,a4 as _u,u as ye,a5 as Ti,g as Du,a6 as Ru,a7 as Lu,a8 as Au,a9 as ji,aa as Fu,ab as Nu,ac as Mu,ad as $u,ae as Uu,af as Bu,ag as Ii,ah as Qt,ai as ki,aj as _i,ak as Wu,al as Hu,am as Di,an as st,ao as Vu,ap as Ri,aq as Gu,ar as Yu,as as St,at as Ku,au as Li,av as zu,aw as Et,ax as qu,ay as Xu,az as Qu,aA as _e,aB as Ai,aC as Fi,aD as Ju,aE as Ni,aF as Zu,aG as ec,aH as Mi,aI as $i,aJ as Ui,s as Bi,aK as wn,aL as tc,aM as nc,aN as rc,aO as ic,aP as ac,aQ as oc,aR as sc,aS as lc,aT as uc,aU as cc,aV as dc,aW as pc,aX as fc,aY as hc,aZ as mc,a_ as gc,a$ as yc,b0 as vc,b1 as bc,b2 as Pc,b3 as xc,b4 as wc,e as Oc,b as Sc,b5 as Ec,b6 as Cc,b7 as Tc,b8 as jc,b9 as Ic,ba as kc,bb as _c,bc as Dc,bd as Rc,be as Lc,bf as Ac,bg as Fc,bh as Nc,bi as Mc,bj as $c,bk as Uc,bl as Wi,bm as Bc,bn as Wc,a as Hc,bo as Vc,bp as Gc,bq as Yc,br as Kc,bs as zc,bt as qc,bu as Xc,bv as Qc,bw as Hi,bx as Vi,by as Gi,bz as On,bA as Jc,bB as Zc,bC as ed,bD as td,bE as nd,bF as rd,bG as id,bH as ad,bI as od,bJ as sd,bK as ld,bL as ud,bM as cd,bN as dd,bO as pd,bP as fd,bQ as hd,bR as md,bS as gd,bT as yd,bU as he,bV as vd,bW as bd}from"./LogPanel-IIvpOJvm.js";import{u as Pd,C as Yi,F as Jt,a as xd,S as wd,b as Zt,D as Od,B as Sd,c as Ed,d as Cd,e as Td,f as en,g as Ct,I as jd,h as Id,T as kd,i as _d,j as tn,k as Dd,l as Ki,m as zi,n as Rd,o as qi,p as nn,q as Xi,r as Qi,s as Ld,t as Ad,v as Fd,w as Nd,x as Md,y as $d,z as Ud,A as Bd,E as Wd,G as Hd,H as Ji,J as Zi,L as Vd,K as Gd,M as Yd,N as Kd,O as zd,P as ea,Q as qd,R as Xd,U as Qd,V as ta,W as Jd,X as Zd,Y as ep,Z as Sn,_ as tp,$ as np,a0 as rp,a1 as ip,a2 as ap,a3 as op,a4 as sp,a5 as lp,a6 as up,a7 as cp,a8 as dp,a9 as pp,aa as fp,ab as hp,ac as mp,ad as gp,ae as yp,af as vp,ag as bp,ah as Pp,ai as xp,aj as wp,ak as na}from"./index-DuOsttR6.js";import{D as Op}from"./DownsamplingError--AAvWHv_.js";import{e as ze,c as Sp,d as Ep,a as Cp,f as Tp,b as jp,g as Ip,h as kp,i as _p,j as ra,u as Dp,k as Rp,l as Lp,m as Ap,n as Se,o as Fp,p as Ye,q as Tt,r as ia,s as rn,t as an,w as aa,v as oa,x as X,T as lt,y as on,A as sn,M as ln,D as sa,z as Np,B as jt,C as Mp,E as $p,F as Up,G as Bp,H as Wp,I as Hp,J as Vp,K as Gp,L as Yp,N as la,O as Kp,P as zp,Q as qp,R as Xp,S as ua,U as Qp,V as Jp,W as Zp,X as ef,Y as tf,Z as nf,_ as ca,$ as rf,a0 as af,a1 as of,a2 as sf,a3 as lf,a4 as uf,a5 as cf,a6 as df,a7 as pf,a8 as ff,a9 as hf,aa as mf,ab as gf,ac as yf,ad as vf,ae as da,af as bf,ag as Pf,ah as xf,ai as wf,aj as Of,ak as Sf,al as Ke,am as Ef,an as pa,ao as Cf,ap as un,aq as pe,ar as En,as as fa,at as Tf,au as jf,av as ha,aw as ma,ax as If,ay as kf,az as _f,aA as Df,aB as Rf,aC as Lf,aD as Af,aE as Ff,aF as Nf,aG as Mf,aH as $f,aI as Uf,aJ as Bf,aK as Wf,aL as Hf,aM as Vf,aN as Gf,aO as Yf,aP as Kf,aQ as zf,aR as qf,aS as Xf,aT as Qf,aU as Jf,aV as Zf,aW as eh,aX as th,aY as nh,aZ as rh,a_ as ih,a$ as ah,b0 as ga,b1 as oh,b2 as sh,b3 as lh,b4 as uh,b5 as ch,b6 as dh,b7 as ph,b8 as fh,b9 as hh,ba as mh,bb as gh,bc as yh}from"./IrisGridThemeProvider-DgZBNU8i.js";import{m as vh,u as bh}from"./useMergeRef-BE92-nRJ.js";import"./helpers-BosuxZz1.js";var Ph=["children","keepMounted"];function Cn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Tn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Cn(Object(n),!0).forEach(function(r){xh(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Cn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function xh(t,e,n){return(e=wh(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function wh(t){var e=Oh(t,"string");return typeof e=="symbol"?e:e+""}function Oh(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Sh(t,e){if(t==null)return{};var n,r,i=Eh(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function Eh(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Ch(t){var{children:e,keepMounted:n=!1}=t,r=Sh(t,Ph),i=n&&typeof e!="function",a=c.useRef(new Map),o=c.useMemo(()=>{var l=[],d=new Map;return i?(U.Children.forEach(e,f=>{if(!(f==null||f.key==null)){if(typeof f.props.children=="function")throw new Error("DHCTabPanels cannot use keepMounted with an ItemRenderer function as its children");var p=a.current.get(f.key);p==null&&(p=Co({attributes:{style:"display: contents"}})),d.set(f.key,p),l.push(u.jsx(To,{node:p,children:f.props.children},f.key))}}),a.current=d,l):(a.current=d,l)},[e,i]),s=c.useMemo(()=>{var l=[];return i&&U.Children.forEach(e,d=>{if(d==null||d.key==null){l.push(d);return}var f=a.current.get(d.key);if(f==null){l.push(d);return}l.push(u.jsx(Xe,{children:u.jsx(jo,{node:f})},d.key))}),l},[e,i]);return u.jsxs(u.Fragment,{children:[i&&o,u.jsx(Io,Tn(Tn({},r),{},{children:i?s:e}))]})}function jn(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function Th(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){jn(a,r,i,o,s,"next",l)}function s(l){jn(a,r,i,o,s,"throw",l)}o(void 0)})}}var jh=[["api"],["client"],["clientUtils"],["dashboardData","*","connection"],["dashboardData","*","sessionWrapper"],["dashboardData","*","openedMap"],["draftManager","draftStorage"],["layoutStorage"],["storage"],["schemaService","client"],["schemaService","clientUtils"],["schemaService","schemaStorage"],["corePlusManager","dheClient"],["dheClient"]],ya=10;function Ih(t){var e=new Map;return function(r,i){var a,o=[...(a=e.get(this))!==null&&a!==void 0?a:[],r];if(i===Object(i)&&e.set(i,[...o]),o.shift(),!kh(o,t))return i instanceof Map?Array.from(i.entries()):i}}function kh(t,e){for(var n=function(o){if(t.length===e[o].length&&t.every((s,l)=>e[o][l]==="*"||s===e[o][l]))return{v:!0}},r,i=0;i<e.length;i+=1)if(r=n(i),r)return r.v;return!1}function _h(t){var e,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:ya,i=_o({maximumDepth:r});return(e=i(t,Ih(n),2))!==null&&e!==void 0?e:""}function Dh(t){return JSON.stringify(t,null,2)}function Rh(t){var e=t.getFullYear(),n=String(t.getMonth()+1).padStart(2,"0"),r=String(t.getDate()).padStart(2,"0"),i=String(t.getHours()).padStart(2,"0"),a=String(t.getMinutes()).padStart(2,"0"),o=String(t.getSeconds()).padStart(2,"0");return"".concat(e,"-").concat(n,"-").concat(r,"-").concat(i).concat(a).concat(o)}function Lh(t,e,n){return It.apply(this,arguments)}function It(){return It=Th(function*(t,e,n){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:jh,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:"".concat(Rh(new Date),"_support_logs"),a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:ya,o=new ko,s=o.folder(i);s.file("console.txt",t.getFormattedHistory()),e!=null&&s.file("metadata.json",Dh(e)),n!=null&&s.file("redux.json",_h(n,r,a));var l=yield o.generateAsync({type:"blob"}),d=document.createElement("a");d.href=URL.createObjectURL(l),d.download="".concat(i,".zip"),d.click()}),It.apply(this,arguments)}function Ah(t,e){return t===0?0:e==="all"||t===e.size?"all":e.size}function va(t,e){return t===e?!0:t==="all"||e==="all"||t.size!==e.size?!1:[...t.keys()].every(n=>e.has(n))}function ba(t,e){return t.isInverted===e.isInverted&&va(t.selection,e.selection)}function Pa(t,e,n){if(t==="all")return"all";var r=[...t.keys()];return new Set(r.map(i=>{var a=e(i);if(a===void 0)throw new Error("Could not find item with key ".concat(i));return n(a)}))}function xa(t,e,n){var r=t==="all"||t.size>e/2,i=t;return r&&(i=t==="all"?new Set:new Set([...du(0,e-1)].map(n).filter(a=>!t.has(a)))),{selection:i,isInverted:r}}function Fh(t,e){return c.useCallback(function(){var n=t(...arguments);return e(),n},[e,t])}function Nh(t){return c.useCallback(e=>{t(e.target.value)},[t])}function cn(t,e){return c.useCallback(n=>{typeof t=="function"?t(e(n)):t.current=e(n)},[e,t])}function wa(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ai,[e,n]=c.useState(0),[r,i]=c.useState(0),[a,o]=c.useState(0),[s,l]=c.useState(0),d=c.useMemo(()=>new DOMRect(e,r,a,s),[s,a,e,r]),[f,p]=c.useState(null),h=cn(p,t),m=c.useCallback(g=>{var P,[v]=g,y=(P=v==null?void 0:v.contentRect)!==null&&P!==void 0?P:{x:0,y:0,width:0,height:0};n(y.x),i(y.y),o(y.width),l(y.height)},[]);return tt(f,m),{ref:h,contentRect:d}}function Mh(t){var[e,n]=c.useState(!0);return c.useEffect(()=>{var r=setTimeout(()=>{n(!1)},t);return()=>{clearTimeout(r)}},[t]),e}function $h(t){var[e,n]=c.useState(t);return c.useEffect(()=>{n(t)},[t]),[e,n]}function Uh(t,e,n,r){var i=c.useRef(0);c.useEffect(()=>{i.current>=n||r&&(i.current+=1,t())},[n,r,...e])}function Oa(t,e){var n=c.useRef(t),r=e(n.current,t)?n.current:t;return n.current=r,r}function Bh(t){t.preventDefault()}function Sa(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,e=c.useMemo(()=>"useSubmitButtonRef-".concat(Bt()),[]),n=c.useCallback(a=>{var o;a==null||(o=a.UNSAFE_getDOMNode())===null||o===void 0||o.setAttribute("form",e)},[e]),r=c.useMemo(()=>({id:e,onSubmit:t?void 0:Bh}),[e,t]),i=c.useMemo(()=>({form:e,ref:n}),[e,n]);return{formProps:r,submitButtonProps:i}}function Ea(t,e,n){var{getItem:r,selectedKeys:i,items:a}=t;return c.useMemo(()=>{var{selection:o,isInverted:s}=xa(i,a.length,n);return{selection:Pa(o,r,e),isInverted:s}},[i,a.length,n,r,e])}function Ca(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ai,n=c.useRef();return c.useEffect(()=>()=>{var r;return(r=n.current)===null||r===void 0?void 0:r.call(n)},[]),c.useCallback(r=>{var i;(i=n.current)===null||i===void 0||i.call(n);var a=e(r);a&&(a.addEventListener("scroll",t),n.current=()=>{a.removeEventListener("scroll",t),n.current=void 0})},[e,t])}function In(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function kn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?In(Object(n),!0).forEach(function(r){Wh(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):In(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Wh(t,e,n){return(e=Hh(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Hh(t){var e=Vh(t,"string");return typeof e=="symbol"?e:e+""}function Vh(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Gh(t,e,n,r){var i=arguments.length===4;return c.useCallback(a=>{var o=i?a??r:a;n(kn(kn({},t),{},{[e]:o}))},[n,t,e,i,r])}function Ne(t,e){var[n,r]=c.useState(!0),[i,a]=c.useState(t),[o,s]=c.useState(t),[l,d]=c.useState(e);return(t!==o||e!==l)&&(r(!0),s(t),d(e)),c.useEffect(()=>{var f=!1,p=setTimeout(()=>{f||(r(!1),a(t))},e);return()=>{f=!0,clearTimeout(p)}},[t,e]),{isDebouncing:n,value:i}}function Ta(t,e){return c.useCallback(n=>{if(n!=null){var r=e==null?[n]:n.querySelectorAll(e);r.forEach(i=>{Object.entries(t).forEach(a=>{var[o,s]=a;i.setAttribute(o,s)})})}},[t,e])}var ja={spellCheck:!1};function Yh(t){var e=Ta(ja,t);return cn(e,ze)}const Kh=Object.freeze(Object.defineProperty({__proto__:null,SPELLCHECK_FALSE_ATTRIBUTE:ja,createValidationProps:Sp,defaultGetKey:Ep,extractSpectrumHTMLElement:ze,extractSpectrumLastChildHTMLElement:Cp,findSpectrumComboBoxScrollArea:Tp,findSpectrumPickerScrollArea:jp,findSpectrumPopoverScrollArea:Ip,getPositionOfSelectedItem:kp,getSelectedItemCountOrAll:Ah,identityExtractHTMLElement:_p,isElementOfType:ra,isSelectionEqual:va,isSelectionMaybeInvertedEqual:ba,mapSelection:Pa,mergeRefs:vh,optimizeSelection:xa,useAsyncInterval:pu,useCallbackWithAction:Fh,useChangeEventValueCallback:Nh,useCheckOverflow:Dp,useContentRect:wa,useContextOrThrow:fu,useCopyToClipboard:Pd,useDebouncedCallback:ke,useDebouncedValue:Ne,useDelay:Mh,useDependentState:$h,useEffectNTimesWhen:Uh,useFormWithDetachedSubmitButton:Sa,useForwardedRef:hu,useIsEqualMemo:Oa,useIsMountedRef:mu,useMappedRef:cn,useMappedSelection:Ea,useMergeRef:bh,useOnChange:Rp,useOnScrollOffsetChangeCallback:Lp,useOnScrollRef:Ca,usePopoverOnScrollRef:Ap,usePrevious:gu,usePromiseFactory:Se,usePropChangeCallback:Gh,useResizeObserver:tt,useSetAttributesCallback:Ta,useSpectrumDisableSpellcheckRef:Yh,useThrottledCallback:yu,useWindowedListData:Fp},Symbol.toStringTag,{value:"Module"}));var zh=["aria-label","aria-labelledby","aria-describedby","aria-details","marginX","marginY","width","height","minWidth","minHeight","maxWidth","maxHeight","flex","flexGrow","flexShrink","flexBasis","justifySelf","alignSelf","order","gridArea","gridColumn","gridRow","gridColumnStart","gridColumnEnd","gridRowStart","gridRowEnd","position","zIndex","top","bottom","start","end","left","right","isHidden"];function qh(t,e){if(t==null)return{};var n,r,i=Xh(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function Xh(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Ia(t){var{"aria-label":e,"aria-labelledby":n,"aria-describedby":r,"aria-details":i,marginX:a,marginY:o,width:s,height:l,minWidth:d,minHeight:f,maxWidth:p,maxHeight:h,flex:m,flexGrow:g,flexShrink:P,flexBasis:v,justifySelf:y,alignSelf:x,order:w,gridArea:j,gridColumn:b,gridRow:S,gridColumnStart:I,gridColumnEnd:k,gridRowStart:L,gridRowEnd:F,position:H,zIndex:E,top:A,bottom:R,start:B,end:Q,left:Z,right:C,isHidden:D}=t,O=qh(t,zh);return{ariaLabelProps:{"aria-label":e,"aria-labelledby":n,"aria-describedby":r,"aria-details":i},styleProps:{marginX:a,marginY:o,width:s,height:l,minWidth:d,minHeight:f,maxWidth:p,maxHeight:h,flex:m,flexGrow:g,flexShrink:P,flexBasis:v,justifySelf:y,alignSelf:x,order:w,gridArea:j,gridColumn:b,gridRow:S,gridColumnStart:I,gridColumnEnd:k,gridRowStart:L,gridRowEnd:F,position:H,zIndex:E,top:A,bottom:R,start:B,end:Q,left:Z,right:C,isHidden:D},componentProps:O}}function ka(t){var{normalizedItems:e,defaultSelectedKeys:n,disabledKeys:r,selectedKeys:i,onChange:a}=t,o=c.useMemo(()=>Ye(i),[i]),s=c.useMemo(()=>Ye(n),[n]),l=c.useMemo(()=>Ye(r),[r]),d=c.useCallback(f=>{if(a!=null){if(f==="all"){a("all");return}var p=new Set;e.forEach(h=>{f.has(String(Tt(h)))&&p.add(Tt(h))}),a(p)}},[e,a]);return{selectedStringKeys:o,defaultSelectedStringKeys:s,disabledStringKeys:l,onStringSelectionChange:d}}function Qh(){var{selectedThemeKey:t,setSelectedThemeKey:e,themes:n}=rt(),r=c.useCallback(i=>{i!=null&&e("".concat(i))},[e]);return u.jsx(Do,{label:"Pick a color scheme",items:n,selectedKey:t,onSelectionChange:r,children:i=>u.jsx(Xe,{children:i.name},i.themeKey)})}function Jh(t){var{className:e,style:n}=t;return u.jsx("div",{className:N("dh-logo",e),style:n})}var _n=W.module("useExternalTheme");function _a(){var[t,e]=c.useState(()=>{var r=Vt();return{isEnabled:r,isPending:r}}),n=c.useCallback(r=>{var i=oi(r);e({isEnabled:!0,isPending:!1,themeData:i})},[]);return c.useEffect(()=>{if(!t.isEnabled)return;_n.debug("Requesting external theme data");function r(i){var a=Gt();i.source!==window&&i.source!==a||i.data.message===li&&ui(i.data.payload)&&n(i.data.payload)}return window.addEventListener("message",r),si().then(n).catch(i=>{_n.error(i),e({isEnabled:!0,isPending:!1})}),()=>{window.removeEventListener("message",r)}},[n,t.isEnabled]),t}var Zh=["UNSAFE_className"],em=["forceRerenderKey","ref"];function Dn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Rn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Dn(Object(n),!0).forEach(function(r){tm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Dn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function tm(t,e,n){return(e=nm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function nm(t){var e=rm(t,"string");return typeof e=="symbol"?e:e+""}function rm(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Ln(t,e){if(t==null)return{};var n,r,i=im(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function im(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Da(t){var{UNSAFE_className:e}=t,n=Ln(t,Zh),r=ia(n),{forceRerenderKey:i,ref:a}=r,o=Ln(r,em);return c.createElement(Wt,Rn(Rn({},o),{},{key:i,ref:a,UNSAFE_className:N("dh-combobox","dh-combobox-normalized",e)}))}var am=["onScroll"];function An(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Me(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?An(Object(n),!0).forEach(function(r){om(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):An(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function om(t,e,n){return(e=sm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function sm(t){var e=lm(t,"string");return typeof e=="symbol"?e:e+""}function lm(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function um(t,e){if(t==null)return{};var n,r,i=cm(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function cm(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function dn(t){var e,n,{ariaLabelProps:r,componentProps:i,styleProps:a}=Ia(t),{onScroll:o=ne}=i,s=um(i,am),{scale:l}=rn(),d=Ca(o,ze),{ref:f,contentRect:p}=wa(ze);return u.jsx(Kr,Me(Me({direction:"column",ref:f},a),{},{minHeight:(e=a.minHeight)!==null&&e!==void 0?e:1,UNSAFE_className:N("dh-list-view-wrapper","dh-list-view-wrapper-density-".concat((n=s.density)!==null&&n!==void 0?n:"regular"),"dh-list-view-wrapper-scale-".concat(l),a.UNSAFE_className),children:p.height===0?null:u.jsx(Ro,Me(Me({ref:d},r),s))}))}var dm=["children","tooltip","selectedKeys","defaultSelectedKeys","disabledKeys","UNSAFE_className","onChange","onScroll","onSelectionChange"];function Fn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Nn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Fn(Object(n),!0).forEach(function(r){pm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Fn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function pm(t,e,n){return(e=fm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function fm(t){var e=hm(t,"string");return typeof e=="symbol"?e:e+""}function hm(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function mm(t,e){if(t==null)return{};var n,r,i=gm(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function gm(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function ym(t){var{children:e,tooltip:n=!0,selectedKeys:r,defaultSelectedKeys:i,disabledKeys:a,UNSAFE_className:o,onChange:s,onScroll:l=ne,onSelectionChange:d}=t,f=mm(t,dm),p=c.useMemo(()=>an(n,"bottom"),[n]),h=c.useMemo(()=>aa(e,p),[e,p]);return u.jsx(dn,Nn(Nn({},f),{},{UNSAFE_className:N("dh-list-view",o),selectedKeys:r,defaultSelectedKeys:i,disabledKeys:a,onScroll:l,onSelectionChange:s??d,children:h}))}var vm=["normalizedItems","tooltip","selectedKeys","defaultSelectedKeys","disabledKeys","showItemIcons","actions","UNSAFE_className","onChange","onSelectionChange"];function Mn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function $n(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Mn(Object(n),!0).forEach(function(r){bm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Mn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function bm(t,e,n){return(e=Pm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Pm(t){var e=xm(t,"string");return typeof e=="symbol"?e:e+""}function xm(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function wm(t,e){if(t==null)return{};var n,r,i=Om(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function Om(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Ra(t){var{normalizedItems:e,tooltip:n=!0,selectedKeys:r,defaultSelectedKeys:i,disabledKeys:a,showItemIcons:o,actions:s,UNSAFE_className:l,onChange:d,onSelectionChange:f}=t,p=wm(t,vm),h=c.useMemo(()=>an(n,"bottom"),[n]),m=oa({itemIconSlot:"illustration",showItemDescriptions:!1,showItemIcons:o,tooltipOptions:h,actions:s}),g="".concat(o,"-").concat(h==null?void 0:h.placement),{selectedStringKeys:P,defaultSelectedStringKeys:v,disabledStringKeys:y,onStringSelectionChange:x}=ka({normalizedItems:e,selectedKeys:r,defaultSelectedKeys:i,disabledKeys:a,onChange:d??f});return c.createElement(dn,$n($n({},p),{},{UNSAFE_className:N("dh-list-view-normalized",l),key:g,items:e,selectedKeys:P,defaultSelectedKeys:v,disabledKeys:y,onSelectionChange:x}),m)}var Sm=["color","UNSAFE_style"];function Un(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function $e(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Un(Object(n),!0).forEach(function(r){Em(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Un(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Em(t,e,n){return(e=Cm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Cm(t){var e=Tm(t,"string");return typeof e=="symbol"?e:e+""}function Tm(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function jm(t,e){if(t==null)return{};var n,r,i=Im(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function Im(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}var ut=c.forwardRef((t,e)=>{var{color:n,UNSAFE_style:r}=t,i=jm(t,Sm),a=c.useMemo(()=>$e($e({},r),{},{color:X(n)}),[n,r]);return u.jsx(Lo,$e($e({},i),{},{ref:e,UNSAFE_style:a}))});ut.displayName="Heading";var km=["backgroundColor","borderColor","borderStartColor","borderEndColor","borderTopColor","borderBottomColor","borderXColor","borderYColor","UNSAFE_style"];function Bn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Ue(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Bn(Object(n),!0).forEach(function(r){_m(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Bn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function _m(t,e,n){return(e=Dm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Dm(t){var e=Rm(t,"string");return typeof e=="symbol"?e:e+""}function Rm(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Lm(t,e){if(t==null)return{};var n,r,i=Am(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function Am(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}var La=c.forwardRef((t,e)=>{var{backgroundColor:n,borderColor:r,borderStartColor:i,borderEndColor:a,borderTopColor:o,borderBottomColor:s,borderXColor:l,borderYColor:d,UNSAFE_style:f}=t,p=Lm(t,km),{direction:h}=Ao(),m=c.useMemo(()=>{var g={};return r!==void 0&&(g.borderColor=X(r)),l!==void 0&&(g.borderLeftColor=X(l),g.borderRightColor=X(l)),d!==void 0&&(g.borderTopColor=X(d),g.borderBottomColor=X(d)),i!==void 0&&(g[h==="rtl"?"borderRightColor":"borderLeftColor"]=X(i)),a!==void 0&&(g[h==="rtl"?"borderLeftColor":"borderRightColor"]=X(a)),o!==void 0&&(g.borderTopColor=X(o)),s!==void 0&&(g.borderBottomColor=X(s)),Ue(Ue({},f),{},{backgroundColor:X(n)},g)},[n,f,r,i,a,o,s,l,d,h]);return u.jsx(Fo,Ue(Ue({},p),{},{ref:e,UNSAFE_style:m}))});La.displayName="View";var Fm=["children"];function Wn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Hn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Wn(Object(n),!0).forEach(function(r){Nm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Wn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Nm(t,e,n){return(e=Mm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Mm(t){var e=$m(t,"string");return typeof e=="symbol"?e:e+""}function $m(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Um(t,e){if(t==null)return{};var n,r,i=Bm(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function Bm(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Wm(t){var{children:e}=t,n=Um(t,Fm),r=c.useMemo(()=>vu(e).map(i=>ra(i,vt)?i:u.jsx(vt,{value:String(i),children:String(i)},String(i))),[e]);return u.jsx(No,Hn(Hn({},n),{},{children:r}))}var Hm=["ariaLabel","icon","isQuiet","labelText","children","onOpenChange","tooltip"];function Vn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Gn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Vn(Object(n),!0).forEach(function(r){Vm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Vn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Vm(t,e,n){return(e=Gm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Gm(t){var e=Ym(t,"string");return typeof e=="symbol"?e:e+""}function Ym(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Km(t,e){if(t==null)return{};var n,r,i=zm(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function zm(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Aa(t){var{ariaLabel:e,icon:n,isQuiet:r,labelText:i,children:a,onOpenChange:o,tooltip:s}=t,l=Km(t,Hm),d=i==null&&s!=null?"action-button-icon-with-tooltip":void 0;return u.jsxs(zr,{type:"popover",onOpenChange:o,children:[u.jsxs(Qe,Gn(Gn({},l),{},{"aria-label":e??i,isQuiet:r,children:[u.jsx(Le,{UNSAFE_className:d,children:u.jsx(Y,{icon:n})}),i==null?null:u.jsx(lt,{children:i}),s==null?null:u.jsx(Fe,{children:s})]})),a]})}function Yn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Be(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Yn(Object(n),!0).forEach(function(r){qm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Yn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function qm(t,e,n){return(e=Xm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Xm(t){var e=Qm(t,"string");return typeof e=="symbol"?e:e+""}function Qm(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Fa(t){var{heading:e,confirmationButtonLabel:n,children:r,onCancel:i,onConfirm:a}=t,{formProps:o,submitButtonProps:s}=Sa();return u.jsxs(qr,{children:[u.jsx(ut,{level:3,UNSAFE_className:on.spectrumDialogComponentHeading,children:e}),u.jsx(Xr,{}),u.jsx(Ht,{children:u.jsx(Qr,Be(Be({},o),{},{children:r}))}),u.jsxs(Jr,{children:[u.jsx(bt,{variant:"secondary",onPress:i,children:"Cancel"}),u.jsx(bt,Be(Be({},s),{},{style:"fill",variant:"negative",onPress:a,type:"submit",children:n}))]})]})}function Jm(t){var{ariaLabel:e,heading:n,confirmationButtonLabel:r,isHidden:i,children:a,tooltip:o,onConfirm:s}=t,l=c.useCallback(d=>u.jsx(Fa,{heading:n,confirmationButtonLabel:r,onCancel:d,onConfirm:()=>{d(),s()},children:a}),[a,r,n,s]);return u.jsx(Aa,{ariaLabel:e,icon:ci,isHidden:i,isQuiet:!0,height:sn,tooltip:o,children:l})}var Zm=["icon","label","tooltip"];function Kn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function zn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Kn(Object(n),!0).forEach(function(r){eg(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Kn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function eg(t,e,n){return(e=tg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function tg(t){var e=ng(t,"string");return typeof e=="symbol"?e:e+""}function ng(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function rg(t,e){if(t==null)return{};var n,r,i=ig(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function ig(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Na(t){var{icon:e,label:n,tooltip:r}=t,i=rg(t,Zm);return u.jsxs(Qe,zn(zn({},i),{},{"aria-label":n,isQuiet:!0,height:sn,children:[u.jsx(Le,{UNSAFE_className:r==null?void 0:"action-button-icon-with-tooltip",children:u.jsx(Y,{icon:e})}),r==null?null:u.jsx(Fe,{children:r})]}))}Na.displayName="IconActionButton";function qn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function ag(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?qn(Object(n),!0).forEach(function(r){ce(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):qn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function ce(t,e,n){return(e=og(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function og(t){var e=sg(t,"string");return typeof e=="symbol"?e:e+""}function sg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var lg=100,Ma=function(t){return t.UP="UP",t.DOWN="DOWN",t}(Ma||{});class te extends c.Component{constructor(e){super(e),ce(this,"popper",void 0),ce(this,"cbContainer",void 0),ce(this,"menuContainer",void 0),ce(this,"input",void 0),ce(this,"getCachedFilteredOptions",Mo((r,i)=>r.filter(a=>a.title.toLowerCase().indexOf(i.toLowerCase())>=0),{max:1e3}));var{popperOptions:n}=this.props;n=ag({placement:"bottom-end",modifiers:{preventOverflow:{enabled:!1}}},n),this.state={title:"",filteredOptions:[],keyboardOptionIndex:0,menuIsOpen:!1,inputWidth:100,invalid:!1,popperOptions:n},this.handleMenuKeyDown=this.handleMenuKeyDown.bind(this),this.handleMenuBlur=this.handleMenuBlur.bind(this),this.handleInputChange=this.handleInputChange.bind(this),this.handleInputKeyDown=this.handleInputKeyDown.bind(this),this.handleInputBlur=this.handleInputBlur.bind(this),this.handelInputFocus=this.handelInputFocus.bind(this),this.handleInputClick=this.handleInputClick.bind(this),this.updateInputValue=Ie(this.updateInputValue,lg),this.handleOptionClick=this.handleOptionClick.bind(this),this.handleMenuOpened=this.handleMenuOpened.bind(this),this.handleMenuExited=this.handleMenuExited.bind(this),this.popper=U.createRef(),this.cbContainer=U.createRef(),this.menuContainer=U.createRef(),this.input=U.createRef()}setInputWidth(){this.cbContainer.current&&this.setState({inputWidth:this.cbContainer.current.getBoundingClientRect().width})}getValueAndValidate(e){if(!e)return this.setState({invalid:!1}),{value:e,isValid:!1};var{options:n}=this.props,r=n.filter(i=>i.title.toLowerCase()===e.toLowerCase());return r.length<1?(this.setState({invalid:!0}),{value:e,isValid:!1}):(this.setState({invalid:!1}),{value:r[0].value,isValid:!0})}updateInputValue(e){var{menuIsOpen:n}=this.state,{value:r,isValid:i}=this.getValueAndValidate(e);n&&this.processFilterChange(e),this.fireOnChange(r,i)}fireOnChange(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,{onChange:r}=this.props;r(e,n)}processFilterChange(e){var n,{options:r}=this.props,{menuIsOpen:i}=this.state,a=e?this.getCachedFilteredOptions(r,e):r,o=a.length===1&&a[0].title===e;if(this.setState({filteredOptions:a,keyboardOptionIndex:0}),o&&i){this.closeMenu();return}(n=this.popper.current)===null||n===void 0||n.scheduleUpdate()}resetValue(){this.setState({title:""}),this.fireOnChange("")}handleResize(){this.setInputWidth()}handleMenuKeyDown(e){var n,{filteredOptions:r,keyboardOptionIndex:i}=this.state,a=r[i];switch(e.key){case"Enter":case"ArrowRight":e.stopPropagation(),e.preventDefault(),a!=null&&(this.setState({title:a.title,invalid:!1}),this.fireOnChange(a.value)),this.closeMenu(),(n=this.input.current)===null||n===void 0||n.focus();break;case"ArrowUp":e.stopPropagation(),e.preventDefault(),this.navigateMenu(te.MENU_NAVIGATION_DIRECTION.UP);break;case"ArrowDown":e.stopPropagation(),e.preventDefault(),this.navigateMenu(te.MENU_NAVIGATION_DIRECTION.DOWN);break;case"Tab":if(e.stopPropagation(),e.preventDefault(),e.shiftKey){this.navigateMenu(te.MENU_NAVIGATION_DIRECTION.UP);break}this.navigateMenu(te.MENU_NAVIGATION_DIRECTION.DOWN);break;case"Escape":e.preventDefault(),e.stopPropagation(),this.closeMenu();break}}navigateMenu(e){var{filteredOptions:n,keyboardOptionIndex:r}=this.state,i=r;e===te.MENU_NAVIGATION_DIRECTION.UP?r>0?(i=(i-1)%n.length,this.setState({keyboardOptionIndex:i})):r===0&&(i=n.length-1,this.setState({keyboardOptionIndex:i})):e===te.MENU_NAVIGATION_DIRECTION.DOWN&&r<n.length&&(i=(i+1)%n.length,this.setState({keyboardOptionIndex:i})),this.scrollOptionIntoView(i)}handleInputKeyDown(e){var{onEnter:n}=this.props,{menuIsOpen:r}=this.state;r?this.handleMenuKeyDown(e):e.key==="Enter"?n():e.key==="Escape"?(this.resetValue(),e.preventDefault(),e.stopPropagation()):e.key==="ArrowRight"||e.key==="ArrowLeft"||e.key==="Tab"||e.key==="Shift"||this.openMenu()}handleInputChange(e){this.setState({title:e.target.value}),this.updateInputValue(e.target.value)}handleOptionClick(e){var n;this.setState({title:e.title,invalid:!1}),this.fireOnChange(e.value),this.closeMenu(),(n=this.input.current)===null||n===void 0||n.focus()}handelInputFocus(){var{menuIsOpen:e}=this.state;e||this.openMenu()}handleInputClick(){var{menuIsOpen:e}=this.state;e||this.openMenu()}handleInputBlur(e){var{menuIsOpen:n}=this.state;n&&e.relatedTarget instanceof Element&&this.popper.current!==null&&this.popper.current.element.contains(e.relatedTarget)||this.closeMenu(!1)}handleMenuBlur(e){e.relatedTarget===this.input.current||e.relatedTarget instanceof Element&&this.popper.current!==null&&this.popper.current.element.contains(e.relatedTarget)||this.closeMenu(!1)}handleMenuOpened(){var e;(e=this.input.current)===null||e===void 0||e.focus()}handleMenuExited(){var{menuIsOpen:e}=this.state;e&&this.setState({menuIsOpen:!1,keyboardOptionIndex:0})}openMenu(){var{title:e}=this.state;this.processFilterChange(e),this.setInputWidth(),this.setState({menuIsOpen:!0}),window.requestAnimationFrame(()=>{var n;(n=this.popper.current)===null||n===void 0||n.show()})}closeMenu(){var e,n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;if(this.setState({menuIsOpen:!1,keyboardOptionIndex:0}),n){var r;(r=this.input.current)===null||r===void 0||r.focus()}(e=this.popper.current)===null||e===void 0||e.hide()}scrollOptionIntoView(e){if(this.menuContainer.current){var n;(n=this.menuContainer.current.children.item(e))===null||n===void 0||n.scrollIntoView({behavior:"smooth",block:"nearest"})}}renderMenuElement(){var{inputWidth:e}=this.state;return u.jsx("div",{className:N("aci-options"),ref:this.menuContainer,role:"presentation",onKeyDown:this.handleMenuKeyDown,style:{width:e},onBlur:this.handleMenuBlur,children:this.renderOptions()})}renderOptions(){var{noMatchText:e}=this.props,{title:n,filteredOptions:r}=this.state;return n&&r.length===0?u.jsx("div",{className:"no-match",children:e}):r.map((i,a)=>this.renderOption(i,a))}renderOption(e,n){var{keyboardOptionIndex:r}=this.state,i="option-".concat(n,"-").concat(e.value);return u.jsx("button",{type:"button",className:N("aci-option-btn",{"keyboard-active":r===n}),onClick:()=>this.handleOptionClick(e),onFocus:()=>this.setState({keyboardOptionIndex:n}),children:e.title},i)}render(){var{options:e,inputPlaceholder:n,disabled:r,className:i,defaultTitle:a,spellCheck:o,"data-testid":s}=this.props,{title:l,menuIsOpen:d,popperOptions:f,invalid:p}=this.state;return u.jsxs("div",{className:"aci-container",ref:this.cbContainer,children:[u.jsx("input",{value:l||a,className:N("form-control",i,"aci-input",{"is-invalid":p&&!d}),ref:this.input,onChange:this.handleInputChange,placeholder:n||e[0].title,disabled:r,onFocus:this.handelInputFocus,onClick:this.handleInputClick,onBlur:this.handleInputBlur,onKeyDown:this.handleInputKeyDown,spellCheck:o,"data-testid":s}),u.jsx(it,{ref:this.popper,options:f,className:N("aci-options-popper interactive"),onEntered:this.handleMenuOpened,onExited:this.handleMenuExited,children:this.renderMenuElement()})]})}}ce(te,"defaultProps",{onChange(){},inputPlaceholder:"",disabled:!1,className:"",defaultTitle:"",popperOptions:null,spellCheck:!0,onEnter(){},noMatchText:"No matching items found","data-testid":void 0});ce(te,"MENU_NAVIGATION_DIRECTION",Ma);function ug(t){var{className:e="",value:n,onChange:r,spellCheck:i=!1,placeholder:a="",disabled:o=!1,delimiter:s="",id:l="","data-testid":d}=t,[f,p]=c.useState(n),[h,m]=c.useState(!1),g=c.useRef(null);c.useEffect(function(){p(n)},[n]);function P(I){return I.trim().split(s).filter(k=>k).join(`
1
+ import{r as c,J as U,P as To,D as u,Q as jo,S as Xe,T as Io,U as ko,V as _o,W as Ro,C as Bt,X as Do,H as N,Y as Wt,Z as Kr,a0 as Lo,a1 as Ao,a2 as Fo,a3 as No,a4 as vt,a5 as Mo,a6 as zr,a7 as Qe,a8 as Le,I as Y,a9 as qr,aa as Xr,ab as Ht,ac as Qr,ad as Jr,ae as bt,af as $o,ag as je,ah as Zr,G as ei,ai as ti,aj as Uo,ak as Bo,al as Wo,am as ni,an as Ho,ao as Vo,ap as Go,aq as Yo,ar as Ko,as as zo,at as qo,au as Xo,av as Qo,aw as Jo,ax as Zo,ay as es,az as ts,aA as ns,aB as rs,aC as is,aD as as,aE as os,aF as ss,aG as ls,aH as us,aI as cs,aJ as ds,aK as ps,aL as ri,aM as fs,aN as hs,aO as ms,aP as gs,aQ as ys,aR as vs,aS as bs,aT as Ps,aU as xs,aV as ws,aW as Os,aX as Ss,aY as Es,aZ as Cs,a_ as Ts,a$ as js,b0 as Is,b1 as ks,b2 as _s,b3 as Rs,b4 as Ds,b5 as Ls,O as As,b6 as Fs,b7 as Ns,b8 as Ms,b9 as $s,ba as Us,bb as Bs,bc as Pt,L as Ws,N as Hs,bd as Vs,be as Gs,bf as bn,bg as Ys,bh as Ks,bi as zs,bj as qs,R as Xs,bk as Qs,bl as Js,bm as ii,bn as Zs,bo as el}from"./vendor-BDYqMH3-.js";import{i as ai,b as Vt,p as oi,a as W,r as si,M as li,c as ui,g as Gt,v as ci,d as Yt,e as Kt,f as Je,h as tl,j as nl,k as rl,l as il,m as al,n as di,o as ol,q as sl,s as ll,t as pi,u as Ze,w as ul,T as xt,C as cl,D as dl,x as pl,y as fl,z as hl,A as ml,B as gl,E as yl,L as me,F as vl,G as fi,N as bl,P as Pl,S as xl,H as wl,I as Ol,J as Sl,K as El,W as Cl,O as Tl,Q as jl,R as Il,U as kl,V as _l,X as Rl,Y as Dl,Z as Ll,_ as Al,$ as Fl,a0 as Nl,a1 as Ml,a2 as $l,a3 as Ul,a4 as Bl,a5 as Wl,a6 as Hl,a7 as Vl,a8 as Gl,a9 as Yl,aa as Kl,ab as zl,ac as zt,ad as ql,ae as et,af as qt,ag as Xl,ah as hi,ai as Ql,aj as Jl,ak as Zl,al as eu,am as tu,an as nu}from"./index-Cq054aM4.js";import{e as tt,C as mi,g as ru,a as Ae,F as iu,f as au,h as ou,d as su,U as nt,i as gi,j as yi,D as Pn,k as lu,l as uu,c as cu,S as du}from"./LocalWorkspaceStorage-CaCzxYFf.js";import{A as n0,p as r0,q as i0,G as a0,L as o0,m as s0,t as l0,s as u0,o as c0,n as d0,r as p0,u as f0,b as h0}from"./LocalWorkspaceStorage-CaCzxYFf.js";import{k as pu,l as fu,m as hu,n as Ie,o as mu,p as gu,q as yu,t as vu,v as rt,w as ne,x as bu,T as Fe,P as it,C as le,y as he,z as vi,A as Ge,D as bi,r as pe,M as V,K,R as xn,I as wt,B as G,F as Ot,G as at,E as Pi,H as Xt,J as ot,L as xi,N as Pu,c as xu,O as wu,Q as wi,U as Oi,S as Ou,V as Su,W as Eu,X as Si,Y as Cu,Z as Tu,_ as ju,$ as Ei,a0 as Iu,a1 as ku,a2 as _u,a3 as Ci,a4 as Ru,u as ge,a5 as Ti,g as Du,a6 as Lu,a7 as Au,a8 as Fu,a9 as ji,aa as Nu,ab as Mu,ac as $u,ad as Uu,ae as Bu,af as Wu,ag as Ii,ah as Qt,ai as ki,aj as _i,ak as Hu,al as Vu,am as Ri,an as st,ao as Gu,ap as Di,aq as Yu,ar as Ku,as as St,at as zu,au as Li,av as qu,aw as Et,ax as Xu,ay as Qu,az as Ju,aA as ke,aB as Ai,aC as Fi,aD as Zu,aE as Ni,aF as ec,aG as tc,aH as Mi,aI as $i,aJ as Ui,s as Bi,aK as wn,aL as nc,aM as rc,aN as ic,aO as ac,aP as oc,aQ as sc,aR as lc,aS as uc,aT as cc,aU as dc,aV as pc,aW as fc,aX as hc,aY as mc,aZ as gc,a_ as yc,a$ as vc,b0 as bc,b1 as Pc,b2 as xc,b3 as wc,b4 as Oc,e as Sc,b as Ec,b5 as Cc,b6 as Tc,b7 as jc,b8 as Ic,b9 as kc,ba as _c,bb as Rc,bc as Dc,bd as Lc,be as Ac,bf as Fc,bg as Nc,bh as Mc,bi as $c,bj as Uc,bk as Bc,bl as Wi,bm as Wc,bn as Hc,a as Vc,bo as Gc,bp as Yc,bq as Kc,br as zc,bs as qc,bt as Xc,bu as Qc,bv as Jc,bw as Hi,bx as Vi,by as Gi,bz as On,bA as Zc,bB as ed,bC as td,bD as nd,bE as rd,bF as id,bG as ad,bH as od,bI as sd,bJ as ld,bK as ud,bL as cd,bM as dd,bN as pd,bO as fd,bP as hd,bQ as md,bR as gd,bS as yd,bT as vd,bU as fe,bV as bd,bW as Pd}from"./LogPanel-2k7dsKfX.js";import{u as xd,C as Yi,F as Jt,a as wd,S as Od,b as Zt,D as Sd,B as Ed,c as Cd,d as Td,e as jd,f as en,g as Ct,I as Id,h as kd,T as _d,i as Rd,j as tn,k as Dd,l as Ki,m as zi,n as Ld,o as qi,p as nn,q as Xi,r as Qi,s as Ad,t as Fd,v as Nd,w as Md,x as $d,y as Ud,z as Bd,A as Wd,E as Hd,G as Vd,H as Ji,J as Zi,L as Gd,K as Yd,M as Kd,N as zd,O as qd,P as ea,Q as Xd,R as Qd,U as Jd,V as ta,W as Zd,X as ep,Y as tp,Z as Sn,_ as np,$ as rp,a0 as ip,a1 as ap,a2 as op,a3 as sp,a4 as lp,a5 as up,a6 as cp,a7 as dp,a8 as pp,a9 as fp,aa as hp,ab as mp,ac as gp,ad as yp,ae as vp,af as bp,ag as Pp,ah as xp,ai as wp,aj as Op,ak as na}from"./index-B8cBuBmD.js";import{D as Sp}from"./DownsamplingError--AAvWHv_.js";import{e as ze,c as Ep,d as Cp,a as Tp,f as jp,b as Ip,g as kp,h as _p,i as Rp,j as ra,u as Dp,k as Lp,l as Ap,m as Fp,n as Oe,o as Np,p as Ye,q as Tt,r as ia,s as rn,t as an,w as aa,v as oa,x as X,T as lt,y as on,A as sn,M as ln,D as sa,z as Mp,B as jt,C as $p,E as Up,F as Bp,G as Wp,H as Hp,I as Vp,J as Gp,K as Yp,L as Kp,N as la,O as zp,P as qp,Q as Xp,R as Qp,S as ua,U as Jp,V as Zp,W as ef,X as tf,Y as nf,Z as rf,_ as ca,$ as af,a0 as of,a1 as sf,a2 as lf,a3 as uf,a4 as cf,a5 as df,a6 as pf,a7 as ff,a8 as hf,a9 as mf,aa as gf,ab as yf,ac as vf,ad as bf,ae as da,af as Pf,ag as xf,ah as wf,ai as Of,aj as Sf,ak as Ef,al as Ke,am as Cf,an as pa,ao as Tf,ap as un,aq as de,ar as En,as as fa,at as jf,au as If,av as ha,aw as ma,ax as kf,ay as _f,az as Rf,aA as Df,aB as Lf,aC as Af,aD as Ff,aE as Nf,aF as Mf,aG as $f,aH as Uf,aI as Bf,aJ as Wf,aK as Hf,aL as Vf,aM as Gf,aN as Yf,aO as Kf,aP as zf,aQ as qf,aR as Xf,aS as Qf,aT as Jf,aU as Zf,aV as eh,aW as th,aX as nh,aY as rh,aZ as ih,a_ as ah,a$ as oh,b0 as ga,b1 as sh,b2 as lh,b3 as uh,b4 as ch,b5 as dh,b6 as ph,b7 as fh,b8 as hh,b9 as mh,ba as gh,bb as yh,bc as vh}from"./IrisGridThemeProvider-CH_zuco9.js";import{m as bh,u as Ph}from"./useMergeRef-BE92-nRJ.js";import"./helpers-BosuxZz1.js";var xh=["children","keepMounted"];function Cn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Tn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Cn(Object(n),!0).forEach(function(r){wh(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Cn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function wh(t,e,n){return(e=Oh(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Oh(t){var e=Sh(t,"string");return typeof e=="symbol"?e:e+""}function Sh(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Eh(t,e){if(t==null)return{};var n,r,i=Ch(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function Ch(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Th(t){var{children:e,keepMounted:n=!1}=t,r=Eh(t,xh),i=n&&typeof e!="function",a=c.useRef(new Map),o=c.useMemo(()=>{var l=[],d=new Map;return i?(U.Children.forEach(e,f=>{if(!(f==null||f.key==null)){if(typeof f.props.children=="function")throw new Error("DHCTabPanels cannot use keepMounted with an ItemRenderer function as its children");var p=a.current.get(f.key);p==null&&(p=To({attributes:{style:"display: contents"}})),d.set(f.key,p),l.push(u.jsx(jo,{node:p,children:f.props.children},f.key))}}),a.current=d,l):(a.current=d,l)},[e,i]),s=c.useMemo(()=>{var l=[];return i&&U.Children.forEach(e,d=>{if(d==null||d.key==null){l.push(d);return}var f=a.current.get(d.key);if(f==null){l.push(d);return}l.push(u.jsx(Xe,{children:u.jsx(Io,{node:f})},d.key))}),l},[e,i]);return u.jsxs(u.Fragment,{children:[i&&o,u.jsx(ko,Tn(Tn({},r),{},{children:i?s:e}))]})}function jn(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function jh(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){jn(a,r,i,o,s,"next",l)}function s(l){jn(a,r,i,o,s,"throw",l)}o(void 0)})}}var Ih=[["api"],["client"],["clientUtils"],["dashboardData","*","connection"],["dashboardData","*","sessionWrapper"],["dashboardData","*","openedMap"],["draftManager","draftStorage"],["layoutStorage"],["storage"],["schemaService","client"],["schemaService","clientUtils"],["schemaService","schemaStorage"],["corePlusManager","dheClient"],["dheClient"]],ya=10;function kh(t){var e=new Map;return function(r,i){var a,o=[...(a=e.get(this))!==null&&a!==void 0?a:[],r];if(i===Object(i)&&e.set(i,[...o]),o.shift(),!_h(o,t))return i instanceof Map?Array.from(i.entries()):i}}function _h(t,e){for(var n=function(o){if(t.length===e[o].length&&t.every((s,l)=>e[o][l]==="*"||s===e[o][l]))return{v:!0}},r,i=0;i<e.length;i+=1)if(r=n(i),r)return r.v;return!1}function Rh(t){var e,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:ya,i=Ro({maximumDepth:r});return(e=i(t,kh(n),2))!==null&&e!==void 0?e:""}function Dh(t){return JSON.stringify(t,null,2)}function Lh(t){var e=t.getFullYear(),n=String(t.getMonth()+1).padStart(2,"0"),r=String(t.getDate()).padStart(2,"0"),i=String(t.getHours()).padStart(2,"0"),a=String(t.getMinutes()).padStart(2,"0"),o=String(t.getSeconds()).padStart(2,"0");return"".concat(e,"-").concat(n,"-").concat(r,"-").concat(i).concat(a).concat(o)}function Ah(t,e,n){return It.apply(this,arguments)}function It(){return It=jh(function*(t,e,n){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:Ih,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:"".concat(Lh(new Date),"_support_logs"),a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:ya,o=new _o,s=o.folder(i);s.file("console.txt",t.getFormattedHistory()),e!=null&&s.file("metadata.json",Dh(e)),n!=null&&s.file("redux.json",Rh(n,r,a));var l=yield o.generateAsync({type:"blob"}),d=document.createElement("a");d.href=URL.createObjectURL(l),d.download="".concat(i,".zip"),d.click()}),It.apply(this,arguments)}function Fh(t,e){return t===0?0:e==="all"||t===e.size?"all":e.size}function va(t,e){return t===e?!0:t==="all"||e==="all"||t.size!==e.size?!1:[...t.keys()].every(n=>e.has(n))}function ba(t,e){return t.isInverted===e.isInverted&&va(t.selection,e.selection)}function Pa(t,e,n){if(t==="all")return"all";var r=[...t.keys()];return new Set(r.map(i=>{var a=e(i);if(a===void 0)throw new Error("Could not find item with key ".concat(i));return n(a)}))}function xa(t,e,n){var r=t==="all"||t.size>e/2,i=t;return r&&(i=t==="all"?new Set:new Set([...pu(0,e-1)].map(n).filter(a=>!t.has(a)))),{selection:i,isInverted:r}}function Nh(t,e){return c.useCallback(function(){var n=t(...arguments);return e(),n},[e,t])}function Mh(t){return c.useCallback(e=>{t(e.target.value)},[t])}function cn(t,e){return c.useCallback(n=>{typeof t=="function"?t(e(n)):t.current=e(n)},[e,t])}function wa(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ai,[e,n]=c.useState(0),[r,i]=c.useState(0),[a,o]=c.useState(0),[s,l]=c.useState(0),d=c.useMemo(()=>new DOMRect(e,r,a,s),[s,a,e,r]),[f,p]=c.useState(null),h=cn(p,t),m=c.useCallback(g=>{var P,[v]=g,y=(P=v==null?void 0:v.contentRect)!==null&&P!==void 0?P:{x:0,y:0,width:0,height:0};n(y.x),i(y.y),o(y.width),l(y.height)},[]);return tt(f,m),{ref:h,contentRect:d}}function $h(t){var[e,n]=c.useState(!0);return c.useEffect(()=>{var r=setTimeout(()=>{n(!1)},t);return()=>{clearTimeout(r)}},[t]),e}function Uh(t){var[e,n]=c.useState(t);return c.useEffect(()=>{n(t)},[t]),[e,n]}function Bh(t,e,n,r){var i=c.useRef(0);c.useEffect(()=>{i.current>=n||r&&(i.current+=1,t())},[n,r,...e])}function Oa(t,e){var n=c.useRef(t),r=e(n.current,t)?n.current:t;return n.current=r,r}function Wh(t){t.preventDefault()}function Sa(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,e=c.useMemo(()=>"useSubmitButtonRef-".concat(Bt()),[]),n=c.useCallback(a=>{var o;a==null||(o=a.UNSAFE_getDOMNode())===null||o===void 0||o.setAttribute("form",e)},[e]),r=c.useMemo(()=>({id:e,onSubmit:t?void 0:Wh}),[e,t]),i=c.useMemo(()=>({form:e,ref:n}),[e,n]);return{formProps:r,submitButtonProps:i}}function Ea(t,e,n){var{getItem:r,selectedKeys:i,items:a}=t;return c.useMemo(()=>{var{selection:o,isInverted:s}=xa(i,a.length,n);return{selection:Pa(o,r,e),isInverted:s}},[i,a.length,n,r,e])}function Ca(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ai,n=c.useRef();return c.useEffect(()=>()=>{var r;return(r=n.current)===null||r===void 0?void 0:r.call(n)},[]),c.useCallback(r=>{var i;(i=n.current)===null||i===void 0||i.call(n);var a=e(r);a&&(a.addEventListener("scroll",t),n.current=()=>{a.removeEventListener("scroll",t),n.current=void 0})},[e,t])}function In(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function kn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?In(Object(n),!0).forEach(function(r){Hh(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):In(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Hh(t,e,n){return(e=Vh(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Vh(t){var e=Gh(t,"string");return typeof e=="symbol"?e:e+""}function Gh(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Yh(t,e,n,r){var i=arguments.length===4;return c.useCallback(a=>{var o=i?a??r:a;n(kn(kn({},t),{},{[e]:o}))},[n,t,e,i,r])}function Ne(t,e){var[n,r]=c.useState(!0),[i,a]=c.useState(t),[o,s]=c.useState(t),[l,d]=c.useState(e);return(t!==o||e!==l)&&(r(!0),s(t),d(e)),c.useEffect(()=>{var f=!1,p=setTimeout(()=>{f||(r(!1),a(t))},e);return()=>{f=!0,clearTimeout(p)}},[t,e]),{isDebouncing:n,value:i}}function Ta(t,e){return c.useCallback(n=>{if(n!=null){var r=e==null?[n]:n.querySelectorAll(e);r.forEach(i=>{Object.entries(t).forEach(a=>{var[o,s]=a;i.setAttribute(o,s)})})}},[t,e])}var ja={spellCheck:!1};function Kh(t){var e=Ta(ja,t);return cn(e,ze)}const zh=Object.freeze(Object.defineProperty({__proto__:null,SPELLCHECK_FALSE_ATTRIBUTE:ja,createValidationProps:Ep,defaultGetKey:Cp,extractSpectrumHTMLElement:ze,extractSpectrumLastChildHTMLElement:Tp,findSpectrumComboBoxScrollArea:jp,findSpectrumPickerScrollArea:Ip,findSpectrumPopoverScrollArea:kp,getPositionOfSelectedItem:_p,getSelectedItemCountOrAll:Fh,identityExtractHTMLElement:Rp,isElementOfType:ra,isSelectionEqual:va,isSelectionMaybeInvertedEqual:ba,mapSelection:Pa,mergeRefs:bh,optimizeSelection:xa,useAsyncInterval:fu,useCallbackWithAction:Nh,useChangeEventValueCallback:Mh,useCheckOverflow:Dp,useContentRect:wa,useContextOrThrow:hu,useCopyToClipboard:xd,useDebouncedCallback:Ie,useDebouncedValue:Ne,useDelay:$h,useDependentState:Uh,useEffectNTimesWhen:Bh,useFormWithDetachedSubmitButton:Sa,useForwardedRef:mu,useIsEqualMemo:Oa,useIsMountedRef:gu,useMappedRef:cn,useMappedSelection:Ea,useMergeRef:Ph,useOnChange:Lp,useOnScrollOffsetChangeCallback:Ap,useOnScrollRef:Ca,usePopoverOnScrollRef:Fp,usePrevious:yu,usePromiseFactory:Oe,usePropChangeCallback:Yh,useResizeObserver:tt,useSetAttributesCallback:Ta,useSpectrumDisableSpellcheckRef:Kh,useThrottledCallback:vu,useWindowedListData:Np},Symbol.toStringTag,{value:"Module"}));var qh=["aria-label","aria-labelledby","aria-describedby","aria-details","marginX","marginY","width","height","minWidth","minHeight","maxWidth","maxHeight","flex","flexGrow","flexShrink","flexBasis","justifySelf","alignSelf","order","gridArea","gridColumn","gridRow","gridColumnStart","gridColumnEnd","gridRowStart","gridRowEnd","position","zIndex","top","bottom","start","end","left","right","isHidden"];function Xh(t,e){if(t==null)return{};var n,r,i=Qh(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function Qh(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Ia(t){var{"aria-label":e,"aria-labelledby":n,"aria-describedby":r,"aria-details":i,marginX:a,marginY:o,width:s,height:l,minWidth:d,minHeight:f,maxWidth:p,maxHeight:h,flex:m,flexGrow:g,flexShrink:P,flexBasis:v,justifySelf:y,alignSelf:x,order:w,gridArea:j,gridColumn:b,gridRow:S,gridColumnStart:I,gridColumnEnd:k,gridRowStart:L,gridRowEnd:F,position:H,zIndex:E,top:A,bottom:D,start:B,end:Q,left:Z,right:C,isHidden:R}=t,O=Xh(t,qh);return{ariaLabelProps:{"aria-label":e,"aria-labelledby":n,"aria-describedby":r,"aria-details":i},styleProps:{marginX:a,marginY:o,width:s,height:l,minWidth:d,minHeight:f,maxWidth:p,maxHeight:h,flex:m,flexGrow:g,flexShrink:P,flexBasis:v,justifySelf:y,alignSelf:x,order:w,gridArea:j,gridColumn:b,gridRow:S,gridColumnStart:I,gridColumnEnd:k,gridRowStart:L,gridRowEnd:F,position:H,zIndex:E,top:A,bottom:D,start:B,end:Q,left:Z,right:C,isHidden:R},componentProps:O}}function ka(t){var{normalizedItems:e,defaultSelectedKeys:n,disabledKeys:r,selectedKeys:i,onChange:a}=t,o=c.useMemo(()=>Ye(i),[i]),s=c.useMemo(()=>Ye(n),[n]),l=c.useMemo(()=>Ye(r),[r]),d=c.useCallback(f=>{if(a!=null){if(f==="all"){a("all");return}var p=new Set;e.forEach(h=>{f.has(String(Tt(h)))&&p.add(Tt(h))}),a(p)}},[e,a]);return{selectedStringKeys:o,defaultSelectedStringKeys:s,disabledStringKeys:l,onStringSelectionChange:d}}function Jh(){var{selectedThemeKey:t,setSelectedThemeKey:e,themes:n}=rt(),r=c.useCallback(i=>{i!=null&&e("".concat(i))},[e]);return u.jsx(Do,{label:"Pick a color scheme",items:n,selectedKey:t,onSelectionChange:r,children:i=>u.jsx(Xe,{children:i.name},i.themeKey)})}function Zh(t){var{className:e,style:n}=t;return u.jsx("div",{className:N("dh-logo",e),style:n})}var _n=W.module("useExternalTheme");function _a(){var[t,e]=c.useState(()=>{var r=Vt();return{isEnabled:r,isPending:r}}),n=c.useCallback(r=>{var i=oi(r);e({isEnabled:!0,isPending:!1,themeData:i})},[]);return c.useEffect(()=>{if(!t.isEnabled)return;_n.debug("Requesting external theme data");function r(i){var a=Gt();i.source!==window&&i.source!==a||i.data.message===li&&ui(i.data.payload)&&n(i.data.payload)}return window.addEventListener("message",r),si().then(n).catch(i=>{_n.error(i),e({isEnabled:!0,isPending:!1})}),()=>{window.removeEventListener("message",r)}},[n,t.isEnabled]),t}var em=["UNSAFE_className"],tm=["forceRerenderKey","ref"];function Rn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Dn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Rn(Object(n),!0).forEach(function(r){nm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Rn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function nm(t,e,n){return(e=rm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function rm(t){var e=im(t,"string");return typeof e=="symbol"?e:e+""}function im(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Ln(t,e){if(t==null)return{};var n,r,i=am(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function am(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Ra(t){var{UNSAFE_className:e}=t,n=Ln(t,em),r=ia(n),{forceRerenderKey:i,ref:a}=r,o=Ln(r,tm);return c.createElement(Wt,Dn(Dn({},o),{},{key:i,ref:a,UNSAFE_className:N("dh-combobox","dh-combobox-normalized",e)}))}var om=["onScroll"];function An(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Me(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?An(Object(n),!0).forEach(function(r){sm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):An(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function sm(t,e,n){return(e=lm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function lm(t){var e=um(t,"string");return typeof e=="symbol"?e:e+""}function um(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function cm(t,e){if(t==null)return{};var n,r,i=dm(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function dm(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function dn(t){var e,n,{ariaLabelProps:r,componentProps:i,styleProps:a}=Ia(t),{onScroll:o=ne}=i,s=cm(i,om),{scale:l}=rn(),d=Ca(o,ze),{ref:f,contentRect:p}=wa(ze);return u.jsx(Kr,Me(Me({direction:"column",ref:f},a),{},{minHeight:(e=a.minHeight)!==null&&e!==void 0?e:1,UNSAFE_className:N("dh-list-view-wrapper","dh-list-view-wrapper-density-".concat((n=s.density)!==null&&n!==void 0?n:"regular"),"dh-list-view-wrapper-scale-".concat(l),a.UNSAFE_className),children:p.height===0?null:u.jsx(Lo,Me(Me({ref:d},r),s))}))}var pm=["children","tooltip","selectedKeys","defaultSelectedKeys","disabledKeys","UNSAFE_className","onChange","onScroll","onSelectionChange"];function Fn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Nn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Fn(Object(n),!0).forEach(function(r){fm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Fn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function fm(t,e,n){return(e=hm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function hm(t){var e=mm(t,"string");return typeof e=="symbol"?e:e+""}function mm(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function gm(t,e){if(t==null)return{};var n,r,i=ym(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function ym(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function vm(t){var{children:e,tooltip:n=!0,selectedKeys:r,defaultSelectedKeys:i,disabledKeys:a,UNSAFE_className:o,onChange:s,onScroll:l=ne,onSelectionChange:d}=t,f=gm(t,pm),p=c.useMemo(()=>an(n,"bottom"),[n]),h=c.useMemo(()=>aa(e,p),[e,p]);return u.jsx(dn,Nn(Nn({},f),{},{UNSAFE_className:N("dh-list-view",o),selectedKeys:r,defaultSelectedKeys:i,disabledKeys:a,onScroll:l,onSelectionChange:s??d,children:h}))}var bm=["normalizedItems","tooltip","selectedKeys","defaultSelectedKeys","disabledKeys","showItemIcons","actions","UNSAFE_className","onChange","onSelectionChange"];function Mn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function $n(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Mn(Object(n),!0).forEach(function(r){Pm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Mn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Pm(t,e,n){return(e=xm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function xm(t){var e=wm(t,"string");return typeof e=="symbol"?e:e+""}function wm(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Om(t,e){if(t==null)return{};var n,r,i=Sm(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function Sm(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Da(t){var{normalizedItems:e,tooltip:n=!0,selectedKeys:r,defaultSelectedKeys:i,disabledKeys:a,showItemIcons:o,actions:s,UNSAFE_className:l,onChange:d,onSelectionChange:f}=t,p=Om(t,bm),h=c.useMemo(()=>an(n,"bottom"),[n]),m=oa({itemIconSlot:"illustration",showItemDescriptions:!1,showItemIcons:o,tooltipOptions:h,actions:s}),g="".concat(o,"-").concat(h==null?void 0:h.placement),{selectedStringKeys:P,defaultSelectedStringKeys:v,disabledStringKeys:y,onStringSelectionChange:x}=ka({normalizedItems:e,selectedKeys:r,defaultSelectedKeys:i,disabledKeys:a,onChange:d??f});return c.createElement(dn,$n($n({},p),{},{UNSAFE_className:N("dh-list-view-normalized",l),key:g,items:e,selectedKeys:P,defaultSelectedKeys:v,disabledKeys:y,onSelectionChange:x}),m)}var Em=["color","UNSAFE_style"];function Un(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function $e(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Un(Object(n),!0).forEach(function(r){Cm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Un(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Cm(t,e,n){return(e=Tm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Tm(t){var e=jm(t,"string");return typeof e=="symbol"?e:e+""}function jm(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Im(t,e){if(t==null)return{};var n,r,i=km(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function km(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}var ut=c.forwardRef((t,e)=>{var{color:n,UNSAFE_style:r}=t,i=Im(t,Em),a=c.useMemo(()=>$e($e({},r),{},{color:X(n)}),[n,r]);return u.jsx(Ao,$e($e({},i),{},{ref:e,UNSAFE_style:a}))});ut.displayName="Heading";var _m=["backgroundColor","borderColor","borderStartColor","borderEndColor","borderTopColor","borderBottomColor","borderXColor","borderYColor","UNSAFE_style"];function Bn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Ue(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Bn(Object(n),!0).forEach(function(r){Rm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Bn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Rm(t,e,n){return(e=Dm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Dm(t){var e=Lm(t,"string");return typeof e=="symbol"?e:e+""}function Lm(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Am(t,e){if(t==null)return{};var n,r,i=Fm(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function Fm(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}var La=c.forwardRef((t,e)=>{var{backgroundColor:n,borderColor:r,borderStartColor:i,borderEndColor:a,borderTopColor:o,borderBottomColor:s,borderXColor:l,borderYColor:d,UNSAFE_style:f}=t,p=Am(t,_m),{direction:h}=Fo(),m=c.useMemo(()=>{var g={};return r!==void 0&&(g.borderColor=X(r)),l!==void 0&&(g.borderLeftColor=X(l),g.borderRightColor=X(l)),d!==void 0&&(g.borderTopColor=X(d),g.borderBottomColor=X(d)),i!==void 0&&(g[h==="rtl"?"borderRightColor":"borderLeftColor"]=X(i)),a!==void 0&&(g[h==="rtl"?"borderLeftColor":"borderRightColor"]=X(a)),o!==void 0&&(g.borderTopColor=X(o)),s!==void 0&&(g.borderBottomColor=X(s)),Ue(Ue({},f),{},{backgroundColor:X(n)},g)},[n,f,r,i,a,o,s,l,d,h]);return u.jsx(No,Ue(Ue({},p),{},{ref:e,UNSAFE_style:m}))});La.displayName="View";var Nm=["children"];function Wn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Hn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Wn(Object(n),!0).forEach(function(r){Mm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Wn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Mm(t,e,n){return(e=$m(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function $m(t){var e=Um(t,"string");return typeof e=="symbol"?e:e+""}function Um(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Bm(t,e){if(t==null)return{};var n,r,i=Wm(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function Wm(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Hm(t){var{children:e}=t,n=Bm(t,Nm),r=c.useMemo(()=>bu(e).map(i=>ra(i,vt)?i:u.jsx(vt,{value:String(i),children:String(i)},String(i))),[e]);return u.jsx(Mo,Hn(Hn({},n),{},{children:r}))}var Vm=["ariaLabel","icon","isQuiet","labelText","children","onOpenChange","tooltip"];function Vn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Gn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Vn(Object(n),!0).forEach(function(r){Gm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Vn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Gm(t,e,n){return(e=Ym(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ym(t){var e=Km(t,"string");return typeof e=="symbol"?e:e+""}function Km(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function zm(t,e){if(t==null)return{};var n,r,i=qm(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function qm(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Aa(t){var{ariaLabel:e,icon:n,isQuiet:r,labelText:i,children:a,onOpenChange:o,tooltip:s}=t,l=zm(t,Vm),d=i==null&&s!=null?"action-button-icon-with-tooltip":void 0;return u.jsxs(zr,{type:"popover",onOpenChange:o,children:[u.jsxs(Qe,Gn(Gn({},l),{},{"aria-label":e??i,isQuiet:r,children:[u.jsx(Le,{UNSAFE_className:d,children:u.jsx(Y,{icon:n})}),i==null?null:u.jsx(lt,{children:i}),s==null?null:u.jsx(Fe,{children:s})]})),a]})}function Yn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Be(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Yn(Object(n),!0).forEach(function(r){Xm(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Yn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Xm(t,e,n){return(e=Qm(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Qm(t){var e=Jm(t,"string");return typeof e=="symbol"?e:e+""}function Jm(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Fa(t){var{heading:e,confirmationButtonLabel:n,children:r,onCancel:i,onConfirm:a}=t,{formProps:o,submitButtonProps:s}=Sa();return u.jsxs(qr,{children:[u.jsx(ut,{level:3,UNSAFE_className:on.spectrumDialogComponentHeading,children:e}),u.jsx(Xr,{}),u.jsx(Ht,{children:u.jsx(Qr,Be(Be({},o),{},{children:r}))}),u.jsxs(Jr,{children:[u.jsx(bt,{variant:"secondary",onPress:i,children:"Cancel"}),u.jsx(bt,Be(Be({},s),{},{style:"fill",variant:"negative",onPress:a,type:"submit",children:n}))]})]})}function Zm(t){var{ariaLabel:e,heading:n,confirmationButtonLabel:r,isHidden:i,children:a,tooltip:o,onConfirm:s}=t,l=c.useCallback(d=>u.jsx(Fa,{heading:n,confirmationButtonLabel:r,onCancel:d,onConfirm:()=>{d(),s()},children:a}),[a,r,n,s]);return u.jsx(Aa,{ariaLabel:e,icon:ci,isHidden:i,isQuiet:!0,height:sn,tooltip:o,children:l})}var eg=["icon","label","tooltip"];function Kn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function zn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Kn(Object(n),!0).forEach(function(r){tg(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Kn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function tg(t,e,n){return(e=ng(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function ng(t){var e=rg(t,"string");return typeof e=="symbol"?e:e+""}function rg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function ig(t,e){if(t==null)return{};var n,r,i=ag(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function ag(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function Na(t){var{icon:e,label:n,tooltip:r}=t,i=ig(t,eg);return u.jsxs(Qe,zn(zn({},i),{},{"aria-label":n,isQuiet:!0,height:sn,children:[u.jsx(Le,{UNSAFE_className:r==null?void 0:"action-button-icon-with-tooltip",children:u.jsx(Y,{icon:e})}),r==null?null:u.jsx(Fe,{children:r})]}))}Na.displayName="IconActionButton";function qn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function og(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?qn(Object(n),!0).forEach(function(r){ue(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):qn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function ue(t,e,n){return(e=sg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function sg(t){var e=lg(t,"string");return typeof e=="symbol"?e:e+""}function lg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var ug=100,Ma=function(t){return t.UP="UP",t.DOWN="DOWN",t}(Ma||{});class te extends c.Component{constructor(e){super(e),ue(this,"popper",void 0),ue(this,"cbContainer",void 0),ue(this,"menuContainer",void 0),ue(this,"input",void 0),ue(this,"getCachedFilteredOptions",$o((r,i)=>r.filter(a=>a.title.toLowerCase().indexOf(i.toLowerCase())>=0),{max:1e3}));var{popperOptions:n}=this.props;n=og({placement:"bottom-end",modifiers:{preventOverflow:{enabled:!1}}},n),this.state={title:"",filteredOptions:[],keyboardOptionIndex:0,menuIsOpen:!1,inputWidth:100,invalid:!1,popperOptions:n},this.handleMenuKeyDown=this.handleMenuKeyDown.bind(this),this.handleMenuBlur=this.handleMenuBlur.bind(this),this.handleInputChange=this.handleInputChange.bind(this),this.handleInputKeyDown=this.handleInputKeyDown.bind(this),this.handleInputBlur=this.handleInputBlur.bind(this),this.handelInputFocus=this.handelInputFocus.bind(this),this.handleInputClick=this.handleInputClick.bind(this),this.updateInputValue=je(this.updateInputValue,ug),this.handleOptionClick=this.handleOptionClick.bind(this),this.handleMenuOpened=this.handleMenuOpened.bind(this),this.handleMenuExited=this.handleMenuExited.bind(this),this.popper=U.createRef(),this.cbContainer=U.createRef(),this.menuContainer=U.createRef(),this.input=U.createRef()}setInputWidth(){this.cbContainer.current&&this.setState({inputWidth:this.cbContainer.current.getBoundingClientRect().width})}getValueAndValidate(e){if(!e)return this.setState({invalid:!1}),{value:e,isValid:!1};var{options:n}=this.props,r=n.filter(i=>i.title.toLowerCase()===e.toLowerCase());return r.length<1?(this.setState({invalid:!0}),{value:e,isValid:!1}):(this.setState({invalid:!1}),{value:r[0].value,isValid:!0})}updateInputValue(e){var{menuIsOpen:n}=this.state,{value:r,isValid:i}=this.getValueAndValidate(e);n&&this.processFilterChange(e),this.fireOnChange(r,i)}fireOnChange(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,{onChange:r}=this.props;r(e,n)}processFilterChange(e){var n,{options:r}=this.props,{menuIsOpen:i}=this.state,a=e?this.getCachedFilteredOptions(r,e):r,o=a.length===1&&a[0].title===e;if(this.setState({filteredOptions:a,keyboardOptionIndex:0}),o&&i){this.closeMenu();return}(n=this.popper.current)===null||n===void 0||n.scheduleUpdate()}resetValue(){this.setState({title:""}),this.fireOnChange("")}handleResize(){this.setInputWidth()}handleMenuKeyDown(e){var n,{filteredOptions:r,keyboardOptionIndex:i}=this.state,a=r[i];switch(e.key){case"Enter":case"ArrowRight":e.stopPropagation(),e.preventDefault(),a!=null&&(this.setState({title:a.title,invalid:!1}),this.fireOnChange(a.value)),this.closeMenu(),(n=this.input.current)===null||n===void 0||n.focus();break;case"ArrowUp":e.stopPropagation(),e.preventDefault(),this.navigateMenu(te.MENU_NAVIGATION_DIRECTION.UP);break;case"ArrowDown":e.stopPropagation(),e.preventDefault(),this.navigateMenu(te.MENU_NAVIGATION_DIRECTION.DOWN);break;case"Tab":if(e.stopPropagation(),e.preventDefault(),e.shiftKey){this.navigateMenu(te.MENU_NAVIGATION_DIRECTION.UP);break}this.navigateMenu(te.MENU_NAVIGATION_DIRECTION.DOWN);break;case"Escape":e.preventDefault(),e.stopPropagation(),this.closeMenu();break}}navigateMenu(e){var{filteredOptions:n,keyboardOptionIndex:r}=this.state,i=r;e===te.MENU_NAVIGATION_DIRECTION.UP?r>0?(i=(i-1)%n.length,this.setState({keyboardOptionIndex:i})):r===0&&(i=n.length-1,this.setState({keyboardOptionIndex:i})):e===te.MENU_NAVIGATION_DIRECTION.DOWN&&r<n.length&&(i=(i+1)%n.length,this.setState({keyboardOptionIndex:i})),this.scrollOptionIntoView(i)}handleInputKeyDown(e){var{onEnter:n}=this.props,{menuIsOpen:r}=this.state;r?this.handleMenuKeyDown(e):e.key==="Enter"?n():e.key==="Escape"?(this.resetValue(),e.preventDefault(),e.stopPropagation()):e.key==="ArrowRight"||e.key==="ArrowLeft"||e.key==="Tab"||e.key==="Shift"||this.openMenu()}handleInputChange(e){this.setState({title:e.target.value}),this.updateInputValue(e.target.value)}handleOptionClick(e){var n;this.setState({title:e.title,invalid:!1}),this.fireOnChange(e.value),this.closeMenu(),(n=this.input.current)===null||n===void 0||n.focus()}handelInputFocus(){var{menuIsOpen:e}=this.state;e||this.openMenu()}handleInputClick(){var{menuIsOpen:e}=this.state;e||this.openMenu()}handleInputBlur(e){var{menuIsOpen:n}=this.state;n&&e.relatedTarget instanceof Element&&this.popper.current!==null&&this.popper.current.element.contains(e.relatedTarget)||this.closeMenu(!1)}handleMenuBlur(e){e.relatedTarget===this.input.current||e.relatedTarget instanceof Element&&this.popper.current!==null&&this.popper.current.element.contains(e.relatedTarget)||this.closeMenu(!1)}handleMenuOpened(){var e;(e=this.input.current)===null||e===void 0||e.focus()}handleMenuExited(){var{menuIsOpen:e}=this.state;e&&this.setState({menuIsOpen:!1,keyboardOptionIndex:0})}openMenu(){var{title:e}=this.state;this.processFilterChange(e),this.setInputWidth(),this.setState({menuIsOpen:!0}),window.requestAnimationFrame(()=>{var n;(n=this.popper.current)===null||n===void 0||n.show()})}closeMenu(){var e,n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;if(this.setState({menuIsOpen:!1,keyboardOptionIndex:0}),n){var r;(r=this.input.current)===null||r===void 0||r.focus()}(e=this.popper.current)===null||e===void 0||e.hide()}scrollOptionIntoView(e){if(this.menuContainer.current){var n;(n=this.menuContainer.current.children.item(e))===null||n===void 0||n.scrollIntoView({behavior:"smooth",block:"nearest"})}}renderMenuElement(){var{inputWidth:e}=this.state;return u.jsx("div",{className:N("aci-options"),ref:this.menuContainer,role:"presentation",onKeyDown:this.handleMenuKeyDown,style:{width:e},onBlur:this.handleMenuBlur,children:this.renderOptions()})}renderOptions(){var{noMatchText:e}=this.props,{title:n,filteredOptions:r}=this.state;return n&&r.length===0?u.jsx("div",{className:"no-match",children:e}):r.map((i,a)=>this.renderOption(i,a))}renderOption(e,n){var{keyboardOptionIndex:r}=this.state,i="option-".concat(n,"-").concat(e.value);return u.jsx("button",{type:"button",className:N("aci-option-btn",{"keyboard-active":r===n}),onClick:()=>this.handleOptionClick(e),onFocus:()=>this.setState({keyboardOptionIndex:n}),children:e.title},i)}render(){var{options:e,inputPlaceholder:n,disabled:r,className:i,defaultTitle:a,spellCheck:o,"data-testid":s}=this.props,{title:l,menuIsOpen:d,popperOptions:f,invalid:p}=this.state;return u.jsxs("div",{className:"aci-container",ref:this.cbContainer,children:[u.jsx("input",{value:l||a,className:N("form-control",i,"aci-input",{"is-invalid":p&&!d}),ref:this.input,onChange:this.handleInputChange,placeholder:n||e[0].title,disabled:r,onFocus:this.handelInputFocus,onClick:this.handleInputClick,onBlur:this.handleInputBlur,onKeyDown:this.handleInputKeyDown,spellCheck:o,"data-testid":s}),u.jsx(it,{ref:this.popper,options:f,className:N("aci-options-popper interactive"),onEntered:this.handleMenuOpened,onExited:this.handleMenuExited,children:this.renderMenuElement()})]})}}ue(te,"defaultProps",{onChange(){},inputPlaceholder:"",disabled:!1,className:"",defaultTitle:"",popperOptions:null,spellCheck:!0,onEnter(){},noMatchText:"No matching items found","data-testid":void 0});ue(te,"MENU_NAVIGATION_DIRECTION",Ma);function cg(t){var{className:e="",value:n,onChange:r,spellCheck:i=!1,placeholder:a="",disabled:o=!1,delimiter:s="",id:l="","data-testid":d}=t,[f,p]=c.useState(n),[h,m]=c.useState(!1),g=c.useRef(null);c.useEffect(function(){p(n)},[n]);function P(I){return I.trim().split(s).filter(k=>k).join(`
2
2
  `.concat(s.trim()))}function v(I){return I.split(`
3
- `).map(k=>k.trim()).join(" ")}function y(){if(g.current){g.current.style.height="0";var I=g.current.scrollHeight+(g.current.offsetHeight-g.current.clientHeight);I>0&&(g.current.style.height="".concat(I,"px"))}}function x(I){var k=I.target.value;h&&(s&&(k=P(k)),m(!1)),p(k),r(k)}function w(){g.current&&(s&&(p(P(f)),y()),g.current.scrollLeft=0)}function j(){g.current&&document.activeElement!==g.current&&g.current.focus()}function b(){s&&(p(v(f)),r(v(f)))}function S(){m(!0)}return c.useEffect(function(){y()},[f]),u.jsx("textarea",{ref:g,id:l,className:N(e,"auto-resize-textarea form-control"),placeholder:a,value:f,rows:1,onChange:x,onFocus:w,onMouseDown:j,onBlur:b,onPaste:S,spellCheck:i,disabled:o,"data-testid":d})}function $a(t){var{blockInteraction:e=!0,children:n,debounceMs:r,isOpen:i=!1}=t,{value:a}=Ne(i,r);return u.jsxs(u.Fragment,{children:[e&&i&&u.jsx("div",{className:"modal-backdrop",style:{backgroundColor:"transparent"},"data-testid":"debounced-modal-backdrop"}),U.cloneElement(n,{isOpen:i&&a})]})}function Ua(t){var{className:e,icon:n,isOpen:r=!1,subtitle:i,title:a}=t;return u.jsx(Yt,{isOpen:r,className:e,children:u.jsx(Kt,{children:u.jsxs("div",{className:"info-modal",children:[n!=null&&u.jsx("div",{className:"message-icon",children:u.jsx(Y,{icon:n})}),u.jsx("div",{className:"message-header",children:a}),i!=null&&u.jsx("div",{className:"message-content",children:i})]})})})}function Xn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Qn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Xn(Object(n),!0).forEach(function(r){cg(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Xn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function cg(t,e,n){return(e=dg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function dg(t){var e=pg(t,"string");return typeof e=="symbol"?e:e+""}function pg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var fg=[];function hg(t){var{styleProps:e,selectedItemCount:n,onClearSelection:r}=t;return u.jsx(Zr,Qn(Qn({UNSAFE_className:on.spectrumActionBar},e),{},{isEmphasized:!0,selectedItemCount:n,onClearSelection:r,children:fg}))}function Jn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function mg(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Jn(Object(n),!0).forEach(function(r){se(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Jn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function se(t,e,n){return(e=gg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function gg(t){var e=yg(t,"string");return typeof e=="symbol"?e:e+""}function yg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Zn=W.module("ContextMenu");class De extends c.PureComponent{static handleContextMenu(e){e.metaKey||(e.stopPropagation(),e.preventDefault())}constructor(e){super(e),se(this,"container",void 0),se(this,"oldFocus",void 0),se(this,"activeSubMenuRef",void 0),se(this,"subMenuTimer",void 0),se(this,"rAF",void 0),se(this,"initialPosition",void 0),this.handleBlur=this.handleBlur.bind(this),this.handleCloseSubMenu=this.handleCloseSubMenu.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleMenuItemClick=this.handleMenuItemClick.bind(this),this.handleMenuItemContextMenu=this.handleMenuItemContextMenu.bind(this),this.handleMenuItemMouseMove=this.handleMenuItemMouseMove.bind(this),this.handleMouseLeave=this.handleMouseLeave.bind(this),this.handleWindowResize=this.handleWindowResize.bind(this),this.container=U.createRef(),this.oldFocus=document.activeElement,this.activeSubMenuRef=U.createRef(),this.subMenuTimer=0,this.rAF=0,this.initialPosition={top:e.top,left:e.left},this.state={menuItems:[],pendingItems:[],activeSubMenu:null,hasOverflow:!1,subMenuTop:null,subMenuLeft:null,subMenuParentWidth:0,subMenuParentHeight:0,keyboardIndex:-1,mouseIndex:-1}}componentDidMount(){this.initMenu(),this.verifyPosition(),window.addEventListener("resize",this.handleWindowResize),this.rAF=window.requestAnimationFrame(()=>{var e;(e=this.container.current)===null||e===void 0||e.focus();var{onMenuOpened:n}=this.props;n(this)})}componentDidUpdate(e,n){var{actions:r}=this.props,{activeSubMenu:i}=this.state;if(i!==n.activeSubMenu)if(i==null){var a;(a=this.container.current)===null||a===void 0||a.focus()}else this.setActiveSubMenuPosition();if(e.actions!==r&&(this.initMenu(),this.container.current==null||!this.container.current.contains(document.activeElement))){var o;(o=this.container.current)===null||o===void 0||o.focus()}this.verifyPosition()}componentWillUnmount(){this.cancelPromises(),window.removeEventListener("resize",this.handleWindowResize),cancelAnimationFrame(this.rAF)}getKeyboardIndex(){var{options:e}=this.props;if(e.separateKeyboardMouse!==void 0&&e.separateKeyboardMouse){var{keyboardIndex:n}=this.state;return n}return this.getMouseIndex()}setKeyboardIndex(e){var{options:n}=this.props;n.separateKeyboardMouse!==void 0&&n.separateKeyboardMouse?this.setState({keyboardIndex:e}):this.setMouseIndex(e)}getMouseIndex(){var{mouseIndex:e}=this.state;return e}setMouseIndex(e){this.setState({mouseIndex:e})}initMenu(){this.cancelPromises(),cancelAnimationFrame(this.rAF);var{options:e}=this.props,n=e.initialKeyboardIndex;n===void 0&&(n=-1);for(var{actions:r}=this.props,i=ue.getMenuItems(r),a=[],o=i.length-1;o>=0;o-=1){var s=i[o];s instanceof Promise?this.initMenuPromise(s):a.push(s)}this.setState({mouseIndex:-1,keyboardIndex:n,activeSubMenu:null,menuItems:ue.sortActions(a)})}initMenuPromise(e){var n=me.makeCancelable(e);this.setState(r=>({pendingItems:r.pendingItems.concat(n)})),n.then(r=>{this.setState(i=>{var a=i.pendingItems.indexOf(n);if(a>=0){var o=i.pendingItems.slice();return o.splice(a,1),{menuItems:ue.sortActions(i.menuItems.concat(r)),pendingItems:o}}return null})},r=>{me.isCanceled(r)||(this.setState(i=>{var a=i.pendingItems.indexOf(n);if(a>=0){var o=i.pendingItems.slice();return o.splice(a,1),{pendingItems:o}}return null}),Zn.error(r))})}cancelPromises(){var{pendingItems:e}=this.state;e.map(n=>n.cancel())}setActiveSubMenuPosition(){if(this.activeSubMenuRef.current!==null){var e=this.activeSubMenuRef.current.getBoundingClientRect();this.setState({subMenuTop:e.top,subMenuLeft:e.right,subMenuParentHeight:e.height,subMenuParentWidth:e.width})}}verifyPosition(){var e,n,r,i,{options:a,updatePosition:o,subMenuParentWidth:s,subMenuParentHeight:l,top:d,left:f}=this.props;if(!(!this.container.current||a.doNotVerifyPosition!=null&&a.doNotVerifyPosition)){var{top:p,left:h}=this.initialPosition,{width:m,height:g}=(e=(n=this.container.current)===null||n===void 0?void 0:n.getBoundingClientRect())!==null&&e!==void 0?e:{width:0,height:0},P=((r=(i=this.container.current)===null||i===void 0?void 0:i.scrollHeight)!==null&&r!==void 0?r:0)>window.innerHeight;g===0||m===0||(p+g>window.innerHeight&&(p-g-l>0?p-=g-l:p=window.innerHeight-g),h+m>window.innerWidth&&(h=h-m-s),(f!==h||d!==p)&&(this.setState({hasOverflow:P}),o(p,h)))}}handleWindowResize(){this.container.current&&this.closeMenu(!0)}handleBlur(e){if(!this.container.current){Zn.warn("Container is null!");return}if(!this.container.current.contains(e.relatedTarget)){for(var n=e.relatedTarget,r=!1;n&&!r;)r=n.hasAttribute("data-dh-context-menu"),n=n.parentElement;r||this.closeMenu(!0)}}isEscapeKey(e){var{left:n}=this.props;return e==="Escape"||n<0&&e==="ArrowRight"||e==="ArrowLeft"}handleKeyDown(e){var{menuItems:n}=this.state,r=this.getKeyboardIndex(),i=r,a=!1;if(e.key==="Enter"||e.key===" "){r>=0&&r<n.length&&this.handleMenuItemClick(n[r],e);return}if(e.key==="ArrowRight"?r>=0&&r<=n.length?a=!0:i=0:this.isEscapeKey(e.key)?i=null:e.key==="ArrowUp"||e.shiftKey&&e.key==="Tab"?i=ue.getNextMenuItem(i,-1,n):(e.key==="ArrowDown"||e.key==="Tab")&&(i=ue.getNextMenuItem(i,1,n)),a){this.openSubMenu(r),e.preventDefault(),e.stopPropagation();return}r!==i&&(i!==null?this.setKeyboardIndex(i):(this.closeMenu(),this.oldFocus instanceof HTMLElement&&this.oldFocus.focus()),e.preventDefault(),e.stopPropagation())}openSubMenu(e){var{menuItems:n,activeSubMenu:r}=this.state,i=n[e].actions?e:null;r!==i&&this.setState({activeSubMenu:i,subMenuTop:null,subMenuLeft:null})}closeMenu(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,{closeMenu:n,onMenuClosed:r}=this.props;cancelAnimationFrame(this.rAF),this.rAF=window.requestAnimationFrame(()=>{n(e),r(this)})}closeSubMenu(){this.setState({activeSubMenu:null})}handleCloseSubMenu(e){e?this.closeMenu(!0):this.closeSubMenu()}handleMenuItemClick(e,n){n.preventDefault(),n.stopPropagation();var{menuItems:r}=this.state;e!=null&&(e.disabled===void 0||!e.disabled)&&(e.actions!=null?this.openSubMenu(r.indexOf(e)):e.action!=null&&(e.action(n.nativeEvent),this.closeMenu(!0)))}handleMenuItemContextMenu(e,n){n.metaKey||this.handleMenuItemClick(e,n)}handleMenuItemMouseMove(e){var{menuItems:n}=this.state,r=n.indexOf(e);this.setMouseIndex(r),r>=0&&r<n.length&&(e.disabled===void 0||!e.disabled)&&this.openSubMenu(r)}handleMouseLeave(){this.setMouseIndex(-1)}render(){for(var e=[],{top:n,left:r}=this.props,{activeSubMenu:i,hasOverflow:a,keyboardIndex:o,menuItems:s,mouseIndex:l,pendingItems:d,subMenuTop:f,subMenuLeft:p,subMenuParentWidth:h,subMenuParentHeight:m}=this.state,g=0;g<s.length;g+=1){var P=s[g];g>0&&P.group!==s[g-1].group&&e.push(u.jsx("hr",{},"".concat(g,".separator")));var v=u.jsx(vi,{ref:i===g?this.activeSubMenuRef:null,isKeyboardSelected:o===g,isMouseSelected:l===g,menuItem:P,closeMenu:this.handleCloseSubMenu,onMenuItemClick:this.handleMenuItemClick,onMenuItemMouseMove:this.handleMenuItemMouseMove,onMenuItemContextMenu:this.handleMenuItemContextMenu},g);e.push(v)}var y=null;d.length>0&&(y=u.jsx("div",{className:"loading",children:u.jsx(Je,{className:"loading-spinner-vertical-align"})}));var{menuStyle:x,"data-testid":w}=this.props,j=i!==null&&f!==null&&p!==null;return u.jsxs(u.Fragment,{children:[u.jsxs("div",{className:N({"has-overflow":a},"context-menu-container"),style:mg({top:n,left:r},x),ref:this.container,"data-dh-context-menu":!0,onBlur:this.handleBlur,onKeyDown:this.handleKeyDown,onMouseLeave:this.handleMouseLeave,onContextMenu:De.handleContextMenu,role:"menuitem",tabIndex:0,"data-testid":w,children:[e,y]}),j&&i!==null&&f!==null&&p!==null&&u.jsx(De,{actions:s[i].actions||[],closeMenu:this.handleCloseSubMenu,top:f,left:p,updatePosition:(b,S)=>{this.setState({subMenuTop:b,subMenuLeft:S})},subMenuParentWidth:h,subMenuParentHeight:m},"sub-".concat(i))]})}}se(De,"defaultProps",{subMenuParentWidth:0,subMenuParentHeight:0,closeMenu(){},onMenuOpened(){},onMenuClosed(){},options:{},menuStyle:{},"data-testid":void 0});function er(t,e,n){return(e=vg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function vg(t){var e=bg(t,"string");return typeof e=="symbol"?e:e+""}function bg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class Ba extends c.Component{constructor(e){super(e),er(this,"container",void 0),er(this,"openMenu",void 0),this.handleMenuClose=this.handleMenuClose.bind(this),this.handleContextMenu=this.handleContextMenu.bind(this),this.container=U.createRef(),this.openMenu=U.createRef(),this.state={actions:null,left:0,top:0}}componentDidMount(){var e;(e=this.container.current)!==null&&e!==void 0&&e.parentElement&&this.container.current.parentElement.addEventListener("contextmenu",this.handleContextMenu)}componentWillUnmount(){var e;(e=this.container.current)!==null&&e!==void 0&&e.parentElement&&this.container.current.parentElement.removeEventListener("contextmenu",this.handleContextMenu)}handleContextMenu(e){if(this.container.current){var n=this.container.current.getBoundingClientRect(),r=e.clientY-n.top,i=e.clientX-n.left,{actions:a}=this.state;if(a!=null&&e.target===this.container.current){e.preventDefault(),this.setState({actions:null},()=>{var s=document.elementFromPoint(i,r),l=new MouseEvent("contextmenu",{clientX:e.clientX,clientY:e.clientY,bubbles:!0,cancelable:!0});s==null||s.dispatchEvent(l)});return}if(ue.isContextActionEvent(e)&&!(e.metaKey||e.ctrlKey)){var o=ue.getMenuItems(e.contextActions);o.length!==0&&(e.preventDefault(),this.setState({actions:o,top:r,left:i}))}}}handleMenuClose(e){e===this.openMenu.current&&this.setState({actions:null})}render(){var e=null,{"data-testid":n}=this.props,{actions:r,top:i,left:a}=this.state;return r&&(e=u.jsx(De,{ref:this.openMenu,actions:r,onMenuClosed:this.handleMenuClose,top:i,left:a,updatePosition:(o,s)=>{this.setState({top:o,left:s})},"data-testid":n})),u.jsx("div",{className:N("context-menu-root",{active:r}),ref:this.container,children:e})}}function Pg(t,e,n){return(e=xg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function xg(t){var e=wg(t,"string");return typeof e=="symbol"?e:e+""}function wg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class ie extends c.Component{static handleEnter(e){var n=e;n.style.height="0"}static handleEntering(e){var n=e;n.style.height="".concat(ie.getHeight(n),"px")}static handleExiting(e){var n=e;n.style.height="0"}static handleExit(e){var n=e;n.style.height="".concat(ie.getHeight(n),"px")}static getHeight(e){var n=e.scrollWidth-e.clientWidth;return e.scrollHeight-n}constructor(e){super(e),this.handleEntered=this.handleEntered.bind(this)}handleEntered(e){var n=e;n.style.height="";var{autoFocusOnShow:r}=this.props;if(r!==void 0&&r){var i=n.querySelector("input, select, textarea");i!=null&&i.focus()}}render(){var{children:e,className:n,in:r,"data-testid":i}=this.props;return u.jsx(ei,{in:r,classNames:{enterActive:"collapsing",enterDone:"collapse show",exitActive:"collapsing",exitDone:"collapse"},onEnter:ie.handleEnter,onEntering:ie.handleEntering,onEntered:this.handleEntered,onExit:ie.handleExit,onExiting:ie.handleExiting,timeout:350,children:a=>u.jsx("div",{className:N({collapse:a==="exited"},n),"data-testid":i,children:e})})}}Pg(ie,"defaultProps",{className:"",autoFocusOnShow:!1,"data-testid":void 0});var Og=W.module("TimeInput"),Sg="([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]",Eg=["00:00:00","12:34:56","23:59:59"];function tr(t){return t!=null?"".concat(t.substring(0,8).replace(/\u2007/g,"0")).concat("00:00:00".substring(t.length)):t}var qe=U.forwardRef((t,e)=>{var{allowValueWrapping:n=!0,className:r="",onChange:i=ne,value:a=0,onFocus:o=ne,onBlur:s=ne,onSelect:l=ne,"data-testid":d}=t,[f,p]=c.useState(Ge.formatTime(a)),h=c.useRef(a),[m,g]=c.useState(),P=c.useRef(null);c.useImperativeHandle(e,()=>({focus:()=>{var b;(b=P.current)===null||b===void 0||b.focus()},setSelection:b=>{var S;(S=P.current)===null||S===void 0||S.focus(),g(b)}}),[]),c.useEffect(function(){h.current!==a&&(p(Ge.formatTime(a)),h.current=a)},[h,a]);function v(b,S,I){var k=b.selectionStart===0?24:60,L=parseInt(I,10)-S;return Number.isNaN(L)?L=0:n?L=(L%k+k)%k:L=Math.min(Math.max(0,L),k-1),"".concat(L).padStart(2,"0")}function y(b,S,I,k,L){return k===0&&L===2&&S===1&&parseInt(I,10)>1?"0".concat(I).concat(b.substring(2)):sa(b,S,I)}var x=c.useCallback(b=>{Og.debug("handleChange",b),p(b),h.current=Ge.parseTime(tr(b)),i(h.current)},[i]),w=c.useCallback(()=>{var b=tr(f);b!==f&&p(b),s()},[f,s]),j=c.useCallback(b=>{g(b),l(b)},[l]);return u.jsx(ln,{ref:P,className:r,example:Eg,getNextSegmentValue:v,getPreferredReplacementString:y,onChange:x,onSelect:j,pattern:Sg,selection:m,value:f,onFocus:o,onBlur:w,"data-testid":d})});function nr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Cg(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?nr(Object(n),!0).forEach(function(r){de(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):nr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function de(t,e,n){return(e=Tg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Tg(t){var e=jg(t,"string");return typeof e=="symbol"?e:e+""}function jg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var rr=-1,Wa=function(t){return t.UP="UP",t.DOWN="DOWN",t}(Wa||{});class z extends c.Component{constructor(e){super(e),de(this,"csContainer",void 0),de(this,"menuContainer",void 0),de(this,"button",void 0),de(this,"input",void 0);var{value:n,valueToTime:r}=e;this.toggleMenu=this.toggleMenu.bind(this),this.handleMenuKeyDown=this.handleMenuKeyDown.bind(this),this.closeMenu=this.closeMenu.bind(this),this.handleOptionClick=this.handleOptionClick.bind(this),this.handleOptionFocus=this.handleOptionFocus.bind(this),this.handleMenuOpened=this.handleMenuOpened.bind(this),this.handleMenuExited=this.handleMenuExited.bind(this),this.handleCustomInput=this.handleCustomInput.bind(this),this.csContainer=U.createRef(),this.menuContainer=U.createRef(),this.button=U.createRef(),this.input=U.createRef(),this.state={keyboardOptionIndex:0,menuIsOpen:!1,inputWidth:100,customTime:r(n),inputFocused:!1}}getSelectedText(){var{options:e,value:n,placeholder:r}=this.props,{customTime:i}=this.state;if(n===null)return r;for(var a=0;a<e.length;a+=1){var o=e[a];if(o.value===n)return o.title}return Ge.formatTime(i)}setInputWidth(){this.csContainer.current&&this.setState({inputWidth:this.csContainer.current.getBoundingClientRect().width})}focus(){var e;(e=this.button.current)===null||e===void 0||e.focus()}updateInputValue(e){var{onChange:n}=this.props;n(e)}handleResize(){this.setInputWidth()}handleMenuKeyDown(e){var n,{keyboardOptionIndex:r,inputFocused:i}=this.state,{options:a}=this.props;switch(e.key){case"Enter":case" ":i?this.updateFromCustom():this.updateInputValue(a[r].value),this.closeMenu(),(n=this.button.current)===null||n===void 0||n.focus(),e.stopPropagation(),e.preventDefault();break;case"Tab":e.shiftKey?this.handleMenuNavigation(z.MENU_NAVIGATION_DIRECTION.UP):this.handleMenuNavigation(z.MENU_NAVIGATION_DIRECTION.DOWN),e.stopPropagation(),e.preventDefault();break;case"ArrowUp":this.handleMenuNavigation(z.MENU_NAVIGATION_DIRECTION.UP),e.stopPropagation(),e.preventDefault();break;case"ArrowDown":this.handleMenuNavigation(z.MENU_NAVIGATION_DIRECTION.DOWN),e.stopPropagation(),e.preventDefault();break;case"Escape":this.closeMenu();break}}handleMenuNavigation(e){var{keyboardOptionIndex:n,inputFocused:r}=this.state,{options:i}=this.props,a=i.length,o=n;switch(e){case z.MENU_NAVIGATION_DIRECTION.UP:if(!r&&n===0){this.focusInput();break}else r&&this.focusOption(n);n>0&&!r?(o=(o-1)%a,this.setState({keyboardOptionIndex:o})):n===0&&(o=a-1,this.setState({keyboardOptionIndex:o})),this.scrollOptionIntoView(o);break;case z.MENU_NAVIGATION_DIRECTION.DOWN:if(!r&&n===a-1){this.focusInput();break}else r&&this.focusOption(n);n<a&&!(r&&n===0)&&(o=(o+1)%a,this.setState({keyboardOptionIndex:o})),this.scrollOptionIntoView(o);break}}handleOptionClick(e){var n=Number(e.currentTarget.value),{options:r,timeToValue:i}=this.props,{customTime:a}=this.state;if(n===rr){var o=i(a);this.updateAndClose(o)}else this.updateAndClose(r[n].value)}updateAndClose(e){var n;this.updateInputValue(e),this.closeMenu(),(n=this.button.current)===null||n===void 0||n.focus()}handleOptionFocus(e){this.setState({keyboardOptionIndex:Number(e.target.value)})}handleMenuOpened(){var e,{options:n,value:r}=this.props,{keyboardOptionIndex:i}=this.state;this.scrollOptionIntoView(i);var a=(e=this.menuContainer.current)===null||e===void 0?void 0:e.querySelector(".cs-option-btn.keyboard-active");if(a instanceof HTMLElement&&a.focus(),r!==null){var o=n.map(s=>s.value).indexOf(r);o<0&&this.focusInput()}}focusInput(){var e;(e=this.input.current)===null||e===void 0||e.focus()}focusOption(e){var n,r=(n=this.menuContainer.current)===null||n===void 0?void 0:n.querySelector(".cs-options");if(r&&r.children!=null){var i=r.children.item(e);i instanceof HTMLElement&&i.focus()}}handleMenuExited(){var{menuIsOpen:e}=this.state;e&&this.setState({menuIsOpen:!1,keyboardOptionIndex:0})}handleCustomInput(e){var{timeToValue:n}=this.props,r=n(e);this.updateInputValue(r),this.setState({customTime:e})}updateFromCustom(){var{timeToValue:e}=this.props,{customTime:n}=this.state,r=e(n);this.updateInputValue(r)}toggleMenu(e){var{menuIsOpen:n}=this.state;n?this.closeMenu():this.openMenu(),e.stopPropagation()}openMenu(){this.updateKeyboardIndex(),this.setInputWidth(),this.setState({menuIsOpen:!0})}closeMenu(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;if(this.setState({menuIsOpen:!1}),e){var n;(n=this.button.current)===null||n===void 0||n.focus()}}updateKeyboardIndex(){var{options:e,value:n}=this.props;if(n!==null){var r=e.map(i=>i.value).indexOf(n);r>0&&this.setState({keyboardOptionIndex:r})}}scrollOptionIntoView(e){var n,r=(n=this.menuContainer.current)===null||n===void 0?void 0:n.querySelector(".cs-options");if(r&&r.children!=null){var i=r.children.item(e);i instanceof HTMLElement&&i.offsetTop>z.DROP_DOWN_MENU_HEIGHT?r.scrollTop=i.offsetTop-z.DROP_DOWN_MENU_HEIGHT:(i instanceof HTMLElement&&i.offsetTop<0||e===0)&&(r.scrollTop=0)}}renderMenuElement(){var{inputWidth:e}=this.state;return u.jsx("div",{className:"cs-menu-container",ref:this.menuContainer,role:"presentation",onKeyDown:this.handleMenuKeyDown,onClick:n=>{n.stopPropagation()},style:{width:e},children:u.jsx("div",{className:"cs-options-container",children:u.jsx("div",{className:"cs-options",children:this.renderOptions()})})})}renderOptions(){for(var{options:e,value:n,icon:r,customText:i}=this.props,{keyboardOptionIndex:a,customTime:o,inputFocused:s}=this.state,l=!1,d=[],f=0;f<e.length;f+=1){var p=e[f],h="option-".concat(f,"-").concat(p.value);l=l||p.value===n,d.push(u.jsxs("button",{type:"button",value:f,className:N("cs-option-btn",{"keyboard-active":a===f&&!s}),onClick:this.handleOptionClick,onFocus:this.handleOptionFocus,children:[p.value===n&&u.jsx(Y,{icon:r,className:"mr-2"}),p.value!==n&&u.jsx("span",{className:"mr-4"}),p.title]},h))}return d.push(u.jsx("hr",{className:"cs-divider"},"option-divider")),d.push(u.jsxs("button",{type:"button",value:rr,className:N("cs-option-btn",{"keyboard-active":s}),onClick:this.handleOptionClick,onFocus:this.handleOptionFocus,children:[!l&&n!==null?u.jsx(Y,{icon:r,className:"mr-2"}):u.jsx("span",{className:"mr-4"}),i]},"option-custom-label")),d.push(u.jsxs("div",{className:"cs-custom-container",children:[u.jsx("span",{className:"mr-2"}),u.jsx(qe,{ref:this.input,onChange:this.handleCustomInput,value:o,onFocus:()=>this.setState({inputFocused:!0}),onBlur:()=>this.setState({inputFocused:!1})},"option-input"),u.jsx("span",{className:"ml-2"})]},"cs-custom-container")),d.push(u.jsx("hr",{className:"mb-2"},"option-end")),d}render(){var{disabled:e,invalid:n,value:r,"data-testid":i}=this.props,{menuIsOpen:a}=this.state,{popperOptions:o}=this.props;return o=Cg({placement:"bottom-end",modifiers:{preventOverflow:{enabled:!1}}},o),u.jsx("div",{className:"input-group cs-container context-menu",ref:this.csContainer,"data-testid":i,children:u.jsx("div",{className:N("input-group-append cs-dropdown",{"cs-dropdown-invalid":n}),children:u.jsxs("button",{type:"button",className:N("btn cs-btn form-control",{"cs-btn-invalid":n}),ref:this.button,onClick:this.toggleMenu,disabled:e,children:[u.jsx("span",{className:N({"text-muted":r===null}),children:this.getSelectedText()}),u.jsx("span",{className:"cs-caret"}),u.jsx(bi,{isShown:a,actions:{menuElement:this.renderMenuElement()},popperOptions:o,popperClassName:"CustomTimeSelect",onMenuOpened:this.handleMenuOpened,onMenuClosed:this.handleMenuExited,menuStyle:{maxWidth:"100rem"}})]})})})}}de(z,"MENU_NAVIGATION_DIRECTION",Wa);de(z,"DROP_DOWN_MENU_HEIGHT",125);de(z,"defaultProps",{onChange(){},value:null,disabled:!1,popperOptions:{},icon:el,customText:"Custom",placeholder:"Select a time",valueToTime:t=>t===null?0:Math.round(t/1e3),timeToValue:t=>t*1e3,invalid:!1,"data-testid":void 0});var Ig=W.module("DateInput"),kg="[12][0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])",_g=["2000-01-01","2022-12-31"],Dg="YYYY-MM-DD",Ha=U.forwardRef((t,e)=>{var{className:n="",onChange:r=()=>{},defaultValue:i="",onFocus:a=()=>{},onBlur:o=()=>{},"data-testid":s}=t,[l,d]=c.useState(i),[f,p]=c.useState(),h=c.useCallback(m=>{Ig.debug("handleChange",m),d(m),r(m)},[r]);return u.jsx("div",{className:"d-flex flex-row align-items-center",children:u.jsx(ln,{ref:e,className:N(n),example:_g,getNextSegmentValue:Np,onChange:h,onSelect:p,pattern:kg,placeholder:Dg,selection:f,value:l,onFocus:a,onBlur:o,"data-testid":s})})});Ha.displayName="DateInput";var Rg={CYCLE_TO_NEXT_STACK:fe.createAndAdd({id:"NAVIGATION.CYCLE_TO_NEXT_STACK",name:"Cycle To Next Stack",shortcut:[V.CTRL,K.SINGLE_QUOTE],macShortcut:[V.CMD,K.SINGLE_QUOTE],isEditable:!0}),CYCLE_TO_PREVIOUS_STACK:fe.createAndAdd({id:"NAVIGATION.CYCLE_TO_PREVIOUS_STACK",name:"Cycle To Previous Stack",shortcut:[V.CTRL,K.SEMICOLON],macShortcut:[V.CMD,K.SEMICOLON],isEditable:!0}),CYCLE_TO_NEXT_TAB:fe.createAndAdd({id:"NAVIGATION.CYCLE_TO_NEXT_TAB",name:"Cycle To Next Tab",shortcut:[V.CTRL,V.SHIFT,K.DOUBLE_QUOTE],macShortcut:[V.CMD,V.SHIFT,K.SINGLE_QUOTE],isEditable:!0}),CYCLE_TO_PREVIOUS_TAB:fe.createAndAdd({id:"NAVIGATION.CYCLE_TO_PREVIOUS_TAB",name:"Cycle To Previous Tab",shortcut:[V.CTRL,V.SHIFT,K.COLON],macShortcut:[V.CMD,V.SHIFT,K.SEMICOLON],isEditable:!0}),CYCLE_TO_NEXT_DASHBOARD:fe.createAndAdd({id:"NAVIGATION.CYCLE_TO_NEXT_DASHBOARD",name:"Cycle To Next Dashboard",shortcut:[V.CTRL,K.PERIOD],macShortcut:[V.CMD,K.PERIOD],isEditable:!0}),CYCLE_TO_PREVIOUS_DASHBOARD:fe.createAndAdd({id:"NAVIGATION.CYCLE_TO_PREVIOUS_DASHBOARD",name:"Cycle To Previous Dashboard",shortcut:[V.CTRL,K.COMMA],macShortcut:[V.CMD,K.COMMA],isEditable:!0})};function Lg(t){var{isInvalid:e=!1,items:n,onAdd:r=()=>{},onDelete:i=()=>{},validate:a=()=>null}=t,[o,s]=c.useState(null),[l,d]=c.useState([]),[f,p]=c.useState(""),h=c.useCallback(w=>{d(w)},[]),m=c.useCallback(()=>{i(xn.getItemsInRanges(n,l)),d([])},[n,l,i]),g=c.useCallback(()=>{if(f!==""){var w=a(f);w==null?(r(f),p("")):s(w)}},[f,r,a]),P=c.useCallback(w=>{var{value:j}=w.target;p(j),s(j===""?null:a(j))},[a]),v=c.useCallback(()=>{d([])},[]),y=c.useCallback(w=>{w.key==="Enter"&&g()},[g]),x=c.useMemo(()=>14+ti(n.length,1,6)*wt.DEFAULT_ROW_HEIGHT,[n.length]);return u.jsxs("div",{className:N("editable-item-list-container",{"is-invalid":e}),children:[u.jsx("div",{style:{height:x},children:u.jsx(wt,{itemCount:n.length,items:n.map((w,j)=>({value:w,isSelected:xn.isSelected(l,j)})),offset:0,selectedRanges:l,onSelectionChange:h,isMultiSelect:!0})}),u.jsxs("div",{className:"d-flex flex-row pt-2",children:[u.jsx("div",{className:"d-flex flex-grow-1",children:u.jsx("input",{className:N("form-control",{"is-invalid":o!=null}),placeholder:"Enter value",type:"text",value:f,onChange:P,onFocus:v,onKeyDown:y})}),u.jsxs("div",{className:"d-flex align-items-start mt-1 ml-2",children:[u.jsx(G,{kind:"ghost",onClick:g,disabled:o!=null||f==="",icon:tl,tooltip:"Add new item","data-testid":"add-item-button"}),u.jsx(G,{kind:"ghost",onClick:m,disabled:l.length===0,icon:ci,tooltip:"Delete selected items","data-testid":"delete-item-button"})]})]})]})}function Ag(t){var{message:e,isExpanded:n=!1,type:r="Error"}=t,[i,a]=c.useState(!1),[o,s]=c.useState(!1),l=c.useRef(null),d=c.useRef(null),f=c.useCallback(()=>{if(!(o||n||d.current==null)){var h=d.current.scrollHeight>d.current.clientHeight;a(h)}},[o,n]),p=ke(f,100);return tt(l.current,p),c.useLayoutEffect(p,[p]),u.jsxs("div",{className:N("error-view",{expanded:o||n}),ref:l,children:[u.jsxs("div",{className:"error-view-header",children:[u.jsxs("div",{className:"error-view-header-text",children:[u.jsx(Y,{icon:nl}),u.jsx("span",{children:r})]}),u.jsxs("div",{className:"error-view-buttons",children:[u.jsx(Yi,{kind:"danger",className:"error-view-copy-button",tooltip:"Copy exception contents",copy:"".concat(r,": ").concat(e).trim()}),(i||o)&&!n&&u.jsx(G,{kind:"danger",className:"error-view-expand-button",onClick:()=>{s(!o)},icon:o?rl:il,children:o?"Show Less":"Show More"})]})]}),u.jsx("pre",{className:"error-view-text",ref:d,children:e})]})}function Fg(t,e,n){return(e=Ng(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ng(t){var e=Mg(t,"string");return typeof e=="symbol"?e:e+""}function Mg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class xe extends c.Component{static isParentSelected(e,n){var r=n.get(e);if(r===void 0)return!1;if(typeof r=="boolean")return r;var i=Array.from(r.values()).includes(!0),a=Array.from(r.values()).includes(!1);return i&&a?null:i}constructor(e){super(e),this.toggleMenu=this.toggleMenu.bind(this),this.toggleValueFor=this.toggleValueFor.bind(this),this.selectAll=this.selectAll.bind(this),this.clear=this.clear.bind(this),this.state={menuIsOpen:!1}}toggleMenu(e){e.stopPropagation(),e.preventDefault(),this.setState(n=>{var{menuIsOpen:r}=n;return{menuIsOpen:!r}})}toggleValueFor(e,n){var{valueMap:r,onUpdateValueMap:i}=this.props,a=new Map(r),o=a.get(e);if(o instanceof Map){var s=new Map(o);if(n!=null)s.set(n,o.get(n)!==!0);else{var l=xe.isParentSelected(e,a),d=l==null||!l;o.forEach((h,m)=>s.set(m,d))}a.set(e,s)}else a.set(e,o==null||!o);var f=a.get(e);if(n===void 0&&f!==void 0&&typeof f!="boolean"){var p=xe.isParentSelected(e,r);p!=null&&p?f.forEach((h,m)=>f.set(m,!1)):f.forEach((h,m)=>f.set(m,!0))}i(a)}setAllValues(e){var{valueMap:n,onUpdateValueMap:r}=this.props,i=new Map;n.forEach((a,o)=>{if(typeof a=="boolean")i.set(o,e);else{var s=new Map;a.forEach((l,d)=>s.set(d,e)),i.set(o,s)}}),r(i)}selectAll(){this.setAllValues(!0)}clear(){this.setAllValues(!1)}renderMenuElement(){var{valueMap:e,"data-testid":n}=this.props;return u.jsxs("div",{className:"hcm-menu-container",children:[Array.from(e.entries()).map(r=>{var[i,a]=r;return u.jsxs("div",{children:[u.jsx(Ot,{className:"hcm-parent",checked:xe.isParentSelected(i,e),onChange:()=>this.toggleValueFor(i),children:i}),a!==void 0&&typeof a!="boolean"&&Array.from(a.entries()).map(o=>{var[s,l]=o;return u.jsx(Ot,{className:"hcm-child",checked:l,onChange:()=>this.toggleValueFor(i,s),children:s},s)})]},i)}),u.jsx(G,{kind:"ghost",onClick:this.selectAll,"data-testid":n!==void 0?"".concat(n,"-btn-select-all"):void 0,children:"Select All"}),u.jsx(G,{kind:"ghost",onClick:this.clear,"data-testid":n!==void 0?"".concat(n,"-btn-clear"):void 0,children:"Clear"})]})}render(){var{menuText:e,className:n,icon:r,id:i,"data-testid":a}=this.props,{menuIsOpen:o}=this.state;return u.jsxs("button",{type:"button",className:N("btn hcm-btn",n),onClick:this.toggleMenu,id:i,"data-testid":a,children:[u.jsxs("span",{children:[r&&u.jsx(Y,{icon:r,className:"hcm-icon mr-1"}),e]}),u.jsx("span",{className:"cs-caret"}),u.jsx(it,{options:{placement:"bottom"},isShown:o,onExited:()=>{this.setState({menuIsOpen:!1})},closeOnBlur:!0,interactive:!0,children:this.renderMenuElement()})]})}}Fg(xe,"defaultProps",{className:"",icon:null,id:"","data-testid":void 0});function ir(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function ft(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?ir(Object(n),!0).forEach(function(r){$g(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):ir(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function $g(t,e,n){return(e=Ug(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ug(t){var e=Bg(t,"string");return typeof e=="symbol"?e:e+""}function Bg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Va=c.memo(t=>{var{tab:e,onClose:n,onSelect:r,isActive:i,activeRef:a,index:o,isDraggable:s,contextActions:l}=t,{key:d,isClosable:f=n!=null,title:p,icon:h}=e,m;return h!=null&&(m=U.isValidElement(h)?h:u.jsx(Y,{icon:h})),u.jsx($o,{draggableId:d,index:o,isDragDisabled:!s,children:(g,P)=>u.jsxs("div",{className:"context-menu-wrapper",ref:i?a:null,children:[u.jsxs("div",ft(ft(ft({ref:g.innerRef},g.draggableProps),g.dragHandleProps),{},{className:N("btn btn-link btn-nav-tab",{active:i},{dragging:P.isDragging}),"data-testid":"btn-nav-tab-".concat(p),role:"tab",tabIndex:0,onAuxClick:v=>{f&&v.button===1&&v.buttons===0&&(n==null||n(d))},onClick:v=>{if(f&&v.button===1&&v.buttons===0){n==null||n(d);return}v.button===0&&v.buttons===0&&(v.target.focus(),r(d))},onKeyPress:v=>{v.key==="Enter"&&r(d)},children:[m,u.jsxs("span",{className:"btn-nav-tab-title",children:[p,u.jsx(Fe,{children:p})]}),f&&u.jsx(G,{kind:"ghost",className:"btn-nav-tab-close",onClick:v=>{n==null||n(d),v.stopPropagation(),v.preventDefault()},icon:di,tooltip:"Close"})]})),u.jsx(at,{actions:l})]})},d)});Va.displayName="NavTab";function Ga(t){var{onSelect:e,tabs:n=Pi}=t,[r,i]=c.useState(""),[a,o]=c.useState(0),s=c.useRef(null),l=c.useRef(null),d=c.useRef([]);c.useEffect(()=>{var y;(y=s.current)===null||y===void 0||y.focus()},[]),c.useEffect(()=>{o(0)},[r]),c.useEffect(()=>{if(a>=0&&d.current[a]){var y;(y=d.current[a])===null||y===void 0||y.scrollIntoView({behavior:"auto",block:"nearest"})}},[a]);var f=c.useCallback(y=>{i(y.target.value)},[]),p=c.useCallback(y=>{e(y)},[e]),h=c.useCallback(y=>{y.preventDefault()},[]),m=c.useMemo(()=>n.filter(y=>y.title.toLowerCase().includes(r.toLowerCase())),[r,n]).sort((y,x)=>{var w;return(w=y.title.localeCompare(x.title))!==null&&w!==void 0?w:0}),g=c.useCallback(y=>{if(y.key==="ArrowDown"&&m.length>0)y.preventDefault(),o(w=>w===-1?0:(w+1)%m.length);else if(y.key==="ArrowUp"&&m.length>0)y.preventDefault(),o(w=>w===-1?m.length-1:(w-1+m.length)%m.length);else if(y.key==="Enter"&&m.length>0){y.preventDefault();var x=a>=0?a:0;p(m[x])}else y.key==="Tab"&&y.preventDefault()},[m,a,p]),P=c.useMemo(()=>m.map((y,x)=>{var w;return u.jsx("li",{ref:j=>{d.current[x]=j},onMouseDown:h,children:u.jsxs(G,{kind:"ghost","data-testid":"dashboard-list-item-".concat((w=y.key)!==null&&w!==void 0?w:"","-button"),onClick:()=>p(y),className:a===x?"focused":"",style:{transition:"none"},children:[y.icon?u.jsx("span",{className:"dashboard-list-item-icon",children:U.isValidElement(y.icon)?y.icon:u.jsx(Y,{icon:y.icon})}):null,y.title]})},y.key)}),[m,p,a,h]),v=c.useMemo(()=>P.length===0?u.jsx("span",{children:"No open dashboard found."}):null,[P]);return u.jsxs("div",{className:"dashboard-list-container d-flex flex-column",children:[u.jsx("div",{className:"dashboard-list-header",children:u.jsx(Xt,{value:r,placeholder:"Find open dashboard",endPlaceholder:ot.OPEN_DASHBOARD_LIST.getDisplayText(),onChange:f,onKeyDown:g,ref:s})}),u.jsxs("ul",{className:"dashboard-list flex-grow-1",ref:l,children:[v&&u.jsx("li",{className:"dashboard-list-message",children:v}),!v&&P]})]})}function ar(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function or(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?ar(Object(n),!0).forEach(function(r){Wg(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):ar(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Wg(t,e,n){return(e=Hg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Hg(t){var e=Vg(t,"string");return typeof e=="symbol"?e:e+""}function Vg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Gg=500,Yg=.01,Kg=5e-4;function sr(t){return t.scrollLeft===0}function lr(t){return Math.abs(t.scrollLeft+t.clientWidth-t.scrollWidth)<=1||t.scrollWidth===0}function zg(t,e,n){var{isClosable:r=!1,key:i}=t,a=[];if(r&&n!=null){a.push({title:"Close",order:10,group:20,action:()=>{n(i)}});for(var o=!0,s=e.length-1;s>0&&e[s].key!==t.key;s-=1)if(e[s].isClosable===!0){o=!1;break}a.push({title:"Close to the Right",order:20,group:20,action:()=>{for(var l=e.length-1;l>0&&e[l].key!==i;l-=1)e[l].isClosable===!0&&n(e[l].key)},disabled:o}),a.push({title:"Close All",order:30,group:20,action:()=>{e.forEach(l=>{l.isClosable===!0&&n(l.key)})}})}return a}function qg(t){var{activeKey:e,tabs:n,onSelect:r,onReorder:i,onClose:a,makeContextActions:o}=t,s=c.useRef(),[l,d]=c.useState(!0),[f,p]=c.useState(!1),[h,m]=c.useState(!0),[g,P]=c.useState(!0),v=c.useCallback(()=>{s.current!=null&&(s.current.clientWidth<s.current.scrollWidth&&n.length>0?d(!0):d(!1),m(sr(s.current)),P(lr(s.current)))},[n]);tt(s.current,v);var y=c.useCallback(C=>{jt.stopDragging(),C.destination&&(i==null||i(C.source.index,C.destination.index))},[i]),x=c.useCallback(()=>{if(s.current!=null){var C=sr(s.current);C!==h&&m(C);var D=lr(s.current);D!==g&&P(D)}},[h,g]),w=c.useRef({cancelClick:!1}),j=c.useCallback(()=>{if(!(s.current==null||w.current.cancelClick))for(var{children:C}=s.current,D=C.length-1;D>=0;D-=1){var O=C[D];if(O.offsetLeft<s.current.scrollLeft-5){O.scrollIntoView({behavior:"smooth",block:"nearest",inline:"start"});return}}},[]),b=c.useCallback(()=>{if(!(s.current==null||w.current.cancelClick))for(var{children:C}=s.current,D=0;D<C.length;D+=1){var O=C[D];if(O.offsetLeft+5>s.current.scrollLeft+s.current.offsetWidth){O.scrollIntoView({behavior:"smooth",block:"nearest",inline:"end"});return}}},[]),S=c.useCallback(function(C,D){var O=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,T=arguments.length>3?arguments[3]:void 0,_=s.current;_!=null&&(w.current.cancelClick=!0,C==="left"?_.scrollLeft=D-O:C==="right"&&(_.scrollLeft=D+O),w.current.rAF=requestAnimationFrame(M=>{var J=T??M,Ee=M-J,pt=Yg*Ee+.5*Kg*Ee**2;pt=Math.min(pt,_.scrollWidth),S(C,D,pt,J)}))},[]),I=c.useCallback(()=>{var{holdTimer:C,rAF:D}=w.current;C!=null&&(clearTimeout(C),w.current.holdTimer=void 0),D!=null&&(cancelAnimationFrame(D),w.current.rAF=void 0),window.removeEventListener("mouseup",I)},[]);c.useEffect(()=>()=>window.removeEventListener("mouseup",I),[I]);var k=c.useCallback(C=>{s.current!=null&&(w.current.holdTimer=window.setTimeout(S,Gg,C,s.current.scrollLeft)),w.current.cancelClick=!1,window.addEventListener("mouseup",I)},[I,S]),L=c.useCallback(()=>{k("left")},[k]),F=c.useCallback(()=>{k("right")},[k]);c.useEffect(function(){var D,O=T=>{T.stopPropagation(),T.preventDefault();var _=T.currentTarget,M=Math.abs(T.deltaY)>Math.abs(T.deltaX)?T.deltaY:T.deltaX;_.scrollLeft+=ti(M,-30,30)};return(D=s.current)===null||D===void 0||D.addEventListener("wheel",O),()=>{var T;(T=s.current)===null||T===void 0||T.removeEventListener("wheel",O)}},[]);var H=c.useMemo(()=>{var C=new Map;return n.forEach(D=>{var{key:O}=D,T=[()=>zg(D,n,a),()=>{var _;return(_=o==null?void 0:o(D))!==null&&_!==void 0?_:[]}];C.set(O,T)}),C},[o,n,a]),E=c.useRef(null),A=n.find(C=>C.key===e),R=n.map((C,D)=>{var{key:O}=C,T=C===A;return u.jsx(Va,{tab:C,index:D,isActive:T,activeRef:E,onSelect:r,onClose:a,isDraggable:i!=null,contextActions:H.get(O)},O)});c.useEffect(function(){E.current!=null&&E.current.scrollIntoView({block:"nearest",inline:"nearest"})},[e]);var B=()=>{p(!f)},Q=C=>{p(!1),r(C.key)},Z=()=>{p(!1)};return u.jsxs("nav",{className:"nav-container",children:[l&&u.jsx(G,{kind:"ghost",icon:u.jsx(Y,{icon:al,transform:"grow-4"}),className:"tab-controls-btn tab-controls-btn-left",tooltip:"Scroll left",onClick:j,onMouseDown:L,disabled:h}),u.jsx(Uo,{onDragStart:jt.startDragging,onDragEnd:y,children:u.jsx(Bo,{droppableId:"droppable-tab-navigation",direction:"horizontal",children:(C,D)=>u.jsxs("div",or(or({ref:O=>{O!=null&&(s.current=O,C.innerRef(O))}},C.droppableProps),{},{className:N("nav nav-tabs",{dragging:D.draggingFromThisWith}),role:"tablist",onScroll:x,children:[R,C.placeholder]}))})}),l&&u.jsx(G,{kind:"ghost",icon:u.jsx(Y,{icon:ol,transform:"grow-4"}),className:"tab-controls-btn tab-controls-btn-right",tooltip:"Scroll right",onClick:b,onMouseDown:F,disabled:g}),u.jsx(G,{kind:"ghost",icon:u.jsx(Y,{icon:sl,transform:"grow-4"}),className:"btn-dashboard-list-menu btn-show-dashboard-list",tooltip:"Search open dashboards",onClick:B,disabled:n.length<2,style:{visibility:l?"visible":"hidden",marginLeft:"auto"},children:u.jsx(it,{isShown:f,className:"dashboard-list-menu-popper",onExited:Z,options:{placement:"bottom-start"},closeOnBlur:!0,interactive:!0,children:u.jsx(Ga,{tabs:n,onSelect:Q})})}),u.jsx(at,{actions:[{action:()=>{p(!f)},shortcut:ot.OPEN_DASHBOARD_LIST,isGlobal:!0}]})]})}var Xg=.025,Qg=.9,Jg=.1,Zg=.618,ur=80,ve={SIZE:8,DOT_SIZE:2},ae=18,ey=250,ty=60*1e3,ny={background:"var(--dh-color-random-area-plot-animation-bg)",foregroundFill:"var(--dh-color-random-area-plot-animation-fg-fill)",foregroundStroke:"var(--dh-color-random-area-plot-animation-fg-stroke)",gridColor:"var(--dh-color-random-area-plot-animation-grid)"};function ry(){return pi(ny)}var Ya=U.memo(()=>{var{activeThemes:t}=rt(),e=c.useMemo(ry,[t]),n=c.useRef(null),r=c.useRef(null),[i,a]=c.useState(!1),o=window.devicePixelRatio,s,l,d,f,p,h=null,m=[];function g(){var E;r.current!=null&&(d=r.current.offsetWidth,f=r.current.offsetHeight),n.current!=null&&(n.current.style.width="".concat(d,"px"),n.current.style.height="".concat(f,"px"),n.current.width=d*o,n.current.height=f*o),(E=s)===null||E===void 0||E.scale(o,o)}function P(){var{foregroundFill:E,foregroundStroke:A}=e,R=document.createElement("canvas");R.width=ve.SIZE,R.height=ve.SIZE;var B=R.getContext("2d");return B!=null&&(B.fillStyle=A,B.fillRect(0,0,ve.DOT_SIZE,ve.DOT_SIZE),B.fillStyle=E,B.fillRect(0,0,ve.SIZE,ve.SIZE)),B==null?void 0:B.createPattern(R,"repeat")}function v(E){var A=Math.random()-.5,R=Xg*A;return E<Jg?R=Math.abs(R):E>Qg&&(R=-Math.abs(R)),E+R}function y(){for(var E=[],A=Zg,R=0;R<d+ae;R+=1)A=v(A),E.push(A);return E}function x(){for(;m.length>=d+ae;)m.pop();for(;m.length<d+ae;)m.push(v(m[m.length-1]))}function w(E,A){A.beginPath(),A.moveTo(-1,f+1),A.lineTo(-1,f*E[0]);for(var R=0;R<E.length;R+=1)A.lineTo(R,f*E[R]);A.lineTo(d+ae,f*E[E.length-1]),A.lineTo(d+ae,f+1),A.closePath()}function j(E){E.beginPath();for(var A=1;A<d;A+=ur)E.moveTo(A,0),E.lineTo(A,f);for(var R=1;R<f;R+=ur)E.moveTo(0,R),E.lineTo(d,R)}function b(E){h=h??E;var{background:A,foregroundStroke:R,gridColor:B}=e;Ze(s),s.fillStyle=A,s.fillRect(0,0,d,f),j(s),s.lineWidth=1,s.strokeStyle=B,s.stroke();var Q=((h??0)-(E??0))/(1e3/ae);if(s.translate(Q,0),w(m,s),s.lineWidth=2,s.strokeStyle=R,s.stroke(),s.translate(-Q,0),l!=null&&(s.fillStyle=l),s.fill(),s.setTransform(o,0,0,o,0,0),(E??0)-(h??0)>1e3/ae){for(var Z=Math.floor(((E??0)-(h??0))/(1e3/ae)),C=0;C<Z;C+=1)m.shift(),m.push(v(m[m.length-1]));h=E}p!=null&&cancelAnimationFrame(p),p=requestAnimationFrame(b)}var S=Ie(()=>{p=requestAnimationFrame(E=>{g(),x(),a(!1),b(E)})},ey,{leading:!0});function I(){a(!0),p!=null&&cancelAnimationFrame(p),p=null,h=null}var k=Ie(()=>{I()},ty);function L(){p==null&&(a(!1),g(),x(),p=requestAnimationFrame(b)),k()}function F(){document.hasFocus()&&L()}function H(){p!=null&&cancelAnimationFrame(p),k(),S()}return c.useEffect(()=>{var E;return s=(E=n.current)===null||E===void 0?void 0:E.getContext("2d",{alpha:!1}),g(),m=y(),l=P(),b(),k(),window.addEventListener("resize",H),window.addEventListener("focus",L),window.addEventListener("blur",I),window.addEventListener("mousemove",F),window.addEventListener("keydown",F),()=>{p!=null&&cancelAnimationFrame(p),window.removeEventListener("resize",H),window.removeEventListener("focus",L),window.removeEventListener("blur",I),window.removeEventListener("mousemove",F),window.removeEventListener("keydown",F),k.cancel(),S.cancel()}},[e]),u.jsx("div",{className:"random-area-plot-animation-container",ref:r,children:u.jsx("canvas",{ref:n,className:i?"shade":""})})});function Ka(t){var{text:e,placement:n="top-start"}=t,r=c.useMemo(()=>({placement:n}),[n]);return u.jsxs(u.Fragment,{children:[u.jsx(lt,{UNSAFE_className:on.spectrumEllipsis,children:e??u.jsx(u.Fragment,{children:" "})}),e==null||e===""?null:u.jsx(Fe,{options:r,children:e})]})}var iy=["scrollRef","getItemDisplayText","getKey"];function cr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function dr(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?cr(Object(n),!0).forEach(function(r){ay(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):cr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function ay(t,e,n){return(e=oy(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function oy(t){var e=sy(t,"string");return typeof e=="symbol"?e:e+""}function sy(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function ly(t,e){if(t==null)return{};var n,r,i=uy(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function uy(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function cy(t){var{scrollRef:e,getItemDisplayText:n,getKey:r}=t,i=ly(t,iy),a=c.useCallback(o=>{var s=r(o),l=n(o);return u.jsx(Xe,{textValue:l??String(s),children:u.jsx(Ka,{text:l})},s)},[n,r]);return u.jsx(Wt,dr(dr({},i),{},{ref:e,menuTrigger:"focus",onSelectionChange:i.onSelectionChange,children:a}))}var dy=500;function py(t){var{heading:e,content:n,delayMs:r=dy}=t,[i,a]=c.useState(!1);return c.useEffect(()=>{window.setTimeout(()=>{a(!0)},r)},[r]),i?u.jsxs(ni,{children:[u.jsx(Le,{size:"XXL",children:u.jsx(Y,{icon:ll})}),u.jsx(ut,{children:e}),n==null?null:u.jsx(Ht,{children:n})]}):null}const za={"handle-size":"15px","popover-width":"90px"};var We=parseInt(za["handle-size"],10),pr=parseInt(za["popover-width"],10),q=24*60*60-1,fr=5*60;function fy(t){var{startTime:e,endTime:n,onChange:r,isStartModified:i=!1,isEndModified:a=!1,"data-testid":o}=t,[s,l]=c.useState(e),[d,f]=c.useState(n),p=c.useRef(null);c.useEffect(function(){l(e),f(n)},[e,n]);var h=c.useCallback((P,v)=>{var y=P,x=v;y===x&&(x<q?x+=1:y-=1),l(y),f(x),r({startTime:y,endTime:x})},[l,f,r]),m=c.useCallback(P=>{h(P,d)},[h,d]),g=c.useCallback(P=>{h(s,P)},[h,s]);return u.jsxs("div",{className:"time-slider","data-testid":o,children:[u.jsx(hy,{startTime:s,endTime:d,onStartTimeChange:m,onEndTimeChange:g,isStartModified:i,isEndModified:a}),u.jsxs("div",{className:"track",ref:p,children:[u.jsx(my,{startTime:s,endTime:d}),u.jsx("div",{className:"ticks",children:Array(24).fill(null).map((P,v)=>u.jsx("div",{className:"tick"},v))}),u.jsx(hr,{track:p,time:s,setTime:m}),u.jsx(hr,{track:p,time:d,setTime:g})]}),u.jsxs("div",{className:"tick-labels",children:[u.jsx("div",{className:"tick-label",children:"0:00"}),u.jsx("div",{className:"tick-label-wrapper",children:Array(24).fill(null).map((P,v)=>u.jsx("div",{className:"tick-label",children:"".concat(v+1,":00")},v))})]})]})}function hy(t){var{startTime:e,endTime:n,onStartTimeChange:r,onEndTimeChange:i,isStartModified:a,isEndModified:o,"data-testid":s}=t,l=e>n,[d,f]=c.useState(l?n:e),[p,h]=c.useState(l?e:n),m=c.useRef(null),g=c.useRef(null),P=c.useRef(null),v=c.useRef(null);c.useEffect(function(){f(e>n?n:e),h(e>n?e:n)},[e,n]),c.useEffect(function(){if(P.current!==null){var S;(S=g.current)===null||S===void 0||S.setSelection(P.current)}if(v.current!==null){var I;(I=m.current)===null||I===void 0||I.setSelection(v.current)}},[l]);function y(b){e<=n?r(b):i(b)}function x(b){e<=n?i(b):r(b)}var w=c.useCallback(b=>{P.current=b,v.current=null},[]),j=c.useCallback(b=>{P.current=null,v.current=b},[]);return u.jsxs("div",{className:"time-slider-popovers",children:[u.jsx("div",{className:"flex",style:{flexBasis:"calc(".concat(d/q*100,"% - ").concat(pr/2,"px)")}}),u.jsxs("div",{className:"handle-popper",children:[u.jsx("label",{className:N({modified:l?o:a}),children:l?"End Time":"Start Time"}),u.jsx(qe,{ref:m,allowValueWrapping:!1,value:d,onChange:y,onSelect:w,"data-testid":s!==void 0?"".concat(s,"-input-1"):void 0})]}),u.jsx("div",{className:"flex-spacer"}),u.jsxs("div",{className:"handle-popper",children:[u.jsx("label",{className:N({modified:l?a:o}),children:l?"Start Time":"End Time"}),u.jsx(qe,{ref:g,allowValueWrapping:!1,value:p,onChange:x,onSelect:j,"data-testid":s!==void 0?"".concat(s,"-input-2"):void 0})]}),u.jsx("div",{className:"flex",style:{flexBasis:"calc(".concat((q-p)/q*100,"% - ").concat(pr/2,"px)")}})]})}function my(t){var{startTime:e,endTime:n,"data-testid":r}=t;return u.jsxs("div",{className:"track-fills","data-testid":r,children:[e>n&&u.jsxs(u.Fragment,{children:[u.jsx("div",{className:"track-fill track-fill-start",style:{transform:"scaleX(".concat(n/q,")")}}),u.jsx("div",{className:"track-fill track-fill-end",style:{transform:"scaleX(".concat((q-e)/q,")")}})]}),e<n&&u.jsx("div",{className:"track-fill track-fill-middle",style:{transform:"translateX(".concat(e/q*100,"%) scaleX(").concat((n-e)/q,")")}})]})}function hr(t){var{track:e,time:n,setTime:r,"data-testid":i}=t,a=c.useMemo(()=>{var h=3600,m=We/2;return n<h?m=n/h*(We/2):n>23*h&&(m=We/2+1/(q-23*h)*(n-23*h)*(We/2)),"translateX(calc(".concat(n/q*100,"% - ").concat(m,"px))")},[n]),o=c.useCallback(h=>{if(!e.current)return 0;var m=e.current.getBoundingClientRect(),g=Math.max(h-m.left,0),P=q*Math.min(1,g/m.width),v=fr*Math.round(P/fr),y=Math.min(q,v);return y},[e]),s=c.useCallback(h=>{var{clientX:m}=h;r(o(m))},[r,o]),l=c.useCallback(h=>{var{clientX:m}=h;r(o(m)),window.removeEventListener("mousemove",s),window.removeEventListener("mouseup",l),document.documentElement.classList.remove("drag-pointer-events-none")},[r,o,s]),d=c.useCallback(()=>{window.addEventListener("mousemove",s),window.addEventListener("mouseup",l),document.documentElement.classList.add("drag-pointer-events-none")},[s,l]),f=c.useCallback(()=>{window.removeEventListener("mousemove",s),window.removeEventListener("mouseup",l),document.documentElement.classList.remove("drag-pointer-events-none")},[s,l]),p=c.useCallback(()=>{d()},[d]);return c.useEffect(function(){return()=>{f()}},[f]),u.jsx("div",{className:"handle-track",style:{transform:a},children:u.jsx("button",{className:"handle",type:"button","aria-label":"Change time",onMouseDown:p,"data-testid":i})})}function qa(t){var{buttons:e,isShown:n=!1,classNames:r,message:i,type:a,onClick:o,onDismiss:s,"data-testid":l}=t,d=e&&e.length!==0;return u.jsx(ei,{in:n,timeout:xt.transitionMs,classNames:"toast-notification-slide-up",mountOnEnter:!0,unmountOnExit:!0,children:u.jsxs("div",{className:N("toast-notification",r,a),role:"presentation",onClick:o,onKeyPress:o,"data-testid":l,children:[u.jsx("div",{className:"message-container",children:u.jsx("span",{className:"message",children:i})}),u.jsx(Jt,{in:d,timeout:xt.transitionSlowMs,mountOnEnter:!0,unmountOnExit:!0,children:u.jsx("div",{className:"buttons-container",children:e})}),s&&u.jsx(G,{kind:"ghost",icon:di,tooltip:"Close notification",className:"my-2",onClick:s})]})})}qa.TYPE=Object.freeze({ERROR:"error"});const gy=Object.freeze(Object.defineProperty({__proto__:null,ACTION_ICON_HEIGHT:sn,Accordion:Wo,ActionBar:Zr,ActionButton:Qe,ActionButtonDialogTrigger:Aa,ActionGroup:Mp,ActionMenu:$p,AlertDialog:Ho,AutoCompleteInput:te,AutoResizeTextarea:ug,Avatar:Vo,Badge:Go,BasicModal:xi,Breadcrumbs:Yo,BulkActionBar:hg,Button:G,ButtonGroup:Jr,CSS_VAR_EXPRESSION_PREFIX:ul,Calendar:Ko,CardFlip:xd,Checkbox:Ot,CheckboxGroup:Wm,Collapse:ie,ColorEditor:zo,ColorPicker:qo,ColorValues:Up,ComboBox:Bp,ComboBoxNormalized:Da,ConfirmActionButton:Jm,ConfirmationDialog:Fa,Content:Ht,ContextActionUtils:ue,ContextActions:at,ContextMenuItem:vi,ContextMenuRoot:Ba,ContextualHelp:Xo,ContextualHelpTrigger:Qo,CopyButton:Yi,CustomTimeSelect:z,DEFAULT_DARK_THEME_KEY:cl,DEFAULT_DARK_THEME_PALETTE:dl,DEFAULT_GET_PREFERRED_REPLACEMENT_STRING:sa,DEFAULT_LIGHT_THEME_KEY:pl,DEFAULT_PRELOAD_DATA_VARIABLES:fl,DH_CSS_VAR_NAME_REGEXP:hl,DH_VAR_PREFIX:ml,DashboardList:Ga,DateField:Jo,DateInput:Ha,DatePicker:Zo,DateRangePicker:es,DateTimeInput:Wp,DebouncedModal:$a,DebouncedSearchInput:bu,Dialog:qr,DialogContainer:ts,DialogTrigger:zr,Disclosure:ns,DisclosurePanel:rs,DisclosureTitle:is,Divider:Xr,DragUtils:jt,DraggableItemList:Hp,DropdownMenu:bi,EXTERNAL_THEME_KEY:gl,EditableItemList:Lg,ErrorBoundary:Pu,ErrorView:Ag,FadeTransition:Jt,Flex:Kr,Footer:as,Form:Qr,GLOBAL_SHORTCUTS:ot,Grid:os,Header:ss,Heading:ut,HierarchicalCheckboxMenu:xe,ITEM_EMPTY_STRING_TEXT_VALUE:Vp,Icon:Le,IconActionButton:Na,IllustratedMessage:ni,Image:ls,InfoModal:Ua,InlineAlert:us,Item:Xe,ItemContent:Gp,ItemList:wt,ItemListItem:xu,ItemTooltip:Yp,KEY:K,Keyboard:cs,LIST_VIEW_ROW_HEIGHTS:la,LabeledValue:ds,Link:ri,ListActionGroup:Kp,ListActionMenu:zp,ListView:ym,ListViewNormalized:Ra,ListViewWrapper:dn,LoadingOverlay:ge,LoadingSpinner:Je,LogicButton:ps,Logo:Jh,MODIFIER:V,MSG_REQUEST_GET_THEME:yl,MSG_REQUEST_SET_THEME:li,MaskedInput:ln,Menu:qp,MenuItem:Xp,MenuTrigger:fs,Meter:hs,Modal:Yt,ModalBody:Kt,ModalFooter:wi,ModalHeader:fi,NAVIGATION_SHORTCUTS:Rg,NON_WHITESPACE_REGEX:vl,NavTabList:qg,NumberField:ms,Option:ua,PICKER_ITEM_HEIGHTS:Qp,PICKER_TOP_OFFSET:Jp,PRELOAD_TRANSPARENT_THEME_QUERY_PARAM:bl,Page:Zp,Picker:ef,PickerNormalized:tf,Popper:it,ProgressBar:gs,ProgressCircle:ys,Radio:vs,RadioGroup:bs,RandomAreaPlotAnimation:Ya,RangeCalendar:Ps,RangeSlider:xs,SVG_ICON_MANUAL_COLOR_MAP:Pl,SearchField:ws,SearchInput:Xt,SearchableCombobox:cy,Section:nf,Select:Oi,SelectValueList:ca,Shortcut:wu,ShortcutRegistry:fe,SlideTransition:rf,Slider:Os,SocketedButton:wd,SpectrumButton:bt,SpectrumCheckbox:vt,SpectrumComboBox:Wt,SpectrumMenu:Ss,SplitButtonGroup:Ou,Stack:af,StatusLight:Es,SubmenuTrigger:Cs,Switch:Ts,TABLE_ROW_HEIGHT:of,THEME_CACHE_LOCAL_STORAGE_KEY:xl,THEME_KEY_OVERRIDE_QUERY_PARAM:wl,TMP_CSS_PROP_PREFIX:Ol,TRANSPARENT_PRELOAD_DATA_VARIABLES:Sl,TabList:js,TabPanels:Ch,TableViewEmptyState:py,Tabs:Is,TagGroup:ks,Text:lt,TextArea:_s,TextField:Ds,TextWithTooltip:Ka,ThemeContext:Su,ThemeExport:xt,ThemePicker:Qh,ThemeProvider:Si,TimeField:Rs,TimeInput:qe,TimeSlider:fy,ToastContainer:Ls,ToastNotification:qa,ToastQueue:As,ToggleButton:Fs,Tooltip:Fe,UISwitch:Eu,View:La,WHITESPACE_REGEX:El,Well:Ns,XComponentMapContext:Cu,XComponentMapProvider:Tu,baseStyleProps:Ms,calculatePreloadStyleContent:Cl,canHaveRef:Ei,colorValueStyle:X,createCssVariableResolver:Tl,createPreloadStyleElement:jl,createXComponent:ju,extractDistinctCssVariableExpressions:Il,fillToLength:sf,getActiveThemes:kl,getDefaultBaseThemes:_l,getDefaultSelectedThemeKey:Dl,getExpressionRanges:Rl,getItemKey:Tt,getItemTextValue:lf,getPositionOfSelectedItemElement:uf,getThemeKey:Ll,getThemeKeyOverride:Al,getThemePreloadData:Fl,isBaseThemeKey:Nl,isClassComponent:Iu,isDHColorValue:cf,isExternalThemeData:ui,isExternalThemeEnabled:Vt,isForwardRefComponentType:ku,isItemElement:df,isItemElementWithDescription:pf,isItemOrSection:ff,isNormalizedItemsWithKeysList:hf,isNormalizedSection:mf,isPreloadTransparentTheme:Ml,isSectionElement:gf,isValidColorVar:$l,isWrappedComponent:Ci,itemSelectionToStringSet:Ye,normalizeTooltipOptions:an,overrideSVGFillColors:Ul,parseExternalThemeData:oi,preloadTheme:Bl,replaceSVGFillColor:Wl,requestExternalThemeData:si,resolveCssVariablesInRecord:pi,resolveCssVariablesInString:Hl,separateSpectrumProps:Ia,setThemePreloadData:Vl,themeDHDefault:Gl,themeDark:Yl,themeLight:Kl,trimTrailingMask:yf,useExternalTheme:_a,useOnChangeTrackUncontrolled:vf,usePickerItemScale:da,usePickerNormalizedProps:ia,usePickerProps:bf,usePickerScrollOnOpen:Pf,useRenderNormalizedItem:oa,useSpectrumThemeProvider:rn,useStaticItemInitialScrollPosition:xf,useStringifiedMultiSelection:ka,useStringifiedSelection:wf,useStyleProps:$s,useTheme:rt,useXComponent:_u,viewStyleProps:Us,wrapIcon:Of,wrapItemChildren:aa,wrapPrimitiveWithText:Sf},Symbol.toStringTag,{value:"Module"}));var Xa=U.memo(t=>{var{children:e,onError:n,widget:r}=t,[i,a]=Zt(r);return a!=null?(n==null||n(a),null):i==null?null:u.jsx(zt.Provider,{value:i,children:e})});Xa.displayName="DeferredApiBootstrap";var ct=c.createContext(null);ct.displayName="ObjectFetchManagerContext";function Qa(t){var[e,n]=c.useState({status:"loading"}),r=c.useContext(ct);return c.useEffect(()=>{if(r==null){n({error:new Error("No ObjectFetchManager available in context"),status:"error"});return}return n(i=>i.status==="loading"?i:{status:"loading"}),r.subscribe(t,n)},[t,r]),e}function mr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function gr(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?mr(Object(n),!0).forEach(function(r){yy(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):mr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function yy(t,e,n){return(e=vy(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function vy(t){var e=by(t,"string");return typeof e=="symbol"?e:e+""}function by(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function yr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function Py(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){yr(a,r,i,o,s,"next",l)}function s(l){yr(a,r,i,o,s,"throw",l)}o(void 0)})}}var He=W.module("useWidget");function xy(t){var[e,n]=c.useState(()=>({widget:null,error:null})),r=Qa(t),[i,a]=Zt(t),o=ye(),s=i??o;c.useEffect(function(){He.debug("loadWidget",t);var{status:f}=r;if(f==="error"){n({widget:null,error:r.error});return}if(f==="loading"){n({widget:null,error:null});return}var{fetch:p}=r,h=!1;function m(){return g.apply(this,arguments)}function g(){return g=Py(function*(){try{Ze(p);var P=yield p();if(h){He.debug2("loadWidgetInternal cancelled",t,P),P.close(),"exportedObjects"in P&&P.exportedObjects.forEach(v=>{v.close()});return}He.debug("loadWidgetInternal done",t,P),n({widget:P,error:null})}catch(v){if(h)return;He.error("loadWidgetInternal error",t,v),n({widget:null,error:v??new Error("Null error")})}}),g.apply(this,arguments)}return m(),()=>{h=!0}},[t,r]);var l=c.useMemo(()=>{var d;return gr(gr({},e),{},{error:(d=e.error)!==null&&d!==void 0?d:a,api:e.widget!=null?s:null})},[e,s,a]);return l}const wy=Object.freeze(Object.defineProperty({__proto__:null,ApiBootstrap:zl,ApiContext:zt,ClientBootstrap:mi,ClientContext:nu,DeferredApiBootstrap:Xa,DeferredApiContext:Od,ObjectFetchManagerContext:ct,ObjectFetcherContext:Ti,getVariableDescriptor:Du,isIdVariableDescriptor:Ru,isNameVariableDescriptor:Lu,isVariableDescriptor:Au,sanitizeVariableDescriptor:ji,useApi:ye,useClient:Ae,useDeferredApi:Zt,useObjectFetch:Qa,useObjectFetcher:Fu,useWidget:xy},Symbol.toStringTag,{value:"Module"}));function Oy(t){return function(n){var{children:r}=n;return u.jsx(zt.Provider,{value:t,children:r})}}var Ja="io.deephaven.message.LoginOptions.request",Za="io.deephaven.message.SessionDetails.request",eo="io.deephaven.broadcast",pn="io.deephaven.broadcast.Login",to="io.deephaven.broadcast.Logout";function no(t){return et(t)&&t.message===pn}function ro(t){return et(t)&&t.message===to}function Sy(t,e,n){return(e=Ey(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ey(t){var e=Cy(t,"string");return typeof e=="symbol"?e:e+""}function Cy(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class io extends Error{constructor(){super(...arguments),Sy(this,"isNoConsolesError",!0)}}function ao(t){return t.isNoConsolesError}function vr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function dt(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){vr(a,r,i,o,s,"next",l)}function s(l){vr(a,r,i,o,s,"throw",l)}o(void 0)})}}var je=W.module("SessionUtils");function oo(t,e,n){return kt.apply(this,arguments)}function kt(){return kt=dt(function*(t,e,n){je.info("Getting console types...");var r=yield e.getConsoleTypes();if(r.length===0)throw new io("No console types available");je.info("Available types:",r);var i=r[0];je.info("Starting session with type",i);var a=yield e.startSession(i),o={type:i,id:Bt()};return je.info("Console session established",o),{session:a,config:o,connection:e,details:n,dh:t}}),kt.apply(this,arguments)}function Ty(t,e,n){return je.info("createCoreClient",e),new t.CoreClient(e,n)}function jy(t){return t!=null&&typeof t=="object"}function Iy(){return _t.apply(this,arguments)}function _t(){return _t=dt(function*(){var t=yield qt(Za);if(!jy(t))throw new Error("Unexpected session details response: ".concat(t));return t}),_t.apply(this,arguments)}function ky(){return Dt.apply(this,arguments)}function Dt(){return Dt=dt(function*(){var t=new URLSearchParams(window.location.search);switch(t.get("authProvider")){case"parent":return Iy()}return{}}),Dt.apply(this,arguments)}function _y(t,e,n){return Rt.apply(this,arguments)}function Rt(){return Rt=dt(function*(t,e,n){var r;try{r=yield oo(t,e,n)}catch(i){if(!ao(i))throw i}return r}),Rt.apply(this,arguments)}const Dy=Object.freeze(Object.defineProperty({__proto__:null,BROADCAST_CHANNEL_NAME:eo,BROADCAST_LOGIN_MESSAGE:pn,BROADCAST_LOGOUT_MESSAGE:to,BooleanColumnFormatter:Sd,CharColumnFormatter:Ed,DateTimeColumnFormatter:Nu,DateUtils:Cd,DecimalColumnFormatter:Mu,DefaultColumnFormatter:Td,FETCH_TIMEOUT:ru,Formatter:en,FormatterUtils:Ct,ITEM_KEY_PREFIX:jd,IntegerColumnFormatter:$u,LOGIN_OPTIONS_REQUEST:Ja,NewTableColumnTypes:Uu,NoConsolesError:io,SESSION_DETAILS_REQUEST:Za,StringColumnFormatter:Id,TableColumnFormatter:Bu,TableUtils:kd,createComboboxFilterArgs:_d,createCoreClient:Ty,createFilterConditionFactory:tn,createFormatterFromSettings:Dd,createKeyedItemKey:Ki,createNotNullOrEmptyFilterCondition:zi,createOnTableUpdatedHandler:Rd,createSearchTextFilter:qi,createSelectedValuesFilter:nn,createSessionWrapper:oo,createShowOnlyEmptyFilterCondition:Xi,createValueFilter:Qi,defaultRowDeserializer:Ld,fetchVariableDefinition:iu,generateEmptyKeyedItems:Ad,getColumnFormats:Fd,getDateTimeFormatterOptions:Nd,getSessionDetails:ky,getSize:Md,getWindowParent:Gt,isBroadcastLoginMessage:no,isBroadcastLogoutMessage:ro,isClosed:$d,isCustomColumnFormatDefined:Ud,isMessage:et,isNoConsolesError:ao,isResponse:ql,isSortDirection:Bd,loadSessionWrapper:_y,makeMessage:hi,makeResponse:Xl,padFirstAndLastRow:Wd,requestParentResponse:qt},Symbol.toStringTag,{value:"Module"}));function Ry(t,e,n){return(e=Ly(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ly(t){var e=Ay(t,"string");return typeof e=="symbol"?e:e+""}function Ay(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class Fy extends Error{constructor(){super(...arguments),Ry(this,"isColumnNameError",!0)}}function Ny(t,e,n){return(e=My(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function My(t){var e=$y(t,"string");return typeof e=="symbol"?e:e+""}function $y(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class Uy extends Error{constructor(){super(...arguments),Ny(this,"isTableDisconnectError",!0)}}var Ve=W.module("useTable"),so=(t,e,n,r)=>{var i=ye(),[a,o]=c.useState(void 0),[s,l]=c.useState([]),[d,f]=c.useState(null),[p,h]=c.useState(null);c.useEffect(()=>{if(r===void 0){o(t==null?void 0:t.columns),f(null);return}try{o(t==null?void 0:t.findColumns(r)),f(null)}catch(v){Ve.error("Column not found",v,r),f(new Fy("Invalid columnNames argument"))}},[t,r]),c.useEffect(()=>{if(!a||!t){Ve.debug2("Table or column not initialized, skip viewport update.");return}Ve.debug2("Setting viewport",e,n),t.setViewport(e,n,a)},[a,t,e,n]);var m=c.useCallback(v=>{var{detail:y}=v;if(!a){Ve.error("Columns not initialized.");return}var x=a.map(w=>y.rows.map(j=>j.get(w)));l(x)},[a]),g=c.useCallback(()=>{h(new Uy("Table disconnected"))},[]),P=c.useCallback(()=>{h(null)},[]);return Ke(t,i.Table.EVENT_UPDATED,m),Ke(t,i.Table.EVENT_DISCONNECT,g),Ke(t,i.Table.EVENT_RECONNECT,P),{columns:a,data:s,error:p??d}},lo=(t,e,n,r)=>{var i=c.useMemo(()=>[r],[r]),{columns:a=[],data:o=[],error:s}=so(t,e,n,i);return{column:a[0],data:o[0],error:s}};function br(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function By(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){br(a,r,i,o,s,"next",l)}function s(l){br(a,r,i,o,s,"throw",l)}o(void 0)})}}var re=W.module("TableInput"),ht=250;function Wy(t){var e,n,{className:r=void 0,columnName:i,settings:a,defaultValue:o=[],isInvalid:s=!1,onChange:l=ne,onBlur:d=ne,table:f}=t,p=c.useRef(null),h=ye(),m=c.useMemo(()=>{var O=Ct.getColumnFormats(a),T=Ct.getDateTimeFormatterOptions(a),{defaultDecimalFormatOptions:_={},defaultIntegerFormatOptions:M={}}=a;return new en(h,O,T,_,M)},[h,a]),[g,P]=c.useState(""),[v,y]=c.useState(new Set(o)),[x,w]=c.useState(),j=c.useRef(null),b=Math.min((e=x==null?void 0:x.size)!==null&&e!==void 0?e:0,ht),{column:S,data:I,error:k}=lo(x,0,ht-1,i),L=c.useCallback(O=>S?m.getFormattedString(O,S.type,S.name):"".concat(O),[S,m]),[F,H]=c.useMemo(()=>{var O=new Set(v),T=[];if(I==null)return[T,null];if(I.forEach(M=>{var J="".concat(M),Ee=v.has(J);Ee&&O.delete(J),T.push({value:J,displayValue:L(M),isSelected:Ee})}),O.size>0){re.debug2("Selection has items that are missing from the viewport");var _=new Set(v);return Array.from(O).forEach(M=>{_.delete(M)}),[T,_]}return[T,null]},[I,v,L]);c.useEffect(()=>{H!==null&&(y(H),l(Array.from(H)))},[l,H]);var E=c.useCallback(function(){var O=By(function*(T){try{var _=yield T;re.debug("Table resolved",_),w(_)}catch(M){if(me.isCanceled(M))return;re.error(M)}});return function(T){return O.apply(this,arguments)}}(),[]);c.useEffect(()=>{var O=me.makeCancelable(f);return E(O),()=>{re.debug2("Cancel table promise"),O.cancel()}},[f,E]);var A=c.useCallback(O=>{var{value:T}=O.target;P(T);var _=F.findIndex(J=>J.displayValue.includes(T));if(_>-1){var M;re.debug2("Found ".concat(T," at index ").concat(_)),(M=j.current)===null||M===void 0||M.scrollIntoView(_)}else re.debug2("".concat(T," not found"))},[F,j]),R=c.useCallback(O=>{if(re.debug("handleSelect",O),O>=F.length){re.error("Invalid index",O);return}var T=F[O].value,_=new Set(v);F[O].isSelected?_.delete(T):_.add(T),y(_),l(Array.from(_))},[l,F,v]),B=c.useCallback(()=>{var O=F.map(_=>_.value),T=new Set(O);y(T),l(O)},[F,l]),Q=c.useCallback(()=>{y(new Set),l([])},[l]),Z=c.useCallback(()=>{},[]),C=c.useCallback(O=>{var T,{relatedTarget:_}=O;re.debug("handleChildBlur",_,_ instanceof HTMLElement,p.current,(T=p.current)===null||T===void 0?void 0:T.contains(_)),(!_||p.current&&_ instanceof HTMLElement&&!p.current.contains(_))&&d()},[d]),D=F.length===0;return u.jsxs("div",{ref:p,className:N("table-input-container d-flex flex-column position-relative",r),children:[u.jsx(Xt,{disabled:!!k||D,value:g,placeholder:"Search",onChange:A,className:"mb-2 d-flex",onBlur:C}),u.jsx(ca,{className:"table-input-list",disabled:x===void 0||D,isInvalid:s,items:D?[{value:"Empty",isSelected:!1}]:F,itemCount:b,offset:0,onSelect:R,onViewportChange:Z,ref:j,onBlur:C}),x&&u.jsxs("div",{className:"meta-row",children:[u.jsx("div",{className:"d-flex align-items-center text-muted small",children:x!=null&&x.size>b&&u.jsxs(u.Fragment,{children:["Table is too large, showing the first ",ht," items."]})}),u.jsxs("div",{children:[u.jsx("button",{type:"button",className:"btn btn-link",onBlur:C,onClick:B,children:"Select All"}),u.jsx("button",{type:"button",className:"btn btn-link mr-a",onBlur:C,onClick:Q,children:"Clear"})]})]}),x==null||k&&u.jsx("div",{className:"h-100 w-100 position-absolute",children:u.jsx(ge,{isLoaded:x!=null,isLoading:x==null&&k==null,errorMessage:(n=k==null?void 0:k.message)!==null&&n!==void 0?n:null,"data-testid":"table-input-loading"})})]})}var Hy=["onInputChange","onSearchTextChange"];function Pr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function xr(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Pr(Object(n),!0).forEach(function(r){Vy(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Pr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Vy(t,e,n){return(e=Gy(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Gy(t){var e=Yy(t,"string");return typeof e=="symbol"?e:e+""}function Yy(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Ky(t,e){if(t==null)return{};var n,r,i=zy(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function zy(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function qy(t){var e=Ef(t),{onInputChange:n,onSearchTextChange:r}=e,i=Ky(e,Hy),a=c.useRef(!1),o=c.useRef(""),s=c.useCallback(d=>{n==null||n(d),a.current?r(d):(r(""),o.current=d)},[n,r]),l=c.useCallback((d,f)=>{var p;(p=i.onOpenChange)===null||p===void 0||p.call(i,d),d?f==="input"&&r(o.current):r(""),a.current=d},[r,i]);return u.jsx(Da,xr(xr({},i),{},{onInputChange:s,onOpenChange:l}))}var Xy=["table","keyColumn","labelColumn","iconColumn","settings"];function wr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Or(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?wr(Object(n),!0).forEach(function(r){Qy(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):wr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Qy(t,e,n){return(e=Jy(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Jy(t){var e=Zy(t,"string");return typeof e=="symbol"?e:e+""}function Zy(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function ev(t,e){if(t==null)return{};var n,r,i=tv(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function tv(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function nv(t){var e,{table:n,keyColumn:r,labelColumn:i,iconColumn:a,settings:o}=t,s=ev(t,Xy),{scale:l}=rn(),d=la[(e=s.density)!==null&&e!==void 0?e:"regular"][l],{getFormattedString:f}=pa(o),p=Cf({table:n,iconColumnName:a,keyColumnName:r,labelColumnName:i,formatValue:f}),{viewportData:h,onScroll:m}=un({reuseItemsOnTableResize:!0,table:n,itemHeight:d,deserializeRow:p});return u.jsx(Ra,Or(Or({},s),{},{normalizedItems:h.items,showItemIcons:a!=null,onScroll:m}))}function rv(t){return typeof t=="object"&&t!=null&&"equals"in t&&typeof t.equals=="function"}function iv(t){return"".concat(t)}function av(t){var{column:e,table:n,filter:r=Pi,onChange:i,selectedValue:a,disabled:o,className:s,formatValue:l=iv,maxSize:d=1e3}=t,f=ye(),[p,h]=c.useState([]);c.useEffect(()=>{if(n==null){h([]);return}var v=e??n.columns[0];n.applyFilter(r);var y=n.setViewport(0,d,[v]);return y.addEventListener(f.Table.EVENT_UPDATED,x=>{var{detail:w}=x,j=w.rows.map(b=>{var S;return(S=b.get(v))!==null&&S!==void 0?S:null});h(j)}),()=>{y.close()}},[e,f,r,d,n]);var m=c.useMemo(()=>a===void 0?[void 0,...p]:p,[a,p]),g=c.useMemo(()=>m.findIndex(v=>v===a||rv(v)&&v.equals(a)),[a,m]),P=c.useCallback(v=>{var y=parseInt(v,10);i(m[y])},[i,m]);return u.jsx(Oi,{className:s,value:g,onChange:P,disabled:o,children:m.map((v,y)=>u.jsx(ua,{value:y,children:l(v)},"".concat(y)))})}var Sr=W.module("useBroadcastChannel");function fn(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ne,e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:eo,n=c.useMemo(()=>new BroadcastChannel(e),[e]);return c.useEffect(()=>()=>{n.close()},[n]),c.useEffect(()=>{function r(i){var{data:a}=i;if(!et(a)){Sr.debug("Ignoring non-deephaven message",a);return}Sr.debug("event received",a),t(i)}return n.addEventListener("message",r),()=>{n.removeEventListener("message",r)}},[n,t]),n}function hn(t,e){var n=c.useCallback(r=>{no(r.data)?t==null||t(r.data):ro(r.data)&&(e==null||e(r.data))},[t,e]);fn(n)}function ov(t,e,n,r){var i=pe(),[a,o]=c.useState(""),{value:s}=Ne(a,n),l=c.useCallback(h=>{o(h.trim())},[]),{data:d,isLoading:f}=Se(i.doesColumnValueExist,[t,e,s,r]),p=f||a!==s?null:d;return{valueTrimmed:a,valueTrimmedDebounced:s,valueExists:p,trimAndUpdateValue:l}}var Er=W.module("useDebouncedViewportSearch"),sv=200;function lv(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:sv,r=pe(),{table:i,applyFiltersAndRefresh:a}=t,o=c.useMemo(()=>Ie(s=>{if(Er.debug("Applying debounced searchText '".concat(s,"'")),i!=null){var l=s.trim();if(l===""){a([]);return}var d=i.findColumn(e),f=r.makeFilterValue(d.type,l),p=[d.filter().contains(f)];a(p)}},n),[a,e,n,i,r]);return c.useEffect(()=>()=>{Er.debug("Cancelling debounced search function"),o.cancel()},[o]),o}var uo=300;function uv(t){var{viewportData:e,columnName:n,shouldSelectAllOnNoSelection:r,mapItemToValue:i}=t,a=pe(),o=Ea(e,i,Ki),{value:s}=Ne(o,uo),l=Oa(s,ba);return c.useMemo(()=>nn(a,n,l.selection,r,l.isInverted),[n,l,r,a])}function cv(t,e,n,r){var i=c.useRef("");return i.current=n,c.useMemo(()=>{var a=t.length>0&&t[0].item==null;return!a&&r!=null&&(i.current===""||r.toLowerCase().includes(i.current.toLowerCase()))?[{key:r,item:{[e]:r}},...t]:t},[r,e,t])}function Cr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function dv(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Cr(a,r,i,o,s,"next",l)}function s(l){Cr(a,r,i,o,s,"throw",l)}o(void 0)})}}function pv(t){var{table:e,columnName:n,defaultValue:r,itemHeight:i,topOffset:a=0,value:o}=t;return c.useCallback(dv(function*(){if(e==null||o===""||o===r)return a;var s=e.findColumn(n),l=yield e.seekRow(0,s,"String",o),d=r==null?0:1;return(l+d)*i+a}),[n,r,i,e,a,o])}function fv(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"or",n=pe(),r=c.useMemo(()=>zi(n),[n]);return c.useMemo(()=>tn(t,r,e),[t,e,r])}function hv(t){var{maybeTable:e,columnName:n,mapItemToValue:r,filterConditionFactories:i=[],trimSearchText:a=!1,timeZone:o}=t,{itemHeight:s}=da(),l=pe(),[d,f]=c.useState(""),[p,h]=c.useState(""),m=c.useCallback(O=>{h(a?O.trim():O)},[a]),g=c.useMemo(()=>a?d.trim():d,[d,a]),[P,v]=c.useState(null),[y,x]=c.useState(()=>new Map),{data:w,isLoading:j}=Se(l.doesColumnValueExist,[e,n,p,!1]),{isDebouncing:b}=Ne(p,En),S=b||j?null:w,I=c.useMemo(()=>qi(l,n,p,o),[p,n,l,o]),k=c.useMemo(()=>nn(l,n,new Set(y.keys()),!1,!0),[n,y,l]),{data:L}=Se(l.createDistinctSortedColumnTable,[e,n,"asc",...i]);fa(L);var F=un({table:L,itemHeight:s,viewportSize:Tf,viewportPadding:jf}),H=g.length>0&&F.size===0,E=y.has(g),A=ke(m,En),R=c.useCallback(O=>{f(O),A(O)},[A]),B=ke(v,0),Q=c.useCallback(O=>{if(f(""),m(""),v(O),B(null),O!=null){var T=F.viewportData.findItem(O);if(T!=null){var _=r(T);x(M=>{var J=new Map(M);return J.set(_,{value:_}),J})}}},[m,B,F.viewportData,r]),Z=c.useCallback(O=>{x(T=>{if(O.size===0)return T;var _=new Map(T);for(var M of O)_.set(M,{value:M});return _})},[]),C=c.useCallback(O=>{x(T=>{if(O==="all")return new Map;var _=new Map(T);for(var M of O)_.delete(M);return _})},[]),D=ha(F.table,I,k);return ma(F,D),c.useMemo(()=>({list:F,hasSearchTextWithZeroResults:H,searchText:d,searchTextExists:S,searchTextIsInSelectedValues:E,selectedKey:P,selectedValueMap:y,onSearchTextChange:R,onSelectKey:Q,onAddValues:Z,onRemoveValues:C}),[H,F,Z,C,R,Q,d,S,E,P,y])}function Tr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function mv(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Tr(a,r,i,o,s,"next",l)}function s(l){Tr(a,r,i,o,s,"throw",l)}o(void 0)})}}function gv(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];var i=c.useCallback(mv(function*(){var d;return(d=t==null?void 0:t.selectDistinct(t.findColumns(n)))!==null&&d!==void 0?d:null}),[t,...n]),{data:a,error:o,isError:s,isLoading:l}=Se(i,[]);return c.useEffect(()=>()=>{a==null||a.close()},[a]),{distinctTable:a,error:o,isError:s,isLoading:l}}function yv(t,e){var n=pe(),r=c.useMemo(()=>Xi(n,t),[t,n]);return c.useMemo(()=>tn(e,r),[e,r])}function vv(t,e,n){var r=pe();return c.useMemo(()=>Qi(r,t,e,n),[t,n,r,e])}const bv=Object.freeze(Object.defineProperty({__proto__:null,ComboBox:qy,DEBOUNCE_MS:uo,ListView:nv,Picker:If,TableDropdown:av,TableInput:Wy,makeApiContextWrapper:Oy,useBroadcastChannel:fn,useBroadcastLoginListener:hn,useCheckIfExistsValue:ov,useDebouncedViewportSearch:lv,useDebouncedViewportSelectionFilter:uv,useFilterConditionFactories:ha,useFilteredItemsWithDefaultValue:cv,useFormatter:pa,useGetItemIndexByValue:kf,useGetItemPosition:pv,useInitializeViewportData:_f,useNotNullOrEmptyFilter:fv,usePickerWithSelectedValues:hv,useSearchableViewportData:Df,useSelectDistinctTable:gv,useSetPaddedViewportCallback:Rf,useShowOnlyEmptyFilter:yv,useTable:so,useTableClose:Lf,useTableColumn:lo,useTableListener:Ke,useTableSize:Af,useTableUtils:pe,useValueFilter:vv,useViewportData:un,useViewportFilter:ma,useWidgetClose:fa},Symbol.toStringTag,{value:"Module"}));var mn=c.createContext(!1);mn.displayName="FontsLoadedContext";function Pv(t){var{fontClassNames:e=["fira-sans-regular","fira-sans-semibold","fira-mono"],children:n}=t,[r,i]=c.useState(!1);return c.useEffect(function(){document.fonts.ready.then(()=>{i(!0)})},[]),u.jsxs(u.Fragment,{children:[u.jsx(mn.Provider,{value:r,children:n}),u.jsx("div",{id:"preload-fonts",style:{visibility:"hidden",position:"absolute",top:-1e4},children:e.map(a=>u.jsx("p",{className:a,children:"preload"},a))})]})}function co(t){var{isEnabled:e,isPending:n,themeData:r}=_a();return c.useMemo(()=>e?n?null:r?[r]:[]:t==null?null:Ii(t),[e,n,r,t])}function xv(t){var{fetch:e,type:n}=t,r=Qt(),i=c.useMemo(()=>[...r.values()].filter(ki).find(o=>[o.supportedTypes].flat().includes(n)),[r,n]);if(i!=null){var a=i.component;return u.jsx(a,{fetch:e})}throw new Error("Unknown widget type '".concat(n,"'"))}function wv(){var t=Qt(),e=c.useMemo(()=>_i(t),[t]);return e}const Ov=Object.freeze(Object.defineProperty({__proto__:null,PersistentStateContext:Wu,PersistentStateProvider:Hu,PluginType:Di,PluginsContext:st,WidgetView:xv,getDashboardPlugins:au,getIconForPlugin:Vu,getPluginsElementMap:_i,getThemeDataFromPlugins:Ii,isAuthPlugin:Ri,isDashboardPlugin:Gu,isElementPlugin:Yu,isLegacyAuthPlugin:St,isLegacyDashboardPlugin:Ku,isLegacyPlugin:Li,isLegacyTablePlugin:zu,isPlugin:Et,isTablePlugin:qu,isThemePlugin:Xu,isWidgetPlugin:ki,pluginSupportsType:Qu,useCustomThemes:co,useDashboardPlugins:ou,usePersistentState:Hd,usePlugins:Qt,usePluginsElementMap:wv},Symbol.toStringTag,{value:"Module"}));function Sv(t){if(t==null)return!1;var e=t;return e.Component!==void 0&&typeof e.isAvailable=="function"}var po="io.deephaven.auth.AnonymousAuthenticationHandler",Ev="io.deephaven.authentication.psk.PskAuthenticationHandler";function jr(t,e,n){return(e=Cv(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Cv(t){var e=Tv(t,"string");return typeof e=="symbol"?e:e+""}function Tv(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class fo extends Error{constructor(){super(...arguments),jr(this,"name","AuthenticationError"),jr(this,"isAuthenticationError",!0)}}function Ir(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function jv(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Ir(a,r,i,o,s,"next",l)}function s(l){Ir(a,r,i,o,s,"throw",l)}o(void 0)})}}var kr=W.module("AuthPluginBase");function gn(t){var{children:e,getLoginOptions:n}=t,r=Ae(),[i,a]=c.useState(),[o,s]=c.useState(!1);return c.useEffect(()=>{var l=!1;function d(){if(l)throw new Ai("Login canceled.")}function f(){return p.apply(this,arguments)}function p(){return p=jv(function*(){try{var h=yield n();d(),kr.info("Logging in..."),yield r.login(h),d(),s(!0)}catch(P){if(!l){var m;kr.error("Unable to login:",P);var g=(m=_e(P))!==null&&m!==void 0?m:"Unable to login. Verify credentials.";a(new fo(g)),s(!1)}}}),p.apply(this,arguments)}return f(),()=>{l=!0}},[r,n]),o?u.jsx(u.Fragment,{children:e}):u.jsx(ge,{"data-testid":"auth-base-loading",isLoading:i==null,isLoaded:!1,errorMessage:_e(i)})}var Iv={canLogout:!1};function kv(t){var{children:e}=t,n=ye(),r=c.useCallback(()=>({type:n.CoreClient.LOGIN_TYPE_ANONYMOUS}),[n]);return u.jsx(gn,{getLoginOptions:r,children:u.jsx(nt.Provider,{value:Iv,children:e})})}var ho={Component:kv,isAvailable:t=>t.includes(po)};function _r(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function _v(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){_r(a,r,i,o,s,"next",l)}function s(l){_r(a,r,i,o,s,"throw",l)}o(void 0)})}}var Dv=W.module("AuthPluginParent"),Rv={canLogout:!1};function Lv(t){return t!=null&&typeof t.type=="string"}function Av(){return Lt.apply(this,arguments)}function Lt(){return Lt=_v(function*(){Dv.info("Logging in by delegating to parent window...");var t=yield qt(Ja);if(!Lv(t))throw new Error("Unexpected login options response: ".concat(t));return t}),Lt.apply(this,arguments)}function Fv(){var t;return(t=new URLSearchParams(window.location.search).get("authProvider"))!==null&&t!==void 0?t:""}function Nv(t){var{children:e}=t;return u.jsx(gn,{getLoginOptions:Av,children:u.jsx(nt.Provider,{value:Rv,children:e})})}var mo={Component:Nv,isAvailable:()=>Gt()!=null&&Fv()==="parent"};function go(t){var{children:e,errorMessage:n,isLoggingIn:r=!1,onSubmit:i}=t;return u.jsxs("form",{className:"login-form",onSubmit:a=>{a.preventDefault(),a.stopPropagation(),i==null||i(a)},children:[u.jsx("div",{className:"flex-spacer"}),u.jsxs("div",{className:"flex-wrapper",children:[u.jsx("fieldset",{disabled:r,className:"container-fluid",children:e}),u.jsx("div",{className:"form-group d-flex justify-content-end align-items-center mb-0",children:u.jsxs("button",{type:"submit",className:N("btn btn-primary",{"btn-spinner":r},{"btn-cancelable":r}),"data-testid":"btn-login",children:[r&&u.jsxs("span",{children:[u.jsx(Je,{className:"mr-2 loading-spinner-vertical-align"}),u.jsx("span",{className:"btn-normal-content",children:"Logging in"}),u.jsx("span",{className:"btn-hover-content",children:"Cancel"})]}),!r&&"Login"]})})]}),u.jsx("div",{className:"flex-spacer",children:n!=null&&u.jsx("p",{className:"error-message mb-0",role:"alert",children:"".concat(n)})})]})}function yo(t){var{children:e,logoPath:n="./logo.png"}=t;return u.jsxs("div",{className:"login-container",children:[u.jsx(Ya,{}),u.jsxs("div",{className:"login-box",children:[u.jsx("div",{className:"logo",children:u.jsx("img",{src:n,alt:"Deephaven Data Labs"})}),e,u.jsxs("p",{className:"footer",children:["© 2016-",new Date().getFullYear()," Deephaven Data Labs LLC. Patent Pending."]})]})]})}function Dr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function mt(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Dr(a,r,i,o,s,"next",l)}function s(l){Dr(a,r,i,o,s,"throw",l)}o(void 0)})}}var At="io.deephaven.authentication.psk.PskAuthenticationHandler",vo="psk",Ft="io.deephaven.web.client.auth.psk.token",Pe=W.module("AuthPluginPsk");function Mv(){return new URLSearchParams(window.location.search).get(vo)}function $v(){Pe.debug2("clearWindowToken");var t=new URL(window.location.href);t.searchParams.delete(vo),window.history.replaceState(null,"",t.href)}function Rr(){var t;return(t=Pt.get(Ft))!==null&&t!==void 0?t:null}function gt(t){Pe.debug2("Storing token in cookie",t),t!=null?Pt.set(Ft,t,{secure:!0,sameSite:"strict"}):Pt.remove(Ft)}function Uv(t){var{children:e,logoPath:n}=t,r=Ae(),i=c.useRef(null),a=c.useRef(null),[o,s]=c.useState(),[l,d]=c.useState(!1),[f,p]=c.useState(!1),[h,m]=c.useState(!1),[g,P]=c.useState(""),v=c.useCallback(function(){var b=mt(function*(S){var I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;Pe.info("Logging in..."),m(!0);var k=null;try{if(k=r.login({type:At,token:S}),a.current=k,yield k,Pe.info("Logged in successfully"),a.current!==k)return;gt(S),p(!0)}catch(H){if(a.current!==k)return;if(d(!0),I){var L;Pe.error("Unable to login",H);var F=(L=_e(H))!==null&&L!==void 0?L:"Unable to login: Verify credentials.";s(new fo(F))}}m(!1)});return function(S){return b.apply(this,arguments)}}(),[r]),y=c.useCallback(()=>{a.current=null,m(!1)},[]),x=c.useCallback(mt(function*(){Pe.debug("onLogin");var b=Rr();f||h||b==null||v(b,!1)}),[f,h,v]),w=c.useCallback(()=>{gt(null)},[]);hn(x,w),c.useEffect(()=>{var b=!1;function S(){return I.apply(this,arguments)}function I(){return I=mt(function*(){var k,L=(k=Mv())!==null&&k!==void 0?k:Rr();if($v(),L==null){d(!0);return}m(!0);try{yield r.login({type:At,token:L}),b||(gt(L),p(!0),m(!1))}catch{b||(d(!0),m(!1))}}),I.apply(this,arguments)}return S(),()=>{b=!0}},[r]);var j=c.useCallback(()=>{h?y():v(g)},[y,h,v,g]);return c.useEffect(function(){var S;(S=i.current)===null||S===void 0||S.focus()},[i,l]),u.jsxs(u.Fragment,{children:[f&&e,l&&u.jsx(Jt,{in:!f,mountOnEnter:!0,unmountOnExit:!0,children:u.jsx(yo,{logoPath:n,children:u.jsx(go,{errorMessage:_e(o),isLoggingIn:h,onSubmit:j,children:u.jsxs("div",{className:"form-group",children:[u.jsx("label",{htmlFor:"auth-psk-token-input",children:"Token"}),u.jsx("input",{id:"auth-psk-token-input",name:"token",className:"input-token form-control",type:"text",autoComplete:"username",autoCapitalize:"none",autoCorrect:"off",spellCheck:"false",ref:i,value:g,onChange:b=>{s(void 0),P(b.target.value)}})]})})})}),u.jsx(ge,{"data-testid":"auth-psk-loading",isLoaded:f||l,isLoading:!f&&!l})]})}var bo={Component:Uv,isAvailable:t=>t.includes(At)};function Lr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function yt(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Lr(Object(n),!0).forEach(function(r){Bv(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Lr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Bv(t,e,n){return(e=Wv(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Wv(t){var e=Hv(t,"string");return typeof e=="symbol"?e:e+""}function Hv(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Vv=W.module("UserUtils");function Po(t,e){return t.get("internal.webClient.appInit.".concat(e))}function xo(t){var e,n,r,i,a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};function s(v){return Po(t,v)}function l(v,y){var x=s(v);return x==="true"?!0:x==="false"?!1:(x!==void 0&&Vv.warn("Unexpected value for ".concat(v,": ").concat(x)),y)}var d=(e=s("name"))!==null&&e!==void 0?e:"",f=(n=s("operateAs"))!==null&&n!==void 0?n:d,p=(r=(i=s("groups"))===null||i===void 0?void 0:i.split(","))!==null&&r!==void 0?r:[],h=l("canCopy",!0),m=l("canDownloadCsv",!0),g=l("canUsePanels",!0),P=l("canLogout",!0);return yt(yt({name:d,operateAs:f,groups:p},a),{},{permissions:yt({canUsePanels:g,canCopy:h,canDownloadCsv:m,canLogout:P},o)})}const Gv=Object.freeze(Object.defineProperty({__proto__:null,AUTH_HANDLER_TYPE_ANONYMOUS:po,AUTH_HANDLER_TYPE_PSK:Ev,AuthPluginAnonymous:ho,AuthPluginBase:gn,AuthPluginParent:mo,AuthPluginPsk:bo,Login:yo,LoginForm:go,UserContext:gi,UserOverrideContext:yi,UserPermissionsOverrideContext:nt,getAppInitValue:Po,getUserFromConfig:xo,isAuthPlugin:Sv},Symbol.toStringTag,{value:"Module"}));function we(t,e,n){return(e=Yv(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Yv(t){var e=Kv(t,"string");return typeof e=="symbol"?e:e+""}function Kv(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class $ extends Ji{static get theme(){return $._theme==null&&($._theme=Fi()),$._theme}static makeRandomSeries(e){for(var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:100,i=[],a=[],o=[],s=[],l=new Date("2018-06-01"),d=0;d<r;d+=1){var f=new Date(l.getFullYear(),l.getMonth(),l.getDate()+d-r);i.push("".concat(f.getFullYear(),"-").concat(f.getMonth()+1,"-").concat(f.getDate()));var p=(Math.sin(d/r*e)*r/3+Math.cos(d*.2)*r/6+Math.sin(d*.5)*r/10+$.random()*r/5+d*$.smoothing)*n;p=Math.round(p*100)/100,a.push(p),s.push(40+d*$.smoothing),o.push(Math.sin(d/r*e)*r/3+$.random()*r/10+d*$.smoothing)}return{x:i,y:a,s:o,l:s}}static makeScatter(e){return{name:"SCTR",x:e.x,y:e.y,type:"scatter",mode:"markers",hoverinfo:"skip",marker:{size:5}}}static makeArea(e){return{name:"AREA",x:e.x,y:e.s,type:"scatter",mode:"line",fill:"tozeroy",hoverinfo:"all",line:{width:3}}}static makeTrendline(e){return{name:"Trendline <br>R<sup>2</sup> = 0.91",x:e.x,y:e.l,type:"scatter",mode:"line",hoverinfo:"skip",line:{width:3,dash:"dot"}}}static makeErrorBand(e){for(var n=[],r=[],i=0;i<e.y.length;i+=1){var a=e.y[i];n[i]=Math.round((a+18)*100)/100,r[i]=Math.round((a-18)*100)/100}var o=n.concat(r.reverse());return{name:"error",x:e.x.concat(e.x.slice().reverse()),y:o,type:"scatter",mode:"line",hoverinfo:"skip",fill:"toself",line:{width:0,color:$.theme.error_band_line_color,shape:"spline"}}}static makeLine(e){return{name:"LINE",x:e.x,y:e.y,type:"scatter",mode:"line",hoverinfo:"x+y+text+name",line:{width:3}}}static makeRandomData(){var e=$.makeRandomSeries(6),n=$.makeArea(e),r=$.makeTrendline(e),i=$.makeRandomSeries(2),a=$.makeLine(i),o=$.makeErrorBand(i);return[n,r,a,o]}static makeDefaultLayout(e){var n={template:new Zi(e).makeDefaultTemplate($.theme)};return n.title={text:"Chart"},n.xaxis={title:{text:"Datestamp"}},n.yaxis={title:{text:"Price"}},n}constructor(e){var{data:n=$.makeRandomData(),layout:r=$.makeDefaultLayout(e),filterFields:i=[]}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};super(e),we(this,"data",void 0),we(this,"filterFields",void 0),we(this,"layout",void 0),this.data=n,this.layout=r,this.filterFields=i}getData(){return this.data}getLayout(){return this.layout}getFilterColumnMap(){for(var e=new Map,n=0;n<this.filterFields.length;n+=1){var r=this.filterFields[n],i="java.lang.String";e.set(r,{name:r,type:i})}return e}isFilterRequired(){return this.filterFields.length>0}setFilter(){this.fireUpdate(this.data)}}we($,"random",Math.random.bind(Math));we($,"smoothing",1.5);we($,"_theme",void 0);const zv=Object.freeze(Object.defineProperty({__proto__:null,Chart:Vd,ChartModel:Ji,ChartModelFactory:Gd,ChartThemeContext:Ju,ChartThemeProvider:Ni,ChartUtils:Zi,DownsamplingError:Op,FigureChartModel:Yd,MockChartModel:$,Plot:Zu,defaultChartTheme:Fi,isFigureChartModel:Kd,isWebGLSupported:zd,useChartTheme:ec},Symbol.toStringTag,{value:"Module"}));function qv(t){var{dashboardProps:e,componentName:n,component:r,supportedTypes:i,hydrate:a,dehydrate:o}=t,{id:s,layout:l,registerComponent:d}=e,f=c.useCallback(p=>{var{dragEvent:h,panelId:m=Bt(),widget:g}=p,{name:P,type:v}=g,y=v!=null&&(Array.isArray(i)&&i.includes(v)||v===i);if(y){var x={localDashboardId:s,metadata:g};a!=null&&(x=a(x,s));var w={type:"react-component",component:n,props:x,title:P??void 0,id:m},{root:j}=l;Mi.openComponent({root:j,config:w,dragEvent:h})}},[n,a,s,l,i]);ea(d,r,a,o),$i(l.eventHub,f)}function Xv(t,e){var n=Bs(),r=Ws(a=>Ui(a,t,e)),i=c.useCallback(a=>n(Bi(t,e,a)),[t,e,n]);return[r,i]}const Qv=Object.freeze(Object.defineProperty({__proto__:null,BasePanel:wn,CLOSE_DASHBOARD:tc,CREATE_DASHBOARD:nc,DEFAULT_DASHBOARD_ID:rc,DH_ID_PROP:ic,Dashboard:Pn,DashboardIdContext:ac,DashboardLayout:oc,DashboardUtils:sc,GLPropTypes:lc,LayoutManagerContext:uc,LayoutUtils:Mi,LazyDashboard:su,Panel:wn,PanelErrorBoundary:cc,PanelEvent:dc,PanelIdContext:pc,PanelManager:fc,SET_DASHBOARD_DATA:hc,TabEvent:mc,assertIsDashboardPluginProps:qd,canHaveRef:Ei,default:Pn,dehydrate:gc,emitCloseDashboard:yc,emitCreateDashboard:vc,emitCycleToNextStack:bc,emitCycleToNextTab:Pc,emitCycleToPreviousStack:xc,emitCycleToPreviousTab:wc,emitPanelOpen:Oc,getAllDashboardsData:Sc,getClosedPanelsForDashboard:Ec,getDashboardData:Cc,getOpenedPanelMapForDashboard:Tc,getPluginDataForDashboard:Ui,getPluginDataMapForDashboard:jc,hydrate:Ic,isDashboardPluginProps:Xd,isWrappedComponent:Ci,listenForCloseDashboard:kc,listenForCreateDashboard:_c,listenForCycleToNextStack:Dc,listenForCycleToNextTab:Rc,listenForCycleToPreviousStack:Lc,listenForCycleToPreviousTab:Ac,listenForPanelOpen:Fc,reducers:Nc,setDashboardData:Mc,setDashboardPluginData:Bi,updateDashboardData:$c,useAppDispatch:Uc,useAppSelector:Wi,useAppStore:Bc,useCloseDashboardListener:Wc,useCreateDashboardListener:Hc,useCycleToNextStackListener:Vc,useCycleToNextTabListener:Gc,useCycleToPreviousStackListener:Yc,useCycleToPreviousTabListener:Kc,useDashboardId:zc,useDashboardPanel:qv,useDashboardPluginData:Xv,useDhId:qc,useLayoutManager:Qd,useListener:Xc,usePanelId:Qc,usePanelOpenListener:$i,usePanelRegistration:ea},Symbol.toStringTag,{value:"Module"}));function wo(t){var{children:e}=t,{activeThemes:n}=rt();return c.useEffect(function(){n!=null&&Hi.initTheme()},[n]),u.jsx(u.Fragment,{children:e})}var Jv={$schema:"http://json-schema.org/draft-07/schema#",title:"Options",type:"object",properties:{"allowed-confusables":{description:'A list of allowed "confusable" Unicode characters to ignore when enforcing `RUF001`, `RUF002`, and `RUF003`.',deprecated:!0,type:["array","null"],items:{type:"string",maxLength:1,minLength:1}},builtins:{description:"A list of builtins to treat as defined references, in addition to the system builtins.",type:["array","null"],items:{type:"string"}},"cache-dir":{description:"A path to the cache directory.\n\nBy default, Ruff stores cache results in a `.ruff_cache` directory in the current project root.\n\nHowever, Ruff will also respect the `RUFF_CACHE_DIR` environment variable, which takes precedence over that default.\n\nThis setting will override even the `RUFF_CACHE_DIR` environment variable, if set.",type:["string","null"]},"dummy-variable-rgx":{description:'A regular expression used to identify "dummy" variables, or those which should be ignored when enforcing (e.g.) unused-variable rules. The default expression matches `_`, `__`, and `_var`, but not `_var_`.',deprecated:!0,type:["string","null"]},exclude:{description:"A list of file patterns to exclude from formatting and linting.\n\nExclusions are based on globs, and can be either:\n\n- Single-path patterns, like `.mypy_cache` (to exclude any directory named `.mypy_cache` in the tree), `foo.py` (to exclude any file named `foo.py`), or `foo_*.py` (to exclude any file matching `foo_*.py` ). - Relative patterns, like `directory/foo.py` (to exclude that specific file) or `directory/*.py` (to exclude any Python files in `directory`). Note that these paths are relative to the project root (e.g., the directory containing your `pyproject.toml`).\n\nFor more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).\n\nNote that you'll typically want to use [`extend-exclude`](#extend-exclude) to modify the excluded paths.",type:["array","null"],items:{type:"string"}},"explicit-preview-rules":{description:"Whether to require exact codes to select preview rules. When enabled, preview rules will not be selected by prefixes — the full code of each preview rule will be required to enable the rule.",deprecated:!0,type:["boolean","null"]},extend:{description:"A path to a local `pyproject.toml` file to merge into this configuration. User home directory and environment variables will be expanded.\n\nTo resolve the current `pyproject.toml` file, Ruff will first resolve this base configuration file, then merge in any properties defined in the current configuration file.",type:["string","null"]},"extend-exclude":{description:"A list of file patterns to omit from formatting and linting, in addition to those specified by [`exclude`](#exclude).\n\nExclusions are based on globs, and can be either:\n\n- Single-path patterns, like `.mypy_cache` (to exclude any directory named `.mypy_cache` in the tree), `foo.py` (to exclude any file named `foo.py`), or `foo_*.py` (to exclude any file matching `foo_*.py` ). - Relative patterns, like `directory/foo.py` (to exclude that specific file) or `directory/*.py` (to exclude any Python files in `directory`). Note that these paths are relative to the project root (e.g., the directory containing your `pyproject.toml`).\n\nFor more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).",type:["array","null"],items:{type:"string"}},"extend-fixable":{description:"A list of rule codes or prefixes to consider fixable, in addition to those specified by [`fixable`](#lint_fixable).",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-ignore":{description:"A list of rule codes or prefixes to ignore, in addition to those specified by `ignore`.",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-include":{description:"A list of file patterns to include when linting, in addition to those specified by [`include`](#include).\n\nInclusion are based on globs, and should be single-path patterns, like `*.pyw`, to include any file with the `.pyw` extension.\n\nFor more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).",type:["array","null"],items:{type:"string"}},"extend-per-file-ignores":{description:"A list of mappings from file pattern to rule codes or prefixes to exclude, in addition to any rules excluded by [`per-file-ignores`](#lint_per-file-ignores).",deprecated:!0,type:["object","null"],additionalProperties:{type:"array",items:{$ref:"#/definitions/RuleSelector"}}},"extend-safe-fixes":{description:"A list of rule codes or prefixes for which unsafe fixes should be considered safe.",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-select":{description:"A list of rule codes or prefixes to enable, in addition to those specified by [`select`](#lint_select).",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-unfixable":{description:"A list of rule codes or prefixes to consider non-auto-fixable, in addition to those specified by [`unfixable`](#lint_unfixable).",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-unsafe-fixes":{description:"A list of rule codes or prefixes for which safe fixes should be considered unsafe.",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},external:{description:"A list of rule codes or prefixes that are unsupported by Ruff, but should be preserved when (e.g.) validating `# noqa` directives. Useful for retaining `# noqa` directives that cover plugins not yet implemented by Ruff.",deprecated:!0,type:["array","null"],items:{type:"string"}},fix:{description:"Enable fix behavior by-default when running `ruff` (overridden by the `--fix` and `--no-fix` command-line flags). Only includes automatic fixes unless `--unsafe-fixes` is provided.",type:["boolean","null"]},"fix-only":{description:"Like [`fix`](#fix), but disables reporting on leftover violation. Implies [`fix`](#fix).",type:["boolean","null"]},fixable:{description:"A list of rule codes or prefixes to consider fixable. By default, all rules are considered fixable.",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"flake8-annotations":{description:"Options for the `flake8-annotations` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8AnnotationsOptions"},{type:"null"}]},"flake8-bandit":{description:"Options for the `flake8-bandit` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8BanditOptions"},{type:"null"}]},"flake8-boolean-trap":{description:"Options for the `flake8-boolean-trap` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8BooleanTrapOptions"},{type:"null"}]},"flake8-bugbear":{description:"Options for the `flake8-bugbear` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8BugbearOptions"},{type:"null"}]},"flake8-builtins":{description:"Options for the `flake8-builtins` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8BuiltinsOptions"},{type:"null"}]},"flake8-comprehensions":{description:"Options for the `flake8-comprehensions` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8ComprehensionsOptions"},{type:"null"}]},"flake8-copyright":{description:"Options for the `flake8-copyright` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8CopyrightOptions"},{type:"null"}]},"flake8-errmsg":{description:"Options for the `flake8-errmsg` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8ErrMsgOptions"},{type:"null"}]},"flake8-gettext":{description:"Options for the `flake8-gettext` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8GetTextOptions"},{type:"null"}]},"flake8-implicit-str-concat":{description:"Options for the `flake8-implicit-str-concat` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8ImplicitStrConcatOptions"},{type:"null"}]},"flake8-import-conventions":{description:"Options for the `flake8-import-conventions` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8ImportConventionsOptions"},{type:"null"}]},"flake8-pytest-style":{description:"Options for the `flake8-pytest-style` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8PytestStyleOptions"},{type:"null"}]},"flake8-quotes":{description:"Options for the `flake8-quotes` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8QuotesOptions"},{type:"null"}]},"flake8-self":{description:"Options for the `flake8_self` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8SelfOptions"},{type:"null"}]},"flake8-tidy-imports":{description:"Options for the `flake8-tidy-imports` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8TidyImportsOptions"},{type:"null"}]},"flake8-type-checking":{description:"Options for the `flake8-type-checking` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8TypeCheckingOptions"},{type:"null"}]},"flake8-unused-arguments":{description:"Options for the `flake8-unused-arguments` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8UnusedArgumentsOptions"},{type:"null"}]},"force-exclude":{description:"Whether to enforce [`exclude`](#exclude) and [`extend-exclude`](#extend-exclude) patterns, even for paths that are passed to Ruff explicitly. Typically, Ruff will lint any paths passed in directly, even if they would typically be excluded. Setting `force-exclude = true` will cause Ruff to respect these exclusions unequivocally.\n\nThis is useful for [`pre-commit`](https://pre-commit.com/), which explicitly passes all changed files to the [`ruff-pre-commit`](https://github.com/astral-sh/ruff-pre-commit) plugin, regardless of whether they're marked as excluded by Ruff's own settings.",type:["boolean","null"]},format:{description:"Options to configure code formatting.",anyOf:[{$ref:"#/definitions/FormatOptions"},{type:"null"}]},ignore:{description:"A list of rule codes or prefixes to ignore. Prefixes can specify exact rules (like `F841`), entire categories (like `F`), or anything in between.\n\nWhen breaking ties between enabled and disabled rules (via `select` and `ignore`, respectively), more specific prefixes override less specific prefixes.",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"ignore-init-module-imports":{description:"Avoid automatically removing unused imports in `__init__.py` files. Such imports will still be flagged, but with a dedicated message suggesting that the import is either added to the module's `__all__` symbol, or re-exported with a redundant alias (e.g., `import os as os`).\n\nThis option is enabled by default, but you can opt-in to removal of imports via an unsafe fix.",deprecated:!0,type:["boolean","null"]},include:{description:"A list of file patterns to include when linting.\n\nInclusion are based on globs, and should be single-path patterns, like `*.pyw`, to include any file with the `.pyw` extension. `pyproject.toml` is included here not for configuration but because we lint whether e.g. the `[project]` matches the schema.\n\nNotebook files (`.ipynb` extension) are included by default on Ruff 0.6.0+.\n\nFor more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).",type:["array","null"],items:{type:"string"}},"indent-width":{description:`The number of spaces per indentation level (tab).
3
+ `).map(k=>k.trim()).join(" ")}function y(){if(g.current){g.current.style.height="0";var I=g.current.scrollHeight+(g.current.offsetHeight-g.current.clientHeight);I>0&&(g.current.style.height="".concat(I,"px"))}}function x(I){var k=I.target.value;h&&(s&&(k=P(k)),m(!1)),p(k),r(k)}function w(){g.current&&(s&&(p(P(f)),y()),g.current.scrollLeft=0)}function j(){g.current&&document.activeElement!==g.current&&g.current.focus()}function b(){s&&(p(v(f)),r(v(f)))}function S(){m(!0)}return c.useEffect(function(){y()},[f]),u.jsx("textarea",{ref:g,id:l,className:N(e,"auto-resize-textarea form-control"),placeholder:a,value:f,rows:1,onChange:x,onFocus:w,onMouseDown:j,onBlur:b,onPaste:S,spellCheck:i,disabled:o,"data-testid":d})}function $a(t){var{blockInteraction:e=!0,children:n,debounceMs:r,isOpen:i=!1}=t,{value:a}=Ne(i,r);return u.jsxs(u.Fragment,{children:[e&&i&&u.jsx("div",{className:"modal-backdrop",style:{backgroundColor:"transparent"},"data-testid":"debounced-modal-backdrop"}),U.cloneElement(n,{isOpen:i&&a})]})}function Ua(t){var{className:e,icon:n,isOpen:r=!1,subtitle:i,title:a}=t;return u.jsx(Yt,{isOpen:r,className:e,children:u.jsx(Kt,{children:u.jsxs("div",{className:"info-modal",children:[n!=null&&u.jsx("div",{className:"message-icon",children:u.jsx(Y,{icon:n})}),u.jsx("div",{className:"message-header",children:a}),i!=null&&u.jsx("div",{className:"message-content",children:i})]})})})}function Xn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Qn(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Xn(Object(n),!0).forEach(function(r){dg(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Xn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function dg(t,e,n){return(e=pg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function pg(t){var e=fg(t,"string");return typeof e=="symbol"?e:e+""}function fg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var hg=[];function mg(t){var{styleProps:e,selectedItemCount:n,onClearSelection:r}=t;return u.jsx(Zr,Qn(Qn({UNSAFE_className:on.spectrumActionBar},e),{},{isEmphasized:!0,selectedItemCount:n,onClearSelection:r,children:hg}))}function Jn(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function gg(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Jn(Object(n),!0).forEach(function(r){oe(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Jn(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function oe(t,e,n){return(e=yg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function yg(t){var e=vg(t,"string");return typeof e=="symbol"?e:e+""}function vg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Zn=W.module("ContextMenu");class _e extends c.PureComponent{static handleContextMenu(e){e.metaKey||(e.stopPropagation(),e.preventDefault())}constructor(e){super(e),oe(this,"container",void 0),oe(this,"oldFocus",void 0),oe(this,"activeSubMenuRef",void 0),oe(this,"subMenuTimer",void 0),oe(this,"rAF",void 0),oe(this,"initialPosition",void 0),this.handleBlur=this.handleBlur.bind(this),this.handleCloseSubMenu=this.handleCloseSubMenu.bind(this),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleMenuItemClick=this.handleMenuItemClick.bind(this),this.handleMenuItemContextMenu=this.handleMenuItemContextMenu.bind(this),this.handleMenuItemMouseMove=this.handleMenuItemMouseMove.bind(this),this.handleMouseLeave=this.handleMouseLeave.bind(this),this.handleWindowResize=this.handleWindowResize.bind(this),this.container=U.createRef(),this.oldFocus=document.activeElement,this.activeSubMenuRef=U.createRef(),this.subMenuTimer=0,this.rAF=0,this.initialPosition={top:e.top,left:e.left},this.state={menuItems:[],pendingItems:[],activeSubMenu:null,hasOverflow:!1,subMenuTop:null,subMenuLeft:null,subMenuParentWidth:0,subMenuParentHeight:0,keyboardIndex:-1,mouseIndex:-1}}componentDidMount(){this.initMenu(),this.verifyPosition(),window.addEventListener("resize",this.handleWindowResize),this.rAF=window.requestAnimationFrame(()=>{var e;(e=this.container.current)===null||e===void 0||e.focus();var{onMenuOpened:n}=this.props;n(this)})}componentDidUpdate(e,n){var{actions:r}=this.props,{activeSubMenu:i}=this.state;if(i!==n.activeSubMenu)if(i==null){var a;(a=this.container.current)===null||a===void 0||a.focus()}else this.setActiveSubMenuPosition();if(e.actions!==r&&(this.initMenu(),this.container.current==null||!this.container.current.contains(document.activeElement))){var o;(o=this.container.current)===null||o===void 0||o.focus()}this.verifyPosition()}componentWillUnmount(){this.cancelPromises(),window.removeEventListener("resize",this.handleWindowResize),cancelAnimationFrame(this.rAF)}getKeyboardIndex(){var{options:e}=this.props;if(e.separateKeyboardMouse!==void 0&&e.separateKeyboardMouse){var{keyboardIndex:n}=this.state;return n}return this.getMouseIndex()}setKeyboardIndex(e){var{options:n}=this.props;n.separateKeyboardMouse!==void 0&&n.separateKeyboardMouse?this.setState({keyboardIndex:e}):this.setMouseIndex(e)}getMouseIndex(){var{mouseIndex:e}=this.state;return e}setMouseIndex(e){this.setState({mouseIndex:e})}initMenu(){this.cancelPromises(),cancelAnimationFrame(this.rAF);var{options:e}=this.props,n=e.initialKeyboardIndex;n===void 0&&(n=-1);for(var{actions:r}=this.props,i=le.getMenuItems(r),a=[],o=i.length-1;o>=0;o-=1){var s=i[o];s instanceof Promise?this.initMenuPromise(s):a.push(s)}this.setState({mouseIndex:-1,keyboardIndex:n,activeSubMenu:null,menuItems:le.sortActions(a)})}initMenuPromise(e){var n=he.makeCancelable(e);this.setState(r=>({pendingItems:r.pendingItems.concat(n)})),n.then(r=>{this.setState(i=>{var a=i.pendingItems.indexOf(n);if(a>=0){var o=i.pendingItems.slice();return o.splice(a,1),{menuItems:le.sortActions(i.menuItems.concat(r)),pendingItems:o}}return null})},r=>{he.isCanceled(r)||(this.setState(i=>{var a=i.pendingItems.indexOf(n);if(a>=0){var o=i.pendingItems.slice();return o.splice(a,1),{pendingItems:o}}return null}),Zn.error(r))})}cancelPromises(){var{pendingItems:e}=this.state;e.map(n=>n.cancel())}setActiveSubMenuPosition(){if(this.activeSubMenuRef.current!==null){var e=this.activeSubMenuRef.current.getBoundingClientRect();this.setState({subMenuTop:e.top,subMenuLeft:e.right,subMenuParentHeight:e.height,subMenuParentWidth:e.width})}}verifyPosition(){var e,n,r,i,{options:a,updatePosition:o,subMenuParentWidth:s,subMenuParentHeight:l,top:d,left:f}=this.props;if(!(!this.container.current||a.doNotVerifyPosition!=null&&a.doNotVerifyPosition)){var{top:p,left:h}=this.initialPosition,{width:m,height:g}=(e=(n=this.container.current)===null||n===void 0?void 0:n.getBoundingClientRect())!==null&&e!==void 0?e:{width:0,height:0},P=((r=(i=this.container.current)===null||i===void 0?void 0:i.scrollHeight)!==null&&r!==void 0?r:0)>window.innerHeight;g===0||m===0||(p+g>window.innerHeight&&(p-g-l>0?p-=g-l:p=window.innerHeight-g),h+m>window.innerWidth&&(h=h-m-s),(f!==h||d!==p)&&(this.setState({hasOverflow:P}),o(p,h)))}}handleWindowResize(){this.container.current&&this.closeMenu(!0)}handleBlur(e){if(!this.container.current){Zn.warn("Container is null!");return}if(!this.container.current.contains(e.relatedTarget)){for(var n=e.relatedTarget,r=!1;n&&!r;)r=n.hasAttribute("data-dh-context-menu"),n=n.parentElement;r||this.closeMenu(!0)}}isEscapeKey(e){var{left:n}=this.props;return e==="Escape"||n<0&&e==="ArrowRight"||e==="ArrowLeft"}handleKeyDown(e){var{menuItems:n}=this.state,r=this.getKeyboardIndex(),i=r,a=!1;if(e.key==="Enter"||e.key===" "){r>=0&&r<n.length&&this.handleMenuItemClick(n[r],e);return}if(e.key==="ArrowRight"?r>=0&&r<=n.length?a=!0:i=0:this.isEscapeKey(e.key)?i=null:e.key==="ArrowUp"||e.shiftKey&&e.key==="Tab"?i=le.getNextMenuItem(i,-1,n):(e.key==="ArrowDown"||e.key==="Tab")&&(i=le.getNextMenuItem(i,1,n)),a){this.openSubMenu(r),e.preventDefault(),e.stopPropagation();return}r!==i&&(i!==null?this.setKeyboardIndex(i):(this.closeMenu(),this.oldFocus instanceof HTMLElement&&this.oldFocus.focus()),e.preventDefault(),e.stopPropagation())}openSubMenu(e){var{menuItems:n,activeSubMenu:r}=this.state,i=n[e].actions?e:null;r!==i&&this.setState({activeSubMenu:i,subMenuTop:null,subMenuLeft:null})}closeMenu(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,{closeMenu:n,onMenuClosed:r}=this.props;cancelAnimationFrame(this.rAF),this.rAF=window.requestAnimationFrame(()=>{n(e),r(this)})}closeSubMenu(){this.setState({activeSubMenu:null})}handleCloseSubMenu(e){e?this.closeMenu(!0):this.closeSubMenu()}handleMenuItemClick(e,n){n.preventDefault(),n.stopPropagation();var{menuItems:r}=this.state;e!=null&&(e.disabled===void 0||!e.disabled)&&(e.actions!=null?this.openSubMenu(r.indexOf(e)):e.action!=null&&(e.action(n.nativeEvent),this.closeMenu(!0)))}handleMenuItemContextMenu(e,n){n.metaKey||this.handleMenuItemClick(e,n)}handleMenuItemMouseMove(e){var{menuItems:n}=this.state,r=n.indexOf(e);this.setMouseIndex(r),r>=0&&r<n.length&&(e.disabled===void 0||!e.disabled)&&this.openSubMenu(r)}handleMouseLeave(){this.setMouseIndex(-1)}render(){for(var e=[],{top:n,left:r}=this.props,{activeSubMenu:i,hasOverflow:a,keyboardIndex:o,menuItems:s,mouseIndex:l,pendingItems:d,subMenuTop:f,subMenuLeft:p,subMenuParentWidth:h,subMenuParentHeight:m}=this.state,g=0;g<s.length;g+=1){var P=s[g];g>0&&P.group!==s[g-1].group&&e.push(u.jsx("hr",{},"".concat(g,".separator")));var v=u.jsx(vi,{ref:i===g?this.activeSubMenuRef:null,isKeyboardSelected:o===g,isMouseSelected:l===g,menuItem:P,closeMenu:this.handleCloseSubMenu,onMenuItemClick:this.handleMenuItemClick,onMenuItemMouseMove:this.handleMenuItemMouseMove,onMenuItemContextMenu:this.handleMenuItemContextMenu},g);e.push(v)}var y=null;d.length>0&&(y=u.jsx("div",{className:"loading",children:u.jsx(Je,{className:"loading-spinner-vertical-align"})}));var{menuStyle:x,"data-testid":w}=this.props,j=i!==null&&f!==null&&p!==null;return u.jsxs(u.Fragment,{children:[u.jsxs("div",{className:N({"has-overflow":a},"context-menu-container"),style:gg({top:n,left:r},x),ref:this.container,"data-dh-context-menu":!0,onBlur:this.handleBlur,onKeyDown:this.handleKeyDown,onMouseLeave:this.handleMouseLeave,onContextMenu:_e.handleContextMenu,role:"menuitem",tabIndex:0,"data-testid":w,children:[e,y]}),j&&i!==null&&f!==null&&p!==null&&u.jsx(_e,{actions:s[i].actions||[],closeMenu:this.handleCloseSubMenu,top:f,left:p,updatePosition:(b,S)=>{this.setState({subMenuTop:b,subMenuLeft:S})},subMenuParentWidth:h,subMenuParentHeight:m},"sub-".concat(i))]})}}oe(_e,"defaultProps",{subMenuParentWidth:0,subMenuParentHeight:0,closeMenu(){},onMenuOpened(){},onMenuClosed(){},options:{},menuStyle:{},"data-testid":void 0});function er(t,e,n){return(e=bg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function bg(t){var e=Pg(t,"string");return typeof e=="symbol"?e:e+""}function Pg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class Ba extends c.Component{constructor(e){super(e),er(this,"container",void 0),er(this,"openMenu",void 0),this.handleMenuClose=this.handleMenuClose.bind(this),this.handleContextMenu=this.handleContextMenu.bind(this),this.container=U.createRef(),this.openMenu=U.createRef(),this.state={actions:null,left:0,top:0}}componentDidMount(){var e;(e=this.container.current)!==null&&e!==void 0&&e.parentElement&&this.container.current.parentElement.addEventListener("contextmenu",this.handleContextMenu)}componentWillUnmount(){var e;(e=this.container.current)!==null&&e!==void 0&&e.parentElement&&this.container.current.parentElement.removeEventListener("contextmenu",this.handleContextMenu)}handleContextMenu(e){if(this.container.current){var n=this.container.current.getBoundingClientRect(),r=e.clientY-n.top,i=e.clientX-n.left,{actions:a}=this.state;if(a!=null&&e.target===this.container.current){e.preventDefault(),this.setState({actions:null},()=>{var s=document.elementFromPoint(i,r),l=new MouseEvent("contextmenu",{clientX:e.clientX,clientY:e.clientY,bubbles:!0,cancelable:!0});s==null||s.dispatchEvent(l)});return}if(le.isContextActionEvent(e)&&!(e.metaKey||e.ctrlKey)){var o=le.getMenuItems(e.contextActions);o.length!==0&&(e.preventDefault(),this.setState({actions:o,top:r,left:i}))}}}handleMenuClose(e){e===this.openMenu.current&&this.setState({actions:null})}render(){var e=null,{"data-testid":n}=this.props,{actions:r,top:i,left:a}=this.state;return r&&(e=u.jsx(_e,{ref:this.openMenu,actions:r,onMenuClosed:this.handleMenuClose,top:i,left:a,updatePosition:(o,s)=>{this.setState({top:o,left:s})},"data-testid":n})),u.jsx("div",{className:N("context-menu-root",{active:r}),ref:this.container,children:e})}}function Wa(t,e,n){return(e=xg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function xg(t){var e=wg(t,"string");return typeof e=="symbol"?e:e+""}function wg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class Re extends c.Component{static getHeight(e){var n=e.scrollWidth-e.clientWidth;return e.scrollHeight-n}constructor(e){super(e),Wa(this,"nodeRef",U.createRef()),this.handleEntered=this.handleEntered.bind(this)}handleEntered(){var e=this.nodeRef.current;if(e){e.style.height="";var{autoFocusOnShow:n}=this.props;if(n!==void 0&&n){var r=e.querySelector("input, select, textarea");r!=null&&r.focus()}}}handleEnter(){var e=this.nodeRef.current;e&&(e.style.height="0")}handleEntering(){var e=this.nodeRef.current;e&&(e.style.height="".concat(Re.getHeight(e),"px"))}handleExiting(){var e=this.nodeRef.current;e&&(e.style.height="0")}handleExit(){var e=this.nodeRef.current;e&&(e.style.height="".concat(Re.getHeight(e),"px"))}render(){var{children:e,className:n,in:r,"data-testid":i}=this.props;return u.jsx(ei,{in:r,classNames:{enterActive:"collapsing",enterDone:"collapse show",exitActive:"collapsing",exitDone:"collapse"},onEnter:this.handleEnter,onEntering:this.handleEntering,onEntered:this.handleEntered,onExit:this.handleExit,onExiting:this.handleExiting,timeout:350,nodeRef:this.nodeRef,children:a=>u.jsx("div",{ref:this.nodeRef,className:N({collapse:a==="exited"},n),"data-testid":i,children:e})})}}Wa(Re,"defaultProps",{className:"",autoFocusOnShow:!1,"data-testid":void 0});var Og=W.module("TimeInput"),Sg="([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]",Eg=["00:00:00","12:34:56","23:59:59"];function tr(t){return t!=null?"".concat(t.substring(0,8).replace(/\u2007/g,"0")).concat("00:00:00".substring(t.length)):t}var qe=U.forwardRef((t,e)=>{var{allowValueWrapping:n=!0,className:r="",onChange:i=ne,value:a=0,onFocus:o=ne,onBlur:s=ne,onSelect:l=ne,"data-testid":d}=t,[f,p]=c.useState(Ge.formatTime(a)),h=c.useRef(a),[m,g]=c.useState(),P=c.useRef(null);c.useImperativeHandle(e,()=>({focus:()=>{var b;(b=P.current)===null||b===void 0||b.focus()},setSelection:b=>{var S;(S=P.current)===null||S===void 0||S.focus(),g(b)}}),[]),c.useEffect(function(){h.current!==a&&(p(Ge.formatTime(a)),h.current=a)},[h,a]);function v(b,S,I){var k=b.selectionStart===0?24:60,L=parseInt(I,10)-S;return Number.isNaN(L)?L=0:n?L=(L%k+k)%k:L=Math.min(Math.max(0,L),k-1),"".concat(L).padStart(2,"0")}function y(b,S,I,k,L){return k===0&&L===2&&S===1&&parseInt(I,10)>1?"0".concat(I).concat(b.substring(2)):sa(b,S,I)}var x=c.useCallback(b=>{Og.debug("handleChange",b),p(b),h.current=Ge.parseTime(tr(b)),i(h.current)},[i]),w=c.useCallback(()=>{var b=tr(f);b!==f&&p(b),s()},[f,s]),j=c.useCallback(b=>{g(b),l(b)},[l]);return u.jsx(ln,{ref:P,className:r,example:Eg,getNextSegmentValue:v,getPreferredReplacementString:y,onChange:x,onSelect:j,pattern:Sg,selection:m,value:f,onFocus:o,onBlur:w,"data-testid":d})});function nr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Cg(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?nr(Object(n),!0).forEach(function(r){ce(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):nr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function ce(t,e,n){return(e=Tg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Tg(t){var e=jg(t,"string");return typeof e=="symbol"?e:e+""}function jg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var rr=-1,Ha=function(t){return t.UP="UP",t.DOWN="DOWN",t}(Ha||{});class z extends c.Component{constructor(e){super(e),ce(this,"csContainer",void 0),ce(this,"menuContainer",void 0),ce(this,"button",void 0),ce(this,"input",void 0);var{value:n,valueToTime:r}=e;this.toggleMenu=this.toggleMenu.bind(this),this.handleMenuKeyDown=this.handleMenuKeyDown.bind(this),this.closeMenu=this.closeMenu.bind(this),this.handleOptionClick=this.handleOptionClick.bind(this),this.handleOptionFocus=this.handleOptionFocus.bind(this),this.handleMenuOpened=this.handleMenuOpened.bind(this),this.handleMenuExited=this.handleMenuExited.bind(this),this.handleCustomInput=this.handleCustomInput.bind(this),this.csContainer=U.createRef(),this.menuContainer=U.createRef(),this.button=U.createRef(),this.input=U.createRef(),this.state={keyboardOptionIndex:0,menuIsOpen:!1,inputWidth:100,customTime:r(n),inputFocused:!1}}getSelectedText(){var{options:e,value:n,placeholder:r}=this.props,{customTime:i}=this.state;if(n===null)return r;for(var a=0;a<e.length;a+=1){var o=e[a];if(o.value===n)return o.title}return Ge.formatTime(i)}setInputWidth(){this.csContainer.current&&this.setState({inputWidth:this.csContainer.current.getBoundingClientRect().width})}focus(){var e;(e=this.button.current)===null||e===void 0||e.focus()}updateInputValue(e){var{onChange:n}=this.props;n(e)}handleResize(){this.setInputWidth()}handleMenuKeyDown(e){var n,{keyboardOptionIndex:r,inputFocused:i}=this.state,{options:a}=this.props;switch(e.key){case"Enter":case" ":i?this.updateFromCustom():this.updateInputValue(a[r].value),this.closeMenu(),(n=this.button.current)===null||n===void 0||n.focus(),e.stopPropagation(),e.preventDefault();break;case"Tab":e.shiftKey?this.handleMenuNavigation(z.MENU_NAVIGATION_DIRECTION.UP):this.handleMenuNavigation(z.MENU_NAVIGATION_DIRECTION.DOWN),e.stopPropagation(),e.preventDefault();break;case"ArrowUp":this.handleMenuNavigation(z.MENU_NAVIGATION_DIRECTION.UP),e.stopPropagation(),e.preventDefault();break;case"ArrowDown":this.handleMenuNavigation(z.MENU_NAVIGATION_DIRECTION.DOWN),e.stopPropagation(),e.preventDefault();break;case"Escape":this.closeMenu();break}}handleMenuNavigation(e){var{keyboardOptionIndex:n,inputFocused:r}=this.state,{options:i}=this.props,a=i.length,o=n;switch(e){case z.MENU_NAVIGATION_DIRECTION.UP:if(!r&&n===0){this.focusInput();break}else r&&this.focusOption(n);n>0&&!r?(o=(o-1)%a,this.setState({keyboardOptionIndex:o})):n===0&&(o=a-1,this.setState({keyboardOptionIndex:o})),this.scrollOptionIntoView(o);break;case z.MENU_NAVIGATION_DIRECTION.DOWN:if(!r&&n===a-1){this.focusInput();break}else r&&this.focusOption(n);n<a&&!(r&&n===0)&&(o=(o+1)%a,this.setState({keyboardOptionIndex:o})),this.scrollOptionIntoView(o);break}}handleOptionClick(e){var n=Number(e.currentTarget.value),{options:r,timeToValue:i}=this.props,{customTime:a}=this.state;if(n===rr){var o=i(a);this.updateAndClose(o)}else this.updateAndClose(r[n].value)}updateAndClose(e){var n;this.updateInputValue(e),this.closeMenu(),(n=this.button.current)===null||n===void 0||n.focus()}handleOptionFocus(e){this.setState({keyboardOptionIndex:Number(e.target.value)})}handleMenuOpened(){var e,{options:n,value:r}=this.props,{keyboardOptionIndex:i}=this.state;this.scrollOptionIntoView(i);var a=(e=this.menuContainer.current)===null||e===void 0?void 0:e.querySelector(".cs-option-btn.keyboard-active");if(a instanceof HTMLElement&&a.focus(),r!==null){var o=n.map(s=>s.value).indexOf(r);o<0&&this.focusInput()}}focusInput(){var e;(e=this.input.current)===null||e===void 0||e.focus()}focusOption(e){var n,r=(n=this.menuContainer.current)===null||n===void 0?void 0:n.querySelector(".cs-options");if(r&&r.children!=null){var i=r.children.item(e);i instanceof HTMLElement&&i.focus()}}handleMenuExited(){var{menuIsOpen:e}=this.state;e&&this.setState({menuIsOpen:!1,keyboardOptionIndex:0})}handleCustomInput(e){var{timeToValue:n}=this.props,r=n(e);this.updateInputValue(r),this.setState({customTime:e})}updateFromCustom(){var{timeToValue:e}=this.props,{customTime:n}=this.state,r=e(n);this.updateInputValue(r)}toggleMenu(e){var{menuIsOpen:n}=this.state;n?this.closeMenu():this.openMenu(),e.stopPropagation()}openMenu(){this.updateKeyboardIndex(),this.setInputWidth(),this.setState({menuIsOpen:!0})}closeMenu(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;if(this.setState({menuIsOpen:!1}),e){var n;(n=this.button.current)===null||n===void 0||n.focus()}}updateKeyboardIndex(){var{options:e,value:n}=this.props;if(n!==null){var r=e.map(i=>i.value).indexOf(n);r>0&&this.setState({keyboardOptionIndex:r})}}scrollOptionIntoView(e){var n,r=(n=this.menuContainer.current)===null||n===void 0?void 0:n.querySelector(".cs-options");if(r&&r.children!=null){var i=r.children.item(e);i instanceof HTMLElement&&i.offsetTop>z.DROP_DOWN_MENU_HEIGHT?r.scrollTop=i.offsetTop-z.DROP_DOWN_MENU_HEIGHT:(i instanceof HTMLElement&&i.offsetTop<0||e===0)&&(r.scrollTop=0)}}renderMenuElement(){var{inputWidth:e}=this.state;return u.jsx("div",{className:"cs-menu-container",ref:this.menuContainer,role:"presentation",onKeyDown:this.handleMenuKeyDown,onClick:n=>{n.stopPropagation()},style:{width:e},children:u.jsx("div",{className:"cs-options-container",children:u.jsx("div",{className:"cs-options",children:this.renderOptions()})})})}renderOptions(){for(var{options:e,value:n,icon:r,customText:i}=this.props,{keyboardOptionIndex:a,customTime:o,inputFocused:s}=this.state,l=!1,d=[],f=0;f<e.length;f+=1){var p=e[f],h="option-".concat(f,"-").concat(p.value);l=l||p.value===n,d.push(u.jsxs("button",{type:"button",value:f,className:N("cs-option-btn",{"keyboard-active":a===f&&!s}),onClick:this.handleOptionClick,onFocus:this.handleOptionFocus,children:[p.value===n&&u.jsx(Y,{icon:r,className:"mr-2"}),p.value!==n&&u.jsx("span",{className:"mr-4"}),p.title]},h))}return d.push(u.jsx("hr",{className:"cs-divider"},"option-divider")),d.push(u.jsxs("button",{type:"button",value:rr,className:N("cs-option-btn",{"keyboard-active":s}),onClick:this.handleOptionClick,onFocus:this.handleOptionFocus,children:[!l&&n!==null?u.jsx(Y,{icon:r,className:"mr-2"}):u.jsx("span",{className:"mr-4"}),i]},"option-custom-label")),d.push(u.jsxs("div",{className:"cs-custom-container",children:[u.jsx("span",{className:"mr-2"}),u.jsx(qe,{ref:this.input,onChange:this.handleCustomInput,value:o,onFocus:()=>this.setState({inputFocused:!0}),onBlur:()=>this.setState({inputFocused:!1})},"option-input"),u.jsx("span",{className:"ml-2"})]},"cs-custom-container")),d.push(u.jsx("hr",{className:"mb-2"},"option-end")),d}render(){var{disabled:e,invalid:n,value:r,"data-testid":i}=this.props,{menuIsOpen:a}=this.state,{popperOptions:o}=this.props;return o=Cg({placement:"bottom-end",modifiers:{preventOverflow:{enabled:!1}}},o),u.jsx("div",{className:"input-group cs-container context-menu",ref:this.csContainer,"data-testid":i,children:u.jsx("div",{className:N("input-group-append cs-dropdown",{"cs-dropdown-invalid":n}),children:u.jsxs("button",{type:"button",className:N("btn cs-btn form-control",{"cs-btn-invalid":n}),ref:this.button,onClick:this.toggleMenu,disabled:e,children:[u.jsx("span",{className:N({"text-muted":r===null}),children:this.getSelectedText()}),u.jsx("span",{className:"cs-caret"}),u.jsx(bi,{isShown:a,actions:{menuElement:this.renderMenuElement()},popperOptions:o,popperClassName:"CustomTimeSelect",onMenuOpened:this.handleMenuOpened,onMenuClosed:this.handleMenuExited,menuStyle:{maxWidth:"100rem"}})]})})})}}ce(z,"MENU_NAVIGATION_DIRECTION",Ha);ce(z,"DROP_DOWN_MENU_HEIGHT",125);ce(z,"defaultProps",{onChange(){},value:null,disabled:!1,popperOptions:{},icon:tl,customText:"Custom",placeholder:"Select a time",valueToTime:t=>t===null?0:Math.round(t/1e3),timeToValue:t=>t*1e3,invalid:!1,"data-testid":void 0});var Ig=W.module("DateInput"),kg="[12][0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])",_g=["2000-01-01","2022-12-31"],Rg="YYYY-MM-DD",Va=U.forwardRef((t,e)=>{var{className:n="",onChange:r=()=>{},defaultValue:i="",onFocus:a=()=>{},onBlur:o=()=>{},"data-testid":s}=t,[l,d]=c.useState(i),[f,p]=c.useState(),h=c.useCallback(m=>{Ig.debug("handleChange",m),d(m),r(m)},[r]);return u.jsx("div",{className:"d-flex flex-row align-items-center",children:u.jsx(ln,{ref:e,className:N(n),example:_g,getNextSegmentValue:Mp,onChange:h,onSelect:p,pattern:kg,placeholder:Rg,selection:f,value:l,onFocus:a,onBlur:o,"data-testid":s})})});Va.displayName="DateInput";var Dg={CYCLE_TO_NEXT_STACK:pe.createAndAdd({id:"NAVIGATION.CYCLE_TO_NEXT_STACK",name:"Cycle To Next Stack",shortcut:[V.CTRL,K.SINGLE_QUOTE],macShortcut:[V.CMD,K.SINGLE_QUOTE],isEditable:!0}),CYCLE_TO_PREVIOUS_STACK:pe.createAndAdd({id:"NAVIGATION.CYCLE_TO_PREVIOUS_STACK",name:"Cycle To Previous Stack",shortcut:[V.CTRL,K.SEMICOLON],macShortcut:[V.CMD,K.SEMICOLON],isEditable:!0}),CYCLE_TO_NEXT_TAB:pe.createAndAdd({id:"NAVIGATION.CYCLE_TO_NEXT_TAB",name:"Cycle To Next Tab",shortcut:[V.CTRL,V.SHIFT,K.DOUBLE_QUOTE],macShortcut:[V.CMD,V.SHIFT,K.SINGLE_QUOTE],isEditable:!0}),CYCLE_TO_PREVIOUS_TAB:pe.createAndAdd({id:"NAVIGATION.CYCLE_TO_PREVIOUS_TAB",name:"Cycle To Previous Tab",shortcut:[V.CTRL,V.SHIFT,K.COLON],macShortcut:[V.CMD,V.SHIFT,K.SEMICOLON],isEditable:!0}),CYCLE_TO_NEXT_DASHBOARD:pe.createAndAdd({id:"NAVIGATION.CYCLE_TO_NEXT_DASHBOARD",name:"Cycle To Next Dashboard",shortcut:[V.CTRL,K.PERIOD],macShortcut:[V.CMD,K.PERIOD],isEditable:!0}),CYCLE_TO_PREVIOUS_DASHBOARD:pe.createAndAdd({id:"NAVIGATION.CYCLE_TO_PREVIOUS_DASHBOARD",name:"Cycle To Previous Dashboard",shortcut:[V.CTRL,K.COMMA],macShortcut:[V.CMD,K.COMMA],isEditable:!0})};function Lg(t){var{isInvalid:e=!1,items:n,onAdd:r=()=>{},onDelete:i=()=>{},validate:a=()=>null}=t,[o,s]=c.useState(null),[l,d]=c.useState([]),[f,p]=c.useState(""),h=c.useCallback(w=>{d(w)},[]),m=c.useCallback(()=>{i(xn.getItemsInRanges(n,l)),d([])},[n,l,i]),g=c.useCallback(()=>{if(f!==""){var w=a(f);w==null?(r(f),p("")):s(w)}},[f,r,a]),P=c.useCallback(w=>{var{value:j}=w.target;p(j),s(j===""?null:a(j))},[a]),v=c.useCallback(()=>{d([])},[]),y=c.useCallback(w=>{w.key==="Enter"&&g()},[g]),x=c.useMemo(()=>14+ti(n.length,1,6)*wt.DEFAULT_ROW_HEIGHT,[n.length]);return u.jsxs("div",{className:N("editable-item-list-container",{"is-invalid":e}),children:[u.jsx("div",{style:{height:x},children:u.jsx(wt,{itemCount:n.length,items:n.map((w,j)=>({value:w,isSelected:xn.isSelected(l,j)})),offset:0,selectedRanges:l,onSelectionChange:h,isMultiSelect:!0})}),u.jsxs("div",{className:"d-flex flex-row pt-2",children:[u.jsx("div",{className:"d-flex flex-grow-1",children:u.jsx("input",{className:N("form-control",{"is-invalid":o!=null}),placeholder:"Enter value",type:"text",value:f,onChange:P,onFocus:v,onKeyDown:y})}),u.jsxs("div",{className:"d-flex align-items-start mt-1 ml-2",children:[u.jsx(G,{kind:"ghost",onClick:g,disabled:o!=null||f==="",icon:nl,tooltip:"Add new item","data-testid":"add-item-button"}),u.jsx(G,{kind:"ghost",onClick:m,disabled:l.length===0,icon:ci,tooltip:"Delete selected items","data-testid":"delete-item-button"})]})]})]})}function Ag(t){var{message:e,isExpanded:n=!1,type:r="Error"}=t,[i,a]=c.useState(!1),[o,s]=c.useState(!1),l=c.useRef(null),d=c.useRef(null),f=c.useCallback(()=>{if(!(o||n||d.current==null)){var h=d.current.scrollHeight>d.current.clientHeight;a(h)}},[o,n]),p=Ie(f,100);return tt(l.current,p),c.useLayoutEffect(p,[p]),u.jsxs("div",{className:N("error-view",{expanded:o||n}),ref:l,children:[u.jsxs("div",{className:"error-view-header",children:[u.jsxs("div",{className:"error-view-header-text",children:[u.jsx(Y,{icon:rl}),u.jsx("span",{children:r})]}),u.jsxs("div",{className:"error-view-buttons",children:[u.jsx(Yi,{kind:"danger",className:"error-view-copy-button",tooltip:"Copy exception contents",copy:"".concat(r,": ").concat(e).trim()}),(i||o)&&!n&&u.jsx(G,{kind:"danger",className:"error-view-expand-button",onClick:()=>{s(!o)},icon:o?il:al,children:o?"Show Less":"Show More"})]})]}),u.jsx("pre",{className:"error-view-text",ref:d,children:e})]})}function Fg(t,e,n){return(e=Ng(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ng(t){var e=Mg(t,"string");return typeof e=="symbol"?e:e+""}function Mg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class Pe extends c.Component{static isParentSelected(e,n){var r=n.get(e);if(r===void 0)return!1;if(typeof r=="boolean")return r;var i=Array.from(r.values()).includes(!0),a=Array.from(r.values()).includes(!1);return i&&a?null:i}constructor(e){super(e),this.toggleMenu=this.toggleMenu.bind(this),this.toggleValueFor=this.toggleValueFor.bind(this),this.selectAll=this.selectAll.bind(this),this.clear=this.clear.bind(this),this.state={menuIsOpen:!1}}toggleMenu(e){e.stopPropagation(),e.preventDefault(),this.setState(n=>{var{menuIsOpen:r}=n;return{menuIsOpen:!r}})}toggleValueFor(e,n){var{valueMap:r,onUpdateValueMap:i}=this.props,a=new Map(r),o=a.get(e);if(o instanceof Map){var s=new Map(o);if(n!=null)s.set(n,o.get(n)!==!0);else{var l=Pe.isParentSelected(e,a),d=l==null||!l;o.forEach((h,m)=>s.set(m,d))}a.set(e,s)}else a.set(e,o==null||!o);var f=a.get(e);if(n===void 0&&f!==void 0&&typeof f!="boolean"){var p=Pe.isParentSelected(e,r);p!=null&&p?f.forEach((h,m)=>f.set(m,!1)):f.forEach((h,m)=>f.set(m,!0))}i(a)}setAllValues(e){var{valueMap:n,onUpdateValueMap:r}=this.props,i=new Map;n.forEach((a,o)=>{if(typeof a=="boolean")i.set(o,e);else{var s=new Map;a.forEach((l,d)=>s.set(d,e)),i.set(o,s)}}),r(i)}selectAll(){this.setAllValues(!0)}clear(){this.setAllValues(!1)}renderMenuElement(){var{valueMap:e,"data-testid":n}=this.props;return u.jsxs("div",{className:"hcm-menu-container",children:[Array.from(e.entries()).map(r=>{var[i,a]=r;return u.jsxs("div",{children:[u.jsx(Ot,{className:"hcm-parent",checked:Pe.isParentSelected(i,e),onChange:()=>this.toggleValueFor(i),children:i}),a!==void 0&&typeof a!="boolean"&&Array.from(a.entries()).map(o=>{var[s,l]=o;return u.jsx(Ot,{className:"hcm-child",checked:l,onChange:()=>this.toggleValueFor(i,s),children:s},s)})]},i)}),u.jsx(G,{kind:"ghost",onClick:this.selectAll,"data-testid":n!==void 0?"".concat(n,"-btn-select-all"):void 0,children:"Select All"}),u.jsx(G,{kind:"ghost",onClick:this.clear,"data-testid":n!==void 0?"".concat(n,"-btn-clear"):void 0,children:"Clear"})]})}render(){var{menuText:e,className:n,icon:r,id:i,"data-testid":a}=this.props,{menuIsOpen:o}=this.state;return u.jsxs("button",{type:"button",className:N("btn hcm-btn",n),onClick:this.toggleMenu,id:i,"data-testid":a,children:[u.jsxs("span",{children:[r&&u.jsx(Y,{icon:r,className:"hcm-icon mr-1"}),e]}),u.jsx("span",{className:"cs-caret"}),u.jsx(it,{options:{placement:"bottom"},isShown:o,onExited:()=>{this.setState({menuIsOpen:!1})},closeOnBlur:!0,interactive:!0,children:this.renderMenuElement()})]})}}Fg(Pe,"defaultProps",{className:"",icon:null,id:"","data-testid":void 0});function ir(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function ft(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?ir(Object(n),!0).forEach(function(r){$g(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):ir(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function $g(t,e,n){return(e=Ug(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ug(t){var e=Bg(t,"string");return typeof e=="symbol"?e:e+""}function Bg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Ga=c.memo(t=>{var{tab:e,onClose:n,onSelect:r,isActive:i,activeRef:a,index:o,isDraggable:s,contextActions:l}=t,{key:d,isClosable:f=n!=null,title:p,icon:h}=e,m;return h!=null&&(m=U.isValidElement(h)?h:u.jsx(Y,{icon:h})),u.jsx(Uo,{draggableId:d,index:o,isDragDisabled:!s,children:(g,P)=>u.jsxs("div",{className:"context-menu-wrapper",ref:i?a:null,children:[u.jsxs("div",ft(ft(ft({ref:g.innerRef},g.draggableProps),g.dragHandleProps),{},{className:N("btn btn-link btn-nav-tab",{active:i},{dragging:P.isDragging}),"data-testid":"btn-nav-tab-".concat(p),role:"tab",tabIndex:0,onAuxClick:v=>{f&&v.button===1&&v.buttons===0&&(n==null||n(d))},onClick:v=>{if(f&&v.button===1&&v.buttons===0){n==null||n(d);return}v.button===0&&v.buttons===0&&(v.target.focus(),r(d))},onKeyPress:v=>{v.key==="Enter"&&r(d)},children:[m,u.jsxs("span",{className:"btn-nav-tab-title",children:[p,u.jsx(Fe,{children:p})]}),f&&u.jsx(G,{kind:"ghost",className:"btn-nav-tab-close",onClick:v=>{n==null||n(d),v.stopPropagation(),v.preventDefault()},icon:di,tooltip:"Close"})]})),u.jsx(at,{actions:l})]})},d)});Ga.displayName="NavTab";function Ya(t){var{onSelect:e,tabs:n=Pi}=t,[r,i]=c.useState(""),[a,o]=c.useState(0),s=c.useRef(null),l=c.useRef(null),d=c.useRef([]);c.useEffect(()=>{var y;(y=s.current)===null||y===void 0||y.focus()},[]),c.useEffect(()=>{o(0)},[r]),c.useEffect(()=>{if(a>=0&&d.current[a]){var y;(y=d.current[a])===null||y===void 0||y.scrollIntoView({behavior:"auto",block:"nearest"})}},[a]);var f=c.useCallback(y=>{i(y.target.value)},[]),p=c.useCallback(y=>{e(y)},[e]),h=c.useCallback(y=>{y.preventDefault()},[]),m=c.useMemo(()=>n.filter(y=>y.title.toLowerCase().includes(r.toLowerCase())),[r,n]).sort((y,x)=>{var w;return(w=y.title.localeCompare(x.title))!==null&&w!==void 0?w:0}),g=c.useCallback(y=>{if(y.key==="ArrowDown"&&m.length>0)y.preventDefault(),o(w=>w===-1?0:(w+1)%m.length);else if(y.key==="ArrowUp"&&m.length>0)y.preventDefault(),o(w=>w===-1?m.length-1:(w-1+m.length)%m.length);else if(y.key==="Enter"&&m.length>0){y.preventDefault();var x=a>=0?a:0;p(m[x])}else y.key==="Tab"&&y.preventDefault()},[m,a,p]),P=c.useMemo(()=>m.map((y,x)=>{var w;return u.jsx("li",{ref:j=>{d.current[x]=j},onMouseDown:h,children:u.jsxs(G,{kind:"ghost","data-testid":"dashboard-list-item-".concat((w=y.key)!==null&&w!==void 0?w:"","-button"),onClick:()=>p(y),className:a===x?"focused":"",style:{transition:"none"},children:[y.icon?u.jsx("span",{className:"dashboard-list-item-icon",children:U.isValidElement(y.icon)?y.icon:u.jsx(Y,{icon:y.icon})}):null,y.title]})},y.key)}),[m,p,a,h]),v=c.useMemo(()=>P.length===0?u.jsx("span",{children:"No open dashboard found."}):null,[P]);return u.jsxs("div",{className:"dashboard-list-container d-flex flex-column",children:[u.jsx("div",{className:"dashboard-list-header",children:u.jsx(Xt,{value:r,placeholder:"Find open dashboard",endPlaceholder:ot.OPEN_DASHBOARD_LIST.getDisplayText(),onChange:f,onKeyDown:g,ref:s})}),u.jsxs("ul",{className:"dashboard-list flex-grow-1",ref:l,children:[v&&u.jsx("li",{className:"dashboard-list-message",children:v}),!v&&P]})]})}function ar(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function or(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?ar(Object(n),!0).forEach(function(r){Wg(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):ar(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Wg(t,e,n){return(e=Hg(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Hg(t){var e=Vg(t,"string");return typeof e=="symbol"?e:e+""}function Vg(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Gg=500,Yg=.01,Kg=5e-4;function sr(t){return t.scrollLeft===0}function lr(t){return Math.abs(t.scrollLeft+t.clientWidth-t.scrollWidth)<=1||t.scrollWidth===0}function zg(t,e,n){var{isClosable:r=!1,key:i}=t,a=[];if(r&&n!=null){a.push({title:"Close",order:10,group:20,action:()=>{n(i)}});for(var o=!0,s=e.length-1;s>0&&e[s].key!==t.key;s-=1)if(e[s].isClosable===!0){o=!1;break}a.push({title:"Close to the Right",order:20,group:20,action:()=>{for(var l=e.length-1;l>0&&e[l].key!==i;l-=1)e[l].isClosable===!0&&n(e[l].key)},disabled:o}),a.push({title:"Close All",order:30,group:20,action:()=>{e.forEach(l=>{l.isClosable===!0&&n(l.key)})}})}return a}function qg(t){var{activeKey:e,tabs:n,onSelect:r,onReorder:i,onClose:a,makeContextActions:o}=t,s=c.useRef(),[l,d]=c.useState(!0),[f,p]=c.useState(!1),[h,m]=c.useState(!0),[g,P]=c.useState(!0),v=c.useCallback(()=>{s.current!=null&&(s.current.clientWidth<s.current.scrollWidth&&n.length>0?d(!0):d(!1),m(sr(s.current)),P(lr(s.current)))},[n]);tt(s.current,v);var y=c.useCallback(C=>{jt.stopDragging(),C.destination&&(i==null||i(C.source.index,C.destination.index))},[i]),x=c.useCallback(()=>{if(s.current!=null){var C=sr(s.current);C!==h&&m(C);var R=lr(s.current);R!==g&&P(R)}},[h,g]),w=c.useRef({cancelClick:!1}),j=c.useCallback(()=>{if(!(s.current==null||w.current.cancelClick))for(var{children:C}=s.current,R=C.length-1;R>=0;R-=1){var O=C[R];if(O.offsetLeft<s.current.scrollLeft-5){O.scrollIntoView({behavior:"smooth",block:"nearest",inline:"start"});return}}},[]),b=c.useCallback(()=>{if(!(s.current==null||w.current.cancelClick))for(var{children:C}=s.current,R=0;R<C.length;R+=1){var O=C[R];if(O.offsetLeft+5>s.current.scrollLeft+s.current.offsetWidth){O.scrollIntoView({behavior:"smooth",block:"nearest",inline:"end"});return}}},[]),S=c.useCallback(function(C,R){var O=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,T=arguments.length>3?arguments[3]:void 0,_=s.current;_!=null&&(w.current.cancelClick=!0,C==="left"?_.scrollLeft=R-O:C==="right"&&(_.scrollLeft=R+O),w.current.rAF=requestAnimationFrame(M=>{var J=T??M,Se=M-J,pt=Yg*Se+.5*Kg*Se**2;pt=Math.min(pt,_.scrollWidth),S(C,R,pt,J)}))},[]),I=c.useCallback(()=>{var{holdTimer:C,rAF:R}=w.current;C!=null&&(clearTimeout(C),w.current.holdTimer=void 0),R!=null&&(cancelAnimationFrame(R),w.current.rAF=void 0),window.removeEventListener("mouseup",I)},[]);c.useEffect(()=>()=>window.removeEventListener("mouseup",I),[I]);var k=c.useCallback(C=>{s.current!=null&&(w.current.holdTimer=window.setTimeout(S,Gg,C,s.current.scrollLeft)),w.current.cancelClick=!1,window.addEventListener("mouseup",I)},[I,S]),L=c.useCallback(()=>{k("left")},[k]),F=c.useCallback(()=>{k("right")},[k]);c.useEffect(function(){var R,O=T=>{T.stopPropagation(),T.preventDefault();var _=T.currentTarget,M=Math.abs(T.deltaY)>Math.abs(T.deltaX)?T.deltaY:T.deltaX;_.scrollLeft+=ti(M,-30,30)};return(R=s.current)===null||R===void 0||R.addEventListener("wheel",O),()=>{var T;(T=s.current)===null||T===void 0||T.removeEventListener("wheel",O)}},[]);var H=c.useMemo(()=>{var C=new Map;return n.forEach(R=>{var{key:O}=R,T=[()=>zg(R,n,a),()=>{var _;return(_=o==null?void 0:o(R))!==null&&_!==void 0?_:[]}];C.set(O,T)}),C},[o,n,a]),E=c.useRef(null),A=n.find(C=>C.key===e),D=n.map((C,R)=>{var{key:O}=C,T=C===A;return u.jsx(Ga,{tab:C,index:R,isActive:T,activeRef:E,onSelect:r,onClose:a,isDraggable:i!=null,contextActions:H.get(O)},O)});c.useEffect(function(){E.current!=null&&E.current.scrollIntoView({block:"nearest",inline:"nearest"})},[e]);var B=()=>{p(!f)},Q=C=>{p(!1),r(C.key)},Z=()=>{p(!1)};return u.jsxs("nav",{className:"nav-container",children:[l&&u.jsx(G,{kind:"ghost",icon:u.jsx(Y,{icon:ol,transform:"grow-4"}),className:"tab-controls-btn tab-controls-btn-left",tooltip:"Scroll left",onClick:j,onMouseDown:L,disabled:h}),u.jsx(Bo,{onDragStart:jt.startDragging,onDragEnd:y,children:u.jsx(Wo,{droppableId:"droppable-tab-navigation",direction:"horizontal",children:(C,R)=>u.jsxs("div",or(or({ref:O=>{O!=null&&(s.current=O,C.innerRef(O))}},C.droppableProps),{},{className:N("nav nav-tabs",{dragging:R.draggingFromThisWith}),role:"tablist",onScroll:x,children:[D,C.placeholder]}))})}),l&&u.jsx(G,{kind:"ghost",icon:u.jsx(Y,{icon:sl,transform:"grow-4"}),className:"tab-controls-btn tab-controls-btn-right",tooltip:"Scroll right",onClick:b,onMouseDown:F,disabled:g}),u.jsx(G,{kind:"ghost",icon:u.jsx(Y,{icon:ll,transform:"grow-4"}),className:"btn-dashboard-list-menu btn-show-dashboard-list",tooltip:"Search open dashboards",onClick:B,disabled:n.length<2,style:{visibility:l?"visible":"hidden",marginLeft:"auto"},children:u.jsx(it,{isShown:f,className:"dashboard-list-menu-popper",onExited:Z,options:{placement:"bottom-start"},closeOnBlur:!0,interactive:!0,children:u.jsx(Ya,{tabs:n,onSelect:Q})})}),u.jsx(at,{actions:[{action:()=>{p(!f)},shortcut:ot.OPEN_DASHBOARD_LIST,isGlobal:!0}]})]})}var Xg=.025,Qg=.9,Jg=.1,Zg=.618,ur=80,ye={SIZE:8,DOT_SIZE:2},ie=18,ey=250,ty=60*1e3,ny={background:"var(--dh-color-random-area-plot-animation-bg)",foregroundFill:"var(--dh-color-random-area-plot-animation-fg-fill)",foregroundStroke:"var(--dh-color-random-area-plot-animation-fg-stroke)",gridColor:"var(--dh-color-random-area-plot-animation-grid)"};function ry(){return pi(ny)}var Ka=U.memo(()=>{var{activeThemes:t}=rt(),e=c.useMemo(ry,[t]),n=c.useRef(null),r=c.useRef(null),[i,a]=c.useState(!1),o=window.devicePixelRatio,s,l,d,f,p,h=null,m=[];function g(){var E;r.current!=null&&(d=r.current.offsetWidth,f=r.current.offsetHeight),n.current!=null&&(n.current.style.width="".concat(d,"px"),n.current.style.height="".concat(f,"px"),n.current.width=d*o,n.current.height=f*o),(E=s)===null||E===void 0||E.scale(o,o)}function P(){var{foregroundFill:E,foregroundStroke:A}=e,D=document.createElement("canvas");D.width=ye.SIZE,D.height=ye.SIZE;var B=D.getContext("2d");return B!=null&&(B.fillStyle=A,B.fillRect(0,0,ye.DOT_SIZE,ye.DOT_SIZE),B.fillStyle=E,B.fillRect(0,0,ye.SIZE,ye.SIZE)),B==null?void 0:B.createPattern(D,"repeat")}function v(E){var A=Math.random()-.5,D=Xg*A;return E<Jg?D=Math.abs(D):E>Qg&&(D=-Math.abs(D)),E+D}function y(){for(var E=[],A=Zg,D=0;D<d+ie;D+=1)A=v(A),E.push(A);return E}function x(){for(;m.length>=d+ie;)m.pop();for(;m.length<d+ie;)m.push(v(m[m.length-1]))}function w(E,A){A.beginPath(),A.moveTo(-1,f+1),A.lineTo(-1,f*E[0]);for(var D=0;D<E.length;D+=1)A.lineTo(D,f*E[D]);A.lineTo(d+ie,f*E[E.length-1]),A.lineTo(d+ie,f+1),A.closePath()}function j(E){E.beginPath();for(var A=1;A<d;A+=ur)E.moveTo(A,0),E.lineTo(A,f);for(var D=1;D<f;D+=ur)E.moveTo(0,D),E.lineTo(d,D)}function b(E){h=h??E;var{background:A,foregroundStroke:D,gridColor:B}=e;Ze(s),s.fillStyle=A,s.fillRect(0,0,d,f),j(s),s.lineWidth=1,s.strokeStyle=B,s.stroke();var Q=((h??0)-(E??0))/(1e3/ie);if(s.translate(Q,0),w(m,s),s.lineWidth=2,s.strokeStyle=D,s.stroke(),s.translate(-Q,0),l!=null&&(s.fillStyle=l),s.fill(),s.setTransform(o,0,0,o,0,0),(E??0)-(h??0)>1e3/ie){for(var Z=Math.floor(((E??0)-(h??0))/(1e3/ie)),C=0;C<Z;C+=1)m.shift(),m.push(v(m[m.length-1]));h=E}p!=null&&cancelAnimationFrame(p),p=requestAnimationFrame(b)}var S=je(()=>{p=requestAnimationFrame(E=>{g(),x(),a(!1),b(E)})},ey,{leading:!0});function I(){a(!0),p!=null&&cancelAnimationFrame(p),p=null,h=null}var k=je(()=>{I()},ty);function L(){p==null&&(a(!1),g(),x(),p=requestAnimationFrame(b)),k()}function F(){document.hasFocus()&&L()}function H(){p!=null&&cancelAnimationFrame(p),k(),S()}return c.useEffect(()=>{var E;return s=(E=n.current)===null||E===void 0?void 0:E.getContext("2d",{alpha:!1}),g(),m=y(),l=P(),b(),k(),window.addEventListener("resize",H),window.addEventListener("focus",L),window.addEventListener("blur",I),window.addEventListener("mousemove",F),window.addEventListener("keydown",F),()=>{p!=null&&cancelAnimationFrame(p),window.removeEventListener("resize",H),window.removeEventListener("focus",L),window.removeEventListener("blur",I),window.removeEventListener("mousemove",F),window.removeEventListener("keydown",F),k.cancel(),S.cancel()}},[e]),u.jsx("div",{className:"random-area-plot-animation-container",ref:r,children:u.jsx("canvas",{ref:n,className:i?"shade":""})})});function za(t){var{text:e,placement:n="top-start"}=t,r=c.useMemo(()=>({placement:n}),[n]);return u.jsxs(u.Fragment,{children:[u.jsx(lt,{UNSAFE_className:on.spectrumEllipsis,children:e??u.jsx(u.Fragment,{children:" "})}),e==null||e===""?null:u.jsx(Fe,{options:r,children:e})]})}var iy=["scrollRef","getItemDisplayText","getKey"];function cr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function dr(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?cr(Object(n),!0).forEach(function(r){ay(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):cr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function ay(t,e,n){return(e=oy(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function oy(t){var e=sy(t,"string");return typeof e=="symbol"?e:e+""}function sy(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function ly(t,e){if(t==null)return{};var n,r,i=uy(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function uy(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function cy(t){var{scrollRef:e,getItemDisplayText:n,getKey:r}=t,i=ly(t,iy),a=c.useCallback(o=>{var s=r(o),l=n(o);return u.jsx(Xe,{textValue:l??String(s),children:u.jsx(za,{text:l})},s)},[n,r]);return u.jsx(Wt,dr(dr({},i),{},{ref:e,menuTrigger:"focus",onSelectionChange:i.onSelectionChange,children:a}))}var dy=500;function py(t){var{heading:e,content:n,delayMs:r=dy}=t,[i,a]=c.useState(!1);return c.useEffect(()=>{window.setTimeout(()=>{a(!0)},r)},[r]),i?u.jsxs(ni,{children:[u.jsx(Le,{size:"XXL",children:u.jsx(Y,{icon:ul})}),u.jsx(ut,{children:e}),n==null?null:u.jsx(Ht,{children:n})]}):null}const qa={"handle-size":"15px","popover-width":"90px"};var We=parseInt(qa["handle-size"],10),pr=parseInt(qa["popover-width"],10),q=24*60*60-1,fr=5*60;function fy(t){var{startTime:e,endTime:n,onChange:r,isStartModified:i=!1,isEndModified:a=!1,"data-testid":o}=t,[s,l]=c.useState(e),[d,f]=c.useState(n),p=c.useRef(null);c.useEffect(function(){l(e),f(n)},[e,n]);var h=c.useCallback((P,v)=>{var y=P,x=v;y===x&&(x<q?x+=1:y-=1),l(y),f(x),r({startTime:y,endTime:x})},[l,f,r]),m=c.useCallback(P=>{h(P,d)},[h,d]),g=c.useCallback(P=>{h(s,P)},[h,s]);return u.jsxs("div",{className:"time-slider","data-testid":o,children:[u.jsx(hy,{startTime:s,endTime:d,onStartTimeChange:m,onEndTimeChange:g,isStartModified:i,isEndModified:a}),u.jsxs("div",{className:"track",ref:p,children:[u.jsx(my,{startTime:s,endTime:d}),u.jsx("div",{className:"ticks",children:Array(24).fill(null).map((P,v)=>u.jsx("div",{className:"tick"},v))}),u.jsx(hr,{track:p,time:s,setTime:m}),u.jsx(hr,{track:p,time:d,setTime:g})]}),u.jsxs("div",{className:"tick-labels",children:[u.jsx("div",{className:"tick-label",children:"0:00"}),u.jsx("div",{className:"tick-label-wrapper",children:Array(24).fill(null).map((P,v)=>u.jsx("div",{className:"tick-label",children:"".concat(v+1,":00")},v))})]})]})}function hy(t){var{startTime:e,endTime:n,onStartTimeChange:r,onEndTimeChange:i,isStartModified:a,isEndModified:o,"data-testid":s}=t,l=e>n,[d,f]=c.useState(l?n:e),[p,h]=c.useState(l?e:n),m=c.useRef(null),g=c.useRef(null),P=c.useRef(null),v=c.useRef(null);c.useEffect(function(){f(e>n?n:e),h(e>n?e:n)},[e,n]),c.useEffect(function(){if(P.current!==null){var S;(S=g.current)===null||S===void 0||S.setSelection(P.current)}if(v.current!==null){var I;(I=m.current)===null||I===void 0||I.setSelection(v.current)}},[l]);function y(b){e<=n?r(b):i(b)}function x(b){e<=n?i(b):r(b)}var w=c.useCallback(b=>{P.current=b,v.current=null},[]),j=c.useCallback(b=>{P.current=null,v.current=b},[]);return u.jsxs("div",{className:"time-slider-popovers",children:[u.jsx("div",{className:"flex",style:{flexBasis:"calc(".concat(d/q*100,"% - ").concat(pr/2,"px)")}}),u.jsxs("div",{className:"handle-popper",children:[u.jsx("label",{className:N({modified:l?o:a}),children:l?"End Time":"Start Time"}),u.jsx(qe,{ref:m,allowValueWrapping:!1,value:d,onChange:y,onSelect:w,"data-testid":s!==void 0?"".concat(s,"-input-1"):void 0})]}),u.jsx("div",{className:"flex-spacer"}),u.jsxs("div",{className:"handle-popper",children:[u.jsx("label",{className:N({modified:l?a:o}),children:l?"Start Time":"End Time"}),u.jsx(qe,{ref:g,allowValueWrapping:!1,value:p,onChange:x,onSelect:j,"data-testid":s!==void 0?"".concat(s,"-input-2"):void 0})]}),u.jsx("div",{className:"flex",style:{flexBasis:"calc(".concat((q-p)/q*100,"% - ").concat(pr/2,"px)")}})]})}function my(t){var{startTime:e,endTime:n,"data-testid":r}=t;return u.jsxs("div",{className:"track-fills","data-testid":r,children:[e>n&&u.jsxs(u.Fragment,{children:[u.jsx("div",{className:"track-fill track-fill-start",style:{transform:"scaleX(".concat(n/q,")")}}),u.jsx("div",{className:"track-fill track-fill-end",style:{transform:"scaleX(".concat((q-e)/q,")")}})]}),e<n&&u.jsx("div",{className:"track-fill track-fill-middle",style:{transform:"translateX(".concat(e/q*100,"%) scaleX(").concat((n-e)/q,")")}})]})}function hr(t){var{track:e,time:n,setTime:r,"data-testid":i}=t,a=c.useMemo(()=>{var h=3600,m=We/2;return n<h?m=n/h*(We/2):n>23*h&&(m=We/2+1/(q-23*h)*(n-23*h)*(We/2)),"translateX(calc(".concat(n/q*100,"% - ").concat(m,"px))")},[n]),o=c.useCallback(h=>{if(!e.current)return 0;var m=e.current.getBoundingClientRect(),g=Math.max(h-m.left,0),P=q*Math.min(1,g/m.width),v=fr*Math.round(P/fr),y=Math.min(q,v);return y},[e]),s=c.useCallback(h=>{var{clientX:m}=h;r(o(m))},[r,o]),l=c.useCallback(h=>{var{clientX:m}=h;r(o(m)),window.removeEventListener("mousemove",s),window.removeEventListener("mouseup",l),document.documentElement.classList.remove("drag-pointer-events-none")},[r,o,s]),d=c.useCallback(()=>{window.addEventListener("mousemove",s),window.addEventListener("mouseup",l),document.documentElement.classList.add("drag-pointer-events-none")},[s,l]),f=c.useCallback(()=>{window.removeEventListener("mousemove",s),window.removeEventListener("mouseup",l),document.documentElement.classList.remove("drag-pointer-events-none")},[s,l]),p=c.useCallback(()=>{d()},[d]);return c.useEffect(function(){return()=>{f()}},[f]),u.jsx("div",{className:"handle-track",style:{transform:a},children:u.jsx("button",{className:"handle",type:"button","aria-label":"Change time",onMouseDown:p,"data-testid":i})})}function Xa(t){var{buttons:e,isShown:n=!1,classNames:r,message:i,type:a,onClick:o,onDismiss:s,"data-testid":l}=t,d=c.useRef(null),f=e&&e.length!==0;return u.jsx(ei,{in:n,timeout:xt.transitionMs,classNames:"toast-notification-slide-up",mountOnEnter:!0,unmountOnExit:!0,nodeRef:d,children:u.jsxs("div",{ref:d,className:N("toast-notification",r,a),role:"presentation",onClick:o,onKeyPress:o,"data-testid":l,children:[u.jsx("div",{className:"message-container",children:u.jsx("span",{className:"message",children:i})}),u.jsx(Jt,{in:f,timeout:xt.transitionSlowMs,mountOnEnter:!0,unmountOnExit:!0,children:u.jsx("div",{className:"buttons-container",children:e})}),s&&u.jsx(G,{kind:"ghost",icon:di,tooltip:"Close notification",className:"my-2",onClick:s})]})})}Xa.TYPE=Object.freeze({ERROR:"error"});const gy=Object.freeze(Object.defineProperty({__proto__:null,ACTION_ICON_HEIGHT:sn,Accordion:Ho,ActionBar:Zr,ActionButton:Qe,ActionButtonDialogTrigger:Aa,ActionGroup:$p,ActionMenu:Up,AlertDialog:Vo,AutoCompleteInput:te,AutoResizeTextarea:cg,Avatar:Go,Badge:Yo,BasicModal:xi,Breadcrumbs:Ko,BulkActionBar:mg,Button:G,ButtonGroup:Jr,CSS_VAR_EXPRESSION_PREFIX:cl,Calendar:zo,CardFlip:wd,Checkbox:Ot,CheckboxGroup:Hm,Collapse:Re,ColorEditor:qo,ColorPicker:Xo,ColorValues:Bp,ComboBox:Wp,ComboBoxNormalized:Ra,ConfirmActionButton:Zm,ConfirmationDialog:Fa,Content:Ht,ContextActionUtils:le,ContextActions:at,ContextMenuItem:vi,ContextMenuRoot:Ba,ContextualHelp:Qo,ContextualHelpTrigger:Jo,CopyButton:Yi,CustomTimeSelect:z,DEFAULT_DARK_THEME_KEY:dl,DEFAULT_DARK_THEME_PALETTE:pl,DEFAULT_GET_PREFERRED_REPLACEMENT_STRING:sa,DEFAULT_LIGHT_THEME_KEY:fl,DEFAULT_PRELOAD_DATA_VARIABLES:hl,DH_CSS_VAR_NAME_REGEXP:ml,DH_VAR_PREFIX:gl,DashboardList:Ya,DateField:Zo,DateInput:Va,DatePicker:es,DateRangePicker:ts,DateTimeInput:Hp,DebouncedModal:$a,DebouncedSearchInput:Pu,Dialog:qr,DialogContainer:ns,DialogTrigger:zr,Disclosure:rs,DisclosurePanel:is,DisclosureTitle:as,Divider:Xr,DragUtils:jt,DraggableItemList:Vp,DropdownMenu:bi,EXTERNAL_THEME_KEY:yl,EditableItemList:Lg,ErrorBoundary:xu,ErrorView:Ag,FadeTransition:Jt,Flex:Kr,Footer:os,Form:Qr,GLOBAL_SHORTCUTS:ot,Grid:ss,Header:ls,Heading:ut,HierarchicalCheckboxMenu:Pe,ITEM_EMPTY_STRING_TEXT_VALUE:Gp,Icon:Le,IconActionButton:Na,IllustratedMessage:ni,Image:us,InfoModal:Ua,InlineAlert:cs,Item:Xe,ItemContent:Yp,ItemList:wt,ItemListItem:wu,ItemTooltip:Kp,KEY:K,Keyboard:ds,LIST_VIEW_ROW_HEIGHTS:la,LabeledValue:ps,Link:ri,ListActionGroup:zp,ListActionMenu:qp,ListView:vm,ListViewNormalized:Da,ListViewWrapper:dn,LoadingOverlay:me,LoadingSpinner:Je,LogicButton:fs,Logo:Zh,MODIFIER:V,MSG_REQUEST_GET_THEME:vl,MSG_REQUEST_SET_THEME:li,MaskedInput:ln,Menu:Xp,MenuItem:Qp,MenuTrigger:hs,Meter:ms,Modal:Yt,ModalBody:Kt,ModalFooter:wi,ModalHeader:fi,NAVIGATION_SHORTCUTS:Dg,NON_WHITESPACE_REGEX:bl,NavTabList:qg,NumberField:gs,Option:ua,PICKER_ITEM_HEIGHTS:Jp,PICKER_TOP_OFFSET:Zp,PRELOAD_TRANSPARENT_THEME_QUERY_PARAM:Pl,Page:ef,Picker:tf,PickerNormalized:nf,Popper:it,ProgressBar:ys,ProgressCircle:vs,Radio:bs,RadioGroup:Ps,RandomAreaPlotAnimation:Ka,RangeCalendar:xs,RangeSlider:ws,SVG_ICON_MANUAL_COLOR_MAP:xl,SearchField:Os,SearchInput:Xt,SearchableCombobox:cy,Section:rf,Select:Oi,SelectValueList:ca,Shortcut:Ou,ShortcutRegistry:pe,SlideTransition:af,Slider:Ss,SocketedButton:Od,SpectrumButton:bt,SpectrumCheckbox:vt,SpectrumComboBox:Wt,SpectrumMenu:Es,SplitButtonGroup:Su,Stack:of,StatusLight:Cs,SubmenuTrigger:Ts,Switch:js,TABLE_ROW_HEIGHT:sf,THEME_CACHE_LOCAL_STORAGE_KEY:wl,THEME_KEY_OVERRIDE_QUERY_PARAM:Ol,TMP_CSS_PROP_PREFIX:Sl,TRANSPARENT_PRELOAD_DATA_VARIABLES:El,TabList:Is,TabPanels:Th,TableViewEmptyState:py,Tabs:ks,TagGroup:_s,Text:lt,TextArea:Rs,TextField:Ds,TextWithTooltip:za,ThemeContext:Eu,ThemeExport:xt,ThemePicker:Jh,ThemeProvider:Si,TimeField:Ls,TimeInput:qe,TimeSlider:fy,ToastContainer:As,ToastNotification:Xa,ToastQueue:Fs,ToggleButton:Ns,Tooltip:Fe,UISwitch:Cu,View:La,WHITESPACE_REGEX:Cl,Well:Ms,XComponentMapContext:Tu,XComponentMapProvider:ju,baseStyleProps:$s,calculatePreloadStyleContent:Tl,canHaveRef:Ei,colorValueStyle:X,createCssVariableResolver:jl,createPreloadStyleElement:Il,createXComponent:Iu,extractDistinctCssVariableExpressions:kl,fillToLength:lf,getActiveThemes:_l,getDefaultBaseThemes:Rl,getDefaultSelectedThemeKey:Dl,getExpressionRanges:Ll,getItemKey:Tt,getItemTextValue:uf,getPositionOfSelectedItemElement:cf,getThemeKey:Al,getThemeKeyOverride:Fl,getThemePreloadData:Nl,isBaseThemeKey:Ml,isClassComponent:ku,isDHColorValue:df,isExternalThemeData:ui,isExternalThemeEnabled:Vt,isForwardRefComponentType:_u,isItemElement:pf,isItemElementWithDescription:ff,isItemOrSection:hf,isNormalizedItemsWithKeysList:mf,isNormalizedSection:gf,isPreloadTransparentTheme:$l,isSectionElement:yf,isValidColorVar:Ul,isWrappedComponent:Ci,itemSelectionToStringSet:Ye,normalizeTooltipOptions:an,overrideSVGFillColors:Bl,parseExternalThemeData:oi,preloadTheme:Wl,replaceSVGFillColor:Hl,requestExternalThemeData:si,resolveCssVariablesInRecord:pi,resolveCssVariablesInString:Vl,separateSpectrumProps:Ia,setThemePreloadData:Gl,themeDHDefault:Yl,themeDark:Kl,themeLight:zl,trimTrailingMask:vf,useExternalTheme:_a,useOnChangeTrackUncontrolled:bf,usePickerItemScale:da,usePickerNormalizedProps:ia,usePickerProps:Pf,usePickerScrollOnOpen:xf,useRenderNormalizedItem:oa,useSpectrumThemeProvider:rn,useStaticItemInitialScrollPosition:wf,useStringifiedMultiSelection:ka,useStringifiedSelection:Of,useStyleProps:Us,useTheme:rt,useXComponent:Ru,viewStyleProps:Bs,wrapIcon:Sf,wrapItemChildren:aa,wrapPrimitiveWithText:Ef},Symbol.toStringTag,{value:"Module"}));var Qa=U.memo(t=>{var{children:e,onError:n,widget:r}=t,[i,a]=Zt(r);return a!=null?(n==null||n(a),null):i==null?null:u.jsx(zt.Provider,{value:i,children:e})});Qa.displayName="DeferredApiBootstrap";var ct=c.createContext(null);ct.displayName="ObjectFetchManagerContext";function Ja(t){var[e,n]=c.useState({status:"loading"}),r=c.useContext(ct);return c.useEffect(()=>{if(r==null){n({error:new Error("No ObjectFetchManager available in context"),status:"error"});return}return n(i=>i.status==="loading"?i:{status:"loading"}),r.subscribe(t,n)},[t,r]),e}function mr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function gr(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?mr(Object(n),!0).forEach(function(r){yy(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):mr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function yy(t,e,n){return(e=vy(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function vy(t){var e=by(t,"string");return typeof e=="symbol"?e:e+""}function by(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function yr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function Py(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){yr(a,r,i,o,s,"next",l)}function s(l){yr(a,r,i,o,s,"throw",l)}o(void 0)})}}var He=W.module("useWidget");function xy(t){var[e,n]=c.useState(()=>({widget:null,error:null})),r=Ja(t),[i,a]=Zt(t),o=ge(),s=i??o;c.useEffect(function(){He.debug("loadWidget",t);var{status:f}=r;if(f==="error"){n({widget:null,error:r.error});return}if(f==="loading"){n({widget:null,error:null});return}var{fetch:p}=r,h=!1;function m(){return g.apply(this,arguments)}function g(){return g=Py(function*(){try{Ze(p);var P=yield p();if(h){He.debug2("loadWidgetInternal cancelled",t,P),P.close(),"exportedObjects"in P&&P.exportedObjects.forEach(v=>{v.close()});return}He.debug("loadWidgetInternal done",t,P),n({widget:P,error:null})}catch(v){if(h)return;He.error("loadWidgetInternal error",t,v),n({widget:null,error:v??new Error("Null error")})}}),g.apply(this,arguments)}return m(),()=>{h=!0}},[t,r]);var l=c.useMemo(()=>{var d;return gr(gr({},e),{},{error:(d=e.error)!==null&&d!==void 0?d:a,api:e.widget!=null?s:null})},[e,s,a]);return l}const wy=Object.freeze(Object.defineProperty({__proto__:null,ApiBootstrap:ql,ApiContext:zt,ClientBootstrap:mi,ClientContext:ru,DeferredApiBootstrap:Qa,DeferredApiContext:Sd,ObjectFetchManagerContext:ct,ObjectFetcherContext:Ti,getVariableDescriptor:Du,isIdVariableDescriptor:Lu,isNameVariableDescriptor:Au,isVariableDescriptor:Fu,sanitizeVariableDescriptor:ji,useApi:ge,useClient:Ae,useDeferredApi:Zt,useObjectFetch:Ja,useObjectFetcher:Nu,useWidget:xy},Symbol.toStringTag,{value:"Module"}));function Oy(t){return function(n){var{children:r}=n;return u.jsx(zt.Provider,{value:t,children:r})}}var Za="io.deephaven.message.LoginOptions.request",eo="io.deephaven.message.SessionDetails.request",to="io.deephaven.broadcast",pn="io.deephaven.broadcast.Login",no="io.deephaven.broadcast.Logout";function ro(t){return et(t)&&t.message===pn}function io(t){return et(t)&&t.message===no}function Sy(t,e,n){return(e=Ey(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ey(t){var e=Cy(t,"string");return typeof e=="symbol"?e:e+""}function Cy(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class ao extends Error{constructor(){super(...arguments),Sy(this,"isNoConsolesError",!0)}}function oo(t){return t.isNoConsolesError}function vr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function dt(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){vr(a,r,i,o,s,"next",l)}function s(l){vr(a,r,i,o,s,"throw",l)}o(void 0)})}}var Te=W.module("SessionUtils");function so(t,e,n){return kt.apply(this,arguments)}function kt(){return kt=dt(function*(t,e,n){Te.info("Getting console types...");var r=yield e.getConsoleTypes();if(r.length===0)throw new ao("No console types available");Te.info("Available types:",r);var i=r[0];Te.info("Starting session with type",i);var a=yield e.startSession(i),o={type:i,id:Bt()};return Te.info("Console session established",o),{session:a,config:o,connection:e,details:n,dh:t}}),kt.apply(this,arguments)}function Ty(t,e,n){return Te.info("createCoreClient",e),new t.CoreClient(e,n)}function jy(t){return t!=null&&typeof t=="object"}function Iy(){return _t.apply(this,arguments)}function _t(){return _t=dt(function*(){var t=yield qt(eo);if(!jy(t))throw new Error("Unexpected session details response: ".concat(t));return t}),_t.apply(this,arguments)}function ky(){return Rt.apply(this,arguments)}function Rt(){return Rt=dt(function*(){var t=new URLSearchParams(window.location.search);switch(t.get("authProvider")){case"parent":return Iy()}return{}}),Rt.apply(this,arguments)}function _y(t,e,n){return Dt.apply(this,arguments)}function Dt(){return Dt=dt(function*(t,e,n){var r;try{r=yield so(t,e,n)}catch(i){if(!oo(i))throw i}return r}),Dt.apply(this,arguments)}const Ry=Object.freeze(Object.defineProperty({__proto__:null,BROADCAST_CHANNEL_NAME:to,BROADCAST_LOGIN_MESSAGE:pn,BROADCAST_LOGOUT_MESSAGE:no,BooleanColumnFormatter:Ed,CharColumnFormatter:Cd,DateTimeColumnFormatter:Mu,DateUtils:Td,DecimalColumnFormatter:$u,DefaultColumnFormatter:jd,FETCH_TIMEOUT:iu,Formatter:en,FormatterUtils:Ct,ITEM_KEY_PREFIX:Id,IntegerColumnFormatter:Uu,LOGIN_OPTIONS_REQUEST:Za,NewTableColumnTypes:Bu,NoConsolesError:ao,SESSION_DETAILS_REQUEST:eo,StringColumnFormatter:kd,TableColumnFormatter:Wu,TableUtils:_d,createComboboxFilterArgs:Rd,createCoreClient:Ty,createFilterConditionFactory:tn,createFormatterFromSettings:Dd,createKeyedItemKey:Ki,createNotNullOrEmptyFilterCondition:zi,createOnTableUpdatedHandler:Ld,createSearchTextFilter:qi,createSelectedValuesFilter:nn,createSessionWrapper:so,createShowOnlyEmptyFilterCondition:Xi,createValueFilter:Qi,defaultRowDeserializer:Ad,fetchVariableDefinition:au,generateEmptyKeyedItems:Fd,getColumnFormats:Nd,getDateTimeFormatterOptions:Md,getSessionDetails:ky,getSize:$d,getWindowParent:Gt,isBroadcastLoginMessage:ro,isBroadcastLogoutMessage:io,isClosed:Ud,isCustomColumnFormatDefined:Bd,isMessage:et,isNoConsolesError:oo,isResponse:Xl,isSortDirection:Wd,loadSessionWrapper:_y,makeMessage:hi,makeResponse:Ql,padFirstAndLastRow:Hd,requestParentResponse:qt},Symbol.toStringTag,{value:"Module"}));function Dy(t,e,n){return(e=Ly(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ly(t){var e=Ay(t,"string");return typeof e=="symbol"?e:e+""}function Ay(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class Fy extends Error{constructor(){super(...arguments),Dy(this,"isColumnNameError",!0)}}function Ny(t,e,n){return(e=My(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function My(t){var e=$y(t,"string");return typeof e=="symbol"?e:e+""}function $y(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class Uy extends Error{constructor(){super(...arguments),Ny(this,"isTableDisconnectError",!0)}}var Ve=W.module("useTable"),lo=(t,e,n,r)=>{var i=ge(),[a,o]=c.useState(void 0),[s,l]=c.useState([]),[d,f]=c.useState(null),[p,h]=c.useState(null);c.useEffect(()=>{if(r===void 0){o(t==null?void 0:t.columns),f(null);return}try{o(t==null?void 0:t.findColumns(r)),f(null)}catch(v){Ve.error("Column not found",v,r),f(new Fy("Invalid columnNames argument"))}},[t,r]),c.useEffect(()=>{if(!a||!t){Ve.debug2("Table or column not initialized, skip viewport update.");return}Ve.debug2("Setting viewport",e,n),t.setViewport(e,n,a)},[a,t,e,n]);var m=c.useCallback(v=>{var{detail:y}=v;if(!a){Ve.error("Columns not initialized.");return}var x=a.map(w=>y.rows.map(j=>j.get(w)));l(x)},[a]),g=c.useCallback(()=>{h(new Uy("Table disconnected"))},[]),P=c.useCallback(()=>{h(null)},[]);return Ke(t,i.Table.EVENT_UPDATED,m),Ke(t,i.Table.EVENT_DISCONNECT,g),Ke(t,i.Table.EVENT_RECONNECT,P),{columns:a,data:s,error:p??d}},uo=(t,e,n,r)=>{var i=c.useMemo(()=>[r],[r]),{columns:a=[],data:o=[],error:s}=lo(t,e,n,i);return{column:a[0],data:o[0],error:s}};function br(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function By(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){br(a,r,i,o,s,"next",l)}function s(l){br(a,r,i,o,s,"throw",l)}o(void 0)})}}var re=W.module("TableInput"),ht=250;function Wy(t){var e,n,{className:r=void 0,columnName:i,settings:a,defaultValue:o=[],isInvalid:s=!1,onChange:l=ne,onBlur:d=ne,table:f}=t,p=c.useRef(null),h=ge(),m=c.useMemo(()=>{var O=Ct.getColumnFormats(a),T=Ct.getDateTimeFormatterOptions(a),{defaultDecimalFormatOptions:_={},defaultIntegerFormatOptions:M={}}=a;return new en(h,O,T,_,M)},[h,a]),[g,P]=c.useState(""),[v,y]=c.useState(new Set(o)),[x,w]=c.useState(),j=c.useRef(null),b=Math.min((e=x==null?void 0:x.size)!==null&&e!==void 0?e:0,ht),{column:S,data:I,error:k}=uo(x,0,ht-1,i),L=c.useCallback(O=>S?m.getFormattedString(O,S.type,S.name):"".concat(O),[S,m]),[F,H]=c.useMemo(()=>{var O=new Set(v),T=[];if(I==null)return[T,null];if(I.forEach(M=>{var J="".concat(M),Se=v.has(J);Se&&O.delete(J),T.push({value:J,displayValue:L(M),isSelected:Se})}),O.size>0){re.debug2("Selection has items that are missing from the viewport");var _=new Set(v);return Array.from(O).forEach(M=>{_.delete(M)}),[T,_]}return[T,null]},[I,v,L]);c.useEffect(()=>{H!==null&&(y(H),l(Array.from(H)))},[l,H]);var E=c.useCallback(function(){var O=By(function*(T){try{var _=yield T;re.debug("Table resolved",_),w(_)}catch(M){if(he.isCanceled(M))return;re.error(M)}});return function(T){return O.apply(this,arguments)}}(),[]);c.useEffect(()=>{var O=he.makeCancelable(f);return E(O),()=>{re.debug2("Cancel table promise"),O.cancel()}},[f,E]);var A=c.useCallback(O=>{var{value:T}=O.target;P(T);var _=F.findIndex(J=>J.displayValue.includes(T));if(_>-1){var M;re.debug2("Found ".concat(T," at index ").concat(_)),(M=j.current)===null||M===void 0||M.scrollIntoView(_)}else re.debug2("".concat(T," not found"))},[F,j]),D=c.useCallback(O=>{if(re.debug("handleSelect",O),O>=F.length){re.error("Invalid index",O);return}var T=F[O].value,_=new Set(v);F[O].isSelected?_.delete(T):_.add(T),y(_),l(Array.from(_))},[l,F,v]),B=c.useCallback(()=>{var O=F.map(_=>_.value),T=new Set(O);y(T),l(O)},[F,l]),Q=c.useCallback(()=>{y(new Set),l([])},[l]),Z=c.useCallback(()=>{},[]),C=c.useCallback(O=>{var T,{relatedTarget:_}=O;re.debug("handleChildBlur",_,_ instanceof HTMLElement,p.current,(T=p.current)===null||T===void 0?void 0:T.contains(_)),(!_||p.current&&_ instanceof HTMLElement&&!p.current.contains(_))&&d()},[d]),R=F.length===0;return u.jsxs("div",{ref:p,className:N("table-input-container d-flex flex-column position-relative",r),children:[u.jsx(Xt,{disabled:!!k||R,value:g,placeholder:"Search",onChange:A,className:"mb-2 d-flex",onBlur:C}),u.jsx(ca,{className:"table-input-list",disabled:x===void 0||R,isInvalid:s,items:R?[{value:"Empty",isSelected:!1}]:F,itemCount:b,offset:0,onSelect:D,onViewportChange:Z,ref:j,onBlur:C}),x&&u.jsxs("div",{className:"meta-row",children:[u.jsx("div",{className:"d-flex align-items-center text-muted small",children:x!=null&&x.size>b&&u.jsxs(u.Fragment,{children:["Table is too large, showing the first ",ht," items."]})}),u.jsxs("div",{children:[u.jsx("button",{type:"button",className:"btn btn-link",onBlur:C,onClick:B,children:"Select All"}),u.jsx("button",{type:"button",className:"btn btn-link mr-a",onBlur:C,onClick:Q,children:"Clear"})]})]}),x==null||k&&u.jsx("div",{className:"h-100 w-100 position-absolute",children:u.jsx(me,{isLoaded:x!=null,isLoading:x==null&&k==null,errorMessage:(n=k==null?void 0:k.message)!==null&&n!==void 0?n:null,"data-testid":"table-input-loading"})})]})}var Hy=["onInputChange","onSearchTextChange"];function Pr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function xr(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Pr(Object(n),!0).forEach(function(r){Vy(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Pr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Vy(t,e,n){return(e=Gy(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Gy(t){var e=Yy(t,"string");return typeof e=="symbol"?e:e+""}function Yy(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Ky(t,e){if(t==null)return{};var n,r,i=zy(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function zy(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function qy(t){var e=Cf(t),{onInputChange:n,onSearchTextChange:r}=e,i=Ky(e,Hy),a=c.useRef(!1),o=c.useRef(""),s=c.useCallback(d=>{n==null||n(d),a.current?r(d):(r(""),o.current=d)},[n,r]),l=c.useCallback((d,f)=>{var p;(p=i.onOpenChange)===null||p===void 0||p.call(i,d),d?f==="input"&&r(o.current):r(""),a.current=d},[r,i]);return u.jsx(Ra,xr(xr({},i),{},{onInputChange:s,onOpenChange:l}))}var Xy=["table","keyColumn","labelColumn","iconColumn","settings"];function wr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Or(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?wr(Object(n),!0).forEach(function(r){Qy(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):wr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Qy(t,e,n){return(e=Jy(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Jy(t){var e=Zy(t,"string");return typeof e=="symbol"?e:e+""}function Zy(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function ev(t,e){if(t==null)return{};var n,r,i=tv(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r<a.length;r++)n=a[r],e.indexOf(n)===-1&&{}.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function tv(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}function nv(t){var e,{table:n,keyColumn:r,labelColumn:i,iconColumn:a,settings:o}=t,s=ev(t,Xy),{scale:l}=rn(),d=la[(e=s.density)!==null&&e!==void 0?e:"regular"][l],{getFormattedString:f}=pa(o),p=Tf({table:n,iconColumnName:a,keyColumnName:r,labelColumnName:i,formatValue:f}),{viewportData:h,onScroll:m}=un({reuseItemsOnTableResize:!0,table:n,itemHeight:d,deserializeRow:p});return u.jsx(Da,Or(Or({},s),{},{normalizedItems:h.items,showItemIcons:a!=null,onScroll:m}))}function rv(t){return typeof t=="object"&&t!=null&&"equals"in t&&typeof t.equals=="function"}function iv(t){return"".concat(t)}function av(t){var{column:e,table:n,filter:r=Pi,onChange:i,selectedValue:a,disabled:o,className:s,formatValue:l=iv,maxSize:d=1e3}=t,f=ge(),[p,h]=c.useState([]);c.useEffect(()=>{if(n==null){h([]);return}var v=e??n.columns[0];n.applyFilter(r);var y=n.setViewport(0,d,[v]);return y.addEventListener(f.Table.EVENT_UPDATED,x=>{var{detail:w}=x,j=w.rows.map(b=>{var S;return(S=b.get(v))!==null&&S!==void 0?S:null});h(j)}),()=>{y.close()}},[e,f,r,d,n]);var m=c.useMemo(()=>a===void 0?[void 0,...p]:p,[a,p]),g=c.useMemo(()=>m.findIndex(v=>v===a||rv(v)&&v.equals(a)),[a,m]),P=c.useCallback(v=>{var y=parseInt(v,10);i(m[y])},[i,m]);return u.jsx(Oi,{className:s,value:g,onChange:P,disabled:o,children:m.map((v,y)=>u.jsx(ua,{value:y,children:l(v)},"".concat(y)))})}var Sr=W.module("useBroadcastChannel");function fn(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ne,e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:to,n=c.useMemo(()=>new BroadcastChannel(e),[e]);return c.useEffect(()=>()=>{n.close()},[n]),c.useEffect(()=>{function r(i){var{data:a}=i;if(!et(a)){Sr.debug("Ignoring non-deephaven message",a);return}Sr.debug("event received",a),t(i)}return n.addEventListener("message",r),()=>{n.removeEventListener("message",r)}},[n,t]),n}function hn(t,e){var n=c.useCallback(r=>{ro(r.data)?t==null||t(r.data):io(r.data)&&(e==null||e(r.data))},[t,e]);fn(n)}function ov(t,e,n,r){var i=de(),[a,o]=c.useState(""),{value:s}=Ne(a,n),l=c.useCallback(h=>{o(h.trim())},[]),{data:d,isLoading:f}=Oe(i.doesColumnValueExist,[t,e,s,r]),p=f||a!==s?null:d;return{valueTrimmed:a,valueTrimmedDebounced:s,valueExists:p,trimAndUpdateValue:l}}var Er=W.module("useDebouncedViewportSearch"),sv=200;function lv(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:sv,r=de(),{table:i,applyFiltersAndRefresh:a}=t,o=c.useMemo(()=>je(s=>{if(Er.debug("Applying debounced searchText '".concat(s,"'")),i!=null){var l=s.trim();if(l===""){a([]);return}var d=i.findColumn(e),f=r.makeFilterValue(d.type,l),p=[d.filter().contains(f)];a(p)}},n),[a,e,n,i,r]);return c.useEffect(()=>()=>{Er.debug("Cancelling debounced search function"),o.cancel()},[o]),o}var co=300;function uv(t){var{viewportData:e,columnName:n,shouldSelectAllOnNoSelection:r,mapItemToValue:i}=t,a=de(),o=Ea(e,i,Ki),{value:s}=Ne(o,co),l=Oa(s,ba);return c.useMemo(()=>nn(a,n,l.selection,r,l.isInverted),[n,l,r,a])}function cv(t,e,n,r){var i=c.useRef("");return i.current=n,c.useMemo(()=>{var a=t.length>0&&t[0].item==null;return!a&&r!=null&&(i.current===""||r.toLowerCase().includes(i.current.toLowerCase()))?[{key:r,item:{[e]:r}},...t]:t},[r,e,t])}function Cr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function dv(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Cr(a,r,i,o,s,"next",l)}function s(l){Cr(a,r,i,o,s,"throw",l)}o(void 0)})}}function pv(t){var{table:e,columnName:n,defaultValue:r,itemHeight:i,topOffset:a=0,value:o}=t;return c.useCallback(dv(function*(){if(e==null||o===""||o===r)return a;var s=e.findColumn(n),l=yield e.seekRow(0,s,"String",o),d=r==null?0:1;return(l+d)*i+a}),[n,r,i,e,a,o])}function fv(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"or",n=de(),r=c.useMemo(()=>zi(n),[n]);return c.useMemo(()=>tn(t,r,e),[t,e,r])}function hv(t){var{maybeTable:e,columnName:n,mapItemToValue:r,filterConditionFactories:i=[],trimSearchText:a=!1,timeZone:o}=t,{itemHeight:s}=da(),l=de(),[d,f]=c.useState(""),[p,h]=c.useState(""),m=c.useCallback(O=>{h(a?O.trim():O)},[a]),g=c.useMemo(()=>a?d.trim():d,[d,a]),[P,v]=c.useState(null),[y,x]=c.useState(()=>new Map),{data:w,isLoading:j}=Oe(l.doesColumnValueExist,[e,n,p,!1]),{isDebouncing:b}=Ne(p,En),S=b||j?null:w,I=c.useMemo(()=>qi(l,n,p,o),[p,n,l,o]),k=c.useMemo(()=>nn(l,n,new Set(y.keys()),!1,!0),[n,y,l]),{data:L}=Oe(l.createDistinctSortedColumnTable,[e,n,"asc",...i]);fa(L);var F=un({table:L,itemHeight:s,viewportSize:jf,viewportPadding:If}),H=g.length>0&&F.size===0,E=y.has(g),A=Ie(m,En),D=c.useCallback(O=>{f(O),A(O)},[A]),B=Ie(v,0),Q=c.useCallback(O=>{if(f(""),m(""),v(O),B(null),O!=null){var T=F.viewportData.findItem(O);if(T!=null){var _=r(T);x(M=>{var J=new Map(M);return J.set(_,{value:_}),J})}}},[m,B,F.viewportData,r]),Z=c.useCallback(O=>{x(T=>{if(O.size===0)return T;var _=new Map(T);for(var M of O)_.set(M,{value:M});return _})},[]),C=c.useCallback(O=>{x(T=>{if(O==="all")return new Map;var _=new Map(T);for(var M of O)_.delete(M);return _})},[]),R=ha(F.table,I,k);return ma(F,R),c.useMemo(()=>({list:F,hasSearchTextWithZeroResults:H,searchText:d,searchTextExists:S,searchTextIsInSelectedValues:E,selectedKey:P,selectedValueMap:y,onSearchTextChange:D,onSelectKey:Q,onAddValues:Z,onRemoveValues:C}),[H,F,Z,C,D,Q,d,S,E,P,y])}function Tr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function mv(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Tr(a,r,i,o,s,"next",l)}function s(l){Tr(a,r,i,o,s,"throw",l)}o(void 0)})}}function gv(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];var i=c.useCallback(mv(function*(){var d;return(d=t==null?void 0:t.selectDistinct(t.findColumns(n)))!==null&&d!==void 0?d:null}),[t,...n]),{data:a,error:o,isError:s,isLoading:l}=Oe(i,[]);return c.useEffect(()=>()=>{a==null||a.close()},[a]),{distinctTable:a,error:o,isError:s,isLoading:l}}function yv(t,e){var n=de(),r=c.useMemo(()=>Xi(n,t),[t,n]);return c.useMemo(()=>tn(e,r),[e,r])}function vv(t,e,n){var r=de();return c.useMemo(()=>Qi(r,t,e,n),[t,n,r,e])}const bv=Object.freeze(Object.defineProperty({__proto__:null,ComboBox:qy,DEBOUNCE_MS:co,ListView:nv,Picker:kf,TableDropdown:av,TableInput:Wy,makeApiContextWrapper:Oy,useBroadcastChannel:fn,useBroadcastLoginListener:hn,useCheckIfExistsValue:ov,useDebouncedViewportSearch:lv,useDebouncedViewportSelectionFilter:uv,useFilterConditionFactories:ha,useFilteredItemsWithDefaultValue:cv,useFormatter:pa,useGetItemIndexByValue:_f,useGetItemPosition:pv,useInitializeViewportData:Rf,useNotNullOrEmptyFilter:fv,usePickerWithSelectedValues:hv,useSearchableViewportData:Df,useSelectDistinctTable:gv,useSetPaddedViewportCallback:Lf,useShowOnlyEmptyFilter:yv,useTable:lo,useTableClose:Af,useTableColumn:uo,useTableListener:Ke,useTableSize:Ff,useTableUtils:de,useValueFilter:vv,useViewportData:un,useViewportFilter:ma,useWidgetClose:fa},Symbol.toStringTag,{value:"Module"}));var mn=c.createContext(!1);mn.displayName="FontsLoadedContext";function Pv(t){var{fontClassNames:e=["fira-sans-regular","fira-sans-semibold","fira-mono"],children:n}=t,[r,i]=c.useState(!1);return c.useEffect(function(){document.fonts.ready.then(()=>{i(!0)})},[]),u.jsxs(u.Fragment,{children:[u.jsx(mn.Provider,{value:r,children:n}),u.jsx("div",{id:"preload-fonts",style:{visibility:"hidden",position:"absolute",top:-1e4},children:e.map(a=>u.jsx("p",{className:a,children:"preload"},a))})]})}function po(t){var{isEnabled:e,isPending:n,themeData:r}=_a();return c.useMemo(()=>e?n?null:r?[r]:[]:t==null?null:Ii(t),[e,n,r,t])}function xv(t){var{fetch:e,type:n}=t,r=Qt(),i=c.useMemo(()=>[...r.values()].filter(ki).find(o=>[o.supportedTypes].flat().includes(n)),[r,n]);if(i!=null){var a=i.component;return u.jsx(a,{fetch:e})}throw new Error("Unknown widget type '".concat(n,"'"))}function wv(){var t=Qt(),e=c.useMemo(()=>_i(t),[t]);return e}const Ov=Object.freeze(Object.defineProperty({__proto__:null,PersistentStateContext:Hu,PersistentStateProvider:Vu,PluginType:Ri,PluginsContext:st,WidgetView:xv,getDashboardPlugins:ou,getIconForPlugin:Gu,getPluginsElementMap:_i,getThemeDataFromPlugins:Ii,isAuthPlugin:Di,isDashboardPlugin:Yu,isElementPlugin:Ku,isLegacyAuthPlugin:St,isLegacyDashboardPlugin:zu,isLegacyPlugin:Li,isLegacyTablePlugin:qu,isPlugin:Et,isTablePlugin:Xu,isThemePlugin:Qu,isWidgetPlugin:ki,pluginSupportsType:Ju,useCustomThemes:po,useDashboardPlugins:su,usePersistentState:Vd,usePlugins:Qt,usePluginsElementMap:wv},Symbol.toStringTag,{value:"Module"}));function Sv(t){if(t==null)return!1;var e=t;return e.Component!==void 0&&typeof e.isAvailable=="function"}var fo="io.deephaven.auth.AnonymousAuthenticationHandler",Ev="io.deephaven.authentication.psk.PskAuthenticationHandler";function jr(t,e,n){return(e=Cv(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Cv(t){var e=Tv(t,"string");return typeof e=="symbol"?e:e+""}function Tv(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class ho extends Error{constructor(){super(...arguments),jr(this,"name","AuthenticationError"),jr(this,"isAuthenticationError",!0)}}function Ir(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function jv(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Ir(a,r,i,o,s,"next",l)}function s(l){Ir(a,r,i,o,s,"throw",l)}o(void 0)})}}var kr=W.module("AuthPluginBase");function gn(t){var{children:e,getLoginOptions:n}=t,r=Ae(),[i,a]=c.useState(),[o,s]=c.useState(!1);return c.useEffect(()=>{var l=!1;function d(){if(l)throw new Ai("Login canceled.")}function f(){return p.apply(this,arguments)}function p(){return p=jv(function*(){try{var h=yield n();d(),kr.info("Logging in..."),yield r.login(h),d(),s(!0)}catch(P){if(!l){var m;kr.error("Unable to login:",P);var g=(m=ke(P))!==null&&m!==void 0?m:"Unable to login. Verify credentials.";a(new ho(g)),s(!1)}}}),p.apply(this,arguments)}return f(),()=>{l=!0}},[r,n]),o?u.jsx(u.Fragment,{children:e}):u.jsx(me,{"data-testid":"auth-base-loading",isLoading:i==null,isLoaded:!1,errorMessage:ke(i)})}var Iv={canLogout:!1};function kv(t){var{children:e}=t,n=ge(),r=c.useCallback(()=>({type:n.CoreClient.LOGIN_TYPE_ANONYMOUS}),[n]);return u.jsx(gn,{getLoginOptions:r,children:u.jsx(nt.Provider,{value:Iv,children:e})})}var mo={Component:kv,isAvailable:t=>t.includes(fo)};function _r(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function _v(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){_r(a,r,i,o,s,"next",l)}function s(l){_r(a,r,i,o,s,"throw",l)}o(void 0)})}}var Rv=W.module("AuthPluginParent"),Dv={canLogout:!1};function Lv(t){return t!=null&&typeof t.type=="string"}function Av(){return Lt.apply(this,arguments)}function Lt(){return Lt=_v(function*(){Rv.info("Logging in by delegating to parent window...");var t=yield qt(Za);if(!Lv(t))throw new Error("Unexpected login options response: ".concat(t));return t}),Lt.apply(this,arguments)}function Fv(){var t;return(t=new URLSearchParams(window.location.search).get("authProvider"))!==null&&t!==void 0?t:""}function Nv(t){var{children:e}=t;return u.jsx(gn,{getLoginOptions:Av,children:u.jsx(nt.Provider,{value:Dv,children:e})})}var go={Component:Nv,isAvailable:()=>Gt()!=null&&Fv()==="parent"};function yo(t){var{children:e,errorMessage:n,isLoggingIn:r=!1,onSubmit:i}=t;return u.jsxs("form",{className:"login-form",onSubmit:a=>{a.preventDefault(),a.stopPropagation(),i==null||i(a)},children:[u.jsx("div",{className:"flex-spacer"}),u.jsxs("div",{className:"flex-wrapper",children:[u.jsx("fieldset",{disabled:r,className:"container-fluid",children:e}),u.jsx("div",{className:"form-group d-flex justify-content-end align-items-center mb-0",children:u.jsxs("button",{type:"submit",className:N("btn btn-primary",{"btn-spinner":r},{"btn-cancelable":r}),"data-testid":"btn-login",children:[r&&u.jsxs("span",{children:[u.jsx(Je,{className:"mr-2 loading-spinner-vertical-align"}),u.jsx("span",{className:"btn-normal-content",children:"Logging in"}),u.jsx("span",{className:"btn-hover-content",children:"Cancel"})]}),!r&&"Login"]})})]}),u.jsx("div",{className:"flex-spacer",children:n!=null&&u.jsx("p",{className:"error-message mb-0",role:"alert",children:"".concat(n)})})]})}function vo(t){var{children:e,logoPath:n="./logo.png"}=t;return u.jsxs("div",{className:"login-container",children:[u.jsx(Ka,{}),u.jsxs("div",{className:"login-box",children:[u.jsx("div",{className:"logo",children:u.jsx("img",{src:n,alt:"Deephaven Data Labs"})}),e,u.jsxs("p",{className:"footer",children:["© 2016-",new Date().getFullYear()," Deephaven Data Labs LLC. Patent Pending."]})]})]})}function Rr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function mt(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Rr(a,r,i,o,s,"next",l)}function s(l){Rr(a,r,i,o,s,"throw",l)}o(void 0)})}}var At="io.deephaven.authentication.psk.PskAuthenticationHandler",bo="psk",Ft="io.deephaven.web.client.auth.psk.token",be=W.module("AuthPluginPsk");function Mv(){return new URLSearchParams(window.location.search).get(bo)}function $v(){be.debug2("clearWindowToken");var t=new URL(window.location.href);t.searchParams.delete(bo),window.history.replaceState(null,"",t.href)}function Dr(){var t;return(t=Pt.get(Ft))!==null&&t!==void 0?t:null}function gt(t){be.debug2("Storing token in cookie",t),t!=null?Pt.set(Ft,t,{secure:!0,sameSite:"strict"}):Pt.remove(Ft)}function Uv(t){var{children:e,logoPath:n}=t,r=Ae(),i=c.useRef(null),a=c.useRef(null),[o,s]=c.useState(),[l,d]=c.useState(!1),[f,p]=c.useState(!1),[h,m]=c.useState(!1),[g,P]=c.useState(""),v=c.useCallback(function(){var b=mt(function*(S){var I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;be.info("Logging in..."),m(!0);var k=null;try{if(k=r.login({type:At,token:S}),a.current=k,yield k,be.info("Logged in successfully"),a.current!==k)return;gt(S),p(!0)}catch(H){if(a.current!==k)return;if(d(!0),I){var L;be.error("Unable to login",H);var F=(L=ke(H))!==null&&L!==void 0?L:"Unable to login: Verify credentials.";s(new ho(F))}}m(!1)});return function(S){return b.apply(this,arguments)}}(),[r]),y=c.useCallback(()=>{a.current=null,m(!1)},[]),x=c.useCallback(mt(function*(){be.debug("onLogin");var b=Dr();f||h||b==null||v(b,!1)}),[f,h,v]),w=c.useCallback(()=>{gt(null)},[]);hn(x,w),c.useEffect(()=>{var b=!1;function S(){return I.apply(this,arguments)}function I(){return I=mt(function*(){var k,L=(k=Mv())!==null&&k!==void 0?k:Dr();if($v(),L==null){d(!0);return}m(!0);try{yield r.login({type:At,token:L}),b||(gt(L),p(!0),m(!1))}catch{b||(d(!0),m(!1))}}),I.apply(this,arguments)}return S(),()=>{b=!0}},[r]);var j=c.useCallback(()=>{h?y():v(g)},[y,h,v,g]);return c.useEffect(function(){var S;(S=i.current)===null||S===void 0||S.focus()},[i,l]),u.jsxs(u.Fragment,{children:[f&&e,l&&u.jsx(Jt,{in:!f,mountOnEnter:!0,unmountOnExit:!0,children:u.jsx(vo,{logoPath:n,children:u.jsx(yo,{errorMessage:ke(o),isLoggingIn:h,onSubmit:j,children:u.jsxs("div",{className:"form-group",children:[u.jsx("label",{htmlFor:"auth-psk-token-input",children:"Token"}),u.jsx("input",{id:"auth-psk-token-input",name:"token",className:"input-token form-control",type:"text",autoComplete:"username",autoCapitalize:"none",autoCorrect:"off",spellCheck:"false",ref:i,value:g,onChange:b=>{s(void 0),P(b.target.value)}})]})})})}),u.jsx(me,{"data-testid":"auth-psk-loading",isLoaded:f||l,isLoading:!f&&!l})]})}var Po={Component:Uv,isAvailable:t=>t.includes(At)};function Lr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function yt(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Lr(Object(n),!0).forEach(function(r){Bv(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Lr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Bv(t,e,n){return(e=Wv(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Wv(t){var e=Hv(t,"string");return typeof e=="symbol"?e:e+""}function Hv(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Vv=W.module("UserUtils");function xo(t,e){return t.get("internal.webClient.appInit.".concat(e))}function wo(t){var e,n,r,i,a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};function s(v){return xo(t,v)}function l(v,y){var x=s(v);return x==="true"?!0:x==="false"?!1:(x!==void 0&&Vv.warn("Unexpected value for ".concat(v,": ").concat(x)),y)}var d=(e=s("name"))!==null&&e!==void 0?e:"",f=(n=s("operateAs"))!==null&&n!==void 0?n:d,p=(r=(i=s("groups"))===null||i===void 0?void 0:i.split(","))!==null&&r!==void 0?r:[],h=l("canCopy",!0),m=l("canDownloadCsv",!0),g=l("canUsePanels",!0),P=l("canLogout",!0);return yt(yt({name:d,operateAs:f,groups:p},a),{},{permissions:yt({canUsePanels:g,canCopy:h,canDownloadCsv:m,canLogout:P},o)})}const Gv=Object.freeze(Object.defineProperty({__proto__:null,AUTH_HANDLER_TYPE_ANONYMOUS:fo,AUTH_HANDLER_TYPE_PSK:Ev,AuthPluginAnonymous:mo,AuthPluginBase:gn,AuthPluginParent:go,AuthPluginPsk:Po,Login:vo,LoginForm:yo,UserContext:gi,UserOverrideContext:yi,UserPermissionsOverrideContext:nt,getAppInitValue:xo,getUserFromConfig:wo,isAuthPlugin:Sv},Symbol.toStringTag,{value:"Module"}));function xe(t,e,n){return(e=Yv(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Yv(t){var e=Kv(t,"string");return typeof e=="symbol"?e:e+""}function Kv(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class $ extends Ji{static get theme(){return $._theme==null&&($._theme=Fi()),$._theme}static makeRandomSeries(e){for(var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:100,i=[],a=[],o=[],s=[],l=new Date("2018-06-01"),d=0;d<r;d+=1){var f=new Date(l.getFullYear(),l.getMonth(),l.getDate()+d-r);i.push("".concat(f.getFullYear(),"-").concat(f.getMonth()+1,"-").concat(f.getDate()));var p=(Math.sin(d/r*e)*r/3+Math.cos(d*.2)*r/6+Math.sin(d*.5)*r/10+$.random()*r/5+d*$.smoothing)*n;p=Math.round(p*100)/100,a.push(p),s.push(40+d*$.smoothing),o.push(Math.sin(d/r*e)*r/3+$.random()*r/10+d*$.smoothing)}return{x:i,y:a,s:o,l:s}}static makeScatter(e){return{name:"SCTR",x:e.x,y:e.y,type:"scatter",mode:"markers",hoverinfo:"skip",marker:{size:5}}}static makeArea(e){return{name:"AREA",x:e.x,y:e.s,type:"scatter",mode:"line",fill:"tozeroy",hoverinfo:"all",line:{width:3}}}static makeTrendline(e){return{name:"Trendline <br>R<sup>2</sup> = 0.91",x:e.x,y:e.l,type:"scatter",mode:"line",hoverinfo:"skip",line:{width:3,dash:"dot"}}}static makeErrorBand(e){for(var n=[],r=[],i=0;i<e.y.length;i+=1){var a=e.y[i];n[i]=Math.round((a+18)*100)/100,r[i]=Math.round((a-18)*100)/100}var o=n.concat(r.reverse());return{name:"error",x:e.x.concat(e.x.slice().reverse()),y:o,type:"scatter",mode:"line",hoverinfo:"skip",fill:"toself",line:{width:0,color:$.theme.error_band_line_color,shape:"spline"}}}static makeLine(e){return{name:"LINE",x:e.x,y:e.y,type:"scatter",mode:"line",hoverinfo:"x+y+text+name",line:{width:3}}}static makeRandomData(){var e=$.makeRandomSeries(6),n=$.makeArea(e),r=$.makeTrendline(e),i=$.makeRandomSeries(2),a=$.makeLine(i),o=$.makeErrorBand(i);return[n,r,a,o]}static makeDefaultLayout(e){var n={template:new Zi(e).makeDefaultTemplate($.theme)};return n.title={text:"Chart"},n.xaxis={title:{text:"Datestamp"}},n.yaxis={title:{text:"Price"}},n}constructor(e){var{data:n=$.makeRandomData(),layout:r=$.makeDefaultLayout(e),filterFields:i=[]}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};super(e),xe(this,"data",void 0),xe(this,"filterFields",void 0),xe(this,"layout",void 0),this.data=n,this.layout=r,this.filterFields=i}getData(){return this.data}getLayout(){return this.layout}getFilterColumnMap(){for(var e=new Map,n=0;n<this.filterFields.length;n+=1){var r=this.filterFields[n],i="java.lang.String";e.set(r,{name:r,type:i})}return e}isFilterRequired(){return this.filterFields.length>0}setFilter(){this.fireUpdate(this.data)}}xe($,"random",Math.random.bind(Math));xe($,"smoothing",1.5);xe($,"_theme",void 0);const zv=Object.freeze(Object.defineProperty({__proto__:null,Chart:Gd,ChartModel:Ji,ChartModelFactory:Yd,ChartThemeContext:Zu,ChartThemeProvider:Ni,ChartUtils:Zi,DownsamplingError:Sp,FigureChartModel:Kd,MockChartModel:$,Plot:ec,defaultChartTheme:Fi,isFigureChartModel:zd,isWebGLSupported:qd,useChartTheme:tc},Symbol.toStringTag,{value:"Module"}));function qv(t){var{dashboardProps:e,componentName:n,component:r,supportedTypes:i,hydrate:a,dehydrate:o}=t,{id:s,layout:l,registerComponent:d}=e,f=c.useCallback(p=>{var{dragEvent:h,panelId:m=Bt(),widget:g}=p,{name:P,type:v}=g,y=v!=null&&(Array.isArray(i)&&i.includes(v)||v===i);if(y){var x={localDashboardId:s,metadata:g};a!=null&&(x=a(x,s));var w={type:"react-component",component:n,props:x,title:P??void 0,id:m},{root:j}=l;Mi.openComponent({root:j,config:w,dragEvent:h})}},[n,a,s,l,i]);ea(d,r,a,o),$i(l.eventHub,f)}function Xv(t,e){var n=Ws(),r=Hs(a=>Ui(a,t,e)),i=c.useCallback(a=>n(Bi(t,e,a)),[t,e,n]);return[r,i]}const Qv=Object.freeze(Object.defineProperty({__proto__:null,BasePanel:wn,CLOSE_DASHBOARD:nc,CREATE_DASHBOARD:rc,DEFAULT_DASHBOARD_ID:ic,DH_ID_PROP:ac,Dashboard:Pn,DashboardIdContext:oc,DashboardLayout:sc,DashboardUtils:lc,GLPropTypes:uc,LayoutManagerContext:cc,LayoutUtils:Mi,LazyDashboard:lu,Panel:wn,PanelErrorBoundary:dc,PanelEvent:pc,PanelIdContext:fc,PanelManager:hc,SET_DASHBOARD_DATA:mc,TabEvent:gc,assertIsDashboardPluginProps:Xd,canHaveRef:Ei,default:Pn,dehydrate:yc,emitCloseDashboard:vc,emitCreateDashboard:bc,emitCycleToNextStack:Pc,emitCycleToNextTab:xc,emitCycleToPreviousStack:wc,emitCycleToPreviousTab:Oc,emitPanelOpen:Sc,getAllDashboardsData:Ec,getClosedPanelsForDashboard:Cc,getDashboardData:Tc,getOpenedPanelMapForDashboard:jc,getPluginDataForDashboard:Ui,getPluginDataMapForDashboard:Ic,hydrate:kc,isDashboardPluginProps:Qd,isWrappedComponent:Ci,listenForCloseDashboard:_c,listenForCreateDashboard:Rc,listenForCycleToNextStack:Dc,listenForCycleToNextTab:Lc,listenForCycleToPreviousStack:Ac,listenForCycleToPreviousTab:Fc,listenForPanelOpen:Nc,reducers:Mc,setDashboardData:$c,setDashboardPluginData:Bi,updateDashboardData:Uc,useAppDispatch:Bc,useAppSelector:Wi,useAppStore:Wc,useCloseDashboardListener:Hc,useCreateDashboardListener:Vc,useCycleToNextStackListener:Gc,useCycleToNextTabListener:Yc,useCycleToPreviousStackListener:Kc,useCycleToPreviousTabListener:zc,useDashboardId:qc,useDashboardPanel:qv,useDashboardPluginData:Xv,useDhId:Xc,useLayoutManager:Jd,useListener:Qc,usePanelId:Jc,usePanelOpenListener:$i,usePanelRegistration:ea},Symbol.toStringTag,{value:"Module"}));function Oo(t){var{children:e}=t,{activeThemes:n}=rt();return c.useEffect(function(){n!=null&&Hi.initTheme()},[n]),u.jsx(u.Fragment,{children:e})}var Jv={$schema:"http://json-schema.org/draft-07/schema#",title:"Options",type:"object",properties:{"allowed-confusables":{description:'A list of allowed "confusable" Unicode characters to ignore when enforcing `RUF001`, `RUF002`, and `RUF003`.',deprecated:!0,type:["array","null"],items:{type:"string",maxLength:1,minLength:1}},builtins:{description:"A list of builtins to treat as defined references, in addition to the system builtins.",type:["array","null"],items:{type:"string"}},"cache-dir":{description:"A path to the cache directory.\n\nBy default, Ruff stores cache results in a `.ruff_cache` directory in the current project root.\n\nHowever, Ruff will also respect the `RUFF_CACHE_DIR` environment variable, which takes precedence over that default.\n\nThis setting will override even the `RUFF_CACHE_DIR` environment variable, if set.",type:["string","null"]},"dummy-variable-rgx":{description:'A regular expression used to identify "dummy" variables, or those which should be ignored when enforcing (e.g.) unused-variable rules. The default expression matches `_`, `__`, and `_var`, but not `_var_`.',deprecated:!0,type:["string","null"]},exclude:{description:"A list of file patterns to exclude from formatting and linting.\n\nExclusions are based on globs, and can be either:\n\n- Single-path patterns, like `.mypy_cache` (to exclude any directory named `.mypy_cache` in the tree), `foo.py` (to exclude any file named `foo.py`), or `foo_*.py` (to exclude any file matching `foo_*.py` ). - Relative patterns, like `directory/foo.py` (to exclude that specific file) or `directory/*.py` (to exclude any Python files in `directory`). Note that these paths are relative to the project root (e.g., the directory containing your `pyproject.toml`).\n\nFor more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).\n\nNote that you'll typically want to use [`extend-exclude`](#extend-exclude) to modify the excluded paths.",type:["array","null"],items:{type:"string"}},"explicit-preview-rules":{description:"Whether to require exact codes to select preview rules. When enabled, preview rules will not be selected by prefixes — the full code of each preview rule will be required to enable the rule.",deprecated:!0,type:["boolean","null"]},extend:{description:"A path to a local `pyproject.toml` file to merge into this configuration. User home directory and environment variables will be expanded.\n\nTo resolve the current `pyproject.toml` file, Ruff will first resolve this base configuration file, then merge in any properties defined in the current configuration file.",type:["string","null"]},"extend-exclude":{description:"A list of file patterns to omit from formatting and linting, in addition to those specified by [`exclude`](#exclude).\n\nExclusions are based on globs, and can be either:\n\n- Single-path patterns, like `.mypy_cache` (to exclude any directory named `.mypy_cache` in the tree), `foo.py` (to exclude any file named `foo.py`), or `foo_*.py` (to exclude any file matching `foo_*.py` ). - Relative patterns, like `directory/foo.py` (to exclude that specific file) or `directory/*.py` (to exclude any Python files in `directory`). Note that these paths are relative to the project root (e.g., the directory containing your `pyproject.toml`).\n\nFor more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).",type:["array","null"],items:{type:"string"}},"extend-fixable":{description:"A list of rule codes or prefixes to consider fixable, in addition to those specified by [`fixable`](#lint_fixable).",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-ignore":{description:"A list of rule codes or prefixes to ignore, in addition to those specified by `ignore`.",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-include":{description:"A list of file patterns to include when linting, in addition to those specified by [`include`](#include).\n\nInclusion are based on globs, and should be single-path patterns, like `*.pyw`, to include any file with the `.pyw` extension.\n\nFor more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).",type:["array","null"],items:{type:"string"}},"extend-per-file-ignores":{description:"A list of mappings from file pattern to rule codes or prefixes to exclude, in addition to any rules excluded by [`per-file-ignores`](#lint_per-file-ignores).",deprecated:!0,type:["object","null"],additionalProperties:{type:"array",items:{$ref:"#/definitions/RuleSelector"}}},"extend-safe-fixes":{description:"A list of rule codes or prefixes for which unsafe fixes should be considered safe.",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-select":{description:"A list of rule codes or prefixes to enable, in addition to those specified by [`select`](#lint_select).",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-unfixable":{description:"A list of rule codes or prefixes to consider non-auto-fixable, in addition to those specified by [`unfixable`](#lint_unfixable).",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-unsafe-fixes":{description:"A list of rule codes or prefixes for which safe fixes should be considered unsafe.",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},external:{description:"A list of rule codes or prefixes that are unsupported by Ruff, but should be preserved when (e.g.) validating `# noqa` directives. Useful for retaining `# noqa` directives that cover plugins not yet implemented by Ruff.",deprecated:!0,type:["array","null"],items:{type:"string"}},fix:{description:"Enable fix behavior by-default when running `ruff` (overridden by the `--fix` and `--no-fix` command-line flags). Only includes automatic fixes unless `--unsafe-fixes` is provided.",type:["boolean","null"]},"fix-only":{description:"Like [`fix`](#fix), but disables reporting on leftover violation. Implies [`fix`](#fix).",type:["boolean","null"]},fixable:{description:"A list of rule codes or prefixes to consider fixable. By default, all rules are considered fixable.",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"flake8-annotations":{description:"Options for the `flake8-annotations` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8AnnotationsOptions"},{type:"null"}]},"flake8-bandit":{description:"Options for the `flake8-bandit` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8BanditOptions"},{type:"null"}]},"flake8-boolean-trap":{description:"Options for the `flake8-boolean-trap` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8BooleanTrapOptions"},{type:"null"}]},"flake8-bugbear":{description:"Options for the `flake8-bugbear` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8BugbearOptions"},{type:"null"}]},"flake8-builtins":{description:"Options for the `flake8-builtins` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8BuiltinsOptions"},{type:"null"}]},"flake8-comprehensions":{description:"Options for the `flake8-comprehensions` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8ComprehensionsOptions"},{type:"null"}]},"flake8-copyright":{description:"Options for the `flake8-copyright` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8CopyrightOptions"},{type:"null"}]},"flake8-errmsg":{description:"Options for the `flake8-errmsg` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8ErrMsgOptions"},{type:"null"}]},"flake8-gettext":{description:"Options for the `flake8-gettext` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8GetTextOptions"},{type:"null"}]},"flake8-implicit-str-concat":{description:"Options for the `flake8-implicit-str-concat` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8ImplicitStrConcatOptions"},{type:"null"}]},"flake8-import-conventions":{description:"Options for the `flake8-import-conventions` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8ImportConventionsOptions"},{type:"null"}]},"flake8-pytest-style":{description:"Options for the `flake8-pytest-style` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8PytestStyleOptions"},{type:"null"}]},"flake8-quotes":{description:"Options for the `flake8-quotes` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8QuotesOptions"},{type:"null"}]},"flake8-self":{description:"Options for the `flake8_self` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8SelfOptions"},{type:"null"}]},"flake8-tidy-imports":{description:"Options for the `flake8-tidy-imports` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8TidyImportsOptions"},{type:"null"}]},"flake8-type-checking":{description:"Options for the `flake8-type-checking` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8TypeCheckingOptions"},{type:"null"}]},"flake8-unused-arguments":{description:"Options for the `flake8-unused-arguments` plugin.",deprecated:!0,anyOf:[{$ref:"#/definitions/Flake8UnusedArgumentsOptions"},{type:"null"}]},"force-exclude":{description:"Whether to enforce [`exclude`](#exclude) and [`extend-exclude`](#extend-exclude) patterns, even for paths that are passed to Ruff explicitly. Typically, Ruff will lint any paths passed in directly, even if they would typically be excluded. Setting `force-exclude = true` will cause Ruff to respect these exclusions unequivocally.\n\nThis is useful for [`pre-commit`](https://pre-commit.com/), which explicitly passes all changed files to the [`ruff-pre-commit`](https://github.com/astral-sh/ruff-pre-commit) plugin, regardless of whether they're marked as excluded by Ruff's own settings.",type:["boolean","null"]},format:{description:"Options to configure code formatting.",anyOf:[{$ref:"#/definitions/FormatOptions"},{type:"null"}]},ignore:{description:"A list of rule codes or prefixes to ignore. Prefixes can specify exact rules (like `F841`), entire categories (like `F`), or anything in between.\n\nWhen breaking ties between enabled and disabled rules (via `select` and `ignore`, respectively), more specific prefixes override less specific prefixes.",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"ignore-init-module-imports":{description:"Avoid automatically removing unused imports in `__init__.py` files. Such imports will still be flagged, but with a dedicated message suggesting that the import is either added to the module's `__all__` symbol, or re-exported with a redundant alias (e.g., `import os as os`).\n\nThis option is enabled by default, but you can opt-in to removal of imports via an unsafe fix.",deprecated:!0,type:["boolean","null"]},include:{description:"A list of file patterns to include when linting.\n\nInclusion are based on globs, and should be single-path patterns, like `*.pyw`, to include any file with the `.pyw` extension. `pyproject.toml` is included here not for configuration but because we lint whether e.g. the `[project]` matches the schema.\n\nNotebook files (`.ipynb` extension) are included by default on Ruff 0.6.0+.\n\nFor more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).",type:["array","null"],items:{type:"string"}},"indent-width":{description:`The number of spaces per indentation level (tab).
4
4
 
5
5
  Used by the formatter and when enforcing long-line violations (like \`E501\`) to determine the visual width of a tab.
6
6
 
@@ -80,5 +80,5 @@ foo, bar, quux = this_is_a_long_line(lion, hippo, lemur, bear) ''' pass \`\`\`
80
80
 
81
81
  ( foo, bar, quux, ) = this_is_a_long_line( lion, hippo, lemur, bear, ) """ pass \`\`\``,anyOf:[{$ref:"#/definitions/DocstringCodeLineWidth"},{type:"null"}]},exclude:{description:"A list of file patterns to exclude from formatting in addition to the files excluded globally (see [`exclude`](#exclude), and [`extend-exclude`](#extend-exclude)).\n\nExclusions are based on globs, and can be either:\n\n- Single-path patterns, like `.mypy_cache` (to exclude any directory named `.mypy_cache` in the tree), `foo.py` (to exclude any file named `foo.py`), or `foo_*.py` (to exclude any file matching `foo_*.py` ). - Relative patterns, like `directory/foo.py` (to exclude that specific file) or `directory/*.py` (to exclude any Python files in `directory`). Note that these paths are relative to the project root (e.g., the directory containing your `pyproject.toml`).\n\nFor more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).",type:["array","null"],items:{type:"string"}},"indent-style":{description:'Whether to use spaces or tabs for indentation.\n\n`indent-style = "space"` (default):\n\n```python def f(): print("Hello") # Spaces indent the `print` statement. ```\n\n`indent-style = "tab"`:\n\n```python def f(): print("Hello") # A tab `\\t` indents the `print` statement. ```\n\nPEP 8 recommends using spaces for [indentation](https://peps.python.org/pep-0008/#indentation). We care about accessibility; if you do not need tabs for accessibility, we do not recommend you use them.\n\nSee [`indent-width`](#indent-width) to configure the number of spaces per indentation and the tab width.',anyOf:[{$ref:"#/definitions/IndentStyle"},{type:"null"}]},"line-ending":{description:"The character Ruff uses at the end of a line.\n\n* `auto`: The newline style is detected automatically on a file per file basis. Files with mixed line endings will be converted to the first detected line ending. Defaults to `\\n` for files that contain no line endings. * `lf`: Line endings will be converted to `\\n`. The default line ending on Unix. * `cr-lf`: Line endings will be converted to `\\r\\n`. The default line ending on Windows. * `native`: Line endings will be converted to `\\n` on Unix and `\\r\\n` on Windows.",anyOf:[{$ref:"#/definitions/LineEnding"},{type:"null"}]},preview:{description:"Whether to enable the unstable preview style formatting.",type:["boolean","null"]},"quote-style":{description:'Configures the preferred quote character for strings. The recommended options are\n\n* `double` (default): Use double quotes `"` * `single`: Use single quotes `\'`\n\nIn compliance with [PEP 8](https://peps.python.org/pep-0008/) and [PEP 257](https://peps.python.org/pep-0257/), Ruff prefers double quotes for triple quoted strings and docstrings even when using `quote-style = "single"`.\n\nRuff deviates from using the configured quotes if doing so prevents the need for escaping quote characters inside the string:\n\n```python a = "a string without any quotes" b = "It\'s monday morning" ```\n\nRuff will change the quotes of the string assigned to `a` to single quotes when using `quote-style = "single"`. However, Ruff uses double quotes for the string assigned to `b` because using single quotes would require escaping the `\'`, which leads to the less readable code: `\'It\\\'s monday morning\'`.\n\nIn addition, Ruff supports the quote style `preserve` for projects that already use a mixture of single and double quotes and can\'t migrate to the `double` or `single` style. The quote style `preserve` leaves the quotes of all strings unchanged.',anyOf:[{$ref:"#/definitions/QuoteStyle"},{type:"null"}]},"skip-magic-trailing-comma":{description:"Ruff uses existing trailing commas as an indication that short lines should be left separate. If this option is set to `true`, the magic trailing comma is ignored.\n\nFor example, Ruff leaves the arguments separate even though collapsing the arguments to a single line doesn't exceed the line length if `skip-magic-trailing-comma = false`:\n\n```python # The arguments remain on separate lines because of the trailing comma after `b` def test( a, b, ): pass ```\n\nSetting `skip-magic-trailing-comma = true` changes the formatting to:\n\n```python # The arguments remain on separate lines because of the trailing comma after `b` def test(a, b): pass ```",type:["boolean","null"]}},additionalProperties:!1},ImportSection:{anyOf:[{$ref:"#/definitions/ImportType"},{type:"string"}]},ImportType:{type:"string",enum:["future","standard-library","third-party","first-party","local-folder"]},IndentStyle:{oneOf:[{description:"Use tabs to indent code.",type:"string",enum:["tab"]},{description:"Use [`IndentWidth`] spaces to indent code.",type:"string",enum:["space"]}]},IndentWidth:{description:"The size of a tab.",type:"integer",format:"uint8",minimum:1},IsortOptions:{type:"object",properties:{"case-sensitive":{description:"Sort imports taking into account case sensitivity.",type:["boolean","null"]},classes:{description:"An override list of tokens to always recognize as a Class for [`order-by-type`](#lint_isort_order-by-type) regardless of casing.",type:["array","null"],items:{type:"string"}},"combine-as-imports":{description:"Combines as imports on the same line. See isort's [`combine-as-imports`](https://pycqa.github.io/isort/docs/configuration/options.html#combine-as-imports) option.",type:["boolean","null"]},constants:{description:"An override list of tokens to always recognize as a CONSTANT for [`order-by-type`](#lint_isort_order-by-type) regardless of casing.",type:["array","null"],items:{type:"string"}},"default-section":{description:"Define a default section for any imports that don't fit into the specified [`section-order`](#lint_isort_section-order).",anyOf:[{$ref:"#/definitions/ImportSection"},{type:"null"}]},"detect-same-package":{description:"Whether to automatically mark imports from within the same package as first-party. For example, when `detect-same-package = true`, then when analyzing files within the `foo` package, any imports from within the `foo` package will be considered first-party.\n\nThis heuristic is often unnecessary when `src` is configured to detect all first-party sources; however, if `src` is _not_ configured, this heuristic can be useful to detect first-party imports from _within_ (but not _across_) first-party packages.",type:["boolean","null"]},"extra-standard-library":{description:"A list of modules to consider standard-library, in addition to those known to Ruff in advance.\n\nSupports glob patterns. For more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).",type:["array","null"],items:{type:"string"}},"force-single-line":{description:"Forces all from imports to appear on their own line.",type:["boolean","null"]},"force-sort-within-sections":{description:"Don't sort straight-style imports (like `import sys`) before from-style imports (like `from itertools import groupby`). Instead, sort the imports by module, independent of import style.",type:["boolean","null"]},"force-to-top":{description:"Force specific imports to the top of their appropriate section.",type:["array","null"],items:{type:"string"}},"force-wrap-aliases":{description:"Force `import from` statements with multiple members and at least one alias (e.g., `import A as B`) to wrap such that every line contains exactly one member. For example, this formatting would be retained, rather than condensing to a single line:\n\n```python from .utils import ( test_directory as test_directory, test_id as test_id ) ```\n\nNote that this setting is only effective when combined with `combine-as-imports = true`. When [`combine-as-imports`](#lint_isort_combine-as-imports) isn't enabled, every aliased `import from` will be given its own line, in which case, wrapping is not necessary.\n\nWhen using the formatter, ensure that [`format.skip-magic-trailing-comma`](#format_skip-magic-trailing-comma) is set to `false` (default) when enabling `force-wrap-aliases` to avoid that the formatter collapses members if they all fit on a single line.",type:["boolean","null"]},"forced-separate":{description:"A list of modules to separate into auxiliary block(s) of imports, in the order specified.",type:["array","null"],items:{type:"string"}},"from-first":{description:"Whether to place `import from` imports before straight imports when sorting.\n\nFor example, by default, imports will be sorted such that straight imports appear before `import from` imports, as in: ```python import os import sys from typing import List ```\n\nSetting `from-first = true` will instead sort such that `import from` imports appear before straight imports, as in: ```python from typing import List import os import sys ```",type:["boolean","null"]},"known-first-party":{description:"A list of modules to consider first-party, regardless of whether they can be identified as such via introspection of the local filesystem.\n\nSupports glob patterns. For more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).",type:["array","null"],items:{type:"string"}},"known-local-folder":{description:"A list of modules to consider being a local folder. Generally, this is reserved for relative imports (`from . import module`).\n\nSupports glob patterns. For more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).",type:["array","null"],items:{type:"string"}},"known-third-party":{description:"A list of modules to consider third-party, regardless of whether they can be identified as such via introspection of the local filesystem.\n\nSupports glob patterns. For more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).",type:["array","null"],items:{type:"string"}},"length-sort":{description:"Sort imports by their string length, such that shorter imports appear before longer imports. For example, by default, imports will be sorted alphabetically, as in: ```python import collections import os ```\n\nSetting `length-sort = true` will instead sort such that shorter imports appear before longer imports, as in: ```python import os import collections ```",type:["boolean","null"]},"length-sort-straight":{description:"Sort straight imports by their string length. Similar to [`length-sort`](#lint_isort_length-sort), but applies only to straight imports and doesn't affect `from` imports.",type:["boolean","null"]},"lines-after-imports":{description:"The number of blank lines to place after imports. Use `-1` for automatic determination.\n\nRuff uses at most one blank line after imports in typing stub files (files with `.pyi` extension) in accordance to the typing style recommendations ([source](https://typing.readthedocs.io/en/latest/source/stubs.html#blank-lines)).\n\nWhen using the formatter, only the values `-1`, `1`, and `2` are compatible because it enforces at least one empty and at most two empty lines after imports.",type:["integer","null"],format:"int"},"lines-between-types":{description:'The number of lines to place between "direct" and `import from` imports.\n\nWhen using the formatter, only the values `0` and `1` are compatible because it preserves up to one empty line after imports in nested blocks.',type:["integer","null"],format:"uint",minimum:0},"no-lines-before":{description:"A list of sections that should _not_ be delineated from the previous section via empty lines.",type:["array","null"],items:{$ref:"#/definitions/ImportSection"}},"no-sections":{description:"Put all imports into the same section bucket.\n\nFor example, rather than separating standard library and third-party imports, as in: ```python import os import sys\n\nimport numpy import pandas ```\n\nSetting `no-sections = true` will instead group all imports into a single section: ```python import numpy import os import pandas import sys ```",type:["boolean","null"]},"order-by-type":{description:"Order imports by type, which is determined by case, in addition to alphabetically.",type:["boolean","null"]},"relative-imports-order":{description:'Whether to place "closer" imports (fewer `.` characters, most local) before "further" imports (more `.` characters, least local), or vice versa.\n\nThe default ("furthest-to-closest") is equivalent to isort\'s [`reverse-relative`](https://pycqa.github.io/isort/docs/configuration/options.html#reverse-relative) default (`reverse-relative = false`); setting this to "closest-to-furthest" is equivalent to isort\'s `reverse-relative = true`.',anyOf:[{$ref:"#/definitions/RelativeImportsOrder"},{type:"null"}]},"required-imports":{description:"Add the specified import line to all files.",type:["array","null"],items:{$ref:"#/definitions/NameImports"}},"section-order":{description:"Override in which order the sections should be output. Can be used to move custom sections.",type:["array","null"],items:{$ref:"#/definitions/ImportSection"}},sections:{description:'A list of mappings from section names to modules.\n\nBy default, imports are categorized according to their type (e.g., `future`, `third-party`, and so on). This setting allows you to group modules into custom sections, to augment or override the built-in sections.\n\nFor example, to group all testing utilities, you could create a `testing` section: ```toml testing = ["pytest", "hypothesis"] ```\n\nThe values in the list are treated as glob patterns. For example, to match all packages in the LangChain ecosystem (`langchain-core`, `langchain-openai`, etc.): ```toml langchain = ["langchain-*"] ```\n\nCustom sections should typically be inserted into the [`section-order`](#lint_isort_section-order) list to ensure that they\'re displayed as a standalone group and in the intended order, as in: ```toml section-order = [ "future", "standard-library", "third-party", "first-party", "local-folder", "testing" ] ```\n\nIf a custom section is omitted from [`section-order`](#lint_isort_section-order), imports in that section will be assigned to the [`default-section`](#lint_isort_default-section) (which defaults to `third-party`).',type:["object","null"],additionalProperties:{type:"array",items:{type:"string"}}},"single-line-exclusions":{description:"One or more modules to exclude from the single line rule.",type:["array","null"],items:{type:"string"}},"split-on-trailing-comma":{description:"If a comma is placed after the last member in a multi-line import, then the imports will never be folded into one line.\n\nSee isort's [`split-on-trailing-comma`](https://pycqa.github.io/isort/docs/configuration/options.html#split-on-trailing-comma) option.\n\nWhen using the formatter, ensure that [`format.skip-magic-trailing-comma`](#format_skip-magic-trailing-comma) is set to `false` (default) when enabling `split-on-trailing-comma` to avoid that the formatter removes the trailing commas.",type:["boolean","null"]},variables:{description:"An override list of tokens to always recognize as a var for [`order-by-type`](#lint_isort_order-by-type) regardless of casing.",type:["array","null"],items:{type:"string"}}},additionalProperties:!1},LineEnding:{oneOf:[{description:"The newline style is detected automatically on a file per file basis. Files with mixed line endings will be converted to the first detected line ending. Defaults to [`LineEnding::Lf`] for a files that contain no line endings.",type:"string",enum:["auto"]},{description:"Line endings will be converted to `\\n` as is common on Unix.",type:"string",enum:["lf"]},{description:"Line endings will be converted to `\\r\\n` as is common on Windows.",type:"string",enum:["cr-lf"]},{description:"Line endings will be converted to `\\n` on Unix and `\\r\\n` on Windows.",type:"string",enum:["native"]}]},LineLength:{description:`The length of a line of text that is considered too long.
82
82
 
83
- The allowed range of values is 1..=320`,type:"integer",format:"uint16",maximum:320,minimum:1},LineWidth:{description:"The maximum visual width to which the formatter should try to limit a line.",type:"integer",format:"uint16",minimum:1},LintOptions:{description:"Configures how Ruff checks your code.\n\nOptions specified in the `lint` section take precedence over the deprecated top-level settings.",type:"object",properties:{"allowed-confusables":{description:'A list of allowed "confusable" Unicode characters to ignore when enforcing `RUF001`, `RUF002`, and `RUF003`.',type:["array","null"],items:{type:"string",maxLength:1,minLength:1}},"dummy-variable-rgx":{description:'A regular expression used to identify "dummy" variables, or those which should be ignored when enforcing (e.g.) unused-variable rules. The default expression matches `_`, `__`, and `_var`, but not `_var_`.',type:["string","null"]},exclude:{description:"A list of file patterns to exclude from linting in addition to the files excluded globally (see [`exclude`](#exclude), and [`extend-exclude`](#extend-exclude)).\n\nExclusions are based on globs, and can be either:\n\n- Single-path patterns, like `.mypy_cache` (to exclude any directory named `.mypy_cache` in the tree), `foo.py` (to exclude any file named `foo.py`), or `foo_*.py` (to exclude any file matching `foo_*.py` ). - Relative patterns, like `directory/foo.py` (to exclude that specific file) or `directory/*.py` (to exclude any Python files in `directory`). Note that these paths are relative to the project root (e.g., the directory containing your `pyproject.toml`).\n\nFor more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).",type:["array","null"],items:{type:"string"}},"explicit-preview-rules":{description:"Whether to require exact codes to select preview rules. When enabled, preview rules will not be selected by prefixes — the full code of each preview rule will be required to enable the rule.",type:["boolean","null"]},"extend-fixable":{description:"A list of rule codes or prefixes to consider fixable, in addition to those specified by [`fixable`](#lint_fixable).",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-ignore":{description:"A list of rule codes or prefixes to ignore, in addition to those specified by `ignore`.",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-per-file-ignores":{description:"A list of mappings from file pattern to rule codes or prefixes to exclude, in addition to any rules excluded by [`per-file-ignores`](#lint_per-file-ignores).",type:["object","null"],additionalProperties:{type:"array",items:{$ref:"#/definitions/RuleSelector"}}},"extend-safe-fixes":{description:"A list of rule codes or prefixes for which unsafe fixes should be considered safe.",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-select":{description:"A list of rule codes or prefixes to enable, in addition to those specified by [`select`](#lint_select).",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-unfixable":{description:"A list of rule codes or prefixes to consider non-auto-fixable, in addition to those specified by [`unfixable`](#lint_unfixable).",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-unsafe-fixes":{description:"A list of rule codes or prefixes for which safe fixes should be considered unsafe.",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},external:{description:"A list of rule codes or prefixes that are unsupported by Ruff, but should be preserved when (e.g.) validating `# noqa` directives. Useful for retaining `# noqa` directives that cover plugins not yet implemented by Ruff.",type:["array","null"],items:{type:"string"}},fixable:{description:"A list of rule codes or prefixes to consider fixable. By default, all rules are considered fixable.",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"flake8-annotations":{description:"Options for the `flake8-annotations` plugin.",anyOf:[{$ref:"#/definitions/Flake8AnnotationsOptions"},{type:"null"}]},"flake8-bandit":{description:"Options for the `flake8-bandit` plugin.",anyOf:[{$ref:"#/definitions/Flake8BanditOptions"},{type:"null"}]},"flake8-boolean-trap":{description:"Options for the `flake8-boolean-trap` plugin.",anyOf:[{$ref:"#/definitions/Flake8BooleanTrapOptions"},{type:"null"}]},"flake8-bugbear":{description:"Options for the `flake8-bugbear` plugin.",anyOf:[{$ref:"#/definitions/Flake8BugbearOptions"},{type:"null"}]},"flake8-builtins":{description:"Options for the `flake8-builtins` plugin.",anyOf:[{$ref:"#/definitions/Flake8BuiltinsOptions"},{type:"null"}]},"flake8-comprehensions":{description:"Options for the `flake8-comprehensions` plugin.",anyOf:[{$ref:"#/definitions/Flake8ComprehensionsOptions"},{type:"null"}]},"flake8-copyright":{description:"Options for the `flake8-copyright` plugin.",anyOf:[{$ref:"#/definitions/Flake8CopyrightOptions"},{type:"null"}]},"flake8-errmsg":{description:"Options for the `flake8-errmsg` plugin.",anyOf:[{$ref:"#/definitions/Flake8ErrMsgOptions"},{type:"null"}]},"flake8-gettext":{description:"Options for the `flake8-gettext` plugin.",anyOf:[{$ref:"#/definitions/Flake8GetTextOptions"},{type:"null"}]},"flake8-implicit-str-concat":{description:"Options for the `flake8-implicit-str-concat` plugin.",anyOf:[{$ref:"#/definitions/Flake8ImplicitStrConcatOptions"},{type:"null"}]},"flake8-import-conventions":{description:"Options for the `flake8-import-conventions` plugin.",anyOf:[{$ref:"#/definitions/Flake8ImportConventionsOptions"},{type:"null"}]},"flake8-pytest-style":{description:"Options for the `flake8-pytest-style` plugin.",anyOf:[{$ref:"#/definitions/Flake8PytestStyleOptions"},{type:"null"}]},"flake8-quotes":{description:"Options for the `flake8-quotes` plugin.",anyOf:[{$ref:"#/definitions/Flake8QuotesOptions"},{type:"null"}]},"flake8-self":{description:"Options for the `flake8_self` plugin.",anyOf:[{$ref:"#/definitions/Flake8SelfOptions"},{type:"null"}]},"flake8-tidy-imports":{description:"Options for the `flake8-tidy-imports` plugin.",anyOf:[{$ref:"#/definitions/Flake8TidyImportsOptions"},{type:"null"}]},"flake8-type-checking":{description:"Options for the `flake8-type-checking` plugin.",anyOf:[{$ref:"#/definitions/Flake8TypeCheckingOptions"},{type:"null"}]},"flake8-unused-arguments":{description:"Options for the `flake8-unused-arguments` plugin.",anyOf:[{$ref:"#/definitions/Flake8UnusedArgumentsOptions"},{type:"null"}]},ignore:{description:"A list of rule codes or prefixes to ignore. Prefixes can specify exact rules (like `F841`), entire categories (like `F`), or anything in between.\n\nWhen breaking ties between enabled and disabled rules (via `select` and `ignore`, respectively), more specific prefixes override less specific prefixes.",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"ignore-init-module-imports":{description:"Avoid automatically removing unused imports in `__init__.py` files. Such imports will still be flagged, but with a dedicated message suggesting that the import is either added to the module's `__all__` symbol, or re-exported with a redundant alias (e.g., `import os as os`).\n\nThis option is enabled by default, but you can opt-in to removal of imports via an unsafe fix.",deprecated:!0,type:["boolean","null"]},isort:{description:"Options for the `isort` plugin.",anyOf:[{$ref:"#/definitions/IsortOptions"},{type:"null"}]},"logger-objects":{description:'A list of objects that should be treated equivalently to a `logging.Logger` object.\n\nThis is useful for ensuring proper diagnostics (e.g., to identify `logging` deprecations and other best-practices) for projects that re-export a `logging.Logger` object from a common module.\n\nFor example, if you have a module `logging_setup.py` with the following contents: ```python import logging\n\nlogger = logging.getLogger(__name__) ```\n\nAdding `"logging_setup.logger"` to `logger-objects` will ensure that `logging_setup.logger` is treated as a `logging.Logger` object when imported from other modules (e.g., `from logging_setup import logger`).',type:["array","null"],items:{type:"string"}},mccabe:{description:"Options for the `mccabe` plugin.",anyOf:[{$ref:"#/definitions/McCabeOptions"},{type:"null"}]},"pep8-naming":{description:"Options for the `pep8-naming` plugin.",anyOf:[{$ref:"#/definitions/Pep8NamingOptions"},{type:"null"}]},"per-file-ignores":{description:"A list of mappings from file pattern to rule codes or prefixes to exclude, when considering any matching files. An initial '!' negates the file pattern.",type:["object","null"],additionalProperties:{type:"array",items:{$ref:"#/definitions/RuleSelector"}}},preview:{description:"Whether to enable preview mode. When preview mode is enabled, Ruff will use unstable rules and fixes.",type:["boolean","null"]},pycodestyle:{description:"Options for the `pycodestyle` plugin.",anyOf:[{$ref:"#/definitions/PycodestyleOptions"},{type:"null"}]},pydocstyle:{description:"Options for the `pydocstyle` plugin.",anyOf:[{$ref:"#/definitions/PydocstyleOptions"},{type:"null"}]},pyflakes:{description:"Options for the `pyflakes` plugin.",anyOf:[{$ref:"#/definitions/PyflakesOptions"},{type:"null"}]},pylint:{description:"Options for the `pylint` plugin.",anyOf:[{$ref:"#/definitions/PylintOptions"},{type:"null"}]},pyupgrade:{description:"Options for the `pyupgrade` plugin.",anyOf:[{$ref:"#/definitions/PyUpgradeOptions"},{type:"null"}]},ruff:{description:"Options for the `ruff` plugin",anyOf:[{$ref:"#/definitions/RuffOptions"},{type:"null"}]},select:{description:"A list of rule codes or prefixes to enable. Prefixes can specify exact rules (like `F841`), entire categories (like `F`), or anything in between.\n\nWhen breaking ties between enabled and disabled rules (via `select` and `ignore`, respectively), more specific prefixes override less specific prefixes.",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"task-tags":{description:'A list of task tags to recognize (e.g., "TODO", "FIXME", "XXX").\n\nComments starting with these tags will be ignored by commented-out code detection (`ERA`), and skipped by line-length rules (`E501`) if [`ignore-overlong-task-comments`](#lint_pycodestyle_ignore-overlong-task-comments) is set to `true`.',type:["array","null"],items:{type:"string"}},"typing-modules":{description:"A list of modules whose exports should be treated equivalently to members of the `typing` module.\n\nThis is useful for ensuring proper type annotation inference for projects that re-export `typing` and `typing_extensions` members from a compatibility module. If omitted, any members imported from modules apart from `typing` and `typing_extensions` will be treated as ordinary Python objects.",type:["array","null"],items:{type:"string"}},unfixable:{description:"A list of rule codes or prefixes to consider non-fixable.",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}}},additionalProperties:!1},McCabeOptions:{type:"object",properties:{"max-complexity":{description:"The maximum McCabe complexity to allow before triggering `C901` errors.",type:["integer","null"],format:"uint",minimum:0}},additionalProperties:!1},NameImports:{type:"string"},OutputFormat:{oneOf:[{type:"string",enum:["concise","full","json","json-lines","junit","grouped","github","gitlab","pylint","rdjson","azure","sarif"]},{deprecated:!0,type:"string",enum:["text"]}]},ParametrizeNameType:{type:"string",enum:["csv","tuple","list"]},ParametrizeValuesRowType:{type:"string",enum:["tuple","list"]},ParametrizeValuesType:{type:"string",enum:["tuple","list"]},Pep8NamingOptions:{type:"object",properties:{"classmethod-decorators":{description:"A list of decorators that, when applied to a method, indicate that the method should be treated as a class method (in addition to the builtin `@classmethod`).\n\nFor example, Ruff will expect that any method decorated by a decorator in this list takes a `cls` argument as its first argument.\n\nExpects to receive a list of fully-qualified names (e.g., `pydantic.validator`, rather than `validator`) or alternatively a plain name which is then matched against the last segment in case the decorator itself consists of a dotted name.",type:["array","null"],items:{type:"string"}},"extend-ignore-names":{description:'Additional names (or patterns) to ignore when considering `pep8-naming` violations, in addition to those included in [`ignore-names`](#lint_pep8-naming_ignore-names).\n\nSupports glob patterns. For example, to ignore all names starting with `test_` or ending with `_test`, you could use `ignore-names = ["test_*", "*_test"]`. For more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).',type:["array","null"],items:{type:"string"}},"ignore-names":{description:'A list of names (or patterns) to ignore when considering `pep8-naming` violations.\n\nSupports glob patterns. For example, to ignore all names starting with `test_` or ending with `_test`, you could use `ignore-names = ["test_*", "*_test"]`. For more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).',type:["array","null"],items:{type:"string"}},"staticmethod-decorators":{description:"A list of decorators that, when applied to a method, indicate that the method should be treated as a static method (in addition to the builtin `@staticmethod`).\n\nFor example, Ruff will expect that any method decorated by a decorator in this list has no `self` or `cls` argument.\n\nExpects to receive a list of fully-qualified names (e.g., `belay.Device.teardown`, rather than `teardown`) or alternatively a plain name which is then matched against the last segment in case the decorator itself consists of a dotted name.",type:["array","null"],items:{type:"string"}}},additionalProperties:!1},PyUpgradeOptions:{type:"object",properties:{"keep-runtime-typing":{description:"Whether to avoid [PEP 585](https://peps.python.org/pep-0585/) (`List[int]` -> `list[int]`) and [PEP 604](https://peps.python.org/pep-0604/) (`Union[str, int]` -> `str | int`) rewrites even if a file imports `from __future__ import annotations`.\n\nThis setting is only applicable when the target Python version is below 3.9 and 3.10 respectively, and is most commonly used when working with libraries like Pydantic and FastAPI, which rely on the ability to parse type annotations at runtime. The use of `from __future__ import annotations` causes Python to treat the type annotations as strings, which typically allows for the use of language features that appear in later Python versions but are not yet supported by the current version (e.g., `str | int`). However, libraries that rely on runtime type annotations will break if the annotations are incompatible with the current Python version.\n\nFor example, while the following is valid Python 3.8 code due to the presence of `from __future__ import annotations`, the use of `str | int` prior to Python 3.10 will cause Pydantic to raise a `TypeError` at runtime:\n\n```python from __future__ import annotations\n\nimport pydantic\n\nclass Foo(pydantic.BaseModel): bar: str | int ```",type:["boolean","null"]}},additionalProperties:!1},PycodestyleOptions:{type:"object",properties:{"ignore-overlong-task-comments":{description:'Whether line-length violations (`E501`) should be triggered for comments starting with [`task-tags`](#lint_task-tags) (by default: "TODO", "FIXME", and "XXX").',type:["boolean","null"]},"max-doc-length":{description:"The maximum line length to allow for [`doc-line-too-long`](https://docs.astral.sh/ruff/rules/doc-line-too-long/) violations within documentation (`W505`), including standalone comments. By default, this is set to `null` which disables reporting violations.\n\nThe length is determined by the number of characters per line, except for lines containing Asian characters or emojis. For these lines, the [unicode width](https://unicode.org/reports/tr11/) of each character is added up to determine the length.\n\nSee the [`doc-line-too-long`](https://docs.astral.sh/ruff/rules/doc-line-too-long/) rule for more information.",anyOf:[{$ref:"#/definitions/LineLength"},{type:"null"}]},"max-line-length":{description:"The maximum line length to allow for [`line-too-long`](https://docs.astral.sh/ruff/rules/line-too-long/) violations. By default, this is set to the value of the [`line-length`](#line-length) option.\n\nUse this option when you want to detect extra-long lines that the formatter can't automatically split by setting `pycodestyle.line-length` to a value larger than [`line-length`](#line-length).\n\n```toml # The formatter wraps lines at a length of 88. line-length = 88\n\n[pycodestyle] # E501 reports lines that exceed the length of 100. max-line-length = 100 ```\n\nThe length is determined by the number of characters per line, except for lines containing East Asian characters or emojis. For these lines, the [unicode width](https://unicode.org/reports/tr11/) of each character is added up to determine the length.\n\nSee the [`line-too-long`](https://docs.astral.sh/ruff/rules/line-too-long/) rule for more information.",anyOf:[{$ref:"#/definitions/LineLength"},{type:"null"}]}},additionalProperties:!1},PydocstyleOptions:{type:"object",properties:{convention:{description:'Whether to use Google-style, NumPy-style conventions, or the [PEP 257](https://peps.python.org/pep-0257/) defaults when analyzing docstring sections.\n\nEnabling a convention will disable all rules that are not included in the specified convention. As such, the intended workflow is to enable a convention and then selectively enable or disable any additional rules on top of it.\n\nFor example, to use Google-style conventions but avoid requiring documentation for every function parameter:\n\n```toml [tool.ruff.lint] # Enable all `pydocstyle` rules, limiting to those that adhere to the # Google convention via `convention = "google"`, below. select = ["D"]\n\n# On top of the Google convention, disable `D417`, which requires # documentation for every function parameter. ignore = ["D417"]\n\n[tool.ruff.lint.pydocstyle] convention = "google" ```\n\nTo enable an additional rule that\'s excluded from the convention, select the desired rule via its fully qualified rule code (e.g., `D400` instead of `D4` or `D40`):\n\n```toml [tool.ruff.lint] # Enable D400 on top of the Google convention. extend-select = ["D400"]\n\n[tool.ruff.lint.pydocstyle] convention = "google" ```',anyOf:[{$ref:"#/definitions/Convention"},{type:"null"}]},"ignore-decorators":{description:"Ignore docstrings for functions or methods decorated with the specified fully-qualified decorators.",type:["array","null"],items:{type:"string"}},"property-decorators":{description:"A list of decorators that, when applied to a method, indicate that the method should be treated as a property (in addition to the builtin `@property` and standard-library `@functools.cached_property`).\n\nFor example, Ruff will expect that any method decorated by a decorator in this list can use a non-imperative summary line.",type:["array","null"],items:{type:"string"}}},additionalProperties:!1},PyflakesOptions:{type:"object",properties:{"extend-generics":{description:'Additional functions or classes to consider generic, such that any subscripts should be treated as type annotation (e.g., `ForeignKey` in `django.db.models.ForeignKey["User"]`.\n\nExpects to receive a list of fully-qualified names (e.g., `django.db.models.ForeignKey`, rather than `ForeignKey`).',type:["array","null"],items:{type:"string"}}},additionalProperties:!1},PylintOptions:{type:"object",properties:{"allow-dunder-method-names":{description:"Dunder methods name to allow, in addition to the default set from the Python standard library (see `PLW3201`).",type:["array","null"],items:{type:"string"},uniqueItems:!0},"allow-magic-value-types":{description:'Constant types to ignore when used as "magic values" (see `PLR2004`).',type:["array","null"],items:{$ref:"#/definitions/ConstantType"}},"max-args":{description:"Maximum number of arguments allowed for a function or method definition (see `PLR0913`).",type:["integer","null"],format:"uint",minimum:0},"max-bool-expr":{description:"Maximum number of Boolean expressions allowed within a single `if` statement (see `PLR0916`).",type:["integer","null"],format:"uint",minimum:0},"max-branches":{description:"Maximum number of branches allowed for a function or method body (see `PLR0912`).",type:["integer","null"],format:"uint",minimum:0},"max-locals":{description:"Maximum number of local variables allowed for a function or method body (see `PLR0914`).",type:["integer","null"],format:"uint",minimum:0},"max-nested-blocks":{description:"Maximum number of nested blocks allowed within a function or method body (see `PLR1702`).",type:["integer","null"],format:"uint",minimum:0},"max-positional-args":{description:"Maximum number of positional arguments allowed for a function or method definition (see `PLR0917`).\n\nIf not specified, defaults to the value of `max-args`.",type:["integer","null"],format:"uint",minimum:0},"max-public-methods":{description:"Maximum number of public methods allowed for a class (see `PLR0904`).",type:["integer","null"],format:"uint",minimum:0},"max-returns":{description:"Maximum number of return statements allowed for a function or method body (see `PLR0911`)",type:["integer","null"],format:"uint",minimum:0},"max-statements":{description:"Maximum number of statements allowed for a function or method body (see `PLR0915`).",type:["integer","null"],format:"uint",minimum:0}},additionalProperties:!1},PythonVersion:{type:"string",enum:["py37","py38","py39","py310","py311","py312","py313"]},Quote:{oneOf:[{description:"Use double quotes.",type:"string",enum:["double"]},{description:"Use single quotes.",type:"string",enum:["single"]}]},QuoteStyle:{type:"string",enum:["single","double","preserve"]},RelativeImportsOrder:{oneOf:[{description:'Place "closer" imports (fewer `.` characters, most local) before "further" imports (more `.` characters, least local).',type:"string",enum:["closest-to-furthest"]},{description:'Place "further" imports (more `.` characters, least local) imports before "closer" imports (fewer `.` characters, most local).',type:"string",enum:["furthest-to-closest"]}]},RequiredVersion:{type:"string"},RuffOptions:{type:"object",properties:{"parenthesize-tuple-in-subscript":{description:"Whether to prefer accessing items keyed by tuples with parentheses around the tuple (see `RUF031`).",type:["boolean","null"]}},additionalProperties:!1},RuleSelector:{type:"string",enum:["A","A0","A00","A001","A002","A003","A004","A005","A006","AIR","AIR0","AIR00","AIR001","ALL","ANN","ANN0","ANN00","ANN001","ANN002","ANN003","ANN1","ANN10","ANN101","ANN102","ANN2","ANN20","ANN201","ANN202","ANN204","ANN205","ANN206","ANN4","ANN40","ANN401","ARG","ARG0","ARG00","ARG001","ARG002","ARG003","ARG004","ARG005","ASYNC","ASYNC1","ASYNC10","ASYNC100","ASYNC105","ASYNC109","ASYNC11","ASYNC110","ASYNC115","ASYNC116","ASYNC2","ASYNC21","ASYNC210","ASYNC22","ASYNC220","ASYNC221","ASYNC222","ASYNC23","ASYNC230","ASYNC25","ASYNC251","B","B0","B00","B002","B003","B004","B005","B006","B007","B008","B009","B01","B010","B011","B012","B013","B014","B015","B016","B017","B018","B019","B02","B020","B021","B022","B023","B024","B025","B026","B027","B028","B029","B03","B030","B031","B032","B033","B034","B035","B039","B9","B90","B901","B904","B905","B909","BLE","BLE0","BLE00","BLE001","C","C4","C40","C400","C401","C402","C403","C404","C405","C406","C408","C409","C41","C410","C411","C413","C414","C415","C416","C417","C418","C419","C42","C420","C9","C90","C901","COM","COM8","COM81","COM812","COM818","COM819","CPY","CPY0","CPY00","CPY001","D","D1","D10","D100","D101","D102","D103","D104","D105","D106","D107","D2","D20","D200","D201","D202","D203","D204","D205","D206","D207","D208","D209","D21","D210","D211","D212","D213","D214","D215","D3","D30","D300","D301","D4","D40","D400","D401","D402","D403","D404","D405","D406","D407","D408","D409","D41","D410","D411","D412","D413","D414","D415","D416","D417","D418","D419","DJ","DJ0","DJ00","DJ001","DJ003","DJ006","DJ007","DJ008","DJ01","DJ012","DJ013","DOC","DOC2","DOC20","DOC201","DOC202","DOC4","DOC40","DOC402","DOC403","DOC5","DOC50","DOC501","DOC502","DTZ","DTZ0","DTZ00","DTZ001","DTZ002","DTZ003","DTZ004","DTZ005","DTZ006","DTZ007","DTZ01","DTZ011","DTZ012","E","E1","E10","E101","E11","E111","E112","E113","E114","E115","E116","E117","E2","E20","E201","E202","E203","E204","E21","E211","E22","E221","E222","E223","E224","E225","E226","E227","E228","E23","E231","E24","E241","E242","E25","E251","E252","E26","E261","E262","E265","E266","E27","E271","E272","E273","E274","E275","E3","E30","E301","E302","E303","E304","E305","E306","E4","E40","E401","E402","E5","E50","E501","E502","E7","E70","E701","E702","E703","E71","E711","E712","E713","E714","E72","E721","E722","E73","E731","E74","E741","E742","E743","E9","E90","E902","E99","E999","EM","EM1","EM10","EM101","EM102","EM103","ERA","ERA0","ERA00","ERA001","EXE","EXE0","EXE00","EXE001","EXE002","EXE003","EXE004","EXE005","F","F4","F40","F401","F402","F403","F404","F405","F406","F407","F5","F50","F501","F502","F503","F504","F505","F506","F507","F508","F509","F52","F521","F522","F523","F524","F525","F54","F541","F6","F60","F601","F602","F62","F621","F622","F63","F631","F632","F633","F634","F7","F70","F701","F702","F704","F706","F707","F72","F722","F8","F81","F811","F82","F821","F822","F823","F84","F841","F842","F9","F90","F901","FA","FA1","FA10","FA100","FA102","FAST","FAST0","FAST00","FAST001","FAST002","FAST003","FBT","FBT0","FBT00","FBT001","FBT002","FBT003","FIX","FIX0","FIX00","FIX001","FIX002","FIX003","FIX004","FLY","FLY0","FLY00","FLY002","FURB","FURB1","FURB10","FURB101","FURB103","FURB105","FURB11","FURB110","FURB113","FURB116","FURB118","FURB12","FURB129","FURB13","FURB131","FURB132","FURB136","FURB14","FURB140","FURB142","FURB145","FURB148","FURB15","FURB152","FURB154","FURB157","FURB16","FURB161","FURB163","FURB164","FURB166","FURB167","FURB168","FURB169","FURB17","FURB171","FURB177","FURB18","FURB180","FURB181","FURB187","FURB19","FURB192","G","G0","G00","G001","G002","G003","G004","G01","G010","G1","G10","G101","G2","G20","G201","G202","I","I0","I00","I001","I002","ICN","ICN0","ICN00","ICN001","ICN002","ICN003","INP","INP0","INP00","INP001","INT","INT0","INT00","INT001","INT002","INT003","ISC","ISC0","ISC00","ISC001","ISC002","ISC003","LOG","LOG0","LOG00","LOG001","LOG002","LOG007","LOG009","N","N8","N80","N801","N802","N803","N804","N805","N806","N807","N81","N811","N812","N813","N814","N815","N816","N817","N818","N9","N99","N999","NPY","NPY0","NPY00","NPY001","NPY002","NPY003","NPY2","NPY20","NPY201","PD","PD0","PD00","PD002","PD003","PD004","PD007","PD008","PD009","PD01","PD010","PD011","PD012","PD013","PD015","PD1","PD10","PD101","PD9","PD90","PD901","PERF","PERF1","PERF10","PERF101","PERF102","PERF2","PERF20","PERF203","PERF4","PERF40","PERF401","PERF402","PERF403","PGH","PGH0","PGH00","PGH003","PGH004","PGH005","PIE","PIE7","PIE79","PIE790","PIE794","PIE796","PIE8","PIE80","PIE800","PIE804","PIE807","PIE808","PIE81","PIE810","PL","PLC","PLC0","PLC01","PLC010","PLC0105","PLC013","PLC0131","PLC0132","PLC02","PLC020","PLC0205","PLC0206","PLC0208","PLC04","PLC041","PLC0414","PLC0415","PLC1","PLC19","PLC190","PLC1901","PLC2","PLC24","PLC240","PLC2401","PLC2403","PLC27","PLC270","PLC2701","PLC28","PLC280","PLC2801","PLC3","PLC30","PLC300","PLC3002","PLE","PLE0","PLE01","PLE010","PLE0100","PLE0101","PLE011","PLE0115","PLE0116","PLE0117","PLE0118","PLE02","PLE023","PLE0237","PLE024","PLE0241","PLE03","PLE030","PLE0302","PLE0303","PLE0304","PLE0305","PLE0307","PLE0308","PLE0309","PLE06","PLE060","PLE0604","PLE0605","PLE064","PLE0643","PLE07","PLE070","PLE0704","PLE1","PLE11","PLE113","PLE1132","PLE114","PLE1141","PLE1142","PLE12","PLE120","PLE1205","PLE1206","PLE13","PLE130","PLE1300","PLE1307","PLE131","PLE1310","PLE15","PLE150","PLE1507","PLE151","PLE1519","PLE152","PLE1520","PLE17","PLE170","PLE1700","PLE2","PLE25","PLE250","PLE2502","PLE251","PLE2510","PLE2512","PLE2513","PLE2514","PLE2515","PLE4","PLE47","PLE470","PLE4703","PLR","PLR0","PLR01","PLR012","PLR0124","PLR013","PLR0133","PLR02","PLR020","PLR0202","PLR0203","PLR0206","PLR04","PLR040","PLR0402","PLR09","PLR090","PLR0904","PLR091","PLR0911","PLR0912","PLR0913","PLR0914","PLR0915","PLR0916","PLR0917","PLR1","PLR17","PLR170","PLR1702","PLR1704","PLR171","PLR1711","PLR1714","PLR172","PLR1722","PLR173","PLR1730","PLR1733","PLR1736","PLR2","PLR20","PLR200","PLR2004","PLR204","PLR2044","PLR5","PLR55","PLR550","PLR5501","PLR6","PLR61","PLR610","PLR6104","PLR62","PLR620","PLR6201","PLR63","PLR630","PLR6301","PLW","PLW0","PLW01","PLW010","PLW0108","PLW012","PLW0120","PLW0127","PLW0128","PLW0129","PLW013","PLW0131","PLW0133","PLW017","PLW0177","PLW02","PLW021","PLW0211","PLW024","PLW0245","PLW04","PLW040","PLW0406","PLW06","PLW060","PLW0602","PLW0603","PLW0604","PLW064","PLW0642","PLW07","PLW071","PLW0711","PLW1","PLW15","PLW150","PLW1501","PLW1508","PLW1509","PLW151","PLW1510","PLW1514","PLW16","PLW164","PLW1641","PLW2","PLW21","PLW210","PLW2101","PLW29","PLW290","PLW2901","PLW3","PLW32","PLW320","PLW3201","PLW33","PLW330","PLW3301","PT","PT0","PT00","PT001","PT002","PT003","PT004","PT005","PT006","PT007","PT008","PT009","PT01","PT010","PT011","PT012","PT013","PT014","PT015","PT016","PT017","PT018","PT019","PT02","PT020","PT021","PT022","PT023","PT024","PT025","PT026","PT027","PTH","PTH1","PTH10","PTH100","PTH101","PTH102","PTH103","PTH104","PTH105","PTH106","PTH107","PTH108","PTH109","PTH11","PTH110","PTH111","PTH112","PTH113","PTH114","PTH115","PTH116","PTH117","PTH118","PTH119","PTH12","PTH120","PTH121","PTH122","PTH123","PTH124","PTH2","PTH20","PTH201","PTH202","PTH203","PTH204","PTH205","PTH206","PTH207","PYI","PYI0","PYI00","PYI001","PYI002","PYI003","PYI004","PYI005","PYI006","PYI007","PYI008","PYI009","PYI01","PYI010","PYI011","PYI012","PYI013","PYI014","PYI015","PYI016","PYI017","PYI018","PYI019","PYI02","PYI020","PYI021","PYI024","PYI025","PYI026","PYI029","PYI03","PYI030","PYI032","PYI033","PYI034","PYI035","PYI036","PYI04","PYI041","PYI042","PYI043","PYI044","PYI045","PYI046","PYI047","PYI048","PYI049","PYI05","PYI050","PYI051","PYI052","PYI053","PYI054","PYI055","PYI056","PYI057","PYI058","PYI059","PYI06","PYI062","PYI063","PYI064","PYI066","Q","Q0","Q00","Q000","Q001","Q002","Q003","Q004","RET","RET5","RET50","RET501","RET502","RET503","RET504","RET505","RET506","RET507","RET508","RSE","RSE1","RSE10","RSE102","RUF","RUF0","RUF00","RUF001","RUF002","RUF003","RUF005","RUF006","RUF007","RUF008","RUF009","RUF01","RUF010","RUF012","RUF013","RUF015","RUF016","RUF017","RUF018","RUF019","RUF02","RUF020","RUF021","RUF022","RUF023","RUF024","RUF026","RUF027","RUF028","RUF029","RUF03","RUF030","RUF031","RUF032","RUF033","RUF034","RUF1","RUF10","RUF100","RUF101","RUF2","RUF20","RUF200","S","S1","S10","S101","S102","S103","S104","S105","S106","S107","S108","S11","S110","S112","S113","S2","S20","S201","S202","S3","S30","S301","S302","S303","S304","S305","S306","S307","S308","S31","S310","S311","S312","S313","S314","S315","S316","S317","S318","S319","S32","S320","S321","S323","S324","S4","S40","S401","S402","S403","S404","S405","S406","S407","S408","S409","S41","S411","S412","S413","S415","S5","S50","S501","S502","S503","S504","S505","S506","S507","S508","S509","S6","S60","S601","S602","S603","S604","S605","S606","S607","S608","S609","S61","S610","S611","S612","S7","S70","S701","S702","SIM","SIM1","SIM10","SIM101","SIM102","SIM103","SIM105","SIM107","SIM108","SIM109","SIM11","SIM110","SIM112","SIM113","SIM114","SIM115","SIM116","SIM117","SIM118","SIM2","SIM20","SIM201","SIM202","SIM208","SIM21","SIM210","SIM211","SIM212","SIM22","SIM220","SIM221","SIM222","SIM223","SIM3","SIM30","SIM300","SIM4","SIM40","SIM401","SIM9","SIM91","SIM910","SIM911","SLF","SLF0","SLF00","SLF001","SLOT","SLOT0","SLOT00","SLOT000","SLOT001","SLOT002","T","T1","T10","T100","T2","T20","T201","T203","TCH","TCH0","TCH00","TCH001","TCH002","TCH003","TCH004","TCH005","TCH01","TCH010","TD","TD0","TD00","TD001","TD002","TD003","TD004","TD005","TD006","TD007","TID","TID2","TID25","TID251","TID252","TID253","TRY","TRY0","TRY00","TRY002","TRY003","TRY004","TRY2","TRY20","TRY201","TRY3","TRY30","TRY300","TRY301","TRY302","TRY4","TRY40","TRY400","TRY401","UP","UP0","UP00","UP001","UP003","UP004","UP005","UP006","UP007","UP008","UP009","UP01","UP010","UP011","UP012","UP013","UP014","UP015","UP017","UP018","UP019","UP02","UP020","UP021","UP022","UP023","UP024","UP025","UP026","UP027","UP028","UP029","UP03","UP030","UP031","UP032","UP033","UP034","UP035","UP036","UP037","UP038","UP039","UP04","UP040","UP041","UP042","UP043","W","W1","W19","W191","W2","W29","W291","W292","W293","W3","W39","W391","W5","W50","W505","W6","W60","W605","YTT","YTT1","YTT10","YTT101","YTT102","YTT103","YTT2","YTT20","YTT201","YTT202","YTT203","YTT204","YTT3","YTT30","YTT301","YTT302","YTT303"]},Strictness:{oneOf:[{description:"Ban imports that extend into the parent module or beyond.",type:"string",enum:["parents"]},{description:"Ban all relative imports.",type:"string",enum:["all"]}]}}};function Ar(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function Zv(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Ar(a,r,i,o,s,"next",l)}function s(l){Ar(a,r,i,o,s,"throw",l)}o(void 0)})}}var Oo=Vs.parse("inmemory://dh-config/ruff-settings.json");function eb(){var{schemas:t=[]}=bn.json.jsonDefaults.diagnosticsOptions;t.some(e=>e.uri==="json://ruff-schema")||bn.json.jsonDefaults.setDiagnosticsOptions({schemas:[...t,{uri:"json://ruff-schema",fileMatch:[Oo.toString()],schema:Jv}]})}function tb(){return Nt.apply(this,arguments)}function Nt(){return Nt=Zv(function*(){return yield Gi.initRuff(),"v".concat(Gs.version())}),Nt.apply(this,arguments)}function nb(t){var{text:e,isOpen:n,onClose:r,onSave:i,readOnly:a=!1,defaultSettings:o=Vi}=t,[s,l]=c.useState(!1),[d,f]=c.useState(!1),p=c.useRef(),h=c.useMemo(()=>JSON.stringify(o,null,2),[o]),{data:m}=Se(tb),[g]=c.useState(()=>Hs.createModel(e,"json",Oo)),P=c.useCallback(()=>{n&&(r(),p.current=void 0,g.dispose())},[n,r,g]),v=c.useCallback(()=>{if(n){try{var b,S;i(JSON.parse((b=(S=p.current)===null||S===void 0||(S=S.getModel())===null||S===void 0?void 0:S.getValue())!==null&&b!==void 0?b:""))}catch{}P()}},[n,P,i]),y=c.useCallback(()=>{Ze(g),g.setValue(h)},[g,h]),x=c.useCallback(b=>{var S;try{JSON.parse(b),l(!0)}catch{l(!1)}f(((S=p.current)===null||S===void 0||(S=S.getModel())===null||S===void 0?void 0:S.getValue())===h)},[h]),w=ke(x,500,{leading:!0}),j=c.useCallback(b=>{p.current=b,g.onDidChangeContent(()=>{w(g.getValue())}),eb(),w(g.getValue())},[w,g]);return n?u.jsxs(Yt,{isOpen:n,centered:!0,keyboard:!0,clickOutside:!1,toggle:P,size:"lg",className:"ruff-settings-modal",children:[u.jsxs(fi,{closeButton:!1,children:[u.jsxs("span",{className:"settings-modal-title mr-auto",children:["Ruff ",m," Settings"]}),u.jsx(ri,{href:"https://docs.astral.sh/ruff/settings/",target:"_blank",children:u.jsx(G,{kind:"ghost",onClick:ne,icon:Ql,children:"Settings Docs"})}),u.jsxs(Qe,{isDisabled:d,onPress:y,children:[u.jsx(Le,{children:u.jsx(Y,{icon:Jl})}),u.jsx(lt,{children:"Reset to default"})]})]}),u.jsx(Kt,{style:{height:"80vh"},children:u.jsx(ta,{onEditorInitialized:j,settings:{readOnly:a,value:e,language:"json",folding:!0,padding:{bottom:16},lineNumbers:"on",overviewRulerLanes:0,model:g}})}),u.jsx(wi,{children:a?u.jsx(G,{kind:"secondary","data-dismiss":"modal",onClick:P,children:"Close"}):u.jsxs(u.Fragment,{children:[u.jsx(G,{kind:"secondary","data-dismiss":"modal",onClick:P,children:"Cancel"}),u.jsx(G,{kind:"primary","data-dismiss":"modal",tooltip:s?void 0:"Cannot save invalid JSON",disabled:!s,onClick:v,children:"Save"})]})})]}):null}const rb=Object.freeze(Object.defineProperty({__proto__:null,Code:Jc,CommandHistory:Zc,CommandHistoryActions:ed,CommandHistoryItem:td,CommandHistoryItemTooltip:nd,Console:On,ConsoleConstants:rd,ConsoleHistory:id,ConsoleHistoryItem:ad,ConsoleHistoryItemResult:od,ConsoleHistoryResultErrorMessage:sd,ConsoleHistoryResultInProgress:ld,ConsoleInput:ud,ConsoleStatusBar:cd,ConsoleUtils:dd,Editor:ta,HeapUsage:pd,LogView:fd,MonacoProviders:Gi,MonacoTheme:hd,MonacoThemeProvider:wo,MonacoUtils:Hi,ObjectIcon:md,RUFF_DEFAULT_SETTINGS:Vi,RuffSettingsModal:nb,SHORTCUTS:gd,ScriptEditor:Jd,ScriptEditorUtils:Zd,default:On},Symbol.toStringTag,{value:"Module"}));function So(t,e,n){return(e=ib(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function ib(t){var e=ab(t,"string");return typeof e=="symbol"?e:e+""}function ab(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class Oe{static valueForCell(e,n,r){var i="".concat(e,",").concat(n);return r!==void 0&&r&&(i="(".concat(i,")")),i}constructor(e){So(this,"dh",void 0),this.dh=e}makeColumn(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Oe.DEFAULT_TYPE,r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;return new this.dh.Column({index:r,name:e,type:n})}makeRollupTableConfig(){return new this.dh.RollupTableConfig}makeColumns(){for(var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:5,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",r=[],i=0;i<e;i+=1)r.push(this.makeColumn("".concat(n).concat(i),Oe.DEFAULT_TYPE,i));return r}static makeUserColumnWidths(){for(var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:5,n=new Map,r=0;r<e;r+=1)n.set(r.toString(),100);return n}makeRow(e){var n=new this.dh.Row({index:e,name:"".concat(e)});return n.get=jest.fn(r=>Oe.valueForCell(e,r.index)),n}makeFilter(){return new this.dh.FilterCondition}makeSort(){return new this.dh.Sort}makeTable(){var{columns:e=this.makeColumns(),size:n=1e9,sort:r=[],layoutHints:i={}}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},a=new this.dh.Table({columns:e,size:n,sort:r});return a.copy=jest.fn(()=>Promise.resolve(a)),a.freeze=jest.fn(()=>Promise.resolve(a)),a.layoutHints=i,a}makeTreeTable(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.makeColumns(),n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1e9,a=arguments.length>4&&arguments[4]!==void 0?arguments[4]:[],o=arguments.length>5?arguments[5]:void 0,s=new this.dh.TreeTable({columns:e,aggregatedColumns:n,groupedColumns:r,size:i,sort:a,layoutHints:o});return s.copy=jest.fn(()=>Promise.resolve(s)),s}makeInputTable(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return new this.dh.InputTable(e)}makeSubscription(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.makeTable();return new this.dh.TableViewportSubscription({table:e})}makeModel(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.makeTable(),n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null,r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null,{dh:i}=this;return new ep(i,e,n??new en(i),r)}}So(Oe,"DEFAULT_TYPE","java.lang.String");const ob=Object.freeze(Object.defineProperty({__proto__:null,AdvancedSettings:tp,AdvancedSettingsType:np,AggregationEdit:Ff,AggregationOperation:rp,AggregationUtils:ip,Aggregations:Nf,BarIcon:Mf,ChartBuilder:$f,ColumnHeaderGroup:ap,CustomColumnBuilder:Uf,DownloadServiceWorkerUtils:Bf,FormatColumnWhereIcon:Wf,FormatRowWhereIcon:Hf,HistogramIcon:Vf,InputEditor:Gf,IrisGrid:Sn,IrisGridCacheUtils:op,IrisGridCellOverflowMouseHandler:Yf,IrisGridCellRendererUtils:Kf,IrisGridColumnSelectMouseHandler:zf,IrisGridColumnTooltipMouseHandler:qf,IrisGridContextMenuHandler:Xf,IrisGridCopyCellMouseHandler:Qf,IrisGridDataSelectMouseHandler:Jf,IrisGridFilterMouseHandler:Zf,IrisGridMetricCalculator:eh,IrisGridModel:sp,IrisGridModelFactory:lp,IrisGridPartitionedTableModel:up,IrisGridPartitionedTableMouseHandler:th,IrisGridRenderer:nh,IrisGridRowTreeMouseHandler:rh,IrisGridSortMouseHandler:ih,IrisGridTableModel:cp,IrisGridTableModelTemplate:dp,IrisGridTestUtils:Oe,IrisGridThemeContext:ah,IrisGridThemeProvider:ga,IrisGridTokenMouseHandler:oh,IrisGridTreeTableModel:pp,IrisGridUtils:fp,LineIcon:sh,OptionType:lh,PendingMouseHandler:uh,PieIcon:ch,RollupRows:dh,SHORTCUTS:ph,ScatterIcon:fh,TableCsvExporter:hh,TableSaver:mh,VisibilityOrderingBuilder:gh,createDefaultIrisGridTheme:yh,default:Sn,isColumnHeaderGroup:hp,isIrisGridTableModelTemplate:mp,isIrisGridTreeTableModel:gp,isPanelStateV1:yp,isPanelStateV2:vp,isPartitionedGridModel:bp,isPartitionedGridModelProvider:Pp,isUITreeRow:xp},Symbol.toStringTag,{value:"Module"}));var Eo={react:U,"react-dom":qs,redux:zs,"react-redux":Ks,"@adobe/react-spectrum":Ys,"@deephaven/auth-plugins":Gv,"@deephaven/chart":zv,"@deephaven/components":gy,"@deephaven/console":rb,"@deephaven/dashboard":Qv,"@deephaven/dashboard-core-plugins":wp,"@deephaven/icons":Zl,"@deephaven/iris-grid":ob,"@deephaven/jsapi-bootstrap":wy,"@deephaven/jsapi-components":bv,"@deephaven/jsapi-utils":Dy,"@deephaven/log":W,"@deephaven/plugin":Ov,"@deephaven/react-hooks":Kh},sb=Qs.createRequires(Eo),lb=Xs({requires:sb});function Fr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Nr(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Fr(Object(n),!0).forEach(function(r){ub(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Fr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function ub(t,e,n){return(e=cb(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function cb(t){var e=db(t,"string");return typeof e=="symbol"?e:e+""}function db(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Mr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function yn(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Mr(a,r,i,o,s,"next",l)}function s(l){Mr(a,r,i,o,s,"throw",l)}o(void 0)})}}var le=W.module("@deephaven/app-utils.PluginUtils");function pb(t){return Mt.apply(this,arguments)}function Mt(){return Mt=yn(function*(t){var e=yield lb(t);return e}),Mt.apply(this,arguments)}function fb(t){return $t.apply(this,arguments)}function $t(){return $t=yn(function*(t){var e=yield fetch(t);if(!e.ok)throw new Error(e.statusText);try{return yield e.json()}catch{throw new Error("Could not be parsed as JSON")}}),$t.apply(this,arguments)}function hb(t){return typeof t=="object"&&t!=null&&typeof t.default=="object"}function mb(t){return Et(t)?t:hb(t)&&Et(t.default)?t.default:Li(t)?t:null}function gb(t){return Ut.apply(this,arguments)}function Ut(){return Ut=yn(function*(t){le.debug("Loading plugins...");try{var e=yield fb("".concat(t,"/manifest.json"));if(!Array.isArray(e.plugins))throw new Error("Plugin manifest JSON does not contain plugins array");le.debug("Plugin manifest loaded:",e);for(var n=[],r=0;r<e.plugins.length;r+=1){var{name:i,main:a}=e.plugins[r],o="".concat(t,"/").concat(i,"/").concat(a);n.push(pb(o))}for(var s=yield Promise.allSettled(n),l=new Map,d=0;d<s.length;d+=1){var f=s[d],{name:p,version:h}=e.plugins[d];if(f.status==="fulfilled"){var m=mb(f.value);m==null?le.error("Plugin '".concat(p,"' is missing an exported value.")):l.set(p,Nr(Nr({},m),{},{version:h}))}else le.error("Unable to load plugin '".concat(p,"'"),f.reason)}return le.info("Plugins loaded:",l),l}catch(g){return le.error("Unable to load plugins:",g),new Map}}),Ut.apply(this,arguments)}function yb(t){var e,n;return(e=(n=t.get("AuthHandlers"))===null||n===void 0?void 0:n.split(","))!==null&&e!==void 0?e:[]}function vb(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:new Map,r=yb(e),i=[...t.entries(),...n.entries()].filter(l=>{var[,d]=l;return Ri(d)||St(d)}).map(l=>{var[d,f]=l;return St(f)?{type:Di.AUTH_PLUGIN,name:d,component:f.AuthPlugin.Component,isAvailable:f.AuthPlugin.isAvailable}:f}),a=i.filter(l=>{var{isAvailable:d}=l;return d(r,e)});if(a.length===0)throw new Error("No login plugins found, please register a login plugin for auth handlers: ".concat(r));a.length>1&&le.warn("More than one login plugin available, will use the first one: ",a.map(l=>{var{name:d}=l;return d}).join(", "));var{name:o,component:s}=a[0];return le.info("Using LoginPlugin",o),s}var bb=ii.createRequires(()=>Eo),Qb=ii.createRemoteComponent({requires:bb});function $r(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function Pb(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){$r(a,r,i,o,s,"next",l)}function s(l){$r(a,r,i,o,s,"throw",l)}o(void 0)})}}function xb(t){var{pluginsUrl:e,getCorePlugins:n,children:r}=t,[i,a]=c.useState(null);return c.useEffect(function(){var s=!1;function l(){return d.apply(this,arguments)}function d(){return d=Pb(function*(){var f,p=(f=yield n==null?void 0:n())!==null&&f!==void 0?f:[],h=yield gb(e);if(!s){var m=p.map(g=>[g.name,g]);a(new Map([...m,...h]))}}),d.apply(this,arguments)}return l(),()=>{s=!0}},[e,n]),u.jsx(st.Provider,{value:i,children:r})}function wb(){var t=fn();return c.useEffect(function(){t.postMessage(hi(pn))},[t]),null}function Ur(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function Ob(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Ur(a,r,i,o,s,"next",l)}function s(l){Ur(a,r,i,o,s,"throw",l)}o(void 0)})}}var Sb=new Map([["@deephaven/auth-plugins.AuthPluginParent",{AuthPlugin:mo}],["@deephaven/auth-plugins.AuthPluginPsk",{AuthPlugin:bo}],["@deephaven/auth-plugins.AuthPluginAnonymous",{AuthPlugin:ho}]]);function Eb(t){var{children:e}=t,n=Ae(),r=c.useContext(st),[i,a]=c.useState(),[o,s]=c.useState();c.useEffect(function(){var p=!1;function h(){return m.apply(this,arguments)}function m(){return m=Ob(function*(){try{var g=yield n.getAuthConfigValues();p||a(new Map(g))}catch(P){p||s(P)}}),m.apply(this,arguments)}return h(),()=>{p=!0}},[n]);var l=c.useMemo(()=>{if(!(r==null||i==null))try{return vb(r,i,Sb)}catch(f){s(f)}},[i,r]),d=l==null||i==null;return d||o!=null?u.jsx(ge,{isLoading:d&&o==null,errorMessage:_e(o),"data-testid":"auth-bootstrap-loading-error"}):u.jsx(l,{authConfigValues:i,children:u.jsxs(u.Fragment,{children:[u.jsx(wb,{}),e]})})}function Br(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function Wr(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Br(a,r,i,o,s,"next",l)}function s(l){Br(a,r,i,o,s,"throw",l)}o(void 0)})}}var Ce=W.module("@deephaven/app-utils.ConnectionBootstrap");function Cb(t){var{children:e}=t,n=ye(),r=Ae(),[i,a]=c.useState(),[o,s]=c.useState(),[l,d]=c.useState("connecting"),f=l==="failed",p=l==="shutdown",h=l==="reconnecting",m=l==="not_connecting";c.useEffect(function(){var x=!1;function w(){return j.apply(this,arguments)}function j(){return j=Wr(function*(){try{var b=yield r.getAsIdeConnection();if(x)return;s(b),d("connected")}catch(S){if(x)return;a(S),d("not_connecting")}}),j.apply(this,arguments)}return w(),()=>{x=!0}},[n,r]),c.useEffect(function(){if(o==null||p)return;function x(j){var{detail:b}=j;Ce.info("Disconnect","".concat(JSON.stringify(b))),d("reconnecting")}var w=o.addEventListener(n.IdeConnection.EVENT_DISCONNECT,x);return w},[n,o,p]),c.useEffect(function(){if(o==null||p)return;function x(j){var{detail:b}=j;Ce.info("Reconnect","".concat(JSON.stringify(b))),d("connected")}var w=o.addEventListener(n.CoreClient.EVENT_RECONNECT,x);return w},[n,o,p]),c.useEffect(function(){if(o==null)return;function x(j){var{detail:b}=j;Ce.info("Shutdown","".concat(JSON.stringify(b))),a("Server shutdown: ".concat(b??"Unknown reason")),d("shutdown")}var w=o.addEventListener(n.IdeConnection.EVENT_SHUTDOWN,x);return w},[n,o]),c.useEffect(function(){if(o==null||p)return;function x(j){var{detail:b}=j;Ce.warn("Reconnect authentication failed","".concat(JSON.stringify(b))),a("Reconnect authentication failed: ".concat(b??"Unknown reason")),d("failed")}var w=o.addEventListener(n.CoreClient.EVENT_RECONNECT_AUTH_FAILED,x);return w},[n,o,p]);var g=c.useCallback(function(){var y=Wr(function*(x){if(Ze(o,"No connection available to fetch object with"),typeof x=="string")throw new Error("No URI resolvers available in Core");return o.getObject(ji(x))});return function(x){return y.apply(this,arguments)}}(),[o]),P=c.useMemo(()=>({subscribe:(y,x)=>(x({fetch:()=>g(y),status:"ready"}),()=>{})}),[g]);function v(){Ce.info("Refreshing application"),window.location.reload()}return p||l==="connecting"||m?u.jsx(ge,{"data-testid":"connection-bootstrap-loading",isLoading:!1,errorMessage:i!=null?"".concat(i):void 0}):u.jsx(lu.Provider,{value:o??null,children:u.jsx(Ti.Provider,{value:g,children:u.jsxs(ct.Provider,{value:P,children:[e,u.jsx($a,{isOpen:h,debounceMs:1e3,children:u.jsx(Ua,{icon:eu,title:u.jsxs(u.Fragment,{children:[u.jsx(Je,{})," Attempting to reconnect..."]}),subtitle:"Please check your network connection."})}),u.jsx(xi,{confirmButtonText:"Refresh",onConfirm:v,isOpen:f,headerText:"Authentication failed",bodyText:"Credentials are invalid. Please refresh your browser to try and reconnect."})]})})})}function Jb(t){return new URL(t,"".concat(window.location))}function Tb(){var t=new URLSearchParams(window.location.search);return t.get("envoyPrefix")}function jb(){var t=Tb();return t!=null?{headers:{"envoy-prefix":t}}:{headers:{}}}function Hr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Vr(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Hr(Object(n),!0).forEach(function(r){Ib(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Hr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Ib(t,e,n){return(e=kb(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function kb(t){var e=_b(t,"string");return typeof e=="symbol"?e:e+""}function _b(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Db(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return{action:()=>{Lh(tu,Vr(Vr({},t),{},{userAgent:navigator.userAgent}),na.getState())},shortcut:ot.EXPORT_LOGS,isGlobal:e}}function Rb(t){var{children:e}=t,n=c.useContext(mn);return n?u.jsx(u.Fragment,{children:e}):u.jsx(ge,{"data-testid":"fonts-loaded-loading"})}function Lb(t){var{children:e}=t,n=uu(),r=c.useContext(yi),i=c.useContext(nt),a=xo(n,r,i);return u.jsx(gi.Provider,{value:a,children:e})}function Ab(t){var{children:e}=t,n=Wi(yd),r=c.useContext(st),i=co(r),a=Vt();return u.jsx(Si,{themes:i,waitForActivation:a,children:u.jsx(Ni,{children:u.jsx(wo,{children:u.jsx(ga,{density:n.gridDensity,children:e})})})})}function Zb(t){var{fontClassNames:e,pluginsUrl:n,getCorePlugins:r,serverUrl:i,logMetadata:a,children:o}=t,s=c.useMemo(()=>jb(),[]),[l,d]=c.useState(0),f=c.useCallback(()=>{},[]),p=c.useCallback(()=>{requestAnimationFrame(()=>{d(m=>m+1)})},[]);hn(f,p);var h=c.useMemo(()=>[Db(a,!0)],[a]);return u.jsxs(Js,{store:na,children:[u.jsx(Pv,{fontClassNames:e,children:u.jsx(xb,{getCorePlugins:r,pluginsUrl:n,children:u.jsx(Ab,{children:u.jsxs(mi,{serverUrl:i,options:s,children:[u.jsx(Eb,{children:u.jsx(cu,{children:u.jsx(Lb,{children:u.jsx(Cb,{children:u.jsx(Rb,{children:o})})})})}),u.jsx(at,{actions:h})]},l)})})}),u.jsx(Ba,{})]})}function Gr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function Fb(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Gr(a,r,i,o,s,"next",l)}function s(l){Gr(a,r,i,o,s,"throw",l)}o(void 0)})}}function ee(t,e,n){return(e=Nb(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Nb(t){var e=Mb(t,"string");return typeof e=="symbol"?e:e+""}function Mb(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Te=W.module("GrpcFileStorageTable");class Re{constructor(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:n;ee(this,"storageService",void 0),ee(this,"baseRoot",void 0),ee(this,"root",void 0),ee(this,"currentSize",0),ee(this,"currentViewport",void 0),ee(this,"listeners",[]),ee(this,"viewportUpdatePromise",void 0),ee(this,"currentViewportData",void 0),ee(this,"childTables",new Map),this.storageService=e,this.baseRoot=n,this.root=r,r===n&&(this.doRefresh=Ie(this.doRefresh.bind(this),Re.REFRESH_DEBOUNCE))}removeBaseRoot(e){return he.removeRoot(this.baseRoot,e)}getViewportData(){var e;return this.viewportUpdatePromise||this.refreshInternal(),(e=this.viewportUpdatePromise)!==null&&e!==void 0?e:Promise.resolve({items:[],offset:0})}getSnapshot(e){throw new Error("Method not implemented.")}get size(){return this.currentSize}setExpanded(e,n){var r=e.split("/"),i=r.shift();if((i===void 0||i==="")&&(i=r.shift()),i===void 0||i==="")throw new Error("Invalid path: ".concat(e));var a=r.join("/");if(n){if(!this.childTables.has(i)){var o=new Re(this.storageService,this.baseRoot,"".concat(this.root,"/").concat(i));this.childTables.set(i,o)}if(a){var s=this.childTables.get(i);s==null||s.setExpanded(a,n)}}else if(this.childTables.has(i))if(a){var l=this.childTables.get(i);l==null||l.setExpanded(a,n)}else this.childTables.delete(i);this.currentViewport&&this.refreshInternal()}collapseAll(){this.childTables.clear(),this.currentViewport&&this.refreshInternal()}setSearch(e){throw new Error("Method not implemented.")}setViewport(e){this.currentViewport=e,this.refreshInternal()}setFilters(){throw new Error("Method not implemented.")}setSorts(){throw new Error("Method not implemented.")}setReversed(){throw new Error("Method not implemented.")}close(){this.listeners=[]}onUpdate(e){return this.listeners=[...this.listeners,e],()=>{this.listeners=this.listeners.filter(n=>n!==e)}}doRefresh(e){Te.debug2("doRefresh",this.root),e(this.fetchData())}refresh(){var e;Te.debug2("refresh",this.root),(e=this.viewportUpdatePromise)===null||e===void 0||e.cancel();var n=new Promise(i=>{this.doRefresh(i)}),r=me.makeCancelable(n.then(i=>{if(this.viewportUpdatePromise!==r)throw new Ai;return this.currentViewportData=i,this.sendUpdate(),i}));r.catch(i=>{me.isCanceled(i)||Te.error("Error updating viewport",i)}),this.viewportUpdatePromise=r}refreshInternal(){try{this.refresh()}catch(e){me.isCanceled(e)||Te.error("Unable to refresh data",e)}}fetchData(){var e=this;return Fb(function*(){var{currentViewport:n}=e;if(!n)throw new Error("No viewport set");for(var r=yield e.storageService.listItems(e.root),i=r.map(p=>({type:p.type,filename:e.removeBaseRoot(p.filename),basename:p.basename,id:e.removeBaseRoot(p.filename),isExpanded:p.type==="directory"?e.childTables.has(p.basename):void 0})).sort((p,h)=>p.type!==h.type?p.type==="directory"?-1:1:p.basename.localeCompare(h.basename)),a=0;a<i.length;a+=1){var o=i[a],{basename:s,filename:l}=o;if(l===e.removeBaseRoot("".concat(e.root,"/").concat(s))&&o.type==="directory"){var d=e.childTables.get(s);if(d!=null){d.setViewport({top:0,bottom:n.bottom-a});var f=yield d.getViewportData();i.splice(a+1,0,...f.items)}}}return e.currentSize=i.length,Te.debug2(e.root,"items",i,n),i=i.slice(n.top,n.bottom),{items:i,offset:n.top}})()}sendUpdate(){for(var e,{listeners:n}=this,r=(e=this.currentViewportData)!==null&&e!==void 0?e:{items:[],offset:0},i=0;i<n.length;i+=1)n[i](r)}}ee(Re,"REFRESH_DEBOUNCE",50);function Yr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function oe(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Yr(a,r,i,o,s,"next",l)}function s(l){Yr(a,r,i,o,s,"throw",l)}o(void 0)})}}function be(t,e,n){return(e=$b(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function $b(t){var e=Ub(t,"string");return typeof e=="symbol"?e:e+""}function Ub(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Bb=W.module("GrpcFileStorage");class vn{constructor(e,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"";be(this,"dh",void 0),be(this,"storageService",void 0),be(this,"tables",[]),be(this,"root",void 0),be(this,"refreshTables",Zs(()=>{this.tables.forEach(i=>i.refresh())},vn.REFRESH_THROTTLE)),this.dh=e,this.storageService=n,this.root=r}removeRoot(e){return he.removeRoot(this.root,e)}addRoot(e){return he.addRoot(this.root,e)}createDirectory(e){var n=this;return oe(function*(){return yield n.storageService.createDirectory(n.addRoot(e)),n.refreshTables(),{type:"directory",id:e,filename:e,basename:he.getBaseName(e)}})()}getTable(){var e=this;return oe(function*(){var n=new Re(e.storageService,e.root);return e.tables.push(n),n})()}saveFile(e){var n=this;return oe(function*(){var r=n.dh.storage.FileContents.text(e.content);return yield n.storageService.saveFile(n.addRoot(e.filename),r,!0),n.refreshTables(),e})()}loadFile(e){var n=this;return oe(function*(){var r=yield n.storageService.loadFile(n.addRoot(e)),i=yield r.text();return{filename:e,basename:he.getBaseName(e),content:i}})()}copyFile(e,n){var r=this;return oe(function*(){var i=yield r.storageService.loadFile(r.addRoot(e));yield r.storageService.saveFile(r.addRoot(n),i,!1),r.refreshTables()})()}deleteFile(e){var n=this;return oe(function*(){yield n.storageService.deleteItem(n.addRoot(e)),n.refreshTables()})()}moveFile(e,n){var r=this;return oe(function*(){yield r.storageService.moveItem(r.addRoot(e),r.addRoot(n)),r.refreshTables()})()}info(e){var n=this;return oe(function*(){var r=yield n.storageService.listItems(n.addRoot(he.getPath(e)),he.getBaseName(e));if(r.length===0)throw new vd;if(r.length>1)throw Bb.error("More than one matching file found, should never happen.",r),new Error("More than one matching file found");var i=r[0];if(!bd(i.type))throw new Error("Unexpected file type: ".concat(i.type));return{filename:n.removeRoot(i.filename),basename:i.basename,id:n.removeRoot(i.filename),type:i.type}})()}}be(vn,"REFRESH_THROTTLE",150);export{Zb as AppBootstrap,n0 as AppDashboards,Eb as AuthBootstrap,Cb as ConnectionBootstrap,lu as ConnectionContext,r0 as DEFAULT_LAYOUT_CONFIG,i0 as DEFAULT_LAYOUT_CONFIG_NO_CONSOLE,Pv as FontBootstrap,Rb as FontsLoaded,mn as FontsLoadedContext,vn as GrpcFileStorage,Re as GrpcFileStorageTable,a0 as GrpcLayoutStorage,o0 as LocalWorkspaceStorage,xb as PluginsBootstrap,Qb as RemoteComponent,Ab as ThemeBootstrap,s0 as UserLayoutUtils,Db as createExportLogsContextAction,l0 as exportLayout,yb as getAuthHandlers,vb as getAuthPluginComponent,Jb as getBaseUrl,jb as getConnectOptions,u0 as getDefaultLayout,Tb as getEnvoyPrefix,mb as getPluginModuleValue,c0 as isLayoutV1,d0 as isLayoutV2,fb as loadJson,pb as loadModulePlugin,gb as loadModulePlugins,p0 as normalizeLayout,f0 as useConnection,uu as useServerConfig,h0 as useUser};
84
- //# sourceMappingURL=index-DfdMWwUx.js.map
83
+ The allowed range of values is 1..=320`,type:"integer",format:"uint16",maximum:320,minimum:1},LineWidth:{description:"The maximum visual width to which the formatter should try to limit a line.",type:"integer",format:"uint16",minimum:1},LintOptions:{description:"Configures how Ruff checks your code.\n\nOptions specified in the `lint` section take precedence over the deprecated top-level settings.",type:"object",properties:{"allowed-confusables":{description:'A list of allowed "confusable" Unicode characters to ignore when enforcing `RUF001`, `RUF002`, and `RUF003`.',type:["array","null"],items:{type:"string",maxLength:1,minLength:1}},"dummy-variable-rgx":{description:'A regular expression used to identify "dummy" variables, or those which should be ignored when enforcing (e.g.) unused-variable rules. The default expression matches `_`, `__`, and `_var`, but not `_var_`.',type:["string","null"]},exclude:{description:"A list of file patterns to exclude from linting in addition to the files excluded globally (see [`exclude`](#exclude), and [`extend-exclude`](#extend-exclude)).\n\nExclusions are based on globs, and can be either:\n\n- Single-path patterns, like `.mypy_cache` (to exclude any directory named `.mypy_cache` in the tree), `foo.py` (to exclude any file named `foo.py`), or `foo_*.py` (to exclude any file matching `foo_*.py` ). - Relative patterns, like `directory/foo.py` (to exclude that specific file) or `directory/*.py` (to exclude any Python files in `directory`). Note that these paths are relative to the project root (e.g., the directory containing your `pyproject.toml`).\n\nFor more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).",type:["array","null"],items:{type:"string"}},"explicit-preview-rules":{description:"Whether to require exact codes to select preview rules. When enabled, preview rules will not be selected by prefixes — the full code of each preview rule will be required to enable the rule.",type:["boolean","null"]},"extend-fixable":{description:"A list of rule codes or prefixes to consider fixable, in addition to those specified by [`fixable`](#lint_fixable).",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-ignore":{description:"A list of rule codes or prefixes to ignore, in addition to those specified by `ignore`.",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-per-file-ignores":{description:"A list of mappings from file pattern to rule codes or prefixes to exclude, in addition to any rules excluded by [`per-file-ignores`](#lint_per-file-ignores).",type:["object","null"],additionalProperties:{type:"array",items:{$ref:"#/definitions/RuleSelector"}}},"extend-safe-fixes":{description:"A list of rule codes or prefixes for which unsafe fixes should be considered safe.",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-select":{description:"A list of rule codes or prefixes to enable, in addition to those specified by [`select`](#lint_select).",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-unfixable":{description:"A list of rule codes or prefixes to consider non-auto-fixable, in addition to those specified by [`unfixable`](#lint_unfixable).",deprecated:!0,type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"extend-unsafe-fixes":{description:"A list of rule codes or prefixes for which safe fixes should be considered unsafe.",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},external:{description:"A list of rule codes or prefixes that are unsupported by Ruff, but should be preserved when (e.g.) validating `# noqa` directives. Useful for retaining `# noqa` directives that cover plugins not yet implemented by Ruff.",type:["array","null"],items:{type:"string"}},fixable:{description:"A list of rule codes or prefixes to consider fixable. By default, all rules are considered fixable.",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"flake8-annotations":{description:"Options for the `flake8-annotations` plugin.",anyOf:[{$ref:"#/definitions/Flake8AnnotationsOptions"},{type:"null"}]},"flake8-bandit":{description:"Options for the `flake8-bandit` plugin.",anyOf:[{$ref:"#/definitions/Flake8BanditOptions"},{type:"null"}]},"flake8-boolean-trap":{description:"Options for the `flake8-boolean-trap` plugin.",anyOf:[{$ref:"#/definitions/Flake8BooleanTrapOptions"},{type:"null"}]},"flake8-bugbear":{description:"Options for the `flake8-bugbear` plugin.",anyOf:[{$ref:"#/definitions/Flake8BugbearOptions"},{type:"null"}]},"flake8-builtins":{description:"Options for the `flake8-builtins` plugin.",anyOf:[{$ref:"#/definitions/Flake8BuiltinsOptions"},{type:"null"}]},"flake8-comprehensions":{description:"Options for the `flake8-comprehensions` plugin.",anyOf:[{$ref:"#/definitions/Flake8ComprehensionsOptions"},{type:"null"}]},"flake8-copyright":{description:"Options for the `flake8-copyright` plugin.",anyOf:[{$ref:"#/definitions/Flake8CopyrightOptions"},{type:"null"}]},"flake8-errmsg":{description:"Options for the `flake8-errmsg` plugin.",anyOf:[{$ref:"#/definitions/Flake8ErrMsgOptions"},{type:"null"}]},"flake8-gettext":{description:"Options for the `flake8-gettext` plugin.",anyOf:[{$ref:"#/definitions/Flake8GetTextOptions"},{type:"null"}]},"flake8-implicit-str-concat":{description:"Options for the `flake8-implicit-str-concat` plugin.",anyOf:[{$ref:"#/definitions/Flake8ImplicitStrConcatOptions"},{type:"null"}]},"flake8-import-conventions":{description:"Options for the `flake8-import-conventions` plugin.",anyOf:[{$ref:"#/definitions/Flake8ImportConventionsOptions"},{type:"null"}]},"flake8-pytest-style":{description:"Options for the `flake8-pytest-style` plugin.",anyOf:[{$ref:"#/definitions/Flake8PytestStyleOptions"},{type:"null"}]},"flake8-quotes":{description:"Options for the `flake8-quotes` plugin.",anyOf:[{$ref:"#/definitions/Flake8QuotesOptions"},{type:"null"}]},"flake8-self":{description:"Options for the `flake8_self` plugin.",anyOf:[{$ref:"#/definitions/Flake8SelfOptions"},{type:"null"}]},"flake8-tidy-imports":{description:"Options for the `flake8-tidy-imports` plugin.",anyOf:[{$ref:"#/definitions/Flake8TidyImportsOptions"},{type:"null"}]},"flake8-type-checking":{description:"Options for the `flake8-type-checking` plugin.",anyOf:[{$ref:"#/definitions/Flake8TypeCheckingOptions"},{type:"null"}]},"flake8-unused-arguments":{description:"Options for the `flake8-unused-arguments` plugin.",anyOf:[{$ref:"#/definitions/Flake8UnusedArgumentsOptions"},{type:"null"}]},ignore:{description:"A list of rule codes or prefixes to ignore. Prefixes can specify exact rules (like `F841`), entire categories (like `F`), or anything in between.\n\nWhen breaking ties between enabled and disabled rules (via `select` and `ignore`, respectively), more specific prefixes override less specific prefixes.",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"ignore-init-module-imports":{description:"Avoid automatically removing unused imports in `__init__.py` files. Such imports will still be flagged, but with a dedicated message suggesting that the import is either added to the module's `__all__` symbol, or re-exported with a redundant alias (e.g., `import os as os`).\n\nThis option is enabled by default, but you can opt-in to removal of imports via an unsafe fix.",deprecated:!0,type:["boolean","null"]},isort:{description:"Options for the `isort` plugin.",anyOf:[{$ref:"#/definitions/IsortOptions"},{type:"null"}]},"logger-objects":{description:'A list of objects that should be treated equivalently to a `logging.Logger` object.\n\nThis is useful for ensuring proper diagnostics (e.g., to identify `logging` deprecations and other best-practices) for projects that re-export a `logging.Logger` object from a common module.\n\nFor example, if you have a module `logging_setup.py` with the following contents: ```python import logging\n\nlogger = logging.getLogger(__name__) ```\n\nAdding `"logging_setup.logger"` to `logger-objects` will ensure that `logging_setup.logger` is treated as a `logging.Logger` object when imported from other modules (e.g., `from logging_setup import logger`).',type:["array","null"],items:{type:"string"}},mccabe:{description:"Options for the `mccabe` plugin.",anyOf:[{$ref:"#/definitions/McCabeOptions"},{type:"null"}]},"pep8-naming":{description:"Options for the `pep8-naming` plugin.",anyOf:[{$ref:"#/definitions/Pep8NamingOptions"},{type:"null"}]},"per-file-ignores":{description:"A list of mappings from file pattern to rule codes or prefixes to exclude, when considering any matching files. An initial '!' negates the file pattern.",type:["object","null"],additionalProperties:{type:"array",items:{$ref:"#/definitions/RuleSelector"}}},preview:{description:"Whether to enable preview mode. When preview mode is enabled, Ruff will use unstable rules and fixes.",type:["boolean","null"]},pycodestyle:{description:"Options for the `pycodestyle` plugin.",anyOf:[{$ref:"#/definitions/PycodestyleOptions"},{type:"null"}]},pydocstyle:{description:"Options for the `pydocstyle` plugin.",anyOf:[{$ref:"#/definitions/PydocstyleOptions"},{type:"null"}]},pyflakes:{description:"Options for the `pyflakes` plugin.",anyOf:[{$ref:"#/definitions/PyflakesOptions"},{type:"null"}]},pylint:{description:"Options for the `pylint` plugin.",anyOf:[{$ref:"#/definitions/PylintOptions"},{type:"null"}]},pyupgrade:{description:"Options for the `pyupgrade` plugin.",anyOf:[{$ref:"#/definitions/PyUpgradeOptions"},{type:"null"}]},ruff:{description:"Options for the `ruff` plugin",anyOf:[{$ref:"#/definitions/RuffOptions"},{type:"null"}]},select:{description:"A list of rule codes or prefixes to enable. Prefixes can specify exact rules (like `F841`), entire categories (like `F`), or anything in between.\n\nWhen breaking ties between enabled and disabled rules (via `select` and `ignore`, respectively), more specific prefixes override less specific prefixes.",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}},"task-tags":{description:'A list of task tags to recognize (e.g., "TODO", "FIXME", "XXX").\n\nComments starting with these tags will be ignored by commented-out code detection (`ERA`), and skipped by line-length rules (`E501`) if [`ignore-overlong-task-comments`](#lint_pycodestyle_ignore-overlong-task-comments) is set to `true`.',type:["array","null"],items:{type:"string"}},"typing-modules":{description:"A list of modules whose exports should be treated equivalently to members of the `typing` module.\n\nThis is useful for ensuring proper type annotation inference for projects that re-export `typing` and `typing_extensions` members from a compatibility module. If omitted, any members imported from modules apart from `typing` and `typing_extensions` will be treated as ordinary Python objects.",type:["array","null"],items:{type:"string"}},unfixable:{description:"A list of rule codes or prefixes to consider non-fixable.",type:["array","null"],items:{$ref:"#/definitions/RuleSelector"}}},additionalProperties:!1},McCabeOptions:{type:"object",properties:{"max-complexity":{description:"The maximum McCabe complexity to allow before triggering `C901` errors.",type:["integer","null"],format:"uint",minimum:0}},additionalProperties:!1},NameImports:{type:"string"},OutputFormat:{oneOf:[{type:"string",enum:["concise","full","json","json-lines","junit","grouped","github","gitlab","pylint","rdjson","azure","sarif"]},{deprecated:!0,type:"string",enum:["text"]}]},ParametrizeNameType:{type:"string",enum:["csv","tuple","list"]},ParametrizeValuesRowType:{type:"string",enum:["tuple","list"]},ParametrizeValuesType:{type:"string",enum:["tuple","list"]},Pep8NamingOptions:{type:"object",properties:{"classmethod-decorators":{description:"A list of decorators that, when applied to a method, indicate that the method should be treated as a class method (in addition to the builtin `@classmethod`).\n\nFor example, Ruff will expect that any method decorated by a decorator in this list takes a `cls` argument as its first argument.\n\nExpects to receive a list of fully-qualified names (e.g., `pydantic.validator`, rather than `validator`) or alternatively a plain name which is then matched against the last segment in case the decorator itself consists of a dotted name.",type:["array","null"],items:{type:"string"}},"extend-ignore-names":{description:'Additional names (or patterns) to ignore when considering `pep8-naming` violations, in addition to those included in [`ignore-names`](#lint_pep8-naming_ignore-names).\n\nSupports glob patterns. For example, to ignore all names starting with `test_` or ending with `_test`, you could use `ignore-names = ["test_*", "*_test"]`. For more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).',type:["array","null"],items:{type:"string"}},"ignore-names":{description:'A list of names (or patterns) to ignore when considering `pep8-naming` violations.\n\nSupports glob patterns. For example, to ignore all names starting with `test_` or ending with `_test`, you could use `ignore-names = ["test_*", "*_test"]`. For more information on the glob syntax, refer to the [`globset` documentation](https://docs.rs/globset/latest/globset/#syntax).',type:["array","null"],items:{type:"string"}},"staticmethod-decorators":{description:"A list of decorators that, when applied to a method, indicate that the method should be treated as a static method (in addition to the builtin `@staticmethod`).\n\nFor example, Ruff will expect that any method decorated by a decorator in this list has no `self` or `cls` argument.\n\nExpects to receive a list of fully-qualified names (e.g., `belay.Device.teardown`, rather than `teardown`) or alternatively a plain name which is then matched against the last segment in case the decorator itself consists of a dotted name.",type:["array","null"],items:{type:"string"}}},additionalProperties:!1},PyUpgradeOptions:{type:"object",properties:{"keep-runtime-typing":{description:"Whether to avoid [PEP 585](https://peps.python.org/pep-0585/) (`List[int]` -> `list[int]`) and [PEP 604](https://peps.python.org/pep-0604/) (`Union[str, int]` -> `str | int`) rewrites even if a file imports `from __future__ import annotations`.\n\nThis setting is only applicable when the target Python version is below 3.9 and 3.10 respectively, and is most commonly used when working with libraries like Pydantic and FastAPI, which rely on the ability to parse type annotations at runtime. The use of `from __future__ import annotations` causes Python to treat the type annotations as strings, which typically allows for the use of language features that appear in later Python versions but are not yet supported by the current version (e.g., `str | int`). However, libraries that rely on runtime type annotations will break if the annotations are incompatible with the current Python version.\n\nFor example, while the following is valid Python 3.8 code due to the presence of `from __future__ import annotations`, the use of `str | int` prior to Python 3.10 will cause Pydantic to raise a `TypeError` at runtime:\n\n```python from __future__ import annotations\n\nimport pydantic\n\nclass Foo(pydantic.BaseModel): bar: str | int ```",type:["boolean","null"]}},additionalProperties:!1},PycodestyleOptions:{type:"object",properties:{"ignore-overlong-task-comments":{description:'Whether line-length violations (`E501`) should be triggered for comments starting with [`task-tags`](#lint_task-tags) (by default: "TODO", "FIXME", and "XXX").',type:["boolean","null"]},"max-doc-length":{description:"The maximum line length to allow for [`doc-line-too-long`](https://docs.astral.sh/ruff/rules/doc-line-too-long/) violations within documentation (`W505`), including standalone comments. By default, this is set to `null` which disables reporting violations.\n\nThe length is determined by the number of characters per line, except for lines containing Asian characters or emojis. For these lines, the [unicode width](https://unicode.org/reports/tr11/) of each character is added up to determine the length.\n\nSee the [`doc-line-too-long`](https://docs.astral.sh/ruff/rules/doc-line-too-long/) rule for more information.",anyOf:[{$ref:"#/definitions/LineLength"},{type:"null"}]},"max-line-length":{description:"The maximum line length to allow for [`line-too-long`](https://docs.astral.sh/ruff/rules/line-too-long/) violations. By default, this is set to the value of the [`line-length`](#line-length) option.\n\nUse this option when you want to detect extra-long lines that the formatter can't automatically split by setting `pycodestyle.line-length` to a value larger than [`line-length`](#line-length).\n\n```toml # The formatter wraps lines at a length of 88. line-length = 88\n\n[pycodestyle] # E501 reports lines that exceed the length of 100. max-line-length = 100 ```\n\nThe length is determined by the number of characters per line, except for lines containing East Asian characters or emojis. For these lines, the [unicode width](https://unicode.org/reports/tr11/) of each character is added up to determine the length.\n\nSee the [`line-too-long`](https://docs.astral.sh/ruff/rules/line-too-long/) rule for more information.",anyOf:[{$ref:"#/definitions/LineLength"},{type:"null"}]}},additionalProperties:!1},PydocstyleOptions:{type:"object",properties:{convention:{description:'Whether to use Google-style, NumPy-style conventions, or the [PEP 257](https://peps.python.org/pep-0257/) defaults when analyzing docstring sections.\n\nEnabling a convention will disable all rules that are not included in the specified convention. As such, the intended workflow is to enable a convention and then selectively enable or disable any additional rules on top of it.\n\nFor example, to use Google-style conventions but avoid requiring documentation for every function parameter:\n\n```toml [tool.ruff.lint] # Enable all `pydocstyle` rules, limiting to those that adhere to the # Google convention via `convention = "google"`, below. select = ["D"]\n\n# On top of the Google convention, disable `D417`, which requires # documentation for every function parameter. ignore = ["D417"]\n\n[tool.ruff.lint.pydocstyle] convention = "google" ```\n\nTo enable an additional rule that\'s excluded from the convention, select the desired rule via its fully qualified rule code (e.g., `D400` instead of `D4` or `D40`):\n\n```toml [tool.ruff.lint] # Enable D400 on top of the Google convention. extend-select = ["D400"]\n\n[tool.ruff.lint.pydocstyle] convention = "google" ```',anyOf:[{$ref:"#/definitions/Convention"},{type:"null"}]},"ignore-decorators":{description:"Ignore docstrings for functions or methods decorated with the specified fully-qualified decorators.",type:["array","null"],items:{type:"string"}},"property-decorators":{description:"A list of decorators that, when applied to a method, indicate that the method should be treated as a property (in addition to the builtin `@property` and standard-library `@functools.cached_property`).\n\nFor example, Ruff will expect that any method decorated by a decorator in this list can use a non-imperative summary line.",type:["array","null"],items:{type:"string"}}},additionalProperties:!1},PyflakesOptions:{type:"object",properties:{"extend-generics":{description:'Additional functions or classes to consider generic, such that any subscripts should be treated as type annotation (e.g., `ForeignKey` in `django.db.models.ForeignKey["User"]`.\n\nExpects to receive a list of fully-qualified names (e.g., `django.db.models.ForeignKey`, rather than `ForeignKey`).',type:["array","null"],items:{type:"string"}}},additionalProperties:!1},PylintOptions:{type:"object",properties:{"allow-dunder-method-names":{description:"Dunder methods name to allow, in addition to the default set from the Python standard library (see `PLW3201`).",type:["array","null"],items:{type:"string"},uniqueItems:!0},"allow-magic-value-types":{description:'Constant types to ignore when used as "magic values" (see `PLR2004`).',type:["array","null"],items:{$ref:"#/definitions/ConstantType"}},"max-args":{description:"Maximum number of arguments allowed for a function or method definition (see `PLR0913`).",type:["integer","null"],format:"uint",minimum:0},"max-bool-expr":{description:"Maximum number of Boolean expressions allowed within a single `if` statement (see `PLR0916`).",type:["integer","null"],format:"uint",minimum:0},"max-branches":{description:"Maximum number of branches allowed for a function or method body (see `PLR0912`).",type:["integer","null"],format:"uint",minimum:0},"max-locals":{description:"Maximum number of local variables allowed for a function or method body (see `PLR0914`).",type:["integer","null"],format:"uint",minimum:0},"max-nested-blocks":{description:"Maximum number of nested blocks allowed within a function or method body (see `PLR1702`).",type:["integer","null"],format:"uint",minimum:0},"max-positional-args":{description:"Maximum number of positional arguments allowed for a function or method definition (see `PLR0917`).\n\nIf not specified, defaults to the value of `max-args`.",type:["integer","null"],format:"uint",minimum:0},"max-public-methods":{description:"Maximum number of public methods allowed for a class (see `PLR0904`).",type:["integer","null"],format:"uint",minimum:0},"max-returns":{description:"Maximum number of return statements allowed for a function or method body (see `PLR0911`)",type:["integer","null"],format:"uint",minimum:0},"max-statements":{description:"Maximum number of statements allowed for a function or method body (see `PLR0915`).",type:["integer","null"],format:"uint",minimum:0}},additionalProperties:!1},PythonVersion:{type:"string",enum:["py37","py38","py39","py310","py311","py312","py313"]},Quote:{oneOf:[{description:"Use double quotes.",type:"string",enum:["double"]},{description:"Use single quotes.",type:"string",enum:["single"]}]},QuoteStyle:{type:"string",enum:["single","double","preserve"]},RelativeImportsOrder:{oneOf:[{description:'Place "closer" imports (fewer `.` characters, most local) before "further" imports (more `.` characters, least local).',type:"string",enum:["closest-to-furthest"]},{description:'Place "further" imports (more `.` characters, least local) imports before "closer" imports (fewer `.` characters, most local).',type:"string",enum:["furthest-to-closest"]}]},RequiredVersion:{type:"string"},RuffOptions:{type:"object",properties:{"parenthesize-tuple-in-subscript":{description:"Whether to prefer accessing items keyed by tuples with parentheses around the tuple (see `RUF031`).",type:["boolean","null"]}},additionalProperties:!1},RuleSelector:{type:"string",enum:["A","A0","A00","A001","A002","A003","A004","A005","A006","AIR","AIR0","AIR00","AIR001","ALL","ANN","ANN0","ANN00","ANN001","ANN002","ANN003","ANN1","ANN10","ANN101","ANN102","ANN2","ANN20","ANN201","ANN202","ANN204","ANN205","ANN206","ANN4","ANN40","ANN401","ARG","ARG0","ARG00","ARG001","ARG002","ARG003","ARG004","ARG005","ASYNC","ASYNC1","ASYNC10","ASYNC100","ASYNC105","ASYNC109","ASYNC11","ASYNC110","ASYNC115","ASYNC116","ASYNC2","ASYNC21","ASYNC210","ASYNC22","ASYNC220","ASYNC221","ASYNC222","ASYNC23","ASYNC230","ASYNC25","ASYNC251","B","B0","B00","B002","B003","B004","B005","B006","B007","B008","B009","B01","B010","B011","B012","B013","B014","B015","B016","B017","B018","B019","B02","B020","B021","B022","B023","B024","B025","B026","B027","B028","B029","B03","B030","B031","B032","B033","B034","B035","B039","B9","B90","B901","B904","B905","B909","BLE","BLE0","BLE00","BLE001","C","C4","C40","C400","C401","C402","C403","C404","C405","C406","C408","C409","C41","C410","C411","C413","C414","C415","C416","C417","C418","C419","C42","C420","C9","C90","C901","COM","COM8","COM81","COM812","COM818","COM819","CPY","CPY0","CPY00","CPY001","D","D1","D10","D100","D101","D102","D103","D104","D105","D106","D107","D2","D20","D200","D201","D202","D203","D204","D205","D206","D207","D208","D209","D21","D210","D211","D212","D213","D214","D215","D3","D30","D300","D301","D4","D40","D400","D401","D402","D403","D404","D405","D406","D407","D408","D409","D41","D410","D411","D412","D413","D414","D415","D416","D417","D418","D419","DJ","DJ0","DJ00","DJ001","DJ003","DJ006","DJ007","DJ008","DJ01","DJ012","DJ013","DOC","DOC2","DOC20","DOC201","DOC202","DOC4","DOC40","DOC402","DOC403","DOC5","DOC50","DOC501","DOC502","DTZ","DTZ0","DTZ00","DTZ001","DTZ002","DTZ003","DTZ004","DTZ005","DTZ006","DTZ007","DTZ01","DTZ011","DTZ012","E","E1","E10","E101","E11","E111","E112","E113","E114","E115","E116","E117","E2","E20","E201","E202","E203","E204","E21","E211","E22","E221","E222","E223","E224","E225","E226","E227","E228","E23","E231","E24","E241","E242","E25","E251","E252","E26","E261","E262","E265","E266","E27","E271","E272","E273","E274","E275","E3","E30","E301","E302","E303","E304","E305","E306","E4","E40","E401","E402","E5","E50","E501","E502","E7","E70","E701","E702","E703","E71","E711","E712","E713","E714","E72","E721","E722","E73","E731","E74","E741","E742","E743","E9","E90","E902","E99","E999","EM","EM1","EM10","EM101","EM102","EM103","ERA","ERA0","ERA00","ERA001","EXE","EXE0","EXE00","EXE001","EXE002","EXE003","EXE004","EXE005","F","F4","F40","F401","F402","F403","F404","F405","F406","F407","F5","F50","F501","F502","F503","F504","F505","F506","F507","F508","F509","F52","F521","F522","F523","F524","F525","F54","F541","F6","F60","F601","F602","F62","F621","F622","F63","F631","F632","F633","F634","F7","F70","F701","F702","F704","F706","F707","F72","F722","F8","F81","F811","F82","F821","F822","F823","F84","F841","F842","F9","F90","F901","FA","FA1","FA10","FA100","FA102","FAST","FAST0","FAST00","FAST001","FAST002","FAST003","FBT","FBT0","FBT00","FBT001","FBT002","FBT003","FIX","FIX0","FIX00","FIX001","FIX002","FIX003","FIX004","FLY","FLY0","FLY00","FLY002","FURB","FURB1","FURB10","FURB101","FURB103","FURB105","FURB11","FURB110","FURB113","FURB116","FURB118","FURB12","FURB129","FURB13","FURB131","FURB132","FURB136","FURB14","FURB140","FURB142","FURB145","FURB148","FURB15","FURB152","FURB154","FURB157","FURB16","FURB161","FURB163","FURB164","FURB166","FURB167","FURB168","FURB169","FURB17","FURB171","FURB177","FURB18","FURB180","FURB181","FURB187","FURB19","FURB192","G","G0","G00","G001","G002","G003","G004","G01","G010","G1","G10","G101","G2","G20","G201","G202","I","I0","I00","I001","I002","ICN","ICN0","ICN00","ICN001","ICN002","ICN003","INP","INP0","INP00","INP001","INT","INT0","INT00","INT001","INT002","INT003","ISC","ISC0","ISC00","ISC001","ISC002","ISC003","LOG","LOG0","LOG00","LOG001","LOG002","LOG007","LOG009","N","N8","N80","N801","N802","N803","N804","N805","N806","N807","N81","N811","N812","N813","N814","N815","N816","N817","N818","N9","N99","N999","NPY","NPY0","NPY00","NPY001","NPY002","NPY003","NPY2","NPY20","NPY201","PD","PD0","PD00","PD002","PD003","PD004","PD007","PD008","PD009","PD01","PD010","PD011","PD012","PD013","PD015","PD1","PD10","PD101","PD9","PD90","PD901","PERF","PERF1","PERF10","PERF101","PERF102","PERF2","PERF20","PERF203","PERF4","PERF40","PERF401","PERF402","PERF403","PGH","PGH0","PGH00","PGH003","PGH004","PGH005","PIE","PIE7","PIE79","PIE790","PIE794","PIE796","PIE8","PIE80","PIE800","PIE804","PIE807","PIE808","PIE81","PIE810","PL","PLC","PLC0","PLC01","PLC010","PLC0105","PLC013","PLC0131","PLC0132","PLC02","PLC020","PLC0205","PLC0206","PLC0208","PLC04","PLC041","PLC0414","PLC0415","PLC1","PLC19","PLC190","PLC1901","PLC2","PLC24","PLC240","PLC2401","PLC2403","PLC27","PLC270","PLC2701","PLC28","PLC280","PLC2801","PLC3","PLC30","PLC300","PLC3002","PLE","PLE0","PLE01","PLE010","PLE0100","PLE0101","PLE011","PLE0115","PLE0116","PLE0117","PLE0118","PLE02","PLE023","PLE0237","PLE024","PLE0241","PLE03","PLE030","PLE0302","PLE0303","PLE0304","PLE0305","PLE0307","PLE0308","PLE0309","PLE06","PLE060","PLE0604","PLE0605","PLE064","PLE0643","PLE07","PLE070","PLE0704","PLE1","PLE11","PLE113","PLE1132","PLE114","PLE1141","PLE1142","PLE12","PLE120","PLE1205","PLE1206","PLE13","PLE130","PLE1300","PLE1307","PLE131","PLE1310","PLE15","PLE150","PLE1507","PLE151","PLE1519","PLE152","PLE1520","PLE17","PLE170","PLE1700","PLE2","PLE25","PLE250","PLE2502","PLE251","PLE2510","PLE2512","PLE2513","PLE2514","PLE2515","PLE4","PLE47","PLE470","PLE4703","PLR","PLR0","PLR01","PLR012","PLR0124","PLR013","PLR0133","PLR02","PLR020","PLR0202","PLR0203","PLR0206","PLR04","PLR040","PLR0402","PLR09","PLR090","PLR0904","PLR091","PLR0911","PLR0912","PLR0913","PLR0914","PLR0915","PLR0916","PLR0917","PLR1","PLR17","PLR170","PLR1702","PLR1704","PLR171","PLR1711","PLR1714","PLR172","PLR1722","PLR173","PLR1730","PLR1733","PLR1736","PLR2","PLR20","PLR200","PLR2004","PLR204","PLR2044","PLR5","PLR55","PLR550","PLR5501","PLR6","PLR61","PLR610","PLR6104","PLR62","PLR620","PLR6201","PLR63","PLR630","PLR6301","PLW","PLW0","PLW01","PLW010","PLW0108","PLW012","PLW0120","PLW0127","PLW0128","PLW0129","PLW013","PLW0131","PLW0133","PLW017","PLW0177","PLW02","PLW021","PLW0211","PLW024","PLW0245","PLW04","PLW040","PLW0406","PLW06","PLW060","PLW0602","PLW0603","PLW0604","PLW064","PLW0642","PLW07","PLW071","PLW0711","PLW1","PLW15","PLW150","PLW1501","PLW1508","PLW1509","PLW151","PLW1510","PLW1514","PLW16","PLW164","PLW1641","PLW2","PLW21","PLW210","PLW2101","PLW29","PLW290","PLW2901","PLW3","PLW32","PLW320","PLW3201","PLW33","PLW330","PLW3301","PT","PT0","PT00","PT001","PT002","PT003","PT004","PT005","PT006","PT007","PT008","PT009","PT01","PT010","PT011","PT012","PT013","PT014","PT015","PT016","PT017","PT018","PT019","PT02","PT020","PT021","PT022","PT023","PT024","PT025","PT026","PT027","PTH","PTH1","PTH10","PTH100","PTH101","PTH102","PTH103","PTH104","PTH105","PTH106","PTH107","PTH108","PTH109","PTH11","PTH110","PTH111","PTH112","PTH113","PTH114","PTH115","PTH116","PTH117","PTH118","PTH119","PTH12","PTH120","PTH121","PTH122","PTH123","PTH124","PTH2","PTH20","PTH201","PTH202","PTH203","PTH204","PTH205","PTH206","PTH207","PYI","PYI0","PYI00","PYI001","PYI002","PYI003","PYI004","PYI005","PYI006","PYI007","PYI008","PYI009","PYI01","PYI010","PYI011","PYI012","PYI013","PYI014","PYI015","PYI016","PYI017","PYI018","PYI019","PYI02","PYI020","PYI021","PYI024","PYI025","PYI026","PYI029","PYI03","PYI030","PYI032","PYI033","PYI034","PYI035","PYI036","PYI04","PYI041","PYI042","PYI043","PYI044","PYI045","PYI046","PYI047","PYI048","PYI049","PYI05","PYI050","PYI051","PYI052","PYI053","PYI054","PYI055","PYI056","PYI057","PYI058","PYI059","PYI06","PYI062","PYI063","PYI064","PYI066","Q","Q0","Q00","Q000","Q001","Q002","Q003","Q004","RET","RET5","RET50","RET501","RET502","RET503","RET504","RET505","RET506","RET507","RET508","RSE","RSE1","RSE10","RSE102","RUF","RUF0","RUF00","RUF001","RUF002","RUF003","RUF005","RUF006","RUF007","RUF008","RUF009","RUF01","RUF010","RUF012","RUF013","RUF015","RUF016","RUF017","RUF018","RUF019","RUF02","RUF020","RUF021","RUF022","RUF023","RUF024","RUF026","RUF027","RUF028","RUF029","RUF03","RUF030","RUF031","RUF032","RUF033","RUF034","RUF1","RUF10","RUF100","RUF101","RUF2","RUF20","RUF200","S","S1","S10","S101","S102","S103","S104","S105","S106","S107","S108","S11","S110","S112","S113","S2","S20","S201","S202","S3","S30","S301","S302","S303","S304","S305","S306","S307","S308","S31","S310","S311","S312","S313","S314","S315","S316","S317","S318","S319","S32","S320","S321","S323","S324","S4","S40","S401","S402","S403","S404","S405","S406","S407","S408","S409","S41","S411","S412","S413","S415","S5","S50","S501","S502","S503","S504","S505","S506","S507","S508","S509","S6","S60","S601","S602","S603","S604","S605","S606","S607","S608","S609","S61","S610","S611","S612","S7","S70","S701","S702","SIM","SIM1","SIM10","SIM101","SIM102","SIM103","SIM105","SIM107","SIM108","SIM109","SIM11","SIM110","SIM112","SIM113","SIM114","SIM115","SIM116","SIM117","SIM118","SIM2","SIM20","SIM201","SIM202","SIM208","SIM21","SIM210","SIM211","SIM212","SIM22","SIM220","SIM221","SIM222","SIM223","SIM3","SIM30","SIM300","SIM4","SIM40","SIM401","SIM9","SIM91","SIM910","SIM911","SLF","SLF0","SLF00","SLF001","SLOT","SLOT0","SLOT00","SLOT000","SLOT001","SLOT002","T","T1","T10","T100","T2","T20","T201","T203","TCH","TCH0","TCH00","TCH001","TCH002","TCH003","TCH004","TCH005","TCH01","TCH010","TD","TD0","TD00","TD001","TD002","TD003","TD004","TD005","TD006","TD007","TID","TID2","TID25","TID251","TID252","TID253","TRY","TRY0","TRY00","TRY002","TRY003","TRY004","TRY2","TRY20","TRY201","TRY3","TRY30","TRY300","TRY301","TRY302","TRY4","TRY40","TRY400","TRY401","UP","UP0","UP00","UP001","UP003","UP004","UP005","UP006","UP007","UP008","UP009","UP01","UP010","UP011","UP012","UP013","UP014","UP015","UP017","UP018","UP019","UP02","UP020","UP021","UP022","UP023","UP024","UP025","UP026","UP027","UP028","UP029","UP03","UP030","UP031","UP032","UP033","UP034","UP035","UP036","UP037","UP038","UP039","UP04","UP040","UP041","UP042","UP043","W","W1","W19","W191","W2","W29","W291","W292","W293","W3","W39","W391","W5","W50","W505","W6","W60","W605","YTT","YTT1","YTT10","YTT101","YTT102","YTT103","YTT2","YTT20","YTT201","YTT202","YTT203","YTT204","YTT3","YTT30","YTT301","YTT302","YTT303"]},Strictness:{oneOf:[{description:"Ban imports that extend into the parent module or beyond.",type:"string",enum:["parents"]},{description:"Ban all relative imports.",type:"string",enum:["all"]}]}}};function Ar(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function Zv(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Ar(a,r,i,o,s,"next",l)}function s(l){Ar(a,r,i,o,s,"throw",l)}o(void 0)})}}var So=Gs.parse("inmemory://dh-config/ruff-settings.json");function eb(){var{schemas:t=[]}=bn.json.jsonDefaults.diagnosticsOptions;t.some(e=>e.uri==="json://ruff-schema")||bn.json.jsonDefaults.setDiagnosticsOptions({schemas:[...t,{uri:"json://ruff-schema",fileMatch:[So.toString()],schema:Jv}]})}function tb(){return Nt.apply(this,arguments)}function Nt(){return Nt=Zv(function*(){return yield Gi.initRuff(),"v".concat(Ys.version())}),Nt.apply(this,arguments)}function nb(t){var{text:e,isOpen:n,onClose:r,onSave:i,readOnly:a=!1,defaultSettings:o=Vi}=t,[s,l]=c.useState(!1),[d,f]=c.useState(!1),p=c.useRef(),h=c.useMemo(()=>JSON.stringify(o,null,2),[o]),{data:m}=Oe(tb),[g]=c.useState(()=>Vs.createModel(e,"json",So)),P=c.useCallback(()=>{n&&(r(),p.current=void 0,g.dispose())},[n,r,g]),v=c.useCallback(()=>{if(n){try{var b,S;i(JSON.parse((b=(S=p.current)===null||S===void 0||(S=S.getModel())===null||S===void 0?void 0:S.getValue())!==null&&b!==void 0?b:""))}catch{}P()}},[n,P,i]),y=c.useCallback(()=>{Ze(g),g.setValue(h)},[g,h]),x=c.useCallback(b=>{var S;try{JSON.parse(b),l(!0)}catch{l(!1)}f(((S=p.current)===null||S===void 0||(S=S.getModel())===null||S===void 0?void 0:S.getValue())===h)},[h]),w=Ie(x,500,{leading:!0}),j=c.useCallback(b=>{p.current=b,g.onDidChangeContent(()=>{w(g.getValue())}),eb(),w(g.getValue())},[w,g]);return n?u.jsxs(Yt,{isOpen:n,centered:!0,keyboard:!0,clickOutside:!1,toggle:P,size:"lg",className:"ruff-settings-modal",children:[u.jsxs(fi,{closeButton:!1,children:[u.jsxs("span",{className:"settings-modal-title mr-auto",children:["Ruff ",m," Settings"]}),u.jsx(ri,{href:"https://docs.astral.sh/ruff/settings/",target:"_blank",children:u.jsx(G,{kind:"ghost",onClick:ne,icon:Jl,children:"Settings Docs"})}),u.jsxs(Qe,{isDisabled:d,onPress:y,children:[u.jsx(Le,{children:u.jsx(Y,{icon:Zl})}),u.jsx(lt,{children:"Reset to default"})]})]}),u.jsx(Kt,{style:{height:"80vh"},children:u.jsx(ta,{onEditorInitialized:j,settings:{readOnly:a,value:e,language:"json",folding:!0,padding:{bottom:16},lineNumbers:"on",overviewRulerLanes:0,model:g}})}),u.jsx(wi,{children:a?u.jsx(G,{kind:"secondary","data-dismiss":"modal",onClick:P,children:"Close"}):u.jsxs(u.Fragment,{children:[u.jsx(G,{kind:"secondary","data-dismiss":"modal",onClick:P,children:"Cancel"}),u.jsx(G,{kind:"primary","data-dismiss":"modal",tooltip:s?void 0:"Cannot save invalid JSON",disabled:!s,onClick:v,children:"Save"})]})})]}):null}const rb=Object.freeze(Object.defineProperty({__proto__:null,Code:Zc,CommandHistory:ed,CommandHistoryActions:td,CommandHistoryItem:nd,CommandHistoryItemTooltip:rd,Console:On,ConsoleConstants:id,ConsoleHistory:ad,ConsoleHistoryItem:od,ConsoleHistoryItemResult:sd,ConsoleHistoryResultErrorMessage:ld,ConsoleHistoryResultInProgress:ud,ConsoleInput:cd,ConsoleStatusBar:dd,ConsoleUtils:pd,Editor:ta,HeapUsage:fd,LogView:hd,MonacoProviders:Gi,MonacoTheme:md,MonacoThemeProvider:Oo,MonacoUtils:Hi,ObjectIcon:gd,RUFF_DEFAULT_SETTINGS:Vi,RuffSettingsModal:nb,SHORTCUTS:yd,ScriptEditor:Zd,ScriptEditorUtils:ep,default:On},Symbol.toStringTag,{value:"Module"}));function Eo(t,e,n){return(e=ib(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function ib(t){var e=ab(t,"string");return typeof e=="symbol"?e:e+""}function ab(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}class we{static valueForCell(e,n,r){var i="".concat(e,",").concat(n);return r!==void 0&&r&&(i="(".concat(i,")")),i}constructor(e){Eo(this,"dh",void 0),this.dh=e}makeColumn(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:we.DEFAULT_TYPE,r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;return new this.dh.Column({index:r,name:e,type:n})}makeRollupTableConfig(){return new this.dh.RollupTableConfig}makeColumns(){for(var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:5,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",r=[],i=0;i<e;i+=1)r.push(this.makeColumn("".concat(n).concat(i),we.DEFAULT_TYPE,i));return r}static makeUserColumnWidths(){for(var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:5,n=new Map,r=0;r<e;r+=1)n.set(r.toString(),100);return n}makeRow(e){var n=new this.dh.Row({index:e,name:"".concat(e)});return n.get=jest.fn(r=>we.valueForCell(e,r.index)),n}makeFilter(){return new this.dh.FilterCondition}makeSort(){return new this.dh.Sort}makeTable(){var{columns:e=this.makeColumns(),size:n=1e9,sort:r=[],layoutHints:i={}}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},a=new this.dh.Table({columns:e,size:n,sort:r});return a.copy=jest.fn(()=>Promise.resolve(a)),a.freeze=jest.fn(()=>Promise.resolve(a)),a.layoutHints=i,a}makeTreeTable(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.makeColumns(),n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1e9,a=arguments.length>4&&arguments[4]!==void 0?arguments[4]:[],o=arguments.length>5?arguments[5]:void 0,s=new this.dh.TreeTable({columns:e,aggregatedColumns:n,groupedColumns:r,size:i,sort:a,layoutHints:o});return s.copy=jest.fn(()=>Promise.resolve(s)),s}makeInputTable(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return new this.dh.InputTable(e)}makeSubscription(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.makeTable();return new this.dh.TableViewportSubscription({table:e})}makeModel(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.makeTable(),n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null,r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null,{dh:i}=this;return new tp(i,e,n??new en(i),r)}}Eo(we,"DEFAULT_TYPE","java.lang.String");const ob=Object.freeze(Object.defineProperty({__proto__:null,AdvancedSettings:np,AdvancedSettingsType:rp,AggregationEdit:Nf,AggregationOperation:ip,AggregationUtils:ap,Aggregations:Mf,BarIcon:$f,ChartBuilder:Uf,ColumnHeaderGroup:op,CustomColumnBuilder:Bf,DownloadServiceWorkerUtils:Wf,FormatColumnWhereIcon:Hf,FormatRowWhereIcon:Vf,HistogramIcon:Gf,InputEditor:Yf,IrisGrid:Sn,IrisGridCacheUtils:sp,IrisGridCellOverflowMouseHandler:Kf,IrisGridCellRendererUtils:zf,IrisGridColumnSelectMouseHandler:qf,IrisGridColumnTooltipMouseHandler:Xf,IrisGridContextMenuHandler:Qf,IrisGridCopyCellMouseHandler:Jf,IrisGridDataSelectMouseHandler:Zf,IrisGridFilterMouseHandler:eh,IrisGridMetricCalculator:th,IrisGridModel:lp,IrisGridModelFactory:up,IrisGridPartitionedTableModel:cp,IrisGridPartitionedTableMouseHandler:nh,IrisGridRenderer:rh,IrisGridRowTreeMouseHandler:ih,IrisGridSortMouseHandler:ah,IrisGridTableModel:dp,IrisGridTableModelTemplate:pp,IrisGridTestUtils:we,IrisGridThemeContext:oh,IrisGridThemeProvider:ga,IrisGridTokenMouseHandler:sh,IrisGridTreeTableModel:fp,IrisGridUtils:hp,LineIcon:lh,OptionType:uh,PendingMouseHandler:ch,PieIcon:dh,RollupRows:ph,SHORTCUTS:fh,ScatterIcon:hh,TableCsvExporter:mh,TableSaver:gh,VisibilityOrderingBuilder:yh,createDefaultIrisGridTheme:vh,default:Sn,isColumnHeaderGroup:mp,isIrisGridTableModelTemplate:gp,isIrisGridTreeTableModel:yp,isPanelStateV1:vp,isPanelStateV2:bp,isPartitionedGridModel:Pp,isPartitionedGridModelProvider:xp,isUITreeRow:wp},Symbol.toStringTag,{value:"Module"}));var Co={react:U,"react-dom":Xs,redux:qs,"react-redux":zs,"@adobe/react-spectrum":Ks,"@deephaven/auth-plugins":Gv,"@deephaven/chart":zv,"@deephaven/components":gy,"@deephaven/console":rb,"@deephaven/dashboard":Qv,"@deephaven/dashboard-core-plugins":Op,"@deephaven/icons":eu,"@deephaven/iris-grid":ob,"@deephaven/jsapi-bootstrap":wy,"@deephaven/jsapi-components":bv,"@deephaven/jsapi-utils":Ry,"@deephaven/log":W,"@deephaven/plugin":Ov,"@deephaven/react-hooks":zh},sb=Js.createRequires(Co),lb=Qs({requires:sb});function Fr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Nr(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Fr(Object(n),!0).forEach(function(r){ub(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Fr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function ub(t,e,n){return(e=cb(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function cb(t){var e=db(t,"string");return typeof e=="symbol"?e:e+""}function db(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Mr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function yn(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Mr(a,r,i,o,s,"next",l)}function s(l){Mr(a,r,i,o,s,"throw",l)}o(void 0)})}}var se=W.module("@deephaven/app-utils.PluginUtils");function pb(t){return Mt.apply(this,arguments)}function Mt(){return Mt=yn(function*(t){var e=yield lb(t);return e}),Mt.apply(this,arguments)}function fb(t){return $t.apply(this,arguments)}function $t(){return $t=yn(function*(t){var e=yield fetch(t);if(!e.ok)throw new Error(e.statusText);try{return yield e.json()}catch{throw new Error("Could not be parsed as JSON")}}),$t.apply(this,arguments)}function hb(t){return typeof t=="object"&&t!=null&&typeof t.default=="object"}function mb(t){return Et(t)?t:hb(t)&&Et(t.default)?t.default:Li(t)?t:null}function gb(t){return Ut.apply(this,arguments)}function Ut(){return Ut=yn(function*(t){se.debug("Loading plugins...");try{var e=yield fb("".concat(t,"/manifest.json"));if(!Array.isArray(e.plugins))throw new Error("Plugin manifest JSON does not contain plugins array");se.debug("Plugin manifest loaded:",e);for(var n=[],r=0;r<e.plugins.length;r+=1){var{name:i,main:a}=e.plugins[r],o="".concat(t,"/").concat(i,"/").concat(a);n.push(pb(o))}for(var s=yield Promise.allSettled(n),l=new Map,d=0;d<s.length;d+=1){var f=s[d],{name:p,version:h}=e.plugins[d];if(f.status==="fulfilled"){var m=mb(f.value);m==null?se.error("Plugin '".concat(p,"' is missing an exported value.")):l.set(p,Nr(Nr({},m),{},{version:h}))}else se.error("Unable to load plugin '".concat(p,"'"),f.reason)}return se.info("Plugins loaded:",l),l}catch(g){return se.error("Unable to load plugins:",g),new Map}}),Ut.apply(this,arguments)}function yb(t){var e,n;return(e=(n=t.get("AuthHandlers"))===null||n===void 0?void 0:n.split(","))!==null&&e!==void 0?e:[]}function vb(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:new Map,r=yb(e),i=[...t.entries(),...n.entries()].filter(l=>{var[,d]=l;return Di(d)||St(d)}).map(l=>{var[d,f]=l;return St(f)?{type:Ri.AUTH_PLUGIN,name:d,component:f.AuthPlugin.Component,isAvailable:f.AuthPlugin.isAvailable}:f}),a=i.filter(l=>{var{isAvailable:d}=l;return d(r,e)});if(a.length===0)throw new Error("No login plugins found, please register a login plugin for auth handlers: ".concat(r));a.length>1&&se.warn("More than one login plugin available, will use the first one: ",a.map(l=>{var{name:d}=l;return d}).join(", "));var{name:o,component:s}=a[0];return se.info("Using LoginPlugin",o),s}var bb=ii.createRequires(()=>Co),Qb=ii.createRemoteComponent({requires:bb});function $r(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function Pb(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){$r(a,r,i,o,s,"next",l)}function s(l){$r(a,r,i,o,s,"throw",l)}o(void 0)})}}function xb(t){var{pluginsUrl:e,getCorePlugins:n,children:r}=t,[i,a]=c.useState(null);return c.useEffect(function(){var s=!1;function l(){return d.apply(this,arguments)}function d(){return d=Pb(function*(){var f,p=(f=yield n==null?void 0:n())!==null&&f!==void 0?f:[],h=yield gb(e);if(!s){var m=p.map(g=>[g.name,g]);a(new Map([...m,...h]))}}),d.apply(this,arguments)}return l(),()=>{s=!0}},[e,n]),u.jsx(st.Provider,{value:i,children:r})}function wb(){var t=fn();return c.useEffect(function(){t.postMessage(hi(pn))},[t]),null}function Ur(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function Ob(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Ur(a,r,i,o,s,"next",l)}function s(l){Ur(a,r,i,o,s,"throw",l)}o(void 0)})}}var Sb=new Map([["@deephaven/auth-plugins.AuthPluginParent",{AuthPlugin:go}],["@deephaven/auth-plugins.AuthPluginPsk",{AuthPlugin:Po}],["@deephaven/auth-plugins.AuthPluginAnonymous",{AuthPlugin:mo}]]);function Eb(t){var{children:e}=t,n=Ae(),r=c.useContext(st),[i,a]=c.useState(),[o,s]=c.useState();c.useEffect(function(){var p=!1;function h(){return m.apply(this,arguments)}function m(){return m=Ob(function*(){try{var g=yield n.getAuthConfigValues();p||a(new Map(g))}catch(P){p||s(P)}}),m.apply(this,arguments)}return h(),()=>{p=!0}},[n]);var l=c.useMemo(()=>{if(!(r==null||i==null))try{return vb(r,i,Sb)}catch(f){s(f)}},[i,r]),d=l==null||i==null;return d||o!=null?u.jsx(me,{isLoading:d&&o==null,errorMessage:ke(o),"data-testid":"auth-bootstrap-loading-error"}):u.jsx(l,{authConfigValues:i,children:u.jsxs(u.Fragment,{children:[u.jsx(wb,{}),e]})})}function Br(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function Wr(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Br(a,r,i,o,s,"next",l)}function s(l){Br(a,r,i,o,s,"throw",l)}o(void 0)})}}var Ee=W.module("@deephaven/app-utils.ConnectionBootstrap");function Cb(t){var{children:e}=t,n=ge(),r=Ae(),[i,a]=c.useState(),[o,s]=c.useState(),[l,d]=c.useState("connecting"),f=l==="failed",p=l==="shutdown",h=l==="reconnecting",m=l==="not_connecting";c.useEffect(function(){var x=!1;function w(){return j.apply(this,arguments)}function j(){return j=Wr(function*(){try{var b=yield r.getAsIdeConnection();if(x)return;s(b),d("connected")}catch(S){if(x)return;a(S),d("not_connecting")}}),j.apply(this,arguments)}return w(),()=>{x=!0}},[n,r]),c.useEffect(function(){if(o==null||p)return;function x(j){var{detail:b}=j;Ee.info("Disconnect","".concat(JSON.stringify(b))),d("reconnecting")}var w=o.addEventListener(n.IdeConnection.EVENT_DISCONNECT,x);return w},[n,o,p]),c.useEffect(function(){if(o==null||p)return;function x(j){var{detail:b}=j;Ee.info("Reconnect","".concat(JSON.stringify(b))),d("connected")}var w=o.addEventListener(n.CoreClient.EVENT_RECONNECT,x);return w},[n,o,p]),c.useEffect(function(){if(o==null)return;function x(j){var{detail:b}=j;Ee.info("Shutdown","".concat(JSON.stringify(b))),a("Server shutdown: ".concat(b??"Unknown reason")),d("shutdown")}var w=o.addEventListener(n.IdeConnection.EVENT_SHUTDOWN,x);return w},[n,o]),c.useEffect(function(){if(o==null||p)return;function x(j){var{detail:b}=j;Ee.warn("Reconnect authentication failed","".concat(JSON.stringify(b))),a("Reconnect authentication failed: ".concat(b??"Unknown reason")),d("failed")}var w=o.addEventListener(n.CoreClient.EVENT_RECONNECT_AUTH_FAILED,x);return w},[n,o,p]);var g=c.useCallback(function(){var y=Wr(function*(x){if(Ze(o,"No connection available to fetch object with"),typeof x=="string")throw new Error("No URI resolvers available in Core");return o.getObject(ji(x))});return function(x){return y.apply(this,arguments)}}(),[o]),P=c.useMemo(()=>({subscribe:(y,x)=>(x({fetch:()=>g(y),status:"ready"}),()=>{})}),[g]);function v(){Ee.info("Refreshing application"),window.location.reload()}return p||l==="connecting"||m?u.jsx(me,{"data-testid":"connection-bootstrap-loading",isLoading:!1,errorMessage:i!=null?"".concat(i):void 0}):u.jsx(uu.Provider,{value:o??null,children:u.jsx(Ti.Provider,{value:g,children:u.jsxs(ct.Provider,{value:P,children:[e,u.jsx($a,{isOpen:h,debounceMs:1e3,children:u.jsx(Ua,{icon:tu,title:u.jsxs(u.Fragment,{children:[u.jsx(Je,{})," Attempting to reconnect..."]}),subtitle:"Please check your network connection."})}),u.jsx(xi,{confirmButtonText:"Refresh",onConfirm:v,isOpen:f,headerText:"Authentication failed",bodyText:"Credentials are invalid. Please refresh your browser to try and reconnect."})]})})})}function Jb(t){return new URL(t,"".concat(window.location))}function Tb(){var t=new URLSearchParams(window.location.search);return t.get("envoyPrefix")}function jb(){var t=Tb();return t!=null?{headers:{"envoy-prefix":t}}:{headers:{}}}function Hr(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),n.push.apply(n,r)}return n}function Vr(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Hr(Object(n),!0).forEach(function(r){Ib(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Hr(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Ib(t,e,n){return(e=kb(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function kb(t){var e=_b(t,"string");return typeof e=="symbol"?e:e+""}function _b(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Rb(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return{action:()=>{Ah(nu,Vr(Vr({},t),{},{userAgent:navigator.userAgent}),na.getState())},shortcut:ot.EXPORT_LOGS,isGlobal:e}}function Db(t){var{children:e}=t,n=c.useContext(mn);return n?u.jsx(u.Fragment,{children:e}):u.jsx(me,{"data-testid":"fonts-loaded-loading"})}function Lb(t){var{children:e}=t,n=cu(),r=c.useContext(yi),i=c.useContext(nt),a=wo(n,r,i);return u.jsx(gi.Provider,{value:a,children:e})}function Ab(t){var{children:e}=t,n=Wi(vd),r=c.useContext(st),i=po(r),a=Vt();return u.jsx(Si,{themes:i,waitForActivation:a,children:u.jsx(Ni,{children:u.jsx(Oo,{children:u.jsx(ga,{density:n.gridDensity,children:e})})})})}function Zb(t){var{fontClassNames:e,pluginsUrl:n,getCorePlugins:r,serverUrl:i,logMetadata:a,children:o}=t,s=c.useMemo(()=>jb(),[]),[l,d]=c.useState(0),f=c.useCallback(()=>{},[]),p=c.useCallback(()=>{requestAnimationFrame(()=>{d(m=>m+1)})},[]);hn(f,p);var h=c.useMemo(()=>[Rb(a,!0)],[a]);return u.jsxs(Zs,{store:na,children:[u.jsx(Pv,{fontClassNames:e,children:u.jsx(xb,{getCorePlugins:r,pluginsUrl:n,children:u.jsx(Ab,{children:u.jsxs(mi,{serverUrl:i,options:s,children:[u.jsx(Eb,{children:u.jsx(du,{children:u.jsx(Lb,{children:u.jsx(Cb,{children:u.jsx(Db,{children:o})})})})}),u.jsx(at,{actions:h})]},l)})})}),u.jsx(Ba,{})]})}function Gr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function Fb(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Gr(a,r,i,o,s,"next",l)}function s(l){Gr(a,r,i,o,s,"throw",l)}o(void 0)})}}function ee(t,e,n){return(e=Nb(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Nb(t){var e=Mb(t,"string");return typeof e=="symbol"?e:e+""}function Mb(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Ce=W.module("GrpcFileStorageTable");class De{constructor(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:n;ee(this,"storageService",void 0),ee(this,"baseRoot",void 0),ee(this,"root",void 0),ee(this,"currentSize",0),ee(this,"currentViewport",void 0),ee(this,"listeners",[]),ee(this,"viewportUpdatePromise",void 0),ee(this,"currentViewportData",void 0),ee(this,"childTables",new Map),this.storageService=e,this.baseRoot=n,this.root=r,r===n&&(this.doRefresh=je(this.doRefresh.bind(this),De.REFRESH_DEBOUNCE))}removeBaseRoot(e){return fe.removeRoot(this.baseRoot,e)}getViewportData(){var e;return this.viewportUpdatePromise||this.refreshInternal(),(e=this.viewportUpdatePromise)!==null&&e!==void 0?e:Promise.resolve({items:[],offset:0})}getSnapshot(e){throw new Error("Method not implemented.")}get size(){return this.currentSize}setExpanded(e,n){var r=e.split("/"),i=r.shift();if((i===void 0||i==="")&&(i=r.shift()),i===void 0||i==="")throw new Error("Invalid path: ".concat(e));var a=r.join("/");if(n){if(!this.childTables.has(i)){var o=new De(this.storageService,this.baseRoot,"".concat(this.root,"/").concat(i));this.childTables.set(i,o)}if(a){var s=this.childTables.get(i);s==null||s.setExpanded(a,n)}}else if(this.childTables.has(i))if(a){var l=this.childTables.get(i);l==null||l.setExpanded(a,n)}else this.childTables.delete(i);this.currentViewport&&this.refreshInternal()}collapseAll(){this.childTables.clear(),this.currentViewport&&this.refreshInternal()}setSearch(e){throw new Error("Method not implemented.")}setViewport(e){this.currentViewport=e,this.refreshInternal()}setFilters(){throw new Error("Method not implemented.")}setSorts(){throw new Error("Method not implemented.")}setReversed(){throw new Error("Method not implemented.")}close(){this.listeners=[]}onUpdate(e){return this.listeners=[...this.listeners,e],()=>{this.listeners=this.listeners.filter(n=>n!==e)}}doRefresh(e){Ce.debug2("doRefresh",this.root),e(this.fetchData())}refresh(){var e;Ce.debug2("refresh",this.root),(e=this.viewportUpdatePromise)===null||e===void 0||e.cancel();var n=new Promise(i=>{this.doRefresh(i)}),r=he.makeCancelable(n.then(i=>{if(this.viewportUpdatePromise!==r)throw new Ai;return this.currentViewportData=i,this.sendUpdate(),i}));r.catch(i=>{he.isCanceled(i)||Ce.error("Error updating viewport",i)}),this.viewportUpdatePromise=r}refreshInternal(){try{this.refresh()}catch(e){he.isCanceled(e)||Ce.error("Unable to refresh data",e)}}fetchData(){var e=this;return Fb(function*(){var{currentViewport:n}=e;if(!n)throw new Error("No viewport set");for(var r=yield e.storageService.listItems(e.root),i=r.map(p=>({type:p.type,filename:e.removeBaseRoot(p.filename),basename:p.basename,id:e.removeBaseRoot(p.filename),isExpanded:p.type==="directory"?e.childTables.has(p.basename):void 0})).sort((p,h)=>p.type!==h.type?p.type==="directory"?-1:1:p.basename.localeCompare(h.basename)),a=0;a<i.length;a+=1){var o=i[a],{basename:s,filename:l}=o;if(l===e.removeBaseRoot("".concat(e.root,"/").concat(s))&&o.type==="directory"){var d=e.childTables.get(s);if(d!=null){d.setViewport({top:0,bottom:n.bottom-a});var f=yield d.getViewportData();i.splice(a+1,0,...f.items)}}}return e.currentSize=i.length,Ce.debug2(e.root,"items",i,n),i=i.slice(n.top,n.bottom),{items:i,offset:n.top}})()}sendUpdate(){for(var e,{listeners:n}=this,r=(e=this.currentViewportData)!==null&&e!==void 0?e:{items:[],offset:0},i=0;i<n.length;i+=1)n[i](r)}}ee(De,"REFRESH_DEBOUNCE",50);function Yr(t,e,n,r,i,a,o){try{var s=t[a](o),l=s.value}catch(d){return void n(d)}s.done?e(l):Promise.resolve(l).then(r,i)}function ae(t){return function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function o(l){Yr(a,r,i,o,s,"next",l)}function s(l){Yr(a,r,i,o,s,"throw",l)}o(void 0)})}}function ve(t,e,n){return(e=$b(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function $b(t){var e=Ub(t,"string");return typeof e=="symbol"?e:e+""}function Ub(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Bb=W.module("GrpcFileStorage");class vn{constructor(e,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"";ve(this,"dh",void 0),ve(this,"storageService",void 0),ve(this,"tables",[]),ve(this,"root",void 0),ve(this,"refreshTables",el(()=>{this.tables.forEach(i=>i.refresh())},vn.REFRESH_THROTTLE)),this.dh=e,this.storageService=n,this.root=r}removeRoot(e){return fe.removeRoot(this.root,e)}addRoot(e){return fe.addRoot(this.root,e)}createDirectory(e){var n=this;return ae(function*(){return yield n.storageService.createDirectory(n.addRoot(e)),n.refreshTables(),{type:"directory",id:e,filename:e,basename:fe.getBaseName(e)}})()}getTable(){var e=this;return ae(function*(){var n=new De(e.storageService,e.root);return e.tables.push(n),n})()}saveFile(e){var n=this;return ae(function*(){var r=n.dh.storage.FileContents.text(e.content);return yield n.storageService.saveFile(n.addRoot(e.filename),r,!0),n.refreshTables(),e})()}loadFile(e){var n=this;return ae(function*(){var r=yield n.storageService.loadFile(n.addRoot(e)),i=yield r.text();return{filename:e,basename:fe.getBaseName(e),content:i}})()}copyFile(e,n){var r=this;return ae(function*(){var i=yield r.storageService.loadFile(r.addRoot(e));yield r.storageService.saveFile(r.addRoot(n),i,!1),r.refreshTables()})()}deleteFile(e){var n=this;return ae(function*(){yield n.storageService.deleteItem(n.addRoot(e)),n.refreshTables()})()}moveFile(e,n){var r=this;return ae(function*(){yield r.storageService.moveItem(r.addRoot(e),r.addRoot(n)),r.refreshTables()})()}info(e){var n=this;return ae(function*(){var r=yield n.storageService.listItems(n.addRoot(fe.getPath(e)),fe.getBaseName(e));if(r.length===0)throw new bd;if(r.length>1)throw Bb.error("More than one matching file found, should never happen.",r),new Error("More than one matching file found");var i=r[0];if(!Pd(i.type))throw new Error("Unexpected file type: ".concat(i.type));return{filename:n.removeRoot(i.filename),basename:i.basename,id:n.removeRoot(i.filename),type:i.type}})()}}ve(vn,"REFRESH_THROTTLE",150);export{Zb as AppBootstrap,n0 as AppDashboards,Eb as AuthBootstrap,Cb as ConnectionBootstrap,uu as ConnectionContext,r0 as DEFAULT_LAYOUT_CONFIG,i0 as DEFAULT_LAYOUT_CONFIG_NO_CONSOLE,Pv as FontBootstrap,Db as FontsLoaded,mn as FontsLoadedContext,vn as GrpcFileStorage,De as GrpcFileStorageTable,a0 as GrpcLayoutStorage,o0 as LocalWorkspaceStorage,xb as PluginsBootstrap,Qb as RemoteComponent,Ab as ThemeBootstrap,s0 as UserLayoutUtils,Rb as createExportLogsContextAction,l0 as exportLayout,yb as getAuthHandlers,vb as getAuthPluginComponent,Jb as getBaseUrl,jb as getConnectOptions,u0 as getDefaultLayout,Tb as getEnvoyPrefix,mb as getPluginModuleValue,c0 as isLayoutV1,d0 as isLayoutV2,fb as loadJson,pb as loadModulePlugin,gb as loadModulePlugins,p0 as normalizeLayout,f0 as useConnection,cu as useServerConfig,h0 as useUser};
84
+ //# sourceMappingURL=index-CDtpRL6c.js.map