From 1b09722d87873d0f11cbaf61dc95bb56d1f01c6a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20Vassbotn=20R=C3=B8yne-Helgesen?= Date: Fri, 24 Nov 2023 10:23:23 +0100 Subject: [PATCH] =?UTF-8?q?fix:=20=F0=9F=90=9B=20Use=20correct=20parameter?= =?UTF-8?q?=20type=20for=20color?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/classes/MoebiusColor.ts | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/classes/MoebiusColor.ts b/src/classes/MoebiusColor.ts index 72cd857..08a7d76 100644 --- a/src/classes/MoebiusColor.ts +++ b/src/classes/MoebiusColor.ts @@ -10,7 +10,8 @@ import { MoebiusLCHObjectType, MoebiusColorInterface, MoebiusRGBObjectType, - MoebiusXYZObjectType + MoebiusXYZObjectType, + MoebiusChromaColorInputType } from '../types'; import * as CONVERTERS from '../utils/converters'; @@ -24,7 +25,7 @@ import * as CONVERTERS from '../utils/converters'; * ``` */ export class MoebiusColor implements MoebiusColorInterface { - color: MoebiusColorValueHexType; + color: MoebiusChromaColorInputType; name: string; hex: MoebiusColorValueHexType; rgb: MoebiusColorValueRgbType; @@ -41,12 +42,12 @@ export class MoebiusColor implements MoebiusColorInterface { /** * Creates an instance of MoebiusColor. - * @param {MoebiusColorValueHexType} value - The hex value of the color. + * @param {MoebiusChromaColorInputType} value - The hex value of the color. * @param {string} name - The name of the color * @constructor * @throws Will throw an error if init has not been run before creating an instance. */ - constructor(color: MoebiusColorValueHexType, name: string) { + constructor(color: MoebiusChromaColorInputType, name: string) { this.color = color; this.name = name;