]> cat aescling's git repositories - mastodon.git/commitdiff
Remove aria-label of status content (#5195)
authorAkihiko Odaki <akihiko.odaki.4i@stu.hosei.ac.jp>
Tue, 3 Oct 2017 11:10:07 +0000 (20:10 +0900)
committerEugen Rochko <eugen@zeonfederated.com>
Tue, 3 Oct 2017 11:10:06 +0000 (13:10 +0200)
aria-label contained body of status with content warning, which should be
hidden by default. Remove the label for the case and other cases due to
consistency.

app/javascript/mastodon/components/status_content.js

index 2069f971ccd3f14c337d8809d22c7059ad04f442..63ce258653031077ddf6f01879a678885ca67fc3 100644 (file)
@@ -144,7 +144,7 @@ export default class StatusContent extends React.PureComponent {
       }
 
       return (
-        <div className={classNames} ref={this.setRef} tabIndex='0' aria-label={status.get('search_index')} onMouseDown={this.handleMouseDown} onMouseUp={this.handleMouseUp}>
+        <div className={classNames} ref={this.setRef} tabIndex='0' onMouseDown={this.handleMouseDown} onMouseUp={this.handleMouseUp}>
           <p style={{ marginBottom: hidden && status.get('mentions').isEmpty() ? '0px' : null }}>
             <span dangerouslySetInnerHTML={spoilerContent} />
             {' '}
@@ -161,7 +161,6 @@ export default class StatusContent extends React.PureComponent {
         <div
           ref={this.setRef}
           tabIndex='0'
-          aria-label={status.get('search_index')}
           className={classNames}
           style={directionStyle}
           onMouseDown={this.handleMouseDown}
@@ -173,7 +172,6 @@ export default class StatusContent extends React.PureComponent {
       return (
         <div
           tabIndex='0'
-          aria-label={status.get('search_index')}
           ref={this.setRef}
           className='status__content'
           style={directionStyle}