Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support tri-backquote style code block and fix ordered list indent #431

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

wetor
Copy link

@wetor wetor commented Nov 4, 2024

Implement #386
testcase: test/backquote_code_style

Fix ordered list indent

<ol start="1">
  <li>
    <span>now with numbers</span>
  </li>
  <li>
    <span>the prisoner</span>
  </li>
  <ol start="1">
    <li>
      <span>not an <i>italic number</i></span>
    </li>
    <li>
      <span>a <b>bold human</b> being</span>
    </li>
  </ol>
  <li>
    <span>end</span>
  </li>
</ol>

now it will be correctly converted into

  1. now with numbers
  2. the prisoner
    1. not an italic number
    2. a bold human being
  3. end

testcase : test/mixed_nested_lists

And, regarding the CLI parameter names and variable names in tri-backquote style, I didn't have a good name, so I used backquote_code_style. What do you think?

@wetor
Copy link
Author

wetor commented Nov 4, 2024

The implementation still has room for optimization, and discussion is welcome.

Copy link

codecov bot commented Nov 13, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.42%. Comparing base (8917f5c) to head (6630122).

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #431      +/-   ##
==========================================
+ Coverage   97.36%   97.42%   +0.06%     
==========================================
  Files          11       11              
  Lines        1137     1164      +27     
==========================================
+ Hits         1107     1134      +27     
  Misses         30       30              
Flag Coverage Δ
unittests-3.10 97.42% <100.00%> (+0.06%) ⬆️
unittests-3.11 97.42% <100.00%> (+0.06%) ⬆️
unittests-3.12 97.42% <100.00%> (+0.06%) ⬆️
unittests-3.8 97.42% <100.00%> (+0.06%) ⬆️
unittests-3.9 97.42% <100.00%> (+0.06%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@zeMingGit
Copy link

Hello author, this function is very practical, I used today, but there is no formal package, I hope to merge and release soon

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants