Enum labels doesn't work

Hey,

I am integrating Bryntum Grid as a custom React component within Retool. Bryntum Grid provides five built-in themes. To allow users to select a theme, I am using a Retool enum state. I have mapped each theme to a user-friendly label—for example, the classic-dark theme is displayed with the label "Dark".

Following is my code :

const [theme, _setTheme] = Retool.useStateEnumeration({
    name: 'theme',
    initialValue: 'material',
    inspector: 'select',
    enumDefinition: ['stockholm', 'material', 'classic', 'classic-dark', 'classic-light'],
    enumLabels: {
      stockholm: 'Stockholm',
      material: 'Material',
      classic: 'Classic',
      'classic-dark': 'Dark',
      'classic-light': 'Light',
    }
  });

In the dropdown, I see the enumDefinition, not the enum label values.

1 Like

Hi @khattakdev!

I'm seeing the same result as you no matter which way I try and configure the enum's display labels. I will have to file this as a bug internally I think.

Will keep looking to see if there's something I'm missing.

Taylor

4 Likes