bito-code-review[bot] commented on code in PR #35460:
URL: https://github.com/apache/superset/pull/35460#discussion_r2400090566


##########
superset-frontend/plugins/plugin-chart-table/src/TableChart.tsx:
##########
@@ -225,13 +225,9 @@ function SelectPageSize({
   const { Option } = Select;
 
   return (
-    <>
-      <label htmlFor="pageSizeSelect" className="sr-only">
-        {t('Select page size')}
-      </label>
+    <span className="dt-select-page-size">
       {t('Show')}{' '}
       <Select<number>

Review Comment:
   
   <div>
   
   
   <div id="suggestion">
   <div id="issue"><b>Accessibility compliance broken</b></div>
   <div id="fix">
   
   The PR removes the accessibility label and id from the SelectPageSize 
component, breaking WCAG 2.1 compliance and screen reader support. The `label` 
with `htmlFor="pageSizeSelect"` provides critical association between the label 
and the `Select` component for assistive technologies. This affects downstream 
usage in `DataTable` component where `SelectPageSize` is rendered as 
`selectPageSize` prop. Restore the hidden label for screen readers and maintain 
the id association to ensure the dropdown remains accessible.
   </div>
   <details>
   <summary>
   <b>Code suggestion</b>
   </summary>
   <blockquote>Check the AI-generated fix before applying</blockquote>
   <div id="code">
   
   
   ```suggestion
         <label htmlFor="pageSizeSelect" className="sr-only">
           {t('Show')} {t('Select page size')}
         </label>
         {t('Show')} {' '}
         <Select<number> id="pageSizeSelect"
   ```
   
   </div>
   </details>
   </div>
   
   
   
   <small><i>Code Review Run <a 
href=https://github.com/apache/superset/pull/35460#issuecomment-3363082030>#a735d3</a></i></small>
   </div>
   
   ---
   Should Bito avoid suggestions like this for future reviews? (<a 
href=https://alpha.bito.ai/home/ai-agents/review-rules>Manage Rules</a>)
   - [ ] Yes, avoid them



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to