Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Commit

Permalink
Fix lint errors, pin standard@8.1.0
Browse files Browse the repository at this point in the history
Fix #4135

Auditors: @bbondy

Test Plan: npm run lint should pass
  • Loading branch information
diracdeltas committed Sep 20, 2016
1 parent c6714a0 commit fab5178
Show file tree
Hide file tree
Showing 27 changed files with 433 additions and 433 deletions.
16 changes: 8 additions & 8 deletions js/about/about.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@ class AboutAbout extends ImmutableComponent {
return <div>
<h1 data-l10n-id='listOfAboutPages' />
<ul>
{
aboutUrls.keySeq().sort().filter((aboutSourceUrl) => isNavigatableAboutPage(aboutSourceUrl)).map((aboutSourceUrl) =>
<li>
<a href={aboutUrls.get(aboutSourceUrl)} target='_blank'>
{aboutSourceUrl}
</a>
</li>)
}
{
aboutUrls.keySeq().sort().filter((aboutSourceUrl) => isNavigatableAboutPage(aboutSourceUrl)).map((aboutSourceUrl) =>
<li>
<a href={aboutUrls.get(aboutSourceUrl)} target='_blank'>
{aboutSourceUrl}
</a>
</li>)
}
</ul>
</div>
}
Expand Down
24 changes: 12 additions & 12 deletions js/about/autofill.js
Original file line number Diff line number Diff line change
Expand Up @@ -151,12 +151,12 @@ class AboutAutofill extends React.Component {
</tr>
</thead>
<tbody>
{
this.state.addressesDetails.sort((a, b) => {
return a.get('name') > b.get('name') ? 1 : -1
}).map((item) =>
<AddressItem address={item} />)
}
{
this.state.addressesDetails.sort((a, b) => {
return a.get('name') > b.get('name') ? 1 : -1
}).map((item) =>
<AddressItem address={item} />)
}
</tbody>
</table>
</div>
Expand All @@ -174,12 +174,12 @@ class AboutAutofill extends React.Component {
</tr>
</thead>
<tbody>
{
this.state.creditCardsDetails.sort((a, b) => {
return a.get('name') > b.get('name') ? 1 : -1
}).map((item) =>
<CreditCardItem creditCard={item} />)
}
{
this.state.creditCardsDetails.sort((a, b) => {
return a.get('name') > b.get('name') ? 1 : -1
}).map((item) =>
<CreditCardItem creditCard={item} />)
}
</tbody>
</table>
</div>
Expand Down
38 changes: 19 additions & 19 deletions js/about/bookmarks.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,18 +73,18 @@ class BookmarkItem extends ImmutableComponent {
data-context-menu-disable
draggable='true'
onDoubleClick={this.navigate.bind(this)}>
{
this.props.bookmark.get('customTitle') || this.props.bookmark.get('title')
? <span className='aboutListItem' title={this.props.bookmark.get('location')}>
<span className='aboutItemTitle'>{this.props.bookmark.get('customTitle') || this.props.bookmark.get('title')}</span>
{partitionNumberInfo}
<span className='aboutItemSeparator'>-</span><span className='aboutItemLocation'>{this.props.bookmark.get('location')}</span>
</span>
: <span className='aboutListItem' title={this.props.bookmark.get('location')}>
<span>{this.props.bookmark.get('location')}</span>
{partitionNumberInfo}
</span>
}
{
this.props.bookmark.get('customTitle') || this.props.bookmark.get('title')
? <span className='aboutListItem' title={this.props.bookmark.get('location')}>
<span className='aboutItemTitle'>{this.props.bookmark.get('customTitle') || this.props.bookmark.get('title')}</span>
{partitionNumberInfo}
<span className='aboutItemSeparator'>-</span><span className='aboutItemLocation'>{this.props.bookmark.get('location')}</span>
</span>
: <span className='aboutListItem' title={this.props.bookmark.get('location')}>
<span>{this.props.bookmark.get('location')}</span>
{partitionNumberInfo}
</span>
}
</div>
}
}
Expand Down Expand Up @@ -181,10 +181,10 @@ class BookmarkFolderList extends ImmutableComponent {
class BookmarksList extends ImmutableComponent {
render () {
return <list className='siteDetailsList'>
{
this.props.bookmarks.map((bookmark) =>
<BookmarkItem bookmark={bookmark} />)
}
{
this.props.bookmarks.map((bookmark) =>
<BookmarkItem bookmark={bookmark} />)
}
</list>
}
}
Expand All @@ -205,9 +205,9 @@ class SearchResults extends React.Component {

return (
<list className='siteDetailsList'>
{
sortedBookmarks.map((bookmark, idx) => <BookmarkItem bookmark={bookmark} inSelectedFolder={selectedFolderIndex.get(idx)} />)
}
{
sortedBookmarks.map((bookmark, idx) => <BookmarkItem bookmark={bookmark} inSelectedFolder={selectedFolderIndex.get(idx)} />)
}
</list>
)
}
Expand Down
12 changes: 6 additions & 6 deletions js/about/certerror.js
Original file line number Diff line number Diff line change
Expand Up @@ -137,12 +137,12 @@ class CertErrorPage extends React.Component {
</div>
<div className='buttons'>
<Button l10nId='certErrorSafety' className='actionButton' onClick={this.onSafety.bind(this)} />
{this.state.url ? (this.state.advanced
? (<div>
<Button l10nId='certErrorButtonText' className='subtleButton' onClick={this.onAccept.bind(this)} />
<Button l10nId='certErrorShowCertificate' className='subtleButton' onClick={this.onDetail.bind(this)} />
</div>)
: <Button l10nId='certErrorAdvanced' className='subtleButton' onClick={this.onAdvanced.bind(this)} />) : null}
{this.state.url ? (this.state.advanced
? (<div>
<Button l10nId='certErrorButtonText' className='subtleButton' onClick={this.onAccept.bind(this)} />
<Button l10nId='certErrorShowCertificate' className='subtleButton' onClick={this.onDetail.bind(this)} />
</div>)
: <Button l10nId='certErrorAdvanced' className='subtleButton' onClick={this.onAdvanced.bind(this)} />) : null}
</div>
</div>
}
Expand Down
26 changes: 13 additions & 13 deletions js/about/downloads.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,26 +30,26 @@ class DownloadItem extends ImmutableComponent {
onContextMenu={aboutActions.contextMenu.bind(this, contextMenuDownload, 'download')}
data-context-menu-disable
onDoubleClick={aboutActions.openDownloadPath.bind(this, this.props.download)}>
{
<div className='aboutListItem' title={this.props.download.get('url')}>
<div className='aboutItemTitle'>{this.props.download.get('filename')}</div>
<div className='aboutItemTitle' data-l10n-id={downloadUtil.getL10nId(this.props.download)} data-l10n-args={JSON.stringify(l10nStateArgs)} />
<div className='aboutItemLocation'>{this.props.download.get('url')}</div>
</div>
}
{
<div className='aboutListItem' title={this.props.download.get('url')}>
<div className='aboutItemTitle'>{this.props.download.get('filename')}</div>
<div className='aboutItemTitle' data-l10n-id={downloadUtil.getL10nId(this.props.download)} data-l10n-args={JSON.stringify(l10nStateArgs)} />
<div className='aboutItemLocation'>{this.props.download.get('url')}</div>
</div>
}
</div>
}
}

class DownloadsList extends ImmutableComponent {
render () {
return <list className='downloadList'>
{
this.props.downloads.size > 0
? this.props.downloads.map((download, downloadId) =>
<DownloadItem download={download} downloadId={downloadId} />)
: <div className='downloadList' data-l10n-id='noDownloads' />
}
{
this.props.downloads.size > 0
? this.props.downloads.map((download, downloadId) =>
<DownloadItem download={download} downloadId={downloadId} />)
: <div className='downloadList' data-l10n-id='noDownloads' />
}
</list>
}
}
Expand Down
8 changes: 4 additions & 4 deletions js/about/extensions.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,10 @@ class ExtensionItem extends ImmutableComponent {
class ExtensionList extends ImmutableComponent {
render () {
return <list className='extensionDetailsList'>
{
this.props.extensions.map((entry) =>
<ExtensionItem extension={entry} />)
}
{
this.props.extensions.map((entry) =>
<ExtensionItem extension={entry} />)
}
</list>
}
}
Expand Down
14 changes: 7 additions & 7 deletions js/about/flashPlaceholder.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,13 +76,13 @@ class FlashPlaceholder extends ImmutableComponent {
<img src='img/bravePluginAlert.png' />
<div id='flashRightClick'>{flashRightClick}</div>
<div className='flashSubtext'>
{
flashEnabled
? flashSubtext
: <span>
To run Flash, enable it in <span className='linkText' onClick={this.onPrefsClick}>Preferences</span>.
</span>
}
{
flashEnabled
? flashSubtext
: <span>
To run Flash, enable it in <span className='linkText' onClick={this.onPrefsClick}>Preferences</span>.
</span>
}
</div>
</div>
{
Expand Down
28 changes: 14 additions & 14 deletions js/about/history.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,10 +92,10 @@ class GroupedHistoryList extends ImmutableComponent {
const defaultLanguage = this.props.languageCodes.find((lang) => lang.includes(navigator.language)) || 'en-US'
const userLanguage = getSetting(settings.LANGUAGE, this.props.settings)
return <list className='historyList'>
{
this.groupEntriesByDay(userLanguage || defaultLanguage).map((groupedEntry) =>
<HistoryDay date={groupedEntry.date} entries={groupedEntry.entries} />)
}
{
this.groupEntriesByDay(userLanguage || defaultLanguage).map((groupedEntry) =>
<HistoryDay date={groupedEntry.date} entries={groupedEntry.entries} />)
}
</list>
}
}
Expand Down Expand Up @@ -167,16 +167,16 @@ class AboutHistory extends React.Component {
</div>

<div className='siteDetailsPageContent'>
{
<GroupedHistoryList
languageCodes={this.state.languageCodes}
settings={this.state.settings}
history={
this.state.search
? this.searchedSiteDetails(this.state.search, this.historyDescendingOrder())
: this.historyDescendingOrder()
} />
}
{
<GroupedHistoryList
languageCodes={this.state.languageCodes}
settings={this.state.settings}
history={
this.state.search
? this.searchedSiteDetails(this.state.search, this.historyDescendingOrder())
: this.historyDescendingOrder()
} />
}
</div>
</div>
}
Expand Down
20 changes: 10 additions & 10 deletions js/about/passwords.js
Original file line number Diff line number Diff line change
Expand Up @@ -165,12 +165,12 @@ class AboutPasswords extends React.Component {
</tr>
</thead>
<tbody>
{
this.state.passwordDetails.sort((a, b) => {
return a.get('origin') > b.get('origin') ? 1 : -1
}).map((item) =>
<PasswordItem password={item} id={counter++} />)
}
{
this.state.passwordDetails.sort((a, b) => {
return a.get('origin') > b.get('origin') ? 1 : -1
}).map((item) =>
<PasswordItem password={item} id={counter++} />)
}
</tbody>
</table>
<div className='passwordsPageFooter'>
Expand All @@ -187,10 +187,10 @@ class AboutPasswords extends React.Component {
<div className='passwordsPageContent'>
<table className='passwordsList'>
<tbody>
{
this.state.disabledSiteDetails.map((item, site) =>
<SiteItem site={site} />)
}
{
this.state.disabledSiteDetails.map((item, site) =>
<SiteItem site={site} />)
}
</tbody>
</table>
</div>
Expand Down
Loading

1 comment on commit fab5178

@bbondy
Copy link
Member

@bbondy bbondy commented on fab5178 Sep 22, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for upgrading it

Please sign in to comment.