From db7eac7488d08af69525058bd4d0f16acb44c99f Mon Sep 17 00:00:00 2001 From: Matt Driscoll Date: Fri, 4 Aug 2023 08:53:16 -0700 Subject: [PATCH] fix(panel): Correct header and action-bar z-indexing display issues (#7440) **Related Issue:** #7437 ## Summary - Places action-bar within the header so the z-index isn't an issue anymore - Adjust styles as necessary - Adjust rendering as necessary - Adds screenshot test --- .../src/components/panel/panel.scss | 18 ++++++++----- .../src/components/panel/panel.stories.ts | 19 ++++++++++++++ .../src/components/panel/panel.tsx | 26 ++++++++++++------- .../src/components/panel/resources.ts | 2 ++ 4 files changed, 49 insertions(+), 16 deletions(-) diff --git a/packages/calcite-components/src/components/panel/panel.scss b/packages/calcite-components/src/components/panel/panel.scss index e8958a2415d..02d164f02e3 100644 --- a/packages/calcite-components/src/components/panel/panel.scss +++ b/packages/calcite-components/src/components/panel/panel.scss @@ -29,17 +29,23 @@ } .header { - @apply bg-foreground-1 - w-full - items-stretch - justify-start + @apply bg-foreground-1 flex flex-col z-header; +} + +.header-container { + @apply flex flex-row w-full + items-stretch + justify-start; flex: 0 0 auto; } .action-bar-container { - @apply w-full - z-header; + @apply w-full; +} + +.top-separator { + border-block-start: 1px solid var(--calcite-ui-border-3); } .bottom-separator { diff --git a/packages/calcite-components/src/components/panel/panel.stories.ts b/packages/calcite-components/src/components/panel/panel.stories.ts index 8d8913220d3..b043a0e3284 100644 --- a/packages/calcite-components/src/components/panel/panel.stories.ts +++ b/packages/calcite-components/src/components/panel/panel.stories.ts @@ -241,6 +241,25 @@ export const actionBarWithoutContent_TestOnly = (): string => html` `; +export const actionBarZIndex_TestOnly = (): string => html` + + + + + + + test + + + + +

Some content

`; + export const footerAndActionBarWithoutContent_TestOnly = (): string => html`