@aurodesignsystem-dev/auro-slideshow 0.0.0-pr80.0 → 0.0.0-pr80.2

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/index.d.ts CHANGED
@@ -77,89 +77,93 @@ type BaseProps<T extends HTMLElement> = {
77
77
  type BaseEvents = {};
78
78
 
79
79
  export type AuroSlideshowProps = {
80
- /** If true, the slideshow will play automatically. */
80
+ /** Adds a play and pause button and moves to the next slide after each `delay`. The slideshow starts playing on page load only when `playOnInit` is also set. */
81
81
  autoplay?: AuroSlideshow["autoplay"];
82
- /** If true, the slideshow will scroll continuously. */
82
+ /** Scrolls the slides at a steady pace instead of stopping on each slide, and adds a play and pause button. The slideshow starts scrolling on page load only when `playOnInit` is also set. Doesn't apply on touch devices (those with a coarse primary pointer), and `autoplay` takes priority when both are set. */
83
83
  autoscroll?: AuroSlideshow["autoScroll"];
84
- /** If true, the slideshow will scroll continuously. */
84
+ /** Scrolls the slides at a steady pace instead of stopping on each slide, and adds a play and pause button. The slideshow starts scrolling on page load only when `playOnInit` is also set. Doesn't apply on touch devices (those with a coarse primary pointer), and `autoplay` takes priority when both are set. */
85
85
  autoScroll?: AuroSlideshow["autoScroll"];
86
- /** Slide duration in milliseconds (Only used with `autoplay`). */
86
+ /** Sets how long each slide shows before the slideshow moves to the next one, in milliseconds. Applies only when `autoplay` is set. */
87
87
  delay?: AuroSlideshow["delay"];
88
- /** If set, the slideshow will take up the width of its parent container showing previous and next slides. **Note:** a parent container must have `overflow-x: hidden` to prevent horizontal scrolling. */
88
+ /** Stretches the slideshow to the full width of the browser window, so parts of the previous and next slides show beside the current slide. Each slide stays as wide as the slideshow's container. To prevent horizontal scrolling, set `overflow-x: hidden` on a parent container. */
89
89
  fullbleed?: AuroSlideshow["fullBleed"];
90
- /** If set, the slideshow will take up the width of its parent container showing previous and next slides. **Note:** a parent container must have `overflow-x: hidden` to prevent horizontal scrolling. */
90
+ /** Stretches the slideshow to the full width of the browser window, so parts of the previous and next slides show beside the current slide. Each slide stays as wide as the slideshow's container. To prevent horizontal scrolling, set `overflow-x: hidden` on a parent container. */
91
91
  fullBleed?: AuroSlideshow["fullBleed"];
92
- /** If true, the slideshow will loop back to the first slide after reaching the last slide. */
92
+ /** Goes back to the first slide after the last slide instead of stopping at the end. When `loop` isn't set, `autoplay` and `autoScroll` stop on the last slide. */
93
93
  loop?: AuroSlideshow["loop"];
94
- /** If true, the slideshow will display navigation arrows for previous and next slides when the slide container is hovered. */
94
+ /** Shows previous and next arrow buttons when the slides are hovered. When `loop` isn't set, the arrow for a direction is hidden at the first or last slide. The arrows don't appear on touch devices, where the primary pointer is coarse. */
95
95
  navigation?: AuroSlideshow["navigation"];
96
- /** If true, the slideshow will display pagination dots for each slide. If autoplay is on, the active dot will also show a progress bar. */
96
+ /** Shows a dot for each slide, with a wider dot for the current slide. When `autoplay` is set, the current dot also shows a progress bar. */
97
97
  pagination?: AuroSlideshow["pagination"];
98
- /** If true, the slideshow will start playing automatically on page load when `autoplay` or `autoScroll` are on. */
98
+ /** Starts playback when the slideshow loads. Applies only when `autoplay` or `autoScroll` is set. */
99
99
  playoninit?: AuroSlideshow["playOnInit"];
100
- /** If true, the slideshow will start playing automatically on page load when `autoplay` or `autoScroll` are on. */
100
+ /** Starts playback when the slideshow loads. Applies only when `autoplay` or `autoScroll` is set. */
101
101
  playOnInit?: AuroSlideshow["playOnInit"];
102
- /** Number of pixels auto scroll should advance per frame (Only used with `autoScroll`). */
102
+ /** Sets how fast the slides scroll, in pixels per frame. Use a higher number to scroll faster. Applies only when `autoScroll` is set. */
103
103
  scrollspeed?: AuroSlideshow["scrollSpeed"];
104
- /** Number of pixels auto scroll should advance per frame (Only used with `autoScroll`). */
104
+ /** Sets how fast the slides scroll, in pixels per frame. Use a higher number to scroll faster. Applies only when `autoScroll` is set. */
105
105
  scrollSpeed?: AuroSlideshow["scrollSpeed"];
106
- /** Delay in milliseconds before the auto scroll starts (Only used with `autoScroll`). */
106
+ /** Sets how long the slideshow waits before it starts or resumes scrolling, in milliseconds. Applies only when `autoScroll` is set. */
107
107
  startdelay?: AuroSlideshow["startDelay"];
108
- /** Delay in milliseconds before the auto scroll starts (Only used with `autoScroll`). */
108
+ /** Sets how long the slideshow waits before it starts or resumes scrolling, in milliseconds. Applies only when `autoScroll` is set. */
109
109
  startDelay?: AuroSlideshow["startDelay"];
110
- /** @deprecated Use `ariaLabel.slideshow.pause` instead. - Accessible label for the pause button. **Deprecated:** use `ariaLabel.slideshow.pause` instead. */
110
+ /** @deprecated Use `ariaLabel.slideshow.pause` instead. - Deprecated: Use `ariaLabel.slideshow.pause` instead.
111
+ Sets the text screen readers announce for the pause button. Used only when the `ariaLabel.slideshow.pause` slot is empty. */
111
112
  pauselabel?: AuroSlideshow["pauseLabel"];
112
- /** @deprecated Use `ariaLabel.slideshow.pause` instead. - Accessible label for the pause button. **Deprecated:** use `ariaLabel.slideshow.pause` instead. */
113
+ /** @deprecated Use `ariaLabel.slideshow.pause` instead. - Deprecated: Use `ariaLabel.slideshow.pause` instead.
114
+ Sets the text screen readers announce for the pause button. Used only when the `ariaLabel.slideshow.pause` slot is empty. */
113
115
  pauseLabel?: AuroSlideshow["pauseLabel"];
114
- /** @deprecated Use `ariaLabel.slideshow.play` instead. - Accessible label for the play button. **Deprecated:** use `ariaLabel.slideshow.play` instead. */
116
+ /** @deprecated Use `ariaLabel.slideshow.play` instead. - Deprecated: Use `ariaLabel.slideshow.play` instead.
117
+ Sets the text screen readers announce for the play button. Used only when the `ariaLabel.slideshow.play` slot is empty. */
115
118
  playlabel?: AuroSlideshow["playLabel"];
116
- /** @deprecated Use `ariaLabel.slideshow.play` instead. - Accessible label for the play button. **Deprecated:** use `ariaLabel.slideshow.play` instead. */
119
+ /** @deprecated Use `ariaLabel.slideshow.play` instead. - Deprecated: Use `ariaLabel.slideshow.play` instead.
120
+ Sets the text screen readers announce for the play button. Used only when the `ariaLabel.slideshow.play` slot is empty. */
117
121
  playLabel?: AuroSlideshow["playLabel"];
118
- /** Calculate the width of the slideshow-wrapper and attach a css property to the host element '--slideshow-width' */
119
- _createWidthProp?: AuroSlideshow["_createWidthProp"];
120
122
  };
121
123
 
122
124
  export type AuroSlideshowSolidJsProps = {
123
- /** If true, the slideshow will play automatically. */
125
+ /** Adds a play and pause button and moves to the next slide after each `delay`. The slideshow starts playing on page load only when `playOnInit` is also set. */
124
126
  "prop:autoplay"?: AuroSlideshow["autoplay"];
125
- /** If true, the slideshow will scroll continuously. */
127
+ /** Scrolls the slides at a steady pace instead of stopping on each slide, and adds a play and pause button. The slideshow starts scrolling on page load only when `playOnInit` is also set. Doesn't apply on touch devices (those with a coarse primary pointer), and `autoplay` takes priority when both are set. */
126
128
  "bool:autoscroll"?: AuroSlideshow["autoScroll"];
127
- /** If true, the slideshow will scroll continuously. */
129
+ /** Scrolls the slides at a steady pace instead of stopping on each slide, and adds a play and pause button. The slideshow starts scrolling on page load only when `playOnInit` is also set. Doesn't apply on touch devices (those with a coarse primary pointer), and `autoplay` takes priority when both are set. */
128
130
  "prop:autoScroll"?: AuroSlideshow["autoScroll"];
129
- /** Slide duration in milliseconds (Only used with `autoplay`). */
131
+ /** Sets how long each slide shows before the slideshow moves to the next one, in milliseconds. Applies only when `autoplay` is set. */
130
132
  "prop:delay"?: AuroSlideshow["delay"];
131
- /** If set, the slideshow will take up the width of its parent container showing previous and next slides. **Note:** a parent container must have `overflow-x: hidden` to prevent horizontal scrolling. */
133
+ /** Stretches the slideshow to the full width of the browser window, so parts of the previous and next slides show beside the current slide. Each slide stays as wide as the slideshow's container. To prevent horizontal scrolling, set `overflow-x: hidden` on a parent container. */
132
134
  "bool:fullbleed"?: AuroSlideshow["fullBleed"];
133
- /** If set, the slideshow will take up the width of its parent container showing previous and next slides. **Note:** a parent container must have `overflow-x: hidden` to prevent horizontal scrolling. */
135
+ /** Stretches the slideshow to the full width of the browser window, so parts of the previous and next slides show beside the current slide. Each slide stays as wide as the slideshow's container. To prevent horizontal scrolling, set `overflow-x: hidden` on a parent container. */
134
136
  "prop:fullBleed"?: AuroSlideshow["fullBleed"];
135
- /** If true, the slideshow will loop back to the first slide after reaching the last slide. */
137
+ /** Goes back to the first slide after the last slide instead of stopping at the end. When `loop` isn't set, `autoplay` and `autoScroll` stop on the last slide. */
136
138
  "prop:loop"?: AuroSlideshow["loop"];
137
- /** If true, the slideshow will display navigation arrows for previous and next slides when the slide container is hovered. */
139
+ /** Shows previous and next arrow buttons when the slides are hovered. When `loop` isn't set, the arrow for a direction is hidden at the first or last slide. The arrows don't appear on touch devices, where the primary pointer is coarse. */
138
140
  "prop:navigation"?: AuroSlideshow["navigation"];
139
- /** If true, the slideshow will display pagination dots for each slide. If autoplay is on, the active dot will also show a progress bar. */
141
+ /** Shows a dot for each slide, with a wider dot for the current slide. When `autoplay` is set, the current dot also shows a progress bar. */
140
142
  "prop:pagination"?: AuroSlideshow["pagination"];
141
- /** If true, the slideshow will start playing automatically on page load when `autoplay` or `autoScroll` are on. */
143
+ /** Starts playback when the slideshow loads. Applies only when `autoplay` or `autoScroll` is set. */
142
144
  "bool:playoninit"?: AuroSlideshow["playOnInit"];
143
- /** If true, the slideshow will start playing automatically on page load when `autoplay` or `autoScroll` are on. */
145
+ /** Starts playback when the slideshow loads. Applies only when `autoplay` or `autoScroll` is set. */
144
146
  "prop:playOnInit"?: AuroSlideshow["playOnInit"];
145
- /** Number of pixels auto scroll should advance per frame (Only used with `autoScroll`). */
147
+ /** Sets how fast the slides scroll, in pixels per frame. Use a higher number to scroll faster. Applies only when `autoScroll` is set. */
146
148
  "attr:scrollspeed"?: AuroSlideshow["scrollSpeed"];
147
- /** Number of pixels auto scroll should advance per frame (Only used with `autoScroll`). */
149
+ /** Sets how fast the slides scroll, in pixels per frame. Use a higher number to scroll faster. Applies only when `autoScroll` is set. */
148
150
  "prop:scrollSpeed"?: AuroSlideshow["scrollSpeed"];
149
- /** Delay in milliseconds before the auto scroll starts (Only used with `autoScroll`). */
151
+ /** Sets how long the slideshow waits before it starts or resumes scrolling, in milliseconds. Applies only when `autoScroll` is set. */
150
152
  "attr:startdelay"?: AuroSlideshow["startDelay"];
151
- /** Delay in milliseconds before the auto scroll starts (Only used with `autoScroll`). */
153
+ /** Sets how long the slideshow waits before it starts or resumes scrolling, in milliseconds. Applies only when `autoScroll` is set. */
152
154
  "prop:startDelay"?: AuroSlideshow["startDelay"];
153
- /** @deprecated Use `ariaLabel.slideshow.pause` instead. - Accessible label for the pause button. **Deprecated:** use `ariaLabel.slideshow.pause` instead. */
155
+ /** @deprecated Use `ariaLabel.slideshow.pause` instead. - Deprecated: Use `ariaLabel.slideshow.pause` instead.
156
+ Sets the text screen readers announce for the pause button. Used only when the `ariaLabel.slideshow.pause` slot is empty. */
154
157
  "attr:pauselabel"?: AuroSlideshow["pauseLabel"];
155
- /** @deprecated Use `ariaLabel.slideshow.pause` instead. - Accessible label for the pause button. **Deprecated:** use `ariaLabel.slideshow.pause` instead. */
158
+ /** @deprecated Use `ariaLabel.slideshow.pause` instead. - Deprecated: Use `ariaLabel.slideshow.pause` instead.
159
+ Sets the text screen readers announce for the pause button. Used only when the `ariaLabel.slideshow.pause` slot is empty. */
156
160
  "prop:pauseLabel"?: AuroSlideshow["pauseLabel"];
157
- /** @deprecated Use `ariaLabel.slideshow.play` instead. - Accessible label for the play button. **Deprecated:** use `ariaLabel.slideshow.play` instead. */
161
+ /** @deprecated Use `ariaLabel.slideshow.play` instead. - Deprecated: Use `ariaLabel.slideshow.play` instead.
162
+ Sets the text screen readers announce for the play button. Used only when the `ariaLabel.slideshow.play` slot is empty. */
158
163
  "attr:playlabel"?: AuroSlideshow["playLabel"];
159
- /** @deprecated Use `ariaLabel.slideshow.play` instead. - Accessible label for the play button. **Deprecated:** use `ariaLabel.slideshow.play` instead. */
164
+ /** @deprecated Use `ariaLabel.slideshow.play` instead. - Deprecated: Use `ariaLabel.slideshow.play` instead.
165
+ Sets the text screen readers announce for the play button. Used only when the `ariaLabel.slideshow.play` slot is empty. */
160
166
  "prop:playLabel"?: AuroSlideshow["playLabel"];
161
- /** Calculate the width of the slideshow-wrapper and attach a css property to the host element '--slideshow-width' */
162
- "prop:_createWidthProp"?: AuroSlideshow["_createWidthProp"];
163
167
 
164
168
  /** Set the innerHTML of the element */
165
169
  innerHTML?: string;
@@ -169,27 +173,42 @@ export type AuroSlideshowSolidJsProps = {
169
173
 
170
174
  export type CustomElements = {
171
175
  /**
172
- * The `auro-slideshow` element is a customizable slideshow that displays a series of slides
173
- * with several options such as autoplay, navigation controls, and pagination dots.
176
+ * A slideshow for presenting a series of images or other content in a space-saving way, with manual controls or automatic advancing.
177
+ *
178
+ * **Key capabilities**
179
+ * - **Autoplay**: Set `autoplay` to move to the next slide after each `delay`.
180
+ * - **Continuous scroll**: Set `autoScroll` to scroll the slides at a steady pace.
181
+ * - **Navigation arrows**: Set `navigation` to show previous and next arrows when the slides are hovered.
182
+ * - **Pagination dots**: Set `pagination` to show a dot for each slide.
183
+ * - **Looping**: Set `loop` to return to the first slide after the last.
184
+ * - **Full-bleed preview**: Set `fullBleed` to show parts of the previous and next slides.
185
+ *
186
+ * **Example**
187
+ * ```html
188
+ * <auro-slideshow navigation pagination>
189
+ * <div style="height: 480px">Slide 1</div>
190
+ * <div style="height: 480px">Slide 2</div>
191
+ * </auro-slideshow>
192
+ * ```
174
193
  *
175
194
  * ## Attributes & Properties
176
195
  *
177
196
  * Component attributes and properties that can be applied to the element or by using JavaScript.
178
197
  *
179
- * - `autoplay`: If true, the slideshow will play automatically.
180
- * - `autoscroll`/`autoScroll`: If true, the slideshow will scroll continuously.
181
- * - `delay`: Slide duration in milliseconds (Only used with `autoplay`).
182
- * - `fullbleed`/`fullBleed`: If set, the slideshow will take up the width of its parent container showing previous and next slides. **Note:** a parent container must have `overflow-x: hidden` to prevent horizontal scrolling.
183
- * - `loop`: If true, the slideshow will loop back to the first slide after reaching the last slide.
184
- * - `navigation`: If true, the slideshow will display navigation arrows for previous and next slides when the slide container is hovered.
185
- * - `pagination`: If true, the slideshow will display pagination dots for each slide. If autoplay is on, the active dot will also show a progress bar.
186
- * - `playoninit`/`playOnInit`: If true, the slideshow will start playing automatically on page load when `autoplay` or `autoScroll` are on.
187
- * - `scrollspeed`/`scrollSpeed`: Number of pixels auto scroll should advance per frame (Only used with `autoScroll`).
188
- * - `startdelay`/`startDelay`: Delay in milliseconds before the auto scroll starts (Only used with `autoScroll`).
189
- * - `pauselabel`/`pauseLabel`: Accessible label for the pause button. **Deprecated:** use `ariaLabel.slideshow.pause` instead.
190
- * - `playlabel`/`playLabel`: Accessible label for the play button. **Deprecated:** use `ariaLabel.slideshow.play` instead.
191
- * - `_createWidthProp`: Calculate the width of the slideshow-wrapper and attach a css property to the host element '--slideshow-width' (property only)
192
- * - `_customAlign`: Calculate the difference between the left edge of the slideshow-wrapper and the embla container (property only) (readonly)
198
+ * - `autoplay`: Adds a play and pause button and moves to the next slide after each `delay`. The slideshow starts playing on page load only when `playOnInit` is also set.
199
+ * - `autoscroll`/`autoScroll`: Scrolls the slides at a steady pace instead of stopping on each slide, and adds a play and pause button. The slideshow starts scrolling on page load only when `playOnInit` is also set. Doesn't apply on touch devices (those with a coarse primary pointer), and `autoplay` takes priority when both are set.
200
+ * - `delay`: Sets how long each slide shows before the slideshow moves to the next one, in milliseconds. Applies only when `autoplay` is set.
201
+ * - `fullbleed`/`fullBleed`: Stretches the slideshow to the full width of the browser window, so parts of the previous and next slides show beside the current slide. Each slide stays as wide as the slideshow's container. To prevent horizontal scrolling, set `overflow-x: hidden` on a parent container.
202
+ * - `loop`: Goes back to the first slide after the last slide instead of stopping at the end. When `loop` isn't set, `autoplay` and `autoScroll` stop on the last slide.
203
+ * - `navigation`: Shows previous and next arrow buttons when the slides are hovered. When `loop` isn't set, the arrow for a direction is hidden at the first or last slide. The arrows don't appear on touch devices, where the primary pointer is coarse.
204
+ * - `pagination`: Shows a dot for each slide, with a wider dot for the current slide. When `autoplay` is set, the current dot also shows a progress bar.
205
+ * - `playoninit`/`playOnInit`: Starts playback when the slideshow loads. Applies only when `autoplay` or `autoScroll` is set.
206
+ * - `scrollspeed`/`scrollSpeed`: Sets how fast the slides scroll, in pixels per frame. Use a higher number to scroll faster. Applies only when `autoScroll` is set.
207
+ * - `startdelay`/`startDelay`: Sets how long the slideshow waits before it starts or resumes scrolling, in milliseconds. Applies only when `autoScroll` is set.
208
+ * - `pauselabel`/`pauseLabel`: Deprecated: Use `ariaLabel.slideshow.pause` instead.
209
+ * Sets the text screen readers announce for the pause button. Used only when the `ariaLabel.slideshow.pause` slot is empty.
210
+ * - `playlabel`/`playLabel`: Deprecated: Use `ariaLabel.slideshow.play` instead.
211
+ * Sets the text screen readers announce for the play button. Used only when the `ariaLabel.slideshow.play` slot is empty.
193
212
  * - `_dotsNode`: undefined (property only) (readonly)
194
213
  * - `_nextBtn`: undefined (property only) (readonly)
195
214
  * - `_playBtn`: undefined (property only) (readonly)
@@ -203,30 +222,30 @@ export type CustomElements = {
203
222
  *
204
223
  * Areas where markup can be added to the component.
205
224
  *
206
- * - `(default)`: Default slot for the slides. Each child element will be treated as a slide.
207
- * - `ariaLabel.scroll.left`: The aria-label for the button navigating to the previous slide. Default is "Previous slide".
208
- * - `ariaLabel.scroll.right`: The aria-label for the button navigating to the next slide. Default is "Next slide".
209
- * - `ariaLabel.slideshow.pause`: The aria-label for the button that pauses the slideshow. Default is "Pause slideshow".
210
- * - `ariaLabel.slideshow.play`: The aria-label for the button that starts the slideshow. Default is "Play slideshow".
225
+ * - `(default)`: The slides. Each direct child element becomes one slide.
226
+ * - `ariaLabel.scroll.left`: Text screen readers announce for the previous slide button. Defaults to "Previous slide".
227
+ * - `ariaLabel.scroll.right`: Text screen readers announce for the next slide button. Defaults to "Next slide".
228
+ * - `ariaLabel.slideshow.pause`: Text screen readers announce for the button that pauses the slideshow. Defaults to "Pause slideshow".
229
+ * - `ariaLabel.slideshow.play`: Text screen readers announce for the button that starts the slideshow. Defaults to "Play slideshow".
211
230
  *
212
231
  * ## Methods
213
232
  *
214
233
  * Methods that can be called to access component functionality.
215
234
  *
216
235
  * - `_initializeDefaults() => void`: undefined
217
- * - `play() => void`: Starts the slideshow playback.
236
+ * - `play() => void`: Starts automatic playback. Does nothing unless `autoplay` or `autoScroll` is set.
218
237
  * - `register(name?: string = "auro-slideshow") => void`: Registers the custom element with the browser.
219
238
  * - `scrollNext() => void`: Scrolls to the next slide.
220
239
  * - `scrollPrev() => void`: Scrolls to the previous slide.
221
- * - `stop() => void`: Stops the slideshow playback.
240
+ * - `stop() => void`: Stops automatic playback. Does nothing unless `autoplay` or `autoScroll` is set.
222
241
  *
223
242
  * ## CSS Parts
224
243
  *
225
244
  * Custom selectors for styling elements within the component.
226
245
  *
227
- * - `next-button`: Use to style the next button control.
228
- * - `play-pause-button`: Use to style the play/pause button control.
229
- * - `prev-button`: Use to style the previous button control.
246
+ * - `next-button`: The button that goes to the next slide, shown when `navigation` is set, except on touch devices.
247
+ * - `play-pause-button`: The button that plays and pauses the slideshow, shown when `autoplay` is set, or when `autoScroll` is set on a device that isn't a touch device.
248
+ * - `prev-button`: The button that goes to the previous slide, shown when `navigation` is set, except on touch devices.
230
249
  */
231
250
  "auro-slideshow": Partial<
232
251
  AuroSlideshowProps & BaseProps<AuroSlideshow> & BaseEvents
@@ -235,27 +254,42 @@ export type CustomElements = {
235
254
 
236
255
  export type CustomElementsSolidJs = {
237
256
  /**
238
- * The `auro-slideshow` element is a customizable slideshow that displays a series of slides
239
- * with several options such as autoplay, navigation controls, and pagination dots.
257
+ * A slideshow for presenting a series of images or other content in a space-saving way, with manual controls or automatic advancing.
258
+ *
259
+ * **Key capabilities**
260
+ * - **Autoplay**: Set `autoplay` to move to the next slide after each `delay`.
261
+ * - **Continuous scroll**: Set `autoScroll` to scroll the slides at a steady pace.
262
+ * - **Navigation arrows**: Set `navigation` to show previous and next arrows when the slides are hovered.
263
+ * - **Pagination dots**: Set `pagination` to show a dot for each slide.
264
+ * - **Looping**: Set `loop` to return to the first slide after the last.
265
+ * - **Full-bleed preview**: Set `fullBleed` to show parts of the previous and next slides.
266
+ *
267
+ * **Example**
268
+ * ```html
269
+ * <auro-slideshow navigation pagination>
270
+ * <div style="height: 480px">Slide 1</div>
271
+ * <div style="height: 480px">Slide 2</div>
272
+ * </auro-slideshow>
273
+ * ```
240
274
  *
241
275
  * ## Attributes & Properties
242
276
  *
243
277
  * Component attributes and properties that can be applied to the element or by using JavaScript.
244
278
  *
245
- * - `autoplay`: If true, the slideshow will play automatically.
246
- * - `autoscroll`/`autoScroll`: If true, the slideshow will scroll continuously.
247
- * - `delay`: Slide duration in milliseconds (Only used with `autoplay`).
248
- * - `fullbleed`/`fullBleed`: If set, the slideshow will take up the width of its parent container showing previous and next slides. **Note:** a parent container must have `overflow-x: hidden` to prevent horizontal scrolling.
249
- * - `loop`: If true, the slideshow will loop back to the first slide after reaching the last slide.
250
- * - `navigation`: If true, the slideshow will display navigation arrows for previous and next slides when the slide container is hovered.
251
- * - `pagination`: If true, the slideshow will display pagination dots for each slide. If autoplay is on, the active dot will also show a progress bar.
252
- * - `playoninit`/`playOnInit`: If true, the slideshow will start playing automatically on page load when `autoplay` or `autoScroll` are on.
253
- * - `scrollspeed`/`scrollSpeed`: Number of pixels auto scroll should advance per frame (Only used with `autoScroll`).
254
- * - `startdelay`/`startDelay`: Delay in milliseconds before the auto scroll starts (Only used with `autoScroll`).
255
- * - `pauselabel`/`pauseLabel`: Accessible label for the pause button. **Deprecated:** use `ariaLabel.slideshow.pause` instead.
256
- * - `playlabel`/`playLabel`: Accessible label for the play button. **Deprecated:** use `ariaLabel.slideshow.play` instead.
257
- * - `_createWidthProp`: Calculate the width of the slideshow-wrapper and attach a css property to the host element '--slideshow-width' (property only)
258
- * - `_customAlign`: Calculate the difference between the left edge of the slideshow-wrapper and the embla container (property only) (readonly)
279
+ * - `autoplay`: Adds a play and pause button and moves to the next slide after each `delay`. The slideshow starts playing on page load only when `playOnInit` is also set.
280
+ * - `autoscroll`/`autoScroll`: Scrolls the slides at a steady pace instead of stopping on each slide, and adds a play and pause button. The slideshow starts scrolling on page load only when `playOnInit` is also set. Doesn't apply on touch devices (those with a coarse primary pointer), and `autoplay` takes priority when both are set.
281
+ * - `delay`: Sets how long each slide shows before the slideshow moves to the next one, in milliseconds. Applies only when `autoplay` is set.
282
+ * - `fullbleed`/`fullBleed`: Stretches the slideshow to the full width of the browser window, so parts of the previous and next slides show beside the current slide. Each slide stays as wide as the slideshow's container. To prevent horizontal scrolling, set `overflow-x: hidden` on a parent container.
283
+ * - `loop`: Goes back to the first slide after the last slide instead of stopping at the end. When `loop` isn't set, `autoplay` and `autoScroll` stop on the last slide.
284
+ * - `navigation`: Shows previous and next arrow buttons when the slides are hovered. When `loop` isn't set, the arrow for a direction is hidden at the first or last slide. The arrows don't appear on touch devices, where the primary pointer is coarse.
285
+ * - `pagination`: Shows a dot for each slide, with a wider dot for the current slide. When `autoplay` is set, the current dot also shows a progress bar.
286
+ * - `playoninit`/`playOnInit`: Starts playback when the slideshow loads. Applies only when `autoplay` or `autoScroll` is set.
287
+ * - `scrollspeed`/`scrollSpeed`: Sets how fast the slides scroll, in pixels per frame. Use a higher number to scroll faster. Applies only when `autoScroll` is set.
288
+ * - `startdelay`/`startDelay`: Sets how long the slideshow waits before it starts or resumes scrolling, in milliseconds. Applies only when `autoScroll` is set.
289
+ * - `pauselabel`/`pauseLabel`: Deprecated: Use `ariaLabel.slideshow.pause` instead.
290
+ * Sets the text screen readers announce for the pause button. Used only when the `ariaLabel.slideshow.pause` slot is empty.
291
+ * - `playlabel`/`playLabel`: Deprecated: Use `ariaLabel.slideshow.play` instead.
292
+ * Sets the text screen readers announce for the play button. Used only when the `ariaLabel.slideshow.play` slot is empty.
259
293
  * - `_dotsNode`: undefined (property only) (readonly)
260
294
  * - `_nextBtn`: undefined (property only) (readonly)
261
295
  * - `_playBtn`: undefined (property only) (readonly)
@@ -269,30 +303,30 @@ export type CustomElementsSolidJs = {
269
303
  *
270
304
  * Areas where markup can be added to the component.
271
305
  *
272
- * - `(default)`: Default slot for the slides. Each child element will be treated as a slide.
273
- * - `ariaLabel.scroll.left`: The aria-label for the button navigating to the previous slide. Default is "Previous slide".
274
- * - `ariaLabel.scroll.right`: The aria-label for the button navigating to the next slide. Default is "Next slide".
275
- * - `ariaLabel.slideshow.pause`: The aria-label for the button that pauses the slideshow. Default is "Pause slideshow".
276
- * - `ariaLabel.slideshow.play`: The aria-label for the button that starts the slideshow. Default is "Play slideshow".
306
+ * - `(default)`: The slides. Each direct child element becomes one slide.
307
+ * - `ariaLabel.scroll.left`: Text screen readers announce for the previous slide button. Defaults to "Previous slide".
308
+ * - `ariaLabel.scroll.right`: Text screen readers announce for the next slide button. Defaults to "Next slide".
309
+ * - `ariaLabel.slideshow.pause`: Text screen readers announce for the button that pauses the slideshow. Defaults to "Pause slideshow".
310
+ * - `ariaLabel.slideshow.play`: Text screen readers announce for the button that starts the slideshow. Defaults to "Play slideshow".
277
311
  *
278
312
  * ## Methods
279
313
  *
280
314
  * Methods that can be called to access component functionality.
281
315
  *
282
316
  * - `_initializeDefaults() => void`: undefined
283
- * - `play() => void`: Starts the slideshow playback.
317
+ * - `play() => void`: Starts automatic playback. Does nothing unless `autoplay` or `autoScroll` is set.
284
318
  * - `register(name?: string = "auro-slideshow") => void`: Registers the custom element with the browser.
285
319
  * - `scrollNext() => void`: Scrolls to the next slide.
286
320
  * - `scrollPrev() => void`: Scrolls to the previous slide.
287
- * - `stop() => void`: Stops the slideshow playback.
321
+ * - `stop() => void`: Stops automatic playback. Does nothing unless `autoplay` or `autoScroll` is set.
288
322
  *
289
323
  * ## CSS Parts
290
324
  *
291
325
  * Custom selectors for styling elements within the component.
292
326
  *
293
- * - `next-button`: Use to style the next button control.
294
- * - `play-pause-button`: Use to style the play/pause button control.
295
- * - `prev-button`: Use to style the previous button control.
327
+ * - `next-button`: The button that goes to the next slide, shown when `navigation` is set, except on touch devices.
328
+ * - `play-pause-button`: The button that plays and pauses the slideshow, shown when `autoplay` is set, or when `autoScroll` is set on a device that isn't a touch device.
329
+ * - `prev-button`: The button that goes to the previous slide, shown when `navigation` is set, except on touch devices.
296
330
  */
297
331
  "auro-slideshow": Partial<
298
332
  AuroSlideshowProps &
package/dist/index.js CHANGED
@@ -1 +1 @@
1
- export{A as AuroSlideshow}from"./auro-slideshow-Di9AtYIy.js";import"lit";import"lit/static-html.js";import"lit/directives/class-map.js";import"lit/directives/if-defined.js";
1
+ export{A as AuroSlideshow}from"./auro-slideshow-1sJeRJNM.js";import"lit";import"lit/static-html.js";import"lit/directives/class-map.js";import"lit/directives/if-defined.js";
@@ -1 +1 @@
1
- import{A as i}from"./auro-slideshow-Di9AtYIy.js";import"lit";import"lit/static-html.js";import"lit/directives/class-map.js";import"lit/directives/if-defined.js";i.register();
1
+ import{A as i}from"./auro-slideshow-1sJeRJNM.js";import"lit";import"lit/static-html.js";import"lit/directives/class-map.js";import"lit/directives/if-defined.js";i.register();
package/package.json CHANGED
@@ -7,7 +7,7 @@
7
7
  "================================================================================"
8
8
  ],
9
9
  "name": "@aurodesignsystem-dev/auro-slideshow",
10
- "version": "0.0.0-pr80.0",
10
+ "version": "0.0.0-pr80.2",
11
11
  "description": "auro-slideshow HTML custom element",
12
12
  "repository": {
13
13
  "type": "git",
@@ -21,23 +21,23 @@
21
21
  "node": ">=20"
22
22
  },
23
23
  "dependencies": {
24
- "lit": "^3.3.2"
24
+ "lit": "^3.3.3"
25
25
  },
26
26
  "devDependencies": {
27
- "@alaskaairux/icons": "^5.14.0",
28
- "@aurodesignsystem/auro-button": "^12.3.0",
29
- "@aurodesignsystem/auro-cli": "^4.1.0",
30
- "@aurodesignsystem/auro-config": "^1.3.1",
31
- "@aurodesignsystem/auro-icon": "^9.1.1",
32
- "@aurodesignsystem/auro-library": "^5.5.4",
33
- "@aurodesignsystem/design-tokens": "^8.7.0",
34
- "@aurodesignsystem/webcorestylesheets": "^10.1.4",
27
+ "@alaskaairux/icons": "^5.32.0",
28
+ "@aurodesignsystem/auro-button": "^13.0.3",
29
+ "@aurodesignsystem/auro-cli": "^5.7.0",
30
+ "@aurodesignsystem/auro-config": "^1.3.2",
31
+ "@aurodesignsystem/auro-icon": "^9.2.1",
32
+ "@aurodesignsystem/auro-library": "^5.14.4",
33
+ "@aurodesignsystem/design-tokens": "^9.4.3",
34
+ "@aurodesignsystem/webcorestylesheets": "^12.1.0",
35
35
  "embla-carousel": "^8.6.0",
36
36
  "embla-carousel-auto-scroll": "^8.6.0",
37
37
  "embla-carousel-autoplay": "^8.6.0",
38
38
  "embla-carousel-class-names": "^8.6.0",
39
39
  "husky": "^9.1.7",
40
- "sinon": "^21.0.1"
40
+ "sinon": "^22.1.0"
41
41
  },
42
42
  "browserslist": [
43
43
  "last 2 Chrome versions",