Skip to Main Content
Feature Request FR-3944
Product Area User Interface
Status ROADMAP

5 Voters

Add --a-treeview-toggle-selected-text-color CSS variable for Tree regions

jack drolet Public
· Aug 1 2024

Idea Summary

The tree region uses several CSS variables to style the rows in the tree. There are specific variables for selected and not selected text color for the icon and the text but the toggle does not use a unique variable to set its selected text color.

For example, the following variables are used to style a tree region:

  • --a-treeview-node-text-color
  • --a-treeview-node-selected-text-color
  • --a-treeview-node-icon-color
  • --a-treeview-node-selected-icon-color
  • --a-treeview-toggle-text-color

When a row is selected, the toggle gets its color from --a-treeview-node-selected-text-color instead of having its own CSS variable like it does when it is not selected (--a-treeview-toggle-text-color) making it so its harder to have the toggle be a different color than the text when the row is selected.

Use Case
This would be useful when styling a tree and you need the toggle to be a different color than the label text.

Preferred Solution
A CSS variable called --a-treeview-toggle-selected-text-color should be used to set the toggle text color when the row is selected such that it can easily be overridden in order to style the region.

This is planned for a future APEX release.