diff --git a/.changeset/shaggy-ties-laugh.md b/.changeset/shaggy-ties-laugh.md new file mode 100644 index 0000000..fe11a95 --- /dev/null +++ b/.changeset/shaggy-ties-laugh.md @@ -0,0 +1,5 @@ +--- +'@astro-community/astro-embed-bluesky': patch +--- + +Allow PostView to be passed to embed diff --git a/package-lock.json b/package-lock.json index 26af2a9..fe61af5 100644 --- a/package-lock.json +++ b/package-lock.json @@ -12726,7 +12726,7 @@ }, "packages/astro-embed-bluesky": { "name": "@astro-community/astro-embed-bluesky", - "version": "0.1.0", + "version": "0.1.1", "license": "MIT", "dependencies": { "@atproto/api": "^0.13.14", diff --git a/packages/astro-embed-bluesky/src/index.ts b/packages/astro-embed-bluesky/src/index.ts index d7c284a..409c251 100644 --- a/packages/astro-embed-bluesky/src/index.ts +++ b/packages/astro-embed-bluesky/src/index.ts @@ -1 +1,2 @@ export { default as BlueskyPost } from './post.astro'; +export type { Post } from './types'; diff --git a/packages/astro-embed-bluesky/src/post.astro b/packages/astro-embed-bluesky/src/post.astro index dda99b1..dd94c79 100644 --- a/packages/astro-embed-bluesky/src/post.astro +++ b/packages/astro-embed-bluesky/src/post.astro @@ -4,10 +4,11 @@ import Embed from './embed.astro'; import type { Post } from './types'; import './styles.css'; import Avatar from './avatar.astro'; +import type { AppBskyFeedDefs } from '@atproto/api'; type Props = { id?: string; - post?: string | Post; + post?: string | Post | AppBskyFeedDefs.PostView; }; const postRef = Astro.props.id ?? Astro.props.post;