zxl
2026-03-25 73e0b3791990bd60c06c2c0388aae9f9faf538a6
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
<template>
  <router-link :to="{ name: 'dashboard' }">
    <div class="flex logo-container flex-center">
      <img class="logo-img" :src="homeLogo" alt="logo" />
      <!-- <h1 class="logo-title" v-if="showTitle">{{ title }}</h1> -->
    </div>
  </router-link>
</template>
 
<script>
import homeLogo from '@/assets/img/sdjt.jpg'
 
export default {
  name: 'Logo',
 
  props: {
    title: {
      type: String,
      default: '智慧加油站1',
      required: false,
    },
    showTitle: {
      type: Boolean,
      default: false,
      required: false,
    },
  },
  data() {
    return {
      homeLogo,
    }
  },
}
</script>
<style lang="less" scoped>
.logo {
  &-container {
    position: relative;
    height: @layout-header-height;
    line-height: @layout-header-height;
    background-color: @layout-logo-background;
    box-shadow: none;
    transition: background 300ms;
    -webkit-transition: all 0.3s;
    transition: all 0.3s;
    overflow: hidden;
 
    &:hover .logo-title {
      color: @layout-logo-color-hover;
    }
  }
 
  &-img,
  &-title {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
 
  &-img {
    height: 32px;
    padding: 0 16px;
  }
 
  &-title {
    margin: 0;
    color: @layout-logo-color;
    font-weight: 600;
    font-size: @font-size-lg;
    font-family: 'Chinese Quote', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB',
      'Microsoft YaHei', 'Helvetica Neue', Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji',
      'Segoe UI Symbol';
  }
}
</style>