How to place switch icon after label (left aligned)

Hi,

When I place some switches with icons in a row, it is difficult to see, to which label the icon belongs.
Looking at the following picture, it looks like the green open door belongs to door2.

Screenshot-switch-icon

How can I place the icon near to the label ?

thanks
Thomas

.nrdb-switch {
    justify-content: flex-start;
    gap: 1rem; /*gap between label and icon*/
}
.nrdb-switch label {
    flex-grow:0;
}
1 Like

Hi,

thanks, got it working if I make

.my_switch_class_iconleft .nrdb-switch {
    justify-content: flex-start;
    gap: 1rem; /*gap between label and icon*/
}
.my_switch_class_iconleft .nrdb-switch label {
    flex-grow:0;
}

and assign this class to the class property of the switch :thinking:

looks much better :slightly_smiling_face:

Screenshot-switch-icon-left

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.