Skip to content

Commit

Permalink
Feedback changes
Browse files Browse the repository at this point in the history
  • Loading branch information
karthick-murugan committed Dec 18, 2024
1 parent 8006447 commit d68f305
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@ export default function DataViewsSelectionCheckbox< Item >( {
}: DataViewsSelectionCheckboxProps< Item > ) {
const id = getItemId( item );
const checked = ! disabled && selection.includes( id );
let selectionLabel;
if ( titleField?.getValue && item ) {
selectionLabel = titleField.getValue( { item } );
}

// Fallback label to ensure accessibility
const selectionLabel = titleField?.getValue?.( { item } ) || 'Select item';

return (
<CheckboxControl
className="dataviews-selection-checkbox"
Expand Down

0 comments on commit d68f305

Please sign in to comment.