PageSourceSearch

https://app.provision.ai/build/assets/slack-config-i5s5m3CZ.js

js provision.ai collected 2026-10-05 12:27:40 UTC 6,310 bytes, 1 lines download raw bytes

1import{c as G,j as t,a as K,H as O,F as V,r as Y}from"./app-DFk7rXTX.js";import{H}from"./heading-CE3yNnG8.js";import{I as L}from"./input-error-B0QNzd-A.js";import{B as J}from"./badge-CNfS7BNq.js";import{B}from"./button-CQLXGyU6.js";import{I as M}from"./input-Dq6PrjqK.js";import{L as q}from"./label-DT6ICE19.js";import{S as P}from"./separator-D25KJWZJ.js";import{A as Q}from"./app-layout-zLG0UwvW.js";import{S as U}from"./layout-CNw-S7hX.js";import{K as W}from"./transition-DsLsFISS.js";import{E as X,a as Z}from"./eye-CNjbW-jS.js";/* empty css            */import"./utils-DvRnx1Xn.js";import"./index-cLxkZZDq.js";import"./app-sidebar-header-BTrGLaID.js";import"./createLucideIcon-EgD1M5_7.js";import"./index-CGhkv8ZN.js";import"./index-C3R0egQb.js";import"./index-0Z-OyOqy.js";import"./index-DR20jdGE.js";import"./log-out-D0RMhzAl.js";import"./x-Dbu6HxN4.js";import"./bot-lGxW-pz8.js";import"./app-logo-icon-CFKLm3eu.js";import"./index-1a_5_4ah.js";function z(R){const e=G.c(16),{id:n,name:r,placeholder:x,required:c}=R,[l,d]=Y.useState(!1),p=l?"text":"password";let m;e[0]!==n||e[1]!==r||e[2]!==x||e[3]!==c||e[4]!==p?(m=t.jsx(M,{id:n,name:r,type:p,required:c,placeholder:x,className:"pr-10"}),e[0]=n,e[1]=r,e[2]=x,e[3]=c,e[4]=p,e[5]=m):m=e[5];let o;e[6]!==l?(o=()=>d(!l),e[6]=l,e[7]=o):o=e[7];let a;e[8]!==l?(a=l?t.jsx(X,{className:"size-4"}):t.jsx(Z,{className:"size-4"}),e[8]=l,e[9]=a):a=e[9];let s;e[10]!==o||e[11]!==a?(s=t.jsx("button",{type:"button",onClick:o,className:"absolute top-1/2 right-3 -translate-y-1/2 text-muted-foreground hover:text-foreground",tabIndex:-1,children:a}),e[10]=o,e[11]=a,e[12]=s):s=e[12];let i;return e[13]!==m||e[14]!==s?(i=t.jsxs("div",{className:"relative",children:[m,s]}),e[13]=m,e[14]=s,e[15]=i):i=e[15],i}function Te(R){const e=G.c(49),{team:n,configToken:r}=R,x=`/settings/teams/${n.id}`;let c;e[0]!==x?(c={title:"Team settings",href:x},e[0]=x,e[1]=c):c=e[1];const l=`/settings/teams/${n.id}/slack-config`;let d;e[2]!==l?(d={title:"Slack",href:l},e[2]=l,e[3]=d):d=e[3];let p;e[4]!==c||e[5]!==d?(p=[c,d],e[4]=c,e[5]=d,e[6]=p):p=e[6];const m=p;let o,a,s,i,u,f,h,j;if(e[7]!==m||e[8]!==r||e[9]!==n.id){const N=r?.expires_at?new Date(r.expires_at):null,b=N?N<new Date:!1;a=Q,j=m,e[18]===Symbol.for("react.memo_cache_sentinel")?(s=t.jsx(O,{title:"Slack Configuration"}),i=t.jsx("h1",{className:"sr-only",children:"Slack Configuration"}),e[18]=s,e[19]=i):(s=e[18],i=e[19]),o=U,u="space-y-6",e[20]===Symbol.for("react.memo_cache_sentinel")?(f=t.jsx(H,{variant:"small",title:"Slack Configuration Token",description:"Connect your Slack workspace to enable automated Slack app creation for agents."}),e[20]=f):f=e[20],h=r?t.jsxs("div",{className:"space-y-4",children:[t.jsxs("div",{className:"flex items-center gap-3",children:[t.jsx("span",{className:"text-sm font-medium",children:"Status:"}),t.jsx(J,{variant:b?"destructive":"default",children:b?"Expired":"Active"}),N&&!b&&t.jsxs("span",{className:"text-sm text-muted-foreground",children:["Expires ",N.toLocaleString()]})]}),t.jsx("div",{className:"flex gap-2",children:t.jsx(B,{variant:"destructive",size:"sm",onClick:()=>K.delete(`/settings/teams/${n.id}/slack-config`,{preserveScroll:!0}),children:"Remove Token"})})]}):null,e[7]=m,e[8]=r,e[9]=n.id,e[10]=o,e[11]=a,e[12]=s,e[13]=i,e[14]=u,e[15]=f,e[16]=h,e[17]=j}else o=e[10],a=e[11],s=e[12],i=e[13],u=e[14],f=e[15],h=e[16],j=e[17];let k;e[21]!==u||e[22]!==f||e[23]!==h?(k=t.jsxs("div",{className:u,children:[f,h]}),e[21]=u,e[22]=f,e[23]=h,e[24]=k):k=e[24];let T;e[25]===Symbol.for("react.memo_cache_sentinel")?(T=t.jsx(P,{}),e[25]=T):T=e[25];const F=r?"Replace Configuration Token":"Add Configuration Token";let g;e[26]!==F?(g=t.jsx(H,{variant:"small",title:F,description:"Generate a Configuration Token from your Slack workspace settings."}),e[26]=F,e[27]=g):g=e[27];let C;e[28]===Symbol.for("react.memo_cache_sentinel")?(C=t.jsx("p",{className:"font-medium",children:"How to get your tokens:"}),e[28]=C):C=e[28];let w;e[29]===Symbol.for("react.memo_cache_sentinel")?(w=t.jsxs("div",{className:"space-y-2 rounded-md bg-muted p-4 text-sm",children:[C,t.jsxs("ol",{className:"list-inside list-decimal space-y-1 text-muted-foreground",children:[t.jsxs("li",{children:["Go to"," ",t.jsx("a",{href:"https://api.slack.com/apps",target:"_blank",rel:"noopener noreferrer",className:"text-foreground underline",children:"api.slack.com/apps"})]}),t.jsx("li",{children:'Scroll down to "Your App Configuration Tokens"'}),t.jsx("li",{children:'Click "Generate Token" and select your workspace'}),t.jsx("li",{children:"Copy the Access Token and Refresh Token below"})]})]}),e[29]=w):w=e[29];const I=`/settings/teams/${n.id}/slack-config`;let E;e[30]===Symbol.for("react.memo_cache_sentinel")?(E={preserveScroll:!0},e[30]=E):E=e[30];let y;e[31]!==r?(y=N=>{const{processing:b,recentlySuccessful:D,errors:$}=N;return t.jsxs(t.Fragment,{children:[t.jsxs("div",{className:"grid gap-2",children:[t.jsx(q,{htmlFor:"access_token",children:"Access Token (xoxe.xoxp-...)"}),t.jsx(z,{id:"access_token",name:"access_token",required:!0,placeholder:"xoxe.xoxp-..."}),t.jsx(L,{className:"mt-2",message:$.access_token})]}),t.jsxs("div",{className:"grid gap-2",children:[t.jsx(q,{htmlFor:"refresh_token",children:"Refresh Token (xoxe-...)"}),t.jsx(z,{id:"refresh_token",name:"refresh_token",required:!0,placeholder:"xoxe-..."}),t.jsx(L,{className:"mt-2",message:$.refresh_token})]}),t.jsxs("div",{className:"flex items-center gap-4",children:[t.jsx(B,{disabled:b,children:r?"Replace Token":"Save Token"}),t.jsx(W,{show:D,enter:"transition ease-in-out",enterFrom:"opacity-0",leave:"transition ease-in-out",leaveTo:"opacity-0",children:t.jsx("p",{className:"text-sm text-neutral-600",children:"Saved"})})]})]})},e[31]=r,e[32]=y):y=e[32];let v;e[33]!==I||e[34]!==y?(v=t.jsx(V,{action:I,method:"post",options:E,className:"space-y-6",children:y}),e[33]=I,e[34]=y,e[35]=v):v=e[35];let S;e[36]!==g||e[37]!==v?(S=t.jsxs("div",{className:"space-y-6",children:[g,w,v]}),e[36]=g,e[37]=v,e[38]=S):S=e[38];let _;e[39]!==o||e[40]!==k||e[41]!==S?(_=t.jsxs(o,{children:[k,T,S]}
1),e[39]=o,e[40]=k,e[41]=S,e[42]=_):_=e[42];let A;return e[43]!==a||e[44]!==s||e[45]!==i||e[46]!==_||e[47]!==j?(A=t.jsxs(a,{breadcrumbs:j,children:[s,i,_]}),e[43]=a,e[44]=s,e[45]=i,e[46]=_,e[47]=j,e[48]=A):A=e[48],A}export{Te as default};

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.