microsoft / microsoft/fluentui-apple

Accessibility issue in TwoLineTitleView

Open
#1,926 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Swift
Stars
977
Forks
180
Avg merge
21h 38m
Merged PRs (30d)
1

Description

Environment Information
  • Platform:
    • iOS
    • macOS
  • Package version(s): 0.23.0 using SwiftPM
  • Xcode and OS versions: Xcode 15.0 in MacOS 13.6.2, target is iPhone simulator 17.0
Please provide a reproduction of the bug:

Just create a TwoLineTitleView in empty view controller and check accessibility of the TwoLineTitleView.

    func addTwoLineView() {
        let twolineView = TwoLineTitleView()
        twolineView.frame = CGRect(x: 30, y: 100, width: 200, height: 40)

        twolineView.setup(title: "title", subtitle: "subtitle", interactivePart: .subtitle)
        twolineView.delegate = self
        view.addSubview(twolineView)
}
Actual behavior:

The TwoLineTitleView should act as two a11y element and tap each one would trigger the twoLineTitleViewDidTapOnTitle method.
image

Expected behavior:

The TwoLineTitleView should act as a whole a11y element as in teh Photo app
image

Priorities and help requested:

Are you willing to submit a PR to fix?: No

Requested priority: Normal

Products/applications affected: Not yet

Additional thought

I am thing what's the expected behavior here. Should we treate it as a whole element or not?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the issue with TwoLineTitleView using the setup(title:subtitle:interactivePart:) example and inspect its accessibility behavior. Confirm whether the intended result is one accessibility element or separate title and subtitle elements, then verify that the chosen behavior triggers the expected delegate action when activated.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift
Domain
accessibility
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.