Changes
5 changed files (+10/-6)
-
-
@@ -26,7 +26,6 @@ "./src/index.ts","./{cjs,esm}/*/index.js" ], "dependencies": { "copy-to-clipboard": "^3.0.0", "lit": "^2.1.3" }, "devDependencies": {
-
-
-
@@ -1,5 +1,4 @@import { css, html } from "lit"; import * as copy from "copy-to-clipboard"; import { HorizontalPaddingIcon,
-
@@ -9,6 +8,10 @@ CopyIcon,} from "../Icons"; import { FigmaNode, getStyleRule, NodeStyles } from "./utils"; import type { CSSRule } from "./utils"; const copy = async (text: string) => { await navigator.clipboard.writeText(text); }; export type InspectorViewProps = { node: FigmaNode;
-
-
-
@@ -191,7 +191,7 @@ if (node.type === "TEXT") {this.color = extractColorStyle(fillColor.color); } else if (fillColor.type.includes("GRADIENT")) { this.backgroundImage = extractGradientColorStyle( fillColor as unknown as ElementGradientColor (fillColor as unknown) as ElementGradientColor ); } else if (fillColor.type === "SOLID") { this.background = extractColorStyle(fillColor.color);
-
-
-
@@ -397,8 +397,10 @@ resetZoom() {if (this.#canvasSize) { // Set initial zoom level based on element size const { width, height } = this.#canvasSize; const { width: elementWidth, height: elementHeight } = this.getBoundingClientRect(); const { width: elementWidth, height: elementHeight, } = this.getBoundingClientRect(); const wDiff = elementWidth / (width + this.zoomMargin * 2); const hDiff = elementHeight / (height + this.zoomMargin * 2);
-
-
-
@@ -4463,7 +4463,7 @@ version "0.1.1"resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" integrity sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= copy-to-clipboard@^3.0.0, copy-to-clipboard@^3.3.1: copy-to-clipboard@^3.3.1: version "3.3.1" resolved "https://registry.yarnpkg.com/copy-to-clipboard/-/copy-to-clipboard-3.3.1.tgz#115aa1a9998ffab6196f93076ad6da3b913662ae" integrity sha512-i13qo6kIHTTpCm8/Wup+0b1mVWETvu2kIMzKoK8FpkLkFxlt0znUAHcMzox+T8sPlqtZXq3CulEjQHsYiGFJUw==
-