Add "tabtextcolor" attribute to tabs

  1. Henr K

    Member

    { #1 — 1 year ago }

    Please add an attribute to the tabs depending on which color the tab text has, like this:
    tabtextcolor=default (when the "Reverse the text color on the tabs" option is disabled)
    tabtextcolor=white (when the "Reverse the text color on the tabs" option is enabled, and the text is white)
    tabtextcolor=black (when the "Reverse the text color on the tabs" option is enabled, and the text is black)

    Many times I've felt that I would have need for this, when developing userstyles, to make it look good on all tabs, no matter what color. Most of the time, one thing looks good on the tabs with white text color, bad bad on those with black. I think there might be many possibilities on what you can do, after this little, simple, kind of "no change at all", feature has been created - new styles for the already amazing add-on ColorfulTabs (Plus), improved compatibility with other add-ons..
    I'm no programmer, but it feels like it would be easy to implement: If you could make the tabs white on a certain occasion, then you could also do something else, like adding an attribute, at the same time, can't you? And there's no UI change, no further localization needed, no new feature that might annoy people...

  2. uptymizar

    Member

    { #2 — 1 year ago }

    You may not modify, adapt or change this software?! ?? O-o, sorry - ok.

  3. Henr K

    Member

    { #3 — 1 year ago }

    Since I learned about CSS3 selectors, I found out that this already exist:

    Selector for tabs with white label:
    .tabbrowser-tab[style*="color: rgb(255, 255, 255)"]:not([style*="background-color: rgb(255, 255, 255)"])

    Selector for tabs with black label:
    .tabbrowser-tab[style*="color: rgb(0, 0, 0)"]:not([style*="background-color: rgb(0, 0, 0)"])

    @uptymizar
    Don't worry, I'm not modifying, adapting or changing this software - I'm just restyling the tabs dependent on ColorfulTabs! And I meant that for example theme developers could optimize their themes for ColorfulTabs.

Reply

You must log in to post.