Add a Carousel to Your Bullet Site

  1. Create a medium gallery view and name it. .bullet-carousel
    1.00
  2. If you don't want the cards to be clickable, add a Publish property and uncheck it
  3. To set up redirects, add a URL property named bullet:Link and insert your desired redirect URL

Navigate to the code section of your site in the Bullet dashboard. Copy the code below and paste it inside the “Body” section.

html

Next, add the carousel's CSS styling. Copy the following code and paste it into the “CSS” section.

css
:root {

    --card-width: 320px;

    --card-gap: 50px;

}

.db-bullet-carousel {
    width: auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(var(--card-width), 1fr));
    grid-auto-flow: column;
    gap: var(--card-gap);
    overflow-x: auto;
}

.db-bullet-carousel .notion-collection-card {
    width: var(--card-width);
}

.coll-Carousel .notion-gallery-grid {
    transition: scroll-behavior 0.5s ease-in-out;
}

.carousel-btn-next,
.carousel-btn-prev {
    border: none;
    background: var(--bg-color);
    color: var(--navbar-btn-bg-color);
    opacity: 0.6;
}

.carousel-btn-next:hover,
.carousel-btn-prev:hover {
    opacity: 1;
}

.carousel-btn-prev:disabled,
.carousel-btn-next:disabled,
.carousel-btn-prev:disabled:hover,
.carousel-btn-next:disabled:hover {
    opacity: 0.2;
}

.notion-gallery-grid {
    scroll-behavior: smooth;
}

Output:

1.00

Was this page helpful?

How can we improve?