Socket
Socket
Sign inDemoInstall

babel-plugin-emotion

Package Overview
Dependencies
Maintainers
2
Versions
90
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

babel-plugin-emotion - npm Package Compare versions

Comparing version 10.0.13 to 10.0.14

6

CHANGELOG.md
# babel-plugin-emotion
## 10.0.14
### Patch Changes
- [c0eb604d](https://github.com/emotion-js/emotion/commit/c0eb604d) [#1419](https://github.com/emotion-js/emotion/pulls/1419) Thanks [@mitchellhamilton](https://github.com/mitchellhamilton)! - Update build tool
## 10.0.13

@@ -4,0 +10,0 @@

40

dist/babel-plugin-emotion.cjs.dev.js
'use strict';
Object.defineProperty(exports, '__esModule', {
value: true
});
Object.defineProperty(exports, '__esModule', { value: true });
function _interopDefault(ex) {
return ex && typeof ex === 'object' && 'default' in ex ? ex['default'] : ex;
}
function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
var nodePath = _interopDefault(require('path'));
var sourceMap = require('source-map');
var convert = _interopDefault(require('convert-source-map'));
var findRoot = _interopDefault(require('find-root'));
var memoize = _interopDefault(require('@emotion/memoize'));
var hashString = _interopDefault(require('@emotion/hash'));
var escapeRegexp = _interopDefault(require('escape-string-regexp'));
var serialize = require('@emotion/serialize');
var helperModuleImports = require('@babel/helper-module-imports');
var babelPluginMacros = require('babel-plugin-macros');
var babelPluginMacros = require('babel-plugin-macros'); // babel-plugin-styled-components
// babel-plugin-styled-components
// https://github.com/styled-components/babel-plugin-styled-components/blob/8d44acc36f067d60d4e09f9c22ff89695bc332d2/src/minify/index.js
var multilineCommentRegex = /\/\*[^!](.|[\r\n])*?\*\//g;

@@ -69,3 +56,2 @@ var lineCommentStart = /\/\//g;

};
var compressSymbols = function compressSymbols(code) {

@@ -87,3 +73,2 @@ return code.split(symbolRegex).reduce(function (str, fragment, index) {

var isLineComment = function isLineComment(line) {

@@ -94,3 +79,2 @@ return line.trim().startsWith('//');

var linebreakRegex = /[\r\n]\s*/g;
var minify = function minify(code) {

@@ -211,3 +195,2 @@ var newCode = code.replace(multilineCommentRegex, '\n') // Remove multiline comments

}
var pascalCaseRegex = /^[A-Z][A-Za-z]+/;

@@ -288,3 +271,3 @@

var declaratorName = getDeclaratorName(path, t); // if the name starts with _ it was probably generated by babel so we should ignore it
var declaratorName = getDeclaratorName(path); // if the name starts with _ it was probably generated by babel so we should ignore it

@@ -312,3 +295,2 @@ if (declaratorName.charAt(0) === '_') {

}
function getSourceMap(offset, state) {

@@ -377,6 +359,7 @@ var generator = makeSourceMapGenerator(state.file);

return stableClassName;
} // it's meant to simplify the most common cases so i don't want to make it especially complex
}
// it's meant to simplify the most common cases so i don't want to make it especially complex
// also, this will be unnecessary when prepack is ready
function simplifyObject(node, t) {

@@ -431,3 +414,2 @@ var finalString = '';

};
var joinStringLiterals = function joinStringLiterals(expressions, t) {

@@ -541,3 +523,3 @@ return expressions.reduce(function (finalExpressions, currentExpression, i) {

var getStyledOptions = function getStyledOptions(t, path, state) {
var properties = [t.objectProperty(t.identifier('target'), t.stringLiteral(getTargetClassName(state, t)))];
var properties = [t.objectProperty(t.identifier('target'), t.stringLiteral(getTargetClassName(state)))];
var label = getLabelFromPath(path, state, t);

@@ -755,3 +737,2 @@

};
var cssMacro = babelPluginMacros.createMacro(function (_ref2) {

@@ -797,2 +778,3 @@ var references = _ref2.references,

});
var webStyledMacro = createStyledMacro({

@@ -857,3 +839,3 @@ importPath: '@emotion/styled-base',

function index(babel) {
function index (babel) {
var t = babel.types;

@@ -860,0 +842,0 @@ return {

@@ -119,3 +119,3 @@ "use strict";

}
var declaratorName = getDeclaratorName(path, t);
var declaratorName = getDeclaratorName(path);
return "_" === declaratorName.charAt(0) ? "" : declaratorName;

@@ -245,3 +245,3 @@ }

}, getStyledOptions = function(t, path, state) {
var properties = [ t.objectProperty(t.identifier("target"), t.stringLiteral(getTargetClassName(state, t))) ], label = getLabelFromPath(path, state, t);
var properties = [ t.objectProperty(t.identifier("target"), t.stringLiteral(getTargetClassName(state))) ], label = getLabelFromPath(path, state, t);
label && properties.push(t.objectProperty(t.identifier("label"), t.stringLiteral(label)));

@@ -248,0 +248,0 @@ var args = path.node.arguments, optionsArgument = args.length >= 2 ? args[1] : null;

{
"name": "babel-plugin-emotion",
"version": "10.0.13",
"version": "10.0.14",
"description": "A recommended babel preprocessing plugin for emotion, The Next Generation of CSS-in-JS.",

@@ -13,5 +13,5 @@ "main": "dist/babel-plugin-emotion.cjs.js",

"@babel/helper-module-imports": "^7.0.0",
"@emotion/hash": "0.7.1",
"@emotion/memoize": "0.7.1",
"@emotion/serialize": "^0.11.6",
"@emotion/hash": "0.7.2",
"@emotion/memoize": "0.7.2",
"@emotion/serialize": "^0.11.8",
"babel-plugin-macros": "^2.0.0",

@@ -18,0 +18,0 @@ "babel-plugin-syntax-jsx": "^6.18.0",

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