From 5c004422f268fc8fe4fdd6035a32382c88878ace Mon Sep 17 00:00:00 2001 From: Tiago Yamamoto Date: Mon, 22 Dec 2025 15:42:58 -0300 Subject: [PATCH] feat(marketplace): fix R$ NaN and add owner navigation links --- marketplace/src/layouts/Shell.tsx | 30 +++++++++++++++++++++++++----- marketplace/src/pages/Checkout.tsx | 12 ++++++++++-- 2 files changed, 35 insertions(+), 7 deletions(-) diff --git a/marketplace/src/layouts/Shell.tsx b/marketplace/src/layouts/Shell.tsx index 3b9edfd..0fc4353 100644 --- a/marketplace/src/layouts/Shell.tsx +++ b/marketplace/src/layouts/Shell.tsx @@ -4,6 +4,9 @@ import { useAuth } from '../context/AuthContext' export function Shell({ children }: { children: React.ReactNode }) { const { user, logout } = useAuth() + const isOwner = user?.role === 'owner' || user?.role === 'seller' + const isAdmin = user?.role === 'admin' + return (
@@ -11,20 +14,37 @@ export function Shell({ children }: { children: React.ReactNode }) {
MP

Marketplace FarmacĂȘutico B2B

-

Dashboard de Compras

+

+ {isAdmin ? 'Painel Administrativo' : isOwner ? 'Painel do Dono' : 'Dashboard'} +