2022-01-24 22:56:57 +00:00
|
|
|
<template>
|
2022-03-31 21:26:53 +00:00
|
|
|
<center class="container">
|
2022-03-31 04:22:24 +00:00
|
|
|
<v-img
|
2022-03-23 13:17:02 +00:00
|
|
|
src="/icon.svg"
|
2022-03-31 04:22:24 +00:00
|
|
|
width="10rem"
|
|
|
|
height="10rem"
|
2022-03-31 14:20:42 +00:00
|
|
|
class="intro"
|
2022-03-23 13:30:24 +00:00
|
|
|
:class="$vuetify.theme.dark ? '' : 'invert'"
|
2022-03-23 13:17:02 +00:00
|
|
|
/>
|
2022-03-31 04:22:24 +00:00
|
|
|
<div style="height: 5rem" />
|
|
|
|
<v-progress-linear rounded height="8" indeterminate color="primary" />
|
2022-03-31 05:20:00 +00:00
|
|
|
<div class="pt-2">{{ progressMsg }}...</div>
|
2022-03-20 07:24:38 +00:00
|
|
|
</center>
|
2022-01-24 22:56:57 +00:00
|
|
|
</template>
|
2022-03-16 00:31:03 +00:00
|
|
|
|
|
|
|
<script>
|
|
|
|
export default {
|
2022-03-25 18:50:18 +00:00
|
|
|
layout: "empty",
|
2022-03-24 22:10:05 +00:00
|
|
|
|
2022-03-28 19:59:08 +00:00
|
|
|
data: () => ({
|
2022-05-06 03:11:28 +00:00
|
|
|
progressMsg: "...",
|
2022-03-28 19:59:08 +00:00
|
|
|
}),
|
2022-03-20 07:24:38 +00:00
|
|
|
async mounted() {
|
2022-05-06 04:34:04 +00:00
|
|
|
this.progressMsg = this.$lang("index").connecting;
|
2022-05-06 03:11:28 +00:00
|
|
|
|
2022-03-31 21:26:53 +00:00
|
|
|
this.$store.commit("tweaks/initTweaks");
|
2022-03-31 04:22:24 +00:00
|
|
|
const theming = new Promise((resolve) =>
|
2022-03-31 21:26:53 +00:00
|
|
|
// Set timeout is required for $vuetify.theme... dont ask me why -Front
|
2022-03-31 04:22:24 +00:00
|
|
|
setTimeout(() => {
|
2022-04-07 20:30:42 +00:00
|
|
|
this.$vuetify.theme.dark =
|
|
|
|
JSON.parse(localStorage.getItem("darkTheme")) === true;
|
2022-03-31 05:20:00 +00:00
|
|
|
if (localStorage.getItem("primaryDark") != null)
|
2022-04-07 20:30:42 +00:00
|
|
|
this.$vuetify.theme.themes.dark.primary =
|
|
|
|
localStorage.getItem("primaryDark");
|
2022-03-31 05:20:00 +00:00
|
|
|
if (localStorage.getItem("primaryLight") != null)
|
2022-04-07 20:30:42 +00:00
|
|
|
this.$vuetify.theme.themes.light.primary =
|
|
|
|
localStorage.getItem("primaryLight");
|
2022-03-31 05:20:00 +00:00
|
|
|
if (localStorage.getItem("backgroundDark") != null)
|
2022-04-07 20:30:42 +00:00
|
|
|
this.$vuetify.theme.themes.dark.background =
|
|
|
|
localStorage.getItem("backgroundDark");
|
2022-03-31 05:20:00 +00:00
|
|
|
if (localStorage.getItem("backgroundLight") != null)
|
2022-04-07 20:30:42 +00:00
|
|
|
this.$vuetify.theme.themes.light.background =
|
|
|
|
localStorage.getItem("backgroundLight");
|
2022-05-04 23:09:17 +00:00
|
|
|
|
2022-03-31 04:22:24 +00:00
|
|
|
this.$vuetube.navigationBar.setTheme(
|
|
|
|
this.$vuetify.theme.currentTheme.background,
|
2022-03-31 05:20:00 +00:00
|
|
|
!this.$vuetify.theme.dark
|
2022-03-20 07:24:38 +00:00
|
|
|
);
|
2022-03-31 04:22:24 +00:00
|
|
|
this.$vuetube.statusBar.setTheme(
|
|
|
|
this.$vuetify.theme.currentTheme.background,
|
2022-03-31 05:20:00 +00:00
|
|
|
this.$vuetify.theme.dark
|
2022-03-31 04:22:24 +00:00
|
|
|
);
|
2022-05-13 19:54:14 +00:00
|
|
|
|
2022-05-04 23:09:17 +00:00
|
|
|
// this.$vuetube.navigationBar.setTransparent();
|
2022-05-13 19:54:14 +00:00
|
|
|
// this.$vuetube.statusBar.setTransparent();
|
2022-03-31 04:22:24 +00:00
|
|
|
resolve();
|
|
|
|
}, 0)
|
|
|
|
);
|
2022-03-19 23:17:26 +00:00
|
|
|
|
2022-03-31 04:22:24 +00:00
|
|
|
await theming;
|
2022-03-20 07:24:38 +00:00
|
|
|
await this.$youtube.getAPI();
|
2022-05-07 06:03:12 +00:00
|
|
|
await this.$vuetube.launchBackHandling();
|
2022-05-06 04:34:04 +00:00
|
|
|
this.progressMsg = this.$lang("index").launching;
|
2022-04-07 00:23:01 +00:00
|
|
|
|
2022-04-24 04:01:52 +00:00
|
|
|
this.$router.replace(`/${localStorage.getItem("startPage") || "home"}`); // Prevent user from navigating back to the splash screen
|
2022-03-20 07:24:38 +00:00
|
|
|
},
|
|
|
|
};
|
2022-03-17 18:10:54 +00:00
|
|
|
</script>
|
2022-03-23 13:17:02 +00:00
|
|
|
|
2022-04-15 03:14:52 +00:00
|
|
|
<style>
|
2022-03-23 13:17:02 +00:00
|
|
|
.container {
|
|
|
|
display: block;
|
|
|
|
position: absolute;
|
|
|
|
top: 50%;
|
|
|
|
left: 50%;
|
2022-03-31 21:26:53 +00:00
|
|
|
transform: translate(-50%, -50%);
|
2022-03-23 13:17:02 +00:00
|
|
|
}
|
2022-03-31 14:20:42 +00:00
|
|
|
.intro {
|
2022-03-31 04:22:24 +00:00
|
|
|
opacity: 0;
|
|
|
|
transform: scale(0.5);
|
|
|
|
transition-property: opacity, transform;
|
2022-05-06 00:57:40 +00:00
|
|
|
animation: bounce 0.66s 0.5s ease 1 forwards;
|
2022-03-31 04:22:24 +00:00
|
|
|
}
|
|
|
|
/* triangles aren't very good at spinning :c */
|
2022-03-31 14:20:42 +00:00
|
|
|
@keyframes bounce {
|
2022-03-31 04:22:24 +00:00
|
|
|
0% {
|
|
|
|
opacity: 0;
|
|
|
|
transform: scale(0.5);
|
|
|
|
}
|
|
|
|
100% {
|
|
|
|
opacity: 1;
|
|
|
|
transform: scale(1);
|
|
|
|
}
|
|
|
|
}
|
2022-03-31 14:20:42 +00:00
|
|
|
|
|
|
|
@keyframes fadein {
|
|
|
|
0% {
|
|
|
|
opacity: 0;
|
|
|
|
}
|
|
|
|
100% {
|
|
|
|
opacity: 1;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/* reduced-motion animations */
|
|
|
|
@media (prefers-reduced-motion) {
|
|
|
|
.intro {
|
|
|
|
opacity: 0;
|
|
|
|
transform: scale(1);
|
|
|
|
transition-property: opacity, transform;
|
|
|
|
animation: fadein 0.5s ease 1 forwards;
|
|
|
|
}
|
|
|
|
}
|
2022-04-15 03:14:52 +00:00
|
|
|
|
|
|
|
/* page transition */
|
|
|
|
.slide-up-enter-active,
|
|
|
|
.slide-up-leave-active,
|
|
|
|
.slide-down-enter-active,
|
|
|
|
.slide-down-leave-active {
|
|
|
|
transition-duration: 0.1s;
|
|
|
|
transition-property: opacity, transform;
|
|
|
|
/* overflow: hidden; */
|
|
|
|
}
|
|
|
|
|
|
|
|
.slide-up-enter,
|
|
|
|
.slide-down-leave-active {
|
|
|
|
opacity: 0;
|
|
|
|
transform: translateY(3rem);
|
|
|
|
}
|
|
|
|
|
|
|
|
.slide-up-leave-active,
|
|
|
|
.slide-down-enter {
|
|
|
|
opacity: 0;
|
|
|
|
transform: translateY(-1rem);
|
|
|
|
}
|
2022-03-23 13:17:02 +00:00
|
|
|
</style>
|