From f92ffd5d8860150eb65174c493027602a38deabb Mon Sep 17 00:00:00 2001 From: Rob Pilling Date: Fri, 27 Jan 2023 23:10:17 +0000 Subject: [PATCH] layout.d.ts: update optionals --- typescript/types/layout.d.ts | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/typescript/types/layout.d.ts b/typescript/types/layout.d.ts index 31d57ff3c..2240ef55b 100644 --- a/typescript/types/layout.d.ts +++ b/typescript/types/layout.d.ts @@ -36,13 +36,13 @@ declare module Layout_ { hier: T, options?: { lazy: boolean, - btns: { + btns?: { label: string, cb: () => void, cbl: () => void, }[], - back: () => void, - remove: () => void, + back?: () => void, + remove?: () => void, }, ): Layouter; }; @@ -71,11 +71,11 @@ declare module Layout_ { id?: string, font?: FontNameWithScaleFactor, scale?: number, - col: ColorResolvable, - bgCol: ColorResolvable, - pad: number, - fillx: Fill, - filly: Fill, + col?: ColorResolvable, + bgCol?: ColorResolvable, + pad?: number, + fillx?: Fill, + filly?: Fill, width?: number, height?: number, } & ( @@ -92,17 +92,17 @@ declare module Layout_ { { type: "v", c: Hierarchy[], - halign: Align, + halign?: Align, } | { type: "h" c: Hierarchy[], - valign: Align, + valign?: Align, } | { type: "txt", label: string, font: FontNameWithScaleFactor, } | { - type: undefined, + type: undefined, // blank, for padding } | ( { type: "btn", @@ -112,8 +112,8 @@ declare module Layout_ { type: "btn", cb: () => void, label: string, - font: FontNameWithScaleFactor, - scale: number, + font?: FontNameWithScaleFactor, + scale?: number, } ) | { type: "img",