RapiDoc icon indicating copy to clipboard operation
RapiDoc copied to clipboard

[Q] Is there a way to style button elements separately?

Open peterlitvak opened this issue 2 years ago • 0 comments

What would be the correct way (if it is at all possible) to style buttons, e.g., btn and btn-response-status parts as well as the tab-btn classes? If I use css-file and css-classes attributes I cannot get styles to work. If I use shadow dom styling I can kind of style buttons like this:

rapi-doc::part(btn-outline) {
    border-color: #0073E5;
    background-color: #FFFFFF !important;
    color: #000000 !important;
}

rapi-doc::part(btn) {
    border-color: #0073E5;
    background-color: #0073E5;
    color: #FFFFFF;
}

rapi-doc::part(btn-response-status) {
    border-color: #0073E5;
    background-color: #FFFFFF;
    color: #000000;
}

rapi-doc::part(btn-selected-response-status) {
    border-color: #0073E5;
    background-color: #0073E5 !important;
    color: #FFFFFF !important;
}

but cannot style the tab-btn since it is not a part and the :host(.tab-btn) wouldn't work.

peterlitvak avatar Mar 27 '23 19:03 peterlitvak