|  |  | 
 |  |  |  | 
 |  |  | const TarBarItem = function (props: TarBarItemProps, context: SetupContext<TarBarItemEvents>) { | 
 |  |  |   const _badge = props.badge > 99 ? '99+' : props.badge; | 
 |  |  |   const isActive = props.currentPath.toLowerCase().includes(props.pagePath.toLowerCase()); | 
 |  |  |   // const isActive = props.currentPath.toLowerCase().includes(props.pagePath.toLowerCase()); | 
 |  |  |   const isActive = props.active; | 
 |  |  |   return ( | 
 |  |  |     <div | 
 |  |  |       class={['bottom-tab-item', { active: isActive }, props.className]} | 
 |  |  | 
 |  |  |     const isLogin = useIsLogin(); | 
 |  |  |  | 
 |  |  |     const loginTipShowed = ref(false); | 
 |  |  |     const isClicking = ref(false); | 
 |  |  |  | 
 |  |  |     const switchTab = (url: string, index: number) => { | 
 |  |  |       if (isClicking.value) return; | 
 |  |  |       if (!isLogin.value && whitePageList.every((x) => x !== url)) { | 
 |  |  |         if (!loginTipShowed.value) { | 
 |  |  |           loginTipShowed.value = true; | 
 |  |  | 
 |  |  |         } | 
 |  |  |         return; | 
 |  |  |       } | 
 |  |  |       Taro.switchTab({ url }).then(() => { | 
 |  |  |         system.setTabIndex(index); | 
 |  |  |       }); | 
 |  |  |       isClicking.value = true; | 
 |  |  |       Taro.switchTab({ url }) | 
 |  |  |         .then(() => { | 
 |  |  |           system.setTabIndex(index); | 
 |  |  |         }) | 
 |  |  |         .finally(() => { | 
 |  |  |           isClicking.value = false; | 
 |  |  |         }); | 
 |  |  |     }; | 
 |  |  |  | 
 |  |  |     function goPublish() { |