Commit Graph

6 Commits (9a0cd3af3b60ccd6ce400539b309026a82788595)

Author SHA1 Message Date
KN4CK3R c9c7afda1a
Add sanitizer rules per renderer ()
* Added sanitizer rules per renderer.

* Updated documentation.

Co-authored-by: techknowlogick <techknowlogick@gitea.io>
Lunny Xiao 9d99f6ab19
Refactor renders ()
* Refactor renders

* Some performance optimization

* Fix comment

* Transform reader

* Fix csv test

* Fix test

* Fix tests

* Improve optimaziation

* Fix test

* Fix test

* Detect file encoding with reader

* Improve optimaziation

* reduce memory usage

* improve code

* fix build

* Fix test

* Fix for go1.15

* Fix render

* Fix comment

* Fix lint

* Fix test

* Don't use NormalEOF when unnecessary

* revert change on util.go

* Apply suggestions from code review

Co-authored-by: zeripath <art27@cantab.net>

* rename function

* Take NormalEOF back

Co-authored-by: zeripath <art27@cantab.net>
Lunny Xiao 66f0fd0959
Add NeedPostProcess for Parser interface to improve performance of csv render ()
KN4CK3R 0c6137617f
Add Tabular Diff for CSV files ()
Implements request  The rendering of CSV files does match the diff style.

* Moved CSV logic into base package.

* Added method to create a tabular diff.

* Added CSV compare context.

* Added CSV diff template.

* Use new table style in CSV markup.

* Added file size limit for CSV rendering.

* Display CSV parser errors in diff.

* Lazy read single file.

* Lazy read rows for full diff.

* Added unit tests for various CSV changes.
Norwin 867f46f78e Detect delimiter in CSV rendering ()
* detect csv delimiter in csv rendering

fixes 

* make linter happy

* fix failing testcase & use ints where possible

* expose markup type to template

previously all markup had the .markdown class, which is incorrect,
as it applies markdown CSS & JS logic to CSV rendering

* fix build (missing `make css`)

* ignore quoted csv content for delimiter scoring

also fix html generation
Lunny Xiao 0bb1c84208 Add csv file render support defaultly ()
* add csv file render support defaultly

* escaping csv column content