File: /var/www/quadcode.com/src/components/pagination/Pagination.svelte
<script lang="ts">
export let className: string;
export let theme: string | undefined = '';
export const ssr = false;
</script>
<div class="pagination {className} {theme}" />
<style lang="scss">
@import 'src/scss/media';
@import 'src/scss/variables';
.pagination {
display: flex;
align-items: center;
justify-content: center;
bottom: 0 !important;
gap: 10px;
&.swiper-pagination-lock {
display: none;
}
& :global(.swiper-pagination-bullet) {
position: relative;
display: inline-flex;
width: 12px;
height: 12px;
background: transparent;
transition: all 0.4s ease;
opacity: 1 !important;
margin: 0 !important;
will-change: transform;
background: none !important;
&:before {
display: block;
content: '';
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
width: 4px;
height: 4px;
border-radius: 100%;
background: $techBlue3;
transition: all 0.4s ease;
}
&:after {
content: '';
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%) scale(0);
width: 12px;
height: 12px;
border-radius: 100%;
border: thin solid $redPrimary;
opacity: 0;
transition: all 0.4s ease;
}
}
& :global(.swiper-pagination-bullet-active) {
transition: all 0.4s ease;
width: 12px;
height: 12px;
background: transparent;
&:before {
transition: all 0.4s ease;
width: 6px;
height: 6px;
background: $redPrimary;
}
&:after {
transform: translate(-50%, -50%) scale(1);
opacity: 1;
}
}
&.white {
& :global(.swiper-pagination-bullet) {
&:before {
background: $techWhite;
}
&:after {
border: thin solid $techWhite;
}
}
& :global(.swiper-pagination-bullet-active) {
&:before {
background: $techWhite;
}
}
}
}
</style>