mirror of
https://github.com/web3privacy/news.git
synced 2024-10-15 18:06:26 +02:00
update
This commit is contained in:
parent
5ad750efbe
commit
968a171408
5 changed files with 34 additions and 7 deletions
3
data/2024/week07.md
Normal file
3
data/2024/week07.md
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
---
|
||||||
|
curator: Mykola
|
||||||
|
---
|
|
@ -12,10 +12,10 @@ const current = false;
|
||||||
|
|
||||||
<div class=`flex w-full p-4 sm:p-6 ${!issue.published ? "bg-blue-950" : "bg-white/10"}`>
|
<div class=`flex w-full p-4 sm:p-6 ${!issue.published ? "bg-blue-950" : "bg-white/10"}`>
|
||||||
<div class="grid gap-2 sm:gap-6 sm:flex items-center">
|
<div class="grid gap-2 sm:gap-6 sm:flex items-center">
|
||||||
<h1 class="text-2xl"><a href={issue.published} class=`${!issue.published ? 'no-underline' : ''}`>Week {issue.week.split('-').join('/')}</a></h1>
|
<h1 class="text-2xl"><a href=`/issue/${issue.week}`>Week {issue.week.split('-').join('/')}</a></h1>
|
||||||
<div class=`text-xl ${current ? "text-white/50" : ""}`>{format(issue.period[0], "MMM d")} - {format(issue.period[1], "MMM d, yyyy")}</div>
|
<div class=`text-xl ${current ? "text-white/50" : ""}`>{format(issue.period[0], "MMM d")} - {format(issue.period[1], "MMM d, yyyy")}</div>
|
||||||
{!issue.published &&
|
{!issue.published &&
|
||||||
<div class="text-white">🚧 Current week</div>
|
<div class="text-white">🚧 Future edition</div>
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
<div class="grow"></div>
|
<div class="grow"></div>
|
||||||
|
|
|
@ -19,13 +19,16 @@ import '../styles/base.css';
|
||||||
</div>
|
</div>
|
||||||
<div class="grow"></div>
|
<div class="grow"></div>
|
||||||
<div class="flex gap-3 mt-4 md:mt-0">
|
<div class="flex gap-3 mt-4 md:mt-0">
|
||||||
<a href="https://docs.web3privacy.info/news/week-in-the-privacy">Documentation</a>
|
<a href="https://paragraph.xyz/@privacynews/subscribe">Subscribe now!</a>
|
||||||
<a href="https://github.com/web3privacy/news">Source code</a>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="mt-10">
|
<div class="mt-10">
|
||||||
<slot />
|
<slot />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="flex gap-6 mt-4 mb-10 items-center justify-center">
|
||||||
|
<a href="https://docs.web3privacy.info/news/week-in-the-privacy">Documentation</a>
|
||||||
|
<a href="https://github.com/web3privacy/news">Source code</a>
|
||||||
|
</div>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -7,9 +7,6 @@ import issues from '../issues.json';
|
||||||
---
|
---
|
||||||
|
|
||||||
<BaseLayout>
|
<BaseLayout>
|
||||||
<div class="mb-8">
|
|
||||||
<a href="https://paragraph.xyz/@privacynews/subscribe">Subscribe now!</a>
|
|
||||||
</div>
|
|
||||||
{issues.map((issue) => (
|
{issues.map((issue) => (
|
||||||
<WeekNews {issue} />
|
<WeekNews {issue} />
|
||||||
))}
|
))}
|
||||||
|
|
24
web/src/pages/issue/[week].astro
Normal file
24
web/src/pages/issue/[week].astro
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
---
|
||||||
|
import BaseLayout from '../../layouts/base.astro';
|
||||||
|
import WeekNews from '../../components/WeekNews.astro';
|
||||||
|
import issues from '../../issues.json';
|
||||||
|
|
||||||
|
export function getStaticPaths() {
|
||||||
|
return issues.map(issue => {
|
||||||
|
return {
|
||||||
|
params: { week: issue.week }
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
const { week } = Astro.params;
|
||||||
|
const issue = issues.find(item => item.week === week);
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
<BaseLayout>
|
||||||
|
<div class="mb-8">
|
||||||
|
<a href="/">← Show latest edition</a>
|
||||||
|
</div>
|
||||||
|
<WeekNews {issue} />
|
||||||
|
</BaseLayout>
|
Loading…
Reference in a new issue