initial commit
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
#pragma once
|
||||
|
||||
#include "Node.h"
|
||||
#include "InlineNode.h"
|
||||
#include <vector>
|
||||
#include <string>
|
||||
|
||||
struct BlockNode : public Node {
|
||||
virtual ~BlockNode() = default;
|
||||
};
|
||||
@@ -0,0 +1,11 @@
|
||||
#pragma once
|
||||
|
||||
#include "BlockNode.h"
|
||||
|
||||
struct CodeBlock : public BlockNode {
|
||||
std::string code;
|
||||
|
||||
NodeKind getKind() const {
|
||||
return NodeKind::CodeBlock;
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,12 @@
|
||||
#pragma once
|
||||
|
||||
#include "BlockNode.h"
|
||||
|
||||
struct Header : public BlockNode {
|
||||
std::string headerText;
|
||||
std::vector<std::unique_ptr<InlineNode>> children;
|
||||
|
||||
NodeKind getKind() const {
|
||||
return NodeKind::Header;
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,12 @@
|
||||
#pragma once
|
||||
|
||||
#include "BlockNode.h"
|
||||
#include "ListItem.h"
|
||||
|
||||
struct List : public BlockNode {
|
||||
std::vector<std::unique_ptr<ListItem>> children;
|
||||
|
||||
NodeKind getKind() const {
|
||||
return NodeKind::List;
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,11 @@
|
||||
#pragma once
|
||||
|
||||
#include "BlockNode.h"
|
||||
|
||||
struct ListItem : public BlockNode {
|
||||
std::vector<std::unique_ptr<InlineNode>> children;
|
||||
|
||||
NodeKind getKind() const {
|
||||
return NodeKind::ListItem;
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,11 @@
|
||||
#pragma once
|
||||
|
||||
#include "BlockNode.h"
|
||||
|
||||
struct Paragraph : public BlockNode {
|
||||
std::vector<std::unique_ptr<InlineNode>> children;
|
||||
|
||||
NodeKind getKind() const {
|
||||
return NodeKind::Paragraph;
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user