Skip to content

Commit

Permalink
Merge branch 'main' into d3rpp/blob_rename_and_delete
Browse files Browse the repository at this point in the history
  • Loading branch information
d3rpp authored Nov 19, 2024
2 parents e338b8f + de945db commit 5be84a6
Show file tree
Hide file tree
Showing 27 changed files with 92 additions and 219 deletions.
Binary file modified bun.lockb
Binary file not shown.
6 changes: 2 additions & 4 deletions drizzle/meta/_journal.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,11 @@
{
"idx": 0,
"version": "6",
"when": 1729459339411,
"tag": "0000_quiet_iron_man",
"breakpoints": true
"when": 1731012522719,
"tag": "0000_salty_red_shift"
},
{
"idx": 1,
"version": "6",
"when": 1731834716676,
"tag": "0001_productive_shadowcat",
"breakpoints": true
Expand Down
2 changes: 1 addition & 1 deletion src/app.css
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
}

.dark {
--background: 240 10% 3.9%;
--background: 0 0% 3.9%;
--foreground: 210 40% 98%;

--muted: 217.2 32.6% 17.5%;
Expand Down
107 changes: 14 additions & 93 deletions src/lib/components/headers/app-header.svelte
Original file line number Diff line number Diff line change
@@ -1,46 +1,36 @@
<script lang="ts">
import type { User } from "lucia";
import { AccountHeaderComponent } from "@/account";
import { page } from "$app/stores";
import { derived } from "svelte/store";
interface Props {
user: User | null;
}
const { user }: Props = $props();
//need to add pathways for each page
const isHomePage = derived(page, ($page) => $page.url.pathname === "/");
const isUploadPage = derived(page, ($page) => $page.url.pathname === "/");
const isProfilePage = derived(
page,
($page) =>
$page.url.pathname === "/src/routes/(app)/app/account/page.svelte",
);
</script>

<header
class="sticky top-0 z-50 w-full border-b border-border/40 bg-[#373737] backdrop-blur supports-[backdrop-filter]:bg-[#373737]"
class="sticky top-0 z-50 w-full bg-gradient-to-b from-[#000013] to-[#000000]"
>
<!-- Div that contains the icon and text logos -->

<div
class="container mx-auto flex h-24 max-w-screen-2xl items-center px-4 2xl:px-0"
>
<!-- need to add link -->
<a href="/">
<a href="/app">
<div class="flex items-center md:mr-4">
<img
src="src/lib/logos/Logo-Green.svg"
src="src/lib/logos/BirdPink.svg"
alt="JailBird Green"
class="h-16"
/>

<h1
class="ml-4"
style="font-family: futura, sans-serif; font-weight: 600; font-style: normal; font-size: 3rem;"
>
JailBird
</h1>
<img
src="src/lib/logos/JailBirdTextWhite.svg"
alt=""
class="h-16 pl-4"
/>
</div>
</a>

Expand All @@ -49,94 +39,25 @@
>
<div>
<!-- need to add link -->
<a
href="/"
class="group flex flex-col items-center hover:text-[#6CFF96]"
>
<a href="/app" class="group flex flex-col items-center">
<img
src={$isHomePage
? "src/lib/menuIcons/homeGreen.svg"
: "src/lib/menuIcons/homeWhite.svg"}
src="src/lib/menuIcons/newHome.svg"
alt="Home Icon"
style="height: 40px;"
class="group-hover:hidden"
/>
<img
src="src/lib/menuIcons/homeGreen.svg"
alt="Home Icon Hover"
style="height: 40px;"
class="hidden group-hover:block"
/>

<p
class="text-white-600 group-hover:text-[#6CFF96]"
style="font-family: futura, sans-serif; font-weight: 600; font-style: normal; font-size: 1.25rem;"
class:active-text={$isHomePage}
>
Home
</p>
</a>
</div>

<div>
<!-- need to add link -->
<a
href="/"
class="group flex flex-col items-center hover:text-[#6CFF96]"
>
<img
src={$isUploadPage
? "src/lib/menuIcons/uploadGreen.svg"
: "src/lib/menuIcons/uploadWhite.svg"}
alt="Upload File Icon"
style="height: 40px;"
class="group-hover:hidden"
/>

<img
src="src/lib/menuIcons/uploadGreen.svg"
src="src/lib/menuIcons/newHomePink.svg"
alt="Home Icon Hover"
style="height: 40px;"
class="hidden group-hover:block"
/>

<p
class="text-white-600 group-hover:text-[#6CFF96]"
style="font-family: futura, sans-serif; font-weight: 600; font-style: normal; font-size: 1.25rem;"
class:active-text={$isUploadPage}
>
Shared Files
</p>
</a>
</div>

<div>
<!-- need to add link -->
<a
href="/"
class="group flex flex-col items-center hover:text-[#6CFF96]"
>
<AccountHeaderComponent {user} avatar_size="custom" />

<p
class="text-white-600 group-hover:text-[#6CFF96]"
style="font-family: futura, sans-serif; font-weight: 600; font-style: normal; font-size: 1.25rem;"
class:active-text={$isProfilePage}
>
Profile
</p>
</a>
<AccountHeaderComponent {user} avatar_size="custom" />
</div>
</div>
</div>
</header>

<style>
p {
color: white;
}
.active-text {
color: #6cff96;
}
</style>
87 changes: 7 additions & 80 deletions src/lib/components/headers/landing-header.svelte
Original file line number Diff line number Diff line change
@@ -1,96 +1,23 @@
<script lang="ts">
import type { User } from "lucia";
import LogoGreen from "$lib/logos/birdAndTextPink.svg";
import { AccountHeaderComponent } from "@/account";
import { page } from "$app/stores";
import { derived } from "svelte/store";
import LogoGreen from "$lib//logos/Logo-Green.svg";
interface Props {
user: User | null;
}
const { user }: Props = $props();
//need to add pathways for each page
const isHomePage = derived(page, ($page) => $page.url.pathname === "/");
const isUploadPage = derived(page, ($page) => $page.url.pathname === "/");
const isProfilePage = derived(
page,
($page) =>
$page.url.pathname === "/src/routes/(app)/app/account/page.svelte",
);
</script>

<header
class="sticky top-0 z-50 w-full border-b border-border/40 bg-[#373737] backdrop-blur supports-[backdrop-filter]:bg-[#373737]"
class="sticky top-0 z-50 h-28 w-full bg-gradient-to-b from-[#000013] to-[#000000] shadow-lg"
>
<div class="container mx-auto flex h-24 max-w-screen-2xl items-center px-4">
<div class="flex items-center md:mr-4">
<img src={LogoGreen} alt="JailBird Green" class="h-20" />

<h1 class="">JailBird</h1>
</div>

<div
class="hidden flex-1 items-center justify-between space-x-40 md:flex md:justify-end"
>
<AccountHeaderComponent {user} />

<!-- Menu icons -->

<div>
<a href="/" class="flex flex-col items-center">
<img
src={$isHomePage
? "src/lib/menuIcons/homeGreen.svg"
: "src/lib/menuIcons/homeWhite.svg"}
alt="Home Icon"
style="height: 40px;"
class:active-icon={$isHomePage}
/>

<p class:active-text={$isHomePage}>Home</p>
</a>
</div>

<div>
<a href="/" class="flex flex-col items-center">
<img
src={$isUploadPage
? "src/lib/menuIcons/uploadGreen.svg"
: "src/lib/menuIcons/uploadWhite.svg"}
alt="Upload File Icon"
style="height: 40px;"
/>

<p class:active-text={$isUploadPage}>Upload Files</p>
</a>
</div>

<div>
<a href="/" class="flex flex-col items-center">
<img
src={$isProfilePage
? "src/lib/menuIcons/accountGreen.svg"
: "src/lib/menuIcons/accountWhite.svg"}
alt="Account Icon"
style="height: 40px;"
/>
<div class="flex h-full items-center justify-end px-20 py-4">
<AccountHeaderComponent {user} avatar_size="custom" />
</div>

<p class:active-text={$isProfilePage}>Profile</p>
</a>
</div>
</div>
<div class="absolute inset-0 flex items-center justify-center">
<img src={LogoGreen} alt="JailBird Green" class="h-20" />
</div>
</header>

<style>
p {
color: white;
}
.active-text {
color: #6cff96;
}
</style>
2 changes: 1 addition & 1 deletion src/lib/components/main.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@
usable and can be expanded later to also work on mobile.
-->

<main class={cn("mx-auto max-w-screen-2xl px-4 py-4 2xl:px-0", className)}>
<main class={cn("mx-auto max-w-screen-2xl px-4 py-4 2xl:px-0 ", className)}>
{@render children?.()}
</main>
2 changes: 1 addition & 1 deletion src/lib/components/ui/file-card/file-card.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
let renameAlertOpen = $state(false);
let deleteAlertOpen = $state(false);
const decodeB64Blob = (b64: string): Uint8Array => {
const binaryString = atob(b64);
let bytes = new Uint8Array(binaryString.length);
Expand Down
1 change: 1 addition & 0 deletions src/lib/logos/BirdPink.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions src/lib/logos/BirdWhite.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions src/lib/logos/JailBirdTextWhite.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions src/lib/logos/birdAndTextPink.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 6 additions & 0 deletions src/lib/menuIcons/newHome.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 6 additions & 0 deletions src/lib/menuIcons/newHomePink.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 9 additions & 3 deletions src/routes/(app)/app/+layout.svelte
Original file line number Diff line number Diff line change
@@ -1,13 +1,19 @@
<script lang="ts">
import { AppFooter } from "@/footers";
import { AppHeader } from "@/headers";
import Main from "@/main.svelte";
const { data, children } = $props();
const { user } = data;
</script>

<AppHeader {user} />

{@render children()}

<div
class="h-full bg-cover bg-center"
style="background-image: url('/backgroundsAndAssets/newBackground2.jpg');background-attachment: fixed; background-size: cover; background-position: center;"
>
<Main>
{@render children()}
</Main>
</div>
<AppFooter />
1 change: 0 additions & 1 deletion src/routes/(app)/app/account/create_key_dialog.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
import { Label } from "@/ui/label";
import { Input } from "@/ui/input";
import * as Select from "@/ui/select";
import { Button, buttonVariants } from "@/ui/button";
import InlineCodeBlock from "@/inline-codeblock.svelte";
Expand Down
12 changes: 9 additions & 3 deletions src/routes/(landing)/+layout.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,14 @@

<LandingHeader {user} />

<Main class="h-landing-main">
{@render children()}
</Main>
<!-- div to add background to pages solely affected by the landing layout -->

<div
class="h-full bg-cover bg-center"
style="background-image: url('/backgroundsAndAssets/newLandingBackground.jpg');background-attachment: fixed; background-size: cover; background-position: center;"
>
<Main class="h-landing-main">
{@render children()}
</Main>
</div>
<LandingFooter />
Loading

0 comments on commit 5be84a6

Please sign in to comment.