import{j as s,l as t,g as d,T as o,cz as x,cA as m}from"./main-TIUJvpaR.js";import{u as j}from"./use-all-social-logins-disabled-BoQ09ZS1.js";import{P as p,D as g,A as u,a as h}from"./PhonelinkLock-EPEqltvl.js";import{L as v}from"./Lock-vDW_pDIt.js";import{L}from"./Login-8NOP77J2.js";import{L as f,a as b}from"./list-DlNGU0yW.js";function S({id:e,title:a,titleSuffix:l,children:c,actions:i}){return s.jsxs("section",{id:e,className:"mb-24 w-full rounded-panel border border-divider-lighter bg-elevated px-24 py-20 shadow",children:[s.jsxs("div",{className:"flex items-center gap-14 border-b pb-10",children:[s.jsx("div",{className:"text-lg font-light",children:a}),l&&s.jsx("div",{className:"ml-auto",children:l})]}),s.jsx("div",{className:"pt-24",children:c}),i&&s.jsx("div",{className:"mt-36 flex justify-end border-t pt-10",children:i})]})}var r=(e=>(e.AccountDetails="account-details",e.SocialLogin="social-login",e.Password="password",e.TwoFactor="two-factor",e.LocationAndLanguage="location-and-language",e.Developers="developers",e.DeleteAccount="delete-account",e.Sessions="sessions",e))(r||{});function I({items:e}){const a=r,{hasPermission:l}=t(),{api:c}=d(),i=j();return s.jsx("aside",{className:"sticky top-[74px] hidden flex-shrink-0 lg:block",children:s.jsxs(f,{padding:"p-0",children:[e,s.jsx(n,{icon:s.jsx(x,{}),panel:a.AccountDetails,children:s.jsx(o,{message:"Account details"})}),!i&&s.jsx(n,{icon:s.jsx(L,{}),panel:a.SocialLogin,children:s.jsx(o,{message:"Social login"})}),s.jsx(n,{icon:s.jsx(v,{}),panel:a.Password,children:s.jsx(o,{message:"Password"})}),s.jsx(n,{icon:s.jsx(p,{}),panel:a.TwoFactor,children:s.jsx(o,{message:"Two factor authentication"})}),s.jsx(n,{icon:s.jsx(g,{}),panel:a.Sessions,children:s.jsx(o,{message:"Active sessions"})}),s.jsx(n,{icon:s.jsx(m,{}),panel:a.LocationAndLanguage,children:s.jsx(o,{message:"Location and language"})}),c!=null&&c.integrated&&l("api.access")?s.jsx(n,{icon:s.jsx(u,{}),panel:a.Developers,children:s.jsx(o,{message:"Developers"})}):null,s.jsx(n,{icon:s.jsx(h,{}),panel:a.DeleteAccount,children:s.jsx(o,{message:"Delete account"})})]})})}function n({children:e,icon:a,isLast:l,panel:c}){return s.jsx(b,{startIcon:a,className:l?void 0:"mb-10",onSelected:()=>{const i=document.querySelector(`#${c}`);i&&i.scrollIntoView({behavior:"smooth",block:"start"})},children:e})}export{S as A,r as a,I as b};
