style(Lineup): 优化代码格式和布局
- 调整了代码的缩进和空格,提高了可读性 -修复了一些小的语法问题,如缺少逗号等 - 优化了部分长行的换行方式,提高了代码的整洁度
This commit is contained in:
@@ -8,4 +8,8 @@ export default defineConfig({
|
|||||||
'process.env.VITE_API_BASE_URL': JSON.stringify(process.env.VITE_API_BASE_URL),
|
'process.env.VITE_API_BASE_URL': JSON.stringify(process.env.VITE_API_BASE_URL),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
html: {
|
||||||
|
title: '露娜助手',
|
||||||
|
favicon: './public/favicon.svg',
|
||||||
|
},
|
||||||
});
|
});
|
||||||
|
|||||||
14
src/api/types.ts
Normal file
14
src/api/types.ts
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
export interface Character {
|
||||||
|
id: number;
|
||||||
|
name: string;
|
||||||
|
code: string;
|
||||||
|
element: string;
|
||||||
|
class: string;
|
||||||
|
role: string;
|
||||||
|
imageUrl: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface CharacterListResponse {
|
||||||
|
characters: Character[];
|
||||||
|
total: number;
|
||||||
|
}
|
||||||
@@ -252,13 +252,13 @@ const Lineup: React.FC = () => {
|
|||||||
{/* 装备信息 */}
|
{/* 装备信息 */}
|
||||||
<div>
|
<div>
|
||||||
<h4 className="text-lg font-semibold text-[#E6B17E] mb-2">装备信息</h4>
|
<h4 className="text-lg font-semibold text-[#E6B17E] mb-2">装备信息</h4>
|
||||||
<p className="text-[#9B8579]">{lineup.equipmentInfo}</p>
|
<p className="text-[#9B8579] whitespace-pre-line">{lineup.equipmentInfo.replace(/[^\S\n]/g, '')}</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{/* 神器信息 */}
|
{/* 神器信息 */}
|
||||||
<div>
|
<div>
|
||||||
<h4 className="text-lg font-semibold text-[#E6B17E] mb-2">神器信息</h4>
|
<h4 className="text-lg font-semibold text-[#E6B17E] mb-2">神器信息</h4>
|
||||||
<p className="text-[#9B8579]">{lineup.artifacts}</p>
|
<p className="text-[#9B8579] whitespace-pre-line">{lineup.artifacts.replace(/[^\S\n]/g, '')}</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -266,13 +266,13 @@ const Lineup: React.FC = () => {
|
|||||||
{/* 前置条件 */}
|
{/* 前置条件 */}
|
||||||
<div>
|
<div>
|
||||||
<h4 className="text-lg font-semibold text-[#E6B17E] mb-2">前置条件</h4>
|
<h4 className="text-lg font-semibold text-[#E6B17E] mb-2">前置条件</h4>
|
||||||
<p className="text-[#9B8579]">{lineup.prerequisites}</p>
|
<p className="text-[#9B8579] whitespace-pre-line">{lineup.prerequisites.replace(/[^\S\n]/g, '')}</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{/* 重要提示 */}
|
{/* 重要提示 */}
|
||||||
<div>
|
<div>
|
||||||
<h4 className="text-lg font-semibold text-[#E6B17E] mb-2">重要提示</h4>
|
<h4 className="text-lg font-semibold text-[#E6B17E] mb-2">重要提示</h4>
|
||||||
<p className="text-[#9B8579]">{lineup.importantNotes}</p>
|
<p className="text-[#9B8579] whitespace-pre-line">{lineup.importantNotes.replace(/[^\S\n]/g, '')}</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user