fluentui icon indicating copy to clipboard operation
fluentui copied to clipboard

Icon Button: Clicking on the button creates flickering behaviour

Open twarzo opened this issue 8 years ago • 2 comments

Bug Report

  • Package version(s): (fill this out)
  • Browser and OS versions: IE and Windows 10

Priorities and help requested:

Are you willing to submit a PR to fix? No

Requested priority: Normal

Products/sites affected: VSTS

Describe the issue:

Clicking on the button makes the button jumps.

Actual behavior:

The button jumps when clicked.

Expected behavior:

The button should not show flickering/jumpy behavior on click.

iconbuttonflickerbehaviour

twarzo avatar Aug 08 '18 05:08 twarzo

Hey @twarzo it looks like this is a known issue for buttons in IE. It looks like the problem is fixed by adding the following styles and wrapping the button in the span:

button:active span {
    	position:relative;
    	top: 0;
    	left: 0;
}

...

<button><span>I don't move!</span><button>

(Reference: https://stackoverflow.com/questions/10305658/prevent-button-from-shifting-during-click-in-ie)

@dzearing I heard you're working on a refactor for buttons, do you think this is something you want to account for in your PR?

natalieethell avatar Aug 08 '18 17:08 natalieethell

This can be considered in the refactor, but this could just be patched immediately as the fix is relatively small.

dzearing avatar Aug 23 '18 03:08 dzearing