Fixes #1201 - Add conditional rendering to Carousel indicators
When totalIndicators is below 0 (when the value prop is an empty array) and numScroll !== numVisible, a RangeError is thrown.pull/1196/head^2
parent
60547bc237
commit
b3dece37ed
|
@ -40,7 +40,7 @@
|
|||
<span :class="['p-carousel-prev-icon pi', {'pi-chevron-right': !isVertical(),'pi-chevron-down': isVertical()}]"></span>
|
||||
</button>
|
||||
</div>
|
||||
<ul :class="indicatorsContentClasses">
|
||||
<ul v-if="totalIndicators >= 0" :class="indicatorsContentClasses">
|
||||
<li v-for="(indicator, i) of totalIndicators" :key="'p-carousel-indicator-' + i.toString()" :class="['p-carousel-indicator', {'p-highlight': d_page === i}]">
|
||||
<button class="p-link" @click="onIndicatorClick($event, i)" type="button" />
|
||||
</li>
|
||||
|
|
Loading…
Reference in New Issue