Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Item count ARIA is set by popupPagination not item #291

Closed
kirsty-hames opened this issue Jan 5, 2024 · 1 comment · Fixed by #292
Closed

Item count ARIA is set by popupPagination not item #291

kirsty-hames opened this issue Jan 5, 2024 · 1 comment · Fixed by #292

Comments

@kirsty-hames
Copy link
Contributor

Subject of the issue

Each .hotgraphic__pin contains an aria-label that describes the visited state, item title and the item count to assistive technologies. The item count refers to the current item index and the total number of items.
There are two globals properties for item count, item and popupPagination. The .hotgraphic__pin aria-label currently reads as "one slash 3" because it's using the popupPagination which sets the visual item count e.g. 1 / 3

Expected behaviour

I'd expect this to read as "Item one of three" as per the Boxmenu item count aria-label.

Use item instead of popupPagination to set itemCount:
const itemCount = compile(globals._components?._hotgraphic?.popupPagination || '', { itemNumber: _index + 1, totalItems: _items.length });]

@kirsty-hames kirsty-hames self-assigned this Jan 5, 2024
github-actions bot pushed a commit that referenced this issue Feb 7, 2024
# [6.11.0](v6.10.1...v6.11.0) (2024-02-07)

### Update

* Item count ARIA updates (fixes #291) (#292) ([3826047](3826047)), closes [#291](#291) [#292](#292)
Copy link

github-actions bot commented Feb 7, 2024

🎉 This issue has been resolved in version 6.11.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants