From 00f736a95e7d1880edf0e5af196f5265ecb9cdfa Mon Sep 17 00:00:00 2001 From: Jonathan Holmes Date: Mon, 11 Oct 2021 16:31:38 +0100 Subject: [PATCH] fix(types): added `name` to format, and export `Named` --- types/Format.d.ts | 1 + types/index.d.ts | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/types/Format.d.ts b/types/Format.d.ts index 483594c90..f2651a39c 100644 --- a/types/Format.d.ts +++ b/types/Format.d.ts @@ -42,5 +42,6 @@ export interface FormatterArguments { export type Formatter = (arguments: FormatterArguments) => string; export interface Format { + name: string; formatter: Formatter; } \ No newline at end of file diff --git a/types/index.d.ts b/types/index.d.ts index 0c743ada7..e1f912906 100644 --- a/types/index.d.ts +++ b/types/index.d.ts @@ -28,7 +28,7 @@ import {Platform as _Platform} from './Platform'; import {Transform as _Transform} from './Transform'; import {TransformedToken as _TransformedToken, TransformedTokens as _TransformedTokens} from './TransformedToken'; import {TransformGroup as _TransformGroup} from './TransformGroup'; -import {Named} from './_helpers'; +import {Named as _Named} from './_helpers'; // Because this library is used in Node and needs to be accessible // as a CommonJS module, we are declaring it as a namespace so that @@ -51,6 +51,7 @@ declare namespace StyleDictionary { type TransformedToken = _TransformedToken; type TransformedTokens = _TransformedTokens; type TransformGroup = _TransformGroup; + type Named = _Named interface Core { VERSION: string;