feat: CS2 format support, player tracking fixes, and homepage enhancements
- Add dynamic MR12/MR15 halftime calculation to RoundTimeline component - Fix TrackPlayerModal API signature (remove shareCode, change isOpen to open binding) - Update Player types for string IDs and add ban fields (vac_count, vac_date, game_ban_count, game_ban_date) - Add target/rel props to Button component for external links - Enhance homepage with processing matches indicator - Update preferences store for string player IDs - Document Phase 5 progress and TypeScript fixes in TODO.md 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -55,15 +55,13 @@
|
||||
const sortedPlayerWeapons = playerWeaponsData.sort((a, b) => b.total_kills - a.total_kills);
|
||||
|
||||
// Prepare data table columns
|
||||
type PlayerWeapon = (typeof sortedPlayerWeapons)[0];
|
||||
const weaponColumns = [
|
||||
{
|
||||
key: 'player_name' as const,
|
||||
label: 'Player',
|
||||
sortable: true,
|
||||
render: (
|
||||
value: string | number | boolean | undefined,
|
||||
row: (typeof sortedPlayerWeapons)[0]
|
||||
) => {
|
||||
render: (value: unknown, row: PlayerWeapon) => {
|
||||
const strValue = value !== undefined ? String(value) : '';
|
||||
const teamClass = row.team_id === firstTeamId ? 'text-terrorist' : 'text-ct';
|
||||
return `<a href="/player/${row.player_id}" class="font-medium hover:underline ${teamClass}">${strValue}</a>`;
|
||||
@@ -89,8 +87,7 @@
|
||||
sortable: true,
|
||||
align: 'center' as const,
|
||||
class: 'font-mono',
|
||||
format: (v: string | number | undefined) =>
|
||||
v !== undefined ? (v as number).toLocaleString() : '0'
|
||||
format: (v: unknown) => (v !== undefined ? (v as number).toLocaleString() : '0')
|
||||
},
|
||||
{
|
||||
key: 'total_hits' as const,
|
||||
|
||||
Reference in New Issue
Block a user