Browse Source

css change

2312970463@qq.com 4 years ago
parent
commit
ae5aae9cff
5 changed files with 69 additions and 41 deletions
  1. 25 7
      src/App.vue
  2. 2 1
      src/components/pageBottom/PageBottom.vue
  3. 2 0
      src/request/api.js
  4. 10 0
      src/request/request.js
  5. 30 33
      src/views/About.vue

+ 25 - 7
src/App.vue

@@ -1,6 +1,11 @@
 <template>
   <div id="app">
-	<div class="bg"></div>
+	<div class="bg">
+		<img src="@/assets/img/m1.png" >
+	</div>
+	<div>
+		
+	</div>
     <top-logo></top-logo>
     <nav-bar></nav-bar>
 	<div class="main-wrapper">
@@ -21,19 +26,32 @@ export default {
   }
 }
 </script>
-<style lang="scss" scoped>
+<style lang="scss" scoped>
+#app {
+	max-width: 1920px;
+	min-width: 1200px;
+	margin: 0 auto;
+}
 .main-wrapper {
 	width: 1200px;
 	margin: 0 auto;
 }
 .bg {
 	position: absolute;
-	top: 0;
-	height: 300px;
-	min-width: 1920px;
+	left: 0;
+	right: 0;
 	margin: 0 auto;
-	background-image: url(assets/img/m1.png);
-	background-size: 100% 100%;
+	// margin: 0 auto -300px;
+	height: 300px;
+	max-width: 1920px;
+	min-width: 1200px;
+	// background-image: url(assets/img/m1.png);
+	// background-size: auto 100%;
 	z-index: -1;
+	img {
+		width: 1920px;
+		
+		height: 300px;
+	}
 }
 </style>

+ 2 - 1
src/components/pageBottom/PageBottom.vue

@@ -10,8 +10,9 @@
 
 <style lang="scss" scoped>
 	.view-bottom {
-		width: 100%;
+		// width: 1920px;
 		height: 174px;
+		margin: 0 auto;
 		background: #D82020;
 		font-size: 14px;
 		font-family: PingFang SC;

+ 2 - 0
src/request/api.js

@@ -0,0 +1,2 @@
+import request from "./request.js"
+

+ 10 - 0
src/request/request.js

@@ -0,0 +1,10 @@
+import Axios from 'axios'
+
+export function request(config){
+  const instance = new Axios.create({
+    baseURL:'http://127.0.0.1:8888/api/private/v1/',
+    timeout:5000
+  })
+
+  return instance(config)
+}

+ 30 - 33
src/views/About.vue

@@ -3,39 +3,36 @@
 		<left-nav :navList="navList">
 			about
 		</left-nav>
-	</div>
-</template>
-
+	</div>
+</template>
+
 <script>
-	import LeftNav from '../components/leftNav/LeftNav.vue'
-	// import PageTitle from '../components/pageTitle/PageTitle.vue'
-	export default {
-		components: {
-			LeftNav,
-			// PageTitle
-		},
-		data() {
-			return {
-				navList: [
-					{ index: 0, name: '关于我们', path: '/about'},
-					{ index: 1, name: '联系我们', path: '/concat'}
-				],
-			}
-			
-		}
-	}
-</script>
-
+import LeftNav from '../components/leftNav/LeftNav.vue';
+// import PageTitle from '../components/pageTitle/PageTitle.vue'
+export default {
+	components: {
+		LeftNav
+		// PageTitle
+	},
+	data() {
+		return {
+			navList: [{ index: 0, name: '关于我们', path: '/about' }, { index: 1, name: '联系我们', path: '/concat' }],
+			radio: '1'
+		};
+	}
+};
+</script>
+
 <style lang="scss" scoped>
-	.about {
-		width: 1200px;
-		margin: 0 auto;
-		display: flex;
-		justify-content: space-between;
-		.right-wrapper {
-			width: 915px;
-			min-height: 776px;
-			box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.1);
-		}
-	}
+.about {
+	width: 1200px;
+	margin: 0 auto;
+	display: flex;
+	justify-content: space-between;
+	.right-wrapper {
+		width: 915px;
+		min-height: 776px;
+		box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.1);
+	}
+}
 </style>