From 7407a3d8810f85666f3035c4b4a92c854da9976d Mon Sep 17 00:00:00 2001 From: Martin Berka Date: Thu, 16 Oct 2025 08:06:22 +0200 Subject: [PATCH] =?UTF-8?q?Oprava=20hover=20popisk=C5=AF=20u=20Font=20Awes?= =?UTF-8?q?ome=20ikon?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- client/src/App.tsx | 27 +++++++++++++++++-------- client/src/components/PizzaOrderRow.tsx | 10 +++++---- client/src/pages/StatsPage.tsx | 8 ++++++-- 3 files changed, 31 insertions(+), 14 deletions(-) diff --git a/client/src/App.tsx b/client/src/App.tsx index 237eb9c..335098f 100644 --- a/client/src/App.tsx +++ b/client/src/App.tsx @@ -454,9 +454,13 @@ function App() { {dayIndex != null &&
- 0 ? "initial" : "hidden" }} onClick={() => handleDayChange(dayIndex - 1)} /> + + 0 ? "initial" : "hidden" }} onClick={() => handleDayChange(dayIndex - 1)} /> +

{data.date}

- handleDayChange(dayIndex + 1)} /> + + handleDayChange(dayIndex + 1)} /> +
} @@ -531,12 +535,16 @@ function App() { {login} {userPayload.departureTime && ({userPayload.departureTime})} {userPayload.note && ({userPayload.note})} - {login === auth.login && canChangeChoice && { + {login === auth.login && canChangeChoice && + { setNoteModalOpen(true); - }} title='Upravit poznámku' className='action-icon' icon={faNoteSticky} />} - {login === auth.login && canChangeChoice && { + }} className='action-icon' icon={faNoteSticky} /> + } + {login === auth.login && canChangeChoice && + { doRemoveChoices(key as LunchChoice); - }} title={`Odstranit volbu ${locationName}, včetně případných zvolených jídel`} className='action-icon' icon={faTrashCan} />} + }} className='action-icon' icon={faTrashCan} /> + } {userChoices?.length && food ?
    @@ -545,9 +553,12 @@ function App() { const foodName = food[restaurantKey]?.food?.[foodIndex].name; return
  • {foodName} - {login === auth.login && canChangeChoice && { + {login === auth.login && canChangeChoice && + + { doRemoveFoodChoice(restaurantKey, foodIndex); - }} title={`Odstranit ${foodName}`} className='action-icon' icon={faTrashCan} />} + }} className='action-icon' icon={faTrashCan} /> + }
  • })}
diff --git a/client/src/components/PizzaOrderRow.tsx b/client/src/components/PizzaOrderRow.tsx index 896e65a..f685005 100644 --- a/client/src/components/PizzaOrderRow.tsx +++ b/client/src/components/PizzaOrderRow.tsx @@ -28,9 +28,11 @@ export default function PizzaOrderRow({ creator, order, state, onDelete, onFeeMo {`${pizzaOrder.name}, ${pizzaOrder.size} (${pizzaOrder.price} Kč)`} {auth?.login === order.customer && state === PizzaDayState.CREATED && - { - onDelete(pizzaOrder); - }} title='Odstranit' className='action-icon' icon={faTrashCan} /> + + { + onDelete(pizzaOrder); + }} className='action-icon' icon={faTrashCan} /> + } ) .reduce((prev, curr, index) => [prev,
, curr])} @@ -38,7 +40,7 @@ export default function PizzaOrderRow({ creator, order, state, onDelete, onFeeMo {order.note ?? '-'} {order.fee?.price ? `${order.fee.price} Kč${order.fee.text ? ` (${order.fee.text})` : ''}` : '-'} - {order.totalPrice} Kč{auth?.login === creator && state === PizzaDayState.CREATED && { setIsFeeModalOpen(true) }} title='Nastavit příplatek' className='action-icon' icon={faMoneyBill1} />} + {order.totalPrice} Kč{auth?.login === creator && state === PizzaDayState.CREATED && { setIsFeeModalOpen(true) }} className='action-icon' icon={faMoneyBill1} />} setIsFeeModalOpen(false)} onSave={saveFees} initialValues={{ text: order.fee?.text, price: order.fee?.price?.toString() }} /> diff --git a/client/src/pages/StatsPage.tsx b/client/src/pages/StatsPage.tsx index e202f89..33f83de 100644 --- a/client/src/pages/StatsPage.tsx +++ b/client/src/pages/StatsPage.tsx @@ -107,9 +107,13 @@ export default function StatsPage() {

Statistiky

- + + +

{getHumanDate(dateRange[0])} - {getHumanDate(dateRange[1])}

- + + +
{Object.values(LunchChoice).map(location => renderLine(location))}