Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions packages/react-core/src/components/DataList/DataListItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export interface DataListItemProps extends Omit<React.HTMLProps<HTMLLIElement>,
children: React.ReactNode;
/** Additional classes added to the DataList item should be either <DataListItemRow> or <DataListContent> */
className?: string;
/** Adds accessible text to the DataList item */
/** Adds an accessible name to the selectable input if one is rendered */
'aria-labelledby': string;
/** Unique id for the DataList item */
id?: string;
Expand Down Expand Up @@ -86,9 +86,7 @@ class DataListItem extends React.Component<DataListItemProps> {
selectedDataListItemId && isSelected && styles.modifiers.selected,
className
)}
aria-labelledby={ariaLabelledBy}
{...(isSelectable && { tabIndex: 0, onClick: selectDataListItem, onKeyDown })}
{...(isSelectable && isSelected && { 'aria-selected': true })}
{...props}
>
{onSelectableRowChange && (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
exports[`DataListItem should match snapshot (auto-generated) 1`] = `
<DocumentFragment>
<li
aria-labelledby="string"
class="pf-v6-c-data-list__item ''"
id="''"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
exports[`Renders to match snapshot 1`] = `
<DocumentFragment>
<li
aria-labelledby="item-1"
class="pf-v6-c-data-list__item"
id=""
/>
Expand Down
Loading