How to over-ride default CSS on Slider #1652
Answered
by
theetrain
chipnetics
asked this question in
Q&A
-
Hi there, I am trying to make the text-input field (where user can click and manually enter a value) on a slider wider (https://carbon-components-svelte.onrender.com/components/Slider).... I think it uses |
Beta Was this translation helpful? Give feedback.
Answered by
theetrain
Feb 7, 2023
Replies: 1 comment 1 reply
-
It's possible to override styles via <style>
:global(.bx--text-input.bx--slider-text-input) {
background-color: black;
color: white;
font-weight: 600;
}
</style> Here's a demo: https://svelte.dev/repl/6e1a4e83c2f54e7e838b1081da3f8bf5?version=3.55.1 Once #1629 is complete, it will be possible to target CSS variables to theme Carbon components. |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
chipnetics
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It's possible to override styles via
:global()
and class selectors.Here's a demo: https://svelte.dev/repl/6e1a4e83c2f54e7e838b1081da3f8bf5?version=3.55.1
Once #1629 is complete, it will be possible to target CSS variables to theme Carbon components.