📝 Add docstrings to codex/wrap-text-paragraphs-and-list-items-at-80-columns#35
Conversation
…columns` Docstrings generation was requested by @leynos. * #32 (comment) The following files were modified: * `src/html.rs` * `src/lib.rs` * `tests/integration.rs`
Reviewer's GuideThis PR enriches the codebase with detailed Rustdoc comments and examples for key markdown-wrapping and HTML-table–conversion functions in lib.rs and html.rs, and adds documentation to integration tests to clarify their intent and expected behavior. Class Diagram: Modules with Newly Documented FunctionsclassDiagram
direction LR
class lib_rs {
+is_fence(line: &str) bool
+flush_paragraph(out: &mut Vec~String~, buf: &Tuple~String,bool~[], indent: &str, width: usize) void
+wrap_text(lines: &String[], width: usize) Vec~String~
+process_stream(lines: &String[]) Vec~String~
}
class html_rs {
+push_html_line(line: &str, buf: &mut Vec~String~, out: &mut Vec~String~, html_state: &mut HtmlState) void
+html_table_to_markdown(lines: &String[]) Vec~String~
+convert_html_tables(lines: &String[]) Vec~String~
}
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
|
Important Review skippedCodeRabbit bot authored PR detected. To trigger a single review, invoke the You can disable this status message by setting the 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
5b5e710
into
codex/wrap-text-paragraphs-and-list-items-at-80-columns
* Add wrapping for paragraphs and list items * Preserve hard breaks when wrapping * Add test for short list item wrapping * 📝 Add docstrings to `codex/wrap-text-paragraphs-and-list-items-at-80-columns` (#35) Docstrings generation was requested by @leynos. * #32 (comment) The following files were modified: * `src/html.rs` * `src/lib.rs` * `tests/integration.rs` Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> --------- Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Docstrings generation was requested by @leynos.
The following files were modified:
src/html.rssrc/lib.rstests/integration.rsThese file types are not supported
Cargo.tomlREADME.mdℹ️ Note
Summary by Sourcery
Add comprehensive docstrings to core text wrapping and HTML table conversion routines and document integration tests for clarity.
Enhancements:
is_fence,flush_paragraph,wrap_text,process_stream)push_html_line,html_table_to_markdown,convert_html_tables)Tests: