Mozilla Add-ons: say "add-on" instead of addon
Mozilla's website uses that format. Also, show star-rating as "4/5" instead of "4 stars" (which looks verbose, less informative, and grammatically incorrect if there is a single star).
This commit is contained in:
parent
2cb82a4ab3
commit
7403b61e25
|
@ -5353,7 +5353,7 @@ cache(function(data, match, sendBadge, request) {
|
|||
var type = match[1];
|
||||
var addonId = match[2];
|
||||
var format = match[3];
|
||||
var badgeData = getBadgeData('mozilla addons', data);
|
||||
var badgeData = getBadgeData('mozilla add-on', data);
|
||||
var url = 'https://services.addons.mozilla.org/api/1.5/addon/' + addonId;
|
||||
|
||||
request(url, function(err, res, buffer) {
|
||||
|
@ -5387,7 +5387,7 @@ cache(function(data, match, sendBadge, request) {
|
|||
case 'rating':
|
||||
var rating = parseInt(data.addon.rating, 10);
|
||||
badgeData.text[0] = 'rating';
|
||||
badgeData.text[1] = rating + ' stars';
|
||||
badgeData.text[1] = rating + '/5';
|
||||
badgeData.colorscheme = floorCountColor(rating, 2, 3, 4);
|
||||
break;
|
||||
case 'users':
|
||||
|
|
8
try.html
8
try.html
|
@ -403,7 +403,7 @@ Pixel-perfect Retina-ready Fast Consistent Hackable
|
|||
<td><img src='/cocoapods/dw/AFNetworking.svg' alt='' /></td>
|
||||
<td><code>https://img.shields.io/cocoapods/dw/AFNetworking.svg</code></td>
|
||||
</tr>
|
||||
<tr><th data-keywords='amo firefox'> Mozilla Addons: </th>
|
||||
<tr><th data-keywords='amo firefox'> Mozilla Add-on: </th>
|
||||
<td><img src='/amo/d/dustman.svg' alt=''/></td>
|
||||
<td><code>https://img.shields.io/amo/d/dustman.svg</code></td>
|
||||
</tr>
|
||||
|
@ -558,7 +558,7 @@ Pixel-perfect Retina-ready Fast Consistent Hackable
|
|||
<td><img src='/homebrew/v/cake.svg' alt=''/></td>
|
||||
<td><code>https://img.shields.io/homebrew/v/cake.svg</code></td>
|
||||
</tr>
|
||||
<tr><th data-keywords='amo firefox'> Mozilla Addons: </th>
|
||||
<tr><th data-keywords='amo firefox'> Mozilla Add-on: </th>
|
||||
<td><img src='/amo/v/dustman.svg' alt=''/></td>
|
||||
<td><code>https://img.shields.io/amo/v/dustman.svg</code></td>
|
||||
</tr>
|
||||
|
@ -873,11 +873,11 @@ Pixel-perfect Retina-ready Fast Consistent Hackable
|
|||
<td><img src='/aur/votes/yaourt.svg' alt=''/></td>
|
||||
<td><code>https://img.shields.io/aur/votes/yaourt.svg</code></td>
|
||||
</tr>
|
||||
<tr><th data-keywords='amo firefox'> Mozilla Addons: </th>
|
||||
<tr><th data-keywords='amo firefox'> Mozilla Add-on: </th>
|
||||
<td><img src='/amo/users/dustman.svg' alt=''/></td>
|
||||
<td><code>https://img.shields.io/amo/users/dustman.svg</code></td>
|
||||
</tr>
|
||||
<tr><th data-keywords='amo firefox'> Mozilla Addons: </th>
|
||||
<tr><th data-keywords='amo firefox'> Mozilla Add-on: </th>
|
||||
<td><img src='/amo/rating/dustman.svg' alt=''/></td>
|
||||
<td><code>https://img.shields.io/amo/rating/dustman.svg</code></td>
|
||||
</tr>
|
||||
|
|
Loading…
Reference in New Issue
Block a user