New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

postcss-object-fit-images

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

postcss-object-fit-images - npm Package Compare versions

Comparing version 1.0.0 to 1.1.0

29

index.js

@@ -27,13 +27,20 @@ 'use strict';

if (!fontFamily && objPosition) {
decl.cloneBefore({
prop: 'font-family',
value: `"object-fit: ${objFit}; object-position: ${objPosition}"`
});
} else if (!fontFamily) {
decl.cloneBefore({
prop: 'font-family',
value: `"object-fit: ${objFit}"`
});
const value = [
'object-fit:' + objFit
];
if (objPosition) {
value.push('object-position:' + objPosition);
}
const props = {
prop: 'font-family',
value: '"' + value.join(';') + '"'
};
// keep existing font-family
if (fontFamily) {
props.value += ', ' + fontFamily;
}
decl.cloneBefore(props);
};

@@ -46,4 +53,4 @@

return function (css) {
css.walkDecls(/(^object-fit$)/, declWalker);
css.walkDecls('object-fit', declWalker);
};
});
{
"name": "postcss-object-fit-images",
"version": "1.0.0",
"version": "1.1.0",
"description": "PostCSS plugin that updates the standard object-fit tag to work with the object-fit-images polyfill for browsers that do not natively support object-fit.",

@@ -5,0 +5,0 @@ "keywords": [

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