chore: 字体文件

This commit is contained in:
2026-02-06 17:20:57 +08:00
parent 1a7c848334
commit af3161fc86
17 changed files with 145 additions and 121 deletions

View File

@@ -7,8 +7,7 @@
<!-- <meta name="viewport" content="width=device-width, initial-scale=1.0"> --> <!-- <meta name="viewport" content="width=device-width, initial-scale=1.0"> -->
<!-- <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"> --> <!-- <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"> -->
<meta name="viewport" content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=0" /> <meta name="viewport" content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=0" />
<link rel="stylesheet" href="/css/fonts/fontFamily.css"> <title>Global Awards</title>
<title>FiDA</title>
</head> </head>
<body> <body>

1
package-lock.json generated
View File

@@ -13,6 +13,7 @@
"axios": "^1.3.6", "axios": "^1.3.6",
"crypto-js": "^4.2.0", "crypto-js": "^4.2.0",
"gsap": "^3.13.0", "gsap": "^3.13.0",
"lodash-es": "^4.17.23",
"normalize.css": "^8.0.1", "normalize.css": "^8.0.1",
"pinia": "^2.0.32", "pinia": "^2.0.32",
"pinia-persistedstate-plugin": "^0.1.0", "pinia-persistedstate-plugin": "^0.1.0",

View File

@@ -17,6 +17,7 @@
"axios": "^1.3.6", "axios": "^1.3.6",
"crypto-js": "^4.2.0", "crypto-js": "^4.2.0",
"gsap": "^3.13.0", "gsap": "^3.13.0",
"lodash-es": "^4.17.23",
"normalize.css": "^8.0.1", "normalize.css": "^8.0.1",
"pinia": "^2.0.32", "pinia": "^2.0.32",
"pinia-persistedstate-plugin": "^0.1.0", "pinia-persistedstate-plugin": "^0.1.0",

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -1,41 +0,0 @@
/* 字体定义 */
@font-face {
font-family: 'Arial';
src: url('./ARIAL.ttf') format('truetype');
}
@font-face {
font-family: 'ArialBold';
src: url('./ARIALBD.ttf') format('truetype');
}
@font-face {
font-family: 'ArialMedium';
src: url('./ArialMdm.ttf') format('truetype');
}
@font-face {
font-family: 'Poppins';
src: url('./Poppins-Regular.ttf') format('truetype');
font-weight: normal;
}
@font-face {
font-family: 'PoppinsMedium';
src: url('./Poppins-Medium.ttf') format('truetype');
}
@font-face {
font-family: 'PoppinsBold';
src: url('./Poppins-SemiBold.ttf') format('ttf');
}
@font-face {
font-family: 'Instrument';
src: url('./InstrumentSans-Regular.ttf') format('truetype');
}
@font-face {
font-family: 'InstrumentBold';
src: url('./InstrumentSans-Bold.ttf') format('truetype');
}

View File

@@ -27,7 +27,7 @@
@font-face { @font-face {
font-family: 'PoppinsBold'; font-family: 'PoppinsBold';
src: url('./Poppins-SemiBold.ttf') format('truetype'); src: url('./Poppins-SemiBold.woff') format('woff2');
} }
@font-face { @font-face {

View File

@@ -62,3 +62,45 @@ body,
.space-between { .space-between {
justify-content: space-between; justify-content: space-between;
} }
/* 字体定义 */
@font-face {
font-family: 'Arial';
src: url('./fonts/ARIAL.ttf') format('truetype');
}
@font-face {
font-family: 'ArialBold';
src: url('./fonts/ARIALBD.ttf') format('truetype');
}
@font-face {
font-family: 'ArialMedium';
src: url('./fonts/ArialMdm.ttf') format('truetype');
}
@font-face {
font-family: 'Poppins';
src: url('./fonts/Poppins-Regular.ttf') format('truetype');
font-weight: normal;
}
@font-face {
font-family: 'PoppinsMedium';
src: url('./fonts/Poppins-Medium.ttf') format('truetype');
}
@font-face {
font-family: 'PoppinsBold';
src: url('./fonts/Poppins-SemiBold.ttf') format('truetype');
}
@font-face {
font-family: 'Instrument';
src: url('./fonts/InstrumentSans-Regular.ttf') format('truetype');
}
@font-face {
font-family: 'InstrumentBold';
src: url('./fonts/InstrumentSans-Bold.ttf') format('truetype');
}

View File

@@ -7,34 +7,36 @@ h1,
h2, h2,
h3, h3,
p { p {
margin: 0; margin: 0;
padding: 0; padding: 0;
} }
* { * {
box-sizing: border-box; box-sizing: border-box;
} }
html, html,
body, body,
#app { #app {
width: 100%; width: 100%;
height: 100%; height: 100%;
overflow: hidden; overflow: hidden;
} }
@keyframes loading { @keyframes loading {
0% { 0% {
transform: rotate(0deg); transform: rotate(0deg);
} }
100% { 100% {
transform: rotate(360deg); transform: rotate(360deg);
} }
} }
.background-pink { .background-pink {
background-color: rgba(248, 247, 245, 1); background-color: rgba(248, 247, 245, 1);
background-image: url('@/assets/images/home-bg.png'); background-image: url('@/assets/images/home-bg.png');
background-size: 100% 100%; background-size: 100% 100%;
} }

View File

@@ -7,7 +7,6 @@ import 'normalize.css'
import './assets/css/style.css' import './assets/css/style.css'
import SvgIcon from "@/components/SvgIcon/index.vue"; import SvgIcon from "@/components/SvgIcon/index.vue";
import "virtual:svg-icons-register"; import "virtual:svg-icons-register";
// import './assets/css/fonts/fontFamily.css'
import i18n from "./lang/index"; import i18n from "./lang/index";

View File

@@ -7,7 +7,7 @@ import Components from 'unplugin-vue-components/vite'
import DefineOptions from 'unplugin-vue-define-options/vite' import DefineOptions from 'unplugin-vue-define-options/vite'
import { createSvgIconsPlugin } from 'vite-plugin-svg-icons' import { createSvgIconsPlugin } from 'vite-plugin-svg-icons'
import path from 'path' import path from 'path'
import { ElementPlusResolver } from 'unplugin-vue-components/resolvers' import { ElementPlusResolver, AntDesignVueResolver } from 'unplugin-vue-components/resolvers'
// console.log(process) // console.log(process)
// console.log(import.meta.env.VITE_APP_URL) // console.log(import.meta.env.VITE_APP_URL)
@@ -15,64 +15,85 @@ import { ElementPlusResolver } from 'unplugin-vue-components/resolvers'
// https://vitejs.dev/config/ // https://vitejs.dev/config/
export default defineConfig(({ mode }) => { export default defineConfig(({ mode }) => {
const env = loadEnv(mode, process.cwd()) const env = loadEnv(mode, process.cwd())
return { return {
plugins: [ plugins: [
vue(), vue(),
DefineOptions(), DefineOptions(),
// ... // ...
AutoImport({ AutoImport({
resolvers: [ElementPlusResolver()], resolvers: [ElementPlusResolver()],
}), imports: [
Components({ 'vue',
resolvers: [ElementPlusResolver()], 'vue-router',
}), {
createSvgIconsPlugin({ 'lodash-es': [
// 指定需要缓存的图标文件夹 'debounce',
iconDirs: [path.resolve(process.cwd(), 'src/assets/icons')], 'cloneDeep',
// 指定symbolId格式 'cloneDeepWith',
symbolId: 'icon-[dir]-[name]', 'isBoolean',
inject: 'body-last' // 注入位置优化 'isString',
}) 'isNumber',
], 'isArray',
define: { 'isDate',
__VUE_PROD_HYDRATION_MISMATCH_DETAILS__: false, 'isFunction',
}, 'isNaN',
css: { 'isNull',
preprocessorOptions: { 'isObject',
less: { 'isUndefined'
modifyVars: { ]
'primary-color': '#ec6800' }
}, ],
javascriptEnabled: true, }),
// 全局导入less变量文件 Components({
additionalData: `@import "${path.resolve(__dirname, 'src/assets/css/style.less')}";` resolvers: [ElementPlusResolver(), AntDesignVueResolver({ importStyle: false })]
} }),
} createSvgIconsPlugin({
}, // 指定需要缓存的图标文件夹
resolve: { iconDirs: [path.resolve(process.cwd(), 'src/assets/icons')],
alias: { // 指定symbolId格式
'@': fileURLToPath(new URL('./src', import.meta.url)), symbolId: 'icon-[dir]-[name]',
_c: fileURLToPath(new URL('./src/components', import.meta.url)) inject: 'body-last' // 注入位置优化
} })
}, ],
server: { define: {
host: '0.0.0.0', // 允许局域网内的IP访问 __VUE_PROD_HYDRATION_MISMATCH_DETAILS__: false
port: 8060, // 根据环境设置端口 },
open: true, // 自动打开浏览器 css: {
strictPort: true, // 如果端口已被占用,则尝试下一个可用端口 preprocessorOptions: {
hmr: { less: {
overlay: true modifyVars: {
}, 'primary-color': '#ec6800'
proxy: { },
'/api': { javascriptEnabled: true,
//'/api'是自行设置的请求前缀 // 全局导入less变量文件
target: env.VITE_APP_URL, additionalData: `@import "${path.resolve(__dirname, 'src/assets/css/style.less')}";`
changeOrigin: true, //用于控制请求头中的host值 }
rewrite: (path) => path.replace(/^\/api/, '/api') //路径重写正则匹配以api开头的路径为空将请求前缀删除 }
} },
} resolve: {
} alias: {
} '@': fileURLToPath(new URL('./src', import.meta.url)),
_c: fileURLToPath(new URL('./src/components', import.meta.url))
}
},
server: {
host: '0.0.0.0', // 允许局域网内的IP访问
port: 8060, // 根据环境设置端口
open: true, // 自动打开浏览器
strictPort: true, // 如果端口已被占用,则尝试下一个可用端口
hmr: {
overlay: true
},
proxy: {
'/api': {
//'/api'是自行设置的请求前缀
target: env.VITE_APP_URL,
changeOrigin: true, //用于控制请求头中的host值
rewrite: (path) => path.replace(/^\/api/, '/api') //路径重写正则匹配以api开头的路径为空将请求前缀删除
}
}
}
}
}) })