Remove list styles in CSS without preventing VoiceOver from announcing them in Safari
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src
test
.editorconfig
.gitignore 1.0.0 Jan 11, 2019
.rollup.js
.tape.js
.travis.yml
CHANGELOG.md
CONTRIBUTING.md
INSTALL.md 1.0.0 Jan 11, 2019
LICENSE.md
README.md
package.json

README.md

PostCSS List Style Safari Fix PostCSS

NPM Version Build Status Support Chat

PostCSS List Style Safari Fix lets you remove list styles in CSS without preventing VoiceOver from announcing them in Safari.

nav ol, nav ul {
  list-style: none;
}

/* becomes */

nav ol, nav ul {
  list-style: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg'/%3E");
}

For more information about this Safari / VoiceOver bug, read VoiceOver and list-style-type: none.

Usage

Add PostCSS List Style Safari Fix to your project:

npm install postcss-list-style-safari-fix --save-dev

Use PostCSS List Style Safari Fix to process your CSS:

const postcssListStyleSafariFix = require('postcss-list-style-safari-fix');

postcssListStyleSafariFix.process(YOUR_CSS /*, processOptions, pluginOptions */);

Or use it as a PostCSS plugin:

const postcss = require('postcss');
const postcssListStyleSafariFix = require('postcss-list-style-safari-fix');

postcss([
  postcssListStyleSafariFix(/* pluginOptions */)
]).process(YOUR_CSS /*, processOptions */);

PostCSS List Style Safari Fix runs in all Node environments, with special instructions for:

Node PostCSS CLI Webpack Create React App Gulp Grunt