"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("vue"),u=require("../../../_util/vue-types/index.js"),b=()=>({tab:u.default.any,disabled:{type:Boolean},forceRender:{type:Boolean},closable:{type:Boolean},animated:{type:Boolean},active:{type:Boolean},destroyInactiveTabPane:{type:Boolean},prefixCls:{type:String},tabKey:{type:[String,Number]},id:{type:String}}),y=t.defineComponent({compatConfig:{MODE:3},name:"ATabPane",inheritAttrs:!1,__ANT_TAB_PANE:!0,props:b(),slots:Object,setup(e,{attrs:l,slots:d}){const i=t.ref(e.forceRender);t.watch([()=>e.active,()=>e.destroyInactiveTabPane],()=>{e.active?i.value=!0:e.destroyInactiveTabPane&&(i.value=!1)},{immediate:!0});const c=t.computed(()=>e.active?{}:e.animated?{visibility:"hidden",height:0,overflowY:"hidden"}:{display:"none"});return()=>{const{prefixCls:r,forceRender:s,id:a,active:n,tabKey:o}=e;return t.createVNode("div",{id:a&&`${a}-panel-${o}`,role:"tabpanel",tabindex:n?0:-1,"aria-labelledby":a&&`${a}-tab-${o}`,"aria-hidden":!n,style:[c.value,l.style],class:[`${r}-tabpane`,n&&`${r}-tabpane-active`,l.class]},[(n||i.value||s)&&d.default?.()])}}});exports.default=y;
