aurelia-ui-toolkits / aurelia-materialize-bridge

Materialize CSS components for Aurelia
http://aurelia-ui-toolkits.github.io/demo-materialize/
MIT License
155 stars 53 forks source link

md-input does not show validation error #488

Closed HIRANO-Satoshi closed 6 years ago

HIRANO-Satoshi commented 7 years ago

<md-input> does not show validation error properly in my app. Although I spent time, I could not find what was wrong.

For example, just press the VALIDATE button in the doc, you can see 'First name is required' below md-input for firstName. That is correct.

https://aurelia-ui-toolkits.github.io/demo-materialize/#/samples/input-aurelia-validation

Next, type PLAY button in the page and I can see the same example on gistrun. Just press VALIDATE button. I cannot see any error message under md-input for firstName. I don't think that is correct.

https://gist.run/?id=59525172dc31afb0de610d0b174676a0

When I press just TAB in md-input for a required field to leave it blank, it does not show an error message.

Thanood commented 6 years ago

@HIRANO-Satoshi I've updated the gist to contain <md-colors></md-colors> in the main html file. Did you add this, too? It's described in the _colors.md file which should be visible as the first tab in the bridge app.

Anyway, the colors are off (black bottom border) when an input is focused, so I'll tag this issue as a bug.

Thanood commented 6 years ago

@HIRANO-Satoshi If you define md-accent-color with <md-colors> it should also display the correct colors.

I remember now that I dropped it from the gist because the bridge app sets the colors dynamically and if I set it in the gist, that would overwrite the dynamic colors.