diff options
author | Morris Jobke <hey@morrisjobke.de> | 2018-04-19 14:47:17 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-04-19 14:47:17 +0200 |
commit | 0bae516c66efe9004d0a8ff504e0deb0069fc9d9 (patch) | |
tree | 386c7cd07dd0063800716ca2531343258d01ddd7 /apps/files/js | |
parent | 4d71e12a43a0d9f0d51fc95f199e217692e7ca41 (diff) | |
parent | 0f9ba852bc7e8bafecbd0bcd73099892645ac79e (diff) | |
download | nextcloud-server-0bae516c66efe9004d0a8ff504e0deb0069fc9d9.tar.gz nextcloud-server-0bae516c66efe9004d0a8ff504e0deb0069fc9d9.zip |
Merge pull request #9224 from nextcloud/accessibility-improvements
Add labels for Contacts menu and Settings, thanks to @MarcoZehe
Diffstat (limited to 'apps/files/js')
-rw-r--r-- | apps/files/js/filelist.js | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/apps/files/js/filelist.js b/apps/files/js/filelist.js index 4ef45a16b49..307147076b2 100644 --- a/apps/files/js/filelist.js +++ b/apps/files/js/filelist.js @@ -1328,7 +1328,9 @@ // size column if (typeof(fileData.size) !== 'undefined' && fileData.size >= 0) { simpleSize = humanFileSize(parseInt(fileData.size, 10), true); - sizeColor = Math.round(160-Math.pow((fileData.size/(1024*1024)),2)); + // rgb(118, 118, 118) / #767676 + // min. color contrast for normal text on white background according to WCAG AA + sizeColor = Math.round(118-Math.pow((fileData.size/(1024*1024)),2)); } else { simpleSize = t('files', 'Pending'); } @@ -1343,8 +1345,10 @@ // difference in days multiplied by 5 - brightest shade for files older than 32 days (160/5) var modifiedColor = Math.round(((new Date()).getTime() - mtime )/1000/60/60/24*5 ); // ensure that the brightest color is still readable - if (modifiedColor >= '160') { - modifiedColor = 160; + // rgb(118, 118, 118) / #767676 + // min. color contrast for normal text on white background according to WCAG AA + if (modifiedColor >= '118') { + modifiedColor = 118; } var formatted; var text; @@ -2387,7 +2391,7 @@ input.blur(function() { if(input.hasClass('error')) { restore(); - } else { + } else { form.trigger('submit'); } }); |