Skip to content

Commit cc8ff36

Browse files
Add support for Divider block type ✨
1 parent 82e978d commit cc8ff36

File tree

3 files changed

+41
-0
lines changed

3 files changed

+41
-0
lines changed
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
using Newtonsoft.Json;
2+
3+
namespace Notion.Client
4+
{
5+
public class DividerUpdateBlock : IUpdateBlock
6+
{
7+
public bool Archived { get; set; }
8+
9+
[JsonProperty("divider")]
10+
public Data Divider { get; set; }
11+
12+
public class Data
13+
{
14+
15+
}
16+
17+
public DividerUpdateBlock()
18+
{
19+
Divider = new Data();
20+
}
21+
}
22+
}

Src/Notion.Client/Models/Blocks/BlockType.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,9 @@ public enum BlockType
6161
[EnumMember(Value = "breadcrumb")]
6262
Breadcrumb,
6363

64+
[EnumMember(Value = "divider")]
65+
Divider,
66+
6467
[EnumMember(Value = "unsupported")]
6568
Unsupported
6669
}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
using Newtonsoft.Json;
2+
3+
namespace Notion.Client
4+
{
5+
public class DividerBlock : Block
6+
{
7+
public override BlockType Type => BlockType.Divider;
8+
9+
[JsonProperty("divider")]
10+
public Data Divider { get; set; }
11+
12+
public class Data
13+
{
14+
}
15+
}
16+
}

0 commit comments

Comments
 (0)