mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-18 03:00:58 +08:00
fix(item): update hostContext to use ion-item element
fixes styling issues with children elements using the .in-item class
This commit is contained in:
@ -120,7 +120,7 @@ export class Checkbox {
|
||||
return {
|
||||
class: {
|
||||
...createColorClasses(this.color),
|
||||
'in-item': hostContext('.item', this.el),
|
||||
'in-item': hostContext('ion-item', this.el),
|
||||
'checkbox-checked': this.checked,
|
||||
'checkbox-disabled': this.disabled,
|
||||
'checkbox-key': this.keyFocus,
|
||||
|
@ -325,7 +325,7 @@ export class Input {
|
||||
class: {
|
||||
...createColorClasses(this.color),
|
||||
|
||||
'in-item': hostContext('.item', this.el),
|
||||
'in-item': hostContext('ion-item', this.el),
|
||||
'has-value': this.hasValue(),
|
||||
'has-focus': this.hasFocus
|
||||
}
|
||||
|
@ -449,7 +449,7 @@ export class Menu implements MenuI {
|
||||
this.gesture.setDisabled(!isActive || !this.swipeGesture);
|
||||
}
|
||||
|
||||
// Close menu inmediately
|
||||
// Close menu immediately
|
||||
if (!isActive && this._isOpen) {
|
||||
// close if this menu is open, and should not be enabled
|
||||
this.forceClosing();
|
||||
|
@ -172,7 +172,7 @@ export class Radio {
|
||||
return {
|
||||
class: {
|
||||
...createColorClasses(this.color),
|
||||
'in-item': hostContext('.item', this.el),
|
||||
'in-item': hostContext('ion-item', this.el),
|
||||
'interactive': true,
|
||||
'radio-checked': this.checked,
|
||||
'radio-disabled': this.disabled,
|
||||
|
@ -330,7 +330,7 @@ export class Range {
|
||||
return {
|
||||
class: {
|
||||
...createColorClasses(this.color),
|
||||
'in-item': hostContext('.item', this.el),
|
||||
'in-item': hostContext('ion-item', this.el),
|
||||
'range-disabled': this.disabled,
|
||||
'range-pressed': this.pressedKnob !== undefined,
|
||||
'range-has-pin': this.pin
|
||||
|
@ -458,7 +458,7 @@ export class Select {
|
||||
hostData() {
|
||||
return {
|
||||
class: {
|
||||
'in-item': hostContext('.item', this.el),
|
||||
'in-item': hostContext('ion-item', this.el),
|
||||
'select-disabled': this.disabled,
|
||||
'select-key': this.keyFocus
|
||||
}
|
||||
|
@ -175,7 +175,7 @@ export class Toggle {
|
||||
return {
|
||||
class: {
|
||||
...createColorClasses(this.color),
|
||||
'in-item': hostContext('.item', this.el),
|
||||
'in-item': hostContext('ion-item', this.el),
|
||||
'toggle-activated': this.activated,
|
||||
'toggle-checked': this.checked,
|
||||
'toggle-disabled': this.disabled,
|
||||
|
Reference in New Issue
Block a user