diff options
Diffstat (limited to 'src/construct/text.rs')
-rw-r--r-- | src/construct/text.rs | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/construct/text.rs b/src/construct/text.rs index 9d40585..65f55d4 100644 --- a/src/construct/text.rs +++ b/src/construct/text.rs @@ -42,13 +42,21 @@ const MARKERS: [u8; 10] = [ /// Start of text. /// +/// There is a slightly weird case where task list items have their check at +/// the start of the first paragraph. +/// So we start by checking for that. +/// /// ```markdown /// > | abc /// ^ /// ``` pub fn start(tokenizer: &mut Tokenizer) -> State { tokenizer.tokenize_state.markers = &MARKERS; - State::Retry(StateName::TextBefore) + tokenizer.attempt( + State::Next(StateName::TextBefore), + State::Next(StateName::TextBefore), + ); + State::Retry(StateName::GfmTaskListItemCheckStart) } /// Before text. |