mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-20 12:29:55 +08:00
chore(colorClass): update createColorClasses() for ts4 (#21896)
Change the createColorClasses() fn so the returned type and jsx class property work well with typescript 4
This commit is contained in:
@ -122,10 +122,8 @@ export class BackButton implements ComponentInterface, ButtonInterface {
|
||||
return (
|
||||
<Host
|
||||
onClick={this.onClick}
|
||||
class={{
|
||||
...createColorClasses(color),
|
||||
class={createColorClasses(color, {
|
||||
[mode]: true,
|
||||
|
||||
'button': true, // ion-buttons target .button
|
||||
'back-button-disabled': disabled,
|
||||
'back-button-has-icon-only': hasIconOnly,
|
||||
@ -134,7 +132,7 @@ export class BackButton implements ComponentInterface, ButtonInterface {
|
||||
'ion-activatable': true,
|
||||
'ion-focusable': true,
|
||||
'show-back-button': showBackButton
|
||||
}}
|
||||
})}
|
||||
>
|
||||
<button
|
||||
type={type}
|
||||
|
Reference in New Issue
Block a user