mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-21 21:15:24 +08:00
fix(select): add the cssClass passed by the user to the alert for a select
fixes #6835
This commit is contained in:
@ -103,7 +103,8 @@ export class AlertCmp {
|
||||
|
||||
if (this.d.cssClass) {
|
||||
this.d.cssClass.split(' ').forEach(cssClass => {
|
||||
renderer.setElementClass(_elementRef.nativeElement, cssClass, true);
|
||||
// Make sure the class isn't whitespace, otherwise it throws exceptions
|
||||
if (cssClass.trim() !== '') renderer.setElementClass(_elementRef.nativeElement, cssClass, true);
|
||||
});
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user