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

Commit

Permalink
Fixed advanced settings modal dialogs on about:preferences#payments
Browse files Browse the repository at this point in the history
Set the equal paddings to
- .advancedSettings
- .ledgerBackupContent
- .recoveryContent

Set the equal margin-bottom to
- .ledgerRecoveryContent
- .firstRecoveryKey
- .secondRecoveryKey

Added white-space:nowrap to recovery keys
Addressed #4807 (comment)

Auditors: @bsclifton

Test Plan:
1. Open about:preferences#payments
2. Click "Advanced Settings..."
3. Make sure style of "Backup your wallet" and "Recover your wallet" is consistent
  • Loading branch information
Suguru Hirahara committed Dec 10, 2016
1 parent 02ce7c7 commit f8efaca
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 10 deletions.
12 changes: 6 additions & 6 deletions js/about/preferences.js
Original file line number Diff line number Diff line change
Expand Up @@ -1019,7 +1019,7 @@ class PaymentsTab extends ImmutableComponent {
return <div className='board'>
<div className='panel advancedSettings'>
<div className='settingsPanelDivider'>
<div data-l10n-id='minimumPageTimeSetting' />
<div className='minimumPageTimeSetting' data-l10n-id='minimumPageTimeSetting' />
<SettingsList>
<SettingItem>
<select
Expand All @@ -1032,7 +1032,7 @@ class PaymentsTab extends ImmutableComponent {
</select>
</SettingItem>
</SettingsList>
<div data-l10n-id='minimumVisitsSetting' />
<div className='minimumVisitsSetting' data-l10n-id='minimumVisitsSetting' />
<SettingsList>
<SettingItem>
<select
Expand Down Expand Up @@ -1072,7 +1072,7 @@ class PaymentsTab extends ImmutableComponent {
const passphrase = this.props.ledgerData.get('passphrase')

return <div className='board'>
<div className='panel'>
<div className='panel ledgerBackupContent'>
<span data-l10n-id='ledgerBackupContent' />
<div className='copyKeyContainer'>
<div className='copyContainer'>
Expand Down Expand Up @@ -1129,13 +1129,13 @@ class PaymentsTab extends ImmutableComponent {
}
<div className='panel recoveryContent'>
<h4 data-l10n-id='ledgerRecoverySubtitle' />
<span data-l10n-id='ledgerRecoveryContent' />
<div className='ledgerRecoveryContent' data-l10n-id='ledgerRecoveryContent' />
<SettingsList>
<SettingItem>
<h3 data-l10n-id='firstRecoveryKey' />
<input className='form-control' onChange={this.handleFirstRecoveryKeyChange} type='text' />
<input className='form-control firstRecoveryKey' onChange={this.handleFirstRecoveryKeyChange} type='text' />
<h3 data-l10n-id='secondRecoveryKey' />
<input className='form-control' onChange={this.handleSecondRecoveryKeyChange} type='text' />
<input className='form-control secondRecoveryKey' onChange={this.handleSecondRecoveryKeyChange} type='text' />
</SettingItem>
</SettingsList>
</div>
Expand Down
36 changes: 32 additions & 4 deletions less/about/preferences.less
Original file line number Diff line number Diff line change
Expand Up @@ -555,7 +555,9 @@ table.sortableTable {
.dialog-body {
.board {
.panel {
&.advancedSettings {
&.advancedSettings,
&.ledgerBackupContent,
&.recoveryContent {
padding-left: 50px;
padding-right: 50px;

Expand All @@ -564,10 +566,27 @@ table.sortableTable {
}
}

&.advancedSettings {
.settingsPanelDivider {
.settingsListContainer:last-child {
margin-bottom: 0;
}
}
}

&.recoveryContent {
h4,
span {
.ledgerRecoveryContent {
margin-bottom: 20px;

& + .settingsListContainer {
margin-bottom: 0;

.firstRecoveryKey,
.secondRecoveryKey {
margin-bottom: 20px;
}
}
}
}

Expand All @@ -583,6 +602,12 @@ table.sortableTable {
&:nth-child(2) {
text-align: right;
}

.minimumPageTimeSetting,
.minimumVisitsSetting {
margin-bottom: 12px; // @itemMargin in .walletBar
}

}

.copyKeyContainer {
Expand All @@ -604,6 +629,10 @@ table.sortableTable {
h3 {
margin-bottom: 15px;
}

> span {
white-space: nowrap;
}
}
}
}
Expand Down Expand Up @@ -780,8 +809,7 @@ table.sortableTable {

.dialog-footer {
.advancedSettingsFooter {
padding-top: 20px;
padding-bottom: 20px;
padding: 20px;
display: flex;
flex-wrap: wrap;
justify-content: center;
Expand Down

0 comments on commit f8efaca

Please sign in to comment.