-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: replaces download modal with download page
- Loading branch information
Showing
32 changed files
with
673 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
<script lang="ts" setup> | ||
import 'swiper/css'; | ||
import { Swiper } from 'swiper/vue'; | ||
import type { SwiperOptions } from 'swiper/types'; | ||
withDefaults(defineProps<SwiperOptions>(), { | ||
effect: 'slide', | ||
direction: 'horizontal', | ||
autoHeight: false, | ||
enabled: true, | ||
slidesPerView: 1, | ||
spaceBetween: 30, | ||
centeredSlides: false, | ||
}); | ||
const css = useCssModule(); | ||
</script> | ||
|
||
<template> | ||
<Swiper | ||
:auto-height="autoHeight" | ||
:autoplay="autoplay" | ||
:breakpoints="breakpoints" | ||
:centered-slides="centeredSlides" | ||
:class="css.swiper" | ||
:coverflow-effect="coverflowEffect" | ||
:direction="direction" | ||
:effect="effect" | ||
:enabled="enabled" | ||
:loop="loop" | ||
:modules="modules" | ||
:navigation="navigation" | ||
:pagination="pagination" | ||
:slides-per-view="slidesPerView" | ||
:space-between="spaceBetween" | ||
:zoom="zoom" | ||
> | ||
<slot /> | ||
</Swiper> | ||
</template> | ||
|
||
<style lang="scss" module> | ||
.swiper { | ||
width: 100%; | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
<script lang="ts" setup> | ||
import 'swiper/css'; | ||
import { get } from '@vueuse/core'; | ||
import { RuiFooterStepper } from '@rotki/ui-library'; | ||
import type { Swiper } from 'swiper/types'; | ||
const props = withDefaults( | ||
defineProps<{ activeIndex: number; pages: number; swiper?: Swiper }>(), | ||
{ | ||
swiper: undefined, | ||
}, | ||
); | ||
const emit = defineEmits<{ (e: 'update:swiper', value: Swiper): void }>(); | ||
const { swiper } = toRefs(props); | ||
const css = useCssModule(); | ||
const onNavigate = (index: number) => { | ||
const s = get(swiper); | ||
if (!s) { | ||
return; | ||
} | ||
s.slideTo(index - 1); | ||
emit('update:swiper', s); | ||
}; | ||
</script> | ||
|
||
<template> | ||
<RuiFooterStepper | ||
:class="css.controls" | ||
:model-value="activeIndex" | ||
:pages="pages" | ||
arrow-buttons | ||
variant="bullet" | ||
@update:model-value="onNavigate($event)" | ||
/> | ||
</template> | ||
|
||
<style lang="scss" module> | ||
.controls { | ||
width: 100%; | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,17 @@ | ||
<script setup lang="ts"> | ||
const emit = defineEmits<{ (e: 'click'): void }>(); | ||
const { t } = useI18n(); | ||
</script> | ||
|
||
<template> | ||
<div> | ||
<NuxtLink class="inline-flex" to="/download"> | ||
<RuiButton | ||
variant="default" | ||
size="lg" | ||
class="!py-4 !px-10 !text-xl uppercase" | ||
rounded | ||
color="primary" | ||
@click="emit('click')" | ||
> | ||
{{ t('actions.download') }} | ||
</RuiButton> | ||
</div> | ||
</NuxtLink> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
<script lang="ts" setup> | ||
const { t } = useI18n(); | ||
const css = useCssModule(); | ||
</script> | ||
|
||
<template> | ||
<div :class="css.wrapper"> | ||
<div :class="css.wrapper__container" class="container"> | ||
<h6 :class="css.title"> | ||
{{ t('download.documentation.title') }} | ||
</h6> | ||
<h4 :class="css.heading"> | ||
{{ t('download.documentation.heading') }} | ||
</h4> | ||
<div :class="css.desc__wrapper"> | ||
<p :class="css.description"> | ||
{{ t('download.documentation.description') }} | ||
</p> | ||
|
||
<div class="shrink-0"> | ||
<ButtonLink | ||
color="primary" | ||
variant="default" | ||
external | ||
to="https://rotki.readthedocs.io/en/latest/index.html" | ||
> | ||
{{ t('download.documentation.action') }} | ||
<template #append> | ||
<RuiIcon name="external-link-line" /> | ||
</template> | ||
</ButtonLink> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</template> | ||
|
||
<style lang="scss" module> | ||
.wrapper { | ||
@apply py-10 lg:py-20 bg-rui-primary/[0.04]; | ||
&__container { | ||
@apply flex flex-col; | ||
.title { | ||
@apply text-rui-light-primary text-h6 mb-3; | ||
} | ||
.heading { | ||
@apply text-rui-text text-h4 mb-5; | ||
} | ||
.desc__wrapper { | ||
@apply flex flex-col md:flex-row space-y-6 md:space-y-0 md:space-x-6 items-start justify-between; | ||
.description { | ||
@apply text-rui-text text-body-1 max-w-[48rem]; | ||
} | ||
} | ||
} | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
<script lang="ts" setup> | ||
import { type DownloadItemProps } from '~/components/download/DownloadItem.vue'; | ||
defineProps<{ version: string; links: DownloadItemProps[] }>(); | ||
const { t } = useI18n(); | ||
const css = useCssModule(); | ||
</script> | ||
|
||
<template> | ||
<div :class="css.wrapper"> | ||
<div :class="css.wrapper__container" class="container"> | ||
<div :class="css.titles"> | ||
<h6 :class="css.title"> | ||
{{ t('download.heading.download_rotki') }} | ||
</h6> | ||
<h3 :class="css.description"> | ||
{{ t('download.heading.description') }} | ||
</h3> | ||
</div> | ||
<div :class="css.links"> | ||
<DownloadItem | ||
v-for="(link, i) in links" | ||
v-bind="link" | ||
:key="i" | ||
:class="css.link" | ||
/> | ||
</div> | ||
<p :class="css.version"> | ||
{{ t('download.latest_release') }}: {{ version }} | ||
</p> | ||
</div> | ||
</div> | ||
</template> | ||
|
||
<style lang="scss" module> | ||
.wrapper { | ||
@apply py-10 lg:py-20; | ||
&__container { | ||
@apply flex flex-col; | ||
.titles { | ||
@apply flex flex-col space-y-4 mb-16; | ||
.title { | ||
@apply text-rui-light-primary text-h6; | ||
} | ||
.description { | ||
@apply text-rui-text text-h3; | ||
} | ||
} | ||
.links { | ||
@apply grid gap-6 grid-cols-2 lg:grid-cols-4 mb-6; | ||
.link { | ||
@apply w-full; | ||
} | ||
} | ||
.version { | ||
@apply text-body-1 text-rui-light-secondary; | ||
} | ||
} | ||
} | ||
</style> |
Oops, something went wrong.