feat: APIPathGen 도우미

This commit is contained in:
2021-12-28 04:28:26 +09:00
parent 499a2ee472
commit 0660180c53
3 changed files with 80 additions and 3 deletions
+16 -3
View File
@@ -163,11 +163,11 @@ export const NoneValue = 'None' as const;
export type Optional<Type> = {
[Property in keyof Type]+?: Type[Property];
};
};
export type OptionalFull<Type> = {
[Property in keyof Type]: Type[Property]|undefined;
};
[Property in keyof Type]: Type[Property] | undefined;
};
export type commandItem = {
value: string;
@@ -210,3 +210,16 @@ export type ChiefResponse = {
values: commandItem[];
}[];
};
type diplomacyInfo = {
name: string,
color?: string,
}
export type diplomacyState = 0 | 1 | 2 | 7;
export const diplomacyStateInfo: Record<diplomacyState, diplomacyInfo> = {
0: { name: '교전', color: 'red' },
1: { name: '선포중', color: 'magenta' },
2: { name: '통상' },
7: { name: '불가침', color: 'green' },
}