vue.js上下滚动_Vue.js流畅流畅的滚动动画

vue.js上下滚动

滚子 (vue-roller)

Fluid and smooth rolling animation for Vue.js.

Vue.js流畅流畅的滚动动画。

example1

example2

入门 (Getting Started)

npm

npm

npm i vue-roller

Vue

Vue

import Roller from "vue-roller";

export default {
    components:{
        Roller
    }
}
...

Vue-typescript

Vue打字稿

import Roller from "vue-roller";

@Component({
	components: { Roller }
})
...

选件 (Options)

文字(必填) (text (Required))

<Roller text="1234">

Displays text.

显示文字。

过渡 (transition)

<Roller transition="1">

Sets the time for the animation to complete in second(s). 0.5 by default.

设置动画完成的时间(以秒为单位)。 默认0.5

isNumberFormat (isNumberFormat)

<Roller isNumberFormat="true">

Can be set to true if you want to display commas as thousands separators. false by default.

如果要将逗号显示为数千个分隔符,可以将其设置为true 。 默认为false

字符列表 (charList)

<Roller :charList="['a', 'b', 'c']">

Sets the list of characters used for the animation.

设置用于动画的字符列表。

Default: ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9"]

默认值: ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9"]

defaultChar (defaultChar)

<Roller defaultChar="0">

Sets the text to display when the page is first loaded before the animation actually starts. "" by default.

设置在动画实际开始之前首次加载页面时显示的文本。 默认情况下为""

翻译自: https://vuejsexamples.com/fluid-and-smooth-rolling-animation-for-vue-js/

vue.js上下滚动

  • 1
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值