mirror of
https://github.com/ReVanced/revanced-website.git
synced 2026-01-29 22:01:05 +00:00
fix: clean up random stuff man idk
This commit is contained in:
@@ -10,16 +10,8 @@ import { slide } from 'svelte/transition';
|
||||
div {
|
||||
position: fixed;
|
||||
width: 100vw;
|
||||
top: 75px;
|
||||
|
||||
top: 70px;
|
||||
z-index: 999;
|
||||
/* background-color: var(--grey-six); guh @xafn */
|
||||
background-color: hsla(220, 12%, 15%, 0.95);
|
||||
border-style: solid;
|
||||
border-color: var(--accent-color);
|
||||
|
||||
/* its rotated for some reason :skull: */
|
||||
border-left: 0.5rem;
|
||||
border-right: 0.5rem;
|
||||
background-color: var(--grey-seven);
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -2,94 +2,109 @@
|
||||
import Navigation from '../atoms/NavButton.svelte';
|
||||
import { page } from '$app/stores';
|
||||
import Button from '../atoms/Button.svelte';
|
||||
import MobileDropdown from './MobileDropdown.svelte';
|
||||
import { onMount } from 'svelte';
|
||||
import RouterEvents from '../../../data/RouterEvents';
|
||||
import MobileDropdown from './MobileDropdown.svelte';
|
||||
import { onMount } from 'svelte';
|
||||
import RouterEvents from '../../../data/RouterEvents';
|
||||
|
||||
let menuOpen = false;
|
||||
|
||||
onMount(() => {
|
||||
return RouterEvents.subscribe(event => {
|
||||
if (event.navigating) {
|
||||
menuOpen = false;
|
||||
}
|
||||
});
|
||||
});
|
||||
onMount(() => {
|
||||
return RouterEvents.subscribe((event) => {
|
||||
if (event.navigating) {
|
||||
menuOpen = false;
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<nav>
|
||||
<div class="navbar">
|
||||
<div class="left-side">
|
||||
<a href="/">
|
||||
<span class="logo">
|
||||
<img src="/logo.svg" class="logo-image" alt="ReVanced Logo" />
|
||||
</span>
|
||||
</a>
|
||||
<div class="navbar">
|
||||
<div class="left-side">
|
||||
<a href="/">
|
||||
<span class="logo">
|
||||
<img src="/logo.svg" class="logo-image" alt="ReVanced Logo" />
|
||||
</span>
|
||||
</a>
|
||||
|
||||
<span class="desktop">
|
||||
<Navigation href="/">Home</Navigation>
|
||||
<Navigation href="/download">Download</Navigation>
|
||||
<div hidden>
|
||||
<!-- This is just temporary so the build doesn't fail -->
|
||||
<Navigation is_selected={target => target.startsWith("/docs")} href="/docs">Docs</Navigation>
|
||||
</div>
|
||||
<Navigation href="/patches">Patches</Navigation>
|
||||
</span>
|
||||
</div>
|
||||
<span class="desktop">
|
||||
<Navigation href="/">Home</Navigation>
|
||||
<Navigation href="/download">Download</Navigation>
|
||||
<div hidden>
|
||||
<!-- This is just temporary so the build doesn't fail -->
|
||||
<Navigation is_selected={(target) => target.startsWith('/docs')} href="/docs"
|
||||
>Docs</Navigation
|
||||
>
|
||||
</div>
|
||||
<Navigation href="/patches">Patches</Navigation>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
<div class="right-side">
|
||||
<span class="desktop">
|
||||
<Navigation href="/contributors/">
|
||||
<img src="/icons/contrib.svg" alt="Contributors"/>
|
||||
</Navigation>
|
||||
<Navigation href="/api-settings/">
|
||||
<img src="/icons/settings.svg" alt="Settings"/>
|
||||
</Navigation>
|
||||
</span>
|
||||
<div class="right-side">
|
||||
<span class="desktop">
|
||||
<Navigation href="/contributors/">
|
||||
<img src="/icons/contrib.svg" alt="Contributors" />
|
||||
</Navigation>
|
||||
<Navigation href="/api-settings/">
|
||||
<img src="/icons/settings.svg" alt="Settings" />
|
||||
</Navigation>
|
||||
</span>
|
||||
|
||||
<!-- Should probably be moved to its own component. -->
|
||||
<button class="menu-btn mobile" class:open={menuOpen} on:click={() => {menuOpen = !menuOpen}}>
|
||||
<span class="menu-btn__burger" />
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- Should probably be moved to its own component. -->
|
||||
<button
|
||||
class="menu-btn mobile"
|
||||
class:open={menuOpen}
|
||||
on:click={() => {
|
||||
menuOpen = !menuOpen;
|
||||
}}
|
||||
>
|
||||
<span class="menu-btn__burger" />
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="mobile">
|
||||
{#if menuOpen}
|
||||
<MobileDropdown>
|
||||
<div class="mobile-menu">
|
||||
<Navigation href="/">Home</Navigation>
|
||||
<Navigation href="/download">Download</Navigation>
|
||||
<Navigation href="/patches">Patches</Navigation>
|
||||
<Navigation href="/contributors">Contributors</Navigation>
|
||||
<Navigation href="/api-settings">Settings</Navigation>
|
||||
</div>
|
||||
</MobileDropdown>
|
||||
{/if}
|
||||
</div>
|
||||
<div class="mobile">
|
||||
{#if menuOpen}
|
||||
<MobileDropdown>
|
||||
<div class="mobile-menu">
|
||||
<div>
|
||||
<Navigation href="/">Home</Navigation>
|
||||
<Navigation href="/download">Download</Navigation>
|
||||
<Navigation href="/patches">Patches</Navigation>
|
||||
</div>
|
||||
|
||||
<div class="bottom-mobile-container">
|
||||
<Navigation href="/contributors/">
|
||||
<img src="/icons/contrib.svg" alt="Contributors" />
|
||||
</Navigation>
|
||||
<Navigation href="/api-settings/">
|
||||
<img src="/icons/settings.svg" alt="Settings" />
|
||||
</Navigation>
|
||||
</div>
|
||||
</div>
|
||||
</MobileDropdown>
|
||||
{/if}
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<style>
|
||||
nav {
|
||||
position: fixed;
|
||||
width: 100vw;
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: 999;
|
||||
}
|
||||
.navbar {
|
||||
padding: 0 1rem 0 2rem;
|
||||
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
min-height: 70px;
|
||||
width: 100%;
|
||||
z-index: 999;
|
||||
background-color: var(--grey-six);
|
||||
backdrop-filter: blur(15px);
|
||||
-webkit-backdrop-filter: blur(15px);
|
||||
}
|
||||
nav {
|
||||
position: fixed;
|
||||
width: 100vw;
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: 999;
|
||||
border-bottom: 0.5px solid var(--grey-three);
|
||||
}
|
||||
.navbar {
|
||||
padding: 0 1rem 0 2rem;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
min-height: 70px;
|
||||
width: 100%;
|
||||
z-index: 999;
|
||||
background-color: var(--grey-seven);
|
||||
}
|
||||
|
||||
.desktop {
|
||||
display: flex;
|
||||
@@ -97,14 +112,17 @@
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.mobile-menu {
|
||||
display: block;
|
||||
width: 80vw;
|
||||
height: 100vh;
|
||||
white-space: pre;
|
||||
margin: 0 auto;
|
||||
padding: 1ch 0;
|
||||
}
|
||||
.mobile-menu {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 0.5rem;
|
||||
width: 85vw;
|
||||
height: calc(100vh - 70px);
|
||||
white-space: pre;
|
||||
padding: 2rem 0;
|
||||
margin: 0 auto;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
a {
|
||||
text-decoration: none;
|
||||
@@ -128,19 +146,29 @@
|
||||
gap: 2.5rem;
|
||||
}
|
||||
|
||||
|
||||
img {
|
||||
height: 20px;
|
||||
}
|
||||
|
||||
@media screen and (max-width: 600px) {
|
||||
@media screen and (max-width: 768px) {
|
||||
.desktop {
|
||||
display: none;
|
||||
}
|
||||
|
||||
img {
|
||||
height: 25px;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
.bottom-mobile-container {
|
||||
display: flex;
|
||||
float: bottom;
|
||||
}
|
||||
|
||||
/* Hamburger mmm yum */
|
||||
@media screen and (min-width: 600px) {
|
||||
@media screen and (min-width: 768px) {
|
||||
.mobile {
|
||||
display: none !important;
|
||||
}
|
||||
@@ -156,15 +184,15 @@
|
||||
cursor: pointer;
|
||||
transition: all 0.5s var(--bezier-one);
|
||||
|
||||
/* We don't want it to look like a normal button. */
|
||||
background-color: transparent;
|
||||
border: none;
|
||||
font-family: inherit;
|
||||
font-size: inherit;
|
||||
font-style: inherit;
|
||||
font-weight: inherit;
|
||||
line-height: inherit;
|
||||
padding: 0;
|
||||
/* We don't want it to look like a normal button. */
|
||||
background-color: transparent;
|
||||
border: none;
|
||||
font-family: inherit;
|
||||
font-size: inherit;
|
||||
font-style: inherit;
|
||||
font-weight: inherit;
|
||||
line-height: inherit;
|
||||
padding: 0;
|
||||
}
|
||||
.menu-btn__burger {
|
||||
width: 25px;
|
||||
@@ -173,8 +201,8 @@
|
||||
background: var(--grey-five);
|
||||
transition: all 0.5s var(--bezier-one);
|
||||
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
.menu-btn__burger::before,
|
||||
.menu-btn__burger::after {
|
||||
|
||||
@@ -127,7 +127,7 @@
|
||||
}
|
||||
|
||||
.patch-container:active {
|
||||
background-color: var(--grey-three);
|
||||
filter: brightness(1.5);
|
||||
}
|
||||
|
||||
.title {
|
||||
@@ -171,4 +171,6 @@
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
|
||||
</style>
|
||||
|
||||
@@ -12,13 +12,13 @@
|
||||
|
||||
<style>
|
||||
.menu {
|
||||
height: calc(100vh - 7.5rem);
|
||||
height: calc(100vh - 7rem);
|
||||
width: 100%;
|
||||
padding: 0px 10px 30px 10px;
|
||||
padding: 0px 30px 30px 10px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
position: sticky;
|
||||
top: 7.5rem;
|
||||
top: 7rem;
|
||||
overflow-y: scroll;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user