!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports["vue-element-ui-plus"]=e():t["vue-element-ui-plus"]=e()}(self,(()=>(()=>{"use strict";var t={1900:(t,e,r)=>{function n(t,e,r,n,i,o,s,a){var c,l="function"==typeof t?t.options:t;if(e&&(l.render=e,l.staticRenderFns=r,l._compiled=!0),n&&(l.functional=!0),o&&(l._scopeId="data-v-"+o),s?(c=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),i&&i.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(s)},l._ssrRegister=c):i&&(c=a?function(){i.call(this,(l.functional?this.parent:this).$root.$options.shadowRoot)}:i),c)if(l.functional){l._injectStyles=c;var u=l.render;l.render=function(t,e){return c.call(e),u(t,e)}}else{var p=l.beforeCreate;l.beforeCreate=p?[].concat(p,c):[c]}return{exports:t,options:l}}r.d(e,{Z:()=>n})}},e={};function r(n){var i=e[n];if(void 0!==i)return i.exports;var o=e[n]={exports:{}};return t[n](o,o.exports,r),o.exports}r.d=(t,e)=>{for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e);var n={};return(()=>{r.d(n,{default:()=>o});const t={name:"ElAvatar",props:{size:{type:[Number,String],validator:function(t){return"string"==typeof t?["large","medium","small"].includes(t):"number"==typeof t}},shape:{type:String,default:"circle",validator:function(t){return["circle","square"].includes(t)}},icon:String,src:String,alt:String,srcSet:String,error:Function,fit:{type:String,default:"cover"}},data:function(){return{isImageExist:!0}},computed:{avatarClass:function(){var t=this.size,e=this.icon,r=this.shape,n=["el-avatar"];return t&&"string"==typeof t&&n.push("el-avatar--".concat(t)),e&&n.push("el-avatar--icon"),r&&n.push("el-avatar--".concat(r)),n.join(" ")}},methods:{handleError:function(){var t=this.error;!1!==(t?t():void 0)&&(this.isImageExist=!1)},renderAvatar:function(){var t=this.$createElement,e=this.icon,r=this.src,n=this.alt,i=this.isImageExist,o=this.srcSet,s=this.fit;return i&&r?t("img",{attrs:{src:r,alt:n,srcSet:o},on:{error:this.handleError},style:{"object-fit":s}}):e?t("i",{class:e}):this.$slots.default}},render:function(){var t=arguments[0],e=this.avatarClass,r=this.size;return t("span",{class:e,style:"number"==typeof r?{height:"".concat(r,"px"),width:"".concat(r,"px"),lineHeight:"".concat(r,"px")}:{}},[this.renderAvatar()])}};var e=(0,r(1900).Z)(t,void 0,void 0,!1,null,null,null);e.options.__file="packages/avatar/src/main.vue";const i=e.exports;i.install=function(t){t.component(i.name,i)};const o=i})(),n.default})()));