From 1ee89d0e643ef130471340c79dabe2cdbdea7a09 Mon Sep 17 00:00:00 2001 From: Lorenzo Blasa Date: Tue, 25 Oct 2022 03:09:00 -0700 Subject: [PATCH] Add enum and boolean inspectables Summary: Add types to support enum and boolean inspectables Reviewed By: aigoncharov Differential Revision: D40344566 fbshipit-source-id: c1f719e634a4096e5dd63d3b96c6d64c9684c62b --- desktop/plugins/public/ui-debugger/types.tsx | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/desktop/plugins/public/ui-debugger/types.tsx b/desktop/plugins/public/ui-debugger/types.tsx index 89a204fcb..4e8bca042 100644 --- a/desktop/plugins/public/ui-debugger/types.tsx +++ b/desktop/plugins/public/ui-debugger/types.tsx @@ -67,7 +67,9 @@ export type Inspectable = | InspectableObject | InspectableText | InspectableNumber - | InspectableColor; + | InspectableColor + | InspectableBoolean + | InspectableEnum; export type InspectableText = { type: 'text'; @@ -81,6 +83,18 @@ export type InspectableNumber = { mutable: boolean; }; +export type InspectableBoolean = { + type: 'boolean'; + value: boolean; + mutable: boolean; +}; + +export type InspectableEnum = { + type: 'enum'; + value: {value: string; values: string[]}; + mutable: boolean; +}; + export type InspectableColor = { type: 'color'; value: Color;