From 1bbe2a56125a0365fab89c83548fff3a94fd7671 Mon Sep 17 00:00:00 2001 From: Nolan Lawson Date: Tue, 24 Sep 2019 00:50:35 -0700 Subject: [PATCH] fix: improve focus styles (#1526) * fix: improve focus styles * fixup --- src/routes/_components/NavItem.html | 3 +-- src/routes/_components/TabSet.html | 1 + .../dialog/components/GenericDialogList.html | 2 +- .../dialog/components/ModalDialog.html | 2 +- .../settings/SettingsListButton.html | 2 +- src/routes/_components/status/Media.html | 4 ++++ .../_components/status/Notification.html | 2 +- src/routes/_components/status/Status.html | 2 +- src/routes/_components/status/StatusPoll.html | 1 + src/scss/focus.scss | 23 +++++++++++++------ 10 files changed, 28 insertions(+), 14 deletions(-) diff --git a/src/routes/_components/NavItem.html b/src/routes/_components/NavItem.html index b0242295..50d3ac58 100644 --- a/src/routes/_components/NavItem.html +++ b/src/routes/_components/NavItem.html @@ -1,4 +1,4 @@ - {tab.label} diff --git a/src/routes/_components/dialog/components/GenericDialogList.html b/src/routes/_components/dialog/components/GenericDialogList.html index 253ede4c..0c163138 100644 --- a/src/routes/_components/dialog/components/GenericDialogList.html +++ b/src/routes/_components/dialog/components/GenericDialogList.html @@ -2,7 +2,7 @@ {#each items as item (item.key)}
  • diff --git a/src/routes/_components/settings/SettingsListButton.html b/src/routes/_components/settings/SettingsListButton.html index a23ccca1..73092716 100644 --- a/src/routes/_components/settings/SettingsListButton.html +++ b/src/routes/_components/settings/SettingsListButton.html @@ -2,7 +2,7 @@ on:click="fire('click', event)" rel="prefetch" aria-label={ariaLabel || label} - class="settings-list-button focus-after {className ? className : ''}" + class="settings-list-button focus-fix {className ? className : ''}" > {label} diff --git a/src/routes/_components/status/Media.html b/src/routes/_components/status/Media.html index 22ce7ea6..6902cc30 100644 --- a/src/routes/_components/status/Media.html +++ b/src/routes/_components/status/Media.html @@ -85,6 +85,10 @@ cursor: zoom-in; } + .inline-media { + position: relative; + } + @media (max-width: 240px) { .inline-media { min-height: 100px; /* TODO: hack for KaiOS, which renders the grouped-images style as 0 height */ diff --git a/src/routes/_components/status/Notification.html b/src/routes/_components/status/Notification.html index 0df641c8..7baf038e 100644 --- a/src/routes/_components/status/Notification.html +++ b/src/routes/_components/status/Notification.html @@ -70,7 +70,7 @@ className: ({ $underlineLinks }) => (classname( 'notification-article', 'shortcut-list-item', - 'focus-after', + 'focus-fix', $underlineLinks && 'underline-links' )) }, diff --git a/src/routes/_components/status/Status.html b/src/routes/_components/status/Status.html index 32bb78f1..bc309a43 100644 --- a/src/routes/_components/status/Status.html +++ b/src/routes/_components/status/Status.html @@ -294,7 +294,7 @@ className: ({ visibility, timelineType, isStatusInOwnThread, $underlineLinks, $disableTapOnStatus }) => (classname( 'status-article', 'shortcut-list-item', - 'focus-after', + 'focus-fix', timelineType !== 'direct' && visibility === 'direct' && 'status-direct', timelineType !== 'search' && 'status-in-timeline', isStatusInOwnThread && 'status-in-own-thread', diff --git a/src/routes/_components/status/StatusPoll.html b/src/routes/_components/status/StatusPoll.html index 5451e3c3..1bfa0d83 100644 --- a/src/routes/_components/status/StatusPoll.html +++ b/src/routes/_components/status/StatusPoll.html @@ -47,6 +47,7 @@