weex 引导页(guide)页面

摘要:
滑块和指示器都是Weex的内置组件,指示器是滑块的子组件。

slider 和 indicator 都是 weex 的内置组件,且 indicator 是 slider 的子组件。

1.报错处理

weex 引导页(guide)页面第1张

原因解析:indicator 样式页面渲染慢

解决方案:indicator 的样式写为 内联样式

2.Guide.vue

<!-- 引导页 -->
<template>
  <div class="wrap">
    <!-- 轮播图 -->
    <slider   auto-play="true" interval="5000" >
      <div   v-for="item in itemList">
        <image   :src="http://t.zoukankan.com/item.pictureUrl" resize="stretch"></image>
      </div>
      <!-- 指示器   -->
      <indicator class="indicator"></indicator>
    </slider>
    <!-- 开始体验 -->
    <text   @click="goStart">{{txt}}</text>
  </div>
</template>

<style scoped>
 .wrap{
    align-items: center;
    justify-content: center;
    flex-direction: column;
    background-color: #2B2D2F;
  }
  /*轮播图*/
  .slider {
     750px;
    height: 1000px;
    background-color: transparent;
    align-items: center;
    justify-content: center;
    margin-top: 0px;
    margin-bottom: 0px;
    margin-left: auto;
    margin-right: auto;
  }
  /*轮播图 图片*/
  .slider-pages {
    flex-direction: row;
     720px;
    height: 1000px;
    align-items: center;
    justify-content: center;
    margin-top: 0px;
    margin-bottom: 0px;
    margin-left: auto;
    margin-right: auto;
  }
  .thumb {
     720px;
    height: 1280px;
    align-items: center;
    justify-content: center;
    margin-top: 0px;
    margin-bottom: 0px;
    margin-left: auto;
    margin-right: auto;
  }
  /*轮播图 指示器*/
  .indicator {
    position: absolute;
    top: 970px;
     720px;
    height: 30px;
    item-color: #dddddd;
    item-selected-color: rgb(40, 96, 144);
  }
  /*开始体验 按钮*/
  .btn{
     300px;
    height: 60px;
    margin-top: 20px;
    background-color:#0096FF;
    font-size:25px;
    height:60px;
    font-weight: bold;
    align-items: center;
    justify-content: center;
    border-radius: 50;
    color:#FFFFFF;
  }
</style>

<script>
  export default {
    data() {
      return {
        txt:"开始体验",
        itemList: [
          {title: 'A', pictureUrl: 'https://duqian291902259.github.io/dusan/oair/bg1.png'},
          {title: 'B', pictureUrl: 'https://duqian291902259.github.io/dusan/oair/bg2.png'},
          {title: 'C', pictureUrl: 'https://duqian291902259.github.io/dusan/oair/bg1.png'}
        ]
      }
    },
    methods: {
      goStart() {
        // 页面跳转
        this.$router.push({path:'/splash'});
      }
    }
  }
</script>

3.效果图

weex 引导页(guide)页面第2张

免责声明:文章转载自《weex 引导页(guide)页面》仅用于学习参考。如对内容有疑问,请及时联系本站处理。

上篇python学习——re模块【数据结构】二叉树、普通树与森林的定义与应用下篇

宿迁高防,2C2G15M,22元/月;香港BGP,2C5G5M,25元/月 雨云优惠码:MjYwNzM=

相关文章

scss基本使用及操作函数

操作函数 1、for循环 @for … from … through @for $var from <start> through <end> // 范围包括<start>和<end>的值 @for … from … to @for $var from <start> to <end&g...

margin的深入理解

第一部分:margin--基础知识 要介绍margin的基础知识,我们不可回避地要谈到css盒子模型(Box Model),一般而言,css盒子模型是用来设计和布局的。它本质上是一个盒子,包括:外边距(margin)、边框(border)、内边距(padding)以及最中间的内容(content)。下图即为盒子模型(这里只谈W3C规范的标准盒模型,而不谈I...

element el-table 合计在横拉滚动条的下面,正确展示应该是滚动条在合计下面

<style lang="less"> .el-table{ overflow: auto; } .el-table .el-table__body-wrapper, .el-table .el-table__header-wrapper, .el-table .el-table__footer-wrapper{ overflow: v...

Qt StyleSheet样式表实例(转)

QT论坛看到的,收藏一下! 在涉及到Qt 美工的时候首先需要掌握CSS 级联样式表。 下面将通过几个例子来介绍一下怎样使用Qt中的部件类型设计。自定义的前台背景与后台背景的颜色: 如果需要一个文本编辑器的背景变为黄色, 下面是代码行: qApp->setStyleSheet("QLineEdit {  针对一个对话框的内容中使用QLineEdit以及...

CSS(八)-- 变形(过渡、动画、平移、旋转、缩放)

目录 1.过渡(transition) 1.1transition-property:指定执行过渡的属性 1.2transition-duration:执行过渡需要的时间 1.3transition-timing-function:过得的时序函数 通过贝塞尔曲线指定 steps()分步执行过渡效果 1.4 transition-delay:过...

CSS对各个浏览器兼容技巧HACK技巧

*   ie6和ie7都可以识别_   只有ie6可以识别\0  只有ie8可以识别:root 只有ie9可以识别  关于CSS对各个浏览器兼容已经是老生常谈的问题了, 网络上的教程遍地都是.以下内容没有太多新颖, 纯属个人总结, 希望能对初学者有一定的帮助. 一、CSS HACK HACK概念: 不同的浏览器,比如Internet Explorer 6,...