1 line
1.2 KiB
JavaScript
1 line
1.2 KiB
JavaScript
"use strict";(wx.webpackJsonp=wx.webpackJsonp||[]).push([[23],{9927:function(e,t,n){var a=n(9975),i=n(1515),c="index-module__customTabBar___AIoAM",o="index-module__customTabBar-line___ClC6e",s="index-module__customTabBar-item___Xo7Pa",u="index-module__customTabBar-item-title___ua8eB",d="index-module__selected___pDY_D",r=n(6666),_=n(6408),l=n.n(_),m=n(2535),b=n.n(m),x=n(9194),f=n(2934),p=n(4119),h=n(5513),T=function CustomTabBar(){var e=(0,x.v)((function(e){return e.tabBarData})),t=e.selectedId,n=e.tabItem,a=(0,f.useDispatch)(),_=function handleSelectTabItem(e){return function(){var t;m(e),b().switchTab({url:null===(t=n.find((function(t){return t.id===e})))||void 0===t?void 0:t.pagePath})}},m=function setSelected(e){a({type:p.g.SET_SELECTED,data:{tabItem:n,selectedId:e}})};return(0,h.jsxs)(i.G7,{className:c,children:[(0,h.jsx)(i.G7,{className:o}),n.map((function(e,n){return(0,h.jsxs)(i.G7,{className:l()(s,u,t===e.id?d:""),onClick:_(e.id),children:[(0,h.jsx)(r.Z,{name:Number(t)===e.id?e.selectedIconPath:e.iconPath,size:56}),(0,h.jsx)(i.G7,{children:e.text})]},n)}))]})};Component((0,a.createComponentConfig)(T,"custom-tab-bar/index"))}},function(e){e.O(0,[107,592],(function(){return t=9927,e(e.s=t);var t}));e.O()}]); |