Improved ux for ticket popup

This commit is contained in:
Marcel Baumgartner
2024-02-13 22:46:31 +01:00
parent 068858f3a1
commit 6ec86fdc25

View File

@@ -1,36 +1,37 @@
@using Moonlight.Features.Ticketing.Entities @using Moonlight.Features.Ticketing.Entities
<div class="mb-4 me-4 d-flex justify-content-end fixed-bottom" style="pointer-events: none;"> <div class="mb-4 me-4 d-flex justify-content-end fixed-bottom" style="pointer-events: none;">
<CascadingValue Value="this"> <CascadingValue Value="this">
@if (ViewIndex == 0) @if (ViewIndex == 0)
{ {
<button @onclick="() => SetViewIndex(1)" class="btn btn-lg btn-icon btn-rounded-circle bg-secondary btn-white border border-2 border-warning" style="pointer-events: all"> <button @onclick="() => SetViewIndex(1)" class="btn btn-lg btn-icon btn-rounded-circle bg-secondary btn-white border border-2 border-warning hover-scale opacity-50 opacity-100-hover" style="pointer-events: all">
<i class="bx bg-lg bx-chat"></i> <i class="bx bg-lg bx-chat"></i>
</button> </button>
} }
else else
{ {
<div class="card border border-2 border-warning" style="pointer-events: all; height: 70vh"> <div class="card border border-2 border-warning" style="pointer-events: all; height: 70vh">
@if (ViewIndex == 1) @if (ViewIndex == 1)
{ {
<TicketPopupOverview /> <TicketPopupOverview/>
} }
else if (ViewIndex == 2) else if (ViewIndex == 2)
{ {
<TicketPopupView /> <TicketPopupView/>
} }
else if (ViewIndex == 3) else if (ViewIndex == 3)
{ {
<TicketPopupCreate /> <TicketPopupCreate/>
} }
</div> </div>
} }
</CascadingValue> </CascadingValue>
</div> </div>
@code @code
{ {
private int ViewIndex = 0; private int ViewIndex = 0;
public Ticket CurrentTicket { get; private set; } public Ticket CurrentTicket { get; private set; }
public async Task SetViewIndex(int index) public async Task SetViewIndex(int index)