当前位置: 首页 > news >正文

织梦cms网站地图网站对于企业的好处

织梦cms网站地图,网站对于企业的好处,最好用的搜索引擎,怎么查域名的注册人前言 使用小程序默认的tabbar可以满足常规开发#xff0c;但是满足不了个性化需求#xff0c;如果想个性化开发就需要用到自定义tabbar,以下图为例子 一、在app.json配置 先按照以往默认的形式配置#xff0c;如果中间的样式特殊则不需要配置 tabBar: {但是满足不了个性化需求如果想个性化开发就需要用到自定义tabbar,以下图为例子 一、在app.json配置 先按照以往默认的形式配置如果中间的样式特殊则不需要配置 tabBar: {custom:true, // 开启自定义tabbarcolor: #333333, // tabbar文字默认颜色selectedColor: #2E41FF, // tabbar文字选中颜色list: [{pagePath: pages/index/index,iconPath: images/customTabBar/home.png,selectedIconPath: images/customTabBar/homeSelect.png,text: 首页},{pagePath: pages/user/user,iconPath: images/customTabBar/my.png,selectedIconPath: images/customTabBar/mySelect.png,text: 我的}] },二、在app.js中配置 tabBar: {color: #333333,selectedColor: #2E41FF,list: [{pagePath: /pages/index/index,iconPath: /images/customTabBar/home.png,selectedIconPath: /images/customTabBar/homeSelect.png,text: 首页,selected:true //该tabbar是否选中的标识},{pagePath: ,iconPath: /images/customTabBar/camera.png,selectedIconPath: /images/customTabBar/camera.png,isSpecial: true, //是否为特殊的那个tabselected:false},{pagePath: /pages/user/user,iconPath: /images/customTabBar/my.png,selectedIconPath: /images/customTabBar/mySelect.png,text: 我的,selected:false}] }三、app.js注册tabbar点击方法 主要作用为控制跳转的路径当前tab及选中的样式 editTabbar() {let tabbar this.globalData.tabBar;let currentPages getCurrentPages();let _this currentPages[currentPages.length - 1];let pagePath _this.route;(pagePath.indexOf(/) ! 0) (pagePath / pagePath);for (let i in tabbar.list) {tabbar.list[i].selected false;(tabbar.list[i].pagePath pagePath) (tabbar.list[i].selected true);}_this.setData({tabbar: tabbar}); },四、封装自定义tabbar组件 1.html view classub-tab-barblock wx:for{{tabbar.list}} wx:keyindex!-- 中间特殊tab --view wx:if{{item.isSpecial}} classub-tab-bar-item bindtapcameraimage modewidthFix src{{item.iconPath}} class{{item.pagePath ? ub-camera : }}/imageview{{item.text}}/view/view!-- 两侧tab -- navigator wx:else classub-tab-bar-item hover-classnone url{{item.pagePath}} stylecolor:{{item.selected ? tabbar.selectedColor : tabbar.color}} open-typeswitchTabimage modewidthFix src{{item.selected ? item.selectedIconPath : item.iconPath}}/imageview{{item.text}}/view/navigator/block /view2.json 接收父组件传过来的值 properties: {tabbar: {type: Object} },五、在用到的页面引用tabbar组件 在需要用到tabbar的页面引用 1.json中引用 usingComponents: {tabBar: /components/customTabBar/customTabBar,}2.js data中获取在app.js定义的tabBar data: {tabBar:app.globalData.tabBar } //隐藏移动的tabbar并调用app.js定义的方法 onLoad(){wx.hideTabBar()app.editTabbar(); }3.html中引用 获取到的方法想子组件中传递 tabBar tabbar{{tabBar}}/tabBar
http://www.sadfv.cn/news/435506/

相关文章:

  • 网站建设网页制作软件校园图书馆网站建设
  • 昆明做网站猫咪科技房屋3d立体设计软件
  • 超链接到网站怎么做视频文件下载餐饮网站建设背景
  • 南京建设局网站网站怎么做六个页面
  • dw做汽车网站出效果图
  • 织梦手机网站怎么做郑州网站设
  • 网站做管理员功能代码公司介绍信模板
  • 建设集团网站报告书网站的字体做多大
  • html网页设计大赛作品鄂州seo
  • 昆明建网站的公司做企业官网费用
  • 博客网站排名大全wordpress数据库新增用户密码忘记
  • 越辉网站建设网页无法访问的原因
  • 济南网站建设工作室wordpress 新闻面板
  • 网站开发技术语言开发软件的应用
  • 广州企业网站建站网站开发 岗位及职责
  • 万网空间最多放几个网站北京平台网站建设报价
  • 湘潭市建设工程质量监督站网站wordpress做导航插件
  • 企业网站设计的要求接外包的平台
  • 企业网站建设方案书 备案企业网站建设要多
  • 苏州那家公司做网站好怎么做根优酷差不多的网站
  • 搜索网站的设计与建设软文推广平台有哪些
  • 西安航空城建设发展集团网站wordpress 表单邮件
  • 智慧团建网站没有验证码福田欧曼重卡
  • 电子商务网站设计的基本要求海南在线人才网招聘信息
  • 类似58同城分类信息网站开发大连在哪个省的什么位置
  • 网站建设 模块phpmysql网站开发
  • 建设网站后如何做后台qq开放平台网站开发申请不通过的原因
  • 安防监控网站模板对网站主要功能界面进行赏析
  • 化妆品网站模板找文网优化服务
  • 中英版网站系统wordpress活动报名功能