{r.data.title}
diff --git a/src/pages/blog/index.astro b/src/pages/blog/index.astro
index b20ede9..71d1b5d 100644
--- a/src/pages/blog/index.astro
+++ b/src/pages/blog/index.astro
@@ -2,7 +2,7 @@
import { getCollection, getEntries } from 'astro:content';
import BaseLayout from '@/layouts/BaseLayout.astro';
import BlogFilter from '@/components/BlogFilter.astro';
-import { TOPICS, formatDate, formatMonth, sortPostsByDate } from '@/lib/data';
+import { TOPICS, formatDate, formatMonth, sortPostsByDate, topicName } from '@/lib/data';
const url = new URL(Astro.request.url);
const activeTopic = url.searchParams.get('topic') || 'all';
@@ -56,7 +56,7 @@ all.forEach((a) => {
{a.data.title}
- {a.data.topic}
+ {topicName(a.data.topicId)}
{a.data.tags?.slice(0, 2).map((t) => (
#{t}
))}
diff --git a/src/pages/community/index.astro b/src/pages/community/index.astro
index 7533a4b..d93af6b 100644
--- a/src/pages/community/index.astro
+++ b/src/pages/community/index.astro
@@ -8,7 +8,7 @@ const channels = [
blurb:
'Long-form Q&A, paper threads, RFCs. Tied to your GitHub identity — searchable, attributed, permanent.',
action: 'Open Discussions',
- href: 'https://github.com/orgs/MLSysDev/discussions',
+ href: SITE.orgDiscussionsUrl,
tag: 'asynchronous',
},
{
@@ -23,7 +23,7 @@ const channels = [
label: 'GitHub Issues',
blurb: 'Found a bug on the site, a broken link, or a typo in an article? File it on the repo.',
action: 'Report an issue',
- href: 'https://github.com/MLSysDev/mlsystems.dev/issues',
+ href: SITE.issuesUrl,
tag: 'bug reports',
},
{
diff --git a/src/pages/contact.astro b/src/pages/contact.astro
index 9d4edcf..94d2e2e 100644
--- a/src/pages/contact.astro
+++ b/src/pages/contact.astro
@@ -18,13 +18,13 @@ const channels = [
{
label: 'Discussions',
action: 'Start a thread',
- href: 'https://github.com/orgs/MLSysDev/discussions',
+ href: SITE.orgDiscussionsUrl,
icon: 'M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12',
},
{
label: 'Issues',
action: 'Report a bug',
- href: 'https://github.com/MLSysDev/mlsystems.dev/issues',
+ href: SITE.issuesUrl,
icon: 'M12 2C6.477 2 2 6.484 2 12.017c0 4.425 2.865 8.18 6.839 9.504.5.092.682-.217.682-.483 0-.237-.008-.868-.013-1.703-2.782.605-3.369-1.343-3.369-1.343-.454-1.158-1.11-1.466-1.11-1.466-.908-.62.069-.608.069-.608 1.003.07 1.531 1.032 1.531 1.032.892 1.53 2.341 1.088 2.91.832.092-.647.35-1.088.636-1.338-2.22-.253-4.555-1.113-4.555-4.951 0-1.093.39-1.988 1.029-2.688-.103-.253-.446-1.272.098-2.65 0 0 .84-.27 2.75 1.026A9.564 9.564 0 0 1 12 6.844c.85.004 1.705.115 2.504.337 1.909-1.296 2.747-1.027 2.747-1.027.546 1.379.203 2.398.1 2.651.64.7 1.028 1.595 1.028 2.688 0 3.848-2.339 4.695-4.566 4.943.359.309.678.92.678 1.855 0 1.338-.012 2.419-.012 2.747 0 .268.18.58.688.482A10.02 10.02 0 0 0 22 12.017C22 6.484 17.522 2 12 2z',
},
{
diff --git a/src/pages/contribute/index.astro b/src/pages/contribute/index.astro
index eddf673..30d45b4 100644
--- a/src/pages/contribute/index.astro
+++ b/src/pages/contribute/index.astro
@@ -83,7 +83,7 @@ const STEPS = [
Draft in your browser →
Email an idea
-
- Open a PR
-
+ Open a PR
{a.data.title}
- {a.data.topic} + {topicName(a.data.topicId)} {a.data.tags?.slice(0, 2).map((t) => ( #{t} ))} diff --git a/src/pages/community/index.astro b/src/pages/community/index.astro index 7533a4b..d93af6b 100644 --- a/src/pages/community/index.astro +++ b/src/pages/community/index.astro @@ -8,7 +8,7 @@ const channels = [ blurb: 'Long-form Q&A, paper threads, RFCs. Tied to your GitHub identity — searchable, attributed, permanent.', action: 'Open Discussions', - href: 'https://github.com/orgs/MLSysDev/discussions', + href: SITE.orgDiscussionsUrl, tag: 'asynchronous', }, { @@ -23,7 +23,7 @@ const channels = [ label: 'GitHub Issues', blurb: 'Found a bug on the site, a broken link, or a typo in an article? File it on the repo.', action: 'Report an issue', - href: 'https://github.com/MLSysDev/mlsystems.dev/issues', + href: SITE.issuesUrl, tag: 'bug reports', }, { diff --git a/src/pages/contact.astro b/src/pages/contact.astro index 9d4edcf..94d2e2e 100644 --- a/src/pages/contact.astro +++ b/src/pages/contact.astro @@ -18,13 +18,13 @@ const channels = [ { label: 'Discussions', action: 'Start a thread', - href: 'https://github.com/orgs/MLSysDev/discussions', + href: SITE.orgDiscussionsUrl, icon: 'M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12', }, { label: 'Issues', action: 'Report a bug', - href: 'https://github.com/MLSysDev/mlsystems.dev/issues', + href: SITE.issuesUrl, icon: 'M12 2C6.477 2 2 6.484 2 12.017c0 4.425 2.865 8.18 6.839 9.504.5.092.682-.217.682-.483 0-.237-.008-.868-.013-1.703-2.782.605-3.369-1.343-3.369-1.343-.454-1.158-1.11-1.466-1.11-1.466-.908-.62.069-.608.069-.608 1.003.07 1.531 1.032 1.531 1.032.892 1.53 2.341 1.088 2.91.832.092-.647.35-1.088.636-1.338-2.22-.253-4.555-1.113-4.555-4.951 0-1.093.39-1.988 1.029-2.688-.103-.253-.446-1.272.098-2.65 0 0 .84-.27 2.75 1.026A9.564 9.564 0 0 1 12 6.844c.85.004 1.705.115 2.504.337 1.909-1.296 2.747-1.027 2.747-1.027.546 1.379.203 2.398.1 2.651.64.7 1.028 1.595 1.028 2.688 0 3.848-2.339 4.695-4.566 4.943.359.309.678.92.678 1.855 0 1.338-.012 2.419-.012 2.747 0 .268.18.58.688.482A10.02 10.02 0 0 0 22 12.017C22 6.484 17.522 2 12 2z', }, { diff --git a/src/pages/contribute/index.astro b/src/pages/contribute/index.astro index eddf673..30d45b4 100644 --- a/src/pages/contribute/index.astro +++ b/src/pages/contribute/index.astro @@ -83,7 +83,7 @@ const STEPS = [ Draft in your browser → Email an idea - - Open a PR - + Open a PR{p.data.title}
{p.data.summary}
@@ -234,7 +234,7 @@ const featuredTools = allTools discussions, and feature proposals. Searchable, attributed, permanent. !data.draft && !data.cover); @@ -19,7 +20,7 @@ export const GET: APIRoute = async ({ props }) => { return generateOgPng({ title: post.data.title, authorNames: authors.map((a) => a.data.name).join(', '), - topic: post.data.topic, + topic: topicName(post.data.topicId), }); }, `post:${post.id}`); }; diff --git a/src/pages/rss.xml.ts b/src/pages/rss.xml.ts index f735672..6200112 100644 --- a/src/pages/rss.xml.ts +++ b/src/pages/rss.xml.ts @@ -2,7 +2,7 @@ import rss from '@astrojs/rss'; import { getCollection, getEntries } from 'astro:content'; import type { APIContext } from 'astro'; import { SITE } from '@/lib/site'; -import { sortPostsByDate } from '@/lib/data'; +import { sortPostsByDate, topicName } from '@/lib/data'; export async function GET(context: APIContext) { const postsRaw = (await getCollection('posts', ({ data }) => !data.draft)).sort(sortPostsByDate); @@ -24,7 +24,7 @@ export async function GET(context: APIContext) { pubDate: p.data.date, link: `/blog/${p.id}/`, author: p.authorNames, - categories: [p.data.topic, ...(p.data.tags ?? [])], + categories: [topicName(p.data.topicId), ...(p.data.tags ?? [])], customData: `