aboutsummaryrefslogtreecommitdiffstats
path: root/modules/markup/sanitizer_test.go
Commit message (Collapse)AuthorAgeFilesLines
* Implement FSFE REUSE for golang files (#21840)flynnnnnnnnnn2022-11-271-2/+1
| | | | | | | | | Change all license headers to comply with REUSE specification. Fix #16132 Co-authored-by: flynnnnnnnnnn <flynnnnnnnnnn@github> Co-authored-by: John Olheiser <john.olheiser@gmail.com>
* Allow to specify colors for text in markup (#20363)Gusted2022-07-151-0/+8
| | | | `<span style="color: red">Hello World!</span>` will now be accepted by Bluemonday, other properties are still disallowed by Bluemonday.
* Add more linters to improve code readability (#19989)Wim2022-06-201-1/+1
| | | | | | | | | | Add nakedret, unconvert, wastedassign, stylecheck and nolintlint linters to improve code readability - nakedret - https://github.com/alexkohler/nakedret - nakedret is a Go static analysis tool to find naked returns in functions greater than a specified function length. - unconvert - https://github.com/mdempsky/unconvert - Remove unnecessary type conversions - wastedassign - https://github.com/sanposhiho/wastedassign - wastedassign finds wasted assignment statements. - notlintlint - Reports ill-formed or insufficient nolint directives - stylecheck - https://staticcheck.io/docs/checks/#ST - keep style consistent - excluded: [ST1003 - Poorly chosen identifier](https://staticcheck.io/docs/checks/#ST1003) and [ST1005 - Incorrectly formatted error string](https://staticcheck.io/docs/checks/#ST1005)
* format with gofumpt (#18184)65432022-01-201-1/+0
| | | | | | | | | | | * gofumpt -w -l . * gofumpt -w -l -extra . * Add linter * manual fix * change make fmt
* Fix data URI scramble (#16098)KN4CK3R2021-06-071-1/+0
| | | | | | | * Removed unused method. * No prefix for data uris. * Added test to prevent regressions.
* Update to bluemonday-1.0.6 (#15294)zeripath2021-04-051-0/+12
| | | Signed-off-by: Andrew Thornton <art27@cantab.net>
* Markdown task list improvements (#13952)silverwind2020-12-131-1/+1
| | | | | | | | | | | | * Markdown task list improvements - Remove `.ui` class and wrappers to prevent fomantic from messing with it. - Change rendered HTML to match GitHub. - Add custom styling for the checkboxes. * fix unittest Co-authored-by: Lauris BH <lauris@nix.lv> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* Restore checkbox rendering and prevent poor sanitization of spans (#11277)zeripath2020-05-031-0/+5
| | | | | | | | | | | | | | | | | * Add test Signed-off-by: Andrew Thornton <art27@cantab.net> * Restore checkbox rendering and prevent poor sanitization of spans Signed-off-by: Andrew Thornton <art27@cantab.net> * Also fix preview context Signed-off-by: Andrew Thornton <art27@cantab.net> * Also fix preview context Signed-off-by: Andrew Thornton <art27@cantab.net>
* Allow kbd tags (#9245)John Olheiser2019-12-031-0/+3
| | | | | | | | | | * Allow kbd tags Signed-off-by: jolheiser <john.olheiser@gmail.com> * Add test Signed-off-by: jolheiser <john.olheiser@gmail.com>
* Restructure markup & markdown to prepare for multiple markup languageā€¦ (#2411)Lunny Xiao2017-09-161-0/+44
* restructure markup & markdown to prepare for multiple markup languages support * adjust some functions between markdown and markup * fix tests * improve the comments