Add the rest of the helpers to the recursive extract inline partials function.

This commit is contained in:
Tom Alexander 2020-05-16 12:13:40 -04:00
parent 3c85717952
commit e04a0be5e7
Signed by: talexander
GPG Key ID: D3A179C9A53C0EDE

View File

@ -99,6 +99,65 @@ fn extract_inline_partials_from_tag<'a, 'b>(
blocks.insert(&named_block.name, &named_block.contents); blocks.insert(&named_block.name, &named_block.contents);
} }
DustTag::DTBlock(..) => (), DustTag::DTBlock(..) => (),
_ => (), // TODO: Implement the rest DustTag::DTHelperEquals(parameterized_block) => {
match &parameterized_block.contents {
None => (),
Some(body) => extract_inline_partials_from_body(blocks, &body),
};
match &parameterized_block.else_contents {
None => (),
Some(body) => extract_inline_partials_from_body(blocks, &body),
};
}
DustTag::DTHelperNotEquals(parameterized_block) => {
match &parameterized_block.contents {
None => (),
Some(body) => extract_inline_partials_from_body(blocks, &body),
};
match &parameterized_block.else_contents {
None => (),
Some(body) => extract_inline_partials_from_body(blocks, &body),
};
}
DustTag::DTHelperGreaterThan(parameterized_block) => {
match &parameterized_block.contents {
None => (),
Some(body) => extract_inline_partials_from_body(blocks, &body),
};
match &parameterized_block.else_contents {
None => (),
Some(body) => extract_inline_partials_from_body(blocks, &body),
};
}
DustTag::DTHelperLessThan(parameterized_block) => {
match &parameterized_block.contents {
None => (),
Some(body) => extract_inline_partials_from_body(blocks, &body),
};
match &parameterized_block.else_contents {
None => (),
Some(body) => extract_inline_partials_from_body(blocks, &body),
};
}
DustTag::DTHelperGreaterThenOrEquals(parameterized_block) => {
match &parameterized_block.contents {
None => (),
Some(body) => extract_inline_partials_from_body(blocks, &body),
};
match &parameterized_block.else_contents {
None => (),
Some(body) => extract_inline_partials_from_body(blocks, &body),
};
}
DustTag::DTHelperLessThenOrEquals(parameterized_block) => {
match &parameterized_block.contents {
None => (),
Some(body) => extract_inline_partials_from_body(blocks, &body),
};
match &parameterized_block.else_contents {
None => (),
Some(body) => extract_inline_partials_from_body(blocks, &body),
};
}
} }
} }