From 35ec4754c376d7fca00f8bc6c51494cbc77ca300 Mon Sep 17 00:00:00 2001 From: jinkang-0 Date: Tue, 16 Jan 2024 10:03:50 -0800 Subject: [PATCH] add branding to hero --- src/components/Brand.astro | 4 +++- src/components/Hero.astro | 25 +++++++++++++++++++------ 2 files changed, 22 insertions(+), 7 deletions(-) diff --git a/src/components/Brand.astro b/src/components/Brand.astro index 20b0d09..1daca30 100644 --- a/src/components/Brand.astro +++ b/src/components/Brand.astro @@ -2,9 +2,11 @@ import { Image } from 'astro:assets'; import bpLogo from '../graphics/bp.webp'; import calHacksLogo from '../graphics/calhacks.webp'; + +const props = Astro.props; --- -
+
Blueprint diff --git a/src/components/Hero.astro b/src/components/Hero.astro index 33b66a8..eec1b02 100644 --- a/src/components/Hero.astro +++ b/src/components/Hero.astro @@ -8,6 +8,7 @@ import heroGraphicLeft from '../graphics/hero_shapes_left.svg'; import heroGraphicRight from '../graphics/hero_shapes_right.svg'; import bearLeft from '../graphics/bear_orange.svg'; import bearRight from '../graphics/bear_blue.svg'; +import Brand from './Brand.astro'; ---
@@ -48,19 +49,20 @@ import bearRight from '../graphics/bear_blue.svg'; arrows -
+
-
+
bear with cape bear with cape
-
+
clouds and stars clouds and sparkles +
@@ -135,7 +137,7 @@ import bearRight from '../graphics/bear_blue.svg'; // bg graphic parallax // kudos to https://keithclark.co.uk/articles/pure-css-parallax-websites/ (1/12/2024) - .parallax { + .parallax-container { position: absolute; width: 100%; height: 100svh; @@ -148,7 +150,7 @@ import bearRight from '../graphics/bear_blue.svg'; height: 100svh; transform-style: preserve-3d; - div { + .parallax { position: absolute; top: 0; left: 0; @@ -188,6 +190,17 @@ import bearRight from '../graphics/bear_blue.svg'; translateY(-50%); } + .hero-brand { + $offset: 50px; + position: absolute; + right: -$offset; + top: 50%; + transform: translate( + calc(clamp(#{-$offset}, -12vw, 0px) - 10px), + calc(50% + 150px) + ); + } + .bear-left { position: absolute; left: -$offset-left; @@ -211,7 +224,7 @@ import bearRight from '../graphics/bear_blue.svg';