postcss-bgc-rgba-fallback

1.1.1 • Public • Published

PostCSS Bgb Rgba Fallback

NPM Traivs CI Coverage NPM Downloads Greenkeeper badge

PostCSS plugin to polyfill background rgba for IE8

Detail about polyfill for background rgba in IE8

The origin artile Cross browser alpha transparent background CSS (rgba) is removed now. You can see this anwser from stackoverflow.

Installation

$ npm install postcss-bgc-rgba-fallback

Usage

// dependencies
var fs = require('fs')
var postcss = require('postcss')
var bgcRgbaFallback = require('postcss-bgc-rgba-fallback')
 
// css to be processed
var css = fs.readFileSync('input.css', 'utf8')
 
// process css
var output = postcss()
  .use(bgcRgbaFallback())
  .process(css)
  .css
.foo {
  background-color: rgba(255,102,0,0.3);
}
.foo {
  background-color: rgb(255,102,0);
  background-color: transparent\9;
  background-color: rgba(255,102,0,0.3);
  filter: progid:DXImageTransform.Microsoft.gradient(startColorstr=#4cFF6600, endColorstr=#4cFF6600);
  zoom: 1;
}
.foo:nth-child(n) {
  filter: none;
}

JavaScript Style Guide

/postcss-bgc-rgba-fallback/

    Package Sidebar

    Install

    npm i postcss-bgc-rgba-fallback

    Weekly Downloads

    0

    Version

    1.1.1

    License

    MIT

    Unpacked Size

    5.86 kB

    Total Files

    4

    Last publish

    Collaborators

    • vagusx