Skip to content

Commit

Permalink
feat(ai): add bluesky to share component
Browse files Browse the repository at this point in the history
  • Loading branch information
zacjones93 authored and kodiakhq[bot] committed Nov 21, 2024
1 parent 115b317 commit 2a339af
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
20 changes: 20 additions & 0 deletions apps/ai-hero/src/components/share.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,26 @@ export const Share = ({
className="via-foreground/10 absolute -bottom-px left-0 h-px w-2/3 bg-gradient-to-r from-transparent to-transparent"
aria-hidden="true"
/>
<a
href={`https://bsky.app/intent/compose?text=${encodeURIComponent(`${title ? `${title} ` : ''} by ${config.bluesky.handle}
${url}`)}`}
target="_blank"
rel="noopener noreferrer"
>
<svg
width="20"
height="20"
viewBox="0 0 64 57"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
fill="currentColor"
d="M13.873 3.805C21.21 9.332 29.103 20.537 32 26.55v15.882c0-.338-.13.044-.41.867-1.512 4.456-7.418 21.847-20.923 7.944-7.111-7.32-3.819-14.64 9.125-16.85-7.405 1.264-15.73-.825-18.014-9.015C1.12 23.022 0 8.51 0 6.55 0-3.268 8.579-.182 13.873 3.805ZM50.127 3.805C42.79 9.332 34.897 20.537 32 26.55v15.882c0-.338.13.044.41.867 1.512 4.456 7.418 21.847 20.923 7.944 7.111-7.32 3.819-14.64-9.125-16.85 7.405 1.264 15.73-.825 18.014-9.015C62.88 23.022 64 8.51 64 6.55c0-9.818-8.578-6.732-13.873-2.745Z"
/>
</svg>
</a>
<a
href={`https://x.com/intent/tweet?text=${encodeURIComponent(url + `${title ? `${title} ` : ''} by ${config.twitter.handle}`)}`}
target="_blank"
Expand Down
3 changes: 3 additions & 0 deletions apps/ai-hero/src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ const config = {
cardType: 'summary_large_image',
handle: `@${process.env.NEXT_PUBLIC_PARTNER_TWITTER}`,
},
bluesky: {
handle: `@${process.env.NEXT_PUBLIC_PARTNER_BLUESKY}`,
},
sameAs: [`https://twitter.com/${process.env.NEXT_PUBLIC_PARTNER_TWITTER}`],
openGraph: {
type: 'website',
Expand Down

0 comments on commit 2a339af

Please sign in to comment.