mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-23 22:17:40 +08:00
chore(slides): move slide to separate directory
This commit is contained in:
2
packages/core/src/components.d.ts
vendored
2
packages/core/src/components.d.ts
vendored
@ -2785,7 +2785,7 @@ declare global {
|
|||||||
|
|
||||||
import {
|
import {
|
||||||
Slide as IonSlide
|
Slide as IonSlide
|
||||||
} from './components/slides/slide';
|
} from './components/slide/slide';
|
||||||
|
|
||||||
declare global {
|
declare global {
|
||||||
interface HTMLIonSlideElement extends IonSlide, HTMLElement {
|
interface HTMLIonSlideElement extends IonSlide, HTMLElement {
|
||||||
|
16
packages/core/src/components/slide/readme.md
Normal file
16
packages/core/src/components/slide/readme.md
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
# ion-slide
|
||||||
|
|
||||||
|
The Slide component is a child component of [Slides](../Slides). The template
|
||||||
|
should be written as `ion-slide`. Any slide content should be written
|
||||||
|
in this component and it should be used in conjunction with [Slides](../Slides).
|
||||||
|
|
||||||
|
See the [Slides API Docs](../Slides) for more usage information.
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Auto Generated Below -->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
----------------------------------------------
|
||||||
|
|
||||||
|
*Built by [StencilJS](https://stenciljs.com/)*
|
22
packages/core/src/components/slide/slide.tsx
Normal file
22
packages/core/src/components/slide/slide.tsx
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
import { Component } from '@stencil/core';
|
||||||
|
|
||||||
|
|
||||||
|
@Component({
|
||||||
|
tag: 'ion-slide',
|
||||||
|
styleUrl: 'slide.scss'
|
||||||
|
})
|
||||||
|
export class Slide {
|
||||||
|
|
||||||
|
hostData() {
|
||||||
|
return {
|
||||||
|
class: {
|
||||||
|
'slide-zoom': true,
|
||||||
|
'swiper-slide': true
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
render() {
|
||||||
|
return <slot></slot>;
|
||||||
|
}
|
||||||
|
}
|
@ -1,10 +1,212 @@
|
|||||||
# ion-slide
|
# ion-slides
|
||||||
|
|
||||||
|
The Slides component is a multi-section container. Each section can be swiped
|
||||||
|
or dragged between. It contains any number of [Slide](../Slide) components.
|
||||||
|
|
||||||
|
|
||||||
|
```
|
||||||
|
Adopted from Swiper.js:
|
||||||
|
The most modern mobile touch slider and framework with
|
||||||
|
hardware accelerated transitions.
|
||||||
|
|
||||||
|
http://www.idangero.us/swiper/
|
||||||
|
|
||||||
|
Copyright 2016, Vladimir Kharlampidi
|
||||||
|
The iDangero.us
|
||||||
|
http://www.idangero.us/
|
||||||
|
|
||||||
|
Licensed under MIT
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
<!-- Auto Generated Below -->
|
<!-- Auto Generated Below -->
|
||||||
|
|
||||||
|
|
||||||
|
## Properties
|
||||||
|
|
||||||
|
#### autoplay
|
||||||
|
|
||||||
|
number
|
||||||
|
|
||||||
|
|
||||||
|
#### control
|
||||||
|
|
||||||
|
any
|
||||||
|
|
||||||
|
|
||||||
|
#### direction
|
||||||
|
|
||||||
|
any
|
||||||
|
|
||||||
|
|
||||||
|
#### effect
|
||||||
|
|
||||||
|
string
|
||||||
|
|
||||||
|
|
||||||
|
#### initialSlide
|
||||||
|
|
||||||
|
number
|
||||||
|
|
||||||
|
|
||||||
|
#### keyboardControl
|
||||||
|
|
||||||
|
boolean
|
||||||
|
|
||||||
|
|
||||||
|
#### loop
|
||||||
|
|
||||||
|
boolean
|
||||||
|
|
||||||
|
|
||||||
|
#### pager
|
||||||
|
|
||||||
|
boolean
|
||||||
|
|
||||||
|
|
||||||
|
#### paginationType
|
||||||
|
|
||||||
|
string
|
||||||
|
|
||||||
|
|
||||||
|
#### parallax
|
||||||
|
|
||||||
|
boolean
|
||||||
|
|
||||||
|
|
||||||
|
#### slidesPerView
|
||||||
|
|
||||||
|
any
|
||||||
|
|
||||||
|
|
||||||
|
#### spaceBetween
|
||||||
|
|
||||||
|
number
|
||||||
|
|
||||||
|
|
||||||
|
#### speed
|
||||||
|
|
||||||
|
number
|
||||||
|
|
||||||
|
|
||||||
|
#### zoom
|
||||||
|
|
||||||
|
boolean
|
||||||
|
|
||||||
|
|
||||||
|
## Attributes
|
||||||
|
|
||||||
|
#### autoplay
|
||||||
|
|
||||||
|
number
|
||||||
|
|
||||||
|
|
||||||
|
#### control
|
||||||
|
|
||||||
|
any
|
||||||
|
|
||||||
|
|
||||||
|
#### direction
|
||||||
|
|
||||||
|
any
|
||||||
|
|
||||||
|
|
||||||
|
#### effect
|
||||||
|
|
||||||
|
string
|
||||||
|
|
||||||
|
|
||||||
|
#### initialSlide
|
||||||
|
|
||||||
|
number
|
||||||
|
|
||||||
|
|
||||||
|
#### keyboardControl
|
||||||
|
|
||||||
|
boolean
|
||||||
|
|
||||||
|
|
||||||
|
#### loop
|
||||||
|
|
||||||
|
boolean
|
||||||
|
|
||||||
|
|
||||||
|
#### pager
|
||||||
|
|
||||||
|
boolean
|
||||||
|
|
||||||
|
|
||||||
|
#### paginationType
|
||||||
|
|
||||||
|
string
|
||||||
|
|
||||||
|
|
||||||
|
#### parallax
|
||||||
|
|
||||||
|
boolean
|
||||||
|
|
||||||
|
|
||||||
|
#### slidesPerView
|
||||||
|
|
||||||
|
any
|
||||||
|
|
||||||
|
|
||||||
|
#### spaceBetween
|
||||||
|
|
||||||
|
number
|
||||||
|
|
||||||
|
|
||||||
|
#### speed
|
||||||
|
|
||||||
|
number
|
||||||
|
|
||||||
|
|
||||||
|
#### zoom
|
||||||
|
|
||||||
|
boolean
|
||||||
|
|
||||||
|
|
||||||
|
## Events
|
||||||
|
|
||||||
|
#### ionSlideDidChange
|
||||||
|
|
||||||
|
|
||||||
|
#### ionSlideDrag
|
||||||
|
|
||||||
|
|
||||||
|
#### ionSlideNextEnd
|
||||||
|
|
||||||
|
|
||||||
|
#### ionSlideNextStart
|
||||||
|
|
||||||
|
|
||||||
|
#### ionSlidePrevEnd
|
||||||
|
|
||||||
|
|
||||||
|
#### ionSlidePrevStart
|
||||||
|
|
||||||
|
|
||||||
|
#### ionSlideReachEnd
|
||||||
|
|
||||||
|
|
||||||
|
#### ionSlideReachStart
|
||||||
|
|
||||||
|
|
||||||
|
#### ionSlideTouchEnd
|
||||||
|
|
||||||
|
|
||||||
|
#### ionSlideTouchStart
|
||||||
|
|
||||||
|
|
||||||
|
#### ionSlideTransitionEnd
|
||||||
|
|
||||||
|
|
||||||
|
#### ionSlideTransitionStart
|
||||||
|
|
||||||
|
|
||||||
|
#### ionSlideWillChange
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
----------------------------------------------
|
----------------------------------------------
|
||||||
|
|
||||||
|
@ -1,34 +0,0 @@
|
|||||||
import { Component } from '@stencil/core';
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @name Slide
|
|
||||||
* @description
|
|
||||||
* The Slide component is a child component of [Slides](../Slides). The template
|
|
||||||
* should be written as `ion-slide`. Any slide content should be written
|
|
||||||
* in this component and it should be used in conjunction with [Slides](../Slides).
|
|
||||||
*
|
|
||||||
* See the [Slides API Docs](../Slides) for more usage information.
|
|
||||||
*
|
|
||||||
* @demo /docs/demos/src/slides/
|
|
||||||
* @see {@link /docs/api/components/slides/Slides/ Slides API Docs}
|
|
||||||
*/
|
|
||||||
@Component({
|
|
||||||
tag: 'ion-slide',
|
|
||||||
styleUrl: 'slide.scss'
|
|
||||||
})
|
|
||||||
export class Slide {
|
|
||||||
|
|
||||||
hostData() {
|
|
||||||
return {
|
|
||||||
class: {
|
|
||||||
'slide-zoom': true,
|
|
||||||
'swiper-slide': true
|
|
||||||
}
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
render() {
|
|
||||||
return <slot></slot>;
|
|
||||||
}
|
|
||||||
}
|
|
@ -2,27 +2,6 @@ import { Component, Element, Event, EventEmitter, Prop } from '@stencil/core';
|
|||||||
import { Swiper } from './vendor/swiper';
|
import { Swiper } from './vendor/swiper';
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @name Slides
|
|
||||||
* @description
|
|
||||||
* The Slides component is a multi-section container. Each section can be swiped
|
|
||||||
* or dragged between. It contains any number of [Slide](../Slide) components.
|
|
||||||
*
|
|
||||||
*
|
|
||||||
* Adopted from Swiper.js:
|
|
||||||
* The most modern mobile touch slider and framework with
|
|
||||||
* hardware accelerated transitions.
|
|
||||||
*
|
|
||||||
* http://www.idangero.us/swiper/
|
|
||||||
*
|
|
||||||
* Copyright 2016, Vladimir Kharlampidi
|
|
||||||
* The iDangero.us
|
|
||||||
* http://www.idangero.us/
|
|
||||||
*
|
|
||||||
* Licensed under MIT
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
tag: 'ion-slides',
|
tag: 'ion-slides',
|
||||||
styleUrl: 'slides.scss',
|
styleUrl: 'slides.scss',
|
||||||
|
2
packages/core/src/index.d.ts
vendored
2
packages/core/src/index.d.ts
vendored
@ -129,7 +129,7 @@ export { SelectPopoverOption, SelectPopover } from './components/select/select-p
|
|||||||
export { Select } from './components/select/select';
|
export { Select } from './components/select/select';
|
||||||
export { SelectOption } from './components/select-option/select-option';
|
export { SelectOption } from './components/select-option/select-option';
|
||||||
export { SkeletonText } from './components/skeleton-text/skeleton-text';
|
export { SkeletonText } from './components/skeleton-text/skeleton-text';
|
||||||
export { Slide } from './components/slides/slide';
|
export { Slide } from './components/slide/slide';
|
||||||
export { Slides } from './components/slides/slides';
|
export { Slides } from './components/slides/slides';
|
||||||
export * from './components/spinner/spinner-configs';
|
export * from './components/spinner/spinner-configs';
|
||||||
export { Spinner } from './components/spinner/spinner';
|
export { Spinner } from './components/spinner/spinner';
|
||||||
|
Reference in New Issue
Block a user