Skip to content

Commit

Permalink
Lint: jsx-one-expression-per-line (where appropriate)
Browse files Browse the repository at this point in the history
Some occurrences left due to rule making code less readable
(see jsx-eslint/eslint-plugin-react#1848)

Rule remains globally disabled
  • Loading branch information
David Evans committed Mar 4, 2019
1 parent 316b054 commit da60ff5
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 17 deletions.
5 changes: 4 additions & 1 deletion web/src/components/home/google_login_wrapper.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,10 @@ export default class GoogleLoginWrapper extends React.Component {
className={'button start-retro ' + this.props.className}
hostedDomain={global.Retro.config.google_oauth_hosted_domain}
>
<span><i className="fa fa-google" aria-hidden="true" style={{marginRight: '10px'}}/>Sign in with Google</span>
<span>
<i className="fa fa-google" aria-hidden="true" style={{marginRight: '10px'}}/>
Sign in with Google
</span>
</GoogleLogin>
</div>
);
Expand Down
3 changes: 2 additions & 1 deletion web/src/components/not-found/not_found_page.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@ export default class NotFoundPage extends React.Component {
type="button"
style={{fontSize: '1.1rem'}}
onClick={this.onCreateNewRetroClicked}
>Create a Project
>
Create a Project
</button>
</div>
</div>
Expand Down
17 changes: 10 additions & 7 deletions web/src/components/retro-create/retro_create_page.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -189,12 +189,12 @@ export default class RetroCreatePage extends React.Component {
return (
<div className="access-instruction">
{this.state.isPrivate ? accessPrivate : accessPublic}

<br/>
Password is always required to: <br/>
<img className="icon-locked" src={iconLockedSvg} alt="Locked"/> Access archives<br/>
Password is always required to:
<br/>
<img className="icon-locked" src={iconLockedSvg} alt="Locked"/> Access archives
<br/>
<img className="icon-locked" src={iconLockedSvg} alt="Locked"/> Edit settings

</div>
);
}
Expand Down Expand Up @@ -228,7 +228,9 @@ export default class RetroCreatePage extends React.Component {
<div className="row">
<label className="label">Choose a team URL</label>
<div className="input-group retro-url">
<span className="input-group-label retro-url-prefix">{this.getCurrentHost()}/retros/</span>
<span className="input-group-label retro-url-prefix">
{`${this.getCurrentHost()}/retros/`}
</span>
<input
id="retro_url"
value={slug}
Expand All @@ -255,8 +257,9 @@ export default class RetroCreatePage extends React.Component {
<div className="error-message">{errors.password}</div>
</div>
<div className="row">
<label className="label" htmlFor="retro_is_private">Do people need the password to <strong>access</strong> this retro?</label>

<label className="label" htmlFor="retro_is_private">
Do people need the password to <strong>access</strong> this retro?
</label>
<Toggle
id="retro_is_private"
name="isPrivate"
Expand Down
4 changes: 3 additions & 1 deletion web/src/components/retro-login/login_to_retro_page.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,9 @@ export default class LoginToRetroPage extends React.Component {
<div className="small-centered medium-8 small-10 columns">
<div className="field row">
<h1>{this.pageTitle()}</h1>
<label className="label">Enter the password to access {name}.</label>
<label className="label">
Enter the password to access {name}.
</label>
<input
className={`form-input ${inputStyle}`}
placeholder="Password"
Expand Down
12 changes: 7 additions & 5 deletions web/src/components/retro-settings/show_retro_settings_page.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -251,12 +251,12 @@ export default class ShowRetroSettingsPage extends React.Component {
return (
<div className="access-instruction">
{this.state.isPrivate ? accessPrivate : accessPublic}

<br/>
Password is always required to: <br/>
<img className="icon-locked" src={iconLockedSvg} alt="Locked"/> Access archives<br/>
Password is always required to:
<br/>
<img className="icon-locked" src={iconLockedSvg} alt="Locked"/> Access archives
<br/>
<img className="icon-locked" src={iconLockedSvg} alt="Locked"/> Edit settings

</div>
);
}
Expand Down Expand Up @@ -322,7 +322,9 @@ export default class ShowRetroSettingsPage extends React.Component {
<div className="row">
<label className="label">Project URL</label>
<div className="input-group retro-url">
<span className="input-group-label retro-url-prefix">{this.getCurrentHost()}/retros/</span>
<span className="input-group-label retro-url-prefix">
{`${this.getCurrentHost()}/retros/`}
</span>
<input
id="retro_url"
value={this.state.slug}
Expand Down
4 changes: 2 additions & 2 deletions web/src/components/terms/new_terms_page.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
import React from 'react';
import RetroFooter from '../shared/footer';

/* eslint-disable react/no-unescaped-entities */
/* eslint-disable react/no-unescaped-entities, react/jsx-one-expression-per-line */

export default () => (
<div id="new-terms" className="terms">
Expand Down Expand Up @@ -240,4 +240,4 @@ export default () => (
</div>
);

/* eslint-enable react/no-unescaped-entities */
/* eslint-enable react/no-unescaped-entities, react/jsx-one-expression-per-line */

0 comments on commit da60ff5

Please sign in to comment.