1 . 概述
我们在学习微信小程序或者做项目时,应该会遇到滚动通知效果情况,那么这个滚动通知功能我们应该怎么编写呢?
今天我们说下微信小程序滚动通知效果的实现,今天我们就分享这样的小教程。希望对大家有所帮助。
不多说了,二当家要上图来啦!
今天分享的是图一
快去拿个小板凳,坐等跟多Tab更新
2 . wxml
<view> 显示完后再显示</view>
<view class="example">
<view class="marquee_box">
<view class="marquee_text" style="{
{orientation}}:{
{marqueeDistance}}px;font-size: {
{size}}px;">
{
{text}}
</view>
</view>
</view>
<view> 出现白边后即显示</view>
<view class="example">
<view class="marquee_box">
<view class="marquee_text" style="{
{orientation}}:{
{marqueeDistance2}}px;font-size: {
{size}}px;">
<text>{
{text}}</text>
<text wx:if="{
{marquee2copy_status}}" style="margin-left:{
{marquee2_margin}}px;">{
{text}}</text>
</view>
</view>