feat: betting history with P&L tracking on bot profile
BetHistory component shows personal bet history with fight links, amounts, outcomes, and payouts. P&L summary shows total wagered, total won, and net sats. Added to BotProfilePage for the bot owner's view. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
005a7942fb
commit
5e598e3987
@@ -5,6 +5,7 @@ import { useNostr } from '../composables/useNostr'
|
||||
import SpritePreview from '../components/SpritePreview.vue'
|
||||
import HumanPreview from '../components/HumanPreview.vue'
|
||||
import WalletConnect from '../components/WalletConnect.vue'
|
||||
import BetHistory from '../components/BetHistory.vue'
|
||||
import type { SpriteCustomization } from '../game/sprites'
|
||||
|
||||
const route = useRoute()
|
||||
@@ -701,9 +702,9 @@ const tierClass = (t: number) => `tier-${t}`
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- RIGHT COLUMN: Recent bouts (scrollable) -->
|
||||
<div class="flex-1 min-w-0 flex flex-col min-h-0 mt-6 lg:mt-0">
|
||||
<div class="border border-border bg-surface-raised/30 flex flex-col flex-1 min-h-0 overflow-hidden">
|
||||
<!-- RIGHT COLUMN: Recent bouts + Bet history (scrollable) -->
|
||||
<div class="flex-1 min-w-0 flex flex-col min-h-0 mt-6 lg:mt-0 gap-4">
|
||||
<div class="border border-border bg-surface-raised/30 flex flex-col min-h-0 overflow-hidden">
|
||||
<div class="px-4 py-3 border-b border-border/50 flex-shrink-0">
|
||||
<p class="font-display text-[10px] font-bold text-text-muted tracking-[0.15em]">
|
||||
RECENT BOUTS
|
||||
@@ -729,6 +730,11 @@ const tierClass = (t: number) => `tier-${t}`
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Bet history (owner's view) -->
|
||||
<div v-if="isOwner && pubkey" class="border border-border bg-surface-raised/30 p-3">
|
||||
<BetHistory :pubkey="pubkey" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user