Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SearchBox] onChange and flex layout fix for IE #3664

Merged
merged 2 commits into from
Jan 24, 2018

Conversation

htryggva
Copy link
Contributor

@htryggva htryggva commented Jan 4, 2018

Description of changes

Fixes two things for the SearchBox when running on IE:

  • Layout issue causing the flex layout to break (the clear button was not right aligned)
  • Focusing on the SearchBox caused onChange to be called, which is inconsistent with Chrome.

@msftclas
Copy link

msftclas commented Jan 4, 2018

CLA assistant check
All CLA requirements met.

@@ -133,7 +133,9 @@ export function getStyles(props: ISearchBoxStyleProps): ISearchBoxStyles {
fontSize: 'inherit',
color: palette.neutralPrimary,
backgroundColor: 'transparent',
flex: '1 1 0',
flexBasis: 0,
Copy link
Contributor

Choose a reason for hiding this comment

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

why change this? it's more bytes-over-wire

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I changed it because IE didn't support this shorthand format:
flex: '1 1 0'

flex: '1 1 0px' does work, however. I've updated the branch.

BTW: This fixes an issue where the clear button is incorrectly positioned:

image

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah, good to know we need the px on the flex-basis part no matter what, thanks for catching that.

@lynamemi lynamemi merged commit 79ea899 into microsoft:master Jan 24, 2018
chrismohr pushed a commit to chrismohr/office-ui-fabric-react that referenced this pull request Apr 17, 2018
* [SearchBox] onChange and flex layout fix for IE

* [SearchBox] Use flex shorthand
@microsoft microsoft locked as resolved and limited conversation to collaborators Aug 31, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants