Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-figma

Package Overview
Dependencies
Maintainers
2
Versions
113
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-figma - npm Package Compare versions

Comparing version 0.1.13 to 0.1.14

2

package.json
{
"name": "react-figma",
"version": "0.1.13",
"version": "0.1.14",
"description": "Render React components to Figma",

@@ -5,0 +5,0 @@ "scripts": {

@@ -55,2 +55,6 @@ "use strict";

var serializers_1 = require("./serializers");
var isReactFigmaExperimental = process.env.REACT_FIGMA_EXPERIMENTAL;
if (isReactFigmaExperimental) {
console.log('REACT_FIGMA_EXPERIMENTAL');
}
var setTextInstance = function (parentNode, childNode) {

@@ -57,0 +61,0 @@ childNode.parent = parentNode;

@@ -15,3 +15,2 @@ "use strict";

var safeGetPluginData_1 = require("../helpers/safeGetPluginData");
var isReactFigmaExperimental = process.env.REACT_FIGMA_EXPERIMENTAL;
var textNodePropsAssign = propsAssign_1.propsAssign([

@@ -70,16 +69,11 @@ 'characters',

}
if (isReactFigmaExperimental) {
var oldCharacters = textNode.characters;
var oldFontSize = textNode.fontSize;
textNodePropsAssign(textNode)(props);
if (oldCharacters !== textNode.characters || oldFontSize !== textNode.fontSize) {
var reactId = safeGetPluginData_1.safeGetPluginData('reactId')(textNode);
if (reactId) {
rpc_1.uiApi.updateYogaNode(reactId);
}
var oldCharacters = textNode.characters;
var oldFontSize = textNode.fontSize;
textNodePropsAssign(textNode)(props);
if (oldCharacters !== textNode.characters || oldFontSize !== textNode.fontSize) {
var reactId = safeGetPluginData_1.safeGetPluginData('reactId')(textNode);
if (reactId) {
rpc_1.uiApi.updateYogaNode(reactId);
}
}
else {
textNodePropsAssign(textNode)(props);
}
}

@@ -86,0 +80,0 @@ return textNode;

@@ -29,9 +29,5 @@ "use strict";

};
var isReactFigmaExperimental = process.env.REACT_FIGMA_EXPERIMENTAL;
if (isReactFigmaExperimental) {
console.log('REACT_FIGMA_EXPERIMENTAL');
rpc_1.$updateYogaReactId
.pipe(operators_1.map(function (reactId) { return ({ reactId: reactId }); }), operators_1.tap(function (val) { return console.log('$updateYogaReactId', val); }))
.subscribe($yogaRoot);
}
rpc_1.$updateYogaReactId
.pipe(operators_1.map(function (reactId) { return ({ reactId: reactId }); }), operators_1.tap(function (val) { return console.log('$updateYogaReactId', val); }))
.subscribe($yogaRoot);
$yogaRoot

@@ -38,0 +34,0 @@ .pipe(operators_1.delay(0), operators_1.exhaustMap(function (instance) {

Sorry, the diff of this file is not supported yet

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