PageSourceSearch

https://app.bob-e.ai/static/react/3223.3a5d70045576e5e50468.js

js bob-e.ai collected 2026-10-05 11:52:24 UTC 4,331 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunkStammer_ai=self.webpackChunkStammer_ai||[]).push([[3223],{13223:function(e,n,t){t.r(n),t.d(n,{ChatbotInboxAllPage:function(){return T}});var a=t(78685),r=t(2057),o=t(86591),i=t(17e3),l=t(16657),u=t(78166),s=t(99658),c=t(982),d=t(11815),f=t(26832),h=t(57275),p=t(7017),v=function(){return v=Object.assign||function(e){for(var n,t=1,a=arguments.length;t<a;t++)for(var r in n=arguments[t])Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);return e},v.apply(this,arguments)},g=function(e,n,t){if(t||2===arguments.length)for(var a,r=0,o=n.length;r<o;r++)!a&&r in n||(a||(a=Array.prototype.slice.call(n,0,r)),a[r]=n[r]);return e.concat(a||Array.prototype.slice.call(n))},m=0,A=function(e){var n=e.value,t=e.onChange,o=e.onResolveDefault,i=(0,l.Bd)().t,s=r.useState(""),c=s[0],d=s[1],A=r.useState(""),S=A[0],x=A[1],b=r.useMemo((function(){return{id:m,name:i("DISPLAY_LABELS.ALL_CHATBOTS")}}),[i]);r.useEffect((function(){var e=window.setTimeout((function(){return x(c)}),300);return function(){return window.clearTimeout(e)}}),[c]);var T=(0,h.AN)(20,v(v({},p.q9),{sortBy:"name",search:S})),L=T.data,I=T.isLoading,_=T.isError,N=T.isFetchingNextPage,P=T.hasNextPage,j=T.fetchNextPage,w=r.useMemo((function(){var e,t=(null!==(e=null==L?void 0:L.pages)&&void 0!==e?e:[]).flatMap((function(e){var n;return(null!==(n=e.results)&&void 0!==n?n:[]).map((function(e){return{id:e.id,name:e.displayName||e.name}}))})),a=g([b],t,!0);return n&&!t.some((function(e){return e.id===n.id}))?n.id===m?a:g([b,n],t,!0):a}),[b,L,n]),C=r.useRef(!1);r.useEffect((function(){var e;if(!n&&o&&!C.current)return _?(C.current=!0,void o(null)):void(!I&&(null===(e=null==L?void 0:L.pages)||void 0===e?void 0:e.length)&&(C.current=!0,o(b)))}),[b,L,_,I,o,n]);return(0,a.jsx)(u.jT8,{size:"small",sx:{width:"100%"},options:w,value:n,disableClearable:!0,loading:I||N,onChange:function(e,n){d(""),t(n)},onInputChange:function(e,n,t){"input"===t&&d(n),"clear"===t&&d("")},filterOptions:function(e){return e},getOptionLabel:function(e){return e.name},isOptionEqualToValue:function(e,n){return e.id===n.id},noOptionsText:i(_?"DISPLAY_STRINGS.FAILED_TO_LOAD_AI_AGENTS_DATA":"DISPLAY_STRINGS.NO_AI_AGENT_FOUND"),loadingText:i("DISPLAY_STRINGS.LOADING"),slotProps:{listbox:{onScroll:function(e){if(P&&!N){var n=e.currentTarget;n.scrollTop+n.clientHeight>=n.scrollHeight-48&&j()}},sx:{maxHeight:320,overflowY:"auto"}}},renderInput:function(e){return(0,a.jsx)(u.A_L,v({},e,{placeholder:i("DISPLAY_STRINGS.SELECT_AI_AGENT"),slotProps:{input:v(v({},e.InputProps),{startAdornment:(0,a.jsx)(u.jC1,{position:"start",children:(0,a.jsx)(f.A,{sx:{marginLeft:"5px"},fontSize:"small",color:"disabled"})}),endAdornment:(0,a.jsxs)(a.Fragment,{children:[I||N?(0,a.jsx)(u.PaH,{size:16}):null,e.InputProps.endAdornment]})})}}))}})},S=t(26165),x="chatbot_id",b="conversation_id";function T(){var e,n,t=(0,l.Bd)().t,f=(0,i.ok)(),h=f[0],p=f[1],v=r.useState(null),g=v[0],T=v[1],L=r.useState("conversations"),I=L[0],_=L[1],N=r.useState(!1),P=N[0],j=N[1],w=r.useState((function(){return!h.get(x)})),C=w[0],y=w[1],O=h.get(x),D=Number(O),E="all"===O?m:Number.isFinite(D)&&D>0?D:null,B=(null==g?void 0:g.id)===E,F=(0,o.I)({queryKey:["chatbot-layout-header",E],queryFn:function(){return(0,s.PF)(E)},enabled:null!==E&&E>0&&!B,retry:!1,staleTime:3e4}).data,k=null===E?null:E===m?{id:m,name:t("DISPLAY_LABELS.ALL_CHATBOTS")}:{id:E,name:B?g.name:null!==(n=null===(e=null==F?void 0:F.chatbot)||void 0===e?void 0:e.name)&&void 0!==n?n:""},G=r.useCallback((function(e,n){T(e),p((function(n){var t=new URLSearchParams(n);return t.delete(b),e?t.set(x,e.id===m?"all":String(e.id)):t.delete(x),t}),{replace:n})}),[p]),H=r.useCallback((function(e){j(!0),G(e,!1)}),[G]),R=r.useCallback((function(e){y(!1),e&&G(e,!0)}),[G]),Y=(0,a.jsx)(A,{value:k,onChange:H,onResolveDefault:null!==E||P?void 0:R});return(0,a.jsx)(d.H,{heading:t("DISPLAY_LABELS.INBOX"),showTabs:!1,showBackToList:!1,showHeader:!0,currentViewName:"chat-inbox",disableLegacyContentPadding:!0,children:null!==E?(0,a.jsx)(s.hu,{chatbot:E,chatbotName:null==k?void 0:k.name,chatAgentFilter:Y,activeTab:I,onTabChange:_,showInboxTitle:!1},E):C?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(u.azJ,{sx:{display:"none"},children:Y}),(0,a.jsx)(S.u5,{showInboxTitle:!1})]}):(0,a.jsx)(c.qx,{chatAgentFilter:Y,showInboxTitle:!1})})}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.