Add enum and boolean inspectables

Summary: Add types to support enum and boolean inspectables

Reviewed By: aigoncharov

Differential Revision: D40344566

fbshipit-source-id: c1f719e634a4096e5dd63d3b96c6d64c9684c62b
This commit is contained in:
Lorenzo Blasa
2022-10-25 03:09:00 -07:00
committed by Facebook GitHub Bot
parent c46ddf7912
commit 1ee89d0e64

View File

@@ -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;