import{r as t,h as s}from"./p-1a7a8b00.js";const e=class{constructor(s){t(this,s),this.type=void 0,this.text=void 0,this.useExternal=!1}resetState(){}connectedCallback(){this.resetState()}componentWillLoad(){this.useExternal=!!customElements.get("bp-sdk-external-chip"),customElements.whenDefined("bp-sdk-external-chip").then((()=>{this.useExternal=!0}))}render(){return[this.useExternal&&this.renderExternal(),!this.useExternal&&this.renderInternal()]}renderExternal(){return s("bp-sdk-external-chip",{type:this.type,text:this.text})}renderInternal(){return[s("bp-sdk-chip-before",{text:this.text}),s("span",{class:`bp-sdk-chip bp-sdk-chip__${this.type}`,innerHTML:this.text}),s("bp-sdk-chip-after",{text:this.text})]}};export{e as bp_sdk_chip}