(function(o,t){typeof exports=="object"&&typeof module<"u"?t(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],t):(o=typeof globalThis<"u"?globalThis:o||self,t(o.VLibras={},o.Vue))})(this,function(o,t){"use strict";const s={vw:"",class:"enabled"},r={__name:"VLibras",props:{src:{type:String,default:"https://vlibras.gov.br/app/vlibras-plugin.js"},urlWidget:{type:String,default:"https://vlibras.gov.br/app"},position:{type:String,default:"right",validator:e=>["left","right","bottom","top","bottom-left","top-left","bottom-right","top-right"].includes(e)},avatar:{type:String,default:"random",validator:e=>["icaro","hosana","guga","random"].includes(e)},opacity:{type:Number,default:1,validator:e=>e>=0&&e<=1}},setup(e){const i=e,d={left:"L",right:"R",bottom:"B",top:"T","bottom-left":"BL","top-left":"TL","bottom-right":"BR","top-right":"TR"};let n=t.ref(null);function c(){n=document.createElement("script"),n.addEventListener("load",a),n.src=i.src,document.querySelector("body").appendChild(n)}function a(){n.removeEventListener("load",a),new window.VLibras.Widget({url:i.urlWidget,position:d[i.position],avatar:i.avatar,opacity:i.opacity})}return t.onMounted(()=>{c()}),(u,l)=>(t.openBlock(),t.createElementBlock("div",s,l[0]||(l[0]=[t.createElementVNode("div",{"vw-access-button":"",class:"active"},null,-1),t.createElementVNode("div",{"vw-plugin-wrapper":""},[t.createElementVNode("div",{class:"vw-plugin-top-wrapper"})],-1)])))}};function p(e){e.component("VLibras",r)}o.VLibrasComponent=r,o.default=p,Object.defineProperties(o,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});