Basic array support

Summary:
Attributes Inspector didn't have support for inspectable arrays.

This change addresses an issue with the inspectable itself and adds basic support to it in the visualiser.

Reviewed By: LukeDefeo

Differential Revision: D41522879

fbshipit-source-id: f9cad42470541039c8157477b0fe9bc58f18f1ba
This commit is contained in:
Lorenzo Blasa
2022-11-28 10:19:20 -08:00
committed by Facebook GitHub Bot
parent 1406e291ee
commit 76b1673d15
4 changed files with 43 additions and 2 deletions

View File

@@ -134,7 +134,7 @@ object ComponentPropExtractor {
override fun isArray(array: EditorArray?): Inspectable {
val values = array?.value?.map { value -> toInspectable(name, value) }
return InspectableArray(0, values ?: listOf())
return InspectableArray(values ?: listOf())
}
override fun isPick(pick: EditorPick): Inspectable = InspectableValue.Enum(pick.selected)