import{r as t,h as a}from"./p-BxRAfMA5.js";const e=":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}}",r=class{constructor(a){t(this,a)}render(){return a("div",{key:"b45af8959832ecc2f240622497174cd70f17015d",class:{bar:!0,"bar--open":this.open}},a("span",{key:"96010998372b90e5afba2316b9b71b3efb0e7502",part:"content",class:"bar__content"},a("slot",{key:"c166254469403bf9b24479697f11fda494246dcb"})),a("span",{key:"94a877081d27b5b19dd68419ca1b0694ef25053c",part:"button",class:"bar__button"},a("slot",{key:"de591a41e84782ef5b9dcdc06c5ee06e22e1b024",name:"button"})))}};r.style=e;const n=":host{display:block}",o=class{constructor(a){t(this,a),this.layout="default"}waitForApi(t){var a=setInterval(function(){var e;(null===(e=null===window||void 0===window?void 0:window.gapi)||void 0===e?void 0:e.ytsubscribe)&&(clearInterval(a),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 a=document.getElementsByTagName("script")[0];a&&a.parentNode.insertBefore(t,a),this.waitForApi(()=>{window.gapi.ytsubscribe.render(this.textInput,{channelId:this.channel,layout:this.layout,count:this.showCount?"default":"hidden"})})}render(){return a("div",{key:"5891adca82eb9dfda8db90ca5b11dac0cfdc58ed",class:"g-ytsubscribe",ref:t=>this.textInput=t})}};o.style=n;export{r as presto_action_bar_ui,o as presto_youtube_subscribe_button};