Skip to content

Commit

Permalink
feat(ui5-radio-button): expose new Css shadow parts
Browse files Browse the repository at this point in the history
We received the following requests for customization of certain parts of the ui5-radio-button:
- inner ring color on hover: can be styled via the new "inner-ring" Css shadow part.
- outer ring Error and Success state colors: can be styled via the new "outer-ring" Css shadow part.

Part of #8105
  • Loading branch information
s-todorova committed Feb 25, 2024
1 parent fae03eb commit 02571fe
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/main/src/RadioButton.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
>
<div class='ui5-radio-inner {{classes.inner}}'>
<svg class="ui5-radio-svg" focusable="false" aria-hidden="true">
<circle class="ui5-radio-svg-outer" cx="50%" cy="50%" r="50%" />
<circle class="ui5-radio-svg-inner" cx="50%" cy="50%" />
<circle part="outer-ring" class="ui5-radio-svg-outer" cx="50%" cy="50%" r="50%" />
<circle part="inner-ring" class="ui5-radio-svg-inner" cx="50%" cy="50%" />
</svg>
<input type='radio' ?required="{{required}}" ?checked="{{checked}}" ?readonly="{{readonly}}" ?disabled="{{effectiveAriaDisabled}}" name="{{name}}" data-sap-no-tab-ref/>
</div>
Expand Down
2 changes: 2 additions & 0 deletions packages/main/src/RadioButton.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ let activeRadio: RadioButton;
* @constructor
* @extends UI5Element
* @public
* @csspart outer-ring - Used to style the outer ring of the <code>ui5-radio-button</code>.
* @csspart inner-ring - Used to style the inner ring of the <code>ui5-radio-button</code>.
*/
@customElement({
tag: "ui5-radio-button",
Expand Down

0 comments on commit 02571fe

Please sign in to comment.