Skip to content

Commit 7eb42c2

Browse files
committed
♻️ refactor: code
1 parent ab73369 commit 7eb42c2

File tree

10 files changed

+18
-29
lines changed

10 files changed

+18
-29
lines changed

README.en.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828

2929
<!-- - [⚡️ Vue3. X + element plus (alpha version, free commercial, supporting PC, tablet and mobile phone)](https://vuejs-core.cn/vue-admin-better-plus/) -->
3030

31-
<!-- - [⚡️ Vue3. X + ant design Vue (beta version, free commercial, supporting PC, tablet and mobile phone)](https://vuejs-core.cn/vue-admin-beautiful-antdv/) -->
31+
<!-- - [⚡️ Vue3. X + ant design Vue (beta version, free commercial, supporting PC, tablet and mobile phone)](https://vuejs-core.cn/vue-admin-better-antdv/) -->
3232

3333
- [⚡️ vue3.x + vite + vue-admin-arco](https://vuejs-core.cn/vue-admin-arco/)
3434

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858

5959
<!-- - [⚡️ vue3.x + element-plus(alpha 版本,免费商用,支持 PC、平板、手机)](https://vuejs-core.cn/vue-admin-better-plus/) -->
6060

61-
<!-- - [⚡️ Vue Admin Ant (vue3.x + ant-design-vue 免费商用,支持 PC、平板、手机)](https://vuejs-core.cn/vue-admin-beautiful-antdv/) -->
61+
<!-- - [⚡️ Vue Admin Ant (vue3.x + ant-design-vue 免费商用,支持 PC、平板、手机)](https://vuejs-core.cn/vue-admin-better-antdv/) -->
6262

6363
- [⚡️ Vue Admin Arco (vue3.x + vite5.x + arco2.x 免费商用,支持 PC)](https://vuejs-core.cn/vue-admin-arco/)
6464

layouts/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
module.exports = {
22
webpackBarName: 'vue-admin-better',
33
webpackBanner:
4-
' build: vue-admin-better \n vue-admin-beautiful.com \n https://gitee.com/chu1204505056/vue-admin-better \n time: ',
4+
' build: vue-admin-better \n vue-admin-better.com \n https://gitee.com/chu1204505056/vue-admin-better \n time: ',
55
donationConsole() {
66
const chalk = require('chalk')
77
console.log(

public/index.html

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<link href="<%= BASE_URL %>favicon.ico" rel="icon" />
88
<title>vue-admin-better官网、首页、文档和下载 - 前端开发框架</title>
99
<meta
10-
content="vab,vab官网,后台管理框架,vue后台管理框架,vue-admin-beautiful-pro源码分享,vue-admin-beautiful-pro源码,vue-admin-beautiful官网,vue-admin-beautiful文档,vue-element-admin,vue-element-admin官网,vue-element-admin文档,vue-admin,vue-admin官网,vue-admin文档"
10+
content="vab,vab官网,后台管理框架,vue后台管理框架,vue-admin-better-pro源码分享,vue-admin-better-pro源码,vue-admin-beautiful官网,vue-admin-beautiful文档,vue-element-admin,vue-element-admin官网,vue-element-admin文档,vue-admin,vue-admin官网,vue-admin文档"
1111
name="keywords"
1212
/>
1313
<meta
@@ -18,11 +18,8 @@
1818
<link href="<%= BASE_URL %>static/css/loading.css" rel="stylesheet" />
1919
</head>
2020
<body>
21-
<noscript>
22-
非常抱歉鉴于安全考量,您无法查看<%= VUE_APP_TITLE %>
23-
源代码,该系统基于vue-admin-better开发
24-
</noscript>
25-
<div id="vue-admin-beautiful">
21+
<noscript>非常抱歉鉴于安全考量,您无法查看<%= VUE_APP_TITLE %> 源代码,该系统基于vue-admin-better开发</noscript>
22+
<div id="vue-admin-better">
2623
<div class="first-loading-wrp">
2724
<div class="loading-wrp">
2825
<span class="dot dot-spin">
@@ -36,10 +33,7 @@ <h1><%= VUE_APP_TITLE %></h1>
3633
</div>
3734
</div>
3835
<script>
39-
;/^http(s*):\/\//.test(location.href) ||
40-
alert(
41-
'基于vue-admin-beautiful-pro开源版开发的项目需要部署到服务器下访问'
42-
)
36+
;/^http(s*):\/\//.test(location.href) || alert('基于vue-admin-beautiful-pro开源版开发的项目需要部署到服务器下访问')
4337
</script>
4438
<script>
4539
if (window.location.hostname !== 'localhost') {

src/App.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<template>
2-
<div id="vue-admin-beautiful">
2+
<div id="vue-admin-better">
33
<router-view />
44
</div>
55
</template>

src/layouts/components/VabThemeBar/index.vue

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@
8484
}
8585
8686
this.$baseEventBus.$on('theme', handleTheme)
87-
const theme = localStorage.getItem('vue-admin-beautiful-theme')
87+
const theme = localStorage.getItem('vue-admin-better-theme')
8888
if (null !== theme) {
8989
this.theme = JSON.parse(theme)
9090
this.handleSetTheme()
@@ -113,7 +113,7 @@
113113
handleSetTheme() {
114114
let { name, layout, header, tabsBar } = this.theme
115115
localStorage.setItem(
116-
'vue-admin-beautiful-theme',
116+
'vue-admin-better-theme',
117117
`{
118118
"name":"${name}",
119119
"layout":"${layout}",
@@ -124,16 +124,16 @@
124124
if (!this.handleIsMobile()) this.changeLayout(layout)
125125
this.changeHeader(header)
126126
this.changeTabsBar(tabsBar)
127-
document.getElementsByTagName('body')[0].className = `vue-admin-beautiful-theme-${name}`
127+
document.getElementsByTagName('body')[0].className = `vue-admin-better-theme-${name}`
128128
this.drawerVisible = false
129129
},
130130
handleSaveTheme() {
131131
this.handleSetTheme()
132132
},
133133
handleSetDfaultTheme() {
134134
let { name } = this.theme
135-
document.getElementsByTagName('body')[0].classList.remove(`vue-admin-beautiful-theme-${name}`)
136-
localStorage.removeItem('vue-admin-beautiful-theme')
135+
document.getElementsByTagName('body')[0].classList.remove(`vue-admin-better-theme-${name}`)
136+
localStorage.removeItem('vue-admin-better-theme')
137137
this.$refs['form'].resetFields()
138138
Object.assign(this.$data, this.$options.data())
139139
this.changeHeader(defaultLayout)

src/layouts/index.vue

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<template>
2-
<div :class="classObj" class="vue-admin-beautiful-wrapper">
2+
<div :class="classObj" class="vue-admin-better-wrapper">
33
<div
44
v-if="'horizontal' === layout"
55
:class="{
@@ -82,11 +82,6 @@
8282
mounted() {
8383
this.oldLayout = this.layout
8484
const userAgent = navigator.userAgent
85-
if (userAgent.includes('Juejin')) {
86-
this.$baseAlert(
87-
'vue-admin-beautiful不支持在掘金内置浏览器演示,请手动复制以下地址到浏览器中查看http://mpfhrd48.sanxing.uz7.cn/vue-admin-beautiful'
88-
)
89-
}
9085
const isMobile = this.handleIsMobile()
9186
if (isMobile) {
9287
if (isMobile) {
@@ -151,7 +146,7 @@
151146
overflow: hidden;
152147
}
153148
154-
.vue-admin-beautiful-wrapper {
149+
.vue-admin-better-wrapper {
155150
position: relative;
156151
width: 100%;
157152
height: 100%;

src/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ if (process.env.NODE_ENV === 'production') {
1717
Vue.config.productionTip = false
1818

1919
new Vue({
20-
el: '#vue-admin-beautiful',
20+
el: '#vue-admin-better',
2121
router,
2222
store,
2323
render: (h) => h(App),

src/store/modules/settings.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import defaultSettings from '@/config'
77

88
const { tabsBar, logo, layout, header, themeBar } = defaultSettings
9-
const theme = JSON.parse(localStorage.getItem('vue-admin-beautiful-theme')) || ''
9+
const theme = JSON.parse(localStorage.getItem('vue-admin-better-theme')) || ''
1010
const state = () => ({
1111
tabsBar: theme.tabsBar || tabsBar,
1212
logo,

src/styles/vab.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ html {
141141
}
142142
}
143143

144-
.vue-admin-beautiful-wrapper {
144+
.vue-admin-better-wrapper {
145145
.app-main-container {
146146
@include base-scrollbar;
147147

0 commit comments

Comments
 (0)