Commit b13f0311 authored by guoyou's avatar guoyou

首页修复

parent 5e2f097e
...@@ -144,6 +144,7 @@ li { ...@@ -144,6 +144,7 @@ li {
.swiper-containerActivity .swiper-wrapper .swiper-slide { .swiper-containerActivity .swiper-wrapper .swiper-slide {
width: 100%; width: 100%;
padding-right: 10px;
} }
.swiper-containerActivity .swiper-wrapper .swiper-slide img { .swiper-containerActivity .swiper-wrapper .swiper-slide img {
...@@ -161,7 +162,8 @@ li { ...@@ -161,7 +162,8 @@ li {
} }
.swiper-containerActivity .left:hover { .swiper-containerActivity .left:hover {
box-shadow: 0px 20px 40px 0px rgba(102, 102, 102, 0.3); background: rgba(255, 255, 255, 1);
box-shadow: 0px 0px 12px 0px rgba(0, 0, 0, .15);
} }
.swiper-containerActivity .left img { .swiper-containerActivity .left img {
...@@ -213,7 +215,8 @@ li { ...@@ -213,7 +215,8 @@ li {
.swiper-containerActivity ul li:hover { .swiper-containerActivity ul li:hover {
/* box-shadow: -1px 4px 12px rgba(0, 0, 0, .1); */ /* box-shadow: -1px 4px 12px rgba(0, 0, 0, .1); */
box-shadow: 0px 20px 40px 0px rgba(102, 102, 102, 0.3); background: rgba(255, 255, 255, 1);
box-shadow: 0px 0px 12px 0px rgba(0, 0, 0, .15);
} }
.vehicle-container { .vehicle-container {
...@@ -319,7 +322,7 @@ li { ...@@ -319,7 +322,7 @@ li {
.tour-t-l-03 .tour-detail, .tour-t-l-03 .tour-detail,
.tour-t-l-04 .tour-detail, .tour-t-l-04 .tour-detail,
.tour-t-r-02 .tour-detail { .tour-t-r-02 .tour-detail {
padding: 5px 50px 5px 37px; padding: 5px 21px 5px 19px;
} }
.tour-t-r-01 .tour-detail img, .tour-t-r-01 .tour-detail img,
...@@ -478,7 +481,7 @@ li { ...@@ -478,7 +481,7 @@ li {
.show-detail span { .show-detail span {
border: 1px solid rgb(255, 255, 255); border: 1px solid rgb(255, 255, 255);
padding: 10px 40px 10px 20px; padding: 10px 23px 10px 20px;
color: #fff; color: #fff;
font-size: 14px; font-size: 14px;
position: relative; position: relative;
...@@ -544,10 +547,12 @@ li { ...@@ -544,10 +547,12 @@ li {
color: #fff; color: #fff;
transition: all .3s ease; transition: all .3s ease;
color: #fff; color: #fff;
box-shadow: 0px 4px 20px 0px rgba(0, 0, 0, .15);
background: rgba(27,187,159, 1);
} }
.tourActive .tour-t-s, .tourActive .tour-t-s,
.tour-t-s-b { .tourActive .tour-t-s-b {
color: #fff; color: #fff;
} }
...@@ -632,13 +637,14 @@ li { ...@@ -632,13 +637,14 @@ li {
.hot-car .min-win .left, .hot-car .min-win .left,
.hot-car .min-win .left .right { .hot-car .min-win .left .right {
margin-top: 40px; margin-top: 40px;
width: 1180px; width: 1120px;
} }
.hot-car .min-win .left>ul { .hot-car .min-win .left>ul {
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
justify-content: space-between; justify-content: space-between;
padding: 0;
} }
.hot-car .min-win .left>ul>li { .hot-car .min-win .left>ul>li {
...@@ -665,7 +671,7 @@ li { ...@@ -665,7 +671,7 @@ li {
} }
.pic-show { .pic-show {
width: 492px; width: 481px;
display: inline-block; display: inline-block;
position: relative; position: relative;
} }
...@@ -874,7 +880,7 @@ li { ...@@ -874,7 +880,7 @@ li {
height: 53px; height: 53px;
line-height: 53px; line-height: 53px;
width: 567px; width: 567px;
border-bottom: 1px solid #d9d9d9; border-bottom: 1px solid #eee;
} }
.flex-aic-jcb-warp .right li span { .flex-aic-jcb-warp .right li span {
...@@ -893,8 +899,11 @@ li { ...@@ -893,8 +899,11 @@ li {
.flex-aic-jcb-warp .right li:hover a { .flex-aic-jcb-warp .right li:hover a {
color: #fff; color: #fff;
font-size: 16px; font-size: 16px;
text-indent: 4px;
}
.flex-aic-jcb-warp .right li:hover span:nth-child(2){
text-indent: 15px;
} }
.flex-aic-jcb-warp .right li:hover span:nth-child(1) { .flex-aic-jcb-warp .right li:hover span:nth-child(1) {
width: 430px; width: 430px;
} }
......
...@@ -77,7 +77,7 @@ body { ...@@ -77,7 +77,7 @@ body {
display: flex; display: flex;
} }
.min-win{ .min-win{
width: 1200px; width: 1120px;
} }
.bread-menu{ .bread-menu{
padding-bottom: 30px; padding-bottom: 30px;
......
...@@ -237,7 +237,7 @@ a { ...@@ -237,7 +237,7 @@ a {
.sidebar { .sidebar {
position: fixed; position: fixed;
right: 50px; right: 0;
top: 50%; top: 50%;
margin-top: -50px; margin-top: -50px;
background: #333; background: #333;
......
<template> <template>
<div class="banner banner-b-n-n"> <div>
<div class="box"> <div class="swiper-container">
<ul id="bannerBox"> <div class="swiper-wrapper">
<li <div class="swiper-slide" v-for="(item,index) in list" :key="index">
v-for="(item, index) in list" <a href>
:key="item.id" <img :src="item.cover" :alt="item.alt" />
:class="index === current ? 'active' : ''" </a>
@click="bannerClick(index, item)" </div>
>
<!-- <img :src= "item.cover" style="width:100%;height:560px;min-height: 350px;" :alt="item.alt"/> -->
<img :src="item.cover" style="width:100%;" class="indexBanner" :alt="item.alt" />
</li>
</ul>
<div class="status" id="status">
<span
class="name-t ellipsis"
v-for="(item, index) in list"
:key="item.id"
:class="index === current ? 'active' : ''"
@mouseenter="changeBanner(index)"
@mouseleave="startLoop"
>{{item.title}}</span>
</div> </div>
<!-- Add Pagination -->
<div class="swiper-pagination"></div>
</div> </div>
</div> </div>
</template> </template>
<script> <script>
import axios from '../plugins/axios'
import Swiper from 'swiper'
import 'swiper/dist/css/swiper.min.css'
export default { export default {
name: 'banner', name: 'banner',
data() { data() {
return { return {
current: 0, // 当前索引 banner: [
timerId: null, // 清除循环标记 {
intStyle: {}, alt: '异地取还',
imgHeight: '', cover:
uiHeight: '', 'https://xxtest.upyuns.com/image/admin/2019-08-30/32.jpg',
screenWidth: '',//屏幕宽度 id: 29,
title: '异地取还',
url: ''
},
{
alt: '欣新房车',
cover:
'https://mgmt.dfangche.com/image/admin/2019-10-22/109.jpg',
id: 29,
title: '欣新房车',
url: ''
}
]
} }
}, },
props: [ props: [
...@@ -48,82 +51,41 @@ export default { ...@@ -48,82 +51,41 @@ export default {
'color', 'color',
'fontSize' 'fontSize'
], ],
methods: { methods: {},
getArticle() {
this.$emit('getArticle', this.article)
},
// 鼠标移入状态圆点
changeBanner(index) {
this.$emit('change', this.current)
this.stopLoop()
this.current = index
},
// 鼠标点击banner内容
bannerClick(index, item) {
this.$emit('click', index, item)
},
// 点击上一张按钮
prev() {
if (this.current > 0) {
// 将对象列表对应的索引和整个对象传出去
this.$emit('prev', this.current, this.list)
this.current--
} else {
this.$emit('prev', this.current, this.list)
this.current = this.list.length - 1
}
},
// 点击下一张按钮
next() {
if (this.current < this.list.length - 1) {
this.$emit('prev', this.current, this.list)
this.current++
} else {
this.$emit('prev', this.current, this.list)
this.current = 0
}
},
// 鼠标移出继续循环播放
startLoop() {
this.int(4000)
},
// 鼠标移入停止循环播放
stopLoop() {
clearTimeout(this.timerId) // 清除循环
},
// 初始化加载
int(time) {
this.timerId = setInterval(() => {
this.next()
}, time)
// 初始化样式
this.intStyle = {
width: this.width + 'px',
height: this.height + 'px',
background: this.background,
color: this.color
}
},
//图片高度
picHeigth() {
this.$nextTick(function() {
// console.log(document.getElementsByClassName('indexBanner')[0].height);
this.imgHeight = document.getElementsByClassName(
'indexBanner'
)[0].height
this.uiHeight = document.getElementById('bannerBox')
this.uiHeight.style.height = this.imgHeight + 'px'
})
}
},
mounted() { mounted() {
this.picHeigth() let t = this
let title = this.banner
t.swiper = new Swiper('.swiper-container', {
// autoplay: true,
effect: 'fade',
pagination: {
el: '.swiper-pagination',
clickable: true,
renderBullet: function(index, className) {
return '<span class="' + className + '">' + title[index].title + '</span>'
}
}
})
}, },
created() { created() {
this.int(4000)
} }
} }
</script> </script>
<style> <style>
@import '../assets/banner.css'; @import '../assets/banner.css';
.swiper-pagination-bullet{
display: inline-block;
width: auto;
height: auto;
background: #fff;
opacity: 1;
padding: 8px 19px;
border-radius: 0;
font-size: 14px;
margin: 10px 4px !important;
}
.swiper-pagination-bullet-active{
background: #1bbb9f;
color: #fff;
}
</style> </style>
...@@ -14,7 +14,9 @@ ...@@ -14,7 +14,9 @@
</ul> --> </ul> -->
<vue-seamless-scroll :data="list" :class-option="optionLeft" class="seamless-warp2" style="width:864px;"> <vue-seamless-scroll :data="list" :class-option="optionLeft" class="seamless-warp2" style="width:864px;">
<ul class="item" style="overflow: hidden;"> <ul class="item" style="overflow: hidden;">
<li v-for="(item,index) in list" :key="index" v-text="item.name"></li> <li v-for="(item,index) in list" :key="index">
<a target="_blank" style="color:#fff" :href="item.linkUrl" v-text="item.name"></a>
</li>
</ul> </ul>
</vue-seamless-scroll> </vue-seamless-scroll>
</div> </div>
...@@ -79,6 +81,7 @@ export default { ...@@ -79,6 +81,7 @@ export default {
let { let {
data: { data } data: { data }
} = await axios.get('/api/uccn/app/unauth/friend_link/list') } = await axios.get('/api/uccn/app/unauth/friend_link/list')
if (data.length == 0) { if (data.length == 0) {
this.listShow = false this.listShow = false
} else { } else {
......
...@@ -101,7 +101,7 @@ ...@@ -101,7 +101,7 @@
</el-select> </el-select>
<el-button <el-button
slot="append" slot="append"
style="width:88px;height:43px;background:#1bbb9f;color:#fff;border-radius: 0;" style="width:88px;height:42px;background:#1bbb9f;color:#fff;border-radius: 0;"
class="search" class="search"
@click="findTo()" @click="findTo()"
>搜索</el-button> >搜索</el-button>
...@@ -443,10 +443,10 @@ export default { ...@@ -443,10 +443,10 @@ export default {
} }
.el-input__inner { .el-input__inner {
border: 1px solid transparent; border: 1px solid transparent !important;
} }
.el-input__inner:hover { .el-input__inner:hover {
border: 1px solid transparent; border: 1px solid transparent !important;
} }
.el-input__suffix { .el-input__suffix {
right: 15px; right: 15px;
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment