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

css-blank-pseudo

Package Overview
Dependencies
Maintainers
3
Versions
22
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

css-blank-pseudo - npm Package Compare versions

Comparing version 6.0.0 to 6.0.1

181

CHANGELOG.md
# Changes to CSS Blank Pseudo
### 6.0.1
_December 15, 2023_
- Fix type definitions
### 6.0.0

@@ -15,175 +21,2 @@

### 5.0.1
_January 28, 2023_
- Improve `types` declaration in `package.json`
### 5.0.0
_January 24, 2023_
- Updated: Support for Node v14+ (major).
- Fix: Do not throw when a selector is invalid, show a warning instead.
- Updated: Export and document the plugin options types.
### 4.1.1
_August 23, 2022_
- Fix: assign global browser polyfill to `window`, `self` or a blank object.
### 4.1.0
_July 30, 2022_
- Added: `disablePolyfillReadyClass` plugin option to prevent `.js-blank-pseudo` from being added.
### 4.0.0
_July 8, 2022_
- Updated: The polyfill now only attaches a single listener to the body so it's
more efficient and also does less work at the MutationObserver handler.
- Breaking: removed old CDN urls
- Breaking: removed old CLI
- Fix case insensitive matching.
#### How to migrate:
- If you use a CDN url, please update it.
- Re-build your CSS with the new version of the library.
```diff
- <script src="https://unpkg.com/css-blank-pseudo/browser"></script>
- <script src="https://unpkg.com/css-blank-pseudo/browser.min"></script>
+ <script src="https://unpkg.com/css-blank-pseudo/dist/browser-global.js"></script>
```
```diff
- cssBlankPseudo(document)
+ cssBlankPseudoInit()
```
```diff
- cssBlankPseudo({
- attr: false,
- className: 'blank'
- })
+ cssBlankPseudoInit({
+ replaceWith: '.blank'
+ })
```
### 3.0.3
_February 5, 2022_
- Rebuild of browser polyfills
### 3.0.2
_January 2, 2022_
- Removed Sourcemaps from package tarball.
- Moved CLI to CLI Package. See [announcement](https://github.com/csstools/postcss-plugins/discussions/121).
### 3.0.1
_December 27, 2021_
- Fixed: require/import paths for browser script
### 3.0.0
_December 13, 2021_
- Breaking: require/import paths have changed
- Changed: new polyfill CDN urls.
- Changed: Supports Node 12+ (major).
- Updated: documentation
**Migrating to 3.0.0**
PostCSS plugin :
```diff
- const postcssBlankPseudo = require('css-blank-pseudo/postcss');
+ const postcssBlankPseudo = require('css-blank-pseudo');
```
Browser Polyfill :
```diff
- const cssBlankPseudo = require('css-blank-pseudo');
+ const cssBlankPseudo = require('css-blank-pseudo/browser');
```
_The old CND url is now deprecated and will be removed in a next major release._
_It will continue to work for now._
```diff
- <script src="https://unpkg.com/css-blank-pseudo/browser"></script>
+ <script src="https://unpkg.com/css-blank-pseudo/dist/browser-global.js"></script>
```
Browser Polyfill IE :
_The polyfill for IE is now the same as the general polyfill_
```diff
- const cssBlankPseudo = require('css-blank-pseudo');
+ const cssBlankPseudo = require('css-blank-pseudo/browser');
```
_The old CND url is now deprecated and will be removed in a next major release._
_It will continue to work for now._
```diff
- <script src="https://unpkg.com/css-blank-pseudo/browser-legacy"></script>
+ <script src="https://unpkg.com/css-blank-pseudo/dist/browser-global.js"></script>
```
### 2.0.0
_September 16, 2021_
- Changed: Supports PostCSS 8.3+ (major).
- Changed: Supports Node 10+ (major).
### 1.0.0
_June 10, 2019_
- Updated: `postcss` to 7.0.16 (patch)
- Updated: Node 8+ compatibility (major)
### 0.1.4
_November 17, 2018_
- Update documentation
### 0.1.3
_November 17, 2018_
- Improve CLI usage
### 0.1.2
_November 17, 2018_
- Provide a version specifically for Internet Explorer 11
### 0.1.1
_November 17, 2018_
- Update documentation
### 0.1.0
_November 17, 2018_
- Initial version
[Full CHANGELOG](https://github.com/csstools/postcss-plugins/tree/main/plugins/css-blank-pseudo/CHANGELOG.md)

10

dist/index.d.ts
import type { PluginCreator } from 'postcss';
declare const creator: PluginCreator<pluginOptions>;
export default creator;
/** css-blank-pseudo plugin options */
export type pluginOptions = {
export declare type pluginOptions = {
/** Preserve the original notation. default: true */

@@ -11,3 +15,3 @@ preserve?: boolean;

};
declare const creator: PluginCreator<pluginOptions>;
export default creator;
export { }
{
"name": "css-blank-pseudo",
"description": "Style form elements when they are empty",
"version": "6.0.0",
"version": "6.0.1",
"contributors": [

@@ -34,11 +34,14 @@ {

},
"type": "module",
"main": "dist/index.cjs",
"module": "dist/index.mjs",
"types": "dist/index.d.ts",
"exports": {
".": {
"types": "./dist/index.d.ts",
"import": "./dist/index.mjs",
"require": "./dist/index.cjs",
"default": "./dist/index.mjs"
"import": {
"types": "./dist/index.d.ts",
"default": "./dist/index.mjs"
},
"require": {
"default": "./dist/index.cjs"
}
},

@@ -66,15 +69,2 @@ "./browser": {

},
"devDependencies": {
"@csstools/postcss-tape": "*",
"puppeteer": "^20.7.4"
},
"scripts": {
"build": "rollup -c ../../rollup/default.mjs",
"docs": "node ../../.github/bin/generate-docs/install.mjs && node ../../.github/bin/generate-docs/readme.mjs",
"lint": "node ../../.github/bin/format-package-json.mjs",
"prepublishOnly": "npm run build && npm run test",
"test": "node .tape.mjs && node ./test/_import.mjs && node ./test/_require.cjs && node ./test/_valid-replacements.mjs",
"test:browser": "node ./test/_browser.mjs",
"test:rewrite-expects": "REWRITE_EXPECTS=true node .tape.mjs"
},
"homepage": "https://github.com/csstools/postcss-plugins/tree/main/plugins/css-blank-pseudo#readme",

@@ -103,12 +93,3 @@ "repository": {

"textarea"
],
"csstools": {
"cssdbId": "blank-pseudo-class",
"exportName": "postcssBlankPseudo",
"humanReadableName": "PostCSS Blank Pseudo",
"specUrl": "https://www.w3.org/TR/selectors-4/#blank"
},
"volta": {
"extends": "../../package.json"
}
]
}

@@ -5,2 +5,6 @@ # PostCSS Blank Pseudo [<img src="https://postcss.github.io/postcss/logo.svg" alt="PostCSS Logo" width="90" height="90" align="right">][PostCSS]

```bash
npm install css-blank-pseudo --save-dev
```
[PostCSS Blank Pseudo] lets you style form elements when they are empty, following

@@ -149,3 +153,3 @@ the [Selectors Level 4] specification.

<!-- When using a CDN url you will have to manually update the version number -->
<script src="https://unpkg.com/css-blank-pseudo@6.0.0/dist/browser-global.js"></script>
<script src="https://unpkg.com/css-blank-pseudo@6.0.1/dist/browser-global.js"></script>
<script>cssBlankPseudoInit()</script>

@@ -152,0 +156,0 @@ ```

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