Aller au contenu

EnumValues

Ce contenu n’est pas encore disponible dans votre langue.

@firecms/core


@firecms/core / EnumValues

EnumValues = EnumValueConfig[] | Record<string | number, string | EnumValueConfig>

Defined in: types/properties.ts:210

We use this type to define mapping between string or number values in the data source to a label (such in a select dropdown). The key in this Record is the value saved in the datasource, and the value in this record is the label displayed in the UI. You can add additional customization by assigning a EnumValueConfig for the label instead of a simple string (for enabling or disabling options and choosing colors). If you need to ensure the order of the elements use an array of EnumValueConfig