import{a as y,b as M,c as O}from"./chunk-RCEV3GYM.js";import{a as P,b as I}from"./chunk-TS62PHQY.js";import{C as A,j as x,p as h}from"./chunk-Z5RJRCWC.js";import{Ac as c,Ec as f,Gd as w,Na as v,Ob as p,Sb as b,Tb as u,dd as z,ec as d,fc as C,jc as _,lc as n,qc as l,rc as g,sc as o,ub as m,zb as i}from"./chunk-JSJB5BKT.js";import{e as S}from"./chunk-SZAW6ZBW.js";function V(a,s){if(a&1&&o(0,"ngx-avatars",1),a&2){let e=c();d("name",e.name)("size",e.avatarSize)}}function k(a,s){a&1&&o(0,"i",2)}function T(a,s){if(a&1&&(l(0,"span",3),o(1,"img",6),g()),a&2){let e=c();i(),f("src","data:image/png;base64,",e.imageBytes,"",m)}}function F(a,s){if(a&1&&o(0,"i",7),a&2){let e=c();_("repo-icon dvl-icon dvl-icon-",e.imageIcon.icon,""),d("ngStyle",z(4,B,e.imageIcon.color))}}function D(a,s){if(a&1&&(l(0,"div",5),o(1,"i",8)(2,"i",9),g()),a&2){let e=c();d("ngClass",e.size)}}var B,$,E=S(()=>{I();O();A();w();O();B=a=>({color:a});$=(()=>{class a extends P{constructor(){super(...arguments),this.isPam=!1,this.isPrivate=!1,this.avatarSize=28}get cssAvatarSize(){return`${this.avatarSize}px`}static{this.\u0275fac=(()=>{let e;return function(t){return(e||(e=v(a)))(t||a)}})()}static{this.\u0275cmp=p({type:a,selectors:[["dvls-vault-avatar"]],hostVars:2,hostBindings:function(r,t){r&2&&C("--avatar-size",t.cssAvatarSize)},inputs:{imageIcon:"imageIcon",imageBytes:"imageBytes",isPam:"isPam",isPrivate:"isPrivate",name:"name",avatarSize:"avatarSize",size:"size"},features:[b],decls:6,vars:5,consts:[[1,"avatar-container"],["textSizeRatio","2.25",3,"name","size"],[1,"repo-private-icon","di","dvl-icon-user-vault"],[1,"repo-custom-image-container"],[3,"class","ngStyle"],[1,"avatar-badge",3,"ngClass"],["alt","",1,"repo-custom-image",3,"src"],[3,"ngStyle"],[1,"avatar-badge-icon","avatar-badge-border","dvl-icon","dvl-icon-pam"],[1,"avatar-badge-icon","dvl-icon","dvl-icon-pam"]],template:function(r,t){r&1&&(l(0,"div",0),u(1,V,1,2,"ngx-avatars",1)(2,k,1,0,"i",2)(3,T,2,2,"span",3)(4,F,1,6,"i",4)(5,D,3,1,"div",5),g()),r&2&&(i(),n(!t.isPrivate&&!t.imageBytes&&!t.imageIcon?1:-1),i(),n(t.isPrivate?2:-1),i(),n(t.imageBytes?3:-1),i(),n(t.imageIcon?4:-1),i(),n(t.isPam?5:-1))},dependencies:[M,y,h,x],styles:['[_nghost-%COMP%]{--badge-icon-size: 16px;--badge-border-width: 4px}.tiny[_ngcontent-%COMP%]{--badge-icon-size: 10px;--badge-border-width: 3px}.small[_ngcontent-%COMP%]{--badge-icon-size: 15px}.medium[_ngcontent-%COMP%]{--badge-icon-size: 16px}.repo-custom-image-container[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;width:var(--avatar-size, 28px);height:var(--avatar-size, 28px)}.repo-custom-image[_ngcontent-%COMP%]{max-width:var(--avatar-size, 28px);max-height:var(--avatar-size, 28px)}.repo-icon[_ngcontent-%COMP%]{font-size:var(--avatar-size, 28px)}.avatar-container[_ngcontent-%COMP%]{position:relative;display:inline-block}.avatar-badge-icon[_ngcontent-%COMP%]{font-size:var(--badge-icon-size)}.avatar-badge[_ngcontent-%COMP%]{position:absolute;bottom:calc(var(--badge-border-width) * -1);right:calc(var(--badge-border-width) * -1);color:rgb(var(--base-color-rgb))}.avatar-badge[_ngcontent-%COMP%], .avatar-badge-icon[_ngcontent-%COMP%]{width:var(--badge-icon-size);height:var(--badge-icon-size)}.avatar-badge-icon[_ngcontent-%COMP%]:not(.avatar-badge-border){width:calc(var(--badge-icon-size) - var(--badge-border-width));height:calc(var(--badge-icon-size) - var(--badge-border-width));font-size:calc(var(--badge-icon-size) - var(--badge-border-width))}.avatar-badge-icon[_ngcontent-%COMP%]{transform:translate(-50%,-50%);font-size:var(--badge-icon-size);position:absolute;top:50%;left:50%}.avatar-badge-border[_ngcontent-%COMP%]{color:var(--side-panel-background-color)}.avatar-badge-border.dvl-icon-role-owner[_ngcontent-%COMP%], .avatar-badge-border.dvl-icon-role-admin[_ngcontent-%COMP%]{text-shadow:0 -2px 0 var(--side-panel-background-color),0 -1px var(--side-panel-background-color)}.avatar-badge-border.dvl-icon-pam[_ngcontent-%COMP%]:after{width:calc(var(--badge-icon-size) - 5px);height:calc(var(--badge-icon-size) - 5px);position:absolute;inset:0;margin:auto;background-color:var(--side-panel-background-color);border-radius:50%;content:""}']})}}return a})()});export{$ as a,E as b};
