Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/SoloJiang/wepy-slide-card
https://github.com/SoloJiang/wepy-slide-card
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/SoloJiang/wepy-slide-card
- Owner: SoloJiang
- Created: 2018-03-11T15:56:25.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2018-03-12T03:12:07.000Z (almost 7 years ago)
- Last Synced: 2024-10-13T11:11:00.707Z (3 months ago)
- Language: JavaScript
- Size: 29.3 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-wepy - wepy-slide-card: 基于wepy的slide-card组件
README
## 微信小程序 wepyjs 第三方slide-card组件
![demo](demo.gif)
### 说明
1.0版本暂不支持滑块跟随手指移动,该功能将在后面开发。
### 使用
#### 安装组件
```shell
npm install wepy-slide-card --save
```#### 引入组件
```html
Left0
Left1
Slide
import wepy from 'wepy'
import SlideCard from 'wepy-slide-card'export default class Index extends wepy.page {
data = {
a: 5,
b: 1
}
components = {
SlideCard
}
}```
#### 使用方法
需要分别传入``constantFlex`` ``slideFlex``给滑块分别作为左侧固定滑块和右侧显隐滑块的宽度,两者是比例关系(flex),两侧的内容采用slot的方式设计,具体使用参照上面。