Skip to content

Commit 7c6cf45

Browse files
committed
styling: Fix transition applying to window resize
1 parent a969f9c commit 7c6cf45

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

app.vue

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
* Created Date: 2024-03-23 12:52:57
66
* Author: 3urobeat
77
*
8-
* Last Modified: 2024-03-30 12:44:47
8+
* Last Modified: 2024-03-30 13:03:32
99
* Modified By: 3urobeat
1010
*
1111
* Copyright (c) 2024 3urobeat <https://github.com/3urobeat>
@@ -19,13 +19,13 @@
1919

2020
<template>
2121
<!-- Title bar -->
22-
<PhList :class="!showNavbar ? 'block' : 'opacity-0'" class="fixed z-30 cursor-pointer left-3 top-2 lg:hidden block transition-all" size="25px" @click="showNavbar = !showNavbar"></PhList>
22+
<PhList :class="!showNavbar ? 'block' : 'opacity-0'" class="fixed z-30 cursor-pointer left-3 top-2 lg:hidden block transition-opacity" size="25px" @click="showNavbar = !showNavbar"></PhList>
2323

2424

2525
<header
2626
id="titlebar"
2727
:class="showNavbar ? 'bg-slate-100 opacity-30 lg:bg-white lg:opacity-100' : ''"
28-
class="fixed z-20 top-0 left-0 w-screen h-fit mb-5 pb-1.5 bg-white border-y-2 border-y-gray-500 border-t-0 transition-all duration-500"
28+
class="fixed z-20 top-0 left-0 w-screen h-fit mb-5 pb-1.5 bg-white border-y-2 border-y-gray-500 border-t-0 transition-opacity duration-500"
2929
> <!-- The extra lg: tags in :class fix a bg color bug when the window is resized while the navbar was open -->
3030
<div class="pt-2 w-full text-center select-none flex items-center justify-center font-semibold">
3131
<PhDetective class="mr-2 size-5"></PhDetective>
@@ -91,7 +91,7 @@
9191
</nav>
9292

9393
<!-- The main content itself, pushed to the side by the navbar -->
94-
<main :class="showNavbar ? 'bg-slate-200 opacity-30 lg:bg-white lg:opacity-100' : ''" class="z-10 w-screen h-screen px-5 pt-3 transition-all duration-500" @click="showNavbar = false"> <!-- The extra lg: tags in :class fix a bg color bug when the window is resized while the navbar was open -->
94+
<main :class="showNavbar ? 'bg-slate-200 opacity-30 lg:bg-white lg:opacity-100' : ''" class="z-10 w-screen h-screen px-5 pt-3 bg-white transition-opacity duration-500" @click="showNavbar = false"> <!-- The extra lg: tags in :class fix a bg color bug when the window is resized while the navbar was open -->
9595
<NuxtPage></NuxtPage> <!-- Links to index.vue -->
9696
</main>
9797

0 commit comments

Comments
 (0)