@tarojs/components 3.6.0-beta.3 → 3.6.0-beta.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1 @@
1
+ {"version":3,"names":["splitUrl","_url","url","pos","res","path","query","fragment","indexOf","substring","addLeadingSlash","charAt","hasBasename","prefix","RegExp","test","stripBasename","length","stripSuffix","suffix","includes","getCurrentPage","routerMode","basename","pagePath","location","hash","slice","split","pathname","isAbsolute","spliceOne","list","index","i","k","n","pop","resolvePathname","to","from","undefined","toParts","fromParts","isToAbs","isFromAbs","mustEndAbs","concat","hasTrailingSlash","last","up","part","unshift","result","join","substr","TabbarItem","isSelected","textColor","iconPath","badgeText","showRedDot","text","onSelect","className","classNames","badgeStyle","position","top","right","dotStyle","onClick","page","Taro","getCurrentPages","shift","onTabItemTap","isVisible","this","h","key","href","class","style","display","src","alt","color","indexCss","STATUS_SHOW","STATUS_HIDE","STATUS_SLIDEOUT","basicTabBarClassName","hideTabBarClassName","hideTabBarWithAnimationClassName","Tabbar","constructor","hostRef","homePage","customRoutes","tabbarPos","getOriginUrl","customRoute","filter","customUrl","pathA","pathB","getSelectedIndex","foundIndex","forEach","idx","switchTab","selectedIndex","switchTabHandler","successHandler","errorHandler","currentUrl","getCurrentUrl","nextTab","errMsg","routerChangeHandler","options","_a","toLocation","currentPage","routerBasename","conf","setTabBarBadgeHandler","removeTabBarBadgeHandler","showTabBarRedDotHandler","hideTabBarRedDotHandler","showTabBarHandler","status","hideTabBarHandler","animation","setTabBarStyleHandler","selectedColor","backgroundColor","borderStyle","setTabBarItemHandler","selectedIconPath","Object","prototype","toString","call","Error","push","map","p","item","routePath","mode","decodeURI","bindEvent","eventCenter","on","removeEvent","off","componentDidLoad","tabbar","nextElementSibling","disconnectedCallback","render","containerCls","shouldHideTabBar","shouldSlideout","Host","height","bind"],"sources":["./src/utils/url.ts","../taro-router/dist/utils/index.js","../../node_modules/.pnpm/registry.npmjs.org+resolve-pathname@3.0.0/node_modules/resolve-pathname/esm/resolve-pathname.js","./src/components/tabbar/tabbar-item.tsx","./src/components/tabbar/style/index.scss?tag=taro-tabbar","./src/components/tabbar/tabbar.tsx"],"sourcesContent":["export const normalizePath = url => {\n let _isRelative\n let _leadingParents = ''\n let _parent, _pos\n\n // handle relative paths\n if (url.charAt(0) !== '/') {\n _isRelative = true\n url = '/' + url\n }\n\n // handle relative files (as opposed to directories)\n if (url.substring(-3) === '/..' || url.slice(-2) === '/.') {\n url += '/'\n }\n\n // resolve simples\n url = url.replace(/(\\/(\\.\\/)+)|(\\/\\.$)/g, '/').replace(/\\/{2,}/g, '/')\n\n // remember leading parents\n if (_isRelative) {\n _leadingParents = url.substring(1).match(/^(\\.\\.\\/)+/) || ''\n if (_leadingParents) {\n _leadingParents = _leadingParents[0]\n }\n }\n\n // resolve parents\n while (true) {\n _parent = url.search(/\\/\\.\\.(\\/|$)/)\n if (_parent === -1) {\n // no more ../ to resolve\n break\n } else if (_parent === 0) {\n // top level cannot be relative, skip it\n url = url.substring(3)\n continue\n }\n\n _pos = url.substring(0, _parent).lastIndexOf('/')\n if (_pos === -1) {\n _pos = _parent\n }\n url = url.substring(0, _pos) + url.substring(_parent + 3)\n }\n\n // revert to relative\n if (_isRelative) {\n url = _leadingParents + url.substring(1)\n }\n\n return url\n}\n\nexport const splitUrl = _url => {\n let url = _url || ''\n let pos\n const res = {\n path: null,\n query: null,\n fragment: null\n }\n\n pos = url.indexOf('#')\n if (pos > -1) {\n res.fragment = url.substring(pos + 1)\n url = url.substring(0, pos)\n }\n\n pos = url.indexOf('?')\n if (pos > -1) {\n res.query = url.substring(pos + 1)\n url = url.substring(0, pos)\n }\n\n res.path = url\n\n return res\n}\n","// export const removeLeadingSlash = (str = '') => str.replace(/^\\.?\\//, '')\n// export const removeTrailingSearch = (str = '') => str.replace(/\\?[\\s\\S]*$/, '')\nexport const addLeadingSlash = (url = '') => (url.charAt(0) === '/' ? url : '/' + url);\nexport const hasBasename = (path = '', prefix = '') => new RegExp('^' + prefix + '(\\\\/|\\\\?|#|$)', 'i').test(path) || path === prefix;\nexport const stripBasename = (path = '', prefix = '') => hasBasename(path, prefix) ? path.substring(prefix.length) : path;\nexport const stripTrailing = (str = '') => str.replace(/[?#][\\s\\S]*$/, '');\nexport const stripSuffix = (path = '', suffix = '') => path.includes(suffix) ? path.substring(0, path.length - suffix.length) : path;\nexport const getHomePage = (path = '', basename = '', customRoutes = {}, entryPagePath = '') => {\n var _a;\n const routePath = addLeadingSlash(stripBasename(path, basename));\n const alias = ((_a = Object.entries(customRoutes).find(([key]) => key === routePath)) === null || _a === void 0 ? void 0 : _a[1]) || routePath;\n return entryPagePath || (typeof alias === 'string' ? alias : alias[0]) || basename;\n};\nexport const getCurrentPage = (routerMode = 'hash', basename = '/') => {\n const pagePath = routerMode === 'hash'\n ? location.hash.slice(1).split('?')[0]\n : location.pathname;\n return addLeadingSlash(stripBasename(pagePath, basename));\n};\nclass RoutesAlias {\n constructor() {\n this.conf = [];\n this.getConfig = (url = '') => {\n const customRoute = this.conf.filter((arr) => {\n return arr.includes(url);\n });\n return customRoute[0];\n };\n this.getOrigin = (url = '') => {\n var _a;\n return ((_a = this.getConfig(url)) === null || _a === void 0 ? void 0 : _a[0]) || url;\n };\n this.getAlias = (url = '') => {\n var _a;\n return ((_a = this.getConfig(url)) === null || _a === void 0 ? void 0 : _a[1]) || url;\n };\n this.getAll = (url = '') => {\n return this.conf\n .filter((arr) => arr.includes(url))\n .reduceRight((p, a) => {\n p.unshift(a[1]);\n return p;\n }, []);\n };\n }\n set(customRoutes = {}) {\n for (let key in customRoutes) {\n const path = customRoutes[key];\n key = addLeadingSlash(key);\n if (typeof path === 'string') {\n this.conf.push([key, addLeadingSlash(path)]);\n }\n else if ((path === null || path === void 0 ? void 0 : path.length) > 0) {\n this.conf.push(...path.map(p => [key, addLeadingSlash(p)]));\n }\n }\n }\n}\nexport const routesAlias = new RoutesAlias();\n","function isAbsolute(pathname) {\n return pathname.charAt(0) === '/';\n}\n\n// About 1.5x faster than the two-arg version of Array#splice()\nfunction spliceOne(list, index) {\n for (var i = index, k = i + 1, n = list.length; k < n; i += 1, k += 1) {\n list[i] = list[k];\n }\n\n list.pop();\n}\n\n// This implementation is based heavily on node's url.parse\nfunction resolvePathname(to, from) {\n if (from === undefined) from = '';\n\n var toParts = (to && to.split('/')) || [];\n var fromParts = (from && from.split('/')) || [];\n\n var isToAbs = to && isAbsolute(to);\n var isFromAbs = from && isAbsolute(from);\n var mustEndAbs = isToAbs || isFromAbs;\n\n if (to && isAbsolute(to)) {\n // to is absolute\n fromParts = toParts;\n } else if (toParts.length) {\n // to is relative, drop the filename\n fromParts.pop();\n fromParts = fromParts.concat(toParts);\n }\n\n if (!fromParts.length) return '/';\n\n var hasTrailingSlash;\n if (fromParts.length) {\n var last = fromParts[fromParts.length - 1];\n hasTrailingSlash = last === '.' || last === '..' || last === '';\n } else {\n hasTrailingSlash = false;\n }\n\n var up = 0;\n for (var i = fromParts.length; i >= 0; i--) {\n var part = fromParts[i];\n\n if (part === '.') {\n spliceOne(fromParts, i);\n } else if (part === '..') {\n spliceOne(fromParts, i);\n up++;\n } else if (up) {\n spliceOne(fromParts, i);\n up--;\n }\n }\n\n if (!mustEndAbs) for (; up--; up) fromParts.unshift('..');\n\n if (\n mustEndAbs &&\n fromParts[0] !== '' &&\n (!fromParts[0] || !isAbsolute(fromParts[0]))\n )\n fromParts.unshift('');\n\n var result = fromParts.join('/');\n\n if (hasTrailingSlash && result.substr(-1) !== '/') result += '/';\n\n return result;\n}\n\nexport default resolvePathname;\n","import classNames from 'classnames'\nimport { FunctionalComponent, h } from '@stencil/core'\nimport Taro from '@tarojs/taro'\n\nimport { isVisible } from '../../utils'\n\ntype TabbarItemProps = {\n index: number\n isSelected?: boolean\n textColor?: string\n badgeText?: string\n iconPath: string\n showRedDot?: boolean\n pagePath?: string\n text?: string\n onSelect: (index: number) => void\n}\n\nexport const TabbarItem: FunctionalComponent<TabbarItemProps> = ({\n index,\n isSelected = false,\n textColor,\n iconPath,\n badgeText,\n showRedDot = false,\n pagePath,\n text,\n onSelect\n}) => {\n const className = classNames('weui-tabbar__item', {\n 'weui-bar__item_on': isSelected\n })\n const badgeStyle = {\n position: 'absolute',\n top: '-2px',\n right: '-13px'\n }\n const dotStyle = {\n position: 'absolute',\n top: '0',\n right: '-6px'\n }\n\n function onClick () {\n const page = Taro.getCurrentPages().shift()\n if (typeof page?.onTabItemTap === 'function' && isVisible(this)) {\n page.onTabItemTap({ index, pagePath, text })\n }\n onSelect(index)\n }\n\n return (\n <a key={index} href='javascript:;' class={className} onClick={onClick}>\n <span style={{ display: 'inline-block', position: 'relative' }}>\n <img src={iconPath} alt='' class='weui-tabbar__icon' />\n {!!badgeText && (\n <span\n class='weui-badge taro-tabbar-badge'\n style={badgeStyle}>\n {badgeText}\n </span>\n )}\n {showRedDot && (\n <span\n class='weui-badge weui-badge_dot'\n style={dotStyle}\n />\n )}\n </span>\n <p class='weui-tabbar__label' style={{ color: textColor }}>\n {text}\n </p>\n </a>\n )\n}\n","html,\nbody {\n height: 100%;\n}\n\n#app {\n height: 100%;\n}\n\n.taro-tabbar {\n &__border {\n &-white {\n &::before {\n border-top-color: #fff !important;\n }\n }\n }\n\n &__container {\n display: flex;\n overflow: hidden;\n flex-direction: column;\n height: 100%;\n }\n\n &__panel {\n overflow: auto;\n position: relative;\n flex: 1;\n -webkit-overflow-scrolling: auto;\n }\n\n &__tabbar {\n position: relative;\n width: 100%;\n height: 50px;\n transition: bottom 0.2s, top 0.2s;\n\n &-top {\n top: 0;\n }\n\n &-bottom {\n bottom: 0;\n margin-bottom: constant(safe-area-inset-bottom);\n margin-bottom: env(safe-area-inset-bottom);\n }\n\n &-hide {\n display: none;\n }\n\n &-slideout {\n top: -52px;\n flex: 0 0;\n }\n }\n\n &__panel + &__tabbar-slideout {\n top: auto;\n bottom: -52px;\n }\n}\n","import { Component, Prop, h, ComponentInterface, Host, State, Event, EventEmitter, Element } from '@stencil/core'\nimport Taro from '@tarojs/taro'\nimport { addLeadingSlash, getCurrentPage, stripBasename, stripSuffix } from '@tarojs/router/dist/utils'\nimport { IH5RouterConfig } from '@tarojs/taro/types/compile'\nimport classNames from 'classnames'\nimport resolvePathname from 'resolve-pathname'\n\nimport { splitUrl } from '../../utils'\nimport { TabbarItem } from './tabbar-item'\n\nconst STATUS_SHOW = 0\nconst STATUS_HIDE = 1\nconst STATUS_SLIDEOUT = 2\n\nconst basicTabBarClassName = 'taro-tabbar__tabbar'\nconst hideTabBarClassName = 'taro-tabbar__tabbar-hide'\nconst hideTabBarWithAnimationClassName = 'taro-tabbar__tabbar-slideout'\n\ninterface RouterHandler {\n index: string\n text: string\n url: string\n successHandler: Function\n errorHandler: Function\n animation?: boolean\n}\n\nexport interface Conf {\n color: string\n selectedColor: string\n backgroundColor: string\n borderStyle?: 'black' | 'white'\n list: TabbarList[]\n position?: 'bottom' | 'top'\n custom: boolean\n customRoutes: Record<string, string | string[]>\n mode: IH5RouterConfig['mode']\n basename: string\n homePage: string\n currentPagename: string\n}\n\ninterface TabbarList {\n pagePath: string\n text: string\n iconPath?: string\n selectedIconPath?: string\n badgeText?: string\n showRedDot?: boolean\n}\n\n@Component({\n tag: 'taro-tabbar',\n styleUrl: './style/index.scss'\n})\nexport class Tabbar implements ComponentInterface {\n private homePage = ''\n\n private customRoutes: Array<string[]> = []\n\n private tabbarPos: 'top' | 'bottom' = 'bottom'\n\n @Prop() conf: Conf\n\n @State() list: TabbarList[]\n\n @State() borderStyle: Conf['borderStyle']\n\n @State() backgroundColor: Conf['backgroundColor']\n\n @State() color: Conf['color']\n\n @State() selectedColor: Conf['selectedColor']\n\n @State() selectedIndex = -1\n\n @State() status: 0 | 1 | 2 = STATUS_SHOW\n\n @Event({\n eventName: 'longpress'\n }) onLongPress: EventEmitter\n\n @Element() tabbar: HTMLDivElement\n\n constructor () {\n const list = this.conf.list\n const customRoutes = this.conf.customRoutes\n if (\n Object.prototype.toString.call(list) !== '[object Array]' ||\n list.length < 2 ||\n list.length > 5\n ) {\n throw new Error('tabBar 配置错误')\n }\n\n this.homePage = addLeadingSlash(this.conf.homePage)\n for (let key in customRoutes) {\n const path = customRoutes[key]\n key = addLeadingSlash(key)\n if (typeof path === 'string') {\n this.customRoutes.push([key, addLeadingSlash(path)])\n } else if (path?.length > 0) {\n this.customRoutes.push(...path.map(p => [key, addLeadingSlash(p)]))\n }\n }\n\n list.forEach(item => {\n if (item.pagePath.indexOf('/') !== 0) {\n item.pagePath = '/' + item.pagePath\n }\n })\n\n this.list = list\n this.borderStyle = this.conf.borderStyle\n this.backgroundColor = this.conf.backgroundColor\n this.color = this.conf.color\n this.selectedColor = this.conf.selectedColor\n }\n\n getCurrentUrl () {\n const routePath = getCurrentPage(this.conf.mode, this.conf.basename)\n return decodeURI(routePath === '/' ? this.homePage : routePath)\n }\n\n getOriginUrl = (url: string) => {\n const customRoute = this.customRoutes.filter(([, customUrl]) => {\n const pathA = splitUrl(customUrl).path\n const pathB = splitUrl(url).path\n return pathA === pathB\n })\n return stripSuffix(customRoute.length ? customRoute[0][0] : url, '.html')\n }\n\n getSelectedIndex = (url: string) => {\n let foundIndex = -1\n this.list.forEach(({ pagePath }, idx) => {\n const pathA = splitUrl(url).path\n const pathB = splitUrl(pagePath).path\n if (pathA === pathB) {\n foundIndex = idx\n }\n })\n return foundIndex\n }\n\n switchTab = (index: number) => {\n this.selectedIndex = index\n Taro.switchTab({\n url: this.list[index].pagePath\n })\n }\n\n switchTabHandler = ({ url, successHandler, errorHandler }: RouterHandler) => {\n const currentUrl = this.getOriginUrl(this.getCurrentUrl() || this.homePage)\n const nextTab = resolvePathname(url, currentUrl)\n const foundIndex = this.getSelectedIndex(nextTab)\n\n if (foundIndex > -1) {\n this.switchTab(foundIndex)\n successHandler({\n errMsg: 'switchTab:ok'\n })\n } else {\n errorHandler({\n errMsg: `switchTab:fail page \"${nextTab}\" is not found`\n })\n }\n }\n\n routerChangeHandler = (options?) => {\n const to = options?.toLocation?.path\n let currentPage\n\n if (typeof to === 'string') {\n const routerBasename = this.conf.basename || '/'\n currentPage = stripBasename(addLeadingSlash(to || this.homePage), routerBasename) || '/'\n } else {\n currentPage = this.getCurrentUrl()\n }\n\n this.selectedIndex = this.getSelectedIndex(this.getOriginUrl(currentPage))\n }\n\n setTabBarBadgeHandler = ({ index, text, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].showRedDot = false\n list[index].badgeText = text\n successHandler({\n errMsg: 'setTabBarBadge:ok'\n })\n } else {\n errorHandler({\n errMsg: 'setTabBarBadge:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n removeTabBarBadgeHandler = ({ index, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].badgeText = null\n list[index].badgeText = null\n successHandler({\n errMsg: 'removeTabBarBadge:ok'\n })\n } else {\n errorHandler({\n errMsg: 'removeTabBarBadge:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n showTabBarRedDotHandler = ({ index, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].badgeText = null\n list[index].showRedDot = true\n successHandler({\n errMsg: 'showTabBarRedDot:ok'\n })\n } else {\n errorHandler({\n errMsg: 'showTabBarRedDot:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n hideTabBarRedDotHandler = ({ index, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].showRedDot = false\n successHandler({\n errMsg: 'hideTabBarRedDot:ok'\n })\n } else {\n errorHandler({\n errMsg: 'hideTabBarRedDot:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n showTabBarHandler = ({ successHandler }) => {\n this.status = STATUS_SHOW\n successHandler({\n errMsg: 'showTabBar:ok'\n })\n }\n\n hideTabBarHandler = ({ animation, successHandler }) => {\n this.status = animation ? STATUS_SLIDEOUT : STATUS_HIDE\n successHandler({\n errMsg: 'hideTabBar:ok'\n })\n }\n\n setTabBarStyleHandler = ({ color, selectedColor, backgroundColor, borderStyle, successHandler }) => {\n if (backgroundColor) this.backgroundColor = backgroundColor\n if (borderStyle) this.borderStyle = borderStyle\n if (color) this.color = color\n if (selectedColor) this.selectedColor = selectedColor\n successHandler({\n errMsg: 'setTabBarStyle:ok'\n })\n }\n\n setTabBarItemHandler = ({ index, iconPath, selectedIconPath, text, successHandler, errorHandler }) => {\n const list = [...this.list]\n if (index in list) {\n if (iconPath) list[index].iconPath = iconPath\n if (selectedIconPath) list[index].selectedIconPath = selectedIconPath\n if (text) list[index].text = text\n successHandler({\n errMsg: 'setTabBarItem:ok'\n })\n } else {\n errorHandler({\n errMsg: 'setTabBarItem:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n bindEvent () {\n Taro.eventCenter.on('__taroRouterChange', this.routerChangeHandler)\n Taro.eventCenter.on('__taroSwitchTab', this.switchTabHandler)\n Taro.eventCenter.on('__taroSetTabBarBadge', this.setTabBarBadgeHandler)\n Taro.eventCenter.on('__taroRemoveTabBarBadge', this.removeTabBarBadgeHandler)\n Taro.eventCenter.on('__taroShowTabBarRedDotHandler', this.showTabBarRedDotHandler)\n Taro.eventCenter.on('__taroHideTabBarRedDotHandler', this.hideTabBarRedDotHandler)\n Taro.eventCenter.on('__taroShowTabBar', this.showTabBarHandler)\n Taro.eventCenter.on('__taroHideTabBar', this.hideTabBarHandler)\n Taro.eventCenter.on('__taroSetTabBarStyle', this.setTabBarStyleHandler)\n Taro.eventCenter.on('__taroSetTabBarItem', this.setTabBarItemHandler)\n }\n\n removeEvent () {\n Taro.eventCenter.off('__taroRouterChange', this.routerChangeHandler)\n Taro.eventCenter.off('__taroSwitchTab', this.switchTabHandler)\n Taro.eventCenter.off('__taroSetTabBarBadge', this.setTabBarBadgeHandler)\n Taro.eventCenter.off('__taroRemoveTabBarBadge', this.removeTabBarBadgeHandler)\n Taro.eventCenter.off('__taroShowTabBarRedDotHandler', this.showTabBarRedDotHandler)\n Taro.eventCenter.off('__taroHideTabBarRedDotHandler', this.hideTabBarRedDotHandler)\n Taro.eventCenter.off('__taroShowTabBar', this.showTabBarHandler)\n Taro.eventCenter.off('__taroHideTabBar', this.hideTabBarHandler)\n Taro.eventCenter.off('__taroSetTabBarStyle', this.setTabBarStyleHandler)\n Taro.eventCenter.off('__taroSetTabBarItem', this.setTabBarItemHandler)\n }\n\n componentDidLoad () {\n this.tabbarPos = this.tabbar.nextElementSibling ? 'top' : 'bottom'\n this.bindEvent()\n this.routerChangeHandler()\n }\n\n disconnectedCallback () {\n this.removeEvent()\n }\n\n render () {\n const { tabbarPos = 'bottom' } = this\n const status = this.status\n const containerCls = classNames('weui-tabbar', {\n [`taro-tabbar__border-${this.borderStyle || 'black'}`]: true\n })\n const shouldHideTabBar = this.selectedIndex === -1 || status === STATUS_HIDE\n const shouldSlideout = status === STATUS_SLIDEOUT\n\n return (\n <Host\n class={classNames(\n basicTabBarClassName,\n `${basicTabBarClassName}-${tabbarPos}`, {\n [hideTabBarClassName]: shouldHideTabBar,\n [hideTabBarWithAnimationClassName]: shouldSlideout\n })} >\n <div\n class={containerCls}\n style={{\n backgroundColor: this.backgroundColor || '',\n height: 'inherit'\n }}\n >\n {this.list.map((item, index) => {\n const isSelected = this.selectedIndex === index\n let textColor\n let iconPath\n if (isSelected) {\n textColor = this.selectedColor || ''\n iconPath = item.selectedIconPath\n } else {\n textColor = this.color || ''\n iconPath = item.iconPath\n }\n return (\n <TabbarItem\n index={index}\n onSelect={this.switchTab.bind(this)}\n isSelected={isSelected}\n textColor={textColor}\n iconPath={iconPath}\n pagePath={item.pagePath}\n text={item.text}\n badgeText={item.badgeText}\n showRedDot={item.showRedDot}\n />\n )\n })}\n </div>\n </Host>\n )\n }\n}\n"],"mappings":"oKAsDO,MAAMA,EAAWC,IACtB,IAAIC,EAAMD,GAAQ,GAClB,IAAIE,EACJ,MAAMC,EAAM,CACVC,KAAM,KACNC,MAAO,KACPC,SAAU,MAGZJ,EAAMD,EAAIM,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r||arguments.length===2)for(var a=0,o=t.length,n;a<o;a++){if(n||!(a in t)){if(!n)n=Array.prototype.slice.call(t,0,a);n[a]=t[a]}}return e.concat(n||Array.prototype.slice.call(t))};System.register(["./p-1a0e1932.system.js","@tarojs/taro","./p-61f225ef.system.js","./p-bd5177d3.system.js"],(function(e){"use strict";var t,r,a,o,n,i,s,l;return{setters:[function(e){t=e.h;r=e.r;a=e.c;o=e.H;n=e.g},function(e){i=e.default},function(e){s=e.c},function(e){l=e.i}],execute:function(){var d=function(e){var t=e||"";var r;var a={path:null,query:null,fragment:null};r=t.indexOf("#");if(r>-1){a.fragment=t.substring(r+1);t=t.substring(0,r)}r=t.indexOf("?");if(r>-1){a.query=t.substring(r+1);t=t.substring(0,r)}a.path=t;return a};var b=function(e){if(e===void 0){e=""}return e.charAt(0)==="/"?e:"/"+e};var h=function(e,t){if(e===void 0){e=""}if(t===void 0){t=""}return new RegExp("^"+t+"(\\/|\\?|#|$)","i").test(e)||e===t};var c=function(e,t){if(e===void 0){e=""}if(t===void 0){t=""}return h(e,t)?e.substring(t.length):e};var f=function(e,t){if(e===void 0){e=""}if(t===void 0){t=""}return e.includes(t)?e.substring(0,e.length-t.length):e};var u=function(e,t){if(e===void 0){e="hash"}if(t===void 0){t="/"}var r=e==="hash"?location.hash.slice(1).split("?")[0]:location.pathname;return b(c(r,t))};function v(e){return e.charAt(0)==="/"}function g(e,t){for(var r=t,a=r+1,o=e.length;a<o;r+=1,a+=1){e[r]=e[a]}e.pop()}function p(e,t){if(t===undefined)t="";var r=e&&e.split("/")||[];var a=t&&t.split("/")||[];var o=e&&v(e);var n=t&&v(t);var i=o||n;if(e&&v(e)){a=r}else if(r.length){a.pop();a=a.concat(r)}if(!a.length)return"/";var s;if(a.length){var l=a[a.length-1];s=l==="."||l===".."||l===""}else{s=false}var d=0;for(var b=a.length;b>=0;b--){var h=a[b];if(h==="."){g(a,b)}else if(h===".."){g(a,b);d++}else if(d){g(a,b);d--}}if(!i)for(;d--;d)a.unshift("..");if(i&&a[0]!==""&&(!a[0]||!v(a[0])))a.unshift("");var c=a.join("/");if(s&&c.substr(-1)!=="/")c+="/";return c}var _=function(e){var r=e.index,a=e.isSelected,o=a===void 0?false:a,n=e.textColor,d=e.iconPath,b=e.badgeText,h=e.showRedDot,c=h===void 0?false:h,f=e.pagePath,u=e.text,v=e.onSelect;var g=s("weui-tabbar__item",{"weui-bar__item_on":o});var p={position:"absolute",top:"-2px",right:"-13px"};var _={position:"absolute",top:"0",right:"-6px"};function m(){var e=i.getCurrentPages().shift();if(typeof(e===null||e===void 0?void 0:e.onTabItemTap)==="function"&&l(this)){e.onTabItemTap({index:r,pagePath:f,text:u})}v(r)}return t("a",{key:r,href:"javascript:;",class:g,onClick:m},t("span",{style:{display:"inline-block",position:"relative"}},t("img",{src:d,alt:"",class:"weui-tabbar__icon"}),!!b&&t("span",{class:"weui-badge taro-tabbar-badge",style:p},b),c&&t("span",{class:"weui-badge weui-badge_dot",style:_})),t("p",{class:"weui-tabbar__label",style:{color:n}},u))};var m="html,body{height:100%}#app{height:100%}.taro-tabbar__border-white::before{border-top-color:#fff !important}.taro-tabbar__container{display:-ms-flexbox;display:flex;overflow:hidden;-ms-flex-direction:column;flex-direction:column;height:100%}.taro-tabbar__panel{overflow:auto;position:relative;-ms-flex:1;flex:1;-webkit-overflow-scrolling:auto}.taro-tabbar__tabbar{position:relative;width:100%;height:50px;-webkit-transition:bottom 0.2s, top 0.2s;transition:bottom 0.2s, top 0.2s}.taro-tabbar__tabbar-top{top:0}.taro-tabbar__tabbar-bottom{bottom:0;margin-bottom:constant(safe-area-inset-bottom);margin-bottom:env(safe-area-inset-bottom)}.taro-tabbar__tabbar-hide{display:none}.taro-tabbar__tabbar-slideout{top:-52px;-ms-flex:0 0;flex:0 0}.taro-tabbar__panel+.taro-tabbar__tabbar-slideout{top:auto;bottom:-52px}";var T=0;var B=1;var y=2;var H="taro-tabbar__tabbar";var x="taro-tabbar__tabbar-hide";var w="taro-tabbar__tabbar-slideout";var C=e("taro_tabbar",function(){function e(e){var t=this;r(this,e);this.onLongPress=a(this,"longpress",7);this.homePage="";this.customRoutes=[];this.tabbarPos="bottom";this.getOriginUrl=function(e){var r=t.customRoutes.filter((function(t){var r=t[1];var a=d(r).path;var o=d(e).path;return a===o}));return f(r.length?r[0][0]:e,".html")};this.getSelectedIndex=function(e){var r=-1;t.list.forEach((function(t,a){var o=t.pagePath;var n=d(e).path;var i=d(o).path;if(n===i){r=a}}));return r};this.switchTab=function(e){t.selectedIndex=e;i.switchTab({url:t.list[e].pagePath})};this.switchTabHandler=function(e){var r=e.url,a=e.successHandler,o=e.errorHandler;var n=t.getOriginUrl(t.getCurrentUrl()||t.homePage);var i=p(r,n);var s=t.getSelectedIndex(i);if(s>-1){t.switchTab(s);a({errMsg:"switchTab:ok"})}else{o({errMsg:'switchTab:fail page "'.concat(i,'" is not found')})}};this.routerChangeHandler=function(e){var r;var a=(r=e===null||e===void 0?void 0:e.toLocation)===null||r===void 0?void 0:r.path;var o;if(typeof a==="string"){var n=t.conf.basename||"/";o=c(b(a||t.homePage),n)||"/"}else{o=t.getCurrentUrl()}t.selectedIndex=t.getSelectedIndex(t.getOriginUrl(o))};this.setTabBarBadgeHandler=function(e){var r=e.index,a=e.text,o=e.successHandler,n=e.errorHandler;var i=__spreadArray([],t.list,true);if(r in i){i[r].showRedDot=false;i[r].badgeText=a;o({errMsg:"setTabBarBadge:ok"})}else{n({errMsg:"setTabBarBadge:fail tabbar item not found"})}t.list=i};this.removeTabBarBadgeHandler=function(e){var r=e.index,a=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(r in n){n[r].badgeText=null;n[r].badgeText=null;a({errMsg:"removeTabBarBadge:ok"})}else{o({errMsg:"removeTabBarBadge:fail tabbar item not found"})}t.list=n};this.showTabBarRedDotHandler=function(e){var r=e.index,a=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(r in n){n[r].badgeText=null;n[r].showRedDot=true;a({errMsg:"showTabBarRedDot:ok"})}else{o({errMsg:"showTabBarRedDot:fail tabbar item not found"})}t.list=n};this.hideTabBarRedDotHandler=function(e){var r=e.index,a=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(r in n){n[r].showRedDot=false;a({errMsg:"hideTabBarRedDot:ok"})}else{o({errMsg:"hideTabBarRedDot:fail tabbar item not found"})}t.list=n};this.showTabBarHandler=function(e){var r=e.successHandler;t.status=T;r({errMsg:"showTabBar:ok"})};this.hideTabBarHandler=function(e){var r=e.animation,a=e.successHandler;t.status=r?y:B;a({errMsg:"hideTabBar:ok"})};this.setTabBarStyleHandler=function(e){var r=e.color,a=e.selectedColor,o=e.backgroundColor,n=e.borderStyle,i=e.successHandler;if(o)t.backgroundColor=o;if(n)t.borderStyle=n;if(r)t.color=r;if(a)t.selectedColor=a;i({errMsg:"setTabBarStyle:ok"})};this.setTabBarItemHandler=function(e){var r=e.index,a=e.iconPath,o=e.selectedIconPath,n=e.text,i=e.successHandler,s=e.errorHandler;var l=__spreadArray([],t.list,true);if(r in l){if(a)l[r].iconPath=a;if(o)l[r].selectedIconPath=o;if(n)l[r].text=n;i({errMsg:"setTabBarItem:ok"})}else{s({errMsg:"setTabBarItem:fail tabbar item not found"})}t.list=l};this.conf=undefined;this.list=undefined;this.borderStyle=undefined;this.backgroundColor=undefined;this.color=undefined;this.selectedColor=undefined;this.selectedIndex=-1;this.status=T;var o=this.conf.list;var n=this.conf.customRoutes;if(Object.prototype.toString.call(o)!=="[object Array]"||o.length<2||o.length>5){throw new Error("tabBar 配置错误")}this.homePage=b(this.conf.homePage);var s=function(e){var t;var r=n[e];e=b(e);if(typeof r==="string"){l.customRoutes.push([e,b(r)])}else if((r===null||r===void 0?void 0:r.length)>0){(t=l.customRoutes).push.apply(t,r.map((function(t){return[e,b(t)]})))}};var l=this;for(var h in n){s(h)}o.forEach((function(e){if(e.pagePath.indexOf("/")!==0){e.pagePath="/"+e.pagePath}}));this.list=o;this.borderStyle=this.conf.borderStyle;this.backgroundColor=this.conf.backgroundColor;this.color=this.conf.color;this.selectedColor=this.conf.selectedColor}e.prototype.getCurrentUrl=function(){var e=u(this.conf.mode,this.conf.basename);return decodeURI(e==="/"?this.homePage:e)};e.prototype.bindEvent=function(){i.eventCenter.on("__taroRouterChange",this.routerChangeHandler);i.eventCenter.on("__taroSwitchTab",this.switchTabHandler);i.eventCenter.on("__taroSetTabBarBadge",this.setTabBarBadgeHandler);i.eventCenter.on("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);i.eventCenter.on("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);i.eventCenter.on("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);i.eventCenter.on("__taroShowTabBar",this.showTabBarHandler);i.eventCenter.on("__taroHideTabBar",this.hideTabBarHandler);i.eventCenter.on("__taroSetTabBarStyle",this.setTabBarStyleHandler);i.eventCenter.on("__taroSetTabBarItem",this.setTabBarItemHandler)};e.prototype.removeEvent=function(){i.eventCenter.off("__taroRouterChange",this.routerChangeHandler);i.eventCenter.off("__taroSwitchTab",this.switchTabHandler);i.eventCenter.off("__taroSetTabBarBadge",this.setTabBarBadgeHandler);i.eventCenter.off("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);i.eventCenter.off("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);i.eventCenter.off("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);i.eventCenter.off("__taroShowTabBar",this.showTabBarHandler);i.eventCenter.off("__taroHideTabBar",this.hideTabBarHandler);i.eventCenter.off("__taroSetTabBarStyle",this.setTabBarStyleHandler);i.eventCenter.off("__taroSetTabBarItem",this.setTabBarItemHandler)};e.prototype.componentDidLoad=function(){this.tabbarPos=this.tabbar.nextElementSibling?"top":"bottom";this.bindEvent();this.routerChangeHandler()};e.prototype.disconnectedCallback=function(){this.removeEvent()};e.prototype.render=function(){var e,r;var a=this;var n=this.tabbarPos,i=n===void 0?"bottom":n;var l=this.status;var d=s("weui-tabbar",(e={},e["taro-tabbar__border-".concat(this.borderStyle||"black")]=true,e));var b=this.selectedIndex===-1||l===B;var h=l===y;return t(o,{class:s(H,"".concat(H,"-").concat(i),(r={},r[x]=b,r[w]=h,r))},t("div",{class:d,style:{backgroundColor:this.backgroundColor||"",height:"inherit"}},this.list.map((function(e,r){var o=a.selectedIndex===r;var n;var i;if(o){n=a.selectedColor||"";i=e.selectedIconPath}else{n=a.color||"";i=e.iconPath}return t(_,{index:r,onSelect:a.switchTab.bind(a),isSelected:o,textColor:n,iconPath:i,pagePath:e.pagePath,text:e.text,badgeText:e.badgeText,showRedDot:e.showRedDot})}))))};Object.defineProperty(e.prototype,"tabbar",{get:function(){return n(this)},enumerable:false,configurable:true});return e}());C.style=m}}}));
2
+ //# sourceMappingURL=p-efa51030.system.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["splitUrl","_url","url","pos","res","path","query","fragment","indexOf","substring","addLeadingSlash","charAt","hasBasename","prefix","RegExp","test","stripBasename","length","stripSuffix","suffix","includes","getCurrentPage","routerMode","basename","pagePath","location","hash","slice","split","pathname","isAbsolute","spliceOne","list","index","i","k","n","pop","resolvePathname","to","from","undefined","toParts","fromParts","isToAbs","isFromAbs","mustEndAbs","concat","hasTrailingSlash","last","up","part","unshift","result","join","substr","TabbarItem","_b","_c","isSelected","textColor","iconPath","badgeText","_d","showRedDot","text","onSelect","className","classNames","badgeStyle","position","top","right","dotStyle","onClick","page","Taro","getCurrentPages","shift","onTabItemTap","isVisible","this","h","key","href","class","style","display","src","alt","color","indexCss","STATUS_SHOW","STATUS_HIDE","STATUS_SLIDEOUT","basicTabBarClassName","hideTabBarClassName","hideTabBarWithAnimationClassName","Tabbar","exports","class_1","hostRef","_this","homePage","customRoutes","tabbarPos","getOriginUrl","customRoute","filter","customUrl","pathA","pathB","getSelectedIndex","foundIndex","forEach","idx","switchTab","selectedIndex","switchTabHandler","successHandler","errorHandler","currentUrl","getCurrentUrl","nextTab","errMsg","routerChangeHandler","options","_a","toLocation","currentPage","routerBasename","conf","setTabBarBadgeHandler","__spreadArray","removeTabBarBadgeHandler","showTabBarRedDotHandler","hideTabBarRedDotHandler","showTabBarHandler","status","hideTabBarHandler","animation","setTabBarStyleHandler","selectedColor","backgroundColor","borderStyle","setTabBarItemHandler","selectedIconPath","Object","prototype","toString","call","Error","this_1","push","apply","map","p","item","routePath","mode","decodeURI","bindEvent","eventCenter","on","removeEvent","off","componentDidLoad","tabbar","nextElementSibling","disconnectedCallback","render","containerCls","shouldHideTabBar","shouldSlideout","Host","height","bind"],"sources":["src/utils/url.ts","../taro-router/dist/utils/index.js","../../node_modules/.pnpm/registry.npmjs.org+resolve-pathname@3.0.0/node_modules/resolve-pathname/esm/resolve-pathname.js","src/components/tabbar/tabbar-item.tsx","src/components/tabbar/style/index.scss?tag=taro-tabbar","src/components/tabbar/tabbar.tsx"],"sourcesContent":["export const normalizePath = url => {\n let _isRelative\n let _leadingParents = ''\n let _parent, _pos\n\n // handle relative paths\n if (url.charAt(0) !== '/') {\n _isRelative = true\n url = '/' + url\n }\n\n // handle relative files (as opposed to directories)\n if (url.substring(-3) === '/..' || url.slice(-2) === '/.') {\n url += '/'\n }\n\n // resolve simples\n url = url.replace(/(\\/(\\.\\/)+)|(\\/\\.$)/g, '/').replace(/\\/{2,}/g, '/')\n\n // remember leading parents\n if (_isRelative) {\n _leadingParents = url.substring(1).match(/^(\\.\\.\\/)+/) || ''\n if (_leadingParents) {\n _leadingParents = _leadingParents[0]\n }\n }\n\n // resolve parents\n while (true) {\n _parent = url.search(/\\/\\.\\.(\\/|$)/)\n if (_parent === -1) {\n // no more ../ to resolve\n break\n } else if (_parent === 0) {\n // top level cannot be relative, skip it\n url = url.substring(3)\n continue\n }\n\n _pos = url.substring(0, _parent).lastIndexOf('/')\n if (_pos === -1) {\n _pos = _parent\n }\n url = url.substring(0, _pos) + url.substring(_parent + 3)\n }\n\n // revert to relative\n if (_isRelative) {\n url = _leadingParents + url.substring(1)\n }\n\n return url\n}\n\nexport const splitUrl = _url => {\n let url = _url || ''\n let pos\n const res = {\n path: null,\n query: null,\n fragment: null\n }\n\n pos = url.indexOf('#')\n if (pos > -1) {\n res.fragment = url.substring(pos + 1)\n url = url.substring(0, pos)\n }\n\n pos = url.indexOf('?')\n if (pos > -1) {\n res.query = url.substring(pos + 1)\n url = url.substring(0, pos)\n }\n\n res.path = url\n\n return res\n}\n","// export const removeLeadingSlash = (str = '') => str.replace(/^\\.?\\//, '')\n// export const removeTrailingSearch = (str = '') => str.replace(/\\?[\\s\\S]*$/, '')\nexport const addLeadingSlash = (url = '') => (url.charAt(0) === '/' ? url : '/' + url);\nexport const hasBasename = (path = '', prefix = '') => new RegExp('^' + prefix + '(\\\\/|\\\\?|#|$)', 'i').test(path) || path === prefix;\nexport const stripBasename = (path = '', prefix = '') => hasBasename(path, prefix) ? path.substring(prefix.length) : path;\nexport const stripTrailing = (str = '') => str.replace(/[?#][\\s\\S]*$/, '');\nexport const stripSuffix = (path = '', suffix = '') => path.includes(suffix) ? path.substring(0, path.length - suffix.length) : path;\nexport const getHomePage = (path = '', basename = '', customRoutes = {}, entryPagePath = '') => {\n var _a;\n const routePath = addLeadingSlash(stripBasename(path, basename));\n const alias = ((_a = Object.entries(customRoutes).find(([key]) => key === routePath)) === null || _a === void 0 ? void 0 : _a[1]) || routePath;\n return entryPagePath || (typeof alias === 'string' ? alias : alias[0]) || basename;\n};\nexport const getCurrentPage = (routerMode = 'hash', basename = '/') => {\n const pagePath = routerMode === 'hash'\n ? location.hash.slice(1).split('?')[0]\n : location.pathname;\n return addLeadingSlash(stripBasename(pagePath, basename));\n};\nclass RoutesAlias {\n constructor() {\n this.conf = [];\n this.getConfig = (url = '') => {\n const customRoute = this.conf.filter((arr) => {\n return arr.includes(url);\n });\n return customRoute[0];\n };\n this.getOrigin = (url = '') => {\n var _a;\n return ((_a = this.getConfig(url)) === null || _a === void 0 ? void 0 : _a[0]) || url;\n };\n this.getAlias = (url = '') => {\n var _a;\n return ((_a = this.getConfig(url)) === null || _a === void 0 ? void 0 : _a[1]) || url;\n };\n this.getAll = (url = '') => {\n return this.conf\n .filter((arr) => arr.includes(url))\n .reduceRight((p, a) => {\n p.unshift(a[1]);\n return p;\n }, []);\n };\n }\n set(customRoutes = {}) {\n for (let key in customRoutes) {\n const path = customRoutes[key];\n key = addLeadingSlash(key);\n if (typeof path === 'string') {\n this.conf.push([key, addLeadingSlash(path)]);\n }\n else if ((path === null || path === void 0 ? void 0 : path.length) > 0) {\n this.conf.push(...path.map(p => [key, addLeadingSlash(p)]));\n }\n }\n }\n}\nexport const routesAlias = new RoutesAlias();\n","function isAbsolute(pathname) {\n return pathname.charAt(0) === '/';\n}\n\n// About 1.5x faster than the two-arg version of Array#splice()\nfunction spliceOne(list, index) {\n for (var i = index, k = i + 1, n = list.length; k < n; i += 1, k += 1) {\n list[i] = list[k];\n }\n\n list.pop();\n}\n\n// This implementation is based heavily on node's url.parse\nfunction resolvePathname(to, from) {\n if (from === undefined) from = '';\n\n var toParts = (to && to.split('/')) || [];\n var fromParts = (from && from.split('/')) || [];\n\n var isToAbs = to && isAbsolute(to);\n var isFromAbs = from && isAbsolute(from);\n var mustEndAbs = isToAbs || isFromAbs;\n\n if (to && isAbsolute(to)) {\n // to is absolute\n fromParts = toParts;\n } else if (toParts.length) {\n // to is relative, drop the filename\n fromParts.pop();\n fromParts = fromParts.concat(toParts);\n }\n\n if (!fromParts.length) return '/';\n\n var hasTrailingSlash;\n if (fromParts.length) {\n var last = fromParts[fromParts.length - 1];\n hasTrailingSlash = last === '.' || last === '..' || last === '';\n } else {\n hasTrailingSlash = false;\n }\n\n var up = 0;\n for (var i = fromParts.length; i >= 0; i--) {\n var part = fromParts[i];\n\n if (part === '.') {\n spliceOne(fromParts, i);\n } else if (part === '..') {\n spliceOne(fromParts, i);\n up++;\n } else if (up) {\n spliceOne(fromParts, i);\n up--;\n }\n }\n\n if (!mustEndAbs) for (; up--; up) fromParts.unshift('..');\n\n if (\n mustEndAbs &&\n fromParts[0] !== '' &&\n (!fromParts[0] || !isAbsolute(fromParts[0]))\n )\n fromParts.unshift('');\n\n var result = fromParts.join('/');\n\n if (hasTrailingSlash && result.substr(-1) !== '/') result += '/';\n\n return result;\n}\n\nexport default resolvePathname;\n","import classNames from 'classnames'\nimport { FunctionalComponent, h } from '@stencil/core'\nimport Taro from '@tarojs/taro'\n\nimport { isVisible } from '../../utils'\n\ntype TabbarItemProps = {\n index: number\n isSelected?: boolean\n textColor?: string\n badgeText?: string\n iconPath: string\n showRedDot?: boolean\n pagePath?: string\n text?: string\n onSelect: (index: number) => void\n}\n\nexport const TabbarItem: FunctionalComponent<TabbarItemProps> = ({\n index,\n isSelected = false,\n textColor,\n iconPath,\n badgeText,\n showRedDot = false,\n pagePath,\n text,\n onSelect\n}) => {\n const className = classNames('weui-tabbar__item', {\n 'weui-bar__item_on': isSelected\n })\n const badgeStyle = {\n position: 'absolute',\n top: '-2px',\n right: '-13px'\n }\n const dotStyle = {\n position: 'absolute',\n top: '0',\n right: '-6px'\n }\n\n function onClick () {\n const page = Taro.getCurrentPages().shift()\n if (typeof page?.onTabItemTap === 'function' && isVisible(this)) {\n page.onTabItemTap({ index, pagePath, text })\n }\n onSelect(index)\n }\n\n return (\n <a key={index} href='javascript:;' class={className} onClick={onClick}>\n <span style={{ display: 'inline-block', position: 'relative' }}>\n <img src={iconPath} alt='' class='weui-tabbar__icon' />\n {!!badgeText && (\n <span\n class='weui-badge taro-tabbar-badge'\n style={badgeStyle}>\n {badgeText}\n </span>\n )}\n {showRedDot && (\n <span\n class='weui-badge weui-badge_dot'\n style={dotStyle}\n />\n )}\n </span>\n <p class='weui-tabbar__label' style={{ color: textColor }}>\n {text}\n </p>\n </a>\n )\n}\n","html,\nbody {\n height: 100%;\n}\n\n#app {\n height: 100%;\n}\n\n.taro-tabbar {\n &__border {\n &-white {\n &::before {\n border-top-color: #fff !important;\n }\n }\n }\n\n &__container {\n display: flex;\n overflow: hidden;\n flex-direction: column;\n height: 100%;\n }\n\n &__panel {\n overflow: auto;\n position: relative;\n flex: 1;\n -webkit-overflow-scrolling: auto;\n }\n\n &__tabbar {\n position: relative;\n width: 100%;\n height: 50px;\n transition: bottom 0.2s, top 0.2s;\n\n &-top {\n top: 0;\n }\n\n &-bottom {\n bottom: 0;\n margin-bottom: constant(safe-area-inset-bottom);\n margin-bottom: env(safe-area-inset-bottom);\n }\n\n &-hide {\n display: none;\n }\n\n &-slideout {\n top: -52px;\n flex: 0 0;\n }\n }\n\n &__panel + &__tabbar-slideout {\n top: auto;\n bottom: -52px;\n }\n}\n","import { Component, Prop, h, ComponentInterface, Host, State, Event, EventEmitter, Element } from '@stencil/core'\nimport Taro from '@tarojs/taro'\nimport { addLeadingSlash, getCurrentPage, stripBasename, stripSuffix } from '@tarojs/router/dist/utils'\nimport { IH5RouterConfig } from '@tarojs/taro/types/compile'\nimport classNames from 'classnames'\nimport resolvePathname from 'resolve-pathname'\n\nimport { splitUrl } from '../../utils'\nimport { TabbarItem } from './tabbar-item'\n\nconst STATUS_SHOW = 0\nconst STATUS_HIDE = 1\nconst STATUS_SLIDEOUT = 2\n\nconst basicTabBarClassName = 'taro-tabbar__tabbar'\nconst hideTabBarClassName = 'taro-tabbar__tabbar-hide'\nconst hideTabBarWithAnimationClassName = 'taro-tabbar__tabbar-slideout'\n\ninterface RouterHandler {\n index: string\n text: string\n url: string\n successHandler: Function\n errorHandler: Function\n animation?: boolean\n}\n\nexport interface Conf {\n color: string\n selectedColor: string\n backgroundColor: string\n borderStyle?: 'black' | 'white'\n list: TabbarList[]\n position?: 'bottom' | 'top'\n custom: boolean\n customRoutes: Record<string, string | string[]>\n mode: IH5RouterConfig['mode']\n basename: string\n homePage: string\n currentPagename: string\n}\n\ninterface TabbarList {\n pagePath: string\n text: string\n iconPath?: string\n selectedIconPath?: string\n badgeText?: string\n showRedDot?: boolean\n}\n\n@Component({\n tag: 'taro-tabbar',\n styleUrl: './style/index.scss'\n})\nexport class Tabbar implements ComponentInterface {\n private homePage = ''\n\n private customRoutes: Array<string[]> = []\n\n private tabbarPos: 'top' | 'bottom' = 'bottom'\n\n @Prop() conf: Conf\n\n @State() list: TabbarList[]\n\n @State() borderStyle: Conf['borderStyle']\n\n @State() backgroundColor: Conf['backgroundColor']\n\n @State() color: Conf['color']\n\n @State() selectedColor: Conf['selectedColor']\n\n @State() selectedIndex = -1\n\n @State() status: 0 | 1 | 2 = STATUS_SHOW\n\n @Event({\n eventName: 'longpress'\n }) onLongPress: EventEmitter\n\n @Element() tabbar: HTMLDivElement\n\n constructor () {\n const list = this.conf.list\n const customRoutes = this.conf.customRoutes\n if (\n Object.prototype.toString.call(list) !== '[object Array]' ||\n list.length < 2 ||\n list.length > 5\n ) {\n throw new Error('tabBar 配置错误')\n }\n\n this.homePage = addLeadingSlash(this.conf.homePage)\n for (let key in customRoutes) {\n const path = customRoutes[key]\n key = addLeadingSlash(key)\n if (typeof path === 'string') {\n this.customRoutes.push([key, addLeadingSlash(path)])\n } else if (path?.length > 0) {\n this.customRoutes.push(...path.map(p => [key, addLeadingSlash(p)]))\n }\n }\n\n list.forEach(item => {\n if (item.pagePath.indexOf('/') !== 0) {\n item.pagePath = '/' + item.pagePath\n }\n })\n\n this.list = list\n this.borderStyle = this.conf.borderStyle\n this.backgroundColor = this.conf.backgroundColor\n this.color = this.conf.color\n this.selectedColor = this.conf.selectedColor\n }\n\n getCurrentUrl () {\n const routePath = getCurrentPage(this.conf.mode, this.conf.basename)\n return decodeURI(routePath === '/' ? this.homePage : routePath)\n }\n\n getOriginUrl = (url: string) => {\n const customRoute = this.customRoutes.filter(([, customUrl]) => {\n const pathA = splitUrl(customUrl).path\n const pathB = splitUrl(url).path\n return pathA === pathB\n })\n return stripSuffix(customRoute.length ? customRoute[0][0] : url, '.html')\n }\n\n getSelectedIndex = (url: string) => {\n let foundIndex = -1\n this.list.forEach(({ pagePath }, idx) => {\n const pathA = splitUrl(url).path\n const pathB = splitUrl(pagePath).path\n if (pathA === pathB) {\n foundIndex = idx\n }\n })\n return foundIndex\n }\n\n switchTab = (index: number) => {\n this.selectedIndex = index\n Taro.switchTab({\n url: this.list[index].pagePath\n })\n }\n\n switchTabHandler = ({ url, successHandler, errorHandler }: RouterHandler) => {\n const currentUrl = this.getOriginUrl(this.getCurrentUrl() || this.homePage)\n const nextTab = resolvePathname(url, currentUrl)\n const foundIndex = this.getSelectedIndex(nextTab)\n\n if (foundIndex > -1) {\n this.switchTab(foundIndex)\n successHandler({\n errMsg: 'switchTab:ok'\n })\n } else {\n errorHandler({\n errMsg: `switchTab:fail page \"${nextTab}\" is not found`\n })\n }\n }\n\n routerChangeHandler = (options?) => {\n const to = options?.toLocation?.path\n let currentPage\n\n if (typeof to === 'string') {\n const routerBasename = this.conf.basename || '/'\n currentPage = stripBasename(addLeadingSlash(to || this.homePage), routerBasename) || '/'\n } else {\n currentPage = this.getCurrentUrl()\n }\n\n this.selectedIndex = this.getSelectedIndex(this.getOriginUrl(currentPage))\n }\n\n setTabBarBadgeHandler = ({ index, text, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].showRedDot = false\n list[index].badgeText = text\n successHandler({\n errMsg: 'setTabBarBadge:ok'\n })\n } else {\n errorHandler({\n errMsg: 'setTabBarBadge:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n removeTabBarBadgeHandler = ({ index, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].badgeText = null\n list[index].badgeText = null\n successHandler({\n errMsg: 'removeTabBarBadge:ok'\n })\n } else {\n errorHandler({\n errMsg: 'removeTabBarBadge:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n showTabBarRedDotHandler = ({ index, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].badgeText = null\n list[index].showRedDot = true\n successHandler({\n errMsg: 'showTabBarRedDot:ok'\n })\n } else {\n errorHandler({\n errMsg: 'showTabBarRedDot:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n hideTabBarRedDotHandler = ({ index, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].showRedDot = false\n successHandler({\n errMsg: 'hideTabBarRedDot:ok'\n })\n } else {\n errorHandler({\n errMsg: 'hideTabBarRedDot:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n showTabBarHandler = ({ successHandler }) => {\n this.status = STATUS_SHOW\n successHandler({\n errMsg: 'showTabBar:ok'\n })\n }\n\n hideTabBarHandler = ({ animation, successHandler }) => {\n this.status = animation ? STATUS_SLIDEOUT : STATUS_HIDE\n successHandler({\n errMsg: 'hideTabBar:ok'\n })\n }\n\n setTabBarStyleHandler = ({ color, selectedColor, backgroundColor, borderStyle, successHandler }) => {\n if (backgroundColor) this.backgroundColor = backgroundColor\n if (borderStyle) this.borderStyle = borderStyle\n if (color) this.color = color\n if (selectedColor) this.selectedColor = selectedColor\n successHandler({\n errMsg: 'setTabBarStyle:ok'\n })\n }\n\n setTabBarItemHandler = ({ index, iconPath, selectedIconPath, text, successHandler, errorHandler }) => {\n const list = [...this.list]\n if (index in list) {\n if (iconPath) list[index].iconPath = iconPath\n if (selectedIconPath) list[index].selectedIconPath = selectedIconPath\n if (text) list[index].text = text\n successHandler({\n errMsg: 'setTabBarItem:ok'\n })\n } else {\n errorHandler({\n errMsg: 'setTabBarItem:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n bindEvent () {\n Taro.eventCenter.on('__taroRouterChange', this.routerChangeHandler)\n Taro.eventCenter.on('__taroSwitchTab', this.switchTabHandler)\n Taro.eventCenter.on('__taroSetTabBarBadge', this.setTabBarBadgeHandler)\n Taro.eventCenter.on('__taroRemoveTabBarBadge', this.removeTabBarBadgeHandler)\n Taro.eventCenter.on('__taroShowTabBarRedDotHandler', this.showTabBarRedDotHandler)\n Taro.eventCenter.on('__taroHideTabBarRedDotHandler', this.hideTabBarRedDotHandler)\n Taro.eventCenter.on('__taroShowTabBar', this.showTabBarHandler)\n Taro.eventCenter.on('__taroHideTabBar', this.hideTabBarHandler)\n Taro.eventCenter.on('__taroSetTabBarStyle', this.setTabBarStyleHandler)\n Taro.eventCenter.on('__taroSetTabBarItem', this.setTabBarItemHandler)\n }\n\n removeEvent () {\n Taro.eventCenter.off('__taroRouterChange', this.routerChangeHandler)\n Taro.eventCenter.off('__taroSwitchTab', this.switchTabHandler)\n Taro.eventCenter.off('__taroSetTabBarBadge', this.setTabBarBadgeHandler)\n Taro.eventCenter.off('__taroRemoveTabBarBadge', this.removeTabBarBadgeHandler)\n Taro.eventCenter.off('__taroShowTabBarRedDotHandler', this.showTabBarRedDotHandler)\n Taro.eventCenter.off('__taroHideTabBarRedDotHandler', this.hideTabBarRedDotHandler)\n Taro.eventCenter.off('__taroShowTabBar', this.showTabBarHandler)\n Taro.eventCenter.off('__taroHideTabBar', this.hideTabBarHandler)\n Taro.eventCenter.off('__taroSetTabBarStyle', this.setTabBarStyleHandler)\n Taro.eventCenter.off('__taroSetTabBarItem', this.setTabBarItemHandler)\n }\n\n componentDidLoad () {\n this.tabbarPos = this.tabbar.nextElementSibling ? 'top' : 'bottom'\n this.bindEvent()\n this.routerChangeHandler()\n }\n\n disconnectedCallback () {\n this.removeEvent()\n }\n\n render () {\n const { tabbarPos = 'bottom' } = this\n const status = this.status\n const containerCls = classNames('weui-tabbar', {\n [`taro-tabbar__border-${this.borderStyle || 'black'}`]: true\n })\n const shouldHideTabBar = this.selectedIndex === -1 || status === STATUS_HIDE\n const shouldSlideout = status === STATUS_SLIDEOUT\n\n return (\n <Host\n class={classNames(\n basicTabBarClassName,\n `${basicTabBarClassName}-${tabbarPos}`, {\n [hideTabBarClassName]: shouldHideTabBar,\n [hideTabBarWithAnimationClassName]: shouldSlideout\n })} >\n <div\n class={containerCls}\n style={{\n backgroundColor: this.backgroundColor || '',\n height: 'inherit'\n }}\n >\n {this.list.map((item, index) => {\n const isSelected = this.selectedIndex === index\n let textColor\n let iconPath\n if (isSelected) {\n textColor = this.selectedColor || ''\n iconPath = item.selectedIconPath\n } else {\n textColor = this.color || ''\n iconPath = item.iconPath\n }\n return (\n <TabbarItem\n index={index}\n onSelect={this.switchTab.bind(this)}\n isSelected={isSelected}\n textColor={textColor}\n iconPath={iconPath}\n pagePath={item.pagePath}\n text={item.text}\n badgeText={item.badgeText}\n showRedDot={item.showRedDot}\n />\n )\n })}\n </div>\n </Host>\n )\n }\n}\n"],"mappings":"0hBAsDO,IAAMA,EAAW,SAAAC,GACtB,IAAIC,EAAMD,GAAQ,GAClB,IAAIE,EACJ,IAAMC,EAAM,CACVC,KAAM,KACNC,MAAO,KACPC,SAAU,MAGZJ,EAAMD,EAAIM,QAAQ,KAClB,GAAIL,GAAO,EAAG,CACZC,EAAIG,SAAWL,EAAIO,UAAUN,EAAM,GACnCD,EAAMA,EAAIO,UAAU,EAAGN,E,CAGzBA,EAAMD,EAAIM,QAAQ,KAClB,GAAIL,GAAO,EAAG,CACZC,EAAIE,MAAQJ,EAAIO,UAAUN,EAAM,GAChCD,EAAMA,EAAIO,UAAU,EAAGN,E,CAGzBC,EAAIC,KAAOH,EAEX,OAAOE,CACT,EC5EO,IAAMM,EAAkB,SAACR,GAAA,GAAAA,SAAA,GAAAA,EAAA,EAAQ,QAAMA,EAAIS,OAAO,KAAO,IAAMT,EAAM,IAAMA,CAA1C,EACjC,IAAMU,EAAc,SAACP,EAAWQ,GAAX,GAAAR,SAAA,GAAAA,EAAA,EAAS,CAAE,GAAAQ,SAAA,GAAAA,EAAA,EAAW,CAAK,WAAIC,OAAO,IAAMD,EAAS,gBAAiB,KAAKE,KAAKV,IAASA,IAASQ,CAAvE,EAChD,IAAMG,EAAgB,SAACX,EAAWQ,GAAX,GAAAR,SAAA,GAAAA,EAAA,EAAS,CAAE,GAAAQ,SAAA,GAAAA,EAAA,EAAW,CAAK,OAAAD,EAAYP,EAAMQ,GAAUR,EAAKI,UAAUI,EAAOI,QAAUZ,CAA5D,EAElD,IAAMa,EAAc,SAACb,EAAW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,IAAW/C,EAAA,GACpCA,EAACsC,GAAsB4E,EACvBlH,EAACuC,GAAmC4E,E,KAExC3F,EAAA,OACEG,MAAOsF,EACPrF,MAAO,CACLyD,gBAAiB9D,KAAK8D,iBAAmB,GACzCgC,OAAQ,YAGT9F,KAAKjD,KAAK2H,KAAI,SAACE,EAAM5H,GACpB,IAAM0B,EAAa2C,EAAKe,gBAAkBpF,EAC1C,IAAI2B,EACJ,IAAIC,EACJ,GAAIF,EAAY,CACdC,EAAY0C,EAAKwC,eAAiB,GAClCjF,EAAWgG,EAAKX,gB,KACX,CACLtF,EAAY0C,EAAKZ,OAAS,GAC1B7B,EAAWgG,EAAKhG,Q,CAElB,OACEqB,EAAC1B,EAAU,CACTvB,MAAOA,EACPiC,SAAUoC,EAAKc,UAAU4D,KAAK1E,GAC9B3C,WAAYA,EACZC,UAAWA,EACXC,SAAUA,EACVrC,SAAUqI,EAAKrI,SACfyC,KAAM4F,EAAK5F,KACXH,UAAW+F,EAAK/F,UAChBE,WAAY6F,EAAK7F,Y,gIA9Td,I"}
@@ -1,2 +1,2 @@
1
- import{p as e,b as o}from"./p-78e3ebb9.js";export{s as setNonce}from"./p-78e3ebb9.js";const r=()=>{const o=import.meta.url;const r={};if(o!==""){r.resourcesUrl=new URL(".",o).href}return e(r)};r().then((e=>o(JSON.parse('[["p-b313c11a",[[4,"taro-checkbox-core",{"name":[1],"value":[1],"color":[1],"id":[1025],"checked":[4],"disabled":[4],"nativeProps":[16],"isWillLoadCalled":[32]}],[0,"taro-checkbox-group-core",{"name":[8]},[[0,"checkboxchange","function"]]]]],["p-7a2f11dc",[[0,"taro-movable-area-core",{"scaleArea":[4,"scale-area"]}],[0,"taro-movable-view-core",{"x":[8],"y":[8],"direction":[1],"outOfBounds":[4,"out-of-bounds"],"inertia":[4],"friction":[2],"damping":[2],"disabled":[4],"scale":[4],"scaleMin":[2,"scale-min"],"scaleMax":[2,"scale-max"],"scaleValue":[2,"scale-value"],"animation":[4],"setParent":[64],"endScale":[64],"setScale":[64]}]]],["p-8625c29c",[[0,"taro-picker-view-column-core",{"col":[1],"initialPosition":[1,"initial-position"],"paddingVertical":[2,"padding-vertical"],"isInit":[32],"isMove":[32]},[[1,"scroll","onScroll"],[1,"mouseup","onMouseEnd"],[1,"mouseout","onMouseEnd"],[1,"mouseleave","onMouseEnd"],[1,"touchend","onTouchEnd"]]],[4,"taro-picker-view-core",{"indicatorStyle":[1,"indicator-style"],"indicatorClass":[1,"indicator-class"],"value":[16],"maskStyle":[1,"mask-style"],"maskClass":[1,"mask-class"]},[[0,"onselect","onSelect"],[0,"onselectstart","onSelectStart"],[0,"onselectend","onPickerColEnd"]]]]],["p-8594d1e5",[[4,"taro-radio-core",{"name":[1],"value":[1],"id":[1025],"checked":[1540],"disabled":[4],"nativeProps":[16],"isWillLoadCalled":[32]}],[0,"taro-radio-group-core",{"name":[8]},[[0,"radiochange","function"]]]]],["p-c1c0e16d",[[4,"taro-swiper-core",{"indicatorDots":[4,"indicator-dots"],"indicatorColor":[1,"indicator-color"],"indicatorActiveColor":[1,"indicator-active-color"],"autoplay":[4],"current":[2],"interval":[2],"duration":[2],"circular":[4],"vertical":[4],"previousMargin":[1,"previous-margin"],"nextMargin":[1,"next-margin"],"displayMultipleItems":[2,"display-multiple-items"],"full":[4],"zoom":[4],"swiperWrapper":[32],"swiper":[32],"isWillLoadCalled":[32],"observer":[32],"observerFirst":[32],"observerLast":[32]}],[0,"taro-swiper-item-core",{"itemId":[1,"item-id"]}]]],["p-c0bb8610",[[0,"taro-ad-core"]]],["p-4a462c95",[[0,"taro-ad-custom-core"]]],["p-7c6f0d5c",[[0,"taro-animation-video-core"]]],["p-66b07ac0",[[0,"taro-animation-view-core"]]],["p-8425ff09",[[0,"taro-ar-camera-core"]]],["p-91f8cd40",[[0,"taro-audio-core",{"src":[1],"controls":[4],"autoplay":[4],"loop":[4],"muted":[4],"nativeProps":[16]}]]],["p-09db02e6",[[0,"taro-aweme-data-core"]]],["p-24c2fd23",[[0,"taro-block-core"]]],["p-d562aae3",[[4,"taro-button-core",{"disabled":[4],"hoverClass":[1,"hover-class"],"type":[1],"hoverStartTime":[2,"hover-start-time"],"hoverStayTime":[2,"hover-stay-time"],"size":[1],"plain":[4],"loading":[4],"formType":[513,"form-type"],"hover":[32],"touch":[32]},[[0,"click","onClick"],[1,"touchstart","onTouchStart"],[1,"touchend","onTouchEnd"]]]]],["p-0accc602",[[0,"taro-camera-core"]]],["p-828bd091",[[0,"taro-canvas-core",{"canvasId":[1,"canvas-id"],"nativeProps":[16]}]]],["p-955fbcfa",[[0,"taro-comment-detail-core"]]],["p-281278cf",[[0,"taro-comment-list-core"]]],["p-c2ac8f08",[[0,"taro-contact-button-core"]]],["p-2357313b",[[0,"taro-cover-image-core",{"src":[1],"nativeProps":[16]}]]],["p-b8ba5d0a",[[4,"taro-cover-view-core",{"animation":[1],"hoverClass":[1,"hover-class"],"hoverStartTime":[2,"hover-start-time"],"hoverStayTime":[2,"hover-stay-time"],"hover":[32],"touch":[32]},[[1,"touchstart","onTouchStart"],[1,"touchmove","onTouchMove"],[1,"touchend","onTouchEnd"]]]]],["p-982e431d",[[0,"taro-custom-wrapper-core"]]],["p-19e87e18",[[0,"taro-editor-core"]]],["p-780870eb",[[0,"taro-follow-swan-core"]]],["p-efe31b23",[[4,"taro-form-core",null,[[0,"tarobuttonsubmit","onButtonSubmit"],[0,"tarobuttonreset","onButtonReset"]]]]],["p-3bce88d9",[[0,"taro-functional-page-navigator-core"]]],["p-5f3c65f0",[[0,"taro-icon-core",{"type":[1],"size":[8],"color":[1]}]]],["p-d1d19ce9",[[0,"taro-image-core",{"src":[1],"mode":[1],"lazyLoad":[4,"lazy-load"],"nativeProps":[16],"aspectFillMode":[32]}]]],["p-51caa3f3",[[0,"taro-inline-payment-panel-core"]]],["p-5208792d",[[0,"taro-input-core",{"value":[1025],"type":[1],"password":[4],"placeholder":[1],"disabled":[4],"maxlength":[2],"autoFocus":[516,"focus"],"confirmType":[1,"confirm-type"],"name":[1],"nativeProps":[16],"focus":[64]}]]],["p-adc37a00",[[0,"taro-keyboard-accessory-core"]]],["p-67c3a0ba",[[4,"taro-label-core",{"for":[1]}]]],["p-c50087fd",[[0,"taro-lifestyle-core"]]],["p-a7789ed6",[[0,"taro-like-core"]]],["p-908ddbb0",[[0,"taro-live-player-core"]]],["p-76e6fbff",[[0,"taro-live-pusher-core"]]],["p-c3e98fdf",[[0,"taro-login-core"]]],["p-eb9adf17",[[0,"taro-lottie-core"]]],["p-4bc85eb7",[[0,"taro-map-core"]]],["p-b4419d86",[[0,"taro-match-media-core"]]],["p-7c1fec76",[[0,"taro-native-slot-core"]]],["p-a23a21e1",[[0,"taro-navigation-bar-core"]]],["p-d621d190",[[0,"taro-navigator-core",{"hoverClass":[1,"hover-class"],"url":[1],"openType":[1,"open-type"],"isHover":[4,"is-hover"],"delta":[2]},[[0,"click","onClick"]]]]],["p-6bb1fdf2",[[0,"taro-official-account-core"]]],["p-4263c9d9",[[0,"taro-open-data-core"]]],["p-d61d3394",[[0,"taro-page-container-core"]]],["p-b39b973e",[[0,"taro-page-meta-core"]]],["p-f88f0f55",[[0,"taro-progress-core",{"percent":[2],"showInfo":[4,"show-info"],"borderRadius":[8,"border-radius"],"fontSize":[8,"font-size"],"strokeWidth":[8,"stroke-width"],"activeColor":[1,"active-color"],"backgroundColor":[1,"background-color"],"active":[4]}]]],["p-d8c8c63f",[[4,"taro-pull-to-refresh",{"prefixCls":[1,"prefix-cls"],"distanceToRefresh":[2,"distance-to-refresh"],"damping":[2],"indicator":[16],"currSt":[32],"dragOnEdge":[32]}]]],["p-663e27a0",[[0,"taro-rich-text-core",{"nodes":[1]}]]],["p-603ceecd",[[0,"taro-root-portal-core"]]],["p-3f07f3d3",[[0,"taro-rtc-room-core"]]],["p-386ae2b2",[[0,"taro-rtc-room-item-core"]]],["p-71155a2c",[[4,"taro-scroll-view-core",{"scrollX":[4,"scroll-x"],"scrollY":[4,"scroll-y"],"upperThreshold":[8,"upper-threshold"],"lowerThreshold":[8,"lower-threshold"],"mpScrollTop":[520,"scroll-top"],"mpScrollLeft":[520,"scroll-left"],"mpScrollIntoView":[513,"scroll-into-view"],"scrollWithAnimation":[4,"scroll-with-animation"]},[[3,"scroll","handleScroll"]]]]],["p-e0e4a403",[[0,"taro-share-element-core"]]],["p-93ccd68a",[[0,"taro-slider-core",{"min":[2],"max":[2],"step":[2],"disabled":[4],"value":[1538],"activeColor":[1,"active-color"],"backgroundColor":[1,"background-color"],"blockSize":[2,"block-size"],"blockColor":[1,"block-color"],"showValue":[4,"show-value"],"name":[1],"totalWidth":[32],"touching":[32],"ogX":[32],"touchId":[32],"percent":[32],"ogPercent":[32],"isWillLoadCalled":[32]}]]],["p-03d4de13",[[0,"taro-slot-core"]]],["p-fec6746d",[[0,"taro-switch-core",{"type":[1],"checked":[4],"color":[1],"name":[1],"disabled":[4],"nativeProps":[16],"isChecked":[32],"isWillLoadCalled":[32]}]]],["p-eb2a7609",[[0,"taro-tab-item-core"]]],["p-f5aaaab7",[[0,"taro-tabbar",{"conf":[16],"list":[32],"borderStyle":[32],"backgroundColor":[32],"color":[32],"selectedColor":[32],"selectedIndex":[32],"status":[32]}]]],["p-0faf45d5",[[0,"taro-tabs-core"]]],["p-05f3f84a",[[4,"taro-text-core",{"selectable":[4]}]]],["p-ef4c1fd4",[[0,"taro-textarea-core",{"value":[1025],"placeholder":[1],"disabled":[4],"maxlength":[2],"autoFocus":[4,"auto-focus"],"autoHeight":[4,"auto-height"],"name":[1],"nativeProps":[16],"line":[32],"focus":[64]}]]],["p-e67165fd",[[4,"taro-view-core",{"animation":[1],"hoverClass":[1,"hover-class"],"hoverStartTime":[2,"hover-start-time"],"hoverStayTime":[2,"hover-stay-time"],"hover":[32],"touch":[32]},[[1,"touchstart","onTouchStart"],[1,"touchmove","onTouchMove"],[1,"touchend","onTouchEnd"]]]]],["p-fda82bc1",[[0,"taro-voip-room-core"]]],["p-2049bdc4",[[0,"taro-web-view-core",{"src":[1]}]]],["p-88fbacdb",[[4,"taro-picker-core",{"mode":[1],"disabled":[4],"range":[16],"rangeKey":[1,"range-key"],"value":[1032],"start":[1],"end":[1],"fields":[1],"name":[1],"pickerValue":[32],"height":[32],"hidden":[32],"fadeOut":[32],"isWillLoadCalled":[32]}],[0,"taro-picker-group",{"mode":[1],"range":[16],"rangeKey":[1,"range-key"],"height":[2],"columnId":[1,"column-id"],"updateHeight":[16],"onColumnChange":[16],"updateDay":[16],"startY":[32],"preY":[32],"hadMove":[32],"touchEnd":[32],"isMove":[32],"handleMoveStart":[64],"handleMoving":[64],"handleMoveEnd":[64]},[[1,"mousedown","onMouseDown"],[1,"mousemove","onMouseMove"],[1,"mouseup","onMouseMoveEnd"],[1,"mouseleave","onMouseMoveEnd"],[1,"touchstart","onTouchStart"],[1,"touchmove","onTouchMove"],[1,"touchend","onTouchEnd"]]]]],["p-020bcd8c",[[0,"taro-video-core",{"src":[1],"duration":[2],"controls":[4],"autoplay":[4],"loop":[4],"muted":[4],"initialTime":[2,"initial-time"],"poster":[1],"objectFit":[1,"object-fit"],"showProgress":[4,"show-progress"],"showFullscreenBtn":[4,"show-fullscreen-btn"],"showPlayBtn":[4,"show-play-btn"],"showCenterPlayBtn":[4,"show-center-play-btn"],"showMuteBtn":[4,"show-mute-btn"],"danmuList":[16],"danmuBtn":[4,"danmu-btn"],"enableDanmu":[4,"enable-danmu"],"enablePlayGesture":[4,"enable-play-gesture"],"enableProgressGesture":[4,"enable-progress-gesture"],"vslideGesture":[4,"vslide-gesture"],"vslideGestureInFullscreen":[4,"vslide-gesture-in-fullscreen"],"nativeProps":[16],"_duration":[32],"_enableDanmu":[32],"isPlaying":[32],"isFirst":[32],"isFullScreen":[32],"fullScreenTimestamp":[32],"isMute":[32],"getHlsObject":[64],"play":[64],"pause":[64],"stop":[64],"seek":[64],"requestFullScreen":[64],"exitFullScreen":[64]},[[5,"touchmove","onDocumentTouchMove"],[5,"touchend","onDocumentTouchEnd"],[5,"touchcancel","onDocumentTouchEnd"]]],[4,"taro-video-control",{"controls":[4],"currentTime":[2,"current-time"],"duration":[2],"isPlaying":[4,"is-playing"],"pauseFunc":[16],"playFunc":[16],"seekFunc":[16],"showPlayBtn":[4,"show-play-btn"],"showProgress":[4,"show-progress"],"setProgressBall":[64],"toggleVisibility":[64],"getIsDraggingProgressBall":[64],"setCurrentTime":[64]},[[5,"touchmove","onDocumentTouchMove"],[5,"touchend","onDocumentTouchEnd"],[5,"touchcancel","onDocumentTouchEnd"]]],[0,"taro-video-danmu",{"enable":[4],"danmuList":[32],"sendDanmu":[64],"tick":[64]}]]]]'),e)));
1
+ import{p as e,b as o}from"./p-78e3ebb9.js";export{s as setNonce}from"./p-78e3ebb9.js";const r=()=>{const o=import.meta.url;const r={};if(o!==""){r.resourcesUrl=new URL(".",o).href}return e(r)};r().then((e=>o(JSON.parse('[["p-b313c11a",[[4,"taro-checkbox-core",{"name":[1],"value":[1],"color":[1],"id":[1025],"checked":[4],"disabled":[4],"nativeProps":[16],"isWillLoadCalled":[32]}],[0,"taro-checkbox-group-core",{"name":[8]},[[0,"checkboxchange","function"]]]]],["p-7a2f11dc",[[0,"taro-movable-area-core",{"scaleArea":[4,"scale-area"]}],[0,"taro-movable-view-core",{"x":[8],"y":[8],"direction":[1],"outOfBounds":[4,"out-of-bounds"],"inertia":[4],"friction":[2],"damping":[2],"disabled":[4],"scale":[4],"scaleMin":[2,"scale-min"],"scaleMax":[2,"scale-max"],"scaleValue":[2,"scale-value"],"animation":[4],"setParent":[64],"endScale":[64],"setScale":[64]}]]],["p-8625c29c",[[0,"taro-picker-view-column-core",{"col":[1],"initialPosition":[1,"initial-position"],"paddingVertical":[2,"padding-vertical"],"isInit":[32],"isMove":[32]},[[1,"scroll","onScroll"],[1,"mouseup","onMouseEnd"],[1,"mouseout","onMouseEnd"],[1,"mouseleave","onMouseEnd"],[1,"touchend","onTouchEnd"]]],[4,"taro-picker-view-core",{"indicatorStyle":[1,"indicator-style"],"indicatorClass":[1,"indicator-class"],"value":[16],"maskStyle":[1,"mask-style"],"maskClass":[1,"mask-class"]},[[0,"onselect","onSelect"],[0,"onselectstart","onSelectStart"],[0,"onselectend","onPickerColEnd"]]]]],["p-8594d1e5",[[4,"taro-radio-core",{"name":[1],"value":[1],"id":[1025],"checked":[1540],"disabled":[4],"nativeProps":[16],"isWillLoadCalled":[32]}],[0,"taro-radio-group-core",{"name":[8]},[[0,"radiochange","function"]]]]],["p-c1c0e16d",[[4,"taro-swiper-core",{"indicatorDots":[4,"indicator-dots"],"indicatorColor":[1,"indicator-color"],"indicatorActiveColor":[1,"indicator-active-color"],"autoplay":[4],"current":[2],"interval":[2],"duration":[2],"circular":[4],"vertical":[4],"previousMargin":[1,"previous-margin"],"nextMargin":[1,"next-margin"],"displayMultipleItems":[2,"display-multiple-items"],"full":[4],"zoom":[4],"swiperWrapper":[32],"swiper":[32],"isWillLoadCalled":[32],"observer":[32],"observerFirst":[32],"observerLast":[32]}],[0,"taro-swiper-item-core",{"itemId":[1,"item-id"]}]]],["p-c0bb8610",[[0,"taro-ad-core"]]],["p-4a462c95",[[0,"taro-ad-custom-core"]]],["p-7c6f0d5c",[[0,"taro-animation-video-core"]]],["p-66b07ac0",[[0,"taro-animation-view-core"]]],["p-8425ff09",[[0,"taro-ar-camera-core"]]],["p-91f8cd40",[[0,"taro-audio-core",{"src":[1],"controls":[4],"autoplay":[4],"loop":[4],"muted":[4],"nativeProps":[16]}]]],["p-09db02e6",[[0,"taro-aweme-data-core"]]],["p-24c2fd23",[[0,"taro-block-core"]]],["p-d562aae3",[[4,"taro-button-core",{"disabled":[4],"hoverClass":[1,"hover-class"],"type":[1],"hoverStartTime":[2,"hover-start-time"],"hoverStayTime":[2,"hover-stay-time"],"size":[1],"plain":[4],"loading":[4],"formType":[513,"form-type"],"hover":[32],"touch":[32]},[[0,"click","onClick"],[1,"touchstart","onTouchStart"],[1,"touchend","onTouchEnd"]]]]],["p-0accc602",[[0,"taro-camera-core"]]],["p-828bd091",[[0,"taro-canvas-core",{"canvasId":[1,"canvas-id"],"nativeProps":[16]}]]],["p-955fbcfa",[[0,"taro-comment-detail-core"]]],["p-281278cf",[[0,"taro-comment-list-core"]]],["p-c2ac8f08",[[0,"taro-contact-button-core"]]],["p-2357313b",[[0,"taro-cover-image-core",{"src":[1],"nativeProps":[16]}]]],["p-b8ba5d0a",[[4,"taro-cover-view-core",{"animation":[1],"hoverClass":[1,"hover-class"],"hoverStartTime":[2,"hover-start-time"],"hoverStayTime":[2,"hover-stay-time"],"hover":[32],"touch":[32]},[[1,"touchstart","onTouchStart"],[1,"touchmove","onTouchMove"],[1,"touchend","onTouchEnd"]]]]],["p-982e431d",[[0,"taro-custom-wrapper-core"]]],["p-19e87e18",[[0,"taro-editor-core"]]],["p-780870eb",[[0,"taro-follow-swan-core"]]],["p-efe31b23",[[4,"taro-form-core",null,[[0,"tarobuttonsubmit","onButtonSubmit"],[0,"tarobuttonreset","onButtonReset"]]]]],["p-3bce88d9",[[0,"taro-functional-page-navigator-core"]]],["p-5f3c65f0",[[0,"taro-icon-core",{"type":[1],"size":[8],"color":[1]}]]],["p-d1d19ce9",[[0,"taro-image-core",{"src":[1],"mode":[1],"lazyLoad":[4,"lazy-load"],"nativeProps":[16],"aspectFillMode":[32]}]]],["p-51caa3f3",[[0,"taro-inline-payment-panel-core"]]],["p-5208792d",[[0,"taro-input-core",{"value":[1025],"type":[1],"password":[4],"placeholder":[1],"disabled":[4],"maxlength":[2],"autoFocus":[516,"focus"],"confirmType":[1,"confirm-type"],"name":[1],"nativeProps":[16],"focus":[64]}]]],["p-adc37a00",[[0,"taro-keyboard-accessory-core"]]],["p-67c3a0ba",[[4,"taro-label-core",{"for":[1]}]]],["p-c50087fd",[[0,"taro-lifestyle-core"]]],["p-a7789ed6",[[0,"taro-like-core"]]],["p-908ddbb0",[[0,"taro-live-player-core"]]],["p-76e6fbff",[[0,"taro-live-pusher-core"]]],["p-c3e98fdf",[[0,"taro-login-core"]]],["p-eb9adf17",[[0,"taro-lottie-core"]]],["p-4bc85eb7",[[0,"taro-map-core"]]],["p-b4419d86",[[0,"taro-match-media-core"]]],["p-7c1fec76",[[0,"taro-native-slot-core"]]],["p-a23a21e1",[[0,"taro-navigation-bar-core"]]],["p-d621d190",[[0,"taro-navigator-core",{"hoverClass":[1,"hover-class"],"url":[1],"openType":[1,"open-type"],"isHover":[4,"is-hover"],"delta":[2]},[[0,"click","onClick"]]]]],["p-6bb1fdf2",[[0,"taro-official-account-core"]]],["p-4263c9d9",[[0,"taro-open-data-core"]]],["p-d61d3394",[[0,"taro-page-container-core"]]],["p-b39b973e",[[0,"taro-page-meta-core"]]],["p-f88f0f55",[[0,"taro-progress-core",{"percent":[2],"showInfo":[4,"show-info"],"borderRadius":[8,"border-radius"],"fontSize":[8,"font-size"],"strokeWidth":[8,"stroke-width"],"activeColor":[1,"active-color"],"backgroundColor":[1,"background-color"],"active":[4]}]]],["p-d8c8c63f",[[4,"taro-pull-to-refresh",{"prefixCls":[1,"prefix-cls"],"distanceToRefresh":[2,"distance-to-refresh"],"damping":[2],"indicator":[16],"currSt":[32],"dragOnEdge":[32]}]]],["p-663e27a0",[[0,"taro-rich-text-core",{"nodes":[1]}]]],["p-603ceecd",[[0,"taro-root-portal-core"]]],["p-3f07f3d3",[[0,"taro-rtc-room-core"]]],["p-386ae2b2",[[0,"taro-rtc-room-item-core"]]],["p-71155a2c",[[4,"taro-scroll-view-core",{"scrollX":[4,"scroll-x"],"scrollY":[4,"scroll-y"],"upperThreshold":[8,"upper-threshold"],"lowerThreshold":[8,"lower-threshold"],"mpScrollTop":[520,"scroll-top"],"mpScrollLeft":[520,"scroll-left"],"mpScrollIntoView":[513,"scroll-into-view"],"scrollWithAnimation":[4,"scroll-with-animation"]},[[3,"scroll","handleScroll"]]]]],["p-e0e4a403",[[0,"taro-share-element-core"]]],["p-93ccd68a",[[0,"taro-slider-core",{"min":[2],"max":[2],"step":[2],"disabled":[4],"value":[1538],"activeColor":[1,"active-color"],"backgroundColor":[1,"background-color"],"blockSize":[2,"block-size"],"blockColor":[1,"block-color"],"showValue":[4,"show-value"],"name":[1],"totalWidth":[32],"touching":[32],"ogX":[32],"touchId":[32],"percent":[32],"ogPercent":[32],"isWillLoadCalled":[32]}]]],["p-03d4de13",[[0,"taro-slot-core"]]],["p-fec6746d",[[0,"taro-switch-core",{"type":[1],"checked":[4],"color":[1],"name":[1],"disabled":[4],"nativeProps":[16],"isChecked":[32],"isWillLoadCalled":[32]}]]],["p-eb2a7609",[[0,"taro-tab-item-core"]]],["p-5d3acf86",[[0,"taro-tabbar",{"conf":[16],"list":[32],"borderStyle":[32],"backgroundColor":[32],"color":[32],"selectedColor":[32],"selectedIndex":[32],"status":[32]}]]],["p-0faf45d5",[[0,"taro-tabs-core"]]],["p-05f3f84a",[[4,"taro-text-core",{"selectable":[4]}]]],["p-ef4c1fd4",[[0,"taro-textarea-core",{"value":[1025],"placeholder":[1],"disabled":[4],"maxlength":[2],"autoFocus":[4,"auto-focus"],"autoHeight":[4,"auto-height"],"name":[1],"nativeProps":[16],"line":[32],"focus":[64]}]]],["p-e67165fd",[[4,"taro-view-core",{"animation":[1],"hoverClass":[1,"hover-class"],"hoverStartTime":[2,"hover-start-time"],"hoverStayTime":[2,"hover-stay-time"],"hover":[32],"touch":[32]},[[1,"touchstart","onTouchStart"],[1,"touchmove","onTouchMove"],[1,"touchend","onTouchEnd"]]]]],["p-fda82bc1",[[0,"taro-voip-room-core"]]],["p-2049bdc4",[[0,"taro-web-view-core",{"src":[1]}]]],["p-88fbacdb",[[4,"taro-picker-core",{"mode":[1],"disabled":[4],"range":[16],"rangeKey":[1,"range-key"],"value":[1032],"start":[1],"end":[1],"fields":[1],"name":[1],"pickerValue":[32],"height":[32],"hidden":[32],"fadeOut":[32],"isWillLoadCalled":[32]}],[0,"taro-picker-group",{"mode":[1],"range":[16],"rangeKey":[1,"range-key"],"height":[2],"columnId":[1,"column-id"],"updateHeight":[16],"onColumnChange":[16],"updateDay":[16],"startY":[32],"preY":[32],"hadMove":[32],"touchEnd":[32],"isMove":[32],"handleMoveStart":[64],"handleMoving":[64],"handleMoveEnd":[64]},[[1,"mousedown","onMouseDown"],[1,"mousemove","onMouseMove"],[1,"mouseup","onMouseMoveEnd"],[1,"mouseleave","onMouseMoveEnd"],[1,"touchstart","onTouchStart"],[1,"touchmove","onTouchMove"],[1,"touchend","onTouchEnd"]]]]],["p-020bcd8c",[[0,"taro-video-core",{"src":[1],"duration":[2],"controls":[4],"autoplay":[4],"loop":[4],"muted":[4],"initialTime":[2,"initial-time"],"poster":[1],"objectFit":[1,"object-fit"],"showProgress":[4,"show-progress"],"showFullscreenBtn":[4,"show-fullscreen-btn"],"showPlayBtn":[4,"show-play-btn"],"showCenterPlayBtn":[4,"show-center-play-btn"],"showMuteBtn":[4,"show-mute-btn"],"danmuList":[16],"danmuBtn":[4,"danmu-btn"],"enableDanmu":[4,"enable-danmu"],"enablePlayGesture":[4,"enable-play-gesture"],"enableProgressGesture":[4,"enable-progress-gesture"],"vslideGesture":[4,"vslide-gesture"],"vslideGestureInFullscreen":[4,"vslide-gesture-in-fullscreen"],"nativeProps":[16],"_duration":[32],"_enableDanmu":[32],"isPlaying":[32],"isFirst":[32],"isFullScreen":[32],"fullScreenTimestamp":[32],"isMute":[32],"getHlsObject":[64],"play":[64],"pause":[64],"stop":[64],"seek":[64],"requestFullScreen":[64],"exitFullScreen":[64]},[[5,"touchmove","onDocumentTouchMove"],[5,"touchend","onDocumentTouchEnd"],[5,"touchcancel","onDocumentTouchEnd"]]],[4,"taro-video-control",{"controls":[4],"currentTime":[2,"current-time"],"duration":[2],"isPlaying":[4,"is-playing"],"pauseFunc":[16],"playFunc":[16],"seekFunc":[16],"showPlayBtn":[4,"show-play-btn"],"showProgress":[4,"show-progress"],"setProgressBall":[64],"toggleVisibility":[64],"getIsDraggingProgressBall":[64],"setCurrentTime":[64]},[[5,"touchmove","onDocumentTouchMove"],[5,"touchend","onDocumentTouchEnd"],[5,"touchcancel","onDocumentTouchEnd"]]],[0,"taro-video-danmu",{"enable":[4],"danmuList":[32],"sendDanmu":[64],"tick":[64]}]]]]'),e)));
2
2
  //# sourceMappingURL=taro-components.esm.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tarojs/components",
3
- "version": "3.6.0-beta.3",
3
+ "version": "3.6.0-beta.4",
4
4
  "description": "Taro 组件库",
5
5
  "browser": "dist/index.js",
6
6
  "main:h5": "dist/index.js",
@@ -30,22 +30,22 @@
30
30
  "author": "",
31
31
  "license": "MIT",
32
32
  "dependencies": {
33
+ "@stencil/core": "^2.18.1",
33
34
  "classnames": "^2.2.5",
34
35
  "hls.js": "^1.1.5",
35
36
  "intersection-observer": "^0.7.0",
36
37
  "resolve-pathname": "^3.0.0",
37
38
  "swiper": "6.8.0",
38
39
  "weui": "^1.1.2",
39
- "@tarojs/components-advanced": "3.6.0-beta.3",
40
- "@tarojs/router": "3.6.0-beta.3",
41
- "@tarojs/taro": "3.6.0-beta.3"
40
+ "@tarojs/components-advanced": "3.6.0-beta.4",
41
+ "@tarojs/router": "3.6.0-beta.4",
42
+ "@tarojs/taro": "3.6.0-beta.4"
42
43
  },
43
44
  "devDependencies": {
44
45
  "@babel/generator": "^7.14.5",
45
46
  "@babel/parser": "^7.14.5",
46
47
  "@babel/traverse": "^7.14.5",
47
48
  "@babel/types": "^7.14.5",
48
- "@stencil/core": "^2.18.1",
49
49
  "@stencil/react-output-target": "0.3.1",
50
50
  "@stencil/sass": "^2.0.0",
51
51
  "@stencil/vue-output-target": "0.6.2",
@@ -1,2 +0,0 @@
1
- var __spreadArray=this&&this.__spreadArray||function(e,t,r){if(r||arguments.length===2)for(var a=0,o=t.length,n;a<o;a++){if(n||!(a in t)){if(!n)n=Array.prototype.slice.call(t,0,a);n[a]=t[a]}}return e.concat(n||Array.prototype.slice.call(t))};System.register(["./p-1a0e1932.system.js","@tarojs/taro","./p-61f225ef.system.js","./p-bd5177d3.system.js"],(function(e){"use strict";var t,r,a,o,n,i,s,l;return{setters:[function(e){t=e.h;r=e.r;a=e.c;o=e.H;n=e.g},function(e){i=e.default},function(e){s=e.c},function(e){l=e.i}],execute:function(){var d=function(e){var t=e||"";var r;var a={path:null,query:null,fragment:null};r=t.indexOf("#");if(r>-1){a.fragment=t.substring(r+1);t=t.substring(0,r)}r=t.indexOf("?");if(r>-1){a.query=t.substring(r+1);t=t.substring(0,r)}a.path=t;return a};var b=function(e){if(e===void 0){e=""}return e.charAt(0)==="/"?e:"/"+e};var h=function(e,t){if(e===void 0){e=""}if(t===void 0){t=""}return new RegExp("^"+t+"(\\/|\\?|#|$)","i").test(e)||e===t};var c=function(e,t){if(e===void 0){e=""}if(t===void 0){t=""}return h(e,t)?e.substring(t.length):e};var f=function(e,t){if(e===void 0){e=""}if(t===void 0){t=""}return e.includes(t)?e.substring(0,e.length-t.length):e};function u(e){return e.charAt(0)==="/"}function v(e,t){for(var r=t,a=r+1,o=e.length;a<o;r+=1,a+=1){e[r]=e[a]}e.pop()}function g(e,t){if(t===undefined)t="";var r=e&&e.split("/")||[];var a=t&&t.split("/")||[];var o=e&&u(e);var n=t&&u(t);var i=o||n;if(e&&u(e)){a=r}else if(r.length){a.pop();a=a.concat(r)}if(!a.length)return"/";var s;if(a.length){var l=a[a.length-1];s=l==="."||l===".."||l===""}else{s=false}var d=0;for(var b=a.length;b>=0;b--){var h=a[b];if(h==="."){v(a,b)}else if(h===".."){v(a,b);d++}else if(d){v(a,b);d--}}if(!i)for(;d--;d)a.unshift("..");if(i&&a[0]!==""&&(!a[0]||!u(a[0])))a.unshift("");var c=a.join("/");if(s&&c.substr(-1)!=="/")c+="/";return c}var p=function(e){var r=e.index,a=e.isSelected,o=a===void 0?false:a,n=e.textColor,d=e.iconPath,b=e.badgeText,h=e.showRedDot,c=h===void 0?false:h,f=e.pagePath,u=e.text,v=e.onSelect;var g=s("weui-tabbar__item",{"weui-bar__item_on":o});var p={position:"absolute",top:"-2px",right:"-13px"};var _={position:"absolute",top:"0",right:"-6px"};function m(){var e=i.getCurrentPages().shift();if(typeof(e===null||e===void 0?void 0:e.onTabItemTap)==="function"&&l(this)){e.onTabItemTap({index:r,pagePath:f,text:u})}v(r)}return t("a",{key:r,href:"javascript:;",class:g,onClick:m},t("span",{style:{display:"inline-block",position:"relative"}},t("img",{src:d,alt:"",class:"weui-tabbar__icon"}),!!b&&t("span",{class:"weui-badge taro-tabbar-badge",style:p},b),c&&t("span",{class:"weui-badge weui-badge_dot",style:_})),t("p",{class:"weui-tabbar__label",style:{color:n}},u))};var _="html,body{height:100%}#app{height:100%}.taro-tabbar__border-white::before{border-top-color:#fff !important}.taro-tabbar__container{display:-ms-flexbox;display:flex;overflow:hidden;-ms-flex-direction:column;flex-direction:column;height:100%}.taro-tabbar__panel{overflow:auto;position:relative;-ms-flex:1;flex:1;-webkit-overflow-scrolling:auto}.taro-tabbar__tabbar{position:relative;width:100%;height:50px;-webkit-transition:bottom 0.2s, top 0.2s;transition:bottom 0.2s, top 0.2s}.taro-tabbar__tabbar-top{top:0}.taro-tabbar__tabbar-bottom{bottom:0;margin-bottom:constant(safe-area-inset-bottom);margin-bottom:env(safe-area-inset-bottom)}.taro-tabbar__tabbar-hide{display:none}.taro-tabbar__tabbar-slideout{top:-52px;-ms-flex:0 0;flex:0 0}.taro-tabbar__panel+.taro-tabbar__tabbar-slideout{top:auto;bottom:-52px}";var m=0;var T=1;var B=2;var y="taro-tabbar__tabbar";var H="taro-tabbar__tabbar-hide";var x="taro-tabbar__tabbar-slideout";var w=e("taro_tabbar",function(){function e(e){var t=this;r(this,e);this.onLongPress=a(this,"longpress",7);this.homePage="";this.customRoutes=[];this.tabbarPos="bottom";this.getOriginUrl=function(e){var r=t.customRoutes.filter((function(t){var r=t[1];var a=d(r).path;var o=d(e).path;return a===o}));return f(r.length?r[0][0]:e,".html")};this.getSelectedIndex=function(e){var r=-1;t.list.forEach((function(t,a){var o=t.pagePath;var n=d(e).path;var i=d(o).path;if(n===i){r=a}}));return r};this.switchTab=function(e){t.selectedIndex=e;i.switchTab({url:t.list[e].pagePath})};this.switchTabHandler=function(e){var r=e.url,a=e.successHandler,o=e.errorHandler;var n=t.getOriginUrl(t.getCurrentUrl()||t.homePage);var i=g(r,n);var s=t.getSelectedIndex(i);if(s>-1){t.switchTab(s);a({errMsg:"switchTab:ok"})}else{o({errMsg:'switchTab:fail page "'.concat(i,'" is not found')})}};this.routerChangeHandler=function(e){var r;var a=(r=e===null||e===void 0?void 0:e.toLocation)===null||r===void 0?void 0:r.path;var o;if(typeof a==="string"){var n=t.conf.basename||"/";o=c(b(a||t.homePage),n)||"/"}else{o=t.getCurrentUrl()}t.selectedIndex=t.getSelectedIndex(t.getOriginUrl(o))};this.setTabBarBadgeHandler=function(e){var r=e.index,a=e.text,o=e.successHandler,n=e.errorHandler;var i=__spreadArray([],t.list,true);if(r in i){i[r].showRedDot=false;i[r].badgeText=a;o({errMsg:"setTabBarBadge:ok"})}else{n({errMsg:"setTabBarBadge:fail tabbar item not found"})}t.list=i};this.removeTabBarBadgeHandler=function(e){var r=e.index,a=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(r in n){n[r].badgeText=null;n[r].badgeText=null;a({errMsg:"removeTabBarBadge:ok"})}else{o({errMsg:"removeTabBarBadge:fail tabbar item not found"})}t.list=n};this.showTabBarRedDotHandler=function(e){var r=e.index,a=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(r in n){n[r].badgeText=null;n[r].showRedDot=true;a({errMsg:"showTabBarRedDot:ok"})}else{o({errMsg:"showTabBarRedDot:fail tabbar item not found"})}t.list=n};this.hideTabBarRedDotHandler=function(e){var r=e.index,a=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(r in n){n[r].showRedDot=false;a({errMsg:"hideTabBarRedDot:ok"})}else{o({errMsg:"hideTabBarRedDot:fail tabbar item not found"})}t.list=n};this.showTabBarHandler=function(e){var r=e.successHandler;t.status=m;r({errMsg:"showTabBar:ok"})};this.hideTabBarHandler=function(e){var r=e.animation,a=e.successHandler;t.status=r?B:T;a({errMsg:"hideTabBar:ok"})};this.setTabBarStyleHandler=function(e){var r=e.color,a=e.selectedColor,o=e.backgroundColor,n=e.borderStyle,i=e.successHandler;if(o)t.backgroundColor=o;if(n)t.borderStyle=n;if(r)t.color=r;if(a)t.selectedColor=a;i({errMsg:"setTabBarStyle:ok"})};this.setTabBarItemHandler=function(e){var r=e.index,a=e.iconPath,o=e.selectedIconPath,n=e.text,i=e.successHandler,s=e.errorHandler;var l=__spreadArray([],t.list,true);if(r in l){if(a)l[r].iconPath=a;if(o)l[r].selectedIconPath=o;if(n)l[r].text=n;i({errMsg:"setTabBarItem:ok"})}else{s({errMsg:"setTabBarItem:fail tabbar item not found"})}t.list=l};this.conf=undefined;this.list=undefined;this.borderStyle=undefined;this.backgroundColor=undefined;this.color=undefined;this.selectedColor=undefined;this.selectedIndex=-1;this.status=m;var o=this.conf.list;var n=this.conf.customRoutes;if(Object.prototype.toString.call(o)!=="[object Array]"||o.length<2||o.length>5){throw new Error("tabBar 配置错误")}this.homePage=b(this.conf.homePage);var s=function(e){var t;var r=n[e];e=b(e);if(typeof r==="string"){l.customRoutes.push([e,b(r)])}else if((r===null||r===void 0?void 0:r.length)>0){(t=l.customRoutes).push.apply(t,r.map((function(t){return[e,b(t)]})))}};var l=this;for(var h in n){s(h)}o.forEach((function(e){if(e.pagePath.indexOf("/")!==0){e.pagePath="/"+e.pagePath}}));this.list=o;this.borderStyle=this.conf.borderStyle;this.backgroundColor=this.conf.backgroundColor;this.color=this.conf.color;this.selectedColor=this.conf.selectedColor}e.prototype.getCurrentUrl=function(){var e=this.conf.mode;var t=this.conf.basename||"/";var r;if(e==="hash"){var a=window.location.href;var o=a.indexOf("#");r=o===-1?"":a.substring(o+1)}else{r=location.pathname}var n=b(c(r,t));return decodeURI(n==="/"?this.homePage:n)};e.prototype.bindEvent=function(){i.eventCenter.on("__taroRouterChange",this.routerChangeHandler);i.eventCenter.on("__taroSwitchTab",this.switchTabHandler);i.eventCenter.on("__taroSetTabBarBadge",this.setTabBarBadgeHandler);i.eventCenter.on("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);i.eventCenter.on("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);i.eventCenter.on("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);i.eventCenter.on("__taroShowTabBar",this.showTabBarHandler);i.eventCenter.on("__taroHideTabBar",this.hideTabBarHandler);i.eventCenter.on("__taroSetTabBarStyle",this.setTabBarStyleHandler);i.eventCenter.on("__taroSetTabBarItem",this.setTabBarItemHandler)};e.prototype.removeEvent=function(){i.eventCenter.off("__taroRouterChange",this.routerChangeHandler);i.eventCenter.off("__taroSwitchTab",this.switchTabHandler);i.eventCenter.off("__taroSetTabBarBadge",this.setTabBarBadgeHandler);i.eventCenter.off("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);i.eventCenter.off("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);i.eventCenter.off("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);i.eventCenter.off("__taroShowTabBar",this.showTabBarHandler);i.eventCenter.off("__taroHideTabBar",this.hideTabBarHandler);i.eventCenter.off("__taroSetTabBarStyle",this.setTabBarStyleHandler);i.eventCenter.off("__taroSetTabBarItem",this.setTabBarItemHandler)};e.prototype.componentDidLoad=function(){this.tabbarPos=this.tabbar.nextElementSibling?"top":"bottom";this.bindEvent();this.routerChangeHandler()};e.prototype.disconnectedCallback=function(){this.removeEvent()};e.prototype.render=function(){var e,r;var a=this;var n=this.tabbarPos,i=n===void 0?"bottom":n;var l=this.status;var d=s("weui-tabbar",(e={},e["taro-tabbar__border-".concat(this.borderStyle||"black")]=true,e));var b=this.selectedIndex===-1||l===T;var h=l===B;return t(o,{class:s(y,"".concat(y,"-").concat(i),(r={},r[H]=b,r[x]=h,r))},t("div",{class:d,style:{backgroundColor:this.backgroundColor||"",height:"inherit"}},this.list.map((function(e,r){var o=a.selectedIndex===r;var n;var i;if(o){n=a.selectedColor||"";i=e.selectedIconPath}else{n=a.color||"";i=e.iconPath}return t(p,{index:r,onSelect:a.switchTab.bind(a),isSelected:o,textColor:n,iconPath:i,pagePath:e.pagePath,text:e.text,badgeText:e.badgeText,showRedDot:e.showRedDot})}))))};Object.defineProperty(e.prototype,"tabbar",{get:function(){return n(this)},enumerable:false,configurable:true});return e}());w.style=_}}}));
2
- //# sourceMappingURL=p-47e6bde7.system.entry.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["splitUrl","_url","url","pos","res","path","query","fragment","indexOf","substring","addLeadingSlash","charAt","hasBasename","prefix","RegExp","test","stripBasename","length","stripSuffix","suffix","includes","isAbsolute","pathname","spliceOne","list","index","i","k","n","pop","resolvePathname","to","from","undefined","toParts","split","fromParts","isToAbs","isFromAbs","mustEndAbs","concat","hasTrailingSlash","last","up","part","unshift","result","join","substr","TabbarItem","_b","_c","isSelected","textColor","iconPath","badgeText","_d","showRedDot","pagePath","text","onSelect","className","classNames","badgeStyle","position","top","right","dotStyle","onClick","page","Taro","getCurrentPages","shift","onTabItemTap","isVisible","this","h","key","href","class","style","display","src","alt","color","indexCss","STATUS_SHOW","STATUS_HIDE","STATUS_SLIDEOUT","basicTabBarClassName","hideTabBarClassName","hideTabBarWithAnimationClassName","Tabbar","exports","class_1","hostRef","_this","homePage","customRoutes","tabbarPos","getOriginUrl","customRoute","filter","customUrl","pathA","pathB","getSelectedIndex","foundIndex","forEach","idx","switchTab","selectedIndex","switchTabHandler","successHandler","errorHandler","currentUrl","getCurrentUrl","nextTab","errMsg","routerChangeHandler","options","_a","toLocation","currentPage","routerBasename","conf","basename","setTabBarBadgeHandler","__spreadArray","removeTabBarBadgeHandler","showTabBarRedDotHandler","hideTabBarRedDotHandler","showTabBarHandler","status","hideTabBarHandler","animation","setTabBarStyleHandler","selectedColor","backgroundColor","borderStyle","setTabBarItemHandler","selectedIconPath","Object","prototype","toString","call","Error","this_1","push","apply","map","p","item","routerMode","mode","window","location","hashIndex","processedUrl","decodeURI","bindEvent","eventCenter","on","removeEvent","off","componentDidLoad","tabbar","nextElementSibling","disconnectedCallback","render","containerCls","shouldHideTabBar","shouldSlideout","Host","height","bind"],"sources":["src/utils/url.ts","../taro-router/dist/utils/index.js","../../node_modules/.pnpm/registry.npmjs.org+resolve-pathname@3.0.0/node_modules/resolve-pathname/esm/resolve-pathname.js","src/components/tabbar/tabbar-item.tsx","src/components/tabbar/style/index.scss?tag=taro-tabbar","src/components/tabbar/tabbar.tsx"],"sourcesContent":["export const normalizePath = url => {\n let _isRelative\n let _leadingParents = ''\n let _parent, _pos\n\n // handle relative paths\n if (url.charAt(0) !== '/') {\n _isRelative = true\n url = '/' + url\n }\n\n // handle relative files (as opposed to directories)\n if (url.substring(-3) === '/..' || url.slice(-2) === '/.') {\n url += '/'\n }\n\n // resolve simples\n url = url.replace(/(\\/(\\.\\/)+)|(\\/\\.$)/g, '/').replace(/\\/{2,}/g, '/')\n\n // remember leading parents\n if (_isRelative) {\n _leadingParents = url.substring(1).match(/^(\\.\\.\\/)+/) || ''\n if (_leadingParents) {\n _leadingParents = _leadingParents[0]\n }\n }\n\n // resolve parents\n while (true) {\n _parent = url.search(/\\/\\.\\.(\\/|$)/)\n if (_parent === -1) {\n // no more ../ to resolve\n break\n } else if (_parent === 0) {\n // top level cannot be relative, skip it\n url = url.substring(3)\n continue\n }\n\n _pos = url.substring(0, _parent).lastIndexOf('/')\n if (_pos === -1) {\n _pos = _parent\n }\n url = url.substring(0, _pos) + url.substring(_parent + 3)\n }\n\n // revert to relative\n if (_isRelative) {\n url = _leadingParents + url.substring(1)\n }\n\n return url\n}\n\nexport const splitUrl = _url => {\n let url = _url || ''\n let pos\n const res = {\n path: null,\n query: null,\n fragment: null\n }\n\n pos = url.indexOf('#')\n if (pos > -1) {\n res.fragment = url.substring(pos + 1)\n url = url.substring(0, pos)\n }\n\n pos = url.indexOf('?')\n if (pos > -1) {\n res.query = url.substring(pos + 1)\n url = url.substring(0, pos)\n }\n\n res.path = url\n\n return res\n}\n","// export const removeLeadingSlash = (str = '') => str.replace(/^\\.?\\//, '')\n// export const removeTrailingSearch = (str = '') => str.replace(/\\?[\\s\\S]*$/, '')\nexport const addLeadingSlash = (url = '') => (url.charAt(0) === '/' ? url : '/' + url);\nexport const hasBasename = (path = '', prefix = '') => new RegExp('^' + prefix + '(\\\\/|\\\\?|#|$)', 'i').test(path) || path === prefix;\nexport const stripBasename = (path = '', prefix = '') => hasBasename(path, prefix) ? path.substring(prefix.length) : path;\nexport const stripTrailing = (str = '') => str.replace(/[?#][\\s\\S]*$/, '');\nexport const stripSuffix = (path = '', suffix = '') => path.includes(suffix) ? path.substring(0, path.length - suffix.length) : path;\nexport const getHomePage = (path = '', basename = '', customRoutes = {}, entryPagePath = '') => {\n var _a;\n const routePath = addLeadingSlash(stripBasename(path, basename));\n const alias = ((_a = Object.entries(customRoutes).find(([key]) => key === routePath)) === null || _a === void 0 ? void 0 : _a[1]) || routePath;\n return entryPagePath || (typeof alias === 'string' ? alias : alias[0]) || basename;\n};\nclass RoutesAlias {\n constructor() {\n this.conf = [];\n this.getConfig = (url = '') => {\n const customRoute = this.conf.filter((arr) => {\n return arr.includes(url);\n });\n return customRoute[0];\n };\n this.getOrigin = (url = '') => {\n var _a;\n return ((_a = this.getConfig(url)) === null || _a === void 0 ? void 0 : _a[0]) || url;\n };\n this.getAlias = (url = '') => {\n var _a;\n return ((_a = this.getConfig(url)) === null || _a === void 0 ? void 0 : _a[1]) || url;\n };\n this.getAll = (url = '') => {\n return this.conf\n .filter((arr) => arr.includes(url))\n .reduceRight((p, a) => {\n p.unshift(a[1]);\n return p;\n }, []);\n };\n }\n set(customRoutes = {}) {\n for (let key in customRoutes) {\n const path = customRoutes[key];\n key = addLeadingSlash(key);\n if (typeof path === 'string') {\n this.conf.push([key, addLeadingSlash(path)]);\n }\n else if ((path === null || path === void 0 ? void 0 : path.length) > 0) {\n this.conf.push(...path.map(p => [key, addLeadingSlash(p)]));\n }\n }\n }\n}\nexport const routesAlias = new RoutesAlias();\n","function isAbsolute(pathname) {\n return pathname.charAt(0) === '/';\n}\n\n// About 1.5x faster than the two-arg version of Array#splice()\nfunction spliceOne(list, index) {\n for (var i = index, k = i + 1, n = list.length; k < n; i += 1, k += 1) {\n list[i] = list[k];\n }\n\n list.pop();\n}\n\n// This implementation is based heavily on node's url.parse\nfunction resolvePathname(to, from) {\n if (from === undefined) from = '';\n\n var toParts = (to && to.split('/')) || [];\n var fromParts = (from && from.split('/')) || [];\n\n var isToAbs = to && isAbsolute(to);\n var isFromAbs = from && isAbsolute(from);\n var mustEndAbs = isToAbs || isFromAbs;\n\n if (to && isAbsolute(to)) {\n // to is absolute\n fromParts = toParts;\n } else if (toParts.length) {\n // to is relative, drop the filename\n fromParts.pop();\n fromParts = fromParts.concat(toParts);\n }\n\n if (!fromParts.length) return '/';\n\n var hasTrailingSlash;\n if (fromParts.length) {\n var last = fromParts[fromParts.length - 1];\n hasTrailingSlash = last === '.' || last === '..' || last === '';\n } else {\n hasTrailingSlash = false;\n }\n\n var up = 0;\n for (var i = fromParts.length; i >= 0; i--) {\n var part = fromParts[i];\n\n if (part === '.') {\n spliceOne(fromParts, i);\n } else if (part === '..') {\n spliceOne(fromParts, i);\n up++;\n } else if (up) {\n spliceOne(fromParts, i);\n up--;\n }\n }\n\n if (!mustEndAbs) for (; up--; up) fromParts.unshift('..');\n\n if (\n mustEndAbs &&\n fromParts[0] !== '' &&\n (!fromParts[0] || !isAbsolute(fromParts[0]))\n )\n fromParts.unshift('');\n\n var result = fromParts.join('/');\n\n if (hasTrailingSlash && result.substr(-1) !== '/') result += '/';\n\n return result;\n}\n\nexport default resolvePathname;\n","import classNames from 'classnames'\nimport { FunctionalComponent, h } from '@stencil/core'\nimport Taro from '@tarojs/taro'\n\nimport { isVisible } from '../../utils'\n\ntype TabbarItemProps = {\n index: number\n isSelected?: boolean\n textColor?: string\n badgeText?: string\n iconPath: string\n showRedDot?: boolean\n pagePath?: string\n text?: string\n onSelect: (index: number) => void\n}\n\nexport const TabbarItem: FunctionalComponent<TabbarItemProps> = ({\n index,\n isSelected = false,\n textColor,\n iconPath,\n badgeText,\n showRedDot = false,\n pagePath,\n text,\n onSelect\n}) => {\n const className = classNames('weui-tabbar__item', {\n 'weui-bar__item_on': isSelected\n })\n const badgeStyle = {\n position: 'absolute',\n top: '-2px',\n right: '-13px'\n }\n const dotStyle = {\n position: 'absolute',\n top: '0',\n right: '-6px'\n }\n\n function onClick () {\n const page = Taro.getCurrentPages().shift()\n if (typeof page?.onTabItemTap === 'function' && isVisible(this)) {\n page.onTabItemTap({ index, pagePath, text })\n }\n onSelect(index)\n }\n\n return (\n <a key={index} href='javascript:;' class={className} onClick={onClick}>\n <span style={{ display: 'inline-block', position: 'relative' }}>\n <img src={iconPath} alt='' class='weui-tabbar__icon' />\n {!!badgeText && (\n <span\n class='weui-badge taro-tabbar-badge'\n style={badgeStyle}>\n {badgeText}\n </span>\n )}\n {showRedDot && (\n <span\n class='weui-badge weui-badge_dot'\n style={dotStyle}\n />\n )}\n </span>\n <p class='weui-tabbar__label' style={{ color: textColor }}>\n {text}\n </p>\n </a>\n )\n}\n","html,\nbody {\n height: 100%;\n}\n\n#app {\n height: 100%;\n}\n\n.taro-tabbar {\n &__border {\n &-white {\n &::before {\n border-top-color: #fff !important;\n }\n }\n }\n\n &__container {\n display: flex;\n overflow: hidden;\n flex-direction: column;\n height: 100%;\n }\n\n &__panel {\n overflow: auto;\n position: relative;\n flex: 1;\n -webkit-overflow-scrolling: auto;\n }\n\n &__tabbar {\n position: relative;\n width: 100%;\n height: 50px;\n transition: bottom 0.2s, top 0.2s;\n\n &-top {\n top: 0;\n }\n\n &-bottom {\n bottom: 0;\n margin-bottom: constant(safe-area-inset-bottom);\n margin-bottom: env(safe-area-inset-bottom);\n }\n\n &-hide {\n display: none;\n }\n\n &-slideout {\n top: -52px;\n flex: 0 0;\n }\n }\n\n &__panel + &__tabbar-slideout {\n top: auto;\n bottom: -52px;\n }\n}\n","import { Component, Prop, h, ComponentInterface, Host, State, Event, EventEmitter, Element } from '@stencil/core'\nimport Taro from '@tarojs/taro'\nimport { addLeadingSlash, stripBasename, stripSuffix } from '@tarojs/router/dist/utils'\nimport { IH5RouterConfig } from '@tarojs/taro/types/compile'\nimport classNames from 'classnames'\nimport resolvePathname from 'resolve-pathname'\n\nimport { splitUrl } from '../../utils'\nimport { TabbarItem } from './tabbar-item'\n\nconst STATUS_SHOW = 0\nconst STATUS_HIDE = 1\nconst STATUS_SLIDEOUT = 2\n\nconst basicTabBarClassName = 'taro-tabbar__tabbar'\nconst hideTabBarClassName = 'taro-tabbar__tabbar-hide'\nconst hideTabBarWithAnimationClassName = 'taro-tabbar__tabbar-slideout'\n\ninterface RouterHandler {\n index: string\n text: string\n url: string\n successHandler: Function\n errorHandler: Function\n animation?: boolean\n}\n\nexport interface Conf {\n color: string\n selectedColor: string\n backgroundColor: string\n borderStyle?: 'black' | 'white'\n list: TabbarList[]\n position?: 'bottom' | 'top'\n custom: boolean\n customRoutes: Record<string, string | string[]>\n mode: IH5RouterConfig['mode']\n basename: string\n homePage: string\n currentPagename: string\n}\n\ninterface TabbarList {\n pagePath: string\n text: string\n iconPath?: string\n selectedIconPath?: string\n badgeText?: string\n showRedDot?: boolean\n}\n\n@Component({\n tag: 'taro-tabbar',\n styleUrl: './style/index.scss'\n})\nexport class Tabbar implements ComponentInterface {\n private homePage = ''\n\n private customRoutes: Array<string[]> = []\n\n private tabbarPos: 'top' | 'bottom' = 'bottom'\n\n @Prop() conf: Conf\n\n @State() list: TabbarList[]\n\n @State() borderStyle: Conf['borderStyle']\n\n @State() backgroundColor: Conf['backgroundColor']\n\n @State() color: Conf['color']\n\n @State() selectedColor: Conf['selectedColor']\n\n @State() selectedIndex = -1\n\n @State() status: 0 | 1 | 2 = STATUS_SHOW\n\n @Event({\n eventName: 'longpress'\n }) onLongPress: EventEmitter\n\n @Element() tabbar: HTMLDivElement\n\n constructor () {\n const list = this.conf.list\n const customRoutes = this.conf.customRoutes\n if (\n Object.prototype.toString.call(list) !== '[object Array]' ||\n list.length < 2 ||\n list.length > 5\n ) {\n throw new Error('tabBar 配置错误')\n }\n\n this.homePage = addLeadingSlash(this.conf.homePage)\n for (let key in customRoutes) {\n const path = customRoutes[key]\n key = addLeadingSlash(key)\n if (typeof path === 'string') {\n this.customRoutes.push([key, addLeadingSlash(path)])\n } else if (path?.length > 0) {\n this.customRoutes.push(...path.map(p => [key, addLeadingSlash(p)]))\n }\n }\n\n list.forEach(item => {\n if (item.pagePath.indexOf('/') !== 0) {\n item.pagePath = '/' + item.pagePath\n }\n })\n\n this.list = list\n this.borderStyle = this.conf.borderStyle\n this.backgroundColor = this.conf.backgroundColor\n this.color = this.conf.color\n this.selectedColor = this.conf.selectedColor\n }\n\n getCurrentUrl () {\n const routerMode = this.conf.mode\n const routerBasename = this.conf.basename || '/'\n let url\n if (routerMode === 'hash') {\n const href = window.location.href\n const hashIndex = href.indexOf('#')\n url = hashIndex === -1\n ? ''\n : href.substring(hashIndex + 1)\n } else {\n url = location.pathname\n }\n const processedUrl = addLeadingSlash(stripBasename(url, routerBasename))\n return decodeURI(processedUrl === '/' ? this.homePage : processedUrl)\n }\n\n getOriginUrl = (url: string) => {\n const customRoute = this.customRoutes.filter(([, customUrl]) => {\n const pathA = splitUrl(customUrl).path\n const pathB = splitUrl(url).path\n return pathA === pathB\n })\n return stripSuffix(customRoute.length ? customRoute[0][0] : url, '.html')\n }\n\n getSelectedIndex = (url: string) => {\n let foundIndex = -1\n this.list.forEach(({ pagePath }, idx) => {\n const pathA = splitUrl(url).path\n const pathB = splitUrl(pagePath).path\n if (pathA === pathB) {\n foundIndex = idx\n }\n })\n return foundIndex\n }\n\n switchTab = (index: number) => {\n this.selectedIndex = index\n Taro.switchTab({\n url: this.list[index].pagePath\n })\n }\n\n switchTabHandler = ({ url, successHandler, errorHandler }: RouterHandler) => {\n const currentUrl = this.getOriginUrl(this.getCurrentUrl() || this.homePage)\n const nextTab = resolvePathname(url, currentUrl)\n const foundIndex = this.getSelectedIndex(nextTab)\n\n if (foundIndex > -1) {\n this.switchTab(foundIndex)\n successHandler({\n errMsg: 'switchTab:ok'\n })\n } else {\n errorHandler({\n errMsg: `switchTab:fail page \"${nextTab}\" is not found`\n })\n }\n }\n\n routerChangeHandler = (options?) => {\n const to = options?.toLocation?.path\n let currentPage\n\n if (typeof to === 'string') {\n const routerBasename = this.conf.basename || '/'\n currentPage = stripBasename(addLeadingSlash(to || this.homePage), routerBasename) || '/'\n } else {\n currentPage = this.getCurrentUrl()\n }\n\n this.selectedIndex = this.getSelectedIndex(this.getOriginUrl(currentPage))\n }\n\n setTabBarBadgeHandler = ({ index, text, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].showRedDot = false\n list[index].badgeText = text\n successHandler({\n errMsg: 'setTabBarBadge:ok'\n })\n } else {\n errorHandler({\n errMsg: 'setTabBarBadge:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n removeTabBarBadgeHandler = ({ index, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].badgeText = null\n list[index].badgeText = null\n successHandler({\n errMsg: 'removeTabBarBadge:ok'\n })\n } else {\n errorHandler({\n errMsg: 'removeTabBarBadge:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n showTabBarRedDotHandler = ({ index, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].badgeText = null\n list[index].showRedDot = true\n successHandler({\n errMsg: 'showTabBarRedDot:ok'\n })\n } else {\n errorHandler({\n errMsg: 'showTabBarRedDot:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n hideTabBarRedDotHandler = ({ index, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].showRedDot = false\n successHandler({\n errMsg: 'hideTabBarRedDot:ok'\n })\n } else {\n errorHandler({\n errMsg: 'hideTabBarRedDot:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n showTabBarHandler = ({ successHandler }) => {\n this.status = STATUS_SHOW\n successHandler({\n errMsg: 'showTabBar:ok'\n })\n }\n\n hideTabBarHandler = ({ animation, successHandler }) => {\n this.status = animation ? STATUS_SLIDEOUT : STATUS_HIDE\n successHandler({\n errMsg: 'hideTabBar:ok'\n })\n }\n\n setTabBarStyleHandler = ({ color, selectedColor, backgroundColor, borderStyle, successHandler }) => {\n if (backgroundColor) this.backgroundColor = backgroundColor\n if (borderStyle) this.borderStyle = borderStyle\n if (color) this.color = color\n if (selectedColor) this.selectedColor = selectedColor\n successHandler({\n errMsg: 'setTabBarStyle:ok'\n })\n }\n\n setTabBarItemHandler = ({ index, iconPath, selectedIconPath, text, successHandler, errorHandler }) => {\n const list = [...this.list]\n if (index in list) {\n if (iconPath) list[index].iconPath = iconPath\n if (selectedIconPath) list[index].selectedIconPath = selectedIconPath\n if (text) list[index].text = text\n successHandler({\n errMsg: 'setTabBarItem:ok'\n })\n } else {\n errorHandler({\n errMsg: 'setTabBarItem:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n bindEvent () {\n Taro.eventCenter.on('__taroRouterChange', this.routerChangeHandler)\n Taro.eventCenter.on('__taroSwitchTab', this.switchTabHandler)\n Taro.eventCenter.on('__taroSetTabBarBadge', this.setTabBarBadgeHandler)\n Taro.eventCenter.on('__taroRemoveTabBarBadge', this.removeTabBarBadgeHandler)\n Taro.eventCenter.on('__taroShowTabBarRedDotHandler', this.showTabBarRedDotHandler)\n Taro.eventCenter.on('__taroHideTabBarRedDotHandler', this.hideTabBarRedDotHandler)\n Taro.eventCenter.on('__taroShowTabBar', this.showTabBarHandler)\n Taro.eventCenter.on('__taroHideTabBar', this.hideTabBarHandler)\n Taro.eventCenter.on('__taroSetTabBarStyle', this.setTabBarStyleHandler)\n Taro.eventCenter.on('__taroSetTabBarItem', this.setTabBarItemHandler)\n }\n\n removeEvent () {\n Taro.eventCenter.off('__taroRouterChange', this.routerChangeHandler)\n Taro.eventCenter.off('__taroSwitchTab', this.switchTabHandler)\n Taro.eventCenter.off('__taroSetTabBarBadge', this.setTabBarBadgeHandler)\n Taro.eventCenter.off('__taroRemoveTabBarBadge', this.removeTabBarBadgeHandler)\n Taro.eventCenter.off('__taroShowTabBarRedDotHandler', this.showTabBarRedDotHandler)\n Taro.eventCenter.off('__taroHideTabBarRedDotHandler', this.hideTabBarRedDotHandler)\n Taro.eventCenter.off('__taroShowTabBar', this.showTabBarHandler)\n Taro.eventCenter.off('__taroHideTabBar', this.hideTabBarHandler)\n Taro.eventCenter.off('__taroSetTabBarStyle', this.setTabBarStyleHandler)\n Taro.eventCenter.off('__taroSetTabBarItem', this.setTabBarItemHandler)\n }\n\n componentDidLoad () {\n this.tabbarPos = this.tabbar.nextElementSibling ? 'top' : 'bottom'\n this.bindEvent()\n this.routerChangeHandler()\n }\n\n disconnectedCallback () {\n this.removeEvent()\n }\n\n render () {\n const { tabbarPos = 'bottom' } = this\n const status = this.status\n const containerCls = classNames('weui-tabbar', {\n [`taro-tabbar__border-${this.borderStyle || 'black'}`]: true\n })\n const shouldHideTabBar = this.selectedIndex === -1 || status === STATUS_HIDE\n const shouldSlideout = status === STATUS_SLIDEOUT\n\n return (\n <Host\n class={classNames(\n basicTabBarClassName,\n `${basicTabBarClassName}-${tabbarPos}`, {\n [hideTabBarClassName]: shouldHideTabBar,\n [hideTabBarWithAnimationClassName]: shouldSlideout\n })} >\n <div\n class={containerCls}\n style={{\n backgroundColor: this.backgroundColor || '',\n height: 'inherit'\n }}\n >\n {this.list.map((item, index) => {\n const isSelected = this.selectedIndex === index\n let textColor\n let iconPath\n if (isSelected) {\n textColor = this.selectedColor || ''\n iconPath = item.selectedIconPath\n } else {\n textColor = this.color || ''\n iconPath = item.iconPath\n }\n return (\n <TabbarItem\n index={index}\n onSelect={this.switchTab.bind(this)}\n isSelected={isSelected}\n textColor={textColor}\n iconPath={iconPath}\n pagePath={item.pagePath}\n text={item.text}\n badgeText={item.badg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AKnD,KAAK8H,KAAI,SAACE,EAAM/H,GACpB,IAAM2B,EAAa4C,EAAKe,gBAAkBtF,EAC1C,IAAI4B,EACJ,IAAIC,EACJ,GAAIF,EAAY,CACdC,EAAY2C,EAAKyC,eAAiB,GAClCnF,EAAWkG,EAAKX,gB,KACX,CACLxF,EAAY2C,EAAKZ,OAAS,GAC1B9B,EAAWkG,EAAKlG,Q,CAElB,OACEsB,EAAC3B,EAAU,CACTxB,MAAOA,EACPmC,SAAUoC,EAAKc,UAAUiE,KAAK/E,GAC9B5C,WAAYA,EACZC,UAAWA,EACXC,SAAUA,EACVI,SAAU8F,EAAK9F,SACfC,KAAM6F,EAAK7F,KACXJ,UAAWiG,EAAKjG,UAChBE,WAAY+F,EAAK/F,Y,gIA1Ud,I"}
@@ -1,2 +0,0 @@
1
- import{h as t,r as e,c as s,H as a,g as i}from"./p-78e3ebb9.js";import r from"@tarojs/taro";import{c as o}from"./p-76724e58.js";import{i as n}from"./p-d3c7f87d.js";const h=t=>{let e=t||"";let s;const a={path:null,query:null,fragment:null};s=e.indexOf("#");if(s>-1){a.fragment=e.substring(s+1);e=e.substring(0,s)}s=e.indexOf("?");if(s>-1){a.query=e.substring(s+1);e=e.substring(0,s)}a.path=e;return a};const l=(t="")=>t.charAt(0)==="/"?t:"/"+t;const b=(t="",e="")=>new RegExp("^"+e+"(\\/|\\?|#|$)","i").test(t)||t===e;const c=(t="",e="")=>b(t,e)?t.substring(e.length):t;const d=(t="",e="")=>t.includes(e)?t.substring(0,t.length-e.length):t;function f(t){return t.charAt(0)==="/"}function _(t,e){for(var s=e,a=s+1,i=t.length;a<i;s+=1,a+=1){t[s]=t[a]}t.pop()}function u(t,e){if(e===undefined)e="";var s=t&&t.split("/")||[];var a=e&&e.split("/")||[];var i=t&&f(t);var r=e&&f(e);var o=i||r;if(t&&f(t)){a=s}else if(s.length){a.pop();a=a.concat(s)}if(!a.length)return"/";var n;if(a.length){var h=a[a.length-1];n=h==="."||h===".."||h===""}else{n=false}var l=0;for(var b=a.length;b>=0;b--){var c=a[b];if(c==="."){_(a,b)}else if(c===".."){_(a,b);l++}else if(l){_(a,b);l--}}if(!o)for(;l--;l)a.unshift("..");if(o&&a[0]!==""&&(!a[0]||!f(a[0])))a.unshift("");var d=a.join("/");if(n&&d.substr(-1)!=="/")d+="/";return d}const g=({index:e,isSelected:s=false,textColor:a,iconPath:i,badgeText:h,showRedDot:l=false,pagePath:b,text:c,onSelect:d})=>{const f=o("weui-tabbar__item",{"weui-bar__item_on":s});const _={position:"absolute",top:"-2px",right:"-13px"};const u={position:"absolute",top:"0",right:"-6px"};function g(){const t=r.getCurrentPages().shift();if(typeof(t===null||t===void 0?void 0:t.onTabItemTap)==="function"&&n(this)){t.onTabItemTap({index:e,pagePath:b,text:c})}d(e)}return t("a",{key:e,href:"javascript:;",class:f,onClick:g},t("span",{style:{display:"inline-block",position:"relative"}},t("img",{src:i,alt:"",class:"weui-tabbar__icon"}),!!h&&t("span",{class:"weui-badge taro-tabbar-badge",style:_},h),l&&t("span",{class:"weui-badge weui-badge_dot",style:u})),t("p",{class:"weui-tabbar__label",style:{color:a}},c))};const p="html,body{height:100%}#app{height:100%}.taro-tabbar__border-white::before{border-top-color:#fff !important}.taro-tabbar__container{display:-ms-flexbox;display:flex;overflow:hidden;-ms-flex-direction:column;flex-direction:column;height:100%}.taro-tabbar__panel{overflow:auto;position:relative;-ms-flex:1;flex:1;-webkit-overflow-scrolling:auto}.taro-tabbar__tabbar{position:relative;width:100%;height:50px;-webkit-transition:bottom 0.2s, top 0.2s;transition:bottom 0.2s, top 0.2s}.taro-tabbar__tabbar-top{top:0}.taro-tabbar__tabbar-bottom{bottom:0;margin-bottom:constant(safe-area-inset-bottom);margin-bottom:env(safe-area-inset-bottom)}.taro-tabbar__tabbar-hide{display:none}.taro-tabbar__tabbar-slideout{top:-52px;-ms-flex:0 0;flex:0 0}.taro-tabbar__panel+.taro-tabbar__tabbar-slideout{top:auto;bottom:-52px}";const m=0;const B=1;const v=2;const T="taro-tabbar__tabbar";const x="taro-tabbar__tabbar-hide";const w="taro-tabbar__tabbar-slideout";const H=class{constructor(t){e(this,t);this.onLongPress=s(this,"longpress",7);this.homePage="";this.customRoutes=[];this.tabbarPos="bottom";this.getOriginUrl=t=>{const e=this.customRoutes.filter((([,e])=>{const s=h(e).path;const a=h(t).path;return s===a}));return d(e.length?e[0][0]:t,".html")};this.getSelectedIndex=t=>{let e=-1;this.list.forEach((({pagePath:s},a)=>{const i=h(t).path;const r=h(s).path;if(i===r){e=a}}));return e};this.switchTab=t=>{this.selectedIndex=t;r.switchTab({url:this.list[t].pagePath})};this.switchTabHandler=({url:t,successHandler:e,errorHandler:s})=>{const a=this.getOriginUrl(this.getCurrentUrl()||this.homePage);const i=u(t,a);const r=this.getSelectedIndex(i);if(r>-1){this.switchTab(r);e({errMsg:"switchTab:ok"})}else{s({errMsg:`switchTab:fail page "${i}" is not found`})}};this.routerChangeHandler=t=>{var e;const s=(e=t===null||t===void 0?void 0:t.toLocation)===null||e===void 0?void 0:e.path;let a;if(typeof s==="string"){const t=this.conf.basename||"/";a=c(l(s||this.homePage),t)||"/"}else{a=this.getCurrentUrl()}this.selectedIndex=this.getSelectedIndex(this.getOriginUrl(a))};this.setTabBarBadgeHandler=({index:t,text:e,successHandler:s,errorHandler:a})=>{const i=[...this.list];if(t in i){i[t].showRedDot=false;i[t].badgeText=e;s({errMsg:"setTabBarBadge:ok"})}else{a({errMsg:"setTabBarBadge:fail tabbar item not found"})}this.list=i};this.removeTabBarBadgeHandler=({index:t,successHandler:e,errorHandler:s})=>{const a=[...this.list];if(t in a){a[t].badgeText=null;a[t].badgeText=null;e({errMsg:"removeTabBarBadge:ok"})}else{s({errMsg:"removeTabBarBadge:fail tabbar item not found"})}this.list=a};this.showTabBarRedDotHandler=({index:t,successHandler:e,errorHandler:s})=>{const a=[...this.list];if(t in a){a[t].badgeText=null;a[t].showRedDot=true;e({errMsg:"showTabBarRedDot:ok"})}else{s({errMsg:"showTabBarRedDot:fail tabbar item not found"})}this.list=a};this.hideTabBarRedDotHandler=({index:t,successHandler:e,errorHandler:s})=>{const a=[...this.list];if(t in a){a[t].showRedDot=false;e({errMsg:"hideTabBarRedDot:ok"})}else{s({errMsg:"hideTabBarRedDot:fail tabbar item not found"})}this.list=a};this.showTabBarHandler=({successHandler:t})=>{this.status=m;t({errMsg:"showTabBar:ok"})};this.hideTabBarHandler=({animation:t,successHandler:e})=>{this.status=t?v:B;e({errMsg:"hideTabBar:ok"})};this.setTabBarStyleHandler=({color:t,selectedColor:e,backgroundColor:s,borderStyle:a,successHandler:i})=>{if(s)this.backgroundColor=s;if(a)this.borderStyle=a;if(t)this.color=t;if(e)this.selectedColor=e;i({errMsg:"setTabBarStyle:ok"})};this.setTabBarItemHandler=({index:t,iconPath:e,selectedIconPath:s,text:a,successHandler:i,errorHandler:r})=>{const o=[...this.list];if(t in o){if(e)o[t].iconPath=e;if(s)o[t].selectedIconPath=s;if(a)o[t].text=a;i({errMsg:"setTabBarItem:ok"})}else{r({errMsg:"setTabBarItem:fail tabbar item not found"})}this.list=o};this.conf=undefined;this.list=undefined;this.borderStyle=undefined;this.backgroundColor=undefined;this.color=undefined;this.selectedColor=undefined;this.selectedIndex=-1;this.status=m;const a=this.conf.list;const i=this.conf.customRoutes;if(Object.prototype.toString.call(a)!=="[object Array]"||a.length<2||a.length>5){throw new Error("tabBar 配置错误")}this.homePage=l(this.conf.homePage);for(let t in i){const e=i[t];t=l(t);if(typeof e==="string"){this.customRoutes.push([t,l(e)])}else if((e===null||e===void 0?void 0:e.length)>0){this.customRoutes.push(...e.map((e=>[t,l(e)])))}}a.forEach((t=>{if(t.pagePath.indexOf("/")!==0){t.pagePath="/"+t.pagePath}}));this.list=a;this.borderStyle=this.conf.borderStyle;this.backgroundColor=this.conf.backgroundColor;this.color=this.conf.color;this.selectedColor=this.conf.selectedColor}getCurrentUrl(){const t=this.conf.mode;const e=this.conf.basename||"/";let s;if(t==="hash"){const t=window.location.href;const e=t.indexOf("#");s=e===-1?"":t.substring(e+1)}else{s=location.pathname}const a=l(c(s,e));return decodeURI(a==="/"?this.homePage:a)}bindEvent(){r.eventCenter.on("__taroRouterChange",this.routerChangeHandler);r.eventCenter.on("__taroSwitchTab",this.switchTabHandler);r.eventCenter.on("__taroSetTabBarBadge",this.setTabBarBadgeHandler);r.eventCenter.on("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);r.eventCenter.on("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);r.eventCenter.on("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);r.eventCenter.on("__taroShowTabBar",this.showTabBarHandler);r.eventCenter.on("__taroHideTabBar",this.hideTabBarHandler);r.eventCenter.on("__taroSetTabBarStyle",this.setTabBarStyleHandler);r.eventCenter.on("__taroSetTabBarItem",this.setTabBarItemHandler)}removeEvent(){r.eventCenter.off("__taroRouterChange",this.routerChangeHandler);r.eventCenter.off("__taroSwitchTab",this.switchTabHandler);r.eventCenter.off("__taroSetTabBarBadge",this.setTabBarBadgeHandler);r.eventCenter.off("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);r.eventCenter.off("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);r.eventCenter.off("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);r.eventCenter.off("__taroShowTabBar",this.showTabBarHandler);r.eventCenter.off("__taroHideTabBar",this.hideTabBarHandler);r.eventCenter.off("__taroSetTabBarStyle",this.setTabBarStyleHandler);r.eventCenter.off("__taroSetTabBarItem",this.setTabBarItemHandler)}componentDidLoad(){this.tabbarPos=this.tabbar.nextElementSibling?"top":"bottom";this.bindEvent();this.routerChangeHandler()}disconnectedCallback(){this.removeEvent()}render(){const{tabbarPos:e="bottom"}=this;const s=this.status;const i=o("weui-tabbar",{[`taro-tabbar__border-${this.borderStyle||"black"}`]:true});const r=this.selectedIndex===-1||s===B;const n=s===v;return t(a,{class:o(T,`${T}-${e}`,{[x]:r,[w]:n})},t("div",{class:i,style:{backgroundColor:this.backgroundColor||"",height:"inherit"}},this.list.map(((e,s)=>{const a=this.selectedIndex===s;let i;let r;if(a){i=this.selectedColor||"";r=e.selectedIconPath}else{i=this.color||"";r=e.iconPath}return t(g,{index:s,onSelect:this.switchTab.bind(this),isSelected:a,textColor:i,iconPath:r,pagePath:e.pagePath,text:e.text,badgeText:e.badgeText,showRedDot:e.showRedDot})}))))}get tabbar(){return i(this)}};H.style=p;export{H as taro_tabbar};
2
- //# sourceMappingURL=p-f5aaaab7.entry.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["splitUrl","_url","url","pos","res","path","query","fragment","indexOf","substring","addLeadingSlash","charAt","hasBasename","prefix","RegExp","test","stripBasename","length","stripSuffix","suffix","includes","isAbsolute","pathname","spliceOne","list","index","i","k","n","pop","resolvePathname","to","from","undefined","toParts","split","fromParts","isToAbs","isFromAbs","mustEndAbs","concat","hasTrailingSlash","last","up","part","unshift","result","join","substr","TabbarItem","isSelected","textColor","iconPath","badgeText","showRedDot","pagePath","text","onSelect","className","classNames","badgeStyle","position","top","right","dotStyle","onClick","page","Taro","getCurrentPages","shift","onTabItemTap","isVisible","this","h","key","href","class","style","display","src","alt","color","indexCss","STATUS_SHOW","STATUS_HIDE","STATUS_SLIDEOUT","basicTabBarClassName","hideTabBarClassName","hideTabBarWithAnimationClassName","Tabbar","constructor","hostRef","homePage","customRoutes","tabbarPos","getOriginUrl","customRoute","filter","customUrl","pathA","pathB","getSelectedIndex","foundIndex","forEach","idx","switchTab","selectedIndex","switchTabHandler","successHandler","errorHandler","currentUrl","getCurrentUrl","nextTab","errMsg","routerChangeHandler","options","_a","toLocation","currentPage","routerBasename","conf","basename","setTabBarBadgeHandler","removeTabBarBadgeHandler","showTabBarRedDotHandler","hideTabBarRedDotHandler","showTabBarHandler","status","hideTabBarHandler","animation","setTabBarStyleHandler","selectedColor","backgroundColor","borderStyle","setTabBarItemHandler","selectedIconPath","Object","prototype","toString","call","Error","push","map","p","item","routerMode","mode","window","location","hashIndex","processedUrl","decodeURI","bindEvent","eventCenter","on","removeEvent","off","componentDidLoad","tabbar","nextElementSibling","disconnectedCallback","render","containerCls","shouldHideTabBar","shouldSlideout","Host","height","bind"],"sources":["./src/utils/url.ts","../taro-router/dist/utils/index.js","../../node_modules/.pnpm/registry.npmjs.org+resolve-pathname@3.0.0/node_modules/resolve-pathname/esm/resolve-pathname.js","./src/components/tabbar/tabbar-item.tsx","./src/components/tabbar/style/index.scss?tag=taro-tabbar","./src/components/tabbar/tabbar.tsx"],"sourcesContent":["export const normalizePath = url => {\n let _isRelative\n let _leadingParents = ''\n let _parent, _pos\n\n // handle relative paths\n if (url.charAt(0) !== '/') {\n _isRelative = true\n url = '/' + url\n }\n\n // handle relative files (as opposed to directories)\n if (url.substring(-3) === '/..' || url.slice(-2) === '/.') {\n url += '/'\n }\n\n // resolve simples\n url = url.replace(/(\\/(\\.\\/)+)|(\\/\\.$)/g, '/').replace(/\\/{2,}/g, '/')\n\n // remember leading parents\n if (_isRelative) {\n _leadingParents = url.substring(1).match(/^(\\.\\.\\/)+/) || ''\n if (_leadingParents) {\n _leadingParents = _leadingParents[0]\n }\n }\n\n // resolve parents\n while (true) {\n _parent = url.search(/\\/\\.\\.(\\/|$)/)\n if (_parent === -1) {\n // no more ../ to resolve\n break\n } else if (_parent === 0) {\n // top level cannot be relative, skip it\n url = url.substring(3)\n continue\n }\n\n _pos = url.substring(0, _parent).lastIndexOf('/')\n if (_pos === -1) {\n _pos = _parent\n }\n url = url.substring(0, _pos) + url.substring(_parent + 3)\n }\n\n // revert to relative\n if (_isRelative) {\n url = _leadingParents + url.substring(1)\n }\n\n return url\n}\n\nexport const splitUrl = _url => {\n let url = _url || ''\n let pos\n const res = {\n path: null,\n query: null,\n fragment: null\n }\n\n pos = url.indexOf('#')\n if (pos > -1) {\n res.fragment = url.substring(pos + 1)\n url = url.substring(0, pos)\n }\n\n pos = url.indexOf('?')\n if (pos > -1) {\n res.query = url.substring(pos + 1)\n url = url.substring(0, pos)\n }\n\n res.path = url\n\n return res\n}\n","// export const removeLeadingSlash = (str = '') => str.replace(/^\\.?\\//, '')\n// export const removeTrailingSearch = (str = '') => str.replace(/\\?[\\s\\S]*$/, '')\nexport const addLeadingSlash = (url = '') => (url.charAt(0) === '/' ? url : '/' + url);\nexport const hasBasename = (path = '', prefix = '') => new RegExp('^' + prefix + '(\\\\/|\\\\?|#|$)', 'i').test(path) || path === prefix;\nexport const stripBasename = (path = '', prefix = '') => hasBasename(path, prefix) ? path.substring(prefix.length) : path;\nexport const stripTrailing = (str = '') => str.replace(/[?#][\\s\\S]*$/, '');\nexport const stripSuffix = (path = '', suffix = '') => path.includes(suffix) ? path.substring(0, path.length - suffix.length) : path;\nexport const getHomePage = (path = '', basename = '', customRoutes = {}, entryPagePath = '') => {\n var _a;\n const routePath = addLeadingSlash(stripBasename(path, basename));\n const alias = ((_a = Object.entries(customRoutes).find(([key]) => key === routePath)) === null || _a === void 0 ? void 0 : _a[1]) || routePath;\n return entryPagePath || (typeof alias === 'string' ? alias : alias[0]) || basename;\n};\nclass RoutesAlias {\n constructor() {\n this.conf = [];\n this.getConfig = (url = '') => {\n const customRoute = this.conf.filter((arr) => {\n return arr.includes(url);\n });\n return customRoute[0];\n };\n this.getOrigin = (url = '') => {\n var _a;\n return ((_a = this.getConfig(url)) === null || _a === void 0 ? void 0 : _a[0]) || url;\n };\n this.getAlias = (url = '') => {\n var _a;\n return ((_a = this.getConfig(url)) === null || _a === void 0 ? void 0 : _a[1]) || url;\n };\n this.getAll = (url = '') => {\n return this.conf\n .filter((arr) => arr.includes(url))\n .reduceRight((p, a) => {\n p.unshift(a[1]);\n return p;\n }, []);\n };\n }\n set(customRoutes = {}) {\n for (let key in customRoutes) {\n const path = customRoutes[key];\n key = addLeadingSlash(key);\n if (typeof path === 'string') {\n this.conf.push([key, addLeadingSlash(path)]);\n }\n else if ((path === null || path === void 0 ? void 0 : path.length) > 0) {\n this.conf.push(...path.map(p => [key, addLeadingSlash(p)]));\n }\n }\n }\n}\nexport const routesAlias = new RoutesAlias();\n","function isAbsolute(pathname) {\n return pathname.charAt(0) === '/';\n}\n\n// About 1.5x faster than the two-arg version of Array#splice()\nfunction spliceOne(list, index) {\n for (var i = index, k = i + 1, n = list.length; k < n; i += 1, k += 1) {\n list[i] = list[k];\n }\n\n list.pop();\n}\n\n// This implementation is based heavily on node's url.parse\nfunction resolvePathname(to, from) {\n if (from === undefined) from = '';\n\n var toParts = (to && to.split('/')) || [];\n var fromParts = (from && from.split('/')) || [];\n\n var isToAbs = to && isAbsolute(to);\n var isFromAbs = from && isAbsolute(from);\n var mustEndAbs = isToAbs || isFromAbs;\n\n if (to && isAbsolute(to)) {\n // to is absolute\n fromParts = toParts;\n } else if (toParts.length) {\n // to is relative, drop the filename\n fromParts.pop();\n fromParts = fromParts.concat(toParts);\n }\n\n if (!fromParts.length) return '/';\n\n var hasTrailingSlash;\n if (fromParts.length) {\n var last = fromParts[fromParts.length - 1];\n hasTrailingSlash = last === '.' || last === '..' || last === '';\n } else {\n hasTrailingSlash = false;\n }\n\n var up = 0;\n for (var i = fromParts.length; i >= 0; i--) {\n var part = fromParts[i];\n\n if (part === '.') {\n spliceOne(fromParts, i);\n } else if (part === '..') {\n spliceOne(fromParts, i);\n up++;\n } else if (up) {\n spliceOne(fromParts, i);\n up--;\n }\n }\n\n if (!mustEndAbs) for (; up--; up) fromParts.unshift('..');\n\n if (\n mustEndAbs &&\n fromParts[0] !== '' &&\n (!fromParts[0] || !isAbsolute(fromParts[0]))\n )\n fromParts.unshift('');\n\n var result = fromParts.join('/');\n\n if (hasTrailingSlash && result.substr(-1) !== '/') result += '/';\n\n return result;\n}\n\nexport default resolvePathname;\n","import classNames from 'classnames'\nimport { FunctionalComponent, h } from '@stencil/core'\nimport Taro from '@tarojs/taro'\n\nimport { isVisible } from '../../utils'\n\ntype TabbarItemProps = {\n index: number\n isSelected?: boolean\n textColor?: string\n badgeText?: string\n iconPath: string\n showRedDot?: boolean\n pagePath?: string\n text?: string\n onSelect: (index: number) => void\n}\n\nexport const TabbarItem: FunctionalComponent<TabbarItemProps> = ({\n index,\n isSelected = false,\n textColor,\n iconPath,\n badgeText,\n showRedDot = false,\n pagePath,\n text,\n onSelect\n}) => {\n const className = classNames('weui-tabbar__item', {\n 'weui-bar__item_on': isSelected\n })\n const badgeStyle = {\n position: 'absolute',\n top: '-2px',\n right: '-13px'\n }\n const dotStyle = {\n position: 'absolute',\n top: '0',\n right: '-6px'\n }\n\n function onClick () {\n const page = Taro.getCurrentPages().shift()\n if (typeof page?.onTabItemTap === 'function' && isVisible(this)) {\n page.onTabItemTap({ index, pagePath, text })\n }\n onSelect(index)\n }\n\n return (\n <a key={index} href='javascript:;' class={className} onClick={onClick}>\n <span style={{ display: 'inline-block', position: 'relative' }}>\n <img src={iconPath} alt='' class='weui-tabbar__icon' />\n {!!badgeText && (\n <span\n class='weui-badge taro-tabbar-badge'\n style={badgeStyle}>\n {badgeText}\n </span>\n )}\n {showRedDot && (\n <span\n class='weui-badge weui-badge_dot'\n style={dotStyle}\n />\n )}\n </span>\n <p class='weui-tabbar__label' style={{ color: textColor }}>\n {text}\n </p>\n </a>\n )\n}\n","html,\nbody {\n height: 100%;\n}\n\n#app {\n height: 100%;\n}\n\n.taro-tabbar {\n &__border {\n &-white {\n &::before {\n border-top-color: #fff !important;\n }\n }\n }\n\n &__container {\n display: flex;\n overflow: hidden;\n flex-direction: column;\n height: 100%;\n }\n\n &__panel {\n overflow: auto;\n position: relative;\n flex: 1;\n -webkit-overflow-scrolling: auto;\n }\n\n &__tabbar {\n position: relative;\n width: 100%;\n height: 50px;\n transition: bottom 0.2s, top 0.2s;\n\n &-top {\n top: 0;\n }\n\n &-bottom {\n bottom: 0;\n margin-bottom: constant(safe-area-inset-bottom);\n margin-bottom: env(safe-area-inset-bottom);\n }\n\n &-hide {\n display: none;\n }\n\n &-slideout {\n top: -52px;\n flex: 0 0;\n }\n }\n\n &__panel + &__tabbar-slideout {\n top: auto;\n bottom: -52px;\n }\n}\n","import { Component, Prop, h, ComponentInterface, Host, State, Event, EventEmitter, Element } from '@stencil/core'\nimport Taro from '@tarojs/taro'\nimport { addLeadingSlash, stripBasename, stripSuffix } from '@tarojs/router/dist/utils'\nimport { IH5RouterConfig } from '@tarojs/taro/types/compile'\nimport classNames from 'classnames'\nimport resolvePathname from 'resolve-pathname'\n\nimport { splitUrl } from '../../utils'\nimport { TabbarItem } from './tabbar-item'\n\nconst STATUS_SHOW = 0\nconst STATUS_HIDE = 1\nconst STATUS_SLIDEOUT = 2\n\nconst basicTabBarClassName = 'taro-tabbar__tabbar'\nconst hideTabBarClassName = 'taro-tabbar__tabbar-hide'\nconst hideTabBarWithAnimationClassName = 'taro-tabbar__tabbar-slideout'\n\ninterface RouterHandler {\n index: string\n text: string\n url: string\n successHandler: Function\n errorHandler: Function\n animation?: boolean\n}\n\nexport interface Conf {\n color: string\n selectedColor: string\n backgroundColor: string\n borderStyle?: 'black' | 'white'\n list: TabbarList[]\n position?: 'bottom' | 'top'\n custom: boolean\n customRoutes: Record<string, string | string[]>\n mode: IH5RouterConfig['mode']\n basename: string\n homePage: string\n currentPagename: string\n}\n\ninterface TabbarList {\n pagePath: string\n text: string\n iconPath?: string\n selectedIconPath?: string\n badgeText?: string\n showRedDot?: boolean\n}\n\n@Component({\n tag: 'taro-tabbar',\n styleUrl: './style/index.scss'\n})\nexport class Tabbar implements ComponentInterface {\n private homePage = ''\n\n private customRoutes: Array<string[]> = []\n\n private tabbarPos: 'top' | 'bottom' = 'bottom'\n\n @Prop() conf: Conf\n\n @State() list: TabbarList[]\n\n @State() borderStyle: Conf['borderStyle']\n\n @State() backgroundColor: Conf['backgroundColor']\n\n @State() color: Conf['color']\n\n @State() selectedColor: Conf['selectedColor']\n\n @State() selectedIndex = -1\n\n @State() status: 0 | 1 | 2 = STATUS_SHOW\n\n @Event({\n eventName: 'longpress'\n }) onLongPress: EventEmitter\n\n @Element() tabbar: HTMLDivElement\n\n constructor () {\n const list = this.conf.list\n const customRoutes = this.conf.customRoutes\n if (\n Object.prototype.toString.call(list) !== '[object Array]' ||\n list.length < 2 ||\n list.length > 5\n ) {\n throw new Error('tabBar 配置错误')\n }\n\n this.homePage = addLeadingSlash(this.conf.homePage)\n for (let key in customRoutes) {\n const path = customRoutes[key]\n key = addLeadingSlash(key)\n if (typeof path === 'string') {\n this.customRoutes.push([key, addLeadingSlash(path)])\n } else if (path?.length > 0) {\n this.customRoutes.push(...path.map(p => [key, addLeadingSlash(p)]))\n }\n }\n\n list.forEach(item => {\n if (item.pagePath.indexOf('/') !== 0) {\n item.pagePath = '/' + item.pagePath\n }\n })\n\n this.list = list\n this.borderStyle = this.conf.borderStyle\n this.backgroundColor = this.conf.backgroundColor\n this.color = this.conf.color\n this.selectedColor = this.conf.selectedColor\n }\n\n getCurrentUrl () {\n const routerMode = this.conf.mode\n const routerBasename = this.conf.basename || '/'\n let url\n if (routerMode === 'hash') {\n const href = window.location.href\n const hashIndex = href.indexOf('#')\n url = hashIndex === -1\n ? ''\n : href.substring(hashIndex + 1)\n } else {\n url = location.pathname\n }\n const processedUrl = addLeadingSlash(stripBasename(url, routerBasename))\n return decodeURI(processedUrl === '/' ? this.homePage : processedUrl)\n }\n\n getOriginUrl = (url: string) => {\n const customRoute = this.customRoutes.filter(([, customUrl]) => {\n const pathA = splitUrl(customUrl).path\n const pathB = splitUrl(url).path\n return pathA === pathB\n })\n return stripSuffix(customRoute.length ? customRoute[0][0] : url, '.html')\n }\n\n getSelectedIndex = (url: string) => {\n let foundIndex = -1\n this.list.forEach(({ pagePath }, idx) => {\n const pathA = splitUrl(url).path\n const pathB = splitUrl(pagePath).path\n if (pathA === pathB) {\n foundIndex = idx\n }\n })\n return foundIndex\n }\n\n switchTab = (index: number) => {\n this.selectedIndex = index\n Taro.switchTab({\n url: this.list[index].pagePath\n })\n }\n\n switchTabHandler = ({ url, successHandler, errorHandler }: RouterHandler) => {\n const currentUrl = this.getOriginUrl(this.getCurrentUrl() || this.homePage)\n const nextTab = resolvePathname(url, currentUrl)\n const foundIndex = this.getSelectedIndex(nextTab)\n\n if (foundIndex > -1) {\n this.switchTab(foundIndex)\n successHandler({\n errMsg: 'switchTab:ok'\n })\n } else {\n errorHandler({\n errMsg: `switchTab:fail page \"${nextTab}\" is not found`\n })\n }\n }\n\n routerChangeHandler = (options?) => {\n const to = options?.toLocation?.path\n let currentPage\n\n if (typeof to === 'string') {\n const routerBasename = this.conf.basename || '/'\n currentPage = stripBasename(addLeadingSlash(to || this.homePage), routerBasename) || '/'\n } else {\n currentPage = this.getCurrentUrl()\n }\n\n this.selectedIndex = this.getSelectedIndex(this.getOriginUrl(currentPage))\n }\n\n setTabBarBadgeHandler = ({ index, text, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].showRedDot = false\n list[index].badgeText = text\n successHandler({\n errMsg: 'setTabBarBadge:ok'\n })\n } else {\n errorHandler({\n errMsg: 'setTabBarBadge:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n removeTabBarBadgeHandler = ({ index, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].badgeText = null\n list[index].badgeText = null\n successHandler({\n errMsg: 'removeTabBarBadge:ok'\n })\n } else {\n errorHandler({\n errMsg: 'removeTabBarBadge:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n showTabBarRedDotHandler = ({ index, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].badgeText = null\n list[index].showRedDot = true\n successHandler({\n errMsg: 'showTabBarRedDot:ok'\n })\n } else {\n errorHandler({\n errMsg: 'showTabBarRedDot:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n hideTabBarRedDotHandler = ({ index, successHandler, errorHandler }: RouterHandler) => {\n const list = [...this.list]\n if (index in list) {\n list[index].showRedDot = false\n successHandler({\n errMsg: 'hideTabBarRedDot:ok'\n })\n } else {\n errorHandler({\n errMsg: 'hideTabBarRedDot:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n showTabBarHandler = ({ successHandler }) => {\n this.status = STATUS_SHOW\n successHandler({\n errMsg: 'showTabBar:ok'\n })\n }\n\n hideTabBarHandler = ({ animation, successHandler }) => {\n this.status = animation ? STATUS_SLIDEOUT : STATUS_HIDE\n successHandler({\n errMsg: 'hideTabBar:ok'\n })\n }\n\n setTabBarStyleHandler = ({ color, selectedColor, backgroundColor, borderStyle, successHandler }) => {\n if (backgroundColor) this.backgroundColor = backgroundColor\n if (borderStyle) this.borderStyle = borderStyle\n if (color) this.color = color\n if (selectedColor) this.selectedColor = selectedColor\n successHandler({\n errMsg: 'setTabBarStyle:ok'\n })\n }\n\n setTabBarItemHandler = ({ index, iconPath, selectedIconPath, text, successHandler, errorHandler }) => {\n const list = [...this.list]\n if (index in list) {\n if (iconPath) list[index].iconPath = iconPath\n if (selectedIconPath) list[index].selectedIconPath = selectedIconPath\n if (text) list[index].text = text\n successHandler({\n errMsg: 'setTabBarItem:ok'\n })\n } else {\n errorHandler({\n errMsg: 'setTabBarItem:fail tabbar item not found'\n })\n }\n\n this.list = list\n }\n\n bindEvent () {\n Taro.eventCenter.on('__taroRouterChange', this.routerChangeHandler)\n Taro.eventCenter.on('__taroSwitchTab', this.switchTabHandler)\n Taro.eventCenter.on('__taroSetTabBarBadge', this.setTabBarBadgeHandler)\n Taro.eventCenter.on('__taroRemoveTabBarBadge', this.removeTabBarBadgeHandler)\n Taro.eventCenter.on('__taroShowTabBarRedDotHandler', this.showTabBarRedDotHandler)\n Taro.eventCenter.on('__taroHideTabBarRedDotHandler', this.hideTabBarRedDotHandler)\n Taro.eventCenter.on('__taroShowTabBar', this.showTabBarHandler)\n Taro.eventCenter.on('__taroHideTabBar', this.hideTabBarHandler)\n Taro.eventCenter.on('__taroSetTabBarStyle', this.setTabBarStyleHandler)\n Taro.eventCenter.on('__taroSetTabBarItem', this.setTabBarItemHandler)\n }\n\n removeEvent () {\n Taro.eventCenter.off('__taroRouterChange', this.routerChangeHandler)\n Taro.eventCenter.off('__taroSwitchTab', this.switchTabHandler)\n Taro.eventCenter.off('__taroSetTabBarBadge', this.setTabBarBadgeHandler)\n Taro.eventCenter.off('__taroRemoveTabBarBadge', this.removeTabBarBadgeHandler)\n Taro.eventCenter.off('__taroShowTabBarRedDotHandler', this.showTabBarRedDotHandler)\n Taro.eventCenter.off('__taroHideTabBarRedDotHandler', this.hideTabBarRedDotHandler)\n Taro.eventCenter.off('__taroShowTabBar', this.showTabBarHandler)\n Taro.eventCenter.off('__taroHideTabBar', this.hideTabBarHandler)\n Taro.eventCenter.off('__taroSetTabBarStyle', this.setTabBarStyleHandler)\n Taro.eventCenter.off('__taroSetTabBarItem', this.setTabBarItemHandler)\n }\n\n componentDidLoad () {\n this.tabbarPos = this.tabbar.nextElementSibling ? 'top' : 'bottom'\n this.bindEvent()\n this.routerChangeHandler()\n }\n\n disconnectedCallback () {\n this.removeEvent()\n }\n\n render () {\n const { tabbarPos = 'bottom' } = this\n const status = this.status\n const containerCls = classNames('weui-tabbar', {\n [`taro-tabbar__border-${this.borderStyle || 'black'}`]: true\n })\n const shouldHideTabBar = this.selectedIndex === -1 || status === STATUS_HIDE\n const shouldSlideout = status === STATUS_SLIDEOUT\n\n return (\n <Host\n class={classNames(\n basicTabBarClassName,\n `${basicTabBarClassName}-${tabbarPos}`, {\n [hideTabBarClassName]: shouldHideTabBar,\n [hideTabBarWithAnimationClassName]: shouldSlideout\n })} >\n <div\n class={containerCls}\n style={{\n backgroundColor: this.backgroundColor || '',\n height: 'inherit'\n }}\n >\n {this.list.map((item, index) => {\n const isSelected = this.selectedIndex === index\n let textColor\n let iconPath\n if (isSelected) {\n textColor = this.selectedColor || ''\n iconPath = item.selectedIconPath\n } else {\n textColor = this.color || ''\n iconPath = item.iconPath\n }\n return (\n <TabbarItem\n index={index}\n onSelect={this.switchTab.bind(this)}\n isSelected={isSelected}\n textColor={textColor}\n iconPath={iconPath}\n pagePath={item.pagePath}\n text={item.text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