mirror of
https://github.com/revanced/revanced-website.git
synced 2025-05-03 16:14:25 +02:00
mobile nav & hero page adjustments
This commit is contained in:
parent
c27a2f46e9
commit
30849593ed
@ -27,7 +27,6 @@
|
|||||||
padding: 12px 40px;
|
padding: 12px 40px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
margin-top: 45px;
|
|
||||||
transition: transform 0.4s var(--bezier-one), box-shadow 0.4s var(--bezier-one);
|
transition: transform 0.4s var(--bezier-one), box-shadow 0.4s var(--bezier-one);
|
||||||
user-select: none;
|
user-select: none;
|
||||||
}
|
}
|
||||||
|
@ -7,14 +7,24 @@
|
|||||||
.hero-img {
|
.hero-img {
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
height: 80vh;
|
height: 80vh;
|
||||||
|
max-height: 80rem;
|
||||||
z-index: -1;
|
z-index: -1;
|
||||||
width: auto;
|
width: auto;
|
||||||
float: right;
|
float: right;
|
||||||
border-radius: 2rem;
|
border-radius: 1.5rem;
|
||||||
transform: rotate(3.7deg) translateY(2%);
|
transform: rotate(3.7deg);
|
||||||
box-shadow: 0 1rem 3rem 0 #0f111a;
|
box-shadow: 0 1rem 3rem 0 #0f111a;
|
||||||
user-select: none;
|
user-select: none;
|
||||||
}
|
}
|
||||||
|
@media (max-width: 1919px) {
|
||||||
|
.hero-img {
|
||||||
|
position: absolute;
|
||||||
|
height: 90vh;
|
||||||
|
top: 90px;
|
||||||
|
right: 7.5%;
|
||||||
|
transform: rotate(3.7deg) translateY(10%);
|
||||||
|
}
|
||||||
|
}
|
||||||
.hero-img::after{
|
.hero-img::after{
|
||||||
box-shadow: inset 2rem 2rem 5rem -3rem var(--grey-two), inset -2rem -2rem 5rem -3rem var(--grey-one);
|
box-shadow: inset 2rem 2rem 5rem -3rem var(--grey-two), inset -2rem -2rem 5rem -3rem var(--grey-one);
|
||||||
content: "";
|
content: "";
|
||||||
|
@ -10,7 +10,23 @@
|
|||||||
h1 {
|
h1 {
|
||||||
color: var(--white);
|
color: var(--white);
|
||||||
font-weight: 800;
|
font-weight: 800;
|
||||||
font-size: 6rem;
|
font-size: 6rem;
|
||||||
letter-spacing: -0.04em;
|
letter-spacing: -0.04em;
|
||||||
|
line-height: 0.75em;
|
||||||
|
}
|
||||||
|
@media screen and (max-width: 1919px) {
|
||||||
|
h1 {
|
||||||
|
font-size: 5rem;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@media screen and (max-width: 1052px) {
|
||||||
|
h1 {
|
||||||
|
font-size: 4.5rem;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@media screen and (max-width: 768px) {
|
||||||
|
h1 {
|
||||||
|
font-size: 3rem;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
@ -24,8 +24,6 @@
|
|||||||
background-color: var(--grey-four);
|
background-color: var(--grey-four);
|
||||||
color: var(--white);
|
color: var(--white);
|
||||||
user-select: none;
|
user-select: none;
|
||||||
margin-right: 0.5rem;
|
|
||||||
margin-left: 0.5rem;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
div {
|
div {
|
||||||
|
@ -11,8 +11,9 @@
|
|||||||
svg {
|
svg {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
z-index: -2;
|
z-index: -2;
|
||||||
bottom:0;
|
bottom: 0;
|
||||||
transform: translateY(20%);
|
height: 35vh;
|
||||||
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.wave {
|
.wave {
|
||||||
|
Before Width: | Height: | Size: 2.2 KiB After Width: | Height: | Size: 2.2 KiB |
@ -1,9 +1,23 @@
|
|||||||
<script>
|
<script lang="ts">
|
||||||
import Navigation from '../atoms/Navigation.svelte';
|
import Navigation from '../atoms/Navigation.svelte';
|
||||||
|
import { onMount } from 'svelte';
|
||||||
import { page } from '$app/stores';
|
import { page } from '$app/stores';
|
||||||
|
let menuBtn: HTMLElement;
|
||||||
|
let menuOpen = false;
|
||||||
|
onMount(() => {
|
||||||
|
menuBtn.addEventListener('click', () => {
|
||||||
|
if (!menuOpen) {
|
||||||
|
menuBtn.classList.add('open');
|
||||||
|
menuOpen = true;
|
||||||
|
} else {
|
||||||
|
menuBtn.classList.remove('open');
|
||||||
|
menuOpen = false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<div>
|
<div class="wrapper">
|
||||||
<nav>
|
<nav>
|
||||||
<a href="/">
|
<a href="/">
|
||||||
<div class="logo">
|
<div class="logo">
|
||||||
@ -20,23 +34,22 @@
|
|||||||
<Navigation href="/docs">Docs</Navigation>
|
<Navigation href="/docs">Docs</Navigation>
|
||||||
<Navigation href="/credits">Credits</Navigation>
|
<Navigation href="/credits">Credits</Navigation>
|
||||||
</ul>
|
</ul>
|
||||||
|
<div class="menu-btn" class:open={menuOpen} bind:this={menuBtn}>
|
||||||
|
<div class="menu-btn__burger" />
|
||||||
|
</div>
|
||||||
</nav>
|
</nav>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
nav {
|
nav {
|
||||||
width: 100%;
|
top: 0;
|
||||||
top: 0;
|
|
||||||
display: flex;
|
display: flex;
|
||||||
padding-top: 0.75rem;
|
|
||||||
padding-right: 3rem;
|
|
||||||
padding-left: 6rem;
|
|
||||||
justify-content: space-between;
|
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
min-height: 90px;
|
min-height: 90px;
|
||||||
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.logo {
|
.logo {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
}
|
}
|
||||||
@ -58,22 +71,75 @@
|
|||||||
color: var(--red);
|
color: var(--red);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@media screen and (max-width: 1052px) {
|
@media screen and (max-width: 1052px) {
|
||||||
|
|
||||||
h1 {
|
h1 {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
nav {
|
|
||||||
padding-left: 7%;
|
|
||||||
padding-right: 1%;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@media screen and (max-width: 768px) {
|
@media screen and (max-width: 768px) {
|
||||||
nav {
|
nav {
|
||||||
background-color: purple;
|
/* background-color: purple; */
|
||||||
|
}
|
||||||
|
ul {
|
||||||
|
display: none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Hamburger mmm yum */
|
||||||
|
@media screen and (min-width: 768px) {
|
||||||
|
.menu-btn {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.menu-btn {
|
||||||
|
user-select: none;
|
||||||
|
position: relative;
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
width: 80px;
|
||||||
|
height: 60px;
|
||||||
|
cursor: pointer;
|
||||||
|
transition: all 0.5s ease-in-out;
|
||||||
|
background: var(--grey-one);
|
||||||
|
border-radius: 3rem;
|
||||||
|
}
|
||||||
|
.menu-btn__burger {
|
||||||
|
width: 30px;
|
||||||
|
height: 3px;
|
||||||
|
background: #fff;
|
||||||
|
border-radius: 5px;
|
||||||
|
box-shadow: 0 2px 5px rgba(255, 101, 47, 0.2);
|
||||||
|
transition: all 0.5s ease-in-out;
|
||||||
|
}
|
||||||
|
.menu-btn__burger::before,
|
||||||
|
.menu-btn__burger::after {
|
||||||
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
width: 30px;
|
||||||
|
height: 3px;
|
||||||
|
background: #fff;
|
||||||
|
border-radius: 5px;
|
||||||
|
box-shadow: 0 2px 5px rgba(255, 101, 47, 0.2);
|
||||||
|
transition: all 0.5s ease-in-out;
|
||||||
|
}
|
||||||
|
.menu-btn__burger::before {
|
||||||
|
transform: translateY(-8px);
|
||||||
|
}
|
||||||
|
.menu-btn__burger::after {
|
||||||
|
transform: translateY(8px);
|
||||||
|
}
|
||||||
|
/* ANIMATION */
|
||||||
|
.menu-btn.open .menu-btn__burger {
|
||||||
|
transform: translateX(-50px);
|
||||||
|
background: transparent;
|
||||||
|
box-shadow: none;
|
||||||
|
}
|
||||||
|
.menu-btn.open .menu-btn__burger::before {
|
||||||
|
transform: rotate(45deg) translate(35px, -35px);
|
||||||
|
}
|
||||||
|
.menu-btn.open .menu-btn__burger::after {
|
||||||
|
transform: rotate(-45deg) translate(35px, 35px);
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
@ -1,27 +1,34 @@
|
|||||||
<script>
|
<script>
|
||||||
import SocialButton from "../atoms/SocialButton.svelte";
|
import SocialButton from '../atoms/SocialButton.svelte';
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<div class="social-host">
|
<div class="social-host">
|
||||||
<SocialButton src="socials/github.svg" alt="GitHub" href="https://revanced.app/github"></SocialButton>
|
<SocialButton src="socials/github.svg" alt="GitHub" href="https://revanced.app/github" />
|
||||||
<SocialButton src="socials/discord.svg" alt="Discord" href="http://revanced.app/discord"></SocialButton>
|
<SocialButton src="socials/discord.svg" alt="Discord" href="http://revanced.app/discord" />
|
||||||
<SocialButton src="socials/reddit.svg" alt="Reddit" href="https://revanced.app/reddit"></SocialButton>
|
<SocialButton src="socials/reddit.svg" alt="Reddit" href="https://revanced.app/reddit" />
|
||||||
<SocialButton src="socials/telegram.svg" alt="Telegram" href="https://revanced.app/telegram"></SocialButton>
|
<SocialButton src="socials/telegram.svg" alt="Telegram" href="https://revanced.app/telegram" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
.social-host {
|
.social-host {
|
||||||
justify-content: space-between;
|
width: min(87%, 100rem);
|
||||||
|
/* same as margin-inline: auto on .wrapper */
|
||||||
|
padding: 0 max(6.5%, calc(50vw - 50rem));
|
||||||
align-items: center;
|
align-items: center;
|
||||||
position: fixed;
|
user-select: none;
|
||||||
bottom: 3rem;
|
position: absolute;
|
||||||
left: 5.5rem;
|
display: flex;
|
||||||
}
|
bottom: 3rem;
|
||||||
|
gap: 1.5rem;
|
||||||
|
left: 0;
|
||||||
|
}
|
||||||
|
|
||||||
@media screen and (max-width: 1052px) {
|
@media screen and (max-width: 768px) {
|
||||||
.social-host {
|
.social-host {
|
||||||
left: 6%;
|
left: 0;
|
||||||
}
|
width: 100%;
|
||||||
|
display: flex;
|
||||||
}
|
justify-content: center;
|
||||||
|
}
|
||||||
|
}
|
||||||
</style>
|
</style>
|
@ -21,11 +21,26 @@
|
|||||||
|
|
||||||
<style>
|
<style>
|
||||||
h2 {
|
h2 {
|
||||||
margin-top: 1rem;
|
margin-top: 1.75rem;
|
||||||
|
margin-bottom: 2rem;
|
||||||
}
|
}
|
||||||
.hero {
|
.hero {
|
||||||
padding-bottom: 10rem;
|
padding-bottom: 10rem;
|
||||||
}
|
}
|
||||||
|
@media (max-width: 768px) {
|
||||||
|
.hero {
|
||||||
|
padding-top: 10rem;
|
||||||
|
padding-bottom: 0;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
h2 {
|
||||||
|
font-size: 1.5rem;
|
||||||
|
}
|
||||||
|
.hero-buttons {
|
||||||
|
flex-direction: column;
|
||||||
|
gap: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
.hero-text {
|
.hero-text {
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
@ -58,7 +58,6 @@
|
|||||||
:global(.wrapper) {
|
:global(.wrapper) {
|
||||||
margin-inline: auto;
|
margin-inline: auto;
|
||||||
width: min(87%, 100rem);
|
width: min(87%, 100rem);
|
||||||
margin-top: 1.5%;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
:root {
|
:root {
|
||||||
|
@ -7,18 +7,29 @@
|
|||||||
<div class="wrapper">
|
<div class="wrapper">
|
||||||
<div class="wrappezoid">
|
<div class="wrappezoid">
|
||||||
<IndexDescription />
|
<IndexDescription />
|
||||||
<HeroImage />
|
<div id="heroimg"><HeroImage /></div>
|
||||||
</div>
|
</div>
|
||||||
<SocialHost />
|
<SocialHost />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
.wrappezoid {
|
.wrappezoid {
|
||||||
|
height: calc(100vh - 90px);
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
justify-content: space-around;
|
justify-content: space-around;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
@media (max-width: 1919px) {
|
||||||
|
.wrappezoid {
|
||||||
|
justify-content: space-between;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@media (max-width: 1052px) {
|
||||||
|
#heroimg {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
@media (max-width: 768px) {
|
@media (max-width: 768px) {
|
||||||
.wrappezoid {
|
.wrappezoid {
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user