feat(web): refresh the app with Astryx and coral branding
This commit is contained in:
1 parent
f649490cd2
commit
da7b502936
140 files changed
+4531
-2368
No files matched your search
@@ -16,6 +16,7 @@ import {
|
||||
} from "../lib/internal-game-matchups";
|
||||
import { ItemIcon, RuneIcon, RuneStyleIcon } from "./ItemTooltip";
|
||||
|
||||
import { Tab, TabList } from "@astryxdesign/core/TabList";
|
||||
export type InternalGameDetailTab = "scoreboard" | "matchup" | "build";
|
||||
|
||||
type InternalGameDetail = ApiInternalMatchDetailResponse["games"][number];
|
||||
@@ -36,10 +37,10 @@ const SKILL_ROWS: Array<{
|
||||
label: string;
|
||||
className: string;
|
||||
}> = [
|
||||
{ slot: 1, label: "Q", className: "bg-blue-500 text-white" },
|
||||
{ slot: 1, label: "Q", className: "bg-win text-white" },
|
||||
{ slot: 2, label: "W", className: "bg-cyan-500 text-white" },
|
||||
{ slot: 3, label: "E", className: "bg-amber-500 text-black" },
|
||||
{ slot: 4, label: "R", className: "bg-red-500 text-white" },
|
||||
{ slot: 4, label: "R", className: "bg-loss text-white" },
|
||||
];
|
||||
|
||||
const STAT_PERK_LABELS: Record<number, string> = {
|
||||
@@ -71,16 +72,16 @@ function formatSignedNumber(value: number) {
|
||||
function sideTone(side: TeamSide) {
|
||||
return side === "blue"
|
||||
? {
|
||||
border: "border-blue-500/20",
|
||||
bg: "bg-blue-500/5",
|
||||
text: "text-blue-400",
|
||||
bar: "bg-blue-500",
|
||||
border: "border-win-line",
|
||||
bg: "bg-win-tint",
|
||||
text: "text-win",
|
||||
bar: "bg-win",
|
||||
}
|
||||
: {
|
||||
border: "border-red-500/20",
|
||||
bg: "bg-red-500/5",
|
||||
text: "text-red-400",
|
||||
bar: "bg-red-500",
|
||||
border: "border-loss-line",
|
||||
bg: "bg-loss-tint",
|
||||
text: "text-loss",
|
||||
bar: "bg-loss",
|
||||
};
|
||||
}
|
||||
|
||||
@@ -672,7 +673,7 @@ function MatchupMetricRow({
|
||||
<div className="grid grid-cols-[1fr_auto_1fr] items-center gap-2 px-3 py-1.5 text-xs">
|
||||
<span
|
||||
className={`text-right tabular-nums ${
|
||||
blueLead ? "font-bold text-blue-400" : "text-base-content/55"
|
||||
blueLead ? "font-bold text-win" : "text-base-content/55"
|
||||
}`}
|
||||
>
|
||||
{blueText}
|
||||
@@ -687,7 +688,7 @@ function MatchupMetricRow({
|
||||
</span>
|
||||
<span
|
||||
className={`tabular-nums ${
|
||||
redLead ? "font-bold text-red-400" : "text-base-content/55"
|
||||
redLead ? "font-bold text-loss" : "text-base-content/55"
|
||||
}`}
|
||||
>
|
||||
{redText}
|
||||
@@ -899,11 +900,11 @@ function LaneMatchupPanel({
|
||||
<section className="overflow-hidden border border-base-content/10 bg-base-100">
|
||||
<div className="border-b border-base-content/8 px-4 py-3">
|
||||
<div className="grid grid-cols-[1fr_auto_1fr] items-center gap-3 text-xs font-bold">
|
||||
<span className="truncate text-right text-blue-400">
|
||||
<span className="truncate text-right text-win">
|
||||
{blueTeamName}
|
||||
</span>
|
||||
<span className="text-base-content/20">VS</span>
|
||||
<span className="truncate text-red-400">{redTeamName}</span>
|
||||
<span className="truncate text-loss">{redTeamName}</span>
|
||||
</div>
|
||||
<div
|
||||
className="mx-auto mt-3 flex w-fit border border-base-content/10"
|
||||
@@ -959,28 +960,19 @@ export function InternalGameDetailTabBar({
|
||||
onChange: (tab: InternalGameDetailTab) => void;
|
||||
}) {
|
||||
return (
|
||||
<div
|
||||
className="flex flex-wrap border-b border-base-content/8"
|
||||
role="tablist"
|
||||
<TabList
|
||||
aria-label="상세 분석"
|
||||
value={activeTab}
|
||||
hasDivider
|
||||
onChange={(next) => {
|
||||
const tab = DETAIL_TABS.find((candidate) => candidate.id === next);
|
||||
if (tab) onChange(tab.id);
|
||||
}}
|
||||
>
|
||||
{DETAIL_TABS.map((tab) => (
|
||||
<button
|
||||
key={tab.id}
|
||||
type="button"
|
||||
role="tab"
|
||||
aria-selected={activeTab === tab.id}
|
||||
onClick={() => onChange(tab.id)}
|
||||
className={`border-b-2 px-3 py-2 text-xs font-semibold transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-primary ${
|
||||
activeTab === tab.id
|
||||
? "border-primary bg-primary/5 text-primary"
|
||||
: "border-transparent text-base-content/45 hover:text-base-content"
|
||||
}`}
|
||||
>
|
||||
{tab.label}
|
||||
</button>
|
||||
<Tab key={tab.id} value={tab.id} label={tab.label} />
|
||||
))}
|
||||
</div>
|
||||
</TabList>
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user