Microsoft has acquired GitHub. Decentraleyes has left GitHub. Welcome to its new home!

To participate, please register, or sign in with an existing GitLab.com, Bitbucket, or GitHub account.

Past contributions on GitHub? Be sure to reclaim your Comments, Issues, and Pull Requests.

Commit c219fae3 authored by Thomas Rientjes's avatar Thomas Rientjes

Improve injection count formatting

parent a8e340ab
......@@ -201,6 +201,13 @@ helpers.determineScriptDirection = function (language) {
return scriptDirection;
};
helpers.formatNumber = function (number) {
if (typeof number === 'number') {
return number.toLocaleString();
}
};
helpers.formatVersion = function (version) {
if (version.indexOf('beta') === -1) {
......
......@@ -47,7 +47,7 @@ popup._renderNonContextualContents = function () {
optionsButtonElement = document.getElementById('options-button');
versionLabelElement.innerText = popup._version;
counterElement.innerText = popup._amountInjected;
counterElement.innerText = helpers.formatNumber(popup._amountInjected);
testingUtilityLinkElement.addEventListener('mouseup', popup._onTestingUtilityLinkClicked);
optionsButtonElement.addEventListener('mouseup', popup._onOptionsButtonClicked);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment