Describe the bug
When adding the FormulaOne card through the Home Assistant visual editor, the required card_type field is not shown in the UI. Because of that, it is impossible to select a card type before saving, and the editor returns the error Please define FormulaOne card type (card_type).
To Reproduce
Steps to reproduce the behavior:
- Go to a Home Assistant dashboard.
- Click
Edit dashboard
- Add a new card and select FormulaOne card.
- Open the visual editor and try to configure the card.
- Click
Save.
- See error:
Please define FormulaOne card type (card_type).
Expected behavior
The visual editor should show a visible selector for the required card_type field, so the user can choose the card type and save the card successfully.
Screenshots
Desktop (please complete the following information):
- OS: Mac OS
- Browser Chrome
- Version v.1.14.3
Smartphone (please complete the following information):
- Device: not tested
- OS: not tested
- Browser [not tested
- Version not tested
Additional context
I looked through the code and the validation itself seems correct, since card_type is required. The issue appears to be in the visual editor. The editor defines card_type as a dropdown, but it is rendered using ha-combo-box, while the editor styles only seem to give explicit width handling to ha-textfield. That makes it look like the required selector is collapsing or not rendering visibly in the layout. A likely fix would be to give ha-combo-box the same width/flex handling as the text fields in the editor CSS.
But I am only guessing a little bit here, what we call “guy guessing” in Sweden, the art of guessing without really knowing, but still sounding like you know what you are talking about.
Describe the bug
When adding the FormulaOne card through the Home Assistant visual editor, the required
card_typefield is not shown in the UI. Because of that, it is impossible to select a card type before saving, and the editor returns the errorPlease define FormulaOne card type (card_type).To Reproduce
Steps to reproduce the behavior:
Edit dashboardSave.Please define FormulaOne card type (card_type).Expected behavior
The visual editor should show a visible selector for the required card_type field, so the user can choose the card type and save the card successfully.
Screenshots
Desktop (please complete the following information):
Smartphone (please complete the following information):
Additional context
I looked through the code and the validation itself seems correct, since
card_typeis required. The issue appears to be in the visual editor. The editor definescard_typeas a dropdown, but it is rendered using ha-combo-box, while the editor styles only seem to give explicit width handling toha-textfield. That makes it look like the required selector is collapsing or not rendering visibly in the layout. A likely fix would be to giveha-combo-boxthe same width/flex handling as the text fields in the editor CSS.But I am only guessing a little bit here, what we call “guy guessing” in Sweden, the art of guessing without really knowing, but still sounding like you know what you are talking about.