mirror of
https://github.com/web3privacy/web
synced 2024-10-15 18:26:27 +02:00
astro4 page transitions
This commit is contained in:
parent
f9f4fe7337
commit
378b34642b
3 changed files with 6 additions and 2 deletions
|
@ -1,4 +1,6 @@
|
|||
---
|
||||
import { ViewTransitions } from 'astro:transitions';
|
||||
|
||||
import * as config from '../config.yaml';
|
||||
import core from '../core.json';
|
||||
import '../styles/base.css';
|
||||
|
@ -19,6 +21,8 @@ function genHeading(str) {
|
|||
<meta name="generator" content={Astro.generator} />
|
||||
<meta name="description" content={description} />
|
||||
<title>{title ? title + ' | ' + config.title : config.title}</title>
|
||||
|
||||
<ViewTransitions />
|
||||
<link
|
||||
rel="preload"
|
||||
href="/fonts/archivo-regular-latin-ext.woff2"
|
||||
|
|
|
@ -63,7 +63,7 @@ for (const year of pastYears.reverse()) {
|
|||
</p>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
<script is:inline>
|
||||
document.querySelectorAll('.event-header .header-base').forEach((el) => {
|
||||
el.addEventListener('click', (ev) => {
|
||||
if (ev.target.tagName === "BUTTON") {
|
||||
|
|
|
@ -117,7 +117,7 @@ for (const ev of events) {
|
|||
|
||||
<AboutFooter />
|
||||
</div>
|
||||
<script>
|
||||
<script is:inline>
|
||||
document.querySelectorAll('.w3pn-hp-grid > div').forEach(el => {
|
||||
el.addEventListener('click', () => {
|
||||
window.location = el.getAttribute('data-url');
|
||||
|
|
Loading…
Reference in a new issue