1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
import '../assets/index.less';
import Slider from '../src/slider';
export default {
render: function render() {
var h = arguments[0];
var settings = {
'class': 'slider variable-width',
props: {
dots: true,
infinite: true,
centerMode: true,
slidesToShow: 1,
slidesToScroll: 1,
variableWidth: true
}
};
return h('div', [h('h2', ['Variable width']), h(
Slider,
settings,
[h(
'div',
{ style: { width: '100px' } },
[h('p', ['100'])]
), h(
'div',
{ style: { width: '200px' } },
[h('p', ['200'])]
), h(
'div',
{ style: { width: '75px' } },
[h('p', ['75'])]
), h(
'div',
{ style: { width: '300px' } },
[h('p', ['300'])]
), h(
'div',
{ style: { width: '225px' } },
[h('p', ['225'])]
), h(
'div',
{ style: { width: '175px' } },
[h('p', ['175'])]
)]
)]);
}
};