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

html2figma

Package Overview
Dependencies
Maintainers
2
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

html2figma - npm Package Compare versions

Comparing version 0.0.11 to 0.0.12

2

lib/node2Frame.js

@@ -160,3 +160,3 @@ import { __assign, __awaiter, __generator } from "tslib";

childrenLayers.forEach(function (layer) { return layers.push(layer); });
frame = __assign(__assign({ type: 'FRAME', clipsContent: overflowHidden, x: rect.left - parentRect.left, y: rect.top - parentRect.top, width: rect.width, height: rect.height, expanded: false, fills: fills, children: [], effects: shadowEffects }, strokes), borderRadii);
frame = __assign(__assign({ type: 'FRAME', clipsContent: overflowHidden, x: rect.left - parentRect.left, y: rect.top - parentRect.top, width: rect.width, height: rect.height, fills: fills, children: [], effects: shadowEffects }, strokes), borderRadii);
frame.children = layers;

@@ -163,0 +163,0 @@ return [2 /*return*/, frame];

@@ -53,3 +53,2 @@ import { __awaiter, __generator } from "tslib";

height: rect.height,
expanded: false,
fills: fills,

@@ -56,0 +55,0 @@ children: []

@@ -20,2 +20,4 @@ export var processSvgUseElements = function (el) {

var parentRect = parentNode.getBoundingClientRect();
console.log('图标测试: 获取节点后的宽高', rect.width, rect.height);
console.log('图标测试: 获取节点后的svg', node.outerHTML);
// TODO: pull in CSS/computed styles

@@ -22,0 +24,0 @@ // TODO: may need to pull in layer styles too like shadow, bg color, etc

@@ -102,2 +102,3 @@ import { __awaiter, __generator } from "tslib";

if (!(layer.type === 'SVG')) return [3 /*break*/, 2];
console.log('图标测试: 生成图标前的数据: layer', layer.width, layer.height, layer.svg);
node = figma.createNodeFromSvg(layer.svg);

@@ -107,2 +108,3 @@ node.x = layer.x;

node.resize(Math.round(layer.width) || 1, layer.height || 1);
console.log('图标测试: figma生成后的数据:', node);
layer.ref = node;

@@ -109,0 +111,0 @@ rects.push(node);

{
"name": "html2figma",
"version": "0.0.11",
"version": "0.0.12",
"description": "convert HTML to figma Layers",

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

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

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