import{e as D,g as F}from"./vendor-react-DX7tU9aY.js";import{e as L}from"./vendor-arcblock-BVQTtbN-.js";var s={exports:{}};const N=D(L);var l;function R(){if(l)return s.exports;l=1;const{getNftBGColor:g,DEFAULT_COLORS:u,getNftBGColorFromDid:v,getSvg:f}=N,n=(e,r)=>{let t;return e==="default"?t=u["app-passport"]:e==="auto"?t=v(r):t=g(e),t},m=e=>{const r=parseInt(e.slice(1,3),16),t=parseInt(e.slice(3,5),16),o=parseInt(e.slice(5,7),16);return(.299*r+.587*t+.114*o)/255>.5?"#111":"#EEE"},x=({issuer:e="",title:r="",issuerDid:t="",issuerAvatarUrl:o="",ownerDid:p="",ownerName:C="",ownerAvatarUrl:P="",preferredColor:S="default",revoked:c=!1,isDataUrl:E=!1,width:d="100%",height:$="100%",extra:I=null,scope:a="passport",role:q=""})=>{const y=n(S,t),i=f({width:d,height:$,tag:c?"revoked":"",tagVariant:c?"error":"info",color:y,did:p,variant:`app-${a}`,verifiable:!0,issuer:{name:e,icon:o},header:{name:a==="passport"?r:C,icon:P},extra:a==="kyc"?{key:q,value:r}:I||{key:"Exp",value:"2123-01-01"}});return E?`data:image/svg+xml;utf8,${encodeURIComponent(i)}`:i};return s.exports=x,s.exports.getPassportColor=n,s.exports.getTextColor=m,s.exports}var T=R();const B=F(T);export{B as c};
