import{p as t,H as e,h as s,a as i}from"./index.js";import{p as a}from"./p-CQvUntGY.js";import{S as o}from"./p-BcQO4NH2.js";import{g as n}from"./p-DKo9A5gq.js";import{v as r}from"./p-BKP-F1qP.js";import{i as c}from"./p-CXgom82_.js";import{d as h}from"./p-BJnSrRNH.js";const d=a(o,["_S","_M","_L"]);const f={root:"gov-link",external:"gov-link--external"};const l=t(class t extends e{constructor(){super();this.__registerHost();this.size="m";this.external=false;this.truncate=false;this.inheritedAttributes={};this.h=n(this.host)}validateSize(t){r(d,t,f.root)}componentWillLoad(){this.validateSize(this.size);this.inheritedAttributes=c(this.host)}onAriaAttributeChange(t,e){this.host.removeAttribute(t);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:e})}render(){return s(i,{key:"87da124a14ecd5515767b8583a98c8a24ea6b21b",class:this.h.classes(f.root),size:this.size,href:this.href,external:this.external,truncate:this.truncate},s("a",Object.assign({key:"7e9b80a7eb6527214cea32a1a6b2dfa7bdba56a9",class:"element",href:this.href,target:this.external?"_blank":this.target,rel:this.external?"noreferrer":null},this.inheritedAttributes),s("slot",{key:"0620fa97529d8966460cd664ff4285719954ca26",name:"icon-start"}),s("span",{key:"fc56fe240cda4ab1dde314deac56937fa9d53717"},s("slot",{key:"fdb01c25b213ee2c093136ff86a9f3d56a0b12ca"})),s("slot",{key:"1d077305b248a77e6b6730c32d5136ce4a9b2858",name:"icon-end"}),this.external&&s("gov-icon",{key:"c9d155610f0cbd4ddf1fd1945b8da78357ba2767",name:"box-arrow-up-right",type:"components",size:this.size,class:f.external})))}get host(){return this}static get watchers(){return{size:["validateSize"]}}},[4,"gov-link",{size:[1],external:[4],truncate:[4],href:[1],target:[1],inheritedAttributes:[32]},undefined,{size:["validateSize"]}]);function m(){if(typeof customElements==="undefined"){return}const t=["gov-link","gov-icon"];t.forEach((t=>{switch(t){case"gov-link":if(!customElements.get(t)){customElements.define(t,l)}break;case"gov-icon":if(!customElements.get(t)){h()}break}}))}m();const b=l;const p=m;export{b as GovLink,p as defineCustomElement};
//# sourceMappingURL=gov-link.js.map