From 9c06178a638a021649671d9b8d015278d1d52ae8 Mon Sep 17 00:00:00 2001
From: chylex <contact@chylex.com>
Date: Wed, 27 Dec 2023 22:35:33 +0100
Subject: [PATCH] Fix double padding in table cells with both clickable rows
 and custom classes

---
 Web/Phantom.Web.Components/Tables/Cell.razor | 5 +++--
 Web/Phantom.Web/wwwroot/css/site.css         | 4 +++-
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/Web/Phantom.Web.Components/Tables/Cell.razor b/Web/Phantom.Web.Components/Tables/Cell.razor
index 19ca5e1..5e1b123 100644
--- a/Web/Phantom.Web.Components/Tables/Cell.razor
+++ b/Web/Phantom.Web.Components/Tables/Cell.razor
@@ -1,10 +1,11 @@
-@if (Url == null) {
+@using Phantom.Web.Components.Utils
+@if (Url == null) {
   <td @attributes="AdditionalAttributes">
     @ChildContent
   </td>
 }
 else {
-  <td class="p-0" @attributes="AdditionalAttributes">
+  <td @attributes="AdditionalAttributes" class="@(BlazorUtils.CombineClassNames(AdditionalAttributes, "p-0"))">
     <a class="table-link" href="@Url">@ChildContent</a>
   </td>
 }
diff --git a/Web/Phantom.Web/wwwroot/css/site.css b/Web/Phantom.Web/wwwroot/css/site.css
index 734d141..f87679d 100644
--- a/Web/Phantom.Web/wwwroot/css/site.css
+++ b/Web/Phantom.Web/wwwroot/css/site.css
@@ -67,7 +67,9 @@ code {
   border-top: 2px solid #a6a6a6;
 }
 
-.table th, .table td, .table td > .table-link {
+.table th,
+.table td,
+.table td > .table-link {
   padding: 0.5rem 1.25rem;
 }