Skip to content

Commit 89f66fa

Browse files
committed
added favicon, mobile optimizations, google verification
1 parent 286af6a commit 89f66fa

File tree

5 files changed

+92
-15
lines changed

5 files changed

+92
-15
lines changed

public/favicon.svg

Lines changed: 0 additions & 9 deletions
This file was deleted.

src/components/header.astro

Lines changed: 35 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,17 @@
11
---
22
import GithubLogo from '/src/images/github-mark-white.svg'
3+
import Favicon from '/src/images/favicon.svg'
34
---
45

56
<header>
6-
<div>
7-
<h1>Binary Search Tree</h1>
8-
<h2>Visualizer</h2>
7+
<div class="title">
8+
<div>
9+
<img src={Favicon.src} alt="Logo">
10+
</div>
11+
<div>
12+
<h1>Binary Search Tree</h1>
13+
<h2>Visualizer</h2>
14+
</div>
915
</div>
1016
<div>
1117
<a href="https://github.com/adammehaney/Binary-Search-Tree-Visualizer" target="_blank"><img src={GithubLogo.src} alt="Github Logo" width="30px" height="30px"></a>
@@ -19,4 +25,30 @@ import GithubLogo from '/src/images/github-mark-white.svg'
1925
justify-content: space-between;
2026
align-items: center;
2127
}
28+
.title {
29+
display: flex;
30+
flex-direction: row;
31+
align-items: end;
32+
gap: 20px;
33+
}
34+
.title div img {
35+
height: 4em;
36+
}
37+
@media screen and (max-width: 600px) {
38+
.title {
39+
flex-direction: column;
40+
align-items: start;
41+
}
42+
header {
43+
flex-direction: column;
44+
align-items: start;
45+
gap: 20px;
46+
}
47+
h1 {
48+
font-size: 2rem;
49+
}
50+
h2 {
51+
font-size: 1.5rem;
52+
}
53+
}
2254
</style>

src/images/favicon.svg

Lines changed: 46 additions & 0 deletions
Loading

src/layouts/Layout.astro

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
---
22
import '@fontsource-variable/manrope';
3+
import Favicon from '/src/images/favicon.svg'
34
45
interface Props {
56
title: string;
@@ -14,11 +15,12 @@ const { title } = Astro.props;
1415
<meta charset="UTF-8" />
1516
<meta name="description" content="Easily visualize, randomly generate, add to, remove from a binary search tree. See preorder, inorder, and postorder lists of your binary search tree." />
1617
<meta name="viewport" content="width=device-width" />
17-
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
18+
<link rel="icon" type="image/svg" href={Favicon.src} />
1819
<meta name="generator" content={Astro.generator} />
1920
<meta name="keywords" content="Binary Search Tree BST Balanced Set Search Insert Delete Adam Mehaney Predecessor Successor Inorder Data Structure Algorithm Visualization Online Learning Tutorial Open Source">
2021
<title>{title}</title>
2122
<script src="../typescript/BST.ts"></script>
23+
<meta name="google-site-verification" content="XQkIf1w-ZpNZNAPfaG-X9BhPLxMQeYv-75eDrQ_dmGE" />
2224
</head>
2325
<body>
2426
<slot />

src/pages/index.astro

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,8 @@ import { Icon } from 'astro-icon/components'
6161

6262
<style>
6363
main div {
64-
display: flex;
65-
flex-direction: column;
64+
display: grid;
65+
grid-template-columns: 6fr 6fr;
6666
gap: 20px;
6767
}
6868
form div {
@@ -109,4 +109,10 @@ import { Icon } from 'astro-icon/components'
109109
background: linear-gradient(90deg, var(--primary), var(--secondary));
110110
cursor: pointer;
111111
}
112+
@media screen and (max-width: 708px) {
113+
main div {
114+
display: flex;
115+
flex-direction: column;
116+
}
117+
}
112118
</style>

0 commit comments

Comments
 (0)