☰Read-only archive⌕
Looking for help with Bokeh?

This is a read-only archive. Ask questions and join the conversation on GitHub.

Visit Community Support on GitHub →
Archived discussions · Captured October 28, 2026

How to change font color in Sliders and TextInput titles?

Community Support
Bryan
Bryan

You are going to have to add custom CSS stylesheets to your page, and for that you will need to use a template. Since you seem to be generating standalone output, you can use json_items or components to embed your Bokeh content in a simple page that has the extra CSS stylesheets at the top. You can use your browser to inspect the page elements to know what CSS selectors to style, or potentially you can set css_classes and add selectors that style based on those classes that you add.

⌁   Link to post
Shin_Huang
Shin_Huang

Yes, I’m generating a standalone output. Is there a better option to it? I tried using css_classes in my python code, this is the code I added:

template = “”"
{% block postamble %}

.bk.custom { color: #FFFFFF; background: #FFFFFF; }

{% endblock %}
“”"

I also added this code to the Sliders and TextInputs widgets:

css_classes = [“custom”]

Can you point to where I’m making an error?

Thanks!

⌁   Link to post

End of archived discussion · Replies are disabled