PageSourceSearch

https://sociallab.sa/chunk-3lA0ERbU.js

js sociallab.sa collected 2026-10-01 23:54:33 UTC 6,030 bytes, 1 lines download raw bytes

1import {E as En,D as De}from'./chunk-DFWdtebV.js';import'./chunk-DvLFd6NQ.js';import'./chunk-BGOHF1M9.js';import {c as ce}from'./chunk-BRsHFk4j.js';import'./chunk-C0DmzTpz.js';import {W,c3 as Xr,cN as Ft,E,D,V,bK as P,bI as Gt,aE as ut,v as vr,O,e as f,X as Xb,j as Xv,cY as OM,h as ea,T as Tt,N as Ng,z as zg,w as w0,H as H0,Z as Zx,k as dn,l as zw,s as sk,n as nd,r as rC,m as wC,o as mv,p as GC,t as tD,q as vD,aO as cD,aP as hD,b0 as _D,aW as pD,aX as mD,u as al,x as tM,y as dM,L as Lb,A as r1,P as P1,B as xS,C as Vs,F as zs,J as GS,K as iI,M as RI,Q as us,Y as UI,_ as tE,$ as Dn,a0 as ME,a1 as ny,a2 as go,a3 as Kd,a4 as XE,a5 as LT,a6 as mA,cx as WM,a7 as mt,a8 as fy,aa as Js,ac as H_,ae as pS,ad as gd,aB as ey,aC as DS,bi as D_,ai as dy,bn as nS,ag as SC,aj as jy,al as gS,cA as se,bZ as M,c4 as ED,cB as vt,a as G,an as x,cE as vd,cF as Ea,aT as d_,ak as Ed,bg as mS,aR as i_,ab as Ey,aS as Vp,aU as Hp}from'./main-4WA6AAHG.js';import'./chunk-CkU8oUfw.js';var ze=(()=>{class e extends se{constructor(t,i,n){super(t,i,n,"ConnectedApps/");}getConnectedApps(){return this.get("GetMyConnectors")}revoke(t){return this.delete("Revoke?grantId="+t)}static{this.\u0275fac=function(i){return new(i||e)(M(ED),M(vt),M(G))};}static{this.\u0275prov=x({token:e,factory:e.\u0275fac,providedIn:"root"});}}return e})();var Xe=()=>["Check the last-used date to spot anything you have forgotten about.","Revoke anything you do not recognise or no longer use."];function Ye(e,o){e&1&&(vd(0),Js(1,"p",4),H_(2),pS(3,"translate"),gd(),Ea()),e&2&&(SC(2),jy(gS(3,1,"No connected apps found")));}function Ze(e,o){if(e&1&&H_(0),e&2){let t=o.$implicit;Ed(" ",t.connectorName," ");}}function et(e,o){if(e&1&&(H_(0),pS(1,"date")),e&2){let t=o.$implicit;Ed(" ",mS(1,1,t.createdOn,"mediumDate")," ");}}function tt(e,o){if(e&1&&(Js(0,"span"),H_(1),pS(2,"date"),gd()),e&2){let t=d_().$implicit;SC(),Ed(" ",mS(2,1,t.lastUsedOn,"mediumDate")," ");}}function it(e,o){e&1&&(H_(0),pS(1,"translate")),e&2&&jy(gS(1,1,"Never"));}function ot(e,o){if(e&1&&ey(0,tt,3,4,"span",3)(1,it,2,3,"ng-template",null,1,DS),e&2){let t=o.$implicit,i=D_(2);dy("ngIf",t.lastUsedOn)("ngIfElse",i);}}function nt(e,o){if(e&1){let t=i_();Js(0,"button",10),Ey("click",function(){let n=Vp(t).$implicit,d=d_(2);return Hp(d.confirmRevoke(n))}),H_(1),pS(2,"translate"),gd();}e&2&&(SC(),Ed(" ",gS(2,1,"Revoke")," "));}function rt(e,o){if(e&1&&(Js(0,"app-responsive-table",5),ey(1,Ze,1,1,"ng-template",6)(2,et,2,4,"ng-template",7)(3,ot,3,2,"ng-template",8)(4,nt,3,3,"ng-template",9),gd()),e&2){let t=d_();dy("dataSource",t.connectedApps)("columns",t.columns)("loading",t.isLoading);}}var si=(()=>{class e{constructor(t,i,n,d,Ke,qe,Je){this.service=t,this.loadingService=i,this.errorService=n,this.toastr=d,this.dialog=Ke,this.translate=qe,this.dialogConfig=Je,this.sub=new W,this.connectedApps=[],this.isLoading=false,this.columns=[{key:"connectorName",label:"Connector",priority:1},{key:"createdOn",label:"Connected on",priority:2},{key:"lastUsedOn",label:"Last used",priority:2},{key:"actions",label:"",priority:1,hideLabel:true,stickyEnd:true}];}ngOnInit(){this.loadConnectedApps();}ngOnDestroy(){this.sub.unsubscribe();}loadConnectedApps(){this.isLoading=true,this.loadingService.beginSuppress(),this.sub.add(this.service.getConnectedApps().pipe(Xr(()=>{this.isLoading=false,this.loadingService.endSuppress();})).subscribe({next:t=>{t.succeeded?this.connectedApps=t.data??[]:this.errorService.setError(t,"Failed to load connected apps");},error:t=>{this.errorService.setError(t,"Error loading connected apps");}}));}confirmRevoke(t){this.dialog.open(Ft,E(D({},this.dialogConfig.getDefaultDialogConfig()),{width:"420px",data:{message:this.translate.instant("Are you sure you want to revoke this connection? The app will lose access immediately."),confirmText:this.translate.instant("Revoke"),cancelText:this.translate.instant("Cancel"),confirmColor:"warn"}})).afterClosed().subscribe(n=>{n&&this.revokeApp(t.grantId);});}revokeApp(t){this.loadingService.loadingOn(),this.sub.add(this.service.revoke(t).subscribe({next:i=>{this.loadingService.loadingOff(),i.succeeded?(this.toastr.success(this.translate.instant("Connector revoked successfully")),this.loadConnectedApps()):this.errorService.setError(i,"Failed to revoke connector");},error:i=>{this.loadingService.loadingOff(),this.errorService.setError(i,"Error revoking connector");}}));}static{this.\u0275fac=function(i){return new(i||e)(V(ze),V(P),V(Gt),V(ut),V(vr),V(O),V(f))};}static{this.\u0275cmp=Xb({type:e,selectors:[["app-connected-apps"]],decls:13,vars:10,consts:[["tableBlock",""],["neverTpl",""],["helpKey","connected-apps","intro","The AI assistants and external apps you have given access to your account.","warning","Revoking takes effect immediately \u2014 that app loses access to your account without warning.",3,"steps"],[4,"ngIf","ngIfElse"],[1,"text-muted","mt-3"],[3,"dataSource","columns","loading"],["rtColumnDef","connectorName"],["rtColumnDef","createdOn"],["rtColumnDef","lastUsedOn"],["rtColumnDef","actions"],["mat-stroked-button","","color","warn",3,"click"]],template:function(i,n){if(i&1&&(fy(0,"app-page-help",2),Js(1,"mat-card")(2,"mat-card-header")(3,"mat-card-title"),H_(4),pS(5,"translate"),gd(),Js(6,"mat-card-subtitle"),H_(7),pS(8,"translate"),gd()(),Js(9,"mat-card-content"),ey(10,Ye,4,3,"ng-container",3)(11,rt,5,3,"ng-template",null,0,DS),gd()()),i&2){let d=D_(12);dy("steps",nS(9,Xe)),SC(4),jy(gS(5,5,"Connected Apps")),SC(3),jy(gS(8,7,"Manage the AI assistants connected to your account")),SC(3),dy("ngIf",!n.isLoading&&n.connectedApps.length===0)("ngIfElse",d);}},dependencies:[ce,Xv,OM,ea,Tt,En,De,Ng,zg,w0,H0,Zx,dn,zw,sk,nd,rC,wC,mv,GC,tD,vD,cD,hD,_D,pD,mD,al,tM,dM,Lb,r1,P1,xS,Vs,zs,GS,iI,RI,us,UI,tE,Dn,ME,ny,go,Kd,XE,LT,mA,WM,mt],styles:["[_nghost-%COMP%]{display:block}mat-card[_ngcontent-%COMP%]{margin-bottom:1rem}.text-muted[_ngcontent-%COMP%]{color:var(--mat-sys-on-surface-variant, rgba(0, 0, 0, .54))}"],changeDetection:1});}}return e})();export{si as ConnectedAppsComponent};

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.