mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-20 20:33:32 +08:00
fix(components): include mode classes on components for use in shadow (#17838)
- removes mode-less component classes from the internal CSS, use element instead - adds mode specific classes `md` or `ios` for styling inside of shadow components - adds e2e test that verifies mode classes exist on all ionic components, plus checks for specific classes that the components need for internal styling fixes #17608
This commit is contained in:
@ -1,10 +1,13 @@
|
||||
import { Component, ComponentInterface, Element, Event, EventEmitter, EventListenerEnable, Listen, Method, Prop, QueueApi, State, Watch } from '@stencil/core';
|
||||
|
||||
import { Mode } from '../../interface';
|
||||
|
||||
@Component({
|
||||
tag: 'ion-infinite-scroll',
|
||||
styleUrl: 'infinite-scroll.scss'
|
||||
})
|
||||
export class InfiniteScroll implements ComponentInterface {
|
||||
mode!: Mode;
|
||||
|
||||
private thrPx = 0;
|
||||
private thrPc = 0;
|
||||
@ -212,6 +215,7 @@ export class InfiniteScroll implements ComponentInterface {
|
||||
hostData() {
|
||||
return {
|
||||
class: {
|
||||
[`${this.mode}`]: true,
|
||||
'infinite-scroll-loading': this.isLoading,
|
||||
'infinite-scroll-enabled': !this.disabled
|
||||
}
|
||||
|
Reference in New Issue
Block a user