Skip to content

[AppBar] Add iconStyleLeft prop#3668

Closed
59naga wants to merge 1 commit intomui:masterfrom
59naga:master
Closed

[AppBar] Add iconStyleLeft prop#3668
59naga wants to merge 1 commit intomui:masterfrom
59naga:master

Conversation

@59naga
Copy link
Copy Markdown
Contributor

@59naga 59naga commented Mar 11, 2016

#3667

  • PR has tests
  • docs demo, and is linted.
  • Commit and PR titles begin with [ComponentName], and are in imperative form: "[Component] Fix leaky abstraction".
  • Description explains the issue / use-case resolved, and auto-closes the related issue(s) (http://tr.im/vFqem).

Fix #3667

@mbrookes mbrookes changed the title [AppBar] Add iconStyleLeft prop (fix #3667) [AppBar] Add iconStyleLeft prop Mar 11, 2016
Comment thread src/app-bar.jsx

menuElementLeft = (
<div style={prepareStyles(Object.assign({}, styles.iconButtonStyle))}>
<div style={prepareStyles(iconLeftStyle)}>
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Might this be a regression? Why even change these?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

iconRightStyle will change the style of menuElementRight.
iconLeftStyle should also be similar.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Yeah, but this is a breaking change. you shouldn't remove the styles.iconButtonStyle just override it: Object.assign({}, styles.iconButtonStyle, iconLeftStyle)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Oh, I'm sorry. Including a test, and re-commit again at a later date. 😵

@59naga 59naga force-pushed the master branch 2 times, most recently from 91e90bb to 13abf8d Compare March 12, 2016 00:49
Comment thread src/app-bar.jsx
style: prepareStyles(Object.assign(styles.title, styles.mainElement, titleStyle)),
}, title);

const iconLeftStyle = Object.assign({}, styles.iconButtonStyle, iconStyleLeft);
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

you shouldn't do this either as it's resulting in calling prepareStyles twice. Please follow my comments as they are 😁

@nathanmarks
Copy link
Copy Markdown
Contributor

@alitaheri @newoga This component is way too rigid.

@newoga
Copy link
Copy Markdown
Contributor

newoga commented Mar 13, 2016

@alitaheri @newoga This component is way too rigid.

I agree, are we still going to try to merge the new AppBar this release?

@59naga
Copy link
Copy Markdown
Contributor Author

59naga commented Mar 17, 2016

👍 yeah, would you like any improvements to other?

Comment thread test/unit/AppBar.spec.js Outdated
import IconButton from 'src/icon-button';
import Paper from 'src/paper';
import NavigationClose from 'src/svg-icons/navigation/close';
import 'src/';
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

What is this for?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

this is a typo, it was deleted 😅

- Add export `getStyles` of app-bar.js for test
@mbrookes mbrookes assigned alitaheri and newoga and unassigned alitaheri Mar 28, 2016
@nathanmarks nathanmarks added the PR: out-of-date The pull request has merge conflicts and can't be merged. label May 15, 2016
@nathanmarks
Copy link
Copy Markdown
Contributor

@newoga what's the situ with this PR?

@59naga 59naga mentioned this pull request May 15, 2016
4 tasks
@59naga
Copy link
Copy Markdown
Contributor Author

59naga commented May 15, 2016

Updated PR. would appreciate your review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

PR: out-of-date The pull request has merge conflicts and can't be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants