diff --git a/src/styles/components/_sheet.scss b/src/styles/components/_sheet.scss index 970cd255..f7954fae 100644 --- a/src/styles/components/_sheet.scss +++ b/src/styles/components/_sheet.scss @@ -89,7 +89,9 @@ border-radius: 0; height: 100%; overflow-x: hidden; - overflow-y: scroll; + // Only show the scrollbar when content overflows, avoiding a permanent + // (often empty) scrollbar in the fullscreen sheet. + overflow-y: auto; } > .mynah-card-body { @@ -126,7 +128,11 @@ gap: var(--mynah-sizing-4); align-items: stretch; flex: 1; - overflow-y: scroll; + // Use auto so the scrollbar only appears when the content actually + // overflows. With 'scroll' the sheet body always renders a scrollbar, + // which combined with the inner scrollable list (e.g. the MCP view) + // produced a redundant second scrollbar wrapping the whole panel. + overflow-y: auto; overflow-x: hidden; > .mynah-sheet-header-status { box-shadow: none; diff --git a/ui-tests/__test__/flows/quick-action-commands-header.ts b/ui-tests/__test__/flows/quick-action-commands-header.ts index c90e28b6..a0e6c7ae 100644 --- a/ui-tests/__test__/flows/quick-action-commands-header.ts +++ b/ui-tests/__test__/flows/quick-action-commands-header.ts @@ -137,9 +137,9 @@ export const verifyQuickActionCommandsHeaderStatusVariations = async (page: Page let foundStatusClass = false; for (const statusClass of statusClasses) { - const hasStatus = await headerElement.evaluate((el, className) => + const hasStatus = Boolean(await headerElement.evaluate((el, className) => el.classList.contains(className), statusClass - ); + )); if (hasStatus) { foundStatusClass = true; console.log(`Found status class: ${statusClass}`);