Socket
Socket
Sign inDemoInstall

framework-utils

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

framework-utils - npm Package Compare versions

Comparing version 0.3.3 to 0.3.4

6

dist/utils.cjs.js

@@ -7,3 +7,3 @@ /*

repository: git+https://github.com/daybrush/framework-utils.git
version: 0.3.3
version: 0.3.4
*/

@@ -26,3 +26,5 @@ 'use strict';

function prefixCSS(prefix, css) {
return css.replace(/\.([^{,\s\d.]+)/g, "." + prefix + "$1");
return css.replace(/([^}{]*){/mg, function (_, selector) {
return selector.replace(/\.([^{,\s\d.]+)/g, "." + prefix + "$1") + "{";
});
}

@@ -29,0 +31,0 @@ /* react */

@@ -7,3 +7,3 @@ /*

repository: git+https://github.com/daybrush/framework-utils.git
version: 0.3.3
version: 0.3.4
*/

@@ -24,3 +24,5 @@ function prefixNames(prefix) {

function prefixCSS(prefix, css) {
return css.replace(/\.([^{,\s\d.]+)/g, "." + prefix + "$1");
return css.replace(/([^}{]*){/mg, function (_, selector) {
return selector.replace(/\.([^{,\s\d.]+)/g, "." + prefix + "$1") + "{";
});
}

@@ -27,0 +29,0 @@ /* react */

{
"name": "framework-utils",
"version": "0.3.3",
"version": "0.3.4",
"description": "utils for framework",

@@ -5,0 +5,0 @@ "main": "./dist/utils.cjs.js",

@@ -8,3 +8,5 @@ export function prefixNames(prefix: string, ...classNames: string[]) {

export function prefixCSS(prefix: string, css: string) {
return css.replace(/\.([^{,\s\d.]+)/g, `.${prefix}$1`);
return css.replace(/([^}{]*){/mg, (_, selector) => {
return `${selector.replace(/\.([^{,\s\d.]+)/g, `.${prefix}$1`)}{`;
});
}

@@ -11,0 +13,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