Files
shd.build/src/lib/database/items.ts
T
jb 57068b61cd
Validate and deploy production / validate (push) Canceled after 0s
Validate and deploy production / deploy (push) Canceled after 0s
Validate and deploy staging / validate (push) Successful in 28s
Validate and deploy staging / deploy (push) Successful in 1m3s
feat: expand ISAC content modeling
2026-08-03 01:23:20 -04:00

70 lines
1.7 KiB
TypeScript

import type { GameIconName } from '$lib/game-icons';
import type { GameDataTargetType } from '$lib/game-data-targets';
export type DatabaseBadge = { label: string; tone?: string };
export type DatabaseMeter = { label: string; value: number };
export type DatabaseWeaponModSlot = {
slot: string;
unlockedAtTierOne: boolean;
iconUrl?: string;
};
export type DatabaseFact = {
label: string;
value: string;
emphasis?: 'primary';
gameIcon?: GameIconName;
note?: string;
meters?: DatabaseMeter[];
};
export type DatabaseItem = {
id: string;
targetType?: GameDataTargetType;
correctionHref?: string;
discussionHref?: string;
discussionCount?: number;
pinnedCommunityNoteHtml?: string;
name: string;
kicker: string;
variant?: 'talent';
iconUrl?: string;
renderUrl?: string;
gameIcon?: GameIconName;
headerBadge?: string;
headerBadgeTone?: string;
headerBadges?: string[];
headerMetaIcon?: GameIconName;
topBorderTone?: string;
badges?: DatabaseBadge[];
facts: DatabaseFact[];
factLayout?: 'grid' | 'stack';
actions?: Array<{ label: string; href: string }>;
lines?: DatabaseFact[];
afterLines?: DatabaseFact[];
iconGroups?: DatabaseIconGroup[];
weaponModSlots?: DatabaseWeaponModSlot[];
description?: string;
secondaryDescription?: string;
descriptionStyle?: 'prose' | 'data';
protocolPreview?: {
primaryStat: string;
primaryUnit: string;
primaryBaseValue: number;
talentDescription?: string;
talentEffects: Array<{ baseValue: number; unit: string }>;
};
};
export type DatabaseRelatedItem = {
id: string;
name: string;
iconUrl?: string;
preview?: DatabaseItem;
};
export type DatabaseIconGroup = {
label: string;
items: DatabaseRelatedItem[];
emptyLabel?: string;
};