Skip to content

Search icon doesn't change color between light/dark mode #287

@tuckergordon

Description

@tuckergordon

The search icon as defined in --ifm-navbar-search-input-icon is uses currentColor:

--ifm-navbar-search-input-icon: url('data:image/svg+xml;utf8,<svg fill="currentColor" ...

However, this does not have the intended effect because currentColor does not get applied on images rendered using url(). This results in the search icon not changing color when switching between light/dark theme (and makes it hard to customize the color more generally).

Perhaps a more flexible approach would be to use an actual SVG in the element, similar to how Docusarus has implemented it on their website:
image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions