welfare-admin/src/App.vue

75 lines
1.3 KiB
Vue

<template>
<a-config-provider :locale="locale">
<div id="app">
<router-view />
</div>
</a-config-provider>
</template>
<script>
import { domTitle, setDocumentTitle } from '@/utils/domUtil'
import { i18nRender } from '@/locales'
export default {
data() {
return {}
},
computed: {
locale() {
// 只是为了切换语言时,更新标题
const { title } = this.$route.meta
title && setDocumentTitle(`${i18nRender(title)} - ${domTitle}`)
return this.$i18n.getLocaleMessage(this.$store.getters.lang).antLocale
}
}
}
</script>
<style lang="less">
.modal-title {
font-size: 16px;
font-weight: bold;
color: #333;
display: flex;
align-items: center;
margin-top: 15px;
&::before {
content: '';
display: inline-block;
width: 4px;
height: 16px;
background: #1890ff;
margin-right: 3px;
}
}
.i-icon{
display: flex;
align-items: center;
justify-content: center;
}
// 全局样式配置
.ant-pro-basicLayout-children-content-wrap{
height: 100%;
}
.ant-pro-grid-content{
height: 100%;
}
.ant-layout-footer{
display: none;
}
.text-cut-2{
text-overflow: -o-ellipsis-lastline;
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 2;
line-clamp: 2;
-webkit-box-orient: vertical;
}
</style>