Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

css-prefers-color-scheme

Package Overview
Dependencies
Maintainers
0
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

css-prefers-color-scheme - npm Package Compare versions

Comparing version 9.0.1 to 10.0.0

18

CHANGELOG.md
# Changes to Prefers Color Scheme
### 9.0.1
### 10.0.0
_December 15, 2023_
_August 3, 2024_
- Fix type definitions
- Updated: Support for Node v18+ (major).
### 9.0.0
_July 3, 2023_
- Change license to `MIT-0` ([read more about this change in the blog post](https://preset-env.cssdb.org/blog/license-change/))
### 8.0.2
_February 6, 2023_
- Reduce the amount of duplicate fallback CSS.
[Full CHANGELOG](https://github.com/csstools/postcss-plugins/tree/main/plugins/css-prefers-color-scheme/CHANGELOG.md)

7

package.json
{
"name": "css-prefers-color-scheme",
"description": "Use light and dark color schemes in all browsers",
"version": "9.0.1",
"version": "10.0.0",
"contributors": [

@@ -32,3 +32,3 @@ {

"engines": {
"node": "^14 || ^16 || >=18"
"node": ">=18"
},

@@ -66,6 +66,7 @@ "type": "module",

},
"scripts": {},
"homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/css-prefers-color-scheme#readme",
"repository": {
"type": "git",
"url": "https://github.com/csstools/postcss-plugins.git",
"url": "git+https://github.com/csstools/postcss-plugins.git",
"directory": "plugins/css-prefers-color-scheme"

@@ -72,0 +73,0 @@ },

# Prefers Color Scheme [<img src="https://postcss.github.io/postcss/logo.svg" alt="PostCSS Logo" width="90" height="90" align="right">][PostCSS]
[<img alt="npm version" src="https://img.shields.io/npm/v/css-prefers-color-scheme.svg" height="20">][npm-url] [<img alt="CSS Standard Status" src="https://cssdb.org/images/badges/prefers-color-scheme-query.svg" height="20">][css-url] [<img alt="Build Status" src="https://github.com/csstools/postcss-plugins/workflows/test/badge.svg" height="20">][cli-url] [<img alt="Discord" src="https://shields.io/badge/Discord-5865F2?logo=discord&logoColor=white">][discord]
`npm install css-prefers-color-scheme --save-dev`
```bash
npm install css-prefers-color-scheme --save-dev
```
[Prefers Color Scheme] lets you use light and dark color schemes in all browsers, following the [Media Queries] specification.

@@ -80,12 +76,3 @@

[Prefers Color Scheme] runs in all Node environments, with special
instructions for:
- [Node](INSTALL.md#node)
- [PostCSS CLI](INSTALL.md#postcss-cli)
- [PostCSS Load Config](INSTALL.md#postcss-load-config)
- [Webpack](INSTALL.md#webpack)
- [Next.js](INSTALL.md#nextjs)
- [Gulp](INSTALL.md#gulp)
- [Grunt](INSTALL.md#grunt)

@@ -150,3 +137,3 @@ ## Options

<!-- When using a CDN url you will have to manually update the version number -->
<script src="https://unpkg.com/css-prefers-color-scheme@9.0.1/dist/browser-global.js"></script>
<script src="https://unpkg.com/css-prefers-color-scheme@10.0.0/dist/browser-global.js"></script>
<script>prefersColorSchemeInit()</script>

@@ -156,3 +143,3 @@ ```

> [!TIP]
> Please use a versioned url, like this : `https://unpkg.com/css-prefers-color-scheme@9.0.1/dist/browser-global.js`
> Please use a versioned url, like this : `https://unpkg.com/css-prefers-color-scheme@10.0.0/dist/browser-global.js`
> Without the version, you might unexpectedly get a new major version of the library with breaking changes.

@@ -231,3 +218,3 @@

```html
<script src="https://unpkg.com/css-prefers-color-scheme@9.0.1/dist/browser-global.js"></script>
<script src="https://unpkg.com/css-prefers-color-scheme@10.0.0/dist/browser-global.js"></script>
<script>prefersColorSchemeInit('light', { debug: true })</script>

@@ -234,0 +221,0 @@ ```

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc