Repository navigation
Conversation
Codecov Report
@@ Coverage Diff @@
## main #2595 +/- ##
==========================================
- Coverage 90.54% 90.48% -0.06%
==========================================
Files 38 38
Lines 3681 3690 +9
Branches 487 485 -2
==========================================
+ Hits 3333 3339 +6
- Misses 348 351 +3
|
nstepien
marked this pull request as ready for review
August 20, 2021 17:11
nstepien
commented
Aug 20, 2021
| // handle case where the pointer `up`'d outside an iframe | ||
| // https://bugs.chromium.org/p/chromium/issues/detail?id=606896 | ||
| // https://bugs.chromium.org/p/chromium/issues/detail?id=693494 | ||
| onPointerUp(); |
Collaborator
Author
There was a problem hiding this comment.
https://developer.mozilla.org/en-US/docs/Web/API/Element/setPointerCapture
Actually the example on this page is in an iframe and it works fine, wonder what's different with the storybook.
We could remove this check 🤔
amanmahajan7
approved these changes
Aug 20, 2021
nstepien
enabled auto-merge (squash)
August 20, 2021 18:11
amanmahajan7
added a commit
that referenced
this pull request
Nov 2, 2026
## Summary Small accessibility fixes from an audit of the grid against Chrome's [Modern Web Guidance](https://developer.chrome.com/docs/modern-web-guidance) accessibility guides. None of them change public APIs. The group toggle changes that were in earlier commits are reverted. The toggle will move to the group row in a separate PR. ## Changes ### Text editor (`renderTextEditor`) - **Accessible name:** the input had none. It's now labeled with the column's `name` when that name is a string. Columns with a React element as their name still get no label, since there's no text to use. - **Contrast in light mode:** | | Before | After | Required | | --- | --- | --- | --- | | Border | `#ccc`, 1.61:1 | `#8f8f8f`, 3.23:1 | 3:1 (WCAG 1.4.11) | | Placeholder | `#999`, 2.85:1 | `#767676`, 4.54:1 | 4.5:1 (WCAG 1.4.3) | Dark mode keeps `#ccc` for the border (already 10:1) and `#999` for the placeholder (already 5.65:1), using `light-dark()`. ### Resize handle - **Was:** `touch-action: none` on the whole resizable header cell, so the grid couldn't be scrolled by touch from those headers. - **Now:** only the resize handle has it. - **Why it was on the header:** it was added in #2595, when the handle was a `::after` pseudo-element of the header cell. Today the handle is its own element with its own pointer handlers. ### Reduced motion - The sort arrow and group caret shape animations (`transition: d 0.1s`) now run only under `@media (prefers-reduced-motion: no-preference)`. - The frozen-column shadow's opacity fade is unchanged, since a fade isn't the kind of motion this preference targets. ## Testing - `vp check` and `vp run typecheck` pass. - **New assertion:** the editor's accessible name, in `renderTextEditor.test.tsx`. - **Existing tests:** `TreeDataGrid`, `renderTextEditor` and `resizable` pass. - **Not tested automatically:** the `touch-action` move and the reduced-motion rules, which are CSS-only. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
https://developer.mozilla.org/en-US/docs/Web/API/Element/setPointerCapture
https://developer.mozilla.org/en-US/docs/Web/API/Element/releasePointerCapture
With this API, we shouldn't need any special handling when the pointer is outside the target.
Except iframes...
I believe we also don't need to check for multi-touch, not 100% sure, can't really test.
We should try this with the drag handle as well.