Socket
Socket
Sign inDemoInstall

stylecow-plugin-msfilter-background-alpha

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

stylecow-plugin-msfilter-background-alpha - npm Package Compare versions

Comparing version 4.0.1 to 4.0.2

11

index.js

@@ -1,2 +0,2 @@

var color = require('stylecow-color');
var Color = require('color');

@@ -20,9 +20,10 @@ module.exports = function (stylecow) {

if (fn) {
var rgba = color.toRGBA(fn);
var color = Color(fn.toString());
var hex = color.hexString();
if (rgba[3] === 1) {
return fn.replaceWith(stylecow.parse('#' + color.RGBA_HEX(rgba), 'Hex'));
if (color.alpha() == 1) {
return fn.replaceWith(stylecow.parse(hex, 'Hex'));
}
var hex = '#' + Math.round(255 * rgba[3]).toString(16) + color.RGBA_HEX(rgba);
hex = hex.replace('#', '#' + Math.round(255 * color.alpha()).toString(16));

@@ -29,0 +30,0 @@ stylecow.utils.addMsFilter(declaration.getParent('Block'), 'progid:DXImageTransform.Microsoft.gradient(startColorStr="' + hex + '", endColorStr="' + hex + '")');

{
"name": "stylecow-plugin-msfilter-background-alpha",
"description": "Stylecow plugin to add ms filters emulating the rgba/hsla colors in backgrounds in explorer < 9 using ms filters.",
"version": "4.0.1",
"author": "Oscar Otero <oom@oscarotero.com>",
"homepage": "https://github.com/stylecow/stylecow-plugin-msfilter-background-alpha",
"bugs": "https://github.com/stylecow/stylecow-plugin-msfilter-background-alpha/issues",
"repository": {
"type": "git",
"url": "https://github.com/stylecow/stylecow-plugin-msfilter-background-alpha.git"
},
"main": "index.js",
"dependencies": {
"stylecow-color": "2.*"
},
"devDependencies": {
"stylecow": "6.*"
},
"scripts": {
"test": "mocha tests/cases.js"
},
"license": "MIT"
"name": "stylecow-plugin-msfilter-background-alpha",
"description": "Stylecow plugin to add ms filters emulating the rgba/hsla colors in backgrounds in explorer < 9 using ms filters.",
"version": "4.0.2",
"author": "Oscar Otero <oom@oscarotero.com>",
"homepage": "https://github.com/stylecow/stylecow-plugin-msfilter-background-alpha",
"bugs": "https://github.com/stylecow/stylecow-plugin-msfilter-background-alpha/issues",
"repository": {
"type": "git",
"url": "https://github.com/stylecow/stylecow-plugin-msfilter-background-alpha.git"
},
"main": "index.js",
"dependencies": {
"color": "^0.8.0"
},
"devDependencies": {
"stylecow": "6.*"
},
"scripts": {
"test": "mocha tests/cases.js"
},
"license": "MIT"
}

@@ -225,4 +225,10 @@ {

{
"class": "Number",
"name": 50
"class": "Unit",
"name": "%",
"children": [
{
"class": "Number",
"name": 50
}
]
}

@@ -235,4 +241,10 @@ ]

{
"class": "Number",
"name": 50
"class": "Unit",
"name": "%",
"children": [
{
"class": "Number",
"name": 50
}
]
}

@@ -239,0 +251,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