Commit 59bdae82 authored by Rene Saarsoo's avatar Rene Saarsoo
Browse files

Use the amazing MonsterID as default avatar.

parent b34a2b65
Loading
Loading
Loading
Loading
+10 −0
Original line number Diff line number Diff line
@@ -103,6 +103,16 @@ Ext.define('Docs.Comments', {
    buildUrl: function(url) {
        url = Docs.baseUrl + '/' + Docs.commentsDb + '/' + Docs.commentsVersion + url;
        return url + (url.match(/\?/) ? '&' : '?') + 'sid=' + Docs.Auth.getSid();
    },

    /**
     * Generates an `<img>` tag for loading the avatar.
     * @param {String} emailHash MD5 hash of users e-mail address.
     * @return {String}
     */
    avatar: function(emailHash) {
        return '<img class="avatar" width="25" height="25" src="http://www.gravatar.com/avatar/' +
               emailHash + '?s=25&amp;r=PG&amp;d=monsterid">';
    }

});
+3 −3
Original line number Diff line number Diff line
@@ -6,7 +6,8 @@ Ext.define('Docs.view.comments.List', {
    alias: 'widget.commentsList',
    requires: [
        'Docs.Auth',
        'Docs.Syntax'
        'Docs.Syntax',
        'Docs.Comments'
    ],

    itemSelector: "div.comment",
@@ -35,8 +36,7 @@ Ext.define('Docs.view.comments.List', {
                '<tpl for=".">',
                '<div class="comment" id="{id}">',
                    '<div class="com-meta">',
                        '<img class="avatar" width="25" height="25" src="http://www.gravatar.com/avatar/{emailHash}',
                              '?s=25&amp;r=PG&amp;d=http://www.sencha.com/img/avatar.png">',
                        '{[Docs.Comments.avatar(values.emailHash)]}',
                        '<div class="author<tpl if="moderator"> moderator" title="Sencha Engineer</tpl>">',
                            '{author}',
                            '<tpl if="showCls">',
+1 −2
Original line number Diff line number Diff line
@@ -68,8 +68,7 @@ Ext.define('Docs.view.comments.Users', {
                    '<tpl for=".">',
                        '<li>',
                            '<span class="score">{score}</span>',
                            '<img class="avatar" width="25" height="25" src="http://www.gravatar.com/avatar/{emailHash}',
                                  '?s=25&amp;r=PG&amp;d=http://www.sencha.com/img/avatar.png">',
                            '{[Docs.Comments.avatar(values.emailHash)]}',
                            '<span class="username <tpl if="mod">moderator</tpl>">{userName}</span>',
                        '</li>',
                    '</tpl>',