Browse Source

feat(layout): 添加字体资源并优化页面布局结构

- 引入多种字体文件并创建字体配置样式表
- 在代码生成模板中添加卡片组件包装表单元素
- 优化侧边栏Logo组件的布局结构和样式
- 更新系统标题为易盟数字后台管理系统
- 配置自定义字体家族用于侧边栏标题显示
JX.Li 2 weeks ago
parent
commit
f48d811864

+ 4 - 2
nexo-modules/nexo-gen/src/main/resources/vm/vue/index.vue.vm

@@ -1,5 +1,6 @@
 <template>
 <template>
   <div class="app-container">
   <div class="app-container">
+    <el-card shadow="never">
     <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
     <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
 #foreach($column in $columns)
 #foreach($column in $columns)
 #if($column.query)
 #if($column.query)
@@ -67,7 +68,8 @@
         <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
         <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
       </el-form-item>
       </el-form-item>
     </el-form>
     </el-form>
-
+    </el-card>
+    <el-card shadow="never" class="mt10">
     <el-row :gutter="10" class="mb8">
     <el-row :gutter="10" class="mb8">
       <el-col :span="1.5">
       <el-col :span="1.5">
         <el-button
         <el-button
@@ -179,7 +181,7 @@
       :limit.sync="queryParams.pageSize"
       :limit.sync="queryParams.pageSize"
       @pagination="getList"
       @pagination="getList"
     />
     />
-
+    </el-card>
     <!-- 添加或修改${functionName}对话框 -->
     <!-- 添加或修改${functionName}对话框 -->
     <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
     <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
       <el-form ref="form" :model="form" :rules="rules" label-width="80px">
       <el-form ref="form" :model="form" :rules="rules" label-width="80px">

BIN
nexo-ui/src/assets/fonts/Barlow-Medium.woff


BIN
nexo-ui/src/assets/fonts/Barlow-Medium.woff2


BIN
nexo-ui/src/assets/fonts/HarmonyOS_Sans_SC_Medium.ttf


BIN
nexo-ui/src/assets/fonts/OPPO-Sans-4.ttf


BIN
nexo-ui/src/assets/fonts/PangMenZhengDaoBiaoTiTiMianFeiBan-2.ttf


BIN
nexo-ui/src/assets/fonts/YouSheBiaoTiHei-2.ttf


BIN
nexo-ui/src/assets/fonts/caihongjimu.ttf


+ 43 - 0
nexo-ui/src/assets/fonts/font.css

@@ -0,0 +1,43 @@
+@font-face {
+    font-family: 'Barlow';
+    src: url('Barlow-Medium.woff2') format('woff2'),
+    url('Barlow-Medium.woff') format('woff');
+    font-weight: 500;
+    font-style: normal;
+    font-display: swap;
+}
+
+@font-face {
+  font-family: 'YouSheBiaoTiHei';
+  src: url('./YouSheBiaoTiHei-2.ttf') format('truetype');
+  font-weight: normal;
+  font-style: normal;
+}
+
+@font-face {
+  font-family: 'PangMenZhengDaoBiaoTiTiMianFeiBan';
+  src: url('./PangMenZhengDaoBiaoTiTiMianFeiBan-2.ttf') format('truetype');
+  font-weight: normal;
+  font-style: normal;
+}
+
+@font-face {
+  font-family: 'HarmonyOS_Sans_SC_Medium';
+  src: url('./HarmonyOS_Sans_SC_Medium.ttf') format('truetype');
+  font-weight: normal;
+  font-style: normal;
+}
+
+@font-face {
+  font-family: 'OPPO_Sans_4';
+  src: url('./OPPO-Sans-4.ttf') format('truetype');
+  font-weight: normal;
+  font-style: normal;
+}
+
+@font-face {
+  font-family: 'CAIHONGJIMU';
+  src: url('./caihongjimu.ttf') format('truetype');
+  font-weight: normal;
+  font-style: normal;
+}

+ 1 - 0
nexo-ui/src/assets/icons/svg/douyin.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1779331879689" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="3837" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M937.254034 423.740952A390.095238 390.095238 0 0 1 704.659749 346.209524v352.060952A317.927619 317.927619 0 0 1 395.021653 1024 317.927619 317.927619 0 0 1 85.383558 698.270476a317.44 317.44 0 0 1 309.638095-325.241905 331.580952 331.580952 0 0 1 48.761905 3.900953v186.758095a137.020952 137.020952 0 0 0-48.761905-9.264762 141.897143 141.897143 0 0 0-138.483809 146.285714 141.897143 141.897143 0 0 0 138.483809 146.285715 141.897143 141.897143 0 0 0 137.996191-146.285715V0h172.617143a237.470476 237.470476 0 0 0 233.081904 243.809524v180.419047" fill="" p-id="3838"></path></svg>

