From 66dbb59aa16981643e3bfa3f94d441bc3166eab3 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Thu, 23 Aug 2018 17:26:21 +0200 Subject: [PATCH] Add aria-label to column regions (#8390) Fix #4485 --- app/javascript/mastodon/components/column.js | 5 +- .../features/community_timeline/index.js | 2 +- .../mastodon/features/compose/index.js | 3 +- .../features/direct_timeline/index.js | 2 +- .../features/favourited_statuses/index.js | 2 +- .../features/getting_started/index.js | 3 +- .../features/hashtag_timeline/index.js | 2 +- .../mastodon/features/home_timeline/index.js | 2 +- .../mastodon/features/list_timeline/index.js | 2 +- .../mastodon/features/notifications/index.js | 2 +- .../features/public_timeline/index.js | 2 +- .../standalone/community_timeline/index.js | 2 +- .../standalone/public_timeline/index.js | 2 +- .../mastodon/features/status/index.js | 3 +- .../mastodon/features/trends/index.js | 66 ------------------- 15 files changed, 19 insertions(+), 81 deletions(-) delete mode 100644 app/javascript/mastodon/features/trends/index.js diff --git a/app/javascript/mastodon/components/column.js b/app/javascript/mastodon/components/column.js index e81236d26..d45387463 100644 --- a/app/javascript/mastodon/components/column.js +++ b/app/javascript/mastodon/components/column.js @@ -7,6 +7,7 @@ export default class Column extends React.PureComponent { static propTypes = { children: PropTypes.node, + label: PropTypes.string, }; scrollTop () { @@ -40,10 +41,10 @@ export default class Column extends React.PureComponent { } render () { - const { children } = this.props; + const { label, children } = this.props; return ( -
+
{children}
); diff --git a/app/javascript/mastodon/features/community_timeline/index.js b/app/javascript/mastodon/features/community_timeline/index.js index 1cd5cf157..48d2b3f68 100644 --- a/app/javascript/mastodon/features/community_timeline/index.js +++ b/app/javascript/mastodon/features/community_timeline/index.js @@ -105,7 +105,7 @@ export default class CommunityTimeline extends React.PureComponent { const pinned = !!columnId; return ( - + ({ @@ -95,7 +96,7 @@ export default class Compose extends React.PureComponent { } return ( -
+
{header} {(multiColumn || isSearchPage) && } diff --git a/app/javascript/mastodon/features/direct_timeline/index.js b/app/javascript/mastodon/features/direct_timeline/index.js index 2181c75b6..dd289ce56 100644 --- a/app/javascript/mastodon/features/direct_timeline/index.js +++ b/app/javascript/mastodon/features/direct_timeline/index.js @@ -76,7 +76,7 @@ export default class DirectTimeline extends React.PureComponent { const pinned = !!columnId; return ( - + + ({ @@ -115,7 +116,7 @@ export default class GettingStarted extends ImmutablePureComponent { } return ( - + {multiColumn &&

- )} - /> - -
- {trends && trends.map(hashtag => )} -
- - ); - } - -}