Skip to content

Conversation

@chunhtai
Copy link
Contributor

@chunhtai chunhtai commented Feb 21, 2025

adding a new property in semantics properties called controlsVisibilityOfNodes, where developer can assign SemanticsProperties.identifier of other nodes to indicates which nodes' visibilities this node controls

fixes #162125

Pre-launch Checklist

If you need help, consider asking for advice on the #hackers-new channel on Discord.

@flutter-dashboard
Copy link

It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption, contact "@test-exemption-reviewer" in the #hackers channel in Discord (don't just cc them here, they won't see it!).

If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix?

Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing. The test exemption team is a small volunteer group, so all reviewers should feel empowered to ask for tests, without delegating that responsibility entirely to the test exemption group.

@github-actions github-actions bot added framework flutter/packages/flutter repository. See also f: labels. engine flutter/engine related. See also e: labels. a: accessibility Accessibility, e.g. VoiceOver or TalkBack. (aka a11y) platform-web Web applications specifically labels Feb 21, 2025
@chunhtai chunhtai marked this pull request as draft February 21, 2025 21:58
@chunhtai
Copy link
Contributor Author

test will be added after we agree this is the approach we want to take

Copy link
Contributor

@mdebbar mdebbar left a comment

Choose a reason for hiding this comment

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

LGTM after addressing Yegor's questions/comments.

@chunhtai chunhtai marked this pull request as ready for review March 4, 2025 23:27
@chunhtai chunhtai requested a review from yjbanov March 4, 2025 23:28
@github-actions github-actions bot added the a: tests "flutter test", flutter_test, or one of our tests label Mar 5, 2025
void _updateControls() {
if (semanticsObject.hasControlsNodes) {
semanticsObject.owner.addOneTimePostUpdateCallback(() {
final List<String> elementIds = <String>[];
Copy link
Contributor

Choose a reason for hiding this comment

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

Here and elsewhere, feel free to omit local variable types, such as final elementIds = <String>[] is just fine, especially in new code.

return false;
}
// They most both be non-null now.
if (a!.length != b!.length) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Are null and empty list not equivalent?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

will update

key: key,
controlsNodes: const <String>{'abc', 'ghi'},
child: Semantics(
controlsNodes: const <String>{'abc', 'def'},
Copy link
Contributor

Choose a reason for hiding this comment

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

Now that I think about it, merging nodes that control different things feels wrong 🤔

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 think they are fine, developer can compose controlsNodes. They may have different widget that provides different control information while another provide tap action

@chunhtai chunhtai added the autosubmit Merge PR when tree becomes green via auto submit App label Mar 6, 2025
@auto-submit auto-submit bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Mar 6, 2025
@auto-submit
Copy link
Contributor

auto-submit bot commented Mar 6, 2025

autosubmit label was removed for flutter/flutter/163894, because - The status or check suite Google testing has failed. Please fix the issues identified (or deflake) before re-applying this label.

@chunhtai chunhtai added the autosubmit Merge PR when tree becomes green via auto submit App label Mar 6, 2025
@auto-submit auto-submit bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Mar 6, 2025
@auto-submit
Copy link
Contributor

auto-submit bot commented Mar 6, 2025

autosubmit label was removed for flutter/flutter/163894, because - The status or check suite Linux linux_unopt has failed. Please fix the issues identified (or deflake) before re-applying this label.

@chunhtai chunhtai added the autosubmit Merge PR when tree becomes green via auto submit App label Mar 6, 2025
@auto-submit auto-submit bot added this pull request to the merge queue Mar 6, 2025
Merged via the queue into flutter:master with commit e0b9869 Mar 6, 2025
178 checks passed
@flutter-dashboard flutter-dashboard bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Mar 6, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Mar 7, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Mar 7, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Mar 7, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Mar 7, 2025
auto-submit bot pushed a commit to flutter/packages that referenced this pull request Mar 7, 2025
flutter/flutter@321fbc0...6b93cf9

2025-03-07 [email protected] Roll Skia from 32c1931117b8 to cbc7e99d6c2f (1 revision) (flutter/flutter#164788)
2025-03-07 [email protected] Roll Packages from fc9d5ca to 4c5a7ed (4 revisions) (flutter/flutter#164785)
2025-03-07 [email protected] Roll Skia from 79f8af105a61 to 32c1931117b8 (1 revision) (flutter/flutter#164782)
2025-03-07 [email protected] Roll Fuchsia Linux SDK from fhm5z889sA5T1AQao... to ixl5bKWCqsRiYGvps... (flutter/flutter#164780)
2025-03-07 [email protected] Roll Skia from 181d81920670 to 79f8af105a61 (1 revision) (flutter/flutter#164770)
2025-03-07 [email protected] Roll Skia from cc74d34e7e68 to 181d81920670 (1 revision) (flutter/flutter#164766)
2025-03-07 [email protected] Clip layers reduce rrects and paths to simpler shapes when possible (flutter/flutter#164693)
2025-03-07 [email protected] [Impeller] test empty snapshot and allocation failure. (flutter/flutter#164668)
2025-03-07 [email protected] Roll Skia from 263308ea4386 to cc74d34e7e68 (2 revisions) (flutter/flutter#164746)
2025-03-06 [email protected] Adds aria-controls support (flutter/flutter#163894)
2025-03-06 [email protected] Migrate Mutators to DisplayList/Impeller geometry (flutter/flutter#164258)
2025-03-06 [email protected] Add lldb init file (flutter/flutter#164344)
2025-03-06 [email protected] Use separate artifacts for arm64 and x64 versions of gen_snapshot on Apple platforms (flutter/flutter#164419)
2025-03-06 [email protected] Roll Skia from ccd8cc23aa94 to 263308ea4386 (1 revision) (flutter/flutter#164728)
2025-03-06 [email protected] [hcpp] Add tests for transform mutator (flutter/flutter#164664)
2025-03-06 [email protected] Roll pub packages (flutter/flutter#164721)
2025-03-06 [email protected] Roll Packages from abba683 to fc9d5ca (3 revisions) (flutter/flutter#164714)
2025-03-06 [email protected] Roll pub packages (flutter/flutter#164713)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages
Please CC [email protected],[email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 20, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 20, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 21, 2025
androidseb pushed a commit to androidseb/packages that referenced this pull request Jun 8, 2025
flutter/flutter@321fbc0...6b93cf9

2025-03-07 [email protected] Roll Skia from 32c1931117b8 to cbc7e99d6c2f (1 revision) (flutter/flutter#164788)
2025-03-07 [email protected] Roll Packages from fc9d5ca to 4c5a7ed (4 revisions) (flutter/flutter#164785)
2025-03-07 [email protected] Roll Skia from 79f8af105a61 to 32c1931117b8 (1 revision) (flutter/flutter#164782)
2025-03-07 [email protected] Roll Fuchsia Linux SDK from fhm5z889sA5T1AQao... to ixl5bKWCqsRiYGvps... (flutter/flutter#164780)
2025-03-07 [email protected] Roll Skia from 181d81920670 to 79f8af105a61 (1 revision) (flutter/flutter#164770)
2025-03-07 [email protected] Roll Skia from cc74d34e7e68 to 181d81920670 (1 revision) (flutter/flutter#164766)
2025-03-07 [email protected] Clip layers reduce rrects and paths to simpler shapes when possible (flutter/flutter#164693)
2025-03-07 [email protected] [Impeller] test empty snapshot and allocation failure. (flutter/flutter#164668)
2025-03-07 [email protected] Roll Skia from 263308ea4386 to cc74d34e7e68 (2 revisions) (flutter/flutter#164746)
2025-03-06 [email protected] Adds aria-controls support (flutter/flutter#163894)
2025-03-06 [email protected] Migrate Mutators to DisplayList/Impeller geometry (flutter/flutter#164258)
2025-03-06 [email protected] Add lldb init file (flutter/flutter#164344)
2025-03-06 [email protected] Use separate artifacts for arm64 and x64 versions of gen_snapshot on Apple platforms (flutter/flutter#164419)
2025-03-06 [email protected] Roll Skia from ccd8cc23aa94 to 263308ea4386 (1 revision) (flutter/flutter#164728)
2025-03-06 [email protected] [hcpp] Add tests for transform mutator (flutter/flutter#164664)
2025-03-06 [email protected] Roll pub packages (flutter/flutter#164721)
2025-03-06 [email protected] Roll Packages from abba683 to fc9d5ca (3 revisions) (flutter/flutter#164714)
2025-03-06 [email protected] Roll pub packages (flutter/flutter#164713)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages
Please CC [email protected],[email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
FMorschel pushed a commit to FMorschel/packages that referenced this pull request Jun 9, 2025
flutter/flutter@321fbc0...6b93cf9

2025-03-07 [email protected] Roll Skia from 32c1931117b8 to cbc7e99d6c2f (1 revision) (flutter/flutter#164788)
2025-03-07 [email protected] Roll Packages from fc9d5ca to 4c5a7ed (4 revisions) (flutter/flutter#164785)
2025-03-07 [email protected] Roll Skia from 79f8af105a61 to 32c1931117b8 (1 revision) (flutter/flutter#164782)
2025-03-07 [email protected] Roll Fuchsia Linux SDK from fhm5z889sA5T1AQao... to ixl5bKWCqsRiYGvps... (flutter/flutter#164780)
2025-03-07 [email protected] Roll Skia from 181d81920670 to 79f8af105a61 (1 revision) (flutter/flutter#164770)
2025-03-07 [email protected] Roll Skia from cc74d34e7e68 to 181d81920670 (1 revision) (flutter/flutter#164766)
2025-03-07 [email protected] Clip layers reduce rrects and paths to simpler shapes when possible (flutter/flutter#164693)
2025-03-07 [email protected] [Impeller] test empty snapshot and allocation failure. (flutter/flutter#164668)
2025-03-07 [email protected] Roll Skia from 263308ea4386 to cc74d34e7e68 (2 revisions) (flutter/flutter#164746)
2025-03-06 [email protected] Adds aria-controls support (flutter/flutter#163894)
2025-03-06 [email protected] Migrate Mutators to DisplayList/Impeller geometry (flutter/flutter#164258)
2025-03-06 [email protected] Add lldb init file (flutter/flutter#164344)
2025-03-06 [email protected] Use separate artifacts for arm64 and x64 versions of gen_snapshot on Apple platforms (flutter/flutter#164419)
2025-03-06 [email protected] Roll Skia from ccd8cc23aa94 to 263308ea4386 (1 revision) (flutter/flutter#164728)
2025-03-06 [email protected] [hcpp] Add tests for transform mutator (flutter/flutter#164664)
2025-03-06 [email protected] Roll pub packages (flutter/flutter#164721)
2025-03-06 [email protected] Roll Packages from abba683 to fc9d5ca (3 revisions) (flutter/flutter#164714)
2025-03-06 [email protected] Roll pub packages (flutter/flutter#164713)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages
Please CC [email protected],[email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

a: accessibility Accessibility, e.g. VoiceOver or TalkBack. (aka a11y) a: tests "flutter test", flutter_test, or one of our tests engine flutter/engine related. See also e: labels. framework flutter/packages/flutter repository. See also f: labels. platform-web Web applications specifically

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Flutter Web: aria-controls must be an available property on all component types (Accessibility)

3 participants