< Summary

Information
Class: RaidLoop.Client.Components.ShopPanel
Assembly: RaidLoop.Client
File(s): /home/runner/work/RaidLoop/RaidLoop/src/RaidLoop.Client/Components/ShopPanel.razor
Line coverage
0%
Covered lines: 0
Uncovered lines: 9
Coverable lines: 9
Total lines: 22
Line coverage: 0%
Branch coverage
0%
Covered branches: 0
Total branches: 6
Branch coverage: 0%
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
BuildRenderTree(...)0%4260%
get_Stock()100%210%
get_Money()100%210%
get_CanBuyItem()100%210%
get_CanPurchaseItem()100%210%
get_GetBuyPrice()100%210%
get_OnBuy()100%210%

File(s)

/home/runner/work/RaidLoop/RaidLoop/src/RaidLoop.Client/Components/ShopPanel.razor

#LineLine coverage
 1<section class="panel top-gap">
 2    <h2>Shopkeeper</h2>
 3    <p>Stock expands by charisma tier.</p>
 04    @foreach (var stock in Stock)
 5    {
 6        <div class="row-item">
 07            <span class="item-name rarity-@stock.Item.DisplayRarity.ToString().ToLower()">@ItemPresentationCatalog.GetLa
 8            <div class="row-actions">
 09                <button class="action" disabled="@(!CanBuyItem(stock.Item) || !CanPurchaseItem(stock.Item) || Money < st
 10            </div>
 11        </div>
 12    }
 13</section>
 14
 15@code {
 016    [Parameter, EditorRequired] public IReadOnlyList<ShopStock> Stock { get; set; } = [];
 017    [Parameter, EditorRequired] public int Money { get; set; }
 018    [Parameter, EditorRequired] public Func<Item, bool> CanBuyItem { get; set; } = _ => false;
 019    [Parameter, EditorRequired] public Func<Item, bool> CanPurchaseItem { get; set; } = _ => false;
 020    [Parameter, EditorRequired] public Func<Item, int> GetBuyPrice { get; set; } = _ => 0;
 021    [Parameter, EditorRequired] public EventCallback<ShopStock> OnBuy { get; set; }
 22}