import{r as registerInstance,h}from"./index-2bbac65f.js";const prestoActionBarUiCss=":host{display:block;overflow:hidden}.bar{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;background:var(--presto-action-bar-background, #1d1d1d);color:#fff;padding:0 var(--presto-action-bar-padding, 6px);line-height:1em;font-size:16px;margin-top:-100%;transition:margin var(--presto-action-bar-animation-speed, 0.5s) ease-in-out;transform:translate3d(0);border-radius:0px 0px var(--presto-player-border-radius) var(--presto-player-border-radius)}.bar.bar--open{margin-top:0}.bar__button{margin:var(--presto-action-bar-padding, 6px);display:flex;align-items:center}.bar__content{margin:var(--presto-action-bar-padding, 6px);width:100%;text-align:center}@media screen and (min-width: 480px){.bar__content{width:auto}}",PrestoActionBarUi=class{constructor(t){registerInstance(this,t),this.open=void 0}render(){return h("div",{class:{bar:!0,"bar--open":this.open}},h("span",{part:"content",class:"bar__content"},h("slot",null)),h("span",{part:"button",class:"bar__button"},h("slot",{name:"button"})))}};PrestoActionBarUi.style=prestoActionBarUiCss;const prestoYoutubeSubscribeButtonCss=":host{display:block}",PrestoYoutubeSubscribeButton=class{constructor(t){registerInstance(this,t),this.channel=void 0,this.layout="default",this.showCount=void 0}waitForApi(t){var r=setInterval((function(){var e;(null===(e=null===window||void 0===window?void 0:window.gapi)||void 0===e?void 0:e.ytsubscribe)&&(clearInterval(r),t())}),50)}componentDidLoad(){const t=document.createElement("script");t.type="text/javascript",t.async=!1,t.src="https://apis.google.com/js/platform.js";const r=document.getElementsByTagName("script")[0];r&&r.parentNode.insertBefore(t,r),this.waitForApi((()=>{window.gapi.ytsubscribe.render(this.textInput,{channelId:this.channel,layout:this.layout,count:this.showCount?"default":"hidden"})}))}render(){return h("div",{class:"g-ytsubscribe",ref:t=>this.textInput=t})}};PrestoYoutubeSubscribeButton.style=":host{display:block}";export{PrestoActionBarUi as presto_action_bar_ui,PrestoYoutubeSubscribeButton as presto_youtube_subscribe_button};