PageSourceSearch

https://app.fyxer.com/assets/SkillsPage-6dhKQNsC.js

js fyxer.com collected 2026-09-25 20:20:39 UTC 15,055 bytes, 1 lines download raw bytes

1import{j as e,r as f,u as ue,d as me,N as pe}from"./vendor-react-C5PewRsl.js";import{cD as ge,fm as he,cA as fe,h as xe,i as w,a8 as be,ek as ke,e as G,fL as Se,bN as ye,bO as we,ag as je,aC as ve,co as Ce,dL as C,Q as Le,fn as Ae,fo as Ee,fp as Ne}from"./main-DoxpiNgY.js";import{b as Fe}from"./vendor-misc-DVk-0spb.js";import{T as Te}from"./ThreadTabs-DREMGMtC.js";import{p as Ie}from"./parseApiError-DF1jzER4.js";import{u as J,S as L}from"./SeatLocked-DufWglWu.js";import{a as Z}from"./ThreadToggle-1fTfD7kJ.js";import{u as ee,g as ae,S as R,a as De,b as Oe,c as Pe,d as se,t as Me,e as _e,f as Re,h as ze,i as Be,j as qe,k as te,l as Ke,m as Qe,r as He,n as Ye,o as Ge}from"./useSkillApplicationDialog-CIgk3MhW.js";import{s as Ue,a as Ve,b as We,c as $e,d as Xe}from"./slide5-DG_I8aFi.js";import{A as Je,c as Ze,d as ea,a as aa,b as sa,e as ta}from"./AnnouncementDialog-CPuMUj7M.js";import{u as ia,A as U,m as V}from"./vendor-ui-BKWhI8D_.js";import{u as na,a as oa}from"./useMessagingAccountLinks-COG_v6U9.js";import{u as ra}from"./useIntegrationVisibility-CttzqPf2.js";import{t as la}from"./SpaceTriggerControls-Dya5b0MU.js";import"./vendor-runtime-DG-GlVKR.js";import"./index-FFROJYLR.js";import"./vendor-icons-Nh3lIdcn.js";import"./vendor-analytics-aNB2-Vwh.js";import"./vendor-sentry-SKD9L_Jy.js";import"./ChatMessageContent-7H3lhDYB.js";import"./documents-BdJCmYft.js";import"./useHasDocumentAccess-CczcC0ux.js";import"./utils-C2A-qYlQ.js";import"./useEmailInboxes-C0IYBzpX.js";import"./mermaid-3ZIDBTTL-BQtYO9pL.js";import"./index-DirJCEvl.js";import"./marked.esm-arQYK1KV.js";import"./ChatToolUsage-CVgoZGld.js";/* empty css               */import"./DashboardChatThreadPanel-CeiCU8qd.js";import"./ChatInput-B-RDd5XN.js";import"./useDebounce-D59gqLuZ.js";import"./index-C3qxNN0c.js";import"./index-BHJ2L8hx.js";import"./index-BoCVrkPy.js";import"./index-CEXy5VPo.js";import"./useChatThreadModeSelection-BhNrKs-i.js";import"./DashboardChatMessages-D7DljgCh.js";import"./getBrowserTimezone-s91SEF56.js";import"./index-Dv1bGROt.js";import"./index-CMGZUsy1.js";import"./PendingFlowQuestionnairePanel-Bd4MNs_t.js";import"./ThreadRadio-uN-gwsux.js";import"./LabelledIconButton-KDjPwz0k.js";import"./microsoft-teams-CQX1KCK3.js";import"./slack-DLuqsmBw.js";import"./google-meet-DZ2kLENO.js";import"./zoom-Dt5C6eOs.js";import"./friendlyLabelName-PYQei73U.js";import"./useLabels-CQVM_iAx.js";import"./labelPresentationalData-LCwAkoKF.js";import"./resolveForMembership-vlUJe36m.js";import"./useAccessibleSpaces-Bna_bKTv.js";import"./queryKeys-Bioab_aL.js";import"./ThreadSelect-DFZ9JAxs.js";import"./ThreadTagInput-BiQGgDJK.js";import"./ThreadCombobox-BddXDWKk.js";import"./integrationSettingKey-wfe_NT02.js";try{let s=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new s.Error().stack;t&&(s._sentryDebugIds=s._sentryDebugIds||{},s._sentryDebugIds[t]="0ca75c1e-a595-4661-8737-3cadb6f1d697",s._sentryDebugIdIdentifier="sentry-dbid-0ca75c1e-a595-4661-8737-3cadb6f1d697")}catch{}const ca=({organisationId:s,skill:t,onClick:i})=>{const{application:n}=t,{isSeatLocked:d}=J("flows"),p=ee(s),a=ae(n);return e.jsx(R,{skill:t,onClick:i,dimmed:!a.isEnabled,action:e.jsxs("div",{className:"flex items-center gap-2.5",children:[a.statusLabel&&e.jsx("label",{className:"text-[12px] leading-[1.6] font-medium whitespace-nowrap text-rb-secondary-dark",children:a.statusLabel}),e.jsx(L,{feature:"flows",side:"left",children:e.jsx(Z,{"aria-label":a.toggleLabel,checked:a.isEnabled,onChange:g=>p.mutate({skillId:t.id,enabled:g}),disabled:!a.canToggle,tooltip:d?void 0:a.toggleLabel})})]})})},da="Your organization has this Flow's delivery channel turned off",ua=({organisationId:s,skill:t,appliedSkill:i,setupNeed:n,onOpenDetails:d})=>{const{isSeatLocked:p}=J("flows"),a=De(s),g=ee(s),o=i&&ae(i.application),b=!!(o!=null&&o.isEnabled),h=n==="unavailable"?da:(o==null?void 0:o.toggleLabel)??"Activate Flow",u=x=>{if(i&&(!x||!n)){g.mutate({skillId:i.id,enabled:x});return}if(x){if(n){d();return}a.mutate(t)}};return e.jsx(R,{skill:t,onClick:d,action:e.jsx(L,{feature:"flows",side:"left",children:e.jsx(Z,{"aria-label":h,checked:b,onChange:u,disabled:n==="pending"||n==="unavailable"&&!b||a.isPending||!!o&&!o.c
1anToggle,tooltip:p?void 0:h})})})},T=[{img:Ue,title:"Welcome to Flows",description:"Flows are pre-built automations that convert your busiest workflows into background tasks. Connect your tools, and Fyxer handles the rest."},{img:Ve,title:"Manage your Flows",description:"The “My Flows” tab keeps everything you've switched on in one place. Adjust how each one works, or check what it's been doing."},{img:We,title:"Activate a Flow",description:"Open any Flow and hit Activate. Thereafter your Flow runs quietly in the background, every time, without any nudging."},{img:$e,title:"Browse Flows",description:"Click on the “Discover” tab to explore the full library, from meetings to email to scheduling, built by Fyxer and the community."},{img:Xe,title:"Pause anytime",description:"Changed your mind? Pause a Flow with one click and switch it back on whenever you need to. You're always in control."}],W=50,ma=({open:s,onClose:t,onCreateSkill:i})=>{const[n,d]=f.useState(0),p=ia();f.useEffect(()=>{s&&d(0)},[s]);const a=n===T.length-1,g=T[n],o=l=>d(Math.min(Math.max(l,0),T.length-1)),b=()=>{a?i():o(n+1)},h=l=>{var m;l.preventDefault(),(m=document.getElementById("skills-onboarding-primary-action"))==null||m.focus()},u=l=>{l||t()},x=l=>{l.key==="ArrowRight"&&o(n+1),l.key==="ArrowLeft"&&o(n-1)};return e.jsx(ge,{open:s,onOpenChange:u,children:e.jsxs(Je,{className:"max-w-[600px]",onKeyDown:x,onOpenAutoFocus:h,children:[e.jsxs(Ze,{className:"aspect-600/320 h-auto border-b border-rb-gray-neutral bg-rb-parchment",children:[e.jsx(U,{mode:"wait",initial:!1,children:e.jsx(V.div,{className:"absolute inset-0",initial:{opacity:0}
1,animate:{opacity:1},exit:{opacity:0},transition:{duration:p?0:.15},drag:"x",dragConstraints:{left:0,right:0},dragElastic:.15,onDragEnd:(l,m)=>{m.offset.x<-W?o(n+1):m.offset.x>W&&o(n-1)},children:e.jsx("img",{src:g.img,alt:"",draggable:!1,className:"pointer-events-none size-full object-cover select-none"})},n)}),e.jsx(he,{asChild:!0,className:"absolute top-3 right-3",children:e.jsx(fe,{icon:"X",label:"Close",size:"md"})})]}),e.jsx(ea,{className:"min-h-[140px]",children:e.jsx(U,{mode:"wait",initial:!1,children:e.jsxs(V.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:p?0:.15},className:"flex flex-col gap-3",children:[e.jsx(aa,{children:g.title}),e.jsx(sa,{children:g.description})]},n)})}),e.jsxs(ta,{className:"relative justify-end border-t border-rb-gray-neutral",children:[e.jsx("div",{className:"absolute left-1/2 flex -translate-x-1/2 items-center gap-2",children:T.map((l,m)=>e.jsx("button",{type:"button","aria-label":`Step ${m+1}`,onClick:()=>o(m),className:xe("h-2 w-2 rounded-full bg-rb-gray-neutral transition-all",{"w-8 bg-rb-orange-neutral":m===n})},m))}),a?e.jsx(L,{feature:"flows",children:e.jsx(w,{id:"skills-onboarding-primary-action",variant:"primary",size:"lg",label:"Create a Flow",onClick:b})}):e.jsx(w,{id:"skills-onboarding-primary-action",variant:"primary",size:"lg",label:"Next",icon:"ArrowRight",iconDir:"right",onClick:b})]})]})})},pa=(s,t)=>ke({arr:[...s,...t],getKey:i=>i.id}),ga=()=>{const{organisationId:s}=be(),t=Oe(s),i=Pe(s),{hasNextPage:n,isFetchingNextPage:d,fetchNextPage:p}=i;f.useEffect(()=>{n&&!d&&p()},[n,d,p]);const a=f.useMemo(()=>t.data??[],[t.data]),g=f.useMemo(()=>{var h;return((h=i.data)==null?void 0:h.pages.flatMap(u=>u.items))??[]},[i.data]),o=f.useMemo(()=>pa(g,a),[g,a]),b=t.isLoading||i.isLoading;return{organisationId:s,isLoading:b,hasAppliedSkillsError:i.isError,hasAvailableSkillsError:t.isError,allSkills:o,appliedSkills:g,availableSkills:a}},ha=()=>{const{accountLinks:s,isLoading:t}=na({enabled:!0}),{accountLink:i,isLoading:n}=oa(),d=se(),{isIntegrationVisible:p,isIntegrationEnabled:a,isTeamsVisible:g,isTeamsEnabled:o,isLoading:b}=ra(),h={slack:s.length>0,teams:i!==null},u={slack:d.slack&&p(G.SLACK)&&a(G.SLACK),teams:d.teams&&g&&o},x={slack:t,teams:n};return l=>{if(la(l)||Me(l)||_e(l))return"configuration";const m=Re(l);if(!(m!=="slack"&&m!=="teams")){if(b||x[m])return"pending";if(!h[m])return u[m]?m:"unavailable"}}},fa=[{label:"Discover",value:"discover"},{label:"My Flows",value:"mine"},{label:"Your team's Flows",value:"shared"}],xa=({value:s,onChange:t})=>e.jsxs(Ae,{className:"w-full sm:w-64",children:[e.jsx(Ee,{value:s,onChange:i=>t(i.target.value),placeholder:"Search your Flows","aria-label":"Search your Flows"}),s&&e.jsx(Ne,{onClear:()=>t("")})]}),A="min-h-[540px]",ba=()=>e.jsx(C,{variant:"panel",className:A,size:"lg",icon:"Sparkle",title:"No Flows to discover yet",description:"Fyxer publishes Flows here as they are released. Until then, describe your own to get started."}),$=32,ka=s=>s.length>$?`${s.slice(0,$)}…`:s,ie=({query:s,onClearSearch:t})=>e.jsx(C,{variant:"panel",className:A,size:"lg",icon:"MagnifyingGlass",title:`No Flows match “${ka(s)}”`,description:"Try another search, or clear it to see everything.",actions:e.jsx(w,{variant:"outline",size:"md",label:"Clear search",onClick:t})}),ne=({children:s})=>e.jsx("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2 2xl:grid-cols-3",children:s}),oe=()=>e.jsx(C,{variant:"panel",className:A,size:"lg",icon:"Warning",title:"Your Flows couldn't be loaded",description:"Refresh the page and try again."}),_=(s,t)=>t?s.filter(i=>i.name.toLowerCase().includes(t)||i.description.toLowerCase().includes(t)):s,Sa=({organisationId:s,officialQuery:t,searchQuery:i,findAppliedSkill:n,onSelect:d,onClearSearch:p})=>{const a=se(),g=ha();if(t.isLoading)return e.jsx(te,{});if(t.isError)return e.jsx(oe,{});const o=i.toLowerCase(),b=(t.data??[]).filter(u=>!He(u,a)),h=Ye.map(u=>({category:u,skills:_(b.filter(x=>x.category===u),o)})).filter(u=>u.skills.length>0);return h.length===0?i?e.jsx(ie,{query:i,onClearSearch:p}):e.jsx(ba,{}):e.jsx("div",{className:"flex flex-col gap-8",children:h.map(({category:u,skills:x})=>e.jsxs("div",{className:"flex flex-col gap-4",children:[e.jsx("p",{className:"text-[14px] leading-[1.6] font-medium text-rb-secondary-dark",children:Ge[u]}
1),e.jsx(ne,{children:x.map(l=>e.jsx(ua,{organisationId:s,skill:l,appliedSkill:n(l),setupNeed:g(l.triggers),onOpenDetails:()=>d(l)},l.id))})]},u))})},X=({hasError:s,searchQuery:t,filteredSkills:i,renderCard:n,emptyState:d,onClearSearch:p})=>s?e.jsx(oe,{}):i.length>0?e.jsx(ne,{children:i.map(n)}):t?e.jsx(ie,{query:t,onClearSearch:p}):e.jsx(e.Fragment,{children:d}),Cs=()=>{const{organisationId:s}=ue(),t=Se(),[i,n]=me();ye(we.SKILLS);const d=je(),p=Fe(),a=ga(),g=ze(a.organisationId),o=Be(a.organisationId),[b,h]=f.useState(!1),[u,x]=f.useState(!1),[l,m]=f.useState(!1),z=()=>{u||h(!0)},k=qe(a.organisationId),B=i.get("q")??"",S=i.get("id"),j=i.get("createSkill"),q=i.get("create")==="true",E=i.get("tab"),re=a.isLoading||a.appliedSkills.length>0?"mine":"discover",I=E==="shared"?"shared":E==="discover"||E==="library"?"discover":E==="mine"?"mine":re,N=B.trim(),F=N.toLowerCase(),le=f.useMemo(()=>_(a.appliedSkills,F),[a.appliedSkills,F]),ce=f.useMemo(()=>_(a.availableSkills,F),[a.availableSkills,F]),K=f.useRef(!1);f.useEffect(()=>{!q||K.current||(K.current=!0,n(r=>(r.delete("create"),r),{replace:!0}),h(!0))},[q,n]);const D=f.useRef(null);f.useEffect(()=>{var y;if(!S||a.isLoading||D.current===S)return;const r=a.allSkills.find(v=>v.id===S);if(r){D.current=S,k.open(r);return}const c=(y=o.data)==null?void 0:y.find(v=>v.id===S);c&&(D.current=S,k.open(c,"template"))},[S,a.isLoading,a.allSkills,o.data,k]);const Q=f.useRef(null);f.useEffect(()=>{if(!j||Q.current===j)return;Q.current=j,n(c=>(c.delete("createSkill"),c),{replace:!0}),(async()=>{x(!0);try{const c=await d.organisations.id(a.organisationId).skills.create({token:j});if(!("skillId"in c))throw new Error("Unexpected create skill response");const{skillId:y}=c,v=await p.fetchQuery({queryKey:Qe(a.organisationId,y),queryFn:()=>d.organisations.id(a.organisationId).skills.id(y).get(),staleTime:6e4});g();const M=a.appliedSkills.find(de=>de.id===y);k.open({...v,application:(M==null?void 0:M.application)??{enabled:!1,appliedAt:new Date,recentRuns:[]}},"manage")}catch(c){Le.error({title:"Couldn't create Flow",description:Ie(c)})}finally{x(!1)}})()},[j,d,a.organisationId,a.appliedSkills,p,k,g,n]);const H=r=>{n(c=>(r?c.set("q",r):c.delete("q"),c),{replace:!0})},O=()=>H(""),Y=r=>a.appliedSkills.find(c=>c.id===r.id||c.sourceSkillId===r.id),P=r=>{n(c=>(c.set("tab",r),c),{replace:!0})};return t===!1?e.jsx(pe,{to:`/org/${s}/dashboard`,replace:!0}):e.jsxs("div",{className:"flex min-h-full min-w-0 flex-col bg-rb-canvas",children:[e.jsxs(ve,{children:[e.jsxs("div",{className:"flex flex-col gap-4 sm:flex-row sm:items-start sm:justify-between sm:gap-6",children:[e.jsxs("div",{className:"flex min-w-0 flex-col gap-1.5",children:[e.jsx(Ce,{title:"Automate workflows"}),e.jsxs("p",{className:"text-[15px] leading-[1.6] font-normal text-rb-secondary-dark",children:["Get more done in the background with Flows."," ",e.jsx("button",{type:"button",onClick:()=>m(!0),className:"font-medium whitespace-nowrap text-rb-darkbtn underline underline-offset-[3px]",children:"Learn more"})]})]}),e.jsxs("div",{className:"flex flex-col gap-2 sm:flex-row sm:items-center",children:[e.jsx(xa,{value:B,onChange:H}),e.jsx(L,{feature:"flows",children:e.jsx(w,{variant:"primary",size:"md",label:u?"Creating Flow...":"Create Flow",icon:"Plus",onClick:z,disabled:u})})]})]}),e.jsxs("div",{className:"flex flex-col gap-8",children:[e.jsx(Te,{ariaLabel:"Flows view",options:fa,value:I,onChange:P,className:"overflow-x-auto"}),a.isLoading?e.jsx(te,{}):I==="discover"?e.jsx(Sa,{organisationId:a.organisationId,officialQuery:o,findAppliedSkill:Y,searchQuery:N,onClearSearch:O,onSelect:r=>{const c=Y(r);c?k.open(c):k.open(r,"template")}}):I==="mine"?e.jsx(X,{hasError:a.hasAppliedSkillsError,searchQuery:N,filteredSkills:le,onClearSearch:O,renderCard:r=>e.jsx(ca,{organisationId:a.organisationId,skill:r,onClick:()=>k.open(r)},r.id),emptyState:e.jsx(C,{variant:"panel",className:A,size:"lg",icon:"Sparkle",title:"No Flows yet",description:"Start from a ready-made Flow, or describe your own.",actions:e.jsxs(e.Fragment,{children:[e.jsx(L,{feature:"flows",children:e.jsx(w,{variant:"primary",size:"md",label:"Create a Flow",icon:"Plus",onClick:z})}),e.jsx(w,{variant:"outline",size:"md",label:"Explore all Flows",onClick:()=>P("discover")})]})})}):e.jsx(X,{hasError:a.hasAvailableSkillsError,searchQuery:N,filteredSkills:ce,onClearSearch:O,renderCard:r=>e.jsx(R,{skill:r,onClick:()=>k.open(r)},r.id),emptyState:e.jsx(C,{variant:"panel",className:A,size:"lg",icon:"Users",title:"Nothing shared with you yet",description:"When a teammate shares a Flow with your organization, it will show up here."})})]})]}
1),k.dialog,e.jsx(Ke,{open:b,onOpenChange:h,onExploreLibrary:()=>P("discover")}),e.jsx(ma,{open:l,onClose:()=>m(!1),onCreateSkill:()=>{m(!1),h(!0)}})]})};export{Cs as SkillsPage};

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.