浏览代码

设置公共组件

baid222u 5 年之前
父节点
当前提交
dfcd796a2e

+ 19 - 2
assets/a.scss

@@ -1,6 +1,6 @@
 @charset "utf-8";
 //font 
-$table:49px;
+$table:90px;
 
 body {
     background    : yellow;
@@ -13,6 +13,7 @@ body {
         width   : 100%;
         height  : $table;
         margin: 0;
+        background-color: #fff;
         ul {
             width: 100%;
             height : 100%;
@@ -20,7 +21,23 @@ body {
                 width  : 24%;
                 height : 100%;
                 display: inline-block;
-                
+                text-align: center;
+                span{
+                    margin-top: 60px;
+                    display: inline-block;
+                }
+            }
+            li:nth-child(1){
+                background: url(../static/img/ztb.png) no-repeat center 16px;
+            }
+            li:nth-child(2){
+                background: url(../static/img/gc.png) no-repeat center 16px;
+            }
+            li:nth-child(3){
+                background: url(../static/img/xm.png) no-repeat center 16px;
+            }
+            li:nth-child(4){
+                background: url(../static/img/me.png) no-repeat center 16px;
             }
         }
 

+ 33 - 4
components/table.vue

@@ -1,10 +1,39 @@
 <template>
   <div class="table">
     <ul>
-      <li>saass</li>
-      <li>saass</li>
-      <li>saass</li>
-      <li>saass</li>
+      <nuxt-link to="/bidding">
+        <li>
+          <span>招投标</span>
+        </li>
+      </nuxt-link>
+      <li>
+        <span>工程项目</span>
+      </li>
+      <li>
+        <span>项目跟踪</span>
+      </li>
+      <li>
+        <span>我的</span>
+      </li>
     </ul>
   </div>
 </template>
+<script>
+import '~/assets/a.scss'
+export default {
+  data() {
+    return {
+      author: '微信公众号 jinkey-love'
+    }
+  },
+  created: function() {
+    
+  },
+  methods: {
+    addTodo(e) {
+      this.$store.commit('todos/add', e.target.value)
+      e.target.value = ''
+    }
+  }
+}
+</script>

+ 21 - 48
layouts/default.vue

@@ -1,55 +1,28 @@
 <template>
   <div>
-    <nuxt />
+    <nuxt/>
+    <logo/>
   </div>
 </template>
-
-<style>
-html {
-  font-family: 'Source Sans Pro', -apple-system, BlinkMacSystemFont, 'Segoe UI',
-    Roboto, 'Helvetica Neue', Arial, sans-serif;
-  font-size: 16px;
-  word-spacing: 1px;
-  -ms-text-size-adjust: 100%;
-  -webkit-text-size-adjust: 100%;
-  -moz-osx-font-smoothing: grayscale;
-  -webkit-font-smoothing: antialiased;
-  box-sizing: border-box;
-}
-
-*,
-*:before,
-*:after {
-  box-sizing: border-box;
-  margin: 0;
-}
-
-.button--green {
-  display: inline-block;
-  border-radius: 4px;
-  border: 1px solid #3b8070;
-  color: #3b8070;
-  text-decoration: none;
-  padding: 10px 30px;
+<script>
+import Logo from '~/components/table.vue'
+export default {
+   components: {
+    Logo
+  },
+   data () {
+    return {
+      author: "微信公众号 jinkey-love"
+    }
+  },
+  methods: {
+    addTodo (e) {
+      this.$store.commit('todos/add', e.target.value)
+      e.target.value = ''
+    }
+  }
 }
+</script>
 
-.button--green:hover {
-  color: #fff;
-  background-color: #3b8070;
-}
-
-.button--grey {
-  display: inline-block;
-  border-radius: 4px;
-  border: 1px solid #35495e;
-  color: #35495e;
-  text-decoration: none;
-  padding: 10px 30px;
-  margin-left: 15px;
-}
-
-.button--grey:hover {
-  color: #fff;
-  background-color: #35495e;
-}
+<style>
 </style>

+ 8 - 8
nuxt.config.js

@@ -57,14 +57,14 @@ export default {
      */
     extend(config, ctx) {
       // Run ESLint on save
-      if (ctx.isDev && ctx.isClient) {
-        config.module.rules.push({
-          enforce: 'pre',
-          test: /\.(js|vue)$/,
-          loader: 'eslint-loader',
-          exclude: /(node_modules)/
-        })
-      }
+      // if (ctx.isDev && ctx.isClient) {
+      //   config.module.rules.push({
+      //     enforce: 'pre',
+      //     test: /\.(js|vue)$/,
+      //     loader: 'eslint-loader',
+      //     exclude: /(node_modules)/
+      //   })
+      // }
       const sassResourcesLoader = {
         loader: 'sass-resources-loader',
         options: {

+ 3 - 52
pages/index.vue

@@ -1,67 +1,18 @@
 <template>
   <section class="container">
     <div>
-      <logo />
-      <h1 class="title">
-        gcb
-      </h1>
-      <h2 class="subtitle">
-        My majestic Nuxt.js project
-      </h2>
-      <div class="links">
-        <a href="https://nuxtjs.org/" target="_blank" class="button--green"
-          >Documentation</a
-        >
-        <a
-          href="https://github.com/nuxt/nuxt.js"
-          target="_blank"
-          class="button--grey"
-          >GitHub</a
-        >
-      </div>
+      dddsdsd 
+      
     </div>
   </section>
 </template>
 
 <script>
-import Logo from '~/components/table.vue'
-import '~/assets/a.scss'
 export default {
-  components: {
-    Logo
-  }
+ 
 }
 </script>
 
 <style>
-.container {
-  margin: 0 auto;
-  min-height: 100vh;
-  display: flex;
-  justify-content: center;
-  align-items: center;
-  text-align: center;
-}
-
-.title {
-  font-family: 'Quicksand', 'Source Sans Pro', -apple-system, BlinkMacSystemFont,
-    'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
-  display: block;
-  font-weight: 300;
-  font-size: 100px;
-  color: #35495e;
-  letter-spacing: 1px;
-}
 
-.subtitle {
-  font-weight: 300;
-  font-size: 42px;
-  color: #526488;
-  word-spacing: 5px;
-  padding-bottom: 15px;
-}
-
-.links {
-  padding-top: 15px;
-}
 </style>

二进制
static/img/icon_gcxm_active.png


二进制
static/img/icon_gcxm_normal.png


二进制
static/img/icon_map_active.png


二进制
static/img/icon_map_normal.png


二进制
static/img/icon_me_active.png


二进制
static/img/icon_me_normal.png


二进制
static/img/icon_ztb_active.png


二进制
static/img/icon_ztb_normal.png