Skip to content

Extract HTML report layout into Templates fragments#196

Open
ewels wants to merge 2 commits into
s-andrews:masterfrom
ewels:cursor/html-template-fragments-753d
Open

Extract HTML report layout into Templates fragments#196
ewels wants to merge 2 commits into
s-andrews:masterfrom
ewels:cursor/html-template-fragments-753d

Conversation

@ewels
Copy link
Copy Markdown
Contributor

@ewels ewels commented May 20, 2026

Another small change split off from #161

This one refactors how the HTML reports are generated a bit - instead of using the Java HTML constructor walker (which makes me want to stab forks in my leg) I've introduced some HTML fragment templates. The Java code pulls these in and then swaps out some {{THING}} placeholders with the dynamic bits.

There was also a CSS file that had a HTML file ending, which I renamed to be .css without any content changing so that stuff like syntax highlighting etc. works.

Outputs are byte-identical against master for test/data/minimal.fastq, so this is really a dev-only refactoring that should have zero impact on outputs.

cursoragent and others added 2 commits May 20, 2026 22:49
Move stylesheet to Templates/fastqc.css and split the static HTML
scaffold into report_template.html, sidebar_item.html, and
module_wrapper.html. HTMLReportArchive assembles these with placeholder
replacement; module bodies are still generated via XMLStreamWriter.

Output verified byte-identical against master for test/data/minimal.fastq.

Co-authored-by: Phil Ewels <phil.ewels@seqera.io>
Makes report_template.html, sidebar_item.html, and module_wrapper.html
easier to read and edit. Generated HTML reports are no longer minified.

Co-authored-by: Phil Ewels <phil.ewels@seqera.io>
@ewels
Copy link
Copy Markdown
Contributor Author

ewels commented May 20, 2026

Ack I couldn't do it sorry, I couldn't resist pushing a second commit that added whitespace to the HTML template files. It'll add additional whitespace to the HTML reports so no longer byte-identical, feel free to revert if you like. It is just a lot easier to read when it's indented.

@ewels ewels mentioned this pull request May 21, 2026
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