From 71a52a16c44e3568128c83070541235133c44436 Mon Sep 17 00:00:00 2001 From: Micah Halter Date: Fri, 13 Oct 2023 10:18:12 -0400 Subject: feat: add Reddit social icon (#854) Co-authored-by: Chris Swithinbank --- .changeset/clean-lies-wink.md | 5 +++++ docs/src/content/docs/guides/customization.mdx | 2 +- docs/src/content/docs/reference/configuration.md | 2 +- packages/starlight/components/Icons.ts | 2 ++ packages/starlight/schemas/social.ts | 2 ++ 5 files changed, 11 insertions(+), 2 deletions(-) create mode 100644 .changeset/clean-lies-wink.md diff --git a/.changeset/clean-lies-wink.md b/.changeset/clean-lies-wink.md new file mode 100644 index 00000000..d36b1301 --- /dev/null +++ b/.changeset/clean-lies-wink.md @@ -0,0 +1,5 @@ +--- +'@astrojs/starlight': patch +--- + +Add Reddit icon diff --git a/docs/src/content/docs/guides/customization.mdx b/docs/src/content/docs/guides/customization.mdx index 3a0905ee..a86cdb41 100644 --- a/docs/src/content/docs/guides/customization.mdx +++ b/docs/src/content/docs/guides/customization.mdx @@ -191,7 +191,7 @@ defineConfig({ Starlight has built-in support for adding links to your social media accounts to the site header via the [`social`](/reference/configuration/#social) option in the Starlight integration. -Currently, links to Bitbucket, Codeberg, CodePen, Discord, Email, Facebook, GitHub, GitLab, Gitter, Instagram, LinkedIn, Mastodon, Microsoft Teams, an RSS feed, Stack Overflow, Telegram, Threads, Twitch, Twitter, X, and Youtube are supported. +Currently, links to Bitbucket, Codeberg, CodePen, Discord, Email, Facebook, GitHub, GitLab, Gitter, Instagram, LinkedIn, Mastodon, Microsoft Teams, Reddit, an RSS feed, Stack Overflow, Telegram, Threads, Twitch, Twitter, X, and Youtube are supported. Let us know on GitHub or Discord if you need support for another service! ```js diff --git a/docs/src/content/docs/reference/configuration.md b/docs/src/content/docs/reference/configuration.md index 9cd51a22..9cdeaeed 100644 --- a/docs/src/content/docs/reference/configuration.md +++ b/docs/src/content/docs/reference/configuration.md @@ -308,7 +308,7 @@ The default locale will be used to provide fallback content where translations a ### `social` -**type:** `Partial>` +**type:** `Partial>` Optional details about the social media accounts for this site. Adding any of these will display them as icon links in the site header. diff --git a/packages/starlight/components/Icons.ts b/packages/starlight/components/Icons.ts index 2f51cea7..711b3e75 100644 --- a/packages/starlight/components/Icons.ts +++ b/packages/starlight/components/Icons.ts @@ -95,4 +95,6 @@ export const Icons = { '', email: '', + reddit: + '' }; diff --git a/packages/starlight/schemas/social.ts b/packages/starlight/schemas/social.ts index f199e766..b55dc944 100644 --- a/packages/starlight/schemas/social.ts +++ b/packages/starlight/schemas/social.ts @@ -25,6 +25,7 @@ export const SocialLinksSchema = () => 'rss', 'facebook', 'email', + 'reddit', ]), // Link to the respective social profile for this site z.string().url() @@ -57,6 +58,7 @@ export const SocialLinksSchema = () => rss: 'RSS', facebook: 'Facebook', email: 'Email', + reddit: 'Reddit', }[key]; labelledLinks[key] = { label, url }; } -- cgit