Skip to content

Add preferred-color-scheme: light support#23

Merged
ai merged 4 commits intopostcss:mainfrom
NataliaNagaeva:add-light-color-scheme-support
Aug 17, 2023
Merged

Add preferred-color-scheme: light support#23
ai merged 4 commits intopostcss:mainfrom
NataliaNagaeva:add-light-color-scheme-support

Conversation

@NataliaNagaeva
Copy link
Contributor

Added preferred-color-scheme: light support
#7

README.md Outdated
}
}

@media (prefers-color-scheme: light) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let’s keep example simple.

But we can mentioned somewhere that we support both light and dark schemes.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are right, it looks redundant. I think the phrase plugin to make switcher to force dark or light theme by copying styles from media query to special class has already described that.

Removed the example for the light scheme.

:root,
a { }
}
@media (prefers-color-scheme:light) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add the light tests to a separated test (maybe one extra test for both cases together)?

Our tests already too long, it will simplify tests.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Separated tests for the light scheme to individual tests and added one extra test for both schemes.

@ai
Copy link
Member

ai commented Aug 15, 2023

A few small fixes for docs and tests, and we are ready to merge. The plugin changes looks good. I already mark task on Cult of Martians as solved by you.

Do you have a twitter account to mentioned you?

@NataliaNagaeva
Copy link
Contributor Author

mentione

Yes, I have. I use it for reading only but you can certainly mention me if you want :) @astashkinana

@ai ai merged commit 71927bc into postcss:main Aug 17, 2023
@ai
Copy link
Member

ai commented Aug 17, 2023

Thanks. This feature was released at 1.0.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants