You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
70 lines
2.5 KiB
70 lines
2.5 KiB
@page "/Inventaire"
|
|
@using System.Globalization
|
|
@using ValblazeProject.Components
|
|
@using ValblazeProject.Models
|
|
|
|
<link href="/path/to/bootstrap.min.css" rel="stylesheet">
|
|
<link href="dist/css/component-custom-switch.css" rel="stylesheet">
|
|
|
|
<main class="contentInvent">
|
|
<div class="inventaire">
|
|
<h3>@Localizer["key1"]</h3>
|
|
<div class="caseInvent">
|
|
@for(int i=0; i<10; i++){
|
|
<CraftingItem Index="i"/>
|
|
}
|
|
</div>
|
|
<label class="mt-2">Actions</label>
|
|
<div class="actions" id="actions"></div>
|
|
</div>
|
|
|
|
<div class="maList">
|
|
<div class="toolSearch">
|
|
<label>
|
|
@Localizer["key2"]
|
|
<input type="text" @bind-value="search"/>
|
|
</label>
|
|
<label class="LabelFiltre">
|
|
@Localizer["key3"]
|
|
<input class="filtre" @bind-value="trieActive" onclick="@TrieChanged" type="checkbox">
|
|
</label>
|
|
</div>
|
|
|
|
|
|
<DataGrid TItem="Item"
|
|
Data="@items"
|
|
ReadData="@OnReadData"
|
|
TotalItems="@totalItem"
|
|
PageSize="@totalSizeByPage"
|
|
@ref="dataGrid"
|
|
ShowPager
|
|
Responsive>
|
|
<DataGridColumn TItem="Item" Field="@nameof(Item.Id)">
|
|
<DisplayTemplate>
|
|
@if (!string.IsNullOrWhiteSpace(context.ImageBase64))
|
|
{
|
|
<div
|
|
class="item"
|
|
ondragover="event.preventDefault();"
|
|
draggable="true"
|
|
@ondragstart="@OnDragStart"
|
|
@ondrop="@OnDrop"
|
|
@ondragenter="@OnDragEnter"
|
|
@ondragleave="@OnDragLeave">
|
|
|
|
@if (context != null)
|
|
{
|
|
<img src="data:image/png;base64, @(context.ImageBase64)" class="img-thumbnail imageList" title="@context.DisplayName" alt="@context.DisplayName" />
|
|
}
|
|
</div>
|
|
}
|
|
else
|
|
{
|
|
<img src="images/default.png" class="img-thumbnail imageList" title="@context.DisplayName" alt="@context.DisplayName"/>
|
|
}
|
|
</DisplayTemplate>
|
|
</DataGridColumn>
|
|
<DataGridColumn TItem="Item" Field="@nameof(Item.DisplayName)"/>
|
|
</DataGrid>
|
|
</div>
|
|
</main> |