vue3-carousel
Advanced tools
Comparing version 0.1.33 to 0.1.34
/** | ||
* Vue 3 Carousel 0.1.32 | ||
* Vue 3 Carousel 0.1.34 | ||
* (c) 2021 | ||
@@ -547,6 +547,14 @@ * @license MIT | ||
const { next: slotNext, prev: slotPrev } = slots; | ||
const config = inject('config', reactive(Object.assign({}, defaultConfigs))); | ||
const maxSlide = inject('maxSlide', ref(1)); | ||
const minSlide = inject('minSlide', ref(1)); | ||
const currentSlide = inject('currentSlide', ref(1)); | ||
const nav = inject('nav', {}); | ||
const prevButton = h('button', { | ||
type: 'button', | ||
class: ['carousel__prev', attrs === null || attrs === void 0 ? void 0 : attrs.class], | ||
class: [ | ||
'carousel__prev', | ||
(!config.wrapAround && currentSlide.value <= minSlide.value) && 'carousel__prev--in-active', | ||
attrs === null || attrs === void 0 ? void 0 : attrs.class | ||
], | ||
'aria-label': `Navigate to previous slide`, | ||
@@ -557,3 +565,7 @@ onClick: nav.prev, | ||
type: 'button', | ||
class: ['carousel__next', attrs === null || attrs === void 0 ? void 0 : attrs.class], | ||
class: [ | ||
'carousel__next', | ||
(!config.wrapAround && currentSlide.value >= maxSlide.value) && 'carousel__next--in-active', | ||
attrs === null || attrs === void 0 ? void 0 : attrs.class | ||
], | ||
'aria-label': `Navigate to next slide`, | ||
@@ -560,0 +572,0 @@ onClick: nav.next, |
/** | ||
* Vue 3 Carousel 0.1.32 | ||
* Vue 3 Carousel 0.1.34 | ||
* (c) 2021 | ||
@@ -10,3 +10,3 @@ * @license MIT | ||
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.VueCarousel = {}, global.Vue)); | ||
})(this, (function (exports, vue) { 'use strict'; | ||
}(this, (function (exports, vue) { 'use strict'; | ||
@@ -552,6 +552,14 @@ const defaultConfigs = { | ||
const { next: slotNext, prev: slotPrev } = slots; | ||
const config = vue.inject('config', vue.reactive(Object.assign({}, defaultConfigs))); | ||
const maxSlide = vue.inject('maxSlide', vue.ref(1)); | ||
const minSlide = vue.inject('minSlide', vue.ref(1)); | ||
const currentSlide = vue.inject('currentSlide', vue.ref(1)); | ||
const nav = vue.inject('nav', {}); | ||
const prevButton = vue.h('button', { | ||
type: 'button', | ||
class: ['carousel__prev', attrs === null || attrs === void 0 ? void 0 : attrs.class], | ||
class: [ | ||
'carousel__prev', | ||
(!config.wrapAround && currentSlide.value <= minSlide.value) && 'carousel__prev--in-active', | ||
attrs === null || attrs === void 0 ? void 0 : attrs.class | ||
], | ||
'aria-label': `Navigate to previous slide`, | ||
@@ -562,3 +570,7 @@ onClick: nav.prev, | ||
type: 'button', | ||
class: ['carousel__next', attrs === null || attrs === void 0 ? void 0 : attrs.class], | ||
class: [ | ||
'carousel__next', | ||
(!config.wrapAround && currentSlide.value >= maxSlide.value) && 'carousel__next--in-active', | ||
attrs === null || attrs === void 0 ? void 0 : attrs.class | ||
], | ||
'aria-label': `Navigate to next slide`, | ||
@@ -666,2 +678,2 @@ onClick: nav.next, | ||
})); | ||
}))); |
declare const _default: import("vue").DefineComponent<{}, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, { | ||
[key: string]: any; | ||
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<{} & {} & {}>, {}>; | ||
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<{} & {} & {}> & ({} | {}), {}>; | ||
export default _default; |
{ | ||
"name": "vue3-carousel", | ||
"version": "0.1.33", | ||
"version": "0.1.34", | ||
"scripts": { | ||
@@ -5,0 +5,0 @@ "build": "rollup -c", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
65350
1717