markdown tables support #1

Merged
ryan merged 1 commits from markdown-tables into master 2025-08-14 20:31:38 -04:00
Owner

Summary

This PR adds full support for rendering markdown tables in the ObsWiki application. The changes enable proper HTML table generation from
standard markdown table syntax.

Changes Made

Core Feature:

  • Markdown Table Rendering (src/markdown/mod.rs):
    • Added Options import from pulldown-cmark crate
    • Updated parser to use Parser::new_ext() with Options::ENABLE_TABLES flag
    • Added comprehensive test coverage for table rendering verification
    • Tables now render with proper HTML structure (, , ,
      , )

      Bug Fixes:

      • Fixed Relative Link Processing (src/markdown/mod.rs):
        • Added logic to prepend /wiki/ prefix to relative links that don't start with http, /, or #
        • Ensures links like Page correctly become /wiki/page-name
        • Added test case to verify the fix

      UI/UX Improvements (src/server/mod.rs):

      • Navigation Redesign: Moved navigation to right-side column with clean styling
      • Typography: Changed to serif fonts throughout the interface
      • Filetree Enhancements:
        • Added collapsible "📁 Filetree" with toggle functionality
        • Moved filetree above article content
        • Folder pages show filetree open by default, wiki pages start closed
        • Implemented lazy loading for better performance
      • Styling: Removed rounded corners and shadows for cleaner, minimal design

      Documentation:

      • Task Log Updates (TASK_LOG.md): Comprehensive documentation of all development tasks and changes made

      Test Plan

      • Verify markdown tables render correctly with headers and data rows
      • Test relative link processing adds proper /wiki/ prefixes
      • Confirm navigation layout works on both folder and wiki pages
      • Validate filetree toggle functionality works as expected
      • Check compilation passes with cargo check

      Technical Notes

      • Uses pulldown-cmark's built-in table extension
      • Maintains backward compatibility with existing markdown content
      • No breaking changes to existing API or functionality
Summary This PR adds full support for rendering markdown tables in the ObsWiki application. The changes enable proper HTML table generation from standard markdown table syntax. Changes Made Core Feature: - Markdown Table Rendering (src/markdown/mod.rs): - Added Options import from pulldown-cmark crate - Updated parser to use Parser::new_ext() with Options::ENABLE_TABLES flag - Added comprehensive test coverage for table rendering verification - Tables now render with proper HTML structure (<table>, <thead>, <tbody>, <th>, <td>) Bug Fixes: - Fixed Relative Link Processing (src/markdown/mod.rs): - Added logic to prepend /wiki/ prefix to relative links that don't start with http, /, or # - Ensures links like [Page](page-name) correctly become /wiki/page-name - Added test case to verify the fix UI/UX Improvements (src/server/mod.rs): - Navigation Redesign: Moved navigation to right-side column with clean styling - Typography: Changed to serif fonts throughout the interface - Filetree Enhancements: - Added collapsible "📁 Filetree" with toggle functionality - Moved filetree above article content - Folder pages show filetree open by default, wiki pages start closed - Implemented lazy loading for better performance - Styling: Removed rounded corners and shadows for cleaner, minimal design Documentation: - Task Log Updates (TASK_LOG.md): Comprehensive documentation of all development tasks and changes made Test Plan - Verify markdown tables render correctly with headers and data rows - Test relative link processing adds proper /wiki/ prefixes - Confirm navigation layout works on both folder and wiki pages - Validate filetree toggle functionality works as expected - Check compilation passes with cargo check Technical Notes - Uses pulldown-cmark's built-in table extension - Maintains backward compatibility with existing markdown content - No breaking changes to existing API or functionality
ryan added 1 commit 2025-08-14 20:31:09 -04:00
ryan merged commit 9fbeb0afa5 into master 2025-08-14 20:31:38 -04:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: ryan/obswiki#1