@roadtrip/components 3.32.4 → 3.32.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/road-badge_14.cjs.entry.js +9 -12
- package/dist/cjs/road-badge_14.cjs.entry.js.map +1 -1
- package/dist/collection/components/accordion/accordion.stories.js +38 -4
- package/dist/collection/components/alert/alert.stories.js +7 -0
- package/dist/collection/components/asset/asset.stories.js +6 -0
- package/dist/collection/components/autocomplete/autocomplete.stories.js +43 -47
- package/dist/collection/components/avatar/avatar.stories.js +6 -0
- package/dist/collection/components/badge/badge.stories.js +6 -0
- package/dist/collection/components/banner/banner.stories.js +33 -3
- package/dist/collection/components/button/button.stories.js +58 -67
- package/dist/collection/components/button-floating/button-floating.stories.js +32 -23
- package/dist/collection/components/card/card.stories.js +25 -15
- package/dist/collection/components/carousel/carousel.stories.js +72 -280
- package/dist/collection/components/checkbox/checkbox.stories.js +54 -33
- package/dist/collection/components/chip/chip.stories.js +32 -47
- package/dist/collection/components/collapse/collapse.stories.js +88 -78
- package/dist/collection/components/content-card/content-card.stories.js +30 -11
- package/dist/collection/components/counter/counter.stories.js +40 -11
- package/dist/collection/components/dialog/dialog.stories.js +37 -51
- package/dist/collection/components/drawer/drawer.js +9 -12
- package/dist/collection/components/drawer/drawer.js.map +1 -1
- package/dist/collection/components/drawer/drawer.stories.js +64 -134
- package/dist/collection/components/dropdown/dropdown.stories.js +69 -53
- package/dist/collection/components/duration/duration.stories.js +49 -45
- package/dist/collection/components/flap/flap.stories.js +22 -10
- package/dist/collection/components/input/input.stories.js +33 -0
- package/dist/collection/components/item/item.stories.js +25 -0
- package/dist/collection/components/list/list.stories.js +2 -0
- package/dist/collection/components/modal/modal.stories.js +14 -0
- package/dist/collection/components/navbar/navbar.stories.js +3 -0
- package/dist/collection/components/navbar-v2/navbar-v2.stories.js +4 -0
- package/dist/collection/components/phone-number-input/phone-number-input.stories.js +15 -1
- package/dist/collection/components/plate-number/plate-number.stories.js +13 -0
- package/dist/collection/components/profil-dropdown/profil-dropdown.stories.js +8 -0
- package/dist/collection/components/progress/progress.stories.js +12 -0
- package/dist/collection/components/progress-indicator-horizontal/progress-indicator-horizontal.stories.js +8 -0
- package/dist/collection/components/progress-indicator-vertical/progress-indicator-vertical.stories.js +1 -0
- package/dist/collection/components/progress-tracker/progress-tracker.stories.js +1 -0
- package/dist/collection/components/radio/radio.stories.js +13 -0
- package/dist/collection/components/range/range.stories.js +11 -0
- package/dist/collection/components/rating/rating.stories.js +7 -0
- package/dist/collection/components/segmented-buttons/segmented-buttons.stories.js +2 -0
- package/dist/collection/components/select/select.stories.js +13 -0
- package/dist/collection/components/select-filter/select-filter.stories.js +5 -0
- package/dist/collection/components/skeleton/skeleton.stories.js +2 -0
- package/dist/collection/components/spinner/spinner.stories.js +2 -0
- package/dist/collection/components/table/table.stories.js +1 -0
- package/dist/collection/components/tabs/tabs.stories.js +2 -0
- package/dist/collection/components/tag/tag.stories.js +3 -0
- package/dist/collection/components/text/text.stories.js +2 -0
- package/dist/collection/components/textarea/textarea.stories.js +26 -0
- package/dist/collection/components/toast/toast.stories.js +6 -0
- package/dist/collection/components/toggle/toggle.stories.js +14 -0
- package/dist/collection/components/toolbar/toolbar.stories.js +6 -0
- package/dist/collection/components/toolbar-v2/toolbar-v2.stories.js +5 -0
- package/dist/collection/components/tooltip/tooltip.stories.js +11 -0
- package/dist/esm/road-badge_14.entry.js +9 -12
- package/dist/esm/road-badge_14.entry.js.map +1 -1
- package/dist/roadtrip/{p-e2a00f9c.entry.js → p-b5c4455e.entry.js} +3 -3
- package/dist/roadtrip/p-b5c4455e.entry.js.map +1 -0
- package/dist/roadtrip/roadtrip.esm.js +1 -1
- package/dist/types/components/drawer/drawer.d.ts +0 -1
- package/hydrate/index.js +271 -255
- package/hydrate/index.mjs +271 -255
- package/package.json +1 -1
- package/dist/roadtrip/p-e2a00f9c.entry.js.map +0 -1
|
@@ -3,7 +3,7 @@ import { ifDefined } from 'lit/directives/if-defined.js';
|
|
|
3
3
|
import { unsafeHTML } from 'lit-html/directives/unsafe-html.js';
|
|
4
4
|
|
|
5
5
|
export default {
|
|
6
|
-
title: 'Forms/Button
|
|
6
|
+
title: 'Forms/Button Floating',
|
|
7
7
|
component: 'road-button-floating',
|
|
8
8
|
parameters: {
|
|
9
9
|
actions: {
|
|
@@ -12,57 +12,66 @@ export default {
|
|
|
12
12
|
},
|
|
13
13
|
argTypes: {
|
|
14
14
|
href: {
|
|
15
|
-
control: {
|
|
16
|
-
|
|
17
|
-
},
|
|
15
|
+
control: { type: null },
|
|
16
|
+
description: 'Defines the hyperlink reference (only applicable if the button acts as a link).',
|
|
18
17
|
},
|
|
19
18
|
position: {
|
|
20
19
|
options: ['left', 'right', 'center'],
|
|
21
|
-
control: {
|
|
22
|
-
|
|
20
|
+
control: { type: 'radio' },
|
|
21
|
+
description: 'Defines the floating button position.',
|
|
22
|
+
table: {
|
|
23
|
+
defaultValue: { summary: 'right' },
|
|
23
24
|
},
|
|
24
25
|
},
|
|
25
26
|
rel: {
|
|
26
|
-
control: {
|
|
27
|
-
|
|
28
|
-
},
|
|
27
|
+
control: { type: null },
|
|
28
|
+
description: 'Specifies the relationship between the current document and the linked document.',
|
|
29
29
|
},
|
|
30
30
|
target: {
|
|
31
|
-
control: {
|
|
32
|
-
|
|
33
|
-
},
|
|
31
|
+
control: { type: null },
|
|
32
|
+
description: 'Specifies where to open the linked document (only applicable if `href` is provided).',
|
|
34
33
|
},
|
|
35
34
|
start: {
|
|
36
35
|
control: 'text',
|
|
36
|
+
description: 'Slot for an icon or content at the **start** of the button.',
|
|
37
37
|
},
|
|
38
38
|
' ': {
|
|
39
39
|
control: 'text',
|
|
40
|
+
description: 'Label or main content inside the button.',
|
|
40
41
|
},
|
|
41
42
|
roadblur: {
|
|
42
|
-
|
|
43
|
-
|
|
43
|
+
action: 'roadblur',
|
|
44
|
+
description: 'Triggered when the button loses focus.',
|
|
45
|
+
table: {
|
|
46
|
+
category: 'Events',
|
|
47
|
+
type: { summary: 'CustomEvent' },
|
|
44
48
|
},
|
|
45
49
|
},
|
|
46
50
|
roadfocus: {
|
|
47
|
-
|
|
48
|
-
|
|
51
|
+
action: 'roadfocus',
|
|
52
|
+
description: 'Triggered when the button gains focus.',
|
|
53
|
+
table: {
|
|
54
|
+
category: 'Events',
|
|
55
|
+
type: { summary: 'CustomEvent' },
|
|
49
56
|
},
|
|
50
57
|
},
|
|
51
58
|
native: {
|
|
52
|
-
control: {
|
|
53
|
-
|
|
54
|
-
},
|
|
59
|
+
control: { type: null },
|
|
60
|
+
description: 'Internal native button element reference (if applicable).',
|
|
55
61
|
},
|
|
56
62
|
},
|
|
57
63
|
args: {
|
|
58
|
-
start:
|
|
64
|
+
start: '',
|
|
59
65
|
position: 'right',
|
|
60
|
-
' ':
|
|
66
|
+
' ': 'Label',
|
|
61
67
|
},
|
|
62
68
|
};
|
|
63
69
|
|
|
64
70
|
const Template = (args) => html`
|
|
65
|
-
<road-button-floating
|
|
71
|
+
<road-button-floating
|
|
72
|
+
position="${ifDefined(args.position)}"
|
|
73
|
+
tabindex="0"
|
|
74
|
+
>
|
|
66
75
|
${unsafeHTML(args.start)}
|
|
67
76
|
${unsafeHTML(args[' '])}
|
|
68
77
|
</road-button-floating>
|
|
@@ -72,4 +81,4 @@ export const Playground = Template.bind({});
|
|
|
72
81
|
Playground.args = {
|
|
73
82
|
start: `<road-icon slot="start" name="shopping-cart-add" role="button"></road-icon>`,
|
|
74
83
|
' ': `Add to cart`,
|
|
75
|
-
};
|
|
84
|
+
};
|
|
@@ -15,46 +15,48 @@ export default {
|
|
|
15
15
|
argTypes: {
|
|
16
16
|
elevation: {
|
|
17
17
|
options: ['none', 'lowest', 'average'],
|
|
18
|
-
control: {
|
|
19
|
-
|
|
18
|
+
control: { type: 'select' },
|
|
19
|
+
description: 'Defines the elevation (shadow effect) of the card.',
|
|
20
|
+
table: {
|
|
21
|
+
defaultValue: { summary: 'none' },
|
|
20
22
|
},
|
|
21
23
|
},
|
|
22
24
|
},
|
|
23
25
|
args: {
|
|
24
|
-
elevation:
|
|
26
|
+
elevation: 'none',
|
|
25
27
|
},
|
|
26
28
|
};
|
|
27
29
|
|
|
28
|
-
|
|
30
|
+
const Template = (args) => html`
|
|
29
31
|
<road-grid>
|
|
30
32
|
<road-row>
|
|
31
33
|
<road-col class="col-4 col-md-3 col-lg-2">
|
|
32
|
-
<road-card button value="125" elevation="${ifDefined(args.elevation)}">
|
|
34
|
+
<road-card button value="125" elevation="${ifDefined(args.elevation)}" @roadcardclick=${args.roadcardclick}>
|
|
33
35
|
<road-label>125</road-label>
|
|
34
36
|
</road-card>
|
|
35
37
|
</road-col>
|
|
36
38
|
<road-col class="col-4 col-md-3 col-lg-2">
|
|
37
|
-
<road-card button value="135" elevation="${ifDefined(args.elevation)}">
|
|
39
|
+
<road-card button value="135" elevation="${ifDefined(args.elevation)}" @roadcardclick=${args.roadcardclick}>
|
|
38
40
|
<road-label>135</road-label>
|
|
39
41
|
</road-card>
|
|
40
42
|
</road-col>
|
|
41
43
|
<road-col class="col-4 col-md-3 col-lg-2">
|
|
42
|
-
<road-card button value="145" elevation="${ifDefined(args.elevation)}">
|
|
44
|
+
<road-card button value="145" elevation="${ifDefined(args.elevation)}" @roadcardclick=${args.roadcardclick}>
|
|
43
45
|
<road-label>145</road-label>
|
|
44
46
|
</road-card>
|
|
45
47
|
</road-col>
|
|
46
48
|
<road-col class="col-4 col-md-3 col-lg-2">
|
|
47
|
-
<road-card button value="155" elevation="${ifDefined(args.elevation)}">
|
|
49
|
+
<road-card button value="155" elevation="${ifDefined(args.elevation)}" @roadcardclick=${args.roadcardclick}>
|
|
48
50
|
<road-label>155</road-label>
|
|
49
51
|
</road-card>
|
|
50
52
|
</road-col>
|
|
51
53
|
<road-col class="col-4 col-md-3 col-lg-2">
|
|
52
|
-
<road-card button value="165" elevation="${ifDefined(args.elevation)}">
|
|
54
|
+
<road-card button value="165" elevation="${ifDefined(args.elevation)}" @roadcardclick=${args.roadcardclick}>
|
|
53
55
|
<road-label>165</road-label>
|
|
54
56
|
</road-card>
|
|
55
57
|
</road-col>
|
|
56
58
|
<road-col class="col-4 col-md-3 col-lg-2">
|
|
57
|
-
<road-card button value="175" elevation="${ifDefined(args.elevation)}">
|
|
59
|
+
<road-card button value="175" elevation="${ifDefined(args.elevation)}" @roadcardclick=${args.roadcardclick}>
|
|
58
60
|
<road-label>175</road-label>
|
|
59
61
|
</road-card>
|
|
60
62
|
</road-col>
|
|
@@ -62,29 +64,34 @@ export const Value = (args) => html`
|
|
|
62
64
|
</road-grid>
|
|
63
65
|
`;
|
|
64
66
|
|
|
65
|
-
export const
|
|
67
|
+
export const Value = Template.bind({});
|
|
68
|
+
Value.args = {
|
|
69
|
+
elevation: 'average',
|
|
70
|
+
};
|
|
71
|
+
|
|
72
|
+
export const Vehicle = (args) => html`
|
|
66
73
|
<road-grid>
|
|
67
74
|
<road-row>
|
|
68
75
|
<road-col class="col-6 col-md-4 col-lg-3">
|
|
69
|
-
<road-card button value="car" elevation="${ifDefined(args.elevation)}">
|
|
76
|
+
<road-card button value="car" elevation="${ifDefined(args.elevation)}" @roadcardclick=${args.roadcardclick}>
|
|
70
77
|
<road-icon name="vehicle-car" size="3x" role="img"></road-icon>
|
|
71
78
|
<road-label>Car</road-label>
|
|
72
79
|
</road-card>
|
|
73
80
|
</road-col>
|
|
74
81
|
<road-col class="col-6 col-md-4 col-lg-3">
|
|
75
|
-
<road-card button value="4x4" elevation="${ifDefined(args.elevation)}">
|
|
82
|
+
<road-card button value="4x4" elevation="${ifDefined(args.elevation)}" @roadcardclick=${args.roadcardclick}>
|
|
76
83
|
<road-icon name="vehicle-suv" size="3x" role="img"></road-icon>
|
|
77
84
|
<road-label>4x4</road-label>
|
|
78
85
|
</road-card>
|
|
79
86
|
</road-col>
|
|
80
87
|
<road-col class="col-6 col-md-4 col-lg-3">
|
|
81
|
-
<road-card button value="truck" elevation="${ifDefined(args.elevation)}">
|
|
88
|
+
<road-card button value="truck" elevation="${ifDefined(args.elevation)}" @roadcardclick=${args.roadcardclick}>
|
|
82
89
|
<road-icon name="vehicle-pickup-van" size="3x" role="img"></road-icon>
|
|
83
90
|
<road-label>Truck</road-label>
|
|
84
91
|
</road-card>
|
|
85
92
|
</road-col>
|
|
86
93
|
<road-col class="col-6 col-md-4 col-lg-3">
|
|
87
|
-
<road-card button value="bike" elevation="${ifDefined(args.elevation)}">
|
|
94
|
+
<road-card button value="bike" elevation="${ifDefined(args.elevation)}" @roadcardclick=${args.roadcardclick}>
|
|
88
95
|
<road-icon name="vehicle-moto" size="3x" role="img"></road-icon>
|
|
89
96
|
<road-label>Bike</road-label>
|
|
90
97
|
</road-card>
|
|
@@ -92,3 +99,6 @@ export const vehicle = (args) => html`
|
|
|
92
99
|
</road-row>
|
|
93
100
|
</road-grid>
|
|
94
101
|
`;
|
|
102
|
+
Vehicle.args = {
|
|
103
|
+
elevation: 'average',
|
|
104
|
+
};
|
|
@@ -26,328 +26,120 @@ export default {
|
|
|
26
26
|
'roadslidereachstart',
|
|
27
27
|
'roadslidereachend',
|
|
28
28
|
'roadslidetouchstart',
|
|
29
|
-
'roadslidetouchend'
|
|
29
|
+
'roadslidetouchend',
|
|
30
30
|
],
|
|
31
31
|
},
|
|
32
32
|
docs: {
|
|
33
33
|
description: {
|
|
34
|
-
component: `The Carousel component
|
|
34
|
+
component: `The Carousel component uses child components named \`road-carousel-item\` to create different slides, so the content of each slide needs to be inside a \`road-carousel-item\` component.`,
|
|
35
35
|
},
|
|
36
36
|
},
|
|
37
37
|
},
|
|
38
38
|
argTypes: {
|
|
39
39
|
pager: {
|
|
40
40
|
control: 'boolean',
|
|
41
|
+
description: 'Shows pagination bullets below the carousel.',
|
|
41
42
|
},
|
|
42
43
|
arrows: {
|
|
43
44
|
control: 'boolean',
|
|
45
|
+
description: 'Displays navigation arrows for manual slide transitions.',
|
|
44
46
|
},
|
|
45
47
|
options: {
|
|
46
48
|
control: 'object',
|
|
49
|
+
description: 'Configuration object for the Swiper instance.',
|
|
47
50
|
},
|
|
48
51
|
' ': {
|
|
49
52
|
control: 'text',
|
|
53
|
+
description: 'Content inside the carousel, usually multiple `<road-carousel-item>` elements.',
|
|
50
54
|
},
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
type: {
|
|
56
|
-
summary: 'getActiveIndex() => Promise<number>',
|
|
57
|
-
},
|
|
58
|
-
},
|
|
59
|
-
defaultValue: {
|
|
60
|
-
summary: null,
|
|
61
|
-
},
|
|
62
|
-
},
|
|
63
|
-
getPreviousIndex : {
|
|
64
|
-
description: 'Get the index of the previous slide.',
|
|
65
|
-
table: {
|
|
66
|
-
category: 'methods',
|
|
67
|
-
type: {
|
|
68
|
-
summary: 'etPreviousIndex() => Promise<number>',
|
|
69
|
-
},
|
|
70
|
-
},
|
|
71
|
-
defaultValue: {
|
|
72
|
-
summary: null,
|
|
73
|
-
},
|
|
74
|
-
},
|
|
75
|
-
getSwiper : {
|
|
76
|
-
description: 'Get the Swiper instance.\nUse this to access the full Swiper API.\nSee https://idangero.us/swiper/api/ for all API options.',
|
|
77
|
-
table: {
|
|
78
|
-
category: 'methods',
|
|
79
|
-
type: {
|
|
80
|
-
summary: 'getSwiper() => Promise<any>',
|
|
81
|
-
},
|
|
82
|
-
},
|
|
83
|
-
defaultValue: {
|
|
84
|
-
summary: null,
|
|
85
|
-
},
|
|
86
|
-
},
|
|
87
|
-
isBeginning : {
|
|
88
|
-
description: 'Get whether or not the current slide is the first slide.',
|
|
89
|
-
table: {
|
|
90
|
-
category: 'methods',
|
|
91
|
-
type: {
|
|
92
|
-
summary: 'isBeginning() => Promise<boolean>',
|
|
93
|
-
},
|
|
94
|
-
},
|
|
95
|
-
defaultValue: {
|
|
96
|
-
summary: null,
|
|
97
|
-
},
|
|
98
|
-
},
|
|
99
|
-
isEnd : {
|
|
100
|
-
description: 'Get whether or not the current slide is the last slide.',
|
|
101
|
-
table: {
|
|
102
|
-
category: 'methods',
|
|
103
|
-
type: {
|
|
104
|
-
summary: 'isEnd() => Promise<boolean>',
|
|
105
|
-
},
|
|
106
|
-
},
|
|
107
|
-
defaultValue: {
|
|
108
|
-
summary: null,
|
|
109
|
-
},
|
|
110
|
-
},
|
|
111
|
-
length : {
|
|
112
|
-
description: 'Get the total number of slides.',
|
|
113
|
-
table: {
|
|
114
|
-
category: 'methods',
|
|
115
|
-
type: {
|
|
116
|
-
summary: 'length() => Promise<number>',
|
|
117
|
-
},
|
|
118
|
-
},
|
|
119
|
-
defaultValue: {
|
|
120
|
-
summary: null,
|
|
121
|
-
},
|
|
122
|
-
},
|
|
123
|
-
lockSwipeToNext : {
|
|
124
|
-
description: 'Lock or unlock the ability to slide to the next slide.',
|
|
125
|
-
table: {
|
|
126
|
-
category: 'methods',
|
|
127
|
-
type: {
|
|
128
|
-
summary: 'lockSwipeToNext(lock: boolean) => Promise<void>',
|
|
129
|
-
},
|
|
130
|
-
},
|
|
131
|
-
defaultValue: {
|
|
132
|
-
summary: null,
|
|
133
|
-
},
|
|
134
|
-
},
|
|
135
|
-
lockSwipeToPrev : {
|
|
136
|
-
description: 'Lock or unlock the ability to slide to the previous slide.',
|
|
137
|
-
table: {
|
|
138
|
-
category: 'methods',
|
|
139
|
-
type: {
|
|
140
|
-
summary: 'lockSwipeToPrev(lock: boolean) => Promise<void>',
|
|
141
|
-
},
|
|
142
|
-
},
|
|
143
|
-
defaultValue: {
|
|
144
|
-
summary: null,
|
|
145
|
-
},
|
|
146
|
-
},
|
|
147
|
-
lockSwipes : {
|
|
148
|
-
description: 'Lock or unlock the ability to slide to the next or previous slide.',
|
|
149
|
-
table: {
|
|
150
|
-
category: 'methods',
|
|
151
|
-
type: {
|
|
152
|
-
summary: 'lockSwipes(lock: boolean) => Promise<void>',
|
|
153
|
-
},
|
|
154
|
-
},
|
|
155
|
-
defaultValue: {
|
|
156
|
-
summary: null,
|
|
157
|
-
},
|
|
158
|
-
},
|
|
159
|
-
slideNext : {
|
|
160
|
-
description: 'Transition to the next slide.',
|
|
161
|
-
table: {
|
|
162
|
-
category: 'methods',
|
|
163
|
-
type: {
|
|
164
|
-
summary: 'slideNext(speed?: number | undefined, runCallbacks?: boolean | undefined) => Promise<void>',
|
|
165
|
-
},
|
|
166
|
-
},
|
|
167
|
-
defaultValue: {
|
|
168
|
-
summary: null,
|
|
169
|
-
},
|
|
170
|
-
},
|
|
171
|
-
slidePrev : {
|
|
172
|
-
description: 'Transition to the previous slide.',
|
|
173
|
-
table: {
|
|
174
|
-
category: 'methods',
|
|
175
|
-
type: {
|
|
176
|
-
summary: 'slidePrev(speed?: number | undefined, runCallbacks?: boolean | undefined) => Promise<void>',
|
|
177
|
-
},
|
|
178
|
-
},
|
|
179
|
-
defaultValue: {
|
|
180
|
-
summary: null,
|
|
181
|
-
},
|
|
182
|
-
},
|
|
183
|
-
slideTo : {
|
|
184
|
-
description: 'Transition to the specified slide.',
|
|
185
|
-
table: {
|
|
186
|
-
category: 'methods',
|
|
187
|
-
type: {
|
|
188
|
-
summary: 'slideTo(index: number, speed?: number | undefined, runCallbacks?: boolean | undefined) => Promise<void>',
|
|
189
|
-
},
|
|
190
|
-
},
|
|
191
|
-
defaultValue: {
|
|
192
|
-
summary: null,
|
|
193
|
-
},
|
|
55
|
+
// 🔹 Méthodes accessibles depuis Storybook
|
|
56
|
+
getActiveIndex: {
|
|
57
|
+
description: 'Returns the index of the active slide.',
|
|
58
|
+
table: { category: 'Methods', type: { summary: '() => Promise<number>' } },
|
|
194
59
|
},
|
|
195
|
-
|
|
196
|
-
description: '
|
|
197
|
-
table: {
|
|
198
|
-
category: 'methods',
|
|
199
|
-
type: {
|
|
200
|
-
summary: 'startAutoplay() => Promise<void>',
|
|
201
|
-
},
|
|
202
|
-
},
|
|
203
|
-
defaultValue: {
|
|
204
|
-
summary: null,
|
|
205
|
-
},
|
|
206
|
-
},
|
|
207
|
-
stopAutoplay : {
|
|
208
|
-
description: 'Stop auto play.',
|
|
209
|
-
table: {
|
|
210
|
-
category: 'methods',
|
|
211
|
-
type: {
|
|
212
|
-
summary: 'stopAutoplay() => Promise<void>',
|
|
213
|
-
},
|
|
214
|
-
},
|
|
215
|
-
defaultValue: {
|
|
216
|
-
summary: null,
|
|
217
|
-
},
|
|
218
|
-
},
|
|
219
|
-
update : {
|
|
220
|
-
description: 'Update the underlying slider implementation. Call this if you\'ve added or removed\nchild slides.',
|
|
221
|
-
table: {
|
|
222
|
-
category: 'methods',
|
|
223
|
-
type: {
|
|
224
|
-
summary: 'update() => Promise<void>',
|
|
225
|
-
},
|
|
226
|
-
},
|
|
227
|
-
defaultValue: {
|
|
228
|
-
summary: null,
|
|
229
|
-
},
|
|
60
|
+
getPreviousIndex: {
|
|
61
|
+
description: 'Returns the index of the previous slide.',
|
|
62
|
+
table: { category: 'Methods', type: { summary: '() => Promise<number>' } },
|
|
230
63
|
},
|
|
231
|
-
|
|
232
|
-
description: '
|
|
233
|
-
table: {
|
|
234
|
-
category: 'methods',
|
|
235
|
-
type: {
|
|
236
|
-
summary: 'updateAutoHeight(speed?: number | undefined) => Promise<void>',
|
|
237
|
-
},
|
|
238
|
-
},
|
|
239
|
-
defaultValue: {
|
|
240
|
-
summary: null,
|
|
241
|
-
},
|
|
242
|
-
},
|
|
243
|
-
roadslidesdidload: {
|
|
244
|
-
control: {
|
|
245
|
-
type: null,
|
|
246
|
-
},
|
|
247
|
-
},
|
|
248
|
-
roadslidetap: {
|
|
249
|
-
control: {
|
|
250
|
-
type: null,
|
|
251
|
-
},
|
|
252
|
-
},
|
|
253
|
-
roadslidedoubletap: {
|
|
254
|
-
control: {
|
|
255
|
-
type: null,
|
|
256
|
-
},
|
|
64
|
+
getSwiper: {
|
|
65
|
+
description: 'Returns the Swiper instance. See Swiper API for more details.',
|
|
66
|
+
table: { category: 'Methods', type: { summary: '() => Promise<any>' } },
|
|
257
67
|
},
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
},
|
|
68
|
+
isBeginning: {
|
|
69
|
+
description: 'Checks if the current slide is the first slide.',
|
|
70
|
+
table: { category: 'Methods', type: { summary: '() => Promise<boolean>' } },
|
|
262
71
|
},
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
},
|
|
72
|
+
isEnd: {
|
|
73
|
+
description: 'Checks if the current slide is the last slide.',
|
|
74
|
+
table: { category: 'Methods', type: { summary: '() => Promise<boolean>' } },
|
|
267
75
|
},
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
},
|
|
76
|
+
length: {
|
|
77
|
+
description: 'Returns the total number of slides.',
|
|
78
|
+
table: { category: 'Methods', type: { summary: '() => Promise<number>' } },
|
|
272
79
|
},
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
},
|
|
80
|
+
lockSwipeToNext: {
|
|
81
|
+
description: 'Locks the ability to slide to the next slide.',
|
|
82
|
+
table: { category: 'Methods', type: { summary: '(lock: boolean) => Promise<void>' } },
|
|
277
83
|
},
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
},
|
|
84
|
+
lockSwipeToPrev: {
|
|
85
|
+
description: 'Locks the ability to slide to the previous slide.',
|
|
86
|
+
table: { category: 'Methods', type: { summary: '(lock: boolean) => Promise<void>' } },
|
|
282
87
|
},
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
},
|
|
88
|
+
lockSwipes: {
|
|
89
|
+
description: 'Locks the ability to swipe in either direction.',
|
|
90
|
+
table: { category: 'Methods', type: { summary: '(lock: boolean) => Promise<void>' } },
|
|
287
91
|
},
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
},
|
|
92
|
+
slideNext: {
|
|
93
|
+
description: 'Transitions to the next slide.',
|
|
94
|
+
table: { category: 'Methods', type: { summary: '(speed?: number, runCallbacks?: boolean) => Promise<void>' } },
|
|
292
95
|
},
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
},
|
|
96
|
+
slidePrev: {
|
|
97
|
+
description: 'Transitions to the previous slide.',
|
|
98
|
+
table: { category: 'Methods', type: { summary: '(speed?: number, runCallbacks?: boolean) => Promise<void>' } },
|
|
297
99
|
},
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
},
|
|
100
|
+
slideTo: {
|
|
101
|
+
description: 'Transitions to a specified slide index.',
|
|
102
|
+
table: { category: 'Methods', type: { summary: '(index: number, speed?: number, runCallbacks?: boolean) => Promise<void>' } },
|
|
302
103
|
},
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
},
|
|
104
|
+
startAutoplay: {
|
|
105
|
+
description: 'Starts automatic slide transition.',
|
|
106
|
+
table: { category: 'Methods', type: { summary: '() => Promise<void>' } },
|
|
307
107
|
},
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
},
|
|
108
|
+
stopAutoplay: {
|
|
109
|
+
description: 'Stops automatic slide transition.',
|
|
110
|
+
table: { category: 'Methods', type: { summary: '() => Promise<void>' } },
|
|
312
111
|
},
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
},
|
|
112
|
+
update: {
|
|
113
|
+
description: 'Updates the carousel when slides are added or removed.',
|
|
114
|
+
table: { category: 'Methods', type: { summary: '() => Promise<void>' } },
|
|
317
115
|
},
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
},
|
|
116
|
+
updateAutoHeight: {
|
|
117
|
+
description: 'Updates carousel height when `autoHeight` is enabled.',
|
|
118
|
+
table: { category: 'Methods', type: { summary: '(speed?: number) => Promise<void>' } },
|
|
322
119
|
},
|
|
323
120
|
},
|
|
324
121
|
args: {
|
|
325
|
-
pager:
|
|
326
|
-
arrows:
|
|
327
|
-
' ':
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
<road-carousel-item>
|
|
340
|
-
<road-img src="https://s1.medias-norauto.fr/visuals/desktop/fr/banners/FR-SLIDE-OP-P1-24-climv2.jpg" alt="roof bar on car"></road-img>
|
|
341
|
-
</road-carousel-item>
|
|
342
|
-
|
|
343
|
-
<road-carousel-item>
|
|
344
|
-
<road-img src="https://s1.medias-norauto.fr/visuals/desktop/fr/banners/FR-SLIDE-OP-Pneu-1er-prix-Fev24.png" alt="roof bar diagram"></road-img>
|
|
345
|
-
</road-carousel-item>`,
|
|
122
|
+
pager: false,
|
|
123
|
+
arrows: false,
|
|
124
|
+
' ': `
|
|
125
|
+
<road-carousel-item>
|
|
126
|
+
<road-img src="https://via.placeholder.com/800x400?text=Slide+1" alt="Slide 1"></road-img>
|
|
127
|
+
</road-carousel-item>
|
|
128
|
+
<road-carousel-item>
|
|
129
|
+
<road-img src="https://via.placeholder.com/800x400?text=Slide+2" alt="Slide 2"></road-img>
|
|
130
|
+
</road-carousel-item>
|
|
131
|
+
<road-carousel-item>
|
|
132
|
+
<road-img src="https://via.placeholder.com/800x400?text=Slide+3" alt="Slide 3"></road-img>
|
|
133
|
+
</road-carousel-item>
|
|
134
|
+
`,
|
|
346
135
|
},
|
|
347
136
|
};
|
|
348
137
|
|
|
349
138
|
const Template = (args) => html`
|
|
350
|
-
<road-carousel
|
|
139
|
+
<road-carousel
|
|
140
|
+
?pager="${args.pager}"
|
|
141
|
+
?arrows="${args.arrows}"
|
|
142
|
+
.options="${args.options}">
|
|
351
143
|
${unsafeHTML(args[' '])}
|
|
352
144
|
</road-carousel>
|
|
353
145
|
`;
|