Question
Swedbank AB
LT
Last activity: 26 Mar 2020 7:46 EDT
Radio button - format of label of selected item
Hello,
Is there a way to change the format of the label of the selected item in a Radio Button control? E.g. to have the label of the selected item in bold.
***Edited by Moderator Marissa to update Platform Capability tags****
-
Like (0)
-
Share this page Facebook Twitter LinkedIn Email Copying... Copied!
Accepted Solution
Swedbank AB
LT
I solved my issue by adding the necessary CSS style to a text file included into the "Additional style sheets" section in the "Included styles" tab on the skin rule. In order to apply the style only to specific Radio button controls rather than all Radio button controls in the application, I used an identifier in the CSS text file (e.g. ".RadioButtonSelected") which I would include into the Cell properties of the specific Radio button controls ("Presentation" tab, "Advanced Presentation Options" section, "Cell read-write classes" and "Cell read-only classes" fields) which I want to behave accordingly.
The CSS code I used was:
.RadioButtonSelected input[type=radio]:checked + label{ font-weight: bold; }
Hopefully someone finds this useful as well.
Pegasystems Inc.
FR
Hello,
Have a look to the UI Gallery:
-
SORNALATHA R
Swedbank AB
LT
Thank you for your answer. I took a look at the Gallery in Pega 8.1 and could not find anything useful. There are only three basic examples and nothing related to my question. Maybe I missed something?
Pegasystems Inc.
FR
oh only the selected one. I guess you might need an OnChange event to change the associated format within the CSS
Pegasystems Inc.
IN
Configure a On Change-Run Script event action on the radio button. In the script include the necessary CSS styles.
Accepted Solution
Swedbank AB
LT
I solved my issue by adding the necessary CSS style to a text file included into the "Additional style sheets" section in the "Included styles" tab on the skin rule. In order to apply the style only to specific Radio button controls rather than all Radio button controls in the application, I used an identifier in the CSS text file (e.g. ".RadioButtonSelected") which I would include into the Cell properties of the specific Radio button controls ("Presentation" tab, "Advanced Presentation Options" section, "Cell read-write classes" and "Cell read-only classes" fields) which I want to behave accordingly.
The CSS code I used was:
.RadioButtonSelected input[type=radio]:checked + label{ font-weight: bold; }
Hopefully someone finds this useful as well.
-
Prakash Babu Thote
Hexaware Technologies Ltd
IN
Hi,
I need some clarification from the above solution.
We will include the CSS code in the selected radio button in the presentation tab. Then we don't want to create any style from the skin level? Could you please explain about .RadioButtonSelected
If possible kindly explain elaborately.
Thanks,
Sornalatha R