From eb45679057a3b5cdf4f048bc0222896c20c212ed Mon Sep 17 00:00:00 2001 From: nlaitine Date: Fri, 1 Feb 2019 16:54:30 +0200 Subject: [PATCH] Removed type definition illegal patch version --- types/theo/index.d.ts | 2 +- types/theo/theo-tests.ts | 10 ++++------ 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/types/theo/index.d.ts b/types/theo/index.d.ts index 3747a69fcf..3ff3770fdd 100644 --- a/types/theo/index.d.ts +++ b/types/theo/index.d.ts @@ -1,4 +1,4 @@ -// Type definitions for theo 8.1.1 +// Type definitions for theo 8.1 // Project: https://github.com/salesforce-ux/theo // Definitions by: Pete Petrash // Niko Laitinen diff --git a/types/theo/theo-tests.ts b/types/theo/theo-tests.ts index d7692e4265..ceaaf9649c 100644 --- a/types/theo/theo-tests.ts +++ b/types/theo/theo-tests.ts @@ -21,12 +21,10 @@ theo.registerFormat( ); theo.registerValueTransform( - "easing/web", - prop => prop.get("category") === "easing", + "relative/pixelValue", + prop => prop.get("category") === "sizing", prop => { - const [x1, y1, x2, y2] = prop.get("value").toArray(); - return `cubic-bezier(${x1}, ${y1}, ${x2}, ${y2})`; + const value = prop.get("value").toString(); + return parseFloat(value.replace(/rem/g, "")) * 16; } ); - -theo.registerTransform("web", ["color/rgb", "easing/web"]);