Skip to content

Commit

Permalink
add support for isso gravatar
Browse files Browse the repository at this point in the history
  • Loading branch information
rocka committed Apr 30, 2018
1 parent f69c336 commit d47b83c
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 4 deletions.
9 changes: 7 additions & 2 deletions config.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,11 +72,16 @@ module.exports = {
embed: 'https://isso.rocka.me/js/embed.min.js',
// Isso usually detects the REST API automatically, but when you serve the JS script on a different location,
// this may fail. Use data-isso to override the API location.
prefix: '',
prefix: 'https://isso.rocka.me',
// Enable or disable voting feature on the client side.
vote: true,
// Enable or disable avatar generation.
avatar: true,
// Uses gravatar images instead of generating svg images.
// You have to set `isso.avatar` to false when you want to use this,
// otherwise both the gravatar and avatar svg image will show up.
// Please also set option "gravatar" to true in the server configuration.
gravatar: false,
// Number of comments to reveal on clicking the “X Hidden” link.
reveal: 5,
// Set to true when spam guard is configured with require-author = true.
Expand All @@ -87,7 +92,7 @@ module.exports = {
replySelf: false,
// Number of top level (or nested) comments to show by default.
// If some comments are not shown, an “X Hidden” link is shown.
maxCommentsTop: 10,
maxCommentsTop: 1,
maxCommentsNested: 5
}
}
Expand Down
8 changes: 6 additions & 2 deletions template/assets/isso.css
Original file line number Diff line number Diff line change
Expand Up @@ -100,12 +100,16 @@
}

.isso-thread .isso-comment .avatar {
width: 40px;
height: 40px;
float: left;
margin-right: 0.83rem;
}

.isso-thread .isso-comment .avatar,
.isso-thread .isso-comment .avatar img {
width: 40px;
height: 40px;
}

.isso-thread .isso-comment .isso-comment-header {
line-height: 40px;
}
Expand Down
1 change: 1 addition & 0 deletions template/isso.pug
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@ script(
data-isso-max-comments-nested=(isso.maxCommentsNested == 5 ? false : isso.maxCommentsNested)
data-isso-reveal-on-click=(isso.reveal == 5 ? false : isso.reveal)
data-isso-avatar=(isso.avatar === false ? "false" : false)
data-isso-gravatar=(isso.gravatar === true ? "true" : false)
data-isso-vote=(isso.vote === false ? "false" : false)
)

0 comments on commit d47b83c

Please sign in to comment.