feat(select-option): pass class from the option to the interface for individual styling (#21304)

Co-authored-by: Robb Wright <audaxion@gmail.com>
This commit is contained in:
Brandy Carney
2020-05-27 12:12:01 -04:00
committed by GitHub
parent 2dac12c577
commit 5285824da5
12 changed files with 1465 additions and 13 deletions

View File

@ -159,6 +159,7 @@ export class Alert implements ComponentInterface, OverlayInterface {
label: i.label,
checked: !!i.checked,
disabled: !!i.disabled,
cssClass: i.cssClass || '',
id: i.id || `alert-input-${this.overlayIndex}-${index}`,
handler: i.handler,
min: i.min,
@ -334,6 +335,7 @@ export class Alert implements ComponentInterface, OverlayInterface {
tabIndex={0}
role="checkbox"
class={{
...getClassMap(i.cssClass),
'alert-tappable': true,
'alert-checkbox': true,
'alert-checkbox-button': true,
@ -372,6 +374,7 @@ export class Alert implements ComponentInterface, OverlayInterface {
id={i.id}
tabIndex={0}
class={{
...getClassMap(i.cssClass),
'alert-radio-button': true,
'alert-tappable': true,
'alert-radio': true,
@ -411,6 +414,7 @@ export class Alert implements ComponentInterface, OverlayInterface {
disabled={i.disabled}
tabIndex={0}
class={{
...getClassMap(i.cssClass),
'alert-input': true,
'alert-input-disabled': i.disabled || false
}}
@ -431,6 +435,7 @@ export class Alert implements ComponentInterface, OverlayInterface {
disabled={i.disabled}
tabIndex={0}
class={{
...getClassMap(i.cssClass),
'alert-input': true,
'alert-input-disabled': i.disabled || false
}}