-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
221 lines (209 loc) · 7.44 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<script
data-goatcounter="https://tentpole.goatcounter.com/count"
async
src="//gc.zgo.at/count.js"
></script>
<link rel="icon" href="/assets/favicon.png" type="image/x-icon" />
<meta
property="og:image"
content="https://tentpole.computer/assets/og.png"
/>
<meta property="og:title" content="Tentpole" />
<meta name="twitter:card" content="summary_large_image" />
<meta name="twitter:title" content="Tentpole" />
<meta name="twitter:description" content="" />
<meta
name="twitter:image"
content="https://tentpole.computer/assets/og.png"
/>
<title>Tentpole</title>
<link rel="stylesheet" href="/style.css" />
</head>
<body>
<main>
<img
id="plain-logo"
class="light"
src="/assets/flourish-0.png"
width="400"
height="350"
alt="A tent drawn with diagrammatic lines and dots. It say 'Tentpole' underneath in a bold, black font."
/>
<img
class="flourish-logo light"
src="/assets/flourish-1.png"
width="400"
height="350"
alt="A tent drawn with diagrammatic lines and dots. It say 'Tentpole' underneath in a bold, black font. A green paint brush stroke is scribbled on top of it all."
/>
<img
class="flourish-logo light"
src="/assets/flourish-2.png"
width="400"
height="350"
alt="A tent drawn with diagrammatic lines and dots. It say 'Tentpole' underneath in a bold, black font. A reddy brown brush stroke is painted over the text."
/>
<img
class="flourish-logo light"
src="/assets/flourish-3.png"
width="400"
height="350"
alt="A tent drawn with diagrammatic lines and dots. It say 'Tentpole' underneath in a bold, black font. A pink paint brush stroke is marked over the roof of the tent."
/>
<img
class="flourish-logo light"
src="/assets/flourish-4.png"
width="400"
height="350"
alt="A tent drawn with diagrammatic lines and dots. It say 'Tentpole' underneath in a bold, black font. A blue paint brush stroke is scribbled on top of it all."
/>
<img
id="plain-logo"
class="dark"
src="/assets/flourish-dark-0.png"
width="400"
height="350"
alt="A tent drawn with diagrammatic lines and dots. It say 'Tentpole' underneath in a bold, white font."
/>
<img
class="flourish-logo dark"
src="/assets/flourish-dark-1.png"
width="400"
height="350"
alt="A tent drawn with diagrammatic lines and dots. It say 'Tentpole' underneath in a bold, white font. A green paint brush stroke is scribbled on top of it all."
/>
<img
class="flourish-logo dark"
src="/assets/flourish-dark-2.png"
width="400"
height="350"
alt="A tent drawn with diagrammatic lines and dots. It say 'Tentpole' underneath in a bold, white font. A reddy brown brush stroke is painted over the text."
/>
<img
class="flourish-logo dark"
src="/assets/flourish-dark-3.png"
width="400"
height="350"
alt="A tent drawn with diagrammatic lines and dots. It say 'Tentpole' underneath in a bold, white font. A pink paint brush stroke is marked over the roof of the tent."
/>
<section>
<p>
<a href="https://todepond.com"><span>Lu Wilson</span></a>
</p>
<p>
<a href="https://orionreed.com"><span>Orion Reed</span></a>
</p>
<p>
<a href="https://elliot.website/"><span>Elliot Evans</span></a>
</p>
<p>
<a href="https://trimmings.wtf">
<span>Philippa Markovics</span>
</a>
</p>
</section>
<section>
<form
action="https://buttondown.com/api/emails/embed-subscribe/tentpole"
method="post"
target="popupwindow"
onsubmit="window.open('https://buttondown.com/tentpole', 'popupwindow')"
class="embeddable-buttondown-form"
>
<input
type="email"
name="email"
id="bd-email"
placeholder="Email updates?"
required
/>
<input type="submit" value="Subscribe" />
</form>
</section>
</main>
<footer>
<span><a href="https://mas.to/@Tentpole">mastodon</a></span>
<span>
<a href="https://bsky.app/profile/tentpole.bsky.social">bluesky</a>
</span>
<span><a href="https://twitter.com/tentpolecc">twitter</a></span>
</footer>
</body>
<script>
const memberSection = document.querySelector("section");
const memberElements = memberSection.querySelectorAll("section p");
const shuffledMemberElements = shuffle(Array.from(memberElements));
memberSection.innerHTML = "";
shuffledMemberElements.forEach((element) => {
memberSection.appendChild(element);
});
function shuffle(array) {
const shuffledArray = [];
while (array.length > 0) {
const randomIndex = Math.floor(Math.random() * array.length);
shuffledArray.push(array[randomIndex]);
array.splice(randomIndex, 1);
}
return shuffledArray;
}
const flourishLogosLight = document.querySelectorAll(
".flourish-logo.light"
);
const flourishLogosDark = document.querySelectorAll(".flourish-logo.dark");
const plainLogoLight = document.querySelector("#plain-logo.light");
const plainLogoDark = document.querySelector("#plain-logo.dark");
const selectedFlourishIndexLight = Math.floor(
Math.random() * flourishLogosLight.length
);
const selectedFlourishIndexDark = Math.floor(
Math.random() * flourishLogosDark.length
);
const selectedFlourishLogoLight =
flourishLogosLight[selectedFlourishIndexLight];
const selectedFlourishLogoDark =
flourishLogosDark[selectedFlourishIndexDark];
plainLogoLight.style.display = "none";
plainLogoDark.style.display = "none";
selectedFlourishLogoLight.classList.add("selected");
selectedFlourishLogoDark.classList.add("selected");
const colourMapLight = ["green", "red", "pink", "blue"];
const primaryColourLight = colourMapLight[selectedFlourishIndexLight];
const colourMapDark = ["green", "red", "pink"];
const primaryColourDark = colourMapDark[selectedFlourishIndexDark];
document.body.style.setProperty(
"--primary-light",
`var(--${primaryColourLight})`
);
document.body.style.setProperty(
"--primary-dark",
`var(--${primaryColourDark})`
);
const isDarkMode = window.matchMedia(
"(prefers-color-scheme: dark)"
).matches;
document.body.style.setProperty(
"--primary",
// todo: shouldnt do this because when the user changes scheme, it wont update
isDarkMode
? `var(--${primaryColourDark})`
: `var(--${primaryColourLight})`
);
// todo: should do this in CSS land instead
// will fix up when colour theme is slightly more stable
window
.matchMedia("(prefers-color-scheme: dark)")
.addEventListener("change", (e) => {
document.body.style.setProperty(
"--primary",
e.matches
? `var(--${primaryColourDark})`
: `var(--${primaryColourLight})`
);
});
</script>
</html>