@odigos/ui-kit 0.0.165 → 0.0.167

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.
@@ -0,0 +1 @@
1
+ import*as t from"react";import{flushSync as e}from"react-dom";function o(t,e){let o;try{o=t()}catch(t){return}return{getItem:t=>{var r;const n=t=>null===t?null:JSON.parse(t,null==e?void 0:e.reviver),a=null!=(r=o.getItem(t))?r:null;return a instanceof Promise?a.then(n):n(a)},setItem:(t,r)=>o.setItem(t,JSON.stringify(r,null==e?void 0:e.replacer)),removeItem:t=>o.removeItem(t)}}const r=t=>e=>{try{const o=t(e);return o instanceof Promise?o:{then:t=>r(t)(o),catch(t){return this}}}catch(t){return{then(t){return this},catch:e=>r(e)(t)}}},n=(t,e)=>(n,a,s)=>{let i={storage:o(()=>localStorage),partialize:t=>t,version:0,merge:(t,e)=>({...e,...t}),...e},l=!1;const c=new Set,d=new Set;let u=i.storage;if(!u)return t((...t)=>{n(...t)},a,s);const h=()=>{const t=i.partialize({...a()});return u.setItem(i.name,{state:t,version:i.version})},f=s.setState;s.setState=(t,e)=>(f(t,e),h());const b=t((...t)=>(n(...t),h()),a,s);let p;s.getInitialState=()=>b;const g=()=>{var t,e;if(!u)return;l=!1,c.forEach(t=>{var e;return t(null!=(e=a())?e:b)});const o=(null==(e=i.onRehydrateStorage)?void 0:e.call(i,null!=(t=a())?t:b))||void 0;return r(u.getItem.bind(u))(i.name).then(t=>{if(t){if("number"!=typeof t.version||t.version===i.version)return[!1,t.state];if(i.migrate){const e=i.migrate(t.state,t.version);return e instanceof Promise?e.then(t=>[!0,t]):[!0,e]}}return[!1,void 0]}).then(t=>{var e;const[o,r]=t;if(p=i.merge(r,null!=(e=a())?e:b),n(p,!0),o)return h()}).then(()=>{null==o||o(p,void 0),p=a(),l=!0,d.forEach(t=>t(p))}).catch(t=>{null==o||o(void 0,t)})};return s.persist={setOptions:t=>{i={...i,...t},t.storage&&(u=t.storage)},clearStorage:()=>{null==u||u.removeItem(i.name)},getOptions:()=>i,rehydrate:()=>g(),hasHydrated:()=>l,onHydrate:t=>(c.add(t),()=>{c.delete(t)}),onFinishHydration:t=>(d.add(t),()=>{d.delete(t)})},i.skipHydration||g(),p||b};function a(t,e){void 0===e&&(e={});var o=e.insertAt;if(t&&"undefined"!=typeof document){var r=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css","top"===o&&r.firstChild?r.insertBefore(n,r.firstChild):r.appendChild(n),n.styleSheet?n.styleSheet.cssText=t:n.appendChild(document.createTextNode(t))}}function s(t,e,o){let r,n=o.initialDeps??[],a=!0;function s(){var s,i,l;let c;o.key&&(null==(s=o.debug)?void 0:s.call(o))&&(c=Date.now());const d=t();if(d.length===n.length&&!d.some((t,e)=>n[e]!==t))return r;let u;return n=d,o.key&&(null==(i=o.debug)?void 0:i.call(o))&&(u=Date.now()),r=e(...d),o.key&&(null==(l=o.debug)?void 0:l.call(o))&&(Math.round(100*(Date.now()-c)),Math.round(100*(Date.now()-u))),!(null==o?void 0:o.onChange)||a&&o.skipInitialOnChange||o.onChange(r),a=!1,r}return s.updateDeps=t=>{n=t},s}function i(t,e){if(void 0===t)throw new Error("Unexpected undefined"+(e?`: ${e}`:""));return t}const l=(t,e,o)=>{let r;return function(...n){t.clearTimeout(r),r=t.setTimeout(()=>e.apply(this,n),o)}},c=t=>{const{offsetWidth:e,offsetHeight:o}=t;return{width:e,height:o}},d=t=>t,u=t=>{const e=Math.max(t.startIndex-t.overscan,0),o=Math.min(t.endIndex+t.overscan,t.count-1),r=[];for(let t=e;t<=o;t++)r.push(t);return r},h=(t,e)=>{const o=t.scrollElement;if(!o)return;const r=t.targetWindow;if(!r)return;const n=t=>{const{width:o,height:r}=t;e({width:Math.round(o),height:Math.round(r)})};if(n(c(o)),!r.ResizeObserver)return()=>{};const a=new r.ResizeObserver(e=>{const r=()=>{const t=e[0];if(null==t?void 0:t.borderBoxSize){const e=t.borderBoxSize[0];if(e)return void n({width:e.inlineSize,height:e.blockSize})}n(c(o))};t.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(r):r()});return a.observe(o,{box:"border-box"}),()=>{a.unobserve(o)}},f={passive:!0},b="undefined"==typeof window||"onscrollend"in window,p=(t,e)=>{const o=t.scrollElement;if(!o)return;const r=t.targetWindow;if(!r)return;let n=0;const a=t.options.useScrollendEvent&&b?()=>{}:l(r,()=>{e(n,!1)},t.options.isScrollingResetDelay),s=r=>()=>{const{horizontal:s,isRtl:i}=t.options;n=s?o.scrollLeft*(i?-1:1):o.scrollTop,a(),e(n,r)},i=s(!0),c=s(!1);o.addEventListener("scroll",i,f);const d=t.options.useScrollendEvent&&b;return d&&o.addEventListener("scrollend",c,f),()=>{o.removeEventListener("scroll",i),d&&o.removeEventListener("scrollend",c)}},g=(t,e,o)=>{if(null==e?void 0:e.borderBoxSize){const t=e.borderBoxSize[0];if(t)return Math.round(t[o.options.horizontal?"inlineSize":"blockSize"])}return t[o.options.horizontal?"offsetWidth":"offsetHeight"]},x=(t,{adjustments:e=0,behavior:o},r)=>{var n,a;const s=t+e;null==(a=null==(n=r.scrollElement)?void 0:n.scrollTo)||a.call(n,{[r.options.horizontal?"left":"top"]:s,behavior:o})};class _{constructor(t){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.currentScrollToIndex=null,this.measurementsCache=[],this.itemSizeCache=new Map,this.laneAssignments=new Map,this.pendingMeasuredCacheIndexes=[],this.prevLanes=void 0,this.lanesChangedFlag=!1,this.lanesSettling=!1,this.scrollRect=null,this.scrollOffset=null,this.scrollDirection=null,this.scrollAdjustments=0,this.elementsCache=new Map,this.observer=(()=>{let t=null;const e=()=>t||(this.targetWindow&&this.targetWindow.ResizeObserver?t=new this.targetWindow.ResizeObserver(t=>{t.forEach(t=>{const e=()=>{this.t(t.target,t)};this.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(e):e()})}):null);return{disconnect:()=>{var o;null==(o=e())||o.disconnect(),t=null},observe:t=>{var o;return null==(o=e())?void 0:o.observe(t,{box:"border-box"})},unobserve:t=>{var o;return null==(o=e())?void 0:o.unobserve(t)}}})(),this.range=null,this.setOptions=t=>{Object.entries(t).forEach(([e,o])=>{void 0===o&&delete t[e]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:d,rangeExtractor:u,onChange:()=>{},measureElement:g,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:"data-index",initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,enabled:!0,isRtl:!1,useScrollendEvent:!1,useAnimationFrameWithResizeObserver:!1,...t}},this.notify=t=>{var e,o;null==(o=(e=this.options).onChange)||o.call(e,this,t)},this.maybeNotify=s(()=>(this.calculateRange(),[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]),t=>{this.notify(t)},{key:"production"!==process.env.NODE_ENV&&"maybeNotify",debug:()=>this.options.debug,initialDeps:[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]}),this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(t=>t()),this.unsubs=[],this.observer.disconnect(),this.scrollElement=null,this.targetWindow=null},this.o=()=>()=>{this.cleanup()},this.i=()=>{var t;const e=this.options.enabled?this.options.getScrollElement():null;if(this.scrollElement!==e){if(this.cleanup(),!e)return void this.maybeNotify();this.scrollElement=e,this.scrollElement&&"ownerDocument"in this.scrollElement?this.targetWindow=this.scrollElement.ownerDocument.defaultView:this.targetWindow=(null==(t=this.scrollElement)?void 0:t.window)??null,this.elementsCache.forEach(t=>{this.observer.observe(t)}),this.unsubs.push(this.options.observeElementRect(this,t=>{this.scrollRect=t,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(t,e)=>{this.scrollAdjustments=0,this.scrollDirection=e?this.getScrollOffset()<t?"forward":"backward":null,this.scrollOffset=t,this.isScrolling=e,this.maybeNotify()})),this.l(this.getScrollOffset(),{adjustments:void 0,behavior:void 0})}},this.getSize=()=>this.options.enabled?(this.scrollRect=this.scrollRect??this.options.initialRect,this.scrollRect[this.options.horizontal?"width":"height"]):(this.scrollRect=null,0),this.getScrollOffset=()=>this.options.enabled?(this.scrollOffset=this.scrollOffset??("function"==typeof this.options.initialOffset?this.options.initialOffset():this.options.initialOffset),this.scrollOffset):(this.scrollOffset=null,0),this.getFurthestMeasurement=(t,e)=>{const o=new Map,r=new Map;for(let n=e-1;n>=0;n--){const e=t[n];if(o.has(e.lane))continue;const a=r.get(e.lane);if(null==a||e.end>a.end?r.set(e.lane,e):e.end<a.end&&o.set(e.lane,!0),o.size===this.options.lanes)break}return r.size===this.options.lanes?Array.from(r.values()).sort((t,e)=>t.end===e.end?t.index-e.index:t.end-e.end)[0]:void 0},this.getMeasurementOptions=s(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled,this.options.lanes],(t,e,o,r,n,a)=>(void 0!==this.prevLanes&&this.prevLanes!==a&&(this.lanesChangedFlag=!0),this.prevLanes=a,this.pendingMeasuredCacheIndexes=[],{count:t,paddingStart:e,scrollMargin:o,getItemKey:r,enabled:n,lanes:a}),{key:!1,skipInitialOnChange:!0,onChange:()=>{this.notify(this.isScrolling)}}),this.getMeasurements=s(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:t,paddingStart:e,scrollMargin:o,getItemKey:r,enabled:n,lanes:a},s)=>{if(!n)return this.measurementsCache=[],this.itemSizeCache.clear(),this.laneAssignments.clear(),[];if(this.laneAssignments.size>t)for(const e of this.laneAssignments.keys())e>=t&&this.laneAssignments.delete(e);this.lanesChangedFlag&&(this.lanesChangedFlag=!1,this.lanesSettling=!0,this.measurementsCache=[],this.itemSizeCache.clear(),this.laneAssignments.clear(),this.pendingMeasuredCacheIndexes=[]),0!==this.measurementsCache.length||this.lanesSettling||(this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach(t=>{this.itemSizeCache.set(t.key,t.size)}));const i=this.lanesSettling?0:this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[],this.lanesSettling&&this.measurementsCache.length===t&&(this.lanesSettling=!1);const l=this.measurementsCache.slice(0,i),c=new Array(a).fill(void 0);for(let t=0;t<i;t++){const e=l[t];e&&(c[e.lane]=t)}for(let n=i;n<t;n++){const t=r(n),a=this.laneAssignments.get(n);let i,d;if(void 0!==a&&this.options.lanes>1){i=a;const t=c[i],r=void 0!==t?l[t]:void 0;d=r?r.end+this.options.gap:e+o}else{const t=1===this.options.lanes?l[n-1]:this.getFurthestMeasurement(l,n);d=t?t.end+this.options.gap:e+o,i=t?t.lane:n%this.options.lanes,this.options.lanes>1&&this.laneAssignments.set(n,i)}const u=s.get(t),h="number"==typeof u?u:this.options.estimateSize(n),f=d+h;l[n]={index:n,start:d,size:h,end:f,key:t,lane:i},c[i]=n}return this.measurementsCache=l,l},{key:"production"!==process.env.NODE_ENV&&"getMeasurements",debug:()=>this.options.debug}),this.calculateRange=s(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset(),this.options.lanes],(t,e,o,r)=>this.range=t.length>0&&e>0?function({measurements:t,outerSize:e,scrollOffset:o,lanes:r}){const n=t.length-1;if(t.length<=r)return{startIndex:0,endIndex:n};let a=w(0,n,e=>t[e].start,o),s=a;if(1===r)for(;s<n&&t[s].end<o+e;)s++;else if(r>1){const i=Array(r).fill(0);for(;s<n&&i.some(t=>t<o+e);){const e=t[s];i[e.lane]=e.end,s++}const l=Array(r).fill(o+e);for(;a>=0&&l.some(t=>t>=o);){const e=t[a];l[e.lane]=e.start,a--}a=Math.max(0,a-a%r),s=Math.min(n,s+(r-1-s%r))}return{startIndex:a,endIndex:s}}({measurements:t,outerSize:e,scrollOffset:o,lanes:r}):null,{key:"production"!==process.env.NODE_ENV&&"calculateRange",debug:()=>this.options.debug}),this.getVirtualIndexes=s(()=>{let t=null,e=null;const o=this.calculateRange();return o&&(t=o.startIndex,e=o.endIndex),this.maybeNotify.updateDeps([this.isScrolling,t,e]),[this.options.rangeExtractor,this.options.overscan,this.options.count,t,e]},(t,e,o,r,n)=>null===r||null===n?[]:t({startIndex:r,endIndex:n,overscan:e,count:o}),{key:"production"!==process.env.NODE_ENV&&"getVirtualIndexes",debug:()=>this.options.debug}),this.indexFromElement=t=>{const e=this.options.indexAttribute,o=t.getAttribute(e);return o?parseInt(o,10):-1},this.t=(t,e)=>{const o=this.indexFromElement(t),r=this.measurementsCache[o];if(!r)return;const n=r.key,a=this.elementsCache.get(n);a!==t&&(a&&this.observer.unobserve(a),this.observer.observe(t),this.elementsCache.set(n,t)),t.isConnected&&this.resizeItem(o,this.options.measureElement(t,e,this))},this.resizeItem=(t,e)=>{const o=this.measurementsCache[t];if(!o)return;const r=e-(this.itemSizeCache.get(o.key)??o.size);0!==r&&((void 0!==this.shouldAdjustScrollPositionOnItemSizeChange?this.shouldAdjustScrollPositionOnItemSizeChange(o,r,this):o.start<this.getScrollOffset()+this.scrollAdjustments)&&("production"!==process.env.NODE_ENV&&this.options.debug,this.l(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=r,behavior:void 0})),this.pendingMeasuredCacheIndexes.push(o.index),this.itemSizeCache=new Map(this.itemSizeCache.set(o.key,e)),this.notify(!1))},this.measureElement=t=>{t?this.t(t,void 0):this.elementsCache.forEach((t,e)=>{t.isConnected||(this.observer.unobserve(t),this.elementsCache.delete(e))})},this.getVirtualItems=s(()=>[this.getVirtualIndexes(),this.getMeasurements()],(t,e)=>{const o=[];for(let r=0,n=t.length;r<n;r++){const n=e[t[r]];o.push(n)}return o},{key:"production"!==process.env.NODE_ENV&&"getVirtualItems",debug:()=>this.options.debug}),this.getVirtualItemForOffset=t=>{const e=this.getMeasurements();if(0!==e.length)return i(e[w(0,e.length-1,t=>i(e[t]).start,t)])},this.getMaxScrollOffset=()=>{if(!this.scrollElement)return 0;if("scrollHeight"in this.scrollElement)return this.options.horizontal?this.scrollElement.scrollWidth-this.scrollElement.clientWidth:this.scrollElement.scrollHeight-this.scrollElement.clientHeight;{const t=this.scrollElement.document.documentElement;return this.options.horizontal?t.scrollWidth-this.scrollElement.innerWidth:t.scrollHeight-this.scrollElement.innerHeight}},this.getOffsetForAlignment=(t,e,o=0)=>{if(!this.scrollElement)return 0;const r=this.getSize(),n=this.getScrollOffset();"auto"===e&&(e=t>=n+r?"end":"start"),"center"===e?t+=(o-r)/2:"end"===e&&(t-=r);const a=this.getMaxScrollOffset();return Math.max(Math.min(a,t),0)},this.getOffsetForIndex=(t,e="auto")=>{t=Math.max(0,Math.min(t,this.options.count-1));const o=this.measurementsCache[t];if(!o)return;const r=this.getSize(),n=this.getScrollOffset();if("auto"===e)if(o.end>=n+r-this.options.scrollPaddingEnd)e="end";else{if(!(o.start<=n+this.options.scrollPaddingStart))return[n,e];e="start"}if("end"===e&&t===this.options.count-1)return[this.getMaxScrollOffset(),e];const a="end"===e?o.end+this.options.scrollPaddingEnd:o.start-this.options.scrollPaddingStart;return[this.getOffsetForAlignment(a,e,o.size),e]},this.isDynamicMode=()=>this.elementsCache.size>0,this.scrollToOffset=(t,{align:e="start",behavior:o}={})=>{"smooth"===o&&this.isDynamicMode(),this.l(this.getOffsetForAlignment(t,e),{adjustments:void 0,behavior:o})},this.scrollToIndex=(t,{align:e="auto",behavior:o}={})=>{"smooth"===o&&this.isDynamicMode(),t=Math.max(0,Math.min(t,this.options.count-1)),this.currentScrollToIndex=t;let r=0;const n=e=>{if(!this.targetWindow)return;const r=this.getOffsetForIndex(t,e);if(!r)return;const[n,s]=r;this.l(n,{adjustments:void 0,behavior:o}),this.targetWindow.requestAnimationFrame(()=>{const e=()=>{if(this.currentScrollToIndex!==t)return;const e=this.getScrollOffset(),o=this.getOffsetForIndex(t,s);var r,n;o&&(r=o[0],n=e,Math.abs(r-n)<1.01||a(s))};this.isDynamicMode()?this.targetWindow.requestAnimationFrame(e):e()})},a=e=>{this.targetWindow&&this.currentScrollToIndex===t&&(r++,r<10&&("production"!==process.env.NODE_ENV&&this.options.debug,this.targetWindow.requestAnimationFrame(()=>n(e))))};n(e)},this.scrollBy=(t,{behavior:e}={})=>{"smooth"===e&&this.isDynamicMode(),this.l(this.getScrollOffset()+t,{adjustments:void 0,behavior:e})},this.getTotalSize=()=>{var t;const e=this.getMeasurements();let o;if(0===e.length)o=this.options.paddingStart;else if(1===this.options.lanes)o=(null==(t=e[e.length-1])?void 0:t.end)??0;else{const t=Array(this.options.lanes).fill(null);let r=e.length-1;for(;r>=0&&t.some(t=>null===t);){const o=e[r];null===t[o.lane]&&(t[o.lane]=o.end),r--}o=Math.max(...t.filter(t=>null!==t))}return Math.max(o-this.options.scrollMargin+this.options.paddingEnd,0)},this.l=(t,{adjustments:e,behavior:o})=>{this.options.scrollToFn(t,{behavior:o,adjustments:e},this)},this.measure=()=>{this.itemSizeCache=new Map,this.laneAssignments=new Map,this.notify(!1)},this.setOptions(t)}}const w=(t,e,o,r)=>{for(;t<=e;){const n=(t+e)/2|0,a=o(n);if(a<r)t=n+1;else{if(!(a>r))return n;e=n-1}}return t>0?t-1:0},y="undefined"!=typeof document?t.useLayoutEffect:t.useEffect;function v(o){return function({useFlushSync:o=!0,...r}){const n=t.useReducer(()=>({}),{})[1],a={...r,onChange:(t,a)=>{var s;o&&a?e(n):n(),null==(s=r.onChange)||s.call(r,t,a)}},[s]=t.useState(()=>new _(a));return s.setOptions(a),y(()=>s.o(),[]),y(()=>s.i()),s}({observeElementRect:h,observeElementOffset:p,scrollToFn:x,...o})}var m={locale:"en",long:{year:{previous:"last year",current:"this year",next:"next year",past:{one:"{0} year ago",other:"{0} years ago"},future:{one:"in {0} year",other:"in {0} years"}},quarter:{previous:"last quarter",current:"this quarter",next:"next quarter",past:{one:"{0} quarter ago",other:"{0} quarters ago"},future:{one:"in {0} quarter",other:"in {0} quarters"}},month:{previous:"last month",current:"this month",next:"next month",past:{one:"{0} month ago",other:"{0} months ago"},future:{one:"in {0} month",other:"in {0} months"}},week:{previous:"last week",current:"this week",next:"next week",past:{one:"{0} week ago",other:"{0} weeks ago"},future:{one:"in {0} week",other:"in {0} weeks"}},day:{previous:"yesterday",current:"today",next:"tomorrow",past:{one:"{0} day ago",other:"{0} days ago"},future:{one:"in {0} day",other:"in {0} days"}},hour:{current:"this hour",past:{one:"{0} hour ago",other:"{0} hours ago"},future:{one:"in {0} hour",other:"in {0} hours"}},minute:{current:"this minute",past:{one:"{0} minute ago",other:"{0} minutes ago"},future:{one:"in {0} minute",other:"in {0} minutes"}},second:{current:"now",past:{one:"{0} second ago",other:"{0} seconds ago"},future:{one:"in {0} second",other:"in {0} seconds"}}},short:{year:{previous:"last yr.",current:"this yr.",next:"next yr.",past:"{0} yr. ago",future:"in {0} yr."},quarter:{previous:"last qtr.",current:"this qtr.",next:"next qtr.",past:{one:"{0} qtr. ago",other:"{0} qtrs. ago"},future:{one:"in {0} qtr.",other:"in {0} qtrs."}},month:{previous:"last mo.",current:"this mo.",next:"next mo.",past:"{0} mo. ago",future:"in {0} mo."},week:{previous:"last wk.",current:"this wk.",next:"next wk.",past:"{0} wk. ago",future:"in {0} wk."},day:{previous:"yesterday",current:"today",next:"tomorrow",past:{one:"{0} day ago",other:"{0} days ago"},future:{one:"in {0} day",other:"in {0} days"}},hour:{current:"this hour",past:"{0} hr. ago",future:"in {0} hr."},minute:{current:"this minute",past:"{0} min. ago",future:"in {0} min."},second:{current:"now",past:"{0} sec. ago",future:"in {0} sec."}},narrow:{year:{previous:"last yr.",current:"this yr.",next:"next yr.",past:"{0}y ago",future:"in {0}y"},quarter:{previous:"last qtr.",current:"this qtr.",next:"next qtr.",past:"{0}q ago",future:"in {0}q"},month:{previous:"last mo.",current:"this mo.",next:"next mo.",past:"{0}mo ago",future:"in {0}mo"},week:{previous:"last wk.",current:"this wk.",next:"next wk.",past:"{0}w ago",future:"in {0}w"},day:{previous:"yesterday",current:"today",next:"tomorrow",past:"{0}d ago",future:"in {0}d"},hour:{current:"this hour",past:"{0}h ago",future:"in {0}h"},minute:{current:"this minute",past:"{0}m ago",future:"in {0}m"},second:{current:"now",past:"{0}s ago",future:"in {0}s"}},now:{now:{current:"now",future:"in a moment",past:"just now"}},mini:{year:"{0}yr",month:"{0}mo",week:"{0}wk",day:"{0}d",hour:"{0}h",minute:"{0}m",second:"{0}s",now:"now"},"short-time":{year:"{0} yr.",month:"{0} mo.",week:"{0} wk.",day:{one:"{0} day",other:"{0} days"},hour:"{0} hr.",minute:"{0} min.",second:"{0} sec."},"long-time":{year:{one:"{0} year",other:"{0} years"},month:{one:"{0} month",other:"{0} months"},week:{one:"{0} week",other:"{0} weeks"},day:{one:"{0} day",other:"{0} days"},hour:{one:"{0} hour",other:"{0} hours"},minute:{one:"{0} minute",other:"{0} minutes"},second:{one:"{0} second",other:"{0} seconds"}}};a(".react-flow{--xy-edge-stroke-default:#b1b1b7;--xy-edge-stroke-width-default:1;--xy-edge-stroke-selected-default:#555;--xy-connectionline-stroke-default:#b1b1b7;--xy-connectionline-stroke-width-default:1;--xy-attribution-background-color-default:hsla(0,0%,100%,.5);--xy-minimap-background-color-default:#fff;--xy-minimap-mask-background-color-default:hsla(0,0%,94%,.6);--xy-minimap-mask-stroke-color-default:transparent;--xy-minimap-mask-stroke-width-default:1;--xy-minimap-node-background-color-default:#e2e2e2;--xy-minimap-node-stroke-color-default:transparent;--xy-minimap-node-stroke-width-default:2;--xy-background-color-default:transparent;--xy-background-pattern-dots-color-default:#91919a;--xy-background-pattern-lines-color-default:#eee;--xy-background-pattern-cross-color-default:#e2e2e2;--xy-node-color-default:inherit;--xy-node-border-default:1px solid #1a192b;--xy-node-background-color-default:#fff;--xy-node-group-background-color-default:hsla(0,0%,94%,.25);--xy-node-boxshadow-hover-default:0 1px 4px 1px rgba(0,0,0,.08);--xy-node-boxshadow-selected-default:0 0 0 0.5px #1a192b;--xy-node-border-radius-default:3px;--xy-handle-background-color-default:#1a192b;--xy-handle-border-color-default:#fff;--xy-selection-background-color-default:rgba(0,89,220,.08);--xy-selection-border-default:1px dotted rgba(0,89,220,.8);--xy-controls-button-background-color-default:#fefefe;--xy-controls-button-background-color-hover-default:#f4f4f4;--xy-controls-button-color-default:inherit;--xy-controls-button-color-hover-default:inherit;--xy-controls-button-border-color-default:#eee;--xy-controls-box-shadow-default:0 0 2px 1px rgba(0,0,0,.08);--xy-edge-label-background-color-default:#fff;--xy-edge-label-color-default:inherit;--xy-resize-background-color-default:#3367d9;background-color:var(--xy-background-color,var(--xy-background-color-default));direction:ltr}.react-flow.dark{--xy-edge-stroke-default:#3e3e3e;--xy-edge-stroke-width-default:1;--xy-edge-stroke-selected-default:#727272;--xy-connectionline-stroke-default:#b1b1b7;--xy-connectionline-stroke-width-default:1;--xy-attribution-background-color-default:hsla(0,0%,59%,.25);--xy-minimap-background-color-default:#141414;--xy-minimap-mask-background-color-default:rgba(60,60,60,.6);--xy-minimap-mask-stroke-color-default:transparent;--xy-minimap-mask-stroke-width-default:1;--xy-minimap-node-background-color-default:#2b2b2b;--xy-minimap-node-stroke-color-default:transparent;--xy-minimap-node-stroke-width-default:2;--xy-background-color-default:#141414;--xy-background-pattern-dots-color-default:#777;--xy-background-pattern-lines-color-default:#777;--xy-background-pattern-cross-color-default:#777;--xy-node-color-default:#f8f8f8;--xy-node-border-default:1px solid #3c3c3c;--xy-node-background-color-default:#1e1e1e;--xy-node-group-background-color-default:hsla(0,0%,94%,.25);--xy-node-boxshadow-hover-default:0 1px 4px 1px hsla(0,0%,100%,.08);--xy-node-boxshadow-selected-default:0 0 0 0.5px #999;--xy-handle-background-color-default:#bebebe;--xy-handle-border-color-default:#1e1e1e;--xy-selection-background-color-default:rgba(200,200,220,.08);--xy-selection-border-default:1px dotted rgba(200,200,220,.8);--xy-controls-button-background-color-default:#2b2b2b;--xy-controls-button-background-color-hover-default:#3e3e3e;--xy-controls-button-color-default:#f8f8f8;--xy-controls-button-color-hover-default:#fff;--xy-controls-button-border-color-default:#5b5b5b;--xy-controls-box-shadow-default:0 0 2px 1px rgba(0,0,0,.08);--xy-edge-label-background-color-default:#141414;--xy-edge-label-color-default:#f8f8f8}.react-flow__background{background-color:var(--xy-background-color-props,var(--xy-background-color,var(--xy-background-color-default)));pointer-events:none;z-index:-1}.react-flow__container{height:100%;left:0;position:absolute;top:0;width:100%}.react-flow__pane{z-index:1}.react-flow__pane.draggable{cursor:grab}.react-flow__pane.dragging{cursor:grabbing}.react-flow__pane.selection{cursor:pointer}.react-flow__viewport{pointer-events:none;transform-origin:0 0;z-index:2}.react-flow__renderer{z-index:4}.react-flow__selection{z-index:6}.react-flow__nodesselection-rect:focus,.react-flow__nodesselection-rect:focus-visible{outline:none}.react-flow__edge-path{stroke:var(--xy-edge-stroke,var(--xy-edge-stroke-default));stroke-width:var(--xy-edge-stroke-width,var(--xy-edge-stroke-width-default));fill:none}.react-flow__connection-path{stroke:var(--xy-connectionline-stroke,var(--xy-connectionline-stroke-default));stroke-width:var(--xy-connectionline-stroke-width,var(--xy-connectionline-stroke-width-default));fill:none}.react-flow .react-flow__edges{position:absolute}.react-flow .react-flow__edges svg{overflow:visible;pointer-events:none;position:absolute}.react-flow__edge{pointer-events:visibleStroke}.react-flow__edge.selectable{cursor:pointer}.react-flow__edge.animated path{stroke-dasharray:5;animation:dashdraw .5s linear infinite}.react-flow__edge.animated path.react-flow__edge-interaction{stroke-dasharray:none;animation:none}.react-flow__edge.inactive{pointer-events:none}.react-flow__edge.selected,.react-flow__edge:focus,.react-flow__edge:focus-visible{outline:none}.react-flow__edge.selectable:focus .react-flow__edge-path,.react-flow__edge.selectable:focus-visible .react-flow__edge-path,.react-flow__edge.selected .react-flow__edge-path{stroke:var(--xy-edge-stroke-selected,var(--xy-edge-stroke-selected-default))}.react-flow__edge-textwrapper{pointer-events:all}.react-flow__edge .react-flow__edge-text{pointer-events:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}.react-flow__arrowhead polyline{stroke:var(--xy-edge-stroke,var(--xy-edge-stroke-default))}.react-flow__arrowhead polyline.arrowclosed{fill:var(--xy-edge-stroke,var(--xy-edge-stroke-default))}.react-flow__connection{pointer-events:none}.react-flow__connection .animated{stroke-dasharray:5;animation:dashdraw .5s linear infinite}svg.react-flow__connectionline{overflow:visible;position:absolute;z-index:1001}.react-flow__nodes{pointer-events:none;transform-origin:0 0}.react-flow__node{box-sizing:border-box;cursor:default;pointer-events:all;position:absolute;transform-origin:0 0;-webkit-user-select:none;-moz-user-select:none;user-select:none}.react-flow__node.selectable{cursor:pointer}.react-flow__node.draggable{cursor:grab;pointer-events:all}.react-flow__node.draggable.dragging{cursor:grabbing}.react-flow__nodesselection{pointer-events:none;transform-origin:left top;z-index:3}.react-flow__nodesselection-rect{cursor:grab;pointer-events:all;position:absolute}.react-flow__handle{background-color:var(--xy-handle-background-color,var(--xy-handle-background-color-default));border:1px solid var(--xy-handle-border-color,var(--xy-handle-border-color-default));border-radius:100%;height:6px;min-height:5px;min-width:5px;pointer-events:none;position:absolute;width:6px}.react-flow__handle.connectingfrom{pointer-events:all}.react-flow__handle.connectionindicator{cursor:crosshair;pointer-events:all}.react-flow__handle-bottom{bottom:0;left:50%;top:auto;transform:translate(-50%,50%)}.react-flow__handle-top{left:50%;top:0;transform:translate(-50%,-50%)}.react-flow__handle-left{left:0;top:50%;transform:translate(-50%,-50%)}.react-flow__handle-right{right:0;top:50%;transform:translate(50%,-50%)}.react-flow__edgeupdater{cursor:move;pointer-events:all}.react-flow__pane.selection .react-flow__panel{pointer-events:none}.react-flow__panel{margin:15px;position:absolute;z-index:5}.react-flow__panel.top{top:0}.react-flow__panel.bottom{bottom:0}.react-flow__panel.bottom.center,.react-flow__panel.top.center{left:50%;transform:translateX(-15px) translateX(-50%)}.react-flow__panel.left{left:0}.react-flow__panel.right{right:0}.react-flow__panel.left.center,.react-flow__panel.right.center{top:50%;transform:translateY(-15px) translateY(-50%)}.react-flow__attribution{background:var(--xy-attribution-background-color,var(--xy-attribution-background-color-default));font-size:10px;margin:0;padding:2px 3px}.react-flow__attribution a{color:#999;text-decoration:none}@keyframes dashdraw{0%{stroke-dashoffset:10}}.react-flow__edgelabel-renderer{pointer-events:none}.react-flow__edgelabel-renderer,.react-flow__viewport-portal{height:100%;left:0;position:absolute;top:0;-webkit-user-select:none;-moz-user-select:none;user-select:none;width:100%}.react-flow__minimap{background:var(\n --xy-minimap-background-color-props,var(--xy-minimap-background-color,var(--xy-minimap-background-color-default))\n )}.react-flow__minimap-svg{display:block}.react-flow__minimap-mask{fill:var(\n --xy-minimap-mask-background-color-props,var(--xy-minimap-mask-background-color,var(--xy-minimap-mask-background-color-default))\n );stroke:var(\n --xy-minimap-mask-stroke-color-props,var(--xy-minimap-mask-stroke-color,var(--xy-minimap-mask-stroke-color-default))\n );stroke-width:var(\n --xy-minimap-mask-stroke-width-props,var(--xy-minimap-mask-stroke-width,var(--xy-minimap-mask-stroke-width-default))\n )}.react-flow__minimap-node{fill:var(\n --xy-minimap-node-background-color-props,var(--xy-minimap-node-background-color,var(--xy-minimap-node-background-color-default))\n );stroke:var(\n --xy-minimap-node-stroke-color-props,var(--xy-minimap-node-stroke-color,var(--xy-minimap-node-stroke-color-default))\n );stroke-width:var(\n --xy-minimap-node-stroke-width-props,var(--xy-minimap-node-stroke-width,var(--xy-minimap-node-stroke-width-default))\n )}.react-flow__background-pattern.dots{fill:var(\n --xy-background-pattern-color-props,var(--xy-background-pattern-color,var(--xy-background-pattern-dots-color-default))\n )}.react-flow__background-pattern.lines{stroke:var(\n --xy-background-pattern-color-props,var(--xy-background-pattern-color,var(--xy-background-pattern-lines-color-default))\n )}.react-flow__background-pattern.cross{stroke:var(\n --xy-background-pattern-color-props,var(--xy-background-pattern-color,var(--xy-background-pattern-cross-color-default))\n )}.react-flow__controls{box-shadow:var(--xy-controls-box-shadow,var(--xy-controls-box-shadow-default));display:flex;flex-direction:column}.react-flow__controls.horizontal{flex-direction:row}.react-flow__controls-button{align-items:center;background:var(--xy-controls-button-background-color,var(--xy-controls-button-background-color-default));border:none;border-bottom:1px solid var(\n --xy-controls-button-border-color-props,var(--xy-controls-button-border-color,var(--xy-controls-button-border-color-default))\n );color:var(\n --xy-controls-button-color-props,var(--xy-controls-button-color,var(--xy-controls-button-color-default))\n );cursor:pointer;display:flex;height:26px;justify-content:center;padding:4px;-webkit-user-select:none;-moz-user-select:none;user-select:none;width:26px}.react-flow__controls-button svg{fill:currentColor;max-height:12px;max-width:12px;width:100%}.react-flow__edge.updating .react-flow__edge-path{stroke:#777}.react-flow__edge-text{font-size:10px}.react-flow__node.selectable:focus,.react-flow__node.selectable:focus-visible{outline:none}.react-flow__node-default,.react-flow__node-group,.react-flow__node-input,.react-flow__node-output{background-color:var(--xy-node-background-color,var(--xy-node-background-color-default));border:var(--xy-node-border,var(--xy-node-border-default));border-radius:var(--xy-node-border-radius,var(--xy-node-border-radius-default));color:var(--xy-node-color,var(--xy-node-color-default));font-size:12px;padding:10px;text-align:center;width:150px}.react-flow__node-default.selectable:hover,.react-flow__node-group.selectable:hover,.react-flow__node-input.selectable:hover,.react-flow__node-output.selectable:hover{box-shadow:var(--xy-node-boxshadow-hover,var(--xy-node-boxshadow-hover-default))}.react-flow__node-default.selectable.selected,.react-flow__node-default.selectable:focus,.react-flow__node-default.selectable:focus-visible,.react-flow__node-group.selectable.selected,.react-flow__node-group.selectable:focus,.react-flow__node-group.selectable:focus-visible,.react-flow__node-input.selectable.selected,.react-flow__node-input.selectable:focus,.react-flow__node-input.selectable:focus-visible,.react-flow__node-output.selectable.selected,.react-flow__node-output.selectable:focus,.react-flow__node-output.selectable:focus-visible{box-shadow:var(--xy-node-boxshadow-selected,var(--xy-node-boxshadow-selected-default))}.react-flow__node-group{background-color:var(--xy-node-group-background-color,var(--xy-node-group-background-color-default))}.react-flow__nodesselection-rect,.react-flow__selection{background:var(--xy-selection-background-color,var(--xy-selection-background-color-default));border:var(--xy-selection-border,var(--xy-selection-border-default))}.react-flow__nodesselection-rect:focus,.react-flow__nodesselection-rect:focus-visible,.react-flow__selection:focus,.react-flow__selection:focus-visible{outline:none}.react-flow__controls-button:hover{background:var(\n --xy-controls-button-background-color-hover-props,var(--xy-controls-button-background-color-hover,var(--xy-controls-button-background-color-hover-default))\n );color:var(\n --xy-controls-button-color-hover-props,var(--xy-controls-button-color-hover,var(--xy-controls-button-color-hover-default))\n )}.react-flow__controls-button:disabled{pointer-events:none}.react-flow__controls-button:disabled svg{fill-opacity:.4}.react-flow__controls-button:last-child{border-bottom:none}.react-flow__controls.horizontal .react-flow__controls-button{border-bottom:none;border-right:1px solid var(\n --xy-controls-button-border-color-props,var(--xy-controls-button-border-color,var(--xy-controls-button-border-color-default))\n )}.react-flow__controls.horizontal .react-flow__controls-button:last-child{border-right:none}.react-flow__resize-control{position:absolute}.react-flow__resize-control.left,.react-flow__resize-control.right{cursor:ew-resize}.react-flow__resize-control.bottom,.react-flow__resize-control.top{cursor:ns-resize}.react-flow__resize-control.bottom.right,.react-flow__resize-control.top.left{cursor:nwse-resize}.react-flow__resize-control.bottom.left,.react-flow__resize-control.top.right{cursor:nesw-resize}.react-flow__resize-control.handle{background-color:var(--xy-resize-background-color,var(--xy-resize-background-color-default));border:1px solid #fff;border-radius:1px;height:5px;translate:-50% -50%;width:5px}.react-flow__resize-control.handle.left{left:0;top:50%}.react-flow__resize-control.handle.right{left:100%;top:50%}.react-flow__resize-control.handle.top{left:50%;top:0}.react-flow__resize-control.handle.bottom{left:50%;top:100%}.react-flow__resize-control.handle.bottom.left,.react-flow__resize-control.handle.top.left{left:0}.react-flow__resize-control.handle.bottom.right,.react-flow__resize-control.handle.top.right{left:100%}.react-flow__resize-control.line{border-color:var(--xy-resize-background-color,var(--xy-resize-background-color-default));border-style:solid;border-width:0}.react-flow__resize-control.line.left,.react-flow__resize-control.line.right{height:100%;top:0;transform:translate(-50%);width:1px}.react-flow__resize-control.line.left{border-left-width:1px;left:0}.react-flow__resize-control.line.right{border-right-width:1px;left:100%}.react-flow__resize-control.line.bottom,.react-flow__resize-control.line.top{height:1px;left:0;transform:translateY(-50%);width:100%}.react-flow__resize-control.line.top{border-top-width:1px;top:0}.react-flow__resize-control.line.bottom{border-bottom-width:1px;top:100%}.react-flow__edge-textbg{fill:var(--xy-edge-label-background-color,var(--xy-edge-label-background-color-default))}.react-flow__edge-text{fill:var(--xy-edge-label-color,var(--xy-edge-label-color-default))}");export{o as c,m as e,n as p,a as s,v as u};
@@ -1,6 +1,7 @@
1
1
  import { type ReactNode, type FC } from 'react';
2
2
  import { type SearchProps } from '../../search';
3
- import { ActionsProps, RichTitleProps } from '@/snippets/_v2';
3
+ import { type ActionsProps } from '@/snippets/_v2/actions';
4
+ import { type RichTitleProps } from '@/snippets/_v2/rich-title';
4
5
  export declare enum SectionCardSize {
5
6
  S = "small",
6
7
  M = "medium"
@@ -1 +1 @@
1
- export{B as Badge,j as Button,r as ButtonSize,dp as ButtonTab,dq as ButtonTabList,k as ButtonVariants,C as Checkbox,dt as CheckboxList,ds as CheckboxSize,J as CliCommand,G as DataCard,g as Drawer,dv as DropData,w as DropDataAlignX,du as DropDataAlignY,dw as Header,c6 as HoverActions,H as IconButton,ci as IconButtonSize,dx as Input,I as Island,L as Loader,dy as Modal,dz as Navbar,i as Note,dB as Radio,dC as RadioGroup,dA as RadioSize,h as Search,p as SectionCard,dr as SectionCardSize,K as Segment,dD as SegmentSize,Q as StatusCard,s as Table,t as TableVariant,dE as Tag,U as TextCard,d as Toggle,dG as ToggleLabelAlign,dH as ToggleList,e as ToggleSize,dF as ToggleVariant,T as Typography,b as TypographySize,dI as TypographyVariants,dJ as WarningModal}from"../chunks/ui-components-76a424df.js";import"../icons.js";import"react";import"styled-components";import"zustand";import"javascript-time-ago";import"../chunks/vendor-55cc654c.js";import"react-dom";import"@xyflow/react";import"react-error-boundary";import"lottie-react";import"prism-react-renderer";
1
+ export{B as Badge,j as Button,r as ButtonSize,dn as ButtonTab,dp as ButtonTabList,k as ButtonVariants,C as Checkbox,ds as CheckboxList,dr as CheckboxSize,J as CliCommand,G as DataCard,g as Drawer,du as DropData,w as DropDataAlignX,dt as DropDataAlignY,dv as Header,c5 as HoverActions,H as IconButton,ch as IconButtonSize,dw as Input,I as Island,L as Loader,dx as Modal,dy as Navbar,i as Note,dA as Radio,dB as RadioGroup,dz as RadioSize,h as Search,p as SectionCard,dq as SectionCardSize,K as Segment,dC as SegmentSize,Q as StatusCard,s as Table,t as TableVariant,dD as Tag,U as TextCard,d as Toggle,dF as ToggleLabelAlign,dG as ToggleList,e as ToggleSize,dE as ToggleVariant,T as Typography,b as TypographySize,dH as TypographyVariants,dI as WarningModal}from"../chunks/ui-components-548ceb33.js";import"../icons.js";import"react";import"styled-components";import"zustand";import"javascript-time-ago";import"../chunks/vendor-0965fadc.js";import"react-dom";import"@xyflow/react";import"react-error-boundary";import"lottie-react";import"prism-react-renderer";
package/lib/components.js CHANGED
@@ -1 +1 @@
1
- export{aG as AutocompleteInput,aZ as Badge,b0 as Button,ar as CancelWarning,z as CenterThis,a3 as Checkbox,d6 as Code,ax as ConditionDetails,ay as DataCard,$ as DataCardFieldTypes,bK as DataCardFields,d7 as DataFinger,b3 as DataTab,aq as DeleteWarning,c4 as DescribeRow,aH as Divider,ah as DocsButton,ap as Drawer,d9 as DrawerFooter,d8 as DrawerHeader,bp as Dropdown,da as ErrorBoundary,bx as ExtendArrow,n as FadeLoader,a4 as FieldError,a2 as FieldLabel,F as FlexColumn,a as FlexRow,db as Header,bw as IconButton,ce as IconGroup,aU as IconTitleBadge,aP as IconWrapped,c0 as IconsNav,dc as ImageControlled,a6 as Input,ac as InputList,a9 as InputTable,aX as InteractiveTable,ab as KeyValueInputsList,a$ as LoadingText,aB as Modal,aD as ModalBody,ai as MonitorsCheckboxes,aR as MonitorsIcons,aC as NavigationButtons,N as NoDataFound,aE as NotificationNote,di as Overlay,P as PageContent,bk as Popup,cj as PopupForm,co as ScrollX,b6 as ScrollY,ag as SectionTitle,af as Segment,bl as SelectionButton,bb as SkeletonLoader,aJ as Status,bJ as Stepper,dd as TabList,aS as TableContainer,aT as TableTitleWrap,aW as TableWrap,bT as Tag,ae as Text,aj as TextArea,aa as Toggle,cm as ToggleCodeComponent,c as Tooltip,aY as TraceLoader,X as UpgradeRequiredWrapper,bm as VerticalScroll,dh as WarningModal,de as getLinksFromText,df as getStrongsFromText,dg as renderText}from"./chunks/ui-components-76a424df.js";import"./icons.js";import"react";import"styled-components";import"zustand";import"javascript-time-ago";import"./chunks/vendor-55cc654c.js";import"react-dom";import"@xyflow/react";import"react-error-boundary";import"lottie-react";import"prism-react-renderer";
1
+ export{aE as AutocompleteInput,aX as Badge,aZ as Button,ap as CancelWarning,z as CenterThis,a3 as Checkbox,d5 as Code,av as ConditionDetails,aw as DataCard,$ as DataCardFieldTypes,bH as DataCardFields,d6 as DataFinger,a$ as DataTab,ao as DeleteWarning,c3 as DescribeRow,aF as Divider,ah as DocsButton,an as Drawer,d8 as DrawerFooter,d7 as DrawerHeader,bm as Dropdown,d9 as ErrorBoundary,bu as ExtendArrow,n as FadeLoader,a4 as FieldError,a2 as FieldLabel,F as FlexColumn,a as FlexRow,da as Header,bt as IconButton,cd as IconGroup,aS as IconTitleBadge,aN as IconWrapped,b$ as IconsNav,db as ImageControlled,a6 as Input,ac as InputList,a9 as InputTable,aV as InteractiveTable,ab as KeyValueInputsList,bZ as LoadingText,az as Modal,aB as ModalBody,ai as MonitorsCheckboxes,aP as MonitorsIcons,aA as NavigationButtons,N as NoDataFound,aC as NotificationNote,dh as Overlay,P as PageContent,bh as Popup,ci as PopupForm,cn as ScrollX,b2 as ScrollY,ag as SectionTitle,af as Segment,bi as SelectionButton,b8 as SkeletonLoader,aH as Status,bG as Stepper,dc as TabList,aQ as TableContainer,aR as TableTitleWrap,aU as TableWrap,bQ as Tag,ae as Text,aj as TextArea,aa as Toggle,cl as ToggleCodeComponent,c as Tooltip,aW as TraceLoader,X as UpgradeRequiredWrapper,bj as VerticalScroll,dg as WarningModal,dd as getLinksFromText,de as getStrongsFromText,df as renderText}from"./chunks/ui-components-548ceb33.js";import"./icons.js";import"react";import"styled-components";import"zustand";import"javascript-time-ago";import"./chunks/vendor-0965fadc.js";import"react-dom";import"@xyflow/react";import"react-error-boundary";import"lottie-react";import"prism-react-renderer";
package/lib/constants.js CHANGED
@@ -1 +1 @@
1
- export{av as ACTION_OPTIONS,ao as BUTTON_TEXTS,D as DEFAULT_DATA_STREAM_NAME,bI as DESTINATION_CATEGORIES,bq as DISPLAY_LANGUAGES,_ as DISPLAY_TITLES,aF as FORM_ALERTS,bW as INSTRUMENTATION_RULE_OPTIONS,c_ as LANGUAGE_OPTIONS,br as MONITORS_OPTIONS,bs as STORAGE_KEYS,c$ as TOKEN_ABOUT_TO_EXPIRE}from"./chunks/ui-components-76a424df.js";import"./icons.js";import"react";import"styled-components";import"zustand";import"javascript-time-ago";import"./chunks/vendor-55cc654c.js";import"react-dom";import"@xyflow/react";import"react-error-boundary";import"lottie-react";import"prism-react-renderer";
1
+ export{at as ACTION_OPTIONS,am as BUTTON_TEXTS,D as DEFAULT_DATA_STREAM_NAME,bF as DESTINATION_CATEGORIES,bn as DISPLAY_LANGUAGES,_ as DISPLAY_TITLES,aD as FORM_ALERTS,bU as INSTRUMENTATION_RULE_OPTIONS,cZ as LANGUAGE_OPTIONS,bo as MONITORS_OPTIONS,bp as STORAGE_KEYS,c_ as TOKEN_ABOUT_TO_EXPIRE}from"./chunks/ui-components-548ceb33.js";import"./icons.js";import"react";import"styled-components";import"zustand";import"javascript-time-ago";import"./chunks/vendor-0965fadc.js";import"react-dom";import"@xyflow/react";import"react-error-boundary";import"lottie-react";import"prism-react-renderer";
@@ -7,7 +7,7 @@ export interface ConnectionConfigurationsFormData {
7
7
  export type GetConnectionRemoteConfig = (id: string) => Promise<ConnectionRemoteConfig | undefined>;
8
8
  export type ApplyConnectionsConfigurationsFunc = (connectionIds: string[], formData: ConnectionConfigurationsFormData) => Promise<{
9
9
  error?: string;
10
- }>;
10
+ } | undefined>;
11
11
  export interface ConfigDrawerProps {
12
12
  onClose: DrawerProps['header']['onClose'];
13
13
  connections: Connection[];
@@ -6,6 +6,10 @@ interface HeadProps {
6
6
  badgeTooltip?: string;
7
7
  isLoading?: boolean;
8
8
  refetch: () => void;
9
+ partiallySelected?: boolean;
10
+ allSelected?: boolean;
11
+ onSelectAll?: (bool: boolean) => void;
12
+ progressPercent?: number;
9
13
  }
10
14
  declare const Head: FC<HeadProps>;
11
15
  export { Head, type HeadProps };
@@ -1,4 +1,4 @@
1
- import e,{useMemo as t,useState as a,useEffect as l,useCallback as n}from"react";import o,{useTheme as s}from"styled-components";import{F as i,a as r,C as c,T as d,b as u,B as p,S as g,c as m,O as h,N as b,d as f,e as y,u as w,D as C,E as k,f as v,g as x,R as $,h as S,L as I,i as A,j as P,k as R,l as D,m as T,n as N,o as z,P as L,p as V,q as M,A as O,r as W,s as j,t as F,v as U,I as E,w as H,x as G,y as q,z as Y,G as B,H as K,J as X,Y as J,K as Q,M as Z,Q as _,U as ee,W as te,V as ae,X as le,Z as ne}from"../chunks/ui-components-76a424df.js";import{SourceIcon as oe,VSquareIcon as se,OdigosLogo as ie,SettingsIcon as re,ConnectionsIcon as ce,RefreshIcon as de,DeleteIcon as ue,VIcon as pe,XIcon as ge,XSquareIcon as me,PodIcon as he,ChevronUpIcon as be,ChevronDownIcon as fe,TerminalIcon as ye,DownloadIcon as we,PipelineCollectorIcon as Ce,GatewayIcon as ke,YamlIcon as ve}from"../icons.js";import"zustand";import"javascript-time-ago";import"../chunks/vendor-55cc654c.js";import"react-dom";import"@xyflow/react";import"react-error-boundary";import"lottie-react";import"prism-react-renderer";const xe=o(i)`
1
+ import e,{useMemo as t,useState as a,useEffect as l,useCallback as n}from"react";import o,{useTheme as s}from"styled-components";import{F as i,a as r,C as c,T as d,b as u,B as p,S as g,c as m,O as h,N as b,d as f,e as y,u as w,D as C,E as k,f as v,g as x,R as $,h as S,L as I,i as A,j as P,k as R,l as D,m as T,n as N,o as z,P as L,p as V,q as M,A as O,r as W,s as j,t as F,v as U,I as E,w as H,x as G,y as q,z as Y,G as B,H as K,J as X,Y as J,K as Q,M as Z,Q as _,U as ee,W as te,V as ae,X as le,Z as ne}from"../chunks/ui-components-548ceb33.js";import{SourceIcon as oe,VSquareIcon as se,OdigosLogo as ie,SettingsIcon as re,ConnectionsIcon as ce,RefreshIcon as de,DeleteIcon as ue,VIcon as pe,XIcon as ge,XSquareIcon as me,PodIcon as he,ChevronUpIcon as be,ChevronDownIcon as fe,TerminalIcon as ye,DownloadIcon as we,PipelineCollectorIcon as Ce,GatewayIcon as ke,YamlIcon as ve}from"../icons.js";import"zustand";import"javascript-time-ago";import"../chunks/vendor-0965fadc.js";import"react-dom";import"@xyflow/react";import"react-error-boundary";import"lottie-react";import"prism-react-renderer";const xe=o(i)`
2
2
  width: ${({$width:e})=>e};
3
3
  gap: 12px;
4
4
  justify-content: space-between;
@@ -25,7 +25,7 @@ import e,{useMemo as t,useState as a,useEffect as l,useCallback as n}from"react"
25
25
  &:hover {
26
26
  background-color: ${({theme:e})=>e.v2.colors.silver[600]};
27
27
  }
28
- `,Ie=({formData:a,handleSourceChange:l,handleSelectAll:n,selectedArea:o,searchText:i,filters:f})=>{const y=s(),{activeNamespace:w,isAll:C,isSome:k}=t(()=>{const e=o.value.clusterId&&o.value.namespaceName?a.find(({clusterId:e})=>e===o.value.clusterId)?.namespaces.find(({name:e})=>e===o.value.namespaceName):void 0;if(!e)return{activeNamespace:void 0,isAll:!1,isSome:!1};const t=e.workloads.filter(({selected:e})=>e).length;return{activeNamespace:e,isAll:t>0&&t===e.workloads.length,isSome:t>0&&t<e.workloads.length}},[a,o.value.clusterId,o.value.namespaceName]),v=t(()=>{if(!w)return[];const{clusterId:t}=o.value,{name:a,workloads:n}=w;return n.map(({name:n,selected:o,kind:s})=>{if(i&&!n.toLowerCase().includes(i.toLowerCase()))return null;const m=o||!1;if(f.showOnlySelected&&!m)return null;const h=()=>l({clusterId:t,workloadId:{namespace:a,name:n,kind:s}});return e.createElement(Se,{key:`${t}#${a}#${n}#${s}`,onClick:h},e.createElement(r,{$gap:12},e.createElement(c,{value:m,onChange:h}),e.createElement(d,{size:u.XS},n)),e.createElement(p,{label:s,status:g.Info,textSize:u.XXXS,backgroundColor:y.v2.colors.blue[900]}))})},[a,o.value.clusterId,w,i,f]);return e.createElement(xe,{$width:"40%"},e.createElement(r,{$padding:"0 12px 0 28px",$gap:12},e.createElement(m,{text:(C?"Unselect":"Select")+" all workloads in the selected namespace"},e.createElement(c,{partiallyChecked:k,value:C,onChange:()=>n({clusterId:o.value.clusterId,namespaceName:o.value.namespaceName,boolean:!C}),disabled:!v.length})),e.createElement(r,{$gap:8},e.createElement(d,{size:u.XS,nowrap:!0},o.value.clusterId?`${o.value.clusterName} > ${o.value.namespaceName} > Workloads`:"Workloads"),e.createElement(p,{label:v.length,status:h.Unknown}))),e.createElement($e,{$borderRadius:"0 16px 16px 0"},v.length?v:e.createElement(b,{title:"Workloads not found",subTitle:"Please select a namespace to view workloads"})))},Ae=({formData:a,handleSourceChange:l,handleSelectAll:n,selectedArea:o,searchText:i,filters:w})=>{const C=s(),{isAll:k,isSome:v}=t(()=>{const e=a.length>0&&a.every(({namespaces:e})=>e.every(({workloads:e})=>e.every(({selected:e})=>e)));return{isAll:e,isSome:!e&&a.length>0&&a.some(({namespaces:e})=>e.some(({workloads:e})=>e.some(({selected:e})=>e)))}},[a]),x=t(()=>a.flatMap(({clusterId:t,clusterName:a,namespaces:n})=>n.map(({name:n,workloads:s,selected:b})=>{if(i&&!n.toLowerCase().includes(i.toLowerCase()))return null;const k=s.filter(({selected:e})=>e).length,v=k>0&&k===s.length,x=k>0&&k<s.length,$=b||!1;if(w.showOnlySelected&&!v&&!x&&!$)return null;const S=o.value.clusterId===t&&o.value.namespaceName===n,I=()=>o.setValue({clusterId:t,clusterName:a,namespaceName:n});return e.createElement(Se,{key:`${t}#${n}`,$isSelected:S,onClick:I},e.createElement(r,{$gap:12},e.createElement(c,{partiallyChecked:x,value:v,onChange:()=>{I(),s.forEach(({name:e,kind:a})=>{l({clusterId:t,workloadId:{namespace:n,name:e,kind:a},boolean:!v})})}}),e.createElement(d,{size:u.XS},`${a} > ${n}`)),e.createElement(r,{$gap:8},e.createElement(m,{text:"Automatically instrument new workloads that are deployed to this namespace in the future"},e.createElement(f,{label:"Auto",size:y.S,value:$,onChange:()=>{l({clusterId:t,workloadId:{namespace:n},boolean:!$}),s.forEach(({name:e,kind:a,selected:o})=>{l({clusterId:t,workloadId:{namespace:n,name:e,kind:a},boolean:o,forceDirty:!$})})}}))),e.createElement(r,{$gap:8},e.createElement(d,{size:u.XXXS,color:C.v2.colors.silver[200],align:"right"},"Selected Sources"),e.createElement(p,{label:`${k}/${s.length}`,status:S?g.Default:h.Unknown})))})),[a,o.value.clusterId,o.value.namespaceName,i,w]);return e.createElement(xe,{$width:"60%"},e.createElement(r,{$padding:"0 12px 0 28px",$gap:12},e.createElement(m,{text:(k?"Unselect":"Select")+" all workloads in all namespaces"},e.createElement(c,{partiallyChecked:v,value:k,onChange:()=>n({boolean:!k}),disabled:!x.length})),e.createElement(r,{$gap:8},e.createElement(d,{size:u.XS,nowrap:!0},"Namespaces"),e.createElement(p,{label:x.length,status:h.Unknown}))),e.createElement($e,{$borderRadius:"16px 0 0 16px"},x.length?x:e.createElement(b,{title:"Namespaces not found",subTitle:""})))},Pe="80vw",Re=o.div`
28
+ `,Ie=({formData:a,handleSourceChange:l,handleSelectAll:n,selectedArea:o,searchText:i,filters:f})=>{const y=s(),{activeNamespace:w,isAll:C,isSome:k}=t(()=>{const e=o.value.clusterId&&o.value.namespaceName?a.find(({clusterId:e})=>e===o.value.clusterId)?.namespaces.find(({name:e})=>e===o.value.namespaceName):void 0;if(!e)return{activeNamespace:void 0,isAll:!1,isSome:!1};const t=e.workloads.filter(({selected:e})=>e).length;return{activeNamespace:e,isAll:t>0&&t===e.workloads.length,isSome:t>0&&t<e.workloads.length}},[a,o.value.clusterId,o.value.namespaceName]),v=t(()=>{if(!w)return[];const{clusterId:t}=o.value,{name:a,workloads:n}=w;return n.map(({name:n,selected:o,kind:s})=>{if(i&&!n.toLowerCase().includes(i.toLowerCase()))return null;const m=o||!1;if(f.showOnlySelected&&!m)return null;const h=()=>l({clusterId:t,workloadId:{namespace:a,name:n,kind:s}});return e.createElement(Se,{key:`${t}#${a}#${n}#${s}`,onClick:h},e.createElement(r,{$gap:12},e.createElement(c,{value:m,onChange:h}),e.createElement(d,{size:u.XS},n)),e.createElement(p,{label:s,status:g.Info,textSize:u.XXXS,backgroundColor:y.v2.colors.blue[900]}))})},[a,o.value.clusterId,w,i,f]);return e.createElement(xe,{$width:"40%"},e.createElement(r,{$padding:"0 12px 0 28px",$gap:12},e.createElement(m,{text:(C?"Unselect":"Select")+" all workloads in the selected namespace"},e.createElement(c,{partiallyChecked:k,value:C,onChange:()=>n({clusterId:o.value.clusterId,namespaceName:o.value.namespaceName,boolean:!C}),disabled:!v.length})),e.createElement(r,{$gap:8},e.createElement(d,{size:u.XS,nowrap:!0},o.value.clusterId?`${o.value.clusterName} > ${o.value.namespaceName} > Workloads`:"Workloads"),e.createElement(p,{label:v.length,status:h.Unknown}))),e.createElement($e,{$borderRadius:"0 16px 16px 0"},v.length?v:e.createElement(b,{title:"Workloads not found",subTitle:"Please select a namespace to view workloads"})))},Ae=({formData:a,handleSourceChange:l,handleSelectAll:n,selectedArea:o,searchText:i,filters:w})=>{const C=s(),{isAll:k,isSome:v}=t(()=>{const e=a.length>0&&a.every(({namespaces:e})=>e.every(({workloads:e})=>e.every(({selected:e})=>e)));return{isAll:e,isSome:!e&&a.length>0&&a.some(({namespaces:e})=>e.some(({workloads:e})=>e.some(({selected:e})=>e)))}},[a]),x=t(()=>a.flatMap(({clusterId:t,clusterName:a,namespaces:n})=>n.map(({name:n,workloads:s,selected:b})=>{if(i&&!n.toLowerCase().includes(i.toLowerCase()))return null;const k=s.filter(({selected:e})=>e).length,v=k>0&&k===s.length,x=k>0&&k<s.length,$=b||!1;if(w.showOnlySelected&&!v&&!x&&!$)return null;const S=o.value.clusterId===t&&o.value.namespaceName===n,I=()=>o.setValue({clusterId:t,clusterName:a,namespaceName:n});return e.createElement(Se,{key:`${t}#${n}`,$isSelected:S,onClick:I},e.createElement(r,{$gap:12},e.createElement(c,{partiallyChecked:x,value:v,onChange:()=>{I(),s.forEach(({name:e,kind:a})=>{l({clusterId:t,workloadId:{namespace:n,name:e,kind:a},boolean:!v})})}}),e.createElement(d,{size:u.XS},`${a} > ${n}`)),e.createElement(r,{$gap:24},e.createElement(m,{text:"Automatically instrument new workloads that are deployed to this namespace in the future"},e.createElement(f,{label:"Auto",size:y.S,value:$,onChange:()=>{l({clusterId:t,workloadId:{namespace:n},boolean:!$}),s.forEach(({name:e,kind:a,selected:o})=>{l({clusterId:t,workloadId:{namespace:n,name:e,kind:a},boolean:o,forceDirty:!$})})}})),e.createElement(r,{$gap:8},e.createElement(d,{size:u.XXXS,color:C.v2.colors.silver[200],align:"right"},"Selected Sources"),e.createElement(p,{label:`${k}/${s.length}`,status:S?g.Default:h.Unknown}))))})),[a,o.value.clusterId,o.value.namespaceName,i,w]);return e.createElement(xe,{$width:"60%"},e.createElement(r,{$padding:"0 12px 0 28px",$gap:12},e.createElement(m,{text:(k?"Unselect":"Select")+" all workloads in all namespaces"},e.createElement(c,{partiallyChecked:v,value:k,onChange:()=>n({boolean:!k}),disabled:!x.length})),e.createElement(r,{$gap:8},e.createElement(d,{size:u.XS,nowrap:!0},"Namespaces"),e.createElement(p,{label:x.length,status:h.Unknown}))),e.createElement($e,{$borderRadius:"16px 0 0 16px"},x.length?x:e.createElement(b,{title:"Namespaces not found",subTitle:""})))},Pe="80vw",Re=o.div`
29
29
  display: flex;
30
30
  flex-direction: column;
31
31
  border-radius: 16px;
@@ -48,7 +48,7 @@ import e,{useMemo as t,useState as a,useEffect as l,useCallback as n}from"react"
48
48
  justify-content: flex-end;
49
49
  gap: 16px;
50
50
  padding: 0 12px;
51
- `,ze=({onClose:o,snapshots:i,selectedConnectionIds:c,setSelectedConnectionIds:p,persistSources:m})=>{const h=s(),{selectedStreamName:b}=w(),T=t(()=>b||C,[b]),[N,z]=a(""),[L,V]=a(k.Namespace),[M,O]=a({showOnlySelected:!1}),[W,j]=a(!1),[F,U]=a(!1),[E,H]=a(void 0),[G,q]=a({clusterId:"",clusterName:"",namespaceName:""}),[Y,B]=a([]);l(()=>{B(e=>{const t=((e,t)=>v(((e,t)=>e.clusters.filter(({clusterId:e})=>t.includes(e)))(e,t)))(i,c);return t.map(t=>{const a=e?.find(e=>e.clusterId===t.clusterId);return a??t})})},[i,c]);const{formDiff:K,isFormDirty:X}=t(()=>{const e=((e,t,a)=>{const l=new Set,n={};return e.forEach(e=>{e.namespaces.forEach(o=>{const s=t.find(t=>t.clusterId===e.clusterId)?.namespaces.find(e=>e.name===o.name);if(o.selected!==s?.selected){const t=`${e.clusterId}#${o.name}`;l.has(t)||(l.add(t),n[e.clusterId]||(n[e.clusterId]=[]),n[e.clusterId].push({namespace:o.name,selected:o.selected||!1,currentStreamName:a}))}o.workloads.forEach(t=>{const i=s?.workloads.find(e=>e.name===t.name&&e.kind===t.kind);if(t.forceDirty||t.selected!==i?.selected){const s=`${e.clusterId}#${o.name}#${t.name}#${t.kind}`;l.has(s)||(l.add(s),n[e.clusterId]||(n[e.clusterId]=[]),n[e.clusterId].push({namespace:o.name,name:t.name,kind:t.kind,selected:t.selected||!1,currentStreamName:a}))}})})}),n})(Y,i.clusters,T);return{formDiff:e,isFormDirty:Object.keys(e).length>0}},[Y,i,T]),J=n(({clusterId:e,workloadId:t,boolean:a,forceDirty:l})=>{B(n=>{const o=v(n),s=o.findIndex(t=>t.clusterId===e);if(-1!==s){const e=o[s].namespaces.findIndex(e=>e.name===t.namespace);if(-1===e)return o;if(t.kind&&t.name){const n=o[s].namespaces[e].workloads.findIndex(e=>e.name===t.name&&e.kind===t.kind);if(-1===n)return o;o[s].namespaces[e].workloads[n].selected="boolean"==typeof a?a:!o[s].namespaces[e].workloads[n].selected,o[s].namespaces[e].workloads[n].forceDirty=l||!1}else o[s].namespaces[e].selected="boolean"==typeof a?a:!o[s].namespaces[e].selected}return o})},[]),Q=n(({clusterId:e,namespaceName:t,boolean:a})=>{B(l=>{const n=v(l);return n.forEach((l,o)=>{e&&l.clusterId!==e||l.namespaces.forEach(({name:e,workloads:l},s)=>{t&&e!==t||l.forEach((e,t)=>{n[o].namespaces[s].workloads[t].selected=a})})}),n})},[]),Z=()=>{j(!1),o()};return e.createElement(x,{isOpen:!0,hideOverlay:!0,width:Pe,header:{icon:oe,title:"Manage Sources",onClose:o}},e.createElement(Re,null,e.createElement(De,null,e.createElement($,{icon:se,title:"Selected Clusters",badge:{label:c.length}}),e.createElement(S,{width:"300px",value:N,onChange:z,segment:{options:[{label:"Namespace",value:k.Namespace},{label:"Source",value:k.Source}],selected:L,setSelected:V}}),e.createElement(r,{$gap:8},e.createElement(d,{size:u.XXXS,color:h.v2.colors.silver[200],nowrap:!0},"Show only:"),e.createElement(f,{size:y.S,label:"Selected",value:M.showOnlySelected,onChange:e=>O(t=>({...t,showOnlySelected:e}))}))),e.createElement(Te,null,e.createElement(Ae,{formData:Y,handleSourceChange:J,handleSelectAll:Q,selectedArea:{value:G,setValue:q},searchText:L===k.Namespace?N:"",filters:M}),e.createElement(Ie,{formData:Y,handleSourceChange:J,handleSelectAll:Q,selectedArea:{value:G,setValue:q},searchText:L===k.Source?N:"",filters:M}))),e.createElement(Ne,null,F?e.createElement(I,{label:"Applying sources...",icon:ie,withGradient:!0,typographyProps:{size:u.XXS}}):E?e.createElement(A,{fullWidth:!0,status:g.Error,message:E}):X?e.createElement(A,{fullWidth:!0,status:g.Info,message:'The values don\'t reflect the current configuration of the selected clusters.\n"Apply" will override the current configurations.'}):X?null:e.createElement(A,{fullWidth:!0,status:g.Success,message:"The values reflect the current configuration of the selected cluster."}),e.createElement(r,{$gap:8},e.createElement("div",{style:{width:"150px"}},e.createElement(P,{fullWidth:!0,variant:R.Secondary,label:"Cancel",onClick:()=>X?j(!0):Z(),disabled:!X||F})),e.createElement("div",{style:{width:"150px"}},e.createElement(P,{fullWidth:!0,variant:R.Primary,label:"Save",onClick:async()=>{U(!0);const{error:e}=await m(K);U(!1),e?H(e):(p([]),o())},disabled:!X||F})))),e.createElement(D,{isOpen:W,onClose:()=>j(!1),onApprove:Z}))},Le="75vw",Ve=o.div`
51
+ `,ze=({onClose:o,snapshots:i,selectedConnectionIds:c,setSelectedConnectionIds:p,persistSources:m})=>{const h=s(),{selectedStreamName:b}=w(),T=t(()=>b||C,[b]),[N,z]=a(""),[L,V]=a(k.Namespace),[M,O]=a({showOnlySelected:!1}),[W,j]=a(!1),[F,U]=a(!1),[E,H]=a(void 0),[G,q]=a({clusterId:"",clusterName:"",namespaceName:""}),[Y,B]=a([]);l(()=>{B(e=>{const t=((e,t)=>v(((e,t)=>e.clusters.filter(({clusterId:e})=>t.includes(e)))(e,t)))(i,c);return t.map(t=>{const a=e?.find(e=>e.clusterId===t.clusterId);return a??t})})},[i,c]);const{formDiff:K,isFormDirty:X}=t(()=>{const e=((e,t,a)=>{const l=new Set,n={};return e.forEach(e=>{e.namespaces.forEach(o=>{const s=t.find(t=>t.clusterId===e.clusterId)?.namespaces.find(e=>e.name===o.name);if(o.selected!==s?.selected){const t=`${e.clusterId}#${o.name}`;l.has(t)||(l.add(t),n[e.clusterId]||(n[e.clusterId]=[]),n[e.clusterId].push({namespace:o.name,selected:o.selected||!1,currentStreamName:a}))}o.workloads.forEach(t=>{const i=s?.workloads.find(e=>e.name===t.name&&e.kind===t.kind);if(t.forceDirty||t.selected!==i?.selected){const s=`${e.clusterId}#${o.name}#${t.name}#${t.kind}`;l.has(s)||(l.add(s),n[e.clusterId]||(n[e.clusterId]=[]),n[e.clusterId].push({namespace:o.name,name:t.name,kind:t.kind,selected:t.selected||!1,currentStreamName:a}))}})})}),n})(Y,i.clusters,T);return{formDiff:e,isFormDirty:Object.keys(e).length>0}},[Y,i,T]),J=n(({clusterId:e,workloadId:t,boolean:a,forceDirty:l})=>{B(n=>{const o=v(n),s=o.findIndex(t=>t.clusterId===e);if(-1!==s){const e=o[s].namespaces.findIndex(e=>e.name===t.namespace);if(-1===e)return o;if(t.kind&&t.name){const n=o[s].namespaces[e].workloads.findIndex(e=>e.name===t.name&&e.kind===t.kind);if(-1===n)return o;o[s].namespaces[e].workloads[n].selected="boolean"==typeof a?a:!o[s].namespaces[e].workloads[n].selected,o[s].namespaces[e].workloads[n].forceDirty=l||!1}else o[s].namespaces[e].selected="boolean"==typeof a?a:!o[s].namespaces[e].selected}return o})},[]),Q=n(({clusterId:e,namespaceName:t,boolean:a})=>{B(l=>{const n=v(l);return n.forEach((l,o)=>{e&&l.clusterId!==e||l.namespaces.forEach(({name:e,workloads:l},s)=>{t&&e!==t||l.forEach((e,t)=>{n[o].namespaces[s].workloads[t].selected=a})})}),n})},[]),Z=()=>{j(!1),o()};return e.createElement(x,{isOpen:!0,hideOverlay:!0,width:Pe,header:{icon:oe,title:"Manage Sources",onClose:o}},e.createElement(Re,null,e.createElement(De,null,e.createElement($,{icon:se,title:"Selected Clusters",badge:{label:c.length}}),e.createElement(S,{width:"300px",value:N,onChange:z,segment:{options:[{label:"Namespace",value:k.Namespace},{label:"Source",value:k.Source}],selected:L,setSelected:V}}),e.createElement(r,{$gap:8},e.createElement(d,{size:u.XXXS,color:h.v2.colors.silver[200],nowrap:!0},"Show only:"),e.createElement(f,{size:y.S,label:"Selected",value:M.showOnlySelected,onChange:e=>O(t=>({...t,showOnlySelected:e}))}))),e.createElement(Te,null,e.createElement(Ae,{formData:Y,handleSourceChange:J,handleSelectAll:Q,selectedArea:{value:G,setValue:q},searchText:L===k.Namespace?N:"",filters:M}),e.createElement(Ie,{formData:Y,handleSourceChange:J,handleSelectAll:Q,selectedArea:{value:G,setValue:q},searchText:L===k.Source?N:"",filters:M}))),e.createElement(Ne,null,F?e.createElement(I,{label:"Applying sources...",icon:ie,withGradient:!0,typographyProps:{size:u.XXS}}):E?e.createElement(A,{fullWidth:!0,status:g.Error,message:E}):X?e.createElement(A,{fullWidth:!0,status:g.Info,message:'The values don\'t reflect the current configuration of the selected clusters.\n"Apply" will override the current configurations.'}):X?null:e.createElement(A,{fullWidth:!0,status:g.Success,message:"The values reflect the current configuration of the selected cluster."}),e.createElement(r,{$gap:8},e.createElement("div",{style:{width:"150px"}},e.createElement(P,{fullWidth:!0,variant:R.Secondary,label:"Cancel",onClick:()=>X?j(!0):Z(),disabled:!X||F})),e.createElement("div",{style:{width:"150px"}},e.createElement(P,{fullWidth:!0,variant:R.Primary,label:"Save",onClick:async()=>{U(!0);const e=await m(K);U(!1),e?.error?H(e.error):(p([]),o())},disabled:!X||F})))),e.createElement(D,{isOpen:W,onClose:()=>j(!1),onApprove:Z}))},Le="75vw",Ve=o.div`
52
52
  display: flex;
53
53
  flex-direction: column;
54
54
  border-radius: 16px;
@@ -97,7 +97,7 @@ import e,{useMemo as t,useState as a,useEffect as l,useCallback as n}from"react"
97
97
  justify-content: flex-end;
98
98
  gap: 16px;
99
99
  padding: 0 12px;
100
- `,Ee=({onClose:n,connections:o,selectedConnectionIds:i,setSelectedConnectionIds:m,getConnectionRemoteConfig:b,onApply:w})=>{const C=s(),[k,v]=a(""),[z,L]=a({showOnlySelected:!1}),V=t(()=>o.filter(e=>(!k||e.name.toLowerCase().includes(k.toLowerCase()))&&(!z.showOnlySelected||i.includes(e.id))),[o,i.length,k,z]),M=e=>{m(t=>t.includes(e)?t.filter(t=>t!==e):[...t,e])},[O,W]=a(!1),[j,F]=a(!1),[U,E]=a(void 0),[H,G]=a(!1),[q,Y]=a(void 0),{formData:B,handleFormChange:K,areFormValuesEqual:X,resetFormData:J}=T(q||{automaticRollout:!0}),{isFormDirty:Q,isFormMatch:Z}=t(()=>({isFormDirty:i.length>1||void 0!==q&&!X(q,B),isFormMatch:1===i.length&&void 0!==q&&X(q,B)}),[i.length,q,B]);l(()=>{1===i.length?(async e=>{if(H)return;G(!0);const t=await b(e);if(t){const e={automaticRollout:!t.rollout?.automaticRolloutDisabled};Y(e),J(e)}G(!1)})(i[0]):Y(void 0)},[i.length]);const _=()=>{W(!1),n()};return e.createElement(x,{isOpen:!0,hideOverlay:!0,width:Le,header:{icon:re,title:"Cluster Configuration",onClose:n}},e.createElement(Ve,null,e.createElement(Me,null,e.createElement($,{icon:se,title:"Selected Clusters",badge:{label:i.length}}),e.createElement(S,{width:"300px",placeholder:"Search by cluster name",value:k,onChange:v}),e.createElement(r,{$gap:8},e.createElement(d,{size:u.XXXS,color:C.v2.colors.silver[200],nowrap:!0},"Show only:"),e.createElement(f,{size:y.S,label:"Selected",value:z.showOnlySelected,onChange:e=>L(t=>({...t,showOnlySelected:e}))}))),e.createElement(Oe,null,e.createElement(We,{$width:"40%"},e.createElement(r,{$padding:"0 12px",$justifyContent:"space-between"},e.createElement(r,{$gap:8},e.createElement(d,{size:u.XS},"Clusters"),e.createElement(p,{label:o.length,status:h.Unknown})),e.createElement(r,{$gap:8},e.createElement(d,{size:u.XXXS,color:C.v2.colors.silver[200],align:"right"},"Selected clusters"),e.createElement(p,{label:`${i.length}/${o.length}`,status:h.Unknown}))),e.createElement(je,{$borderRadius:"16px 0 0 16px"},V.map(t=>e.createElement(Fe,{key:t.id,onClick:()=>M(t.id)},e.createElement(c,{value:i.includes(t.id),onChange:()=>M(t.id)}),e.createElement(d,{size:u.XS},t.name))))),e.createElement(We,{$width:"60%"},e.createElement(r,{$padding:"0 12px"},e.createElement(d,{size:u.XS},"Configurations")),e.createElement(je,{$borderRadius:"0 16px 16px 0",$gap:12},H?e.createElement(N,null):e.createElement(f,{label:"Automatic Rollout "+(B.automaticRollout?"Enabled":"Disabled"),tooltip:"Odigos automatically triggers a one-time rollout for workloads when instrumenting or uninstrumenting, ensuring that changes are applied without requiring manual intervention. When automatic rollout is enabled, Odigos will proactively restart workloads as needed to apply updated instrumentation. Users do not need to manually trigger rollouts after adding or removing sources. Any new pods created after enabling or disabling the agent (via automatic rollout, autoscaling, etc.) will still have the agent injected, regardless of this setting. When set to false, additional configurations related to automated rollouts or rollbacks take effect.",value:B.automaticRollout,onChange:e=>K("automaticRollout",e)}))))),e.createElement(Ue,null,H?e.createElement(I,{label:"Fetching configuration...",icon:ie,withGradient:!0,typographyProps:{size:u.XXS}}):j?e.createElement(I,{label:"Applying configurations...",icon:ie,withGradient:!0,typographyProps:{size:u.XXS}}):U?e.createElement(A,{fullWidth:!0,status:g.Error,message:U}):Q?e.createElement(A,{fullWidth:!0,status:g.Info,message:'The values don\'t reflect the current configuration of the selected clusters.\n"Apply" will override the current configurations.'}):Z?e.createElement(A,{fullWidth:!0,status:g.Success,message:"The values reflect the current configuration of the selected cluster."}):null,e.createElement(r,{$gap:8},e.createElement("div",{style:{width:"150px"}},e.createElement(P,{fullWidth:!0,variant:R.Secondary,label:"Cancel",onClick:()=>Q?W(!0):_(),disabled:j})),e.createElement("div",{style:{width:"150px"}},e.createElement(P,{fullWidth:!0,variant:R.Primary,label:"Save",onClick:async()=>{F(!0);const{error:e}=await w(i,B);F(!1),e?E(e):(m([]),n())},disabled:!Q||j})))),e.createElement(D,{isOpen:O,onClose:()=>W(!1),onApprove:_}))};var He,Ge;!function(e){e.BulkConfig="bulk-config",e.BulkSource="bulk-source",e.BulkDestination="bulk-destination",e.BulkAction="bulk-action",e.BulkInstrumentationRule="bulk-instrumentation-rule",e.Delete="delete"}(He||(He={})),function(e){e.Id="id",e.Name="name",e.Type="type",e.Status="status",e.OdigosVersion="odigosVersion",e.ConnectedSince="connectedSince",e.LastActivity="lastActivity"}(Ge||(Ge={}));const qe=[{key:Ge.Name,label:"Name"},{key:Ge.Type,label:"Type",textAlign:"right"},{key:Ge.Status,label:"Status"},{key:Ge.OdigosVersion,label:"Odigos Version"},{key:Ge.ConnectedSince,label:"Connected Since"},{key:Ge.LastActivity,label:"Last Activity"}],Ye=(e,t)=>{const a=e.find(e=>e.key===Ge.Id)?.rawValue;a&&t(a.toString())},Be=({tableRowsMaxHeight:o,connections:i,getConnections:r,onClickConnection:c,deleteConnection:d,getConnectionRemoteConfig:u,applyConfigurations:m,getAllClusterSnapshots:b,persistSources:f})=>{const y=s(),{formatTimeAgo:w}=z(),[C,k]=a(!1),[v,x]=a(i||[]),[$,S]=a(!1),[I,A]=a(null),P=n(async()=>{try{k(!0),x(await r()??[])}catch(e){}finally{k(!1)}},[]),D=n(async()=>{if(b)try{S(!0),A(await b()??null)}catch(e){}finally{S(!1)}},[]);l(()=>{v.length||P()},[v.length,P]),l(()=>{I||D()},[I,D]);const[T,N]=a(""),[G,q]=a(null),[Y,B]=a([]),K=t(()=>v.filter(e=>e.status===g.Success),[v]),X=t(()=>v.filter(e=>!T||e.name.toLowerCase().includes(T.toLowerCase())).map(t=>({cells:[{key:Ge.Id,rawValue:t.id},{key:Ge.Name,rawValue:t.name},{key:Ge.Type,rawValue:t.type},{key:Ge.Status,rawValue:t.status,component:()=>(t=>{const a=t===g.Success?"Connection live":"Connection lost",l=t===g.Success?pe:ge;return e.createElement(p,{status:t,label:a,leftIcon:l})})(t.status)},{key:Ge.OdigosVersion,rawValue:t.odigosVersion},{key:Ge.ConnectedSince,rawValue:t.connectedAt?w(t.connectedAt):"-"},{key:Ge.LastActivity,rawValue:t.lastSeenAt?w(t.lastSeenAt):"-"}],onClick:t.status===g.Success?()=>c(t):void 0,isSelected:Y.includes(t.id),onSelect:()=>B(e=>Array.from(new Set([...e,t.id]))),onDeselect:()=>B(e=>e.filter(e=>e!==t.id)),hideCheckbox:t.status!==g.Success})),[v,Y,T]);return e.createElement(L,null,e.createElement(V,{richTitle:{icon:ce,title:"Connections",badge:{label:v.length.toString(),status:h.Unknown}},search:{placeholder:"Search by cluster name",value:T,onChange:e=>N(e),width:"300px"},actions:[{id:M(),type:O.Button,buttonProps:{variant:R.Secondary,size:W.S,leftIcon:de,onClick:async()=>{await P(),await D()},disabled:C||$}}]},e.createElement(j,{variant:F.Pretty,maxHeight:o,headerBackgroundColor:y.v2.colors.silver[1e3],isLoading:C,withCheckboxes:!0,columns:qe,rows:X,rowActionsPushRightPosition:G?`calc(${G===He.BulkConfig?Le:Pe} - 24px)`:void 0,getRowActions:({cells:e})=>(e=>e.find(e=>e.key===Ge.Status)?.rawValue===g.Success)(e)?[I&&f?{id:M(),label:"Manage Sources",rightIcon:oe,onClick:async()=>{Ye(e,e=>{B([e]),q(He.BulkSource)})}}:null,u&&m?{id:M(),label:"Edit Configuration",rightIcon:re,onClick:async()=>{Ye(e,e=>{B([e]),q(He.BulkConfig)})}}:null]:[{id:M(),label:"Delete Connection",rightIcon:ue,onClick:()=>{Ye(e,e=>{B([e]),q(He.Delete)})}}]}),G===He.BulkConfig&&u&&m&&e.createElement(Ee,{onClose:()=>q(null),connections:K,selectedConnectionIds:Y,setSelectedConnectionIds:B,getConnectionRemoteConfig:u,onApply:m}),G===He.BulkSource&&I&&f&&e.createElement(ze,{onClose:()=>q(null),snapshots:I,selectedConnectionIds:Y,setSelectedConnectionIds:B,persistSources:f}),e.createElement(U,{target:"connection",isOpen:G===He.Delete,onClose:()=>{B([]),q(null)},onApprove:async()=>{const e=Y[0];e&&(await d(e),await P())}}),e.createElement(E,{isOpen:!!Y.length&&!G,richTitle:{icon:se,title:"Selected Clusters",badge:{label:Y.length}},actions:[{id:M(),type:O.Button,buttonProps:{variant:R.Text,size:W.S,label:"Cancel",onClick:()=>B([])}},I&&f?{id:M(),type:O.ButtonDropData,buttonProps:{variant:R.Secondary,size:W.S,label:"Add Component",onClick:e=>q(e)},dropDataProps:{alignX:H.Left,items:[{id:He.BulkSource,label:"Add Source",icon:oe}]}}:null,u&&m?{id:M(),type:O.Button,buttonProps:{variant:R.Primary,size:W.S,label:"Manage Configurations",rightIcon:re,onClick:()=>q(He.BulkConfig)}}:null]})))},Ke=o.div`
100
+ `,Ee=({onClose:n,connections:o,selectedConnectionIds:i,setSelectedConnectionIds:m,getConnectionRemoteConfig:b,onApply:w})=>{const C=s(),[k,v]=a(""),[z,L]=a({showOnlySelected:!1}),V=t(()=>o.filter(e=>(!k||e.name.toLowerCase().includes(k.toLowerCase()))&&(!z.showOnlySelected||i.includes(e.id))),[o,i.length,k,z]),M=e=>{m(t=>t.includes(e)?t.filter(t=>t!==e):[...t,e])},[O,W]=a(!1),[j,F]=a(!1),[U,E]=a(void 0),[H,G]=a(!1),[q,Y]=a(void 0),{formData:B,handleFormChange:K,areFormValuesEqual:X,resetFormData:J}=T(q||{automaticRollout:!0}),{isFormDirty:Q,isFormMatch:Z}=t(()=>({isFormDirty:i.length>1||void 0!==q&&!X(q,B),isFormMatch:1===i.length&&void 0!==q&&X(q,B)}),[i.length,q,B]);l(()=>{1===i.length?(async e=>{if(H)return;G(!0);const t=await b(e);if(t){const e={automaticRollout:!t.rollout?.automaticRolloutDisabled};Y(e),J(e)}G(!1)})(i[0]):Y(void 0)},[i.length]);const _=()=>{W(!1),n()};return e.createElement(x,{isOpen:!0,hideOverlay:!0,width:Le,header:{icon:re,title:"Cluster Configuration",onClose:n}},e.createElement(Ve,null,e.createElement(Me,null,e.createElement($,{icon:se,title:"Selected Clusters",badge:{label:i.length}}),e.createElement(S,{width:"300px",placeholder:"Search by cluster name",value:k,onChange:v}),e.createElement(r,{$gap:8},e.createElement(d,{size:u.XXXS,color:C.v2.colors.silver[200],nowrap:!0},"Show only:"),e.createElement(f,{size:y.S,label:"Selected",value:z.showOnlySelected,onChange:e=>L(t=>({...t,showOnlySelected:e}))}))),e.createElement(Oe,null,e.createElement(We,{$width:"40%"},e.createElement(r,{$padding:"0 12px",$justifyContent:"space-between"},e.createElement(r,{$gap:8},e.createElement(d,{size:u.XS},"Clusters"),e.createElement(p,{label:o.length,status:h.Unknown})),e.createElement(r,{$gap:8},e.createElement(d,{size:u.XXXS,color:C.v2.colors.silver[200],align:"right"},"Selected clusters"),e.createElement(p,{label:`${i.length}/${o.length}`,status:h.Unknown}))),e.createElement(je,{$borderRadius:"16px 0 0 16px"},V.map(t=>e.createElement(Fe,{key:t.id,onClick:()=>M(t.id)},e.createElement(c,{value:i.includes(t.id),onChange:()=>M(t.id)}),e.createElement(d,{size:u.XS},t.name))))),e.createElement(We,{$width:"60%"},e.createElement(r,{$padding:"0 12px"},e.createElement(d,{size:u.XS},"Configurations")),e.createElement(je,{$borderRadius:"0 16px 16px 0",$gap:12},H?e.createElement(N,null):e.createElement(f,{label:"Automatic Rollout "+(B.automaticRollout?"Enabled":"Disabled"),tooltip:"Odigos automatically triggers a one-time rollout for workloads when instrumenting or uninstrumenting, ensuring that changes are applied without requiring manual intervention. When automatic rollout is enabled, Odigos will proactively restart workloads as needed to apply updated instrumentation. Users do not need to manually trigger rollouts after adding or removing sources. Any new pods created after enabling or disabling the agent (via automatic rollout, autoscaling, etc.) will still have the agent injected, regardless of this setting. When set to false, additional configurations related to automated rollouts or rollbacks take effect.",value:B.automaticRollout,onChange:e=>K("automaticRollout",e)}))))),e.createElement(Ue,null,H?e.createElement(I,{label:"Fetching configuration...",icon:ie,withGradient:!0,typographyProps:{size:u.XXS}}):j?e.createElement(I,{label:"Applying configurations...",icon:ie,withGradient:!0,typographyProps:{size:u.XXS}}):U?e.createElement(A,{fullWidth:!0,status:g.Error,message:U}):Q?e.createElement(A,{fullWidth:!0,status:g.Info,message:'The values don\'t reflect the current configuration of the selected clusters.\n"Apply" will override the current configurations.'}):Z?e.createElement(A,{fullWidth:!0,status:g.Success,message:"The values reflect the current configuration of the selected cluster."}):null,e.createElement(r,{$gap:8},e.createElement("div",{style:{width:"150px"}},e.createElement(P,{fullWidth:!0,variant:R.Secondary,label:"Cancel",onClick:()=>Q?W(!0):_(),disabled:j})),e.createElement("div",{style:{width:"150px"}},e.createElement(P,{fullWidth:!0,variant:R.Primary,label:"Save",onClick:async()=>{F(!0);const e=await w(i,B);F(!1),e?.error?E(e.error):(m([]),n())},disabled:!Q||j})))),e.createElement(D,{isOpen:O,onClose:()=>W(!1),onApprove:_}))};var He,Ge;!function(e){e.BulkConfig="bulk-config",e.BulkSource="bulk-source",e.BulkDestination="bulk-destination",e.BulkAction="bulk-action",e.BulkInstrumentationRule="bulk-instrumentation-rule",e.Delete="delete"}(He||(He={})),function(e){e.Id="id",e.Name="name",e.Type="type",e.Status="status",e.OdigosVersion="odigosVersion",e.ConnectedSince="connectedSince",e.LastActivity="lastActivity"}(Ge||(Ge={}));const qe=[{key:Ge.Name,label:"Name"},{key:Ge.Type,label:"Type",textAlign:"right"},{key:Ge.Status,label:"Status"},{key:Ge.OdigosVersion,label:"Odigos Version"},{key:Ge.ConnectedSince,label:"Connected Since"},{key:Ge.LastActivity,label:"Last Activity"}],Ye=(e,t)=>{const a=e.find(e=>e.key===Ge.Id)?.rawValue;a&&t(a.toString())},Be=({tableRowsMaxHeight:o,connections:i,getConnections:r,onClickConnection:c,deleteConnection:d,getConnectionRemoteConfig:u,applyConfigurations:m,getAllClusterSnapshots:b,persistSources:f})=>{const y=s(),{formatTimeAgo:w}=z(),[C,k]=a(!1),[v,x]=a(i||[]),[$,S]=a(!1),[I,A]=a(null),P=n(async()=>{try{k(!0),x(await r()??[])}catch(e){}finally{k(!1)}},[]),D=n(async()=>{if(b)try{S(!0),A(await b()??null)}catch(e){}finally{S(!1)}},[]);l(()=>{v.length||P()},[v.length,P]),l(()=>{I||D()},[I,D]);const[T,N]=a(""),[G,q]=a(null),[Y,B]=a([]),K=t(()=>v.filter(e=>e.status===g.Success),[v]),X=t(()=>v.filter(e=>!T||e.name.toLowerCase().includes(T.toLowerCase())).map(t=>({cells:[{key:Ge.Id,rawValue:t.id},{key:Ge.Name,rawValue:t.name},{key:Ge.Type,rawValue:t.type},{key:Ge.Status,rawValue:t.status,component:()=>(t=>{const a=t===g.Success?"Connection live":"Connection lost",l=t===g.Success?pe:ge;return e.createElement(p,{status:t,label:a,leftIcon:l})})(t.status)},{key:Ge.OdigosVersion,rawValue:t.odigosVersion},{key:Ge.ConnectedSince,rawValue:t.connectedAt?w(t.connectedAt):"-"},{key:Ge.LastActivity,rawValue:t.lastSeenAt?w(t.lastSeenAt):"-"}],onClick:t.status===g.Success?()=>c(t):void 0,isSelected:Y.includes(t.id),onSelect:()=>B(e=>Array.from(new Set([...e,t.id]))),onDeselect:()=>B(e=>e.filter(e=>e!==t.id)),hideCheckbox:t.status!==g.Success})),[v,Y,T]);return e.createElement(L,null,e.createElement(V,{richTitle:{icon:ce,title:"Connections",badge:{label:v.length.toString(),status:h.Unknown}},search:{placeholder:"Search by cluster name",value:T,onChange:e=>N(e),width:"300px"},actions:[{id:M(),type:O.Button,buttonProps:{variant:R.Secondary,size:W.S,leftIcon:de,onClick:async()=>{await P(),await D()},disabled:C||$}}]},e.createElement(j,{variant:F.Pretty,maxHeight:o,headerBackgroundColor:y.v2.colors.silver[1e3],isLoading:C,withCheckboxes:!0,columns:qe,rows:X,rowActionsPushRightPosition:G?`calc(${G===He.BulkConfig?Le:Pe} - 24px)`:void 0,getRowActions:({cells:e})=>(e=>e.find(e=>e.key===Ge.Status)?.rawValue===g.Success)(e)?[I&&f?{id:M(),label:"Manage Sources",rightIcon:oe,onClick:async()=>{Ye(e,e=>{B([e]),q(He.BulkSource)})}}:null,u&&m?{id:M(),label:"Edit Configuration",rightIcon:re,onClick:async()=>{Ye(e,e=>{B([e]),q(He.BulkConfig)})}}:null]:[{id:M(),label:"Delete Connection",rightIcon:ue,onClick:()=>{Ye(e,e=>{B([e]),q(He.Delete)})}}]}),G===He.BulkConfig&&u&&m&&e.createElement(Ee,{onClose:()=>q(null),connections:K,selectedConnectionIds:Y,setSelectedConnectionIds:B,getConnectionRemoteConfig:u,onApply:m}),G===He.BulkSource&&I&&f&&e.createElement(ze,{onClose:()=>q(null),snapshots:I,selectedConnectionIds:Y,setSelectedConnectionIds:B,persistSources:async e=>{if(!f)return{error:"Persist sources function is not defined"};const t=await f(e);return t?.error||await D(),t}}),e.createElement(U,{target:"connection",isOpen:G===He.Delete,onClose:()=>{B([]),q(null)},onApprove:async()=>{const e=Y[0];e&&(await d(e),await P())}}),e.createElement(E,{isOpen:!!Y.length&&!G,richTitle:{icon:se,title:"Selected Clusters",badge:{label:Y.length}},actions:[{id:M(),type:O.Button,buttonProps:{variant:R.Text,size:W.S,label:"Cancel",onClick:()=>B([])}},I&&f?{id:M(),type:O.ButtonDropData,buttonProps:{variant:R.Secondary,size:W.S,label:"Add Component",onClick:e=>q(e)},dropDataProps:{alignX:H.Left,items:[{id:He.BulkSource,label:"Add Source",icon:oe}]}}:null,u&&m?{id:M(),type:O.Button,buttonProps:{variant:R.Primary,size:W.S,label:"Manage Configurations",rightIcon:re,onClick:()=>q(He.BulkConfig)}}:null]})))},Ke=o.div`
101
101
  display: flex;
102
102
  align-items: center;
103
103
  justify-content: space-between;