From e1594c6a7ba1fa4b702bd58b89953812a1e27c2c Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Tue, 9 Aug 2022 17:44:20 +0200 Subject: [PATCH] Add the typings for the icon web components --- global.d.ts | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/global.d.ts b/global.d.ts index f2553a04ab..0cac1e4445 100644 --- a/global.d.ts +++ b/global.d.ts @@ -11,6 +11,8 @@ type Codepoint = string; type IconStyles = string[]; type IconMetadata = [Codepoint, IconStyles]; +type IconSize = 16 | 24 | 32 | 48 | 64 | 96 | 128 | 144; + declare global { interface Window { Devtools?: typeof Devtools; @@ -50,4 +52,15 @@ declare global { } type ArbitraryObject = Record; + + interface FaBrand extends HTMLElement { + name: string; + size: IconSize; + } + + interface FaIcon extends HTMLElement { + name: string; + solid: boolean; + size: IconSize; + } } -- 2.20.1