Open VladimirAlexiev opened 2 years ago
Default template is here. CSS for colors is in the head matter.
Most complicated inline code is for calculating test percentages, and it should be pretty close to what you need. Most be pre-computing and storing in memory would simplify the summary.
I can spend some time with it when I’m back from vacation next week.
@mkotoff is starting on this. We looked at the Haml, and we think all we need is there for the picking.
https://github.com/gkellogg/earl-report/blob/master/lib/earl_report/views/earl_report.html.haml is only an example, right? https://github.com/w3c/json-ld-api/blob/main/reports/template.haml is the only Haml used for the report in question?
So I think we'll submit a PR against the latter, with a small PR to the README of the former just describing the new functionality and providing a pointer?
The version in the earl_report gem is the default, and can be overridden, which is done in the json-ld report as you noted, so yes, changes to the base will need to be ported over, or changes to the template in the JSON-LD repo will need to be back-ported. Maybe easier to work on the one in the JSON-LD repo which has more data to look for the expected results. I can back-port to earl_report.
@VladimirAlexiev did you end up adding a summary report to one of your implementations? I'd like to add that into the built-in template. If you could provide a format, that would be great.
(from this thread https://twitter.com/valexiev1/status/1546427579363631104)
Eg https://w3c.github.io/json-ld-api/reports/: add new sec![image](https://user-images.githubusercontent.com/536250/179220105-f2698909-9b9c-4305-92b1-a50d47a0f2c8.png)
4 Summary Table
with a summary like in this sheetThese are hand-made optimizations that the feature probably cannot do:
@gkellogg "this is auto-generated from individual EARL reports. It would be cool to generate a table like this in HTML. Should be doable. The software that generates the report is open-source. The HTML version is generated from a Haml template, which iterates on the JSON-LD version. Adding a summary table should be straightforward."
Thanks! I don't know Ruby or Haml, but I've read some Ruby and I hope Haml is straightforward. If not, I'll try to coopt a colleague.
Can you point me to: