make the title image redirect to about
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
This commit is contained in:
parent
bc92b2184b
commit
d344924a1d
2 changed files with 26 additions and 3 deletions
|
@ -4,15 +4,21 @@ import { Content as ShortBio } from "../content/partials/shortBio.md";
|
|||
import links from "../data/links";
|
||||
import { Image } from "astro:assets";
|
||||
import portrait from "../assets/self.png";
|
||||
|
||||
const target = Astro.url.pathname === "/" ? "/about/" : "/";
|
||||
---
|
||||
|
||||
<nav class="side-nav">
|
||||
<div class="side-nav-content">
|
||||
<a href="/" class="portrait">
|
||||
<a href={target} class="portrait">
|
||||
<Image src={portrait} alt="portrait" class="portrait" />
|
||||
</a>
|
||||
<div class="me">
|
||||
<h1 class="title">Michael Zhang</h1>
|
||||
<div class="titleContainer">
|
||||
<h1 class="title">
|
||||
<a href={target}>Michael Zhang</a>
|
||||
</h1>
|
||||
</div>
|
||||
<div class="links">
|
||||
{
|
||||
links.map((link) => {
|
||||
|
|
|
@ -10,6 +10,16 @@
|
|||
justify-content: space-evenly;
|
||||
flex-direction: column;
|
||||
|
||||
.title {
|
||||
a {
|
||||
color: inherit;
|
||||
|
||||
&:hover {
|
||||
background-color: inherit;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.links {
|
||||
text-align: center;
|
||||
font-size: 0.9rem;
|
||||
|
@ -76,12 +86,19 @@
|
|||
justify-content: space-evenly;
|
||||
}
|
||||
|
||||
.titleContainer {
|
||||
container-type: inline-size;
|
||||
}
|
||||
|
||||
h1.title {
|
||||
margin-top: 0;
|
||||
margin-bottom: 5px;
|
||||
|
||||
font-size: 14cqw;
|
||||
}
|
||||
|
||||
a.portrait img {
|
||||
max-height: 80px;
|
||||
max-height: 120px;
|
||||
}
|
||||
|
||||
.bio {
|
||||
|
|
Loading…
Reference in a new issue