|
156 | 156 | :pause-on-hover="pauseOnHover"
|
157 | 157 | @autoplay-pause="internalAutoPlaying = false"
|
158 | 158 | @autoplay-resume="internalAutoPlaying = true")
|
159 |
| - v-icon(slot="pause-icon" large color="white") pause_circle_outline |
| 159 | + template(v-slot:pause-icon) |
| 160 | + v-icon(large color="white") pause_circle_outline |
160 | 161 | vueper-slide(v-for="(slide, i) in slides1" :key="slide.id" :title="slide.title" :content="slide.content" :style="'background-color: ' + colors[i % 4]")
|
161 | 162 |
|
162 | 163 | .subtitle-1.mt-6 Basic autoplay (with pause on mouseover) source code:
|
|
167 | 168 | :title="slide.title"
|
168 | 169 | :content="slide.content"
|
169 | 170 | :style="'background-color: ' + colors[i % 4]"></vueper-slide>
|
170 |
| - <i slot="pause-icon" class="icon pause_circle_outline"></i> |
| 171 | + <template v-slot:pause-icon> |
| 172 | + <i class="icon pause_circle_outline"></i> |
| 173 | + </template> |
171 | 174 | </vueper-slides>
|
172 | 175 |
|
173 | 176 | .subtitle-1 This example full source code:
|
|
190 | 193 | :title="slide.title"
|
191 | 194 | :content="slide.content"
|
192 | 195 | :style="'background-color: ' + colors[i % 4]"></vueper-slide>
|
193 |
| - <i slot="pause-icon" class="icon pause_circle_outline"></i> |
| 196 | + <template v-slot:pause-icon> |
| 197 | + <i class="icon pause_circle_outline"></i> |
| 198 | + </template> |
194 | 199 | </vueper-slides>
|
195 | 200 | ssh-pre(language="js" label="Vue JS component").
|
196 | 201 | data: () => ({
|
|
215 | 220 | The bullets are showing slide indexes which is disabled by default.#[br]
|
216 | 221 | You can also disable arrows and/or bullets. E.g. #[span.code :arrows="false"], #[span.code :bullets="false"]
|
217 | 222 | vueper-slides.ex--arrows-and-bullets(:infinite="false" :bullets-outside="true")
|
218 |
| - v-icon(slot="arrow-left" color="white" x-large) undo |
219 |
| - v-icon(slot="arrow-right" color="white" x-large) redo |
| 223 | + template(v-slot:arrow-left) |
| 224 | + v-icon(color="white" x-large) undo |
| 225 | + template(v-slot:arrow-right) |
| 226 | + v-icon(color="white" x-large) redo |
220 | 227 | vueper-slide(v-for="(slide, i) in slides1" :key="slide.id" :title="slide.title" :content="slide.content" :style="'background-color: ' + colors[(i + 1) % 4]")
|
221 | 228 | ssh-pre(language="html-vue" label="HTML Vue Template").
|
222 | 229 | <vueper-slides :infinite="false" :bullets-outside="true">
|
223 |
| - <v-icon slot="arrow-left" color="white" large>arrow_left</v-icon> |
224 |
| - <v-icon slot="arrow-right" color="white" large>arrow_right</v-icon> |
| 230 | + <template v-slot:arrow-left> |
| 231 | + <i class="icon icon-arrow-left"></i> |
| 232 | + </template> |
| 233 | + <template v-slot:arrow-right> |
| 234 | + <i class="icon icon-arrow-right"></i> |
| 235 | + </template> |
225 | 236 | <vueper-slide
|
226 | 237 | v-for="(slide, i) in slides"
|
227 | 238 | :key="slide.id"
|
|
344 | 355 | :key="i"
|
345 | 356 | :style="'background-color: ' + ['#ff5252', '#42b983'][i % 2]">
|
346 | 357 | <template v-slot:slide-content>
|
347 |
| - <v-icon color="white">check</v-icon> |
| 358 | + <i class="icon icon-check"></i> |
348 | 359 | Complex content with Vue.js {{ "\{\{ 1 === 1 ? 'interpreted' : 'non-interpreted' \}\}" }} compilable content & <span v-pre>{{ '\{\{ mustaches \}\}' }}</span>.
|
349 | 360 | </template>
|
350 | 361 | </vueper-slide>
|
351 | 362 | </vueper-slides>
|
352 | 363 | highlight(type="info")
|
353 | 364 | ul.my-0
|
354 |
| - li if both #[span.code :title="..."] and #[span.code slot="slide-title"] are provided, the title slot will be displayed. |
355 |
| - li if both #[span.code :content="..."] and #[span.code slot="slide-content"] are provided, the content slot will be displayed. |
| 365 | + li if both #[span.code :title="..."] and #[span.code v-slot:slide-title] are provided, the title slot will be displayed. |
| 366 | + li if both #[span.code :content="..."] and #[span.code v-slot:slide-content] are provided, the content slot will be displayed. |
356 | 367 |
|
357 | 368 | h3
|
358 | 369 | a(href="#ex--updating-content") Updating Content Inside/Outside
|
|
380 | 391 | vueper-slides.ex--updating-content(
|
381 | 392 | :slide-ratio="1/4"
|
382 | 393 | autoplay
|
| 394 | + always-refresh-clones |
383 | 395 | :slide-content-outside="contentPosition === 'false' ? false : contentPosition"
|
384 |
| - slide-content-outside-class="text-center py-4" |
385 |
| - :refresh-clones-on-drag="true") |
| 396 | + slide-content-outside-class="text-center py-4") |
386 | 397 | vueper-slide(v-for="(slide, i) in slides4" :key="i" :style="'background-color: ' + ['#42b983', '#ff5252'][i % 2]")
|
387 | 398 | template(v-slot:slide-content)
|
388 | 399 | v-layout(align-center justify-center)
|
|
399 | 410 | :title="slide.title"
|
400 | 411 | :content="slide.content"
|
401 | 412 | :style="'background-color: ' + ['#42b983', '#ff5252'][i % 2]">
|
402 |
| - <div slot="slide-content"> |
| 413 | + <template slot:slide-content> |
403 | 414 | <v-layout">
|
404 | 415 | <v-icon>access_time</v-icon>
|
405 | 416 | <div>
|
406 | 417 | <div>{{ '\{\{ slide.title \}\}' }}</div>
|
407 | 418 | <div>{{ '\{\{ slide.content \}\}' }}</div>
|
408 | 419 | </div>
|
409 | 420 | </v-layout>
|
410 |
| - </div> |
| 421 | + </template> |
411 | 422 | </vueper-slide>
|
412 | 423 | </vueper-slides>
|
413 | 424 |
|
|
898 | 909 | transitionSpeed: [Number, String], default: 600
|
899 | 910 | pauseOnHover: [Boolean], default: true
|
900 | 911 | infinite: [Boolean], default: true
|
901 |
| - refreshClonesOnDrag: [Boolean], default: false |
| 912 | + alwaysRefreshClones: [Boolean], default: false |
902 | 913 | parallax: [Boolean, Number], default: false
|
903 | 914 | touchable: [Boolean], default: true
|
904 | 915 | preventYScroll: [Boolean], default: false
|
|
1036 | 1047 | as a fade transition slideshow does not need such effect.
|
1037 | 1048 |
|
1038 | 1049 | li
|
1039 |
| - | #[code refreshClonesOnDrag], #[strong.mr-1 Type:] #[span.code.mr-1 [Boolean]], #[strong.mr-1 Default:] #[span.code false] |
| 1050 | + | #[code alwaysRefreshClones], #[strong.mr-1 Type:] #[span.code.mr-1 [Boolean]], #[strong.mr-1 Default:] #[span.code false] |
1040 | 1051 | p.
|
1041 | 1052 | With #[span.code infinite] mode on and sliding transitions, the clones
|
1042 | 1053 | (#[a(href="#what-are-clones" @click="onWhatAreClonesClick") What are clones?]) are created with a copy of content at
|
1043 | 1054 | the time it's created.#[br]Your content can get outdated if you have a fast #[span.code setInterval]
|
1044 |
| - operating on content (E.g. a clock).#[br]Set #[span.code refreshClonesOnDrag] to |
| 1055 | + operating on content (E.g. a clock).#[br]Set #[span.code alwaysRefreshClones] to |
1045 | 1056 | #[span.code true] if you want to keep updating clones before you see them while you drag.
|
1046 | 1057 | highlight(type="success").
|
1047 | 1058 | By default this parameter is disabled to save up operations. In most cases you should
|
|
1393 | 1404 | li If both slide-title slot and title attribute are provided now use the slot.
|
1394 | 1405 | li If both slide-content slot and content attribute are provided now use the slot.
|
1395 | 1406 | li Improved autoplay pause & resume - manual slide does not resume if paused.
|
| 1407 | + li Removed #[span.code refreshClonesOnDrag] option and introduced #[span.code alwaysRefreshClones]. |
1396 | 1408 | li TODO: update clones on content/title slots update
|
1397 | 1409 | li TODO: update all examples with new slots syntax
|
| 1410 | + li TODO: document alwaysRefreshClones |
1398 | 1411 |
|
1399 | 1412 | li.mt-6
|
1400 | 1413 | strong Version 1.16.0
|
|
0 commit comments