• 微信小程序 简单控件


    1.滚动栏设置

    <!--wxml-->
    <
    scroll-view class="container1" scroll-y> <view>1</view> <view>2</view> <view>3</view> </scroll-view >
    /* pages/list/list.wxss */
    .container1 view{
      width: 100px;
      height: 100px;
      text-align: center;
      line-height: 100px;
    }
    
    .container1 view:nth-child(1){
      background-color: lightgreen;
    }
    .container1 view:nth-child(2){
      background-color: lightblue;
    }
    .container1 view:nth-child(3){
      background-color: lightcoral;
    }
    
    .container1{
      border: 1px solid red;
      width: 100px;
      height: 120px;
    }

     2.轮播图

    <!--pages/list/list.wxml-->
    <!--轮播图的结构-->
    <swiper class="swiper-container" indicator-dots indicator-color="white" indicator-active-color="red" autoplay interval="3000" circular>
    <!--第一个轮播图-->
    <swiper-item>
      <view class="item">A</view>
    </swiper-item>
    <!--第二个轮播图-->
    <swiper-item>
      <view class="item">B</view>
    </swiper-item>
    <!--第三个轮播图-->
    <swiper-item>
      <view class="item">C</view>
    </swiper-item>
    </swiper>
    /* pages/list/list.wxss */
    .swiper-container{
      height: 150px;
    }
    .item{
      height: 100%;
      line-height: 150px;
      text-align: center;
    }
    
    swiper-item:nth-child(1) .item{
      background-color: lightgreen;
    }
    swiper-item:nth-child(2) .item{
      background-color: lightblue;
    }
    swiper-item:nth-child(3) .item {
      background-color: lightpink;
    }

    <view>
    手机号支持长安转中效果
    <text user-select>15930901693</text>
    </view>
    <rich-text nodes="<h1 style='color :red;'>标题</h1>"></rich-text>
  • 相关阅读:
    Quartz 基本概念及原理
    quartz-2.2.x 快速入门 (1)
    hive踩过的小坑
    spring profile 多环境配置管理
    win10窗口设置眼睛保护色
    优雅地在markdown插入图片
    Using Spring Boot without the parent POM
    isDebugEnabled作用
    Log 日志级别
    为什么要使用SLF4J而不是Log4J
  • 原文地址:https://www.cnblogs.com/wfswf/p/15782530.html
Copyright © 2020-2023  润新知