Merge branch 'master' of http://git.luyuan.tk/luyuan/deming into zhy

This commit is contained in:
ghusermoon 2020-06-02 11:41:33 +08:00
commit 963dc86404
11 changed files with 319 additions and 31 deletions

3
.gitignore vendored
View File

@ -1 +1,2 @@
.vscode
.vscode
node_modules

View File

@ -2,7 +2,7 @@
## 使用
- scss
- uniapp
- 组建库待定
- 组建库 [uview](http://www.uviewui.com/)
## 目录结构
```1=
|-pages tabes 目录

View File

@ -0,0 +1,25 @@
<template>
<swiper class="ad" indicator-dots="true" indicator-color="#fff" indicator-active-color="#634838">
<swiper-item></swiper-item>
<swiper-item></swiper-item>
<swiper-item></swiper-item>
</swiper>
</template>
<style lang="scss" scoped>
.ad{
width: 100%;
height: 294rpx;
border-radius: 20rpx;
background-color: #0f0;
}
</style>
<script>
export default {
name:"ad",
data(){
return {
}
}
}
</script>

View File

@ -0,0 +1,54 @@
<template>
<view class="daren-item">
<image class="head"></image>
<text class="name">这是名字</text>
<text class="zhuangtai">直播状态</text>
<view class="guanzhu">关注</view>
</view>
</template>
<script>
export default {
name:"daren-item"
}
</script>
<style lang="scss" scoped>
.daren-item{
width: 215rpx;
height: 282rpx;
display: flex;
flex-direction: column;
align-items: center;
background-color: #fff;
border-radius: 10rpx;
overflow: hidden;
.head{
width: 80rpx;
height: 80rpx;
border-radius: 50%;
margin-top: 24rpx;
background-color: #0f0;
}
.name{
font-size: 26rpx;
color: #333;
font-weight: 400;
margin-top: 23rpx;
}
.zhuangtai{
font-size:22rpx;
color: #999;
margin-top: 19rpx;
}
.guanzhu{
width: 130rpx;
height: 50rpx;
background-color: #FF780F;
font-size: 26rpx;
line-height: 50rpx;
color: #fff;
text-align: center;
margin-top: 19rpx;
border-radius: 25rpx;
}
}
</style>

View File

@ -4,10 +4,11 @@
</image>
<view class="title">这是标题这是标题这是标题</view>
<view class="jianjie">这是简介这是简介这是简介</view>
<view class="user">
<view>
<image></image>
<text></text>
<text>这是名字</text>
</view>
<image></image>
</view>
@ -15,21 +16,36 @@
</template>
<style lang="scss" scoped>
.video-item{
image{
background-color: #0f0;
}
margin-top: 20rpx;
width: 335rpx;
box-shadow:0 3rpx 7rpx 0 rgba(153, 153, 153, 0.35);
padding-bottom: 20rpx;
border-radius: 20rpx;
overflow: hidden;
.head{
width: 100%;
height: 334rpx;
border-radius: 20rpx 0;
}
.title{
margin:0 auto;
margin-top: 20rpx;
font-size: 22rpx;
color: #333;
font-weight: 500;
line-height: 30rpx;
width: 307rpx;
overflow:hidden;
text-overflow:ellipsis;
display:-webkit-box;
-webkit-box-orient:vertical;
-webkit-line-clamp:2;
}
.jianjie{
margin:0 auto;
margin-top: 20rpx;
font-size: 22rpx;
color: #666;
line-height: 30rpx;
margin-top: 20px;
width: 307rpx;
margin-left: 18rpx;
overflow:hidden;
@ -37,18 +53,28 @@
display:-webkit-box;
-webkit-box-orient:vertical;
-webkit-line-clamp:2;
}
.user{
display: flex;
justify-content: space-between;
align-items: center;
margin:0 auto;
margin-top: 20rpx;
width: 307rpx;
>view{
display: flex;
align-items: center;
>image{
width: 38rpx;
height: 38rpx;
border-radius: 50%;
}
>text{
font-size: 20rpx;
color:#333;
margin-left: 9rpx;
}
}
>image{

View File

@ -0,0 +1,75 @@
<template>
<view class="zhibo">
<image class="head"></image>
<view class="user">
<view class="name">
<image></image>
<text>这是名字</text>
</view>
<view class="pingbi">
<image></image>
<text>屏蔽用户</text>
</view>
</view>
</view>
</template>
<style lang="scss" scoped>
.zhibo{
width: 335rpx;
margin-top: 20rpx;
box-shadow:0 3rpx 7rpx 0 rgba(153, 153, 153, 0.35);
padding-bottom: 20rpx;
border-radius: 20rpx;
overflow: hidden;
.head{
width: 100%;
height: 425rpx;
}
.user{
display: flex;
justify-content: space-between;
align-items: center;
margin:0 auto;
margin-top: 20rpx;
width: 307rpx;
.name{
display: flex;
align-items: center;
>image{
width: 38rpx;
height: 38rpx;
border-radius: 50%;
}
>text{
font-size: 20rpx;
color:#333;
margin-left: 9rpx;
}
}
.pingbi{
display: flex;
align-items: center;
>text{
font-size: 20rpx;
color: #333;
margin-left: 9rpx;
}
>image{
width: 24rpx;
height: 24rpx;
}
}
}
}
</style>
<script>
export default {
name:"zhibo-item",
data(){
return {
}
}
}
</script>

View File

@ -1,11 +1,11 @@
import Vue from 'vue'
import App from './App'
import uView from "uview-ui";
Vue.config.productionTip = false
Vue.use(uView);
App.mpType = 'app'
const app = new Vue({
...App
})
app.$mount()
app.$mount()

13
package-lock.json generated Normal file
View File

@ -0,0 +1,13 @@
{
"name": "deming",
"version": "1.0.0",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
"uview-ui": {
"version": "1.2.9",
"resolved": "https://registry.npm.taobao.org/uview-ui/download/uview-ui-1.2.9.tgz",
"integrity": "sha1-PwC6ziaB/LXyMacGRkMfPrZfF2c="
}
}
}

18
package.json Normal file
View File

@ -0,0 +1,18 @@
{
"name": "deming",
"version": "1.0.0",
"description": "- scss - uniapp - 组建库 [uview](http://www.uviewui.com/) ## 目录结构 ```1= |-pages tabes 目录 |-pageA 前期注册用页面 |-pageB 首页类页面 |-pageC 商城下页面 |-pageD 我的页面 |-pageE 其余杂乱页面 |-components 组建目录 |-static 静态文件目录 |-|images 图片文件 |util js库文件 |App.js |main.js |pages.json |manifest.json |uni.scss ``` ## 开发规范 - 使用组建化 - 要使用scss - 命名尽量规范 可以语义化但不可以胡乱输入 - scss层级关系使用好 - 统一使用rpx - 组建目录需要根据页面或功能命名子目录 ## 分支开发规则 - master分支将开启保护 请使用gitea合并功能 - 每人各自工作分支 每天合并 - 合并请及时拉取处理冲突",
"main": "main.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"repository": {
"type": "git",
"url": "http://git.luyuan.tk/luyuan/deming.git"
},
"author": "",
"license": "ISC",
"dependencies": {
"uview-ui": "^1.2.9"
}
}

View File

@ -12,26 +12,56 @@
<swiper class="card">
<swiper-item>
<scroll-view style="width:100%;height:100%" scroll-y="true">
<swiper class="ad" indicator-dots="true" indicator-color="#fff" indicator-active-color="#634838">
<swiper-item></swiper-item>
<swiper-item></swiper-item>
<swiper-item></swiper-item>
</swiper>
<videoItem></videoItem>
<view class="box">
<indexad style="width:690rpx"></indexad>
<view class="list">
<view >
<videoItem v-for="item in 10"></videoItem>
</view>
<view style="margin-left:20rpx">
<videoItem v-for="item in 10"></videoItem>
</view>
</view>
</view>
</scroll-view>
</swiper-item>
<swiper-item>
<scroll-view style="width:100%;height:100%" scroll-y="true">
<view id="demo1" class="scroll-view-item uni-bg-red">A</view>
<view id="demo2" class="scroll-view-item uni-bg-green">B</view>
<view id="demo3" class="scroll-view-item uni-bg-blue">C</view>
<view class="box">
<indexad style="width:690rpx"></indexad>
<view class="list">
<view >
<zhiboItem v-for="item in 10"></zhiboItem>
</view>
<view style="margin-left:20rpx">
<zhiboItem v-for="item in 10"></zhiboItem>
</view>
</view>
</view>
</scroll-view>
</swiper-item>
<swiper-item>
<scroll-view style="width:100%;height:100%" scroll-y="true">
<view id="demo1" class="scroll-view-item uni-bg-red">A</view>
<view id="demo2" class="scroll-view-item uni-bg-green">B</view>
<view id="demo3" class="scroll-view-item uni-bg-blue">C</view>
<view class="box">
<view class="tuijian">
<view class="title">
<view class="left">
<view></view>
<text>推荐达人</text>
</view>
<image class="right"></image>
</view>
<view class="tuijianlist">
<darenItem style="margin-right:23rpx"></darenItem>
<darenItem style="margin-right:23rpx"></darenItem>
<darenItem></darenItem>
</view>
</view>
</view>
</scroll-view>
</swiper-item>
</swiper>
@ -41,11 +71,11 @@
<style lang="scss" scoped>
.index{
width: 750rpx;
padding: 0 30rpx;
display: flex;
flex-direction: column;
height: 100vh;
.top{
padding: 0 30rpx;
display: flex;
justify-content: space-between;
width: 100%;
@ -55,7 +85,6 @@
.sosuo{
width: 32rpx;
height: 32rpx;
background-color: #0f0;
}
.tabs{
display: flex;
@ -83,19 +112,62 @@
}
}
.card{
width: 100%;
height: 100%;
.ad{
width: 100%;
.box{
width: 100%;
height: 294rpx;
border-radius: 20rpx;
background-color: #0f0;
padding: 0 30rpx;
}
.list{
display: flex;
}
}
.tuijian{
width: 750rpx;
margin-left: -30rpx;
height: 400rpx;
background-color: #ececec;
padding: 30rpx;
.title{
width: 100%;
display: flex;
align-items: center;
justify-content: space-between;
.left{
display: flex;
align-items: center;
>view{
width: 6rpx;
height: 30rpx;
background-color: #FF780F;
}
>text{
font-size: 30rpx;
color: 30rpx;
margin-left: 14rpx;
}
}
.right{
width: 14rpx;
height: 24rpx;
}
}
.tuijianlist{
width: 100%;
height: 282rpx;
margin-top: 30rpx;
display: flex;
}
}
}
</style>
<script>
import videoItem from "@/components/index/video-item/index"
import zhiboItem from "@/components/index/zhibo-item/index"
import indexad from "@/components/index/ad/index"
import darenItem from "@/components/index/daren-item/index"
export default {
name:"index",
data(){
@ -104,7 +176,10 @@ export default {
}
},
components:{
videoItem
videoItem,
zhiboItem,
indexad,
darenItem
}
}
</script>

View File

@ -1,3 +1,4 @@
@import 'node_modules/uview-ui/theme.scss';
/**
* 这里是uni-app内置的常用样式变量
*