feat(WIP): process 등용 등

- ColorSelect 색을 가득 채움,
- ColorSelect 결과값을 둥글게
- procGeneralList의 column 가변형 정의
- 등용 brief 조사 처리 버그 수정
This commit is contained in:
2021-12-20 01:08:08 +09:00
parent 5d8e2c16f5
commit 6ac021ff12
9 changed files with 325 additions and 123 deletions
+11 -27
View File
@@ -3,42 +3,26 @@ import { combineArray } from "@/util/combineArray";
export type procGeneralItem = {
no: number,
name: string,
nationID?: number,
officerLevel: number,
npc: number,
gold: number,
rice: number,
gold?: number,
rice?: number,
leadership: number,
strength: number,
intel: number,
cityID: number,
crew: number,
train: number,
atmos: number,
troopID: number,
cityID?: number,
crew?: number,
train?: number,
atmos?: number,
troopID?: number,
}
export type procGeneralList = procGeneralItem[];
export type procGeneralKeyList = [
'no', 'name', 'officerLevel', 'npc', 'gold', 'rice', 'leadership', 'strength', 'intel', 'cityID', 'crew', 'train', 'atmos', 'troopID'
];
export type procGeneralKey = 'no'| 'name'| 'nationID' | 'officerLevel'| 'npc'| 'gold'| 'rice'| 'leadership'| 'strength'| 'intel'| 'cityID'| 'crew'| 'train'| 'atmos'| 'troopID';
export type procGeneralRawItem = [
procGeneralItem[procGeneralKeyList[0]],
procGeneralItem[procGeneralKeyList[1]],
procGeneralItem[procGeneralKeyList[2]],
procGeneralItem[procGeneralKeyList[3]],
procGeneralItem[procGeneralKeyList[4]],
procGeneralItem[procGeneralKeyList[5]],
procGeneralItem[procGeneralKeyList[6]],
procGeneralItem[procGeneralKeyList[7]],
procGeneralItem[procGeneralKeyList[8]],
procGeneralItem[procGeneralKeyList[9]],
procGeneralItem[procGeneralKeyList[10]],
procGeneralItem[procGeneralKeyList[11]],
procGeneralItem[procGeneralKeyList[12]],
procGeneralItem[procGeneralKeyList[13]],
];
export type procGeneralRawItem = procGeneralItem[procGeneralKey][];
export type procTroopItem = {
troop_leader: number,
@@ -49,7 +33,7 @@ export type procTroopList = Record<number, procTroopItem>;
export type procGeneralRawItemList = procGeneralRawItem[];
export function convertGeneralList(keys: procGeneralKeyList, rawList: procGeneralRawItemList): procGeneralList{
export function convertGeneralList(keys: procGeneralKey[], rawList: procGeneralRawItemList): procGeneralList{
return combineArray(rawList, keys) as procGeneralList;
}