Skip to content

Commit

Permalink
fix(deps): update dependency highlight.js to v11 (#176)
Browse files Browse the repository at this point in the history
* fix(deps): update dependency highlight.js to v11

* Fix styles + fix deprecated call

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Alex <[email protected]>
  • Loading branch information
renovate[bot] and alxhotel authored Oct 8, 2022
1 parent 8a448cf commit 2e37f9a
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 11 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,5 @@ static/style.css
static/torrents/*
!static/torrents/*.torrent
!static/torrents/README.md

tmp
2 changes: 1 addition & 1 deletion client/style.styl
Original file line number Diff line number Diff line change
Expand Up @@ -805,7 +805,7 @@ body.is-seed .show-leech
.error-list.visible
display: block

@import '../node_modules/highlight.js/styles/zenburn.css'
@import '../node_modules/highlight.js/styles/base16/zenburn.css'

#carbonads {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu,
Expand Down
16 changes: 8 additions & 8 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"express": "4.18.1",
"express-rate-limit": "6.6.0",
"gitter-irc-bot": "1.6.0",
"highlight.js": "10.7.3",
"highlight.js": "11.6.0",
"moment": "2.29.4",
"morgan": "1.10.0",
"multer": "1.4.4",
Expand Down
2 changes: 1 addition & 1 deletion server/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const remark = new Remarkable({
html: true,
highlight: function (code, lang) {
const h = lang
? highlight.highlight(lang, code)
? highlight.highlight(code, { language: lang })
: highlight.highlightAuto(code)
return '<div class="hljs">' + h.value + '</div>'
}
Expand Down

0 comments on commit 2e37f9a

Please sign in to comment.