From 48d8ef195c33323a544dcdf065de6294511a523c Mon Sep 17 00:00:00 2001 From: NicolasRichel Date: Tue, 14 Jun 2022 16:27:04 +0200 Subject: [PATCH] PATCH: doc(components): improve BIMDataCarousel doc + add reactivity on minGap prop --- .../BIMDataCarousel/BIMDataCarousel.vue | 5 ++ .../views/Components/Carousel/Carousel.vue | 56 ++++++++++++++----- 2 files changed, 46 insertions(+), 15 deletions(-) diff --git a/src/BIMDataComponents/BIMDataCarousel/BIMDataCarousel.vue b/src/BIMDataComponents/BIMDataCarousel/BIMDataCarousel.vue index e9ebc9b3..7a1aa015 100644 --- a/src/BIMDataComponents/BIMDataCarousel/BIMDataCarousel.vue +++ b/src/BIMDataComponents/BIMDataCarousel/BIMDataCarousel.vue @@ -63,6 +63,11 @@ export default { translations: [], }; }, + watch: { + minGap() { + this.distributeItems(); + }, + }, mounted() { this.distributeItems(); this.resizeObserver = new ResizeObserver(() => this.distributeItems()); diff --git a/src/web/views/Components/Carousel/Carousel.vue b/src/web/views/Components/Carousel/Carousel.vue index f74ea0a2..dc3c1d64 100644 --- a/src/web/views/Components/Carousel/Carousel.vue +++ b/src/web/views/Components/Carousel/Carousel.vue @@ -13,11 +13,20 @@ :minGap="+minGap" >
+ > + {{ i }} + @@ -28,12 +37,6 @@ placeholder="Carousel width" v-model="carouselWidth" /> - + /> + +