codeant-ai-for-open-source[bot] commented on code in PR #42600:
URL: https://github.com/apache/superset/pull/42600#discussion_r3685474767


##########
superset-frontend/packages/superset-ui-core/src/components/Select/Select.stories.tsx:
##########
@@ -338,6 +338,46 @@ AtEveryCorner.parameters = {
   },
 };
 
+const manyPermissionLabels = [
+  'can read SavedQuery',
+  'can write SavedQuery',
+  'can read Database',
+  'can read Query',
+  'can activate TabStateView',
+  'can copy clipboard Superset',
+  'can csv Superset',
+  'can delete query TabStateView',
+  'can delete TableSchemaView',
+  'can delete TabStateView',
+  'can estimate query cost SQLLab',
+  'can execute sql query SQLLab',
+];
+const manyPermissionOptions = Array.from({ length: 32 }, (_, i) => ({
+  label:
+    manyPermissionLabels[i % manyPermissionLabels.length] +
+    (i >= manyPermissionLabels.length ? ` ${i}` : ''),
+  value: `perm_${i}`,
+}));
+
+/**
+ * Regression coverage for a narrow container where selected tags wrap to
+ * multiple rows (e.g. the Role edit modal's Permissions field, which has no
+ * `maxTagCount` override and defaults to wrapping at 4 tags per row). See
+ * https://github.com/apache/superset/issues/39339.
+ */
+export const ManySelectedValuesWrapping = () => (
+  <div style={{ width: 600 }}>
+    <Select
+      ariaLabel="many-selected-values-select"
+      mode="multiple"
+      showSearch
+      options={manyPermissionOptions}
+      value={manyPermissionOptions.map(o => o.value)}
+      getPopupContainer={trigger => trigger.parentElement as HTMLElement}

Review Comment:
   ✅ **Customized review instruction saved!**
   
   **Instruction:**
   > Do not require Select stories covering this regression to set maxTagCount 
to render every selected value; preserving the default collapsed tag behavior 
is intentional when testing overflow and wrapping in the real-world layout.
   
   **Applied to:**
     - 
`superset-frontend/packages/superset-ui-core/src/components/Select/Select.stories.tsx`
   
   ---
   💡 *To manage or update this instruction, visit: [CodeAnt AI 
Settings](https://app.codeant.ai/org/settings/learnings)*



-- 
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