[Selection API] Implement selection.direction
Add selection.direction [1] which returns "none", "forward" or
"backward".
We also update the WPT test selection-direction.tentative.html
to remove the selection click-based tests as this behavior is not
standardized across browsers [2] [3].
[1] https://w3c.github.io/selection-api/#dom-selection-direction
[2] w3c/selection-api#70 (comment)
[3] w3c/selection-api#177 (comment)
Change-Id: I2aad4f8efc4f3d700437501929af274116f7910a
Bug: 40286116
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5677331
Commit-Queue: Di Zhang dizhangg@chromium.org
Reviewed-by: Kent Tamura tkent@chromium.org
Cr-Commit-Position: refs/heads/main@{#1324573}