Refactor #4211 - For Carousel
parent
066f9caade
commit
dfef0ca9b5
|
@ -20,6 +20,7 @@ export interface CarouselPassThroughMethodOptions {
|
||||||
instance: any;
|
instance: any;
|
||||||
props: CarouselProps;
|
props: CarouselProps;
|
||||||
state: CarouselState;
|
state: CarouselState;
|
||||||
|
context: CarouselContext;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -165,6 +166,17 @@ export interface CarouselState {
|
||||||
swipeThreshold: number;
|
swipeThreshold: number;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Defines current inline options in Carousel component.
|
||||||
|
*/
|
||||||
|
export interface GalleriaContext {
|
||||||
|
/**
|
||||||
|
* Current highlighted state of the indicator as a boolean.
|
||||||
|
* @defaultValue false
|
||||||
|
*/
|
||||||
|
highlighted: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
export interface CarouselResponsiveOptions {
|
export interface CarouselResponsiveOptions {
|
||||||
/**
|
/**
|
||||||
* Breakpoint for responsive mode. Exp; @media screen and (max-width: ${breakpoint}) {...}
|
* Breakpoint for responsive mode. Exp; @media screen and (max-width: ${breakpoint}) {...}
|
||||||
|
|
|
@ -239,6 +239,13 @@ export default {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
getIndicatorPTOptions(index) {
|
||||||
|
return {
|
||||||
|
context: {
|
||||||
|
highlighted: index === this.d_page
|
||||||
|
}
|
||||||
|
};
|
||||||
|
},
|
||||||
step(dir, page) {
|
step(dir, page) {
|
||||||
let totalShiftedItems = this.totalShiftedItems;
|
let totalShiftedItems = this.totalShiftedItems;
|
||||||
const isCircular = this.isCircular();
|
const isCircular = this.isCircular();
|
||||||
|
|
Loading…
Reference in New Issue