Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reduce repeated code in secondary theme colours #6505

Draft
wants to merge 1 commit into
base: development
Choose a base branch
from

Conversation

absidue
Copy link
Member

@absidue absidue commented Jan 3, 2025

Reduce repeated code in secondary theme colours

Pull Request Type

  • Other

Related issue

Description

For each secondary theme colour we specify 5 variables --accent-color and --accent-color-opacity{1,2,3,4}, where the opacity ones are just the --accent-color with various levels of opacity. At the moment that is done in the classes of the secondary theme colours. This pull request instead specifies just a single variable --accent-color-rgb in each class and then uses that in the body rule to construct the 5 variables with rgb().

This reduces the amount of work for people adding new themes and also shaves about 10kb (10333 bytes) off the output CSS file compared to the development branch.

Testing

Test a few theme colours to check they still work and that the Hot Pink theme is still able to override them.

Desktop

  • OS: Windows
  • OS Version: 10
  • FreeTube version: 1c3728e

Copy link
Contributor

This PR is stale because it has been open 14 days with no activity. Remove stale label or comment or this will be closed in 14 days.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants