document.execCommand("copy") always returns false

Fixed Issue #16257511

Details

Created
Mar 6, 2018
Privacy
This issue is public.
Found in build #
15.15063
Reports
Reported by 1 person

Sign in to watch or report this issue.

Steps to reproduce

Check-in Instructions

PR Pull Request 1056827: 14080262 document.execCommand(“copy”) always returns false

Conflict Contact

naiyij

Submitted by

naiyij

What is the issue?

Sample html attached. Open F12 Console and click button; console log should show true
but shows false
.
Basically, as per MDN docs, we should return false only in when command either not supported or enabled:
"Return value
A Boolean that is false if the command is not supported or enabled. Note: Only returns true if part of a user interaction i.e not to be used to verify browser support before rendering an element that calls a command. "
In case of PreventDefault, it should return true.

How was the issue/bug found?

This bug was reported by Lucas Garronlgarron@live.com
and is publicly viewable at
https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/14080262/

Quantify the impact of the issue - why do we need to service this issue now?

Excel Online alone had 20,647,693 Edge sessions
in January. This constitutes merely ~5.31% of our monthly usage. The rest is
done via other browsers.

 

Once we ship our infra, the UX in other browsers
will become superior to that of Edge unless you backport the fix. And
copy/paste being a highly used operation will induce Office Online users to
choose other browsers.

 

The CCP infrastructure will serve more than just Excel
Online and is tailored to be common among other Office Online applications. We
are eager to release it to production within the next couple of months and
execCommand() fixes for Edge are an important part of it

Is the fix ready and what is it?

Office online folks  would
like the fix to be serviced in RS3. The change is not risky and has been in RS4
branches for a while now.

How was the fix Validated?

This was fixed  and validated in RS4

Regression risk level of the fix

low

Has the fix been flighted in a RS4 flight??

Yes

Do you have any data points that can be monitored to ensure that the fix works or if there are adverse effects from the fix?

?

Does this fix need to be backported to TH2, RS1, RS2 or prior releases (for CBB/LTSB customers)?

No

QD signing off on this change

naiyij

How to validate/test for regressions

(required for WSD pre-release validation)

Scenario to validate
:
Sample html attached. Open F12 Console and click button; console log should show true
but shows false
.
Expected behavior
:
Sample html attached. Open F12 Console and click button; console log should show true
but shows false
.
Optional: list potential issues arising from the bug fix
:
<Potential regressions or negative results based on the change>

Attachments

0 attachments

    Comments and activity

    • Microsoft Edge Team

      Changed Assigned To to “wsdcfebrowser”

      Changed Steps to Reproduce

      Changed Assigned To from “wsdcfebrowser” to “Naiyi J.”

      Changed Steps to Reproduce

      Changed Steps to Reproduce

      Changed Status to “Confirmed”

      Changed Assigned To from “Naiyi J.” to “Brent M.”

      Changed Status from “Confirmed” to “Fixed”

    You need to sign in to your Microsoft account to add a comment.

    Sign in