Skip to content

Commit e49f2ab

Browse files
committed
fix(astro-portabletext): add PortableTextBlock type
1 parent a29b920 commit e49f2ab

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.changeset/four-stingrays-trade.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"astro-portabletext": patch
3+
---
4+
5+
Added `PortableTextBlock` type to `PortableTextProps<Value>` parameter

astro-portabletext/src/types.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ export type { TypedObject } from "@portabletext/types";
2525
* @template Value Portable Text payload
2626
*/
2727
export interface PortableTextProps<
28-
Value extends TypedObject = ArbitraryTypedObject
28+
Value extends TypedObject = PortableTextBlock | ArbitraryTypedObject
2929
> {
3030
/**
3131
* Portable Text blocks

0 commit comments

Comments
 (0)