Minor accessibility improvements
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
This commit is contained in:
parent
a48e7f28b0
commit
9734290bfb
6 changed files with 22 additions and 8 deletions
|
@ -323,13 +323,13 @@ class Header extends ImmutablePureComponent {
|
||||||
{info}
|
{info}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className='account__header__subscribe'>
|
|
||||||
<SubscriptionButton account={account} />
|
|
||||||
</div>
|
|
||||||
|
|
||||||
{header && <a className='account__header__header' href={account.get('header')} onClick={this.handleHeaderClick} target='_blank'>
|
{header && <a className='account__header__header' href={account.get('header')} onClick={this.handleHeaderClick} target='_blank'>
|
||||||
<StillImage src={account.get('header')} alt='' className='parallax' />
|
<StillImage src={account.get('header')} alt='' className='parallax' />
|
||||||
</a>}
|
</a>}
|
||||||
|
|
||||||
|
<div className='account__header__subscribe'>
|
||||||
|
<SubscriptionButton account={account} />
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className='account__header__bar'>
|
<div className='account__header__bar'>
|
||||||
|
|
|
@ -193,7 +193,7 @@ class AccountTimeline extends ImmutablePureComponent {
|
||||||
</div>
|
</div>
|
||||||
<div className={classNames('column-header__collapsible', { collapsed, animating })} onTransitionEnd={this.handleTransitionEnd}>
|
<div className={classNames('column-header__collapsible', { collapsed, animating })} onTransitionEnd={this.handleTransitionEnd}>
|
||||||
<div className='column-header__collapsible-inner'>
|
<div className='column-header__collapsible-inner'>
|
||||||
<ColumnSettingsContainer />
|
{(!collapsed || animating) && <ColumnSettingsContainer />}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<StatusList
|
<StatusList
|
||||||
|
|
|
@ -73,7 +73,7 @@ class Reactions extends ImmutablePureComponent {
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
const { params, reactions, accounts, status } = this.props;
|
const { params, reactions, accounts, status } = this.props;
|
||||||
const { username, statusId } = params;
|
const { username, statusId, reaction } = params;
|
||||||
|
|
||||||
const back = `/@${username}/posts/${statusId}`;
|
const back = `/@${username}/posts/${statusId}`;
|
||||||
|
|
||||||
|
@ -95,13 +95,14 @@ class Reactions extends ImmutablePureComponent {
|
||||||
|
|
||||||
const emptyMessage = <FormattedMessage id='status.reactions.empty' defaultMessage='No one has reacted to this post yet. When someone does, they will show up here.' />;
|
const emptyMessage = <FormattedMessage id='status.reactions.empty' defaultMessage='No one has reacted to this post yet. When someone does, they will show up here.' />;
|
||||||
|
|
||||||
|
console.log(params.reaction);
|
||||||
return (
|
return (
|
||||||
<Column back={back}>
|
<Column back={back}>
|
||||||
{
|
{
|
||||||
reactions.size > 0 && (
|
reactions.size > 0 && (
|
||||||
<div className='reaction__filter-bar'>
|
<div className='reaction__filter-bar'>
|
||||||
<button onClick={this.handleFilterChange('')}>All</button>
|
<button className={!params.reaction ? 'active' : ''} onClick={this.handleFilterChange('')}>All</button>
|
||||||
{reactions?.filter(reaction => reaction.count).map(reaction => <button key={reaction.name} onClick={this.handleFilterChange(reaction.name)}>{reaction.name} {reaction.count}</button>)}
|
{reactions?.filter(reaction => reaction.count).map(reaction => <button key={reaction.name} className={params.reaction === reaction.name ? 'active' : ''} onClick={this.handleFilterChange(reaction.name)}>{reaction.name} {reaction.count}</button>)}
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
|
@ -524,6 +524,7 @@ a .account__avatar {
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
opacity: 0.7;
|
opacity: 0.7;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
|
transition: 0.2s;
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
|
|
|
@ -34,6 +34,12 @@
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
opacity: 0.7;
|
opacity: 0.7;
|
||||||
|
|
||||||
|
&:active,
|
||||||
|
&:focus,
|
||||||
|
&:hover {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
|
||||||
&:not(.button-active) i.fa {
|
&:not(.button-active) i.fa {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -638,9 +638,14 @@
|
||||||
position: relative;
|
position: relative;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
|
|
||||||
|
&:active,
|
||||||
|
&:focus,
|
||||||
|
&:hover,
|
||||||
&.active {
|
&.active {
|
||||||
color: var(--primary-text-color);
|
color: var(--primary-text-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
&.active {
|
||||||
&::before,
|
&::before,
|
||||||
&::after {
|
&::after {
|
||||||
display: block;
|
display: block;
|
||||||
|
@ -668,6 +673,7 @@
|
||||||
overflow-x: auto;
|
overflow-x: auto;
|
||||||
overflow-y: hidden;
|
overflow-y: hidden;
|
||||||
|
|
||||||
|
button,
|
||||||
a {
|
a {
|
||||||
flex: unset;
|
flex: unset;
|
||||||
padding: 15px 24px;
|
padding: 15px 24px;
|
||||||
|
|
Loading…
Reference in a new issue