Adding deck disclaimer and removing hallucinated buttons

This commit is contained in:
2026-06-19 00:18:50 -04:00
parent 7978adbd37
commit ce5b45fe46
2 changed files with 2 additions and 31 deletions
+1 -31
View File
@@ -19,9 +19,6 @@
<button class="tab spell @(categoryFilter == "Spell" ? "active" : "")" @onclick='@(() => SetCategory("Spell"))'> <button class="tab spell @(categoryFilter == "Spell" ? "active" : "")" @onclick='@(() => SetCategory("Spell"))'>
<i class="bi bi-wand"></i> Spells <i class="bi bi-wand"></i> Spells
</button> </button>
<button class="tab token @(categoryFilter == "Token" ? "active" : "")" @onclick='@(() => SetCategory("Token"))'>
<i class="bi bi-coin"></i> Tokens
</button>
</div> </div>
<div class="filter-bar"> <div class="filter-bar">
@@ -43,7 +40,7 @@
</select> </select>
<select @bind="costFilter" class="form-select filter-select"> <select @bind="costFilter" class="form-select filter-select">
<option value="">All Costs</option> <option value="">All Costs</option>
@for (var i = 0; i <= 12; i++) @for (var i = 0; i <= 13; i++)
{ {
<option value="@i">@i</option> <option value="@i">@i</option>
} }
@@ -65,10 +62,6 @@
@onclick="() => showDetailedView = !showDetailedView" title="Toggle Detailed View"> @onclick="() => showDetailedView = !showDetailedView" title="Toggle Detailed View">
<i class="bi bi-list-ul"></i> <i class="bi bi-list-ul"></i>
</button> </button>
<button class="btn btn-outline-warning random-deck-btn" @onclick="GenerateRandomDeck"
title="Generate Random Deck">
<i class="bi bi-dice-5-fill"></i>
</button>
</div> </div>
@if (HasActiveFilters) @if (HasActiveFilters)
@@ -386,27 +379,4 @@
factionFilter = ""; factionFilter = "";
costFilter = ""; costFilter = "";
} }
private void GenerateRandomDeck()
{
var random = new Random();
var pool = allCards.Where(c => !c.IsToken && !string.IsNullOrEmpty(c.Faction)).ToList();
if (pool.Count < 40) return;
var selectedFaction = factions[random.Next(factions.Count)];
var factionPool = pool.Where(c => c.Faction == selectedFaction || c.Faction == "Neutral").ToList();
// Simple logic: pick 40 cards
var deckCards = factionPool.OrderBy(x => random.Next()).Take(40).Select(c => c.Name).ToList();
// For now, let's just log it or we could navigate to a "Create Deck" page if it existed.
// Since we don't have a create deck page in the context, let's just show a notification or similar.
// Actually, I'll just clear filters and search for these cards to "show" them.
search = string.Join(" | ", deckCards.Take(3)); // Just show a few to demonstrate
categoryFilter = "";
factionFilter = selectedFaction;
// In a real app, this would save to a new DeckData object.
}
} }
+1
View File
@@ -6,6 +6,7 @@
<div class="decks-header"> <div class="decks-header">
<h1>Decks</h1> <h1>Decks</h1>
<p class="text-secondary">@decks.Count deck@(decks.Count != 1 ? "s" : "")</p> <p class="text-secondary">@decks.Count deck@(decks.Count != 1 ? "s" : "")</p>
<p class="text-primary">Please note these are my crafted decks. They are probably not optimal or good. See <a href="https://runeterra.ar/chrono/home">Runeterra.ar</a> and check out the decks from recognizable names there. This is not an ad, just common sense.</p>
</div> </div>
<div class="deck-list"> <div class="deck-list">