mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Make height consistent on all row in send-content (#6480)
* Update all send-content row to 54px height * Remove header subtitle * Remove tests that check for send screen subheader
This commit is contained in:
parent
ed23801490
commit
3519e90ffd
@ -50,9 +50,6 @@ async function runSendFlowTest (assert, done) {
|
|||||||
const sendTitle = await queryAsync($, '.page-container__title')
|
const sendTitle = await queryAsync($, '.page-container__title')
|
||||||
assert.equal(sendTitle[0].textContent, 'Send ETH', 'Send screen title is correct')
|
assert.equal(sendTitle[0].textContent, 'Send ETH', 'Send screen title is correct')
|
||||||
|
|
||||||
const sendCopy = await queryAsync($, '.page-container__subtitle')
|
|
||||||
assert.equal(sendCopy[0].textContent, 'Only send ETH to an Ethereum address.', 'Send screen has copy')
|
|
||||||
|
|
||||||
const sendFromField = await queryAsync($, '.send-v2__form-field')
|
const sendFromField = await queryAsync($, '.send-v2__form-field')
|
||||||
assert.ok(sendFromField[0], 'send screen has a from field')
|
assert.ok(sendFromField[0], 'send screen has a from field')
|
||||||
|
|
||||||
|
@ -65,6 +65,7 @@
|
|||||||
.gas-price-button-group--small {
|
.gas-price-button-group--small {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: stretch;
|
justify-content: stretch;
|
||||||
|
height: 54px;
|
||||||
|
|
||||||
@media screen and (max-width: $break-small) {
|
@media screen and (max-width: $break-small) {
|
||||||
max-width: 260px;
|
max-width: 260px;
|
||||||
@ -80,10 +81,14 @@
|
|||||||
|
|
||||||
&__label {
|
&__label {
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
|
line-height: 16px;
|
||||||
|
padding-bottom: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
&__primary-currency {
|
&__primary-currency {
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
|
line-height: 12px;
|
||||||
|
padding-bottom: 2px;
|
||||||
|
|
||||||
@media screen and (max-width: 575px) {
|
@media screen and (max-width: 575px) {
|
||||||
font-size: 10px;
|
font-size: 10px;
|
||||||
@ -92,6 +97,8 @@
|
|||||||
|
|
||||||
&__secondary-currency {
|
&__secondary-currency {
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
|
line-height: 12px;
|
||||||
|
padding-bottom: 2px;
|
||||||
|
|
||||||
@media screen and (max-width: 575px) {
|
@media screen and (max-width: 575px) {
|
||||||
font-size: 10px;
|
font-size: 10px;
|
||||||
@ -105,11 +112,7 @@
|
|||||||
.button-group__button, .button-group__button--active {
|
.button-group__button, .button-group__button--active {
|
||||||
background: white;
|
background: white;
|
||||||
color: $scorpion;
|
color: $scorpion;
|
||||||
padding: 2px 8.5px 4px 8.5px;
|
padding: 0 4px;
|
||||||
|
|
||||||
@media screen and (max-width: $break-small) {
|
|
||||||
padding-left: 4px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div {
|
div {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
color: #4d4d4d;
|
color: #4d4d4d;
|
||||||
font-size: 1rem;
|
font-size: 16px;
|
||||||
padding: 8px 10px;
|
padding: 8px 10px;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
|
||||||
@ -29,6 +29,8 @@
|
|||||||
|
|
||||||
&__inputs {
|
&__inputs {
|
||||||
flex: 1 0 auto;
|
flex: 1 0 auto;
|
||||||
|
display: flex;
|
||||||
|
flex-flow: column nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
&__input {
|
&__input {
|
||||||
@ -38,15 +40,20 @@
|
|||||||
border: none;
|
border: none;
|
||||||
outline: 0 !important;
|
outline: 0 !important;
|
||||||
max-width: 22ch;
|
max-width: 22ch;
|
||||||
|
height: 16px;
|
||||||
|
line-height: 18px;
|
||||||
}
|
}
|
||||||
|
|
||||||
&__input-container {
|
&__input-container {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: flex-start;
|
||||||
|
padding-bottom: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
&__suffix {
|
&__suffix {
|
||||||
margin-left: 3px;
|
margin-left: 3px;
|
||||||
|
font-size: 1rem;
|
||||||
|
line-height: 1rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
&--error {
|
&--error {
|
||||||
|
@ -633,14 +633,14 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
&__asset-dropdown {
|
&__asset-dropdown {
|
||||||
height: 62px;
|
height: 54px;
|
||||||
border: none;
|
border: none;
|
||||||
|
|
||||||
&__asset {
|
&__asset {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-flow: row nowrap;
|
flex-flow: row nowrap;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
padding: 10px 8px;
|
padding: 0 8px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
@ -688,15 +688,22 @@
|
|||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
background-color: $white;
|
background-color: $white;
|
||||||
box-shadow: 0 3px 6px 0 rgba(0 ,0 ,0 ,.11);
|
box-shadow: 0 3px 6px 0 rgba(0 ,0 ,0 ,.11);
|
||||||
top: 55px;
|
top: 65px;
|
||||||
left: 0;
|
left: 0;
|
||||||
box-sizing: content-box;
|
box-sizing: content-box;
|
||||||
overflow-y: scroll;
|
overflow-y: scroll;
|
||||||
|
margin-top: 0;
|
||||||
|
padding: 4px 0;
|
||||||
|
|
||||||
|
.send-v2__asset-dropdown__asset {
|
||||||
|
padding: 8px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&__input-wrapper {
|
&__input-wrapper {
|
||||||
border: 1px solid $alto;
|
border: 1px solid $alto;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
|
height: 100%;
|
||||||
|
|
||||||
&--opened {
|
&--opened {
|
||||||
position: relative;
|
position: relative;
|
||||||
@ -704,6 +711,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.send-v2__asset-dropdown__asset {
|
.send-v2__asset-dropdown__asset {
|
||||||
|
height: 100%;
|
||||||
&:hover {
|
&:hover {
|
||||||
background-color: $white;
|
background-color: $white;
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,6 @@ export default class SendHeader extends Component {
|
|||||||
return (
|
return (
|
||||||
<PageContainerHeader
|
<PageContainerHeader
|
||||||
onClose={() => this.onClose()}
|
onClose={() => this.onClose()}
|
||||||
subtitle={this.context.t(...this.props.subtitleParams)}
|
|
||||||
title={this.context.t(this.props.titleKey)}
|
title={this.context.t(this.props.titleKey)}
|
||||||
/>
|
/>
|
||||||
)
|
)
|
||||||
|
@ -57,10 +57,8 @@ describe('SendHeader Component', function () {
|
|||||||
it('should pass the correct props to PageContainerHeader', () => {
|
it('should pass the correct props to PageContainerHeader', () => {
|
||||||
const {
|
const {
|
||||||
onClose,
|
onClose,
|
||||||
subtitle,
|
|
||||||
title,
|
title,
|
||||||
} = wrapper.find(PageContainerHeader).props()
|
} = wrapper.find(PageContainerHeader).props()
|
||||||
assert.equal(subtitle, 'mockSubtitleKeymockVal')
|
|
||||||
assert.equal(title, 'mockTitleKey')
|
assert.equal(title, 'mockTitleKey')
|
||||||
assert.equal(SendHeader.prototype.onClose.callCount, 0)
|
assert.equal(SendHeader.prototype.onClose.callCount, 0)
|
||||||
onClose()
|
onClose()
|
||||||
|
Loading…
Reference in New Issue
Block a user