feat : buzz feedback
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
export function artifactTierCount(secondName: string | null): 2 | 4 {
|
||||
return secondName ? 2 : 4;
|
||||
}
|
||||
@@ -175,6 +175,7 @@ export async function getPublicTeamExport(teamId: string) {
|
||||
|
||||
return {
|
||||
...row.team,
|
||||
guideId: row.guide.id,
|
||||
guideName: row.guide.name,
|
||||
members: members.map(({ member, character }) => {
|
||||
const weapon = weapons.find((item) => item.key === member.weaponKey);
|
||||
|
||||
@@ -113,6 +113,7 @@ export const extraSectionSchema = z.strictObject({
|
||||
title: z.string().trim().min(1).max(160),
|
||||
rows: z.array(z.strictObject({
|
||||
mediaId: z.string().uuid().nullable(),
|
||||
ratio: z.enum(["1:1", "16:9"]),
|
||||
heading: z.string().trim().min(1).max(200),
|
||||
body: z.string().trim().max(2_000),
|
||||
percent: percent.nullable(),
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
|
||||
import { normalizeTalentPriorities, reorderTalentPriorities, talentRelationSymbol } from "@/lib/guides/talents";
|
||||
import { normalizeTalentPriorities, reorderTalentPriorities, talentRelationSymbol, talentTypeLabel } from "@/lib/guides/talents";
|
||||
|
||||
describe("talent priorities", () => {
|
||||
it("normalizes legacy talents to strict comparisons", () => {
|
||||
@@ -32,4 +32,10 @@ describe("talent priorities", () => {
|
||||
expect(talentRelationSymbol("gte")).toBe("≥");
|
||||
expect(talentRelationSymbol()).toBe(">");
|
||||
});
|
||||
|
||||
it("labels each talent type in Thai", () => {
|
||||
expect(talentTypeLabel("NA")).toBe("ตีปกติ");
|
||||
expect(talentTypeLabel("E")).toBe("สกิลธาตุ");
|
||||
expect(talentTypeLabel("Q")).toBe("ท่าไม้ตาย");
|
||||
});
|
||||
});
|
||||
|
||||
@@ -41,3 +41,7 @@ export function reorderTalentPriorities(
|
||||
export function talentRelationSymbol(relation?: TalentRelation): ">" | "≥" {
|
||||
return relation === "gte" ? "≥" : ">";
|
||||
}
|
||||
|
||||
export function talentTypeLabel(type: TalentPriority["type"]): string {
|
||||
return type === "E" ? "สกิลธาตุ" : type === "Q" ? "ท่าไม้ตาย" : "ตีปกติ";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user