Comments (4)
您好,
<ui-swiper>
如何增加跳转页面呢?目前我是在ui-swiper.js的toTap()
函数中增加跳转代码wx.navigateTo({url: e.currentTarget.dataset.item.url })
,直接改动组件显然是不合理的,请问该如何操作实现<ui-swiper>
跳转页面呢?
您好,非常抱歉,暂时还不支持设置跳转或返回点击事情,今天晚上我完善下,完善后,我会回复您。
from mp-cu.
您好,
<ui-swiper>
如何增加跳转页面呢?目前我是在ui-swiper.js的toTap()
函数中增加跳转代码wx.navigateTo({url: e.currentTarget.dataset.item.url })
,直接改动组件显然是不合理的,请问该如何操作实现<ui-swiper>
跳转页面呢?
您好,已经修复了。
使用方式如下:
//type: switchTab/reLaunch/redirectTo/navigateTo/eve
swiperList: [
{
img: 'https://ossweb-img.qq.com/images/lol/web201310/skin/big84000.jpg',
url: '/pages/document/system/system',
type: 'navigateTo' //直接跳转类型
},
{
img: 'https://ossweb-img.qq.com/images/lol/web201310/skin/big37006.jpg',
url: '/pages/custom/home',
type: 'switchTab' //直接跳转类型
},
{
img: 'https://ossweb-img.qq.com/images/lol/web201310/skin/big39000.jpg',
type: 'eve' //事件方式
},
{
img: 'https://ossweb-img.qq.com/images/lol/web201310/skin/big10001.jpg',
type: 'eve'
},
]
加事件
<ui-swiper info="{{swiperList}}" dotCur="ui-BG-Main" bind:uiTap="swiperTap"/>
注意type: switchTab/reLaunch/redirectTo/navigateTo/eve
类型为eve时,为点击事件,不会跳转,其它类型会跳转。
from mp-cu.
您好,
<ui-swiper>
如何增加跳转页面呢?目前我是在ui-swiper.js的toTap()
函数中增加跳转代码wx.navigateTo({url: e.currentTarget.dataset.item.url })
,直接改动组件显然是不合理的,请问该如何操作实现<ui-swiper>
跳转页面呢?您好,已经修复了。
使用方式如下:
//type: switchTab/reLaunch/redirectTo/navigateTo/eve swiperList: [ { img: 'https://ossweb-img.qq.com/images/lol/web201310/skin/big84000.jpg', url: '/pages/document/system/system', type: 'navigateTo' //直接跳转类型 }, { img: 'https://ossweb-img.qq.com/images/lol/web201310/skin/big37006.jpg', url: '/pages/custom/home', type: 'switchTab' //直接跳转类型 }, { img: 'https://ossweb-img.qq.com/images/lol/web201310/skin/big39000.jpg', type: 'eve' //事件方式 }, { img: 'https://ossweb-img.qq.com/images/lol/web201310/skin/big10001.jpg', type: 'eve' }, ]加事件
<ui-swiper info="{{swiperList}}" dotCur="ui-BG-Main" bind:uiTap="swiperTap"/>
注意type: switchTab/reLaunch/redirectTo/navigateTo/eve
类型为eve时,为点击事件,不会跳转,其它类型会跳转。
感谢,我试一下
from mp-cu.
from mp-cu.
Related Issues (20)
- 版本号没更新 HOT 1
- footer: false,页脚貌似不起作用 HOT 2
- loading: false不起作用 HOT 2
- ui-img 这个组件的_preview方法,如果使用catchtap的话会导致小程序崩溃。 HOT 12
- 使用2.21.0以上版本号时,出现错误导致页面白屏。 HOT 3
- 微信开发者工具Nightly 1.05.2202142之后的版本打开小程序页面样式异常 HOT 1
- 不同的页面能修改配置显示不同tabbar吗 HOT 2
- tabbar不支持setTabBarBadge是吗 HOT 1
- $cuData赋值问题 HOT 1
- $tips 有时候从一个页面到另一个页面关不掉 HOT 2
- ui-modal 中的_cancel方法有问题 HOT 1
- 复选框ui-checkbox-group全选状态值isAllChecked初始值状态异常问题
- loading="{{true}}" 800ms 后依然关闭了loading
- modal 模态框遮罩层无法覆盖input输入框 HOT 1
- ui-swiper 不显示图片
- 什么时候能全部完成??
- ui-popover 异常触发 HOT 1
- toast demo问题 HOT 2
- 导航栏 HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mp-cu.