mirror of
https://github.com/dstotijn/go-notion.git
synced 2025-06-08 23:46:12 +02:00
Add quote block type, simplify callout block type
This commit is contained in:
parent
a45f658ecc
commit
0060b295c2
5
block.go
5
block.go
@ -25,6 +25,7 @@ type Block struct {
|
|||||||
Toggle *RichTextBlock `json:"toggle,omitempty"`
|
Toggle *RichTextBlock `json:"toggle,omitempty"`
|
||||||
ChildPage *ChildPage `json:"child_page,omitempty"`
|
ChildPage *ChildPage `json:"child_page,omitempty"`
|
||||||
Callout *Callout `json:"callout,omitempty"`
|
Callout *Callout `json:"callout,omitempty"`
|
||||||
|
Quote *RichTextBlock `json:"quote,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type RichTextBlock struct {
|
type RichTextBlock struct {
|
||||||
@ -46,9 +47,8 @@ type ChildPage struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Callout struct {
|
type Callout struct {
|
||||||
Text []RichText `json:"text"`
|
RichTextBlock
|
||||||
Icon *Icon `json:"icon,omitempty"`
|
Icon *Icon `json:"icon,omitempty"`
|
||||||
Children []Block `json:"children,omitempty"`
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type BlockType string
|
type BlockType string
|
||||||
@ -64,6 +64,7 @@ const (
|
|||||||
BlockTypeToggle BlockType = "toggle"
|
BlockTypeToggle BlockType = "toggle"
|
||||||
BlockTypeChildPage BlockType = "child_page"
|
BlockTypeChildPage BlockType = "child_page"
|
||||||
BlockTypeCallout BlockType = "callout"
|
BlockTypeCallout BlockType = "callout"
|
||||||
|
BlockTypeQuote BlockType = "quote"
|
||||||
BlockTypeUnsupported BlockType = "unsupported"
|
BlockTypeUnsupported BlockType = "unsupported"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user