hive-react-kit 0.9.7 → 0.9.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,31 @@
1
+ /**
2
+ * Shared media-extraction helpers for the post-card lists. Walks
3
+ * `post.json_metadata.image` plus the body for embedded images, YouTube
4
+ * links, 3Speak links, and X.com / Twitter status links — returns a
5
+ * deduped, ordered list. Used by both <BlogPostList/> and
6
+ * <UserDetailProfile/>'s renderPostItem to drive the right-side media
7
+ * strip.
8
+ */
9
+ import type { Post } from '@/types/post';
10
+ export type PostMedia = {
11
+ kind: 'image';
12
+ url: string;
13
+ } | {
14
+ kind: 'youtube';
15
+ id: string;
16
+ } | {
17
+ kind: 'threespeak';
18
+ url: string;
19
+ } | {
20
+ kind: 'twitter';
21
+ id: string;
22
+ url: string;
23
+ };
24
+ export declare function extractPostMedia(post: Post): PostMedia[];
25
+ /** Pull `?v=author/permlink` out of any 3Speak URL shape. Returns null
26
+ * for unrecognised URLs (rare; older 3Speak embeds use a path-style
27
+ * identifier instead of a query param). */
28
+ export declare function parseThreeSpeakRef(url: string): {
29
+ author: string;
30
+ permlink: string;
31
+ } | null;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "hive-react-kit",
3
3
  "private": false,
4
- "version": "0.9.7",
4
+ "version": "0.9.8",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs.js",
7
7
  "module": "./dist/index.esm.js",