-
-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bullets slot or prop #67
Comments
i tried overwriting the glide classes, for example:
but without success |
i tried also with the slot control, as you say in the documentation:
but i have this error in the console:
|
sorry for all the posts, i solved in this way:
if it could help someone, but please, update the docs |
hello, the items in the v-for are the same of the glide, so the index is
the same, here is a sample code
<vue-glide class="" type="slider" :bound="false" :autoplay="2000" :
animation-duration="1000" :gap="10" :per-view="1"
:bullet="false" v-model="active">
<vue-glide-slide v-for="(item,index) in items" :key="index"
class="block relative py-16 w-full justify-center px-10">
<!-- card content -->
</vue-glide-slide>
<template slot="control" class="py-2">
<button v-for="(el, index) in items" class="h-1 w-6 rounded-full
mx-1"
:class="active==index?'bg-red':'bg-green'" :data-glide-dir="
'='+index" :key="index">
</button>
</template>
</vue-glide>
data() {
return {
active: 0,
items: [
{
title: "Lorem ",
description: "Lorem Ipsum ",
},
{
title: "Lorem ",
description: "Lorem Ipsum ",
},
{
title: "Lorem ",
description: "Lorem Ipsum ",
},
{
title: "Lorem ",
description: "Lorem Ipsum ",
},
{
title: "Lorem ",
description: "Lorem Ipsum ",
},
],
}
},
Il giorno gio 11 ago 2022 alle ore 09:22 Edoardo Mazzon <
***@***.***> ha scritto:
… sorry for all the posts, i solved in this way:
<template slot="control">
<button
v-for="(el, index) in items"
class="h-6 w-6 rounded-full"
:class="active==index?'bg-red-600':'bg-gray-500'"
:data-glide-dir="'='+index" :key="index"
>
</button>
</template>
if it could help someone, but please, update the docs
Hi, can I ask you how did you know which slide is active even in bullets?
How did you pass the active variable from the slider to the dots?
—
Reply to this email directly, view it on GitHub
<#67 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AGCCEW6VTZ5HDNPBZHCZSODVYSS4DANCNFSM47BKTLIQ>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
hello i'm trying to add the bullets to my carousel, but nothing shows, i added :bullet="true" prop and inspecting the html there are the bullets, but nothing shows, any suggestions?
here is the html:
inside the html i have:
and the glide works, i can see the glide__bullet glide__bullet--active class switch between the bullets, i think is some css issue
the slide section is ok, just the bullets didn't show
thanks for your help
The text was updated successfully, but these errors were encountered: