Skip to content

fix(ui5-color-palette): fix hover background shape mismatch in color palette popover buttons#13832

Open
unazko wants to merge 4 commits into
mainfrom
color_palette_button_hover
Open

fix(ui5-color-palette): fix hover background shape mismatch in color palette popover buttons#13832
unazko wants to merge 4 commits into
mainfrom
color_palette_button_hover

Conversation

@unazko

@unazko unazko commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Issue:

The Default Color and More colors... buttons inside the color palette popover are placed in wrapper elements (ui5-cp-default-color-button-wrapper and ui5-cp-more-colors-wrapper) that have a specific shape due to the popover's border-radius clipping. On hover, the button rendered its own background with four fully rounded corners, visually conflicting with the wrapper shape.

Solution:

Apply the hover background color on the wrapper elements instead of letting the button render it. The button's own hover background and border are overridden to transparent via CSS custom properties scoped to those wrappers, so the highlight takes the correct shape of the wrapper.

Fixes: #13763

…palette popover buttons

Issue:
The Default Color and More colors... buttons inside the color palette popover
are placed in wrapper elements (ui5-cp-default-color-button-wrapper and
ui5-cp-more-colors-wrapper) that have a specific shape due to the popover's
border-radius clipping. On hover, the button rendered its own background with
four fully rounded corners, visually conflicting with the wrapper shape.

Solution:
Apply the hover background color on the wrapper elements instead of letting
the button render it. The button's own hover background and border are
overridden to transparent via CSS custom properties scoped to those wrappers,
so the highlight takes the correct shape of the wrapper.

Fixes: #13763
@unazko unazko temporarily deployed to netlify-preview July 15, 2026 12:36 — with GitHub Actions Inactive
@sap-ui5-webcomponents-release

Copy link
Copy Markdown

…palette popover buttons

Issue:
The Default Color and More colors... buttons inside the color palette popover
are placed in wrapper elements that have a specific shape due to the popover's
border-radius clipping. On hover, the button rendered its own background with
four fully rounded corners, visually conflicting with the wrapper shape.
Additionally, the buttons displayed a visible border and used the blue link
text color from the Transparent button design instead of the standard text color.

Solution:
Override CSS custom properties on the button elements inside the wrappers.
Setting --_ui5_button_border_radius to 0 removes the button's own corner
rounding so the rectangular hover background fills the full wrapper area,
relying on the popover's overflow: hidden to clip the corners correctly.
Setting --sapButton_Lite_BorderColor and --sapButton_Lite_Hover_BorderColor
to transparent removes the visible border in both normal and hover states.
Setting --sapButton_Lite_TextColor and --sapButton_Lite_Hover_TextColor to
--sapTextColor aligns the text color with the design specification.

Fixes: #13763
@unazko unazko temporarily deployed to netlify-preview July 15, 2026 13:45 — with GitHub Actions Inactive
@unazko unazko temporarily deployed to netlify-preview July 15, 2026 13:49 — with GitHub Actions Inactive
…palette popover buttons

Issue:
The Default Color and More colors... buttons inside the color palette popover
are placed in wrapper elements that have a specific shape due to the popover's
border-radius clipping. On hover, the button rendered its own background with
four fully rounded corners, visually conflicting with the wrapper shape.
Additionally, the buttons used the blue link text color from the Transparent
button design instead of the standard text color.

Solution:
Override --_ui5_button_border_radius to 0 on the button elements so the
rectangular hover background fills the full wrapper area, relying on the
popover's overflow: hidden to clip the corners correctly.
Introduce --_ui5_color-palette-button-text-color in the component parameters
and use it to override --sapButton_Lite_TextColor and
--sapButton_Lite_Hover_TextColor, scoped only to those buttons.

Fixes: #13763
@unazko unazko temporarily deployed to netlify-preview July 15, 2026 13:59 — with GitHub Actions Inactive
@unazko unazko requested a review from didip1000 July 15, 2026 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ColorPalettePopover buttons have incorrect hover and down states

1 participant