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

feat(ui5-timeline-item): introduce state property #10277

Merged
merged 15 commits into from
Jan 20, 2025
Merged

feat(ui5-timeline-item): introduce state property #10277

merged 15 commits into from
Jan 20, 2025

Conversation

hinzzx
Copy link
Contributor

@hinzzx hinzzx commented Nov 29, 2024

Introducing state property into the <ui5-timeline-item> web component.

The state property allows you to set the semantic state of the icon using the following values: Information, Positive, Critical, Negative or None.
Each state automatically changes the icon's color to visually represent the corresponding state, improving clarity and consistency.
The state is also accessible. Screen readers will read the text, ensuring that users with assistive technologies can understand the semantic meaning.

Sample usecases with and without state property

With

image

Without

image

Fixes: #9806

Copy link
Contributor

@unazko unazko left a comment

Choose a reason for hiding this comment

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

  • From the commit description - the semantic meaning gets set over the ui5-timeline-item and not only over the icon.
  • You could add a test, in order to check whether the accessible-description property results into aria-description over the inner element.

Tested with NVDA and JAWS. The announcements are as expected.

packages/fiori/src/themes/TimelineItem.css Outdated Show resolved Hide resolved
packages/fiori/src/TimelineItem.ts Show resolved Hide resolved
packages/fiori/src/TimelineItem.ts Outdated Show resolved Hide resolved
packages/fiori/src/types/TimelineItemStatus.ts Outdated Show resolved Hide resolved
packages/fiori/src/types/TimelineItemStatus.ts Outdated Show resolved Hide resolved
packages/fiori/src/types/TimelineItemStatus.ts Outdated Show resolved Hide resolved
packages/fiori/src/types/TimelineItemStatus.ts Outdated Show resolved Hide resolved
packages/fiori/src/types/TimelineItemStatus.ts Outdated Show resolved Hide resolved
packages/fiori/src/TimelineItem.ts Outdated Show resolved Hide resolved
packages/fiori/src/TimelineGroupItem.ts Outdated Show resolved Hide resolved
packages/fiori/src/types/TimelineItemStatus.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@vladitasev vladitasev left a comment

Choose a reason for hiding this comment

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

See Dialog, NotificationListItem:

@property() state: ${ValueState}= "None" (edited)

In short:

  • change the name to state to be consistent
  • use the existing enum

@hinzzx hinzzx changed the title feat(ui5-timeline-item): introduce status property feat(ui5-timeline-item): introduce state property Jan 14, 2025
@hinzzx hinzzx requested review from unazko and vladitasev January 15, 2025 11:50
@hinzzx hinzzx merged commit b378604 into main Jan 20, 2025
10 checks passed
@hinzzx hinzzx deleted the feat-tli-status branch January 20, 2025 13:00
@ui5-webcomponents-bot
Copy link
Collaborator

🎉 This PR is included in version v2.7.0-rc.1 🎉

The release is available on v2.7.0-rc.1

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

[Timeline]: [No text alternative for the icons]
5 participants