+ 15 - 9
nexo-ui/src/layout/components/Sidebar/Logo.vue

@@ -1,13 +1,19 @@
 <template>
 <template>
-  <div class="sidebar-logo-container" :class="{'collapse':collapse}" :style="{ backgroundColor: sideTheme === 'theme-dark' ? variables.menuBackground : variables.menuLightBackground }">
+  <div class="sidebar-logo-container" :class="{'collapse':collapse}"
+       :style="{ backgroundColor: sideTheme === 'theme-dark' ? variables.menuBackground : variables.menuLightBackground }"
+  >
     <transition name="sidebarLogoFade">
     <transition name="sidebarLogoFade">
       <router-link v-if="collapse" key="collapse" class="sidebar-logo-link" to="/">
       <router-link v-if="collapse" key="collapse" class="sidebar-logo-link" to="/">
-        <img v-if="logo" :src="logo" class="sidebar-logo" />
-        <h1 v-else class="sidebar-title" :style="{ color: sideTheme === 'theme-dark' ? variables.logoTitleColor : variables.logoLightTitleColor }">{{ title }} </h1>
+        <img v-if="logo" :src="logo" class="sidebar-logo"/>
+        <h1 v-else class="sidebar-title"
+            :style="{ color: sideTheme === 'theme-dark' ? variables.logoTitleColor : variables.logoLightTitleColor }"
+        >{{ title }} </h1>
       </router-link>
       </router-link>
       <router-link v-else key="expand" class="sidebar-logo-link" to="/">
       <router-link v-else key="expand" class="sidebar-logo-link" to="/">
-        <img v-if="logo" :src="logo" class="sidebar-logo" />
-        <h1 class="sidebar-title" :style="{ color: sideTheme === 'theme-dark' ? variables.logoTitleColor : variables.logoLightTitleColor }">{{ title }} </h1>
+        <img v-if="logo" :src="logo" class="sidebar-logo"/>
+        <h1 class="sidebar-title"
+            :style="{ color: sideTheme === 'theme-dark' ? variables.logoTitleColor : variables.logoLightTitleColor }"
+        >{{ title }} </h1>
       </router-link>
       </router-link>
     </transition>
     </transition>
   </div>
   </div>
@@ -27,7 +33,7 @@ export default {
   },
   },
   computed: {
   computed: {
     variables() {
     variables() {
-      return variables;
+      return variables
     },
     },
     sideTheme() {
     sideTheme() {
       return this.$store.state.settings.sideTheme
       return this.$store.state.settings.sideTheme
@@ -35,7 +41,7 @@ export default {
   },
   },
   data() {
   data() {
     return {
     return {
-      title: 'Nexo-Cloud-Plus',
+      title: '易盟数字后台管理系统',
       logo: logoImg
       logo: logoImg
     }
     }
   }
   }
@@ -78,8 +84,8 @@ export default {
       color: #fff;
       color: #fff;
       font-weight: 600;
       font-weight: 600;
       line-height: 50px;
       line-height: 50px;
-      font-size: 14px;
-      font-family: Avenir, Helvetica Neue, Arial, Helvetica, sans-serif;
+      font-size: 16px;
+      font-family: CAIHONGJIMU, PangMenZhengDaoBiaoTiTiMianFeiBan, Avenir, Helvetica Neue, Arial, Helvetica, sans-serif;
       vertical-align: middle;
       vertical-align: middle;
     }
     }
   }
   }

+ 1 - 0
nexo-ui/src/main.js

@@ -7,6 +7,7 @@ import './assets/styles/element-variables.scss'
 
 
 import '@/assets/styles/index.scss' // global css
 import '@/assets/styles/index.scss' // global css
 import '@/assets/styles/nexo.scss' // nexo css
 import '@/assets/styles/nexo.scss' // nexo css
+import "@/assets/fonts/font.css";
 import App from './App'
 import App from './App'
 import store from './store'
 import store from './store'
 import router from './router'
 import router from './router'