PageSourceSearch

https://app.courier.com/_next/static/chunks/pages/index-750ca234b0ef7a19.js

js courier.com collected 2026-10-01 10:34:23 UTC 6,646 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5405],{87314:function(e,t,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/",function(){return r(64796)}])},55545:function(e,t,r){"use strict";r.d(t,{v:function(){return C}});var a=r(50930),s=r(52322),l=r(2784),n=r(44728),i=r(78406),o=r(14310),d=r(19557),c=r(93278),u=r(5632),x=r(42946),f=r(24427),m=r(2972),h=r(22063),p=r(57248),v=r(59324),b=r(49228),w=r(56982),j=r(17276),g=r(85602),N=r(87490),k=r(176),y=r(3938);var C=function(){var e,t,r=(0,u.useRouter)(),C=(0,j.V$)(),_=(0,l.useContext)(i.z),E=_.user,S=_.logout,T=(0,o.S)(),O=T.tenantsListState,R=T.refetchTenants,W=(0,g.N)(),I=W.selectableWorkspaces,L=W.handleWorkspaceSwitch,V=W.loadingWorkspaceId,z=W.selectedWorkspace,A=W.handleResetSelectedWorkspace,B=(0,l.useState)(""),F=B[0],P=B[1],Q=(0,l.useRef)(!1),U=function(e,t){var r,s;return(t.trim()?e.filter((function(e){var r;return null===(r=e.name)||void 0===r?void 0:r.toLowerCase().includes(t.toLowerCase())})):(0,a.Z)(e)).sort((function(e,t){return(null!==(r=t.created)&&void 0!==r?r:0)-(null!==(s=e.created)&&void 0!==s?s:0)}))}(I,F),X="loaded"===O&&0===I.length;if((0,l.useEffect)((function(){Q.current?X&&r.replace("/create-workspace"):E&&("error"===O||X)&&(Q.current=!0,R())}),[null===E||void 0===E?void 0:E.username,O,X,R]),!E)return null;var Z=null!==(t=null===(e=E.attributes)||void 0===e?void 0:e.email)&&void 0!==t?t:E.username,q=(0,b.Q)(Z,1)||"U";return"loading"===O||X?(0,s.jsx)(n.SX,{fullViewport:!0}):(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)("div",{className:"flex min-h-screen w-full flex-col bg-[var(--background-default)]",children:[(0,s.jsxs)("div",{className:"flex h-14 w-full shrink-0 items-center justify-between px-5",children:[(0,s.jsx)("a",{href:"https://www.courier.com",className:"cursor-pointer border-0 bg-transparent p-0 transition-opacity hover:opacity-80","aria-label":"Courier home",children:(0,s.jsx)(w.TRl,{className:"h-[20px] w-[104px] text-header dark:text-white"})}),(0,s.jsxs)(p.J2,{children:[(0,s.jsx)(p.xo,{asChild:!0,children:(0,s.jsx)(h.default,{variant:"brand",className:"h-8 w-8 rounded-md border-[1px] text-md font-semibold",children:(0,s.jsx)(m.q,{text:q,className:"w-full"})})}),(0,s.jsxs)(p.yk,{side:"bottom",align:"end",className:"w-fit min-w-72 overflow-hidden",children:[(0,s.jsxs)("div",{className:"flex items-center gap-4 p-4",children:[(0,s.jsx)(m.q,{text:q,variant:"brand",size:"lg"}),(0,s.jsxs)("div",{className:"flex flex-col",children:[(0,s.jsx)(d.default,{variant:"medium-sm",children:"My account"}),(0,s.jsx)(d.default,{variant:"regular-sm",children:Z})]})]}),(0,s.jsx)("div",{className:"w-full border-0 border-b border-solid border-structure-border"}),(0,s.jsx)(v.Q,{icon:x.oTz,label:"Log out",onClick:S})]})]})]}),(0,s.jsx)("div",{className:"flex min-h-0 flex-1 items-start justify-center px-4 py-10",children:(0,s.jsxs)("div",{className:"mx-auto flex w-full max-w-[1120px] flex-col items-start px-4 sm:max-w-[608px] md:max-w-[864px]",children:[(0,s.jsx)("div",{className:"mb-4 w-full text-left",children:(0,s.jsx)(d.default,{variant:"semibold-4xl",className:"text-header",children:"Select a Workspace"})}),I.length>0&&(0,s.jsx)("div",{className:"mt-2 w-full",children:(0,s.jsx)(c.Z,{className:"w-full [&_input]:w-full",placeholder:"Search workspaces",onChange:function(e){return P(e.target.value)}})}),"error"===O&&(0,s.jsxs)("div",{className:"mt-4 flex w-full flex-col items-center justify-center gap-2 py-12",children:[(0,s.jsx)(d.default,{variant:"bold-xl",className:"text-default",children:"Failed to load workspaces"}),(0,s.jsx)(d.default,{variant:"regular-md",className:"text-default",children:"Please refresh the page or try again later."})]}),"loaded"===O&&(0,s.jsx)("div",{className:"mt-4 w-full",children:(0,s.jsxs)("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-2",children:[(0,s.jsxs)("button",{type:"button",onClick:function(){return r.push(C.settings.workspaces.create)},className:"relative flex h-[80px] min-w-0 flex-1 cursor-pointer flex-col items-center justify-center overflow-hidden rounded-[6px] border-[1px] border-solid border-neutral-200 bg-neutral-50 px-[16px] py-[5px] shadow-sm transition-all duration-200 hover:bg-neutral-100 active:bg-neutral-200 dark:border-neutral-600 dar
1k:bg-neutral-800 dark:hover:bg-neutral-700 dark:active:bg-neutral-600",children:[(0,s.jsx)(f.v,{icon:x.r8p,className:"absolute left-4 h-4 w-4 text-neutral-400 dark:text-neutral-400"}),(0,s.jsx)(d.default,{className:"text-center text-header transition-all duration-200 dark:text-white",variant:"medium-sm",children:"Create a new workspace"}),(0,s.jsx)(d.default,{className:"text-center text-subtext dark:text-neutral-400",variant:"regular-xs",children:"Set up a new project from scratch"})]}),U.map((function(e){var t,r,a=null!==(t=e.tenantId)&&void 0!==t?t:e.id;return(0,s.jsx)("button",{type:"button",disabled:!!V,onClick:function(){return function(e){L(e)}(e)},className:"flex h-[80px] min-w-0 flex-1 cursor-pointer flex-col items-center justify-center gap-[8px] overflow-hidden rounded-[6px] border-[1px] border-solid border-default bg-background-default px-[12px] py-[5px] shadow-sm transition-all duration-200 hover:gap-[12px] hover:bg-button-states-action-hover active:bg-button-states-action-pressed dark:border-neutral-700 dark:hover:bg-neutral-700",children:(0,s.jsx)(d.default,{className:"line-clamp-2 text-center text-header transition-all duration-200",variant:"medium-sm",children:null!==(r=e.name)&&void 0!==r?r:"Unnamed workspace"})},a)}))]})}),"loaded"===O&&0===U.length&&F.trim()&&(0,s.jsx)("div",{className:"flex w-full items-center justify-center py-12",children:(0,s.jsx)(d.default,{variant:"bold-xl",className:"text-default",children:"No workspaces match your search"})})]})})]}),(0,s.jsx)(N.V,{isOpen:"FREE_TO_JOIN"===(null===z||void 0===z?void 0:z.discoverable),onClose:A,workspace:z}),(0,s.jsx)(k.M,{isOpen:"NEEDS_ACCESS_REQUEST"===(null===z||void 0===z?void 0:z.discoverable),onClose:A,workspace:z}),(0,s.jsx)(y.Z,{isOpen:"NEEDS_CONTACT_IT"===(null===z||void 0===z?void 0:z.discoverable),onClose:A,onConfirm:A,variant:"confirm",header:"Access Restricted",title:" You can\u2019t join this workspace.",subtext:"Based on the account settings, access to this workspace is restricted. To join, you\u2019ll need to contact someone on the team directly.",loading:!!V,hideCloseButton:!0,confirmationButtonVariant:"default"})]})}},64796:function(e,t,r){"use strict";r.r(t),r.d(t,{default:function(){return l}});var a=r(52322),s=(r(2784),r(55545));function l(){return(0,a.jsx)(s.v,{})}}},function(e){e.O(0,[9774,2888,179],(function(){return t=87314,e(e.s=t);var t}));var t=e.O();_N_E=t}]);

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.