From b6a703d5ded81e230a95b954e0579ce676383d83 Mon Sep 17 00:00:00 2001 From: Danny Coates Date: Wed, 20 Feb 2019 15:58:44 -0800 Subject: [PATCH] added outline styles for keyboard nav --- app/main.css | 14 ++++++++++---- app/ui/account.js | 2 +- app/ui/archiveTile.js | 32 ++++++++++++++++++++++++-------- app/ui/copyDialog.js | 12 ++++++++---- app/ui/download.js | 2 -- tailwind.js | 3 ++- 6 files changed, 45 insertions(+), 20 deletions(-) diff --git a/app/main.css b/app/main.css index 14a11317..459502a2 100644 --- a/app/main.css +++ b/app/main.css @@ -13,6 +13,10 @@ a { text-decoration: none; } +a:focus { + outline: 1px dotted grey; +} + body { background-image: url('../assets/bg.svg'); background-position: center; @@ -96,10 +100,6 @@ body { cursor: auto; } -.delete:hover { - opacity: 0.7; -} - details { overflow: hidden; } @@ -278,6 +278,12 @@ select { } } +@variants focus { + .outline { + outline: 1px dotted grey; + } +} + .word-break-all { word-break: break-all; } diff --git a/app/ui/account.js b/app/ui/account.js index 29374adb..f632d985 100644 --- a/app/ui/account.js +++ b/app/ui/account.js @@ -62,7 +62,7 @@ class Account extends Component { return html` - ${state.translate('okButton')} + ${state.translate('okButton')} + `; diff --git a/app/ui/download.js b/app/ui/download.js index 9b681ea9..5c591625 100644 --- a/app/ui/download.js +++ b/app/ui/download.js @@ -68,8 +68,6 @@ function password(state, emit) { event.preventDefault(); const el = document.getElementById('password-input'); const password = el.value; - // clear the value to prevent the save password dialog - el.value = ''; if (password.length > 0) { document.getElementById('password-btn').disabled = true; state.fileInfo.url = window.location.href; diff --git a/tailwind.js b/tailwind.js index fb0ed426..b020cf89 100644 --- a/tailwind.js +++ b/tailwind.js @@ -457,6 +457,7 @@ module.exports = { width: { auto: 'auto', px: '1px', + '0': '0', '1': '0.25rem', '2': '0.5rem', '3': '0.75rem', @@ -861,7 +862,7 @@ module.exports = { minHeight: ['responsive'], minWidth: ['responsive'], negativeMargin: ['responsive'], - opacity: ['responsive'], + opacity: ['responsive', 'hover'], outline: ['focus'], overflow: ['responsive'], padding: ['responsive'],