Fixed a bug in parsing indented chunks with blank lines (#33)
Revised the algorithm for determining node depth in the AST to better work with fenced divs
As a consequnce of these changes by_section() may yield slighly different results in some cases.
The rmd_node_depth() function was added to expose these depth calculations.
Add support for pandoc fenced attributes for headings
Added wrap_children argument to rmd_fenced_div_wrap() to control whether the selected nodes or their children are wrapped.
Fixed a several bugs around handling of rmd_tibble methods (@ateucher)
Breaking Change: Migrated from S3/S4 classes to S7 classes for all AST node types (rmd_ast, rmd_chunk, rmd_heading, etc.)
Breaking Change: Removed deprecated rmd_subset() and related helper functions (rmd_get_node(), rmd_get_chunk(), rmd_get_markdown(), rmd_has_node(), rmd_has_chunk(), rmd_has_markdown()). Use rmd_select() with tidyselect syntax instead.
Added support for yaml chunk options - e.g. (#| echo: false)
Added support for fenced divs - e.g. (::: {.class} ... :::)
Added support for markdown code blocks
Added support for yaml expressions - e.g. (!expr)
Added support for parsing collections of Rmd and qmd files - see parse_qmd_collection() and parse_rmd_collection()
Removed option to not parse yaml - this is now always parsed. Based on this yaml node classes were simplified to just include rmd_yaml.
Added support for Pandoc-style ordered fenced attributes for code blocks, fenced divs, and spans
Added rmd_fenced_div_wrap() function to wrap selected nodes with fenced divs
Added rmd_insert() function to insert nodes relative to selected nodes
Added support for code block literals - e.g. ```{{r}}
Added support for 2ndary parsing to handle inline elements:
Enhanced rmd_select() functionality and node manipulation
has_heading() helper function for selecting heading nodes using glob patternsby_fenced_div() helper function for selecting fenced div sections using attribute patternskeep_yaml argument to rmd_select() (defaults to TRUE) to automatically include YAML nodes in selectionsUnlabeled chunks will now be labeled as unnamed-chunk-n, with n incrementing.
Minor fixes and updates to resolve CRAN warnings.
LANG=en_US.iso88591 LC_ALL=en_US.iso88591 R CMD check)Added new parser error reporting system
Adopt testthat 3.0.0 for testing
Added new render function to support rendering rmd_ast related objects
Added rmd_get_options and rmd_set_options
Added support for raw attribute chunks (#13)
Added rmd_source to support sourcing chunks directly into an environment.
Added rmd_select which uses tidyselect based syntax as a replacement for rmd_subset.
Soft deprecated rmd_subset, rmd_get_node, rmd_get_markdwon, and rmd_get_chunk.
Added a NEWS.md file to track changes to the package.
Incremented the version number.
Overhauled the ast and tibble representations to make them as compatible as possible.
Starting to add helper functions: rmd_subset, rmd_has_node, rmd_get_node, etc.
Initial implementation of Rmd templates