From d8eb6b965afdbf2fd9a1a2a6630902af976adced Mon Sep 17 00:00:00 2001 From: Justin Edmund Date: Wed, 24 Sep 2025 00:45:40 -0700 Subject: [PATCH] Update description sidebar padding and title --- .../sidebar/DescriptionSidebar.svelte | 77 ++++++------------- .../openDescriptionSidebar.svelte.ts | 4 +- 2 files changed, 25 insertions(+), 56 deletions(-) diff --git a/src/lib/components/sidebar/DescriptionSidebar.svelte b/src/lib/components/sidebar/DescriptionSidebar.svelte index 3c7c8a75..e8fe9d2b 100644 --- a/src/lib/components/sidebar/DescriptionSidebar.svelte +++ b/src/lib/components/sidebar/DescriptionSidebar.svelte @@ -14,40 +14,25 @@
- {#if title} -
-

{title}

-
- {/if} - - {#if description} -
- -
- {:else} -
-

No description available for this party.

- {#if canEdit} - - {/if} -
- {/if} +
+ {#if description} +
+ +
+ {:else} +
+

No description available for this party.

+ {#if canEdit} + + {/if} +
+ {/if} +
{#if canEdit && description}
- +
{/if}
@@ -62,35 +47,14 @@ display: flex; flex-direction: column; height: 100%; - padding: $unit-2x; color: var(--text-primary); } .content-section { flex: 1; overflow-y: auto; - } - .party-title { - margin-bottom: $unit-3x; - padding-bottom: $unit-2x; - border-bottom: 1px solid var(--button-bg); - - h2 { - margin: 0; - font-size: $font-xlarge; - font-weight: $bold; - color: var(--text-primary); - line-height: 1.2; - } - } - - .description-content { - // Allow the content to scroll if it's very long - overflow-y: auto; - padding-right: $unit; - - // Custom scrollbar styling + // Custom scrollbar styling - on the outer container &::-webkit-scrollbar { width: 6px; } @@ -110,6 +74,10 @@ } } + .content-inner { + padding: 0 $unit-2x; + } + .empty-state { display: flex; flex-direction: column; @@ -128,11 +96,12 @@ .actions-section { margin-top: $unit-2x; - padding-top: $unit-2x; + padding: $unit-2x; + padding-bottom: $unit-2x; border-top: 1px solid var(--button-bg); :global(.edit-button) { width: 100%; } } - \ No newline at end of file + diff --git a/src/lib/features/description/openDescriptionSidebar.svelte.ts b/src/lib/features/description/openDescriptionSidebar.svelte.ts index ba37c12f..09a20b1f 100644 --- a/src/lib/features/description/openDescriptionSidebar.svelte.ts +++ b/src/lib/features/description/openDescriptionSidebar.svelte.ts @@ -11,8 +11,8 @@ interface DescriptionSidebarOptions { export function openDescriptionSidebar(options: DescriptionSidebarOptions) { const { title, description, canEdit = false, onEdit } = options - // Open the sidebar with the description component - sidebar.openWithComponent('Description', DescriptionSidebar, { + // Open the sidebar with the party title as the header + sidebar.openWithComponent(title, DescriptionSidebar, { title, description, canEdit,