Theme-ui: Theme color for caretColor on input element not resolved properly

Created on 17 Mar 2020  路  2Comments  路  Source: system-ui/theme-ui

Describe the bug
Setting the caretColor prop on an input element to a color defined in theme.colors renders broken CSS.

To Reproduce
Steps to reproduce the behavior:

  1. Define some color in your theme, for example accent: "#FF0000".
  2. Set the caretColor prop to "accent" on an input:
    <input sx={{ caretColor: "accent" }}>...</input>
  3. Rendered CSS will be caret-color: accent.

Expected behavior
Expected rendered CSS to be caret-color: #FF0000.

Most helpful comment

This property is not currently mapped to the theme.colors scale -- in the meantime, you can use functional values

All 2 comments

This property is not currently mapped to the theme.colors scale -- in the meantime, you can use functional values

https://github.com/system-ui/theme-ui/pull/780 will close this issue :)

Was this page helpful?
0 / 5 - 0 ratings