Skip to content

Tab indicator color #4202

Closed Answered by falkoschindler
chupins asked this question in Q&A
Jan 10, 2025 · 1 comments · 3 replies
Discussion options

You must be logged in to vote

You can set different tab colors which, however, changes the text color as well:

with ui.tabs() as tabs:
    one = ui.tab('One').classes('text-blue')
    two = ui.tab('Two').classes('text-red')

We can enforce a common text color with some custom CSS:

ui.add_css('''
    .my-tabs .q-tab__label {
        color: black !important;
    }
''')

with ui.tabs().classes('my-tabs') as tabs:
    one = ui.tab('One').classes('text-blue')
    two = ui.tab('Two').classes('text-red')

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@chupins
Comment options

@falkoschindler
Comment options

Answer selected by chupins
@chupins
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants