From 3bf8214e6eb5853f4f8d11fa95d7f8c09cd4ed98 Mon Sep 17 00:00:00 2001 From: Korbs Date: Fri, 9 Aug 2024 00:57:39 -0400 Subject: [PATCH] Update sidebar footer area and add channels you follow --- source/src/components/global/Sidebar.astro | 86 +++++++++++++++------- 1 file changed, 58 insertions(+), 28 deletions(-) diff --git a/source/src/components/global/Sidebar.astro b/source/src/components/global/Sidebar.astro index c30c013..9a54ad7 100755 --- a/source/src/components/global/Sidebar.astro +++ b/source/src/components/global/Sidebar.astro @@ -9,6 +9,11 @@ import { version } from '@root/package.json' +// Components +import CreatorInSidebar from '@components/CreatorInSidebar.astro' +import { ViewTransitions } from 'astro:transitions'; +import { slide } from "astro/virtual-modules/transitions.js"; + // Icons import { GraphUp, @@ -18,45 +23,61 @@ import { AppleImac2021Side, EmojiTalkingHappy, PeaceHand, - HelpCircle, - Server, - CurveArray, PlanetAlt, -InputSearch, -ProfileCircle, -SettingsProfiles, -Settings + InputSearch, + Settings, + LogIn } from '@iconoir/vue' // i18n import i18next, { t } from "i18next" import SettingsLayout from '@layouts/Settings.astro' + +// Supabase Data +import { supabase } from "@library/supabase" +const { data: { user } } = await supabase.auth.getUser() +const id = user?.id + +// Is the user logged in? +if (user?.id === "undefined") { + var Guest = true +} else { + var Guest = false +} + +// Get Channels +const { data: channels, error } = await supabase + .from('channels') + .select('*') +let { data: subs } = await supabase + .from('subs') + .select("*") + .eq('UserSubscribed', id) --- + @@ -167,15 +191,16 @@ import SettingsLayout from '@layouts/Settings.astro' } } .sidebar-bottom { - padding: 12px; display: flex; flex-direction: column; justify-content: space-between; - .sidebar-bottom-center { - background: #232323; - padding: 0px 24px; - margin: 0px -24px 12px -24px; + .sidebar-bottom-end { text-align: center; + padding-bottom: 12px; + display: flex; + align-items: center; + justify-content: space-between; + padding: 0px 18px; } a { margin: 0px 4px; @@ -186,6 +211,11 @@ import SettingsLayout from '@layouts/Settings.astro' text-decoration: underline; } } + p#version { + background: rgb(48, 48, 48); + border-radius: 3rem; + padding: 6px 12px; + } } .sidebar-top-end a, .sidebar-bottom-start a { color: white;