creativecommons / cc-legal-tools-app

Legal tool (licenses, public domain dedication, etc.) management application for Creative Commons
https://creativecommons.org/licenses/
MIT License
97 stars 94 forks source link

[Bug] Extraneous spaces in HTML #485

Open TimidRobot opened 4 weeks ago

TimidRobot commented 4 weeks ago

Description

Due to a combination of string separation to aid translation and HTML formatting via BeautifulSoup4, the published HTML output includes extraneous spaces.

Example:

docs/licenses/by/4.0/legalcode.en.html lines 559-562:

       <strong>
        License grant
       </strong>
       .

Results in:

Screenshot 2024-10-28 at 10 15 57

Expectation

Extraneous whitespace should not be included in rendered / user-facing text.

Additional context

Requirements

Documentation

Resolution

TimidRobot commented 4 weeks ago

HTML formatting tools are surprisingly evasive. The best one I've encountered so far is Prettier · Opinionated Code Formatter, but I haven't found or developed a good way to integrate it into a Python project.

LMDcoded commented 4 weeks ago

Hi @TimidRobot! I’d be interested in working on this issue. I’ll start by exploring options to clean up the extra spaces without disrupting the translation structure. Will keep you posted on progress and any solutions I find. Thanks for outlining the context so clearly!

VibhorShukla-BHRT commented 2 weeks ago

HI @TimidRobot! I can resolve this issue, please assign this issue to me :)

eskayML commented 5 days ago

Hello, @maintainers

please can i raise a PR for this