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

Fix margin around the button on about:safebrowsing & Add browserButton_subtleItem fixing regressions #9026

Merged
merged 3 commits into from
May 30, 2017
Merged

Fix margin around the button on about:safebrowsing & Add browserButton_subtleItem fixing regressions #9026

merged 3 commits into from
May 30, 2017

Conversation

luixxiul
Copy link
Contributor

@luixxiul luixxiul commented May 24, 2017

On the 1st commit:
Fix margin around the button on about:safebrowsing

On the 2nd commit:
Add browserButton_subtleItem fixing regressions

  • Add lines in the same way as LESS files
  • Add comments for refenrence (We could remove them after refactoring work)
  • Fix regressions on browserButton_default
    • Add globalStyles.button.color to replace it with globalStyles.button.default.color
  • Fix a typo

Closes #8945
Closes #9072
Addresses #9025
Addresses #9071

Auditors:

Test Plan 1:

  1. Take a screenshot of the buttons section on about:styles before testing the PR for later use
  2. Open about:styles
  3. Click "buttons"
  4. Take another screenshot of the section
  5. Compare the two screenshots and make sure they look same

Test Plan 2:

  1. Open about:styles
  2. Toggle developer tools
  3. Make sure button's padding is set to '5px 16px'

Test Plan 3:

  1. Open downloadme.org
  2. Click "Advanced" button
  3. Make sure the button is not pushed down
  4. Click "Hide advanced" button
  5. Make sure the button does not move

Submitter Checklist:

  • Submitted a ticket for my issue if one did not already exist.
  • Used Github auto-closing keywords in the commit message.
  • Added/updated tests for this change (for new code or code which already has tests).
  • Ran git rebase -i to squash commits (if needed).

Reviewer Checklist:

Tests

  • Adequate test coverage exists to prevent regressions
  • Tests should be independent and work correctly when run individually or as a suite ref
  • New files have MPL2 license header

</div>
? <section>
<div className='buttons'>
<Button className='subtleButton'
Copy link
Contributor

Choose a reason for hiding this comment

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

could we take advantage of this PR and add subtleButton to <BrowserButton> component?

Copy link
Contributor Author

@luixxiul luixxiul May 26, 2017

Choose a reason for hiding this comment

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

ah right, I've totally forgot about that component :-p

I'll replace it with that, adding subtleButton. Thanks for heads up.

@luixxiul luixxiul changed the title Fix margin around the button on about:safebrowsing Fix margin around the button on about:safebrowsing & Add browserButton_subtleItem fixing regressions May 26, 2017
@luixxiul
Copy link
Contributor Author

luixxiul commented May 26, 2017

on the 2nd commit I fixed several regressions introduced with #8568 for 0.15.3, which seem to me a not blocker. I think it's fine to wait for 0.16 series.

paddingLeft: '16px',

// cf: https://github.com/brave/browser-laptop/blob/548e11b1c889332fadb379237555625ad2a3c845/less/button.less#L98
minWidth: `calc(${globalStyles.spacing.defaultFontSize} * 6)`, // issue #6384
Copy link
Contributor

Choose a reason for hiding this comment

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

nice catch


browserButton_subtleItem: {
// cf: https://github.com/brave/browser-laptop/blob/548e11b1c889332fadb379237555625ad2a3c845/less/button.less#L151-L152
background: '#ccc',
Copy link
Contributor

Choose a reason for hiding this comment

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

this should belong to global styles

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed with 03a9abd

Suguru Hirahara added 3 commits May 29, 2017 22:46
Closes #8945
Addresses #9025

Auditors:

Test Plan:
1. Open downloadme.org
2. Click "Advanced" button
3. Click "Hide advanced" button
4. Make sure the button does not move
Closes #9072
Addresses #9071

Also:
- Add lines in the same way as LESS files
- Add comments for refenrence (We could remove them after refactoring work)
- Fix regressions on browserButton_default
  - Add globalStyles.button.color to replace it with globalStyles.button.default.color
- Fix a typo

Auditors:

Test Plan 1:
(0. Take a screenshot of the buttons section on about:styles before testing the PR for later use)
1. Open about:styles
2. Click "buttons"
3. Take another screenshot of the section
4. Compare the two screenshots and make sure they look same

Test Plan 2:
1. Open about:styles
2. Toggle developer tools
3. Make sure button's padding is set to '5px 16px'

Test Plan 3:
1. Open downloadme.org
2. Click "Advanced" button
3. Make sure the button is not pushed down
4. Click "Hide advanced" button
5. Make sure the button does not move
Copy link
Contributor

@cezaraugusto cezaraugusto left a comment

Choose a reason for hiding this comment

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

++

@cezaraugusto cezaraugusto merged commit e93ce87 into brave:master May 30, 2017
@luixxiul
Copy link
Contributor Author

@cezaraugusto thanks for review.

@luixxiul luixxiul deleted the aboutSafebrowsing-aphrodite branch June 2, 2017 04:28
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add browserButton_subtleItem to BrowserButton component button styling on about:safebrowsing
2 participants